This commit is contained in:
Angelos Chalaris 2018-04-26 20:51:48 +03:00
parent 44cb83c04e
commit f1c088b684
88 changed files with 18815 additions and 18815 deletions

26
.gitignore vendored
View file

@ -1,13 +1,13 @@
prepros-6\.config
dist/mini-doc\.min\.css
dist/mini-doc\.css
docs/v3/index-splash-o1\.jpg
docs/v3/index-splash-o2\.jpg
docs/v3/responsive-original\.svg
docs/v3/index-splash_original\.jpg
prepros-6\.config
dist/mini-doc\.min\.css
dist/mini-doc\.css
docs/v3/index-splash-o1\.jpg
docs/v3/index-splash-o2\.jpg
docs/v3/responsive-original\.svg
docs/v3/index-splash_original\.jpg

File diff suppressed because one or more lines are too long

View file

@ -1,192 +1,192 @@
var fs = require('fs');
var version = require('./vinf'); // Gets version info.
var frameworkUrl = `"https://cdnjs.cloudflare.com/ajax/libs/mini.css/${version.version.slice(1)}/mini-default.css"`;
// INDEX
var indexHtml = `<!DOCTYPE html>
<html lang="en">
<head>
<link href="https://fonts.googleapis.com/css?family=Inconsolata:400,700|Poppins:400,400i,500,700,700i&amp;subset=latin-ext" rel="stylesheet">
<link rel="stylesheet" href="./style.min.css">
<title>mini.css - Minimal, responsive, style-agnostic CSS framework</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites.">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, toolkit">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
</head>
<body>
<div class="index-splash">
<div class="index-splash-image no-filter"></div>
<div class="index-splash-image"></div>
<h1 class="splash">mini<small>.css</small></h1>
<p class="splash">minimal, responsive, style-agnostic <br>CSS framework</p>
<p id="version-info">${version.version}</p>
<a class="button splash" href="docs">Get started</a>
</div>
<header class="row sticky">
<span class="col-md-1 col-lg-2"></span>
<span class="logo col-sm-3 col-md">mini.css</span>
<a class="button col-sm col-md" href="docs">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" style="height: 20px; vertical-align: text-top;"><path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"></path><polyline points="14 2 14 8 20 8"></polyline><line x1="16" y1="13" x2="8" y2="13"></line><line x1="16" y1="17" x2="8" y2="17"></line><polyline points="10 9 9 9 8 9"></polyline></svg>
<span>&nbsp;Docs</span></a>
<a class="button col-sm col-md" href="https://github.com/Chalarangelo/mini.css" target="_blank">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" style="height: 20px; vertical-align: text-top;"><path d="M9 19c-5 1.5-5-2.5-7-3m14 6v-3.87a3.37 3.37 0 0 0-.94-2.61c3.14-.35 6.44-1.54 6.44-7A5.44 5.44 0 0 0 20 4.77 5.07 5.07 0 0 0 19.91 1S18.73.65 16 2.48a13.38 13.38 0 0 0-7 0C6.27.65 5.09 1 5.09 1A5.07 5.07 0 0 0 5 4.77a5.44 5.44 0 0 0-1.5 3.78c0 5.42 3.3 6.61 6.44 7A3.37 3.37 0 0 0 9 18.13V22"></path></svg>
<span>&nbsp;Github</span></a>
<a class="button col-sm col-md" href="#">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" style="height: 20px; vertical-align: text-top;"><path d="M20 14.66V20a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h5.34"></path><polygon points="18 2 22 6 12 16 8 16 8 12 18 2"></polygon></svg>
<span>&nbsp;Flavors</span></a>
<span class="col-md-1 col-lg-2"></span>
</header>
<div class="row padded">
<div class="col-sm-12 col-md-10 col-md-offset-1 col-lg-8 col-lg-offset-2">
<img src="./responsive.svg" class="feature-image">
<h2 class="feature-header">Fast and Responsive</h2><br>
<p>Want to build websites that look beautiful on any and all devices, but also load fast on mobile connections? Then <strong>mini.css</strong> is the right tool for you! Its tiny size (under 10KB gzipped), along with its <strong>responsive grid</strong> and modern components ensures that all your users are satisfied and can access your website anytime, anywhere. Bridging the gap between fully-featured frameworks (e.g. Bootstrap and Semantic UI) and micro frameworks (e.g. Milligram and Pure.CSS), <strong>mini.css</strong> packs a lot of features in a small package, while it relies solely on CSS, meaning you do not have to worry about any conflicts with other Javascript libraries you might be using.</p>
</div>
</div>
<div class="row padded alt-back">
<div class="col-sm-12 col-md-10 col-md-offset-1 col-lg-8 col-lg-offset-2">
<img src="./tailored.svg" class="feature-image">
<h2 class="feature-header">Tailored to Your Needs</h2><br>
<p>Creating a CSS framework that caters to everyone's needs is no easy task, but <strong>mini.css</strong> manages to rise to the occasion by providing extensive and coherent documentation in combination with templates, examples and semantic HTML5 markup. Modern UX patterns and accessibility guidelines are well-documented and can be used out of the box, using one of the unique <strong>flavors</strong> that the framework provides. If you still want more, you can create your own custom flavor or tweak an existing one just by opening its CSS file and changing a few custom properties. It's that simple! </p>
</div>
</div>
<div class="row padded primary-section">
<div class="col-sm-12 col-md-10 col-md-offset-1 col-lg-8 col-lg-offset-2">
<h2 class="feature-header">Get started now!</h2><br>
<p>Head over to the <a href="docs">documentation</a> to learn how to get started using <strong>mini.css</strong>, as well as what flavors and components are availble and how to use them to create the website or web app you've always wanted. If you like the framework and want to support it, remember to to star it on Github. It means a lot to us and it only takes a couple of seconds!</p>
<p style="text-align:center;"><a href="docs" class="button">Get started</a></p>
<a href="https://github.com/Chalarangelo/mini.css" target="_blank" class="centered">mini.css on Github</a>
</div>
</div>
<footer class="row"><div class="col-sm-12 col-md-10 col-md-offset-1 col-lg-8 col-lg-offset-2"><p style="text-align: justify;"><strong>mini.css</strong> was designed and built by <a href="https://github.com/Chalarangelo" target="_blank">@Chalarangelo</a>. Source code licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>.</p><p>Icons provided by <a href="https://feathericons.com/" target="_blank">Feather</a>. Photo by <a href="https://unsplash.com/photos/vjMgqUkS8q8" target="_blank">Christopher Gower</a> on <a href="https://unsplash.com" target="_blank">Unsplash</a>.</p></div></footer>
</body>
</html>`;
var indexOutputPath = './docs/v3/index.html'; // This path is relative to package.json.
fs.writeFile(indexOutputPath,
`${indexHtml}`,
function(err) { if(err) return console.log(err); console.log("Index file generated!"); }
);
// DOCUMENTATION
var docFragments = require('./doc-fragments/docFragments'); // Gets all document fragments as a list.
var docOutputPath = './docs/v3/docs.html'; // This path is relative to package.json.
const FEATHER_BANNER = `<a href="https://feathericons.com/" class="section double-padded" id="feather-banner" target="_blank" rel="noopener"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="#f8f8f8" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M20.24 12.24a6 6 0 0 0-8.49-8.49L5 10.5V19h8.5z"></path><line x1="16" y1="8" x2="2" y2="22"></line><line x1="17" y1="15" x2="9" y2="15"></line></svg>&nbsp;Powered by Feather</a>`;
var documentStart = `<!DOCTYPE html><html lang="en"><head>
<link href="https://fonts.googleapis.com/css?family=Inconsolata:400,700|Poppins:400,400i,500,700,700i&amp;subset=latin-ext" rel="stylesheet">
<link rel="stylesheet" href="./style.min.css">
<script src="https://cdnjs.cloudflare.com/ajax/libs/fuse.js/3.0.4/fuse.min.js"></script>
<title>mini.css - Docs</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites.">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, toolkit">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
</head><body>`;
var documentEnd = `</body></html>`;
var appShellStart = `<div id="root"><header class="row">
<span class="logo col-sm-3 col-md">mini.css</span>
<a class="button col-sm col-md" href="https://github.com/Chalarangelo/mini.css" target="_blank">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" style="height: 20px; vertical-align: text-top;"><path d="M9 19c-5 1.5-5-2.5-7-3m14 6v-3.87a3.37 3.37 0 0 0-.94-2.61c3.14-.35 6.44-1.54 6.44-7A5.44 5.44 0 0 0 20 4.77 5.07 5.07 0 0 0 19.91 1S18.73.65 16 2.48a13.38 13.38 0 0 0-7 0C6.27.65 5.09 1 5.09 1A5.07 5.07 0 0 0 5 4.77a5.44 5.44 0 0 0-1.5 3.78c0 5.42 3.3 6.61 6.44 7A3.37 3.37 0 0 0 9 18.13V22"></path></svg>
<span>&nbsp;Github</span></a>
<a class="button col-sm col-md" href="#">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" style="height: 20px; vertical-align: text-top;"><path d="M20 14.66V20a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h5.34"></path><polygon points="18 2 22 6 12 16 8 16 8 12 18 2"></polygon></svg>
<span>&nbsp;Flavors</span></a>
<label for="doc-drawer-checkbox" class="button drawer-toggle col-sm"></label>
</header>
<div class="row" id="doc-wrapper">`;
var appShellEnd = `</div></div>`;
var appSidebarStart = `<input id="doc-drawer-checkbox" class="drawer" value="on" type="checkbox">
<nav class="col-md-4 col-lg-3" id="nav-drawer"><h3>Menu</h3><label for="doc-drawer-checkbox" class="button drawer-close"></label><div><input style="width: 100%; margin: 0px;" placeholder="Search..." type="search" id="search-bar" oninput="search()"></div>`;
var appSidebarEnd = `<span id="no-results">No results found</span></nav>`;
var mainStart = `<main class="col-sm-12 col-md-8 col-lg-9" id="doc-content">`;
var mainEnd = `<footer><p><strong>mini.css</strong> was designed and built by <a href="https://github.com/Chalarangelo" target="_blank">@Chalarangelo</a>. Source code licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>.</p><p>Icons provided by <a href="https://feathericons.com/" target="_blank">Feather</a>. Search powered by <a href="http://fusejs.io/" target="_blank">Fuse.js</a>.</p></footer></main>`;
var documentationFragments = docFragments.map(f => buildFragment(f)).join('<br/>');
var documentationLinks = docFragments.map(f => buildLink(f)).join('');
var documentationSearch = `<script>
// Search script
var docs= [${docFragments.map(f => stripData(f))}];
var options = {threshold:0.4, keys:["keys"]};
var fuse = new Fuse(docs,options);
function search(){
var query = document.getElementById('search-bar').value;
if(query.length){
var result = fuse.search(query);
if(result.length){
var resIds = result.map(function(item){
return ':not(#link-to-'+item.id+')';
}).join('');
document.getElementById('search-style').innerHTML = '#no-results{display:none;}#nav-drawer a'+resIds+'{display:none;}';
}
else {
document.getElementById('search-style').innerHTML = '#nav-drawer a{display:none;}#no-results{display:block;}';
}
}
else{
document.getElementById('search-style').innerHTML = '#no-results{display:none;}';
}
}
// Codepen prefill script
var el = document.querySelectorAll('.prefiller-example > pre');
el.forEach(e => e.innerHTML = '<form action="https://codepen.io/pen/define" method="POST" target="_blank" class="codepen-form">' +
'<input type="hidden" name="data" value=\\\'' + JSON.stringify({
html : e.innerText,
css_external : ${frameworkUrl}
}).replace(/"/g, "&quot;")
.replace(/'/g, "&apos;") + '\\\'>' +
'<input type="image" class="codepen-link" src="data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2224%22%20height%3D%2224%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22%23424242%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%3E%3Cpolygon%20points%3D%2212%202%2022%208.5%2022%2015.5%2012%2022%202%2015.5%202%208.5%2012%202%22%3E%3C%2Fpolygon%3E%3Cline%20x1%3D%2212%22%20y1%3D%2222%22%20x2%3D%2212%22%20y2%3D%2215.5%22%3E%3C%2Fline%3E%3Cpolyline%20points%3D%2222%208.5%2012%2015.5%202%208.5%22%3E%3C%2Fpolyline%3E%3Cpolyline%20points%3D%222%2015.5%2012%208.5%2022%2015.5%22%3E%3C%2Fpolyline%3E%3Cline%20x1%3D%2212%22%20y1%3D%222%22%20x2%3D%2212%22%20y2%3D%228.5%22%3E%3C%2Fline%3E%3C%2Fsvg%3E" width="40" height="40" value="Open in Codepen">' +
'</form>' + e.innerHTML);
</script>
<style id="search-style">#no-results{display:none;}</style>`;
function buildFragment(fragment){
var fragmentHtml = `<div id="${fragment.id}" class="card fluid">
<h2 class="section double-padded">${fragment.title}</h2>
${fragment.id === 'icons'?FEATHER_BANNER:''}
<div class="section">${fragment.description}</div>
${fragment.example?`<div class="section"><h3>Example</h3>${fragment.example}</div>`:''}
${fragment.samples.length?`<div class="section double-padded prefiller-example"><h3>Sample code</h3>${fragment.samples.join('')}</div>`:''}
${fragment.modifiers.length?
`<div class="section double-padded prefiller-example"><h3>Modifiers</h3>
${fragment.modifiers.map(m => `<h4>${m.title}</h4>${m.description}${m.example?`<h5>Example</h5>${m.example}`:''}${m.samples.length?`<h5>Sample code</h5>${m.samples.join('')}`:''}`).join('<br/>')}</div>`:''}
${fragment.dos.length||fragment.donts.length?
`<div class="section double-padded"><h3>Best practices</h3>${[fragment.dos.map(d => `<div class="row dodos"><div class="col-sm-12 col-md-6">${d.sample}</div><div class="col-sm-12 col-md-6"><p><mark class="do">Do:</mark>&nbsp;${d.description}</p></div></div>`).join('<br/>'),fragment.donts.map(d => `<div class="row dodos"><div class="col-sm-12 col-md-6">${d.sample}</div><div class="col-sm-12 col-md-6"><p><mark class="dont">Don't:</mark>&nbsp;${d.description}</p></div></div>`).join('<br/>')].join('')}</div>`
:''}
${fragment.notes.length?`<div class="section double-padded"><h3>Notes</h3><ul>${fragment.notes.map(n => `<li>${n}</li>`).join('')}</ul></div>`:''}
${fragment.customization.length?`<div class="section double-padded"><h3>Customization</h3><ul>${fragment.customization.map(s => `<li>${s}</li>`).join('')}</ul></div>`:''}
</div>`;
return fragmentHtml;
}
function buildLink(fragment){
return `<a href="#${fragment.id}" id="link-to-${fragment.id}">${fragment.title}</a>`;
}
function stripData(fragment){
return `{id: "${fragment.id}", keys: [${fragment.keywords.map(k=>`"${k}"`)}] }`;
}
fs.writeFile(docOutputPath,
`${documentStart}${appShellStart}
${appSidebarStart}${documentationLinks}${appSidebarEnd}
${mainStart}${documentationFragments}${mainEnd}
${appShellEnd}
${documentationSearch}
${documentEnd}`,
function(err) { if(err) return console.log(err); console.log("Documentation file generated!"); }
);
var fs = require('fs');
var version = require('./vinf'); // Gets version info.
var frameworkUrl = `"https://cdnjs.cloudflare.com/ajax/libs/mini.css/${version.version.slice(1)}/mini-default.css"`;
// INDEX
var indexHtml = `<!DOCTYPE html>
<html lang="en">
<head>
<link href="https://fonts.googleapis.com/css?family=Inconsolata:400,700|Poppins:400,400i,500,700,700i&amp;subset=latin-ext" rel="stylesheet">
<link rel="stylesheet" href="./style.min.css">
<title>mini.css - Minimal, responsive, style-agnostic CSS framework</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites.">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, toolkit">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
</head>
<body>
<div class="index-splash">
<div class="index-splash-image no-filter"></div>
<div class="index-splash-image"></div>
<h1 class="splash">mini<small>.css</small></h1>
<p class="splash">minimal, responsive, style-agnostic <br>CSS framework</p>
<p id="version-info">${version.version}</p>
<a class="button splash" href="docs">Get started</a>
</div>
<header class="row sticky">
<span class="col-md-1 col-lg-2"></span>
<span class="logo col-sm-3 col-md">mini.css</span>
<a class="button col-sm col-md" href="docs">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" style="height: 20px; vertical-align: text-top;"><path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"></path><polyline points="14 2 14 8 20 8"></polyline><line x1="16" y1="13" x2="8" y2="13"></line><line x1="16" y1="17" x2="8" y2="17"></line><polyline points="10 9 9 9 8 9"></polyline></svg>
<span>&nbsp;Docs</span></a>
<a class="button col-sm col-md" href="https://github.com/Chalarangelo/mini.css" target="_blank">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" style="height: 20px; vertical-align: text-top;"><path d="M9 19c-5 1.5-5-2.5-7-3m14 6v-3.87a3.37 3.37 0 0 0-.94-2.61c3.14-.35 6.44-1.54 6.44-7A5.44 5.44 0 0 0 20 4.77 5.07 5.07 0 0 0 19.91 1S18.73.65 16 2.48a13.38 13.38 0 0 0-7 0C6.27.65 5.09 1 5.09 1A5.07 5.07 0 0 0 5 4.77a5.44 5.44 0 0 0-1.5 3.78c0 5.42 3.3 6.61 6.44 7A3.37 3.37 0 0 0 9 18.13V22"></path></svg>
<span>&nbsp;Github</span></a>
<a class="button col-sm col-md" href="#">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" style="height: 20px; vertical-align: text-top;"><path d="M20 14.66V20a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h5.34"></path><polygon points="18 2 22 6 12 16 8 16 8 12 18 2"></polygon></svg>
<span>&nbsp;Flavors</span></a>
<span class="col-md-1 col-lg-2"></span>
</header>
<div class="row padded">
<div class="col-sm-12 col-md-10 col-md-offset-1 col-lg-8 col-lg-offset-2">
<img src="./responsive.svg" class="feature-image">
<h2 class="feature-header">Fast and Responsive</h2><br>
<p>Want to build websites that look beautiful on any and all devices, but also load fast on mobile connections? Then <strong>mini.css</strong> is the right tool for you! Its tiny size (under 10KB gzipped), along with its <strong>responsive grid</strong> and modern components ensures that all your users are satisfied and can access your website anytime, anywhere. Bridging the gap between fully-featured frameworks (e.g. Bootstrap and Semantic UI) and micro frameworks (e.g. Milligram and Pure.CSS), <strong>mini.css</strong> packs a lot of features in a small package, while it relies solely on CSS, meaning you do not have to worry about any conflicts with other Javascript libraries you might be using.</p>
</div>
</div>
<div class="row padded alt-back">
<div class="col-sm-12 col-md-10 col-md-offset-1 col-lg-8 col-lg-offset-2">
<img src="./tailored.svg" class="feature-image">
<h2 class="feature-header">Tailored to Your Needs</h2><br>
<p>Creating a CSS framework that caters to everyone's needs is no easy task, but <strong>mini.css</strong> manages to rise to the occasion by providing extensive and coherent documentation in combination with templates, examples and semantic HTML5 markup. Modern UX patterns and accessibility guidelines are well-documented and can be used out of the box, using one of the unique <strong>flavors</strong> that the framework provides. If you still want more, you can create your own custom flavor or tweak an existing one just by opening its CSS file and changing a few custom properties. It's that simple! </p>
</div>
</div>
<div class="row padded primary-section">
<div class="col-sm-12 col-md-10 col-md-offset-1 col-lg-8 col-lg-offset-2">
<h2 class="feature-header">Get started now!</h2><br>
<p>Head over to the <a href="docs">documentation</a> to learn how to get started using <strong>mini.css</strong>, as well as what flavors and components are availble and how to use them to create the website or web app you've always wanted. If you like the framework and want to support it, remember to to star it on Github. It means a lot to us and it only takes a couple of seconds!</p>
<p style="text-align:center;"><a href="docs" class="button">Get started</a></p>
<a href="https://github.com/Chalarangelo/mini.css" target="_blank" class="centered">mini.css on Github</a>
</div>
</div>
<footer class="row"><div class="col-sm-12 col-md-10 col-md-offset-1 col-lg-8 col-lg-offset-2"><p style="text-align: justify;"><strong>mini.css</strong> was designed and built by <a href="https://github.com/Chalarangelo" target="_blank">@Chalarangelo</a>. Source code licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>.</p><p>Icons provided by <a href="https://feathericons.com/" target="_blank">Feather</a>. Photo by <a href="https://unsplash.com/photos/vjMgqUkS8q8" target="_blank">Christopher Gower</a> on <a href="https://unsplash.com" target="_blank">Unsplash</a>.</p></div></footer>
</body>
</html>`;
var indexOutputPath = './docs/v3/index.html'; // This path is relative to package.json.
fs.writeFile(indexOutputPath,
`${indexHtml}`,
function(err) { if(err) return console.log(err); console.log("Index file generated!"); }
);
// DOCUMENTATION
var docFragments = require('./doc-fragments/docFragments'); // Gets all document fragments as a list.
var docOutputPath = './docs/v3/docs.html'; // This path is relative to package.json.
const FEATHER_BANNER = `<a href="https://feathericons.com/" class="section double-padded" id="feather-banner" target="_blank" rel="noopener"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="#f8f8f8" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M20.24 12.24a6 6 0 0 0-8.49-8.49L5 10.5V19h8.5z"></path><line x1="16" y1="8" x2="2" y2="22"></line><line x1="17" y1="15" x2="9" y2="15"></line></svg>&nbsp;Powered by Feather</a>`;
var documentStart = `<!DOCTYPE html><html lang="en"><head>
<link href="https://fonts.googleapis.com/css?family=Inconsolata:400,700|Poppins:400,400i,500,700,700i&amp;subset=latin-ext" rel="stylesheet">
<link rel="stylesheet" href="./style.min.css">
<script src="https://cdnjs.cloudflare.com/ajax/libs/fuse.js/3.0.4/fuse.min.js"></script>
<title>mini.css - Docs</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites.">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, toolkit">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
</head><body>`;
var documentEnd = `</body></html>`;
var appShellStart = `<div id="root"><header class="row">
<span class="logo col-sm-3 col-md">mini.css</span>
<a class="button col-sm col-md" href="https://github.com/Chalarangelo/mini.css" target="_blank">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" style="height: 20px; vertical-align: text-top;"><path d="M9 19c-5 1.5-5-2.5-7-3m14 6v-3.87a3.37 3.37 0 0 0-.94-2.61c3.14-.35 6.44-1.54 6.44-7A5.44 5.44 0 0 0 20 4.77 5.07 5.07 0 0 0 19.91 1S18.73.65 16 2.48a13.38 13.38 0 0 0-7 0C6.27.65 5.09 1 5.09 1A5.07 5.07 0 0 0 5 4.77a5.44 5.44 0 0 0-1.5 3.78c0 5.42 3.3 6.61 6.44 7A3.37 3.37 0 0 0 9 18.13V22"></path></svg>
<span>&nbsp;Github</span></a>
<a class="button col-sm col-md" href="#">
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" style="height: 20px; vertical-align: text-top;"><path d="M20 14.66V20a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h5.34"></path><polygon points="18 2 22 6 12 16 8 16 8 12 18 2"></polygon></svg>
<span>&nbsp;Flavors</span></a>
<label for="doc-drawer-checkbox" class="button drawer-toggle col-sm"></label>
</header>
<div class="row" id="doc-wrapper">`;
var appShellEnd = `</div></div>`;
var appSidebarStart = `<input id="doc-drawer-checkbox" class="drawer" value="on" type="checkbox">
<nav class="col-md-4 col-lg-3" id="nav-drawer"><h3>Menu</h3><label for="doc-drawer-checkbox" class="button drawer-close"></label><div><input style="width: 100%; margin: 0px;" placeholder="Search..." type="search" id="search-bar" oninput="search()"></div>`;
var appSidebarEnd = `<span id="no-results">No results found</span></nav>`;
var mainStart = `<main class="col-sm-12 col-md-8 col-lg-9" id="doc-content">`;
var mainEnd = `<footer><p><strong>mini.css</strong> was designed and built by <a href="https://github.com/Chalarangelo" target="_blank">@Chalarangelo</a>. Source code licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>.</p><p>Icons provided by <a href="https://feathericons.com/" target="_blank">Feather</a>. Search powered by <a href="http://fusejs.io/" target="_blank">Fuse.js</a>.</p></footer></main>`;
var documentationFragments = docFragments.map(f => buildFragment(f)).join('<br/>');
var documentationLinks = docFragments.map(f => buildLink(f)).join('');
var documentationSearch = `<script>
// Search script
var docs= [${docFragments.map(f => stripData(f))}];
var options = {threshold:0.4, keys:["keys"]};
var fuse = new Fuse(docs,options);
function search(){
var query = document.getElementById('search-bar').value;
if(query.length){
var result = fuse.search(query);
if(result.length){
var resIds = result.map(function(item){
return ':not(#link-to-'+item.id+')';
}).join('');
document.getElementById('search-style').innerHTML = '#no-results{display:none;}#nav-drawer a'+resIds+'{display:none;}';
}
else {
document.getElementById('search-style').innerHTML = '#nav-drawer a{display:none;}#no-results{display:block;}';
}
}
else{
document.getElementById('search-style').innerHTML = '#no-results{display:none;}';
}
}
// Codepen prefill script
var el = document.querySelectorAll('.prefiller-example > pre');
el.forEach(e => e.innerHTML = '<form action="https://codepen.io/pen/define" method="POST" target="_blank" class="codepen-form">' +
'<input type="hidden" name="data" value=\\\'' + JSON.stringify({
html : e.innerText,
css_external : ${frameworkUrl}
}).replace(/"/g, "&quot;")
.replace(/'/g, "&apos;") + '\\\'>' +
'<input type="image" class="codepen-link" src="data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2224%22%20height%3D%2224%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22%23424242%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%3E%3Cpolygon%20points%3D%2212%202%2022%208.5%2022%2015.5%2012%2022%202%2015.5%202%208.5%2012%202%22%3E%3C%2Fpolygon%3E%3Cline%20x1%3D%2212%22%20y1%3D%2222%22%20x2%3D%2212%22%20y2%3D%2215.5%22%3E%3C%2Fline%3E%3Cpolyline%20points%3D%2222%208.5%2012%2015.5%202%208.5%22%3E%3C%2Fpolyline%3E%3Cpolyline%20points%3D%222%2015.5%2012%208.5%2022%2015.5%22%3E%3C%2Fpolyline%3E%3Cline%20x1%3D%2212%22%20y1%3D%222%22%20x2%3D%2212%22%20y2%3D%228.5%22%3E%3C%2Fline%3E%3C%2Fsvg%3E" width="40" height="40" value="Open in Codepen">' +
'</form>' + e.innerHTML);
</script>
<style id="search-style">#no-results{display:none;}</style>`;
function buildFragment(fragment){
var fragmentHtml = `<div id="${fragment.id}" class="card fluid">
<h2 class="section double-padded">${fragment.title}</h2>
${fragment.id === 'icons'?FEATHER_BANNER:''}
<div class="section">${fragment.description}</div>
${fragment.example?`<div class="section"><h3>Example</h3>${fragment.example}</div>`:''}
${fragment.samples.length?`<div class="section double-padded prefiller-example"><h3>Sample code</h3>${fragment.samples.join('')}</div>`:''}
${fragment.modifiers.length?
`<div class="section double-padded prefiller-example"><h3>Modifiers</h3>
${fragment.modifiers.map(m => `<h4>${m.title}</h4>${m.description}${m.example?`<h5>Example</h5>${m.example}`:''}${m.samples.length?`<h5>Sample code</h5>${m.samples.join('')}`:''}`).join('<br/>')}</div>`:''}
${fragment.dos.length||fragment.donts.length?
`<div class="section double-padded"><h3>Best practices</h3>${[fragment.dos.map(d => `<div class="row dodos"><div class="col-sm-12 col-md-6">${d.sample}</div><div class="col-sm-12 col-md-6"><p><mark class="do">Do:</mark>&nbsp;${d.description}</p></div></div>`).join('<br/>'),fragment.donts.map(d => `<div class="row dodos"><div class="col-sm-12 col-md-6">${d.sample}</div><div class="col-sm-12 col-md-6"><p><mark class="dont">Don't:</mark>&nbsp;${d.description}</p></div></div>`).join('<br/>')].join('')}</div>`
:''}
${fragment.notes.length?`<div class="section double-padded"><h3>Notes</h3><ul>${fragment.notes.map(n => `<li>${n}</li>`).join('')}</ul></div>`:''}
${fragment.customization.length?`<div class="section double-padded"><h3>Customization</h3><ul>${fragment.customization.map(s => `<li>${s}</li>`).join('')}</ul></div>`:''}
</div>`;
return fragmentHtml;
}
function buildLink(fragment){
return `<a href="#${fragment.id}" id="link-to-${fragment.id}">${fragment.title}</a>`;
}
function stripData(fragment){
return `{id: "${fragment.id}", keys: [${fragment.keywords.map(k=>`"${k}"`)}] }`;
}
fs.writeFile(docOutputPath,
`${documentStart}${appShellStart}
${appSidebarStart}${documentationLinks}${appSidebarEnd}
${mainStart}${documentationFragments}${mainEnd}
${appShellEnd}
${documentationSearch}
${documentEnd}`,
function(err) { if(err) return console.log(err); console.log("Documentation file generated!"); }
);

View file

@ -1,126 +1,126 @@
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="../mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<title>mini.css - Customization</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, customization, flavor ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="../page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="../favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-centered { text-align: center; } .box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;} .box-colored.red { background: #e53935; }
.box-centered > .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto; } [class^='col-'] .card.fluid { margin: 2px 0 20px; }
[class^='fore-'] { font-family: monospace, monospace;} .fore-primary { color: #0d47a1;} .fore-secondary { color: #b71c1c;} .fore-tertiary { color: #1b5e20;}
.col-sm-12.col-sm-last.col-lg-4.col-lg-normal {box-sizing: border-box; border-right: 1px solid #c9c9c9;}
@media (max-width: 1279px){.col-sm-12.col-sm-last.col-lg-4.col-lg-normal {border: 0;border-top: 1px solid #c9c9c9;}}
.box-colored.green { background: #689f38; } .do {border-top: 15px solid #689f38;padding-top: 10px;} .dont {border-top: 15px solid #e53935;padding-top: 10px;}
.box-colored { color: #f5f5f5;} @media (max-width: 767px){.container {padding: 0.25rem !important;}.col-sm-12.col-md-8.col-lg-10{padding: 0 !important;}}
@media screen and (min-width: 768px) { .drawer { margin-top: 4px;}}
</style>
</head>
<body>
<header class="sticky">
<a href="../index" class="logo"><span id="header-logo">m</span></a>
<label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="../index" class="button hidden-sm">Introduction</a> <a href="../modules" class="button hidden-sm">Modules</a>
<a href="../flavors" class="button hidden-sm">Flavors</a> <a href="../templates" class="button hidden-sm">Templates</a>
<a href="../customization" class="button hidden-sm">Customization</a> <a href="../quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<div class="container" style="padding-left: 0.25rem;">
<div class="row"> <input type="checkbox" id="navigation-toggle"> <nav class="drawer col-md-4 col-lg-2">
<label class="close" for="navigation-toggle"></label>
<a href="../index"><h4 style="margin-left: 0;">Introduction</h4></a>
<a href="../modules"><h4 style="margin-left: 0;">Modules</h4></a>
<a href="../flavors"><h4 style="margin-left: 0;">Flavors</h4></a>
<a href="../templates"><h4 style="margin-left: 0;">Templates</h4></a>
<h4 style="margin-left: 0;">Customization</h4> <a href="core#core-title">Core</a>
<a href="core#typography-headings" class="sublink-1">Typography &amp; headings</a>
<a href="core#common-elements" class="sublink-1">Common elements &amp; fixes</a>
<br/> <a href="grid#grid-title">Grid</a>
<a href="grid#classes-breakpoints" class="sublink-1">Classes &amp; breakpoints</a>
<br/> <a href="input_control#input-control-title">Input Control</a>
<a href="input_control#forms-input" class="sublink-1">Forms &amp; input</a> <a href="input_control#checkbox-radio" class="sublink-1">Checkboxes &amp; radio buttons</a> <a href="input_control#switch" class="sublink-1">Switches</a>
<a href="input_control#buttons" class="sublink-1">Buttons &amp; button groups</a> <a href="input_control#button-mixins" class="sublink-1">Button mixins</a> <a href="input_control#switch-mixins" class="sublink-1">Switch mixins</a>
<br/> <a href="navigation#navigation-title">Navigation</a>
<a href="navigation#header" class="sublink-1">Header</a> <a href="navigation#navigation-bar" class="sublink-1">Navigation bar</a>
<a href="navigation#drawer" class="sublink-1">Drawer</a> <a href="navigation#footer" class="sublink-1">Footer</a>
<br/> <a href="table#table-title">Table</a>
<a href="table#table-styling" class="sublink-1">Table styling</a>
<br/> <a href="card#card-title">Card</a>
<a href="card#cards-sections" class="sublink-1">Cards and sections</a> <a href="card#card-mixins" class="sublink-1">Card mixins</a>
<br/> <a href="tab#tab-title">Tab</a>
<a href="tab#tab-styling" class="sublink-1">Tab styling</a>
<br/> <a href="contextual#contextual-title">Contextual</a>
<a href="contextual#text-highlighting" class="sublink-1">Text highlighting</a> <a href="contextual#toasts" class="sublink-1">Toasts</a>
<a href="contextual#tooltips" class="sublink-1">Tooltips</a> <a href="contextual#modals" class="sublink-1">Modals</a>
<a href="contextual#highlighting-mixins" class="sublink-1">Text highlighting mixins</a>
<a href="contextual#toast-mixins" class="sublink-1">Toast mixins</a> <a href="contextual#tooltip-mixins" class="sublink-1">Tooltip mixins</a>
<br/> <a href="progress#progress-title">Progress</a>
<a href="progress#progress-bar" class="sublink-1">Progress bar</a> <a href="progress#donut-spinner" class="sublink-1">Donut spinner</a>
<a href="progress#progress-mixins" class="sublink-1">Progress bar mixins</a> <a href="progress#spinner-mixins" class="sublink-1">Donut spinner mixins</a>
<br/> <a href="utility#utility-title">Utility</a>
<a href="utility#visibility-legacy" class="sublink-1">Visibility helpers &amp; legacy features</a> <a href="utility#breadcrumbs" class="sublink-1">Breadcrumbs</a>
<a href="utility#close-icon" class="sublink-1">Close icon</a>
<a href="utility#borders-shadows-mixins" class="sublink-1">Generic border &amp; shadow mixins</a>
<a href="utility#responsive-sizing-mixins" class="sublink-1">Responsive sizing &amp; spacing mixins</a>
<a href="utility#responsive-visibility-mixins" class="sublink-1">Responsive visibility helper mixins</a>
<a href="../quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<div class="col-sm-12 col-md-8 col-lg-10"><main>
<div class="row" style="padding-top: 40px;">
<div class="col-sm-12">
<h1>Customization</h1>
<p style="text-align:justify"><strong>mini.css</strong> is built in such a way that customization is really simple. You could try out one of the <a href="../flavors">pre-defined flavors</a>, if you want, in order to get used to the framework and build something quickly and easily. However, many projects require custom styles and color palettes, which is when you need to get your hands dirty and start creating your own flavor by customizing an existing one and using mixins and variables to create your own, unique style for your brand or product. This page, along with the rest of the <strong>Customization</strong> section is aimed at developers who want to tweak the code provided with <strong>mini.css</strong> to create their own flavors for their projects, as well as active maintainers of the framework and people who just want to understand the inner workings of the codebase.</p>
<p style="text-align:justify">Use the menu to quickly jump to the documentation of any module that you want to check out. We strongly recommend, however, that you read the general information provided in this page before you start exploring the modules' code, especially if you are not familiar with the way <strong>mini.css</strong> is structured.</p><br>
</div>
<div class="col-sm-12">
<br/>
<h2>Introduction &amp; basics</h2>
<p style="text-align:justify"><strong>mini.css</strong> is written using <a href="http://sass-lang.com/">Sass</a>, a very popular CSS preprocessor. We use Sass to do four things:</p>
<ul>
<li>Make the code modular</li>
<li>Create variables that can be changed on the fly</li>
<li>Optimize the code</li>
<li>Create reusable mixins</li>
</ul><br/>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<h3>Modules &amp; file structure</h3>
<p style="text-align:justify">At the heart of <strong>mini.css</strong> are modules - groups of classes and styles that aim to solve one set of needs. There are 10 modules in <strong>mini.css</strong>, which have been already written for you. All of the modules are built using partial files, named <code>_module_name.scss</code> and placed in the <code>src/mini</code> folder. You can edit any of the modules' code and/or add your own modules, following the same structure. The only thing you need to remember to do, in order to add your module to your flavor, is to add an <code>@import</code> statement after all the required variable declarations towards the bottom of your flavor file and it will be compiled along with the rest of <strong>mini.css</strong>. Similarly, to disable a module, just comment out its <code>@import</code> statement from the flavor file.</p><br/>
</div>
<div class="col-sm-12">
<h3>Variables</h3>
<p style="text-align:justify">Everything in <strong>mini.css</strong> is based on Sass variables. We try to make our variable names as descriptive as possible, usually using names like <code>$block-element-property-name</code>, but some things might vary a little bit. Changing the values of variables should be reasonably easy, simply navigate to the <code>src/flavors/flavor-name.scss</code> file for a pre-defined flavor and you will see a list of variables that you can tweak. Change the values as you see fit and your finalized stylesheet will reflect the changes you have made. We did our best to make everything as customizable as possible, so that different people can build entirely different flavors using the same building blocks.</p><br/>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<h3>Code optimization</h3>
<p style="text-align:justify">Building <strong>mini.css</strong> was no small task. Making it lightweight and customizable made things even harder, because these two things don't go well together most of the time. What we did was put more of the load on the preprocessor, instead of the final file. In order to accomplish this, we optimized as much of the code as possible, using conditions, flags and other tricks, so that compiling a flavor file might take one second longer, but loading won't. If you add any code to a flavor yourself, remember not only to make it customizable, but also to optimize it as best as possible.</p><br/>
</div>
<div class="col-sm-12">
<h3>Mixins</h3>
<p style="text-align:justify">A lot of elements and components can be styled in many ways and most of the time we want a few styles to be available, without having to rewrite everything. We utilized the <code>@mixin</code> directive of Sass wherever we could to make it possible for you to easily create styles for pre-existing components and elements without having to tweak the base code for said elements or components. Each module's mixins can be found in the corresponding <code>_module_name_mixins.scss</code> file in the <code>src/mini</code> folder. To use a mixin, simply <code>@import</code> its file and then <code>@include</code> the mixin itself, passing values to at least its mandatory parameters. We recommend you write mixins wherever possible, if you create any new modules for <strong>mini.css</strong>.</p><br/>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<p style="text-align:justify">To read more about the inner workings of <strong>mini.css</strong>, please choose a module from the menu to view its documentation.</p>
</div>
</div>
<div class="row box-centered"><div class="col-sm-12"></div></div>
</main></div></div></div>
<footer style="text-align:justify"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="../mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<title>mini.css - Customization</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, customization, flavor ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="../page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="../favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-centered { text-align: center; } .box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;} .box-colored.red { background: #e53935; }
.box-centered > .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto; } [class^='col-'] .card.fluid { margin: 2px 0 20px; }
[class^='fore-'] { font-family: monospace, monospace;} .fore-primary { color: #0d47a1;} .fore-secondary { color: #b71c1c;} .fore-tertiary { color: #1b5e20;}
.col-sm-12.col-sm-last.col-lg-4.col-lg-normal {box-sizing: border-box; border-right: 1px solid #c9c9c9;}
@media (max-width: 1279px){.col-sm-12.col-sm-last.col-lg-4.col-lg-normal {border: 0;border-top: 1px solid #c9c9c9;}}
.box-colored.green { background: #689f38; } .do {border-top: 15px solid #689f38;padding-top: 10px;} .dont {border-top: 15px solid #e53935;padding-top: 10px;}
.box-colored { color: #f5f5f5;} @media (max-width: 767px){.container {padding: 0.25rem !important;}.col-sm-12.col-md-8.col-lg-10{padding: 0 !important;}}
@media screen and (min-width: 768px) { .drawer { margin-top: 4px;}}
</style>
</head>
<body>
<header class="sticky">
<a href="../index" class="logo"><span id="header-logo">m</span></a>
<label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="../index" class="button hidden-sm">Introduction</a> <a href="../modules" class="button hidden-sm">Modules</a>
<a href="../flavors" class="button hidden-sm">Flavors</a> <a href="../templates" class="button hidden-sm">Templates</a>
<a href="../customization" class="button hidden-sm">Customization</a> <a href="../quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<div class="container" style="padding-left: 0.25rem;">
<div class="row"> <input type="checkbox" id="navigation-toggle"> <nav class="drawer col-md-4 col-lg-2">
<label class="close" for="navigation-toggle"></label>
<a href="../index"><h4 style="margin-left: 0;">Introduction</h4></a>
<a href="../modules"><h4 style="margin-left: 0;">Modules</h4></a>
<a href="../flavors"><h4 style="margin-left: 0;">Flavors</h4></a>
<a href="../templates"><h4 style="margin-left: 0;">Templates</h4></a>
<h4 style="margin-left: 0;">Customization</h4> <a href="core#core-title">Core</a>
<a href="core#typography-headings" class="sublink-1">Typography &amp; headings</a>
<a href="core#common-elements" class="sublink-1">Common elements &amp; fixes</a>
<br/> <a href="grid#grid-title">Grid</a>
<a href="grid#classes-breakpoints" class="sublink-1">Classes &amp; breakpoints</a>
<br/> <a href="input_control#input-control-title">Input Control</a>
<a href="input_control#forms-input" class="sublink-1">Forms &amp; input</a> <a href="input_control#checkbox-radio" class="sublink-1">Checkboxes &amp; radio buttons</a> <a href="input_control#switch" class="sublink-1">Switches</a>
<a href="input_control#buttons" class="sublink-1">Buttons &amp; button groups</a> <a href="input_control#button-mixins" class="sublink-1">Button mixins</a> <a href="input_control#switch-mixins" class="sublink-1">Switch mixins</a>
<br/> <a href="navigation#navigation-title">Navigation</a>
<a href="navigation#header" class="sublink-1">Header</a> <a href="navigation#navigation-bar" class="sublink-1">Navigation bar</a>
<a href="navigation#drawer" class="sublink-1">Drawer</a> <a href="navigation#footer" class="sublink-1">Footer</a>
<br/> <a href="table#table-title">Table</a>
<a href="table#table-styling" class="sublink-1">Table styling</a>
<br/> <a href="card#card-title">Card</a>
<a href="card#cards-sections" class="sublink-1">Cards and sections</a> <a href="card#card-mixins" class="sublink-1">Card mixins</a>
<br/> <a href="tab#tab-title">Tab</a>
<a href="tab#tab-styling" class="sublink-1">Tab styling</a>
<br/> <a href="contextual#contextual-title">Contextual</a>
<a href="contextual#text-highlighting" class="sublink-1">Text highlighting</a> <a href="contextual#toasts" class="sublink-1">Toasts</a>
<a href="contextual#tooltips" class="sublink-1">Tooltips</a> <a href="contextual#modals" class="sublink-1">Modals</a>
<a href="contextual#highlighting-mixins" class="sublink-1">Text highlighting mixins</a>
<a href="contextual#toast-mixins" class="sublink-1">Toast mixins</a> <a href="contextual#tooltip-mixins" class="sublink-1">Tooltip mixins</a>
<br/> <a href="progress#progress-title">Progress</a>
<a href="progress#progress-bar" class="sublink-1">Progress bar</a> <a href="progress#donut-spinner" class="sublink-1">Donut spinner</a>
<a href="progress#progress-mixins" class="sublink-1">Progress bar mixins</a> <a href="progress#spinner-mixins" class="sublink-1">Donut spinner mixins</a>
<br/> <a href="utility#utility-title">Utility</a>
<a href="utility#visibility-legacy" class="sublink-1">Visibility helpers &amp; legacy features</a> <a href="utility#breadcrumbs" class="sublink-1">Breadcrumbs</a>
<a href="utility#close-icon" class="sublink-1">Close icon</a>
<a href="utility#borders-shadows-mixins" class="sublink-1">Generic border &amp; shadow mixins</a>
<a href="utility#responsive-sizing-mixins" class="sublink-1">Responsive sizing &amp; spacing mixins</a>
<a href="utility#responsive-visibility-mixins" class="sublink-1">Responsive visibility helper mixins</a>
<a href="../quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<div class="col-sm-12 col-md-8 col-lg-10"><main>
<div class="row" style="padding-top: 40px;">
<div class="col-sm-12">
<h1>Customization</h1>
<p style="text-align:justify"><strong>mini.css</strong> is built in such a way that customization is really simple. You could try out one of the <a href="../flavors">pre-defined flavors</a>, if you want, in order to get used to the framework and build something quickly and easily. However, many projects require custom styles and color palettes, which is when you need to get your hands dirty and start creating your own flavor by customizing an existing one and using mixins and variables to create your own, unique style for your brand or product. This page, along with the rest of the <strong>Customization</strong> section is aimed at developers who want to tweak the code provided with <strong>mini.css</strong> to create their own flavors for their projects, as well as active maintainers of the framework and people who just want to understand the inner workings of the codebase.</p>
<p style="text-align:justify">Use the menu to quickly jump to the documentation of any module that you want to check out. We strongly recommend, however, that you read the general information provided in this page before you start exploring the modules' code, especially if you are not familiar with the way <strong>mini.css</strong> is structured.</p><br>
</div>
<div class="col-sm-12">
<br/>
<h2>Introduction &amp; basics</h2>
<p style="text-align:justify"><strong>mini.css</strong> is written using <a href="http://sass-lang.com/">Sass</a>, a very popular CSS preprocessor. We use Sass to do four things:</p>
<ul>
<li>Make the code modular</li>
<li>Create variables that can be changed on the fly</li>
<li>Optimize the code</li>
<li>Create reusable mixins</li>
</ul><br/>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<h3>Modules &amp; file structure</h3>
<p style="text-align:justify">At the heart of <strong>mini.css</strong> are modules - groups of classes and styles that aim to solve one set of needs. There are 10 modules in <strong>mini.css</strong>, which have been already written for you. All of the modules are built using partial files, named <code>_module_name.scss</code> and placed in the <code>src/mini</code> folder. You can edit any of the modules' code and/or add your own modules, following the same structure. The only thing you need to remember to do, in order to add your module to your flavor, is to add an <code>@import</code> statement after all the required variable declarations towards the bottom of your flavor file and it will be compiled along with the rest of <strong>mini.css</strong>. Similarly, to disable a module, just comment out its <code>@import</code> statement from the flavor file.</p><br/>
</div>
<div class="col-sm-12">
<h3>Variables</h3>
<p style="text-align:justify">Everything in <strong>mini.css</strong> is based on Sass variables. We try to make our variable names as descriptive as possible, usually using names like <code>$block-element-property-name</code>, but some things might vary a little bit. Changing the values of variables should be reasonably easy, simply navigate to the <code>src/flavors/flavor-name.scss</code> file for a pre-defined flavor and you will see a list of variables that you can tweak. Change the values as you see fit and your finalized stylesheet will reflect the changes you have made. We did our best to make everything as customizable as possible, so that different people can build entirely different flavors using the same building blocks.</p><br/>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<h3>Code optimization</h3>
<p style="text-align:justify">Building <strong>mini.css</strong> was no small task. Making it lightweight and customizable made things even harder, because these two things don't go well together most of the time. What we did was put more of the load on the preprocessor, instead of the final file. In order to accomplish this, we optimized as much of the code as possible, using conditions, flags and other tricks, so that compiling a flavor file might take one second longer, but loading won't. If you add any code to a flavor yourself, remember not only to make it customizable, but also to optimize it as best as possible.</p><br/>
</div>
<div class="col-sm-12">
<h3>Mixins</h3>
<p style="text-align:justify">A lot of elements and components can be styled in many ways and most of the time we want a few styles to be available, without having to rewrite everything. We utilized the <code>@mixin</code> directive of Sass wherever we could to make it possible for you to easily create styles for pre-existing components and elements without having to tweak the base code for said elements or components. Each module's mixins can be found in the corresponding <code>_module_name_mixins.scss</code> file in the <code>src/mini</code> folder. To use a mixin, simply <code>@import</code> its file and then <code>@include</code> the mixin itself, passing values to at least its mandatory parameters. We recommend you write mixins wherever possible, if you create any new modules for <strong>mini.css</strong>.</p><br/>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<p style="text-align:justify">To read more about the inner workings of <strong>mini.css</strong>, please choose a module from the menu to view its documentation.</p>
</div>
</div>
<div class="row box-centered"><div class="col-sm-12"></div></div>
</main></div></div></div>
<footer style="text-align:justify"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>

View file

@ -1,58 +1,58 @@
module.exports = {
id: 'buttons',
title: 'Buttons',
keywords: [`button`, `input`, `reset`, `submit`, `link`, `a`, `label`, `primary`, `secondary`, `tertiary`, `aria`, `small`, `large`, `inverse`],
description: `<p>Buttons and button-like input elements have been styled by default to be consistent across browsers. You can also style other elements, such as links or form labels, to look like buttons, using the appropriate class (<code>.button</code>) or the <a href="https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/ARIA_Techniques/Using_the_button_role" target="_blank">button</a> role.</p>`,
example: `<button class="doc">Button</button><a href="#" class="button doc">Link</a><label class="button doc">Label</label><button disabled class="doc">Disabled</button>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;button&gt;</span>Button<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;button&quot;</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;Button&quot;</span><span class="highlight-a"> /&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;reset&quot;</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;Button&quot;</span><span class="highlight-a"> /&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;submit&quot;</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;Button&quot;</span><span class="highlight-a"> /&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;button&quot;</span><span class="highlight-a">&gt;</span>Link<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span> <span class="highlight-b">role</span>=<span class="highlight-c">&quot;button&quot;</span><span class="highlight-a">&gt;</span>Link<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;label</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;button&quot;</span><span class="highlight-a">&gt;</span>Label<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;label</span> <span class="highlight-b">role</span>=<span class="highlight-c">&quot;button&quot;</span><span class="highlight-a">&gt;</span>Label<span class="highlight-a">&lt;/label&gt;</span></span></pre>`],
notes: [
`It is recommended to use the button role instead of the provided class, if you want your custom buttons to be fully accessible.`
],
customization: [
`Text color for buttons can be changed by changing the value of the <code>--button-fore-color</code> variable.`,
`Background color for buttons can be changed by changing the value of the <code>--button-back-color</code> variable.`,
`Border color for buttons can be changed by changing the value of the <code>--button-border-color</code> variable.`,
`Background and border color for focused buttons can be changed by changing the values of the <code>--button-hover-back-color</code> and <code>--button-hover-border-color</code> variables respectively.`,
`You can customize the colors of different color variants by changing the values of the related variables in their respective definitions.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [
{
title : 'Color variants',
description: '<p>To make your buttons stand out, you can give them a primary (<code>.primary</code>), secondary (<code>.secondary</code>), tertiary (<code>.tertiary</code>) or inversed (<code>.inverse</code>) color palette.</p>',
example: `<button class="primary doc">Primary</button><button class="secondary doc">Secondary</button><button class="tertiary doc">Tertiary</button><button class="inverse doc">Inverse</button>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;button</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;primary&quot;</span><span class="highlight-a">&gt;</span>Primary<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;button</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;secondary&quot;</span><span class="highlight-a">&gt;</span>Secondary<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;button</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;tertiary&quot;</span><span class="highlight-a">&gt;</span>Tertiary<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;button</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;inverse&quot;</span><span class="highlight-a">&gt;</span>Inverse<span class="highlight-a">&lt;/button&gt;</span></span></pre>`]
},
{
title : 'Size variants',
description: `<p>You can make buttons smaller (<code>.small</code>) or larger (<code>.large</code>), by applying the appropriate modifier.</p>`,
example: `<button class="small doc">Small</button><button class="large doc">Large</button>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;button</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;small&quot;</span><span class="highlight-a">&gt;</span>Small<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;button</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;large&quot;</span><span class="highlight-a">&gt;</span>Large<span class="highlight-a">&lt;/button&gt;</span></span></pre>`]
}
],
dos: [{
description: `File upload inputs are not styled by default, due to inconsistencies in how browsers handle them. If you want them to look like other buttons, you can hide them and use a linked label.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;file&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;file-input&quot;</span> <span class="highlight-b">style</span>=<span class="highlight-c">&quot;display:none&quot;</span><span class="highlight-a"> /&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;file-input&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;button&quot;</span><span class="highlight-a">&gt;</span>Upload file<span class="highlight-a">&lt;/label&gt;</span></span></pre>`
}],
donts: [
{
description: `Avoid applying multiple modifiers of the same type on the same button.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;button</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;primary inverse&quot;</span><span class="highlight-a">&gt;</span>Button<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;button</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;small large&quot;</span><span class="highlight-a">&gt;</span>Button<span class="highlight-a">&lt;/button&gt;</span></span></pre>`
}
]
}
module.exports = {
id: 'buttons',
title: 'Buttons',
keywords: [`button`, `input`, `reset`, `submit`, `link`, `a`, `label`, `primary`, `secondary`, `tertiary`, `aria`, `small`, `large`, `inverse`],
description: `<p>Buttons and button-like input elements have been styled by default to be consistent across browsers. You can also style other elements, such as links or form labels, to look like buttons, using the appropriate class (<code>.button</code>) or the <a href="https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/ARIA_Techniques/Using_the_button_role" target="_blank">button</a> role.</p>`,
example: `<button class="doc">Button</button><a href="#" class="button doc">Link</a><label class="button doc">Label</label><button disabled class="doc">Disabled</button>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;button&gt;</span>Button<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;button&quot;</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;Button&quot;</span><span class="highlight-a"> /&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;reset&quot;</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;Button&quot;</span><span class="highlight-a"> /&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;submit&quot;</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;Button&quot;</span><span class="highlight-a"> /&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;button&quot;</span><span class="highlight-a">&gt;</span>Link<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span> <span class="highlight-b">role</span>=<span class="highlight-c">&quot;button&quot;</span><span class="highlight-a">&gt;</span>Link<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;label</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;button&quot;</span><span class="highlight-a">&gt;</span>Label<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;label</span> <span class="highlight-b">role</span>=<span class="highlight-c">&quot;button&quot;</span><span class="highlight-a">&gt;</span>Label<span class="highlight-a">&lt;/label&gt;</span></span></pre>`],
notes: [
`It is recommended to use the button role instead of the provided class, if you want your custom buttons to be fully accessible.`
],
customization: [
`Text color for buttons can be changed by changing the value of the <code>--button-fore-color</code> variable.`,
`Background color for buttons can be changed by changing the value of the <code>--button-back-color</code> variable.`,
`Border color for buttons can be changed by changing the value of the <code>--button-border-color</code> variable.`,
`Background and border color for focused buttons can be changed by changing the values of the <code>--button-hover-back-color</code> and <code>--button-hover-border-color</code> variables respectively.`,
`You can customize the colors of different color variants by changing the values of the related variables in their respective definitions.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [
{
title : 'Color variants',
description: '<p>To make your buttons stand out, you can give them a primary (<code>.primary</code>), secondary (<code>.secondary</code>), tertiary (<code>.tertiary</code>) or inversed (<code>.inverse</code>) color palette.</p>',
example: `<button class="primary doc">Primary</button><button class="secondary doc">Secondary</button><button class="tertiary doc">Tertiary</button><button class="inverse doc">Inverse</button>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;button</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;primary&quot;</span><span class="highlight-a">&gt;</span>Primary<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;button</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;secondary&quot;</span><span class="highlight-a">&gt;</span>Secondary<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;button</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;tertiary&quot;</span><span class="highlight-a">&gt;</span>Tertiary<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;button</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;inverse&quot;</span><span class="highlight-a">&gt;</span>Inverse<span class="highlight-a">&lt;/button&gt;</span></span></pre>`]
},
{
title : 'Size variants',
description: `<p>You can make buttons smaller (<code>.small</code>) or larger (<code>.large</code>), by applying the appropriate modifier.</p>`,
example: `<button class="small doc">Small</button><button class="large doc">Large</button>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;button</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;small&quot;</span><span class="highlight-a">&gt;</span>Small<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;button</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;large&quot;</span><span class="highlight-a">&gt;</span>Large<span class="highlight-a">&lt;/button&gt;</span></span></pre>`]
}
],
dos: [{
description: `File upload inputs are not styled by default, due to inconsistencies in how browsers handle them. If you want them to look like other buttons, you can hide them and use a linked label.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;file&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;file-input&quot;</span> <span class="highlight-b">style</span>=<span class="highlight-c">&quot;display:none&quot;</span><span class="highlight-a"> /&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;file-input&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;button&quot;</span><span class="highlight-a">&gt;</span>Upload file<span class="highlight-a">&lt;/label&gt;</span></span></pre>`
}],
donts: [
{
description: `Avoid applying multiple modifiers of the same type on the same button.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;button</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;primary inverse&quot;</span><span class="highlight-a">&gt;</span>Button<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;button</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;small large&quot;</span><span class="highlight-a">&gt;</span>Button<span class="highlight-a">&lt;/button&gt;</span></span></pre>`
}
]
}

View file

@ -1,85 +1,85 @@
module.exports = {
id: 'card-sections',
title: 'Card sections',
keywords: [`card`, `row`, `section`, `container`, `col`, `column`, `media`, `double-padded`, `dark`],
description: '<p>Card content is usually organized in smaller sections (<code>.section</code>) to be more easily digestible. A card section can be any valid HTML5 element with the appropriate class applied to it.</p>',
example: `<div class="container" style="padding: 0.25rem"><div class="row"><div class="col-sm-12">
<div class="card fluid" style="margin: 0.5rem 0.25rem"><h3 class="doc section">Title section</h3><p class="doc section">This is a section with some textual content.</p></div>
</div></div></div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`],
notes: [
`While not mandatory, it is highly suggested that you wrap all of your cards' contents in one or more sections.`,
`Remember that a section can be any valid HTML5 element, so you can apply them to headings, paragraphs, input elements etc.`,
`Media sections have a default height of <code>200px</code>.`,
`Due to the media sections using <a href="http://caniuse.com/#feat=object-fit" target="_blank"><code>object-fit</code></a>, you might want to use a polyfill for better browser support (recommended: <a href="https://github.com/bfred-it/object-fit-images" target="_blank">image polyfill</a>, <a href="https://github.com/jonathantneal/fitie" target="_blank">video polyfill</a>).`,
`Depending on the source website, some embedded videos might not display properly as media sections.`
],
customization: [
`Text color for cards and card sections can be changed by changing the value of the <code>--card-fore-color</code> variable.`,
`Background color for cards and card sections can be changed by changing the value of the <code>--card-back-color</code> variable.`,
`Border color for cards and card sections can be changed by changing the value of the <code>--card-border-color</code> variable.`,
`You can customize the colors of different color variants by changing the values of the related variables in their respective definitions.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`
],
modifiers: [
{
title : 'Media sections',
description: '<p>You can create sections for media (<code>.media</code>), such as images or videos (using an <code>&lt;img&gt;</code> or a <code>&lt;iframe&gt;</code> element respectively). These sections are styled appropriately for presentation of media content, meaning that the content will scale appropriately to fill up the available space.</p>',
example: `<div class="container" style="padding: 0.25rem;"><div class="row">
<div class="card"><div class="section"><h3 class="doc">Card with image</h3></div><img class="section media" src="https://placehold.it/800x600" alt="placeholder"></div>
<div class="card"><div class="section"><h3 class="doc">Card with video</h3></div><iframe class="section media" width="1280" height="720" src="https://www.youtube.com/embed/ScMzIvxBSi4"></iframe></div>
</div></div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;img</span> <span class="highlight-b">src</span>=<span class="highlight-c">&quot;image.png&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section media&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`]
},
{
title : 'Color variants',
description: '<p>You can create sections with a darker (<code>.dark</code>) background, by applying the appropriate modifier.</p>',
example: `<div class="container" style="padding: 0.25rem;"><div class="row">
<div class="card"><div class="section"><h3 class="doc">Normal section</h3></div><div class="section dark"><h3 class="doc">Dark section</h3></div></div>
</div></div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section dark&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`]
},
{
title : 'Additional spacing',
description: '<p>You can create sections with additional spacing (<code>.double-padded</code>), by applying the appropriate modifier.</p>',
example: `<div class="container" style="padding: 0.25rem;"><div class="row">
<div class="card"><div class="section"><h3 class="doc">Normal spacing</h3></div><div class="section double-padded"><h3 class="doc">Additional spacing</h3></div></div>
</div></div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section double-padded&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`]
}
],
dos: [],
donts: [
{
description: `Avoid mixing regular content with content in sections. Instead, wrap all of your card's contents in sections.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>This should have been a section!<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
}
]
}
/*
Modifiers:
{
title : '',
description: '',
example: '',
samples: []
}
Dos/Donts:
{
description: '',
sample: ''
}
*/
module.exports = {
id: 'card-sections',
title: 'Card sections',
keywords: [`card`, `row`, `section`, `container`, `col`, `column`, `media`, `double-padded`, `dark`],
description: '<p>Card content is usually organized in smaller sections (<code>.section</code>) to be more easily digestible. A card section can be any valid HTML5 element with the appropriate class applied to it.</p>',
example: `<div class="container" style="padding: 0.25rem"><div class="row"><div class="col-sm-12">
<div class="card fluid" style="margin: 0.5rem 0.25rem"><h3 class="doc section">Title section</h3><p class="doc section">This is a section with some textual content.</p></div>
</div></div></div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`],
notes: [
`While not mandatory, it is highly suggested that you wrap all of your cards' contents in one or more sections.`,
`Remember that a section can be any valid HTML5 element, so you can apply them to headings, paragraphs, input elements etc.`,
`Media sections have a default height of <code>200px</code>.`,
`Due to the media sections using <a href="http://caniuse.com/#feat=object-fit" target="_blank"><code>object-fit</code></a>, you might want to use a polyfill for better browser support (recommended: <a href="https://github.com/bfred-it/object-fit-images" target="_blank">image polyfill</a>, <a href="https://github.com/jonathantneal/fitie" target="_blank">video polyfill</a>).`,
`Depending on the source website, some embedded videos might not display properly as media sections.`
],
customization: [
`Text color for cards and card sections can be changed by changing the value of the <code>--card-fore-color</code> variable.`,
`Background color for cards and card sections can be changed by changing the value of the <code>--card-back-color</code> variable.`,
`Border color for cards and card sections can be changed by changing the value of the <code>--card-border-color</code> variable.`,
`You can customize the colors of different color variants by changing the values of the related variables in their respective definitions.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`
],
modifiers: [
{
title : 'Media sections',
description: '<p>You can create sections for media (<code>.media</code>), such as images or videos (using an <code>&lt;img&gt;</code> or a <code>&lt;iframe&gt;</code> element respectively). These sections are styled appropriately for presentation of media content, meaning that the content will scale appropriately to fill up the available space.</p>',
example: `<div class="container" style="padding: 0.25rem;"><div class="row">
<div class="card"><div class="section"><h3 class="doc">Card with image</h3></div><img class="section media" src="https://placehold.it/800x600" alt="placeholder"></div>
<div class="card"><div class="section"><h3 class="doc">Card with video</h3></div><iframe class="section media" width="1280" height="720" src="https://www.youtube.com/embed/ScMzIvxBSi4"></iframe></div>
</div></div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;img</span> <span class="highlight-b">src</span>=<span class="highlight-c">&quot;image.png&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section media&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`]
},
{
title : 'Color variants',
description: '<p>You can create sections with a darker (<code>.dark</code>) background, by applying the appropriate modifier.</p>',
example: `<div class="container" style="padding: 0.25rem;"><div class="row">
<div class="card"><div class="section"><h3 class="doc">Normal section</h3></div><div class="section dark"><h3 class="doc">Dark section</h3></div></div>
</div></div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section dark&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`]
},
{
title : 'Additional spacing',
description: '<p>You can create sections with additional spacing (<code>.double-padded</code>), by applying the appropriate modifier.</p>',
example: `<div class="container" style="padding: 0.25rem;"><div class="row">
<div class="card"><div class="section"><h3 class="doc">Normal spacing</h3></div><div class="section double-padded"><h3 class="doc">Additional spacing</h3></div></div>
</div></div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section double-padded&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`]
}
],
dos: [],
donts: [
{
description: `Avoid mixing regular content with content in sections. Instead, wrap all of your card's contents in sections.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>This should have been a section!<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
}
]
}
/*
Modifiers:
{
title : '',
description: '',
example: '',
samples: []
}
Dos/Donts:
{
description: '',
sample: ''
}
*/

View file

@ -1,89 +1,89 @@
module.exports = {
id: 'cards',
title: 'Cards',
keywords: [`card`, `row`, `section`, `container`, `col`, `column`, `small`, `large`, `fluid`, `warning`, `error`],
description: `<p><strong>mini.css</strong> provides you with cards (<code>.card</code>), general-purpose containers that help you organize the content of your web apps. Cards should be used in combination with the <a href="#grid">grid system</a>, meaning that they need to be placed inside a grid's rows to work properly. Layouts created with cards are responsive, realigning according to the available size on the screen.</p>`,
example: `<div class="container" style="padding: 0.25rem"><div class="row">
<div class="card"><div class="section"><h3 class="doc">Card 1</h3><p class="doc">This is a basic card with some sample content.</p></div></div>
<div class="card"><div class="section"><h3 class="doc">Card 2</h3><p class="doc">This is another card with some sample content.</p></div></div>
<div class="card"><div class="section"><h3 class="doc">Card 3</h3><p class="doc">This is one more card with some sample content.</p></div></div>
</div></div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`],
notes: [`Due to the fact that fluid cards stretch to fill their parent container, they might not fully respect their margins sometimes, although this should not cause any noticable problems in your web apps' layouts.`],
customization: [
`Text color for cards can be changed by changing the value of the <code>--card-fore-color</code> variable.`,
`Background color for cards can be changed by changing the value of the <code>--card-back-color</code> variable.`,
`Border color for cards can be changed by changing the value of the <code>--card-border-color</code> variable.`,
`You can customize the colors of different color variants by changing the values of the related variables in their respective definitions.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [
{
title : 'Alternative sizes',
description: `<p>You can create small (<code>.small</code>, <code>240px</code> wide) or large (<code>.large</code>, <code>480px</code> wide) cards by applying the appropriate modifiers to a card. Apart from that, you can also create fluid (<code>.fluid</code>) cards, that take up as much space as is available, however you will have to place these cards inside a grid layout's columns, effectively adding one extra step for them to display properly.</p>`,
example: `<div class="container" style="padding: 0.25rem"><div class="row">
<div class="card small"><div class="section"><h3 class="doc">Small Card</h3><p class="doc">Small cards are <code>240px</code> wide.</p></div></div>
<div class="card large"><div class="section"><h3 class="doc">Large Card</h3><p class="doc">Large cards are <code>480px</code> wide.</p></div></div>
<div class="col-sm-12 col-md-10 col-lg-8">
<div class="card fluid" style="margin: 0.5rem 0.25rem;"><div class="section"><h3 class="doc">Fluid Card</h3><p class="doc">Fluid cards scale their width based on the column that contains them.</p></div></div>
</div></div></div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card small&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card large&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card fluid&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`]
},
{
title : 'Color variants',
description: `<p>You can display warning (<code>.warning</code>) or error (<code>.error</code>) messages using cards, simply by adding the appropriate color modifiers to a card.</p>`,
example: `<div class="container" style="padding: 0.25rem"><div class="row">
<div class="card warning"><div class="section"><h3 class="doc">Warning Card</h3><p class="doc">Warning cards are used to display important information to users.</p></div></div>
<div class="card error"><div class="section"><h3 class="doc">Error Card</h3><p class="doc">Error cards are used to display error messages to users.</p></div></div>
</div></div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card warning&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card error&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`]
}
],
dos: [
{
description: `You can create rows inside a card, which can in turn contain other cards.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
}
],
donts: [
{
description: `An element cannot be a card and a row or column at the same time.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card row&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card col-sm&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span></pre>`
},
{
description: `Never forget to wrap your cards inside a row and your fluid cards inside a row and a column.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
},
{
description: `Try not to combine fixed-width and fluid cards. Instead, combine fixed-width cards with columns and place fluid cards inside them.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card fluid&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
},
{
description: `Avoid applying two color modifiers on the same card.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card warning error&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span></pre>`
}
]
}
module.exports = {
id: 'cards',
title: 'Cards',
keywords: [`card`, `row`, `section`, `container`, `col`, `column`, `small`, `large`, `fluid`, `warning`, `error`],
description: `<p><strong>mini.css</strong> provides you with cards (<code>.card</code>), general-purpose containers that help you organize the content of your web apps. Cards should be used in combination with the <a href="#grid">grid system</a>, meaning that they need to be placed inside a grid's rows to work properly. Layouts created with cards are responsive, realigning according to the available size on the screen.</p>`,
example: `<div class="container" style="padding: 0.25rem"><div class="row">
<div class="card"><div class="section"><h3 class="doc">Card 1</h3><p class="doc">This is a basic card with some sample content.</p></div></div>
<div class="card"><div class="section"><h3 class="doc">Card 2</h3><p class="doc">This is another card with some sample content.</p></div></div>
<div class="card"><div class="section"><h3 class="doc">Card 3</h3><p class="doc">This is one more card with some sample content.</p></div></div>
</div></div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`],
notes: [`Due to the fact that fluid cards stretch to fill their parent container, they might not fully respect their margins sometimes, although this should not cause any noticable problems in your web apps' layouts.`],
customization: [
`Text color for cards can be changed by changing the value of the <code>--card-fore-color</code> variable.`,
`Background color for cards can be changed by changing the value of the <code>--card-back-color</code> variable.`,
`Border color for cards can be changed by changing the value of the <code>--card-border-color</code> variable.`,
`You can customize the colors of different color variants by changing the values of the related variables in their respective definitions.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [
{
title : 'Alternative sizes',
description: `<p>You can create small (<code>.small</code>, <code>240px</code> wide) or large (<code>.large</code>, <code>480px</code> wide) cards by applying the appropriate modifiers to a card. Apart from that, you can also create fluid (<code>.fluid</code>) cards, that take up as much space as is available, however you will have to place these cards inside a grid layout's columns, effectively adding one extra step for them to display properly.</p>`,
example: `<div class="container" style="padding: 0.25rem"><div class="row">
<div class="card small"><div class="section"><h3 class="doc">Small Card</h3><p class="doc">Small cards are <code>240px</code> wide.</p></div></div>
<div class="card large"><div class="section"><h3 class="doc">Large Card</h3><p class="doc">Large cards are <code>480px</code> wide.</p></div></div>
<div class="col-sm-12 col-md-10 col-lg-8">
<div class="card fluid" style="margin: 0.5rem 0.25rem;"><div class="section"><h3 class="doc">Fluid Card</h3><p class="doc">Fluid cards scale their width based on the column that contains them.</p></div></div>
</div></div></div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card small&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card large&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card fluid&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`]
},
{
title : 'Color variants',
description: `<p>You can display warning (<code>.warning</code>) or error (<code>.error</code>) messages using cards, simply by adding the appropriate color modifiers to a card.</p>`,
example: `<div class="container" style="padding: 0.25rem"><div class="row">
<div class="card warning"><div class="section"><h3 class="doc">Warning Card</h3><p class="doc">Warning cards are used to display important information to users.</p></div></div>
<div class="card error"><div class="section"><h3 class="doc">Error Card</h3><p class="doc">Error cards are used to display error messages to users.</p></div></div>
</div></div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card warning&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card error&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`]
}
],
dos: [
{
description: `You can create rows inside a card, which can in turn contain other cards.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
}
],
donts: [
{
description: `An element cannot be a card and a row or column at the same time.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card row&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card col-sm&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span></pre>`
},
{
description: `Never forget to wrap your cards inside a row and your fluid cards inside a row and a column.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
},
{
description: `Try not to combine fixed-width and fluid cards. Instead, combine fixed-width cards with columns and place fluid cards inside them.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card fluid&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
},
{
description: `Avoid applying two color modifiers on the same card.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card warning error&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span></pre>`
}
]
}

View file

@ -1,51 +1,51 @@
module.exports = {
id: 'code-and-quotations',
title: 'Code &amp; quotations',
keywords: [`code`, `pre`, `kbd`, `blockquote`, `quotation`],
description: '<p>Code blocks and quotation elements are styled using custom rules that help make them stand out from the rest of the text, while inline code and keyboard input tags are minimally styled, aiming not to break the flow of regular text.</p>',
example: `<p class="doc">This is some text with some inline <code class="doc">source code</code> and some keyboard <kbd class="doc">input</kbd>.</p>
<pre class="doc">function sum(num1, num2){
return num1 + num2;
}</pre>
<blockquote cite="www.quotation.source" class="doc">This is some text quoted from elsewhere.</blockquote>`,
samples: [
`<pre><span class="code-line"><span class="highlight-a">&lt;p&gt;</span>This is some text with some inline <span class="highlight-a">&lt;code&gt;</span>source code<span class="highlight-a">&lt;/code&gt;</span> and some keyboard <span class="highlight-a">&lt;kbd&gt;</span>input<span class="highlight-a">&lt;/kbd&gt;</span>.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;pre&gt;</span>function sum(num1, num2){</span>
<span class="code-line"> return num1 + num2;</span>
<span class="code-line">}<span class="highlight-a">&lt;/pre&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;blockquote</span> <span class="highlight-b">cite</span>=<span class="highlight-c">&quot;www.quotation.source&quot;</span><span class="highlight-a">&gt;</span>This is some text quoted from elsewhere.<span class="highlight-a">&lt;/blockquote&gt;</span></span></pre>`
],
notes: [
`The <code>cite</code> attribute of <code>&lt;blockquote&gt;</code> elements is not mandatory and can be omitted. The element's sizing will be automatically adjusted according to the presence of the <code>cite</code> attribute.`
],
customization: [
`Text color can be changed globally by changing the value of the <code>--fore-color</code> variable. This will affect the text color of <code>&lt;code&gt</code> and <code>&lt;pre&gt</code> elements and background color of <code>&lt;kbd&gt;</code> elements.`,
`Background color can be changed globally by changing the value of the <code>--back-color</code> variable. This will affect the background color of <code>&lt;blockquote&gt</code> elements and text color of <code>&lt;kbd&gt</code>.`,
`You can change the background color of <code>&lt;code&gt</code> and <code>&lt;pre&gt</code> elements by changing the value of the <code>--secondary-back-color</code> variable.`,
`You can change the text color of <code>&lt;blockquote&gt;</code> elements by changing the value of the <code>--secondary-fore-color</code> variable.`,
`You can change the border color of <code>&lt;pre&gt;</code> and <code>&lt;blockquote&gt;</code> elements by changing the value of the <code>--secondary-border-color</code> variable.`,
`You can change the border color of the left border of <code>&lt;pre&gt;</code> elements by changing the value of the <code>--pre-color</code> variable.`,
`You can change the border color of the left border of <code>&lt;blockquote&gt;</code> elements by changing the value of the <code>--blockquote-color</code> variable.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [],
dos: [],
donts: []
}
/*
Modifiers:
{
title : '',
description: '',
example: '',
samples: []
}
Dos/Donts:
{
description: '',
sample: ''
}
*/
module.exports = {
id: 'code-and-quotations',
title: 'Code &amp; quotations',
keywords: [`code`, `pre`, `kbd`, `blockquote`, `quotation`],
description: '<p>Code blocks and quotation elements are styled using custom rules that help make them stand out from the rest of the text, while inline code and keyboard input tags are minimally styled, aiming not to break the flow of regular text.</p>',
example: `<p class="doc">This is some text with some inline <code class="doc">source code</code> and some keyboard <kbd class="doc">input</kbd>.</p>
<pre class="doc">function sum(num1, num2){
return num1 + num2;
}</pre>
<blockquote cite="www.quotation.source" class="doc">This is some text quoted from elsewhere.</blockquote>`,
samples: [
`<pre><span class="code-line"><span class="highlight-a">&lt;p&gt;</span>This is some text with some inline <span class="highlight-a">&lt;code&gt;</span>source code<span class="highlight-a">&lt;/code&gt;</span> and some keyboard <span class="highlight-a">&lt;kbd&gt;</span>input<span class="highlight-a">&lt;/kbd&gt;</span>.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;pre&gt;</span>function sum(num1, num2){</span>
<span class="code-line"> return num1 + num2;</span>
<span class="code-line">}<span class="highlight-a">&lt;/pre&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;blockquote</span> <span class="highlight-b">cite</span>=<span class="highlight-c">&quot;www.quotation.source&quot;</span><span class="highlight-a">&gt;</span>This is some text quoted from elsewhere.<span class="highlight-a">&lt;/blockquote&gt;</span></span></pre>`
],
notes: [
`The <code>cite</code> attribute of <code>&lt;blockquote&gt;</code> elements is not mandatory and can be omitted. The element's sizing will be automatically adjusted according to the presence of the <code>cite</code> attribute.`
],
customization: [
`Text color can be changed globally by changing the value of the <code>--fore-color</code> variable. This will affect the text color of <code>&lt;code&gt</code> and <code>&lt;pre&gt</code> elements and background color of <code>&lt;kbd&gt;</code> elements.`,
`Background color can be changed globally by changing the value of the <code>--back-color</code> variable. This will affect the background color of <code>&lt;blockquote&gt</code> elements and text color of <code>&lt;kbd&gt</code>.`,
`You can change the background color of <code>&lt;code&gt</code> and <code>&lt;pre&gt</code> elements by changing the value of the <code>--secondary-back-color</code> variable.`,
`You can change the text color of <code>&lt;blockquote&gt;</code> elements by changing the value of the <code>--secondary-fore-color</code> variable.`,
`You can change the border color of <code>&lt;pre&gt;</code> and <code>&lt;blockquote&gt;</code> elements by changing the value of the <code>--secondary-border-color</code> variable.`,
`You can change the border color of the left border of <code>&lt;pre&gt;</code> elements by changing the value of the <code>--pre-color</code> variable.`,
`You can change the border color of the left border of <code>&lt;blockquote&gt;</code> elements by changing the value of the <code>--blockquote-color</code> variable.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [],
dos: [],
donts: []
}
/*
Modifiers:
{
title : '',
description: '',
example: '',
samples: []
}
Dos/Donts:
{
description: '',
sample: ''
}
*/

View file

@ -1,39 +1,39 @@
module.exports = {
id: 'common-textual-elements',
title: 'Common textual elements',
tag: 'p',
keywords: ['p', 'paragraph', 'text', 'textual elements', 'strong', 'bold', 'b', 'em', 'i', 'emphasis', 'italics', 'small', 'a', 'link', 'hr', 'horizontal rule', 'sub', 'subscript', 'sup', 'exponent', 'superscript', 'normalize', 'reset'],
description: `<p><strong>mini.css</strong> utilizes the ruleset of <a href="http://necolas.github.io/normalize.css/" target="_blank">Normalize.css</a> v7.0.0 to reliably deal with inconsistencies between browsers, while applying some tasteful defaults on top, such as using <a href="https://www.smashingmagazine.com/2015/11/using-system-ui-fonts-practical-guide/" target="_blank">native font stack</a> to figure out the best font for each device, setting the background and foreground colors, as well as the size of the text to <code>16px</code> and its line height to <code>1.5</code>.</p>
<p>All of the most common HTML5 elements, such as paragraphs, links, bold, small and slanted text, have been styled by default using clean, modern typography to make your pages look cool and stand out from the rest of the internet.</p>`,
example: `<p class="doc">This is a paragraph with some sample text. Did you know that the latest version of <strong class="doc">mini.css</strong> is codenamed <em class="doc">Gluon</em>? Well, now you do!</p><hr class="doc"/><p><small class="doc">Remember that <strong class="doc">mini.css</strong> is totally free, no fine print involved!</small></p>`,
samples: [
`<pre><span class="code-line"><span class="highlight-a">&lt;p&gt;</span>This is a paragraph. with some <span class="highlight-a">&lt;strong&gt;</span>bold text<span class="highlight-a">&lt;/strong&gt;</span> and some <span class="highlight-a">&lt;em&gt;</span>italics text<span class="highlight-a">&lt;/em&gt;</span>.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span><span class="highlight-a">&gt;</span>This is a link.<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;small&gt;</span>This is some small text.<span class="highlight-a">&lt;/small&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;sub&gt;</span>Subscript<span class="highlight-a">&lt;/sub&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;sup&gt;</span>Superscript<span class="highlight-a">&lt;/sup&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;hr/&gt;</span></span></pre>`
],
notes: [
],
customization: [
`Text color can be changed globally by changing the value of the <code>--fore-color</code> variable.`,
`Background color can be changed globally by changing the value of the <code>--back-color</code> variable.`,
`Border color can be changed globally by changing the value of the <code>--border-color</code> variable. This affects the color of <code>&lt;hr&gt;</code> elements.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`You can change the color of links by changing the values of the <code>--a-link-color</code> and <code>--a-visited-color</code> variables.`
],
modifiers: [],
dos: [],
donts: [
{description: `Avoid altering the base font size of <code>16px</code> directly in your CSS code, as it can cause problems with the display of certain elements.`,
sample:
`<pre><span class="code-line"><span class="highlight-c">/* Do not do this (use Sass instead) */</span></span>
<span class="code-line"><span class="highlight-a">html</span> {</span>
<span class="code-line"> font-size: <span class="highlight-b">14px</span>;</span>
<span class="code-line">}</span></pre>`
}
]
}
module.exports = {
id: 'common-textual-elements',
title: 'Common textual elements',
tag: 'p',
keywords: ['p', 'paragraph', 'text', 'textual elements', 'strong', 'bold', 'b', 'em', 'i', 'emphasis', 'italics', 'small', 'a', 'link', 'hr', 'horizontal rule', 'sub', 'subscript', 'sup', 'exponent', 'superscript', 'normalize', 'reset'],
description: `<p><strong>mini.css</strong> utilizes the ruleset of <a href="http://necolas.github.io/normalize.css/" target="_blank">Normalize.css</a> v7.0.0 to reliably deal with inconsistencies between browsers, while applying some tasteful defaults on top, such as using <a href="https://www.smashingmagazine.com/2015/11/using-system-ui-fonts-practical-guide/" target="_blank">native font stack</a> to figure out the best font for each device, setting the background and foreground colors, as well as the size of the text to <code>16px</code> and its line height to <code>1.5</code>.</p>
<p>All of the most common HTML5 elements, such as paragraphs, links, bold, small and slanted text, have been styled by default using clean, modern typography to make your pages look cool and stand out from the rest of the internet.</p>`,
example: `<p class="doc">This is a paragraph with some sample text. Did you know that the latest version of <strong class="doc">mini.css</strong> is codenamed <em class="doc">Gluon</em>? Well, now you do!</p><hr class="doc"/><p><small class="doc">Remember that <strong class="doc">mini.css</strong> is totally free, no fine print involved!</small></p>`,
samples: [
`<pre><span class="code-line"><span class="highlight-a">&lt;p&gt;</span>This is a paragraph. with some <span class="highlight-a">&lt;strong&gt;</span>bold text<span class="highlight-a">&lt;/strong&gt;</span> and some <span class="highlight-a">&lt;em&gt;</span>italics text<span class="highlight-a">&lt;/em&gt;</span>.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span><span class="highlight-a">&gt;</span>This is a link.<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;small&gt;</span>This is some small text.<span class="highlight-a">&lt;/small&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;sub&gt;</span>Subscript<span class="highlight-a">&lt;/sub&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;sup&gt;</span>Superscript<span class="highlight-a">&lt;/sup&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;hr/&gt;</span></span></pre>`
],
notes: [
],
customization: [
`Text color can be changed globally by changing the value of the <code>--fore-color</code> variable.`,
`Background color can be changed globally by changing the value of the <code>--back-color</code> variable.`,
`Border color can be changed globally by changing the value of the <code>--border-color</code> variable. This affects the color of <code>&lt;hr&gt;</code> elements.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`You can change the color of links by changing the values of the <code>--a-link-color</code> and <code>--a-visited-color</code> variables.`
],
modifiers: [],
dos: [],
donts: [
{description: `Avoid altering the base font size of <code>16px</code> directly in your CSS code, as it can cause problems with the display of certain elements.`,
sample:
`<pre><span class="code-line"><span class="highlight-c">/* Do not do this (use Sass instead) */</span></span>
<span class="code-line"><span class="highlight-a">html</span> {</span>
<span class="code-line"> font-size: <span class="highlight-b">14px</span>;</span>
<span class="code-line">}</span></pre>`
}
]
}

View file

@ -1,41 +1,41 @@
var gettingStarted = require('./gettingStarted');
var commonTextualElements = require('./commonTextualElements');
var headings = require('./headings');
var lists = require('./lists');
var images = require('./images');
var codeAndQuotations = require('./codeAndQuotations');
var grid = require('./grid');
var cards = require('./cards');
var cardSections = require('./cardSections');
var formsAndInput = require('./formsAndInput');
var buttons = require('./buttons');
var inputGrouping = require('./inputGrouping');
var header = require('./header');
var navigationBar = require('./navigationBar');
var footer = require('./footer');
var drawer = require('./drawer');
var tables = require('./tables');
var textHighlighting = require('./textHighlighting');
var toasts = require('./toasts');
var tooltips = require('./tooltips');
var modalDialogs = require('./modalDialogs');
var spoilersAndAccordions = require('./spoilersAndAccordions');
var progressBars = require('./progressBars');
var donutSpinners = require('./donutSpinners');
var icons = require('./icons');
var visibilityHelpers = require('./visibilityHelpers');
var elementDecorators = require('./elementDecorators');
var responsiveSpacingAndSizing = require('./responsiveSpacingAndSizing');
module.exports = [
gettingStarted,
commonTextualElements, headings, images, lists, codeAndQuotations,
grid, cards, cardSections,
formsAndInput, buttons, inputGrouping,
header, navigationBar, footer, drawer,
tables,
textHighlighting, toasts, tooltips, modalDialogs, spoilersAndAccordions,
progressBars, donutSpinners,
icons,
visibilityHelpers, elementDecorators, responsiveSpacingAndSizing
]
var gettingStarted = require('./gettingStarted');
var commonTextualElements = require('./commonTextualElements');
var headings = require('./headings');
var lists = require('./lists');
var images = require('./images');
var codeAndQuotations = require('./codeAndQuotations');
var grid = require('./grid');
var cards = require('./cards');
var cardSections = require('./cardSections');
var formsAndInput = require('./formsAndInput');
var buttons = require('./buttons');
var inputGrouping = require('./inputGrouping');
var header = require('./header');
var navigationBar = require('./navigationBar');
var footer = require('./footer');
var drawer = require('./drawer');
var tables = require('./tables');
var textHighlighting = require('./textHighlighting');
var toasts = require('./toasts');
var tooltips = require('./tooltips');
var modalDialogs = require('./modalDialogs');
var spoilersAndAccordions = require('./spoilersAndAccordions');
var progressBars = require('./progressBars');
var donutSpinners = require('./donutSpinners');
var icons = require('./icons');
var visibilityHelpers = require('./visibilityHelpers');
var elementDecorators = require('./elementDecorators');
var responsiveSpacingAndSizing = require('./responsiveSpacingAndSizing');
module.exports = [
gettingStarted,
commonTextualElements, headings, images, lists, codeAndQuotations,
grid, cards, cardSections,
formsAndInput, buttons, inputGrouping,
header, navigationBar, footer, drawer,
tables,
textHighlighting, toasts, tooltips, modalDialogs, spoilersAndAccordions,
progressBars, donutSpinners,
icons,
visibilityHelpers, elementDecorators, responsiveSpacingAndSizing
]

View file

@ -1,38 +1,38 @@
module.exports = {
id: 'donut-spinners',
title: 'Donut spinners',
keywords: [`spinner`, `donut`, `loading`, `progress`, `primary`, `secondary`, `tertiary`, `inline`, `animation`, `animated`],
description: `<p><strong>mini.css</strong> provides you with animated loading indicators (<code>.spinner</code>), which you can use to indicate that some content is loading.</p>`,
example: `<div class="spinner"></div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;spinner&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span></pre>`],
notes: [`You can use either a <code>&lt;div&gt;</code> or a <code>&lt;span&gt;</code> element to create a donut spinner.`,
`You can add the <code>role="progressbar"</code> attribute to spinner donut elements to increase accessibility.`,
`You can inline donut spinners inside a paragraph or some other textual content.`],
customization: [
`Foreground color for donut spinners can be changed by changing the value of the <code>--spinner-fore-color</code> variable.`,
`Background color for donut spinners can be changed by changing the value of the <code>--spinner-back-color</code> variable.`,
`You can customize the colors of different color variants by changing the values of the related variables in their respective definitions.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`
],
modifiers: [
{
title : 'Color variants',
description: `<p>You can create primary, secondary or tertiary (<code>.primary</code>, <code>.secondary</code>, <code>.tertiary</code>) donut spinners, simply by adding the appropriate color modifier.</p>`,
example: `<span class="spinner primary"></span><span class="spinner secondary"></span><span class="spinner tertiary"></span>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;spinner primary&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;spinner secondary&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;spinner tertiary&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span></pre>`]
}
],
dos: [],
donts: [
{
description: `Avoid inserting text inside donut spinners.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;spinner&quot;</span><span class="highlight-a">&gt;</span>Don't place text here.<span class="highlight-a">&lt;/div&gt;</span></span></pre>`
},
{
description: `Avoid applying two color modifiers on the same donut spinner.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;spinner primary secondary&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span></pre>`
}
]
}
module.exports = {
id: 'donut-spinners',
title: 'Donut spinners',
keywords: [`spinner`, `donut`, `loading`, `progress`, `primary`, `secondary`, `tertiary`, `inline`, `animation`, `animated`],
description: `<p><strong>mini.css</strong> provides you with animated loading indicators (<code>.spinner</code>), which you can use to indicate that some content is loading.</p>`,
example: `<div class="spinner"></div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;spinner&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span></pre>`],
notes: [`You can use either a <code>&lt;div&gt;</code> or a <code>&lt;span&gt;</code> element to create a donut spinner.`,
`You can add the <code>role="progressbar"</code> attribute to spinner donut elements to increase accessibility.`,
`You can inline donut spinners inside a paragraph or some other textual content.`],
customization: [
`Foreground color for donut spinners can be changed by changing the value of the <code>--spinner-fore-color</code> variable.`,
`Background color for donut spinners can be changed by changing the value of the <code>--spinner-back-color</code> variable.`,
`You can customize the colors of different color variants by changing the values of the related variables in their respective definitions.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`
],
modifiers: [
{
title : 'Color variants',
description: `<p>You can create primary, secondary or tertiary (<code>.primary</code>, <code>.secondary</code>, <code>.tertiary</code>) donut spinners, simply by adding the appropriate color modifier.</p>`,
example: `<span class="spinner primary"></span><span class="spinner secondary"></span><span class="spinner tertiary"></span>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;spinner primary&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;spinner secondary&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;spinner tertiary&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span></pre>`]
}
],
dos: [],
donts: [
{
description: `Avoid inserting text inside donut spinners.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;spinner&quot;</span><span class="highlight-a">&gt;</span>Don't place text here.<span class="highlight-a">&lt;/div&gt;</span></span></pre>`
},
{
description: `Avoid applying two color modifiers on the same donut spinner.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;spinner primary secondary&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span></pre>`
}
]
}

View file

@ -1,84 +1,84 @@
module.exports = {
id: 'drawer',
title: 'Menu drawer',
keywords: [`drawer`, `checkbox`, `toggle`, `close`, `drawer-toggle`, `drawer-close`, `menu`, `navigation`, `hamburger`],
description: `<p>The drawer component of <strong>mini.css</strong> is used to create responsive navigation menus for your web apps. It is composed of three components - the drawer, the toggle button and the close button:</p>
<ul><li>To create a drawer, simply create a checkbox input, applying the appropriate class to it (<code>.drawer</code>), immediately followed by a container of your liking (e.g. a <code>&lt;div&gt;</code> or <code>&lt;nav&gt;</code>). The former serves as your drawer's control, while the latter is the actual drawer container.</li>
<li>Create a label anywhere outside your drawer's container for the checkbox controlling your drawer, applying the appropriate class (<code>.drawer-toggle</code>). This will serve as the toggle button for your drawer menu.</li>
<li>Finally, inside your drawer's container, add another label for the checkbox controlling your drawer, applying the appropriate class (<code>.drawer-close</code>). This will serve as the close button for your drawer menu.</li>
</ul>`,
example: `<div style="height: 8rem; position: relative; text-align: center;"><br>
<style>.drawer + .demo { position: absolute; height: 8rem; z-index: 0; top: 0; right: calc(0rem - 320px - 0.5rem); padding: 0.5rem; text-align: left;} [type="checkbox"]:checked.drawer + .demo { z-index: 1001; margin-right: 0.5rem;}</style>
<label for="demo-toggle" class="button drawer-toggle persistent doc"></label>
<input type="checkbox" id="demo-toggle" class="drawer persistent"> <div class="demo doc">
<label for="demo-toggle" class="drawer-close doc"></label><a href="#" class="doc">Home</a><br/> <a href="#" class="doc">News</a><br/>
<a href="#" class="doc">About</a><br/> <a href="#" class="doc">Contact</a><br/></div>
</div>`,
samples: [
`<pre><span class="code-line"><span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;drawer-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;drawer-toggle&quot;</span><span class="highlight-a">&gt;&lt;/label&gt;</span></span>
<span class="code-line"></span>
<span class="code-line"><span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;checkbox&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;drawer-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;drawer&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;drawer-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;drawer-close&quot;</span><span class="highlight-a">&gt;&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span><span class="highlight-a">&gt;</span>Home<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
],
notes: [
`Drawer menus are responsive by default and will expand into normal containers on screens larger or equal to <code>768px</code> wide.`,
`It is highly recommended to place your drawer's toggle button inside your web app's header element.`,
`You can combine the navigation bar element with the drawer menu for better results.`,
`Remember to apply the appropriate classes to any and all elements, as indicated in the examples. Failing to do so will result in the drawer menu not rendering or behaving properly.`
],
customization: [
`Text color can be changed globally by changing the value of the <code>--fore-color</code> variable. This will affect the text color of the toggle button and items inside the drawer container.`,
`Background color for the drawer container can be changed by changing the value of the <code>--drawer-back-color</code> variable.`,
`Border color for the drawer container can be changed by changing the value of the <code>--drawer-border-color</code> variable.`,
`Text color for the drawer close button can be changed by changing the values of the <code>--drawer-close-color</code>.`,
`Background color for the drawer close button when focused or hovered over can be changed by changing the values of the <code>--drawer-hover-back-color</code>.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [
{
title : `Persistent drawer`,
description: `<p>If you want your drawer menus to not expand into normal containers on larger screens, simply add the appropriate modifier (<code>.persistent</code>) on the checkbox controlling the drawer and its toggle button.</p>`,
example: ``,
samples: [
`<pre><span class="code-line"><span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;drawer-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;drawer-toggle persistent&quot;</span><span class="highlight-a">&gt;&lt;/label&gt;</span></span>
<span class="code-line"></span>
<span class="code-line"><span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;checkbox&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;drawer-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;drawer persistent&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;drawer-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;drawer-close&quot;</span><span class="highlight-a">&gt;&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span><span class="highlight-a">&gt;</span>Home<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
]
}
],
dos: [
{
description: `You can combine the drawer menu with the <a href="#grid">grid system</a> to create responsive menus that are part of the layout of your web app.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;checkbox&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;drawer-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;drawer&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-md-4&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;drawer-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;drawer-close&quot;</span><span class="highlight-a">&gt;&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span><span class="highlight-a">&gt;</span>Home<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12 col-md-8&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>Page content<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
}
],
donts: [
{
description: `You should not place anything between the checkbox controlling the drawer and the container.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;checkbox&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;drawer-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;drawer&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"><span class="highlight-c">&lt;!-- Do not place other stuff between these --&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;drawer-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;drawer-close&quot;</span><span class="highlight-a">&gt;&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span><span class="highlight-a">&gt;</span>Home<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
}
]
}
module.exports = {
id: 'drawer',
title: 'Menu drawer',
keywords: [`drawer`, `checkbox`, `toggle`, `close`, `drawer-toggle`, `drawer-close`, `menu`, `navigation`, `hamburger`],
description: `<p>The drawer component of <strong>mini.css</strong> is used to create responsive navigation menus for your web apps. It is composed of three components - the drawer, the toggle button and the close button:</p>
<ul><li>To create a drawer, simply create a checkbox input, applying the appropriate class to it (<code>.drawer</code>), immediately followed by a container of your liking (e.g. a <code>&lt;div&gt;</code> or <code>&lt;nav&gt;</code>). The former serves as your drawer's control, while the latter is the actual drawer container.</li>
<li>Create a label anywhere outside your drawer's container for the checkbox controlling your drawer, applying the appropriate class (<code>.drawer-toggle</code>). This will serve as the toggle button for your drawer menu.</li>
<li>Finally, inside your drawer's container, add another label for the checkbox controlling your drawer, applying the appropriate class (<code>.drawer-close</code>). This will serve as the close button for your drawer menu.</li>
</ul>`,
example: `<div style="height: 8rem; position: relative; text-align: center;"><br>
<style>.drawer + .demo { position: absolute; height: 8rem; z-index: 0; top: 0; right: calc(0rem - 320px - 0.5rem); padding: 0.5rem; text-align: left;} [type="checkbox"]:checked.drawer + .demo { z-index: 1001; margin-right: 0.5rem;}</style>
<label for="demo-toggle" class="button drawer-toggle persistent doc"></label>
<input type="checkbox" id="demo-toggle" class="drawer persistent"> <div class="demo doc">
<label for="demo-toggle" class="drawer-close doc"></label><a href="#" class="doc">Home</a><br/> <a href="#" class="doc">News</a><br/>
<a href="#" class="doc">About</a><br/> <a href="#" class="doc">Contact</a><br/></div>
</div>`,
samples: [
`<pre><span class="code-line"><span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;drawer-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;drawer-toggle&quot;</span><span class="highlight-a">&gt;&lt;/label&gt;</span></span>
<span class="code-line"></span>
<span class="code-line"><span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;checkbox&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;drawer-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;drawer&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;drawer-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;drawer-close&quot;</span><span class="highlight-a">&gt;&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span><span class="highlight-a">&gt;</span>Home<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
],
notes: [
`Drawer menus are responsive by default and will expand into normal containers on screens larger or equal to <code>768px</code> wide.`,
`It is highly recommended to place your drawer's toggle button inside your web app's header element.`,
`You can combine the navigation bar element with the drawer menu for better results.`,
`Remember to apply the appropriate classes to any and all elements, as indicated in the examples. Failing to do so will result in the drawer menu not rendering or behaving properly.`
],
customization: [
`Text color can be changed globally by changing the value of the <code>--fore-color</code> variable. This will affect the text color of the toggle button and items inside the drawer container.`,
`Background color for the drawer container can be changed by changing the value of the <code>--drawer-back-color</code> variable.`,
`Border color for the drawer container can be changed by changing the value of the <code>--drawer-border-color</code> variable.`,
`Text color for the drawer close button can be changed by changing the values of the <code>--drawer-close-color</code>.`,
`Background color for the drawer close button when focused or hovered over can be changed by changing the values of the <code>--drawer-hover-back-color</code>.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [
{
title : `Persistent drawer`,
description: `<p>If you want your drawer menus to not expand into normal containers on larger screens, simply add the appropriate modifier (<code>.persistent</code>) on the checkbox controlling the drawer and its toggle button.</p>`,
example: ``,
samples: [
`<pre><span class="code-line"><span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;drawer-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;drawer-toggle persistent&quot;</span><span class="highlight-a">&gt;&lt;/label&gt;</span></span>
<span class="code-line"></span>
<span class="code-line"><span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;checkbox&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;drawer-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;drawer persistent&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;drawer-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;drawer-close&quot;</span><span class="highlight-a">&gt;&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span><span class="highlight-a">&gt;</span>Home<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
]
}
],
dos: [
{
description: `You can combine the drawer menu with the <a href="#grid">grid system</a> to create responsive menus that are part of the layout of your web app.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;checkbox&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;drawer-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;drawer&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-md-4&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;drawer-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;drawer-close&quot;</span><span class="highlight-a">&gt;&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span><span class="highlight-a">&gt;</span>Home<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12 col-md-8&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>Page content<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
}
],
donts: [
{
description: `You should not place anything between the checkbox controlling the drawer and the container.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;checkbox&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;drawer-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;drawer&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"><span class="highlight-c">&lt;!-- Do not place other stuff between these --&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;drawer-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;drawer-close&quot;</span><span class="highlight-a">&gt;&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span><span class="highlight-a">&gt;</span>Home<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
}
]
}

View file

@ -1,27 +1,27 @@
module.exports = {
id: 'element-decorators',
title: 'Element decorators',
keywords: ['border','border-radius', 'bordered', 'rounded', 'circular', 'shadowed', 'utility'],
description: '<p>You can apply generic borders, shadows or border radiuses to any element, by using the appropriate class (<code>.bordered</code>, <code>.shadowed</code>, <code>.rounded</code> or <code>.circular</code>).</p>',
example: '<button class="bordered doc">Bordered button</button><button class="primary bordered doc">Bordered button</button><button class="shadowed doc">Shadowed button</button><br/><p><img src="https://placehold.it/200x200?text=rounded" alt="placeholder" class="rounded">&nbsp;&nbsp;<img src="https://placehold.it/200x200?text=circular" alt="placeholder" class="circular"></p>',
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;bordered&quot;</span><span class="highlight-a">&gt;</span>Bordered element.<span class="highlight-a">&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;shadowed&quot;</span><span class="highlight-a">&gt;</span>Shadowed element.<span class="highlight-a">&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;rounded&quot;</span><span class="highlight-a">&gt;</span>Rounded element.<span class="highlight-a">&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;circular&quot;</span><span class="highlight-a">&gt;</span>Circular element.<span class="highlight-a">&lt;/span&gt;</span></span></pre>`],
notes: [
'Element decorators use <code>!important</code> declarations to override any other styles, so exercise caution when using them.',
'Element decorators can be used with pretty much every element or component that is available.'
],
customization: [
`Boder color for the generic border decorator can be changed by changing the value of the <code>--generic-border-color</code> variable.`,
`Box shadow style for the generic shadow can be changed by changing the value of the <code>--generic-box-shadow</code> variable.`
],
modifiers: [],
dos: [],
donts: [
{
description: `Avoid applying the <code>.rounded</code> and <code>.circular</code> decorators on the same element.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;rounded circular&quot;</span><span class="highlight-a">&gt;</span>Do not do this.<span class="highlight-a">&lt;/span&gt;</span></span></pre>`
}
]
}
module.exports = {
id: 'element-decorators',
title: 'Element decorators',
keywords: ['border','border-radius', 'bordered', 'rounded', 'circular', 'shadowed', 'utility'],
description: '<p>You can apply generic borders, shadows or border radiuses to any element, by using the appropriate class (<code>.bordered</code>, <code>.shadowed</code>, <code>.rounded</code> or <code>.circular</code>).</p>',
example: '<button class="bordered doc">Bordered button</button><button class="primary bordered doc">Bordered button</button><button class="shadowed doc">Shadowed button</button><br/><p><img src="https://placehold.it/200x200?text=rounded" alt="placeholder" class="rounded">&nbsp;&nbsp;<img src="https://placehold.it/200x200?text=circular" alt="placeholder" class="circular"></p>',
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;bordered&quot;</span><span class="highlight-a">&gt;</span>Bordered element.<span class="highlight-a">&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;shadowed&quot;</span><span class="highlight-a">&gt;</span>Shadowed element.<span class="highlight-a">&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;rounded&quot;</span><span class="highlight-a">&gt;</span>Rounded element.<span class="highlight-a">&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;circular&quot;</span><span class="highlight-a">&gt;</span>Circular element.<span class="highlight-a">&lt;/span&gt;</span></span></pre>`],
notes: [
'Element decorators use <code>!important</code> declarations to override any other styles, so exercise caution when using them.',
'Element decorators can be used with pretty much every element or component that is available.'
],
customization: [
`Boder color for the generic border decorator can be changed by changing the value of the <code>--generic-border-color</code> variable.`,
`Box shadow style for the generic shadow can be changed by changing the value of the <code>--generic-box-shadow</code> variable.`
],
modifiers: [],
dos: [],
donts: [
{
description: `Avoid applying the <code>.rounded</code> and <code>.circular</code> decorators on the same element.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;rounded circular&quot;</span><span class="highlight-a">&gt;</span>Do not do this.<span class="highlight-a">&lt;/span&gt;</span></span></pre>`
}
]
}

View file

@ -1,30 +1,30 @@
module.exports = {
id: 'footer',
title: 'Footer',
keywords: [`navigation`, `footer`, `sticky`, `link`],
description: `<p>The footer element has been minimally styled, aiming to provide you with a clean base to create your web apps' footers.</p>`,
example: `<footer> <p class="doc">&copy; 2016-2017 Web Corporation | <a href="#" class="doc">About</a> | <a href="#" class="doc">Terms of use</a></p> </footer>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;footer&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>Footer text<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/footer&gt;</span></span></pre>`],
notes: [],
customization: [
`Text color for the footer can be changed by changing the value of the <code>--footer-fore-color</code> variable.`,
`Background color for the footer can be changed by changing the value of the <code>--footer-back-color</code> variable.`,
`Border color for the footer can be changed by changing the value of the <code>--footer-border-color</code> variable.`,
`Text color for links inside the footer can be changed by changing the value of the <code>--footer-link-color</code> variable.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`
],
modifiers: [
{
title : 'Sticky footer',
description: `<p>You can make your web app's footer sticky (<code>.sticky</code>), by applying the appropriate modifier.</p>`,
example: '',
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;footer</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;sticky&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>Footer text<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/footer&gt;</span></span></pre>`]
}
],
dos: [],
donts: []
}
module.exports = {
id: 'footer',
title: 'Footer',
keywords: [`navigation`, `footer`, `sticky`, `link`],
description: `<p>The footer element has been minimally styled, aiming to provide you with a clean base to create your web apps' footers.</p>`,
example: `<footer> <p class="doc">&copy; 2016-2017 Web Corporation | <a href="#" class="doc">About</a> | <a href="#" class="doc">Terms of use</a></p> </footer>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;footer&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>Footer text<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/footer&gt;</span></span></pre>`],
notes: [],
customization: [
`Text color for the footer can be changed by changing the value of the <code>--footer-fore-color</code> variable.`,
`Background color for the footer can be changed by changing the value of the <code>--footer-back-color</code> variable.`,
`Border color for the footer can be changed by changing the value of the <code>--footer-border-color</code> variable.`,
`Text color for links inside the footer can be changed by changing the value of the <code>--footer-link-color</code> variable.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`
],
modifiers: [
{
title : 'Sticky footer',
description: `<p>You can make your web app's footer sticky (<code>.sticky</code>), by applying the appropriate modifier.</p>`,
example: '',
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;footer</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;sticky&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>Footer text<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/footer&gt;</span></span></pre>`]
}
],
dos: [],
donts: []
}

View file

@ -1,76 +1,76 @@
module.exports = {
id: 'forms-and-input',
title: 'Forms &amp; input',
keywords: [`form`, `fieldset`, `legend`, `input`, `type`, `text`, `checkbox`, `radio`, `email`, `password`, `tel`, `input-group`, `input group`, `row`, `col`, `column`, `vertical`, `fluid`, `file`, `upload`, `select`, `textarea`, `option`, `label`],
description: `<p>Forms, labels and common HTML5 input elements have been styled using clean, modern rules, improving the accessibility and usability of your web apps' forms.</p>`,
example: `<form><fieldset><legend class="doc">Sample form</legend>
<div class="row responsive-label"><div class="col-sm-12 col-md-3"><label for="sf1-text" class="doc">Text</label></div>
<div class="col-sm-12 col-md"><input type="text" placeholder="Text" id="sf1-text" style="width:85%;" class="doc"></div></div>
<div class="row responsive-label"><div class="col-sm-12 col-md-3"><label for="sf1-pwd" class="doc">Password</label></div>
<div class="col-sm-12 col-md"><input type="password" placeholder="Password" id="sf1-pwd" style="width:85%;" class="doc"></div></div>
<div class="row responsive-label"><div class="col-sm-12 col-md-3"><label for="sf1-num" class="doc">Number</label></div>
<div class="col-sm-12 col-md"><input type="number" value="42" id="sf1-num" style="width:85%;" class="doc"></div></div>
<div class="row responsive-label"><div class="col-sm-12 col-md-3"><label for="sf1-select" class="doc">Select</label></div>
<div class="col-sm-12 col-md"><select id="sf1-select" style="width:85%;" class="doc"><option class="doc">Apples</option><option class="doc">Oranges</option></select></div></div>
<div class="row responsive-label"><div class="col-sm-12 col-md-3"><label for="sf1-check" class="doc">Checkbox</label></div>
<div class="col-sm-12 col-md"><input type="checkbox" autocomplete="off" id="sf1-check" class="doc"></div></div>
<div class="row responsive-label"><div class="col-sm-12 col-md-3"><label for="sf1-radio" class="doc">Radio</label></div>
<div class="col-sm-12 col-md"><input type="radio" autocomplete="off" id="sf1-radio" class="doc"></div></div>
<div class="row responsive-label"><div class="col-sm-12 col-md-3"><label for="sf1-textarea" class="doc">Textarea</label></div>
<div class="col-sm-12 col-md"><textarea class="doc" style="width:85%;" placeholder="Textarea"></textarea></div></div>
<div class="row responsive-label"><div class="col-sm-12 col-md-3"><label for="sf1-invalid" class="doc">Invalid</label></div>
<div class="col-sm-12 col-md"><input value="Invalid" id="sf1-invalid" style="width:85%;" class="doc"></div>
<script>document.getElementById("sf1-invalid").setCustomValidity("This field is invalid");</script></div>
<div class="row responsive-label"><div class="col-sm-12 col-md-3"><label for="sf1-disabled" class="doc">Disabled</label></div>
<div class="col-sm-12 col-md"><input disabled value="Disabled" id="sf1-disabled" style="width:85%;" class="doc"></div></div>
<div class="row responsive-label"><div class="col-sm-12 col-md-3"><label for="sf1-readonly" class="doc">Readonly</label></div>
<div class="col-sm-12 col-md"><input readonly value="Readonly" id="sf1-readonly" style="width:85%;" class="doc"></div></div>
</fieldset></form>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;form&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;fieldset&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;legend&gt;</span>Simple form<span class="highlight-a">&lt;/legend&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;username&quot;</span><span class="highlight-a">&gt;</span>Username<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;text&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;Username&quot;</span> <span class="highlight-b">placeholder</span>=<span class="highlight-c">&quot;Username&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;password&quot;</span><span class="highlight-a">&gt;</span>Password<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;password&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;password&quot;</span> <span class="highlight-b">placeholder</span>=<span class="highlight-c">&quot;Password&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/fieldset&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/form&gt;</span></span></pre>`],
notes: [
`Using the <code>&lt;fieldset&gt;</code> and <code>&lt;legend&gt;</code> elements is highly recommended, as it improves semantic markup and accessibility.`,
`Some input elements, such as date &amp; time, color and range types, are not supported and, as a result, do not have a default style defined for them. You can define said styles manually if you need to use them in your web app.`
],
customization: [
`Text color for forms and legend elements can be changed by changing the value of the <code>--form-fore-color</code> variable.`,
`Background color for forms can be changed by changing the value of the <code>--form-back-color</code> variable.`,
`Border color for forms and fieldset elements can be changed by changing the value of the <code>--form-border-color</code> variable.`,
`Text color for input elements can be changed by changing the value of the <code>--input-fore-color</code> variable.`,
`Background color for input elements can be changed by changing the value of the <code>--input-back-color</code> variable.`,
`Border color for input elements can be changed by changing the value of the <code>--input-border-color</code> variable.`,
`Border color for focused and invalid input elements can be changed by changing the value of the <code>--input-focus-color</code> and <code>--input-invalid-color</code> variables respectively.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [],
dos: [
{
description: 'Form inputs are inline by defaut, however you can combine forms with the <a href="#grid">grid system</a> to create aligned forms.',
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;form&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;fieldset&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;legend&gt;</span>Simple form<span class="highlight-a">&lt;/legend&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12 col-md-6&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;username&quot;</span><span class="highlight-a">&gt;</span>Username<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;text&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;Username&quot;</span> <span class="highlight-b">placeholder</span>=<span class="highlight-c">&quot;Username&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12 col-md-6&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;password&quot;</span><span class="highlight-a">&gt;</span>Password<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;password&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;password&quot;</span> <span class="highlight-b">placeholder</span>=<span class="highlight-c">&quot;Password&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/fieldset&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/form&gt;</span></span></pre>`
}
],
donts: []
}
module.exports = {
id: 'forms-and-input',
title: 'Forms &amp; input',
keywords: [`form`, `fieldset`, `legend`, `input`, `type`, `text`, `checkbox`, `radio`, `email`, `password`, `tel`, `input-group`, `input group`, `row`, `col`, `column`, `vertical`, `fluid`, `file`, `upload`, `select`, `textarea`, `option`, `label`],
description: `<p>Forms, labels and common HTML5 input elements have been styled using clean, modern rules, improving the accessibility and usability of your web apps' forms.</p>`,
example: `<form><fieldset><legend class="doc">Sample form</legend>
<div class="row responsive-label"><div class="col-sm-12 col-md-3"><label for="sf1-text" class="doc">Text</label></div>
<div class="col-sm-12 col-md"><input type="text" placeholder="Text" id="sf1-text" style="width:85%;" class="doc"></div></div>
<div class="row responsive-label"><div class="col-sm-12 col-md-3"><label for="sf1-pwd" class="doc">Password</label></div>
<div class="col-sm-12 col-md"><input type="password" placeholder="Password" id="sf1-pwd" style="width:85%;" class="doc"></div></div>
<div class="row responsive-label"><div class="col-sm-12 col-md-3"><label for="sf1-num" class="doc">Number</label></div>
<div class="col-sm-12 col-md"><input type="number" value="42" id="sf1-num" style="width:85%;" class="doc"></div></div>
<div class="row responsive-label"><div class="col-sm-12 col-md-3"><label for="sf1-select" class="doc">Select</label></div>
<div class="col-sm-12 col-md"><select id="sf1-select" style="width:85%;" class="doc"><option class="doc">Apples</option><option class="doc">Oranges</option></select></div></div>
<div class="row responsive-label"><div class="col-sm-12 col-md-3"><label for="sf1-check" class="doc">Checkbox</label></div>
<div class="col-sm-12 col-md"><input type="checkbox" autocomplete="off" id="sf1-check" class="doc"></div></div>
<div class="row responsive-label"><div class="col-sm-12 col-md-3"><label for="sf1-radio" class="doc">Radio</label></div>
<div class="col-sm-12 col-md"><input type="radio" autocomplete="off" id="sf1-radio" class="doc"></div></div>
<div class="row responsive-label"><div class="col-sm-12 col-md-3"><label for="sf1-textarea" class="doc">Textarea</label></div>
<div class="col-sm-12 col-md"><textarea class="doc" style="width:85%;" placeholder="Textarea"></textarea></div></div>
<div class="row responsive-label"><div class="col-sm-12 col-md-3"><label for="sf1-invalid" class="doc">Invalid</label></div>
<div class="col-sm-12 col-md"><input value="Invalid" id="sf1-invalid" style="width:85%;" class="doc"></div>
<script>document.getElementById("sf1-invalid").setCustomValidity("This field is invalid");</script></div>
<div class="row responsive-label"><div class="col-sm-12 col-md-3"><label for="sf1-disabled" class="doc">Disabled</label></div>
<div class="col-sm-12 col-md"><input disabled value="Disabled" id="sf1-disabled" style="width:85%;" class="doc"></div></div>
<div class="row responsive-label"><div class="col-sm-12 col-md-3"><label for="sf1-readonly" class="doc">Readonly</label></div>
<div class="col-sm-12 col-md"><input readonly value="Readonly" id="sf1-readonly" style="width:85%;" class="doc"></div></div>
</fieldset></form>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;form&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;fieldset&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;legend&gt;</span>Simple form<span class="highlight-a">&lt;/legend&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;username&quot;</span><span class="highlight-a">&gt;</span>Username<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;text&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;Username&quot;</span> <span class="highlight-b">placeholder</span>=<span class="highlight-c">&quot;Username&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;password&quot;</span><span class="highlight-a">&gt;</span>Password<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;password&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;password&quot;</span> <span class="highlight-b">placeholder</span>=<span class="highlight-c">&quot;Password&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/fieldset&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/form&gt;</span></span></pre>`],
notes: [
`Using the <code>&lt;fieldset&gt;</code> and <code>&lt;legend&gt;</code> elements is highly recommended, as it improves semantic markup and accessibility.`,
`Some input elements, such as date &amp; time, color and range types, are not supported and, as a result, do not have a default style defined for them. You can define said styles manually if you need to use them in your web app.`
],
customization: [
`Text color for forms and legend elements can be changed by changing the value of the <code>--form-fore-color</code> variable.`,
`Background color for forms can be changed by changing the value of the <code>--form-back-color</code> variable.`,
`Border color for forms and fieldset elements can be changed by changing the value of the <code>--form-border-color</code> variable.`,
`Text color for input elements can be changed by changing the value of the <code>--input-fore-color</code> variable.`,
`Background color for input elements can be changed by changing the value of the <code>--input-back-color</code> variable.`,
`Border color for input elements can be changed by changing the value of the <code>--input-border-color</code> variable.`,
`Border color for focused and invalid input elements can be changed by changing the value of the <code>--input-focus-color</code> and <code>--input-invalid-color</code> variables respectively.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [],
dos: [
{
description: 'Form inputs are inline by defaut, however you can combine forms with the <a href="#grid">grid system</a> to create aligned forms.',
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;form&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;fieldset&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;legend&gt;</span>Simple form<span class="highlight-a">&lt;/legend&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12 col-md-6&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;username&quot;</span><span class="highlight-a">&gt;</span>Username<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;text&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;Username&quot;</span> <span class="highlight-b">placeholder</span>=<span class="highlight-c">&quot;Username&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12 col-md-6&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;password&quot;</span><span class="highlight-a">&gt;</span>Password<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;password&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;password&quot;</span> <span class="highlight-b">placeholder</span>=<span class="highlight-c">&quot;Password&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/fieldset&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/form&gt;</span></span></pre>`
}
],
donts: []
}

View file

@ -1,29 +1,29 @@
var version = require('../vinf').version;
module.exports = {
id: 'getting-started',
title: 'Getting started',
keywords: ['html', 'viewport', 'head', 'meta', 'getting started', 'introduction', 'browser support', 'installation', 'usage', 'setup', 'cdn', 'npm', 'yarn'],
description: `<p>You can get started using <strong>mini.css</strong> in one of many ways. It is published on <strong>npm</strong> and <strong>yarn</strong>, so you can easily download it, using your preferred package manager:</p>
<div class="row"><div class="col-sm-12 col-md"><pre>npm install mini.css</pre></div><div class="col-sm-12 col-md"><pre>yarn add mini.css</pre></div></div>
<br/><p>Alternatively, you can use either <strong>rawgit</strong> or <strong>cdnjs</strong> to import <strong>mini.css</strong> into your HTML page's <code>&lt;head&gt;</code> tag:</p>
<pre>&lt;link rel=&quot;stylesheet&quot; href=&quot;https://cdn.rawgit.com/Chalarangelo/mini.css/${version}/dist/mini-default.min.css&quot;&gt;</pre>
<pre>&lt;link rel=&quot;stylesheet&quot; href=&quot;https://cdnjs.cloudflare.com/ajax/libs/mini.css/${version}/mini-default.min.css&quot;&gt;</pre>
<br/><p>After adding <strong>mini.css</strong> to your project, remember to also add the following line inside your HTML page's <code>&lt;head&gt;</code> tag to utilize the viewport meta tag:</p>
<pre>&lt;meta name=&quot;viewport&quot; content=&quot;width=device-width, initial-scale=1&quot;&gt;</pre>
<br/><p><strong>mini.css</strong> is crafted with long-term support in mind, so expect it to be compatible with all modern browsers, as well as their future versions. However, most legacy and proxy browsers, such as Internet Explorer, Opera Mini, IE Mobile and UC Browser are not officially supported, meaning certain features may not be displayed properly or behave exactly as expected.</p><br/>
<figure class="container"><div class="row">
<div class="col-sm" style="text-align:center; background: #35BCE6; padding: 1rem;"><img src="browser-logos/edge_128x128.png" alt="edge"><br/><h3><small>&nbsp;&nbsp;Edge<sup style="-0.675em"><i class="fa fa-lg fa-exclamation" aria-hidden="true" style="font-size: 80%;"></i></sup></small>15</h3></div>
<div class="col-sm" style="text-align:center; background: #FF742E; padding: 1rem;"><img src="browser-logos/firefox_128x128.png" alt="firefox"><br/><h3><small>&nbsp;Firefox</small>35</h3></div>
<div class="col-sm" style="text-align:center; background: #FFE270; padding: 1rem;"><img src="browser-logos/chrome_128x128.png" alt="chrome"><br/><h3><small>&nbsp;Chrome</small>49</h3></div>
<div class="col-sm" style="text-align:center; background: #00D0FF; padding: 1rem;"><img src="browser-logos/safari_128x128.png" alt="safari"><br/><h3><small>&nbsp;Safari</small>9.1</h3></div>
<div class="col-sm" style="text-align:center; background: #FF6E6E; padding: 1rem;"><img src="browser-logos/opera_128x128.png" alt="opera"><br/><h3><small>&nbsp;Opera</small>36</h3></div>
<div class="col-sm" style="text-align:center; background: #0F98E0; padding: 1rem;"><img src="browser-logos/android_128x128.png" alt="android"><br/><h3><small>&nbsp;Android</small>56</h3></div>
</div><figcaption>Browser versions officially supported</figcaption></figure><br/>`,
example: '',
samples: [],
notes: [],
customization: [],
modifiers: [],
dos: [],
donts: []
}
var version = require('../vinf').version;
module.exports = {
id: 'getting-started',
title: 'Getting started',
keywords: ['html', 'viewport', 'head', 'meta', 'getting started', 'introduction', 'browser support', 'installation', 'usage', 'setup', 'cdn', 'npm', 'yarn'],
description: `<p>You can get started using <strong>mini.css</strong> in one of many ways. It is published on <strong>npm</strong> and <strong>yarn</strong>, so you can easily download it, using your preferred package manager:</p>
<div class="row"><div class="col-sm-12 col-md"><pre>npm install mini.css</pre></div><div class="col-sm-12 col-md"><pre>yarn add mini.css</pre></div></div>
<br/><p>Alternatively, you can use either <strong>rawgit</strong> or <strong>cdnjs</strong> to import <strong>mini.css</strong> into your HTML page's <code>&lt;head&gt;</code> tag:</p>
<pre>&lt;link rel=&quot;stylesheet&quot; href=&quot;https://cdn.rawgit.com/Chalarangelo/mini.css/${version}/dist/mini-default.min.css&quot;&gt;</pre>
<pre>&lt;link rel=&quot;stylesheet&quot; href=&quot;https://cdnjs.cloudflare.com/ajax/libs/mini.css/${version}/mini-default.min.css&quot;&gt;</pre>
<br/><p>After adding <strong>mini.css</strong> to your project, remember to also add the following line inside your HTML page's <code>&lt;head&gt;</code> tag to utilize the viewport meta tag:</p>
<pre>&lt;meta name=&quot;viewport&quot; content=&quot;width=device-width, initial-scale=1&quot;&gt;</pre>
<br/><p><strong>mini.css</strong> is crafted with long-term support in mind, so expect it to be compatible with all modern browsers, as well as their future versions. However, most legacy and proxy browsers, such as Internet Explorer, Opera Mini, IE Mobile and UC Browser are not officially supported, meaning certain features may not be displayed properly or behave exactly as expected.</p><br/>
<figure class="container"><div class="row">
<div class="col-sm" style="text-align:center; background: #35BCE6; padding: 1rem;"><img src="browser-logos/edge_128x128.png" alt="edge"><br/><h3><small>&nbsp;&nbsp;Edge<sup style="-0.675em"><i class="fa fa-lg fa-exclamation" aria-hidden="true" style="font-size: 80%;"></i></sup></small>15</h3></div>
<div class="col-sm" style="text-align:center; background: #FF742E; padding: 1rem;"><img src="browser-logos/firefox_128x128.png" alt="firefox"><br/><h3><small>&nbsp;Firefox</small>35</h3></div>
<div class="col-sm" style="text-align:center; background: #FFE270; padding: 1rem;"><img src="browser-logos/chrome_128x128.png" alt="chrome"><br/><h3><small>&nbsp;Chrome</small>49</h3></div>
<div class="col-sm" style="text-align:center; background: #00D0FF; padding: 1rem;"><img src="browser-logos/safari_128x128.png" alt="safari"><br/><h3><small>&nbsp;Safari</small>9.1</h3></div>
<div class="col-sm" style="text-align:center; background: #FF6E6E; padding: 1rem;"><img src="browser-logos/opera_128x128.png" alt="opera"><br/><h3><small>&nbsp;Opera</small>36</h3></div>
<div class="col-sm" style="text-align:center; background: #0F98E0; padding: 1rem;"><img src="browser-logos/android_128x128.png" alt="android"><br/><h3><small>&nbsp;Android</small>56</h3></div>
</div><figcaption>Browser versions officially supported</figcaption></figure><br/>`,
example: '',
samples: [],
notes: [],
customization: [],
modifiers: [],
dos: [],
donts: []
}

View file

@ -1,245 +1,245 @@
module.exports = {
id: 'grid',
title: 'Grid system',
keywords: [`grid`, `grid system`, `col`, `column`, `layout`, `row`, `container`, `small`, `medium`, `large`, `sm`, `md`, `lg`, `cols`, `predefined`, `offset`, `order`, `reorder`, `first`, `last`, `normal`],
description: `<p>The grid system of <strong>mini.css</strong> utilizes the <a href="https://css-tricks.com/snippets/css/a-guide-to-flexbox/" target="_blank">Flexbox layout</a> to provide you with a simple, modern, responsive layout system for your web apps. Like most modern CSS frameworks' grid systems, it is composed of three main components - containers, rows and columns:</p>
<ul><li>The container (<code>.container</code>) is the outermost layer of the grid system and serves as a fluid wrapper, which can be used as the basis for your layout.</li>
<li>Inside the container, you can add one or more rows (<code>.row</code>), which will in turn house the columns.</li>
<li>Columns (<code>col-*-*</code>) are placed inside rows and they can be customized to display differently on different screen sizes, make use of fluid layouts, use offsets or change ordering.</li></ul>`,
example: `<div class="container" style="padding: 0.25rem">
<div class="row"><div class="col-sm-1"><div class="box-colored">1</div></div><div class="col-sm-11"><div class="box-colored">11</div></div></div>
<div class="row"><div class="col-sm-2"><div class="box-colored">2</div></div><div class="col-sm-10"><div class="box-colored">10</div></div></div>
<div class="row"><div class="col-sm-3"><div class="box-colored">3</div></div><div class="col-sm-9"><div class="box-colored">9</div></div></div>
<div class="row"><div class="col-sm-4"><div class="box-colored">4</div></div><div class="col-sm-8"><div class="box-colored">8</div></div></div>
<div class="row"><div class="col-sm-5"><div class="box-colored">5</div></div><div class="col-sm-7"><div class="box-colored">7</div></div></div>
<div class="row"><div class="col-sm-6"><div class="box-colored">6</div></div><div class="col-sm-6"><div class="box-colored">6</div></div></div>
<div class="row"><div class="col-sm-12"><div class="box-colored">12</div></div></div>
<div class="row"><div class="col-sm"><div class="box-colored">fluid</div></div><div class="col-sm"><div class="box-colored">fluid</div></div></div>
</div>`,
samples: [`
<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;container&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-1&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-11&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-2&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-10&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-3&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-9&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-4&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-8&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-5&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-7&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-6&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-6&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>
`,
`<p>You can use the grid system to create a responsive <a href="https://www.stubbornella.org/content/2010/06/25/the-media-object-saves-hundreds-of-lines-of-code/" target="_blank">media object</a> in one of many ways. Below is a simple example of a two-column media object with an image and some text:
<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-2&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;img</span> <span class="highlight-b">src</span>=<span class="highlight-c">&quot;image.png&quot;</span> <span class="highlight-b">alt</span>=<span class="highlight-c">&quot;Image description&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;h2&gt;</span>Media object heading<span class="highlight-a">&lt;/h2&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>Media object content...<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
],
notes: [
`<strong>mini.css</strong> uses a mobile-first approach in its grid system, so you do not have to rewrite the same layout for all three screen sizes. Leaving a column's size, offset or order unspecified for a screen size will use the style applied for the previous largest screen size recursively. This also applies to predefined layouts.`,
`The specific breakpoints for small, medium and large screen sizes are as follows:
<ul>
<li>small: less than <code>768px</code> wide</li>
<li>medium: more than or equal to <code>768px</code> wide and less than <code>1280px</code> wide</li>
<li>large: <code>1280px</code> wide or more</li>
</ul>`,
`In many cases, you can omit the container and just use rows and columns. You only need to make sure that all of your rows have the same parent element.`,
`You can use fluid columns to create columns whose width is not a multiple of 1/12th of the screen's width (e.g. if you have 7 fluid columns in a row, each one of them will be 1/7th of the screen's width).`,
`Predefined layouts can be combined with most of the features of the grid system, such as offsets and reordering, however they do not combine very well with regular columns.`,
`You should only apply offset and reordering modifiers to the columns that you need and for the screen sizes that are necessary. Remember to also specify a column width or use a predefined layout before applying these modifiers.`
],
customization: [
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable. This only affects the padding of the container.`
],
modifiers: [
{
title: `Screen sizes and width`,
description: `<p>Each column class is defined by specifying a screen size (small - <code>sm</code>, medium - <code>md</code> or large - <code>lg</code>) and a column width (a value between <code>1</code> and <code>12</code> or you can omit it for a fluid column), separated by dashes (e.g. <code>.col-sm-6</code> for a 6-wide column on a small screen). Using these you can apply different layouts for different screen sizes, by altering the width of columns, using multiple classes. Note that column widths are applied recursively, meaning that if you do not specify a width for a specific screen size the column will use the width applied for the previous largest screen size.</p>`,
example: `<div class="container" style="padding: 0.25rem">
<div class="row">
<div class="col-sm-12 col-md">
<div class="row"><div class="col-sm"><h6 style="text-align:center">Small screen layout</h6></div></div>
<div class="row"><div class="col-sm"><div class="box-colored">sm-12</div></div></div>
<div class="row"><div class="col-sm-12"><div class="box-colored" style="height: 3.75rem">sm-12 md-8</div></div><div class="col-sm-12"><div class="box-colored" style="height: 2rem">sm-12 md-4</div></div></div>
<div class="row"><div class="col-sm"><div class="box-colored">sm-12</div></div></div>
</div>
<div class="col-sm-12 col-md">
<div class="row"><div class="col-sm"><h6 style="text-align:center">Medium/Large screen layout</h6></div></div>
<div class="row"><div class="col-sm"><div class="box-colored">sm-12</div></div></div>
<div class="row"><div class="col-sm-8"><div class="box-colored" style="height: 8rem">sm-12 md-8</div></div><div class="col-sm-4"><div class="box-colored" style="height: 8rem">sm-12 md-4</div></div></div>
<div class="row"><div class="col-sm"><div class="box-colored">sm-12</div></div></div>
</div>
</div>
</div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;container&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12 col-md-3 col-lg-2&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12 col-md-5 col-lg-7&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12 col-md-4 col-lg-3&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span>&gt;</span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm col-lg-10&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-4 col-md&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`]
},
{
title: `Predefined layouts`,
description: `<p>Rows can be modified to apply predefined layouts to the columns inside them, effectively reducing the amount of work required for simple layouts. To create a predefined layout, you can add a class to a row (<code>.cols-*-*</code>), specifying a screen size and width for the columns inside it (or omitting the width for fluid columns), similarly to the way columns are defined (e.g. <code>.row.cols-sm-6</code> will cause all elements inside the row to be 6-wide on a small screen). Columns inside a predefined layout do not require any further classes to display and, much like normal column layouts, their widths are applied recursively.</p>`,
example: '',
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row cols-sm-6&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>This paragraph is inside a 6-wide column.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>This paragraph is inside a 6-wide column.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`]
},
{
title: `Column offsets`,
description: `<p>Columns can be moved to the right, by applying offset classes (<code>.col-*-offset-*</code>), defining a screen size and an offset (a value between <code>0</code> and <code>11</code>, e.g. <code>.col-sm-offset-3</code> will move a column 25% to the right on a small screen). Like all other column modifiers, offsets are applied recursively.</p>`,
example: `<div class="container" style="padding: 0.25rem">
<div class="row"><div class="col-sm col-sm-offset-11"><div class="box-colored">11</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-10"><div class="box-colored">10</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-9"><div class="box-colored">9</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-8"><div class="box-colored">8</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-7"><div class="box-colored">7</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-6"><div class="box-colored">6</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-5"><div class="box-colored">5</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-4"><div class="box-colored">4</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-3"><div class="box-colored">3</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-2"><div class="box-colored">2</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-1"><div class="box-colored">1</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-0"><div class="box-colored">0</div></div></div>
</div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-8 col-sm-offset-2 col-md-offset-1 col-lg-offset-0&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm col-sm-offset-3 col-md-offset-4 col-lg-offset-0&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-4 col-md-offset-5&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`]
},
{
title: `Column reordering`,
description: `<p>Columns can be reordered on different screen sizes, by applying a reordering class (<code>.col-*-*</code>), defining a screen size and the order (first, normal or last, e.g. <code>.col-sm-last</code> will move a column to the end of its row on a small screen). Like all other column modifiers, reordering is applied recursively.</p>`,
example: `<div class="container" style="padding: 0.25rem">
<div class="row">
<div class="col-sm-12 col-md">
<div class="row"><div class="col-sm"><h6 style="text-align:center">Small screen layout</h6></div></div>
<div class="row"><div class="col-sm-4"><div class="box-colored">md-last</div></div><div class="col-sm-4"><div class="box-colored">&nbsp;</div></div><div class="col-sm-4"><div class="box-colored">md-first</div></div></div>
</div>
<div class="col-sm-12 col-md">
<div class="row"><div class="col-sm"><h6 style="text-align:center">Medium/Large screen layout</h6></div></div>
<div class="row"><div class="col-sm-4"><div class="box-colored">md-first</div></div><div class="col-sm-4"><div class="box-colored">&nbsp;</div></div><div class="col-sm-4"><div class="box-colored">md-last</div></div></div>
</div>
</div>
</div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm col-md-last col-lg-normal&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm col-sm-first col-md-last&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm col-md-first col-lg-normal&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`]
}
],
dos: [
{
description: `A column can contain a container or a row inside it, or even be a row at the same time. In the latter case, it will act as a column for its parent row and as a row for its children.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-3&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;container&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-3&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-3 row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-6&quot;</span><span class="highlight-a">&gt;&lt;/div&gt; &lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-6&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
},
{
description: `You can mix fluid columns with fixed, if you like. Fluid columns will adapt to the size of the container left for them. You can also use columns whose total width exceeds <code>12</code> (100%). The remaining content will flow below the rest, allowing you to specify multiple blocks of content inside the same row if you need to.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm&quot;</span><span class="highlight-a">&gt;&lt;/div&gt; &lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-4&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
},
{
description: `You can change the layout of your content for different displays, laying out your content vertically on smaller screens or horizontally on larger screens. If your columns exceed a total width of <code>12</code> (100%) on some displays, they will wrap accordingly.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12 col-md-6&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12 col-md-6&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
},
{
description: `You do not need to specify a column's width or reapply offset and reordering modifiers if they are the same as the previous screen size.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm col-lg-3 col-md-last&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-6 col-md-offset-2&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
},
{
description: `You can add multiple predefined layout classes for different screen sizes, allowing you to build responsive predefined layouts.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row cols-sm-12 cols-md-6&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;&lt;/div&gt;</span> <span class="highlight-a">&lt;div&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
},
{
description: `To remove a previously applied offset from a column (i.e. one applied from the layout from a smaller screen size) or to make sure no offsets are active on a column, you can set its offset to <code>0</code> for a specific screen size. Similarly, to remove previously applied reordering modifiers from a column, you can set its order to <code>normal</code>.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-8 col-sm-offset-1 col-md-offset-0&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-last col-md-normal&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
}
],
donts: [
{
description: `Avoid placing a column directly inside another column. Always use a row to wrap columns, instead.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
},
{
description: `Avoid mixing rows and columns with normal content that is not wrapped on the respective level of the grid layout.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;container&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>Do not do this.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>Do not do this.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
},
{
description: `Never omit the class that specifies a column's width for the small screen size. You can omit all other classes and modifiers, except for this. This also applies to predefined layouts.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-md&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row cols-md&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span></pre>`
},
{
description: `Avoid combining normal column width modifiers with predefined layouts, as the predefined layout will most likely override the width modifier of the column.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row cols-sm-6&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row cols-sm-4&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
}
]
}
module.exports = {
id: 'grid',
title: 'Grid system',
keywords: [`grid`, `grid system`, `col`, `column`, `layout`, `row`, `container`, `small`, `medium`, `large`, `sm`, `md`, `lg`, `cols`, `predefined`, `offset`, `order`, `reorder`, `first`, `last`, `normal`],
description: `<p>The grid system of <strong>mini.css</strong> utilizes the <a href="https://css-tricks.com/snippets/css/a-guide-to-flexbox/" target="_blank">Flexbox layout</a> to provide you with a simple, modern, responsive layout system for your web apps. Like most modern CSS frameworks' grid systems, it is composed of three main components - containers, rows and columns:</p>
<ul><li>The container (<code>.container</code>) is the outermost layer of the grid system and serves as a fluid wrapper, which can be used as the basis for your layout.</li>
<li>Inside the container, you can add one or more rows (<code>.row</code>), which will in turn house the columns.</li>
<li>Columns (<code>col-*-*</code>) are placed inside rows and they can be customized to display differently on different screen sizes, make use of fluid layouts, use offsets or change ordering.</li></ul>`,
example: `<div class="container" style="padding: 0.25rem">
<div class="row"><div class="col-sm-1"><div class="box-colored">1</div></div><div class="col-sm-11"><div class="box-colored">11</div></div></div>
<div class="row"><div class="col-sm-2"><div class="box-colored">2</div></div><div class="col-sm-10"><div class="box-colored">10</div></div></div>
<div class="row"><div class="col-sm-3"><div class="box-colored">3</div></div><div class="col-sm-9"><div class="box-colored">9</div></div></div>
<div class="row"><div class="col-sm-4"><div class="box-colored">4</div></div><div class="col-sm-8"><div class="box-colored">8</div></div></div>
<div class="row"><div class="col-sm-5"><div class="box-colored">5</div></div><div class="col-sm-7"><div class="box-colored">7</div></div></div>
<div class="row"><div class="col-sm-6"><div class="box-colored">6</div></div><div class="col-sm-6"><div class="box-colored">6</div></div></div>
<div class="row"><div class="col-sm-12"><div class="box-colored">12</div></div></div>
<div class="row"><div class="col-sm"><div class="box-colored">fluid</div></div><div class="col-sm"><div class="box-colored">fluid</div></div></div>
</div>`,
samples: [`
<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;container&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-1&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-11&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-2&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-10&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-3&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-9&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-4&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-8&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-5&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-7&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-6&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-6&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>
`,
`<p>You can use the grid system to create a responsive <a href="https://www.stubbornella.org/content/2010/06/25/the-media-object-saves-hundreds-of-lines-of-code/" target="_blank">media object</a> in one of many ways. Below is a simple example of a two-column media object with an image and some text:
<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-2&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;img</span> <span class="highlight-b">src</span>=<span class="highlight-c">&quot;image.png&quot;</span> <span class="highlight-b">alt</span>=<span class="highlight-c">&quot;Image description&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;h2&gt;</span>Media object heading<span class="highlight-a">&lt;/h2&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>Media object content...<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
],
notes: [
`<strong>mini.css</strong> uses a mobile-first approach in its grid system, so you do not have to rewrite the same layout for all three screen sizes. Leaving a column's size, offset or order unspecified for a screen size will use the style applied for the previous largest screen size recursively. This also applies to predefined layouts.`,
`The specific breakpoints for small, medium and large screen sizes are as follows:
<ul>
<li>small: less than <code>768px</code> wide</li>
<li>medium: more than or equal to <code>768px</code> wide and less than <code>1280px</code> wide</li>
<li>large: <code>1280px</code> wide or more</li>
</ul>`,
`In many cases, you can omit the container and just use rows and columns. You only need to make sure that all of your rows have the same parent element.`,
`You can use fluid columns to create columns whose width is not a multiple of 1/12th of the screen's width (e.g. if you have 7 fluid columns in a row, each one of them will be 1/7th of the screen's width).`,
`Predefined layouts can be combined with most of the features of the grid system, such as offsets and reordering, however they do not combine very well with regular columns.`,
`You should only apply offset and reordering modifiers to the columns that you need and for the screen sizes that are necessary. Remember to also specify a column width or use a predefined layout before applying these modifiers.`
],
customization: [
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable. This only affects the padding of the container.`
],
modifiers: [
{
title: `Screen sizes and width`,
description: `<p>Each column class is defined by specifying a screen size (small - <code>sm</code>, medium - <code>md</code> or large - <code>lg</code>) and a column width (a value between <code>1</code> and <code>12</code> or you can omit it for a fluid column), separated by dashes (e.g. <code>.col-sm-6</code> for a 6-wide column on a small screen). Using these you can apply different layouts for different screen sizes, by altering the width of columns, using multiple classes. Note that column widths are applied recursively, meaning that if you do not specify a width for a specific screen size the column will use the width applied for the previous largest screen size.</p>`,
example: `<div class="container" style="padding: 0.25rem">
<div class="row">
<div class="col-sm-12 col-md">
<div class="row"><div class="col-sm"><h6 style="text-align:center">Small screen layout</h6></div></div>
<div class="row"><div class="col-sm"><div class="box-colored">sm-12</div></div></div>
<div class="row"><div class="col-sm-12"><div class="box-colored" style="height: 3.75rem">sm-12 md-8</div></div><div class="col-sm-12"><div class="box-colored" style="height: 2rem">sm-12 md-4</div></div></div>
<div class="row"><div class="col-sm"><div class="box-colored">sm-12</div></div></div>
</div>
<div class="col-sm-12 col-md">
<div class="row"><div class="col-sm"><h6 style="text-align:center">Medium/Large screen layout</h6></div></div>
<div class="row"><div class="col-sm"><div class="box-colored">sm-12</div></div></div>
<div class="row"><div class="col-sm-8"><div class="box-colored" style="height: 8rem">sm-12 md-8</div></div><div class="col-sm-4"><div class="box-colored" style="height: 8rem">sm-12 md-4</div></div></div>
<div class="row"><div class="col-sm"><div class="box-colored">sm-12</div></div></div>
</div>
</div>
</div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;container&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12 col-md-3 col-lg-2&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12 col-md-5 col-lg-7&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12 col-md-4 col-lg-3&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span>&gt;</span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm col-lg-10&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-4 col-md&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`]
},
{
title: `Predefined layouts`,
description: `<p>Rows can be modified to apply predefined layouts to the columns inside them, effectively reducing the amount of work required for simple layouts. To create a predefined layout, you can add a class to a row (<code>.cols-*-*</code>), specifying a screen size and width for the columns inside it (or omitting the width for fluid columns), similarly to the way columns are defined (e.g. <code>.row.cols-sm-6</code> will cause all elements inside the row to be 6-wide on a small screen). Columns inside a predefined layout do not require any further classes to display and, much like normal column layouts, their widths are applied recursively.</p>`,
example: '',
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row cols-sm-6&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>This paragraph is inside a 6-wide column.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>This paragraph is inside a 6-wide column.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`]
},
{
title: `Column offsets`,
description: `<p>Columns can be moved to the right, by applying offset classes (<code>.col-*-offset-*</code>), defining a screen size and an offset (a value between <code>0</code> and <code>11</code>, e.g. <code>.col-sm-offset-3</code> will move a column 25% to the right on a small screen). Like all other column modifiers, offsets are applied recursively.</p>`,
example: `<div class="container" style="padding: 0.25rem">
<div class="row"><div class="col-sm col-sm-offset-11"><div class="box-colored">11</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-10"><div class="box-colored">10</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-9"><div class="box-colored">9</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-8"><div class="box-colored">8</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-7"><div class="box-colored">7</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-6"><div class="box-colored">6</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-5"><div class="box-colored">5</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-4"><div class="box-colored">4</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-3"><div class="box-colored">3</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-2"><div class="box-colored">2</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-1"><div class="box-colored">1</div></div></div>
<div class="row"><div class="col-sm col-sm-offset-0"><div class="box-colored">0</div></div></div>
</div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-8 col-sm-offset-2 col-md-offset-1 col-lg-offset-0&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm col-sm-offset-3 col-md-offset-4 col-lg-offset-0&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-4 col-md-offset-5&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`]
},
{
title: `Column reordering`,
description: `<p>Columns can be reordered on different screen sizes, by applying a reordering class (<code>.col-*-*</code>), defining a screen size and the order (first, normal or last, e.g. <code>.col-sm-last</code> will move a column to the end of its row on a small screen). Like all other column modifiers, reordering is applied recursively.</p>`,
example: `<div class="container" style="padding: 0.25rem">
<div class="row">
<div class="col-sm-12 col-md">
<div class="row"><div class="col-sm"><h6 style="text-align:center">Small screen layout</h6></div></div>
<div class="row"><div class="col-sm-4"><div class="box-colored">md-last</div></div><div class="col-sm-4"><div class="box-colored">&nbsp;</div></div><div class="col-sm-4"><div class="box-colored">md-first</div></div></div>
</div>
<div class="col-sm-12 col-md">
<div class="row"><div class="col-sm"><h6 style="text-align:center">Medium/Large screen layout</h6></div></div>
<div class="row"><div class="col-sm-4"><div class="box-colored">md-first</div></div><div class="col-sm-4"><div class="box-colored">&nbsp;</div></div><div class="col-sm-4"><div class="box-colored">md-last</div></div></div>
</div>
</div>
</div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm col-md-last col-lg-normal&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm col-sm-first col-md-last&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm col-md-first col-lg-normal&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`]
}
],
dos: [
{
description: `A column can contain a container or a row inside it, or even be a row at the same time. In the latter case, it will act as a column for its parent row and as a row for its children.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-3&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;container&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-3&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-3 row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-6&quot;</span><span class="highlight-a">&gt;&lt;/div&gt; &lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-6&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
},
{
description: `You can mix fluid columns with fixed, if you like. Fluid columns will adapt to the size of the container left for them. You can also use columns whose total width exceeds <code>12</code> (100%). The remaining content will flow below the rest, allowing you to specify multiple blocks of content inside the same row if you need to.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm&quot;</span><span class="highlight-a">&gt;&lt;/div&gt; &lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-4&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
},
{
description: `You can change the layout of your content for different displays, laying out your content vertically on smaller screens or horizontally on larger screens. If your columns exceed a total width of <code>12</code> (100%) on some displays, they will wrap accordingly.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12 col-md-6&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-12 col-md-6&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
},
{
description: `You do not need to specify a column's width or reapply offset and reordering modifiers if they are the same as the previous screen size.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm col-lg-3 col-md-last&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-6 col-md-offset-2&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
},
{
description: `You can add multiple predefined layout classes for different screen sizes, allowing you to build responsive predefined layouts.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row cols-sm-12 cols-md-6&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;&lt;/div&gt;</span> <span class="highlight-a">&lt;div&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
},
{
description: `To remove a previously applied offset from a column (i.e. one applied from the layout from a smaller screen size) or to make sure no offsets are active on a column, you can set its offset to <code>0</code> for a specific screen size. Similarly, to remove previously applied reordering modifiers from a column, you can set its order to <code>normal</code>.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-8 col-sm-offset-1 col-md-offset-0&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm-last col-md-normal&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
}
],
donts: [
{
description: `Avoid placing a column directly inside another column. Always use a row to wrap columns, instead.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
},
{
description: `Avoid mixing rows and columns with normal content that is not wrapped on the respective level of the grid layout.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;container&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>Do not do this.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>Do not do this.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
},
{
description: `Never omit the class that specifies a column's width for the small screen size. You can omit all other classes and modifiers, except for this. This also applies to predefined layouts.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-md&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row cols-md&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span></pre>`
},
{
description: `Avoid combining normal column width modifiers with predefined layouts, as the predefined layout will most likely override the width modifier of the column.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row cols-sm-6&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;row cols-sm-4&quot;</span><span class="highlight-a">&gt;&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
}
]
}

View file

@ -1,46 +1,46 @@
module.exports = {
id: 'header',
title: 'Header',
keywords: [`navigation`, `header`, `sticky`, `button`, `logo`, `link`],
description: `<p>The header element has been minimally styled, allowing you to create modern headers for your web apps. A header can include a logo element (<code>.logo</code>), as well as buttons, links and labels, styled as buttons (<code>.button</code>).</p>`,
example: `<header>
<a href="#" class="logo" class="doc">Logo</a> <button class="doc">Home</button>
<a href="#" class="button doc">News</a>
<button class="doc">About</button> <button class="doc">Contact</button>
</header>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;header&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;logo&quot;</span><span class="highlight-a">&gt;</span>Logo<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;button&quot;</span><span class="highlight-a">&gt;</span>Home<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;button&gt;</span>Download<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/header&gt;</span></span></pre>`],
notes: [`The header element is partially responsive on smaller screens, displaying a scrollbar indicating that there is more content off-screen.`,
`The header element can be a row in a <a href="grid">grid system</a>, allowing you to create responsive headers.`],
customization: [
`Text color for the header can be changed by changing the value of the <code>--header-fore-color</code> variable.`,
`Background color for the header can be changed by changing the value of the <code>--header-back-color</code> variable.`,
`Border color for the header can be changed by changing the value of the <code>--header-border-color</code> variable.`,
`Background color for focused buttons inside the header can be changed by changing the value of the <code>--header-hover-back-color</code> variable.`
],
modifiers: [
{
title : 'Sticky header',
description: `<p>You can make your web app's header sticky (<code>.sticky</code>), by applying the appropriate modifier.</p>`,
example: '',
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;header</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;sticky&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;logo&quot;</span><span class="highlight-a">&gt;</span>Logo<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;button&quot;</span><span class="highlight-a">&gt;</span>Home<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;button&gt;</span>Download<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/header&gt;</span></span></pre>`]
}
],
dos: [],
donts: [
{
description: `You should not apply a <code>.button</code> class to the logo of your header, but you must make sure that all other elements inside the header are styled as buttons.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;header&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;button logo&quot;</span><span class="highlight-a">&gt;</span>Logo<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span><span class="highlight-a">&gt;</span>Home<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/header&gt;</span></span></pre>`
}
]
}
module.exports = {
id: 'header',
title: 'Header',
keywords: [`navigation`, `header`, `sticky`, `button`, `logo`, `link`],
description: `<p>The header element has been minimally styled, allowing you to create modern headers for your web apps. A header can include a logo element (<code>.logo</code>), as well as buttons, links and labels, styled as buttons (<code>.button</code>).</p>`,
example: `<header>
<a href="#" class="logo" class="doc">Logo</a> <button class="doc">Home</button>
<a href="#" class="button doc">News</a>
<button class="doc">About</button> <button class="doc">Contact</button>
</header>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;header&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;logo&quot;</span><span class="highlight-a">&gt;</span>Logo<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;button&quot;</span><span class="highlight-a">&gt;</span>Home<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;button&gt;</span>Download<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/header&gt;</span></span></pre>`],
notes: [`The header element is partially responsive on smaller screens, displaying a scrollbar indicating that there is more content off-screen.`,
`The header element can be a row in a <a href="grid">grid system</a>, allowing you to create responsive headers.`],
customization: [
`Text color for the header can be changed by changing the value of the <code>--header-fore-color</code> variable.`,
`Background color for the header can be changed by changing the value of the <code>--header-back-color</code> variable.`,
`Border color for the header can be changed by changing the value of the <code>--header-border-color</code> variable.`,
`Background color for focused buttons inside the header can be changed by changing the value of the <code>--header-hover-back-color</code> variable.`
],
modifiers: [
{
title : 'Sticky header',
description: `<p>You can make your web app's header sticky (<code>.sticky</code>), by applying the appropriate modifier.</p>`,
example: '',
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;header</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;sticky&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;logo&quot;</span><span class="highlight-a">&gt;</span>Logo<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;button&quot;</span><span class="highlight-a">&gt;</span>Home<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;button&gt;</span>Download<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/header&gt;</span></span></pre>`]
}
],
dos: [],
donts: [
{
description: `You should not apply a <code>.button</code> class to the logo of your header, but you must make sure that all other elements inside the header are styled as buttons.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;header&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;button logo&quot;</span><span class="highlight-a">&gt;</span>Logo<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span><span class="highlight-a">&gt;</span>Home<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/header&gt;</span></span></pre>`
}
]
}

View file

@ -1,31 +1,31 @@
module.exports = {
id: 'heading',
title: 'Headings',
keywords: [`heading`, `h1`, `h2`, `h3`, `h4`, `h5`, `h6`, `small`, `title`, `subtitle`, `subheading`],
description: `<p>All of the HTML5 heading elements are styled, using a customizable ratio and simple rules, providing a clean base for your web app's titles. Apart from the headings themselves, customized rules are provided for displaying subheadings or explanatory text below your web app's headings.</p>`,
example: `<div class="row"><div class="col-sm-12 col-md-6 col-md-first"><h1 class="doc">Heading 1<small class="doc">Subheading</small></h1></div>
<div class="col-sm-12 col-md-6"><h2 class="doc">Heading 2<small class="doc">Subheading</small></h2></div>
<div class="col-sm-12 col-md-6 col-md-last"><h3 class="doc">Heading 3<small class="doc">Subheading</small></h3></div>
<div class="col-sm-12 col-md-6 col-md-first"><h4 class="doc">Heading 4<small class="doc">Subheading</small></h4></div>
<div class="col-sm-12 col-md-6"><h5 class="doc">Heading 5<small class="doc">Subheading</small></h5></div>
<div class="col-sm-12 col-md-6 col-md-last"><h6 class="doc">Heading 6<small class="doc">Subheading</small></h6></div></div>`,
samples: [
`<pre><span class="code-line"><span class="highlight-a">&lt;h1&gt;</span>Heading 1 <span class="highlight-a">&lt;small&gt;</span>Subheading<span class="highlight-a">&lt;/small&gt;&lt;/h1&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;h2&gt;</span>Heading 2 <span class="highlight-a">&lt;small&gt;</span>Subheading<span class="highlight-a">&lt;/small&gt;&lt;/h2&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;h3&gt;</span>Heading 3 <span class="highlight-a">&lt;small&gt;</span>Subheading<span class="highlight-a">&lt;/small&gt;&lt;/h3&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;h4&gt;</span>Heading 4 <span class="highlight-a">&lt;small&gt;</span>Subheading<span class="highlight-a">&lt;/small&gt;&lt;/h4&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;h5&gt;</span>Heading 5 <span class="highlight-a">&lt;small&gt;</span>Subheading<span class="highlight-a">&lt;/small&gt;&lt;/h5&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;h6&gt;</span>Heading 6 <span class="highlight-a">&lt;small&gt;</span>Subheading<span class="highlight-a">&lt;/small&gt;&lt;/h6&gt;</span></span></pre>
`
],
notes: [],
customization: [
`Text color can be changed globally by changing the value of the <code>--fore-color</code> variable. This will affect the color of the headings' main text.`,
`Secondary text color can be changed globally by changing the value of the <code>--secondary-fore-color</code> variable. This will affect the color of subheadings.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`You can change the ratio of headings' size by chaning the value of the <code>--heading-ratio</code> variable. Bear in mind that the value of this variable must be unitless to work properly.`
],
modifiers: [],
dos: [],
donts: []
}
module.exports = {
id: 'heading',
title: 'Headings',
keywords: [`heading`, `h1`, `h2`, `h3`, `h4`, `h5`, `h6`, `small`, `title`, `subtitle`, `subheading`],
description: `<p>All of the HTML5 heading elements are styled, using a customizable ratio and simple rules, providing a clean base for your web app's titles. Apart from the headings themselves, customized rules are provided for displaying subheadings or explanatory text below your web app's headings.</p>`,
example: `<div class="row"><div class="col-sm-12 col-md-6 col-md-first"><h1 class="doc">Heading 1<small class="doc">Subheading</small></h1></div>
<div class="col-sm-12 col-md-6"><h2 class="doc">Heading 2<small class="doc">Subheading</small></h2></div>
<div class="col-sm-12 col-md-6 col-md-last"><h3 class="doc">Heading 3<small class="doc">Subheading</small></h3></div>
<div class="col-sm-12 col-md-6 col-md-first"><h4 class="doc">Heading 4<small class="doc">Subheading</small></h4></div>
<div class="col-sm-12 col-md-6"><h5 class="doc">Heading 5<small class="doc">Subheading</small></h5></div>
<div class="col-sm-12 col-md-6 col-md-last"><h6 class="doc">Heading 6<small class="doc">Subheading</small></h6></div></div>`,
samples: [
`<pre><span class="code-line"><span class="highlight-a">&lt;h1&gt;</span>Heading 1 <span class="highlight-a">&lt;small&gt;</span>Subheading<span class="highlight-a">&lt;/small&gt;&lt;/h1&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;h2&gt;</span>Heading 2 <span class="highlight-a">&lt;small&gt;</span>Subheading<span class="highlight-a">&lt;/small&gt;&lt;/h2&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;h3&gt;</span>Heading 3 <span class="highlight-a">&lt;small&gt;</span>Subheading<span class="highlight-a">&lt;/small&gt;&lt;/h3&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;h4&gt;</span>Heading 4 <span class="highlight-a">&lt;small&gt;</span>Subheading<span class="highlight-a">&lt;/small&gt;&lt;/h4&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;h5&gt;</span>Heading 5 <span class="highlight-a">&lt;small&gt;</span>Subheading<span class="highlight-a">&lt;/small&gt;&lt;/h5&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;h6&gt;</span>Heading 6 <span class="highlight-a">&lt;small&gt;</span>Subheading<span class="highlight-a">&lt;/small&gt;&lt;/h6&gt;</span></span></pre>
`
],
notes: [],
customization: [
`Text color can be changed globally by changing the value of the <code>--fore-color</code> variable. This will affect the color of the headings' main text.`,
`Secondary text color can be changed globally by changing the value of the <code>--secondary-fore-color</code> variable. This will affect the color of subheadings.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`You can change the ratio of headings' size by chaning the value of the <code>--heading-ratio</code> variable. Bear in mind that the value of this variable must be unitless to work properly.`
],
modifiers: [],
dos: [],
donts: []
}

View file

@ -1,73 +1,73 @@
module.exports = {
id: 'icons',
title: 'Icons',
keywords: [`icon`, `svg`, `feather`, `icons`],
description: `<p><strong>mini.css</strong> comes with a set of 20 commonly-used icons (courtesy of <a href="https://feathericons.com/" target="_blank" rel="noopener">Feather</a>) that you can use anywhere in your web apps, utilizing the appropriate class for each icon.</p>`,
example: `<div class="row icon-row">
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-alert"></span>&nbsp;.icon-alert</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-bookmark"></span>&nbsp;.icon-bookmark</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-calendar"></span>&nbsp;.icon-calendar</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-cart"></span>&nbsp;.icon-cart</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-credit"></span>&nbsp;.icon-credit</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-edit"></span>&nbsp;.icon-edit</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-help"></span>&nbsp;.icon-help</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-home"></span>&nbsp;.icon-home</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-info"></span>&nbsp;.icon-info</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-link"></span>&nbsp;.icon-link</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-location"></span>&nbsp;.icon-location</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-lock"></span>&nbsp;.icon-lock</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-mail"></span>&nbsp;.icon-mail</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-phone"></span>&nbsp;.icon-phone</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-rss"></span>&nbsp;.icon-rss</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-search"></span>&nbsp;.icon-search</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-settings"></span>&nbsp;.icon-settings</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-share"></span>&nbsp;.icon-share</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-upload"></span>&nbsp;.icon-upload</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-user"></span>&nbsp;.icon-user</p></div>
</div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-alert&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-bookmark&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-calendar&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-cart&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-credit&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-edit&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-help&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-home&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-info&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-link&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-location&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-lock&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-mail&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-phone&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-rss&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-search&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-settings&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-share&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-upload&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-user&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span></pre>`],
notes: [`You can only use a <code>&lt;span&gt;</code> element to create an icon.`,
`You can inline icons inside a paragraph or pretty much any other textual content. Icons scale relative to their parent element.`],
customization: [
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`
],
modifiers: [
{
title : 'Color variants',
description: `<p>You can create secondary or inverse (<code>.secondary</code>, <code>.inverse</code>) icons, simply by adding the appropriate color modifier.</p>`,
example: `<p style="padding: 0.5rem;" class="doc">This is a <span class="icon-home secondary"></span> secondary icon, which has a lighter color.</p><p style="background: #111; color: #f8f8f8; padding: 0.5rem;" class="doc">This is an <span class="icon-home inverse"></span> inverse icon.</p>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-alert secondary&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-alert inverse&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span></pre>`]
}
],
dos: [],
donts: [
{
description: `Avoid inserting text inside icon elements.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-alert&quot;</span><span class="highlight-a">&gt;</span>Don't place text here.<span class="highlight-a">&lt;/span&gt;</span></span></pre>`
},
{
description: `Avoid applying two color modifiers on the same icon.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-alert inverse secondary&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span></pre>`
}
]
}
module.exports = {
id: 'icons',
title: 'Icons',
keywords: [`icon`, `svg`, `feather`, `icons`],
description: `<p><strong>mini.css</strong> comes with a set of 20 commonly-used icons (courtesy of <a href="https://feathericons.com/" target="_blank" rel="noopener">Feather</a>) that you can use anywhere in your web apps, utilizing the appropriate class for each icon.</p>`,
example: `<div class="row icon-row">
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-alert"></span>&nbsp;.icon-alert</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-bookmark"></span>&nbsp;.icon-bookmark</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-calendar"></span>&nbsp;.icon-calendar</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-cart"></span>&nbsp;.icon-cart</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-credit"></span>&nbsp;.icon-credit</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-edit"></span>&nbsp;.icon-edit</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-help"></span>&nbsp;.icon-help</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-home"></span>&nbsp;.icon-home</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-info"></span>&nbsp;.icon-info</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-link"></span>&nbsp;.icon-link</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-location"></span>&nbsp;.icon-location</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-lock"></span>&nbsp;.icon-lock</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-mail"></span>&nbsp;.icon-mail</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-phone"></span>&nbsp;.icon-phone</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-rss"></span>&nbsp;.icon-rss</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-search"></span>&nbsp;.icon-search</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-settings"></span>&nbsp;.icon-settings</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-share"></span>&nbsp;.icon-share</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-upload"></span>&nbsp;.icon-upload</p></div>
<div class="col-sm-12 col-md-6 col-lg-3"><p class="doc bordered rounded"><span class="icon-user"></span>&nbsp;.icon-user</p></div>
</div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-alert&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-bookmark&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-calendar&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-cart&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-credit&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-edit&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-help&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-home&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-info&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-link&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-location&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-lock&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-mail&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-phone&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-rss&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-search&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-settings&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-share&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-upload&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-user&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span></pre>`],
notes: [`You can only use a <code>&lt;span&gt;</code> element to create an icon.`,
`You can inline icons inside a paragraph or pretty much any other textual content. Icons scale relative to their parent element.`],
customization: [
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`
],
modifiers: [
{
title : 'Color variants',
description: `<p>You can create secondary or inverse (<code>.secondary</code>, <code>.inverse</code>) icons, simply by adding the appropriate color modifier.</p>`,
example: `<p style="padding: 0.5rem;" class="doc">This is a <span class="icon-home secondary"></span> secondary icon, which has a lighter color.</p><p style="background: #111; color: #f8f8f8; padding: 0.5rem;" class="doc">This is an <span class="icon-home inverse"></span> inverse icon.</p>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-alert secondary&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-alert inverse&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span></pre>`]
}
],
dos: [],
donts: [
{
description: `Avoid inserting text inside icon elements.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-alert&quot;</span><span class="highlight-a">&gt;</span>Don't place text here.<span class="highlight-a">&lt;/span&gt;</span></span></pre>`
},
{
description: `Avoid applying two color modifiers on the same icon.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;icon-alert inverse secondary&quot;</span><span class="highlight-a">&gt;&lt;/span&gt;</span></span></pre>`
}
]
}

View file

@ -1,21 +1,21 @@
module.exports = {
id: 'images-captions',
title: 'Images &amp; captions',
keywords: [`img`, `image`, `responsive`, `responsiveness`, `caption`, `figure`, `figcaption`],
description: `<p>Image elements are responsive by default, automatically scaling down as necessary to display properly on smaller devices. Images retain their original aspect ratio and they will never scale above their original size.</p>
<p>If you want to add captions to images, you can use HTML5 figure elements, along with their related captions.</p>`,
example: '<figure><img src="https://placehold.it/800x600" alt="placeholder"><figcaption class="doc">Image caption</figcaption></figure>',
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;img</span> <span class="highlight-b">src</span>=<span class="highlight-c">&quot;image.png&quot;</span> <span class="highlight-b">alt</span>=<span class="highlight-c">&quot;Image description&quot;</span><span class="highlight-a">/&gt;</span></span></pre>`,
`<pre><span class="code-line"><span class="highlight-a">&lt;figure&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;img</span> <span class="highlight-b">src</span>=<span class="highlight-c">&quot;image.png&quot;</span> <span class="highlight-b">alt</span>=<span class="highlight-c">&quot;Image description&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;figcaption&gt;</span>Image caption<span class="highlight-a">&lt;/figcaption&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/figure&gt;</span></span></pre>`],
notes: [`While not mandatory, it is considered a good practice to always add a <code>alt</code> attribute to image elements on your web apps.`],
customization: [
`You can change the text color of <code>&lt;figcaption&gt;</code> elements by changing the value of the <code>--secondary-fore-color</code> variable.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`
],
modifiers: [],
dos: [],
donts: []
}
module.exports = {
id: 'images-captions',
title: 'Images &amp; captions',
keywords: [`img`, `image`, `responsive`, `responsiveness`, `caption`, `figure`, `figcaption`],
description: `<p>Image elements are responsive by default, automatically scaling down as necessary to display properly on smaller devices. Images retain their original aspect ratio and they will never scale above their original size.</p>
<p>If you want to add captions to images, you can use HTML5 figure elements, along with their related captions.</p>`,
example: '<figure><img src="https://placehold.it/800x600" alt="placeholder"><figcaption class="doc">Image caption</figcaption></figure>',
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;img</span> <span class="highlight-b">src</span>=<span class="highlight-c">&quot;image.png&quot;</span> <span class="highlight-b">alt</span>=<span class="highlight-c">&quot;Image description&quot;</span><span class="highlight-a">/&gt;</span></span></pre>`,
`<pre><span class="code-line"><span class="highlight-a">&lt;figure&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;img</span> <span class="highlight-b">src</span>=<span class="highlight-c">&quot;image.png&quot;</span> <span class="highlight-b">alt</span>=<span class="highlight-c">&quot;Image description&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;figcaption&gt;</span>Image caption<span class="highlight-a">&lt;/figcaption&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/figure&gt;</span></span></pre>`],
notes: [`While not mandatory, it is considered a good practice to always add a <code>alt</code> attribute to image elements on your web apps.`],
customization: [
`You can change the text color of <code>&lt;figcaption&gt;</code> elements by changing the value of the <code>--secondary-fore-color</code> variable.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`
],
modifiers: [],
dos: [],
donts: []
}

View file

@ -1,68 +1,68 @@
module.exports = {
id: 'input-grouping',
title: 'Input grouping',
keywords: [`input group`, `input-group`, `vertical`, `fluid`, `input`, `button`, `button group`, `button-group`],
description: `<p>You can ensure that input elements and labels display together on the same line, by grouping them together (<code>.input-group</code>). You can also group buttons together, using a different grouping class (<code>.button-group</code>).</p>`,
example: `<form>
<fieldset>
<legend class="doc">Grouped inputs</legend>
<div class="input-group"><label for="gi1-un" class="doc">Username</label> <input type="email" value="" id="gi1-un" placeholder="Username" class="doc"></div><br/>
<div class="input-group"><label for="gi1-pwd" class="doc">Password</label> <input type="password" value="" id="gi1-pwd" placeholder="Password" class="doc"></div>
</fieldset>
</form>
<div class="button-group"><button class="doc">Buttons</button><button class="doc">can be</button><button class="doc">grouped</button></div>`,
samples: [
`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;input-group&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;username&quot;</span><span class="highlight-a">&gt;</span>Username<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;text&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;Username&quot;</span> <span class="highlight-b">placeholder</span>=<span class="highlight-c">&quot;Username&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`,
`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;button-group&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;button&gt;</span>Button<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;button&gt;</span>Button<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;button&gt;</span>Button<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
],
notes: [`It is highly recommended that you do not place checkboxes or radio buttons inside fluid or vertical input groups.`,
`Button groups will display horizontally on medium and large screens, but collapse into a vertical view on small screens.`],
customization: [],
modifiers: [
{
title : `Fluid &amp; vertical grouping`,
description: `<p>You can make your input groups fluid (<code>.fluid</code>) or vertical (<code>.vertical</code>), by applying the appropriate modifiers.</p>`,
example: `<form>
<fieldset>
<legend class="doc">Fluid input groups</legend>
<div class="input-group fluid"><label for="gi2-un" class="doc">Username</label> <input type="email" value="" id="gi2-un" placeholder="Username" class="doc"></div>
<div class="input-group fluid"><label for="gi2-pwd" class="doc">Password</label> <input type="password" value="" id="gi2-pwd" placeholder="Password" class="doc"></div>
</fieldset>
</form>
<form>
<fieldset>
<legend class="doc">Vertical input groups</legend>
<div class="input-group vertical"><label for="gi3-un" class="doc">Username</label> <input type="email" value="" id="gi3-un" placeholder="Username" class="doc"></div>
<div class="input-group vertical"><label for="gi3-pwd" class="doc">Password</label> <input type="password" value="" id="gi3-pwd" placeholder="Password" class="doc"></div>
</fieldset>
</form>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;input-group fluid&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;username&quot;</span><span class="highlight-a">&gt;</span>Username<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;text&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;Username&quot;</span> <span class="highlight-b">placeholder</span>=<span class="highlight-c">&quot;Username&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;input-group vertical&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;username&quot;</span><span class="highlight-a">&gt;</span>Username<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;text&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;Username&quot;</span> <span class="highlight-b">placeholder</span>=<span class="highlight-c">&quot;Username&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`]
}
],
dos: [],
donts: [
{
description: `Avoid combining input groups with the <a href="#grid">grid system</a>, as there might be overlapping styles.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;input-group row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;username&quot;</span><span class="highlight-a">&gt;</span>Username<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;text&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;Username&quot;</span> <span class="highlight-b">placeholder</span>=<span class="highlight-c">&quot;Username&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
}
]
}
module.exports = {
id: 'input-grouping',
title: 'Input grouping',
keywords: [`input group`, `input-group`, `vertical`, `fluid`, `input`, `button`, `button group`, `button-group`],
description: `<p>You can ensure that input elements and labels display together on the same line, by grouping them together (<code>.input-group</code>). You can also group buttons together, using a different grouping class (<code>.button-group</code>).</p>`,
example: `<form>
<fieldset>
<legend class="doc">Grouped inputs</legend>
<div class="input-group"><label for="gi1-un" class="doc">Username</label> <input type="email" value="" id="gi1-un" placeholder="Username" class="doc"></div><br/>
<div class="input-group"><label for="gi1-pwd" class="doc">Password</label> <input type="password" value="" id="gi1-pwd" placeholder="Password" class="doc"></div>
</fieldset>
</form>
<div class="button-group"><button class="doc">Buttons</button><button class="doc">can be</button><button class="doc">grouped</button></div>`,
samples: [
`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;input-group&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;username&quot;</span><span class="highlight-a">&gt;</span>Username<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;text&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;Username&quot;</span> <span class="highlight-b">placeholder</span>=<span class="highlight-c">&quot;Username&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`,
`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;button-group&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;button&gt;</span>Button<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;button&gt;</span>Button<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;button&gt;</span>Button<span class="highlight-a">&lt;/button&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
],
notes: [`It is highly recommended that you do not place checkboxes or radio buttons inside fluid or vertical input groups.`,
`Button groups will display horizontally on medium and large screens, but collapse into a vertical view on small screens.`],
customization: [],
modifiers: [
{
title : `Fluid &amp; vertical grouping`,
description: `<p>You can make your input groups fluid (<code>.fluid</code>) or vertical (<code>.vertical</code>), by applying the appropriate modifiers.</p>`,
example: `<form>
<fieldset>
<legend class="doc">Fluid input groups</legend>
<div class="input-group fluid"><label for="gi2-un" class="doc">Username</label> <input type="email" value="" id="gi2-un" placeholder="Username" class="doc"></div>
<div class="input-group fluid"><label for="gi2-pwd" class="doc">Password</label> <input type="password" value="" id="gi2-pwd" placeholder="Password" class="doc"></div>
</fieldset>
</form>
<form>
<fieldset>
<legend class="doc">Vertical input groups</legend>
<div class="input-group vertical"><label for="gi3-un" class="doc">Username</label> <input type="email" value="" id="gi3-un" placeholder="Username" class="doc"></div>
<div class="input-group vertical"><label for="gi3-pwd" class="doc">Password</label> <input type="password" value="" id="gi3-pwd" placeholder="Password" class="doc"></div>
</fieldset>
</form>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;input-group fluid&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;username&quot;</span><span class="highlight-a">&gt;</span>Username<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;text&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;Username&quot;</span> <span class="highlight-b">placeholder</span>=<span class="highlight-c">&quot;Username&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;input-group vertical&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;username&quot;</span><span class="highlight-a">&gt;</span>Username<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;text&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;Username&quot;</span> <span class="highlight-b">placeholder</span>=<span class="highlight-c">&quot;Username&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`]
}
],
dos: [],
donts: [
{
description: `Avoid combining input groups with the <a href="#grid">grid system</a>, as there might be overlapping styles.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;input-group row&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;col-sm&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;username&quot;</span><span class="highlight-a">&gt;</span>Username<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;text&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;Username&quot;</span> <span class="highlight-b">placeholder</span>=<span class="highlight-c">&quot;Username&quot;</span><span class="highlight-a">/&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
}
]
}

View file

@ -1,28 +1,28 @@
module.exports = {
id: 'lists',
title: 'Lists',
keywords: [`list`, `ul`, `ol`, `li`],
description: `<p>List elements, both unordered and ordered, are minimally styled to match with the rest of the framework's aesthetics. Their margins and padding are reset to properly align with the rest of the common HTML5 elements, providing a stable foundation for all of your web app's lists.</p>`,
example: `<ul class="doc"><li class="doc">Apple</li><li class="doc">Orange</li><li class="doc">Strawberry</li></ul><br/>
<ol class="doc"><li class="doc">Wake up</li><li class="doc">Eat breakfast</li><li class="doc">Go to work</li></ol>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;ul&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;li&gt;</span>Apple<span class="highlight-a">&lt;/li&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;li&gt;</span>Orange<span class="highlight-a">&lt;/li&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;li&gt;</span>Strawberry<span class="highlight-a">&lt;/li&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/ul&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;ol&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;li&gt;</span>Wake up<span class="highlight-a">&lt;/li&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;li&gt;</span>Eat breakfast<span class="highlight-a">&lt;/li&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;li&gt;</span>Go to work<span class="highlight-a">&lt;/li&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/ol&gt;</span></span></pre>`],
notes: [],
customization: [
`Text color can be changed globally by changing the value of the <code>--fore-color</code> variable.`,
`Background color can be changed globally by changing the value of the <code>--back-color</code> variable.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`
],
modifiers: [],
dos: [],
donts: []
}
module.exports = {
id: 'lists',
title: 'Lists',
keywords: [`list`, `ul`, `ol`, `li`],
description: `<p>List elements, both unordered and ordered, are minimally styled to match with the rest of the framework's aesthetics. Their margins and padding are reset to properly align with the rest of the common HTML5 elements, providing a stable foundation for all of your web app's lists.</p>`,
example: `<ul class="doc"><li class="doc">Apple</li><li class="doc">Orange</li><li class="doc">Strawberry</li></ul><br/>
<ol class="doc"><li class="doc">Wake up</li><li class="doc">Eat breakfast</li><li class="doc">Go to work</li></ol>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;ul&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;li&gt;</span>Apple<span class="highlight-a">&lt;/li&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;li&gt;</span>Orange<span class="highlight-a">&lt;/li&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;li&gt;</span>Strawberry<span class="highlight-a">&lt;/li&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/ul&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;ol&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;li&gt;</span>Wake up<span class="highlight-a">&lt;/li&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;li&gt;</span>Eat breakfast<span class="highlight-a">&lt;/li&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;li&gt;</span>Go to work<span class="highlight-a">&lt;/li&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/ol&gt;</span></span></pre>`],
notes: [],
customization: [
`Text color can be changed globally by changing the value of the <code>--fore-color</code> variable.`,
`Background color can be changed globally by changing the value of the <code>--back-color</code> variable.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`
],
modifiers: [],
dos: [],
donts: []
}

View file

@ -1,62 +1,62 @@
module.exports = {
id: 'modal-dialogs',
title: 'Modal dialogs',
keywords: [`modal`, `dialog`, `contextual`, `alert`, `notification`],
description: `<p><strong>mini.css</strong> provides you with a modal dialog component to display messages to users. It is composed of three components - the modal dialog, the toggle button and the close button:</p>
<ul><li>To create a modal dialog, simply create a checkbox input, applying the appropriate class to it (<code>.modal</code>), immediately followed by a <code>&lt;div&gt;</code> container. The former serves as your modal dialog's control, while the latter is the actual modal dialog container.</li>
<li>Create a label anywhere outside your modal dialog's container for the checkbox controlling your modal dialog. This will serve as the toggle button for your modal dialog.</li>
<li>Finally, inside your modal dialog's container, add another label for the checkbox controlling your modal dialog, applying the appropriate class (.modal-close). This will serve as the close button for your modal dialog.</li>
</ul>`,
example: `<input type="checkbox" class="modal" id="modal-example"><div class="modal doc"><div class="card doc"><label for="modal-example" class="modal-close doc"></label><h3 class="section double-padded doc">Modal</h3><p class="section double-padded doc">This is a modal dialog!</p></div></div><label for="modal-example" class="button doc">Show modal dialog</label>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;modal-control&quot;</span><span class="highlight-a">&gt;</span>Show modal<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"></span>
<span class="code-line"><span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;checkbox&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;modal-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;modal&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;modal-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;modal-close&quot;</span> <span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;h3</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section&quot;</span><span class="highlight-a">&gt;</span>Modal<span class="highlight-a">&lt;/h3&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section&quot;</span><span class="highlight-a">&gt;</span>This is a modal dialog!<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`],
notes: [
`Modal dialogs should be used in combination with the <a href="#card">card</a> component for best results.`,
`Remember to apply the appropriate classes to any and all elements, as indicated in the examples. Failing to do so will result in the modal dialog not rendering or behaving properly.`,
`You can omit the toggle for the modal dialog and use Javascript to show/hide it, instead. You can also use any correctly linked label inside the modal dialog to change its state.`
],
customization: [
`Background color for the modal dialog overlay can be changed by changing the value of <code>--modal-overlay-color</code>.`,
`Text color for the modal dialog close button can be changed by changing the value of the <code>--modal-close-color</code>.`,
`Background color for the modal dialog close button when focused or hovered over can be changed by changing the value of the <code>--modal-close-hover-color</code>.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [],
dos: [
{
description: `You can use the <code>role=&quot;dialog&quot;</code> to add accessibility to your modal dialogs. Remember to properly label it and manage keyboard focus, as required.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;checkbox&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;modal-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;modal&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">role</span>=<span class="highlight-c">&quot;dialog&quot;</span> <span class="highlight-b">aria-labelledby</span>=<span class="highlight-c">&quot;dialog-title&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;modal-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;modal-close&quot;</span> <span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;h3</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;dialog-title&quot;</span><span class="highlight-a">&gt;</span>Modal<span class="highlight-a">&lt;/h3&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section&quot;</span><span class="highlight-a">&gt;</span>This is a modal dialog!<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
}
],
donts: [
{
description: `You should not place anything between the checkbox controlling the modal dialog and the container.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;checkbox&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;modal-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;modal&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"><span class="highlight-c">&lt;!-- Do not place other stuff between these --&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;modal-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;modal-close&quot;</span> <span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;h3</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section&quot;</span><span class="highlight-a">&gt;</span>Modal<span class="highlight-a">&lt;/h3&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section&quot;</span><span class="highlight-a">&gt;</span>This is a modal dialog!<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
}
]
}
module.exports = {
id: 'modal-dialogs',
title: 'Modal dialogs',
keywords: [`modal`, `dialog`, `contextual`, `alert`, `notification`],
description: `<p><strong>mini.css</strong> provides you with a modal dialog component to display messages to users. It is composed of three components - the modal dialog, the toggle button and the close button:</p>
<ul><li>To create a modal dialog, simply create a checkbox input, applying the appropriate class to it (<code>.modal</code>), immediately followed by a <code>&lt;div&gt;</code> container. The former serves as your modal dialog's control, while the latter is the actual modal dialog container.</li>
<li>Create a label anywhere outside your modal dialog's container for the checkbox controlling your modal dialog. This will serve as the toggle button for your modal dialog.</li>
<li>Finally, inside your modal dialog's container, add another label for the checkbox controlling your modal dialog, applying the appropriate class (.modal-close). This will serve as the close button for your modal dialog.</li>
</ul>`,
example: `<input type="checkbox" class="modal" id="modal-example"><div class="modal doc"><div class="card doc"><label for="modal-example" class="modal-close doc"></label><h3 class="section double-padded doc">Modal</h3><p class="section double-padded doc">This is a modal dialog!</p></div></div><label for="modal-example" class="button doc">Show modal dialog</label>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;modal-control&quot;</span><span class="highlight-a">&gt;</span>Show modal<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"></span>
<span class="code-line"><span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;checkbox&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;modal-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;modal&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;modal-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;modal-close&quot;</span> <span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;h3</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section&quot;</span><span class="highlight-a">&gt;</span>Modal<span class="highlight-a">&lt;/h3&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section&quot;</span><span class="highlight-a">&gt;</span>This is a modal dialog!<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`],
notes: [
`Modal dialogs should be used in combination with the <a href="#card">card</a> component for best results.`,
`Remember to apply the appropriate classes to any and all elements, as indicated in the examples. Failing to do so will result in the modal dialog not rendering or behaving properly.`,
`You can omit the toggle for the modal dialog and use Javascript to show/hide it, instead. You can also use any correctly linked label inside the modal dialog to change its state.`
],
customization: [
`Background color for the modal dialog overlay can be changed by changing the value of <code>--modal-overlay-color</code>.`,
`Text color for the modal dialog close button can be changed by changing the value of the <code>--modal-close-color</code>.`,
`Background color for the modal dialog close button when focused or hovered over can be changed by changing the value of the <code>--modal-close-hover-color</code>.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [],
dos: [
{
description: `You can use the <code>role=&quot;dialog&quot;</code> to add accessibility to your modal dialogs. Remember to properly label it and manage keyboard focus, as required.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;checkbox&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;modal-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;modal&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">role</span>=<span class="highlight-c">&quot;dialog&quot;</span> <span class="highlight-b">aria-labelledby</span>=<span class="highlight-c">&quot;dialog-title&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;modal-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;modal-close&quot;</span> <span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;h3</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;dialog-title&quot;</span><span class="highlight-a">&gt;</span>Modal<span class="highlight-a">&lt;/h3&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section&quot;</span><span class="highlight-a">&gt;</span>This is a modal dialog!<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
}
],
donts: [
{
description: `You should not place anything between the checkbox controlling the modal dialog and the container.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;checkbox&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;modal-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;modal&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"><span class="highlight-c">&lt;!-- Do not place other stuff between these --&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;card&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;modal-control&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;modal-close&quot;</span> <span class="highlight-a">&gt;</span><span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;h3</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section&quot;</span><span class="highlight-a">&gt;</span>Modal<span class="highlight-a">&lt;/h3&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;section&quot;</span><span class="highlight-a">&gt;</span>This is a modal dialog!<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
}
]
}

View file

@ -1,49 +1,49 @@
module.exports = {
id: 'navigation-bar',
title: 'Navigation bar',
keywords: [`navigation`, `bar`, `nav`, `link`],
description: `<p>The navigation bar element has been minimally styled, allowing you to create simple vertical navigation menus for your web apps. Apart from styling from links, custom classes (<code>.sublink-1</code> and <code>.sublink-2</code>) are provided for creating navigation trees.</p>`,
example: `<nav>
<a href="#" class="doc">Home</a> <span class="doc">News</span>
<a href="#" class="sublink-1 doc">New Courses</a> <a href="#" class="sublink-1 doc">Certifications</a>
<span class="sublink-1 doc">Events</span> <a href="#" class="sublink-2 doc">Course Showcase - 12th, Dec</a>
<a href="#" class="sublink-2 doc">Staff AMA - 16th, Dec</a> <a href="#" class="sublink-1 doc">Policy Update</a>
<a href="#" class="doc">About</a> <a href="#" class="doc">Contact</a>
</nav>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;nav&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span><span class="highlight-a">&gt;</span>Category 1<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;span&gt;</span>Category 2<span class="highlight-a">&lt;/span&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;sublink-1&quot;</span><span class="highlight-a">&gt;</span>Item 2.1<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;sublink-1&quot;</span><span class="highlight-a">&gt;</span>Category 2.2<span class="highlight-a">&lt;/span&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;sublink-2&quot;</span><span class="highlight-a">&gt;</span>Item 2.2.1<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/nav&gt;</span></span></pre>`],
notes: [`It is recommended that you combine the navigation bar element with the <a href="#grid">grid system</a> to create responsive navigation menus for your web apps.`],
customization: [
`Text color for navigation bars can be changed by changing the value of the <code>--nav-fore-color</code> variable.`,
`Background color for navigation bars can be changed by changing the value of the <code>--nav-back-color</code> variable.`,
`Border color for navigation bars can be changed by changing the value of the <code>--nav-border-color</code> variable.`,
`Background color for focused buttons inside navigation bars can be changed by changing the value of the <code>--nav-hover-back-color</code> variable.`,
`Text color for links inside navigation bars can be changed by changing the value of the <code>--nav-link-color</code> variable.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [],
dos: [],
donts: []
}
/*
Modifiers:
{
title : '',
description: '',
example: '',
samples: []
}
Dos/Donts:
{
description: '',
sample: ''
}
*/
module.exports = {
id: 'navigation-bar',
title: 'Navigation bar',
keywords: [`navigation`, `bar`, `nav`, `link`],
description: `<p>The navigation bar element has been minimally styled, allowing you to create simple vertical navigation menus for your web apps. Apart from styling from links, custom classes (<code>.sublink-1</code> and <code>.sublink-2</code>) are provided for creating navigation trees.</p>`,
example: `<nav>
<a href="#" class="doc">Home</a> <span class="doc">News</span>
<a href="#" class="sublink-1 doc">New Courses</a> <a href="#" class="sublink-1 doc">Certifications</a>
<span class="sublink-1 doc">Events</span> <a href="#" class="sublink-2 doc">Course Showcase - 12th, Dec</a>
<a href="#" class="sublink-2 doc">Staff AMA - 16th, Dec</a> <a href="#" class="sublink-1 doc">Policy Update</a>
<a href="#" class="doc">About</a> <a href="#" class="doc">Contact</a>
</nav>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;nav&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span><span class="highlight-a">&gt;</span>Category 1<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;span&gt;</span>Category 2<span class="highlight-a">&lt;/span&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;sublink-1&quot;</span><span class="highlight-a">&gt;</span>Item 2.1<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;sublink-1&quot;</span><span class="highlight-a">&gt;</span>Category 2.2<span class="highlight-a">&lt;/span&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;a</span> <span class="highlight-b">href</span>=<span class="highlight-c">&quot;#&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;sublink-2&quot;</span><span class="highlight-a">&gt;</span>Item 2.2.1<span class="highlight-a">&lt;/a&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/nav&gt;</span></span></pre>`],
notes: [`It is recommended that you combine the navigation bar element with the <a href="#grid">grid system</a> to create responsive navigation menus for your web apps.`],
customization: [
`Text color for navigation bars can be changed by changing the value of the <code>--nav-fore-color</code> variable.`,
`Background color for navigation bars can be changed by changing the value of the <code>--nav-back-color</code> variable.`,
`Border color for navigation bars can be changed by changing the value of the <code>--nav-border-color</code> variable.`,
`Background color for focused buttons inside navigation bars can be changed by changing the value of the <code>--nav-hover-back-color</code> variable.`,
`Text color for links inside navigation bars can be changed by changing the value of the <code>--nav-link-color</code> variable.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [],
dos: [],
donts: []
}
/*
Modifiers:
{
title : '',
description: '',
example: '',
samples: []
}
Dos/Donts:
{
description: '',
sample: ''
}
*/

View file

@ -1,44 +1,44 @@
module.exports = {
id: 'progress-bars',
title: 'Progress bars',
keywords: [`progress`, `bar`, `primary`, `secondary`, `tertiary`, `inline`],
description: `<p>Progress bars are minimally styled to match with the rest of the framework's aesthetics and be consistent across all modern browsers.</p>`,
example: `<progress value="450" max="1000"></progress>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;progress</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;450&quot;</span> <span class="highlight-b">max</span>=<span class="highlight-c">&quot;1000&quot;</span><span class="highlight-a">&gt;&lt;/progress&gt;</span></span></pre>`],
notes: [`Progress bars are designed to work with a <code>max="1000"</code> attribute, as this covers the most common use-cases.`],
customization: [
`Foreground color for progress bars can be changed by changing the value of the <code>--progress-fore-color</code> variable.`,
`Background color for progress bars can be changed by changing the value of the <code>--progress-back-color</code> variable.`,
`You can customize the colors of different color variants by changing the values of the related variables in their respective definitions.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [
{
title : 'Inline progress bars',
description: `<p>You can create inline progress bars (<code>.inline</code>), by applying the appropriate modifier.</p>`,
example: `<p class="doc"><progress value="450" max="1000" class="inline"></progress> 45% completed...</p>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;progress</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;450&quot;</span> <span class="highlight-b">max</span>=<span class="highlight-c">&quot;1000&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;inline&quot;</span><span class="highlight-a">&gt;&lt;/progress&gt;</span></span></pre>`]
},
{
title : 'Color variants',
description: `<p>You can create primary, secondary or tertiary (<code>.primary</code>, <code>.secondary</code>, <code>.tertiary</code>) progress bars, simply by adding the appropriate color modifier.</p>`,
example: `<progress value="450" max="1000" class="primary"></progress><progress value="450" max="1000" class="secondary"></progress><progress value="450" max="1000" class="tertiary"></progress>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;progress</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;450&quot;</span> <span class="highlight-b">max</span>=<span class="highlight-c">&quot;1000&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;primary&quot;</span><span class="highlight-a">&gt;&lt;/progress&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;progress</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;450&quot;</span> <span class="highlight-b">max</span>=<span class="highlight-c">&quot;1000&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;secondary&quot;</span><span class="highlight-a">&gt;&lt;/progress&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;progress</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;450&quot;</span> <span class="highlight-b">max</span>=<span class="highlight-c">&quot;1000&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;tertiary&quot;</span><span class="highlight-a">&gt;&lt;/progress&gt;</span></span></pre>`]
}
],
dos: [],
donts: [
{
description: `Avoid using different values than <code>1000</code> for progress bars' <code>max</code> attribute, as well as floating point values for either <code>max</code> or <code>value</code>.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;progress</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;45&quot;</span> <span class="highlight-b">max</span>=<span class="highlight-c">&quot;100&quot;</span><span class="highlight-a">&gt;&lt;/progress&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;progress</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;450.0&quot;</span> <span class="highlight-b">max</span>=<span class="highlight-c">&quot;1000.0&quot;</span><span class="highlight-a">&gt;&lt;/progress&gt;</span></span></pre>`
},
{
description: `Avoid applying two color modifiers on the same progress bar.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;progress</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;450&quot;</span> <span class="highlight-b">max</span>=<span class="highlight-c">&quot;1000&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;primary secondary&quot;</span><span class="highlight-a">&gt;&lt;/progress&gt;</span></span></pre>`
}
]
}
module.exports = {
id: 'progress-bars',
title: 'Progress bars',
keywords: [`progress`, `bar`, `primary`, `secondary`, `tertiary`, `inline`],
description: `<p>Progress bars are minimally styled to match with the rest of the framework's aesthetics and be consistent across all modern browsers.</p>`,
example: `<progress value="450" max="1000"></progress>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;progress</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;450&quot;</span> <span class="highlight-b">max</span>=<span class="highlight-c">&quot;1000&quot;</span><span class="highlight-a">&gt;&lt;/progress&gt;</span></span></pre>`],
notes: [`Progress bars are designed to work with a <code>max="1000"</code> attribute, as this covers the most common use-cases.`],
customization: [
`Foreground color for progress bars can be changed by changing the value of the <code>--progress-fore-color</code> variable.`,
`Background color for progress bars can be changed by changing the value of the <code>--progress-back-color</code> variable.`,
`You can customize the colors of different color variants by changing the values of the related variables in their respective definitions.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [
{
title : 'Inline progress bars',
description: `<p>You can create inline progress bars (<code>.inline</code>), by applying the appropriate modifier.</p>`,
example: `<p class="doc"><progress value="450" max="1000" class="inline"></progress> 45% completed...</p>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;progress</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;450&quot;</span> <span class="highlight-b">max</span>=<span class="highlight-c">&quot;1000&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;inline&quot;</span><span class="highlight-a">&gt;&lt;/progress&gt;</span></span></pre>`]
},
{
title : 'Color variants',
description: `<p>You can create primary, secondary or tertiary (<code>.primary</code>, <code>.secondary</code>, <code>.tertiary</code>) progress bars, simply by adding the appropriate color modifier.</p>`,
example: `<progress value="450" max="1000" class="primary"></progress><progress value="450" max="1000" class="secondary"></progress><progress value="450" max="1000" class="tertiary"></progress>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;progress</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;450&quot;</span> <span class="highlight-b">max</span>=<span class="highlight-c">&quot;1000&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;primary&quot;</span><span class="highlight-a">&gt;&lt;/progress&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;progress</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;450&quot;</span> <span class="highlight-b">max</span>=<span class="highlight-c">&quot;1000&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;secondary&quot;</span><span class="highlight-a">&gt;&lt;/progress&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;progress</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;450&quot;</span> <span class="highlight-b">max</span>=<span class="highlight-c">&quot;1000&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;tertiary&quot;</span><span class="highlight-a">&gt;&lt;/progress&gt;</span></span></pre>`]
}
],
dos: [],
donts: [
{
description: `Avoid using different values than <code>1000</code> for progress bars' <code>max</code> attribute, as well as floating point values for either <code>max</code> or <code>value</code>.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;progress</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;45&quot;</span> <span class="highlight-b">max</span>=<span class="highlight-c">&quot;100&quot;</span><span class="highlight-a">&gt;&lt;/progress&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;progress</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;450.0&quot;</span> <span class="highlight-b">max</span>=<span class="highlight-c">&quot;1000.0&quot;</span><span class="highlight-a">&gt;&lt;/progress&gt;</span></span></pre>`
},
{
description: `Avoid applying two color modifiers on the same progress bar.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;progress</span> <span class="highlight-b">value</span>=<span class="highlight-c">&quot;450&quot;</span> <span class="highlight-b">max</span>=<span class="highlight-c">&quot;1000&quot;</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;primary secondary&quot;</span><span class="highlight-a">&gt;&lt;/progress&gt;</span></span></pre>`
}
]
}

View file

@ -1,20 +1,20 @@
module.exports = {
id: 'responsive-spacing-sizing',
title: 'Responsive spacing &amp; sizing',
keywords: ['responsiveness', 'margin', 'padding', 'responsive-margin', 'responsive-margin'],
description: '<p>You can make elements\' spacing or sizing responsive by applying the appropriate class (<code>.responsive-margin</code> or <code>.responsive-padding</code>).</p>',
example: '',
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;responsive-margin&quot;</span><span class="highlight-a">&gt;</span>Responsive margin.<span class="highlight-a">&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;responsive-padding&quot;</span><span class="highlight-a">&gt;</span>Responsive padding.<span class="highlight-a">&lt;/span&gt;</span></span></pre>`],
notes: [
'Responsive spacing and sizing modifiers use <code>!important</code> declarations to override any other styles, so exercise caution when using them.',
'Responsive spacing and sizing modifiers are independent, meaning that hiding or visually hiding an element in one screen size will not affect its visibility in any other screen size.'
],
customization: [
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable, affecting the responsive spacing modifier. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable, affecting the responsive sizing modifier.`
],
modifiers: [],
dos: [],
donts: []
}
module.exports = {
id: 'responsive-spacing-sizing',
title: 'Responsive spacing &amp; sizing',
keywords: ['responsiveness', 'margin', 'padding', 'responsive-margin', 'responsive-margin'],
description: '<p>You can make elements\' spacing or sizing responsive by applying the appropriate class (<code>.responsive-margin</code> or <code>.responsive-padding</code>).</p>',
example: '',
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;responsive-margin&quot;</span><span class="highlight-a">&gt;</span>Responsive margin.<span class="highlight-a">&lt;/span&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;responsive-padding&quot;</span><span class="highlight-a">&gt;</span>Responsive padding.<span class="highlight-a">&lt;/span&gt;</span></span></pre>`],
notes: [
'Responsive spacing and sizing modifiers use <code>!important</code> declarations to override any other styles, so exercise caution when using them.',
'Responsive spacing and sizing modifiers are independent, meaning that hiding or visually hiding an element in one screen size will not affect its visibility in any other screen size.'
],
customization: [
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable, affecting the responsive spacing modifier. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable, affecting the responsive sizing modifier.`
],
modifiers: [],
dos: [],
donts: []
}

View file

@ -1,68 +1,68 @@
module.exports = {
id: 'spoilers-and-accordions',
title: 'Spoilers &amp; accordions',
keywords: [`spoiler`, `collapse`, `accordion`, `contextual`, `vertical tabs`],
description: `<p><strong>mini.css</strong> provides you with accessible spoilers and accordions. They are composed of two components - the wrapper, the toggle button and the content container:</p>
<ul><li>To create a collapsible spoiler, simply create a <code>&lt;div&gt;</code>, applying the appropriate class to it (<code>.collapse</code>). This serves as the wrapper for the collapsible spoiler.</li>
<li>Inside the wrapper, create a checkbox or radio input, immediately followed by a <code>&lt;label&gt;</code> for the checkbox. The former serves as your collapsible spoiler's control, while the latter is the toggle button for your collapsible spoiler.</li>
<li>Create a <code>&lt;div&gt;</code> right after the <code>&lt;label&gt;</code>. This will serve as the container for the collapsible content.</li>
</ul>
<p>If you want to create an accordion, simply repeat the last two steps above for each section of the accordion. In order to make collapsible spoilers and accordions fully accessible, it is highly recommended to add the <code>aria-hidden=&quot;true&quot;</code> attribute to all labels and inputs that control the behavior of these components.</p>`,
example: `<div class="collapse"><input type="checkbox" id="collapse-example1" checked aria-hidden="true"><label for="collapse-example1" aria-hidden="true">Collapse section 1</label><div><p>This is the first section of the collapse</p></div><input type="checkbox" id="collapse-example2" aria-hidden="true"><label for="collapse-example2" aria-hidden="true">Collapse section 2</label><div><p>This is the second section of the collapse</p></div></div><br/>
<div class="collapse"><input type="radio" name="accordion" id="accordion-example1" checked aria-hidden="true"><label for="accordion-example1" aria-hidden="true">Accordion section 1</label><div><p>This is the first section of the accordion</p></div><input type="radio" name="accordion" id="accordion-example2" aria-hidden="true"><label for="accordion-example2" aria-hidden="true">Accordion section 2</label><div><p>This is the second section of the accordion</p></div></div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;collapse&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;checkbox&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;collapse-section1&quot;</span> <span class="highlight-b">checked</span> <span class="highlight-b">aria-hidden</span>=<span class="highlight-c">&quot;true&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;collapse-section1&quot;</span> <span class="highlight-b">aria-hidden</span>=<span class="highlight-c">&quot;true&quot;</span><span class="highlight-a">&gt;</span>Collapse section 1<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>This is the first section of the collapse<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;checkbox&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;collapse-section2&quot;</span> <span class="highlight-b">aria-hidden</span>=<span class="highlight-c">&quot;true&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;collapse-section2&quot;</span> <span class="highlight-b">aria-hidden</span>=<span class="highlight-c">&quot;true&quot;</span><span class="highlight-a">&gt;</span>Collapse section 2<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>This is the second section of the collapse<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`,
`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;collapse&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;radio&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;accordion-section1&quot;</span> <span class="highlight-b">checked</span> <span class="highlight-b">aria-hidden</span>=<span class="highlight-c">&quot;true&quot;</span> <span class="highlight-b">name</span>=<span class="highlight-c">&quot;accordion&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;accordion-section1&quot;</span> <span class="highlight-b">aria-hidden</span>=<span class="highlight-c">&quot;true&quot;</span><span class="highlight-a">&gt;</span>Accordion section 1<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>This is the first section of the accordion<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;radio&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;accordion-section2&quot;</span> <span class="highlight-b">aria-hidden</span>=<span class="highlight-c">&quot;true&quot;</span> <span class="highlight-b">name</span>=<span class="highlight-c">&quot;accordion&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;accordion-section2&quot;</span> <span class="highlight-b">aria-hidden</span>=<span class="highlight-c">&quot;true&quot;</span><span class="highlight-a">&gt;</span>Accordion section 2<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>This is the second section of the accordion<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`],
notes: [
`Make sure all the radio buttons in the same accordion have the same <code>name</code>.`,
`If you want a collapsible spoiler or an accordion section to be expanded by default, you can add the <code>checked</code> attribute to the respective collapsible spooiler's or section's control.`,
`The <code>max-height</code> of the content container is <code>400px</code>.`,
`Using the <code>aria-hidden=&quot;true&quot;</code> attribute is highly recommended, as screen readers will ignore the controls of the collapsible spoiler or accordion and read all the contained content normally.`
],
customization: [
`Background color, text color and background color on hover for the collapsible spoiler's labels can be changed by changing the values of <code>--collapse-label-back-color</code>, <code>--collapse-label-fore-color</code> and <code>--collapse-label-hover-back-color</code> respectively.`,
`Border color for the collapsible spoiler can be changed by changing the value of the <code>--collapse-border-color</code>.`,
`Background color for the collapsible spoiler's content can be changed by changing the value of the <code>--collapse-content-back-color</code>.`,
`Background color and border for the spoiler's content selected labels can be changed by changing the values of the <code>--collapse-selected-label-back-color</code> and <code>--collapse-selected-label-border-color</code> respectively.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [],
dos: [],
donts: [
{
description: `You should not place anything between the checkbox controlling the collapsible spoiler and its label or between the label and the content container.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;collapse&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;checkbox&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;collapse-section1&quot;</span> <span class="highlight-b">checked</span> <span class="highlight-b">aria-hidden</span>=<span class="highlight-c">&quot;true&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-c">&lt;!-- Do not place other stuff between these --&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;collapse-section1&quot;</span> <span class="highlight-b">aria-hidden</span>=<span class="highlight-c">&quot;true&quot;</span><span class="highlight-a">&gt;</span>Collapse section 1<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-c">&lt;!-- Do not place other stuff between these --&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>This is the first section of the collapse<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
}
]
}
module.exports = {
id: 'spoilers-and-accordions',
title: 'Spoilers &amp; accordions',
keywords: [`spoiler`, `collapse`, `accordion`, `contextual`, `vertical tabs`],
description: `<p><strong>mini.css</strong> provides you with accessible spoilers and accordions. They are composed of two components - the wrapper, the toggle button and the content container:</p>
<ul><li>To create a collapsible spoiler, simply create a <code>&lt;div&gt;</code>, applying the appropriate class to it (<code>.collapse</code>). This serves as the wrapper for the collapsible spoiler.</li>
<li>Inside the wrapper, create a checkbox or radio input, immediately followed by a <code>&lt;label&gt;</code> for the checkbox. The former serves as your collapsible spoiler's control, while the latter is the toggle button for your collapsible spoiler.</li>
<li>Create a <code>&lt;div&gt;</code> right after the <code>&lt;label&gt;</code>. This will serve as the container for the collapsible content.</li>
</ul>
<p>If you want to create an accordion, simply repeat the last two steps above for each section of the accordion. In order to make collapsible spoilers and accordions fully accessible, it is highly recommended to add the <code>aria-hidden=&quot;true&quot;</code> attribute to all labels and inputs that control the behavior of these components.</p>`,
example: `<div class="collapse"><input type="checkbox" id="collapse-example1" checked aria-hidden="true"><label for="collapse-example1" aria-hidden="true">Collapse section 1</label><div><p>This is the first section of the collapse</p></div><input type="checkbox" id="collapse-example2" aria-hidden="true"><label for="collapse-example2" aria-hidden="true">Collapse section 2</label><div><p>This is the second section of the collapse</p></div></div><br/>
<div class="collapse"><input type="radio" name="accordion" id="accordion-example1" checked aria-hidden="true"><label for="accordion-example1" aria-hidden="true">Accordion section 1</label><div><p>This is the first section of the accordion</p></div><input type="radio" name="accordion" id="accordion-example2" aria-hidden="true"><label for="accordion-example2" aria-hidden="true">Accordion section 2</label><div><p>This is the second section of the accordion</p></div></div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;collapse&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;checkbox&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;collapse-section1&quot;</span> <span class="highlight-b">checked</span> <span class="highlight-b">aria-hidden</span>=<span class="highlight-c">&quot;true&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;collapse-section1&quot;</span> <span class="highlight-b">aria-hidden</span>=<span class="highlight-c">&quot;true&quot;</span><span class="highlight-a">&gt;</span>Collapse section 1<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>This is the first section of the collapse<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;checkbox&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;collapse-section2&quot;</span> <span class="highlight-b">aria-hidden</span>=<span class="highlight-c">&quot;true&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;collapse-section2&quot;</span> <span class="highlight-b">aria-hidden</span>=<span class="highlight-c">&quot;true&quot;</span><span class="highlight-a">&gt;</span>Collapse section 2<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>This is the second section of the collapse<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`,
`<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;collapse&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;radio&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;accordion-section1&quot;</span> <span class="highlight-b">checked</span> <span class="highlight-b">aria-hidden</span>=<span class="highlight-c">&quot;true&quot;</span> <span class="highlight-b">name</span>=<span class="highlight-c">&quot;accordion&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;accordion-section1&quot;</span> <span class="highlight-b">aria-hidden</span>=<span class="highlight-c">&quot;true&quot;</span><span class="highlight-a">&gt;</span>Accordion section 1<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>This is the first section of the accordion<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;radio&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;accordion-section2&quot;</span> <span class="highlight-b">aria-hidden</span>=<span class="highlight-c">&quot;true&quot;</span> <span class="highlight-b">name</span>=<span class="highlight-c">&quot;accordion&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;accordion-section2&quot;</span> <span class="highlight-b">aria-hidden</span>=<span class="highlight-c">&quot;true&quot;</span><span class="highlight-a">&gt;</span>Accordion section 2<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>This is the second section of the accordion<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`],
notes: [
`Make sure all the radio buttons in the same accordion have the same <code>name</code>.`,
`If you want a collapsible spoiler or an accordion section to be expanded by default, you can add the <code>checked</code> attribute to the respective collapsible spooiler's or section's control.`,
`The <code>max-height</code> of the content container is <code>400px</code>.`,
`Using the <code>aria-hidden=&quot;true&quot;</code> attribute is highly recommended, as screen readers will ignore the controls of the collapsible spoiler or accordion and read all the contained content normally.`
],
customization: [
`Background color, text color and background color on hover for the collapsible spoiler's labels can be changed by changing the values of <code>--collapse-label-back-color</code>, <code>--collapse-label-fore-color</code> and <code>--collapse-label-hover-back-color</code> respectively.`,
`Border color for the collapsible spoiler can be changed by changing the value of the <code>--collapse-border-color</code>.`,
`Background color for the collapsible spoiler's content can be changed by changing the value of the <code>--collapse-content-back-color</code>.`,
`Background color and border for the spoiler's content selected labels can be changed by changing the values of the <code>--collapse-selected-label-back-color</code> and <code>--collapse-selected-label-border-color</code> respectively.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [],
dos: [],
donts: [
{
description: `You should not place anything between the checkbox controlling the collapsible spoiler and its label or between the label and the content container.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;div</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;collapse&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;input</span> <span class="highlight-b">type</span>=<span class="highlight-c">&quot;checkbox&quot;</span> <span class="highlight-b">id</span>=<span class="highlight-c">&quot;collapse-section1&quot;</span> <span class="highlight-b">checked</span> <span class="highlight-b">aria-hidden</span>=<span class="highlight-c">&quot;true&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"> <span class="highlight-c">&lt;!-- Do not place other stuff between these --&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;label</span> <span class="highlight-b">for</span>=<span class="highlight-c">&quot;collapse-section1&quot;</span> <span class="highlight-b">aria-hidden</span>=<span class="highlight-c">&quot;true&quot;</span><span class="highlight-a">&gt;</span>Collapse section 1<span class="highlight-a">&lt;/label&gt;</span></span>
<span class="code-line"> <span class="highlight-c">&lt;!-- Do not place other stuff between these --&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;div&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;p&gt;</span>This is the first section of the collapse<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;/div&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/div&gt;</span></span></pre>`
}
]
}

View file

@ -1,208 +1,208 @@
module.exports = {
id: 'tables',
title: 'Tables',
keywords: [`table`, `caption`, `thead`, `tbody`, `tr`, `th`, `td`, `horizontal`, `striped`, `hoverable`],
description: `<p>Tables are styled in a minimal, modern and responsive manner, allowing users on all devices to easily browse tabular data, taking advantage of the <a href="https://css-tricks.com/snippets/css/a-guide-to-flexbox/" target="_blank">Flexbox layout</a>'s capabilities. To make tabular data properly display on mobile devices, remember to specify a <code>data-label</code> attribute for each <code>&lt;&gt;</code> element (usually same as the heading of the column).</p>`,
example: `<h6 style="text-align:center">Desktop view</h6>
<table class="doc"><caption class="doc">People</caption>
<thead class="doc"><tr class="doc"><th class="doc">Name</th><th class="doc">Surname</th><th class="doc">Alias</th></tr></thead>
<tbody class="doc">
<tr class="doc"><td data-label="Name" class="doc">Chad</td><td data-label="Surname" class="doc">Wilberts</td><td data-label="Alias" class="doc">MrOne</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Adam</td><td data-label="Surname" class="doc">Smith</td><td data-label="Alias" class="doc">TheSmith</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Sophia</td><td data-label="Surname" class="doc">Canderson</td><td data-label="Alias" class="doc">Candee</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Nick</td><td data-label="Surname" class="doc">Thomson</td><td data-label="Alias" class="doc">NickThom</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Mark</td><td data-label="Surname" class="doc">Gerkis</td><td data-label="Alias" class="doc">Markie</td></tr>
<tr class="doc"><td data-label="Name" class="doc">John</td><td data-label="Surname" class="doc">Fergusson</td><td data-label="Alias" class="doc">Fergujohn</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Sylvia</td><td data-label="Surname" class="doc">Pouleau</td><td data-label="Alias" class="doc">Sylver</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Norman</td><td data-label="Surname" class="doc">Jones</td><td data-label="Alias" class="doc">NormalJones</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Trevor</td><td data-label="Surname" class="doc">Heidel</td><td data-label="Alias" class="doc">Heidi</td></tr>
</tbody>
</table><br/><h6 style="text-align:center">Mobile view</h6>
<table class="doc cardized"><caption class="doc">People</caption>
<thead class="doc"><tr class="doc"><th class="doc">Name</th><th class="doc">Surname</th><th class="doc">Alias</th></tr></thead>
<tbody class="doc">
<tr class="doc"><td data-label="Name" class="doc">Chad</td><td data-label="Surname" class="doc">Wilberts</td><td data-label="Alias" class="doc">MrOne</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Adam</td><td data-label="Surname" class="doc">Smith</td><td data-label="Alias" class="doc">TheSmith</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Sophia</td><td data-label="Surname" class="doc">Canderson</td><td data-label="Alias" class="doc">Candee</td></tr>
</tbody>
</table>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;table&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;caption&gt;</span>People<span class="highlight-a">&lt;/caption&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;thead&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Name<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Surname<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Alias<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/thead&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tbody&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Chad<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Wilberts<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>MrOne<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Adam<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Smith<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>TheSmith<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Sophia<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Canderson<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>Candee<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tbody&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/table&gt;</span></span></pre>`],
notes: [`Remember to always specify a <code>data-label</code> attribute for all of your <code>&lt;td&gt;</code> elements, otherwise they will not display properly on mobile.`,
`Due to the way tables are displayed, the <code>&lt;tfoot&gt;</code> element is not supported.`,
`Tables are vertically scrollable by default, with a <code>max-height</code> property of <code>400px</code>.`],
customization: [
`Text color for <code>&lt;th&gt;</code> and <code>&lt;td&gt;</code> elements can be changed by changing the values of the <code>--table-head-fore-color</code> and <code>--table-body-fore-color</code> variables respectively.`,
`Background color for <code>&lt;th&gt;</code> and <code>&lt;td&gt;</code> elements can be changed by changing the values of the <code>--table-head-back-color</code> and <code>--table-body-back-color</code> variables respectively.`,
`Border color for tables can be changed by changing the value of the <code>--table-border-color</code> variable.`,
`Border color for the separator between a table's heading and a table's body can be changed by changing the value of the <code>--table-border-separator-color</code> variable.`,
`Alternative background color for <code>&lt;td&gt;</code> elements in striped tables can be changed by changing the value of the <code>--table-body-alt-back-color</code> variable.`,
`Hover background color for <code>&lt;tr&gt;</code> elements in hoverable tables can be changed by changing the value of the <code>--table-body-hover-back-color</code> variable.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [
{
title : 'Horizontal tables',
description: `<p>You can create horizontal tables (<code>.horizontal</code>), by applying the appropriate class.</p>`,
example: `<table class="doc horizontal"><caption class="doc">People</caption>
<thead class="doc"><tr class="doc"><th class="doc">Name</th><th class="doc">Surname</th><th class="doc">Alias</th></tr></thead>
<tbody class="doc">
<tr class="doc"><td data-label="Name" class="doc">Chad</td><td data-label="Surname" class="doc">Wilberts</td><td data-label="Alias" class="doc">MrOne</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Adam</td><td data-label="Surname" class="doc">Smith</td><td data-label="Alias" class="doc">TheSmith</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Sophia</td><td data-label="Surname" class="doc">Canderson</td><td data-label="Alias" class="doc">Candee</td></tr>
</tbody>
</table>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;table</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;horizontal&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;caption&gt;</span>People<span class="highlight-a">&lt;/caption&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;thead&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Name<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Surname<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Alias<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/thead&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tbody&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Chad<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Wilberts<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>MrOne<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Adam<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Smith<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>TheSmith<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Sophia<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Canderson<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>Candee<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tbody&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/table&gt;</span></span></pre>`]
},
{
title : 'Striped tables',
description: `<p>You can create striped tables (<code>.striped</code>), by applying the appropriate class.</p>`,
example: `<table class="doc striped"><caption class="doc">People</caption>
<thead class="doc"><tr class="doc"><th class="doc">Name</th><th class="doc">Surname</th><th class="doc">Alias</th></tr></thead>
<tbody class="doc">
<tr class="doc"><td data-label="Name" class="doc">Chad</td><td data-label="Surname" class="doc">Wilberts</td><td data-label="Alias" class="doc">MrOne</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Adam</td><td data-label="Surname" class="doc">Smith</td><td data-label="Alias" class="doc">TheSmith</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Sophia</td><td data-label="Surname" class="doc">Canderson</td><td data-label="Alias" class="doc">Candee</td></tr>
</tbody>
</table>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;table</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;striped&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;caption&gt;</span>People<span class="highlight-a">&lt;/caption&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;thead&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Name<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Surname<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Alias<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/thead&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tbody&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Chad<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Wilberts<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>MrOne<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Adam<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Smith<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>TheSmith<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Sophia<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Canderson<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>Candee<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tbody&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/table&gt;</span></span></pre>`]
},
{
title : 'Hoverable tables',
description: `<p>You can create hoverable tables (<code>.hoverable</code>), by applying the appropriate class.</p>`,
example: `<table class="doc hoverable"><caption class="doc">People</caption>
<thead class="doc"><tr class="doc"><th class="doc">Name</th><th class="doc">Surname</th><th class="doc">Alias</th></tr></thead>
<tbody class="doc">
<tr class="doc"><td data-label="Name" class="doc">Chad</td><td data-label="Surname" class="doc">Wilberts</td><td data-label="Alias" class="doc">MrOne</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Adam</td><td data-label="Surname" class="doc">Smith</td><td data-label="Alias" class="doc">TheSmith</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Sophia</td><td data-label="Surname" class="doc">Canderson</td><td data-label="Alias" class="doc">Candee</td></tr>
</tbody>
</table>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;table</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;hoverable&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;caption&gt;</span>People<span class="highlight-a">&lt;/caption&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;thead&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Name<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Surname<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Alias<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/thead&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tbody&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Chad<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Wilberts<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>MrOne<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Adam<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Smith<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>TheSmith<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Sophia<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Canderson<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>Candee<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tbody&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/table&gt;</span></span></pre>`]
}
],
dos: [],
donts: [
{
description: `Avoid placing <code>&lt;td&gt;</code> elements in the <code>&lt;thead&gt;</code> of your tables, as well as placing <code>&lt;th&gt;</code> elements in the <code>&lt;tbody&gt;</code>.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;table&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;caption&gt;</span>People<span class="highlight-a">&lt;/caption&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;thead&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td&gt;</span>Bad idea<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/thead&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tbody&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Bad&quot;</span><span class="highlight-a">&gt;</span>Also bad idea<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tbody&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/table&gt;</span></span></pre>`
}
]
}
module.exports = {
id: 'tables',
title: 'Tables',
keywords: [`table`, `caption`, `thead`, `tbody`, `tr`, `th`, `td`, `horizontal`, `striped`, `hoverable`],
description: `<p>Tables are styled in a minimal, modern and responsive manner, allowing users on all devices to easily browse tabular data, taking advantage of the <a href="https://css-tricks.com/snippets/css/a-guide-to-flexbox/" target="_blank">Flexbox layout</a>'s capabilities. To make tabular data properly display on mobile devices, remember to specify a <code>data-label</code> attribute for each <code>&lt;&gt;</code> element (usually same as the heading of the column).</p>`,
example: `<h6 style="text-align:center">Desktop view</h6>
<table class="doc"><caption class="doc">People</caption>
<thead class="doc"><tr class="doc"><th class="doc">Name</th><th class="doc">Surname</th><th class="doc">Alias</th></tr></thead>
<tbody class="doc">
<tr class="doc"><td data-label="Name" class="doc">Chad</td><td data-label="Surname" class="doc">Wilberts</td><td data-label="Alias" class="doc">MrOne</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Adam</td><td data-label="Surname" class="doc">Smith</td><td data-label="Alias" class="doc">TheSmith</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Sophia</td><td data-label="Surname" class="doc">Canderson</td><td data-label="Alias" class="doc">Candee</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Nick</td><td data-label="Surname" class="doc">Thomson</td><td data-label="Alias" class="doc">NickThom</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Mark</td><td data-label="Surname" class="doc">Gerkis</td><td data-label="Alias" class="doc">Markie</td></tr>
<tr class="doc"><td data-label="Name" class="doc">John</td><td data-label="Surname" class="doc">Fergusson</td><td data-label="Alias" class="doc">Fergujohn</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Sylvia</td><td data-label="Surname" class="doc">Pouleau</td><td data-label="Alias" class="doc">Sylver</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Norman</td><td data-label="Surname" class="doc">Jones</td><td data-label="Alias" class="doc">NormalJones</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Trevor</td><td data-label="Surname" class="doc">Heidel</td><td data-label="Alias" class="doc">Heidi</td></tr>
</tbody>
</table><br/><h6 style="text-align:center">Mobile view</h6>
<table class="doc cardized"><caption class="doc">People</caption>
<thead class="doc"><tr class="doc"><th class="doc">Name</th><th class="doc">Surname</th><th class="doc">Alias</th></tr></thead>
<tbody class="doc">
<tr class="doc"><td data-label="Name" class="doc">Chad</td><td data-label="Surname" class="doc">Wilberts</td><td data-label="Alias" class="doc">MrOne</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Adam</td><td data-label="Surname" class="doc">Smith</td><td data-label="Alias" class="doc">TheSmith</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Sophia</td><td data-label="Surname" class="doc">Canderson</td><td data-label="Alias" class="doc">Candee</td></tr>
</tbody>
</table>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;table&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;caption&gt;</span>People<span class="highlight-a">&lt;/caption&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;thead&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Name<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Surname<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Alias<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/thead&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tbody&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Chad<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Wilberts<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>MrOne<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Adam<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Smith<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>TheSmith<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Sophia<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Canderson<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>Candee<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tbody&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/table&gt;</span></span></pre>`],
notes: [`Remember to always specify a <code>data-label</code> attribute for all of your <code>&lt;td&gt;</code> elements, otherwise they will not display properly on mobile.`,
`Due to the way tables are displayed, the <code>&lt;tfoot&gt;</code> element is not supported.`,
`Tables are vertically scrollable by default, with a <code>max-height</code> property of <code>400px</code>.`],
customization: [
`Text color for <code>&lt;th&gt;</code> and <code>&lt;td&gt;</code> elements can be changed by changing the values of the <code>--table-head-fore-color</code> and <code>--table-body-fore-color</code> variables respectively.`,
`Background color for <code>&lt;th&gt;</code> and <code>&lt;td&gt;</code> elements can be changed by changing the values of the <code>--table-head-back-color</code> and <code>--table-body-back-color</code> variables respectively.`,
`Border color for tables can be changed by changing the value of the <code>--table-border-color</code> variable.`,
`Border color for the separator between a table's heading and a table's body can be changed by changing the value of the <code>--table-border-separator-color</code> variable.`,
`Alternative background color for <code>&lt;td&gt;</code> elements in striped tables can be changed by changing the value of the <code>--table-body-alt-back-color</code> variable.`,
`Hover background color for <code>&lt;tr&gt;</code> elements in hoverable tables can be changed by changing the value of the <code>--table-body-hover-back-color</code> variable.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [
{
title : 'Horizontal tables',
description: `<p>You can create horizontal tables (<code>.horizontal</code>), by applying the appropriate class.</p>`,
example: `<table class="doc horizontal"><caption class="doc">People</caption>
<thead class="doc"><tr class="doc"><th class="doc">Name</th><th class="doc">Surname</th><th class="doc">Alias</th></tr></thead>
<tbody class="doc">
<tr class="doc"><td data-label="Name" class="doc">Chad</td><td data-label="Surname" class="doc">Wilberts</td><td data-label="Alias" class="doc">MrOne</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Adam</td><td data-label="Surname" class="doc">Smith</td><td data-label="Alias" class="doc">TheSmith</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Sophia</td><td data-label="Surname" class="doc">Canderson</td><td data-label="Alias" class="doc">Candee</td></tr>
</tbody>
</table>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;table</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;horizontal&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;caption&gt;</span>People<span class="highlight-a">&lt;/caption&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;thead&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Name<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Surname<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Alias<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/thead&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tbody&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Chad<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Wilberts<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>MrOne<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Adam<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Smith<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>TheSmith<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Sophia<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Canderson<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>Candee<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tbody&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/table&gt;</span></span></pre>`]
},
{
title : 'Striped tables',
description: `<p>You can create striped tables (<code>.striped</code>), by applying the appropriate class.</p>`,
example: `<table class="doc striped"><caption class="doc">People</caption>
<thead class="doc"><tr class="doc"><th class="doc">Name</th><th class="doc">Surname</th><th class="doc">Alias</th></tr></thead>
<tbody class="doc">
<tr class="doc"><td data-label="Name" class="doc">Chad</td><td data-label="Surname" class="doc">Wilberts</td><td data-label="Alias" class="doc">MrOne</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Adam</td><td data-label="Surname" class="doc">Smith</td><td data-label="Alias" class="doc">TheSmith</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Sophia</td><td data-label="Surname" class="doc">Canderson</td><td data-label="Alias" class="doc">Candee</td></tr>
</tbody>
</table>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;table</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;striped&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;caption&gt;</span>People<span class="highlight-a">&lt;/caption&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;thead&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Name<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Surname<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Alias<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/thead&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tbody&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Chad<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Wilberts<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>MrOne<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Adam<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Smith<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>TheSmith<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Sophia<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Canderson<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>Candee<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tbody&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/table&gt;</span></span></pre>`]
},
{
title : 'Hoverable tables',
description: `<p>You can create hoverable tables (<code>.hoverable</code>), by applying the appropriate class.</p>`,
example: `<table class="doc hoverable"><caption class="doc">People</caption>
<thead class="doc"><tr class="doc"><th class="doc">Name</th><th class="doc">Surname</th><th class="doc">Alias</th></tr></thead>
<tbody class="doc">
<tr class="doc"><td data-label="Name" class="doc">Chad</td><td data-label="Surname" class="doc">Wilberts</td><td data-label="Alias" class="doc">MrOne</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Adam</td><td data-label="Surname" class="doc">Smith</td><td data-label="Alias" class="doc">TheSmith</td></tr>
<tr class="doc"><td data-label="Name" class="doc">Sophia</td><td data-label="Surname" class="doc">Canderson</td><td data-label="Alias" class="doc">Candee</td></tr>
</tbody>
</table>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;table</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;hoverable&quot;</span><span class="highlight-a">&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;caption&gt;</span>People<span class="highlight-a">&lt;/caption&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;thead&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Name<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Surname<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th&gt;</span>Alias<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/thead&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tbody&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Chad<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Wilberts<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>MrOne<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Adam<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Smith<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>TheSmith<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Name&quot;</span><span class="highlight-a">&gt;</span>Sophia<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Surname&quot;</span><span class="highlight-a">&gt;</span>Canderson<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Alias&quot;</span><span class="highlight-a">&gt;</span>Candee<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tbody&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/table&gt;</span></span></pre>`]
}
],
dos: [],
donts: [
{
description: `Avoid placing <code>&lt;td&gt;</code> elements in the <code>&lt;thead&gt;</code> of your tables, as well as placing <code>&lt;th&gt;</code> elements in the <code>&lt;tbody&gt;</code>.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;table&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;caption&gt;</span>People<span class="highlight-a">&lt;/caption&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;thead&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;td&gt;</span>Bad idea<span class="highlight-a">&lt;/td&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/thead&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tbody&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;tr&gt;</span></span>
<span class="code-line"> <span class="highlight-a">&lt;th</span> <span class="highlight-b">data-label</span>=<span class="highlight-c">&quot;Bad&quot;</span><span class="highlight-a">&gt;</span>Also bad idea<span class="highlight-a">&lt;/th&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tr&gt;</span></span>
<span class="code-line"><span class="highlight-a"> &lt;/tbody&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;/table&gt;</span></span></pre>`
}
]
}

View file

@ -1,28 +1,28 @@
module.exports = {
id: '',
title: '',
keywords: [],
description: '',
example: '',
samples: [],
notes: [],
customization: [],
modifiers: [],
dos: [],
donts: []
}
/*
Modifiers:
{
title : '',
description: '',
example: '',
samples: []
}
Dos/Donts:
{
description: '',
sample: ''
}
*/
module.exports = {
id: '',
title: '',
keywords: [],
description: '',
example: '',
samples: [],
notes: [],
customization: [],
modifiers: [],
dos: [],
donts: []
}
/*
Modifiers:
{
title : '',
description: '',
example: '',
samples: []
}
Dos/Donts:
{
description: '',
sample: ''
}
*/

View file

@ -1,43 +1,43 @@
module.exports = {
id: 'text-highlighting',
title: 'Text highlighting',
keywords: [`mark`, `highlight`, `text highlighting`, `tag`, `primary`, `secondary`, `tertiary`, `inline-block`],
description: `<p>The native HTML5 mark element has been minimally styled to allow for easy text highlighting.</p>`,
example: `<p class="doc">This is a paragraph with some <mark class="doc">highlighted text</mark>.</p>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;p&gt;</span>This is some <span class="highlight-a">&lt;mark&gt;</span>highlighted text<span class="highlight-a">&lt;/mark&gt;</span>.<span class="highlight-a">&lt;/p&gt;</span></span></pre>`],
notes: [
`Highlighted text scales according to its parent element, so it can be used inside any kind of element (headings, forms, paragraphs etc.).`
],
customization: [
`Text color for highlighted text can be changed by changing the value of the <code>--mark-fore-color</code> variable.`,
`Background color for highlighted text can be changed by changing the value of the <code>--mark-back-color</code> variable.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [
{
title : 'Color variants',
description: '<p>You can change the color of highlighted text, based on context by applying the appropriate class (secondary - <code>.secondary</code> or tertiary - <code>.tertiary</code>).</p>',
example: `<p class="doc">This is a <mark class="doc secondary">secondary highlight</mark> and this is a <mark class="doc tertiary">tertiary highlight</mark>.</p>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;p&gt;</span>This is a <span class="highlight-a">&lt;mark</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;secondary&quot;</span><span class="highlight-a">&gt;</span>secondary highlight<span class="highlight-a">&lt;/mark&gt;</span> and this is a <span class="highlight-a">&lt;mark</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;tertiary&quot;</span><span class="highlight-a">&gt;</span>tertiary highlight<span class="highlight-a">&lt;/mark&gt;</span>.<span class="highlight-a">&lt;/p&gt;</span></span></pre>`]
},
{
title : 'Style variants',
description: `<p>You can make highlights look like tags (<code>.tag</code>) or display as inline blocks (<code>.inline-block</code>), by applying the appropriate class.</p>`,
example: `<p class="doc">This is a highlight styled as a <mark class="doc tag">tag</mark>.</p><p><mark class="doc inline-block">This is some highlighted text that is displayed as an inline block.</mark></p>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;p&gt;</span>This is a highlight styled as a <span class="highlight-a">&lt;mark</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;tag&quot;</span><span class="highlight-a">&gt;</span>tag<span class="highlight-a">&lt;/mark&gt;</span>.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;p&gt;</span><span class="highlight-a">&lt;mark</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;inline-block&quot;</span><span class="highlight-a">&gt;</span>This is some highlighted text that is displayed as an inline block.<span class="highlight-a">&lt;/mark&gt;</span><span class="highlight-a">&lt;/p&gt;</span></span></pre>`]
}
],
dos: [{
description: `You can nest a highlight inside another one, if the outer one is displayed as an inline-block.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;mark</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;inline-block&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;mark</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;secondary&quot;</span><span class="highlight-a">&gt;</span>Secondary highlight<span class="highlight-a">&lt;/mark&gt;</span> inside a inline block.<span class="highlight-a">&lt;/mark&gt;</span></span></pre>`
}],
donts: [
{
description: `Avoid applying multiple color modifiers on the same highlight.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;mark</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;primary inverse&quot;</span><span class="highlight-a">&gt;</span>Highlight<span class="highlight-a">&lt;/mark&gt;</span></span>
</pre>`
}
]
}
module.exports = {
id: 'text-highlighting',
title: 'Text highlighting',
keywords: [`mark`, `highlight`, `text highlighting`, `tag`, `primary`, `secondary`, `tertiary`, `inline-block`],
description: `<p>The native HTML5 mark element has been minimally styled to allow for easy text highlighting.</p>`,
example: `<p class="doc">This is a paragraph with some <mark class="doc">highlighted text</mark>.</p>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;p&gt;</span>This is some <span class="highlight-a">&lt;mark&gt;</span>highlighted text<span class="highlight-a">&lt;/mark&gt;</span>.<span class="highlight-a">&lt;/p&gt;</span></span></pre>`],
notes: [
`Highlighted text scales according to its parent element, so it can be used inside any kind of element (headings, forms, paragraphs etc.).`
],
customization: [
`Text color for highlighted text can be changed by changing the value of the <code>--mark-fore-color</code> variable.`,
`Background color for highlighted text can be changed by changing the value of the <code>--mark-back-color</code> variable.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [
{
title : 'Color variants',
description: '<p>You can change the color of highlighted text, based on context by applying the appropriate class (secondary - <code>.secondary</code> or tertiary - <code>.tertiary</code>).</p>',
example: `<p class="doc">This is a <mark class="doc secondary">secondary highlight</mark> and this is a <mark class="doc tertiary">tertiary highlight</mark>.</p>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;p&gt;</span>This is a <span class="highlight-a">&lt;mark</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;secondary&quot;</span><span class="highlight-a">&gt;</span>secondary highlight<span class="highlight-a">&lt;/mark&gt;</span> and this is a <span class="highlight-a">&lt;mark</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;tertiary&quot;</span><span class="highlight-a">&gt;</span>tertiary highlight<span class="highlight-a">&lt;/mark&gt;</span>.<span class="highlight-a">&lt;/p&gt;</span></span></pre>`]
},
{
title : 'Style variants',
description: `<p>You can make highlights look like tags (<code>.tag</code>) or display as inline blocks (<code>.inline-block</code>), by applying the appropriate class.</p>`,
example: `<p class="doc">This is a highlight styled as a <mark class="doc tag">tag</mark>.</p><p><mark class="doc inline-block">This is some highlighted text that is displayed as an inline block.</mark></p>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;p&gt;</span>This is a highlight styled as a <span class="highlight-a">&lt;mark</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;tag&quot;</span><span class="highlight-a">&gt;</span>tag<span class="highlight-a">&lt;/mark&gt;</span>.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;p&gt;</span><span class="highlight-a">&lt;mark</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;inline-block&quot;</span><span class="highlight-a">&gt;</span>This is some highlighted text that is displayed as an inline block.<span class="highlight-a">&lt;/mark&gt;</span><span class="highlight-a">&lt;/p&gt;</span></span></pre>`]
}
],
dos: [{
description: `You can nest a highlight inside another one, if the outer one is displayed as an inline-block.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;mark</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;inline-block&quot;</span><span class="highlight-a">&gt;</span><span class="highlight-a">&lt;mark</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;secondary&quot;</span><span class="highlight-a">&gt;</span>Secondary highlight<span class="highlight-a">&lt;/mark&gt;</span> inside a inline block.<span class="highlight-a">&lt;/mark&gt;</span></span></pre>`
}],
donts: [
{
description: `Avoid applying multiple color modifiers on the same highlight.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;mark</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;primary inverse&quot;</span><span class="highlight-a">&gt;</span>Highlight<span class="highlight-a">&lt;/mark&gt;</span></span>
</pre>`
}
]
}

View file

@ -1,21 +1,21 @@
module.exports = {
id: 'toasts',
title: 'Toasts',
keywords: [`span`, `toast`, `mobile`, `contextual`, `message`],
description: `<p><strong>mini.css</strong> provides you with toast messages (<code>.toast</code>), allowing you to display native-looking notifications on mobile devices.</p>`,
example: `<div class="container" style="height: 8rem; position: relative;"><span class="toast doc" style="position: absolute;">This is a toast message!</span></div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;toast&quot;</span><span class="highlight-a">&gt;</span>This is a toast message!<span class="highlight-a">&lt;/span&gt;</span></span></pre>`],
notes: [
`Toast elements do not have any pre-defined behavior, but you can use Javascript to add functionality to them.`
],
customization: [
`Text color for toast messages can be changed by changing the value of the <code>--toast-fore-color</code> variable.`,
`Background color for toast messages can be changed by changing the value of the <code>--toast-back-color</code> variable.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [],
dos: [],
donts: []
}
module.exports = {
id: 'toasts',
title: 'Toasts',
keywords: [`span`, `toast`, `mobile`, `contextual`, `message`],
description: `<p><strong>mini.css</strong> provides you with toast messages (<code>.toast</code>), allowing you to display native-looking notifications on mobile devices.</p>`,
example: `<div class="container" style="height: 8rem; position: relative;"><span class="toast doc" style="position: absolute;">This is a toast message!</span></div>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;toast&quot;</span><span class="highlight-a">&gt;</span>This is a toast message!<span class="highlight-a">&lt;/span&gt;</span></span></pre>`],
notes: [
`Toast elements do not have any pre-defined behavior, but you can use Javascript to add functionality to them.`
],
customization: [
`Text color for toast messages can be changed by changing the value of the <code>--toast-fore-color</code> variable.`,
`Background color for toast messages can be changed by changing the value of the <code>--toast-back-color</code> variable.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [],
dos: [],
donts: []
}

View file

@ -1,28 +1,28 @@
module.exports = {
id: 'tooltips',
title: 'Tooltips',
keywords: [`tooltip`, `aria-label`, `contextual`, `bottom`, `span`],
description: `<p>You can utilize the <code>aria-label</code> property to create accessible tooltips (<code>.tooltip</code>), allowing you to display explanatory text for different elements.</p>`,
example: `<p class="tooltip" aria-label="This is a tooltip">Hover over this text to see a tooltip!</p>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;tooltip&quot;</span> <span class="highlight-b">aria-label</span>=<span class="highlight-c">&quot;Tooltip text&quot;</span><span class="highlight-a">&gt;</span>Hover over text to see tooltip<span class="highlight-a">&lt;/span&gt;</span></span></pre>`],
notes: [
`Tooltips depend on the <code>aria-label</code> property, so they are fully accessible on screen readers.`
],
customization: [
`Text color for tooltips can be changed by changing the value of the <code>--tooltip-fore-color</code> variable.`,
`Background color for tooltips can be changed by changing the value of the <code>--tooltip-back-color</code> variable.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [
{
title : 'Position variant',
description: '<p>You can make tooltips display below the related text, by adding the appropriate class (<code>.bottom</code>).</p>',
example: `<p class="tooltip bottom" aria-label="This is a bottom tooltip">Hover over this text to see a tooltip!</p>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;tooltip bottom&quot;</span> <span class="highlight-b">aria-label</span>=<span class="highlight-c">&quot;Tooltip text&quot;</span><span class="highlight-a">&gt;</span>Hover over text to see tooltip<span class="highlight-a">&lt;/span&gt;</span></span></pre>`]
}
],
dos: [],
donts: []
}
module.exports = {
id: 'tooltips',
title: 'Tooltips',
keywords: [`tooltip`, `aria-label`, `contextual`, `bottom`, `span`],
description: `<p>You can utilize the <code>aria-label</code> property to create accessible tooltips (<code>.tooltip</code>), allowing you to display explanatory text for different elements.</p>`,
example: `<p class="tooltip" aria-label="This is a tooltip">Hover over this text to see a tooltip!</p>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;tooltip&quot;</span> <span class="highlight-b">aria-label</span>=<span class="highlight-c">&quot;Tooltip text&quot;</span><span class="highlight-a">&gt;</span>Hover over text to see tooltip<span class="highlight-a">&lt;/span&gt;</span></span></pre>`],
notes: [
`Tooltips depend on the <code>aria-label</code> property, so they are fully accessible on screen readers.`
],
customization: [
`Text color for tooltips can be changed by changing the value of the <code>--tooltip-fore-color</code> variable.`,
`Background color for tooltips can be changed by changing the value of the <code>--tooltip-back-color</code> variable.`,
`Universal margin for elements can be changed globally by changing the value of the <code>--universal-margin</code> variable. As a rule of thumb, consider the universal margin to be the distance you want your paragraphs to have from the sides of the screen.`,
`Universal padding for elements can be changed globally by changing the value of the <code>--universal-padding</code> variable.`,
`Universal border radius for elements can be changed globally by changing the value of the <code>--universal-border-radius</code> variable.`
],
modifiers: [
{
title : 'Position variant',
description: '<p>You can make tooltips display below the related text, by adding the appropriate class (<code>.bottom</code>).</p>',
example: `<p class="tooltip bottom" aria-label="This is a bottom tooltip">Hover over this text to see a tooltip!</p>`,
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;span</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;tooltip bottom&quot;</span> <span class="highlight-b">aria-label</span>=<span class="highlight-c">&quot;Tooltip text&quot;</span><span class="highlight-a">&gt;</span>Hover over text to see tooltip<span class="highlight-a">&lt;/span&gt;</span></span></pre>`]
}
],
dos: [],
donts: []
}

View file

@ -1,34 +1,34 @@
module.exports = {
id: 'visibility-helpers',
title: 'Visibility helpers',
keywords: ['hidden', 'visibility', 'visually-hidden', 'accessibility', 'utility'],
description: '<p>You can use visibility helper classes to hide elements for all users (<code>.hidden</code>) or for users not on screen readers (<code>.visually-hidden</code>). There are also responsive visibility helpers provided, for hiding or visually hiding content only for specific screen sizes (<code>.hidden-sm</code>, <code>.hidden-md</code>, <code>.hidden-lg</code> and <code>.visually-hidden-sm</code>, <code>.visually-hidden-md</code> and <code>.visually-hidden-lg</code> respectively).</p>',
example: '',
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;hidden&quot;</span><span class="highlight-a">&gt;</span>Not visible for any users.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;visually-hidden&quot;</span><span class="highlight-a">&gt;</span>Visible only for screen readers.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;hidden-sm&quot;</span><span class="highlight-a">&gt;</span>Not visible for users on screens under 768px wide.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;hidden-md&quot;</span><span class="highlight-a">&gt;</span>Not visible for users on screens 768px-1280px wide.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;hidden-lg&quot;</span><span class="highlight-a">&gt;</span>Not visible for users on screens wider than 1280px.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;visually-hidden-sm&quot;</span><span class="highlight-a">&gt;</span>Visible only for screen readers under 768px wide.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;visually-hidden-md&quot;</span><span class="highlight-a">&gt;</span>Visible only for screen readers 768px-1280px wide.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;visually-hidden-lg&quot;</span><span class="highlight-a">&gt;</span>Visible only for screen readers wider than 1280px.<span class="highlight-a">&lt;/p&gt;</span></span></pre>`],
notes: [
'Visibility helpers use <code>!important</code> declarations to override any other styles, so exercise caution when using them.',
'The specific breakpoints for small, medium and large screen sizes are as follows:<ul><li>small: less than <code>768px</code> wide</li><li>medium: more than or equal to <code>768px</code> wide and less than <code>1280px</code> wide</li><li>large: <code>1280px</code> wide or more</li></ul>',
'Responsive visibility helper classes are independent, meaning that hiding or visually hiding an element in one screen size will not affect its visibility in any other screen size.'
],
customization: [],
modifiers: [],
dos: [
{
description: `You can apply multiple responsive visibility helpers on the same element.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;hidden-sm hidden-md&quot;</span><span class="highlight-a">&gt;</span>Not visible for users on screens under 1280px wide.<span class="highlight-a">&lt;/p&gt;</span></span></pre>`
}
],
donts: [
{
description: `Avoid combining <code>.hidden</code> and <code>.visually-hidden</code> or responsive helpers for the same screen size.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;hidden visually-hidden&quot;</span><span class="highlight-a">&gt;</span>Do not do this.<span class="highlight-a">&lt;/p&gt;</span></span></pre>`
}
]
}
module.exports = {
id: 'visibility-helpers',
title: 'Visibility helpers',
keywords: ['hidden', 'visibility', 'visually-hidden', 'accessibility', 'utility'],
description: '<p>You can use visibility helper classes to hide elements for all users (<code>.hidden</code>) or for users not on screen readers (<code>.visually-hidden</code>). There are also responsive visibility helpers provided, for hiding or visually hiding content only for specific screen sizes (<code>.hidden-sm</code>, <code>.hidden-md</code>, <code>.hidden-lg</code> and <code>.visually-hidden-sm</code>, <code>.visually-hidden-md</code> and <code>.visually-hidden-lg</code> respectively).</p>',
example: '',
samples: [`<pre><span class="code-line"><span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;hidden&quot;</span><span class="highlight-a">&gt;</span>Not visible for any users.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;visually-hidden&quot;</span><span class="highlight-a">&gt;</span>Visible only for screen readers.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;hidden-sm&quot;</span><span class="highlight-a">&gt;</span>Not visible for users on screens under 768px wide.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;hidden-md&quot;</span><span class="highlight-a">&gt;</span>Not visible for users on screens 768px-1280px wide.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;hidden-lg&quot;</span><span class="highlight-a">&gt;</span>Not visible for users on screens wider than 1280px.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;visually-hidden-sm&quot;</span><span class="highlight-a">&gt;</span>Visible only for screen readers under 768px wide.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;visually-hidden-md&quot;</span><span class="highlight-a">&gt;</span>Visible only for screen readers 768px-1280px wide.<span class="highlight-a">&lt;/p&gt;</span></span>
<span class="code-line"><span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;visually-hidden-lg&quot;</span><span class="highlight-a">&gt;</span>Visible only for screen readers wider than 1280px.<span class="highlight-a">&lt;/p&gt;</span></span></pre>`],
notes: [
'Visibility helpers use <code>!important</code> declarations to override any other styles, so exercise caution when using them.',
'The specific breakpoints for small, medium and large screen sizes are as follows:<ul><li>small: less than <code>768px</code> wide</li><li>medium: more than or equal to <code>768px</code> wide and less than <code>1280px</code> wide</li><li>large: <code>1280px</code> wide or more</li></ul>',
'Responsive visibility helper classes are independent, meaning that hiding or visually hiding an element in one screen size will not affect its visibility in any other screen size.'
],
customization: [],
modifiers: [],
dos: [
{
description: `You can apply multiple responsive visibility helpers on the same element.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;hidden-sm hidden-md&quot;</span><span class="highlight-a">&gt;</span>Not visible for users on screens under 1280px wide.<span class="highlight-a">&lt;/p&gt;</span></span></pre>`
}
],
donts: [
{
description: `Avoid combining <code>.hidden</code> and <code>.visually-hidden</code> or responsive helpers for the same screen size.`,
sample: `<pre><span class="code-line"><span class="highlight-a">&lt;p</span> <span class="highlight-b">class</span>=<span class="highlight-c">&quot;hidden visually-hidden&quot;</span><span class="highlight-a">&gt;</span>Do not do this.<span class="highlight-a">&lt;/p&gt;</span></span></pre>`
}
]
}

View file

@ -1,389 +1,389 @@
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<title>mini.css - Card</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, module, card ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-centered { text-align: center; } .box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;} .box-colored.red { background: #e53935; }
.box-centered > .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto;} [class^='col-'] .card.fluid { margin: 2px 0 20px; }
[class^='fore-'] { font-family: monospace, monospace;} .fore-primary { color: #0d47a1;} .fore-secondary { color: #b71c1c;} .fore-tertiary { color: #1b5e20;}
.col-sm-12.col-sm-last.col-md-12.col-md-normal {box-sizing: border-box;border-bottom: 1px solid #c9c9c9;}
@media (max-width: 767px){.col-sm-12.col-sm-last.col-md-12.col-md-normal {border: 0;border-top: 1px solid #c9c9c9;}}
.box-colored.green { background: #689f38; } .do {border-top: 15px solid #689f38;padding-top: 10px;} .dont {border-top: 15px solid #e53935;padding-top: 10px;}
.box-colored {color: #f5f5f5;} @media (max-width: 767px){.container#co {padding: 0.25rem !important;}.col-sm-12.col-md-8.col-lg-10#col{padding: 0 !important;}}
@media screen and (min-width: 768px) { .drawer { margin-top: 4px;}}
</style>
</head>
<body>
<header class="sticky">
<a href="index" class="logo"><span id="header-logo">m</span></a>
<label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="index" class="button hidden-sm">Introduction</a> <a href="modules" class="button hidden-sm">Modules</a>
<a href="flavors" class="button hidden-sm">Flavors</a> <a href="templates" class="button hidden-sm">Templates</a>
<a href="customization" class="button hidden-sm">Customization</a> <a href="quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<div class="container" style="padding-left: 0.25rem;">
<div class="row"> <input type="checkbox" id="navigation-toggle"> <nav class="drawer col-md-4 col-lg-2">
<label class="close" for="navigation-toggle"></label>
<a href="index"><h4 style="margin-left: 0;">Introduction</h4></a>
<h4 style="margin-left: 0;">Modules</h4> <a href="core#core-title">Core</a>
<a href="core#typography" class="sublink-1">Typography</a> <a href="core#headings" class="sublink-1">Headings</a>
<a href="core#common-textual-elements" class="sublink-1">Common textual elements</a>
<a href="core#lists" class="sublink-1">Lists</a> <a href="core#images-captions" class="sublink-1">Image responsiveness &amp; captions</a>
<br/> <a href="grid#grid-title">Grid</a>
<a href="grid#basic-layout" class="sublink-1">Basic layout</a> <a href="grid#screen-specific-layout" class="sublink-1">Screen specific layouts</a>
<a href="grid#predefined-layout" class="sublink-1">Predefined layouts</a> <a href="grid#column-offset" class="sublink-1">Column offsets</a>
<a href="grid#column-reorder" class="sublink-1">Column reordering</a> <a href="grid#media-object" class="sublink-1">Media object pattern</a>
<br/> <a href="input_control#input-control-title">Input Control</a>
<a href="input_control#forms-input" class="sublink-1">Forms &amp; input</a> <a href="input_control#checkbox-radio" class="sublink-1">Checkboxes &amp; radio buttons</a> <a href="input_control#switches" class="sublink-1">Switches</a>
<a href="input_control#buttons" class="sublink-1">Buttons &amp; button groups</a> <a href="input_control#file-upload" class="sublink-1">File upload buttons</a>
<br/> <a href="navigation#navigation-title">Navigation</a>
<a href="navigation#header" class="sublink-1">Header</a> <a href="navigation#navigation-bar" class="sublink-1">Navigation bar</a> <a href="navigation#drawer" class="sublink-1">Drawer</a>
<a href="navigation#footer" class="sublink-1">Footer</a> <a href="navigation#sticky" class="sublink-1">Sticky headers &amp; footers</a>
<br/> <a href="table#table-title">Table</a>
<a href="table#syntax-responsiveness" class="sublink-1">Basic syntax &amp; responsiveness</a> <a href="table#scrollable-tables" class="sublink-1">Scrollable tables</a>
<a href="table#horizontal-tables" class="sublink-1">Horizontal tables</a> <a href="table#variants-matrices" class="sublink-1">Table variants &amp; matrices</a>
<br/> <a href="card#card-title">Card</a>
<a href="card#basic-syntax" class="sublink-1">Basic syntax</a> <a href="card#sections-media" class="sublink-1">Sections &amp; media</a>
<a href="card#sizing-fluidity" class="sublink-1">Card sizing &amp; fluidity</a> <a href="card#color-variants" class="sublink-1">Card color variants</a>
<br/> <a href="tab#tab-title">Tab</a>
<a href="tab#basic-syntax" class="sublink-1">Basic syntax</a> <a href="tab#stacked-tabs" class="sublink-1">Stacked tabs</a>
<br/> <a href="contextual#contextual-title">Contextual</a>
<a href="contextual#text-highlighting" class="sublink-1">Text highlighting</a> <a href="contextual#toasts" class="sublink-1">Toasts</a>
<a href="contextual#tooltips" class="sublink-1">Tooltips</a> <a href="contextual#modals" class="sublink-1">Modals</a>
<br/> <a href="progress#progress-title">Progress</a>
<a href="progress#basic-progress-bar" class="sublink-1">Basic progress bar</a> <a href="progress#progress-variants" class="sublink-1">Progress bar variants</a>
<a href="progress#donut-spinner" class="sublink-1">Donut spinner</a> <a href="progress#spinner-variants" class="sublink-1">Donut spinner variants</a>
<br/> <a href="utility#utility-title">Utility</a>
<a href="utility#visibility-helpers" class="sublink-1">Visibility helpers</a> <a href="utility#borders-shadows" class="sublink-1">Generic borders &amp; shadows</a>
<a href="utility#responsive-sizing" class="sublink-1">Responsive sizing &amp; spacing classes</a>
<a href="utility#responsive-visibility" class="sublink-1">Responsive visibility helpers</a> <a href="utility#breadcrumbs" class="sublink-1">Breadcrumbs</a>
<a href="utility#close-icon" class="sublink-1">Close icon</a>
<a href="flavors"><h4 style="margin-left: 0;">Flavors</h4></a>
<a href="templates"><h4 style="margin-left: 0;">Templates</h4></a>
<a href="customization"><h4 style="margin-left: 0;">Customization</h4></a>
<a href="quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<div class="col-sm-12 col-md-8 col-lg-10" id="col"><main>
<div class="row" style="padding-top: 40px;" id="card-title">
<div class="col-sm-12">
<h1>Card</h1>
<p style="text-align: justify;">The <strong>card</strong> module provides you with modern, responsive, general-purpose containers for your page's contents. They are very easy to use and their structure is really simple and versatile. Layouts will respond to smaller screens, realigning the cards in a manner that makes your page mobile-friendly.</p>
<p style="text-align: justify;"><small>All examples showcased refer to the mini-default flavor, some class names and styles might differ based on the flavor you're using.</small></p><br/>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<div class="card fluid">
<div class="section">
<h2>Quick overview</h2>
<p style="text-align: justify;">The main content of a website or web app needs to be easy to access and well organized no matter the nature of the content itself. The <strong>card</strong> module seeks to help deal with this problem, by utilizing the <a href="https://css-tricks.com/snippets/css/a-guide-to-flexbox/">Flexbox Layout</a> in order to provide general-purpose containers that help you present the information you want in the best possible way. Cards are designed in a very modern way, self-aligning and structuring their content based on your needs, while also being fully responsive to changes and compatible with the versatile <a href="grid"><strong>grid</strong></a> module to deliver the best experience on any device.</p><br>
</div>
<div class="section">
<h2>Quick start</h2>
<p style="text-align: justify;">To use the <strong>card</strong> module, simply include the link to the flavor you are using and start writing your HTML page as usual. Remember that the <strong>card</strong> module is heavily dependent on the <a href="grid"><strong>grid</strong></a> module, so you might want to first familiarize with its basic layout. One suggestion we will make is to add the following line inside your HTML page's <code>&lt;head&gt;</code> to utilize the viewport meta tag:</p>
<pre>&lt;<span class="fore-tertiary">meta</span> <span class="fore-secondary">name</span>=<span class="fore-primary">&quot;viewport&quot;</span> <span class="fore-secondary">content</span>=<span class="fore-primary">&quot;width=device-width, initial-scale=1&quot;</span>&gt;</pre><br>
</div>
</div>
</div>
</div>
<div class="row" id="basic-syntax">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"> <h2>Basic syntax</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal">
<div class="container">
<br>
<div class="row">
<div class="card"><div class="section"><h3>Card 1</h3><p>This is a basic card with some sample content.</p></div></div>
<div class="card"><div class="section"><h3>Card 2</h3><p>This is another card with some sample content.</p></div></div>
<div class="card"><div class="section"><h3>Card 3</h3><p>This is one more card with some sample content.</p></div></div>
</div>
<br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal">
<p style="text-align: justify;">To start using cards in your layout, you need to be somewhat familiar with the <a href="grid"><strong>grid</strong></a> module, so if you aren't, take a minute to read how its basic layout works. The basic syntax for cards is composed of three components, presented below in the order they should be added to the DOM tree:</p>
<ol style="text-align: justify;">
<li>At the outermost level of the card layout syntax is a <code>.row</code>, which serves as a wrapper for all the cards inside it.</li>
<li>Inside the <code>.row</code>, cards are defined as <code>&lt;div&gt;</code> elements of the <code>.card</code> class.</li>
<li>Finally, inside the <code>.card</code>s, you can define sections using the <code>.section</code> class to wrap your content.</li>
</ol>
<p style="text-align: justify;">Note that cards will respond to screen changes, realigning themselves as necessary to fit on the page.</p>
<h3>Sample code</h3>
<pre>&lt;div class=&quot;row&quot;&gt;
&lt;div class=&quot;card&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;h3&gt;Card Title&lt;/h3&gt;
&lt;p&gt;Card content...&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;card&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;h3&gt;Card Title&lt;/h3&gt;
&lt;p&gt;Card content...&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align: justify;">
<li>The <strong>card</strong> module is compatible with modern browsers, but might not display properly in older browsers.</li>
<li>If you want to further customize your <code>.section</code>s, check the section below.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6 col-lg-4">
<pre>&lt;div class=&quot;card&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;h3&gt;Card Title&lt;/h3&gt;
&lt;/div&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;p&gt;Card content...&lt;/p&gt;
&lt;p&gt;More card content...&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="do" style="text-align: justify;"><mark class="tertiary">Do:</mark>&nbsp;You can add as many <code>.section</code>s as you like to a card.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal col-lg-4 col-lg-last">
<pre>&lt;div class=&quot;card&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;h3&gt;Card Title&lt;/h3&gt;
&lt;/div&gt;
&lt;p&gt;Content not in a section!&lt;/p&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align: justify;"><mark class="secondary">Don't:</mark>&nbsp;Avoid using cards with content inside them that is not wrapped in sections. Try to use a single <code>.section</code> to wrap the content inside these to avoid unexpected behavior.</p>
</div>
<div class="col-sm-12 col-md-6 col-lg-4">
<pre>&lt;div class=&quot;card&quot;&gt;
&lt;h3 class=&quot;section&quot;&gt;Card Title&lt;/h3&gt;
&lt;p class=&quot;section&quot;&gt;Card content...&lt;/p&gt;
&lt;/div&gt;</pre>
<p class="do" style="text-align: justify;"><mark class="tertiary">Do:</mark>&nbsp;You can use the <code>.section</code> class for things other than <code>&lt;div&gt;</code> elements (e.g. <code>&lt;h1&gt;</code>-<code>&lt;h6&gt;</code>, <code>&lt;p&gt;</code>, <code>&lt;button&gt;</code>).</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal col-lg-4 col-lg-last">
<pre>&lt;div class=&quot;row&quot;&gt;
&lt;div class=&quot;card&quot;&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;row&quot;&gt;
&lt;div class=&quot;card&quot;&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align: justify;"><mark class="secondary">Don't:</mark>&nbsp;If you want to place multiple cards side by side, add them all inside the same <code>.row</code>. Placing cards inside different rows or not inside rows at all can result in unexpected behavior. </p>
</div>
<div class="col-sm-12 col-md-6 col-lg-4">
<pre>&lt;div class=&quot;card&quot;&gt;
&lt;div class=&quot;section row&quot;&gt;
&lt;div class=&quot;card&quot;&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
<span class="fore-tertiary">&lt;!-- or --&gt;</span>
&lt;div class=&quot;card&quot;&gt;
&lt;div class=&quot;row&quot;&gt;
&lt;div class=&quot;card&quot;&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="do" style="text-align: justify;"><mark class="tertiary">Do:</mark>&nbsp;You can place <code>.row</code> elements inside <code>.card</code> elements, if you want. you should normally also make those rows into card <code>.section</code>s, but for this specific case you might want to make an exception sometimes.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal col-lg-4 col-lg-last">
<pre>&lt;div class=&quot;card row&quot;&gt;
&lt;/div&gt;
<span class="fore-secondary">&lt;!-- or --&gt;</span>
&lt;div class=&quot;card col-sm&quot;&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align: justify;"><mark class="secondary">Don't:</mark>&nbsp;You should not have elements that are both cards and rows or columns at the same time.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="sections-media">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Sections &amp; media</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal">
<div class="container"><br>
<div class="row">
<div class="card"><div class="section"><h3>Card with image</h3></div><img class="section media" src="https://placehold.it/800x600" alt="image"><div class="section"><p>Content</p></div></div>
<div class="card"><iframe class="section media" width="1280" height="720" src="https://www.youtube.com/embed/ScMzIvxBSi4"></iframe><div class="section"><h3>Card with video</h3></div></div>
<div class="card"><div class="section"><h3>Normal section</h3></div><div class="section double-padded"><h3>Double-padded section</h3></div></div>
<div class="card"><div class="section"><h3>Normal section</h3></div><div class="section dark"><h3>Dark section</h3></div><div class="section darker"><h3>Darker section</h3></div></div>
</div><br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal">
<p style="text-align: justify;">You can do a lot more with card sections apart from filling them with textual content. First off, you can add media sections to your cards, applying the styles of <code>.section</code> and <code>.media</code> to an <code>&lt;img&gt;</code> element or a video element of your choice (e.g. using a <code>&lt;iframe&gt;</code> element in the same manner). If you want a section to have more space around it, use the <code>.double-padded</code> class. There are also two section color variations: <code>.dark</code> and <code>.darker</code>.</p>
<h3>Sample code</h3>
<pre>&lt;div class=&quot;card&quot;&gt;
&lt;img src=&quot;...&quot; class=&quot;section media&quot;&gt;
&lt;div class=&quot;section double-padded&quot;&gt;&lt;p&gt;Content&lt;/p&gt;&lt;/div&gt;
&lt;div class=&quot;section dark&quot;&gt;&lt;p&gt;Content&lt;/p&gt;&lt;/div&gt;
&lt;div class=&quot;section darker&quot;&gt;&lt;p&gt;Content&lt;/p&gt;&lt;/div&gt;
&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align: justify;">
<li>The <code>.media</code> class might not be well supported in older browsers, especially legacy versions of Internet Explorer.</li>
<li>Due to the <code>.media</code> class using <a href="http://caniuse.com/#feat=object-fit"><code>object-fit</code></a>, you might want to use a polyfill for better browser support, especially if you are targeting Microsoft browsers. We recommend <a href="https://github.com/bfred-it/object-fit-images">this one</a> for images and <a href="https://github.com/jonathantneal/fitie">this one</a> for videos.</li>
<li>Depending on the source website, some embedded videos might not display properly inside a <code>.media</code> section.</li>
<li>The <code>.media</code> class has a preset size of <code>height: 200px</code>. If you want to customize this, you should check the <a href="customization">customization page</a> for instructions.</li>
</ul>
</div>
</div>
</div>
</div>
<div class="row" id="sizing-fluidity">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Card sizing &amp; fluidity</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal">
<div class="container"><br>
<div class="row">
<div class="card small"><div class="section"><h3>Small Card</h3><p>Small cards are <code>240px</code> wide.</p></div></div>
<div class="card large"><div class="section"><h3>Large Card</h3><p>Large cards are <code>480px</code> wide.</p></div></div>
<div class="col-sm-12 col-md-12 col-lg">
<div class="card fluid" style="margin: 2px 10px 20px;"><div class="section"><h3>Fluid Card</h3><p>Fluid cards scale their width based on their container. Always wrap them in a column.</p></div></div>
</div>
</div>
<br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal">
<p style="text-align: justify;">Apart from the normal-sized cards (<code>320px</code> wide), there are also two different fixed-width card styles, which can be applied using the <code>.small</code> and <code>.large</code> classes respectively. Fluid cards are available via the <code>.fluid</code> class, but they require one extra step in the card structure, between the <code>.row</code> and <code>.card</code> step, which is to insert either a <code>.col-<span class="fore-primary">SCR_SZ</span></code>, replacing <code><span class="fore-primary">SCR_SZ</span></code> with one of the available screen size names (<code><span class="fore-tertiary">sm</span></code> for smaller screens, <code><span class="fore-tertiary">md</span></code> for medium-sized screens or <code><span class="fore-tertiary">lg</span></code> for larger screens) or a <code>.col-<span class="fore-primary">SCR_SZ</span>-<span class="fore-secondary">COL_WD</span></code> to specify columns with fixed width, replacing <code><span class="fore-primary">SCR_SZ</span></code> with one of the available screen size names and <code><span class="fore-secondary">COL_WD</span></code> with a number from <code>1</code> to <code>12</code> specifying the width of the column.</p>
<h3>Sample code</h3>
<pre>&lt;div class=&quot;card small&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;p&gt;Content&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;card large&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;p&gt;Content&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;col-sm-12&quot;&gt;
&lt;div class=&quot;card fluid&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;p&gt;Content&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align: justify;">
<li><code>.fluid</code> cards might not display properly in older browsers, especially legacy versions of Internet Explorer.</li>
<li>Due to the fact that <code>.fluid</code> cards stretch to fill their parent container, they might not fully respect their margins, like the rest of the cards. However, this should not cause any noticable problems with layout, except maybe the odd pixel here and there.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;div class=&quot;card&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;p&gt;Content&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;card fluid&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;p&gt;Content&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align: justify;"><mark class="secondary">Don't:</mark>&nbsp;Avoid mixing fixed-width cards with <code>.fluid</code> cards. Mixing the two could result in some unexpected behaviors. You can, however, mix fixed-width cards with fluid columns, which can contain <code>.fluid</code> cards inside them, effectively achieving the desired effect.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;div class=&quot;row&quot;&gt;
&lt;div class=&quot;card fluid&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;p&gt;Content&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align: justify;"><mark class="secondary">Don't:</mark>&nbsp;Avoid using <code>.fluid</code> cards without wrapping them in columns. Try to use a single <code>.col-sm</code> to wrap the card inside it, otherwise there might be unexpected behavior.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="color-variants">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Card color variants</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal">
<div class="container"><br>
<div class="row">
<div class="card warning"><div class="section"><h3>Warning Card</h3><p>Warning cards are used to display important information to users.</p></div></div>
<div class="card error"><div class="section"><h3>Error Card</h3><p>Error cards are used to display error messages to users.</p></div></div>
</div>
<br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal">
<p style="text-align: justify;">Cards can also be used to display important information or error messages to users. You can use the <code>.warning</code> class to display a yellow warning card or, if you need to display an error message to your users, you can use the <code>.error</code> class to display a red error card. </p>
<h3>Sample code</h3>
<pre>&lt;div class=&quot;card warning&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;p&gt;Warning&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;card error&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;p&gt;Error&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align: justify;">
<li>If you want more color variants for your cards, check out the <a href="customization">customization</a> page.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12"><pre>&lt;div class=&quot;card warning errors&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;p&gt;Bad card&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align: justify;"><mark class="secondary">Don't:</mark>&nbsp;Avoid combining two card color variants, as this might cause some unexpected behavior.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" style="padding-bottom: 20px; padding-top:20px;">
<div class="col-sm-12">
<p style="text-align: justify;">If you want to learn more about <strong>mini.css</strong>'s modules, go back to the <a href="modules">modules page</a> and choose another module to see its documentation.</p>
</div>
</div>
</main></div></div></div>
<footer style="text-align: justify;"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<title>mini.css - Card</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, module, card ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-centered { text-align: center; } .box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;} .box-colored.red { background: #e53935; }
.box-centered > .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto;} [class^='col-'] .card.fluid { margin: 2px 0 20px; }
[class^='fore-'] { font-family: monospace, monospace;} .fore-primary { color: #0d47a1;} .fore-secondary { color: #b71c1c;} .fore-tertiary { color: #1b5e20;}
.col-sm-12.col-sm-last.col-md-12.col-md-normal {box-sizing: border-box;border-bottom: 1px solid #c9c9c9;}
@media (max-width: 767px){.col-sm-12.col-sm-last.col-md-12.col-md-normal {border: 0;border-top: 1px solid #c9c9c9;}}
.box-colored.green { background: #689f38; } .do {border-top: 15px solid #689f38;padding-top: 10px;} .dont {border-top: 15px solid #e53935;padding-top: 10px;}
.box-colored {color: #f5f5f5;} @media (max-width: 767px){.container#co {padding: 0.25rem !important;}.col-sm-12.col-md-8.col-lg-10#col{padding: 0 !important;}}
@media screen and (min-width: 768px) { .drawer { margin-top: 4px;}}
</style>
</head>
<body>
<header class="sticky">
<a href="index" class="logo"><span id="header-logo">m</span></a>
<label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="index" class="button hidden-sm">Introduction</a> <a href="modules" class="button hidden-sm">Modules</a>
<a href="flavors" class="button hidden-sm">Flavors</a> <a href="templates" class="button hidden-sm">Templates</a>
<a href="customization" class="button hidden-sm">Customization</a> <a href="quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<div class="container" style="padding-left: 0.25rem;">
<div class="row"> <input type="checkbox" id="navigation-toggle"> <nav class="drawer col-md-4 col-lg-2">
<label class="close" for="navigation-toggle"></label>
<a href="index"><h4 style="margin-left: 0;">Introduction</h4></a>
<h4 style="margin-left: 0;">Modules</h4> <a href="core#core-title">Core</a>
<a href="core#typography" class="sublink-1">Typography</a> <a href="core#headings" class="sublink-1">Headings</a>
<a href="core#common-textual-elements" class="sublink-1">Common textual elements</a>
<a href="core#lists" class="sublink-1">Lists</a> <a href="core#images-captions" class="sublink-1">Image responsiveness &amp; captions</a>
<br/> <a href="grid#grid-title">Grid</a>
<a href="grid#basic-layout" class="sublink-1">Basic layout</a> <a href="grid#screen-specific-layout" class="sublink-1">Screen specific layouts</a>
<a href="grid#predefined-layout" class="sublink-1">Predefined layouts</a> <a href="grid#column-offset" class="sublink-1">Column offsets</a>
<a href="grid#column-reorder" class="sublink-1">Column reordering</a> <a href="grid#media-object" class="sublink-1">Media object pattern</a>
<br/> <a href="input_control#input-control-title">Input Control</a>
<a href="input_control#forms-input" class="sublink-1">Forms &amp; input</a> <a href="input_control#checkbox-radio" class="sublink-1">Checkboxes &amp; radio buttons</a> <a href="input_control#switches" class="sublink-1">Switches</a>
<a href="input_control#buttons" class="sublink-1">Buttons &amp; button groups</a> <a href="input_control#file-upload" class="sublink-1">File upload buttons</a>
<br/> <a href="navigation#navigation-title">Navigation</a>
<a href="navigation#header" class="sublink-1">Header</a> <a href="navigation#navigation-bar" class="sublink-1">Navigation bar</a> <a href="navigation#drawer" class="sublink-1">Drawer</a>
<a href="navigation#footer" class="sublink-1">Footer</a> <a href="navigation#sticky" class="sublink-1">Sticky headers &amp; footers</a>
<br/> <a href="table#table-title">Table</a>
<a href="table#syntax-responsiveness" class="sublink-1">Basic syntax &amp; responsiveness</a> <a href="table#scrollable-tables" class="sublink-1">Scrollable tables</a>
<a href="table#horizontal-tables" class="sublink-1">Horizontal tables</a> <a href="table#variants-matrices" class="sublink-1">Table variants &amp; matrices</a>
<br/> <a href="card#card-title">Card</a>
<a href="card#basic-syntax" class="sublink-1">Basic syntax</a> <a href="card#sections-media" class="sublink-1">Sections &amp; media</a>
<a href="card#sizing-fluidity" class="sublink-1">Card sizing &amp; fluidity</a> <a href="card#color-variants" class="sublink-1">Card color variants</a>
<br/> <a href="tab#tab-title">Tab</a>
<a href="tab#basic-syntax" class="sublink-1">Basic syntax</a> <a href="tab#stacked-tabs" class="sublink-1">Stacked tabs</a>
<br/> <a href="contextual#contextual-title">Contextual</a>
<a href="contextual#text-highlighting" class="sublink-1">Text highlighting</a> <a href="contextual#toasts" class="sublink-1">Toasts</a>
<a href="contextual#tooltips" class="sublink-1">Tooltips</a> <a href="contextual#modals" class="sublink-1">Modals</a>
<br/> <a href="progress#progress-title">Progress</a>
<a href="progress#basic-progress-bar" class="sublink-1">Basic progress bar</a> <a href="progress#progress-variants" class="sublink-1">Progress bar variants</a>
<a href="progress#donut-spinner" class="sublink-1">Donut spinner</a> <a href="progress#spinner-variants" class="sublink-1">Donut spinner variants</a>
<br/> <a href="utility#utility-title">Utility</a>
<a href="utility#visibility-helpers" class="sublink-1">Visibility helpers</a> <a href="utility#borders-shadows" class="sublink-1">Generic borders &amp; shadows</a>
<a href="utility#responsive-sizing" class="sublink-1">Responsive sizing &amp; spacing classes</a>
<a href="utility#responsive-visibility" class="sublink-1">Responsive visibility helpers</a> <a href="utility#breadcrumbs" class="sublink-1">Breadcrumbs</a>
<a href="utility#close-icon" class="sublink-1">Close icon</a>
<a href="flavors"><h4 style="margin-left: 0;">Flavors</h4></a>
<a href="templates"><h4 style="margin-left: 0;">Templates</h4></a>
<a href="customization"><h4 style="margin-left: 0;">Customization</h4></a>
<a href="quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<div class="col-sm-12 col-md-8 col-lg-10" id="col"><main>
<div class="row" style="padding-top: 40px;" id="card-title">
<div class="col-sm-12">
<h1>Card</h1>
<p style="text-align: justify;">The <strong>card</strong> module provides you with modern, responsive, general-purpose containers for your page's contents. They are very easy to use and their structure is really simple and versatile. Layouts will respond to smaller screens, realigning the cards in a manner that makes your page mobile-friendly.</p>
<p style="text-align: justify;"><small>All examples showcased refer to the mini-default flavor, some class names and styles might differ based on the flavor you're using.</small></p><br/>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<div class="card fluid">
<div class="section">
<h2>Quick overview</h2>
<p style="text-align: justify;">The main content of a website or web app needs to be easy to access and well organized no matter the nature of the content itself. The <strong>card</strong> module seeks to help deal with this problem, by utilizing the <a href="https://css-tricks.com/snippets/css/a-guide-to-flexbox/">Flexbox Layout</a> in order to provide general-purpose containers that help you present the information you want in the best possible way. Cards are designed in a very modern way, self-aligning and structuring their content based on your needs, while also being fully responsive to changes and compatible with the versatile <a href="grid"><strong>grid</strong></a> module to deliver the best experience on any device.</p><br>
</div>
<div class="section">
<h2>Quick start</h2>
<p style="text-align: justify;">To use the <strong>card</strong> module, simply include the link to the flavor you are using and start writing your HTML page as usual. Remember that the <strong>card</strong> module is heavily dependent on the <a href="grid"><strong>grid</strong></a> module, so you might want to first familiarize with its basic layout. One suggestion we will make is to add the following line inside your HTML page's <code>&lt;head&gt;</code> to utilize the viewport meta tag:</p>
<pre>&lt;<span class="fore-tertiary">meta</span> <span class="fore-secondary">name</span>=<span class="fore-primary">&quot;viewport&quot;</span> <span class="fore-secondary">content</span>=<span class="fore-primary">&quot;width=device-width, initial-scale=1&quot;</span>&gt;</pre><br>
</div>
</div>
</div>
</div>
<div class="row" id="basic-syntax">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"> <h2>Basic syntax</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal">
<div class="container">
<br>
<div class="row">
<div class="card"><div class="section"><h3>Card 1</h3><p>This is a basic card with some sample content.</p></div></div>
<div class="card"><div class="section"><h3>Card 2</h3><p>This is another card with some sample content.</p></div></div>
<div class="card"><div class="section"><h3>Card 3</h3><p>This is one more card with some sample content.</p></div></div>
</div>
<br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal">
<p style="text-align: justify;">To start using cards in your layout, you need to be somewhat familiar with the <a href="grid"><strong>grid</strong></a> module, so if you aren't, take a minute to read how its basic layout works. The basic syntax for cards is composed of three components, presented below in the order they should be added to the DOM tree:</p>
<ol style="text-align: justify;">
<li>At the outermost level of the card layout syntax is a <code>.row</code>, which serves as a wrapper for all the cards inside it.</li>
<li>Inside the <code>.row</code>, cards are defined as <code>&lt;div&gt;</code> elements of the <code>.card</code> class.</li>
<li>Finally, inside the <code>.card</code>s, you can define sections using the <code>.section</code> class to wrap your content.</li>
</ol>
<p style="text-align: justify;">Note that cards will respond to screen changes, realigning themselves as necessary to fit on the page.</p>
<h3>Sample code</h3>
<pre>&lt;div class=&quot;row&quot;&gt;
&lt;div class=&quot;card&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;h3&gt;Card Title&lt;/h3&gt;
&lt;p&gt;Card content...&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;card&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;h3&gt;Card Title&lt;/h3&gt;
&lt;p&gt;Card content...&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align: justify;">
<li>The <strong>card</strong> module is compatible with modern browsers, but might not display properly in older browsers.</li>
<li>If you want to further customize your <code>.section</code>s, check the section below.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6 col-lg-4">
<pre>&lt;div class=&quot;card&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;h3&gt;Card Title&lt;/h3&gt;
&lt;/div&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;p&gt;Card content...&lt;/p&gt;
&lt;p&gt;More card content...&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="do" style="text-align: justify;"><mark class="tertiary">Do:</mark>&nbsp;You can add as many <code>.section</code>s as you like to a card.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal col-lg-4 col-lg-last">
<pre>&lt;div class=&quot;card&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;h3&gt;Card Title&lt;/h3&gt;
&lt;/div&gt;
&lt;p&gt;Content not in a section!&lt;/p&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align: justify;"><mark class="secondary">Don't:</mark>&nbsp;Avoid using cards with content inside them that is not wrapped in sections. Try to use a single <code>.section</code> to wrap the content inside these to avoid unexpected behavior.</p>
</div>
<div class="col-sm-12 col-md-6 col-lg-4">
<pre>&lt;div class=&quot;card&quot;&gt;
&lt;h3 class=&quot;section&quot;&gt;Card Title&lt;/h3&gt;
&lt;p class=&quot;section&quot;&gt;Card content...&lt;/p&gt;
&lt;/div&gt;</pre>
<p class="do" style="text-align: justify;"><mark class="tertiary">Do:</mark>&nbsp;You can use the <code>.section</code> class for things other than <code>&lt;div&gt;</code> elements (e.g. <code>&lt;h1&gt;</code>-<code>&lt;h6&gt;</code>, <code>&lt;p&gt;</code>, <code>&lt;button&gt;</code>).</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal col-lg-4 col-lg-last">
<pre>&lt;div class=&quot;row&quot;&gt;
&lt;div class=&quot;card&quot;&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;row&quot;&gt;
&lt;div class=&quot;card&quot;&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align: justify;"><mark class="secondary">Don't:</mark>&nbsp;If you want to place multiple cards side by side, add them all inside the same <code>.row</code>. Placing cards inside different rows or not inside rows at all can result in unexpected behavior. </p>
</div>
<div class="col-sm-12 col-md-6 col-lg-4">
<pre>&lt;div class=&quot;card&quot;&gt;
&lt;div class=&quot;section row&quot;&gt;
&lt;div class=&quot;card&quot;&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
<span class="fore-tertiary">&lt;!-- or --&gt;</span>
&lt;div class=&quot;card&quot;&gt;
&lt;div class=&quot;row&quot;&gt;
&lt;div class=&quot;card&quot;&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="do" style="text-align: justify;"><mark class="tertiary">Do:</mark>&nbsp;You can place <code>.row</code> elements inside <code>.card</code> elements, if you want. you should normally also make those rows into card <code>.section</code>s, but for this specific case you might want to make an exception sometimes.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal col-lg-4 col-lg-last">
<pre>&lt;div class=&quot;card row&quot;&gt;
&lt;/div&gt;
<span class="fore-secondary">&lt;!-- or --&gt;</span>
&lt;div class=&quot;card col-sm&quot;&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align: justify;"><mark class="secondary">Don't:</mark>&nbsp;You should not have elements that are both cards and rows or columns at the same time.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="sections-media">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Sections &amp; media</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal">
<div class="container"><br>
<div class="row">
<div class="card"><div class="section"><h3>Card with image</h3></div><img class="section media" src="https://placehold.it/800x600" alt="image"><div class="section"><p>Content</p></div></div>
<div class="card"><iframe class="section media" width="1280" height="720" src="https://www.youtube.com/embed/ScMzIvxBSi4"></iframe><div class="section"><h3>Card with video</h3></div></div>
<div class="card"><div class="section"><h3>Normal section</h3></div><div class="section double-padded"><h3>Double-padded section</h3></div></div>
<div class="card"><div class="section"><h3>Normal section</h3></div><div class="section dark"><h3>Dark section</h3></div><div class="section darker"><h3>Darker section</h3></div></div>
</div><br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal">
<p style="text-align: justify;">You can do a lot more with card sections apart from filling them with textual content. First off, you can add media sections to your cards, applying the styles of <code>.section</code> and <code>.media</code> to an <code>&lt;img&gt;</code> element or a video element of your choice (e.g. using a <code>&lt;iframe&gt;</code> element in the same manner). If you want a section to have more space around it, use the <code>.double-padded</code> class. There are also two section color variations: <code>.dark</code> and <code>.darker</code>.</p>
<h3>Sample code</h3>
<pre>&lt;div class=&quot;card&quot;&gt;
&lt;img src=&quot;...&quot; class=&quot;section media&quot;&gt;
&lt;div class=&quot;section double-padded&quot;&gt;&lt;p&gt;Content&lt;/p&gt;&lt;/div&gt;
&lt;div class=&quot;section dark&quot;&gt;&lt;p&gt;Content&lt;/p&gt;&lt;/div&gt;
&lt;div class=&quot;section darker&quot;&gt;&lt;p&gt;Content&lt;/p&gt;&lt;/div&gt;
&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align: justify;">
<li>The <code>.media</code> class might not be well supported in older browsers, especially legacy versions of Internet Explorer.</li>
<li>Due to the <code>.media</code> class using <a href="http://caniuse.com/#feat=object-fit"><code>object-fit</code></a>, you might want to use a polyfill for better browser support, especially if you are targeting Microsoft browsers. We recommend <a href="https://github.com/bfred-it/object-fit-images">this one</a> for images and <a href="https://github.com/jonathantneal/fitie">this one</a> for videos.</li>
<li>Depending on the source website, some embedded videos might not display properly inside a <code>.media</code> section.</li>
<li>The <code>.media</code> class has a preset size of <code>height: 200px</code>. If you want to customize this, you should check the <a href="customization">customization page</a> for instructions.</li>
</ul>
</div>
</div>
</div>
</div>
<div class="row" id="sizing-fluidity">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Card sizing &amp; fluidity</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal">
<div class="container"><br>
<div class="row">
<div class="card small"><div class="section"><h3>Small Card</h3><p>Small cards are <code>240px</code> wide.</p></div></div>
<div class="card large"><div class="section"><h3>Large Card</h3><p>Large cards are <code>480px</code> wide.</p></div></div>
<div class="col-sm-12 col-md-12 col-lg">
<div class="card fluid" style="margin: 2px 10px 20px;"><div class="section"><h3>Fluid Card</h3><p>Fluid cards scale their width based on their container. Always wrap them in a column.</p></div></div>
</div>
</div>
<br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal">
<p style="text-align: justify;">Apart from the normal-sized cards (<code>320px</code> wide), there are also two different fixed-width card styles, which can be applied using the <code>.small</code> and <code>.large</code> classes respectively. Fluid cards are available via the <code>.fluid</code> class, but they require one extra step in the card structure, between the <code>.row</code> and <code>.card</code> step, which is to insert either a <code>.col-<span class="fore-primary">SCR_SZ</span></code>, replacing <code><span class="fore-primary">SCR_SZ</span></code> with one of the available screen size names (<code><span class="fore-tertiary">sm</span></code> for smaller screens, <code><span class="fore-tertiary">md</span></code> for medium-sized screens or <code><span class="fore-tertiary">lg</span></code> for larger screens) or a <code>.col-<span class="fore-primary">SCR_SZ</span>-<span class="fore-secondary">COL_WD</span></code> to specify columns with fixed width, replacing <code><span class="fore-primary">SCR_SZ</span></code> with one of the available screen size names and <code><span class="fore-secondary">COL_WD</span></code> with a number from <code>1</code> to <code>12</code> specifying the width of the column.</p>
<h3>Sample code</h3>
<pre>&lt;div class=&quot;card small&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;p&gt;Content&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;card large&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;p&gt;Content&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;col-sm-12&quot;&gt;
&lt;div class=&quot;card fluid&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;p&gt;Content&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align: justify;">
<li><code>.fluid</code> cards might not display properly in older browsers, especially legacy versions of Internet Explorer.</li>
<li>Due to the fact that <code>.fluid</code> cards stretch to fill their parent container, they might not fully respect their margins, like the rest of the cards. However, this should not cause any noticable problems with layout, except maybe the odd pixel here and there.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;div class=&quot;card&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;p&gt;Content&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;card fluid&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;p&gt;Content&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align: justify;"><mark class="secondary">Don't:</mark>&nbsp;Avoid mixing fixed-width cards with <code>.fluid</code> cards. Mixing the two could result in some unexpected behaviors. You can, however, mix fixed-width cards with fluid columns, which can contain <code>.fluid</code> cards inside them, effectively achieving the desired effect.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;div class=&quot;row&quot;&gt;
&lt;div class=&quot;card fluid&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;p&gt;Content&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align: justify;"><mark class="secondary">Don't:</mark>&nbsp;Avoid using <code>.fluid</code> cards without wrapping them in columns. Try to use a single <code>.col-sm</code> to wrap the card inside it, otherwise there might be unexpected behavior.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="color-variants">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Card color variants</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal">
<div class="container"><br>
<div class="row">
<div class="card warning"><div class="section"><h3>Warning Card</h3><p>Warning cards are used to display important information to users.</p></div></div>
<div class="card error"><div class="section"><h3>Error Card</h3><p>Error cards are used to display error messages to users.</p></div></div>
</div>
<br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal">
<p style="text-align: justify;">Cards can also be used to display important information or error messages to users. You can use the <code>.warning</code> class to display a yellow warning card or, if you need to display an error message to your users, you can use the <code>.error</code> class to display a red error card. </p>
<h3>Sample code</h3>
<pre>&lt;div class=&quot;card warning&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;p&gt;Warning&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;card error&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;p&gt;Error&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align: justify;">
<li>If you want more color variants for your cards, check out the <a href="customization">customization</a> page.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12"><pre>&lt;div class=&quot;card warning errors&quot;&gt;
&lt;div class=&quot;section&quot;&gt;
&lt;p&gt;Bad card&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align: justify;"><mark class="secondary">Don't:</mark>&nbsp;Avoid combining two card color variants, as this might cause some unexpected behavior.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" style="padding-bottom: 20px; padding-top:20px;">
<div class="col-sm-12">
<p style="text-align: justify;">If you want to learn more about <strong>mini.css</strong>'s modules, go back to the <a href="modules">modules page</a> and choose another module to see its documentation.</p>
</div>
</div>
</main></div></div></div>
<footer style="text-align: justify;"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>

View file

@ -1,309 +1,309 @@
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<title>mini.css - Contextual</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, module, contextual ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-centered { text-align: center; } .box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;} .box-colored.red { background: #e53935; }
.box-centered > .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto; } [class^='col-'] .card.fluid { margin: 2px 0 20px; }
[class^='fore-'] { font-family: monospace, monospace;} .fore-primary { color: #0d47a1;} .fore-secondary { color: #b71c1c;} .fore-tertiary { color: #1b5e20;}
.col-sm-12.col-sm-last.col-md-4.col-md-normal { box-sizing: border-box; border-right: 1px solid #c9c9c9; }
@media (max-width: 767px){ .col-sm-12.col-sm-last.col-md-4.col-md-normal { border: 0; border-top: 1px solid #c9c9c9;}}
.col-sm-12.col-sm-last.col-md-12.col-md-normal { box-sizing: border-box; border-bottom: 1px solid #c9c9c9; }
@media (max-width: 767px){ .col-sm-12.col-sm-last.col-md-12.col-md-normal { border: 0; border-top: 1px solid #c9c9c9;}}
.box-colored.green { background: #689f38; } .do {border-top: 15px solid #689f38;padding-top: 10px;} .dont {border-top: 15px solid #e53935;padding-top: 10px;}
.box-colored {color: #f5f5f5;} @media (max-width: 767px){.container {padding: 0.25rem !important;}.col-sm-12.col-md-8.col-lg-10{padding: 0 !important;}}
.toast.demo { position: relative; top: 2rem; left: calc(50% - 6rem); z-index: 1;} .toast.demo.small { top: 4.5rem; left: calc(50% - 6.75rem);} .toast.demo.large { top: 7.5rem; left: calc(50% - 8rem);}
@media screen and (min-width: 768px) { .drawer { margin-top: 4px;}}
</style>
</head>
<body>
<header class="sticky">
<a href="index" class="logo"><span id="header-logo">m</span></a>
<label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="index" class="button hidden-sm">Introduction</a> <a href="modules" class="button hidden-sm">Modules</a>
<a href="flavors" class="button hidden-sm">Flavors</a> <a href="templates" class="button hidden-sm">Templates</a>
<a href="customization" class="button hidden-sm">Customization</a> <a href="quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<div class="container" style="padding-left: 0.25rem;">
<div class="row"> <input type="checkbox" id="navigation-toggle"> <nav class="drawer col-md-4 col-lg-2">
<label class="close" for="navigation-toggle"></label>
<a href="index"><h4 style="margin-left: 0;">Introduction</h4></a>
<h4 style="margin-left: 0;">Modules</h4> <a href="core#core-title">Core</a>
<a href="core#typography" class="sublink-1">Typography</a> <a href="core#headings" class="sublink-1">Headings</a>
<a href="core#common-textual-elements" class="sublink-1">Common textual elements</a>
<a href="core#lists" class="sublink-1">Lists</a> <a href="core#images-captions" class="sublink-1">Image responsiveness &amp; captions</a>
<br/> <a href="grid#grid-title">Grid</a>
<a href="grid#basic-layout" class="sublink-1">Basic layout</a> <a href="grid#screen-specific-layout" class="sublink-1">Screen specific layouts</a>
<a href="grid#predefined-layout" class="sublink-1">Predefined layouts</a> <a href="grid#column-offset" class="sublink-1">Column offsets</a>
<a href="grid#column-reorder" class="sublink-1">Column reordering</a> <a href="grid#media-object" class="sublink-1">Media object pattern</a>
<br/> <a href="input_control#input-control-title">Input Control</a>
<a href="input_control#forms-input" class="sublink-1">Forms &amp; input</a> <a href="input_control#checkbox-radio" class="sublink-1">Checkboxes &amp; radio buttons</a> <a href="input_control#switches" class="sublink-1">Switches</a>
<a href="input_control#buttons" class="sublink-1">Buttons &amp; button groups</a> <a href="input_control#file-upload" class="sublink-1">File upload buttons</a>
<br/> <a href="navigation#navigation-title">Navigation</a>
<a href="navigation#header" class="sublink-1">Header</a> <a href="navigation#navigation-bar" class="sublink-1">Navigation bar</a> <a href="navigation#drawer" class="sublink-1">Drawer</a>
<a href="navigation#footer" class="sublink-1">Footer</a> <a href="navigation#sticky" class="sublink-1">Sticky headers &amp; footers</a>
<br/> <a href="table#table-title">Table</a>
<a href="table#syntax-responsiveness" class="sublink-1">Basic syntax &amp; responsiveness</a> <a href="table#scrollable-tables" class="sublink-1">Scrollable tables</a>
<a href="table#horizontal-tables" class="sublink-1">Horizontal tables</a> <a href="table#variants-matrices" class="sublink-1">Table variants &amp; matrices</a>
<br/> <a href="card#card-title">Card</a>
<a href="card#basic-syntax" class="sublink-1">Basic syntax</a> <a href="card#sections-media" class="sublink-1">Sections &amp; media</a>
<a href="card#sizing-fluidity" class="sublink-1">Card sizing &amp; fluidity</a> <a href="card#color-variants" class="sublink-1">Card color variants</a>
<br/> <a href="tab#tab-title">Tab</a>
<a href="tab#basic-syntax" class="sublink-1">Basic syntax</a> <a href="tab#stacked-tabs" class="sublink-1">Stacked tabs</a>
<br/> <a href="contextual#contextual-title">Contextual</a>
<a href="contextual#text-highlighting" class="sublink-1">Text highlighting</a> <a href="contextual#toasts" class="sublink-1">Toasts</a>
<a href="contextual#tooltips" class="sublink-1">Tooltips</a> <a href="contextual#modals" class="sublink-1">Modals</a>
<br/> <a href="progress#progress-title">Progress</a>
<a href="progress#basic-progress-bar" class="sublink-1">Basic progress bar</a> <a href="progress#progress-variants" class="sublink-1">Progress bar variants</a>
<a href="progress#donut-spinner" class="sublink-1">Donut spinner</a> <a href="progress#spinner-variants" class="sublink-1">Donut spinner variants</a>
<br/> <a href="utility#utility-title">Utility</a>
<a href="utility#visibility-helpers" class="sublink-1">Visibility helpers</a> <a href="utility#borders-shadows" class="sublink-1">Generic borders &amp; shadows</a>
<a href="utility#responsive-sizing" class="sublink-1">Responsive sizing &amp; spacing classes</a>
<a href="utility#responsive-visibility" class="sublink-1">Responsive visibility helpers</a> <a href="utility#breadcrumbs" class="sublink-1">Breadcrumbs</a>
<a href="utility#close-icon" class="sublink-1">Close icon</a>
<a href="flavors"><h4 style="margin-left: 0;">Flavors</h4></a>
<a href="templates"><h4 style="margin-left: 0;">Templates</h4></a>
<a href="customization"><h4 style="margin-left: 0;">Customization</h4></a>
<a href="quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<div class="col-sm-12 col-md-8 col-lg-10"><main>
<div class="row" style="padding-top: 40px;" id="contextual-title">
<div class="col-sm-12">
<h1>Contextual</h1>
<p style="text-align:justify">The <strong>contextual</strong> module provides you with simple tags, marks and highlights for your pages, allowing you to easily emphasize parts of your text. Contextual toasts, tooltips and modals are also provided, aiming to help deliver important information to users. HTML5 elements and simple rules are used in order to make important messages and pieces of content stand out easily.</p>
<p style="text-align:justify"><small>All examples showcased refer to the mini-default flavor, some class names and styles might differ based on the flavor you're using.</small></p><br/>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<div class="card fluid">
<div class="section">
<h2>Quick overview</h2>
<p style="text-align:justify">Almost every website present on the web has some sort of content that needs highlighting in one way or another. The <strong>contextual</strong> module provides you with simple semantic text highlighting that utilises the <code>&lt;mark&gt;</code> HTML element. Apart from that, this module contains styles and definitions for a simple <code>.toast</code> container, that you can use to display toast messages on your websites and web apps. Toasts mimic the native application notifications of certain devices, making them mobile friendly. Finally, a simple accessible <code>.tooltip</code> implementation is included along with an implementation for <code>.modal</code> dialogs. All components in this module are fully accessible, so that's another thing not to worry about.</p><br>
</div>
<div class="section">
<h2>Quick start</h2>
<p style="text-align:justify">To use the <strong>contextual</strong> module, simply include the link to the flavor you are using and start writing your HTML page as usual. One suggestion we will make is to add the following line inside your HTML page's <code>&lt;head&gt;</code> to utilize the viewport meta tag:</p>
<pre>&lt;<span class="fore-tertiary">meta</span> <span class="fore-secondary">name</span>=<span class="fore-primary">&quot;viewport&quot;</span> <span class="fore-secondary">content</span>=<span class="fore-primary">&quot;width=device-width, initial-scale=1&quot;</span>&gt;</pre><br>
</div>
</div>
</div>
</div>
<div class="row" id="text-highlighting">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Text highlighting</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<div>
<p>This is some text with a <mark>highlight</mark>.</p>
<p>Apart from the primary highlight style, there are also <mark class="secondary">secondary</mark> and <mark class="tertiary">tertiary</mark> styles for highlighting.</p><br>
<p><mark class="inline-block">If you want to highlight a longer piece of text, without line breaks, you can turn the highlight into an inline-block like you see this piece of text being displayed.</mark></p><br>
<p>Finally, you can create contextual tags like <mark class="tag">this</mark> or <mark class="tag">7</mark>.</p><br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align:justify">To add simple highlights in your text, you can use the <code>&lt;mark&gt;</code> HTML element. These highlights come pre-styled to use the default primary color, but if you would rather use another color for your highlight you can easily add the <code>.secondary</code> or <code>.tertiary</code> class to a <code>&lt;mark&gt;</code> element. For longer pieces of text that need highlighting, consider adding the <code>.inline-block</code> class to make them stand out even more. Finally, you can create contextual tags, using the <code>.tag</code> class.</p>
<h3>Sample code</h3>
<pre>&lt;mark&gt;primary&lt;/mark&gt;
&lt;mark class=&quot;secondary&quot;&gt;secondary&lt;/mark&gt;
&lt;mark class=&quot;tertiary&quot;&gt;tertiary&lt;/mark&gt;
&lt;mark class=&quot;inline-block&quot;&gt;long highlight text...&lt;/mark&gt;
&lt;mark class=&quot;tag&quot;&gt;tag&lt;/mark&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>Try to use elements with the <code>.inline-block</code> class only when absolutely necessary, as they break the normal text flow of the document. Avoid using this class on shorter pieces of text that span a few words and contain no line breaks.</li>
<li><code>&lt;mark&gt;</code> elements, along with their supporting classes (except for <code>.inline-block</code>) can be easily used in paragraphs, headings and other elements, as they scale according to their parent element.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;mark class=&quot;tag tertiary&quot;&gt;green tag&lt;/mark&gt;
<span class="fore-tertiary">&lt;!-- or --&gt;</span>
&lt;mark class=&quot;inline-block secondary&quot;&gt;red chunk&lt;/mark&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;You can combine any of the contextual color classes (<code>.secondary</code> or <code>.tertiary</code>) with the <code>.tag</code> or <code>.inline-block</code> class.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;mark class=&quot;secondary tertiary&quot;&gt;no, no&lt;/mark&gt;
<span class="fore-secondary">&lt;!-- or --&gt;</span>
&lt;mark class=&quot;inline-block tag&quot;&gt;oh, no&lt;/mark&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid combining two contextual color classes or a <code>.tag</code> and an <code>.inline-block</code>, as these combinations might result in unexpected behavior.</p>
</div>
<div class="col-sm-12 col-md-6">
<pre>&lt;mark class=&quot;inline-block&quot;&gt;some
&lt;mark class=&quot;secondary&quot;&gt;text&lt;/mark&gt;
&lt;/mark&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;You can only nest a <code>&lt;mark&gt;</code> inside another if the outer one is of the <code>.inline-block</code> class. You can color the inner <code>&lt;mark&gt;</code> using any of the contextual color classes or even make it a <code>.tag</code>. Be careful, however, to not make the inner <code>&lt;mark&gt;</code> an <code>.inline-block</code> as well.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;mark&gt;some
&lt;mark class=&quot;secondary&quot;&gt;text&lt;/mark&gt;
&lt;/mark&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid using nested <code>&lt;mark&gt;</code> elements, unless the outer <code>&lt;mark&gt;</code> element is an <code>.inline-block</code>.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="toasts">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Toasts</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal">
<div style="height: 15rem;">
<span class="toast demo">I'm a toast message!</span><br/>
<span class="toast small demo">I'm a small toast message!</span><br/>
<span class="toast large demo">I'm a large toast message!</span>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal">
<p style="text-align:justify">Toasts aim to help bridge the gap between web and native applications on mobile devices, by displaying native-looking toast messages. To create a toast, wrap some text inside a <code>&lt;span&gt;</code> element with the <code>.toast</code> class. Toasts appear at the bottom of the screen on top of everything else. If you want to create smaller or larger toast messasges, you can add the <code>.small</code> or <code>.large</code> classes respectively.</p>
<h3>Sample code</h3>
<pre>&lt;span class=&quot;toast&quot;&gt;This is a normal toast message!&lt;/span&gt;
&lt;span class=&quot;toast small&quot;&gt;This is a large toast message!&lt;/span&gt;
&lt;span class=&quot;toast large&quot;&gt;This is a small toast message!&lt;/span&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul>
<li>Toast elements do not have any pre-defined behavior. You should use your own Javascript code and interactive HTML elements to deal with showing and hiding them as necessary.</li>
<li>If you want to create your own color or size variants for toast messages, check out the <a href="customization">customization</a> page.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12">
<pre>&lt;span class=&quot;toast small large&quot;&gt;Not a good toast&lt;/span&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid combining two toast size variants, as this might cause unexpected behavior.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="tooltips">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Tooltips</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<div>
<br /><p class="tooltip" aria-label="This is a tooltip">Hover over this text to see a tooltip!</p><br />
<p class="tooltip bottom" aria-label="This is a tooltip">Hover over this text to see a reverse tooltip!</p><br />
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align:justify">Tooltips can be used to convey context-sensitive information when the user hovers over some text. To create a tooltip, simply wrap the text you want users to hover over in an element with the <code>.tooltip</code> class (our choice is usually a <code>&lt;span&gt;</code> element, but your needs may differ) and add an <code><span class="fore-secondary">aria-label</span></code> in that element, setting its value to the content of your tooltip. Tooltips display at the top of the hovered text by default, so if you want to show them below the text, add the <code>.bottom</code> class to them.</p>
<h3>Sample code</h3>
<pre>&lt;span class=&quot;tooltip&quot; aria-label=&quot;This is a tooltip&quot;&gt;Hover over this text to see a tooltip!&lt;/span&gt;
&lt;span class=&quot;tooltip bottom&quot; aria-label=&quot;This is a tooltip&quot;&gt;Hover over this text to see a reverse tooltip!&lt;/span&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>Tooltips are built to be accessible and should display properly on screenreaders.</li>
<li>If you are not satisfied with the default tooltip colors, please check out the <a href="customization">customization page</a> for instuctions on how to create your own tooltip variants.</li>
<li>Remember to always add the <code><span class="fore-secondary">aria-label</span></code> attribute, otherwise your tooltip will not have any text to show.</li>
</ul>
</div>
</div>
</div>
</div>
<div class="row" id="modals">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Modals</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<div style="text-align:center"><br/>
<label class="button primary large" for="modal-check">Click to display a modal dialog</label><br/><br/>
<input id="modal-check" type="checkbox"/>
<div class="modal" style="text-align:initial">
<div class="card">
<label for="modal-check" class="close"></label>
<h3 class="section double-padded">Modal</h3>
<div class="section double-padded">
<p>This is a modal window!</p>
<label class="button primary" for="modal-check">Close modal</label>
</div>
</div>
</div>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align: justify;">Modal dialogs are pretty ease to make. Simply create an <code>&lt;input <span class="fore-secondary">type</span>="<span class="fore-primary">checkbox</span>"&gt;</code> element, immediately followed by a <code>&lt;div&gt;</code> element with the <code>.modal</code> class. Inside this element, you can add a <code>.card</code> element with your modal dialog's contents. Remember to add a <code>&lt;label&gt;</code> element linked to your modal dialog's <code>&lt;input <span class="fore-secondary">type</span>="<span class="fore-primary">checkbox</span>"&gt;</code> to let users close the dialog. You can also apply the <code>.close</code> class to a <code>&lt;label&gt;</code> element to display a close icon at the top right of the modal dialog.</p>
<h3>Sample code</h3>
<pre>&lt;label for=&quot;modal-toggle&quot;&gt;Show modal&lt;/label&gt;
&lt;input id=&quot;modal-toggle&quot; type=&quot;checkbox&quot;/&gt;
&lt;div class=&quot;modal&quot;&gt;
&lt;div class=&quot;card&quot;&gt;
&lt;label for=&quot;modal-toggle&quot; class=&quot;close&quot;&gt;&lt;/label&gt;
&lt;h3 class=&quot;section&quot;&gt;Modal&lt;/h3&gt;
&lt;p class=&quot;section&quot;&gt;This is a modal window!&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align: justify;">
<li>You can use any styles you want from the <strong><a href="card">card</a></strong> module to create different dialogs based on context (e.g. alerts, warnings etc.).</li>
<li>Remember to add a <code>&lt;label&gt;</code> linked to your modal dialog's <code>&lt;input <span class="fore-secondary">type</span>="<span class="fore-primary">checkbox</span>"&gt;</code> or use Javascript to alter its state, otherwise users will not be able to close the dialog.</li>
<li>You can place your modal dialog anywhere on your page, as long as the structure is not altered. You can also toggle it from anywhere on a page.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;input id=&quot;modal-toggle&quot; type=&quot;checkbox&quot;/&gt;
&lt;label for=&quot;modal-toggle&quot;&gt;Show modal&lt;/label&gt;
&lt;div class=&quot;modal&quot; role=&quot;dialog&quot; aria-labelledby=&quot;dialogTitle&quot;&gt;
&lt;div class=&quot;card&quot;&gt;
&lt;label for=&quot;modal-toggle&quot; class=&quot;close&quot;&gt;&lt;/label&gt;
&lt;h3 class=&quot;section&quot; id=&quot;dialogTitle&quot;&gt;Bad Modal&lt;/h3&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;You can use the <code><span class="fore-secondary">role</span>=<span class="fore-primary">&quot;<a href="https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/ARIA_Techniques/Using_the_dialog_role">dialog</a>&quot;</span></code> to add accessibility to your modal dialogs. Remember to properly label it and manage keyboard focus, as required.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;input id=&quot;modal-toggle&quot; type=&quot;checkbox&quot;/&gt;
&lt;label for=&quot;modal-toggle&quot;&gt;Show modal&lt;/label&gt;
&lt;div class=&quot;modal&quot;&gt;
&lt;div class=&quot;card&quot;&gt;
&lt;label for=&quot;modal-toggle&quot; class=&quot;close&quot;&gt;&lt;/label&gt;
&lt;h3 class=&quot;section&quot;&gt;Bad Modal&lt;/h3&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align: justify;"><mark class="secondary">Don't:</mark>&nbsp;The syntax and structure of the modal dialog's container is very strict. Try to follow it exactly as described in this section.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" style="padding-bottom: 20px; padding-top:20px;">
<div class="col-sm-12">
<p style="text-align:justify">If you want to learn more about <strong>mini.css</strong>'s modules, go back to the <a href="modules">modules page</a> and choose another module to see its documentation.</p>
</div>
</div>
</main></div></div></div>
<footer style="text-align:justify"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<title>mini.css - Contextual</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, module, contextual ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-centered { text-align: center; } .box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;} .box-colored.red { background: #e53935; }
.box-centered > .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto; } [class^='col-'] .card.fluid { margin: 2px 0 20px; }
[class^='fore-'] { font-family: monospace, monospace;} .fore-primary { color: #0d47a1;} .fore-secondary { color: #b71c1c;} .fore-tertiary { color: #1b5e20;}
.col-sm-12.col-sm-last.col-md-4.col-md-normal { box-sizing: border-box; border-right: 1px solid #c9c9c9; }
@media (max-width: 767px){ .col-sm-12.col-sm-last.col-md-4.col-md-normal { border: 0; border-top: 1px solid #c9c9c9;}}
.col-sm-12.col-sm-last.col-md-12.col-md-normal { box-sizing: border-box; border-bottom: 1px solid #c9c9c9; }
@media (max-width: 767px){ .col-sm-12.col-sm-last.col-md-12.col-md-normal { border: 0; border-top: 1px solid #c9c9c9;}}
.box-colored.green { background: #689f38; } .do {border-top: 15px solid #689f38;padding-top: 10px;} .dont {border-top: 15px solid #e53935;padding-top: 10px;}
.box-colored {color: #f5f5f5;} @media (max-width: 767px){.container {padding: 0.25rem !important;}.col-sm-12.col-md-8.col-lg-10{padding: 0 !important;}}
.toast.demo { position: relative; top: 2rem; left: calc(50% - 6rem); z-index: 1;} .toast.demo.small { top: 4.5rem; left: calc(50% - 6.75rem);} .toast.demo.large { top: 7.5rem; left: calc(50% - 8rem);}
@media screen and (min-width: 768px) { .drawer { margin-top: 4px;}}
</style>
</head>
<body>
<header class="sticky">
<a href="index" class="logo"><span id="header-logo">m</span></a>
<label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="index" class="button hidden-sm">Introduction</a> <a href="modules" class="button hidden-sm">Modules</a>
<a href="flavors" class="button hidden-sm">Flavors</a> <a href="templates" class="button hidden-sm">Templates</a>
<a href="customization" class="button hidden-sm">Customization</a> <a href="quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<div class="container" style="padding-left: 0.25rem;">
<div class="row"> <input type="checkbox" id="navigation-toggle"> <nav class="drawer col-md-4 col-lg-2">
<label class="close" for="navigation-toggle"></label>
<a href="index"><h4 style="margin-left: 0;">Introduction</h4></a>
<h4 style="margin-left: 0;">Modules</h4> <a href="core#core-title">Core</a>
<a href="core#typography" class="sublink-1">Typography</a> <a href="core#headings" class="sublink-1">Headings</a>
<a href="core#common-textual-elements" class="sublink-1">Common textual elements</a>
<a href="core#lists" class="sublink-1">Lists</a> <a href="core#images-captions" class="sublink-1">Image responsiveness &amp; captions</a>
<br/> <a href="grid#grid-title">Grid</a>
<a href="grid#basic-layout" class="sublink-1">Basic layout</a> <a href="grid#screen-specific-layout" class="sublink-1">Screen specific layouts</a>
<a href="grid#predefined-layout" class="sublink-1">Predefined layouts</a> <a href="grid#column-offset" class="sublink-1">Column offsets</a>
<a href="grid#column-reorder" class="sublink-1">Column reordering</a> <a href="grid#media-object" class="sublink-1">Media object pattern</a>
<br/> <a href="input_control#input-control-title">Input Control</a>
<a href="input_control#forms-input" class="sublink-1">Forms &amp; input</a> <a href="input_control#checkbox-radio" class="sublink-1">Checkboxes &amp; radio buttons</a> <a href="input_control#switches" class="sublink-1">Switches</a>
<a href="input_control#buttons" class="sublink-1">Buttons &amp; button groups</a> <a href="input_control#file-upload" class="sublink-1">File upload buttons</a>
<br/> <a href="navigation#navigation-title">Navigation</a>
<a href="navigation#header" class="sublink-1">Header</a> <a href="navigation#navigation-bar" class="sublink-1">Navigation bar</a> <a href="navigation#drawer" class="sublink-1">Drawer</a>
<a href="navigation#footer" class="sublink-1">Footer</a> <a href="navigation#sticky" class="sublink-1">Sticky headers &amp; footers</a>
<br/> <a href="table#table-title">Table</a>
<a href="table#syntax-responsiveness" class="sublink-1">Basic syntax &amp; responsiveness</a> <a href="table#scrollable-tables" class="sublink-1">Scrollable tables</a>
<a href="table#horizontal-tables" class="sublink-1">Horizontal tables</a> <a href="table#variants-matrices" class="sublink-1">Table variants &amp; matrices</a>
<br/> <a href="card#card-title">Card</a>
<a href="card#basic-syntax" class="sublink-1">Basic syntax</a> <a href="card#sections-media" class="sublink-1">Sections &amp; media</a>
<a href="card#sizing-fluidity" class="sublink-1">Card sizing &amp; fluidity</a> <a href="card#color-variants" class="sublink-1">Card color variants</a>
<br/> <a href="tab#tab-title">Tab</a>
<a href="tab#basic-syntax" class="sublink-1">Basic syntax</a> <a href="tab#stacked-tabs" class="sublink-1">Stacked tabs</a>
<br/> <a href="contextual#contextual-title">Contextual</a>
<a href="contextual#text-highlighting" class="sublink-1">Text highlighting</a> <a href="contextual#toasts" class="sublink-1">Toasts</a>
<a href="contextual#tooltips" class="sublink-1">Tooltips</a> <a href="contextual#modals" class="sublink-1">Modals</a>
<br/> <a href="progress#progress-title">Progress</a>
<a href="progress#basic-progress-bar" class="sublink-1">Basic progress bar</a> <a href="progress#progress-variants" class="sublink-1">Progress bar variants</a>
<a href="progress#donut-spinner" class="sublink-1">Donut spinner</a> <a href="progress#spinner-variants" class="sublink-1">Donut spinner variants</a>
<br/> <a href="utility#utility-title">Utility</a>
<a href="utility#visibility-helpers" class="sublink-1">Visibility helpers</a> <a href="utility#borders-shadows" class="sublink-1">Generic borders &amp; shadows</a>
<a href="utility#responsive-sizing" class="sublink-1">Responsive sizing &amp; spacing classes</a>
<a href="utility#responsive-visibility" class="sublink-1">Responsive visibility helpers</a> <a href="utility#breadcrumbs" class="sublink-1">Breadcrumbs</a>
<a href="utility#close-icon" class="sublink-1">Close icon</a>
<a href="flavors"><h4 style="margin-left: 0;">Flavors</h4></a>
<a href="templates"><h4 style="margin-left: 0;">Templates</h4></a>
<a href="customization"><h4 style="margin-left: 0;">Customization</h4></a>
<a href="quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<div class="col-sm-12 col-md-8 col-lg-10"><main>
<div class="row" style="padding-top: 40px;" id="contextual-title">
<div class="col-sm-12">
<h1>Contextual</h1>
<p style="text-align:justify">The <strong>contextual</strong> module provides you with simple tags, marks and highlights for your pages, allowing you to easily emphasize parts of your text. Contextual toasts, tooltips and modals are also provided, aiming to help deliver important information to users. HTML5 elements and simple rules are used in order to make important messages and pieces of content stand out easily.</p>
<p style="text-align:justify"><small>All examples showcased refer to the mini-default flavor, some class names and styles might differ based on the flavor you're using.</small></p><br/>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<div class="card fluid">
<div class="section">
<h2>Quick overview</h2>
<p style="text-align:justify">Almost every website present on the web has some sort of content that needs highlighting in one way or another. The <strong>contextual</strong> module provides you with simple semantic text highlighting that utilises the <code>&lt;mark&gt;</code> HTML element. Apart from that, this module contains styles and definitions for a simple <code>.toast</code> container, that you can use to display toast messages on your websites and web apps. Toasts mimic the native application notifications of certain devices, making them mobile friendly. Finally, a simple accessible <code>.tooltip</code> implementation is included along with an implementation for <code>.modal</code> dialogs. All components in this module are fully accessible, so that's another thing not to worry about.</p><br>
</div>
<div class="section">
<h2>Quick start</h2>
<p style="text-align:justify">To use the <strong>contextual</strong> module, simply include the link to the flavor you are using and start writing your HTML page as usual. One suggestion we will make is to add the following line inside your HTML page's <code>&lt;head&gt;</code> to utilize the viewport meta tag:</p>
<pre>&lt;<span class="fore-tertiary">meta</span> <span class="fore-secondary">name</span>=<span class="fore-primary">&quot;viewport&quot;</span> <span class="fore-secondary">content</span>=<span class="fore-primary">&quot;width=device-width, initial-scale=1&quot;</span>&gt;</pre><br>
</div>
</div>
</div>
</div>
<div class="row" id="text-highlighting">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Text highlighting</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<div>
<p>This is some text with a <mark>highlight</mark>.</p>
<p>Apart from the primary highlight style, there are also <mark class="secondary">secondary</mark> and <mark class="tertiary">tertiary</mark> styles for highlighting.</p><br>
<p><mark class="inline-block">If you want to highlight a longer piece of text, without line breaks, you can turn the highlight into an inline-block like you see this piece of text being displayed.</mark></p><br>
<p>Finally, you can create contextual tags like <mark class="tag">this</mark> or <mark class="tag">7</mark>.</p><br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align:justify">To add simple highlights in your text, you can use the <code>&lt;mark&gt;</code> HTML element. These highlights come pre-styled to use the default primary color, but if you would rather use another color for your highlight you can easily add the <code>.secondary</code> or <code>.tertiary</code> class to a <code>&lt;mark&gt;</code> element. For longer pieces of text that need highlighting, consider adding the <code>.inline-block</code> class to make them stand out even more. Finally, you can create contextual tags, using the <code>.tag</code> class.</p>
<h3>Sample code</h3>
<pre>&lt;mark&gt;primary&lt;/mark&gt;
&lt;mark class=&quot;secondary&quot;&gt;secondary&lt;/mark&gt;
&lt;mark class=&quot;tertiary&quot;&gt;tertiary&lt;/mark&gt;
&lt;mark class=&quot;inline-block&quot;&gt;long highlight text...&lt;/mark&gt;
&lt;mark class=&quot;tag&quot;&gt;tag&lt;/mark&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>Try to use elements with the <code>.inline-block</code> class only when absolutely necessary, as they break the normal text flow of the document. Avoid using this class on shorter pieces of text that span a few words and contain no line breaks.</li>
<li><code>&lt;mark&gt;</code> elements, along with their supporting classes (except for <code>.inline-block</code>) can be easily used in paragraphs, headings and other elements, as they scale according to their parent element.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;mark class=&quot;tag tertiary&quot;&gt;green tag&lt;/mark&gt;
<span class="fore-tertiary">&lt;!-- or --&gt;</span>
&lt;mark class=&quot;inline-block secondary&quot;&gt;red chunk&lt;/mark&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;You can combine any of the contextual color classes (<code>.secondary</code> or <code>.tertiary</code>) with the <code>.tag</code> or <code>.inline-block</code> class.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;mark class=&quot;secondary tertiary&quot;&gt;no, no&lt;/mark&gt;
<span class="fore-secondary">&lt;!-- or --&gt;</span>
&lt;mark class=&quot;inline-block tag&quot;&gt;oh, no&lt;/mark&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid combining two contextual color classes or a <code>.tag</code> and an <code>.inline-block</code>, as these combinations might result in unexpected behavior.</p>
</div>
<div class="col-sm-12 col-md-6">
<pre>&lt;mark class=&quot;inline-block&quot;&gt;some
&lt;mark class=&quot;secondary&quot;&gt;text&lt;/mark&gt;
&lt;/mark&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;You can only nest a <code>&lt;mark&gt;</code> inside another if the outer one is of the <code>.inline-block</code> class. You can color the inner <code>&lt;mark&gt;</code> using any of the contextual color classes or even make it a <code>.tag</code>. Be careful, however, to not make the inner <code>&lt;mark&gt;</code> an <code>.inline-block</code> as well.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;mark&gt;some
&lt;mark class=&quot;secondary&quot;&gt;text&lt;/mark&gt;
&lt;/mark&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid using nested <code>&lt;mark&gt;</code> elements, unless the outer <code>&lt;mark&gt;</code> element is an <code>.inline-block</code>.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="toasts">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Toasts</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal">
<div style="height: 15rem;">
<span class="toast demo">I'm a toast message!</span><br/>
<span class="toast small demo">I'm a small toast message!</span><br/>
<span class="toast large demo">I'm a large toast message!</span>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal">
<p style="text-align:justify">Toasts aim to help bridge the gap between web and native applications on mobile devices, by displaying native-looking toast messages. To create a toast, wrap some text inside a <code>&lt;span&gt;</code> element with the <code>.toast</code> class. Toasts appear at the bottom of the screen on top of everything else. If you want to create smaller or larger toast messasges, you can add the <code>.small</code> or <code>.large</code> classes respectively.</p>
<h3>Sample code</h3>
<pre>&lt;span class=&quot;toast&quot;&gt;This is a normal toast message!&lt;/span&gt;
&lt;span class=&quot;toast small&quot;&gt;This is a large toast message!&lt;/span&gt;
&lt;span class=&quot;toast large&quot;&gt;This is a small toast message!&lt;/span&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul>
<li>Toast elements do not have any pre-defined behavior. You should use your own Javascript code and interactive HTML elements to deal with showing and hiding them as necessary.</li>
<li>If you want to create your own color or size variants for toast messages, check out the <a href="customization">customization</a> page.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12">
<pre>&lt;span class=&quot;toast small large&quot;&gt;Not a good toast&lt;/span&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid combining two toast size variants, as this might cause unexpected behavior.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="tooltips">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Tooltips</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<div>
<br /><p class="tooltip" aria-label="This is a tooltip">Hover over this text to see a tooltip!</p><br />
<p class="tooltip bottom" aria-label="This is a tooltip">Hover over this text to see a reverse tooltip!</p><br />
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align:justify">Tooltips can be used to convey context-sensitive information when the user hovers over some text. To create a tooltip, simply wrap the text you want users to hover over in an element with the <code>.tooltip</code> class (our choice is usually a <code>&lt;span&gt;</code> element, but your needs may differ) and add an <code><span class="fore-secondary">aria-label</span></code> in that element, setting its value to the content of your tooltip. Tooltips display at the top of the hovered text by default, so if you want to show them below the text, add the <code>.bottom</code> class to them.</p>
<h3>Sample code</h3>
<pre>&lt;span class=&quot;tooltip&quot; aria-label=&quot;This is a tooltip&quot;&gt;Hover over this text to see a tooltip!&lt;/span&gt;
&lt;span class=&quot;tooltip bottom&quot; aria-label=&quot;This is a tooltip&quot;&gt;Hover over this text to see a reverse tooltip!&lt;/span&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>Tooltips are built to be accessible and should display properly on screenreaders.</li>
<li>If you are not satisfied with the default tooltip colors, please check out the <a href="customization">customization page</a> for instuctions on how to create your own tooltip variants.</li>
<li>Remember to always add the <code><span class="fore-secondary">aria-label</span></code> attribute, otherwise your tooltip will not have any text to show.</li>
</ul>
</div>
</div>
</div>
</div>
<div class="row" id="modals">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Modals</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<div style="text-align:center"><br/>
<label class="button primary large" for="modal-check">Click to display a modal dialog</label><br/><br/>
<input id="modal-check" type="checkbox"/>
<div class="modal" style="text-align:initial">
<div class="card">
<label for="modal-check" class="close"></label>
<h3 class="section double-padded">Modal</h3>
<div class="section double-padded">
<p>This is a modal window!</p>
<label class="button primary" for="modal-check">Close modal</label>
</div>
</div>
</div>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align: justify;">Modal dialogs are pretty ease to make. Simply create an <code>&lt;input <span class="fore-secondary">type</span>="<span class="fore-primary">checkbox</span>"&gt;</code> element, immediately followed by a <code>&lt;div&gt;</code> element with the <code>.modal</code> class. Inside this element, you can add a <code>.card</code> element with your modal dialog's contents. Remember to add a <code>&lt;label&gt;</code> element linked to your modal dialog's <code>&lt;input <span class="fore-secondary">type</span>="<span class="fore-primary">checkbox</span>"&gt;</code> to let users close the dialog. You can also apply the <code>.close</code> class to a <code>&lt;label&gt;</code> element to display a close icon at the top right of the modal dialog.</p>
<h3>Sample code</h3>
<pre>&lt;label for=&quot;modal-toggle&quot;&gt;Show modal&lt;/label&gt;
&lt;input id=&quot;modal-toggle&quot; type=&quot;checkbox&quot;/&gt;
&lt;div class=&quot;modal&quot;&gt;
&lt;div class=&quot;card&quot;&gt;
&lt;label for=&quot;modal-toggle&quot; class=&quot;close&quot;&gt;&lt;/label&gt;
&lt;h3 class=&quot;section&quot;&gt;Modal&lt;/h3&gt;
&lt;p class=&quot;section&quot;&gt;This is a modal window!&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align: justify;">
<li>You can use any styles you want from the <strong><a href="card">card</a></strong> module to create different dialogs based on context (e.g. alerts, warnings etc.).</li>
<li>Remember to add a <code>&lt;label&gt;</code> linked to your modal dialog's <code>&lt;input <span class="fore-secondary">type</span>="<span class="fore-primary">checkbox</span>"&gt;</code> or use Javascript to alter its state, otherwise users will not be able to close the dialog.</li>
<li>You can place your modal dialog anywhere on your page, as long as the structure is not altered. You can also toggle it from anywhere on a page.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;input id=&quot;modal-toggle&quot; type=&quot;checkbox&quot;/&gt;
&lt;label for=&quot;modal-toggle&quot;&gt;Show modal&lt;/label&gt;
&lt;div class=&quot;modal&quot; role=&quot;dialog&quot; aria-labelledby=&quot;dialogTitle&quot;&gt;
&lt;div class=&quot;card&quot;&gt;
&lt;label for=&quot;modal-toggle&quot; class=&quot;close&quot;&gt;&lt;/label&gt;
&lt;h3 class=&quot;section&quot; id=&quot;dialogTitle&quot;&gt;Bad Modal&lt;/h3&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;You can use the <code><span class="fore-secondary">role</span>=<span class="fore-primary">&quot;<a href="https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/ARIA_Techniques/Using_the_dialog_role">dialog</a>&quot;</span></code> to add accessibility to your modal dialogs. Remember to properly label it and manage keyboard focus, as required.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;input id=&quot;modal-toggle&quot; type=&quot;checkbox&quot;/&gt;
&lt;label for=&quot;modal-toggle&quot;&gt;Show modal&lt;/label&gt;
&lt;div class=&quot;modal&quot;&gt;
&lt;div class=&quot;card&quot;&gt;
&lt;label for=&quot;modal-toggle&quot; class=&quot;close&quot;&gt;&lt;/label&gt;
&lt;h3 class=&quot;section&quot;&gt;Bad Modal&lt;/h3&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align: justify;"><mark class="secondary">Don't:</mark>&nbsp;The syntax and structure of the modal dialog's container is very strict. Try to follow it exactly as described in this section.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" style="padding-bottom: 20px; padding-top:20px;">
<div class="col-sm-12">
<p style="text-align:justify">If you want to learn more about <strong>mini.css</strong>'s modules, go back to the <a href="modules">modules page</a> and choose another module to see its documentation.</p>
</div>
</div>
</main></div></div></div>
<footer style="text-align:justify"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>

View file

@ -1,255 +1,255 @@
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<title>mini.css - Core</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, module, core ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;}
.box-centered { text-align: center; } .box-colored.red { background: #e53935; }
.box-centered > .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto;} [class^='col-'] .card.fluid { margin: 2px 0 20px; }
[class^='fore-'] { font-family: monospace, monospace;} .fore-primary { color: #0d47a1;} .fore-secondary { color: #b71c1c;} .fore-tertiary { color: #1b5e20;}
.col-sm-12.col-sm-last.col-md-4.col-md-normal { box-sizing: border-box; border-right: 1px solid #bdbdbd; }
@media (max-width: 767px){ .col-sm-12.col-sm-last.col-md-4.col-md-normal { border: 0; border-top: 1px solid #bdbdbd; } }
@media (max-width: 767px){.container {padding: 0.25rem !important;}.col-sm-12.col-md-8.col-lg-10{padding: 0 !important;}}
@media screen and (min-width: 768px) { .drawer { margin-top: 4px;}}
</style>
</head>
<body>
<header class="sticky">
<a href="index" class="logo"><span id="header-logo">m</span></a>
<label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="index" class="button hidden-sm">Introduction</a> <a href="modules" class="button hidden-sm">Modules</a>
<a href="flavors" class="button hidden-sm">Flavors</a> <a href="templates" class="button hidden-sm">Templates</a>
<a href="customization" class="button hidden-sm">Customization</a> <a href="quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<div class="container" style="padding-left: 0.25rem;">
<div class="row"> <input type="checkbox" id="navigation-toggle"> <nav class="drawer col-md-4 col-lg-2">
<label class="close" for="navigation-toggle"></label>
<a href="index"><h4 style="margin-left: 0;">Introduction</h4></a>
<h4 style="margin-left: 0;">Modules</h4> <a href="core#core-title">Core</a>
<a href="core#typography" class="sublink-1">Typography</a> <a href="core#headings" class="sublink-1">Headings</a>
<a href="core#common-textual-elements" class="sublink-1">Common textual elements</a>
<a href="core#lists" class="sublink-1">Lists</a> <a href="core#images-captions" class="sublink-1">Image responsiveness &amp; captions</a>
<br/> <a href="grid#grid-title">Grid</a>
<a href="grid#basic-layout" class="sublink-1">Basic layout</a> <a href="grid#screen-specific-layout" class="sublink-1">Screen specific layouts</a>
<a href="grid#predefined-layout" class="sublink-1">Predefined layouts</a> <a href="grid#column-offset" class="sublink-1">Column offsets</a>
<a href="grid#column-reorder" class="sublink-1">Column reordering</a> <a href="grid#media-object" class="sublink-1">Media object pattern</a>
<br/> <a href="input_control#input-control-title">Input Control</a>
<a href="input_control#forms-input" class="sublink-1">Forms &amp; input</a> <a href="input_control#checkbox-radio" class="sublink-1">Checkboxes &amp; radio buttons</a> <a href="input_control#switches" class="sublink-1">Switches</a>
<a href="input_control#buttons" class="sublink-1">Buttons &amp; button groups</a> <a href="input_control#file-upload" class="sublink-1">File upload buttons</a>
<br/> <a href="navigation#navigation-title">Navigation</a>
<a href="navigation#header" class="sublink-1">Header</a> <a href="navigation#navigation-bar" class="sublink-1">Navigation bar</a> <a href="navigation#drawer" class="sublink-1">Drawer</a>
<a href="navigation#footer" class="sublink-1">Footer</a> <a href="navigation#sticky" class="sublink-1">Sticky headers &amp; footers</a>
<br/> <a href="table#table-title">Table</a>
<a href="table#syntax-responsiveness" class="sublink-1">Basic syntax &amp; responsiveness</a> <a href="table#scrollable-tables" class="sublink-1">Scrollable tables</a>
<a href="table#horizontal-tables" class="sublink-1">Horizontal tables</a> <a href="table#variants-matrices" class="sublink-1">Table variants &amp; matrices</a>
<br/> <a href="card#card-title">Card</a>
<a href="card#basic-syntax" class="sublink-1">Basic syntax</a> <a href="card#sections-media" class="sublink-1">Sections &amp; media</a>
<a href="card#sizing-fluidity" class="sublink-1">Card sizing &amp; fluidity</a> <a href="card#color-variants" class="sublink-1">Card color variants</a>
<br/> <a href="tab#tab-title">Tab</a>
<a href="tab#basic-syntax" class="sublink-1">Basic syntax</a> <a href="tab#stacked-tabs" class="sublink-1">Stacked tabs</a>
<br/> <a href="contextual#contextual-title">Contextual</a>
<a href="contextual#text-highlighting" class="sublink-1">Text highlighting</a> <a href="contextual#toasts" class="sublink-1">Toasts</a>
<a href="contextual#tooltips" class="sublink-1">Tooltips</a> <a href="contextual#modals" class="sublink-1">Modals</a>
<br/> <a href="progress#progress-title">Progress</a>
<a href="progress#basic-progress-bar" class="sublink-1">Basic progress bar</a> <a href="progress#progress-variants" class="sublink-1">Progress bar variants</a>
<a href="progress#donut-spinner" class="sublink-1">Donut spinner</a> <a href="progress#spinner-variants" class="sublink-1">Donut spinner variants</a>
<br/> <a href="utility#utility-title">Utility</a>
<a href="utility#visibility-helpers" class="sublink-1">Visibility helpers</a> <a href="utility#borders-shadows" class="sublink-1">Generic borders &amp; shadows</a>
<a href="utility#responsive-sizing" class="sublink-1">Responsive sizing &amp; spacing classes</a>
<a href="utility#responsive-visibility" class="sublink-1">Responsive visibility helpers</a> <a href="utility#breadcrumbs" class="sublink-1">Breadcrumbs</a>
<a href="utility#close-icon" class="sublink-1">Close icon</a>
<a href="flavors"><h4 style="margin-left: 0;">Flavors</h4></a>
<a href="templates"><h4 style="margin-left: 0;">Templates</h4></a>
<a href="customization"><h4 style="margin-left: 0;">Customization</h4></a>
<a href="quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<div class="col-sm-12 col-md-8 col-lg-10"><main>
<div class="row" style="padding-top: 40px;" id="core-title">
<div class="col-sm-12">
<h1>Core</h1>
<p style="text-align: justify;">The <strong>core</strong> module contains basic reset and fix rules, based on <a href="http://necolas.github.io/normalize.css/">Normalize.css</a> v5.0.0, along with lots of custom typography rules. Most textual HTML5 elements are styled by this module, so you can start writing your pages immediately without worrying about font families, weights, sizes, line heights, paddings and the like.</p>
<p style="text-align: justify;"><small>All examples showcased refer to the mini-default flavor, some class names and styles might differ based on the flavor you're using.</small></p><br/>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<div class="card fluid">
<div class="section">
<h2>Quick overview</h2>
<p style="text-align: justify;">Before applying any typography and styling rules, some resets need to be applied to make sure that different elements display consistently on all browsers. The <strong>core</strong> module utilizes the ruleset of <a href="http://necolas.github.io/normalize.css/">Normalize.css</a> v5.0.0 to apply those much needed resets and fixes. However, to keep the framework small, we removed some rules that only help with legacy browser support and also tweaked a lot of the rules around to use customizable variables so no duplicate rules are applied, taking up unnecessary space. The typography rules in <strong>core</strong> deal with a page's basics, like fonts and styling of headings and paragraphs, horizontal rules, colors, margins, padding etc.</p><br>
</div>
<div class="section">
<h2>Quick start</h2>
<p style="text-align: justify;">To use the <strong>core</strong> module, simply include the link to the flavor you are using and start writing your HTML page as usual. One suggestion we will make is to add the following line inside your HTML page's <code>&lt;head&gt;</code> to utilize the viewport meta tag:</p>
<pre>&lt;<span class="fore-tertiary">meta</span> <span class="fore-secondary">name</span>=<span class="fore-primary">&quot;viewport&quot;</span> <span class="fore-secondary">content</span>=<span class="fore-primary">&quot;width=device-width, initial-scale=1&quot;</span>&gt;</pre>
<figure style="margin: 0;" class="hidden-sm"><div style="position: relative; padding: 0.5rem; padding-bottom: 42%; margin-bottom: 0.25rem; margin-right: 1rem;"><iframe style="display: none; border: 0; position: absolute; width: 100%; height: 100%;" onload="this.style.display='block';" src="https://scrimba.com/cast/cast-1949.embed"></iframe></div><figcaption style="padding: 0.5rem;">Intro to mini.css by <a href="https://scrimba.com/casts/cast-1949" style="font-size: 0.8125rem; text-decoration: none;">Per Harald Borgen</a></figcaption></figure><br/>
</div>
</div>
</div>
</div>
<div class="row" id="typography">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Typography</h2></div>
<div class="section row">
<div class="col-sm-12">
<p style="text-align: justify;">For the basic typography rules we did the following, along with other things presented below:</p>
<ul>
<li>We use a <a href="https://www.smashingmagazine.com/2015/11/using-system-ui-fonts-practical-guide/">native font stack</a> to figure out the best font for your device.</li>
<li>We set the colors to <code>background: #f8f8f8;</code> and <code>color: #212121;</code>.</li>
<li>We use a <code>font-size</code> of <code>16px</code> for the root element.</li>
<li>We set <code>line-height</code> to <code>1.5</code>.</li>
</ul>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>Fluid typography is also included, but not enabled by default. If you want to try it out, check out the out the <a href="customization">customization</a> page.</li>
</ul>
</div>
</div>
</div>
</div>
<div class="row" id="headings">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Headings</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal row">
<div class="col-sm-12 col-lg-6 col-lg-first"><h1>Heading 1<small>Subheading</small></h1></div>
<div class="col-sm-12 col-lg-6"><h2>Heading 2<small>Subheading</small></h2></div>
<div class="col-sm-12 col-lg-6 col-lg-last"><h3>Heading 3<small>Subheading</small></h3></div>
<div class="col-sm-12 col-lg-6 col-lg-first"><h4>Heading 4<small>Subheading</small></h4></div>
<div class="col-sm-12 col-lg-6"><h5>Heading 5<small>Subheading</small></h5></div>
<div class="col-sm-12 col-lg-6 col-lg-last"><h6>Heading 6<small>Subheading</small></h6></div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align: justify;">All six of the HTML headings (<code>&lt;h1&gt;</code> - <code>&lt;h6&gt;</code>) are styled with simple rules, providing a clean base for your pages' headings. Apart from the headings themselves, complementary rules are provided for <code>&lt;small&gt;</code> elements inside headings, allowing you to define subheadings or explanatory text for those headings. These subheadings are stylized to display below the headings in smaller, lighter type.</p>
<h3>Sample code</h3>
<pre>&lt;h1&gt;Heading 1&lt;small&gt;Subheading&lt;/small&gt;&lt;/h1&gt;
&lt;h2&gt;Heading 2&lt;small&gt;Subheading&lt;/small&gt;&lt;/h2&gt;
&lt;h3&gt;Heading 3&lt;small&gt;Subheading&lt;/small&gt;&lt;/h3&gt;
&lt;h4&gt;Heading 4&lt;small&gt;Subheading&lt;/small&gt;&lt;/h4&gt;
&lt;h5&gt;Heading 5&lt;small&gt;Subheading&lt;/small&gt;&lt;/h5&gt;
&lt;h6&gt;Heading 6&lt;small&gt;Subheading&lt;/small&gt;&lt;/h6&gt;</pre><br>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="common-textual-elements">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Common textual elements</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<div><p>This is a paragraph with some sample text. Did you know <strong>mini.css</strong> v2 is codenamed <strong>Fermion</strong>? No? Well, now you do! Oh, by the way, that was some Bold text and here is some <em>text in Italics</em>. Maybe you want to know what our inline elements look like. For example a <a href="https://github.com/Chalarangelo/mini.css">link to the Github repository of mini.css</a> looks like that! Neat, right? Maybe you want to see some <code>inline code</code> or some sample <kbd>input</kbd>. Oh, also <small>small text</small> is cool, along with its siblings: the subscript<sub>hi!</sub> and the superscript<sup>hello!</sup>. Finally, check out the horizontal rule, preformatted code block and quotation below.</p><hr>
<pre>function sum(num1, num2) {
var num3 = num1 + num2;
console.log('Result: ' + num3);
}</pre>
<blockquote cite="https://www.google.com">This is some quoted text from elsewhere.</blockquote><br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align: justify;">The most common HTML5 elements must be things like <code>&lt;p&gt;</code>aragraphs, bold (<code>&lt;strong&gt;</code>) &amp; italics (<code>&lt;em&gt;</code>) text, links (<code>&lt;a&gt;</code>), horizontal rules (<code>&lt;hr&gt;</code>) and <code>&lt;small&gt;</code> text. These, along with a few others, are styled by default using clean, modern design to make your pages look cool and stand out from the rest of the internet.</p>
<h3>Sample code</h3>
<pre>&lt;p&gt;This is a paragraph with some &lt;strong&gt;bold text&lt;/strong&gt; and some &lt;em&gt;italics text&lt;/em&gt;.&lt;/p&gt;
&lt;a href=&quot;#&quot;&gt;This is a link.&lt;/a&gt;
&lt;small&gt;This is some small text.&lt;/small&gt;
&lt;sub&gt;Subscript&lt;/sub&gt;
&lt;sup&gt;Superscript&lt;/sup&gt;
&lt;code&gt;Inline code&lt;/code&gt;
&lt;kbd&gt;Keyboard Input&lt;/kbd&gt;
&lt;hr&gt;
&lt;pre&gt;This is some preformatted text.&lt;/pre&gt;
&lt;blockquote cite=&quot;www.quotation.source&quot;&gt;
This is some quoted text from another website or person.
&lt;/blockquote&gt;</pre><br>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="lists">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Lists</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<div><br>
<ul>
<li>Apple</li>
<li>Orange</li>
<li>Strawberry</li>
</ul><br>
<ol>
<li>Wake up</li>
<li>Eat breakfast</li>
<li>Go to work</li>
</ol><br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align: justify;">Lists are also very commonly used in websites and apps. We tweaked a few margins and paddings to save some space and make them align properly with the rest of the common HTML elements that we use, but both unordered lists (<code>&lt;ul&gt;</code>) and ordered lists (<code>&lt;ol&gt;</code>) are minimally pre-styled to make things a little bit easier for you.</p>
<h3>Sample code</h3>
<pre>&lt;ul&gt;
&lt;li&gt;Apple&lt;/li&gt;
&lt;li&gt;Orange&lt;/li&gt;
&lt;li&gt;Strawberry&lt;/li&gt;
&lt;/ul&gt;
&lt;ol&gt;
&lt;li&gt;Wake up&lt;/li&gt;
&lt;li&gt;Eat breakfast&lt;/li&gt;
&lt;li&gt;Go to work&lt;/li&gt;
&lt;/ol&gt;</pre><br>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="images-captions">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Image responsiveness &amp; captions</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<div><figure><img src="https://placehold.it/800x600" alt="image"><figcaption>Image caption</figcaption></figure></div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align: justify;">Image elements (<code>&lt;img&gt;</code>) are responsive by default, without the need for any special classes or anything else. We made sure they will scale down as necessary to display properly on smaller devices, while keeping their original aspect ratio, but they will never scale up above their original size.</p> <p>On a side note, if you want to add captions to images, you can use a <code>&lt;figcaption&gt;</code> element, while wrapping both the image and it inside a <code>&lt;figure&gt;</code>.</p>
<h3>Sample code</h3>
<pre>&lt;figure&gt;
&lt;img src=&quot;...&quot;&gt;
&lt;figcaption&gt;Image caption&lt;/figcaption&gt;
&lt;/figure&gt;</pre><br>
</div>
</div>
</div>
</div>
</div>
<div class="row" style="padding-bottom: 20px; padding-top:20px;">
<div class="col-sm-12">
<p style="text-align: justify;">If you want to learn more about <strong>mini.css</strong>'s modules, go back to the <a href="modules">modules page</a> and choose another module to see its documentation.</p>
</div>
</div>
</main></div></div></div>
<footer style="text-align: justify;"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<title>mini.css - Core</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, module, core ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;}
.box-centered { text-align: center; } .box-colored.red { background: #e53935; }
.box-centered > .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto;} [class^='col-'] .card.fluid { margin: 2px 0 20px; }
[class^='fore-'] { font-family: monospace, monospace;} .fore-primary { color: #0d47a1;} .fore-secondary { color: #b71c1c;} .fore-tertiary { color: #1b5e20;}
.col-sm-12.col-sm-last.col-md-4.col-md-normal { box-sizing: border-box; border-right: 1px solid #bdbdbd; }
@media (max-width: 767px){ .col-sm-12.col-sm-last.col-md-4.col-md-normal { border: 0; border-top: 1px solid #bdbdbd; } }
@media (max-width: 767px){.container {padding: 0.25rem !important;}.col-sm-12.col-md-8.col-lg-10{padding: 0 !important;}}
@media screen and (min-width: 768px) { .drawer { margin-top: 4px;}}
</style>
</head>
<body>
<header class="sticky">
<a href="index" class="logo"><span id="header-logo">m</span></a>
<label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="index" class="button hidden-sm">Introduction</a> <a href="modules" class="button hidden-sm">Modules</a>
<a href="flavors" class="button hidden-sm">Flavors</a> <a href="templates" class="button hidden-sm">Templates</a>
<a href="customization" class="button hidden-sm">Customization</a> <a href="quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<div class="container" style="padding-left: 0.25rem;">
<div class="row"> <input type="checkbox" id="navigation-toggle"> <nav class="drawer col-md-4 col-lg-2">
<label class="close" for="navigation-toggle"></label>
<a href="index"><h4 style="margin-left: 0;">Introduction</h4></a>
<h4 style="margin-left: 0;">Modules</h4> <a href="core#core-title">Core</a>
<a href="core#typography" class="sublink-1">Typography</a> <a href="core#headings" class="sublink-1">Headings</a>
<a href="core#common-textual-elements" class="sublink-1">Common textual elements</a>
<a href="core#lists" class="sublink-1">Lists</a> <a href="core#images-captions" class="sublink-1">Image responsiveness &amp; captions</a>
<br/> <a href="grid#grid-title">Grid</a>
<a href="grid#basic-layout" class="sublink-1">Basic layout</a> <a href="grid#screen-specific-layout" class="sublink-1">Screen specific layouts</a>
<a href="grid#predefined-layout" class="sublink-1">Predefined layouts</a> <a href="grid#column-offset" class="sublink-1">Column offsets</a>
<a href="grid#column-reorder" class="sublink-1">Column reordering</a> <a href="grid#media-object" class="sublink-1">Media object pattern</a>
<br/> <a href="input_control#input-control-title">Input Control</a>
<a href="input_control#forms-input" class="sublink-1">Forms &amp; input</a> <a href="input_control#checkbox-radio" class="sublink-1">Checkboxes &amp; radio buttons</a> <a href="input_control#switches" class="sublink-1">Switches</a>
<a href="input_control#buttons" class="sublink-1">Buttons &amp; button groups</a> <a href="input_control#file-upload" class="sublink-1">File upload buttons</a>
<br/> <a href="navigation#navigation-title">Navigation</a>
<a href="navigation#header" class="sublink-1">Header</a> <a href="navigation#navigation-bar" class="sublink-1">Navigation bar</a> <a href="navigation#drawer" class="sublink-1">Drawer</a>
<a href="navigation#footer" class="sublink-1">Footer</a> <a href="navigation#sticky" class="sublink-1">Sticky headers &amp; footers</a>
<br/> <a href="table#table-title">Table</a>
<a href="table#syntax-responsiveness" class="sublink-1">Basic syntax &amp; responsiveness</a> <a href="table#scrollable-tables" class="sublink-1">Scrollable tables</a>
<a href="table#horizontal-tables" class="sublink-1">Horizontal tables</a> <a href="table#variants-matrices" class="sublink-1">Table variants &amp; matrices</a>
<br/> <a href="card#card-title">Card</a>
<a href="card#basic-syntax" class="sublink-1">Basic syntax</a> <a href="card#sections-media" class="sublink-1">Sections &amp; media</a>
<a href="card#sizing-fluidity" class="sublink-1">Card sizing &amp; fluidity</a> <a href="card#color-variants" class="sublink-1">Card color variants</a>
<br/> <a href="tab#tab-title">Tab</a>
<a href="tab#basic-syntax" class="sublink-1">Basic syntax</a> <a href="tab#stacked-tabs" class="sublink-1">Stacked tabs</a>
<br/> <a href="contextual#contextual-title">Contextual</a>
<a href="contextual#text-highlighting" class="sublink-1">Text highlighting</a> <a href="contextual#toasts" class="sublink-1">Toasts</a>
<a href="contextual#tooltips" class="sublink-1">Tooltips</a> <a href="contextual#modals" class="sublink-1">Modals</a>
<br/> <a href="progress#progress-title">Progress</a>
<a href="progress#basic-progress-bar" class="sublink-1">Basic progress bar</a> <a href="progress#progress-variants" class="sublink-1">Progress bar variants</a>
<a href="progress#donut-spinner" class="sublink-1">Donut spinner</a> <a href="progress#spinner-variants" class="sublink-1">Donut spinner variants</a>
<br/> <a href="utility#utility-title">Utility</a>
<a href="utility#visibility-helpers" class="sublink-1">Visibility helpers</a> <a href="utility#borders-shadows" class="sublink-1">Generic borders &amp; shadows</a>
<a href="utility#responsive-sizing" class="sublink-1">Responsive sizing &amp; spacing classes</a>
<a href="utility#responsive-visibility" class="sublink-1">Responsive visibility helpers</a> <a href="utility#breadcrumbs" class="sublink-1">Breadcrumbs</a>
<a href="utility#close-icon" class="sublink-1">Close icon</a>
<a href="flavors"><h4 style="margin-left: 0;">Flavors</h4></a>
<a href="templates"><h4 style="margin-left: 0;">Templates</h4></a>
<a href="customization"><h4 style="margin-left: 0;">Customization</h4></a>
<a href="quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<div class="col-sm-12 col-md-8 col-lg-10"><main>
<div class="row" style="padding-top: 40px;" id="core-title">
<div class="col-sm-12">
<h1>Core</h1>
<p style="text-align: justify;">The <strong>core</strong> module contains basic reset and fix rules, based on <a href="http://necolas.github.io/normalize.css/">Normalize.css</a> v5.0.0, along with lots of custom typography rules. Most textual HTML5 elements are styled by this module, so you can start writing your pages immediately without worrying about font families, weights, sizes, line heights, paddings and the like.</p>
<p style="text-align: justify;"><small>All examples showcased refer to the mini-default flavor, some class names and styles might differ based on the flavor you're using.</small></p><br/>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<div class="card fluid">
<div class="section">
<h2>Quick overview</h2>
<p style="text-align: justify;">Before applying any typography and styling rules, some resets need to be applied to make sure that different elements display consistently on all browsers. The <strong>core</strong> module utilizes the ruleset of <a href="http://necolas.github.io/normalize.css/">Normalize.css</a> v5.0.0 to apply those much needed resets and fixes. However, to keep the framework small, we removed some rules that only help with legacy browser support and also tweaked a lot of the rules around to use customizable variables so no duplicate rules are applied, taking up unnecessary space. The typography rules in <strong>core</strong> deal with a page's basics, like fonts and styling of headings and paragraphs, horizontal rules, colors, margins, padding etc.</p><br>
</div>
<div class="section">
<h2>Quick start</h2>
<p style="text-align: justify;">To use the <strong>core</strong> module, simply include the link to the flavor you are using and start writing your HTML page as usual. One suggestion we will make is to add the following line inside your HTML page's <code>&lt;head&gt;</code> to utilize the viewport meta tag:</p>
<pre>&lt;<span class="fore-tertiary">meta</span> <span class="fore-secondary">name</span>=<span class="fore-primary">&quot;viewport&quot;</span> <span class="fore-secondary">content</span>=<span class="fore-primary">&quot;width=device-width, initial-scale=1&quot;</span>&gt;</pre>
<figure style="margin: 0;" class="hidden-sm"><div style="position: relative; padding: 0.5rem; padding-bottom: 42%; margin-bottom: 0.25rem; margin-right: 1rem;"><iframe style="display: none; border: 0; position: absolute; width: 100%; height: 100%;" onload="this.style.display='block';" src="https://scrimba.com/cast/cast-1949.embed"></iframe></div><figcaption style="padding: 0.5rem;">Intro to mini.css by <a href="https://scrimba.com/casts/cast-1949" style="font-size: 0.8125rem; text-decoration: none;">Per Harald Borgen</a></figcaption></figure><br/>
</div>
</div>
</div>
</div>
<div class="row" id="typography">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Typography</h2></div>
<div class="section row">
<div class="col-sm-12">
<p style="text-align: justify;">For the basic typography rules we did the following, along with other things presented below:</p>
<ul>
<li>We use a <a href="https://www.smashingmagazine.com/2015/11/using-system-ui-fonts-practical-guide/">native font stack</a> to figure out the best font for your device.</li>
<li>We set the colors to <code>background: #f8f8f8;</code> and <code>color: #212121;</code>.</li>
<li>We use a <code>font-size</code> of <code>16px</code> for the root element.</li>
<li>We set <code>line-height</code> to <code>1.5</code>.</li>
</ul>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>Fluid typography is also included, but not enabled by default. If you want to try it out, check out the out the <a href="customization">customization</a> page.</li>
</ul>
</div>
</div>
</div>
</div>
<div class="row" id="headings">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Headings</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal row">
<div class="col-sm-12 col-lg-6 col-lg-first"><h1>Heading 1<small>Subheading</small></h1></div>
<div class="col-sm-12 col-lg-6"><h2>Heading 2<small>Subheading</small></h2></div>
<div class="col-sm-12 col-lg-6 col-lg-last"><h3>Heading 3<small>Subheading</small></h3></div>
<div class="col-sm-12 col-lg-6 col-lg-first"><h4>Heading 4<small>Subheading</small></h4></div>
<div class="col-sm-12 col-lg-6"><h5>Heading 5<small>Subheading</small></h5></div>
<div class="col-sm-12 col-lg-6 col-lg-last"><h6>Heading 6<small>Subheading</small></h6></div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align: justify;">All six of the HTML headings (<code>&lt;h1&gt;</code> - <code>&lt;h6&gt;</code>) are styled with simple rules, providing a clean base for your pages' headings. Apart from the headings themselves, complementary rules are provided for <code>&lt;small&gt;</code> elements inside headings, allowing you to define subheadings or explanatory text for those headings. These subheadings are stylized to display below the headings in smaller, lighter type.</p>
<h3>Sample code</h3>
<pre>&lt;h1&gt;Heading 1&lt;small&gt;Subheading&lt;/small&gt;&lt;/h1&gt;
&lt;h2&gt;Heading 2&lt;small&gt;Subheading&lt;/small&gt;&lt;/h2&gt;
&lt;h3&gt;Heading 3&lt;small&gt;Subheading&lt;/small&gt;&lt;/h3&gt;
&lt;h4&gt;Heading 4&lt;small&gt;Subheading&lt;/small&gt;&lt;/h4&gt;
&lt;h5&gt;Heading 5&lt;small&gt;Subheading&lt;/small&gt;&lt;/h5&gt;
&lt;h6&gt;Heading 6&lt;small&gt;Subheading&lt;/small&gt;&lt;/h6&gt;</pre><br>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="common-textual-elements">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Common textual elements</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<div><p>This is a paragraph with some sample text. Did you know <strong>mini.css</strong> v2 is codenamed <strong>Fermion</strong>? No? Well, now you do! Oh, by the way, that was some Bold text and here is some <em>text in Italics</em>. Maybe you want to know what our inline elements look like. For example a <a href="https://github.com/Chalarangelo/mini.css">link to the Github repository of mini.css</a> looks like that! Neat, right? Maybe you want to see some <code>inline code</code> or some sample <kbd>input</kbd>. Oh, also <small>small text</small> is cool, along with its siblings: the subscript<sub>hi!</sub> and the superscript<sup>hello!</sup>. Finally, check out the horizontal rule, preformatted code block and quotation below.</p><hr>
<pre>function sum(num1, num2) {
var num3 = num1 + num2;
console.log('Result: ' + num3);
}</pre>
<blockquote cite="https://www.google.com">This is some quoted text from elsewhere.</blockquote><br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align: justify;">The most common HTML5 elements must be things like <code>&lt;p&gt;</code>aragraphs, bold (<code>&lt;strong&gt;</code>) &amp; italics (<code>&lt;em&gt;</code>) text, links (<code>&lt;a&gt;</code>), horizontal rules (<code>&lt;hr&gt;</code>) and <code>&lt;small&gt;</code> text. These, along with a few others, are styled by default using clean, modern design to make your pages look cool and stand out from the rest of the internet.</p>
<h3>Sample code</h3>
<pre>&lt;p&gt;This is a paragraph with some &lt;strong&gt;bold text&lt;/strong&gt; and some &lt;em&gt;italics text&lt;/em&gt;.&lt;/p&gt;
&lt;a href=&quot;#&quot;&gt;This is a link.&lt;/a&gt;
&lt;small&gt;This is some small text.&lt;/small&gt;
&lt;sub&gt;Subscript&lt;/sub&gt;
&lt;sup&gt;Superscript&lt;/sup&gt;
&lt;code&gt;Inline code&lt;/code&gt;
&lt;kbd&gt;Keyboard Input&lt;/kbd&gt;
&lt;hr&gt;
&lt;pre&gt;This is some preformatted text.&lt;/pre&gt;
&lt;blockquote cite=&quot;www.quotation.source&quot;&gt;
This is some quoted text from another website or person.
&lt;/blockquote&gt;</pre><br>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="lists">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Lists</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<div><br>
<ul>
<li>Apple</li>
<li>Orange</li>
<li>Strawberry</li>
</ul><br>
<ol>
<li>Wake up</li>
<li>Eat breakfast</li>
<li>Go to work</li>
</ol><br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align: justify;">Lists are also very commonly used in websites and apps. We tweaked a few margins and paddings to save some space and make them align properly with the rest of the common HTML elements that we use, but both unordered lists (<code>&lt;ul&gt;</code>) and ordered lists (<code>&lt;ol&gt;</code>) are minimally pre-styled to make things a little bit easier for you.</p>
<h3>Sample code</h3>
<pre>&lt;ul&gt;
&lt;li&gt;Apple&lt;/li&gt;
&lt;li&gt;Orange&lt;/li&gt;
&lt;li&gt;Strawberry&lt;/li&gt;
&lt;/ul&gt;
&lt;ol&gt;
&lt;li&gt;Wake up&lt;/li&gt;
&lt;li&gt;Eat breakfast&lt;/li&gt;
&lt;li&gt;Go to work&lt;/li&gt;
&lt;/ol&gt;</pre><br>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="images-captions">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Image responsiveness &amp; captions</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<div><figure><img src="https://placehold.it/800x600" alt="image"><figcaption>Image caption</figcaption></figure></div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align: justify;">Image elements (<code>&lt;img&gt;</code>) are responsive by default, without the need for any special classes or anything else. We made sure they will scale down as necessary to display properly on smaller devices, while keeping their original aspect ratio, but they will never scale up above their original size.</p> <p>On a side note, if you want to add captions to images, you can use a <code>&lt;figcaption&gt;</code> element, while wrapping both the image and it inside a <code>&lt;figure&gt;</code>.</p>
<h3>Sample code</h3>
<pre>&lt;figure&gt;
&lt;img src=&quot;...&quot;&gt;
&lt;figcaption&gt;Image caption&lt;/figcaption&gt;
&lt;/figure&gt;</pre><br>
</div>
</div>
</div>
</div>
</div>
<div class="row" style="padding-bottom: 20px; padding-top:20px;">
<div class="col-sm-12">
<p style="text-align: justify;">If you want to learn more about <strong>mini.css</strong>'s modules, go back to the <a href="modules">modules page</a> and choose another module to see its documentation.</p>
</div>
</div>
</main></div></div></div>
<footer style="text-align: justify;"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>

View file

@ -1,112 +1,112 @@
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<title>mini.css - Flavors</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, flavor, flavors ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-centered { text-align: center; } .box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;}
.box-colored.red { background: #e53935; } .box-centered > .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto;} [class^='col-'] .card.fluid { margin: 2px 0 20px; }
h2 > a{ font-size: 1rem; float: right;} .box-left { text-align: left; }
[class^='fore-'] { font-family: monospace, monospace;} .fore-primary { color: #0d47a1;} .fore-secondary { color: #b71c1c;} .fore-tertiary { color: #1b5e20;}
@media (max-width: 767px){.container {padding: 0.25rem !important;}.col-sm.col-lg-offset.col-lg-10{padding: 0 !important;}}
</style>
</head>
<body>
<header class="sticky">
<a href="index" class="logo"><span id="header-logo">m</span></a> <label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="index" class="button hidden-sm">Introduction</a> <a href="modules" class="button hidden-sm">Modules</a>
<a href="flavors" class="button hidden-sm">Flavors</a> <a href="templates" class="button hidden-sm">Templates</a>
<a href="customization" class="button hidden-sm">Customization</a> <a href="quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<input type="checkbox" id="navigation-toggle"> <nav class="drawer hidden-md hidden-lg">
<label class="close" for="navigation-toggle"></label>
<a href="index"><h4 style="margin-left: 0;">Introduction</h4></a> <a href="modules"><h4 style="margin-left: 0;">Modules</h4></a>
<a href="flavors"><h4 style="margin-left: 0;">Flavors</h4></a> <a href="templates"><h4 style="margin-left: 0;">Templates</h4></a>
<a href="customization"><h4 style="margin-left: 0;">Customization</h4></a> <a href="quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<!-- Insert your page content here-->
<main><div class="container">
<div class="row" style="padding-top: 40px;">
<div class="col-sm col-lg-10 col-lg-offset-1">
<h1>Flavors</h1>
<p style="text-align:justify">One of the core ideas behind <strong>mini.css</strong> is its flavor system. A flavor is the final compiled stylesheet a website or web app uses. When you start using <strong>mini.css</strong>, you usually try out the default flavor, using one of the following references inside your HTML page's <code>&lt;head&gt;</code> tag:</p>
<pre>&lt;<span class="fore-tertiary">link</span> <span class="fore-secondary">rel</span>=<span class="fore-primary">&quot;stylesheet&quot;</span> <span class="fore-secondary">href</span>=<span class="fore-primary">&quot;https://gitcdn.link/repo/Chalarangelo/mini.css/master/dist/mini-default.min.css&quot;</span>&gt;</pre>
<pre>&lt;<span class="fore-tertiary">link</span> <span class="fore-secondary">rel</span>=<span class="fore-primary">&quot;stylesheet&quot;</span> <span class="fore-secondary">href</span>=<span class="fore-primary">&quot;https://cdn.rawgit.com/Chalarangelo/mini.css/v2.3.4/dist/mini-default.min.css&quot;</span>&gt;</pre><br>
<p style="text-align:justify">There are, however a handful of other flavors included with <strong>mini.css</strong>. Below, you can see a full list of them:</p><br>
<ul style="margin-left:0px; padding-left: 4px">
<li class="card fluid">
<h2 class="section double-padded">Default <small>mini-default</small></h2>
<pre class="section double-padded" style="border-left:0; box-shadow: none;">&lt;<span class="fore-tertiary">link</span> <span class="fore-secondary">rel</span>=<span class="fore-primary">&quot;stylesheet&quot;</span> <span class="fore-secondary">href</span>=<span class="fore-primary">&quot;https://gitcdn.link/repo/Chalarangelo/mini.css/master/dist/mini-default.min.css&quot;</span>&gt;</pre>
<p class="section double-padded" style="text-align:justify">The default flavor for <strong>mini.css</strong> uses a light gray background and gray-black foreground color. Certain containers, such as cards and tabs use white-gray backgrounds. The grid system has 12 columns and most of the components and modules use sharp corners and light border colors. All of the colors used in this flavor are loosely based on <a href="https://material.google.com/style/color">Google's Material design color palette</a>.</p>
<div class="section double-padded">
<p><strong>Author:</strong> <a href="https://github.com/Chalarangelo">Chalarangelo</a></p>
<p><strong>Size:</strong> 7 KB</p>
</div>
</li>
<li class="card fluid">
<h2 class="section double-padded">Dark <a href="http://codepen.io/chalarangelo/pen/mmWrZz" target="_blank" class="button small"><i class="fa fa-codepen" aria-hidden="true"></i>&nbsp;View on Codepen</a><small>mini-dark</small></h2>
<pre class="section double-padded" style="border-left:0; box-shadow: none;">&lt;<span class="fore-tertiary">link</span> <span class="fore-secondary">rel</span>=<span class="fore-primary">&quot;stylesheet&quot;</span> <span class="fore-secondary">href</span>=<span class="fore-primary">&quot;https://gitcdn.link/repo/Chalarangelo/mini.css/master/dist/mini-dark.min.css&quot;</span>&gt;</pre>
<p class="section double-padded" style="text-align:justify">The dark version of the default flavor, Dark uses a dark gray background with light gray foreground color. All modules are the same as in the default flavor, but with a dark palette, loosely based on <a href="https://material.google.com/style/color">Google's Material design color palette</a>.</p>
<div class="section double-padded">
<p><strong>Author:</strong> <a href="https://github.com/Chalarangelo">Chalarangelo</a></p>
<p><strong>Size:</strong> 7 KB</p>
</div>
</li>
<li class="card fluid">
<h2 class="section double-padded">Lite <a href="http://codepen.io/chalarangelo/pen/bWVrMv" target="_blank" class="button small"><i class="fa fa-codepen" aria-hidden="true"></i>&nbsp;View on Codepen</a><small>mini-lite</small></h2>
<pre class="section double-padded" style="border-left:0; box-shadow: none;">&lt;<span class="fore-tertiary">link</span> <span class="fore-secondary">rel</span>=<span class="fore-primary">&quot;stylesheet&quot;</span> <span class="fore-secondary">href</span>=<span class="fore-primary">&quot;https://gitcdn.link/repo/Chalarangelo/mini.css/master/dist/mini-lite.min.css&quot;</span>&gt;</pre>
<p class="section double-padded" style="text-align:justify">Lite is a light flavor that uses the default palette (light gray background and gray-black foreground color). It uses the default naming conventions (<code>.primary</code>, <code>.secondary</code> etc.). The grid system has 12 columns and most components use sharp corners without shadows. To make the flavor lighter, button groups, horizontal and vertical tables, certain card and progress styles, along with spinner donuts, tooltips, navigation bars, modals, drawers and toasts are not included.</p>
<div class="section double-padded">
<p><strong>Author:</strong> <a href="https://github.com/Chalarangelo">Chalarangelo</a></p>
<p><strong>Size:</strong> 5 KB</p>
</div>
</li>
<li class="card fluid">
<h2 class="section double-padded">Sucroa <a href="http://codepen.io/chalarangelo/pen/YNKYgz" target="_blank" class="button small"><i class="fa fa-codepen" aria-hidden="true"></i>&nbsp;View on Codepen</a><small>mini-sucroa</small></h2>
<pre class="section double-padded" style="border-left:0; box-shadow: none;">&lt;<span class="fore-tertiary">link</span> <span class="fore-secondary">rel</span>=<span class="fore-primary">&quot;stylesheet&quot;</span> <span class="fore-secondary">href</span>=<span class="fore-primary">&quot;https://gitcdn.link/repo/Chalarangelo/mini.css/master/dist/mini-sucroa.min.css&quot;</span>&gt;</pre>
<p class="section double-padded" style="text-align:justify">Sucroa is a full flavor that uses a yellow-pink-lilac background color palette with dark purple-black foreground colors. It uses the default naming conventions (<code>.primary</code>, <code>.secondary</code> etc.). The grid system has 12 columns and most components use soft shadows combined with rounded corners. The card module's <code>.dark</code> and <code>.darker</code> classes have been replaced by the <code>.light</code> and <code>.lighter</code> classes respectively. Finally, the <code>.shadowed</code> class is replaced by varying degrees of generic shadows (<code>.shadow-none</code>, <code>.shadow-small</code>, <code>.shadow-medium</code> and <code>.shadow-large</code>).</p>
<div class="section double-padded">
<p><strong>Author:</strong> <a href="https://github.com/AngieDaskalakis">Angeliki Daskalakis</a></p>
<p><strong>Size:</strong> 7 KB (loads external fonts)</p>
</div>
</li>
<li class="card fluid">
<h2 class="section double-padded">Nord <a href="http://codepen.io/chalarangelo/pen/gWaxZX" target="_blank" class="button small"><i class="fa fa-codepen" aria-hidden="true"></i>&nbsp;View on Codepen</a><small>mini-nord</small></h2>
<pre class="section double-padded" style="border-left:0; box-shadow: none;">&lt;<span class="fore-tertiary">link</span> <span class="fore-secondary">rel</span>=<span class="fore-primary">&quot;stylesheet&quot;</span> <span class="fore-secondary">href</span>=<span class="fore-primary">&quot;https://gitcdn.link/repo/Chalarangelo/mini.css/master/dist/mini-nord.min.css&quot;</span>&gt;</pre>
<p class="section double-padded" style="text-align:justify">Nord is a full flavor that uses the <a href="https://github.com/arcticicestudio/nord">Nord color palette</a> (arctic, north-bluish color palette). It uses the default naming conventions (<code>.primary</code>, <code>.secondary</code> etc.). The grid system has 12 columns and most components use soft shadows combined with rounded corners. All modules and components that are available in the default flavor are also available in Nord. Finally, the <code>.shadowed</code> class is replaced by varying degrees of generic shadows (<code>.shadow-none</code>, <code>.shadow-small</code>, <code>.shadow-medium</code> and <code>.shadow-large</code>).</p>
<div class="section double-padded">
<p><strong>Author:</strong> <a href="https://github.com/tphecca">tphecca</a></p>
<p><strong>Size:</strong> 7 KB</p>
</div>
</li>
<li class="card fluid">
<h2 class="section double-padded">Progressive Web App <a href="http://codepen.io/chalarangelo/pen/KqEOjy" target="_blank" class="button small"><i class="fa fa-codepen" aria-hidden="true"></i>&nbsp;View on Codepen</a><small>mini-pwa</small></h2>
<pre class="section double-padded" style="border-left:0; box-shadow: none;">&lt;<span class="fore-tertiary">link</span> <span class="fore-secondary">rel</span>=<span class="fore-primary">&quot;stylesheet&quot;</span> <span class="fore-secondary">href</span>=<span class="fore-primary">&quot;https://gitcdn.link/repo/Chalarangelo/mini.css/master/dist/mini-pwa.min.css&quot;</span>&gt;</pre>
<p class="section double-padded" style="text-align:justify">The Progressive Web App flavor follows the <a href="https://material.io/">Google Material Design Guidelines</a> and targets mobile devices and especially those based on the Android operating system. It uses mostly the default naming conventions (<code>.primary</code> etc.). The grid system has 12 columns and most components use rounded corners with soft shadows. To make the flavor lighter, button groups, horizontal and vertical tables, certain card styles, the entirety of the progress and tab modules, along with tooltips, navigation bars, modals and most style variants are not included. Finally, the card module's <code>.dark</code> class has been replaced by the <code>.accent</code> class.</p>
<div class="section double-padded">
<p><strong>Author:</strong> <a href="https://github.com/Chalarangelo">Chalarangelo</a></p>
<p><strong>Size:</strong> 5 KB</p>
</div>
</li>
</ul>
<p style="text-align:justify">If you would rather modify one of the pre-defined flavors or create your own, check out our <a href="customization">customization</a> page for instructions.</p>
</div>
</div>
</div></main>
<!-- End of page content-->
<footer style="text-align:justify"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<title>mini.css - Flavors</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, flavor, flavors ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-centered { text-align: center; } .box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;}
.box-colored.red { background: #e53935; } .box-centered > .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto;} [class^='col-'] .card.fluid { margin: 2px 0 20px; }
h2 > a{ font-size: 1rem; float: right;} .box-left { text-align: left; }
[class^='fore-'] { font-family: monospace, monospace;} .fore-primary { color: #0d47a1;} .fore-secondary { color: #b71c1c;} .fore-tertiary { color: #1b5e20;}
@media (max-width: 767px){.container {padding: 0.25rem !important;}.col-sm.col-lg-offset.col-lg-10{padding: 0 !important;}}
</style>
</head>
<body>
<header class="sticky">
<a href="index" class="logo"><span id="header-logo">m</span></a> <label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="index" class="button hidden-sm">Introduction</a> <a href="modules" class="button hidden-sm">Modules</a>
<a href="flavors" class="button hidden-sm">Flavors</a> <a href="templates" class="button hidden-sm">Templates</a>
<a href="customization" class="button hidden-sm">Customization</a> <a href="quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<input type="checkbox" id="navigation-toggle"> <nav class="drawer hidden-md hidden-lg">
<label class="close" for="navigation-toggle"></label>
<a href="index"><h4 style="margin-left: 0;">Introduction</h4></a> <a href="modules"><h4 style="margin-left: 0;">Modules</h4></a>
<a href="flavors"><h4 style="margin-left: 0;">Flavors</h4></a> <a href="templates"><h4 style="margin-left: 0;">Templates</h4></a>
<a href="customization"><h4 style="margin-left: 0;">Customization</h4></a> <a href="quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<!-- Insert your page content here-->
<main><div class="container">
<div class="row" style="padding-top: 40px;">
<div class="col-sm col-lg-10 col-lg-offset-1">
<h1>Flavors</h1>
<p style="text-align:justify">One of the core ideas behind <strong>mini.css</strong> is its flavor system. A flavor is the final compiled stylesheet a website or web app uses. When you start using <strong>mini.css</strong>, you usually try out the default flavor, using one of the following references inside your HTML page's <code>&lt;head&gt;</code> tag:</p>
<pre>&lt;<span class="fore-tertiary">link</span> <span class="fore-secondary">rel</span>=<span class="fore-primary">&quot;stylesheet&quot;</span> <span class="fore-secondary">href</span>=<span class="fore-primary">&quot;https://gitcdn.link/repo/Chalarangelo/mini.css/master/dist/mini-default.min.css&quot;</span>&gt;</pre>
<pre>&lt;<span class="fore-tertiary">link</span> <span class="fore-secondary">rel</span>=<span class="fore-primary">&quot;stylesheet&quot;</span> <span class="fore-secondary">href</span>=<span class="fore-primary">&quot;https://cdn.rawgit.com/Chalarangelo/mini.css/v2.3.4/dist/mini-default.min.css&quot;</span>&gt;</pre><br>
<p style="text-align:justify">There are, however a handful of other flavors included with <strong>mini.css</strong>. Below, you can see a full list of them:</p><br>
<ul style="margin-left:0px; padding-left: 4px">
<li class="card fluid">
<h2 class="section double-padded">Default <small>mini-default</small></h2>
<pre class="section double-padded" style="border-left:0; box-shadow: none;">&lt;<span class="fore-tertiary">link</span> <span class="fore-secondary">rel</span>=<span class="fore-primary">&quot;stylesheet&quot;</span> <span class="fore-secondary">href</span>=<span class="fore-primary">&quot;https://gitcdn.link/repo/Chalarangelo/mini.css/master/dist/mini-default.min.css&quot;</span>&gt;</pre>
<p class="section double-padded" style="text-align:justify">The default flavor for <strong>mini.css</strong> uses a light gray background and gray-black foreground color. Certain containers, such as cards and tabs use white-gray backgrounds. The grid system has 12 columns and most of the components and modules use sharp corners and light border colors. All of the colors used in this flavor are loosely based on <a href="https://material.google.com/style/color">Google's Material design color palette</a>.</p>
<div class="section double-padded">
<p><strong>Author:</strong> <a href="https://github.com/Chalarangelo">Chalarangelo</a></p>
<p><strong>Size:</strong> 7 KB</p>
</div>
</li>
<li class="card fluid">
<h2 class="section double-padded">Dark <a href="http://codepen.io/chalarangelo/pen/mmWrZz" target="_blank" class="button small"><i class="fa fa-codepen" aria-hidden="true"></i>&nbsp;View on Codepen</a><small>mini-dark</small></h2>
<pre class="section double-padded" style="border-left:0; box-shadow: none;">&lt;<span class="fore-tertiary">link</span> <span class="fore-secondary">rel</span>=<span class="fore-primary">&quot;stylesheet&quot;</span> <span class="fore-secondary">href</span>=<span class="fore-primary">&quot;https://gitcdn.link/repo/Chalarangelo/mini.css/master/dist/mini-dark.min.css&quot;</span>&gt;</pre>
<p class="section double-padded" style="text-align:justify">The dark version of the default flavor, Dark uses a dark gray background with light gray foreground color. All modules are the same as in the default flavor, but with a dark palette, loosely based on <a href="https://material.google.com/style/color">Google's Material design color palette</a>.</p>
<div class="section double-padded">
<p><strong>Author:</strong> <a href="https://github.com/Chalarangelo">Chalarangelo</a></p>
<p><strong>Size:</strong> 7 KB</p>
</div>
</li>
<li class="card fluid">
<h2 class="section double-padded">Lite <a href="http://codepen.io/chalarangelo/pen/bWVrMv" target="_blank" class="button small"><i class="fa fa-codepen" aria-hidden="true"></i>&nbsp;View on Codepen</a><small>mini-lite</small></h2>
<pre class="section double-padded" style="border-left:0; box-shadow: none;">&lt;<span class="fore-tertiary">link</span> <span class="fore-secondary">rel</span>=<span class="fore-primary">&quot;stylesheet&quot;</span> <span class="fore-secondary">href</span>=<span class="fore-primary">&quot;https://gitcdn.link/repo/Chalarangelo/mini.css/master/dist/mini-lite.min.css&quot;</span>&gt;</pre>
<p class="section double-padded" style="text-align:justify">Lite is a light flavor that uses the default palette (light gray background and gray-black foreground color). It uses the default naming conventions (<code>.primary</code>, <code>.secondary</code> etc.). The grid system has 12 columns and most components use sharp corners without shadows. To make the flavor lighter, button groups, horizontal and vertical tables, certain card and progress styles, along with spinner donuts, tooltips, navigation bars, modals, drawers and toasts are not included.</p>
<div class="section double-padded">
<p><strong>Author:</strong> <a href="https://github.com/Chalarangelo">Chalarangelo</a></p>
<p><strong>Size:</strong> 5 KB</p>
</div>
</li>
<li class="card fluid">
<h2 class="section double-padded">Sucroa <a href="http://codepen.io/chalarangelo/pen/YNKYgz" target="_blank" class="button small"><i class="fa fa-codepen" aria-hidden="true"></i>&nbsp;View on Codepen</a><small>mini-sucroa</small></h2>
<pre class="section double-padded" style="border-left:0; box-shadow: none;">&lt;<span class="fore-tertiary">link</span> <span class="fore-secondary">rel</span>=<span class="fore-primary">&quot;stylesheet&quot;</span> <span class="fore-secondary">href</span>=<span class="fore-primary">&quot;https://gitcdn.link/repo/Chalarangelo/mini.css/master/dist/mini-sucroa.min.css&quot;</span>&gt;</pre>
<p class="section double-padded" style="text-align:justify">Sucroa is a full flavor that uses a yellow-pink-lilac background color palette with dark purple-black foreground colors. It uses the default naming conventions (<code>.primary</code>, <code>.secondary</code> etc.). The grid system has 12 columns and most components use soft shadows combined with rounded corners. The card module's <code>.dark</code> and <code>.darker</code> classes have been replaced by the <code>.light</code> and <code>.lighter</code> classes respectively. Finally, the <code>.shadowed</code> class is replaced by varying degrees of generic shadows (<code>.shadow-none</code>, <code>.shadow-small</code>, <code>.shadow-medium</code> and <code>.shadow-large</code>).</p>
<div class="section double-padded">
<p><strong>Author:</strong> <a href="https://github.com/AngieDaskalakis">Angeliki Daskalakis</a></p>
<p><strong>Size:</strong> 7 KB (loads external fonts)</p>
</div>
</li>
<li class="card fluid">
<h2 class="section double-padded">Nord <a href="http://codepen.io/chalarangelo/pen/gWaxZX" target="_blank" class="button small"><i class="fa fa-codepen" aria-hidden="true"></i>&nbsp;View on Codepen</a><small>mini-nord</small></h2>
<pre class="section double-padded" style="border-left:0; box-shadow: none;">&lt;<span class="fore-tertiary">link</span> <span class="fore-secondary">rel</span>=<span class="fore-primary">&quot;stylesheet&quot;</span> <span class="fore-secondary">href</span>=<span class="fore-primary">&quot;https://gitcdn.link/repo/Chalarangelo/mini.css/master/dist/mini-nord.min.css&quot;</span>&gt;</pre>
<p class="section double-padded" style="text-align:justify">Nord is a full flavor that uses the <a href="https://github.com/arcticicestudio/nord">Nord color palette</a> (arctic, north-bluish color palette). It uses the default naming conventions (<code>.primary</code>, <code>.secondary</code> etc.). The grid system has 12 columns and most components use soft shadows combined with rounded corners. All modules and components that are available in the default flavor are also available in Nord. Finally, the <code>.shadowed</code> class is replaced by varying degrees of generic shadows (<code>.shadow-none</code>, <code>.shadow-small</code>, <code>.shadow-medium</code> and <code>.shadow-large</code>).</p>
<div class="section double-padded">
<p><strong>Author:</strong> <a href="https://github.com/tphecca">tphecca</a></p>
<p><strong>Size:</strong> 7 KB</p>
</div>
</li>
<li class="card fluid">
<h2 class="section double-padded">Progressive Web App <a href="http://codepen.io/chalarangelo/pen/KqEOjy" target="_blank" class="button small"><i class="fa fa-codepen" aria-hidden="true"></i>&nbsp;View on Codepen</a><small>mini-pwa</small></h2>
<pre class="section double-padded" style="border-left:0; box-shadow: none;">&lt;<span class="fore-tertiary">link</span> <span class="fore-secondary">rel</span>=<span class="fore-primary">&quot;stylesheet&quot;</span> <span class="fore-secondary">href</span>=<span class="fore-primary">&quot;https://gitcdn.link/repo/Chalarangelo/mini.css/master/dist/mini-pwa.min.css&quot;</span>&gt;</pre>
<p class="section double-padded" style="text-align:justify">The Progressive Web App flavor follows the <a href="https://material.io/">Google Material Design Guidelines</a> and targets mobile devices and especially those based on the Android operating system. It uses mostly the default naming conventions (<code>.primary</code> etc.). The grid system has 12 columns and most components use rounded corners with soft shadows. To make the flavor lighter, button groups, horizontal and vertical tables, certain card styles, the entirety of the progress and tab modules, along with tooltips, navigation bars, modals and most style variants are not included. Finally, the card module's <code>.dark</code> class has been replaced by the <code>.accent</code> class.</p>
<div class="section double-padded">
<p><strong>Author:</strong> <a href="https://github.com/Chalarangelo">Chalarangelo</a></p>
<p><strong>Size:</strong> 5 KB</p>
</div>
</li>
</ul>
<p style="text-align:justify">If you would rather modify one of the pre-defined flavors or create your own, check out our <a href="customization">customization</a> page for instructions.</p>
</div>
</div>
</div></main>
<!-- End of page content-->
<footer style="text-align:justify"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>

File diff suppressed because it is too large Load diff

View file

@ -1,54 +1,54 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- Generator: Adobe Illustrator 19.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 512 512" style="enable-background:new 0 0 512 512;" xml:space="preserve">
<path style="fill:#F74D37;" d="M355.501,245.374L213.124,387.75c-24.541,24.542-64.333,24.542-88.874,0s-24.542-64.332,0-88.874
l142.376-142.376l-72.064-72.064L48.257,230.741c-64.342,64.342-64.342,168.661,0,233.002s168.661,64.342,233.002,0l146.306-146.306
L355.501,245.374z"/>
<path style="fill:#C43D2C;" d="M48.256,463.744l75.994-75.994c24.541,24.542,64.333,24.542,88.874,0L355.5,245.374l72.064,72.064
L281.259,463.743C216.916,528.086,112.598,528.086,48.256,463.744z"/>
<g>
<rect x="276.246" y="33.588" transform="matrix(-0.7071 -0.7071 0.7071 -0.7071 447.431 311.1306)" style="fill:#F9D026;" width="23.813" height="58.623"/>
<rect x="230.5" style="fill:#F9D026;" width="23.815" height="58.624"/>
<rect x="292.441" y="96.746" style="fill:#F9D026;" width="58.624" height="23.815"/>
</g>
<g>
<rect x="437.184" y="194.529" transform="matrix(-0.7071 -0.7071 0.7071 -0.7071 608.3666 699.6761)" style="fill:#E7C224;" width="23.813" height="58.623"/>
<rect x="391.446" y="160.935" style="fill:#E7C224;" width="23.815" height="58.624"/>
<rect x="453.376" y="257.681" style="fill:#E7C224;" width="58.624" height="23.815"/>
</g>
<rect x="314.661" y="270.675" transform="matrix(-0.7071 -0.7071 0.7071 -0.7071 406.8443 783.1379)" style="fill:#B7B9C0;" width="101.909" height="73.266"/>
<rect x="153.734" y="109.741" transform="matrix(0.7071 0.7071 -0.7071 0.7071 163.4544 -101.8644)" style="fill:#D8D9DD;" width="101.909" height="73.266"/>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
</svg>
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- Generator: Adobe Illustrator 19.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 512 512" style="enable-background:new 0 0 512 512;" xml:space="preserve">
<path style="fill:#F74D37;" d="M355.501,245.374L213.124,387.75c-24.541,24.542-64.333,24.542-88.874,0s-24.542-64.332,0-88.874
l142.376-142.376l-72.064-72.064L48.257,230.741c-64.342,64.342-64.342,168.661,0,233.002s168.661,64.342,233.002,0l146.306-146.306
L355.501,245.374z"/>
<path style="fill:#C43D2C;" d="M48.256,463.744l75.994-75.994c24.541,24.542,64.333,24.542,88.874,0L355.5,245.374l72.064,72.064
L281.259,463.743C216.916,528.086,112.598,528.086,48.256,463.744z"/>
<g>
<rect x="276.246" y="33.588" transform="matrix(-0.7071 -0.7071 0.7071 -0.7071 447.431 311.1306)" style="fill:#F9D026;" width="23.813" height="58.623"/>
<rect x="230.5" style="fill:#F9D026;" width="23.815" height="58.624"/>
<rect x="292.441" y="96.746" style="fill:#F9D026;" width="58.624" height="23.815"/>
</g>
<g>
<rect x="437.184" y="194.529" transform="matrix(-0.7071 -0.7071 0.7071 -0.7071 608.3666 699.6761)" style="fill:#E7C224;" width="23.813" height="58.623"/>
<rect x="391.446" y="160.935" style="fill:#E7C224;" width="23.815" height="58.624"/>
<rect x="453.376" y="257.681" style="fill:#E7C224;" width="58.624" height="23.815"/>
</g>
<rect x="314.661" y="270.675" transform="matrix(-0.7071 -0.7071 0.7071 -0.7071 406.8443 783.1379)" style="fill:#B7B9C0;" width="101.909" height="73.266"/>
<rect x="153.734" y="109.741" transform="matrix(0.7071 0.7071 -0.7071 0.7071 163.4544 -101.8644)" style="fill:#D8D9DD;" width="101.909" height="73.266"/>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 1.9 KiB

After

Width:  |  Height:  |  Size: 1.9 KiB

View file

@ -1,74 +1,74 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- Generator: Adobe Illustrator 19.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 512 512" style="enable-background:new 0 0 512 512;" xml:space="preserve">
<path style="fill:#FCD999;" d="M378.203,260.162L378.203,260.162L250.74,132.725v-0.001c-17.489-5.419-36.035-8.434-55.258-8.635
v386.822c105.882-1.104,191.363-87.268,191.363-193.411C386.844,297.536,383.818,278.28,378.203,260.162z"/>
<path style="fill:#FEECCC;" d="M195.482,124.089c-0.683-0.011-1.377-0.011-2.059-0.011C86.596,124.078,0,210.674,0,317.5
C0,376.595,26.5,429.5,68.266,464.979l70.896,38.23c17.215,5.021,35.424,7.714,54.261,7.714c0.683,0,1.377,0,2.059-0.011
c87.029-1.343,157.23-87.415,157.23-193.411S282.51,125.432,195.482,124.089z"/>
<path style="fill:#FCD999;" d="M250.74,132.725c-42.26,12.611-73.074,51.769-73.074,98.131c0,56.554,45.847,102.4,102.4,102.4
c46.369,0,85.531-30.822,98.137-73.094C359.385,199.443,311.461,151.538,250.74,132.725z"/>
<path style="fill:#FBC566;" d="M114.369,419.911l14.302,79.906c3.447,1.229,6.952,2.355,10.49,3.391
c12.14-8.181,20.127-22.062,20.127-37.797C159.289,440.471,139.23,420.218,114.369,419.911z"/>
<g>
<path style="fill:#FCD999;" d="M136.533,465.411c0,13.733-3.049,26.066-7.862,34.406c-22.3-7.919-42.724-19.82-60.405-34.839
c0.25-24.951,20.526-45.079,45.511-45.079c0.193,0,0.387,0,0.592,0.011C126.669,420.537,136.533,440.676,136.533,465.411z"/>
<circle style="fill:#FCD999;" cx="73.956" cy="283.363" r="17.067"/>
</g>
<path style="fill:#FBC566;" d="M226.759,373.251v68.267c18.842,0,34.133-15.28,34.133-34.133
C260.892,388.531,245.601,373.251,226.759,373.251z"/>
<path style="fill:#FCD999;" d="M226.759,373.251c6.281,0,11.378,15.28,11.378,34.133c0,18.853-5.097,34.133-11.378,34.133
c-18.853,0-34.133-15.28-34.133-34.133C192.626,388.531,207.906,373.251,226.759,373.251z"/>
<g>
<circle style="fill:#F9B233;" cx="412.809" cy="33.746" r="8.533"/>
<circle style="fill:#F9B233;" cx="436.952" cy="9.61" r="8.533"/>
<path style="fill:#F9B233;" d="M404.769,138.335c-8.886,8.886-23.295,8.886-32.181,0c-8.886-8.886-8.886-23.295,0-32.181
l16.09-16.09c8.886-8.886,8.886-23.295,0-32.181s-23.295-8.886-32.181,0l-60.34,60.34l-39.261,89.465l55.352,55.352
L404.769,138.335z"/>
</g>
<path style="fill:#FA9647;" d="M505.335,69.95c-8.886-8.886-23.295-8.886-32.181,0L296.157,246.946l96.544-32.181l112.634-112.634
C514.222,93.244,514.222,78.836,505.335,69.95z"/>
<path style="fill:#FD5F6E;" d="M360.52,214.765v-32.181l-128.725,96.544c26.66,26.66,69.883,26.659,96.544,0l64.363-64.363H360.52z"
/>
<path style="fill:#FA9647;" d="M328.339,182.584v-32.182h-32.181v-32.181l-64.363,64.363c-26.659,26.659-26.659,69.883,0,96.544
c8.886,8.886,37.703-5.522,64.363-32.181l64.363-64.363H328.339z"/>
<path style="fill:#FEECCC;" d="M280.066,196.722l-11.378,34.133l11.378,34.133c18.852,0,34.133-15.282,34.133-34.133
S298.918,196.722,280.066,196.722z"/>
<path style="fill:#FFFFFF;" d="M245.933,230.856c0,18.852,15.283,34.133,34.133,34.133v-68.267
C261.216,196.722,245.933,212.004,245.933,230.856z"/>
<g>
<circle style="fill:#FCD999;" cx="108.089" cy="232.163" r="8.533"/>
<circle style="fill:#FCD999;" cx="295.026" cy="407.381" r="8.533"/>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
</svg>
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- Generator: Adobe Illustrator 19.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 512 512" style="enable-background:new 0 0 512 512;" xml:space="preserve">
<path style="fill:#FCD999;" d="M378.203,260.162L378.203,260.162L250.74,132.725v-0.001c-17.489-5.419-36.035-8.434-55.258-8.635
v386.822c105.882-1.104,191.363-87.268,191.363-193.411C386.844,297.536,383.818,278.28,378.203,260.162z"/>
<path style="fill:#FEECCC;" d="M195.482,124.089c-0.683-0.011-1.377-0.011-2.059-0.011C86.596,124.078,0,210.674,0,317.5
C0,376.595,26.5,429.5,68.266,464.979l70.896,38.23c17.215,5.021,35.424,7.714,54.261,7.714c0.683,0,1.377,0,2.059-0.011
c87.029-1.343,157.23-87.415,157.23-193.411S282.51,125.432,195.482,124.089z"/>
<path style="fill:#FCD999;" d="M250.74,132.725c-42.26,12.611-73.074,51.769-73.074,98.131c0,56.554,45.847,102.4,102.4,102.4
c46.369,0,85.531-30.822,98.137-73.094C359.385,199.443,311.461,151.538,250.74,132.725z"/>
<path style="fill:#FBC566;" d="M114.369,419.911l14.302,79.906c3.447,1.229,6.952,2.355,10.49,3.391
c12.14-8.181,20.127-22.062,20.127-37.797C159.289,440.471,139.23,420.218,114.369,419.911z"/>
<g>
<path style="fill:#FCD999;" d="M136.533,465.411c0,13.733-3.049,26.066-7.862,34.406c-22.3-7.919-42.724-19.82-60.405-34.839
c0.25-24.951,20.526-45.079,45.511-45.079c0.193,0,0.387,0,0.592,0.011C126.669,420.537,136.533,440.676,136.533,465.411z"/>
<circle style="fill:#FCD999;" cx="73.956" cy="283.363" r="17.067"/>
</g>
<path style="fill:#FBC566;" d="M226.759,373.251v68.267c18.842,0,34.133-15.28,34.133-34.133
C260.892,388.531,245.601,373.251,226.759,373.251z"/>
<path style="fill:#FCD999;" d="M226.759,373.251c6.281,0,11.378,15.28,11.378,34.133c0,18.853-5.097,34.133-11.378,34.133
c-18.853,0-34.133-15.28-34.133-34.133C192.626,388.531,207.906,373.251,226.759,373.251z"/>
<g>
<circle style="fill:#F9B233;" cx="412.809" cy="33.746" r="8.533"/>
<circle style="fill:#F9B233;" cx="436.952" cy="9.61" r="8.533"/>
<path style="fill:#F9B233;" d="M404.769,138.335c-8.886,8.886-23.295,8.886-32.181,0c-8.886-8.886-8.886-23.295,0-32.181
l16.09-16.09c8.886-8.886,8.886-23.295,0-32.181s-23.295-8.886-32.181,0l-60.34,60.34l-39.261,89.465l55.352,55.352
L404.769,138.335z"/>
</g>
<path style="fill:#FA9647;" d="M505.335,69.95c-8.886-8.886-23.295-8.886-32.181,0L296.157,246.946l96.544-32.181l112.634-112.634
C514.222,93.244,514.222,78.836,505.335,69.95z"/>
<path style="fill:#FD5F6E;" d="M360.52,214.765v-32.181l-128.725,96.544c26.66,26.66,69.883,26.659,96.544,0l64.363-64.363H360.52z"
/>
<path style="fill:#FA9647;" d="M328.339,182.584v-32.182h-32.181v-32.181l-64.363,64.363c-26.659,26.659-26.659,69.883,0,96.544
c8.886,8.886,37.703-5.522,64.363-32.181l64.363-64.363H328.339z"/>
<path style="fill:#FEECCC;" d="M280.066,196.722l-11.378,34.133l11.378,34.133c18.852,0,34.133-15.282,34.133-34.133
S298.918,196.722,280.066,196.722z"/>
<path style="fill:#FFFFFF;" d="M245.933,230.856c0,18.852,15.283,34.133,34.133,34.133v-68.267
C261.216,196.722,245.933,212.004,245.933,230.856z"/>
<g>
<circle style="fill:#FCD999;" cx="108.089" cy="232.163" r="8.533"/>
<circle style="fill:#FCD999;" cx="295.026" cy="407.381" r="8.533"/>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 3.4 KiB

After

Width:  |  Height:  |  Size: 3.5 KiB

View file

@ -1,51 +1,51 @@
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- Generator: Adobe Illustrator 19.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 512 512" style="enable-background:new 0 0 512 512;" xml:space="preserve">
<path style="fill:#BBE095;" d="M486.935,146.104l-7.905,7.905l-144.751,23.714L394.063,70.51l92.873-45.444
C520.355,58.487,520.355,112.682,486.935,146.104z"/>
<path style="fill:#E0F4B4;" d="M486.935,25.065L334.278,177.722l23.714-144.751l7.905-7.905
C399.318-8.355,453.513-8.355,486.935,25.065z"/>
<polygon style="fill:#5EDAFF;" points="357.992,154.008 203.478,308.522 243.002,147.96 357.992,32.97 "/>
<polygon style="fill:#089AC6;" points="243.002,268.997 104.298,407.701 128.013,262.951 243.002,147.96 "/>
<path style="fill:#4B58E3;" d="M128.013,383.987l-68.32,68.32c0-80.897-8.157-112.88,25.224-146.261l43.096-43.096
C128.013,262.951,128.013,383.987,128.013,383.987z"/>
<polygon style="fill:#089AC6;" points="479.029,154.008 364.04,268.997 203.478,308.522 357.992,154.008 "/>
<polygon style="fill:#4B58E3;" points="364.04,268.997 249.049,383.987 104.298,407.701 243.002,268.997 "/>
<g>
<path style="fill:#693F9E;" d="M249.049,383.987l-43.096,43.096c-33.382,33.382-65.365,25.224-146.261,25.224l68.32-68.32H249.049z
"/>
<path style="fill:#693F9E;" d="M2.619,509.381c-3.492-3.492-3.492-9.154,0-12.648L456.897,42.457c3.492-3.492,9.156-3.492,12.648,0
c3.492,3.492,3.492,9.154,0,12.648L15.267,509.381C11.774,512.873,6.112,512.873,2.619,509.381z"/>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
</svg>
<?xml version="1.0" encoding="iso-8859-1"?>
<!-- Generator: Adobe Illustrator 19.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 512 512" style="enable-background:new 0 0 512 512;" xml:space="preserve">
<path style="fill:#BBE095;" d="M486.935,146.104l-7.905,7.905l-144.751,23.714L394.063,70.51l92.873-45.444
C520.355,58.487,520.355,112.682,486.935,146.104z"/>
<path style="fill:#E0F4B4;" d="M486.935,25.065L334.278,177.722l23.714-144.751l7.905-7.905
C399.318-8.355,453.513-8.355,486.935,25.065z"/>
<polygon style="fill:#5EDAFF;" points="357.992,154.008 203.478,308.522 243.002,147.96 357.992,32.97 "/>
<polygon style="fill:#089AC6;" points="243.002,268.997 104.298,407.701 128.013,262.951 243.002,147.96 "/>
<path style="fill:#4B58E3;" d="M128.013,383.987l-68.32,68.32c0-80.897-8.157-112.88,25.224-146.261l43.096-43.096
C128.013,262.951,128.013,383.987,128.013,383.987z"/>
<polygon style="fill:#089AC6;" points="479.029,154.008 364.04,268.997 203.478,308.522 357.992,154.008 "/>
<polygon style="fill:#4B58E3;" points="364.04,268.997 249.049,383.987 104.298,407.701 243.002,268.997 "/>
<g>
<path style="fill:#693F9E;" d="M249.049,383.987l-43.096,43.096c-33.382,33.382-65.365,25.224-146.261,25.224l68.32-68.32H249.049z
"/>
<path style="fill:#693F9E;" d="M2.619,509.381c-3.492-3.492-3.492-9.154,0-12.648L456.897,42.457c3.492-3.492,9.156-3.492,12.648,0
c3.492,3.492,3.492,9.154,0,12.648L15.267,509.381C11.774,512.873,6.112,512.873,2.619,509.381z"/>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
<g>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 1.7 KiB

After

Width:  |  Height:  |  Size: 1.8 KiB

File diff suppressed because it is too large Load diff

View file

@ -1,210 +1,210 @@
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<title>mini.css - Modules</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, modules">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-centered { text-align: center; } .box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;} .box-colored.red { background: #e53935; }
.box-centered .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto; } [class^='col-'] .box-left { text-align: left; } li a { text-decoration: none; } h2.section + div.section.box-left { height: 100%; }
@media screen and (min-width: 768px) { .drawer { margin-top: 4px;}}
</style>
</head>
<body>
<header class="sticky">
<a href="index" class="logo"><span id="header-logo">m</span></a>
<label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="index" class="button hidden-sm">Introduction</a> <a href="modules" class="button hidden-sm">Modules</a>
<a href="flavors" class="button hidden-sm">Flavors</a> <a href="templates" class="button hidden-sm">Templates</a>
<a href="customization" class="button hidden-sm">Customization</a> <a href="quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<div class="container" style="padding-left: 0.25rem;">
<div class="row"> <input type="checkbox" id="navigation-toggle"> <nav class="drawer col-md-4 col-lg-2">
<label class="close" for="navigation-toggle"></label>
<a href="index"><h4 style="margin-left: 0;">Introduction</h4></a>
<h4 style="margin-left: 0;">Modules</h4> <a href="core#core-title">Core</a>
<a href="core#typography" class="sublink-1">Typography</a> <a href="core#headings" class="sublink-1">Headings</a>
<a href="core#common-textual-elements" class="sublink-1">Common textual elements</a>
<a href="core#lists" class="sublink-1">Lists</a> <a href="core#images-captions" class="sublink-1">Image responsiveness &amp; captions</a>
<br/> <a href="grid#grid-title">Grid</a>
<a href="grid#basic-layout" class="sublink-1">Basic layout</a> <a href="grid#screen-specific-layout" class="sublink-1">Screen specific layouts</a>
<a href="grid#predefined-layout" class="sublink-1">Predefined layouts</a> <a href="grid#column-offset" class="sublink-1">Column offsets</a>
<a href="grid#column-reorder" class="sublink-1">Column reordering</a> <a href="grid#media-object" class="sublink-1">Media object pattern</a>
<br/> <a href="input_control#input-control-title">Input Control</a>
<a href="input_control#forms-input" class="sublink-1">Forms &amp; input</a> <a href="input_control#checkbox-radio" class="sublink-1">Checkboxes &amp; radio buttons</a> <a href="input_control#switches" class="sublink-1">Switches</a>
<a href="input_control#buttons" class="sublink-1">Buttons &amp; button groups</a> <a href="input_control#file-upload" class="sublink-1">File upload buttons</a>
<br/> <a href="navigation#navigation-title">Navigation</a>
<a href="navigation#header" class="sublink-1">Header</a> <a href="navigation#navigation-bar" class="sublink-1">Navigation bar</a> <a href="navigation#drawer" class="sublink-1">Drawer</a>
<a href="navigation#footer" class="sublink-1">Footer</a> <a href="navigation#sticky" class="sublink-1">Sticky headers &amp; footers</a>
<br/> <a href="table#table-title">Table</a>
<a href="table#syntax-responsiveness" class="sublink-1">Basic syntax &amp; responsiveness</a> <a href="table#scrollable-tables" class="sublink-1">Scrollable tables</a>
<a href="table#horizontal-tables" class="sublink-1">Horizontal tables</a> <a href="table#variants-matrices" class="sublink-1">Table variants &amp; matrices</a>
<br/> <a href="card#card-title">Card</a>
<a href="card#basic-syntax" class="sublink-1">Basic syntax</a> <a href="card#sections-media" class="sublink-1">Sections &amp; media</a>
<a href="card#sizing-fluidity" class="sublink-1">Card sizing &amp; fluidity</a> <a href="card#color-variants" class="sublink-1">Card color variants</a>
<br/> <a href="tab#tab-title">Tab</a>
<a href="tab#basic-syntax" class="sublink-1">Basic syntax</a> <a href="tab#stacked-tabs" class="sublink-1">Stacked tabs</a>
<br/> <a href="contextual#contextual-title">Contextual</a>
<a href="contextual#text-highlighting" class="sublink-1">Text highlighting</a> <a href="contextual#toasts" class="sublink-1">Toasts</a>
<a href="contextual#tooltips" class="sublink-1">Tooltips</a> <a href="contextual#modals" class="sublink-1">Modals</a>
<br/> <a href="progress#progress-title">Progress</a>
<a href="progress#basic-progress-bar" class="sublink-1">Basic progress bar</a> <a href="progress#progress-variants" class="sublink-1">Progress bar variants</a>
<a href="progress#donut-spinner" class="sublink-1">Donut spinner</a> <a href="progress#spinner-variants" class="sublink-1">Donut spinner variants</a>
<br/> <a href="utility#utility-title">Utility</a>
<a href="utility#visibility-helpers" class="sublink-1">Visibility helpers</a> <a href="utility#borders-shadows" class="sublink-1">Generic borders &amp; shadows</a>
<a href="utility#responsive-sizing" class="sublink-1">Responsive sizing &amp; spacing classes</a>
<a href="utility#responsive-visibility" class="sublink-1">Responsive visibility helpers</a> <a href="utility#breadcrumbs" class="sublink-1">Breadcrumbs</a>
<a href="utility#close-icon" class="sublink-1">Close icon</a>
<a href="flavors"><h4 style="margin-left: 0;">Flavors</h4></a>
<a href="templates"><h4 style="margin-left: 0;">Templates</h4></a>
<a href="customization"><h4 style="margin-left: 0;">Customization</h4></a>
<a href="quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<div class="col-sm-12 col-md-8 col-lg-10"><main>
<div class="row" style="padding-top: 40px;">
<div class="col-sm-12">
<h1>Modules</h1>
<p style="text-align: justify;"><strong>mini.css</strong> uses modules as its base building blocks. Each module contains one or more components that affect the same part of the user experience. Below you can see a quick overview of all the modules that compose <strong>mini.css</strong>.</p><br>
</div>
</div>
<div class="row box-centered">
<div class="col-sm-12 col-lg-6 row">
<div class="card fluid">
<h2 class="section"><mark class="primary"><i class="fa fa-font fa-fw" aria-hidden="true"></i></mark>&nbsp;Core</h2>
<div class="section box-left"><p style="text-align: justify;">The <strong>core</strong> module contains basic reset and fix rules, based on <a href="http://necolas.github.io/normalize.css/">Normalize.css</a> v5.0.0, along with lots of custom typography rules. Most textual HTML5 elements are styled by this module, so you can start writing your pages immediately without worrying about font families, weights, sizes, line heights, paddings and the like. More specifically, the <strong>core</strong> module contains:</p><ul>
<li><a href="core#typography" class="sublink-1">General typography rules</a></li>
<li><a href="core#headings" class="sublink-1">Styling for headings</a></li>
<li><a href="core#common-textual-elements" class="sublink-1">Styling for common textual elements</a></li>
<li><a href="core#lists" class="sublink-1">Styling for lists</a></li>
<li><a href="core#images-captions" class="sublink-1">Rules for image responsiveness and captions</a></li>
</ul></div><a href="core" class="button section">See more</a>
</div>
</div>
<div class="col-sm-12 col-lg-6 row">
<div class="card fluid">
<h2 class="section"><mark class="secondary"><i class="fa fa-th-large fa-fw" aria-hidden="true"></i></mark>&nbsp;Grid</h2>
<div class="section box-left"><p style="text-align: justify;">The <strong>grid</strong> module provides you with a modern, responsive grid system based on the Flexible Layout Module (commonly known as <em>flexbox</em>). The structure of the grid is simple and logical, allowing you to quickly build your pages from scratch. Setting the layout for a page is easy and will behave the way you want them to on mobile devices and smaller screens. More specifically, the <strong>grid</strong> module contains:</p><ul>
<li><a href="grid#basic-layout" class="sublink-1">Containers, rows and columns for layout</a></li>
<li><a href="grid#screen-specific-layout" class="sublink-1">Classes for defining screen-specific layouts</a></li>
<li><a href="grid#predefined-layout" class="sublink-1">Classes for predefined layouts</a></li>
<li><a href="grid#column-offset" class="sublink-1">Classes for content offsetting</a></li>
<li><a href="grid#column-reorder" class="sublink-1">Classes for content reordering</a></li>
<li><a href="grid#media-object" class="sublink-1">Layout examples for implementing the media object pattern</a></li>
</ul></div><a href="grid" class="button section">See more</a>
</div>
</div>
</div>
<div class="row box-centered">
<div class="col-sm-12 col-lg-6 row">
<div class="card fluid">
<h2 class="section"><mark class="tertiary"><i class="fa fa-keyboard-o fa-fw" aria-hidden="true"></i></mark>&nbsp;Input Control</h2>
<div class="section box-left"><p style="text-align: justify;">The <strong>input_control</strong> module contains rules that affect forms, input elements, buttons, checkboxes and radio buttons. All of these elements's styles are predefined, allowing you to create modern, responsive forms quickly. Layout alternatives are also provided if you want your forms to look a certain way. More specifically, the <strong>input_control</strong> module contains:</p><ul>
<li><a href="input_control#forms-input" class="sublink-1">Styling for forms and input elements</a></li>
<li><a href="input_control#checkbox-radio" class="sublink-1">Styling for checkboxes and radio buttons</a></li>
<li><a href="input_control#buttons" class="sublink-1">Styling and grouping classes for buttons</a></li>
<li><a href="input_control#switches" class="sublink-1">Classes for creating switches</a></li>
<li><a href="input_control#file-upload" class="sublink-1">Workarounds for styling file upload buttons</a></li>
</ul></div><a href="input_control" class="button section">See more</a>
</div>
</div>
<div class="col-sm-12 col-lg-6 row">
<div class="card fluid">
<h2 class="section"><mark class="primary"><i class="fa fa-compass fa-fw" aria-hidden="true"></i></mark>&nbsp;Navigation</h2>
<div class="section box-left"><p style="text-align: justify;">The <strong>navigation</strong> module seeks to remedy the problems of vertical and horizontal navigation design paradigms, by combining the two for a better presentational effect. HTML5 navigational elements are at the heart of the module, allowing you to quickly build your navigation menus. More specifically, the <strong>navigation</strong> module contains:</p><ul>
<li><a href="navigation#header" class="sublink-1">Styling for headers, logos and header links</a></li>
<li><a href="navigation#navigation-bar" class="sublink-1">Styling for navigation bars</a></li>
<li><a href="navigation#drawer" class="sublink-1">Classes for creating responsive drawers</a></li>
<li><a href="navigation#footer" class="sublink-1">Styling for footers</a></li>
<li><a href="navigation#sticky" class="sublink-1">Classes for making headers and footers sticky</a></li>
</ul></div><a href="navigation" class="button section">See more</a>
</div>
</div>
</div>
<div class="row box-centered">
<div class="col-sm-12 col-lg-6 row">
<div class="card fluid">
<h2 class="section"><mark class="primary"><i class="fa fa-table fa-fw" aria-hidden="true"></i></mark>&nbsp;Table</h2>
<div class="section box-left"><p style="text-align: justify;">The <strong>table</strong> module provides styling and responsiveness for tables. Simple rules and accessible design paradigms have been used to make creating tables quick and easy. Large tables will collapse to cards when on smaller devices or, if you don't want that, they can be locked into their default, desktop view. More specifically, the <strong>table</strong> module contains:</p><ul>
<li><a href="table#syntax-responsiveness" class="sublink-1">Styling for tables and built-in responsiveness</a></li>
<li><a href="table#scrollable-tables" class="sublink-1">Classes for creating scrollable tables</a></li>
<li><a href="table#horizontal-tables" class="sublink-1">Classes for creating horizontal tables</a></li>
<li><a href="table#variants-matrices" class="sublink-1">Classes for creating table variants and matrices</a></li>
</ul></div><a href="table" class="button section">See more</a>
</div>
</div>
<div class="col-sm-12 col-lg-6 row">
<div class="card fluid">
<h2 class="section"><mark class="secondary"><i class="fa fa-id-card-o fa-fw" aria-hidden="true"></i></mark>&nbsp;Card</h2>
<div class="section box-left"><p style="text-align: justify;">The <strong>card</strong> module provides you with modern, responsive, general-purpose containers for your page's contents. They are very easy to use and their structure is really simple and versatile. Layouts will respond to smaller screens, realigning the cards in a manner that makes your page mobile-friendly. More specifically, the <strong>card</strong> module contains:</p><ul>
<li><a href="card#basic-syntax" class="sublink-1">Classes for creating card-based layouts</a></li>
<li><a href="card#sections-media" class="sublink-1">Classes for creating card sections and adding media</a></li>
<li><a href="card#sizing-fluidity" class="sublink-1">Classes for creating card variants and making cards fluid</a></li>
<li><a href="card#color-variants" class="sublink-1">Classes for creating card color variants</a></li>
</ul></div><a href="card" class="button section">See more</a>
</div>
</div>
</div>
<div class="row box-centered">
<div class="col-sm-12 col-lg-6 row">
<div class="card fluid">
<h2 class="section"><mark class="secondary"><i class="fa fa-files-o fa-fw" aria-hidden="true"></i></mark>&nbsp;Tab</h2>
<div class="section box-left"><p style="text-align: justify;">The <strong>tab</strong> module aims to combine multiple components and design paradigms, like collapses, accordions, carousels and tabs, into one general-purpose component. Tabs are very simple in structure, responsive on mobile and they allow for layout customization so that you can turn them into accordions or collapses whenever you want. More specifically, the <strong>tab</strong> module contains:</p><ul>
<li><a href="tab#basic-syntax" class="sublink-1">Classes for creating tab-based layouts</a></li>
<li><a href="tab#stacked-tabs" class="sublink-1">Classes for creating stacked tabs, accordions and collapses</a></li>
</ul></div><a href="tab" class="button section">See more</a>
</div>
</div>
<div class="col-sm-12 col-lg-6 row">
<div class="card fluid">
<h2 class="section"><mark class="secondary"><i class="fa fa-tags fa-fw" aria-hidden="true"></i></mark>&nbsp;Contextual</h2>
<div class="section box-left"><p style="text-align: justify;">The <strong>contextual</strong> module provides you with simple tags, marks and highlights for your pages, allowing you to easily emphasize parts of your text. Contextual toasts, tooltips and modals are also provided, aiming to help deliver important information to users. HTML5 elements and simple rules are used in order to make important messages and pieces of content stand out easily. More specifically, the <strong>contextual</strong> module contains:</p><ul>
<li><a href="contextual#text-highlighting" class="sublink-1">Styling for highlighted text</a></li>
<li><a href="contextual#toasts" class="sublink-1">Classes for creating toast messages</a></li>
<li><a href="contextual#tooltips" class="sublink-1">Classes for creating hover-over tooltips</a></li>
<li><a href="contextual#modals" class="sublink-1">Classes for creating modal dialogs</a></li>
</ul></div><a href="contextual" class="button section">See more</a>
</div>
</div>
</div>
<div class="row box-centered" style="padding-bottom: 40px;">
<div class="col-sm-12 col-lg-6 row">
<div class="card fluid">
<h2 class="section"><mark class="tertiary"><i class="fa fa-spinner fa-fw" aria-hidden="true"></i></mark>&nbsp;Progress</h2>
<div class="section box-left"><p style="text-align: justify;">The <strong>progress</strong> module gives you full control over the presentation of progress and loading on your pages. Apart from progress bars and color variants for them, spinner elements are provided to help communicate that something is loading. More specifically, the <strong>progress</strong> module contains:</p><ul>
<li><a href="progress#basic-progress-bar" class="sublink-1">Styling for progress bars</a></li>
<li><a href="progress#progress-variants" class="sublink-1">Classes for creating progress bar variants</a></li>
<li><a href="progress#donut-spinner" class="sublink-1">Classes for creating donut spinners</a></li>
<li><a href="progress#spinner-variants" class="sublink-1">Classes for creating donut spinner variants</a></li>
</ul></div><a href="progress" class="button section">See more</a>
</div>
</div>
<div class="col-sm-12 col-lg-6 row">
<div class="card fluid">
<h2 class="section"><mark class="tertiary"><i class="fa fa-wrench fa-fw" aria-hidden="true"></i></mark>&nbsp;Utility</h2>
<div class="section box-left"><p style="text-align: justify;">The <strong>utility</strong> module contains all the utilities and helper classes that you might want when designing a website or application. They solve common design problems efficiently and provide you with generic rules you can easily apply everywhere. More specifically, the <strong>utility</strong> module contains:</p><ul>
<li><a href="utility#visibility-helpers" class="sublink-1">Visibility helpers for hiding elements</a></li>
<li><a href="utility#borders-shadows" class="sublink-1">Classes for creating generic borders and shadows</a></li>
<li><a href="utility#responsive-sizing" class="sublink-1">Classes for responsive sizing and spacing</a></li>
<li><a href="utility#responsive-visibility" class="sublink-1">Responsive visibility helpers for hiding elements</a></li>
<li><a href="utility#breadcrumbs" class="sublink-1">Classes for creating breadcrumbs</a></li>
<li><a href="utility#close-icon" class="sublink-1">Classes for creating close icons</a></li>
</ul></div><a href="utility" class="button section">See more</a>
</div>
</div>
</div>
</main></div></div></div>
<footer style="text-align: justify;"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<title>mini.css - Modules</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, modules">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-centered { text-align: center; } .box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;} .box-colored.red { background: #e53935; }
.box-centered .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto; } [class^='col-'] .box-left { text-align: left; } li a { text-decoration: none; } h2.section + div.section.box-left { height: 100%; }
@media screen and (min-width: 768px) { .drawer { margin-top: 4px;}}
</style>
</head>
<body>
<header class="sticky">
<a href="index" class="logo"><span id="header-logo">m</span></a>
<label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="index" class="button hidden-sm">Introduction</a> <a href="modules" class="button hidden-sm">Modules</a>
<a href="flavors" class="button hidden-sm">Flavors</a> <a href="templates" class="button hidden-sm">Templates</a>
<a href="customization" class="button hidden-sm">Customization</a> <a href="quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<div class="container" style="padding-left: 0.25rem;">
<div class="row"> <input type="checkbox" id="navigation-toggle"> <nav class="drawer col-md-4 col-lg-2">
<label class="close" for="navigation-toggle"></label>
<a href="index"><h4 style="margin-left: 0;">Introduction</h4></a>
<h4 style="margin-left: 0;">Modules</h4> <a href="core#core-title">Core</a>
<a href="core#typography" class="sublink-1">Typography</a> <a href="core#headings" class="sublink-1">Headings</a>
<a href="core#common-textual-elements" class="sublink-1">Common textual elements</a>
<a href="core#lists" class="sublink-1">Lists</a> <a href="core#images-captions" class="sublink-1">Image responsiveness &amp; captions</a>
<br/> <a href="grid#grid-title">Grid</a>
<a href="grid#basic-layout" class="sublink-1">Basic layout</a> <a href="grid#screen-specific-layout" class="sublink-1">Screen specific layouts</a>
<a href="grid#predefined-layout" class="sublink-1">Predefined layouts</a> <a href="grid#column-offset" class="sublink-1">Column offsets</a>
<a href="grid#column-reorder" class="sublink-1">Column reordering</a> <a href="grid#media-object" class="sublink-1">Media object pattern</a>
<br/> <a href="input_control#input-control-title">Input Control</a>
<a href="input_control#forms-input" class="sublink-1">Forms &amp; input</a> <a href="input_control#checkbox-radio" class="sublink-1">Checkboxes &amp; radio buttons</a> <a href="input_control#switches" class="sublink-1">Switches</a>
<a href="input_control#buttons" class="sublink-1">Buttons &amp; button groups</a> <a href="input_control#file-upload" class="sublink-1">File upload buttons</a>
<br/> <a href="navigation#navigation-title">Navigation</a>
<a href="navigation#header" class="sublink-1">Header</a> <a href="navigation#navigation-bar" class="sublink-1">Navigation bar</a> <a href="navigation#drawer" class="sublink-1">Drawer</a>
<a href="navigation#footer" class="sublink-1">Footer</a> <a href="navigation#sticky" class="sublink-1">Sticky headers &amp; footers</a>
<br/> <a href="table#table-title">Table</a>
<a href="table#syntax-responsiveness" class="sublink-1">Basic syntax &amp; responsiveness</a> <a href="table#scrollable-tables" class="sublink-1">Scrollable tables</a>
<a href="table#horizontal-tables" class="sublink-1">Horizontal tables</a> <a href="table#variants-matrices" class="sublink-1">Table variants &amp; matrices</a>
<br/> <a href="card#card-title">Card</a>
<a href="card#basic-syntax" class="sublink-1">Basic syntax</a> <a href="card#sections-media" class="sublink-1">Sections &amp; media</a>
<a href="card#sizing-fluidity" class="sublink-1">Card sizing &amp; fluidity</a> <a href="card#color-variants" class="sublink-1">Card color variants</a>
<br/> <a href="tab#tab-title">Tab</a>
<a href="tab#basic-syntax" class="sublink-1">Basic syntax</a> <a href="tab#stacked-tabs" class="sublink-1">Stacked tabs</a>
<br/> <a href="contextual#contextual-title">Contextual</a>
<a href="contextual#text-highlighting" class="sublink-1">Text highlighting</a> <a href="contextual#toasts" class="sublink-1">Toasts</a>
<a href="contextual#tooltips" class="sublink-1">Tooltips</a> <a href="contextual#modals" class="sublink-1">Modals</a>
<br/> <a href="progress#progress-title">Progress</a>
<a href="progress#basic-progress-bar" class="sublink-1">Basic progress bar</a> <a href="progress#progress-variants" class="sublink-1">Progress bar variants</a>
<a href="progress#donut-spinner" class="sublink-1">Donut spinner</a> <a href="progress#spinner-variants" class="sublink-1">Donut spinner variants</a>
<br/> <a href="utility#utility-title">Utility</a>
<a href="utility#visibility-helpers" class="sublink-1">Visibility helpers</a> <a href="utility#borders-shadows" class="sublink-1">Generic borders &amp; shadows</a>
<a href="utility#responsive-sizing" class="sublink-1">Responsive sizing &amp; spacing classes</a>
<a href="utility#responsive-visibility" class="sublink-1">Responsive visibility helpers</a> <a href="utility#breadcrumbs" class="sublink-1">Breadcrumbs</a>
<a href="utility#close-icon" class="sublink-1">Close icon</a>
<a href="flavors"><h4 style="margin-left: 0;">Flavors</h4></a>
<a href="templates"><h4 style="margin-left: 0;">Templates</h4></a>
<a href="customization"><h4 style="margin-left: 0;">Customization</h4></a>
<a href="quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<div class="col-sm-12 col-md-8 col-lg-10"><main>
<div class="row" style="padding-top: 40px;">
<div class="col-sm-12">
<h1>Modules</h1>
<p style="text-align: justify;"><strong>mini.css</strong> uses modules as its base building blocks. Each module contains one or more components that affect the same part of the user experience. Below you can see a quick overview of all the modules that compose <strong>mini.css</strong>.</p><br>
</div>
</div>
<div class="row box-centered">
<div class="col-sm-12 col-lg-6 row">
<div class="card fluid">
<h2 class="section"><mark class="primary"><i class="fa fa-font fa-fw" aria-hidden="true"></i></mark>&nbsp;Core</h2>
<div class="section box-left"><p style="text-align: justify;">The <strong>core</strong> module contains basic reset and fix rules, based on <a href="http://necolas.github.io/normalize.css/">Normalize.css</a> v5.0.0, along with lots of custom typography rules. Most textual HTML5 elements are styled by this module, so you can start writing your pages immediately without worrying about font families, weights, sizes, line heights, paddings and the like. More specifically, the <strong>core</strong> module contains:</p><ul>
<li><a href="core#typography" class="sublink-1">General typography rules</a></li>
<li><a href="core#headings" class="sublink-1">Styling for headings</a></li>
<li><a href="core#common-textual-elements" class="sublink-1">Styling for common textual elements</a></li>
<li><a href="core#lists" class="sublink-1">Styling for lists</a></li>
<li><a href="core#images-captions" class="sublink-1">Rules for image responsiveness and captions</a></li>
</ul></div><a href="core" class="button section">See more</a>
</div>
</div>
<div class="col-sm-12 col-lg-6 row">
<div class="card fluid">
<h2 class="section"><mark class="secondary"><i class="fa fa-th-large fa-fw" aria-hidden="true"></i></mark>&nbsp;Grid</h2>
<div class="section box-left"><p style="text-align: justify;">The <strong>grid</strong> module provides you with a modern, responsive grid system based on the Flexible Layout Module (commonly known as <em>flexbox</em>). The structure of the grid is simple and logical, allowing you to quickly build your pages from scratch. Setting the layout for a page is easy and will behave the way you want them to on mobile devices and smaller screens. More specifically, the <strong>grid</strong> module contains:</p><ul>
<li><a href="grid#basic-layout" class="sublink-1">Containers, rows and columns for layout</a></li>
<li><a href="grid#screen-specific-layout" class="sublink-1">Classes for defining screen-specific layouts</a></li>
<li><a href="grid#predefined-layout" class="sublink-1">Classes for predefined layouts</a></li>
<li><a href="grid#column-offset" class="sublink-1">Classes for content offsetting</a></li>
<li><a href="grid#column-reorder" class="sublink-1">Classes for content reordering</a></li>
<li><a href="grid#media-object" class="sublink-1">Layout examples for implementing the media object pattern</a></li>
</ul></div><a href="grid" class="button section">See more</a>
</div>
</div>
</div>
<div class="row box-centered">
<div class="col-sm-12 col-lg-6 row">
<div class="card fluid">
<h2 class="section"><mark class="tertiary"><i class="fa fa-keyboard-o fa-fw" aria-hidden="true"></i></mark>&nbsp;Input Control</h2>
<div class="section box-left"><p style="text-align: justify;">The <strong>input_control</strong> module contains rules that affect forms, input elements, buttons, checkboxes and radio buttons. All of these elements's styles are predefined, allowing you to create modern, responsive forms quickly. Layout alternatives are also provided if you want your forms to look a certain way. More specifically, the <strong>input_control</strong> module contains:</p><ul>
<li><a href="input_control#forms-input" class="sublink-1">Styling for forms and input elements</a></li>
<li><a href="input_control#checkbox-radio" class="sublink-1">Styling for checkboxes and radio buttons</a></li>
<li><a href="input_control#buttons" class="sublink-1">Styling and grouping classes for buttons</a></li>
<li><a href="input_control#switches" class="sublink-1">Classes for creating switches</a></li>
<li><a href="input_control#file-upload" class="sublink-1">Workarounds for styling file upload buttons</a></li>
</ul></div><a href="input_control" class="button section">See more</a>
</div>
</div>
<div class="col-sm-12 col-lg-6 row">
<div class="card fluid">
<h2 class="section"><mark class="primary"><i class="fa fa-compass fa-fw" aria-hidden="true"></i></mark>&nbsp;Navigation</h2>
<div class="section box-left"><p style="text-align: justify;">The <strong>navigation</strong> module seeks to remedy the problems of vertical and horizontal navigation design paradigms, by combining the two for a better presentational effect. HTML5 navigational elements are at the heart of the module, allowing you to quickly build your navigation menus. More specifically, the <strong>navigation</strong> module contains:</p><ul>
<li><a href="navigation#header" class="sublink-1">Styling for headers, logos and header links</a></li>
<li><a href="navigation#navigation-bar" class="sublink-1">Styling for navigation bars</a></li>
<li><a href="navigation#drawer" class="sublink-1">Classes for creating responsive drawers</a></li>
<li><a href="navigation#footer" class="sublink-1">Styling for footers</a></li>
<li><a href="navigation#sticky" class="sublink-1">Classes for making headers and footers sticky</a></li>
</ul></div><a href="navigation" class="button section">See more</a>
</div>
</div>
</div>
<div class="row box-centered">
<div class="col-sm-12 col-lg-6 row">
<div class="card fluid">
<h2 class="section"><mark class="primary"><i class="fa fa-table fa-fw" aria-hidden="true"></i></mark>&nbsp;Table</h2>
<div class="section box-left"><p style="text-align: justify;">The <strong>table</strong> module provides styling and responsiveness for tables. Simple rules and accessible design paradigms have been used to make creating tables quick and easy. Large tables will collapse to cards when on smaller devices or, if you don't want that, they can be locked into their default, desktop view. More specifically, the <strong>table</strong> module contains:</p><ul>
<li><a href="table#syntax-responsiveness" class="sublink-1">Styling for tables and built-in responsiveness</a></li>
<li><a href="table#scrollable-tables" class="sublink-1">Classes for creating scrollable tables</a></li>
<li><a href="table#horizontal-tables" class="sublink-1">Classes for creating horizontal tables</a></li>
<li><a href="table#variants-matrices" class="sublink-1">Classes for creating table variants and matrices</a></li>
</ul></div><a href="table" class="button section">See more</a>
</div>
</div>
<div class="col-sm-12 col-lg-6 row">
<div class="card fluid">
<h2 class="section"><mark class="secondary"><i class="fa fa-id-card-o fa-fw" aria-hidden="true"></i></mark>&nbsp;Card</h2>
<div class="section box-left"><p style="text-align: justify;">The <strong>card</strong> module provides you with modern, responsive, general-purpose containers for your page's contents. They are very easy to use and their structure is really simple and versatile. Layouts will respond to smaller screens, realigning the cards in a manner that makes your page mobile-friendly. More specifically, the <strong>card</strong> module contains:</p><ul>
<li><a href="card#basic-syntax" class="sublink-1">Classes for creating card-based layouts</a></li>
<li><a href="card#sections-media" class="sublink-1">Classes for creating card sections and adding media</a></li>
<li><a href="card#sizing-fluidity" class="sublink-1">Classes for creating card variants and making cards fluid</a></li>
<li><a href="card#color-variants" class="sublink-1">Classes for creating card color variants</a></li>
</ul></div><a href="card" class="button section">See more</a>
</div>
</div>
</div>
<div class="row box-centered">
<div class="col-sm-12 col-lg-6 row">
<div class="card fluid">
<h2 class="section"><mark class="secondary"><i class="fa fa-files-o fa-fw" aria-hidden="true"></i></mark>&nbsp;Tab</h2>
<div class="section box-left"><p style="text-align: justify;">The <strong>tab</strong> module aims to combine multiple components and design paradigms, like collapses, accordions, carousels and tabs, into one general-purpose component. Tabs are very simple in structure, responsive on mobile and they allow for layout customization so that you can turn them into accordions or collapses whenever you want. More specifically, the <strong>tab</strong> module contains:</p><ul>
<li><a href="tab#basic-syntax" class="sublink-1">Classes for creating tab-based layouts</a></li>
<li><a href="tab#stacked-tabs" class="sublink-1">Classes for creating stacked tabs, accordions and collapses</a></li>
</ul></div><a href="tab" class="button section">See more</a>
</div>
</div>
<div class="col-sm-12 col-lg-6 row">
<div class="card fluid">
<h2 class="section"><mark class="secondary"><i class="fa fa-tags fa-fw" aria-hidden="true"></i></mark>&nbsp;Contextual</h2>
<div class="section box-left"><p style="text-align: justify;">The <strong>contextual</strong> module provides you with simple tags, marks and highlights for your pages, allowing you to easily emphasize parts of your text. Contextual toasts, tooltips and modals are also provided, aiming to help deliver important information to users. HTML5 elements and simple rules are used in order to make important messages and pieces of content stand out easily. More specifically, the <strong>contextual</strong> module contains:</p><ul>
<li><a href="contextual#text-highlighting" class="sublink-1">Styling for highlighted text</a></li>
<li><a href="contextual#toasts" class="sublink-1">Classes for creating toast messages</a></li>
<li><a href="contextual#tooltips" class="sublink-1">Classes for creating hover-over tooltips</a></li>
<li><a href="contextual#modals" class="sublink-1">Classes for creating modal dialogs</a></li>
</ul></div><a href="contextual" class="button section">See more</a>
</div>
</div>
</div>
<div class="row box-centered" style="padding-bottom: 40px;">
<div class="col-sm-12 col-lg-6 row">
<div class="card fluid">
<h2 class="section"><mark class="tertiary"><i class="fa fa-spinner fa-fw" aria-hidden="true"></i></mark>&nbsp;Progress</h2>
<div class="section box-left"><p style="text-align: justify;">The <strong>progress</strong> module gives you full control over the presentation of progress and loading on your pages. Apart from progress bars and color variants for them, spinner elements are provided to help communicate that something is loading. More specifically, the <strong>progress</strong> module contains:</p><ul>
<li><a href="progress#basic-progress-bar" class="sublink-1">Styling for progress bars</a></li>
<li><a href="progress#progress-variants" class="sublink-1">Classes for creating progress bar variants</a></li>
<li><a href="progress#donut-spinner" class="sublink-1">Classes for creating donut spinners</a></li>
<li><a href="progress#spinner-variants" class="sublink-1">Classes for creating donut spinner variants</a></li>
</ul></div><a href="progress" class="button section">See more</a>
</div>
</div>
<div class="col-sm-12 col-lg-6 row">
<div class="card fluid">
<h2 class="section"><mark class="tertiary"><i class="fa fa-wrench fa-fw" aria-hidden="true"></i></mark>&nbsp;Utility</h2>
<div class="section box-left"><p style="text-align: justify;">The <strong>utility</strong> module contains all the utilities and helper classes that you might want when designing a website or application. They solve common design problems efficiently and provide you with generic rules you can easily apply everywhere. More specifically, the <strong>utility</strong> module contains:</p><ul>
<li><a href="utility#visibility-helpers" class="sublink-1">Visibility helpers for hiding elements</a></li>
<li><a href="utility#borders-shadows" class="sublink-1">Classes for creating generic borders and shadows</a></li>
<li><a href="utility#responsive-sizing" class="sublink-1">Classes for responsive sizing and spacing</a></li>
<li><a href="utility#responsive-visibility" class="sublink-1">Responsive visibility helpers for hiding elements</a></li>
<li><a href="utility#breadcrumbs" class="sublink-1">Classes for creating breadcrumbs</a></li>
<li><a href="utility#close-icon" class="sublink-1">Classes for creating close icons</a></li>
</ul></div><a href="utility" class="button section">See more</a>
</div>
</div>
</div>
</main></div></div></div>
<footer style="text-align: justify;"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>

View file

@ -1,368 +1,368 @@
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<title>mini.css - Navigation</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, module, navigation ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-centered { text-align: center; } .box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;} .box-colored.red { background: #e53935; }
.box-centered > .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto; } [class^='col-'] .card.fluid { margin: 2px 0 20px; }
[class^='fore-'] { font-family: monospace, monospace;} .fore-primary { color: #0d47a1;} .fore-secondary { color: #b71c1c;} .fore-tertiary { color: #1b5e20;}
.col-sm-12.col-sm-last.col-lg-4.col-md-normal {box-sizing: border-box; border-right: 1px solid #c9c9c9;}
@media (max-width: 767px){.col-sm-12.col-sm-last.col-lg-4.col-md-normal {border: 0;border-top: 1px solid #c9c9c9;}}
@media (min-width:768px) and (max-width: 1279px){.col-sm-12.col-sm-last.col-lg-4.col-md-normal {border: 0;border-bottom: 1px solid #c9c9c9;}}
.box-colored.green { background: #689f38; } .do {border-top: 15px solid #689f38;padding-top: 10px;} .dont {border-top: 15px solid #e53935;padding-top: 10px;}
.box-colored { color: #f5f5f5;} .col-sm-12.col-sm-last.col-md-12.col-md-normal {box-sizing: border-box;border-bottom: 1px solid #c9c9c9;}
@media (max-width: 767px){.col-sm-12.col-sm-last.col-md-12.col-md-normal {border: 0;border-top: 1px solid #c9c9c9;}}
@media (min-width: 1280px) {.col-sm-12.col-sm-last.col-md-12.col-md-normal.col-lg-4.col-lg-normal {border:0; border-right: 1px solid #c9c9c9; }}
@media (max-width: 767px){.container {padding: 0.25rem !important;}.col-sm-12.col-md-8.col-lg-10{padding: 0 !important;}}
@media screen and (min-width: 768px) { .drawer#real-drawer { margin-top: 4px;}}
</style>
</head>
<body>
<header class="sticky">
<a href="index" class="logo"><span id="header-logo">m</span></a>
<label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="index" class="button hidden-sm">Introduction</a> <a href="modules" class="button hidden-sm">Modules</a>
<a href="flavors" class="button hidden-sm">Flavors</a> <a href="templates" class="button hidden-sm">Templates</a>
<a href="customization" class="button hidden-sm">Customization</a> <a href="quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<div class="container" style="padding-left: 0.25rem;">
<div class="row"> <input type="checkbox" id="navigation-toggle"> <nav class="drawer col-md-4 col-lg-2" id="real-drawer">
<label class="close" for="navigation-toggle"></label>
<a href="index"><h4 style="margin-left: 0;">Introduction</h4></a>
<h4 style="margin-left: 0;">Modules</h4> <a href="core#core-title">Core</a>
<a href="core#typography" class="sublink-1">Typography</a> <a href="core#headings" class="sublink-1">Headings</a>
<a href="core#common-textual-elements" class="sublink-1">Common textual elements</a>
<a href="core#lists" class="sublink-1">Lists</a> <a href="core#images-captions" class="sublink-1">Image responsiveness &amp; captions</a>
<br/> <a href="grid#grid-title">Grid</a>
<a href="grid#basic-layout" class="sublink-1">Basic layout</a> <a href="grid#screen-specific-layout" class="sublink-1">Screen specific layouts</a>
<a href="grid#predefined-layout" class="sublink-1">Predefined layouts</a> <a href="grid#column-offset" class="sublink-1">Column offsets</a>
<a href="grid#column-reorder" class="sublink-1">Column reordering</a> <a href="grid#media-object" class="sublink-1">Media object pattern</a>
<br/> <a href="input_control#input-control-title">Input Control</a>
<a href="input_control#forms-input" class="sublink-1">Forms &amp; input</a> <a href="input_control#checkbox-radio" class="sublink-1">Checkboxes &amp; radio buttons</a> <a href="input_control#switches" class="sublink-1">Switches</a>
<a href="input_control#buttons" class="sublink-1">Buttons &amp; button groups</a> <a href="input_control#file-upload" class="sublink-1">File upload buttons</a>
<br/> <a href="navigation#navigation-title">Navigation</a>
<a href="navigation#header" class="sublink-1">Header</a> <a href="navigation#navigation-bar" class="sublink-1">Navigation bar</a> <a href="navigation#drawer" class="sublink-1">Drawer</a>
<a href="navigation#footer" class="sublink-1">Footer</a> <a href="navigation#sticky" class="sublink-1">Sticky headers &amp; footers</a>
<br/> <a href="table#table-title">Table</a>
<a href="table#syntax-responsiveness" class="sublink-1">Basic syntax &amp; responsiveness</a> <a href="table#scrollable-tables" class="sublink-1">Scrollable tables</a>
<a href="table#horizontal-tables" class="sublink-1">Horizontal tables</a> <a href="table#variants-matrices" class="sublink-1">Table variants &amp; matrices</a>
<br/> <a href="card#card-title">Card</a>
<a href="card#basic-syntax" class="sublink-1">Basic syntax</a> <a href="card#sections-media" class="sublink-1">Sections &amp; media</a>
<a href="card#sizing-fluidity" class="sublink-1">Card sizing &amp; fluidity</a> <a href="card#color-variants" class="sublink-1">Card color variants</a>
<br/> <a href="tab#tab-title">Tab</a>
<a href="tab#basic-syntax" class="sublink-1">Basic syntax</a> <a href="tab#stacked-tabs" class="sublink-1">Stacked tabs</a>
<br/> <a href="contextual#contextual-title">Contextual</a>
<a href="contextual#text-highlighting" class="sublink-1">Text highlighting</a> <a href="contextual#toasts" class="sublink-1">Toasts</a>
<a href="contextual#tooltips" class="sublink-1">Tooltips</a> <a href="contextual#modals" class="sublink-1">Modals</a>
<br/> <a href="progress#progress-title">Progress</a>
<a href="progress#basic-progress-bar" class="sublink-1">Basic progress bar</a> <a href="progress#progress-variants" class="sublink-1">Progress bar variants</a>
<a href="progress#donut-spinner" class="sublink-1">Donut spinner</a> <a href="progress#spinner-variants" class="sublink-1">Donut spinner variants</a>
<br/> <a href="utility#utility-title">Utility</a>
<a href="utility#visibility-helpers" class="sublink-1">Visibility helpers</a> <a href="utility#borders-shadows" class="sublink-1">Generic borders &amp; shadows</a>
<a href="utility#responsive-sizing" class="sublink-1">Responsive sizing &amp; spacing classes</a>
<a href="utility#responsive-visibility" class="sublink-1">Responsive visibility helpers</a> <a href="utility#breadcrumbs" class="sublink-1">Breadcrumbs</a>
<a href="utility#close-icon" class="sublink-1">Close icon</a>
<a href="flavors"><h4 style="margin-left: 0;">Flavors</h4></a>
<a href="templates"><h4 style="margin-left: 0;">Templates</h4></a>
<a href="customization"><h4 style="margin-left: 0;">Customization</h4></a>
<a href="quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<div class="col-sm-12 col-md-8 col-lg-10"><main>
<div class="row" style="padding-top: 40px;" id="navigation-title">
<div class="col-sm-12">
<h1>Navigation</h1>
<p style="text-align: justify;">The <strong>navigation</strong> module seeks to remedy the problems of vertical and horizontal navigation design paradigms, by combining the two for a better presentational effect. HTML5 navigational elements are at the heart of the module, allowing you to quickly build your navigation menus.</p>
<p style="text-align: justify;"><small>All examples showcased refer to the mini-default flavor, some class names and styles might differ based on the flavor you're using.</small></p><br/>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<div class="card fluid">
<div class="section">
<h2>Quick overview</h2>
<p style="text-align: justify;">Menus and navigation are some of the most important elements for any website or web app and their design and ease-of-use are key factors that can determine a page's bounce rates. The <strong>navigation</strong> module takes a step back from the complicated menu and navigation design paradigms of the modern web, using HTML5 elements (i.e. <code>header</code>, <code>nav</code> and <code>footer</code>) for basic navigation, while providing fully accessibility for screen readers. Apart from the simple horizontal navigation (headers) and vertical menus (sidebars), we opted to add a responsive slide-in drawer menu that works well with any page layout. Finally, footers are also part of the <strong>navigation</strong> module, as they can often provide the user with useful information and/or links that are very important to enhancing their experience.</p><br>
</div>
<div class="section">
<h2>Quick start</h2>
<p style="text-align: justify;">To use the <strong>navigation</strong> module, simply include the link to the flavor you are using and start writing your HTML page as usual. One suggestion we will make is to add the following line inside your HTML page's <code>&lt;head&gt;</code> to utilize the viewport meta tag:</p>
<pre>&lt;<span class="fore-tertiary">meta</span> <span class="fore-secondary">name</span>=<span class="fore-primary">&quot;viewport&quot;</span> <span class="fore-secondary">content</span>=<span class="fore-primary">&quot;width=device-width, initial-scale=1&quot;</span>&gt;</pre><br>
</div>
</div>
</div>
</div>
<div class="row" id="header">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Header</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal">
<div><br>
<header>
<a href="#" class="logo">Logo</a> <button>Home</button>
<a href="#" class="button">News</a> <span>|</span>
<button>About</button> <button>Contact</button>
</header> <br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal">
<p style="text-align: justify;">The <code>&lt;header&gt;</code> HTML element is used for a page's top horizontal navigation menu. It can contain a unique <code>.logo</code> element as its first child (this structure is not mandatory, but still recommended as a best practice), which can be either text (with or without a link) or an image. The rest of the elements inside the <code>&lt;header&gt;</code> must be button elements (i.e. <code>&lt;button&gt;</code>, <code>&lt;input <span class="fore-secondary">type</span>=<span class="fore-primary">&quot;button&quot;</span>&gt;</code>, <code><span class="fore-secondary">role</span>=<span class="fore-primary">&quot;<a href="https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/ARIA_Techniques/Using_the_button_role">button</a>&quot;</span></code> or <code>.button</code>) in order to be styled properly. Textual separators between those can be added using <code>&lt;span&gt;</code> elements.</p>
<h3>Sample code</h3>
<pre>&lt;header&gt;
&lt;a href=&quot;#&quot; class=&quot;logo&quot;&gt;Logo&lt;/a&gt;
&lt;button&gt;Home&lt;/button&gt;
&lt;a href=&quot;#&quot; class=&quot;button&quot;&gt;News&lt;/a&gt;
&lt;span&gt;|&lt;/span&gt;
&lt;button&gt;About&lt;/button&gt;
&lt;a href=&quot;#&quot; role=&quot;button&quot;&gt;Contact&lt;/a&gt;
&lt;/header&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align: justify;">
<li>The <code>&lt;header&gt;</code> element is partially responsive on smaller screen devices. More specifically, when the content inside it exceeds the width of the viewport (ie. overflows to the right), users will be able to scroll horizontally in order to see the rest of the menu.</li>
<li>The <code>&lt;header&gt;</code> element does not display as <code class="fore-tertiary">fixed</code> by default. You can, however, alter this CSS property manually, if you so desire.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;header&gt;
&lt;a href=&quot;#&quot; class=&quot;logo&quot;&gt;Logo&lt;/a&gt;
&lt;button&gt;Action 1&lt;/button&gt;
&lt;a href=&quot;#&quot; class=&quot;button&quot;&gt;Action 2&lt;/a&gt;
&lt;label class=&quot;button&quot;&gt;Action 3&lt;/label&gt;
&lt;/header&gt;</pre>
<p class="do" style="text-align: justify;"><mark class="tertiary">Do:</mark>&nbsp;You can mix different elements styled like buttons inside a <code>&lt;header&gt;</code> element. In fact, we strongly recommend doing so, if you need to.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;header&gt;
&lt;a href=&quot;#&quot; class=&quot;button logo&quot;&gt;Logo&lt;/a&gt;
&lt;/header&gt;
<span class="fore-secondary">&lt;!-- or --&gt;</span>
&lt;header&gt;
&lt;a href=&quot;#&quot; class=&quot;logo&quot;&gt;Logo&lt;/a&gt;
&lt;a href=&quot;#&quot;&gt;Link&lt;/a&gt;
&lt;/header&gt;</pre>
<p class="dont" style="text-align: justify;"><mark class="secondary">Don't:</mark>&nbsp;The <code>.logo</code> element should not be a <code>&lt;button&gt;</code> element, have the <code>.button</code> class or the <code><span class="fore-secondary">role</span>=<span class="fore-primary">&quot;<a href="https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/ARIA_Techniques/Using_the_button_role">button</a>&quot;</span></code> attribute. On the other hand, links and labels in the <code>&lt;header&gt;</code> should not be without a <code>.button</code> class or a <code><span class="fore-secondary">role</span>=<span class="fore-primary">&quot;<a href="https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/ARIA_Techniques/Using_the_button_role">button</a>&quot;</span></code> attribute. Ignoring this rule might cause unexpected behavior.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="navigation-bar">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Navigation bar</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal col-lg-4 col-lg-normal">
<div><br>
<nav>
<a href="#">Home</a> <span>News</span>
<a href="#" class="sublink-1">New Courses</a> <a href="#" class="sublink-1">Certifications</a>
<span class="sublink-1">Events</span> <a href="#" class="sublink-2">Course Showcase - 12th, Dec</a>
<a href="#" class="sublink-2">Staff AMA - 16th, Dec</a> <a href="#" class="sublink-1">Policy Update</a>
<a href="#">About</a> <a href="#">Contact</a>
</nav><br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal col-lg-8 col-lg-normal">
<p style="text-align: justify;">To add vertical navigation to your websites, use the <code>&lt;nav&gt;</code> HTML element. Adding links is pretty simple, just use <code>&lt;a&gt;</code> elements, no lists or anything else required. In order to add subcategories to your vertical navigation, use any normal textual element as the title of the subcategory and follow it with its links as normal, adding the <code>.sublink-1</code> class to them. Similarly, you can create a subcategory with a depth of 2, using a similar structure and the <code>.sublink-2</code> class.</p>
<h3>Sample code</h3>
<pre>&lt;nav&gt;
&lt;a href=&quot;#&quot;&gt;Home&lt;/a&gt;
&lt;span&gt;News&lt;/span&gt;
&lt;a href=&quot;#&quot; class=&quot;sublink-1&quot;&gt;New Courses&lt;/a&gt;
&lt;a href=&quot;#&quot; class=&quot;sublink-1&quot;&gt;Certifications&lt;/a&gt;
&lt;span class=&quot;sublink-1&quot;&gt;Events&lt;/span&gt;
&lt;a href=&quot;#&quot; class=&quot;sublink-2&quot;&gt;Course Showcase - 12th, Dec&lt;/a&gt;
&lt;a href=&quot;#&quot; class=&quot;sublink-2&quot;&gt;Staff AMA - 16th, Dec&lt;/a&gt;
&lt;a href=&quot;#&quot; class=&quot;sublink-1&quot;&gt;Policy Update&lt;/a&gt;
&lt;a href=&quot;#&quot;&gt;About&lt;/a&gt;
&lt;a href=&quot;#&quot;&gt;Contact&lt;/a&gt;
&lt;/nav&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align: justify;">
<li>Subcategories and their links support a depth of 2 by default. If, however, you need more than that, we recommend you check the <a href="customization">customization page</a> for instructions on how to add more depth to the vertical navigation.</li>
<li>We strongly suggest you do not add irrelevant things inside your <code>&lt;nav&gt;</code> element, like images or text that are not part of the navigation menu.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12">
<pre>&lt;div class=&quot;col-sm-12 col-sm-last col-md-3 col-md-first&quot;&gt;
&lt;nav&gt;
<span class="fore-tertiary">&lt;!-- navigation content --&gt;</span>
&lt;/nav&gt;
&lt;/div&gt;</pre>
<p class="do" style="text-align: justify;"><mark class="tertiary">Do:</mark>&nbsp;We strongly recommend using the <code>&lt;nav&gt;</code> element in combination with the <a href="grid"><strong>grid</strong></a> module to make your layouts more responsive. For example, you could make your sidebar appear on the left side of your content in medium-sized and larger screens, but move to the very bottom of your content on smaller screens.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="drawer">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Drawer</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal">
<div style="height: 15rem;"><br>
<style>.drawer.demo { position: absolute; height: 15rem; z-index: 0; top: 6.625rem; height: 12.5rem;} [type="checkbox"]:checked + .drawer.demo { z-index: 1001; margin-left: 0.75rem;}</style>
<header><label for="demo-toggle" class="button drawer-toggle persistent"></label></header> <br>
<input type="checkbox" id="demo-toggle"> <nav class="drawer demo persistent">
<label for="demo-toggle" class="close"></label><a href="#">Home</a> <span>News</span>
<a href="#" class="sublink-1">New Courses</a> <a href="#" class="sublink-1">Certifications</a>
<span class="sublink-1">Events</span> <a href="#" class="sublink-2">Course Showcase - 12th, Dec</a>
<a href="#" class="sublink-2">Staff AMA - 16th, Dec</a> <a href="#" class="sublink-1">Policy Update</a>
<a href="#">About</a> <a href="#">Contact</a><br/></nav>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal">
<p style="text-align: justify;">The drawer component is used to create responsive and collapsible navigation menus. To create the drawer system, follow the steps presented below:</p>
<ul style="text-align: justify;">
<li>Inside your <code>&lt;header&gt;</code> element, add a <code>&lt;label&gt;</code> element with the <code>.drawer-toggle</code> class (remember to add the <code>.button</code> class to apply the necessary styles).</li>
<li>Create an <code>&lt;input <span class="fore-secondary">type</span>="<span class="fore-primary">checkbox</span>"&gt;</code> element. Give it an <code class="fore-secondary">id</code> to be able to link it to the necessary interactive elements.</li>
<li>Immediately after the previous <code>&lt;input <span class="fore-secondary">type</span>="<span class="fore-primary">checkbox</span>"&gt;</code>, create a <code>&lt;div&gt;</code> element with the <code>.drawer</code> class. This is where you will put your menu's contents.</li>
<li>Add an empty <code>&lt;label&gt;</code> element inside your <code>.drawer</code>, adding the <code>.close</code> class to it.</li>
<li>Finally, link the <code>.drawer-toggle</code> and <code>.close</code> elements to the <code class="fore-secondary">id</code> of your <code>&lt;input <span class="fore-secondary">type</span>="<span class="fore-primary">checkbox</span>"&gt;</code>.</li>
</ul>
<p style="text-align: justify;">Drawers are responsive and will expand into normal containers on larger screens. If you want to avoid this, add the <code>.persistent</code> class to both your <code>.drawer-toggle</code> and <code>.drawer</code> elements. You can also change the position of the drawer from the left side of the screen to the right by applying the <code>.right</code> class to your <code>.drawer</code> element.</p>
<h3>Sample code</h3>
<pre>&lt;header&gt;
&lt;label for=&quot;drawer-checkbox&quot; class=&quot;button drawer-toggle&quot;&gt;&lt;/label&gt;
&lt;/header&gt;
&lt;input type=&quot;checkbox&quot; id=&quot;drawer-checkbox&quot;&gt;
&lt;div class=&quot;drawer&quot;&gt;
&lt;label for=&quot;drawer-checkbox&quot; class=&quot;close&quot;&gt;&lt;/label&gt;
&lt;a href=&quot;#&quot;&gt;Home&lt;/a&gt;
&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align: justify;">
<li>The <code>.drawer</code> component can be easily and effectively combined with the <a href="grid"><strong>grid</strong></a> module's system and classes, as well as the <a href="utility"><strong>utility</strong></a> module's responsive visibility helper classes to create fully responsive navigation menus.</li>
<li>It's best to use the <code>.drawer</code> component in combination with a <code>&lt;header&gt;</code> element that has the <code>.sticky</code> class (check the last section of this page).</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6 col-sm-first">
<pre>&lt;nav class=&quot;drawer&quot;&gt;
&lt;label for=&quot;drawer-checkbox&quot; class=&quot;close&quot;&gt;&lt;/label&gt;
&lt;a href=&quot;#&quot;&gt;Home&lt;/a&gt;
&lt;/nav&gt;</pre>
<p class="do" style="text-align: justify;"><mark class="tertiary">Do:</mark>&nbsp;You can apply the <code>.drawer</code> class to a <code>&lt;nav&gt;</code> element, effectively making your page's navigation menu collapse on smaller screen sizes.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;input type=&quot;checkbox&quot; id=&quot;drawer-checkbox&quot;&gt;
<span class="fore-secondary">&lt;!-- Other stuff here --&gt;</span>
&lt;div class=&quot;drawer&quot;&gt;
&lt;h3&gt;Bad drawer&lt;/h3&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align: justify;"><mark class="secondary">Don't:</mark>&nbsp;The syntax and structure of the drawer container is very strict. Try to follow it exactly as described in this section.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-first col-md-normal">
<pre>&lt;div class=&quot;row&quot;&gt;
&lt;input type=&quot;checkbox&quot; id=&quot;drawer-checkbox&quot;&gt;
&lt;div class=&quot;drawer col-md-4&quot;&gt;
&lt;label for=&quot;drawer-checkbox&quot; class=&quot;close&quot;&gt;&lt;/label&gt;
&lt;a href=&quot;#&quot;&gt;Home&lt;/a&gt;
&lt;/div&gt;
&lt;div class=&quot;col-sm-12 col-md-8&quot;&gt;
&lt;p&gt;Page content&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="do" style="text-align: justify;"><mark class="tertiary">Do:</mark>&nbsp;You can combine the <code>.drawer</code> component with the grid system, similarly to any other element or component. The <code>.drawer</code> will be displayed as a slide-in menu on smaller screens, but it's part of the layout on medium-sized and larger screens.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last">
<pre>&lt;header&gt;
&lt;label for=&quot;drawer-checkbox&quot; class=&quot;button drawer-toggle persistent&quot;&gt;&lt;/label&gt;
&lt;/header&gt;
&lt;input type=&quot;checkbox&quot; id=&quot;drawer-checkbox&quot;&gt;
&lt;div class=&quot;drawer&quot;&gt;...&lt;/div&gt;
&lt;!-- or --&gt;
&lt;header&gt;
&lt;label for=&quot;drawer-checkbox&quot; class=&quot;button drawer-toggle&quot;&gt;&lt;/label&gt;
&lt;/header&gt;
&lt;input type=&quot;checkbox&quot; id=&quot;drawer-checkbox&quot;&gt;
&lt;div class=&quot;drawer peristent&quot;&gt;...&lt;/div&gt;</pre>
<p class="dont" style="text-align: justify;"><mark class="secondary">Don't:</mark>&nbsp;Remember to apply the <code>.persistent</code> class to the <code>.drawer-toggle</code> and <code>.drawer</code> elements to avoid unexpected behavior.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="footer">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Footer</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-lg-4 col-md-normal">
<div><br>
<footer> <p>&copy; 2001-2016 Web Corporation | <a href="#">About</a> | <a href="#">Terms of use</a></p> </footer> <br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-lg-8 col-md-normal">
<p style="text-align: justify;">The <code>&lt;footer&gt;</code> element is used to create your page's footer. As normal, add the <code>&lt;footer&gt;</code> at or near the end of your <code>&lt;body&gt;</code> element and add content to it like you would otherwise.</p>
<h3>Sample code</h3>
<pre>&lt;footer&gt;
&lt;p&gt;&amp;copy; 2001-2016 Web Corporation | &lt;a href=&quot;#&quot;&gt;About&lt;/a&gt; | &lt;a href=&quot;#&quot;&gt;Terms of use&lt;/a&gt;&lt;/p&gt;
&lt;/footer&gt;</pre>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="sticky">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Sticky headers and footers</h2></div>
<div class="section row">
<div class="col-sm-12">
<p style="text-align: justify;">You can create sticky headers and footers, using the <code>.sticky</code> class on either of these elements.</p>
<h3>Sample code</h3>
<pre>&lt;header class=&quot;sticky&quot;&gt;
&lt;a href=&quot;#&quot; class=&quot;logo&quot;&gt;Logo&lt;/a&gt; &lt;button&gt;Home&lt;/button&gt; &lt;button&gt;About&lt;/button&gt;
&lt;/header&gt;
&lt;footer class=&quot;sticky&quot;&gt;
&lt;p&gt;&amp;copy; 2001-2016 Web Corporation | &lt;a href=&quot;#&quot;&gt;About&lt;/a&gt; | &lt;a href=&quot;#&quot;&gt;Terms of use&lt;/a&gt;&lt;/p&gt;
&lt;/footer&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align: justify;">
<li>Sticky headers and footers are compatible with modern browsers, but might not display properly in older browsers. Support is being added over time, so be sure to check out if your target platforms support <a href="http://caniuse.com/#feat=css-sticky"><code>position:sticky</code></a>.</li>
</ul>
</div>
</div>
</div>
</div>
<div class="row" style="padding-bottom: 20px; padding-top:20px;">
<div class="col-sm-12">
<p style="text-align: justify;">If you want to learn more about <strong>mini.css</strong>'s modules, go back to the <a href="modules">modules page</a> and choose another module to see its documentation.</p>
</div>
</div>
</main></div></div></div>
<footer style="text-align: justify;"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<title>mini.css - Navigation</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, module, navigation ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-centered { text-align: center; } .box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;} .box-colored.red { background: #e53935; }
.box-centered > .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto; } [class^='col-'] .card.fluid { margin: 2px 0 20px; }
[class^='fore-'] { font-family: monospace, monospace;} .fore-primary { color: #0d47a1;} .fore-secondary { color: #b71c1c;} .fore-tertiary { color: #1b5e20;}
.col-sm-12.col-sm-last.col-lg-4.col-md-normal {box-sizing: border-box; border-right: 1px solid #c9c9c9;}
@media (max-width: 767px){.col-sm-12.col-sm-last.col-lg-4.col-md-normal {border: 0;border-top: 1px solid #c9c9c9;}}
@media (min-width:768px) and (max-width: 1279px){.col-sm-12.col-sm-last.col-lg-4.col-md-normal {border: 0;border-bottom: 1px solid #c9c9c9;}}
.box-colored.green { background: #689f38; } .do {border-top: 15px solid #689f38;padding-top: 10px;} .dont {border-top: 15px solid #e53935;padding-top: 10px;}
.box-colored { color: #f5f5f5;} .col-sm-12.col-sm-last.col-md-12.col-md-normal {box-sizing: border-box;border-bottom: 1px solid #c9c9c9;}
@media (max-width: 767px){.col-sm-12.col-sm-last.col-md-12.col-md-normal {border: 0;border-top: 1px solid #c9c9c9;}}
@media (min-width: 1280px) {.col-sm-12.col-sm-last.col-md-12.col-md-normal.col-lg-4.col-lg-normal {border:0; border-right: 1px solid #c9c9c9; }}
@media (max-width: 767px){.container {padding: 0.25rem !important;}.col-sm-12.col-md-8.col-lg-10{padding: 0 !important;}}
@media screen and (min-width: 768px) { .drawer#real-drawer { margin-top: 4px;}}
</style>
</head>
<body>
<header class="sticky">
<a href="index" class="logo"><span id="header-logo">m</span></a>
<label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="index" class="button hidden-sm">Introduction</a> <a href="modules" class="button hidden-sm">Modules</a>
<a href="flavors" class="button hidden-sm">Flavors</a> <a href="templates" class="button hidden-sm">Templates</a>
<a href="customization" class="button hidden-sm">Customization</a> <a href="quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<div class="container" style="padding-left: 0.25rem;">
<div class="row"> <input type="checkbox" id="navigation-toggle"> <nav class="drawer col-md-4 col-lg-2" id="real-drawer">
<label class="close" for="navigation-toggle"></label>
<a href="index"><h4 style="margin-left: 0;">Introduction</h4></a>
<h4 style="margin-left: 0;">Modules</h4> <a href="core#core-title">Core</a>
<a href="core#typography" class="sublink-1">Typography</a> <a href="core#headings" class="sublink-1">Headings</a>
<a href="core#common-textual-elements" class="sublink-1">Common textual elements</a>
<a href="core#lists" class="sublink-1">Lists</a> <a href="core#images-captions" class="sublink-1">Image responsiveness &amp; captions</a>
<br/> <a href="grid#grid-title">Grid</a>
<a href="grid#basic-layout" class="sublink-1">Basic layout</a> <a href="grid#screen-specific-layout" class="sublink-1">Screen specific layouts</a>
<a href="grid#predefined-layout" class="sublink-1">Predefined layouts</a> <a href="grid#column-offset" class="sublink-1">Column offsets</a>
<a href="grid#column-reorder" class="sublink-1">Column reordering</a> <a href="grid#media-object" class="sublink-1">Media object pattern</a>
<br/> <a href="input_control#input-control-title">Input Control</a>
<a href="input_control#forms-input" class="sublink-1">Forms &amp; input</a> <a href="input_control#checkbox-radio" class="sublink-1">Checkboxes &amp; radio buttons</a> <a href="input_control#switches" class="sublink-1">Switches</a>
<a href="input_control#buttons" class="sublink-1">Buttons &amp; button groups</a> <a href="input_control#file-upload" class="sublink-1">File upload buttons</a>
<br/> <a href="navigation#navigation-title">Navigation</a>
<a href="navigation#header" class="sublink-1">Header</a> <a href="navigation#navigation-bar" class="sublink-1">Navigation bar</a> <a href="navigation#drawer" class="sublink-1">Drawer</a>
<a href="navigation#footer" class="sublink-1">Footer</a> <a href="navigation#sticky" class="sublink-1">Sticky headers &amp; footers</a>
<br/> <a href="table#table-title">Table</a>
<a href="table#syntax-responsiveness" class="sublink-1">Basic syntax &amp; responsiveness</a> <a href="table#scrollable-tables" class="sublink-1">Scrollable tables</a>
<a href="table#horizontal-tables" class="sublink-1">Horizontal tables</a> <a href="table#variants-matrices" class="sublink-1">Table variants &amp; matrices</a>
<br/> <a href="card#card-title">Card</a>
<a href="card#basic-syntax" class="sublink-1">Basic syntax</a> <a href="card#sections-media" class="sublink-1">Sections &amp; media</a>
<a href="card#sizing-fluidity" class="sublink-1">Card sizing &amp; fluidity</a> <a href="card#color-variants" class="sublink-1">Card color variants</a>
<br/> <a href="tab#tab-title">Tab</a>
<a href="tab#basic-syntax" class="sublink-1">Basic syntax</a> <a href="tab#stacked-tabs" class="sublink-1">Stacked tabs</a>
<br/> <a href="contextual#contextual-title">Contextual</a>
<a href="contextual#text-highlighting" class="sublink-1">Text highlighting</a> <a href="contextual#toasts" class="sublink-1">Toasts</a>
<a href="contextual#tooltips" class="sublink-1">Tooltips</a> <a href="contextual#modals" class="sublink-1">Modals</a>
<br/> <a href="progress#progress-title">Progress</a>
<a href="progress#basic-progress-bar" class="sublink-1">Basic progress bar</a> <a href="progress#progress-variants" class="sublink-1">Progress bar variants</a>
<a href="progress#donut-spinner" class="sublink-1">Donut spinner</a> <a href="progress#spinner-variants" class="sublink-1">Donut spinner variants</a>
<br/> <a href="utility#utility-title">Utility</a>
<a href="utility#visibility-helpers" class="sublink-1">Visibility helpers</a> <a href="utility#borders-shadows" class="sublink-1">Generic borders &amp; shadows</a>
<a href="utility#responsive-sizing" class="sublink-1">Responsive sizing &amp; spacing classes</a>
<a href="utility#responsive-visibility" class="sublink-1">Responsive visibility helpers</a> <a href="utility#breadcrumbs" class="sublink-1">Breadcrumbs</a>
<a href="utility#close-icon" class="sublink-1">Close icon</a>
<a href="flavors"><h4 style="margin-left: 0;">Flavors</h4></a>
<a href="templates"><h4 style="margin-left: 0;">Templates</h4></a>
<a href="customization"><h4 style="margin-left: 0;">Customization</h4></a>
<a href="quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<div class="col-sm-12 col-md-8 col-lg-10"><main>
<div class="row" style="padding-top: 40px;" id="navigation-title">
<div class="col-sm-12">
<h1>Navigation</h1>
<p style="text-align: justify;">The <strong>navigation</strong> module seeks to remedy the problems of vertical and horizontal navigation design paradigms, by combining the two for a better presentational effect. HTML5 navigational elements are at the heart of the module, allowing you to quickly build your navigation menus.</p>
<p style="text-align: justify;"><small>All examples showcased refer to the mini-default flavor, some class names and styles might differ based on the flavor you're using.</small></p><br/>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<div class="card fluid">
<div class="section">
<h2>Quick overview</h2>
<p style="text-align: justify;">Menus and navigation are some of the most important elements for any website or web app and their design and ease-of-use are key factors that can determine a page's bounce rates. The <strong>navigation</strong> module takes a step back from the complicated menu and navigation design paradigms of the modern web, using HTML5 elements (i.e. <code>header</code>, <code>nav</code> and <code>footer</code>) for basic navigation, while providing fully accessibility for screen readers. Apart from the simple horizontal navigation (headers) and vertical menus (sidebars), we opted to add a responsive slide-in drawer menu that works well with any page layout. Finally, footers are also part of the <strong>navigation</strong> module, as they can often provide the user with useful information and/or links that are very important to enhancing their experience.</p><br>
</div>
<div class="section">
<h2>Quick start</h2>
<p style="text-align: justify;">To use the <strong>navigation</strong> module, simply include the link to the flavor you are using and start writing your HTML page as usual. One suggestion we will make is to add the following line inside your HTML page's <code>&lt;head&gt;</code> to utilize the viewport meta tag:</p>
<pre>&lt;<span class="fore-tertiary">meta</span> <span class="fore-secondary">name</span>=<span class="fore-primary">&quot;viewport&quot;</span> <span class="fore-secondary">content</span>=<span class="fore-primary">&quot;width=device-width, initial-scale=1&quot;</span>&gt;</pre><br>
</div>
</div>
</div>
</div>
<div class="row" id="header">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Header</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal">
<div><br>
<header>
<a href="#" class="logo">Logo</a> <button>Home</button>
<a href="#" class="button">News</a> <span>|</span>
<button>About</button> <button>Contact</button>
</header> <br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal">
<p style="text-align: justify;">The <code>&lt;header&gt;</code> HTML element is used for a page's top horizontal navigation menu. It can contain a unique <code>.logo</code> element as its first child (this structure is not mandatory, but still recommended as a best practice), which can be either text (with or without a link) or an image. The rest of the elements inside the <code>&lt;header&gt;</code> must be button elements (i.e. <code>&lt;button&gt;</code>, <code>&lt;input <span class="fore-secondary">type</span>=<span class="fore-primary">&quot;button&quot;</span>&gt;</code>, <code><span class="fore-secondary">role</span>=<span class="fore-primary">&quot;<a href="https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/ARIA_Techniques/Using_the_button_role">button</a>&quot;</span></code> or <code>.button</code>) in order to be styled properly. Textual separators between those can be added using <code>&lt;span&gt;</code> elements.</p>
<h3>Sample code</h3>
<pre>&lt;header&gt;
&lt;a href=&quot;#&quot; class=&quot;logo&quot;&gt;Logo&lt;/a&gt;
&lt;button&gt;Home&lt;/button&gt;
&lt;a href=&quot;#&quot; class=&quot;button&quot;&gt;News&lt;/a&gt;
&lt;span&gt;|&lt;/span&gt;
&lt;button&gt;About&lt;/button&gt;
&lt;a href=&quot;#&quot; role=&quot;button&quot;&gt;Contact&lt;/a&gt;
&lt;/header&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align: justify;">
<li>The <code>&lt;header&gt;</code> element is partially responsive on smaller screen devices. More specifically, when the content inside it exceeds the width of the viewport (ie. overflows to the right), users will be able to scroll horizontally in order to see the rest of the menu.</li>
<li>The <code>&lt;header&gt;</code> element does not display as <code class="fore-tertiary">fixed</code> by default. You can, however, alter this CSS property manually, if you so desire.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;header&gt;
&lt;a href=&quot;#&quot; class=&quot;logo&quot;&gt;Logo&lt;/a&gt;
&lt;button&gt;Action 1&lt;/button&gt;
&lt;a href=&quot;#&quot; class=&quot;button&quot;&gt;Action 2&lt;/a&gt;
&lt;label class=&quot;button&quot;&gt;Action 3&lt;/label&gt;
&lt;/header&gt;</pre>
<p class="do" style="text-align: justify;"><mark class="tertiary">Do:</mark>&nbsp;You can mix different elements styled like buttons inside a <code>&lt;header&gt;</code> element. In fact, we strongly recommend doing so, if you need to.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;header&gt;
&lt;a href=&quot;#&quot; class=&quot;button logo&quot;&gt;Logo&lt;/a&gt;
&lt;/header&gt;
<span class="fore-secondary">&lt;!-- or --&gt;</span>
&lt;header&gt;
&lt;a href=&quot;#&quot; class=&quot;logo&quot;&gt;Logo&lt;/a&gt;
&lt;a href=&quot;#&quot;&gt;Link&lt;/a&gt;
&lt;/header&gt;</pre>
<p class="dont" style="text-align: justify;"><mark class="secondary">Don't:</mark>&nbsp;The <code>.logo</code> element should not be a <code>&lt;button&gt;</code> element, have the <code>.button</code> class or the <code><span class="fore-secondary">role</span>=<span class="fore-primary">&quot;<a href="https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/ARIA_Techniques/Using_the_button_role">button</a>&quot;</span></code> attribute. On the other hand, links and labels in the <code>&lt;header&gt;</code> should not be without a <code>.button</code> class or a <code><span class="fore-secondary">role</span>=<span class="fore-primary">&quot;<a href="https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/ARIA_Techniques/Using_the_button_role">button</a>&quot;</span></code> attribute. Ignoring this rule might cause unexpected behavior.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="navigation-bar">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Navigation bar</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal col-lg-4 col-lg-normal">
<div><br>
<nav>
<a href="#">Home</a> <span>News</span>
<a href="#" class="sublink-1">New Courses</a> <a href="#" class="sublink-1">Certifications</a>
<span class="sublink-1">Events</span> <a href="#" class="sublink-2">Course Showcase - 12th, Dec</a>
<a href="#" class="sublink-2">Staff AMA - 16th, Dec</a> <a href="#" class="sublink-1">Policy Update</a>
<a href="#">About</a> <a href="#">Contact</a>
</nav><br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal col-lg-8 col-lg-normal">
<p style="text-align: justify;">To add vertical navigation to your websites, use the <code>&lt;nav&gt;</code> HTML element. Adding links is pretty simple, just use <code>&lt;a&gt;</code> elements, no lists or anything else required. In order to add subcategories to your vertical navigation, use any normal textual element as the title of the subcategory and follow it with its links as normal, adding the <code>.sublink-1</code> class to them. Similarly, you can create a subcategory with a depth of 2, using a similar structure and the <code>.sublink-2</code> class.</p>
<h3>Sample code</h3>
<pre>&lt;nav&gt;
&lt;a href=&quot;#&quot;&gt;Home&lt;/a&gt;
&lt;span&gt;News&lt;/span&gt;
&lt;a href=&quot;#&quot; class=&quot;sublink-1&quot;&gt;New Courses&lt;/a&gt;
&lt;a href=&quot;#&quot; class=&quot;sublink-1&quot;&gt;Certifications&lt;/a&gt;
&lt;span class=&quot;sublink-1&quot;&gt;Events&lt;/span&gt;
&lt;a href=&quot;#&quot; class=&quot;sublink-2&quot;&gt;Course Showcase - 12th, Dec&lt;/a&gt;
&lt;a href=&quot;#&quot; class=&quot;sublink-2&quot;&gt;Staff AMA - 16th, Dec&lt;/a&gt;
&lt;a href=&quot;#&quot; class=&quot;sublink-1&quot;&gt;Policy Update&lt;/a&gt;
&lt;a href=&quot;#&quot;&gt;About&lt;/a&gt;
&lt;a href=&quot;#&quot;&gt;Contact&lt;/a&gt;
&lt;/nav&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align: justify;">
<li>Subcategories and their links support a depth of 2 by default. If, however, you need more than that, we recommend you check the <a href="customization">customization page</a> for instructions on how to add more depth to the vertical navigation.</li>
<li>We strongly suggest you do not add irrelevant things inside your <code>&lt;nav&gt;</code> element, like images or text that are not part of the navigation menu.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12">
<pre>&lt;div class=&quot;col-sm-12 col-sm-last col-md-3 col-md-first&quot;&gt;
&lt;nav&gt;
<span class="fore-tertiary">&lt;!-- navigation content --&gt;</span>
&lt;/nav&gt;
&lt;/div&gt;</pre>
<p class="do" style="text-align: justify;"><mark class="tertiary">Do:</mark>&nbsp;We strongly recommend using the <code>&lt;nav&gt;</code> element in combination with the <a href="grid"><strong>grid</strong></a> module to make your layouts more responsive. For example, you could make your sidebar appear on the left side of your content in medium-sized and larger screens, but move to the very bottom of your content on smaller screens.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="drawer">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Drawer</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal">
<div style="height: 15rem;"><br>
<style>.drawer.demo { position: absolute; height: 15rem; z-index: 0; top: 6.625rem; height: 12.5rem;} [type="checkbox"]:checked + .drawer.demo { z-index: 1001; margin-left: 0.75rem;}</style>
<header><label for="demo-toggle" class="button drawer-toggle persistent"></label></header> <br>
<input type="checkbox" id="demo-toggle"> <nav class="drawer demo persistent">
<label for="demo-toggle" class="close"></label><a href="#">Home</a> <span>News</span>
<a href="#" class="sublink-1">New Courses</a> <a href="#" class="sublink-1">Certifications</a>
<span class="sublink-1">Events</span> <a href="#" class="sublink-2">Course Showcase - 12th, Dec</a>
<a href="#" class="sublink-2">Staff AMA - 16th, Dec</a> <a href="#" class="sublink-1">Policy Update</a>
<a href="#">About</a> <a href="#">Contact</a><br/></nav>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal">
<p style="text-align: justify;">The drawer component is used to create responsive and collapsible navigation menus. To create the drawer system, follow the steps presented below:</p>
<ul style="text-align: justify;">
<li>Inside your <code>&lt;header&gt;</code> element, add a <code>&lt;label&gt;</code> element with the <code>.drawer-toggle</code> class (remember to add the <code>.button</code> class to apply the necessary styles).</li>
<li>Create an <code>&lt;input <span class="fore-secondary">type</span>="<span class="fore-primary">checkbox</span>"&gt;</code> element. Give it an <code class="fore-secondary">id</code> to be able to link it to the necessary interactive elements.</li>
<li>Immediately after the previous <code>&lt;input <span class="fore-secondary">type</span>="<span class="fore-primary">checkbox</span>"&gt;</code>, create a <code>&lt;div&gt;</code> element with the <code>.drawer</code> class. This is where you will put your menu's contents.</li>
<li>Add an empty <code>&lt;label&gt;</code> element inside your <code>.drawer</code>, adding the <code>.close</code> class to it.</li>
<li>Finally, link the <code>.drawer-toggle</code> and <code>.close</code> elements to the <code class="fore-secondary">id</code> of your <code>&lt;input <span class="fore-secondary">type</span>="<span class="fore-primary">checkbox</span>"&gt;</code>.</li>
</ul>
<p style="text-align: justify;">Drawers are responsive and will expand into normal containers on larger screens. If you want to avoid this, add the <code>.persistent</code> class to both your <code>.drawer-toggle</code> and <code>.drawer</code> elements. You can also change the position of the drawer from the left side of the screen to the right by applying the <code>.right</code> class to your <code>.drawer</code> element.</p>
<h3>Sample code</h3>
<pre>&lt;header&gt;
&lt;label for=&quot;drawer-checkbox&quot; class=&quot;button drawer-toggle&quot;&gt;&lt;/label&gt;
&lt;/header&gt;
&lt;input type=&quot;checkbox&quot; id=&quot;drawer-checkbox&quot;&gt;
&lt;div class=&quot;drawer&quot;&gt;
&lt;label for=&quot;drawer-checkbox&quot; class=&quot;close&quot;&gt;&lt;/label&gt;
&lt;a href=&quot;#&quot;&gt;Home&lt;/a&gt;
&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align: justify;">
<li>The <code>.drawer</code> component can be easily and effectively combined with the <a href="grid"><strong>grid</strong></a> module's system and classes, as well as the <a href="utility"><strong>utility</strong></a> module's responsive visibility helper classes to create fully responsive navigation menus.</li>
<li>It's best to use the <code>.drawer</code> component in combination with a <code>&lt;header&gt;</code> element that has the <code>.sticky</code> class (check the last section of this page).</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6 col-sm-first">
<pre>&lt;nav class=&quot;drawer&quot;&gt;
&lt;label for=&quot;drawer-checkbox&quot; class=&quot;close&quot;&gt;&lt;/label&gt;
&lt;a href=&quot;#&quot;&gt;Home&lt;/a&gt;
&lt;/nav&gt;</pre>
<p class="do" style="text-align: justify;"><mark class="tertiary">Do:</mark>&nbsp;You can apply the <code>.drawer</code> class to a <code>&lt;nav&gt;</code> element, effectively making your page's navigation menu collapse on smaller screen sizes.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;input type=&quot;checkbox&quot; id=&quot;drawer-checkbox&quot;&gt;
<span class="fore-secondary">&lt;!-- Other stuff here --&gt;</span>
&lt;div class=&quot;drawer&quot;&gt;
&lt;h3&gt;Bad drawer&lt;/h3&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align: justify;"><mark class="secondary">Don't:</mark>&nbsp;The syntax and structure of the drawer container is very strict. Try to follow it exactly as described in this section.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-first col-md-normal">
<pre>&lt;div class=&quot;row&quot;&gt;
&lt;input type=&quot;checkbox&quot; id=&quot;drawer-checkbox&quot;&gt;
&lt;div class=&quot;drawer col-md-4&quot;&gt;
&lt;label for=&quot;drawer-checkbox&quot; class=&quot;close&quot;&gt;&lt;/label&gt;
&lt;a href=&quot;#&quot;&gt;Home&lt;/a&gt;
&lt;/div&gt;
&lt;div class=&quot;col-sm-12 col-md-8&quot;&gt;
&lt;p&gt;Page content&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="do" style="text-align: justify;"><mark class="tertiary">Do:</mark>&nbsp;You can combine the <code>.drawer</code> component with the grid system, similarly to any other element or component. The <code>.drawer</code> will be displayed as a slide-in menu on smaller screens, but it's part of the layout on medium-sized and larger screens.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last">
<pre>&lt;header&gt;
&lt;label for=&quot;drawer-checkbox&quot; class=&quot;button drawer-toggle persistent&quot;&gt;&lt;/label&gt;
&lt;/header&gt;
&lt;input type=&quot;checkbox&quot; id=&quot;drawer-checkbox&quot;&gt;
&lt;div class=&quot;drawer&quot;&gt;...&lt;/div&gt;
&lt;!-- or --&gt;
&lt;header&gt;
&lt;label for=&quot;drawer-checkbox&quot; class=&quot;button drawer-toggle&quot;&gt;&lt;/label&gt;
&lt;/header&gt;
&lt;input type=&quot;checkbox&quot; id=&quot;drawer-checkbox&quot;&gt;
&lt;div class=&quot;drawer peristent&quot;&gt;...&lt;/div&gt;</pre>
<p class="dont" style="text-align: justify;"><mark class="secondary">Don't:</mark>&nbsp;Remember to apply the <code>.persistent</code> class to the <code>.drawer-toggle</code> and <code>.drawer</code> elements to avoid unexpected behavior.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="footer">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Footer</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-lg-4 col-md-normal">
<div><br>
<footer> <p>&copy; 2001-2016 Web Corporation | <a href="#">About</a> | <a href="#">Terms of use</a></p> </footer> <br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-lg-8 col-md-normal">
<p style="text-align: justify;">The <code>&lt;footer&gt;</code> element is used to create your page's footer. As normal, add the <code>&lt;footer&gt;</code> at or near the end of your <code>&lt;body&gt;</code> element and add content to it like you would otherwise.</p>
<h3>Sample code</h3>
<pre>&lt;footer&gt;
&lt;p&gt;&amp;copy; 2001-2016 Web Corporation | &lt;a href=&quot;#&quot;&gt;About&lt;/a&gt; | &lt;a href=&quot;#&quot;&gt;Terms of use&lt;/a&gt;&lt;/p&gt;
&lt;/footer&gt;</pre>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="sticky">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Sticky headers and footers</h2></div>
<div class="section row">
<div class="col-sm-12">
<p style="text-align: justify;">You can create sticky headers and footers, using the <code>.sticky</code> class on either of these elements.</p>
<h3>Sample code</h3>
<pre>&lt;header class=&quot;sticky&quot;&gt;
&lt;a href=&quot;#&quot; class=&quot;logo&quot;&gt;Logo&lt;/a&gt; &lt;button&gt;Home&lt;/button&gt; &lt;button&gt;About&lt;/button&gt;
&lt;/header&gt;
&lt;footer class=&quot;sticky&quot;&gt;
&lt;p&gt;&amp;copy; 2001-2016 Web Corporation | &lt;a href=&quot;#&quot;&gt;About&lt;/a&gt; | &lt;a href=&quot;#&quot;&gt;Terms of use&lt;/a&gt;&lt;/p&gt;
&lt;/footer&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align: justify;">
<li>Sticky headers and footers are compatible with modern browsers, but might not display properly in older browsers. Support is being added over time, so be sure to check out if your target platforms support <a href="http://caniuse.com/#feat=css-sticky"><code>position:sticky</code></a>.</li>
</ul>
</div>
</div>
</div>
</div>
<div class="row" style="padding-bottom: 20px; padding-top:20px;">
<div class="col-sm-12">
<p style="text-align: justify;">If you want to learn more about <strong>mini.css</strong>'s modules, go back to the <a href="modules">modules page</a> and choose another module to see its documentation.</p>
</div>
</div>
</main></div></div></div>
<footer style="text-align: justify;"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>

View file

@ -1,251 +1,251 @@
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<title>mini.css - Progress</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, module, progress ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-centered { text-align: center; } .box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;}
.box-colored.red { background: #e53935; } @media (max-width: 767px){.container {padding: 0.25rem !important;}.col-sm-12.col-md-8.col-lg-10{padding: 0 !important;}}
.box-centered > .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto; } [class^='col-'] .card.fluid { margin: 2px 0 20px; }
[class^='fore-'] { font-family: monospace, monospace;} .fore-primary { color: #0d47a1;} .fore-secondary { color: #b71c1c;} .fore-tertiary { color: #1b5e20;}
.col-sm-12.col-sm-last.col-md-4.col-md-normal {box-sizing: border-box;border-right: 1px solid #c9c9c9;}
@media (max-width: 767px){.col-sm-12.col-sm-last.col-md-4.col-md-normal { border: 0;border-top: 1px solid #c9c9c9;}}
.box-colored.green { background: #689f38; } .do {border-top: 15px solid #689f38;padding-top: 10px;} .dont {border-top: 15px solid #e53935;padding-top: 10px;}
.box-colored {color: #f5f5f5;} @media screen and (min-width: 768px) { .drawer { margin-top: 4px;}}
</style>
</head>
<body>
<header class="sticky">
<a href="index" class="logo"><span id="header-logo">m</span></a>
<label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="index" class="button hidden-sm">Introduction</a> <a href="modules" class="button hidden-sm">Modules</a>
<a href="flavors" class="button hidden-sm">Flavors</a> <a href="templates" class="button hidden-sm">Templates</a>
<a href="customization" class="button hidden-sm">Customization</a> <a href="quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<div class="container" style="padding-left: 0.25rem;">
<div class="row"> <input type="checkbox" id="navigation-toggle"> <nav class="drawer col-md-4 col-lg-2">
<label class="close" for="navigation-toggle"></label>
<a href="index"><h4 style="margin-left: 0;">Introduction</h4></a>
<h4 style="margin-left: 0;">Modules</h4> <a href="core#core-title">Core</a>
<a href="core#typography" class="sublink-1">Typography</a> <a href="core#headings" class="sublink-1">Headings</a>
<a href="core#common-textual-elements" class="sublink-1">Common textual elements</a>
<a href="core#lists" class="sublink-1">Lists</a> <a href="core#images-captions" class="sublink-1">Image responsiveness &amp; captions</a>
<br/> <a href="grid#grid-title">Grid</a>
<a href="grid#basic-layout" class="sublink-1">Basic layout</a> <a href="grid#screen-specific-layout" class="sublink-1">Screen specific layouts</a>
<a href="grid#predefined-layout" class="sublink-1">Predefined layouts</a> <a href="grid#column-offset" class="sublink-1">Column offsets</a>
<a href="grid#column-reorder" class="sublink-1">Column reordering</a> <a href="grid#media-object" class="sublink-1">Media object pattern</a>
<br/> <a href="input_control#input-control-title">Input Control</a>
<a href="input_control#forms-input" class="sublink-1">Forms &amp; input</a> <a href="input_control#checkbox-radio" class="sublink-1">Checkboxes &amp; radio buttons</a> <a href="input_control#switches" class="sublink-1">Switches</a>
<a href="input_control#buttons" class="sublink-1">Buttons &amp; button groups</a> <a href="input_control#file-upload" class="sublink-1">File upload buttons</a>
<br/> <a href="navigation#navigation-title">Navigation</a>
<a href="navigation#header" class="sublink-1">Header</a> <a href="navigation#navigation-bar" class="sublink-1">Navigation bar</a> <a href="navigation#drawer" class="sublink-1">Drawer</a>
<a href="navigation#footer" class="sublink-1">Footer</a> <a href="navigation#sticky" class="sublink-1">Sticky headers &amp; footers</a>
<br/> <a href="table#table-title">Table</a>
<a href="table#syntax-responsiveness" class="sublink-1">Basic syntax &amp; responsiveness</a> <a href="table#scrollable-tables" class="sublink-1">Scrollable tables</a>
<a href="table#horizontal-tables" class="sublink-1">Horizontal tables</a> <a href="table#variants-matrices" class="sublink-1">Table variants &amp; matrices</a>
<br/> <a href="card#card-title">Card</a>
<a href="card#basic-syntax" class="sublink-1">Basic syntax</a> <a href="card#sections-media" class="sublink-1">Sections &amp; media</a>
<a href="card#sizing-fluidity" class="sublink-1">Card sizing &amp; fluidity</a> <a href="card#color-variants" class="sublink-1">Card color variants</a>
<br/> <a href="tab#tab-title">Tab</a>
<a href="tab#basic-syntax" class="sublink-1">Basic syntax</a> <a href="tab#stacked-tabs" class="sublink-1">Stacked tabs</a>
<br/> <a href="contextual#contextual-title">Contextual</a>
<a href="contextual#text-highlighting" class="sublink-1">Text highlighting</a> <a href="contextual#toasts" class="sublink-1">Toasts</a>
<a href="contextual#tooltips" class="sublink-1">Tooltips</a> <a href="contextual#modals" class="sublink-1">Modals</a>
<br/> <a href="progress#progress-title">Progress</a>
<a href="progress#basic-progress-bar" class="sublink-1">Basic progress bar</a> <a href="progress#progress-variants" class="sublink-1">Progress bar variants</a>
<a href="progress#donut-spinner" class="sublink-1">Donut spinner</a> <a href="progress#spinner-variants" class="sublink-1">Donut spinner variants</a>
<br/> <a href="utility#utility-title">Utility</a>
<a href="utility#visibility-helpers" class="sublink-1">Visibility helpers</a> <a href="utility#borders-shadows" class="sublink-1">Generic borders &amp; shadows</a>
<a href="utility#responsive-sizing" class="sublink-1">Responsive sizing &amp; spacing classes</a>
<a href="utility#responsive-visibility" class="sublink-1">Responsive visibility helpers</a> <a href="utility#breadcrumbs" class="sublink-1">Breadcrumbs</a>
<a href="utility#close-icon" class="sublink-1">Close icon</a>
<a href="flavors"><h4 style="margin-left: 0;">Flavors</h4></a>
<a href="templates"><h4 style="margin-left: 0;">Templates</h4></a>
<a href="customization"><h4 style="margin-left: 0;">Customization</h4></a>
<a href="quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<div class="col-sm-12 col-md-8 col-lg-10"><main>
<div class="row" style="padding-top: 40px;" id="progress-title">
<div class="col-sm-12">
<h1>Progress</h1>
<p style="text-align:justify">The <strong>progress</strong> module gives you full control over the presentation of progress and loading on your pages. Apart from progress bars and color variants for them, spinner elements are provided to help communicate that something is loading.</p>
<p style="text-align:justify"><small>All examples showcased refer to the mini-default flavor, some class names and styles might differ based on the flavor you're using.</small></p><br/>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<div class="card fluid">
<div class="section">
<h2>Quick overview</h2>
<p style="text-align:justify">Progress indicators are very common UI elements for almost any website and web app, as they help communicate vital information such as the fact that a process is being executed in the background, informing the user that they should wait for it to complete before proceeding. The <strong>progress</strong> module provides you with two essential tools to communicate this information: the <code>&lt;progress&gt;</code> HTML element, which is pre-styled and compatible with modern browsers to help you communicate information about the percentage of a task and the <code>.spinner-donut</code> class that allows you to create an animated spinner that communicates that something is loading currently and will continue doing so for an indefinite amount of time. Both elements come with their own color and size variants and are fully accessible.</p><br>
</div>
<div class="section">
<h2>Quick start</h2>
<p style="text-align:justify">To use the <strong>progress</strong> module, simply include the link to the flavor you are using and start writing your HTML page as usual. One suggestion we will make is to add the following line inside your HTML page's <code>&lt;head&gt;</code> to utilize the viewport meta tag:</p>
<pre>&lt;<span class="fore-tertiary">meta</span> <span class="fore-secondary">name</span>=<span class="fore-primary">&quot;viewport&quot;</span> <span class="fore-secondary">content</span>=<span class="fore-primary">&quot;width=device-width, initial-scale=1&quot;</span>&gt;</pre><br>
</div>
</div>
</div>
</div>
<div class="row" id="basic-progress-bar">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Basic progress bar</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<p>Process is 0% complete!</p> <progress value="0" max="1000"></progress>
<p>Process is 45% complete!</p> <progress value="450" max="1000"></progress>
<p>Process is 100% complete!</p> <progress value="1000" max="1000"></progress>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align:justify">To create a progress bar, use the <code>&lt;progress&gt;</code> HTML element, specify the preset maximum of <code><span class="fore-secondary">max</span>=<span class="fore-primary">&quot;1000&quot;</span></code> and set a <code>value</code> between <code>0</code> and <code>1000</code>. Update your <code>&lt;progress&gt;</code> element using some Javascript code, by changing its <code>value</code> to any integer in the same range.</p>
<h3>Sample code</h3>
<pre>&lt;progress value=&quot;0&quot; max=&quot;1000&quot;&gt;&lt;/progress&gt;
&lt;progress value=&quot;450&quot; max=&quot;1000&quot;&gt;&lt;/progress&gt;
&lt;progress value=&quot;1000&quot; max=&quot;1000&quot;&gt;&lt;/progress&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>We made sure that the <code>&lt;progress&gt;</code> element displays properly on all modern browsers, using browser-specific rules. However, there might be some irregularities with older browsers, especially legacy versions of Internet Explorer.</li>
<li>If the preset <code>max="1000"</code> does not suit your needs, you should check the <a href="customization">customization page</a> for instructions on how to set your own maximum value for the <code>&lt;progress&gt;</code> element.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;progress value=&quot;80&quot; max=&quot;100&quot;&gt;&lt;/progress&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid using different values for the <code>&lt;progress&gt;</code> element's <code>max</code>, except for the preset one (<code>1000</code>).</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;progress value=&quot;450.5&quot; max=&quot;1000.0&quot;&gt;&lt;/progress&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Try not to use floating point values for either the <code>&lt;progress&gt;</code> element's <code>value</code> or <code>max</code>. During testing of the module, we found that floating point values could cause unexpected behavior.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="progress-variants">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Progress bar variants</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<p>Secondary process is 60% complete!</p> <progress class="secondary" value="600" max="1000"></progress>
<p>Tertiary process is 30% complete!</p> <progress class="tertiary" value="300" max="1000"></progress>
<p>Inline progress bar:<progress class="inline" value="150" max="1000"></progress></p>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align:justify">Apart from the default style for the <code>&lt;progress&gt;</code> element, we have also included a couple of variants for it. As with many other elements, you can change the color of your progress bars, based on the context, using the <code>.secondary</code> or <code>.tertiary</code> class. You can also make a <code>&lt;progress&gt;</code> element display inline, using the <code>.inline</code> class.</p>
<h3>Sample code</h3>
<pre>&lt;progress class=&quot;secondary&quot; value=&quot;600&quot; max=&quot;1000&quot;&gt;&lt;/progress&gt;
&lt;progress class=&quot;tertiary&quot; value=&quot;300&quot; max=&quot;1000&quot;&gt;&lt;/progress&gt;
&lt;progress class=&quot;inline&quot; value=&quot;150&quot; max=&quot;1000&quot;&gt;&lt;/progress&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>If you want to add your own custom size classes for <code>&lt;progress&gt;</code> elements, check the <a href="customization">customization page</a> for instructions.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;progress class=&quot;inline secondary&quot; value=&quot;800&quot; max=&quot;1000&quot;&gt;&lt;/progress&gt;
<span class="fore-tertiary">&lt;!-- or --&gt;</span>
&lt;progress class=&quot;inline tertiary&quot; value=&quot;650&quot; max=&quot;1000&quot;&gt;&lt;/progress&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;You can mix size and color classes for <code>&lt;progress&gt;</code> elements as needed.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;progress class=&quot;secondary teriary&quot; value=&quot;450&quot; max=&quot;1000&quot;&gt;&lt;/progress&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid mixing two classes of the same type (i.e. two color classes or two size classes).</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="donut-spinner">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Donut spinner</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<div class="box-centered"><br>
<div class="spinner-donut"></div><br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align:justify">Donut spinners can be used to indicate that something is loading or that a process is running in the background. To create a donut spinner, add the <code>.spinner-donut</code> class to an element of your liking. We would recommend using a <code>&lt;div&gt;</code> element for most cases, but <code>&lt;span&gt;</code> elements should work pretty well, too.</p>
<h3>Sample code</h3>
<pre>&lt;div class=&quot;spinner-donut&quot;&gt;&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>The <code>.spinner-donut</code> is an animated component, meaning that if a browsers does not support animation, this element might display incorrectly.</li>
<li>In certain cases, it might be useful to add the <code><span class="fore-secondary">role</span>=<span class="fore-primary">&quot;<a href="https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/ARIA_Techniques/Using_the_progressbar_role">progressbar</a>&quot;</span></code> attribute to increase donut spinner accessibility.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;p&gt;Loading... &lt;span class=&quot;spinner-donut&quot;&gt;&lt;/span&gt;&lt;/p&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;You can place a <code>.spinner-donut</code> inside a paragraph or some other textual context and it will display inline.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;div class=&quot;spinner-donut&quot;&gt;Loading...&lt;/div&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid inserting text inside the <code>.spinner-donut</code>, as this might cause unexpected bahavior and will probably make the text spin along with it.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="spinner-variants">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Donut spinner variants</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<div class="box-centered"><br>
<div class="spinner-donut secondary"></div><br> <div class="spinner-donut tertiary"></div><br> <div class="spinner-donut large"></div><br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align:justify">Apart from the default donut spinner style, there are also two more contextual color classes: <code>.secondary</code> and <code>.tertiary</code>. If your donut spinners are too small, you can also use the <code>.large</code> class to make it pop out a little bit more.</p>
<h3>Sample code</h3>
<pre>&lt;div class=&quot;spinner-donut secondary&quot;&gt;&lt;/div&gt;
&lt;div class=&quot;spinner-donut tertiary&quot;&gt;&lt;/div&gt;
&lt;div class=&quot;spinner-donut large&quot;&gt;&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>You can mix one of the contextual color classes and the <code>.large</code> class, if you want, similarly to what you can do with progress bars.</li>
</ul>
</div>
</div>
</div>
</div>
<div class="row" style="padding-bottom: 20px; padding-top:20px;">
<div class="col-sm-12">
<p style="text-align:justify">If you want to learn more about <strong>mini.css</strong>'s modules, go back to the <a href="modules">modules page</a> and choose another module to see its documentation.</p>
</div>
</div>
</main></div></div></div>
<footer style="text-align:justify"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<title>mini.css - Progress</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, module, progress ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-centered { text-align: center; } .box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;}
.box-colored.red { background: #e53935; } @media (max-width: 767px){.container {padding: 0.25rem !important;}.col-sm-12.col-md-8.col-lg-10{padding: 0 !important;}}
.box-centered > .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto; } [class^='col-'] .card.fluid { margin: 2px 0 20px; }
[class^='fore-'] { font-family: monospace, monospace;} .fore-primary { color: #0d47a1;} .fore-secondary { color: #b71c1c;} .fore-tertiary { color: #1b5e20;}
.col-sm-12.col-sm-last.col-md-4.col-md-normal {box-sizing: border-box;border-right: 1px solid #c9c9c9;}
@media (max-width: 767px){.col-sm-12.col-sm-last.col-md-4.col-md-normal { border: 0;border-top: 1px solid #c9c9c9;}}
.box-colored.green { background: #689f38; } .do {border-top: 15px solid #689f38;padding-top: 10px;} .dont {border-top: 15px solid #e53935;padding-top: 10px;}
.box-colored {color: #f5f5f5;} @media screen and (min-width: 768px) { .drawer { margin-top: 4px;}}
</style>
</head>
<body>
<header class="sticky">
<a href="index" class="logo"><span id="header-logo">m</span></a>
<label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="index" class="button hidden-sm">Introduction</a> <a href="modules" class="button hidden-sm">Modules</a>
<a href="flavors" class="button hidden-sm">Flavors</a> <a href="templates" class="button hidden-sm">Templates</a>
<a href="customization" class="button hidden-sm">Customization</a> <a href="quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<div class="container" style="padding-left: 0.25rem;">
<div class="row"> <input type="checkbox" id="navigation-toggle"> <nav class="drawer col-md-4 col-lg-2">
<label class="close" for="navigation-toggle"></label>
<a href="index"><h4 style="margin-left: 0;">Introduction</h4></a>
<h4 style="margin-left: 0;">Modules</h4> <a href="core#core-title">Core</a>
<a href="core#typography" class="sublink-1">Typography</a> <a href="core#headings" class="sublink-1">Headings</a>
<a href="core#common-textual-elements" class="sublink-1">Common textual elements</a>
<a href="core#lists" class="sublink-1">Lists</a> <a href="core#images-captions" class="sublink-1">Image responsiveness &amp; captions</a>
<br/> <a href="grid#grid-title">Grid</a>
<a href="grid#basic-layout" class="sublink-1">Basic layout</a> <a href="grid#screen-specific-layout" class="sublink-1">Screen specific layouts</a>
<a href="grid#predefined-layout" class="sublink-1">Predefined layouts</a> <a href="grid#column-offset" class="sublink-1">Column offsets</a>
<a href="grid#column-reorder" class="sublink-1">Column reordering</a> <a href="grid#media-object" class="sublink-1">Media object pattern</a>
<br/> <a href="input_control#input-control-title">Input Control</a>
<a href="input_control#forms-input" class="sublink-1">Forms &amp; input</a> <a href="input_control#checkbox-radio" class="sublink-1">Checkboxes &amp; radio buttons</a> <a href="input_control#switches" class="sublink-1">Switches</a>
<a href="input_control#buttons" class="sublink-1">Buttons &amp; button groups</a> <a href="input_control#file-upload" class="sublink-1">File upload buttons</a>
<br/> <a href="navigation#navigation-title">Navigation</a>
<a href="navigation#header" class="sublink-1">Header</a> <a href="navigation#navigation-bar" class="sublink-1">Navigation bar</a> <a href="navigation#drawer" class="sublink-1">Drawer</a>
<a href="navigation#footer" class="sublink-1">Footer</a> <a href="navigation#sticky" class="sublink-1">Sticky headers &amp; footers</a>
<br/> <a href="table#table-title">Table</a>
<a href="table#syntax-responsiveness" class="sublink-1">Basic syntax &amp; responsiveness</a> <a href="table#scrollable-tables" class="sublink-1">Scrollable tables</a>
<a href="table#horizontal-tables" class="sublink-1">Horizontal tables</a> <a href="table#variants-matrices" class="sublink-1">Table variants &amp; matrices</a>
<br/> <a href="card#card-title">Card</a>
<a href="card#basic-syntax" class="sublink-1">Basic syntax</a> <a href="card#sections-media" class="sublink-1">Sections &amp; media</a>
<a href="card#sizing-fluidity" class="sublink-1">Card sizing &amp; fluidity</a> <a href="card#color-variants" class="sublink-1">Card color variants</a>
<br/> <a href="tab#tab-title">Tab</a>
<a href="tab#basic-syntax" class="sublink-1">Basic syntax</a> <a href="tab#stacked-tabs" class="sublink-1">Stacked tabs</a>
<br/> <a href="contextual#contextual-title">Contextual</a>
<a href="contextual#text-highlighting" class="sublink-1">Text highlighting</a> <a href="contextual#toasts" class="sublink-1">Toasts</a>
<a href="contextual#tooltips" class="sublink-1">Tooltips</a> <a href="contextual#modals" class="sublink-1">Modals</a>
<br/> <a href="progress#progress-title">Progress</a>
<a href="progress#basic-progress-bar" class="sublink-1">Basic progress bar</a> <a href="progress#progress-variants" class="sublink-1">Progress bar variants</a>
<a href="progress#donut-spinner" class="sublink-1">Donut spinner</a> <a href="progress#spinner-variants" class="sublink-1">Donut spinner variants</a>
<br/> <a href="utility#utility-title">Utility</a>
<a href="utility#visibility-helpers" class="sublink-1">Visibility helpers</a> <a href="utility#borders-shadows" class="sublink-1">Generic borders &amp; shadows</a>
<a href="utility#responsive-sizing" class="sublink-1">Responsive sizing &amp; spacing classes</a>
<a href="utility#responsive-visibility" class="sublink-1">Responsive visibility helpers</a> <a href="utility#breadcrumbs" class="sublink-1">Breadcrumbs</a>
<a href="utility#close-icon" class="sublink-1">Close icon</a>
<a href="flavors"><h4 style="margin-left: 0;">Flavors</h4></a>
<a href="templates"><h4 style="margin-left: 0;">Templates</h4></a>
<a href="customization"><h4 style="margin-left: 0;">Customization</h4></a>
<a href="quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<div class="col-sm-12 col-md-8 col-lg-10"><main>
<div class="row" style="padding-top: 40px;" id="progress-title">
<div class="col-sm-12">
<h1>Progress</h1>
<p style="text-align:justify">The <strong>progress</strong> module gives you full control over the presentation of progress and loading on your pages. Apart from progress bars and color variants for them, spinner elements are provided to help communicate that something is loading.</p>
<p style="text-align:justify"><small>All examples showcased refer to the mini-default flavor, some class names and styles might differ based on the flavor you're using.</small></p><br/>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<div class="card fluid">
<div class="section">
<h2>Quick overview</h2>
<p style="text-align:justify">Progress indicators are very common UI elements for almost any website and web app, as they help communicate vital information such as the fact that a process is being executed in the background, informing the user that they should wait for it to complete before proceeding. The <strong>progress</strong> module provides you with two essential tools to communicate this information: the <code>&lt;progress&gt;</code> HTML element, which is pre-styled and compatible with modern browsers to help you communicate information about the percentage of a task and the <code>.spinner-donut</code> class that allows you to create an animated spinner that communicates that something is loading currently and will continue doing so for an indefinite amount of time. Both elements come with their own color and size variants and are fully accessible.</p><br>
</div>
<div class="section">
<h2>Quick start</h2>
<p style="text-align:justify">To use the <strong>progress</strong> module, simply include the link to the flavor you are using and start writing your HTML page as usual. One suggestion we will make is to add the following line inside your HTML page's <code>&lt;head&gt;</code> to utilize the viewport meta tag:</p>
<pre>&lt;<span class="fore-tertiary">meta</span> <span class="fore-secondary">name</span>=<span class="fore-primary">&quot;viewport&quot;</span> <span class="fore-secondary">content</span>=<span class="fore-primary">&quot;width=device-width, initial-scale=1&quot;</span>&gt;</pre><br>
</div>
</div>
</div>
</div>
<div class="row" id="basic-progress-bar">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Basic progress bar</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<p>Process is 0% complete!</p> <progress value="0" max="1000"></progress>
<p>Process is 45% complete!</p> <progress value="450" max="1000"></progress>
<p>Process is 100% complete!</p> <progress value="1000" max="1000"></progress>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align:justify">To create a progress bar, use the <code>&lt;progress&gt;</code> HTML element, specify the preset maximum of <code><span class="fore-secondary">max</span>=<span class="fore-primary">&quot;1000&quot;</span></code> and set a <code>value</code> between <code>0</code> and <code>1000</code>. Update your <code>&lt;progress&gt;</code> element using some Javascript code, by changing its <code>value</code> to any integer in the same range.</p>
<h3>Sample code</h3>
<pre>&lt;progress value=&quot;0&quot; max=&quot;1000&quot;&gt;&lt;/progress&gt;
&lt;progress value=&quot;450&quot; max=&quot;1000&quot;&gt;&lt;/progress&gt;
&lt;progress value=&quot;1000&quot; max=&quot;1000&quot;&gt;&lt;/progress&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>We made sure that the <code>&lt;progress&gt;</code> element displays properly on all modern browsers, using browser-specific rules. However, there might be some irregularities with older browsers, especially legacy versions of Internet Explorer.</li>
<li>If the preset <code>max="1000"</code> does not suit your needs, you should check the <a href="customization">customization page</a> for instructions on how to set your own maximum value for the <code>&lt;progress&gt;</code> element.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;progress value=&quot;80&quot; max=&quot;100&quot;&gt;&lt;/progress&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid using different values for the <code>&lt;progress&gt;</code> element's <code>max</code>, except for the preset one (<code>1000</code>).</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;progress value=&quot;450.5&quot; max=&quot;1000.0&quot;&gt;&lt;/progress&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Try not to use floating point values for either the <code>&lt;progress&gt;</code> element's <code>value</code> or <code>max</code>. During testing of the module, we found that floating point values could cause unexpected behavior.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="progress-variants">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Progress bar variants</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<p>Secondary process is 60% complete!</p> <progress class="secondary" value="600" max="1000"></progress>
<p>Tertiary process is 30% complete!</p> <progress class="tertiary" value="300" max="1000"></progress>
<p>Inline progress bar:<progress class="inline" value="150" max="1000"></progress></p>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align:justify">Apart from the default style for the <code>&lt;progress&gt;</code> element, we have also included a couple of variants for it. As with many other elements, you can change the color of your progress bars, based on the context, using the <code>.secondary</code> or <code>.tertiary</code> class. You can also make a <code>&lt;progress&gt;</code> element display inline, using the <code>.inline</code> class.</p>
<h3>Sample code</h3>
<pre>&lt;progress class=&quot;secondary&quot; value=&quot;600&quot; max=&quot;1000&quot;&gt;&lt;/progress&gt;
&lt;progress class=&quot;tertiary&quot; value=&quot;300&quot; max=&quot;1000&quot;&gt;&lt;/progress&gt;
&lt;progress class=&quot;inline&quot; value=&quot;150&quot; max=&quot;1000&quot;&gt;&lt;/progress&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>If you want to add your own custom size classes for <code>&lt;progress&gt;</code> elements, check the <a href="customization">customization page</a> for instructions.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;progress class=&quot;inline secondary&quot; value=&quot;800&quot; max=&quot;1000&quot;&gt;&lt;/progress&gt;
<span class="fore-tertiary">&lt;!-- or --&gt;</span>
&lt;progress class=&quot;inline tertiary&quot; value=&quot;650&quot; max=&quot;1000&quot;&gt;&lt;/progress&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;You can mix size and color classes for <code>&lt;progress&gt;</code> elements as needed.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;progress class=&quot;secondary teriary&quot; value=&quot;450&quot; max=&quot;1000&quot;&gt;&lt;/progress&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid mixing two classes of the same type (i.e. two color classes or two size classes).</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="donut-spinner">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Donut spinner</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<div class="box-centered"><br>
<div class="spinner-donut"></div><br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align:justify">Donut spinners can be used to indicate that something is loading or that a process is running in the background. To create a donut spinner, add the <code>.spinner-donut</code> class to an element of your liking. We would recommend using a <code>&lt;div&gt;</code> element for most cases, but <code>&lt;span&gt;</code> elements should work pretty well, too.</p>
<h3>Sample code</h3>
<pre>&lt;div class=&quot;spinner-donut&quot;&gt;&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>The <code>.spinner-donut</code> is an animated component, meaning that if a browsers does not support animation, this element might display incorrectly.</li>
<li>In certain cases, it might be useful to add the <code><span class="fore-secondary">role</span>=<span class="fore-primary">&quot;<a href="https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/ARIA_Techniques/Using_the_progressbar_role">progressbar</a>&quot;</span></code> attribute to increase donut spinner accessibility.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;p&gt;Loading... &lt;span class=&quot;spinner-donut&quot;&gt;&lt;/span&gt;&lt;/p&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;You can place a <code>.spinner-donut</code> inside a paragraph or some other textual context and it will display inline.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;div class=&quot;spinner-donut&quot;&gt;Loading...&lt;/div&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid inserting text inside the <code>.spinner-donut</code>, as this might cause unexpected bahavior and will probably make the text spin along with it.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="spinner-variants">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Donut spinner variants</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<div class="box-centered"><br>
<div class="spinner-donut secondary"></div><br> <div class="spinner-donut tertiary"></div><br> <div class="spinner-donut large"></div><br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align:justify">Apart from the default donut spinner style, there are also two more contextual color classes: <code>.secondary</code> and <code>.tertiary</code>. If your donut spinners are too small, you can also use the <code>.large</code> class to make it pop out a little bit more.</p>
<h3>Sample code</h3>
<pre>&lt;div class=&quot;spinner-donut secondary&quot;&gt;&lt;/div&gt;
&lt;div class=&quot;spinner-donut tertiary&quot;&gt;&lt;/div&gt;
&lt;div class=&quot;spinner-donut large&quot;&gt;&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>You can mix one of the contextual color classes and the <code>.large</code> class, if you want, similarly to what you can do with progress bars.</li>
</ul>
</div>
</div>
</div>
</div>
<div class="row" style="padding-bottom: 20px; padding-top:20px;">
<div class="col-sm-12">
<p style="text-align:justify">If you want to learn more about <strong>mini.css</strong>'s modules, go back to the <a href="modules">modules page</a> and choose another module to see its documentation.</p>
</div>
</div>
</main></div></div></div>
<footer style="text-align:justify"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>

File diff suppressed because it is too large Load diff

View file

@ -1,14 +1,14 @@
<!DOCTYPE html>
<html lang="en">
<head>
<title>mini.css - React and Preact Libraries</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, react, preact ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/react-mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<meta http-equiv="refresh" content="0; url=https://chalarangelo.github.io/react-mini.css/">
</head>
<!DOCTYPE html>
<html lang="en">
<head>
<title>mini.css - React and Preact Libraries</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, react, preact ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/react-mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<meta http-equiv="refresh" content="0; url=https://chalarangelo.github.io/react-mini.css/">
</head>

View file

@ -1,314 +1,314 @@
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<title>mini.css - Tab</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, module, tab, tabs ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-centered { text-align: center; } .box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;} .box-colored.red { background: #e53935; }
.box-centered > .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto; } [class^='col-'] .card.fluid { margin: 2px 0 20px; } @media (max-width: 767px){.container {padding: 0.25rem !important;}.col-sm-12.col-md-8.col-lg-10{padding: 0 !important;}}
[class^='fore-'] { font-family: monospace, monospace;} .fore-primary { color: #0d47a1;} .fore-secondary { color: #b71c1c;} .fore-tertiary { color: #1b5e20;}
.col-sm-12.col-sm-last.col-lg-4.col-md-normal {box-sizing: border-box;border-right: 1px solid #c9c9c9;}
.box-colored.green { background: #689f38; } .do {border-top: 15px solid #689f38;padding-top: 10px;} .dont {border-top: 15px solid #e53935;padding-top: 10px;}
.box-colored {color: #f5f5f5;} @media (max-width: 1279px){.col-sm-12.col-sm-last.col-md-12.col-md-normal {box-sizing: border-box; border: 0; border-bottom: 1px solid #c9c9c9;}}
@media (max-width: 767px){.col-sm-12.col-sm-last.col-md-12.col-md-normal {border: 0;border-top: 1px solid #c9c9c9;}}
@media screen and (min-width: 768px) { .drawer { margin-top: 4px;}}
</style>
</head>
<body>
<header class="sticky">
<a href="index" class="logo"><span id="header-logo">m</span></a>
<label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="index" class="button hidden-sm">Introduction</a> <a href="modules" class="button hidden-sm">Modules</a>
<a href="flavors" class="button hidden-sm">Flavors</a> <a href="templates" class="button hidden-sm">Templates</a>
<a href="customization" class="button hidden-sm">Customization</a> <a href="quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<div class="container" style="padding-left: 0.25rem;">
<div class="row"> <input type="checkbox" id="navigation-toggle"> <nav class="drawer col-md-4 col-lg-2">
<label class="close" for="navigation-toggle"></label>
<a href="index"><h4 style="margin-left: 0;">Introduction</h4></a>
<h4 style="margin-left: 0;">Modules</h4> <a href="core#core-title">Core</a>
<a href="core#typography" class="sublink-1">Typography</a> <a href="core#headings" class="sublink-1">Headings</a>
<a href="core#common-textual-elements" class="sublink-1">Common textual elements</a>
<a href="core#lists" class="sublink-1">Lists</a> <a href="core#images-captions" class="sublink-1">Image responsiveness &amp; captions</a>
<br/> <a href="grid#grid-title">Grid</a>
<a href="grid#basic-layout" class="sublink-1">Basic layout</a> <a href="grid#screen-specific-layout" class="sublink-1">Screen specific layouts</a>
<a href="grid#predefined-layout" class="sublink-1">Predefined layouts</a> <a href="grid#column-offset" class="sublink-1">Column offsets</a>
<a href="grid#column-reorder" class="sublink-1">Column reordering</a> <a href="grid#media-object" class="sublink-1">Media object pattern</a>
<br/> <a href="input_control#input-control-title">Input Control</a>
<a href="input_control#forms-input" class="sublink-1">Forms &amp; input</a> <a href="input_control#checkbox-radio" class="sublink-1">Checkboxes &amp; radio buttons</a> <a href="input_control#switches" class="sublink-1">Switches</a>
<a href="input_control#buttons" class="sublink-1">Buttons &amp; button groups</a> <a href="input_control#file-upload" class="sublink-1">File upload buttons</a>
<br/> <a href="navigation#navigation-title">Navigation</a>
<a href="navigation#header" class="sublink-1">Header</a> <a href="navigation#navigation-bar" class="sublink-1">Navigation bar</a> <a href="navigation#drawer" class="sublink-1">Drawer</a>
<a href="navigation#footer" class="sublink-1">Footer</a> <a href="navigation#sticky" class="sublink-1">Sticky headers &amp; footers</a>
<br/> <a href="table#table-title">Table</a>
<a href="table#syntax-responsiveness" class="sublink-1">Basic syntax &amp; responsiveness</a> <a href="table#scrollable-tables" class="sublink-1">Scrollable tables</a>
<a href="table#horizontal-tables" class="sublink-1">Horizontal tables</a> <a href="table#variants-matrices" class="sublink-1">Table variants &amp; matrices</a>
<br/> <a href="card#card-title">Card</a>
<a href="card#basic-syntax" class="sublink-1">Basic syntax</a> <a href="card#sections-media" class="sublink-1">Sections &amp; media</a>
<a href="card#sizing-fluidity" class="sublink-1">Card sizing &amp; fluidity</a> <a href="card#color-variants" class="sublink-1">Card color variants</a>
<br/> <a href="tab#tab-title">Tab</a>
<a href="tab#basic-syntax" class="sublink-1">Basic syntax</a> <a href="tab#stacked-tabs" class="sublink-1">Stacked tabs</a>
<br/> <a href="contextual#contextual-title">Contextual</a>
<a href="contextual#text-highlighting" class="sublink-1">Text highlighting</a> <a href="contextual#toasts" class="sublink-1">Toasts</a>
<a href="contextual#tooltips" class="sublink-1">Tooltips</a> <a href="contextual#modals" class="sublink-1">Modals</a>
<br/> <a href="progress#progress-title">Progress</a>
<a href="progress#basic-progress-bar" class="sublink-1">Basic progress bar</a> <a href="progress#progress-variants" class="sublink-1">Progress bar variants</a>
<a href="progress#donut-spinner" class="sublink-1">Donut spinner</a> <a href="progress#spinner-variants" class="sublink-1">Donut spinner variants</a>
<br/> <a href="utility#utility-title">Utility</a>
<a href="utility#visibility-helpers" class="sublink-1">Visibility helpers</a> <a href="utility#borders-shadows" class="sublink-1">Generic borders &amp; shadows</a>
<a href="utility#responsive-sizing" class="sublink-1">Responsive sizing &amp; spacing classes</a>
<a href="utility#responsive-visibility" class="sublink-1">Responsive visibility helpers</a> <a href="utility#breadcrumbs" class="sublink-1">Breadcrumbs</a>
<a href="utility#close-icon" class="sublink-1">Close icon</a>
<a href="flavors"><h4 style="margin-left: 0;">Flavors</h4></a>
<a href="templates"><h4 style="margin-left: 0;">Templates</h4></a>
<a href="customization"><h4 style="margin-left: 0;">Customization</h4></a>
<a href="quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<div class="col-sm-12 col-md-8 col-lg-10"><main>
<div class="row" style="padding-top: 40px;" id="tab-title">
<div class="col-sm-12">
<h1>Tab</h1>
<p style="text-align:justify">The <strong>tab</strong> module aims to combine multiple components and design paradigms, like collapses, accordions, carousels and tabs, into one general-purpose component. Tabs are very simple in structure, responsive on mobile and they allow for layout customization so that you can turn them into accordions or collapses whenever you want.</p>
<p style="text-align:justify"><small>All examples showcased refer to the mini-default flavor, some class names and styles might differ based on the flavor you're using.</small></p><br/>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<div class="card fluid">
<div class="section">
<h2>Quick overview</h2>
<p style="text-align:justify">Spoilers, collapses, accordions, tabs, carousels have been a staple of modern design for quite a long time. All of these elements are implemented using the <strong>tab</strong> module's single generic container. The tab container replaces all of these design paradigms with one component that is very flexible and responsive in order to let you present your website or app's content any way you like. Tabbed navigation is very easy to implement, while collapse, accordion and carousel components use the stacked architecture of tabs. As usual, the tab container is responsive and accessible, allowing you to deliver your content properly to all devices and users.</p><br>
</div>
<div class="section">
<h2>Quick start</h2>
<p style="text-align:justify">To use the <strong>tab</strong> module, simply include the link to the flavor you are using and start writing your HTML page as usual. One suggestion we will make is to add the following line inside your HTML page's <code>&lt;head&gt;</code> to utilize the viewport meta tag:</p>
<pre>&lt;<span class="fore-tertiary">meta</span> <span class="fore-secondary">name</span>=<span class="fore-primary">&quot;viewport&quot;</span> <span class="fore-secondary">content</span>=<span class="fore-primary">&quot;width=device-width, initial-scale=1&quot;</span>&gt;</pre><br>
</div>
</div>
</div>
</div>
<div class="row" id="basic-syntax">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Basic syntax</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal col-lg-4">
<div class="tabs" style="margin-top: 5px; margin-bottom: 5px;">
<input type="radio" name="tabdemo" id="tab1" checked aria-hidden="true">
<label for="tab1" aria-hidden="true">Tab 1</label>
<div> <h3>Tab 1</h3> <p>This is the first tab's content.</p> </div>
<input type="radio" name="tabdemo" id="tab2" aria-hidden="true">
<label for="tab2" aria-hidden="true">Tab 2</label>
<div> <h3>Tab 2</h3> <p>This is the second tab's content.</p> </div>
<input type="radio" name="tabdemo" id="tab3" aria-hidden="true">
<label for="tab3" aria-hidden="true">Tab 3</label>
<div> <h3>Tab 3</h3> <p>This is the third tab's content.</p> </div>
<input type="radio" name="tabdemo" id="tab4" aria-hidden="true">
<label for="tab4" aria-hidden="true">Tab 4</label>
<div> <h3>Tab 4</h3> <p>This is the fourth tab's content.</p> </div>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal col-lg-8">
<p style="text-align:justify">The tab container's basic syntax is composed of two components, presented below in the order they should be added to the DOM tree:</p>
<ul style="text-align:justify">
<li>At the outermost level of the tab container is a <code>&lt;div&gt;</code> element implementing the <code>.tabs</code> class. This serves as the wrapper of the tab container.</li>
<li>Inside the <code>.tabs</code> container, add a set of the following three elements for each tab:
<ol>
<li>First, add an <code>&lt;input <span class="fore-secondary">type</span>=<span class="fore-primary">&quot;radio&quot;</span>&gt;</code> element. Give it a <code><span class="fore-secondary">name</span></code> and an <code><span class="fore-secondary">id</span></code> in order to be able to link to it and group it with the rest of the radio buttons in the container.</li>
<li>Follow the <code>&lt;input&gt;</code> element with a <code>&lt;label&gt;</code> element linking to it. Inside this element, add the text you want to be shown as the title of your tab.</li>
<li>Finally, add a <code>&lt;div&gt;</code> immediately after the <code>&lt;label&gt;</code>'s closing tag. This will be the panel that contains the tab's content. Inside this element, you can add all the content you want in your tab (headings, images, text).</li>
</ol>
</li>
</ul>
<p style="text-align:justify">Tabs are responsive and will collapse into a stacked display on smaller screens, allowing the user to view the actual content more easily. The tab container's syntax is accessible, but parts of it might confuse screen readers, so we suggest adding the <code><span class="fore-secondary">aria-hidden</span>=<span class="fore-primary">&quot;true&quot;</span></code> attribute to all the <code>&lt;input&gt;</code> and <code>&lt;label&gt;</code> elements inside the <code>.tabs</code> container.</p>
<h3>Sample code</h3>
<pre>&lt;div class=&quot;tabs&quot;&gt;
&lt;input type=&quot;radio&quot; name=&quot;tab-group&quot; id=&quot;tab1&quot; checked aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;tab1&quot; aria-hidden=&quot;true&quot;&gt;Tab 1&lt;/label&gt;
&lt;div&gt;
&lt;h3&gt;Tab 1&lt;/h3&gt;
&lt;p&gt;This is the first tab's content.&lt;/p&gt;
&lt;/div&gt;
&lt;input type=&quot;radio&quot; name=&quot;tab-group&quot; id=&quot;tab2&quot; aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;tab2&quot; aria-hidden=&quot;true&quot;&gt;Tab 2&lt;/label&gt;
&lt;div&gt;
&lt;h3&gt;Tab 2&lt;/h3&gt;
&lt;p&gt;This is the second tab's content.&lt;/p&gt;
&lt;/div&gt;
&lt;input type=&quot;radio&quot; name=&quot;tab-group&quot; id=&quot;tab3&quot; aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;tab3&quot; aria-hidden=&quot;true&quot;&gt;Tab 3&lt;/label&gt;
&lt;div&gt;
&lt;h3&gt;Tab 3&lt;/h3&gt;
&lt;p&gt;This is the third tab's content.&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>Tabs are compatible with modern browsers, but might not display properly in older browsers.</li>
<li>Remember to add the <code><span class="fore-secondary">checked</span></code> attribute to one of your <code>&lt;input&gt;</code>s if you want that tab to be the one displayed by default. If none is specified, the first one will be displayed.</li>
<li>The <code>height</code> of the tab container's panel area is <code>400px</code>. If you want to change this default size, please check out the <a href="customization">customization</a> page.</li>
<li>Using the method described above for making tabs accessible, screen readers will ignore tab controls and only read the content of tabs.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;div class=&quot;tabs&quot;&gt;
&lt;input type=&quot;checkbox&quot; name=&quot;tab-group&quot; id=&quot;tab1&quot; checked aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;tab1&quot; aria-hidden=&quot;true&quot;&gt;Tab 1&lt;/label&gt;
&lt;div&gt;
&lt;h3&gt;Bad Tab&lt;/h3&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Do not use checkboxes inside the default <code>.tabs</code> container, otherwise you might notice unexpected behavior. If you want to use an <code>&lt;input <span class="fore-secondary">type</span>=<span class="fore-primary">&quot;checkbox&quot;</span>&gt;</code>, check out the next section.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;div class=&quot;tabs&quot;&gt;
&lt;input type=&quot;radio&quot; name=&quot;tab-group&quot; id=&quot;tab1&quot; checked aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;tab1&quot; aria-hidden=&quot;true&quot;&gt;Tab 1&lt;/label&gt;
&lt;div&gt;
&lt;h3&gt;Lonely Tab&lt;/h3&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;You can add a single tab in a <code>.tabs</code> container, but what use would that be? You should probably read the next section to see what you can do with a stacked tab container instead.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;div class=&quot;tabs&quot;&gt;
&lt;input type=&quot;radio&quot; name=&quot;tab-group&quot; id=&quot;tab1&quot; checked aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;tab1&quot; aria-hidden=&quot;true&quot;&gt;Tab 1&lt;/label&gt;
&lt;input type=&quot;radio&quot; name=&quot;tab-group&quot; id=&quot;tab2&quot; aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;tab2&quot; aria-hidden=&quot;true&quot;&gt;Tab 2&lt;/label&gt;
&lt;div&gt;
&lt;h3&gt;Bad Tab&lt;/h3&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;h3&gt;Bad Tab&lt;/h3&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;The syntax and structure of the tab container is very strict. Try to follow it exactly as described in this section.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;div class=&quot;tabs&quot;&gt;
&lt;input type=&quot;radio&quot; name=&quot;tab-group&quot; id=&quot;tab1&quot; checked&gt;
&lt;label for=&quot;tab1&quot;&gt;Tab&lt;/label&gt;
&lt;div&gt;
&lt;h3&gt;Not fully accessible tab&lt;/h3&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Remember to use the <code><span class="fore-secondary">aria-hidden</span>=<span class="fore-primary">&quot;true&quot;</span></code> attribute to make your tabs fully accessible.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="stacked-tabs">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Stacked tabs</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal col-lg-4">
<div class="tabs stacked" style="margin-top: 5px; margin-bottom: 5px;">
<input type="radio" name="accordion" id="a1" checked aria-hidden="true">
<label for="a1" aria-hidden="true">Accordion section 1</label>
<div> <h3>Section 1</h3> <p>This is the first accordion section's content.</p> </div>
<input type="radio" name="accordion" id="a2" aria-hidden="true">
<label for="a2" aria-hidden="true">Accordion section 2</label>
<div> <h3>Section 2</h3> <p>This is the second accordion section's content.</p> </div>
</div>
<div class="tabs stacked" style="margin-top: 5px; margin-bottom: 5px;">
<input type="checkbox" id="c1" aria-hidden="true">
<label for="c1" aria-hidden="true">Collapse section 1</label>
<div> <p>This is the first collapse section's content.</p> </div>
<input type="checkbox" id="c2" aria-hidden="true">
<label for="c2" aria-hidden="true">Collapse section 2</label>
<div> <p>This is the second collapse section's content.</p> </div>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal col-lg-8">
<p style="text-align:justify">Apart from the normal tab layout, you can make your tabs stacked instead, using the <code>.stacked</code> class in your <code>.tabs</code> container element. Stacked tabs are more versatile, allowing you to use checkboxes and/or radio buttons to implement collapses, accordions and spoilers. Carousel-styled elements can also be displayed in this fashion, if you wish. Remember to use the <code><span class="fore-secondary">aria-hidden</span>=<span class="fore-primary">&quot;true&quot;</span></code> attribute to make your tabs fully accessible, as before.</p>
<h3>Sample code</h3>
<pre>&lt;div class=&quot;tabs stacked&quot;&gt;
&lt;input type=&quot;radio&quot; name=&quot;accordion&quot; id=&quot;a1&quot; checked aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;a1&quot; aria-hidden=&quot;true&quot;&gt;Accordion section 1&lt;/label&gt;
&lt;div&gt;
&lt;h3&gt;Section 1&lt;/h3&gt;
&lt;p&gt;This is the first accordion section's content.&lt;/p&gt;
&lt;/div&gt;
&lt;input type=&quot;radio&quot; name=&quot;accordion&quot; id=&quot;a2&quot;aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;a2&quot; aria-hidden=&quot;true&quot;&gt;Accordion section 2&lt;/label&gt;
&lt;div&gt;
&lt;h3&gt;Section 2&lt;/h3&gt;
&lt;p&gt;This is the second accordion section's content.&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;tabs stacked&quot;&gt;
&lt;input type=&quot;checkbox&quot; id=&quot;c1&quot; aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;c1&quot; aria-hidden=&quot;true&quot;&gt;Collapse section 1&lt;/label&gt;
&lt;div&gt;
&lt;p&gt;This is the first collapse section's content.&lt;/p&gt;
&lt;/div&gt;
&lt;input type=&quot;checkbox&quot; id=&quot;c2&quot; aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;c2&quot; aria-hidden=&quot;true&quot;&gt;Collapse section 2&lt;/label&gt;
&lt;div&gt;
&lt;p&gt;This is the second collapse section's content.&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li><code>.stacked</code> tabs can be used with either checkboxes or radio buttons.</li>
<li>You can mix and match checkboxes and radio buttons, but we suggest you do not do so, unless you think it is necessary for your design.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;div class=&quot;tabs stacked&quot;&gt;
&lt;input type=&quot;checkbox&quot; id=&quot;c1&quot; aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;c1&quot; aria-hidden=&quot;true&quot;&gt;Single collapse&lt;/label&gt;
&lt;div&gt;
&lt;p&gt;This is a singular collapse.&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;You can implement single collapses (otherwise known as spoilers), using a <code>.tabs</code><code>.stacked</code> container with only one checkbox-based tab.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;div class=&quot;tabs stacked&quot;&gt;
&lt;input type=&quot;radio&quot; name=&quot;accordion&quot; id=&quot;a1&quot; checked aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;a1&quot; aria-hidden=&quot;true&quot;&gt;Single accordion section&lt;/label&gt;
&lt;div&gt;
&lt;p&gt;This accordion section cannot close once opened&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid having a single radio-based tab in a <code>.tabs</code><code>.stacked</code> container, as this might result in unexpected behavior.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" style="padding-bottom: 20px; padding-top:20px;">
<div class="col-sm-12">
<p style="text-align:justify">If you want to learn more about <strong>mini.css</strong>'s modules, go back to the <a href="modules">modules page</a> and choose another module to see its documentation.</p>
</div>
</div>
</main></div></div></div>
<footer style="text-align:justify"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<title>mini.css - Tab</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, module, tab, tabs ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-centered { text-align: center; } .box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;} .box-colored.red { background: #e53935; }
.box-centered > .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto; } [class^='col-'] .card.fluid { margin: 2px 0 20px; } @media (max-width: 767px){.container {padding: 0.25rem !important;}.col-sm-12.col-md-8.col-lg-10{padding: 0 !important;}}
[class^='fore-'] { font-family: monospace, monospace;} .fore-primary { color: #0d47a1;} .fore-secondary { color: #b71c1c;} .fore-tertiary { color: #1b5e20;}
.col-sm-12.col-sm-last.col-lg-4.col-md-normal {box-sizing: border-box;border-right: 1px solid #c9c9c9;}
.box-colored.green { background: #689f38; } .do {border-top: 15px solid #689f38;padding-top: 10px;} .dont {border-top: 15px solid #e53935;padding-top: 10px;}
.box-colored {color: #f5f5f5;} @media (max-width: 1279px){.col-sm-12.col-sm-last.col-md-12.col-md-normal {box-sizing: border-box; border: 0; border-bottom: 1px solid #c9c9c9;}}
@media (max-width: 767px){.col-sm-12.col-sm-last.col-md-12.col-md-normal {border: 0;border-top: 1px solid #c9c9c9;}}
@media screen and (min-width: 768px) { .drawer { margin-top: 4px;}}
</style>
</head>
<body>
<header class="sticky">
<a href="index" class="logo"><span id="header-logo">m</span></a>
<label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="index" class="button hidden-sm">Introduction</a> <a href="modules" class="button hidden-sm">Modules</a>
<a href="flavors" class="button hidden-sm">Flavors</a> <a href="templates" class="button hidden-sm">Templates</a>
<a href="customization" class="button hidden-sm">Customization</a> <a href="quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<div class="container" style="padding-left: 0.25rem;">
<div class="row"> <input type="checkbox" id="navigation-toggle"> <nav class="drawer col-md-4 col-lg-2">
<label class="close" for="navigation-toggle"></label>
<a href="index"><h4 style="margin-left: 0;">Introduction</h4></a>
<h4 style="margin-left: 0;">Modules</h4> <a href="core#core-title">Core</a>
<a href="core#typography" class="sublink-1">Typography</a> <a href="core#headings" class="sublink-1">Headings</a>
<a href="core#common-textual-elements" class="sublink-1">Common textual elements</a>
<a href="core#lists" class="sublink-1">Lists</a> <a href="core#images-captions" class="sublink-1">Image responsiveness &amp; captions</a>
<br/> <a href="grid#grid-title">Grid</a>
<a href="grid#basic-layout" class="sublink-1">Basic layout</a> <a href="grid#screen-specific-layout" class="sublink-1">Screen specific layouts</a>
<a href="grid#predefined-layout" class="sublink-1">Predefined layouts</a> <a href="grid#column-offset" class="sublink-1">Column offsets</a>
<a href="grid#column-reorder" class="sublink-1">Column reordering</a> <a href="grid#media-object" class="sublink-1">Media object pattern</a>
<br/> <a href="input_control#input-control-title">Input Control</a>
<a href="input_control#forms-input" class="sublink-1">Forms &amp; input</a> <a href="input_control#checkbox-radio" class="sublink-1">Checkboxes &amp; radio buttons</a> <a href="input_control#switches" class="sublink-1">Switches</a>
<a href="input_control#buttons" class="sublink-1">Buttons &amp; button groups</a> <a href="input_control#file-upload" class="sublink-1">File upload buttons</a>
<br/> <a href="navigation#navigation-title">Navigation</a>
<a href="navigation#header" class="sublink-1">Header</a> <a href="navigation#navigation-bar" class="sublink-1">Navigation bar</a> <a href="navigation#drawer" class="sublink-1">Drawer</a>
<a href="navigation#footer" class="sublink-1">Footer</a> <a href="navigation#sticky" class="sublink-1">Sticky headers &amp; footers</a>
<br/> <a href="table#table-title">Table</a>
<a href="table#syntax-responsiveness" class="sublink-1">Basic syntax &amp; responsiveness</a> <a href="table#scrollable-tables" class="sublink-1">Scrollable tables</a>
<a href="table#horizontal-tables" class="sublink-1">Horizontal tables</a> <a href="table#variants-matrices" class="sublink-1">Table variants &amp; matrices</a>
<br/> <a href="card#card-title">Card</a>
<a href="card#basic-syntax" class="sublink-1">Basic syntax</a> <a href="card#sections-media" class="sublink-1">Sections &amp; media</a>
<a href="card#sizing-fluidity" class="sublink-1">Card sizing &amp; fluidity</a> <a href="card#color-variants" class="sublink-1">Card color variants</a>
<br/> <a href="tab#tab-title">Tab</a>
<a href="tab#basic-syntax" class="sublink-1">Basic syntax</a> <a href="tab#stacked-tabs" class="sublink-1">Stacked tabs</a>
<br/> <a href="contextual#contextual-title">Contextual</a>
<a href="contextual#text-highlighting" class="sublink-1">Text highlighting</a> <a href="contextual#toasts" class="sublink-1">Toasts</a>
<a href="contextual#tooltips" class="sublink-1">Tooltips</a> <a href="contextual#modals" class="sublink-1">Modals</a>
<br/> <a href="progress#progress-title">Progress</a>
<a href="progress#basic-progress-bar" class="sublink-1">Basic progress bar</a> <a href="progress#progress-variants" class="sublink-1">Progress bar variants</a>
<a href="progress#donut-spinner" class="sublink-1">Donut spinner</a> <a href="progress#spinner-variants" class="sublink-1">Donut spinner variants</a>
<br/> <a href="utility#utility-title">Utility</a>
<a href="utility#visibility-helpers" class="sublink-1">Visibility helpers</a> <a href="utility#borders-shadows" class="sublink-1">Generic borders &amp; shadows</a>
<a href="utility#responsive-sizing" class="sublink-1">Responsive sizing &amp; spacing classes</a>
<a href="utility#responsive-visibility" class="sublink-1">Responsive visibility helpers</a> <a href="utility#breadcrumbs" class="sublink-1">Breadcrumbs</a>
<a href="utility#close-icon" class="sublink-1">Close icon</a>
<a href="flavors"><h4 style="margin-left: 0;">Flavors</h4></a>
<a href="templates"><h4 style="margin-left: 0;">Templates</h4></a>
<a href="customization"><h4 style="margin-left: 0;">Customization</h4></a>
<a href="quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<div class="col-sm-12 col-md-8 col-lg-10"><main>
<div class="row" style="padding-top: 40px;" id="tab-title">
<div class="col-sm-12">
<h1>Tab</h1>
<p style="text-align:justify">The <strong>tab</strong> module aims to combine multiple components and design paradigms, like collapses, accordions, carousels and tabs, into one general-purpose component. Tabs are very simple in structure, responsive on mobile and they allow for layout customization so that you can turn them into accordions or collapses whenever you want.</p>
<p style="text-align:justify"><small>All examples showcased refer to the mini-default flavor, some class names and styles might differ based on the flavor you're using.</small></p><br/>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<div class="card fluid">
<div class="section">
<h2>Quick overview</h2>
<p style="text-align:justify">Spoilers, collapses, accordions, tabs, carousels have been a staple of modern design for quite a long time. All of these elements are implemented using the <strong>tab</strong> module's single generic container. The tab container replaces all of these design paradigms with one component that is very flexible and responsive in order to let you present your website or app's content any way you like. Tabbed navigation is very easy to implement, while collapse, accordion and carousel components use the stacked architecture of tabs. As usual, the tab container is responsive and accessible, allowing you to deliver your content properly to all devices and users.</p><br>
</div>
<div class="section">
<h2>Quick start</h2>
<p style="text-align:justify">To use the <strong>tab</strong> module, simply include the link to the flavor you are using and start writing your HTML page as usual. One suggestion we will make is to add the following line inside your HTML page's <code>&lt;head&gt;</code> to utilize the viewport meta tag:</p>
<pre>&lt;<span class="fore-tertiary">meta</span> <span class="fore-secondary">name</span>=<span class="fore-primary">&quot;viewport&quot;</span> <span class="fore-secondary">content</span>=<span class="fore-primary">&quot;width=device-width, initial-scale=1&quot;</span>&gt;</pre><br>
</div>
</div>
</div>
</div>
<div class="row" id="basic-syntax">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Basic syntax</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal col-lg-4">
<div class="tabs" style="margin-top: 5px; margin-bottom: 5px;">
<input type="radio" name="tabdemo" id="tab1" checked aria-hidden="true">
<label for="tab1" aria-hidden="true">Tab 1</label>
<div> <h3>Tab 1</h3> <p>This is the first tab's content.</p> </div>
<input type="radio" name="tabdemo" id="tab2" aria-hidden="true">
<label for="tab2" aria-hidden="true">Tab 2</label>
<div> <h3>Tab 2</h3> <p>This is the second tab's content.</p> </div>
<input type="radio" name="tabdemo" id="tab3" aria-hidden="true">
<label for="tab3" aria-hidden="true">Tab 3</label>
<div> <h3>Tab 3</h3> <p>This is the third tab's content.</p> </div>
<input type="radio" name="tabdemo" id="tab4" aria-hidden="true">
<label for="tab4" aria-hidden="true">Tab 4</label>
<div> <h3>Tab 4</h3> <p>This is the fourth tab's content.</p> </div>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal col-lg-8">
<p style="text-align:justify">The tab container's basic syntax is composed of two components, presented below in the order they should be added to the DOM tree:</p>
<ul style="text-align:justify">
<li>At the outermost level of the tab container is a <code>&lt;div&gt;</code> element implementing the <code>.tabs</code> class. This serves as the wrapper of the tab container.</li>
<li>Inside the <code>.tabs</code> container, add a set of the following three elements for each tab:
<ol>
<li>First, add an <code>&lt;input <span class="fore-secondary">type</span>=<span class="fore-primary">&quot;radio&quot;</span>&gt;</code> element. Give it a <code><span class="fore-secondary">name</span></code> and an <code><span class="fore-secondary">id</span></code> in order to be able to link to it and group it with the rest of the radio buttons in the container.</li>
<li>Follow the <code>&lt;input&gt;</code> element with a <code>&lt;label&gt;</code> element linking to it. Inside this element, add the text you want to be shown as the title of your tab.</li>
<li>Finally, add a <code>&lt;div&gt;</code> immediately after the <code>&lt;label&gt;</code>'s closing tag. This will be the panel that contains the tab's content. Inside this element, you can add all the content you want in your tab (headings, images, text).</li>
</ol>
</li>
</ul>
<p style="text-align:justify">Tabs are responsive and will collapse into a stacked display on smaller screens, allowing the user to view the actual content more easily. The tab container's syntax is accessible, but parts of it might confuse screen readers, so we suggest adding the <code><span class="fore-secondary">aria-hidden</span>=<span class="fore-primary">&quot;true&quot;</span></code> attribute to all the <code>&lt;input&gt;</code> and <code>&lt;label&gt;</code> elements inside the <code>.tabs</code> container.</p>
<h3>Sample code</h3>
<pre>&lt;div class=&quot;tabs&quot;&gt;
&lt;input type=&quot;radio&quot; name=&quot;tab-group&quot; id=&quot;tab1&quot; checked aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;tab1&quot; aria-hidden=&quot;true&quot;&gt;Tab 1&lt;/label&gt;
&lt;div&gt;
&lt;h3&gt;Tab 1&lt;/h3&gt;
&lt;p&gt;This is the first tab's content.&lt;/p&gt;
&lt;/div&gt;
&lt;input type=&quot;radio&quot; name=&quot;tab-group&quot; id=&quot;tab2&quot; aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;tab2&quot; aria-hidden=&quot;true&quot;&gt;Tab 2&lt;/label&gt;
&lt;div&gt;
&lt;h3&gt;Tab 2&lt;/h3&gt;
&lt;p&gt;This is the second tab's content.&lt;/p&gt;
&lt;/div&gt;
&lt;input type=&quot;radio&quot; name=&quot;tab-group&quot; id=&quot;tab3&quot; aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;tab3&quot; aria-hidden=&quot;true&quot;&gt;Tab 3&lt;/label&gt;
&lt;div&gt;
&lt;h3&gt;Tab 3&lt;/h3&gt;
&lt;p&gt;This is the third tab's content.&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>Tabs are compatible with modern browsers, but might not display properly in older browsers.</li>
<li>Remember to add the <code><span class="fore-secondary">checked</span></code> attribute to one of your <code>&lt;input&gt;</code>s if you want that tab to be the one displayed by default. If none is specified, the first one will be displayed.</li>
<li>The <code>height</code> of the tab container's panel area is <code>400px</code>. If you want to change this default size, please check out the <a href="customization">customization</a> page.</li>
<li>Using the method described above for making tabs accessible, screen readers will ignore tab controls and only read the content of tabs.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;div class=&quot;tabs&quot;&gt;
&lt;input type=&quot;checkbox&quot; name=&quot;tab-group&quot; id=&quot;tab1&quot; checked aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;tab1&quot; aria-hidden=&quot;true&quot;&gt;Tab 1&lt;/label&gt;
&lt;div&gt;
&lt;h3&gt;Bad Tab&lt;/h3&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Do not use checkboxes inside the default <code>.tabs</code> container, otherwise you might notice unexpected behavior. If you want to use an <code>&lt;input <span class="fore-secondary">type</span>=<span class="fore-primary">&quot;checkbox&quot;</span>&gt;</code>, check out the next section.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;div class=&quot;tabs&quot;&gt;
&lt;input type=&quot;radio&quot; name=&quot;tab-group&quot; id=&quot;tab1&quot; checked aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;tab1&quot; aria-hidden=&quot;true&quot;&gt;Tab 1&lt;/label&gt;
&lt;div&gt;
&lt;h3&gt;Lonely Tab&lt;/h3&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;You can add a single tab in a <code>.tabs</code> container, but what use would that be? You should probably read the next section to see what you can do with a stacked tab container instead.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;div class=&quot;tabs&quot;&gt;
&lt;input type=&quot;radio&quot; name=&quot;tab-group&quot; id=&quot;tab1&quot; checked aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;tab1&quot; aria-hidden=&quot;true&quot;&gt;Tab 1&lt;/label&gt;
&lt;input type=&quot;radio&quot; name=&quot;tab-group&quot; id=&quot;tab2&quot; aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;tab2&quot; aria-hidden=&quot;true&quot;&gt;Tab 2&lt;/label&gt;
&lt;div&gt;
&lt;h3&gt;Bad Tab&lt;/h3&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;h3&gt;Bad Tab&lt;/h3&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;The syntax and structure of the tab container is very strict. Try to follow it exactly as described in this section.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;div class=&quot;tabs&quot;&gt;
&lt;input type=&quot;radio&quot; name=&quot;tab-group&quot; id=&quot;tab1&quot; checked&gt;
&lt;label for=&quot;tab1&quot;&gt;Tab&lt;/label&gt;
&lt;div&gt;
&lt;h3&gt;Not fully accessible tab&lt;/h3&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Remember to use the <code><span class="fore-secondary">aria-hidden</span>=<span class="fore-primary">&quot;true&quot;</span></code> attribute to make your tabs fully accessible.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="stacked-tabs">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Stacked tabs</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal col-lg-4">
<div class="tabs stacked" style="margin-top: 5px; margin-bottom: 5px;">
<input type="radio" name="accordion" id="a1" checked aria-hidden="true">
<label for="a1" aria-hidden="true">Accordion section 1</label>
<div> <h3>Section 1</h3> <p>This is the first accordion section's content.</p> </div>
<input type="radio" name="accordion" id="a2" aria-hidden="true">
<label for="a2" aria-hidden="true">Accordion section 2</label>
<div> <h3>Section 2</h3> <p>This is the second accordion section's content.</p> </div>
</div>
<div class="tabs stacked" style="margin-top: 5px; margin-bottom: 5px;">
<input type="checkbox" id="c1" aria-hidden="true">
<label for="c1" aria-hidden="true">Collapse section 1</label>
<div> <p>This is the first collapse section's content.</p> </div>
<input type="checkbox" id="c2" aria-hidden="true">
<label for="c2" aria-hidden="true">Collapse section 2</label>
<div> <p>This is the second collapse section's content.</p> </div>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal col-lg-8">
<p style="text-align:justify">Apart from the normal tab layout, you can make your tabs stacked instead, using the <code>.stacked</code> class in your <code>.tabs</code> container element. Stacked tabs are more versatile, allowing you to use checkboxes and/or radio buttons to implement collapses, accordions and spoilers. Carousel-styled elements can also be displayed in this fashion, if you wish. Remember to use the <code><span class="fore-secondary">aria-hidden</span>=<span class="fore-primary">&quot;true&quot;</span></code> attribute to make your tabs fully accessible, as before.</p>
<h3>Sample code</h3>
<pre>&lt;div class=&quot;tabs stacked&quot;&gt;
&lt;input type=&quot;radio&quot; name=&quot;accordion&quot; id=&quot;a1&quot; checked aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;a1&quot; aria-hidden=&quot;true&quot;&gt;Accordion section 1&lt;/label&gt;
&lt;div&gt;
&lt;h3&gt;Section 1&lt;/h3&gt;
&lt;p&gt;This is the first accordion section's content.&lt;/p&gt;
&lt;/div&gt;
&lt;input type=&quot;radio&quot; name=&quot;accordion&quot; id=&quot;a2&quot;aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;a2&quot; aria-hidden=&quot;true&quot;&gt;Accordion section 2&lt;/label&gt;
&lt;div&gt;
&lt;h3&gt;Section 2&lt;/h3&gt;
&lt;p&gt;This is the second accordion section's content.&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;tabs stacked&quot;&gt;
&lt;input type=&quot;checkbox&quot; id=&quot;c1&quot; aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;c1&quot; aria-hidden=&quot;true&quot;&gt;Collapse section 1&lt;/label&gt;
&lt;div&gt;
&lt;p&gt;This is the first collapse section's content.&lt;/p&gt;
&lt;/div&gt;
&lt;input type=&quot;checkbox&quot; id=&quot;c2&quot; aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;c2&quot; aria-hidden=&quot;true&quot;&gt;Collapse section 2&lt;/label&gt;
&lt;div&gt;
&lt;p&gt;This is the second collapse section's content.&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li><code>.stacked</code> tabs can be used with either checkboxes or radio buttons.</li>
<li>You can mix and match checkboxes and radio buttons, but we suggest you do not do so, unless you think it is necessary for your design.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;div class=&quot;tabs stacked&quot;&gt;
&lt;input type=&quot;checkbox&quot; id=&quot;c1&quot; aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;c1&quot; aria-hidden=&quot;true&quot;&gt;Single collapse&lt;/label&gt;
&lt;div&gt;
&lt;p&gt;This is a singular collapse.&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;You can implement single collapses (otherwise known as spoilers), using a <code>.tabs</code><code>.stacked</code> container with only one checkbox-based tab.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;div class=&quot;tabs stacked&quot;&gt;
&lt;input type=&quot;radio&quot; name=&quot;accordion&quot; id=&quot;a1&quot; checked aria-hidden=&quot;true&quot;&gt;
&lt;label for=&quot;a1&quot; aria-hidden=&quot;true&quot;&gt;Single accordion section&lt;/label&gt;
&lt;div&gt;
&lt;p&gt;This accordion section cannot close once opened&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid having a single radio-based tab in a <code>.tabs</code><code>.stacked</code> container, as this might result in unexpected behavior.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" style="padding-bottom: 20px; padding-top:20px;">
<div class="col-sm-12">
<p style="text-align:justify">If you want to learn more about <strong>mini.css</strong>'s modules, go back to the <a href="modules">modules page</a> and choose another module to see its documentation.</p>
</div>
</div>
</main></div></div></div>
<footer style="text-align:justify"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>

File diff suppressed because it is too large Load diff

View file

@ -1,95 +1,95 @@
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<script async src="https://production-assets.codepen.io/assets/embed/ei.js"></script>
<title>mini.css - Templates</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, template, templates ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-centered { text-align: center; } .box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;}
.box-colored.red { background: #e53935; } .box-centered > .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto;} [class^='col-'] .card.fluid { margin: 2px 0 20px; }
h2 > a{ font-size: 1rem; float: right;} .box-left { text-align: left; } @media (max-width: 767px){.container {padding: 0.25rem !important;}.col-sm.col-lg-offset.col-lg-10{padding: 0 !important;}}
[class^='fore-'] { font-family: monospace, monospace;} .fore-primary { color: #0d47a1;} .fore-secondary { color: #b71c1c;} .fore-tertiary { color: #1b5e20;}
</style>
</head>
<body>
<header class="sticky">
<a href="index" class="logo"><span id="header-logo">m</span></a> <label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="index" class="button hidden-sm">Introduction</a> <a href="modules" class="button hidden-sm">Modules</a>
<a href="flavors" class="button hidden-sm">Flavors</a> <a href="templates" class="button hidden-sm">Templates</a>
<a href="customization" class="button hidden-sm">Customization</a> <a href="quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<input type="checkbox" id="navigation-toggle"> <nav class="drawer hidden-md hidden-lg">
<label class="close" for="navigation-toggle"></label>
<a href="index"><h4 style="margin-left: 0;">Introduction</h4></a> <a href="modules"><h4 style="margin-left: 0;">Modules</h4></a>
<a href="flavors"><h4 style="margin-left: 0;">Flavors</h4></a> <a href="templates"><h4 style="margin-left: 0;">Templates</h4></a>
<a href="customization"><h4 style="margin-left: 0;">Customization</h4></a> <a href="quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<!-- Insert your page content here-->
<main><div class="container">
<div class="row" style="padding-top: 40px;">
<div class="col-sm col-lg-10 col-lg-offset-1">
<h1>Templates</h1>
<p style="text-align: justify;">Getting started with <strong>mini.css</strong> is reasonably easy, however sometimes you need a couple of examples or templates to figure out the optimal way to design your website or app. To help you get started, we maintain a handful of templates that can help you quickstart your projects without having to read the full documentation.</p><br/>
<ul style="margin-left:0px; padding-left: 4px">
<li class="card fluid" style="margin-bottom: 3rem;">
<a href="https://codepen.io/chalarangelo/project/editor/DzvxKa/" class="section media" style="height:480px; -o-object-fit: scale-down; object-fit:scale-down; text-align: center;"><img src="project_thumbnail.png" style="height:480px; -o-object-fit: scale-down; object-fit:scale-down;"></a>
<h2 class="section double-padded">Full website template</h2>
<p class="section double-padded" style="text-align: justify;">A complete sample website created using the grid system of <strong>mini.css</strong>, cards, navigational elements and input controls. The website consists of three pages, each showcasing different modules and patterns. The homepage and blog post showcase the typography styling and emphasize the importance of the grid system and the card module, while the contact form showcases the forms, buttons and other input controls. The sample website is fully responsive, changing layout based on screen size, while all of the code is carefully documented, implementing certain patterns and tricks that can be very useful when designing a website.</p>
</li>
<li class="card fluid" style="margin-bottom: 3rem;">
<p data-height="480" data-theme-id="0" data-slug-hash="WpPqaj" data-default-tab="result" data-user="chalarangelo" data-embed-version="2" data-pen-title="Single Column Template (mini.css)" data-preview="true" class="codepen section">See the Pen <a href="http://codepen.io/chalarangelo/pen/WpPqaj/">Single Column Template (mini.css)</a> by Angelos Chalaris (<a href="http://codepen.io/chalarangelo">@chalarangelo</a>) on <a href="http://codepen.io">CodePen</a>.</p>
<h2 class="section double-padded">Single column template</h2>
<p class="section double-padded" style="text-align: justify;">The most basic layout template for a blog or website consists of a sticky header, one column used to display content and a footer at the bottom of the page. This template uses the grid system of <strong>mini.css</strong>, along with its navigational elements to provide a simple responsive website design, that you can use to display content across devices without the need for any changes in the layout.</p>
</li>
<li class="card fluid" style="margin-bottom: 3rem;">
<p data-height="480" data-theme-id="0" data-slug-hash="Vbeeqj" data-default-tab="result" data-user="chalarangelo" data-embed-version="2" data-pen-title="Two Column Template (mini.css)" data-preview="true" class="codepen section">See the Pen <a href="http://codepen.io/chalarangelo/pen/Vbeeqj/">Two Column Template (mini.css)</a> by Angelos Chalaris (<a href="http://codepen.io/chalarangelo">@chalarangelo</a>) on <a href="http://codepen.io">CodePen</a>.</p>
<h2 class="section double-padded">Two-column template</h2>
<p class="section double-padded" style="text-align: justify;">Another common layout template for blogs and websites consists of a sticky header, a footer and two columns for displaying content. Like in most templates, the grid system of <strong>mini.css</strong> is used to provide an easy way to create columns and make them responsive across multiple screen sizes and devices.</p>
</li>
<li class="card fluid" style="margin-bottom: 3rem;">
<p data-height="480" data-theme-id="0" data-slug-hash="OmMNoa" data-default-tab="result" data-user="chalarangelo" data-embed-version="2" data-pen-title="Three Column Template (mini.css)" data-preview="true" class="codepen section">See the Pen <a href="http://codepen.io/chalarangelo/pen/OmMNoa/">Three Column Template (mini.css)</a> by Angelos Chalaris (<a href="http://codepen.io/chalarangelo">@chalarangelo</a>) on <a href="http://codepen.io">CodePen</a>.</p>
<h2 class="section double-padded">Three-column template</h2>
<p class="section double-padded" style="text-align: justify;">Last but not least, the three-column website layout template is better used in websites with a lot of content. The grid system of <strong>mini.css</strong> provides an easy solution to handling lots of content on multiple screen sizes and devices, making the content responsive. Finally, as in most templates, navigational elements such as sticky headers and foooters are used to complete the template.</p>
</li>
<li class="card fluid" style="margin-bottom: 3rem;">
<p data-height="480" data-theme-id="0" data-slug-hash="xdZOVP" data-default-tab="result" data-user="chalarangelo" data-embed-version="2" data-pen-title="Card Showcase Template (mini.css)" data-preview="true" class="codepen section">See the Pen <a href="http://codepen.io/chalarangelo/pen/xdZOVP/">Card Showcase Template (mini.css)</a> by Angelos Chalaris (<a href="http://codepen.io/chalarangelo">@chalarangelo</a>) on <a href="http://codepen.io">CodePen</a>.</p>
<h2 class="section double-padded">Card showcase template</h2>
<p class="section double-padded" style="text-align: justify;">Card-based website layout templates are another common need, as many websites utilize a tile system to display lots of smaller pieces of content. Using the card and grid modules of <strong>mini.css</strong>, along with a couple of navigational elements, it's really easy to create a responsive website with lots of cards containing small pieces of content, such as a showcase for a website, a photo album or an article browser.</p>
</li>
<li class="card fluid" style="margin-bottom: 3rem;">
<p data-height="480" data-theme-id="0" data-slug-hash="GmWrVv" data-default-tab="result" data-user="chalarangelo" data-embed-version="2" data-pen-title="Login Form Template (mini.css)" data-preview="true" class="codepen section">See the Pen <a href="http://codepen.io/chalarangelo/pen/GmWrVv/">Login Form Template (mini.css)</a> by Angelos Chalaris (<a href="http://codepen.io/chalarangelo">@chalarangelo</a>) on <a href="http://codepen.io">CodePen</a>.</p>
<h2 class="section double-padded">Login form template</h2>
<p class="section double-padded" style="text-align: justify;">Login forms are one of the most commonly used elements in any website design. Using the input_control and grid modules of <strong>mini.css</strong>, along with a couple of navigational elements and a couple of optional tricks, it's really easy to create a responsive login form with the required fields and buttons.</p>
</li>
<li class="card fluid" style="margin-bottom: 3rem;">
<p data-height="480" data-theme-id="0" data-slug-hash="EmPyBe" data-default-tab="result" data-user="chalarangelo" data-embed-version="2" data-pen-title="Android App Template (mini.css)" data-preview="true" class="codepen section">See the Pen <a href="http://codepen.io/chalarangelo/pen/EmPyBe/">Android App Template (mini.css)</a> by Angelos Chalaris (<a href="http://codepen.io/chalarangelo">@chalarangelo</a>) on <a href="http://codepen.io">CodePen</a>.</p>
<h2 class="section double-padded">Android app template</h2>
<p class="section double-padded" style="text-align: justify;">Web application layout templates are pretty popular these days, especially ones that look and feel like native Android apps. Utilizing some clever CSS tricks, the grid module and navigational elements from <strong>mini.css</strong>, we created a pretty simple app template, complete with a call-to-action button and header bar, making it look quite similar to a native Android app and display properly across multiple devices.</p>
</li>
<li class="card fluid" style="margin-bottom: 3rem;">
<p data-height="480" data-theme-id="0" data-slug-hash="JNGREq" data-default-tab="result" data-user="chalarangelo" data-embed-version="2" data-pen-title="Tabbed App Template (mini.css)" data-preview="true" class="codepen section">See the Pen <a href="http://codepen.io/chalarangelo/pen/JNGREq/">Tabbed App Template (mini.css)</a> by Angelos Chalaris (<a href="http://codepen.io/chalarangelo">@chalarangelo</a>) on <a href="http://codepen.io">CodePen</a>.</p>
<h2 class="section double-padded">Tabbed app template</h2>
<p class="section double-padded" style="text-align: justify;">A single page application layout template can be built using many things, but tabbed web applications are one of our favorites. Utilizing the tab module of <strong>mini.css</strong> and some CSS tricks, we created a simple single page app template with three tabs, containing different content. The template will switch to a stacked view on smaller devices, although if you add more than three tabs, you will have to alter a couple of values to make sure that everything fits nicely on the screen.</p>
</li>
</ul>
<br/>
</div>
</div>
</div></main>
<!-- End of page content-->
<footer style="text-align: justify;"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<script async src="https://production-assets.codepen.io/assets/embed/ei.js"></script>
<title>mini.css - Templates</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, template, templates ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-centered { text-align: center; } .box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;}
.box-colored.red { background: #e53935; } .box-centered > .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto;} [class^='col-'] .card.fluid { margin: 2px 0 20px; }
h2 > a{ font-size: 1rem; float: right;} .box-left { text-align: left; } @media (max-width: 767px){.container {padding: 0.25rem !important;}.col-sm.col-lg-offset.col-lg-10{padding: 0 !important;}}
[class^='fore-'] { font-family: monospace, monospace;} .fore-primary { color: #0d47a1;} .fore-secondary { color: #b71c1c;} .fore-tertiary { color: #1b5e20;}
</style>
</head>
<body>
<header class="sticky">
<a href="index" class="logo"><span id="header-logo">m</span></a> <label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="index" class="button hidden-sm">Introduction</a> <a href="modules" class="button hidden-sm">Modules</a>
<a href="flavors" class="button hidden-sm">Flavors</a> <a href="templates" class="button hidden-sm">Templates</a>
<a href="customization" class="button hidden-sm">Customization</a> <a href="quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<input type="checkbox" id="navigation-toggle"> <nav class="drawer hidden-md hidden-lg">
<label class="close" for="navigation-toggle"></label>
<a href="index"><h4 style="margin-left: 0;">Introduction</h4></a> <a href="modules"><h4 style="margin-left: 0;">Modules</h4></a>
<a href="flavors"><h4 style="margin-left: 0;">Flavors</h4></a> <a href="templates"><h4 style="margin-left: 0;">Templates</h4></a>
<a href="customization"><h4 style="margin-left: 0;">Customization</h4></a> <a href="quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<!-- Insert your page content here-->
<main><div class="container">
<div class="row" style="padding-top: 40px;">
<div class="col-sm col-lg-10 col-lg-offset-1">
<h1>Templates</h1>
<p style="text-align: justify;">Getting started with <strong>mini.css</strong> is reasonably easy, however sometimes you need a couple of examples or templates to figure out the optimal way to design your website or app. To help you get started, we maintain a handful of templates that can help you quickstart your projects without having to read the full documentation.</p><br/>
<ul style="margin-left:0px; padding-left: 4px">
<li class="card fluid" style="margin-bottom: 3rem;">
<a href="https://codepen.io/chalarangelo/project/editor/DzvxKa/" class="section media" style="height:480px; -o-object-fit: scale-down; object-fit:scale-down; text-align: center;"><img src="project_thumbnail.png" style="height:480px; -o-object-fit: scale-down; object-fit:scale-down;"></a>
<h2 class="section double-padded">Full website template</h2>
<p class="section double-padded" style="text-align: justify;">A complete sample website created using the grid system of <strong>mini.css</strong>, cards, navigational elements and input controls. The website consists of three pages, each showcasing different modules and patterns. The homepage and blog post showcase the typography styling and emphasize the importance of the grid system and the card module, while the contact form showcases the forms, buttons and other input controls. The sample website is fully responsive, changing layout based on screen size, while all of the code is carefully documented, implementing certain patterns and tricks that can be very useful when designing a website.</p>
</li>
<li class="card fluid" style="margin-bottom: 3rem;">
<p data-height="480" data-theme-id="0" data-slug-hash="WpPqaj" data-default-tab="result" data-user="chalarangelo" data-embed-version="2" data-pen-title="Single Column Template (mini.css)" data-preview="true" class="codepen section">See the Pen <a href="http://codepen.io/chalarangelo/pen/WpPqaj/">Single Column Template (mini.css)</a> by Angelos Chalaris (<a href="http://codepen.io/chalarangelo">@chalarangelo</a>) on <a href="http://codepen.io">CodePen</a>.</p>
<h2 class="section double-padded">Single column template</h2>
<p class="section double-padded" style="text-align: justify;">The most basic layout template for a blog or website consists of a sticky header, one column used to display content and a footer at the bottom of the page. This template uses the grid system of <strong>mini.css</strong>, along with its navigational elements to provide a simple responsive website design, that you can use to display content across devices without the need for any changes in the layout.</p>
</li>
<li class="card fluid" style="margin-bottom: 3rem;">
<p data-height="480" data-theme-id="0" data-slug-hash="Vbeeqj" data-default-tab="result" data-user="chalarangelo" data-embed-version="2" data-pen-title="Two Column Template (mini.css)" data-preview="true" class="codepen section">See the Pen <a href="http://codepen.io/chalarangelo/pen/Vbeeqj/">Two Column Template (mini.css)</a> by Angelos Chalaris (<a href="http://codepen.io/chalarangelo">@chalarangelo</a>) on <a href="http://codepen.io">CodePen</a>.</p>
<h2 class="section double-padded">Two-column template</h2>
<p class="section double-padded" style="text-align: justify;">Another common layout template for blogs and websites consists of a sticky header, a footer and two columns for displaying content. Like in most templates, the grid system of <strong>mini.css</strong> is used to provide an easy way to create columns and make them responsive across multiple screen sizes and devices.</p>
</li>
<li class="card fluid" style="margin-bottom: 3rem;">
<p data-height="480" data-theme-id="0" data-slug-hash="OmMNoa" data-default-tab="result" data-user="chalarangelo" data-embed-version="2" data-pen-title="Three Column Template (mini.css)" data-preview="true" class="codepen section">See the Pen <a href="http://codepen.io/chalarangelo/pen/OmMNoa/">Three Column Template (mini.css)</a> by Angelos Chalaris (<a href="http://codepen.io/chalarangelo">@chalarangelo</a>) on <a href="http://codepen.io">CodePen</a>.</p>
<h2 class="section double-padded">Three-column template</h2>
<p class="section double-padded" style="text-align: justify;">Last but not least, the three-column website layout template is better used in websites with a lot of content. The grid system of <strong>mini.css</strong> provides an easy solution to handling lots of content on multiple screen sizes and devices, making the content responsive. Finally, as in most templates, navigational elements such as sticky headers and foooters are used to complete the template.</p>
</li>
<li class="card fluid" style="margin-bottom: 3rem;">
<p data-height="480" data-theme-id="0" data-slug-hash="xdZOVP" data-default-tab="result" data-user="chalarangelo" data-embed-version="2" data-pen-title="Card Showcase Template (mini.css)" data-preview="true" class="codepen section">See the Pen <a href="http://codepen.io/chalarangelo/pen/xdZOVP/">Card Showcase Template (mini.css)</a> by Angelos Chalaris (<a href="http://codepen.io/chalarangelo">@chalarangelo</a>) on <a href="http://codepen.io">CodePen</a>.</p>
<h2 class="section double-padded">Card showcase template</h2>
<p class="section double-padded" style="text-align: justify;">Card-based website layout templates are another common need, as many websites utilize a tile system to display lots of smaller pieces of content. Using the card and grid modules of <strong>mini.css</strong>, along with a couple of navigational elements, it's really easy to create a responsive website with lots of cards containing small pieces of content, such as a showcase for a website, a photo album or an article browser.</p>
</li>
<li class="card fluid" style="margin-bottom: 3rem;">
<p data-height="480" data-theme-id="0" data-slug-hash="GmWrVv" data-default-tab="result" data-user="chalarangelo" data-embed-version="2" data-pen-title="Login Form Template (mini.css)" data-preview="true" class="codepen section">See the Pen <a href="http://codepen.io/chalarangelo/pen/GmWrVv/">Login Form Template (mini.css)</a> by Angelos Chalaris (<a href="http://codepen.io/chalarangelo">@chalarangelo</a>) on <a href="http://codepen.io">CodePen</a>.</p>
<h2 class="section double-padded">Login form template</h2>
<p class="section double-padded" style="text-align: justify;">Login forms are one of the most commonly used elements in any website design. Using the input_control and grid modules of <strong>mini.css</strong>, along with a couple of navigational elements and a couple of optional tricks, it's really easy to create a responsive login form with the required fields and buttons.</p>
</li>
<li class="card fluid" style="margin-bottom: 3rem;">
<p data-height="480" data-theme-id="0" data-slug-hash="EmPyBe" data-default-tab="result" data-user="chalarangelo" data-embed-version="2" data-pen-title="Android App Template (mini.css)" data-preview="true" class="codepen section">See the Pen <a href="http://codepen.io/chalarangelo/pen/EmPyBe/">Android App Template (mini.css)</a> by Angelos Chalaris (<a href="http://codepen.io/chalarangelo">@chalarangelo</a>) on <a href="http://codepen.io">CodePen</a>.</p>
<h2 class="section double-padded">Android app template</h2>
<p class="section double-padded" style="text-align: justify;">Web application layout templates are pretty popular these days, especially ones that look and feel like native Android apps. Utilizing some clever CSS tricks, the grid module and navigational elements from <strong>mini.css</strong>, we created a pretty simple app template, complete with a call-to-action button and header bar, making it look quite similar to a native Android app and display properly across multiple devices.</p>
</li>
<li class="card fluid" style="margin-bottom: 3rem;">
<p data-height="480" data-theme-id="0" data-slug-hash="JNGREq" data-default-tab="result" data-user="chalarangelo" data-embed-version="2" data-pen-title="Tabbed App Template (mini.css)" data-preview="true" class="codepen section">See the Pen <a href="http://codepen.io/chalarangelo/pen/JNGREq/">Tabbed App Template (mini.css)</a> by Angelos Chalaris (<a href="http://codepen.io/chalarangelo">@chalarangelo</a>) on <a href="http://codepen.io">CodePen</a>.</p>
<h2 class="section double-padded">Tabbed app template</h2>
<p class="section double-padded" style="text-align: justify;">A single page application layout template can be built using many things, but tabbed web applications are one of our favorites. Utilizing the tab module of <strong>mini.css</strong> and some CSS tricks, we created a simple single page app template with three tabs, containing different content. The template will switch to a stacked view on smaller devices, although if you add more than three tabs, you will have to alter a couple of values to make sure that everything fits nicely on the screen.</p>
</li>
</ul>
<br/>
</div>
</div>
</div></main>
<!-- End of page content-->
<footer style="text-align: justify;"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>

View file

@ -1,350 +1,350 @@
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<title>mini.css - Utility</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, module, utility, helper, classes, utilities ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-centered { text-align: center; } .box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;} .box-colored.red { background: #b71c1c; }
.box-centered > .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto; } [class^='col-'] .card.fluid { margin: 2px 0 20px; } @media (max-width: 767px){.container {padding: 0.25rem !important;}.col-sm-12.col-md-8.col-lg-10{padding: 0 !important;}}
[class^='fore-'] { font-family: monospace, monospace;} .fore-primary { color: #0d47a1;} .fore-secondary { color: #b71c1c;} .fore-tertiary { color: #1b5e20;}
.col-sm-12.col-sm-last.col-md-4.col-md-normal { box-sizing: border-box; border-right: 1px solid #c9c9c9; }
@media (max-width: 767px){ .col-sm-12.col-sm-last.col-md-4.col-md-normal { border: 0; border-top: 1px solid #c9c9c9;}}
.col-sm-12.col-sm-last.col-md-12.col-md-normal { box-sizing: border-box; border-bottom: 1px solid #c9c9c9; }
@media (max-width: 767px){ .col-sm-12.col-sm-last.col-md-12.col-md-normal { border: 0; border-top: 1px solid #c9c9c9;}}
.box-colored.green { background: #1b5e20; } .do {border-top: 15px solid #689f38;padding-top: 10px;} .dont {border-top: 15px solid #e53935;padding-top: 10px;}
.box-colored { color: #f5f5f5;} @media screen and (min-width: 768px) { .drawer { margin-top: 4px;}}
</style>
</head>
<body>
<header class="sticky">
<a href="index" class="logo"><span id="header-logo">m</span></a>
<label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="index" class="button hidden-sm">Introduction</a> <a href="modules" class="button hidden-sm">Modules</a>
<a href="flavors" class="button hidden-sm">Flavors</a> <a href="templates" class="button hidden-sm">Templates</a>
<a href="customization" class="button hidden-sm">Customization</a> <a href="quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<div class="container" style="padding-left: 0.25rem;">
<div class="row"> <input type="checkbox" id="navigation-toggle"> <nav class="drawer col-md-4 col-lg-2">
<label class="close" for="navigation-toggle"></label>
<a href="index"><h4 style="margin-left: 0;">Introduction</h4></a>
<h4 style="margin-left: 0;">Modules</h4> <a href="core#core-title">Core</a>
<a href="core#typography" class="sublink-1">Typography</a> <a href="core#headings" class="sublink-1">Headings</a>
<a href="core#common-textual-elements" class="sublink-1">Common textual elements</a>
<a href="core#lists" class="sublink-1">Lists</a> <a href="core#images-captions" class="sublink-1">Image responsiveness &amp; captions</a>
<br/> <a href="grid#grid-title">Grid</a>
<a href="grid#basic-layout" class="sublink-1">Basic layout</a> <a href="grid#screen-specific-layout" class="sublink-1">Screen specific layouts</a>
<a href="grid#predefined-layout" class="sublink-1">Predefined layouts</a> <a href="grid#column-offset" class="sublink-1">Column offsets</a>
<a href="grid#column-reorder" class="sublink-1">Column reordering</a> <a href="grid#media-object" class="sublink-1">Media object pattern</a>
<br/> <a href="input_control#input-control-title">Input Control</a>
<a href="input_control#forms-input" class="sublink-1">Forms &amp; input</a> <a href="input_control#checkbox-radio" class="sublink-1">Checkboxes &amp; radio buttons</a> <a href="input_control#switches" class="sublink-1">Switches</a>
<a href="input_control#buttons" class="sublink-1">Buttons &amp; button groups</a> <a href="input_control#file-upload" class="sublink-1">File upload buttons</a>
<br/> <a href="navigation#navigation-title">Navigation</a>
<a href="navigation#header" class="sublink-1">Header</a> <a href="navigation#navigation-bar" class="sublink-1">Navigation bar</a> <a href="navigation#drawer" class="sublink-1">Drawer</a>
<a href="navigation#footer" class="sublink-1">Footer</a> <a href="navigation#sticky" class="sublink-1">Sticky headers &amp; footers</a>
<br/> <a href="table#table-title">Table</a>
<a href="table#syntax-responsiveness" class="sublink-1">Basic syntax &amp; responsiveness</a> <a href="table#scrollable-tables" class="sublink-1">Scrollable tables</a>
<a href="table#horizontal-tables" class="sublink-1">Horizontal tables</a> <a href="table#variants-matrices" class="sublink-1">Table variants &amp; matrices</a>
<br/> <a href="card#card-title">Card</a>
<a href="card#basic-syntax" class="sublink-1">Basic syntax</a> <a href="card#sections-media" class="sublink-1">Sections &amp; media</a>
<a href="card#sizing-fluidity" class="sublink-1">Card sizing &amp; fluidity</a> <a href="card#color-variants" class="sublink-1">Card color variants</a>
<br/> <a href="tab#tab-title">Tab</a>
<a href="tab#basic-syntax" class="sublink-1">Basic syntax</a> <a href="tab#stacked-tabs" class="sublink-1">Stacked tabs</a>
<br/> <a href="contextual#contextual-title">Contextual</a>
<a href="contextual#text-highlighting" class="sublink-1">Text highlighting</a> <a href="contextual#toasts" class="sublink-1">Toasts</a>
<a href="contextual#tooltips" class="sublink-1">Tooltips</a> <a href="contextual#modals" class="sublink-1">Modals</a>
<br/> <a href="progress#progress-title">Progress</a>
<a href="progress#basic-progress-bar" class="sublink-1">Basic progress bar</a> <a href="progress#progress-variants" class="sublink-1">Progress bar variants</a>
<a href="progress#donut-spinner" class="sublink-1">Donut spinner</a> <a href="progress#spinner-variants" class="sublink-1">Donut spinner variants</a>
<br/> <a href="utility#utility-title">Utility</a>
<a href="utility#visibility-helpers" class="sublink-1">Visibility helpers</a> <a href="utility#borders-shadows" class="sublink-1">Generic borders &amp; shadows</a>
<a href="utility#responsive-sizing" class="sublink-1">Responsive sizing &amp; spacing classes</a>
<a href="utility#responsive-visibility" class="sublink-1">Responsive visibility helpers</a> <a href="utility#breadcrumbs" class="sublink-1">Breadcrumbs</a>
<a href="utility#close-icon" class="sublink-1">Close icon</a>
<a href="flavors"><h4 style="margin-left: 0;">Flavors</h4></a>
<a href="templates"><h4 style="margin-left: 0;">Templates</h4></a>
<a href="customization"><h4 style="margin-left: 0;">Customization</h4></a>
<a href="quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<div class="col-sm-12 col-md-8 col-lg-10"><main>
<div class="row" style="padding-top: 40px;" id="utility-title">
<div class="col-sm-12">
<h1>Utility</h1>
<p style="text-align:justify">The <strong>utility</strong> module contains all the utilities and helper classes that you might want when designing a website or application. They solve common design problems efficiently and provide you with generic rules you can easily apply everywhere.</p>
<p style="text-align:justify"><small>All examples showcased refer to the mini-default flavor, some class names and styles might differ based on the flavor you're using.</small></p><br/>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<div class="card fluid">
<div class="section">
<h2>Quick overview</h2>
<p style="text-align:justify">Every website or app has different needs and no CSS framework can predict them all. The <strong>utility</strong> module addresses this issue by providing you with a handful of utility and helper classes to make common, repetitive declarations easier. These classes include, but are not limited to, generic border styling and shadows, some responsive sizing and spacing utilities and a few other things, like a close icon, breadcrumbs styling and visiblity helpers for screen readers.</p><br>
</div>
<div class="section">
<h2>Quick start</h2>
<p style="text-align:justify">To use the <strong>utility</strong> module, simply include the link to the flavor you are using and start writing your HTML page as usual. One suggestion we will make is to add the following line inside your HTML page's <code>&lt;head&gt;</code> to utilize the viewport meta tag:</p>
<pre>&lt;<span class="fore-tertiary">meta</span> <span class="fore-secondary">name</span>=<span class="fore-primary">&quot;viewport&quot;</span> <span class="fore-secondary">content</span>=<span class="fore-primary">&quot;width=device-width, initial-scale=1&quot;</span>&gt;</pre><br>
</div>
</div>
</div>
</div>
<div class="row" id="visibility-helpers">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Visibility helpers</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-first">
<p style="text-align:justify">You can hide content for all your users, using the default <code><span class="fore-secondary">hidden</span></code> attribute. However, we provide you with the <code>.hidden</code> class for the same purpose, as well as the <code>.visually-hidden</code> class which will make your content hidden, except for screen readers.</p>
<h3>Sample code</h3>
<pre>&lt;span class=&quot;hidden&quot;&gt;Hidden text&lt;/span&gt;
&lt;span class=&quot;visually-hidden&quot;&gt;Screen-reader-only text&lt;/span&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>Both classes utilize <code><span class="fore-secondary">!important</span></code> declarations, so be careful when and how to use them.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12">
<pre>&lt;span class=&quot;hidden visually-hidden&quot;&gt;Not a good idea&lt;/span&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid using both classes at the same time. Instead, use <code>.hidden</code> to hide content for all users, <code>.visually-hidden</code> to hide it for non-screen-reader users or <code><span class="fore-secondary">aria-hidden</span>=<span class="fore-primary">&quot;true&quot;</span></code> to hide it for screen-reader-only users.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="borders-shadows">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Generic borders &amp; shadows</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<div>
<br>
<p>This is a paragraph with a piece of <span class="bordered">bordered text</span>.</p>
<button class="bordered">Bordered button</button><button class="bordered primary">Bordered button</button><br>
<p><img src="https://placehold.it/200x200?text=rounded" class="rounded" alt="image">&nbsp;&nbsp;<img src="https://placehold.it/200x200?text=circular" class="circular" alt="image"></p><br>
<p><span class="shadowed">This is an element that casts a shadow.</span></p><br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align:justify">Use the <code>.bordered</code> class to apply a generic black border with 25% opacity to any element. Apart from that you can use the <code>.rounded</code> and <code>.circular</code> classes to create generic border radiuses. Finally, you can use the <code>.shadowed</code> class to add a generic <code><span class="fore-secondary">box-shadow</span></code> to any element.</p>
<h3>Sample code</h3>
<pre>&lt;span class=&quot;bordered&quot;&gt;Bordered&lt;/span&gt;
&lt;span class=&quot;rounded&quot;&gt;Rounded&lt;/span&gt;
&lt;span class=&quot;circular&quot;&gt;Circular&lt;/span&gt;
&lt;span class=&quot;shadowed&quot;&gt;Casts shadow&lt;/span&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>All of these classes utilize <code><span class="fore-secondary">!important</span></code> declarations, so be careful when and how to use them.</li>
<li>The <code>.bordered</code> class was originally created with elements such as buttons in mind, to allow users highlighting certain elements in their designs, without having to change any default styles.</li>
<li>All of the above classes can be used with most modern HTML elements.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;span class=&quot;bordered rounded shadow-small&quot;&gt;Stylized element&lt;/span&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;You can combine a generic border with any border radius or shadow or even both.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;span class=&quot;rounded circular&quot;&gt;Bad radius&lt;/span&gt;
<span class="fore-secondary">&lt;!-- or --&gt;</span>
&lt;span class=&quot;shadow-small shadow-large&quot;&gt;Bad shadow&lt;/span&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid combining two classes of the same type (i.e. two radii or two shadow styles), as they might overwrite each other and cause unexpected behavior.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="responsive-sizing">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Responsive sizing &amp; spacing classes</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-first">
<p style="text-align:justify">Helper classes for the <code>padding</code> and <code>margin</code> attributes are provided in the form of <code>.responsive-margin</code> and <code>.responsive-padding</code> classes. Both of these classes are responsive, allowing you to collapse the spacing and size of elements on different displays to make better use of the device's viewport.</p>
<h3>Sample code</h3>
<pre>&lt;div class=&quot;responsive-padding&quot;&gt;Responsive padding&lt;/div&gt;
&lt;div class=&quot;responsive-margin&quot;&gt;Responsive margin&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>If the default values of these classes are not suited to your needs, check out the <a href="customization">customization</a> page.</li>
<li>Both classes utilize <code><span class="fore-secondary">!important</span></code> declarations, so be careful when and how to use them.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12">
<pre>&lt;div class=&quot;responsive-padding responsive-margin&quot;&gt;Responsive padding and margin&lt;/div&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;You can use both of these classes to make certain element adapt to changes. This could be especially useful for certain grid layouts.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="responsive-visibility">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Responsive visibility helpers</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-first">
<p style="text-align:justify">You can hide content (either fully or only visually) for certain screens, using the responsive visibility helpers. To hide elements completely use the <code>.hidden-<span class="fore-primary">SCR_SZ</span></code> syntax, replacing <code><span class="fore-primary">SCR_SZ</span></code> with one of the available screen size names (<code><span class="fore-tertiary">sm</span></code> for smaller screens, <code><span class="fore-tertiary">md</span></code> for medium-sized screens or <code><span class="fore-tertiary">lg</span></code> for larger screens). If you want to hide certains elements for all users, except screen readers, replace <code>.hidden</code> with <code>.visually-hidden</code>, followed by the screen size name.</p>
<h3>Sample code</h3>
<pre>&lt;span class=&quot;hidden-sm&quot;&gt;Hidden in smaller screens&lt;/span&gt;
&lt;span class=&quot;hidden-md&quot;&gt;Hidden in medium-sized screens&lt;/span&gt;
&lt;span class=&quot;hidden-lg&quot;&gt;Hidden in larger screens&lt;/span&gt;
&lt;span class=&quot;visually-hidden-sm&quot;&gt;Visually hidden in smaller screens&lt;/span&gt;
&lt;span class=&quot;visually-hidden-md&quot;&gt;Visually hidden in medium-sized screens&lt;/span&gt;
&lt;span class=&quot;visually-hidden-lg&quot;&gt;Visually hidden in larger screens&lt;/span&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>Responsive visibility helper classes utilize <code><span class="fore-secondary">!important</span></code> declarations, so be careful when and how to use them.</li>
<li>The specific breakpoints for small, medium and large screen sizes are as follows:
<ul>
<li><strong>small</strong>: less than <code>768px</code> wide</li>
<li><strong>medium</strong>: more than or equal to <code>768px</code> wide but less than <code>1280px</code> wide</li>
<li><strong>large</strong>: <code>1280px</code> wide or more</li>
</ul>
</li>
<li>Responsive visibility helper classes are independent, meaning that hiding an element in one screen size will not affect it visibility in any other screen size.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;span class=&quot;hidden-sm hidden-md&quot;&gt;Hidden in smaller and medium-sized screens, visible in larger screens&lt;/span&gt;
<span class="fore-tertiary">&lt;!-- or --&gt;</span>
&lt;span class=&quot;visually-hidden-md visually-hidden-lg&quot;&gt;Visually hidden in medium-sized and larger screens, visible in smaller screens&lt;/span&gt;
<span class="fore-tertiary">&lt;!-- or --&gt;</span>
&lt;span class=&quot;hidden-sm visually-hidden-lg&quot;&gt;Hidden in smaller screens, visually hidden in larger screens, visible in medium-sized screens&lt;/span&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;You can combine responsive visibility helpers for different sizes, based on your needs.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;span class=&quot;hidden-sm visually-hidden-sm&quot;&gt;Not a good idea&lt;/span&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid combining responsive visibility helpers for the same screen size. Combining both of them might cause unexpected behavior.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="breadcrumbs">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Breadcrumbs</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal">
<div><br>
<ul class="breadcrumbs"> <li><a href="#">Root</a></li> <li><a href="#">Folder</a></li> <li>File</li> </ul><br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal">
<p style="text-align:justify">Breadcrumbs are usually used to show the navigational hierarchy of pages or folders. To use them, simply create a <code>&lt;ul&gt;</code> element that implements the <code>.breadcrumbs</code> class. Inside this unordered list, add as many <code>&lt;li&gt;</code> elements as needed to show your hierarchy. You can add links to the list elements, as necessary.</p>
<h3>Sample code</h3>
<pre>&lt;ul class=&quot;breadcrumbs&quot;&gt;
&lt;li&gt;&lt;a href=&quot;#&quot;&gt;Root&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;#&quot;&gt;Folder&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;File&lt;/li&gt;
&lt;/ul&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>The separators between breadcrumbs are added using some tricky CSS rules. Due to that, there might be a few browser versions or devices where you can see part of the seams between the element separators.</li>
<li>Breadcrumbs show a hierarchy, an ordered list. However, we do not use the <code>&lt;ol&gt;</code> element, as it might conflict with some custom styles we've seen people use.</li>
<li>If you want to add some accesibility to your breadcrumbs, you can add the <code><span class="fore-secondary">role</span>=<span class="fore-primary">&quot;<a href="https://www.w3.org/TR/wai-aria/roles#navigation">navigation</a>&quot;</span></code> attribute, although it is not required.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;ol class=&quot;breadcrumbs&quot;&gt;
&lt;li&gt;&lt;a href=&quot;#&quot;&gt;Does&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;#&quot;&gt;Not&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;Work&lt;/li&gt;
&lt;/ol&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;The structure of the breadcrumb component prohibits the use of <code>&lt;ol&gt;</code> in place of the <code>&lt;ul&gt;</code> element.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;ul class=&quot;breadcrumbs&quot;&gt;
&lt;li&gt;&lt;a href=&quot;#&quot;&gt;Root&lt;/a&gt;
&lt;ul class=&quot;breadcrumbs&quot;&gt;
&lt;li&gt;&lt;a href=&quot;#&quot;&gt;Folder&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;File&lt;/li&gt;
&lt;/ul&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid nesting lists, breadcrumbs or a combination of the two inside the <code>.breadcrumbs</code> list, as this might cause unexpected behavior.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="close-icon">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Close icon</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<div>
<br>
<p style="text-align:center;">&nbsp;&nbsp;<span class="close"></span>&nbsp;&nbsp;</p>
<br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align:justify">To create a close icon, simply add an element implementing the <code>.close</code> class.</p>
<h3>Sample code</h3>
<pre>&lt;span class=&quot;close&quot;&gt;&lt;/span&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>The close icon behaves similar to a button when hovering over it or otherwise focusing or selecting it.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;div class=&quot;close&quot;&gt;&lt;/div&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;You can use a handful of other HTML elements instead of the <code>&lt;span&gt;</code> element showcased in the example above, most commonly <code>&lt;div&gt;</code> elements.</p>
</div>
<div class="col-sm-12 col-md-6">
<pre>&lt;button class=&quot;close&quot;&gt;&lt;/button&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;If you want your close icon to behave like a button (i.e. register as a button on screen readers and have the required logic attached to it), you can apply the <code>.close</code> class to a <code>&lt;button&gt;</code> element instead. You can even apply any of the button color variant classes.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" style="padding-bottom: 20px; padding-top:20px;">
<div class="col-sm-12">
<p style="text-align:justify">If you want to learn more about <strong>mini.css</strong>'s modules, go back to the <a href="modules">modules page</a> and choose another module to see its documentation.</p>
</div>
</div>
</main></div></div></div>
<footer style="text-align:justify"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="mini-default.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css">
<title>mini.css - Utility</title>
<meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta name="keywords" content="mini, mini.css, CSS, framework, minimal, responsive, style-agnostic, front-end, frontend, Sass, module, utility, helper, classes, utilities ">
<meta name="author" content="Angelos Chalaris (chalarangelo)">
<meta property="og:title" content="mini.css - Minimal, responsive, style-agnostic CSS framework">
<meta property="og:description" content="mini.css is a tiny CSS framework designed to build quick, modern and responsive websites."/>
<meta property="og:type" content="website"/><meta property="og:image" content="page_thumb.png">
<meta property="og:url" content="https://chalarangelo.github.io/mini.css/"><link rel="icon" type="image/png" href="favicon.png">
<style>
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/erE3KsIWUumgD1j_Ca-V-xJtnKITppOI_IvcXXDNrsc.woff2) format('woff2'); unicode-range: U+0100-024F, U+1E00-1EFF, U+20A0-20AB, U+20AD-20CF, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 400; src: local('Noto Sans'), local('NotoSans'), url(https://fonts.gstatic.com/s/notosans/v6/LeFlHvsZjXu2c3ZRgBq9nFtXRa8TVwTICgirnJhmVJw.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215; }
#header-logo { background: -webkit-linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); background: linear-gradient(#07020d 20%, #150627 45%, #220a40 70%, #300d5a); line-height:1; font-size: 39px; width: 48px; height: 48px; padding: 8px; margin-left: -9px; }
.box-centered { text-align: center; } .box-colored { background: #0277bd; border-radius: 2px; padding: 14px; margin-bottom: 8px; min-height: 14px;} .box-colored.red { background: #b71c1c; }
.box-centered > .card.fluid {-webkit-box-pack: start; -webkit-box-align: start; -webkit-justify-content: flex-start; justify-content: flex-start; -webkit-align-self: auto; align-self: auto; } [class^='col-'] .card.fluid { margin: 2px 0 20px; } @media (max-width: 767px){.container {padding: 0.25rem !important;}.col-sm-12.col-md-8.col-lg-10{padding: 0 !important;}}
[class^='fore-'] { font-family: monospace, monospace;} .fore-primary { color: #0d47a1;} .fore-secondary { color: #b71c1c;} .fore-tertiary { color: #1b5e20;}
.col-sm-12.col-sm-last.col-md-4.col-md-normal { box-sizing: border-box; border-right: 1px solid #c9c9c9; }
@media (max-width: 767px){ .col-sm-12.col-sm-last.col-md-4.col-md-normal { border: 0; border-top: 1px solid #c9c9c9;}}
.col-sm-12.col-sm-last.col-md-12.col-md-normal { box-sizing: border-box; border-bottom: 1px solid #c9c9c9; }
@media (max-width: 767px){ .col-sm-12.col-sm-last.col-md-12.col-md-normal { border: 0; border-top: 1px solid #c9c9c9;}}
.box-colored.green { background: #1b5e20; } .do {border-top: 15px solid #689f38;padding-top: 10px;} .dont {border-top: 15px solid #e53935;padding-top: 10px;}
.box-colored { color: #f5f5f5;} @media screen and (min-width: 768px) { .drawer { margin-top: 4px;}}
</style>
</head>
<body>
<header class="sticky">
<a href="index" class="logo"><span id="header-logo">m</span></a>
<label class="drawer-toggle button" for="navigation-toggle"></label>
<a href="index" class="button hidden-sm">Introduction</a> <a href="modules" class="button hidden-sm">Modules</a>
<a href="flavors" class="button hidden-sm">Flavors</a> <a href="templates" class="button hidden-sm">Templates</a>
<a href="customization" class="button hidden-sm">Customization</a> <a href="quick_reference" class="button hidden-sm">Quick Reference</a>
<a href="https://github.com/Chalarangelo/mini.css" class="button"><i class="fa fa-github" aria-hidden="true" style="font-size: 1.3em; position: relative; bottom: -2px; margin-right: 2px;"></i>&nbsp;Github</a>
</header>
<div class="container" style="padding-left: 0.25rem;">
<div class="row"> <input type="checkbox" id="navigation-toggle"> <nav class="drawer col-md-4 col-lg-2">
<label class="close" for="navigation-toggle"></label>
<a href="index"><h4 style="margin-left: 0;">Introduction</h4></a>
<h4 style="margin-left: 0;">Modules</h4> <a href="core#core-title">Core</a>
<a href="core#typography" class="sublink-1">Typography</a> <a href="core#headings" class="sublink-1">Headings</a>
<a href="core#common-textual-elements" class="sublink-1">Common textual elements</a>
<a href="core#lists" class="sublink-1">Lists</a> <a href="core#images-captions" class="sublink-1">Image responsiveness &amp; captions</a>
<br/> <a href="grid#grid-title">Grid</a>
<a href="grid#basic-layout" class="sublink-1">Basic layout</a> <a href="grid#screen-specific-layout" class="sublink-1">Screen specific layouts</a>
<a href="grid#predefined-layout" class="sublink-1">Predefined layouts</a> <a href="grid#column-offset" class="sublink-1">Column offsets</a>
<a href="grid#column-reorder" class="sublink-1">Column reordering</a> <a href="grid#media-object" class="sublink-1">Media object pattern</a>
<br/> <a href="input_control#input-control-title">Input Control</a>
<a href="input_control#forms-input" class="sublink-1">Forms &amp; input</a> <a href="input_control#checkbox-radio" class="sublink-1">Checkboxes &amp; radio buttons</a> <a href="input_control#switches" class="sublink-1">Switches</a>
<a href="input_control#buttons" class="sublink-1">Buttons &amp; button groups</a> <a href="input_control#file-upload" class="sublink-1">File upload buttons</a>
<br/> <a href="navigation#navigation-title">Navigation</a>
<a href="navigation#header" class="sublink-1">Header</a> <a href="navigation#navigation-bar" class="sublink-1">Navigation bar</a> <a href="navigation#drawer" class="sublink-1">Drawer</a>
<a href="navigation#footer" class="sublink-1">Footer</a> <a href="navigation#sticky" class="sublink-1">Sticky headers &amp; footers</a>
<br/> <a href="table#table-title">Table</a>
<a href="table#syntax-responsiveness" class="sublink-1">Basic syntax &amp; responsiveness</a> <a href="table#scrollable-tables" class="sublink-1">Scrollable tables</a>
<a href="table#horizontal-tables" class="sublink-1">Horizontal tables</a> <a href="table#variants-matrices" class="sublink-1">Table variants &amp; matrices</a>
<br/> <a href="card#card-title">Card</a>
<a href="card#basic-syntax" class="sublink-1">Basic syntax</a> <a href="card#sections-media" class="sublink-1">Sections &amp; media</a>
<a href="card#sizing-fluidity" class="sublink-1">Card sizing &amp; fluidity</a> <a href="card#color-variants" class="sublink-1">Card color variants</a>
<br/> <a href="tab#tab-title">Tab</a>
<a href="tab#basic-syntax" class="sublink-1">Basic syntax</a> <a href="tab#stacked-tabs" class="sublink-1">Stacked tabs</a>
<br/> <a href="contextual#contextual-title">Contextual</a>
<a href="contextual#text-highlighting" class="sublink-1">Text highlighting</a> <a href="contextual#toasts" class="sublink-1">Toasts</a>
<a href="contextual#tooltips" class="sublink-1">Tooltips</a> <a href="contextual#modals" class="sublink-1">Modals</a>
<br/> <a href="progress#progress-title">Progress</a>
<a href="progress#basic-progress-bar" class="sublink-1">Basic progress bar</a> <a href="progress#progress-variants" class="sublink-1">Progress bar variants</a>
<a href="progress#donut-spinner" class="sublink-1">Donut spinner</a> <a href="progress#spinner-variants" class="sublink-1">Donut spinner variants</a>
<br/> <a href="utility#utility-title">Utility</a>
<a href="utility#visibility-helpers" class="sublink-1">Visibility helpers</a> <a href="utility#borders-shadows" class="sublink-1">Generic borders &amp; shadows</a>
<a href="utility#responsive-sizing" class="sublink-1">Responsive sizing &amp; spacing classes</a>
<a href="utility#responsive-visibility" class="sublink-1">Responsive visibility helpers</a> <a href="utility#breadcrumbs" class="sublink-1">Breadcrumbs</a>
<a href="utility#close-icon" class="sublink-1">Close icon</a>
<a href="flavors"><h4 style="margin-left: 0;">Flavors</h4></a>
<a href="templates"><h4 style="margin-left: 0;">Templates</h4></a>
<a href="customization"><h4 style="margin-left: 0;">Customization</h4></a>
<a href="quick_reference"><h4 style="margin-left: 0;">Quick Reference</h4></a>
</nav>
<div class="col-sm-12 col-md-8 col-lg-10"><main>
<div class="row" style="padding-top: 40px;" id="utility-title">
<div class="col-sm-12">
<h1>Utility</h1>
<p style="text-align:justify">The <strong>utility</strong> module contains all the utilities and helper classes that you might want when designing a website or application. They solve common design problems efficiently and provide you with generic rules you can easily apply everywhere.</p>
<p style="text-align:justify"><small>All examples showcased refer to the mini-default flavor, some class names and styles might differ based on the flavor you're using.</small></p><br/>
</div>
</div>
<div class="row">
<div class="col-sm-12">
<div class="card fluid">
<div class="section">
<h2>Quick overview</h2>
<p style="text-align:justify">Every website or app has different needs and no CSS framework can predict them all. The <strong>utility</strong> module addresses this issue by providing you with a handful of utility and helper classes to make common, repetitive declarations easier. These classes include, but are not limited to, generic border styling and shadows, some responsive sizing and spacing utilities and a few other things, like a close icon, breadcrumbs styling and visiblity helpers for screen readers.</p><br>
</div>
<div class="section">
<h2>Quick start</h2>
<p style="text-align:justify">To use the <strong>utility</strong> module, simply include the link to the flavor you are using and start writing your HTML page as usual. One suggestion we will make is to add the following line inside your HTML page's <code>&lt;head&gt;</code> to utilize the viewport meta tag:</p>
<pre>&lt;<span class="fore-tertiary">meta</span> <span class="fore-secondary">name</span>=<span class="fore-primary">&quot;viewport&quot;</span> <span class="fore-secondary">content</span>=<span class="fore-primary">&quot;width=device-width, initial-scale=1&quot;</span>&gt;</pre><br>
</div>
</div>
</div>
</div>
<div class="row" id="visibility-helpers">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Visibility helpers</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-first">
<p style="text-align:justify">You can hide content for all your users, using the default <code><span class="fore-secondary">hidden</span></code> attribute. However, we provide you with the <code>.hidden</code> class for the same purpose, as well as the <code>.visually-hidden</code> class which will make your content hidden, except for screen readers.</p>
<h3>Sample code</h3>
<pre>&lt;span class=&quot;hidden&quot;&gt;Hidden text&lt;/span&gt;
&lt;span class=&quot;visually-hidden&quot;&gt;Screen-reader-only text&lt;/span&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>Both classes utilize <code><span class="fore-secondary">!important</span></code> declarations, so be careful when and how to use them.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12">
<pre>&lt;span class=&quot;hidden visually-hidden&quot;&gt;Not a good idea&lt;/span&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid using both classes at the same time. Instead, use <code>.hidden</code> to hide content for all users, <code>.visually-hidden</code> to hide it for non-screen-reader users or <code><span class="fore-secondary">aria-hidden</span>=<span class="fore-primary">&quot;true&quot;</span></code> to hide it for screen-reader-only users.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="borders-shadows">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Generic borders &amp; shadows</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<div>
<br>
<p>This is a paragraph with a piece of <span class="bordered">bordered text</span>.</p>
<button class="bordered">Bordered button</button><button class="bordered primary">Bordered button</button><br>
<p><img src="https://placehold.it/200x200?text=rounded" class="rounded" alt="image">&nbsp;&nbsp;<img src="https://placehold.it/200x200?text=circular" class="circular" alt="image"></p><br>
<p><span class="shadowed">This is an element that casts a shadow.</span></p><br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align:justify">Use the <code>.bordered</code> class to apply a generic black border with 25% opacity to any element. Apart from that you can use the <code>.rounded</code> and <code>.circular</code> classes to create generic border radiuses. Finally, you can use the <code>.shadowed</code> class to add a generic <code><span class="fore-secondary">box-shadow</span></code> to any element.</p>
<h3>Sample code</h3>
<pre>&lt;span class=&quot;bordered&quot;&gt;Bordered&lt;/span&gt;
&lt;span class=&quot;rounded&quot;&gt;Rounded&lt;/span&gt;
&lt;span class=&quot;circular&quot;&gt;Circular&lt;/span&gt;
&lt;span class=&quot;shadowed&quot;&gt;Casts shadow&lt;/span&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>All of these classes utilize <code><span class="fore-secondary">!important</span></code> declarations, so be careful when and how to use them.</li>
<li>The <code>.bordered</code> class was originally created with elements such as buttons in mind, to allow users highlighting certain elements in their designs, without having to change any default styles.</li>
<li>All of the above classes can be used with most modern HTML elements.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;span class=&quot;bordered rounded shadow-small&quot;&gt;Stylized element&lt;/span&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;You can combine a generic border with any border radius or shadow or even both.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;span class=&quot;rounded circular&quot;&gt;Bad radius&lt;/span&gt;
<span class="fore-secondary">&lt;!-- or --&gt;</span>
&lt;span class=&quot;shadow-small shadow-large&quot;&gt;Bad shadow&lt;/span&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid combining two classes of the same type (i.e. two radii or two shadow styles), as they might overwrite each other and cause unexpected behavior.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="responsive-sizing">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Responsive sizing &amp; spacing classes</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-first">
<p style="text-align:justify">Helper classes for the <code>padding</code> and <code>margin</code> attributes are provided in the form of <code>.responsive-margin</code> and <code>.responsive-padding</code> classes. Both of these classes are responsive, allowing you to collapse the spacing and size of elements on different displays to make better use of the device's viewport.</p>
<h3>Sample code</h3>
<pre>&lt;div class=&quot;responsive-padding&quot;&gt;Responsive padding&lt;/div&gt;
&lt;div class=&quot;responsive-margin&quot;&gt;Responsive margin&lt;/div&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>If the default values of these classes are not suited to your needs, check out the <a href="customization">customization</a> page.</li>
<li>Both classes utilize <code><span class="fore-secondary">!important</span></code> declarations, so be careful when and how to use them.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12">
<pre>&lt;div class=&quot;responsive-padding responsive-margin&quot;&gt;Responsive padding and margin&lt;/div&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;You can use both of these classes to make certain element adapt to changes. This could be especially useful for certain grid layouts.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="responsive-visibility">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Responsive visibility helpers</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-first">
<p style="text-align:justify">You can hide content (either fully or only visually) for certain screens, using the responsive visibility helpers. To hide elements completely use the <code>.hidden-<span class="fore-primary">SCR_SZ</span></code> syntax, replacing <code><span class="fore-primary">SCR_SZ</span></code> with one of the available screen size names (<code><span class="fore-tertiary">sm</span></code> for smaller screens, <code><span class="fore-tertiary">md</span></code> for medium-sized screens or <code><span class="fore-tertiary">lg</span></code> for larger screens). If you want to hide certains elements for all users, except screen readers, replace <code>.hidden</code> with <code>.visually-hidden</code>, followed by the screen size name.</p>
<h3>Sample code</h3>
<pre>&lt;span class=&quot;hidden-sm&quot;&gt;Hidden in smaller screens&lt;/span&gt;
&lt;span class=&quot;hidden-md&quot;&gt;Hidden in medium-sized screens&lt;/span&gt;
&lt;span class=&quot;hidden-lg&quot;&gt;Hidden in larger screens&lt;/span&gt;
&lt;span class=&quot;visually-hidden-sm&quot;&gt;Visually hidden in smaller screens&lt;/span&gt;
&lt;span class=&quot;visually-hidden-md&quot;&gt;Visually hidden in medium-sized screens&lt;/span&gt;
&lt;span class=&quot;visually-hidden-lg&quot;&gt;Visually hidden in larger screens&lt;/span&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>Responsive visibility helper classes utilize <code><span class="fore-secondary">!important</span></code> declarations, so be careful when and how to use them.</li>
<li>The specific breakpoints for small, medium and large screen sizes are as follows:
<ul>
<li><strong>small</strong>: less than <code>768px</code> wide</li>
<li><strong>medium</strong>: more than or equal to <code>768px</code> wide but less than <code>1280px</code> wide</li>
<li><strong>large</strong>: <code>1280px</code> wide or more</li>
</ul>
</li>
<li>Responsive visibility helper classes are independent, meaning that hiding an element in one screen size will not affect it visibility in any other screen size.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;span class=&quot;hidden-sm hidden-md&quot;&gt;Hidden in smaller and medium-sized screens, visible in larger screens&lt;/span&gt;
<span class="fore-tertiary">&lt;!-- or --&gt;</span>
&lt;span class=&quot;visually-hidden-md visually-hidden-lg&quot;&gt;Visually hidden in medium-sized and larger screens, visible in smaller screens&lt;/span&gt;
<span class="fore-tertiary">&lt;!-- or --&gt;</span>
&lt;span class=&quot;hidden-sm visually-hidden-lg&quot;&gt;Hidden in smaller screens, visually hidden in larger screens, visible in medium-sized screens&lt;/span&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;You can combine responsive visibility helpers for different sizes, based on your needs.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;span class=&quot;hidden-sm visually-hidden-sm&quot;&gt;Not a good idea&lt;/span&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid combining responsive visibility helpers for the same screen size. Combining both of them might cause unexpected behavior.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="breadcrumbs">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Breadcrumbs</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-12 col-md-normal">
<div><br>
<ul class="breadcrumbs"> <li><a href="#">Root</a></li> <li><a href="#">Folder</a></li> <li>File</li> </ul><br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-12 col-md-normal">
<p style="text-align:justify">Breadcrumbs are usually used to show the navigational hierarchy of pages or folders. To use them, simply create a <code>&lt;ul&gt;</code> element that implements the <code>.breadcrumbs</code> class. Inside this unordered list, add as many <code>&lt;li&gt;</code> elements as needed to show your hierarchy. You can add links to the list elements, as necessary.</p>
<h3>Sample code</h3>
<pre>&lt;ul class=&quot;breadcrumbs&quot;&gt;
&lt;li&gt;&lt;a href=&quot;#&quot;&gt;Root&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;#&quot;&gt;Folder&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;File&lt;/li&gt;
&lt;/ul&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>The separators between breadcrumbs are added using some tricky CSS rules. Due to that, there might be a few browser versions or devices where you can see part of the seams between the element separators.</li>
<li>Breadcrumbs show a hierarchy, an ordered list. However, we do not use the <code>&lt;ol&gt;</code> element, as it might conflict with some custom styles we've seen people use.</li>
<li>If you want to add some accesibility to your breadcrumbs, you can add the <code><span class="fore-secondary">role</span>=<span class="fore-primary">&quot;<a href="https://www.w3.org/TR/wai-aria/roles#navigation">navigation</a>&quot;</span></code> attribute, although it is not required.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;ol class=&quot;breadcrumbs&quot;&gt;
&lt;li&gt;&lt;a href=&quot;#&quot;&gt;Does&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;#&quot;&gt;Not&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;Work&lt;/li&gt;
&lt;/ol&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;The structure of the breadcrumb component prohibits the use of <code>&lt;ol&gt;</code> in place of the <code>&lt;ul&gt;</code> element.</p>
</div>
<div class="col-sm-12 col-md-6 col-sm-last col-md-normal">
<pre>&lt;ul class=&quot;breadcrumbs&quot;&gt;
&lt;li&gt;&lt;a href=&quot;#&quot;&gt;Root&lt;/a&gt;
&lt;ul class=&quot;breadcrumbs&quot;&gt;
&lt;li&gt;&lt;a href=&quot;#&quot;&gt;Folder&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;File&lt;/li&gt;
&lt;/ul&gt;</pre>
<p class="dont" style="text-align:justify"><mark class="secondary">Don't:</mark>&nbsp;Avoid nesting lists, breadcrumbs or a combination of the two inside the <code>.breadcrumbs</code> list, as this might cause unexpected behavior.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" id="close-icon">
<div class="col-sm-12">
<div class="card fluid">
<div class="section"><h2>Close icon</h2></div>
<div class="section row">
<div class="col-sm-12 col-sm-last col-md-4 col-md-normal">
<div>
<br>
<p style="text-align:center;">&nbsp;&nbsp;<span class="close"></span>&nbsp;&nbsp;</p>
<br>
</div>
</div>
<div class="col-sm-12 col-sm-first col-md-8 col-md-normal">
<p style="text-align:justify">To create a close icon, simply add an element implementing the <code>.close</code> class.</p>
<h3>Sample code</h3>
<pre>&lt;span class=&quot;close&quot;&gt;&lt;/span&gt;</pre>
</div>
</div>
<div class="section">
<h3>Notes</h3>
<ul style="text-align:justify">
<li>The close icon behaves similar to a button when hovering over it or otherwise focusing or selecting it.</li>
</ul><hr>
<div class="row">
<div class="col-sm-12 col-md-6">
<pre>&lt;div class=&quot;close&quot;&gt;&lt;/div&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;You can use a handful of other HTML elements instead of the <code>&lt;span&gt;</code> element showcased in the example above, most commonly <code>&lt;div&gt;</code> elements.</p>
</div>
<div class="col-sm-12 col-md-6">
<pre>&lt;button class=&quot;close&quot;&gt;&lt;/button&gt;</pre>
<p class="do" style="text-align:justify"><mark class="tertiary">Do:</mark>&nbsp;If you want your close icon to behave like a button (i.e. register as a button on screen readers and have the required logic attached to it), you can apply the <code>.close</code> class to a <code>&lt;button&gt;</code> element instead. You can even apply any of the button color variant classes.</p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="row" style="padding-bottom: 20px; padding-top:20px;">
<div class="col-sm-12">
<p style="text-align:justify">If you want to learn more about <strong>mini.css</strong>'s modules, go back to the <a href="modules">modules page</a> and choose another module to see its documentation.</p>
</div>
</div>
</main></div></div></div>
<footer style="text-align:justify"><strong>mini.css</strong> was designed and built with <i class="fa fa-heart-o" aria-hidden="true"></i> by <a href="https://github.com/Chalarangelo">@Chalarangelo</a>. It is licensed under the <a href="https://github.com/Chalarangelo/mini.css/blob/master/LICENSE">MIT License</a>. You can view the project's source code on <a href="https://github.com/Chalarangelo/mini.css">Github</a>.</footer>
</body>
</html>

View file

@ -1,4 +1,4 @@
// Get the current version of the Gluon branch.
module.exports = {
version: 'v3.0.0-alpha.3'
}
// Get the current version of the Gluon branch.
module.exports = {
version: 'v3.0.0-alpha.3'
}

View file

@ -1,38 +1,38 @@
{
"name": "mini.css",
"version": "2.3.4",
"description": "A minimal, responsive, style-agnostic CSS framework.",
"main": "dist/mini-default.min.css",
"directories": {
"lib": "src/mini"
},
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"build-docs": "node ./docs/build-docs.js"
},
"repository": {
"type": "git",
"url": "git+https://github.com/Chalarangelo/mini.css.git"
},
"devDependencies": {
"node-sass": "^4.5.2"
},
"keywords": [
"css",
"sass",
"minimal",
"responsive",
"style-agnostic",
"framework",
"toolkit",
"mini",
"mini.css"
],
"author": "Angelos Chalaris (chalarangelo@gmail.com)",
"license": "MIT",
"bugs": {
"url": "https://github.com/Chalarangelo/mini.css/issues",
"email": "chalarangelo@gmail.com"
},
"homepage": "http://minicss.org"
}
{
"name": "mini.css",
"version": "2.3.4",
"description": "A minimal, responsive, style-agnostic CSS framework.",
"main": "dist/mini-default.min.css",
"directories": {
"lib": "src/mini"
},
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"build-docs": "node ./docs/build-docs.js"
},
"repository": {
"type": "git",
"url": "git+https://github.com/Chalarangelo/mini.css.git"
},
"devDependencies": {
"node-sass": "^4.5.2"
},
"keywords": [
"css",
"sass",
"minimal",
"responsive",
"style-agnostic",
"framework",
"toolkit",
"mini",
"mini.css"
],
"author": "Angelos Chalaris (chalarangelo@gmail.com)",
"license": "MIT",
"bugs": {
"url": "https://github.com/Chalarangelo/mini.css/issues",
"email": "chalarangelo@gmail.com"
},
"homepage": "http://minicss.org"
}

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

View file

@ -1,460 +1,460 @@
// This is a flavor file. Duplicate it and edit it to create your own flavor. Read instructions carefully.
// Single-line comments, starting with '//' will not be included in your final CSS file. Multiline comments,
// structured like the flavor description below, will be included in your final CSS file.
// Note: This flavor is not a full flavor, we strongly recommend you duplicate the mini-default flavor instead
// of this file, unless you know what you are doing.
/*
Flavor name: Lite (mini-lite)
Author: Angelos Chalaris (chalarangelo@gmail.com)
Maintainers: Angelos Chalaris
mini.css version: v2.3.4
*/
// Basic rules for body and typography
$fore-color: #212121; // Text and general foreground color
$back-color: #f8f8f8; // Body background color
$base-font-family: // Default font stack for all elements:
'-apple-system, BlinkMacSystemFont,\"Segoe UI\",\"Roboto\", \"Droid Sans\",\"Helvetica Neue\", Helvetica, Arial, sans-serif';
// OS X and iOS system fonts (San Francisco) -> Windows system fonts -> Android system fonts (newer and older) -> Fallback fonts
$base-root-font-size: 16px; // Root font sizing for all elements [1]
$_1px: (1px/$base-root-font-size) * 1rem; // Calculated rem value of 1px [1]
$base-font-size: 1rem; // Default font sizing for all elements [2]
$base-line-height: 1.5; // Default line height for all elements.
$use-fluid-typography: false; // Should fluid typography be used at the root element? (`true`/`false`)
$body-margin: 0; // Margin for the body
$apply-defaults-to-all: true; // Should default values be applied to all elements? (`true` or `false`) [3]
$h1-font-size: 2rem; // Font size of h1
$h2-font-size: 1.6875rem; // Font size for h2
$h3-font-size: 1.4375rem; // Font size for h3
$h4-font-size: 1.1875rem; // Font size for h4
$h5-font-size: 1rem; // Font size for h5
$h6-font-size: 0.8125rem; // Font size for h6
$heading-line-height: 1.2em; // Line height for all headings
$heading-margin: 0.75rem 0.5rem; // Margin for all headings
$heading-font-weight: 500; // Font weight for all headings
$heading-smalltext-fore-color: #424242; // <small> color in headings
$make-heading-smalltext-block: true; // Should <small> elements in headings be displayed as blocks (`true`/`false`) [4]
$heading-smalltext-b-font-size: 0.75em; // Font size of block <small> elements in headings
$heading-smalltext-b-top-margin:-0.25rem; // Top margin of block <small> elements in headings
$paragraph-margin: 0.5rem; // Margin for <p> elements
$list-margin: 0.5rem; // Margin for <ol> and <ul> elements
$list-left-padding: 1rem; // Left padding for <ol> and <ul> elements
$bold-font-weight: 700; // Font weight for <b> and <strong>
$horizontal-rule-line-height: 1.25em; // <hr> line height
$horizontal-rule-margin: 0.5rem; // <hr> margin
$horizontal-rule-border-style: $_1px solid #8c8c8c; // Border style for horizontal rules (used in the <hr> element's border-top)
$horizontal-rule-fancy-style: false; // Should a fancy styling be applied for the <hr> element (`true`/`false`) [5]
$blockquote-back-color: #eeeeee; // Background color for <blockquote>
$blockquote-fore-color: $fore-color; // Text color for <blockquote>
$blockquote-margin: 0.5rem; // Margin for <blockquote>
$blockquote-padding: 0.5rem 0.5rem 1.5rem;// Padding for <blockquote>
$blockquote-sidebar-style: 0; // Style for the sidebar of <blockquote>
$blockquote-cite-font-size: 0.875rem; // Font size for citation of <blockquote>
$blockquote-cite-fore-color: #505050; // Text color for citation of <blockquote>
$blockquote-cite-left-position: 0.625rem; // Left padding for citation of <blockquote>
$blockquote-cite-bottom-position: 0; // Bottom padding for citation of <blockquote>
$blockquote-border-style: 0; // Border style for <blockquote>
$blockquote-border-radius: 0 2px 2px 0; // Border radius for <blockquote>
$blockquote-box-shadow: none; // Box shadow for <blockquote>
$use-default-code-fonts: true; // Should default font choice (monospace) be used for code elements? (`true`/`false`) [6]
$code-element-padding: 0.125rem 0.25rem; // Padding for <code>
$code-element-fore-color: $fore-color; // Text color for <code>
$code-element-back-color: #e6e6e6; // Background color for <code>
$code-element-border-style: 0; // Border style for <code>
$code-element-border-radius: 2*$_1px; // Border radius for <code>
$code-element-box-shadow: none; // Box shadow for <code>
$pre-element-padding: 0.75rem; // Padding for <pre>
$pre-element-fore-color: $code-element-fore-color; // Text color for <pre>
$pre-element-back-color: $code-element-back-color; // Background color for <pre>
$pre-element-border-style: 0; // Border style for <pre>
$pre-element-border-radius: 0 2*$_1px 2*$_1px 0;// Border radius for <pre>
$pre-element-margin: 0.5rem; // Margin for <pre>
$pre-element-box-shadow: none; // Box shadow for <pre>
$add-pre-element-sidebar: false; // Should a fancy sidebar be added to the left side of <pre> (`true`/`false`) [7]
$kbd-element-padding: $code-element-padding; // Padding for <kbd>
$kbd-element-fore-color: #fafafa; // Text color for <kbd>
$kbd-element-back-color: #0c0c0c; // Background color for <kbd>
$kbd-element-border-style: 0; // Border style for <kbd>
$kbd-element-border-radius: $code-element-border-radius; // Border radius for <kbd>
$kbd-element-box-shadow: $code-element-box-shadow; // Box shadow for <kbd>
$style-samp-element: false; // Should styles for <samp> be included? (`true`/`false`) [8]
$include-dfn-fix: true; // Should the fix for Android 4.3 concerning <dfn> be included (`true`/`false`) [9]
$small-font-size: 0.75em; // Font size for <small> elements
$sup-font-size: 0.75em; // Font size for <sup> elements
$sub-font-size: 0.75em; // Font size for <sub> elements
$sup-top: -0.5em; // <sup> top
$sub-bottom: -0.25em; // <sub> bottom
$link-fore-color: #0277bd; // Text color for <a>
$link-visited-fore-color: #01579b; // Text color for visited <a>
$link-font-weight: 500; // Font weight for <a>
$apply-link-underline: true; // Should an underline be applied to all <a> elements? (`true`/`false`) [10]
$apply-link-hover-fade: true; // Should the :hover and :focus state of <a> elements use fade-out instead of a different color (`true`/`false`) [11]
$figcaption-font-size: 0.8125rem; // Font size of <figcaption> elements
$figcaption-fore-color: #424242; // Text color for <figcaption> elements
// Notes:
// [1] - The value $base-root-font-size should be in `px` only! This rule is very important, as it will determine the root
// element's font sizing. The value of $_1px is calculated based on the value of $base-root-font-size, please do not alter
// the way that it's calculated.
// [2] - The value of $base-font-size will only be used if the value of $apply-defaults-to-all is set to `true` (see [3]).
// This is due to the fact that applying the value of it on the root element again will overwrite the value of
// $base-root-font-size (see [1]). The value of this variable should be set in either `em` or `rem`.
// [3] - It is recommended to set the value of $apply-defaults-to-all to `true`, unless you want to apply extra styling
// to elements manually.
// [4] - If the value of $make-heading-smalltext-block is `true` the <small> elements in headings will be displayed below
// the main heading and the 2 values specified below will apply.
// [5] - If $horizontal-rule-fancy-style is set to `true` the value of $horizontal-rule-border-style will not be used and
// a gradient with the style specified in $horizontal-rule-fancy-gradient will be applied instead.
// [6] - If the value of $use-default-code-fonts is set to `false` the value of $code-font-family will be used. `true`
// will apply the proper fix to use monospace font without any problems on all browsers.
// [7] - if the value of $add-pre-element-sidebar is set to true, the style specified in $pre-element-sidebar-style will
// be applied as a left border for the <pre> elements.
// [8] - If the value of $style-samp-element is set to `false`, no styling will be included in the final CSS file for
// `samp` elements. Otherwise, the styling defined in the $samp-... variables will be applied.
// [9] - If the value of $include-dfn-fix is set to `true` a styling fix will be applied, so that the <dfn> elements are
// displayed properly on older versions of Android (4.3-) in italics. Otherwise, said fix will not be included.
// [10] - If the value of $apply-link-underline is set to `true`, an underline will be applied to the link in its normal
// color, as defined in $link-fore-color.
// [11] - If `$apply-link-hover-fade` is set to `true`, a fading transition will be used for the link when hovered over or
// focused. Otherwise, the color specified in $link-hover-fore-color will be used.
// Variables for grid elements
$use-four-step-grid: false; // Should the old 4-step grid system be used instead of the new (`true`/`false`) [1]
$include-parent-layout: true; // Should the classes for rows defining the column layout of children be included (`true`/`false`) [2]
$grid-container-name: 'container'; // Class name for the grid container
$grid-container-side-padding: 0.75rem; // Padding for the grid container (left and right only)
$grid-row-name: 'row'; // Class name for the grid's rows
$grid-row-parent-layout-prefix:'cols'; // Class name prefix for the grid's row parents [2]
$grid-column-prefix: 'col'; // Class name prefix for the grid's columns
$grid-column-offset-suffix: 'offset'; // Class name suffix for the grid's offsets
$grid-order-normal-suffix: 'normal'; // Class name suffix for grid columns with normal priority
$grid-order-first-suffix: 'first'; // Class name suffix for grid columns with highest priority
$grid-order-last-suffix: 'last'; // Class name suffix for grid columns with lowest priorty
$grid-column-count: 12; // Number of columns in the grid (integer value only)
$grid-column-padding: 0 0.25rem; // Padding for the columns of the grid
$grid-small-prefix: 'sm'; // Small screen class prefix for grid
$grid-medium-breakpoint: 768px; // Medium screen breakpoint for grid
$grid-medium-prefix: 'md'; // Medium screen class prefix for grid
$grid-large-breakpoint: 1280px; // Large screen breakpoint for grid
$grid-large-prefix: 'lg'; // Large screen class prefix for grid
// Notes:
// [1] - If the value of $use-four-step-grid is `true`, the grid system will contain 4 breakpoints instead of 3, along with
// the needed styles. In this case, values should be specified for $grid-extra-small-prefix and $grid-small-breakpoint.
// [2] - If the value of $include-parent-layout is `true`, the grid system will contain extra classes that will define the column
// layout of their children. In this case, a value should be specified for $grid-row-parent-layout-prefix.
// Variables for forms and inputs
$form-back-color: #eeeeee; // Background color for forms
$form-fore-color: $fore-color; // Text color for forms
$form-border-style: $_1px solid #c9c9c9; // Border style for forms
$form-border-radius: 0; // Border radius for forms
$form-margin: 0.5rem; // Margin for forms
$form-padding: 0.75rem 0.5rem 1.125rem; // Padding for forms
$form-box-shadow: none; // Box shadow for forms
$fieldset-back-color: $form-back-color; // Background color for fieldset
$fieldset-border-style: $_1px solid #d0d0d0; // Border style for fieldset
$fieldset-border-radius: 2*$_1px; // Border radius for fieldset
$fieldset-margin: 0.125rem; // Margin for fieldset
$fieldset-padding: 0.5rem; // Padding for fieldset
$legend-font-weight: $bold-font-weight; // Font weight for legend
$legend-font-size: 0.875rem; // Font size for legend
$legend-fore-color: $form-fore-color; // Text color for legend
$legend-padding: 0.125rem 0.25rem; // Padding for legend
$label-padding: 0.25rem 0.5rem; // Padding for label
$input-group-name: 'input-group'; // Class for input groups
$include-fluid-input-group: false; // Should fluid input grooups be included? (`true`/`false`) [1]
$include-vertical-input-group: false; // Should vertical input grooups be included? (`true`/`false`) [1]
$input-back-color: #fafafa; // Background for input
$input-fore-color: $fore-color; // Text color for input
$input-border-style: $_1px solid #c9c9c9; // Border style for input
$input-border-radius: 2*$_1px; // Border radius for input
$input-margin: 0.25rem; // Margin for input
$input-padding: 0.5rem 0.75rem; // Padding for input
$input-focus-border-color: #0288d1; // Border color for focused input
$input-invalid-border-color: #d32f2f; // Border color for invalid input
$input-disabled-opacity: 0.75; // Opacity for disabled input
$input-readonly-back-color: #e5e5e5; // Background color for readonly input
$input-readonly-border-color: #c9c9c9; // Border color for readonly input
$input-placeholder-fore-color:#616161; // Text color for input placeholder
$apply-select-fix: false; // [Hidden flag override] Should the styles that fix <select> styling be applied? (`true`/`false`)
$button-back-color: #dcdcdc; // Back color for button elements
$button-back-opacity: 0.75; // Background opacity for button elements
$button-hover-back-opacity: 1; // Background opacity for button elements on hover or focus
$button-fore-color: $fore-color; // Text color for button elements
$button-border-style: 0; // Border style for button elements
$button-border-radius: 2*$_1px; // Border radius for button elements
$button-padding: 0.5rem 0.75rem; // Padding for button elements
$button-margin: 0.5rem; // Margin for button elements
$button-box-shadow: none; // Box shadow for buttons
$button-disabled-opacity:0.75; // Disabled button elements opacity
$button-class-name: 'button'; // Class for custom button elements
$include-button-group: false; // [Hidden flag override] Should button groups be enabled? (`true`/`false`) [2]
$hide-file-inputs: true; // Should a style be added that makes all <input>s of type `file` hidden? (`true`/`false`) [3]
$button-variant1-name: 'primary'; // Class name for button variant 1
$button-variant1-back-color: #0277bd; // Background color for button variant 1
$button-variant1-back-opacity: 0.9; // Background opacity for button variant 1
$button-variant1-hover-back-opacity: 1; // Background opacity for button variant 1 on hover or focus
$button-variant1-fore-color: #fafafa; // Text color for button variant 1
$button-variant2-name: 'secondary';// Class name for button variant 2
$button-variant2-back-color: #c62828; // Background color for button variant 2
$button-variant2-back-opacity: 0.9; // Background opacity for button variant 2
$button-variant2-hover-back-opacity: 1; // Background opacity for button variant 2 on hover or focus
$button-variant2-fore-color: #fafafa; // Text color for button variant 2
$button-variant3-name: 'tertiary';// Class name for button variant 3
$button-variant3-back-color: #5f9133; // Background color for button variant 3
$button-variant3-back-opacity: 0.9; // Background opacity for button variant 3
$button-variant3-hover-back-opacity: 1; // Background opacity for button variant 3 on hover or focus
$button-variant3-fore-color: #fafafa; // Text color for button variant 3
$button-style1-name: 'small'; // Class name for button style 1
$button-style1-border-style: 0; // Border style for button style 1
$button-style1-border-radius: $_1px; // Border radius for button style 1
$button-style1-padding: 0.25rem 0.375rem; // Padding for button style 1
$button-style1-margin: 0.5rem; // Margin for button style 1
$button-style2-name: 'large'; // Class name for button style 2
$button-style2-border-style: 0; // Border style for button style 2
$button-style2-border-radius: 4*$_1px; // Border radius for button style 2
$button-style2-padding: 0.75rem 1.125rem; // Padding for button style 2
$button-style2-margin: 0.5rem; // Margin for button style 2
$checkbox-size: 1rem; // Size for checkbox/radio [4]
$checkbox-back-color: $input-back-color;// Background clor for checkbox/radio
$checkbox-fore-color: $input-fore-color;// Text/mark color for checkbox/radio
$checkbox-border-thickness: $_1px; // Border thickness for checkbox/radio
$checkbox-border-color: #bdbdbd; // Border color for checkbox/radio
$checkbox-border-radius: $input-border-radius;// Border radius for checkbox/radio
$checkbox-focus-border-color: $input-focus-border-color;// Border color for checkbox/radio on focus
$checkbox-bottom-spacing: 0.375rem; // Bottom spacing for checkbox/radio
$checkbox-disabled-opacity: $input-disabled-opacity;// Opacity for disabled checkbox/radio
$checkbox-box-shadow: none; // Box shadow for checkbox/radio
$include-switch: false; // Should switch components be included? (`true`/`false`) [5]
// Notes:
// [1] - If the value of $include-fluid-input-group is `true`, fluid input groups will be included, using the values
// specified in the corresponding variables. The same applies for $include-vertical-input-group and vertical input groups.
// [2] - Due to the fact that the value of $include-button-group is set to `false`, no button group styles will be created.
// If you wish to enable them, please refer to a full flavor for the required variables.
// [3] - If the value of $hide-file-inputs is `true`, all <input type="file"> elements will be hidden and the only way
// to access them is via the use of <label> elements that are linked to them. This option is enabled by default to
// allow for universal button styles, even for file input buttons, but can be disabled if the base style is desired.
// If the value is `false`, some fixes will be applied to the <input type="file"> element.
// [4] - The value of $checkbox-size will determine a few variables like some `margin` values, `height`, `width` etc.
// Variables for navigational elements
// [5] - Due to the fact that the value of $include-switch is set to `false`, no switch styles will be created.
// If you wish to enable them, please refer to a full flavor for the required variables.
$header-height: 2.75rem; // Height for <header>
$header-back-color: #12171a; // Background color for <header>
$header-fore-color: #f5f5f5; // Text color for <header>
$header-border-style: 0; // Border style for <header>
$header-margin: 0; // Margin for <header>
$header-padding: 0.125rem 0.5rem; // Padding for <header>
$header-box-shadow: none; // Box shadow for <header>
$header-logo-name: 'logo'; // Class name for <header>'s logo
$header-logo-font-size: 1.75rem; // Font size for <header>'s logo
$header-logo-line-height: 1.3125em; // Line height for <header>'s logo
$header-logo-margin: 0.0625rem 0.375rem 0.0625rem 0.0625rem; // Margin for <header>'s logo
$header-logo-padding: 0; // Padding for <header>'s logo
$header-link-hover-color: #20292e; // Hover color for <header>'s links
$header-link-margin: 0.125rem 0; // Margin for <header>'s links
$include-header-sticky: true; // Should sticky <header> elements be included? (`true`/`false`) [1]
$header-sticky-name: 'sticky'; // Class name for sticky <header>
$include-nav-styles: false; // [Hidden flag override] Should <nav> elements by stylized? (`true`/`false`) [2]
$include-drawer: false; // [Hidden flag override] Should the drawer component be included? (`true`/`false`) [2]
$footer-back-color: #192024; // Background color for <footer>
$footer-fore-color: #f5f5f5; // Text color for <footer>
$footer-border-style: 0; // Border stye for <footer>
$footer-font-size: 0.875rem; // Font size for <footer>
$footer-margin: 1rem 0 0; // Margin for <footer>
$footer-padding: 1.5rem 0.5rem 0.75rem; // Padding for <footer>
$footer-link-fore-color: #0288d1; // Text color for links in <footer>
$include-footer-sticky: true; // Should sticky <footer> elements be included (`true`/`false`) [3]
$footer-sticky-name: 'sticky'; // Class name for sticky <footer> elements
// Notes:
// [1] - If the value of $include-header-sticky is `true`, a class will be created that will allow for sticky positioning
// of <header> elements, using the value of $header-sticky-name for the name of the class.
// [2] - Due to the fact that the values of $include-nav-styles and $include-drawer are set to `false`, <nav> elements
// will not be stylized and the drawer component will not be included. If you set it to `true`, please refer to a full
// flavor to find the required variable definitions.
// [3] - If the value of $include-footer-bottom is `true`, a class will be created that will allow for sticky positioning
// of <footer> elements, using the value of $footer-sticky-name for the name of the class.
// Variables for responsive tables
$table-border-style: $_1px solid #c9c9c9; // Border style for <table> and children
$table-border-radius: 0; // Border radius for <table> and children
$table-margin: 0 auto; // Margin for <table>
$table-box-shadow: none; // Box shadow for <table>
$table-caption-font-size: 1.5rem; // Font size for <caption>
$table-caption-margin: 0.5rem; // Margin for <caption>
$table-row-padding: 0.5rem; // Padding for <tr> - both views
$table-column-padding: 0.625rem; // Padding for <td> and <th> - desktop view
$table-head-back-color: #e6e6e6; // Background color for <th>
$table-head-fore-color: $fore-color; // Text color for <th>
$table-body-back-color: #fafafa; // Background color for <td>
$table-body-fore-color: $fore-color; // Text color for <td>
$table-mobile-breakpoint: 767px; // Breakpoint for <table> mobile view
$table-mobile-card-spacing: 0.625rem; // Space between <tr> cards - mobile view
$table-mobile-card-label: 'data-label'; // Attribute used to replace column headers in mobile view [1]
$table-mobile-label-font-weight:$bold-font-weight; // Font weight for mobile headers
$include-horizontal-table: false; // Should horizontal <table> elements be included? (`true`/`false`) [2]
$include-scrollable-table: false; // Should scrollable <table> elements be included? (`true`/`false`) [2]
$include-striped-table: false; // [Hidden flag override] Should striped <table> elements be included (`true`/`false`) [2]
// Notes:
// [1] - The attribute specified in $table-mobile-card-label must be added manually to each and every element in the table
// in order for their mobile headers to display properly.
// [2] - Due to the $include-horizontal-table, $include-scrollable-table and $include-striped-table flags being set to `false`,
// no styling will be provided for horizontal, scrollable and striped <table> elements. Please refer to a full fulavor to find
// the variables associated with these components, if you want to enable them.
$card-name: 'card'; // Class name for cards
$card-back-color: #fafafa; // Background color for cards
$card-fore-color: $fore-color; // Text color for cards
$card-border-style: $_1px solid #acacac; // Border style for cards
$card-border-radius: 0; // Border radius for cards
$card-margin: 0.5rem; // Margin for cards
$card-box-shadow: none; // Box shadow for cards
$card-section-name: 'section'; // Class name for card sections
$card-section-border-style: $_1px solid #c9c9c9;// Border style for card sections
$card-section-padding: 0.5rem; // Padding for card sections
$card-section-media-name: 'media'; // Class name for card media sections
$card-section-media-height: 200px; // Height for card media setions
$card-normal-width: 320px; // Width for normal cards
$card-size1-name: 'fluid'; // Class name for fluid cards
$card-size1-width: 100%; // Width for fluid cards
$card-section-style1-name: 'dark'; // Class name for card section style 1
$card-section-style1-back-color: #e0e0e0; // Background color for card section style 1
$card-section-style1-fore-color: $fore-color; // Text color for card section style 1
$card-section-padding1-name: 'double-padded'; // Class name for card section padding style 1
$card-section-padding1-padding: 0.75rem; // Padding for card section padding style 1
// Notes:
// [1] - The cards module depends heavily on the grid system module.
// --- --- ---
// No variables specified for the tab module. This module is disabled by default.
// To re-enable it, please refer to a full flavor for variables and documentation.
// --- --- ---
// Variables for contextual background elements and alerts
$mark-back-color: #0277bd; // Background color for <mark>
$mark-fore-color: #fafafa; // Text color for <mark>
$mark-font-size: 0.9375em; // Font size for <mark>
$mark-line-height: 1em; // Line height for <mark>
$mark-border-style: 0; // Border style for <mark>
$mark-border-radius: 2*$_1px; // Border radius for <mark>
$mark-padding: 0.125em 0.25em; // Padding for <mark>
$mark-margin: 0; // Margin for <mark>
$mark-box-shadow: none; // Box shadow for <mark>
$mark-inline-block-name: 'inline-block'; // Class name for <mark> inline block styling
$mark-variant1-name: 'secondary'; // Class name for <mark> variant 1
$mark-variant1-back-color: #e53935; // Background color for <mark> variant 1
$mark-variant2-name: 'tertiary'; // Class name for <mark> variant 2
$mark-variant2-back-color: #689f38; // Background color for <mark> variant 2
$mark-style1-name: 'tag'; // Class name for <mark> style 1
$mark-style1-border-style: 0; // Border style for <mark> style 1
$mark-style1-border-radius: 200px; // Border radius for <mark> style 1
$mark-style1-padding: 0.25em 0.5em; // Padding for <mark> style 1
$mark-style2-name: 'inline-block'; // Class name for <mark> style 2
$mark-style2-border-style: 0; // Border style for <mark> style 2
$mark-style2-border-radius: 2*$_1px; // Border radius for <mark> style 2
$mark-style2-padding: 0.375em; // Padding for <mark> style 2
$mark-style2-font-size: 1em; // Font size for <mark> style 2
$mark-style2-line-height: 1.375em; // Line height for <mark> style 2
$include-toast: false; // [Hidden flag override] Should toasts be included? (`true`/`false``) [1]
$include-tooltip: false; // Should tooltips be included? (`true`/`false`) [1]
$include-modal: false; // Should modals be included? (`true`/`false`) [1]
// Notes:
// [1] - Due to the values of $include-toast, $include-tooltip and $include-modal being set
// to `false`, no styling is provided for these elements. If you want to enable them, please
// refer to a full flavor file for variable definitions.
// Variables for progress elements and spinners
$progress-back-color: #e0e0e0; // Background color for <progress>
$progress-fore-color: #0277bd; // Progress bar color for <progress>
$progress-height: 0.625rem; // Height of <progress>
$progress-max-value: 1000; // Arithmetic max value of <progress>
$progress-border-style: 0; // Border style for <progress>
$progress-border-radius: 2*$_1px; // Border radius for the <progress> container
$progress-top-bottom-margin: 0.5rem; // Top and bottom margin for <progress>
$progress-left-right-margin: 0.5rem; // Left and right margin for <progress>
$progress-box-shadow: none; // Box shadow for <progress>
$progress-inline-name: 'inline'; // Class name for inline <progress>
$progress-inline-width: 60%; // Width for inline <progress>
$progress-variant1-name: 'secondary'; // Class name for <progress> variant 1
$progress-variant1-fore-color: #e53935; // Progress bar color for <progress> variant 1
$progress-variant2-name: 'tertiary'; // Class name for <progress> variant 2
$progress-variant2-fore-color: #689f38; // Progress bar color for <progress> variant 2
$include-spinner-donut: false; // [Hidden flag override] Should spinner donuts be enabled? (`true`/`false`) [1]
// Notes :
// [1] - Due to the value of $include-spinner-donut being set to `false`, the spinner
// donut styling will not be included. To enable it, pelase refer to a full flavor.
// Variables for utilities and helper classes
$hidden-name: 'hidden'; // Class name for hidden elements
$visually-hidden-name: 'visually-hidden'; // Class name for visually hidden elements
$include-breadcrumbs: false; // [Hidden flag override] Should breadcrumbs be included? (`true`/`false`) [1]
$include-close-icon: false; // [Hidden flag override] Should the close icon be included? (`true`/`false`) [1]
$border-generic-name: 'bordered'; // Class name for generic border style
$border-radial-style1-name: 'rounded'; // Class name for radial border style 1
$border-radial-style1-radius: 2*$_1px; // Border radius for radial border style 1
$border-radial-style2-name: 'circular'; // Class name for radial border style 2
$border-radial-style2-radius: 50%; // Border radius for radial border style 2
$responsive-margin-name: 'responsive-margin'; // Class name for responsive margin
$responsive-margin-small-value: 0.25rem; // Margin value for responsive margin on small screens
$responsive-margin-medium-value: 0.375rem; // Margin value for responsive margin on medium screens
$responsive-margin-large-value: 0.5rem; // Margin value for responsive margin on large screens
$responsive-padding-name: 'responsive-padding'; // Class name for responsive padding
$responsive-padding-small-value: 0.125rem 0.25rem;// Padding value for responsive padding on small screens
$responsive-padding-medium-value: 0.25rem 0.375rem;// Padding value for responsive padding on medium screens
$responsive-padding-large-value: 0.375rem 0.5rem; // Padding value for responsive padding on large screens
$responsive-hidden-prefix: 'hidden'; // Class name prefix for responsive hidden elements
$responsive-visually-hidden-prefix: 'visually-hidden'; // Class name prefix for responsive visually hidden elements
// Notes:
// [1] - Due to the values of $include-breadcrumbs and $include-close-icon being set
// to `false`, these elements will not be included. Refer to a full flavor file for
// help on how to enable them.
@import '../mini/core';
@import '../mini/grid';
@import '../mini/input_control';
/*
Custom elements for forms and input elements.
*/
@include make-button-alt-color ($button-variant1-name, $button-variant1-back-color,
$button-variant1-back-opacity, $button-variant1-hover-back-opacity, $button-variant1-fore-color);
@include make-button-alt-color ($button-variant2-name, $button-variant2-back-color,
$button-variant2-back-opacity, $button-variant2-hover-back-opacity, $button-variant2-fore-color);
@include make-button-alt-color ($button-variant3-name, $button-variant3-back-color,
$button-variant3-back-opacity, $button-variant3-hover-back-opacity, $button-variant3-fore-color);
@include make-button-alt-style ($button-style1-name, $button-style1-border-style,
$button-style1-border-radius, $button-style1-padding, $button-style1-margin);
@include make-button-alt-style ($button-style2-name, $button-style2-border-style,
$button-style2-border-radius, $button-style2-padding, $button-style2-margin);
@import '../mini/navigation';
@import '../mini/table';
@import '../mini/card';
/*
Custom elements for cards and containers.
*/
@include make-card-alt-size ($card-size1-name, $card-size1-width);
@include make-card-section-alt-color ($card-section-style1-name, $card-section-style1-back-color,
$card-section-style1-fore-color);
@include make-card-section-alt-style ($card-section-padding1-name, $card-section-padding1-padding);
// --- --- ---
// Tab module is disabled for this flavor.
// @import '../mini/tab';
// --- --- ---
@import '../mini/contextual';
/*
Custom contextual background elements and alerts.
*/
@include make-mark-alt-color ($mark-variant1-name, $mark-variant1-back-color);
@include make-mark-alt-color ($mark-variant2-name, $mark-variant2-back-color);
@include make-mark-alt-style ($mark-style1-name, $mark-style1-border-style,
$mark-style1-border-radius, $mark-style1-padding);
@include make-mark-alt-style ($mark-style2-name, $mark-style2-border-style,
$mark-style2-border-radius, $mark-style2-padding, $mark-style2-font-size, $mark-style2-line-height);
@import '../mini/progress';
/*
Custom elements for progress elements and spinners.
*/
@include make-progress-inline ($progress-inline-name, $progress-inline-width);
@include make-progress-alt-color ($progress-variant1-name, $progress-variant1-fore-color);
@include make-progress-alt-color ($progress-variant2-name, $progress-variant2-fore-color);
@import '../mini/utility';
/*
Custom elements for utilities and helper classes.
*/
@include make-border-generic ($border-generic-name);
@include make-border-radial-style ($border-radial-style1-name, $border-radial-style1-radius);
@include make-border-radial-style ($border-radial-style2-name, $border-radial-style2-radius);
@include make-margin-responsive ($responsive-margin-name, $responsive-margin-small-value,
$responsive-margin-medium-value, $responsive-margin-large-value);
@include make-padding-responsive ($responsive-padding-name, $responsive-padding-small-value,
$responsive-padding-medium-value, $responsive-padding-large-value);
@include make-hidden-responsive ($responsive-hidden-prefix);
@include make-visually-hidden-responsive ($responsive-visually-hidden-prefix);
// This is a flavor file. Duplicate it and edit it to create your own flavor. Read instructions carefully.
// Single-line comments, starting with '//' will not be included in your final CSS file. Multiline comments,
// structured like the flavor description below, will be included in your final CSS file.
// Note: This flavor is not a full flavor, we strongly recommend you duplicate the mini-default flavor instead
// of this file, unless you know what you are doing.
/*
Flavor name: Lite (mini-lite)
Author: Angelos Chalaris (chalarangelo@gmail.com)
Maintainers: Angelos Chalaris
mini.css version: v2.3.4
*/
// Basic rules for body and typography
$fore-color: #212121; // Text and general foreground color
$back-color: #f8f8f8; // Body background color
$base-font-family: // Default font stack for all elements:
'-apple-system, BlinkMacSystemFont,\"Segoe UI\",\"Roboto\", \"Droid Sans\",\"Helvetica Neue\", Helvetica, Arial, sans-serif';
// OS X and iOS system fonts (San Francisco) -> Windows system fonts -> Android system fonts (newer and older) -> Fallback fonts
$base-root-font-size: 16px; // Root font sizing for all elements [1]
$_1px: (1px/$base-root-font-size) * 1rem; // Calculated rem value of 1px [1]
$base-font-size: 1rem; // Default font sizing for all elements [2]
$base-line-height: 1.5; // Default line height for all elements.
$use-fluid-typography: false; // Should fluid typography be used at the root element? (`true`/`false`)
$body-margin: 0; // Margin for the body
$apply-defaults-to-all: true; // Should default values be applied to all elements? (`true` or `false`) [3]
$h1-font-size: 2rem; // Font size of h1
$h2-font-size: 1.6875rem; // Font size for h2
$h3-font-size: 1.4375rem; // Font size for h3
$h4-font-size: 1.1875rem; // Font size for h4
$h5-font-size: 1rem; // Font size for h5
$h6-font-size: 0.8125rem; // Font size for h6
$heading-line-height: 1.2em; // Line height for all headings
$heading-margin: 0.75rem 0.5rem; // Margin for all headings
$heading-font-weight: 500; // Font weight for all headings
$heading-smalltext-fore-color: #424242; // <small> color in headings
$make-heading-smalltext-block: true; // Should <small> elements in headings be displayed as blocks (`true`/`false`) [4]
$heading-smalltext-b-font-size: 0.75em; // Font size of block <small> elements in headings
$heading-smalltext-b-top-margin:-0.25rem; // Top margin of block <small> elements in headings
$paragraph-margin: 0.5rem; // Margin for <p> elements
$list-margin: 0.5rem; // Margin for <ol> and <ul> elements
$list-left-padding: 1rem; // Left padding for <ol> and <ul> elements
$bold-font-weight: 700; // Font weight for <b> and <strong>
$horizontal-rule-line-height: 1.25em; // <hr> line height
$horizontal-rule-margin: 0.5rem; // <hr> margin
$horizontal-rule-border-style: $_1px solid #8c8c8c; // Border style for horizontal rules (used in the <hr> element's border-top)
$horizontal-rule-fancy-style: false; // Should a fancy styling be applied for the <hr> element (`true`/`false`) [5]
$blockquote-back-color: #eeeeee; // Background color for <blockquote>
$blockquote-fore-color: $fore-color; // Text color for <blockquote>
$blockquote-margin: 0.5rem; // Margin for <blockquote>
$blockquote-padding: 0.5rem 0.5rem 1.5rem;// Padding for <blockquote>
$blockquote-sidebar-style: 0; // Style for the sidebar of <blockquote>
$blockquote-cite-font-size: 0.875rem; // Font size for citation of <blockquote>
$blockquote-cite-fore-color: #505050; // Text color for citation of <blockquote>
$blockquote-cite-left-position: 0.625rem; // Left padding for citation of <blockquote>
$blockquote-cite-bottom-position: 0; // Bottom padding for citation of <blockquote>
$blockquote-border-style: 0; // Border style for <blockquote>
$blockquote-border-radius: 0 2px 2px 0; // Border radius for <blockquote>
$blockquote-box-shadow: none; // Box shadow for <blockquote>
$use-default-code-fonts: true; // Should default font choice (monospace) be used for code elements? (`true`/`false`) [6]
$code-element-padding: 0.125rem 0.25rem; // Padding for <code>
$code-element-fore-color: $fore-color; // Text color for <code>
$code-element-back-color: #e6e6e6; // Background color for <code>
$code-element-border-style: 0; // Border style for <code>
$code-element-border-radius: 2*$_1px; // Border radius for <code>
$code-element-box-shadow: none; // Box shadow for <code>
$pre-element-padding: 0.75rem; // Padding for <pre>
$pre-element-fore-color: $code-element-fore-color; // Text color for <pre>
$pre-element-back-color: $code-element-back-color; // Background color for <pre>
$pre-element-border-style: 0; // Border style for <pre>
$pre-element-border-radius: 0 2*$_1px 2*$_1px 0;// Border radius for <pre>
$pre-element-margin: 0.5rem; // Margin for <pre>
$pre-element-box-shadow: none; // Box shadow for <pre>
$add-pre-element-sidebar: false; // Should a fancy sidebar be added to the left side of <pre> (`true`/`false`) [7]
$kbd-element-padding: $code-element-padding; // Padding for <kbd>
$kbd-element-fore-color: #fafafa; // Text color for <kbd>
$kbd-element-back-color: #0c0c0c; // Background color for <kbd>
$kbd-element-border-style: 0; // Border style for <kbd>
$kbd-element-border-radius: $code-element-border-radius; // Border radius for <kbd>
$kbd-element-box-shadow: $code-element-box-shadow; // Box shadow for <kbd>
$style-samp-element: false; // Should styles for <samp> be included? (`true`/`false`) [8]
$include-dfn-fix: true; // Should the fix for Android 4.3 concerning <dfn> be included (`true`/`false`) [9]
$small-font-size: 0.75em; // Font size for <small> elements
$sup-font-size: 0.75em; // Font size for <sup> elements
$sub-font-size: 0.75em; // Font size for <sub> elements
$sup-top: -0.5em; // <sup> top
$sub-bottom: -0.25em; // <sub> bottom
$link-fore-color: #0277bd; // Text color for <a>
$link-visited-fore-color: #01579b; // Text color for visited <a>
$link-font-weight: 500; // Font weight for <a>
$apply-link-underline: true; // Should an underline be applied to all <a> elements? (`true`/`false`) [10]
$apply-link-hover-fade: true; // Should the :hover and :focus state of <a> elements use fade-out instead of a different color (`true`/`false`) [11]
$figcaption-font-size: 0.8125rem; // Font size of <figcaption> elements
$figcaption-fore-color: #424242; // Text color for <figcaption> elements
// Notes:
// [1] - The value $base-root-font-size should be in `px` only! This rule is very important, as it will determine the root
// element's font sizing. The value of $_1px is calculated based on the value of $base-root-font-size, please do not alter
// the way that it's calculated.
// [2] - The value of $base-font-size will only be used if the value of $apply-defaults-to-all is set to `true` (see [3]).
// This is due to the fact that applying the value of it on the root element again will overwrite the value of
// $base-root-font-size (see [1]). The value of this variable should be set in either `em` or `rem`.
// [3] - It is recommended to set the value of $apply-defaults-to-all to `true`, unless you want to apply extra styling
// to elements manually.
// [4] - If the value of $make-heading-smalltext-block is `true` the <small> elements in headings will be displayed below
// the main heading and the 2 values specified below will apply.
// [5] - If $horizontal-rule-fancy-style is set to `true` the value of $horizontal-rule-border-style will not be used and
// a gradient with the style specified in $horizontal-rule-fancy-gradient will be applied instead.
// [6] - If the value of $use-default-code-fonts is set to `false` the value of $code-font-family will be used. `true`
// will apply the proper fix to use monospace font without any problems on all browsers.
// [7] - if the value of $add-pre-element-sidebar is set to true, the style specified in $pre-element-sidebar-style will
// be applied as a left border for the <pre> elements.
// [8] - If the value of $style-samp-element is set to `false`, no styling will be included in the final CSS file for
// `samp` elements. Otherwise, the styling defined in the $samp-... variables will be applied.
// [9] - If the value of $include-dfn-fix is set to `true` a styling fix will be applied, so that the <dfn> elements are
// displayed properly on older versions of Android (4.3-) in italics. Otherwise, said fix will not be included.
// [10] - If the value of $apply-link-underline is set to `true`, an underline will be applied to the link in its normal
// color, as defined in $link-fore-color.
// [11] - If `$apply-link-hover-fade` is set to `true`, a fading transition will be used for the link when hovered over or
// focused. Otherwise, the color specified in $link-hover-fore-color will be used.
// Variables for grid elements
$use-four-step-grid: false; // Should the old 4-step grid system be used instead of the new (`true`/`false`) [1]
$include-parent-layout: true; // Should the classes for rows defining the column layout of children be included (`true`/`false`) [2]
$grid-container-name: 'container'; // Class name for the grid container
$grid-container-side-padding: 0.75rem; // Padding for the grid container (left and right only)
$grid-row-name: 'row'; // Class name for the grid's rows
$grid-row-parent-layout-prefix:'cols'; // Class name prefix for the grid's row parents [2]
$grid-column-prefix: 'col'; // Class name prefix for the grid's columns
$grid-column-offset-suffix: 'offset'; // Class name suffix for the grid's offsets
$grid-order-normal-suffix: 'normal'; // Class name suffix for grid columns with normal priority
$grid-order-first-suffix: 'first'; // Class name suffix for grid columns with highest priority
$grid-order-last-suffix: 'last'; // Class name suffix for grid columns with lowest priorty
$grid-column-count: 12; // Number of columns in the grid (integer value only)
$grid-column-padding: 0 0.25rem; // Padding for the columns of the grid
$grid-small-prefix: 'sm'; // Small screen class prefix for grid
$grid-medium-breakpoint: 768px; // Medium screen breakpoint for grid
$grid-medium-prefix: 'md'; // Medium screen class prefix for grid
$grid-large-breakpoint: 1280px; // Large screen breakpoint for grid
$grid-large-prefix: 'lg'; // Large screen class prefix for grid
// Notes:
// [1] - If the value of $use-four-step-grid is `true`, the grid system will contain 4 breakpoints instead of 3, along with
// the needed styles. In this case, values should be specified for $grid-extra-small-prefix and $grid-small-breakpoint.
// [2] - If the value of $include-parent-layout is `true`, the grid system will contain extra classes that will define the column
// layout of their children. In this case, a value should be specified for $grid-row-parent-layout-prefix.
// Variables for forms and inputs
$form-back-color: #eeeeee; // Background color for forms
$form-fore-color: $fore-color; // Text color for forms
$form-border-style: $_1px solid #c9c9c9; // Border style for forms
$form-border-radius: 0; // Border radius for forms
$form-margin: 0.5rem; // Margin for forms
$form-padding: 0.75rem 0.5rem 1.125rem; // Padding for forms
$form-box-shadow: none; // Box shadow for forms
$fieldset-back-color: $form-back-color; // Background color for fieldset
$fieldset-border-style: $_1px solid #d0d0d0; // Border style for fieldset
$fieldset-border-radius: 2*$_1px; // Border radius for fieldset
$fieldset-margin: 0.125rem; // Margin for fieldset
$fieldset-padding: 0.5rem; // Padding for fieldset
$legend-font-weight: $bold-font-weight; // Font weight for legend
$legend-font-size: 0.875rem; // Font size for legend
$legend-fore-color: $form-fore-color; // Text color for legend
$legend-padding: 0.125rem 0.25rem; // Padding for legend
$label-padding: 0.25rem 0.5rem; // Padding for label
$input-group-name: 'input-group'; // Class for input groups
$include-fluid-input-group: false; // Should fluid input grooups be included? (`true`/`false`) [1]
$include-vertical-input-group: false; // Should vertical input grooups be included? (`true`/`false`) [1]
$input-back-color: #fafafa; // Background for input
$input-fore-color: $fore-color; // Text color for input
$input-border-style: $_1px solid #c9c9c9; // Border style for input
$input-border-radius: 2*$_1px; // Border radius for input
$input-margin: 0.25rem; // Margin for input
$input-padding: 0.5rem 0.75rem; // Padding for input
$input-focus-border-color: #0288d1; // Border color for focused input
$input-invalid-border-color: #d32f2f; // Border color for invalid input
$input-disabled-opacity: 0.75; // Opacity for disabled input
$input-readonly-back-color: #e5e5e5; // Background color for readonly input
$input-readonly-border-color: #c9c9c9; // Border color for readonly input
$input-placeholder-fore-color:#616161; // Text color for input placeholder
$apply-select-fix: false; // [Hidden flag override] Should the styles that fix <select> styling be applied? (`true`/`false`)
$button-back-color: #dcdcdc; // Back color for button elements
$button-back-opacity: 0.75; // Background opacity for button elements
$button-hover-back-opacity: 1; // Background opacity for button elements on hover or focus
$button-fore-color: $fore-color; // Text color for button elements
$button-border-style: 0; // Border style for button elements
$button-border-radius: 2*$_1px; // Border radius for button elements
$button-padding: 0.5rem 0.75rem; // Padding for button elements
$button-margin: 0.5rem; // Margin for button elements
$button-box-shadow: none; // Box shadow for buttons
$button-disabled-opacity:0.75; // Disabled button elements opacity
$button-class-name: 'button'; // Class for custom button elements
$include-button-group: false; // [Hidden flag override] Should button groups be enabled? (`true`/`false`) [2]
$hide-file-inputs: true; // Should a style be added that makes all <input>s of type `file` hidden? (`true`/`false`) [3]
$button-variant1-name: 'primary'; // Class name for button variant 1
$button-variant1-back-color: #0277bd; // Background color for button variant 1
$button-variant1-back-opacity: 0.9; // Background opacity for button variant 1
$button-variant1-hover-back-opacity: 1; // Background opacity for button variant 1 on hover or focus
$button-variant1-fore-color: #fafafa; // Text color for button variant 1
$button-variant2-name: 'secondary';// Class name for button variant 2
$button-variant2-back-color: #c62828; // Background color for button variant 2
$button-variant2-back-opacity: 0.9; // Background opacity for button variant 2
$button-variant2-hover-back-opacity: 1; // Background opacity for button variant 2 on hover or focus
$button-variant2-fore-color: #fafafa; // Text color for button variant 2
$button-variant3-name: 'tertiary';// Class name for button variant 3
$button-variant3-back-color: #5f9133; // Background color for button variant 3
$button-variant3-back-opacity: 0.9; // Background opacity for button variant 3
$button-variant3-hover-back-opacity: 1; // Background opacity for button variant 3 on hover or focus
$button-variant3-fore-color: #fafafa; // Text color for button variant 3
$button-style1-name: 'small'; // Class name for button style 1
$button-style1-border-style: 0; // Border style for button style 1
$button-style1-border-radius: $_1px; // Border radius for button style 1
$button-style1-padding: 0.25rem 0.375rem; // Padding for button style 1
$button-style1-margin: 0.5rem; // Margin for button style 1
$button-style2-name: 'large'; // Class name for button style 2
$button-style2-border-style: 0; // Border style for button style 2
$button-style2-border-radius: 4*$_1px; // Border radius for button style 2
$button-style2-padding: 0.75rem 1.125rem; // Padding for button style 2
$button-style2-margin: 0.5rem; // Margin for button style 2
$checkbox-size: 1rem; // Size for checkbox/radio [4]
$checkbox-back-color: $input-back-color;// Background clor for checkbox/radio
$checkbox-fore-color: $input-fore-color;// Text/mark color for checkbox/radio
$checkbox-border-thickness: $_1px; // Border thickness for checkbox/radio
$checkbox-border-color: #bdbdbd; // Border color for checkbox/radio
$checkbox-border-radius: $input-border-radius;// Border radius for checkbox/radio
$checkbox-focus-border-color: $input-focus-border-color;// Border color for checkbox/radio on focus
$checkbox-bottom-spacing: 0.375rem; // Bottom spacing for checkbox/radio
$checkbox-disabled-opacity: $input-disabled-opacity;// Opacity for disabled checkbox/radio
$checkbox-box-shadow: none; // Box shadow for checkbox/radio
$include-switch: false; // Should switch components be included? (`true`/`false`) [5]
// Notes:
// [1] - If the value of $include-fluid-input-group is `true`, fluid input groups will be included, using the values
// specified in the corresponding variables. The same applies for $include-vertical-input-group and vertical input groups.
// [2] - Due to the fact that the value of $include-button-group is set to `false`, no button group styles will be created.
// If you wish to enable them, please refer to a full flavor for the required variables.
// [3] - If the value of $hide-file-inputs is `true`, all <input type="file"> elements will be hidden and the only way
// to access them is via the use of <label> elements that are linked to them. This option is enabled by default to
// allow for universal button styles, even for file input buttons, but can be disabled if the base style is desired.
// If the value is `false`, some fixes will be applied to the <input type="file"> element.
// [4] - The value of $checkbox-size will determine a few variables like some `margin` values, `height`, `width` etc.
// Variables for navigational elements
// [5] - Due to the fact that the value of $include-switch is set to `false`, no switch styles will be created.
// If you wish to enable them, please refer to a full flavor for the required variables.
$header-height: 2.75rem; // Height for <header>
$header-back-color: #12171a; // Background color for <header>
$header-fore-color: #f5f5f5; // Text color for <header>
$header-border-style: 0; // Border style for <header>
$header-margin: 0; // Margin for <header>
$header-padding: 0.125rem 0.5rem; // Padding for <header>
$header-box-shadow: none; // Box shadow for <header>
$header-logo-name: 'logo'; // Class name for <header>'s logo
$header-logo-font-size: 1.75rem; // Font size for <header>'s logo
$header-logo-line-height: 1.3125em; // Line height for <header>'s logo
$header-logo-margin: 0.0625rem 0.375rem 0.0625rem 0.0625rem; // Margin for <header>'s logo
$header-logo-padding: 0; // Padding for <header>'s logo
$header-link-hover-color: #20292e; // Hover color for <header>'s links
$header-link-margin: 0.125rem 0; // Margin for <header>'s links
$include-header-sticky: true; // Should sticky <header> elements be included? (`true`/`false`) [1]
$header-sticky-name: 'sticky'; // Class name for sticky <header>
$include-nav-styles: false; // [Hidden flag override] Should <nav> elements by stylized? (`true`/`false`) [2]
$include-drawer: false; // [Hidden flag override] Should the drawer component be included? (`true`/`false`) [2]
$footer-back-color: #192024; // Background color for <footer>
$footer-fore-color: #f5f5f5; // Text color for <footer>
$footer-border-style: 0; // Border stye for <footer>
$footer-font-size: 0.875rem; // Font size for <footer>
$footer-margin: 1rem 0 0; // Margin for <footer>
$footer-padding: 1.5rem 0.5rem 0.75rem; // Padding for <footer>
$footer-link-fore-color: #0288d1; // Text color for links in <footer>
$include-footer-sticky: true; // Should sticky <footer> elements be included (`true`/`false`) [3]
$footer-sticky-name: 'sticky'; // Class name for sticky <footer> elements
// Notes:
// [1] - If the value of $include-header-sticky is `true`, a class will be created that will allow for sticky positioning
// of <header> elements, using the value of $header-sticky-name for the name of the class.
// [2] - Due to the fact that the values of $include-nav-styles and $include-drawer are set to `false`, <nav> elements
// will not be stylized and the drawer component will not be included. If you set it to `true`, please refer to a full
// flavor to find the required variable definitions.
// [3] - If the value of $include-footer-bottom is `true`, a class will be created that will allow for sticky positioning
// of <footer> elements, using the value of $footer-sticky-name for the name of the class.
// Variables for responsive tables
$table-border-style: $_1px solid #c9c9c9; // Border style for <table> and children
$table-border-radius: 0; // Border radius for <table> and children
$table-margin: 0 auto; // Margin for <table>
$table-box-shadow: none; // Box shadow for <table>
$table-caption-font-size: 1.5rem; // Font size for <caption>
$table-caption-margin: 0.5rem; // Margin for <caption>
$table-row-padding: 0.5rem; // Padding for <tr> - both views
$table-column-padding: 0.625rem; // Padding for <td> and <th> - desktop view
$table-head-back-color: #e6e6e6; // Background color for <th>
$table-head-fore-color: $fore-color; // Text color for <th>
$table-body-back-color: #fafafa; // Background color for <td>
$table-body-fore-color: $fore-color; // Text color for <td>
$table-mobile-breakpoint: 767px; // Breakpoint for <table> mobile view
$table-mobile-card-spacing: 0.625rem; // Space between <tr> cards - mobile view
$table-mobile-card-label: 'data-label'; // Attribute used to replace column headers in mobile view [1]
$table-mobile-label-font-weight:$bold-font-weight; // Font weight for mobile headers
$include-horizontal-table: false; // Should horizontal <table> elements be included? (`true`/`false`) [2]
$include-scrollable-table: false; // Should scrollable <table> elements be included? (`true`/`false`) [2]
$include-striped-table: false; // [Hidden flag override] Should striped <table> elements be included (`true`/`false`) [2]
// Notes:
// [1] - The attribute specified in $table-mobile-card-label must be added manually to each and every element in the table
// in order for their mobile headers to display properly.
// [2] - Due to the $include-horizontal-table, $include-scrollable-table and $include-striped-table flags being set to `false`,
// no styling will be provided for horizontal, scrollable and striped <table> elements. Please refer to a full fulavor to find
// the variables associated with these components, if you want to enable them.
$card-name: 'card'; // Class name for cards
$card-back-color: #fafafa; // Background color for cards
$card-fore-color: $fore-color; // Text color for cards
$card-border-style: $_1px solid #acacac; // Border style for cards
$card-border-radius: 0; // Border radius for cards
$card-margin: 0.5rem; // Margin for cards
$card-box-shadow: none; // Box shadow for cards
$card-section-name: 'section'; // Class name for card sections
$card-section-border-style: $_1px solid #c9c9c9;// Border style for card sections
$card-section-padding: 0.5rem; // Padding for card sections
$card-section-media-name: 'media'; // Class name for card media sections
$card-section-media-height: 200px; // Height for card media setions
$card-normal-width: 320px; // Width for normal cards
$card-size1-name: 'fluid'; // Class name for fluid cards
$card-size1-width: 100%; // Width for fluid cards
$card-section-style1-name: 'dark'; // Class name for card section style 1
$card-section-style1-back-color: #e0e0e0; // Background color for card section style 1
$card-section-style1-fore-color: $fore-color; // Text color for card section style 1
$card-section-padding1-name: 'double-padded'; // Class name for card section padding style 1
$card-section-padding1-padding: 0.75rem; // Padding for card section padding style 1
// Notes:
// [1] - The cards module depends heavily on the grid system module.
// --- --- ---
// No variables specified for the tab module. This module is disabled by default.
// To re-enable it, please refer to a full flavor for variables and documentation.
// --- --- ---
// Variables for contextual background elements and alerts
$mark-back-color: #0277bd; // Background color for <mark>
$mark-fore-color: #fafafa; // Text color for <mark>
$mark-font-size: 0.9375em; // Font size for <mark>
$mark-line-height: 1em; // Line height for <mark>
$mark-border-style: 0; // Border style for <mark>
$mark-border-radius: 2*$_1px; // Border radius for <mark>
$mark-padding: 0.125em 0.25em; // Padding for <mark>
$mark-margin: 0; // Margin for <mark>
$mark-box-shadow: none; // Box shadow for <mark>
$mark-inline-block-name: 'inline-block'; // Class name for <mark> inline block styling
$mark-variant1-name: 'secondary'; // Class name for <mark> variant 1
$mark-variant1-back-color: #e53935; // Background color for <mark> variant 1
$mark-variant2-name: 'tertiary'; // Class name for <mark> variant 2
$mark-variant2-back-color: #689f38; // Background color for <mark> variant 2
$mark-style1-name: 'tag'; // Class name for <mark> style 1
$mark-style1-border-style: 0; // Border style for <mark> style 1
$mark-style1-border-radius: 200px; // Border radius for <mark> style 1
$mark-style1-padding: 0.25em 0.5em; // Padding for <mark> style 1
$mark-style2-name: 'inline-block'; // Class name for <mark> style 2
$mark-style2-border-style: 0; // Border style for <mark> style 2
$mark-style2-border-radius: 2*$_1px; // Border radius for <mark> style 2
$mark-style2-padding: 0.375em; // Padding for <mark> style 2
$mark-style2-font-size: 1em; // Font size for <mark> style 2
$mark-style2-line-height: 1.375em; // Line height for <mark> style 2
$include-toast: false; // [Hidden flag override] Should toasts be included? (`true`/`false``) [1]
$include-tooltip: false; // Should tooltips be included? (`true`/`false`) [1]
$include-modal: false; // Should modals be included? (`true`/`false`) [1]
// Notes:
// [1] - Due to the values of $include-toast, $include-tooltip and $include-modal being set
// to `false`, no styling is provided for these elements. If you want to enable them, please
// refer to a full flavor file for variable definitions.
// Variables for progress elements and spinners
$progress-back-color: #e0e0e0; // Background color for <progress>
$progress-fore-color: #0277bd; // Progress bar color for <progress>
$progress-height: 0.625rem; // Height of <progress>
$progress-max-value: 1000; // Arithmetic max value of <progress>
$progress-border-style: 0; // Border style for <progress>
$progress-border-radius: 2*$_1px; // Border radius for the <progress> container
$progress-top-bottom-margin: 0.5rem; // Top and bottom margin for <progress>
$progress-left-right-margin: 0.5rem; // Left and right margin for <progress>
$progress-box-shadow: none; // Box shadow for <progress>
$progress-inline-name: 'inline'; // Class name for inline <progress>
$progress-inline-width: 60%; // Width for inline <progress>
$progress-variant1-name: 'secondary'; // Class name for <progress> variant 1
$progress-variant1-fore-color: #e53935; // Progress bar color for <progress> variant 1
$progress-variant2-name: 'tertiary'; // Class name for <progress> variant 2
$progress-variant2-fore-color: #689f38; // Progress bar color for <progress> variant 2
$include-spinner-donut: false; // [Hidden flag override] Should spinner donuts be enabled? (`true`/`false`) [1]
// Notes :
// [1] - Due to the value of $include-spinner-donut being set to `false`, the spinner
// donut styling will not be included. To enable it, pelase refer to a full flavor.
// Variables for utilities and helper classes
$hidden-name: 'hidden'; // Class name for hidden elements
$visually-hidden-name: 'visually-hidden'; // Class name for visually hidden elements
$include-breadcrumbs: false; // [Hidden flag override] Should breadcrumbs be included? (`true`/`false`) [1]
$include-close-icon: false; // [Hidden flag override] Should the close icon be included? (`true`/`false`) [1]
$border-generic-name: 'bordered'; // Class name for generic border style
$border-radial-style1-name: 'rounded'; // Class name for radial border style 1
$border-radial-style1-radius: 2*$_1px; // Border radius for radial border style 1
$border-radial-style2-name: 'circular'; // Class name for radial border style 2
$border-radial-style2-radius: 50%; // Border radius for radial border style 2
$responsive-margin-name: 'responsive-margin'; // Class name for responsive margin
$responsive-margin-small-value: 0.25rem; // Margin value for responsive margin on small screens
$responsive-margin-medium-value: 0.375rem; // Margin value for responsive margin on medium screens
$responsive-margin-large-value: 0.5rem; // Margin value for responsive margin on large screens
$responsive-padding-name: 'responsive-padding'; // Class name for responsive padding
$responsive-padding-small-value: 0.125rem 0.25rem;// Padding value for responsive padding on small screens
$responsive-padding-medium-value: 0.25rem 0.375rem;// Padding value for responsive padding on medium screens
$responsive-padding-large-value: 0.375rem 0.5rem; // Padding value for responsive padding on large screens
$responsive-hidden-prefix: 'hidden'; // Class name prefix for responsive hidden elements
$responsive-visually-hidden-prefix: 'visually-hidden'; // Class name prefix for responsive visually hidden elements
// Notes:
// [1] - Due to the values of $include-breadcrumbs and $include-close-icon being set
// to `false`, these elements will not be included. Refer to a full flavor file for
// help on how to enable them.
@import '../mini/core';
@import '../mini/grid';
@import '../mini/input_control';
/*
Custom elements for forms and input elements.
*/
@include make-button-alt-color ($button-variant1-name, $button-variant1-back-color,
$button-variant1-back-opacity, $button-variant1-hover-back-opacity, $button-variant1-fore-color);
@include make-button-alt-color ($button-variant2-name, $button-variant2-back-color,
$button-variant2-back-opacity, $button-variant2-hover-back-opacity, $button-variant2-fore-color);
@include make-button-alt-color ($button-variant3-name, $button-variant3-back-color,
$button-variant3-back-opacity, $button-variant3-hover-back-opacity, $button-variant3-fore-color);
@include make-button-alt-style ($button-style1-name, $button-style1-border-style,
$button-style1-border-radius, $button-style1-padding, $button-style1-margin);
@include make-button-alt-style ($button-style2-name, $button-style2-border-style,
$button-style2-border-radius, $button-style2-padding, $button-style2-margin);
@import '../mini/navigation';
@import '../mini/table';
@import '../mini/card';
/*
Custom elements for cards and containers.
*/
@include make-card-alt-size ($card-size1-name, $card-size1-width);
@include make-card-section-alt-color ($card-section-style1-name, $card-section-style1-back-color,
$card-section-style1-fore-color);
@include make-card-section-alt-style ($card-section-padding1-name, $card-section-padding1-padding);
// --- --- ---
// Tab module is disabled for this flavor.
// @import '../mini/tab';
// --- --- ---
@import '../mini/contextual';
/*
Custom contextual background elements and alerts.
*/
@include make-mark-alt-color ($mark-variant1-name, $mark-variant1-back-color);
@include make-mark-alt-color ($mark-variant2-name, $mark-variant2-back-color);
@include make-mark-alt-style ($mark-style1-name, $mark-style1-border-style,
$mark-style1-border-radius, $mark-style1-padding);
@include make-mark-alt-style ($mark-style2-name, $mark-style2-border-style,
$mark-style2-border-radius, $mark-style2-padding, $mark-style2-font-size, $mark-style2-line-height);
@import '../mini/progress';
/*
Custom elements for progress elements and spinners.
*/
@include make-progress-inline ($progress-inline-name, $progress-inline-width);
@include make-progress-alt-color ($progress-variant1-name, $progress-variant1-fore-color);
@include make-progress-alt-color ($progress-variant2-name, $progress-variant2-fore-color);
@import '../mini/utility';
/*
Custom elements for utilities and helper classes.
*/
@include make-border-generic ($border-generic-name);
@include make-border-radial-style ($border-radial-style1-name, $border-radial-style1-radius);
@include make-border-radial-style ($border-radial-style2-name, $border-radial-style2-radius);
@include make-margin-responsive ($responsive-margin-name, $responsive-margin-small-value,
$responsive-margin-medium-value, $responsive-margin-large-value);
@include make-padding-responsive ($responsive-padding-name, $responsive-padding-small-value,
$responsive-padding-medium-value, $responsive-padding-large-value);
@include make-hidden-responsive ($responsive-hidden-prefix);
@include make-visually-hidden-responsive ($responsive-visually-hidden-prefix);

File diff suppressed because it is too large Load diff

View file

@ -1,468 +1,468 @@
// This is a flavor file. Duplicate it and edit it to create your own flavor. Read instructions carefully.
// Single-line comments, starting with '//' will not be included in your final CSS file. Multiline comments,
// structured like the flavor description below, will be included in your final CSS file.
// Note: This flavor is not a full flavor, we strongly recommend you duplicate the mini-default flavor instead
// of this file, unless you know what you are doing.
/*
Flavor name: Progressive Web App (mini-pw)
Author: Angelos Chalaris (chalarangelo@gmail.com)
Maintainers: Angelos Chalaris
mini.css version: v2.3.4
*/
// Basic rules for body and typography
$fore-color: #212121; // Text and general foreground color
$back-color: #eeeeee; // Body background color
$base-font-family: // Default font stack for all elements:
'-apple-system, BlinkMacSystemFont,\"Segoe UI\",\"Roboto\", \"Droid Sans\",\"Helvetica Neue\", Helvetica, Arial, sans-serif';
// OS X and iOS system fonts (San Francisco) -> Windows system fonts -> Android system fonts (newer and older) -> Fallback fonts
$base-root-font-size: 16px; // Root font sizing for all elements [1]
$_1px: (1px/$base-root-font-size) * 1rem; // Calculated rem value of 1px [1]
$base-font-size: 1rem; // Default font sizing for all elements [2]
$base-line-height: 1.5; // Default line height for all elements.
$use-fluid-typography: false; // Should fluid typography be used at the root element? (`true`/`false`)
$body-margin: 0; // Margin for the body
$apply-defaults-to-all: true; // Should default values be applied to all elements? (`true` or `false`) [3]
$h1-font-size: 2.4375rem; // Font size of h1
$h2-font-size: 1.935rem; // Font size for h2
$h3-font-size: 1.5625rem; // Font size for h3
$h4-font-size: 1.25rem; // Font size for h4
$h5-font-size: 1rem; // Font size for h5
$h6-font-size: 0.8125rem; // Font size for h6
$heading-line-height: 1.25em; // Line height for all headings
$heading-margin: 0.75rem 0.5rem; // Margin for all headings
$heading-font-weight: 500; // Font weight for all headings
$heading-smalltext-fore-color: #424242; // <small> color in headings
$make-heading-smalltext-block: true; // Should <small> elements in headings be displayed as blocks (`true`/`false`) [4]
$heading-smalltext-b-font-size: 0.75em; // Font size of block <small> elements in headings
$heading-smalltext-b-top-margin:-0.25em; // Top margin of block <small> elements in headings
$paragraph-margin: 0.5rem; // Margin for <p> elements
$list-margin: 0.5rem; // Margin for <ol> and <ul> elements
$list-left-padding: 1.25rem; // Left padding for <ol> and <ul> elements
$bold-font-weight: 600; // Font weight for <b> and <strong>
$horizontal-rule-line-height: 1.25em; // <hr> line height
$horizontal-rule-margin: 0.5rem; // <hr> margin
$horizontal-rule-border-style: $_1px solid #757575; // Border style for horizontal rules (used in the <hr> element's border-top)
$horizontal-rule-fancy-style: false; // Should a fancy styling be applied for the <hr> element (`true`/`false`) [5]
$blockquote-back-color: #e0e0e0; // Background color for <blockquote>
$blockquote-fore-color: $fore-color; // Text color for <blockquote>
$blockquote-margin: 0.5rem; // Margin for <blockquote>
$blockquote-padding: 0.5rem 0.5rem 1.5rem;// Padding for <blockquote>
$blockquote-sidebar-style: 4*$_1px solid #3f51b5;// Style for the sidebar of <blockquote>
$blockquote-cite-font-size: 0.875rem; // Font size for citation of <blockquote>
$blockquote-cite-fore-color: #616161; // Text color for citation of <blockquote>
$blockquote-cite-left-position: 0.625rem; // Left padding for citation of <blockquote>
$blockquote-cite-bottom-position: 0; // Bottom padding for citation of <blockquote>
$blockquote-border-style: 0; // Border style for <blockquote>
$blockquote-border-radius: 0 3*$_1px 3*$_1px 0; // Border radius for <blockquote>
$blockquote-box-shadow: // Box shadow for <blockquote>
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$use-default-code-fonts: true; // Should default font choice (monospace) be used for code elements? (`true`/`false`) [6]
$code-element-padding: 0.125rem 0.25rem; // Padding for <code>
$code-element-fore-color: $fore-color; // Text color for <code>
$code-element-back-color: #e0e0e0; // Background color for <code>
$code-element-border-style: 0; // Border style for <code>
$code-element-border-radius: 2*$_1px; // Border radius for <code>
$code-element-box-shadow: // Box shadow for <code>
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$pre-element-padding: 0.75rem; // Padding for <pre>
$pre-element-fore-color: $code-element-fore-color; // Text color for <pre>
$pre-element-back-color: $code-element-back-color; // Background color for <pre>
$pre-element-border-style: 0; // Border style for <pre>
$pre-element-border-radius: 0 3*$_1px 3*$_1px 0;// Border radius for <pre>
$pre-element-margin: 0.5rem; // Margin for <pre>
$pre-element-box-shadow: // Box shadow for <pre>
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$add-pre-element-sidebar: true; // Should a fancy sidebar be added to the left side of <pre> (`true`/`false`) [7]
$pre-element-sidebar-style: 4*$_1px solid #303f9f;// Style of the sidebar of <pre>
$kbd-element-padding: $code-element-padding; // Padding for <kbd>
$kbd-element-fore-color: #fafafa; // Text color for <kbd>
$kbd-element-back-color: #212121; // Background color for <kbd>
$kbd-element-border-style: 0; // Border style for <kbd>
$kbd-element-border-radius: $code-element-border-radius; // Border radius for <kbd>
$kbd-element-box-shadow: $code-element-box-shadow; // Box shadow for <kbd>
$style-samp-element: false; // Should styles for <samp> be included? (`true`/`false`) [8]
$include-dfn-fix: true; // Should the fix for Android 4.3 concerning <dfn> be included (`true`/`false`) [9]
$small-font-size: 0.75em; // Font size for <small> elements
$sup-font-size: 0.75em; // Font size for <sup> elements
$sub-font-size: 0.75em; // Font size for <sub> elements
$sup-top: -0.5em; // <sup> top
$sub-bottom: -0.25em; // <sub> bottom
$link-fore-color: #3f51b5; // Text color for <a>
$link-visited-fore-color: #3f51b5; // Text color for visited <a>
$link-font-weight: 500; // Font weight for <a>
$apply-link-underline: true; // Should an underline be applied to all <a> elements? (`true`/`false`) [10]
$apply-link-hover-fade: true; // Should the :hover and :focus state of <a> elements use fade-out instead of a different color (`true`/`false`) [11]
$figcaption-font-size: 0.8125rem; // Font size of <figcaption> elements
$figcaption-fore-color: #424242; // Text color for <figcaption> elements
// Notes:
// [1] - The value $base-root-font-size should be in `px` only! This rule is very important, as it will determine the root
// element's font sizing. The value of $_1px is calculated based on the value of $base-root-font-size, please do not alter
// the way that it's calculated.
// [2] - The value of $base-font-size will only be used if the value of $apply-defaults-to-all is set to `true` (see [3]).
// This is due to the fact that applying the value of it on the root element again will overwrite the value of
// $base-root-font-size (see [1]). The value of this variable should be set in either `em` or `rem`.
// [3] - It is recommended to set the value of $apply-defaults-to-all to `true`, unless you want to apply extra styling
// to elements manually.
// [4] - If the value of $make-heading-smalltext-block is `true` the <small> elements in headings will be displayed below
// the main heading and the 2 values specified below will apply.
// [5] - If $horizontal-rule-fancy-style is set to `true` the value of $horizontal-rule-border-style will not be used and
// a gradient with the style specified in $horizontal-rule-fancy-gradient will be applied instead.
// [6] - If the value of $use-default-code-fonts is set to `false` the value of $code-font-family will be used. `true`
// will apply the proper fix to use monospace font without any problems on all browsers.
// [7] - if the value of $add-pre-element-sidebar is set to true, the style specified in $pre-element-sidebar-style will
// be applied as a left border for the <pre> elements.
// [8] - If the value of $style-samp-element is set to `false`, no styling will be included in the final CSS file for
// `samp` elements. Otherwise, the styling defined in the $samp-... variables will be applied.
// [9] - If the value of $include-dfn-fix is set to `true` a styling fix will be applied, so that the <dfn> elements are
// displayed properly on older versions of Android (4.3-) in italics. Otherwise, said fix will not be included.
// [10] - If the value of $apply-link-underline is set to `true`, an underline will be applied to the link in its normal
// color, as defined in $link-fore-color.
// [11] - If `$apply-link-hover-fade` is set to `true`, a fading transition will be used for the link when hovered over or
// focused. Otherwise, the color specified in $link-hover-fore-color will be used.
// Variables for grid elements
$use-four-step-grid: false; // Should the old 4-step grid system be used instead of the new (`true`/`false`) [1]
$include-parent-layout: true; // Should the classes for rows defining the column layout of children be included (`true`/`false`) [2]
$grid-container-name: 'container'; // Class name for the grid container
$grid-container-side-padding: 0.75rem; // Padding for the grid container (left and right only)
$grid-row-name: 'row'; // Class name for the grid's rows
$grid-row-parent-layout-prefix:'cols'; // Class name prefix for the grid's row parents [2]
$grid-column-prefix: 'col'; // Class name prefix for the grid's columns
$grid-column-offset-suffix: 'offset'; // Class name suffix for the grid's offsets
$grid-order-normal-suffix: 'normal'; // Class name suffix for grid columns with normal priority
$grid-order-first-suffix: 'first'; // Class name suffix for grid columns with highest priority
$grid-order-last-suffix: 'last'; // Class name suffix for grid columns with lowest priorty
$grid-column-count: 12; // Number of columns in the grid (integer value only)
$grid-column-padding: 0 0.25rem; // Padding for the columns of the grid
$grid-small-prefix: 'sm'; // Small screen class prefix for grid
$grid-medium-breakpoint: 768px; // Medium screen breakpoint for grid
$grid-medium-prefix: 'md'; // Medium screen class prefix for grid
$grid-large-breakpoint: 1280px; // Large screen breakpoint for grid
$grid-large-prefix: 'lg'; // Large screen class prefix for grid
// Notes:
// [1] - If the value of $use-four-step-grid is `true`, the grid system will contain 4 breakpoints instead of 3, along with
// the needed styles. In this case, values should be specified for $grid-extra-small-prefix and $grid-small-breakpoint.
// [2] - If the value of $include-parent-layout is `true`, the grid system will contain extra classes that will define the column
// layout of their children. In this case, a value should be specified for $grid-row-parent-layout-prefix.
// Variables for forms and inputs
$form-back-color: #eeeeee; // Background color for forms
$form-fore-color: $fore-color; // Text color for forms
$form-border-style: $_1px solid #bdbdbd; // Border style for forms
$form-border-radius: 3*$_1px; // Border radius for forms
$form-margin: 0.5rem; // Margin for forms
$form-padding: 0.75rem 0.5rem 1.125rem; // Padding for forms
$form-box-shadow: // Box shadow for forms
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$fieldset-back-color: $form-back-color; // Background color for fieldset
$fieldset-border-style: $_1px solid #e0e0e0; // Border style for fieldset
$fieldset-border-radius: 2*$_1px; // Border radius for fieldset
$fieldset-margin: 0.125rem; // Margin for fieldset
$fieldset-padding: 0.5rem; // Padding for fieldset
$legend-font-weight: 600; // Font weight for legend
$legend-font-size: 0.875rem; // Font size for legend
$legend-fore-color: $form-fore-color; // Text color for legend
$legend-padding: 0.125rem 0.25rem; // Padding for legend
$label-padding: 0.25rem 0.5rem; // Padding for label
$input-group-name: 'input-group'; // Class for input groups
$include-fluid-input-group: false; // Should fluid input grooups be included? (`true`/`false`) [1]
$include-vertical-input-group: true; // Should vertical input grooups be included? (`true`/`false`) [1]
$input-back-color: #fafafa; // Background for input
$input-fore-color: $fore-color; // Text color for input
$input-border-style: $_1px solid #bdbdbd; // Border style for input
$input-border-radius: 2*$_1px; // Border radius for input
$input-margin: 0.25rem; // Margin for input
$input-padding: 0.5rem 0.75rem; // Padding for input
$input-focus-border-color: #0288d1; // Border color for focused input
$input-invalid-border-color: #d32f2f; // Border color for invalid input
$input-disabled-opacity: 0.75; // Opacity for disabled input
$input-readonly-back-color: #e0e0e0; // Background color for readonly input
$input-readonly-border-color: #bdbdbd; // Border color for readonly input
$input-placeholder-fore-color:#616161; // Text color for input placeholder
$apply-select-fix: false; // [Hidden flag override] Should the styles that fix <select> styling be applied? (`true`/`false`)
$button-back-color: #e0e0e0; // Back color for button elements
$button-back-opacity: 1; // Background opacity for button elements
$button-hover-back-opacity: 1; // Background opacity for button elements on hover or focus
$button-fore-color: $fore-color; // Text color for button elements
$button-border-style: 0; // Border style for button elements
$button-border-radius: 3*$_1px; // Border radius for button elements
$button-padding: 0.625rem 0.875rem; // Padding for button elements
$button-margin: 0.5rem; // Margin for button elements
$button-box-shadow: // Box shadow for buttons
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$button-disabled-opacity:0.75; // Disabled button elements opacity
$button-class-name: 'button'; // Class for custom button elements
$include-button-group: false; // [Hidden flag override] Should button groups be enabled? (`true`/`false`) [2]
$hide-file-inputs: true; // Should a style be added that makes all <input>s of type `file` hidden? (`true`/`false`) [3]
$button-variant1-name: 'primary'; // Class name for button variant 1
$button-variant1-back-color: #303f9f; // Background color for button variant 1
$button-variant1-back-opacity: 1; // Background opacity for button variant 1
$button-variant1-hover-back-opacity: 1; // Background opacity for button variant 1 on hover or focus
$button-variant1-fore-color: #fafafa; // Text color for button variant 1
$checkbox-size: 1rem; // Size for checkbox/radio [4]
$checkbox-back-color: $input-back-color;// Background clor for checkbox/radio
$checkbox-fore-color: $input-fore-color;// Text/mark color for checkbox/radio
$checkbox-border-thickness: $_1px; // Border thickness for checkbox/radio
$checkbox-border-color: #bdbdbd; // Border color for checkbox/radio
$checkbox-border-radius: $input-border-radius;// Border radius for checkbox/radio
$checkbox-focus-border-color: $input-focus-border-color;// Border color for checkbox/radio on focus
$checkbox-bottom-spacing: 0.375rem; // Bottom spacing for checkbox/radio
$checkbox-disabled-opacity: $input-disabled-opacity;// Opacity for disabled checkbox/radio
$checkbox-box-shadow: none; // Box shadow for checkbox/radio
$include-switch: false; // Should switch components be included? (`true`/`false`) [5]
// Notes:
// [1] - If the value of $include-fluid-input-group is `true`, fluid input groups will be included, using the values
// specified in the corresponding variables. The same applies for $include-vertical-input-group and vertical input groups.
// [2] - Due to the fact that the value of $include-button-group is set to `false`, no button group styles will be created.
// If you wish to enable them, please refer to a full flavor for the required variables.
// [3] - If the value of $hide-file-inputs is `true`, all <input type="file"> elements will be hidden and the only way
// to access them is via the use of <label> elements that are linked to them. This option is enabled by default to
// allow for universal button styles, even for file input buttons, but can be disabled if the base style is desired.
// If the value is `false`, some fixes will be applied to the <input type="file"> element.
// [4] - The value of $checkbox-size will determine a few variables like some `margin` values, `height`, `width` etc.
// Variables for navigational elements
// [5] - Due to the fact that the value of $include-switch is set to `false`, no switch styles will be created.
// If you wish to enable them, please refer to a full flavor for the required variables.
$header-height: 3rem; // Height for <header>
$header-back-color: #283593; // Background color for <header>
$header-fore-color: #fafafa; // Text color for <header>
$header-border-style: 0; // Border style for <header>
$header-margin: 0; // Margin for <header>
$header-padding: 0.25rem 0.75rem; // Padding for <header>
$header-box-shadow: // Box shadow for <header>
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$header-logo-name: 'logo'; // Class name for <header>'s logo
$header-logo-font-size: 1.75rem; // Font size for <header>'s logo
$header-logo-line-height: 1.3125em; // Line height for <header>'s logo
$header-logo-margin: 0.0625rem 0.375rem 0.0625rem 0.0625rem; // Margin for <header>'s logo
$header-logo-padding: 0; // Padding for <header>'s logo
$header-link-hover-color: #303f9f; // Hover color for <header>'s links
$header-link-margin: 0.125rem 0; // Margin for <header>'s links
$include-header-sticky: true; // Should sticky <header> elements be included? (`true`/`false`) [1]
$header-sticky-name: 'sticky'; // Class name for sticky <header>
$include-nav-styles: false; // [Hidden flag override] Should <nav> elements by stylized? (`true`/`false`) [2]
$drawer-name: 'drawer'; // Class name for the drawer component
$drawer-back-color: #f5f5f5; // Background color of the drawer component
$drawer-border-style: 1px solid #bdbdbd; // Border style of the drawer component
$drawer-border-radius: 0; // Border radius of the drawer component
$drawer-width: 320px; // Width of the drawer component
$drawer-padding: 0; // Padding of the drawer component
$drawer-box-shadow: // Box shadow for the drawer component
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$drawer-mobile-breakpoint: 768px; // Mobile breakpoint for the drawer component
$drawer-normal-height: calc(100vh - 3rem); // Height of the drawer component when shown as normal menu
$drawer-right-name: 'right'; // Class name for the right variant of the drawer component
$drawer-persistent-name: 'drawer'; // Class name for the persisten variant of the drawer component
$drawer-toggle-name: 'drawer-toggle'; // Class name for the drawer component's toggle
$drawer-toggle-font-size: 2.5rem; // Font size for the drawer component's toggle icon
$drawer-toggle-line-height:0.125; // Line height for the drawer component's toggle icon
$drawer-toggle-top: 0.4375rem; // Top position for the drawer component's toggle icon
$drawer-close-name: 'close'; // Class name of the close element for the drawer component
$drawer-close-top: 0.75rem; // Top position of the drawer component's close icon
$drawer-close-right: 0.25rem; // Right position of the drawer component's close icon
$footer-back-color: #283593; // Background color for <footer>
$footer-fore-color: #fafafa; // Text color for <footer>
$footer-border-style: 0; // Border stye for <footer>
$footer-font-size: 0.875rem; // Font size for <footer>
$footer-margin: 1rem 0 0; // Margin for <footer>
$footer-padding: 1.5rem 0.5rem 0.75rem; // Padding for <footer>
$footer-link-fore-color: #f5f5f5; // Text color for links in <footer>
$include-footer-sticky: false; // Should sticky <footer> elements be included (`true`/`false`) [3]
$footer-sticky-name: 'sticky'; // Class name for sticky <footer> elements
// Notes:
// [1] - If the value of $include-header-sticky is `true`, a class will be created that will allow for sticky positioning
// of <header> elements, using the value of $header-sticky-name for the name of the class.
// [2] - Due to the fact that the value of $include-nav-styles is set to `false`, <nav> elements
// will not be stylized. If you set it to `true`, please refer to a full flavor
// to find the required variable definitions.
// [3] - If the value of $include-footer-bottom is `true`, a class will be created that will allow for sticky positioning
// of <footer> elements, using the value of $footer-sticky-name for the name of the class.
// Variables for responsive tables
$table-border-style: $_1px solid #bdbdbd; // Border style for <table> and children
$table-border-radius: 3*$_1px; // Border radius for <table> and children
$table-margin: 0 auto; // Margin for <table>
$table-box-shadow: // Box shadow for <table>
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$table-caption-font-size: 1.5rem; // Font size for <caption>
$table-caption-margin: 0.5rem; // Margin for <caption>
$table-row-padding: 0.5rem; // Padding for <tr> - both views
$table-column-padding: 0.625rem; // Padding for <td> and <th> - desktop view
$table-head-back-color: #f5f5f5; // Background color for <th>
$table-head-fore-color: #424242; // Text color for <th>
$table-body-back-color: #fafafa; // Background color for <td>
$table-body-fore-color: $fore-color; // Text color for <td>
$table-mobile-breakpoint: 767px; // Breakpoint for <table> mobile view
$table-mobile-card-spacing: 0.625rem; // Space between <tr> cards - mobile view
$table-mobile-card-label: 'data-label'; // Attribute used to replace column headers in mobile view [1]
$table-mobile-label-font-weight:$bold-font-weight; // Font weight for mobile headers
$include-horizontal-table: false; // Should horizontal <table> elements be included? (`true`/`false`) [2]
$include-scrollable-table: false; // Should scrollable <table> elements be included? (`true`/`false`) [2]
$include-striped-table: false; // [Hidden flag override] Should striped <table> elements be included (`true`/`false`) [2]
// Notes:
// [1] - The attribute specified in $table-mobile-card-label must be added manually to each and every element in the table
// in order for their mobile headers to display properly.
// [2] - Due to the $include-horizontal-table, $include-scrollable-table and $include-striped-table flags being set to `false`,
// no styling will be provided for horizontal, scrollable and striped <table> elements. Please refer to a full fulavor to find
// the variables associated with these components, if you want to enable them.
$card-name: 'card'; // Class name for cards
$card-back-color: #fafafa; // Background color for cards
$card-fore-color: $fore-color; // Text color for cards
$card-border-style: $_1px solid #bdbdbd; // Border style for cards
$card-border-radius: 3*$_1px; // Border radius for cards
$card-margin: 0.5rem; // Margin for cards
$card-box-shadow: // Box shadow for cards
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$card-section-name: 'section'; // Class name for card sections
$card-section-border-style: $_1px solid #bdbdbd;// Border style for card sections
$card-section-padding: 0.75rem; // Padding for card sections
$card-section-media-name: 'media'; // Class name for card media sections
$card-section-media-height: 200px; // Height for card media setions
$card-normal-width: 320px; // Width for normal cards
$card-size1-name: 'fluid'; // Class name for fluid cards
$card-size1-width: 100%; // Width for fluid cards
$card-section-style1-name: 'accent'; // Class name for card section style 1
$card-section-style1-back-color: #303f9f; // Background color for card section style 1
$card-section-style1-border-style: $_1px solid #283593; // Border style for card section style 1
$card-section-style1-fore-color: #fafafa; // Text color for card section style 1
// Notes:
// [1] - The cards module depends heavily on the grid system module.
// --- --- ---
// No variables specified for the tab module. This module is disabled by default.
// To re-enable it, please refer to a full flavor for variables and documentation.
// --- --- ---
// Variables for contextual background elements and alerts
$mark-back-color: #283593; // Background color for <mark>
$mark-fore-color: #fafafa; // Text color for <mark>
$mark-font-size: 0.9375em; // Font size for <mark>
$mark-line-height: 1em; // Line height for <mark>
$mark-border-style: 0; // Border style for <mark>
$mark-border-radius: 2*$_1px; // Border radius for <mark>
$mark-padding: 0.25em 0.375em; // Padding for <mark>
$mark-margin: 0.125rem; // Margin for <mark>
$mark-box-shadow: // Box shadow for <mark>
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$mark-inline-block-name: 'inline-block'; // Class name for <mark> inline block styling
$toast-name: 'toast'; // Class name for toast component
$toast-bottom: 1.5rem; // Bottom position for toasts
$toast-back-color: $fore-color; // Background color for toasts
$toast-fore-color: #fafafa; // Text color for toasts
$toast-border-style: 0; // Border style for toasts
$toast-border-radius: 2rem; // Border radius for toasts
$toast-padding: 0.75rem 1.5rem; // Padding for toasts
$toast-box-shadow: // Box shadow for toasts
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$include-tooltip: false; // Should tooltips be included? (`true`/`false`) [1]
$include-modal: false; // Should modals be included? (`true`/`false`) [1]
// Notes:
// [1] - Due to the values of $include-tooltip and $include-modal being set
// to `false`, no styling is provided for these elements. If you want to enable them, please
// refer to a full flavor file for variable definitions.
// --- --- ---
// No variables specified for the progress module. This module is disabled by default.
// To re-enable it, please refer to a full flavor for variables and documentation.
// --- --- ---
// Variables for utilities and helper classes
$hidden-name: 'hidden'; // Class name for hidden elements
$visually-hidden-name: 'visually-hidden'; // Class name for visually hidden elements
$include-breadcrumbs: false; // [Hidden flag override] Should breadcrumbs be included? (`true`/`false`) [1]
$close-icon-name: 'close'; // Class name for close icon
$close-icon-size: 1.5rem; // Size of the close icon
$close-icon-back-color: #e0e0e0; // Background color for the close icon
$close-icon-fore-color: #212121; // Foreground color for the close icon
// Notes:
// [1] - Due to the values of $include-breadcrumbs being set to `false`, this element will
// not be included. Refer to a full flavor file for help on how to enable them.
@import '../mini/core';
@import '../mini/grid';
@import '../mini/input_control';
/*
Custom elements for forms and input elements.
*/
@include make-button-alt-color ($button-variant1-name, $button-variant1-back-color,
$button-variant1-back-opacity, $button-variant1-hover-back-opacity, $button-variant1-fore-color);
/*
Custom style fixes and tweaks for input elements.
*/
button, [type="button"], [type="submit"], [type="reset"],
a.button, label.button, .button,
a[role="button"], label[role="button"], [role="button"], label{
text-transform: uppercase;
font-weight: 600;
font-size: 0.875rem;
}
button:hover, button:focus, [type="button"]:hover, [type="button"]:focus, [type="submit"]:hover, [type="submit"]:focus, [type="reset"]:hover, [type="reset"]:focus,
a.button:hover,
a.button:focus, label.button:hover, label.button:focus, .button:hover, .button:focus,
a[role="button"]:hover,
a[role="button"]:focus, label[role="button"]:hover, label[role="button"]:focus, [role="button"]:hover, [role="button"]:focus {
background: #e5e5e5;
box-shadow: 0 3*$_1px 3*$_1px 0 rgba(0,0,0,0.14),0 1*$_1px 7*$_1px 0 rgba(0,0,0,0.12),0 3*$_1px 1*$_1px -1*$_1px rgba(0,0,0,0.2);
}
button.primary:hover, button.primary:focus, [type="button"].primary:hover, [type="button"].primary:focus, [type="submit"].primary:hover, [type="submit"].primary:focus,
[type="reset"].primary:hover,
[type="reset"].primary:focus, .button.primary:hover, .button.primary:focus, [role="button"].primary:hover, [role="button"].primary:focus {
background: #3f51b5;
}
@import '../mini/navigation';
/*
Custom style fixes and tweaks for input elements.
*/
.drawer-toggle::before{
line-height: 0.3125;
}
@media screen and (min-width: 768px) {
.drawer-toggle:not(.drawer) {
display: inline-block;
}
}
.drawer {
button, [type="button"], [type="submit"], [type="reset"],
a, label:not(.close), [role="button"] {
display: block;
margin: 0;
background: #f5f5f5;
box-shadow: none;
border-bottom: 1px solid #bdbdbd;
border-radius: 0;
&:hover, &:focus {
background: #fafafa;
box-shadow: none;
}
}
}
@import '../mini/table';
/*
Custom style fixes and tweaks for table elements.
*/
th, table:not(.preset) td:before {
text-transform: uppercase;
font-weight: 500;
}
table:not(.preset) td:before {
font-weight: 600;
color: #424242;
}
th, td {
font-size: 0.75rem;
}
@import '../mini/card';
/*
Custom elements for cards and containers.
*/
@include make-card-alt-size ($card-size1-name, $card-size1-width);
@include make-card-section-alt-color ($card-section-style1-name, $card-section-style1-back-color,
$card-section-style1-fore-color, $card-section-style1-border-style);
// --- --- ---
// Tab module is disabled for this flavor.
// @import '../mini/tab';
// --- --- ---
@import '../mini/contextual';
/*
Custom style fixes and tweaks for contextual elements.
*/
.toast {
font-size: 0.875rem;
}
// --- --- ---
// Progress module is disabled for this flavor.
// @import '../mini/progress';
// --- --- ---
@import '../mini/utility';
// This is a flavor file. Duplicate it and edit it to create your own flavor. Read instructions carefully.
// Single-line comments, starting with '//' will not be included in your final CSS file. Multiline comments,
// structured like the flavor description below, will be included in your final CSS file.
// Note: This flavor is not a full flavor, we strongly recommend you duplicate the mini-default flavor instead
// of this file, unless you know what you are doing.
/*
Flavor name: Progressive Web App (mini-pw)
Author: Angelos Chalaris (chalarangelo@gmail.com)
Maintainers: Angelos Chalaris
mini.css version: v2.3.4
*/
// Basic rules for body and typography
$fore-color: #212121; // Text and general foreground color
$back-color: #eeeeee; // Body background color
$base-font-family: // Default font stack for all elements:
'-apple-system, BlinkMacSystemFont,\"Segoe UI\",\"Roboto\", \"Droid Sans\",\"Helvetica Neue\", Helvetica, Arial, sans-serif';
// OS X and iOS system fonts (San Francisco) -> Windows system fonts -> Android system fonts (newer and older) -> Fallback fonts
$base-root-font-size: 16px; // Root font sizing for all elements [1]
$_1px: (1px/$base-root-font-size) * 1rem; // Calculated rem value of 1px [1]
$base-font-size: 1rem; // Default font sizing for all elements [2]
$base-line-height: 1.5; // Default line height for all elements.
$use-fluid-typography: false; // Should fluid typography be used at the root element? (`true`/`false`)
$body-margin: 0; // Margin for the body
$apply-defaults-to-all: true; // Should default values be applied to all elements? (`true` or `false`) [3]
$h1-font-size: 2.4375rem; // Font size of h1
$h2-font-size: 1.935rem; // Font size for h2
$h3-font-size: 1.5625rem; // Font size for h3
$h4-font-size: 1.25rem; // Font size for h4
$h5-font-size: 1rem; // Font size for h5
$h6-font-size: 0.8125rem; // Font size for h6
$heading-line-height: 1.25em; // Line height for all headings
$heading-margin: 0.75rem 0.5rem; // Margin for all headings
$heading-font-weight: 500; // Font weight for all headings
$heading-smalltext-fore-color: #424242; // <small> color in headings
$make-heading-smalltext-block: true; // Should <small> elements in headings be displayed as blocks (`true`/`false`) [4]
$heading-smalltext-b-font-size: 0.75em; // Font size of block <small> elements in headings
$heading-smalltext-b-top-margin:-0.25em; // Top margin of block <small> elements in headings
$paragraph-margin: 0.5rem; // Margin for <p> elements
$list-margin: 0.5rem; // Margin for <ol> and <ul> elements
$list-left-padding: 1.25rem; // Left padding for <ol> and <ul> elements
$bold-font-weight: 600; // Font weight for <b> and <strong>
$horizontal-rule-line-height: 1.25em; // <hr> line height
$horizontal-rule-margin: 0.5rem; // <hr> margin
$horizontal-rule-border-style: $_1px solid #757575; // Border style for horizontal rules (used in the <hr> element's border-top)
$horizontal-rule-fancy-style: false; // Should a fancy styling be applied for the <hr> element (`true`/`false`) [5]
$blockquote-back-color: #e0e0e0; // Background color for <blockquote>
$blockquote-fore-color: $fore-color; // Text color for <blockquote>
$blockquote-margin: 0.5rem; // Margin for <blockquote>
$blockquote-padding: 0.5rem 0.5rem 1.5rem;// Padding for <blockquote>
$blockquote-sidebar-style: 4*$_1px solid #3f51b5;// Style for the sidebar of <blockquote>
$blockquote-cite-font-size: 0.875rem; // Font size for citation of <blockquote>
$blockquote-cite-fore-color: #616161; // Text color for citation of <blockquote>
$blockquote-cite-left-position: 0.625rem; // Left padding for citation of <blockquote>
$blockquote-cite-bottom-position: 0; // Bottom padding for citation of <blockquote>
$blockquote-border-style: 0; // Border style for <blockquote>
$blockquote-border-radius: 0 3*$_1px 3*$_1px 0; // Border radius for <blockquote>
$blockquote-box-shadow: // Box shadow for <blockquote>
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$use-default-code-fonts: true; // Should default font choice (monospace) be used for code elements? (`true`/`false`) [6]
$code-element-padding: 0.125rem 0.25rem; // Padding for <code>
$code-element-fore-color: $fore-color; // Text color for <code>
$code-element-back-color: #e0e0e0; // Background color for <code>
$code-element-border-style: 0; // Border style for <code>
$code-element-border-radius: 2*$_1px; // Border radius for <code>
$code-element-box-shadow: // Box shadow for <code>
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$pre-element-padding: 0.75rem; // Padding for <pre>
$pre-element-fore-color: $code-element-fore-color; // Text color for <pre>
$pre-element-back-color: $code-element-back-color; // Background color for <pre>
$pre-element-border-style: 0; // Border style for <pre>
$pre-element-border-radius: 0 3*$_1px 3*$_1px 0;// Border radius for <pre>
$pre-element-margin: 0.5rem; // Margin for <pre>
$pre-element-box-shadow: // Box shadow for <pre>
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$add-pre-element-sidebar: true; // Should a fancy sidebar be added to the left side of <pre> (`true`/`false`) [7]
$pre-element-sidebar-style: 4*$_1px solid #303f9f;// Style of the sidebar of <pre>
$kbd-element-padding: $code-element-padding; // Padding for <kbd>
$kbd-element-fore-color: #fafafa; // Text color for <kbd>
$kbd-element-back-color: #212121; // Background color for <kbd>
$kbd-element-border-style: 0; // Border style for <kbd>
$kbd-element-border-radius: $code-element-border-radius; // Border radius for <kbd>
$kbd-element-box-shadow: $code-element-box-shadow; // Box shadow for <kbd>
$style-samp-element: false; // Should styles for <samp> be included? (`true`/`false`) [8]
$include-dfn-fix: true; // Should the fix for Android 4.3 concerning <dfn> be included (`true`/`false`) [9]
$small-font-size: 0.75em; // Font size for <small> elements
$sup-font-size: 0.75em; // Font size for <sup> elements
$sub-font-size: 0.75em; // Font size for <sub> elements
$sup-top: -0.5em; // <sup> top
$sub-bottom: -0.25em; // <sub> bottom
$link-fore-color: #3f51b5; // Text color for <a>
$link-visited-fore-color: #3f51b5; // Text color for visited <a>
$link-font-weight: 500; // Font weight for <a>
$apply-link-underline: true; // Should an underline be applied to all <a> elements? (`true`/`false`) [10]
$apply-link-hover-fade: true; // Should the :hover and :focus state of <a> elements use fade-out instead of a different color (`true`/`false`) [11]
$figcaption-font-size: 0.8125rem; // Font size of <figcaption> elements
$figcaption-fore-color: #424242; // Text color for <figcaption> elements
// Notes:
// [1] - The value $base-root-font-size should be in `px` only! This rule is very important, as it will determine the root
// element's font sizing. The value of $_1px is calculated based on the value of $base-root-font-size, please do not alter
// the way that it's calculated.
// [2] - The value of $base-font-size will only be used if the value of $apply-defaults-to-all is set to `true` (see [3]).
// This is due to the fact that applying the value of it on the root element again will overwrite the value of
// $base-root-font-size (see [1]). The value of this variable should be set in either `em` or `rem`.
// [3] - It is recommended to set the value of $apply-defaults-to-all to `true`, unless you want to apply extra styling
// to elements manually.
// [4] - If the value of $make-heading-smalltext-block is `true` the <small> elements in headings will be displayed below
// the main heading and the 2 values specified below will apply.
// [5] - If $horizontal-rule-fancy-style is set to `true` the value of $horizontal-rule-border-style will not be used and
// a gradient with the style specified in $horizontal-rule-fancy-gradient will be applied instead.
// [6] - If the value of $use-default-code-fonts is set to `false` the value of $code-font-family will be used. `true`
// will apply the proper fix to use monospace font without any problems on all browsers.
// [7] - if the value of $add-pre-element-sidebar is set to true, the style specified in $pre-element-sidebar-style will
// be applied as a left border for the <pre> elements.
// [8] - If the value of $style-samp-element is set to `false`, no styling will be included in the final CSS file for
// `samp` elements. Otherwise, the styling defined in the $samp-... variables will be applied.
// [9] - If the value of $include-dfn-fix is set to `true` a styling fix will be applied, so that the <dfn> elements are
// displayed properly on older versions of Android (4.3-) in italics. Otherwise, said fix will not be included.
// [10] - If the value of $apply-link-underline is set to `true`, an underline will be applied to the link in its normal
// color, as defined in $link-fore-color.
// [11] - If `$apply-link-hover-fade` is set to `true`, a fading transition will be used for the link when hovered over or
// focused. Otherwise, the color specified in $link-hover-fore-color will be used.
// Variables for grid elements
$use-four-step-grid: false; // Should the old 4-step grid system be used instead of the new (`true`/`false`) [1]
$include-parent-layout: true; // Should the classes for rows defining the column layout of children be included (`true`/`false`) [2]
$grid-container-name: 'container'; // Class name for the grid container
$grid-container-side-padding: 0.75rem; // Padding for the grid container (left and right only)
$grid-row-name: 'row'; // Class name for the grid's rows
$grid-row-parent-layout-prefix:'cols'; // Class name prefix for the grid's row parents [2]
$grid-column-prefix: 'col'; // Class name prefix for the grid's columns
$grid-column-offset-suffix: 'offset'; // Class name suffix for the grid's offsets
$grid-order-normal-suffix: 'normal'; // Class name suffix for grid columns with normal priority
$grid-order-first-suffix: 'first'; // Class name suffix for grid columns with highest priority
$grid-order-last-suffix: 'last'; // Class name suffix for grid columns with lowest priorty
$grid-column-count: 12; // Number of columns in the grid (integer value only)
$grid-column-padding: 0 0.25rem; // Padding for the columns of the grid
$grid-small-prefix: 'sm'; // Small screen class prefix for grid
$grid-medium-breakpoint: 768px; // Medium screen breakpoint for grid
$grid-medium-prefix: 'md'; // Medium screen class prefix for grid
$grid-large-breakpoint: 1280px; // Large screen breakpoint for grid
$grid-large-prefix: 'lg'; // Large screen class prefix for grid
// Notes:
// [1] - If the value of $use-four-step-grid is `true`, the grid system will contain 4 breakpoints instead of 3, along with
// the needed styles. In this case, values should be specified for $grid-extra-small-prefix and $grid-small-breakpoint.
// [2] - If the value of $include-parent-layout is `true`, the grid system will contain extra classes that will define the column
// layout of their children. In this case, a value should be specified for $grid-row-parent-layout-prefix.
// Variables for forms and inputs
$form-back-color: #eeeeee; // Background color for forms
$form-fore-color: $fore-color; // Text color for forms
$form-border-style: $_1px solid #bdbdbd; // Border style for forms
$form-border-radius: 3*$_1px; // Border radius for forms
$form-margin: 0.5rem; // Margin for forms
$form-padding: 0.75rem 0.5rem 1.125rem; // Padding for forms
$form-box-shadow: // Box shadow for forms
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$fieldset-back-color: $form-back-color; // Background color for fieldset
$fieldset-border-style: $_1px solid #e0e0e0; // Border style for fieldset
$fieldset-border-radius: 2*$_1px; // Border radius for fieldset
$fieldset-margin: 0.125rem; // Margin for fieldset
$fieldset-padding: 0.5rem; // Padding for fieldset
$legend-font-weight: 600; // Font weight for legend
$legend-font-size: 0.875rem; // Font size for legend
$legend-fore-color: $form-fore-color; // Text color for legend
$legend-padding: 0.125rem 0.25rem; // Padding for legend
$label-padding: 0.25rem 0.5rem; // Padding for label
$input-group-name: 'input-group'; // Class for input groups
$include-fluid-input-group: false; // Should fluid input grooups be included? (`true`/`false`) [1]
$include-vertical-input-group: true; // Should vertical input grooups be included? (`true`/`false`) [1]
$input-back-color: #fafafa; // Background for input
$input-fore-color: $fore-color; // Text color for input
$input-border-style: $_1px solid #bdbdbd; // Border style for input
$input-border-radius: 2*$_1px; // Border radius for input
$input-margin: 0.25rem; // Margin for input
$input-padding: 0.5rem 0.75rem; // Padding for input
$input-focus-border-color: #0288d1; // Border color for focused input
$input-invalid-border-color: #d32f2f; // Border color for invalid input
$input-disabled-opacity: 0.75; // Opacity for disabled input
$input-readonly-back-color: #e0e0e0; // Background color for readonly input
$input-readonly-border-color: #bdbdbd; // Border color for readonly input
$input-placeholder-fore-color:#616161; // Text color for input placeholder
$apply-select-fix: false; // [Hidden flag override] Should the styles that fix <select> styling be applied? (`true`/`false`)
$button-back-color: #e0e0e0; // Back color for button elements
$button-back-opacity: 1; // Background opacity for button elements
$button-hover-back-opacity: 1; // Background opacity for button elements on hover or focus
$button-fore-color: $fore-color; // Text color for button elements
$button-border-style: 0; // Border style for button elements
$button-border-radius: 3*$_1px; // Border radius for button elements
$button-padding: 0.625rem 0.875rem; // Padding for button elements
$button-margin: 0.5rem; // Margin for button elements
$button-box-shadow: // Box shadow for buttons
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$button-disabled-opacity:0.75; // Disabled button elements opacity
$button-class-name: 'button'; // Class for custom button elements
$include-button-group: false; // [Hidden flag override] Should button groups be enabled? (`true`/`false`) [2]
$hide-file-inputs: true; // Should a style be added that makes all <input>s of type `file` hidden? (`true`/`false`) [3]
$button-variant1-name: 'primary'; // Class name for button variant 1
$button-variant1-back-color: #303f9f; // Background color for button variant 1
$button-variant1-back-opacity: 1; // Background opacity for button variant 1
$button-variant1-hover-back-opacity: 1; // Background opacity for button variant 1 on hover or focus
$button-variant1-fore-color: #fafafa; // Text color for button variant 1
$checkbox-size: 1rem; // Size for checkbox/radio [4]
$checkbox-back-color: $input-back-color;// Background clor for checkbox/radio
$checkbox-fore-color: $input-fore-color;// Text/mark color for checkbox/radio
$checkbox-border-thickness: $_1px; // Border thickness for checkbox/radio
$checkbox-border-color: #bdbdbd; // Border color for checkbox/radio
$checkbox-border-radius: $input-border-radius;// Border radius for checkbox/radio
$checkbox-focus-border-color: $input-focus-border-color;// Border color for checkbox/radio on focus
$checkbox-bottom-spacing: 0.375rem; // Bottom spacing for checkbox/radio
$checkbox-disabled-opacity: $input-disabled-opacity;// Opacity for disabled checkbox/radio
$checkbox-box-shadow: none; // Box shadow for checkbox/radio
$include-switch: false; // Should switch components be included? (`true`/`false`) [5]
// Notes:
// [1] - If the value of $include-fluid-input-group is `true`, fluid input groups will be included, using the values
// specified in the corresponding variables. The same applies for $include-vertical-input-group and vertical input groups.
// [2] - Due to the fact that the value of $include-button-group is set to `false`, no button group styles will be created.
// If you wish to enable them, please refer to a full flavor for the required variables.
// [3] - If the value of $hide-file-inputs is `true`, all <input type="file"> elements will be hidden and the only way
// to access them is via the use of <label> elements that are linked to them. This option is enabled by default to
// allow for universal button styles, even for file input buttons, but can be disabled if the base style is desired.
// If the value is `false`, some fixes will be applied to the <input type="file"> element.
// [4] - The value of $checkbox-size will determine a few variables like some `margin` values, `height`, `width` etc.
// Variables for navigational elements
// [5] - Due to the fact that the value of $include-switch is set to `false`, no switch styles will be created.
// If you wish to enable them, please refer to a full flavor for the required variables.
$header-height: 3rem; // Height for <header>
$header-back-color: #283593; // Background color for <header>
$header-fore-color: #fafafa; // Text color for <header>
$header-border-style: 0; // Border style for <header>
$header-margin: 0; // Margin for <header>
$header-padding: 0.25rem 0.75rem; // Padding for <header>
$header-box-shadow: // Box shadow for <header>
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$header-logo-name: 'logo'; // Class name for <header>'s logo
$header-logo-font-size: 1.75rem; // Font size for <header>'s logo
$header-logo-line-height: 1.3125em; // Line height for <header>'s logo
$header-logo-margin: 0.0625rem 0.375rem 0.0625rem 0.0625rem; // Margin for <header>'s logo
$header-logo-padding: 0; // Padding for <header>'s logo
$header-link-hover-color: #303f9f; // Hover color for <header>'s links
$header-link-margin: 0.125rem 0; // Margin for <header>'s links
$include-header-sticky: true; // Should sticky <header> elements be included? (`true`/`false`) [1]
$header-sticky-name: 'sticky'; // Class name for sticky <header>
$include-nav-styles: false; // [Hidden flag override] Should <nav> elements by stylized? (`true`/`false`) [2]
$drawer-name: 'drawer'; // Class name for the drawer component
$drawer-back-color: #f5f5f5; // Background color of the drawer component
$drawer-border-style: 1px solid #bdbdbd; // Border style of the drawer component
$drawer-border-radius: 0; // Border radius of the drawer component
$drawer-width: 320px; // Width of the drawer component
$drawer-padding: 0; // Padding of the drawer component
$drawer-box-shadow: // Box shadow for the drawer component
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$drawer-mobile-breakpoint: 768px; // Mobile breakpoint for the drawer component
$drawer-normal-height: calc(100vh - 3rem); // Height of the drawer component when shown as normal menu
$drawer-right-name: 'right'; // Class name for the right variant of the drawer component
$drawer-persistent-name: 'drawer'; // Class name for the persisten variant of the drawer component
$drawer-toggle-name: 'drawer-toggle'; // Class name for the drawer component's toggle
$drawer-toggle-font-size: 2.5rem; // Font size for the drawer component's toggle icon
$drawer-toggle-line-height:0.125; // Line height for the drawer component's toggle icon
$drawer-toggle-top: 0.4375rem; // Top position for the drawer component's toggle icon
$drawer-close-name: 'close'; // Class name of the close element for the drawer component
$drawer-close-top: 0.75rem; // Top position of the drawer component's close icon
$drawer-close-right: 0.25rem; // Right position of the drawer component's close icon
$footer-back-color: #283593; // Background color for <footer>
$footer-fore-color: #fafafa; // Text color for <footer>
$footer-border-style: 0; // Border stye for <footer>
$footer-font-size: 0.875rem; // Font size for <footer>
$footer-margin: 1rem 0 0; // Margin for <footer>
$footer-padding: 1.5rem 0.5rem 0.75rem; // Padding for <footer>
$footer-link-fore-color: #f5f5f5; // Text color for links in <footer>
$include-footer-sticky: false; // Should sticky <footer> elements be included (`true`/`false`) [3]
$footer-sticky-name: 'sticky'; // Class name for sticky <footer> elements
// Notes:
// [1] - If the value of $include-header-sticky is `true`, a class will be created that will allow for sticky positioning
// of <header> elements, using the value of $header-sticky-name for the name of the class.
// [2] - Due to the fact that the value of $include-nav-styles is set to `false`, <nav> elements
// will not be stylized. If you set it to `true`, please refer to a full flavor
// to find the required variable definitions.
// [3] - If the value of $include-footer-bottom is `true`, a class will be created that will allow for sticky positioning
// of <footer> elements, using the value of $footer-sticky-name for the name of the class.
// Variables for responsive tables
$table-border-style: $_1px solid #bdbdbd; // Border style for <table> and children
$table-border-radius: 3*$_1px; // Border radius for <table> and children
$table-margin: 0 auto; // Margin for <table>
$table-box-shadow: // Box shadow for <table>
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$table-caption-font-size: 1.5rem; // Font size for <caption>
$table-caption-margin: 0.5rem; // Margin for <caption>
$table-row-padding: 0.5rem; // Padding for <tr> - both views
$table-column-padding: 0.625rem; // Padding for <td> and <th> - desktop view
$table-head-back-color: #f5f5f5; // Background color for <th>
$table-head-fore-color: #424242; // Text color for <th>
$table-body-back-color: #fafafa; // Background color for <td>
$table-body-fore-color: $fore-color; // Text color for <td>
$table-mobile-breakpoint: 767px; // Breakpoint for <table> mobile view
$table-mobile-card-spacing: 0.625rem; // Space between <tr> cards - mobile view
$table-mobile-card-label: 'data-label'; // Attribute used to replace column headers in mobile view [1]
$table-mobile-label-font-weight:$bold-font-weight; // Font weight for mobile headers
$include-horizontal-table: false; // Should horizontal <table> elements be included? (`true`/`false`) [2]
$include-scrollable-table: false; // Should scrollable <table> elements be included? (`true`/`false`) [2]
$include-striped-table: false; // [Hidden flag override] Should striped <table> elements be included (`true`/`false`) [2]
// Notes:
// [1] - The attribute specified in $table-mobile-card-label must be added manually to each and every element in the table
// in order for their mobile headers to display properly.
// [2] - Due to the $include-horizontal-table, $include-scrollable-table and $include-striped-table flags being set to `false`,
// no styling will be provided for horizontal, scrollable and striped <table> elements. Please refer to a full fulavor to find
// the variables associated with these components, if you want to enable them.
$card-name: 'card'; // Class name for cards
$card-back-color: #fafafa; // Background color for cards
$card-fore-color: $fore-color; // Text color for cards
$card-border-style: $_1px solid #bdbdbd; // Border style for cards
$card-border-radius: 3*$_1px; // Border radius for cards
$card-margin: 0.5rem; // Margin for cards
$card-box-shadow: // Box shadow for cards
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$card-section-name: 'section'; // Class name for card sections
$card-section-border-style: $_1px solid #bdbdbd;// Border style for card sections
$card-section-padding: 0.75rem; // Padding for card sections
$card-section-media-name: 'media'; // Class name for card media sections
$card-section-media-height: 200px; // Height for card media setions
$card-normal-width: 320px; // Width for normal cards
$card-size1-name: 'fluid'; // Class name for fluid cards
$card-size1-width: 100%; // Width for fluid cards
$card-section-style1-name: 'accent'; // Class name for card section style 1
$card-section-style1-back-color: #303f9f; // Background color for card section style 1
$card-section-style1-border-style: $_1px solid #283593; // Border style for card section style 1
$card-section-style1-fore-color: #fafafa; // Text color for card section style 1
// Notes:
// [1] - The cards module depends heavily on the grid system module.
// --- --- ---
// No variables specified for the tab module. This module is disabled by default.
// To re-enable it, please refer to a full flavor for variables and documentation.
// --- --- ---
// Variables for contextual background elements and alerts
$mark-back-color: #283593; // Background color for <mark>
$mark-fore-color: #fafafa; // Text color for <mark>
$mark-font-size: 0.9375em; // Font size for <mark>
$mark-line-height: 1em; // Line height for <mark>
$mark-border-style: 0; // Border style for <mark>
$mark-border-radius: 2*$_1px; // Border radius for <mark>
$mark-padding: 0.25em 0.375em; // Padding for <mark>
$mark-margin: 0.125rem; // Margin for <mark>
$mark-box-shadow: // Box shadow for <mark>
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$mark-inline-block-name: 'inline-block'; // Class name for <mark> inline block styling
$toast-name: 'toast'; // Class name for toast component
$toast-bottom: 1.5rem; // Bottom position for toasts
$toast-back-color: $fore-color; // Background color for toasts
$toast-fore-color: #fafafa; // Text color for toasts
$toast-border-style: 0; // Border style for toasts
$toast-border-radius: 2rem; // Border radius for toasts
$toast-padding: 0.75rem 1.5rem; // Padding for toasts
$toast-box-shadow: // Box shadow for toasts
0 2*$_1px 2*$_1px 0 rgba(0, 0, 0, 0.14), 0 1*$_1px 5*$_1px 0 rgba(0, 0, 0, 0.12), 0 3*$_1px 1*$_1px -2*$_1px rgba(0, 0, 0, 0.2);
$include-tooltip: false; // Should tooltips be included? (`true`/`false`) [1]
$include-modal: false; // Should modals be included? (`true`/`false`) [1]
// Notes:
// [1] - Due to the values of $include-tooltip and $include-modal being set
// to `false`, no styling is provided for these elements. If you want to enable them, please
// refer to a full flavor file for variable definitions.
// --- --- ---
// No variables specified for the progress module. This module is disabled by default.
// To re-enable it, please refer to a full flavor for variables and documentation.
// --- --- ---
// Variables for utilities and helper classes
$hidden-name: 'hidden'; // Class name for hidden elements
$visually-hidden-name: 'visually-hidden'; // Class name for visually hidden elements
$include-breadcrumbs: false; // [Hidden flag override] Should breadcrumbs be included? (`true`/`false`) [1]
$close-icon-name: 'close'; // Class name for close icon
$close-icon-size: 1.5rem; // Size of the close icon
$close-icon-back-color: #e0e0e0; // Background color for the close icon
$close-icon-fore-color: #212121; // Foreground color for the close icon
// Notes:
// [1] - Due to the values of $include-breadcrumbs being set to `false`, this element will
// not be included. Refer to a full flavor file for help on how to enable them.
@import '../mini/core';
@import '../mini/grid';
@import '../mini/input_control';
/*
Custom elements for forms and input elements.
*/
@include make-button-alt-color ($button-variant1-name, $button-variant1-back-color,
$button-variant1-back-opacity, $button-variant1-hover-back-opacity, $button-variant1-fore-color);
/*
Custom style fixes and tweaks for input elements.
*/
button, [type="button"], [type="submit"], [type="reset"],
a.button, label.button, .button,
a[role="button"], label[role="button"], [role="button"], label{
text-transform: uppercase;
font-weight: 600;
font-size: 0.875rem;
}
button:hover, button:focus, [type="button"]:hover, [type="button"]:focus, [type="submit"]:hover, [type="submit"]:focus, [type="reset"]:hover, [type="reset"]:focus,
a.button:hover,
a.button:focus, label.button:hover, label.button:focus, .button:hover, .button:focus,
a[role="button"]:hover,
a[role="button"]:focus, label[role="button"]:hover, label[role="button"]:focus, [role="button"]:hover, [role="button"]:focus {
background: #e5e5e5;
box-shadow: 0 3*$_1px 3*$_1px 0 rgba(0,0,0,0.14),0 1*$_1px 7*$_1px 0 rgba(0,0,0,0.12),0 3*$_1px 1*$_1px -1*$_1px rgba(0,0,0,0.2);
}
button.primary:hover, button.primary:focus, [type="button"].primary:hover, [type="button"].primary:focus, [type="submit"].primary:hover, [type="submit"].primary:focus,
[type="reset"].primary:hover,
[type="reset"].primary:focus, .button.primary:hover, .button.primary:focus, [role="button"].primary:hover, [role="button"].primary:focus {
background: #3f51b5;
}
@import '../mini/navigation';
/*
Custom style fixes and tweaks for input elements.
*/
.drawer-toggle::before{
line-height: 0.3125;
}
@media screen and (min-width: 768px) {
.drawer-toggle:not(.drawer) {
display: inline-block;
}
}
.drawer {
button, [type="button"], [type="submit"], [type="reset"],
a, label:not(.close), [role="button"] {
display: block;
margin: 0;
background: #f5f5f5;
box-shadow: none;
border-bottom: 1px solid #bdbdbd;
border-radius: 0;
&:hover, &:focus {
background: #fafafa;
box-shadow: none;
}
}
}
@import '../mini/table';
/*
Custom style fixes and tweaks for table elements.
*/
th, table:not(.preset) td:before {
text-transform: uppercase;
font-weight: 500;
}
table:not(.preset) td:before {
font-weight: 600;
color: #424242;
}
th, td {
font-size: 0.75rem;
}
@import '../mini/card';
/*
Custom elements for cards and containers.
*/
@include make-card-alt-size ($card-size1-name, $card-size1-width);
@include make-card-section-alt-color ($card-section-style1-name, $card-section-style1-back-color,
$card-section-style1-fore-color, $card-section-style1-border-style);
// --- --- ---
// Tab module is disabled for this flavor.
// @import '../mini/tab';
// --- --- ---
@import '../mini/contextual';
/*
Custom style fixes and tweaks for contextual elements.
*/
.toast {
font-size: 0.875rem;
}
// --- --- ---
// Progress module is disabled for this flavor.
// @import '../mini/progress';
// --- --- ---
@import '../mini/utility';

File diff suppressed because it is too large Load diff

View file

@ -1,80 +1,80 @@
/*
Definitions for cards and containers.
*/
// Dependency: This module depends heavily on the grid system module.
$card-name: 'card' !default; // Class name for the cards
$card-section-name: 'section' !default; // Class name for the cards' sections
$card-section-media-name: 'media' !default; // Class name for the cards' sections (media cotent)
$card-normal-width: 320px !default; // Width for normal cards
// External variables' defaults are used only if you import this module on its own, without the rest of the framework.
$back-color: white !default; // [External variable - core] Background color for everything.
$fore-color: black !default; // [External variable - core] Foreground color for everything.
// Check the `_card_mixins.scss` file to find this module's mixins.
@import 'card_mixins';
// Card styling
.#{$card-name} {
// Old syntax
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-box-pack: justify;
-webkit-box-align: center;
// New syntax
display: -webkit-flex;
display: flex;
-webkit-flex-direction: column;
flex-direction: column;
-webkit-justify-content: space-between;
justify-content: space-between;
-webkit-align-self: center;
align-self: center;
position: relative;
width: 100%;
// Actual styling for the cards
@if $card-back-color != $back-color {
background: $card-back-color;
}
@if $card-fore-color != $fore-color {
color: $card-fore-color;
}
@if $card-border-style != 0 {
border: $card-border-style;
}
@if $card-border-radius != 0 {
border-radius: $card-border-radius;
}
@if $card-margin != 0 {
margin: $card-margin;
}
@if $card-box-shadow != none {
box-shadow: $card-box-shadow;
}
// Hide overflow from section borders
overflow: hidden;
// Card sections
& > .#{$card-section-name} {
box-sizing: border-box;
margin: 0;
border: 0; // Clean borders and radiuses for any element-based sections
border-radius: 0; // Clean borders and radiuses for any element-based sections
border-bottom: $card-section-border-style;
padding: $card-section-padding;
width: 100%;
// Card media sections
&.#{$card-section-media-name} {
height: $card-section-media-height;
padding: 0;
-o-object-fit: cover;
object-fit: cover;
}
}
// Card sections - last
& > .#{$card-section-name}:last-child {
border-bottom: 0; // Clean the extra border for last section
}
}
// Responsiveness (if the screen is larger than card, set max-width)
@media screen and (min-width: #{$card-normal-width}) {
.#{$card-name} {
max-width: $card-normal-width;
}
}
/*
Definitions for cards and containers.
*/
// Dependency: This module depends heavily on the grid system module.
$card-name: 'card' !default; // Class name for the cards
$card-section-name: 'section' !default; // Class name for the cards' sections
$card-section-media-name: 'media' !default; // Class name for the cards' sections (media cotent)
$card-normal-width: 320px !default; // Width for normal cards
// External variables' defaults are used only if you import this module on its own, without the rest of the framework.
$back-color: white !default; // [External variable - core] Background color for everything.
$fore-color: black !default; // [External variable - core] Foreground color for everything.
// Check the `_card_mixins.scss` file to find this module's mixins.
@import 'card_mixins';
// Card styling
.#{$card-name} {
// Old syntax
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-box-pack: justify;
-webkit-box-align: center;
// New syntax
display: -webkit-flex;
display: flex;
-webkit-flex-direction: column;
flex-direction: column;
-webkit-justify-content: space-between;
justify-content: space-between;
-webkit-align-self: center;
align-self: center;
position: relative;
width: 100%;
// Actual styling for the cards
@if $card-back-color != $back-color {
background: $card-back-color;
}
@if $card-fore-color != $fore-color {
color: $card-fore-color;
}
@if $card-border-style != 0 {
border: $card-border-style;
}
@if $card-border-radius != 0 {
border-radius: $card-border-radius;
}
@if $card-margin != 0 {
margin: $card-margin;
}
@if $card-box-shadow != none {
box-shadow: $card-box-shadow;
}
// Hide overflow from section borders
overflow: hidden;
// Card sections
& > .#{$card-section-name} {
box-sizing: border-box;
margin: 0;
border: 0; // Clean borders and radiuses for any element-based sections
border-radius: 0; // Clean borders and radiuses for any element-based sections
border-bottom: $card-section-border-style;
padding: $card-section-padding;
width: 100%;
// Card media sections
&.#{$card-section-media-name} {
height: $card-section-media-height;
padding: 0;
-o-object-fit: cover;
object-fit: cover;
}
}
// Card sections - last
& > .#{$card-section-name}:last-child {
border-bottom: 0; // Clean the extra border for last section
}
}
// Responsiveness (if the screen is larger than card, set max-width)
@media screen and (min-width: #{$card-normal-width}) {
.#{$card-name} {
max-width: $card-normal-width;
}
}

View file

@ -1,88 +1,88 @@
// Card module's mixin definitions are here. For the module itself
// check `_card.scss`.
// Mixin for alternate card sizes.
// Variables:
// - $card-alt-size-name : The name of the class used for the alternate size card.
// - $card-alt-size-width : The width of the alternate size card.
@mixin make-card-alt-size ($card-alt-size-name, $card-alt-size-width) {
@if type-of($card-alt-size-width) == 'number' and unit($card-alt-size-width) == '%' {
.#{$card-name}.#{$card-alt-size-name} {
max-width: $card-alt-size-width;
width: auto;
}
}
@else {
@media screen and (min-width: #{$card-alt-size-width}) {
.#{$card-name}.#{$card-alt-size-name} {
max-width: $card-alt-size-width;
}
}
}
}
// Mixin for alternate cards (card color variants).
// Variables:
// - $card-alt-name : The name of the class used for the alternate card.
// - $card-alt-back-color : The background color of the alternate card.
// - $card-alt-fore-color : The text color of the alternate card.
// - $card-alt-border-style : (Optional) The border style of the alternate card. Defaults to the value
// of $card-border-style.
// - $card-alt-border-radius : (Optional) The border radius of the alternate card. Defaults to the value
// of $card-border-radius.
// - $card-alt-section-border-style : (Optional) The border style of the alternate card's sections. Defaults to
// the value of $card-section-border-style.
@mixin make-card-alt-color ($card-alt-name, $card-alt-back-color, $card-alt-fore-color,
$card-alt-border-style : $card-border-style, $card-alt-border-radius : $card-border-radius,
$card-alt-section-border-style : $card-section-border-style) {
.#{$card-name}.#{$card-alt-name} {
@if $card-alt-back-color != $card-back-color {
background: $card-alt-back-color;
}
@if $card-alt-fore-color != $card-fore-color {
color: $card-alt-fore-color;
}
@if $card-alt-border-style != $card-border-style {
border: $card-alt-border-style;
}
@if $card-alt-border-radius != $card-border-radius {
border-radius: $card-alt-border-radius;
}
@if $card-alt-section-border-style != $card-section-border-style{
& > .#{$card-section-name} {
border-bottom: $card-alt-section-border-style;
}
& > .#{$card-section-name}:last-child {
border-bottom: 0; // Clean the extra border for last section
}
}
}
}
// Mixin for alternate card sections (card section color variants).
// Variables:
// - $card-section-alt-name : The name of the class used for the alternate card section.
// - $card-section-alt-back-color : The background color of the alternate card section.
// - $card-section-alt-fore-color : The text color of the alternate card section.
// - $card-section-alt-border-style : (Optional) The border style of the alternate card section. Defaults to
// the value of $card-section-border-style.
@mixin make-card-section-alt-color ($card-section-alt-name, $card-section-alt-back-color,
$card-section-alt-fore-color, $card-section-alt-border-style : $card-section-border-style) {
.#{$card-name} > .#{$card-section-name}.#{$card-section-alt-name} {
@if $card-section-alt-back-color != $card-back-color {
background: $card-section-alt-back-color;
}
@if $card-section-alt-fore-color != $card-fore-color {
color: $card-section-alt-fore-color;
}
@if $card-section-alt-border-style != $card-section-border-style {
border: $card-section-alt-border-style;
}
}
}
// Mixin for alternate card sections (card section padding variants).
// Variables:
// - $card-section-alt-name : The name of the class used for the alternate card section.
// - $card-section-alt-padding : The padding of the alternate card section.
@mixin make-card-section-alt-style ($card-section-alt-name, $card-section-alt-padding) {
.#{$card-name} > .#{$card-section-name}.#{$card-section-alt-name} {
padding: $card-section-alt-padding;
}
}
// Card module's mixin definitions are here. For the module itself
// check `_card.scss`.
// Mixin for alternate card sizes.
// Variables:
// - $card-alt-size-name : The name of the class used for the alternate size card.
// - $card-alt-size-width : The width of the alternate size card.
@mixin make-card-alt-size ($card-alt-size-name, $card-alt-size-width) {
@if type-of($card-alt-size-width) == 'number' and unit($card-alt-size-width) == '%' {
.#{$card-name}.#{$card-alt-size-name} {
max-width: $card-alt-size-width;
width: auto;
}
}
@else {
@media screen and (min-width: #{$card-alt-size-width}) {
.#{$card-name}.#{$card-alt-size-name} {
max-width: $card-alt-size-width;
}
}
}
}
// Mixin for alternate cards (card color variants).
// Variables:
// - $card-alt-name : The name of the class used for the alternate card.
// - $card-alt-back-color : The background color of the alternate card.
// - $card-alt-fore-color : The text color of the alternate card.
// - $card-alt-border-style : (Optional) The border style of the alternate card. Defaults to the value
// of $card-border-style.
// - $card-alt-border-radius : (Optional) The border radius of the alternate card. Defaults to the value
// of $card-border-radius.
// - $card-alt-section-border-style : (Optional) The border style of the alternate card's sections. Defaults to
// the value of $card-section-border-style.
@mixin make-card-alt-color ($card-alt-name, $card-alt-back-color, $card-alt-fore-color,
$card-alt-border-style : $card-border-style, $card-alt-border-radius : $card-border-radius,
$card-alt-section-border-style : $card-section-border-style) {
.#{$card-name}.#{$card-alt-name} {
@if $card-alt-back-color != $card-back-color {
background: $card-alt-back-color;
}
@if $card-alt-fore-color != $card-fore-color {
color: $card-alt-fore-color;
}
@if $card-alt-border-style != $card-border-style {
border: $card-alt-border-style;
}
@if $card-alt-border-radius != $card-border-radius {
border-radius: $card-alt-border-radius;
}
@if $card-alt-section-border-style != $card-section-border-style{
& > .#{$card-section-name} {
border-bottom: $card-alt-section-border-style;
}
& > .#{$card-section-name}:last-child {
border-bottom: 0; // Clean the extra border for last section
}
}
}
}
// Mixin for alternate card sections (card section color variants).
// Variables:
// - $card-section-alt-name : The name of the class used for the alternate card section.
// - $card-section-alt-back-color : The background color of the alternate card section.
// - $card-section-alt-fore-color : The text color of the alternate card section.
// - $card-section-alt-border-style : (Optional) The border style of the alternate card section. Defaults to
// the value of $card-section-border-style.
@mixin make-card-section-alt-color ($card-section-alt-name, $card-section-alt-back-color,
$card-section-alt-fore-color, $card-section-alt-border-style : $card-section-border-style) {
.#{$card-name} > .#{$card-section-name}.#{$card-section-alt-name} {
@if $card-section-alt-back-color != $card-back-color {
background: $card-section-alt-back-color;
}
@if $card-section-alt-fore-color != $card-fore-color {
color: $card-section-alt-fore-color;
}
@if $card-section-alt-border-style != $card-section-border-style {
border: $card-section-alt-border-style;
}
}
}
// Mixin for alternate card sections (card section padding variants).
// Variables:
// - $card-section-alt-name : The name of the class used for the alternate card section.
// - $card-section-alt-padding : The padding of the alternate card section.
@mixin make-card-section-alt-style ($card-section-alt-name, $card-section-alt-padding) {
.#{$card-name} > .#{$card-section-name}.#{$card-section-alt-name} {
padding: $card-section-alt-padding;
}
}

View file

@ -1,265 +1,265 @@
/*
Definitions for contextual background elements, toasts and tooltips.
*/
// Contextual background elements use the mark element as their base.
$mark-inline-block-name: 'inline-block' !default; // Class name for <mark> inline block styling.
$include-toast: true !default; // [Hidden flag] Should toasts be included? (`true`/`false`)
$toast-name: 'toast' !default; // Class name for the toasts.
$include-tooltip: true !default; // Should tooltips be included? (`true`/`false`)
$tooltip-name: 'tooltip' !default; // Class name for the tooltips.
$tooltip-bottom-name: 'bottom' !default; // Bottom tooltip class name.
$include-modal: true !default; // Should modals be included? (`true`/`false`)
$modal-name: 'modal' !default; // Class name for the modals.
$modal-close-name: 'close' !default; // Class name of the close element for the modal component.
// External variables' defaults are used only if you import this module on its own, without the rest of the framework.
$back-color: white !default; // [External variable - core] Background color for everything.
$fore-color: black !default; // [External variable - core] Foreground color for everything.
$base-line-height: 1 !default; // [External variable - core] Line height for everything.
$style-link-active-state: false !default; // [External flag - core] Should the :active state of <a> elements be stylized, same as the :hover state (`true`/`false`).
// Check the `_contextual_mixins.scss` file to find this module's mixins.
@import 'contextual_mixins';
// Default styling for mark. Use mixins for alternate styles.
mark {
@if $mark-back-color != $back-color {
background: $mark-back-color;
}
@if $mark-fore-color != $fore-color {
color: $mark-fore-color;
}
@if $mark-font-size != 100% {
font-size: $mark-font-size;
}
@if $mark-line-height != $base-line-height {
line-height: $mark-line-height;
}
@if $mark-border-style != 0 {
border: $mark-border-style;
}
@if $mark-border-radius != 0 {
border-radius: $mark-border-radius;
}
@if $mark-padding != 0 {
padding: $mark-padding;
}
@if $mark-margin != 0 {
margin: $mark-margin;
}
@if $mark-box-shadow != none {
box-shadow: $mark-box-shadow;
}
&.#{$mark-inline-block-name}{
display: inline-block; // Can be used to deal with some problems.
}
}
// Default styling for toasts. Use mixins for alternate styles
@if $include-toast {
.#{$toast-name} {
position: fixed;
background: $toast-back-color;
bottom: $toast-bottom;
left: 50%;
transform: translate(-50%, -50%);
@if $toast-fore-color != $fore-color {
color: $toast-fore-color;
}
@if $toast-border-style != 0 {
border: $toast-border-style;
}
@if $toast-border-radius != 0 {
border-radius: $toast-border-radius;
}
@if $toast-padding != 0 {
padding: $toast-padding;
}
@if $toast-box-shadow != none {
box-shadow: $toast-box-shadow;
}
z-index: 1111;
}
}
// Default styling for tooltips. Use mixins for alternate styles
@if $include-tooltip {
.#{$tooltip-name} {
position: relative;
display: inline-block;
&:before, &:after {
position: absolute;
opacity: 0;
clip: rect(0 0 0 0);
-webkit-clip-path: inset(100%);
clip-path: inset(100%);
transition: all 0.3s;
// Remember to keep this index a lower value than the one used for stickies.
z-index: 1010; // Deals with certain problems when combined with cards and tables.
left: 50%;
}
&:not(.#{$tooltip-bottom-name}):before, &:not(.#{$tooltip-bottom-name}):after { // Top (default) tooltip styling
bottom: 75%;
}
&.#{$tooltip-bottom-name}:before, &.#{$tooltip-bottom-name}:after { // Bottom tooltip styling
top: 75%;
}
@if $style-link-active-state {
&:hover, &:focus, &:active {
&:before, &:after {
opacity: 1;
clip: auto;
-webkit-clip-path: inset(0%);
clip-path: inset(0%);
}
}
}
@else {
&:hover, &:focus {
&:before, &:after {
opacity: 1;
clip: auto;
-webkit-clip-path: inset(0%);
clip-path: inset(0%);
}
}
}
&:before { // This is the little tooltip triangle
content: '';
background: transparent;
border: $tooltip-tail-size solid transparent;
// Older browsers will almost center the tooltip's tail
left: 50%;
// Newer browsers will center the tail properly
left: calc(50% - #{$tooltip-tail-size});
}
&:not(.#{$tooltip-bottom-name}):before { // Top (default) tooltip styling
border-top-color: $tooltip-back-color;
}
&.#{$tooltip-bottom-name}:before { // Bottom tooltip styling
border-bottom-color: $tooltip-back-color;
}
&:after { // This is the actual tooltip's text block
content: attr(aria-label);
background: $tooltip-back-color;
@if $tooltip-border-radius != 0 {
border-radius: $tooltip-border-radius;
}
@if $tooltip-fore-color != $fore-color {
color: $tooltip-fore-color;
}
@if $tooltip-padding != 0 {
padding: $tooltip-padding;
}
@if $tooltip-box-shadow != none {
box-shadow: $tooltip-box-shadow;
}
white-space: nowrap;
-webkit-transform: translateX(-50%);
transform: translateX(-50%);
}
&:not(.#{$tooltip-bottom-name}):after { // Top (default) tooltip styling
margin-bottom: 2 * $tooltip-tail-size;
}
&.#{$tooltip-bottom-name}:after { // Bottom tooltip styling
margin-top: 2 * $tooltip-tail-size;
}
}
}
@if $include-modal {
.#{$modal-name} {
position: fixed;
top: 0;
left: 0;
display: none;
width: 100vw;
height: 100vh;
background: rgba($modal-back-color, $modal-back-opacity);
& .card {
margin: 0 auto;
max-height: 50vh;
overflow: auto;
& .#{$modal-close-name} {
position: absolute;
top: $modal-close-top;
right: $modal-close-right;
padding: 0; // Fixes the extra padding added from <label> styling.
}
}
}
:checked + .#{$modal-name} {
// Old syntax
display: -webkit-box;
-webkit-box-flex: 0;
// New syntax
display: -webkit-flex;
display: flex;
-webkit-flex: 0 1 auto;
flex: 0 1 auto;
z-index: 1200;
& .card {
& .#{$modal-close-name} {
z-index: 1211;
}
}
}
}
// [WARNING: As of v2.2.0, the alert component is deprecated and no longer maintained.]
$include-alerts: false !default; // [Hidden flag] Should alerts be included? (`true`/`false`)
// Animation definition for animated alerts (included if wanted)
@if $include-alerts { // Turn on if you want to enable the alert component.
$alert-name: 'alert' !default; // Class name for the alerts.
$alert-include-animated: false !default; // Should animated alerts be included? (`true`/`false`)
$alert-animated-name: 'animated' !default; // Class name for animated alerts.
$alert-back-color: #d1e6f3 !default; // Background color for alerts
$alert-fore-color: $fore-color !default; // Text color for alerts
$alert-border-style: 1px solid #d0d0d0 !default; // Border style for alerts
$alert-border-radius: 0 !default; // Border radius for alerts
$alert-padding: 0.75rem !default; // Padding for alerts
$alert-margin: 0.5rem !default; // Margin for alerts
$alert-box-shadow: none !default; // Box shadow for alerts
@if $alert-include-animated {
@-webkit-keyframes alert-anim {
45% { -webkit-transform: scale(1); -webkit-transform-origin: 50% 50%; }
50% { -webkit-transform: scale(1.005); -webkit-transform-origin: 50% 50%; }
55% { -webkit-transform: scale(1); -webkit-transform-origin: 50% 50%; }
}
@keyframes alert-anim {
45% { transform: scale(1); transform-origin: 50% 50%; }
50% { transform: scale(1.005); transform-origin: 50% 50%; }
55% { transform: scale(1); transform-origin: 50% 50%; }
}
}
// Default styling for alerts. Use mixins for alternate styles
.#{$alert-name} {
display: block;
@if $alert-back-color != $back-color {
background: $alert-back-color;
}
@if $alert-fore-color != $fore-color {
color: $alert-fore-color;
}
@if $alert-border-style != 0 {
border: $alert-border-style;
}
@if $alert-border-radius != 0 {
border-radius: $alert-border-radius;
}
@if $alert-margin != 0 {
margin: $alert-margin;
}
@if $alert-padding != 0 {
padding: $alert-padding;
}
@if $alert-box-shadow != none {
box-shadow: $alert-box-shadow;
}
@if $alert-include-animated {
&.#{$alert-animated-name} {
// Try to make the animated alert not blurry
-webkit-backface-visibility: hidden;
backface-visibility: hidden;
-webkit-transform: translateZ(0);
transform: translateZ(0);
// Apply the animation
-webkit-animation: alert-anim 6s linear infinite;
animation: alert-anim 6s linear infinite;
}
}
}
}
/*
Definitions for contextual background elements, toasts and tooltips.
*/
// Contextual background elements use the mark element as their base.
$mark-inline-block-name: 'inline-block' !default; // Class name for <mark> inline block styling.
$include-toast: true !default; // [Hidden flag] Should toasts be included? (`true`/`false`)
$toast-name: 'toast' !default; // Class name for the toasts.
$include-tooltip: true !default; // Should tooltips be included? (`true`/`false`)
$tooltip-name: 'tooltip' !default; // Class name for the tooltips.
$tooltip-bottom-name: 'bottom' !default; // Bottom tooltip class name.
$include-modal: true !default; // Should modals be included? (`true`/`false`)
$modal-name: 'modal' !default; // Class name for the modals.
$modal-close-name: 'close' !default; // Class name of the close element for the modal component.
// External variables' defaults are used only if you import this module on its own, without the rest of the framework.
$back-color: white !default; // [External variable - core] Background color for everything.
$fore-color: black !default; // [External variable - core] Foreground color for everything.
$base-line-height: 1 !default; // [External variable - core] Line height for everything.
$style-link-active-state: false !default; // [External flag - core] Should the :active state of <a> elements be stylized, same as the :hover state (`true`/`false`).
// Check the `_contextual_mixins.scss` file to find this module's mixins.
@import 'contextual_mixins';
// Default styling for mark. Use mixins for alternate styles.
mark {
@if $mark-back-color != $back-color {
background: $mark-back-color;
}
@if $mark-fore-color != $fore-color {
color: $mark-fore-color;
}
@if $mark-font-size != 100% {
font-size: $mark-font-size;
}
@if $mark-line-height != $base-line-height {
line-height: $mark-line-height;
}
@if $mark-border-style != 0 {
border: $mark-border-style;
}
@if $mark-border-radius != 0 {
border-radius: $mark-border-radius;
}
@if $mark-padding != 0 {
padding: $mark-padding;
}
@if $mark-margin != 0 {
margin: $mark-margin;
}
@if $mark-box-shadow != none {
box-shadow: $mark-box-shadow;
}
&.#{$mark-inline-block-name}{
display: inline-block; // Can be used to deal with some problems.
}
}
// Default styling for toasts. Use mixins for alternate styles
@if $include-toast {
.#{$toast-name} {
position: fixed;
background: $toast-back-color;
bottom: $toast-bottom;
left: 50%;
transform: translate(-50%, -50%);
@if $toast-fore-color != $fore-color {
color: $toast-fore-color;
}
@if $toast-border-style != 0 {
border: $toast-border-style;
}
@if $toast-border-radius != 0 {
border-radius: $toast-border-radius;
}
@if $toast-padding != 0 {
padding: $toast-padding;
}
@if $toast-box-shadow != none {
box-shadow: $toast-box-shadow;
}
z-index: 1111;
}
}
// Default styling for tooltips. Use mixins for alternate styles
@if $include-tooltip {
.#{$tooltip-name} {
position: relative;
display: inline-block;
&:before, &:after {
position: absolute;
opacity: 0;
clip: rect(0 0 0 0);
-webkit-clip-path: inset(100%);
clip-path: inset(100%);
transition: all 0.3s;
// Remember to keep this index a lower value than the one used for stickies.
z-index: 1010; // Deals with certain problems when combined with cards and tables.
left: 50%;
}
&:not(.#{$tooltip-bottom-name}):before, &:not(.#{$tooltip-bottom-name}):after { // Top (default) tooltip styling
bottom: 75%;
}
&.#{$tooltip-bottom-name}:before, &.#{$tooltip-bottom-name}:after { // Bottom tooltip styling
top: 75%;
}
@if $style-link-active-state {
&:hover, &:focus, &:active {
&:before, &:after {
opacity: 1;
clip: auto;
-webkit-clip-path: inset(0%);
clip-path: inset(0%);
}
}
}
@else {
&:hover, &:focus {
&:before, &:after {
opacity: 1;
clip: auto;
-webkit-clip-path: inset(0%);
clip-path: inset(0%);
}
}
}
&:before { // This is the little tooltip triangle
content: '';
background: transparent;
border: $tooltip-tail-size solid transparent;
// Older browsers will almost center the tooltip's tail
left: 50%;
// Newer browsers will center the tail properly
left: calc(50% - #{$tooltip-tail-size});
}
&:not(.#{$tooltip-bottom-name}):before { // Top (default) tooltip styling
border-top-color: $tooltip-back-color;
}
&.#{$tooltip-bottom-name}:before { // Bottom tooltip styling
border-bottom-color: $tooltip-back-color;
}
&:after { // This is the actual tooltip's text block
content: attr(aria-label);
background: $tooltip-back-color;
@if $tooltip-border-radius != 0 {
border-radius: $tooltip-border-radius;
}
@if $tooltip-fore-color != $fore-color {
color: $tooltip-fore-color;
}
@if $tooltip-padding != 0 {
padding: $tooltip-padding;
}
@if $tooltip-box-shadow != none {
box-shadow: $tooltip-box-shadow;
}
white-space: nowrap;
-webkit-transform: translateX(-50%);
transform: translateX(-50%);
}
&:not(.#{$tooltip-bottom-name}):after { // Top (default) tooltip styling
margin-bottom: 2 * $tooltip-tail-size;
}
&.#{$tooltip-bottom-name}:after { // Bottom tooltip styling
margin-top: 2 * $tooltip-tail-size;
}
}
}
@if $include-modal {
.#{$modal-name} {
position: fixed;
top: 0;
left: 0;
display: none;
width: 100vw;
height: 100vh;
background: rgba($modal-back-color, $modal-back-opacity);
& .card {
margin: 0 auto;
max-height: 50vh;
overflow: auto;
& .#{$modal-close-name} {
position: absolute;
top: $modal-close-top;
right: $modal-close-right;
padding: 0; // Fixes the extra padding added from <label> styling.
}
}
}
:checked + .#{$modal-name} {
// Old syntax
display: -webkit-box;
-webkit-box-flex: 0;
// New syntax
display: -webkit-flex;
display: flex;
-webkit-flex: 0 1 auto;
flex: 0 1 auto;
z-index: 1200;
& .card {
& .#{$modal-close-name} {
z-index: 1211;
}
}
}
}
// [WARNING: As of v2.2.0, the alert component is deprecated and no longer maintained.]
$include-alerts: false !default; // [Hidden flag] Should alerts be included? (`true`/`false`)
// Animation definition for animated alerts (included if wanted)
@if $include-alerts { // Turn on if you want to enable the alert component.
$alert-name: 'alert' !default; // Class name for the alerts.
$alert-include-animated: false !default; // Should animated alerts be included? (`true`/`false`)
$alert-animated-name: 'animated' !default; // Class name for animated alerts.
$alert-back-color: #d1e6f3 !default; // Background color for alerts
$alert-fore-color: $fore-color !default; // Text color for alerts
$alert-border-style: 1px solid #d0d0d0 !default; // Border style for alerts
$alert-border-radius: 0 !default; // Border radius for alerts
$alert-padding: 0.75rem !default; // Padding for alerts
$alert-margin: 0.5rem !default; // Margin for alerts
$alert-box-shadow: none !default; // Box shadow for alerts
@if $alert-include-animated {
@-webkit-keyframes alert-anim {
45% { -webkit-transform: scale(1); -webkit-transform-origin: 50% 50%; }
50% { -webkit-transform: scale(1.005); -webkit-transform-origin: 50% 50%; }
55% { -webkit-transform: scale(1); -webkit-transform-origin: 50% 50%; }
}
@keyframes alert-anim {
45% { transform: scale(1); transform-origin: 50% 50%; }
50% { transform: scale(1.005); transform-origin: 50% 50%; }
55% { transform: scale(1); transform-origin: 50% 50%; }
}
}
// Default styling for alerts. Use mixins for alternate styles
.#{$alert-name} {
display: block;
@if $alert-back-color != $back-color {
background: $alert-back-color;
}
@if $alert-fore-color != $fore-color {
color: $alert-fore-color;
}
@if $alert-border-style != 0 {
border: $alert-border-style;
}
@if $alert-border-radius != 0 {
border-radius: $alert-border-radius;
}
@if $alert-margin != 0 {
margin: $alert-margin;
}
@if $alert-padding != 0 {
padding: $alert-padding;
}
@if $alert-box-shadow != none {
box-shadow: $alert-box-shadow;
}
@if $alert-include-animated {
&.#{$alert-animated-name} {
// Try to make the animated alert not blurry
-webkit-backface-visibility: hidden;
backface-visibility: hidden;
-webkit-transform: translateZ(0);
transform: translateZ(0);
// Apply the animation
-webkit-animation: alert-anim 6s linear infinite;
animation: alert-anim 6s linear infinite;
}
}
}
}

View file

@ -1,214 +1,214 @@
// Contextual module's mixin definitions are here. For the module itself
// check `_contextual.scss`.
// Mixin for alternate mark (contextual color variants).
// Variables:
// - $mark-alt-name : The name of the class used for the alternate mark.
// - $mark-alt-back-color : The background color of the alternate mark.
// - $mark-alt-fore-color : (Optional) The text color of the alternate mark. Defaults to the text color of the mark.
@mixin make-mark-alt-color ($mark-alt-name, $mark-alt-back-color, $mark-alt-fore-color: $mark-fore-color) {
mark.#{$mark-alt-name} {
@if $mark-alt-back-color != $mark-back-color {
background: $mark-alt-back-color;
}
@if $mark-alt-fore-color != $mark-fore-color {
color: $mark-alt-fore-color;
}
}
}
// Mixin for alternative mark styles (contextual tags).
// Variables:
// - $mark-alt-name : The name of the class used for the alternate mark style.
// - $mark-alt-border-style : The border-style of the alternate mark style.
// - $mark-alt-border-radius : The border-radius of the alternate mark style.
// - $mark-alt-padding : (Optional) The padding of the alternate mark style. Defaults to the padding of the mark.
// - $mark-alt-font-size : (Optional) The font-size of the alternate mark style. Defaults to the font-size of the mark.
// - $mark-alt-line-height : (Optional) The line height of the alternate mark style. Defaults to the line height of the mark.
// - $mark-alt-box-shadow : (Optional) The box shadow of the alternate mark style. Defaults to the box shadow of the mark.
@mixin make-mark-alt-style ($mark-alt-name, $mark-alt-border-style, $mark-alt-border-radius,
$mark-alt-padding : $mark-padding, $mark-alt-font-size : $mark-font-size, $mark-alt-line-height : $mark-line-height,
$mark-alt-box-shadow : $mark-box-shadow ) {
mark.#{$mark-alt-name} {
@if $mark-alt-font-size != $mark-font-size {
font-size: $mark-alt-font-size;
}
@if $mark-alt-line-height != $mark-line-height {
line-height: $mark-alt-line-height;
}
@if $mark-alt-border-style != $mark-border-style {
border: $mark-alt-border-style;
}
@if $mark-alt-border-radius != $mark-border-radius {
border-radius: $mark-alt-border-radius;
}
@if $mark-alt-padding != $mark-padding {
padding: $mark-alt-padding;
}
@if $mark-alt-box-shadow != $mark-box-shadow {
box-shadow: $mark-alt-box-shadow;
}
}
}
// Mixin for alternate toast (toast color variants).
// Variables:
// - $toast-alt-name : The name of the class used for the alternate toast.
// - $toast-alt-back-color : The background color of the alternate toast.
// - $toast-alt-fore-color : (Optional) The text color of the alternate mark. Defaults to the text color of the toast.
@mixin make-toast-alt-color ($toast-alt-name, $toast-alt-back-color, $toast-alt-fore-color: $toast-fore-color) {
@if not ($include-toast) {
@error "Contextual module's toast mixins are only available if toasts are enabled. Set '$include-toast' to 'true' and try again!";
}
.#{$toast-name}.#{$toast-alt-name} {
@if $toast-alt-back-color != $toast-back-color {
background: $toast-alt-back-color;
}
@if $toast-alt-fore-color != $toast-fore-color {
color: $toast-alt-fore-color;
}
}
}
// Mixin for alternate toast styles (toast style variants).
// Variables:
// - $toast-alt-name : The name of the class used for the alternate toast style.
// - $toast-alt-border-style : The border style of the alternate toast style.
// - $toast-alt-border-radius : Border radius of the alternate toast style.
// - $toast-alt-padding : (Optional) Padding of the alternate toast style. Defaults to the toast's padding.
// - $toast-alt-box-shadow : (Optional) Box shadow of the alretnate toast style. Defaults to the toast's box shadow.
@mixin make-toast-alt-style ($toast-alt-name, $toast-alt-border-style, $toast-alt-border-radius,
$toast-alt-padding : $toast-padding, $toast-alt-box-shadow : $toast-box-shadow) {
@if not ($include-toast) {
@error "Contextual module's toast mixins are only available if toasts are enabled. Set '$include-toast' to 'true' and try again!";
}
.#{$toast-name}.#{$toast-alt-name} {
@if $toast-alt-border-style != $toast-border-style {
border: $toast-alt-border-style;
}
@if $toast-alt-border-radius != $toast-border-radius {
border-radius: $toast-alt-border-radius;
}
@if $toast-alt-padding != $toast-padding {
padding: $toast-alt-padding;
}
@if $toast-alt-box-shadow != $toast-box-shadow {
box-shadow: $toast-alt-box-shadowbox-shadow;
}
}
}
// Mixin for alternate tooltip (tooltip color variants).
// Variables:
// - $tooltip-alt-name : The name of the class used for the alternate tooltip.
// - $tooltip-alt-back-color : The background color of the alternate tooltip.
// - $tooltip-alt-fore-color : (Optional) The text color of the alternate mark. Defaults to the text color of the tooltip.
@mixin make-tooltip-alt-color ($tooltip-alt-name, $tooltip-alt-back-color, $tooltip-alt-fore-color: $tooltip-fore-color) {
@if not ($include-tooltip) {
@error "Contextual module's tooltip mixins are only available if tooltips are enabled. Set '$include-tooltip' to 'true' and try again!";
}
.#{$tooltip-name}.#{$tooltip-alt-name} {
@if $tooltip-alt-back-color != $tooltip-back-color {
&:not(.#{$tooltip-bottom-name}):before { // Top (default) tooltip styling
border-top-color: $tooltip-alt-back-color;
}
&.#{$tooltip-bottom-name}:before { // Bottom tooltip styling
border-bottom-color: $tooltip-alt-back-color;
}
}
&:after {
@if $tooltip-alt-back-color != $tooltip-back-color {
background: $tooltip-alt-back-color;
}
@if $tooltip-alt-fore-color != $tooltip-fore-color {
color: $tooltip-alt-fore-color;
}
}
}
}
// Mixin for alternate tooltip styles (tooltip style variants).
// Variables:
// - $tooltip-alt-name : The name of the class used for the alternate tooltip style.
// - $tooltip-alt-tail-size : The border style of the alternate tooltip style.
// - $tooltip-alt-border-radius : Border radius of the alternate tooltip style.
// - $tooltip-alt-padding : (Optional) Padding of the alternate tooltip style. Defaults to the tooltip's padding.
// - $tooltip-alt-box-shadow : (Optional) Box shadow of the alretnate tooltip style. Defaults to the tooltip's box shadow.
@mixin make-tooltip-alt-style ($tooltip-alt-name, $tooltip-alt-tail-size, $tooltip-alt-border-radius,
$tooltip-alt-padding : $tooltip-padding, $tooltip-alt-box-shadow : $tooltip-box-shadow) {
@if not ($include-tooltip) {
@error "Contextual module's tooltip mixins are only available if tooltips are enabled. Set '$include-tooltip' to 'true' and try again!";
}
.#{$tooltip-name}.#{$tooltip-alt-name} {
@if $tooltip-alt-tail-size != $tooltip-tail-size {
&:before {
border-width: $tooltip-alt-tail-size;
left: calc(50% - #{$tooltip-alt-tail-size});
}
&:not(.#{$tooltip-bottom-name}):after { // Top (default) tooltip styling
margin-bottom: 2 * $tooltip-alt-tail-size;
}
&.#{$tooltip-bottom-name}:after { // Bottom tooltip styling
margin-top: 2 * $tooltip-alt-tail-size;
}
}
&:after {
@if $tooltip-alt-border-radius != $tooltip-border-radius {
border-radius: $tooltip-alt-border-radius;
}
@if $tooltip-alt-padding != $tooltip-padding {
padding: $tooltip-alt-padding;
}
@if $tooltip-alt-box-shadow != $tooltip-box-shadow {
box-shadow: $tooltip-alt-box-shadow;
}
}
}
}
// [WARNING: As of v2.2.0, this mixin is deprecated, due to the fact that the alert component is no longer maintained.]
// Mixin for alternate alert (alert color variants).
// Variables:
// - $alert-alt-name : The name of the class used for the alternate alert.
// - $alert-alt-back-color : The background color of the alternate alert.
// - $alert-alt-fore-color : (Optional) The text color of the alternate mark. Defaults to the text color of the alert.
@mixin make-alert-alt-color ($alert-alt-name, $alert-alt-back-color, $alert-alt-fore-color: $alert-fore-color) {
@if not ($include-alerts) {
@error "Contextual module's alert mixins are only available if alerts are enabled. Set '$include-alerts' to 'true' and try again!";
}
.#{$alert-name}.#{$alert-alt-name} {
@if $alert-alt-back-color != $alert-back-color {
background: $alert-alt-back-color;
}
@if $alert-alt-fore-color != $alert-fore-color {
color: $alert-alt-fore-color;
}
}
}
// [WARNING: As of v2.2.0, this mixin is deprecated, due to the fact that the alert component is no longer maintained.]
// Mixin for alternate alert styles (alert style variants).
// Variables:
// - $alert-alt-name : The name of the class used for the alternate alert style.
// - $alert-alt-border-style : The border style of the alternate alert style.
// - $alert-alt-border-radius : Border radius of the alternate alert style.
// - $alert-alt-padding : (Optional) Padding of the alternate alert style. Defaults to the alert's padding.
// - $alert-alt-margin : (Optional) Margin of the alternate alert style. Defaults to the alert's margin.
// - $alert-alt-box-shadow : (Optional) Box shadow of the alretnate alert style. Defaults to the alert's box shadow.
@mixin make-alert-alt-style ($alert-alt-name, $alert-alt-border-style, $alert-alt-border-radius,
$alert-alt-padding : $alert-padding, $alert-alt-margin : $alert-margin,
$alert-alt-box-shadow : $alert-box-shadow) {
@if not ($include-alerts) {
@error "Contextual module's alert mixins are only available if alerts are enabled. Set '$include-alerts' to 'true' and try again!";
}
.#{$alert-name}.#{$alert-alt-name} {
@if $alert-alt-border-style != $alert-border-style {
border: $alert-alt-border-style;
}
@if $alert-alt-border-radius != $alert-border-radius {
border-radius: $alert-alt-border-radius;
}
@if $alert-alt-padding != $alert-padding {
padding: $alert-alt-padding;
}
@if $alert-alt-margin != $alert-margin {
margin: $alert-alt-margin;
}
@if $alert-alt-box-shadow != $alert-box-shadow {
box-shadow: $alert-alt-box-shadowbox-shadow;
}
}
}
// Contextual module's mixin definitions are here. For the module itself
// check `_contextual.scss`.
// Mixin for alternate mark (contextual color variants).
// Variables:
// - $mark-alt-name : The name of the class used for the alternate mark.
// - $mark-alt-back-color : The background color of the alternate mark.
// - $mark-alt-fore-color : (Optional) The text color of the alternate mark. Defaults to the text color of the mark.
@mixin make-mark-alt-color ($mark-alt-name, $mark-alt-back-color, $mark-alt-fore-color: $mark-fore-color) {
mark.#{$mark-alt-name} {
@if $mark-alt-back-color != $mark-back-color {
background: $mark-alt-back-color;
}
@if $mark-alt-fore-color != $mark-fore-color {
color: $mark-alt-fore-color;
}
}
}
// Mixin for alternative mark styles (contextual tags).
// Variables:
// - $mark-alt-name : The name of the class used for the alternate mark style.
// - $mark-alt-border-style : The border-style of the alternate mark style.
// - $mark-alt-border-radius : The border-radius of the alternate mark style.
// - $mark-alt-padding : (Optional) The padding of the alternate mark style. Defaults to the padding of the mark.
// - $mark-alt-font-size : (Optional) The font-size of the alternate mark style. Defaults to the font-size of the mark.
// - $mark-alt-line-height : (Optional) The line height of the alternate mark style. Defaults to the line height of the mark.
// - $mark-alt-box-shadow : (Optional) The box shadow of the alternate mark style. Defaults to the box shadow of the mark.
@mixin make-mark-alt-style ($mark-alt-name, $mark-alt-border-style, $mark-alt-border-radius,
$mark-alt-padding : $mark-padding, $mark-alt-font-size : $mark-font-size, $mark-alt-line-height : $mark-line-height,
$mark-alt-box-shadow : $mark-box-shadow ) {
mark.#{$mark-alt-name} {
@if $mark-alt-font-size != $mark-font-size {
font-size: $mark-alt-font-size;
}
@if $mark-alt-line-height != $mark-line-height {
line-height: $mark-alt-line-height;
}
@if $mark-alt-border-style != $mark-border-style {
border: $mark-alt-border-style;
}
@if $mark-alt-border-radius != $mark-border-radius {
border-radius: $mark-alt-border-radius;
}
@if $mark-alt-padding != $mark-padding {
padding: $mark-alt-padding;
}
@if $mark-alt-box-shadow != $mark-box-shadow {
box-shadow: $mark-alt-box-shadow;
}
}
}
// Mixin for alternate toast (toast color variants).
// Variables:
// - $toast-alt-name : The name of the class used for the alternate toast.
// - $toast-alt-back-color : The background color of the alternate toast.
// - $toast-alt-fore-color : (Optional) The text color of the alternate mark. Defaults to the text color of the toast.
@mixin make-toast-alt-color ($toast-alt-name, $toast-alt-back-color, $toast-alt-fore-color: $toast-fore-color) {
@if not ($include-toast) {
@error "Contextual module's toast mixins are only available if toasts are enabled. Set '$include-toast' to 'true' and try again!";
}
.#{$toast-name}.#{$toast-alt-name} {
@if $toast-alt-back-color != $toast-back-color {
background: $toast-alt-back-color;
}
@if $toast-alt-fore-color != $toast-fore-color {
color: $toast-alt-fore-color;
}
}
}
// Mixin for alternate toast styles (toast style variants).
// Variables:
// - $toast-alt-name : The name of the class used for the alternate toast style.
// - $toast-alt-border-style : The border style of the alternate toast style.
// - $toast-alt-border-radius : Border radius of the alternate toast style.
// - $toast-alt-padding : (Optional) Padding of the alternate toast style. Defaults to the toast's padding.
// - $toast-alt-box-shadow : (Optional) Box shadow of the alretnate toast style. Defaults to the toast's box shadow.
@mixin make-toast-alt-style ($toast-alt-name, $toast-alt-border-style, $toast-alt-border-radius,
$toast-alt-padding : $toast-padding, $toast-alt-box-shadow : $toast-box-shadow) {
@if not ($include-toast) {
@error "Contextual module's toast mixins are only available if toasts are enabled. Set '$include-toast' to 'true' and try again!";
}
.#{$toast-name}.#{$toast-alt-name} {
@if $toast-alt-border-style != $toast-border-style {
border: $toast-alt-border-style;
}
@if $toast-alt-border-radius != $toast-border-radius {
border-radius: $toast-alt-border-radius;
}
@if $toast-alt-padding != $toast-padding {
padding: $toast-alt-padding;
}
@if $toast-alt-box-shadow != $toast-box-shadow {
box-shadow: $toast-alt-box-shadowbox-shadow;
}
}
}
// Mixin for alternate tooltip (tooltip color variants).
// Variables:
// - $tooltip-alt-name : The name of the class used for the alternate tooltip.
// - $tooltip-alt-back-color : The background color of the alternate tooltip.
// - $tooltip-alt-fore-color : (Optional) The text color of the alternate mark. Defaults to the text color of the tooltip.
@mixin make-tooltip-alt-color ($tooltip-alt-name, $tooltip-alt-back-color, $tooltip-alt-fore-color: $tooltip-fore-color) {
@if not ($include-tooltip) {
@error "Contextual module's tooltip mixins are only available if tooltips are enabled. Set '$include-tooltip' to 'true' and try again!";
}
.#{$tooltip-name}.#{$tooltip-alt-name} {
@if $tooltip-alt-back-color != $tooltip-back-color {
&:not(.#{$tooltip-bottom-name}):before { // Top (default) tooltip styling
border-top-color: $tooltip-alt-back-color;
}
&.#{$tooltip-bottom-name}:before { // Bottom tooltip styling
border-bottom-color: $tooltip-alt-back-color;
}
}
&:after {
@if $tooltip-alt-back-color != $tooltip-back-color {
background: $tooltip-alt-back-color;
}
@if $tooltip-alt-fore-color != $tooltip-fore-color {
color: $tooltip-alt-fore-color;
}
}
}
}
// Mixin for alternate tooltip styles (tooltip style variants).
// Variables:
// - $tooltip-alt-name : The name of the class used for the alternate tooltip style.
// - $tooltip-alt-tail-size : The border style of the alternate tooltip style.
// - $tooltip-alt-border-radius : Border radius of the alternate tooltip style.
// - $tooltip-alt-padding : (Optional) Padding of the alternate tooltip style. Defaults to the tooltip's padding.
// - $tooltip-alt-box-shadow : (Optional) Box shadow of the alretnate tooltip style. Defaults to the tooltip's box shadow.
@mixin make-tooltip-alt-style ($tooltip-alt-name, $tooltip-alt-tail-size, $tooltip-alt-border-radius,
$tooltip-alt-padding : $tooltip-padding, $tooltip-alt-box-shadow : $tooltip-box-shadow) {
@if not ($include-tooltip) {
@error "Contextual module's tooltip mixins are only available if tooltips are enabled. Set '$include-tooltip' to 'true' and try again!";
}
.#{$tooltip-name}.#{$tooltip-alt-name} {
@if $tooltip-alt-tail-size != $tooltip-tail-size {
&:before {
border-width: $tooltip-alt-tail-size;
left: calc(50% - #{$tooltip-alt-tail-size});
}
&:not(.#{$tooltip-bottom-name}):after { // Top (default) tooltip styling
margin-bottom: 2 * $tooltip-alt-tail-size;
}
&.#{$tooltip-bottom-name}:after { // Bottom tooltip styling
margin-top: 2 * $tooltip-alt-tail-size;
}
}
&:after {
@if $tooltip-alt-border-radius != $tooltip-border-radius {
border-radius: $tooltip-alt-border-radius;
}
@if $tooltip-alt-padding != $tooltip-padding {
padding: $tooltip-alt-padding;
}
@if $tooltip-alt-box-shadow != $tooltip-box-shadow {
box-shadow: $tooltip-alt-box-shadow;
}
}
}
}
// [WARNING: As of v2.2.0, this mixin is deprecated, due to the fact that the alert component is no longer maintained.]
// Mixin for alternate alert (alert color variants).
// Variables:
// - $alert-alt-name : The name of the class used for the alternate alert.
// - $alert-alt-back-color : The background color of the alternate alert.
// - $alert-alt-fore-color : (Optional) The text color of the alternate mark. Defaults to the text color of the alert.
@mixin make-alert-alt-color ($alert-alt-name, $alert-alt-back-color, $alert-alt-fore-color: $alert-fore-color) {
@if not ($include-alerts) {
@error "Contextual module's alert mixins are only available if alerts are enabled. Set '$include-alerts' to 'true' and try again!";
}
.#{$alert-name}.#{$alert-alt-name} {
@if $alert-alt-back-color != $alert-back-color {
background: $alert-alt-back-color;
}
@if $alert-alt-fore-color != $alert-fore-color {
color: $alert-alt-fore-color;
}
}
}
// [WARNING: As of v2.2.0, this mixin is deprecated, due to the fact that the alert component is no longer maintained.]
// Mixin for alternate alert styles (alert style variants).
// Variables:
// - $alert-alt-name : The name of the class used for the alternate alert style.
// - $alert-alt-border-style : The border style of the alternate alert style.
// - $alert-alt-border-radius : Border radius of the alternate alert style.
// - $alert-alt-padding : (Optional) Padding of the alternate alert style. Defaults to the alert's padding.
// - $alert-alt-margin : (Optional) Margin of the alternate alert style. Defaults to the alert's margin.
// - $alert-alt-box-shadow : (Optional) Box shadow of the alretnate alert style. Defaults to the alert's box shadow.
@mixin make-alert-alt-style ($alert-alt-name, $alert-alt-border-style, $alert-alt-border-radius,
$alert-alt-padding : $alert-padding, $alert-alt-margin : $alert-margin,
$alert-alt-box-shadow : $alert-box-shadow) {
@if not ($include-alerts) {
@error "Contextual module's alert mixins are only available if alerts are enabled. Set '$include-alerts' to 'true' and try again!";
}
.#{$alert-name}.#{$alert-alt-name} {
@if $alert-alt-border-style != $alert-border-style {
border: $alert-alt-border-style;
}
@if $alert-alt-border-radius != $alert-border-radius {
border-radius: $alert-alt-border-radius;
}
@if $alert-alt-padding != $alert-padding {
padding: $alert-alt-padding;
}
@if $alert-alt-margin != $alert-margin {
margin: $alert-alt-margin;
}
@if $alert-alt-box-shadow != $alert-box-shadow {
box-shadow: $alert-alt-box-shadowbox-shadow;
}
}
}

View file

@ -1,466 +1,466 @@
/*
Browsers resets and base typography.
*/
$apply-defaults-to-all: true !default; // Should default values be applied to all elements? (`true`/`false`).
$base-root-font-size: 16px !default; // Root font sizing for all elements - Should only be specified in `px` units!
$_1px: (1px/$base-root-font-size) * 1rem !default; // Calculated rem value of 1px.
$use-fluid-typography: false !default; // Should fluid typography be used at the root element? (`true`/`false`)
$fluid-type-start-breakpoint: 320px !default; // Breakpoint where fluid typography scaling starts.
$fluid-type-end-breakpoint: 1600px !default; // Breakpoint where fluid typography scaling ends.
$fluid-type-small-type: 14px !default; // Smallest root font size for fluid typography.
$fluid-type-large-type: 18px !default; // Largest root font size for fluid typography.
$include-dfn-fix: true !default; // Fix display of <dfn> element in older versions of Android.
$make-heading-smalltext-block: false !default; // Should <small> elements in headings be displayed as blocks (`true`/`false`).
$horizontal-rule-fancy-style: false !default; // Should a fancy styling be applied for the <hr> element (`true`/`false`).
$add-pre-element-sidebar: false !default; // Should a fancy sidebar be added to the left side of <pre> (`true`/`false`).
$apply-link-underline: true !default; // Should an underline be applied to all <a> elements? (`true`/`false`).
$apply-link-hover-fade: true !default; // Should the :hover and :focus state of <a> elements use fade-out instead of a different color (`true`/`false`).
$style-link-active-state: false !default; // [Hidden flag] Should the :active state of <a> elements be stylized, same as the :hover state (`true`/`false`).
// Base typography rules
@if $use-fluid-typography {
// Calculation of local variables (unitless values needed for the calculation of fluid typography)
$_fluid-type-unitless-size-change: ($fluid-type-large-type - $fluid-type-small-type)/($fluid-type-small-type * 0 + 1);
$_fluid-type-unitless-distance: ($fluid-type-end-breakpoint - $fluid-type-start-breakpoint)/($fluid-type-start-breakpoint * 0 + 1);
html {
font-size: #{$fluid-type-small-type};
}
@media screen and (min-width: #{$fluid-type-start-breakpoint}) {
html {
font-size: $base-root-font-size; // If the below calculation does not work, this is the fallback.
font-size: calc(#{$fluid-type-small-type} + #{$_fluid-type-unitless-size-change} * ((100vw - #{$fluid-type-start-breakpoint}) / #{$_fluid-type-unitless-distance}));
}
}
@media screen and (min-width: #{$fluid-type-end-breakpoint}) {
html {
font-size: #{$fluid-type-large-type};
}
}
}
@else {
html {
font-size: $base-root-font-size; // Set root's font sizing.
}
}
@if $apply-defaults-to-all {
html, * {
font-family: #{$base-font-family};
line-height: $base-line-height;
// Prevent adjustments of font size after orientation changes in mobile.
-webkit-text-size-adjust: 100%;
}
* {
font-size: $base-font-size;
}
}
@else {
html {
font-family: #{$base-font-family};
line-height: $base-line-height;
// Prevent adjustments of font size after orientation changes in mobile.
-webkit-text-size-adjust: 100%;
}
}
body {
margin: $body-margin;
color: $fore-color;
background: $back-color;
}
// Correct display for older versions of IE. Fix display of some elements in other browsers as well.
article, aside, section, figcaption, figure, main, details, menu {
display: block;
}
// Correct display in all browsers.
summary {
display: list-item;
}
// Abbreviations
abbr[title] {
border-bottom: none; // Remove bottom border in Firefox 39-.
text-decoration: underline; // Opinionated style-fix for all browsers.
}
// Correct display for older versions of IE.
audio, video {
display: inline-block;
}
// Hide overflow in IE.
svg:not(:root) {
overflow: hidden;
}
// Show overflow in IE.
input {
overflow: visible;
}
// Make images responsive by default.
img {
max-width: 100%;
height: auto;
}
// Fix display of <dfn> element in older versions of Android.
@if $include-dfn-fix {
dfn {
font-style: italic;
}
}
h1, h2, h3, h4, h5, h6 {
line-height: $heading-line-height;
margin: $heading-margin;
font-weight: $heading-font-weight;
small {
color: $heading-smalltext-fore-color;
@if $make-heading-smalltext-block {
display: block;
@if $heading-smalltext-b-top-margin != 0 {
margin-top: $heading-smalltext-b-top-margin;
}
@if $heading-smalltext-b-font-size != $small-font-size {
font-size: $heading-smalltext-b-font-size;
}
}
}
}
h1 {
font-size: $h1-font-size;
}
h2 {
font-size: $h2-font-size;
}
h3 {
font-size: $h3-font-size;
}
h4 {
font-size: $h4-font-size;
}
h5 {
font-size: $h5-font-size;
}
h6 {
font-size: $h6-font-size;
}
p {
margin: $paragraph-margin;
}
ol, ul {
margin: $list-margin;
padding-left: $list-left-padding;
}
b, strong {
font-weight: $bold-font-weight;
}
hr {
// Fixes and defaults for styling
box-sizing: content-box;
border: 0;
overflow: visible;
// Actual styling using variables
line-height: $horizontal-rule-line-height;
margin: $horizontal-rule-margin;
@if $horizontal-rule-fancy-style {
height: $_1px;
background: linear-gradient(#{$horizontal-rule-fancy-gradient});
}
@else {
height: 0;
border-top: $horizontal-rule-border-style;
}
}
blockquote {
display: block;
position: relative;
font-style: italic;
@if $blockquote-back-color != $back-color {
background: $blockquote-back-color;
}
@if $blockquote-fore-color != $fore-color {
color: $blockquote-fore-color;
}
// Overwrite defaults
margin: $blockquote-margin;
padding: $blockquote-padding;
@if $blockquote-border-style != 0 {
border: $blockquote-border-style;
}
@if $blockquote-sidebar-style != 0 {
border-left: $blockquote-sidebar-style;
}
@if $blockquote-border-radius != 0 {
border-radius: $blockquote-border-radius;
}
@if $blockquote-box-shadow != none {
box-shadow: $blockquote-box-shadow;
}
&:after {
position: absolute;
font-style: normal;
font-size: $blockquote-cite-font-size;
@if $blockquote-cite-fore-color != $blockquote-fore-color {
color: $blockquote-cite-fore-color;
}
left: $blockquote-cite-left-position;
bottom: $blockquote-cite-bottom-position;
content: '\2014 \2009'attr(cite);
}
}
$use-default-code-fonts: true !default;
@if $use-default-code-fonts {
code, kbd, pre, samp{
font-family: monospace, monospace; // Applies display fix for all code elements
}
}
@else {
code, kbd, pre, samp{
font-family: $code-font-family; // Display fix should be applied manually!
}
}
code {
@if $code-element-border-style != 0{
border: $code-element-border-style;
}
@if $code-element-border-radius != 0 {
border-radius: $code-element-border-radius;
}
@if $code-element-back-color != $back-color {
background: $code-element-back-color;
}
@if $code-element-fore-color != $fore-color {
color: $code-element-fore-color;
}
@if $code-element-padding != 0 {
padding: $code-element-padding;
}
@if $code-element-box-shadow != none {
box-shadow: $code-element-box-shadow;
}
}
pre {
overflow: auto; // Responsiveness
@if $pre-element-border-style != 0 {
border: $pre-element-border-style;
}
@if $pre-element-border-radius != 0 {
border-radius: $pre-element-border-radius;
}
@if $pre-element-back-color != $back-color {
background: $pre-element-back-color;
}
@if $pre-element-fore-color != $fore-color {
color: $pre-element-fore-color;
}
@if $pre-element-padding != 0 {
padding: $pre-element-padding;
}
@if $pre-element-margin != 0 {
margin: $pre-element-margin;
}
@if $add-pre-element-sidebar {
border-left: $pre-element-sidebar-style;
}
@if $pre-element-box-shadow != none {
box-shadow: $pre-element-box-shadow;
}
}
kbd {
@if $kbd-element-border-style != 0 {
border: $kbd-element-border-style;
}
@if $kbd-element-border-radius != 0 {
border-radius: $kbd-element-border-radius;
}
@if $kbd-element-back-color != $back-color {
background: $kbd-element-back-color;
}
@if $kbd-element-fore-color != $fore-color {
color: $kbd-element-fore-color;
}
@if $kbd-element-padding != 0 {
padding: $kbd-element-padding;
}
@if $kbd-element-box-shadow != none {
box-shadow: $kbd-element-box-shadow;
}
}
$style-samp-element: false !default;
@if $style-samp-element {
samp{
@if $samp-element-border-style != 0 {
border: $samp-element-border-style;
}
@if $samp-element-border-radius != 0 {
border-radius: $samp-element-border-radius;
}
@if $samp-element-back-color != $back-color {
background: $samp-element-back-color;
}
@if $samp-element-fore-color != $fore-color {
color: $samp-element-fore-color;
}
@if $samp-element-padding != 0 {
padding: $samp-element-padding;
}
@if $samp-element-box-shadow != none {
box-shadow: $samp-element-box-shadow;
}
}
}
@if $small-font-size == $sub-font-size and $small-font-size == $sup-font-size {
small, sup, sub {
font-size: $small-font-size;
}
sup {
top: $sup-top;
}
sub{
bottom: $sub-bottom;
}
sup, sub {
line-height: 0;
position: relative;
vertical-align: baseline;
}
}
@else if $small-font-size == $sub-font-size {
small, sub {
font-size: $small-font-size;
}
sup {
font-size: $sup-font-size;
top: $sup-top;
}
sub {
bottom: $sub-bottom;
}
sup, sub {
line-height: 0;
position: relative;
vertical-align: baseline;
}
}
@else if $small-font-size == $sup-font-size {
small, sup {
font-size: $small-font-size;
}
sup {
top: $sup-top;
}
sub {
font-size: $sub-font-size;
bottom: $sub-bottom;
}
sup, sub {
line-height: 0;
position: relative;
vertical-align: baseline;
}
}
@else if $sup-font-size == $sub-font-size {
small {
font-size: $small-font-size;
}
sup, sub {
font-size: $sup-font-size;
line-height: 0;
position: relative;
vertical-align: baseline;
}
sup {
top: $sup-top;
}
sub{
bottom: $sub-bottom;
}
}
@else {
small {
font-size: $small-font-size;
}
sup {
font-size: $sup-font-size;
top: $sup-top;
}
sub{
font-size: $sub-font-size;
bottom: $sub-bottom;
}
sup, sub {
line-height: 0;
position: relative;
vertical-align: baseline;
}
}
// Link styling
a{
color: $link-fore-color;
@if $apply-link-underline {
text-decoration: underline;
}
@else {
text-decoration: none;
}
@if $link-font-weight != 500 {
font-weight: $link-font-weight;
}
@if $apply-link-hover-fade {
opacity: 1;
transition: opacity 0.3s;
}
&:visited {
color: $link-visited-fore-color;
}
@if $apply-link-hover-fade {
@if $style-link-active-state {
&:hover, &:focus, &:active {
opacity: 0.75;
}
}
@else {
&:hover, &:focus {
opacity: 0.75;
}
}
}
@else {
@if $style-link-active-state {
&:hover, &:focus, &:active {
color: $link-hover-fore-color;
}
}
@else {
&:hover, &:focus {
color: $link-hover-fore-color;
}
}
}
}
// Captions for figures
figcaption {
@if $figcaption-font-size != 100% {
font-size: $figcaption-font-size;
}
@if $figcaption-fore-color != $fore-color {
color: $figcaption-fore-color;
}
}
/*
Browsers resets and base typography.
*/
$apply-defaults-to-all: true !default; // Should default values be applied to all elements? (`true`/`false`).
$base-root-font-size: 16px !default; // Root font sizing for all elements - Should only be specified in `px` units!
$_1px: (1px/$base-root-font-size) * 1rem !default; // Calculated rem value of 1px.
$use-fluid-typography: false !default; // Should fluid typography be used at the root element? (`true`/`false`)
$fluid-type-start-breakpoint: 320px !default; // Breakpoint where fluid typography scaling starts.
$fluid-type-end-breakpoint: 1600px !default; // Breakpoint where fluid typography scaling ends.
$fluid-type-small-type: 14px !default; // Smallest root font size for fluid typography.
$fluid-type-large-type: 18px !default; // Largest root font size for fluid typography.
$include-dfn-fix: true !default; // Fix display of <dfn> element in older versions of Android.
$make-heading-smalltext-block: false !default; // Should <small> elements in headings be displayed as blocks (`true`/`false`).
$horizontal-rule-fancy-style: false !default; // Should a fancy styling be applied for the <hr> element (`true`/`false`).
$add-pre-element-sidebar: false !default; // Should a fancy sidebar be added to the left side of <pre> (`true`/`false`).
$apply-link-underline: true !default; // Should an underline be applied to all <a> elements? (`true`/`false`).
$apply-link-hover-fade: true !default; // Should the :hover and :focus state of <a> elements use fade-out instead of a different color (`true`/`false`).
$style-link-active-state: false !default; // [Hidden flag] Should the :active state of <a> elements be stylized, same as the :hover state (`true`/`false`).
// Base typography rules
@if $use-fluid-typography {
// Calculation of local variables (unitless values needed for the calculation of fluid typography)
$_fluid-type-unitless-size-change: ($fluid-type-large-type - $fluid-type-small-type)/($fluid-type-small-type * 0 + 1);
$_fluid-type-unitless-distance: ($fluid-type-end-breakpoint - $fluid-type-start-breakpoint)/($fluid-type-start-breakpoint * 0 + 1);
html {
font-size: #{$fluid-type-small-type};
}
@media screen and (min-width: #{$fluid-type-start-breakpoint}) {
html {
font-size: $base-root-font-size; // If the below calculation does not work, this is the fallback.
font-size: calc(#{$fluid-type-small-type} + #{$_fluid-type-unitless-size-change} * ((100vw - #{$fluid-type-start-breakpoint}) / #{$_fluid-type-unitless-distance}));
}
}
@media screen and (min-width: #{$fluid-type-end-breakpoint}) {
html {
font-size: #{$fluid-type-large-type};
}
}
}
@else {
html {
font-size: $base-root-font-size; // Set root's font sizing.
}
}
@if $apply-defaults-to-all {
html, * {
font-family: #{$base-font-family};
line-height: $base-line-height;
// Prevent adjustments of font size after orientation changes in mobile.
-webkit-text-size-adjust: 100%;
}
* {
font-size: $base-font-size;
}
}
@else {
html {
font-family: #{$base-font-family};
line-height: $base-line-height;
// Prevent adjustments of font size after orientation changes in mobile.
-webkit-text-size-adjust: 100%;
}
}
body {
margin: $body-margin;
color: $fore-color;
background: $back-color;
}
// Correct display for older versions of IE. Fix display of some elements in other browsers as well.
article, aside, section, figcaption, figure, main, details, menu {
display: block;
}
// Correct display in all browsers.
summary {
display: list-item;
}
// Abbreviations
abbr[title] {
border-bottom: none; // Remove bottom border in Firefox 39-.
text-decoration: underline; // Opinionated style-fix for all browsers.
}
// Correct display for older versions of IE.
audio, video {
display: inline-block;
}
// Hide overflow in IE.
svg:not(:root) {
overflow: hidden;
}
// Show overflow in IE.
input {
overflow: visible;
}
// Make images responsive by default.
img {
max-width: 100%;
height: auto;
}
// Fix display of <dfn> element in older versions of Android.
@if $include-dfn-fix {
dfn {
font-style: italic;
}
}
h1, h2, h3, h4, h5, h6 {
line-height: $heading-line-height;
margin: $heading-margin;
font-weight: $heading-font-weight;
small {
color: $heading-smalltext-fore-color;
@if $make-heading-smalltext-block {
display: block;
@if $heading-smalltext-b-top-margin != 0 {
margin-top: $heading-smalltext-b-top-margin;
}
@if $heading-smalltext-b-font-size != $small-font-size {
font-size: $heading-smalltext-b-font-size;
}
}
}
}
h1 {
font-size: $h1-font-size;
}
h2 {
font-size: $h2-font-size;
}
h3 {
font-size: $h3-font-size;
}
h4 {
font-size: $h4-font-size;
}
h5 {
font-size: $h5-font-size;
}
h6 {
font-size: $h6-font-size;
}
p {
margin: $paragraph-margin;
}
ol, ul {
margin: $list-margin;
padding-left: $list-left-padding;
}
b, strong {
font-weight: $bold-font-weight;
}
hr {
// Fixes and defaults for styling
box-sizing: content-box;
border: 0;
overflow: visible;
// Actual styling using variables
line-height: $horizontal-rule-line-height;
margin: $horizontal-rule-margin;
@if $horizontal-rule-fancy-style {
height: $_1px;
background: linear-gradient(#{$horizontal-rule-fancy-gradient});
}
@else {
height: 0;
border-top: $horizontal-rule-border-style;
}
}
blockquote {
display: block;
position: relative;
font-style: italic;
@if $blockquote-back-color != $back-color {
background: $blockquote-back-color;
}
@if $blockquote-fore-color != $fore-color {
color: $blockquote-fore-color;
}
// Overwrite defaults
margin: $blockquote-margin;
padding: $blockquote-padding;
@if $blockquote-border-style != 0 {
border: $blockquote-border-style;
}
@if $blockquote-sidebar-style != 0 {
border-left: $blockquote-sidebar-style;
}
@if $blockquote-border-radius != 0 {
border-radius: $blockquote-border-radius;
}
@if $blockquote-box-shadow != none {
box-shadow: $blockquote-box-shadow;
}
&:after {
position: absolute;
font-style: normal;
font-size: $blockquote-cite-font-size;
@if $blockquote-cite-fore-color != $blockquote-fore-color {
color: $blockquote-cite-fore-color;
}
left: $blockquote-cite-left-position;
bottom: $blockquote-cite-bottom-position;
content: '\2014 \2009'attr(cite);
}
}
$use-default-code-fonts: true !default;
@if $use-default-code-fonts {
code, kbd, pre, samp{
font-family: monospace, monospace; // Applies display fix for all code elements
}
}
@else {
code, kbd, pre, samp{
font-family: $code-font-family; // Display fix should be applied manually!
}
}
code {
@if $code-element-border-style != 0{
border: $code-element-border-style;
}
@if $code-element-border-radius != 0 {
border-radius: $code-element-border-radius;
}
@if $code-element-back-color != $back-color {
background: $code-element-back-color;
}
@if $code-element-fore-color != $fore-color {
color: $code-element-fore-color;
}
@if $code-element-padding != 0 {
padding: $code-element-padding;
}
@if $code-element-box-shadow != none {
box-shadow: $code-element-box-shadow;
}
}
pre {
overflow: auto; // Responsiveness
@if $pre-element-border-style != 0 {
border: $pre-element-border-style;
}
@if $pre-element-border-radius != 0 {
border-radius: $pre-element-border-radius;
}
@if $pre-element-back-color != $back-color {
background: $pre-element-back-color;
}
@if $pre-element-fore-color != $fore-color {
color: $pre-element-fore-color;
}
@if $pre-element-padding != 0 {
padding: $pre-element-padding;
}
@if $pre-element-margin != 0 {
margin: $pre-element-margin;
}
@if $add-pre-element-sidebar {
border-left: $pre-element-sidebar-style;
}
@if $pre-element-box-shadow != none {
box-shadow: $pre-element-box-shadow;
}
}
kbd {
@if $kbd-element-border-style != 0 {
border: $kbd-element-border-style;
}
@if $kbd-element-border-radius != 0 {
border-radius: $kbd-element-border-radius;
}
@if $kbd-element-back-color != $back-color {
background: $kbd-element-back-color;
}
@if $kbd-element-fore-color != $fore-color {
color: $kbd-element-fore-color;
}
@if $kbd-element-padding != 0 {
padding: $kbd-element-padding;
}
@if $kbd-element-box-shadow != none {
box-shadow: $kbd-element-box-shadow;
}
}
$style-samp-element: false !default;
@if $style-samp-element {
samp{
@if $samp-element-border-style != 0 {
border: $samp-element-border-style;
}
@if $samp-element-border-radius != 0 {
border-radius: $samp-element-border-radius;
}
@if $samp-element-back-color != $back-color {
background: $samp-element-back-color;
}
@if $samp-element-fore-color != $fore-color {
color: $samp-element-fore-color;
}
@if $samp-element-padding != 0 {
padding: $samp-element-padding;
}
@if $samp-element-box-shadow != none {
box-shadow: $samp-element-box-shadow;
}
}
}
@if $small-font-size == $sub-font-size and $small-font-size == $sup-font-size {
small, sup, sub {
font-size: $small-font-size;
}
sup {
top: $sup-top;
}
sub{
bottom: $sub-bottom;
}
sup, sub {
line-height: 0;
position: relative;
vertical-align: baseline;
}
}
@else if $small-font-size == $sub-font-size {
small, sub {
font-size: $small-font-size;
}
sup {
font-size: $sup-font-size;
top: $sup-top;
}
sub {
bottom: $sub-bottom;
}
sup, sub {
line-height: 0;
position: relative;
vertical-align: baseline;
}
}
@else if $small-font-size == $sup-font-size {
small, sup {
font-size: $small-font-size;
}
sup {
top: $sup-top;
}
sub {
font-size: $sub-font-size;
bottom: $sub-bottom;
}
sup, sub {
line-height: 0;
position: relative;
vertical-align: baseline;
}
}
@else if $sup-font-size == $sub-font-size {
small {
font-size: $small-font-size;
}
sup, sub {
font-size: $sup-font-size;
line-height: 0;
position: relative;
vertical-align: baseline;
}
sup {
top: $sup-top;
}
sub{
bottom: $sub-bottom;
}
}
@else {
small {
font-size: $small-font-size;
}
sup {
font-size: $sup-font-size;
top: $sup-top;
}
sub{
font-size: $sub-font-size;
bottom: $sub-bottom;
}
sup, sub {
line-height: 0;
position: relative;
vertical-align: baseline;
}
}
// Link styling
a{
color: $link-fore-color;
@if $apply-link-underline {
text-decoration: underline;
}
@else {
text-decoration: none;
}
@if $link-font-weight != 500 {
font-weight: $link-font-weight;
}
@if $apply-link-hover-fade {
opacity: 1;
transition: opacity 0.3s;
}
&:visited {
color: $link-visited-fore-color;
}
@if $apply-link-hover-fade {
@if $style-link-active-state {
&:hover, &:focus, &:active {
opacity: 0.75;
}
}
@else {
&:hover, &:focus {
opacity: 0.75;
}
}
}
@else {
@if $style-link-active-state {
&:hover, &:focus, &:active {
color: $link-hover-fore-color;
}
}
@else {
&:hover, &:focus {
color: $link-hover-fore-color;
}
}
}
}
// Captions for figures
figcaption {
@if $figcaption-font-size != 100% {
font-size: $figcaption-font-size;
}
@if $figcaption-fore-color != $fore-color {
color: $figcaption-fore-color;
}
}

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

View file

@ -1,101 +1,101 @@
// Input_control module's mixin definitions are here. For the module itself
// check `_input_control.scss`.
// Mixin for alternate buttons (button color variants).
// Variables:
// - $button-alt-name : The name of the class used for the alternate button.
// - $button-alt-back-color : The background color of the alternate button.
// - $button-alt-back-opacity : Opacity of the background color of the alternate button.
// - $button-alt-hover-back-opacity : Opacity of the background color of the alternate button on hover.
// - $button-alt-fore-color : (Optional) The text color of the alternate button. Defaults to the text color of the button.
// Notes:
// Due to something like `.button.secondary` being a higher specificity than `a.button` or `a`, no extra rules are
// required for such elements. However rules for the normal button elements are applied in order to not require the
// base class for the button styles.
@mixin make-button-alt-color ($button-alt-name, $button-alt-back-color, $button-alt-back-opacity,
$button-alt-hover-back-opacity, $button-alt-fore-color: $button-fore-color) {
button.#{$button-alt-name}, [type="button"].#{$button-alt-name}, [type="submit"].#{$button-alt-name},
[type="reset"].#{$button-alt-name}, .#{$button-class-name}.#{$button-alt-name}, [role="button"].#{$button-alt-name} {
background: rgba($button-alt-back-color, $button-alt-back-opacity);
@if $button-alt-fore-color != $button-fore-color {
color: $button-alt-fore-color;
}
&:hover, &:focus {
background: rgba($button-alt-back-color, $button-alt-hover-back-opacity);
}
}
@if $style-link-active-state {
a.#{$button-class-name}.#{$button-alt-name}:active, a[role="button"].#{$button-alt-name}:active {
background: rgba($button-alt-back-color, $button-alt-hover-back-opacity);
}
}
}
// Mixin for alternate button styles (button style variants).
// Variables:
// - $button-alt-name : The name of the class used for the alternate button style.
// - $button-alt-border-style : The border style of the alternate button style.
// - $button-alt-border-radius : Border radius of the alternate button style.
// - $button-alt-padding : Padding of the alternate button style.
// - $button-alt-margin : Margin of the alternate button style.
// Notes:
// Due to something like `.button.small` being a higher specificity than `a.small` or `a`, no extra rules are
// required for such elements. However rules for the normal button elements are applied in order to not require the
// base class for the button styles.
@mixin make-button-alt-style ($button-alt-name, $button-alt-border-style, $button-alt-border-radius,
$button-alt-padding, $button-alt-margin) {
button.#{$button-alt-name}, [type="button"].#{$button-alt-name}, [type="submit"].#{$button-alt-name},
[type="reset"].#{$button-alt-name}, .#{$button-class-name}.#{$button-alt-name}, [role="button"].#{$button-alt-name} {
@if $button-alt-border-style != $button-border-style {
border: $button-alt-border-style;
}
@if $button-alt-border-radius != $button-border-radius {
border-radius: $button-alt-border-radius;
}
@if $button-alt-padding != $button-padding {
padding: $button-alt-padding;
}
@if $button-alt-margin != $button-margin {
margin: $button-alt-margin;
}
}
}
// Mixin for alternate switch (switch color variants).
// Variables:
// - $switch-alt-name : The name of the class used for the alternate switch.
// - $switch-alt-on-knob-back-color : The background color of the alternate switch's knob when the switch is turned on.
// - $switch-alt-on-bar-back-color : (Optional) The background color of the alternate switch's bar when the switch is turned on. Defaults to the background color of the switch's bar when the switch is turned on.
// - $switch-alt-knob-back-color : (Optional) The background color of the alternate switch's knob. Defaults to the background color of the switch's knob.
// - $switch-alt-bar-back-color : (Optional) The background color of the alternate switch's bar. Defaults to the background color of the switch's bar.
@mixin make-switch-alt-color ($switch-alt-name, $switch-alt-on-knob-back-color,
$switch-alt-on-bar-back-color: $switch-on-bar-back-color, $switch-alt-knob-back-color: $switch-knob-back-color,
$switch-alt-bar-back-color: $switch-bar-back-color) {
@if not ($include-switch) {
@error "Input_control module's switch mixins are only available if switchws are enabled. Set '$include-switch' to 'true' and try again!";
}
[type="checkbox"] + label.#{$switch-name}.#{$switch-alt-name},
[type="radio"] + label.#{$switch-name}.#{$switch-alt-name} {
&:before {
@if $switch-alt-bar-back-color != $switch--bar-back-color {
background: $switch-alt-bar-back-color;
}
}
&:after {
@if $switch-alt-knob-back-color != $switch-knob-back-color {
background: $switch-alt-knob-back-color;
}
}
}
[type="checkbox"]:checked + label.#{$switch-name}.#{$switch-alt-name},
[type="radio"]:checked + label.#{$switch-name}.#{$switch-alt-name} {
&:before {
@if $switch-alt-on-bar-back-color != $switch-on-bar-back-color {
background: $switch-alt-on-bar-back-color;
}
}
&:after {
@if $switch-alt-on-knob-back-color != $switch-on-knob-back-color {
background: $switch-alt-on-knob-back-color;
}
}
}
}
// Input_control module's mixin definitions are here. For the module itself
// check `_input_control.scss`.
// Mixin for alternate buttons (button color variants).
// Variables:
// - $button-alt-name : The name of the class used for the alternate button.
// - $button-alt-back-color : The background color of the alternate button.
// - $button-alt-back-opacity : Opacity of the background color of the alternate button.
// - $button-alt-hover-back-opacity : Opacity of the background color of the alternate button on hover.
// - $button-alt-fore-color : (Optional) The text color of the alternate button. Defaults to the text color of the button.
// Notes:
// Due to something like `.button.secondary` being a higher specificity than `a.button` or `a`, no extra rules are
// required for such elements. However rules for the normal button elements are applied in order to not require the
// base class for the button styles.
@mixin make-button-alt-color ($button-alt-name, $button-alt-back-color, $button-alt-back-opacity,
$button-alt-hover-back-opacity, $button-alt-fore-color: $button-fore-color) {
button.#{$button-alt-name}, [type="button"].#{$button-alt-name}, [type="submit"].#{$button-alt-name},
[type="reset"].#{$button-alt-name}, .#{$button-class-name}.#{$button-alt-name}, [role="button"].#{$button-alt-name} {
background: rgba($button-alt-back-color, $button-alt-back-opacity);
@if $button-alt-fore-color != $button-fore-color {
color: $button-alt-fore-color;
}
&:hover, &:focus {
background: rgba($button-alt-back-color, $button-alt-hover-back-opacity);
}
}
@if $style-link-active-state {
a.#{$button-class-name}.#{$button-alt-name}:active, a[role="button"].#{$button-alt-name}:active {
background: rgba($button-alt-back-color, $button-alt-hover-back-opacity);
}
}
}
// Mixin for alternate button styles (button style variants).
// Variables:
// - $button-alt-name : The name of the class used for the alternate button style.
// - $button-alt-border-style : The border style of the alternate button style.
// - $button-alt-border-radius : Border radius of the alternate button style.
// - $button-alt-padding : Padding of the alternate button style.
// - $button-alt-margin : Margin of the alternate button style.
// Notes:
// Due to something like `.button.small` being a higher specificity than `a.small` or `a`, no extra rules are
// required for such elements. However rules for the normal button elements are applied in order to not require the
// base class for the button styles.
@mixin make-button-alt-style ($button-alt-name, $button-alt-border-style, $button-alt-border-radius,
$button-alt-padding, $button-alt-margin) {
button.#{$button-alt-name}, [type="button"].#{$button-alt-name}, [type="submit"].#{$button-alt-name},
[type="reset"].#{$button-alt-name}, .#{$button-class-name}.#{$button-alt-name}, [role="button"].#{$button-alt-name} {
@if $button-alt-border-style != $button-border-style {
border: $button-alt-border-style;
}
@if $button-alt-border-radius != $button-border-radius {
border-radius: $button-alt-border-radius;
}
@if $button-alt-padding != $button-padding {
padding: $button-alt-padding;
}
@if $button-alt-margin != $button-margin {
margin: $button-alt-margin;
}
}
}
// Mixin for alternate switch (switch color variants).
// Variables:
// - $switch-alt-name : The name of the class used for the alternate switch.
// - $switch-alt-on-knob-back-color : The background color of the alternate switch's knob when the switch is turned on.
// - $switch-alt-on-bar-back-color : (Optional) The background color of the alternate switch's bar when the switch is turned on. Defaults to the background color of the switch's bar when the switch is turned on.
// - $switch-alt-knob-back-color : (Optional) The background color of the alternate switch's knob. Defaults to the background color of the switch's knob.
// - $switch-alt-bar-back-color : (Optional) The background color of the alternate switch's bar. Defaults to the background color of the switch's bar.
@mixin make-switch-alt-color ($switch-alt-name, $switch-alt-on-knob-back-color,
$switch-alt-on-bar-back-color: $switch-on-bar-back-color, $switch-alt-knob-back-color: $switch-knob-back-color,
$switch-alt-bar-back-color: $switch-bar-back-color) {
@if not ($include-switch) {
@error "Input_control module's switch mixins are only available if switchws are enabled. Set '$include-switch' to 'true' and try again!";
}
[type="checkbox"] + label.#{$switch-name}.#{$switch-alt-name},
[type="radio"] + label.#{$switch-name}.#{$switch-alt-name} {
&:before {
@if $switch-alt-bar-back-color != $switch--bar-back-color {
background: $switch-alt-bar-back-color;
}
}
&:after {
@if $switch-alt-knob-back-color != $switch-knob-back-color {
background: $switch-alt-knob-back-color;
}
}
}
[type="checkbox"]:checked + label.#{$switch-name}.#{$switch-alt-name},
[type="radio"]:checked + label.#{$switch-name}.#{$switch-alt-name} {
&:before {
@if $switch-alt-on-bar-back-color != $switch-on-bar-back-color {
background: $switch-alt-on-bar-back-color;
}
}
&:after {
@if $switch-alt-on-knob-back-color != $switch-on-knob-back-color {
background: $switch-alt-on-knob-back-color;
}
}
}
}

View file

@ -1,294 +1,294 @@
/*
Definitions for navigation elements.
*/
// Different elements are styled based on the same set of rules.
$button-class-name: 'button' !default; // Class name for the button-like elements.
$header-logo-name: 'logo' !default; // Class name for <header>'s logo.
$header-colorize-svgs: true !default; // [Hidden flag] Colorizes SVGs in the <header> element's logo (`true`/`false`).
$include-header-sticky: false !default; // Should the sticky class for <header> elements be included (`true`/`false`).
$header-sticky-name: 'sticky' !default; // Class name for sticky <header>.
$include-footer-sticky: false !default; // Should the sticky class for <footer> elements be included (`true`/`false`).
$footer-sticky-name: 'sticky' !default; // Class name for sticky <footer>.
$include-nav-styles: true !default; // [Hidden flag] Should <nav> elements by stylized? (`true`/`false`)
$nav-sublink-prefix: 'sublink' !default; // Prefix for the subcategory tabs in nav.
$nav-sublink-depth: 2 !default; // Amount of subcategory classes to add.
$nav-sublink-padding-left:12px !default; // Left padding to add to subcategories.
$nav-include-sublink-bar: false !default; // Should a border be added to the subcategories? (`true`/`false`)
$include-drawer: true !default; // [Hidden flag] Should the drawer component be included? (`true`/`false`)
$drawer-name: 'drawer' !default; // Class name for the drawer component.
$drawer-toggle-name: 'drawer-toggle' !default; // Class name for the drawer component's toggle.
$drawer-mobile-breakpoint:768px !default; // Mobile breakpoint for the drawer component.
$drawer-right-name: 'right' !default; // Class name for the right variant of the drawer component.
$drawer-persistent-name: 'persistent' !default; // Class name for the persisten variant of the drawer component.
$drawer-width: 320px !default; // Width of the drawer component.
$drawer-close-name: 'close' !default; // Class name of the close element for the drawer component.
// External variables' defaults are used only if you import this module on its own, without the rest of the framework.
$back-color: white !default; // [External variable - core] Background color for everything.
$fore-color: black !default; // [External variable - core] Foreground color for everything.
// Policy for below external flag is `ALWAYS_TRUE`. This is done due to links being underlined by default and as a safeguard from ugly branding.
$apply-link-underline: true !default; // [External flag - core] Should underlining be applied to <a> elements? (`true`/`false`)
$style-link-active-state: false !default; // [External flag - core] Should the :active state of <a> elements be stylized, same as the :hover state (`true`/`false`).
// The below variable is used to fix the display problem of the <header> element when used as a responsive row
$grid-row-name: 'row' !default; // [External flag - grid] Class name for the grid system rows.
$button-class-name: 'button' !default; // [External variable - input_control] Name of the button-like element styling class.
$button-box-shadow:0 1px 3px rgba(0,0,0, 0.1) !default;// [External variable - input_control] Value of button's box-shadow.
$button-border-style: 1px solid transparent !default; // [External variable - input_control] Value of button's border-style.
// Header styling.
header {
display: block; // Correct display for older versions of IE.
height: $header-height;
background: $header-back-color; // Always apply background color to avoid shine through
@if $header-fore-color != $fore-color {
color: $header-fore-color;
}
@if $header-border-style != 0 {
border: $header-border-style;
}
@if $header-margin != 0 {
margin: $header-margin;
}
@if $header-padding != 0 {
padding: $header-padding;
}
@if $header-box-shadow != none {
box-shadow: $header-box-shadow;
}
// Responsiveness for smaller displays, scrolls horizontally.
white-space: nowrap;
overflow-x: auto;
overflow-y: hidden;
// Header logo styling.
.#{$header-logo-name} {
@if $header-colorize-svgs { // Deals with SVG colorization in case people use SVGs.
color: $header-fore-color; // Only toggle off if you know what you're doing.
}
@if $header-logo-font-size != $base-font-size {
font-size: $header-logo-font-size;
}
@if $header-logo-line-height != $base-line-height {
line-height: $header-logo-line-height;
}
@if $header-logo-margin != 0 {
margin: $header-logo-margin;
}
@if $header-logo-padding != 0 {
padding: $header-logo-padding;
}
@if $apply-link-hover-fade {
transition: opacity 0.3s ;
}
}
// Link styling.
button, [type="button"],
a.#{$button-class-name}, label.#{$button-class-name}, .#{$button-class-name},
a[role="button"], label[role="button"], [role="button"] {
background: $header-back-color; // Apply color regardless to override styling from other things.
color: $header-fore-color;
vertical-align: top; // Alignemt, really important to make this work well.
@if $header-link-margin != 0 {
margin: $header-link-margin;
}
@if $style-link-active-state {
&:hover, &:focus, &:active {
background: $header-link-hover-color;
}
}
@else {
&:hover, &:focus {
background: $header-link-hover-color;
}
}
@if $button-box-shadow != none { // Override for buttons when shadow is enabled.
box-shadow: none;
}
@if $button-border-style != 0 { // Override for buttons when border-style is enabled.
border: 0;
}
}
@if $apply-link-underline { // Override for links if underline is enabled.
.#{$header-logo-name}, a.#{$button-class-name}, a[role="button"] {
text-decoration: none;
}
}
// Fix for responsive header, using the grid system's row and column alignment.
&.#{$grid-row-name} {
box-sizing: content-box;
}
}
// Navigation sidebar styling.
@if $include-nav-styles { // Unless you want unstylized <nav> elements, keep this flag on.
nav {
display: block; // Correct display for older versions of IE.
@if $nav-back-color != $back-color {
background: $nav-back-color;
}
@if $nav-fore-color != $fore-color {
color: $nav-fore-color;
}
@if $nav-border-style != 0 {
border: $nav-border-style;
}
@if $nav-border-radius != 0 {
border-radius: $nav-border-radius;
}
@if $nav-margin != 0 {
margin: $nav-margin;
}
@if $nav-padding != 0 {
padding: $nav-padding;
}
@if $nav-box-shadow != none {
box-shadow: $nav-box-shadow;
}
a, a:visited {
display: block;
color: $nav-link-fore-color; // Apply regardless to de-stylize visited links.
text-decoration: none;
}
// Subcategories in navigation.
@for $i from 1 through $nav-sublink-depth {
.#{$nav-sublink-prefix}-#{$i} {
padding-left: $i * $nav-sublink-padding-left;
position: relative;
@if $nav-include-sublink-bar {
&:before {
position: absolute;
left: $nav-sublink-bar-left-position;
top: -$nav-sublink-bar-width;
content: '';
height: 100%;
border: $nav-sublink-bar-width solid $nav-sublink-bar-color;
border-left: 0;
}
}
}
}
}
}
// Footer styling.
footer {
display: block; // Correct display for older versions of IE.
@if $footer-back-color != $back-color {
background: $footer-back-color;
}
@if $footer-fore-color != $fore-color {
color: $footer-fore-color;
}
@if $footer-border-style != 0 {
border: $footer-border-style;
}
@if $footer-margin != 0 {
margin: $footer-margin;
}
@if $footer-padding != 0 {
padding: $footer-padding;
}
font-size: $footer-font-size;
a, a:visited {
color: $footer-link-fore-color;
}
}
// Sticky headers and footers.
@if $include-header-sticky and $include-footer-sticky {
header.#{$header-sticky-name}, footer.#{$footer-sticky-name} {
position: -webkit-sticky;
position: sticky;
z-index: 1101; // Deals with certain problems when combined with cards and tables.
}
header.#{$header-sticky-name} {
top: 0;
}
footer.#{$footer-sticky-name} {
bottom: 0;
}
}
@else if $include-header-sticky {
header.#{$header-sticky-name} {
position: -webkit-sticky;
position: sticky;
top: 0;
z-index: 1101; // Deals with certain problems when combined with cards and tables.
}
}
@else if $include-footer-sticky {
footer.#{$footer-sticky-name} {
position: -webkit-sticky;
position: sticky;
bottom: 0;
z-index: 1101; // Deals with certain problems when combined with cards and tables.
}
}
// Responsive drawer component
@if $include-drawer {
.#{$drawer-toggle-name}:before {
position: relative;
top: $drawer-toggle-top;
font-family: sans-serif;
font-size: $drawer-toggle-font-size;
line-height: $drawer-toggle-line-height;
content: '\2261';
}
.#{$drawer-name} {
display: block;
box-sizing: border-box;
position: fixed;
top: 0;
width: $drawer-width;
height: 100vh;
overflow-y: auto;
background: $drawer-back-color;
@if $drawer-border-style != 0 {
border: $drawer-border-style;
}
@if $drawer-border-radius != 0 {
border-radius: $drawer-border-radius;
}
margin: 0;
@if $drawer-padding != 0 {
padding: $drawer-padding;
}
@if $drawer-box-shadow != none {
box-shadow: $drawer-box-shadow;
}
z-index: 1110;
&:not(.#{$drawer-right-name}) {
left: -$drawer-width;
transition: left 0.3s;
}
&.#{$drawer-right-name} {
right: -$drawer-width;
transition: right 0.3s;
}
& .#{$drawer-close-name} {
position: absolute;
top: $drawer-close-top;
right: $drawer-close-right;
z-index: 1111;
padding: 0; // Fixes the extra padding added from <label> styling.
}
}
@media screen and (max-width: #{$drawer-width}) {
.#{$drawer-name} {
width: 100%;
}
}
@media screen and (min-width: #{$drawer-mobile-breakpoint}){
.#{$drawer-name}:not(.#{$drawer-persistent-name}) {
position: static;
height: 100%;
z-index: 1100;
& .#{$drawer-close-name} {
display: none;
}
}
.#{$drawer-toggle-name}:not(.#{$drawer-persistent-name}) {
display: none;
}
}
:checked + .#{$drawer-name}:not(.#{$drawer-right-name}) {
left: 0;
}
:checked + .#{$drawer-name}.#{$drawer-right-name} {
right: 0;
}
}
/*
Definitions for navigation elements.
*/
// Different elements are styled based on the same set of rules.
$button-class-name: 'button' !default; // Class name for the button-like elements.
$header-logo-name: 'logo' !default; // Class name for <header>'s logo.
$header-colorize-svgs: true !default; // [Hidden flag] Colorizes SVGs in the <header> element's logo (`true`/`false`).
$include-header-sticky: false !default; // Should the sticky class for <header> elements be included (`true`/`false`).
$header-sticky-name: 'sticky' !default; // Class name for sticky <header>.
$include-footer-sticky: false !default; // Should the sticky class for <footer> elements be included (`true`/`false`).
$footer-sticky-name: 'sticky' !default; // Class name for sticky <footer>.
$include-nav-styles: true !default; // [Hidden flag] Should <nav> elements by stylized? (`true`/`false`)
$nav-sublink-prefix: 'sublink' !default; // Prefix for the subcategory tabs in nav.
$nav-sublink-depth: 2 !default; // Amount of subcategory classes to add.
$nav-sublink-padding-left:12px !default; // Left padding to add to subcategories.
$nav-include-sublink-bar: false !default; // Should a border be added to the subcategories? (`true`/`false`)
$include-drawer: true !default; // [Hidden flag] Should the drawer component be included? (`true`/`false`)
$drawer-name: 'drawer' !default; // Class name for the drawer component.
$drawer-toggle-name: 'drawer-toggle' !default; // Class name for the drawer component's toggle.
$drawer-mobile-breakpoint:768px !default; // Mobile breakpoint for the drawer component.
$drawer-right-name: 'right' !default; // Class name for the right variant of the drawer component.
$drawer-persistent-name: 'persistent' !default; // Class name for the persisten variant of the drawer component.
$drawer-width: 320px !default; // Width of the drawer component.
$drawer-close-name: 'close' !default; // Class name of the close element for the drawer component.
// External variables' defaults are used only if you import this module on its own, without the rest of the framework.
$back-color: white !default; // [External variable - core] Background color for everything.
$fore-color: black !default; // [External variable - core] Foreground color for everything.
// Policy for below external flag is `ALWAYS_TRUE`. This is done due to links being underlined by default and as a safeguard from ugly branding.
$apply-link-underline: true !default; // [External flag - core] Should underlining be applied to <a> elements? (`true`/`false`)
$style-link-active-state: false !default; // [External flag - core] Should the :active state of <a> elements be stylized, same as the :hover state (`true`/`false`).
// The below variable is used to fix the display problem of the <header> element when used as a responsive row
$grid-row-name: 'row' !default; // [External flag - grid] Class name for the grid system rows.
$button-class-name: 'button' !default; // [External variable - input_control] Name of the button-like element styling class.
$button-box-shadow:0 1px 3px rgba(0,0,0, 0.1) !default;// [External variable - input_control] Value of button's box-shadow.
$button-border-style: 1px solid transparent !default; // [External variable - input_control] Value of button's border-style.
// Header styling.
header {
display: block; // Correct display for older versions of IE.
height: $header-height;
background: $header-back-color; // Always apply background color to avoid shine through
@if $header-fore-color != $fore-color {
color: $header-fore-color;
}
@if $header-border-style != 0 {
border: $header-border-style;
}
@if $header-margin != 0 {
margin: $header-margin;
}
@if $header-padding != 0 {
padding: $header-padding;
}
@if $header-box-shadow != none {
box-shadow: $header-box-shadow;
}
// Responsiveness for smaller displays, scrolls horizontally.
white-space: nowrap;
overflow-x: auto;
overflow-y: hidden;
// Header logo styling.
.#{$header-logo-name} {
@if $header-colorize-svgs { // Deals with SVG colorization in case people use SVGs.
color: $header-fore-color; // Only toggle off if you know what you're doing.
}
@if $header-logo-font-size != $base-font-size {
font-size: $header-logo-font-size;
}
@if $header-logo-line-height != $base-line-height {
line-height: $header-logo-line-height;
}
@if $header-logo-margin != 0 {
margin: $header-logo-margin;
}
@if $header-logo-padding != 0 {
padding: $header-logo-padding;
}
@if $apply-link-hover-fade {
transition: opacity 0.3s ;
}
}
// Link styling.
button, [type="button"],
a.#{$button-class-name}, label.#{$button-class-name}, .#{$button-class-name},
a[role="button"], label[role="button"], [role="button"] {
background: $header-back-color; // Apply color regardless to override styling from other things.
color: $header-fore-color;
vertical-align: top; // Alignemt, really important to make this work well.
@if $header-link-margin != 0 {
margin: $header-link-margin;
}
@if $style-link-active-state {
&:hover, &:focus, &:active {
background: $header-link-hover-color;
}
}
@else {
&:hover, &:focus {
background: $header-link-hover-color;
}
}
@if $button-box-shadow != none { // Override for buttons when shadow is enabled.
box-shadow: none;
}
@if $button-border-style != 0 { // Override for buttons when border-style is enabled.
border: 0;
}
}
@if $apply-link-underline { // Override for links if underline is enabled.
.#{$header-logo-name}, a.#{$button-class-name}, a[role="button"] {
text-decoration: none;
}
}
// Fix for responsive header, using the grid system's row and column alignment.
&.#{$grid-row-name} {
box-sizing: content-box;
}
}
// Navigation sidebar styling.
@if $include-nav-styles { // Unless you want unstylized <nav> elements, keep this flag on.
nav {
display: block; // Correct display for older versions of IE.
@if $nav-back-color != $back-color {
background: $nav-back-color;
}
@if $nav-fore-color != $fore-color {
color: $nav-fore-color;
}
@if $nav-border-style != 0 {
border: $nav-border-style;
}
@if $nav-border-radius != 0 {
border-radius: $nav-border-radius;
}
@if $nav-margin != 0 {
margin: $nav-margin;
}
@if $nav-padding != 0 {
padding: $nav-padding;
}
@if $nav-box-shadow != none {
box-shadow: $nav-box-shadow;
}
a, a:visited {
display: block;
color: $nav-link-fore-color; // Apply regardless to de-stylize visited links.
text-decoration: none;
}
// Subcategories in navigation.
@for $i from 1 through $nav-sublink-depth {
.#{$nav-sublink-prefix}-#{$i} {
padding-left: $i * $nav-sublink-padding-left;
position: relative;
@if $nav-include-sublink-bar {
&:before {
position: absolute;
left: $nav-sublink-bar-left-position;
top: -$nav-sublink-bar-width;
content: '';
height: 100%;
border: $nav-sublink-bar-width solid $nav-sublink-bar-color;
border-left: 0;
}
}
}
}
}
}
// Footer styling.
footer {
display: block; // Correct display for older versions of IE.
@if $footer-back-color != $back-color {
background: $footer-back-color;
}
@if $footer-fore-color != $fore-color {
color: $footer-fore-color;
}
@if $footer-border-style != 0 {
border: $footer-border-style;
}
@if $footer-margin != 0 {
margin: $footer-margin;
}
@if $footer-padding != 0 {
padding: $footer-padding;
}
font-size: $footer-font-size;
a, a:visited {
color: $footer-link-fore-color;
}
}
// Sticky headers and footers.
@if $include-header-sticky and $include-footer-sticky {
header.#{$header-sticky-name}, footer.#{$footer-sticky-name} {
position: -webkit-sticky;
position: sticky;
z-index: 1101; // Deals with certain problems when combined with cards and tables.
}
header.#{$header-sticky-name} {
top: 0;
}
footer.#{$footer-sticky-name} {
bottom: 0;
}
}
@else if $include-header-sticky {
header.#{$header-sticky-name} {
position: -webkit-sticky;
position: sticky;
top: 0;
z-index: 1101; // Deals with certain problems when combined with cards and tables.
}
}
@else if $include-footer-sticky {
footer.#{$footer-sticky-name} {
position: -webkit-sticky;
position: sticky;
bottom: 0;
z-index: 1101; // Deals with certain problems when combined with cards and tables.
}
}
// Responsive drawer component
@if $include-drawer {
.#{$drawer-toggle-name}:before {
position: relative;
top: $drawer-toggle-top;
font-family: sans-serif;
font-size: $drawer-toggle-font-size;
line-height: $drawer-toggle-line-height;
content: '\2261';
}
.#{$drawer-name} {
display: block;
box-sizing: border-box;
position: fixed;
top: 0;
width: $drawer-width;
height: 100vh;
overflow-y: auto;
background: $drawer-back-color;
@if $drawer-border-style != 0 {
border: $drawer-border-style;
}
@if $drawer-border-radius != 0 {
border-radius: $drawer-border-radius;
}
margin: 0;
@if $drawer-padding != 0 {
padding: $drawer-padding;
}
@if $drawer-box-shadow != none {
box-shadow: $drawer-box-shadow;
}
z-index: 1110;
&:not(.#{$drawer-right-name}) {
left: -$drawer-width;
transition: left 0.3s;
}
&.#{$drawer-right-name} {
right: -$drawer-width;
transition: right 0.3s;
}
& .#{$drawer-close-name} {
position: absolute;
top: $drawer-close-top;
right: $drawer-close-right;
z-index: 1111;
padding: 0; // Fixes the extra padding added from <label> styling.
}
}
@media screen and (max-width: #{$drawer-width}) {
.#{$drawer-name} {
width: 100%;
}
}
@media screen and (min-width: #{$drawer-mobile-breakpoint}){
.#{$drawer-name}:not(.#{$drawer-persistent-name}) {
position: static;
height: 100%;
z-index: 1100;
& .#{$drawer-close-name} {
display: none;
}
}
.#{$drawer-toggle-name}:not(.#{$drawer-persistent-name}) {
display: none;
}
}
:checked + .#{$drawer-name}:not(.#{$drawer-right-name}) {
left: 0;
}
:checked + .#{$drawer-name}.#{$drawer-right-name} {
right: 0;
}
}

View file

@ -1,86 +1,86 @@
/*
Definitions for progress elements and spinners.
*/
// Progress elements use the progress element as their base.
$progress-max-value: 100 !default; // Arithmetic max value of <progress> - use integer values.
$progress-height: 14px !default; // Height of <progress>.
$include-spinner-donut: true !default; // [Hidden flag] Should spinner donuts be enabled? (`true`/`false`)
$spinner-donut-name: 'spinner-donut' !default; // Class name for donut spinner.
// Check the `_progress_mixins.scss` file to find this module's mixins.
@import 'progress_mixins';
// Default styling for progress. Use mixins for alternate styles.
progress {
display: block;
vertical-align: baseline; // Correct vertical alignment in certain browsers.
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
height: $progress-height;
// Older browsers will sort not display progress properly, but that's ok
width: 90%;
// Newer browsers will calculate the proper width
width: calc(100% - #{$progress-left-right-margin*2});
margin: $progress-top-bottom-margin $progress-left-right-margin;
border: $progress-border-style;
@if $progress-border-radius != 0 {
border-radius: $progress-border-radius;
}
@if $progress-box-shadow != none {
box-shadow: $progress-box-shadow;
}
background: $progress-back-color; // Background color of the element (IE 10+ and Firefox).
color: $progress-fore-color; // Foreground of the element (IE 10+).
&::-webkit-progress-value { // Foreground of the element (webkit browsers).
background: $progress-fore-color;
@if $progress-border-radius != 0 {
border-top-left-radius: $progress-border-radius;
border-bottom-left-radius: $progress-border-radius;
}
}
&::-webkit-progress-bar { // Background of the element (webkit browsers).
background: $progress-back-color;
}
&::-moz-progress-bar { // Foreground of the element (Firefox).
background: $progress-fore-color;
@if $progress-border-radius != 0 {
border-top-left-radius: $progress-border-radius;
border-bottom-left-radius: $progress-border-radius;
}
}
&[value="#{$progress-max-value}"] {
&::-webkit-progress-value {
@if $progress-border-radius != 0 {
border-radius: $progress-border-radius;
}
}
&::-moz-progress-bar {
@if $progress-border-radius != 0 {
border-radius: $progress-border-radius;
}
}
}
}
@if $include-spinner-donut { // Turn off to disable spinner donuts.
// Animation definition for donut spinner
@-webkit-keyframes spinner-donut-anim {
0% { -webkit-transform: rotate(0deg); }
100% { -webkit-transform: rotate(360deg);}
}
@keyframes spinner-donut-anim {
0% { transform: rotate(0deg); }
100% { transform: rotate(360deg);}
}
}
@if $include-spinner-donut { // Turn off to disable spinner donuts.
// Style for donut spinner
.#{$spinner-donut-name} {
display: inline-block;
border: $spinner-donut-border-thickness solid $spinner-donut-back-color;
border-left: $spinner-donut-border-thickness solid $spinner-donut-fore-color;
border-radius: 50%;
width: $spinner-donut-size;
height: $spinner-donut-size;
-webkit-animation: spinner-donut-anim 1.2s linear infinite;
animation: spinner-donut-anim 1.2s linear infinite;
}
}
/*
Definitions for progress elements and spinners.
*/
// Progress elements use the progress element as their base.
$progress-max-value: 100 !default; // Arithmetic max value of <progress> - use integer values.
$progress-height: 14px !default; // Height of <progress>.
$include-spinner-donut: true !default; // [Hidden flag] Should spinner donuts be enabled? (`true`/`false`)
$spinner-donut-name: 'spinner-donut' !default; // Class name for donut spinner.
// Check the `_progress_mixins.scss` file to find this module's mixins.
@import 'progress_mixins';
// Default styling for progress. Use mixins for alternate styles.
progress {
display: block;
vertical-align: baseline; // Correct vertical alignment in certain browsers.
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
height: $progress-height;
// Older browsers will sort not display progress properly, but that's ok
width: 90%;
// Newer browsers will calculate the proper width
width: calc(100% - #{$progress-left-right-margin*2});
margin: $progress-top-bottom-margin $progress-left-right-margin;
border: $progress-border-style;
@if $progress-border-radius != 0 {
border-radius: $progress-border-radius;
}
@if $progress-box-shadow != none {
box-shadow: $progress-box-shadow;
}
background: $progress-back-color; // Background color of the element (IE 10+ and Firefox).
color: $progress-fore-color; // Foreground of the element (IE 10+).
&::-webkit-progress-value { // Foreground of the element (webkit browsers).
background: $progress-fore-color;
@if $progress-border-radius != 0 {
border-top-left-radius: $progress-border-radius;
border-bottom-left-radius: $progress-border-radius;
}
}
&::-webkit-progress-bar { // Background of the element (webkit browsers).
background: $progress-back-color;
}
&::-moz-progress-bar { // Foreground of the element (Firefox).
background: $progress-fore-color;
@if $progress-border-radius != 0 {
border-top-left-radius: $progress-border-radius;
border-bottom-left-radius: $progress-border-radius;
}
}
&[value="#{$progress-max-value}"] {
&::-webkit-progress-value {
@if $progress-border-radius != 0 {
border-radius: $progress-border-radius;
}
}
&::-moz-progress-bar {
@if $progress-border-radius != 0 {
border-radius: $progress-border-radius;
}
}
}
}
@if $include-spinner-donut { // Turn off to disable spinner donuts.
// Animation definition for donut spinner
@-webkit-keyframes spinner-donut-anim {
0% { -webkit-transform: rotate(0deg); }
100% { -webkit-transform: rotate(360deg);}
}
@keyframes spinner-donut-anim {
0% { transform: rotate(0deg); }
100% { transform: rotate(360deg);}
}
}
@if $include-spinner-donut { // Turn off to disable spinner donuts.
// Style for donut spinner
.#{$spinner-donut-name} {
display: inline-block;
border: $spinner-donut-border-thickness solid $spinner-donut-back-color;
border-left: $spinner-donut-border-thickness solid $spinner-donut-fore-color;
border-radius: 50%;
width: $spinner-donut-size;
height: $spinner-donut-size;
-webkit-animation: spinner-donut-anim 1.2s linear infinite;
animation: spinner-donut-anim 1.2s linear infinite;
}
}

View file

@ -1,127 +1,127 @@
// Progress module's mixin definitions are here. For the module itself
// check `_progress.scss`.
// Mixin for inline progress.
// Variables:
// - $progress-inline-name : The name of the class used for the inline progress.
// - $progress-inline-width : The width of the inline progress.
@mixin make-progress-inline ($progress-inline-name, $progress-inline-width) {
progress.#{$progress-inline-name} {
display: inline-block;
vertical-align: middle; // Align progress bar vertically to look better with text next to it.
@if $progress-inline-width != 100% {
width: $progress-inline-width;
}
}
}
// Mixin for alternate progress (progress color variants).
// Variables:
// - $progress-alt-name : The name of the class used for the alternate progress.
// - $progress-alt-fore-color : The progress bar color of the alternate progress.
// - $progress-alt-back-color : (Optional) The background color of the alternate progress. Defaults to the background color of the progress.
@mixin make-progress-alt-color ($progress-alt-name, $progress-alt-fore-color, $progress-alt-back-color: $progress-back-color) {
progress.#{$progress-alt-name} {
@if $progress-alt-back-color != $progress-back-color {
background: $progress-alt-back-color; // Background color of the element (IE 10+ and Firefox).
&::-webkit-progress-bar { // Background of the element (webkit browsers).
background: $progress-alt-back-color;
}
}
@if $progress-alt-fore-color != $progress-fore-color {
color: $progress-alt-fore-color; // Foreground of the element (IE 10+).
&::-webkit-progress-value { // Foreground of the element (webkit browsers).
background: $progress-alt-fore-color;
}
&::-moz-progress-bar { // Foreground of the element (Firefox).
background: $progress-alt-fore-color;
}
}
}
}
// Mixin for alternate progress styles.
// Variables:
// - $progress-alt-name : The name of the class used for the alternate progress style.
// - $progress-alt-height : The height of the alternate progress style.
// - $progress-alt-top-bottom-margin : (Optional) The top and bottom margin of the alternate progress style. Defaults to the margin of the progress.
// - $progress-alt-left-right-margin : (Optional) The left and right margin of the alternate progress style. Defaults to the margin of the progress.
// - $progress-alt-border-style : (Optional) The border style of the alternate progress style. Defaults to the border style of the progress.
// - $progress-alt-border-radius : (Optional) The border radius of the alternate progress style. Defaults to the border radius of the progress.
// - $progress-alt-box-shadow : (Optional) The box shadow of the alternate progress style. Defaults to the box shadow of the progress.
@mixin make-progress-alt-style ($progress-alt-name, $progress-alt-height,
$progress-alt-top-bottom-margin : $progress-top-bottom-margin, $progress-alt-left-right-margin : $progress-left-right-margin,
$progress-alt-border-style : $progress-border-style, $progress-alt-border-radius : $progress-border-radius,
$progress-alt-box-shadow : $progress-box-shadow) {
progress.#{$progress-alt-name} {
@if $progress-alt-height != $progress-height {
height: $progress-alt-height;
}
@if $progress-alt-left-right-margin != $progress-left-right-margin {
width: calc(100% - #{$progress-alt-left-right-margin*2});
}
@if $progress-alt-left-right-margin != $progress-left-right-margin or $progress-alt-top-bottom-margin != $progress-top-bottom-margin {
margin: $progress-alt-top-bottom-margin $progress-alt-left-right-margin;
}
@if $progress-alt-top-bottom-margin != $progress-top-bottom-margin {
margin: $progress-alt-top-bottom-margin auto;
}
@if $progress-alt-border-style != $progress-border-style {
border: $progress-alt-border-style;
}
@if progress-alt-border-radius != $progress-border-radius {
border-radius: $progress-alt-border-radius;
&::-webkit-progress-value {
border-top-left-radius: $progress-alt-border-radius;
border-bottom-left-radius: $progress-alt-border-radius;
}
&::-moz-progress-bar {
border-top-left-radius: $progress-alt-border-radius;
border-bottom-left-radius: $progress-alt-border-radius;
}
&[value="#{$progress-max-value}"] {
&::-webkit-progress-value {
border-radius: $progress-alt-border-radius;
}
&::-moz-progress-bar {
border-radius: $progress-alt-border-radius;
}
}
}
@if $progress-alt-box-shadow != $progress-box-shadow {
box-shadow: $progress-alt-box-shadow;
}
}
}
// Mixin for alternate donut spinner colors (spinner donut color variants).
// Variables:
// - $spinner-donut-alt-name : The name of the class used for the alternate donut spinner.
// - $spinner-donut-alt-back-color : The background color of the alternate donut spinner.
// - $spinner-donut-alt-fore-color : The foreground color of the alternate donut spinner.
@mixin make-spinner-donut-alt-color ($spinner-donut-alt-name, $spinner-donut-alt-back-color, $spinner-donut-alt-fore-color) {
@if not ($include-spinner-donut) {
@error "Progress module's spinner donut mixins are only available if spinner donuts are enabled. Set '$include-spinner-donut' to 'true' and try again!";
}
.#{$spinner-donut-name}.#{$spinner-donut-alt-name} {
border: $spinner-donut-border-thickness solid $spinner-donut-alt-back-color;
border-left: $spinner-donut-border-thickness solid $spinner-donut-alt-fore-color;
}
}
// Mixin for alternate donut spinner styles (spinner donut styles variants).
// Variables:
// - $spinner-donut-alt-name : The name of the class used for the alternate donut spinner style.
// - $spinner-donut-alt-size : The size of the alternate donut spinner style.
// - $spinner-donut-alt-border-thickness : (Optional) The border thickness of the alternate donut spinner style.
// Defaults to the value of $spinner-donut-alt-border-thickness.
@mixin make-spinner-donut-alt-style ($spinner-donut-alt-name, $spinner-donut-alt-size,
$spinner-donut-alt-border-thickness : $spinner-donut-border-thickness) {
@if not ($include-spinner-donut) {
@error "Progress module's spinner donut mixins are only available if spinner donuts are enabled. Set '$include-spinner-donut' to 'true' and try again!";
}
.#{$spinner-donut-name}.#{$spinner-donut-alt-name} {
@if $spinner-donut-alt-border-thickness != $spinner-donut-border-thickness {
border-width: $spinner-donut-alt-border-thickness;
}
@if $spinner-donut-alt-size != $spinner-donut-size {
width: $spinner-donut-alt-size;
height: $spinner-donut-alt-size;
}
}
}
// Progress module's mixin definitions are here. For the module itself
// check `_progress.scss`.
// Mixin for inline progress.
// Variables:
// - $progress-inline-name : The name of the class used for the inline progress.
// - $progress-inline-width : The width of the inline progress.
@mixin make-progress-inline ($progress-inline-name, $progress-inline-width) {
progress.#{$progress-inline-name} {
display: inline-block;
vertical-align: middle; // Align progress bar vertically to look better with text next to it.
@if $progress-inline-width != 100% {
width: $progress-inline-width;
}
}
}
// Mixin for alternate progress (progress color variants).
// Variables:
// - $progress-alt-name : The name of the class used for the alternate progress.
// - $progress-alt-fore-color : The progress bar color of the alternate progress.
// - $progress-alt-back-color : (Optional) The background color of the alternate progress. Defaults to the background color of the progress.
@mixin make-progress-alt-color ($progress-alt-name, $progress-alt-fore-color, $progress-alt-back-color: $progress-back-color) {
progress.#{$progress-alt-name} {
@if $progress-alt-back-color != $progress-back-color {
background: $progress-alt-back-color; // Background color of the element (IE 10+ and Firefox).
&::-webkit-progress-bar { // Background of the element (webkit browsers).
background: $progress-alt-back-color;
}
}
@if $progress-alt-fore-color != $progress-fore-color {
color: $progress-alt-fore-color; // Foreground of the element (IE 10+).
&::-webkit-progress-value { // Foreground of the element (webkit browsers).
background: $progress-alt-fore-color;
}
&::-moz-progress-bar { // Foreground of the element (Firefox).
background: $progress-alt-fore-color;
}
}
}
}
// Mixin for alternate progress styles.
// Variables:
// - $progress-alt-name : The name of the class used for the alternate progress style.
// - $progress-alt-height : The height of the alternate progress style.
// - $progress-alt-top-bottom-margin : (Optional) The top and bottom margin of the alternate progress style. Defaults to the margin of the progress.
// - $progress-alt-left-right-margin : (Optional) The left and right margin of the alternate progress style. Defaults to the margin of the progress.
// - $progress-alt-border-style : (Optional) The border style of the alternate progress style. Defaults to the border style of the progress.
// - $progress-alt-border-radius : (Optional) The border radius of the alternate progress style. Defaults to the border radius of the progress.
// - $progress-alt-box-shadow : (Optional) The box shadow of the alternate progress style. Defaults to the box shadow of the progress.
@mixin make-progress-alt-style ($progress-alt-name, $progress-alt-height,
$progress-alt-top-bottom-margin : $progress-top-bottom-margin, $progress-alt-left-right-margin : $progress-left-right-margin,
$progress-alt-border-style : $progress-border-style, $progress-alt-border-radius : $progress-border-radius,
$progress-alt-box-shadow : $progress-box-shadow) {
progress.#{$progress-alt-name} {
@if $progress-alt-height != $progress-height {
height: $progress-alt-height;
}
@if $progress-alt-left-right-margin != $progress-left-right-margin {
width: calc(100% - #{$progress-alt-left-right-margin*2});
}
@if $progress-alt-left-right-margin != $progress-left-right-margin or $progress-alt-top-bottom-margin != $progress-top-bottom-margin {
margin: $progress-alt-top-bottom-margin $progress-alt-left-right-margin;
}
@if $progress-alt-top-bottom-margin != $progress-top-bottom-margin {
margin: $progress-alt-top-bottom-margin auto;
}
@if $progress-alt-border-style != $progress-border-style {
border: $progress-alt-border-style;
}
@if progress-alt-border-radius != $progress-border-radius {
border-radius: $progress-alt-border-radius;
&::-webkit-progress-value {
border-top-left-radius: $progress-alt-border-radius;
border-bottom-left-radius: $progress-alt-border-radius;
}
&::-moz-progress-bar {
border-top-left-radius: $progress-alt-border-radius;
border-bottom-left-radius: $progress-alt-border-radius;
}
&[value="#{$progress-max-value}"] {
&::-webkit-progress-value {
border-radius: $progress-alt-border-radius;
}
&::-moz-progress-bar {
border-radius: $progress-alt-border-radius;
}
}
}
@if $progress-alt-box-shadow != $progress-box-shadow {
box-shadow: $progress-alt-box-shadow;
}
}
}
// Mixin for alternate donut spinner colors (spinner donut color variants).
// Variables:
// - $spinner-donut-alt-name : The name of the class used for the alternate donut spinner.
// - $spinner-donut-alt-back-color : The background color of the alternate donut spinner.
// - $spinner-donut-alt-fore-color : The foreground color of the alternate donut spinner.
@mixin make-spinner-donut-alt-color ($spinner-donut-alt-name, $spinner-donut-alt-back-color, $spinner-donut-alt-fore-color) {
@if not ($include-spinner-donut) {
@error "Progress module's spinner donut mixins are only available if spinner donuts are enabled. Set '$include-spinner-donut' to 'true' and try again!";
}
.#{$spinner-donut-name}.#{$spinner-donut-alt-name} {
border: $spinner-donut-border-thickness solid $spinner-donut-alt-back-color;
border-left: $spinner-donut-border-thickness solid $spinner-donut-alt-fore-color;
}
}
// Mixin for alternate donut spinner styles (spinner donut styles variants).
// Variables:
// - $spinner-donut-alt-name : The name of the class used for the alternate donut spinner style.
// - $spinner-donut-alt-size : The size of the alternate donut spinner style.
// - $spinner-donut-alt-border-thickness : (Optional) The border thickness of the alternate donut spinner style.
// Defaults to the value of $spinner-donut-alt-border-thickness.
@mixin make-spinner-donut-alt-style ($spinner-donut-alt-name, $spinner-donut-alt-size,
$spinner-donut-alt-border-thickness : $spinner-donut-border-thickness) {
@if not ($include-spinner-donut) {
@error "Progress module's spinner donut mixins are only available if spinner donuts are enabled. Set '$include-spinner-donut' to 'true' and try again!";
}
.#{$spinner-donut-name}.#{$spinner-donut-alt-name} {
@if $spinner-donut-alt-border-thickness != $spinner-donut-border-thickness {
border-width: $spinner-donut-alt-border-thickness;
}
@if $spinner-donut-alt-size != $spinner-donut-size {
width: $spinner-donut-alt-size;
height: $spinner-donut-alt-size;
}
}
}

View file

@ -1,261 +1,261 @@
/*
Definitions for tabs/horizontal accordions.
*/
// Dependency: This module is somewhat dependent on the grid system.
$tab-container-name: 'tabs' !default; // Class name for the tabs container.
$include-stacked-tabs: true !default; // [Hidden flag] Should stacked tabs be included? (`true`/`false`).
$tab-stacked-name: 'stacked' !default; // Class name for stacked tabs container.
$tab-stacked-breakpoint: 767px !default; // Breakpoint for tabs layout (stacked/horizontal)
// External variables' defaults are used only if you import this module on its own, without the rest of the framework.
$back-color: white !default; // [External variable - core] Background color for everything.
$fore-color: black !default; // [External variable - core] Foreground color for everything.
// Tab styling
.#{$tab-container-name} {
width: 100%;
opacity: 1;
// Old syntax
display: -webkit-box;
-webkit-box-pack: justify;
// New syntax
display: -webkit-flex;
display: flex;
-webkit-justify-content: space-between;
justify-content: space-between;
-webkit-flex-wrap: wrap;
flex-wrap: wrap;
@if $tab-container-box-shadow != none {
box-shadow: $tab-container-box-shadow;
}
// Tab label styling
& > label {
// Old syntax
-webkit-box-flex: 1;
// New syntax
-webkit-flex-grow: 1;
flex-grow: 1;
// Make tab labels stay at the top on large displays
-webkit-order: 1;
order: 1;
// Actual styling
display: inline-block;
height: $tab-label-height;
cursor: pointer;
transition: background 0.3s;
@if $tab-label-back-color != $back-color {
background: $tab-label-back-color;
}
@if $tab-label-fore-color != $fore-color {
color: $tab-label-fore-color;
}
@if $tab-border-style != 0 {
border: $tab-border-style;
}
@if $tab-label-padding != 0 {
padding: $tab-label-padding;
}
@if $tab-border-radius != 0 { // Style first and last tabs' labels' top corners as needed
&:first-of-type {
border-top-left-radius: $tab-border-radius;
}
&:last-of-type {
border-top-right-radius: $tab-border-radius;
}
}
// Hover styling for tabs' labels
&:hover, &:focus {
background: rgba($tab-label-back-color, $tab-label-hover-opacity);
}
}
// Tab radio styling
& > [type="radio"], & > [type="checkbox"] {
display: none;
visibility: hidden;
}
// Tab content styling
& > label + div {
// New syntax
-webkit-flex-basis: auto;
flex-basis: auto;
// Make tab panels display after all the labels on larger displays
-webkit-order: 2;
order: 2;
// Hide content, while allowing accessibility
height: 1px;
width: 1px;
margin: -1px;
overflow: hidden;
position: absolute;
clip: rect(0 0 0 0);
-webkit-clip-path: inset(100%);
clip-path: inset(100%);
// Presentation
-webkit-transform: scaleY(0);
transform: scaleY(0);
-webkit-transform-origin: top;
transform-origin: top;
transition: -webkit-transform 0.3s,
transform 0.3s;
@if $tab-border-radius != 0 {
border-bottom-left-radius: $tab-border-radius;
border-bottom-right-radius: $tab-border-radius;
}
}
// Style for tab labels except the first
@if $tab-border-style != 0 {
& > label:not(:first-of-type) {
border-left: 0;
}
}
// Tab label styling for open tab
& > :checked + label {
@if $tab-label-selected-back-color != $tab-label-back-color {
background: $tab-label-selected-back-color;
&:hover, &:focus {
background: rgba($tab-label-selected-back-color, $tab-label-hover-opacity);
}
}
@if $tab-label-selected-fore-color != $tab-label-fore-color {
color: $tab-label-selected-fore-color;
}
border-bottom-color: $tab-selected-border-color;
}
// Tab content styling (open tab)
& > :checked + label + div {
box-sizing: border-box;
position: relative;
height: $tab-panel-height;
width: 100%;
overflow: auto;
margin: 0;
-webkit-transform: scaleY(1);
transform: scaleY(1);
@if $tab-panel-back-color != $back-color {
background: $tab-panel-back-color;
}
@if $tab-panel-fore-color != $fore-color {
color: $tab-panel-fore-color;
}
@if $tab-border-style != 0 {
border: $tab-border-style;
border-top: 0;
}
@if $tab-panel-padding != 0 {
padding: $tab-panel-padding;
}
// Fix display for some browsers
clip: auto;
-webkit-clip-path: inset(0%);
clip-path: inset(0%);
}
}
// Stacked tabs
@if $include-stacked-tabs { // Turn off if you don't want stacked tabs enabled (except on smaller screens for responsiveness)
.#{$tab-container-name}.#{$tab-stacked-name} {
// Old syntax
-webkit-box-orient: vertical;
// New syntax
-webkit-flex-direction: column;
flex-direction: column;
& > label {
-webkit-order: initial; // Reset order to show stacked tabs properly
order: initial;
@if $tab-border-radius != 0 { // Style first and last tabs' labels' corners as needed
&:last-of-type {
border-top-right-radius: 0;
border-bottom-left-radius: $tab-border-radius;
border-bottom-right-radius: $tab-border-radius;
}
// Keep :first-of-type below :last-of-type to make sure that single collapses get proper radiuses
&:first-of-type {
border-top-right-radius: $tab-border-radius;
}
}
}
& > :checked + label {
@if $tab-border-style != 0 {
border: $tab-border-style;
}
@if $tab-border-radius != 0 {
border-bottom-left-radius: 0;
border-bottom-right-radius: 0;
}
}
& > label + div {
-webkit-order: initial; // Reset order to show stacked tabs properly
order: initial;
// Presentation
-webkit-transform-origin: top;
transform-origin: top;
@if $tab-border-radius != 0 {
border-radius: 0;
}
}
& > label:not(:first-of-type) {
@if $tab-border-style != 0 {
border: $tab-border-style;
border-top: 0;
}
}
& > :checked + label + div {
height: auto;
}
@if $tab-border-radius != 0 {
& > label + div:last-of-type {
border-bottom-left-radius: $tab-border-radius;
border-bottom-right-radius: $tab-border-radius;
}
}
}
}
// Responsiveness
@media screen and (max-width: #{$tab-stacked-breakpoint}) {
.#{$tab-container-name} {
// Old syntax
-webkit-box-orient: vertical;
// New syntax
-webkit-flex-direction: column;
flex-direction: column;
& > label {
-webkit-order: initial; // Reset order to show stacked tabs properly
order: initial;
@if $tab-border-radius != 0 { // Style first and last tabs' labels' corners as needed
&:first-of-type {
border-top-right-radius: $tab-border-radius;
}
&:last-of-type {
border-top-right-radius: 0;
border-bottom-left-radius: $tab-border-radius;
border-bottom-right-radius: $tab-border-radius;
}
}
}
& > :checked + label {
@if $tab-border-style != 0 {
border: $tab-border-style;
}
@if $tab-border-radius != 0 {
border-bottom-left-radius: 0;
border-bottom-right-radius: 0;
}
}
& > label + div {
-webkit-order: initial; // Reset order to show stacked tabs properly
order: initial;
@if $tab-border-radius != 0 {
border-radius: 0;
}
}
& > label:not(:first-of-type) {
@if $tab-border-style != 0 {
border: $tab-border-style;
border-top: 0;
}
}
@if $tab-border-radius != 0 {
& > label + div:last-of-type {
border-bottom-left-radius: $tab-border-radius;
border-bottom-right-radius: $tab-border-radius;
}
}
}
}
/*
Definitions for tabs/horizontal accordions.
*/
// Dependency: This module is somewhat dependent on the grid system.
$tab-container-name: 'tabs' !default; // Class name for the tabs container.
$include-stacked-tabs: true !default; // [Hidden flag] Should stacked tabs be included? (`true`/`false`).
$tab-stacked-name: 'stacked' !default; // Class name for stacked tabs container.
$tab-stacked-breakpoint: 767px !default; // Breakpoint for tabs layout (stacked/horizontal)
// External variables' defaults are used only if you import this module on its own, without the rest of the framework.
$back-color: white !default; // [External variable - core] Background color for everything.
$fore-color: black !default; // [External variable - core] Foreground color for everything.
// Tab styling
.#{$tab-container-name} {
width: 100%;
opacity: 1;
// Old syntax
display: -webkit-box;
-webkit-box-pack: justify;
// New syntax
display: -webkit-flex;
display: flex;
-webkit-justify-content: space-between;
justify-content: space-between;
-webkit-flex-wrap: wrap;
flex-wrap: wrap;
@if $tab-container-box-shadow != none {
box-shadow: $tab-container-box-shadow;
}
// Tab label styling
& > label {
// Old syntax
-webkit-box-flex: 1;
// New syntax
-webkit-flex-grow: 1;
flex-grow: 1;
// Make tab labels stay at the top on large displays
-webkit-order: 1;
order: 1;
// Actual styling
display: inline-block;
height: $tab-label-height;
cursor: pointer;
transition: background 0.3s;
@if $tab-label-back-color != $back-color {
background: $tab-label-back-color;
}
@if $tab-label-fore-color != $fore-color {
color: $tab-label-fore-color;
}
@if $tab-border-style != 0 {
border: $tab-border-style;
}
@if $tab-label-padding != 0 {
padding: $tab-label-padding;
}
@if $tab-border-radius != 0 { // Style first and last tabs' labels' top corners as needed
&:first-of-type {
border-top-left-radius: $tab-border-radius;
}
&:last-of-type {
border-top-right-radius: $tab-border-radius;
}
}
// Hover styling for tabs' labels
&:hover, &:focus {
background: rgba($tab-label-back-color, $tab-label-hover-opacity);
}
}
// Tab radio styling
& > [type="radio"], & > [type="checkbox"] {
display: none;
visibility: hidden;
}
// Tab content styling
& > label + div {
// New syntax
-webkit-flex-basis: auto;
flex-basis: auto;
// Make tab panels display after all the labels on larger displays
-webkit-order: 2;
order: 2;
// Hide content, while allowing accessibility
height: 1px;
width: 1px;
margin: -1px;
overflow: hidden;
position: absolute;
clip: rect(0 0 0 0);
-webkit-clip-path: inset(100%);
clip-path: inset(100%);
// Presentation
-webkit-transform: scaleY(0);
transform: scaleY(0);
-webkit-transform-origin: top;
transform-origin: top;
transition: -webkit-transform 0.3s,
transform 0.3s;
@if $tab-border-radius != 0 {
border-bottom-left-radius: $tab-border-radius;
border-bottom-right-radius: $tab-border-radius;
}
}
// Style for tab labels except the first
@if $tab-border-style != 0 {
& > label:not(:first-of-type) {
border-left: 0;
}
}
// Tab label styling for open tab
& > :checked + label {
@if $tab-label-selected-back-color != $tab-label-back-color {
background: $tab-label-selected-back-color;
&:hover, &:focus {
background: rgba($tab-label-selected-back-color, $tab-label-hover-opacity);
}
}
@if $tab-label-selected-fore-color != $tab-label-fore-color {
color: $tab-label-selected-fore-color;
}
border-bottom-color: $tab-selected-border-color;
}
// Tab content styling (open tab)
& > :checked + label + div {
box-sizing: border-box;
position: relative;
height: $tab-panel-height;
width: 100%;
overflow: auto;
margin: 0;
-webkit-transform: scaleY(1);
transform: scaleY(1);
@if $tab-panel-back-color != $back-color {
background: $tab-panel-back-color;
}
@if $tab-panel-fore-color != $fore-color {
color: $tab-panel-fore-color;
}
@if $tab-border-style != 0 {
border: $tab-border-style;
border-top: 0;
}
@if $tab-panel-padding != 0 {
padding: $tab-panel-padding;
}
// Fix display for some browsers
clip: auto;
-webkit-clip-path: inset(0%);
clip-path: inset(0%);
}
}
// Stacked tabs
@if $include-stacked-tabs { // Turn off if you don't want stacked tabs enabled (except on smaller screens for responsiveness)
.#{$tab-container-name}.#{$tab-stacked-name} {
// Old syntax
-webkit-box-orient: vertical;
// New syntax
-webkit-flex-direction: column;
flex-direction: column;
& > label {
-webkit-order: initial; // Reset order to show stacked tabs properly
order: initial;
@if $tab-border-radius != 0 { // Style first and last tabs' labels' corners as needed
&:last-of-type {
border-top-right-radius: 0;
border-bottom-left-radius: $tab-border-radius;
border-bottom-right-radius: $tab-border-radius;
}
// Keep :first-of-type below :last-of-type to make sure that single collapses get proper radiuses
&:first-of-type {
border-top-right-radius: $tab-border-radius;
}
}
}
& > :checked + label {
@if $tab-border-style != 0 {
border: $tab-border-style;
}
@if $tab-border-radius != 0 {
border-bottom-left-radius: 0;
border-bottom-right-radius: 0;
}
}
& > label + div {
-webkit-order: initial; // Reset order to show stacked tabs properly
order: initial;
// Presentation
-webkit-transform-origin: top;
transform-origin: top;
@if $tab-border-radius != 0 {
border-radius: 0;
}
}
& > label:not(:first-of-type) {
@if $tab-border-style != 0 {
border: $tab-border-style;
border-top: 0;
}
}
& > :checked + label + div {
height: auto;
}
@if $tab-border-radius != 0 {
& > label + div:last-of-type {
border-bottom-left-radius: $tab-border-radius;
border-bottom-right-radius: $tab-border-radius;
}
}
}
}
// Responsiveness
@media screen and (max-width: #{$tab-stacked-breakpoint}) {
.#{$tab-container-name} {
// Old syntax
-webkit-box-orient: vertical;
// New syntax
-webkit-flex-direction: column;
flex-direction: column;
& > label {
-webkit-order: initial; // Reset order to show stacked tabs properly
order: initial;
@if $tab-border-radius != 0 { // Style first and last tabs' labels' corners as needed
&:first-of-type {
border-top-right-radius: $tab-border-radius;
}
&:last-of-type {
border-top-right-radius: 0;
border-bottom-left-radius: $tab-border-radius;
border-bottom-right-radius: $tab-border-radius;
}
}
}
& > :checked + label {
@if $tab-border-style != 0 {
border: $tab-border-style;
}
@if $tab-border-radius != 0 {
border-bottom-left-radius: 0;
border-bottom-right-radius: 0;
}
}
& > label + div {
-webkit-order: initial; // Reset order to show stacked tabs properly
order: initial;
@if $tab-border-radius != 0 {
border-radius: 0;
}
}
& > label:not(:first-of-type) {
@if $tab-border-style != 0 {
border: $tab-border-style;
border-top: 0;
}
}
@if $tab-border-radius != 0 {
& > label + div:last-of-type {
border-bottom-left-radius: $tab-border-radius;
border-bottom-right-radius: $tab-border-radius;
}
}
}
}

File diff suppressed because it is too large Load diff

View file

@ -1,167 +1,167 @@
/*
Definitions for utilities and helper classes.
*/
$hidden-name: 'hidden' !default; // Class name for hidden elements.
$visually-hidden-name: 'visually-hidden' !default; // Class name for visually hidden elements.
$include-breadcrumbs: true !default; // [Hidden flag] Should breadcrumbs be included? (`true`/`false`)
$breadcrumbs-name: 'breadcrumbs' !default; // Class name for breadcrumbs.
$include-close-icon: true !default; // [Hidden flag] Should the close icon be included? (`true`/`false`)
$close-icon-name: 'close'!default; // Class name for close icon.
// The floats, clearfix and center-block flags are for legacy features.
$include-floats: false !default; // Should floats be included? (`true`/`false`)
$include-clearfix: false !default; // Should clearfix be included? (`true`/`false`)
$include-center-block: false !default; // Should center block be included? (`true`/`false`)
$style-link-active-state: false !default; // [External flag - core] Should the :active state of <a> elements be stylized, same as the :hover state (`true`/`false`).
// Check the `_utility_mixins.scss` file to find this module's mixins.
@import 'utility_mixins';
// Hidden elements class. ATTENTION: Uses !important.
.#{$hidden-name}{
display: none !important;
}
// Visually hidden elements class. ATTENTION: Uses !important.
.#{$visually-hidden-name} {
position: absolute !important;
width: 1px !important;
height: 1px !important;
margin: -1px !important;
border: 0 !important;
padding: 0 !important;
clip: rect(0 0 0 0) !important;
-webkit-clip-path: inset(100%) !important;
clip-path: inset(100%) !important;
overflow: hidden !important;
}
@if $include-breadcrumbs { // Turn off if you do not want breadcrumbs to be included.
// Breadcrumbs
ul.#{$breadcrumbs-name} {
// Old syntax
display: -webkit-box;
// New syntax
display: -webkit-flex;
display: flex;
list-style: none;
// Apply margin from styling
@if $breadcrumbs-margin != 0 {
margin: $breadcrumbs-margin;
}
@else { // Reset margins from list styling
margin-left: 0;
margin-right: 0;
}
padding: 0; // Remove unnecessary left and right empty space
@if $breadcrumbs-border-style !=0 {
border: $breadcrumbs-border-style;
}
@if $breadcrumbs-border-radius != 0 {
border-radius: $breadcrumbs-border-radius;
}
@if $breadcrumbs-box-shadow != none {
box-shadow: $breadcrumbs-box-shadow;
}
li {
// Old syntax
-webkit-box-flex: 1;
max-width: 100%;
// New syntax
-webkit-flex-grow: 1;
flex-grow: 1;
-webkit-flex-basis: 0;
flex-basis: 0;
position: relative;
text-align: center;
background: $breadcrumbs-back-color;
height: $breadcrumbs-height;
line-height: $breadcrumbs-height;
margin-right: ($breadcrumbs-height/2) + $breadcrumbs-separator-width;
&:before, &:after {
content: "";
position: absolute;
top: 0;
width: 0;
height: 0;
border: 0 solid $breadcrumbs-back-color;
border-width: ($breadcrumbs-height/2) ceil($breadcrumbs-height/4);
}
&:before {
left: -($breadcrumbs-height/2);
border-left-color: transparent;
}
&:after {
left: 100%;
border-color: transparent;
border-left-color: $breadcrumbs-back-color;
}
&:first-child {
&:before {
border: 0;
}
}
&:last-child {
margin-right: 0;
&:after {
border: 0;
}
}
}
}
}
@if $include-close-icon { // Turn off if you do not want to include the close icon
// Close icon
.#{$close-icon-name}{
display: inline-block;
width: $close-icon-size;
font-family: sans-serif;
font-size: $close-icon-size;
line-height: 1;
font-weight: 700;
border-radius: 2rem;
background: rgba($close-icon-back-color,0);
vertical-align: top;
cursor: pointer;
transition: background 0.3s;
@if $style-link-active-state {
&:hover, &:focus, &:active {
background: rgba($close-icon-back-color,1);
}
}
@else {
&:hover, &:focus {
background: rgba($close-icon-back-color,1);
}
}
&:before {
content: "\00D7";
display: block;
text-align: center;
}
}
}
// Floats. ATTENTION: Uses !important.
// NOTE: Might be obsolete and not play well with others.
@if $include-floats {
.#{$float-prefix}-left {
float: left !important;
}
.#{$float-prefix}-right {
float: right !important;
}
}
// Clearfix mixin. ATTENTION: Uses !important.
// NOTE: Might be obsolete and not play well with others.
@if $include-clearfix {
.#{$clearfix-name} {
&:before, &:after {
content: ' ' !important;
display: table !important;
clear: both !important;
}
}
}
// Center block. ATTENTION: Uses !important.
@if $include-center-block {
.#{$center-block-name} {
display: block !important;
margin-left: auto !important;
margin-right: auto !important;
}
}
/*
Definitions for utilities and helper classes.
*/
$hidden-name: 'hidden' !default; // Class name for hidden elements.
$visually-hidden-name: 'visually-hidden' !default; // Class name for visually hidden elements.
$include-breadcrumbs: true !default; // [Hidden flag] Should breadcrumbs be included? (`true`/`false`)
$breadcrumbs-name: 'breadcrumbs' !default; // Class name for breadcrumbs.
$include-close-icon: true !default; // [Hidden flag] Should the close icon be included? (`true`/`false`)
$close-icon-name: 'close'!default; // Class name for close icon.
// The floats, clearfix and center-block flags are for legacy features.
$include-floats: false !default; // Should floats be included? (`true`/`false`)
$include-clearfix: false !default; // Should clearfix be included? (`true`/`false`)
$include-center-block: false !default; // Should center block be included? (`true`/`false`)
$style-link-active-state: false !default; // [External flag - core] Should the :active state of <a> elements be stylized, same as the :hover state (`true`/`false`).
// Check the `_utility_mixins.scss` file to find this module's mixins.
@import 'utility_mixins';
// Hidden elements class. ATTENTION: Uses !important.
.#{$hidden-name}{
display: none !important;
}
// Visually hidden elements class. ATTENTION: Uses !important.
.#{$visually-hidden-name} {
position: absolute !important;
width: 1px !important;
height: 1px !important;
margin: -1px !important;
border: 0 !important;
padding: 0 !important;
clip: rect(0 0 0 0) !important;
-webkit-clip-path: inset(100%) !important;
clip-path: inset(100%) !important;
overflow: hidden !important;
}
@if $include-breadcrumbs { // Turn off if you do not want breadcrumbs to be included.
// Breadcrumbs
ul.#{$breadcrumbs-name} {
// Old syntax
display: -webkit-box;
// New syntax
display: -webkit-flex;
display: flex;
list-style: none;
// Apply margin from styling
@if $breadcrumbs-margin != 0 {
margin: $breadcrumbs-margin;
}
@else { // Reset margins from list styling
margin-left: 0;
margin-right: 0;
}
padding: 0; // Remove unnecessary left and right empty space
@if $breadcrumbs-border-style !=0 {
border: $breadcrumbs-border-style;
}
@if $breadcrumbs-border-radius != 0 {
border-radius: $breadcrumbs-border-radius;
}
@if $breadcrumbs-box-shadow != none {
box-shadow: $breadcrumbs-box-shadow;
}
li {
// Old syntax
-webkit-box-flex: 1;
max-width: 100%;
// New syntax
-webkit-flex-grow: 1;
flex-grow: 1;
-webkit-flex-basis: 0;
flex-basis: 0;
position: relative;
text-align: center;
background: $breadcrumbs-back-color;
height: $breadcrumbs-height;
line-height: $breadcrumbs-height;
margin-right: ($breadcrumbs-height/2) + $breadcrumbs-separator-width;
&:before, &:after {
content: "";
position: absolute;
top: 0;
width: 0;
height: 0;
border: 0 solid $breadcrumbs-back-color;
border-width: ($breadcrumbs-height/2) ceil($breadcrumbs-height/4);
}
&:before {
left: -($breadcrumbs-height/2);
border-left-color: transparent;
}
&:after {
left: 100%;
border-color: transparent;
border-left-color: $breadcrumbs-back-color;
}
&:first-child {
&:before {
border: 0;
}
}
&:last-child {
margin-right: 0;
&:after {
border: 0;
}
}
}
}
}
@if $include-close-icon { // Turn off if you do not want to include the close icon
// Close icon
.#{$close-icon-name}{
display: inline-block;
width: $close-icon-size;
font-family: sans-serif;
font-size: $close-icon-size;
line-height: 1;
font-weight: 700;
border-radius: 2rem;
background: rgba($close-icon-back-color,0);
vertical-align: top;
cursor: pointer;
transition: background 0.3s;
@if $style-link-active-state {
&:hover, &:focus, &:active {
background: rgba($close-icon-back-color,1);
}
}
@else {
&:hover, &:focus {
background: rgba($close-icon-back-color,1);
}
}
&:before {
content: "\00D7";
display: block;
text-align: center;
}
}
}
// Floats. ATTENTION: Uses !important.
// NOTE: Might be obsolete and not play well with others.
@if $include-floats {
.#{$float-prefix}-left {
float: left !important;
}
.#{$float-prefix}-right {
float: right !important;
}
}
// Clearfix mixin. ATTENTION: Uses !important.
// NOTE: Might be obsolete and not play well with others.
@if $include-clearfix {
.#{$clearfix-name} {
&:before, &:after {
content: ' ' !important;
display: table !important;
clear: both !important;
}
}
}
// Center block. ATTENTION: Uses !important.
@if $include-center-block {
.#{$center-block-name} {
display: block !important;
margin-left: auto !important;
margin-right: auto !important;
}
}

View file

@ -1,241 +1,241 @@
// Utility module's mixin definitions are here. For the module itself
// check `_utility.scss`.
// Generic border mixin. ATTENTION: Uses !important.
// Variables:
// - $border-generic-name : The name of the class used for the generic border.
@mixin make-border-generic ($border-generic-name) {
.#{$border-generic-name} {
border: 1px solid rgba(0,0,0, 0.25) !important;
}
}
// Generic radial border mixin. ATTENTION: Uses !important.
// Variables:
// - $border-radial-name : The name of the class used for the radial border.
// - $border-radial-radius : The border radius used for the radial border.
@mixin make-border-radial-style ($border-radial-name, $border-radial-radius) {
.#{$border-radial-name} {
border-radius: $border-radial-radius !important;
}
}
// Generic box shadow mixin. ATTENTION: Uses !important.
// Variables:
// - $box-shadow-name : The name of the class used for the generic box shadow.
// - $box-shadow-value : The box shadow value of the generic box shadow.
@mixin make-box-shadow-generic ($box-shadow-name, $box-shadow-value) {
.#{$box-shadow-name} {
box-shadow: $box-shadow-value !important;
}
}
// Responsive margin mixin. ATTENTION: Uses !important.
// Variables:
// - $margin-name : The name of the class used for the responsive margin.
// - $margin-small-value : Responsive margin value for smaller screens.
// - $margin-medium-value : Responsive margin value for medium screens.
// - $margin-large-value : Responsive margin value for large screens.
// - $margin-medium-breakpoint : (Optional) Medium screen breakpoint for the responsive margin. Defaults to `768px`.
// - $margin-large-breakpoint : (Optional) Large screen breakpoint for the responsive margin. Defaults to `1280px`.
// - $margin-use-four-step-grid : (Optional) Should the legacy four-step grid be used? Defaults to `false`.
// - $margin-small-breakpoint : (Optional) Small screen breakpoint for the responsive margin, used only if above flag is set to `true`. Defaults to `480px`.
// - $margin-extra-small-value : (Optional) Responsive margin value for extra small screens, used only if above flag is set to `true`. Defaults to `0`.
@mixin make-margin-responsive ($margin-name, $margin-small-value,
$margin-medium-value, $margin-large-value, $margin-medium-breakpoint : 768px,
$margin-large-breakpoint : 1280px, $margin-use-four-step-grid : false,
$margin-small-breakpoint : 480px, $margin-extra-small-value : 0) {
@if $margin-use-four-step-grid {
.#{$margin-name} {
margin: $margin-extra-small-value !important;
}
@media screen and (min-width: #{$margin-small-breakpoint}) {
margin: $margin-small-value !important;
}
}
@else {
.#{$margin-name} {
margin: $margin-small-value !important;
}
}
@media screen and (min-width: #{$margin-medium-breakpoint}) {
.#{$margin-name} {
margin: $margin-medium-value !important;
}
}
@media screen and (min-width: #{$margin-large-breakpoint}) {
.#{$margin-name} {
margin: $margin-large-value !important;
}
}
}
// Responsive padding mixin. ATTENTION: Uses !important.
// Variables:
// - $padding-name : The name of the class used for the responsive padding.
// - $padding-small-value : Responsive padding value for smaller screens.
// - $padding-medium-value : Responsive padding value for medium screens.
// - $padding-large-value : Responsive padding value for large screens.
// - $padding-medium-breakpoint : (Optional) Medium screen breakpoint for the responsive padding. Defaults to `768px`.
// - $padding-large-breakpoint : (Optional) Large screen breakpoint for the responsive padding. Defaults to `1280px`.
// - $padding-use-four-step-grid : (Optional) Should the legacy four-step grid be used? Defaults to `false`.
// - $padding-small-breakpoint : (Optional) Small screen breakpoint for the responsive padding, used only if above flag is set to `true`. Defaults to `480px`.
// - $padding-extra-small-value : (Optional) Responsive padding value for extra small screens, used only if above flag is set to `true`. Defaults to `0`.
@mixin make-padding-responsive ($padding-name, $padding-small-value,
$padding-medium-value, $padding-large-value, $padding-medium-breakpoint : 768px,
$padding-large-breakpoint : 1280px, $padding-use-four-step-grid : false,
$padding-small-breakpoint : 480px, $padding-extra-small-value : 0) {
@if $padding-use-four-step-grid{
.#{$padding-name} {
padding: $padding-extra-small-value !important;
}
@media screen and (min-width: #{$padding-small-breakpoint}) {
padding: $padding-small-value !important;
}
}
@else {
.#{$padding-name} {
padding: $padding-small-value !important;
}
}
@media screen and (min-width: #{$padding-medium-breakpoint}) {
.#{$padding-name} {
padding: $padding-medium-value !important;
}
}
@media screen and (min-width: #{$padding-large-breakpoint}) {
.#{$padding-name} {
padding: $padding-large-value !important;
}
}
}
// Responsive hidden elements mixin. ATTENTION: Uses !important.
// Variables:
// - $hidden-prefix : The prefix for the name of the class used for the responsive hiding.
// - $hidden-medium-breakpoint : (Optional) Medium screen breakpoint for the responsive hiding. Defaults to `768px`.
// - $hidden-large-breakpoint : (Optional) Large screen breakpoint for the responsive hiding. Defaults to `1280px`.
// - $hidden-small-suffix : (Optional) The small-screen suffix for the name of the class used for the responsive hiding. Defaults to 'sm'.
// - $hidden-medium-suffix : (Optional) The medium-screen suffix for the name of the class used for the responsive hiding. Defaults to 'md'.
// - $hidden-large-suffix : (Optional) The large-screen suffix for the name of the class used for the responsive hiding. Defaults to 'lg'.
// - $hidden-use-four-step-grid : (Optional) Should the legacy four-step grid be used? Defaults to `false`.
// - $hidden-small-breakpoint : (Optional) Small screen breakpoint for the responsive hiding, used only if the above variable is set to `true`. Defaults to `480px`.
// - $hidden-extra-small-suffix : (Optional) The extra-small-screen suffix for the name of the class used for the responsive hiding. Used only if the above flag is set to `true`. Defaults to 'xs'.
@mixin make-hidden-responsive ($hidden-prefix, $hidden-medium-breakpoint : 768px,
$hidden-large-breakpoint : 1280px , $hidden-small-suffix : 'sm', $hidden-medium-suffix : 'md',
$hidden-large-suffix : 'lg', $hidden-use-four-step-grid : false,
$hidden-small-breakpoint : 480px, $hidden-extra-small-suffix : 'xs') {
@if $hidden-use-four-step-grid {
@media screen and (max-width: #{$hidden-small-breakpoint}-1px) {
.#{$hidden-prefix}-#{$hidden-extra-small-suffix} {
display: none !important;
}
}
@media screen and (min-width: #{$hidden-small-breakpoint}) and (max-width: #{$hidden-medium-breakpoint}-1px) {
.#{$hidden-prefix}-#{$hidden-small-suffix} {
display: none !important;
}
}
}
@else {
@media screen and (max-width: #{$hidden-medium-breakpoint}-1px) {
.#{$hidden-prefix}-#{$hidden-small-suffix} {
display: none !important;
}
}
@media screen and (min-width: #{$hidden-medium-breakpoint}) and (max-width: #{$hidden-large-breakpoint}-1px) {
.#{$hidden-prefix}-#{$hidden-medium-suffix} {
display: none !important;
}
}
@media screen and (min-width: #{$hidden-large-breakpoint}) {
.#{$hidden-prefix}-#{$hidden-large-suffix} {
display: none !important;
}
}
}
}
// Responsive visually hidden elements mixin. ATTENTION: Uses !important.
// Variables:
// - $visually-hidden-prefix : The prefix for the name of the class used for the responsive visual hiding.
// - $visually-hidden-medium-breakpoint : (Optional) Medium screen breakpoint for the responsive visual hiding. Defaults to `768px`.
// - $visually-hidden-large-breakpoint : (Optional) Large screen breakpoint for the responsive visual hiding. Defaults to `1280px`.
// - $visually-hidden-small-suffix : (Optional) The small-screen suffix for the name of the class used for the responsive visual hiding. Defaults to 'sm'.
// - $visually-hidden-medium-suffix : (Optional) The medium-screen suffix for the name of the class used for the responsive visual hiding. Defaults to 'md'.
// - $visually-hidden-large-suffix : (Optional) The large-screen suffix for the name of the class used for the responsive visual hiding. Defaults to 'lg'.
// - $visually-hidden-use-four-step-grid : (Optional) Should the legacy four-step grid be used? Defaults to `false`.
// - $visually-hidden-small-breakpoint : (Optional) Small screen breakpoint for the responsive visual hiding, used only if the above variable is set to `true`. Defaults to `480px`.
// - $visually-hidden-extra-small-suffix : (Optional) The extra-small-screen suffix for the name of the class used for the responsive visual hiding. Used only if the above flag is set to `true`. Defaults to 'xs'.
@mixin make-visually-hidden-responsive ($visually-hidden-prefix, $visually-hidden-medium-breakpoint : 768px,
$visually-hidden-large-breakpoint : 1280px , $visually-hidden-small-suffix : 'sm', $visually-hidden-medium-suffix : 'md',
$visually-hidden-large-suffix : 'lg', $visually-hidden-use-four-step-grid : false,
$visually-hidden-small-breakpoint : 480px, $visually-hidden-extra-small-suffix : 'xs') {
@if $visually-hidden-use-four-step-grid {
@media screen and (max-width: #{$visually-hidden-small-breakpoint}-1px) {
.#{$visually-hidden-prefix}-#{$visually-hidden-extra-small-suffix} {
position: absolute !important;
width: 1px !important;
height: 1px !important;
margin: -1px !important;
border: 0 !important;
padding: 0 !important;
clip: rect(0 0 0 0) !important;
-webkit-clip-path: inset(100%) !important;
clip-path: inset(100%) !important;
overflow: hidden !important;
}
}
@media screen and (min-width: #{$visually-hidden-small-breakpoint}) and (max-width: #{$visually-hidden-medium-breakpoint}-1px) {
.#{$visually-hidden-prefix}-#{$visually-hidden-small-suffix} {
position: absolute !important;
width: 1px !important;
height: 1px !important;
margin: -1px !important;
border: 0 !important;
padding: 0 !important;
clip: rect(0 0 0 0) !important;
-webkit-clip-path: inset(100%) !important;
clip-path: inset(100%) !important;
overflow: hidden !important;
}
}
}
@else {
@media screen and (max-width: #{$visually-hidden-medium-breakpoint}-1px) {
.#{$visually-hidden-prefix}-#{$visually-hidden-small-suffix} {
position: absolute !important;
width: 1px !important;
height: 1px !important;
margin: -1px !important;
border: 0 !important;
padding: 0 !important;
clip: rect(0 0 0 0) !important;
-webkit-clip-path: inset(100%) !important;
clip-path: inset(100%) !important;
overflow: hidden !important;
}
}
@media screen and (min-width: #{$visually-hidden-medium-breakpoint}) and (max-width: #{$visually-hidden-large-breakpoint}-1px) {
.#{$visually-hidden-prefix}-#{$visually-hidden-medium-suffix} {
position: absolute !important;
width: 1px !important;
height: 1px !important;
margin: -1px !important;
border: 0 !important;
padding: 0 !important;
clip: rect(0 0 0 0) !important;
-webkit-clip-path: inset(100%) !important;
clip-path: inset(100%) !important;
overflow: hidden !important;
}
}
@media screen and (min-width: #{$visually-hidden-large-breakpoint}) {
.#{$visually-hidden-prefix}-#{$visually-hidden-large-suffix} {
position: absolute !important;
width: 1px !important;
height: 1px !important;
margin: -1px !important;
border: 0 !important;
padding: 0 !important;
clip: rect(0 0 0 0) !important;
-webkit-clip-path: inset(100%) !important;
clip-path: inset(100%) !important;
overflow: hidden !important;
}
}
}
}
// Utility module's mixin definitions are here. For the module itself
// check `_utility.scss`.
// Generic border mixin. ATTENTION: Uses !important.
// Variables:
// - $border-generic-name : The name of the class used for the generic border.
@mixin make-border-generic ($border-generic-name) {
.#{$border-generic-name} {
border: 1px solid rgba(0,0,0, 0.25) !important;
}
}
// Generic radial border mixin. ATTENTION: Uses !important.
// Variables:
// - $border-radial-name : The name of the class used for the radial border.
// - $border-radial-radius : The border radius used for the radial border.
@mixin make-border-radial-style ($border-radial-name, $border-radial-radius) {
.#{$border-radial-name} {
border-radius: $border-radial-radius !important;
}
}
// Generic box shadow mixin. ATTENTION: Uses !important.
// Variables:
// - $box-shadow-name : The name of the class used for the generic box shadow.
// - $box-shadow-value : The box shadow value of the generic box shadow.
@mixin make-box-shadow-generic ($box-shadow-name, $box-shadow-value) {
.#{$box-shadow-name} {
box-shadow: $box-shadow-value !important;
}
}
// Responsive margin mixin. ATTENTION: Uses !important.
// Variables:
// - $margin-name : The name of the class used for the responsive margin.
// - $margin-small-value : Responsive margin value for smaller screens.
// - $margin-medium-value : Responsive margin value for medium screens.
// - $margin-large-value : Responsive margin value for large screens.
// - $margin-medium-breakpoint : (Optional) Medium screen breakpoint for the responsive margin. Defaults to `768px`.
// - $margin-large-breakpoint : (Optional) Large screen breakpoint for the responsive margin. Defaults to `1280px`.
// - $margin-use-four-step-grid : (Optional) Should the legacy four-step grid be used? Defaults to `false`.
// - $margin-small-breakpoint : (Optional) Small screen breakpoint for the responsive margin, used only if above flag is set to `true`. Defaults to `480px`.
// - $margin-extra-small-value : (Optional) Responsive margin value for extra small screens, used only if above flag is set to `true`. Defaults to `0`.
@mixin make-margin-responsive ($margin-name, $margin-small-value,
$margin-medium-value, $margin-large-value, $margin-medium-breakpoint : 768px,
$margin-large-breakpoint : 1280px, $margin-use-four-step-grid : false,
$margin-small-breakpoint : 480px, $margin-extra-small-value : 0) {
@if $margin-use-four-step-grid {
.#{$margin-name} {
margin: $margin-extra-small-value !important;
}
@media screen and (min-width: #{$margin-small-breakpoint}) {
margin: $margin-small-value !important;
}
}
@else {
.#{$margin-name} {
margin: $margin-small-value !important;
}
}
@media screen and (min-width: #{$margin-medium-breakpoint}) {
.#{$margin-name} {
margin: $margin-medium-value !important;
}
}
@media screen and (min-width: #{$margin-large-breakpoint}) {
.#{$margin-name} {
margin: $margin-large-value !important;
}
}
}
// Responsive padding mixin. ATTENTION: Uses !important.
// Variables:
// - $padding-name : The name of the class used for the responsive padding.
// - $padding-small-value : Responsive padding value for smaller screens.
// - $padding-medium-value : Responsive padding value for medium screens.
// - $padding-large-value : Responsive padding value for large screens.
// - $padding-medium-breakpoint : (Optional) Medium screen breakpoint for the responsive padding. Defaults to `768px`.
// - $padding-large-breakpoint : (Optional) Large screen breakpoint for the responsive padding. Defaults to `1280px`.
// - $padding-use-four-step-grid : (Optional) Should the legacy four-step grid be used? Defaults to `false`.
// - $padding-small-breakpoint : (Optional) Small screen breakpoint for the responsive padding, used only if above flag is set to `true`. Defaults to `480px`.
// - $padding-extra-small-value : (Optional) Responsive padding value for extra small screens, used only if above flag is set to `true`. Defaults to `0`.
@mixin make-padding-responsive ($padding-name, $padding-small-value,
$padding-medium-value, $padding-large-value, $padding-medium-breakpoint : 768px,
$padding-large-breakpoint : 1280px, $padding-use-four-step-grid : false,
$padding-small-breakpoint : 480px, $padding-extra-small-value : 0) {
@if $padding-use-four-step-grid{
.#{$padding-name} {
padding: $padding-extra-small-value !important;
}
@media screen and (min-width: #{$padding-small-breakpoint}) {
padding: $padding-small-value !important;
}
}
@else {
.#{$padding-name} {
padding: $padding-small-value !important;
}
}
@media screen and (min-width: #{$padding-medium-breakpoint}) {
.#{$padding-name} {
padding: $padding-medium-value !important;
}
}
@media screen and (min-width: #{$padding-large-breakpoint}) {
.#{$padding-name} {
padding: $padding-large-value !important;
}
}
}
// Responsive hidden elements mixin. ATTENTION: Uses !important.
// Variables:
// - $hidden-prefix : The prefix for the name of the class used for the responsive hiding.
// - $hidden-medium-breakpoint : (Optional) Medium screen breakpoint for the responsive hiding. Defaults to `768px`.
// - $hidden-large-breakpoint : (Optional) Large screen breakpoint for the responsive hiding. Defaults to `1280px`.
// - $hidden-small-suffix : (Optional) The small-screen suffix for the name of the class used for the responsive hiding. Defaults to 'sm'.
// - $hidden-medium-suffix : (Optional) The medium-screen suffix for the name of the class used for the responsive hiding. Defaults to 'md'.
// - $hidden-large-suffix : (Optional) The large-screen suffix for the name of the class used for the responsive hiding. Defaults to 'lg'.
// - $hidden-use-four-step-grid : (Optional) Should the legacy four-step grid be used? Defaults to `false`.
// - $hidden-small-breakpoint : (Optional) Small screen breakpoint for the responsive hiding, used only if the above variable is set to `true`. Defaults to `480px`.
// - $hidden-extra-small-suffix : (Optional) The extra-small-screen suffix for the name of the class used for the responsive hiding. Used only if the above flag is set to `true`. Defaults to 'xs'.
@mixin make-hidden-responsive ($hidden-prefix, $hidden-medium-breakpoint : 768px,
$hidden-large-breakpoint : 1280px , $hidden-small-suffix : 'sm', $hidden-medium-suffix : 'md',
$hidden-large-suffix : 'lg', $hidden-use-four-step-grid : false,
$hidden-small-breakpoint : 480px, $hidden-extra-small-suffix : 'xs') {
@if $hidden-use-four-step-grid {
@media screen and (max-width: #{$hidden-small-breakpoint}-1px) {
.#{$hidden-prefix}-#{$hidden-extra-small-suffix} {
display: none !important;
}
}
@media screen and (min-width: #{$hidden-small-breakpoint}) and (max-width: #{$hidden-medium-breakpoint}-1px) {
.#{$hidden-prefix}-#{$hidden-small-suffix} {
display: none !important;
}
}
}
@else {
@media screen and (max-width: #{$hidden-medium-breakpoint}-1px) {
.#{$hidden-prefix}-#{$hidden-small-suffix} {
display: none !important;
}
}
@media screen and (min-width: #{$hidden-medium-breakpoint}) and (max-width: #{$hidden-large-breakpoint}-1px) {
.#{$hidden-prefix}-#{$hidden-medium-suffix} {
display: none !important;
}
}
@media screen and (min-width: #{$hidden-large-breakpoint}) {
.#{$hidden-prefix}-#{$hidden-large-suffix} {
display: none !important;
}
}
}
}
// Responsive visually hidden elements mixin. ATTENTION: Uses !important.
// Variables:
// - $visually-hidden-prefix : The prefix for the name of the class used for the responsive visual hiding.
// - $visually-hidden-medium-breakpoint : (Optional) Medium screen breakpoint for the responsive visual hiding. Defaults to `768px`.
// - $visually-hidden-large-breakpoint : (Optional) Large screen breakpoint for the responsive visual hiding. Defaults to `1280px`.
// - $visually-hidden-small-suffix : (Optional) The small-screen suffix for the name of the class used for the responsive visual hiding. Defaults to 'sm'.
// - $visually-hidden-medium-suffix : (Optional) The medium-screen suffix for the name of the class used for the responsive visual hiding. Defaults to 'md'.
// - $visually-hidden-large-suffix : (Optional) The large-screen suffix for the name of the class used for the responsive visual hiding. Defaults to 'lg'.
// - $visually-hidden-use-four-step-grid : (Optional) Should the legacy four-step grid be used? Defaults to `false`.
// - $visually-hidden-small-breakpoint : (Optional) Small screen breakpoint for the responsive visual hiding, used only if the above variable is set to `true`. Defaults to `480px`.
// - $visually-hidden-extra-small-suffix : (Optional) The extra-small-screen suffix for the name of the class used for the responsive visual hiding. Used only if the above flag is set to `true`. Defaults to 'xs'.
@mixin make-visually-hidden-responsive ($visually-hidden-prefix, $visually-hidden-medium-breakpoint : 768px,
$visually-hidden-large-breakpoint : 1280px , $visually-hidden-small-suffix : 'sm', $visually-hidden-medium-suffix : 'md',
$visually-hidden-large-suffix : 'lg', $visually-hidden-use-four-step-grid : false,
$visually-hidden-small-breakpoint : 480px, $visually-hidden-extra-small-suffix : 'xs') {
@if $visually-hidden-use-four-step-grid {
@media screen and (max-width: #{$visually-hidden-small-breakpoint}-1px) {
.#{$visually-hidden-prefix}-#{$visually-hidden-extra-small-suffix} {
position: absolute !important;
width: 1px !important;
height: 1px !important;
margin: -1px !important;
border: 0 !important;
padding: 0 !important;
clip: rect(0 0 0 0) !important;
-webkit-clip-path: inset(100%) !important;
clip-path: inset(100%) !important;
overflow: hidden !important;
}
}
@media screen and (min-width: #{$visually-hidden-small-breakpoint}) and (max-width: #{$visually-hidden-medium-breakpoint}-1px) {
.#{$visually-hidden-prefix}-#{$visually-hidden-small-suffix} {
position: absolute !important;
width: 1px !important;
height: 1px !important;
margin: -1px !important;
border: 0 !important;
padding: 0 !important;
clip: rect(0 0 0 0) !important;
-webkit-clip-path: inset(100%) !important;
clip-path: inset(100%) !important;
overflow: hidden !important;
}
}
}
@else {
@media screen and (max-width: #{$visually-hidden-medium-breakpoint}-1px) {
.#{$visually-hidden-prefix}-#{$visually-hidden-small-suffix} {
position: absolute !important;
width: 1px !important;
height: 1px !important;
margin: -1px !important;
border: 0 !important;
padding: 0 !important;
clip: rect(0 0 0 0) !important;
-webkit-clip-path: inset(100%) !important;
clip-path: inset(100%) !important;
overflow: hidden !important;
}
}
@media screen and (min-width: #{$visually-hidden-medium-breakpoint}) and (max-width: #{$visually-hidden-large-breakpoint}-1px) {
.#{$visually-hidden-prefix}-#{$visually-hidden-medium-suffix} {
position: absolute !important;
width: 1px !important;
height: 1px !important;
margin: -1px !important;
border: 0 !important;
padding: 0 !important;
clip: rect(0 0 0 0) !important;
-webkit-clip-path: inset(100%) !important;
clip-path: inset(100%) !important;
overflow: hidden !important;
}
}
@media screen and (min-width: #{$visually-hidden-large-breakpoint}) {
.#{$visually-hidden-prefix}-#{$visually-hidden-large-suffix} {
position: absolute !important;
width: 1px !important;
height: 1px !important;
margin: -1px !important;
border: 0 !important;
padding: 0 !important;
clip: rect(0 0 0 0) !important;
-webkit-clip-path: inset(100%) !important;
clip-path: inset(100%) !important;
overflow: hidden !important;
}
}
}
}

File diff suppressed because it is too large Load diff

View file

@ -1,354 +1,354 @@
/*
Definitions for contextual background elements, toasts and tooltips.
*/
$mark-back-color: #0277bd !default; // Background color for <mark>
$mark-fore-color: #fafafa !default; // Text color for <mark>
$mark-font-size: 0.95em !default; // Font size for <mark>
$mark-line-height: 1em !default; // Line height for <mark>
$mark-inline-block-name: 'inline-block' !default;// Class name for inline-block <mark>
$_include-toast: true !default; // [Hidden] Should toasts be included? (boolean)
$toast-name: 'toast' !default; // Class name for toast component
$toast-back-color: #424242 !default; // Background color for toast component
$toast-fore-color: #fafafa !default; // Text color for toast component
$_include-tooltip: true !default; // [Hidden] Should tooltips be included? (boolean)
$tooltip-name: 'tooltip' !default; // Class name for tooltip component
$tooltip-bottom-name: 'bottom' !default; // Bottom tooltip class name
$tooltip-back-color: #212121 !default; // Background color for tooltip component
$tooltip-fore-color: #fafafa !default; // Text color for tooltip component
$_include-modal: true !default; // [Hidden] Should modal dialogs be included? (boolean)
$modal-name: 'modal' !default; // Class name for modal dialog component
$modal-overlay-color: rgba(0, 0, 0, 0.45) !default; // Overlay color for modal dialog component
$modal-close-name: 'modal-close' !default;// Class name for modal dialog close button
$modal-close-color: #444 !default; // Text color for the close button of the modal dialog component
$modal-close-hover-back-color: #f0f0f0 !default; // Background color for the close button of the modal dialog component (on hover/focus)
$modal-close-size: 1.75rem !default; // Font size for the close button of the modal dialog component
$_include-collapse: true !default; // [Hidden] Should collapse components be included? (boolean)
$collapse-name: 'collapse' !default; // Class name for collapse component
$collapse-label-height: 1.5rem !default; // Height for the labels in the collapse component
$collapse-content-max-height: 400px !default; // Max height for the content panes in the collapse component
$collapse-label-back-color: #e8e8e8 !default;// Background color for labels in the collapse component
$collapse-label-fore-color: #212121 !default;// Text color for labels in the collapse component
$collapse-label-hover-back-color:#f0f0f0 !default;// Background color for labels in the collapse component (hover)
$collapse-selected-label-back-color:#ececec !default;// Background color for selected labels in the collapse component
$collapse-border-color: #ddd !default; // Border color for collapse component
$collapse-selected-label-border-color: #0277bd !default; // Border color for collapse component's selected labels
$collapse-content-back-color: #fafafa !default; // Background color for collapse component's content panes
// CSS variable name definitions [exercise caution if modifying these]
$mark-back-color-var: '--mark-back-color' !default;
$mark-fore-color-var: '--mark-fore-color' !default;
$toast-back-color-var: '--toast-back-color' !default;
$toast-fore-color-var: '--toast-fore-color' !default;
$tooltip-back-color-var: '--tooltip-back-color' !default;
$tooltip-fore-color-var: '--tooltip-fore-color' !default;
$modal-overlay-color-var: '--modal-overlay-color' !default;
$modal-close-color-var: '--modal-close-color' !default;
$modal-close-hover-back-color-var: '--modal-close-hover-color' !default;
$collapse-label-back-color-var: '--collapse-label-back-color' !default;
$collapse-label-fore-color-var: '--collapse-label-fore-color' !default;
$collapse-label-hover-back-color-var: '--collapse-label-hover-back-color' !default;
$collapse-selected-label-back-color-var: '--collapse-selected-label-back-color' !default;
$collapse-border-color-var: '--collapse-border-color' !default;
$collapse-content-back-color-var: '--collapse-content-back-color' !default;
$collapse-selected-label-border-color-var: '--collapse-selected-label-border-color' !default;
// == Uncomment below code if this module is used on its own ==
//
// $base-line-height: 1.5 !default; // Line height for most elements
// $universal-margin: 0.5rem !default; // Universal margin for the most elements
// $universal-padding: 0.5rem !default; // Universal padding for the most elements
// $universal-border-radius: 0.125rem !default; // Universal border-radius for most elements
// $universal-box-shadow: none !default; // Universal box-shadow for most elements
// $universal-margin-var: '--universal-margin' !default;
// $universal-padding-var: '--universal-padding' !default;
// $universal-border-radius-var: '--universal-border-radius' !default;
// $universal-box-shadow-var: '--universal-box-shadow' !default;
// :root {
// #{$universal-margin-var}: $universal-margin;
// #{$universal-padding-var}: $universal-padding;
// #{$universal-border-radius-var}: $universal-border-radius;
// @if $universal-box-shadow != none {
// #{$universal-box-shadow-var}: $universal-box-shadow;
// }
// }
//
// ============================================================
// Check the `_contextual_mixins.scss` file to find this module's mixins.
@import '_contextual_mixins';
/* Contextual module CSS variable definitions */
:root {
#{$mark-back-color-var}: $mark-back-color;
#{$mark-fore-color-var}: $mark-fore-color;
}
// Default styling for mark. Use mixins for alternate styles.
mark {
background: var(#{$mark-back-color-var});
color: var(#{$mark-fore-color-var});
font-size: $mark-font-size;
line-height: $mark-line-height;
border-radius: var(#{$universal-border-radius-var});
padding: calc(var(#{$universal-padding-var}) / 4) calc(var(#{$universal-padding-var}) / 2);
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
&.#{$mark-inline-block-name} {
display: inline-block;
// This is hardcoded, as we want inline-block <mark> elements to be styled as normal pieces of text, instead of look small and weird.
font-size: 1em;
// Line height is reset to the normal line-height from `core`. Also hardcoded for same reasons.
line-height: $base-line-height;
padding: calc(var(#{$universal-padding-var}) / 2) var(#{$universal-padding-var});
}
}
// Styling for toasts. - No border styling, I think it's unnecessary anyways.
@if $_include-toast {
:root {
#{$toast-back-color-var}: $toast-back-color;
#{$toast-fore-color-var}: $toast-fore-color;
}
.#{$toast-name} {
position: fixed;
bottom: calc(var(#{$universal-margin-var}) * 3);
left: 50%;
transform: translate(-50%, -50%);
z-index: 1111;
color: var(#{$toast-fore-color-var});
background: var(#{$toast-back-color-var});
border-radius: calc(var(#{$universal-border-radius-var}) * 16);
padding: var(#{$universal-padding-var}) calc(var(#{$universal-padding-var}) * 3);
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
}
}
// Styling for tooltips.
@if $_include-tooltip {
:root {
#{$tooltip-back-color-var}: $tooltip-back-color;
#{$tooltip-fore-color-var}: $tooltip-fore-color;
}
.#{$tooltip-name} {
position: relative;
display: inline-block;
&:before, &:after {
position: absolute;
opacity: 0;
clip: rect(0 0 0 0);
-webkit-clip-path: inset(100%);
clip-path: inset(100%);
transition: all 0.3s;
// Remember to keep this index a lower value than the one used for stickies.
z-index: 1010; // Deals with certain problems when combined with cards and tables.
left: 50%;
}
&:not(.#{$tooltip-bottom-name}):before, &:not(.#{$tooltip-bottom-name}):after { // Top (default) tooltip styling
bottom: 75%;
}
&.#{$tooltip-bottom-name}:before, &.#{$tooltip-bottom-name}:after { // Bottom tooltip styling
top: 75%;
}
&:hover, &:focus {
&:before, &:after {
opacity: 1;
clip: auto;
-webkit-clip-path: inset(0%);
clip-path: inset(0%);
}
}
&:before { // This is the little tooltip triangle
content: '';
background: transparent;
border: var(#{$universal-margin-var}) solid transparent;
// Newer browsers will center the tail properly
left: calc(50% - var(#{$universal-margin-var}));
}
&:not(.#{$tooltip-bottom-name}):before { // Top (default) tooltip styling
border-top-color: $tooltip-back-color;
}
&.#{$tooltip-bottom-name}:before { // Bottom tooltip styling
border-bottom-color: $tooltip-back-color;
}
&:after { // This is the actual tooltip's text block
content: attr(aria-label);
color: var(#{$tooltip-fore-color-var});
background: var(#{$tooltip-back-color-var});
border-radius: var(#{$universal-border-radius-var});
padding: var(#{$universal-padding-var});
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
white-space: nowrap;
transform: translateX(-50%);
}
&:not(.#{$tooltip-bottom-name}):after { // Top (default) tooltip styling
margin-bottom: calc(2 * var(#{$universal-margin-var}));
}
&.#{$tooltip-bottom-name}:after { // Bottom tooltip styling
margin-top: calc(2 * var(#{$universal-margin-var}));
}
}
}
// Styling for modal dialogs.
@if $_include-modal {
:root {
#{$modal-overlay-color-var}: $modal-overlay-color;
#{$modal-close-color-var}: $modal-close-color;
#{$modal-close-hover-back-color-var}: $modal-close-hover-back-color;
}
[type="checkbox"].#{$modal-name} {
height: 1px;
width: 1px;
margin: -1px;
overflow: hidden;
position: absolute;
clip: rect(0 0 0 0);
-webkit-clip-path: inset(100%);
clip-path: inset(100%);
& + div {
position: fixed;
top: 0;
left: 0;
display: none;
width: 100vw;
height: 100vh;
background: var(#{$modal-overlay-color-var});
& .card {
margin: 0 auto;
max-height: 50vh;
overflow: auto;
& .#{$modal-close-name} {
position: absolute;
top: 0;
right: 0;
width: $modal-close-size;
height: $modal-close-size;
border-radius: var(#{$universal-border-radius-var});
padding: var(#{$universal-padding-var});
margin: 0;
cursor: pointer;
transition: background 0.3s;
&:before {
display: block;
content: '\00D7';
color: var(#{$modal-close-color-var});
position: relative;
font-family: sans-serif;
font-size: $modal-close-size;
line-height: 1;
text-align: center;
}
&:hover, &:focus {
background: var(#{$modal-close-hover-back-color-var});
}
}
}
}
&:checked + div {
display: flex;
flex: 0 1 auto;
z-index: 1200;
& .card {
& .#{$modal-close-name} {
z-index: 1211;
}
}
}
}
}
// Styling for collapse.
@if $_include-collapse {
:root {
#{$collapse-label-back-color-var}: $collapse-label-back-color;
#{$collapse-label-fore-color-var}: $collapse-label-fore-color;
#{$collapse-label-hover-back-color-var}: $collapse-label-hover-back-color;
#{$collapse-selected-label-back-color-var}: $collapse-selected-label-back-color;
#{$collapse-border-color-var}: $collapse-border-color;
#{$collapse-content-back-color-var} : $collapse-content-back-color;
#{$collapse-selected-label-border-color-var}: $collapse-selected-label-border-color;
}
.#{$collapse-name} {
width: calc(100% - 2 * var(#{$universal-margin-var}));
opacity: 1;
display: flex;
flex-direction: column;
margin: var(#{$universal-margin-var});
border-radius: var(#{$universal-border-radius-var});
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
& > [type="radio"], & > [type="checkbox"] {
height: 1px;
width: 1px;
margin: -1px;
overflow: hidden;
position: absolute;
clip: rect(0 0 0 0);
-webkit-clip-path: inset(100%);
clip-path: inset(100%);
}
& > label {
flex-grow: 1;
display: inline-block;
height: $collapse-label-height;
cursor: pointer;
transition: background 0.3s;
color: var(#{$collapse-label-fore-color-var});
background: var(#{$collapse-label-back-color-var});
border: $__1px solid var(#{$collapse-border-color-var});
padding: calc(1.5 * var(#{$universal-padding-var}));
&:hover, &:focus {
background: var(#{$collapse-label-hover-back-color-var});
}
+ div {
flex-basis: auto;
height: 1px;
width: 1px;
margin: -1px;
overflow: hidden;
position: absolute;
clip: rect(0 0 0 0);
-webkit-clip-path: inset(100%);
clip-path: inset(100%);
transition: max-height 0.3s;
max-height: 1px; // for transition
}
}
> :checked + label {
background: var(#{$collapse-selected-label-back-color-var});
// border: 0.0625rem solid #bdbdbd; // var it
border-bottom-color: var(#{$collapse-selected-label-border-color-var});
& + div {
box-sizing: border-box;
position: relative;
width: 100%;
height: auto;
overflow: auto;
margin: 0;
background: var(#{$collapse-content-back-color-var});
border: $__1px solid var(#{$collapse-border-color-var});
border-top: 0;
padding: var(#{$universal-padding-var});
clip: auto;
-webkit-clip-path: inset(0%);
clip-path: inset(0%);
max-height: $collapse-content-max-height;
}
}
& > label:not(:first-of-type) { // Keep these down here, as it overrides some other styles.
border-top: 0;
}
& > label:first-of-type {
border-radius: var(#{$universal-border-radius-var}) var(#{$universal-border-radius-var}) 0 0;
}
& > label:last-of-type:not(:first-of-type) {
border-radius: 0 0 var(#{$universal-border-radius-var}) var(#{$universal-border-radius-var});
}
& > label:last-of-type:first-of-type {
border-radius: var(#{$universal-border-radius-var});
}
& > :checked:last-of-type:not(:first-of-type) + label {
border-radius: 0;
}
& > :checked:last-of-type + label + div {
border-radius: 0 0 var(#{$universal-border-radius-var}) var(#{$universal-border-radius-var});
}
}
}
/*
Definitions for contextual background elements, toasts and tooltips.
*/
$mark-back-color: #0277bd !default; // Background color for <mark>
$mark-fore-color: #fafafa !default; // Text color for <mark>
$mark-font-size: 0.95em !default; // Font size for <mark>
$mark-line-height: 1em !default; // Line height for <mark>
$mark-inline-block-name: 'inline-block' !default;// Class name for inline-block <mark>
$_include-toast: true !default; // [Hidden] Should toasts be included? (boolean)
$toast-name: 'toast' !default; // Class name for toast component
$toast-back-color: #424242 !default; // Background color for toast component
$toast-fore-color: #fafafa !default; // Text color for toast component
$_include-tooltip: true !default; // [Hidden] Should tooltips be included? (boolean)
$tooltip-name: 'tooltip' !default; // Class name for tooltip component
$tooltip-bottom-name: 'bottom' !default; // Bottom tooltip class name
$tooltip-back-color: #212121 !default; // Background color for tooltip component
$tooltip-fore-color: #fafafa !default; // Text color for tooltip component
$_include-modal: true !default; // [Hidden] Should modal dialogs be included? (boolean)
$modal-name: 'modal' !default; // Class name for modal dialog component
$modal-overlay-color: rgba(0, 0, 0, 0.45) !default; // Overlay color for modal dialog component
$modal-close-name: 'modal-close' !default;// Class name for modal dialog close button
$modal-close-color: #444 !default; // Text color for the close button of the modal dialog component
$modal-close-hover-back-color: #f0f0f0 !default; // Background color for the close button of the modal dialog component (on hover/focus)
$modal-close-size: 1.75rem !default; // Font size for the close button of the modal dialog component
$_include-collapse: true !default; // [Hidden] Should collapse components be included? (boolean)
$collapse-name: 'collapse' !default; // Class name for collapse component
$collapse-label-height: 1.5rem !default; // Height for the labels in the collapse component
$collapse-content-max-height: 400px !default; // Max height for the content panes in the collapse component
$collapse-label-back-color: #e8e8e8 !default;// Background color for labels in the collapse component
$collapse-label-fore-color: #212121 !default;// Text color for labels in the collapse component
$collapse-label-hover-back-color:#f0f0f0 !default;// Background color for labels in the collapse component (hover)
$collapse-selected-label-back-color:#ececec !default;// Background color for selected labels in the collapse component
$collapse-border-color: #ddd !default; // Border color for collapse component
$collapse-selected-label-border-color: #0277bd !default; // Border color for collapse component's selected labels
$collapse-content-back-color: #fafafa !default; // Background color for collapse component's content panes
// CSS variable name definitions [exercise caution if modifying these]
$mark-back-color-var: '--mark-back-color' !default;
$mark-fore-color-var: '--mark-fore-color' !default;
$toast-back-color-var: '--toast-back-color' !default;
$toast-fore-color-var: '--toast-fore-color' !default;
$tooltip-back-color-var: '--tooltip-back-color' !default;
$tooltip-fore-color-var: '--tooltip-fore-color' !default;
$modal-overlay-color-var: '--modal-overlay-color' !default;
$modal-close-color-var: '--modal-close-color' !default;
$modal-close-hover-back-color-var: '--modal-close-hover-color' !default;
$collapse-label-back-color-var: '--collapse-label-back-color' !default;
$collapse-label-fore-color-var: '--collapse-label-fore-color' !default;
$collapse-label-hover-back-color-var: '--collapse-label-hover-back-color' !default;
$collapse-selected-label-back-color-var: '--collapse-selected-label-back-color' !default;
$collapse-border-color-var: '--collapse-border-color' !default;
$collapse-content-back-color-var: '--collapse-content-back-color' !default;
$collapse-selected-label-border-color-var: '--collapse-selected-label-border-color' !default;
// == Uncomment below code if this module is used on its own ==
//
// $base-line-height: 1.5 !default; // Line height for most elements
// $universal-margin: 0.5rem !default; // Universal margin for the most elements
// $universal-padding: 0.5rem !default; // Universal padding for the most elements
// $universal-border-radius: 0.125rem !default; // Universal border-radius for most elements
// $universal-box-shadow: none !default; // Universal box-shadow for most elements
// $universal-margin-var: '--universal-margin' !default;
// $universal-padding-var: '--universal-padding' !default;
// $universal-border-radius-var: '--universal-border-radius' !default;
// $universal-box-shadow-var: '--universal-box-shadow' !default;
// :root {
// #{$universal-margin-var}: $universal-margin;
// #{$universal-padding-var}: $universal-padding;
// #{$universal-border-radius-var}: $universal-border-radius;
// @if $universal-box-shadow != none {
// #{$universal-box-shadow-var}: $universal-box-shadow;
// }
// }
//
// ============================================================
// Check the `_contextual_mixins.scss` file to find this module's mixins.
@import '_contextual_mixins';
/* Contextual module CSS variable definitions */
:root {
#{$mark-back-color-var}: $mark-back-color;
#{$mark-fore-color-var}: $mark-fore-color;
}
// Default styling for mark. Use mixins for alternate styles.
mark {
background: var(#{$mark-back-color-var});
color: var(#{$mark-fore-color-var});
font-size: $mark-font-size;
line-height: $mark-line-height;
border-radius: var(#{$universal-border-radius-var});
padding: calc(var(#{$universal-padding-var}) / 4) calc(var(#{$universal-padding-var}) / 2);
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
&.#{$mark-inline-block-name} {
display: inline-block;
// This is hardcoded, as we want inline-block <mark> elements to be styled as normal pieces of text, instead of look small and weird.
font-size: 1em;
// Line height is reset to the normal line-height from `core`. Also hardcoded for same reasons.
line-height: $base-line-height;
padding: calc(var(#{$universal-padding-var}) / 2) var(#{$universal-padding-var});
}
}
// Styling for toasts. - No border styling, I think it's unnecessary anyways.
@if $_include-toast {
:root {
#{$toast-back-color-var}: $toast-back-color;
#{$toast-fore-color-var}: $toast-fore-color;
}
.#{$toast-name} {
position: fixed;
bottom: calc(var(#{$universal-margin-var}) * 3);
left: 50%;
transform: translate(-50%, -50%);
z-index: 1111;
color: var(#{$toast-fore-color-var});
background: var(#{$toast-back-color-var});
border-radius: calc(var(#{$universal-border-radius-var}) * 16);
padding: var(#{$universal-padding-var}) calc(var(#{$universal-padding-var}) * 3);
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
}
}
// Styling for tooltips.
@if $_include-tooltip {
:root {
#{$tooltip-back-color-var}: $tooltip-back-color;
#{$tooltip-fore-color-var}: $tooltip-fore-color;
}
.#{$tooltip-name} {
position: relative;
display: inline-block;
&:before, &:after {
position: absolute;
opacity: 0;
clip: rect(0 0 0 0);
-webkit-clip-path: inset(100%);
clip-path: inset(100%);
transition: all 0.3s;
// Remember to keep this index a lower value than the one used for stickies.
z-index: 1010; // Deals with certain problems when combined with cards and tables.
left: 50%;
}
&:not(.#{$tooltip-bottom-name}):before, &:not(.#{$tooltip-bottom-name}):after { // Top (default) tooltip styling
bottom: 75%;
}
&.#{$tooltip-bottom-name}:before, &.#{$tooltip-bottom-name}:after { // Bottom tooltip styling
top: 75%;
}
&:hover, &:focus {
&:before, &:after {
opacity: 1;
clip: auto;
-webkit-clip-path: inset(0%);
clip-path: inset(0%);
}
}
&:before { // This is the little tooltip triangle
content: '';
background: transparent;
border: var(#{$universal-margin-var}) solid transparent;
// Newer browsers will center the tail properly
left: calc(50% - var(#{$universal-margin-var}));
}
&:not(.#{$tooltip-bottom-name}):before { // Top (default) tooltip styling
border-top-color: $tooltip-back-color;
}
&.#{$tooltip-bottom-name}:before { // Bottom tooltip styling
border-bottom-color: $tooltip-back-color;
}
&:after { // This is the actual tooltip's text block
content: attr(aria-label);
color: var(#{$tooltip-fore-color-var});
background: var(#{$tooltip-back-color-var});
border-radius: var(#{$universal-border-radius-var});
padding: var(#{$universal-padding-var});
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
white-space: nowrap;
transform: translateX(-50%);
}
&:not(.#{$tooltip-bottom-name}):after { // Top (default) tooltip styling
margin-bottom: calc(2 * var(#{$universal-margin-var}));
}
&.#{$tooltip-bottom-name}:after { // Bottom tooltip styling
margin-top: calc(2 * var(#{$universal-margin-var}));
}
}
}
// Styling for modal dialogs.
@if $_include-modal {
:root {
#{$modal-overlay-color-var}: $modal-overlay-color;
#{$modal-close-color-var}: $modal-close-color;
#{$modal-close-hover-back-color-var}: $modal-close-hover-back-color;
}
[type="checkbox"].#{$modal-name} {
height: 1px;
width: 1px;
margin: -1px;
overflow: hidden;
position: absolute;
clip: rect(0 0 0 0);
-webkit-clip-path: inset(100%);
clip-path: inset(100%);
& + div {
position: fixed;
top: 0;
left: 0;
display: none;
width: 100vw;
height: 100vh;
background: var(#{$modal-overlay-color-var});
& .card {
margin: 0 auto;
max-height: 50vh;
overflow: auto;
& .#{$modal-close-name} {
position: absolute;
top: 0;
right: 0;
width: $modal-close-size;
height: $modal-close-size;
border-radius: var(#{$universal-border-radius-var});
padding: var(#{$universal-padding-var});
margin: 0;
cursor: pointer;
transition: background 0.3s;
&:before {
display: block;
content: '\00D7';
color: var(#{$modal-close-color-var});
position: relative;
font-family: sans-serif;
font-size: $modal-close-size;
line-height: 1;
text-align: center;
}
&:hover, &:focus {
background: var(#{$modal-close-hover-back-color-var});
}
}
}
}
&:checked + div {
display: flex;
flex: 0 1 auto;
z-index: 1200;
& .card {
& .#{$modal-close-name} {
z-index: 1211;
}
}
}
}
}
// Styling for collapse.
@if $_include-collapse {
:root {
#{$collapse-label-back-color-var}: $collapse-label-back-color;
#{$collapse-label-fore-color-var}: $collapse-label-fore-color;
#{$collapse-label-hover-back-color-var}: $collapse-label-hover-back-color;
#{$collapse-selected-label-back-color-var}: $collapse-selected-label-back-color;
#{$collapse-border-color-var}: $collapse-border-color;
#{$collapse-content-back-color-var} : $collapse-content-back-color;
#{$collapse-selected-label-border-color-var}: $collapse-selected-label-border-color;
}
.#{$collapse-name} {
width: calc(100% - 2 * var(#{$universal-margin-var}));
opacity: 1;
display: flex;
flex-direction: column;
margin: var(#{$universal-margin-var});
border-radius: var(#{$universal-border-radius-var});
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
& > [type="radio"], & > [type="checkbox"] {
height: 1px;
width: 1px;
margin: -1px;
overflow: hidden;
position: absolute;
clip: rect(0 0 0 0);
-webkit-clip-path: inset(100%);
clip-path: inset(100%);
}
& > label {
flex-grow: 1;
display: inline-block;
height: $collapse-label-height;
cursor: pointer;
transition: background 0.3s;
color: var(#{$collapse-label-fore-color-var});
background: var(#{$collapse-label-back-color-var});
border: $__1px solid var(#{$collapse-border-color-var});
padding: calc(1.5 * var(#{$universal-padding-var}));
&:hover, &:focus {
background: var(#{$collapse-label-hover-back-color-var});
}
+ div {
flex-basis: auto;
height: 1px;
width: 1px;
margin: -1px;
overflow: hidden;
position: absolute;
clip: rect(0 0 0 0);
-webkit-clip-path: inset(100%);
clip-path: inset(100%);
transition: max-height 0.3s;
max-height: 1px; // for transition
}
}
> :checked + label {
background: var(#{$collapse-selected-label-back-color-var});
// border: 0.0625rem solid #bdbdbd; // var it
border-bottom-color: var(#{$collapse-selected-label-border-color-var});
& + div {
box-sizing: border-box;
position: relative;
width: 100%;
height: auto;
overflow: auto;
margin: 0;
background: var(#{$collapse-content-back-color-var});
border: $__1px solid var(#{$collapse-border-color-var});
border-top: 0;
padding: var(#{$universal-padding-var});
clip: auto;
-webkit-clip-path: inset(0%);
clip-path: inset(0%);
max-height: $collapse-content-max-height;
}
}
& > label:not(:first-of-type) { // Keep these down here, as it overrides some other styles.
border-top: 0;
}
& > label:first-of-type {
border-radius: var(#{$universal-border-radius-var}) var(#{$universal-border-radius-var}) 0 0;
}
& > label:last-of-type:not(:first-of-type) {
border-radius: 0 0 var(#{$universal-border-radius-var}) var(#{$universal-border-radius-var});
}
& > label:last-of-type:first-of-type {
border-radius: var(#{$universal-border-radius-var});
}
& > :checked:last-of-type:not(:first-of-type) + label {
border-radius: 0;
}
& > :checked:last-of-type + label + div {
border-radius: 0 0 var(#{$universal-border-radius-var}) var(#{$universal-border-radius-var});
}
}
}

View file

@ -1,27 +1,27 @@
// Contextual module's mixin definitions are here. For the module itself
// check `_contextual.scss`.
// Mark color variant mixin:
// $mark-alt-name: The name of the class used for the <mark> variant.
// $mark-alt-back-color: Background color for <mark> variant.
// $mark-alt-fore-color: Text color for <mark> variant.
@mixin make-mark-alt-color ($mark-alt-name, $mark-alt-back-color : $mark-back-color,
$mark-alt-fore-color : $mark-fore-color) {
mark.#{$mark-alt-name} {
@if $mark-alt-back-color != $mark-back-color {
#{$mark-back-color-var}: $mark-alt-back-color;
}
@if $mark-alt-fore-color != $mark-fore-color{
#{$mark-fore-color-var}: $mark-alt-fore-color;
}
}
}
// Mark size variant mixin:
// $mark-alt-name: The name of the class used for the <mark> variant.
// $mark-alt-padding: The padding of the <mark> variant.
// $mark-alt-border-radius: The border radius of the <mark> variant.
@mixin make-mark-alt-size ($mark-alt-name, $mark-alt-padding, $mark-alt-border-radius) {
mark.#{$mark-alt-name} {
padding: $mark-alt-padding;
border-radius: $mark-alt-border-radius;
}
}
// Contextual module's mixin definitions are here. For the module itself
// check `_contextual.scss`.
// Mark color variant mixin:
// $mark-alt-name: The name of the class used for the <mark> variant.
// $mark-alt-back-color: Background color for <mark> variant.
// $mark-alt-fore-color: Text color for <mark> variant.
@mixin make-mark-alt-color ($mark-alt-name, $mark-alt-back-color : $mark-back-color,
$mark-alt-fore-color : $mark-fore-color) {
mark.#{$mark-alt-name} {
@if $mark-alt-back-color != $mark-back-color {
#{$mark-back-color-var}: $mark-alt-back-color;
}
@if $mark-alt-fore-color != $mark-fore-color{
#{$mark-fore-color-var}: $mark-alt-fore-color;
}
}
}
// Mark size variant mixin:
// $mark-alt-name: The name of the class used for the <mark> variant.
// $mark-alt-padding: The padding of the <mark> variant.
// $mark-alt-border-radius: The border radius of the <mark> variant.
@mixin make-mark-alt-size ($mark-alt-name, $mark-alt-padding, $mark-alt-border-radius) {
mark.#{$mark-alt-name} {
padding: $mark-alt-padding;
border-radius: $mark-alt-border-radius;
}
}

View file

@ -1,131 +1,131 @@
/*
Definitions for icons - powered by Feather (https://feathericons.com/).
*/
$icon-prefix: 'icon' !default; // Class name prefix for icons.
$icon-alert-name: 'alert' !default; // Class name suffix for alert icon.
$icon-bookmark-name: 'bookmark' !default; // Class name suffix for bookmark icon.
$icon-calendar-name: 'calendar' !default; // Class name suffix for calendar icon.
$icon-credit-name: 'credit' !default; // Class name suffix for credit icon.
$icon-edit-name: 'edit' !default; // Class name suffix for edit icon.
$icon-link-name: 'link' !default; // Class name suffix for link icon.
$icon-help-name: 'help' !default; // Class name suffix for help icon.
$icon-home-name: 'home' !default; // Class name suffix for home icon.
$icon-info-name: 'info' !default; // Class name suffix for info icon.
$icon-lock-name: 'lock' !default; // Class name suffix for lock icon.
$icon-mail-name: 'mail' !default; // Class name suffix for mail icon.
$icon-location-name: 'location' !default; // Class name suffix for location icon.
$icon-phone-name: 'phone' !default; // Class name suffix for phone icon.
$icon-rss-name: 'rss' !default; // Class name suffix for rss icon.
$icon-search-name: 'search' !default; // Class name suffix for search icon.
$icon-settings-name: 'settings' !default; // Class name suffix for settings icon.
$icon-share-name: 'share' !default; // Class name suffix for share icon.
$icon-cart-name: 'cart' !default; // Class name suffix for cart icon.
$icon-upload-name: 'upload' !default; // Class name suffix for upload icon.
$icon-user-name: 'user' !default; // Class name suffix for user icon.
$icon-secondary-color-name: 'secondary' !default;// Class name for secondary color icons.
$icon-inverse-color-name: 'inverse' !default; // Class name for inverse color icons.
/// Replace `$search` with `$replace` in `$string`
/// @author Hugo Giraudel
/// @param {String} $string - Initial string
/// @param {String} $search - Substring to replace
/// @param {String} $replace ('') - New value
/// @return {String} - Updated string
@function str-replace($string, $search, $replace: '') {
$index: str-index($string, $search);
@if $index {
@return str-slice($string, 1, $index - 1) + $replace + str-replace(str-slice($string, $index + str-length($search)), $search, $replace);
}
@return $string;
}
// == Uncomment below code if this module is used on its own ==
//
// $universal-margin: 0.5rem !default; // Universal margin for the most elements
// $fore-color: #111 !default; // Text & foreground color
// $universal-margin-var: '--universal-margin' !default;
// $fore-color-var: '--fore-color' !default;
// :root {
// #{$universal-margin-var}: $universal-margin;
// #{$fore-color-var}: $fore-color;
// }
//
// ============================================================
// Base styling for icons.
span[class^='#{$icon-prefix}-'] {
display: inline-block;
height: 1em;
width: 1em;
vertical-align: -0.125em; // fixes alignment issues
background-size: contain;
margin: 0 calc(var(#{$universal-margin-var}) / 4);
&.#{$icon-secondary-color-name}{
-webkit-filter: invert(25%);
filter: invert(25%);
}
&.#{$icon-inverse-color-name}{
-webkit-filter: invert(100%);
filter: invert(100%);
}
}
span{
$stroke-color: str-replace(#{$fore-color}, '#', '%23');
&.#{$icon-prefix}-#{$icon-alert-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'%3E%3C/circle%3E%3Cline x1='12' y1='8' x2='12' y2='12'%3E%3C/line%3E%3Cline x1='12' y1='16' x2='12' y2='16'%3E%3C/line%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-bookmark-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M19 21l-7-5-7 5V5a2 2 0 0 1 2-2h10a2 2 0 0 1 2 2z'%3E%3C/path%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-calendar-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='4' width='18' height='18' rx='2' ry='2'%3E%3C/rect%3E%3Cline x1='16' y1='2' x2='16' y2='6'%3E%3C/line%3E%3Cline x1='8' y1='2' x2='8' y2='6'%3E%3C/line%3E%3Cline x1='3' y1='10' x2='21' y2='10'%3E%3C/line%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-credit-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='1' y='4' width='22' height='16' rx='2' ry='2'%3E%3C/rect%3E%3Cline x1='1' y1='10' x2='23' y2='10'%3E%3C/line%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-edit-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 14.66V20a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h5.34'%3E%3C/path%3E%3Cpolygon points='18 2 22 6 12 16 8 16 8 12 18 2'%3E%3C/polygon%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-link-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6'%3E%3C/path%3E%3Cpolyline points='15 3 21 3 21 9'%3E%3C/polyline%3E%3Cline x1='10' y1='14' x2='21' y2='3'%3E%3C/line%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-help-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3'%3E%3C/path%3E%3Ccircle cx='12' cy='12' r='10'%3E%3C/circle%3E%3Cline x1='12' y1='17' x2='12' y2='17'%3E%3C/line%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-home-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 9l9-7 9 7v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z'%3E%3C/path%3E%3Cpolyline points='9 22 9 12 15 12 15 22'%3E%3C/polyline%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-info-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'%3E%3C/circle%3E%3Cline x1='12' y1='16' x2='12' y2='12'%3E%3C/line%3E%3Cline x1='12' y1='8' x2='12' y2='8'%3E%3C/line%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-lock-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='11' width='18' height='11' rx='2' ry='2'%3E%3C/rect%3E%3Cpath d='M7 11V7a5 5 0 0 1 10 0v4'%3E%3C/path%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-mail-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 4h16c1.1 0 2 .9 2 2v12c0 1.1-.9 2-2 2H4c-1.1 0-2-.9-2-2V6c0-1.1.9-2 2-2z'%3E%3C/path%3E%3Cpolyline points='22,6 12,13 2,6'%3E%3C/polyline%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-location-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 10c0 7-9 13-9 13s-9-6-9-13a9 9 0 0 1 18 0z'%3E%3C/path%3E%3Ccircle cx='12' cy='10' r='3'%3E%3C/circle%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-phone-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72 12.84 12.84 0 0 0 .7 2.81 2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45 12.84 12.84 0 0 0 2.81.7A2 2 0 0 1 22 16.92z'%3E%3C/path%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-rss-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 11a9 9 0 0 1 9 9'%3E%3C/path%3E%3Cpath d='M4 4a16 16 0 0 1 16 16'%3E%3C/path%3E%3Ccircle cx='5' cy='19' r='1'%3E%3C/circle%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-search-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='8'%3E%3C/circle%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'%3E%3C/line%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-settings-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='3'%3E%3C/circle%3E%3Cpath d='M19.4 15a1.65 1.65 0 0 0 .33 1.82l.06.06a2 2 0 0 1 0 2.83 2 2 0 0 1-2.83 0l-.06-.06a1.65 1.65 0 0 0-1.82-.33 1.65 1.65 0 0 0-1 1.51V21a2 2 0 0 1-2 2 2 2 0 0 1-2-2v-.09A1.65 1.65 0 0 0 9 19.4a1.65 1.65 0 0 0-1.82.33l-.06.06a2 2 0 0 1-2.83 0 2 2 0 0 1 0-2.83l.06-.06a1.65 1.65 0 0 0 .33-1.82 1.65 1.65 0 0 0-1.51-1H3a2 2 0 0 1-2-2 2 2 0 0 1 2-2h.09A1.65 1.65 0 0 0 4.6 9a1.65 1.65 0 0 0-.33-1.82l-.06-.06a2 2 0 0 1 0-2.83 2 2 0 0 1 2.83 0l.06.06a1.65 1.65 0 0 0 1.82.33H9a1.65 1.65 0 0 0 1-1.51V3a2 2 0 0 1 2-2 2 2 0 0 1 2 2v.09a1.65 1.65 0 0 0 1 1.51 1.65 1.65 0 0 0 1.82-.33l.06-.06a2 2 0 0 1 2.83 0 2 2 0 0 1 0 2.83l-.06.06a1.65 1.65 0 0 0-.33 1.82V9a1.65 1.65 0 0 0 1.51 1H21a2 2 0 0 1 2 2 2 2 0 0 1-2 2h-.09a1.65 1.65 0 0 0-1.51 1z'%3E%3C/path%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-share-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='18' cy='5' r='3'%3E%3C/circle%3E%3Ccircle cx='6' cy='12' r='3'%3E%3C/circle%3E%3Ccircle cx='18' cy='19' r='3'%3E%3C/circle%3E%3Cline x1='8.59' y1='13.51' x2='15.42' y2='17.49'%3E%3C/line%3E%3Cline x1='15.41' y1='6.51' x2='8.59' y2='10.49'%3E%3C/line%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-cart-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='9' cy='21' r='1'%3E%3C/circle%3E%3Ccircle cx='20' cy='21' r='1'%3E%3C/circle%3E%3Cpath d='M1 1h4l2.68 13.39a2 2 0 0 0 2 1.61h9.72a2 2 0 0 0 2-1.61L23 6H6'%3E%3C/path%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-upload-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4'%3E%3C/path%3E%3Cpolyline points='17 8 12 3 7 8'%3E%3C/polyline%3E%3Cline x1='12' y1='3' x2='12' y2='15'%3E%3C/line%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-user-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 21v-2a4 4 0 0 0-4-4H8a4 4 0 0 0-4 4v2'%3E%3C/path%3E%3Ccircle cx='12' cy='7' r='4'%3E%3C/circle%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
}
/*
Definitions for icons - powered by Feather (https://feathericons.com/).
*/
$icon-prefix: 'icon' !default; // Class name prefix for icons.
$icon-alert-name: 'alert' !default; // Class name suffix for alert icon.
$icon-bookmark-name: 'bookmark' !default; // Class name suffix for bookmark icon.
$icon-calendar-name: 'calendar' !default; // Class name suffix for calendar icon.
$icon-credit-name: 'credit' !default; // Class name suffix for credit icon.
$icon-edit-name: 'edit' !default; // Class name suffix for edit icon.
$icon-link-name: 'link' !default; // Class name suffix for link icon.
$icon-help-name: 'help' !default; // Class name suffix for help icon.
$icon-home-name: 'home' !default; // Class name suffix for home icon.
$icon-info-name: 'info' !default; // Class name suffix for info icon.
$icon-lock-name: 'lock' !default; // Class name suffix for lock icon.
$icon-mail-name: 'mail' !default; // Class name suffix for mail icon.
$icon-location-name: 'location' !default; // Class name suffix for location icon.
$icon-phone-name: 'phone' !default; // Class name suffix for phone icon.
$icon-rss-name: 'rss' !default; // Class name suffix for rss icon.
$icon-search-name: 'search' !default; // Class name suffix for search icon.
$icon-settings-name: 'settings' !default; // Class name suffix for settings icon.
$icon-share-name: 'share' !default; // Class name suffix for share icon.
$icon-cart-name: 'cart' !default; // Class name suffix for cart icon.
$icon-upload-name: 'upload' !default; // Class name suffix for upload icon.
$icon-user-name: 'user' !default; // Class name suffix for user icon.
$icon-secondary-color-name: 'secondary' !default;// Class name for secondary color icons.
$icon-inverse-color-name: 'inverse' !default; // Class name for inverse color icons.
/// Replace `$search` with `$replace` in `$string`
/// @author Hugo Giraudel
/// @param {String} $string - Initial string
/// @param {String} $search - Substring to replace
/// @param {String} $replace ('') - New value
/// @return {String} - Updated string
@function str-replace($string, $search, $replace: '') {
$index: str-index($string, $search);
@if $index {
@return str-slice($string, 1, $index - 1) + $replace + str-replace(str-slice($string, $index + str-length($search)), $search, $replace);
}
@return $string;
}
// == Uncomment below code if this module is used on its own ==
//
// $universal-margin: 0.5rem !default; // Universal margin for the most elements
// $fore-color: #111 !default; // Text & foreground color
// $universal-margin-var: '--universal-margin' !default;
// $fore-color-var: '--fore-color' !default;
// :root {
// #{$universal-margin-var}: $universal-margin;
// #{$fore-color-var}: $fore-color;
// }
//
// ============================================================
// Base styling for icons.
span[class^='#{$icon-prefix}-'] {
display: inline-block;
height: 1em;
width: 1em;
vertical-align: -0.125em; // fixes alignment issues
background-size: contain;
margin: 0 calc(var(#{$universal-margin-var}) / 4);
&.#{$icon-secondary-color-name}{
-webkit-filter: invert(25%);
filter: invert(25%);
}
&.#{$icon-inverse-color-name}{
-webkit-filter: invert(100%);
filter: invert(100%);
}
}
span{
$stroke-color: str-replace(#{$fore-color}, '#', '%23');
&.#{$icon-prefix}-#{$icon-alert-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'%3E%3C/circle%3E%3Cline x1='12' y1='8' x2='12' y2='12'%3E%3C/line%3E%3Cline x1='12' y1='16' x2='12' y2='16'%3E%3C/line%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-bookmark-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M19 21l-7-5-7 5V5a2 2 0 0 1 2-2h10a2 2 0 0 1 2 2z'%3E%3C/path%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-calendar-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='4' width='18' height='18' rx='2' ry='2'%3E%3C/rect%3E%3Cline x1='16' y1='2' x2='16' y2='6'%3E%3C/line%3E%3Cline x1='8' y1='2' x2='8' y2='6'%3E%3C/line%3E%3Cline x1='3' y1='10' x2='21' y2='10'%3E%3C/line%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-credit-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='1' y='4' width='22' height='16' rx='2' ry='2'%3E%3C/rect%3E%3Cline x1='1' y1='10' x2='23' y2='10'%3E%3C/line%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-edit-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 14.66V20a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h5.34'%3E%3C/path%3E%3Cpolygon points='18 2 22 6 12 16 8 16 8 12 18 2'%3E%3C/polygon%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-link-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6'%3E%3C/path%3E%3Cpolyline points='15 3 21 3 21 9'%3E%3C/polyline%3E%3Cline x1='10' y1='14' x2='21' y2='3'%3E%3C/line%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-help-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3'%3E%3C/path%3E%3Ccircle cx='12' cy='12' r='10'%3E%3C/circle%3E%3Cline x1='12' y1='17' x2='12' y2='17'%3E%3C/line%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-home-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 9l9-7 9 7v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z'%3E%3C/path%3E%3Cpolyline points='9 22 9 12 15 12 15 22'%3E%3C/polyline%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-info-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'%3E%3C/circle%3E%3Cline x1='12' y1='16' x2='12' y2='12'%3E%3C/line%3E%3Cline x1='12' y1='8' x2='12' y2='8'%3E%3C/line%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-lock-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='11' width='18' height='11' rx='2' ry='2'%3E%3C/rect%3E%3Cpath d='M7 11V7a5 5 0 0 1 10 0v4'%3E%3C/path%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-mail-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 4h16c1.1 0 2 .9 2 2v12c0 1.1-.9 2-2 2H4c-1.1 0-2-.9-2-2V6c0-1.1.9-2 2-2z'%3E%3C/path%3E%3Cpolyline points='22,6 12,13 2,6'%3E%3C/polyline%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-location-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 10c0 7-9 13-9 13s-9-6-9-13a9 9 0 0 1 18 0z'%3E%3C/path%3E%3Ccircle cx='12' cy='10' r='3'%3E%3C/circle%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-phone-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72 12.84 12.84 0 0 0 .7 2.81 2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45 12.84 12.84 0 0 0 2.81.7A2 2 0 0 1 22 16.92z'%3E%3C/path%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-rss-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 11a9 9 0 0 1 9 9'%3E%3C/path%3E%3Cpath d='M4 4a16 16 0 0 1 16 16'%3E%3C/path%3E%3Ccircle cx='5' cy='19' r='1'%3E%3C/circle%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-search-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='8'%3E%3C/circle%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'%3E%3C/line%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-settings-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='3'%3E%3C/circle%3E%3Cpath d='M19.4 15a1.65 1.65 0 0 0 .33 1.82l.06.06a2 2 0 0 1 0 2.83 2 2 0 0 1-2.83 0l-.06-.06a1.65 1.65 0 0 0-1.82-.33 1.65 1.65 0 0 0-1 1.51V21a2 2 0 0 1-2 2 2 2 0 0 1-2-2v-.09A1.65 1.65 0 0 0 9 19.4a1.65 1.65 0 0 0-1.82.33l-.06.06a2 2 0 0 1-2.83 0 2 2 0 0 1 0-2.83l.06-.06a1.65 1.65 0 0 0 .33-1.82 1.65 1.65 0 0 0-1.51-1H3a2 2 0 0 1-2-2 2 2 0 0 1 2-2h.09A1.65 1.65 0 0 0 4.6 9a1.65 1.65 0 0 0-.33-1.82l-.06-.06a2 2 0 0 1 0-2.83 2 2 0 0 1 2.83 0l.06.06a1.65 1.65 0 0 0 1.82.33H9a1.65 1.65 0 0 0 1-1.51V3a2 2 0 0 1 2-2 2 2 0 0 1 2 2v.09a1.65 1.65 0 0 0 1 1.51 1.65 1.65 0 0 0 1.82-.33l.06-.06a2 2 0 0 1 2.83 0 2 2 0 0 1 0 2.83l-.06.06a1.65 1.65 0 0 0-.33 1.82V9a1.65 1.65 0 0 0 1.51 1H21a2 2 0 0 1 2 2 2 2 0 0 1-2 2h-.09a1.65 1.65 0 0 0-1.51 1z'%3E%3C/path%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-share-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='18' cy='5' r='3'%3E%3C/circle%3E%3Ccircle cx='6' cy='12' r='3'%3E%3C/circle%3E%3Ccircle cx='18' cy='19' r='3'%3E%3C/circle%3E%3Cline x1='8.59' y1='13.51' x2='15.42' y2='17.49'%3E%3C/line%3E%3Cline x1='15.41' y1='6.51' x2='8.59' y2='10.49'%3E%3C/line%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-cart-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='9' cy='21' r='1'%3E%3C/circle%3E%3Ccircle cx='20' cy='21' r='1'%3E%3C/circle%3E%3Cpath d='M1 1h4l2.68 13.39a2 2 0 0 0 2 1.61h9.72a2 2 0 0 0 2-1.61L23 6H6'%3E%3C/path%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-upload-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4'%3E%3C/path%3E%3Cpolyline points='17 8 12 3 7 8'%3E%3C/polyline%3E%3Cline x1='12' y1='3' x2='12' y2='15'%3E%3C/line%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
&.#{$icon-prefix}-#{$icon-user-name}{
background-image: #{str-replace("url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 21v-2a4 4 0 0 0-4-4H8a4 4 0 0 0-4 4v2'%3E%3C/path%3E%3Ccircle cx='12' cy='7' r='4'%3E%3C/circle%3E%3C/svg%3E\")",'currentColor',$stroke-color)};
}
}

View file

@ -1,317 +1,317 @@
/*
Definitions for forms and input elements.
*/
// Different elements are styled based on the same set of rules.
$input-group-name: 'input-group' !default; // Class name for input groups.
$_include-fluid-input-group: true !default; // [Hidden] Should fluid input groups be included? (boolean)
$input-group-fluid-name: 'fluid' !default; // Class name for fluid input groups.
$input-group-vertical-name: 'vertical' !default; // Class name for vertical input groups.
$input-group-mobile-breakpoint: 767px !default; // Breakpoint for fluid input group mobile view.
$button-class-name: 'button' !default; // Class name for elements styled as buttons.
$input-disabled-opacity: 0.75 !default; // Opacity for input elements when disabled.
$button-group-name: 'button-group' !default; // Class name for button groups.
$button-group-mobile-breakpoint: 767px !default; // Mobile breakpoint for button groups.
$form-back-color: #f0f0f0 !default; // Background color for forms.
$form-fore-color: #111 !default; // Text color for forms.
$form-border-color: #ddd !default; // Border color for forms.
$input-back-color: #f8f8f8 !default; // Background color for input elements.
$input-fore-color: #111 !default; // Text color for input elements.
$input-border-color: #ddd !default; // Border color for input elements.
$input-focus-color: #0288d1 !default; // Border color for focused input elements.
$input-invalid-color: #d32f2f !default; // Border color for invalid input elements.
$button-back-color: #e2e2e2 !default; // Background color for buttons.
$button-hover-back-color: #dcdcdc !default; // Background color for buttons (hover).
$button-fore-color: #212121 !default; // Text color for buttons.
$button-border-color: transparent !default; // Border color for buttons.
$button-hover-border-color: transparent !default; // Border color for buttons (hover).
$button-group-border-color: rgba(124,124,124, 0.54) !default; // Border color for button groups.
// CSS variable name definitions [exercise caution if modifying these]
$form-back-color-var: '--form-back-color' !default;
$form-fore-color-var: '--form-fore-color' !default;
$form-border-color-var: '--form-border-color' !default;
$input-back-color-var: '--input-back-color' !default;
$input-fore-color-var: '--input-fore-color' !default;
$input-border-color-var: '--input-border-color' !default;
$input-focus-color-var: '--input-focus-color' !default;
$input-invalid-color-var: '--input-invalid-color' !default;
$button-back-color-var: '--button-back-color' !default;
$button-hover-back-color-var: '--button-hover-back-color' !default;
$button-fore-color-var: '--button-fore-color' !default;
$button-border-color-var: '--button-border-color' !default;
$button-hover-border-color-var: '--button-hover-border-color' !default;
$button-group-border-color-var: '--button-group-border-color' !default;
// == Uncomment below code if this module is used on its own ==
//
// $base-font-size: 1rem !default; // Font sizing for all elements
// $universal-margin: 0.5rem !default; // Universal margin for the most elements
// $universal-padding: 0.5rem !default; // Universal padding for the most elements
// $universal-border-radius: 0.125rem !default; // Universal border-radius for most elements
// $universal-box-shadow: none !default; // Universal box-shadow for most elements
// $universal-margin-var: '--universal-margin' !default;
// $universal-padding-var: '--universal-padding' !default;
// $universal-border-radius-var: '--universal-border-radius' !default;
// $universal-box-shadow-var: '--universal-box-shadow' !default;
// :root {
// #{$universal-margin-var}: $universal-margin;
// #{$universal-padding-var}: $universal-padding;
// #{$universal-border-radius-var}: $universal-border-radius;
// @if $universal-box-shadow != none {
// #{$universal-box-shadow-var}: $universal-box-shadow;
// }
// }
//
// ============================================================
// Check the `_input_control_mixins.scss` file to find this module's mixins.
@import 'input_control_mixins';
/* Input_control module CSS variable definitions */
:root {
#{$form-back-color-var}: $form-back-color;
#{$form-fore-color-var}: $form-fore-color;
#{$form-border-color-var}: $form-border-color;
#{$input-back-color-var}: $input-back-color;
#{$input-fore-color-var}: $input-fore-color;
#{$input-border-color-var}: $input-border-color;
#{$input-focus-color-var}: $input-focus-color;
#{$input-invalid-color-var}: $input-invalid-color;
#{$button-back-color-var}: $button-back-color;
#{$button-hover-back-color-var}: $button-hover-back-color;
#{$button-fore-color-var}: $button-fore-color;
#{$button-border-color-var}: $button-border-color;
#{$button-hover-border-color-var}: $button-hover-border-color;
#{$button-group-border-color-var}: $button-group-border-color;
}
// Base form styling
form { // Text color is the default, this can be changed manually.
background: var(#{$form-back-color-var});
color: var(#{$form-fore-color-var});
border: $__1px solid var(#{$form-border-color-var});
border-radius: var(#{$universal-border-radius-var});
margin: var(#{$universal-margin-var});
padding: calc(2 * var(#{$universal-padding-var})) var(#{$universal-padding-var});
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
}
// Fieldset styling
fieldset {
// Apply always to overwrite defaults for all of the below.
border: $__1px solid var(#{$form-border-color-var});
border-radius: var(#{$universal-border-radius-var});
margin: calc(var(#{$universal-margin-var}) / 4);
padding: var(#{$universal-padding-var});
}
// Legend styling.
legend {
// Edge fixes.
box-sizing: border-box;
display: table;
max-width: 100%;
white-space: normal;
// Actual styling.
font-weight: $bold-font-weight;
padding: calc(var(#{$universal-padding-var}) / 2);
}
// Label syling. - Basically just padding, but there might be more in the future.
label {
padding: calc(var(#{$universal-padding-var}) / 2) var(#{$universal-padding-var});
}
// Input group styling.
.#{$input-group-name} {
display: inline-block;
// Fluid input groups
@if $_include-fluid-input-group {
&.#{$input-group-fluid-name} {
display: flex;
align-items: center;
justify-content: center;
& > input {
max-width: 100%;
flex-grow: 1;
flex-basis: 0px;
}
// On mobile
@media screen and (max-width: #{$input-group-mobile-breakpoint}) {
align-items: stretch;
flex-direction: column;
}
}
// Vertical input groups
&.#{$input-group-vertical-name} {
display: flex;
align-items: stretch;
flex-direction: column;
& > input {
max-width: 100%;
flex-grow: 1;
flex-basis: 0px;
}
}
}
}
// Correct the cursor style of increment and decrement buttons in Chrome.
[type="number"]::-webkit-inner-spin-button, [type="number"]::-webkit-outer-spin-button {
height: auto;
}
// Correct style in Chrome and Safari.
[type="search"] {
-webkit-appearance: textfield;
outline-offset: -2px;
}
// Correct style in Chrome and Safari.
[type="search"]::-webkit-search-cancel-button,
[type="search"]::-webkit-search-decoration {
-webkit-appearance: none;
}
// Common textual input styling. - Avoid using box-shadow with these.
input:not([type]), [type="text"], [type="email"], [type="number"], [type="search"],
[type="password"], [type="url"], [type="tel"], [type="checkbox"], [type="radio"], textarea, select {
box-sizing: border-box;
// Background, color and border should not be unassigned, as the browser defaults will apply.
background: var(#{$input-back-color-var});
color: var(#{$input-fore-color-var});
border: $__1px solid var(#{$input-border-color-var});
border-radius: var(#{$universal-border-radius-var});
margin: calc(var(#{$universal-margin-var}) / 2);
padding: var(#{$universal-padding-var}) calc(1.5 * var(#{$universal-padding-var}));
}
// Hover, focus, disabled, readonly, invalid styling for common textual inputs.
input:not([type="button"]):not([type="submit"]):not([type="reset"]), textarea, select {
&:hover, &:focus {
border-color: var(#{$input-focus-color-var});
box-shadow: none;
}
&:invalid, &:focus:invalid{
border-color: var(#{$input-invalid-color-var});
box-shadow: none;
}
&[readonly]{
background: var(#{$secondary-back-color-var});
}
}
// Fix for select and option elements overflowing their parent container.
select {
max-width: 100%;
}
option {
overflow: hidden;
text-overflow: ellipsis;
}
// Styling for checkboxes and radio buttons.
[type="checkbox"], [type="radio"] {
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
position: relative;
height: calc(#{$base-font-size} + var(#{$universal-padding-var}) / 2);
width: calc(#{$base-font-size} + var(#{$universal-padding-var}) / 2);
vertical-align: text-bottom;
padding: 0; // Remove padding added from previous styles.
flex-basis: calc(#{$base-font-size} + var(#{$universal-padding-var}) / 2) !important; // Override fluid input-group styling.
flex-grow: 0 !important; // Using with fluid input-groups is not recommended.
&:checked:before {
position: absolute;
}
}
[type="checkbox"] {
&:checked:before {
content: '\2713';
font-family: sans-serif;
font-size: calc(#{$base-font-size} + var(#{$universal-padding-var}) / 2);
top: calc(0rem - var(#{$universal-padding-var}));
left: calc(var(#{$universal-padding-var}) / 4);
}
}
[type="radio"] {
border-radius: 100%;
&:checked:before {
border-radius: 100%;
content: '';
top: calc(#{$__1px} + var(#{$universal-padding-var}) / 2);
left: calc(#{$__1px} + var(#{$universal-padding-var}) / 2);
background: var(#{$input-fore-color-var});
width: 0.5rem;
height: 0.5rem;
}
}
// Placeholder styling (keep browser-specific definitions separated, they do not play well together).
:placeholder-shown {
color: var(#{$input-fore-color-var});
}
::-ms-placeholder {
color: var(#{$input-fore-color-var});
opacity: 0.54;
}
// Definitions for the button and button-like elements.
// Different elements are styled based on the same set of rules.
// Reset for Firefox focusing on button elements.
button::-moz-focus-inner, [type="button"]::-moz-focus-inner, [type="reset"]::-moz-focus-inner, [type="submit"]::-moz-focus-inner {
border-style: none;
padding: 0;
}
// Fixes for Android 4, iOS and Safari.
button, html [type="button"], [type="reset"], [type="submit"] {
-webkit-appearance: button;
}
// Other fixes.
button {
overflow: visible; // Show the overflow in IE.
text-transform: none; // Remove inheritance of text-transform in Edge, Firefox, and IE.
}
// Default styling
button, [type="button"], [type="submit"], [type="reset"],
a.#{$button-class-name}, label.#{$button-class-name}, .#{$button-class-name},
a[role="button"], label[role="button"], [role="button"] {
display: inline-block;
background: var(#{$button-back-color-var});
color: var(#{$button-fore-color-var});
border: $__1px solid var(#{$button-border-color-var});
border-radius: var(#{$universal-border-radius-var});
padding: var(#{$universal-padding-var}) calc(1.5 * var(#{$universal-padding-var}));
margin: var(#{$universal-margin-var});
text-decoration: none;
cursor: pointer;
transition: background 0.3s;
&:hover, &:focus {
background: var(#{$button-hover-back-color-var});
border-color: var(#{$button-hover-border-color-var});
}
}
// Disabled styling for input and button elements.
input, textarea, select, button, .#{$button-class-name}, [role="button"] {
// .button[disabled] is actually higher specificity than a.button, so no need for more than that
&:disabled, &[disabled] {
cursor: not-allowed;
opacity: $input-disabled-opacity;
}
}
// Button group styling.
.#{$button-group-name} {
display: flex;
border: $__1px solid var(#{$button-group-border-color-var});
border-radius: var(#{$universal-border-radius-var});
margin: var(#{$universal-margin-var});
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
& > button, [type="button"], & > [type="submit"], & > [type="reset"],
& > .#{$button-class-name}, & > [role="button"] {
margin: 0;
max-width: 100%;
flex: 1 1 auto;
text-align: center;
border: 0;
border-radius: 0;
box-shadow: none;
}
& > :not(:first-child) {
border-left: $__1px solid var(#{$button-group-border-color-var});
}
// Responsiveness for button groups
@media screen and (max-width: #{$button-group-mobile-breakpoint}) {
flex-direction: column;
& > :not(:first-child) {
border: 0; // Reapply to remove the left border from elements.
border-top: $__1px solid var(#{$button-group-border-color-var});
}
}
}
/*
Definitions for forms and input elements.
*/
// Different elements are styled based on the same set of rules.
$input-group-name: 'input-group' !default; // Class name for input groups.
$_include-fluid-input-group: true !default; // [Hidden] Should fluid input groups be included? (boolean)
$input-group-fluid-name: 'fluid' !default; // Class name for fluid input groups.
$input-group-vertical-name: 'vertical' !default; // Class name for vertical input groups.
$input-group-mobile-breakpoint: 767px !default; // Breakpoint for fluid input group mobile view.
$button-class-name: 'button' !default; // Class name for elements styled as buttons.
$input-disabled-opacity: 0.75 !default; // Opacity for input elements when disabled.
$button-group-name: 'button-group' !default; // Class name for button groups.
$button-group-mobile-breakpoint: 767px !default; // Mobile breakpoint for button groups.
$form-back-color: #f0f0f0 !default; // Background color for forms.
$form-fore-color: #111 !default; // Text color for forms.
$form-border-color: #ddd !default; // Border color for forms.
$input-back-color: #f8f8f8 !default; // Background color for input elements.
$input-fore-color: #111 !default; // Text color for input elements.
$input-border-color: #ddd !default; // Border color for input elements.
$input-focus-color: #0288d1 !default; // Border color for focused input elements.
$input-invalid-color: #d32f2f !default; // Border color for invalid input elements.
$button-back-color: #e2e2e2 !default; // Background color for buttons.
$button-hover-back-color: #dcdcdc !default; // Background color for buttons (hover).
$button-fore-color: #212121 !default; // Text color for buttons.
$button-border-color: transparent !default; // Border color for buttons.
$button-hover-border-color: transparent !default; // Border color for buttons (hover).
$button-group-border-color: rgba(124,124,124, 0.54) !default; // Border color for button groups.
// CSS variable name definitions [exercise caution if modifying these]
$form-back-color-var: '--form-back-color' !default;
$form-fore-color-var: '--form-fore-color' !default;
$form-border-color-var: '--form-border-color' !default;
$input-back-color-var: '--input-back-color' !default;
$input-fore-color-var: '--input-fore-color' !default;
$input-border-color-var: '--input-border-color' !default;
$input-focus-color-var: '--input-focus-color' !default;
$input-invalid-color-var: '--input-invalid-color' !default;
$button-back-color-var: '--button-back-color' !default;
$button-hover-back-color-var: '--button-hover-back-color' !default;
$button-fore-color-var: '--button-fore-color' !default;
$button-border-color-var: '--button-border-color' !default;
$button-hover-border-color-var: '--button-hover-border-color' !default;
$button-group-border-color-var: '--button-group-border-color' !default;
// == Uncomment below code if this module is used on its own ==
//
// $base-font-size: 1rem !default; // Font sizing for all elements
// $universal-margin: 0.5rem !default; // Universal margin for the most elements
// $universal-padding: 0.5rem !default; // Universal padding for the most elements
// $universal-border-radius: 0.125rem !default; // Universal border-radius for most elements
// $universal-box-shadow: none !default; // Universal box-shadow for most elements
// $universal-margin-var: '--universal-margin' !default;
// $universal-padding-var: '--universal-padding' !default;
// $universal-border-radius-var: '--universal-border-radius' !default;
// $universal-box-shadow-var: '--universal-box-shadow' !default;
// :root {
// #{$universal-margin-var}: $universal-margin;
// #{$universal-padding-var}: $universal-padding;
// #{$universal-border-radius-var}: $universal-border-radius;
// @if $universal-box-shadow != none {
// #{$universal-box-shadow-var}: $universal-box-shadow;
// }
// }
//
// ============================================================
// Check the `_input_control_mixins.scss` file to find this module's mixins.
@import 'input_control_mixins';
/* Input_control module CSS variable definitions */
:root {
#{$form-back-color-var}: $form-back-color;
#{$form-fore-color-var}: $form-fore-color;
#{$form-border-color-var}: $form-border-color;
#{$input-back-color-var}: $input-back-color;
#{$input-fore-color-var}: $input-fore-color;
#{$input-border-color-var}: $input-border-color;
#{$input-focus-color-var}: $input-focus-color;
#{$input-invalid-color-var}: $input-invalid-color;
#{$button-back-color-var}: $button-back-color;
#{$button-hover-back-color-var}: $button-hover-back-color;
#{$button-fore-color-var}: $button-fore-color;
#{$button-border-color-var}: $button-border-color;
#{$button-hover-border-color-var}: $button-hover-border-color;
#{$button-group-border-color-var}: $button-group-border-color;
}
// Base form styling
form { // Text color is the default, this can be changed manually.
background: var(#{$form-back-color-var});
color: var(#{$form-fore-color-var});
border: $__1px solid var(#{$form-border-color-var});
border-radius: var(#{$universal-border-radius-var});
margin: var(#{$universal-margin-var});
padding: calc(2 * var(#{$universal-padding-var})) var(#{$universal-padding-var});
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
}
// Fieldset styling
fieldset {
// Apply always to overwrite defaults for all of the below.
border: $__1px solid var(#{$form-border-color-var});
border-radius: var(#{$universal-border-radius-var});
margin: calc(var(#{$universal-margin-var}) / 4);
padding: var(#{$universal-padding-var});
}
// Legend styling.
legend {
// Edge fixes.
box-sizing: border-box;
display: table;
max-width: 100%;
white-space: normal;
// Actual styling.
font-weight: $bold-font-weight;
padding: calc(var(#{$universal-padding-var}) / 2);
}
// Label syling. - Basically just padding, but there might be more in the future.
label {
padding: calc(var(#{$universal-padding-var}) / 2) var(#{$universal-padding-var});
}
// Input group styling.
.#{$input-group-name} {
display: inline-block;
// Fluid input groups
@if $_include-fluid-input-group {
&.#{$input-group-fluid-name} {
display: flex;
align-items: center;
justify-content: center;
& > input {
max-width: 100%;
flex-grow: 1;
flex-basis: 0px;
}
// On mobile
@media screen and (max-width: #{$input-group-mobile-breakpoint}) {
align-items: stretch;
flex-direction: column;
}
}
// Vertical input groups
&.#{$input-group-vertical-name} {
display: flex;
align-items: stretch;
flex-direction: column;
& > input {
max-width: 100%;
flex-grow: 1;
flex-basis: 0px;
}
}
}
}
// Correct the cursor style of increment and decrement buttons in Chrome.
[type="number"]::-webkit-inner-spin-button, [type="number"]::-webkit-outer-spin-button {
height: auto;
}
// Correct style in Chrome and Safari.
[type="search"] {
-webkit-appearance: textfield;
outline-offset: -2px;
}
// Correct style in Chrome and Safari.
[type="search"]::-webkit-search-cancel-button,
[type="search"]::-webkit-search-decoration {
-webkit-appearance: none;
}
// Common textual input styling. - Avoid using box-shadow with these.
input:not([type]), [type="text"], [type="email"], [type="number"], [type="search"],
[type="password"], [type="url"], [type="tel"], [type="checkbox"], [type="radio"], textarea, select {
box-sizing: border-box;
// Background, color and border should not be unassigned, as the browser defaults will apply.
background: var(#{$input-back-color-var});
color: var(#{$input-fore-color-var});
border: $__1px solid var(#{$input-border-color-var});
border-radius: var(#{$universal-border-radius-var});
margin: calc(var(#{$universal-margin-var}) / 2);
padding: var(#{$universal-padding-var}) calc(1.5 * var(#{$universal-padding-var}));
}
// Hover, focus, disabled, readonly, invalid styling for common textual inputs.
input:not([type="button"]):not([type="submit"]):not([type="reset"]), textarea, select {
&:hover, &:focus {
border-color: var(#{$input-focus-color-var});
box-shadow: none;
}
&:invalid, &:focus:invalid{
border-color: var(#{$input-invalid-color-var});
box-shadow: none;
}
&[readonly]{
background: var(#{$secondary-back-color-var});
}
}
// Fix for select and option elements overflowing their parent container.
select {
max-width: 100%;
}
option {
overflow: hidden;
text-overflow: ellipsis;
}
// Styling for checkboxes and radio buttons.
[type="checkbox"], [type="radio"] {
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
position: relative;
height: calc(#{$base-font-size} + var(#{$universal-padding-var}) / 2);
width: calc(#{$base-font-size} + var(#{$universal-padding-var}) / 2);
vertical-align: text-bottom;
padding: 0; // Remove padding added from previous styles.
flex-basis: calc(#{$base-font-size} + var(#{$universal-padding-var}) / 2) !important; // Override fluid input-group styling.
flex-grow: 0 !important; // Using with fluid input-groups is not recommended.
&:checked:before {
position: absolute;
}
}
[type="checkbox"] {
&:checked:before {
content: '\2713';
font-family: sans-serif;
font-size: calc(#{$base-font-size} + var(#{$universal-padding-var}) / 2);
top: calc(0rem - var(#{$universal-padding-var}));
left: calc(var(#{$universal-padding-var}) / 4);
}
}
[type="radio"] {
border-radius: 100%;
&:checked:before {
border-radius: 100%;
content: '';
top: calc(#{$__1px} + var(#{$universal-padding-var}) / 2);
left: calc(#{$__1px} + var(#{$universal-padding-var}) / 2);
background: var(#{$input-fore-color-var});
width: 0.5rem;
height: 0.5rem;
}
}
// Placeholder styling (keep browser-specific definitions separated, they do not play well together).
:placeholder-shown {
color: var(#{$input-fore-color-var});
}
::-ms-placeholder {
color: var(#{$input-fore-color-var});
opacity: 0.54;
}
// Definitions for the button and button-like elements.
// Different elements are styled based on the same set of rules.
// Reset for Firefox focusing on button elements.
button::-moz-focus-inner, [type="button"]::-moz-focus-inner, [type="reset"]::-moz-focus-inner, [type="submit"]::-moz-focus-inner {
border-style: none;
padding: 0;
}
// Fixes for Android 4, iOS and Safari.
button, html [type="button"], [type="reset"], [type="submit"] {
-webkit-appearance: button;
}
// Other fixes.
button {
overflow: visible; // Show the overflow in IE.
text-transform: none; // Remove inheritance of text-transform in Edge, Firefox, and IE.
}
// Default styling
button, [type="button"], [type="submit"], [type="reset"],
a.#{$button-class-name}, label.#{$button-class-name}, .#{$button-class-name},
a[role="button"], label[role="button"], [role="button"] {
display: inline-block;
background: var(#{$button-back-color-var});
color: var(#{$button-fore-color-var});
border: $__1px solid var(#{$button-border-color-var});
border-radius: var(#{$universal-border-radius-var});
padding: var(#{$universal-padding-var}) calc(1.5 * var(#{$universal-padding-var}));
margin: var(#{$universal-margin-var});
text-decoration: none;
cursor: pointer;
transition: background 0.3s;
&:hover, &:focus {
background: var(#{$button-hover-back-color-var});
border-color: var(#{$button-hover-border-color-var});
}
}
// Disabled styling for input and button elements.
input, textarea, select, button, .#{$button-class-name}, [role="button"] {
// .button[disabled] is actually higher specificity than a.button, so no need for more than that
&:disabled, &[disabled] {
cursor: not-allowed;
opacity: $input-disabled-opacity;
}
}
// Button group styling.
.#{$button-group-name} {
display: flex;
border: $__1px solid var(#{$button-group-border-color-var});
border-radius: var(#{$universal-border-radius-var});
margin: var(#{$universal-margin-var});
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
& > button, [type="button"], & > [type="submit"], & > [type="reset"],
& > .#{$button-class-name}, & > [role="button"] {
margin: 0;
max-width: 100%;
flex: 1 1 auto;
text-align: center;
border: 0;
border-radius: 0;
box-shadow: none;
}
& > :not(:first-child) {
border-left: $__1px solid var(#{$button-group-border-color-var});
}
// Responsiveness for button groups
@media screen and (max-width: #{$button-group-mobile-breakpoint}) {
flex-direction: column;
& > :not(:first-child) {
border: 0; // Reapply to remove the left border from elements.
border-top: $__1px solid var(#{$button-group-border-color-var});
}
}
}

View file

@ -1,46 +1,46 @@
// Input_control module's mixin definitions are here. For the module itself
// check `_input_control.scss`.
// Button color variant mixin:
// $button-alt-name: The name of the class used for the button variant.
// $button-alt-back-color: Background color for button variant.
// $button-alt-hover-back-color: Background color for button variant (hover).
// $button-alt-fore-color: Text color for button variant.
// $button-alt-border-color: Border color for button variant.
// $button-alt-hover-border-color: Border color for button variant (hover).
@mixin make-button-alt-color ($button-alt-name, $button-alt-back-color : $button-back-color,
$button-alt-hover-back-color : $button-hover-back-color, $button-alt-fore-color : $button-fore-color,
$button-alt-border-color : $button-border-color, $button-alt-hover-border-color : $button-hover-border-color) {
button, [type="button"], [type="submit"], [type="reset"], .#{$button-class-name}, [role="button"] {
&.#{$button-alt-name} {
@if $button-alt-back-color != $button-back-color {
#{$button-back-color-var}: $button-alt-back-color;
}
@if $button-alt-fore-color != $button-fore-color{
#{$button-fore-color-var}: $button-alt-fore-color;
}
@if $button-alt-border-color != $button-border-color{
#{$button-border-color-var}: $button-alt-border-color;
}
&:hover, &:focus {
@if $button-alt-hover-back-color != $button-hover-back-color{
#{$button-hover-back-color-var}: $button-alt-hover-back-color;
}
@if $button-alt-hover-border-color != $button-hover-border-color{
#{$button-hover-border-color-var}: $button-alt-hover-border-color;
}
}
}
}
}
// Button size variant mixin:
// $button-alt-name: The name of the class used for the button variant.
// $button-alt-padding: The padding of the button variant.
// $button-alt-margin The margin of the button variant.
@mixin make-button-alt-size ($button-alt-name, $button-alt-padding, $button-alt-margin) {
button, [type="button"], [type="submit"], [type="reset"], .#{$button-class-name}, [role="button"] {
&.#{$button-alt-name} {
padding: $button-alt-padding;
margin: $button-alt-margin;
}
}
}
// Input_control module's mixin definitions are here. For the module itself
// check `_input_control.scss`.
// Button color variant mixin:
// $button-alt-name: The name of the class used for the button variant.
// $button-alt-back-color: Background color for button variant.
// $button-alt-hover-back-color: Background color for button variant (hover).
// $button-alt-fore-color: Text color for button variant.
// $button-alt-border-color: Border color for button variant.
// $button-alt-hover-border-color: Border color for button variant (hover).
@mixin make-button-alt-color ($button-alt-name, $button-alt-back-color : $button-back-color,
$button-alt-hover-back-color : $button-hover-back-color, $button-alt-fore-color : $button-fore-color,
$button-alt-border-color : $button-border-color, $button-alt-hover-border-color : $button-hover-border-color) {
button, [type="button"], [type="submit"], [type="reset"], .#{$button-class-name}, [role="button"] {
&.#{$button-alt-name} {
@if $button-alt-back-color != $button-back-color {
#{$button-back-color-var}: $button-alt-back-color;
}
@if $button-alt-fore-color != $button-fore-color{
#{$button-fore-color-var}: $button-alt-fore-color;
}
@if $button-alt-border-color != $button-border-color{
#{$button-border-color-var}: $button-alt-border-color;
}
&:hover, &:focus {
@if $button-alt-hover-back-color != $button-hover-back-color{
#{$button-hover-back-color-var}: $button-alt-hover-back-color;
}
@if $button-alt-hover-border-color != $button-hover-border-color{
#{$button-hover-border-color-var}: $button-alt-hover-border-color;
}
}
}
}
}
// Button size variant mixin:
// $button-alt-name: The name of the class used for the button variant.
// $button-alt-padding: The padding of the button variant.
// $button-alt-margin The margin of the button variant.
@mixin make-button-alt-size ($button-alt-name, $button-alt-padding, $button-alt-margin) {
button, [type="button"], [type="submit"], [type="reset"], .#{$button-class-name}, [role="button"] {
&.#{$button-alt-name} {
padding: $button-alt-padding;
margin: $button-alt-margin;
}
}
}

View file

@ -1,199 +1,199 @@
/*
Definitions for the grid system, cards and containers.
*/
// The grid system uses the flexbox module, meaning it might be incompatible with certain browsers.
$_include-parent-layout: true !default; // [Hidden] Flag for rows defining column layouts (`true`/`false`).
$grid-column-count: 12 !default; // Number of columns in the grid (integer value only).
$grid-container-name: 'container' !default; // Class name for the grid system container.
$grid-row-name: 'row' !default; // Class name for the grid system rows.
$grid-row-parent-layout-prefix:'cols' !default; // Class name prefix for the grid's row parents.
$grid-column-prefix: 'col' !default; // Class name prefix for the grid's columns.
$grid-column-offset-suffix: 'offset' !default; // Class name suffix for the grid's offsets.
$grid-order-normal-suffix: 'normal' !default; // Class name suffix for grid columns with normal priority.
$grid-order-first-suffix: 'first' !default; // Class name suffix for grid columns with highest priority.
$grid-order-last-suffix: 'last' !default; // Class name suffix for grid columns with lowest priorty.
$grid-small-prefix: 'sm' !default; // Small screen class prefix for grid.
$grid-medium-prefix: 'md' !default; // Medium screen class prefix for grid.
$grid-large-prefix: 'lg' !default; // Large screen class prefix for grid.
$grid-medium-breakpoint: 768px !default; // Medium screen breakpoint for grid.
$grid-large-breakpoint: 1280px !default; // Large screen breakpoint for grid.
$card-name: 'card' !default; // Class name for the cards.
$card-section-name: 'section' !default; // Class name for the cards' sections.
$card-section-media-name: 'media' !default; // Class name for the cards' sections (media cotent).
$card-normal-width: 320px !default; // Width for normal cards.
$card-section-media-height: 200px !default; // Height for cards' media sections.
$card-fore-color: #111 !default; // Text color for the cards.
$card-back-color: #f8f8f8 !default; // Background color for the cards.
$card-border-color: #ddd !default; // Border color for the cards.
// CSS variable name definitions [exercise caution if modifying these]
$card-fore-color-var: '--card-fore-color' !default;
$card-back-color-var: '--card-back-color' !default;
$card-border-color-var: '--card-border-color' !default;
// == Uncomment below code if this module is used on its own ==
//
// $universal-margin: 0.5rem !default; // Universal margin for the most elements
// $universal-padding: 0.5rem !default; // Universal padding for the most elements
// $universal-border-radius: 0.125rem !default; // Universal border-radius for most elements
// $universal-box-shadow: none !default; // Universal box-shadow for most elements
// $universal-margin-var: '--universal-margin' !default;
// $universal-padding-var: '--universal-padding' !default;
// $universal-border-radius-var: '--universal-border-radius' !default;
// $universal-box-shadow-var: '--universal-box-shadow' !default;
// :root {
// #{$universal-margin-var}: $universal-margin;
// #{$universal-padding-var}: $universal-padding;
// #{$universal-border-radius-var}: $universal-border-radius;
// @if $universal-box-shadow != none {
// #{$universal-box-shadow-var}: $universal-box-shadow;
// }
// }
//
// ============================================================
// Check the `_layout_mixins.scss` file to find this module's mixins.
@import 'layout_mixins';
// Fluid grid system container definition.
.#{$grid-container-name} {
margin: 0 auto;
padding: 0 calc(1.5 * var(#{$universal-padding-var}));
}
// Grid row definition.
.#{$grid-row-name} {
box-sizing: border-box;
display: flex;
flex: 0 1 auto;
flex-flow: row wrap;
}
// Inline mixin, used to generate class definitions for each grid step.
@mixin generate-grid-size ($size-prefix){
@if $_include-parent-layout {
.#{$grid-column-prefix}-#{$size-prefix},
[class^='#{$grid-column-prefix}-#{$size-prefix}-'],
[class^='#{$grid-column-prefix}-#{$size-prefix}-#{$grid-column-offset-suffix}-'],
.#{$grid-row-name}[class*='#{$grid-row-parent-layout-prefix}-#{$size-prefix}-'] > * {
box-sizing: border-box;
flex: 0 0 auto;
padding: 0 calc(var(#{$universal-padding-var}) / 2);
}
// Grid column specific definition for flexible column.
.#{$grid-column-prefix}-#{$size-prefix},
.#{$grid-row-name}.#{$grid-row-parent-layout-prefix}-#{$size-prefix} > * {
max-width: 100%;
flex-grow: 1;
flex-basis: 0;
}
}
@else {
// Grid column generic definitions.
.#{$grid-column-prefix}-#{$size-prefix},
[class^='#{$grid-column-prefix}-#{$size-prefix}-'],
[class^='#{$grid-column-prefix}-#{$size-prefix}-#{$grid-column-offset-suffix}-'] {
flex: 0 0 auto;
padding: 0 calc(var(#{$universal-padding-var}) / 2);
}
// Grid column specific definition for flexible column.
.#{$grid-column-prefix}-#{$size-prefix} {
max-width: 100%;
flex-grow: 1;
flex-basis: 0;
}
}
// Grid column specific definitions for predefined columns.
@for $i from 1 through $grid-column-count {
@if $_include-parent-layout {
.#{$grid-column-prefix}-#{$size-prefix}-#{$i},
.#{$grid-row-name}.#{$grid-row-parent-layout-prefix}-#{$size-prefix}-#{$i} > * {
max-width: #{($i * 100% / $grid-column-count)};
flex-basis: #{($i * 100% / $grid-column-count)};
}
}
@else {
.#{$grid-column-prefix}-#{$size-prefix}-#{$i} {
max-width: #{($i * 100% / $grid-column-count)};
flex-basis: #{($i * 100% / $grid-column-count)};
}
}
// Offest definitions.
.#{$grid-column-prefix}-#{$size-prefix}-#{$grid-column-offset-suffix}-#{($i - 1)} {
@if ($i - 1) == 0 {
margin-left: 0;
}
@else {
margin-left: #{(($i - 1) * 100% / $grid-column-count)};
}
}
}
// Reordering definitions.
.#{$grid-column-prefix}-#{$size-prefix}-#{$grid-order-normal-suffix} {
order: initial;
}
.#{$grid-column-prefix}-#{$size-prefix}-#{$grid-order-first-suffix} {
order: -999;
}
.#{$grid-column-prefix}-#{$size-prefix}-#{$grid-order-last-suffix} {
order: 999;
}
}
// Definitions for smaller screens.
@include generate-grid-size($grid-small-prefix);
// Definitions for medium screens.
@media screen and (min-width: #{$grid-medium-breakpoint}){
@include generate-grid-size($grid-medium-prefix);
}
// Definitions for large screens.
@media screen and (min-width: #{$grid-large-breakpoint}){
@include generate-grid-size($grid-large-prefix);
}
/* Card component CSS variable definitions */
:root {
#{$card-back-color-var}: $card-back-color;
#{$card-fore-color-var}: $card-fore-color;
#{$card-border-color-var}: $card-border-color;
}
// Card styling
.#{$card-name} {
// New syntax
display: flex;
flex-direction: column;
justify-content: space-between;
align-self: center;
position: relative;
width: 100%;
// Actual styling for the cards
background: var(#{$card-back-color-var});
color: var(#{$card-fore-color-var});
border: $__1px solid var(#{$card-border-color-var});
border-radius: var(#{$universal-border-radius-var});
margin: var(#{$universal-margin-var});
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
overflow: hidden; // Hide overflow from section borders
// Responsiveness (if the screen is larger than card, set max-width)
@media screen and (min-width: #{$card-normal-width}) {
max-width: $card-normal-width;
}
// Card sections
& > .#{$card-section-name} {
// Reapply background and foreground colors, so that mixins can be applied properly.
background: var(#{$card-back-color-var});
color: var(#{$card-fore-color-var});
box-sizing: border-box;
margin: 0;
border: 0; // Clean borders and radiuses for any element-based sections
border-radius: 0; // Clean borders and radiuses for any element-based sections
border-bottom: $__1px solid var(#{$card-border-color-var});
padding: var(#{$universal-padding-var});
width: 100%;
// Card media sections
&.#{$card-section-media-name} {
height: $card-section-media-height;
padding: 0;
-o-object-fit: cover;
object-fit: cover;
}
}
// Card sections - last
& > .#{$card-section-name}:last-child {
border-bottom: 0; // Clean the extra border for last section
}
}
/*
Definitions for the grid system, cards and containers.
*/
// The grid system uses the flexbox module, meaning it might be incompatible with certain browsers.
$_include-parent-layout: true !default; // [Hidden] Flag for rows defining column layouts (`true`/`false`).
$grid-column-count: 12 !default; // Number of columns in the grid (integer value only).
$grid-container-name: 'container' !default; // Class name for the grid system container.
$grid-row-name: 'row' !default; // Class name for the grid system rows.
$grid-row-parent-layout-prefix:'cols' !default; // Class name prefix for the grid's row parents.
$grid-column-prefix: 'col' !default; // Class name prefix for the grid's columns.
$grid-column-offset-suffix: 'offset' !default; // Class name suffix for the grid's offsets.
$grid-order-normal-suffix: 'normal' !default; // Class name suffix for grid columns with normal priority.
$grid-order-first-suffix: 'first' !default; // Class name suffix for grid columns with highest priority.
$grid-order-last-suffix: 'last' !default; // Class name suffix for grid columns with lowest priorty.
$grid-small-prefix: 'sm' !default; // Small screen class prefix for grid.
$grid-medium-prefix: 'md' !default; // Medium screen class prefix for grid.
$grid-large-prefix: 'lg' !default; // Large screen class prefix for grid.
$grid-medium-breakpoint: 768px !default; // Medium screen breakpoint for grid.
$grid-large-breakpoint: 1280px !default; // Large screen breakpoint for grid.
$card-name: 'card' !default; // Class name for the cards.
$card-section-name: 'section' !default; // Class name for the cards' sections.
$card-section-media-name: 'media' !default; // Class name for the cards' sections (media cotent).
$card-normal-width: 320px !default; // Width for normal cards.
$card-section-media-height: 200px !default; // Height for cards' media sections.
$card-fore-color: #111 !default; // Text color for the cards.
$card-back-color: #f8f8f8 !default; // Background color for the cards.
$card-border-color: #ddd !default; // Border color for the cards.
// CSS variable name definitions [exercise caution if modifying these]
$card-fore-color-var: '--card-fore-color' !default;
$card-back-color-var: '--card-back-color' !default;
$card-border-color-var: '--card-border-color' !default;
// == Uncomment below code if this module is used on its own ==
//
// $universal-margin: 0.5rem !default; // Universal margin for the most elements
// $universal-padding: 0.5rem !default; // Universal padding for the most elements
// $universal-border-radius: 0.125rem !default; // Universal border-radius for most elements
// $universal-box-shadow: none !default; // Universal box-shadow for most elements
// $universal-margin-var: '--universal-margin' !default;
// $universal-padding-var: '--universal-padding' !default;
// $universal-border-radius-var: '--universal-border-radius' !default;
// $universal-box-shadow-var: '--universal-box-shadow' !default;
// :root {
// #{$universal-margin-var}: $universal-margin;
// #{$universal-padding-var}: $universal-padding;
// #{$universal-border-radius-var}: $universal-border-radius;
// @if $universal-box-shadow != none {
// #{$universal-box-shadow-var}: $universal-box-shadow;
// }
// }
//
// ============================================================
// Check the `_layout_mixins.scss` file to find this module's mixins.
@import 'layout_mixins';
// Fluid grid system container definition.
.#{$grid-container-name} {
margin: 0 auto;
padding: 0 calc(1.5 * var(#{$universal-padding-var}));
}
// Grid row definition.
.#{$grid-row-name} {
box-sizing: border-box;
display: flex;
flex: 0 1 auto;
flex-flow: row wrap;
}
// Inline mixin, used to generate class definitions for each grid step.
@mixin generate-grid-size ($size-prefix){
@if $_include-parent-layout {
.#{$grid-column-prefix}-#{$size-prefix},
[class^='#{$grid-column-prefix}-#{$size-prefix}-'],
[class^='#{$grid-column-prefix}-#{$size-prefix}-#{$grid-column-offset-suffix}-'],
.#{$grid-row-name}[class*='#{$grid-row-parent-layout-prefix}-#{$size-prefix}-'] > * {
box-sizing: border-box;
flex: 0 0 auto;
padding: 0 calc(var(#{$universal-padding-var}) / 2);
}
// Grid column specific definition for flexible column.
.#{$grid-column-prefix}-#{$size-prefix},
.#{$grid-row-name}.#{$grid-row-parent-layout-prefix}-#{$size-prefix} > * {
max-width: 100%;
flex-grow: 1;
flex-basis: 0;
}
}
@else {
// Grid column generic definitions.
.#{$grid-column-prefix}-#{$size-prefix},
[class^='#{$grid-column-prefix}-#{$size-prefix}-'],
[class^='#{$grid-column-prefix}-#{$size-prefix}-#{$grid-column-offset-suffix}-'] {
flex: 0 0 auto;
padding: 0 calc(var(#{$universal-padding-var}) / 2);
}
// Grid column specific definition for flexible column.
.#{$grid-column-prefix}-#{$size-prefix} {
max-width: 100%;
flex-grow: 1;
flex-basis: 0;
}
}
// Grid column specific definitions for predefined columns.
@for $i from 1 through $grid-column-count {
@if $_include-parent-layout {
.#{$grid-column-prefix}-#{$size-prefix}-#{$i},
.#{$grid-row-name}.#{$grid-row-parent-layout-prefix}-#{$size-prefix}-#{$i} > * {
max-width: #{($i * 100% / $grid-column-count)};
flex-basis: #{($i * 100% / $grid-column-count)};
}
}
@else {
.#{$grid-column-prefix}-#{$size-prefix}-#{$i} {
max-width: #{($i * 100% / $grid-column-count)};
flex-basis: #{($i * 100% / $grid-column-count)};
}
}
// Offest definitions.
.#{$grid-column-prefix}-#{$size-prefix}-#{$grid-column-offset-suffix}-#{($i - 1)} {
@if ($i - 1) == 0 {
margin-left: 0;
}
@else {
margin-left: #{(($i - 1) * 100% / $grid-column-count)};
}
}
}
// Reordering definitions.
.#{$grid-column-prefix}-#{$size-prefix}-#{$grid-order-normal-suffix} {
order: initial;
}
.#{$grid-column-prefix}-#{$size-prefix}-#{$grid-order-first-suffix} {
order: -999;
}
.#{$grid-column-prefix}-#{$size-prefix}-#{$grid-order-last-suffix} {
order: 999;
}
}
// Definitions for smaller screens.
@include generate-grid-size($grid-small-prefix);
// Definitions for medium screens.
@media screen and (min-width: #{$grid-medium-breakpoint}){
@include generate-grid-size($grid-medium-prefix);
}
// Definitions for large screens.
@media screen and (min-width: #{$grid-large-breakpoint}){
@include generate-grid-size($grid-large-prefix);
}
/* Card component CSS variable definitions */
:root {
#{$card-back-color-var}: $card-back-color;
#{$card-fore-color-var}: $card-fore-color;
#{$card-border-color-var}: $card-border-color;
}
// Card styling
.#{$card-name} {
// New syntax
display: flex;
flex-direction: column;
justify-content: space-between;
align-self: center;
position: relative;
width: 100%;
// Actual styling for the cards
background: var(#{$card-back-color-var});
color: var(#{$card-fore-color-var});
border: $__1px solid var(#{$card-border-color-var});
border-radius: var(#{$universal-border-radius-var});
margin: var(#{$universal-margin-var});
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
overflow: hidden; // Hide overflow from section borders
// Responsiveness (if the screen is larger than card, set max-width)
@media screen and (min-width: #{$card-normal-width}) {
max-width: $card-normal-width;
}
// Card sections
& > .#{$card-section-name} {
// Reapply background and foreground colors, so that mixins can be applied properly.
background: var(#{$card-back-color-var});
color: var(#{$card-fore-color-var});
box-sizing: border-box;
margin: 0;
border: 0; // Clean borders and radiuses for any element-based sections
border-radius: 0; // Clean borders and radiuses for any element-based sections
border-bottom: $__1px solid var(#{$card-border-color-var});
padding: var(#{$universal-padding-var});
width: 100%;
// Card media sections
&.#{$card-section-media-name} {
height: $card-section-media-height;
padding: 0;
-o-object-fit: cover;
object-fit: cover;
}
}
// Card sections - last
& > .#{$card-section-name}:last-child {
border-bottom: 0; // Clean the extra border for last section
}
}

View file

@ -1,62 +1,62 @@
// Layout (card) module's mixin definitions are here. For the module itself
// check `_layout.scss`.
// Mixin for alternate card sizes:
// $card-alt-size-name: The name of the class used for the alternate size card.
// $card-alt-size-width: The width of the alternate size card.
@mixin make-card-alt-size ($card-alt-size-name, $card-alt-size-width) {
@if type-of($card-alt-size-width) == 'number' and unit($card-alt-size-width) == '%' {
.#{$card-name}.#{$card-alt-size-name} {
max-width: $card-alt-size-width;
width: auto;
}
}
@else {
@media screen and (min-width: #{$card-alt-size-width}) {
.#{$card-name}.#{$card-alt-size-name} {
max-width: $card-alt-size-width;
}
}
}
}
// Mixin for alternate cards (card color variants):
// $card-alt-name: The name of the class used for the alternate card.
// $card-alt-back-color: The background color of the alternate card.
// $card-alt-fore-color: The text color of the alternate card.
// $card-alt-border-color: The border style of the alternate card.
@mixin make-card-alt-color ($card-alt-name, $card-alt-back-color : $card-back-color,
$card-alt-fore-color : $card-fore-color, $card-alt-border-color : $card-border-color) {
.#{$card-name}.#{$card-alt-name} {
@if $card-alt-back-color != $card-back-color {
#{$card-back-color-var}: $card-alt-back-color;
}
@if $card-alt-fore-color != $card-fore-color {
#{$card-fore-color-var}: $card-alt-fore-color;
}
@if $card-alt-border-color != $card-border-color {
#{$card-border-color-var}: $card-alt-border-color;
}
}
}
// Mixin for alternate card sections (card section color variants):
// $card-section-alt-name: The name of the class used for the alternate card section.
// $card-section-alt-back-color: The background color of the alternate card section.
// $card-section-alt-fore-color: The text color of the alternate card section.
@mixin make-card-section-alt-color ($card-section-alt-name, $card-section-alt-back-color : $card-back-color,
$card-section-alt-fore-color : $card-fore-color) {
.#{$card-name} > .#{$card-section-name}.#{$card-section-alt-name} {
@if $card-section-alt-back-color != $card-back-color {
#{$card-back-color-var}: $card-section-alt-back-color;
}
@if $card-section-alt-fore-color != $card-fore-color {
#{$card-fore-color-var}: $card-section-alt-fore-color;
}
}
}
// Mixin for alternate card sections (card section padding variants):
// $card-section-alt-name: The name of the class used for the alternate card section.
// $card-section-alt-padding: The padding of the alternate card section.
@mixin make-card-section-alt-style ($card-section-alt-name, $card-section-alt-padding) {
.#{$card-name} > .#{$card-section-name}.#{$card-section-alt-name} {
padding: $card-section-alt-padding;
}
}
// Layout (card) module's mixin definitions are here. For the module itself
// check `_layout.scss`.
// Mixin for alternate card sizes:
// $card-alt-size-name: The name of the class used for the alternate size card.
// $card-alt-size-width: The width of the alternate size card.
@mixin make-card-alt-size ($card-alt-size-name, $card-alt-size-width) {
@if type-of($card-alt-size-width) == 'number' and unit($card-alt-size-width) == '%' {
.#{$card-name}.#{$card-alt-size-name} {
max-width: $card-alt-size-width;
width: auto;
}
}
@else {
@media screen and (min-width: #{$card-alt-size-width}) {
.#{$card-name}.#{$card-alt-size-name} {
max-width: $card-alt-size-width;
}
}
}
}
// Mixin for alternate cards (card color variants):
// $card-alt-name: The name of the class used for the alternate card.
// $card-alt-back-color: The background color of the alternate card.
// $card-alt-fore-color: The text color of the alternate card.
// $card-alt-border-color: The border style of the alternate card.
@mixin make-card-alt-color ($card-alt-name, $card-alt-back-color : $card-back-color,
$card-alt-fore-color : $card-fore-color, $card-alt-border-color : $card-border-color) {
.#{$card-name}.#{$card-alt-name} {
@if $card-alt-back-color != $card-back-color {
#{$card-back-color-var}: $card-alt-back-color;
}
@if $card-alt-fore-color != $card-fore-color {
#{$card-fore-color-var}: $card-alt-fore-color;
}
@if $card-alt-border-color != $card-border-color {
#{$card-border-color-var}: $card-alt-border-color;
}
}
}
// Mixin for alternate card sections (card section color variants):
// $card-section-alt-name: The name of the class used for the alternate card section.
// $card-section-alt-back-color: The background color of the alternate card section.
// $card-section-alt-fore-color: The text color of the alternate card section.
@mixin make-card-section-alt-color ($card-section-alt-name, $card-section-alt-back-color : $card-back-color,
$card-section-alt-fore-color : $card-fore-color) {
.#{$card-name} > .#{$card-section-name}.#{$card-section-alt-name} {
@if $card-section-alt-back-color != $card-back-color {
#{$card-back-color-var}: $card-section-alt-back-color;
}
@if $card-section-alt-fore-color != $card-fore-color {
#{$card-fore-color-var}: $card-section-alt-fore-color;
}
}
}
// Mixin for alternate card sections (card section padding variants):
// $card-section-alt-name: The name of the class used for the alternate card section.
// $card-section-alt-padding: The padding of the alternate card section.
@mixin make-card-section-alt-style ($card-section-alt-name, $card-section-alt-padding) {
.#{$card-name} > .#{$card-section-name}.#{$card-section-alt-name} {
padding: $card-section-alt-padding;
}
}

View file

@ -1,315 +1,315 @@
/*
Definitions for navigation elements.
*/
// Different elements are styled based on the same set of rules.
$header-height: 3.1875rem !default; // Height of the header element.
$header-back-color: #f8f8f8 !default; // Background color for the header element.
$header-hover-back-color: #f0f0f0 !default; // Background color for the header element (hover).
$header-fore-color: #444 !default; // Text color for the header element.
$header-border-color: #ddd !default; // Border color for the header element.
$nav-back-color: #f8f8f8 !default; // Background color for the nav element.
$nav-hover-back-color: #f0f0f0 !default; // Background color for the nav element (hover).
$nav-fore-color: #444 !default; // Text color for the nav element.
$nav-border-color: #ddd !default; // Border color for the nav element.
$nav-link-color: #0277bd !default; // Color for link in the nav element.
$footer-fore-color: #444 !default; // Text color for the footer element.
$footer-back-color: #f8f8f8 !default; // Background color for footer nav element.
$footer-border-color: #ddd !default; // Border color for the footer element.
$footer-link-color: #0277bd !default; // Color for link in the footer element.
$drawer-back-color: #f8f8f8 !default; // Background color for the drawer component.
$drawer-border-color: #ddd !default; // Border color for the drawer component.
$drawer-hover-back-color: #f0f0f0 !default; // Background color for the drawer component's close (hover).
$drawer-close-color: #444 !default; // Color of the close element for the drawer component.
$_header-only-bottom-border: true !default; // [Hidden] Apply styling only to the bottom border of header? (boolean)
$_header-links-uppercase: true !default; // [Hidden] Should header links and buttons be uppercase? (boolean)
$header-logo-name: 'logo' !default; // Class name for the header logo element.
$header-logo-font-size: 1.75rem !default; // Font ize for the header logo element.
$nav-sublink-prefix: 'sublink' !default; // Prefix for the subcategory tabs in nav.
$nav-sublink-depth: 2 !default; // Amount of subcategory classes to add.
$_footer-only-top-border: true !default; // [Hidden] Apply styling only to the top border of footer? (boolean)
$footer-font-size: 0.875rem !default; // Font size for text in footer element.
$sticky-name: 'sticky' !default; // Class name for sticky headers and footers.
$drawer-name: 'drawer' !default; // Class name for the drawer component.
$drawer-toggle-name: 'drawer-toggle' !default; // Class name for the drawer component's toggle.
$drawer-toggle-font-size: 1.5em !default; // Font size for the drawer component's toggle. (prefer em units)
$drawer-mobile-breakpoint: 768px !default; // Mobile breakpoint for the drawer component.
$_drawer-right: true !default; // [Hidden] Should the drawer appear on the right side of the screen?
$drawer-persistent-name: 'persistent' !default; // Class name for the persisten variant of the drawer component.
$drawer-width: 320px !default; // Width of the drawer component.
$drawer-close-name: 'drawer-close' !default; // Class name of the close element for the drawer component.
$drawer-close-size: 2rem !default; // Size of the close element for the drawer component.
$drawer-icons-color: #212121 !default; // Color for the icons used in the drawer component.
// CSS variable name definitions [exercise caution if modifying these]
$header-fore-color-var: '--header-fore-color' !default;
$header-back-color-var: '--header-back-color' !default;
$header-hover-back-color-var: '--header-hover-back-color' !default;
$header-border-color-var: '--header-border-color' !default;
$nav-fore-color-var: '--nav-fore-color' !default;
$nav-back-color-var: '--nav-back-color' !default;
$nav-hover-back-color-var: '--nav-hover-back-color' !default;
$nav-border-color-var: '--nav-border-color' !default;
$nav-link-color-var: '--nav-link-color' !default;
$footer-fore-color-var: '--footer-fore-color' !default;
$footer-back-color-var: '--footer-back-color' !default;
$footer-border-color-var: '--footer-border-color' !default;
$footer-link-color-var: '--footer-link-color' !default;
$drawer-back-color-var: '--drawer-back-color' !default;
$drawer-border-color-var: '--drawer-border-color' !default;
$drawer-hover-back-color-var: '--drawer-hover-back-color' !default;
$drawer-close-color-var: '--drawer-close-color' !default;
// == Uncomment below code if this module is used on its own ==
//
// $universal-margin: 0.5rem !default; // Universal margin for the most elements
// $universal-padding: 0.5rem !default; // Universal padding for the most elements
// $universal-border-radius: 0.125rem !default; // Universal border-radius for most elements
// $universal-box-shadow: none !default; // Universal box-shadow for most elements
// $universal-margin-var: '--universal-margin' !default;
// $universal-padding-var: '--universal-padding' !default;
// $universal-border-radius-var: '--universal-border-radius' !default;
// $universal-box-shadow-var: '--universal-box-shadow' !default;
// :root {
// #{$universal-margin-var}: $universal-margin;
// #{$universal-padding-var}: $universal-padding;
// #{$universal-border-radius-var}: $universal-border-radius;
// @if $universal-box-shadow != none {
// #{$universal-box-shadow-var}: $universal-box-shadow;
// }
// }
//
// ============================================================
/* Navigation module CSS variable definitions */
:root {
#{$header-back-color-var}: $header-back-color;
#{$header-hover-back-color-var}: $header-hover-back-color;
#{$header-fore-color-var}: $header-fore-color;
#{$header-border-color-var}: $header-border-color;
#{$nav-back-color-var}: $nav-back-color;
#{$nav-hover-back-color-var}: $nav-hover-back-color;
#{$nav-fore-color-var}: $nav-fore-color;
#{$nav-border-color-var}: $nav-border-color;
#{$nav-link-color-var}: $nav-link-color;
#{$footer-fore-color-var}: $footer-fore-color;
#{$footer-back-color-var}: $footer-back-color;
#{$footer-border-color-var}: $footer-border-color;
#{$footer-link-color-var}: $footer-link-color;
#{$drawer-back-color-var}: $drawer-back-color;
#{$drawer-hover-back-color-var}: $drawer-hover-back-color;
#{$drawer-border-color-var}: $drawer-border-color;
#{$drawer-close-color-var}: $drawer-close-color;
}
// Header styling. - No box-shadow as it causes lots of weird bugs in Chrome. No margin as it shouldn't have any.
header {
height: $header-height;
background: var(#{$header-back-color-var}); // Always apply background color to avoid shine through
color: var(#{$header-fore-color-var});
@if $_header-only-bottom-border {
border-bottom: $__1px solid var(#{$header-border-color-var});
}
@else {
border: $__1px solid var(#{$header-border-color-var});
}
padding: calc(var(#{$universal-padding-var}) / 4) 0;
// Responsiveness for smaller displays, scrolls horizontally.
white-space: nowrap;
overflow-x: auto;
overflow-y: hidden;
// Fix for responsive header, using the grid system's row and column alignment.
&.#{$grid-row-name} {
box-sizing: content-box;
}
// Header logo styling.
.#{$header-logo-name} {
color: var(#{$header-fore-color-var});
font-size: $header-logo-font-size;
padding: var(#{$universal-padding-var}) calc(2 * var(#{$universal-padding-var}));
text-decoration: none;
}
// Link styling.
button, [type="button"], .#{$button-class-name}, [role="button"] {
box-sizing: border-box;
position: relative;
top: calc(0rem - var(#{$universal-padding-var}) / 4); // Use universal-padding to offset the padding of the header.
height: calc(#{$header-height} + var(#{$universal-padding-var}) / 2); // Fill header.
background: var(#{$header-back-color-var}); // Apply color regardless to override styling from other things.
line-height: calc(#{$header-height} - var(#{$universal-padding-var}) * 1.5);
text-align: center;
color: var(#{$header-fore-color-var});
border: 0;
border-radius: 0;
margin: 0;
@if $_header-links-uppercase {
text-transform: uppercase;
}
&:hover, &:focus {
background: var(#{$header-hover-back-color-var});
}
}
}
// Navigation sidebar styling.
nav {
background: var(#{$nav-back-color-var});
color: var(#{$nav-fore-color-var});
border: $__1px solid var(#{$nav-border-color-var});
border-radius: var(#{$universal-border-radius-var});
margin: var(#{$universal-margin-var});
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
* {
padding: var(#{$universal-padding-var}) calc(1.5 * var(#{$universal-padding-var}));
}
a, a:visited {
display: block;
color: var(#{$nav-link-color-var}); // Apply regardless to de-stylize visited links.
border-radius: var(#{$universal-border-radius-var});
transition: background 0.3s;
&:hover, &:focus {
text-decoration: none;
background: var(#{$nav-hover-back-color-var});
}
}
// Subcategories in navigation.
@for $i from 1 through $nav-sublink-depth {
.#{$nav-sublink-prefix}-#{$i} {
position: relative;
margin-left: calc(#{$i * 2} * var(#{$universal-padding-var}));
&:before {
position: absolute;
left: calc(var(#{$universal-padding-var}) - #{1 + ($i - 1)*2} * var(#{$universal-padding-var}));
top: -#{$__1px};
content: '';
height: 100%;
border: $__1px solid var(#{$nav-border-color-var});
border-left: 0;
}
}
}
}
// Footer styling.
footer {
background: var(#{$footer-back-color-var}); // Always apply background color to avoid shine through
color: var(#{$footer-fore-color-var});
@if $_footer-only-top-border {
border-top: $__1px solid var(#{$footer-border-color-var});
}
@else {
border: $__1px solid var(#{$footer-border-color-var});
}
// margin: $footer-margin;
padding: calc(2 * var(#{$universal-padding-var})) var(#{$universal-padding-var});
font-size: $footer-font-size;
a, a:visited {
color: var(#{$footer-link-color-var});
}
}
// Definitions for sticky headers and footers.
header.#{$sticky-name} {
position: -webkit-sticky; // One of the rare instances where prefixes are necessary.
position: sticky;
z-index: 1101; // Deals with certain problems when combined with cards and tables.
top: 0;
}
footer.#{$sticky-name} {
position: -webkit-sticky; // One of the rare instances where prefixes are necessary.
position: sticky;
z-index: 1101; // Deals with certain problems when combined with cards and tables.
bottom: 0;
}
// Responsive drawer component.
.#{$drawer-toggle-name} {
&:before { // No color specified, should use the color of its surroundings!
display: inline-block;
position: relative;
vertical-align: bottom;
content: '\00a0\2261\00a0'; // Spaces ensure compatibility with buttons that have text and that textless buttons will have some extra padding.
font-family: sans-serif;
font-size: $drawer-toggle-font-size; // Almost hardcoded, should be fully compatible with its surroundings.
}
@media screen and (min-width: #{$drawer-mobile-breakpoint}){
&:not(.#{$drawer-persistent-name}) {
display: none;
}
}
}
[type="checkbox"].#{$drawer-name} {
height: 1px;
width: 1px;
margin: -1px;
overflow: hidden;
position: absolute;
clip: rect(0 0 0 0);
-webkit-clip-path: inset(100%);
clip-path: inset(100%);
+ * {
display: block;
box-sizing: border-box;
position: fixed;
top: 0;
width: $drawer-width;
height: 100vh;
overflow-y: auto;
background: var(#{$drawer-back-color-var});
border: $__1px solid var(#{$drawer-border-color-var});
border-radius: 0; // Set to 0 to override the value from `nav`.
margin: 0; // Set to 0 to override the value from `nav`.
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
z-index: 1110;
@if $_drawer-right {
right: -$drawer-width;
transition: right 0.3s;
}
@else {
left: -$drawer-width;
transition: left 0.3s;
}
& .#{$drawer-close-name} {
position: absolute;
top: var(#{$universal-margin-var});
right: var(#{$universal-margin-var});
z-index: 1111;
width: $drawer-close-size;
height: $drawer-close-size;
border-radius: var(#{$universal-border-radius-var});
padding: var(#{$universal-padding-var});
margin: 0; // Fixes the offset from label
cursor: pointer;
transition: background 0.3s;
&:before { // Transparent background unless hovered over. Does not block text behind it.
display: block;
content: '\00D7';
color: var(#{$drawer-close-color-var});
position: relative;
font-family: sans-serif;
font-size: $drawer-close-size;
line-height: 1; // Setting to 1 seems to center the 'X' properly.
text-align: center;
}
&:hover, &:focus {
background: var(#{$drawer-hover-back-color-var});
}
}
@media screen and (max-width: #{$drawer-width}) {
width: 100%;
}
}
&:checked + * {
@if $_drawer-right {
right: 0;
}
@else {
left: 0;
}
}
@media screen and (min-width: #{$drawer-mobile-breakpoint}){
&:not(.#{$drawer-persistent-name}) + * {
position: static;
height: 100%;
z-index: 1100;
& .#{$drawer-close-name} {
display: none;
}
}
}
}
/*
Definitions for navigation elements.
*/
// Different elements are styled based on the same set of rules.
$header-height: 3.1875rem !default; // Height of the header element.
$header-back-color: #f8f8f8 !default; // Background color for the header element.
$header-hover-back-color: #f0f0f0 !default; // Background color for the header element (hover).
$header-fore-color: #444 !default; // Text color for the header element.
$header-border-color: #ddd !default; // Border color for the header element.
$nav-back-color: #f8f8f8 !default; // Background color for the nav element.
$nav-hover-back-color: #f0f0f0 !default; // Background color for the nav element (hover).
$nav-fore-color: #444 !default; // Text color for the nav element.
$nav-border-color: #ddd !default; // Border color for the nav element.
$nav-link-color: #0277bd !default; // Color for link in the nav element.
$footer-fore-color: #444 !default; // Text color for the footer element.
$footer-back-color: #f8f8f8 !default; // Background color for footer nav element.
$footer-border-color: #ddd !default; // Border color for the footer element.
$footer-link-color: #0277bd !default; // Color for link in the footer element.
$drawer-back-color: #f8f8f8 !default; // Background color for the drawer component.
$drawer-border-color: #ddd !default; // Border color for the drawer component.
$drawer-hover-back-color: #f0f0f0 !default; // Background color for the drawer component's close (hover).
$drawer-close-color: #444 !default; // Color of the close element for the drawer component.
$_header-only-bottom-border: true !default; // [Hidden] Apply styling only to the bottom border of header? (boolean)
$_header-links-uppercase: true !default; // [Hidden] Should header links and buttons be uppercase? (boolean)
$header-logo-name: 'logo' !default; // Class name for the header logo element.
$header-logo-font-size: 1.75rem !default; // Font ize for the header logo element.
$nav-sublink-prefix: 'sublink' !default; // Prefix for the subcategory tabs in nav.
$nav-sublink-depth: 2 !default; // Amount of subcategory classes to add.
$_footer-only-top-border: true !default; // [Hidden] Apply styling only to the top border of footer? (boolean)
$footer-font-size: 0.875rem !default; // Font size for text in footer element.
$sticky-name: 'sticky' !default; // Class name for sticky headers and footers.
$drawer-name: 'drawer' !default; // Class name for the drawer component.
$drawer-toggle-name: 'drawer-toggle' !default; // Class name for the drawer component's toggle.
$drawer-toggle-font-size: 1.5em !default; // Font size for the drawer component's toggle. (prefer em units)
$drawer-mobile-breakpoint: 768px !default; // Mobile breakpoint for the drawer component.
$_drawer-right: true !default; // [Hidden] Should the drawer appear on the right side of the screen?
$drawer-persistent-name: 'persistent' !default; // Class name for the persisten variant of the drawer component.
$drawer-width: 320px !default; // Width of the drawer component.
$drawer-close-name: 'drawer-close' !default; // Class name of the close element for the drawer component.
$drawer-close-size: 2rem !default; // Size of the close element for the drawer component.
$drawer-icons-color: #212121 !default; // Color for the icons used in the drawer component.
// CSS variable name definitions [exercise caution if modifying these]
$header-fore-color-var: '--header-fore-color' !default;
$header-back-color-var: '--header-back-color' !default;
$header-hover-back-color-var: '--header-hover-back-color' !default;
$header-border-color-var: '--header-border-color' !default;
$nav-fore-color-var: '--nav-fore-color' !default;
$nav-back-color-var: '--nav-back-color' !default;
$nav-hover-back-color-var: '--nav-hover-back-color' !default;
$nav-border-color-var: '--nav-border-color' !default;
$nav-link-color-var: '--nav-link-color' !default;
$footer-fore-color-var: '--footer-fore-color' !default;
$footer-back-color-var: '--footer-back-color' !default;
$footer-border-color-var: '--footer-border-color' !default;
$footer-link-color-var: '--footer-link-color' !default;
$drawer-back-color-var: '--drawer-back-color' !default;
$drawer-border-color-var: '--drawer-border-color' !default;
$drawer-hover-back-color-var: '--drawer-hover-back-color' !default;
$drawer-close-color-var: '--drawer-close-color' !default;
// == Uncomment below code if this module is used on its own ==
//
// $universal-margin: 0.5rem !default; // Universal margin for the most elements
// $universal-padding: 0.5rem !default; // Universal padding for the most elements
// $universal-border-radius: 0.125rem !default; // Universal border-radius for most elements
// $universal-box-shadow: none !default; // Universal box-shadow for most elements
// $universal-margin-var: '--universal-margin' !default;
// $universal-padding-var: '--universal-padding' !default;
// $universal-border-radius-var: '--universal-border-radius' !default;
// $universal-box-shadow-var: '--universal-box-shadow' !default;
// :root {
// #{$universal-margin-var}: $universal-margin;
// #{$universal-padding-var}: $universal-padding;
// #{$universal-border-radius-var}: $universal-border-radius;
// @if $universal-box-shadow != none {
// #{$universal-box-shadow-var}: $universal-box-shadow;
// }
// }
//
// ============================================================
/* Navigation module CSS variable definitions */
:root {
#{$header-back-color-var}: $header-back-color;
#{$header-hover-back-color-var}: $header-hover-back-color;
#{$header-fore-color-var}: $header-fore-color;
#{$header-border-color-var}: $header-border-color;
#{$nav-back-color-var}: $nav-back-color;
#{$nav-hover-back-color-var}: $nav-hover-back-color;
#{$nav-fore-color-var}: $nav-fore-color;
#{$nav-border-color-var}: $nav-border-color;
#{$nav-link-color-var}: $nav-link-color;
#{$footer-fore-color-var}: $footer-fore-color;
#{$footer-back-color-var}: $footer-back-color;
#{$footer-border-color-var}: $footer-border-color;
#{$footer-link-color-var}: $footer-link-color;
#{$drawer-back-color-var}: $drawer-back-color;
#{$drawer-hover-back-color-var}: $drawer-hover-back-color;
#{$drawer-border-color-var}: $drawer-border-color;
#{$drawer-close-color-var}: $drawer-close-color;
}
// Header styling. - No box-shadow as it causes lots of weird bugs in Chrome. No margin as it shouldn't have any.
header {
height: $header-height;
background: var(#{$header-back-color-var}); // Always apply background color to avoid shine through
color: var(#{$header-fore-color-var});
@if $_header-only-bottom-border {
border-bottom: $__1px solid var(#{$header-border-color-var});
}
@else {
border: $__1px solid var(#{$header-border-color-var});
}
padding: calc(var(#{$universal-padding-var}) / 4) 0;
// Responsiveness for smaller displays, scrolls horizontally.
white-space: nowrap;
overflow-x: auto;
overflow-y: hidden;
// Fix for responsive header, using the grid system's row and column alignment.
&.#{$grid-row-name} {
box-sizing: content-box;
}
// Header logo styling.
.#{$header-logo-name} {
color: var(#{$header-fore-color-var});
font-size: $header-logo-font-size;
padding: var(#{$universal-padding-var}) calc(2 * var(#{$universal-padding-var}));
text-decoration: none;
}
// Link styling.
button, [type="button"], .#{$button-class-name}, [role="button"] {
box-sizing: border-box;
position: relative;
top: calc(0rem - var(#{$universal-padding-var}) / 4); // Use universal-padding to offset the padding of the header.
height: calc(#{$header-height} + var(#{$universal-padding-var}) / 2); // Fill header.
background: var(#{$header-back-color-var}); // Apply color regardless to override styling from other things.
line-height: calc(#{$header-height} - var(#{$universal-padding-var}) * 1.5);
text-align: center;
color: var(#{$header-fore-color-var});
border: 0;
border-radius: 0;
margin: 0;
@if $_header-links-uppercase {
text-transform: uppercase;
}
&:hover, &:focus {
background: var(#{$header-hover-back-color-var});
}
}
}
// Navigation sidebar styling.
nav {
background: var(#{$nav-back-color-var});
color: var(#{$nav-fore-color-var});
border: $__1px solid var(#{$nav-border-color-var});
border-radius: var(#{$universal-border-radius-var});
margin: var(#{$universal-margin-var});
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
* {
padding: var(#{$universal-padding-var}) calc(1.5 * var(#{$universal-padding-var}));
}
a, a:visited {
display: block;
color: var(#{$nav-link-color-var}); // Apply regardless to de-stylize visited links.
border-radius: var(#{$universal-border-radius-var});
transition: background 0.3s;
&:hover, &:focus {
text-decoration: none;
background: var(#{$nav-hover-back-color-var});
}
}
// Subcategories in navigation.
@for $i from 1 through $nav-sublink-depth {
.#{$nav-sublink-prefix}-#{$i} {
position: relative;
margin-left: calc(#{$i * 2} * var(#{$universal-padding-var}));
&:before {
position: absolute;
left: calc(var(#{$universal-padding-var}) - #{1 + ($i - 1)*2} * var(#{$universal-padding-var}));
top: -#{$__1px};
content: '';
height: 100%;
border: $__1px solid var(#{$nav-border-color-var});
border-left: 0;
}
}
}
}
// Footer styling.
footer {
background: var(#{$footer-back-color-var}); // Always apply background color to avoid shine through
color: var(#{$footer-fore-color-var});
@if $_footer-only-top-border {
border-top: $__1px solid var(#{$footer-border-color-var});
}
@else {
border: $__1px solid var(#{$footer-border-color-var});
}
// margin: $footer-margin;
padding: calc(2 * var(#{$universal-padding-var})) var(#{$universal-padding-var});
font-size: $footer-font-size;
a, a:visited {
color: var(#{$footer-link-color-var});
}
}
// Definitions for sticky headers and footers.
header.#{$sticky-name} {
position: -webkit-sticky; // One of the rare instances where prefixes are necessary.
position: sticky;
z-index: 1101; // Deals with certain problems when combined with cards and tables.
top: 0;
}
footer.#{$sticky-name} {
position: -webkit-sticky; // One of the rare instances where prefixes are necessary.
position: sticky;
z-index: 1101; // Deals with certain problems when combined with cards and tables.
bottom: 0;
}
// Responsive drawer component.
.#{$drawer-toggle-name} {
&:before { // No color specified, should use the color of its surroundings!
display: inline-block;
position: relative;
vertical-align: bottom;
content: '\00a0\2261\00a0'; // Spaces ensure compatibility with buttons that have text and that textless buttons will have some extra padding.
font-family: sans-serif;
font-size: $drawer-toggle-font-size; // Almost hardcoded, should be fully compatible with its surroundings.
}
@media screen and (min-width: #{$drawer-mobile-breakpoint}){
&:not(.#{$drawer-persistent-name}) {
display: none;
}
}
}
[type="checkbox"].#{$drawer-name} {
height: 1px;
width: 1px;
margin: -1px;
overflow: hidden;
position: absolute;
clip: rect(0 0 0 0);
-webkit-clip-path: inset(100%);
clip-path: inset(100%);
+ * {
display: block;
box-sizing: border-box;
position: fixed;
top: 0;
width: $drawer-width;
height: 100vh;
overflow-y: auto;
background: var(#{$drawer-back-color-var});
border: $__1px solid var(#{$drawer-border-color-var});
border-radius: 0; // Set to 0 to override the value from `nav`.
margin: 0; // Set to 0 to override the value from `nav`.
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
z-index: 1110;
@if $_drawer-right {
right: -$drawer-width;
transition: right 0.3s;
}
@else {
left: -$drawer-width;
transition: left 0.3s;
}
& .#{$drawer-close-name} {
position: absolute;
top: var(#{$universal-margin-var});
right: var(#{$universal-margin-var});
z-index: 1111;
width: $drawer-close-size;
height: $drawer-close-size;
border-radius: var(#{$universal-border-radius-var});
padding: var(#{$universal-padding-var});
margin: 0; // Fixes the offset from label
cursor: pointer;
transition: background 0.3s;
&:before { // Transparent background unless hovered over. Does not block text behind it.
display: block;
content: '\00D7';
color: var(#{$drawer-close-color-var});
position: relative;
font-family: sans-serif;
font-size: $drawer-close-size;
line-height: 1; // Setting to 1 seems to center the 'X' properly.
text-align: center;
}
&:hover, &:focus {
background: var(#{$drawer-hover-back-color-var});
}
}
@media screen and (max-width: #{$drawer-width}) {
width: 100%;
}
}
&:checked + * {
@if $_drawer-right {
right: 0;
}
@else {
left: 0;
}
}
@media screen and (min-width: #{$drawer-mobile-breakpoint}){
&:not(.#{$drawer-persistent-name}) + * {
position: static;
height: 100%;
z-index: 1100;
& .#{$drawer-close-name} {
display: none;
}
}
}
}

View file

@ -1,113 +1,113 @@
/*
Definitions for progress elements and spinners.
*/
$progress-back-color: #ddd !default; // Background color of <progress>.
$progress-fore-color: #555 !default; // Foreground color of <progress>.
$progress-height: 0.75rem !default; // Height of <progress>.
$progress-max-value: 1000 !default; // Arithmetic max value of <progress> - use integer values.
$progress-inline-name: 'inline' !default; // Class name for inline <progress> elements.
$progress-inline-width: 60% !default; // Width of inline <progress> elements.
$_include-spinner-donut: true !default; // [Hidden] Should spinner donuts be included? (boolean)
$spinner-donut-name: 'spinner' !default; // Class name for spinner donuts
$spinner-donut-size: 1.25rem !default; // Size of the spinner donuts
$spinner-donut-border-thickness: 0.25rem !default; // Border thickness for spinner donuts
$spinner-donut-back-color: #ddd !default; // Background color for spinner donuts
$spinner-donut-fore-color: #555 !default; // Foreground color for spinner donuts
// CSS variable name definitions [exercise caution if modifying these]
$progress-back-color-var: '--progress-back-color' !default;
$progress-fore-color-var: '--progress-fore-color' !default;
$spinner-donut-back-color-var: '--spinner-back-color' !default;
$spinner-donut-fore-color-var: '--spinner-fore-color' !default;
// == Uncomment below code if this module is used on its own ==
//
// $universal-margin: 0.5rem !default; // Universal margin for the most elements
// $universal-border-radius: 0.125rem !default; // Universal border-radius for most elements
// $universal-box-shadow: none !default; // Universal box-shadow for most elements
// $universal-margin-var: '--universal-margin' !default;
// $universal-border-radius-var: '--universal-border-radius' !default;
// $universal-box-shadow-var: '--universal-box-shadow' !default;
// :root {
// #{$universal-margin-var}: $universal-margin;
// #{$universal-border-radius-var}: $universal-border-radius;
// @if $universal-box-shadow != none {
// #{$universal-box-shadow-var}: $universal-box-shadow;
// }
// }
//
// ============================================================
// Check the `_progress_mixins.scss` file to find this module's mixins.
@import '_progress_mixins';
/* Progess module CSS variable definitions */
:root {
#{$progress-back-color-var}: $progress-back-color;
#{$progress-fore-color-var}: $progress-fore-color;
}
// Default styling for progress. Use mixins for alternate styles
progress {
display: block;
vertical-align: baseline; // Correct vertical alignment in some browsers.
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
height: $progress-height;
width: calc(100% - 2 * var(#{$universal-margin-var}));
margin: var(#{$universal-margin-var});
border: 0; // Removes default border
border-radius: calc(2 * var(#{$universal-border-radius-var}));
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
background: var(#{$progress-back-color-var});
color: var(#{$progress-fore-color-var});
// Foreground color on webkit browsers
&::-webkit-progress-value {
background: var(#{$progress-fore-color-var});
border-top-left-radius: calc(2 * var(#{$universal-border-radius-var}));
border-bottom-left-radius: calc(2 * var(#{$universal-border-radius-var}));
}
// Background color on webkit browser
&::-webkit-progress-bar {
background: var(#{$progress-back-color});
}
// Foreground color on Firefox
&::-moz-progress-bar {
background: var(#{$progress-fore-color-var});
border-top-left-radius: calc(2 * var(#{$universal-border-radius-var}));
border-bottom-left-radius: calc(2 * var(#{$universal-border-radius-var}));
}
&[value="#{$progress-max-value}"] {
&::-webkit-progress-value {
border-radius: calc(2 * var(#{$universal-border-radius-var}));
}
&::-moz-progress-bar {
border-radius: calc(2 * var(#{$universal-border-radius-var}));
}
}
&.#{$progress-inline-name} {
display: inline-block;
vertical-align: middle; // Align progress bar vertically to look better with text next to it.
width: $progress-inline-width;
}
}
// Style for donut spinner
@if $_include-spinner-donut {
:root {
#{$spinner-donut-back-color-var}: $spinner-donut-back-color;
#{$spinner-donut-fore-color-var}: $spinner-donut-fore-color;
}
// Donut spinner animation
@keyframes spinner-donut-anim {
0% { transform: rotate(0deg); }
100% { transform: rotate(360deg);}
}
.#{$spinner-donut-name} {
display: inline-block;
margin: var(#{$universal-margin-var});
border: $spinner-donut-border-thickness solid var(#{$spinner-donut-back-color-var});
border-left: $spinner-donut-border-thickness solid var(#{$spinner-donut-fore-color-var});
border-radius: 50%;
width: $spinner-donut-size;
height: $spinner-donut-size;
animation: spinner-donut-anim 1.2s linear infinite;
}
}
/*
Definitions for progress elements and spinners.
*/
$progress-back-color: #ddd !default; // Background color of <progress>.
$progress-fore-color: #555 !default; // Foreground color of <progress>.
$progress-height: 0.75rem !default; // Height of <progress>.
$progress-max-value: 1000 !default; // Arithmetic max value of <progress> - use integer values.
$progress-inline-name: 'inline' !default; // Class name for inline <progress> elements.
$progress-inline-width: 60% !default; // Width of inline <progress> elements.
$_include-spinner-donut: true !default; // [Hidden] Should spinner donuts be included? (boolean)
$spinner-donut-name: 'spinner' !default; // Class name for spinner donuts
$spinner-donut-size: 1.25rem !default; // Size of the spinner donuts
$spinner-donut-border-thickness: 0.25rem !default; // Border thickness for spinner donuts
$spinner-donut-back-color: #ddd !default; // Background color for spinner donuts
$spinner-donut-fore-color: #555 !default; // Foreground color for spinner donuts
// CSS variable name definitions [exercise caution if modifying these]
$progress-back-color-var: '--progress-back-color' !default;
$progress-fore-color-var: '--progress-fore-color' !default;
$spinner-donut-back-color-var: '--spinner-back-color' !default;
$spinner-donut-fore-color-var: '--spinner-fore-color' !default;
// == Uncomment below code if this module is used on its own ==
//
// $universal-margin: 0.5rem !default; // Universal margin for the most elements
// $universal-border-radius: 0.125rem !default; // Universal border-radius for most elements
// $universal-box-shadow: none !default; // Universal box-shadow for most elements
// $universal-margin-var: '--universal-margin' !default;
// $universal-border-radius-var: '--universal-border-radius' !default;
// $universal-box-shadow-var: '--universal-box-shadow' !default;
// :root {
// #{$universal-margin-var}: $universal-margin;
// #{$universal-border-radius-var}: $universal-border-radius;
// @if $universal-box-shadow != none {
// #{$universal-box-shadow-var}: $universal-box-shadow;
// }
// }
//
// ============================================================
// Check the `_progress_mixins.scss` file to find this module's mixins.
@import '_progress_mixins';
/* Progess module CSS variable definitions */
:root {
#{$progress-back-color-var}: $progress-back-color;
#{$progress-fore-color-var}: $progress-fore-color;
}
// Default styling for progress. Use mixins for alternate styles
progress {
display: block;
vertical-align: baseline; // Correct vertical alignment in some browsers.
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
height: $progress-height;
width: calc(100% - 2 * var(#{$universal-margin-var}));
margin: var(#{$universal-margin-var});
border: 0; // Removes default border
border-radius: calc(2 * var(#{$universal-border-radius-var}));
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
background: var(#{$progress-back-color-var});
color: var(#{$progress-fore-color-var});
// Foreground color on webkit browsers
&::-webkit-progress-value {
background: var(#{$progress-fore-color-var});
border-top-left-radius: calc(2 * var(#{$universal-border-radius-var}));
border-bottom-left-radius: calc(2 * var(#{$universal-border-radius-var}));
}
// Background color on webkit browser
&::-webkit-progress-bar {
background: var(#{$progress-back-color});
}
// Foreground color on Firefox
&::-moz-progress-bar {
background: var(#{$progress-fore-color-var});
border-top-left-radius: calc(2 * var(#{$universal-border-radius-var}));
border-bottom-left-radius: calc(2 * var(#{$universal-border-radius-var}));
}
&[value="#{$progress-max-value}"] {
&::-webkit-progress-value {
border-radius: calc(2 * var(#{$universal-border-radius-var}));
}
&::-moz-progress-bar {
border-radius: calc(2 * var(#{$universal-border-radius-var}));
}
}
&.#{$progress-inline-name} {
display: inline-block;
vertical-align: middle; // Align progress bar vertically to look better with text next to it.
width: $progress-inline-width;
}
}
// Style for donut spinner
@if $_include-spinner-donut {
:root {
#{$spinner-donut-back-color-var}: $spinner-donut-back-color;
#{$spinner-donut-fore-color-var}: $spinner-donut-fore-color;
}
// Donut spinner animation
@keyframes spinner-donut-anim {
0% { transform: rotate(0deg); }
100% { transform: rotate(360deg);}
}
.#{$spinner-donut-name} {
display: inline-block;
margin: var(#{$universal-margin-var});
border: $spinner-donut-border-thickness solid var(#{$spinner-donut-back-color-var});
border-left: $spinner-donut-border-thickness solid var(#{$spinner-donut-fore-color-var});
border-radius: 50%;
width: $spinner-donut-size;
height: $spinner-donut-size;
animation: spinner-donut-anim 1.2s linear infinite;
}
}

View file

@ -1,32 +1,32 @@
// Progress module's mixin definitions are here. For the module itself
// check `progress.scss`.
// Progress color variant mixin:
// $progress-alt-name: The name of the class used for the <progress> variant.
// $progress-alt-fore-color: Foregound color for <progress> variant.
// $progress-alt-back-color: Background color for <progress> variant.
@mixin make-progress-alt-color ($progress-alt-name, $progress-alt-fore-color : $progress-fore-color,
$progress-alt-back-color : $progress-back-color) {
progress.#{$progress-alt-name} {
@if $progress-alt-fore-color != $progress-fore-color{
#{$progress-fore-color-var}: $progress-alt-fore-color;
}
@if $progress-alt-back-color != $progress-back-color {
#{$progress-back-color-var}: $progress-alt-back-color;
}
}
}
// Spinner donut color variant mixin:
// $spinner-donut-alt-name: The name of the class used for the spinner donut variant.
// $spinner-donut-alt-fore-color: Text color for spinner donut variant.
// $spinner-donut-alt-back-color: Background color for spinner donut variant.
@mixin make-spinner-donut-alt-color ($spinner-donut-alt-name, $spinner-donut-alt-fore-color : $spinner-donut-fore-color,
$spinner-donut-alt-back-color : $spinner-donut-back-color) {
.#{$spinner-donut-name}.#{$spinner-donut-alt-name} {
@if $spinner-donut-alt-fore-color != $spinner-donut-fore-color{
#{$spinner-donut-fore-color-var}: $spinner-donut-alt-fore-color;
}
@if $spinner-donut-alt-back-color != $spinner-donut-back-color {
#{$spinner-donut-back-color-var}: $spinner-donut-alt-back-color;
}
}
}
// Progress module's mixin definitions are here. For the module itself
// check `progress.scss`.
// Progress color variant mixin:
// $progress-alt-name: The name of the class used for the <progress> variant.
// $progress-alt-fore-color: Foregound color for <progress> variant.
// $progress-alt-back-color: Background color for <progress> variant.
@mixin make-progress-alt-color ($progress-alt-name, $progress-alt-fore-color : $progress-fore-color,
$progress-alt-back-color : $progress-back-color) {
progress.#{$progress-alt-name} {
@if $progress-alt-fore-color != $progress-fore-color{
#{$progress-fore-color-var}: $progress-alt-fore-color;
}
@if $progress-alt-back-color != $progress-back-color {
#{$progress-back-color-var}: $progress-alt-back-color;
}
}
}
// Spinner donut color variant mixin:
// $spinner-donut-alt-name: The name of the class used for the spinner donut variant.
// $spinner-donut-alt-fore-color: Text color for spinner donut variant.
// $spinner-donut-alt-back-color: Background color for spinner donut variant.
@mixin make-spinner-donut-alt-color ($spinner-donut-alt-name, $spinner-donut-alt-fore-color : $spinner-donut-fore-color,
$spinner-donut-alt-back-color : $spinner-donut-back-color) {
.#{$spinner-donut-name}.#{$spinner-donut-alt-name} {
@if $spinner-donut-alt-fore-color != $spinner-donut-fore-color{
#{$spinner-donut-fore-color-var}: $spinner-donut-alt-fore-color;
}
@if $spinner-donut-alt-back-color != $spinner-donut-back-color {
#{$spinner-donut-back-color-var}: $spinner-donut-alt-back-color;
}
}
}

View file

@ -1,371 +1,371 @@
/*
Definitions for the responsive table component.
*/
// The tables use the common table elements and syntax - <tfoot> is not supported.
$table-mobile-breakpoint: 768px !default; // Breakpoint for <table> mobile view.
$table-max-height: 400px !default; // Maximum height of <table> elements (non-horizontal).
$table-caption-font-size: 1.5rem !default; // Font size for <caption> elements.
$table-mobile-card-label: 'data-label' !default; // Attribute used to replace column headers in mobile view.
$table-mobile-label-font-weight: 600 !default; // Font weight for column header labels in mobile view.
$table-border-color: #aaa !default; // Border color for <table> elements.
$table-border-separator-color: #666 !default; // Border color for the border between <thead> and <tbody>.
$table-th-back-color: #e6e6e6 !default; // Background color for <th> elements.
$table-th-fore-color: #111 !default; // Text color for <th> elements.
$table-td-back-color: #f8f8f8 !default; // Background color for <td> elements.
$table-td-fore-color: #111 !default; // Text color for <td> elements.
$_include-horizontal-table: true !default; // [Hidden] Flag for horizontal tables (`true`/`false`).
$table-horizontal-name: 'horizontal' !default; // Class name for horizontal <table> elements.
$_include-striped-table: true !default; // [Hidden] Flag for striped tables.
$table-striped-name: 'striped' !default; // Class name for striped <table> elements.
$table-td-alt-back-color: #eee !default; // Alternative background color for <td> elements in striped tables.
$_include-hoverable-table: true !default; // [Hidden] Flag for striped tables.
$table-hoverable-name: 'hoverable' !default; // Class name for hoverable <table> elements.
$table-td-hover-back-color: #90caf9 !default; // Hover background color for <td> elements in hoverable tables.
// CSS variable name definitions [exercise caution if modifying these]
$table-border-color-var: '--table-border-color' !default;
$table-border-separator-color-var: '--table-border-separator-color' !default;
$table-th-back-color-var: '--table-head-back-color' !default;
$table-th-fore-color-var: '--table-head-fore-color' !default;
$table-td-back-color-var: '--table-body-back-color' !default;
$table-td-fore-color-var: '--table-body-fore-color' !default;
$table-td-alt-back-color-var: '--table-body-alt-back-color' !default;
$table-td-hover-back-color-var: '--table-body-hover-back-color' !default;
// == Uncomment below code if this module is used on its own ==
//
// $universal-margin: 0.5rem !default; // Universal margin for the most elements
// $universal-padding: 0.5rem !default; // Universal padding for the most elements
// $universal-border-radius: 0.125rem !default; // Universal border-radius for most elements
// $universal-box-shadow: none !default; // Universal box-shadow for most elements
// $universal-margin-var: '--universal-margin' !default;
// $universal-padding-var: '--universal-padding' !default;
// $universal-border-radius-var: '--universal-border-radius' !default;
// $universal-box-shadow-var: '--universal-box-shadow' !default;
// :root {
// #{$universal-margin-var}: $universal-margin;
// #{$universal-padding-var}: $universal-padding;
// #{$universal-border-radius-var}: $universal-border-radius;
// @if $universal-box-shadow != none {
// #{$universal-box-shadow-var}: $universal-box-shadow;
// }
// }
//
// ============================================================
/* Table module CSS variable definitions. */
:root {
#{$table-border-color-var}: $table-border-color;
#{$table-border-separator-color-var}: $table-border-separator-color;
#{$table-th-back-color-var}: $table-th-back-color;
#{$table-th-fore-color-var}: $table-th-fore-color;
#{$table-td-back-color-var}: $table-td-back-color;
#{$table-td-fore-color-var}: $table-td-fore-color;
#{$table-td-alt-back-color-var}: $table-td-alt-back-color;
}
// Desktop view (scrollable vertical tables).
table {
border-collapse: separate;
border-spacing: 0;
margin: 0;
display: flex;
flex: 0 1 auto;
flex-flow: row wrap;
padding: var(#{$universal-padding-var});
padding-top: 0;
@if not($_include-horizontal-table) {
overflow: auto;
max-height: $table-max-height;
}
caption {
font-size: $table-caption-font-size;
margin: calc(2 * var(#{$universal-margin-var})) 0;
max-width: 100%;
flex: 0 0 100%;
}
thead, tbody {
display: flex;
flex-flow: row wrap;
border: $__1px solid var(#{$table-border-color-var});
@if not($_include-horizontal-table) {
max-width: 100%;
flex: 0 0 100%;
}
}
thead {
z-index: 999; // Fixes the visibility of the element.
border-radius: var(#{$universal-border-radius-var}) var(#{$universal-border-radius-var}) 0 0;
border-bottom: $__1px solid var(#{$table-border-separator-color-var});
@if not($_include-horizontal-table) {
position: sticky;
top: 0;
}
}
tbody {
border-top: 0;
margin-top: calc(0 - var(#{$universal-margin-var}));
border-radius: 0 0 var(--universal-border-radius) var(--universal-border-radius);
}
tr {
display: flex;
padding: 0; // Apply always to overwrite default.
@if not($_include-horizontal-table) {
flex-flow: row wrap;
flex: 0 0 100%;
}
}
th, td {
padding: calc(2 * var(#{$universal-padding-var})); // Apply always to overwrite default.
@if not($_include-horizontal-table) {
flex: 1 0 0%;
overflow: hidden;
text-overflow: ellipsis;
}
}
th {
text-align: left;
background: var(#{$table-th-back-color-var});
color: var(#{$table-th-fore-color-var});
}
td {
background: var(#{$table-td-back-color-var});
color: var(#{$table-td-fore-color-var});
border-top: $__1px solid var(#{$table-border-color-var});
}
@if not($_include-horizontal-table) {
tbody tr:first-child td {
border-top: 0;
}
}
}
// Styling for horizontal tables
@if $_include-horizontal-table {
table:not(.#{$table-horizontal-name}) {
overflow: auto;
max-height: $table-max-height;
thead, tbody {
max-width: 100%;
flex: 0 0 100%;
}
tr {
flex-flow: row wrap;
flex: 0 0 100%;
}
th, td {
flex: 1 0 0%;
overflow: hidden;
text-overflow: ellipsis;
}
thead {
position: sticky;
top: 0;
}
tbody tr:first-child td {
border-top: 0;
}
}
table.#{$table-horizontal-name} {
border: 0;
thead, tbody {
border: 0;
flex-flow: row nowrap;
}
tbody {
overflow: auto;
justify-content: space-between;
flex: 1 0 0;
margin-left: calc( 4 * var(#{$universal-margin-var}));
padding-bottom: calc(var(#{$universal-padding-var}) / 4);
}
tr {
flex-direction: column;
flex: 1 0 auto;
}
th, td {
width: 100%;
border: 0;
border-bottom: $__1px solid var(#{$table-border-color-var});
&:not(:first-child){
border-top: 0;
}
}
th {
text-align: right;
border-left: $__1px solid var(#{$table-border-color-var});
border-right: $__1px solid var(#{$table-border-separator-color-var});
}
thead {
tr:first-child {
padding-left: 0;
}
}
th:first-child, td:first-child {
border-top: $__1px solid var(#{$table-border-color-var});
}
tbody tr:last-child td {
border-right: $__1px solid var(#{$table-border-color-var});
&:first-child{
border-top-right-radius: 0.25rem;
}
&:last-child{
border-bottom-right-radius: 0.25rem;
}
}
thead tr:first-child th {
&:first-child{
border-top-left-radius: 0.25rem;
}
&:last-child{
border-bottom-left-radius: 0.25rem;
}
}
}
}
// Mobile
@media screen and (max-width: #{$table-mobile-breakpoint - 1px}){
@if $_include-horizontal-table {
table, table.#{$table-horizontal-name} {
border-collapse: collapse;
border: 0;
width: 100%;
display: table;
// Accessibility (element is not visible, but screen readers read it normally)
thead, th {
border: 0;
height: 1px;
width: 1px;
margin: -1px;
overflow: hidden;
padding: 0;
position: absolute;
clip: rect(0 0 0 0);
-webkit-clip-path: inset(100%);
clip-path: inset(100%);
}
tbody {
border: 0;
display: table-row-group;
}
tr {
display: block;
border: $__1px solid var(#{$table-border-color-var});
border-radius: var(#{$universal-border-radius-var});
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
background: #fafafa; // use variables, this is a test (body)
padding: var(#{$universal-padding-var});
margin: var(#{$universal-margin-var});
margin-bottom: calc(2 * var(#{$universal-margin-var}));
}
th, td {
width: auto;
}
td {
display: block;
border: 0;
text-align: right;
}
td:before {
content: attr(#{$table-mobile-card-label});
float: left;
font-weight: $table-mobile-label-font-weight;
}
th:first-child, td:first-child {
border-top: 0;
}
tbody tr:last-child td {
border-right: 0;
}
}
}
@else {
table {
border-collapse: collapse;
border: 0;
width: 100%;
display: table;
// Accessibility (element is not visible, but screen readers read it normally)
thead, th {
border: 0;
height: 1px;
width: 1px;
margin: -1px;
overflow: hidden;
padding: 0;
position: absolute;
clip: rect(0 0 0 0);
-webkit-clip-path: inset(100%);
clip-path: inset(100%);
}
tbody {
border: 0;
display: table-row-group;
}
tr {
display: block;
border: $__1px solid var(#{$table-border-color-var});
border-radius: var(#{$universal-border-radius-var});
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
background: #fafafa; // use variables, this is a test (body)
padding: var(#{$universal-padding-var});
margin: var(#{$universal-margin-var});
margin-bottom: calc(2 * var(#{$universal-margin-var}));
}
td {
display: block;
border: 0;
text-align: right;
}
td:before {
content: attr(#{$table-mobile-card-label});
float: left;
font-weight: $table-mobile-label-font-weight;
}
}
}
}
// Striped tables.
@if $_include-striped-table {
:root {
#{$table-td-alt-back-color-var} : $table-td-alt-back-color;
}
table.#{$table-striped-name} {
tr:nth-of-type(2n) > td {
background: var(#{$table-td-alt-back-color-var});
}
}
// Responsiveness for striped tables.
@media screen and (max-width: #{$table-mobile-breakpoint}) {
table.#{$table-striped-name} {
tr:nth-of-type(2n) {
background: var(#{$table-td-alt-back-color-var});
}
}
}
}
// Hoverable tables.
@if $_include-striped-table {
:root {
#{$table-td-hover-back-color-var} : $table-td-hover-back-color;
}
table.#{$table-hoverable-name} {
tr {
&:hover, &:focus {
&, & > td {
background: var(#{$table-td-hover-back-color-var});
}
}
}
}
@media screen and (max-width: #{$table-mobile-breakpoint}) {
table.#{$table-hoverable-name} {
tr {
&:hover, &:focus {
&, & > td {
background: var(#{$table-td-hover-back-color-var});
}
}
}
}
}
}
/*
Definitions for the responsive table component.
*/
// The tables use the common table elements and syntax - <tfoot> is not supported.
$table-mobile-breakpoint: 768px !default; // Breakpoint for <table> mobile view.
$table-max-height: 400px !default; // Maximum height of <table> elements (non-horizontal).
$table-caption-font-size: 1.5rem !default; // Font size for <caption> elements.
$table-mobile-card-label: 'data-label' !default; // Attribute used to replace column headers in mobile view.
$table-mobile-label-font-weight: 600 !default; // Font weight for column header labels in mobile view.
$table-border-color: #aaa !default; // Border color for <table> elements.
$table-border-separator-color: #666 !default; // Border color for the border between <thead> and <tbody>.
$table-th-back-color: #e6e6e6 !default; // Background color for <th> elements.
$table-th-fore-color: #111 !default; // Text color for <th> elements.
$table-td-back-color: #f8f8f8 !default; // Background color for <td> elements.
$table-td-fore-color: #111 !default; // Text color for <td> elements.
$_include-horizontal-table: true !default; // [Hidden] Flag for horizontal tables (`true`/`false`).
$table-horizontal-name: 'horizontal' !default; // Class name for horizontal <table> elements.
$_include-striped-table: true !default; // [Hidden] Flag for striped tables.
$table-striped-name: 'striped' !default; // Class name for striped <table> elements.
$table-td-alt-back-color: #eee !default; // Alternative background color for <td> elements in striped tables.
$_include-hoverable-table: true !default; // [Hidden] Flag for striped tables.
$table-hoverable-name: 'hoverable' !default; // Class name for hoverable <table> elements.
$table-td-hover-back-color: #90caf9 !default; // Hover background color for <td> elements in hoverable tables.
// CSS variable name definitions [exercise caution if modifying these]
$table-border-color-var: '--table-border-color' !default;
$table-border-separator-color-var: '--table-border-separator-color' !default;
$table-th-back-color-var: '--table-head-back-color' !default;
$table-th-fore-color-var: '--table-head-fore-color' !default;
$table-td-back-color-var: '--table-body-back-color' !default;
$table-td-fore-color-var: '--table-body-fore-color' !default;
$table-td-alt-back-color-var: '--table-body-alt-back-color' !default;
$table-td-hover-back-color-var: '--table-body-hover-back-color' !default;
// == Uncomment below code if this module is used on its own ==
//
// $universal-margin: 0.5rem !default; // Universal margin for the most elements
// $universal-padding: 0.5rem !default; // Universal padding for the most elements
// $universal-border-radius: 0.125rem !default; // Universal border-radius for most elements
// $universal-box-shadow: none !default; // Universal box-shadow for most elements
// $universal-margin-var: '--universal-margin' !default;
// $universal-padding-var: '--universal-padding' !default;
// $universal-border-radius-var: '--universal-border-radius' !default;
// $universal-box-shadow-var: '--universal-box-shadow' !default;
// :root {
// #{$universal-margin-var}: $universal-margin;
// #{$universal-padding-var}: $universal-padding;
// #{$universal-border-radius-var}: $universal-border-radius;
// @if $universal-box-shadow != none {
// #{$universal-box-shadow-var}: $universal-box-shadow;
// }
// }
//
// ============================================================
/* Table module CSS variable definitions. */
:root {
#{$table-border-color-var}: $table-border-color;
#{$table-border-separator-color-var}: $table-border-separator-color;
#{$table-th-back-color-var}: $table-th-back-color;
#{$table-th-fore-color-var}: $table-th-fore-color;
#{$table-td-back-color-var}: $table-td-back-color;
#{$table-td-fore-color-var}: $table-td-fore-color;
#{$table-td-alt-back-color-var}: $table-td-alt-back-color;
}
// Desktop view (scrollable vertical tables).
table {
border-collapse: separate;
border-spacing: 0;
margin: 0;
display: flex;
flex: 0 1 auto;
flex-flow: row wrap;
padding: var(#{$universal-padding-var});
padding-top: 0;
@if not($_include-horizontal-table) {
overflow: auto;
max-height: $table-max-height;
}
caption {
font-size: $table-caption-font-size;
margin: calc(2 * var(#{$universal-margin-var})) 0;
max-width: 100%;
flex: 0 0 100%;
}
thead, tbody {
display: flex;
flex-flow: row wrap;
border: $__1px solid var(#{$table-border-color-var});
@if not($_include-horizontal-table) {
max-width: 100%;
flex: 0 0 100%;
}
}
thead {
z-index: 999; // Fixes the visibility of the element.
border-radius: var(#{$universal-border-radius-var}) var(#{$universal-border-radius-var}) 0 0;
border-bottom: $__1px solid var(#{$table-border-separator-color-var});
@if not($_include-horizontal-table) {
position: sticky;
top: 0;
}
}
tbody {
border-top: 0;
margin-top: calc(0 - var(#{$universal-margin-var}));
border-radius: 0 0 var(--universal-border-radius) var(--universal-border-radius);
}
tr {
display: flex;
padding: 0; // Apply always to overwrite default.
@if not($_include-horizontal-table) {
flex-flow: row wrap;
flex: 0 0 100%;
}
}
th, td {
padding: calc(2 * var(#{$universal-padding-var})); // Apply always to overwrite default.
@if not($_include-horizontal-table) {
flex: 1 0 0%;
overflow: hidden;
text-overflow: ellipsis;
}
}
th {
text-align: left;
background: var(#{$table-th-back-color-var});
color: var(#{$table-th-fore-color-var});
}
td {
background: var(#{$table-td-back-color-var});
color: var(#{$table-td-fore-color-var});
border-top: $__1px solid var(#{$table-border-color-var});
}
@if not($_include-horizontal-table) {
tbody tr:first-child td {
border-top: 0;
}
}
}
// Styling for horizontal tables
@if $_include-horizontal-table {
table:not(.#{$table-horizontal-name}) {
overflow: auto;
max-height: $table-max-height;
thead, tbody {
max-width: 100%;
flex: 0 0 100%;
}
tr {
flex-flow: row wrap;
flex: 0 0 100%;
}
th, td {
flex: 1 0 0%;
overflow: hidden;
text-overflow: ellipsis;
}
thead {
position: sticky;
top: 0;
}
tbody tr:first-child td {
border-top: 0;
}
}
table.#{$table-horizontal-name} {
border: 0;
thead, tbody {
border: 0;
flex-flow: row nowrap;
}
tbody {
overflow: auto;
justify-content: space-between;
flex: 1 0 0;
margin-left: calc( 4 * var(#{$universal-margin-var}));
padding-bottom: calc(var(#{$universal-padding-var}) / 4);
}
tr {
flex-direction: column;
flex: 1 0 auto;
}
th, td {
width: 100%;
border: 0;
border-bottom: $__1px solid var(#{$table-border-color-var});
&:not(:first-child){
border-top: 0;
}
}
th {
text-align: right;
border-left: $__1px solid var(#{$table-border-color-var});
border-right: $__1px solid var(#{$table-border-separator-color-var});
}
thead {
tr:first-child {
padding-left: 0;
}
}
th:first-child, td:first-child {
border-top: $__1px solid var(#{$table-border-color-var});
}
tbody tr:last-child td {
border-right: $__1px solid var(#{$table-border-color-var});
&:first-child{
border-top-right-radius: 0.25rem;
}
&:last-child{
border-bottom-right-radius: 0.25rem;
}
}
thead tr:first-child th {
&:first-child{
border-top-left-radius: 0.25rem;
}
&:last-child{
border-bottom-left-radius: 0.25rem;
}
}
}
}
// Mobile
@media screen and (max-width: #{$table-mobile-breakpoint - 1px}){
@if $_include-horizontal-table {
table, table.#{$table-horizontal-name} {
border-collapse: collapse;
border: 0;
width: 100%;
display: table;
// Accessibility (element is not visible, but screen readers read it normally)
thead, th {
border: 0;
height: 1px;
width: 1px;
margin: -1px;
overflow: hidden;
padding: 0;
position: absolute;
clip: rect(0 0 0 0);
-webkit-clip-path: inset(100%);
clip-path: inset(100%);
}
tbody {
border: 0;
display: table-row-group;
}
tr {
display: block;
border: $__1px solid var(#{$table-border-color-var});
border-radius: var(#{$universal-border-radius-var});
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
background: #fafafa; // use variables, this is a test (body)
padding: var(#{$universal-padding-var});
margin: var(#{$universal-margin-var});
margin-bottom: calc(2 * var(#{$universal-margin-var}));
}
th, td {
width: auto;
}
td {
display: block;
border: 0;
text-align: right;
}
td:before {
content: attr(#{$table-mobile-card-label});
float: left;
font-weight: $table-mobile-label-font-weight;
}
th:first-child, td:first-child {
border-top: 0;
}
tbody tr:last-child td {
border-right: 0;
}
}
}
@else {
table {
border-collapse: collapse;
border: 0;
width: 100%;
display: table;
// Accessibility (element is not visible, but screen readers read it normally)
thead, th {
border: 0;
height: 1px;
width: 1px;
margin: -1px;
overflow: hidden;
padding: 0;
position: absolute;
clip: rect(0 0 0 0);
-webkit-clip-path: inset(100%);
clip-path: inset(100%);
}
tbody {
border: 0;
display: table-row-group;
}
tr {
display: block;
border: $__1px solid var(#{$table-border-color-var});
border-radius: var(#{$universal-border-radius-var});
@if $universal-box-shadow != none {
box-shadow: var(#{$universal-box-shadow-var});
}
background: #fafafa; // use variables, this is a test (body)
padding: var(#{$universal-padding-var});
margin: var(#{$universal-margin-var});
margin-bottom: calc(2 * var(#{$universal-margin-var}));
}
td {
display: block;
border: 0;
text-align: right;
}
td:before {
content: attr(#{$table-mobile-card-label});
float: left;
font-weight: $table-mobile-label-font-weight;
}
}
}
}
// Striped tables.
@if $_include-striped-table {
:root {
#{$table-td-alt-back-color-var} : $table-td-alt-back-color;
}
table.#{$table-striped-name} {
tr:nth-of-type(2n) > td {
background: var(#{$table-td-alt-back-color-var});
}
}
// Responsiveness for striped tables.
@media screen and (max-width: #{$table-mobile-breakpoint}) {
table.#{$table-striped-name} {
tr:nth-of-type(2n) {
background: var(#{$table-td-alt-back-color-var});
}
}
}
}
// Hoverable tables.
@if $_include-striped-table {
:root {
#{$table-td-hover-back-color-var} : $table-td-hover-back-color;
}
table.#{$table-hoverable-name} {
tr {
&:hover, &:focus {
&, & > td {
background: var(#{$table-td-hover-back-color-var});
}
}
}
}
@media screen and (max-width: #{$table-mobile-breakpoint}) {
table.#{$table-hoverable-name} {
tr {
&:hover, &:focus {
&, & > td {
background: var(#{$table-td-hover-back-color-var});
}
}
}
}
}
}

View file

@ -1,169 +1,169 @@
/*
Definitions for utilities and helper classes.
*/
$hidden-name: 'hidden' !default; // Class name for hidden elements.
$visually-hidden-name: 'visually-hidden' !default; // Class name for visually hidden elements.
$border-generic-name: 'bordered' !default; // Class name for bordered elements.
$border-generic-color: rgba(0,0,0, 0.3) !default; // Border color for bordered elements.
$border-rounded-name: 'rounded' !default; // Class name for rounded-border elements.
$border-circular-name: 'circular' !default; // Class name for circular-border elements.
$box-shadow-generic-name:'shadowed' !default; // Class name for box-shadow elements.
$box-shadow-generic: 0 4*$__1px 4*$__1px 0 rgba(0, 0, 0, 0.125), 0 2*$__1px 2*$__1px -2*$__1px rgba(0, 0, 0, 0.25);
$responsive-margin-name: 'responsive-margin' !default; //Class name for responsive margin elements.
$responsive-margin-medium-breakpoint: 768px !default; // Medium screen breakpoint for responsive margin elements.
$responsive-margin-large-breakpoint: 1280px !default; // Medium screen breakpoint for responsive margin elements.
$responsive-padding-name: 'responsive-padding' !default; //Class name for responsive padding elements.
$responsive-padding-medium-breakpoint: 768px !default; // Medium screen breakpoint for responsive padding elements.
$responsive-padding-large-breakpoint: 1280px !default; // Medium screen breakpoint for responsive padding elements.
$hidden-prefix: 'hidden' !default; // Class prefix for responsive hidden elements.
$hidden-small-suffix: 'sm' !default; // Class suffix for responsive hidden elements.
$hidden-medium-breakpoint: 768px !default; // Medium screen breakpoint for responsive hidden elements.
$hidden-medium-suffix: 'md' !default; // Class suffix for responsive hidden elements.
$hidden-large-breakpoint: 1280px !default; // Medium screen breakpoint for responsive hidden elements.
$hidden-large-suffix: 'lg' !default; // Class suffix for responsive hidden elements.
$visually-hidden-prefix: 'visually-hidden' !default; // Class prefix for responsive visually hidden elements.
$visually-hidden-small-suffix: 'sm' !default; // Class suffix for responsive hidden elements.
$visually-hidden-medium-breakpoint: 768px !default; // Medium screen breakpoint for responsive visually hidden elements.
$visually-hidden-medium-suffix: 'md' !default; // Class suffix for responsive hidden elements.
$visually-hidden-large-breakpoint: 1280px !default; // Medium screen breakpoint for responsive visually hidden elements.
$visually-hidden-large-suffix: 'lg' !default; // Class suffix for responsive hidden elements.
// CSS variable name definitions [exercise caution if modifying these]
$border-generic-color-var: '--generic-border-color' !default;
$box-shadow-generic-var: '--generic-box-shadow' !default;
// == Uncomment below code if this module is used on its own ==
//
// $universal-margin: 0.5rem !default; // Universal margin for the most elements
// $universal-padding: 0.5rem !default; // Universal padding for the most elements
// $universal-border-radius: 0.125rem !default; // Universal border-radius for most elements
// $universal-box-shadow: none !default; // Universal box-shadow for most elements
// $universal-margin-var: '--universal-margin' !default;
// $universal-padding-var: '--universal-padding' !default;
// $universal-border-radius-var: '--universal-border-radius' !default;
// $universal-box-shadow-var: '--universal-box-shadow' !default;
// :root {
// #{$universal-margin-var}: $universal-margin;
// #{$universal-padding-var}: $universal-padding;
// #{$universal-border-radius-var}: $universal-border-radius;
// @if $universal-box-shadow != none {
// #{$universal-box-shadow-var}: $universal-box-shadow;
// }
// }
//
// ============================================================
/* Utility module CSS variable definitions */
:root {
#{$border-generic-color-var}: $border-generic-color;
#{$box-shadow-generic-var}: $box-shadow-generic;
}
// Hidden elements class. NOTE: Uses !important.
.#{$hidden-name}{
display: none !important;
}
// Visually hidden elements class. NOTE: Uses !important.
.#{$visually-hidden-name} {
position: absolute !important;
width: 1px !important;
height: 1px !important;
margin: -1px !important;
border: 0 !important;
padding: 0 !important;
clip: rect(0 0 0 0) !important;
-webkit-clip-path: inset(100%) !important;
clip-path: inset(100%) !important;
overflow: hidden !important;
}
// Generic bordered element class. NOTE: Uses !important.
.#{$border-generic-name} {
border: $__1px solid var(#{$border-generic-color-var}) !important;
}
// Generic rounded-border element class. NOTE: Uses !important.
.#{$border-rounded-name} {
border-radius: var(#{$universal-border-radius-var}) !important;
}
// Generic circular-border element class. NOTE: Uses !important.
.#{$border-circular-name} {
border-radius: 50% !important;
}
// Generic box-shadow element class. NOTE: Uses !important.
.#{$box-shadow-generic-name} {
box-shadow: var(#{$box-shadow-generic-var}) !important;
}
// Responsive margin class. NOTE: Uses !important.
.#{$responsive-margin-name} {
margin: calc(var(#{$universal-margin-var}) / 4) !important;
@media screen and (min-width: #{$responsive-margin-medium-breakpoint}) {
margin: calc(var(#{$universal-margin-var}) / 2) !important;
}
@media screen and (min-width: #{$responsive-margin-large-breakpoint}) {
margin: var(#{$universal-margin-var}) !important;
}
}
// Responsive padding class. NOTE: Uses !important.
.#{$responsive-padding-name} {
padding: calc(var(#{$universal-padding-var}) / 4) !important;
@media screen and (min-width: #{$responsive-padding-medium-breakpoint}) {
padding: calc(var(#{$universal-padding-var}) / 2) !important;
}
@media screen and (min-width: #{$responsive-padding-large-breakpoint}) {
padding: var(#{$universal-padding-var}) !important;
}
}
// Responsive hidden element class. NOTE: Uses !important.
@media screen and (max-width: #{$hidden-medium-breakpoint}-1px) {
.#{$hidden-prefix}-#{$hidden-small-suffix} {
display: none !important;
}
}
@media screen and (min-width: #{$hidden-medium-breakpoint}) and (max-width: #{$hidden-large-breakpoint}-1px) {
.#{$hidden-prefix}-#{$hidden-medium-suffix} {
display: none !important;
}
}
@media screen and (min-width: #{$hidden-large-breakpoint}) {
.#{$hidden-prefix}-#{$hidden-large-suffix} {
display: none !important;
}
}
// Responsive visually hidden element class. NOTE: Uses !important.
@media screen and (max-width: #{$visually-hidden-medium-breakpoint}-1px) {
.#{$visually-hidden-prefix}-#{$visually-hidden-small-suffix} {
position: absolute !important;
width: 1px !important;
height: 1px !important;
margin: -1px !important;
border: 0 !important;
padding: 0 !important;
clip: rect(0 0 0 0) !important;
-webkit-clip-path: inset(100%) !important;
clip-path: inset(100%) !important;
overflow: hidden !important;
}
}
@media screen and (min-width: #{$visually-hidden-medium-breakpoint}) and (max-width: #{$visually-hidden-large-breakpoint}-1px) {
.#{$visually-hidden-prefix}-#{$visually-hidden-medium-suffix} {
position: absolute !important;
width: 1px !important;
height: 1px !important;
margin: -1px !important;
border: 0 !important;
padding: 0 !important;
clip: rect(0 0 0 0) !important;
-webkit-clip-path: inset(100%) !important;
clip-path: inset(100%) !important;
overflow: hidden !important;
}
}
@media screen and (min-width: #{$visually-hidden-large-breakpoint}) {
.#{$visually-hidden-prefix}-#{$visually-hidden-large-suffix} {
position: absolute !important;
width: 1px !important;
height: 1px !important;
margin: -1px !important;
border: 0 !important;
padding: 0 !important;
clip: rect(0 0 0 0) !important;
-webkit-clip-path: inset(100%) !important;
clip-path: inset(100%) !important;
overflow: hidden !important;
}
}
/*
Definitions for utilities and helper classes.
*/
$hidden-name: 'hidden' !default; // Class name for hidden elements.
$visually-hidden-name: 'visually-hidden' !default; // Class name for visually hidden elements.
$border-generic-name: 'bordered' !default; // Class name for bordered elements.
$border-generic-color: rgba(0,0,0, 0.3) !default; // Border color for bordered elements.
$border-rounded-name: 'rounded' !default; // Class name for rounded-border elements.
$border-circular-name: 'circular' !default; // Class name for circular-border elements.
$box-shadow-generic-name:'shadowed' !default; // Class name for box-shadow elements.
$box-shadow-generic: 0 4*$__1px 4*$__1px 0 rgba(0, 0, 0, 0.125), 0 2*$__1px 2*$__1px -2*$__1px rgba(0, 0, 0, 0.25);
$responsive-margin-name: 'responsive-margin' !default; //Class name for responsive margin elements.
$responsive-margin-medium-breakpoint: 768px !default; // Medium screen breakpoint for responsive margin elements.
$responsive-margin-large-breakpoint: 1280px !default; // Medium screen breakpoint for responsive margin elements.
$responsive-padding-name: 'responsive-padding' !default; //Class name for responsive padding elements.
$responsive-padding-medium-breakpoint: 768px !default; // Medium screen breakpoint for responsive padding elements.
$responsive-padding-large-breakpoint: 1280px !default; // Medium screen breakpoint for responsive padding elements.
$hidden-prefix: 'hidden' !default; // Class prefix for responsive hidden elements.
$hidden-small-suffix: 'sm' !default; // Class suffix for responsive hidden elements.
$hidden-medium-breakpoint: 768px !default; // Medium screen breakpoint for responsive hidden elements.
$hidden-medium-suffix: 'md' !default; // Class suffix for responsive hidden elements.
$hidden-large-breakpoint: 1280px !default; // Medium screen breakpoint for responsive hidden elements.
$hidden-large-suffix: 'lg' !default; // Class suffix for responsive hidden elements.
$visually-hidden-prefix: 'visually-hidden' !default; // Class prefix for responsive visually hidden elements.
$visually-hidden-small-suffix: 'sm' !default; // Class suffix for responsive hidden elements.
$visually-hidden-medium-breakpoint: 768px !default; // Medium screen breakpoint for responsive visually hidden elements.
$visually-hidden-medium-suffix: 'md' !default; // Class suffix for responsive hidden elements.
$visually-hidden-large-breakpoint: 1280px !default; // Medium screen breakpoint for responsive visually hidden elements.
$visually-hidden-large-suffix: 'lg' !default; // Class suffix for responsive hidden elements.
// CSS variable name definitions [exercise caution if modifying these]
$border-generic-color-var: '--generic-border-color' !default;
$box-shadow-generic-var: '--generic-box-shadow' !default;
// == Uncomment below code if this module is used on its own ==
//
// $universal-margin: 0.5rem !default; // Universal margin for the most elements
// $universal-padding: 0.5rem !default; // Universal padding for the most elements
// $universal-border-radius: 0.125rem !default; // Universal border-radius for most elements
// $universal-box-shadow: none !default; // Universal box-shadow for most elements
// $universal-margin-var: '--universal-margin' !default;
// $universal-padding-var: '--universal-padding' !default;
// $universal-border-radius-var: '--universal-border-radius' !default;
// $universal-box-shadow-var: '--universal-box-shadow' !default;
// :root {
// #{$universal-margin-var}: $universal-margin;
// #{$universal-padding-var}: $universal-padding;
// #{$universal-border-radius-var}: $universal-border-radius;
// @if $universal-box-shadow != none {
// #{$universal-box-shadow-var}: $universal-box-shadow;
// }
// }
//
// ============================================================
/* Utility module CSS variable definitions */
:root {
#{$border-generic-color-var}: $border-generic-color;
#{$box-shadow-generic-var}: $box-shadow-generic;
}
// Hidden elements class. NOTE: Uses !important.
.#{$hidden-name}{
display: none !important;
}
// Visually hidden elements class. NOTE: Uses !important.
.#{$visually-hidden-name} {
position: absolute !important;
width: 1px !important;
height: 1px !important;
margin: -1px !important;
border: 0 !important;
padding: 0 !important;
clip: rect(0 0 0 0) !important;
-webkit-clip-path: inset(100%) !important;
clip-path: inset(100%) !important;
overflow: hidden !important;
}
// Generic bordered element class. NOTE: Uses !important.
.#{$border-generic-name} {
border: $__1px solid var(#{$border-generic-color-var}) !important;
}
// Generic rounded-border element class. NOTE: Uses !important.
.#{$border-rounded-name} {
border-radius: var(#{$universal-border-radius-var}) !important;
}
// Generic circular-border element class. NOTE: Uses !important.
.#{$border-circular-name} {
border-radius: 50% !important;
}
// Generic box-shadow element class. NOTE: Uses !important.
.#{$box-shadow-generic-name} {
box-shadow: var(#{$box-shadow-generic-var}) !important;
}
// Responsive margin class. NOTE: Uses !important.
.#{$responsive-margin-name} {
margin: calc(var(#{$universal-margin-var}) / 4) !important;
@media screen and (min-width: #{$responsive-margin-medium-breakpoint}) {
margin: calc(var(#{$universal-margin-var}) / 2) !important;
}
@media screen and (min-width: #{$responsive-margin-large-breakpoint}) {
margin: var(#{$universal-margin-var}) !important;
}
}
// Responsive padding class. NOTE: Uses !important.
.#{$responsive-padding-name} {
padding: calc(var(#{$universal-padding-var}) / 4) !important;
@media screen and (min-width: #{$responsive-padding-medium-breakpoint}) {
padding: calc(var(#{$universal-padding-var}) / 2) !important;
}
@media screen and (min-width: #{$responsive-padding-large-breakpoint}) {
padding: var(#{$universal-padding-var}) !important;
}
}
// Responsive hidden element class. NOTE: Uses !important.
@media screen and (max-width: #{$hidden-medium-breakpoint}-1px) {
.#{$hidden-prefix}-#{$hidden-small-suffix} {
display: none !important;
}
}
@media screen and (min-width: #{$hidden-medium-breakpoint}) and (max-width: #{$hidden-large-breakpoint}-1px) {
.#{$hidden-prefix}-#{$hidden-medium-suffix} {
display: none !important;
}
}
@media screen and (min-width: #{$hidden-large-breakpoint}) {
.#{$hidden-prefix}-#{$hidden-large-suffix} {
display: none !important;
}
}
// Responsive visually hidden element class. NOTE: Uses !important.
@media screen and (max-width: #{$visually-hidden-medium-breakpoint}-1px) {
.#{$visually-hidden-prefix}-#{$visually-hidden-small-suffix} {
position: absolute !important;
width: 1px !important;
height: 1px !important;
margin: -1px !important;
border: 0 !important;
padding: 0 !important;
clip: rect(0 0 0 0) !important;
-webkit-clip-path: inset(100%) !important;
clip-path: inset(100%) !important;
overflow: hidden !important;
}
}
@media screen and (min-width: #{$visually-hidden-medium-breakpoint}) and (max-width: #{$visually-hidden-large-breakpoint}-1px) {
.#{$visually-hidden-prefix}-#{$visually-hidden-medium-suffix} {
position: absolute !important;
width: 1px !important;
height: 1px !important;
margin: -1px !important;
border: 0 !important;
padding: 0 !important;
clip: rect(0 0 0 0) !important;
-webkit-clip-path: inset(100%) !important;
clip-path: inset(100%) !important;
overflow: hidden !important;
}
}
@media screen and (min-width: #{$visually-hidden-large-breakpoint}) {
.#{$visually-hidden-prefix}-#{$visually-hidden-large-suffix} {
position: absolute !important;
width: 1px !important;
height: 1px !important;
margin: -1px !important;
border: 0 !important;
padding: 0 !important;
clip: rect(0 0 0 0) !important;
-webkit-clip-path: inset(100%) !important;
clip-path: inset(100%) !important;
overflow: hidden !important;
}
}