fortitude-sass 0.6.5 → 0.7.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (128) hide show
  1. checksums.yaml +4 -4
  2. data/.editorconfig +12 -0
  3. data/.gitignore +3 -1
  4. data/.ruby-version +1 -1
  5. data/Gruntfile.js +73 -38
  6. data/app/assets/javascripts/fortitude/blocks/dropdown.js +44 -0
  7. data/app/assets/javascripts/fortitude/blocks/flashbar.js +24 -0
  8. data/app/assets/javascripts/fortitude/blocks/modal.js +50 -0
  9. data/app/assets/javascripts/fortitude/blocks/navigationbar.js +11 -0
  10. data/app/assets/javascripts/fortitude/blocks/select-input.js +38 -0
  11. data/app/assets/javascripts/fortitude/blocks/shade.js +28 -0
  12. data/app/assets/javascripts/fortitude/blocks/tabs.js +50 -0
  13. data/app/assets/javascripts/fortitude/generic/get-target.js +13 -0
  14. data/app/assets/javascripts/fortitude/generic/measure-scrollbar.js +21 -0
  15. data/app/assets/javascripts/fortitude/{jquery/generic → generic}/screen-lock.js +6 -2
  16. data/app/assets/javascripts/fortitude/generic/transition-with.js +57 -0
  17. data/app/assets/javascripts/fortitude/generic/viewport.js +21 -0
  18. data/app/assets/javascripts/fortitude/generic/wait-for-animation.js +27 -0
  19. data/app/assets/javascripts/fortitude.js +1 -0
  20. data/app/assets/stylesheets/fortitude/api/blocks/_badge.scss +1 -1
  21. data/app/assets/stylesheets/fortitude/api/blocks/_block-list.scss +2 -2
  22. data/app/assets/stylesheets/fortitude/api/blocks/_button.scss +1 -1
  23. data/app/assets/stylesheets/fortitude/api/blocks/_dropdown.scss +45 -0
  24. data/app/assets/stylesheets/fortitude/api/blocks/_flag.scss +2 -2
  25. data/app/assets/stylesheets/fortitude/api/blocks/_flashbar.scss +11 -1
  26. data/app/assets/stylesheets/fortitude/api/blocks/_input.scss +5 -2
  27. data/app/assets/stylesheets/fortitude/api/blocks/_layout.scss +2 -2
  28. data/app/assets/stylesheets/fortitude/api/blocks/_media.scss +2 -2
  29. data/app/assets/stylesheets/fortitude/api/blocks/_modal.scss +28 -0
  30. data/app/assets/stylesheets/fortitude/api/blocks/_navigationbar.scss +1 -0
  31. data/app/assets/stylesheets/fortitude/api/blocks/_shade.scss +11 -1
  32. data/app/assets/stylesheets/fortitude/api/blocks/_table.scss +5 -0
  33. data/app/assets/stylesheets/fortitude/api/blocks/_tabs-navigation.scss +3 -0
  34. data/app/assets/stylesheets/fortitude/api/blocks/_text.scss +3 -0
  35. data/app/assets/stylesheets/fortitude/api/blocks/_ui-list.scss +2 -2
  36. data/app/assets/stylesheets/fortitude/base/_hr.scss +2 -2
  37. data/app/assets/stylesheets/fortitude/base/_page.scss +0 -2
  38. data/app/assets/stylesheets/fortitude/blocks/_badge.scss +2 -0
  39. data/app/assets/stylesheets/fortitude/blocks/_bare-list.scss +2 -0
  40. data/app/assets/stylesheets/fortitude/blocks/_block-list.scss +2 -0
  41. data/app/assets/stylesheets/fortitude/blocks/_box.scss +2 -0
  42. data/app/assets/stylesheets/fortitude/blocks/_button.scss +2 -0
  43. data/app/assets/stylesheets/fortitude/blocks/_container.scss +2 -0
  44. data/app/assets/stylesheets/fortitude/blocks/_dropdown.scss +15 -0
  45. data/app/assets/stylesheets/fortitude/blocks/_flag.scss +2 -0
  46. data/app/assets/stylesheets/fortitude/blocks/_flashbar.scss +6 -0
  47. data/app/assets/stylesheets/fortitude/blocks/_fluid-container.scss +2 -0
  48. data/app/assets/stylesheets/fortitude/blocks/_inline-list.scss +2 -0
  49. data/app/assets/stylesheets/fortitude/blocks/_input.scss +2 -0
  50. data/app/assets/stylesheets/fortitude/blocks/_layout.scss +2 -0
  51. data/app/assets/stylesheets/fortitude/blocks/_list-navigation.scss +2 -0
  52. data/app/assets/stylesheets/fortitude/blocks/_media.scss +2 -0
  53. data/app/assets/stylesheets/fortitude/blocks/_modal.scss +8 -16
  54. data/app/assets/stylesheets/fortitude/blocks/_navigationbar.scss +5 -2
  55. data/app/assets/stylesheets/fortitude/blocks/_shade.scss +7 -0
  56. data/app/assets/stylesheets/fortitude/blocks/_table.scss +1 -6
  57. data/app/assets/stylesheets/fortitude/blocks/_tabs-navigation.scss +6 -0
  58. data/app/assets/stylesheets/fortitude/blocks/_tabs.scss +2 -0
  59. data/app/assets/stylesheets/fortitude/blocks/_text.scss +1 -3
  60. data/app/assets/stylesheets/fortitude/blocks/_tooltip.scss +2 -0
  61. data/app/assets/stylesheets/fortitude/blocks/_ui-list.scss +2 -0
  62. data/app/assets/stylesheets/fortitude/blocks/_wings.scss +3 -1
  63. data/app/assets/stylesheets/fortitude/generic/_normalize.scss +52 -15
  64. data/app/assets/stylesheets/fortitude/settings/_defaults.scss +1 -0
  65. data/app/assets/stylesheets/fortitude/theme/base/_page.scss +21 -0
  66. data/app/assets/stylesheets/fortitude/theme/extensions/_badge.scss +11 -0
  67. data/app/assets/stylesheets/fortitude/theme/extensions/_box.scss +11 -0
  68. data/app/assets/stylesheets/fortitude/theme/extensions/_button.scss +25 -0
  69. data/app/assets/stylesheets/fortitude/theme/extensions/_flashbar.scss +15 -0
  70. data/app/assets/stylesheets/fortitude/theme/extensions/_navigationbar.scss +51 -0
  71. data/app/assets/stylesheets/fortitude/theme/extensions/_wings.scss +15 -0
  72. data/app/assets/stylesheets/fortitude/theme/settings/_colors.scss +309 -0
  73. data/app/assets/stylesheets/fortitude/theme.scss +9 -0
  74. data/app/assets/stylesheets/fortitude/tools/_functions.scss +22 -13
  75. data/app/assets/stylesheets/fortitude/tools/_mixins.scss +10 -3
  76. data/app/assets/stylesheets/fortitude/trumps/_responsive-column.scss +1 -1
  77. data/app/assets/stylesheets/fortitude/trumps/_responsive-line-height.scss +1 -1
  78. data/app/assets/stylesheets/fortitude/trumps/_responsive-margin.scss +3 -3
  79. data/app/assets/stylesheets/fortitude/trumps/_responsive-padding.scss +1 -1
  80. data/app/assets/stylesheets/fortitude.scss +2 -0
  81. data/bower.json +1 -1
  82. data/jasmine/fixtures/animations.css +85 -0
  83. data/jasmine/fixtures/dropdownFixture.html +91 -0
  84. data/jasmine/fixtures/flashbarFixture.html +6 -0
  85. data/jasmine/fixtures/getTargetFixture.html +11 -0
  86. data/jasmine/fixtures/measureScrollBarFixture.html +1 -0
  87. data/jasmine/fixtures/modalFixture.html +20 -0
  88. data/jasmine/fixtures/navigationbarFixture.html +20 -0
  89. data/jasmine/fixtures/selectInputFixture.html +13 -0
  90. data/jasmine/fixtures/shadeFixture.html +2 -0
  91. data/jasmine/fixtures/tabsFixture.html +22 -0
  92. data/jasmine/fixtures/transitionWithFixture.html +6 -0
  93. data/jasmine/fixtures/viewportFixture.html +2 -0
  94. data/jasmine/fixtures/waitForAnimationFixture.html +1 -0
  95. data/jasmine/helpers/fixtureHelper.js +4 -0
  96. data/jasmine/helpers/multiCallbackHelper.js +24 -0
  97. data/jasmine/specs/blocks/dropdownSpec.js +106 -0
  98. data/jasmine/specs/blocks/flashbarSpec.js +22 -0
  99. data/jasmine/specs/blocks/modalSpec.js +66 -0
  100. data/jasmine/specs/blocks/navigationbarSpec.js +34 -0
  101. data/jasmine/specs/blocks/selectInputSpec.js +31 -0
  102. data/jasmine/specs/blocks/shadeSpec.js +38 -0
  103. data/jasmine/specs/blocks/tabsSpec.js +63 -0
  104. data/jasmine/specs/generic/getTargetSpec.js +28 -0
  105. data/jasmine/specs/generic/measureScrollbarSpec.js +19 -0
  106. data/jasmine/specs/generic/screenLockSpec.js +32 -0
  107. data/jasmine/specs/generic/transitionWithSpec.js +82 -0
  108. data/jasmine/specs/generic/viewportSpec.js +32 -0
  109. data/jasmine/specs/generic/waitForAnimationSpec.js +35 -0
  110. data/jasmine/template.tmpl +2 -0
  111. data/lib/fortitude-sass/version.rb +1 -1
  112. data/package.json +8 -2
  113. data/sass_specs/blocks/_shade_spec.scss +11 -0
  114. data/sass_specs/tests.scss +1 -0
  115. data/sass_specs/tools/_functions_spec.scss +42 -12
  116. metadata +59 -16
  117. data/app/assets/javascripts/fortitude/jquery/blocks/flashbar.js +0 -13
  118. data/app/assets/javascripts/fortitude/jquery/blocks/select-input.js +0 -26
  119. data/app/assets/javascripts/fortitude/jquery/blocks/shade.js +0 -36
  120. data/app/assets/javascripts/fortitude/jquery/generic/measure-scrollbar.js +0 -13
  121. data/app/assets/javascripts/fortitude/jquery/generic/viewport.js +0 -9
  122. data/app/assets/javascripts/fortitude/jquery/generic/wait-for-animation.js +0 -103
  123. data/app/assets/javascripts/fortitude/jquery/index.js +0 -3
  124. data/app/assets/javascripts/fortitude.jquery.js +0 -45
  125. data/dist/fortitude-theme.css +0 -9236
  126. data/dist/fortitude.css +0 -8976
  127. data/dist/fortitude.jquery.js +0 -1
  128. data/dist/fortitude.min.js +0 -1
