Skip to content

Instantly share code, notes, and snippets.

@janpecha janpecha/index.html
Last active Dec 25, 2015

Embed
What would you like to do?
MiniTypro - a tiny CSS framework
<!DOCTYPE html>
<html lang="cs">
<head>
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" type="text/css" href="minitypro.css">
<title>MiniTypro - basic example</title>
</head>
<body>
<h1>MiniTypro</h1>
<div class="row">
<div class="column column-1p4">
<div class="box">
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse
cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non
proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
</div>
<div class="box info">
<h2>Lorem ipsum</h2>
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse
cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non
proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
</div>
</div>
<div class="column column-1p4">
<div class="box success">
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse
cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non
proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
</div>
<div class="box warning">
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse
cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non
proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
</div>
</div>
<div class="column column-1p2">
<form class="form">
<label for="name">Name:</label> <input id="name" type="text">
<label for="surname">Surname:</label> <input id="surname" type="text">
<label for="mail">E-mail:</label> <input id="mail" type="text">
<label for="product">Product:</label>
<select id="product">
<option>Product A</option>
<option>Product B</option>
</select>
<label for="text">Text:</label> <textarea id="text"></textarea>
<input type="submit" value="Send">
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse
cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non
proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>
<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse
cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non
proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>
</form>
<table class="table">
<thead>
<tr>
<th>&nbsp;</th>
<th>ID</th>
<th>Name</th>
<th>&nbsp;</th>
</tr>
</thead>
<tr>
<th>Row #1</th>
<td>1</td>
<td>John Doe</td>
<td><a href="#">Detail</a></td>
</tr>
<tr>
<th>Row #2</th>
<td>5</td>
<td>Neo</td>
<td><a href="#">Detail</a></td>
</tr>
<tr>
<th>Row #3</th>
<td>6</td>
<td>Morfeus</td>
<td><a href="#">Detail</a></td>
</tr>
<tr>
<th>Row #4</th>
<td>7</td>
<td>Gandalf</td>
<td><a href="#">Detail</a></td>
</tr>
<tfoot>
<tr>
<th>&nbsp;</th>
<th>ID</th>
<th>Name</th>
<th>&nbsp;</th>
</tr>
</tfoot>
</table>
</div>
</div>
<div class="box error">
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse
cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non
proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
</div>
</body>
</html>
/**
* Mini-Typro
* @author Jan Pecha, 2014
* @license New BSD License (BSD-3)
*/
body {
margin: 0;
padding: 1em; /* 0 */
font-size: 100%;
font: inherit;
vertical-align: baseline;
line-height: 1.6;
text-align: left;
font-family: 'Arial CE', 'Helvetica CE', Arial, Verdana, Helvetica, sans-serif;
color: #222;
}
/* headings */
h1, h2, h3, h4, h5, h6 {
font-weight: bold;
margin-bottom: 0.15em;
line-height: 1.4;
color: #444;
}
h2:first-child,
h3:first-child,
h4:first-child,
h5:first-child,
h6:first-child {
margin-top: 0;
}
h1 {
margin-top: 0;
font-size: 250%;
}
.form,
.table {
margin: 0 0 1em;
}
/* forms */
.form textarea,
.form input,
.form select {
display: block;
margin-bottom: 1em;
padding: 1em;
font-size: 90%;
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
box-sizing: border-box;
}
.form textarea {
width: 100%;
-moz-resize: vertical;
resize: vertical;
}
.form input,
.form select {
padding-top: 0.5em;
padding-bottom: 0.5em;
}
/* tables */
.table {
width: 100%;
/*background: red;*/
border-spacing: 0;
border: 1px solid silver;
border-width: 0 1px 1px 0;
}
.table tr {
background: #fff;
}
.table tr:nth-child(odd) {
background-color: #f4f4f4;
}
.table th,
.table td {
text-align: left;
padding: 0.4em 1em;
border: 1px solid silver;
border-width: 1px 0 0 1px;
}
.table th {
background: #eee;
}
.table thead th,
.table tfoot th {
text-align: center;
}
/* grid */
.row {
overflow: hidden;
}
.column {
display: block;
float: left;
width: 50%;
text-align: left;
padding-left: 0.5em;
padding-right: 0.5em;
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
box-sizing: border-box;
}
.column:last-child {
padding-right: 0;
}
.column:first-child {
padding-left: 0;
}
.column-1p2 {
width: 50%;
}
.column-1p3 {
width: 33.33333333333333%;
}
.column-1p4 {
width: 25%;
}
.column-2p3 {
width: 66.66666666666666%;
}
.column-3p4 {
width: 75%;
}
/* box */
.box {
background: #eee;
padding: 1em;
margin-bottom: 1em;
}
.box.info {
background: #C3E0FF;
}
.box.success {
background: #C3F1AF;
}
.box.warning {
background: #FFF991;
}
.box.error,
.box.danger {
background: #FECCC8;
}
.box p:last-child {
margin-bottom: 0;
}
/* elements */
p {
margin-top: 0;
}
a:link {
color: #0044aa;
}
a:visited {
color: #00255c;
}
a:hover {
color: #d22;
}
@janpecha

This comment has been minimized.

Copy link
Owner Author

commented Jul 5, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.