middleman 3.0.0.alpha.5 → 3.0.0.alpha.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (58) hide show
  1. data/CHANGELOG.md +3 -2
  2. data/README.md +7 -7
  3. data/bin/middleman +3 -2
  4. data/features/builder.feature +4 -0
  5. data/features/cli.feature +10 -11
  6. data/features/nested_layouts.feature +24 -0
  7. data/features/sitemap_traversal.features +56 -0
  8. data/fixtures/empty-app/not-config.rb +0 -0
  9. data/fixtures/nested-layout-app/config.rb +1 -0
  10. data/fixtures/nested-layout-app/source/data-one.html.erb +5 -0
  11. data/fixtures/nested-layout-app/source/data-two.html.erb +5 -0
  12. data/fixtures/nested-layout-app/source/index.html.erb +1 -0
  13. data/fixtures/nested-layout-app/source/layouts/inner.erb +4 -0
  14. data/fixtures/nested-layout-app/source/layouts/master.erb +3 -0
  15. data/fixtures/nested-layout-app/source/layouts/outer.erb +4 -0
  16. data/fixtures/traversal-app/config.rb +2 -0
  17. data/fixtures/traversal-app/source/index.html.erb +0 -0
  18. data/fixtures/traversal-app/source/layout.erb +13 -0
  19. data/fixtures/traversal-app/source/proxied.html.erb +0 -0
  20. data/fixtures/traversal-app/source/root.html.erb +0 -0
  21. data/fixtures/traversal-app/source/sub/index.html.erb +0 -0
  22. data/fixtures/traversal-app/source/sub/sibling.html.erb +0 -0
  23. data/fixtures/traversal-app/source/sub/sibling2.html.erb +0 -0
  24. data/fixtures/traversal-app/source/sub/sub2/index.html.erb +0 -0
  25. data/fixtures/traversal-app/source/sub/sub3/deep.html.erb +0 -0
  26. data/lib/middleman.rb +0 -3
  27. data/lib/middleman/base.rb +3 -28
  28. data/lib/middleman/cli/server.rb +0 -1
  29. data/lib/middleman/core_extensions/builder.rb +1 -7
  30. data/lib/middleman/core_extensions/default_helpers.rb +27 -1
  31. data/lib/middleman/core_extensions/extensions.rb +20 -4
  32. data/lib/middleman/core_extensions/file_watcher.rb +25 -8
  33. data/lib/middleman/core_extensions/front_matter.rb +5 -12
  34. data/lib/middleman/core_extensions/rendering.rb +10 -0
  35. data/lib/middleman/core_extensions/sitemap.rb +4 -0
  36. data/lib/middleman/guard.rb +11 -11
  37. data/lib/middleman/sitemap/page.rb +55 -0
  38. data/lib/middleman/sitemap/template.rb +9 -3
  39. data/lib/middleman/step_definitions.rb +0 -1
  40. data/lib/middleman/templates/default.rb +7 -2
  41. data/lib/middleman/templates/default/source/images/background.png +0 -0
  42. data/lib/middleman/templates/default/source/images/middleman.png +0 -0
  43. data/lib/middleman/templates/default/source/index.html.erb +9 -4
  44. data/lib/middleman/templates/default/source/javascripts/all.js +1 -0
  45. data/lib/middleman/templates/default/source/layouts/layout.erb +19 -0
  46. data/lib/middleman/templates/default/source/stylesheets/_animate.scss +23 -0
  47. data/lib/middleman/templates/default/source/stylesheets/_normalize.scss +431 -0
  48. data/lib/middleman/templates/default/source/stylesheets/all.css.scss +40 -0
  49. data/lib/middleman/templates/shared/config.tt +4 -16
  50. data/lib/middleman/version.rb +1 -1
  51. data/middleman-x86-mingw32.gemspec +1 -1
  52. data/middleman.gemspec +1 -1
  53. metadata +54 -13
  54. data/features/generator.feature +0 -8
  55. data/lib/middleman/extensions/sitemap_tree.rb +0 -38
  56. data/lib/middleman/step_definitions/generator_steps.rb +0 -26
  57. data/lib/middleman/templates/default/source/layout.erb +0 -19
  58. data/lib/middleman/templates/default/source/stylesheets/site.css.scss +0 -32