@@ -1 +0,0 @@
1
- !function(a){"use strict";a(document).on("click.ft.flashbar.data-api",".flashbar__close",function(b){var c=a(this);c.closest(".flashbar").remove(),b.preventDefault()})}(jQuery),function(a){"use strict";a(document).on("change.ft.select.data-api","select:not([multiple])",function(b){var c=a(this),d=c.find(":selected").attr("class"),e=c.data("lastOptionClassName");d!==e&&(c.addClass(d),c.removeClass(e),c.data("lastOptionClassName",d||"")),b.preventDefault()}),setTimeout(function(){a(document).find(".select-input").trigger("change")},0)}(jQuery),function(a){var b=a('meta[name="viewport"]');a(document).on("focus blur",":input",function(a){b.attr("content","width=device-width,initial-scale=1,maximum-scale="+("focusout"===a.type||"blur"===a.type?5:1))})}(jQuery),function(a){"use strict";a(document).on("close:ft:flashbar",".flashbar",function(){a(this).remove()}).on("click.ft.flashbar.data-api",".flashbar__close",function(b){a(this).closest(".flashbar").trigger("close:ft:flashbar"),b.preventDefault()})}(jQuery),function(a){"use strict";var b=a(document),c=function(){var b=a(this),c=b.find(":selected").attr("class")||"",d=b.data("ft.select")||{};c!==d.previousClass&&b.addClass(c).removeClass(d.previousClass).data("ft.select",a.merge({previousClass:c},d))};b.on("change.ft.select.data-api","select:not([multiple])",c),b.on("DOMContentLoaded",function(){b.find("select").data("ft.select",{previousClass:""}).each(c)})}(jQuery),function(a){"use strict";a(document).on("open:ft:shade",".shade",function(){var b=a(this);b.hasClass("shade--is-active")||b.addClass("shade--is-active").addClass(b.data().showClass).show().waitForAnimation().then(function(){b.removeClass(b.data().showClass)})}).on("close:ft:shade",".shade",function(){var b=a(this);b.hasClass("shade--is-active")&&b.addClass(b.data().hideClass).waitForAnimation().then(function(){b.hide().removeClass("shade--is-active").removeClass(b.data().hideClass)})}).on("click.ft.shade.data-api",".shade",function(b){a(this).trigger("close:ft:shade"),b.preventDefault()})}(jQuery),function(a){"use strict";a.measureScrollBar=function(){var b=a("body"),c=document.createElement("div");c.setAttribute("style","position: absolute; top: -9999px; width: 50px; height: 50px; overflow: scroll;"),b.append(c);var d=c.offsetWidth-c.clientWidth;return b.get(0).removeChild(c),d}}(jQuery),function(a){"use strict";a.screenLock=function(b){var c=a("html"),d=a("body");b?(c.addClass("html--is-locked"),d.css({paddingRight:a.measureScrollBar()})):(c.removeClass("html--is-locked"),d.css({paddingRight:""}))}}(jQuery),function(a){"use strict";var b=a('meta[name="viewport"]');a(document).on("focus blur",":input",function(a){b.attr("content","width=device-width,initial-scale=1,maximum-scale="+("focusout"===a.type||"blur"===a.type?5:1))})}(jQuery),function(a){"use strict";function b(){var a=document.createElement("fortitude"),b={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"},c={WebkitTransition:"-webkit-transition-duration",MozTransition:"transition-duration",OTransition:"-o-transition-duration",transition:"transition-duration"};for(var d in b)if(void 0!==a.style[d])return{end:b[d],duration:c[d]};return!1}function c(){var a=document.createElement("fortitude"),b={WebkitAnimation:"webkitAnimationEnd",MozAnimation:"animationend",OAnimation:"oAnimationEnd oanimationend",animation:"animationend"},c={WebkitAnimation:"-webkit-animation-duration",MozAnimation:"animationDuration",OAnimation:"-o-animation-duration",animation:"animation-duration"};for(var d in b)if(void 0!==a.style[d])return{end:b[d],duration:c[d]};return!1}function d(a){var b=a.split(/(ms|s)/,2),c="ms"===b[1]?parseFloat(b[0]):1e3*parseFloat(b[0]);return c||0}var e=b(),f=c();a.fn.waitForAnimation=function(b,c){var g,h,i=this,j=!1,k=a(i),l={type:"animation"};b=a.extend({},l,b),"animation"===b.type?(g=f.end,h=d(getComputedStyle(k.get(0),null)[f.duration])):"transition"===b.type&&(g=e.end,h=d(getComputedStyle(k.get(0),null)[e.duration]));var m=a.Deferred(function(a){var b=function(){j=!0,k.off(g,b),c&&clearTimeout(c),a.resolve()};k.on(g,b);var c=setTimeout(b,h)}).promise();return m.done(c)}}(jQuery);
@@ -1 +0,0 @@
1
- !function(a){"use strict";a(document).on("click.ft.flashbar.data-api",".flashbar__close",function(b){var c=a(this);c.closest(".flashbar").remove(),b.preventDefault()})}(jQuery),function(a){"use strict";a(document).on("change.ft.select.data-api","select:not([multiple])",function(b){var c=a(this),d=c.find(":selected").attr("class"),e=c.data("lastOptionClassName");d!==e&&(c.addClass(d),c.removeClass(e),c.data("lastOptionClassName",d||"")),b.preventDefault()}),setTimeout(function(){a(document).find(".select-input").trigger("change")},0)}(jQuery),function(a){var b=a('meta[name="viewport"]');a(document).on("focus blur",":input",function(a){b.attr("content","width=device-width,initial-scale=1,maximum-scale="+("focusout"===a.type||"blur"===a.type?5:1))})}(jQuery),function(a){"use strict";a(document).on("close:ft:flashbar",".flashbar",function(){a(this).remove()}).on("click.ft.flashbar.data-api",".flashbar__close",function(b){a(this).closest(".flashbar").trigger("close:ft:flashbar"),b.preventDefault()})}(jQuery),function(a){"use strict";var b=a(document),c=function(){var b=a(this),c=b.find(":selected").attr("class")||"",d=b.data("ft.select")||{};c!==d.previousClass&&b.addClass(c).removeClass(d.previousClass).data("ft.select",a.merge({previousClass:c},d))};b.on("change.ft.select.data-api","select:not([multiple])",c),b.on("DOMContentLoaded",function(){b.find("select").data("ft.select",{previousClass:""}).each(c)})}(jQuery),function(a){"use strict";a(document).on("open:ft:shade",".shade",function(){var b=a(this);b.hasClass("shade--is-active")||b.addClass("shade--is-active").addClass(b.data().showClass).show().waitForAnimation().then(function(){b.removeClass(b.data().showClass)})}).on("close:ft:shade",".shade",function(){var b=a(this);b.hasClass("shade--is-active")&&b.addClass(b.data().hideClass).waitForAnimation().then(function(){b.hide().removeClass("shade--is-active").removeClass(b.data().hideClass)})}).on("click.ft.shade.data-api",".shade",function(b){a(this).trigger("close:ft:shade"),b.preventDefault()})}(jQuery),function(a){"use strict";a.measureScrollBar=function(){var b=a("body"),c=document.createElement("div");c.setAttribute("style","position: absolute; top: -9999px; width: 50px; height: 50px; overflow: scroll;"),b.append(c);var d=c.offsetWidth-c.clientWidth;return b.get(0).removeChild(c),d}}(jQuery),function(a){"use strict";a.screenLock=function(b){var c=a("html"),d=a("body");b?(c.addClass("html--is-locked"),d.css({paddingRight:a.measureScrollBar()})):(c.removeClass("html--is-locked"),d.css({paddingRight:""}))}}(jQuery),function(a){"use strict";var b=a('meta[name="viewport"]');a(document).on("focus blur",":input",function(a){b.attr("content","width=device-width,initial-scale=1,maximum-scale="+("focusout"===a.type||"blur"===a.type?5:1))})}(jQuery),function(a){"use strict";function b(){var a=document.createElement("fortitude"),b={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"},c={WebkitTransition:"-webkit-transition-duration",MozTransition:"transition-duration",OTransition:"-o-transition-duration",transition:"transition-duration"};for(var d in b)if(void 0!==a.style[d])return{end:b[d],duration:c[d]};return!1}function c(){var a=document.createElement("fortitude"),b={WebkitAnimation:"webkitAnimationEnd",MozAnimation:"animationend",OAnimation:"oAnimationEnd oanimationend",animation:"animationend"},c={WebkitAnimation:"-webkit-animation-duration",MozAnimation:"animationDuration",OAnimation:"-o-animation-duration",animation:"animation-duration"};for(var d in b)if(void 0!==a.style[d])return{end:b[d],duration:c[d]};return!1}function d(a){var b=a.split(/(ms|s)/,2),c="ms"===b[1]?parseFloat(b[0]):1e3*parseFloat(b[0]);return c||0}var e=b(),f=c();a.fn.waitForAnimation=function(b,c){var g,h,i=this,j=!1,k=a(i),l={type:"animation"};b=a.extend({},l,b),"animation"===b.type?(g=f.end,h=d(getComputedStyle(k.get(0),null)[f.duration])):"transition"===b.type&&(g=e.end,h=d(getComputedStyle(k.get(0),null)[e.duration]));var m=a.Deferred(function(a){var b=function(){j=!0,k.off(g,b),c&&clearTimeout(c),a.resolve()};k.on(g,b);var c=setTimeout(b,h)}).promise();return m.done(c)}}(jQuery);