locomotivecms_wagon 1.4.0 → 1.5.0.rc1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (352) hide show
  1. checksums.yaml +4 -4
  2. data/.travis.yml +3 -0
  3. data/Gemfile +6 -2
  4. data/README.md +7 -1
  5. data/bin/wagon +3 -0
  6. data/generators/blank/Gemfile.tt +1 -3
  7. data/generators/blank/config/site.yml.tt +3 -3
  8. data/generators/bootstrap/config/site.yml.tt +3 -3
  9. data/generators/bootstrap3/Gemfile.tt +1 -3
  10. data/generators/bootstrap3/app/views/pages/index.liquid +21 -63
  11. data/generators/bootstrap3/app/views/pages/index.liquid.haml +15 -57
  12. data/generators/bootstrap3/config/deploy.yml +15 -15
  13. data/generators/bootstrap3/config/site.yml.tt +2 -2
  14. data/generators/bootstrap3/icon.png +0 -0
  15. data/generators/bootstrap3/public/fonts/glyphicons-halflings-regular.eot +0 -0
  16. data/generators/bootstrap3/public/fonts/glyphicons-halflings-regular.svg +201 -200
  17. data/generators/bootstrap3/public/fonts/glyphicons-halflings-regular.ttf +0 -0
  18. data/generators/bootstrap3/public/fonts/glyphicons-halflings-regular.woff +0 -0
  19. data/generators/{bootstrap2/app/content_types → bootstrap3/public/images}/.empty_directory +0 -0
  20. data/generators/bootstrap3/public/javascripts/bootstrap/affix.js +137 -0
  21. data/generators/bootstrap3/public/javascripts/bootstrap/alert.js +88 -0
  22. data/generators/bootstrap3/public/javascripts/bootstrap/button.js +107 -0
  23. data/generators/bootstrap3/public/javascripts/bootstrap/carousel.js +205 -0
  24. data/generators/bootstrap3/public/javascripts/bootstrap/collapse.js +170 -0
  25. data/generators/bootstrap3/public/javascripts/bootstrap/dropdown.js +147 -0
  26. data/generators/bootstrap3/public/javascripts/bootstrap/modal.js +243 -0
  27. data/generators/bootstrap3/public/javascripts/bootstrap/popover.js +110 -0
  28. data/generators/bootstrap3/public/javascripts/bootstrap/scrollspy.js +153 -0
  29. data/generators/bootstrap3/public/javascripts/bootstrap/tab.js +125 -0
  30. data/generators/bootstrap3/public/javascripts/bootstrap/tooltip.js +399 -0
  31. data/generators/bootstrap3/public/javascripts/bootstrap/transition.js +48 -0
  32. data/generators/bootstrap3/public/javascripts/bootstrap.min.js +12 -6
  33. data/generators/bootstrap3/public/stylesheets/application.css +1 -0
  34. data/generators/bootstrap3/public/stylesheets/application.css.scss +8 -0
  35. data/generators/bootstrap3/public/stylesheets/bootstrap/_alerts.scss +67 -0
  36. data/generators/bootstrap3/public/stylesheets/bootstrap/_badges.scss +55 -0
  37. data/generators/bootstrap3/public/stylesheets/bootstrap/_breadcrumbs.scss +26 -0
  38. data/generators/bootstrap3/public/stylesheets/bootstrap/_button-groups.scss +226 -0
  39. data/generators/bootstrap3/public/stylesheets/bootstrap/_buttons.scss +159 -0
  40. data/generators/bootstrap3/public/stylesheets/bootstrap/_carousel.scss +232 -0
  41. data/generators/bootstrap3/public/stylesheets/bootstrap/_close.scss +35 -0
  42. data/generators/bootstrap3/public/stylesheets/bootstrap/_code.scss +63 -0
  43. data/generators/bootstrap3/public/stylesheets/bootstrap/_component-animations.scss +29 -0
  44. data/generators/bootstrap3/public/stylesheets/bootstrap/_dropdowns.scss +213 -0
  45. data/generators/bootstrap3/public/stylesheets/bootstrap/_forms.scss +436 -0
  46. data/generators/bootstrap3/public/stylesheets/bootstrap/_glyphicons.scss +233 -0
  47. data/generators/bootstrap3/public/stylesheets/bootstrap/_grid.scss +84 -0
  48. data/generators/bootstrap3/public/stylesheets/bootstrap/_input-groups.scss +162 -0
  49. data/generators/bootstrap3/public/stylesheets/bootstrap/_jumbotron.scss +44 -0
  50. data/generators/bootstrap3/public/stylesheets/bootstrap/_labels.scss +64 -0
  51. data/generators/bootstrap3/public/stylesheets/bootstrap/_list-group.scss +110 -0
  52. data/generators/bootstrap3/public/stylesheets/bootstrap/_media.scss +56 -0
  53. data/generators/bootstrap3/public/stylesheets/bootstrap/_mixins.scss +947 -0
  54. data/generators/bootstrap3/public/stylesheets/bootstrap/_modals.scss +139 -0
  55. data/generators/bootstrap3/public/stylesheets/bootstrap/_navbar.scss +620 -0
  56. data/generators/bootstrap3/public/stylesheets/bootstrap/_navs.scss +242 -0
  57. data/generators/bootstrap3/public/stylesheets/bootstrap/_normalize.scss +423 -0
  58. data/generators/bootstrap3/public/stylesheets/bootstrap/_pager.scss +55 -0
  59. data/generators/bootstrap3/public/stylesheets/bootstrap/_pagination.scss +88 -0
  60. data/generators/bootstrap3/public/stylesheets/bootstrap/_panels.scss +241 -0
  61. data/generators/bootstrap3/public/stylesheets/bootstrap/_popovers.scss +133 -0
  62. data/generators/bootstrap3/public/stylesheets/bootstrap/_print.scss +101 -0
  63. data/generators/bootstrap3/public/stylesheets/bootstrap/_progress-bars.scss +80 -0
  64. data/generators/bootstrap3/public/stylesheets/bootstrap/_responsive-utilities.scss +74 -0
  65. data/generators/bootstrap3/public/stylesheets/bootstrap/_scaffolding.scss +134 -0
  66. data/generators/bootstrap3/public/stylesheets/bootstrap/_tables.scss +233 -0
  67. data/generators/bootstrap3/public/stylesheets/bootstrap/_theme.scss +247 -0
  68. data/generators/bootstrap3/public/stylesheets/bootstrap/_thumbnails.scss +38 -0
  69. data/generators/bootstrap3/public/stylesheets/bootstrap/_tooltip.scss +95 -0
  70. data/generators/bootstrap3/public/stylesheets/bootstrap/_type.scss +284 -0
  71. data/generators/bootstrap3/public/stylesheets/bootstrap/_utilities.scss +56 -0
  72. data/generators/bootstrap3/public/stylesheets/bootstrap/_variables.scss +833 -0
  73. data/generators/bootstrap3/public/stylesheets/bootstrap/_wells.scss +29 -0
  74. data/generators/bootstrap3/public/stylesheets/bootstrap/bootstrap.css.scss +49 -0
  75. data/generators/bootstrap3/public/stylesheets/bootstrap.css +2035 -3056
  76. data/generators/bootstrap3/public/stylesheets/bootstrap.css.scss +49 -0
  77. data/generators/cloned/Gemfile.tt +1 -3
  78. data/generators/content_type/app/content_types/%slug%.yml.tt +57 -0
  79. data/generators/content_type/data/{%name%.yml.tt → %slug%.yml.tt} +2 -2
  80. data/generators/{bootstrap2 → foundation5}/Gemfile.tt +1 -3
  81. data/generators/{bootstrap2/data → foundation5/app/content_types}/.empty_directory +0 -0
  82. data/generators/{foundation → foundation5}/app/views/pages/404.liquid +1 -4
  83. data/generators/{foundation → foundation5}/app/views/pages/404.liquid.haml +1 -1
  84. data/generators/foundation5/app/views/pages/index.liquid +196 -0
  85. data/generators/foundation5/app/views/pages/index.liquid.haml +157 -0
  86. data/generators/foundation5/config/deploy.yml +15 -0
  87. data/generators/{bootstrap2 → foundation5}/config/site.yml.tt +3 -4
  88. data/generators/{bootstrap2 → foundation5}/config/translations.yml +0 -0
  89. data/generators/{bootstrap2 → foundation5}/config.ru +0 -0
  90. data/generators/{bootstrap2/public/samples → foundation5/data}/.empty_directory +0 -0
  91. data/generators/foundation5/favicon.ico +0 -0
  92. data/generators/foundation5/icon.png +0 -0
  93. data/generators/{foundation/app/content_types → foundation5/public/fonts}/.empty_directory +0 -0
  94. data/generators/{foundation/data → foundation5/public/images}/.empty_directory +0 -0
  95. data/generators/foundation5/public/javascripts/foundation/foundation.abide.js +299 -0
  96. data/generators/foundation5/public/javascripts/foundation/foundation.accordion.js +59 -0
  97. data/generators/foundation5/public/javascripts/foundation/foundation.alert.js +43 -0
  98. data/generators/foundation5/public/javascripts/foundation/foundation.clearing.js +534 -0
  99. data/generators/foundation5/public/javascripts/foundation/foundation.dropdown.js +311 -0
  100. data/generators/foundation5/public/javascripts/foundation/foundation.equalizer.js +74 -0
  101. data/generators/foundation5/public/javascripts/foundation/foundation.interchange.js +331 -0
  102. data/generators/foundation5/public/javascripts/foundation/foundation.joyride.js +843 -0
  103. data/generators/foundation5/public/javascripts/foundation/foundation.js +611 -0
  104. data/generators/foundation5/public/javascripts/foundation/foundation.magellan.js +178 -0
  105. data/generators/foundation5/public/javascripts/foundation/foundation.offcanvas.js +108 -0
  106. data/generators/foundation5/public/javascripts/foundation/foundation.orbit.js +610 -0
  107. data/generators/foundation5/public/javascripts/foundation/foundation.reveal.js +437 -0
  108. data/generators/foundation5/public/javascripts/foundation/foundation.slider.js +199 -0
  109. data/generators/foundation5/public/javascripts/foundation/foundation.tab.js +167 -0
  110. data/generators/foundation5/public/javascripts/foundation/foundation.tooltip.js +298 -0
  111. data/generators/foundation5/public/javascripts/foundation/foundation.topbar.js +425 -0
  112. data/generators/foundation5/public/javascripts/foundation.js +4161 -0
  113. data/generators/foundation5/public/javascripts/foundation.min.js +10 -0
  114. data/generators/{foundation → foundation5}/public/javascripts/vendor/custom.modernizr.js +0 -0
  115. data/generators/foundation5/public/javascripts/vendor/custom.modernizr.min.js +1 -0
  116. data/generators/foundation5/public/javascripts/vendor/fastclick.js +9 -0
  117. data/generators/foundation5/public/javascripts/vendor/fastclick.min.js +11 -0
  118. data/generators/foundation5/public/javascripts/vendor/jquery.autocomplete.js +645 -0
  119. data/generators/foundation5/public/javascripts/vendor/jquery.autocomplete.min.js +1 -0
  120. data/generators/foundation5/public/javascripts/vendor/jquery.cookie.js +8 -0
  121. data/generators/foundation5/public/javascripts/vendor/jquery.cookie.min.js +8 -0
  122. data/generators/foundation5/public/javascripts/vendor/jquery.js +26 -0
  123. data/generators/foundation5/public/javascripts/vendor/jquery.min.js +27 -0
  124. data/generators/foundation5/public/javascripts/vendor/modernizr.js +8 -0
  125. data/generators/foundation5/public/javascripts/vendor/modernizr.min.js +1 -0
  126. data/generators/foundation5/public/javascripts/vendor/placeholder.js +2 -0
  127. data/generators/foundation5/public/javascripts/vendor/placeholder.min.js +1 -0
  128. data/generators/{foundation/public/fonts → foundation5/public/samples}/.empty_directory +0 -0
  129. data/generators/foundation5/public/stylesheets/application.css +2 -0
  130. data/generators/foundation5/public/stylesheets/application.css.scss +3 -0
  131. data/generators/foundation5/public/stylesheets/foundation/_functions.scss +101 -0
  132. data/generators/foundation5/public/stylesheets/foundation/_settings.scss +1296 -0
  133. data/generators/foundation5/public/stylesheets/foundation/components/_accordion.scss +53 -0
  134. data/generators/foundation5/public/stylesheets/foundation/components/_alert-boxes.scss +126 -0
  135. data/generators/foundation5/public/stylesheets/foundation/components/_block-grid.scss +132 -0
  136. data/generators/foundation5/public/stylesheets/foundation/components/_breadcrumbs.scss +127 -0
  137. data/generators/foundation5/public/stylesheets/foundation/components/_button-groups.scss +108 -0
  138. data/generators/foundation5/public/stylesheets/foundation/components/_buttons.scss +222 -0
  139. data/generators/foundation5/public/stylesheets/foundation/components/_clearing.scss +247 -0
  140. data/generators/foundation5/public/stylesheets/foundation/components/_dropdown-buttons.scss +129 -0
  141. data/generators/foundation5/public/stylesheets/foundation/components/_dropdown.scss +248 -0
  142. data/generators/foundation5/public/stylesheets/foundation/components/_flex-video.scss +51 -0
  143. data/generators/foundation5/public/stylesheets/foundation/components/_forms.scss +498 -0
  144. data/generators/foundation5/public/stylesheets/foundation/components/_global.scss +434 -0
  145. data/generators/foundation5/public/stylesheets/foundation/components/_grid.scss +260 -0
  146. data/generators/foundation5/public/stylesheets/foundation/components/_inline-lists.scss +57 -0
  147. data/generators/foundation5/public/stylesheets/foundation/components/_joyride.scss +220 -0
  148. data/generators/foundation5/public/stylesheets/foundation/components/_keystrokes.scss +61 -0
  149. data/generators/foundation5/public/stylesheets/foundation/components/_labels.scss +104 -0
  150. data/generators/foundation5/public/stylesheets/foundation/components/_magellan.scss +34 -0
  151. data/generators/foundation5/public/stylesheets/foundation/components/_offcanvas.scss +356 -0
  152. data/generators/foundation5/public/stylesheets/foundation/components/_orbit.scss +423 -0
  153. data/generators/foundation5/public/stylesheets/foundation/components/_pagination.scss +150 -0
  154. data/generators/foundation5/public/stylesheets/foundation/components/_panels.scss +90 -0
  155. data/generators/foundation5/public/stylesheets/foundation/components/_pricing-tables.scss +150 -0
  156. data/generators/foundation5/public/stylesheets/foundation/components/_progress-bars.scss +79 -0
  157. data/generators/foundation5/public/stylesheets/foundation/components/_range-slider.scss +148 -0
  158. data/generators/foundation5/public/stylesheets/foundation/components/_reveal-new.scss +0 -0
  159. data/generators/foundation5/public/stylesheets/foundation/components/_reveal.scss +216 -0
  160. data/generators/foundation5/public/stylesheets/foundation/components/_side-nav.scss +115 -0
  161. data/generators/foundation5/public/stylesheets/foundation/components/_split-buttons.scss +191 -0
  162. data/generators/foundation5/public/stylesheets/foundation/components/_sub-nav.scss +125 -0
  163. data/generators/foundation5/public/stylesheets/foundation/components/_switch.scss +294 -0
  164. data/generators/foundation5/public/stylesheets/foundation/components/_tables.scss +129 -0
  165. data/generators/foundation5/public/stylesheets/foundation/components/_tabs.scss +109 -0
  166. data/generators/foundation5/public/stylesheets/foundation/components/_thumbs.scss +68 -0
  167. data/generators/foundation5/public/stylesheets/foundation/components/_tooltips.scss +140 -0
  168. data/generators/foundation5/public/stylesheets/foundation/components/_top-bar.scss +659 -0
  169. data/generators/foundation5/public/stylesheets/foundation/components/_type.scss +513 -0
  170. data/generators/foundation5/public/stylesheets/foundation/components/_visibility.scss +408 -0
  171. data/generators/foundation5/public/stylesheets/foundation.css +5398 -0
  172. data/generators/foundation5/public/stylesheets/foundation.css.scss +45 -0
  173. data/generators/foundation5/public/stylesheets/normalize.css +425 -0
  174. data/generators/foundation5/public/stylesheets/normalize.css.scss +425 -0
  175. data/generators/{foundation → line_case}/Gemfile.tt +1 -3
  176. data/generators/line_case/app/content_types/categories.yml +56 -0
  177. data/generators/line_case/app/content_types/emails.yml +35 -0
  178. data/generators/line_case/app/content_types/projects.yml +58 -0
  179. data/generators/{bootstrap2 → line_case}/app/views/pages/404.liquid.haml +3 -2
  180. data/generators/line_case/app/views/pages/email-registered.liquid.haml +13 -0
  181. data/generators/line_case/app/views/pages/index.liquid.haml +110 -0
  182. data/generators/line_case/app/views/pages/projects/content_type_template.liquid.haml +32 -0
  183. data/generators/line_case/app/views/snippets/newsletter_form.liquid.haml +14 -0
  184. data/generators/line_case/app/views/snippets/projects.liquid.haml +17 -0
  185. data/generators/line_case/app/views/snippets/social_links.liquid.haml +19 -0
  186. data/generators/line_case/config/deploy.yml +15 -0
  187. data/generators/{foundation → line_case}/config/site.yml.tt +3 -3
  188. data/generators/{foundation → line_case}/config/translations.yml +0 -0
  189. data/generators/{foundation → line_case}/config.ru +0 -0
  190. data/generators/line_case/data/categories.yml +8 -0
  191. data/generators/line_case/data/emails.yml +2 -0
  192. data/generators/line_case/data/projects.yml +39 -0
  193. data/generators/line_case/icon.png +0 -0
  194. data/generators/line_case/public/images/banner-header.png +0 -0
  195. data/generators/{foundation → line_case}/public/javascripts/foundation/foundation.abide.js +0 -0
  196. data/generators/{foundation → line_case}/public/javascripts/foundation/foundation.alerts.js +0 -0
  197. data/generators/{foundation → line_case}/public/javascripts/foundation/foundation.clearing.js +0 -0
  198. data/generators/{foundation → line_case}/public/javascripts/foundation/foundation.cookie.js +0 -0
  199. data/generators/{foundation → line_case}/public/javascripts/foundation/foundation.dropdown.js +0 -0
  200. data/generators/{foundation → line_case}/public/javascripts/foundation/foundation.forms.js +0 -0
  201. data/generators/{foundation → line_case}/public/javascripts/foundation/foundation.interchange.js +0 -0
  202. data/generators/{foundation → line_case}/public/javascripts/foundation/foundation.joyride.js +0 -0
  203. data/generators/{foundation → line_case}/public/javascripts/foundation/foundation.js +0 -0
  204. data/generators/{foundation → line_case}/public/javascripts/foundation/foundation.magellan.js +0 -0
  205. data/generators/{foundation → line_case}/public/javascripts/foundation/foundation.orbit.js +0 -0
  206. data/generators/{foundation → line_case}/public/javascripts/foundation/foundation.placeholder.js +0 -0
  207. data/generators/{foundation → line_case}/public/javascripts/foundation/foundation.reveal.js +0 -0
  208. data/generators/{foundation → line_case}/public/javascripts/foundation/foundation.section.js +0 -0
  209. data/generators/{foundation → line_case}/public/javascripts/foundation/foundation.tooltips.js +0 -0
  210. data/generators/{foundation → line_case}/public/javascripts/foundation/foundation.topbar.js +0 -0
  211. data/generators/{foundation → line_case}/public/javascripts/foundation.min.js +0 -0
  212. data/generators/line_case/public/javascripts/vendor/custom.modernizr.js +4 -0
  213. data/generators/{foundation → line_case}/public/javascripts/vendor/jquery.js +0 -0
  214. data/generators/{foundation → line_case}/public/javascripts/vendor/zepto.js +0 -0
  215. data/generators/line_case/public/samples/projects/sample.jpeg +0 -0
  216. data/generators/line_case/public/samples/projects/sample2.jpeg +0 -0
  217. data/generators/line_case/public/samples/projects/sample3.jpeg +0 -0
  218. data/generators/line_case/public/samples/projects/sample4.jpeg +0 -0
  219. data/generators/line_case/public/samples/projects/sample5.jpeg +0 -0
  220. data/generators/line_case/public/samples/projects/sample6.jpeg +0 -0
  221. data/generators/line_case/public/samples/projects/sample7.jpeg +0 -0
  222. data/generators/line_case/public/samples/projects/sample8.jpeg +0 -0
  223. data/generators/line_case/public/stylesheets/_variables.css.sass +20 -0
  224. data/generators/line_case/public/stylesheets/foundation/_variables.scss +1290 -0
  225. data/generators/line_case/public/stylesheets/foundation/components/_alert-boxes.scss +107 -0
  226. data/generators/line_case/public/stylesheets/foundation/components/_block-grid.scss +71 -0
  227. data/generators/line_case/public/stylesheets/foundation/components/_breadcrumbs.scss +124 -0
  228. data/generators/line_case/public/stylesheets/foundation/components/_button-groups.scss +89 -0
  229. data/generators/line_case/public/stylesheets/foundation/components/_buttons.scss +230 -0
  230. data/generators/line_case/public/stylesheets/foundation/components/_clearing.scss +227 -0
  231. data/generators/line_case/public/stylesheets/foundation/components/_custom-forms.scss +278 -0
  232. data/generators/line_case/public/stylesheets/foundation/components/_dropdown-buttons.scss +115 -0
  233. data/generators/line_case/public/stylesheets/foundation/components/_dropdown.scss +151 -0
  234. data/generators/line_case/public/stylesheets/foundation/components/_flex-video.scss +46 -0
  235. data/generators/line_case/public/stylesheets/foundation/components/_forms.scss +411 -0
  236. data/generators/line_case/public/stylesheets/foundation/components/_global.scss +366 -0
  237. data/generators/line_case/public/stylesheets/foundation/components/_grid-5.scss +214 -0
  238. data/generators/line_case/public/stylesheets/foundation/components/_grid.scss +188 -0
  239. data/generators/line_case/public/stylesheets/foundation/components/_inline-lists.scss +53 -0
  240. data/generators/line_case/public/stylesheets/foundation/components/_joyride.scss +217 -0
  241. data/generators/line_case/public/stylesheets/foundation/components/_keystrokes.scss +57 -0
  242. data/generators/line_case/public/stylesheets/foundation/components/_labels.scss +85 -0
  243. data/generators/line_case/public/stylesheets/foundation/components/_magellan.scss +23 -0
  244. data/generators/line_case/public/stylesheets/foundation/components/_orbit.scss +340 -0
  245. data/generators/line_case/public/stylesheets/foundation/components/_pagination.scss +140 -0
  246. data/generators/line_case/public/stylesheets/foundation/components/_panels.scss +83 -0
  247. data/generators/line_case/public/stylesheets/foundation/components/_pricing-tables.scss +131 -0
  248. data/generators/line_case/public/stylesheets/foundation/components/_progress-bars.scss +71 -0
  249. data/generators/line_case/public/stylesheets/foundation/components/_reveal.scss +136 -0
  250. data/generators/line_case/public/stylesheets/foundation/components/_section.scss +391 -0
  251. data/generators/line_case/public/stylesheets/foundation/components/_side-nav.scss +69 -0
  252. data/generators/line_case/public/stylesheets/foundation/components/_split-buttons.scss +167 -0
  253. data/generators/line_case/public/stylesheets/foundation/components/_sub-nav.scss +84 -0
  254. data/generators/line_case/public/stylesheets/foundation/components/_switch.scss +266 -0
  255. data/generators/line_case/public/stylesheets/foundation/components/_tables.scss +84 -0
  256. data/generators/line_case/public/stylesheets/foundation/components/_thumbs.scss +53 -0
  257. data/generators/line_case/public/stylesheets/foundation/components/_tooltips.scss +117 -0
  258. data/generators/line_case/public/stylesheets/foundation/components/_top-bar.scss +576 -0
  259. data/generators/line_case/public/stylesheets/foundation/components/_type.scss +435 -0
  260. data/generators/line_case/public/stylesheets/foundation/components/_visibility.scss +322 -0
  261. data/generators/line_case/public/stylesheets/foundation.css.scss +43 -0
  262. data/generators/{foundation → line_case}/public/stylesheets/foundation.min.css +0 -0
  263. data/generators/{foundation/public/stylesheets/normalize.css → line_case/public/stylesheets/normalize.css.scss} +5 -5
  264. data/generators/line_case/public/stylesheets/pages.css.sass +163 -0
  265. data/generators/page/template.liquid.haml.tt +8 -5
  266. data/generators/page/template.liquid.tt +6 -2
  267. data/lib/locomotive/wagon/cli.rb +139 -43
  268. data/lib/locomotive/wagon/generators/content_type.rb +26 -10
  269. data/lib/locomotive/wagon/generators/page.rb +41 -25
  270. data/lib/locomotive/wagon/generators/site/base.rb +53 -0
  271. data/lib/locomotive/wagon/generators/site/blank.rb +9 -2
  272. data/lib/locomotive/wagon/generators/site/bootstrap2.rb +8 -2
  273. data/lib/locomotive/wagon/generators/site/bootstrap3.rb +20 -2
  274. data/lib/locomotive/wagon/generators/site/cloned.rb +4 -0
  275. data/lib/locomotive/wagon/generators/site/{foundation.rb → foundation4.rb} +10 -4
  276. data/lib/locomotive/wagon/generators/site/foundation5.rb +48 -0
  277. data/lib/locomotive/wagon/generators/site/line_case.rb +20 -0
  278. data/lib/locomotive/wagon/generators/site/unzip.rb +10 -2
  279. data/lib/locomotive/wagon/generators/site.rb +48 -2
  280. data/lib/locomotive/wagon/generators/snippet.rb +2 -1
  281. data/lib/locomotive/wagon/liquid/drops/content_types.rb +9 -3
  282. data/lib/locomotive/wagon/liquid/drops/page.rb +9 -1
  283. data/lib/locomotive/wagon/liquid/scopeable.rb +1 -1
  284. data/lib/locomotive/wagon/liquid/tags/fetch_page.rb +41 -0
  285. data/lib/locomotive/wagon/liquid/tags/model_form.rb +67 -0
  286. data/lib/locomotive/wagon/liquid/tags/path_helper.rb +2 -2
  287. data/lib/locomotive/wagon/liquid/tags/with_scope.rb +1 -1
  288. data/lib/locomotive/wagon/listen.rb +18 -10
  289. data/lib/locomotive/wagon/logger.rb +4 -0
  290. data/lib/locomotive/wagon/misc/core_ext.rb +8 -0
  291. data/lib/locomotive/wagon/misc/deployment_connection.rb +120 -0
  292. data/lib/locomotive/wagon/misc/hosting_api.rb +115 -0
  293. data/lib/locomotive/wagon/misc/httparty.rb +2 -0
  294. data/lib/locomotive/wagon/misc/livereload.rb +43 -0
  295. data/lib/locomotive/wagon/misc/mounter.rb +1 -1
  296. data/lib/locomotive/wagon/misc/tcp_port.rb +42 -0
  297. data/lib/locomotive/wagon/misc/thor.rb +15 -0
  298. data/lib/locomotive/wagon/server/entry_submission.rb +69 -38
  299. data/lib/locomotive/wagon/server/middleware.rb +4 -2
  300. data/lib/locomotive/wagon/server/page.rb +2 -2
  301. data/lib/locomotive/wagon/server.rb +11 -7
  302. data/lib/locomotive/wagon/version.rb +1 -1
  303. data/lib/locomotive/wagon.rb +141 -30
  304. data/locomotivecms_wagon.gemspec +7 -6
  305. data/spec/fixtures/default/app/content_types/bands.yml +3 -1
  306. data/spec/fixtures/default/app/views/pages/all.liquid.haml +3 -0
  307. data/spec/fixtures/default/app/views/pages/events.liquid.haml +21 -0
  308. data/spec/fixtures/default/app/views/pages/filtered.liquid.haml +11 -1
  309. data/spec/fixtures/default/app/views/pages/index.liquid.haml +1 -1
  310. data/spec/fixtures/default/data/bands.yml +3 -0
  311. data/spec/integration/server/basic_spec.rb +1 -0
  312. data/spec/integration/server/contact_form_spec.rb +1 -1
  313. data/spec/integration/server/liquid_spec.rb +8 -1
  314. data/spec/integration/server/new_contact_form_spec.rb +67 -0
  315. data/spec/integration/server/with_scope_spec.rb +10 -0
  316. data/spec/spec_helper.rb +3 -0
  317. metadata +339 -144
  318. data/generators/bootstrap2/app/views/pages/404.liquid +0 -13
  319. data/generators/bootstrap2/app/views/pages/index.liquid +0 -98
  320. data/generators/bootstrap2/app/views/pages/index.liquid.haml +0 -80
  321. data/generators/bootstrap2/app/views/snippets/footer.liquid +0 -3
  322. data/generators/bootstrap2/app/views/snippets/footer.liquid.haml +0 -2
  323. data/generators/bootstrap2/config/deploy.yml +0 -15
  324. data/generators/bootstrap2/public/fonts/FontAwesome.otf +0 -0
  325. data/generators/bootstrap2/public/fonts/fontawesome-webfont.eot +0 -0
  326. data/generators/bootstrap2/public/fonts/fontawesome-webfont.svg +0 -399
  327. data/generators/bootstrap2/public/fonts/fontawesome-webfont.ttf +0 -0
  328. data/generators/bootstrap2/public/fonts/fontawesome-webfont.woff +0 -0
  329. data/generators/bootstrap2/public/javascripts/bootstrap.js +0 -2280
  330. data/generators/bootstrap2/public/javascripts/bootstrap.min.js +0 -6
  331. data/generators/bootstrap2/public/stylesheets/application.css.scss +0 -39
  332. data/generators/bootstrap2/public/stylesheets/bootstrap-responsive.css +0 -1109
  333. data/generators/bootstrap2/public/stylesheets/bootstrap-responsive.min.css +0 -9
  334. data/generators/bootstrap2/public/stylesheets/bootstrap.css +0 -5568
  335. data/generators/bootstrap2/public/stylesheets/bootstrap.min.css +0 -9
  336. data/generators/bootstrap2/public/stylesheets/fonts/awesome.css.scss +0 -3
  337. data/generators/bootstrap2/public/stylesheets/fonts/font-awesome-ie7.css +0 -1203
  338. data/generators/bootstrap2/public/stylesheets/fonts/font-awesome-ie7.min.css +0 -384
  339. data/generators/bootstrap2/public/stylesheets/fonts/font-awesome.css +0 -1470
  340. data/generators/bootstrap2/public/stylesheets/fonts/font-awesome.min.css +0 -403
  341. data/generators/bootstrap3/public/javascripts/bootstrap.js +0 -1999
  342. data/generators/bootstrap3/public/stylesheets/bootstrap-theme.css +0 -384
  343. data/generators/bootstrap3/public/stylesheets/bootstrap-theme.min.css +0 -1
  344. data/generators/bootstrap3/public/stylesheets/bootstrap.min.css +0 -9
  345. data/generators/content_type/app/content_types/%name%.yml.tt +0 -58
  346. data/generators/foundation/app/views/pages/index.liquid +0 -150
  347. data/generators/foundation/app/views/pages/index.liquid.haml +0 -125
  348. data/generators/foundation/app/views/snippets/footer.liquid +0 -16
  349. data/generators/foundation/app/views/snippets/footer.liquid.haml +0 -22
  350. data/generators/foundation/config/deploy.yml +0 -15
  351. data/generators/foundation/public/samples/.empty_directory +0 -1
  352. data/generators/foundation/public/stylesheets/foundation.css +0 -4727