@@ -0,0 +1,431 @@
1
+ /*! normalize.css 2011-11-04T15:38 UTC - http://github.com/necolas/normalize.css */
2
+
3
+ /* =============================================================================
4
+ HTML5 display definitions
5
+ ========================================================================== */
6
+
7
+ /*
8
+ * Corrects block display not defined in IE6/7/8/9 & FF3
9
+ */
10
+
11
+ article,
12
+ aside,
13
+ details,
14
+ figcaption,
15
+ figure,
16
+ footer,
17
+ header,
18
+ hgroup,
19
+ nav,
20
+ section {
21
+ display: block;
22
+ }
23
+
24
+ /*
25
+ * Corrects inline-block display not defined in IE6/7/8/9 & FF3
26
+ */
27
+
28
+ audio,
29
+ canvas,
30
+ video {
31
+ display: inline-block;
32
+ *display: inline;
33
+ *zoom: 1;
34
+ }
35
+
36
+ /*
37
+ * Prevents modern browsers from displaying 'audio' without controls
38
+ */
39
+
40
+ audio:not([controls]) {
41
+ display: none;
42
+ }
43
+
44
+ /*
45
+ * Addresses styling for 'hidden' attribute not present in IE7/8/9, FF3, S4
46
+ * Known issue: no IE6 support
47
+ */
48
+
49
+ [hidden] {
50
+ display: none;
51
+ }
52
+
53
+
54
+ /* =============================================================================
55
+ Base
56
+ ========================================================================== */
57
+
58
+ /*
59
+ * 1. Corrects text resizing oddly in IE6/7 when body font-size is set using em units
60
+ * http://clagnut.com/blog/348/#c790
61
+ * 2. Keeps page centred in all browsers regardless of content height
62
+ * 3. Prevents iOS text size adjust after orientation change, without disabling user zoom
63
+ * www.456bereastreet.com/archive/201012/controlling_text_size_in_safari_for_ios_without_disabling_user_zoom/
64
+ */
65
+
66
+ html {
67
+ font-size: 100%; /* 1 */
68
+ overflow-y: scroll; /* 2 */
69
+ -webkit-text-size-adjust: 100%; /* 3 */
70
+ -ms-text-size-adjust: 100%; /* 3 */
71
+ }
72
+
73
+ /*
74
+ * Addresses margins handled incorrectly in IE6/7
75
+ */
76
+
77
+ body {
78
+ margin: 0;
79
+ }
80
+
81
+ /*
82
+ * Addresses font-family inconsistency between 'textarea' and other form elements.
83
+ */
84
+
85
+ body,
86
+ button,
87
+ input,
88
+ select,
89
+ textarea {
90
+ font-family: sans-serif;
91
+ }
92
+
93
+
94
+ /* =============================================================================
95
+ Links
96
+ ========================================================================== */
97
+
98
+ /*
99
+ * Addresses outline displayed oddly in Chrome
100
+ */
101
+
102
+ a:focus {
103
+ outline: thin dotted;
104
+ }
105
+
106
+ /*
107
+ * Improves readability when focused and also mouse hovered in all browsers
108
+ * people.opera.com/patrickl/experiments/keyboard/test
109
+ */
110
+
111
+ a:hover,
112
+ a:active {
113
+ outline: 0;
114
+ }
115
+
116
+
117
+ /* =============================================================================
118
+ Typography
119
+ ========================================================================== */
120
+
121
+ /*
122
+ * Neutralise smaller font-size in 'section' and 'article' in FF4+, Chrome, S5
123
+ */
124
+
125
+ h1 {
126
+ font-size: 2em;
127
+ }
128
+
129
+ /*
130
+ * Addresses styling not present in IE7/8/9, S5, Chrome
131
+ */
132
+
133
+ abbr[title] {
134
+ border-bottom: 1px dotted;
135
+ }
136
+
137
+ /*
138
+ * Addresses style set to 'bolder' in FF3+, S4/5, Chrome
139
+ */
140
+
141
+ b,
142
+ strong {
143
+ font-weight: bold;
144
+ }
145
+
146
+ blockquote {
147
+ margin: 1em 40px;
148
+ }
149
+
150
+ /*
151
+ * Addresses styling not present in S5, Chrome
152
+ */
153
+
154
+ dfn {
155
+ font-style: italic;
156
+ }
157
+
158
+ /*
159
+ * Addresses styling not present in IE6/7/8/9
160
+ */
161
+
162
+ mark {
163
+ background: #ff0;
164
+ color: #000;
165
+ }
166
+
167
+ /*
168
+ * Corrects font family set oddly in IE6, S4/5, Chrome
169
+ * en.wikipedia.org/wiki/User:Davidgothberg/Test59
170
+ */
171
+
172
+ pre,
173
+ code,
174
+ kbd,
175
+ samp {
176
+ font-family: monospace, serif;
177
+ _font-family: 'courier new', monospace;
178
+ font-size: 1em;
179
+ }
180
+
181
+ /*
182
+ * Improves readability of pre-formatted text in all browsers
183
+ */
184
+
185
+ pre {
186
+ white-space: pre;
187
+ white-space: pre-wrap;
188
+ word-wrap: break-word;
189
+ }
190
+
191
+ /*
192
+ * 1. Addresses CSS quotes not supported in IE6/7
193
+ * 2. Addresses quote property not supported in S4
194
+ */
195
+
196
+ /* 1 */
197
+
198
+ q {
199
+ quotes: none;
200
+ }
201
+
202
+ /* 2 */
203
+
204
+ q:before,
205
+ q:after {
206
+ content: '';
207
+ content: none;
208
+ }
209
+
210
+ small {
211
+ font-size: 75%;
212
+ }
213
+
214
+ /*
215
+ * Prevents sub and sup affecting line-height in all browsers
216
+ * gist.github.com/413930
217
+ */
218
+
219
+ sub,
220
+ sup {
221
+ font-size: 75%;
222
+ line-height: 0;
223
+ position: relative;
224
+ vertical-align: baseline;
225
+ }
226
+
227
+ sup {
228
+ top: -0.5em;
229
+ }
230
+
231
+ sub {
232
+ bottom: -0.25em;
233
+ }
234
+
235
+
236
+ /* =============================================================================
237
+ Lists
238
+ ========================================================================== */
239
+
240
+ ul,
241
+ ol {
242
+ margin-left: 0;
243
+ padding: 0 0 0 40px;
244
+ }
245
+
246
+ dd {
247
+ margin: 0 0 0 40px;
248
+ }
249
+
250
+ nav ul,
251
+ nav ol {
252
+ list-style: none;
253
+ list-style-image: none;
254
+ }
255
+
256
+
257
+ /* =============================================================================
258
+ Embedded content
259
+ ========================================================================== */
260
+
261
+ /*
262
+ * 1. Removes border when inside 'a' element in IE6/7/8/9, FF3
263
+ * 2. Improves image quality when scaled in IE7
264
+ * code.flickr.com/blog/2008/11/12/on-ui-quality-the-little-things-client-side-image-resizing/
265
+ */
266
+
267
+ img {
268
+ border: 0; /* 1 */
269
+ -ms-interpolation-mode: bicubic; /* 2 */
270
+ }
271
+
272
+ /*
273
+ * Corrects overflow displayed oddly in IE9
274
+ */
275
+
276
+ svg:not(:root) {
277
+ overflow: hidden;
278
+ }
279
+
280
+
281
+ /* =============================================================================
282
+ Figures
283
+ ========================================================================== */
284
+
285
+ /*
286
+ * Addresses margin not present in IE6/7/8/9, S5, O11
287
+ */
288
+
289
+ figure {
290
+ margin: 0;
291
+ }
292
+
293
+
294
+ /* =============================================================================
295
+ Forms
296
+ ========================================================================== */
297
+
298
+ /*
299
+ * Corrects margin displayed oddly in IE6/7
300
+ */
301
+
302
+ form {
303
+ margin: 0;
304
+ }
305
+
306
+ /*
307
+ * Define consistent border, margin, and padding
308
+ */
309
+
310
+ fieldset {
311
+ border: 1px solid #c0c0c0;
312
+ margin: 0 2px;
313
+ padding: 0.35em 0.625em 0.75em;
314
+ }
315
+
316
+ /*
317
+ * 1. Corrects color not being inherited in IE6/7/8/9
318
+ * 2. Corrects alignment displayed oddly in IE6/7
319
+ */
320
+
321
+ legend {
322
+ border: 0; /* 1 */
323
+ *margin-left: -7px; /* 2 */
324
+ }
325
+
326
+ /*
327
+ * 1. Corrects font size not being inherited in all browsers
328
+ * 2. Addresses margins set differently in IE6/7, FF3+, S5, Chrome
329
+ * 3. Improves appearance and consistency in all browsers
330
+ */
331
+
332
+ button,
333
+ input,
334
+ select,
335
+ textarea {
336
+ font-size: 100%; /* 1 */
337
+ margin: 0; /* 2 */
338
+ vertical-align: baseline; /* 3 */
339
+ *vertical-align: middle; /* 3 */
340
+ }
341
+
342
+ /*
343
+ * Addresses FF3/4 setting line-height on 'input' using !important in the UA stylesheet
344
+ */
345
+
346
+ button,
347
+ input {
348
+ line-height: normal; /* 1 */
349
+ }
350
+
351
+ /*
352
+ * 1. Improves usability and consistency of cursor style between image-type 'input' and others
353
+ * 2. Corrects inability to style clickable 'input' types in iOS
354
+ * 3. Removes inner spacing in IE7 without affecting normal text inputs
355
+ * Known issue: inner spacing remains in IE6
356
+ */
357
+
358
+ button,
359
+ input[type="button"],
360
+ input[type="reset"],
361
+ input[type="submit"] {
362
+ cursor: pointer; /* 1 */
363
+ -webkit-appearance: button; /* 2 */
364
+ *overflow: visible; /* 3 */
365
+ }
366
+
367
+ /*
368
+ * 1. Addresses box sizing set to content-box in IE8/9
369
+ * 2. Removes excess padding in IE8/9
370
+ */
371
+
372
+ input[type="checkbox"],
373
+ input[type="radio"] {
374
+ box-sizing: border-box; /* 1 */
375
+ padding: 0; /* 2 */
376
+ }
377
+
378
+ /*
379
+ * 1. Addresses appearance set to searchfield in S5, Chrome
380
+ * 2. Addresses box-sizing set to border-box in S5, Chrome (include -moz to future-proof)
381
+ */
382
+
383
+ input[type="search"] {
384
+ -webkit-appearance: textfield; /* 1 */
385
+ -moz-box-sizing: content-box;
386
+ -webkit-box-sizing: content-box; /* 2 */
387
+ box-sizing: content-box;
388
+ }
389
+
390
+ /*
391
+ * Removes inner padding that is displayed in S5, Chrome on OS X
392
+ */
393
+
394
+ input[type="search"]::-webkit-search-decoration {
395
+ -webkit-appearance: none;
396
+ }
397
+
398
+ /*
399
+ * Removes inner padding and border in FF3+
400
+ * www.sitepen.com/blog/2008/05/14/the-devils-in-the-details-fixing-dojos-toolbar-buttons/
401
+ */
402
+
403
+ button::-moz-focus-inner,
404
+ input::-moz-focus-inner {
405
+ border: 0;
406
+ padding: 0;
407
+ }
408
+
409
+ /*
410
+ * 1. Removes default vertical scrollbar in IE6/7/8/9
411
+ * 2. Improves readability and alignment in all browsers
412
+ */
413
+
414
+ textarea {
415
+ overflow: auto; /* 1 */
416
+ vertical-align: top; /* 2 */
417
+ }
418
+
419
+
420
+ /* =============================================================================
421
+ Tables
422
+ ========================================================================== */
423
+
424
+ /*
425
+ * Remove most spacing between table cells
426
+ */
427
+
428
+ table {
429
+ border-collapse: collapse;
430
+ border-spacing: 0;
431
+ }
@@ -0,0 +1,40 @@
1
+ @charset "utf-8";
2
+
3
+ @import "normalize";
4
+ @import "compass";
5
+
6
+ body {
7
+ background: #d4d4d4 image-url("background.png");
8
+ text-align: center;
9
+ font-family: sans-serif;
10
+ }
11
+
12
+ h1 {
13
+ color: rgba(black, .3);
14
+ font-weight: bold;
15
+ @include adjust-font-size-to(32px);
16
+ letter-spacing: -1px;
17
+ text-transform: uppercase;
18
+ text-shadow: 0 1px 0 rgba(white, .5);
19
+ background: image-url("middleman.png") no-repeat center 100px;
20
+ padding: 350px 0 10px;
21
+ margin: 0;
22
+ }
23
+
24
+ .doc {
25
+ @include adjust-font-size-to(14px);
26
+ margin: 0;
27
+ &:before,
28
+ &:after {
29
+ opacity: .2;
30
+ padding: 6px;
31
+ font-style: normal;
32
+ position: relative;
33
+ content: "•";
34
+ }
35
+ a {
36
+ @include link-colors( rgba( black, .3 ) , #666);
37
+ }
38
+ }
39
+
40
+ @import "animate";