Skip to content
This repository
Browse code

cheatsheet model updated, rebuilt

  • Loading branch information...
commit 28a8096433f03277e0decf242e7262ce0e6d8bdb 1 parent 7559557
Jon Schlinkert authored March 03, 2013
2  .gitignore
@@ -11,6 +11,8 @@ pids
11 11
 logs
12 12
 results
13 13
 
  14
+src/content/less-tests/
  15
+
14 16
 npm-debug.log
15 17
 /node_modules/
16 18
 *.sublime-project
5,852  cheatsheet.html
3379 additions, 2473 deletions not shown
1  config.json
@@ -4,7 +4,6 @@
4 4
   "helpers": {
5 5
     "handlebars": "node_modules/assemble/lib/engines/handlebars/helpers/defaultHelpers.js"
6 6
   },
7  
-  "highlight": false,
8 7
   "prettify": true,
9 8
   "content": "src/content"
10 9
 }
1,656  src/data/cheatsheet.json
1025 additions, 631 deletions not shown
69  src/templates/partials/accordion.hbs
... ...
@@ -1,36 +1,43 @@
1 1
 {{#each rows}}
2 2
   <div class="{{row-modifier}}">
3  
-  {{#each columns}}
4  
-    <div class="{{column}}">
5  
-    {{#each accordion}}
6  
-      <div class="accordion-panel">
7  
-        <div class="accordion" id="{{accordion-id}}">
8  
-          {{#if wiki-href}}<a href="{{wiki-href}}" class="btn btn-primary btn-mini pull-right">Wiki &raquo;</a>{{/if}}
9  
-          <h4 class="accordion-title">{{{accordion-title}}}</h4>
10  
-          {{#each accordion-groups}}{{#if accordion-section}} <strong class="accordion-section">{{{accordion-section}}}</strong>
11  
-          {{else}}
12  
-          <dl class="accordion-group">
13  
-            <dd class="accordion-heading">
14  
-              <a class="accordion-toggle" data-toggle="collapse" data-parent="#{{../../accordion-id}}" href="#{{../../accordion-id}}-{{../topic-href}}">
15  
-                <i class="toggle-chevron"></i>
16  
-                <span class="label label-{{topic-label-modifier}} pull-right">{{ topic-label }}</span>
17  
-                {{{ topic-name }}}
18  
-              </a>
19  
-            </dd>
20  
-            <dt id="{{../../accordion-id}}-{{../topic-href}}" class="accordion-body collapse">
21  
-              <div class="accordion-inner">
22  
-                <div class="summary">
23  
-                  {{{ topic-summary }}}
24  
-                </div>
25  
-                {{{ topic-description }}}
  3
+    {{#each columns}}
  4
+      <div class="span{{width}}">
  5
+        {{#each accordions}}
26 6
 
27  
-                {{> example }}
  7
+          <!-- Accordion panel.
  8
+          ======================================== -->
  9
+          <div class="accordion-panel">
  10
+            <div class="accordion" id="{{accordion-id}}">
  11
+              {{#if wiki-href}}<a href="{{wiki-href}}" class="btn btn-primary btn-mini pull-right">Wiki &raquo;</a>{{/if}}
  12
+              <h4 class="accordion-title">{{{accordion-title}}}</h4>
  13
+              {{#each accordion-groups}}
  14
+                {{#if accordion-section}} <strong class="accordion-section">{{{accordion-section}}}</strong> {{else}}
28 15
 
29  
-              </div>
30  
-            </dt>
31  
-          </dl>{{/if}}{{/each}}
32  
-        </div>
33  
-      </div>{{/each}}
34  
-    </div>{{/each}}
35  
-  </div>
  16
+                  <!-- Accordion group -->
  17
+                  <dl class="accordion-group">
  18
+                    <dt class="accordion-heading">
  19
+                      <a class="accordion-toggle" data-toggle="collapse" data-parent="#{{../../accordion-id}}" href="#{{../../accordion-id}}-{{../topic-href}}">
  20
+                        <i class="toggle-chevron"></i>{{#if label}} <span class="label label-{{label-modifier}} pull-right">{{ label }}</span>{{/if}}
  21
+                        {{{ topic-name }}}
  22
+                      </a>
  23
+                    </dt>
  24
+
  25
+                    <!-- Accordion group --> {{! concatenate the accordion Id onto the topic href to create a unique Id for definition }}
  26
+                    <dd id="{{../../accordion-id}}-{{../topic-href}}" class="accordion-body collapse">
  27
+                      <div class="accordion-inner">
  28
+                        <div class="topic-summary">
  29
+                          {{{ topic-summary }}}
  30
+                        </div>
  31
+                        {{> example }}
  32
+                      </div>
  33
+                    </dd>
  34
+                  </dl><!-- /accordion-group -->
  35
+                {{/if}}
  36
+              {{/each}}
  37
+            </div>
  38
+          </div><!-- /accordion-panel -->
  39
+        {{/each}}
  40
+      </div> {{! /columns }}
  41
+    {{/each}}
  42
+  </div> {{! /rows }}
36 43
 {{/each}}

0 notes on commit 28a8096

Please sign in to comment.
Something went wrong with that request. Please try again.