@@ -0,0 +1,227 @@
1
+ //
2
+ // Clearing Variables
3
+ //
4
+ $include-html-clearing-classes: $include-html-classes !default;
5
+
6
+ // We use these to set the background colors for parts of Clearing.
7
+ $clearing-bg: #111 !default;
8
+ $clearing-caption-bg: $clearing-bg !default;
9
+ $clearing-carousel-bg: #111 !default;
10
+ $clearing-img-bg: $clearing-bg !default;
11
+
12
+ // We use these to style the close button
13
+ $clearing-close-color: #fff !default;
14
+ $clearing-close-size: 40px !default;
15
+
16
+ // We use these to style the arrows
17
+ $clearing-arrow-size: 16px !default;
18
+ $clearing-arrow-color: $clearing-close-color !default;
19
+
20
+ // We use these to style captions
21
+ $clearing-caption-font-color: #fff !default;
22
+ $clearing-caption-padding: 10px 30px !default;
23
+
24
+ // We use these to make the image and carousel height and style
25
+ $clearing-active-img-height: 75% !default;
26
+ $clearing-carousel-height: 150px !default;
27
+ $clearing-carousel-thumb-width: 175px !default;
28
+ $clearing-carousel-thumb-active-border: 4px solid rgb(255,255,255) !default;
29
+
30
+ @if $include-html-clearing-classes {
31
+ // We decided to not create a mixin for Clearing because it relies
32
+ // on predefined classes and structure to work properly.
33
+ // The variables above should give enough control.
34
+
35
+ /* Clearing Styles */
36
+ [data-clearing] {
37
+ @include clearfix;
38
+ margin-bottom: 0;
39
+ margin-#{$default-float}: 0;
40
+ list-style: none;
41
+
42
+ li {
43
+ float: $default-float;
44
+ margin-#{$opposite-direction}: 10px;
45
+ }
46
+ }
47
+
48
+ .clearing-blackout {
49
+ background: $clearing-bg;
50
+ position: fixed;
51
+ width: 100%;
52
+ height: 100%;
53
+ top: 0;
54
+ #{$default-float}: 0;
55
+ z-index: 998;
56
+
57
+ .clearing-close { display: block; }
58
+ }
59
+
60
+ .clearing-container {
61
+ position: relative;
62
+ z-index: 998;
63
+ height: 100%;
64
+ overflow: hidden;
65
+ margin: 0;
66
+ }
67
+
68
+ .visible-img {
69
+ height: 95%;
70
+ position: relative;
71
+
72
+ img {
73
+ position: absolute;
74
+ #{$default-float}: 50%;
75
+ top: 50%;
76
+ margin-#{$default-float}: -50%;
77
+ max-height: 100%;
78
+ max-width: 100%;
79
+ }
80
+ }
81
+
82
+ .clearing-caption {
83
+ color: $clearing-caption-font-color;
84
+ line-height: 1.3;
85
+ margin-bottom: 0;
86
+ text-align: center;
87
+ bottom: 0;
88
+ background: $clearing-caption-bg;
89
+ width: 100%;
90
+ padding: $clearing-caption-padding;
91
+ position: absolute;
92
+ #{$default-float}: 0;
93
+ }
94
+
95
+ .clearing-close {
96
+ z-index: 999;
97
+ padding-#{$default-float}: 20px;
98
+ padding-top: 10px;
99
+ font-size: $clearing-close-size;
100
+ line-height: 1;
101
+ color: $clearing-close-color;
102
+ display: none;
103
+
104
+ &:hover,
105
+ &:focus { color: #ccc; }
106
+ }
107
+
108
+ .clearing-assembled .clearing-container { height: 100%;
109
+ .carousel > ul { display: none; }
110
+ }
111
+
112
+ // If you want to show a lightbox, but only have a single image come through as the thumbnail
113
+ .clearing-feature li {
114
+ display: none;
115
+ &.clearing-featured-img {
116
+ display: block;
117
+ }
118
+ }
119
+
120
+ // Large screen overrides
121
+ @media #{$small} {
122
+ .clearing-main-prev,
123
+ .clearing-main-next {
124
+ position: absolute;
125
+ height: 100%;
126
+ width: 40px;
127
+ top: 0;
128
+ & > span {
129
+ position: absolute;
130
+ top: 50%;
131
+ display: block;
132
+ width: 0;
133
+ height: 0;
134
+ border: solid $clearing-arrow-size;
135
+ }
136
+ }
137
+ .clearing-main-prev {
138
+ #{$default-float}: 0;
139
+ & > span {
140
+ #{$default-float}: 5px;
141
+ border-color: transparent;
142
+ border-#{$opposite-direction}-color: $clearing-arrow-color;
143
+ }
144
+ }
145
+ .clearing-main-next {
146
+ #{$opposite-direction}: 0;
147
+ & > span {
148
+ border-color: transparent;
149
+ border-#{$default-float}-color: $clearing-arrow-color;
150
+ }
151
+ }
152
+
153
+ .clearing-main-prev.disabled,
154
+ .clearing-main-next.disabled { opacity: 0.5; }
155
+
156
+ .clearing-assembled .clearing-container {
157
+
158
+ .carousel {
159
+ background: $clearing-carousel-bg;
160
+ height: $clearing-carousel-height;
161
+ margin-top: 5px;
162
+
163
+ & > ul {
164
+ display: block;
165
+ z-index: 999;
166
+ width: 200%;
167
+ height: 100%;
168
+ margin-#{$default-float}: 0;
169
+ position: relative;
170
+ #{$default-float}: 0;
171
+
172
+ li {
173
+ display: block;
174
+ width: $clearing-carousel-thumb-width;
175
+ height: inherit;
176
+ padding: 0;
177
+ float: $default-float;
178
+ overflow: hidden;
179
+ margin-#{$opposite-direction}: 1px;
180
+ position: relative;
181
+ cursor: $cursor-pointer-value;
182
+ opacity: 0.4;
183
+
184
+ &.fix-height {
185
+ img {
186
+ min-height: 100%;
187
+ height: 100%;
188
+ max-width: none;
189
+ }
190
+ }
191
+
192
+ a.th {
193
+ border: none;
194
+ @if $experimental {
195
+ -webkit-box-shadow: none;
196
+ }
197
+ box-shadow: none;
198
+ display: block;
199
+ }
200
+
201
+ img {
202
+ cursor: $cursor-pointer-value !important;
203
+ min-width: 100% !important;
204
+ }
205
+
206
+ &.visible { opacity: 1; }
207
+ }
208
+ }
209
+ }
210
+
211
+ .visible-img {
212
+ background: $clearing-img-bg;
213
+ overflow: hidden;
214
+ height: $clearing-active-img-height;
215
+ }
216
+ }
217
+
218
+ .clearing-close {
219
+ position: absolute;
220
+ top: 10px;
221
+ #{$opposite-direction}: 20px;
222
+ padding-#{$default-float}: 0;
223
+ padding-top: 0;
224
+ }
225
+ }
226
+
227
+ }
@@ -0,0 +1,278 @@
1
+ //
2
+ // Custom Form Variables
3
+ //
4
+ $include-html-custom-form-classes: $include-html-classes !default;
5
+
6
+ // We use these to control the basic form styles input styles
7
+ $custom-form-border-color: #ccc !default;
8
+ $custom-form-border-size: 1px !default;
9
+ $custom-form-bg: #fff !default;
10
+ $custom-form-bg-disabled: #ddd !default;
11
+ $custom-form-input-size: 16px !default;
12
+ $custom-form-check-color: #222 !default;
13
+ $custom-form-check-size: 16px !default;
14
+ $custom-form-radio-size: 8px !default;
15
+ $custom-form-checkbox-radius: 0 !default;
16
+
17
+ // We use these to style the custom select form element.
18
+ $custom-select-bg: #fff !default;
19
+ $custom-select-fade-to-color: #f3f3f3 !default;
20
+ $custom-select-border-color: #ddd !default;
21
+ $custom-select-triangle-color: #aaa !default;
22
+ $custom-select-triangle-color-open: #222 !default;
23
+ $custom-select-height: em-calc(13) + ($form-spacing * 1.5) !default;
24
+ $custom-select-margin-bottom: em-calc(20) !default;
25
+ $custom-select-font-color-selected: #141414 !default;
26
+ $custom-select-disabled-color: #888 !default;
27
+
28
+ // We use these to control the style of the custom select dropdown element.
29
+ $custom-dropdown-height: 200px !default;
30
+ $custom-dropdown-bg: #fff !default;
31
+ $custom-dropdown-border-color: darken(#fff, 20%) !default;
32
+ $custom-dropdown-border-width: 1px !default;
33
+ $custom-dropdown-border-style: solid !default;
34
+ $custom-dropdown-font-color: #555 !default;
35
+ $custom-dropdown-font-size: em-calc(14) !default;
36
+ $custom-dropdown-color-selected: #eeeeee !default;
37
+ $custom-dropdown-font-color-selected: #000 !default;
38
+ $custom-dropdown-shadow: 0 2px 2px 0 rgba(0,0,0,0.1) !default;
39
+ $custom-dropdown-offset-top: auto !default;
40
+ $custom-dropdown-list-padding: em-calc(4) !default;
41
+ $custom-dropdown-default-float-padding: em-calc(6) !default;
42
+ $custom-dropdown-opposite-padding: em-calc(38) !default;
43
+ $custom-dropdown-list-item-min-height: em-calc(24) !default;
44
+ $custom-dropdown-width-small: 134px !default;
45
+ $custom-dropdown-width-medium: 254px !default;
46
+ $custom-dropdown-width-large: 434px !default;
47
+
48
+ // We decided not to make a mixin for the custom forms because
49
+ // they rely on a very specific class naming structure.
50
+ // We may look at updating this in the future.
51
+ @mixin custom-form-input($radius:0px, $mark-size:0px) {
52
+ @include radius($radius);
53
+ $custom-form-input-padding: (($custom-form-input-size - $mark-size) / 2) - $custom-form-border-size;
54
+ @if $custom-form-input-padding >= 0 {
55
+ padding: $custom-form-input-padding;
56
+ } @else {
57
+ padding: 0;
58
+ }
59
+ }
60
+
61
+ // Only include these classes if the variable is true, otherwise they'll be left out.
62
+ @if $include-html-custom-form-classes != false {
63
+
64
+ /* Custom Checkbox and Radio Inputs */
65
+ form.custom {
66
+
67
+ .hidden-field {
68
+ margin-#{$default-float}: -99999px;
69
+ position: absolute;
70
+ visibility: hidden;
71
+ }
72
+
73
+ .custom {
74
+ display: inline-block;
75
+ width: $custom-form-input-size;
76
+ height: $custom-form-input-size;
77
+ position: relative;
78
+ top:-1px; /* fix centering issue */
79
+ vertical-align: middle;
80
+ border: solid $custom-form-border-size $custom-form-border-color;
81
+ background: $custom-form-bg;
82
+
83
+ &.checkbox {
84
+ @include custom-form-input($radius:$custom-form-checkbox-radius, $mark-size:$custom-form-check-size);
85
+ }
86
+
87
+ &.radio {
88
+ @include custom-form-input($radius:1000px, $mark-size:$custom-form-radio-size);
89
+ }
90
+
91
+ &.checkbox {
92
+ &:before {
93
+ content: "";
94
+ display: block;
95
+ font-size: $custom-form-check-size;
96
+ color: $custom-form-bg;
97
+ }
98
+ }
99
+
100
+ &.radio.checked {
101
+ &:before {
102
+ content: "";
103
+ display: block;
104
+ width: $custom-form-radio-size;
105
+ height: $custom-form-radio-size;
106
+ @include radius(1000px);
107
+ background: $custom-form-check-color;
108
+ position: relative;
109
+ }
110
+ }
111
+
112
+ &.checkbox.checked {
113
+ &:before {
114
+ content: "\00d7";
115
+ color: $custom-form-check-color;
116
+ position: absolute;
117
+ top: -50%;
118
+ left: 50%;
119
+ margin-top: 4px;
120
+ margin-left: -5px;
121
+ }
122
+ }
123
+ }
124
+ }
125
+
126
+ /* Custom Select Options and Dropdowns */
127
+ form.custom {
128
+ .custom.dropdown {
129
+ display: block;
130
+ position: relative;
131
+ top: 0;
132
+ height: $custom-select-height;
133
+ margin-bottom: $custom-select-margin-bottom;
134
+ margin-top: 0;
135
+ padding: 0;
136
+ width: 100%;
137
+ background: $custom-dropdown-bg;
138
+ @if $experimental {
139
+ background: -moz-linear-gradient(top, $custom-dropdown-bg 0%, $custom-select-fade-to-color 100%);
140
+ background: -webkit-linear-gradient(top, $custom-dropdown-bg 0%,$custom-select-fade-to-color 100%);
141
+ -webkit-box-shadow: none;
142
+ }
143
+ background: linear-gradient(to bottom, $custom-dropdown-bg 0%,$custom-select-fade-to-color 100%);
144
+ box-shadow: none;
145
+ font-size: $custom-dropdown-font-size;
146
+ vertical-align: top;
147
+
148
+ ul {
149
+ overflow-y: auto;
150
+ max-height: $custom-dropdown-height;
151
+ }
152
+
153
+ .current {
154
+ cursor:default;
155
+ white-space: nowrap;
156
+ line-height: $custom-select-height - em-calc(1);
157
+ color: $input-font-color;
158
+ text-decoration: none;
159
+ overflow: hidden;
160
+ display: block;
161
+ margin-#{$default-float}: $form-spacing / 2;
162
+ margin-#{$opposite-direction}: $custom-select-height;
163
+ }
164
+
165
+ .selector {
166
+ cursor:default;
167
+ position: absolute;
168
+ width: $form-spacing * 2.5;
169
+ height: $custom-select-height;
170
+ display: block;
171
+ #{$opposite-direction}: 0;
172
+ top: 0;
173
+ &:after {
174
+ content: "";
175
+ display: block;
176
+ @include css-triangle(5px, $custom-select-triangle-color, top);
177
+ position: absolute;
178
+ #{$default-float}: ($form-spacing * 2.5) / 2 - em-calc(5);
179
+ top: 50%;
180
+ margin-top: -3px;
181
+ }
182
+ }
183
+
184
+ &:hover, &.open {
185
+ a.selector {
186
+ &:after { @include css-triangle(5px, $custom-select-triangle-color-open, top); }
187
+ }
188
+ }
189
+
190
+ .disabled {
191
+ color: $custom-select-disabled-color;
192
+ &:hover {
193
+ background: transparent;
194
+ color: $custom-select-disabled-color;
195
+ &:after { display: none; }
196
+ }
197
+ }
198
+
199
+ &.open ul {
200
+ display: block;
201
+ z-index: 10;
202
+ min-width:100%;
203
+ @include box-sizing(content-box);
204
+ }
205
+
206
+ &.small { max-width: $custom-dropdown-width-small; }
207
+ &.medium { max-width: $custom-dropdown-width-medium; }
208
+ &.large { max-width: $custom-dropdown-width-large; }
209
+ &.expand { width: 100% !important; }
210
+
211
+ &.open.small ul { min-width: $custom-dropdown-width-small; @include box-sizing(border-box); }
212
+ &.open.medium ul { min-width: $custom-dropdown-width-medium; @include box-sizing(border-box); }
213
+ &.open.large ul { min-width: $custom-dropdown-width-large; @include box-sizing(border-box); }
214
+ }
215
+
216
+ .error .custom.dropdown {
217
+ @include form-error-color;
218
+ background: rgba($alert-color, 0.1);
219
+ margin-bottom: 0;
220
+ }
221
+
222
+ .error .custom.dropdown + small.error {
223
+ margin-top: 0;
224
+ }
225
+
226
+ .custom.dropdown ul {
227
+ position: absolute;
228
+ width: auto;
229
+ display: none;
230
+ margin: 0;
231
+ #{$default-float}: -$input-border-width;
232
+ top: $custom-dropdown-offset-top;
233
+ @if $experimental {
234
+ -webkit-box-shadow: $custom-dropdown-shadow;
235
+ }
236
+ box-shadow: $custom-dropdown-shadow;
237
+ margin: 0;
238
+ padding: 0;
239
+ background: $custom-dropdown-bg;
240
+ border: $custom-dropdown-border-style $custom-dropdown-border-width $custom-dropdown-border-color;
241
+ font-size: $em-base;
242
+
243
+ li {
244
+ color: $custom-dropdown-font-color;
245
+ font-size: $custom-dropdown-font-size;
246
+ cursor: $cursor-default-value;
247
+ padding-top: $custom-dropdown-list-padding;
248
+ padding-bottom: $custom-dropdown-list-padding;
249
+ padding-#{$default-float}: $custom-dropdown-default-float-padding;
250
+ padding-#{$opposite-direction}: $custom-dropdown-opposite-padding;
251
+ min-height: $custom-dropdown-list-item-min-height;
252
+ line-height: $custom-dropdown-list-item-min-height;
253
+ margin: 0;
254
+ white-space: nowrap;
255
+ list-style: none;
256
+
257
+ &.selected {
258
+ background: $custom-dropdown-color-selected;
259
+ color: $custom-dropdown-font-color-selected;
260
+ }
261
+ &:hover {
262
+ background-color: darken($custom-dropdown-color-selected, 4%);
263
+ color: $custom-dropdown-font-color-selected;
264
+ }
265
+ &.selected:hover {
266
+ background: $custom-dropdown-color-selected;
267
+ cursor: $cursor-default-value;
268
+ color: $custom-dropdown-font-color-selected;
269
+ }
270
+ }
271
+
272
+ &.show { display: block; }
273
+ }
274
+
275
+ /* Custom input, disabled */
276
+ .custom.disabled { background: $custom-form-bg-disabled; }
277
+ }
278
+ }
@@ -0,0 +1,115 @@
1
+ //
2
+ // Dropdown Button Variables
3
+ //
4
+ $include-html-button-classes: $include-html-classes !default;
5
+
6
+ // We use these to set the color of the pip in dropdown buttons
7
+ $dropdown-button-pip-color: #fff !default;
8
+ $dropdown-button-pip-color-alt: #333 !default;
9
+
10
+ // We use these to style tiny dropdown buttons
11
+ $dropdown-button-padding-tny: $button-tny * 5 !default;
12
+ $dropdown-button-pip-size-tny: $button-tny !default;
13
+ $dropdown-button-pip-opposite-tny: $button-tny * 2 !default;
14
+ $dropdown-button-pip-top-tny: -$button-tny / 2 + em-calc(1) !default;
15
+
16
+ // We use these to style small dropdown buttons
17
+ $dropdown-button-padding-sml: $button-sml * 5 !default;
18
+ $dropdown-button-pip-size-sml: $button-sml !default;
19
+ $dropdown-button-pip-opposite-sml: $button-sml * 2 !default;
20
+ $dropdown-button-pip-top-sml: -$button-sml / 2 + em-calc(1) !default;
21
+
22
+ // We use these to style medium dropdown buttons
23
+ $dropdown-button-padding-med: $button-med * 4 + em-calc(3) !default;
24
+ $dropdown-button-pip-size-med: $button-med - em-calc(3) !default;
25
+ $dropdown-button-pip-opposite-med: $button-med * 2 !default;
26
+ $dropdown-button-pip-top-med: -$button-med / 2 + em-calc(2) !default;
27
+
28
+ // We use these to style large dropdown buttons
29
+ $dropdown-button-padding-lrg: $button-lrg * 4 !default;
30
+ $dropdown-button-pip-size-lrg: $button-lrg - em-calc(6) !default;
31
+ $dropdown-button-pip-opposite-lrg: $button-lrg + em-calc(12) !default;
32
+ $dropdown-button-pip-top-lrg: -$button-lrg / 2 + em-calc(3) !default;
33
+
34
+ //
35
+ // Dropdown Button Mixin
36
+ //
37
+
38
+ // We use this mixin to build off of the button mixin and add dropdown button styles
39
+ @mixin dropdown-button($padding:medium, $pip-color:#fff, $base-style:true) {
40
+
41
+ // We add in base styles, but they can be negated by setting to 'false'.
42
+ @if $base-style {
43
+ position: relative;
44
+
45
+ // This creates the base styles for the triangle pip
46
+ &:before {
47
+ position: absolute;
48
+ content: "";
49
+ width: 0;
50
+ height: 0;
51
+ display: block;
52
+ border-style: solid;
53
+ border-color: $dropdown-button-pip-color transparent transparent transparent;
54
+ top: 50%;
55
+ }
56
+ }
57
+
58
+ // If we're dealing with tiny buttons, use these styles
59
+ @if $padding == tiny {
60
+ padding-#{$opposite-direction}: $dropdown-button-padding-tny;
61
+ &:before {
62
+ border-width: $dropdown-button-pip-size-tny;
63
+ #{$opposite-direction}: $dropdown-button-pip-opposite-tny;
64
+ margin-top: $dropdown-button-pip-top-tny;
65
+ }
66
+ }
67
+
68
+ // If we're dealing with small buttons, use these styles
69
+ @if $padding == small {
70
+ padding-#{$opposite-direction}: $dropdown-button-padding-sml;
71
+ &:before {
72
+ border-width: $dropdown-button-pip-size-sml;
73
+ #{$opposite-direction}: $dropdown-button-pip-opposite-sml;
74
+ margin-top: $dropdown-button-pip-top-sml;
75
+ }
76
+ }
77
+
78
+ // If we're dealing with default (medium) buttons, use these styles
79
+ @if $padding == medium {
80
+ padding-#{$opposite-direction}: $dropdown-button-padding-med;
81
+ &:before {
82
+ border-width: $dropdown-button-pip-size-med;
83
+ #{$opposite-direction}: $dropdown-button-pip-opposite-med;
84
+ margin-top: $dropdown-button-pip-top-med;
85
+ }
86
+ }
87
+
88
+ // If we're dealing with large buttons, use these styles
89
+ @if $padding == large {
90
+ padding-#{$opposite-direction}: $dropdown-button-padding-lrg;
91
+ &:before {
92
+ border-width: $dropdown-button-pip-size-lrg;
93
+ #{$opposite-direction}: $dropdown-button-pip-opposite-lrg;
94
+ margin-top: $dropdown-button-pip-top-lrg;
95
+ }
96
+ }
97
+
98
+ // We can control the pip color. We didn't use logic in this case, just set it and forget it.
99
+ @if $pip-color {
100
+ &:before { border-color: $pip-color transparent transparent transparent; }
101
+ }
102
+ }
103
+
104
+
105
+ @if $include-html-button-classes {
106
+
107
+ /* Dropdown Button */
108
+ .dropdown.button { @include dropdown-button;
109
+ &.tiny { @include dropdown-button(tiny,$base-style:false); }
110
+ &.small { @include dropdown-button(small,$base-style:false); }
111
+ &.large { @include dropdown-button(large,$base-style:false); }
112
+ &.secondary:before { border-color: $dropdown-button-pip-color-alt transparent transparent transparent; }
113
+ }
114
+
115
+ }