Updated resets

This commit is contained in:
squidfunk 2016-09-04 18:13:17 +02:00
parent adf6f50c3e
commit 6ac4b0f749
18 changed files with 1959 additions and 54 deletions

View File

@ -104,7 +104,7 @@ rules:
- 2
- style: double
shorthand-values: 2
single-line-per-selector: 0
single-line-per-selector: 2
space-after-bang: 2
space-after-colon: 2
space-after-comma: 2

View File

@ -11,7 +11,7 @@ mkdocs-material-1.0.0-rc.1 (2016-XX-XX)
* Introduced ESLint and SassLint for code style checks
* Introduced more accurate Material Design colors and shadows
* Introduced Modular Scales for harmonic font sizing
* Rewrite of CSS using the BEM methodology
* Rewrite of CSS using the BEM methodology and SassDoc styles
* Rewrite of JavaScript using ES6 and Babel as a transpiler
* Rewrite of Admonition, Permalinks and Codehilite integration
* Rewrite of the complete typographical system

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -25,14 +25,14 @@
<meta name="author" content="{{ site_author }}">
{% endif %}
{% endblock %}
<link rel="stylesheet" href="{{ base_url }}/assets/stylesheets/application-67e8d741f4.css">
<link rel="stylesheet" href="{{ base_url }}/assets/stylesheets/application-984ab9f73e.css">
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Roboto:300,400,700">
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Roboto+Mono:400,700">
<link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons">
{% for path in extra_css %}
<link rel="stylesheet" href="{{ path }}">
{% endfor %}
<script src="{{ base_url }}/assets/javascripts/modernizr-d41d8cd98f.js"></script>
<script src="{{ base_url }}/assets/javascripts/modernizr-ca288b1d5b.js"></script>
</head>
<body>
<input class="md-toggle md-toggle--drawer" type="checkbox" id="drawer">

View File

@ -1,6 +1,6 @@
{
"assets/images/favicon.ico": "assets/images/favicon-e565ddfa3b.ico",
"assets/javascripts/application.js": "assets/javascripts/application-e9877e2824.js",
"assets/javascripts/modernizr.js": "assets/javascripts/modernizr-d41d8cd98f.js",
"assets/stylesheets/application.css": "assets/stylesheets/application-67e8d741f4.css"
"assets/javascripts/modernizr.js": "assets/javascripts/modernizr-ca288b1d5b.js",
"assets/stylesheets/application.css": "assets/stylesheets/application-984ab9f73e.css"
}

View File

@ -1,7 +1,7 @@
<div class="md-sidebar md-sidebar--primary md-js__sidebar">
<div class="md-sidebar__scrollwrap">
<nav class="md-sidebar__inner md-nav">
<h3>Navigation</h3>
<h3 class="md-nav__title">Navigation</h3>
<ul class="md-nav__list">
{% for nav_item in nav %}
{% set path = "md-toggle-nav-" + loop.index | string %}

View File

@ -5,7 +5,7 @@
{% set toc = (toc | first).children %}
{% endif %}
{% if toc and (toc | first) %}
<h3>Table of contents</h3>
<h3 class="md-nav__title">Table of contents</h3>
<ul class="md-nav__list">
{% for toc_item in toc %}
{% include "toc-item.html" %}

View File

