zurb-foundation 3.2.5 → 4.0.0.rc1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (239) hide show
  1. data/.gitignore +6 -2
  2. data/CHANGELOG.md +1 -26
  3. data/CONTRIBUTING.md +18 -0
  4. data/Gemfile.lock +19 -0
  5. data/Gruntfile.js +27 -0
  6. data/README.md +5 -6
  7. data/{Capfile → docs/Capfile} +0 -1
  8. data/docs/Gemfile +8 -0
  9. data/docs/Gemfile.lock +43 -0
  10. data/docs/Procfile +2 -0
  11. data/docs/README.md +1 -0
  12. data/docs/_sidebar-components.html.erb +109 -0
  13. data/docs/_sidebar.html.erb +109 -0
  14. data/docs/_zurb-jobs.html.erb +5 -0
  15. data/docs/changelog.html.erb +185 -0
  16. data/docs/compile.rb +43 -0
  17. data/docs/components/alert-boxes.html.erb +202 -0
  18. data/docs/components/block-grid.html.erb +118 -0
  19. data/docs/components/breadcrumbs.html.erb +146 -0
  20. data/docs/components/button-groups.html.erb +174 -0
  21. data/docs/components/buttons.html.erb +220 -0
  22. data/docs/components/clearing.html.erb +152 -0
  23. data/docs/components/custom-forms.html.erb +306 -0
  24. data/docs/components/dropdown-buttons.html.erb +233 -0
  25. data/docs/components/dropdown.html.erb +186 -0
  26. data/docs/components/flex-video.html.erb +93 -0
  27. data/docs/components/forms.html.erb +468 -0
  28. data/docs/components/grid.html.erb +355 -0
  29. data/docs/components/inline-lists.html.erb +89 -0
  30. data/docs/components/joyride.html.erb +178 -0
  31. data/docs/components/keystrokes.html.erb +74 -0
  32. data/docs/components/labels.html.erb +98 -0
  33. data/docs/components/magellan.html.erb +84 -0
  34. data/docs/components/orbit.html.erb +262 -0
  35. data/docs/components/pagination.html.erb +181 -0
  36. data/docs/components/panels.html.erb +121 -0
  37. data/docs/components/pricing-tables.html.erb +154 -0
  38. data/docs/components/progress-bars.html.erb +120 -0
  39. data/docs/components/reveal.html.erb +147 -0
  40. data/docs/components/section.html.erb +156 -0
  41. data/docs/components/side-nav.html.erb +122 -0
  42. data/docs/components/split-buttons.html.erb +218 -0
  43. data/docs/components/sub-nav.html.erb +120 -0
  44. data/docs/components/switch.html.erb +288 -0
  45. data/docs/components/tables.html.erb +123 -0
  46. data/docs/components/thumbnails.html.erb +87 -0
  47. data/docs/components/tooltips.html.erb +73 -0
  48. data/docs/components/top-bar.html.erb +219 -0
  49. data/docs/components/type.html.erb +359 -0
  50. data/docs/components/visibility.html.erb +102 -0
  51. data/docs/config.ru +12 -0
  52. data/docs/config/deploy.rb +33 -0
  53. data/docs/controller.rb +43 -0
  54. data/docs/css/_coderay.scss +116 -0
  55. data/docs/css/_settings.scss +1 -0
  56. data/docs/css/docs.scss +174 -0
  57. data/docs/css/normalize.scss +396 -0
  58. data/docs/css/qunit-composite.css +13 -0
  59. data/docs/css/qunit.css +235 -0
  60. data/docs/faq.html.erb +61 -0
  61. data/docs/img/demos/demo1-th.png +0 -0
  62. data/docs/img/demos/demo1.png +0 -0
  63. data/docs/img/demos/demo2-th.png +0 -0
  64. data/docs/img/demos/demo2.png +0 -0
  65. data/docs/img/demos/demo3-th.png +0 -0
  66. data/docs/img/demos/demo3.png +0 -0
  67. data/docs/img/demos/demo4-th.png +0 -0
  68. data/docs/img/demos/demo4.png +0 -0
  69. data/docs/img/demos/demo5-th.png +0 -0
  70. data/docs/img/demos/demo5.png +0 -0
  71. data/docs/index.html.erb +299 -0
  72. data/docs/javascript.html.erb +133 -0
  73. data/docs/js/docs.js +3 -0
  74. data/docs/js/qunit-composite.js +105 -0
  75. data/docs/js/qunit.js +1977 -0
  76. data/docs/js/tests/tabs/simple_tabs.html +57 -0
  77. data/docs/js/tests/tabs/simple_tabs.js +54 -0
  78. data/docs/js/tests/tooltips/tooltips.html +39 -0
  79. data/docs/js/tests/tooltips/tooltips.js +11 -0
  80. data/docs/layout.html.erb +99 -0
  81. data/docs/rails.html.erb +66 -0
  82. data/docs/sass.html.erb +299 -0
  83. data/docs/support.html.erb +134 -0
  84. data/foundation.gemspec +2 -4
  85. data/index.html +3 -23
  86. data/js/foundation/foundation.alerts.js +50 -0
  87. data/js/foundation/foundation.clearing.js +478 -0
  88. data/{vendor/assets/javascripts/foundation/jquery.cookie.js → js/foundation/foundation.cookie.js} +3 -1
  89. data/js/foundation/foundation.dropdown.js +122 -0
  90. data/js/foundation/foundation.forms.js +403 -0
  91. data/js/foundation/foundation.joyride.js +613 -0
  92. data/js/foundation/foundation.js +331 -0
  93. data/js/foundation/foundation.magellan.js +130 -0
  94. data/js/foundation/foundation.orbit.js +355 -0
  95. data/{vendor/assets/javascripts/foundation/jquery.placeholder.js → js/foundation/foundation.placeholder.js} +4 -2
  96. data/js/foundation/foundation.reveal.js +264 -0
  97. data/js/foundation/foundation.section.js +180 -0
  98. data/js/foundation/foundation.tooltips.js +195 -0
  99. data/js/foundation/foundation.topbar.js +187 -0
  100. data/js/foundation/index.js +16 -0
  101. data/{vendor/assets/javascripts/foundation/modernizr.foundation.js → js/vendor/custom.modernizr.js} +0 -0
  102. data/js/vendor/jquery.js +9597 -0
  103. data/js/vendor/zepto.js +1782 -0
  104. data/lib/foundation/engine.rb +8 -1
  105. data/lib/foundation/generators/install_generator.rb +24 -1
  106. data/lib/foundation/generators/templates/application.html.erb +20 -6
  107. data/lib/foundation/generators/templates/application.html.haml +2 -6
  108. data/lib/foundation/generators/templates/application.html.slim +2 -5
  109. data/lib/foundation/version.rb +1 -1
  110. data/lib/zurb-foundation.rb +7 -9
  111. data/package.json +9 -0
  112. data/scss/foundation.scss +42 -15
  113. data/scss/foundation/_foundation-global.scss +226 -0
  114. data/scss/foundation/components/_alert-boxes.scss +106 -0
  115. data/scss/foundation/components/_block-grid.scss +63 -0
  116. data/scss/foundation/components/_breadcrumbs.scss +117 -0
  117. data/scss/foundation/components/_button-groups.scss +59 -0
  118. data/scss/foundation/components/_buttons.scss +217 -0
  119. data/scss/foundation/components/_clearing.scss +209 -0
  120. data/scss/foundation/components/_custom-forms.scss +232 -0
  121. data/scss/foundation/components/_dropdown-buttons.scss +114 -0
  122. data/scss/foundation/components/_dropdown.scss +137 -0
  123. data/scss/foundation/components/_flex-video.scss +45 -0
  124. data/scss/foundation/components/_forms.scss +309 -0
  125. data/scss/foundation/components/_grid.scss +149 -71
  126. data/scss/foundation/components/_inline-lists.scss +47 -0
  127. data/scss/foundation/components/_joyride.scss +193 -0
  128. data/scss/foundation/components/_keystrokes.scss +56 -0
  129. data/scss/foundation/components/_labels.scss +81 -0
  130. data/scss/foundation/components/_magellan.scss +15 -0
  131. data/scss/foundation/components/_orbit.scss +193 -0
  132. data/scss/foundation/components/_pagination.scss +99 -0
  133. data/scss/foundation/components/_panels.scss +76 -0
  134. data/scss/foundation/components/_pricing-tables.scss +130 -0
  135. data/scss/foundation/components/_progress-bars.scss +68 -0
  136. data/scss/foundation/components/_reveal.scss +131 -0
  137. data/scss/foundation/components/_section.scss +194 -0
  138. data/scss/foundation/components/_side-nav.scss +68 -0
  139. data/scss/foundation/components/_split-buttons.scss +159 -0
  140. data/scss/foundation/components/_sub-nav.scss +67 -0
  141. data/scss/foundation/components/_switch.scss +242 -0
  142. data/scss/foundation/components/_tables.scss +80 -0
  143. data/scss/foundation/components/_thumbs.scss +45 -0
  144. data/scss/foundation/components/_tooltips.scss +113 -0
  145. data/scss/foundation/components/_top-bar.scss +443 -0
  146. data/scss/foundation/components/_type.scss +411 -0
  147. data/scss/foundation/components/_visibility.scss +117 -0
  148. data/scss/normalize.scss +396 -0
  149. data/templates/project/config.rb +26 -0
  150. data/templates/project/index.html +28 -43
  151. data/templates/project/manifest.rb +21 -28
  152. data/templates/project/scss/_settings.scss +4 -243
  153. data/templates/project/scss/app.scss +37 -44
  154. data/templates/project/scss/normalize.scss +396 -0
  155. data/test/stylesheets/styles.css +955 -0
  156. metadata +144 -153
  157. data/config/deploy.rb +0 -42
  158. data/lib/foundation/generators/layout_generator.rb +0 -28
  159. data/scss/foundation/_settings.scss +0 -281
  160. data/scss/foundation/common/_base.scss +0 -4
  161. data/scss/foundation/common/_forms.scss +0 -117
  162. data/scss/foundation/common/_globals.scss +0 -35
  163. data/scss/foundation/common/_ratios.scss +0 -19
  164. data/scss/foundation/common/_typography.scss +0 -104
  165. data/scss/foundation/components/modules/_all.scss +0 -10
  166. data/scss/foundation/components/modules/_buttons.scss +0 -178
  167. data/scss/foundation/components/modules/_clearing.scss +0 -61
  168. data/scss/foundation/components/modules/_joyride.scss +0 -33
  169. data/scss/foundation/components/modules/_mqueries.scss +0 -458
  170. data/scss/foundation/components/modules/_navbar.scss +0 -74
  171. data/scss/foundation/components/modules/_offcanvas.scss +0 -55
  172. data/scss/foundation/components/modules/_orbit.scss +0 -90
  173. data/scss/foundation/components/modules/_reveal.scss +0 -34
  174. data/scss/foundation/components/modules/_tabs.scss +0 -67
  175. data/scss/foundation/components/modules/_topbar.scss +0 -167
  176. data/scss/foundation/components/modules/_ui.scss +0 -292
  177. data/scss/foundation/functions/_all.scss +0 -2
  178. data/scss/foundation/functions/_convert-number-to-word.scss +0 -10
  179. data/scss/foundation/functions/_grid-calc.scss +0 -5
  180. data/scss/foundation/functions/modular-scale.scss +0 -3
  181. data/scss/foundation/mixins/_all.scss +0 -5
  182. data/scss/foundation/mixins/_clearfix.scss +0 -13
  183. data/scss/foundation/mixins/_css-triangle.scss +0 -22
  184. data/scss/foundation/mixins/_font-size.scss +0 -13
  185. data/scss/foundation/mixins/_respond-to.scss +0 -11
  186. data/scss/foundation/mixins/_semantic-grid.scss +0 -66
  187. data/test/buttons.html +0 -189
  188. data/test/clearing.html +0 -85
  189. data/test/config.rb +0 -11
  190. data/test/elements.html +0 -490
  191. data/test/forms.html +0 -371
  192. data/test/grid.html +0 -543
  193. data/test/images/orbit-demo/demo1.jpeg +0 -0
  194. data/test/images/orbit-demo/demo2.jpeg +0 -0
  195. data/test/images/orbit-demo/demo3.jpeg +0 -0
  196. data/test/images/orbit-demo/slider-background.jpeg +0 -0
  197. data/test/index.html +0 -83
  198. data/test/joyride.html +0 -127
  199. data/test/magellan.html +0 -112
  200. data/test/navigation.html +0 -269
  201. data/test/orbit.html +0 -112
  202. data/test/reveal.html +0 -91
  203. data/test/scss/_settings.scss +0 -245
  204. data/test/scss/styles.scss +0 -50
  205. data/test/tabs.html +0 -197
  206. data/test/template.html +0 -52
  207. data/test/topbar-login.html +0 -194
  208. data/test/topbar.html +0 -139
  209. data/test/type.html +0 -188
  210. data/vendor/assets/images/foundation/orbit/bullets.jpg +0 -0
  211. data/vendor/assets/images/foundation/orbit/left-arrow-small.png +0 -0
  212. data/vendor/assets/images/foundation/orbit/left-arrow.png +0 -0
  213. data/vendor/assets/images/foundation/orbit/loading.gif +0 -0
  214. data/vendor/assets/images/foundation/orbit/mask-black.png +0 -0
  215. data/vendor/assets/images/foundation/orbit/pause-black.png +0 -0
  216. data/vendor/assets/images/foundation/orbit/right-arrow-small.png +0 -0
  217. data/vendor/assets/images/foundation/orbit/right-arrow.png +0 -0
  218. data/vendor/assets/images/foundation/orbit/rotator-black.png +0 -0
  219. data/vendor/assets/images/foundation/orbit/timer-black.png +0 -0
  220. data/vendor/assets/javascripts/foundation/app.js +0 -41
  221. data/vendor/assets/javascripts/foundation/index.js +0 -19
  222. data/vendor/assets/javascripts/foundation/jquery.event.move.js +0 -580
  223. data/vendor/assets/javascripts/foundation/jquery.event.swipe.js +0 -130
  224. data/vendor/assets/javascripts/foundation/jquery.foundation.accordion.js +0 -47
  225. data/vendor/assets/javascripts/foundation/jquery.foundation.alerts.js +0 -20
  226. data/vendor/assets/javascripts/foundation/jquery.foundation.buttons.js +0 -83
  227. data/vendor/assets/javascripts/foundation/jquery.foundation.clearing.js +0 -413
  228. data/vendor/assets/javascripts/foundation/jquery.foundation.forms.js +0 -502
  229. data/vendor/assets/javascripts/foundation/jquery.foundation.joyride.js +0 -639
  230. data/vendor/assets/javascripts/foundation/jquery.foundation.magellan.js +0 -96
  231. data/vendor/assets/javascripts/foundation/jquery.foundation.mediaQueryToggle.js +0 -27
  232. data/vendor/assets/javascripts/foundation/jquery.foundation.navigation.js +0 -55
  233. data/vendor/assets/javascripts/foundation/jquery.foundation.orbit.js +0 -919
  234. data/vendor/assets/javascripts/foundation/jquery.foundation.reveal.js +0 -794
  235. data/vendor/assets/javascripts/foundation/jquery.foundation.tabs.js +0 -66
  236. data/vendor/assets/javascripts/foundation/jquery.foundation.tooltips.js +0 -211
  237. data/vendor/assets/javascripts/foundation/jquery.foundation.topbar.js +0 -174
  238. data/vendor/assets/javascripts/foundation/jquery.js +0 -9555
  239. data/vendor/assets/javascripts/foundation/jquery.offcanvas.js +0 -50
