ZURB-foundation 2.1.5.2 → 2.2

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.
@@ -1,46 +1,87 @@
1
- $(document).ready(function () {
2
- /* TOOLTIPS ---------- */
3
- /* Positiong and options for adding tooltips */
1
+ /*
2
+ * jQuery Foundation Tooltip Plugin 1.0
3
+ * http://foundation.zurb.com
4
+ * Copyright 2012, ZURB
5
+ * Free to use under the MIT license.
6
+ * http://www.opensource.org/licenses/mit-license.php
7
+ */
8
+
9
+ ;(function($) {
10
+ var attributes = {
11
+ bodyHeight : 0,
12
+ pollInterval : 1000
13
+ };
14
+
15
+ var methods = {
16
+ init : function( options ) {
17
+
18
+ return this.each(function() {
19
+ var targets = $('.has-tip'),
20
+ tips = $('.tooltip'),
21
+ tipTemplate = function(target, content) {
22
+ return '<span data-id="' + target + '" class="tooltip">' + content + '<span class="nub"></span></span>';
23
+ },
24
+ poll = setInterval(methods.isDomResized, attributes.pollInterval);
25
+ if (tips.length < 1) {
26
+ targets.each(function(i){
27
+ var target = $(this),
28
+ id = 'foundationTooltip' + i,
29
+ content = target.attr('title'),
30
+ classes = target.attr('class');
31
+ target.data('id', id);
32
+ var tip = $(tipTemplate(id, content));
33
+ tip.addClass(classes).removeClass('has-tip').appendTo('body');
34
+ if (Modernizr.touch) {
35
+ tip.append('<span class="tap-to-close">tap to close </span>');
36
+ }
37
+ methods.reposition(target, tip, classes);
38
+ tip.fadeOut(150);
39
+ });
40
+ }
41
+ $(window).resize(function() {
42
+ var tips = $('.tooltip');
43
+ tips.each(function() {
44
+ var data = $(this).data();
45
+ target = targets = $('.has-tip'),
46
+ tip = $(this),
47
+ classes = tip.attr('class');
48
+ targets.each(function() {
49
+ ($(this).data().id == data.id) ? target = $(this) : target = target;
50
+ });
51
+ methods.reposition(target, tip, classes);
52
+ });
53
+
54
+ });
55
+
56
+ if (Modernizr.touch) {
57
+ $('.tooltip').live('click touchstart touchend', function(e) {
58
+ e.preventDefault();
59
+ $(this).fadeOut(150);
60
+ });
61
+ targets.live('click touchstart touchend', function(e){
62
+ e.preventDefault();
63
+ $('.tooltip').hide();
64
+ $('span[data-id=' + $(this).data('id') + '].tooltip').fadeIn(150);
65
+ targets.attr('title', "");
66
+ });
67
+
68
+ } else {
69
+ targets.hover(function() {
70
+ $('span[data-id=' + $(this).data('id') + '].tooltip').fadeIn(150);
71
+ targets.attr('title', "");
72
+ }, function() {
73
+ $('span[data-id=' + $(this).data('id') + '].tooltip').fadeOut(150);
74
+ });
75
+ }
4
76
 
5
- function foundationTooltipsInit() {
6
- var targets = $('.has-tip'),
7
- tipTemplate = function(target, content) {
8
- return '<span data-id="' + target + '" class="tooltip">' + content + '<span class="nub"></span></span>';
9
- };
10
- targets.each(function(){
11
- var target = $(this),
12
- content = target.attr('title'),
13
- classes = target.attr('class'),
14
- id = target.attr('id'),
15
- tip = $(tipTemplate(id, content));
16
- tip.addClass(classes).removeClass('has-tip').appendTo('body');
17
- reposition(target, tip, classes);
18
- tip.hide();
19
- if (Modernizr.touch) {
20
- tip.append('<span class="tap-to-close">tap to close </span>');
21
- }
22
- });
23
- $(window).resize(function() {
24
- var tips = $('.tooltip');
25
- tips.each(function() {
26
- var target = $('#' + $(this).data('id')),
27
- tip = $(this),
28
- classes = tip.attr('class');
29
- reposition(target, tip, classes);
30
77
  });
31
-
32
- });
33
-
34
- function reposition(target, tip, classes) {
78
+ },
79
+ reposition : function(target, tip, classes) {
35
80
  var width = target.data('width'),
36
81
  nub = tip.children('.nub'),
37
82
  nubHeight = nub.outerHeight(),
38
83
  nubWidth = nub.outerWidth();
39
- tip.css({
40
- 'top' : (target.offset().top + target.outerHeight() + 10),
41
- 'left' : target.offset().left,
42
- 'width' : width
43
- });
84
+
44
85
  function nubPos(nub, top, right, bottom, left) {
45
86
  nub.css({
46
87
  'top' : top,
@@ -49,53 +90,62 @@ $(document).ready(function () {
49
90
  'right' : right
50
91
  });
51
92
  }
93
+
94
+ tip.css({
95
+ 'top' : (target.offset().top + target.outerHeight() + 10),
96
+ 'left' : target.offset().left,
97
+ 'width' : width
98
+ });
52
99
  nubPos(nub, -nubHeight, 'auto', 'auto', 10);
100
+
53
101
  if ($(window).width() < 767) {
54
102
  var row = target.parents('.row');
55
- tip.width(row.outerWidth() - 20).css('left', row.offset().left);
103
+ tip.width(row.outerWidth() - 20).css('left', row.offset().left).addClass('tip-override');
56
104
  nubPos(nub, -nubHeight, 'auto', 'auto', target.offset().left);
57
105
  } else {
58
- if (classes.indexOf('top') > -1) {
59
- tip.css('top', target.offset().top - tip.outerHeight());
60
- nubPos(nub, 'auto', 'auto', -nubHeight, nubWidth);
61
- }
62
- if (classes.indexOf('left') > -1) {
106
+ if (classes.indexOf('tip-top') > -1) {
107
+ var top = target.offset().top - tip.outerHeight() - nubHeight;
63
108
  tip.css({
64
- 'top' : target.offset().top - (target.outerHeight() / 2),
65
- 'left' : target.offset().left - tip.outerWidth() - 10
66
- }).children('.nub').css('top', (tip.outerHeight() / 2) - (nub.outerHeight() / 2));
67
- nubPos(nub, ((tip.outerHeight() / 2) - (nub.outerHeight / 2)), -nubHeight, 'auto', 'auto');
68
- } else if (classes.indexOf('right') > -1){
109
+ 'top' : top,
110
+ 'left' : target.offset().left,
111
+ 'width' : width
112
+ }).removeClass('tip-override');
113
+ nubPos(nub, 'auto', 'auto', -nubHeight, 'auto');
114
+ } else if (classes.indexOf('tip-left') > -1) {
69
115
  tip.css({
70
- 'top' : target.offset().top - (target.outerHeight() / 2),
71
- 'left' : target.offset().left + target.outerWidth() + 10
72
- }).children('.nub').css('top', (tip.outerHeight() / 2) - (nub.outerHeight() / 2));
73
- nubPos(nub, ((tip.outerHeight() / 2) - (nub.outerHeight / 2)), 'auto', 'auto', -nubHeight);
74
- }
116
+ 'top' : target.offset().top - (target.outerHeight() / 2) - (nubHeight / 2),
117
+ 'left' : target.offset().left - tip.outerWidth() - 10,
118
+ 'width' : width
119
+ }).removeClass('tip-override');
120
+ nubPos(nub, (tip.outerHeight() / 2) - (nubHeight / 2), -nubHeight, 'auto', 'auto');
121
+ } else if (classes.indexOf('tip-right') > -1){
122
+ tip.css({
123
+ 'top' : target.offset().top - (target.outerHeight() / 2) - (nubHeight / 2),
124
+ 'left' : target.offset().left + target.outerWidth() + 10,
125
+ 'width' : width
126
+ }).removeClass('tip-override');
127
+ nubPos(nub, (tip.outerHeight() / 2) - (nubHeight / 2), 'auto', 'auto', -nubHeight);
128
+ }
129
+ }
130
+ },
131
+ isDomResized : function() {
132
+ $body = $('body');
133
+ if(attributes.bodyHeight != $body.height()) {
134
+ attributes.bodyHeight = $body.height();
135
+ $(window).trigger('resize');
75
136
  }
76
137
  }
77
- if (Modernizr.touch) {
78
- $('.tooltip').live('click', function(e) {
79
- e.preventDefault();
80
- $(this).hide();
81
- });
82
- targets.live('click', function(){
83
- targets.hover(function() {
84
- $('span[data-id=' + $(this).attr('id') + ']').show();
85
- targets.attr('title', "");
86
- }, function() {
87
- $('span[data-id=' + $(this).attr('id') + ']').hide();
88
- });
89
- });
138
+ };
90
139
 
140
+ $.fn.tooltips = function( method ) {
141
+
142
+ if ( methods[method] ) {
143
+ return methods[ method ].apply( this, Array.prototype.slice.call( arguments, 1 ));
144
+ } else if ( typeof method === 'object' || ! method ) {
145
+ return methods.init.apply( this, arguments );
91
146
  } else {
92
- targets.hover(function() {
93
- $('span[data-id=' + $(this).attr('id') + ']').show();
94
- targets.attr('title', "");
95
- }, function() {
96
- $('span[data-id=' + $(this).attr('id') + ']').hide();
97
- });
98
- }
99
- }
100
- foundationTooltipsInit();
101
- });
147
+ $.error( 'Method ' + method + ' does not exist on jQuery.tooltips' );
148
+ }
149
+
150
+ };
151
+ })(jQuery);;
@@ -1,4 +1,4 @@
1
- /* Modernizr 2.0.6 (Custom Build) | MIT & BSD
2
- * Build: http://www.modernizr.com/download/#-touch-iepp-respond-mq-cssclasses-teststyles-prefixes-load
1
+ /* Modernizr 2.5.2 (Custom Build) | MIT & BSD
2
+ * Build: http://www.modernizr.com/download/#-touch-mq-cssclasses-addtest-teststyles-prefixes-ie8compat-load
3
3
  */
4
- ;window.Modernizr=function(a,b,c){function A(a,b){return!!~(""+a).indexOf(b)}function z(a,b){return typeof a===b}function y(a,b){return x(n.join(a+";")+(b||""))}function x(a){k.cssText=a}var d="2.0.6",e={},f=!0,g=b.documentElement,h=b.head||b.getElementsByTagName("head")[0],i="modernizr",j=b.createElement(i),k=j.style,l,m=Object.prototype.toString,n=" -webkit- -moz- -o- -ms- -khtml- ".split(" "),o={},p={},q={},r=[],s=function(a,c,d,e){var f,h,j,k=b.createElement("div");if(parseInt(d,10))while(d--)j=b.createElement("div"),j.id=e?e[d]:i+(d+1),k.appendChild(j);f=["&shy;","<style>",a,"</style>"].join(""),k.id=i,k.innerHTML+=f,g.appendChild(k),h=c(k,a),k.parentNode.removeChild(k);return!!h},t=function(b){if(a.matchMedia)return matchMedia(b).matches;var c;s("@media "+b+" { #"+i+" { position: absolute; } }",function(b){c=(a.getComputedStyle?getComputedStyle(b,null):b.currentStyle).position=="absolute"});return c},u,v={}.hasOwnProperty,w;!z(v,c)&&!z(v.call,c)?w=function(a,b){return v.call(a,b)}:w=function(a,b){return b in a&&z(a.constructor.prototype[b],c)};var B=function(c,d){var f=c.join(""),g=d.length;s(f,function(c,d){var f=b.styleSheets[b.styleSheets.length-1],h=f.cssRules&&f.cssRules[0]?f.cssRules[0].cssText:f.cssText||"",i=c.childNodes,j={};while(g--)j[i[g].id]=i[g];e.touch="ontouchstart"in a||j.touch.offsetTop===9},g,d)}([,["@media (",n.join("touch-enabled),("),i,")","{#touch{top:9px;position:absolute}}"].join("")],[,"touch"]);o.touch=function(){return e.touch};for(var C in o)w(o,C)&&(u=C.toLowerCase(),e[u]=o[C](),r.push((e[u]?"":"no-")+u));x(""),j=l=null,a.attachEvent&&function(){var a=b.createElement("div");a.innerHTML="<elem></elem>";return a.childNodes.length!==1}()&&function(a,b){function s(a){var b=-1;while(++b<g)a.createElement(f[b])}a.iepp=a.iepp||{};var d=a.iepp,e=d.html5elements||"abbr|article|aside|audio|canvas|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",f=e.split("|"),g=f.length,h=new RegExp("(^|\\s)("+e+")","gi"),i=new RegExp("<(/*)("+e+")","gi"),j=/^\s*[\{\}]\s*$/,k=new RegExp("(^|[^\\n]*?\\s)("+e+")([^\\n]*)({[\\n\\w\\W]*?})","gi"),l=b.createDocumentFragment(),m=b.documentElement,n=m.firstChild,o=b.createElement("body"),p=b.createElement("style"),q=/print|all/,r;d.getCSS=function(a,b){if(a+""===c)return"";var e=-1,f=a.length,g,h=[];while(++e<f){g=a[e];if(g.disabled)continue;b=g.media||b,q.test(b)&&h.push(d.getCSS(g.imports,b),g.cssText),b="all"}return h.join("")},d.parseCSS=function(a){var b=[],c;while((c=k.exec(a))!=null)b.push(((j.exec(c[1])?"\n":c[1])+c[2]+c[3]).replace(h,"$1.iepp_$2")+c[4]);return b.join("\n")},d.writeHTML=function(){var a=-1;r=r||b.body;while(++a<g){var c=b.getElementsByTagName(f[a]),d=c.length,e=-1;while(++e<d)c[e].className.indexOf("iepp_")<0&&(c[e].className+=" iepp_"+f[a])}l.appendChild(r),m.appendChild(o),o.className=r.className,o.id=r.id,o.innerHTML=r.innerHTML.replace(i,"<$1font")},d._beforePrint=function(){p.styleSheet.cssText=d.parseCSS(d.getCSS(b.styleSheets,"all")),d.writeHTML()},d.restoreHTML=function(){o.innerHTML="",m.removeChild(o),m.appendChild(r)},d._afterPrint=function(){d.restoreHTML(),p.styleSheet.cssText=""},s(b),s(l);d.disablePP||(n.insertBefore(p,n.firstChild),p.media="print",p.className="iepp-printshim",a.attachEvent("onbeforeprint",d._beforePrint),a.attachEvent("onafterprint",d._afterPrint))}(a,b),e._version=d,e._prefixes=n,e.mq=t,e.testStyles=s,g.className=g.className.replace(/\bno-js\b/,"")+(f?" js "+r.join(" "):"");return e}(this,this.document),function(a,b){function u(){r(!0)}a.respond={},respond.update=function(){},respond.mediaQueriesSupported=b;if(!b){var c=a.document,d=c.documentElement,e=[],f=[],g=[],h={},i=30,j=c.getElementsByTagName("head")[0]||d,k=j.getElementsByTagName("link"),l=[],m=function(){var b=k,c=b.length,d=0,e,f,g,i;for(;d<c;d++)e=b[d],f=e.href,g=e.media,i=e.rel&&e.rel.toLowerCase()==="stylesheet",!!f&&i&&!h[f]&&(!/^([a-zA-Z]+?:(\/\/)?(www\.)?)/.test(f)||f.replace(RegExp.$1,"").split("/")[0]===a.location.host?l.push({href:f,media:g}):h[f]=!0);n()},n=function(){if(l.length){var a=l.shift();s(a.href,function(b){o(b,a.href,a.media),h[a.href]=!0,n()})}},o=function(a,b,c){var d=a.match(/@media[^\{]+\{([^\{\}]+\{[^\}\{]+\})+/gi),g=d&&d.length||0,b=b.substring(0,b.lastIndexOf("/")),h=function(a){return a.replace(/(url\()['"]?([^\/\)'"][^:\)'"]+)['"]?(\))/g,"$1"+b+"$2$3")},i=!g&&c,j=0,k,l,m,n,o;b.length&&(b+="/"),i&&(g=1);for(;j<g;j++){k=0,i?(l=c,f.push(h(a))):(l=d[j].match(/@media ([^\{]+)\{([\S\s]+?)$/)&&RegExp.$1,f.push(RegExp.$2&&h(RegExp.$2))),n=l.split(","),o=n.length;for(;k<o;k++)m=n[k],e.push({media:m.match(/(only\s+)?([a-zA-Z]+)(\sand)?/)&&RegExp.$2,rules:f.length-1,minw:m.match(/\(min\-width:[\s]*([\s]*[0-9]+)px[\s]*\)/)&&parseFloat(RegExp.$1),maxw:m.match(/\(max\-width:[\s]*([\s]*[0-9]+)px[\s]*\)/)&&parseFloat(RegExp.$1)})}r()},p,q,r=function(a){var b="clientWidth",h=d[b],l=c.compatMode==="CSS1Compat"&&h||c.body[b]||h,m={},n=c.createDocumentFragment(),o=k[k.length-1],s=(new Date).getTime();if(a&&p&&s-p<i)clearTimeout(q),q=setTimeout(r,i);else{p=s;for(var t in e){var u=e[t];if(!u.minw&&!u.maxw||(!u.minw||u.minw&&l>=u.minw)&&(!u.maxw||u.maxw&&l<=u.maxw))m[u.media]||(m[u.media]=[]),m[u.media].push(f[u.rules])}for(var t in g)g[t]&&g[t].parentNode===j&&j.removeChild(g[t]);for(var t in m){var v=c.createElement("style"),w=m[t].join("\n");v.type="text/css",v.media=t,v.styleSheet?v.styleSheet.cssText=w:v.appendChild(c.createTextNode(w)),n.appendChild(v),g.push(v)}j.insertBefore(n,o.nextSibling)}},s=function(a,b){var c=t();if(!!c){c.open("GET",a,!0),c.onreadystatechange=function(){c.readyState==4&&(c.status==200||c.status==304)&&b(c.responseText)};if(c.readyState==4)return;c.send()}},t=function(){var a=!1,b=[function(){return new ActiveXObject("Microsoft.XMLHTTP")},function(){return new XMLHttpRequest}],c=b.length;while(c--){try{a=b[c]()}catch(d){continue}break}return function(){return a}}();m(),respond.update=m,a.addEventListener?a.addEventListener("resize",u,!1):a.attachEvent&&a.attachEvent("onresize",u)}}(this,Modernizr.mq("only all")),function(a,b,c){function k(a){return!a||a=="loaded"||a=="complete"}function j(){var a=1,b=-1;while(p.length- ++b)if(p[b].s&&!(a=p[b].r))break;a&&g()}function i(a){var c=b.createElement("script"),d;c.src=a.s,c.onreadystatechange=c.onload=function(){!d&&k(c.readyState)&&(d=1,j(),c.onload=c.onreadystatechange=null)},m(function(){d||(d=1,j())},H.errorTimeout),a.e?c.onload():n.parentNode.insertBefore(c,n)}function h(a){var c=b.createElement("link"),d;c.href=a.s,c.rel="stylesheet",c.type="text/css";if(!a.e&&(w||r)){var e=function(a){m(function(){if(!d)try{a.sheet.cssRules.length?(d=1,j()):e(a)}catch(b){b.code==1e3||b.message=="security"||b.message=="denied"?(d=1,m(function(){j()},0)):e(a)}},0)};e(c)}else c.onload=function(){d||(d=1,m(function(){j()},0))},a.e&&c.onload();m(function(){d||(d=1,j())},H.errorTimeout),!a.e&&n.parentNode.insertBefore(c,n)}function g(){var a=p.shift();q=1,a?a.t?m(function(){a.t=="c"?h(a):i(a)},0):(a(),j()):q=0}function f(a,c,d,e,f,h){function i(){!o&&k(l.readyState)&&(r.r=o=1,!q&&j(),l.onload=l.onreadystatechange=null,m(function(){u.removeChild(l)},0))}var l=b.createElement(a),o=0,r={t:d,s:c,e:h};l.src=l.data=c,!s&&(l.style.display="none"),l.width=l.height="0",a!="object"&&(l.type=d),l.onload=l.onreadystatechange=i,a=="img"?l.onerror=i:a=="script"&&(l.onerror=function(){r.e=r.r=1,g()}),p.splice(e,0,r),u.insertBefore(l,s?null:n),m(function(){o||(u.removeChild(l),r.r=r.e=o=1,j())},H.errorTimeout)}function e(a,b,c){var d=b=="c"?z:y;q=0,b=b||"j",C(a)?f(d,a,b,this.i++,l,c):(p.splice(this.i++,0,a),p.length==1&&g());return this}function d(){var a=H;a.loader={load:e,i:0};return a}var l=b.documentElement,m=a.setTimeout,n=b.getElementsByTagName("script")[0],o={}.toString,p=[],q=0,r="MozAppearance"in l.style,s=r&&!!b.createRange().compareNode,t=r&&!s,u=s?l:n.parentNode,v=a.opera&&o.call(a.opera)=="[object Opera]",w="webkitAppearance"in l.style,x=w&&"async"in b.createElement("script"),y=r?"object":v||x?"img":"script",z=w?"img":y,A=Array.isArray||function(a){return o.call(a)=="[object Array]"},B=function(a){return Object(a)===a},C=function(a){return typeof a=="string"},D=function(a){return o.call(a)=="[object Function]"},E=[],F={},G,H;H=function(a){function f(a){var b=a.split("!"),c=E.length,d=b.pop(),e=b.length,f={url:d,origUrl:d,prefixes:b},g,h;for(h=0;h<e;h++)g=F[b[h]],g&&(f=g(f));for(h=0;h<c;h++)f=E[h](f);return f}function e(a,b,e,g,h){var i=f(a),j=i.autoCallback;if(!i.bypass){b&&(b=D(b)?b:b[a]||b[g]||b[a.split("/").pop().split("?")[0]]);if(i.instead)return i.instead(a,b,e,g,h);e.load(i.url,i.forceCSS||!i.forceJS&&/css$/.test(i.url)?"c":c,i.noexec),(D(b)||D(j))&&e.load(function(){d(),b&&b(i.origUrl,h,g),j&&j(i.origUrl,h,g)})}}function b(a,b){function c(a){if(C(a))e(a,h,b,0,d);else if(B(a))for(i in a)a.hasOwnProperty(i)&&e(a[i],h,b,i,d)}var d=!!a.test,f=d?a.yep:a.nope,g=a.load||a.both,h=a.callback,i;c(f),c(g),a.complete&&b.load(a.complete)}var g,h,i=this.yepnope.loader;if(C(a))e(a,0,i,0);else if(A(a))for(g=0;g<a.length;g++)h=a[g],C(h)?e(h,0,i,0):A(h)?H(h):B(h)&&b(h,i);else B(a)&&b(a,i)},H.addPrefix=function(a,b){F[a]=b},H.addFilter=function(a){E.push(a)},H.errorTimeout=1e4,b.readyState==null&&b.addEventListener&&(b.readyState="loading",b.addEventListener("DOMContentLoaded",G=function(){b.removeEventListener("DOMContentLoaded",G,0),b.readyState="complete"},0)),a.yepnope=d()}(this,this.document),Modernizr.load=function(){yepnope.apply(window,[].slice.call(arguments,0))};
4
+ ;window.Modernizr=function(a,b,c){function x(a){j.cssText=a}function y(a,b){return x(m.join(a+";")+(b||""))}function z(a,b){return typeof a===b}function A(a,b){return!!~(""+a).indexOf(b)}function B(a,b,d){for(var e in a){var f=b[a[e]];if(f!==c)return d===!1?a[e]:z(f,"function")?f.bind(d||b):f}return!1}var d="2.5.2",e={},f=!0,g=b.documentElement,h="modernizr",i=b.createElement(h),j=i.style,k,l={}.toString,m=" -webkit- -moz- -o- -ms- ".split(" "),n={},o={},p={},q=[],r=q.slice,s,t=function(a,c,d,e){var f,i,j,k=b.createElement("div"),l=b.body,m=l?l:b.createElement("body");if(parseInt(d,10))while(d--)j=b.createElement("div"),j.id=e?e[d]:h+(d+1),k.appendChild(j);return f=["&#173;","<style>",a,"</style>"].join(""),k.id=h,m.innerHTML+=f,m.appendChild(k),l||g.appendChild(m),i=c(k,a),l?k.parentNode.removeChild(k):m.parentNode.removeChild(m),!!i},u=function(b){var c=a.matchMedia||a.msMatchMedia;if(c)return c(b).matches;var d;return t("@media "+b+" { #"+h+" { position: absolute; } }",function(b){d=(a.getComputedStyle?getComputedStyle(b,null):b.currentStyle)["position"]=="absolute"}),d},v={}.hasOwnProperty,w;!z(v,"undefined")&&!z(v.call,"undefined")?w=function(a,b){return v.call(a,b)}:w=function(a,b){return b in a&&z(a.constructor.prototype[b],"undefined")},Function.prototype.bind||(Function.prototype.bind=function(b){var c=this;if(typeof c!="function")throw new TypeError;var d=r.call(arguments,1),e=function(){if(this instanceof e){var a=function(){};a.prototype=c.prototype;var f=new a,g=c.apply(f,d.concat(r.call(arguments)));return Object(g)===g?g:f}return c.apply(b,d.concat(r.call(arguments)))};return e});var C=function(c,d){var f=c.join(""),g=d.length;t(f,function(c,d){var f=b.styleSheets[b.styleSheets.length-1],h=f?f.cssRules&&f.cssRules[0]?f.cssRules[0].cssText:f.cssText||"":"",i=c.childNodes,j={};while(g--)j[i[g].id]=i[g];e.touch="ontouchstart"in a||a.DocumentTouch&&b instanceof DocumentTouch||(j.touch&&j.touch.offsetTop)===9},g,d)}([,["@media (",m.join("touch-enabled),("),h,")","{#touch{top:9px;position:absolute}}"].join("")],[,"touch"]);n.touch=function(){return e.touch};for(var D in n)w(n,D)&&(s=D.toLowerCase(),e[s]=n[D](),q.push((e[s]?"":"no-")+s));return e.addTest=function(a,b){if(typeof a=="object")for(var d in a)w(a,d)&&e.addTest(d,a[d]);else{a=a.toLowerCase();if(e[a]!==c)return e;b=typeof b=="function"?b():b,g.className+=" "+(b?"":"no-")+a,e[a]=b}return e},x(""),i=k=null,e._version=d,e._prefixes=m,e.mq=u,e.testStyles=t,g.className=g.className.replace(/(^|\s)no-js(\s|$)/,"$1$2")+(f?" js "+q.join(" "):""),e}(this,this.document),function(a,b,c){function d(a){return o.call(a)=="[object Function]"}function e(a){return typeof a=="string"}function f(){}function g(a){return!a||a=="loaded"||a=="complete"||a=="uninitialized"}function h(){var a=p.shift();q=1,a?a.t?m(function(){(a.t=="c"?B.injectCss:B.injectJs)(a.s,0,a.a,a.x,a.e,1)},0):(a(),h()):q=0}function i(a,c,d,e,f,i,j){function k(b){if(!o&&g(l.readyState)&&(u.r=o=1,!q&&h(),l.onload=l.onreadystatechange=null,b)){a!="img"&&m(function(){t.removeChild(l)},50);for(var d in y[c])y[c].hasOwnProperty(d)&&y[c][d].onload()}}var j=j||B.errorTimeout,l={},o=0,r=0,u={t:d,s:c,e:f,a:i,x:j};y[c]===1&&(r=1,y[c]=[],l=b.createElement(a)),a=="object"?l.data=c:(l.src=c,l.type=a),l.width=l.height="0",l.onerror=l.onload=l.onreadystatechange=function(){k.call(this,r)},p.splice(e,0,u),a!="img"&&(r||y[c]===2?(t.insertBefore(l,s?null:n),m(k,j)):y[c].push(l))}function j(a,b,c,d,f){return q=0,b=b||"j",e(a)?i(b=="c"?v:u,a,b,this.i++,c,d,f):(p.splice(this.i++,0,a),p.length==1&&h()),this}function k(){var a=B;return a.loader={load:j,i:0},a}var l=b.documentElement,m=a.setTimeout,n=b.getElementsByTagName("script")[0],o={}.toString,p=[],q=0,r="MozAppearance"in l.style,s=r&&!!b.createRange().compareNode,t=s?l:n.parentNode,l=!!b.attachEvent,u=r?"object":l?"script":"img",v=l?"script":u,w=Array.isArray||function(a){return o.call(a)=="[object Array]"},x=[],y={},z={timeout:function(a,b){return b.length&&(a.timeout=b[0]),a}},A,B;B=function(a){function b(a){var a=a.split("!"),b=x.length,c=a.pop(),d=a.length,c={url:c,origUrl:c,prefixes:a},e,f,g;for(f=0;f<d;f++)g=a[f].split("="),(e=z[g.shift()])&&(c=e(c,g));for(f=0;f<b;f++)c=x[f](c);return c}function g(a,e,f,g,i){var j=b(a),l=j.autoCallback;j.url.split(".").pop().split("?").shift(),j.bypass||(e&&(e=d(e)?e:e[a]||e[g]||e[a.split("/").pop().split("?")[0]]||h),j.instead?j.instead(a,e,f,g,i):(y[j.url]?j.noexec=!0:y[j.url]=1,f.load(j.url,j.forceCSS||!j.forceJS&&"css"==j.url.split(".").pop().split("?").shift()?"c":c,j.noexec,j.attrs,j.timeout),(d(e)||d(l))&&f.load(function(){k(),e&&e(j.origUrl,i,g),l&&l(j.origUrl,i,g),y[j.url]=2})))}function i(a,b){function c(a,c){if(a){if(e(a))c||(j=function(){var a=[].slice.call(arguments);k.apply(this,a),l()}),g(a,j,b,0,h);else if(Object(a)===a)for(n in m=function(){var b=0,c;for(c in a)a.hasOwnProperty(c)&&b++;return b}(),a)a.hasOwnProperty(n)&&(!c&&!--m&&(d(j)?j=function(){var a=[].slice.call(arguments);k.apply(this,a),l()}:j[n]=function(a){return function(){var b=[].slice.call(arguments);a&&a.apply(this,b),l()}}(k[n])),g(a[n],j,b,n,h))}else!c&&l()}var h=!!a.test,i=a.load||a.both,j=a.callback||f,k=j,l=a.complete||f,m,n;c(h?a.yep:a.nope,!!i),i&&c(i)}var j,l,m=this.yepnope.loader;if(e(a))g(a,0,m,0);else if(w(a))for(j=0;j<a.length;j++)l=a[j],e(l)?g(l,0,m,0):w(l)?B(l):Object(l)===l&&i(l,m);else Object(a)===a&&i(a,m)},B.addPrefix=function(a,b){z[a]=b},B.addFilter=function(a){x.push(a)},B.errorTimeout=1e4,b.readyState==null&&b.addEventListener&&(b.readyState="loading",b.addEventListener("DOMContentLoaded",A=function(){b.removeEventListener("DOMContentLoaded",A,0),b.readyState="complete"},0)),a.yepnope=k(),a.yepnope.executeStack=h,a.yepnope.injectJs=function(a,c,d,e,i,j){var k=b.createElement("script"),l,o,e=e||B.errorTimeout;k.src=a;for(o in d)k.setAttribute(o,d[o]);c=j?h:c||f,k.onreadystatechange=k.onload=function(){!l&&g(k.readyState)&&(l=1,c(),k.onload=k.onreadystatechange=null)},m(function(){l||(l=1,c(1))},e),i?k.onload():n.parentNode.insertBefore(k,n)},a.yepnope.injectCss=function(a,c,d,e,g,i){var e=b.createElement("link"),j,c=i?h:c||f;e.href=a,e.rel="stylesheet",e.type="text/css";for(j in d)e.setAttribute(j,d[j]);g||(n.parentNode.insertBefore(e,n),m(c,0))}}(this,document),Modernizr.load=function(){yepnope.apply(window,[].slice.call(arguments,0))},Modernizr.addTest("ie8compat",function(){return!window.addEventListener&&document.documentMode&&document.documentMode===7});
@@ -1,6 +1,7 @@
1
1
  description 'ZURB-foundation Compass Gem'
2
2
 
3
3
  # Sass Files
4
+ stylesheet 'sass/foundation.sass', :to => 'foundation.sass', :media => "screen, projector, print"
4
5
  stylesheet 'sass/app.sass', :to => 'app.sass', :media => "screen, projector, print"
5
6
  stylesheet 'sass/ie.sass', :to => 'ie.sass', :condition => "IE lt 9"
6
7
  stylesheet 'sass/_settings.sass', :to => '_settings.sass'
@@ -8,7 +9,6 @@ stylesheet 'sass/_settings.sass', :to => '_settings.sass'
8
9
  # Javascripts
9
10
  javascript 'javascripts/jquery.min.js', :to => 'jquery.min.js'
10
11
  javascript 'javascripts/modernizr.foundation.js', :to => 'modernizr.foundation.js'
11
- javascript 'javascripts/forms.jquery.js', :to => 'forms.jquery.js'
12
12
  javascript 'javascripts/jquery.customforms.js', :to => 'jquery.customforms.js'
13
13
  javascript 'javascripts/jquery.reveal.js', :to => 'jquery.reveal.js'
14
14
  javascript 'javascripts/jquery.orbit-1.4.0.js', :to => 'jquery.orbit-1.4.0.js'
@@ -1,24 +1,23 @@
1
- // `Global Foundation vars
2
- //----------------------------------------------------------------------------------------------------
1
+ // Global Foundation vars
2
+ //----------------------------------------------------------
3
3
 
4
- //
5
4
  // This file contains global variables and settings for Foundation
6
- // When adding new variables, be sure to use `!default` to allow over-riding at the project level
7
- //
5
+ // When adding new variables, be sure to use `!default` to allow over-riding
6
+ // at the project level
8
7
 
9
8
  // Compass experimental support setttings
10
- //----------------------------------------------------------------------------------------------------
9
+ //----------------------------------------------------------
11
10
 
12
11
  // $experimental-support-for-khtml: false
13
12
  // $experimental-support-for-microsoft: false
14
13
 
15
14
  // Font stacks
16
- //----------------------------------------------------------------------------------------------------
15
+ //----------------------------------------------------------
17
16
 
18
17
  // $helvetica-font-stack: "HelveticaNeue", "Helvetica Neue", Helvetica, Arial, "Lucida Grande", sans-serif
19
18
 
20
19
  // Default body tag variables
21
- //----------------------------------------------------------------------------------------------------
20
+ //----------------------------------------------------------
22
21
 
23
22
  // $body-font-size: 13
24
23
  // $body-font-family: $helvetica-font-stack
@@ -27,19 +26,23 @@
27
26
  // $body-color: #555
28
27
 
29
28
  // Grid settings
30
- //----------------------------------------------------------------------------------------------------
29
+ //----------------------------------------------------------
31
30
 
32
31
  // $grid-max-width: 980px
33
32
  // $grid-min-width: 727px
34
33
  // $support-block-grid-nth-child: false
35
34
 
36
35
  // Button settings
37
- //----------------------------------------------------------------------------------------------------
36
+ //----------------------------------------------------------
38
37
 
39
38
  // $button-transition-duration: .25s
40
39
 
41
40
  // Orbit settings
42
- //----------------------------------------------------------------------------------------------------
41
+ //----------------------------------------------------------
43
42
 
44
43
  // $orbit-slider-id: featured
45
- // $include-default-orbit-slider-id: true
44
+ // $include-default-orbit-slider-id: true
45
+
46
+ // Default Color
47
+ //----------------------------------------------------------
48
+ // $default-color: $blue
@@ -1,9 +1,16 @@
1
- // ZURB Foundation settings
2
- // Uncomment and adjust things in this file to create your own settings.
3
- @import settings
1
+ /* Artfully masterminded by ZURB */
4
2
 
5
- // Importing Foundation
6
- @import ZURB-foundation
3
+ // Table of Content
4
+ //-----------------------------------------
5
+ // - Shared Styles
6
+ // - Page Name 1
7
+ // - Page Name 2
7
8
 
8
- // Project Styles
9
- //-----------------------------------------
9
+
10
+ // Shared Styles
11
+
12
+
13
+ // Page Name 1
14
+
15
+
16
+ // Page Name 2
@@ -0,0 +1,17 @@
1
+ // ZURB Foundation settings
2
+ @import settings
3
+
4
+ // Importing all of Foundation
5
+ @import ZURB-foundation
6
+
7
+ // Import Each Specific Piece
8
+ // @import zurb/buttons
9
+ // @import zurb/forms
10
+ // @import zurb/globals
11
+ // @import zurb/grid
12
+ // @import zurb/mobile
13
+ // @import zurb/orbit
14
+ // @import zurb/reveal
15
+ // @import zurb/typography
16
+ // @import zurb/ui
17
+ // @import zurb/shared
@@ -11,4 +11,18 @@ div.panel
11
11
  .nav-bar li.has-flyout a
12
12
  padding-right: 20px
13
13
  &:after
14
- border-top: none
14
+ border-top: none
15
+
16
+ // Correct IE7 button padding
17
+ .lt-ie8 input[type=submit].nice.button
18
+ filter: chroma(color=#000000)
19
+ position: relative
20
+ top: -2px
21
+ .lt-ie8 input[type=submit].tiny.button
22
+ padding: 5px 5px 7px
23
+ .lt-ie8 input[type=submit].small.button
24
+ padding: 8px 7px 9px
25
+ .lt-ie8 input[type=submit].medium.button
26
+ padding: 9px 13px 9px
27
+ .lt-ie8 input[type=submit].large.button
28
+ padding: 9px 18px 10px
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ZURB-foundation
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.5.2
4
+ version: '2.2'
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,11 +9,11 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-01-27 00:00:00.000000000Z
12
+ date: 2012-02-29 00:00:00.000000000Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: compass
16
- requirement: &70152156998300 !ruby/object:Gem::Requirement
16
+ requirement: &70211124707640 !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ! '>='
@@ -21,7 +21,7 @@ dependencies:
21
21
  version: 0.11.5
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: *70152156998300
24
+ version_requirements: *70211124707640
25
25
  description: ZURB Foundation ported over to work with the power of Compass.
26
26
  email: foundation@zurb.com
27
27
  executables: []
@@ -62,7 +62,6 @@ files:
62
62
  - templates/project/images/orbit/timer-black.png
63
63
  - templates/project/index.html
64
64
  - templates/project/javascripts/app.js
65
- - templates/project/javascripts/forms.jquery.js
66
65
  - templates/project/javascripts/jquery.customforms.js
67
66
  - templates/project/javascripts/jquery.min.js
68
67
  - templates/project/javascripts/jquery.orbit-1.4.0.js
@@ -75,6 +74,7 @@ files:
75
74
  - templates/project/robots.txt
76
75
  - templates/project/sass/_settings.sass
77
76
  - templates/project/sass/app.sass
77
+ - templates/project/sass/foundation.sass
78
78
  - templates/project/sass/ie.sass
79
79
  homepage: http://foundation.zurb.com
80
80
  licenses: []
@@ -1,58 +0,0 @@
1
- /**
2
- * jQuery.placeholder - Placeholder plugin for input fields
3
- * Written by Blair Mitchelmore (blair DOT mitchelmore AT gmail DOT com)
4
- * Licensed under the WTFPL (http://sam.zoy.org/wtfpl/).
5
- * Date: 2008/10/14
6
- *
7
- * @author Blair Mitchelmore
8
- * @version 1.0.1
9
- *
10
- **/
11
- new function($) {
12
- $.fn.placeholder = function(settings) {
13
- settings = settings || {};
14
- var key = settings.dataKey || "placeholderValue";
15
- var attr = settings.attr || "placeholder";
16
- var className = settings.className || "placeholder";
17
- var values = settings.values || [];
18
- var block = settings.blockSubmit || false;
19
- var blank = settings.blankSubmit || false;
20
- var submit = settings.onSubmit || false;
21
- var value = settings.value || "";
22
- var position = settings.cursor_position || 0;
23
-
24
-
25
- return this.filter(":input").each(function(index) {
26
- $.data(this, key, values[index] || $(this).attr(attr));
27
- }).each(function() {
28
- if ($.trim($(this).val()) === "")
29
- $(this).addClass(className).val($.data(this, key));
30
- }).focus(function() {
31
- if ($.trim($(this).val()) === $.data(this, key))
32
- $(this).removeClass(className).val(value)
33
- if ($.fn.setCursorPosition) {
34
- $(this).setCursorPosition(position);
35
- }
36
- }).blur(function() {
37
- if ($.trim($(this).val()) === value)
38
- $(this).addClass(className).val($.data(this, key));
39
- }).each(function(index, elem) {
40
- if (block)
41
- new function(e) {
42
- $(e.form).submit(function() {
43
- return $.trim($(e).val()) != $.data(e, key)
44
- });
45
- }(elem);
46
- else if (blank)
47
- new function(e) {
48
- $(e.form).submit(function() {
49
- if ($.trim($(e).val()) == $.data(e, key))
50
- $(e).removeClass(className).val("");
51
- return true;
52
- });
53
- }(elem);
54
- else if (submit)
55
- new function(e) { $(e.form).submit(submit); }(elem);
56
- });
57
- };
58
- }(jQuery);