va_common 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (285) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +9 -0
  3. data/.travis.yml +4 -0
  4. data/CODE_OF_CONDUCT.md +13 -0
  5. data/Gemfile +4 -0
  6. data/README.md +66 -0
  7. data/Rakefile +1 -0
  8. data/app/assets/fonts/merriweather-bold-webfont.eot +0 -0
  9. data/app/assets/fonts/merriweather-bold-webfont.svg +294 -0
  10. data/app/assets/fonts/merriweather-bold-webfont.ttf +0 -0
  11. data/app/assets/fonts/merriweather-bold-webfont.woff +0 -0
  12. data/app/assets/fonts/merriweather-bold-webfont.woff2 +0 -0
  13. data/app/assets/fonts/merriweather-italic-webfont.eot +0 -0
  14. data/app/assets/fonts/merriweather-italic-webfont.svg +283 -0
  15. data/app/assets/fonts/merriweather-italic-webfont.ttf +0 -0
  16. data/app/assets/fonts/merriweather-italic-webfont.woff +0 -0
  17. data/app/assets/fonts/merriweather-italic-webfont.woff2 +0 -0
  18. data/app/assets/fonts/merriweather-light-webfont.eot +0 -0
  19. data/app/assets/fonts/merriweather-light-webfont.svg +299 -0
  20. data/app/assets/fonts/merriweather-light-webfont.ttf +0 -0
  21. data/app/assets/fonts/merriweather-light-webfont.woff +0 -0
  22. data/app/assets/fonts/merriweather-light-webfont.woff2 +0 -0
  23. data/app/assets/fonts/merriweather-regular-webfont.eot +0 -0
  24. data/app/assets/fonts/merriweather-regular-webfont.svg +294 -0
  25. data/app/assets/fonts/merriweather-regular-webfont.ttf +0 -0
  26. data/app/assets/fonts/merriweather-regular-webfont.woff +0 -0
  27. data/app/assets/fonts/merriweather-regular-webfont.woff2 +0 -0
  28. data/app/assets/fonts/sourcesanspro-bold-webfont.eot +0 -0
  29. data/app/assets/fonts/sourcesanspro-bold-webfont.svg +965 -0
  30. data/app/assets/fonts/sourcesanspro-bold-webfont.ttf +0 -0
  31. data/app/assets/fonts/sourcesanspro-bold-webfont.woff +0 -0
  32. data/app/assets/fonts/sourcesanspro-bold-webfont.woff2 +0 -0
  33. data/app/assets/fonts/sourcesanspro-italic-webfont.eot +0 -0
  34. data/app/assets/fonts/sourcesanspro-italic-webfont.svg +853 -0
  35. data/app/assets/fonts/sourcesanspro-italic-webfont.ttf +0 -0
  36. data/app/assets/fonts/sourcesanspro-italic-webfont.woff +0 -0
  37. data/app/assets/fonts/sourcesanspro-italic-webfont.woff2 +0 -0
  38. data/app/assets/fonts/sourcesanspro-light-webfont.eot +0 -0
  39. data/app/assets/fonts/sourcesanspro-light-webfont.svg +915 -0
  40. data/app/assets/fonts/sourcesanspro-light-webfont.ttf +0 -0
  41. data/app/assets/fonts/sourcesanspro-light-webfont.woff +0 -0
  42. data/app/assets/fonts/sourcesanspro-light-webfont.woff2 +0 -0
  43. data/app/assets/fonts/sourcesanspro-regular-webfont.eot +0 -0
  44. data/app/assets/fonts/sourcesanspro-regular-webfont.svg +989 -0
  45. data/app/assets/fonts/sourcesanspro-regular-webfont.ttf +0 -0
  46. data/app/assets/fonts/sourcesanspro-regular-webfont.woff +0 -0
  47. data/app/assets/fonts/sourcesanspro-regular-webfont.woff2 +0 -0
  48. data/app/assets/images/design/background/thread.png +0 -0
  49. data/app/assets/images/design/logo/logo-alt-hover.png +0 -0
  50. data/app/assets/images/design/logo/logo-alt.png +0 -0
  51. data/app/assets/images/design/logo/logo-hover.png +0 -0
  52. data/app/assets/images/design/logo/logo-small.png +0 -0
  53. data/app/assets/images/design/logo/logo.png +0 -0
  54. data/app/assets/images/design/logo/og-image.jpg +0 -0
  55. data/app/assets/images/design/seal/seal-footer.png +0 -0
  56. data/app/assets/images/design/seal/seal-footer.svg +1 -0
  57. data/app/assets/images/design/seal/seal.png +0 -0
  58. data/app/assets/images/design/seal/stars.png +0 -0
  59. data/app/assets/images/icons/apple-touch-icon-114x114.png +0 -0
  60. data/app/assets/images/icons/apple-touch-icon-152x152.png +0 -0
  61. data/app/assets/images/icons/apple-touch-icon-72x72.png +0 -0
  62. data/app/assets/images/icons/apple-touch-icon.png +0 -0
  63. data/app/assets/images/icons/favicon.ico +0 -0
  64. data/app/assets/images/icons/va.png +0 -0
  65. data/app/assets/images/icons/watermark.png +0 -0
  66. data/app/assets/images/icons/wrench.png +0 -0
  67. data/app/assets/images/social-icons/png/facebook25.png +0 -0
  68. data/app/assets/images/social-icons/png/rss25.png +0 -0
  69. data/app/assets/images/social-icons/png/twitter16.png +0 -0
  70. data/app/assets/images/social-icons/png/youtube15.png +0 -0
  71. data/app/assets/images/social-icons/svg/facebook25.svg +11 -0
  72. data/app/assets/images/social-icons/svg/rss25.svg +1 -0
  73. data/app/assets/images/social-icons/svg/twitter16.svg +15 -0
  74. data/app/assets/images/social-icons/svg/youtube15.svg +1 -0
  75. data/app/assets/js/components.js +376 -0
  76. data/app/assets/js/foundation/foundation.abide.js +408 -0
  77. data/app/assets/js/foundation/foundation.accordion.js +88 -0
  78. data/app/assets/js/foundation/foundation.alert.js +43 -0
  79. data/app/assets/js/foundation/foundation.clearing.js +586 -0
  80. data/app/assets/js/foundation/foundation.dropdown.js +463 -0
  81. data/app/assets/js/foundation/foundation.equalizer.js +104 -0
  82. data/app/assets/js/foundation/foundation.interchange.js +359 -0
  83. data/app/assets/js/foundation/foundation.joyride.js +932 -0
  84. data/app/assets/js/foundation/foundation.js +725 -0
  85. data/app/assets/js/foundation/foundation.magellan.js +215 -0
  86. data/app/assets/js/foundation/foundation.offcanvas.js +152 -0
  87. data/app/assets/js/foundation/foundation.orbit.js +476 -0
  88. data/app/assets/js/foundation/foundation.reveal.js +498 -0
  89. data/app/assets/js/foundation/foundation.slider.js +281 -0
  90. data/app/assets/js/foundation/foundation.tab.js +249 -0
  91. data/app/assets/js/foundation/foundation.tooltip.js +339 -0
  92. data/app/assets/js/foundation/foundation.topbar.js +458 -0
  93. data/app/assets/js/foundation.min.js +6376 -0
  94. data/app/assets/js/scripts-no-touch.js +33 -0
  95. data/app/assets/js/scripts-touch.js +33 -0
  96. data/app/assets/js/va_common_main.js +1 -0
  97. data/app/assets/js/vendor/classie.js +80 -0
  98. data/app/assets/js/vendor/html5shiv.js +8 -0
  99. data/app/assets/js/vendor/jquery-1.11.0.min.js +4 -0
  100. data/app/assets/js/vendor/jquery.js +9789 -0
  101. data/app/assets/js/vendor/jquery.smooth-scroll.js +255 -0
  102. data/app/assets/js/vendor/jquery.stellar.js +651 -0
  103. data/app/assets/js/vendor/jquery.tipsy.js +258 -0
  104. data/app/assets/js/vendor/menu.js +40 -0
  105. data/app/assets/js/vendor/modernizr.custom.js +4 -0
  106. data/app/assets/js/vendor/nwmatcher-1.2.5-min.js +7 -0
  107. data/app/assets/js/vendor/respond.min.js +6 -0
  108. data/app/assets/js/vendor/scroll-settings.js +3 -0
  109. data/app/assets/js/vendor/selectivizr-1.0.3b.js +560 -0
  110. data/app/assets/js/vendor/stellar-settings.js +8 -0
  111. data/app/assets/js/vendor/svg-injector.js +450 -0
  112. data/app/assets/js/vendor/tota11y.min.js +28 -0
  113. data/app/assets/js/vendor/wow.min.js +2 -0
  114. data/app/assets/stylesheets/_va.scss +2377 -0
  115. data/app/assets/stylesheets/components/_accordions.scss +98 -0
  116. data/app/assets/stylesheets/core/_base.scss +20 -0
  117. data/app/assets/stylesheets/core/_defaults.scss +92 -0
  118. data/app/assets/stylesheets/core/_grid-settings.scss +10 -0
  119. data/app/assets/stylesheets/core/_grid.scss +116 -0
  120. data/app/assets/stylesheets/core/_utilities.scss +105 -0
  121. data/app/assets/stylesheets/core/_variables.scss +88 -0
  122. data/app/assets/stylesheets/elements/_buttons.scss +189 -0
  123. data/app/assets/stylesheets/elements/_figure.scss +9 -0
  124. data/app/assets/stylesheets/elements/_inputs.scss +328 -0
  125. data/app/assets/stylesheets/elements/_labels.scss +39 -0
  126. data/app/assets/stylesheets/elements/_list.scss +82 -0
  127. data/app/assets/stylesheets/elements/_table.scss +39 -0
  128. data/app/assets/stylesheets/elements/_typography.scss +220 -0
  129. data/app/assets/stylesheets/foundation/_functions.scss +146 -0
  130. data/app/assets/stylesheets/foundation/_settings.scss +1467 -0
  131. data/app/assets/stylesheets/foundation/_variables.scss +1286 -0
  132. data/app/assets/stylesheets/foundation/components/_accordion.scss +157 -0
  133. data/app/assets/stylesheets/foundation/components/_alert-boxes.scss +128 -0
  134. data/app/assets/stylesheets/foundation/components/_block-grid.scss +132 -0
  135. data/app/assets/stylesheets/foundation/components/_breadcrumbs.scss +132 -0
  136. data/app/assets/stylesheets/foundation/components/_button-groups.scss +200 -0
  137. data/app/assets/stylesheets/foundation/components/_buttons.scss +259 -0
  138. data/app/assets/stylesheets/foundation/components/_clearing.scss +256 -0
  139. data/app/assets/stylesheets/foundation/components/_dropdown-buttons.scss +131 -0
  140. data/app/assets/stylesheets/foundation/components/_dropdown.scss +262 -0
  141. data/app/assets/stylesheets/foundation/components/_flex-video.scss +51 -0
  142. data/app/assets/stylesheets/foundation/components/_forms.scss +570 -0
  143. data/app/assets/stylesheets/foundation/components/_global.scss +481 -0
  144. data/app/assets/stylesheets/foundation/components/_grid.scss +289 -0
  145. data/app/assets/stylesheets/foundation/components/_icon-bar.scss +358 -0
  146. data/app/assets/stylesheets/foundation/components/_inline-lists.scss +57 -0
  147. data/app/assets/stylesheets/foundation/components/_joyride.scss +222 -0
  148. data/app/assets/stylesheets/foundation/components/_keystrokes.scss +61 -0
  149. data/app/assets/stylesheets/foundation/components/_labels.scss +106 -0
  150. data/app/assets/stylesheets/foundation/components/_magellan.scss +34 -0
  151. data/app/assets/stylesheets/foundation/components/_offcanvas.scss +515 -0
  152. data/app/assets/stylesheets/foundation/components/_orbit.scss +368 -0
  153. data/app/assets/stylesheets/foundation/components/_pagination.scss +162 -0
  154. data/app/assets/stylesheets/foundation/components/_panels.scss +101 -0
  155. data/app/assets/stylesheets/foundation/components/_pricing-tables.scss +150 -0
  156. data/app/assets/stylesheets/foundation/components/_progress-bars.scss +79 -0
  157. data/app/assets/stylesheets/foundation/components/_range-slider.scss +169 -0
  158. data/app/assets/stylesheets/foundation/components/_reveal.scss +202 -0
  159. data/app/assets/stylesheets/foundation/components/_side-nav.scss +116 -0
  160. data/app/assets/stylesheets/foundation/components/_split-buttons.scss +199 -0
  161. data/app/assets/stylesheets/foundation/components/_sub-nav.scss +123 -0
  162. data/app/assets/stylesheets/foundation/components/_switches.scss +238 -0
  163. data/app/assets/stylesheets/foundation/components/_tables.scss +135 -0
  164. data/app/assets/stylesheets/foundation/components/_tabs.scss +123 -0
  165. data/app/assets/stylesheets/foundation/components/_thumbs.scss +66 -0
  166. data/app/assets/stylesheets/foundation/components/_toolbar.scss +70 -0
  167. data/app/assets/stylesheets/foundation/components/_tooltips.scss +142 -0
  168. data/app/assets/stylesheets/foundation/components/_top-bar.scss +691 -0
  169. data/app/assets/stylesheets/foundation/components/_type.scss +525 -0
  170. data/app/assets/stylesheets/foundation/components/_visibility.scss +408 -0
  171. data/app/assets/stylesheets/functions/_new-breakpoint.scss +49 -0
  172. data/app/assets/stylesheets/functions/_private.scss +114 -0
  173. data/app/assets/stylesheets/lib/_normalize.scss +427 -0
  174. data/app/assets/stylesheets/lib/bourbon/_bourbon-deprecated-upcoming.scss +411 -0
  175. data/app/assets/stylesheets/lib/bourbon/_bourbon.scss +87 -0
  176. data/app/assets/stylesheets/lib/bourbon/addons/_border-color.scss +26 -0
  177. data/app/assets/stylesheets/lib/bourbon/addons/_border-radius.scss +48 -0
  178. data/app/assets/stylesheets/lib/bourbon/addons/_border-style.scss +25 -0
  179. data/app/assets/stylesheets/lib/bourbon/addons/_border-width.scss +25 -0
  180. data/app/assets/stylesheets/lib/bourbon/addons/_buttons.scss +64 -0
  181. data/app/assets/stylesheets/lib/bourbon/addons/_clearfix.scss +25 -0
  182. data/app/assets/stylesheets/lib/bourbon/addons/_ellipsis.scss +30 -0
  183. data/app/assets/stylesheets/lib/bourbon/addons/_font-stacks.scss +31 -0
  184. data/app/assets/stylesheets/lib/bourbon/addons/_hide-text.scss +27 -0
  185. data/app/assets/stylesheets/lib/bourbon/addons/_margin.scss +26 -0
  186. data/app/assets/stylesheets/lib/bourbon/addons/_padding.scss +26 -0
  187. data/app/assets/stylesheets/lib/bourbon/addons/_position.scss +48 -0
  188. data/app/assets/stylesheets/lib/bourbon/addons/_prefixer.scss +66 -0
  189. data/app/assets/stylesheets/lib/bourbon/addons/_retina-image.scss +25 -0
  190. data/app/assets/stylesheets/lib/bourbon/addons/_size.scss +51 -0
  191. data/app/assets/stylesheets/lib/bourbon/addons/_text-inputs.scss +112 -0
  192. data/app/assets/stylesheets/lib/bourbon/addons/_timing-functions.scss +34 -0
  193. data/app/assets/stylesheets/lib/bourbon/addons/_triangle.scss +63 -0
  194. data/app/assets/stylesheets/lib/bourbon/addons/_word-wrap.scss +29 -0
  195. data/app/assets/stylesheets/lib/bourbon/css3/_animation.scss +43 -0
  196. data/app/assets/stylesheets/lib/bourbon/css3/_appearance.scss +3 -0
  197. data/app/assets/stylesheets/lib/bourbon/css3/_backface-visibility.scss +3 -0
  198. data/app/assets/stylesheets/lib/bourbon/css3/_background-image.scss +42 -0
  199. data/app/assets/stylesheets/lib/bourbon/css3/_background.scss +55 -0
  200. data/app/assets/stylesheets/lib/bourbon/css3/_border-image.scss +59 -0
  201. data/app/assets/stylesheets/lib/bourbon/css3/_calc.scss +4 -0
  202. data/app/assets/stylesheets/lib/bourbon/css3/_columns.scss +47 -0
  203. data/app/assets/stylesheets/lib/bourbon/css3/_filter.scss +4 -0
  204. data/app/assets/stylesheets/lib/bourbon/css3/_flex-box.scss +287 -0
  205. data/app/assets/stylesheets/lib/bourbon/css3/_font-face.scss +24 -0
  206. data/app/assets/stylesheets/lib/bourbon/css3/_font-feature-settings.scss +4 -0
  207. data/app/assets/stylesheets/lib/bourbon/css3/_hidpi-media-query.scss +10 -0
  208. data/app/assets/stylesheets/lib/bourbon/css3/_hyphens.scss +4 -0
  209. data/app/assets/stylesheets/lib/bourbon/css3/_image-rendering.scss +14 -0
  210. data/app/assets/stylesheets/lib/bourbon/css3/_keyframes.scss +36 -0
  211. data/app/assets/stylesheets/lib/bourbon/css3/_linear-gradient.scss +38 -0
  212. data/app/assets/stylesheets/lib/bourbon/css3/_perspective.scss +8 -0
  213. data/app/assets/stylesheets/lib/bourbon/css3/_placeholder.scss +8 -0
  214. data/app/assets/stylesheets/lib/bourbon/css3/_radial-gradient.scss +39 -0
  215. data/app/assets/stylesheets/lib/bourbon/css3/_selection.scss +42 -0
  216. data/app/assets/stylesheets/lib/bourbon/css3/_text-decoration.scss +19 -0
  217. data/app/assets/stylesheets/lib/bourbon/css3/_transform.scss +15 -0
  218. data/app/assets/stylesheets/lib/bourbon/css3/_transition.scss +71 -0
  219. data/app/assets/stylesheets/lib/bourbon/css3/_user-select.scss +3 -0
  220. data/app/assets/stylesheets/lib/bourbon/functions/_assign-inputs.scss +11 -0
  221. data/app/assets/stylesheets/lib/bourbon/functions/_contains-falsy.scss +20 -0
  222. data/app/assets/stylesheets/lib/bourbon/functions/_contains.scss +26 -0
  223. data/app/assets/stylesheets/lib/bourbon/functions/_is-length.scss +11 -0
  224. data/app/assets/stylesheets/lib/bourbon/functions/_is-light.scss +21 -0
  225. data/app/assets/stylesheets/lib/bourbon/functions/_is-number.scss +11 -0
  226. data/app/assets/stylesheets/lib/bourbon/functions/_is-size.scss +13 -0
  227. data/app/assets/stylesheets/lib/bourbon/functions/_modular-scale.scss +69 -0
  228. data/app/assets/stylesheets/lib/bourbon/functions/_px-to-em.scss +13 -0
  229. data/app/assets/stylesheets/lib/bourbon/functions/_px-to-rem.scss +15 -0
  230. data/app/assets/stylesheets/lib/bourbon/functions/_shade.scss +24 -0
  231. data/app/assets/stylesheets/lib/bourbon/functions/_strip-units.scss +17 -0
  232. data/app/assets/stylesheets/lib/bourbon/functions/_tint.scss +24 -0
  233. data/app/assets/stylesheets/lib/bourbon/functions/_transition-property-name.scss +22 -0
  234. data/app/assets/stylesheets/lib/bourbon/functions/_unpack.scss +27 -0
  235. data/app/assets/stylesheets/lib/bourbon/helpers/_convert-units.scss +21 -0
  236. data/app/assets/stylesheets/lib/bourbon/helpers/_directional-values.scss +96 -0
  237. data/app/assets/stylesheets/lib/bourbon/helpers/_font-source-declaration.scss +43 -0
  238. data/app/assets/stylesheets/lib/bourbon/helpers/_gradient-positions-parser.scss +13 -0
  239. data/app/assets/stylesheets/lib/bourbon/helpers/_linear-angle-parser.scss +25 -0
  240. data/app/assets/stylesheets/lib/bourbon/helpers/_linear-gradient-parser.scss +41 -0
  241. data/app/assets/stylesheets/lib/bourbon/helpers/_linear-positions-parser.scss +61 -0
  242. data/app/assets/stylesheets/lib/bourbon/helpers/_linear-side-corner-parser.scss +31 -0
  243. data/app/assets/stylesheets/lib/bourbon/helpers/_radial-arg-parser.scss +69 -0
  244. data/app/assets/stylesheets/lib/bourbon/helpers/_radial-gradient-parser.scss +50 -0
  245. data/app/assets/stylesheets/lib/bourbon/helpers/_radial-positions-parser.scss +18 -0
  246. data/app/assets/stylesheets/lib/bourbon/helpers/_render-gradients.scss +26 -0
  247. data/app/assets/stylesheets/lib/bourbon/helpers/_shape-size-stripper.scss +10 -0
  248. data/app/assets/stylesheets/lib/bourbon/helpers/_str-to-num.scss +50 -0
  249. data/app/assets/stylesheets/lib/bourbon/settings/_asset-pipeline.scss +7 -0
  250. data/app/assets/stylesheets/lib/bourbon/settings/_prefixer.scss +9 -0
  251. data/app/assets/stylesheets/lib/bourbon/settings/_px-to-em.scss +1 -0
  252. data/app/assets/stylesheets/lib/neat/_neat-helpers.scss +8 -0
  253. data/app/assets/stylesheets/lib/neat/_neat.scss +23 -0
  254. data/app/assets/stylesheets/lib/neat/functions/_new-breakpoint.scss +49 -0
  255. data/app/assets/stylesheets/lib/neat/functions/_private.scss +114 -0
  256. data/app/assets/stylesheets/lib/neat/grid/_box-sizing.scss +15 -0
  257. data/app/assets/stylesheets/lib/neat/grid/_direction-context.scss +33 -0
  258. data/app/assets/stylesheets/lib/neat/grid/_display-context.scss +28 -0
  259. data/app/assets/stylesheets/lib/neat/grid/_fill-parent.scss +22 -0
  260. data/app/assets/stylesheets/lib/neat/grid/_media.scss +92 -0
  261. data/app/assets/stylesheets/lib/neat/grid/_omega.scss +87 -0
  262. data/app/assets/stylesheets/lib/neat/grid/_outer-container.scss +38 -0
  263. data/app/assets/stylesheets/lib/neat/grid/_pad.scss +25 -0
  264. data/app/assets/stylesheets/lib/neat/grid/_private.scss +35 -0
  265. data/app/assets/stylesheets/lib/neat/grid/_row.scss +52 -0
  266. data/app/assets/stylesheets/lib/neat/grid/_shift.scss +50 -0
  267. data/app/assets/stylesheets/lib/neat/grid/_span-columns.scss +94 -0
  268. data/app/assets/stylesheets/lib/neat/grid/_to-deprecate.scss +97 -0
  269. data/app/assets/stylesheets/lib/neat/grid/_visual-grid.scss +42 -0
  270. data/app/assets/stylesheets/lib/neat/settings/_disable-warnings.scss +13 -0
  271. data/app/assets/stylesheets/lib/neat/settings/_grid.scss +51 -0
  272. data/app/assets/stylesheets/lib/neat/settings/_visual-grid.scss +27 -0
  273. data/app/assets/stylesheets/va_common_main.css.scss +18 -0
  274. data/bin/console +14 -0
  275. data/bin/setup +7 -0
  276. data/lib/generators/files/_footer.html.erb +89 -0
  277. data/lib/generators/files/_header.html.erb +7 -0
  278. data/lib/generators/va_common_generator.rb +6 -0
  279. data/lib/generators/va_footer_generator.rb +7 -0
  280. data/lib/generators/va_header_generator.rb +7 -0
  281. data/lib/va_common/engine.rb +4 -0
  282. data/lib/va_common/version.rb +3 -0
  283. data/lib/va_common.rb +2 -0
  284. data/va_common.gemspec +22 -0
  285. metadata +354 -0
