Permalink
Browse files

initial commit

  • Loading branch information...
0 parents commit a14ce6c9375323f69bc46ae5306517e5d83e56c2 @kswedberg committed Sep 7, 2010
Showing with 1,177 additions and 0 deletions.
  1. +90 −0 index.html
  2. +13 −0 lib/LAB.src.min.js
  3. +7 −0 lib/extras.js
  4. +154 −0 lib/jquery-1.4.2.min.js
  5. +18 −0 lib/jquery.bbq.js
  6. +278 −0 license-GPL.txt
  7. +20 −0 license.txt
  8. +62 −0 readme.md
  9. +198 −0 scripts/search.js
  10. +26 −0 styles/ie.css
  11. +311 −0 styles/style.css
@@ -0,0 +1,90 @@
+<!DOCTYPE HTML>
+<html lang="en">
+<head>
+ <meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
+ <title>jQuery API Search</title>
+ <script>document.documentElement.className = 'js';</script>
+ <link rel="stylesheet" href="styles/style.css" type="text/css" media="screen, projection" />
+ <!--[if lte IE 8]>
+ <link rel="stylesheet" href="styles/ie.css" type="text/css" media="screen, projection" />
+ <![endif]-->
+</head>
+<body>
+ <form action="" class="group">
+ <div>
+ <a id="search-again" class="js-hide btn" href="#">&#x271A; Search Again</a>
+ <h3>jQuery API Search <span class="note">A demonstration</span></h3>
+
+ </div>
+ <fieldset>
+ <div class="text">
+ <label for="title">Name</label>
+ <input type="text" id="title" name="title" />
+ </div>
+ <div class="text">
+ <label for="category">Category</label>
+ <input type="text" id="category" name="category" />
+ </div>
+ <div class="text">
+ <label for="version">Version</label>
+ <input type="text" id="version" name="version" />
+ </div>
+ <div class="actions">
+ <button type="submit">Search</button>
+ </div>
+ </fieldset>
+ <fieldset class="includes">
+ <h4><a id="toggle-advanced" class="btn" href="#advanced"><span>&#x2712;</span> Advanced</a></h4>
+ <div id="advanced" class="js-hide">
+ <h5>Matching</h5>
+ <div class="radio">
+ <input type="radio" checked="checked" value="" id="match_anywhere" name="match" />
+ <label for="match_anywhere">Anywhere</label>
+ </div>
+ <div class="radio">
+ <input type="radio" value="start" id="match_start" name="match" />
+ <label for="match_start">Start</label>
+ </div>
+ <div class="radio">
+ <input type="radio" value="end" id="match_end" name="match" />
+ <label for="match_end">End</label>
+ </div>
+ <div class="radio">
+ <input type="radio" value="exact" id="match_exact" name="match" />
+ <label for="match_exact">Exact</label>
+ </div>
+ <h5>Include in Results</h5>
+ <div class="checkbox">
+ <input type="checkbox" checked="checked" value="added" id="added" name="include[]" />
+ <label for="added">Version Added</label>
+ </div>
+ <div class="checkbox">
+ <input type="checkbox" checked="checked" value="params" id="params" name="include[]" />
+ <label for="params">Arguments</label>
+ </div>
+
+ <div class="checkbox">
+ <input type="checkbox" checked="checked" value="desc" id="short_description" name="include[]" />
+ <label for="short_description">Short Description</label>
+ </div>
+ <div class="checkbox">
+ <input type="checkbox" checked="checked" value="longdesc" id="long_description" name="include[]" />
+ <label for="long_description">Long Description</label>
+ </div>
+ </div>
+ </fieldset>
+ </form>
+
+<div id="log"></div>
+<script src="lib/LAB.src.min.js"></script>
+<script>
+ $LAB
+ .script('lib/jquery-1.4.2.min.js')
+ .wait()
+ .script('lib/jquery.bbq.js')
+ .wait()
+ .script('lib/extras.js')
+ .script('scripts/search.js');
+</script>
+</body>
+</html>
@@ -0,0 +1,13 @@
+// LAB.js (LABjs :: Loading And Blocking JavaScript)
+// v1.0.2rc1 (c) Kyle Simpson
+// MIT License
+
+(function(m){var p="string",z="head",L="body",aa="script",w="readyState",n="preloaddone",C="loadtrigger",M="srcuri",G="preload",ba="complete",D="done",E="which",N="preserve",H="onreadystatechange",ca="onload",O="hasOwnProperty",da="script/cache",A="[object ",ta=A+"Function]",ua=A+"Array]",f=null,i=true,j=false,v=m.document,I=m.location,ea=m.ActiveXObject,F=m.setTimeout,fa=m.clearTimeout;function P(c){return v.getElementsByTagName(c)}var Q=Object.prototype.toString;function R(){}var q={},S={},ga=/^[^?#]*\//.exec(I.href)[0],
+ha=/^\w+\:\/\/\/?[^\/]+/.exec(ga)[0],va=P(aa);A=m.opera&&Q.call(m.opera)==A+"Opera]";I=function(c){c[c]=c+"";return c[c]!=c+""}(new String("__count__"));var x={cache:!(I||A),order:I||A,xhr:i,dupe:i,base:"",which:z};x[N]=j;x[G]=i;q[z]=P(z);q[L]=P(L);function T(c){return Q.call(c)===ta}function U(c,d){var g=/^\w+\:\/\//;if(typeof c!==p)c="";if(typeof d!==p)d="";c=(g.test(c)?"":d)+c;return(g.test(c)?"":c.charAt(0)==="/"?ha:ga)+c}function wa(c){return U(c).indexOf(ha)===0}function xa(c){for(var d,g=-1;d=
+va[++g];)if(typeof d.src===p&&c===U(d.src)&&d.type!==da)return i;return j}function J(c,d){c=!!c;if(d==f)d=x;var g=j,l=c&&d[G],r=l&&d.cache,K=l&&d.order,ia=l&&d.xhr,ya=d[N],za=d.which,Aa=d.base,ja=R,V=j,B,s=i,o={},W=[],X=f;l=r||ia||K;function ka(a,b){if(a[w]&&a[w]!==ba&&a[w]!=="loaded"||b[D])return j;a[ca]=a[H]=f;return i}function Y(a,b,e){if((e=!!e)||ka(a,b)){b[D]=i;for(var h in o)if(o[O](h)&&!o[h][D])return;g=i;ja()}}function la(a){if(T(a[C])){a[C]();a[C]=f}}function Ba(a,b){if(ka(a,b)){b[n]=i;F(function(){q[b[E]].removeChild(a);
+la(b)},0)}}function Ca(a,b){if(a[w]===4){a[H]=R;b[n]=i;F(function(){la(b)},0)}}function Z(a,b,e,h,k,t){var y=a[E];F(function(){if("item"in q[y]){if(!q[y][0]){F(arguments.callee,25);return}q[y]=q[y][0]}var u=v.createElement(aa);u.type=e;if(typeof h===p)u.charset=h;if(T(k)){u[ca]=u[H]=function(){k(u,a)};u.src=b}q[y].insertBefore(u,y===z?q[y].firstChild:f);if(typeof t===p){u.text=t;Y(u,a,i)}},0)}function ma(a,b,e,h){S[a[M]]=i;Z(a,b,e,h,Y)}function na(a,b,e,h){var k=arguments;if(s&&a[n]==f){a[n]=j;Z(a,
+b,da,h,Ba)}else if(!s&&a[n]!=f&&!a[n])a[C]=function(){na.apply(f,k)};else s||ma.apply(f,k)}function oa(a,b,e,h){var k=arguments,t;if(s&&a[n]==f){a[n]=j;t=a.xhr=ea?new ea("Microsoft.XMLHTTP"):new m.XMLHttpRequest;t[H]=function(){Ca(t,a)};t.open("GET",b);t.send("")}else if(!s&&a[n]!=f&&!a[n])a[C]=function(){oa.apply(f,k)};else if(!s){S[a[M]]=i;Z(a,b,e,h,f,a.xhr.responseText);a.xhr=f}}function pa(a){if(a.allowDup==f)a.allowDup=d.dupe;var b=a.src,e=a.type,h=a.charset;a=a.allowDup;b=U(b,Aa);var k=wa(b);
+if(typeof e!==p)e="text/javascript";if(typeof h!==p)h=f;a=!!a;if(!a&&(S[b]!=f||s&&o[b]||xa(b)))o[b]!=f&&o[b][n]&&!o[b][D]&&k&&Y(f,o[b],i);else{if(o[b]==f)o[b]={};a=o[b];if(a[E]==f)a[E]=za;a[D]=j;a[M]=b;V=i;if(!K&&ia&&k)oa(a,b,e,h);else!K&&r?na(a,b,e,h):ma(a,b,e,h)}}function qa(a){W.push(a)}function $(a){c&&!K&&qa(a);if(!c||l)a()}function ra(a){var b=[],e;for(e=-1;++e<a.length;)if(Q.call(a[e])===ua)b=b.concat(ra(a[e]));else b[b.length]=a[e];return b}B={script:function(){fa(X);var a=ra(arguments),b=
+B,e;if(ya)for(e=-1;++e<a.length;){if(e===0)$(function(){pa(typeof a[0]===p?{src:a[0]}:a[0])});else b=b.script(a[e]);b=b.wait()}else $(function(){for(e=-1;++e<a.length;)pa(typeof a[e]===p?{src:a[e]}:a[e])});X=F(function(){s=j},5);return b},wait:function(a){fa(X);s=j;T(a)||(a=R);var b=J(i,d),e=b.trigger;function h(){try{a()}catch(t){}e()}delete b.trigger;function k(){if(V&&!g)ja=h;else h()}c&&!V?qa(k):$(k);return b}};B.block=B.wait;if(c)B.trigger=function(){for(var a,b=-1;a=W[++b];)a();W=[]};return B}
+function sa(c){var d,g={},l={UseCachePreload:"cache",UseLocalXHR:"xhr",UsePreloading:G,AlwaysPreserveOrder:N,AllowDuplicates:"dupe"},r={AppendTo:E,BasePath:"base"};for(d in l)r[d]=l[d];g.order=!!x.order;for(d in r)if(r[O](d)&&x[r[d]]!=f)g[r[d]]=c[d]!=f?c[d]:x[r[d]];for(d in l)if(l[O](d))g[l[d]]=!!g[l[d]];if(!g[G])g.cache=g.order=g.xhr=j;g.which=g.which===z||g.which===L?g.which:z;return g}m.$LAB={setGlobalDefaults:function(c){x=sa(c)},setOptions:function(c){return J(j,sa(c))},script:function(){return J().script.apply(f,
+arguments)},wait:function(){return J().wait.apply(f,arguments)}};m.$LAB.block=m.$LAB.wait;(function(c,d,g){if(v[w]==f&&v[c]){v[w]="loading";v[c](d,g=function(){v.removeEventListener(d,g,j);v[w]=ba},j)}})("addEventListener","DOMContentLoaded")})(window);
@@ -0,0 +1,7 @@
+
+$('#toggle-advanced').click(function() {
+ var $span = $(this).find('span');
+ $span.html($span.html() == '' ? '' : '');
+ $('#advanced').slideToggle();
+ return false;
+});
Oops, something went wrong.

0 comments on commit a14ce6c

Please sign in to comment.