@ -33,7 +33,9 @@ html {
}
// All elements shall inherit the document default
*, *::before, *::after {
*,
*::before,
*::after {
box-sizing: inherit;
-moz-box-sizing: inherit;
-webkit-box-sizing: inherit;
@ -46,17 +48,81 @@ html {
text-size-adjust: none;
}
// Reset spacing and borders for all tags
html, body, div, span, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote,
pre, a, abbr, acronym, address, big, cite, code, del, dfn, em, img, ins, kbd,
q, s, samp, small, strike, strong, sub, sup, tt, var, b, u, i, dl, dt, dd, ol,
ul, li, fieldset, form, label, legend, table, caption, tbody, tfoot, thead, tr,
th, td, article, aside, canvas, details, embed, figure, figcaption, footer,
header, hgroup, main, menu, nav, output, ruby, section, summary, time, mark,
audio, video {
// Remove margin in all browsers
body {
margin: 0;
padding: 0;
border: 0;
}
// Add correct display property in IE < 9
article,
aside,
figcaption,
figure,
footer,
header,
main,
nav,
section {
display: block;
}
// Reset horizontal rules in FF
hr {
overflow: visible;
box-sizing: content-box;
}
// Reset link styles
a {
color: inherit;
text-decoration: none;
// Remove outline on focused or active links
&:active,
&:hover {
outline-width: 0;
}
}
// Remove gaps in links underline in iOS >= 8 and Safari >= 8
a {
-webkit-text-decoration-skip: objects;
}
// Reset tap outlines on iOS and Android
a,
button,
label,
input {
-webkit-tap-highlight-color: transparent;
}
// Correct font-size in all browsers
small {
font-size: 80%;
}
// Prevent subscript and superscript from affecting line-height
sub,
sup {
position: relative;
font-size: 80%;
line-height: 0;
vertical-align: baseline;
}
// Correct subscript offset
sub {
bottom: -0.25em;
}
// Correct superscript offset
sup {
top: -0.5em;
}
img {
border-style: none;
}
// Reset table styles
@ -66,7 +132,8 @@ table {
}
// Reset table cell styles
td, th {
td,
th {
font-weight: normal;
text-align: left;
vertical-align: top;
@ -88,13 +155,4 @@ input {
appearance: none;
}
// Reset link styles
a {
color: inherit;
text-decoration: none;
}
// Reset tap outlines on iOS and Android
a, button, label, input {
-webkit-tap-highlight-color: transparent;
}

View File

@ -25,7 +25,8 @@
// ----------------------------------------------------------------------------
// Default fonts
body, kbd {
body,
kbd {
font-family: "Roboto", Helvetica, Arial, sans-serif;
font-weight: 400;
font-feature-settings: "kern", "onum", "liga";
@ -41,7 +42,8 @@ body, kbd {
}
// Proportionally spaced fonts
pre, code {
pre,
code {
font-family: "Roboto Mono", "Courier New", Courier, monospace;
// Use system fonts, if browser doesn't support webfonts
@ -66,6 +68,7 @@ pre, code {
// 1st level headline
h1 {
margin: 0 0 4.0rem;
color: $md-color-black--light;
font-size: ms(3);
font-weight: 300;
@ -75,7 +78,7 @@ pre, code {
// 2nd level headline
h2 {
margin-top: 4.0rem;
margin: 4.0rem 0 1.6rem;
font-size: ms(2);
font-weight: 300;
letter-spacing: -0.01em;
@ -84,7 +87,7 @@ pre, code {
// 3rd level headline
h3 {
margin-top: 3.2rem;
margin: 3.2rem 0 1.6rem;
font-size: ms(1);
font-weight: 400;
letter-spacing: -0.01em;
@ -98,7 +101,7 @@ pre, code {
// 4th level headline
h4 {
margin-top: 1.6rem;
margin: 1.6rem 0;
font-size: ms(0);
font-weight: 700;
letter-spacing: -0.01em;
@ -107,7 +110,7 @@ pre, code {
// 5th and 6th level headline
h5,
h6 {
margin-top: 1.6rem;
margin: 1.6rem 0;
color: $md-color-black--light;
font-size: ms(-1);
font-weight: 700;
@ -119,6 +122,12 @@ pre, code {
text-transform: uppercase;
}
// Horizontal separators
hr {
margin: 2.4rem 0;
border-bottom: px2rem(1px) dotted $md-color-black--lighter;
}
// Links
a {
color: $md-color-primary;
@ -181,7 +190,6 @@ pre, code {
// Smaller text
small {
color: $md-color-black--light;
font-size: smaller;
}
// Superscript and subscript
@ -190,12 +198,6 @@ pre, code {
margin-left: 0.1rem;
}
// Horizontal separators
hr {
margin: 2.4rem 0;
border-bottom: px2rem(1px) dotted $md-color-black--lighter;
}
// Blockquotes, possibly nested
blockquote {
padding-left: 1.2rem;

View File

@ -109,8 +109,8 @@
.ss { color: #990073; } // Literal.String.Symbol
// Diffs
.gd { background-color: #ffdddd; } // Generic.Deleted
.gi { background-color: #ddffdd; } // Generic.Inserted
.gd { background-color: #FFDDDD; } // Generic.Deleted
.gi { background-color: #DDFFDD; } // Generic.Inserted
// Miscellaneous
.w { color: transparent; } // Text.Whitespace

View File

@ -30,7 +30,7 @@
// Footnote
.footnote {
color: $md-color-black--light;
font-size: smaller;
font-size: 80%;
// Remove additional spacing on footnotes
> ol {

View File

@ -26,12 +26,14 @@
// Nested navigation
.md-nav {
font-size: ms(-1);
line-height: 1.2;
// Set font sizes
&,
h3 {
font-size: ms(-1);
line-height: 1.2;
// Title
&__title {
margin: 0;
font-size: inherit;
line-height: inherit;
}
// Table of contents
@ -41,6 +43,8 @@
// List of items
&__list {
margin: 0;
padding: 0;
list-style: none;
// 2nd+ level list

View File

@ -24,7 +24,7 @@
<div class="md-sidebar md-sidebar--primary md-js__sidebar">
<div class="md-sidebar__scrollwrap">
<nav class="md-sidebar__inner md-nav">
<h3>Navigation</h3>
<h3 class="md-nav__title">Navigation</h3>
<ul class="md-nav__list">
{% for nav_item in nav %}
{% set path = "md-toggle-nav-" + loop.index | string %}

View File

@ -37,7 +37,7 @@
<!-- Render item list -->
{% if toc and (toc | first) %}
<h3>Table of contents</h3>
<h3 class="md-nav__title">Table of contents</h3>
<ul class="md-nav__list">
{% for toc_item in toc %}
{% include "toc-item.html" %}