/*!
* version: beta 0.2.4
* date: 2014-07-17
* updates and docs at: http://www.greensock.com
*
* @license copyright (c) 2008-2014, greensock. all rights reserved.
* splittext is a club greensock membership benefit; you must have a valid membership to use
* this code without violating the terms of use. visit http://www.greensock.com/club/ to sign up or get more details.
* this work is subject to the software agreement that was issued with your membership.
*
* @author: jack doyle, jack@greensock.com
*/
var _gsscope="undefined"!=typeof module&&module.exports&&"undefined"!=typeof global?global:this||window;(function(t){"use strict";var e=t.greensockglobals||t,i=function(t){var i,s=t.split("."),r=e;for(i=0;s.length>i;i++)r[s[i]]=r=r[s[i]]||{};return r},s=i("com.greensock.utils"),r=function(t){var e=t.nodetype,i="";if(1===e||9===e||11===e){if("string"==typeof t.textcontent)return t.textcontent;for(t=t.firstchild;t;t=t.nextsibling)i+=r(t)}else if(3===e||4===e)return t.nodevalue;return i},n=document,a=n.defaultview?n.defaultview.getcomputedstyle:function(){},o=/([a-z])/g,h=function(t,e,i,s){var r;return(i=i||a(t,null))?(t=i.getpropertyvalue(e.replace(o,"-$1").tolowercase()),r=t||i.length?t:i[e]):t.currentstyle&&(i=t.currentstyle,r=i[e]),s?r:parseint(r,10)||0},l=function(t){return t.length&&t[0]&&(t[0].nodetype&&t[0].style&&!t.nodetype||t[0].length&&t[0][0])?!0:!1},_=function(t){var e,i,s,r=[],n=t.length;for(e=0;n>e;e++)if(i=t[e],l(i))for(s=i.length,s=0;i.length>s;s++)r.push(i[s]);else r.push(i);return r},u=")eefec303079ad17405c",c=/(?:
|
|
)/gi,p=n.all&&!n.addeventlistener,f="
":">")}},d=s.splittext=e.splittext=function(t,e){if("string"==typeof t&&(t=d.selector(t)),!t)throw"cannot split a null element.";this.elements=l(t)?_(t):[t],this.chars=[],this.words=[],this.lines=[],this._originals=[],this.vars=e||{},this.split(e)},g=function(t,e,i,s,o){c.test(t.innerhtml)&&(t.innerhtml=t.innerhtml.replace(c,u));var l,_,p,f,d,g,v,y,t,w,b,x,p,s=r(t),c=e.type||e.split||"chars,words,lines",k=-1!==c.indexof("lines")?[]:null,r=-1!==c.indexof("words"),a=-1!==c.indexof("chars"),d="absolute"===e.position||e.absolute===!0,o=d?" ":" ",m=-999,l=a(t),z=h(t,"paddingleft",l),i=h(t,"borderbottomwidth",l)+h(t,"bordertopwidth",l),e=h(t,"borderleftwidth",l)+h(t,"borderrightwidth",l),n=h(t,"paddingtop",l)+h(t,"paddingbottom",l),f=h(t,"paddingleft",l)+h(t,"paddingright",l),x=h(t,"textalign",l,!0),u=t.clientheight,b=t.clientwidth,j=s.length,y="
",q=m(e.wordsclass),g=m(e.charsclass),v=-1!==(e.linesclass||"").indexof("++"),q=e.linesclass;for(v&&(q=q.split("++").join("")),p=q(),f=0;j>f;f++)g=s.charat(f),")"===g&&s.substr(f,20)===u?(p+=y+"
",f!==j-1&&(p+=" "+q()),f+=19):" "===g&&" "!==s.charat(f-1)&&f!==j-1?(p+=y,f!==j-1&&(p+=o+q())):p+=a&&" "!==g?g()+g+"":g;for(t.innerhtml=p+y,d=t.getelementsbytagname("*"),j=d.length,v=[],f=0;j>f;f++)v[f]=d[f];if(k||d)for(f=0;j>f;f++)y=v[f],_=y.parentnode===t,(_||d||a&&!r)&&(t=y.offsettop,k&&_&&t!==m&&"br"!==y.nodename&&(l=[],k.push(l),m=t),d&&(y._x=y.offsetleft,y._y=t,y._w=y.offsetwidth,y._h=y.offsetheight),k&&(r!==_&&a||(l.push(y),y._x-=z),_&&f&&(v[f-1]._wordend=!0)));for(f=0;j>f;f++)y=v[f],_=y.parentnode===t,"br"!==y.nodename?(d&&(b=y.style,r||_||(y._x+=y.parentnode._x,y._y+=y.parentnode._y),b.left=y._x+"px",b.top=y._y+"px",b.position="absolute",b.display="block",b.width=y._w+1+"px",b.height=y._h+"px"),r?_?s.push(y):a&&i.push(y):_?(t.removechild(y),v.splice(f--,1),j--):!_&&a&&(t=!k&&!d&&y.nextsibling,t.appendchild(y),t||t.appendchild(n.createtextnode(" ")),i.push(y))):k||d?(t.removechild(y),v.splice(f--,1),j--):r||t.appendchild(y);if(k){for(d&&(w=n.createelement("div"),t.appendchild(w),x=w.offsetwidth+"px",t=w.offsetparent===t?0:t.offsetleft,t.removechild(w)),b=t.style.csstext,t.style.csstext="display:none;";t.firstchild;)t.removechild(t.firstchild);for(p=!d||!r&&!a,f=0;k.length>f;f++){for(l=k[f],w=n.createelement("div"),w.style.csstext="display:block;text-align:"+x+";position:"+(d?"absolute;":"relative;"),q&&(w.classname=q+(v?f+1:"")),o.push(w),j=l.length,d=0;j>d;d++)"br"!==l[d].nodename&&(y=l[d],w.appendchild(y),p&&(y._wordend||r)&&w.appendchild(n.createtextnode(" ")),d&&(0===d&&(w.style.top=y._y+"px",w.style.left=z+t+"px"),y.style.top="0px",t&&(y.style.left=y._x-t+"px")));r||a||(w.innerhtml=r(w).split(string.fromcharcode(160)).join(" ")),d&&(w.style.width=x,w.style.height=y._h+"px"),t.appendchild(w)}t.style.csstext=b}d&&(u>t.clientheight&&(t.style.height=u-n+"px",u>t.clientheight&&(t.style.height=u+i+"px")),b>t.clientwidth&&(t.style.width=b-f+"px",b>t.clientwidth&&(t.style.width=b+e+"px")))},v=d.prototype;v.split=function(t){this.issplit&&this.revert(),this.vars=t||this.vars,this._originals.length=this.chars.length=this.words.length=this.lines.length=0;for(var e=0;this.elements.length>e;e++)this._originals[e]=this.elements[e].innerhtml,g(this.elements[e],this.vars,this.chars,this.words,this.lines);return this.issplit=!0,this},v.revert=function(){if(!this._originals)throw"revert() call wasn't scoped properly.";for(var t=this._originals.length;--t>-1;)this.elements[t].innerhtml=this._originals[t];return this.chars=[],this.words=[],this.lines=[],this.issplit=!1,this},d.selector=t.$||t.jquery||function(e){return t.$?(d.selector=t.$,t.$(e)):n?n.getelementbyid("#"===e.charat(0)?e.substr(1):e):e},d.version="0.2.4"})(_gsscope),function(t){"use strict";var e=function(){return(_gsscope.greensockglobals||_gsscope)[t]};"function"==typeof define&&define.amd?define(["tweenlite"],e):"undefined"!=typeof module&&module.exports&&(module.exports=e())}("splittext");