madness 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/styles/_anchor.scss +15 -15
- data/app/styles/_breadcrumbs.scss +8 -8
- data/app/styles/_code.scss +54 -54
- data/app/styles/_coderay.scss +9 -9
- data/app/styles/_general.scss +33 -33
- data/app/styles/_image.scss +7 -7
- data/app/styles/_keyboard.scss +14 -14
- data/app/styles/_line.scss +28 -28
- data/app/styles/_list.scss +44 -44
- data/app/styles/_manifest.scss +14 -14
- data/app/styles/_nav.scss +35 -35
- data/app/styles/_search.scss +24 -24
- data/app/styles/_table.scss +28 -28
- data/app/styles/_typography.scss +62 -62
- data/app/styles/main.scss +28 -28
- data/app/views/_breadcrumbs.slim +8 -8
- data/app/views/_content.slim +6 -6
- data/app/views/_index_nav.slim +5 -5
- data/app/views/_nav.slim +11 -11
- data/app/views/document.slim +11 -11
- data/app/views/layout.slim +7 -7
- data/app/views/search.slim +25 -25
- data/lib/madness.rb +1 -1
- data/lib/madness/breadcrumbs.rb +36 -36
- data/lib/madness/command_line.rb +77 -77
- data/lib/madness/docopt.txt +40 -40
- data/lib/madness/document.rb +98 -98
- data/lib/madness/navigation.rb +60 -60
- data/lib/madness/search.rb +63 -63
- data/lib/madness/server.rb +39 -39
- data/lib/madness/server_base.rb +36 -36
- data/lib/madness/server_helper.rb +21 -21
- data/lib/madness/settings.rb +65 -65
- data/lib/madness/version.rb +1 -1
- metadata +3 -4
data/app/styles/_manifest.scss
CHANGED
@@ -1,15 +1,15 @@
|
|
1
|
-
@import "typography";
|
2
|
-
@import "table";
|
3
|
-
@import "anchor";
|
4
|
-
@import "list";
|
5
|
-
@import "code";
|
6
|
-
@import "coderay";
|
7
|
-
@import "image";
|
8
|
-
@import "line";
|
9
|
-
@import "keyboard";
|
10
|
-
@import "search";
|
11
|
-
@import "breadcrumbs";
|
12
|
-
@import "nav";
|
13
|
-
|
14
|
-
// Last
|
1
|
+
@import "typography";
|
2
|
+
@import "table";
|
3
|
+
@import "anchor";
|
4
|
+
@import "list";
|
5
|
+
@import "code";
|
6
|
+
@import "coderay";
|
7
|
+
@import "image";
|
8
|
+
@import "line";
|
9
|
+
@import "keyboard";
|
10
|
+
@import "search";
|
11
|
+
@import "breadcrumbs";
|
12
|
+
@import "nav";
|
13
|
+
|
14
|
+
// Last
|
15
15
|
@import "general";
|
data/app/styles/_nav.scss
CHANGED
@@ -1,35 +1,35 @@
|
|
1
|
-
nav {
|
2
|
-
@media print {
|
3
|
-
display: none;
|
4
|
-
}
|
5
|
-
background: #eee;
|
6
|
-
height: 100vh;
|
7
|
-
width: 250px;
|
8
|
-
overflow-y: auto;
|
9
|
-
position: fixed;
|
10
|
-
padding: 10px 0;
|
11
|
-
border-right: 1px solid #eee;
|
12
|
-
a, span {
|
13
|
-
&:hover {
|
14
|
-
background: #e4e4e4;
|
15
|
-
}
|
16
|
-
display: block;
|
17
|
-
padding: 3px 20px 3px 30px;
|
18
|
-
margin-bottom: 4px;
|
19
|
-
}
|
20
|
-
&:after {
|
21
|
-
content: "";
|
22
|
-
height: 90px;
|
23
|
-
display: block;
|
24
|
-
}
|
25
|
-
}
|
26
|
-
|
27
|
-
|
28
|
-
// Nicer sidebar scrollbars
|
29
|
-
::-webkit-scrollbar {
|
30
|
-
width: 6px;
|
31
|
-
}
|
32
|
-
::-webkit-scrollbar-thumb {
|
33
|
-
background: #ddd;
|
34
|
-
-webkit-border-radius: 3px;
|
35
|
-
}
|
1
|
+
nav {
|
2
|
+
@media print {
|
3
|
+
display: none;
|
4
|
+
}
|
5
|
+
background: #eee;
|
6
|
+
height: 100vh;
|
7
|
+
width: 250px;
|
8
|
+
overflow-y: auto;
|
9
|
+
position: fixed;
|
10
|
+
padding: 10px 0;
|
11
|
+
border-right: 1px solid #eee;
|
12
|
+
a, span {
|
13
|
+
&:hover {
|
14
|
+
background: #e4e4e4;
|
15
|
+
}
|
16
|
+
display: block;
|
17
|
+
padding: 3px 20px 3px 30px;
|
18
|
+
margin-bottom: 4px;
|
19
|
+
}
|
20
|
+
&:after {
|
21
|
+
content: "";
|
22
|
+
height: 90px;
|
23
|
+
display: block;
|
24
|
+
}
|
25
|
+
}
|
26
|
+
|
27
|
+
|
28
|
+
// Nicer sidebar scrollbars
|
29
|
+
::-webkit-scrollbar {
|
30
|
+
width: 6px;
|
31
|
+
}
|
32
|
+
::-webkit-scrollbar-thumb {
|
33
|
+
background: #ddd;
|
34
|
+
-webkit-border-radius: 3px;
|
35
|
+
}
|
data/app/styles/_search.scss
CHANGED
@@ -1,24 +1,24 @@
|
|
1
|
-
.search-form {
|
2
|
-
margin-bottom: 20px;
|
3
|
-
}
|
4
|
-
|
5
|
-
.search-field {
|
6
|
-
outline: none;
|
7
|
-
padding: 8px 12px;
|
8
|
-
font-size: 1.5em;
|
9
|
-
width: 50%;
|
10
|
-
min-width: 200px;
|
11
|
-
|
12
|
-
border: #ccc 1px solid;
|
13
|
-
border-radius: 3px;
|
14
|
-
|
15
|
-
&:focus {
|
16
|
-
border-color: #4078c0;
|
17
|
-
}
|
18
|
-
}
|
19
|
-
|
20
|
-
.search-excerpt {
|
21
|
-
@extend blockquote;
|
22
|
-
white-space: pre-wrap;
|
23
|
-
}
|
24
|
-
|
1
|
+
.search-form {
|
2
|
+
margin-bottom: 20px;
|
3
|
+
}
|
4
|
+
|
5
|
+
.search-field {
|
6
|
+
outline: none;
|
7
|
+
padding: 8px 12px;
|
8
|
+
font-size: 1.5em;
|
9
|
+
width: 50%;
|
10
|
+
min-width: 200px;
|
11
|
+
|
12
|
+
border: #ccc 1px solid;
|
13
|
+
border-radius: 3px;
|
14
|
+
|
15
|
+
&:focus {
|
16
|
+
border-color: #4078c0;
|
17
|
+
}
|
18
|
+
}
|
19
|
+
|
20
|
+
.search-excerpt {
|
21
|
+
@extend blockquote;
|
22
|
+
white-space: pre-wrap;
|
23
|
+
}
|
24
|
+
|
data/app/styles/_table.scss
CHANGED
@@ -1,28 +1,28 @@
|
|
1
|
-
table {
|
2
|
-
border-spacing: 0;
|
3
|
-
border-collapse: collapse;
|
4
|
-
|
5
|
-
display: block;
|
6
|
-
width: 100%;
|
7
|
-
overflow: auto;
|
8
|
-
word-break: normal;
|
9
|
-
word-break: keep-all;
|
10
|
-
|
11
|
-
th {
|
12
|
-
font-weight: bold;
|
13
|
-
}
|
14
|
-
|
15
|
-
th, td {
|
16
|
-
padding: 6px 13px;
|
17
|
-
border: 1px solid #ddd;
|
18
|
-
}
|
19
|
-
|
20
|
-
tr {
|
21
|
-
background-color: #fff;
|
22
|
-
border-top: 1px solid #ccc;
|
23
|
-
}
|
24
|
-
|
25
|
-
tr:nth-child(2n) {
|
26
|
-
background-color: #f8f8f8;
|
27
|
-
}
|
28
|
-
}
|
1
|
+
table {
|
2
|
+
border-spacing: 0;
|
3
|
+
border-collapse: collapse;
|
4
|
+
|
5
|
+
display: block;
|
6
|
+
width: 100%;
|
7
|
+
overflow: auto;
|
8
|
+
word-break: normal;
|
9
|
+
word-break: keep-all;
|
10
|
+
|
11
|
+
th {
|
12
|
+
font-weight: bold;
|
13
|
+
}
|
14
|
+
|
15
|
+
th, td {
|
16
|
+
padding: 6px 13px;
|
17
|
+
border: 1px solid #ddd;
|
18
|
+
}
|
19
|
+
|
20
|
+
tr {
|
21
|
+
background-color: #fff;
|
22
|
+
border-top: 1px solid #ccc;
|
23
|
+
}
|
24
|
+
|
25
|
+
tr:nth-child(2n) {
|
26
|
+
background-color: #f8f8f8;
|
27
|
+
}
|
28
|
+
}
|
data/app/styles/_typography.scss
CHANGED
@@ -1,62 +1,62 @@
|
|
1
|
-
body {
|
2
|
-
-ms-text-size-adjust: 100%;
|
3
|
-
-webkit-text-size-adjust: 100%;
|
4
|
-
color: #333;
|
5
|
-
font-family: "Helvetica Neue", Helvetica, "Segoe UI", Arial, freesans, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
|
6
|
-
font-size: 16px;
|
7
|
-
line-height: 1.6;
|
8
|
-
word-wrap: break-word;
|
9
|
-
}
|
10
|
-
|
11
|
-
strong, .strong {
|
12
|
-
font-weight: bolder;
|
13
|
-
}
|
14
|
-
|
15
|
-
h1, h2, h3, h4, h5, h6 {
|
16
|
-
margin-top: 1em;
|
17
|
-
margin-bottom: 16px;
|
18
|
-
font-weight: bold;
|
19
|
-
line-height: 1.4;
|
20
|
-
}
|
21
|
-
|
22
|
-
h1 {
|
23
|
-
margin: 0.67em 0;
|
24
|
-
padding-bottom: 0.3em;
|
25
|
-
font-size: 2.25em;
|
26
|
-
line-height: 1.2;
|
27
|
-
border-bottom: 1px solid #eee;
|
28
|
-
}
|
29
|
-
|
30
|
-
h2 {
|
31
|
-
padding-bottom: 0.3em;
|
32
|
-
font-size: 1.75em;
|
33
|
-
line-height: 1.225;
|
34
|
-
border-bottom: 1px solid #eee;
|
35
|
-
}
|
36
|
-
|
37
|
-
h3 {
|
38
|
-
font-size: 1.5em;
|
39
|
-
line-height: 1.43;
|
40
|
-
}
|
41
|
-
|
42
|
-
h4 {
|
43
|
-
font-size: 1.25em;
|
44
|
-
}
|
45
|
-
|
46
|
-
h5 {
|
47
|
-
font-size: 1em;
|
48
|
-
}
|
49
|
-
|
50
|
-
h6 {
|
51
|
-
font-size: 1em;
|
52
|
-
color: #777;
|
53
|
-
}
|
54
|
-
|
55
|
-
code, kbd, pre {
|
56
|
-
font-family: monospace, monospace;
|
57
|
-
font-size: 1em;
|
58
|
-
}
|
59
|
-
|
60
|
-
code, pre, kbd {
|
61
|
-
font-family: Consolas, "Liberation Mono", Menlo, Courier, monospace;
|
62
|
-
}
|
1
|
+
body {
|
2
|
+
-ms-text-size-adjust: 100%;
|
3
|
+
-webkit-text-size-adjust: 100%;
|
4
|
+
color: #333;
|
5
|
+
font-family: "Helvetica Neue", Helvetica, "Segoe UI", Arial, freesans, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
|
6
|
+
font-size: 16px;
|
7
|
+
line-height: 1.6;
|
8
|
+
word-wrap: break-word;
|
9
|
+
}
|
10
|
+
|
11
|
+
strong, .strong {
|
12
|
+
font-weight: bolder;
|
13
|
+
}
|
14
|
+
|
15
|
+
h1, h2, h3, h4, h5, h6 {
|
16
|
+
margin-top: 1em;
|
17
|
+
margin-bottom: 16px;
|
18
|
+
font-weight: bold;
|
19
|
+
line-height: 1.4;
|
20
|
+
}
|
21
|
+
|
22
|
+
h1 {
|
23
|
+
margin: 0.67em 0;
|
24
|
+
padding-bottom: 0.3em;
|
25
|
+
font-size: 2.25em;
|
26
|
+
line-height: 1.2;
|
27
|
+
border-bottom: 1px solid #eee;
|
28
|
+
}
|
29
|
+
|
30
|
+
h2 {
|
31
|
+
padding-bottom: 0.3em;
|
32
|
+
font-size: 1.75em;
|
33
|
+
line-height: 1.225;
|
34
|
+
border-bottom: 1px solid #eee;
|
35
|
+
}
|
36
|
+
|
37
|
+
h3 {
|
38
|
+
font-size: 1.5em;
|
39
|
+
line-height: 1.43;
|
40
|
+
}
|
41
|
+
|
42
|
+
h4 {
|
43
|
+
font-size: 1.25em;
|
44
|
+
}
|
45
|
+
|
46
|
+
h5 {
|
47
|
+
font-size: 1em;
|
48
|
+
}
|
49
|
+
|
50
|
+
h6 {
|
51
|
+
font-size: 1em;
|
52
|
+
color: #777;
|
53
|
+
}
|
54
|
+
|
55
|
+
code, kbd, pre {
|
56
|
+
font-family: monospace, monospace;
|
57
|
+
font-size: 1em;
|
58
|
+
}
|
59
|
+
|
60
|
+
code, pre, kbd {
|
61
|
+
font-family: Consolas, "Liberation Mono", Menlo, Courier, monospace;
|
62
|
+
}
|
data/app/styles/main.scss
CHANGED
@@ -1,28 +1,28 @@
|
|
1
|
-
@import "manifest";
|
2
|
-
|
3
|
-
body {
|
4
|
-
max-width: 1300px;
|
5
|
-
margin: 0 auto;
|
6
|
-
}
|
7
|
-
|
8
|
-
.main {
|
9
|
-
@media print {
|
10
|
-
margin-left: 0;
|
11
|
-
border-width: 0;
|
12
|
-
}
|
13
|
-
padding: 0 20px 100px 20px;
|
14
|
-
margin-left: 250px;
|
15
|
-
border:1px solid #ccc;
|
16
|
-
border-width: 0 1px;
|
17
|
-
min-height: 100vh;
|
18
|
-
|
19
|
-
&:before, &:after {
|
20
|
-
display: table;
|
21
|
-
content: "";
|
22
|
-
}
|
23
|
-
|
24
|
-
&:after {
|
25
|
-
// clear: both;
|
26
|
-
}
|
27
|
-
}
|
28
|
-
|
1
|
+
@import "manifest";
|
2
|
+
|
3
|
+
body {
|
4
|
+
max-width: 1300px;
|
5
|
+
margin: 0 auto;
|
6
|
+
}
|
7
|
+
|
8
|
+
.main {
|
9
|
+
@media print {
|
10
|
+
margin-left: 0;
|
11
|
+
border-width: 0;
|
12
|
+
}
|
13
|
+
padding: 0 20px 100px 20px;
|
14
|
+
margin-left: 250px;
|
15
|
+
border:1px solid #ccc;
|
16
|
+
border-width: 0 1px;
|
17
|
+
min-height: 100vh;
|
18
|
+
|
19
|
+
&:before, &:after {
|
20
|
+
display: table;
|
21
|
+
content: "";
|
22
|
+
}
|
23
|
+
|
24
|
+
&:after {
|
25
|
+
// clear: both;
|
26
|
+
}
|
27
|
+
}
|
28
|
+
|
data/app/views/_breadcrumbs.slim
CHANGED
@@ -1,8 +1,8 @@
|
|
1
|
-
- unless breadcrumbs.empty?
|
2
|
-
.breadcrumbs
|
3
|
-
- breadcrumbs.each do |item|
|
4
|
-
- if item.last
|
5
|
-
span = item.label
|
6
|
-
- else
|
7
|
-
a href="#{item.href}" = item.label
|
8
|
-
= " / "
|
1
|
+
- unless breadcrumbs.empty?
|
2
|
+
.breadcrumbs
|
3
|
+
- breadcrumbs.each do |item|
|
4
|
+
- if item.last
|
5
|
+
span = item.label
|
6
|
+
- else
|
7
|
+
a href="#{item.href}" = item.label
|
8
|
+
= " / "
|
data/app/views/_content.slim
CHANGED
@@ -1,6 +1,6 @@
|
|
1
|
-
- if content.empty?
|
2
|
-
h1 = nav.caption || "Index"
|
3
|
-
|
4
|
-
- else
|
5
|
-
== content
|
6
|
-
|
1
|
+
- if content.empty?
|
2
|
+
h1 = nav.caption || "Index"
|
3
|
+
|
4
|
+
- else
|
5
|
+
== content
|
6
|
+
|
data/app/views/_index_nav.slim
CHANGED
@@ -1,5 +1,5 @@
|
|
1
|
-
ul
|
2
|
-
- nav.links.each do |item|
|
3
|
-
li
|
4
|
-
a href="#{item.href}" class=('strong' if item.type == :dir)
|
5
|
-
= item.label
|
1
|
+
ul
|
2
|
+
- nav.links.each do |item|
|
3
|
+
li
|
4
|
+
a href="#{item.href}" class=('strong' if item.type == :dir)
|
5
|
+
= item.label
|
data/app/views/_nav.slim
CHANGED
@@ -1,11 +1,11 @@
|
|
1
|
-
nav
|
2
|
-
a.strong href="/" accesskey='h' Home
|
3
|
-
- if nav.with_search?
|
4
|
-
a.strong href="/_search" accesskey='s' Search
|
5
|
-
|
6
|
-
- if nav.caption
|
7
|
-
span.strong = "#{nav.caption}:"
|
8
|
-
|
9
|
-
- nav.links.each do |item|
|
10
|
-
a href="#{item.href}" class=('strong' if item.type == :dir)
|
11
|
-
= item.label
|
1
|
+
nav
|
2
|
+
a.strong href="/" accesskey='h' Home
|
3
|
+
- if nav.with_search?
|
4
|
+
a.strong href="/_search" accesskey='s' Search
|
5
|
+
|
6
|
+
- if nav.caption
|
7
|
+
span.strong = "#{nav.caption}:"
|
8
|
+
|
9
|
+
- nav.links.each do |item|
|
10
|
+
a href="#{item.href}" class=('strong' if item.type == :dir)
|
11
|
+
= item.label
|