@@ -0,0 +1,463 @@
1
+ ;(function ($, window, document, undefined) {
2
+ 'use strict';
3
+
4
+ Foundation.libs.dropdown = {
5
+ name : 'dropdown',
6
+
7
+ version : '5.5.2',
8
+
9
+ settings : {
10
+ active_class : 'open',
11
+ disabled_class : 'disabled',
12
+ mega_class : 'mega',
13
+ align : 'bottom',
14
+ is_hover : false,
15
+ hover_timeout : 150,
16
+ opened : function () {},
17
+ closed : function () {}
18
+ },
19
+
20
+ init : function (scope, method, options) {
21
+ Foundation.inherit(this, 'throttle');
22
+
23
+ $.extend(true, this.settings, method, options);
24
+ this.bindings(method, options);
25
+ },
26
+
27
+ events : function (scope) {
28
+ var self = this,
29
+ S = self.S;
30
+
31
+ S(this.scope)
32
+ .off('.dropdown')
33
+ .on('click.fndtn.dropdown', '[' + this.attr_name() + ']', function (e) {
34
+ var settings = S(this).data(self.attr_name(true) + '-init') || self.settings;
35
+ if (!settings.is_hover || Modernizr.touch) {
36
+ e.preventDefault();
37
+ if (S(this).parent('[data-reveal-id]').length) {
38
+ e.stopPropagation();
39
+ }
40
+ self.toggle($(this));
41
+ }
42
+ })
43
+ .on('mouseenter.fndtn.dropdown', '[' + this.attr_name() + '], [' + this.attr_name() + '-content]', function (e) {
44
+ var $this = S(this),
45
+ dropdown,
46
+ target;
47
+
48
+ clearTimeout(self.timeout);
49
+
50
+ if ($this.data(self.data_attr())) {
51
+ dropdown = S('#' + $this.data(self.data_attr()));
52
+ target = $this;
53
+ } else {
54
+ dropdown = $this;
55
+ target = S('[' + self.attr_name() + '="' + dropdown.attr('id') + '"]');
56
+ }
57
+
58
+ var settings = target.data(self.attr_name(true) + '-init') || self.settings;
59
+
60
+ if (S(e.currentTarget).data(self.data_attr()) && settings.is_hover) {
61
+ self.closeall.call(self);
62
+ }
63
+
64
+ if (settings.is_hover) {
65
+ self.open.apply(self, [dropdown, target]);
66
+ }
67
+ })
68
+ .on('mouseleave.fndtn.dropdown', '[' + this.attr_name() + '], [' + this.attr_name() + '-content]', function (e) {
69
+ var $this = S(this);
70
+ var settings;
71
+
72
+ if ($this.data(self.data_attr())) {
73
+ settings = $this.data(self.data_attr(true) + '-init') || self.settings;
74
+ } else {
75
+ var target = S('[' + self.attr_name() + '="' + S(this).attr('id') + '"]'),
76
+ settings = target.data(self.attr_name(true) + '-init') || self.settings;
77
+ }
78
+
79
+ self.timeout = setTimeout(function () {
80
+ if ($this.data(self.data_attr())) {
81
+ if (settings.is_hover) {
82
+ self.close.call(self, S('#' + $this.data(self.data_attr())));
83
+ }
84
+ } else {
85
+ if (settings.is_hover) {
86
+ self.close.call(self, $this);
87
+ }
88
+ }
89
+ }.bind(this), settings.hover_timeout);
90
+ })
91
+ .on('click.fndtn.dropdown', function (e) {
92
+ var parent = S(e.target).closest('[' + self.attr_name() + '-content]');
93
+ var links = parent.find('a');
94
+
95
+ if (links.length > 0 && parent.attr('aria-autoclose') !== 'false') {
96
+ self.close.call(self, S('[' + self.attr_name() + '-content]'));
97
+ }
98
+
99
+ if (e.target !== document && !$.contains(document.documentElement, e.target)) {
100
+ return;
101
+ }
102
+
103
+ if (S(e.target).closest('[' + self.attr_name() + ']').length > 0) {
104
+ return;
105
+ }
106
+
107
+ if (!(S(e.target).data('revealId')) &&
108
+ (parent.length > 0 && (S(e.target).is('[' + self.attr_name() + '-content]') ||
109
+ $.contains(parent.first()[0], e.target)))) {
110
+ e.stopPropagation();
111
+ return;
112
+ }
113
+
114
+ self.close.call(self, S('[' + self.attr_name() + '-content]'));
115
+ })
116
+ .on('opened.fndtn.dropdown', '[' + self.attr_name() + '-content]', function () {
117
+ self.settings.opened.call(this);
118
+ })
119
+ .on('closed.fndtn.dropdown', '[' + self.attr_name() + '-content]', function () {
120
+ self.settings.closed.call(this);
121
+ });
122
+
123
+ S(window)
124
+ .off('.dropdown')
125
+ .on('resize.fndtn.dropdown', self.throttle(function () {
126
+ self.resize.call(self);
127
+ }, 50));
128
+
129
+ this.resize();
130
+ },
131
+
132
+ close : function (dropdown) {
133
+ var self = this;
134
+ dropdown.each(function (idx) {
135
+ var original_target = $('[' + self.attr_name() + '=' + dropdown[idx].id + ']') || $('aria-controls=' + dropdown[idx].id + ']');
136
+ original_target.attr('aria-expanded', 'false');
137
+ if (self.S(this).hasClass(self.settings.active_class)) {
138
+ self.S(this)
139
+ .css(Foundation.rtl ? 'right' : 'left', '-99999px')
140
+ .attr('aria-hidden', 'true')
141
+ .removeClass(self.settings.active_class)
142
+ .prev('[' + self.attr_name() + ']')
143
+ .removeClass(self.settings.active_class)
144
+ .removeData('target');
145
+
146
+ self.S(this).trigger('closed.fndtn.dropdown', [dropdown]);
147
+ }
148
+ });
149
+ dropdown.removeClass('f-open-' + this.attr_name(true));
150
+ },
151
+
152
+ closeall : function () {
153
+ var self = this;
154
+ $.each(self.S('.f-open-' + this.attr_name(true)), function () {
155
+ self.close.call(self, self.S(this));
156
+ });
157
+ },
158
+
159
+ open : function (dropdown, target) {
160
+ this
161
+ .css(dropdown
162
+ .addClass(this.settings.active_class), target);
163
+ dropdown.prev('[' + this.attr_name() + ']').addClass(this.settings.active_class);
164
+ dropdown.data('target', target.get(0)).trigger('opened.fndtn.dropdown', [dropdown, target]);
165
+ dropdown.attr('aria-hidden', 'false');
166
+ target.attr('aria-expanded', 'true');
167
+ dropdown.focus();
168
+ dropdown.addClass('f-open-' + this.attr_name(true));
169
+ },
170
+
171
+ data_attr : function () {
172
+ if (this.namespace.length > 0) {
173
+ return this.namespace + '-' + this.name;
174
+ }
175
+
176
+ return this.name;
177
+ },
178
+
179
+ toggle : function (target) {
180
+ if (target.hasClass(this.settings.disabled_class)) {
181
+ return;
182
+ }
183
+ var dropdown = this.S('#' + target.data(this.data_attr()));
184
+ if (dropdown.length === 0) {
185
+ // No dropdown found, not continuing
186
+ return;
187
+ }
188
+
189
+ this.close.call(this, this.S('[' + this.attr_name() + '-content]').not(dropdown));
190
+
191
+ if (dropdown.hasClass(this.settings.active_class)) {
192
+ this.close.call(this, dropdown);
193
+ if (dropdown.data('target') !== target.get(0)) {
194
+ this.open.call(this, dropdown, target);
195
+ }
196
+ } else {
197
+ this.open.call(this, dropdown, target);
198
+ }
199
+ },
200
+
201
+ resize : function () {
202
+ var dropdown = this.S('[' + this.attr_name() + '-content].open');
203
+ var target = $(dropdown.data("target"));
204
+
205
+ if (dropdown.length && target.length) {
206
+ this.css(dropdown, target);
207
+ }
208
+ },
209
+
210
+ css : function (dropdown, target) {
211
+ var left_offset = Math.max((target.width() - dropdown.width()) / 2, 8),
212
+ settings = target.data(this.attr_name(true) + '-init') || this.settings,
213
+ parentOverflow = dropdown.parent().css('overflow-y') || dropdown.parent().css('overflow');
214
+
215
+ this.clear_idx();
216
+
217
+
218
+
219
+ if (this.small()) {
220
+ var p = this.dirs.bottom.call(dropdown, target, settings);
221
+
222
+ dropdown.attr('style', '').removeClass('drop-left drop-right drop-top').css({
223
+ position : 'absolute',
224
+ width : '95%',
225
+ 'max-width' : 'none',
226
+ top : p.top
227
+ });
228
+
229
+ dropdown.css(Foundation.rtl ? 'right' : 'left', left_offset);
230
+ }
231
+ // detect if dropdown is in an overflow container
232
+ else if (parentOverflow !== 'visible') {
233
+ var offset = target[0].offsetTop + target[0].offsetHeight;
234
+
235
+ dropdown.attr('style', '').css({
236
+ position : 'absolute',
237
+ top : offset
238
+ });
239
+
240
+ dropdown.css(Foundation.rtl ? 'right' : 'left', left_offset);
241
+ }
242
+ else {
243
+
244
+ this.style(dropdown, target, settings);
245
+ }
246
+
247
+ return dropdown;
248
+ },
249
+
250
+ style : function (dropdown, target, settings) {
251
+ var css = $.extend({position : 'absolute'},
252
+ this.dirs[settings.align].call(dropdown, target, settings));
253
+
254
+ dropdown.attr('style', '').css(css);
255
+ },
256
+
257
+ // return CSS property object
258
+ // `this` is the dropdown
259
+ dirs : {
260
+ // Calculate target offset
261
+ _base : function (t) {
262
+ var o_p = this.offsetParent(),
263
+ o = o_p.offset(),
264
+ p = t.offset();
265
+
266
+ p.top -= o.top;
267
+ p.left -= o.left;
268
+
269
+ //set some flags on the p object to pass along
270
+ p.missRight = false;
271
+ p.missTop = false;
272
+ p.missLeft = false;
273
+ p.leftRightFlag = false;
274
+
275
+ //lets see if the panel will be off the screen
276
+ //get the actual width of the page and store it
277
+ var actualBodyWidth;
278
+ if (document.getElementsByClassName('row')[0]) {
279
+ actualBodyWidth = document.getElementsByClassName('row')[0].clientWidth;
280
+ } else {
281
+ actualBodyWidth = window.innerWidth;
282
+ }
283
+
284
+ var actualMarginWidth = (window.innerWidth - actualBodyWidth) / 2;
285
+ var actualBoundary = actualBodyWidth;
286
+
287
+ if (!this.hasClass('mega')) {
288
+ //miss top
289
+ if (t.offset().top <= this.outerHeight()) {
290
+ p.missTop = true;
291
+ actualBoundary = window.innerWidth - actualMarginWidth;
292
+ p.leftRightFlag = true;
293
+ }
294
+
295
+ //miss right
296
+ if (t.offset().left + this.outerWidth() > t.offset().left + actualMarginWidth && t.offset().left - actualMarginWidth > this.outerWidth()) {
297
+ p.missRight = true;
298
+ p.missLeft = false;
299
+ }
300
+
301
+ //miss left
302
+ if (t.offset().left - this.outerWidth() <= 0) {
303
+ p.missLeft = true;
304
+ p.missRight = false;
305
+ }
306
+ }
307
+
308
+ return p;
309
+ },
310
+
311
+ top : function (t, s) {
312
+ var self = Foundation.libs.dropdown,
313
+ p = self.dirs._base.call(this, t);
314
+
315
+ this.addClass('drop-top');
316
+
317
+ if (p.missTop == true) {
318
+ p.top = p.top + t.outerHeight() + this.outerHeight();
319
+ this.removeClass('drop-top');
320
+ }
321
+
322
+ if (p.missRight == true) {
323
+ p.left = p.left - this.outerWidth() + t.outerWidth();
324
+ }
325
+
326
+ if (t.outerWidth() < this.outerWidth() || self.small() || this.hasClass(s.mega_menu)) {
327
+ self.adjust_pip(this, t, s, p);
328
+ }
329
+
330
+ if (Foundation.rtl) {
331
+ return {left : p.left - this.outerWidth() + t.outerWidth(),
332
+ top : p.top - this.outerHeight()};
333
+ }
334
+
335
+ return {left : p.left, top : p.top - this.outerHeight()};
336
+ },
337
+
338
+ bottom : function (t, s) {
339
+ var self = Foundation.libs.dropdown,
340
+ p = self.dirs._base.call(this, t);
341
+
342
+ if (p.missRight == true) {
343
+ p.left = p.left - this.outerWidth() + t.outerWidth();
344
+ }
345
+
346
+ if (t.outerWidth() < this.outerWidth() || self.small() || this.hasClass(s.mega_menu)) {
347
+ self.adjust_pip(this, t, s, p);
348
+ }
349
+
350
+ if (self.rtl) {
351
+ return {left : p.left - this.outerWidth() + t.outerWidth(), top : p.top + t.outerHeight()};
352
+ }
353
+
354
+ return {left : p.left, top : p.top + t.outerHeight()};
355
+ },
356
+
357
+ left : function (t, s) {
358
+ var p = Foundation.libs.dropdown.dirs._base.call(this, t);
359
+
360
+ this.addClass('drop-left');
361
+
362
+ if (p.missLeft == true) {
363
+ p.left = p.left + this.outerWidth();
364
+ p.top = p.top + t.outerHeight();
365
+ this.removeClass('drop-left');
366
+ }
367
+
368
+ return {left : p.left - this.outerWidth(), top : p.top};
369
+ },
370
+
371
+ right : function (t, s) {
372
+ var p = Foundation.libs.dropdown.dirs._base.call(this, t);
373
+
374
+ this.addClass('drop-right');
375
+
376
+ if (p.missRight == true) {
377
+ p.left = p.left - this.outerWidth();
378
+ p.top = p.top + t.outerHeight();
379
+ this.removeClass('drop-right');
380
+ } else {
381
+ p.triggeredRight = true;
382
+ }
383
+
384
+ var self = Foundation.libs.dropdown;
385
+
386
+ if (t.outerWidth() < this.outerWidth() || self.small() || this.hasClass(s.mega_menu)) {
387
+ self.adjust_pip(this, t, s, p);
388
+ }
389
+
390
+ return {left : p.left + t.outerWidth(), top : p.top};
391
+ }
392
+ },
393
+
394
+ // Insert rule to style psuedo elements
395
+ adjust_pip : function (dropdown, target, settings, position) {
396
+ var sheet = Foundation.stylesheet,
397
+ pip_offset_base = 8;
398
+
399
+ if (dropdown.hasClass(settings.mega_class)) {
400
+ pip_offset_base = position.left + (target.outerWidth() / 2) - 8;
401
+ } else if (this.small()) {
402
+ pip_offset_base += position.left - 8;
403
+ }
404
+
405
+ this.rule_idx = sheet.cssRules.length;
406
+
407
+ //default
408
+ var sel_before = '.f-dropdown.open:before',
409
+ sel_after = '.f-dropdown.open:after',
410
+ css_before = 'left: ' + pip_offset_base + 'px;',
411
+ css_after = 'left: ' + (pip_offset_base - 1) + 'px;';
412
+
413
+ if (position.missRight == true) {
414
+ pip_offset_base = dropdown.outerWidth() - 23;
415
+ sel_before = '.f-dropdown.open:before',
416
+ sel_after = '.f-dropdown.open:after',
417
+ css_before = 'left: ' + pip_offset_base + 'px;',
418
+ css_after = 'left: ' + (pip_offset_base - 1) + 'px;';
419
+ }
420
+
421
+ //just a case where right is fired, but its not missing right
422
+ if (position.triggeredRight == true) {
423
+ sel_before = '.f-dropdown.open:before',
424
+ sel_after = '.f-dropdown.open:after',
425
+ css_before = 'left:-12px;',
426
+ css_after = 'left:-14px;';
427
+ }
428
+
429
+ if (sheet.insertRule) {
430
+ sheet.insertRule([sel_before, '{', css_before, '}'].join(' '), this.rule_idx);
431
+ sheet.insertRule([sel_after, '{', css_after, '}'].join(' '), this.rule_idx + 1);
432
+ } else {
433
+ sheet.addRule(sel_before, css_before, this.rule_idx);
434
+ sheet.addRule(sel_after, css_after, this.rule_idx + 1);
435
+ }
436
+ },
437
+
438
+ // Remove old dropdown rule index
439
+ clear_idx : function () {
440
+ var sheet = Foundation.stylesheet;
441
+
442
+ if (typeof this.rule_idx !== 'undefined') {
443
+ sheet.deleteRule(this.rule_idx);
444
+ sheet.deleteRule(this.rule_idx);
445
+ delete this.rule_idx;
446
+ }
447
+ },
448
+
449
+ small : function () {
450
+ return matchMedia(Foundation.media_queries.small).matches &&
451
+ !matchMedia(Foundation.media_queries.medium).matches;
452
+ },
453
+
454
+ off : function () {
455
+ this.S(this.scope).off('.fndtn.dropdown');
456
+ this.S('html, body').off('.fndtn.dropdown');
457
+ this.S(window).off('.fndtn.dropdown');
458
+ this.S('[data-dropdown-content]').off('.fndtn.dropdown');
459
+ },
460
+
461
+ reflow : function () {}
462
+ };
463
+ }(jQuery, window, window.document));
@@ -0,0 +1,104 @@
1
+ ;(function ($, window, document, undefined) {
2
+ 'use strict';
3
+
4
+ Foundation.libs.equalizer = {
5
+ name : 'equalizer',
6
+
7
+ version : '5.5.2',
8
+
9
+ settings : {
10
+ use_tallest : true,
11
+ before_height_change : $.noop,
12
+ after_height_change : $.noop,
13
+ equalize_on_stack : false,
14
+ act_on_hidden_el: false
15
+ },
16
+
17
+ init : function (scope, method, options) {
18
+ Foundation.inherit(this, 'image_loaded');
19
+ this.bindings(method, options);
20
+ this.reflow();
21
+ },
22
+
23
+ events : function () {
24
+ this.S(window).off('.equalizer').on('resize.fndtn.equalizer', function (e) {
25
+ this.reflow();
26
+ }.bind(this));
27
+ },
28
+
29
+ equalize : function (equalizer) {
30
+ var isStacked = false,
31
+ group = equalizer.data('equalizer'),
32
+ settings = equalizer.data(this.attr_name(true)+'-init') || this.settings,
33
+ vals,
34
+ firstTopOffset;
35
+
36
+ if (settings.act_on_hidden_el) {
37
+ vals = group ? equalizer.find('['+this.attr_name()+'-watch="'+group+'"]') : equalizer.find('['+this.attr_name()+'-watch]');
38
+ }
39
+ else {
40
+ vals = group ? equalizer.find('['+this.attr_name()+'-watch="'+group+'"]:visible') : equalizer.find('['+this.attr_name()+'-watch]:visible');
41
+ }
42
+
43
+ if (vals.length === 0) {
44
+ return;
45
+ }
46
+
47
+ settings.before_height_change();
48
+ equalizer.trigger('before-height-change.fndth.equalizer');
49
+ vals.height('inherit');
50
+
51
+ if (settings.equalize_on_stack === false) {
52
+ firstTopOffset = vals.first().offset().top;
53
+ vals.each(function () {
54
+ if ($(this).offset().top !== firstTopOffset) {
55
+ isStacked = true;
56
+ return false;
57
+ }
58
+ });
59
+ if (isStacked) {
60
+ return;
61
+ }
62
+ }
63
+
64
+ var heights = vals.map(function () { return $(this).outerHeight(false) }).get();
65
+
66
+ if (settings.use_tallest) {
67
+ var max = Math.max.apply(null, heights);
68
+ vals.css('height', max);
69
+ } else {
70
+ var min = Math.min.apply(null, heights);
71
+ vals.css('height', min);
72
+ }
73
+
74
+ settings.after_height_change();
75
+ equalizer.trigger('after-height-change.fndtn.equalizer');
76
+ },
77
+
78
+ reflow : function () {
79
+ var self = this;
80
+
81
+ this.S('[' + this.attr_name() + ']', this.scope).each(function () {
82
+ var $eq_target = $(this),
83
+ media_query = $eq_target.data('equalizer-mq'),
84
+ ignore_media_query = true;
85
+
86
+ if (media_query) {
87
+ media_query = 'is_' + media_query.replace(/-/g, '_');
88
+ if (Foundation.utils.hasOwnProperty(media_query)) {
89
+ ignore_media_query = false;
90
+ }
91
+ }
92
+
93
+ self.image_loaded(self.S('img', this), function () {
94
+ if (ignore_media_query || Foundation.utils[media_query]()) {
95
+ self.equalize($eq_target)
96
+ } else {
97
+ var vals = $eq_target.find('[' + self.attr_name() + '-watch]:visible');
98
+ vals.css('height', 'auto');
99
+ }
100
+ });
101
+ });
102
+ }
103
+ };
104
+ })(jQuery, window, window.document);