@@ -0,0 +1,57 @@
1
+ <!DOCTYPE html>
2
+ <!-- paulirish.com/2008/conditional-stylesheets-vs-css-hacks-answer-neither/ -->
3
+ <!--[if IE 8]> <html class="no-js lt-ie9" lang="en"> <![endif]-->
4
+ <!--[if gt IE 8]><!--> <html class="no-js" lang="en"> <!--<![endif]-->
5
+ <head>
6
+ <meta charset="utf-8" />
7
+
8
+ <!-- Set the viewport width to device width for mobile -->
9
+ <meta name="viewport" content="width=device-width" />
10
+
11
+ <title>Foundation Tabs Testing</title>
12
+
13
+ <!-- Included CSS Files -->
14
+ <link rel="stylesheet" href="../../../stylesheets/styles.css">
15
+ <link rel="stylesheet" href="../../../stylesheets/qunit.css">
16
+
17
+ <script src="../../../../lib/assets/javascripts/foundation/modernizr.foundation.js"></script>
18
+ </head>
19
+ <body>
20
+
21
+ <div class="row">
22
+ <div class="twelve columns">
23
+ <div id="qunit"></div>
24
+ <div id="qunit-fixture">
25
+
26
+ <div class="row">
27
+ <div class="twelve columns">
28
+ <ul id="tabs1" class="tabs">
29
+ <li class="active"><a href="#simple1">Simple Tab 1</a></li>
30
+ <li><a href="#simple2">Simple Tab 2</a></li>
31
+ <li><a href="#simple3">Simple Tab 3</a></li>
32
+ </ul>
33
+ <ul class="tabs-content">
34
+ <li class="active" id="simple1Tab">This is simple tab 1's content. Pretty neat, huh?</li>
35
+ <li id="simple2Tab">This is simple tab 2's content. Now you see it!</li>
36
+ <li id="simple3Tab">This is simple tab 3's content. It's only okay.</li>
37
+ </ul>
38
+ </div>
39
+ </div>
40
+
41
+ </div>
42
+ </div>
43
+ </div>
44
+
45
+ <!-- Test Foundation Components Here -->
46
+
47
+
48
+
49
+
50
+ <!-- Included JS Files -->
51
+ <script src="../../../../lib/assets/javascripts/foundation/jquery.js"></script>
52
+ <script src="../../../../lib/assets/javascripts/foundation/foundation.js"></script>
53
+ <script src="../../../../lib/assets/javascripts/foundation/jquery.foundation.tabs.js"></script>
54
+ <script src="../../../javascripts/qunit.js"></script>
55
+ <script src="../../../javascripts/tests/tabs/simple_tabs.js"></script>
56
+ </body>
57
+ </html>
@@ -0,0 +1,54 @@
1
+ module('core', {
2
+ setup: function () {
3
+ this.$tabs = $('#tabs1');
4
+ $(document).foundation('tabs');
5
+ },
6
+ teardown: function () {
7
+
8
+ }
9
+ });
10
+ test('setup is correct', function () {
11
+ ok(this.$tabs.length == 1, 'one one set of tabs should be present');
12
+ strictEqual(this.$tabs.find('a:last').hasClass('active'), false, 'last tab should not be active');
13
+ });
14
+ test('click tab activates content pane', function () {
15
+ var $activeTab = this.$tabs.find('.active a'),
16
+ $activeTabContent = $($activeTab.attr('href') + 'Tab'),
17
+ $lastTab = this.$tabs.find('a:last'),
18
+ $lastTabContent = $($lastTab.attr('href') + 'Tab');
19
+
20
+ strictEqual($activeTabContent.hasClass('active'), true, 'active tab content should be active');
21
+
22
+ $lastTab.trigger('click');
23
+
24
+ strictEqual($activeTabContent.hasClass('active'), false, 'previous tab content should no longer be active');
25
+ strictEqual($lastTabContent.hasClass('active'), true, 'newly clicked tab should be active');
26
+ });
27
+
28
+ module('initialize with wrong scope', {
29
+ setup: function () {
30
+ this.$tabs = $('#tabs1');
31
+ $('#tabs2').foundation('tabs');
32
+ },
33
+ teardown: function () {
34
+
35
+ }
36
+ });
37
+ test('setup is correct', function () {
38
+ ok(this.$tabs.length == 1, 'one one set of tabs should be present');
39
+ strictEqual(this.$tabs.find('a:last').hasClass('active'), false, 'last tab should not be active');
40
+ });
41
+ test('click tab activates content pane', function () {
42
+ var $activeTab = this.$tabs.find('.active a'),
43
+ $activeTabContent = $($activeTab.attr('href') + 'Tab'),
44
+ $lastTab = this.$tabs.find('a:last'),
45
+ $lastTabContent = $($lastTab.attr('href') + 'Tab');
46
+
47
+ strictEqual($activeTabContent.hasClass('active'), true, 'active tab content should be active');
48
+
49
+ // triggering an event on an uninitialized tabs should have no effect
50
+ $lastTab.trigger('click');
51
+
52
+ strictEqual($activeTabContent.hasClass('active'), true, 'previous tab should still be active');
53
+ strictEqual($lastTabContent.hasClass('active'), false, 'newly clicked tab should be NOT active');
54
+ });
@@ -0,0 +1,39 @@
1
+ <!DOCTYPE html>
2
+ <!-- paulirish.com/2008/conditional-stylesheets-vs-css-hacks-answer-neither/ -->
3
+ <!--[if IE 8]> <html class="no-js lt-ie9" lang="en"> <![endif]-->
4
+ <!--[if gt IE 8]><!--> <html class="no-js" lang="en"> <!--<![endif]-->
5
+ <head>
6
+ <meta charset="utf-8" />
7
+
8
+ <!-- Set the viewport width to device width for mobile -->
9
+ <meta name="viewport" content="width=device-width" />
10
+
11
+ <title>Foundation Tooltips Testing</title>
12
+
13
+ <!-- Included CSS Files -->
14
+ <link rel="stylesheet" href="../../../stylesheets/styles.css">
15
+ <link rel="stylesheet" href="../../../stylesheets/qunit.css">
16
+
17
+ <script src="../../../../lib/assets/javascripts/foundation/modernizr.foundation.js"></script>
18
+ </head>
19
+ <body>
20
+
21
+ <div class="row">
22
+ <div class="twelve columns">
23
+ <div id="qunit"></div>
24
+ <div id="qunit-fixture">
25
+
26
+ <span class="has-tip" data-width="210" title="I'm on bottom and the default position.">Tooltip</span>
27
+
28
+ </div>
29
+ </div>
30
+ </div>
31
+
32
+ <!-- Included JS Files -->
33
+ <script src="../../../../lib/assets/javascripts/foundation/jquery.js"></script>
34
+ <script src="../../../../lib/assets/javascripts/foundation/foundation.js"></script>
35
+ <script src="../../../../lib/assets/javascripts/foundation/jquery.foundation.tooltips.js"></script>
36
+ <script src="../../../javascripts/qunit.js"></script>
37
+ <script src="../../../javascripts/tests/tooltips/tooltips.js"></script>
38
+ </body>
39
+ </html>
@@ -0,0 +1,11 @@
1
+ module('core', {
2
+ setup: function () {
3
+ $(document).foundation('tooltips');
4
+ },
5
+ teardown: function () {
6
+
7
+ }
8
+ });
9
+ test('setup', function () {
10
+ ok(false, 'please test');
11
+ });
@@ -0,0 +1,99 @@
1
+ <!doctype html>
2
+ <!--[if IE 8]><html class="no-js lt-ie9" lang="en"><![endif]-->
3
+ <!--[if gt IE 8]><!--><html class="no-js" lang="en"><!--<![endif]-->
4
+ <head>
5
+ <meta charset="utf-8" />
6
+ <meta name="viewport" content="width=device-width" />
7
+ <title>Foundation Docs: <%= @page_title %></title>
8
+ <link rel="stylesheet" href="<%= asset_path %>/normalize.css" />
9
+ <link rel="stylesheet" href="<%= asset_path %>/docs.css" />
10
+ <script src="<%= asset_path %>/vendor/custom.modernizr.js"></script>
11
+ </head>
12
+ <body>
13
+
14
+ <nav class="top-bar">
15
+ <ul class="title-area">
16
+ <!-- Title Area -->
17
+ <li class="name">
18
+ <h1><a href="/">Foundation</a></h1>
19
+ </li>
20
+ <!-- Remove the class "menu-icon" to get rid of menu icon. Take out "Menu" to just have icon alone -->
21
+ <li class="toggle-topbar menu-icon"><a href="#"><span>Menu</span></a></li>
22
+ </ul>
23
+
24
+ <section class="top-bar-section">
25
+ <!-- Right Nav Section -->
26
+ <ul class="right">
27
+ <li class="divider"></li>
28
+ <li><a href="<%= features_path %>">Features</a></li>
29
+ <li class="divider"></li>
30
+ <li><a href="<%= add_ons_path %>">Add-ons</a></li>
31
+ <li class="divider"></li>
32
+ <li><a href="<%= case_studies_path %>">Case Studies</a></li>
33
+ <li class="divider"></li>
34
+ <li><a href="<%= docs_path %>">Docs</a></li>
35
+ <li class="divider"></li>
36
+ <li class="has-form">
37
+ <a href="<%= docs_path %>" class="button">Get Started</a>
38
+ </li>
39
+ </ul>
40
+ </section>
41
+ </nav>
42
+
43
+ <% @page_title = "4 Documentation" %>
44
+ <div class="row">
45
+ <div class="large-12 columns">
46
+ <h1><a href="../index.html">Foundation <%= @page_title %></a></h1>
47
+ <hr>
48
+ </div>
49
+ </div>
50
+
51
+ <%= yield %>
52
+
53
+ <footer class="row full-width">
54
+ <div class="large-5 columns">
55
+ <h6><strong>Made by ZURB</strong></h6>
56
+ <p>Foundation is made by <a href="http://www.zurb.com/">ZURB</a>, a product design company in Campbell, California. We've put more than 14 years of experience building web products, services and websites into this framework. <a href="../about.php">Foundation Info and Goodies &rarr;</a></p>
57
+ </div>
58
+
59
+ <div class="large-3 columns">
60
+ <h6><strong>Using Foundation?</strong></h6>
61
+ <p>Let us know how you're using Foundation and we might feature you as an example! <a href="mailto:foundation@zurb.com?subject=I'm%20using%20Foundation">Get in touch &rarr;</a></p>
62
+ </div>
63
+
64
+ <div class="large-4 columns">
65
+ <h6><strong>Need some help?</strong></h6>
66
+ <p>For answers or help visit the <a href="../support.html">Support page</a>.</p>
67
+ </div>
68
+ </footer>
69
+
70
+ <div id="copyright">
71
+ <div class="row full-width">
72
+ <div class="large-4 columns">
73
+ <p>Site content &copy; 2013 ZURB, inc.</p>
74
+ </div>
75
+ <div class="large-8 columns">
76
+ <ul class="inline-list right">
77
+ <li><a href="../index.php">Home</a></li>
78
+ <li><a href="../download.php">Download</a></li>
79
+ <li><a href="index.html">Docs</a></li>
80
+ <li><a href="changelog.html">Changelog</a></li>
81
+ <li><a href="../about.php">About</a></li>
82
+ <li><a href="http://feeds.feedburner.com/zurb/blog">Subscribe to the ZURBlog</a></li>
83
+ </ul>
84
+ </div>
85
+ </div>
86
+ </div>
87
+
88
+ <script>
89
+ document.write('<script src="<%= asset_path %>/vendor/'
90
+ + ('__proto__' in {} ? 'zepto' : 'jquery')
91
+ + '.js"><\/script>');
92
+ </script>
93
+ <script src="<%= asset_path %>/docs.js"></script>
94
+ <script>
95
+ $(document).foundation()
96
+ .foundation('joyride', 'start');
97
+ </script>
98
+ </body>
99
+ </html>
@@ -0,0 +1,66 @@
1
+ <div class="row">
2
+ <div class="large-9 push-3 columns"
3
+ <% @page_title = "Installing with Rails" %>
4
+ <div class="row">
5
+ <div class="large-12 columns">
6
+ <h2><%= @page_title %></h2>
7
+ <h4 class="subheader">We use Rails to develop our <a href="http://zurb.com/apps">apps</a> and Foundation makes things so much quicker. Start using Foundation in your Rails projects by following these instructions.</h4>
8
+ <hr>
9
+
10
+ <h4>Adding Foundation to the Asset Pipeline</h4>
11
+ <p>First you'll want to add the following gems to the assets group in your <code>Gemfile</code> like so:</p>
12
+
13
+ <%= code_example "
14
+ group :assets do
15
+ gem 'sass-rails', '~> 3.2.3'
16
+ gem 'coffee-rails', '~> 3.2.1'
17
+ gem 'uglifier', '>= 1.0.3'
18
+ # Add Foundation Here
19
+ gem 'zurb-foundation', '~> 4.0.0'
20
+ end
21
+ ", :ruby %>
22
+
23
+ <p>Then run <code>bundle install</code> to finish installing Foundation.</p>
24
+
25
+ <div class="alert-box">
26
+ <p><strong>NOTE:</strong> Make sure that your restart your server after running <code>bundle install</code>. Otherwise the asset pipeline may not recognize the new Foundation files.</p>
27
+ </div>
28
+
29
+ <h4>Easy Install</h4>
30
+ <p>Simply run <code>rails g foundation:install</code> to configure your application to use Foundation. That's it!</p>
31
+
32
+ <h4>Manual Installation</h4>
33
+ <h5 class="subheader">Add Foundation to your CSS</h5>
34
+ <p>Append the following line to your <code>app/assets/stylesheets/application.css</code> file:</p>
35
+
36
+ <%= code_example '
37
+ /*= require foundation */
38
+ ', :css %>
39
+
40
+ <p>If you're planning on using <a href="http://sass-lang.com/" rel="nofollow">Sass</a> then you'll want to rename <code>application.css</code> to <code>application.scss</code>. That file should then look like:</p>
41
+
42
+ <%= code_example '
43
+ @import "foundation";
44
+ ', :css %>
45
+
46
+ <h5 class="subheader">Add Foundation to your JS</h5>
47
+ <p>Append the following line to your <code>app/assets/javascripts/application.js</code> file:</p>
48
+
49
+ <%= code_example '
50
+ //= require foundation
51
+ ', :js %>
52
+
53
+ <h5 class="subheader">Set Viewport Width</h5>
54
+ <p>Add the following line to the <kbd>&lt;head&gt;</kbd> of your page layout:</p>
55
+
56
+ <%= code_example '
57
+ <meta name="viewport" content="width=device-width, initial-scale=1.0" />
58
+ ', :html %>
59
+
60
+ </div>
61
+ </div>
62
+ <div class="large-3 pull-9 columns">
63
+ <%= render "_sidebar.html.erb" %>
64
+ </div>
65
+ </div>
66
+ </div>
@@ -0,0 +1,299 @@
1
+ <div class="row">
2
+ <div class="large-9 push-3 columns">
3
+
4
+ <h2>Using the Sass Version of Foundation</h2>
5
+ <h4 class="subheader">Start using Foundation the way you want, with more control than ever before. We've made it really easy to install using Compass so you'll need a little bit of knowledge before you get going. Visit the <a href="http://compass-style.org">Compass</a> and <a href="http://sass-lang.com">Sass</a> sites to learn the basics if you don't already know them.</h4>
6
+
7
+ <h4>Recommended Installation</h4>
8
+ <p>To create your first project using our Compass extension, you'll need to have the <kbd>zurb-foundation</kbd> gem installed. This will install Foundation and all necessary dependencies. Here's the command that will do this for you:</p>
9
+ <p class="btm-marg keystroke">[sudo] gem install zurb-foundation</p>
10
+ <br>
11
+ <em style="font-size: 12px;">Note: Make sure ZURB isn't all caps.</em>
12
+
13
+ <br><br>
14
+
15
+ <div class="row">
16
+ <div class="large-6 columns">
17
+ <h5>Upgrading Your Gem</h5>
18
+ <p>To upgrade your gem to the latest public release, just paste this snippet into your command line:</p>
19
+ <p class="keystroke">[sudo] gem update zurb-foundation</p>
20
+ </div>
21
+ <div class="large-6 columns">
22
+ <h5>Release Candidates</h5>
23
+ <p>Stay on top of the latest before official releases by installing release candidates with this command:</p>
24
+ <p class="btm-marg keystroke">[sudo] gem install zurb-foundation --pre</p>
25
+ </div>
26
+ </div>
27
+
28
+ <br>
29
+
30
+ <div class="row">
31
+ <div class="large-12 columns">
32
+ <h5>Compiling Your Scss</h5>
33
+ <p>To compile your Scss into CSS you run a simple command that will watch for saves and compile each time you save an Scss file. The command is:</p>
34
+ <p class="btm-marg keystroke">compass watch</p>
35
+ </div>
36
+ </div>
37
+
38
+ <br>
39
+ <hr>
40
+
41
+ <a name="create-compass"></a>
42
+ <h2>Creating your first project</h2>
43
+ <h5 class="subheader">Compass makes it really easy to start a new project. Since you've installed the Foundation gem by now, you now have Compass, Sass and a few other necessary dependencies available at your fingertips.</h5>
44
+ <p>Follow these two steps to get going:</p>
45
+ <ol style="margin-left: 20px;">
46
+ <li><span class="keystroke">cd path/to/where-you-want-your-project</span></li>
47
+ <li>run <span class="keystroke">compass create &lt;project-name&gt; -r zurb-foundation --using foundation</span></li>
48
+ </ol>
49
+
50
+ <hr>
51
+
52
+ <a name="compass-existing"></a>
53
+ <h3>Working with Existing projects</h3>
54
+ <h5 class="subheader">There are a couple situations to cover here. You might be adding Foundation to an existing project that wasn't build with Foundation or you might be upgrading Foundation for an already created Foundation Compass project.</h5>
55
+
56
+ <h5>Adding Foundation to existing Compass projects</h5>
57
+ <p>If you've created a project using Compass, but didn't require the Foundation gem, you'll need to install it separately. When you do this you'll get all the necessary files on top of the ones you already have. If something is a duplicate, Compass will ignore it. The steps you'll take to properly install Foundation are:</p>
58
+ <ol style="margin-left: 20px;">
59
+ <li>Add <span class="keystroke">require "zurb-foundation"</span> to your config.rb file</li>
60
+ <li><span class="keystroke">cd path/to/your-project</span></li>
61
+ <li>run <span class="keystroke">compass install foundation</span></li>
62
+ </ol>
63
+
64
+ <!-- <h5>Upgrading Foundation Compass projects</h5>
65
+ <p><strong>Javascript and Image Updates:</strong> If you already added Foundation to your Compass project or created the project using Foundation in the first place and just want to copy over any updated javascripts/image assets to your project, use the provided <kbd>foundation/upgrade</kbd> pattern below:</p>
66
+ <ol style="margin-left: 20px;">
67
+ <li><span class="keystroke">cd /path/to/your-project</span></li>
68
+ <li>run <span class="keystroke">compass install -r zurb-foundation foundation/upgrade force</span></li>
69
+ </ol>
70
+
71
+ <p><strong>Settings file updates:</strong> You can also upgrade Foundation as a whole, which will override the existing Foundation styles and your settings file. So if you've made changes to your settings file and want to make sure your project is on the latest version of Foundation, make sure you backup your settings file before you begin. Alternatively, you can copy/paste the settings from our file and <strong>@import</strong> your own so they don't get erased.</p>
72
+ <p>We also recommend creating a <code>foundation-overrides.scss</code> file that you can use for your own specific styles. This will ensure that your styles don't get obliterated upon updating. <strong>We do not recommend directly editing the Foundation files if you plan to upgrade.</strong> To update you project, use the following steps:</p>
73
+ <ol style="margin-left: 20px;">
74
+ <li>Make sure you've updated your system version of the gem or upgrading won't work.</li>
75
+ <li><span class="keystroke">cd /path/to/your-project</span></li>
76
+ <li>run <span class="keystroke">compass install -r zurb-foundation foundation</span></li>
77
+ </ol> -->
78
+
79
+ <hr>
80
+
81
+ <a name="project-git"></a>
82
+ <h3>Creating a project from Git</h3>
83
+ <h5 class="subheader">Sometimes you want to checkout what we've got even before we decide to deploy a release candidate. For these situations, you can install using Bundler.</h5>
84
+
85
+ <p>There are a few different ways to do this, but here's what we recommend:</p>
86
+ <ol style="margin-left: 20px;">
87
+ <li>Setup a Foundation project folder: <kbd>mkdir ~/awesomeapp</kbd></li>
88
+ <li>Create a Gemfile with this content: <br>
89
+ <kbd style="margin-left: 15px;">source :rubygems</kbd> <br>
90
+ <kbd style="margin-left: 15px;">gem "zurb-foundation", :git => "git@github.com:zurb/foundation.git"</kbd> <br>
91
+ <kbd style="margin-left: 15px;">gem "compass"</kbd>
92
+ </li>
93
+ <li>Then run: <kbd>touch ~/awesomeapp/Gemfile</kbd></li>
94
+ <li>Change into your application directory: <kbd>cd ~/awesomeapp</kbd></li>
95
+ <li>Create a project using Bundler: <kbd>bundle exec compass create . -r zurb-foundation --using foundation</kbd></li>
96
+ <li>When you're working on your project, run: <kbd>bundle exec compass watch</kbd></li>
97
+ </ol>
98
+
99
+ <hr>
100
+
101
+ <h3>Foundation Global Settings and Mixins</h3>
102
+ <p>We've inlcluded a global settings file that holds veriables and mixins that are used throughout the entirety of Foundation. Here's a look at that file:</p>
103
+
104
+ <%= code_example '
105
+ // Foundation Global Function, Variables and Mixins
106
+ //
107
+ // Variables
108
+ //
109
+
110
+ // This is the default html and body font-size for the base em value.
111
+ $em-base: 16px;
112
+
113
+ // We use these to control various global styles
114
+ $body-bg: #fff;
115
+ $body-font-color: #222;
116
+ $body-font-family: "Helvetica Neue", "Helvetica", Helvetica, Arial, sans-serif;
117
+ $body-font-weight: normal;
118
+ $body-font-style: normal;
119
+
120
+ // We use this to control font-smoothing
121
+ $font-smoothing: antialiased;
122
+
123
+ // We use these to control text direction settings
124
+ $text-direction: ltr;
125
+
126
+ // We use these as default colors throughout
127
+ $primary-color: #2ba6cb;
128
+ $secondary-color: #e9e9e9;
129
+ $alert-color: #c60f13;
130
+ $success-color: #5da423;
131
+
132
+ // We use these to make sure border radius matches unless we want it different.
133
+ $global-radius: 3px;
134
+ $global-rounded: 1000px;
135
+
136
+ // We use these to control inset shadow shiny edges and depressions.
137
+ $shiny-edge-size: 0 1px 0;
138
+ $shiny-edge-color: rgba(#fff, .5);
139
+ $shiny-edge-active-color: rgba(#000, .2);
140
+
141
+ // We use this to control whether or not CSS classes come through in the gem files.
142
+ $include-html-classes: true;
143
+ $include-print-styles: true;
144
+
145
+
146
+ //
147
+ // Functions
148
+ //
149
+
150
+ // Working in ems is annoying. Think in pixels by using this handy function, emCalc(#px)
151
+ @function emCalc($pxWidth) {
152
+ @return $pxWidth / $em-base * 1em;
153
+ }
154
+
155
+ // Creating rems and pixels
156
+ @function remCalc($pxWidth) {
157
+ @return $pxWidth / $em-base * 1rem;
158
+ }
159
+
160
+ // Grid Calculation for Percentages
161
+ @function gridCalc($colNumber, $totalColumns) {
162
+ @return percentage(($colNumber / $totalColumns));
163
+ }
164
+
165
+
166
+ //
167
+ // Mixins
168
+ //
169
+
170
+ // We use this to control border radius.
171
+ @mixin radius($radius:$global-radius) {
172
+ @if $radius {
173
+ -webkit-border-radius: $radius;
174
+ border-radius: $radius;
175
+ }
176
+ }
177
+
178
+ // We use this to create equal side border radius on elements.
179
+ @mixin side-radius($side, $radius) {
180
+ @if $side == left {
181
+ -webkit-border-radius: $radius 0 0 $radius;
182
+ border-radius: $radius 0 0 $radius;
183
+ }
184
+ @else if $side == right {
185
+ -webkit-border-radius: 0 $radius $radius 0;
186
+ border-radius: 0 $radius $radius 0;
187
+ }
188
+ @else if $side == top {
189
+ -webkit-border-radius: $radius $radius 0 0;
190
+ border-radius: $radius $radius 0 0;
191
+ }
192
+ @else if $side == bottom {
193
+ -webkit-border-radius: 0 0 $radius $radius;
194
+ border-radius: 0 0 $radius $radius;
195
+ }
196
+ }
197
+
198
+ // We can control whether or not we have inset shadows edges.
199
+ @mixin inset-shadow($active:true) {
200
+ -webkit-box-shadow: $shiny-edge-size $shiny-edge-color inset;
201
+ box-shadow: $shiny-edge-size $shiny-edge-color inset;
202
+
203
+ @if $active { &:active {
204
+ -webkit-box-shadow: $shiny-edge-size $shiny-edge-active-color inset;
205
+ box-shadow: $shiny-edge-size $shiny-edge-active-color inset; } }
206
+ }
207
+
208
+ // We use this to add transitions to elements
209
+ @mixin single-transition($property:all, $speed:300ms, $ease:ease-out) {
210
+ -webkit-transition: $property $speed $ease;
211
+ -moz-transition: $property $speed $ease;
212
+ transition: $property $speed $ease;
213
+ }
214
+
215
+ // We use this to add box-sizing across browser prefixes
216
+ @mixin box-sizing($type:border-box) {
217
+ -moz-box-sizing: $type;
218
+ -webkit-box-sizing: $type;
219
+ box-sizing: $type;
220
+ }
221
+
222
+ // We use this to create equalateral triangles
223
+ @mixin css-triangle($triangle-size, $triangle-color, $triangle-direction) {
224
+ content: "";
225
+ display: block;
226
+ width: 0;
227
+ height: 0;
228
+ border: solid $triangle-size;
229
+ @if ($triangle-direction == top) {
230
+ border-color: $triangle-color transparent transparent transparent;
231
+ }
232
+ @if ($triangle-direction == bottom) {
233
+ border-color: transparent transparent $triangle-color transparent;
234
+ }
235
+ @if ($triangle-direction == left) {
236
+ border-color: transparent transparent transparent $triangle-color;
237
+ }
238
+ @if ($triangle-direction == right) {
239
+ border-color: transparent $triangle-color transparent transparent;
240
+ }
241
+ }
242
+
243
+ // We use this to do clear floats
244
+ @mixin clearfix() {
245
+ *zoom:1;
246
+ &:before, &:after { content: " "; display: table; }
247
+ &:after { clear: both; }
248
+ }
249
+
250
+ ', :css %>
251
+
252
+
253
+ <!-- <a name="gui-apps"></a>
254
+ <h3>Working with GUI applications</h3>
255
+ <h5 class="subheader">We want you to be able to work with Foundation in whatever way you are comfortable and we realize that not all of us are Terminal ninjas. Here's a rundown of some of the popular GUI applications and how to utilize Foundation with them.</h5>
256
+
257
+ <h5>CodeKit Project</h5>
258
+ <p>We're using a version of Sass and Compass that doesn't come with CodeKit. This means that you'll need to do a couple steps in order to get everything to compile correctly:</p>
259
+ <ol style="margin-left: 20px;">
260
+ <li>First things first, make sure you have the gem installed.</li>
261
+ <li>Run <kbd>[sudo] gem environment</kbd> in the command line, note your gem executables path.</li>
262
+ <li>Go into <strong>Codekit prefs</strong>, click on <strong>Sass/Scss</strong></li>
263
+ <li>Click on <strong>"Use the Sass executable at this path:"</strong></li>
264
+ <li>Navigate to the <strong>bin</strong> folder at the gem path you found earlier.</li>
265
+ <li>Select sass.bin</li>
266
+ <li>Click on <strong>Compass</strong> in the preferences menu.</li>
267
+ <li>Click on <strong>"Use the Compass executable at this path:"</strong></li>
268
+ <li>Navigate to the <strong>bin</strong> folder at the gem path you found earlier.</li>
269
+ <li>Select compass.bin</li>
270
+ <li>Compile to your hearts content.</li>
271
+ </ol>
272
+
273
+ <p><strong>Note:</strong> CodeKit does not support adding Foundation as a "framework" through the GUI. You'll need to use the steps above to accomplish this.</p>
274
+
275
+ <h5>LiveReload</h5>
276
+ <p>While LiveReload works great within CodeKit, it doesn't work well on its own because you can't update it to use your system Sass and Compass directories. Do not use this application to compile Foundation.</p>
277
+
278
+ <h5>Compass.app</h5>
279
+ <p>Foundation is included with Compass.app.</p>
280
+
281
+ <h5>Scout</h5>
282
+ <p>This app doesn't have support for updating the version of Sass and Compass that you use so we're not supporting it at this point.</p>
283
+
284
+ <hr> -->
285
+
286
+ </div>
287
+
288
+ <div class="large-3 pull-9 columns">
289
+ <%= render "_sidebar.html.erb" %>
290
+ </div>
291
+ </div>
292
+
293
+
294
+
295
+
296
+
297
+
298
+
299
+