Permalink
Browse files

Fixed state parser, added some more styling to example docs and modif…

…ied the mustache template
  • Loading branch information...
1 parent d292863 commit 2246280c1a57b9ff7d3c5f6bc9181706901612bd @darcyclarke darcyclarke committed Mar 15, 2013
Showing with 50 additions and 14 deletions.
  1. +3 −1 .gitignore
  2. +1 −1 tasks/DSS.js
  3. +8 −0 template/assets/css/styles.css
  4. +26 −0 template/assets/js/scripts.js
  5. +12 −12 template/index.mustache
View
@@ -1,4 +1,6 @@
/node_modules/
.DS_STORE
.DS_Store?
-/docs/
+/docs/
+/example/articleview.scss
+/example/config.rb
View
@@ -466,7 +466,7 @@ module.exports = function(grunt) {
// Describe parsing a state
dss.parser('state', function(i, line, block, file){
- var state = line.split('-');
+ var state = line.split(' - ');
return {
name: (state[0]) ? dss.trim(state[0].replace('.', ' ').replace(':', ' pseudo-class-')) : '',
description: (state[1]) ? dss.trim(state[1]) : ''
@@ -196,6 +196,14 @@ td { vertical-align: top; }
padding: 10px;
}
+ #wrapper .markup {
+ margin: 0;
+ padding: 24px 20px 20px;
+ font-size: 13px;
+ font-family: Consolas, "Liberation Mono", Courier, monospace;
+ background: #efefef;
+ }
+
footer {
}
@@ -1,3 +1,29 @@
+/*
+
+@author Kyle Neath
+@url https://github.com/kneath/kss
+
+Copyright (c) 2011 Tom Preston-Werner, Kyle Neath
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+Software), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED AS IS, WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+*/
(function() {
var KssStateGenerator;
View
@@ -47,25 +47,25 @@
</div>
{{#markup}}
+
<div class="example">
{{{example}}}
</div>
- {{/markup}}
-
- {{#state}}
- <div class="example state {{class}}">
- <div class="name">{{name}}</div>
- {{#markup}}
- {{markup}}
- {{/markup}}
- </div>
- {{/state}}
+
+ {{#state}}
+ <div class="example state {{class}}">
+ <div class="name">{{name}}</div>
+ {{#markup}}
+ {{markup}}
+ {{/markup}}
+ </div>
+ {{/state}}
-{{#markup}}
<pre class="markup">
{{{markup.escaped}}}
</pre>
-{{/markup}}
+
+ {{/markup}}
</div>
{{/blocks}}

0 comments on commit 2246280

Please sign in to comment.