Business intelligence made simple
First commit
Andrew Kanefebad48ae164
diff --git a/.gitignore b/.gitignorenew file mode 100644index 00000000..ae3fdc29--- /dev/null+++ b/.gitignore@@ -0,0 +1,14 @@+/.bundle/+/.yardoc+/Gemfile.lock+/_yardoc/+/coverage/+/doc/+/pkg/+/spec/reports/+/tmp/+*.bundle+*.so+*.o+*.a+mkmf.logdiff --git a/Gemfile b/Gemfilenew file mode 100644index 00000000..23ebcf43--- /dev/null+++ b/Gemfile@@ -0,0 +1,4 @@+source 'https://rubygems.org'++# Specify your gem's dependencies in blazer.gemspec+gemspecdiff --git a/LICENSE.txt b/LICENSE.txtnew file mode 100644index 00000000..ae04bf67--- /dev/null+++ b/LICENSE.txt@@ -0,0 +1,22 @@+Copyright (c) 2014 Andrew Kane++MIT License++Permission is hereby granted, free of charge, to any person obtaining+a copy of this software and associated documentation files (the+"Software"), to deal in the Software without restriction, including+without limitation the rights to use, copy, modify, merge, publish,+distribute, sublicense, and/or sell copies of the Software, and to+permit persons to whom the Software is furnished to do so, subject to+the following conditions:++The above copyright notice and this permission notice shall be+included in all copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE+LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION+OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION+WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.diff --git a/README.md b/README.mdnew file mode 100644index 00000000..28bc1260--- /dev/null+++ b/README.md@@ -0,0 +1,144 @@+# Blazer++Create and share SQL queries instantly++[View the demo](https://blazerme.herokuapp.com)++Works with PostgreSQL and MySQL++:tangerine: Battle-tested at [Instacart](https://www.instacart.com)++## Features++- **Secure** - works with your authentication system+- **Variables** - get the same insights for multiple values+- **Linked Columns** - link to other pages in your apps or around the web+- **Smart Columns** - get the data your want without all the joins+- **Smart Variables** - no need to remember IDs+- **Charts & Maps** - a picture is worth a thousand words++Documentation coming soon.++## Installation++Add this line to your application’s Gemfile:++```ruby+gem 'blazer'+```++Run:++```sh+rails g blazer:install+rake db:migrate+```++And mount the dashboard in your `config/routes.rb`:++```ruby+mount Blazer::Engine, at: "blazer"+```++Then, specify your database:++```ruby+ENV["BLAZER_DATABASE_URL"]+```++It is **highly, highly recommended** to use a read only user. Keep reading to see how to create one.++## Permissions++### PostgreSQL++Create a user with read only permissions:++```sql+BEGIN;+CREATE ROLE blazer LOGIN PASSWORD 'secret123';+GRANT CONNECT ON DATABASE database_name TO blazer;+GRANT USAGE ON SCHEMA public TO blazer;+COMMIT;+```++It’s highly recommended to protect sensitive information with views. Documentation coming soon.++### MySQL++Create a user with read only permissions:++```sql+GRANT SELECT, SHOW VIEW ON database_name.* TO blazer@’127.0.0.1′ IDENTIFIED BY ‘secret123‘;+FLUSH PRIVILEGES;+```++It’s highly recommended to protect sensitive information with views. Documentation coming soon.++## Authentication++Don’t forget to protect the dashboard in production.++### Basic Authentication++Set the following variables in your environment or an initializer.++```ruby+ENV["BLAZER_USERNAME"] = "andrew"+ENV["BLAZER_PASSWORD"] = "secret"+```++### Devise++```ruby+authenticate :user, lambda{|user| user.admin? } do+ mount Blazer::Engine, at: "blazer"+end+```++## Customization++Change time zone++```ruby+Blazer.time_zone = "Pacific Time (US & Canada)"+```++Turn off audits++```ruby+Blazer.audit = false+```++## TODO++- better readme+- better navigation+- standalone version+- update lock+- warn when database user has write permissions+- advanced permissions+- favorites+- support for multiple data sources++## Thanks++Blazer uses a number of awesome, open source projects.++- [Rails](https://github.com/rails/rails/)+- [jQuery](https://github.com/jquery/jquery)+- [Bootstrap](https://github.com/twbs/bootstrap)+- [Selectize](https://github.com/brianreavis/selectize.js)+- [List.js](https://github.com/javve/list.js)+- [StickyTableHeaders](https://github.com/jmosbech/StickyTableHeaders)+- [Stupid jQuery Table Sort](https://github.com/joequery/Stupid-Table-Plugin)+- [Date Range Picker](https://github.com/dangrossman/bootstrap-daterangepicker)++## Contributing++Everyone is encouraged to help improve this project. Here are a few ways you can help:++- [Report bugs](https://github.com/ankane/blazer/issues)+- Fix bugs and [submit pull requests](https://github.com/ankane/blazer/pulls)+- Write, clarify, or fix documentation+- Suggest or add new featuresdiff --git a/Rakefile b/Rakefilenew file mode 100644index 00000000..809eb561--- /dev/null+++ b/Rakefile@@ -0,0 +1,2 @@+require "bundler/gem_tasks"+diff --git a/app/assets/javascripts/blazer/ace/ace.js b/app/assets/javascripts/blazer/ace/ace.jsnew file mode 100755index 00000000..06573765--- /dev/null+++ b/app/assets/javascripts/blazer/ace/ace.js@@ -0,0 +1,11 @@+(function(){function s(r){var i=function(e,t){return n("",e,t)},s=e;r&&(e[r]||(e[r]={}),s=e[r]);if(!s.define||!s.define.packaged)t.original=s.define,s.define=t,s.define.packaged=!0;if(!s.require||!s.require.packaged)n.original=s.require,s.require=i,s.require.packaged=!0}var ACE_NAMESPACE = "ace",e=function(){return this}();if(!ACE_NAMESPACE&&typeof requirejs!="undefined")return;var t=function(e,n,r){if(typeof e!="string"){t.original?t.original.apply(window,arguments):(console.error("dropping module because define wasn't a string."),console.trace());return}arguments.length==2&&(r=n),t.modules||(t.modules={},t.payloads={}),t.payloads[e]=r,t.modules[e]=null},n=function(e,t,r){if(Object.prototype.toString.call(t)==="[object Array]"){var s=[];for(var o=0,u=t.length;o<u;++o){var a=i(e,t[o]);if(!a&&n.original)return n.original.apply(window,arguments);s.push(a)}r&&r.apply(null,s)}else{if(typeof t=="string"){var f=i(e,t);return!f&&n.original?n.original.apply(window,arguments):(r&&r(),f)}if(n.original)return n.original.apply(window,arguments)}},r=function(e,t){if(t.indexOf("!")!==-1){var n=t.split("!");return r(e,n[0])+"!"+r(e,n[1])}if(t.charAt(0)=="."){var i=e.split("/").slice(0,-1).join("/");t=i+"/"+t;while(t.indexOf(".")!==-1&&s!=t){var s=t;t=t.replace(/\/\.\//,"/").replace(/[^\/]+\/\.\.\//,"")}}return t},i=function(e,i){i=r(e,i);var s=t.modules[i];if(!s){s=t.payloads[i];if(typeof s=="function"){var o={},u={id:i,uri:"",exports:o,packaged:!0},a=function(e,t){return n(i,e,t)},f=s(a,o,u);o=f||u.exports,t.modules[i]=o,delete t.payloads[i]}s=t.modules[i]=o||s}return s};s(ACE_NAMESPACE)})(),ace.define("ace/lib/regexp",["require","exports","module"],function(e,t,n){"use strict";function o(e){return(e.global?"g":"")+(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.extended?"x":"")+(e.sticky?"y":"")}function u(e,t,n){if(Array.prototype.indexOf)return e.indexOf(t,n);for(var r=n||0;r<e.length;r++)if(e[r]===t)return r;return-1}var r={exec:RegExp.prototype.exec,test:RegExp.prototype.test,match:String.prototype.match,replace:String.prototype.replace,split:String.prototype.split},i=r.exec.call(/()??/,"")[1]===undefined,s=function(){var e=/^/g;return r.test.call(e,""),!e.lastIndex}();if(s&&i)return;RegExp.prototype.exec=function(e){var t=r.exec.apply(this,arguments),n,a;if(typeof e=="string"&&t){!i&&t.length>1&&u(t,"")>-1&&(a=RegExp(this.source,r.replace.call(o(this),"g","")),r.replace.call(e.slice(t.index),a,function(){for(var e=1;e<arguments.length-2;e++)arguments[e]===undefined&&(t[e]=undefined)}));if(this._xregexp&&this._xregexp.captureNames)for(var f=1;f<t.length;f++)n=this._xregexp.captureNames[f-1],n&&(t[n]=t[f]);!s&&this.global&&!t[0].length&&this.lastIndex>t.index&&this.lastIndex--}return t},s||(RegExp.prototype.test=function(e){var t=r.exec.call(this,e);return t&&this.global&&!t[0].length&&this.lastIndex>t.index&&this.lastIndex--,!!t})}),ace.define("ace/lib/es5-shim",["require","exports","module"],function(e,t,n){function r(){}function w(e){try{return Object.defineProperty(e,"sentinel",{}),"sentinel"in e}catch(t){}}function H(e){return e=+e,e!==e?e=0:e!==0&&e!==1/0&&e!==-1/0&&(e=(e>0||-1)*Math.floor(Math.abs(e))),e}function B(e){var t=typeof e;return e===null||t==="undefined"||t==="boolean"||t==="number"||t==="string"}function j(e){var t,n,r;if(B(e))return e;n=e.valueOf;if(typeof n=="function"){t=n.call(e);if(B(t))return t}r=e.toString;if(typeof r=="function"){t=r.call(e);if(B(t))return t}throw new TypeError}Function.prototype.bind||(Function.prototype.bind=function(t){var n=this;if(typeof n!="function")throw new TypeError("Function.prototype.bind called on incompatible "+n);var i=u.call(arguments,1),s=function(){if(this instanceof s){var e=n.apply(this,i.concat(u.call(arguments)));return Object(e)===e?e:this}return n.apply(t,i.concat(u.call(arguments)))};return n.prototype&&(r.prototype=n.prototype,s.prototype=new r,r.prototype=null),s});var i=Function.prototype.call,s=Array.prototype,o=Object.prototype,u=s.slice,a=i.bind(o.toString),f=i.bind(o.hasOwnProperty),l,c,h,p,d;if(d=f(o,"__defineGetter__"))l=i.bind(o.__defineGetter__),c=i.bind(o.__defineSetter__),h=i.bind(o.__lookupGetter__),p=i.bind(o.__lookupSetter__);if([1,2].splice(0).length!=2)if(!function(){function e(e){var t=new Array(e+2);return t[0]=t[1]=0,t}var t=[],n;t.splice.apply(t,e(20)),t.splice.apply(t,e(26)),n=t.length,t.splice(5,0,"XXX"),n+1==t.length;if(n+1==t.length)return!0}())Array.prototype.splice=function(e,t){var n=this.length;e>0?e>n&&(e=n):e==void 0?e=0:e<0&&(e=Math.max(n+e,0)),e+t<n||(t=n-e);var r=this.slice(e,e+t),i=u.call(arguments,2),s=i.length;if(e===n)s&&this.push.apply(this,i);else{var o=Math.min(t,n-e),a=e+o,f=a+s-o,l=n-a,c=n-o;if(f<a)for(var h=0;h<l;++h)this[f+h]=this[a+h];else if(f>a)for(h=l;h--;)this[f+h]=this[a+h];if(s&&e===c)this.length=c,this.push.apply(this,i);else{this.length=c+s;for(h=0;h<s;++h)this[e+h]=i[h]}}return r};else{var v=Array.prototype.splice;Array.prototype.splice=function(e,t){return arguments.length?v.apply(this,[e===void 0?0:e,t===void 0?this.length-e:t].concat(u.call(arguments,2))):[]}}Array.isArray||(Array.isArray=function(t){return a(t)=="[object Array]"});var m=Object("a"),g=m[0]!="a"||!(0 in m);Array.prototype.forEach||(Array.prototype.forEach=function(t){var n=F(this),r=g&&a(this)=="[object String]"?this.split(""):n,i=arguments[1],s=-1,o=r.length>>>0;if(a(t)!="[object Function]")throw new TypeError;while(++s<o)s in r&&t.call(i,r[s],s,n)}),Array.prototype.map||(Array.prototype.map=function(t){var n=F(this),r=g&&a(this)=="[object String]"?this.split(""):n,i=r.length>>>0,s=Array(i),o=arguments[1];if(a(t)!="[object Function]")throw new TypeError(t+" is not a function");for(var u=0;u<i;u++)u in r&&(s[u]=t.call(o,r[u],u,n));return s}),Array.prototype.filter||(Array.prototype.filter=function(t){var n=F(this),r=g&&a(this)=="[object String]"?this.split(""):n,i=r.length>>>0,s=[],o,u=arguments[1];if(a(t)!="[object Function]")throw new TypeError(t+" is not a function");for(var f=0;f<i;f++)f in r&&(o=r[f],t.call(u,o,f,n)&&s.push(o));return s}),Array.prototype.every||(Array.prototype.every=function(t){var n=F(this),r=g&&a(this)=="[object String]"?this.split(""):n,i=r.length>>>0,s=arguments[1];if(a(t)!="[object Function]")throw new TypeError(t+" is not a function");for(var o=0;o<i;o++)if(o in r&&!t.call(s,r[o],o,n))return!1;return!0}),Array.prototype.some||(Array.prototype.some=function(t){var n=F(this),r=g&&a(this)=="[object String]"?this.split(""):n,i=r.length>>>0,s=arguments[1];if(a(t)!="[object Function]")throw new TypeError(t+" is not a function");for(var o=0;o<i;o++)if(o in r&&t.call(s,r[o],o,n))return!0;return!1}),Array.prototype.reduce||(Array.prototype.reduce=function(t){var n=F(this),r=g&&a(this)=="[object String]"?this.split(""):n,i=r.length>>>0;if(a(t)!="[object Function]")throw new TypeError(t+" is not a function");if(!i&&arguments.length==1)throw new TypeError("reduce of empty array with no initial value");var s=0,o;if(arguments.length>=2)o=arguments[1];else do{if(s in r){o=r[s++];break}if(++s>=i)throw new TypeError("reduce of empty array with no initial value")}while(!0);for(;s<i;s++)s in r&&(o=t.call(void 0,o,r[s],s,n));return o}),Array.prototype.reduceRight||(Array.prototype.reduceRight=function(t){var n=F(this),r=g&&a(this)=="[object String]"?this.split(""):n,i=r.length>>>0;if(a(t)!="[object Function]")throw new TypeError(t+" is not a function");if(!i&&arguments.length==1)throw new TypeError("reduceRight of empty array with no initial value");var s,o=i-1;if(arguments.length>=2)s=arguments[1];else do{if(o in r){s=r[o--];break}if(--o<0)throw new TypeError("reduceRight of empty array with no initial value")}while(!0);do o in this&&(s=t.call(void 0,s,r[o],o,n));while(o--);return s});if(!Array.prototype.indexOf||[0,1].indexOf(1,2)!=-1)Array.prototype.indexOf=function(t){var n=g&&a(this)=="[object String]"?this.split(""):F(this),r=n.length>>>0;if(!r)return-1;var i=0;arguments.length>1&&(i=H(arguments[1])),i=i>=0?i:Math.max(0,r+i);for(;i<r;i++)if(i in n&&n[i]===t)return i;return-1};if(!Array.prototype.lastIndexOf||[0,1].lastIndexOf(0,-3)!=-1)Array.prototype.lastIndexOf=function(t){var n=g&&a(this)=="[object String]"?this.split(""):F(this),r=n.length>>>0;if(!r)return-1;var i=r-1;arguments.length>1&&(i=Math.min(i,H(arguments[1]))),i=i>=0?i:r-Math.abs(i);for(;i>=0;i--)if(i in n&&t===n[i])return i;return-1};Object.getPrototypeOf||(Object.getPrototypeOf=function(t){return t.__proto__||(t.constructor?t.constructor.prototype:o)});if(!Object.getOwnPropertyDescriptor){var y="Object.getOwnPropertyDescriptor called on a non-object: ";Object.getOwnPropertyDescriptor=function(t,n){if(typeof t!="object"&&typeof t!="function"||t===null)throw new TypeError(y+t);if(!f(t,n))return;var r,i,s;r={enumerable:!0,configurable:!0};if(d){var u=t.__proto__;t.__proto__=o;var i=h(t,n),s=p(t,n);t.__proto__=u;if(i||s)return i&&(r.get=i),s&&(r.set=s),r}return r.value=t[n],r}}Object.getOwnPropertyNames||(Object.getOwnPropertyNames=function(t){return Object.keys(t)});if(!Object.create){var b;Object.prototype.__proto__===null?b=function(){return{__proto__:null}}:b=function(){var e={};for(var t in e)e[t]=null;return e.constructor=e.hasOwnProperty=e.propertyIsEnumerable=e.isPrototypeOf=e.toLocaleString=e.toString=e.valueOf=e.__proto__=null,e},Object.create=function(t,n){var r;if(t===null)r=b();else{if(typeof t!="object")throw new TypeError("typeof prototype["+typeof t+"] != 'object'");var i=function(){};i.prototype=t,r=new i,r.__proto__=t}return n!==void 0&&Object.defineProperties(r,n),r}}if(Object.defineProperty){var E=w({}),S=typeof document=="undefined"||w(document.createElement("div"));if(!E||!S)var x=Object.defineProperty}if(!Object.defineProperty||x){var T="Property description must be an object: ",N="Object.defineProperty called on non-object: ",C="getters & setters can not be defined on this javascript engine";Object.defineProperty=function(t,n,r){if(typeof t!="object"&&typeof t!="function"||t===null)throw new TypeError(N+t);if(typeof r!="object"&&typeof r!="function"||r===null)throw new TypeError(T+r);if(x)try{return x.call(Object,t,n,r)}catch(i){}if(f(r,"value"))if(d&&(h(t,n)||p(t,n))){var s=t.__proto__;t.__proto__=o,delete t[n],t[n]=r.value,t.__proto__=s}else t[n]=r.value;else{if(!d)throw new TypeError(C);f(r,"get")&&l(t,n,r.get),f(r,"set")&&c(t,n,r.set)}return t}}Object.defineProperties||(Object.defineProperties=function(t,n){for(var r in n)f(n,r)&&Object.defineProperty(t,r,n[r]);return t}),Object.seal||(Object.seal=function(t){return t}),Object.freeze||(Object.freeze=function(t){return t});try{Object.freeze(function(){})}catch(k){Object.freeze=function(t){return function(n){return typeof n=="function"?n:t(n)}}(Object.freeze)}Object.preventExtensions||(Object.preventExtensions=function(t){return t}),Object.isSealed||(Object.isSealed=function(t){return!1}),Object.isFrozen||(Object.isFrozen=function(t){return!1}),Object.isExtensible||(Object.isExtensible=function(t){if(Object(t)===t)throw new TypeError;var n="";while(f(t,n))n+="?";t[n]=!0;var r=f(t,n);return delete t[n],r});if(!Object.keys){var L=!0,A=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],O=A.length;for(var M in{toString:null})L=!1;Object.keys=function I(e){if(typeof e!="object"&&typeof e!="function"||e===null)throw new TypeError("Object.keys called on a non-object");var I=[];for(var t in e)f(e,t)&&I.push(t);if(L)for(var n=0,r=O;n<r;n++){var i=A[n];f(e,i)&&I.push(i)}return I}}Date.now||(Date.now=function(){return(new Date).getTime()});var _=" \n\f\r \u00a0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029\ufeff";if(!String.prototype.trim||_.trim()){_="["+_+"]";var D=new RegExp("^"+_+_+"*"),P=new RegExp(_+_+"*$");String.prototype.trim=function(){return String(this).replace(D,"").replace(P,"")}}var F=function(e){if(e==null)throw new TypeError("can't convert "+e+" to object");return Object(e)}}),ace.define("ace/lib/fixoldbrowsers",["require","exports","module","ace/lib/regexp","ace/lib/es5-shim"],function(e,t,n){"use strict";e("./regexp"),e("./es5-shim")}),ace.define("ace/lib/dom",["require","exports","module"],function(e,t,n){"use strict";if(typeof document=="undefined")return;var r="http://www.w3.org/1999/xhtml";t.getDocumentHead=function(e){return e||(e=document),e.head||e.getElementsByTagName("head")[0]||e.documentElement},t.createElement=function(e,t){return document.createElementNS?document.createElementNS(t||r,e):document.createElement(e)},t.hasCssClass=function(e,t){var n=(e.className||"").split(/\s+/g);return n.indexOf(t)!==-1},t.addCssClass=function(e,n){t.hasCssClass(e,n)||(e.className+=" "+n)},t.removeCssClass=function(e,t){var n=e.className.split(/\s+/g);for(;;){var r=n.indexOf(t);if(r==-1)break;n.splice(r,1)}e.className=n.join(" ")},t.toggleCssClass=function(e,t){var n=e.className.split(/\s+/g),r=!0;for(;;){var i=n.indexOf(t);if(i==-1)break;r=!1,n.splice(i,1)}return r&&n.push(t),e.className=n.join(" "),r},t.setCssClass=function(e,n,r){r?t.addCssClass(e,n):t.removeCssClass(e,n)},t.hasCssString=function(e,t){var n=0,r;t=t||document;if(t.createStyleSheet&&(r=t.styleSheets)){while(n<r.length)if(r[n++].owningElement.id===e)return!0}else if(r=t.getElementsByTagName("style"))while(n<r.length)if(r[n++].id===e)return!0;return!1},t.importCssString=function(n,i,s){s=s||document;if(i&&t.hasCssString(i,s))return null;var o;s.createStyleSheet?(o=s.createStyleSheet(),o.cssText=n,i&&(o.owningElement.id=i)):(o=s.createElementNS?s.createElementNS(r,"style"):s.createElement("style"),o.appendChild(s.createTextNode(n)),i&&(o.id=i),t.getDocumentHead(s).appendChild(o))},t.importCssStylsheet=function(e,n){if(n.createStyleSheet)n.createStyleSheet(e);else{var r=t.createElement("link");r.rel="stylesheet",r.href=e,t.getDocumentHead(n).appendChild(r)}},t.getInnerWidth=function(e){return parseInt(t.computedStyle(e,"paddingLeft"),10)+parseInt(t.computedStyle(e,"paddingRight"),10)+e.clientWidth},t.getInnerHeight=function(e){return parseInt(t.computedStyle(e,"paddingTop"),10)+parseInt(t.computedStyle(e,"paddingBottom"),10)+e.clientHeight},window.pageYOffset!==undefined?(t.getPageScrollTop=function(){return window.pageYOffset},t.getPageScrollLeft=function(){return window.pageXOffset}):(t.getPageScrollTop=function(){return document.body.scrollTop},t.getPageScrollLeft=function(){return document.body.scrollLeft}),window.getComputedStyle?t.computedStyle=function(e,t){return t?(window.getComputedStyle(e,"")||{})[t]||"":window.getComputedStyle(e,"")||{}}:t.computedStyle=function(e,t){return t?e.currentStyle[t]:e.currentStyle},t.scrollbarWidth=function(e){var n=t.createElement("ace_inner");n.style.width="100%",n.style.minWidth="0px",n.style.height="200px",n.style.display="block";var r=t.createElement("ace_outer"),i=r.style;i.position="absolute",i.left="-10000px",i.overflow="hidden",i.width="200px",i.minWidth="0px",i.height="150px",i.display="block",r.appendChild(n);var s=e.documentElement;s.appendChild(r);var o=n.offsetWidth;i.overflow="scroll";var u=n.offsetWidth;return o==u&&(u=r.clientWidth),s.removeChild(r),o-u},t.setInnerHtml=function(e,t){var n=e.cloneNode(!1);return n.innerHTML=t,e.parentNode.replaceChild(n,e),n},"textContent"in document.documentElement?(t.setInnerText=function(e,t){e.textContent=t},t.getInnerText=function(e){return e.textContent}):(t.setInnerText=function(e,t){e.innerText=t},t.getInnerText=function(e){return e.innerText}),t.getParentWindow=function(e){return e.defaultView||e.parentWindow}}),ace.define("ace/lib/oop",["require","exports","module"],function(e,t,n){"use strict";t.inherits=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})},t.mixin=function(e,t){for(var n in t)e[n]=t[n];return e},t.implement=function(e,n){t.mixin(e,n)}}),ace.define("ace/lib/keys",["require","exports","module","ace/lib/oop"],function(e,t,n){"use strict";var r=e("./oop"),i=function(){var e={MODIFIER_KEYS:{16:"Shift",17:"Ctrl",18:"Alt",224:"Meta"},KEY_MODS:{ctrl:1,alt:2,option:2,shift:4,"super":8,meta:8,command:8,cmd:8},FUNCTION_KEYS:{8:"Backspace",9:"Tab",13:"Return",19:"Pause",27:"Esc",32:"Space",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"Left",38:"Up",39:"Right",40:"Down",44:"Print",45:"Insert",46:"Delete",96:"Numpad0",97:"Numpad1",98:"Numpad2",99:"Numpad3",100:"Numpad4",101:"Numpad5",102:"Numpad6",103:"Numpad7",104:"Numpad8",105:"Numpad9","-13":"NumpadEnter",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"Numlock",145:"Scrolllock"},PRINTABLE_KEYS:{32:" ",48:"0",49:"1",50:"2",51:"3",52:"4",53:"5",54:"6",55:"7",56:"8",57:"9",59:";",61:"=",65:"a",66:"b",67:"c",68:"d",69:"e",70:"f",71:"g",72:"h",73:"i",74:"j",75:"k",76:"l",77:"m",78:"n",79:"o",80:"p",81:"q",82:"r",83:"s",84:"t",85:"u",86:"v",87:"w",88:"x",89:"y",90:"z",107:"+",109:"-",110:".",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'"}},t,n;for(n in e.FUNCTION_KEYS)t=e.FUNCTION_KEYS[n].toLowerCase(),e[t]=parseInt(n,10);for(n in e.PRINTABLE_KEYS)t=e.PRINTABLE_KEYS[n].toLowerCase(),e[t]=parseInt(n,10);return r.mixin(e,e.MODIFIER_KEYS),r.mixin(e,e.PRINTABLE_KEYS),r.mixin(e,e.FUNCTION_KEYS),e.enter=e["return"],e.escape=e.esc,e.del=e["delete"],e[173]="-",function(){var t=["cmd","ctrl","alt","shift"];for(var n=Math.pow(2,t.length);n--;)e.KEY_MODS[n]=t.filter(function(t){return n&e.KEY_MODS[t]}).join("-")+"-"}(),e}();r.mixin(t,i),t.keyCodeToString=function(e){var t=i[e];return typeof t!="string"&&(t=String.fromCharCode(e)),t.toLowerCase()}}),ace.define("ace/lib/useragent",["require","exports","module"],function(e,t,n){"use strict";t.OS={LINUX:"LINUX",MAC:"MAC",WINDOWS:"WINDOWS"},t.getOS=function(){return t.isMac?t.OS.MAC:t.isLinux?t.OS.LINUX:t.OS.WINDOWS};if(typeof navigator!="object")return;var r=(navigator.platform.match(/mac|win|linux/i)||["other"])[0].toLowerCase(),i=navigator.userAgent;t.isWin=r=="win",t.isMac=r=="mac",t.isLinux=r=="linux",t.isIE=navigator.appName=="Microsoft Internet Explorer"||navigator.appName.indexOf("MSAppHost")>=0?parseFloat((i.match(/(?:MSIE |Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]):parseFloat((i.match(/(?:Trident\/[0-9]+[\.0-9]+;.*rv:)([0-9]+[\.0-9]+)/)||[])[1]),t.isOldIE=t.isIE&&t.isIE<9,t.isGecko=t.isMozilla=(window.Controllers||window.controllers)&&window.navigator.product==="Gecko",t.isOldGecko=t.isGecko&&parseInt((i.match(/rv\:(\d+)/)||[])[1],10)<4,t.isOpera=window.opera&&Object.prototype.toString.call(window.opera)=="[object Opera]",t.isWebKit=parseFloat(i.split("WebKit/")[1])||undefined,t.isChrome=parseFloat(i.split(" Chrome/")[1])||undefined,t.isAIR=i.indexOf("AdobeAIR")>=0,t.isIPad=i.indexOf("iPad")>=0,t.isTouchPad=i.indexOf("TouchPad")>=0,t.isChromeOS=i.indexOf(" CrOS ")>=0}),ace.define("ace/lib/event",["require","exports","module","ace/lib/keys","ace/lib/useragent"],function(e,t,n){"use strict";function o(e,t,n){var o=s(t);if(!i.isMac&&u){if(u[91]||u[92])o|=8;if(u.altGr){if((3&o)==3)return;u.altGr=0}if(n===18||n===17){var f=t.location||t.keyLocation;if(n===17&&f===1)a=t.timeStamp;else if(n===18&&o===3&&f===2){var l=-a;a=t.timeStamp,l+=a,l<3&&(u.altGr=!0)}}}if(n in r.MODIFIER_KEYS){switch(r.MODIFIER_KEYS[n]){case"Alt":o=2;break;case"Shift":o=4;break;case"Ctrl":o=1;break;default:o=8}n=-1}o&8&&(n===91||n===93)&&(n=-1);if(!o&&n===13)if(t.location||t.keyLocation===3){e(t,o,-n);if(t.defaultPrevented)return}if(i.isChromeOS&&o&8){e(t,o,n);if(t.defaultPrevented)return;o&=-9}return!!o||n in r.FUNCTION_KEYS||n in r.PRINTABLE_KEYS?e(t,o,n):!1}var r=e("./keys"),i=e("./useragent");t.addListener=function(e,t,n){if(e.addEventListener)return e.addEventListener(t,n,!1);if(e.attachEvent){var r=function(){n.call(e,window.event)};n._wrapper=r,e.attachEvent("on"+t,r)}},t.removeListener=function(e,t,n){if(e.removeEventListener)return e.removeEventListener(t,n,!1);e.detachEvent&&e.detachEvent("on"+t,n._wrapper||n)},t.stopEvent=function(e){return t.stopPropagation(e),t.preventDefault(e),!1},t.stopPropagation=function(e){e.stopPropagation?e.stopPropagation():e.cancelBubble=!0},t.preventDefault=function(e){e.preventDefault?e.preventDefault():e.returnValue=!1},t.getButton=function(e){return e.type=="dblclick"?0:e.type=="contextmenu"||i.isMac&&e.ctrlKey&&!e.altKey&&!e.shiftKey?2:e.preventDefault?e.button:{1:0,2:2,4:1}[e.button]},t.capture=function(e,n,r){function i(e){n&&n(e),r&&r(e),t.removeListener(document,"mousemove",n,!0),t.removeListener(document,"mouseup",i,!0),t.removeListener(document,"dragstart",i,!0)}return t.addListener(document,"mousemove",n,!0),t.addListener(document,"mouseup",i,!0),t.addListener(document,"dragstart",i,!0),i},t.addMouseWheelListener=function(e,n){"onmousewheel"in e?t.addListener(e,"mousewheel",function(e){var t=8;e.wheelDeltaX!==undefined?(e.wheelX=-e.wheelDeltaX/t,e.wheelY=-e.wheelDeltaY/t):(e.wheelX=0,e.wheelY=-e.wheelDelta/t),n(e)}):"onwheel"in e?t.addListener(e,"wheel",function(e){var t=.35;switch(e.deltaMode){case e.DOM_DELTA_PIXEL:e.wheelX=e.deltaX*t||0,e.wheelY=e.deltaY*t||0;break;case e.DOM_DELTA_LINE:case e.DOM_DELTA_PAGE:e.wheelX=(e.deltaX||0)*5,e.wheelY=(e.deltaY||0)*5}n(e)}):t.addListener(e,"DOMMouseScroll",function(e){e.axis&&e.axis==e.HORIZONTAL_AXIS?(e.wheelX=(e.detail||0)*5,e.wheelY=0):(e.wheelX=0,e.wheelY=(e.detail||0)*5),n(e)})},t.addMultiMouseDownListener=function(e,n,r,s){var o=0,u,a,f,l={2:"dblclick",3:"tripleclick",4:"quadclick"};t.addListener(e,"mousedown",function(e){t.getButton(e)!==0?o=0:e.detail>1?(o++,o>4&&(o=1)):o=1;if(i.isIE){var c=Math.abs(e.clientX-u)>5||Math.abs(e.clientY-a)>5;if(!f||c)o=1;f&&clearTimeout(f),f=setTimeout(function(){f=null},n[o-1]||600),o==1&&(u=e.clientX,a=e.clientY)}e._clicks=o,r[s]("mousedown",e);if(o>4)o=0;else if(o>1)return r[s](l[o],e)}),i.isOldIE&&t.addListener(e,"dblclick",function(e){o=2,f&&clearTimeout(f),f=setTimeout(function(){f=null},n[o-1]||600),r[s]("mousedown",e),r[s](l[o],e)})};var s=!i.isMac||!i.isOpera||"KeyboardEvent"in window?function(e){return 0|(e.ctrlKey?1:0)|(e.altKey?2:0)|(e.shiftKey?4:0)|(e.metaKey?8:0)}:function(e){return 0|(e.metaKey?1:0)|(e.altKey?2:0)|(e.shiftKey?4:0)|(e.ctrlKey?8:0)};t.getModifierString=function(e){return r.KEY_MODS[s(e)]};var u=null,a=0;t.addCommandKeyListener=function(e,n){var r=t.addListener;if(i.isOldGecko||i.isOpera&&!("KeyboardEvent"in window)){var s=null;r(e,"keydown",function(e){s=e.keyCode}),r(e,"keypress",function(e){return o(n,e,s)})}else{var a=null;r(e,"keydown",function(e){u[e.keyCode]=!0;var t=o(n,e,e.keyCode);return a=e.defaultPrevented,t}),r(e,"keypress",function(e){a&&(e.ctrlKey||e.altKey||e.shiftKey||e.metaKey)&&(t.stopEvent(e),a=null)}),r(e,"keyup",function(e){u[e.keyCode]=null}),u||(u=Object.create(null),r(window,"focus",function(e){u=Object.create(null)}))}};if(window.postMessage&&!i.isOldIE){var f=1;t.nextTick=function(e,n){n=n||window;var r="zero-timeout-message-"+f;t.addListener(n,"message",function i(s){s.data==r&&(t.stopPropagation(s),t.removeListener(n,"message",i),e())}),n.postMessage(r,"*")}}t.nextFrame=window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||window.msRequestAnimationFrame||window.oRequestAnimationFrame,t.nextFrame?t.nextFrame=t.nextFrame.bind(window):t.nextFrame=function(e){setTimeout(e,17)}}),ace.define("ace/lib/lang",["require","exports","module"],function(e,t,n){"use strict";t.last=function(e){return e[e.length-1]},t.stringReverse=function(e){return e.split("").reverse().join("")},t.stringRepeat=function(e,t){var n="";while(t>0){t&1&&(n+=e);if(t>>=1)e+=e}return n};var r=/^\s\s*/,i=/\s\s*$/;t.stringTrimLeft=function(e){return e.replace(r,"")},t.stringTrimRight=function(e){return e.replace(i,"")},t.copyObject=function(e){var t={};for(var n in e)t[n]=e[n];return t},t.copyArray=function(e){var t=[];for(var n=0,r=e.length;n<r;n++)e[n]&&typeof e[n]=="object"?t[n]=this.copyObject(e[n]):t[n]=e[n];return t},t.deepCopy=function(e){if(typeof e!="object"||!e)return e;var n=e.constructor;if(n===RegExp)return e;var r=n();for(var i in e)typeof e[i]=="object"?r[i]=t.deepCopy(e[i]):r[i]=e[i];return r},t.arrayToMap=function(e){var t={};for(var n=0;n<e.length;n++)t[e[n]]=1;return t},t.createMap=function(e){var t=Object.create(null);for(var n in e)t[n]=e[n];return t},t.arrayRemove=function(e,t){for(var n=0;n<=e.length;n++)t===e[n]&&e.splice(n,1)},t.escapeRegExp=function(e){return e.replace(/([.*+?^${}()|[\]\/\\])/g,"\\$1")},t.escapeHTML=function(e){return e.replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(/</g,"<")},t.getMatchOffsets=function(e,t){var n=[];return e.replace(t,function(e){n.push({offset:arguments[arguments.length-2],length:e.length})}),n},t.deferredCall=function(e){var t=null,n=function(){t=null,e()},r=function(e){return r.cancel(),t=setTimeout(n,e||0),r};return r.schedule=r,r.call=function(){return this.cancel(),e(),r},r.cancel=function(){return clearTimeout(t),t=null,r},r.isPending=function(){return t},r},t.delayedCall=function(e,t){var n=null,r=function(){n=null,e()},i=function(e){n==null&&(n=setTimeout(r,e||t))};return i.delay=function(e){n&&clearTimeout(n),n=setTimeout(r,e||t)},i.schedule=i,i.call=function(){this.cancel(),e()},i.cancel=function(){n&&clearTimeout(n),n=null},i.isPending=function(){return n},i}}),ace.define("ace/keyboard/textinput",["require","exports","module","ace/lib/event","ace/lib/useragent","ace/lib/dom","ace/lib/lang"],function(e,t,n){"use strict";var r=e("../lib/event"),i=e("../lib/useragent"),s=e("../lib/dom"),o=e("../lib/lang"),u=i.isChrome<18,a=i.isIE,f=function(e,t){function b(e){if(h)return;if(k)t=0,r=e?0:n.value.length-1;else var t=e?2:1,r=2;try{n.setSelectionRange(t,r)}catch(i){}}function w(){if(h)return;n.value=f,i.isWebKit&&y.schedule()}function q(){setTimeout(function(){p&&(n.style.cssText=p,p=""),t.renderer.$keepTextAreaAtCursor==null&&(t.renderer.$keepTextAreaAtCursor=!0,t.renderer.$moveTextAreaToCursor())},0)}var n=s.createElement("textarea");n.className="ace_text-input",i.isTouchPad&&n.setAttribute("x-palm-disable-auto-cap",!0),n.wrap="off",n.autocorrect="off",n.autocapitalize="off",n.spellcheck=!1,n.style.opacity="0",e.insertBefore(n,e.firstChild);var f="",l=!1,c=!1,h=!1,p="",d=!0;try{var v=document.activeElement===n}catch(m){}r.addListener(n,"blur",function(){t.onBlur(),v=!1}),r.addListener(n,"focus",function(){v=!0,t.onFocus(),b()}),this.focus=function(){n.focus()},this.blur=function(){n.blur()},this.isFocused=function(){return v};var g=o.delayedCall(function(){v&&b(d)}),y=o.delayedCall(function(){h||(n.value=f,v&&b())});i.isWebKit||t.addEventListener("changeSelection",function(){t.selection.isEmpty()!=d&&(d=!d,g.schedule())}),w(),v&&t.onFocus();var E=function(e){return e.selectionStart===0&&e.selectionEnd===e.value.length};!n.setSelectionRange&&n.createTextRange&&(n.setSelectionRange=function(e,t){var n=this.createTextRange();n.collapse(!0),n.moveStart("character",e),n.moveEnd("character",t),n.select()},E=function(e){try{var t=e.ownerDocument.selection.createRange()}catch(n){}return!t||t.parentElement()!=e?!1:t.text==e.value});if(i.isOldIE){var S=!1,x=function(e){if(S)return;var t=n.value;if(h||!t||t==f)return;if(e&&t==f[0])return T.schedule();A(t),S=!0,w(),S=!1},T=o.delayedCall(x);r.addListener(n,"propertychange",x);var N={13:1,27:1};r.addListener(n,"keyup",function(e){h&&(!n.value||N[e.keyCode])&&setTimeout(F,0);if((n.value.charCodeAt(0)||0)<129)return T.call();h?j():B()}),r.addListener(n,"keydown",function(e){T.schedule(50)})}var C=function(e){l?l=!1:E(n)?(t.selectAll(),b()):k&&b(t.selection.isEmpty())},k=null;this.setInputHandler=function(e){k=e},this.getInputHandler=function(){return k};var L=!1,A=function(e){k&&(e=k(e),k=null),c?(b(),e&&t.onPaste(e),c=!1):e==f.charAt(0)?L?t.execCommand("del",{source:"ace"}):t.execCommand("backspace",{source:"ace"}):(e.substring(0,2)==f?e=e.substr(2):e.charAt(0)==f.charAt(0)?e=e.substr(1):e.charAt(e.length-1)==f.charAt(0)&&(e=e.slice(0,-1)),e.charAt(e.length-1)==f.charAt(0)&&(e=e.slice(0,-1)),e&&t.onTextInput(e)),L&&(L=!1)},O=function(e){if(h)return;var t=n.value;A(t),w()},M=function(e,t){var n=e.clipboardData||window.clipboardData;if(!n||u)return;var r=a?"Text":"text/plain";return t?n.setData(r,t)!==!1:n.getData(r)},_=function(e,i){var s=t.getCopyText();if(!s)return r.preventDefault(e);M(e,s)?(i?t.onCut():t.onCopy(),r.preventDefault(e)):(l=!0,n.value=s,n.select(),setTimeout(function(){l=!1,w(),b(),i?t.onCut():t.onCopy()}))},D=function(e){_(e,!0)},P=function(e){_(e,!1)},H=function(e){var s=M(e);typeof s=="string"?(s&&t.onPaste(s),i.isIE&&setTimeout(b),r.preventDefault(e)):(n.value="",c=!0)};r.addCommandKeyListener(n,t.onCommandKey.bind(t)),r.addListener(n,"select",C),r.addListener(n,"input",O),r.addListener(n,"cut",D),r.addListener(n,"copy",P),r.addListener(n,"paste",H),(!("oncut"in n)||!("oncopy"in n)||!("onpaste"in n))&&r.addListener(e,"keydown",function(e){if(i.isMac&&!e.metaKey||!e.ctrlKey)return;switch(e.keyCode){case 67:P(e);break;case 86:H(e);break;case 88:D(e)}});var B=function(e){if(h||!t.onCompositionStart||t.$readOnly)return;h={},t.onCompositionStart(),setTimeout(j,0),t.on("mousedown",F),t.selection.isEmpty()||(t.insert(""),t.session.markUndoGroup(),t.selection.clearSelection()),t.session.markUndoGroup()},j=function(){if(!h||!t.onCompositionUpdate||t.$readOnly)return;var e=n.value.replace(/\x01/g,"");if(h.lastValue===e)return;t.onCompositionUpdate(e),h.lastValue&&t.undo(),h.lastValue=e;if(h.lastValue){var r=t.selection.getRange();t.insert(h.lastValue),t.session.markUndoGroup(),h.range=t.selection.getRange(),t.selection.setRange(r),t.selection.clearSelection()}},F=function(e){if(!t.onCompositionEnd||t.$readOnly)return;var r=h;h=!1;var i=setTimeout(function(){i=null;var e=n.value.replace(/\x01/g,"");if(h)return;e==r.lastValue?w():!r.lastValue&&e&&(w(),A(e))});k=function(n){return i&&clearTimeout(i),n=n.replace(/\x01/g,""),n==r.lastValue?"":(r.lastValue&&i&&t.undo(),n)},t.onCompositionEnd(),t.removeListener("mousedown",F),e.type=="compositionend"&&r.range&&t.selection.setRange(r.range)},I=o.delayedCall(j,50);r.addListener(n,"compositionstart",B),i.isGecko?r.addListener(n,"text",function(){I.schedule()}):(r.addListener(n,"keyup",function(){I.schedule()}),r.addListener(n,"keydown",function(){I.schedule()})),r.addListener(n,"compositionend",F),this.getElement=function(){return n},this.setReadOnly=function(e){n.readOnly=e},this.onContextMenu=function(e){L=!0,b(t.selection.isEmpty()),t._emit("nativecontextmenu",{target:t,domEvent:e}),this.moveToMouse(e,!0)},this.moveToMouse=function(e,o){p||(p=n.style.cssText),n.style.cssText=(o?"z-index:100000;":"")+"height:"+n.style.height+";"+(i.isIE?"opacity:0.1;":"");var u=t.container.getBoundingClientRect(),a=s.computedStyle(t.container),f=u.top+(parseInt(a.borderTopWidth)||0),l=u.left+(parseInt(u.borderLeftWidth)||0),c=u.bottom-f-n.clientHeight-2,h=function(e){n.style.left=e.clientX-l-2+"px",n.style.top=Math.min(e.clientY-f-2,c)+"px"};h(e);if(e.type!="mousedown")return;t.renderer.$keepTextAreaAtCursor&&(t.renderer.$keepTextAreaAtCursor=null),i.isWin&&r.capture(t.container,h,q)},this.onContextMenuClose=q;var R=function(e){t.textInput.onContextMenu(e),q()};r.addListener(t.renderer.scroller,"contextmenu",R),r.addListener(n,"contextmenu",R)};t.TextInput=f}),ace.define("ace/mouse/default_handlers",["require","exports","module","ace/lib/dom","ace/lib/event","ace/lib/useragent"],function(e,t,n){"use strict";function u(e){e.$clickSelection=null;var t=e.editor;t.setDefaultHandler("mousedown",this.onMouseDown.bind(e)),t.setDefaultHandler("dblclick",this.onDoubleClick.bind(e)),t.setDefaultHandler("tripleclick",this.onTripleClick.bind(e)),t.setDefaultHandler("quadclick",this.onQuadClick.bind(e)),t.setDefaultHandler("mousewheel",this.onMouseWheel.bind(e));var n=["select","startSelect","selectEnd","selectAllEnd","selectByWordsEnd","selectByLinesEnd","dragWait","dragWaitEnd","focusWait"];n.forEach(function(t){e[t]=this[t]},this),e.selectByLines=this.extendSelectionBy.bind(e,"getLineRange"),e.selectByWords=this.extendSelectionBy.bind(e,"getWordRange")}function a(e,t,n,r){return Math.sqrt(Math.pow(n-e,2)+Math.pow(r-t,2))}function f(e,t){if(e.start.row==e.end.row)var n=2*t.column-e.start.column-e.end.column;else if(e.start.row==e.end.row-1&&!e.start.column&&!e.end.column)var n=t.column-4;else var n=2*t.row-e.start.row-e.end.row;return n<0?{cursor:e.start,anchor:e.end}:{cursor:e.end,anchor:e.start}}var r=e("../lib/dom"),i=e("../lib/event"),s=e("../lib/useragent"),o=0;(function(){this.onMouseDown=function(e){var t=e.inSelection(),n=e.getDocumentPosition();this.mousedownEvent=e;var r=this.editor,i=e.getButton();if(i!==0){var s=r.getSelectionRange(),o=s.isEmpty();o&&r.selection.moveToPosition(n),r.textInput.onContextMenu(e.domEvent);return}this.mousedownEvent.time=Date.now();if(t&&!r.isFocused()){r.focus();if(this.$focusTimout&&!this.$clickSelection&&!r.inMultiSelectMode){this.setState("focusWait"),this.captureMouse(e);return}}return this.captureMouse(e),this.startSelect(n,e.domEvent._clicks>1),e.preventDefault()},this.startSelect=function(e,t){e=e||this.editor.renderer.screenToTextCoordinates(this.x,this.y);var n=this.editor;this.mousedownEvent.getShiftKey()?n.selection.selectToPosition(e):t||n.selection.moveToPosition(e),t||this.select(),n.renderer.scroller.setCapture&&n.renderer.scroller.setCapture(),n.setStyle("ace_selecting"),this.setState("select")},this.select=function(){var e,t=this.editor,n=t.renderer.screenToTextCoordinates(this.x,this.y);if(this.$clickSelection){var r=this.$clickSelection.comparePoint(n);if(r==-1)e=this.$clickSelection.end;else if(r==1)e=this.$clickSelection.start;else{var i=f(this.$clickSelection,n);n=i.cursor,e=i.anchor}t.selection.setSelectionAnchor(e.row,e.column)}t.selection.selectToPosition(n),t.renderer.scrollCursorIntoView()},this.extendSelectionBy=function(e){var t,n=this.editor,r=n.renderer.screenToTextCoordinates(this.x,this.y),i=n.selection[e](r.row,r.column);if(this.$clickSelection){var s=this.$clickSelection.comparePoint(i.start),o=this.$clickSelection.comparePoint(i.end);if(s==-1&&o<=0){t=this.$clickSelection.end;if(i.end.row!=r.row||i.end.column!=r.column)r=i.start}else if(o==1&&s>=0){t=this.$clickSelection.start;if(i.start.row!=r.row||i.start.column!=r.column)r=i.end}else if(s==-1&&o==1)r=i.end,t=i.start;else{var u=f(this.$clickSelection,r);r=u.cursor,t=u.anchor}n.selection.setSelectionAnchor(t.row,t.column)}n.selection.selectToPosition(r),n.renderer.scrollCursorIntoView()},this.selectEnd=this.selectAllEnd=this.selectByWordsEnd=this.selectByLinesEnd=function(){this.$clickSelection=null,this.editor.unsetStyle("ace_selecting"),this.editor.renderer.scroller.releaseCapture&&this.editor.renderer.scroller.releaseCapture()},this.focusWait=function(){var e=a(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y),t=Date.now();(e>o||t-this.mousedownEvent.time>this.$focusTimout)&&this.startSelect(this.mousedownEvent.getDocumentPosition())},this.onDoubleClick=function(e){var t=e.getDocumentPosition(),n=this.editor,r=n.session,i=r.getBracketRange(t);i?(i.isEmpty()&&(i.start.column--,i.end.column++),this.setState("select")):(i=n.selection.getWordRange(t.row,t.column),this.setState("selectByWords")),this.$clickSelection=i,this.select()},this.onTripleClick=function(e){var t=e.getDocumentPosition(),n=this.editor;this.setState("selectByLines");var r=n.getSelectionRange();r.isMultiLine()&&r.contains(t.row,t.column)?(this.$clickSelection=n.selection.getLineRange(r.start.row),this.$clickSelection.end=n.selection.getLineRange(r.end.row).end):this.$clickSelection=n.selection.getLineRange(t.row),this.select()},this.onQuadClick=function(e){var t=this.editor;t.selectAll(),this.$clickSelection=t.getSelectionRange(),this.setState("selectAll")},this.onMouseWheel=function(e){if(e.getAccelKey())return;e.getShiftKey()&&e.wheelY&&!e.wheelX&&(e.wheelX=e.wheelY,e.wheelY=0);var t=e.domEvent.timeStamp,n=t-(this.$lastScrollTime||0),r=this.editor,i=r.renderer.isScrollableBy(e.wheelX*e.speed,e.wheelY*e.speed);if(i||n<200)return this.$lastScrollTime=t,r.renderer.scrollBy(e.wheelX*e.speed,e.wheelY*e.speed),e.stop()}}).call(u.prototype),t.DefaultHandlers=u}),ace.define("ace/tooltip",["require","exports","module","ace/lib/oop","ace/lib/dom"],function(e,t,n){"use strict";function s(e){this.isOpen=!1,this.$element=null,this.$parentNode=e}var r=e("./lib/oop"),i=e("./lib/dom");(function(){this.$init=function(){return this.$element=i.createElement("div"),this.$element.className="ace_tooltip",this.$element.style.display="none",this.$parentNode.appendChild(this.$element),this.$element},this.getElement=function(){return this.$element||this.$init()},this.setText=function(e){i.setInnerText(this.getElement(),e)},this.setHtml=function(e){this.getElement().innerHTML=e},this.setPosition=function(e,t){this.getElement().style.left=e+"px",this.getElement().style.top=t+"px"},this.setClassName=function(e){i.addCssClass(this.getElement(),e)},this.show=function(e,t,n){e!=null&&this.setText(e),t!=null&&n!=null&&this.setPosition(t,n),this.isOpen||(this.getElement().style.display="block",this.isOpen=!0)},this.hide=function(){this.isOpen&&(this.getElement().style.display="none",this.isOpen=!1)},this.getHeight=function(){return this.getElement().offsetHeight},this.getWidth=function(){return this.getElement().offsetWidth}}).call(s.prototype),t.Tooltip=s}),ace.define("ace/mouse/default_gutter_handler",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/event","ace/tooltip"],function(e,t,n){"use strict";function u(e){function l(){var r=u.getDocumentPosition().row,s=n.$annotations[r];if(!s)return c();var o=t.session.getLength();if(r==o){var a=t.renderer.pixelToScreenCoordinates(0,u.y).row,l=u.$pos;if(a>t.session.documentToScreenRow(l.row,l.column))return c()}if(f==s)return;f=s.text.join("<br/>"),i.setHtml(f),i.show(),t.on("mousewheel",c);if(e.$tooltipFollowsMouse)h(u);else{var p=n.$cells[t.session.documentToScreenRow(r,0)].element,d=p.getBoundingClientRect(),v=i.getElement().style;v.left=d.right+"px",v.top=d.bottom+"px"}}function c(){o&&(o=clearTimeout(o)),f&&(i.hide(),f=null,t.removeEventListener("mousewheel",c))}function h(e){i.setPosition(e.x,e.y)}var t=e.editor,n=t.renderer.$gutterLayer,i=new a(t.container);e.editor.setDefaultHandler("guttermousedown",function(r){if(!t.isFocused()||r.getButton()!=0)return;var i=n.getRegion(r);if(i=="foldWidgets")return;var s=r.getDocumentPosition().row,o=t.session.selection;if(r.getShiftKey())o.selectTo(s,0);else{if(r.domEvent.detail==2)return t.selectAll(),r.preventDefault();e.$clickSelection=t.selection.getLineRange(s)}return e.setState("selectByLines"),e.captureMouse(r),r.preventDefault()});var o,u,f;e.editor.setDefaultHandler("guttermousemove",function(t){var n=t.domEvent.target||t.domEvent.srcElement;if(r.hasCssClass(n,"ace_fold-widget"))return c();f&&e.$tooltipFollowsMouse&&h(t),u=t;if(o)return;o=setTimeout(function(){o=null,u&&!e.isMousePressed?l():c()},50)}),s.addListener(t.renderer.$gutter,"mouseout",function(e){u=null;if(!f||o)return;o=setTimeout(function(){o=null,c()},50)}),t.on("changeSession",c)}function a(e){o.call(this,e)}var r=e("../lib/dom"),i=e("../lib/oop"),s=e("../lib/event"),o=e("../tooltip").Tooltip;i.inherits(a,o),function(){this.setPosition=function(e,t){var n=window.innerWidth||document.documentElement.clientWidth,r=window.innerHeight||document.documentElement.clientHeight,i=this.getWidth(),s=this.getHeight();e+=15,t+=15,e+i>n&&(e-=e+i-n),t+s>r&&(t-=20+s),o.prototype.setPosition.call(this,e,t)}}.call(a.prototype),t.GutterHandler=u}),ace.define("ace/mouse/mouse_event",["require","exports","module","ace/lib/event","ace/lib/useragent"],function(e,t,n){"use strict";var r=e("../lib/event"),i=e("../lib/useragent"),s=t.MouseEvent=function(e,t){this.domEvent=e,this.editor=t,this.x=this.clientX=e.clientX,this.y=this.clientY=e.clientY,this.$pos=null,this.$inSelection=null,this.propagationStopped=!1,this.defaultPrevented=!1};(function(){this.stopPropagation=function(){r.stopPropagation(this.domEvent),this.propagationStopped=!0},this.preventDefault=function(){r.preventDefault(this.domEvent),this.defaultPrevented=!0},this.stop=function(){this.stopPropagation(),this.preventDefault()},this.getDocumentPosition=function(){return this.$pos?this.$pos:(this.$pos=this.editor.renderer.screenToTextCoordinates(this.clientX,this.clientY),this.$pos)},this.inSelection=function(){if(this.$inSelection!==null)return this.$inSelection;var e=this.editor,t=e.getSelectionRange();if(t.isEmpty())this.$inSelection=!1;else{var n=this.getDocumentPosition();this.$inSelection=t.contains(n.row,n.column)}return this.$inSelection},this.getButton=function(){return r.getButton(this.domEvent)},this.getShiftKey=function(){return this.domEvent.shiftKey},this.getAccelKey=i.isMac?function(){return this.domEvent.metaKey}:function(){return this.domEvent.ctrlKey}}).call(s.prototype)}),ace.define("ace/mouse/dragdrop_handler",["require","exports","module","ace/lib/dom","ace/lib/event","ace/lib/useragent"],function(e,t,n){"use strict";function f(e){function T(e,n){var r=Date.now(),i=!n||e.row!=n.row,s=!n||e.column!=n.column;if(!S||i||s)t.$blockScrolling+=1,t.moveCursorToPosition(e),t.$blockScrolling-=1,S=r,x={x:p,y:d};else{var o=l(x.x,x.y,p,d);o>a?S=null:r-S>=u&&(t.renderer.scrollCursorIntoView(),S=null)}}function N(e,n){var r=Date.now(),i=t.renderer.layerConfig.lineHeight,s=t.renderer.layerConfig.characterWidth,u=t.renderer.scroller.getBoundingClientRect(),a={x:{left:p-u.left,right:u.right-p},y:{top:d-u.top,bottom:u.bottom-d}},f=Math.min(a.x.left,a.x.right),l=Math.min(a.y.top,a.y.bottom),c={row:e.row,column:e.column};f/s<=2&&(c.column+=a.x.left<a.x.right?-3:2),l/i<=1&&(c.row+=a.y.top<a.y.bottom?-1:1);var h=e.row!=c.row,v=e.column!=c.column,m=!n||e.row!=n.row;h||v&&!m?E?r-E>=o&&t.renderer.scrollCursorIntoView(c):E=r:E=null}function C(){var e=g;g=t.renderer.screenToTextCoordinates(p,d),T(g,e),N(g,e)}function k(){m=t.selection.toOrientedRange(),h=t.session.addMarker(m,"ace_selection",t.getSelectionStyle()),t.clearSelection(),t.isFocused()&&t.renderer.$cursorLayer.setBlinking(!1),clearInterval(v),v=setInterval(C,20),y=0,i.addListener(document,"mousemove",O)}function L(){clearInterval(v),t.session.removeMarker(h),h=null,t.$blockScrolling+=1,t.selection.fromOrientedRange(m),t.$blockScrolling-=1,t.isFocused()&&!w&&t.renderer.$cursorLayer.setBlinking(!t.getReadOnly()),m=null,y=0,E=null,S=null,i.removeListener(document,"mousemove",O)}function O(){A==null&&(A=setTimeout(function(){A!=null&&h&&L()},20))}function M(e){var t=e.types;return!t||Array.prototype.some.call(t,function(e){return e=="text/plain"||e=="Text"})}function _(e){var t=["copy","copymove","all","uninitialized"],n=["move","copymove","linkmove","all","uninitialized"],r=s.isMac?e.altKey:e.ctrlKey,i="uninitialized";try{i=e.dataTransfer.effectAllowed.toLowerCase()}catch(e){}var o="none";return r&&t.indexOf(i)>=0?o="copy":n.indexOf(i)>=0?o="move":t.indexOf(i)>=0&&(o="copy"),o}var t=e.editor,n=r.createElement("img");n.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",s.isOpera&&(n.style.cssText="width:1px;height:1px;position:fixed;top:0;left:0;z-index:2147483647;opacity:0;");var f=["dragWait","dragWaitEnd","startDrag","dragReadyEnd","onMouseDrag"];f.forEach(function(t){e[t]=this[t]},this),t.addEventListener("mousedown",this.onMouseDown.bind(e));var c=t.container,h,p,d,v,m,g,y=0,b,w,E,S,x;this.onDragStart=function(e){if(this.cancelDrag||!c.draggable){var r=this;return setTimeout(function(){r.startSelect(),r.captureMouse(e)},0),e.preventDefault()}m=t.getSelectionRange();var i=e.dataTransfer;i.effectAllowed=t.getReadOnly()?"copy":"copyMove",s.isOpera&&(t.container.appendChild(n),n._top=n.offsetTop),i.setDragImage&&i.setDragImage(n,0,0),s.isOpera&&t.container.removeChild(n),i.clearData(),i.setData("Text",t.session.getTextRange()),w=!0,this.setState("drag")},this.onDragEnd=function(e){c.draggable=!1,w=!1,this.setState(null);if(!t.getReadOnly()){var n=e.dataTransfer.dropEffect;!b&&n=="move"&&t.session.remove(t.getSelectionRange()),t.renderer.$cursorLayer.setBlinking(!0)}this.editor.unsetStyle("ace_dragging")},this.onDragEnter=function(e){if(t.getReadOnly()||!M(e.dataTransfer))return;return h||k(),y++,e.dataTransfer.dropEffect=b=_(e),i.preventDefault(e)},this.onDragOver=function(e){if(t.getReadOnly()||!M(e.dataTransfer))return;return h||(k(),y++),A!==null&&(A=null),p=e.clientX,d=e.clientY,e.dataTransfer.dropEffect=b=_(e),i.preventDefault(e)},this.onDragLeave=function(e){y--;if(y<=0&&h)return L(),b=null,i.preventDefault(e)},this.onDrop=function(e){if(!h)return;var n=e.dataTransfer;if(w)switch(b){case"move":m.contains(g.row,g.column)?m={start:g,end:g}:m=t.moveText(m,g);break;case"copy":m=t.moveText(m,g,!0)}else{var r=n.getData("Text");m={start:g,end:t.session.insert(g,r)},t.focus(),b=null}return L(),i.preventDefault(e)},i.addListener(c,"dragstart",this.onDragStart.bind(e)),i.addListener(c,"dragend",this.onDragEnd.bind(e)),i.addListener(c,"dragenter",this.onDragEnter.bind(e)),i.addListener(c,"dragover",this.onDragOver.bind(e)),i.addListener(c,"dragleave",this.onDragLeave.bind(e)),i.addListener(c,"drop",this.onDrop.bind(e));var A=null}function l(e,t,n,r){return Math.sqrt(Math.pow(n-e,2)+Math.pow(r-t,2))}var r=e("../lib/dom"),i=e("../lib/event"),s=e("../lib/useragent"),o=200,u=200,a=5;(function(){this.dragWait=function(){var e=Date.now()-this.mousedownEvent.time;e>this.editor.getDragDelay()&&this.startDrag()},this.dragWaitEnd=function(){var e=this.editor.container;e.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()),this.selectEnd()},this.dragReadyEnd=function(e){this.editor.renderer.$cursorLayer.setBlinking(!this.editor.getReadOnly()),this.editor.unsetStyle("ace_dragging"),this.dragWaitEnd()},this.startDrag=function(){this.cancelDrag=!1;var e=this.editor.container;e.draggable=!0,this.editor.renderer.$cursorLayer.setBlinking(!1),this.editor.setStyle("ace_dragging"),this.setState("dragReady")},this.onMouseDrag=function(e){var t=this.editor.container;if(s.isIE&&this.state=="dragReady"){var n=l(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y);n>3&&t.dragDrop()}if(this.state==="dragWait"){var n=l(this.mousedownEvent.x,this.mousedownEvent.y,this.x,this.y);n>0&&(t.draggable=!1,this.startSelect(this.mousedownEvent.getDocumentPosition()))}},this.onMouseDown=function(e){if(!this.$dragEnabled)return;this.mousedownEvent=e;var t=this.editor,n=e.inSelection(),r=e.getButton(),i=e.domEvent.detail||1;if(i===1&&r===0&&n){if(e.editor.inMultiSelectMode&&(e.getAccelKey()||e.getShiftKey()))return;this.mousedownEvent.time=Date.now();var o=e.domEvent.target||e.domEvent.srcElement;"unselectable"in o&&(o.unselectable="on");if(t.getDragDelay()){if(s.isWebKit){this.cancelDrag=!0;var u=t.container;u.draggable=!0}this.setState("dragWait")}else this.startDrag();this.captureMouse(e,this.onMouseDrag.bind(this)),e.defaultPrevented=!0}}}).call(f.prototype),t.DragdropHandler=f}),ace.define("ace/lib/net",["require","exports","module","ace/lib/dom"],function(e,t,n){"use strict";var r=e("./dom");t.get=function(e,t){var n=new XMLHttpRequest;n.open("GET",e,!0),n.onreadystatechange=function(){n.readyState===4&&t(n.responseText)},n.send(null)},t.loadScript=function(e,t){var n=r.getDocumentHead(),i=document.createElement("script");i.src=e,n.appendChild(i),i.onload=i.onreadystatechange=function(e,n){if(n||!i.readyState||i.readyState=="loaded"||i.readyState=="complete")i=i.onload=i.onreadystatechange=null,n||t()}},t.qualifyURL=function(e){var t=document.createElement("a");return t.href=e,t.href}}),ace.define("ace/lib/event_emitter",["require","exports","module"],function(e,t,n){"use strict";var r={},i=function(){this.propagationStopped=!0},s=function(){this.defaultPrevented=!0};r._emit=r._dispatchEvent=function(e,t){this._eventRegistry||(this._eventRegistry={}),this._defaultHandlers||(this._defaultHandlers={});var n=this._eventRegistry[e]||[],r=this._defaultHandlers[e];if(!n.length&&!r)return;if(typeof t!="object"||!t)t={};t.type||(t.type=e),t.stopPropagation||(t.stopPropagation=i),t.preventDefault||(t.preventDefault=s),n=n.slice();for(var o=0;o<n.length;o++){n[o](t,this);if(t.propagationStopped)break}if(r&&!t.defaultPrevented)return r(t,this)},r._signal=function(e,t){var n=(this._eventRegistry||{})[e];if(!n)return;n=n.slice();for(var r=0;r<n.length;r++)n[r](t,this)},r.once=function(e,t){var n=this;t&&this.addEventListener(e,function r(){n.removeEventListener(e,r),t.apply(null,arguments)})},r.setDefaultHandler=function(e,t){var n=this._defaultHandlers;n||(n=this._defaultHandlers={_disabled_:{}});if(n[e]){var r=n[e],i=n._disabled_[e];i||(n._disabled_[e]=i=[]),i.push(r);var s=i.indexOf(t);s!=-1&&i.splice(s,1)}n[e]=t},r.removeDefaultHandler=function(e,t){var n=this._defaultHandlers;if(!n)return;var r=n._disabled_[e];if(n[e]==t){var i=n[e];r&&this.setDefaultHandler(e,r.pop())}else if(r){var s=r.indexOf(t);s!=-1&&r.splice(s,1)}},r.on=r.addEventListener=function(e,t,n){this._eventRegistry=this._eventRegistry||{};var r=this._eventRegistry[e];return r||(r=this._eventRegistry[e]=[]),r.indexOf(t)==-1&&r[n?"unshift":"push"](t),t},r.off=r.removeListener=r.removeEventListener=function(e,t){this._eventRegistry=this._eventRegistry||{};var n=this._eventRegistry[e];if(!n)return;var r=n.indexOf(t);r!==-1&&n.splice(r,1)},r.removeAllListeners=function(e){this._eventRegistry&&(this._eventRegistry[e]=[])},t.EventEmitter=r}),ace.define("ace/config",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/lib/net","ace/lib/event_emitter"],function(e,t,n){"no use strict";function f(r){a.packaged=r||e.packaged||n.packaged||u.define&&define.packaged;if(!u.document)return"";var i={},s="",o=document.currentScript||document._currentScript,f=o&&o.ownerDocument||document,c=f.getElementsByTagName("script");for(var h=0;h<c.length;h++){var p=c[h],d=p.src||p.getAttribute("src");if(!d)continue;var v=p.attributes;for(var m=0,g=v.length;m<g;m++){var y=v[m];y.name.indexOf("data-ace-")===0&&(i[l(y.name.replace(/^data-ace-/,""))]=y.value)}var b=d.match(/^(.*)\/ace(\-\w+)?\.js(\?|$)/);b&&(s=b[1])}s&&(i.base=i.base||s,i.packaged=!0),i.basePath=i.base,i.workerPath=i.workerPath||i.base,i.modePath=i.modePath||i.base,i.themePath=i.themePath||i.base,delete i.base;for(var w in i)typeof i[w]!="undefined"&&t.set(w,i[w])}function l(e){return e.replace(/-(.)/g,function(e,t){return t.toUpperCase()})}var r=e("./lib/lang"),i=e("./lib/oop"),s=e("./lib/net"),o=e("./lib/event_emitter").EventEmitter,u=function(){return this}(),a={packaged:!1,workerPath:null,modePath:null,themePath:null,basePath:"",suffix:".js",$moduleUrls:{}};t.get=function(e){if(!a.hasOwnProperty(e))throw new Error("Unknown config key: "+e);return a[e]},t.set=function(e,t){if(!a.hasOwnProperty(e))throw new Error("Unknown config key: "+e);a[e]=t},t.all=function(){return r.copyObject(a)},i.implement(t,o),t.moduleUrl=function(e,t){if(a.$moduleUrls[e])return a.$moduleUrls[e];var n=e.split("/");t=t||n[n.length-2]||"";var r=t=="snippets"?"/":"-",i=n[n.length-1];if(t=="worker"&&r=="-"){var s=new RegExp("^"+t+"[\\-_]|[\\-_]"+t+"$","g");i=i.replace(s,"")}(!i||i==t)&&n.length>1&&(i=n[n.length-2]);var o=a[t+"Path"];return o==null?o=a.basePath:r=="/"&&(t=r=""),o&&o.slice(-1)!="/"&&(o+="/"),o+t+r+i+this.get("suffix")},t.setModuleUrl=function(e,t){return a.$moduleUrls[e]=t},t.$loading={},t.loadModule=function(n,r){var i,o;Array.isArray(n)&&(o=n[0],n=n[1]);try{i=e(n)}catch(u){}if(i&&!t.$loading[n])return r&&r(i);t.$loading[n]||(t.$loading[n]=[]),t.$loading[n].push(r);if(t.$loading[n].length>1)return;var a=function(){e([n],function(e){t._emit("load.module",{name:n,module:e});var r=t.$loading[n];t.$loading[n]=null,r.forEach(function(t){t&&t(e)})})};if(!t.get("packaged"))return a();s.loadScript(t.moduleUrl(n,o),a)},t.init=f;var c={setOptions:function(e){Object.keys(e).forEach(function(t){this.setOption(t,e[t])},this)},getOptions:function(e){var t={};return e?Array.isArray(e)||(t=e,e=Object.keys(t)):e=Object.keys(this.$options),e.forEach(function(e){t[e]=this.getOption(e)},this),t},setOption:function(e,t){if(this["$"+e]===t)return;var n=this.$options[e];if(!n)return typeof console!="undefined"&&console.warn&&console.warn('misspelled option "'+e+'"'),undefined;if(n.forwardTo)return this[n.forwardTo]&&this[n.forwardTo].setOption(e,t);n.handlesSet||(this["$"+e]=t),n&&n.set&&n.set.call(this,t)},getOption:function(e){var t=this.$options[e];return t?t.forwardTo?this[t.forwardTo]&&this[t.forwardTo].getOption(e):t&&t.get?t.get.call(this):this["$"+e]:(typeof console!="undefined"&&console.warn&&console.warn('misspelled option "'+e+'"'),undefined)}},h={};t.defineOptions=function(e,t,n){return e.$options||(h[t]=e.$options={}),Object.keys(n).forEach(function(t){var r=n[t];typeof r=="string"&&(r={forwardTo:r}),r.name||(r.name=t),e.$options[r.name]=r,"initialValue"in r&&(e["$"+r.name]=r.initialValue)}),i.implement(e,c),this},t.resetOptions=function(e){Object.keys(e.$options).forEach(function(t){var n=e.$options[t];"value"in n&&e.setOption(t,n.value)})},t.setDefaultValue=function(e,n,r){var i=h[e]||(h[e]={});i[n]&&(i.forwardTo?t.setDefaultValue(i.forwardTo,n,r):i[n].value=r)},t.setDefaultValues=function(e,n){Object.keys(n).forEach(function(r){t.setDefaultValue(e,r,n[r])})}}),ace.define("ace/mouse/mouse_handler",["require","exports","module","ace/lib/event","ace/lib/useragent","ace/mouse/default_handlers","ace/mouse/default_gutter_handler","ace/mouse/mouse_event","ace/mouse/dragdrop_handler","ace/config"],function(e,t,n){"use strict";var r=e("../lib/event"),i=e("../lib/useragent"),s=e("./default_handlers").DefaultHandlers,o=e("./default_gutter_handler").GutterHandler,u=e("./mouse_event").MouseEvent,a=e("./dragdrop_handler").DragdropHandler,f=e("../config"),l=function(e){var t=this;this.editor=e,new s(this),new o(this),new a(this);var n=function(t){!e.isFocused()&&e.textInput&&e.textInput.moveToMouse(t),e.focus()},u=e.renderer.getMouseEventTarget();r.addListener(u,"click",this.onMouseEvent.bind(this,"click")),r.addListener(u,"mousemove",this.onMouseMove.bind(this,"mousemove")),r.addMultiMouseDownListener(u,[400,300,250],this,"onMouseEvent"),e.renderer.scrollBarV&&(r.addMultiMouseDownListener(e.renderer.scrollBarV.inner,[400,300,250],this,"onMouseEvent"),r.addMultiMouseDownListener(e.renderer.scrollBarH.inner,[400,300,250],this,"onMouseEvent"),i.isIE&&(r.addListener(e.renderer.scrollBarV.element,"mousedown",n),r.addListener(e.renderer.scrollBarH.element,"mousemove",n))),r.addMouseWheelListener(e.container,this.onMouseWheel.bind(this,"mousewheel"));var f=e.renderer.$gutter;r.addListener(f,"mousedown",this.onMouseEvent.bind(this,"guttermousedown")),r.addListener(f,"click",this.onMouseEvent.bind(this,"gutterclick")),r.addListener(f,"dblclick",this.onMouseEvent.bind(this,"gutterdblclick")),r.addListener(f,"mousemove",this.onMouseEvent.bind(this,"guttermousemove")),r.addListener(u,"mousedown",n),r.addListener(f,"mousedown",function(t){return e.focus(),r.preventDefault(t)}),e.on("mousemove",function(n){if(t.state||t.$dragDelay||!t.$dragEnabled)return;var r=e.renderer.screenToTextCoordinates(n.x,n.y),i=e.session.selection.getRange(),s=e.renderer;!i.isEmpty()&&i.insideStart(r.row,r.column)?s.setCursorStyle("default"):s.setCursorStyle("")})};(function(){this.onMouseEvent=function(e,t){this.editor._emit(e,new u(t,this.editor))},this.onMouseMove=function(e,t){var n=this.editor._eventRegistry&&this.editor._eventRegistry.mousemove;if(!n||!n.length)return;this.editor._emit(e,new u(t,this.editor))},this.onMouseWheel=function(e,t){var n=new u(t,this.editor);n.speed=this.$scrollSpeed*2,n.wheelX=t.wheelX,n.wheelY=t.wheelY,this.editor._emit(e,n)},this.setState=function(e){this.state=e},this.captureMouse=function(e,t){this.x=e.x,this.y=e.y,this.isMousePressed=!0;var n=this.editor.renderer;n.$keepTextAreaAtCursor&&(n.$keepTextAreaAtCursor=null);var s=this,o=function(e){if(!e)return;if(i.isWebKit&&!e.which&&s.releaseMouse)return s.releaseMouse();s.x=e.clientX,s.y=e.clientY,t&&t(e),s.mouseEvent=new u(e,s.editor),s.$mouseMoved=!0},a=function(e){clearInterval(l),f(),s[s.state+"End"]&&s[s.state+"End"](e),s.state="",n.$keepTextAreaAtCursor==null&&(n.$keepTextAreaAtCursor=!0,n.$moveTextAreaToCursor()),s.isMousePressed=!1,s.$onCaptureMouseMove=s.releaseMouse=null,e&&s.onMouseEvent("mouseup",e)},f=function(){s[s.state]&&s[s.state](),s.$mouseMoved=!1};if(i.isOldIE&&e.domEvent.type=="dblclick")return setTimeout(function(){a(e)});s.$onCaptureMouseMove=o,s.releaseMouse=r.capture(this.editor.container,o,a);var l=setInterval(f,20)},this.releaseMouse=null,this.cancelContextMenu=function(){var e=function(t){if(t&&t.domEvent&&t.domEvent.type!="contextmenu")return;this.editor.off("nativecontextmenu",e),t&&t.domEvent&&r.stopEvent(t.domEvent)}.bind(this);setTimeout(e,10),this.editor.on("nativecontextmenu",e)}}).call(l.prototype),f.defineOptions(l.prototype,"mouseHandler",{scrollSpeed:{initialValue:2},dragDelay:{initialValue:i.isMac?150:0},dragEnabled:{initialValue:!0},focusTimout:{initialValue:0},tooltipFollowsMouse:{initialValue:!0}}),t.MouseHandler=l}),ace.define("ace/mouse/fold_handler",["require","exports","module"],function(e,t,n){"use strict";function r(e){e.on("click",function(t){var n=t.getDocumentPosition(),r=e.session,i=r.getFoldAt(n.row,n.column,1);i&&(t.getAccelKey()?r.removeFold(i):r.expandFold(i),t.stop())}),e.on("gutterclick",function(t){var n=e.renderer.$gutterLayer.getRegion(t);if(n=="foldWidgets"){var r=t.getDocumentPosition().row,i=e.session;i.foldWidgets&&i.foldWidgets[r]&&e.session.onFoldWidgetClick(r,t),e.isFocused()||e.focus(),t.stop()}}),e.on("gutterdblclick",function(t){var n=e.renderer.$gutterLayer.getRegion(t);if(n=="foldWidgets"){var r=t.getDocumentPosition().row,i=e.session,s=i.getParentFoldRangeData(r,!0),o=s.range||s.firstRange;if(o){r=o.start.row;var u=i.getFoldAt(r,i.getLine(r).length,1);u?i.removeFold(u):(i.addFold("...",o),e.renderer.scrollCursorIntoView({row:o.start.row,column:0}))}t.stop()}})}t.FoldHandler=r}),ace.define("ace/keyboard/keybinding",["require","exports","module","ace/lib/keys","ace/lib/event"],function(e,t,n){"use strict";var r=e("../lib/keys"),i=e("../lib/event"),s=function(e){this.$editor=e,this.$data={editor:e},this.$handlers=[],this.setDefaultHandler(e.commands)};(function(){this.setDefaultHandler=function(e){this.removeKeyboardHandler(this.$defaultHandler),this.$defaultHandler=e,this.addKeyboardHandler(e,0)},this.setKeyboardHandler=function(e){var t=this.$handlers;if(t[t.length-1]==e)return;while(t[t.length-1]&&t[t.length-1]!=this.$defaultHandler)this.removeKeyboardHandler(t[t.length-1]);this.addKeyboardHandler(e,1)},this.addKeyboardHandler=function(e,t){if(!e)return;typeof e=="function"&&!e.handleKeyboard&&(e.handleKeyboard=e);var n=this.$handlers.indexOf(e);n!=-1&&this.$handlers.splice(n,1),t==undefined?this.$handlers.push(e):this.$handlers.splice(t,0,e),n==-1&&e.attach&&e.attach(this.$editor)},this.removeKeyboardHandler=function(e){var t=this.$handlers.indexOf(e);return t==-1?!1:(this.$handlers.splice(t,1),e.detach&&e.detach(this.$editor),!0)},this.getKeyboardHandler=function(){return this.$handlers[this.$handlers.length-1]},this.$callKeyboardHandlers=function(e,t,n,r){var s,o=!1,u=this.$editor.commands;for(var a=this.$handlers.length;a--;){s=this.$handlers[a].handleKeyboard(this.$data,e,t,n,r);if(!s||!s.command)continue;s.command=="null"?o=!0:o=u.exec(s.command,this.$editor,s.args,r),o&&r&&e!=-1&&s.passEvent!=1&&s.command.passEvent!=1&&i.stopEvent(r);if(o)break}return o},this.onCommandKey=function(e,t,n){var i=r.keyCodeToString(n);this.$callKeyboardHandlers(t,i,n,e)},this.onTextInput=function(e){var t=this.$callKeyboardHandlers(-1,e);t||this.$editor.commands.exec("insertstring",this.$editor,e)}}).call(s.prototype),t.KeyBinding=s}),ace.define("ace/range",["require","exports","module"],function(e,t,n){"use strict";var r=function(e,t){return e.row-t.row||e.column-t.column},i=function(e,t,n,r){this.start={row:e,column:t},this.end={row:n,column:r}};(function(){this.isEqual=function(e){return this.start.row===e.start.row&&this.end.row===e.end.row&&this.start.column===e.start.column&&this.end.column===e.end.column},this.toString=function(){return"Range: ["+this.start.row+"/"+this.start.column+"] -> ["+this.end.row+"/"+this.end.column+"]"},this.contains=function(e,t){return this.compare(e,t)==0},this.compareRange=function(e){var t,n=e.end,r=e.start;return t=this.compare(n.row,n.column),t==1?(t=this.compare(r.row,r.column),t==1?2:t==0?1:0):t==-1?-2:(t=this.compare(r.row,r.column),t==-1?-1:t==1?42:0)},this.comparePoint=function(e){return this.compare(e.row,e.column)},this.containsRange=function(e){return this.comparePoint(e.start)==0&&this.comparePoint(e.end)==0},this.intersects=function(e){var t=this.compareRange(e);return t==-1||t==0||t==1},this.isEnd=function(e,t){return this.end.row==e&&this.end.column==t},this.isStart=function(e,t){return this.start.row==e&&this.start.column==t},this.setStart=function(e,t){typeof e=="object"?(this.start.column=e.column,this.start.row=e.row):(this.start.row=e,this.start.column=t)},this.setEnd=function(e,t){typeof e=="object"?(this.end.column=e.column,this.end.row=e.row):(this.end.row=e,this.end.column=t)},this.inside=function(e,t){return this.compare(e,t)==0?this.isEnd(e,t)||this.isStart(e,t)?!1:!0:!1},this.insideStart=function(e,t){return this.compare(e,t)==0?this.isEnd(e,t)?!1:!0:!1},this.insideEnd=function(e,t){return this.compare(e,t)==0?this.isStart(e,t)?!1:!0:!1},this.compare=function(e,t){return!this.isMultiLine()&&e===this.start.row?t<this.start.column?-1:t>this.end.column?1:0:e<this.start.row?-1:e>this.end.row?1:this.start.row===e?t>=this.start.column?0:-1:this.end.row===e?t<=this.end.column?0:1:0},this.compareStart=function(e,t){return this.start.row==e&&this.start.column==t?-1:this.compare(e,t)},this.compareEnd=function(e,t){return this.end.row==e&&this.end.column==t?1:this.compare(e,t)},this.compareInside=function(e,t){return this.end.row==e&&this.end.column==t?1:this.start.row==e&&this.start.column==t?-1:this.compare(e,t)},this.clipRows=function(e,t){if(this.end.row>t)var n={row:t+1,column:0};else if(this.end.row<e)var n={row:e,column:0};if(this.start.row>t)var r={row:t+1,column:0};else if(this.start.row<e)var r={row:e,column:0};return i.fromPoints(r||this.start,n||this.end)},this.extend=function(e,t){var n=this.compare(e,t);if(n==0)return this;if(n==-1)var r={row:e,column:t};else var s={row:e,column:t};return i.fromPoints(r||this.start,s||this.end)},this.isEmpty=function(){return this.start.row===this.end.row&&this.start.column===this.end.column},this.isMultiLine=function(){return this.start.row!==this.end.row},this.clone=function(){return i.fromPoints(this.start,this.end)},this.collapseRows=function(){return this.end.column==0?new i(this.start.row,0,Math.max(this.start.row,this.end.row-1),0):new i(this.start.row,0,this.end.row,0)},this.toScreenRange=function(e){var t=e.documentToScreenPosition(this.start),n=e.documentToScreenPosition(this.end);return new i(t.row,t.column,n.row,n.column)},this.moveBy=function(e,t){this.start.row+=e,this.start.column+=t,this.end.row+=e,this.end.column+=t}}).call(i.prototype),i.fromPoints=function(e,t){return new i(e.row,e.column,t.row,t.column)},i.comparePoints=r,i.comparePoints=function(e,t){return e.row-t.row||e.column-t.column},t.Range=i}),ace.define("ace/selection",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter","ace/range"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/lang"),s=e("./lib/event_emitter").EventEmitter,o=e("./range").Range,u=function(e){this.session=e,this.doc=e.getDocument(),this.clearSelection(),this.lead=this.selectionLead=this.doc.createAnchor(0,0),this.anchor=this.selectionAnchor=this.doc.createAnchor(0,0);var t=this;this.lead.on("change",function(e){t._emit("changeCursor"),t.$isEmpty||t._emit("changeSelection"),!t.$keepDesiredColumnOnChange&&e.old.column!=e.value.column&&(t.$desiredColumn=null)}),this.selectionAnchor.on("change",function(){t.$isEmpty||t._emit("changeSelection")})};(function(){r.implement(this,s),this.isEmpty=function(){return this.$isEmpty||this.anchor.row==this.lead.row&&this.anchor.column==this.lead.column},this.isMultiLine=function(){return this.isEmpty()?!1:this.getRange().isMultiLine()},this.getCursor=function(){return this.lead.getPosition()},this.setSelectionAnchor=function(e,t){this.anchor.setPosition(e,t),this.$isEmpty&&(this.$isEmpty=!1,this._emit("changeSelection"))},this.getSelectionAnchor=function(){return this.$isEmpty?this.getSelectionLead():this.anchor.getPosition()},this.getSelectionLead=function(){return this.lead.getPosition()},this.shiftSelection=function(e){if(this.$isEmpty){this.moveCursorTo(this.lead.row,this.lead.column+e);return}var t=this.getSelectionAnchor(),n=this.getSelectionLead(),r=this.isBackwards();(!r||t.column!==0)&&this.setSelectionAnchor(t.row,t.column+e),(r||n.column!==0)&&this.$moveSelection(function(){this.moveCursorTo(n.row,n.column+e)})},this.isBackwards=function(){var e=this.anchor,t=this.lead;return e.row>t.row||e.row==t.row&&e.column>t.column},this.getRange=function(){var e=this.anchor,t=this.lead;return this.isEmpty()?o.fromPoints(t,t):this.isBackwards()?o.fromPoints(t,e):o.fromPoints(e,t)},this.clearSelection=function(){this.$isEmpty||(this.$isEmpty=!0,this._emit("changeSelection"))},this.selectAll=function(){var e=this.doc.getLength()-1;this.setSelectionAnchor(0,0),this.moveCursorTo(e,this.doc.getLine(e).length)},this.setRange=this.setSelectionRange=function(e,t){t?(this.setSelectionAnchor(e.end.row,e.end.column),this.selectTo(e.start.row,e.start.column)):(this.setSelectionAnchor(e.start.row,e.start.column),this.selectTo(e.end.row,e.end.column)),this.getRange().isEmpty()&&(this.$isEmpty=!0),this.$desiredColumn=null},this.$moveSelection=function(e){var t=this.lead;this.$isEmpty&&this.setSelectionAnchor(t.row,t.column),e.call(this)},this.selectTo=function(e,t){this.$moveSelection(function(){this.moveCursorTo(e,t)})},this.selectToPosition=function(e){this.$moveSelection(function(){this.moveCursorToPosition(e)})},this.moveTo=function(e,t){this.clearSelection(),this.moveCursorTo(e,t)},this.moveToPosition=function(e){this.clearSelection(),this.moveCursorToPosition(e)},this.selectUp=function(){this.$moveSelection(this.moveCursorUp)},this.selectDown=function(){this.$moveSelection(this.moveCursorDown)},this.selectRight=function(){this.$moveSelection(this.moveCursorRight)},this.selectLeft=function(){this.$moveSelection(this.moveCursorLeft)},this.selectLineStart=function(){this.$moveSelection(this.moveCursorLineStart)},this.selectLineEnd=function(){this.$moveSelection(this.moveCursorLineEnd)},this.selectFileEnd=function(){this.$moveSelection(this.moveCursorFileEnd)},this.selectFileStart=function(){this.$moveSelection(this.moveCursorFileStart)},this.selectWordRight=function(){this.$moveSelection(this.moveCursorWordRight)},this.selectWordLeft=function(){this.$moveSelection(this.moveCursorWordLeft)},this.getWordRange=function(e,t){if(typeof t=="undefined"){var n=e||this.lead;e=n.row,t=n.column}return this.session.getWordRange(e,t)},this.selectWord=function(){this.setSelectionRange(this.getWordRange())},this.selectAWord=function(){var e=this.getCursor(),t=this.session.getAWordRange(e.row,e.column);this.setSelectionRange(t)},this.getLineRange=function(e,t){var n=typeof e=="number"?e:this.lead.row,r,i=this.session.getFoldLine(n);return i?(n=i.start.row,r=i.end.row):r=n,t===!0?new o(n,0,r,this.session.getLine(r).length):new o(n,0,r+1,0)},this.selectLine=function(){this.setSelectionRange(this.getLineRange())},this.moveCursorUp=function(){this.moveCursorBy(-1,0)},this.moveCursorDown=function(){this.moveCursorBy(1,0)},this.moveCursorLeft=function(){var e=this.lead.getPosition(),t;if(t=this.session.getFoldAt(e.row,e.column,-1))this.moveCursorTo(t.start.row,t.start.column);else if(e.column===0)e.row>0&&this.moveCursorTo(e.row-1,this.doc.getLine(e.row-1).length);else{var n=this.session.getTabSize();this.session.isTabStop(e)&&this.doc.getLine(e.row).slice(e.column-n,e.column).split(" ").length-1==n?this.moveCursorBy(0,-n):this.moveCursorBy(0,-1)}},this.moveCursorRight=function(){var e=this.lead.getPosition(),t;if(t=this.session.getFoldAt(e.row,e.column,1))this.moveCursorTo(t.end.row,t.end.column);else if(this.lead.column==this.doc.getLine(this.lead.row).length)this.lead.row<this.doc.getLength()-1&&this.moveCursorTo(this.lead.row+1,0);else{var n=this.session.getTabSize(),e=this.lead;this.session.isTabStop(e)&&this.doc.getLine(e.row).slice(e.column,e.column+n).split(" ").length-1==n?this.moveCursorBy(0,n):this.moveCursorBy(0,1)}},this.moveCursorLineStart=function(){var e=this.lead.row,t=this.lead.column,n=this.session.documentToScreenRow(e,t),r=this.session.screenToDocumentPosition(n,0),i=this.session.getDisplayLine(e,null,r.row,r.column),s=i.match(/^\s*/);s[0].length!=t&&!this.session.$useEmacsStyleLineStart&&(r.column+=s[0].length),this.moveCursorToPosition(r)},this.moveCursorLineEnd=function(){var e=this.lead,t=this.session.getDocumentLastRowColumnPosition(e.row,e.column);if(this.lead.column==t.column){var n=this.session.getLine(t.row);if(t.column==n.length){var r=n.search(/\s+$/);r>0&&(t.column=r)}}this.moveCursorTo(t.row,t.column)},this.moveCursorFileEnd=function(){var e=this.doc.getLength()-1,t=this.doc.getLine(e).length;this.moveCursorTo(e,t)},this.moveCursorFileStart=function(){this.moveCursorTo(0,0)},this.moveCursorLongWordRight=function(){var e=this.lead.row,t=this.lead.column,n=this.doc.getLine(e),r=n.substring(t),i;this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0;var s=this.session.getFoldAt(e,t,1);if(s){this.moveCursorTo(s.end.row,s.end.column);return}if(i=this.session.nonTokenRe.exec(r))t+=this.session.nonTokenRe.lastIndex,this.session.nonTokenRe.lastIndex=0,r=n.substring(t);if(t>=n.length){this.moveCursorTo(e,n.length),this.moveCursorRight(),e<this.doc.getLength()-1&&this.moveCursorWordRight();return}if(i=this.session.tokenRe.exec(r))t+=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0;this.moveCursorTo(e,t)},this.moveCursorLongWordLeft=function(){var e=this.lead.row,t=this.lead.column,n;if(n=this.session.getFoldAt(e,t,-1)){this.moveCursorTo(n.start.row,n.start.column);return}var r=this.session.getFoldStringAt(e,t,-1);r==null&&(r=this.doc.getLine(e).substring(0,t));var s=i.stringReverse(r),o;this.session.nonTokenRe.lastIndex=0,this.session.tokenRe.lastIndex=0;if(o=this.session.nonTokenRe.exec(s))t-=this.session.nonTokenRe.lastIndex,s=s.slice(this.session.nonTokenRe.lastIndex),this.session.nonTokenRe.lastIndex=0;if(t<=0){this.moveCursorTo(e,0),this.moveCursorLeft(),e>0&&this.moveCursorWordLeft();return}if(o=this.session.tokenRe.exec(s))t-=this.session.tokenRe.lastIndex,this.session.tokenRe.lastIndex=0;this.moveCursorTo(e,t)},this.$shortWordEndIndex=function(e){var t,n=0,r,i=/\s/,s=this.session.tokenRe;s.lastIndex=0;if(t=this.session.tokenRe.exec(e))n=this.session.tokenRe.lastIndex;else{while((r=e[n])&&i.test(r))n++;if(n<1){s.lastIndex=0;while((r=e[n])&&!s.test(r)){s.lastIndex=0,n++;if(i.test(r)){if(n>2){n--;break}while((r=e[n])&&i.test(r))n++;if(n>2)break}}}}return s.lastIndex=0,n},this.moveCursorShortWordRight=function(){var e=this.lead.row,t=this.lead.column,n=this.doc.getLine(e),r=n.substring(t),i=this.session.getFoldAt(e,t,1);if(i)return this.moveCursorTo(i.end.row,i.end.column);if(t==n.length){var s=this.doc.getLength();do e++,r=this.doc.getLine(e);while(e<s&&/^\s*$/.test(r));/^\s+/.test(r)||(r=""),t=0}var o=this.$shortWordEndIndex(r);this.moveCursorTo(e,t+o)},this.moveCursorShortWordLeft=function(){var e=this.lead.row,t=this.lead.column,n;if(n=this.session.getFoldAt(e,t,-1))return this.moveCursorTo(n.start.row,n.start.column);var r=this.session.getLine(e).substring(0,t);if(t===0){do e--,r=this.doc.getLine(e);while(e>0&&/^\s*$/.test(r));t=r.length,/\s+$/.test(r)||(r="")}var s=i.stringReverse(r),o=this.$shortWordEndIndex(s);return this.moveCursorTo(e,t-o)},this.moveCursorWordRight=function(){this.session.$selectLongWords?this.moveCursorLongWordRight():this.moveCursorShortWordRight()},this.moveCursorWordLeft=function(){this.session.$selectLongWords?this.moveCursorLongWordLeft():this.moveCursorShortWordLeft()},this.moveCursorBy=function(e,t){var n=this.session.documentToScreenPosition(this.lead.row,this.lead.column);t===0&&(this.$desiredColumn?n.column=this.$desiredColumn:this.$desiredColumn=n.column);var r=this.session.screenToDocumentPosition(n.row+e,n.column);e!==0&&t===0&&r.row===this.lead.row&&r.column===this.lead.column&&this.session.lineWidgets&&this.session.lineWidgets[r.row]&&r.row++,this.moveCursorTo(r.row,r.column+t,t===0)},this.moveCursorToPosition=function(e){this.moveCursorTo(e.row,e.column)},this.moveCursorTo=function(e,t,n){var r=this.session.getFoldAt(e,t,1);r&&(e=r.start.row,t=r.start.column),this.$keepDesiredColumnOnChange=!0,this.lead.setPosition(e,t),this.$keepDesiredColumnOnChange=!1,n||(this.$desiredColumn=null)},this.moveCursorToScreen=function(e,t,n){var r=this.session.screenToDocumentPosition(e,t);this.moveCursorTo(r.row,r.column,n)},this.detach=function(){this.lead.detach(),this.anchor.detach(),this.session=this.doc=null},this.fromOrientedRange=function(e){this.setSelectionRange(e,e.cursor==e.start),this.$desiredColumn=e.desiredColumn||this.$desiredColumn},this.toOrientedRange=function(e){var t=this.getRange();return e?(e.start.column=t.start.column,e.start.row=t.start.row,e.end.column=t.end.column,e.end.row=t.end.row):e=t,e.cursor=this.isBackwards()?e.start:e.end,e.desiredColumn=this.$desiredColumn,e},this.getRangeOfMovements=function(e){var t=this.getCursor();try{e.call(null,this);var n=this.getCursor();return o.fromPoints(t,n)}catch(r){return o.fromPoints(t,t)}finally{this.moveCursorToPosition(t)}},this.toJSON=function(){if(this.rangeCount)var e=this.ranges.map(function(e){var t=e.clone();return t.isBackwards=e.cursor==e.start,t});else{var e=this.getRange();e.isBackwards=this.isBackwards()}return e},this.fromJSON=function(e){if(e.start==undefined){if(this.rangeList){this.toSingleRange(e[0]);for(var t=e.length;t--;){var n=o.fromPoints(e[t].start,e[t].end);e.isBackwards&&(n.cursor=n.start),this.addRange(n,!0)}return}e=e[0]}this.rangeList&&this.toSingleRange(e),this.setSelectionRange(e,e.isBackwards)},this.isEqual=function(e){if((e.length||this.rangeCount)&&e.length!=this.rangeCount)return!1;if(!e.length||!this.ranges)return this.getRange().isEqual(e);for(var t=this.ranges.length;t--;)if(!this.ranges[t].isEqual(e[t]))return!1;return!0}}).call(u.prototype),t.Selection=u}),ace.define("ace/tokenizer",["require","exports","module"],function(e,t,n){"use strict";var r=1e3,i=function(e){this.states=e,this.regExps={},this.matchMappings={};for(var t in this.states){var n=this.states[t],r=[],i=0,s=this.matchMappings[t]={defaultToken:"text"},o="g",u=[];for(var a=0;a<n.length;a++){var f=n[a];f.defaultToken&&(s.defaultToken=f.defaultToken),f.caseInsensitive&&(o="gi");if(f.regex==null)continue;f.regex instanceof RegExp&&(f.regex=f.regex.toString().slice(1,-1));var l=f.regex,c=(new RegExp("(?:("+l+")|(.))")).exec("a").length-2;if(Array.isArray(f.token))if(f.token.length==1||c==1)f.token=f.token[0];else{if(c-1!=f.token.length)throw new Error("number of classes and regexp groups in '"+f.token+"'\n'"+f.regex+"' doesn't match\n"+(c-1)+"!="+f.token.length);f.tokenArray=f.token,f.token=null,f.onMatch=this.$arrayTokens}else typeof f.token=="function"&&!f.onMatch&&(c>1?f.onMatch=this.$applyToken:f.onMatch=f.token);c>1&&(/\\\d/.test(f.regex)?l=f.regex.replace(/\\([0-9]+)/g,function(e,t){return"\\"+(parseInt(t,10)+i+1)}):(c=1,l=this.removeCapturingGroups(f.regex)),!f.splitRegex&&typeof f.token!="string"&&u.push(f)),s[i]=a,i+=c,r.push(l),f.onMatch||(f.onMatch=null)}r.length||(s[0]=0,r.push("$")),u.forEach(function(e){e.splitRegex=this.createSplitterRegexp(e.regex,o)},this),this.regExps[t]=new RegExp("("+r.join(")|(")+")|($)",o)}};(function(){this.$setMaxTokenCount=function(e){r=e|0},this.$applyToken=function(e){var t=this.splitRegex.exec(e).slice(1),n=this.token.apply(this,t);if(typeof n=="string")return[{type:n,value:e}];var r=[];for(var i=0,s=n.length;i<s;i++)t[i]&&(r[r.length]={type:n[i],value:t[i]});return r},this.$arrayTokens=function(e){if(!e)return[];var t=this.splitRegex.exec(e);if(!t)return"text";var n=[],r=this.tokenArray;for(var i=0,s=r.length;i<s;i++)t[i+1]&&(n[n.length]={type:r[i],value:t[i+1]});return n},this.removeCapturingGroups=function(e){var t=e.replace(/\[(?:\\.|[^\]])*?\]|\\.|\(\?[:=!]|(\()/g,function(e,t){return t?"(?:":e});return t},this.createSplitterRegexp=function(e,t){if(e.indexOf("(?=")!=-1){var n=0,r=!1,i={};e.replace(/(\\.)|(\((?:\?[=!])?)|(\))|([\[\]])/g,function(e,t,s,o,u,a){return r?r=u!="]":u?r=!0:o?(n==i.stack&&(i.end=a+1,i.stack=-1),n--):s&&(n++,s.length!=1&&(i.stack=n,i.start=a)),e}),i.end!=null&&/^\)*$/.test(e.substr(i.end))&&(e=e.substring(0,i.start)+e.substr(i.end))}return new RegExp(e,(t||"").replace("g",""))},this.getLineTokens=function(e,t){if(t&&typeof t!="string"){var n=t.slice(0);t=n[0]}else var n=[];var i=t||"start",s=this.states[i];s||(i="start",s=this.states[i]);var o=this.matchMappings[i],u=this.regExps[i];u.lastIndex=0;var a,f=[],l=0,c={type:null,value:""};while(a=u.exec(e)){var h=o.defaultToken,p=null,d=a[0],v=u.lastIndex;if(v-d.length>l){var m=e.substring(l,v-d.length);c.type==h?c.value+=m:(c.type&&f.push(c),c={type:h,value:m})}for(var g=0;g<a.length-2;g++){if(a[g+1]===undefined)continue;p=s[o[g]],p.onMatch?h=p.onMatch(d,i,n):h=p.token,p.next&&(typeof p.next=="string"?(n.length&&n[0]==i&&n[1]==p.next&&n.shift(),i=p.next):i=p.next(i,n),s=this.states[i],s||(window.console&&console.error&&console.error(i,"doesn't exist"),i="start",s=this.states[i]),o=this.matchMappings[i],l=v,u=this.regExps[i],u.lastIndex=v);break}if(d)if(typeof h=="string")!!p&&p.merge===!1||c.type!==h?(c.type&&f.push(c),c={type:h,value:d}):c.value+=d;else if(h){c.type&&f.push(c),c={type:null,value:""};for(var g=0;g<h.length;g++)f.push(h[g])}if(l==e.length)break;l=v;if(f.length>r){while(l<e.length)c.type&&f.push(c),c={value:e.substring(l,l+=2e3),type:"overflow"};i="start",n=[];break}}return c.type&&f.push(c),n.length>1&&n[0]!==i&&n.unshift(i),{tokens:f,state:n.length?n:i}}}).call(i.prototype),t.Tokenizer=i}),ace.define("ace/mode/text_highlight_rules",["require","exports","module","ace/lib/lang"],function(e,t,n){"use strict";var r=e("../lib/lang"),i=function(){this.$rules={start:[{token:"empty_line",regex:"^$"},{defaultToken:"text"}]}};(function(){this.addRules=function(e,t){if(!t){for(var n in e)this.$rules[n]=e[n];return}for(var n in e){var r=e[n];for(var i=0;i<r.length;i++){var s=r[i];s.next&&(typeof s.next!="string"?s.nextState&&s.nextState.indexOf(t)!==0&&(s.nextState=t+s.nextState):s.next.indexOf(t)!==0&&(s.next=t+s.next))}this.$rules[t+n]=r}},this.getRules=function(){return this.$rules},this.embedRules=function(e,t,n,i,s){var o=typeof e=="function"?(new e).getRules():e;if(i)for(var u=0;u<i.length;u++)i[u]=t+i[u];else{i=[];for(var a in o)i.push(t+a)}this.addRules(o,t);if(n){var f=Array.prototype[s?"push":"unshift"];for(var u=0;u<i.length;u++)f.apply(this.$rules[i[u]],r.deepCopy(n))}this.$embeds||(this.$embeds=[]),this.$embeds.push(t)},this.getEmbeds=function(){return this.$embeds};var e=function(e,t){return(e!="start"||t.length)&&t.unshift(this.nextState,e),this.nextState},t=function(e,t){return t.shift(),t.shift()||"start"};this.normalizeRules=function(){function i(s){var o=r[s];o.processed=!0;for(var u=0;u<o.length;u++){var a=o[u];!a.regex&&a.start&&(a.regex=a.start,a.next||(a.next=[]),a.next.push({defaultToken:a.token},{token:a.token+".end",regex:a.end||a.start,next:"pop"}),a.token=a.token+".start",a.push=!0);var f=a.next||a.push;if(f&&Array.isArray(f)){var l=a.stateName;l||(l=a.token,typeof l!="string"&&(l=l[0]||""),r[l]&&(l+=n++)),r[l]=f,a.next=l,i(l)}else f=="pop"&&(a.next=t);a.push&&(a.nextState=a.next||a.push,a.next=e,delete a.push);if(a.rules)for(var c in a.rules)r[c]?r[c].push&&r[c].push.apply(r[c],a.rules[c]):r[c]=a.rules[c];if(a.include||typeof a=="string")var h=a.include||a,p=r[h];else Array.isArray(a)&&(p=a);if(p){var d=[u,1].concat(p);a.noEscape&&(d=d.filter(function(e){return!e.next})),o.splice.apply(o,d),u--,p=null}a.keywordMap&&(a.token=this.createKeywordMapper(a.keywordMap,a.defaultToken||"text",a.caseInsensitive),delete a.defaultToken)}}var n=0,r=this.$rules;Object.keys(r).forEach(i,this)},this.createKeywordMapper=function(e,t,n,r){var i=Object.create(null);return Object.keys(e).forEach(function(t){var s=e[t];n&&(s=s.toLowerCase());var o=s.split(r||"|");for(var u=o.length;u--;)i[o[u]]=t}),Object.getPrototypeOf(i)&&(i.__proto__=null),this.$keywordList=Object.keys(i),e=null,n?function(e){return i[e.toLowerCase()]||t}:function(e){return i[e]||t}},this.getKeywords=function(){return this.$keywords}}).call(i.prototype),t.TextHighlightRules=i}),ace.define("ace/mode/behaviour",["require","exports","module"],function(e,t,n){"use strict";var r=function(){this.$behaviours={}};(function(){this.add=function(e,t,n){switch(undefined){case this.$behaviours:this.$behaviours={};case this.$behaviours[e]:this.$behaviours[e]={}}this.$behaviours[e][t]=n},this.addBehaviours=function(e){for(var t in e)for(var n in e[t])this.add(t,n,e[t][n])},this.remove=function(e){this.$behaviours&&this.$behaviours[e]&&delete this.$behaviours[e]},this.inherit=function(e,t){if(typeof e=="function")var n=(new e).getBehaviours(t);else var n=e.getBehaviours(t);this.addBehaviours(n)},this.getBehaviours=function(e){if(!e)return this.$behaviours;var t={};for(var n=0;n<e.length;n++)this.$behaviours[e[n]]&&(t[e[n]]=this.$behaviours[e[n]]);return t}}).call(r.prototype),t.Behaviour=r}),ace.define("ace/unicode",["require","exports","module"],function(e,t,n){"use strict";function r(e){var n=/\w{4}/g;for(var r in e)t.packages[r]=e[r].replace(n,"\\u$&")}t.packages={},r({L:"0041-005A0061-007A00AA00B500BA00C0-00D600D8-00F600F8-02C102C6-02D102E0-02E402EC02EE0370-037403760377037A-037D03860388-038A038C038E-03A103A3-03F503F7-0481048A-05250531-055605590561-058705D0-05EA05F0-05F20621-064A066E066F0671-06D306D506E506E606EE06EF06FA-06FC06FF07100712-072F074D-07A507B107CA-07EA07F407F507FA0800-0815081A082408280904-0939093D09500958-0961097109720979-097F0985-098C098F09900993-09A809AA-09B009B209B6-09B909BD09CE09DC09DD09DF-09E109F009F10A05-0A0A0A0F0A100A13-0A280A2A-0A300A320A330A350A360A380A390A59-0A5C0A5E0A72-0A740A85-0A8D0A8F-0A910A93-0AA80AAA-0AB00AB20AB30AB5-0AB90ABD0AD00AE00AE10B05-0B0C0B0F0B100B13-0B280B2A-0B300B320B330B35-0B390B3D0B5C0B5D0B5F-0B610B710B830B85-0B8A0B8E-0B900B92-0B950B990B9A0B9C0B9E0B9F0BA30BA40BA8-0BAA0BAE-0BB90BD00C05-0C0C0C0E-0C100C12-0C280C2A-0C330C35-0C390C3D0C580C590C600C610C85-0C8C0C8E-0C900C92-0CA80CAA-0CB30CB5-0CB90CBD0CDE0CE00CE10D05-0D0C0D0E-0D100D12-0D280D2A-0D390D3D0D600D610D7A-0D7F0D85-0D960D9A-0DB10DB3-0DBB0DBD0DC0-0DC60E01-0E300E320E330E40-0E460E810E820E840E870E880E8A0E8D0E94-0E970E99-0E9F0EA1-0EA30EA50EA70EAA0EAB0EAD-0EB00EB20EB30EBD0EC0-0EC40EC60EDC0EDD0F000F40-0F470F49-0F6C0F88-0F8B1000-102A103F1050-1055105A-105D106110651066106E-10701075-1081108E10A0-10C510D0-10FA10FC1100-1248124A-124D1250-12561258125A-125D1260-1288128A-128D1290-12B012B2-12B512B8-12BE12C012C2-12C512C8-12D612D8-13101312-13151318-135A1380-138F13A0-13F41401-166C166F-167F1681-169A16A0-16EA1700-170C170E-17111720-17311740-17511760-176C176E-17701780-17B317D717DC1820-18771880-18A818AA18B0-18F51900-191C1950-196D1970-19741980-19AB19C1-19C71A00-1A161A20-1A541AA71B05-1B331B45-1B4B1B83-1BA01BAE1BAF1C00-1C231C4D-1C4F1C5A-1C7D1CE9-1CEC1CEE-1CF11D00-1DBF1E00-1F151F18-1F1D1F20-1F451F48-1F4D1F50-1F571F591F5B1F5D1F5F-1F7D1F80-1FB41FB6-1FBC1FBE1FC2-1FC41FC6-1FCC1FD0-1FD31FD6-1FDB1FE0-1FEC1FF2-1FF41FF6-1FFC2071207F2090-209421022107210A-211321152119-211D212421262128212A-212D212F-2139213C-213F2145-2149214E218321842C00-2C2E2C30-2C5E2C60-2CE42CEB-2CEE2D00-2D252D30-2D652D6F2D80-2D962DA0-2DA62DA8-2DAE2DB0-2DB62DB8-2DBE2DC0-2DC62DC8-2DCE2DD0-2DD62DD8-2DDE2E2F300530063031-3035303B303C3041-3096309D-309F30A1-30FA30FC-30FF3105-312D3131-318E31A0-31B731F0-31FF3400-4DB54E00-9FCBA000-A48CA4D0-A4FDA500-A60CA610-A61FA62AA62BA640-A65FA662-A66EA67F-A697A6A0-A6E5A717-A71FA722-A788A78BA78CA7FB-A801A803-A805A807-A80AA80C-A822A840-A873A882-A8B3A8F2-A8F7A8FBA90A-A925A930-A946A960-A97CA984-A9B2A9CFAA00-AA28AA40-AA42AA44-AA4BAA60-AA76AA7AAA80-AAAFAAB1AAB5AAB6AAB9-AABDAAC0AAC2AADB-AADDABC0-ABE2AC00-D7A3D7B0-D7C6D7CB-D7FBF900-FA2DFA30-FA6DFA70-FAD9FB00-FB06FB13-FB17FB1DFB1F-FB28FB2A-FB36FB38-FB3CFB3EFB40FB41FB43FB44FB46-FBB1FBD3-FD3DFD50-FD8FFD92-FDC7FDF0-FDFBFE70-FE74FE76-FEFCFF21-FF3AFF41-FF5AFF66-FFBEFFC2-FFC7FFCA-FFCFFFD2-FFD7FFDA-FFDC",Ll:"0061-007A00AA00B500BA00DF-00F600F8-00FF01010103010501070109010B010D010F01110113011501170119011B011D011F01210123012501270129012B012D012F01310133013501370138013A013C013E014001420144014601480149014B014D014F01510153015501570159015B015D015F01610163016501670169016B016D016F0171017301750177017A017C017E-0180018301850188018C018D019201950199-019B019E01A101A301A501A801AA01AB01AD01B001B401B601B901BA01BD-01BF01C601C901CC01CE01D001D201D401D601D801DA01DC01DD01DF01E101E301E501E701E901EB01ED01EF01F001F301F501F901FB01FD01FF02010203020502070209020B020D020F02110213021502170219021B021D021F02210223022502270229022B022D022F02310233-0239023C023F0240024202470249024B024D024F-02930295-02AF037103730377037B-037D039003AC-03CE03D003D103D5-03D703D903DB03DD03DF03E103E303E503E703E903EB03ED03EF-03F303F503F803FB03FC0430-045F04610463046504670469046B046D046F04710473047504770479047B047D047F0481048B048D048F04910493049504970499049B049D049F04A104A304A504A704A904AB04AD04AF04B104B304B504B704B904BB04BD04BF04C204C404C604C804CA04CC04CE04CF04D104D304D504D704D904DB04DD04DF04E104E304E504E704E904EB04ED04EF04F104F304F504F704F904FB04FD04FF05010503050505070509050B050D050F05110513051505170519051B051D051F0521052305250561-05871D00-1D2B1D62-1D771D79-1D9A1E011E031E051E071E091E0B1E0D1E0F1E111E131E151E171E191E1B1E1D1E1F1E211E231E251E271E291E2B1E2D1E2F1E311E331E351E371E391E3B1E3D1E3F1E411E431E451E471E491E4B1E4D1E4F1E511E531E551E571E591E5B1E5D1E5F1E611E631E651E671E691E6B1E6D1E6F1E711E731E751E771E791E7B1E7D1E7F1E811E831E851E871E891E8B1E8D1E8F1E911E931E95-1E9D1E9F1EA11EA31EA51EA71EA91EAB1EAD1EAF1EB11EB31EB51EB71EB91EBB1EBD1EBF1EC11EC31EC51EC71EC91ECB1ECD1ECF1ED11ED31ED51ED71ED91EDB1EDD1EDF1EE11EE31EE51EE71EE91EEB1EED1EEF1EF11EF31EF51EF71EF91EFB1EFD1EFF-1F071F10-1F151F20-1F271F30-1F371F40-1F451F50-1F571F60-1F671F70-1F7D1F80-1F871F90-1F971FA0-1FA71FB0-1FB41FB61FB71FBE1FC2-1FC41FC61FC71FD0-1FD31FD61FD71FE0-1FE71FF2-1FF41FF61FF7210A210E210F2113212F21342139213C213D2146-2149214E21842C30-2C5E2C612C652C662C682C6A2C6C2C712C732C742C76-2C7C2C812C832C852C872C892C8B2C8D2C8F2C912C932C952C972C992C9B2C9D2C9F2CA12CA32CA52CA72CA92CAB2CAD2CAF2CB12CB32CB52CB72CB92CBB2CBD2CBF2CC12CC32CC52CC72CC92CCB2CCD2CCF2CD12CD32CD52CD72CD92CDB2CDD2CDF2CE12CE32CE42CEC2CEE2D00-2D25A641A643A645A647A649A64BA64DA64FA651A653A655A657A659A65BA65DA65FA663A665A667A669A66BA66DA681A683A685A687A689A68BA68DA68FA691A693A695A697A723A725A727A729A72BA72DA72F-A731A733A735A737A739A73BA73DA73FA741A743A745A747A749A74BA74DA74FA751A753A755A757A759A75BA75DA75FA761A763A765A767A769A76BA76DA76FA771-A778A77AA77CA77FA781A783A785A787A78CFB00-FB06FB13-FB17FF41-FF5A",Lu:"0041-005A00C0-00D600D8-00DE01000102010401060108010A010C010E01100112011401160118011A011C011E01200122012401260128012A012C012E01300132013401360139013B013D013F0141014301450147014A014C014E01500152015401560158015A015C015E01600162016401660168016A016C016E017001720174017601780179017B017D018101820184018601870189-018B018E-0191019301940196-0198019C019D019F01A001A201A401A601A701A901AC01AE01AF01B1-01B301B501B701B801BC01C401C701CA01CD01CF01D101D301D501D701D901DB01DE01E001E201E401E601E801EA01EC01EE01F101F401F6-01F801FA01FC01FE02000202020402060208020A020C020E02100212021402160218021A021C021E02200222022402260228022A022C022E02300232023A023B023D023E02410243-02460248024A024C024E03700372037603860388-038A038C038E038F0391-03A103A3-03AB03CF03D2-03D403D803DA03DC03DE03E003E203E403E603E803EA03EC03EE03F403F703F903FA03FD-042F04600462046404660468046A046C046E04700472047404760478047A047C047E0480048A048C048E04900492049404960498049A049C049E04A004A204A404A604A804AA04AC04AE04B004B204B404B604B804BA04BC04BE04C004C104C304C504C704C904CB04CD04D004D204D404D604D804DA04DC04DE04E004E204E404E604E804EA04EC04EE04F004F204F404F604F804FA04FC04FE05000502050405060508050A050C050E05100512051405160518051A051C051E0520052205240531-055610A0-10C51E001E021E041E061E081E0A1E0C1E0E1E101E121E141E161E181E1A1E1C1E1E1E201E221E241E261E281E2A1E2C1E2E1E301E321E341E361E381E3A1E3C1E3E1E401E421E441E461E481E4A1E4C1E4E1E501E521E541E561E581E5A1E5C1E5E1E601E621E641E661E681E6A1E6C1E6E1E701E721E741E761E781E7A1E7C1E7E1E801E821E841E861E881E8A1E8C1E8E1E901E921E941E9E1EA01EA21EA41EA61EA81EAA1EAC1EAE1EB01EB21EB41EB61EB81EBA1EBC1EBE1EC01EC21EC41EC61EC81ECA1ECC1ECE1ED01ED21ED41ED61ED81EDA1EDC1EDE1EE01EE21EE41EE61EE81EEA1EEC1EEE1EF01EF21EF41EF61EF81EFA1EFC1EFE1F08-1F0F1F18-1F1D1F28-1F2F1F38-1F3F1F48-1F4D1F591F5B1F5D1F5F1F68-1F6F1FB8-1FBB1FC8-1FCB1FD8-1FDB1FE8-1FEC1FF8-1FFB21022107210B-210D2110-211221152119-211D212421262128212A-212D2130-2133213E213F214521832C00-2C2E2C602C62-2C642C672C692C6B2C6D-2C702C722C752C7E-2C802C822C842C862C882C8A2C8C2C8E2C902C922C942C962C982C9A2C9C2C9E2CA02CA22CA42CA62CA82CAA2CAC2CAE2CB02CB22CB42CB62CB82CBA2CBC2CBE2CC02CC22CC42CC62CC82CCA2CCC2CCE2CD02CD22CD42CD62CD82CDA2CDC2CDE2CE02CE22CEB2CEDA640A642A644A646A648A64AA64CA64EA650A652A654A656A658A65AA65CA65EA662A664A666A668A66AA66CA680A682A684A686A688A68AA68CA68EA690A692A694A696A722A724A726A728A72AA72CA72EA732A734A736A738A73AA73CA73EA740A742A744A746A748A74AA74CA74EA750A752A754A756A758A75AA75CA75EA760A762A764A766A768A76AA76CA76EA779A77BA77DA77EA780A782A784A786A78BFF21-FF3A",Lt:"01C501C801CB01F21F88-1F8F1F98-1F9F1FA8-1FAF1FBC1FCC1FFC",Lm:"02B0-02C102C6-02D102E0-02E402EC02EE0374037A0559064006E506E607F407F507FA081A0824082809710E460EC610FC17D718431AA71C78-1C7D1D2C-1D611D781D9B-1DBF2071207F2090-20942C7D2D6F2E2F30053031-3035303B309D309E30FC-30FEA015A4F8-A4FDA60CA67FA717-A71FA770A788A9CFAA70AADDFF70FF9EFF9F",Lo:"01BB01C0-01C3029405D0-05EA05F0-05F20621-063F0641-064A066E066F0671-06D306D506EE06EF06FA-06FC06FF07100712-072F074D-07A507B107CA-07EA0800-08150904-0939093D09500958-096109720979-097F0985-098C098F09900993-09A809AA-09B009B209B6-09B909BD09CE09DC09DD09DF-09E109F009F10A05-0A0A0A0F0A100A13-0A280A2A-0A300A320A330A350A360A380A390A59-0A5C0A5E0A72-0A740A85-0A8D0A8F-0A910A93-0AA80AAA-0AB00AB20AB30AB5-0AB90ABD0AD00AE00AE10B05-0B0C0B0F0B100B13-0B280B2A-0B300B320B330B35-0B390B3D0B5C0B5D0B5F-0B610B710B830B85-0B8A0B8E-0B900B92-0B950B990B9A0B9C0B9E0B9F0BA30BA40BA8-0BAA0BAE-0BB90BD00C05-0C0C0C0E-0C100C12-0C280C2A-0C330C35-0C390C3D0C580C590C600C610C85-0C8C0C8E-0C900C92-0CA80CAA-0CB30CB5-0CB90CBD0CDE0CE00CE10D05-0D0C0D0E-0D100D12-0D280D2A-0D390D3D0D600D610D7A-0D7F0D85-0D960D9A-0DB10DB3-0DBB0DBD0DC0-0DC60E01-0E300E320E330E40-0E450E810E820E840E870E880E8A0E8D0E94-0E970E99-0E9F0EA1-0EA30EA50EA70EAA0EAB0EAD-0EB00EB20EB30EBD0EC0-0EC40EDC0EDD0F000F40-0F470F49-0F6C0F88-0F8B1000-102A103F1050-1055105A-105D106110651066106E-10701075-1081108E10D0-10FA1100-1248124A-124D1250-12561258125A-125D1260-1288128A-128D1290-12B012B2-12B512B8-12BE12C012C2-12C512C8-12D612D8-13101312-13151318-135A1380-138F13A0-13F41401-166C166F-167F1681-169A16A0-16EA1700-170C170E-17111720-17311740-17511760-176C176E-17701780-17B317DC1820-18421844-18771880-18A818AA18B0-18F51900-191C1950-196D1970-19741980-19AB19C1-19C71A00-1A161A20-1A541B05-1B331B45-1B4B1B83-1BA01BAE1BAF1C00-1C231C4D-1C4F1C5A-1C771CE9-1CEC1CEE-1CF12135-21382D30-2D652D80-2D962DA0-2DA62DA8-2DAE2DB0-2DB62DB8-2DBE2DC0-2DC62DC8-2DCE2DD0-2DD62DD8-2DDE3006303C3041-3096309F30A1-30FA30FF3105-312D3131-318E31A0-31B731F0-31FF3400-4DB54E00-9FCBA000-A014A016-A48CA4D0-A4F7A500-A60BA610-A61FA62AA62BA66EA6A0-A6E5A7FB-A801A803-A805A807-A80AA80C-A822A840-A873A882-A8B3A8F2-A8F7A8FBA90A-A925A930-A946A960-A97CA984-A9B2AA00-AA28AA40-AA42AA44-AA4BAA60-AA6FAA71-AA76AA7AAA80-AAAFAAB1AAB5AAB6AAB9-AABDAAC0AAC2AADBAADCABC0-ABE2AC00-D7A3D7B0-D7C6D7CB-D7FBF900-FA2DFA30-FA6DFA70-FAD9FB1DFB1F-FB28FB2A-FB36FB38-FB3CFB3EFB40FB41FB43FB44FB46-FBB1FBD3-FD3DFD50-FD8FFD92-FDC7FDF0-FDFBFE70-FE74FE76-FEFCFF66-FF6FFF71-FF9DFFA0-FFBEFFC2-FFC7FFCA-FFCFFFD2-FFD7FFDA-FFDC",M:"0300-036F0483-04890591-05BD05BF05C105C205C405C505C70610-061A064B-065E067006D6-06DC06DE-06E406E706E806EA-06ED07110730-074A07A6-07B007EB-07F30816-0819081B-08230825-08270829-082D0900-0903093C093E-094E0951-0955096209630981-098309BC09BE-09C409C709C809CB-09CD09D709E209E30A01-0A030A3C0A3E-0A420A470A480A4B-0A4D0A510A700A710A750A81-0A830ABC0ABE-0AC50AC7-0AC90ACB-0ACD0AE20AE30B01-0B030B3C0B3E-0B440B470B480B4B-0B4D0B560B570B620B630B820BBE-0BC20BC6-0BC80BCA-0BCD0BD70C01-0C030C3E-0C440C46-0C480C4A-0C4D0C550C560C620C630C820C830CBC0CBE-0CC40CC6-0CC80CCA-0CCD0CD50CD60CE20CE30D020D030D3E-0D440D46-0D480D4A-0D4D0D570D620D630D820D830DCA0DCF-0DD40DD60DD8-0DDF0DF20DF30E310E34-0E3A0E47-0E4E0EB10EB4-0EB90EBB0EBC0EC8-0ECD0F180F190F350F370F390F3E0F3F0F71-0F840F860F870F90-0F970F99-0FBC0FC6102B-103E1056-1059105E-10601062-10641067-106D1071-10741082-108D108F109A-109D135F1712-17141732-1734175217531772177317B6-17D317DD180B-180D18A91920-192B1930-193B19B0-19C019C819C91A17-1A1B1A55-1A5E1A60-1A7C1A7F1B00-1B041B34-1B441B6B-1B731B80-1B821BA1-1BAA1C24-1C371CD0-1CD21CD4-1CE81CED1CF21DC0-1DE61DFD-1DFF20D0-20F02CEF-2CF12DE0-2DFF302A-302F3099309AA66F-A672A67CA67DA6F0A6F1A802A806A80BA823-A827A880A881A8B4-A8C4A8E0-A8F1A926-A92DA947-A953A980-A983A9B3-A9C0AA29-AA36AA43AA4CAA4DAA7BAAB0AAB2-AAB4AAB7AAB8AABEAABFAAC1ABE3-ABEAABECABEDFB1EFE00-FE0FFE20-FE26",Mn:"0300-036F0483-04870591-05BD05BF05C105C205C405C505C70610-061A064B-065E067006D6-06DC06DF-06E406E706E806EA-06ED07110730-074A07A6-07B007EB-07F30816-0819081B-08230825-08270829-082D0900-0902093C0941-0948094D0951-095509620963098109BC09C1-09C409CD09E209E30A010A020A3C0A410A420A470A480A4B-0A4D0A510A700A710A750A810A820ABC0AC1-0AC50AC70AC80ACD0AE20AE30B010B3C0B3F0B41-0B440B4D0B560B620B630B820BC00BCD0C3E-0C400C46-0C480C4A-0C4D0C550C560C620C630CBC0CBF0CC60CCC0CCD0CE20CE30D41-0D440D4D0D620D630DCA0DD2-0DD40DD60E310E34-0E3A0E47-0E4E0EB10EB4-0EB90EBB0EBC0EC8-0ECD0F180F190F350F370F390F71-0F7E0F80-0F840F860F870F90-0F970F99-0FBC0FC6102D-10301032-10371039103A103D103E10581059105E-10601071-1074108210851086108D109D135F1712-17141732-1734175217531772177317B7-17BD17C617C9-17D317DD180B-180D18A91920-19221927192819321939-193B1A171A181A561A58-1A5E1A601A621A65-1A6C1A73-1A7C1A7F1B00-1B031B341B36-1B3A1B3C1B421B6B-1B731B801B811BA2-1BA51BA81BA91C2C-1C331C361C371CD0-1CD21CD4-1CE01CE2-1CE81CED1DC0-1DE61DFD-1DFF20D0-20DC20E120E5-20F02CEF-2CF12DE0-2DFF302A-302F3099309AA66FA67CA67DA6F0A6F1A802A806A80BA825A826A8C4A8E0-A8F1A926-A92DA947-A951A980-A982A9B3A9B6-A9B9A9BCAA29-AA2EAA31AA32AA35AA36AA43AA4CAAB0AAB2-AAB4AAB7AAB8AABEAABFAAC1ABE5ABE8ABEDFB1EFE00-FE0FFE20-FE26",Mc:"0903093E-09400949-094C094E0982098309BE-09C009C709C809CB09CC09D70A030A3E-0A400A830ABE-0AC00AC90ACB0ACC0B020B030B3E0B400B470B480B4B0B4C0B570BBE0BBF0BC10BC20BC6-0BC80BCA-0BCC0BD70C01-0C030C41-0C440C820C830CBE0CC0-0CC40CC70CC80CCA0CCB0CD50CD60D020D030D3E-0D400D46-0D480D4A-0D4C0D570D820D830DCF-0DD10DD8-0DDF0DF20DF30F3E0F3F0F7F102B102C10311038103B103C105610571062-10641067-106D108310841087-108C108F109A-109C17B617BE-17C517C717C81923-19261929-192B193019311933-193819B0-19C019C819C91A19-1A1B1A551A571A611A631A641A6D-1A721B041B351B3B1B3D-1B411B431B441B821BA11BA61BA71BAA1C24-1C2B1C341C351CE11CF2A823A824A827A880A881A8B4-A8C3A952A953A983A9B4A9B5A9BAA9BBA9BD-A9C0AA2FAA30AA33AA34AA4DAA7BABE3ABE4ABE6ABE7ABE9ABEAABEC",Me:"0488048906DE20DD-20E020E2-20E4A670-A672",N:"0030-003900B200B300B900BC-00BE0660-066906F0-06F907C0-07C90966-096F09E6-09EF09F4-09F90A66-0A6F0AE6-0AEF0B66-0B6F0BE6-0BF20C66-0C6F0C78-0C7E0CE6-0CEF0D66-0D750E50-0E590ED0-0ED90F20-0F331040-10491090-10991369-137C16EE-16F017E0-17E917F0-17F91810-18191946-194F19D0-19DA1A80-1A891A90-1A991B50-1B591BB0-1BB91C40-1C491C50-1C5920702074-20792080-20892150-21822185-21892460-249B24EA-24FF2776-27932CFD30073021-30293038-303A3192-31953220-32293251-325F3280-328932B1-32BFA620-A629A6E6-A6EFA830-A835A8D0-A8D9A900-A909A9D0-A9D9AA50-AA59ABF0-ABF9FF10-FF19",Nd:"0030-00390660-066906F0-06F907C0-07C90966-096F09E6-09EF0A66-0A6F0AE6-0AEF0B66-0B6F0BE6-0BEF0C66-0C6F0CE6-0CEF0D66-0D6F0E50-0E590ED0-0ED90F20-0F291040-10491090-109917E0-17E91810-18191946-194F19D0-19DA1A80-1A891A90-1A991B50-1B591BB0-1BB91C40-1C491C50-1C59A620-A629A8D0-A8D9A900-A909A9D0-A9D9AA50-AA59ABF0-ABF9FF10-FF19",Nl:"16EE-16F02160-21822185-218830073021-30293038-303AA6E6-A6EF",No:"00B200B300B900BC-00BE09F4-09F90BF0-0BF20C78-0C7E0D70-0D750F2A-0F331369-137C17F0-17F920702074-20792080-20892150-215F21892460-249B24EA-24FF2776-27932CFD3192-31953220-32293251-325F3280-328932B1-32BFA830-A835",P:"0021-00230025-002A002C-002F003A003B003F0040005B-005D005F007B007D00A100AB00B700BB00BF037E0387055A-055F0589058A05BE05C005C305C605F305F40609060A060C060D061B061E061F066A-066D06D40700-070D07F7-07F90830-083E0964096509700DF40E4F0E5A0E5B0F04-0F120F3A-0F3D0F850FD0-0FD4104A-104F10FB1361-13681400166D166E169B169C16EB-16ED1735173617D4-17D617D8-17DA1800-180A1944194519DE19DF1A1E1A1F1AA0-1AA61AA8-1AAD1B5A-1B601C3B-1C3F1C7E1C7F1CD32010-20272030-20432045-20512053-205E207D207E208D208E2329232A2768-277527C527C627E6-27EF2983-299829D8-29DB29FC29FD2CF9-2CFC2CFE2CFF2E00-2E2E2E302E313001-30033008-30113014-301F3030303D30A030FBA4FEA4FFA60D-A60FA673A67EA6F2-A6F7A874-A877A8CEA8CFA8F8-A8FAA92EA92FA95FA9C1-A9CDA9DEA9DFAA5C-AA5FAADEAADFABEBFD3EFD3FFE10-FE19FE30-FE52FE54-FE61FE63FE68FE6AFE6BFF01-FF03FF05-FF0AFF0C-FF0FFF1AFF1BFF1FFF20FF3B-FF3DFF3FFF5BFF5DFF5F-FF65",Pd:"002D058A05BE140018062010-20152E172E1A301C303030A0FE31FE32FE58FE63FF0D",Ps:"0028005B007B0F3A0F3C169B201A201E2045207D208D23292768276A276C276E27702772277427C527E627E827EA27EC27EE2983298529872989298B298D298F299129932995299729D829DA29FC2E222E242E262E283008300A300C300E3010301430163018301A301DFD3EFE17FE35FE37FE39FE3BFE3DFE3FFE41FE43FE47FE59FE5BFE5DFF08FF3BFF5BFF5FFF62",Pe:"0029005D007D0F3B0F3D169C2046207E208E232A2769276B276D276F27712773277527C627E727E927EB27ED27EF298429862988298A298C298E2990299229942996299829D929DB29FD2E232E252E272E293009300B300D300F3011301530173019301B301E301FFD3FFE18FE36FE38FE3AFE3CFE3EFE40FE42FE44FE48FE5AFE5CFE5EFF09FF3DFF5DFF60FF63",Pi:"00AB2018201B201C201F20392E022E042E092E0C2E1C2E20",Pf:"00BB2019201D203A2E032E052E0A2E0D2E1D2E21",Pc:"005F203F20402054FE33FE34FE4D-FE4FFF3F",Po:"0021-00230025-0027002A002C002E002F003A003B003F0040005C00A100B700BF037E0387055A-055F058905C005C305C605F305F40609060A060C060D061B061E061F066A-066D06D40700-070D07F7-07F90830-083E0964096509700DF40E4F0E5A0E5B0F04-0F120F850FD0-0FD4104A-104F10FB1361-1368166D166E16EB-16ED1735173617D4-17D617D8-17DA1800-18051807-180A1944194519DE19DF1A1E1A1F1AA0-1AA61AA8-1AAD1B5A-1B601C3B-1C3F1C7E1C7F1CD3201620172020-20272030-2038203B-203E2041-20432047-205120532055-205E2CF9-2CFC2CFE2CFF2E002E012E06-2E082E0B2E0E-2E162E182E192E1B2E1E2E1F2E2A-2E2E2E302E313001-3003303D30FBA4FEA4FFA60D-A60FA673A67EA6F2-A6F7A874-A877A8CEA8CFA8F8-A8FAA92EA92FA95FA9C1-A9CDA9DEA9DFAA5C-AA5FAADEAADFABEBFE10-FE16FE19FE30FE45FE46FE49-FE4CFE50-FE52FE54-FE57FE5F-FE61FE68FE6AFE6BFF01-FF03FF05-FF07FF0AFF0CFF0EFF0FFF1AFF1BFF1FFF20FF3CFF61FF64FF65",S:"0024002B003C-003E005E0060007C007E00A2-00A900AC00AE-00B100B400B600B800D700F702C2-02C502D2-02DF02E5-02EB02ED02EF-02FF03750384038503F604820606-0608060B060E060F06E906FD06FE07F609F209F309FA09FB0AF10B700BF3-0BFA0C7F0CF10CF20D790E3F0F01-0F030F13-0F170F1A-0F1F0F340F360F380FBE-0FC50FC7-0FCC0FCE0FCF0FD5-0FD8109E109F13601390-139917DB194019E0-19FF1B61-1B6A1B74-1B7C1FBD1FBF-1FC11FCD-1FCF1FDD-1FDF1FED-1FEF1FFD1FFE20442052207A-207C208A-208C20A0-20B8210021012103-21062108210921142116-2118211E-2123212521272129212E213A213B2140-2144214A-214D214F2190-2328232B-23E82400-24262440-244A249C-24E92500-26CD26CF-26E126E326E8-26FF2701-27042706-2709270C-27272729-274B274D274F-27522756-275E2761-276727942798-27AF27B1-27BE27C0-27C427C7-27CA27CC27D0-27E527F0-29822999-29D729DC-29FB29FE-2B4C2B50-2B592CE5-2CEA2E80-2E992E9B-2EF32F00-2FD52FF0-2FFB300430123013302030363037303E303F309B309C319031913196-319F31C0-31E33200-321E322A-32503260-327F328A-32B032C0-32FE3300-33FF4DC0-4DFFA490-A4C6A700-A716A720A721A789A78AA828-A82BA836-A839AA77-AA79FB29FDFCFDFDFE62FE64-FE66FE69FF04FF0BFF1C-FF1EFF3EFF40FF5CFF5EFFE0-FFE6FFE8-FFEEFFFCFFFD",Sm:"002B003C-003E007C007E00AC00B100D700F703F60606-060820442052207A-207C208A-208C2140-2144214B2190-2194219A219B21A021A321A621AE21CE21CF21D221D421F4-22FF2308-230B23202321237C239B-23B323DC-23E125B725C125F8-25FF266F27C0-27C427C7-27CA27CC27D0-27E527F0-27FF2900-29822999-29D729DC-29FB29FE-2AFF2B30-2B442B47-2B4CFB29FE62FE64-FE66FF0BFF1C-FF1EFF5CFF5EFFE2FFE9-FFEC",Sc:"002400A2-00A5060B09F209F309FB0AF10BF90E3F17DB20A0-20B8A838FDFCFE69FF04FFE0FFE1FFE5FFE6",Sk:"005E006000A800AF00B400B802C2-02C502D2-02DF02E5-02EB02ED02EF-02FF0375038403851FBD1FBF-1FC11FCD-1FCF1FDD-1FDF1FED-1FEF1FFD1FFE309B309CA700-A716A720A721A789A78AFF3EFF40FFE3",So:"00A600A700A900AE00B000B60482060E060F06E906FD06FE07F609FA0B700BF3-0BF80BFA0C7F0CF10CF20D790F01-0F030F13-0F170F1A-0F1F0F340F360F380FBE-0FC50FC7-0FCC0FCE0FCF0FD5-0FD8109E109F13601390-1399194019E0-19FF1B61-1B6A1B74-1B7C210021012103-21062108210921142116-2118211E-2123212521272129212E213A213B214A214C214D214F2195-2199219C-219F21A121A221A421A521A7-21AD21AF-21CD21D021D121D321D5-21F32300-2307230C-231F2322-2328232B-237B237D-239A23B4-23DB23E2-23E82400-24262440-244A249C-24E92500-25B625B8-25C025C2-25F72600-266E2670-26CD26CF-26E126E326E8-26FF2701-27042706-2709270C-27272729-274B274D274F-27522756-275E2761-276727942798-27AF27B1-27BE2800-28FF2B00-2B2F2B452B462B50-2B592CE5-2CEA2E80-2E992E9B-2EF32F00-2FD52FF0-2FFB300430123013302030363037303E303F319031913196-319F31C0-31E33200-321E322A-32503260-327F328A-32B032C0-32FE3300-33FF4DC0-4DFFA490-A4C6A828-A82BA836A837A839AA77-AA79FDFDFFE4FFE8FFEDFFEEFFFCFFFD",Z:"002000A01680180E2000-200A20282029202F205F3000",Zs:"002000A01680180E2000-200A202F205F3000",Zl:"2028",Zp:"2029",C:"0000-001F007F-009F00AD03780379037F-0383038B038D03A20526-05300557055805600588058B-059005C8-05CF05EB-05EF05F5-0605061C061D0620065F06DD070E070F074B074C07B2-07BF07FB-07FF082E082F083F-08FF093A093B094F095609570973-097809800984098D098E0991099209A909B109B3-09B509BA09BB09C509C609C909CA09CF-09D609D8-09DB09DE09E409E509FC-0A000A040A0B-0A0E0A110A120A290A310A340A370A3A0A3B0A3D0A43-0A460A490A4A0A4E-0A500A52-0A580A5D0A5F-0A650A76-0A800A840A8E0A920AA90AB10AB40ABA0ABB0AC60ACA0ACE0ACF0AD1-0ADF0AE40AE50AF00AF2-0B000B040B0D0B0E0B110B120B290B310B340B3A0B3B0B450B460B490B4A0B4E-0B550B58-0B5B0B5E0B640B650B72-0B810B840B8B-0B8D0B910B96-0B980B9B0B9D0BA0-0BA20BA5-0BA70BAB-0BAD0BBA-0BBD0BC3-0BC50BC90BCE0BCF0BD1-0BD60BD8-0BE50BFB-0C000C040C0D0C110C290C340C3A-0C3C0C450C490C4E-0C540C570C5A-0C5F0C640C650C70-0C770C800C810C840C8D0C910CA90CB40CBA0CBB0CC50CC90CCE-0CD40CD7-0CDD0CDF0CE40CE50CF00CF3-0D010D040D0D0D110D290D3A-0D3C0D450D490D4E-0D560D58-0D5F0D640D650D76-0D780D800D810D840D97-0D990DB20DBC0DBE0DBF0DC7-0DC90DCB-0DCE0DD50DD70DE0-0DF10DF5-0E000E3B-0E3E0E5C-0E800E830E850E860E890E8B0E8C0E8E-0E930E980EA00EA40EA60EA80EA90EAC0EBA0EBE0EBF0EC50EC70ECE0ECF0EDA0EDB0EDE-0EFF0F480F6D-0F700F8C-0F8F0F980FBD0FCD0FD9-0FFF10C6-10CF10FD-10FF1249124E124F12571259125E125F1289128E128F12B112B612B712BF12C112C612C712D7131113161317135B-135E137D-137F139A-139F13F5-13FF169D-169F16F1-16FF170D1715-171F1737-173F1754-175F176D17711774-177F17B417B517DE17DF17EA-17EF17FA-17FF180F181A-181F1878-187F18AB-18AF18F6-18FF191D-191F192C-192F193C-193F1941-1943196E196F1975-197F19AC-19AF19CA-19CF19DB-19DD1A1C1A1D1A5F1A7D1A7E1A8A-1A8F1A9A-1A9F1AAE-1AFF1B4C-1B4F1B7D-1B7F1BAB-1BAD1BBA-1BFF1C38-1C3A1C4A-1C4C1C80-1CCF1CF3-1CFF1DE7-1DFC1F161F171F1E1F1F1F461F471F4E1F4F1F581F5A1F5C1F5E1F7E1F7F1FB51FC51FD41FD51FDC1FF01FF11FF51FFF200B-200F202A-202E2060-206F20722073208F2095-209F20B9-20CF20F1-20FF218A-218F23E9-23FF2427-243F244B-245F26CE26E226E4-26E727002705270A270B2728274C274E2753-2755275F27602795-279727B027BF27CB27CD-27CF2B4D-2B4F2B5A-2BFF2C2F2C5F2CF2-2CF82D26-2D2F2D66-2D6E2D70-2D7F2D97-2D9F2DA72DAF2DB72DBF2DC72DCF2DD72DDF2E32-2E7F2E9A2EF4-2EFF2FD6-2FEF2FFC-2FFF3040309730983100-3104312E-3130318F31B8-31BF31E4-31EF321F32FF4DB6-4DBF9FCC-9FFFA48D-A48FA4C7-A4CFA62C-A63FA660A661A674-A67BA698-A69FA6F8-A6FFA78D-A7FAA82C-A82FA83A-A83FA878-A87FA8C5-A8CDA8DA-A8DFA8FC-A8FFA954-A95EA97D-A97FA9CEA9DA-A9DDA9E0-A9FFAA37-AA3FAA4EAA4FAA5AAA5BAA7C-AA7FAAC3-AADAAAE0-ABBFABEEABEFABFA-ABFFD7A4-D7AFD7C7-D7CAD7FC-F8FFFA2EFA2FFA6EFA6FFADA-FAFFFB07-FB12FB18-FB1CFB37FB3DFB3FFB42FB45FBB2-FBD2FD40-FD4FFD90FD91FDC8-FDEFFDFEFDFFFE1A-FE1FFE27-FE2FFE53FE67FE6C-FE6FFE75FEFD-FF00FFBF-FFC1FFC8FFC9FFD0FFD1FFD8FFD9FFDD-FFDFFFE7FFEF-FFFBFFFEFFFF",Cc:"0000-001F007F-009F",Cf:"00AD0600-060306DD070F17B417B5200B-200F202A-202E2060-2064206A-206FFEFFFFF9-FFFB",Co:"E000-F8FF",Cs:"D800-DFFF",Cn:"03780379037F-0383038B038D03A20526-05300557055805600588058B-059005C8-05CF05EB-05EF05F5-05FF06040605061C061D0620065F070E074B074C07B2-07BF07FB-07FF082E082F083F-08FF093A093B094F095609570973-097809800984098D098E0991099209A909B109B3-09B509BA09BB09C509C609C909CA09CF-09D609D8-09DB09DE09E409E509FC-0A000A040A0B-0A0E0A110A120A290A310A340A370A3A0A3B0A3D0A43-0A460A490A4A0A4E-0A500A52-0A580A5D0A5F-0A650A76-0A800A840A8E0A920AA90AB10AB40ABA0ABB0AC60ACA0ACE0ACF0AD1-0ADF0AE40AE50AF00AF2-0B000B040B0D0B0E0B110B120B290B310B340B3A0B3B0B450B460B490B4A0B4E-0B550B58-0B5B0B5E0B640B650B72-0B810B840B8B-0B8D0B910B96-0B980B9B0B9D0BA0-0BA20BA5-0BA70BAB-0BAD0BBA-0BBD0BC3-0BC50BC90BCE0BCF0BD1-0BD60BD8-0BE50BFB-0C000C040C0D0C110C290C340C3A-0C3C0C450C490C4E-0C540C570C5A-0C5F0C640C650C70-0C770C800C810C840C8D0C910CA90CB40CBA0CBB0CC50CC90CCE-0CD40CD7-0CDD0CDF0CE40CE50CF00CF3-0D010D040D0D0D110D290D3A-0D3C0D450D490D4E-0D560D58-0D5F0D640D650D76-0D780D800D810D840D97-0D990DB20DBC0DBE0DBF0DC7-0DC90DCB-0DCE0DD50DD70DE0-0DF10DF5-0E000E3B-0E3E0E5C-0E800E830E850E860E890E8B0E8C0E8E-0E930E980EA00EA40EA60EA80EA90EAC0EBA0EBE0EBF0EC50EC70ECE0ECF0EDA0EDB0EDE-0EFF0F480F6D-0F700F8C-0F8F0F980FBD0FCD0FD9-0FFF10C6-10CF10FD-10FF1249124E124F12571259125E125F1289128E128F12B112B612B712BF12C112C612C712D7131113161317135B-135E137D-137F139A-139F13F5-13FF169D-169F16F1-16FF170D1715-171F1737-173F1754-175F176D17711774-177F17DE17DF17EA-17EF17FA-17FF180F181A-181F1878-187F18AB-18AF18F6-18FF191D-191F192C-192F193C-193F1941-1943196E196F1975-197F19AC-19AF19CA-19CF19DB-19DD1A1C1A1D1A5F1A7D1A7E1A8A-1A8F1A9A-1A9F1AAE-1AFF1B4C-1B4F1B7D-1B7F1BAB-1BAD1BBA-1BFF1C38-1C3A1C4A-1C4C1C80-1CCF1CF3-1CFF1DE7-1DFC1F161F171F1E1F1F1F461F471F4E1F4F1F581F5A1F5C1F5E1F7E1F7F1FB51FC51FD41FD51FDC1FF01FF11FF51FFF2065-206920722073208F2095-209F20B9-20CF20F1-20FF218A-218F23E9-23FF2427-243F244B-245F26CE26E226E4-26E727002705270A270B2728274C274E2753-2755275F27602795-279727B027BF27CB27CD-27CF2B4D-2B4F2B5A-2BFF2C2F2C5F2CF2-2CF82D26-2D2F2D66-2D6E2D70-2D7F2D97-2D9F2DA72DAF2DB72DBF2DC72DCF2DD72DDF2E32-2E7F2E9A2EF4-2EFF2FD6-2FEF2FFC-2FFF3040309730983100-3104312E-3130318F31B8-31BF31E4-31EF321F32FF4DB6-4DBF9FCC-9FFFA48D-A48FA4C7-A4CFA62C-A63FA660A661A674-A67BA698-A69FA6F8-A6FFA78D-A7FAA82C-A82FA83A-A83FA878-A87FA8C5-A8CDA8DA-A8DFA8FC-A8FFA954-A95EA97D-A97FA9CEA9DA-A9DDA9E0-A9FFAA37-AA3FAA4EAA4FAA5AAA5BAA7C-AA7FAAC3-AADAAAE0-ABBFABEEABEFABFA-ABFFD7A4-D7AFD7C7-D7CAD7FC-D7FFFA2EFA2FFA6EFA6FFADA-FAFFFB07-FB12FB18-FB1CFB37FB3DFB3FFB42FB45FBB2-FBD2FD40-FD4FFD90FD91FDC8-FDEFFDFEFDFFFE1A-FE1FFE27-FE2FFE53FE67FE6C-FE6FFE75FEFDFEFEFF00FFBF-FFC1FFC8FFC9FFD0FFD1FFD8FFD9FFDD-FFDFFFE7FFEF-FFF8FFFEFFFF"})}),ace.define("ace/token_iterator",["require","exports","module"],function(e,t,n){"use strict";var r=function(e,t,n){this.$session=e,this.$row=t,this.$rowTokens=e.getTokens(t);var r=e.getTokenAt(t,n);this.$tokenIndex=r?r.index:-1};(function(){this.stepBackward=function(){this.$tokenIndex-=1;while(this.$tokenIndex<0){this.$row-=1;if(this.$row<0)return this.$row=0,null;this.$rowTokens=this.$session.getTokens(this.$row),this.$tokenIndex=this.$rowTokens.length-1}return this.$rowTokens[this.$tokenIndex]},this.stepForward=function(){this.$tokenIndex+=1;var e;while(this.$tokenIndex>=this.$rowTokens.length){this.$row+=1,e||(e=this.$session.getLength());if(this.$row>=e)return this.$row=e-1,null;this.$rowTokens=this.$session.getTokens(this.$row),this.$tokenIndex=0}return this.$rowTokens[this.$tokenIndex]},this.getCurrentToken=function(){return this.$rowTokens[this.$tokenIndex]},this.getCurrentTokenRow=function(){return this.$row},this.getCurrentTokenColumn=function(){var e=this.$rowTokens,t=this.$tokenIndex,n=e[t].start;if(n!==undefined)return n;n=0;while(t>0)t-=1,n+=e[t].value.length;return n}}).call(r.prototype),t.TokenIterator=r}),ace.define("ace/mode/text",["require","exports","module","ace/tokenizer","ace/mode/text_highlight_rules","ace/mode/behaviour","ace/unicode","ace/lib/lang","ace/token_iterator","ace/range"],function(e,t,n){"use strict";var r=e("../tokenizer").Tokenizer,i=e("./text_highlight_rules").TextHighlightRules,s=e("./behaviour").Behaviour,o=e("../unicode"),u=e("../lib/lang"),a=e("../token_iterator").TokenIterator,f=e("../range").Range,l=function(){this.HighlightRules=i,this.$behaviour=new s};(function(){this.tokenRe=new RegExp("^["+o.packages.L+o.packages.Mn+o.packages.Mc+o.packages.Nd+o.packages.Pc+"\\$_]+","g"),this.nonTokenRe=new RegExp("^(?:[^"+o.packages.L+o.packages.Mn+o.packages.Mc+o.packages.Nd+o.packages.Pc+"\\$_]|\\s])+","g"),this.getTokenizer=function(){return this.$tokenizer||(this.$highlightRules=this.$highlightRules||new this.HighlightRules,this.$tokenizer=new r(this.$highlightRules.getRules())),this.$tokenizer},this.lineCommentStart="",this.blockComment="",this.toggleCommentLines=function(e,t,n,r){function w(e){for(var t=n;t<=r;t++)e(i.getLine(t),t)}var i=t.doc,s=!0,o=!0,a=Infinity,f=t.getTabSize(),l=!1;if(!this.lineCommentStart){if(!this.blockComment)return!1;var c=this.blockComment.start,h=this.blockComment.end,p=new RegExp("^(\\s*)(?:"+u.escapeRegExp(c)+")"),d=new RegExp("(?:"+u.escapeRegExp(h)+")\\s*$"),v=function(e,t){if(g(e,t))return;if(!s||/\S/.test(e))i.insertInLine({row:t,column:e.length},h),i.insertInLine({row:t,column:a},c)},m=function(e,t){var n;(n=e.match(d))&&i.removeInLine(t,e.length-n[0].length,e.length),(n=e.match(p))&&i.removeInLine(t,n[1].length,n[0].length)},g=function(e,n){if(p.test(e))return!0;var r=t.getTokens(n);for(var i=0;i<r.length;i++)if(r[i].type==="comment")return!0}}else{if(Array.isArray(this.lineCommentStart))var p=this.lineCommentStart.map(u.escapeRegExp).join("|"),c=this.lineCommentStart[0];else var p=u.escapeRegExp(this.lineCommentStart),c=this.lineCommentStart;p=new RegExp("^(\\s*)(?:"+p+") ?"),l=t.getUseSoftTabs();var m=function(e,t){var n=e.match(p);if(!n)return;var r=n[1].length,s=n[0].length;!b(e,r,s)&&n[0][s-1]==" "&&s--,i.removeInLine(t,r,s)},y=c+" ",v=function(e,t){if(!s||/\S/.test(e))b(e,a,a)?i.insertInLine({row:t,column:a},y):i.insertInLine({row:t,column:a},c)},g=function(e,t){return p.test(e)},b=function(e,t,n){var r=0;while(t--&&e.charAt(t)==" ")r++;if(r%f!=0)return!1;var r=0;while(e.charAt(n++)==" ")r++;return f>2?r%f!=f-1:r%f==0}}var E=Infinity;w(function(e,t){var n=e.search(/\S/);n!==-1?(n<a&&(a=n),o&&!g(e,t)&&(o=!1)):E>e.length&&(E=e.length)}),a==Infinity&&(a=E,s=!1,o=!1),l&&a%f!=0&&(a=Math.floor(a/f)*f),w(o?m:v)},this.toggleBlockComment=function(e,t,n,r){var i=this.blockComment;if(!i)return;!i.start&&i[0]&&(i=i[0]);var s=new a(t,r.row,r.column),o=s.getCurrentToken(),u=t.selection,l=t.selection.toOrientedRange(),c,h;if(o&&/comment/.test(o.type)){var p,d;while(o&&/comment/.test(o.type)){var v=o.value.indexOf(i.start);if(v!=-1){var m=s.getCurrentTokenRow(),g=s.getCurrentTokenColumn()+v;p=new f(m,g,m,g+i.start.length);break}o=s.stepBackward()}var s=new a(t,r.row,r.column),o=s.getCurrentToken();while(o&&/comment/.test(o.type)){var v=o.value.indexOf(i.end);if(v!=-1){var m=s.getCurrentTokenRow(),g=s.getCurrentTokenColumn()+v;d=new f(m,g,m,g+i.end.length);break}o=s.stepForward()}d&&t.remove(d),p&&(t.remove(p),c=p.start.row,h=-i.start.length)}else h=i.start.length,c=n.start.row,t.insert(n.end,i.end),t.insert(n.start,i.start);l.start.row==c&&(l.start.column+=h),l.end.row==c&&(l.end.column+=h),t.selection.fromOrientedRange(l)},this.getNextLineIndent=function(e,t,n){return this.$getIndent(t)},this.checkOutdent=function(e,t,n){return!1},this.autoOutdent=function(e,t,n){},this.$getIndent=function(e){return e.match(/^\s*/)[0]},this.createWorker=function(e){return null},this.createModeDelegates=function(e){this.$embeds=[],this.$modes={};for(var t in e)e[t]&&(this.$embeds.push(t),this.$modes[t]=new e[t]);var n=["toggleBlockComment","toggleCommentLines","getNextLineIndent","checkOutdent","autoOutdent","transformAction","getCompletions"];for(var t=0;t<n.length;t++)(function(e){var r=n[t],i=e[r];e[n[t]]=function(){return this.$delegator(r,arguments,i)}})(this)},this.$delegator=function(e,t,n){var r=t[0];typeof r!="string"&&(r=r[0]);for(var i=0;i<this.$embeds.length;i++){if(!this.$modes[this.$embeds[i]])continue;var s=r.split(this.$embeds[i]);if(!s[0]&&s[1]){t[0]=s[1];var o=this.$modes[this.$embeds[i]];return o[e].apply(o,t)}}var u=n.apply(this,t);return n?u:undefined},this.transformAction=function(e,t,n,r,i){if(this.$behaviour){var s=this.$behaviour.getBehaviours();for(var o in s)if(s[o][t]){var u=s[o][t].apply(this,arguments);if(u)return u}}},this.getKeywords=function(e){if(!this.completionKeywords){var t=this.$tokenizer.rules,n=[];for(var r in t){var i=t[r];for(var s=0,o=i.length;s<o;s++)if(typeof i[s].token=="string")/keyword|support|storage/.test(i[s].token)&&n.push(i[s].regex);else if(typeof i[s].token=="object")for(var u=0,a=i[s].token.length;u<a;u++)if(/keyword|support|storage/.test(i[s].token[u])){var r=i[s].regex.match(/\(.+?\)/g)[u];n.push(r.substr(1,r.length-2))}}this.completionKeywords=n}return e?n.concat(this.$keywordList||[]):this.$keywordList},this.$createKeywordList=function(){return this.$highlightRules||this.getTokenizer(),this.$keywordList=this.$highlightRules.$keywordList||[]},this.getCompletions=function(e,t,n,r){var i=this.$keywordList||this.$createKeywordList();return i.map(function(e){return{name:e,value:e,score:0,meta:"keyword"}})},this.$id="ace/mode/text"}).call(l.prototype),t.Mode=l}),ace.define("ace/anchor",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/event_emitter").EventEmitter,s=t.Anchor=function(e,t,n){this.$onChange=this.onChange.bind(this),this.attach(e),typeof n=="undefined"?this.setPosition(t.row,t.column):this.setPosition(t,n)};(function(){r.implement(this,i),this.getPosition=function(){return this.$clipPositionToDocument(this.row,this.column)},this.getDocument=function(){return this.document},this.$insertRight=!1,this.onChange=function(e){var t=e.data,n=t.range;if(n.start.row==n.end.row&&n.start.row!=this.row)return;if(n.start.row>this.row)return;if(n.start.row==this.row&&n.start.column>this.column)return;var r=this.row,i=this.column,s=n.start,o=n.end;if(t.action==="insertText")if(s.row===r&&s.column<=i){if(s.column!==i||!this.$insertRight)s.row===o.row?i+=o.column-s.column:(i-=s.column,r+=o.row-s.row)}else s.row!==o.row&&s.row<r&&(r+=o.row-s.row);else t.action==="insertLines"?(s.row!==r||i!==0||!this.$insertRight)&&s.row<=r&&(r+=o.row-s.row):t.action==="removeText"?s.row===r&&s.column<i?o.column>=i?i=s.column:i=Math.max(0,i-(o.column-s.column)):s.row!==o.row&&s.row<r?(o.row===r&&(i=Math.max(0,i-o.column)+s.column),r-=o.row-s.row):o.row===r&&(r-=o.row-s.row,i=Math.max(0,i-o.column)+s.column):t.action=="removeLines"&&s.row<=r&&(o.row<=r?r-=o.row-s.row:(r=s.row,i=0));this.setPosition(r,i,!0)},this.setPosition=function(e,t,n){var r;n?r={row:e,column:t}:r=this.$clipPositionToDocument(e,t);if(this.row==r.row&&this.column==r.column)return;var i={row:this.row,column:this.column};this.row=r.row,this.column=r.column,this._signal("change",{old:i,value:r})},this.detach=function(){this.document.removeEventListener("change",this.$onChange)},this.attach=function(e){this.document=e||this.document,this.document.on("change",this.$onChange)},this.$clipPositionToDocument=function(e,t){var n={};return e>=this.document.getLength()?(n.row=Math.max(0,this.document.getLength()-1),n.column=this.document.getLine(n.row).length):e<0?(n.row=0,n.column=0):(n.row=e,n.column=Math.min(this.document.getLine(n.row).length,Math.max(0,t))),t<0&&(n.column=0),n}}).call(s.prototype)}),ace.define("ace/document",["require","exports","module","ace/lib/oop","ace/lib/event_emitter","ace/range","ace/anchor"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/event_emitter").EventEmitter,s=e("./range").Range,o=e("./anchor").Anchor,u=function(e){this.$lines=[],e.length===0?this.$lines=[""]:Array.isArray(e)?this._insertLines(0,e):this.insert({row:0,column:0},e)};(function(){r.implement(this,i),this.setValue=function(e){var t=this.getLength();this.remove(new s(0,0,t,this.getLine(t-1).length)),this.insert({row:0,column:0},e)},this.getValue=function(){return this.getAllLines().join(this.getNewLineCharacter())},this.createAnchor=function(e,t){return new o(this,e,t)},"aaa".split(/a/).length===0?this.$split=function(e){return e.replace(/\r\n|\r/g,"\n").split("\n")}:this.$split=function(e){return e.split(/\r\n|\r|\n/)},this.$detectNewLine=function(e){var t=e.match(/^.*?(\r\n|\r|\n)/m);this.$autoNewLine=t?t[1]:"\n",this._signal("changeNewLineMode")},this.getNewLineCharacter=function(){switch(this.$newLineMode){case"windows":return"\r\n";case"unix":return"\n";default:return this.$autoNewLine||"\n"}},this.$autoNewLine="",this.$newLineMode="auto",this.setNewLineMode=function(e){if(this.$newLineMode===e)return;this.$newLineMode=e,this._signal("changeNewLineMode")},this.getNewLineMode=function(){return this.$newLineMode},this.isNewLine=function(e){return e=="\r\n"||e=="\r"||e=="\n"},this.getLine=function(e){return this.$lines[e]||""},this.getLines=function(e,t){return this.$lines.slice(e,t+1)},this.getAllLines=function(){return this.getLines(0,this.getLength())},this.getLength=function(){return this.$lines.length},this.getTextRange=function(e){if(e.start.row==e.end.row)return this.getLine(e.start.row).substring(e.start.column,e.end.column);var t=this.getLines(e.start.row,e.end.row);t[0]=(t[0]||"").substring(e.start.column);var n=t.length-1;return e.end.row-e.start.row==n&&(t[n]=t[n].substring(0,e.end.column)),t.join(this.getNewLineCharacter())},this.$clipPosition=function(e){var t=this.getLength();return e.row>=t?(e.row=Math.max(0,t-1),e.column=this.getLine(t-1).length):e.row<0&&(e.row=0),e},this.insert=function(e,t){if(!t||t.length===0)return e;e=this.$clipPosition(e),this.getLength()<=1&&this.$detectNewLine(t);var n=this.$split(t),r=n.splice(0,1)[0],i=n.length==0?null:n.splice(n.length-1,1)[0];return e=this.insertInLine(e,r),i!==null&&(e=this.insertNewLine(e),e=this._insertLines(e.row,n),e=this.insertInLine(e,i||"")),e},this.insertLines=function(e,t){return e>=this.getLength()?this.insert({row:e,column:0},"\n"+t.join("\n")):this._insertLines(Math.max(e,0),t)},this._insertLines=function(e,t){if(t.length==0)return{row:e,column:0};while(t.length>61440){var n=this._insertLines(e,t.slice(0,61440));t=t.slice(61440),e=n.row}var r=[e,0];r.push.apply(r,t),this.$lines.splice.apply(this.$lines,r);var i=new s(e,0,e+t.length,0),o={action:"insertLines",range:i,lines:t};return this._signal("change",{data:o}),i.end},this.insertNewLine=function(e){e=this.$clipPosition(e);var t=this.$lines[e.row]||"";this.$lines[e.row]=t.substring(0,e.column),this.$lines.splice(e.row+1,0,t.substring(e.column,t.length));var n={row:e.row+1,column:0},r={action:"insertText",range:s.fromPoints(e,n),text:this.getNewLineCharacter()};return this._signal("change",{data:r}),n},this.insertInLine=function(e,t){if(t.length==0)return e;var n=this.$lines[e.row]||"";this.$lines[e.row]=n.substring(0,e.column)+t+n.substring(e.column);var r={row:e.row,column:e.column+t.length},i={action:"insertText",range:s.fromPoints(e,r),text:t};return this._signal("change",{data:i}),r},this.remove=function(e){e instanceof s||(e=s.fromPoints(e.start,e.end)),e.start=this.$clipPosition(e.start),e.end=this.$clipPosition(e.end);if(e.isEmpty())return e.start;var t=e.start.row,n=e.end.row;if(e.isMultiLine()){var r=e.start.column==0?t:t+1,i=n-1;e.end.column>0&&this.removeInLine(n,0,e.end.column),i>=r&&this._removeLines(r,i),r!=t&&(this.removeInLine(t,e.start.column,this.getLine(t).length),this.removeNewLine(e.start.row))}else this.removeInLine(t,e.start.column,e.end.column);return e.start},this.removeInLine=function(e,t,n){if(t==n)return;var r=new s(e,t,e,n),i=this.getLine(e),o=i.substring(t,n),u=i.substring(0,t)+i.substring(n,i.length);this.$lines.splice(e,1,u);var a={action:"removeText",range:r,text:o};return this._signal("change",{data:a}),r.start},this.removeLines=function(e,t){return e<0||t>=this.getLength()?this.remove(new s(e,0,t+1,0)):this._removeLines(e,t)},this._removeLines=function(e,t){var n=new s(e,0,t+1,0),r=this.$lines.splice(e,t-e+1),i={action:"removeLines",range:n,nl:this.getNewLineCharacter(),lines:r};return this._signal("change",{data:i}),r},this.removeNewLine=function(e){var t=this.getLine(e),n=this.getLine(e+1),r=new s(e,t.length,e+1,0),i=t+n;this.$lines.splice(e,2,i);var o={action:"removeText",range:r,text:this.getNewLineCharacter()};this._signal("change",{data:o})},this.replace=function(e,t){e instanceof s||(e=s.fromPoints(e.start,e.end));if(t.length==0&&e.isEmpty())return e.start;if(t==this.getTextRange(e))return e.end;this.remove(e);if(t)var n=this.insert(e.start,t);else n=e.start;return n},this.applyDeltas=function(e){for(var t=0;t<e.length;t++){var n=e[t],r=s.fromPoints(n.range.start,n.range.end);n.action=="insertLines"?this.insertLines(r.start.row,n.lines):n.action=="insertText"?this.insert(r.start,n.text):n.action=="removeLines"?this._removeLines(r.start.row,r.end.row-1):n.action=="removeText"&&this.remove(r)}},this.revertDeltas=function(e){for(var t=e.length-1;t>=0;t--){var n=e[t],r=s.fromPoints(n.range.start,n.range.end);n.action=="insertLines"?this._removeLines(r.start.row,r.end.row-1):n.action=="insertText"?this.remove(r):n.action=="removeLines"?this._insertLines(r.start.row,n.lines):n.action=="removeText"&&this.insert(r.start,n.text)}},this.indexToPosition=function(e,t){var n=this.$lines||this.getAllLines(),r=this.getNewLineCharacter().length;for(var i=t||0,s=n.length;i<s;i++){e-=n[i].length+r;if(e<0)return{row:i,column:e+n[i].length+r}}return{row:s-1,column:n[s-1].length}},this.positionToIndex=function(e,t){var n=this.$lines||this.getAllLines(),r=this.getNewLineCharacter().length,i=0,s=Math.min(e.row,n.length);for(var o=t||0;o<s;++o)i+=n[o].length+r;return i+e.column}}).call(u.prototype),t.Document=u}),ace.define("ace/background_tokenizer",["require","exports","module","ace/lib/oop","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/event_emitter").EventEmitter,s=function(e,t){this.running=!1,this.lines=[],this.states=[],this.currentLine=0,this.tokenizer=e;var n=this;this.$worker=function(){if(!n.running)return;var e=new Date,t=n.currentLine,r=-1,i=n.doc;while(n.lines[t])t++;var s=t,o=i.getLength(),u=0;n.running=!1;while(t<o){n.$tokenizeRow(t),r=t;do t++;while(n.lines[t]);u++;if(u%5===0&&new Date-e>20){n.running=setTimeout(n.$worker,20);break}}n.currentLine=t,s<=r&&n.fireUpdateEvent(s,r)}};(function(){r.implement(this,i),this.setTokenizer=function(e){this.tokenizer=e,this.lines=[],this.states=[],this.start(0)},this.setDocument=function(e){this.doc=e,this.lines=[],this.states=[],this.stop()},this.fireUpdateEvent=function(e,t){var n={first:e,last:t};this._signal("update",{data:n})},this.start=function(e){this.currentLine=Math.min(e||0,this.currentLine,this.doc.getLength()),this.lines.splice(this.currentLine,this.lines.length),this.states.splice(this.currentLine,this.states.length),this.stop(),this.running=setTimeout(this.$worker,700)},this.scheduleStart=function(){this.running||(this.running=setTimeout(this.$worker,700))},this.$updateOnChange=function(e){var t=e.range,n=t.start.row,r=t.end.row-n;if(r===0)this.lines[n]=null;else if(e.action=="removeText"||e.action=="removeLines")this.lines.splice(n,r+1,null),this.states.splice(n,r+1,null);else{var i=Array(r+1);i.unshift(n,1),this.lines.splice.apply(this.lines,i),this.states.splice.apply(this.states,i)}this.currentLine=Math.min(n,this.currentLine,this.doc.getLength()),this.stop()},this.stop=function(){this.running&&clearTimeout(this.running),this.running=!1},this.getTokens=function(e){return this.lines[e]||this.$tokenizeRow(e)},this.getState=function(e){return this.currentLine==e&&this.$tokenizeRow(e),this.states[e]||"start"},this.$tokenizeRow=function(e){var t=this.doc.getLine(e),n=this.states[e-1],r=this.tokenizer.getLineTokens(t,n,e);return this.states[e]+""!=r.state+""?(this.states[e]=r.state,this.lines[e+1]=null,this.currentLine>e+1&&(this.currentLine=e+1)):this.currentLine==e&&(this.currentLine=e+1),this.lines[e]=r.tokens}}).call(s.prototype),t.BackgroundTokenizer=s}),ace.define("ace/search_highlight",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/range"],function(e,t,n){"use strict";var r=e("./lib/lang"),i=e("./lib/oop"),s=e("./range").Range,o=function(e,t,n){this.setRegexp(e),this.clazz=t,this.type=n||"text"};(function(){this.MAX_RANGES=500,this.setRegexp=function(e){if(this.regExp+""==e+"")return;this.regExp=e,this.cache=[]},this.update=function(e,t,n,i){if(!this.regExp)return;var o=i.firstRow,u=i.lastRow;for(var a=o;a<=u;a++){var f=this.cache[a];f==null&&(f=r.getMatchOffsets(n.getLine(a),this.regExp),f.length>this.MAX_RANGES&&(f=f.slice(0,this.MAX_RANGES)),f=f.map(function(e){return new s(a,e.offset,a,e.offset+e.length)}),this.cache[a]=f.length?f:"");for(var l=f.length;l--;)t.drawSingleLineMarker(e,f[l].toScreenRange(n),this.clazz,i)}}}).call(o.prototype),t.SearchHighlight=o}),ace.define("ace/edit_session/fold_line",["require","exports","module","ace/range"],function(e,t,n){"use strict";function i(e,t){this.foldData=e,Array.isArray(t)?this.folds=t:t=this.folds=[t];var n=t[t.length-1];this.range=new r(t[0].start.row,t[0].start.column,n.end.row,n.end.column),this.start=this.range.start,this.end=this.range.end,this.folds.forEach(function(e){e.setFoldLine(this)},this)}var r=e("../range").Range;(function(){this.shiftRow=function(e){this.start.row+=e,this.end.row+=e,this.folds.forEach(function(t){t.start.row+=e,t.end.row+=e})},this.addFold=function(e){if(e.sameRow){if(e.start.row<this.startRow||e.endRow>this.endRow)throw new Error("Can't add a fold to this FoldLine as it has no connection");this.folds.push(e),this.folds.sort(function(e,t){return-e.range.compareEnd(t.start.row,t.start.column)}),this.range.compareEnd(e.start.row,e.start.column)>0?(this.end.row=e.end.row,this.end.column=e.end.column):this.range.compareStart(e.end.row,e.end.column)<0&&(this.start.row=e.start.row,this.start.column=e.start.column)}else if(e.start.row==this.end.row)this.folds.push(e),this.end.row=e.end.row,this.end.column=e.end.column;else{if(e.end.row!=this.start.row)throw new Error("Trying to add fold to FoldRow that doesn't have a matching row");this.folds.unshift(e),this.start.row=e.start.row,this.start.column=e.start.column}e.foldLine=this},this.containsRow=function(e){return e>=this.start.row&&e<=this.end.row},this.walk=function(e,t,n){var r=0,i=this.folds,s,o,u,a=!0;t==null&&(t=this.end.row,n=this.end.column);for(var f=0;f<i.length;f++){s=i[f],o=s.range.compareStart(t,n);if(o==-1){e(null,t,n,r,a);return}u=e(null,s.start.row,s.start.column,r,a),u=!u&&e(s.placeholder,s.start.row,s.start.column,r);if(u||o===0)return;a=!s.sameRow,r=s.end.column}e(null,t,n,r,a)},this.getNextFoldTo=function(e,t){var n,r;for(var i=0;i<this.folds.length;i++){n=this.folds[i],r=n.range.compareEnd(e,t);if(r==-1)return{fold:n,kind:"after"};if(r===0)return{fold:n,kind:"inside"}}return null},this.addRemoveChars=function(e,t,n){var r=this.getNextFoldTo(e,t),i,s;if(r){i=r.fold;if(r.kind=="inside"&&i.start.column!=t&&i.start.row!=e)window.console&&window.console.log(e,t,i);else if(i.start.row==e){s=this.folds;var o=s.indexOf(i);o===0&&(this.start.column+=n);for(o;o<s.length;o++){i=s[o],i.start.column+=n;if(!i.sameRow)return;i.end.column+=n}this.end.column+=n}}},this.split=function(e,t){var n=this.getNextFoldTo(e,t);if(!n||n.kind=="inside")return null;var r=n.fold,s=this.folds,o=this.foldData,u=s.indexOf(r),a=s[u-1];this.end.row=a.end.row,this.end.column=a.end.column,s=s.splice(u,s.length-u);var f=new i(o,s);return o.splice(o.indexOf(this)+1,0,f),f},this.merge=function(e){var t=e.folds;for(var n=0;n<t.length;n++)this.addFold(t[n]);var r=this.foldData;r.splice(r.indexOf(e),1)},this.toString=function(){var e=[this.range.toString()+": ["];return this.folds.forEach(function(t){e.push(" "+t.toString())}),e.push("]"),e.join("\n")},this.idxToPosition=function(e){var t=0;for(var n=0;n<this.folds.length;n++){var r=this.folds[n];e-=r.start.column-t;if(e<0)return{row:r.start.row,column:r.start.column+e};e-=r.placeholder.length;if(e<0)return r.start;t=r.end.column}return{row:this.end.row,column:this.end.column+e}}}).call(i.prototype),t.FoldLine=i}),ace.define("ace/range_list",["require","exports","module","ace/range"],function(e,t,n){"use strict";var r=e("./range").Range,i=r.comparePoints,s=function(){this.ranges=[]};(function(){this.comparePoints=i,this.pointIndex=function(e,t,n){var r=this.ranges;for(var s=n||0;s<r.length;s++){var o=r[s],u=i(e,o.end);if(u>0)continue;var a=i(e,o.start);return u===0?t&&a!==0?-s-2:s:a>0||a===0&&!t?s:-s-1}return-s-1},this.add=function(e){var t=!e.isEmpty(),n=this.pointIndex(e.start,t);n<0&&(n=-n-1);var r=this.pointIndex(e.end,t,n);return r<0?r=-r-1:r++,this.ranges.splice(n,r-n,e)},this.addList=function(e){var t=[];for(var n=e.length;n--;)t.push.call(t,this.add(e[n]));return t},this.substractPoint=function(e){var t=this.pointIndex(e);if(t>=0)return this.ranges.splice(t,1)},this.merge=function(){var e=[],t=this.ranges;t=t.sort(function(e,t){return i(e.start,t.start)});var n=t[0],r;for(var s=1;s<t.length;s++){r=n,n=t[s];var o=i(r.end,n.start);if(o<0)continue;if(o==0&&!r.isEmpty()&&!n.isEmpty())continue;i(r.end,n.end)<0&&(r.end.row=n.end.row,r.end.column=n.end.column),t.splice(s,1),e.push(n),n=r,s--}return this.ranges=t,e},this.contains=function(e,t){return this.pointIndex({row:e,column:t})>=0},this.containsPoint=function(e){return this.pointIndex(e)>=0},this.rangeAtPoint=function(e){var t=this.pointIndex(e);if(t>=0)return this.ranges[t]},this.clipRows=function(e,t){var n=this.ranges;if(n[0].start.row>t||n[n.length-1].start.row<e)return[];var r=this.pointIndex({row:e,column:0});r<0&&(r=-r-1);var i=this.pointIndex({row:t,column:0},r);i<0&&(i=-i-1);var s=[];for(var o=r;o<i;o++)s.push(n[o]);return s},this.removeAll=function(){return this.ranges.splice(0,this.ranges.length)},this.attach=function(e){this.session&&this.detach(),this.session=e,this.onChange=this.$onChange.bind(this),this.session.on("change",this.onChange)},this.detach=function(){if(!this.session)return;this.session.removeListener("change",this.onChange),this.session=null},this.$onChange=function(e){var t=e.data.range;if(e.data.action[0]=="i")var n=t.start,r=t.end;else var r=t.start,n=t.end;var i=n.row,s=r.row,o=s-i,u=-n.column+r.column,a=this.ranges;for(var f=0,l=a.length;f<l;f++){var c=a[f];if(c.end.row<i)continue;if(c.start.row>i)break;c.start.row==i&&c.start.column>=n.column&&(c.start.column!=n.column||!this.$insertRight)&&(c.start.column+=u,c.start.row+=o);if(c.end.row==i&&c.end.column>=n.column){if(c.end.column==n.column&&this.$insertRight)continue;c.end.column==n.column&&u>0&&f<l-1&&c.end.column>c.start.column&&c.end.column==a[f+1].start.column&&(c.end.column-=u),c.end.column+=u,c.end.row+=o}}if(o!=0&&f<l)for(;f<l;f++){var c=a[f];c.start.row+=o,c.end.row+=o}}}).call(s.prototype),t.RangeList=s}),ace.define("ace/edit_session/fold",["require","exports","module","ace/range","ace/range_list","ace/lib/oop"],function(e,t,n){"use strict";function u(e,t){e.row-=t.row,e.row==0&&(e.column-=t.column)}function a(e,t){u(e.start,t),u(e.end,t)}function f(e,t){e.row==0&&(e.column+=t.column),e.row+=t.row}function l(e,t){f(e.start,t),f(e.end,t)}var r=e("../range").Range,i=e("../range_list").RangeList,s=e("../lib/oop"),o=t.Fold=function(e,t){this.foldLine=null,this.placeholder=t,this.range=e,this.start=e.start,this.end=e.end,this.sameRow=e.start.row==e.end.row,this.subFolds=this.ranges=[]};s.inherits(o,i),function(){this.toString=function(){return'"'+this.placeholder+'" '+this.range.toString()},this.setFoldLine=function(e){this.foldLine=e,this.subFolds.forEach(function(t){t.setFoldLine(e)})},this.clone=function(){var e=this.range.clone(),t=new o(e,this.placeholder);return this.subFolds.forEach(function(e){t.subFolds.push(e.clone())}),t.collapseChildren=this.collapseChildren,t},this.addSubFold=function(e){if(this.range.isEqual(e))return;if(!this.range.containsRange(e))throw new Error("A fold can't intersect already existing fold"+e.range+this.range);a(e,this.start);var t=e.start.row,n=e.start.column;for(var r=0,i=-1;r<this.subFolds.length;r++){i=this.subFolds[r].range.compare(t,n);if(i!=1)break}var s=this.subFolds[r];if(i==0)return s.addSubFold(e);var t=e.range.end.row,n=e.range.end.column;for(var o=r,i=-1;o<this.subFolds.length;o++){i=this.subFolds[o].range.compare(t,n);if(i!=1)break}var u=this.subFolds[o];if(i==0)throw new Error("A fold can't intersect already existing fold"+e.range+this.range);var f=this.subFolds.splice(r,o-r,e);return e.setFoldLine(this.foldLine),e},this.restoreRange=function(e){return l(e,this.start)}}.call(o.prototype)}),ace.define("ace/edit_session/folding",["require","exports","module","ace/range","ace/edit_session/fold_line","ace/edit_session/fold","ace/token_iterator"],function(e,t,n){"use strict";function u(){this.getFoldAt=function(e,t,n){var r=this.getFoldLine(e);if(!r)return null;var i=r.folds;for(var s=0;s<i.length;s++){var o=i[s];if(o.range.contains(e,t)){if(n==1&&o.range.isEnd(e,t))continue;if(n==-1&&o.range.isStart(e,t))continue;return o}}},this.getFoldsInRange=function(e){var t=e.start,n=e.end,r=this.$foldData,i=[];t.column+=1,n.column-=1;for(var s=0;s<r.length;s++){var o=r[s].range.compareRange(e);if(o==2)continue;if(o==-2)break;var u=r[s].folds;for(var a=0;a<u.length;a++){var f=u[a];o=f.range.compareRange(e);if(o==-2)break;if(o==2)continue;if(o==42)break;i.push(f)}}return t.column-=1,n.column+=1,i},this.getFoldsInRangeList=function(e){if(Array.isArray(e)){var t=[];e.forEach(function(e){t=t.concat(this.getFoldsInRange(e))},this)}else var t=this.getFoldsInRange(e);return t},this.getAllFolds=function(){var e=[],t=this.$foldData;for(var n=0;n<t.length;n++)for(var r=0;r<t[n].folds.length;r++)e.push(t[n].folds[r]);return e},this.getFoldStringAt=function(e,t,n,r){r=r||this.getFoldLine(e);if(!r)return null;var i={end:{column:0}},s,o;for(var u=0;u<r.folds.length;u++){o=r.folds[u];var a=o.range.compareEnd(e,t);if(a==-1){s=this.getLine(o.start.row).substring(i.end.column,o.start.column);break}if(a===0)return null;i=o}return s||(s=this.getLine(o.start.row).substring(i.end.column)),n==-1?s.substring(0,t-i.end.column):n==1?s.substring(t-i.end.column):s},this.getFoldLine=function(e,t){var n=this.$foldData,r=0;t&&(r=n.indexOf(t)),r==-1&&(r=0);for(r;r<n.length;r++){var i=n[r];if(i.start.row<=e&&i.end.row>=e)return i;if(i.end.row>e)return null}return null},this.getNextFoldLine=function(e,t){var n=this.$foldData,r=0;t&&(r=n.indexOf(t)),r==-1&&(r=0);for(r;r<n.length;r++){var i=n[r];if(i.end.row>=e)return i}return null},this.getFoldedRowCount=function(e,t){var n=this.$foldData,r=t-e+1;for(var i=0;i<n.length;i++){var s=n[i],o=s.end.row,u=s.start.row;if(o>=t){u<t&&(u>=e?r-=t-u:r=0);break}o>=e&&(u>=e?r-=o-u:r-=o-e+1)}return r},this.$addFoldLine=function(e){return this.$foldData.push(e),this.$foldData.sort(function(e,t){return e.start.row-t.start.row}),e},this.addFold=function(e,t){var n=this.$foldData,r=!1,o;e instanceof s?o=e:(o=new s(t,e),o.collapseChildren=t.collapseChildren),this.$clipRangeToDocument(o.range);var u=o.start.row,a=o.start.column,f=o.end.row,l=o.end.column;if(u<f||u==f&&a<=l-2){var c=this.getFoldAt(u,a,1),h=this.getFoldAt(f,l,-1);if(c&&h==c)return c.addSubFold(o);if(c&&!c.range.isStart(u,a)||h&&!h.range.isEnd(f,l))throw new Error("A fold can't intersect already existing fold"+o.range+c.range);var p=this.getFoldsInRange(o.range);p.length>0&&(this.removeFolds(p),p.forEach(function(e){o.addSubFold(e)}));for(var d=0;d<n.length;d++){var v=n[d];if(f==v.start.row){v.addFold(o),r=!0;break}if(u==v.end.row){v.addFold(o),r=!0;if(!o.sameRow){var m=n[d+1];if(m&&m.start.row==f){v.merge(m);break}}break}if(f<=v.start.row)break}return r||(v=this.$addFoldLine(new i(this.$foldData,o))),this.$useWrapMode?this.$updateWrapData(v.start.row,v.start.row):this.$updateRowLengthCache(v.start.row,v.start.row),this.$modified=!0,this._emit("changeFold",{data:o,action:"add"}),o}throw new Error("The range has to be at least 2 characters width")},this.addFolds=function(e){e.forEach(function(e){this.addFold(e)},this)},this.removeFold=function(e){var t=e.foldLine,n=t.start.row,r=t.end.row,i=this.$foldData,s=t.folds;if(s.length==1)i.splice(i.indexOf(t),1);else if(t.range.isEnd(e.end.row,e.end.column))s.pop(),t.end.row=s[s.length-1].end.row,t.end.column=s[s.length-1].end.column;else if(t.range.isStart(e.start.row,e.start.column))s.shift(),t.start.row=s[0].start.row,t.start.column=s[0].start.column;else if(e.sameRow)s.splice(s.indexOf(e),1);else{var o=t.split(e.start.row,e.start.column);s=o.folds,s.shift(),o.start.row=s[0].start.row,o.start.column=s[0].start.column}this.$updating||(this.$useWrapMode?this.$updateWrapData(n,r):this.$updateRowLengthCache(n,r)),this.$modified=!0,this._emit("changeFold",{data:e,action:"remove"})},this.removeFolds=function(e){var t=[];for(var n=0;n<e.length;n++)t.push(e[n]);t.forEach(function(e){this.removeFold(e)},this),this.$modified=!0},this.expandFold=function(e){this.removeFold(e),e.subFolds.forEach(function(t){e.restoreRange(t),this.addFold(t)},this),e.collapseChildren>0&&this.foldAll(e.start.row+1,e.end.row,e.collapseChildren-1),e.subFolds=[]},this.expandFolds=function(e){e.forEach(function(e){this.expandFold(e)},this)},this.unfold=function(e,t){var n,i;e==null?(n=new r(0,0,this.getLength(),0),t=!0):typeof e=="number"?n=new r(e,0,e,this.getLine(e).length):"row"in e?n=r.fromPoints(e,e):n=e,i=this.getFoldsInRangeList(n);if(t)this.removeFolds(i);else{var s=i;while(s.length)this.expandFolds(s),s=this.getFoldsInRangeList(n)}if(i.length)return i},this.isRowFolded=function(e,t){return!!this.getFoldLine(e,t)},this.getRowFoldEnd=function(e,t){var n=this.getFoldLine(e,t);return n?n.end.row:e},this.getRowFoldStart=function(e,t){var n=this.getFoldLine(e,t);return n?n.start.row:e},this.getFoldDisplayLine=function(e,t,n,r,i){r==null&&(r=e.start.row),i==null&&(i=0),t==null&&(t=e.end.row),n==null&&(n=this.getLine(t).length);var s=this.doc,o="";return e.walk(function(e,t,n,u){if(t<r)return;if(t==r){if(n<i)return;u=Math.max(i,u)}e!=null?o+=e:o+=s.getLine(t).substring(u,n)},t,n),o},this.getDisplayLine=function(e,t,n,r){var i=this.getFoldLine(e);if(!i){var s;return s=this.doc.getLine(e),s.substring(r||0,t||s.length)}return this.getFoldDisplayLine(i,e,t,n,r)},this.$cloneFoldData=function(){var e=[];return e=this.$foldData.map(function(t){var n=t.folds.map(function(e){return e.clone()});return new i(e,n)}),e},this.toggleFold=function(e){var t=this.selection,n=t.getRange(),r,i;if(n.isEmpty()){var s=n.start;r=this.getFoldAt(s.row,s.column);if(r){this.expandFold(r);return}(i=this.findMatchingBracket(s))?n.comparePoint(i)==1?n.end=i:(n.start=i,n.start.column++,n.end.column--):(i=this.findMatchingBracket({row:s.row,column:s.column+1}))?(n.comparePoint(i)==1?n.end=i:n.start=i,n.start.column++):n=this.getCommentFoldRange(s.row,s.column)||n}else{var o=this.getFoldsInRange(n);if(e&&o.length){this.expandFolds(o);return}o.length==1&&(r=o[0])}r||(r=this.getFoldAt(n.start.row,n.start.column));if(r&&r.range.toString()==n.toString()){this.expandFold(r);return}var u="...";if(!n.isMultiLine()){u=this.getTextRange(n);if(u.length<4)return;u=u.trim().substring(0,2)+".."}this.addFold(u,n)},this.getCommentFoldRange=function(e,t,n){var i=new o(this,e,t),s=i.getCurrentToken();if(s&&/^comment|string/.test(s.type)){var u=new r,a=new RegExp(s.type.replace(/\..*/,"\\."));if(n!=1){do s=i.stepBackward();while(s&&a.test(s.type));i.stepForward()}u.start.row=i.getCurrentTokenRow(),u.start.column=i.getCurrentTokenColumn()+2,i=new o(this,e,t);if(n!=-1){do s=i.stepForward();while(s&&a.test(s.type));s=i.stepBackward()}else s=i.getCurrentToken();return u.end.row=i.getCurrentTokenRow(),u.end.column=i.getCurrentTokenColumn()+s.value.length-2,u}},this.foldAll=function(e,t,n){n==undefined&&(n=1e5);var r=this.foldWidgets;if(!r)return;t=t||this.getLength(),e=e||0;for(var i=e;i<t;i++){r[i]==null&&(r[i]=this.getFoldWidget(i));if(r[i]!="start")continue;var s=this.getFoldWidgetRange(i);if(s&&s.isMultiLine()&&s.end.row<=t&&s.start.row>=e){i=s.end.row;try{var o=this.addFold("...",s);o&&(o.collapseChildren=n)}catch(u){}}}},this.$foldStyles={manual:1,markbegin:1,markbeginend:1},this.$foldStyle="markbegin",this.setFoldStyle=function(e){if(!this.$foldStyles[e])throw new Error("invalid fold style: "+e+"["+Object.keys(this.$foldStyles).join(", ")+"]");if(this.$foldStyle==e)return;this.$foldStyle=e,e=="manual"&&this.unfold();var t=this.$foldMode;this.$setFolding(null),this.$setFolding(t)},this.$setFolding=function(e){if(this.$foldMode==e)return;this.$foldMode=e,this.removeListener("change",this.$updateFoldWidgets),this._emit("changeAnnotation");if(!e||this.$foldStyle=="manual"){this.foldWidgets=null;return}this.foldWidgets=[],this.getFoldWidget=e.getFoldWidget.bind(e,this,this.$foldStyle),this.getFoldWidgetRange=e.getFoldWidgetRange.bind(e,this,this.$foldStyle),this.$updateFoldWidgets=this.updateFoldWidgets.bind(this),this.on("change",this.$updateFoldWidgets)},this.getParentFoldRangeData=function(e,t){var n=this.foldWidgets;if(!n||t&&n[e])return{};var r=e-1,i;while(r>=0){var s=n[r];s==null&&(s=n[r]=this.getFoldWidget(r));if(s=="start"){var o=this.getFoldWidgetRange(r);i||(i=o);if(o&&o.end.row>=e)break}r--}return{range:r!==-1&&o,firstRange:i}},this.onFoldWidgetClick=function(e,t){t=t.domEvent;var n={children:t.shiftKey,all:t.ctrlKey||t.metaKey,siblings:t.altKey},r=this.$toggleFoldWidget(e,n);if(!r){var i=t.target||t.srcElement;i&&/ace_fold-widget/.test(i.className)&&(i.className+=" ace_invalid")}},this.$toggleFoldWidget=function(e,t){if(!this.getFoldWidget)return;var n=this.getFoldWidget(e),r=this.getLine(e),i=n==="end"?-1:1,s=this.getFoldAt(e,i===-1?0:r.length,i);if(s){t.children||t.all?this.removeFold(s):this.expandFold(s);return}var o=this.getFoldWidgetRange(e,!0);if(o&&!o.isMultiLine()){s=this.getFoldAt(o.start.row,o.start.column,1);if(s&&o.isEqual(s.range)){this.removeFold(s);return}}if(t.siblings){var u=this.getParentFoldRangeData(e);if(u.range)var a=u.range.start.row+1,f=u.range.end.row;this.foldAll(a,f,t.all?1e4:0)}else t.children?(f=o?o.end.row:this.getLength(),this.foldAll(e+1,o.end.row,t.all?1e4:0)):o&&(t.all&&(o.collapseChildren=1e4),this.addFold("...",o));return o},this.toggleFoldWidget=function(e){var t=this.selection.getCursor().row;t=this.getRowFoldStart(t);var n=this.$toggleFoldWidget(t,{});if(n)return;var r=this.getParentFoldRangeData(t,!0);n=r.range||r.firstRange;if(n){t=n.start.row;var i=this.getFoldAt(t,this.getLine(t).length,1);i?this.removeFold(i):this.addFold("...",n)}},this.updateFoldWidgets=function(e){var t=e.data,n=t.range,r=n.start.row,i=n.end.row-r;if(i===0)this.foldWidgets[r]=null;else if(t.action=="removeText"||t.action=="removeLines")this.foldWidgets.splice(r,i+1,null);else{var s=Array(i+1);s.unshift(r,1),this.foldWidgets.splice.apply(this.foldWidgets,s)}}}var r=e("../range").Range,i=e("./fold_line").FoldLine,s=e("./fold").Fold,o=e("../token_iterator").TokenIterator;t.Folding=u}),ace.define("ace/edit_session/bracket_match",["require","exports","module","ace/token_iterator","ace/range"],function(e,t,n){"use strict";function s(){this.findMatchingBracket=function(e,t){if(e.column==0)return null;var n=t||this.getLine(e.row).charAt(e.column-1);if(n=="")return null;var r=n.match(/([\(\[\{])|([\)\]\}])/);return r?r[1]?this.$findClosingBracket(r[1],e):this.$findOpeningBracket(r[2],e):null},this.getBracketRange=function(e){var t=this.getLine(e.row),n=!0,r,s=t.charAt(e.column-1),o=s&&s.match(/([\(\[\{])|([\)\]\}])/);o||(s=t.charAt(e.column),e={row:e.row,column:e.column+1},o=s&&s.match(/([\(\[\{])|([\)\]\}])/),n=!1);if(!o)return null;if(o[1]){var u=this.$findClosingBracket(o[1],e);if(!u)return null;r=i.fromPoints(e,u),n||(r.end.column++,r.start.column--),r.cursor=r.end}else{var u=this.$findOpeningBracket(o[2],e);if(!u)return null;r=i.fromPoints(u,e),n||(r.start.column++,r.end.column--),r.cursor=r.start}return r},this.$brackets={")":"(","(":")","]":"[","[":"]","{":"}","}":"{"},this.$findOpeningBracket=function(e,t,n){var i=this.$brackets[e],s=1,o=new r(this,t.row,t.column),u=o.getCurrentToken();u||(u=o.stepForward());if(!u)return;n||(n=new RegExp("(\\.?"+u.type.replace(".","\\.").replace("rparen",".paren")+")+"));var a=t.column-o.getCurrentTokenColumn()-2,f=u.value;for(;;){while(a>=0){var l=f.charAt(a);if(l==i){s-=1;if(s==0)return{row:o.getCurrentTokenRow(),column:a+o.getCurrentTokenColumn()}}else l==e&&(s+=1);a-=1}do u=o.stepBackward();while(u&&!n.test(u.type));if(u==null)break;f=u.value,a=f.length-1}return null},this.$findClosingBracket=function(e,t,n){var i=this.$brackets[e],s=1,o=new r(this,t.row,t.column),u=o.getCurrentToken();u||(u=o.stepForward());if(!u)return;n||(n=new RegExp("(\\.?"+u.type.replace(".","\\.").replace("lparen",".paren")+")+"));var a=t.column-o.getCurrentTokenColumn();for(;;){var f=u.value,l=f.length;while(a<l){var c=f.charAt(a);if(c==i){s-=1;if(s==0)return{row:o.getCurrentTokenRow(),column:a+o.getCurrentTokenColumn()}}else c==e&&(s+=1);a+=1}do u=o.stepForward();while(u&&!n.test(u.type));if(u==null)break;a=0}return null}}var r=e("../token_iterator").TokenIterator,i=e("../range").Range;t.BracketMatch=s}),ace.define("ace/edit_session",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/config","ace/lib/event_emitter","ace/selection","ace/mode/text","ace/range","ace/document","ace/background_tokenizer","ace/search_highlight","ace/edit_session/folding","ace/edit_session/bracket_match"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/lang"),s=e("./config"),o=e("./lib/event_emitter").EventEmitter,u=e("./selection").Selection,a=e("./mode/text").Mode,f=e("./range").Range,l=e("./document").Document,c=e("./background_tokenizer").BackgroundTokenizer,h=e("./search_highlight").SearchHighlight,p=function(e,t){this.$breakpoints=[],this.$decorations=[],this.$frontMarkers={},this.$backMarkers={},this.$markerId=1,this.$undoSelect=!0,this.$foldData=[],this.$foldData.toString=function(){return this.join("\n")},this.on("changeFold",this.onChangeFold.bind(this)),this.$onChange=this.onChange.bind(this);if(typeof e!="object"||!e.getLine)e=new l(e);this.setDocument(e),this.selection=new u(this),s.resetOptions(this),this.setMode(t),s._signal("session",this)};(function(){function m(e){return e<4352?!1:e>=4352&&e<=4447||e>=4515&&e<=4519||e>=4602&&e<=4607||e>=9001&&e<=9002||e>=11904&&e<=11929||e>=11931&&e<=12019||e>=12032&&e<=12245||e>=12272&&e<=12283||e>=12288&&e<=12350||e>=12353&&e<=12438||e>=12441&&e<=12543||e>=12549&&e<=12589||e>=12593&&e<=12686||e>=12688&&e<=12730||e>=12736&&e<=12771||e>=12784&&e<=12830||e>=12832&&e<=12871||e>=12880&&e<=13054||e>=13056&&e<=19903||e>=19968&&e<=42124||e>=42128&&e<=42182||e>=43360&&e<=43388||e>=44032&&e<=55203||e>=55216&&e<=55238||e>=55243&&e<=55291||e>=63744&&e<=64255||e>=65040&&e<=65049||e>=65072&&e<=65106||e>=65108&&e<=65126||e>=65128&&e<=65131||e>=65281&&e<=65376||e>=65504&&e<=65510}r.implement(this,o),this.setDocument=function(e){this.doc&&this.doc.removeListener("change",this.$onChange),this.doc=e,e.on("change",this.$onChange),this.bgTokenizer&&this.bgTokenizer.setDocument(this.getDocument()),this.resetCaches()},this.getDocument=function(){return this.doc},this.$resetRowCache=function(e){if(!e){this.$docRowCache=[],this.$screenRowCache=[];return}var t=this.$docRowCache.length,n=this.$getRowCacheIndex(this.$docRowCache,e)+1;t>n&&(this.$docRowCache.splice(n,t),this.$screenRowCache.splice(n,t))},this.$getRowCacheIndex=function(e,t){var n=0,r=e.length-1;while(n<=r){var i=n+r>>1,s=e[i];if(t>s)n=i+1;else{if(!(t<s))return i;r=i-1}}return n-1},this.resetCaches=function(){this.$modified=!0,this.$wrapData=[],this.$rowLengthCache=[],this.$resetRowCache(0),this.bgTokenizer&&this.bgTokenizer.start(0)},this.onChangeFold=function(e){var t=e.data;this.$resetRowCache(t.start.row)},this.onChange=function(e){var t=e.data;this.$modified=!0,this.$resetRowCache(t.range.start.row);var n=this.$updateInternalDataOnChange(e);!this.$fromUndo&&this.$undoManager&&!t.ignore&&(this.$deltasDoc.push(t),n&&n.length!=0&&this.$deltasFold.push({action:"removeFolds",folds:n}),this.$informUndoManager.schedule()),this.bgTokenizer&&this.bgTokenizer.$updateOnChange(t),this._signal("change",e)},this.setValue=function(e){this.doc.setValue(e),this.selection.moveTo(0,0),this.$resetRowCache(0),this.$deltas=[],this.$deltasDoc=[],this.$deltasFold=[],this.setUndoManager(this.$undoManager),this.getUndoManager().reset()},this.getValue=this.toString=function(){return this.doc.getValue()},this.getSelection=function(){return this.selection},this.getState=function(e){return this.bgTokenizer.getState(e)},this.getTokens=function(e){return this.bgTokenizer.getTokens(e)},this.getTokenAt=function(e,t){var n=this.bgTokenizer.getTokens(e),r,i=0;if(t==null)s=n.length-1,i=this.getLine(e).length;else for(var s=0;s<n.length;s++){i+=n[s].value.length;if(i>=t)break}return r=n[s],r?(r.index=s,r.start=i-r.value.length,r):null},this.setUndoManager=function(e){this.$undoManager=e,this.$deltas=[],this.$deltasDoc=[],this.$deltasFold=[],this.$informUndoManager&&this.$informUndoManager.cancel();if(e){var t=this;this.$syncInformUndoManager=function(){t.$informUndoManager.cancel(),t.$deltasFold.length&&(t.$deltas.push({group:"fold",deltas:t.$deltasFold}),t.$deltasFold=[]),t.$deltasDoc.length&&(t.$deltas.push({group:"doc",deltas:t.$deltasDoc}),t.$deltasDoc=[]),t.$deltas.length>0&&e.execute({action:"aceupdate",args:[t.$deltas,t],merge:t.mergeUndoDeltas}),t.mergeUndoDeltas=!1,t.$deltas=[]},this.$informUndoManager=i.delayedCall(this.$syncInformUndoManager)}},this.markUndoGroup=function(){this.$syncInformUndoManager&&this.$syncInformUndoManager()},this.$defaultUndoManager={undo:function(){},redo:function(){},reset:function(){}},this.getUndoManager=function(){return this.$undoManager||this.$defaultUndoManager},this.getTabString=function(){return this.getUseSoftTabs()?i.stringRepeat(" ",this.getTabSize()):" "},this.setUseSoftTabs=function(e){this.setOption("useSoftTabs",e)},this.getUseSoftTabs=function(){return this.$useSoftTabs&&!this.$mode.$indentWithTabs},this.setTabSize=function(e){this.setOption("tabSize",e)},this.getTabSize=function(){return this.$tabSize},this.isTabStop=function(e){return this.$useSoftTabs&&e.column%this.$tabSize===0},this.$overwrite=!1,this.setOverwrite=function(e){this.setOption("overwrite",e)},this.getOverwrite=function(){return this.$overwrite},this.toggleOverwrite=function(){this.setOverwrite(!this.$overwrite)},this.addGutterDecoration=function(e,t){this.$decorations[e]||(this.$decorations[e]=""),this.$decorations[e]+=" "+t,this._signal("changeBreakpoint",{})},this.removeGutterDecoration=function(e,t){this.$decorations[e]=(this.$decorations[e]||"").replace(" "+t,""),this._signal("changeBreakpoint",{})},this.getBreakpoints=function(){return this.$breakpoints},this.setBreakpoints=function(e){this.$breakpoints=[];for(var t=0;t<e.length;t++)this.$breakpoints[e[t]]="ace_breakpoint";this._signal("changeBreakpoint",{})},this.clearBreakpoints=function(){this.$breakpoints=[],this._signal("changeBreakpoint",{})},this.setBreakpoint=function(e,t){t===undefined&&(t="ace_breakpoint"),t?this.$breakpoints[e]=t:delete this.$breakpoints[e],this._signal("changeBreakpoint",{})},this.clearBreakpoint=function(e){delete this.$breakpoints[e],this._signal("changeBreakpoint",{})},this.addMarker=function(e,t,n,r){var i=this.$markerId++,s={range:e,type:n||"line",renderer:typeof n=="function"?n:null,clazz:t,inFront:!!r,id:i};return r?(this.$frontMarkers[i]=s,this._signal("changeFrontMarker")):(this.$backMarkers[i]=s,this._signal("changeBackMarker")),i},this.addDynamicMarker=function(e,t){if(!e.update)return;var n=this.$markerId++;return e.id=n,e.inFront=!!t,t?(this.$frontMarkers[n]=e,this._signal("changeFrontMarker")):(this.$backMarkers[n]=e,this._signal("changeBackMarker")),e},this.removeMarker=function(e){var t=this.$frontMarkers[e]||this.$backMarkers[e];if(!t)return;var n=t.inFront?this.$frontMarkers:this.$backMarkers;t&&(delete n[e],this._signal(t.inFront?"changeFrontMarker":"changeBackMarker"))},this.getMarkers=function(e){return e?this.$frontMarkers:this.$backMarkers},this.highlight=function(e){if(!this.$searchHighlight){var t=new h(null,"ace_selected-word","text");this.$searchHighlight=this.addDynamicMarker(t)}this.$searchHighlight.setRegexp(e)},this.highlightLines=function(e,t,n,r){typeof t!="number"&&(n=t,t=e),n||(n="ace_step");var i=new f(e,0,t,Infinity);return i.id=this.addMarker(i,n,"fullLine",r),i},this.setAnnotations=function(e){this.$annotations=e,this._signal("changeAnnotation",{})},this.getAnnotations=function(){return this.$annotations||[]},this.clearAnnotations=function(){this.setAnnotations([])},this.$detectNewLine=function(e){var t=e.match(/^.*?(\r?\n)/m);t?this.$autoNewLine=t[1]:this.$autoNewLine="\n"},this.getWordRange=function(e,t){var n=this.getLine(e),r=!1;t>0&&(r=!!n.charAt(t-1).match(this.tokenRe)),r||(r=!!n.charAt(t).match(this.tokenRe));if(r)var i=this.tokenRe;else if(/^\s+$/.test(n.slice(t-1,t+1)))var i=/\s/;else var i=this.nonTokenRe;var s=t;if(s>0){do s--;while(s>=0&&n.charAt(s).match(i));s++}var o=t;while(o<n.length&&n.charAt(o).match(i))o++;return new f(e,s,e,o)},this.getAWordRange=function(e,t){var n=this.getWordRange(e,t),r=this.getLine(n.end.row);while(r.charAt(n.end.column).match(/[ \t]/))n.end.column+=1;return n},this.setNewLineMode=function(e){this.doc.setNewLineMode(e)},this.getNewLineMode=function(){return this.doc.getNewLineMode()},this.setUseWorker=function(e){this.setOption("useWorker",e)},this.getUseWorker=function(){return this.$useWorker},this.onReloadTokenizer=function(e){var t=e.data;this.bgTokenizer.start(t.first),this._signal("tokenizerUpdate",e)},this.$modes={},this.$mode=null,this.$modeId=null,this.setMode=function(e,t){if(e&&typeof e=="object"){if(e.getTokenizer)return this.$onChangeMode(e);var n=e,r=n.path}else r=e||"ace/mode/text";this.$modes["ace/mode/text"]||(this.$modes["ace/mode/text"]=new a);if(this.$modes[r]&&!n){this.$onChangeMode(this.$modes[r]),t&&t();return}this.$modeId=r,s.loadModule(["mode",r],function(e){if(this.$modeId!==r)return t&&t();if(this.$modes[r]&&!n)return this.$onChangeMode(this.$modes[r]);e&&e.Mode&&(e=new e.Mode(n),n||(this.$modes[r]=e,e.$id=r),this.$onChangeMode(e),t&&t())}.bind(this)),this.$mode||this.$onChangeMode(this.$modes["ace/mode/text"],!0)},this.$onChangeMode=function(e,t){t||(this.$modeId=e.$id);if(this.$mode===e)return;this.$mode=e,this.$stopWorker(),this.$useWorker&&this.$startWorker();var n=e.getTokenizer();if(n.addEventListener!==undefined){var r=this.onReloadTokenizer.bind(this);n.addEventListener("update",r)}if(!this.bgTokenizer){this.bgTokenizer=new c(n);var i=this;this.bgTokenizer.addEventListener("update",function(e){i._signal("tokenizerUpdate",e)})}else this.bgTokenizer.setTokenizer(n);this.bgTokenizer.setDocument(this.getDocument()),this.tokenRe=e.tokenRe,this.nonTokenRe=e.nonTokenRe,t||(e.attachToSession&&e.attachToSession(this),this.$options.wrapMethod.set.call(this,this.$wrapMethod),this.$setFolding(e.foldingRules),this.bgTokenizer.start(0),this._emit("changeMode"))},this.$stopWorker=function(){this.$worker&&(this.$worker.terminate(),this.$worker=null)},this.$startWorker=function(){try{this.$worker=this.$mode.createWorker(this)}catch(e){console.log("Could not load worker"),console.log(e),this.$worker=null}},this.getMode=function(){return this.$mode},this.$scrollTop=0,this.setScrollTop=function(e){if(this.$scrollTop===e||isNaN(e))return;this.$scrollTop=e,this._signal("changeScrollTop",e)},this.getScrollTop=function(){return this.$scrollTop},this.$scrollLeft=0,this.setScrollLeft=function(e){if(this.$scrollLeft===e||isNaN(e))return;this.$scrollLeft=e,this._signal("changeScrollLeft",e)},this.getScrollLeft=function(){return this.$scrollLeft},this.getScreenWidth=function(){return this.$computeWidth(),this.lineWidgets?Math.max(this.getLineWidgetMaxWidth(),this.screenWidth):this.screenWidth},this.getLineWidgetMaxWidth=function(){if(this.lineWidgetsWidth!=null)return this.lineWidgetsWidth;var e=0;return this.lineWidgets.forEach(function(t){t&&t.screenWidth>e&&(e=t.screenWidth)}),this.lineWidgetWidth=e},this.$computeWidth=function(e){if(this.$modified||e){this.$modified=!1;if(this.$useWrapMode)return this.screenWidth=this.$wrapLimit;var t=this.doc.getAllLines(),n=this.$rowLengthCache,r=0,i=0,s=this.$foldData[i],o=s?s.start.row:Infinity,u=t.length;for(var a=0;a<u;a++){if(a>o){a=s.end.row+1;if(a>=u)break;s=this.$foldData[i++],o=s?s.start.row:Infinity}n[a]==null&&(n[a]=this.$getStringScreenWidth(t[a])[0]),n[a]>r&&(r=n[a])}this.screenWidth=r}},this.getLine=function(e){return this.doc.getLine(e)},this.getLines=function(e,t){return this.doc.getLines(e,t)},this.getLength=function(){return this.doc.getLength()},this.getTextRange=function(e){return this.doc.getTextRange(e||this.selection.getRange())},this.insert=function(e,t){return this.doc.insert(e,t)},this.remove=function(e){return this.doc.remove(e)},this.undoChanges=function(e,t){if(!e.length)return;this.$fromUndo=!0;var n=null;for(var r=e.length-1;r!=-1;r--){var i=e[r];i.group=="doc"?(this.doc.revertDeltas(i.deltas),n=this.$getUndoSelection(i.deltas,!0,n)):i.deltas.forEach(function(e){this.addFolds(e.folds)},this)}return this.$fromUndo=!1,n&&this.$undoSelect&&!t&&this.selection.setSelectionRange(n),n},this.redoChanges=function(e,t){if(!e.length)return;this.$fromUndo=!0;var n=null;for(var r=0;r<e.length;r++){var i=e[r];i.group=="doc"&&(this.doc.applyDeltas(i.deltas),n=this.$getUndoSelection(i.deltas,!1,n))}return this.$fromUndo=!1,n&&this.$undoSelect&&!t&&this.selection.setSelectionRange(n),n},this.setUndoSelect=function(e){this.$undoSelect=e},this.$getUndoSelection=function(e,t,n){function r(e){var n=e.action==="insertText"||e.action==="insertLines";return t?!n:n}var i=e[0],s,o,u=!1;r(i)?(s=f.fromPoints(i.range.start,i.range.end),u=!0):(s=f.fromPoints(i.range.start,i.range.start),u=!1);for(var a=1;a<e.length;a++)i=e[a],r(i)?(o=i.range.start,s.compare(o.row,o.column)==-1&&s.setStart(i.range.start),o=i.range.end,s.compare(o.row,o.column)==1&&s.setEnd(i.range.end),u=!0):(o=i.range.start,s.compare(o.row,o.column)==-1&&(s=f.fromPoints(i.range.start,i.range.start)),u=!1);if(n!=null){f.comparePoints(n.start,s.start)===0&&(n.start.column+=s.end.column-s.start.column,n.end.column+=s.end.column-s.start.column);var l=n.compareRange(s);l==1?s.setStart(n.start):l==-1&&s.setEnd(n.end)}return s},this.replace=function(e,t){return this.doc.replace(e,t)},this.moveText=function(e,t,n){var r=this.getTextRange(e),i=this.getFoldsInRange(e),s=f.fromPoints(t,t);if(!n){this.remove(e);var o=e.start.row-e.end.row,u=o?-e.end.column:e.start.column-e.end.column;u&&(s.start.row==e.end.row&&s.start.column>e.end.column&&(s.start.column+=u),s.end.row==e.end.row&&s.end.column>e.end.column&&(s.end.column+=u)),o&&s.start.row>=e.end.row&&(s.start.row+=o,s.end.row+=o)}s.end=this.insert(s.start,r);if(i.length){var a=e.start,l=s.start,o=l.row-a.row,u=l.column-a.column;this.addFolds(i.map(function(e){return e=e.clone(),e.start.row==a.row&&(e.start.column+=u),e.end.row==a.row&&(e.end.column+=u),e.start.row+=o,e.end.row+=o,e}))}return s},this.indentRows=function(e,t,n){n=n.replace(/\t/g,this.getTabString());for(var r=e;r<=t;r++)this.insert({row:r,column:0},n)},this.outdentRows=function(e){var t=e.collapseRows(),n=new f(0,0,0,0),r=this.getTabSize();for(var i=t.start.row;i<=t.end.row;++i){var s=this.getLine(i);n.start.row=i,n.end.row=i;for(var o=0;o<r;++o)if(s.charAt(o)!=" ")break;o<r&&s.charAt(o)==" "?(n.start.column=o,n.end.column=o+1):(n.start.column=0,n.end.column=o),this.remove(n)}},this.$moveLines=function(e,t,n){e=this.getRowFoldStart(e),t=this.getRowFoldEnd(t);if(n<0){var r=this.getRowFoldStart(e+n);if(r<0)return 0;var i=r-e}else if(n>0){var r=this.getRowFoldEnd(t+n);if(r>this.doc.getLength()-1)return 0;var i=r-t}else{e=this.$clipRowToDocument(e),t=this.$clipRowToDocument(t);var i=t-e+1}var s=new f(e,0,t,Number.MAX_VALUE),o=this.getFoldsInRange(s).map(function(e){return e=e.clone(),e.start.row+=i,e.end.row+=i,e}),u=n==0?this.doc.getLines(e,t):this.doc.removeLines(e,t);return this.doc.insertLines(e+i,u),o.length&&this.addFolds(o),i},this.moveLinesUp=function(e,t){return this.$moveLines(e,t,-1)},this.moveLinesDown=function(e,t){return this.$moveLines(e,t,1)},this.duplicateLines=function(e,t){return this.$moveLines(e,t,0)},this.$clipRowToDocument=function(e){return Math.max(0,Math.min(e,this.doc.getLength()-1))},this.$clipColumnToRow=function(e,t){return t<0?0:Math.min(this.doc.getLine(e).length,t)},this.$clipPositionToDocument=function(e,t){t=Math.max(0,t);if(e<0)e=0,t=0;else{var n=this.doc.getLength();e>=n?(e=n-1,t=this.doc.getLine(n-1).length):t=Math.min(this.doc.getLine(e).length,t)}return{row:e,column:t}},this.$clipRangeToDocument=function(e){e.start.row<0?(e.start.row=0,e.start.column=0):e.start.column=this.$clipColumnToRow(e.start.row,e.start.column);var t=this.doc.getLength()-1;return e.end.row>t?(e.end.row=t,e.end.column=this.doc.getLine(t).length):e.end.column=this.$clipColumnToRow(e.end.row,e.end.column),e},this.$wrapLimit=80,this.$useWrapMode=!1,this.$wrapLimitRange={min:null,max:null},this.setUseWrapMode=function(e){if(e!=this.$useWrapMode){this.$useWrapMode=e,this.$modified=!0,this.$resetRowCache(0);if(e){var t=this.getLength();this.$wrapData=Array(t),this.$updateWrapData(0,t-1)}this._signal("changeWrapMode")}},this.getUseWrapMode=function(){return this.$useWrapMode},this.setWrapLimitRange=function(e,t){if(this.$wrapLimitRange.min!==e||this.$wrapLimitRange.max!==t)this.$wrapLimitRange={min:e,max:t},this.$modified=!0,this._signal("changeWrapMode")},this.adjustWrapLimit=function(e,t){var n=this.$wrapLimitRange;n.max<0&&(n={min:t,max:t});var r=this.$constrainWrapLimit(e,n.min,n.max);return r!=this.$wrapLimit&&r>1?(this.$wrapLimit=r,this.$modified=!0,this.$useWrapMode&&(this.$updateWrapData(0,this.getLength()-1),this.$resetRowCache(0),this._signal("changeWrapLimit")),!0):!1},this.$constrainWrapLimit=function(e,t,n){return t&&(e=Math.max(t,e)),n&&(e=Math.min(n,e)),e},this.getWrapLimit=function(){return this.$wrapLimit},this.setWrapLimit=function(e){this.setWrapLimitRange(e,e)},this.getWrapLimitRange=function(){return{min:this.$wrapLimitRange.min,max:this.$wrapLimitRange.max}},this.$updateInternalDataOnChange=function(e){var t=this.$useWrapMode,n,r=e.data.action,i=e.data.range.start.row,s=e.data.range.end.row,o=e.data.range.start,u=e.data.range.end,a=null;r.indexOf("Lines")!=-1?(r=="insertLines"?s=i+e.data.lines.length:s=i,n=e.data.lines?e.data.lines.length:s-i):n=s-i,this.$updating=!0;if(n!=0)if(r.indexOf("remove")!=-1){this[t?"$wrapData":"$rowLengthCache"].splice(i,n);var f=this.$foldData;a=this.getFoldsInRange(e.data.range),this.removeFolds(a);var l=this.getFoldLine(u.row),c=0;if(l){l.addRemoveChars(u.row,u.column,o.column-u.column),l.shiftRow(-n);var h=this.getFoldLine(i);h&&h!==l&&(h.merge(l),l=h),c=f.indexOf(l)+1}for(c;c<f.length;c++){var l=f[c];l.start.row>=u.row&&l.shiftRow(-n)}s=i}else{var p=Array(n);p.unshift(i,0);var d=t?this.$wrapData:this.$rowLengthCache;d.splice.apply(d,p);var f=this.$foldData,l=this.getFoldLine(i),c=0;if(l){var v=l.range.compareInside(o.row,o.column);v==0?(l=l.split(o.row,o.column),l&&(l.shiftRow(n),l.addRemoveChars(s,0,u.column-o.column))):v==-1&&(l.addRemoveChars(i,0,u.column-o.column),l.shiftRow(n)),c=f.indexOf(l)+1}for(c;c<f.length;c++){var l=f[c];l.start.row>=i&&l.shiftRow(n)}}else{n=Math.abs(e.data.range.start.column-e.data.range.end.column),r.indexOf("remove")!=-1&&(a=this.getFoldsInRange(e.data.range),this.removeFolds(a),n=-n);var l=this.getFoldLine(i);l&&l.addRemoveChars(i,o.column,n)}return t&&this.$wrapData.length!=this.doc.getLength()&&console.error("doc.getLength() and $wrapData.length have to be the same!"),this.$updating=!1,t?this.$updateWrapData(i,s):this.$updateRowLengthCache(i,s),a},this.$updateRowLengthCache=function(e,t,n){this.$rowLengthCache[e]=null,this.$rowLengthCache[t]=null},this.$updateWrapData=function(e,t){var r=this.doc.getAllLines(),i=this.getTabSize(),s=this.$wrapData,o=this.$wrapLimit,a,f,l=e;t=Math.min(t,r.length-1);while(l<=t)f=this.getFoldLine(l,f),f?(a=[],f.walk(function(e,t,i,s){var o;if(e!=null){o=this.$getDisplayTokens(e,a.length),o[0]=n;for(var f=1;f<o.length;f++)o[f]=u}else o=this.$getDisplayTokens(r[t].substring(s,i),a.length);a=a.concat(o)}.bind(this),f.end.row,r[f.end.row].length+1),s[f.start.row]=this.$computeWrapSplits(a,o,i),l=f.end.row+1):(a=this.$getDisplayTokens(r[l]),s[l]=this.$computeWrapSplits(a,o,i),l++)};var e=1,t=2,n=3,u=4,l=9,p=10,d=11,v=12;this.$computeWrapSplits=function(e,t){function f(t){var n=e.slice(s,t),i=n.length;n.join("").replace(/12/g,function(){i-=1}).replace(/2/g,function(){i-=1}),o+=i,r.push(o),s=t}if(e.length==0)return[];var r=[],i=e.length,s=0,o=0,a=this.$wrapAsCode;while(i-s>t){var c=s+t;if(e[c-1]>=p&&e[c]>=p){f(c);continue}if(e[c]==n||e[c]==u){for(c;c!=s-1;c--)if(e[c]==n)break;if(c>s){f(c);continue}c=s+t;for(c;c<e.length;c++)if(e[c]!=u)break;if(c==e.length)break;f(c);continue}var h=Math.max(c-(a?10:t-(t>>2)),s-1);while(c>h&&e[c]<n)c--;if(a){while(c>h&&e[c]<n)c--;while(c>h&&e[c]==l)c--}else while(c>h&&e[c]<p)c--;if(c>h){f(++c);continue}c=s+t,f(c)}return r},this.$getDisplayTokens=function(n,r){var i=[],s;r=r||0;for(var o=0;o<n.length;o++){var u=n.charCodeAt(o);if(u==9){s=this.getScreenTabSize(i.length+r),i.push(d);for(var a=1;a<s;a++)i.push(v)}else u==32?i.push(p):u>39&&u<48||u>57&&u<64?i.push(l):u>=4352&&m(u)?i.push(e,t):i.push(e)}return i},this.$getStringScreenWidth=function(e,t,n){if(t==0)return[0,0];t==null&&(t=Infinity),n=n||0;var r,i;for(i=0;i<e.length;i++){r=e.charCodeAt(i),r==9?n+=this.getScreenTabSize(n):r>=4352&&m(r)?n+=2:n+=1;if(n>t)break}return[n,i]},this.lineWidgets=null,this.getRowLength=function(e){if(this.lineWidgets)var t=this.lineWidgets[e]&&this.lineWidgets[e].rowCount||0;else t=0;return!this.$useWrapMode||!this.$wrapData[e]?1+t:this.$wrapData[e].length+1+t},this.getRowLineCount=function(e){return!this.$useWrapMode||!this.$wrapData[e]?1:this.$wrapData[e].length+1},this.getScreenLastRowColumn=function(e){var t=this.screenToDocumentPosition(e,Number.MAX_VALUE);return this.documentToScreenColumn(t.row,t.column)},this.getDocumentLastRowColumn=function(e,t){var n=this.documentToScreenRow(e,t);return this.getScreenLastRowColumn(n)},this.getDocumentLastRowColumnPosition=function(e,t){var n=this.documentToScreenRow(e,t);return this.screenToDocumentPosition(n,Number.MAX_VALUE/10)},this.getRowSplitData=function(e){return this.$useWrapMode?this.$wrapData[e]:undefined},this.getScreenTabSize=function(e){return this.$tabSize-e%this.$tabSize},this.screenToDocumentRow=function(e,t){return this.screenToDocumentPosition(e,t).row},this.screenToDocumentColumn=function(e,t){return this.screenToDocumentPosition(e,t).column},this.screenToDocumentPosition=function(e,t){if(e<0)return{row:0,column:0};var n,r=0,i=0,s,o=0,u=0,a=this.$screenRowCache,f=this.$getRowCacheIndex(a,e),l=a.length;if(l&&f>=0)var o=a[f],r=this.$docRowCache[f],c=e>a[l-1];else var c=!l;var h=this.getLength()-1,p=this.getNextFoldLine(r),d=p?p.start.row:Infinity;while(o<=e){u=this.getRowLength(r);if(o+u>e||r>=h)break;o+=u,r++,r>d&&(r=p.end.row+1,p=this.getNextFoldLine(r,p),d=p?p.start.row:Infinity),c&&(this.$docRowCache.push(r),this.$screenRowCache.push(o))}if(p&&p.start.row<=r)n=this.getFoldDisplayLine(p),r=p.start.row;else{if(o+u<=e||r>h)return{row:h,column:this.getLine(h).length};n=this.getLine(r),p=null}if(this.$useWrapMode){var v=this.$wrapData[r];if(v){var m=Math.floor(e-o);s=v[m],m>0&&v.length&&(i=v[m-1]||v[v.length-1],n=n.substring(i))}}return i+=this.$getStringScreenWidth(n,t)[1],this.$useWrapMode&&i>=s&&(i=s-1),p?p.idxToPosition(i):{row:r,column:i}},this.documentToScreenPosition=function(e,t){if(typeof t=="undefined")var n=this.$clipPositionToDocument(e.row,e.column);else n=this.$clipPositionToDocument(e,t);e=n.row,t=n.column;var r=0,i=null,s=null;s=this.getFoldAt(e,t,1),s&&(e=s.start.row,t=s.start.column);var o,u=0,a=this.$docRowCache,f=this.$getRowCacheIndex(a,e),l=a.length;if(l&&f>=0)var u=a[f],r=this.$screenRowCache[f],c=e>a[l-1];else var c=!l;var h=this.getNextFoldLine(u),p=h?h.start.row:Infinity;while(u<e){if(u>=p){o=h.end.row+1;if(o>e)break;h=this.getNextFoldLine(o,h),p=h?h.start.row:Infinity}else o=u+1;r+=this.getRowLength(u),u=o,c&&(this.$docRowCache.push(u),this.$screenRowCache.push(r))}var d="";h&&u>=p?(d=this.getFoldDisplayLine(h,e,t),i=h.start.row):(d=this.getLine(e).substring(0,t),i=e);if(this.$useWrapMode){var v=this.$wrapData[i];if(v){var m=0;while(d.length>=v[m])r++,m++;d=d.substring(v[m-1]||0,d.length)}}return{row:r,column:this.$getStringScreenWidth(d)[0]}},this.documentToScreenColumn=function(e,t){return this.documentToScreenPosition(e,t).column},this.documentToScreenRow=function(e,t){return this.documentToScreenPosition(e,t).row},this.getScreenLength=function(){var e=0,t=null;if(!this.$useWrapMode){e=this.getLength();var n=this.$foldData;for(var r=0;r<n.length;r++)t=n[r],e-=t.end.row-t.start.row}else{var i=this.$wrapData.length,s=0,r=0,t=this.$foldData[r++],o=t?t.start.row:Infinity;while(s<i){var u=this.$wrapData[s];e+=u?u.length+1:1,s++,s>o&&(s=t.end.row+1,t=this.$foldData[r++],o=t?t.start.row:Infinity)}}return this.lineWidgets&&(e+=this.$getWidgetScreenLength()),e},this.$setFontMetrics=function(e){},this.destroy=function(){this.bgTokenizer&&(this.bgTokenizer.setDocument(null),this.bgTokenizer=null),this.$stopWorker()}}).call(p.prototype),e("./edit_session/folding").Folding.call(p.prototype),e("./edit_session/bracket_match").BracketMatch.call(p.prototype),s.defineOptions(p.prototype,"session",{wrap:{set:function(e){!e||e=="off"?e=!1:e=="free"?e=!0:e=="printMargin"?e=-1:typeof e=="string"&&(e=parseInt(e,10)||!1);if(this.$wrap==e)return;if(!e)this.setUseWrapMode(!1);else{var t=typeof e=="number"?e:null;this.setWrapLimitRange(t,t),this.setUseWrapMode(!0)}this.$wrap=e},get:function(){return this.getUseWrapMode()?this.$wrap==-1?"printMargin":this.getWrapLimitRange().min?this.$wrap:"free":"off"},handlesSet:!0},wrapMethod:{set:function(e){e=e=="auto"?this.$mode.type!="text":e!="text",e!=this.$wrapAsCode&&(this.$wrapAsCode=e,this.$useWrapMode&&(this.$modified=!0,this.$resetRowCache(0),this.$updateWrapData(0,this.getLength()-1)))},initialValue:"auto"},firstLineNumber:{set:function(){this._signal("changeBreakpoint")},initialValue:1},useWorker:{set:function(e){this.$useWorker=e,this.$stopWorker(),e&&this.$startWorker()},initialValue:!0},useSoftTabs:{initialValue:!0},tabSize:{set:function(e){if(isNaN(e)||this.$tabSize===e)return;this.$modified=!0,this.$rowLengthCache=[],this.$tabSize=e,this._signal("changeTabSize")},initialValue:4,handlesSet:!0},overwrite:{set:function(e){this._signal("changeOverwrite")},initialValue:!1},newLineMode:{set:function(e){this.doc.setNewLineMode(e)},get:function(){return this.doc.getNewLineMode()},handlesSet:!0},mode:{set:function(e){this.setMode(e)},get:function(){return this.$modeId}}}),t.EditSession=p}),ace.define("ace/search",["require","exports","module","ace/lib/lang","ace/lib/oop","ace/range"],function(e,t,n){"use strict";var r=e("./lib/lang"),i=e("./lib/oop"),s=e("./range").Range,o=function(){this.$options={}};(function(){this.set=function(e){return i.mixin(this.$options,e),this},this.getOptions=function(){return r.copyObject(this.$options)},this.setOptions=function(e){this.$options=e},this.find=function(e){var t=this.$matchIterator(e,this.$options);if(!t)return!1;var n=null;return t.forEach(function(e,t,r){if(!e.start){var i=e.offset+(r||0);n=new s(t,i,t,i+e.length)}else n=e;return!0}),n},this.findAll=function(e){var t=this.$options;if(!t.needle)return[];this.$assembleRegExp(t);var n=t.range,i=n?e.getLines(n.start.row,n.end.row):e.doc.getAllLines(),o=[],u=t.re;if(t.$isMultiLine){var a=u.length,f=i.length-a,l;e:for(var c=u.offset||0;c<=f;c++){for(var h=0;h<a;h++)if(i[c+h].search(u[h])==-1)continue e;var p=i[c],d=i[c+a-1],v=p.length-p.match(u[0])[0].length,m=d.match(u[a-1])[0].length;if(l&&l.end.row===c&&l.end.column>v)continue;o.push(l=new s(c,v,c+a-1,m)),a>2&&(c=c+a-2)}}else for(var g=0;g<i.length;g++){var y=r.getMatchOffsets(i[g],u);for(var h=0;h<y.length;h++){var b=y[h];o.push(new s(g,b.offset,g,b.offset+b.length))}}if(n){var w=n.start.column,E=n.start.column,g=0,h=o.length-1;while(g<h&&o[g].start.column<w&&o[g].start.row==n.start.row)g++;while(g<h&&o[h].end.column>E&&o[h].end.row==n.end.row)h--;o=o.slice(g,h+1);for(g=0,h=o.length;g<h;g++)o[g].start.row+=n.start.row,o[g].end.row+=n.start.row}return o},this.replace=function(e,t){var n=this.$options,r=this.$assembleRegExp(n);if(n.$isMultiLine)return t;if(!r)return;var i=r.exec(e);if(!i||i[0].length!=e.length)return null;t=e.replace(r,t);if(n.preserveCase){t=t.split("");for(var s=Math.min(e.length,e.length);s--;){var o=e[s];o&&o.toLowerCase()!=o?t[s]=t[s].toUpperCase():t[s]=t[s].toLowerCase()}t=t.join("")}return t},this.$matchIterator=function(e,t){var n=this.$assembleRegExp(t);if(!n)return!1;var i=this,o,u=t.backwards;if(t.$isMultiLine)var a=n.length,f=function(t,r,i){var u=t.search(n[0]);if(u==-1)return;for(var f=1;f<a;f++){t=e.getLine(r+f);if(t.search(n[f])==-1)return}var l=t.match(n[a-1])[0].length,c=new s(r,u,r+a-1,l);n.offset==1?(c.start.row--,c.start.column=Number.MAX_VALUE):i&&(c.start.column+=i);if(o(c))return!0};else if(u)var f=function(e,t,i){var s=r.getMatchOffsets(e,n);for(var u=s.length-1;u>=0;u--)if(o(s[u],t,i))return!0};else var f=function(e,t,i){var s=r.getMatchOffsets(e,n);for(var u=0;u<s.length;u++)if(o(s[u],t,i))return!0};return{forEach:function(n){o=n,i.$lineIterator(e,t).forEach(f)}}},this.$assembleRegExp=function(e,t){if(e.needle instanceof RegExp)return e.re=e.needle;var n=e.needle;if(!e.needle)return e.re=!1;e.regExp||(n=r.escapeRegExp(n)),e.wholeWord&&(n="\\b"+n+"\\b");var i=e.caseSensitive?"g":"gi";e.$isMultiLine=!t&&/[\n\r]/.test(n);if(e.$isMultiLine)return e.re=this.$assembleMultilineRegExp(n,i);try{var s=new RegExp(n,i)}catch(o){s=!1}return e.re=s},this.$assembleMultilineRegExp=function(e,t){var n=e.replace(/\r\n|\r|\n/g,"$\n^").split("\n"),r=[];for(var i=0;i<n.length;i++)try{r.push(new RegExp(n[i],t))}catch(s){return!1}return n[0]==""?(r.shift(),r.offset=1):r.offset=0,r},this.$lineIterator=function(e,t){var n=t.backwards==1,r=t.skipCurrent!=0,i=t.range,s=t.start;s||(s=i?i[n?"end":"start"]:e.selection.getRange()),s.start&&(s=s[r!=n?"end":"start"]);var o=i?i.start.row:0,u=i?i.end.row:e.getLength()-1,a=n?function(n){var r=s.row,i=e.getLine(r).substring(0,s.column);if(n(i,r))return;for(r--;r>=o;r--)if(n(e.getLine(r),r))return;if(t.wrap==0)return;for(r=u,o=s.row;r>=o;r--)if(n(e.getLine(r),r))return}:function(n){var r=s.row,i=e.getLine(r).substr(s.column);if(n(i,r,s.column))return;for(r+=1;r<=u;r++)if(n(e.getLine(r),r))return;if(t.wrap==0)return;for(r=o,u=s.row;r<=u;r++)if(n(e.getLine(r),r))return};return{forEach:a}}}).call(o.prototype),t.Search=o}),ace.define("ace/keyboard/hash_handler",["require","exports","module","ace/lib/keys","ace/lib/useragent"],function(e,t,n){"use strict";function s(e,t){this.platform=t||(i.isMac?"mac":"win"),this.commands={},this.commandKeyBinding={};if(this.__defineGetter__&&this.__defineSetter__&&typeof console!="undefined"&&console.error){var n=!1,r=function(){n||(n=!0,console.error("commmandKeyBinding has too many m's. use commandKeyBinding"))};this.__defineGetter__("commmandKeyBinding",function(){return r(),this.commandKeyBinding}),this.__defineSetter__("commmandKeyBinding",function(e){return r(),this.commandKeyBinding=e})}else this.commmandKeyBinding=this.commandKeyBinding;this.addCommands(e)}var r=e("../lib/keys"),i=e("../lib/useragent");(function(){this.addCommand=function(e){this.commands[e.name]&&this.removeCommand(e),this.commands[e.name]=e,e.bindKey&&this._buildKeyHash(e)},this.removeCommand=function(e){var t=typeof e=="string"?e:e.name;e=this.commands[t],delete this.commands[t];var n=this.commandKeyBinding;for(var r in n)for(var i in n[r])n[r][i]==e&&delete n[r][i]},this.bindKey=function(e,t){if(!e)return;if(typeof t=="function"){this.addCommand({exec:t,bindKey:e,name:t.name||e});return}var n=this.commandKeyBinding;e.split("|").forEach(function(e){var r=this.parseKeys(e,t),i=r.hashId;(n[i]||(n[i]={}))[r.key]=t},this)},this.addCommands=function(e){e&&Object.keys(e).forEach(function(t){var n=e[t];if(!n)return;if(typeof n=="string")return this.bindKey(n,t);typeof n=="function"&&(n={exec:n});if(typeof n!="object")return;n.name||(n.name=t),this.addCommand(n)},this)},this.removeCommands=function(e){Object.keys(e).forEach(function(t){this.removeCommand(e[t])},this)},this.bindKeys=function(e){Object.keys(e).forEach(function(t){this.bindKey(t,e[t])},this)},this._buildKeyHash=function(e){var t=e.bindKey;if(!t)return;var n=typeof t=="string"?t:t[this.platform];this.bindKey(n,e)},this.parseKeys=function(e){e.indexOf(" ")!=-1&&(e=e.split(/\s+/).pop());var t=e.toLowerCase().split(/[\-\+]([\-\+])?/).filter(function(e){return e}),n=t.pop(),i=r[n];if(r.FUNCTION_KEYS[i])n=r.FUNCTION_KEYS[i].toLowerCase();else{if(!t.length)return{key:n,hashId:-1};if(t.length==1&&t[0]=="shift")return{key:n.toUpperCase(),hashId:-1}}var s=0;for(var o=t.length;o--;){var u=r.KEY_MODS[t[o]];if(u==null)return typeof console!="undefined"&&console.error("invalid modifier "+t[o]+" in "+e),!1;s|=u}return{key:n,hashId:s}},this.findKeyCommand=function(t,n){var r=this.commandKeyBinding;return r[t]&&r[t][n]},this.handleKeyboard=function(e,t,n,r){return{command:this.findKeyCommand(t,n)}}}).call(s.prototype),t.HashHandler=s}),ace.define("ace/commands/command_manager",["require","exports","module","ace/lib/oop","ace/keyboard/hash_handler","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("../lib/oop"),i=e("../keyboard/hash_handler").HashHandler,s=e("../lib/event_emitter").EventEmitter,o=function(e,t){i.call(this,t,e),this.byName=this.commands,this.setDefaultHandler("exec",function(e){return e.command.exec(e.editor,e.args||{})})};r.inherits(o,i),function(){r.implement(this,s),this.exec=function(e,t,n){typeof e=="string"&&(e=this.commands[e]);if(!e)return!1;if(t&&t.$readOnly&&!e.readOnly)return!1;var r={editor:t,command:e,args:n},i=this._emit("exec",r);return this._signal("afterExec",r),i===!1?!1:!0},this.toggleRecording=function(e){if(this.$inReplay)return;return e&&e._emit("changeStatus"),this.recording?(this.macro.pop(),this.removeEventListener("exec",this.$addCommandToMacro),this.macro.length||(this.macro=this.oldMacro),this.recording=!1):(this.$addCommandToMacro||(this.$addCommandToMacro=function(e){this.macro.push([e.command,e.args])}.bind(this)),this.oldMacro=this.macro,this.macro=[],this.on("exec",this.$addCommandToMacro),this.recording=!0)},this.replay=function(e){if(this.$inReplay||!this.macro)return;if(this.recording)return this.toggleRecording(e);try{this.$inReplay=!0,this.macro.forEach(function(t){typeof t=="string"?this.exec(t,e):this.exec(t[0],e,t[1])},this)}finally{this.$inReplay=!1}},this.trimMacro=function(e){return e.map(function(e){return typeof e[0]!="string"&&(e[0]=e[0].name),e[1]||(e=e[0]),e})}}.call(o.prototype),t.CommandManager=o}),ace.define("ace/commands/default_commands",["require","exports","module","ace/lib/lang","ace/config","ace/range"],function(e,t,n){"use strict";function o(e,t){return{win:e,mac:t}}var r=e("../lib/lang"),i=e("../config"),s=e("../range").Range;t.commands=[{name:"showSettingsMenu",bindKey:o("Ctrl-,","Command-,"),exec:function(e){i.loadModule("ace/ext/settings_menu",function(t){t.init(e),e.showSettingsMenu()})},readOnly:!0},{name:"goToNextError",bindKey:o("Alt-E","Ctrl-E"),exec:function(e){i.loadModule("ace/ext/error_marker",function(t){t.showErrorMarker(e,1)})},scrollIntoView:"animate",readOnly:!0},{name:"goToPreviousError",bindKey:o("Alt-Shift-E","Ctrl-Shift-E"),exec:function(e){i.loadModule("ace/ext/error_marker",function(t){t.showErrorMarker(e,-1)})},scrollIntoView:"animate",readOnly:!0},{name:"selectall",bindKey:o("Ctrl-A","Command-A"),exec:function(e){e.selectAll()},readOnly:!0},{name:"centerselection",bindKey:o(null,"Ctrl-L"),exec:function(e){e.centerSelection()},readOnly:!0},{name:"gotoline",bindKey:o("Ctrl-L","Command-L"),exec:function(e){var t=parseInt(prompt("Enter line number:"),10);isNaN(t)||e.gotoLine(t)},readOnly:!0},{name:"fold",bindKey:o("Alt-L|Ctrl-F1","Command-Alt-L|Command-F1"),exec:function(e){e.session.toggleFold(!1)},scrollIntoView:"center",readOnly:!0},{name:"unfold",bindKey:o("Alt-Shift-L|Ctrl-Shift-F1","Command-Alt-Shift-L|Command-Shift-F1"),exec:function(e){e.session.toggleFold(!0)},scrollIntoView:"center",readOnly:!0},{name:"toggleFoldWidget",bindKey:o("F2","F2"),exec:function(e){e.session.toggleFoldWidget()},scrollIntoView:"center",readOnly:!0},{name:"toggleParentFoldWidget",bindKey:o("Alt-F2","Alt-F2"),exec:function(e){e.session.toggleFoldWidget(!0)},scrollIntoView:"center",readOnly:!0},{name:"foldall",bindKey:o("Ctrl-Alt-0","Ctrl-Command-Option-0"),exec:function(e){e.session.foldAll()},scrollIntoView:"center",readOnly:!0},{name:"foldOther",bindKey:o("Alt-0","Command-Option-0"),exec:function(e){e.session.foldAll(),e.session.unfold(e.selection.getAllRanges())},scrollIntoView:"center",readOnly:!0},{name:"unfoldall",bindKey:o("Alt-Shift-0","Command-Option-Shift-0"),exec:function(e){e.session.unfold()},scrollIntoView:"center",readOnly:!0},{name:"findnext",bindKey:o("Ctrl-K","Command-G"),exec:function(e){e.findNext()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"findprevious",bindKey:o("Ctrl-Shift-K","Command-Shift-G"),exec:function(e){e.findPrevious()},multiSelectAction:"forEach",scrollIntoView:"center",readOnly:!0},{name:"selectOrFindNext",bindKey:o("Alt-K","Ctrl-G"),exec:function(e){e.selection.isEmpty()?e.selection.selectWord():e.findNext()},readOnly:!0},{name:"selectOrFindPrevious",bindKey:o("Alt-Shift-K","Ctrl-Shift-G"),exec:function(e){e.selection.isEmpty()?e.selection.selectWord():e.findPrevious()},readOnly:!0},{name:"find",bindKey:o("Ctrl-F","Command-F"),exec:function(e){i.loadModule("ace/ext/searchbox",function(t){t.Search(e)})},readOnly:!0},{name:"overwrite",bindKey:"Insert",exec:function(e){e.toggleOverwrite()},readOnly:!0},{name:"selecttostart",bindKey:o("Ctrl-Shift-Home","Command-Shift-Up"),exec:function(e){e.getSelection().selectFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotostart",bindKey:o("Ctrl-Home","Command-Home|Command-Up"),exec:function(e){e.navigateFileStart()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectup",bindKey:o("Shift-Up","Shift-Up"),exec:function(e){e.getSelection().selectUp()},multiSelectAction:"forEach",readOnly:!0},{name:"golineup",bindKey:o("Up","Up|Ctrl-P"),exec:function(e,t){e.navigateUp(t.times)},multiSelectAction:"forEach",readOnly:!0},{name:"selecttoend",bindKey:o("Ctrl-Shift-End","Command-Shift-Down"),exec:function(e){e.getSelection().selectFileEnd()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"gotoend",bindKey:o("Ctrl-End","Command-End|Command-Down"),exec:function(e){e.navigateFileEnd()},multiSelectAction:"forEach",readOnly:!0,scrollIntoView:"animate",aceCommandGroup:"fileJump"},{name:"selectdown",bindKey:o("Shift-Down","Shift-Down"),exec:function(e){e.getSelection().selectDown()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"golinedown",bindKey:o("Down","Down|Ctrl-N"),exec:function(e,t){e.navigateDown(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordleft",bindKey:o("Ctrl-Shift-Left","Option-Shift-Left"),exec:function(e){e.getSelection().selectWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordleft",bindKey:o("Ctrl-Left","Option-Left"),exec:function(e){e.navigateWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolinestart",bindKey:o("Alt-Shift-Left","Command-Shift-Left"),exec:function(e){e.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolinestart",bindKey:o("Alt-Left|Home","Command-Left|Home|Ctrl-A"),exec:function(e){e.navigateLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectleft",bindKey:o("Shift-Left","Shift-Left"),exec:function(e){e.getSelection().selectLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoleft",bindKey:o("Left","Left|Ctrl-B"),exec:function(e,t){e.navigateLeft(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectwordright",bindKey:o("Ctrl-Shift-Right","Option-Shift-Right"),exec:function(e){e.getSelection().selectWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotowordright",bindKey:o("Ctrl-Right","Option-Right"),exec:function(e){e.navigateWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selecttolineend",bindKey:o("Alt-Shift-Right","Command-Shift-Right"),exec:function(e){e.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotolineend",bindKey:o("Alt-Right|End","Command-Right|End|Ctrl-E"),exec:function(e){e.navigateLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectright",bindKey:o("Shift-Right","Shift-Right"),exec:function(e){e.getSelection().selectRight()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"gotoright",bindKey:o("Right","Right|Ctrl-F"),exec:function(e,t){e.navigateRight(t.times)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectpagedown",bindKey:"Shift-PageDown",exec:function(e){e.selectPageDown()},readOnly:!0},{name:"pagedown",bindKey:o(null,"Option-PageDown"),exec:function(e){e.scrollPageDown()},readOnly:!0},{name:"gotopagedown",bindKey:o("PageDown","PageDown|Ctrl-V"),exec:function(e){e.gotoPageDown()},readOnly:!0},{name:"selectpageup",bindKey:"Shift-PageUp",exec:function(e){e.selectPageUp()},readOnly:!0},{name:"pageup",bindKey:o(null,"Option-PageUp"),exec:function(e){e.scrollPageUp()},readOnly:!0},{name:"gotopageup",bindKey:"PageUp",exec:function(e){e.gotoPageUp()},readOnly:!0},{name:"scrollup",bindKey:o("Ctrl-Up",null),exec:function(e){e.renderer.scrollBy(0,-2*e.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"scrolldown",bindKey:o("Ctrl-Down",null),exec:function(e){e.renderer.scrollBy(0,2*e.renderer.layerConfig.lineHeight)},readOnly:!0},{name:"selectlinestart",bindKey:"Shift-Home",exec:function(e){e.getSelection().selectLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"selectlineend",bindKey:"Shift-End",exec:function(e){e.getSelection().selectLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"togglerecording",bindKey:o("Ctrl-Alt-E","Command-Option-E"),exec:function(e){e.commands.toggleRecording(e)},readOnly:!0},{name:"replaymacro",bindKey:o("Ctrl-Shift-E","Command-Shift-E"),exec:function(e){e.commands.replay(e)},readOnly:!0},{name:"jumptomatching",bindKey:o("Ctrl-P","Ctrl-P"),exec:function(e){e.jumpToMatching()},multiSelectAction:"forEach",readOnly:!0},{name:"selecttomatching",bindKey:o("Ctrl-Shift-P","Ctrl-Shift-P"),exec:function(e){e.jumpToMatching(!0)},multiSelectAction:"forEach",readOnly:!0},{name:"passKeysToBrowser",bindKey:o("null","null"),exec:function(){},passEvent:!0,readOnly:!0},{name:"cut",exec:function(e){var t=e.getSelectionRange();e._emit("cut",t),e.selection.isEmpty()||(e.session.remove(t),e.clearSelection())},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"removeline",bindKey:o("Ctrl-D","Command-D"),exec:function(e){e.removeLines()},scrollIntoView:"cursor",multiSelectAction:"forEachLine"},{name:"duplicateSelection",bindKey:o("Ctrl-Shift-D","Command-Shift-D"),exec:function(e){e.duplicateSelection()},scrollIntoView:"cursor",multiSelectAction:"forEach"},{name:"sortlines",bindKey:o("Ctrl-Alt-S","Command-Alt-S"),exec:function(e){e.sortLines()},scrollIntoView:"selection",multiSelectAction:"forEachLine"},{name:"togglecomment",bindKey:o("Ctrl-/","Command-/"),exec:function(e){e.toggleCommentLines()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"toggleBlockComment",bindKey:o("Ctrl-Shift-/","Command-Shift-/"),exec:function(e){e.toggleBlockComment()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"modifyNumberUp",bindKey:o("Ctrl-Shift-Up","Alt-Shift-Up"),exec:function(e){e.modifyNumber(1)},multiSelectAction:"forEach"},{name:"modifyNumberDown",bindKey:o("Ctrl-Shift-Down","Alt-Shift-Down"),exec:function(e){e.modifyNumber(-1)},multiSelectAction:"forEach"},{name:"replace",bindKey:o("Ctrl-H","Command-Option-F"),exec:function(e){i.loadModule("ace/ext/searchbox",function(t){t.Search(e,!0)})}},{name:"undo",bindKey:o("Ctrl-Z","Command-Z"),exec:function(e){e.undo()}},{name:"redo",bindKey:o("Ctrl-Shift-Z|Ctrl-Y","Command-Shift-Z|Command-Y"),exec:function(e){e.redo()}},{name:"copylinesup",bindKey:o("Alt-Shift-Up","Command-Option-Up"),exec:function(e){e.copyLinesUp()},scrollIntoView:"cursor"},{name:"movelinesup",bindKey:o("Alt-Up","Option-Up"),exec:function(e){e.moveLinesUp()},scrollIntoView:"cursor"},{name:"copylinesdown",bindKey:o("Alt-Shift-Down","Command-Option-Down"),exec:function(e){e.copyLinesDown()},scrollIntoView:"cursor"},{name:"movelinesdown",bindKey:o("Alt-Down","Option-Down"),exec:function(e){e.moveLinesDown()},scrollIntoView:"cursor"},{name:"del",bindKey:o("Delete","Delete|Ctrl-D|Shift-Delete"),exec:function(e){e.remove("right")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"backspace",bindKey:o("Shift-Backspace|Backspace","Ctrl-Backspace|Shift-Backspace|Backspace|Ctrl-H"),exec:function(e){e.remove("left")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"cut_or_delete",bindKey:o("Shift-Delete",null),exec:function(e){if(!e.selection.isEmpty())return!1;e.remove("left")},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolinestart",bindKey:o("Alt-Backspace","Command-Backspace"),exec:function(e){e.removeToLineStart()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removetolineend",bindKey:o("Alt-Delete","Ctrl-K"),exec:function(e){e.removeToLineEnd()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordleft",bindKey:o("Ctrl-Backspace","Alt-Backspace|Ctrl-Alt-Backspace"),exec:function(e){e.removeWordLeft()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"removewordright",bindKey:o("Ctrl-Delete","Alt-Delete"),exec:function(e){e.removeWordRight()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"outdent",bindKey:o("Shift-Tab","Shift-Tab"),exec:function(e){e.blockOutdent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"indent",bindKey:o("Tab","Tab"),exec:function(e){e.indent()},multiSelectAction:"forEach",scrollIntoView:"selectionPart"},{name:"blockoutdent",bindKey:o("Ctrl-[","Ctrl-["),exec:function(e){e.blockOutdent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"blockindent",bindKey:o("Ctrl-]","Ctrl-]"),exec:function(e){e.blockIndent()},multiSelectAction:"forEachLine",scrollIntoView:"selectionPart"},{name:"insertstring",exec:function(e,t){e.insert(t)},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"inserttext",exec:function(e,t){e.insert(r.stringRepeat(t.text||"",t.times||1))},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"splitline",bindKey:o(null,"Ctrl-O"),exec:function(e){e.splitLine()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"transposeletters",bindKey:o("Ctrl-T","Ctrl-T"),exec:function(e){e.transposeLetters()},multiSelectAction:function(e){e.transposeSelections(1)},scrollIntoView:"cursor"},{name:"touppercase",bindKey:o("Ctrl-U","Ctrl-U"),exec:function(e){e.toUpperCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"tolowercase",bindKey:o("Ctrl-Shift-U","Ctrl-Shift-U"),exec:function(e){e.toLowerCase()},multiSelectAction:"forEach",scrollIntoView:"cursor"},{name:"expandtoline",bindKey:o("Ctrl-Shift-L","Command-Shift-L"),exec:function(e){var t=e.selection.getRange();t.start.column=t.end.column=0,t.end.row++,e.selection.setRange(t,!1)},multiSelectAction:"forEach",scrollIntoView:"cursor",readOnly:!0},{name:"joinlines",bindKey:o(null,null),exec:function(e){var t=e.selection.isBackwards(),n=t?e.selection.getSelectionLead():e.selection.getSelectionAnchor(),i=t?e.selection.getSelectionAnchor():e.selection.getSelectionLead(),o=e.session.doc.getLine(n.row).length,u=e.session.doc.getTextRange(e.selection.getRange()),a=u.replace(/\n\s*/," ").length,f=e.session.doc.getLine(n.row);for(var l=n.row+1;l<=i.row+1;l++){var c=r.stringTrimLeft(r.stringTrimRight(e.session.doc.getLine(l)));c.length!==0&&(c=" "+c),f+=c}i.row+1<e.session.doc.getLength()-1&&(f+=e.session.doc.getNewLineCharacter()),e.clearSelection(),e.session.doc.replace(new s(n.row,0,i.row+2,0),f),a>0?(e.selection.moveCursorTo(n.row,n.column),e.selection.selectTo(n.row,n.column+a)):(o=e.session.doc.getLine(n.row).length>o?o+1:o,e.selection.moveCursorTo(n.row,o))},multiSelectAction:"forEach",readOnly:!0},{name:"invertSelection",bindKey:o(null,null),exec:function(e){var t=e.session.doc.getLength()-1,n=e.session.doc.getLine(t).length,r=e.selection.rangeList.ranges,i=[];r.length<1&&(r=[e.selection.getRange()]);for(var o=0;o<r.length;o++)o==r.length-1&&(r[o].end.row!==t||r[o].end.column!==n)&&i.push(new s(r[o].end.row,r[o].end.column,t,n)),o===0?(r[o].start.row!==0||r[o].start.column!==0)&&i.push(new s(0,0,r[o].start.row,r[o].start.column)):i.push(new s(r[o-1].end.row,r[o-1].end.column,r[o].start.row,r[o].start.column));e.exitMultiSelectMode(),e.clearSelection();for(var o=0;o<i.length;o++)e.selection.addRange(i[o],!1)},readOnly:!0,scrollIntoView:"none"}]}),ace.define("ace/editor",["require","exports","module","ace/lib/fixoldbrowsers","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/lib/useragent","ace/keyboard/textinput","ace/mouse/mouse_handler","ace/mouse/fold_handler","ace/keyboard/keybinding","ace/edit_session","ace/search","ace/range","ace/lib/event_emitter","ace/commands/command_manager","ace/commands/default_commands","ace/config","ace/token_iterator"],function(e,t,n){"use strict";e("./lib/fixoldbrowsers");var r=e("./lib/oop"),i=e("./lib/dom"),s=e("./lib/lang"),o=e("./lib/useragent"),u=e("./keyboard/textinput").TextInput,a=e("./mouse/mouse_handler").MouseHandler,f=e("./mouse/fold_handler").FoldHandler,l=e("./keyboard/keybinding").KeyBinding,c=e("./edit_session").EditSession,h=e("./search").Search,p=e("./range").Range,d=e("./lib/event_emitter").EventEmitter,v=e("./commands/command_manager").CommandManager,m=e("./commands/default_commands").commands,g=e("./config"),y=e("./token_iterator").TokenIterator,b=function(e,t){var n=e.getContainerElement();this.container=n,this.renderer=e,this.commands=new v(o.isMac?"mac":"win",m),this.textInput=new u(e.getTextAreaContainer(),this),this.renderer.textarea=this.textInput.getElement(),this.keyBinding=new l(this),this.$mouseHandler=new a(this),new f(this),this.$blockScrolling=0,this.$search=(new h).set({wrap:!0}),this.$historyTracker=this.$historyTracker.bind(this),this.commands.on("exec",this.$historyTracker),this.$initOperationListeners(),this._$emitInputEvent=s.delayedCall(function(){this._signal("input",{}),this.session&&this.session.bgTokenizer&&this.session.bgTokenizer.scheduleStart()}.bind(this)),this.on("change",function(e,t){t._$emitInputEvent.schedule(31)}),this.setSession(t||new c("")),g.resetOptions(this),g._signal("editor",this)};(function(){r.implement(this,d),this.$initOperationListeners=function(){function e(e){return e[e.length-1]}this.selections=[],this.commands.on("exec",function(t){this.startOperation(t);var n=t.command;if(n.aceCommandGroup=="fileJump"){var r=this.prevOp;if(!r||r.command.aceCommandGroup!="fileJump")this.lastFileJumpPos=e(this.selections)}else this.lastFileJumpPos=null}.bind(this),!0),this.commands.on("afterExec",function(e){var t=e.command;t.aceCommandGroup=="fileJump"&&this.lastFileJumpPos&&!this.curOp.selectionChanged&&this.selection.fromJSON(this.lastFileJumpPos),this.endOperation(e)}.bind(this),!0),this.$opResetTimer=s.delayedCall(this.endOperation.bind(this)),this.on("change",function(){this.curOp||this.startOperation(),this.curOp.docChanged=!0}.bind(this),!0),this.on("changeSelection",function(){this.curOp||this.startOperation(),this.curOp.selectionChanged=!0}.bind(this),!0)},this.curOp=null,this.prevOp={},this.startOperation=function(e){if(this.curOp){if(!e||this.curOp.command)return;this.prevOp=this.curOp}e||(this.previousCommand=null,e={}),this.$opResetTimer.schedule(),this.curOp={command:e.command||{},args:e.args,scrollTop:this.renderer.scrollTop};var t=this.curOp.command;t&&t.scrollIntoView&&this.$blockScrolling++,this.selections.push(this.selection.toJSON())},this.endOperation=function(){if(this.curOp){var e=this.curOp.command;if(e&&e.scrollIntoView){this.$blockScrolling--;switch(e.scrollIntoView){case"center":this.renderer.scrollCursorIntoView(null,.5);break;case"animate":case"cursor":this.renderer.scrollCursorIntoView();break;case"selectionPart":var t=this.selection.getRange(),n=this.renderer.layerConfig;(t.start.row>=n.lastRow||t.end.row<=n.firstRow)&&this.renderer.scrollSelectionIntoView(this.selection.anchor,this.selection.lead);break;default:}e.scrollIntoView=="animate"&&this.renderer.animateScrolling(this.curOp.scrollTop)}this.prevOp=this.curOp,this.curOp=null}},this.$mergeableCommands=["backspace","del","insertstring"],this.$historyTracker=function(e){if(!this.$mergeUndoDeltas)return;var t=this.prevOp,n=this.$mergeableCommands,r=t.command&&e.command.name==t.command.name;if(e.command.name=="insertstring"){var i=e.args;this.mergeNextCommand===undefined&&(this.mergeNextCommand=!0),r=r&&this.mergeNextCommand&&(!/\s/.test(i)||/\s/.test(t.args)),this.mergeNextCommand=!0}else r=r&&n.indexOf(e.command.name)!==-1;this.$mergeUndoDeltas!="always"&&Date.now()-this.sequenceStartTime>2e3&&(r=!1),r?this.session.mergeUndoDeltas=!0:n.indexOf(e.command.name)!==-1&&(this.sequenceStartTime=Date.now())},this.setKeyboardHandler=function(e){if(!e)this.keyBinding.setKeyboardHandler(null);else if(typeof e=="string"){this.$keybindingId=e;var t=this;g.loadModule(["keybinding",e],function(n){t.$keybindingId==e&&t.keyBinding.setKeyboardHandler(n&&n.handler)})}else this.$keybindingId=null,this.keyBinding.setKeyboardHandler(e)},this.getKeyboardHandler=function(){return this.keyBinding.getKeyboardHandler()},this.setSession=function(e){if(this.session==e)return;var t=this.session;if(t){this.session.removeEventListener("change",this.$onDocumentChange),this.session.removeEventListener("changeMode",this.$onChangeMode),this.session.removeEventListener("tokenizerUpdate",this.$onTokenizerUpdate),this.session.removeEventListener("changeTabSize",this.$onChangeTabSize),this.session.removeEventListener("changeWrapLimit",this.$onChangeWrapLimit),this.session.removeEventListener("changeWrapMode",this.$onChangeWrapMode),this.session.removeEventListener("onChangeFold",this.$onChangeFold),this.session.removeEventListener("changeFrontMarker",this.$onChangeFrontMarker),this.session.removeEventListener("changeBackMarker",this.$onChangeBackMarker),this.session.removeEventListener("changeBreakpoint",this.$onChangeBreakpoint),this.session.removeEventListener("changeAnnotation",this.$onChangeAnnotation),this.session.removeEventListener("changeOverwrite",this.$onCursorChange),this.session.removeEventListener("changeScrollTop",this.$onScrollTopChange),this.session.removeEventListener("changeScrollLeft",this.$onScrollLeftChange);var n=this.session.getSelection();n.removeEventListener("changeCursor",this.$onCursorChange),n.removeEventListener("changeSelection",this.$onSelectionChange)}this.session=e,e?(this.$onDocumentChange=this.onDocumentChange.bind(this),e.addEventListener("change",this.$onDocumentChange),this.renderer.setSession(e),this.$onChangeMode=this.onChangeMode.bind(this),e.addEventListener("changeMode",this.$onChangeMode),this.$onTokenizerUpdate=this.onTokenizerUpdate.bind(this),e.addEventListener("tokenizerUpdate",this.$onTokenizerUpdate),this.$onChangeTabSize=this.renderer.onChangeTabSize.bind(this.renderer),e.addEventListener("changeTabSize",this.$onChangeTabSize),this.$onChangeWrapLimit=this.onChangeWrapLimit.bind(this),e.addEventListener("changeWrapLimit",this.$onChangeWrapLimit),this.$onChangeWrapMode=this.onChangeWrapMode.bind(this),e.addEventListener("changeWrapMode",this.$onChangeWrapMode),this.$onChangeFold=this.onChangeFold.bind(this),e.addEventListener("changeFold",this.$onChangeFold),this.$onChangeFrontMarker=this.onChangeFrontMarker.bind(this),this.session.addEventListener("changeFrontMarker",this.$onChangeFrontMarker),this.$onChangeBackMarker=this.onChangeBackMarker.bind(this),this.session.addEventListener("changeBackMarker",this.$onChangeBackMarker),this.$onChangeBreakpoint=this.onChangeBreakpoint.bind(this),this.session.addEventListener("changeBreakpoint",this.$onChangeBreakpoint),this.$onChangeAnnotation=this.onChangeAnnotation.bind(this),this.session.addEventListener("changeAnnotation",this.$onChangeAnnotation),this.$onCursorChange=this.onCursorChange.bind(this),this.session.addEventListener("changeOverwrite",this.$onCursorChange),this.$onScrollTopChange=this.onScrollTopChange.bind(this),this.session.addEventListener("changeScrollTop",this.$onScrollTopChange),this.$onScrollLeftChange=this.onScrollLeftChange.bind(this),this.session.addEventListener("changeScrollLeft",this.$onScrollLeftChange),this.selection=e.getSelection(),this.selection.addEventListener("changeCursor",this.$onCursorChange),this.$onSelectionChange=this.onSelectionChange.bind(this),this.selection.addEventListener("changeSelection",this.$onSelectionChange),this.onChangeMode(),this.$blockScrolling+=1,this.onCursorChange(),this.$blockScrolling-=1,this.onScrollTopChange(),this.onScrollLeftChange(),this.onSelectionChange(),this.onChangeFrontMarker(),this.onChangeBackMarker(),this.onChangeBreakpoint(),this.onChangeAnnotation(),this.session.getUseWrapMode()&&this.renderer.adjustWrapLimit(),this.renderer.updateFull()):(this.selection=null,this.renderer.setSession(e)),this._signal("changeSession",{session:e,oldSession:t}),t&&t._signal("changeEditor",{oldEditor:this}),e&&e._signal("changeEditor",{editor:this})},this.getSession=function(){return this.session},this.setValue=function(e,t){return this.session.doc.setValue(e),t?t==1?this.navigateFileEnd():t==-1&&this.navigateFileStart():this.selectAll(),e},this.getValue=function(){return this.session.getValue()},this.getSelection=function(){return this.selection},this.resize=function(e){this.renderer.onResize(e)},this.setTheme=function(e,t){this.renderer.setTheme(e,t)},this.getTheme=function(){return this.renderer.getTheme()},this.setStyle=function(e){this.renderer.setStyle(e)},this.unsetStyle=function(e){this.renderer.unsetStyle(e)},this.getFontSize=function(){return this.getOption("fontSize")||i.computedStyle(this.container,"fontSize")},this.setFontSize=function(e){this.setOption("fontSize",e)},this.$highlightBrackets=function(){this.session.$bracketHighlight&&(this.session.removeMarker(this.session.$bracketHighlight),this.session.$bracketHighlight=null);if(this.$highlightPending)return;var e=this;this.$highlightPending=!0,setTimeout(function(){e.$highlightPending=!1;var t=e.session;if(!t||!t.bgTokenizer)return;var n=t.findMatchingBracket(e.getCursorPosition());if(n)var r=new p(n.row,n.column,n.row,n.column+1);else if(t.$mode.getMatching)var r=t.$mode.getMatching(e.session);r&&(t.$bracketHighlight=t.addMarker(r,"ace_bracket","text"))},50)},this.$highlightTags=function(){if(this.$highlightTagPending)return;var e=this;this.$highlightTagPending=!0,setTimeout(function(){e.$highlightTagPending=!1;var t=e.session;if(!t||!t.bgTokenizer)return;var n=e.getCursorPosition(),r=new y(e.session,n.row,n.column),i=r.getCurrentToken();if(!i||i.type.indexOf("tag-name")===-1){t.removeMarker(t.$tagHighlight),t.$tagHighlight=null;return}var s=i.value,o=0,u=r.stepBackward();if(u.value=="<"){do u=i,i=r.stepForward(),i&&i.value===s&&i.type.indexOf("tag-name")!==-1&&(u.value==="<"?o++:u.value==="</"&&o--);while(i&&o>=0)}else{do i=u,u=r.stepBackward(),i&&i.value===s&&i.type.indexOf("tag-name")!==-1&&(u.value==="<"?o++:u.value==="</"&&o--);while(u&&o<=0);r.stepForward()}if(!i){t.removeMarker(t.$tagHighlight),t.$tagHighlight=null;return}var a=r.getCurrentTokenRow(),f=r.getCurrentTokenColumn(),l=new p(a,f,a,f+i.value.length);t.$tagHighlight&&l.compareRange(t.$backMarkers[t.$tagHighlight].range)!==0&&(t.removeMarker(t.$tagHighlight),t.$tagHighlight=null),l&&!t.$tagHighlight&&(t.$tagHighlight=t.addMarker(l,"ace_bracket","text"))},50)},this.focus=function(){var e=this;setTimeout(function(){e.textInput.focus()}),this.textInput.focus()},this.isFocused=function(){return this.textInput.isFocused()},this.blur=function(){this.textInput.blur()},this.onFocus=function(){if(this.$isFocused)return;this.$isFocused=!0,this.renderer.showCursor(),this.renderer.visualizeFocus(),this._emit("focus")},this.onBlur=function(){if(!this.$isFocused)return;this.$isFocused=!1,this.renderer.hideCursor(),this.renderer.visualizeBlur(),this._emit("blur")},this.$cursorChange=function(){this.renderer.updateCursor()},this.onDocumentChange=function(e){var t=e.data,n=t.range,r;n.start.row==n.end.row&&t.action!="insertLines"&&t.action!="removeLines"?r=n.end.row:r=Infinity,this.renderer.updateLines(n.start.row,r,this.session.$useWrapMode),this._signal("change",e),this.$cursorChange(),this.$updateHighlightActiveLine()},this.onTokenizerUpdate=function(e){var t=e.data;this.renderer.updateLines(t.first,t.last)},this.onScrollTopChange=function(){this.renderer.scrollToY(this.session.getScrollTop())},this.onScrollLeftChange=function(){this.renderer.scrollToX(this.session.getScrollLeft())},this.onCursorChange=function(){this.$cursorChange(),this.$blockScrolling||this.renderer.scrollCursorIntoView(),this.$highlightBrackets(),this.$highlightTags(),this.$updateHighlightActiveLine(),this._signal("changeSelection")},this.$updateHighlightActiveLine=function(){var e=this.getSession(),t;if(this.$highlightActiveLine){if(this.$selectionStyle!="line"||!this.selection.isMultiLine())t=this.getCursorPosition();this.renderer.$maxLines&&this.session.getLength()===1&&!(this.renderer.$minLines>1)&&(t=!1)}if(e.$highlightLineMarker&&!t)e.removeMarker(e.$highlightLineMarker.id),e.$highlightLineMarker=null;else if(!e.$highlightLineMarker&&t){var n=new p(t.row,t.column,t.row,Infinity);n.id=e.addMarker(n,"ace_active-line","screenLine"),e.$highlightLineMarker=n}else t&&(e.$highlightLineMarker.start.row=t.row,e.$highlightLineMarker.end.row=t.row,e.$highlightLineMarker.start.column=t.column,e._signal("changeBackMarker"))},this.onSelectionChange=function(e){var t=this.session;t.$selectionMarker&&t.removeMarker(t.$selectionMarker),t.$selectionMarker=null;if(!this.selection.isEmpty()){var n=this.selection.getRange(),r=this.getSelectionStyle();t.$selectionMarker=t.addMarker(n,"ace_selection",r)}else this.$updateHighlightActiveLine();var i=this.$highlightSelectedWord&&this.$getSelectionHighLightRegexp();this.session.highlight(i),this._signal("changeSelection")},this.$getSelectionHighLightRegexp=function(){var e=this.session,t=this.getSelectionRange();if(t.isEmpty()||t.isMultiLine())return;var n=t.start.column-1,r=t.end.column+1,i=e.getLine(t.start.row),s=i.length,o=i.substring(Math.max(n,0),Math.min(r,s));if(n>=0&&/^[\w\d]/.test(o)||r<=s&&/[\w\d]$/.test(o))return;o=i.substring(t.start.column,t.end.column);if(!/^[\w\d]+$/.test(o))return;var u=this.$search.$assembleRegExp({wholeWord:!0,caseSensitive:!0,needle:o});return u},this.onChangeFrontMarker=function(){this.renderer.updateFrontMarkers()},this.onChangeBackMarker=function(){this.renderer.updateBackMarkers()},this.onChangeBreakpoint=function(){this.renderer.updateBreakpoints()},this.onChangeAnnotation=function(){this.renderer.setAnnotations(this.session.getAnnotations())},this.onChangeMode=function(e){this.renderer.updateText(),this._emit("changeMode",e)},this.onChangeWrapLimit=function(){this.renderer.updateFull()},this.onChangeWrapMode=function(){this.renderer.onResize(!0)},this.onChangeFold=function(){this.$updateHighlightActiveLine(),this.renderer.updateFull()},this.getSelectedText=function(){return this.session.getTextRange(this.getSelectionRange())},this.getCopyText=function(){var e=this.getSelectedText();return this._signal("copy",e),e},this.onCopy=function(){this.commands.exec("copy",this)},this.onCut=function(){this.commands.exec("cut",this)},this.onPaste=function(e){if(this.$readOnly)return;var t={text:e};this._signal("paste",t),this.insert(t.text,!0)},this.execCommand=function(e,t){this.commands.exec(e,this,t)},this.insert=function(e,t){var n=this.session,r=n.getMode(),i=this.getCursorPosition();if(this.getBehavioursEnabled()&&!t){var s=r.transformAction(n.getState(i.row),"insertion",this,n,e);s&&(e!==s.text&&(this.session.mergeUndoDeltas=!1,this.$mergeNextCommand=!1),e=s.text)}e==" "&&(e=this.session.getTabString());if(!this.selection.isEmpty()){var o=this.getSelectionRange();i=this.session.remove(o),this.clearSelection()}else if(this.session.getOverwrite()){var o=new p.fromPoints(i,i);o.end.column+=e.length,this.session.remove(o)}if(e=="\n"||e=="\r\n"){var u=n.getLine(i.row);if(i.column>u.search(/\S|$/)){var a=u.substr(i.column).search(/\S|$/);n.doc.removeInLine(i.row,i.column,i.column+a)}}this.clearSelection();var f=i.column,l=n.getState(i.row),u=n.getLine(i.row),c=r.checkOutdent(l,u,e),h=n.insert(i,e);s&&s.selection&&(s.selection.length==2?this.selection.setSelectionRange(new p(i.row,f+s.selection[0],i.row,f+s.selection[1])):this.selection.setSelectionRange(new p(i.row+s.selection[0],s.selection[1],i.row+s.selection[2],s.selection[3])));if(n.getDocument().isNewLine(e)){var d=r.getNextLineIndent(l,u.slice(0,i.column),n.getTabString());n.insert({row:i.row+1,column:0},d)}c&&r.autoOutdent(l,n,i.row)},this.onTextInput=function(e){this.keyBinding.onTextInput(e)},this.onCommandKey=function(e,t,n){this.keyBinding.onCommandKey(e,t,n)},this.setOverwrite=function(e){this.session.setOverwrite(e)},this.getOverwrite=function(){return this.session.getOverwrite()},this.toggleOverwrite=function(){this.session.toggleOverwrite()},this.setScrollSpeed=function(e){this.setOption("scrollSpeed",e)},this.getScrollSpeed=function(){return this.getOption("scrollSpeed")},this.setDragDelay=function(e){this.setOption("dragDelay",e)},this.getDragDelay=function(){return this.getOption("dragDelay")},this.setSelectionStyle=function(e){this.setOption("selectionStyle",e)},this.getSelectionStyle=function(){return this.getOption("selectionStyle")},this.setHighlightActiveLine=function(e){this.setOption("highlightActiveLine",e)},this.getHighlightActiveLine=function(){return this.getOption("highlightActiveLine")},this.setHighlightGutterLine=function(e){this.setOption("highlightGutterLine",e)},this.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},this.setHighlightSelectedWord=function(e){this.setOption("highlightSelectedWord",e)},this.getHighlightSelectedWord=function(){return this.$highlightSelectedWord},this.setAnimatedScroll=function(e){this.renderer.setAnimatedScroll(e)},this.getAnimatedScroll=function(){return this.renderer.getAnimatedScroll()},this.setShowInvisibles=function(e){this.renderer.setShowInvisibles(e)},this.getShowInvisibles=function(){return this.renderer.getShowInvisibles()},this.setDisplayIndentGuides=function(e){this.renderer.setDisplayIndentGuides(e)},this.getDisplayIndentGuides=function(){return this.renderer.getDisplayIndentGuides()},this.setShowPrintMargin=function(e){this.renderer.setShowPrintMargin(e)},this.getShowPrintMargin=function(){return this.renderer.getShowPrintMargin()},this.setPrintMarginColumn=function(e){this.renderer.setPrintMarginColumn(e)},this.getPrintMarginColumn=function(){return this.renderer.getPrintMarginColumn()},this.setReadOnly=function(e){this.setOption("readOnly",e)},this.getReadOnly=function(){return this.getOption("readOnly")},this.setBehavioursEnabled=function(e){this.setOption("behavioursEnabled",e)},this.getBehavioursEnabled=function(){return this.getOption("behavioursEnabled")},this.setWrapBehavioursEnabled=function(e){this.setOption("wrapBehavioursEnabled",e)},this.getWrapBehavioursEnabled=function(){return this.getOption("wrapBehavioursEnabled")},this.setShowFoldWidgets=function(e){this.setOption("showFoldWidgets",e)},this.getShowFoldWidgets=function(){return this.getOption("showFoldWidgets")},this.setFadeFoldWidgets=function(e){this.setOption("fadeFoldWidgets",e)},this.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},this.remove=function(e){this.selection.isEmpty()&&(e=="left"?this.selection.selectLeft():this.selection.selectRight());var t=this.getSelectionRange();if(this.getBehavioursEnabled()){var n=this.session,r=n.getState(t.start.row),i=n.getMode().transformAction(r,"deletion",this,n,t);if(t.end.column===0){var s=n.getTextRange(t);if(s[s.length-1]=="\n"){var o=n.getLine(t.end.row);/^\s+$/.test(o)&&(t.end.column=o.length)}}i&&(t=i)}this.session.remove(t),this.clearSelection()},this.removeWordRight=function(){this.selection.isEmpty()&&this.selection.selectWordRight(),this.session.remove(this.getSelectionRange()),this.clearSelection()},this.removeWordLeft=function(){this.selection.isEmpty()&&this.selection.selectWordLeft(),this.session.remove(this.getSelectionRange()),this.clearSelection()},this.removeToLineStart=function(){this.selection.isEmpty()&&this.selection.selectLineStart(),this.session.remove(this.getSelectionRange()),this.clearSelection()},this.removeToLineEnd=function(){this.selection.isEmpty()&&this.selection.selectLineEnd();var e=this.getSelectionRange();e.start.column==e.end.column&&e.start.row==e.end.row&&(e.end.column=0,e.end.row++),this.session.remove(e),this.clearSelection()},this.splitLine=function(){this.selection.isEmpty()||(this.session.remove(this.getSelectionRange()),this.clearSelection());var e=this.getCursorPosition();this.insert("\n"),this.moveCursorToPosition(e)},this.transposeLetters=function(){if(!this.selection.isEmpty())return;var e=this.getCursorPosition(),t=e.column;if(t===0)return;var n=this.session.getLine(e.row),r,i;t<n.length?(r=n.charAt(t)+n.charAt(t-1),i=new p(e.row,t-1,e.row,t+1)):(r=n.charAt(t-1)+n.charAt(t-2),i=new p(e.row,t-2,e.row,t)),this.session.replace(i,r)},this.toLowerCase=function(){var e=this.getSelectionRange();this.selection.isEmpty()&&this.selection.selectWord();var t=this.getSelectionRange(),n=this.session.getTextRange(t);this.session.replace(t,n.toLowerCase()),this.selection.setSelectionRange(e)},this.toUpperCase=function(){var e=this.getSelectionRange();this.selection.isEmpty()&&this.selection.selectWord();var t=this.getSelectionRange(),n=this.session.getTextRange(t);this.session.replace(t,n.toUpperCase()),this.selection.setSelectionRange(e)},this.indent=function(){var e=this.session,t=this.getSelectionRange();if(t.start.row<t.end.row){var n=this.$getSelectedRows();e.indentRows(n.first,n.last," ");return}if(t.start.column<t.end.column){var r=e.getTextRange(t);if(!/^\s+$/.test(r)){var n=this.$getSelectedRows();e.indentRows(n.first,n.last," ");return}}var i=e.getLine(t.start.row),o=t.start,u=e.getTabSize(),a=e.documentToScreenColumn(o.row,o.column);if(this.session.getUseSoftTabs())var f=u-a%u,l=s.stringRepeat(" ",f);else{var f=a%u;while(i[t.start.column]==" "&&f)t.start.column--,f--;this.selection.setSelectionRange(t),l=" "}return this.insert(l)},this.blockIndent=function(){var e=this.$getSelectedRows();this.session.indentRows(e.first,e.last," ")},this.blockOutdent=function(){var e=this.session.getSelection();this.session.outdentRows(e.getRange())},this.sortLines=function(){var e=this.$getSelectedRows(),t=this.session,n=[];for(i=e.first;i<=e.last;i++)n.push(t.getLine(i));n.sort(function(e,t){return e.toLowerCase()<t.toLowerCase()?-1:e.toLowerCase()>t.toLowerCase()?1:0});var r=new p(0,0,0,0);for(var i=e.first;i<=e.last;i++){var s=t.getLine(i);r.start.row=i,r.end.row=i,r.end.column=s.length,t.replace(r,n[i-e.first])}},this.toggleCommentLines=function(){var e=this.session.getState(this.getCursorPosition().row),t=this.$getSelectedRows();this.session.getMode().toggleCommentLines(e,this.session,t.first,t.last)},this.toggleBlockComment=function(){var e=this.getCursorPosition(),t=this.session.getState(e.row),n=this.getSelectionRange();this.session.getMode().toggleBlockComment(t,this.session,n,e)},this.getNumberAt=function(e,t){var n=/[\-]?[0-9]+(?:\.[0-9]+)?/g;n.lastIndex=0;var r=this.session.getLine(e);while(n.lastIndex<t){var i=n.exec(r);if(i.index<=t&&i.index+i[0].length>=t){var s={value:i[0],start:i.index,end:i.index+i[0].length};return s}}return null},this.modifyNumber=function(e){var t=this.selection.getCursor().row,n=this.selection.getCursor().column,r=new p(t,n-1,t,n),i=this.session.getTextRange(r);if(!isNaN(parseFloat(i))&&isFinite(i)){var s=this.getNumberAt(t,n);if(s){var o=s.value.indexOf(".")>=0?s.start+s.value.indexOf(".")+1:s.end,u=s.start+s.value.length-o,a=parseFloat(s.value);a*=Math.pow(10,u),o!==s.end&&n<o?e*=Math.pow(10,s.end-n-1):e*=Math.pow(10,s.end-n),a+=e,a/=Math.pow(10,u);var f=a.toFixed(u),l=new p(t,s.start,t,s.end);this.session.replace(l,f),this.moveCursorTo(t,Math.max(s.start+1,n+f.length-s.value.length))}}},this.removeLines=function(){var e=this.$getSelectedRows(),t;e.first===0||e.last+1<this.session.getLength()?t=new p(e.first,0,e.last+1,0):t=new p(e.first-1,this.session.getLine(e.first-1).length,e.last,this.session.getLine(e.last).length),this.session.remove(t),this.clearSelection()},this.duplicateSelection=function(){var e=this.selection,t=this.session,n=e.getRange(),r=e.isBackwards();if(n.isEmpty()){var i=n.start.row;t.duplicateLines(i,i)}else{var s=r?n.start:n.end,o=t.insert(s,t.getTextRange(n),!1);n.start=s,n.end=o,e.setSelectionRange(n,r)}},this.moveLinesDown=function(){this.$moveLines(function(e,t){return this.session.moveLinesDown(e,t)})},this.moveLinesUp=function(){this.$moveLines(function(e,t){return this.session.moveLinesUp(e,t)})},this.moveText=function(e,t,n){return this.session.moveText(e,t,n)},this.copyLinesUp=function(){this.$moveLines(function(e,t){return this.session.duplicateLines(e,t),0})},this.copyLinesDown=function(){this.$moveLines(function(e,t){return this.session.duplicateLines(e,t)})},this.$moveLines=function(e){var t=this.selection;if(!t.inMultiSelectMode||this.inVirtualSelectionMode){var n=t.toOrientedRange(),r=this.$getSelectedRows(n),i=e.call(this,r.first,r.last);n.moveBy(i,0),t.fromOrientedRange(n)}else{var s=t.rangeList.ranges;t.rangeList.detach(this.session);for(var o=s.length;o--;){var u=o,r=s[o].collapseRows(),a=r.end.row,f=r.start.row;while(o--){r=s[o].collapseRows();if(!(f-r.end.row<=1))break;f=r.end.row}o++;var i=e.call(this,f,a);while(u>=o)s[u].moveBy(i,0),u--}t.fromOrientedRange(t.ranges[0]),t.rangeList.attach(this.session)}},this.$getSelectedRows=function(){var e=this.getSelectionRange().collapseRows();return{first:this.session.getRowFoldStart(e.start.row),last:this.session.getRowFoldEnd(e.end.row)}},this.onCompositionStart=function(e){this.renderer.showComposition(this.getCursorPosition())},this.onCompositionUpdate=function(e){this.renderer.setCompositionText(e)},this.onCompositionEnd=function(){this.renderer.hideComposition()},this.getFirstVisibleRow=function(){return this.renderer.getFirstVisibleRow()},this.getLastVisibleRow=function(){return this.renderer.getLastVisibleRow()},this.isRowVisible=function(e){return e>=this.getFirstVisibleRow()&&e<=this.getLastVisibleRow()},this.isRowFullyVisible=function(e){return e>=this.renderer.getFirstFullyVisibleRow()&&e<=this.renderer.getLastFullyVisibleRow()},this.$getVisibleRowCount=function(){return this.renderer.getScrollBottomRow()-this.renderer.getScrollTopRow()+1},this.$moveByPage=function(e,t){var n=this.renderer,r=this.renderer.layerConfig,i=e*Math.floor(r.height/r.lineHeight);this.$blockScrolling++,t===!0?this.selection.$moveSelection(function(){this.moveCursorBy(i,0)}):t===!1&&(this.selection.moveCursorBy(i,0),this.selection.clearSelection()),this.$blockScrolling--;var s=n.scrollTop;n.scrollBy(0,i*r.lineHeight),t!=null&&n.scrollCursorIntoView(null,.5),n.animateScrolling(s)},this.selectPageDown=function(){this.$moveByPage(1,!0)},this.selectPageUp=function(){this.$moveByPage(-1,!0)},this.gotoPageDown=function(){this.$moveByPage(1,!1)},this.gotoPageUp=function(){this.$moveByPage(-1,!1)},this.scrollPageDown=function(){this.$moveByPage(1)},this.scrollPageUp=function(){this.$moveByPage(-1)},this.scrollToRow=function(e){this.renderer.scrollToRow(e)},this.scrollToLine=function(e,t,n,r){this.renderer.scrollToLine(e,t,n,r)},this.centerSelection=function(){var e=this.getSelectionRange(),t={row:Math.floor(e.start.row+(e.end.row-e.start.row)/2),column:Math.floor(e.start.column+(e.end.column-e.start.column)/2)};this.renderer.alignCursor(t,.5)},this.getCursorPosition=function(){return this.selection.getCursor()},this.getCursorPositionScreen=function(){return this.session.documentToScreenPosition(this.getCursorPosition())},this.getSelectionRange=function(){return this.selection.getRange()},this.selectAll=function(){this.$blockScrolling+=1,this.selection.selectAll(),this.$blockScrolling-=1},this.clearSelection=function(){this.selection.clearSelection()},this.moveCursorTo=function(e,t){this.selection.moveCursorTo(e,t)},this.moveCursorToPosition=function(e){this.selection.moveCursorToPosition(e)},this.jumpToMatching=function(e,t){var n=this.getCursorPosition(),r=new y(this.session,n.row,n.column),i=r.getCurrentToken(),s=i||r.stepForward();if(!s)return;var o,u=!1,a={},f=n.column-s.start,l,c={")":"(","(":"(","]":"[","[":"[","{":"{","}":"{"};do{if(s.value.match(/[{}()\[\]]/g))for(;f<s.value.length&&!u;f++){if(!c[s.value[f]])continue;l=c[s.value[f]]+"."+s.type.replace("rparen","lparen"),isNaN(a[l])&&(a[l]=0);switch(s.value[f]){case"(":case"[":case"{":a[l]++;break;case")":case"]":case"}":a[l]--,a[l]===-1&&(o="bracket",u=!0)}}else s&&s.type.indexOf("tag-name")!==-1&&(isNaN(a[s.value])&&(a[s.value]=0),i.value==="<"?a[s.value]++:i.value==="</"&&a[s.value]--,a[s.value]===-1&&(o="tag",u=!0));u||(i=s,s=r.stepForward(),f=0)}while(s&&!u);if(!o)return;var h,d;if(o==="bracket"){h=this.session.getBracketRange(n);if(!h){h=new p(r.getCurrentTokenRow(),r.getCurrentTokenColumn()+f-1,r.getCurrentTokenRow(),r.getCurrentTokenColumn()+f-1),d=h.start;if(t||d.row===n.row&&Math.abs(d.column-n.column)<2)h=this.session.getBracketRange(d)}}else if(o==="tag"){if(!s||s.type.indexOf("tag-name")===-1)return;var v=s.value;h=new p(r.getCurrentTokenRow(),r.getCurrentTokenColumn()-2,r.getCurrentTokenRow(),r.getCurrentTokenColumn()-2);if(h.compare(n.row,n.column)===0){u=!1;do s=i,i=r.stepBackward(),i&&(i.type.indexOf("tag-close")!==-1&&h.setEnd(r.getCurrentTokenRow(),r.getCurrentTokenColumn()+1),s.value===v&&s.type.indexOf("tag-name")!==-1&&(i.value==="<"?a[v]++:i.value==="</"&&a[v]--,a[v]===0&&(u=!0)));while(i&&!u)}s&&s.type.indexOf("tag-name")&&(d=h.start,d.row==n.row&&Math.abs(d.column-n.column)<2&&(d=h.end))}d=h&&h.cursor||d,d&&(e?h&&t?this.selection.setRange(h):h&&h.isEqual(this.getSelectionRange())?this.clearSelection():this.selection.selectTo(d.row,d.column):this.selection.moveTo(d.row,d.column))},this.gotoLine=function(e,t,n){this.selection.clearSelection(),this.session.unfold({row:e-1,column:t||0}),this.$blockScrolling+=1,this.exitMultiSelectMode&&this.exitMultiSelectMode(),this.moveCursorTo(e-1,t||0),this.$blockScrolling-=1,this.isRowFullyVisible(e-1)||this.scrollToLine(e-1,!0,n)},this.navigateTo=function(e,t){this.selection.moveTo(e,t)},this.navigateUp=function(e){if(this.selection.isMultiLine()&&!this.selection.isBackwards()){var t=this.selection.anchor.getPosition();return this.moveCursorToPosition(t)}this.selection.clearSelection(),this.selection.moveCursorBy(-e||-1,0)},this.navigateDown=function(e){if(this.selection.isMultiLine()&&this.selection.isBackwards()){var t=this.selection.anchor.getPosition();return this.moveCursorToPosition(t)}this.selection.clearSelection(),this.selection.moveCursorBy(e||1,0)},this.navigateLeft=function(e){if(!this.selection.isEmpty()){var t=this.getSelectionRange().start;this.moveCursorToPosition(t)}else{e=e||1;while(e--)this.selection.moveCursorLeft()}this.clearSelection()},this.navigateRight=function(e){if(!this.selection.isEmpty()){var t=this.getSelectionRange().end;this.moveCursorToPosition(t)}else{e=e||1;while(e--)this.selection.moveCursorRight()}this.clearSelection()},this.navigateLineStart=function(){this.selection.moveCursorLineStart(),this.clearSelection()},this.navigateLineEnd=function(){this.selection.moveCursorLineEnd(),this.clearSelection()},this.navigateFileEnd=function(){this.selection.moveCursorFileEnd(),this.clearSelection()},this.navigateFileStart=function(){this.selection.moveCursorFileStart(),this.clearSelection()},this.navigateWordRight=function(){this.selection.moveCursorWordRight(),this.clearSelection()},this.navigateWordLeft=function(){this.selection.moveCursorWordLeft(),this.clearSelection()},this.replace=function(e,t){t&&this.$search.set(t);var n=this.$search.find(this.session),r=0;return n?(this.$tryReplace(n,e)&&(r=1),n!==null&&(this.selection.setSelectionRange(n),this.renderer.scrollSelectionIntoView(n.start,n.end)),r):r},this.replaceAll=function(e,t){t&&this.$search.set(t);var n=this.$search.findAll(this.session),r=0;if(!n.length)return r;this.$blockScrolling+=1;var i=this.getSelectionRange();this.selection.moveTo(0,0);for(var s=n.length-1;s>=0;--s)this.$tryReplace(n[s],e)&&r++;return this.selection.setSelectionRange(i),this.$blockScrolling-=1,r},this.$tryReplace=function(e,t){var n=this.session.getTextRange(e);return t=this.$search.replace(n,t),t!==null?(e.end=this.session.replace(e,t),e):null},this.getLastSearchOptions=function(){return this.$search.getOptions()},this.find=function(e,t,n){t||(t={}),typeof e=="string"||e instanceof RegExp?t.needle=e:typeof e=="object"&&r.mixin(t,e);var i=this.selection.getRange();t.needle==null&&(e=this.session.getTextRange(i)||this.$search.$options.needle,e||(i=this.session.getWordRange(i.start.row,i.start.column),e=this.session.getTextRange(i)),this.$search.set({needle:e})),this.$search.set(t),t.start||this.$search.set({start:i});var s=this.$search.find(this.session);if(t.preventScroll)return s;if(s)return this.revealRange(s,n),s;t.backwards?i.start=i.end:i.end=i.start,this.selection.setRange(i)},this.findNext=function(e,t){this.find({skipCurrent:!0,backwards:!1},e,t)},this.findPrevious=function(e,t){this.find(e,{skipCurrent:!0,backwards:!0},t)},this.revealRange=function(e,t){this.$blockScrolling+=1,this.session.unfold(e),this.selection.setSelectionRange(e),this.$blockScrolling-=1;var n=this.renderer.scrollTop;this.renderer.scrollSelectionIntoView(e.start,e.end,.5),t!==!1&&this.renderer.animateScrolling(n)},this.undo=function(){this.$blockScrolling++,this.session.getUndoManager().undo(),this.$blockScrolling--,this.renderer.scrollCursorIntoView(null,.5)},this.redo=function(){this.$blockScrolling++,this.session.getUndoManager().redo(),this.$blockScrolling--,this.renderer.scrollCursorIntoView(null,.5)},this.destroy=function(){this.renderer.destroy(),this._signal("destroy",this),this.session&&this.session.destroy()},this.setAutoScrollEditorIntoView=function(e){if(!e)return;var t,n=this,r=!1;this.$scrollAnchor||(this.$scrollAnchor=document.createElement("div"));var i=this.$scrollAnchor;i.style.cssText="position:absolute",this.container.insertBefore(i,this.container.firstChild);var s=this.on("changeSelection",function(){r=!0}),o=this.renderer.on("beforeRender",function(){r&&(t=n.renderer.container.getBoundingClientRect())}),u=this.renderer.on("afterRender",function(){if(r&&t&&n.isFocused()){var e=n.renderer,s=e.$cursorLayer.$pixelPos,o=e.layerConfig,u=s.top-o.offset;s.top>=0&&u+t.top<0?r=!0:s.top<o.height&&s.top+t.top+o.lineHeight>window.innerHeight?r=!1:r=null,r!=null&&(i.style.top=u+"px",i.style.left=s.left+"px",i.style.height=o.lineHeight+"px",i.scrollIntoView(r)),r=t=null}});this.setAutoScrollEditorIntoView=function(e){if(e)return;delete this.setAutoScrollEditorIntoView,this.removeEventListener("changeSelection",s),this.renderer.removeEventListener("afterRender",u),this.renderer.removeEventListener("beforeRender",o)}},this.$resetCursorStyle=function(){var e=this.$cursorStyle||"ace",t=this.renderer.$cursorLayer;if(!t)return;t.setSmoothBlinking(/smooth/.test(e)),t.isBlinking=!this.$readOnly&&e!="wide",i.setCssClass(t.element,"ace_slim-cursors",/slim/.test(e))}}).call(b.prototype),g.defineOptions(b.prototype,"editor",{selectionStyle:{set:function(e){this.onSelectionChange(),this._signal("changeSelectionStyle",{data:e})},initialValue:"line"},highlightActiveLine:{set:function(){this.$updateHighlightActiveLine()},initialValue:!0},highlightSelectedWord:{set:function(e){this.$onSelectionChange()},initialValue:!0},readOnly:{set:function(e){this.$resetCursorStyle()},initialValue:!1},cursorStyle:{set:function(e){this.$resetCursorStyle()},values:["ace","slim","smooth","wide"],initialValue:"ace"},mergeUndoDeltas:{values:[!1,!0,"always"],initialValue:!0},behavioursEnabled:{initialValue:!0},wrapBehavioursEnabled:{initialValue:!0},autoScrollEditorIntoView:{set:function(e){this.setAutoScrollEditorIntoView(e)}},hScrollBarAlwaysVisible:"renderer",vScrollBarAlwaysVisible:"renderer",highlightGutterLine:"renderer",animatedScroll:"renderer",showInvisibles:"renderer",showPrintMargin:"renderer",printMarginColumn:"renderer",printMargin:"renderer",fadeFoldWidgets:"renderer",showFoldWidgets:"renderer",showLineNumbers:"renderer",showGutter:"renderer",displayIndentGuides:"renderer",fontSize:"renderer",fontFamily:"renderer",maxLines:"renderer",minLines:"renderer",scrollPastEnd:"renderer",fixedWidthGutter:"renderer",theme:"renderer",scrollSpeed:"$mouseHandler",dragDelay:"$mouseHandler",dragEnabled:"$mouseHandler",focusTimout:"$mouseHandler",tooltipFollowsMouse:"$mouseHandler",firstLineNumber:"session",overwrite:"session",newLineMode:"session",useWorker:"session",useSoftTabs:"session",tabSize:"session",wrap:"session",foldStyle:"session",mode:"session"}),t.Editor=b}),ace.define("ace/undomanager",["require","exports","module"],function(e,t,n){"use strict";var r=function(){this.reset()};(function(){this.execute=function(e){var t=e.args[0];this.$doc=e.args[1],e.merge&&this.hasUndo()&&(this.dirtyCounter--,t=this.$undoStack.pop().concat(t)),this.$undoStack.push(t),this.$redoStack=[],this.dirtyCounter<0&&(this.dirtyCounter=NaN),this.dirtyCounter++},this.undo=function(e){var t=this.$undoStack.pop(),n=null;return t&&(n=this.$doc.undoChanges(t,e),this.$redoStack.push(t),this.dirtyCounter--),n},this.redo=function(e){var t=this.$redoStack.pop(),n=null;return t&&(n=this.$doc.redoChanges(t,e),this.$undoStack.push(t),this.dirtyCounter++),n},this.reset=function(){this.$undoStack=[],this.$redoStack=[],this.dirtyCounter=0},this.hasUndo=function(){return this.$undoStack.length>0},this.hasRedo=function(){return this.$redoStack.length>0},this.markClean=function(){this.dirtyCounter=0},this.isClean=function(){return this.dirtyCounter===0}}).call(r.prototype),t.UndoManager=r}),ace.define("ace/layer/gutter",["require","exports","module","ace/lib/dom","ace/lib/oop","ace/lib/lang","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("../lib/dom"),i=e("../lib/oop"),s=e("../lib/lang"),o=e("../lib/event_emitter").EventEmitter,u=function(e){this.element=r.createElement("div"),this.element.className="ace_layer ace_gutter-layer",e.appendChild(this.element),this.setShowFoldWidgets(this.$showFoldWidgets),this.gutterWidth=0,this.$annotations=[],this.$updateAnnotations=this.$updateAnnotations.bind(this),this.$cells=[]};(function(){i.implement(this,o),this.setSession=function(e){this.session&&this.session.removeEventListener("change",this.$updateAnnotations),this.session=e,e&&e.on("change",this.$updateAnnotations)},this.addGutterDecoration=function(e,t){window.console&&console.warn&&console.warn("deprecated use session.addGutterDecoration"),this.session.addGutterDecoration(e,t)},this.removeGutterDecoration=function(e,t){window.console&&console.warn&&console.warn("deprecated use session.removeGutterDecoration"),this.session.removeGutterDecoration(e,t)},this.setAnnotations=function(e){this.$annotations=[];for(var t=0;t<e.length;t++){var n=e[t],r=n.row,i=this.$annotations[r];i||(i=this.$annotations[r]={text:[]});var o=n.text;o=o?s.escapeHTML(o):n.html||"",i.text.indexOf(o)===-1&&i.text.push(o);var u=n.type;u=="error"?i.className=" ace_error":u=="warning"&&i.className!=" ace_error"?i.className=" ace_warning":u=="info"&&!i.className&&(i.className=" ace_info")}},this.$updateAnnotations=function(e){if(!this.$annotations.length)return;var t=e.data,n=t.range,r=n.start.row,i=n.end.row-r;if(i!==0)if(t.action=="removeText"||t.action=="removeLines")this.$annotations.splice(r,i+1,null);else{var s=new Array(i+1);s.unshift(r,1),this.$annotations.splice.apply(this.$annotations,s)}},this.update=function(e){var t=this.session,n=e.firstRow,i=Math.min(e.lastRow+e.gutterOffset,t.getLength()-1),s=t.getNextFoldLine(n),o=s?s.start.row:Infinity,u=this.$showFoldWidgets&&t.foldWidgets,a=t.$breakpoints,f=t.$decorations,l=t.$firstLineNumber,c=0,h=t.gutterRenderer||this.$renderer,p=null,d=-1,v=n;for(;;){v>o&&(v=s.end.row+1,s=t.getNextFoldLine(v,s),o=s?s.start.row:Infinity);if(v>i){while(this.$cells.length>d+1)p=this.$cells.pop(),this.element.removeChild(p.element);break}p=this.$cells[++d],p||(p={element:null,textNode:null,foldWidget:null},p.element=r.createElement("div"),p.textNode=document.createTextNode(""),p.element.appendChild(p.textNode),this.element.appendChild(p.element),this.$cells[d]=p);var m="ace_gutter-cell ";a[v]&&(m+=a[v]),f[v]&&(m+=f[v]),this.$annotations[v]&&(m+=this.$annotations[v].className),p.element.className!=m&&(p.element.className=m);var g=t.getRowLength(v)*e.lineHeight+"px";g!=p.element.style.height&&(p.element.style.height=g);if(u){var y=u[v];y==null&&(y=u[v]=t.getFoldWidget(v))}if(y){p.foldWidget||(p.foldWidget=r.createElement("span"),p.element.appendChild(p.foldWidget));var m="ace_fold-widget ace_"+y;y=="start"&&v==o&&v<s.end.row?m+=" ace_closed":m+=" ace_open",p.foldWidget.className!=m&&(p.foldWidget.className=m);var g=e.lineHeight+"px";p.foldWidget.style.height!=g&&(p.foldWidget.style.height=g)}else p.foldWidget&&(p.element.removeChild(p.foldWidget),p.foldWidget=null);var b=c=h?h.getText(t,v):v+l;b!=p.textNode.data&&(p.textNode.data=b),v++}this.element.style.height=e.minHeight+"px";if(this.$fixedWidth||t.$useWrapMode)c=t.getLength()+l;var w=h?h.getWidth(t,c,e):c.toString().length*e.characterWidth,E=this.$padding||this.$computePadding();w+=E.left+E.right,w!==this.gutterWidth&&!isNaN(w)&&(this.gutterWidth=w,this.element.style.width=Math.ceil(this.gutterWidth)+"px",this._emit("changeGutterWidth",w))},this.$fixedWidth=!1,this.$showLineNumbers=!0,this.$renderer="",this.setShowLineNumbers=function(e){this.$renderer=!e&&{getWidth:function(){return""},getText:function(){return""}}},this.getShowLineNumbers=function(){return this.$showLineNumbers},this.$showFoldWidgets=!0,this.setShowFoldWidgets=function(e){e?r.addCssClass(this.element,"ace_folding-enabled"):r.removeCssClass(this.element,"ace_folding-enabled"),this.$showFoldWidgets=e,this.$padding=null},this.getShowFoldWidgets=function(){return this.$showFoldWidgets},this.$computePadding=function(){if(!this.element.firstChild)return{left:0,right:0};var e=r.computedStyle(this.element.firstChild);return this.$padding={},this.$padding.left=parseInt(e.paddingLeft)+1||0,this.$padding.right=parseInt(e.paddingRight)||0,this.$padding},this.getRegion=function(e){var t=this.$padding||this.$computePadding(),n=this.element.getBoundingClientRect();if(e.x<t.left+n.left)return"markers";if(this.$showFoldWidgets&&e.x>n.right-t.right)return"foldWidgets"}}).call(u.prototype),t.Gutter=u}),ace.define("ace/layer/marker",["require","exports","module","ace/range","ace/lib/dom"],function(e,t,n){"use strict";var r=e("../range").Range,i=e("../lib/dom"),s=function(e){this.element=i.createElement("div"),this.element.className="ace_layer ace_marker-layer",e.appendChild(this.element)};(function(){this.$padding=0,this.setPadding=function(e){this.$padding=e},this.setSession=function(e){this.session=e},this.setMarkers=function(e){this.markers=e},this.update=function(e){var e=e||this.config;if(!e)return;this.config=e;var t=[];for(var n in this.markers){var r=this.markers[n];if(!r.range){r.update(t,this,this.session,e);continue}var i=r.range.clipRows(e.firstRow,e.lastRow);if(i.isEmpty())continue;i=i.toScreenRange(this.session);if(r.renderer){var s=this.$getTop(i.start.row,e),o=this.$padding+i.start.column*e.characterWidth;r.renderer(t,i,o,s,e)}else r.type=="fullLine"?this.drawFullLineMarker(t,i,r.clazz,e):r.type=="screenLine"?this.drawScreenLineMarker(t,i,r.clazz,e):i.isMultiLine()?r.type=="text"?this.drawTextMarker(t,i,r.clazz,e):this.drawMultiLineMarker(t,i,r.clazz,e):this.drawSingleLineMarker(t,i,r.clazz+" ace_start",e)}this.element.innerHTML=t.join("")},this.$getTop=function(e,t){return(e-t.firstRowScreen)*t.lineHeight},this.drawTextMarker=function(e,t,n,i,s){var o=t.start.row,u=new r(o,t.start.column,o,this.session.getScreenLastRowColumn(o));this.drawSingleLineMarker(e,u,n+" ace_start",i,1,s),o=t.end.row,u=new r(o,0,o,t.end.column),this.drawSingleLineMarker(e,u,n,i,0,s);for(o=t.start.row+1;o<t.end.row;o++)u.start.row=o,u.end.row=o,u.end.column=this.session.getScreenLastRowColumn(o),this.drawSingleLineMarker(e,u,n,i,1,s)},this.drawMultiLineMarker=function(e,t,n,r,i){var s=this.$padding,o=r.lineHeight,u=this.$getTop(t.start.row,r),a=s+t.start.column*r.characterWidth;i=i||"",e.push("<div class='",n," ace_start' style='","height:",o,"px;","right:0;","top:",u,"px;","left:",a,"px;",i,"'></div>"),u=this.$getTop(t.end.row,r);var f=t.end.column*r.characterWidth;e.push("<div class='",n,"' style='","height:",o,"px;","width:",f,"px;","top:",u,"px;","left:",s,"px;",i,"'></div>"),o=(t.end.row-t.start.row-1)*r.lineHeight;if(o<0)return;u=this.$getTop(t.start.row+1,r),e.push("<div class='",n,"' style='","height:",o,"px;","right:0;","top:",u,"px;","left:",s,"px;",i,"'></div>")},this.drawSingleLineMarker=function(e,t,n,r,i,s){var o=r.lineHeight,u=(t.end.column+(i||0)-t.start.column)*r.characterWidth,a=this.$getTop(t.start.row,r),f=this.$padding+t.start.column*r.characterWidth;e.push("<div class='",n,"' style='","height:",o,"px;","width:",u,"px;","top:",a,"px;","left:",f,"px;",s||"","'></div>")},this.drawFullLineMarker=function(e,t,n,r,i){var s=this.$getTop(t.start.row,r),o=r.lineHeight;t.start.row!=t.end.row&&(o+=this.$getTop(t.end.row,r)-s),e.push("<div class='",n,"' style='","height:",o,"px;","top:",s,"px;","left:0;right:0;",i||"","'></div>")},this.drawScreenLineMarker=function(e,t,n,r,i){var s=this.$getTop(t.start.row,r),o=r.lineHeight;e.push("<div class='",n,"' style='","height:",o,"px;","top:",s,"px;","left:0;right:0;",i||"","'></div>")}}).call(s.prototype),t.Marker=s}),ace.define("ace/layer/text",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/lib/useragent","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("../lib/oop"),i=e("../lib/dom"),s=e("../lib/lang"),o=e("../lib/useragent"),u=e("../lib/event_emitter").EventEmitter,a=function(e){this.element=i.createElement("div"),this.element.className="ace_layer ace_text-layer",e.appendChild(this.element),this.$updateEolChar=this.$updateEolChar.bind(this)};(function(){r.implement(this,u),this.EOF_CHAR="\u00b6",this.EOL_CHAR_LF="\u00ac",this.EOL_CHAR_CRLF="\u00a4",this.EOL_CHAR=this.EOL_CHAR_LF,this.TAB_CHAR="\u2192",this.SPACE_CHAR="\u00b7",this.$padding=0,this.$updateEolChar=function(){var e=this.session.doc.getNewLineCharacter()=="\n"?this.EOL_CHAR_LF:this.EOL_CHAR_CRLF;if(this.EOL_CHAR!=e)return this.EOL_CHAR=e,!0},this.setPadding=function(e){this.$padding=e,this.element.style.padding="0 "+e+"px"},this.getLineHeight=function(){return this.$fontMetrics.$characterSize.height||0},this.getCharacterWidth=function(){return this.$fontMetrics.$characterSize.width||0},this.$setFontMetrics=function(e){this.$fontMetrics=e,this.$fontMetrics.on("changeCharacterSize",function(e){this._signal("changeCharacterSize",e)}.bind(this)),this.$pollSizeChanges()},this.checkForSizeChanges=function(){this.$fontMetrics.checkForSizeChanges()},this.$pollSizeChanges=function(){return this.$pollSizeChangesTimer=this.$fontMetrics.$pollSizeChanges()},this.setSession=function(e){this.session=e,e&&this.$computeTabString()},this.showInvisibles=!1,this.setShowInvisibles=function(e){return this.showInvisibles==e?!1:(this.showInvisibles=e,this.$computeTabString(),!0)},this.displayIndentGuides=!0,this.setDisplayIndentGuides=function(e){return this.displayIndentGuides==e?!1:(this.displayIndentGuides=e,this.$computeTabString(),!0)},this.$tabStrings=[],this.onChangeTabSize=this.$computeTabString=function(){var e=this.session.getTabSize();this.tabSize=e;var t=this.$tabStrings=[0];for(var n=1;n<e+1;n++)this.showInvisibles?t.push("<span class='ace_invisible ace_invisible_tab'>"+this.TAB_CHAR+s.stringRepeat("\u00a0",n-1)+"</span>"):t.push(s.stringRepeat("\u00a0",n));if(this.displayIndentGuides){this.$indentGuideRe=/\s\S| \t|\t |\s$/;var r="ace_indent-guide",i="",o="";if(this.showInvisibles){r+=" ace_invisible",i=" ace_invisible_space",o=" ace_invisible_tab";var u=s.stringRepeat(this.SPACE_CHAR,this.tabSize),a=this.TAB_CHAR+s.stringRepeat("\u00a0",this.tabSize-1)}else var u=s.stringRepeat("\u00a0",this.tabSize),a=u;this.$tabStrings[" "]="<span class='"+r+i+"'>"+u+"</span>",this.$tabStrings[" "]="<span class='"+r+o+"'>"+a+"</span>"}},this.updateLines=function(e,t,n){(this.config.lastRow!=e.lastRow||this.config.firstRow!=e.firstRow)&&this.scrollLines(e),this.config=e;var r=Math.max(t,e.firstRow),i=Math.min(n,e.lastRow),s=this.element.childNodes,o=0;for(var u=e.firstRow;u<r;u++){var a=this.session.getFoldLine(u);if(a){if(a.containsRow(r)){r=a.start.row;break}u=a.end.row}o++}var u=r,a=this.session.getNextFoldLine(u),f=a?a.start.row:Infinity;for(;;){u>f&&(u=a.end.row+1,a=this.session.getNextFoldLine(u,a),f=a?a.start.row:Infinity);if(u>i)break;var l=s[o++];if(l){var c=[];this.$renderLine(c,u,!this.$useLineGroups(),u==f?a:!1),l.style.height=e.lineHeight*this.session.getRowLength(u)+"px",l.innerHTML=c.join("")}u++}},this.scrollLines=function(e){var t=this.config;this.config=e;if(!t||t.lastRow<e.firstRow)return this.update(e);if(e.lastRow<t.firstRow)return this.update(e);var n=this.element;if(t.firstRow<e.firstRow)for(var r=this.session.getFoldedRowCount(t.firstRow,e.firstRow-1);r>0;r--)n.removeChild(n.firstChild);if(t.lastRow>e.lastRow)for(var r=this.session.getFoldedRowCount(e.lastRow+1,t.lastRow);r>0;r--)n.removeChild(n.lastChild);if(e.firstRow<t.firstRow){var i=this.$renderLinesFragment(e,e.firstRow,t.firstRow-1);n.firstChild?n.insertBefore(i,n.firstChild):n.appendChild(i)}if(e.lastRow>t.lastRow){var i=this.$renderLinesFragment(e,t.lastRow+1,e.lastRow);n.appendChild(i)}},this.$renderLinesFragment=function(e,t,n){var r=this.element.ownerDocument.createDocumentFragment(),s=t,o=this.session.getNextFoldLine(s),u=o?o.start.row:Infinity;for(;;){s>u&&(s=o.end.row+1,o=this.session.getNextFoldLine(s,o),u=o?o.start.row:Infinity);if(s>n)break;var a=i.createElement("div"),f=[];this.$renderLine(f,s,!1,s==u?o:!1),a.innerHTML=f.join("");if(this.$useLineGroups())a.className="ace_line_group",r.appendChild(a),a.style.height=e.lineHeight*this.session.getRowLength(s)+"px";else while(a.firstChild)r.appendChild(a.firstChild);s++}return r},this.update=function(e){this.config=e;var t=[],n=e.firstRow,r=e.lastRow,i=n,s=this.session.getNextFoldLine(i),o=s?s.start.row:Infinity;for(;;){i>o&&(i=s.end.row+1,s=this.session.getNextFoldLine(i,s),o=s?s.start.row:Infinity);if(i>r)break;this.$useLineGroups()&&t.push("<div class='ace_line_group' style='height:",e.lineHeight*this.session.getRowLength(i),"px'>"),this.$renderLine(t,i,!1,i==o?s:!1),this.$useLineGroups()&&t.push("</div>"),i++}this.element.innerHTML=t.join("")},this.$textToken={text:!0,rparen:!0,lparen:!0},this.$renderToken=function(e,t,n,r){var i=this,o=/\t|&|<|( +)|([\x00-\x1f\x80-\xa0\u1680\u180E\u2000-\u200f\u2028\u2029\u202F\u205F\u3000\uFEFF])|[\u1100-\u115F\u11A3-\u11A7\u11FA-\u11FF\u2329-\u232A\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u2FFB\u3000-\u303E\u3041-\u3096\u3099-\u30FF\u3105-\u312D\u3131-\u318E\u3190-\u31BA\u31C0-\u31E3\u31F0-\u321E\u3220-\u3247\u3250-\u32FE\u3300-\u4DBF\u4E00-\uA48C\uA490-\uA4C6\uA960-\uA97C\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFAFF\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE66\uFE68-\uFE6B\uFF01-\uFF60\uFFE0-\uFFE6]/g,u=function(e,n,r,o,u){if(n)return i.showInvisibles?"<span class='ace_invisible ace_invisible_space'>"+s.stringRepeat(i.SPACE_CHAR,e.length)+"</span>":s.stringRepeat("\u00a0",e.length);if(e=="&")return"&";if(e=="<")return"<";if(e==" "){var a=i.session.getScreenTabSize(t+o);return t+=a-1,i.$tabStrings[a]}if(e=="\u3000"){var f=i.showInvisibles?"ace_cjk ace_invisible ace_invisible_space":"ace_cjk",l=i.showInvisibles?i.SPACE_CHAR:"";return t+=1,"<span class='"+f+"' style='width:"+i.config.characterWidth*2+"px'>"+l+"</span>"}return r?"<span class='ace_invisible ace_invisible_space ace_invalid'>"+i.SPACE_CHAR+"</span>":(t+=1,"<span class='ace_cjk' style='width:"+i.config.characterWidth*2+"px'>"+e+"</span>")},a=r.replace(o,u);if(!this.$textToken[n.type]){var f="ace_"+n.type.replace(/\./g," ace_"),l="";n.type=="fold"&&(l=" style='width:"+n.value.length*this.config.characterWidth+"px;' "),e.push("<span class='",f,"'",l,">",a,"</span>")}else e.push(a);return t+r.length},this.renderIndentGuide=function(e,t,n){var r=t.search(this.$indentGuideRe);return r<=0||r>=n?t:t[0]==" "?(r-=r%this.tabSize,e.push(s.stringRepeat(this.$tabStrings[" "],r/this.tabSize)),t.substr(r)):t[0]==" "?(e.push(s.stringRepeat(this.$tabStrings[" "],r)),t.substr(r)):t},this.$renderWrappedLine=function(e,t,n,r){var i=0,s=0,o=n[0],u=0;for(var a=0;a<t.length;a++){var f=t[a],l=f.value;if(a==0&&this.displayIndentGuides){i=l.length,l=this.renderIndentGuide(e,l,o);if(!l)continue;i-=l.length}if(i+l.length<o)u=this.$renderToken(e,u,f,l),i+=l.length;else{while(i+l.length>=o)u=this.$renderToken(e,u,f,l.substring(0,o-i)),l=l.substring(o-i),i=o,r||e.push("</div>","<div class='ace_line' style='height:",this.config.lineHeight,"px'>"),s++,u=0,o=n[s]||Number.MAX_VALUE;l.length!=0&&(i+=l.length,u=this.$renderToken(e,u,f,l))}}},this.$renderSimpleLine=function(e,t){var n=0,r=t[0],i=r.value;this.displayIndentGuides&&(i=this.renderIndentGuide(e,i)),i&&(n=this.$renderToken(e,n,r,i));for(var s=1;s<t.length;s++)r=t[s],i=r.value,n=this.$renderToken(e,n,r,i)},this.$renderLine=function(e,t,n,r){!r&&r!=0&&(r=this.session.getFoldLine(t));if(r)var i=this.$getFoldLineTokens(t,r);else var i=this.session.getTokens(t);n||e.push("<div class='ace_line' style='height:",this.config.lineHeight*(this.$useLineGroups()?1:this.session.getRowLength(t)),"px'>");if(i.length){var s=this.session.getRowSplitData(t);s&&s.length?this.$renderWrappedLine(e,i,s,n):this.$renderSimpleLine(e,i)}this.showInvisibles&&(r&&(t=r.end.row),e.push("<span class='ace_invisible ace_invisible_eol'>",t==this.session.getLength()-1?this.EOF_CHAR:this.EOL_CHAR,"</span>")),n||e.push("</div>")},this.$getFoldLineTokens=function(e,t){function i(e,t,n){var i=0,s=0;while(s+e[i].value.length<t){s+=e[i].value.length,i++;if(i==e.length)return}if(s!=t){var o=e[i].value.substring(t-s);o.length>n-t&&(o=o.substring(0,n-t)),r.push({type:e[i].type,value:o}),s=t+o.length,i+=1}while(s<n&&i<e.length){var o=e[i].value;o.length+s>n?r.push({type:e[i].type,value:o.substring(0,n-s)}):r.push(e[i]),s+=o.length,i+=1}}var n=this.session,r=[],s=n.getTokens(e);return t.walk(function(e,t,o,u,a){e!=null?r.push({type:"fold",value:e}):(a&&(s=n.getTokens(t)),s.length&&i(s,u,o))},t.end.row,this.session.getLine(t.end.row).length),r},this.$useLineGroups=function(){return this.session.getUseWrapMode()},this.destroy=function(){clearInterval(this.$pollSizeChangesTimer),this.$measureNode&&this.$measureNode.parentNode.removeChild(this.$measureNode),delete this.$measureNode}}).call(a.prototype),t.Text=a}),ace.define("ace/layer/cursor",["require","exports","module","ace/lib/dom"],function(e,t,n){"use strict";var r=e("../lib/dom"),i,s=function(e){this.element=r.createElement("div"),this.element.className="ace_layer ace_cursor-layer",e.appendChild(this.element),i===undefined&&(i="opacity"in this.element),this.isVisible=!1,this.isBlinking=!0,this.blinkInterval=1e3,this.smoothBlinking=!1,this.cursors=[],this.cursor=this.addCursor(),r.addCssClass(this.element,"ace_hidden-cursors"),this.$updateCursors=this.$updateVisibility.bind(this)};(function(){this.$updateVisibility=function(e){var t=this.cursors;for(var n=t.length;n--;)t[n].style.visibility=e?"":"hidden"},this.$updateOpacity=function(e){var t=this.cursors;for(var n=t.length;n--;)t[n].style.opacity=e?"":"0"},this.$padding=0,this.setPadding=function(e){this.$padding=e},this.setSession=function(e){this.session=e},this.setBlinking=function(e){e!=this.isBlinking&&(this.isBlinking=e,this.restartTimer())},this.setBlinkInterval=function(e){e!=this.blinkInterval&&(this.blinkInterval=e,this.restartTimer())},this.setSmoothBlinking=function(e){e!=this.smoothBlinking&&!i&&(this.smoothBlinking=e,r.setCssClass(this.element,"ace_smooth-blinking",e),this.$updateCursors(!0),this.$updateCursors=(e?this.$updateOpacity:this.$updateVisibility).bind(this),this.restartTimer())},this.addCursor=function(){var e=r.createElement("div");return e.className="ace_cursor",this.element.appendChild(e),this.cursors.push(e),e},this.removeCursor=function(){if(this.cursors.length>1){var e=this.cursors.pop();return e.parentNode.removeChild(e),e}},this.hideCursor=function(){this.isVisible=!1,r.addCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},this.showCursor=function(){this.isVisible=!0,r.removeCssClass(this.element,"ace_hidden-cursors"),this.restartTimer()},this.restartTimer=function(){var e=this.$updateCursors;clearInterval(this.intervalId),clearTimeout(this.timeoutId),this.smoothBlinking&&r.removeCssClass(this.element,"ace_smooth-blinking"),e(!0);if(!this.isBlinking||!this.blinkInterval||!this.isVisible)return;this.smoothBlinking&&setTimeout(function(){r.addCssClass(this.element,"ace_smooth-blinking")}.bind(this));var t=function(){this.timeoutId=setTimeout(function(){e(!1)},.6*this.blinkInterval)}.bind(this);this.intervalId=setInterval(function(){e(!0),t()},this.blinkInterval),t()},this.getPixelPosition=function(e,t){if(!this.config||!this.session)return{left:0,top:0};e||(e=this.session.selection.getCursor());var n=this.session.documentToScreenPosition(e),r=this.$padding+n.column*this.config.characterWidth,i=(n.row-(t?this.config.firstRowScreen:0))*this.config.lineHeight;return{left:r,top:i}},this.update=function(e){this.config=e;var t=this.session.$selectionMarkers,n=0,r=0;if(t===undefined||t.length===0)t=[{cursor:null}];for(var n=0,i=t.length;n<i;n++){var s=this.getPixelPosition(t[n].cursor,!0);if((s.top>e.height+e.offset||s.top<0)&&n>1)continue;var o=(this.cursors[r++]||this.addCursor()).style;o.left=s.left+"px",o.top=s.top+"px",o.width=e.characterWidth+"px",o.height=e.lineHeight+"px"}while(this.cursors.length>r)this.removeCursor();var u=this.session.getOverwrite();this.$setOverwrite(u),this.$pixelPos=s,this.restartTimer()},this.$setOverwrite=function(e){e!=this.overwrite&&(this.overwrite=e,e?r.addCssClass(this.element,"ace_overwrite-cursors"):r.removeCssClass(this.element,"ace_overwrite-cursors"))},this.destroy=function(){clearInterval(this.intervalId),clearTimeout(this.timeoutId)}}).call(s.prototype),t.Cursor=s}),ace.define("ace/scrollbar",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/event","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/dom"),s=e("./lib/event"),o=e("./lib/event_emitter").EventEmitter,u=function(e){this.element=i.createElement("div"),this.element.className="ace_scrollbar ace_scrollbar"+this.classSuffix,this.inner=i.createElement("div"),this.inner.className="ace_scrollbar-inner",this.element.appendChild(this.inner),e.appendChild(this.element),this.setVisible(!1),this.skipEvent=!1,s.addListener(this.element,"scroll",this.onScroll.bind(this)),s.addListener(this.element,"mousedown",s.preventDefault)};(function(){r.implement(this,o),this.setVisible=function(e){this.element.style.display=e?"":"none",this.isVisible=e}}).call(u.prototype);var a=function(e,t){u.call(this,e),this.scrollTop=0,t.$scrollbarWidth=this.width=i.scrollbarWidth(e.ownerDocument),this.inner.style.width=this.element.style.width=(this.width||15)+5+"px"};r.inherits(a,u),function(){this.classSuffix="-v",this.onScroll=function(){this.skipEvent||(this.scrollTop=this.element.scrollTop,this._emit("scroll",{data:this.scrollTop})),this.skipEvent=!1},this.getWidth=function(){return this.isVisible?this.width:0},this.setHeight=function(e){this.element.style.height=e+"px"},this.setInnerHeight=function(e){this.inner.style.height=e+"px"},this.setScrollHeight=function(e){this.inner.style.height=e+"px"},this.setScrollTop=function(e){this.scrollTop!=e&&(this.skipEvent=!0,this.scrollTop=this.element.scrollTop=e)}}.call(a.prototype);var f=function(e,t){u.call(this,e),this.scrollLeft=0,this.height=t.$scrollbarWidth,this.inner.style.height=this.element.style.height=(this.height||15)+5+"px"};r.inherits(f,u),function(){this.classSuffix="-h",this.onScroll=function(){this.skipEvent||(this.scrollLeft=this.element.scrollLeft,this._emit("scroll",{data:this.scrollLeft})),this.skipEvent=!1},this.getHeight=function(){return this.isVisible?this.height:0},this.setWidth=function(e){this.element.style.width=e+"px"},this.setInnerWidth=function(e){this.inner.style.width=e+"px"},this.setScrollWidth=function(e){this.inner.style.width=e+"px"},this.setScrollLeft=function(e){this.scrollLeft!=e&&(this.skipEvent=!0,this.scrollLeft=this.element.scrollLeft=e)}}.call(f.prototype),t.ScrollBar=a,t.ScrollBarV=a,t.ScrollBarH=f,t.VScrollBar=a,t.HScrollBar=f}),ace.define("ace/renderloop",["require","exports","module","ace/lib/event"],function(e,t,n){"use strict";var r=e("./lib/event"),i=function(e,t){this.onRender=e,this.pending=!1,this.changes=0,this.window=t||window};(function(){this.schedule=function(e){this.changes=this.changes|e;if(!this.pending&&this.changes){this.pending=!0;var t=this;r.nextFrame(function(){t.pending=!1;var e;while(e=t.changes)t.changes=0,t.onRender(e)},this.window)}}}).call(i.prototype),t.RenderLoop=i}),ace.define("ace/layer/font_metrics",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/lib/lang","ace/lib/useragent","ace/lib/event_emitter"],function(e,t,n){var r=e("../lib/oop"),i=e("../lib/dom"),s=e("../lib/lang"),o=e("../lib/useragent"),u=e("../lib/event_emitter").EventEmitter,a=0,f=t.FontMetrics=function(e,t){this.el=i.createElement("div"),this.$setMeasureNodeStyles(this.el.style,!0),this.$main=i.createElement("div"),this.$setMeasureNodeStyles(this.$main.style),this.$measureNode=i.createElement("div"),this.$setMeasureNodeStyles(this.$measureNode.style),this.el.appendChild(this.$main),this.el.appendChild(this.$measureNode),e.appendChild(this.el),a||this.$testFractionalRect(),this.$measureNode.innerHTML=s.stringRepeat("X",a),this.$characterSize={width:0,height:0},this.checkForSizeChanges()};(function(){r.implement(this,u),this.$characterSize={width:0,height:0},this.$testFractionalRect=function(){var e=i.createElement("div");this.$setMeasureNodeStyles(e.style),e.style.width="0.2px",document.documentElement.appendChild(e);var t=e.getBoundingClientRect().width;t>0&&t<1?a=1:a=100,e.parentNode.removeChild(e)},this.$setMeasureNodeStyles=function(e,t){e.width=e.height="auto",e.left=e.top="-100px",e.visibility="hidden",e.position="fixed",e.whiteSpace="pre",o.isIE<8?e["font-family"]="inherit":e.font="inherit",e.overflow=t?"hidden":"visible"},this.checkForSizeChanges=function(){var e=this.$measureSizes();if(e&&(this.$characterSize.width!==e.width||this.$characterSize.height!==e.height)){this.$measureNode.style.fontWeight="bold";var t=this.$measureSizes();this.$measureNode.style.fontWeight="",this.$characterSize=e,this.charSizes=Object.create(null),this.allowBoldFonts=t&&t.width===e.width&&t.height===e.height,this._emit("changeCharacterSize",{data:e})}},this.$pollSizeChanges=function(){if(this.$pollSizeChangesTimer)return this.$pollSizeChangesTimer;var e=this;return this.$pollSizeChangesTimer=setInterval(function(){e.checkForSizeChanges()},500)},this.setPolling=function(e){e?this.$pollSizeChanges():this.$pollSizeChangesTimer&&this.$pollSizeChangesTimer},this.$measureSizes=function(){if(a===1){var e=null;try{e=this.$measureNode.getBoundingClientRect()}catch(t){e={width:0,height:0}}var n={height:e.height,width:e.width}}else var n={height:this.$measureNode.clientHeight,width:this.$measureNode.clientWidth/a};return n.width===0||n.height===0?null:n},this.$measureCharWidth=function(e){this.$main.innerHTML=s.stringRepeat(e,a);var t=this.$main.getBoundingClientRect();return t.width/a},this.getCharacterWidth=function(e){var t=this.charSizes[e];return t===undefined&&(this.charSizes[e]=this.$measureCharWidth(e)/this.$characterSize.width),t},this.destroy=function(){clearInterval(this.$pollSizeChangesTimer),this.el&&this.el.parentNode&&this.el.parentNode.removeChild(this.el)}}).call(f.prototype)}),ace.define("ace/virtual_renderer",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/config","ace/lib/useragent","ace/layer/gutter","ace/layer/marker","ace/layer/text","ace/layer/cursor","ace/scrollbar","ace/scrollbar","ace/renderloop","ace/layer/font_metrics","ace/lib/event_emitter"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/dom"),s=e("./config"),o=e("./lib/useragent"),u=e("./layer/gutter").Gutter,a=e("./layer/marker").Marker,f=e("./layer/text").Text,l=e("./layer/cursor").Cursor,c=e("./scrollbar").HScrollBar,h=e("./scrollbar").VScrollBar,p=e("./renderloop").RenderLoop,d=e("./layer/font_metrics").FontMetrics,v=e("./lib/event_emitter").EventEmitter,m='.ace_editor {position: relative;overflow: hidden;font-family: \'Monaco\', \'Menlo\', \'Ubuntu Mono\', \'Consolas\', \'source-code-pro\', monospace;font-size: 12px;line-height: normal;direction: ltr;}.ace_scroller {position: absolute;overflow: hidden;top: 0;bottom: 0;background-color: inherit;-ms-user-select: none;-moz-user-select: none;-webkit-user-select: none;user-select: none;}.ace_content {position: absolute;-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-sizing: border-box;cursor: text;min-width: 100%;}.ace_dragging, .ace_dragging * {cursor: move !important;}.ace_dragging .ace_scroller:before{position: absolute;top: 0;left: 0;right: 0;bottom: 0;content: \'\';background: rgba(250, 250, 250, 0.01);z-index: 1000;}.ace_dragging.ace_dark .ace_scroller:before{background: rgba(0, 0, 0, 0.01);}.ace_selecting, .ace_selecting * {cursor: text !important;}.ace_gutter {position: absolute;overflow : hidden;width: auto;top: 0;bottom: 0;left: 0;cursor: default;z-index: 4;-ms-user-select: none;-moz-user-select: none;-webkit-user-select: none;user-select: none;}.ace_gutter-active-line {position: absolute;left: 0;right: 0;}.ace_scroller.ace_scroll-left {box-shadow: 17px 0 16px -16px rgba(0, 0, 0, 0.4) inset;}.ace_gutter-cell {padding-left: 19px;padding-right: 6px;background-repeat: no-repeat;}.ace_gutter-cell.ace_error {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAABOFBMVEX/////////QRswFAb/Ui4wFAYwFAYwFAaWGAfDRymzOSH/PxswFAb/SiUwFAYwFAbUPRvjQiDllog5HhHdRybsTi3/Tyv9Tir+Syj/UC3////XurebMBIwFAb/RSHbPx/gUzfdwL3kzMivKBAwFAbbvbnhPx66NhowFAYwFAaZJg8wFAaxKBDZurf/RB6mMxb/SCMwFAYwFAbxQB3+RB4wFAb/Qhy4Oh+4QifbNRcwFAYwFAYwFAb/QRzdNhgwFAYwFAbav7v/Uy7oaE68MBK5LxLewr/r2NXewLswFAaxJw4wFAbkPRy2PyYwFAaxKhLm1tMwFAazPiQwFAaUGAb/QBrfOx3bvrv/VC/maE4wFAbRPBq6MRO8Qynew8Dp2tjfwb0wFAbx6eju5+by6uns4uH9/f36+vr/GkHjAAAAYnRSTlMAGt+64rnWu/bo8eAA4InH3+DwoN7j4eLi4xP99Nfg4+b+/u9B/eDs1MD1mO7+4PHg2MXa347g7vDizMLN4eG+Pv7i5evs/v79yu7S3/DV7/498Yv24eH+4ufQ3Ozu/v7+y13sRqwAAADLSURBVHjaZc/XDsFgGIBhtDrshlitmk2IrbHFqL2pvXf/+78DPokj7+Fz9qpU/9UXJIlhmPaTaQ6QPaz0mm+5gwkgovcV6GZzd5JtCQwgsxoHOvJO15kleRLAnMgHFIESUEPmawB9ngmelTtipwwfASilxOLyiV5UVUyVAfbG0cCPHig+GBkzAENHS0AstVF6bacZIOzgLmxsHbt2OecNgJC83JERmePUYq8ARGkJx6XtFsdddBQgZE2nPR6CICZhawjA4Fb/chv+399kfR+MMMDGOQAAAABJRU5ErkJggg==");background-repeat: no-repeat;background-position: 2px center;}.ace_gutter-cell.ace_warning {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAmVBMVEX///8AAAD///8AAAAAAABPSzb/5sAAAAB/blH/73z/ulkAAAAAAAD85pkAAAAAAAACAgP/vGz/rkDerGbGrV7/pkQICAf////e0IsAAAD/oED/qTvhrnUAAAD/yHD/njcAAADuv2r/nz//oTj/p064oGf/zHAAAAA9Nir/tFIAAAD/tlTiuWf/tkIAAACynXEAAAAAAAAtIRW7zBpBAAAAM3RSTlMAABR1m7RXO8Ln31Z36zT+neXe5OzooRDfn+TZ4p3h2hTf4t3k3ucyrN1K5+Xaks52Sfs9CXgrAAAAjklEQVR42o3PbQ+CIBQFYEwboPhSYgoYunIqqLn6/z8uYdH8Vmdnu9vz4WwXgN/xTPRD2+sgOcZjsge/whXZgUaYYvT8QnuJaUrjrHUQreGczuEafQCO/SJTufTbroWsPgsllVhq3wJEk2jUSzX3CUEDJC84707djRc5MTAQxoLgupWRwW6UB5fS++NV8AbOZgnsC7BpEAAAAABJRU5ErkJggg==");background-position: 2px center;}.ace_gutter-cell.ace_info {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAAAAAA6mKC9AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAAJ0Uk5TAAB2k804AAAAPklEQVQY02NgIB68QuO3tiLznjAwpKTgNyDbMegwisCHZUETUZV0ZqOquBpXj2rtnpSJT1AEnnRmL2OgGgAAIKkRQap2htgAAAAASUVORK5CYII=");background-position: 2px center;}.ace_dark .ace_gutter-cell.ace_info {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQBAMAAADt3eJSAAAAJFBMVEUAAAChoaGAgIAqKiq+vr6tra1ZWVmUlJSbm5s8PDxubm56enrdgzg3AAAAAXRSTlMAQObYZgAAAClJREFUeNpjYMAPdsMYHegyJZFQBlsUlMFVCWUYKkAZMxZAGdxlDMQBAG+TBP4B6RyJAAAAAElFTkSuQmCC");}.ace_scrollbar {position: absolute;right: 0;bottom: 0;z-index: 6;}.ace_scrollbar-inner {position: absolute;cursor: text;left: 0;top: 0;}.ace_scrollbar-v{overflow-x: hidden;overflow-y: scroll;top: 0;}.ace_scrollbar-h {overflow-x: scroll;overflow-y: hidden;left: 0;}.ace_print-margin {position: absolute;height: 100%;}.ace_text-input {position: absolute;z-index: 0;width: 0.5em;height: 1em;opacity: 0;background: transparent;-moz-appearance: none;appearance: none;border: none;resize: none;outline: none;overflow: hidden;font: inherit;padding: 0 1px;margin: 0 -1px;text-indent: -1em;-ms-user-select: text;-moz-user-select: text;-webkit-user-select: text;user-select: text;}.ace_text-input.ace_composition {background: inherit;color: inherit;z-index: 1000;opacity: 1;text-indent: 0;}.ace_layer {z-index: 1;position: absolute;overflow: hidden;white-space: pre;height: 100%;width: 100%;-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-sizing: border-box;pointer-events: none;}.ace_gutter-layer {position: relative;width: auto;text-align: right;pointer-events: auto;}.ace_text-layer {font: inherit !important;}.ace_cjk {display: inline-block;text-align: center;}.ace_cursor-layer {z-index: 4;}.ace_cursor {z-index: 4;position: absolute;-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-sizing: border-box;border-left: 2px solid}.ace_slim-cursors .ace_cursor {border-left-width: 1px;}.ace_overwrite-cursors .ace_cursor {border-left-width: 0px;border-bottom: 1px solid;}.ace_hidden-cursors .ace_cursor {opacity: 0.2;}.ace_smooth-blinking .ace_cursor {-moz-transition: opacity 0.18s;-webkit-transition: opacity 0.18s;-o-transition: opacity 0.18s;-ms-transition: opacity 0.18s;transition: opacity 0.18s;}.ace_editor.ace_multiselect .ace_cursor {border-left-width: 1px;}.ace_marker-layer .ace_step, .ace_marker-layer .ace_stack {position: absolute;z-index: 3;}.ace_marker-layer .ace_selection {position: absolute;z-index: 5;}.ace_marker-layer .ace_bracket {position: absolute;z-index: 6;}.ace_marker-layer .ace_active-line {position: absolute;z-index: 2;}.ace_marker-layer .ace_selected-word {position: absolute;z-index: 4;-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-sizing: border-box;}.ace_line .ace_fold {-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-sizing: border-box;display: inline-block;height: 11px;margin-top: -2px;vertical-align: middle;background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACJJREFUeNpi+P//fxgTAwPDBxDxD078RSX+YeEyDFMCIMAAI3INmXiwf2YAAAAASUVORK5CYII=");background-repeat: no-repeat, repeat-x;background-position: center center, top left;color: transparent;border: 1px solid black;-moz-border-radius: 2px;-webkit-border-radius: 2px;border-radius: 2px;cursor: pointer;pointer-events: auto;}.ace_dark .ace_fold {}.ace_fold:hover{background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABEAAAAJCAYAAADU6McMAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJpJREFUeNpi/P//PwOlgAXGYGRklAVSokD8GmjwY1wasKljQpYACtpCFeADcHVQfQyMQAwzwAZI3wJKvCLkfKBaMSClBlR7BOQikCFGQEErIH0VqkabiGCAqwUadAzZJRxQr/0gwiXIal8zQQPnNVTgJ1TdawL0T5gBIP1MUJNhBv2HKoQHHjqNrA4WO4zY0glyNKLT2KIfIMAAQsdgGiXvgnYAAAAASUVORK5CYII="),url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAA3CAYAAADNNiA5AAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAACBJREFUeNpi+P//fz4TAwPDZxDxD5X4i5fLMEwJgAADAEPVDbjNw87ZAAAAAElFTkSuQmCC");}.ace_tooltip {background-color: #FFF;background-image: -webkit-linear-gradient(top, transparent, rgba(0, 0, 0, 0.1));background-image: linear-gradient(to bottom, transparent, rgba(0, 0, 0, 0.1));border: 1px solid gray;border-radius: 1px;box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);color: black;display: block;max-width: 100%;padding: 3px 4px;position: fixed;z-index: 999999;-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-sizing: border-box;cursor: default;white-space: pre;word-wrap: break-word;line-height: normal;font-style: normal;font-weight: normal;letter-spacing: normal;pointer-events: none;}.ace_folding-enabled > .ace_gutter-cell {padding-right: 13px;}.ace_fold-widget {-moz-box-sizing: border-box;-webkit-box-sizing: border-box;box-sizing: border-box;margin: 0 -12px 0 1px;display: none;width: 11px;vertical-align: top;background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42mWKsQ0AMAzC8ixLlrzQjzmBiEjp0A6WwBCSPgKAXoLkqSot7nN3yMwR7pZ32NzpKkVoDBUxKAAAAABJRU5ErkJggg==");background-repeat: no-repeat;background-position: center;border-radius: 3px;border: 1px solid transparent;cursor: pointer;}.ace_folding-enabled .ace_fold-widget {display: inline-block; }.ace_fold-widget.ace_end {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAANElEQVR42m3HwQkAMAhD0YzsRchFKI7sAikeWkrxwScEB0nh5e7KTPWimZki4tYfVbX+MNl4pyZXejUO1QAAAABJRU5ErkJggg==");}.ace_fold-widget.ace_closed {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAGCAYAAAAG5SQMAAAAOUlEQVR42jXKwQkAMAgDwKwqKD4EwQ26sSOkVWjgIIHAzPiCgaqiqnJHZnKICBERHN194O5b9vbLuAVRL+l0YWnZAAAAAElFTkSuQmCCXA==");}.ace_fold-widget:hover {border: 1px solid rgba(0, 0, 0, 0.3);background-color: rgba(255, 255, 255, 0.2);-moz-box-shadow: 0 1px 1px rgba(255, 255, 255, 0.7);-webkit-box-shadow: 0 1px 1px rgba(255, 255, 255, 0.7);box-shadow: 0 1px 1px rgba(255, 255, 255, 0.7);}.ace_fold-widget:active {border: 1px solid rgba(0, 0, 0, 0.4);background-color: rgba(0, 0, 0, 0.05);-moz-box-shadow: 0 1px 1px rgba(255, 255, 255, 0.8);-webkit-box-shadow: 0 1px 1px rgba(255, 255, 255, 0.8);box-shadow: 0 1px 1px rgba(255, 255, 255, 0.8);}.ace_dark .ace_fold-widget {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHklEQVQIW2P4//8/AzoGEQ7oGCaLLAhWiSwB146BAQCSTPYocqT0AAAAAElFTkSuQmCC");}.ace_dark .ace_fold-widget.ace_end {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAH0lEQVQIW2P4//8/AxQ7wNjIAjDMgC4AxjCVKBirIAAF0kz2rlhxpAAAAABJRU5ErkJggg==");}.ace_dark .ace_fold-widget.ace_closed {background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAMAAAAFCAYAAACAcVaiAAAAHElEQVQIW2P4//+/AxAzgDADlOOAznHAKgPWAwARji8UIDTfQQAAAABJRU5ErkJggg==");}.ace_dark .ace_fold-widget:hover {box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);background-color: rgba(255, 255, 255, 0.1);}.ace_dark .ace_fold-widget:active {-moz-box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);-webkit-box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);box-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);}.ace_fold-widget.ace_invalid {background-color: #FFB4B4;border-color: #DE5555;}.ace_fade-fold-widgets .ace_fold-widget {-moz-transition: opacity 0.4s ease 0.05s;-webkit-transition: opacity 0.4s ease 0.05s;-o-transition: opacity 0.4s ease 0.05s;-ms-transition: opacity 0.4s ease 0.05s;transition: opacity 0.4s ease 0.05s;opacity: 0;}.ace_fade-fold-widgets:hover .ace_fold-widget {-moz-transition: opacity 0.05s ease 0.05s;-webkit-transition: opacity 0.05s ease 0.05s;-o-transition: opacity 0.05s ease 0.05s;-ms-transition: opacity 0.05s ease 0.05s;transition: opacity 0.05s ease 0.05s;opacity:1;}.ace_underline {text-decoration: underline;}.ace_bold {font-weight: bold;}.ace_nobold .ace_bold {font-weight: normal;}.ace_italic {font-style: italic;}.ace_error-marker {background-color: rgba(255, 0, 0,0.2);position: absolute;z-index: 9;}.ace_highlight-marker {background-color: rgba(255, 255, 0,0.2);position: absolute;z-index: 8;}';i.importCssString(m,"ace_editor");var g=function(e,t){var n=this;this.container=e||i.createElement("div"),this.$keepTextAreaAtCursor=!o.isOldIE,i.addCssClass(this.container,"ace_editor"),this.setTheme(t),this.$gutter=i.createElement("div"),this.$gutter.className="ace_gutter",this.container.appendChild(this.$gutter),this.scroller=i.createElement("div"),this.scroller.className="ace_scroller",this.container.appendChild(this.scroller),this.content=i.createElement("div"),this.content.className="ace_content",this.scroller.appendChild(this.content),this.$gutterLayer=new u(this.$gutter),this.$gutterLayer.on("changeGutterWidth",this.onGutterResize.bind(this)),this.$markerBack=new a(this.content);var r=this.$textLayer=new f(this.content);this.canvas=r.element,this.$markerFront=new a(this.content),this.$cursorLayer=new l(this.content),this.$horizScroll=!1,this.$vScroll=!1,this.scrollBar=this.scrollBarV=new h(this.container,this),this.scrollBarH=new c(this.container,this),this.scrollBarV.addEventListener("scroll",function(e){n.$scrollAnimation||n.session.setScrollTop(e.data-n.scrollMargin.top)}),this.scrollBarH.addEventListener("scroll",function(e){n.$scrollAnimation||n.session.setScrollLeft(e.data-n.scrollMargin.left)}),this.scrollTop=0,this.scrollLeft=0,this.cursorPos={row:0,column:0},this.$fontMetrics=new d(this.container,500),this.$textLayer.$setFontMetrics(this.$fontMetrics),this.$textLayer.addEventListener("changeCharacterSize",function(e){n.updateCharacterSize(),n.onResize(!0,n.gutterWidth,n.$size.width,n.$size.height),n._signal("changeCharacterSize",e)}),this.$size={width:0,height:0,scrollerHeight:0,scrollerWidth:0,$dirty:!0},this.layerConfig={width:1,padding:0,firstRow:0,firstRowScreen:0,lastRow:0,lineHeight:0,characterWidth:0,minHeight:1,maxHeight:1,offset:0,height:1,gutterOffset:1},this.scrollMargin={left:0,right:0,top:0,bottom:0,v:0,h:0},this.$loop=new p(this.$renderChanges.bind(this),this.container.ownerDocument.defaultView),this.$loop.schedule(this.CHANGE_FULL),this.updateCharacterSize(),this.setPadding(4),s.resetOptions(this),s._emit("renderer",this)};(function(){this.CHANGE_CURSOR=1,this.CHANGE_MARKER=2,this.CHANGE_GUTTER=4,this.CHANGE_SCROLL=8,this.CHANGE_LINES=16,this.CHANGE_TEXT=32,this.CHANGE_SIZE=64,this.CHANGE_MARKER_BACK=128,this.CHANGE_MARKER_FRONT=256,this.CHANGE_FULL=512,this.CHANGE_H_SCROLL=1024,r.implement(this,v),this.updateCharacterSize=function(){this.$textLayer.allowBoldFonts!=this.$allowBoldFonts&&(this.$allowBoldFonts=this.$textLayer.allowBoldFonts,this.setStyle("ace_nobold",!this.$allowBoldFonts)),this.layerConfig.characterWidth=this.characterWidth=this.$textLayer.getCharacterWidth(),this.layerConfig.lineHeight=this.lineHeight=this.$textLayer.getLineHeight(),this.$updatePrintMargin()},this.setSession=function(e){this.session&&this.session.doc.off("changeNewLineMode",this.onChangeNewLineMode),this.session=e,e&&this.scrollMargin.top&&e.getScrollTop()<=0&&e.setScrollTop(-this.scrollMargin.top),this.$cursorLayer.setSession(e),this.$markerBack.setSession(e),this.$markerFront.setSession(e),this.$gutterLayer.setSession(e),this.$textLayer.setSession(e);if(!e)return;this.$loop.schedule(this.CHANGE_FULL),this.session.$setFontMetrics(this.$fontMetrics),this.onChangeNewLineMode=this.onChangeNewLineMode.bind(this),this.onChangeNewLineMode(),this.session.doc.on("changeNewLineMode",this.onChangeNewLineMode)},this.updateLines=function(e,t,n){t===undefined&&(t=Infinity),this.$changedLines?(this.$changedLines.firstRow>e&&(this.$changedLines.firstRow=e),this.$changedLines.lastRow<t&&(this.$changedLines.lastRow=t)):this.$changedLines={firstRow:e,lastRow:t};if(this.$changedLines.lastRow<this.layerConfig.firstRow){if(!n)return;this.$changedLines.lastRow=this.layerConfig.lastRow}if(this.$changedLines.firstRow>this.layerConfig.lastRow)return;this.$loop.schedule(this.CHANGE_LINES)},this.onChangeNewLineMode=function(){this.$loop.schedule(this.CHANGE_TEXT),this.$textLayer.$updateEolChar()},this.onChangeTabSize=function(){this.$loop.schedule(this.CHANGE_TEXT|this.CHANGE_MARKER),this.$textLayer.onChangeTabSize()},this.updateText=function(){this.$loop.schedule(this.CHANGE_TEXT)},this.updateFull=function(e){e?this.$renderChanges(this.CHANGE_FULL,!0):this.$loop.schedule(this.CHANGE_FULL)},this.updateFontSize=function(){this.$textLayer.checkForSizeChanges()},this.$changes=0,this.$updateSizeAsync=function(){this.$loop.pending?this.$size.$dirty=!0:this.onResize()},this.onResize=function(e,t,n,r){if(this.resizing>2)return;this.resizing>0?this.resizing++:this.resizing=e?1:0;var i=this.container;r||(r=i.clientHeight||i.scrollHeight),n||(n=i.clientWidth||i.scrollWidth);var s=this.$updateCachedSize(e,t,n,r);if(!this.$size.scrollerHeight||!n&&!r)return this.resizing=0;e&&(this.$gutterLayer.$padding=null),e?this.$renderChanges(s|this.$changes,!0):this.$loop.schedule(s|this.$changes),this.resizing&&(this.resizing=0)},this.$updateCachedSize=function(e,t,n,r){r-=this.$extraHeight||0;var i=0,s=this.$size,o={width:s.width,height:s.height,scrollerHeight:s.scrollerHeight,scrollerWidth:s.scrollerWidth};r&&(e||s.height!=r)&&(s.height=r,i|=this.CHANGE_SIZE,s.scrollerHeight=s.height,this.$horizScroll&&(s.scrollerHeight-=this.scrollBarH.getHeight()),this.scrollBarV.element.style.bottom=this.scrollBarH.getHeight()+"px",i|=this.CHANGE_SCROLL);if(n&&(e||s.width!=n)){i|=this.CHANGE_SIZE,s.width=n,t==null&&(t=this.$showGutter?this.$gutter.offsetWidth:0),this.gutterWidth=t,this.scrollBarH.element.style.left=this.scroller.style.left=t+"px",s.scrollerWidth=Math.max(0,n-t-this.scrollBarV.getWidth()),this.scrollBarH.element.style.right=this.scroller.style.right=this.scrollBarV.getWidth()+"px",this.scroller.style.bottom=this.scrollBarH.getHeight()+"px";if(this.session&&this.session.getUseWrapMode()&&this.adjustWrapLimit()||e)i|=this.CHANGE_FULL}return s.$dirty=!n||!r,i&&this._signal("resize",o),i},this.onGutterResize=function(){var e=this.$showGutter?this.$gutter.offsetWidth:0;e!=this.gutterWidth&&(this.$changes|=this.$updateCachedSize(!0,e,this.$size.width,this.$size.height)),this.session.getUseWrapMode()&&this.adjustWrapLimit()?this.$loop.schedule(this.CHANGE_FULL):this.$size.$dirty?this.$loop.schedule(this.CHANGE_FULL):(this.$computeLayerConfig(),this.$loop.schedule(this.CHANGE_MARKER))},this.adjustWrapLimit=function(){var e=this.$size.scrollerWidth-this.$padding*2,t=Math.floor(e/this.characterWidth);return this.session.adjustWrapLimit(t,this.$showPrintMargin&&this.$printMarginColumn)},this.setAnimatedScroll=function(e){this.setOption("animatedScroll",e)},this.getAnimatedScroll=function(){return this.$animatedScroll},this.setShowInvisibles=function(e){this.setOption("showInvisibles",e)},this.getShowInvisibles=function(){return this.getOption("showInvisibles")},this.getDisplayIndentGuides=function(){return this.getOption("displayIndentGuides")},this.setDisplayIndentGuides=function(e){this.setOption("displayIndentGuides",e)},this.setShowPrintMargin=function(e){this.setOption("showPrintMargin",e)},this.getShowPrintMargin=function(){return this.getOption("showPrintMargin")},this.setPrintMarginColumn=function(e){this.setOption("printMarginColumn",e)},this.getPrintMarginColumn=function(){return this.getOption("printMarginColumn")},this.getShowGutter=function(){return this.getOption("showGutter")},this.setShowGutter=function(e){return this.setOption("showGutter",e)},this.getFadeFoldWidgets=function(){return this.getOption("fadeFoldWidgets")},this.setFadeFoldWidgets=function(e){this.setOption("fadeFoldWidgets",e)},this.setHighlightGutterLine=function(e){this.setOption("highlightGutterLine",e)},this.getHighlightGutterLine=function(){return this.getOption("highlightGutterLine")},this.$updateGutterLineHighlight=function(){var e=this.$cursorLayer.$pixelPos,t=this.layerConfig.lineHeight;if(this.session.getUseWrapMode()){var n=this.session.selection.getCursor();n.column=0,e=this.$cursorLayer.getPixelPosition(n,!0),t*=this.session.getRowLength(n.row)}this.$gutterLineHighlight.style.top=e.top-this.layerConfig.offset+"px",this.$gutterLineHighlight.style.height=t+"px"},this.$updatePrintMargin=function(){if(!this.$showPrintMargin&&!this.$printMarginEl)return;if(!this.$printMarginEl){var e=i.createElement("div");e.className="ace_layer ace_print-margin-layer",this.$printMarginEl=i.createElement("div"),this.$printMarginEl.className="ace_print-margin",e.appendChild(this.$printMarginEl),this.content.insertBefore(e,this.content.firstChild)}var t=this.$printMarginEl.style;t.left=this.characterWidth*this.$printMarginColumn+this.$padding+"px",t.visibility=this.$showPrintMargin?"visible":"hidden",this.session&&this.session.$wrap==-1&&this.adjustWrapLimit()},this.getContainerElement=function(){return this.container},this.getMouseEventTarget=function(){return this.content},this.getTextAreaContainer=function(){return this.container},this.$moveTextAreaToCursor=function(){if(!this.$keepTextAreaAtCursor)return;var e=this.layerConfig,t=this.$cursorLayer.$pixelPos.top,n=this.$cursorLayer.$pixelPos.left;t-=e.offset;var r=this.lineHeight;if(t<0||t>e.height-r)return;var i=this.characterWidth;if(this.$composition){var s=this.textarea.value.replace(/^\x01+/,"");i*=this.session.$getStringScreenWidth(s)[0]+2,r+=2}n-=this.scrollLeft,n>this.$size.scrollerWidth-i&&(n=this.$size.scrollerWidth-i),n+=this.gutterWidth,this.textarea.style.height=r+"px",this.textarea.style.width=i+"px",this.textarea.style.left=Math.min(n,this.$size.scrollerWidth-i)+"px",this.textarea.style.top=Math.min(t,this.$size.height-r)+"px"},this.getFirstVisibleRow=function(){return this.layerConfig.firstRow},this.getFirstFullyVisibleRow=function(){return this.layerConfig.firstRow+(this.layerConfig.offset===0?0:1)},this.getLastFullyVisibleRow=function(){var e=Math.floor((this.layerConfig.height+this.layerConfig.offset)/this.layerConfig.lineHeight);return this.layerConfig.firstRow-1+e},this.getLastVisibleRow=function(){return this.layerConfig.lastRow},this.$padding=null,this.setPadding=function(e){this.$padding=e,this.$textLayer.setPadding(e),this.$cursorLayer.setPadding(e),this.$markerFront.setPadding(e),this.$markerBack.setPadding(e),this.$loop.schedule(this.CHANGE_FULL),this.$updatePrintMargin()},this.setScrollMargin=function(e,t,n,r){var i=this.scrollMargin;i.top=e|0,i.bottom=t|0,i.right=r|0,i.left=n|0,i.v=i.top+i.bottom,i.h=i.left+i.right,i.top&&this.scrollTop<=0&&this.session&&this.session.setScrollTop(-i.top),this.updateFull()},this.getHScrollBarAlwaysVisible=function(){return this.$hScrollBarAlwaysVisible},this.setHScrollBarAlwaysVisible=function(e){this.setOption("hScrollBarAlwaysVisible",e)},this.getVScrollBarAlwaysVisible=function(){return this.$hScrollBarAlwaysVisible},this.setVScrollBarAlwaysVisible=function(e){this.setOption("vScrollBarAlwaysVisible",e)},this.$updateScrollBarV=function(){var e=this.layerConfig.maxHeight,t=this.$size.scrollerHeight;!this.$maxLines&&this.$scrollPastEnd&&(e-=(t-this.lineHeight)*this.$scrollPastEnd,this.scrollTop>e-t&&(e=this.scrollTop+t,this.scrollBarV.scrollTop=null)),this.scrollBarV.setScrollHeight(e+this.scrollMargin.v),this.scrollBarV.setScrollTop(this.scrollTop+this.scrollMargin.top)},this.$updateScrollBarH=function(){this.scrollBarH.setScrollWidth(this.layerConfig.width+2*this.$padding+this.scrollMargin.h),this.scrollBarH.setScrollLeft(this.scrollLeft+this.scrollMargin.left)},this.$frozen=!1,this.freeze=function(){this.$frozen=!0},this.unfreeze=function(){this.$frozen=!1},this.$renderChanges=function(e,t){this.$changes&&(e|=this.$changes,this.$changes=0);if(!this.session||!this.container.offsetWidth||this.$frozen||!e&&!t){this.$changes|=e;return}if(this.$size.$dirty)return this.$changes|=e,this.onResize(!0);this.lineHeight||this.$textLayer.checkForSizeChanges(),this._signal("beforeRender");var n=this.layerConfig;if(e&this.CHANGE_FULL||e&this.CHANGE_SIZE||e&this.CHANGE_TEXT||e&this.CHANGE_LINES||e&this.CHANGE_SCROLL||e&this.CHANGE_H_SCROLL)e|=this.$computeLayerConfig(),n=this.layerConfig,this.$updateScrollBarV(),e&this.CHANGE_H_SCROLL&&this.$updateScrollBarH(),this.$gutterLayer.element.style.marginTop=-n.offset+"px",this.content.style.marginTop=-n.offset+"px",this.content.style.width=n.width+2*this.$padding+"px",this.content.style.height=n.minHeight+"px";e&this.CHANGE_H_SCROLL&&(this.content.style.marginLeft=-this.scrollLeft+"px",this.scroller.className=this.scrollLeft<=0?"ace_scroller":"ace_scroller ace_scroll-left");if(e&this.CHANGE_FULL){this.$textLayer.update(n),this.$showGutter&&this.$gutterLayer.update(n),this.$markerBack.update(n),this.$markerFront.update(n),this.$cursorLayer.update(n),this.$moveTextAreaToCursor(),this.$highlightGutterLine&&this.$updateGutterLineHighlight(),this._signal("afterRender");return}if(e&this.CHANGE_SCROLL){e&this.CHANGE_TEXT||e&this.CHANGE_LINES?this.$textLayer.update(n):this.$textLayer.scrollLines(n),this.$showGutter&&this.$gutterLayer.update(n),this.$markerBack.update(n),this.$markerFront.update(n),this.$cursorLayer.update(n),this.$highlightGutterLine&&this.$updateGutterLineHighlight(),this.$moveTextAreaToCursor(),this._signal("afterRender");return}e&this.CHANGE_TEXT?(this.$textLayer.update(n),this.$showGutter&&this.$gutterLayer.update(n)):e&this.CHANGE_LINES?(this.$updateLines()||e&this.CHANGE_GUTTER&&this.$showGutter)&&this.$gutterLayer.update(n):(e&this.CHANGE_TEXT||e&this.CHANGE_GUTTER)&&this.$showGutter&&this.$gutterLayer.update(n),e&this.CHANGE_CURSOR&&(this.$cursorLayer.update(n),this.$moveTextAreaToCursor(),this.$highlightGutterLine&&this.$updateGutterLineHighlight()),e&(this.CHANGE_MARKER|this.CHANGE_MARKER_FRONT)&&this.$markerFront.update(n),e&(this.CHANGE_MARKER|this.CHANGE_MARKER_BACK)&&this.$markerBack.update(n),this._signal("afterRender")},this.$autosize=function(){var e=this.session.getScreenLength()*this.lineHeight,t=this.$maxLines*this.lineHeight,n=Math.max((this.$minLines||1)*this.lineHeight,Math.min(t,e))+this.scrollMargin.v+(this.$extraHeight||0),r=e>t;if(n!=this.desiredHeight||this.$size.height!=this.desiredHeight||r!=this.$vScroll){r!=this.$vScroll&&(this.$vScroll=r,this.scrollBarV.setVisible(r));var i=this.container.clientWidth;this.container.style.height=n+"px",this.$updateCachedSize(!0,this.$gutterWidth,i,n),this.desiredHeight=n,this._signal("autosize")}},this.$computeLayerConfig=function(){this.$maxLines&&this.lineHeight>1&&this.$autosize();var e=this.session,t=this.$size,n=t.height<=2*this.lineHeight,r=this.session.getScreenLength(),i=r*this.lineHeight,s=this.scrollTop%this.lineHeight,o=t.scrollerHeight+this.lineHeight,u=this.$getLongestLine(),a=!n&&(this.$hScrollBarAlwaysVisible||t.scrollerWidth-u-2*this.$padding<0),f=this.$horizScroll!==a;f&&(this.$horizScroll=a,this.scrollBarH.setVisible(a)),!this.$maxLines&&this.$scrollPastEnd&&(i+=(t.scrollerHeight-this.lineHeight)*this.$scrollPastEnd);var l=!n&&(this.$vScrollBarAlwaysVisible||t.scrollerHeight-i<0),c=this.$vScroll!==l;c&&(this.$vScroll=l,this.scrollBarV.setVisible(l)),this.session.setScrollTop(Math.max(-this.scrollMargin.top,Math.min(this.scrollTop,i-t.scrollerHeight+this.scrollMargin.bottom))),this.session.setScrollLeft(Math.max(-this.scrollMargin.left,Math.min(this.scrollLeft,u+2*this.$padding-t.scrollerWidth+this.scrollMargin.right)));var h=Math.ceil(o/this.lineHeight)-1,p=Math.max(0,Math.round((this.scrollTop-s)/this.lineHeight)),d=p+h,v,m,g=this.lineHeight;p=e.screenToDocumentRow(p,0);var y=e.getFoldLine(p);y&&(p=y.start.row),v=e.documentToScreenRow(p,0),m=e.getRowLength(p)*g,d=Math.min(e.screenToDocumentRow(d,0),e.getLength()-1),o=t.scrollerHeight+e.getRowLength(d)*g+m,s=this.scrollTop-v*g;var b=0;this.layerConfig.width!=u&&(b=this.CHANGE_H_SCROLL);if(f||c)b=this.$updateCachedSize(!0,this.gutterWidth,t.width,t.height),this._signal("scrollbarVisibilityChanged"),c&&(u=this.$getLongestLine());return this.layerConfig={width:u,padding:this.$padding,firstRow:p,firstRowScreen:v,lastRow:d,lineHeight:g,characterWidth:this.characterWidth,minHeight:o,maxHeight:i,offset:s,gutterOffset:Math.max(0,Math.ceil((s+t.height-t.scrollerHeight)/g)),height:this.$size.scrollerHeight},b},this.$updateLines=function(){var e=this.$changedLines.firstRow,t=this.$changedLines.lastRow;this.$changedLines=null;var n=this.layerConfig;if(e>n.lastRow+1)return;if(t<n.firstRow)return;if(t===Infinity){this.$showGutter&&this.$gutterLayer.update(n),this.$textLayer.update(n);return}return this.$textLayer.updateLines(n,e,t),!0},this.$getLongestLine=function(){var e=this.session.getScreenWidth();return this.showInvisibles&&!this.session.$useWrapMode&&(e+=1),Math.max(this.$size.scrollerWidth-2*this.$padding,Math.round(e*this.characterWidth))},this.updateFrontMarkers=function(){this.$markerFront.setMarkers(this.session.getMarkers(!0)),this.$loop.schedule(this.CHANGE_MARKER_FRONT)},this.updateBackMarkers=function(){this.$markerBack.setMarkers(this.session.getMarkers()),this.$loop.schedule(this.CHANGE_MARKER_BACK)},this.addGutterDecoration=function(e,t){this.$gutterLayer.addGutterDecoration(e,t)},this.removeGutterDecoration=function(e,t){this.$gutterLayer.removeGutterDecoration(e,t)},this.updateBreakpoints=function(e){this.$loop.schedule(this.CHANGE_GUTTER)},this.setAnnotations=function(e){this.$gutterLayer.setAnnotations(e),this.$loop.schedule(this.CHANGE_GUTTER)},this.updateCursor=function(){this.$loop.schedule(this.CHANGE_CURSOR)},this.hideCursor=function(){this.$cursorLayer.hideCursor()},this.showCursor=function(){this.$cursorLayer.showCursor()},this.scrollSelectionIntoView=function(e,t,n){this.scrollCursorIntoView(e,n),this.scrollCursorIntoView(t,n)},this.scrollCursorIntoView=function(e,t,n){if(this.$size.scrollerHeight===0)return;var r=this.$cursorLayer.getPixelPosition(e),i=r.left,s=r.top,o=n&&n.top||0,u=n&&n.bottom||0,a=this.$scrollAnimation?this.session.getScrollTop():this.scrollTop;a+o>s?(t&&(s-=t*this.$size.scrollerHeight),s===0&&(s=-this.scrollMargin.top),this.session.setScrollTop(s)):a+this.$size.scrollerHeight-u<s+this.lineHeight&&(t&&(s+=t*this.$size.scrollerHeight),this.session.setScrollTop(s+this.lineHeight-this.$size.scrollerHeight));var f=this.scrollLeft;f>i?(i<this.$padding+2*this.layerConfig.characterWidth&&(i=-this.scrollMargin.left),this.session.setScrollLeft(i)):f+this.$size.scrollerWidth<i+this.characterWidth?this.session.setScrollLeft(Math.round(i+this.characterWidth-this.$size.scrollerWidth)):f<=this.$padding&&i-f<this.characterWidth&&this.session.setScrollLeft(0)},this.getScrollTop=function(){return this.session.getScrollTop()},this.getScrollLeft=function(){return this.session.getScrollLeft()},this.getScrollTopRow=function(){return this.scrollTop/this.lineHeight},this.getScrollBottomRow=function(){return Math.max(0,Math.floor((this.scrollTop+this.$size.scrollerHeight)/this.lineHeight)-1)},this.scrollToRow=function(e){this.session.setScrollTop(e*this.lineHeight)},this.alignCursor=function(e,t){typeof e=="number"&&(e={row:e,column:0});var n=this.$cursorLayer.getPixelPosition(e),r=this.$size.scrollerHeight-this.lineHeight,i=n.top-r*(t||0);return this.session.setScrollTop(i),i},this.STEPS=8,this.$calcSteps=function(e,t){var n=0,r=this.STEPS,i=[],s=function(e,t,n){return n*(Math.pow(e-1,3)+1)+t};for(n=0;n<r;++n)i.push(s(n/this.STEPS,e,t-e));return i},this.scrollToLine=function(e,t,n,r){var i=this.$cursorLayer.getPixelPosition({row:e,column:0}),s=i.top;t&&(s-=this.$size.scrollerHeight/2);var o=this.scrollTop;this.session.setScrollTop(s),n!==!1&&this.animateScrolling(o,r)},this.animateScrolling=function(e,t){var n=this.scrollTop;if(!this.$animatedScroll)return;var r=this;if(e==n)return;if(this.$scrollAnimation){var i=this.$scrollAnimation.steps;if(i.length){e=i[0];if(e==n)return}}var s=r.$calcSteps(e,n);this.$scrollAnimation={from:e,to:n,steps:s},clearInterval(this.$timer),r.session.setScrollTop(s.shift()),r.session.$scrollTop=n,this.$timer=setInterval(function(){s.length?(r.session.setScrollTop(s.shift()),r.session.$scrollTop=n):n!=null?(r.session.$scrollTop=-1,r.session.setScrollTop(n),n=null):(r.$timer=clearInterval(r.$timer),r.$scrollAnimation=null,t&&t())},10)},this.scrollToY=function(e){this.scrollTop!==e&&(this.$loop.schedule(this.CHANGE_SCROLL),this.scrollTop=e)},this.scrollToX=function(e){this.scrollLeft!==e&&(this.scrollLeft=e),this.$loop.schedule(this.CHANGE_H_SCROLL)},this.scrollTo=function(e,t){this.session.setScrollTop(t),this.session.setScrollLeft(t)},this.scrollBy=function(e,t){t&&this.session.setScrollTop(this.session.getScrollTop()+t),e&&this.session.setScrollLeft(this.session.getScrollLeft()+e)},this.isScrollableBy=function(e,t){if(t<0&&this.session.getScrollTop()>=1-this.scrollMargin.top)return!0;if(t>0&&this.session.getScrollTop()+this.$size.scrollerHeight-this.layerConfig.maxHeight<-1+this.scrollMargin.bottom)return!0;if(e<0&&this.session.getScrollLeft()>=1-this.scrollMargin.left)return!0;if(e>0&&this.session.getScrollLeft()+this.$size.scrollerWidth-this.layerConfig.width<-1+this.scrollMargin.right)return!0},this.pixelToScreenCoordinates=function(e,t){var n=this.scroller.getBoundingClientRect(),r=(e+this.scrollLeft-n.left-this.$padding)/this.characterWidth,i=Math.floor((t+this.scrollTop-n.top)/this.lineHeight),s=Math.round(r);return{row:i,column:s,side:r-s>0?1:-1}},this.screenToTextCoordinates=function(e,t){var n=this.scroller.getBoundingClientRect(),r=Math.round((e+this.scrollLeft-n.left-this.$padding)/this.characterWidth),i=(t+this.scrollTop-n.top)/this.lineHeight;return this.session.screenToDocumentPosition(i,Math.max(r,0))},this.textToScreenCoordinates=function(e,t){var n=this.scroller.getBoundingClientRect(),r=this.session.documentToScreenPosition(e,t),i=this.$padding+Math.round(r.column*this.characterWidth),s=r.row*this.lineHeight;return{pageX:n.left+i-this.scrollLeft,pageY:n.top+s-this.scrollTop}},this.visualizeFocus=function(){i.addCssClass(this.container,"ace_focus")},this.visualizeBlur=function(){i.removeCssClass(this.container,"ace_focus")},this.showComposition=function(e){this.$composition||(this.$composition={keepTextAreaAtCursor:this.$keepTextAreaAtCursor,cssText:this.textarea.style.cssText}),this.$keepTextAreaAtCursor=!0,i.addCssClass(this.textarea,"ace_composition"),this.textarea.style.cssText="",this.$moveTextAreaToCursor()},this.setCompositionText=function(e){this.$moveTextAreaToCursor()},this.hideComposition=function(){if(!this.$composition)return;i.removeCssClass(this.textarea,"ace_composition"),this.$keepTextAreaAtCursor=this.$composition.keepTextAreaAtCursor,this.textarea.style.cssText=this.$composition.cssText,this.$composition=null},this.setTheme=function(e,t){function o(r){if(n.$themeId!=e)return t&&t();if(!r.cssClass)return;i.importCssString(r.cssText,r.cssClass,n.container.ownerDocument),n.theme&&i.removeCssClass(n.container,n.theme.cssClass);var s="padding"in r?r.padding:"padding"in(n.theme||{})?4:n.$padding;n.$padding&&s!=n.$padding&&n.setPadding(s),n.$theme=r.cssClass,n.theme=r,i.addCssClass(n.container,r.cssClass),i.setCssClass(n.container,"ace_dark",r.isDark),n.$size&&(n.$size.width=0,n.$updateSizeAsync()),n._dispatchEvent("themeLoaded",{theme:r}),t&&t()}var n=this;this.$themeId=e,n._dispatchEvent("themeChange",{theme:e});if(!e||typeof e=="string"){var r=e||this.$options.theme.initialValue;s.loadModule(["theme",r],o)}else o(e)},this.getTheme=function(){return this.$themeId},this.setStyle=function(e,t){i.setCssClass(this.container,e,t!==!1)},this.unsetStyle=function(e){i.removeCssClass(this.container,e)},this.setCursorStyle=function(e){this.content.style.cursor!=e&&(this.content.style.cursor=e)},this.setMouseCursor=function(e){this.content.style.cursor=e},this.destroy=function(){this.$textLayer.destroy(),this.$cursorLayer.destroy()}}).call(g.prototype),s.defineOptions(g.prototype,"renderer",{animatedScroll:{initialValue:!1},showInvisibles:{set:function(e){this.$textLayer.setShowInvisibles(e)&&this.$loop.schedule(this.CHANGE_TEXT)},initialValue:!1},showPrintMargin:{set:function(){this.$updatePrintMargin()},initialValue:!0},printMarginColumn:{set:function(){this.$updatePrintMargin()},initialValue:80},printMargin:{set:function(e){typeof e=="number"&&(this.$printMarginColumn=e),this.$showPrintMargin=!!e,this.$updatePrintMargin()},get:function(){return this.$showPrintMargin&&this.$printMarginColumn}},showGutter:{set:function(e){this.$gutter.style.display=e?"block":"none",this.$loop.schedule(this.CHANGE_FULL),this.onGutterResize()},initialValue:!0},fadeFoldWidgets:{set:function(e){i.setCssClass(this.$gutter,"ace_fade-fold-widgets",e)},initialValue:!1},showFoldWidgets:{set:function(e){this.$gutterLayer.setShowFoldWidgets(e)},initialValue:!0},showLineNumbers:{set:function(e){this.$gutterLayer.setShowLineNumbers(e),this.$loop.schedule(this.CHANGE_GUTTER)},initialValue:!0},displayIndentGuides:{set:function(e){this.$textLayer.setDisplayIndentGuides(e)&&this.$loop.schedule(this.CHANGE_TEXT)},initialValue:!0},highlightGutterLine:{set:function(e){if(!this.$gutterLineHighlight){this.$gutterLineHighlight=i.createElement("div"),this.$gutterLineHighlight.className="ace_gutter-active-line",this.$gutter.appendChild(this.$gutterLineHighlight);return}this.$gutterLineHighlight.style.display=e?"":"none",this.$cursorLayer.$pixelPos&&this.$updateGutterLineHighlight()},initialValue:!1,value:!0},hScrollBarAlwaysVisible:{set:function(e){(!this.$hScrollBarAlwaysVisible||!this.$horizScroll)&&this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},vScrollBarAlwaysVisible:{set:function(e){(!this.$vScrollBarAlwaysVisible||!this.$vScroll)&&this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:!1},fontSize:{set:function(e){typeof e=="number"&&(e+="px"),this.container.style.fontSize=e,this.updateFontSize()},initialValue:12},fontFamily:{set:function(e){this.container.style.fontFamily=e,this.updateFontSize()}},maxLines:{set:function(e){this.updateFull()}},minLines:{set:function(e){this.updateFull()}},scrollPastEnd:{set:function(e){e=+e||0;if(this.$scrollPastEnd==e)return;this.$scrollPastEnd=e,this.$loop.schedule(this.CHANGE_SCROLL)},initialValue:0,handlesSet:!0},fixedWidthGutter:{set:function(e){this.$gutterLayer.$fixedWidth=!!e,this.$loop.schedule(this.CHANGE_GUTTER)}},theme:{set:function(e){this.setTheme(e)},get:function(){return this.$themeId||this.theme},initialValue:"./theme/textmate",handlesSet:!0}}),t.VirtualRenderer=g}),ace.define("ace/worker/worker_client",["require","exports","module","ace/lib/oop","ace/lib/net","ace/lib/event_emitter","ace/config"],function(e,t,n){"use strict";var r=e("../lib/oop"),i=e("../lib/net"),s=e("../lib/event_emitter").EventEmitter,o=e("../config"),u=function(t,n,r,i){this.$sendDeltaQueue=this.$sendDeltaQueue.bind(this),this.changeListener=this.changeListener.bind(this),this.onMessage=this.onMessage.bind(this),e.nameToUrl&&!e.toUrl&&(e.toUrl=e.nameToUrl);if(o.get("packaged")||!e.toUrl)i=i||o.moduleUrl(n,"worker");else{var s=this.$normalizePath;i=i||s(e.toUrl("ace/worker/worker.js",null,"_"));var u={};t.forEach(function(t){u[t]=s(e.toUrl(t,null,"_").replace(/(\.js)?(\?.*)?$/,""))})}try{this.$worker=new Worker(i)}catch(a){if(!(a instanceof window.DOMException))throw a;var f=this.$workerBlob(i),l=window.URL||window.webkitURL,c=l.createObjectURL(f);this.$worker=new Worker(c),l.revokeObjectURL(c)}this.$worker.postMessage({init:!0,tlns:u,module:n,classname:r}),this.callbackId=1,this.callbacks={},this.$worker.onmessage=this.onMessage};(function(){r.implement(this,s),this.onMessage=function(e){var t=e.data;switch(t.type){case"log":window.console&&console.log&&console.log.apply(console,t.data);break;case"event":this._signal(t.name,{data:t.data});break;case"call":var n=this.callbacks[t.id];n&&(n(t.data),delete this.callbacks[t.id])}},this.$normalizePath=function(e){return i.qualifyURL(e)},this.terminate=function(){this._signal("terminate",{}),this.deltaQueue=null,this.$worker.terminate(),this.$worker=null,this.$doc.removeEventListener("change",this.changeListener),this.$doc=null},this.send=function(e,t){this.$worker.postMessage({command:e,args:t})},this.call=function(e,t,n){if(n){var r=this.callbackId++;this.callbacks[r]=n,t.push(r)}this.send(e,t)},this.emit=function(e,t){try{this.$worker.postMessage({event:e,data:{data:t.data}})}catch(n){console.error(n.stack)}},this.attachToDocument=function(e){this.$doc&&this.terminate(),this.$doc=e,this.call("setValue",[e.getValue()]),e.on("change",this.changeListener)},this.changeListener=function(e){this.deltaQueue?this.deltaQueue.push(e.data):(this.deltaQueue=[e.data],setTimeout(this.$sendDeltaQueue,0))},this.$sendDeltaQueue=function(){var e=this.deltaQueue;if(!e)return;this.deltaQueue=null,e.length>20&&e.length>this.$doc.getLength()>>1?this.call("setValue",[this.$doc.getValue()]):this.emit("change",{data:e})},this.$workerBlob=function(e){var t="importScripts('"+i.qualifyURL(e)+"');";try{return new Blob([t],{type:"application/javascript"})}catch(n){var r=window.BlobBuilder||window.WebKitBlobBuilder||window.MozBlobBuilder,s=new r;return s.append(t),s.getBlob("application/javascript")}}}).call(u.prototype);var a=function(e,t,n){this.$sendDeltaQueue=this.$sendDeltaQueue.bind(this),this.changeListener=this.changeListener.bind(this),this.callbackId=1,this.callbacks={},this.messageBuffer=[];var r=null,i=!1,u=Object.create(s),a=this;this.$worker={},this.$worker.terminate=function(){},this.$worker.postMessage=function(e){a.messageBuffer.push(e),r&&(i?setTimeout(f):f())},this.setEmitSync=function(e){i=e};var f=function(){var e=a.messageBuffer.shift();e.command?r[e.command].apply(r,e.args):e.event&&u._signal(e.event,e.data)};u.postMessage=function(e){a.onMessage({data:e})},u.callback=function(e,t){this.postMessage({type:"call",id:t,data:e})},u.emit=function(e,t){this.postMessage({type:"event",name:e,data:t})},o.loadModule(["worker",t],function(e){r=new e[n](u);while(a.messageBuffer.length)f()})};a.prototype=u.prototype,t.UIWorkerClient=a,t.WorkerClient=u}),ace.define("ace/placeholder",["require","exports","module","ace/range","ace/lib/event_emitter","ace/lib/oop"],function(e,t,n){"use strict";var r=e("./range").Range,i=e("./lib/event_emitter").EventEmitter,s=e("./lib/oop"),o=function(e,t,n,r,i,s){var o=this;this.length=t,this.session=e,this.doc=e.getDocument(),this.mainClass=i,this.othersClass=s,this.$onUpdate=this.onUpdate.bind(this),this.doc.on("change",this.$onUpdate),this.$others=r,this.$onCursorChange=function(){setTimeout(function(){o.onCursorChange()})},this.$pos=n;var u=e.getUndoManager().$undoStack||e.getUndoManager().$undostack||{length:-1};this.$undoStackDepth=u.length,this.setup(),e.selection.on("changeCursor",this.$onCursorChange)};(function(){s.implement(this,i),this.setup=function(){var e=this,t=this.doc,n=this.session,i=this.$pos;this.selectionBefore=n.selection.toJSON(),n.selection.inMultiSelectMode&&n.selection.toSingleRange(),this.pos=t.createAnchor(i.row,i.column),this.markerId=n.addMarker(new r(i.row,i.column,i.row,i.column+this.length),this.mainClass,null,!1),this.pos.on("change",function(t){n.removeMarker(e.markerId),e.markerId=n.addMarker(new r(t.value.row,t.value.column,t.value.row,t.value.column+e.length),e.mainClass,null,!1)}),this.others=[],this.$others.forEach(function(n){var r=t.createAnchor(n.row,n.column);e.others.push(r)}),n.setUndoSelect(!1)},this.showOtherMarkers=function(){if(this.othersActive)return;var e=this.session,t=this;this.othersActive=!0,this.others.forEach(function(n){n.markerId=e.addMarker(new r(n.row,n.column,n.row,n.column+t.length),t.othersClass,null,!1),n.on("change",function(i){e.removeMarker(n.markerId),n.markerId=e.addMarker(new r(i.value.row,i.value.column,i.value.row,i.value.column+t.length),t.othersClass,null,!1)})})},this.hideOtherMarkers=function(){if(!this.othersActive)return;this.othersActive=!1;for(var e=0;e<this.others.length;e++)this.session.removeMarker(this.others[e].markerId)},this.onUpdate=function(e){var t=e.data,n=t.range;if(n.start.row!==n.end.row)return;if(n.start.row!==this.pos.row)return;if(this.$updating)return;this.$updating=!0;var i=t.action==="insertText"?n.end.column-n.start.column:n.start.column-n.end.column;if(n.start.column>=this.pos.column&&n.start.column<=this.pos.column+this.length+1){var s=n.start.column-this.pos.column;this.length+=i;if(!this.session.$fromUndo){if(t.action==="insertText")for(var o=this.others.length-1;o>=0;o--){var u=this.others[o],a={row:u.row,column:u.column+s};u.row===n.start.row&&n.start.column<u.column&&(a.column+=i),this.doc.insert(a,t.text)}else if(t.action==="removeText")for(var o=this.others.length-1;o>=0;o--){var u=this.others[o],a={row:u.row,column:u.column+s};u.row===n.start.row&&n.start.column<u.column&&(a.column+=i),this.doc.remove(new r(a.row,a.column,a.row,a.column-i))}n.start.column===this.pos.column&&t.action==="insertText"?setTimeout(function(){this.pos.setPosition(this.pos.row,this.pos.column-i);for(var e=0;e<this.others.length;e++){var t=this.others[e],r={row:t.row,column:t.column-i};t.row===n.start.row&&n.start.column<t.column&&(r.column+=i),t.setPosition(r.row,r.column)}}.bind(this),0):n.start.column===this.pos.column&&t.action==="removeText"&&setTimeout(function(){for(var e=0;e<this.others.length;e++){var t=this.others[e];t.row===n.start.row&&n.start.column<t.column&&t.setPosition(t.row,t.column-i)}}.bind(this),0)}this.pos._emit("change",{value:this.pos});for(var o=0;o<this.others.length;o++)this.others[o]._emit("change",{value:this.others[o]})}this.$updating=!1},this.onCursorChange=function(e){if(this.$updating||!this.session)return;var t=this.session.selection.getCursor();t.row===this.pos.row&&t.column>=this.pos.column&&t.column<=this.pos.column+this.length?(this.showOtherMarkers(),this._emit("cursorEnter",e)):(this.hideOtherMarkers(),this._emit("cursorLeave",e))},this.detach=function(){this.session.removeMarker(this.markerId),this.hideOtherMarkers(),this.doc.removeEventListener("change",this.$onUpdate),this.session.selection.removeEventListener("changeCursor",this.$onCursorChange),this.pos.detach();for(var e=0;e<this.others.length;e++)this.others[e].detach();this.session.setUndoSelect(!0),this.session=null},this.cancel=function(){if(this.$undoStackDepth===-1)throw Error("Canceling placeholders only supported with undo manager attached to session.");var e=this.session.getUndoManager(),t=(e.$undoStack||e.$undostack).length-this.$undoStackDepth;for(var n=0;n<t;n++)e.undo(!0);this.selectionBefore&&this.session.selection.fromJSON(this.selectionBefore)}}).call(o.prototype),t.PlaceHolder=o}),ace.define("ace/mouse/multi_select_handler",["require","exports","module","ace/lib/event","ace/lib/useragent"],function(e,t,n){function s(e,t){return e.row==t.row&&e.column==t.column}function o(e){var t=e.domEvent,n=t.altKey,o=t.shiftKey,u=t.ctrlKey,a=e.getAccelKey(),f=e.getButton();u&&i.isMac&&(f=t.button);if(e.editor.inMultiSelectMode&&f==2){e.editor.textInput.onContextMenu(e.domEvent);return}if(!u&&!n&&!a){f===0&&e.editor.inMultiSelectMode&&e.editor.exitMultiSelectMode();return}if(f!==0)return;var l=e.editor,c=l.selection,h=l.inMultiSelectMode,p=e.getDocumentPosition(),d=c.getCursor(),v=e.inSelection()||c.isEmpty()&&s(p,d),m=e.x,g=e.y,y=function(e){m=e.clientX,g=e.clientY},b=l.session,w=l.renderer.pixelToScreenCoordinates(m,g),E=w,S;if(l.$mouseHandler.$enableJumpToDef)u&&n||a&&n?S="add":n&&(S="block");else if(a&&!n){S="add";if(!h&&o)return}else n&&(S="block");S&&i.isMac&&t.ctrlKey&&l.$mouseHandler.cancelContextMenu();if(S=="add"){if(!h&&v)return;if(!h){var x=c.toOrientedRange();l.addSelectionMarker(x)}var T=c.rangeList.rangeAtPoint(p);l.$blockScrolling++,l.inVirtualSelectionMode=!0,o&&(T=null,x=c.ranges[0],l.removeSelectionMarker(x)),l.once("mouseup",function(){var e=c.toOrientedRange();T&&e.isEmpty()&&s(T.cursor,e.cursor)?c.substractPoint(e.cursor):(o?c.substractPoint(x.cursor):x&&(l.removeSelectionMarker(x),c.addRange(x)),c.addRange(e)),l.$blockScrolling--,l.inVirtualSelectionMode=!1})}else if(S=="block"){e.stop(),l.inVirtualSelectionMode=!0;var N,C=[],k=function(){var e=l.renderer.pixelToScreenCoordinates(m,g),t=b.screenToDocumentPosition(e.row,e.column);if(s(E,e)&&s(t,c.lead))return;E=e,l.selection.moveToPosition(t),l.renderer.scrollCursorIntoView(),l.removeSelectionMarkers(C),C=c.rectangularRangeBlock(E,w),l.$mouseHandler.$clickSelection&&C.length==1&&C[0].isEmpty()&&(C[0]=l.$mouseHandler.$clickSelection.clone()),C.forEach(l.addSelectionMarker,l),l.updateSelectionMarkers()};h&&!a?c.toSingleRange():!h&&a&&(N=c.toOrientedRange(),l.addSelectionMarker(N)),o?w=b.documentToScreenPosition(c.lead):c.moveToPosition(p),E={row:-1,column:-1};var L=function(e){clearInterval(O),l.removeSelectionMarkers(C),C.length||(C=[c.toOrientedRange()]),l.$blockScrolling++,N&&(l.removeSelectionMarker(N),c.toSingleRange(N));for(var t=0;t<C.length;t++)c.addRange(C[t]);l.inVirtualSelectionMode=!1,l.$mouseHandler.$clickSelection=null,l.$blockScrolling--},A=k;r.capture(l.container,y,L);var O=setInterval(function(){A()},20);return e.preventDefault()}}var r=e("../lib/event"),i=e("../lib/useragent");t.onMouseDown=o}),ace.define("ace/commands/multi_select_commands",["require","exports","module","ace/keyboard/hash_handler"],function(e,t,n){t.defaultCommands=[{name:"addCursorAbove",exec:function(e){e.selectMoreLines(-1)},bindKey:{win:"Ctrl-Alt-Up",mac:"Ctrl-Alt-Up"},readonly:!0},{name:"addCursorBelow",exec:function(e){e.selectMoreLines(1)},bindKey:{win:"Ctrl-Alt-Down",mac:"Ctrl-Alt-Down"},readonly:!0},{name:"addCursorAboveSkipCurrent",exec:function(e){e.selectMoreLines(-1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Up",mac:"Ctrl-Alt-Shift-Up"},readonly:!0},{name:"addCursorBelowSkipCurrent",exec:function(e){e.selectMoreLines(1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Down",mac:"Ctrl-Alt-Shift-Down"},readonly:!0},{name:"selectMoreBefore",exec:function(e){e.selectMore(-1)},bindKey:{win:"Ctrl-Alt-Left",mac:"Ctrl-Alt-Left"},readonly:!0},{name:"selectMoreAfter",exec:function(e){e.selectMore(1)},bindKey:{win:"Ctrl-Alt-Right",mac:"Ctrl-Alt-Right"},readonly:!0},{name:"selectNextBefore",exec:function(e){e.selectMore(-1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Left",mac:"Ctrl-Alt-Shift-Left"},readonly:!0},{name:"selectNextAfter",exec:function(e){e.selectMore(1,!0)},bindKey:{win:"Ctrl-Alt-Shift-Right",mac:"Ctrl-Alt-Shift-Right"},readonly:!0},{name:"splitIntoLines",exec:function(e){e.multiSelect.splitIntoLines()},bindKey:{win:"Ctrl-Alt-L",mac:"Ctrl-Alt-L"},readonly:!0},{name:"alignCursors",exec:function(e){e.alignCursors()},bindKey:{win:"Ctrl-Alt-A",mac:"Ctrl-Alt-A"}},{name:"findAll",exec:function(e){e.findAll()},bindKey:{win:"Ctrl-Alt-K",mac:"Ctrl-Alt-G"},readonly:!0}],t.multiSelectCommands=[{name:"singleSelection",bindKey:"esc",exec:function(e){e.exitMultiSelectMode()},readonly:!0,isAvailable:function(e){return e&&e.inMultiSelectMode}}];var r=e("../keyboard/hash_handler").HashHandler;t.keyboardHandler=new r(t.multiSelectCommands)}),ace.define("ace/multi_select",["require","exports","module","ace/range_list","ace/range","ace/selection","ace/mouse/multi_select_handler","ace/lib/event","ace/lib/lang","ace/commands/multi_select_commands","ace/search","ace/edit_session","ace/editor","ace/config"],function(e,t,n){function h(e,t,n){return c.$options.wrap=!0,c.$options.needle=t,c.$options.backwards=n==-1,c.find(e)}function v(e,t){return e.row==t.row&&e.column==t.column}function m(e){if(e.$multiselectOnSessionChange)return;e.$onAddRange=e.$onAddRange.bind(e),e.$onRemoveRange=e.$onRemoveRange.bind(e),e.$onMultiSelect=e.$onMultiSelect.bind(e),e.$onSingleSelect=e.$onSingleSelect.bind(e),e.$multiselectOnSessionChange=t.onSessionChange.bind(e),e.$checkMultiselectChange=e.$checkMultiselectChange.bind(e),e.$multiselectOnSessionChange(e),e.on("changeSession",e.$multiselectOnSessionChange),e.on("mousedown",o),e.commands.addCommands(f.defaultCommands),g(e)}function g(e){function r(t){n&&(e.renderer.setMouseCursor(""),n=!1)}var t=e.textInput.getElement(),n=!1;u.addListener(t,"keydown",function(t){t.keyCode==18&&!(t.ctrlKey||t.shiftKey||t.metaKey)?n||(e.renderer.setMouseCursor("crosshair"),n=!0):n&&r()}),u.addListener(t,"keyup",r),u.addListener(t,"blur",r)}var r=e("./range_list").RangeList,i=e("./range").Range,s=e("./selection").Selection,o=e("./mouse/multi_select_handler").onMouseDown,u=e("./lib/event"),a=e("./lib/lang"),f=e("./commands/multi_select_commands");t.commands=f.defaultCommands.concat(f.multiSelectCommands);var l=e("./search").Search,c=new l,p=e("./edit_session").EditSession;(function(){this.getSelectionMarkers=function(){return this.$selectionMarkers}}).call(p.prototype),function(){this.ranges=null,this.rangeList=null,this.addRange=function(e,t){if(!e)return;if(!this.inMultiSelectMode&&this.rangeCount===0){var n=this.toOrientedRange();this.rangeList.add(n),this.rangeList.add(e);if(this.rangeList.ranges.length!=2)return this.rangeList.removeAll(),t||this.fromOrientedRange(e);this.rangeList.removeAll(),this.rangeList.add(n),this.$onAddRange(n)}e.cursor||(e.cursor=e.end);var r=this.rangeList.add(e);return this.$onAddRange(e),r.length&&this.$onRemoveRange(r),this.rangeCount>1&&!this.inMultiSelectMode&&(this._signal("multiSelect"),this.inMultiSelectMode=!0,this.session.$undoSelect=!1,this.rangeList.attach(this.session)),t||this.fromOrientedRange(e)},this.toSingleRange=function(e){e=e||this.ranges[0];var t=this.rangeList.removeAll();t.length&&this.$onRemoveRange(t),e&&this.fromOrientedRange(e)},this.substractPoint=function(e){var t=this.rangeList.substractPoint(e);if(t)return this.$onRemoveRange(t),t[0]},this.mergeOverlappingRanges=function(){var e=this.rangeList.merge();e.length?this.$onRemoveRange(e):this.ranges[0]&&this.fromOrientedRange(this.ranges[0])},this.$onAddRange=function(e){this.rangeCount=this.rangeList.ranges.length,this.ranges.unshift(e),this._signal("addRange",{range:e})},this.$onRemoveRange=function(e){this.rangeCount=this.rangeList.ranges.length;if(this.rangeCount==1&&this.inMultiSelectMode){var t=this.rangeList.ranges.pop();e.push(t),this.rangeCount=0}for(var n=e.length;n--;){var r=this.ranges.indexOf(e[n]);this.ranges.splice(r,1)}this._signal("removeRange",{ranges:e}),this.rangeCount===0&&this.inMultiSelectMode&&(this.inMultiSelectMode=!1,this._signal("singleSelect"),this.session.$undoSelect=!0,this.rangeList.detach(this.session)),t=t||this.ranges[0],t&&!t.isEqual(this.getRange())&&this.fromOrientedRange(t)},this.$initRangeList=function(){if(this.rangeList)return;this.rangeList=new r,this.ranges=[],this.rangeCount=0},this.getAllRanges=function(){return this.rangeCount?this.rangeList.ranges.concat():[this.getRange()]},this.splitIntoLines=function(){if(this.rangeCount>1){var e=this.rangeList.ranges,t=e[e.length-1],n=i.fromPoints(e[0].start,t.end);this.toSingleRange(),this.setSelectionRange(n,t.cursor==t.start)}else{var n=this.getRange(),r=this.isBackwards(),s=n.start.row,o=n.end.row;if(s==o){if(r)var u=n.end,a=n.start;else var u=n.start,a=n.end;this.addRange(i.fromPoints(a,a)),this.addRange(i.fromPoints(u,u));return}var f=[],l=this.getLineRange(s,!0);l.start.column=n.start.column,f.push(l);for(var c=s+1;c<o;c++)f.push(this.getLineRange(c,!0));l=this.getLineRange(o,!0),l.end.column=n.end.column,f.push(l),f.forEach(this.addRange,this)}},this.toggleBlockSelection=function(){if(this.rangeCount>1){var e=this.rangeList.ranges,t=e[e.length-1],n=i.fromPoints(e[0].start,t.end);this.toSingleRange(),this.setSelectionRange(n,t.cursor==t.start)}else{var r=this.session.documentToScreenPosition(this.selectionLead),s=this.session.documentToScreenPosition(this.selectionAnchor),o=this.rectangularRangeBlock(r,s);o.forEach(this.addRange,this)}},this.rectangularRangeBlock=function(e,t,n){var r=[],s=e.column<t.column;if(s)var o=e.column,u=t.column;else var o=t.column,u=e.column;var a=e.row<t.row;if(a)var f=e.row,l=t.row;else var f=t.row,l=e.row;o<0&&(o=0),f<0&&(f=0),f==l&&(n=!0);for(var c=f;c<=l;c++){var h=i.fromPoints(this.session.screenToDocumentPosition(c,o),this.session.screenToDocumentPosition(c,u));if(h.isEmpty()){if(p&&v(h.end,p))break;var p=h.end}h.cursor=s?h.start:h.end,r.push(h)}a&&r.reverse();if(!n){var d=r.length-1;while(r[d].isEmpty()&&d>0)d--;if(d>0){var m=0;while(r[m].isEmpty())m++}for(var g=d;g>=m;g--)r[g].isEmpty()&&r.splice(g,1)}return r}}.call(s.prototype);var d=e("./editor").Editor;(function(){this.updateSelectionMarkers=function(){this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.addSelectionMarker=function(e){e.cursor||(e.cursor=e.end);var t=this.getSelectionStyle();return e.marker=this.session.addMarker(e,"ace_selection",t),this.session.$selectionMarkers.push(e),this.session.selectionMarkerCount=this.session.$selectionMarkers.length,e},this.removeSelectionMarker=function(e){if(!e.marker)return;this.session.removeMarker(e.marker);var t=this.session.$selectionMarkers.indexOf(e);t!=-1&&this.session.$selectionMarkers.splice(t,1),this.session.selectionMarkerCount=this.session.$selectionMarkers.length},this.removeSelectionMarkers=function(e){var t=this.session.$selectionMarkers;for(var n=e.length;n--;){var r=e[n];if(!r.marker)continue;this.session.removeMarker(r.marker);var i=t.indexOf(r);i!=-1&&t.splice(i,1)}this.session.selectionMarkerCount=t.length},this.$onAddRange=function(e){this.addSelectionMarker(e.range),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onRemoveRange=function(e){this.removeSelectionMarkers(e.ranges),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onMultiSelect=function(e){if(this.inMultiSelectMode)return;this.inMultiSelectMode=!0,this.setStyle("ace_multiselect"),this.keyBinding.addKeyboardHandler(f.keyboardHandler),this.commands.setDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers()},this.$onSingleSelect=function(e){if(this.session.multiSelect.inVirtualMode)return;this.inMultiSelectMode=!1,this.unsetStyle("ace_multiselect"),this.keyBinding.removeKeyboardHandler(f.keyboardHandler),this.commands.removeDefaultHandler("exec",this.$onMultiSelectExec),this.renderer.updateCursor(),this.renderer.updateBackMarkers(),this._emit("changeSelection")},this.$onMultiSelectExec=function(e){var t=e.command,n=e.editor;if(!n.multiSelect)return;if(!t.multiSelectAction){var r=t.exec(n,e.args||{});n.multiSelect.addRange(n.multiSelect.toOrientedRange()),n.multiSelect.mergeOverlappingRanges()}else t.multiSelectAction=="forEach"?r=n.forEachSelection(t,e.args):t.multiSelectAction=="forEachLine"?r=n.forEachSelection(t,e.args,!0):t.multiSelectAction=="single"?(n.exitMultiSelectMode(),r=t.exec(n,e.args||{})):r=t.multiSelectAction(n,e.args||{});return r},this.forEachSelection=function(e,t,n){if(this.inVirtualSelectionMode)return;var r=n&&n.keepOrder,i=n==1||n&&n.$byLines,o=this.session,u=this.selection,a=u.rangeList,f=(r?u:a).ranges,l;if(!f.length)return e.exec?e.exec(this,t||{}):e(this,t||{});var c=u._eventRegistry;u._eventRegistry={};var h=new s(o);this.inVirtualSelectionMode=!0;for(var p=f.length;p--;){if(i)while(p>0&&f[p].start.row==f[p-1].end.row)p--;h.fromOrientedRange(f[p]),h.index=p,this.selection=o.selection=h;var d=e.exec?e.exec(this,t||{}):e(this,t||{});!l&&d!==undefined&&(l=d),h.toOrientedRange(f[p])}h.detach(),this.selection=o.selection=u,this.inVirtualSelectionMode=!1,u._eventRegistry=c,u.mergeOverlappingRanges();var v=this.renderer.$scrollAnimation;return this.onCursorChange(),this.onSelectionChange(),v&&v.from==v.to&&this.renderer.animateScrolling(v.from),l},this.exitMultiSelectMode=function(){if(!this.inMultiSelectMode||this.inVirtualSelectionMode)return;this.multiSelect.toSingleRange()},this.getSelectedText=function(){var e="";if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){var t=this.multiSelect.rangeList.ranges,n=[];for(var r=0;r<t.length;r++)n.push(this.session.getTextRange(t[r]));var i=this.session.getDocument().getNewLineCharacter();e=n.join(i),e.length==(n.length-1)*i.length&&(e="")}else this.selection.isEmpty()||(e=this.session.getTextRange(this.getSelectionRange()));return e},this.$checkMultiselectChange=function(e,t){if(this.inMultiSelectMode&&!this.inVirtualSelectionMode){var n=this.multiSelect.ranges[0];if(this.multiSelect.isEmpty()&&t==this.multiSelect.anchor)return;var r=t==this.multiSelect.anchor?n.cursor==n.start?n.end:n.start:n.cursor;v(r,t)||this.multiSelect.toSingleRange(this.multiSelect.toOrientedRange())}},this.onPaste=function(e){if(this.$readOnly)return;var t={text:e};this._signal("paste",t),e=t.text;if(!this.inMultiSelectMode||this.inVirtualSelectionMode)return this.insert(e);var n=e.split(/\r\n|\r|\n/),r=this.selection.rangeList.ranges;if(n.length>r.length||n.length<2||!n[1])return this.commands.exec("insertstring",this,e);for(var i=r.length;i--;){var s=r[i];s.isEmpty()||this.session.remove(s),this.session.insert(s.start,n[i])}},this.findAll=function(e,t,n){t=t||{},t.needle=e||t.needle;if(t.needle==undefined){var r=this.selection.isEmpty()?this.selection.getWordRange():this.selection.getRange();t.needle=this.session.getTextRange(r)}this.$search.set(t);var i=this.$search.findAll(this.session);if(!i.length)return 0;this.$blockScrolling+=1;var s=this.multiSelect;n||s.toSingleRange(i[0]);for(var o=i.length;o--;)s.addRange(i[o],!0);return r&&s.rangeList.rangeAtPoint(r.start)&&s.addRange(r,!0),this.$blockScrolling-=1,i.length},this.selectMoreLines=function(e,t){var n=this.selection.toOrientedRange(),r=n.cursor==n.end,s=this.session.documentToScreenPosition(n.cursor);this.selection.$desiredColumn&&(s.column=this.selection.$desiredColumn);var o=this.session.screenToDocumentPosition(s.row+e,s.column);if(!n.isEmpty())var u=this.session.documentToScreenPosition(r?n.end:n.start),a=this.session.screenToDocumentPosition(u.row+e,u.column);else var a=o;if(r){var f=i.fromPoints(o,a);f.cursor=f.start}else{var f=i.fromPoints(a,o);f.cursor=f.end}f.desiredColumn=s.column;if(!this.selection.inMultiSelectMode)this.selection.addRange(n);else if(t)var l=n.cursor;this.selection.addRange(f),l&&this.selection.substractPoint(l)},this.transposeSelections=function(e){var t=this.session,n=t.multiSelect,r=n.ranges;for(var i=r.length;i--;){var s=r[i];if(s.isEmpty()){var o=t.getWordRange(s.start.row,s.start.column);s.start.row=o.start.row,s.start.column=o.start.column,s.end.row=o.end.row,s.end.column=o.end.column}}n.mergeOverlappingRanges();var u=[];for(var i=r.length;i--;){var s=r[i];u.unshift(t.getTextRange(s))}e<0?u.unshift(u.pop()):u.push(u.shift());for(var i=r.length;i--;){var s=r[i],o=s.clone();t.replace(s,u[i]),s.start.row=o.start.row,s.start.column=o.start.column}},this.selectMore=function(e,t,n){var r=this.session,i=r.multiSelect,s=i.toOrientedRange();if(s.isEmpty()){s=r.getWordRange(s.start.row,s.start.column),s.cursor=e==-1?s.start:s.end,this.multiSelect.addRange(s);if(n)return}var o=r.getTextRange(s),u=h(r,o,e);u&&(u.cursor=e==-1?u.start:u.end,this.$blockScrolling+=1,this.session.unfold(u),this.multiSelect.addRange(u),this.$blockScrolling-=1,this.renderer.scrollCursorIntoView(null,.5)),t&&this.multiSelect.substractPoint(s.cursor)},this.alignCursors=function(){var e=this.session,t=e.multiSelect,n=t.ranges,r=-1,s=n.filter(function(e){if(e.cursor.row==r)return!0;r=e.cursor.row});if(!n.length||s.length==n.length-1){var o=this.selection.getRange(),u=o.start.row,f=o.end.row,l=u==f;if(l){var c=this.session.getLength(),h;do h=this.session.getLine(f);while(/[=:]/.test(h)&&++f<c);do h=this.session.getLine(u);while(/[=:]/.test(h)&&--u>0);u<0&&(u=0),f>=c&&(f=c-1)}var p=this.session.doc.removeLines(u,f);p=this.$reAlignText(p,l),this.session.doc.insert({row:u,column:0},p.join("\n")+"\n"),l||(o.start.column=0,o.end.column=p[p.length-1].length),this.selection.setRange(o)}else{s.forEach(function(e){t.substractPoint(e.cursor)});var d=0,v=Infinity,m=n.map(function(t){var n=t.cursor,r=e.getLine(n.row),i=r.substr(n.column).search(/\S/g);return i==-1&&(i=0),n.column>d&&(d=n.column),i<v&&(v=i),i});n.forEach(function(t,n){var r=t.cursor,s=d-r.column,o=m[n]-v;s>o?e.insert(r,a.stringRepeat(" ",s-o)):e.remove(new i(r.row,r.column,r.row,r.column-s+o)),t.start.column=t.end.column=d,t.start.row=t.end.row=r.row,t.cursor=t.end}),t.fromOrientedRange(n[0]),this.renderer.updateCursor(),this.renderer.updateBackMarkers()}},this.$reAlignText=function(e,t){function u(e){return a.stringRepeat(" ",e)}function f(e){return e[2]?u(i)+e[2]+u(s-e[2].length+o)+e[4].replace(/^([=:])\s+/,"$1 "):e[0]}function l(e){return e[2]?u(i+s-e[2].length)+e[2]+u(o," ")+e[4].replace(/^([=:])\s+/,"$1 "):e[0]}function c(e){return e[2]?u(i)+e[2]+u(o)+e[4].replace(/^([=:])\s+/,"$1 "):e[0]}var n=!0,r=!0,i,s,o;return e.map(function(e){var t=e.match(/(\s*)(.*?)(\s*)([=:].*)/);return t?i==null?(i=t[1].length,s=t[2].length,o=t[3].length,t):(i+s+o!=t[1].length+t[2].length+t[3].length&&(r=!1),i!=t[1].length&&(n=!1),i>t[1].length&&(i=t[1].length),s<t[2].length&&(s=t[2].length),o>t[3].length&&(o=t[3].length),t):[e]}).map(t?f:n?r?l:f:c)}}).call(d.prototype),t.onSessionChange=function(e){var t=e.session;t&&!t.multiSelect&&(t.$selectionMarkers=[],t.selection.$initRangeList(),t.multiSelect=t.selection),this.multiSelect=t&&t.multiSelect;var n=e.oldSession;n&&(n.multiSelect.off("addRange",this.$onAddRange),n.multiSelect.off("removeRange",this.$onRemoveRange),n.multiSelect.off("multiSelect",this.$onMultiSelect),n.multiSelect.off("singleSelect",this.$onSingleSelect),n.multiSelect.lead.off("change",this.$checkMultiselectChange),n.multiSelect.anchor.off("change",this.$checkMultiselectChange)),t&&(t.multiSelect.on("addRange",this.$onAddRange),t.multiSelect.on("removeRange",this.$onRemoveRange),t.multiSelect.on("multiSelect",this.$onMultiSelect),t.multiSelect.on("singleSelect",this.$onSingleSelect),t.multiSelect.lead.on("change",this.$checkMultiselectChange),t.multiSelect.anchor.on("change",this.$checkMultiselectChange)),t&&this.inMultiSelectMode!=t.selection.inMultiSelectMode&&(t.selection.inMultiSelectMode?this.$onMultiSelect():this.$onSingleSelect())},t.MultiSelect=m,e("./config").defineOptions(d.prototype,"editor",{enableMultiselect:{set:function(e){m(this),e?(this.on("changeSession",this.$multiselectOnSessionChange),this.on("mousedown",o)):(this.off("changeSession",this.$multiselectOnSessionChange),this.off("mousedown",o))},value:!0}})}),ace.define("ace/mode/folding/fold_mode",["require","exports","module","ace/range"],function(e,t,n){"use strict";var r=e("../../range").Range,i=t.FoldMode=function(){};(function(){this.foldingStartMarker=null,this.foldingStopMarker=null,this.getFoldWidget=function(e,t,n){var r=e.getLine(n);return this.foldingStartMarker.test(r)?"start":t=="markbeginend"&&this.foldingStopMarker&&this.foldingStopMarker.test(r)?"end":""},this.getFoldWidgetRange=function(e,t,n){return null},this.indentationBlock=function(e,t,n){var i=/\S/,s=e.getLine(t),o=s.search(i);if(o==-1)return;var u=n||s.length,a=e.getLength(),f=t,l=t;while(++t<a){var c=e.getLine(t).search(i);if(c==-1)continue;if(c<=o)break;l=t}if(l>f){var h=e.getLine(l).length;return new r(f,u,l,h)}},this.openingBracketBlock=function(e,t,n,i,s){var o={row:n,column:i+1},u=e.$findClosingBracket(t,o,s);if(!u)return;var a=e.foldWidgets[u.row];return a==null&&(a=e.getFoldWidget(u.row)),a=="start"&&u.row>o.row&&(u.row--,u.column=e.getLine(u.row).length),r.fromPoints(o,u)},this.closingBracketBlock=function(e,t,n,i,s){var o={row:n,column:i},u=e.$findOpeningBracket(t,o);if(!u)return;return u.column++,o.column--,r.fromPoints(u,o)}}).call(i.prototype)}),ace.define("ace/theme/textmate",["require","exports","module","ace/lib/dom"],function(e,t,n){"use strict";t.isDark=!1,t.cssClass="ace-tm",t.cssText='.ace-tm .ace_gutter {background: #f0f0f0;color: #333;}.ace-tm .ace_print-margin {width: 1px;background: #e8e8e8;}.ace-tm .ace_fold {background-color: #6B72E6;}.ace-tm {background-color: #FFFFFF;color: black;}.ace-tm .ace_cursor {color: black;}.ace-tm .ace_invisible {color: rgb(191, 191, 191);}.ace-tm .ace_storage,.ace-tm .ace_keyword {color: blue;}.ace-tm .ace_constant {color: rgb(197, 6, 11);}.ace-tm .ace_constant.ace_buildin {color: rgb(88, 72, 246);}.ace-tm .ace_constant.ace_language {color: rgb(88, 92, 246);}.ace-tm .ace_constant.ace_library {color: rgb(6, 150, 14);}.ace-tm .ace_invalid {background-color: rgba(255, 0, 0, 0.1);color: red;}.ace-tm .ace_support.ace_function {color: rgb(60, 76, 114);}.ace-tm .ace_support.ace_constant {color: rgb(6, 150, 14);}.ace-tm .ace_support.ace_type,.ace-tm .ace_support.ace_class {color: rgb(109, 121, 222);}.ace-tm .ace_keyword.ace_operator {color: rgb(104, 118, 135);}.ace-tm .ace_string {color: rgb(3, 106, 7);}.ace-tm .ace_comment {color: rgb(76, 136, 107);}.ace-tm .ace_comment.ace_doc {color: rgb(0, 102, 255);}.ace-tm .ace_comment.ace_doc.ace_tag {color: rgb(128, 159, 191);}.ace-tm .ace_constant.ace_numeric {color: rgb(0, 0, 205);}.ace-tm .ace_variable {color: rgb(49, 132, 149);}.ace-tm .ace_xml-pe {color: rgb(104, 104, 91);}.ace-tm .ace_entity.ace_name.ace_function {color: #0000A2;}.ace-tm .ace_heading {color: rgb(12, 7, 255);}.ace-tm .ace_list {color:rgb(185, 6, 144);}.ace-tm .ace_meta.ace_tag {color:rgb(0, 22, 142);}.ace-tm .ace_string.ace_regex {color: rgb(255, 0, 0)}.ace-tm .ace_marker-layer .ace_selection {background: rgb(181, 213, 255);}.ace-tm.ace_multiselect .ace_selection.ace_start {box-shadow: 0 0 3px 0px white;border-radius: 2px;}.ace-tm .ace_marker-layer .ace_step {background: rgb(252, 255, 0);}.ace-tm .ace_marker-layer .ace_stack {background: rgb(164, 229, 101);}.ace-tm .ace_marker-layer .ace_bracket {margin: -1px 0 0 -1px;border: 1px solid rgb(192, 192, 192);}.ace-tm .ace_marker-layer .ace_active-line {background: rgba(0, 0, 0, 0.07);}.ace-tm .ace_gutter-active-line {background-color : #dcdcdc;}.ace-tm .ace_marker-layer .ace_selected-word {background: rgb(250, 250, 255);border: 1px solid rgb(200, 200, 250);}.ace-tm .ace_indent-guide {background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAE0lEQVQImWP4////f4bLly//BwAmVgd1/w11/gAAAABJRU5ErkJggg==") right repeat-y;}';var r=e("../lib/dom");r.importCssString(t.cssText,t.cssClass)}),ace.define("ace/line_widgets",["require","exports","module","ace/lib/oop","ace/lib/dom","ace/range"],function(e,t,n){"use strict";function o(e){this.session=e,this.session.widgetManager=this,this.session.getRowLength=this.getRowLength,this.session.$getWidgetScreenLength=this.$getWidgetScreenLength,this.updateOnChange=this.updateOnChange.bind(this),this.renderWidgets=this.renderWidgets.bind(this),this.measureWidgets=this.measureWidgets.bind(this),this.session._changedWidgets=[],this.detach=this.detach.bind(this),this.session.on("change",this.updateOnChange)}var r=e("./lib/oop"),i=e("./lib/dom"),s=e("./range").Range;(function(){this.getRowLength=function(e){var t;return this.lineWidgets?t=this.lineWidgets[e]&&this.lineWidgets[e].rowCount||0:t=0,!this.$useWrapMode||!this.$wrapData[e]?1+t:this.$wrapData[e].length+1+t},this.$getWidgetScreenLength=function(){var e=0;return this.lineWidgets.forEach(function(t){t&&t.rowCount&&(e+=t.rowCount)}),e},this.attach=function(e){e.widgetManager&&e.widgetManager!=this&&e.widgetManager.detach();if(this.editor==e)return;this.detach(),this.editor=e,this.editor.on("changeSession",this.detach),e.widgetManager=this,e.renderer.on("beforeRender",this.measureWidgets),e.renderer.on("afterRender",this.renderWidgets)},this.detach=function(e){if(e&&e.session==this.session)return;var t=this.editor;if(!t)return;t.off("changeSession",this.detach),this.editor=null,t.widgetManager=null,t.renderer.off("beforeRender",this.measureWidgets),t.renderer.off("afterRender",this.renderWidgets);var n=this.session.lineWidgets;n&&n.forEach(function(e){e&&e.el&&e.el.parentNode&&(e._inDocument=!1,e.el.parentNode.removeChild(e.el))})},this.updateOnChange=function(e){var t=this.session.lineWidgets;if(!t)return;var n=e.data,r=n.range,i=r.start.row,s=r.end.row-i;if(s!==0)if(n.action=="removeText"||n.action=="removeLines"){var o=t.splice(i+1,s);o.forEach(function(e){e&&this.removeLineWidget(e)},this),this.$updateRows()}else{var u=new Array(s);u.unshift(i,0),t.splice.apply(t,u),this.$updateRows()}},this.$updateRows=function(){var e=this.session.lineWidgets;if(!e)return;var t=!0;e.forEach(function(e,n){e&&(t=!1,e.row=n)}),t&&(this.session.lineWidgets=null)},this.addLineWidget=function(e){this.session.lineWidgets||(this.session.lineWidgets=new Array(this.session.getLength())),this.session.lineWidgets[e.row]=e;var t=this.editor.renderer;return e.html&&!e.el&&(e.el=i.createElement("div"),e.el.innerHTML=e.html),e.el&&(i.addCssClass(e.el,"ace_lineWidgetContainer"),e.el.style.position="absolute",e.el.style.zIndex=5,t.container.appendChild(e.el),e._inDocument=!0),e.coverGutter||(e.el.style.zIndex=3),e.pixelHeight||(e.pixelHeight=e.el.offsetHeight),e.rowCount==null&&(e.rowCount=e.pixelHeight/t.layerConfig.lineHeight),this.session._emit("changeFold",{data:{start:{row:e.row}}}),this.$updateRows(),this.renderWidgets(null,t),e},this.removeLineWidget=function(e){e._inDocument=!1,e.el&&e.el.parentNode&&e.el.parentNode.removeChild(e.el);if(e.editor&&e.editor.destroy)try{e.editor.destroy()}catch(t){}this.session.lineWidgets&&(this.session.lineWidgets[e.row]=undefined),this.session._emit("changeFold",{data:{start:{row:e.row}}}),this.$updateRows()},this.onWidgetChanged=function(e){this.session._changedWidgets.push(e),this.editor&&this.editor.renderer.updateFull()},this.measureWidgets=function(e,t){var n=this.session._changedWidgets,r=t.layerConfig;if(!n||!n.length)return;var i=Infinity;for(var s=0;s<n.length;s++){var o=n[s];o._inDocument||(o._inDocument=!0,t.container.appendChild(o.el)),o.h=o.el.offsetHeight,o.fixedWidth||(o.w=o.el.offsetWidth,o.screenWidth=Math.ceil(o.w/r.characterWidth));var u=o.h/r.lineHeight;o.coverLine&&(u-=this.session.getRowLineCount(o.row),u<0&&(u=0)),o.rowCount!=u&&(o.rowCount=u,o.row<i&&(i=o.row))}i!=Infinity&&(this.session._emit("changeFold",{data:{start:{row:i}}}),this.session.lineWidgetWidth=null),this.session._changedWidgets=[]},this.renderWidgets=function(e,t){var n=t.layerConfig,r=this.session.lineWidgets;if(!r)return;var i=Math.min(this.firstRow,n.firstRow),s=Math.max(this.lastRow,n.lastRow,r.length);while(i>0&&!r[i])i--;this.firstRow=n.firstRow,this.lastRow=n.lastRow,t.$cursorLayer.config=n;for(var o=i;o<=s;o++){var u=r[o];if(!u||!u.el)continue;u._inDocument||(u._inDocument=!0,t.container.appendChild(u.el));var a=t.$cursorLayer.getPixelPosition({row:o,column:0},!0).top;u.coverLine||(a+=n.lineHeight*this.session.getRowLineCount(u.row)),u.el.style.top=a-n.offset+"px";var f=u.coverGutter?0:t.gutterWidth;u.fixedWidth||(f-=t.scrollLeft),u.el.style.left=f+"px",u.fixedWidth?u.el.style.right=t.scrollBar.getWidth()+"px":u.el.style.right=""}}}).call(o.prototype),t.LineWidgets=o}),ace.define("ace/ext/error_marker",["require","exports","module","ace/line_widgets","ace/lib/dom","ace/range"],function(e,t,n){"use strict";function o(e,t,n){var r=0,i=e.length-1;while(r<=i){var s=r+i>>1,o=n(t,e[s]);if(o>0)r=s+1;else{if(!(o<0))return s;i=s-1}}return-(r+1)}function u(e,t,n){var r=e.getAnnotations().sort(s.comparePoints);if(!r.length)return;var i=o(r,{row:t,column:-1},s.comparePoints);i<0&&(i=-i-1),i>=r.length-1?i=n>0?0:r.length-1:i===0&&n<0&&(i=r.length-1);var u=r[i];if(!u||!n)return;if(u.row===t){do u=r[i+=n];while(u&&u.row===t);if(!u)return r.slice()}var a=[];t=u.row;do a[n<0?"unshift":"push"](u),u=r[i+=n];while(u&&u.row==t);return a.length&&a}var r=e("ace/line_widgets").LineWidgets,i=e("ace/lib/dom"),s=e("ace/range").Range;t.showErrorMarker=function(e,t){var n=e.session;n.widgetManager||(n.widgetManager=new r(n),n.widgetManager.attach(e));var s=e.getCursorPosition(),o=s.row,a=n.lineWidgets&&n.lineWidgets[o];a?a.destroy():o-=t;var f=u(n,o,t),l;if(f){var c=f[0];s.column=(c.pos&&typeof c.column!="number"?c.pos.sc:c.column)||0,s.row=c.row,l=e.renderer.$gutterLayer.$annotations[s.row]}else{if(a)return;l={text:["Looks good!"],className:"ace_ok"}}e.session.unfold(s.row),e.selection.moveToPosition(s);var h={row:s.row,fixedWidth:!0,coverGutter:!0,el:i.createElement("div")},p=h.el.appendChild(i.createElement("div")),d=h.el.appendChild(i.createElement("div"));d.className="error_widget_arrow "+l.className;var v=e.renderer.$cursorLayer.getPixelPosition(s).left;d.style.left=v+e.renderer.gutterWidth-5+"px",h.el.className="error_widget_wrapper",p.className="error_widget "+l.className,p.innerHTML=l.text.join("<br>"),p.appendChild(i.createElement("div"));var m=function(e,t,n){if(t===0&&(n==="esc"||n==="return"))return h.destroy(),{command:"null"}};h.destroy=function(){if(e.$mouseHandler.isMousePressed)return;e.keyBinding.removeKeyboardHandler(m),n.widgetManager.removeLineWidget(h),e.off("changeSelection",h.destroy),e.off("changeSession",h.destroy),e.off("mouseup",h.destroy),e.off("change",h.destroy)},e.keyBinding.addKeyboardHandler(m),e.on("changeSelection",h.destroy),e.on("changeSession",h.destroy),e.on("mouseup",h.destroy),e.on("change",h.destroy),e.session.widgetManager.addLineWidget(h),h.el.onmousedown=e.focus.bind(e),e.renderer.scrollCursorIntoView(null,.5,{bottom:h.el.offsetHeight})},i.importCssString(" .error_widget_wrapper { background: inherit; color: inherit; border:none } .error_widget { border-top: solid 2px; border-bottom: solid 2px; margin: 5px 0; padding: 10px 40px; white-space: pre-wrap; } .error_widget.ace_error, .error_widget_arrow.ace_error{ border-color: #ff5a5a } .error_widget.ace_warning, .error_widget_arrow.ace_warning{ border-color: #F1D817 } .error_widget.ace_info, .error_widget_arrow.ace_info{ border-color: #5a5a5a } .error_widget.ace_ok, .error_widget_arrow.ace_ok{ border-color: #5aaa5a } .error_widget_arrow { position: absolute; border: solid 5px; border-top-color: transparent!important; border-right-color: transparent!important; border-left-color: transparent!important; top: -5px; }","")}),ace.define("ace/ace",["require","exports","module","ace/lib/fixoldbrowsers","ace/lib/dom","ace/lib/event","ace/editor","ace/edit_session","ace/undomanager","ace/virtual_renderer","ace/worker/worker_client","ace/keyboard/hash_handler","ace/placeholder","ace/multi_select","ace/mode/folding/fold_mode","ace/theme/textmate","ace/ext/error_marker","ace/config"],function(e,t,n){"use strict";e("./lib/fixoldbrowsers");var r=e("./lib/dom"),i=e("./lib/event"),s=e("./editor").Editor,o=e("./edit_session").EditSession,u=e("./undomanager").UndoManager,a=e("./virtual_renderer").VirtualRenderer;e("./worker/worker_client"),e("./keyboard/hash_handler"),e("./placeholder"),e("./multi_select"),e("./mode/folding/fold_mode"),e("./theme/textmate"),e("./ext/error_marker"),t.config=e("./config"),t.require=e,t.edit=function(e){if(typeof e=="string"){var n=e;e=document.getElementById(n);if(!e)throw new Error("ace.edit can't find div #"+n)}if(e&&e.env&&e.env.editor instanceof s)return e.env.editor;var o="";if(e&&/input|textarea/i.test(e.tagName)){var u=e;o=u.value,e=r.createElement("pre"),u.parentNode.replaceChild(e,u)}else o=r.getInnerText(e),e.innerHTML="";var f=t.createEditSession(o),l=new s(new a(e));l.setSession(f);var c={document:f,editor:l,onResize:l.resize.bind(l,null)};return u&&(c.textarea=u),i.addListener(window,"resize",c.onResize),l.on("destroy",function(){i.removeListener(window,"resize",c.onResize),c.editor.container.env=null}),l.container.env=l.env=c,l},t.createEditSession=function(e,t){var n=new o(e,t);return n.setUndoManager(new u),n},t.EditSession=o,t.UndoManager=u});+ (function() {+ ace.require(["ace/ace"], function(a) {+ a && a.config.init(true);+ if (!window.ace)+ window.ace = a;+ for (var key in a) if (a.hasOwnProperty(key))+ window.ace[key] = a[key];+ });+ })();+\ No newline at end of filediff --git a/app/assets/javascripts/blazer/ace/ext-language_tools.js b/app/assets/javascripts/blazer/ace/ext-language_tools.jsnew file mode 100755index 00000000..335dc8f6--- /dev/null+++ b/app/assets/javascripts/blazer/ace/ext-language_tools.js@@ -0,0 +1,5 @@+ace.define("ace/snippets",["require","exports","module","ace/lib/oop","ace/lib/event_emitter","ace/lib/lang","ace/range","ace/anchor","ace/keyboard/hash_handler","ace/tokenizer","ace/lib/dom","ace/editor"],function(e,t,n){"use strict";var r=e("./lib/oop"),i=e("./lib/event_emitter").EventEmitter,s=e("./lib/lang"),o=e("./range").Range,u=e("./anchor").Anchor,a=e("./keyboard/hash_handler").HashHandler,f=e("./tokenizer").Tokenizer,l=o.comparePoints,c=function(){this.snippetMap={},this.snippetNameMap={}};(function(){r.implement(this,i),this.getTokenizer=function(){function e(e,t,n){return e=e.substr(1),/^\d+$/.test(e)&&!n.inFormatString?[{tabstopId:parseInt(e,10)}]:[{text:e}]}function t(e){return"(?:[^\\\\"+e+"]|\\\\.)"}return c.$tokenizer=new f({start:[{regex:/:/,onMatch:function(e,t,n){return n.length&&n[0].expectIf?(n[0].expectIf=!1,n[0].elseBranch=n[0],[n[0]]):":"}},{regex:/\\./,onMatch:function(e,t,n){var r=e[1];return r=="}"&&n.length?e=r:"`$\\".indexOf(r)!=-1?e=r:n.inFormatString&&(r=="n"?e="\n":r=="t"?e="\n":"ulULE".indexOf(r)!=-1&&(e={changeCase:r,local:r>"a"})),[e]}},{regex:/}/,onMatch:function(e,t,n){return[n.length?n.shift():e]}},{regex:/\$(?:\d+|\w+)/,onMatch:e},{regex:/\$\{[\dA-Z_a-z]+/,onMatch:function(t,n,r){var i=e(t.substr(1),n,r);return r.unshift(i[0]),i},next:"snippetVar"},{regex:/\n/,token:"newline",merge:!1}],snippetVar:[{regex:"\\|"+t("\\|")+"*\\|",onMatch:function(e,t,n){n[0].choices=e.slice(1,-1).split(",")},next:"start"},{regex:"/("+t("/")+"+)/(?:("+t("/")+"*)/)(\\w*):?",onMatch:function(e,t,n){var r=n[0];return r.fmtString=e,e=this.splitRegex.exec(e),r.guard=e[1],r.fmt=e[2],r.flag=e[3],""},next:"start"},{regex:"`"+t("`")+"*`",onMatch:function(e,t,n){return n[0].code=e.splice(1,-1),""},next:"start"},{regex:"\\?",onMatch:function(e,t,n){n[0]&&(n[0].expectIf=!0)},next:"start"},{regex:"([^:}\\\\]|\\\\.)*:?",token:"",next:"start"}],formatString:[{regex:"/("+t("/")+"+)/",token:"regex"},{regex:"",onMatch:function(e,t,n){n.inFormatString=!0},next:"start"}]}),c.prototype.getTokenizer=function(){return c.$tokenizer},c.$tokenizer},this.tokenizeTmSnippet=function(e,t){return this.getTokenizer().getLineTokens(e,t).tokens.map(function(e){return e.value||e})},this.$getDefaultValue=function(e,t){if(/^[A-Z]\d+$/.test(t)){var n=t.substr(1);return(this.variables[t[0]+"__"]||{})[n]}if(/^\d+$/.test(t))return(this.variables.__||{})[t];t=t.replace(/^TM_/,"");if(!e)return;var r=e.session;switch(t){case"CURRENT_WORD":var i=r.getWordRange();case"SELECTION":case"SELECTED_TEXT":return r.getTextRange(i);case"CURRENT_LINE":return r.getLine(e.getCursorPosition().row);case"PREV_LINE":return r.getLine(e.getCursorPosition().row-1);case"LINE_INDEX":return e.getCursorPosition().column;case"LINE_NUMBER":return e.getCursorPosition().row+1;case"SOFT_TABS":return r.getUseSoftTabs()?"YES":"NO";case"TAB_SIZE":return r.getTabSize();case"FILENAME":case"FILEPATH":return"";case"FULLNAME":return"Ace"}},this.variables={},this.getVariableValue=function(e,t){return this.variables.hasOwnProperty(t)?this.variables[t](e,t)||"":this.$getDefaultValue(e,t)||""},this.tmStrFormat=function(e,t,n){var r=t.flag||"",i=t.guard;i=new RegExp(i,r.replace(/[^gi]/,""));var s=this.tokenizeTmSnippet(t.fmt,"formatString"),o=this,u=e.replace(i,function(){o.variables.__=arguments;var e=o.resolveVariables(s,n),t="E";for(var r=0;r<e.length;r++){var i=e[r];if(typeof i=="object"){e[r]="";if(i.changeCase&&i.local){var u=e[r+1];u&&typeof u=="string"&&(i.changeCase=="u"?e[r]=u[0].toUpperCase():e[r]=u[0].toLowerCase(),e[r+1]=u.substr(1))}else i.changeCase&&(t=i.changeCase)}else t=="U"?e[r]=i.toUpperCase():t=="L"&&(e[r]=i.toLowerCase())}return e.join("")});return this.variables.__=null,u},this.resolveVariables=function(e,t){function o(t){var n=e.indexOf(t,r+1);n!=-1&&(r=n)}var n=[];for(var r=0;r<e.length;r++){var i=e[r];if(typeof i=="string")n.push(i);else{if(typeof i!="object")continue;if(i.skip)o(i);else{if(i.processed<r)continue;if(i.text){var s=this.getVariableValue(t,i.text);s&&i.fmtString&&(s=this.tmStrFormat(s,i)),i.processed=r,i.expectIf==null?s&&(n.push(s),o(i)):s?i.skip=i.elseBranch:o(i)}else i.tabstopId!=null?n.push(i):i.changeCase!=null&&n.push(i)}}}return n},this.insertSnippetForSelection=function(e,t){function f(e){var t=[];for(var n=0;n<e.length;n++){var r=e[n];if(typeof r=="object"){if(a[r.tabstopId])continue;var i=e.lastIndexOf(r,n-1);r=t[i]||{tabstopId:r.tabstopId}}t[n]=r}return t}var n=e.getCursorPosition(),r=e.session.getLine(n.row),i=e.session.getTabString(),s=r.match(/^\s*/)[0];n.column<s.length&&(s=s.slice(0,n.column));var o=this.tokenizeTmSnippet(t);o=this.resolveVariables(o,e),o=o.map(function(e){return e=="\n"?e+s:typeof e=="string"?e.replace(/\t/g,i):e});var u=[];o.forEach(function(e,t){if(typeof e!="object")return;var n=e.tabstopId,r=u[n];r||(r=u[n]=[],r.index=n,r.value="");if(r.indexOf(e)!==-1)return;r.push(e);var i=o.indexOf(e,t+1);if(i===-1)return;var s=o.slice(t+1,i),a=s.some(function(e){return typeof e=="object"});a&&!r.value?r.value=s:s.length&&(!r.value||typeof r.value!="string")&&(r.value=s.join(""))}),u.forEach(function(e){e.length=0});var a={};for(var l=0;l<o.length;l++){var c=o[l];if(typeof c!="object")continue;var p=c.tabstopId,d=o.indexOf(c,l+1);if(a[p]){a[p]===c&&(a[p]=null);continue}var v=u[p],m=typeof v.value=="string"?[v.value]:f(v.value);m.unshift(l+1,Math.max(0,d-l)),m.push(c),a[p]=c,o.splice.apply(o,m),v.indexOf(c)===-1&&v.push(c)}var g=0,y=0,b="";o.forEach(function(e){typeof e=="string"?(e[0]==="\n"?(y=e.length-1,g++):y+=e.length,b+=e):e.start?e.end={row:g,column:y}:e.start={row:g,column:y}});var w=e.getSelectionRange(),E=e.session.replace(w,b),S=new h(e),x=e.inVirtualSelectionMode&&e.selection.index;S.addTabstops(u,w.start,E,x)},this.insertSnippet=function(e,t){var n=this;if(e.inVirtualSelectionMode)return n.insertSnippetForSelection(e,t);e.forEachSelection(function(){n.insertSnippetForSelection(e,t)},null,{keepOrder:!0}),e.tabstopManager&&e.tabstopManager.tabNext()},this.$getScope=function(e){var t=e.session.$mode.$id||"";t=t.split("/").pop();if(t==="html"||t==="php"){t==="php"&&!e.session.$mode.inlinePhp&&(t="html");var n=e.getCursorPosition(),r=e.session.getState(n.row);typeof r=="object"&&(r=r[0]),r.substring&&(r.substring(0,3)=="js-"?t="javascript":r.substring(0,4)=="css-"?t="css":r.substring(0,4)=="php-"&&(t="php"))}return t},this.getActiveScopes=function(e){var t=this.$getScope(e),n=[t],r=this.snippetMap;return r[t]&&r[t].includeScopes&&n.push.apply(n,r[t].includeScopes),n.push("_"),n},this.expandWithTab=function(e,t){var n=this,r=e.forEachSelection(function(){return n.expandSnippetForSelection(e,t)},null,{keepOrder:!0});return r&&e.tabstopManager&&e.tabstopManager.tabNext(),r},this.expandSnippetForSelection=function(e,t){var n=e.getCursorPosition(),r=e.session.getLine(n.row),i=r.substring(0,n.column),s=r.substr(n.column),o=this.snippetMap,u;return this.getActiveScopes(e).some(function(e){var t=o[e];return t&&(u=this.findMatchingSnippet(t,i,s)),!!u},this),u?t&&t.dryRun?!0:(e.session.doc.removeInLine(n.row,n.column-u.replaceBefore.length,n.column+u.replaceAfter.length),this.variables.M__=u.matchBefore,this.variables.T__=u.matchAfter,this.insertSnippetForSelection(e,u.content),this.variables.M__=this.variables.T__=null,!0):!1},this.findMatchingSnippet=function(e,t,n){for(var r=e.length;r--;){var i=e[r];if(i.startRe&&!i.startRe.test(t))continue;if(i.endRe&&!i.endRe.test(n))continue;if(!i.startRe&&!i.endRe)continue;return i.matchBefore=i.startRe?i.startRe.exec(t):[""],i.matchAfter=i.endRe?i.endRe.exec(n):[""],i.replaceBefore=i.triggerRe?i.triggerRe.exec(t)[0]:"",i.replaceAfter=i.endTriggerRe?i.endTriggerRe.exec(n)[0]:"",i}},this.snippetMap={},this.snippetNameMap={},this.register=function(e,t){function o(e){return e&&!/^\^?\(.*\)\$?$|^\\b$/.test(e)&&(e="(?:"+e+")"),e||""}function u(e,t,n){return e=o(e),t=o(t),n?(e=t+e,e&&e[e.length-1]!="$"&&(e+="$")):(e+=t,e&&e[0]!="^"&&(e="^"+e)),new RegExp(e)}function a(e){e.scope||(e.scope=t||"_"),t=e.scope,n[t]||(n[t]=[],r[t]={});var o=r[t];if(e.name){var a=o[e.name];a&&i.unregister(a),o[e.name]=e}n[t].push(e),e.tabTrigger&&!e.trigger&&(!e.guard&&/^\w/.test(e.tabTrigger)&&(e.guard="\\b"),e.trigger=s.escapeRegExp(e.tabTrigger)),e.startRe=u(e.trigger,e.guard,!0),e.triggerRe=new RegExp(e.trigger,"",!0),e.endRe=u(e.endTrigger,e.endGuard,!0),e.endTriggerRe=new RegExp(e.endTrigger,"",!0)}var n=this.snippetMap,r=this.snippetNameMap,i=this;e||(e=[]),e&&e.content?a(e):Array.isArray(e)&&e.forEach(a),this._signal("registerSnippets",{scope:t})},this.unregister=function(e,t){function i(e){var i=r[e.scope||t];if(i&&i[e.name]){delete i[e.name];var s=n[e.scope||t],o=s&&s.indexOf(e);o>=0&&s.splice(o,1)}}var n=this.snippetMap,r=this.snippetNameMap;e.content?i(e):Array.isArray(e)&&e.forEach(i)},this.parseSnippetFile=function(e){e=e.replace(/\r/g,"");var t=[],n={},r=/^#.*|^({[\s\S]*})\s*$|^(\S+) (.*)$|^((?:\n*\t.*)+)/gm,i;while(i=r.exec(e)){if(i[1])try{n=JSON.parse(i[1]),t.push(n)}catch(s){}if(i[4])n.content=i[4].replace(/^\t/gm,""),t.push(n),n={};else{var o=i[2],u=i[3];if(o=="regex"){var a=/\/((?:[^\/\\]|\\.)*)|$/g;n.guard=a.exec(u)[1],n.trigger=a.exec(u)[1],n.endTrigger=a.exec(u)[1],n.endGuard=a.exec(u)[1]}else o=="snippet"?(n.tabTrigger=u.match(/^\S*/)[0],n.name||(n.name=u)):n[o]=u}}return t},this.getSnippetByName=function(e,t){var n=this.snippetNameMap,r;return this.getActiveScopes(t).some(function(t){var i=n[t];return i&&(r=i[e]),!!r},this),r}}).call(c.prototype);var h=function(e){if(e.tabstopManager)return e.tabstopManager;e.tabstopManager=this,this.$onChange=this.onChange.bind(this),this.$onChangeSelection=s.delayedCall(this.onChangeSelection.bind(this)).schedule,this.$onChangeSession=this.onChangeSession.bind(this),this.$onAfterExec=this.onAfterExec.bind(this),this.attach(e)};(function(){this.attach=function(e){this.index=0,this.ranges=[],this.tabstops=[],this.$openTabstops=null,this.selectedTabstop=null,this.editor=e,this.editor.on("change",this.$onChange),this.editor.on("changeSelection",this.$onChangeSelection),this.editor.on("changeSession",this.$onChangeSession),this.editor.commands.on("afterExec",this.$onAfterExec),this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler)},this.detach=function(){this.tabstops.forEach(this.removeTabstopMarkers,this),this.ranges=null,this.tabstops=null,this.selectedTabstop=null,this.editor.removeListener("change",this.$onChange),this.editor.removeListener("changeSelection",this.$onChangeSelection),this.editor.removeListener("changeSession",this.$onChangeSession),this.editor.commands.removeListener("afterExec",this.$onAfterExec),this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler),this.editor.tabstopManager=null,this.editor=null},this.onChange=function(e){var t=e.data.range,n=e.data.action[0]=="r",r=t.start,i=t.end,s=r.row,o=i.row,u=o-s,a=i.column-r.column;n&&(u=-u,a=-a);if(!this.$inChange&&n){var f=this.selectedTabstop,c=f&&!f.some(function(e){return l(e.start,r)<=0&&l(e.end,i)>=0});if(c)return this.detach()}var h=this.ranges;for(var p=0;p<h.length;p++){var d=h[p];if(d.end.row<r.row)continue;if(n&&l(r,d.start)<0&&l(i,d.end)>0){this.removeRange(d),p--;continue}d.start.row==s&&d.start.column>r.column&&(d.start.column+=a),d.end.row==s&&d.end.column>=r.column&&(d.end.column+=a),d.start.row>=s&&(d.start.row+=u),d.end.row>=s&&(d.end.row+=u),l(d.start,d.end)>0&&this.removeRange(d)}h.length||this.detach()},this.updateLinkedFields=function(){var e=this.selectedTabstop;if(!e||!e.hasLinkedRanges)return;this.$inChange=!0;var n=this.editor.session,r=n.getTextRange(e.firstNonLinked);for(var i=e.length;i--;){var s=e[i];if(!s.linked)continue;var o=t.snippetManager.tmStrFormat(r,s.original);n.replace(s,o)}this.$inChange=!1},this.onAfterExec=function(e){e.command&&!e.command.readOnly&&this.updateLinkedFields()},this.onChangeSelection=function(){if(!this.editor)return;var e=this.editor.selection.lead,t=this.editor.selection.anchor,n=this.editor.selection.isEmpty();for(var r=this.ranges.length;r--;){if(this.ranges[r].linked)continue;var i=this.ranges[r].contains(e.row,e.column),s=n||this.ranges[r].contains(t.row,t.column);if(i&&s)return}this.detach()},this.onChangeSession=function(){this.detach()},this.tabNext=function(e){var t=this.tabstops.length,n=this.index+(e||1);n=Math.min(Math.max(n,1),t),n==t&&(n=0),this.selectTabstop(n),n===0&&this.detach()},this.selectTabstop=function(e){this.$openTabstops=null;var t=this.tabstops[this.index];t&&this.addTabstopMarkers(t),this.index=e,t=this.tabstops[this.index];if(!t||!t.length)return;this.selectedTabstop=t;if(!this.editor.inVirtualSelectionMode){var n=this.editor.multiSelect;n.toSingleRange(t.firstNonLinked.clone());for(var r=t.length;r--;){if(t.hasLinkedRanges&&t[r].linked)continue;n.addRange(t[r].clone(),!0)}n.ranges[0]&&n.addRange(n.ranges[0].clone())}else this.editor.selection.setRange(t.firstNonLinked);this.editor.keyBinding.addKeyboardHandler(this.keyboardHandler)},this.addTabstops=function(e,t,n){this.$openTabstops||(this.$openTabstops=[]);if(!e[0]){var r=o.fromPoints(n,n);v(r.start,t),v(r.end,t),e[0]=[r],e[0].index=0}var i=this.index,s=[i+1,0],u=this.ranges;e.forEach(function(e,n){var r=this.$openTabstops[n]||e;for(var i=e.length;i--;){var a=e[i],f=o.fromPoints(a.start,a.end||a.start);d(f.start,t),d(f.end,t),f.original=a,f.tabstop=r,u.push(f),r!=e?r.unshift(f):r[i]=f,a.fmtString?(f.linked=!0,r.hasLinkedRanges=!0):r.firstNonLinked||(r.firstNonLinked=f)}r.firstNonLinked||(r.hasLinkedRanges=!1),r===e&&(s.push(r),this.$openTabstops[n]=r),this.addTabstopMarkers(r)},this),s.length>2&&(this.tabstops.length&&s.push(s.splice(2,1)[0]),this.tabstops.splice.apply(this.tabstops,s))},this.addTabstopMarkers=function(e){var t=this.editor.session;e.forEach(function(e){e.markerId||(e.markerId=t.addMarker(e,"ace_snippet-marker","text"))})},this.removeTabstopMarkers=function(e){var t=this.editor.session;e.forEach(function(e){t.removeMarker(e.markerId),e.markerId=null})},this.removeRange=function(e){var t=e.tabstop.indexOf(e);e.tabstop.splice(t,1),t=this.ranges.indexOf(e),this.ranges.splice(t,1),this.editor.session.removeMarker(e.markerId),e.tabstop.length||(t=this.tabstops.indexOf(e.tabstop),t!=-1&&this.tabstops.splice(t,1),this.tabstops.length||this.detach())},this.keyboardHandler=new a,this.keyboardHandler.bindKeys({Tab:function(e){if(t.snippetManager&&t.snippetManager.expandWithTab(e))return;e.tabstopManager.tabNext(1)},"Shift-Tab":function(e){e.tabstopManager.tabNext(-1)},Esc:function(e){e.tabstopManager.detach()},Return:function(e){return!1}})}).call(h.prototype);var p={};p.onChange=u.prototype.onChange,p.setPosition=function(e,t){this.pos.row=e,this.pos.column=t},p.update=function(e,t,n){this.$insertRight=n,this.pos=e,this.onChange(t)};var d=function(e,t){e.row==0&&(e.column+=t.column),e.row+=t.row},v=function(e,t){e.row==t.row&&(e.column-=t.column),e.row-=t.row};e("./lib/dom").importCssString(".ace_snippet-marker { -moz-box-sizing: border-box; box-sizing: border-box; background: rgba(194, 193, 208, 0.09); border: 1px dotted rgba(211, 208, 235, 0.62); position: absolute;}"),t.snippetManager=new c;var m=e("./editor").Editor;(function(){this.insertSnippet=function(e,n){return t.snippetManager.insertSnippet(this,e,n)},this.expandSnippet=function(e){return t.snippetManager.expandWithTab(this,e)}}).call(m.prototype)}),ace.define("ace/autocomplete/popup",["require","exports","module","ace/edit_session","ace/virtual_renderer","ace/editor","ace/range","ace/lib/event","ace/lib/lang","ace/lib/dom"],function(e,t,n){"use strict";var r=e("../edit_session").EditSession,i=e("../virtual_renderer").VirtualRenderer,s=e("../editor").Editor,o=e("../range").Range,u=e("../lib/event"),a=e("../lib/lang"),f=e("../lib/dom"),l=function(e){var t=new i(e);t.$maxLines=4;var n=new s(t);return n.setHighlightActiveLine(!1),n.setShowPrintMargin(!1),n.renderer.setShowGutter(!1),n.renderer.setHighlightGutterLine(!1),n.$mouseHandler.$focusWaitTimout=0,n.$highlightTagPending=!0,n},c=function(e){var t=f.createElement("div"),n=new l(t);e&&e.appendChild(t),t.style.display="none",n.renderer.content.style.cursor="default",n.renderer.setStyle("ace_autocomplete"),n.setOption("displayIndentGuides",!1),n.setOption("dragDelay",150);var r=function(){};n.focus=r,n.$isFocused=!0,n.renderer.$cursorLayer.restartTimer=r,n.renderer.$cursorLayer.element.style.opacity=0,n.renderer.$maxLines=8,n.renderer.$keepTextAreaAtCursor=!1,n.setHighlightActiveLine(!1),n.session.highlight(""),n.session.$searchHighlight.clazz="ace_highlight-marker",n.on("mousedown",function(e){var t=e.getDocumentPosition();n.selection.moveToPosition(t),c.start.row=c.end.row=t.row,e.stop()});var i,s=new o(-1,0,-1,Infinity),c=new o(-1,0,-1,Infinity);c.id=n.session.addMarker(c,"ace_active-line","fullLine"),n.setSelectOnHover=function(e){e?s.id&&(n.session.removeMarker(s.id),s.id=null):s.id=n.session.addMarker(s,"ace_line-hover","fullLine")},n.setSelectOnHover(!1),n.on("mousemove",function(e){if(!i){i=e;return}if(i.x==e.x&&i.y==e.y)return;i=e,i.scrollTop=n.renderer.scrollTop;var t=i.getDocumentPosition().row;s.start.row!=t&&(s.id||n.setRow(t),p(t))}),n.renderer.on("beforeRender",function(){if(i&&s.start.row!=-1){i.$pos=null;var e=i.getDocumentPosition().row;s.id||n.setRow(e),p(e,!0)}}),n.renderer.on("afterRender",function(){var e=n.getRow(),t=n.renderer.$textLayer,r=t.element.childNodes[e-t.config.firstRow];if(r==t.selectedNode)return;t.selectedNode&&f.removeCssClass(t.selectedNode,"ace_selected"),t.selectedNode=r,r&&f.addCssClass(r,"ace_selected")});var h=function(){p(-1)},p=function(e,t){e!==s.start.row&&(s.start.row=s.end.row=e,t||n.session._emit("changeBackMarker"),n._emit("changeHoverMarker"))};n.getHoveredRow=function(){return s.start.row},u.addListener(n.container,"mouseout",h),n.on("hide",h),n.on("changeSelection",h),n.session.doc.getLength=function(){return n.data.length},n.session.doc.getLine=function(e){var t=n.data[e];return typeof t=="string"?t:t&&t.value||""};var d=n.session.bgTokenizer;return d.$tokenizeRow=function(e){var t=n.data[e],r=[];if(!t)return r;typeof t=="string"&&(t={value:t}),t.caption||(t.caption=t.value||t.name);var i=-1,s,o;for(var u=0;u<t.caption.length;u++)o=t.caption[u],s=t.matchMask&1<<u?1:0,i!==s?(r.push({type:t.className||""+(s?"completion-highlight":""),value:o}),i=s):r[r.length-1].value+=o;if(t.meta){var a=n.renderer.$size.scrollerWidth/n.renderer.layerConfig.characterWidth;t.meta.length+t.caption.length<a-2&&r.push({type:"rightAlignedText",value:t.meta})}return r},d.$updateOnChange=r,d.start=r,n.session.$computeWidth=function(){return this.screenWidth=0},n.isOpen=!1,n.isTopdown=!1,n.data=[],n.setData=function(e){n.data=e||[],n.setValue(a.stringRepeat("\n",e.length),-1),n.setRow(0)},n.getData=function(e){return n.data[e]},n.getRow=function(){return c.start.row},n.setRow=function(e){e=Math.max(-1,Math.min(this.data.length,e)),c.start.row!=e&&(n.selection.clearSelection(),c.start.row=c.end.row=e||0,n.session._emit("changeBackMarker"),n.moveCursorTo(e||0,0),n.isOpen&&n._signal("select"))},n.on("changeSelection",function(){n.isOpen&&n.setRow(n.selection.lead.row)}),n.hide=function(){this.container.style.display="none",this._signal("hide"),n.isOpen=!1},n.show=function(e,t,r){var s=this.container,o=window.innerHeight,u=window.innerWidth,a=this.renderer,f=a.$maxLines*t*1.4,l=e.top+this.$borderSize;l+f>o-t&&!r?(s.style.top="",s.style.bottom=o-l+"px",n.isTopdown=!1):(l+=t,s.style.top=l+"px",s.style.bottom="",n.isTopdown=!0),s.style.display="",this.renderer.$textLayer.checkForSizeChanges();var c=e.left;c+s.offsetWidth>u&&(c=u-s.offsetWidth),s.style.left=c+"px",this._signal("show"),i=null,n.isOpen=!0},n.getTextLeftOffset=function(){return this.$borderSize+this.renderer.$padding+this.$imageSize},n.$imageSize=0,n.$borderSize=1,n};f.importCssString(".ace_editor.ace_autocomplete .ace_marker-layer .ace_active-line { background-color: #CAD6FA; z-index: 1;}.ace_editor.ace_autocomplete .ace_line-hover { border: 1px solid #abbffe; margin-top: -1px; background: rgba(233,233,253,0.4);}.ace_editor.ace_autocomplete .ace_line-hover { position: absolute; z-index: 2;}.ace_editor.ace_autocomplete .ace_scroller { background: none; border: none; box-shadow: none;}.ace_rightAlignedText { color: gray; display: inline-block; position: absolute; right: 4px; text-align: right; z-index: -1;}.ace_editor.ace_autocomplete .ace_completion-highlight{ color: #000; text-shadow: 0 0 0.01em;}.ace_editor.ace_autocomplete { width: 280px; z-index: 200000; background: #fbfbfb; color: #444; border: 1px lightgray solid; position: fixed; box-shadow: 2px 3px 5px rgba(0,0,0,.2); line-height: 1.4;}"),t.AcePopup=c}),ace.define("ace/autocomplete/util",["require","exports","module"],function(e,t,n){"use strict";t.parForEach=function(e,t,n){var r=0,i=e.length;i===0&&n();for(var s=0;s<i;s++)t(e[s],function(e,t){r++,r===i&&n(e,t)})};var r=/[a-zA-Z_0-9\$\-\u00A2-\uFFFF]/;t.retrievePrecedingIdentifier=function(e,t,n){n=n||r;var i=[];for(var s=t-1;s>=0;s--){if(!n.test(e[s]))break;i.push(e[s])}return i.reverse().join("")},t.retrieveFollowingIdentifier=function(e,t,n){n=n||r;var i=[];for(var s=t;s<e.length;s++){if(!n.test(e[s]))break;i.push(e[s])}return i}}),ace.define("ace/autocomplete",["require","exports","module","ace/keyboard/hash_handler","ace/autocomplete/popup","ace/autocomplete/util","ace/lib/event","ace/lib/lang","ace/snippets"],function(e,t,n){"use strict";var r=e("./keyboard/hash_handler").HashHandler,i=e("./autocomplete/popup").AcePopup,s=e("./autocomplete/util"),o=e("./lib/event"),u=e("./lib/lang"),a=e("./snippets").snippetManager,f=function(){this.autoInsert=!0,this.autoSelect=!0,this.keyboardHandler=new r,this.keyboardHandler.bindKeys(this.commands),this.blurListener=this.blurListener.bind(this),this.changeListener=this.changeListener.bind(this),this.mousedownListener=this.mousedownListener.bind(this),this.mousewheelListener=this.mousewheelListener.bind(this),this.changeTimer=u.delayedCall(function(){this.updateCompletions(!0)}.bind(this))};(function(){this.gatherCompletionsId=0,this.$init=function(){this.popup=new i(document.body||document.documentElement),this.popup.on("click",function(e){this.insertMatch(),e.stop()}.bind(this)),this.popup.focus=this.editor.focus.bind(this.editor)},this.openPopup=function(e,t,n){this.popup||this.$init(),this.popup.setData(this.completions.filtered);var r=e.renderer;this.popup.setRow(this.autoSelect?0:-1);if(!n){this.popup.setTheme(e.getTheme()),this.popup.setFontSize(e.getFontSize());var i=r.layerConfig.lineHeight,s=r.$cursorLayer.getPixelPosition(this.base,!0);s.left-=this.popup.getTextLeftOffset();var o=e.container.getBoundingClientRect();s.top+=o.top-r.layerConfig.offset,s.left+=o.left-e.renderer.scrollLeft,s.left+=r.$gutterLayer.gutterWidth,this.popup.show(s,i)}},this.detach=function(){this.editor.keyBinding.removeKeyboardHandler(this.keyboardHandler),this.editor.off("changeSelection",this.changeListener),this.editor.off("blur",this.blurListener),this.editor.off("mousedown",this.mousedownListener),this.editor.off("mousewheel",this.mousewheelListener),this.changeTimer.cancel(),this.popup&&this.popup.isOpen&&(this.gatherCompletionsId+=1,this.popup.hide()),this.base&&this.base.detach(),this.activated=!1,this.completions=this.base=null},this.changeListener=function(e){var t=this.editor.selection.lead;(t.row!=this.base.row||t.column<this.base.column)&&this.detach(),this.activated?this.changeTimer.schedule():this.detach()},this.blurListener=function(){var e=document.activeElement;e!=this.editor.textInput.getElement()&&e.parentNode!=this.popup.container&&this.detach()},this.mousedownListener=function(e){this.detach()},this.mousewheelListener=function(e){this.detach()},this.goTo=function(e){var t=this.popup.getRow(),n=this.popup.session.getLength()-1;switch(e){case"up":t=t<=0?n:t-1;break;case"down":t=t>=n?-1:t+1;break;case"start":t=0;break;case"end":t=n}this.popup.setRow(t)},this.insertMatch=function(e){e||(e=this.popup.getData(this.popup.getRow()));if(!e)return!1;if(e.completer&&e.completer.insertMatch)e.completer.insertMatch(this.editor);else{if(this.completions.filterText){var t=this.editor.selection.getAllRanges();for(var n=0,r;r=t[n];n++)r.start.column-=this.completions.filterText.length,this.editor.session.remove(r)}e.snippet?a.insertSnippet(this.editor,e.snippet):this.editor.execCommand("insertstring",e.value||e)}this.detach()},this.commands={Up:function(e){e.completer.goTo("up")},Down:function(e){e.completer.goTo("down")},"Ctrl-Up|Ctrl-Home":function(e){e.completer.goTo("start")},"Ctrl-Down|Ctrl-End":function(e){e.completer.goTo("end")},Esc:function(e){e.completer.detach()},Space:function(e){e.completer.detach(),e.insert(" ")},Return:function(e){return e.completer.insertMatch()},"Shift-Return":function(e){e.completer.insertMatch(!0)},Tab:function(e){var t=e.completer.insertMatch();if(!!t||!!e.tabstopManager)return t;e.completer.goTo("down")},PageUp:function(e){e.completer.popup.gotoPageUp()},PageDown:function(e){e.completer.popup.gotoPageDown()}},this.gatherCompletions=function(e,t){var n=e.getSession(),r=e.getCursorPosition(),i=n.getLine(r.row),o=s.retrievePrecedingIdentifier(i,r.column);this.base=n.doc.createAnchor(r.row,r.column-o.length);var u=[],a=e.completers.length;return e.completers.forEach(function(i,f){i.getCompletions(e,n,r,o,function(r,i){r||(u=u.concat(i));var o=e.getCursorPosition(),f=n.getLine(o.row);t(null,{prefix:s.retrievePrecedingIdentifier(f,o.column,i[0]&&i[0].identifierRegex),matches:u,finished:--a===0})})}),!0},this.showPopup=function(e){this.editor&&this.detach(),this.activated=!0,this.editor=e,e.completer!=this&&(e.completer&&e.completer.detach(),e.completer=this),e.keyBinding.addKeyboardHandler(this.keyboardHandler),e.on("changeSelection",this.changeListener),e.on("blur",this.blurListener),e.on("mousedown",this.mousedownListener),e.on("mousewheel",this.mousewheelListener),this.updateCompletions()},this.updateCompletions=function(e){if(e&&this.base&&this.completions){var t=this.editor.getCursorPosition(),n=this.editor.session.getTextRange({start:this.base,end:t});if(n==this.completions.filterText)return;this.completions.setFilter(n);if(!this.completions.filtered.length)return this.detach();if(this.completions.filtered.length==1&&this.completions.filtered[0].value==n&&!this.completions.filtered[0].snippet)return this.detach();this.openPopup(this.editor,n,e);return}var r=this.gatherCompletionsId;this.gatherCompletions(this.editor,function(t,n){var i=function(){if(!n.finished)return;return this.detach()}.bind(this),s=n.prefix,o=n&&n.matches;if(!o||!o.length)return i();if(s.indexOf(n.prefix)!==0||r!=this.gatherCompletionsId)return;this.completions=new l(o),this.completions.setFilter(s);var u=this.completions.filtered;if(!u.length)return i();if(u.length==1&&u[0].value==s&&!u[0].snippet)return i();if(this.autoInsert&&u.length==1)return this.insertMatch(u[0]);this.openPopup(this.editor,s,e)}.bind(this))},this.cancelContextMenu=function(){this.editor.$mouseHandler.cancelContextMenu()}}).call(f.prototype),f.startCommand={name:"startAutocomplete",exec:function(e){e.completer||(e.completer=new f),e.completer.autoInsert=e.completer.autoSelect=!0,e.completer.showPopup(e),e.completer.cancelContextMenu()},bindKey:"Ctrl-Space|Ctrl-Shift-Space|Alt-Space"};var l=function(e,t,n){this.all=e,this.filtered=e,this.filterText=t||""};(function(){this.setFilter=function(e){if(e.length>this.filterText&&e.lastIndexOf(this.filterText,0)===0)var t=this.filtered;else var t=this.all;this.filterText=e,t=this.filterCompletions(t,this.filterText),t=t.sort(function(e,t){return t.exactMatch-e.exactMatch||t.score-e.score});var n=null;t=t.filter(function(e){var t=e.value||e.caption||e.snippet;return t===n?!1:(n=t,!0)}),this.filtered=t},this.filterCompletions=function(e,t){var n=[],r=t.toUpperCase(),i=t.toLowerCase();e:for(var s=0,o;o=e[s];s++){var u=o.value||o.caption||o.snippet;if(!u)continue;var a=-1,f=0,l=0,c,h;for(var p=0;p<t.length;p++){var d=u.indexOf(i[p],a+1),v=u.indexOf(r[p],a+1);c=d>=0?v<0||d<v?d:v:v;if(c<0)continue e;h=c-a-1,h>0&&(a===-1&&(l+=10),l+=h),f|=1<<c,a=c}o.matchMask=f,o.exactMatch=l?0:1,o.score=(o.score||0)-l,n.push(o)}return n}}).call(l.prototype),t.Autocomplete=f,t.FilteredList=l}),ace.define("ace/autocomplete/text_completer",["require","exports","module","ace/range"],function(e,t,n){function s(e,t){var n=e.getTextRange(r.fromPoints({row:0,column:0},t));return n.split(i).length-1}function o(e,t){var n=s(e,t),r=e.getValue().split(i),o=Object.create(null),u=r[n];return r.forEach(function(e,t){if(!e||e===u)return;var i=Math.abs(n-t),s=r.length-i;o[e]?o[e]=Math.max(s,o[e]):o[e]=s}),o}var r=e("../range").Range,i=/[^a-zA-Z_0-9\$\-\u00C0-\u1FFF\u2C00-\uD7FF\w]+/;t.getCompletions=function(e,t,n,r,i){var s=o(t,n,r),u=Object.keys(s);i(null,u.map(function(e){return{caption:e,value:e,score:s[e],meta:"local"}}))}}),ace.define("ace/ext/language_tools",["require","exports","module","ace/snippets","ace/autocomplete","ace/config","ace/autocomplete/util","ace/autocomplete/text_completer","ace/editor","ace/config"],function(e,t,n){"use strict";function v(e){var t=e.getCursorPosition(),n=e.session.getLine(t.row),r=o.retrievePrecedingIdentifier(n,t.column);return e.completers.forEach(function(e){e.identifierRegexps&&e.identifierRegexps.forEach(function(e){!r&&e&&(r=o.retrievePrecedingIdentifier(n,t.column,e))})}),r}var r=e("../snippets").snippetManager,i=e("../autocomplete").Autocomplete,s=e("../config"),o=e("../autocomplete/util"),u=e("../autocomplete/text_completer"),a={getCompletions:function(e,t,n,r,i){var s=e.session.getState(n.row),o=t.$mode.getCompletions(s,t,n,r);i(null,o)}},f={getCompletions:function(e,t,n,i,s){var o=r.snippetMap,u=[];r.getActiveScopes(e).forEach(function(e){var t=o[e]||[];for(var n=t.length;n--;){var r=t[n],i=r.name||r.tabTrigger;if(!i)continue;u.push({caption:i,snippet:r.content,meta:r.tabTrigger&&!r.name?r.tabTrigger+"\u21e5 ":"snippet"})}},this),s(null,u)}},l=[f,u,a];t.addCompleter=function(e){l.push(e)},t.textCompleter=u,t.keyWordCompleter=a,t.snippetCompleter=f;var c={name:"expandSnippet",exec:function(e){var t=r.expandWithTab(e);t||e.execCommand("indent")},bindKey:"Tab"},h=function(e,t){p(t.session.$mode)},p=function(e){var t=e.$id;r.files||(r.files={}),d(t),e.modes&&e.modes.forEach(p)},d=function(e){if(!e||r.files[e])return;var t=e.replace("mode","snippets");r.files[e]={},s.loadModule(t,function(t){t&&(r.files[e]=t,!t.snippets&&t.snippetText&&(t.snippets=r.parseSnippetFile(t.snippetText)),r.register(t.snippets||[],t.scope),t.includeScopes&&(r.snippetMap[t.scope].includeScopes=t.includeScopes,t.includeScopes.forEach(function(e){d("ace/mode/"+e)})))})},m=function(e){var t=e.editor,n=e.args||"",r=t.completer&&t.completer.activated;if(e.command.name==="backspace")r&&!v(t)&&t.completer.detach();else if(e.command.name==="insertstring"){var s=v(t);s&&!r&&(t.completer||(t.completer=new i),t.completer.autoSelect=!1,t.completer.autoInsert=!1,t.completer.showPopup(t))}},g=e("../editor").Editor;e("../config").defineOptions(g.prototype,"editor",{enableBasicAutocompletion:{set:function(e){e?(this.completers||(this.completers=Array.isArray(e)?e:l),this.commands.addCommand(i.startCommand)):this.commands.removeCommand(i.startCommand)},value:!1},enableLiveAutocompletion:{set:function(e){e?(this.completers||(this.completers=Array.isArray(e)?e:l),this.commands.on("afterExec",m)):this.commands.removeListener("afterExec",m)},value:!1},enableSnippets:{set:function(e){e?(this.commands.addCommand(c),this.on("changeMode",h),h(null,this)):(this.commands.removeCommand(c),this.off("changeMode",h))},value:!1}})});+ (function() {+ ace.require(["ace/ext/language_tools"], function() {});+ })();+\ No newline at end of filediff --git a/app/assets/javascripts/blazer/ace/mode-sql.js b/app/assets/javascripts/blazer/ace/mode-sql.jsnew file mode 100755index 00000000..c5e02e5a--- /dev/null+++ b/app/assets/javascripts/blazer/ace/mode-sql.js@@ -0,0 +1 @@+ace.define("ace/mode/sql_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(e,t,n){"use strict";var r=e("../lib/oop"),i=e("./text_highlight_rules").TextHighlightRules,s=function(){var e="select|insert|update|delete|from|where|and|or|group|by|order|limit|offset|having|as|case|when|else|end|type|left|right|join|on|outer|desc|asc",t="true|false|null",n="count|min|max|avg|sum|rank|now|coalesce",r=this.createKeywordMapper({"support.function":n,keyword:e,"constant.language":t},"identifier",!0);this.$rules={start:[{token:"comment",regex:"--.*$"},{token:"comment",start:"/\\*",end:"\\*/"},{token:"string",regex:'".*?"'},{token:"string",regex:"'.*?'"},{token:"constant.numeric",regex:"[+-]?\\d+(?:(?:\\.\\d*)?(?:[eE][+-]?\\d+)?)?\\b"},{token:r,regex:"[a-zA-Z_$][a-zA-Z0-9_$]*\\b"},{token:"keyword.operator",regex:"\\+|\\-|\\/|\\/\\/|%|<@>|@>|<@|&|\\^|~|<|>|<=|=>|==|!=|<>|="},{token:"paren.lparen",regex:"[\\(]"},{token:"paren.rparen",regex:"[\\)]"},{token:"text",regex:"\\s+"}]},this.normalizeRules()};r.inherits(s,i),t.SqlHighlightRules=s}),ace.define("ace/mode/sql",["require","exports","module","ace/lib/oop","ace/mode/text","ace/mode/sql_highlight_rules","ace/range"],function(e,t,n){"use strict";var r=e("../lib/oop"),i=e("./text").Mode,s=e("./sql_highlight_rules").SqlHighlightRules,o=e("../range").Range,u=function(){this.HighlightRules=s};r.inherits(u,i),function(){this.lineCommentStart="--",this.$id="ace/mode/sql"}.call(u.prototype),t.Mode=u})\ No newline at end of filediff --git a/app/assets/javascripts/blazer/ace/snippets/sql.js b/app/assets/javascripts/blazer/ace/snippets/sql.jsnew file mode 100755index 00000000..1bacce06--- /dev/null+++ b/app/assets/javascripts/blazer/ace/snippets/sql.js@@ -0,0 +1 @@+ace.define("ace/snippets/sql",["require","exports","module"],function(e,t,n){"use strict";t.snippetText="snippet tbl\n create table ${1:table} (\n ${2:columns}\n );\nsnippet col\n ${1:name} ${2:type} ${3:default ''} ${4:not null}\nsnippet ccol\n ${1:name} varchar2(${2:size}) ${3:default ''} ${4:not null}\nsnippet ncol\n ${1:name} number ${3:default 0} ${4:not null}\nsnippet dcol\n ${1:name} date ${3:default sysdate} ${4:not null}\nsnippet ind\n create index ${3:$1_$2} on ${1:table}(${2:column});\nsnippet uind\n create unique index ${1:name} on ${2:table}(${3:column});\nsnippet tblcom\n comment on table ${1:table} is '${2:comment}';\nsnippet colcom\n comment on column ${1:table}.${2:column} is '${3:comment}';\nsnippet addcol\n alter table ${1:table} add (${2:column} ${3:type});\nsnippet seq\n create sequence ${1:name} start with ${2:1} increment by ${3:1} minvalue ${4:1};\nsnippet s*\n select * from ${1:table}\n",t.scope="sql"})\ No newline at end of filediff --git a/app/assets/javascripts/blazer/ace/snippets/text.js b/app/assets/javascripts/blazer/ace/snippets/text.jsnew file mode 100755index 00000000..233803da--- /dev/null+++ b/app/assets/javascripts/blazer/ace/snippets/text.js@@ -0,0 +1 @@+ace.define("ace/snippets/text",["require","exports","module"],function(e,t,n){"use strict";t.snippetText=undefined,t.scope="text"})\ No newline at end of filediff --git a/app/assets/javascripts/blazer/ace/theme-twilight.js b/app/assets/javascripts/blazer/ace/theme-twilight.jsnew file mode 100755index 00000000..1c5dfda7--- /dev/null+++ b/app/assets/javascripts/blazer/ace/theme-twilight.js@@ -0,0 +1 @@+ace.define("ace/theme/twilight",["require","exports","module","ace/lib/dom"],function(e,t,n){t.isDark=!0,t.cssClass="ace-twilight",t.cssText=".ace-twilight .ace_gutter {background: #232323;color: #E2E2E2}.ace-twilight .ace_print-margin {width: 1px;background: #232323}.ace-twilight {background-color: #141414;color: #F8F8F8}.ace-twilight .ace_cursor {color: #A7A7A7}.ace-twilight .ace_marker-layer .ace_selection {background: rgba(221, 240, 255, 0.20)}.ace-twilight.ace_multiselect .ace_selection.ace_start {box-shadow: 0 0 3px 0px #141414;border-radius: 2px}.ace-twilight .ace_marker-layer .ace_step {background: rgb(102, 82, 0)}.ace-twilight .ace_marker-layer .ace_bracket {margin: -1px 0 0 -1px;border: 1px solid rgba(255, 255, 255, 0.25)}.ace-twilight .ace_marker-layer .ace_active-line {background: rgba(255, 255, 255, 0.031)}.ace-twilight .ace_gutter-active-line {background-color: rgba(255, 255, 255, 0.031)}.ace-twilight .ace_marker-layer .ace_selected-word {border: 1px solid rgba(221, 240, 255, 0.20)}.ace-twilight .ace_invisible {color: rgba(255, 255, 255, 0.25)}.ace-twilight .ace_keyword,.ace-twilight .ace_meta {color: #CDA869}.ace-twilight .ace_constant,.ace-twilight .ace_constant.ace_character,.ace-twilight .ace_constant.ace_character.ace_escape,.ace-twilight .ace_constant.ace_other,.ace-twilight .ace_heading,.ace-twilight .ace_markup.ace_heading,.ace-twilight .ace_support.ace_constant {color: #CF6A4C}.ace-twilight .ace_invalid.ace_illegal {color: #F8F8F8;background-color: rgba(86, 45, 86, 0.75)}.ace-twilight .ace_invalid.ace_deprecated {text-decoration: underline;font-style: italic;color: #D2A8A1}.ace-twilight .ace_support {color: #9B859D}.ace-twilight .ace_fold {background-color: #AC885B;border-color: #F8F8F8}.ace-twilight .ace_support.ace_function {color: #DAD085}.ace-twilight .ace_list,.ace-twilight .ace_markup.ace_list,.ace-twilight .ace_storage {color: #F9EE98}.ace-twilight .ace_entity.ace_name.ace_function,.ace-twilight .ace_meta.ace_tag,.ace-twilight .ace_variable {color: #AC885B}.ace-twilight .ace_string {color: #8F9D6A}.ace-twilight .ace_string.ace_regexp {color: #E9C062}.ace-twilight .ace_comment {font-style: italic;color: #5F5A60}.ace-twilight .ace_variable {color: #7587A6}.ace-twilight .ace_xml-pe {color: #494949}.ace-twilight .ace_indent-guide {background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAACCAYAAACZgbYnAAAAEklEQVQImWMQERFpYLC1tf0PAAgOAnPnhxyiAAAAAElFTkSuQmCC) right repeat-y}";var r=e("../lib/dom");r.importCssString(t.cssText,t.cssClass)})\ No newline at end of filediff --git a/app/assets/javascripts/blazer/application.js b/app/assets/javascripts/blazer/application.jsnew file mode 100644index 00000000..e4ebbfea--- /dev/null+++ b/app/assets/javascripts/blazer/application.js@@ -0,0 +1,15 @@+//= require ./jquery+//= require ./jquery_ujs+//= require ./list+//= require ./stupidtable+//= require ./jquery.stickytableheaders+//= require ./selectize+//= require ./highlight.pack+//= require ./moment+//= require ./daterangepicker+//= require ./ace/ace+//= require ./ace/ext-language_tools+//= require ./ace/theme-twilight+//= require ./ace/mode-sql+//= require ./ace/snippets/text+//= require ./ace/snippets/sqldiff --git a/app/assets/javascripts/blazer/daterangepicker.js b/app/assets/javascripts/blazer/daterangepicker.jsnew file mode 100644index 00000000..e4872ca1--- /dev/null+++ b/app/assets/javascripts/blazer/daterangepicker.js@@ -0,0 +1,1026 @@+/**+* @version: 1.3.7+* @author: Dan Grossman http://www.dangrossman.info/+* @date: 2014-04-29+* @copyright: Copyright (c) 2012-2014 Dan Grossman. All rights reserved.+* @license: Licensed under Apache License v2.0. See http://www.apache.org/licenses/LICENSE-2.0+* @website: http://www.improvely.com/+*/+!function ($, moment) {++ var DateRangePicker = function (element, options, cb) {++ // by default, the daterangepicker element is placed at the bottom of HTML body+ this.parentEl = 'body';++ //element that triggered the date range picker+ this.element = $(element);++ //create the picker HTML object+ var DRPTemplate = '<div class="daterangepicker dropdown-menu">' ++ '<div class="calendar left"></div>' ++ '<div class="calendar right"></div>' ++ '<div class="ranges">' ++ '<div class="range_inputs">' ++ '<div class="daterangepicker_start_input">' ++ '<label for="daterangepicker_start"></label>' ++ '<input class="input-mini" type="text" name="daterangepicker_start" value="" disabled="disabled" />' ++ '</div>' ++ '<div class="daterangepicker_end_input">' ++ '<label for="daterangepicker_end"></label>' ++ '<input class="input-mini" type="text" name="daterangepicker_end" value="" disabled="disabled" />' ++ '</div>' ++ '<button class="applyBtn" disabled="disabled"></button> ' ++ '<button class="cancelBtn"></button>' ++ '</div>' ++ '</div>' ++ '</div>';++ //custom options+ if (typeof options !== 'object' || options === null)+ options = {};++ this.parentEl = (typeof options === 'object' && options.parentEl && $(options.parentEl).length) ? $(options.parentEl) : $(this.parentEl);+ this.container = $(DRPTemplate).appendTo(this.parentEl);++ this.setOptions(options, cb);++ //apply CSS classes and labels to buttons+ var c = this.container;+ $.each(this.buttonClasses, function (idx, val) {+ c.find('button').addClass(val);+ });+ this.container.find('.daterangepicker_start_input label').html(this.locale.fromLabel);+ this.container.find('.daterangepicker_end_input label').html(this.locale.toLabel);+ if (this.applyClass.length)+ this.container.find('.applyBtn').addClass(this.applyClass);+ if (this.cancelClass.length)+ this.container.find('.cancelBtn').addClass(this.cancelClass);+ this.container.find('.applyBtn').html(this.locale.applyLabel);+ this.container.find('.cancelBtn').html(this.locale.cancelLabel);++ //event listeners++ this.container.find('.calendar')+ .on('click.daterangepicker', '.prev', $.proxy(this.clickPrev, this))+ .on('click.daterangepicker', '.next', $.proxy(this.clickNext, this))+ .on('click.daterangepicker', 'td.available', $.proxy(this.clickDate, this))+ .on('mouseenter.daterangepicker', 'td.available', $.proxy(this.enterDate, this))+ .on('mouseleave.daterangepicker', 'td.available', $.proxy(this.updateFormInputs, this))+ .on('change.daterangepicker', 'select.yearselect', $.proxy(this.updateMonthYear, this))+ .on('change.daterangepicker', 'select.monthselect', $.proxy(this.updateMonthYear, this))+ .on('change.daterangepicker', 'select.hourselect,select.minuteselect,select.ampmselect', $.proxy(this.updateTime, this));++ this.container.find('.ranges')+ .on('click.daterangepicker', 'button.applyBtn', $.proxy(this.clickApply, this))+ .on('click.daterangepicker', 'button.cancelBtn', $.proxy(this.clickCancel, this))+ .on('click.daterangepicker', '.daterangepicker_start_input,.daterangepicker_end_input', $.proxy(this.showCalendars, this))+ .on('click.daterangepicker', 'li', $.proxy(this.clickRange, this))+ .on('mouseenter.daterangepicker', 'li', $.proxy(this.enterRange, this))+ .on('mouseleave.daterangepicker', 'li', $.proxy(this.updateFormInputs, this));++ if (this.element.is('input')) {+ this.element.on({+ 'click.daterangepicker': $.proxy(this.show, this),+ 'focus.daterangepicker': $.proxy(this.show, this),+ 'keyup.daterangepicker': $.proxy(this.updateFromControl, this)+ });+ } else {+ this.element.on('click.daterangepicker', $.proxy(this.toggle, this));+ }++ };++ DateRangePicker.prototype = {++ constructor: DateRangePicker,++ setOptions: function(options, callback) {++ this.startDate = moment().startOf('day');+ this.endDate = moment().endOf('day');+ this.minDate = false;+ this.maxDate = false;+ this.dateLimit = false;++ this.showDropdowns = false;+ this.showWeekNumbers = false;+ this.timePicker = false;+ this.timePickerIncrement = 30;+ this.timePicker12Hour = true;+ this.singleDatePicker = false;+ this.ranges = {};++ this.opens = 'right';+ if (this.element.hasClass('pull-right'))+ this.opens = 'left';++ this.buttonClasses = ['btn', 'btn-small'];+ this.applyClass = 'btn-success';+ this.cancelClass = 'btn-default';++ this.format = 'MM/DD/YYYY';+ this.separator = ' - ';++ this.locale = {+ applyLabel: 'Apply',+ cancelLabel: 'Cancel',+ fromLabel: 'From',+ toLabel: 'To',+ weekLabel: 'W',+ customRangeLabel: 'Custom Range',+ daysOfWeek: moment()._lang._weekdaysMin.slice(),+ monthNames: moment()._lang._monthsShort.slice(),+ firstDay: 0+ };++ this.cb = function () { };++ if (typeof options.format === 'string')+ this.format = options.format;++ if (typeof options.separator === 'string')+ this.separator = options.separator;++ if (typeof options.startDate === 'string')+ this.startDate = moment(options.startDate, this.format);++ if (typeof options.endDate === 'string')+ this.endDate = moment(options.endDate, this.format);++ if (typeof options.minDate === 'string')+ this.minDate = moment(options.minDate, this.format);++ if (typeof options.maxDate === 'string')+ this.maxDate = moment(options.maxDate, this.format);++ if (typeof options.startDate === 'object')+ this.startDate = moment(options.startDate);++ if (typeof options.endDate === 'object')+ this.endDate = moment(options.endDate);++ if (typeof options.minDate === 'object')+ this.minDate = moment(options.minDate);++ if (typeof options.maxDate === 'object')+ this.maxDate = moment(options.maxDate);++ if (typeof options.applyClass === 'string')+ this.applyClass = options.applyClass;++ if (typeof options.cancelClass === 'string')+ this.cancelClass = options.cancelClass;++ if (typeof options.dateLimit === 'object')+ this.dateLimit = options.dateLimit;++ // update day names order to firstDay+ if (typeof options.locale === 'object') {++ if (typeof options.locale.daysOfWeek === 'object') {+ // Create a copy of daysOfWeek to avoid modification of original+ // options object for reusability in multiple daterangepicker instances+ this.locale.daysOfWeek = options.locale.daysOfWeek.slice();+ }++ if (typeof options.locale.monthNames === 'object') {+ this.locale.monthNames = options.locale.monthNames.slice();+ }++ if (typeof options.locale.firstDay === 'number') {+ this.locale.firstDay = options.locale.firstDay;+ var iterator = options.locale.firstDay;+ while (iterator > 0) {+ this.locale.daysOfWeek.push(this.locale.daysOfWeek.shift());+ iterator--;+ }+ }++ if (typeof options.locale.applyLabel === 'string') {+ this.locale.applyLabel = options.locale.applyLabel;+ }++ if (typeof options.locale.cancelLabel === 'string') {+ this.locale.cancelLabel = options.locale.cancelLabel;+ }++ if (typeof options.locale.fromLabel === 'string') {+ this.locale.fromLabel = options.locale.fromLabel;+ }++ if (typeof options.locale.toLabel === 'string') {+ this.locale.toLabel = options.locale.toLabel;+ }++ if (typeof options.locale.weekLabel === 'string') {+ this.locale.weekLabel = options.locale.weekLabel;+ }++ if (typeof options.locale.customRangeLabel === 'string') {+ this.locale.customRangeLabel = options.locale.customRangeLabel;+ }+ }++ if (typeof options.opens === 'string')+ this.opens = options.opens;++ if (typeof options.showWeekNumbers === 'boolean') {+ this.showWeekNumbers = options.showWeekNumbers;+ }++ if (typeof options.buttonClasses === 'string') {+ this.buttonClasses = [options.buttonClasses];+ }++ if (typeof options.buttonClasses === 'object') {+ this.buttonClasses = options.buttonClasses;+ }++ if (typeof options.showDropdowns === 'boolean') {+ this.showDropdowns = options.showDropdowns;+ }++ if (typeof options.singleDatePicker === 'boolean') {+ this.singleDatePicker = options.singleDatePicker;+ }++ if (typeof options.timePicker === 'boolean') {+ this.timePicker = options.timePicker;+ }++ if (typeof options.timePickerIncrement === 'number') {+ this.timePickerIncrement = options.timePickerIncrement;+ }++ if (typeof options.timePicker12Hour === 'boolean') {+ this.timePicker12Hour = options.timePicker12Hour;+ }++ var start, end, range;++ //if no start/end dates set, check if an input element contains initial values+ if (typeof options.startDate === 'undefined' && typeof options.endDate === 'undefined') {+ if ($(this.element).is('input[type=text]')) {+ var val = $(this.element).val();+ var split = val.split(this.separator);+ start = end = null;+ if (split.length == 2) {+ start = moment(split[0], this.format);+ end = moment(split[1], this.format);+ } else if (this.singleDatePicker) {+ start = moment(val, this.format);+ end = moment(val, this.format);+ }+ if (start !== null && end !== null) {+ this.startDate = start;+ this.endDate = end;+ }+ }+ }++ if (typeof options.ranges === 'object') {+ for (range in options.ranges) {++ start = moment(options.ranges[range][0]);+ end = moment(options.ranges[range][1]);++ // If we have a min/max date set, bound this range+ // to it, but only if it would otherwise fall+ // outside of the min/max.+ if (this.minDate && start.isBefore(this.minDate))+ start = moment(this.minDate);++ if (this.maxDate && end.isAfter(this.maxDate))+ end = moment(this.maxDate);++ // If the end of the range is before the minimum (if min is set) OR+ // the start of the range is after the max (also if set) don't display this+ // range option.+ if ((this.minDate && end.isBefore(this.minDate)) || (this.maxDate && start.isAfter(this.maxDate))) {+ continue;+ }++ this.ranges[range] = [start, end];+ }++ var list = '<ul>';+ for (range in this.ranges) {+ list += '<li>' + range + '</li>';+ }+ list += '<li>' + this.locale.customRangeLabel + '</li>';+ list += '</ul>';+ this.container.find('.ranges ul').remove();+ this.container.find('.ranges').prepend(list);+ }++ if (typeof callback === 'function') {+ this.cb = callback;+ }++ if (!this.timePicker) {+ this.startDate = this.startDate.startOf('day');+ this.endDate = this.endDate.endOf('day');+ }++ if (this.singleDatePicker) {+ this.opens = 'right';+ this.container.find('.calendar.right').show();+ this.container.find('.calendar.left').hide();+ this.container.find('.ranges').hide();+ if (!this.container.find('.calendar.right').hasClass('single'))+ this.container.find('.calendar.right').addClass('single');+ } else {+ this.container.find('.calendar.right').removeClass('single');+ this.container.find('.ranges').show();+ }++ this.oldStartDate = this.startDate.clone();+ this.oldEndDate = this.endDate.clone();+ this.oldChosenLabel = this.chosenLabel;++ this.leftCalendar = {+ month: moment([this.startDate.year(), this.startDate.month(), 1, this.startDate.hour(), this.startDate.minute()]),+ calendar: []+ };++ this.rightCalendar = {+ month: moment([this.endDate.year(), this.endDate.month(), 1, this.endDate.hour(), this.endDate.minute()]),+ calendar: []+ };++ if (this.opens == 'right') {+ //swap calendar positions+ var left = this.container.find('.calendar.left');+ var right = this.container.find('.calendar.right');+ left.removeClass('left').addClass('right');+ right.removeClass('right').addClass('left');+ }++ if (typeof options.ranges === 'undefined' && !this.singleDatePicker) {+ this.container.addClass('show-calendar');+ }++ this.container.addClass('opens' + this.opens);++ this.updateView();+ this.updateCalendars();++ },++ setStartDate: function(startDate) {+ if (typeof startDate === 'string')+ this.startDate = moment(startDate, this.format);++ if (typeof startDate === 'object')+ this.startDate = moment(startDate);++ if (!this.timePicker)+ this.startDate = this.startDate.startOf('day');++ this.oldStartDate = this.startDate.clone();++ this.updateView();+ this.updateCalendars();+ },++ setEndDate: function(endDate) {+ if (typeof endDate === 'string')+ this.endDate = moment(endDate, this.format);++ if (typeof endDate === 'object')+ this.endDate = moment(endDate);++ if (!this.timePicker)+ this.endDate = this.endDate.endOf('day');++ this.oldEndDate = this.endDate.clone();++ this.updateView();+ this.updateCalendars();+ },++ updateView: function () {+ this.leftCalendar.month.month(this.startDate.month()).year(this.startDate.year());+ this.rightCalendar.month.month(this.endDate.month()).year(this.endDate.year());+ this.updateFormInputs();+ },++ updateFormInputs: function () {+ this.container.find('input[name=daterangepicker_start]').val(this.startDate.format(this.format));+ this.container.find('input[name=daterangepicker_end]').val(this.endDate.format(this.format));++ if (this.startDate.isSame(this.endDate) || this.startDate.isBefore(this.endDate)) {+ this.container.find('button.applyBtn').removeAttr('disabled');+ } else {+ this.container.find('button.applyBtn').attr('disabled', 'disabled');+ }+ },++ updateFromControl: function () {+ if (!this.element.is('input')) return;+ if (!this.element.val().length) return;++ var dateString = this.element.val().split(this.separator),+ start = null,+ end = null;++ if(dateString.length === 2) {+ start = moment(dateString[0], this.format);+ end = moment(dateString[1], this.format);+ }++ if (this.singleDatePicker || start === null || end === null) {+ start = moment(this.element.val(), this.format);+ end = start;+ }++ if (end.isBefore(start)) return;++ this.oldStartDate = this.startDate.clone();+ this.oldEndDate = this.endDate.clone();++ this.startDate = start;+ this.endDate = end;++ if (!this.startDate.isSame(this.oldStartDate) || !this.endDate.isSame(this.oldEndDate))+ this.notify();++ this.updateCalendars();+ },++ notify: function () {+ this.updateView();+ this.cb(this.startDate, this.endDate, this.chosenLabel);+ },++ move: function () {+ var parentOffset = { top: 0, left: 0 };+ if (!this.parentEl.is('body')) {+ parentOffset = {+ top: this.parentEl.offset().top - this.parentEl.scrollTop(),+ left: this.parentEl.offset().left - this.parentEl.scrollLeft()+ };+ }++ if (this.opens == 'left') {+ this.container.css({+ top: this.element.offset().top + this.element.outerHeight() - parentOffset.top,+ right: $(window).width() - this.element.offset().left - this.element.outerWidth() - parentOffset.left,+ left: 'auto'+ });+ if (this.container.offset().left < 0) {+ this.container.css({+ right: 'auto',+ left: 9+ });+ }+ } else {+ this.container.css({+ top: this.element.offset().top + this.element.outerHeight() - parentOffset.top,+ left: this.element.offset().left - parentOffset.left,+ right: 'auto'+ });+ if (this.container.offset().left + this.container.outerWidth() > $(window).width()) {+ this.container.css({+ left: 'auto',+ right: 0+ });+ }+ }+ },++ toggle: function (e) {+ if (this.element.hasClass('active')) {+ this.hide();+ } else {+ this.show();+ }+ },++ show: function (e) {+ this.element.addClass('active');+ this.container.show();+ this.move();++ // Create a click proxy that is private to this instance of datepicker, for unbinding+ this._outsideClickProxy = $.proxy(function (e) { this.outsideClick(e); }, this);+ // Bind global datepicker mousedown for hiding and+ $(document)+ .on('mousedown.daterangepicker', this._outsideClickProxy)+ // also explicitly play nice with Bootstrap dropdowns, which stopPropagation when clicking them+ .on('click.daterangepicker', '[data-toggle=dropdown]', this._outsideClickProxy)+ // and also close when focus changes to outside the picker (eg. tabbing between controls)+ .on('focusin.daterangepicker', this._outsideClickProxy);++ this.element.trigger('show.daterangepicker', this);+ },++ outsideClick: function (e) {+ var target = $(e.target);+ // if the page is clicked anywhere except within the daterangerpicker/button+ // itself then call this.hide()+ if (+ target.closest(this.element).length ||+ target.closest(this.container).length ||+ target.closest('.calendar-date').length+ ) return;+ this.hide();+ },++ hide: function (e) {+ $(document)+ .off('mousedown.daterangepicker', this._outsideClickProxy)+ .off('click.daterangepicker', this._outsideClickProxy)+ .off('focusin.daterangepicker', this._outsideClickProxy);++ this.element.removeClass('active');+ this.container.hide();++ if (!this.startDate.isSame(this.oldStartDate) || !this.endDate.isSame(this.oldEndDate))+ this.notify();++ this.oldStartDate = this.startDate.clone();+ this.oldEndDate = this.endDate.clone();++ this.element.trigger('hide.daterangepicker', this);+ },++ enterRange: function (e) {+ // mouse pointer has entered a range label+ var label = e.target.innerHTML;+ if (label == this.locale.customRangeLabel) {+ this.updateView();+ } else {+ var dates = this.ranges[label];+ this.container.find('input[name=daterangepicker_start]').val(dates[0].format(this.format));+ this.container.find('input[name=daterangepicker_end]').val(dates[1].format(this.format));+ }+ },++ showCalendars: function() {+ this.container.addClass('show-calendar');+ this.move();+ },++ hideCalendars: function() {+ this.container.removeClass('show-calendar');+ },++ updateInputText: function() {+ if (this.element.is('input') && !this.singleDatePicker) {+ this.element.val(this.startDate.format(this.format) + this.separator + this.endDate.format(this.format));+ } else if (this.element.is('input')) {+ this.element.val(this.startDate.format(this.format));+ }+ },++ clickRange: function (e) {+ var label = e.target.innerHTML;+ this.chosenLabel = label;+ if (label == this.locale.customRangeLabel) {+ this.showCalendars();+ } else {+ var dates = this.ranges[label];++ this.startDate = dates[0];+ this.endDate = dates[1];++ if (!this.timePicker) {+ this.startDate.startOf('day');+ this.endDate.endOf('day');+ }++ this.leftCalendar.month.month(this.startDate.month()).year(this.startDate.year()).hour(this.startDate.hour()).minute(this.startDate.minute());+ this.rightCalendar.month.month(this.endDate.month()).year(this.endDate.year()).hour(this.endDate.hour()).minute(this.endDate.minute());+ this.updateCalendars();++ this.updateInputText();++ this.hideCalendars();+ this.hide();+ this.element.trigger('apply.daterangepicker', this);+ }+ },++ clickPrev: function (e) {+ var cal = $(e.target).parents('.calendar');+ if (cal.hasClass('left')) {+ this.leftCalendar.month.subtract('month', 1);+ } else {+ this.rightCalendar.month.subtract('month', 1);+ }+ this.updateCalendars();+ },++ clickNext: function (e) {+ var cal = $(e.target).parents('.calendar');+ if (cal.hasClass('left')) {+ this.leftCalendar.month.add('month', 1);+ } else {+ this.rightCalendar.month.add('month', 1);+ }+ this.updateCalendars();+ },++ enterDate: function (e) {++ var title = $(e.target).attr('data-title');+ var row = title.substr(1, 1);+ var col = title.substr(3, 1);+ var cal = $(e.target).parents('.calendar');++ if (cal.hasClass('left')) {+ this.container.find('input[name=daterangepicker_start]').val(this.leftCalendar.calendar[row][col].format(this.format));+ } else {+ this.container.find('input[name=daterangepicker_end]').val(this.rightCalendar.calendar[row][col].format(this.format));+ }++ },++ clickDate: function (e) {+ var title = $(e.target).attr('data-title');+ var row = title.substr(1, 1);+ var col = title.substr(3, 1);+ var cal = $(e.target).parents('.calendar');++ var startDate, endDate;+ if (cal.hasClass('left')) {+ startDate = this.leftCalendar.calendar[row][col];+ endDate = this.endDate;+ if (typeof this.dateLimit === 'object') {+ var maxDate = moment(startDate).add(this.dateLimit).startOf('day');+ if (endDate.isAfter(maxDate)) {+ endDate = maxDate;+ }+ }+ } else {+ startDate = this.startDate;+ endDate = this.rightCalendar.calendar[row][col];+ if (typeof this.dateLimit === 'object') {+ var minDate = moment(endDate).subtract(this.dateLimit).startOf('day');+ if (startDate.isBefore(minDate)) {+ startDate = minDate;+ }+ }+ }++ if (this.singleDatePicker && cal.hasClass('left')) {+ endDate = startDate.clone();+ } else if (this.singleDatePicker && cal.hasClass('right')) {+ startDate = endDate.clone();+ }++ cal.find('td').removeClass('active');++ if (startDate.isSame(endDate) || startDate.isBefore(endDate)) {+ $(e.target).addClass('active');+ this.startDate = startDate;+ this.endDate = endDate;+ this.chosenLabel = this.locale.customRangeLabel;+ } else if (startDate.isAfter(endDate)) {+ $(e.target).addClass('active');+ var difference = this.endDate.diff(this.startDate);+ this.startDate = startDate;+ this.endDate = moment(startDate).add('ms', difference);+ this.chosenLabel = this.locale.customRangeLabel;+ }++ this.leftCalendar.month.month(this.startDate.month()).year(this.startDate.year());+ this.rightCalendar.month.month(this.endDate.month()).year(this.endDate.year());+ this.updateCalendars();++ if (!this.timePicker)+ endDate.endOf('day');++ if (this.singleDatePicker)+ this.clickApply();+ },++ clickApply: function (e) {+ this.updateInputText();+ this.hide();+ this.element.trigger('apply.daterangepicker', this);+ },++ clickCancel: function (e) {+ this.startDate = this.oldStartDate;+ this.endDate = this.oldEndDate;+ this.chosenLabel = this.oldChosenLabel;+ this.updateView();+ this.updateCalendars();+ this.hide();+ this.element.trigger('cancel.daterangepicker', this);+ },++ updateMonthYear: function (e) {+ var isLeft = $(e.target).closest('.calendar').hasClass('left'),+ leftOrRight = isLeft ? 'left' : 'right',+ cal = this.container.find('.calendar.'+leftOrRight);++ // Month must be Number for new moment versions+ var month = parseInt(cal.find('.monthselect').val(), 10);+ var year = cal.find('.yearselect').val();++ this[leftOrRight+'Calendar'].month.month(month).year(year);+ this.updateCalendars();+ },++ updateTime: function(e) {++ var cal = $(e.target).closest('.calendar'),+ isLeft = cal.hasClass('left');++ var hour = parseInt(cal.find('.hourselect').val(), 10);+ var minute = parseInt(cal.find('.minuteselect').val(), 10);++ if (this.timePicker12Hour) {+ var ampm = cal.find('.ampmselect').val();+ if (ampm === 'PM' && hour < 12)+ hour += 12;+ if (ampm === 'AM' && hour === 12)+ hour = 0;+ }++ if (isLeft) {+ var start = this.startDate.clone();+ start.hour(hour);+ start.minute(minute);+ this.startDate = start;+ this.leftCalendar.month.hour(hour).minute(minute);+ } else {+ var end = this.endDate.clone();+ end.hour(hour);+ end.minute(minute);+ this.endDate = end;+ this.rightCalendar.month.hour(hour).minute(minute);+ }++ this.updateCalendars();+ },++ updateCalendars: function () {+ this.leftCalendar.calendar = this.buildCalendar(this.leftCalendar.month.month(), this.leftCalendar.month.year(), this.leftCalendar.month.hour(), this.leftCalendar.month.minute(), 'left');+ this.rightCalendar.calendar = this.buildCalendar(this.rightCalendar.month.month(), this.rightCalendar.month.year(), this.rightCalendar.month.hour(), this.rightCalendar.month.minute(), 'right');+ this.container.find('.calendar.left').empty().html(this.renderCalendar(this.leftCalendar.calendar, this.startDate, this.minDate, this.maxDate));+ this.container.find('.calendar.right').empty().html(this.renderCalendar(this.rightCalendar.calendar, this.endDate, this.startDate, this.maxDate));++ this.container.find('.ranges li').removeClass('active');+ var customRange = true;+ var i = 0;+ for (var range in this.ranges) {+ if (this.timePicker) {+ if (this.startDate.isSame(this.ranges[range][0]) && this.endDate.isSame(this.ranges[range][1])) {+ customRange = false;+ this.chosenLabel = this.container.find('.ranges li:eq(' + i + ')')+ .addClass('active').html();+ }+ } else {+ //ignore times when comparing dates if time picker is not enabled+ if (this.startDate.format('YYYY-MM-DD') == this.ranges[range][0].format('YYYY-MM-DD') && this.endDate.format('YYYY-MM-DD') == this.ranges[range][1].format('YYYY-MM-DD')) {+ customRange = false;+ this.chosenLabel = this.container.find('.ranges li:eq(' + i + ')')+ .addClass('active').html();+ }+ }+ i++;+ }+ if (customRange) {+ this.chosenLabel = this.container.find('.ranges li:last')+ .addClass('active').html();+ }+ },++ buildCalendar: function (month, year, hour, minute, side) {+ var firstDay = moment([year, month, 1]);+ var lastMonth = moment(firstDay).subtract('month', 1).month();+ var lastYear = moment(firstDay).subtract('month', 1).year();++ var daysInLastMonth = moment([lastYear, lastMonth]).daysInMonth();++ var dayOfWeek = firstDay.day();++ var i;++ //initialize a 6 rows x 7 columns array for the calendar+ var calendar = [];+ for (i = 0; i < 6; i++) {+ calendar[i] = [];+ }++ //populate the calendar with date objects+ var startDay = daysInLastMonth - dayOfWeek + this.locale.firstDay + 1;+ if (startDay > daysInLastMonth)+ startDay -= 7;++ if (dayOfWeek == this.locale.firstDay)+ startDay = daysInLastMonth - 6;++ var curDate = moment([lastYear, lastMonth, startDay, 12, minute]);+ var col, row;+ for (i = 0, col = 0, row = 0; i < 42; i++, col++, curDate = moment(curDate).add('hour', 24)) {+ if (i > 0 && col % 7 === 0) {+ col = 0;+ row++;+ }+ calendar[row][col] = curDate.clone().hour(hour);+ curDate.hour(12);+ }++ return calendar;+ },++ renderDropdowns: function (selected, minDate, maxDate) {+ var currentMonth = selected.month();+ var monthHtml = '<select class="monthselect">';+ var inMinYear = false;+ var inMaxYear = false;++ for (var m = 0; m < 12; m++) {+ if ((!inMinYear || m >= minDate.month()) && (!inMaxYear || m <= maxDate.month())) {+ monthHtml += "<option value='" + m + "'" ++ (m === currentMonth ? " selected='selected'" : "") ++ ">" + this.locale.monthNames[m] + "</option>";+ }+ }+ monthHtml += "</select>";++ var currentYear = selected.year();+ var maxYear = (maxDate && maxDate.year()) || (currentYear + 5);+ var minYear = (minDate && minDate.year()) || (currentYear - 50);+ var yearHtml = '<select class="yearselect">';++ for (var y = minYear; y <= maxYear; y++) {+ yearHtml += '<option value="' + y + '"' ++ (y === currentYear ? ' selected="selected"' : '') ++ '>' + y + '</option>';+ }++ yearHtml += '</select>';++ return monthHtml + yearHtml;+ },++ renderCalendar: function (calendar, selected, minDate, maxDate) {++ var html = '<div class="calendar-date">';+ html += '<table class="table-condensed">';+ html += '<thead>';+ html += '<tr>';++ // add empty cell for week number+ if (this.showWeekNumbers)+ html += '<th></th>';++ if (!minDate || minDate.isBefore(calendar[1][1])) {+ html += '<th class="prev available"><i class="fa fa-arrow-left icon-arrow-left glyphicon glyphicon-arrow-left"></i></th>';+ } else {+ html += '<th></th>';+ }++ var dateHtml = this.locale.monthNames[calendar[1][1].month()] + calendar[1][1].format(" YYYY");++ if (this.showDropdowns) {+ dateHtml = this.renderDropdowns(calendar[1][1], minDate, maxDate);+ }++ html += '<th colspan="5" class="month">' + dateHtml + '</th>';+ if (!maxDate || maxDate.isAfter(calendar[1][1])) {+ html += '<th class="next available"><i class="fa fa-arrow-right icon-arrow-right glyphicon glyphicon-arrow-right"></i></th>';+ } else {+ html += '<th></th>';+ }++ html += '</tr>';+ html += '<tr>';++ // add week number label+ if (this.showWeekNumbers)+ html += '<th class="week">' + this.locale.weekLabel + '</th>';++ $.each(this.locale.daysOfWeek, function (index, dayOfWeek) {+ html += '<th>' + dayOfWeek + '</th>';+ });++ html += '</tr>';+ html += '</thead>';+ html += '<tbody>';++ for (var row = 0; row < 6; row++) {+ html += '<tr>';++ // add week number+ if (this.showWeekNumbers)+ html += '<td class="week">' + calendar[row][0].week() + '</td>';++ for (var col = 0; col < 7; col++) {+ var cname = 'available ';+ cname += (calendar[row][col].month() == calendar[1][1].month()) ? '' : 'off';++ if ((minDate && calendar[row][col].isBefore(minDate, 'day')) || (maxDate && calendar[row][col].isAfter(maxDate, 'day'))) {+ cname = ' off disabled ';+ } else if (calendar[row][col].format('YYYY-MM-DD') == selected.format('YYYY-MM-DD')) {+ cname += ' active ';+ if (calendar[row][col].format('YYYY-MM-DD') == this.startDate.format('YYYY-MM-DD')) {+ cname += ' start-date ';+ }+ if (calendar[row][col].format('YYYY-MM-DD') == this.endDate.format('YYYY-MM-DD')) {+ cname += ' end-date ';+ }+ } else if (calendar[row][col] >= this.startDate && calendar[row][col] <= this.endDate) {+ cname += ' in-range ';+ if (calendar[row][col].isSame(this.startDate)) { cname += ' start-date '; }+ if (calendar[row][col].isSame(this.endDate)) { cname += ' end-date '; }+ }++ var title = 'r' + row + 'c' + col;+ html += '<td class="' + cname.replace(/\s+/g, ' ').replace(/^\s?(.*?)\s?$/, '$1') + '" data-title="' + title + '">' + calendar[row][col].date() + '</td>';+ }+ html += '</tr>';+ }++ html += '</tbody>';+ html += '</table>';+ html += '</div>';++ var i;+ if (this.timePicker) {++ html += '<div class="calendar-time">';+ html += '<select class="hourselect">';+ var start = 0;+ var end = 23;+ var selected_hour = selected.hour();+ if (this.timePicker12Hour) {+ start = 1;+ end = 12;+ if (selected_hour >= 12)+ selected_hour -= 12;+ if (selected_hour === 0)+ selected_hour = 12;+ }++ for (i = start; i <= end; i++) {+ if (i == selected_hour) {+ html += '<option value="' + i + '" selected="selected">' + i + '</option>';+ } else {+ html += '<option value="' + i + '">' + i + '</option>';+ }+ }++ html += '</select> : ';++ html += '<select class="minuteselect">';++ for (i = 0; i < 60; i += this.timePickerIncrement) {+ var num = i;+ if (num < 10)+ num = '0' + num;+ if (i == selected.minute()) {+ html += '<option value="' + i + '" selected="selected">' + num + '</option>';+ } else {+ html += '<option value="' + i + '">' + num + '</option>';+ }+ }++ html += '</select> ';++ if (this.timePicker12Hour) {+ html += '<select class="ampmselect">';+ if (selected.hour() >= 12) {+ html += '<option value="AM">AM</option><option value="PM" selected="selected">PM</option>';+ } else {+ html += '<option value="AM" selected="selected">AM</option><option value="PM">PM</option>';+ }+ html += '</select>';+ }++ html += '</div>';++ }++ return html;++ },++ remove: function() {++ this.container.remove();+ this.element.off('.daterangepicker');+ this.element.removeData('daterangepicker');++ }++ };++ $.fn.daterangepicker = function (options, cb) {+ this.each(function () {+ var el = $(this);+ if (el.data('daterangepicker'))+ el.data('daterangepicker').remove();+ el.data('daterangepicker', new DateRangePicker(el, options, cb));+ });+ return this;+ };++}(window.jQuery, window.moment);diff --git a/app/assets/javascripts/blazer/highlight.pack.js b/app/assets/javascripts/blazer/highlight.pack.jsnew file mode 100644index 00000000..36235f91--- /dev/null+++ b/app/assets/javascripts/blazer/highlight.pack.js@@ -0,0 +1 @@+var hljs=new function(){function j(v){return v.replace(/&/gm,"&").replace(/</gm,"<").replace(/>/gm,">")}function t(v){return v.nodeName.toLowerCase()}function h(w,x){var v=w&&w.exec(x);return v&&v.index==0}function r(w){var v=(w.className+" "+(w.parentNode?w.parentNode.className:"")).split(/\s+/);v=v.map(function(x){return x.replace(/^lang(uage)?-/,"")});return v.filter(function(x){return i(x)||x=="no-highlight"})[0]}function o(x,y){var v={};for(var w in x){v[w]=x[w]}if(y){for(var w in y){v[w]=y[w]}}return v}function u(x){var v=[];(function w(y,z){for(var A=y.firstChild;A;A=A.nextSibling){if(A.nodeType==3){z+=A.nodeValue.length}else{if(t(A)=="br"){z+=1}else{if(A.nodeType==1){v.push({event:"start",offset:z,node:A});z=w(A,z);v.push({event:"stop",offset:z,node:A})}}}}return z})(x,0);return v}function q(w,y,C){var x=0;var F="";var z=[];function B(){if(!w.length||!y.length){return w.length?w:y}if(w[0].offset!=y[0].offset){return(w[0].offset<y[0].offset)?w:y}return y[0].event=="start"?w:y}function A(H){function G(I){return" "+I.nodeName+'="'+j(I.value)+'"'}F+="<"+t(H)+Array.prototype.map.call(H.attributes,G).join("")+">"}function E(G){F+="</"+t(G)+">"}function v(G){(G.event=="start"?A:E)(G.node)}while(w.length||y.length){var D=B();F+=j(C.substr(x,D[0].offset-x));x=D[0].offset;if(D==w){z.reverse().forEach(E);do{v(D.splice(0,1)[0]);D=B()}while(D==w&&D.length&&D[0].offset==x);z.reverse().forEach(A)}else{if(D[0].event=="start"){z.push(D[0].node)}else{z.pop()}v(D.splice(0,1)[0])}}return F+j(C.substr(x))}function m(y){function v(z){return(z&&z.source)||z}function w(A,z){return RegExp(v(A),"m"+(y.cI?"i":"")+(z?"g":""))}function x(D,C){if(D.compiled){return}D.compiled=true;D.k=D.k||D.bK;if(D.k){var z={};function E(G,F){if(y.cI){F=F.toLowerCase()}F.split(" ").forEach(function(H){var I=H.split("|");z[I[0]]=[G,I[1]?Number(I[1]):1]})}if(typeof D.k=="string"){E("keyword",D.k)}else{Object.keys(D.k).forEach(function(F){E(F,D.k[F])})}D.k=z}D.lR=w(D.l||/\b[A-Za-z0-9_]+\b/,true);if(C){if(D.bK){D.b="\\b("+D.bK.split(" ").join("|")+")\\b"}if(!D.b){D.b=/\B|\b/}D.bR=w(D.b);if(!D.e&&!D.eW){D.e=/\B|\b/}if(D.e){D.eR=w(D.e)}D.tE=v(D.e)||"";if(D.eW&&C.tE){D.tE+=(D.e?"|":"")+C.tE}}if(D.i){D.iR=w(D.i)}if(D.r===undefined){D.r=1}if(!D.c){D.c=[]}var B=[];D.c.forEach(function(F){if(F.v){F.v.forEach(function(G){B.push(o(F,G))})}else{B.push(F=="self"?D:F)}});D.c=B;D.c.forEach(function(F){x(F,D)});if(D.starts){x(D.starts,C)}var A=D.c.map(function(F){return F.bK?"\\.?("+F.b+")\\.?":F.b}).concat([D.tE,D.i]).map(v).filter(Boolean);D.t=A.length?w(A.join("|"),true):{exec:function(F){return null}};D.continuation={}}x(y)}function c(S,L,J,R){function v(U,V){for(var T=0;T<V.c.length;T++){if(h(V.c[T].bR,U)){return V.c[T]}}}function z(U,T){if(h(U.eR,T)){return U}if(U.eW){return z(U.parent,T)}}function A(T,U){return !J&&h(U.iR,T)}function E(V,T){var U=M.cI?T[0].toLowerCase():T[0];return V.k.hasOwnProperty(U)&&V.k[U]}function w(Z,X,W,V){var T=V?"":b.classPrefix,U='<span class="'+T,Y=W?"":"</span>";U+=Z+'">';return U+X+Y}function N(){if(!I.k){return j(C)}var T="";var W=0;I.lR.lastIndex=0;var U=I.lR.exec(C);while(U){T+=j(C.substr(W,U.index-W));var V=E(I,U);if(V){H+=V[1];T+=w(V[0],j(U[0]))}else{T+=j(U[0])}W=I.lR.lastIndex;U=I.lR.exec(C)}return T+j(C.substr(W))}function F(){if(I.sL&&!f[I.sL]){return j(C)}var T=I.sL?c(I.sL,C,true,I.continuation.top):e(C);if(I.r>0){H+=T.r}if(I.subLanguageMode=="continuous"){I.continuation.top=T.top}return w(T.language,T.value,false,true)}function Q(){return I.sL!==undefined?F():N()}function P(V,U){var T=V.cN?w(V.cN,"",true):"";if(V.rB){D+=T;C=""}else{if(V.eB){D+=j(U)+T;C=""}else{D+=T;C=U}}I=Object.create(V,{parent:{value:I}})}function G(T,X){C+=T;if(X===undefined){D+=Q();return 0}var V=v(X,I);if(V){D+=Q();P(V,X);return V.rB?0:X.length}var W=z(I,X);if(W){var U=I;if(!(U.rE||U.eE)){C+=X}D+=Q();do{if(I.cN){D+="</span>"}H+=I.r;I=I.parent}while(I!=W.parent);if(U.eE){D+=j(X)}C="";if(W.starts){P(W.starts,"")}return U.rE?0:X.length}if(A(X,I)){throw new Error('Illegal lexeme "'+X+'" for mode "'+(I.cN||"<unnamed>")+'"')}C+=X;return X.length||1}var M=i(S);if(!M){throw new Error('Unknown language: "'+S+'"')}m(M);var I=R||M;var D="";for(var K=I;K!=M;K=K.parent){if(K.cN){D+=w(K.cN,D,true)}}var C="";var H=0;try{var B,y,x=0;while(true){I.t.lastIndex=x;B=I.t.exec(L);if(!B){break}y=G(L.substr(x,B.index-x),B[0]);x=B.index+y}G(L.substr(x));for(var K=I;K.parent;K=K.parent){if(K.cN){D+="</span>"}}return{r:H,value:D,language:S,top:I}}catch(O){if(O.message.indexOf("Illegal")!=-1){return{r:0,value:j(L)}}else{throw O}}}function e(y,x){x=x||b.languages||Object.keys(f);var v={r:0,value:j(y)};var w=v;x.forEach(function(z){if(!i(z)){return}var A=c(z,y,false);A.language=z;if(A.r>w.r){w=A}if(A.r>v.r){w=v;v=A}});if(w.language){v.second_best=w}return v}function g(v){if(b.tabReplace){v=v.replace(/^((<[^>]+>|\t)+)/gm,function(w,z,y,x){return z.replace(/\t/g,b.tabReplace)})}if(b.useBR){v=v.replace(/\n/g,"<br>")}return v}function p(z){var y=b.useBR?z.innerHTML.replace(/\n/g,"").replace(/<br>|<br [^>]*>/g,"\n").replace(/<[^>]*>/g,""):z.textContent;var A=r(z);if(A=="no-highlight"){return}var v=A?c(A,y,true):e(y);var w=u(z);if(w.length){var x=document.createElementNS("http://www.w3.org/1999/xhtml","pre");x.innerHTML=v.value;v.value=q(w,u(x),y)}v.value=g(v.value);z.innerHTML=v.value;z.className+=" hljs "+(!A&&v.language||"");z.result={language:v.language,re:v.r};if(v.second_best){z.second_best={language:v.second_best.language,re:v.second_best.r}}}var b={classPrefix:"hljs-",tabReplace:null,useBR:false,languages:undefined};function s(v){b=o(b,v)}function l(){if(l.called){return}l.called=true;var v=document.querySelectorAll("pre code");Array.prototype.forEach.call(v,p)}function a(){addEventListener("DOMContentLoaded",l,false);addEventListener("load",l,false)}var f={};var n={};function d(v,x){var w=f[v]=x(this);if(w.aliases){w.aliases.forEach(function(y){n[y]=v})}}function k(){return Object.keys(f)}function i(v){return f[v]||f[n[v]]}this.highlight=c;this.highlightAuto=e;this.fixMarkup=g;this.highlightBlock=p;this.configure=s;this.initHighlighting=l;this.initHighlightingOnLoad=a;this.registerLanguage=d;this.listLanguages=k;this.getLanguage=i;this.inherit=o;this.IR="[a-zA-Z][a-zA-Z0-9_]*";this.UIR="[a-zA-Z_][a-zA-Z0-9_]*";this.NR="\\b\\d+(\\.\\d+)?";this.CNR="(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)";this.BNR="\\b(0b[01]+)";this.RSR="!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|-|-=|/=|/|:|;|<<|<<=|<=|<|===|==|=|>>>=|>>=|>=|>>>|>>|>|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~";this.BE={b:"\\\\[\\s\\S]",r:0};this.ASM={cN:"string",b:"'",e:"'",i:"\\n",c:[this.BE]};this.QSM={cN:"string",b:'"',e:'"',i:"\\n",c:[this.BE]};this.PWM={b:/\b(a|an|the|are|I|I'm|isn't|don't|doesn't|won't|but|just|should|pretty|simply|enough|gonna|going|wtf|so|such)\b/};this.CLCM={cN:"comment",b:"//",e:"$",c:[this.PWM]};this.CBCM={cN:"comment",b:"/\\*",e:"\\*/",c:[this.PWM]};this.HCM={cN:"comment",b:"#",e:"$",c:[this.PWM]};this.NM={cN:"number",b:this.NR,r:0};this.CNM={cN:"number",b:this.CNR,r:0};this.BNM={cN:"number",b:this.BNR,r:0};this.CSSNM={cN:"number",b:this.NR+"(%|em|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc|px|deg|grad|rad|turn|s|ms|Hz|kHz|dpi|dpcm|dppx)?",r:0};this.RM={cN:"regexp",b:/\//,e:/\/[gim]*/,i:/\n/,c:[this.BE,{b:/\[/,e:/\]/,r:0,c:[this.BE]}]};this.TM={cN:"title",b:this.IR,r:0};this.UTM={cN:"title",b:this.UIR,r:0}}();hljs.registerLanguage("sql",function(a){var b={cN:"comment",b:"--",e:"$"};var c={cN:"variable",b:"{",e:"}"};return{cI:true,i:/[<>]/,c:[{cN:"operator",bK:"begin end start commit rollback savepoint lock alter create drop rename call delete do handler insert load replace select truncate update set show pragma grant merge describe use explain help declare prepare execute deallocate savepoint release unlock purge reset change stop analyze cache flush optimize repair kill install uninstall checksum restore check backup",e:/;/,eW:true,k:{keyword:"abs absolute acos action add adddate addtime aes_decrypt aes_encrypt after aggregate all allocate alter analyze and any are as asc ascii asin assertion at atan atan2 atn2 authorization authors avg backup before begin benchmark between bin binlog bit_and bit_count bit_length bit_or bit_xor both by cache call cascade cascaded case cast catalog ceil ceiling chain change changed char_length character_length charindex charset check checksum checksum_agg choose close coalesce coercibility collate collation collationproperty column columns columns_updated commit compress concat concat_ws concurrent connect connection connection_id consistent constraint constraints continue contributors conv convert convert_tz corresponding cos cot count count_big crc32 create cross cume_dist curdate current current_date current_time current_timestamp current_user cursor curtime data database databases datalength date_add date_format date_sub dateadd datediff datefromparts datename datepart datetime2fromparts datetimeoffsetfromparts day dayname dayofmonth dayofweek dayofyear deallocate declare decode default deferrable deferred degrees delayed delete des_decrypt des_encrypt des_key_file desc describe descriptor diagnostics difference disconnect distinct distinctrow div do domain double drop dumpfile each else elt enclosed encode encrypt end end-exec engine engines eomonth errors escape escaped event eventdata events except exception exec execute exists exp explain export_set extended external extract fast fetch field fields find_in_set first first_value floor flush for force foreign format found found_rows from from_base64 from_days from_unixtime full function get get_format get_lock getdate getutcdate global go goto grant grants greatest group group_concat grouping grouping_id gtid_subset gtid_subtract handler having help hex high_priority hosts hour ident_current ident_incr ident_seed identified identity if ifnull ignore iif ilike immediate in index indicator inet6_aton inet6_ntoa inet_aton inet_ntoa infile initially inner innodb input insert install instr intersect into is is_free_lock is_ipv4 is_ipv4_compat is_ipv4_mapped is_not is_not_null is_used_lock isdate isnull isolation join key kill language last last_day last_insert_id last_value lcase lead leading least leaves left len lenght level like limit lines ln load load_file local localtime localtimestamp locate lock log log10 log2 logfile logs low_priority lower lpad ltrim make_set makedate maketime master master_pos_wait match matched max md5 medium merge microsecond mid min minute mod mode module month monthname mutex name_const names national natural nchar next no no_write_to_binlog not now nullif nvarchar oct octet_length of old_password on only open optimize option optionally or ord order outer outfile output pad parse partial partition password patindex percent_rank percentile_cont percentile_disc period_add period_diff pi plugin position pow power pragma precision prepare preserve primary prior privileges procedure procedure_analyze processlist profile profiles public publishingservername purge quarter query quick quote quotename radians rand read references regexp relative relaylog release release_lock rename repair repeat replace replicate reset restore restrict return returns reverse revoke right rlike rollback rollup round row row_count rows rpad rtrim savepoint schema scroll sec_to_time second section select serializable server session session_user set sha sha1 sha2 share show sign sin size slave sleep smalldatetimefromparts snapshot some soname soundex sounds_like space sql sql_big_result sql_buffer_result sql_cache sql_calc_found_rows sql_no_cache sql_small_result sql_variant_property sqlstate sqrt square start starting status std stddev stddev_pop stddev_samp stdev stdevp stop str str_to_date straight_join strcmp string stuff subdate substr substring subtime subtring_index sum switchoffset sysdate sysdatetime sysdatetimeoffset system_user sysutcdatetime table tables tablespace tan temporary terminated tertiary_weights then time time_format time_to_sec timediff timefromparts timestamp timestampadd timestampdiff timezone_hour timezone_minute to to_base64 to_days to_seconds todatetimeoffset trailing transaction translation trigger trigger_nestlevel triggers trim truncate try_cast try_convert try_parse ucase uncompress uncompressed_length unhex unicode uninstall union unique unix_timestamp unknown unlock update upgrade upped upper usage use user user_resources using utc_date utc_time utc_timestamp uuid uuid_short validate_password_strength value values var var_pop var_samp variables variance varp version view warnings week weekday weekofyear weight_string when whenever where with work write xml xor year yearweek zon",literal:"true false null",built_in:"array bigint binary bit blob boolean char character date dec decimal float int integer interval number numeric real serial smallint varchar varying int8 serial8 text"},c:[{cN:"string",b:"'",e:"'",c:[a.BE,{b:"''"}]},{cN:"string",b:'"',e:'"',c:[a.BE,{b:'""'}]},{cN:"string",b:"`",e:"`",c:[a.BE]},a.CNM,a.CBCM,b,c]},a.CBCM,b,c]}});\ No newline at end of filediff --git a/app/assets/javascripts/blazer/jquery.js b/app/assets/javascripts/blazer/jquery.jsnew file mode 100644index 00000000..30c2a631--- /dev/null+++ b/app/assets/javascripts/blazer/jquery.js@@ -0,0 +1,10308 @@+/*!+ * jQuery JavaScript Library v1.11.1+ * http://jquery.com/+ *+ * Includes Sizzle.js+ * http://sizzlejs.com/+ *+ * Copyright 2005, 2014 jQuery Foundation, Inc. and other contributors+ * Released under the MIT license+ * http://jquery.org/license+ *+ * Date: 2014-05-01T17:42Z+ */++(function( global, factory ) {++ if ( typeof module === "object" && typeof module.exports === "object" ) {+ // For CommonJS and CommonJS-like environments where a proper window is present,+ // execute the factory and get jQuery+ // For environments that do not inherently posses a window with a document+ // (such as Node.js), expose a jQuery-making factory as module.exports+ // This accentuates the need for the creation of a real window+ // e.g. var jQuery = require("jquery")(window);+ // See ticket #14549 for more info+ module.exports = global.document ?+ factory( global, true ) :+ function( w ) {+ if ( !w.document ) {+ throw new Error( "jQuery requires a window with a document" );+ }+ return factory( w );+ };+ } else {+ factory( global );+ }++// Pass this if window is not defined yet+}(typeof window !== "undefined" ? window : this, function( window, noGlobal ) {++// Can't do this because several apps including ASP.NET trace+// the stack via arguments.caller.callee and Firefox dies if+// you try to trace through "use strict" call chains. (#13335)+// Support: Firefox 18++//++var deletedIds = [];++var slice = deletedIds.slice;++var concat = deletedIds.concat;++var push = deletedIds.push;++var indexOf = deletedIds.indexOf;++var class2type = {};++var toString = class2type.toString;++var hasOwn = class2type.hasOwnProperty;++var support = {};++++var+ version = "1.11.1",++ // Define a local copy of jQuery+ jQuery = function( selector, context ) {+ // The jQuery object is actually just the init constructor 'enhanced'+ // Need init if jQuery is called (just allow error to be thrown if not included)+ return new jQuery.fn.init( selector, context );+ },++ // Support: Android<4.1, IE<9+ // Make sure we trim BOM and NBSP+ rtrim = /^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,++ // Matches dashed string for camelizing+ rmsPrefix = /^-ms-/,+ rdashAlpha = /-([\da-z])/gi,++ // Used by jQuery.camelCase as callback to replace()+ fcamelCase = function( all, letter ) {+ return letter.toUpperCase();+ };++jQuery.fn = jQuery.prototype = {+ // The current version of jQuery being used+ jquery: version,++ constructor: jQuery,++ // Start with an empty selector+ selector: "",++ // The default length of a jQuery object is 0+ length: 0,++ toArray: function() {+ return slice.call( this );+ },++ // Get the Nth element in the matched element set OR+ // Get the whole matched element set as a clean array+ get: function( num ) {+ return num != null ?++ // Return just the one element from the set+ ( num < 0 ? this[ num + this.length ] : this[ num ] ) :++ // Return all the elements in a clean array+ slice.call( this );+ },++ // Take an array of elements and push it onto the stack+ // (returning the new matched element set)+ pushStack: function( elems ) {++ // Build a new jQuery matched element set+ var ret = jQuery.merge( this.constructor(), elems );++ // Add the old object onto the stack (as a reference)+ ret.prevObject = this;+ ret.context = this.context;++ // Return the newly-formed element set+ return ret;+ },++ // Execute a callback for every element in the matched set.+ // (You can seed the arguments with an array of args, but this is+ // only used internally.)+ each: function( callback, args ) {+ return jQuery.each( this, callback, args );+ },++ map: function( callback ) {+ return this.pushStack( jQuery.map(this, function( elem, i ) {+ return callback.call( elem, i, elem );+ }));+ },++ slice: function() {+ return this.pushStack( slice.apply( this, arguments ) );+ },++ first: function() {+ return this.eq( 0 );+ },++ last: function() {+ return this.eq( -1 );+ },++ eq: function( i ) {+ var len = this.length,+ j = +i + ( i < 0 ? len : 0 );+ return this.pushStack( j >= 0 && j < len ? [ this[j] ] : [] );+ },++ end: function() {+ return this.prevObject || this.constructor(null);+ },++ // For internal use only.+ // Behaves like an Array's method, not like a jQuery method.+ push: push,+ sort: deletedIds.sort,+ splice: deletedIds.splice+};++jQuery.extend = jQuery.fn.extend = function() {+ var src, copyIsArray, copy, name, options, clone,+ target = arguments[0] || {},+ i = 1,+ length = arguments.length,+ deep = false;++ // Handle a deep copy situation+ if ( typeof target === "boolean" ) {+ deep = target;++ // skip the boolean and the target+ target = arguments[ i ] || {};+ i++;+ }++ // Handle case when target is a string or something (possible in deep copy)+ if ( typeof target !== "object" && !jQuery.isFunction(target) ) {+ target = {};+ }++ // extend jQuery itself if only one argument is passed+ if ( i === length ) {+ target = this;+ i--;+ }++ for ( ; i < length; i++ ) {+ // Only deal with non-null/undefined values+ if ( (options = arguments[ i ]) != null ) {+ // Extend the base object+ for ( name in options ) {+ src = target[ name ];+ copy = options[ name ];++ // Prevent never-ending loop+ if ( target === copy ) {+ continue;+ }++ // Recurse if we're merging plain objects or arrays+ if ( deep && copy && ( jQuery.isPlainObject(copy) || (copyIsArray = jQuery.isArray(copy)) ) ) {+ if ( copyIsArray ) {+ copyIsArray = false;+ clone = src && jQuery.isArray(src) ? src : [];++ } else {+ clone = src && jQuery.isPlainObject(src) ? src : {};+ }++ // Never move original objects, clone them+ target[ name ] = jQuery.extend( deep, clone, copy );++ // Don't bring in undefined values+ } else if ( copy !== undefined ) {+ target[ name ] = copy;+ }+ }+ }+ }++ // Return the modified object+ return target;+};++jQuery.extend({+ // Unique for each copy of jQuery on the page+ expando: "jQuery" + ( version + Math.random() ).replace( /\D/g, "" ),++ // Assume jQuery is ready without the ready module+ isReady: true,++ error: function( msg ) {+ throw new Error( msg );+ },++ noop: function() {},++ // See test/unit/core.js for details concerning isFunction.+ // Since version 1.3, DOM methods and functions like alert+ // aren't supported. They return false on IE (#2968).+ isFunction: function( obj ) {+ return jQuery.type(obj) === "function";+ },++ isArray: Array.isArray || function( obj ) {+ return jQuery.type(obj) === "array";+ },++ isWindow: function( obj ) {+ /* jshint eqeqeq: false */+ return obj != null && obj == obj.window;+ },++ isNumeric: function( obj ) {+ // parseFloat NaNs numeric-cast false positives (null|true|false|"")+ // ...but misinterprets leading-number strings, particularly hex literals ("0x...")+ // subtraction forces infinities to NaN+ return !jQuery.isArray( obj ) && obj - parseFloat( obj ) >= 0;+ },++ isEmptyObject: function( obj ) {+ var name;+ for ( name in obj ) {+ return false;+ }+ return true;+ },++ isPlainObject: function( obj ) {+ var key;++ // Must be an Object.+ // Because of IE, we also have to check the presence of the constructor property.+ // Make sure that DOM nodes and window objects don't pass through, as well+ if ( !obj || jQuery.type(obj) !== "object" || obj.nodeType || jQuery.isWindow( obj ) ) {+ return false;+ }++ try {+ // Not own constructor property must be Object+ if ( obj.constructor &&+ !hasOwn.call(obj, "constructor") &&+ !hasOwn.call(obj.constructor.prototype, "isPrototypeOf") ) {+ return false;+ }+ } catch ( e ) {+ // IE8,9 Will throw exceptions on certain host objects #9897+ return false;+ }++ // Support: IE<9+ // Handle iteration over inherited properties before own properties.+ if ( support.ownLast ) {+ for ( key in obj ) {+ return hasOwn.call( obj, key );+ }+ }++ // Own properties are enumerated firstly, so to speed up,+ // if last one is own, then all properties are own.+ for ( key in obj ) {}++ return key === undefined || hasOwn.call( obj, key );+ },++ type: function( obj ) {+ if ( obj == null ) {+ return obj + "";+ }+ return typeof obj === "object" || typeof obj === "function" ?+ class2type[ toString.call(obj) ] || "object" :+ typeof obj;+ },++ // Evaluates a script in a global context+ // Workarounds based on findings by Jim Driscoll+ // http://weblogs.java.net/blog/driscoll/archive/2009/09/08/eval-javascript-global-context+ globalEval: function( data ) {+ if ( data && jQuery.trim( data ) ) {+ // We use execScript on Internet Explorer+ // We use an anonymous function so that context is window+ // rather than jQuery in Firefox+ ( window.execScript || function( data ) {+ window[ "eval" ].call( window, data );+ } )( data );+ }+ },++ // Convert dashed to camelCase; used by the css and data modules+ // Microsoft forgot to hump their vendor prefix (#9572)+ camelCase: function( string ) {+ return string.replace( rmsPrefix, "ms-" ).replace( rdashAlpha, fcamelCase );+ },++ nodeName: function( elem, name ) {+ return elem.nodeName && elem.nodeName.toLowerCase() === name.toLowerCase();+ },++ // args is for internal usage only+ each: function( obj, callback, args ) {+ var value,+ i = 0,+ length = obj.length,+ isArray = isArraylike( obj );++ if ( args ) {+ if ( isArray ) {+ for ( ; i < length; i++ ) {+ value = callback.apply( obj[ i ], args );++ if ( value === false ) {+ break;+ }+ }+ } else {+ for ( i in obj ) {+ value = callback.apply( obj[ i ], args );++ if ( value === false ) {+ break;+ }+ }+ }++ // A special, fast, case for the most common use of each+ } else {+ if ( isArray ) {+ for ( ; i < length; i++ ) {+ value = callback.call( obj[ i ], i, obj[ i ] );++ if ( value === false ) {+ break;+ }+ }+ } else {+ for ( i in obj ) {+ value = callback.call( obj[ i ], i, obj[ i ] );++ if ( value === false ) {+ break;+ }+ }+ }+ }++ return obj;+ },++ // Support: Android<4.1, IE<9+ trim: function( text ) {+ return text == null ?+ "" :+ ( text + "" ).replace( rtrim, "" );+ },++ // results is for internal usage only+ makeArray: function( arr, results ) {+ var ret = results || [];++ if ( arr != null ) {+ if ( isArraylike( Object(arr) ) ) {+ jQuery.merge( ret,+ typeof arr === "string" ?+ [ arr ] : arr+ );+ } else {+ push.call( ret, arr );+ }+ }++ return ret;+ },++ inArray: function( elem, arr, i ) {+ var len;++ if ( arr ) {+ if ( indexOf ) {+ return indexOf.call( arr, elem, i );+ }++ len = arr.length;+ i = i ? i < 0 ? Math.max( 0, len + i ) : i : 0;++ for ( ; i < len; i++ ) {+ // Skip accessing in sparse arrays+ if ( i in arr && arr[ i ] === elem ) {+ return i;+ }+ }+ }++ return -1;+ },++ merge: function( first, second ) {+ var len = +second.length,+ j = 0,+ i = first.length;++ while ( j < len ) {+ first[ i++ ] = second[ j++ ];+ }++ // Support: IE<9+ // Workaround casting of .length to NaN on otherwise arraylike objects (e.g., NodeLists)+ if ( len !== len ) {+ while ( second[j] !== undefined ) {+ first[ i++ ] = second[ j++ ];+ }+ }++ first.length = i;++ return first;+ },++ grep: function( elems, callback, invert ) {+ var callbackInverse,+ matches = [],+ i = 0,+ length = elems.length,+ callbackExpect = !invert;++ // Go through the array, only saving the items+ // that pass the validator function+ for ( ; i < length; i++ ) {+ callbackInverse = !callback( elems[ i ], i );+ if ( callbackInverse !== callbackExpect ) {+ matches.push( elems[ i ] );+ }+ }++ return matches;+ },++ // arg is for internal usage only+ map: function( elems, callback, arg ) {+ var value,+ i = 0,+ length = elems.length,+ isArray = isArraylike( elems ),+ ret = [];++ // Go through the array, translating each of the items to their new values+ if ( isArray ) {+ for ( ; i < length; i++ ) {+ value = callback( elems[ i ], i, arg );++ if ( value != null ) {+ ret.push( value );+ }+ }++ // Go through every key on the object,+ } else {+ for ( i in elems ) {+ value = callback( elems[ i ], i, arg );++ if ( value != null ) {+ ret.push( value );+ }+ }+ }++ // Flatten any nested arrays+ return concat.apply( [], ret );+ },++ // A global GUID counter for objects+ guid: 1,++ // Bind a function to a context, optionally partially applying any+ // arguments.+ proxy: function( fn, context ) {+ var args, proxy, tmp;++ if ( typeof context === "string" ) {+ tmp = fn[ context ];+ context = fn;+ fn = tmp;+ }++ // Quick check to determine if target is callable, in the spec+ // this throws a TypeError, but we will just return undefined.+ if ( !jQuery.isFunction( fn ) ) {+ return undefined;+ }++ // Simulated bind+ args = slice.call( arguments, 2 );+ proxy = function() {+ return fn.apply( context || this, args.concat( slice.call( arguments ) ) );+ };++ // Set the guid of unique handler to the same of original handler, so it can be removed+ proxy.guid = fn.guid = fn.guid || jQuery.guid++;++ return proxy;+ },++ now: function() {+ return +( new Date() );+ },++ // jQuery.support is not used in Core but other projects attach their+ // properties to it so it needs to exist.+ support: support+});++// Populate the class2type map+jQuery.each("Boolean Number String Function Array Date RegExp Object Error".split(" "), function(i, name) {+ class2type[ "[object " + name + "]" ] = name.toLowerCase();+});++function isArraylike( obj ) {+ var length = obj.length,+ type = jQuery.type( obj );++ if ( type === "function" || jQuery.isWindow( obj ) ) {+ return false;+ }++ if ( obj.nodeType === 1 && length ) {+ return true;+ }++ return type === "array" || length === 0 ||+ typeof length === "number" && length > 0 && ( length - 1 ) in obj;+}+var Sizzle =+/*!+ * Sizzle CSS Selector Engine v1.10.19+ * http://sizzlejs.com/+ *+ * Copyright 2013 jQuery Foundation, Inc. and other contributors+ * Released under the MIT license+ * http://jquery.org/license+ *+ * Date: 2014-04-18+ */+(function( window ) {++var i,+ support,+ Expr,+ getText,+ isXML,+ tokenize,+ compile,+ select,+ outermostContext,+ sortInput,+ hasDuplicate,++ // Local document vars+ setDocument,+ document,+ docElem,+ documentIsHTML,+ rbuggyQSA,+ rbuggyMatches,+ matches,+ contains,++ // Instance-specific data+ expando = "sizzle" + -(new Date()),+ preferredDoc = window.document,+ dirruns = 0,+ done = 0,+ classCache = createCache(),+ tokenCache = createCache(),+ compilerCache = createCache(),+ sortOrder = function( a, b ) {+ if ( a === b ) {+ hasDuplicate = true;+ }+ return 0;+ },++ // General-purpose constants+ strundefined = typeof undefined,+ MAX_NEGATIVE = 1 << 31,++ // Instance methods+ hasOwn = ({}).hasOwnProperty,+ arr = [],+ pop = arr.pop,+ push_native = arr.push,+ push = arr.push,+ slice = arr.slice,+ // Use a stripped-down indexOf if we can't use a native one+ indexOf = arr.indexOf || function( elem ) {+ var i = 0,+ len = this.length;+ for ( ; i < len; i++ ) {+ if ( this[i] === elem ) {+ return i;+ }+ }+ return -1;+ },++ booleans = "checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",++ // Regular expressions++ // Whitespace characters http://www.w3.org/TR/css3-selectors/#whitespace+ whitespace = "[\\x20\\t\\r\\n\\f]",+ // http://www.w3.org/TR/css3-syntax/#characters+ characterEncoding = "(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",++ // Loosely modeled on CSS identifier characters+ // An unquoted value should be a CSS identifier http://www.w3.org/TR/css3-selectors/#attribute-selectors+ // Proper syntax: http://www.w3.org/TR/CSS21/syndata.html#value-def-identifier+ identifier = characterEncoding.replace( "w", "w#" ),++ // Attribute selectors: http://www.w3.org/TR/selectors/#attribute-selectors+ attributes = "\\[" + whitespace + "*(" + characterEncoding + ")(?:" + whitespace ++ // Operator (capture 2)+ "*([*^$|!~]?=)" + whitespace ++ // "Attribute values must be CSS identifiers [capture 5] or strings [capture 3 or capture 4]"+ "*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|(" + identifier + "))|)" + whitespace ++ "*\\]",++ pseudos = ":(" + characterEncoding + ")(?:\\((" ++ // To reduce the number of selectors needing tokenize in the preFilter, prefer arguments:+ // 1. quoted (capture 3; capture 4 or capture 5)+ "('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|" ++ // 2. simple (capture 6)+ "((?:\\\\.|[^\\\\()[\\]]|" + attributes + ")*)|" ++ // 3. anything else (capture 2)+ ".*" ++ ")\\)|)",++ // Leading and non-escaped trailing whitespace, capturing some non-whitespace characters preceding the latter+ rtrim = new RegExp( "^" + whitespace + "+|((?:^|[^\\\\])(?:\\\\.)*)" + whitespace + "+$", "g" ),++ rcomma = new RegExp( "^" + whitespace + "*," + whitespace + "*" ),+ rcombinators = new RegExp( "^" + whitespace + "*([>+~]|" + whitespace + ")" + whitespace + "*" ),++ rattributeQuotes = new RegExp( "=" + whitespace + "*([^\\]'\"]*?)" + whitespace + "*\\]", "g" ),++ rpseudo = new RegExp( pseudos ),+ ridentifier = new RegExp( "^" + identifier + "$" ),++ matchExpr = {+ "ID": new RegExp( "^#(" + characterEncoding + ")" ),+ "CLASS": new RegExp( "^\\.(" + characterEncoding + ")" ),+ "TAG": new RegExp( "^(" + characterEncoding.replace( "w", "w*" ) + ")" ),+ "ATTR": new RegExp( "^" + attributes ),+ "PSEUDO": new RegExp( "^" + pseudos ),+ "CHILD": new RegExp( "^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\(" + whitespace ++ "*(even|odd|(([+-]|)(\\d*)n|)" + whitespace + "*(?:([+-]|)" + whitespace ++ "*(\\d+)|))" + whitespace + "*\\)|)", "i" ),+ "bool": new RegExp( "^(?:" + booleans + ")$", "i" ),+ // For use in libraries implementing .is()+ // We use this for POS matching in `select`+ "needsContext": new RegExp( "^" + whitespace + "*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\(" ++ whitespace + "*((?:-\\d)?\\d*)" + whitespace + "*\\)|)(?=[^-]|$)", "i" )+ },++ rinputs = /^(?:input|select|textarea|button)$/i,+ rheader = /^h\d$/i,++ rnative = /^[^{]+\{\s*\[native \w/,++ // Easily-parseable/retrievable ID or TAG or CLASS selectors+ rquickExpr = /^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,++ rsibling = /[+~]/,+ rescape = /'|\\/g,++ // CSS escapes http://www.w3.org/TR/CSS21/syndata.html#escaped-characters+ runescape = new RegExp( "\\\\([\\da-f]{1,6}" + whitespace + "?|(" + whitespace + ")|.)", "ig" ),+ funescape = function( _, escaped, escapedWhitespace ) {+ var high = "0x" + escaped - 0x10000;+ // NaN means non-codepoint+ // Support: Firefox<24+ // Workaround erroneous numeric interpretation of +"0x"+ return high !== high || escapedWhitespace ?+ escaped :+ high < 0 ?+ // BMP codepoint+ String.fromCharCode( high + 0x10000 ) :+ // Supplemental Plane codepoint (surrogate pair)+ String.fromCharCode( high >> 10 | 0xD800, high & 0x3FF | 0xDC00 );+ };++// Optimize for push.apply( _, NodeList )+try {+ push.apply(+ (arr = slice.call( preferredDoc.childNodes )),+ preferredDoc.childNodes+ );+ // Support: Android<4.0+ // Detect silently failing push.apply+ arr[ preferredDoc.childNodes.length ].nodeType;+} catch ( e ) {+ push = { apply: arr.length ?++ // Leverage slice if possible+ function( target, els ) {+ push_native.apply( target, slice.call(els) );+ } :++ // Support: IE<9+ // Otherwise append directly+ function( target, els ) {+ var j = target.length,+ i = 0;+ // Can't trust NodeList.length+ while ( (target[j++] = els[i++]) ) {}+ target.length = j - 1;+ }+ };+}++function Sizzle( selector, context, results, seed ) {+ var match, elem, m, nodeType,+ // QSA vars+ i, groups, old, nid, newContext, newSelector;++ if ( ( context ? context.ownerDocument || context : preferredDoc ) !== document ) {+ setDocument( context );+ }++ context = context || document;+ results = results || [];++ if ( !selector || typeof selector !== "string" ) {+ return results;+ }++ if ( (nodeType = context.nodeType) !== 1 && nodeType !== 9 ) {+ return [];+ }++ if ( documentIsHTML && !seed ) {++ // Shortcuts+ if ( (match = rquickExpr.exec( selector )) ) {+ // Speed-up: Sizzle("#ID")+ if ( (m = match[1]) ) {+ if ( nodeType === 9 ) {+ elem = context.getElementById( m );+ // Check parentNode to catch when Blackberry 4.6 returns+ // nodes that are no longer in the document (jQuery #6963)+ if ( elem && elem.parentNode ) {+ // Handle the case where IE, Opera, and Webkit return items+ // by name instead of ID+ if ( elem.id === m ) {+ results.push( elem );+ return results;+ }+ } else {+ return results;+ }+ } else {+ // Context is not a document+ if ( context.ownerDocument && (elem = context.ownerDocument.getElementById( m )) &&+ contains( context, elem ) && elem.id === m ) {+ results.push( elem );+ return results;+ }+ }++ // Speed-up: Sizzle("TAG")+ } else if ( match[2] ) {+ push.apply( results, context.getElementsByTagName( selector ) );+ return results;++ // Speed-up: Sizzle(".CLASS")+ } else if ( (m = match[3]) && support.getElementsByClassName && context.getElementsByClassName ) {+ push.apply( results, context.getElementsByClassName( m ) );+ return results;+ }+ }++ // QSA path+ if ( support.qsa && (!rbuggyQSA || !rbuggyQSA.test( selector )) ) {+ nid = old = expando;+ newContext = context;+ newSelector = nodeType === 9 && selector;++ // qSA works strangely on Element-rooted queries+ // We can work around this by specifying an extra ID on the root+ // and working up from there (Thanks to Andrew Dupont for the technique)+ // IE 8 doesn't work on object elements+ if ( nodeType === 1 && context.nodeName.toLowerCase() !== "object" ) {+ groups = tokenize( selector );++ if ( (old = context.getAttribute("id")) ) {+ nid = old.replace( rescape, "\\$&" );+ } else {+ context.setAttribute( "id", nid );+ }+ nid = "[id='" + nid + "'] ";++ i = groups.length;+ while ( i-- ) {+ groups[i] = nid + toSelector( groups[i] );+ }+ newContext = rsibling.test( selector ) && testContext( context.parentNode ) || context;+ newSelector = groups.join(",");+ }++ if ( newSelector ) {+ try {+ push.apply( results,+ newContext.querySelectorAll( newSelector )+ );+ return results;+ } catch(qsaError) {+ } finally {+ if ( !old ) {+ context.removeAttribute("id");+ }+ }+ }+ }+ }++ // All others+ return select( selector.replace( rtrim, "$1" ), context, results, seed );+}++/**+ * Create key-value caches of limited size+ * @returns {Function(string, Object)} Returns the Object data after storing it on itself with+ * property name the (space-suffixed) string and (if the cache is larger than Expr.cacheLength)+ * deleting the oldest entry+ */+function createCache() {+ var keys = [];++ function cache( key, value ) {+ // Use (key + " ") to avoid collision with native prototype properties (see Issue #157)+ if ( keys.push( key + " " ) > Expr.cacheLength ) {+ // Only keep the most recent entries+ delete cache[ keys.shift() ];+ }+ return (cache[ key + " " ] = value);+ }+ return cache;+}++/**+ * Mark a function for special use by Sizzle+ * @param {Function} fn The function to mark+ */+function markFunction( fn ) {+ fn[ expando ] = true;+ return fn;+}++/**+ * Support testing using an element+ * @param {Function} fn Passed the created div and expects a boolean result+ */+function assert( fn ) {+ var div = document.createElement("div");++ try {+ return !!fn( div );+ } catch (e) {+ return false;+ } finally {+ // Remove from its parent by default+ if ( div.parentNode ) {+ div.parentNode.removeChild( div );+ }+ // release memory in IE+ div = null;+ }+}++/**+ * Adds the same handler for all of the specified attrs+ * @param {String} attrs Pipe-separated list of attributes+ * @param {Function} handler The method that will be applied+ */+function addHandle( attrs, handler ) {+ var arr = attrs.split("|"),+ i = attrs.length;++ while ( i-- ) {+ Expr.attrHandle[ arr[i] ] = handler;+ }+}++/**+ * Checks document order of two siblings+ * @param {Element} a+ * @param {Element} b+ * @returns {Number} Returns less than 0 if a precedes b, greater than 0 if a follows b+ */+function siblingCheck( a, b ) {+ var cur = b && a,+ diff = cur && a.nodeType === 1 && b.nodeType === 1 &&+ ( ~b.sourceIndex || MAX_NEGATIVE ) -+ ( ~a.sourceIndex || MAX_NEGATIVE );++ // Use IE sourceIndex if available on both nodes+ if ( diff ) {+ return diff;+ }++ // Check if b follows a+ if ( cur ) {+ while ( (cur = cur.nextSibling) ) {+ if ( cur === b ) {+ return -1;+ }+ }+ }++ return a ? 1 : -1;+}++/**+ * Returns a function to use in pseudos for input types+ * @param {String} type+ */+function createInputPseudo( type ) {+ return function( elem ) {+ var name = elem.nodeName.toLowerCase();+ return name === "input" && elem.type === type;+ };+}++/**+ * Returns a function to use in pseudos for buttons+ * @param {String} type+ */+function createButtonPseudo( type ) {+ return function( elem ) {+ var name = elem.nodeName.toLowerCase();+ return (name === "input" || name === "button") && elem.type === type;+ };+}++/**+ * Returns a function to use in pseudos for positionals+ * @param {Function} fn+ */+function createPositionalPseudo( fn ) {+ return markFunction(function( argument ) {+ argument = +argument;+ return markFunction(function( seed, matches ) {+ var j,+ matchIndexes = fn( [], seed.length, argument ),+ i = matchIndexes.length;++ // Match elements found at the specified indexes+ while ( i-- ) {+ if ( seed[ (j = matchIndexes[i]) ] ) {+ seed[j] = !(matches[j] = seed[j]);+ }+ }+ });+ });+}++/**+ * Checks a node for validity as a Sizzle context+ * @param {Element|Object=} context+ * @returns {Element|Object|Boolean} The input node if acceptable, otherwise a falsy value+ */+function testContext( context ) {+ return context && typeof context.getElementsByTagName !== strundefined && context;+}++// Expose support vars for convenience+support = Sizzle.support = {};++/**+ * Detects XML nodes+ * @param {Element|Object} elem An element or a document+ * @returns {Boolean} True iff elem is a non-HTML XML node+ */+isXML = Sizzle.isXML = function( elem ) {+ // documentElement is verified for cases where it doesn't yet exist+ // (such as loading iframes in IE - #4833)+ var documentElement = elem && (elem.ownerDocument || elem).documentElement;+ return documentElement ? documentElement.nodeName !== "HTML" : false;+};++/**+ * Sets document-related variables once based on the current document+ * @param {Element|Object} [doc] An element or document object to use to set the document+ * @returns {Object} Returns the current document+ */+setDocument = Sizzle.setDocument = function( node ) {+ var hasCompare,+ doc = node ? node.ownerDocument || node : preferredDoc,+ parent = doc.defaultView;++ // If no document and documentElement is available, return+ if ( doc === document || doc.nodeType !== 9 || !doc.documentElement ) {+ return document;+ }++ // Set our document+ document = doc;+ docElem = doc.documentElement;++ // Support tests+ documentIsHTML = !isXML( doc );++ // Support: IE>8+ // If iframe document is assigned to "document" variable and if iframe has been reloaded,+ // IE will throw "permission denied" error when accessing "document" variable, see jQuery #13936+ // IE6-8 do not support the defaultView property so parent will be undefined+ if ( parent && parent !== parent.top ) {+ // IE11 does not have attachEvent, so all must suffer+ if ( parent.addEventListener ) {+ parent.addEventListener( "unload", function() {+ setDocument();+ }, false );+ } else if ( parent.attachEvent ) {+ parent.attachEvent( "onunload", function() {+ setDocument();+ });+ }+ }++ /* Attributes+ ---------------------------------------------------------------------- */++ // Support: IE<8+ // Verify that getAttribute really returns attributes and not properties (excepting IE8 booleans)+ support.attributes = assert(function( div ) {+ div.className = "i";+ return !div.getAttribute("className");+ });++ /* getElement(s)By*+ ---------------------------------------------------------------------- */++ // Check if getElementsByTagName("*") returns only elements+ support.getElementsByTagName = assert(function( div ) {+ div.appendChild( doc.createComment("") );+ return !div.getElementsByTagName("*").length;+ });++ // Check if getElementsByClassName can be trusted+ support.getElementsByClassName = rnative.test( doc.getElementsByClassName ) && assert(function( div ) {+ div.innerHTML = "<div class='a'></div><div class='a i'></div>";++ // Support: Safari<4+ // Catch class over-caching+ div.firstChild.className = "i";+ // Support: Opera<10+ // Catch gEBCN failure to find non-leading classes+ return div.getElementsByClassName("i").length === 2;+ });++ // Support: IE<10+ // Check if getElementById returns elements by name+ // The broken getElementById methods don't pick up programatically-set names,+ // so use a roundabout getElementsByName test+ support.getById = assert(function( div ) {+ docElem.appendChild( div ).id = expando;+ return !doc.getElementsByName || !doc.getElementsByName( expando ).length;+ });++ // ID find and filter+ if ( support.getById ) {+ Expr.find["ID"] = function( id, context ) {+ if ( typeof context.getElementById !== strundefined && documentIsHTML ) {+ var m = context.getElementById( id );+ // Check parentNode to catch when Blackberry 4.6 returns+ // nodes that are no longer in the document #6963+ return m && m.parentNode ? [ m ] : [];+ }+ };+ Expr.filter["ID"] = function( id ) {+ var attrId = id.replace( runescape, funescape );+ return function( elem ) {+ return elem.getAttribute("id") === attrId;+ };+ };+ } else {+ // Support: IE6/7+ // getElementById is not reliable as a find shortcut+ delete Expr.find["ID"];++ Expr.filter["ID"] = function( id ) {+ var attrId = id.replace( runescape, funescape );+ return function( elem ) {+ var node = typeof elem.getAttributeNode !== strundefined && elem.getAttributeNode("id");+ return node && node.value === attrId;+ };+ };+ }++ // Tag+ Expr.find["TAG"] = support.getElementsByTagName ?+ function( tag, context ) {+ if ( typeof context.getElementsByTagName !== strundefined ) {+ return context.getElementsByTagName( tag );+ }+ } :+ function( tag, context ) {+ var elem,+ tmp = [],+ i = 0,+ results = context.getElementsByTagName( tag );++ // Filter out possible comments+ if ( tag === "*" ) {+ while ( (elem = results[i++]) ) {+ if ( elem.nodeType === 1 ) {+ tmp.push( elem );+ }+ }++ return tmp;+ }+ return results;+ };++ // Class+ Expr.find["CLASS"] = support.getElementsByClassName && function( className, context ) {+ if ( typeof context.getElementsByClassName !== strundefined && documentIsHTML ) {+ return context.getElementsByClassName( className );+ }+ };++ /* QSA/matchesSelector+ ---------------------------------------------------------------------- */++ // QSA and matchesSelector support++ // matchesSelector(:active) reports false when true (IE9/Opera 11.5)+ rbuggyMatches = [];++ // qSa(:focus) reports false when true (Chrome 21)+ // We allow this because of a bug in IE8/9 that throws an error+ // whenever `document.activeElement` is accessed on an iframe+ // So, we allow :focus to pass through QSA all the time to avoid the IE error+ // See http://bugs.jquery.com/ticket/13378+ rbuggyQSA = [];++ if ( (support.qsa = rnative.test( doc.querySelectorAll )) ) {+ // Build QSA regex+ // Regex strategy adopted from Diego Perini+ assert(function( div ) {+ // Select is set to empty string on purpose+ // This is to test IE's treatment of not explicitly+ // setting a boolean content attribute,+ // since its presence should be enough+ // http://bugs.jquery.com/ticket/12359+ div.innerHTML = "<select msallowclip=''><option selected=''></option></select>";++ // Support: IE8, Opera 11-12.16+ // Nothing should be selected when empty strings follow ^= or $= or *=+ // The test attribute must be unknown in Opera but "safe" for WinRT+ // http://msdn.microsoft.com/en-us/library/ie/hh465388.aspx#attribute_section+ if ( div.querySelectorAll("[msallowclip^='']").length ) {+ rbuggyQSA.push( "[*^$]=" + whitespace + "*(?:''|\"\")" );+ }++ // Support: IE8+ // Boolean attributes and "value" are not treated correctly+ if ( !div.querySelectorAll("[selected]").length ) {+ rbuggyQSA.push( "\\[" + whitespace + "*(?:value|" + booleans + ")" );+ }++ // Webkit/Opera - :checked should return selected option elements+ // http://www.w3.org/TR/2011/REC-css3-selectors-20110929/#checked+ // IE8 throws error here and will not see later tests+ if ( !div.querySelectorAll(":checked").length ) {+ rbuggyQSA.push(":checked");+ }+ });++ assert(function( div ) {+ // Support: Windows 8 Native Apps+ // The type and name attributes are restricted during .innerHTML assignment+ var input = doc.createElement("input");+ input.setAttribute( "type", "hidden" );+ div.appendChild( input ).setAttribute( "name", "D" );++ // Support: IE8+ // Enforce case-sensitivity of name attribute+ if ( div.querySelectorAll("[name=d]").length ) {+ rbuggyQSA.push( "name" + whitespace + "*[*^$|!~]?=" );+ }++ // FF 3.5 - :enabled/:disabled and hidden elements (hidden elements are still enabled)+ // IE8 throws error here and will not see later tests+ if ( !div.querySelectorAll(":enabled").length ) {+ rbuggyQSA.push( ":enabled", ":disabled" );+ }++ // Opera 10-11 does not throw on post-comma invalid pseudos+ div.querySelectorAll("*,:x");+ rbuggyQSA.push(",.*:");+ });+ }++ if ( (support.matchesSelector = rnative.test( (matches = docElem.matches ||+ docElem.webkitMatchesSelector ||+ docElem.mozMatchesSelector ||+ docElem.oMatchesSelector ||+ docElem.msMatchesSelector) )) ) {++ assert(function( div ) {+ // Check to see if it's possible to do matchesSelector+ // on a disconnected node (IE 9)+ support.disconnectedMatch = matches.call( div, "div" );++ // This should fail with an exception+ // Gecko does not error, returns false instead+ matches.call( div, "[s!='']:x" );+ rbuggyMatches.push( "!=", pseudos );+ });+ }++ rbuggyQSA = rbuggyQSA.length && new RegExp( rbuggyQSA.join("|") );+ rbuggyMatches = rbuggyMatches.length && new RegExp( rbuggyMatches.join("|") );++ /* Contains+ ---------------------------------------------------------------------- */+ hasCompare = rnative.test( docElem.compareDocumentPosition );++ // Element contains another+ // Purposefully does not implement inclusive descendent+ // As in, an element does not contain itself+ contains = hasCompare || rnative.test( docElem.contains ) ?+ function( a, b ) {+ var adown = a.nodeType === 9 ? a.documentElement : a,+ bup = b && b.parentNode;+ return a === bup || !!( bup && bup.nodeType === 1 && (+ adown.contains ?+ adown.contains( bup ) :+ a.compareDocumentPosition && a.compareDocumentPosition( bup ) & 16+ ));+ } :+ function( a, b ) {+ if ( b ) {+ while ( (b = b.parentNode) ) {+ if ( b === a ) {+ return true;+ }+ }+ }+ return false;+ };++ /* Sorting+ ---------------------------------------------------------------------- */++ // Document order sorting+ sortOrder = hasCompare ?+ function( a, b ) {++ // Flag for duplicate removal+ if ( a === b ) {+ hasDuplicate = true;+ return 0;+ }++ // Sort on method existence if only one input has compareDocumentPosition+ var compare = !a.compareDocumentPosition - !b.compareDocumentPosition;+ if ( compare ) {+ return compare;+ }++ // Calculate position if both inputs belong to the same document+ compare = ( a.ownerDocument || a ) === ( b.ownerDocument || b ) ?+ a.compareDocumentPosition( b ) :++ // Otherwise we know they are disconnected+ 1;++ // Disconnected nodes+ if ( compare & 1 ||+ (!support.sortDetached && b.compareDocumentPosition( a ) === compare) ) {++ // Choose the first element that is related to our preferred document+ if ( a === doc || a.ownerDocument === preferredDoc && contains(preferredDoc, a) ) {+ return -1;+ }+ if ( b === doc || b.ownerDocument === preferredDoc && contains(preferredDoc, b) ) {+ return 1;+ }++ // Maintain original order+ return sortInput ?+ ( indexOf.call( sortInput, a ) - indexOf.call( sortInput, b ) ) :+ 0;+ }++ return compare & 4 ? -1 : 1;+ } :+ function( a, b ) {+ // Exit early if the nodes are identical+ if ( a === b ) {+ hasDuplicate = true;+ return 0;+ }++ var cur,+ i = 0,+ aup = a.parentNode,+ bup = b.parentNode,+ ap = [ a ],+ bp = [ b ];++ // Parentless nodes are either documents or disconnected+ if ( !aup || !bup ) {+ return a === doc ? -1 :+ b === doc ? 1 :+ aup ? -1 :+ bup ? 1 :+ sortInput ?+ ( indexOf.call( sortInput, a ) - indexOf.call( sortInput, b ) ) :+ 0;++ // If the nodes are siblings, we can do a quick check+ } else if ( aup === bup ) {+ return siblingCheck( a, b );+ }++ // Otherwise we need full lists of their ancestors for comparison+ cur = a;+ while ( (cur = cur.parentNode) ) {+ ap.unshift( cur );+ }+ cur = b;+ while ( (cur = cur.parentNode) ) {+ bp.unshift( cur );+ }++ // Walk down the tree looking for a discrepancy+ while ( ap[i] === bp[i] ) {+ i++;+ }++ return i ?+ // Do a sibling check if the nodes have a common ancestor+ siblingCheck( ap[i], bp[i] ) :++ // Otherwise nodes in our document sort first+ ap[i] === preferredDoc ? -1 :+ bp[i] === preferredDoc ? 1 :+ 0;+ };++ return doc;+};++Sizzle.matches = function( expr, elements ) {+ return Sizzle( expr, null, null, elements );+};++Sizzle.matchesSelector = function( elem, expr ) {+ // Set document vars if needed+ if ( ( elem.ownerDocument || elem ) !== document ) {+ setDocument( elem );+ }++ // Make sure that attribute selectors are quoted+ expr = expr.replace( rattributeQuotes, "='$1']" );++ if ( support.matchesSelector && documentIsHTML &&+ ( !rbuggyMatches || !rbuggyMatches.test( expr ) ) &&+ ( !rbuggyQSA || !rbuggyQSA.test( expr ) ) ) {++ try {+ var ret = matches.call( elem, expr );++ // IE 9's matchesSelector returns false on disconnected nodes+ if ( ret || support.disconnectedMatch ||+ // As well, disconnected nodes are said to be in a document+ // fragment in IE 9+ elem.document && elem.document.nodeType !== 11 ) {+ return ret;+ }+ } catch(e) {}+ }++ return Sizzle( expr, document, null, [ elem ] ).length > 0;+};++Sizzle.contains = function( context, elem ) {+ // Set document vars if needed+ if ( ( context.ownerDocument || context ) !== document ) {+ setDocument( context );+ }+ return contains( context, elem );+};++Sizzle.attr = function( elem, name ) {+ // Set document vars if needed+ if ( ( elem.ownerDocument || elem ) !== document ) {+ setDocument( elem );+ }++ var fn = Expr.attrHandle[ name.toLowerCase() ],+ // Don't get fooled by Object.prototype properties (jQuery #13807)+ val = fn && hasOwn.call( Expr.attrHandle, name.toLowerCase() ) ?+ fn( elem, name, !documentIsHTML ) :+ undefined;++ return val !== undefined ?+ val :+ support.attributes || !documentIsHTML ?+ elem.getAttribute( name ) :+ (val = elem.getAttributeNode(name)) && val.specified ?+ val.value :+ null;+};++Sizzle.error = function( msg ) {+ throw new Error( "Syntax error, unrecognized expression: " + msg );+};++/**+ * Document sorting and removing duplicates+ * @param {ArrayLike} results+ */+Sizzle.uniqueSort = function( results ) {+ var elem,+ duplicates = [],+ j = 0,+ i = 0;++ // Unless we *know* we can detect duplicates, assume their presence+ hasDuplicate = !support.detectDuplicates;+ sortInput = !support.sortStable && results.slice( 0 );+ results.sort( sortOrder );++ if ( hasDuplicate ) {+ while ( (elem = results[i++]) ) {+ if ( elem === results[ i ] ) {+ j = duplicates.push( i );+ }+ }+ while ( j-- ) {+ results.splice( duplicates[ j ], 1 );+ }+ }++ // Clear input after sorting to release objects+ // See https://github.com/jquery/sizzle/pull/225+ sortInput = null;++ return results;+};++/**+ * Utility function for retrieving the text value of an array of DOM nodes+ * @param {Array|Element} elem+ */+getText = Sizzle.getText = function( elem ) {+ var node,+ ret = "",+ i = 0,+ nodeType = elem.nodeType;++ if ( !nodeType ) {+ // If no nodeType, this is expected to be an array+ while ( (node = elem[i++]) ) {+ // Do not traverse comment nodes+ ret += getText( node );+ }+ } else if ( nodeType === 1 || nodeType === 9 || nodeType === 11 ) {+ // Use textContent for elements+ // innerText usage removed for consistency of new lines (jQuery #11153)+ if ( typeof elem.textContent === "string" ) {+ return elem.textContent;+ } else {+ // Traverse its children+ for ( elem = elem.firstChild; elem; elem = elem.nextSibling ) {+ ret += getText( elem );+ }+ }+ } else if ( nodeType === 3 || nodeType === 4 ) {+ return elem.nodeValue;+ }+ // Do not include comment or processing instruction nodes++ return ret;+};++Expr = Sizzle.selectors = {++ // Can be adjusted by the user+ cacheLength: 50,++ createPseudo: markFunction,++ match: matchExpr,++ attrHandle: {},++ find: {},++ relative: {+ ">": { dir: "parentNode", first: true },+ " ": { dir: "parentNode" },+ "+": { dir: "previousSibling", first: true },+ "~": { dir: "previousSibling" }+ },++ preFilter: {+ "ATTR": function( match ) {+ match[1] = match[1].replace( runescape, funescape );++ // Move the given value to match[3] whether quoted or unquoted+ match[3] = ( match[3] || match[4] || match[5] || "" ).replace( runescape, funescape );++ if ( match[2] === "~=" ) {+ match[3] = " " + match[3] + " ";+ }++ return match.slice( 0, 4 );+ },++ "CHILD": function( match ) {+ /* matches from matchExpr["CHILD"]+ 1 type (only|nth|...)+ 2 what (child|of-type)+ 3 argument (even|odd|\d*|\d*n([+-]\d+)?|...)+ 4 xn-component of xn+y argument ([+-]?\d*n|)+ 5 sign of xn-component+ 6 x of xn-component+ 7 sign of y-component+ 8 y of y-component+ */+ match[1] = match[1].toLowerCase();++ if ( match[1].slice( 0, 3 ) === "nth" ) {+ // nth-* requires argument+ if ( !match[3] ) {+ Sizzle.error( match[0] );+ }++ // numeric x and y parameters for Expr.filter.CHILD+ // remember that false/true cast respectively to 0/1+ match[4] = +( match[4] ? match[5] + (match[6] || 1) : 2 * ( match[3] === "even" || match[3] === "odd" ) );+ match[5] = +( ( match[7] + match[8] ) || match[3] === "odd" );++ // other types prohibit arguments+ } else if ( match[3] ) {+ Sizzle.error( match[0] );+ }++ return match;+ },++ "PSEUDO": function( match ) {+ var excess,+ unquoted = !match[6] && match[2];++ if ( matchExpr["CHILD"].test( match[0] ) ) {+ return null;+ }++ // Accept quoted arguments as-is+ if ( match[3] ) {+ match[2] = match[4] || match[5] || "";++ // Strip excess characters from unquoted arguments+ } else if ( unquoted && rpseudo.test( unquoted ) &&+ // Get excess from tokenize (recursively)+ (excess = tokenize( unquoted, true )) &&+ // advance to the next closing parenthesis+ (excess = unquoted.indexOf( ")", unquoted.length - excess ) - unquoted.length) ) {++ // excess is a negative index+ match[0] = match[0].slice( 0, excess );+ match[2] = unquoted.slice( 0, excess );+ }++ // Return only captures needed by the pseudo filter method (type and argument)+ return match.slice( 0, 3 );+ }+ },++ filter: {++ "TAG": function( nodeNameSelector ) {+ var nodeName = nodeNameSelector.replace( runescape, funescape ).toLowerCase();+ return nodeNameSelector === "*" ?+ function() { return true; } :+ function( elem ) {+ return elem.nodeName && elem.nodeName.toLowerCase() === nodeName;+ };+ },++ "CLASS": function( className ) {+ var pattern = classCache[ className + " " ];++ return pattern ||+ (pattern = new RegExp( "(^|" + whitespace + ")" + className + "(" + whitespace + "|$)" )) &&+ classCache( className, function( elem ) {+ return pattern.test( typeof elem.className === "string" && elem.className || typeof elem.getAttribute !== strundefined && elem.getAttribute("class") || "" );+ });+ },++ "ATTR": function( name, operator, check ) {+ return function( elem ) {+ var result = Sizzle.attr( elem, name );++ if ( result == null ) {+ return operator === "!=";+ }+ if ( !operator ) {+ return true;+ }++ result += "";++ return operator === "=" ? result === check :+ operator === "!=" ? result !== check :+ operator === "^=" ? check && result.indexOf( check ) === 0 :+ operator === "*=" ? check && result.indexOf( check ) > -1 :+ operator === "$=" ? check && result.slice( -check.length ) === check :+ operator === "~=" ? ( " " + result + " " ).indexOf( check ) > -1 :+ operator === "|=" ? result === check || result.slice( 0, check.length + 1 ) === check + "-" :+ false;+ };+ },++ "CHILD": function( type, what, argument, first, last ) {+ var simple = type.slice( 0, 3 ) !== "nth",+ forward = type.slice( -4 ) !== "last",+ ofType = what === "of-type";++ return first === 1 && last === 0 ?++ // Shortcut for :nth-*(n)+ function( elem ) {+ return !!elem.parentNode;+ } :++ function( elem, context, xml ) {+ var cache, outerCache, node, diff, nodeIndex, start,+ dir = simple !== forward ? "nextSibling" : "previousSibling",+ parent = elem.parentNode,+ name = ofType && elem.nodeName.toLowerCase(),+ useCache = !xml && !ofType;++ if ( parent ) {++ // :(first|last|only)-(child|of-type)+ if ( simple ) {+ while ( dir ) {+ node = elem;+ while ( (node = node[ dir ]) ) {+ if ( ofType ? node.nodeName.toLowerCase() === name : node.nodeType === 1 ) {+ return false;+ }+ }+ // Reverse direction for :only-* (if we haven't yet done so)+ start = dir = type === "only" && !start && "nextSibling";+ }+ return true;+ }++ start = [ forward ? parent.firstChild : parent.lastChild ];++ // non-xml :nth-child(...) stores cache data on `parent`+ if ( forward && useCache ) {+ // Seek `elem` from a previously-cached index+ outerCache = parent[ expando ] || (parent[ expando ] = {});+ cache = outerCache[ type ] || [];+ nodeIndex = cache[0] === dirruns && cache[1];+ diff = cache[0] === dirruns && cache[2];+ node = nodeIndex && parent.childNodes[ nodeIndex ];++ while ( (node = ++nodeIndex && node && node[ dir ] ||++ // Fallback to seeking `elem` from the start+ (diff = nodeIndex = 0) || start.pop()) ) {++ // When found, cache indexes on `parent` and break+ if ( node.nodeType === 1 && ++diff && node === elem ) {+ outerCache[ type ] = [ dirruns, nodeIndex, diff ];+ break;+ }+ }++ // Use previously-cached element index if available+ } else if ( useCache && (cache = (elem[ expando ] || (elem[ expando ] = {}))[ type ]) && cache[0] === dirruns ) {+ diff = cache[1];++ // xml :nth-child(...) or :nth-last-child(...) or :nth(-last)?-of-type(...)+ } else {+ // Use the same loop as above to seek `elem` from the start+ while ( (node = ++nodeIndex && node && node[ dir ] ||+ (diff = nodeIndex = 0) || start.pop()) ) {++ if ( ( ofType ? node.nodeName.toLowerCase() === name : node.nodeType === 1 ) && ++diff ) {+ // Cache the index of each encountered element+ if ( useCache ) {+ (node[ expando ] || (node[ expando ] = {}))[ type ] = [ dirruns, diff ];+ }++ if ( node === elem ) {+ break;+ }+ }+ }+ }++ // Incorporate the offset, then check against cycle size+ diff -= last;+ return diff === first || ( diff % first === 0 && diff / first >= 0 );+ }+ };+ },++ "PSEUDO": function( pseudo, argument ) {+ // pseudo-class names are case-insensitive+ // http://www.w3.org/TR/selectors/#pseudo-classes+ // Prioritize by case sensitivity in case custom pseudos are added with uppercase letters+ // Remember that setFilters inherits from pseudos+ var args,+ fn = Expr.pseudos[ pseudo ] || Expr.setFilters[ pseudo.toLowerCase() ] ||+ Sizzle.error( "unsupported pseudo: " + pseudo );++ // The user may use createPseudo to indicate that+ // arguments are needed to create the filter function+ // just as Sizzle does+ if ( fn[ expando ] ) {+ return fn( argument );+ }++ // But maintain support for old signatures+ if ( fn.length > 1 ) {+ args = [ pseudo, pseudo, "", argument ];+ return Expr.setFilters.hasOwnProperty( pseudo.toLowerCase() ) ?+ markFunction(function( seed, matches ) {+ var idx,+ matched = fn( seed, argument ),+ i = matched.length;+ while ( i-- ) {+ idx = indexOf.call( seed, matched[i] );+ seed[ idx ] = !( matches[ idx ] = matched[i] );+ }+ }) :+ function( elem ) {+ return fn( elem, 0, args );+ };+ }++ return fn;+ }+ },++ pseudos: {+ // Potentially complex pseudos+ "not": markFunction(function( selector ) {+ // Trim the selector passed to compile+ // to avoid treating leading and trailing+ // spaces as combinators+ var input = [],+ results = [],+ matcher = compile( selector.replace( rtrim, "$1" ) );++ return matcher[ expando ] ?+ markFunction(function( seed, matches, context, xml ) {+ var elem,+ unmatched = matcher( seed, null, xml, [] ),+ i = seed.length;++ // Match elements unmatched by `matcher`+ while ( i-- ) {+ if ( (elem = unmatched[i]) ) {+ seed[i] = !(matches[i] = elem);+ }+ }+ }) :+ function( elem, context, xml ) {+ input[0] = elem;+ matcher( input, null, xml, results );+ return !results.pop();+ };+ }),++ "has": markFunction(function( selector ) {+ return function( elem ) {+ return Sizzle( selector, elem ).length > 0;+ };+ }),++ "contains": markFunction(function( text ) {+ return function( elem ) {+ return ( elem.textContent || elem.innerText || getText( elem ) ).indexOf( text ) > -1;+ };+ }),++ // "Whether an element is represented by a :lang() selector+ // is based solely on the element's language value+ // being equal to the identifier C,+ // or beginning with the identifier C immediately followed by "-".+ // The matching of C against the element's language value is performed case-insensitively.+ // The identifier C does not have to be a valid language name."+ // http://www.w3.org/TR/selectors/#lang-pseudo+ "lang": markFunction( function( lang ) {+ // lang value must be a valid identifier+ if ( !ridentifier.test(lang || "") ) {+ Sizzle.error( "unsupported lang: " + lang );+ }+ lang = lang.replace( runescape, funescape ).toLowerCase();+ return function( elem ) {+ var elemLang;+ do {+ if ( (elemLang = documentIsHTML ?+ elem.lang :+ elem.getAttribute("xml:lang") || elem.getAttribute("lang")) ) {++ elemLang = elemLang.toLowerCase();+ return elemLang === lang || elemLang.indexOf( lang + "-" ) === 0;+ }+ } while ( (elem = elem.parentNode) && elem.nodeType === 1 );+ return false;+ };+ }),++ // Miscellaneous+ "target": function( elem ) {+ var hash = window.location && window.location.hash;+ return hash && hash.slice( 1 ) === elem.id;+ },++ "root": function( elem ) {+ return elem === docElem;+ },++ "focus": function( elem ) {+ return elem === document.activeElement && (!document.hasFocus || document.hasFocus()) && !!(elem.type || elem.href || ~elem.tabIndex);+ },++ // Boolean properties+ "enabled": function( elem ) {+ return elem.disabled === false;+ },++ "disabled": function( elem ) {+ return elem.disabled === true;+ },++ "checked": function( elem ) {+ // In CSS3, :checked should return both checked and selected elements+ // http://www.w3.org/TR/2011/REC-css3-selectors-20110929/#checked+ var nodeName = elem.nodeName.toLowerCase();+ return (nodeName === "input" && !!elem.checked) || (nodeName === "option" && !!elem.selected);+ },++ "selected": function( elem ) {+ // Accessing this property makes selected-by-default+ // options in Safari work properly+ if ( elem.parentNode ) {+ elem.parentNode.selectedIndex;+ }++ return elem.selected === true;+ },++ // Contents+ "empty": function( elem ) {+ // http://www.w3.org/TR/selectors/#empty-pseudo+ // :empty is negated by element (1) or content nodes (text: 3; cdata: 4; entity ref: 5),+ // but not by others (comment: 8; processing instruction: 7; etc.)+ // nodeType < 6 works because attributes (2) do not appear as children+ for ( elem = elem.firstChild; elem; elem = elem.nextSibling ) {+ if ( elem.nodeType < 6 ) {+ return false;+ }+ }+ return true;+ },++ "parent": function( elem ) {+ return !Expr.pseudos["empty"]( elem );+ },++ // Element/input types+ "header": function( elem ) {+ return rheader.test( elem.nodeName );+ },++ "input": function( elem ) {+ return rinputs.test( elem.nodeName );+ },++ "button": function( elem ) {+ var name = elem.nodeName.toLowerCase();+ return name === "input" && elem.type === "button" || name === "button";+ },++ "text": function( elem ) {+ var attr;+ return elem.nodeName.toLowerCase() === "input" &&+ elem.type === "text" &&++ // Support: IE<8+ // New HTML5 attribute values (e.g., "search") appear with elem.type === "text"+ ( (attr = elem.getAttribute("type")) == null || attr.toLowerCase() === "text" );+ },++ // Position-in-collection+ "first": createPositionalPseudo(function() {+ return [ 0 ];+ }),++ "last": createPositionalPseudo(function( matchIndexes, length ) {+ return [ length - 1 ];+ }),++ "eq": createPositionalPseudo(function( matchIndexes, length, argument ) {+ return [ argument < 0 ? argument + length : argument ];+ }),++ "even": createPositionalPseudo(function( matchIndexes, length ) {+ var i = 0;+ for ( ; i < length; i += 2 ) {+ matchIndexes.push( i );+ }+ return matchIndexes;+ }),++ "odd": createPositionalPseudo(function( matchIndexes, length ) {+ var i = 1;+ for ( ; i < length; i += 2 ) {+ matchIndexes.push( i );+ }+ return matchIndexes;+ }),++ "lt": createPositionalPseudo(function( matchIndexes, length, argument ) {+ var i = argument < 0 ? argument + length : argument;+ for ( ; --i >= 0; ) {+ matchIndexes.push( i );+ }+ return matchIndexes;+ }),++ "gt": createPositionalPseudo(function( matchIndexes, length, argument ) {+ var i = argument < 0 ? argument + length : argument;+ for ( ; ++i < length; ) {+ matchIndexes.push( i );+ }+ return matchIndexes;+ })+ }+};++Expr.pseudos["nth"] = Expr.pseudos["eq"];++// Add button/input type pseudos+for ( i in { radio: true, checkbox: true, file: true, password: true, image: true } ) {+ Expr.pseudos[ i ] = createInputPseudo( i );+}+for ( i in { submit: true, reset: true } ) {+ Expr.pseudos[ i ] = createButtonPseudo( i );+}++// Easy API for creating new setFilters+function setFilters() {}+setFilters.prototype = Expr.filters = Expr.pseudos;+Expr.setFilters = new setFilters();++tokenize = Sizzle.tokenize = function( selector, parseOnly ) {+ var matched, match, tokens, type,+ soFar, groups, preFilters,+ cached = tokenCache[ selector + " " ];++ if ( cached ) {+ return parseOnly ? 0 : cached.slice( 0 );+ }++ soFar = selector;+ groups = [];+ preFilters = Expr.preFilter;++ while ( soFar ) {++ // Comma and first run+ if ( !matched || (match = rcomma.exec( soFar )) ) {+ if ( match ) {+ // Don't consume trailing commas as valid+ soFar = soFar.slice( match[0].length ) || soFar;+ }+ groups.push( (tokens = []) );+ }++ matched = false;++ // Combinators+ if ( (match = rcombinators.exec( soFar )) ) {+ matched = match.shift();+ tokens.push({+ value: matched,+ // Cast descendant combinators to space+ type: match[0].replace( rtrim, " " )+ });+ soFar = soFar.slice( matched.length );+ }++ // Filters+ for ( type in Expr.filter ) {+ if ( (match = matchExpr[ type ].exec( soFar )) && (!preFilters[ type ] ||+ (match = preFilters[ type ]( match ))) ) {+ matched = match.shift();+ tokens.push({+ value: matched,+ type: type,+ matches: match+ });+ soFar = soFar.slice( matched.length );+ }+ }++ if ( !matched ) {+ break;+ }+ }++ // Return the length of the invalid excess+ // if we're just parsing+ // Otherwise, throw an error or return tokens+ return parseOnly ?+ soFar.length :+ soFar ?+ Sizzle.error( selector ) :+ // Cache the tokens+ tokenCache( selector, groups ).slice( 0 );+};++function toSelector( tokens ) {+ var i = 0,+ len = tokens.length,+ selector = "";+ for ( ; i < len; i++ ) {+ selector += tokens[i].value;+ }+ return selector;+}++function addCombinator( matcher, combinator, base ) {+ var dir = combinator.dir,+ checkNonElements = base && dir === "parentNode",+ doneName = done++;++ return combinator.first ?+ // Check against closest ancestor/preceding element+ function( elem, context, xml ) {+ while ( (elem = elem[ dir ]) ) {+ if ( elem.nodeType === 1 || checkNonElements ) {+ return matcher( elem, context, xml );+ }+ }+ } :++ // Check against all ancestor/preceding elements+ function( elem, context, xml ) {+ var oldCache, outerCache,+ newCache = [ dirruns, doneName ];++ // We can't set arbitrary data on XML nodes, so they don't benefit from dir caching+ if ( xml ) {+ while ( (elem = elem[ dir ]) ) {+ if ( elem.nodeType === 1 || checkNonElements ) {+ if ( matcher( elem, context, xml ) ) {+ return true;+ }+ }+ }+ } else {+ while ( (elem = elem[ dir ]) ) {+ if ( elem.nodeType === 1 || checkNonElements ) {+ outerCache = elem[ expando ] || (elem[ expando ] = {});+ if ( (oldCache = outerCache[ dir ]) &&+ oldCache[ 0 ] === dirruns && oldCache[ 1 ] === doneName ) {++ // Assign to newCache so results back-propagate to previous elements+ return (newCache[ 2 ] = oldCache[ 2 ]);+ } else {+ // Reuse newcache so results back-propagate to previous elements+ outerCache[ dir ] = newCache;++ // A match means we're done; a fail means we have to keep checking+ if ( (newCache[ 2 ] = matcher( elem, context, xml )) ) {+ return true;+ }+ }+ }+ }+ }+ };+}++function elementMatcher( matchers ) {+ return matchers.length > 1 ?+ function( elem, context, xml ) {+ var i = matchers.length;+ while ( i-- ) {+ if ( !matchers[i]( elem, context, xml ) ) {+ return false;+ }+ }+ return true;+ } :+ matchers[0];+}++function multipleContexts( selector, contexts, results ) {+ var i = 0,+ len = contexts.length;+ for ( ; i < len; i++ ) {+ Sizzle( selector, contexts[i], results );+ }+ return results;+}++function condense( unmatched, map, filter, context, xml ) {+ var elem,+ newUnmatched = [],+ i = 0,+ len = unmatched.length,+ mapped = map != null;++ for ( ; i < len; i++ ) {+ if ( (elem = unmatched[i]) ) {+ if ( !filter || filter( elem, context, xml ) ) {+ newUnmatched.push( elem );+ if ( mapped ) {+ map.push( i );+ }+ }+ }+ }++ return newUnmatched;+}++function setMatcher( preFilter, selector, matcher, postFilter, postFinder, postSelector ) {+ if ( postFilter && !postFilter[ expando ] ) {+ postFilter = setMatcher( postFilter );+ }+ if ( postFinder && !postFinder[ expando ] ) {+ postFinder = setMatcher( postFinder, postSelector );+ }+ return markFunction(function( seed, results, context, xml ) {+ var temp, i, elem,+ preMap = [],+ postMap = [],+ preexisting = results.length,++ // Get initial elements from seed or context+ elems = seed || multipleContexts( selector || "*", context.nodeType ? [ context ] : context, [] ),++ // Prefilter to get matcher input, preserving a map for seed-results synchronization+ matcherIn = preFilter && ( seed || !selector ) ?+ condense( elems, preMap, preFilter, context, xml ) :+ elems,++ matcherOut = matcher ?+ // If we have a postFinder, or filtered seed, or non-seed postFilter or preexisting results,+ postFinder || ( seed ? preFilter : preexisting || postFilter ) ?++ // ...intermediate processing is necessary+ [] :++ // ...otherwise use results directly+ results :+ matcherIn;++ // Find primary matches+ if ( matcher ) {+ matcher( matcherIn, matcherOut, context, xml );+ }++ // Apply postFilter+ if ( postFilter ) {+ temp = condense( matcherOut, postMap );+ postFilter( temp, [], context, xml );++ // Un-match failing elements by moving them back to matcherIn+ i = temp.length;+ while ( i-- ) {+ if ( (elem = temp[i]) ) {+ matcherOut[ postMap[i] ] = !(matcherIn[ postMap[i] ] = elem);+ }+ }+ }++ if ( seed ) {+ if ( postFinder || preFilter ) {+ if ( postFinder ) {+ // Get the final matcherOut by condensing this intermediate into postFinder contexts+ temp = [];+ i = matcherOut.length;+ while ( i-- ) {+ if ( (elem = matcherOut[i]) ) {+ // Restore matcherIn since elem is not yet a final match+ temp.push( (matcherIn[i] = elem) );+ }+ }+ postFinder( null, (matcherOut = []), temp, xml );+ }++ // Move matched elements from seed to results to keep them synchronized+ i = matcherOut.length;+ while ( i-- ) {+ if ( (elem = matcherOut[i]) &&+ (temp = postFinder ? indexOf.call( seed, elem ) : preMap[i]) > -1 ) {++ seed[temp] = !(results[temp] = elem);+ }+ }+ }++ // Add elements to results, through postFinder if defined+ } else {+ matcherOut = condense(+ matcherOut === results ?+ matcherOut.splice( preexisting, matcherOut.length ) :+ matcherOut+ );+ if ( postFinder ) {+ postFinder( null, results, matcherOut, xml );+ } else {+ push.apply( results, matcherOut );+ }+ }+ });+}++function matcherFromTokens( tokens ) {+ var checkContext, matcher, j,+ len = tokens.length,+ leadingRelative = Expr.relative[ tokens[0].type ],+ implicitRelative = leadingRelative || Expr.relative[" "],+ i = leadingRelative ? 1 : 0,++ // The foundational matcher ensures that elements are reachable from top-level context(s)+ matchContext = addCombinator( function( elem ) {+ return elem === checkContext;+ }, implicitRelative, true ),+ matchAnyContext = addCombinator( function( elem ) {+ return indexOf.call( checkContext, elem ) > -1;+ }, implicitRelative, true ),+ matchers = [ function( elem, context, xml ) {+ return ( !leadingRelative && ( xml || context !== outermostContext ) ) || (+ (checkContext = context).nodeType ?+ matchContext( elem, context, xml ) :+ matchAnyContext( elem, context, xml ) );+ } ];++ for ( ; i < len; i++ ) {+ if ( (matcher = Expr.relative[ tokens[i].type ]) ) {+ matchers = [ addCombinator(elementMatcher( matchers ), matcher) ];+ } else {+ matcher = Expr.filter[ tokens[i].type ].apply( null, tokens[i].matches );++ // Return special upon seeing a positional matcher+ if ( matcher[ expando ] ) {+ // Find the next relative operator (if any) for proper handling+ j = ++i;+ for ( ; j < len; j++ ) {+ if ( Expr.relative[ tokens[j].type ] ) {+ break;+ }+ }+ return setMatcher(+ i > 1 && elementMatcher( matchers ),+ i > 1 && toSelector(+ // If the preceding token was a descendant combinator, insert an implicit any-element `*`+ tokens.slice( 0, i - 1 ).concat({ value: tokens[ i - 2 ].type === " " ? "*" : "" })+ ).replace( rtrim, "$1" ),+ matcher,+ i < j && matcherFromTokens( tokens.slice( i, j ) ),+ j < len && matcherFromTokens( (tokens = tokens.slice( j )) ),+ j < len && toSelector( tokens )+ );+ }+ matchers.push( matcher );+ }+ }++ return elementMatcher( matchers );+}++function matcherFromGroupMatchers( elementMatchers, setMatchers ) {+ var bySet = setMatchers.length > 0,+ byElement = elementMatchers.length > 0,+ superMatcher = function( seed, context, xml, results, outermost ) {+ var elem, j, matcher,+ matchedCount = 0,+ i = "0",+ unmatched = seed && [],+ setMatched = [],+ contextBackup = outermostContext,+ // We must always have either seed elements or outermost context+ elems = seed || byElement && Expr.find["TAG"]( "*", outermost ),+ // Use integer dirruns iff this is the outermost matcher+ dirrunsUnique = (dirruns += contextBackup == null ? 1 : Math.random() || 0.1),+ len = elems.length;++ if ( outermost ) {+ outermostContext = context !== document && context;+ }++ // Add elements passing elementMatchers directly to results+ // Keep `i` a string if there are no elements so `matchedCount` will be "00" below+ // Support: IE<9, Safari+ // Tolerate NodeList properties (IE: "length"; Safari: <number>) matching elements by id+ for ( ; i !== len && (elem = elems[i]) != null; i++ ) {+ if ( byElement && elem ) {+ j = 0;+ while ( (matcher = elementMatchers[j++]) ) {+ if ( matcher( elem, context, xml ) ) {+ results.push( elem );+ break;+ }+ }+ if ( outermost ) {+ dirruns = dirrunsUnique;+ }+ }++ // Track unmatched elements for set filters+ if ( bySet ) {+ // They will have gone through all possible matchers+ if ( (elem = !matcher && elem) ) {+ matchedCount--;+ }++ // Lengthen the array for every element, matched or not+ if ( seed ) {+ unmatched.push( elem );+ }+ }+ }++ // Apply set filters to unmatched elements+ matchedCount += i;+ if ( bySet && i !== matchedCount ) {+ j = 0;+ while ( (matcher = setMatchers[j++]) ) {+ matcher( unmatched, setMatched, context, xml );+ }++ if ( seed ) {+ // Reintegrate element matches to eliminate the need for sorting+ if ( matchedCount > 0 ) {+ while ( i-- ) {+ if ( !(unmatched[i] || setMatched[i]) ) {+ setMatched[i] = pop.call( results );+ }+ }+ }++ // Discard index placeholder values to get only actual matches+ setMatched = condense( setMatched );+ }++ // Add matches to results+ push.apply( results, setMatched );++ // Seedless set matches succeeding multiple successful matchers stipulate sorting+ if ( outermost && !seed && setMatched.length > 0 &&+ ( matchedCount + setMatchers.length ) > 1 ) {++ Sizzle.uniqueSort( results );+ }+ }++ // Override manipulation of globals by nested matchers+ if ( outermost ) {+ dirruns = dirrunsUnique;+ outermostContext = contextBackup;+ }++ return unmatched;+ };++ return bySet ?+ markFunction( superMatcher ) :+ superMatcher;+}++compile = Sizzle.compile = function( selector, match /* Internal Use Only */ ) {+ var i,+ setMatchers = [],+ elementMatchers = [],+ cached = compilerCache[ selector + " " ];++ if ( !cached ) {+ // Generate a function of recursive functions that can be used to check each element+ if ( !match ) {+ match = tokenize( selector );+ }+ i = match.length;+ while ( i-- ) {+ cached = matcherFromTokens( match[i] );+ if ( cached[ expando ] ) {+ setMatchers.push( cached );+ } else {+ elementMatchers.push( cached );+ }+ }++ // Cache the compiled function+ cached = compilerCache( selector, matcherFromGroupMatchers( elementMatchers, setMatchers ) );++ // Save selector and tokenization+ cached.selector = selector;+ }+ return cached;+};++/**+ * A low-level selection function that works with Sizzle's compiled+ * selector functions+ * @param {String|Function} selector A selector or a pre-compiled+ * selector function built with Sizzle.compile+ * @param {Element} context+ * @param {Array} [results]+ * @param {Array} [seed] A set of elements to match against+ */+select = Sizzle.select = function( selector, context, results, seed ) {+ var i, tokens, token, type, find,+ compiled = typeof selector === "function" && selector,+ match = !seed && tokenize( (selector = compiled.selector || selector) );++ results = results || [];++ // Try to minimize operations if there is no seed and only one group+ if ( match.length === 1 ) {++ // Take a shortcut and set the context if the root selector is an ID+ tokens = match[0] = match[0].slice( 0 );+ if ( tokens.length > 2 && (token = tokens[0]).type === "ID" &&+ support.getById && context.nodeType === 9 && documentIsHTML &&+ Expr.relative[ tokens[1].type ] ) {++ context = ( Expr.find["ID"]( token.matches[0].replace(runescape, funescape), context ) || [] )[0];+ if ( !context ) {+ return results;++ // Precompiled matchers will still verify ancestry, so step up a level+ } else if ( compiled ) {+ context = context.parentNode;+ }++ selector = selector.slice( tokens.shift().value.length );+ }++ // Fetch a seed set for right-to-left matching+ i = matchExpr["needsContext"].test( selector ) ? 0 : tokens.length;+ while ( i-- ) {+ token = tokens[i];++ // Abort if we hit a combinator+ if ( Expr.relative[ (type = token.type) ] ) {+ break;+ }+ if ( (find = Expr.find[ type ]) ) {+ // Search, expanding context for leading sibling combinators+ if ( (seed = find(+ token.matches[0].replace( runescape, funescape ),+ rsibling.test( tokens[0].type ) && testContext( context.parentNode ) || context+ )) ) {++ // If seed is empty or no tokens remain, we can return early+ tokens.splice( i, 1 );+ selector = seed.length && toSelector( tokens );+ if ( !selector ) {+ push.apply( results, seed );+ return results;+ }++ break;+ }+ }+ }+ }++ // Compile and execute a filtering function if one is not provided+ // Provide `match` to avoid retokenization if we modified the selector above+ ( compiled || compile( selector, match ) )(+ seed,+ context,+ !documentIsHTML,+ results,+ rsibling.test( selector ) && testContext( context.parentNode ) || context+ );+ return results;+};++// One-time assignments++// Sort stability+support.sortStable = expando.split("").sort( sortOrder ).join("") === expando;++// Support: Chrome<14+// Always assume duplicates if they aren't passed to the comparison function+support.detectDuplicates = !!hasDuplicate;++// Initialize against the default document+setDocument();++// Support: Webkit<537.32 - Safari 6.0.3/Chrome 25 (fixed in Chrome 27)+// Detached nodes confoundingly follow *each other*+support.sortDetached = assert(function( div1 ) {+ // Should return 1, but returns 4 (following)+ return div1.compareDocumentPosition( document.createElement("div") ) & 1;+});++// Support: IE<8+// Prevent attribute/property "interpolation"+// http://msdn.microsoft.com/en-us/library/ms536429%28VS.85%29.aspx+if ( !assert(function( div ) {+ div.innerHTML = "<a href='#'></a>";+ return div.firstChild.getAttribute("href") === "#" ;+}) ) {+ addHandle( "type|href|height|width", function( elem, name, isXML ) {+ if ( !isXML ) {+ return elem.getAttribute( name, name.toLowerCase() === "type" ? 1 : 2 );+ }+ });+}++// Support: IE<9+// Use defaultValue in place of getAttribute("value")+if ( !support.attributes || !assert(function( div ) {+ div.innerHTML = "<input/>";+ div.firstChild.setAttribute( "value", "" );+ return div.firstChild.getAttribute( "value" ) === "";+}) ) {+ addHandle( "value", function( elem, name, isXML ) {+ if ( !isXML && elem.nodeName.toLowerCase() === "input" ) {+ return elem.defaultValue;+ }+ });+}++// Support: IE<9+// Use getAttributeNode to fetch booleans when getAttribute lies+if ( !assert(function( div ) {+ return div.getAttribute("disabled") == null;+}) ) {+ addHandle( booleans, function( elem, name, isXML ) {+ var val;+ if ( !isXML ) {+ return elem[ name ] === true ? name.toLowerCase() :+ (val = elem.getAttributeNode( name )) && val.specified ?+ val.value :+ null;+ }+ });+}++return Sizzle;++})( window );++++jQuery.find = Sizzle;+jQuery.expr = Sizzle.selectors;+jQuery.expr[":"] = jQuery.expr.pseudos;+jQuery.unique = Sizzle.uniqueSort;+jQuery.text = Sizzle.getText;+jQuery.isXMLDoc = Sizzle.isXML;+jQuery.contains = Sizzle.contains;++++var rneedsContext = jQuery.expr.match.needsContext;++var rsingleTag = (/^<(\w+)\s*\/?>(?:<\/\1>|)$/);++++var risSimple = /^.[^:#\[\.,]*$/;++// Implement the identical functionality for filter and not+function winnow( elements, qualifier, not ) {+ if ( jQuery.isFunction( qualifier ) ) {+ return jQuery.grep( elements, function( elem, i ) {+ /* jshint -W018 */+ return !!qualifier.call( elem, i, elem ) !== not;+ });++ }++ if ( qualifier.nodeType ) {+ return jQuery.grep( elements, function( elem ) {+ return ( elem === qualifier ) !== not;+ });++ }++ if ( typeof qualifier === "string" ) {+ if ( risSimple.test( qualifier ) ) {+ return jQuery.filter( qualifier, elements, not );+ }++ qualifier = jQuery.filter( qualifier, elements );+ }++ return jQuery.grep( elements, function( elem ) {+ return ( jQuery.inArray( elem, qualifier ) >= 0 ) !== not;+ });+}++jQuery.filter = function( expr, elems, not ) {+ var elem = elems[ 0 ];++ if ( not ) {+ expr = ":not(" + expr + ")";+ }++ return elems.length === 1 && elem.nodeType === 1 ?+ jQuery.find.matchesSelector( elem, expr ) ? [ elem ] : [] :+ jQuery.find.matches( expr, jQuery.grep( elems, function( elem ) {+ return elem.nodeType === 1;+ }));+};++jQuery.fn.extend({+ find: function( selector ) {+ var i,+ ret = [],+ self = this,+ len = self.length;++ if ( typeof selector !== "string" ) {+ return this.pushStack( jQuery( selector ).filter(function() {+ for ( i = 0; i < len; i++ ) {+ if ( jQuery.contains( self[ i ], this ) ) {+ return true;+ }+ }+ }) );+ }++ for ( i = 0; i < len; i++ ) {+ jQuery.find( selector, self[ i ], ret );+ }++ // Needed because $( selector, context ) becomes $( context ).find( selector )+ ret = this.pushStack( len > 1 ? jQuery.unique( ret ) : ret );+ ret.selector = this.selector ? this.selector + " " + selector : selector;+ return ret;+ },+ filter: function( selector ) {+ return this.pushStack( winnow(this, selector || [], false) );+ },+ not: function( selector ) {+ return this.pushStack( winnow(this, selector || [], true) );+ },+ is: function( selector ) {+ return !!winnow(+ this,++ // If this is a positional/relative selector, check membership in the returned set+ // so $("p:first").is("p:last") won't return true for a doc with two "p".+ typeof selector === "string" && rneedsContext.test( selector ) ?+ jQuery( selector ) :+ selector || [],+ false+ ).length;+ }+});+++// Initialize a jQuery object+++// A central reference to the root jQuery(document)+var rootjQuery,++ // Use the correct document accordingly with window argument (sandbox)+ document = window.document,++ // A simple way to check for HTML strings+ // Prioritize #id over <tag> to avoid XSS via location.hash (#9521)+ // Strict HTML recognition (#11290: must start with <)+ rquickExpr = /^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,++ init = jQuery.fn.init = function( selector, context ) {+ var match, elem;++ // HANDLE: $(""), $(null), $(undefined), $(false)+ if ( !selector ) {+ return this;+ }++ // Handle HTML strings+ if ( typeof selector === "string" ) {+ if ( selector.charAt(0) === "<" && selector.charAt( selector.length - 1 ) === ">" && selector.length >= 3 ) {+ // Assume that strings that start and end with <> are HTML and skip the regex check+ match = [ null, selector, null ];++ } else {+ match = rquickExpr.exec( selector );+ }++ // Match html or make sure no context is specified for #id+ if ( match && (match[1] || !context) ) {++ // HANDLE: $(html) -> $(array)+ if ( match[1] ) {+ context = context instanceof jQuery ? context[0] : context;++ // scripts is true for back-compat+ // Intentionally let the error be thrown if parseHTML is not present+ jQuery.merge( this, jQuery.parseHTML(+ match[1],+ context && context.nodeType ? context.ownerDocument || context : document,+ true+ ) );++ // HANDLE: $(html, props)+ if ( rsingleTag.test( match[1] ) && jQuery.isPlainObject( context ) ) {+ for ( match in context ) {+ // Properties of context are called as methods if possible+ if ( jQuery.isFunction( this[ match ] ) ) {+ this[ match ]( context[ match ] );++ // ...and otherwise set as attributes+ } else {+ this.attr( match, context[ match ] );+ }+ }+ }++ return this;++ // HANDLE: $(#id)+ } else {+ elem = document.getElementById( match[2] );++ // Check parentNode to catch when Blackberry 4.6 returns+ // nodes that are no longer in the document #6963+ if ( elem && elem.parentNode ) {+ // Handle the case where IE and Opera return items+ // by name instead of ID+ if ( elem.id !== match[2] ) {+ return rootjQuery.find( selector );+ }++ // Otherwise, we inject the element directly into the jQuery object+ this.length = 1;+ this[0] = elem;+ }++ this.context = document;+ this.selector = selector;+ return this;+ }++ // HANDLE: $(expr, $(...))+ } else if ( !context || context.jquery ) {+ return ( context || rootjQuery ).find( selector );++ // HANDLE: $(expr, context)+ // (which is just equivalent to: $(context).find(expr)+ } else {+ return this.constructor( context ).find( selector );+ }++ // HANDLE: $(DOMElement)+ } else if ( selector.nodeType ) {+ this.context = this[0] = selector;+ this.length = 1;+ return this;++ // HANDLE: $(function)+ // Shortcut for document ready+ } else if ( jQuery.isFunction( selector ) ) {+ return typeof rootjQuery.ready !== "undefined" ?+ rootjQuery.ready( selector ) :+ // Execute immediately if ready is not present+ selector( jQuery );+ }++ if ( selector.selector !== undefined ) {+ this.selector = selector.selector;+ this.context = selector.context;+ }++ return jQuery.makeArray( selector, this );+ };++// Give the init function the jQuery prototype for later instantiation+init.prototype = jQuery.fn;++// Initialize central reference+rootjQuery = jQuery( document );+++var rparentsprev = /^(?:parents|prev(?:Until|All))/,+ // methods guaranteed to produce a unique set when starting from a unique set+ guaranteedUnique = {+ children: true,+ contents: true,+ next: true,+ prev: true+ };++jQuery.extend({+ dir: function( elem, dir, until ) {+ var matched = [],+ cur = elem[ dir ];++ while ( cur && cur.nodeType !== 9 && (until === undefined || cur.nodeType !== 1 || !jQuery( cur ).is( until )) ) {+ if ( cur.nodeType === 1 ) {+ matched.push( cur );+ }+ cur = cur[dir];+ }+ return matched;+ },++ sibling: function( n, elem ) {+ var r = [];++ for ( ; n; n = n.nextSibling ) {+ if ( n.nodeType === 1 && n !== elem ) {+ r.push( n );+ }+ }++ return r;+ }+});++jQuery.fn.extend({+ has: function( target ) {+ var i,+ targets = jQuery( target, this ),+ len = targets.length;++ return this.filter(function() {+ for ( i = 0; i < len; i++ ) {+ if ( jQuery.contains( this, targets[i] ) ) {+ return true;+ }+ }+ });+ },++ closest: function( selectors, context ) {+ var cur,+ i = 0,+ l = this.length,+ matched = [],+ pos = rneedsContext.test( selectors ) || typeof selectors !== "string" ?+ jQuery( selectors, context || this.context ) :+ 0;++ for ( ; i < l; i++ ) {+ for ( cur = this[i]; cur && cur !== context; cur = cur.parentNode ) {+ // Always skip document fragments+ if ( cur.nodeType < 11 && (pos ?+ pos.index(cur) > -1 :++ // Don't pass non-elements to Sizzle+ cur.nodeType === 1 &&+ jQuery.find.matchesSelector(cur, selectors)) ) {++ matched.push( cur );+ break;+ }+ }+ }++ return this.pushStack( matched.length > 1 ? jQuery.unique( matched ) : matched );+ },++ // Determine the position of an element within+ // the matched set of elements+ index: function( elem ) {++ // No argument, return index in parent+ if ( !elem ) {+ return ( this[0] && this[0].parentNode ) ? this.first().prevAll().length : -1;+ }++ // index in selector+ if ( typeof elem === "string" ) {+ return jQuery.inArray( this[0], jQuery( elem ) );+ }++ // Locate the position of the desired element+ return jQuery.inArray(+ // If it receives a jQuery object, the first element is used+ elem.jquery ? elem[0] : elem, this );+ },++ add: function( selector, context ) {+ return this.pushStack(+ jQuery.unique(+ jQuery.merge( this.get(), jQuery( selector, context ) )+ )+ );+ },++ addBack: function( selector ) {+ return this.add( selector == null ?+ this.prevObject : this.prevObject.filter(selector)+ );+ }+});++function sibling( cur, dir ) {+ do {+ cur = cur[ dir ];+ } while ( cur && cur.nodeType !== 1 );++ return cur;+}++jQuery.each({+ parent: function( elem ) {+ var parent = elem.parentNode;+ return parent && parent.nodeType !== 11 ? parent : null;+ },+ parents: function( elem ) {+ return jQuery.dir( elem, "parentNode" );+ },+ parentsUntil: function( elem, i, until ) {+ return jQuery.dir( elem, "parentNode", until );+ },+ next: function( elem ) {+ return sibling( elem, "nextSibling" );+ },+ prev: function( elem ) {+ return sibling( elem, "previousSibling" );+ },+ nextAll: function( elem ) {+ return jQuery.dir( elem, "nextSibling" );+ },+ prevAll: function( elem ) {+ return jQuery.dir( elem, "previousSibling" );+ },+ nextUntil: function( elem, i, until ) {+ return jQuery.dir( elem, "nextSibling", until );+ },+ prevUntil: function( elem, i, until ) {+ return jQuery.dir( elem, "previousSibling", until );+ },+ siblings: function( elem ) {+ return jQuery.sibling( ( elem.parentNode || {} ).firstChild, elem );+ },+ children: function( elem ) {+ return jQuery.sibling( elem.firstChild );+ },+ contents: function( elem ) {+ return jQuery.nodeName( elem, "iframe" ) ?+ elem.contentDocument || elem.contentWindow.document :+ jQuery.merge( [], elem.childNodes );+ }+}, function( name, fn ) {+ jQuery.fn[ name ] = function( until, selector ) {+ var ret = jQuery.map( this, fn, until );++ if ( name.slice( -5 ) !== "Until" ) {+ selector = until;+ }++ if ( selector && typeof selector === "string" ) {+ ret = jQuery.filter( selector, ret );+ }++ if ( this.length > 1 ) {+ // Remove duplicates+ if ( !guaranteedUnique[ name ] ) {+ ret = jQuery.unique( ret );+ }++ // Reverse order for parents* and prev-derivatives+ if ( rparentsprev.test( name ) ) {+ ret = ret.reverse();+ }+ }++ return this.pushStack( ret );+ };+});+var rnotwhite = (/\S+/g);++++// String to Object options format cache+var optionsCache = {};++// Convert String-formatted options into Object-formatted ones and store in cache+function createOptions( options ) {+ var object = optionsCache[ options ] = {};+ jQuery.each( options.match( rnotwhite ) || [], function( _, flag ) {+ object[ flag ] = true;+ });+ return object;+}++/*+ * Create a callback list using the following parameters:+ *+ * options: an optional list of space-separated options that will change how+ * the callback list behaves or a more traditional option object+ *+ * By default a callback list will act like an event callback list and can be+ * "fired" multiple times.+ *+ * Possible options:+ *+ * once: will ensure the callback list can only be fired once (like a Deferred)+ *+ * memory: will keep track of previous values and will call any callback added+ * after the list has been fired right away with the latest "memorized"+ * values (like a Deferred)+ *+ * unique: will ensure a callback can only be added once (no duplicate in the list)+ *+ * stopOnFalse: interrupt callings when a callback returns false+ *+ */+jQuery.Callbacks = function( options ) {++ // Convert options from String-formatted to Object-formatted if needed+ // (we check in cache first)+ options = typeof options === "string" ?+ ( optionsCache[ options ] || createOptions( options ) ) :+ jQuery.extend( {}, options );++ var // Flag to know if list is currently firing+ firing,+ // Last fire value (for non-forgettable lists)+ memory,+ // Flag to know if list was already fired+ fired,+ // End of the loop when firing+ firingLength,+ // Index of currently firing callback (modified by remove if needed)+ firingIndex,+ // First callback to fire (used internally by add and fireWith)+ firingStart,+ // Actual callback list+ list = [],+ // Stack of fire calls for repeatable lists+ stack = !options.once && [],+ // Fire callbacks+ fire = function( data ) {+ memory = options.memory && data;+ fired = true;+ firingIndex = firingStart || 0;+ firingStart = 0;+ firingLength = list.length;+ firing = true;+ for ( ; list && firingIndex < firingLength; firingIndex++ ) {+ if ( list[ firingIndex ].apply( data[ 0 ], data[ 1 ] ) === false && options.stopOnFalse ) {+ memory = false; // To prevent further calls using add+ break;+ }+ }+ firing = false;+ if ( list ) {+ if ( stack ) {+ if ( stack.length ) {+ fire( stack.shift() );+ }+ } else if ( memory ) {+ list = [];+ } else {+ self.disable();+ }+ }+ },+ // Actual Callbacks object+ self = {+ // Add a callback or a collection of callbacks to the list+ add: function() {+ if ( list ) {+ // First, we save the current length+ var start = list.length;+ (function add( args ) {+ jQuery.each( args, function( _, arg ) {+ var type = jQuery.type( arg );+ if ( type === "function" ) {+ if ( !options.unique || !self.has( arg ) ) {+ list.push( arg );+ }+ } else if ( arg && arg.length && type !== "string" ) {+ // Inspect recursively+ add( arg );+ }+ });+ })( arguments );+ // Do we need to add the callbacks to the+ // current firing batch?+ if ( firing ) {+ firingLength = list.length;+ // With memory, if we're not firing then+ // we should call right away+ } else if ( memory ) {+ firingStart = start;+ fire( memory );+ }+ }+ return this;+ },+ // Remove a callback from the list+ remove: function() {+ if ( list ) {+ jQuery.each( arguments, function( _, arg ) {+ var index;+ while ( ( index = jQuery.inArray( arg, list, index ) ) > -1 ) {+ list.splice( index, 1 );+ // Handle firing indexes+ if ( firing ) {+ if ( index <= firingLength ) {+ firingLength--;+ }+ if ( index <= firingIndex ) {+ firingIndex--;+ }+ }+ }+ });+ }+ return this;+ },+ // Check if a given callback is in the list.+ // If no argument is given, return whether or not list has callbacks attached.+ has: function( fn ) {+ return fn ? jQuery.inArray( fn, list ) > -1 : !!( list && list.length );+ },+ // Remove all callbacks from the list+ empty: function() {+ list = [];+ firingLength = 0;+ return this;+ },+ // Have the list do nothing anymore+ disable: function() {+ list = stack = memory = undefined;+ return this;+ },+ // Is it disabled?+ disabled: function() {+ return !list;+ },+ // Lock the list in its current state+ lock: function() {+ stack = undefined;+ if ( !memory ) {+ self.disable();+ }+ return this;+ },+ // Is it locked?+ locked: function() {+ return !stack;+ },+ // Call all callbacks with the given context and arguments+ fireWith: function( context, args ) {+ if ( list && ( !fired || stack ) ) {+ args = args || [];+ args = [ context, args.slice ? args.slice() : args ];+ if ( firing ) {+ stack.push( args );+ } else {+ fire( args );+ }+ }+ return this;+ },+ // Call all the callbacks with the given arguments+ fire: function() {+ self.fireWith( this, arguments );+ return this;+ },+ // To know if the callbacks have already been called at least once+ fired: function() {+ return !!fired;+ }+ };++ return self;+};+++jQuery.extend({++ Deferred: function( func ) {+ var tuples = [+ // action, add listener, listener list, final state+ [ "resolve", "done", jQuery.Callbacks("once memory"), "resolved" ],+ [ "reject", "fail", jQuery.Callbacks("once memory"), "rejected" ],+ [ "notify", "progress", jQuery.Callbacks("memory") ]+ ],+ state = "pending",+ promise = {+ state: function() {+ return state;+ },+ always: function() {+ deferred.done( arguments ).fail( arguments );+ return this;+ },+ then: function( /* fnDone, fnFail, fnProgress */ ) {+ var fns = arguments;+ return jQuery.Deferred(function( newDefer ) {+ jQuery.each( tuples, function( i, tuple ) {+ var fn = jQuery.isFunction( fns[ i ] ) && fns[ i ];+ // deferred[ done | fail | progress ] for forwarding actions to newDefer+ deferred[ tuple[1] ](function() {+ var returned = fn && fn.apply( this, arguments );+ if ( returned && jQuery.isFunction( returned.promise ) ) {+ returned.promise()+ .done( newDefer.resolve )+ .fail( newDefer.reject )+ .progress( newDefer.notify );+ } else {+ newDefer[ tuple[ 0 ] + "With" ]( this === promise ? newDefer.promise() : this, fn ? [ returned ] : arguments );+ }+ });+ });+ fns = null;+ }).promise();+ },+ // Get a promise for this deferred+ // If obj is provided, the promise aspect is added to the object+ promise: function( obj ) {+ return obj != null ? jQuery.extend( obj, promise ) : promise;+ }+ },+ deferred = {};++ // Keep pipe for back-compat+ promise.pipe = promise.then;++ // Add list-specific methods+ jQuery.each( tuples, function( i, tuple ) {+ var list = tuple[ 2 ],+ stateString = tuple[ 3 ];++ // promise[ done | fail | progress ] = list.add+ promise[ tuple[1] ] = list.add;++ // Handle state+ if ( stateString ) {+ list.add(function() {+ // state = [ resolved | rejected ]+ state = stateString;++ // [ reject_list | resolve_list ].disable; progress_list.lock+ }, tuples[ i ^ 1 ][ 2 ].disable, tuples[ 2 ][ 2 ].lock );+ }++ // deferred[ resolve | reject | notify ]+ deferred[ tuple[0] ] = function() {+ deferred[ tuple[0] + "With" ]( this === deferred ? promise : this, arguments );+ return this;+ };+ deferred[ tuple[0] + "With" ] = list.fireWith;+ });++ // Make the deferred a promise+ promise.promise( deferred );++ // Call given func if any+ if ( func ) {+ func.call( deferred, deferred );+ }++ // All done!+ return deferred;+ },++ // Deferred helper+ when: function( subordinate /* , ..., subordinateN */ ) {+ var i = 0,+ resolveValues = slice.call( arguments ),+ length = resolveValues.length,++ // the count of uncompleted subordinates+ remaining = length !== 1 || ( subordinate && jQuery.isFunction( subordinate.promise ) ) ? length : 0,++ // the master Deferred. If resolveValues consist of only a single Deferred, just use that.+ deferred = remaining === 1 ? subordinate : jQuery.Deferred(),++ // Update function for both resolve and progress values+ updateFunc = function( i, contexts, values ) {+ return function( value ) {+ contexts[ i ] = this;+ values[ i ] = arguments.length > 1 ? slice.call( arguments ) : value;+ if ( values === progressValues ) {+ deferred.notifyWith( contexts, values );++ } else if ( !(--remaining) ) {+ deferred.resolveWith( contexts, values );+ }+ };+ },++ progressValues, progressContexts, resolveContexts;++ // add listeners to Deferred subordinates; treat others as resolved+ if ( length > 1 ) {+ progressValues = new Array( length );+ progressContexts = new Array( length );+ resolveContexts = new Array( length );+ for ( ; i < length; i++ ) {+ if ( resolveValues[ i ] && jQuery.isFunction( resolveValues[ i ].promise ) ) {+ resolveValues[ i ].promise()+ .done( updateFunc( i, resolveContexts, resolveValues ) )+ .fail( deferred.reject )+ .progress( updateFunc( i, progressContexts, progressValues ) );+ } else {+ --remaining;+ }+ }+ }++ // if we're not waiting on anything, resolve the master+ if ( !remaining ) {+ deferred.resolveWith( resolveContexts, resolveValues );+ }++ return deferred.promise();+ }+});+++// The deferred used on DOM ready+var readyList;++jQuery.fn.ready = function( fn ) {+ // Add the callback+ jQuery.ready.promise().done( fn );++ return this;+};++jQuery.extend({+ // Is the DOM ready to be used? Set to true once it occurs.+ isReady: false,++ // A counter to track how many items to wait for before+ // the ready event fires. See #6781+ readyWait: 1,++ // Hold (or release) the ready event+ holdReady: function( hold ) {+ if ( hold ) {+ jQuery.readyWait++;+ } else {+ jQuery.ready( true );+ }+ },++ // Handle when the DOM is ready+ ready: function( wait ) {++ // Abort if there are pending holds or we're already ready+ if ( wait === true ? --jQuery.readyWait : jQuery.isReady ) {+ return;+ }++ // Make sure body exists, at least, in case IE gets a little overzealous (ticket #5443).+ if ( !document.body ) {+ return setTimeout( jQuery.ready );+ }++ // Remember that the DOM is ready+ jQuery.isReady = true;++ // If a normal DOM Ready event fired, decrement, and wait if need be+ if ( wait !== true && --jQuery.readyWait > 0 ) {+ return;+ }++ // If there are functions bound, to execute+ readyList.resolveWith( document, [ jQuery ] );++ // Trigger any bound ready events+ if ( jQuery.fn.triggerHandler ) {+ jQuery( document ).triggerHandler( "ready" );+ jQuery( document ).off( "ready" );+ }+ }+});++/**+ * Clean-up method for dom ready events+ */+function detach() {+ if ( document.addEventListener ) {+ document.removeEventListener( "DOMContentLoaded", completed, false );+ window.removeEventListener( "load", completed, false );++ } else {+ document.detachEvent( "onreadystatechange", completed );+ window.detachEvent( "onload", completed );+ }+}++/**+ * The ready event handler and self cleanup method+ */+function completed() {+ // readyState === "complete" is good enough for us to call the dom ready in oldIE+ if ( document.addEventListener || event.type === "load" || document.readyState === "complete" ) {+ detach();+ jQuery.ready();+ }+}++jQuery.ready.promise = function( obj ) {+ if ( !readyList ) {++ readyList = jQuery.Deferred();++ // Catch cases where $(document).ready() is called after the browser event has already occurred.+ // we once tried to use readyState "interactive" here, but it caused issues like the one+ // discovered by ChrisS here: http://bugs.jquery.com/ticket/12282#comment:15+ if ( document.readyState === "complete" ) {+ // Handle it asynchronously to allow scripts the opportunity to delay ready+ setTimeout( jQuery.ready );++ // Standards-based browsers support DOMContentLoaded+ } else if ( document.addEventListener ) {+ // Use the handy event callback+ document.addEventListener( "DOMContentLoaded", completed, false );++ // A fallback to window.onload, that will always work+ window.addEventListener( "load", completed, false );++ // If IE event model is used+ } else {+ // Ensure firing before onload, maybe late but safe also for iframes+ document.attachEvent( "onreadystatechange", completed );++ // A fallback to window.onload, that will always work+ window.attachEvent( "onload", completed );++ // If IE and not a frame+ // continually check to see if the document is ready+ var top = false;++ try {+ top = window.frameElement == null && document.documentElement;+ } catch(e) {}++ if ( top && top.doScroll ) {+ (function doScrollCheck() {+ if ( !jQuery.isReady ) {++ try {+ // Use the trick by Diego Perini+ // http://javascript.nwbox.com/IEContentLoaded/+ top.doScroll("left");+ } catch(e) {+ return setTimeout( doScrollCheck, 50 );+ }++ // detach all dom ready events+ detach();++ // and execute any waiting functions+ jQuery.ready();+ }+ })();+ }+ }+ }+ return readyList.promise( obj );+};+++var strundefined = typeof undefined;++++// Support: IE<9+// Iteration over object's inherited properties before its own+var i;+for ( i in jQuery( support ) ) {+ break;+}+support.ownLast = i !== "0";++// Note: most support tests are defined in their respective modules.+// false until the test is run+support.inlineBlockNeedsLayout = false;++// Execute ASAP in case we need to set body.style.zoom+jQuery(function() {+ // Minified: var a,b,c,d+ var val, div, body, container;++ body = document.getElementsByTagName( "body" )[ 0 ];+ if ( !body || !body.style ) {+ // Return for frameset docs that don't have a body+ return;+ }++ // Setup+ div = document.createElement( "div" );+ container = document.createElement( "div" );+ container.style.cssText = "position:absolute;border:0;width:0;height:0;top:0;left:-9999px";+ body.appendChild( container ).appendChild( div );++ if ( typeof div.style.zoom !== strundefined ) {+ // Support: IE<8+ // Check if natively block-level elements act like inline-block+ // elements when setting their display to 'inline' and giving+ // them layout+ div.style.cssText = "display:inline;margin:0;border:0;padding:1px;width:1px;zoom:1";++ support.inlineBlockNeedsLayout = val = div.offsetWidth === 3;+ if ( val ) {+ // Prevent IE 6 from affecting layout for positioned elements #11048+ // Prevent IE from shrinking the body in IE 7 mode #12869+ // Support: IE<8+ body.style.zoom = 1;+ }+ }++ body.removeChild( container );+});+++++(function() {+ var div = document.createElement( "div" );++ // Execute the test only if not already executed in another module.+ if (support.deleteExpando == null) {+ // Support: IE<9+ support.deleteExpando = true;+ try {+ delete div.test;+ } catch( e ) {+ support.deleteExpando = false;+ }+ }++ // Null elements to avoid leaks in IE.+ div = null;+})();+++/**+ * Determines whether an object can have data+ */+jQuery.acceptData = function( elem ) {+ var noData = jQuery.noData[ (elem.nodeName + " ").toLowerCase() ],+ nodeType = +elem.nodeType || 1;++ // Do not set data on non-element DOM nodes because it will not be cleared (#8335).+ return nodeType !== 1 && nodeType !== 9 ?+ false :++ // Nodes accept data unless otherwise specified; rejection can be conditional+ !noData || noData !== true && elem.getAttribute("classid") === noData;+};+++var rbrace = /^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,+ rmultiDash = /([A-Z])/g;++function dataAttr( elem, key, data ) {+ // If nothing was found internally, try to fetch any+ // data from the HTML5 data-* attribute+ if ( data === undefined && elem.nodeType === 1 ) {++ var name = "data-" + key.replace( rmultiDash, "-$1" ).toLowerCase();++ data = elem.getAttribute( name );++ if ( typeof data === "string" ) {+ try {+ data = data === "true" ? true :+ data === "false" ? false :+ data === "null" ? null :+ // Only convert to a number if it doesn't change the string+ +data + "" === data ? +data :+ rbrace.test( data ) ? jQuery.parseJSON( data ) :+ data;+ } catch( e ) {}++ // Make sure we set the data so it isn't changed later+ jQuery.data( elem, key, data );++ } else {+ data = undefined;+ }+ }++ return data;+}++// checks a cache object for emptiness+function isEmptyDataObject( obj ) {+ var name;+ for ( name in obj ) {++ // if the public data object is empty, the private is still empty+ if ( name === "data" && jQuery.isEmptyObject( obj[name] ) ) {+ continue;+ }+ if ( name !== "toJSON" ) {+ return false;+ }+ }++ return true;+}++function internalData( elem, name, data, pvt /* Internal Use Only */ ) {+ if ( !jQuery.acceptData( elem ) ) {+ return;+ }++ var ret, thisCache,+ internalKey = jQuery.expando,++ // We have to handle DOM nodes and JS objects differently because IE6-7+ // can't GC object references properly across the DOM-JS boundary+ isNode = elem.nodeType,++ // Only DOM nodes need the global jQuery cache; JS object data is+ // attached directly to the object so GC can occur automatically+ cache = isNode ? jQuery.cache : elem,++ // Only defining an ID for JS objects if its cache already exists allows+ // the code to shortcut on the same path as a DOM node with no cache+ id = isNode ? elem[ internalKey ] : elem[ internalKey ] && internalKey;++ // Avoid doing any more work than we need to when trying to get data on an+ // object that has no data at all+ if ( (!id || !cache[id] || (!pvt && !cache[id].data)) && data === undefined && typeof name === "string" ) {+ return;+ }++ if ( !id ) {+ // Only DOM nodes need a new unique ID for each element since their data+ // ends up in the global cache+ if ( isNode ) {+ id = elem[ internalKey ] = deletedIds.pop() || jQuery.guid++;+ } else {+ id = internalKey;+ }+ }++ if ( !cache[ id ] ) {+ // Avoid exposing jQuery metadata on plain JS objects when the object+ // is serialized using JSON.stringify+ cache[ id ] = isNode ? {} : { toJSON: jQuery.noop };+ }++ // An object can be passed to jQuery.data instead of a key/value pair; this gets+ // shallow copied over onto the existing cache+ if ( typeof name === "object" || typeof name === "function" ) {+ if ( pvt ) {+ cache[ id ] = jQuery.extend( cache[ id ], name );+ } else {+ cache[ id ].data = jQuery.extend( cache[ id ].data, name );+ }+ }++ thisCache = cache[ id ];++ // jQuery data() is stored in a separate object inside the object's internal data+ // cache in order to avoid key collisions between internal data and user-defined+ // data.+ if ( !pvt ) {+ if ( !thisCache.data ) {+ thisCache.data = {};+ }++ thisCache = thisCache.data;+ }++ if ( data !== undefined ) {+ thisCache[ jQuery.camelCase( name ) ] = data;+ }++ // Check for both converted-to-camel and non-converted data property names+ // If a data property was specified+ if ( typeof name === "string" ) {++ // First Try to find as-is property data+ ret = thisCache[ name ];++ // Test for null|undefined property data+ if ( ret == null ) {++ // Try to find the camelCased property+ ret = thisCache[ jQuery.camelCase( name ) ];+ }+ } else {+ ret = thisCache;+ }++ return ret;+}++function internalRemoveData( elem, name, pvt ) {+ if ( !jQuery.acceptData( elem ) ) {+ return;+ }++ var thisCache, i,+ isNode = elem.nodeType,++ // See jQuery.data for more information+ cache = isNode ? jQuery.cache : elem,+ id = isNode ? elem[ jQuery.expando ] : jQuery.expando;++ // If there is already no cache entry for this object, there is no+ // purpose in continuing+ if ( !cache[ id ] ) {+ return;+ }++ if ( name ) {++ thisCache = pvt ? cache[ id ] : cache[ id ].data;++ if ( thisCache ) {++ // Support array or space separated string names for data keys+ if ( !jQuery.isArray( name ) ) {++ // try the string as a key before any manipulation+ if ( name in thisCache ) {+ name = [ name ];+ } else {++ // split the camel cased version by spaces unless a key with the spaces exists+ name = jQuery.camelCase( name );+ if ( name in thisCache ) {+ name = [ name ];+ } else {+ name = name.split(" ");+ }+ }+ } else {+ // If "name" is an array of keys...+ // When data is initially created, via ("key", "val") signature,+ // keys will be converted to camelCase.+ // Since there is no way to tell _how_ a key was added, remove+ // both plain key and camelCase key. #12786+ // This will only penalize the array argument path.+ name = name.concat( jQuery.map( name, jQuery.camelCase ) );+ }++ i = name.length;+ while ( i-- ) {+ delete thisCache[ name[i] ];+ }++ // If there is no data left in the cache, we want to continue+ // and let the cache object itself get destroyed+ if ( pvt ? !isEmptyDataObject(thisCache) : !jQuery.isEmptyObject(thisCache) ) {+ return;+ }+ }+ }++ // See jQuery.data for more information+ if ( !pvt ) {+ delete cache[ id ].data;++ // Don't destroy the parent cache unless the internal data object+ // had been the only thing left in it+ if ( !isEmptyDataObject( cache[ id ] ) ) {+ return;+ }+ }++ // Destroy the cache+ if ( isNode ) {+ jQuery.cleanData( [ elem ], true );++ // Use delete when supported for expandos or `cache` is not a window per isWindow (#10080)+ /* jshint eqeqeq: false */+ } else if ( support.deleteExpando || cache != cache.window ) {+ /* jshint eqeqeq: true */+ delete cache[ id ];++ // When all else fails, null+ } else {+ cache[ id ] = null;+ }+}++jQuery.extend({+ cache: {},++ // The following elements (space-suffixed to avoid Object.prototype collisions)+ // throw uncatchable exceptions if you attempt to set expando properties+ noData: {+ "applet ": true,+ "embed ": true,+ // ...but Flash objects (which have this classid) *can* handle expandos+ "object ": "clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"+ },++ hasData: function( elem ) {+ elem = elem.nodeType ? jQuery.cache[ elem[jQuery.expando] ] : elem[ jQuery.expando ];+ return !!elem && !isEmptyDataObject( elem );+ },++ data: function( elem, name, data ) {+ return internalData( elem, name, data );+ },++ removeData: function( elem, name ) {+ return internalRemoveData( elem, name );+ },++ // For internal use only.+ _data: function( elem, name, data ) {+ return internalData( elem, name, data, true );+ },++ _removeData: function( elem, name ) {+ return internalRemoveData( elem, name, true );+ }+});++jQuery.fn.extend({+ data: function( key, value ) {+ var i, name, data,+ elem = this[0],+ attrs = elem && elem.attributes;++ // Special expections of .data basically thwart jQuery.access,+ // so implement the relevant behavior ourselves++ // Gets all values+ if ( key === undefined ) {+ if ( this.length ) {+ data = jQuery.data( elem );++ if ( elem.nodeType === 1 && !jQuery._data( elem, "parsedAttrs" ) ) {+ i = attrs.length;+ while ( i-- ) {++ // Support: IE11++ // The attrs elements can be null (#14894)+ if ( attrs[ i ] ) {+ name = attrs[ i ].name;+ if ( name.indexOf( "data-" ) === 0 ) {+ name = jQuery.camelCase( name.slice(5) );+ dataAttr( elem, name, data[ name ] );+ }+ }+ }+ jQuery._data( elem, "parsedAttrs", true );+ }+ }++ return data;+ }++ // Sets multiple values+ if ( typeof key === "object" ) {+ return this.each(function() {+ jQuery.data( this, key );+ });+ }++ return arguments.length > 1 ?++ // Sets one value+ this.each(function() {+ jQuery.data( this, key, value );+ }) :++ // Gets one value+ // Try to fetch any internally stored data first+ elem ? dataAttr( elem, key, jQuery.data( elem, key ) ) : undefined;+ },++ removeData: function( key ) {+ return this.each(function() {+ jQuery.removeData( this, key );+ });+ }+});+++jQuery.extend({+ queue: function( elem, type, data ) {+ var queue;++ if ( elem ) {+ type = ( type || "fx" ) + "queue";+ queue = jQuery._data( elem, type );++ // Speed up dequeue by getting out quickly if this is just a lookup+ if ( data ) {+ if ( !queue || jQuery.isArray(data) ) {+ queue = jQuery._data( elem, type, jQuery.makeArray(data) );+ } else {+ queue.push( data );+ }+ }+ return queue || [];+ }+ },++ dequeue: function( elem, type ) {+ type = type || "fx";++ var queue = jQuery.queue( elem, type ),+ startLength = queue.length,+ fn = queue.shift(),+ hooks = jQuery._queueHooks( elem, type ),+ next = function() {+ jQuery.dequeue( elem, type );+ };++ // If the fx queue is dequeued, always remove the progress sentinel+ if ( fn === "inprogress" ) {+ fn = queue.shift();+ startLength--;+ }++ if ( fn ) {++ // Add a progress sentinel to prevent the fx queue from being+ // automatically dequeued+ if ( type === "fx" ) {+ queue.unshift( "inprogress" );+ }++ // clear up the last queue stop function+ delete hooks.stop;+ fn.call( elem, next, hooks );+ }++ if ( !startLength && hooks ) {+ hooks.empty.fire();+ }+ },++ // not intended for public consumption - generates a queueHooks object, or returns the current one+ _queueHooks: function( elem, type ) {+ var key = type + "queueHooks";+ return jQuery._data( elem, key ) || jQuery._data( elem, key, {+ empty: jQuery.Callbacks("once memory").add(function() {+ jQuery._removeData( elem, type + "queue" );+ jQuery._removeData( elem, key );+ })+ });+ }+});++jQuery.fn.extend({+ queue: function( type, data ) {+ var setter = 2;++ if ( typeof type !== "string" ) {+ data = type;+ type = "fx";+ setter--;+ }++ if ( arguments.length < setter ) {+ return jQuery.queue( this[0], type );+ }++ return data === undefined ?+ this :+ this.each(function() {+ var queue = jQuery.queue( this, type, data );++ // ensure a hooks for this queue+ jQuery._queueHooks( this, type );++ if ( type === "fx" && queue[0] !== "inprogress" ) {+ jQuery.dequeue( this, type );+ }+ });+ },+ dequeue: function( type ) {+ return this.each(function() {+ jQuery.dequeue( this, type );+ });+ },+ clearQueue: function( type ) {+ return this.queue( type || "fx", [] );+ },+ // Get a promise resolved when queues of a certain type+ // are emptied (fx is the type by default)+ promise: function( type, obj ) {+ var tmp,+ count = 1,+ defer = jQuery.Deferred(),+ elements = this,+ i = this.length,+ resolve = function() {+ if ( !( --count ) ) {+ defer.resolveWith( elements, [ elements ] );+ }+ };++ if ( typeof type !== "string" ) {+ obj = type;+ type = undefined;+ }+ type = type || "fx";++ while ( i-- ) {+ tmp = jQuery._data( elements[ i ], type + "queueHooks" );+ if ( tmp && tmp.empty ) {+ count++;+ tmp.empty.add( resolve );+ }+ }+ resolve();+ return defer.promise( obj );+ }+});+var pnum = (/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/).source;++var cssExpand = [ "Top", "Right", "Bottom", "Left" ];++var isHidden = function( elem, el ) {+ // isHidden might be called from jQuery#filter function;+ // in that case, element will be second argument+ elem = el || elem;+ return jQuery.css( elem, "display" ) === "none" || !jQuery.contains( elem.ownerDocument, elem );+ };++++// Multifunctional method to get and set values of a collection+// The value/s can optionally be executed if it's a function+var access = jQuery.access = function( elems, fn, key, value, chainable, emptyGet, raw ) {+ var i = 0,+ length = elems.length,+ bulk = key == null;++ // Sets many values+ if ( jQuery.type( key ) === "object" ) {+ chainable = true;+ for ( i in key ) {+ jQuery.access( elems, fn, i, key[i], true, emptyGet, raw );+ }++ // Sets one value+ } else if ( value !== undefined ) {+ chainable = true;++ if ( !jQuery.isFunction( value ) ) {+ raw = true;+ }++ if ( bulk ) {+ // Bulk operations run against the entire set+ if ( raw ) {+ fn.call( elems, value );+ fn = null;++ // ...except when executing function values+ } else {+ bulk = fn;+ fn = function( elem, key, value ) {+ return bulk.call( jQuery( elem ), value );+ };+ }+ }++ if ( fn ) {+ for ( ; i < length; i++ ) {+ fn( elems[i], key, raw ? value : value.call( elems[i], i, fn( elems[i], key ) ) );+ }+ }+ }++ return chainable ?+ elems :++ // Gets+ bulk ?+ fn.call( elems ) :+ length ? fn( elems[0], key ) : emptyGet;+};+var rcheckableType = (/^(?:checkbox|radio)$/i);++++(function() {+ // Minified: var a,b,c+ var input = document.createElement( "input" ),+ div = document.createElement( "div" ),+ fragment = document.createDocumentFragment();++ // Setup+ div.innerHTML = " <link/><table></table><a href='/a'>a</a><input type='checkbox'/>";++ // IE strips leading whitespace when .innerHTML is used+ support.leadingWhitespace = div.firstChild.nodeType === 3;++ // Make sure that tbody elements aren't automatically inserted+ // IE will insert them into empty tables+ support.tbody = !div.getElementsByTagName( "tbody" ).length;++ // Make sure that link elements get serialized correctly by innerHTML+ // This requires a wrapper element in IE+ support.htmlSerialize = !!div.getElementsByTagName( "link" ).length;++ // Makes sure cloning an html5 element does not cause problems+ // Where outerHTML is undefined, this still works+ support.html5Clone =+ document.createElement( "nav" ).cloneNode( true ).outerHTML !== "<:nav></:nav>";++ // Check if a disconnected checkbox will retain its checked+ // value of true after appended to the DOM (IE6/7)+ input.type = "checkbox";+ input.checked = true;+ fragment.appendChild( input );+ support.appendChecked = input.checked;++ // Make sure textarea (and checkbox) defaultValue is properly cloned+ // Support: IE6-IE11++ div.innerHTML = "<textarea>x</textarea>";+ support.noCloneChecked = !!div.cloneNode( true ).lastChild.defaultValue;++ // #11217 - WebKit loses check when the name is after the checked attribute+ fragment.appendChild( div );+ div.innerHTML = "<input type='radio' checked='checked' name='t'/>";++ // Support: Safari 5.1, iOS 5.1, Android 4.x, Android 2.3+ // old WebKit doesn't clone checked state correctly in fragments+ support.checkClone = div.cloneNode( true ).cloneNode( true ).lastChild.checked;++ // Support: IE<9+ // Opera does not clone events (and typeof div.attachEvent === undefined).+ // IE9-10 clones events bound via attachEvent, but they don't trigger with .click()+ support.noCloneEvent = true;+ if ( div.attachEvent ) {+ div.attachEvent( "onclick", function() {+ support.noCloneEvent = false;+ });++ div.cloneNode( true ).click();+ }++ // Execute the test only if not already executed in another module.+ if (support.deleteExpando == null) {+ // Support: IE<9+ support.deleteExpando = true;+ try {+ delete div.test;+ } catch( e ) {+ support.deleteExpando = false;+ }+ }+})();+++(function() {+ var i, eventName,+ div = document.createElement( "div" );++ // Support: IE<9 (lack submit/change bubble), Firefox 23+ (lack focusin event)+ for ( i in { submit: true, change: true, focusin: true }) {+ eventName = "on" + i;++ if ( !(support[ i + "Bubbles" ] = eventName in window) ) {+ // Beware of CSP restrictions (https://developer.mozilla.org/en/Security/CSP)+ div.setAttribute( eventName, "t" );+ support[ i + "Bubbles" ] = div.attributes[ eventName ].expando === false;+ }+ }++ // Null elements to avoid leaks in IE.+ div = null;+})();+++var rformElems = /^(?:input|select|textarea)$/i,+ rkeyEvent = /^key/,+ rmouseEvent = /^(?:mouse|pointer|contextmenu)|click/,+ rfocusMorph = /^(?:focusinfocus|focusoutblur)$/,+ rtypenamespace = /^([^.]*)(?:\.(.+)|)$/;++function returnTrue() {+ return true;+}++function returnFalse() {+ return false;+}++function safeActiveElement() {+ try {+ return document.activeElement;+ } catch ( err ) { }+}++/*+ * Helper functions for managing events -- not part of the public interface.+ * Props to Dean Edwards' addEvent library for many of the ideas.+ */+jQuery.event = {++ global: {},++ add: function( elem, types, handler, data, selector ) {+ var tmp, events, t, handleObjIn,+ special, eventHandle, handleObj,+ handlers, type, namespaces, origType,+ elemData = jQuery._data( elem );++ // Don't attach events to noData or text/comment nodes (but allow plain objects)+ if ( !elemData ) {+ return;+ }++ // Caller can pass in an object of custom data in lieu of the handler+ if ( handler.handler ) {+ handleObjIn = handler;+ handler = handleObjIn.handler;+ selector = handleObjIn.selector;+ }++ // Make sure that the handler has a unique ID, used to find/remove it later+ if ( !handler.guid ) {+ handler.guid = jQuery.guid++;+ }++ // Init the element's event structure and main handler, if this is the first+ if ( !(events = elemData.events) ) {+ events = elemData.events = {};+ }+ if ( !(eventHandle = elemData.handle) ) {+ eventHandle = elemData.handle = function( e ) {+ // Discard the second event of a jQuery.event.trigger() and+ // when an event is called after a page has unloaded+ return typeof jQuery !== strundefined && (!e || jQuery.event.triggered !== e.type) ?+ jQuery.event.dispatch.apply( eventHandle.elem, arguments ) :+ undefined;+ };+ // Add elem as a property of the handle fn to prevent a memory leak with IE non-native events+ eventHandle.elem = elem;+ }++ // Handle multiple events separated by a space+ types = ( types || "" ).match( rnotwhite ) || [ "" ];+ t = types.length;+ while ( t-- ) {+ tmp = rtypenamespace.exec( types[t] ) || [];+ type = origType = tmp[1];+ namespaces = ( tmp[2] || "" ).split( "." ).sort();++ // There *must* be a type, no attaching namespace-only handlers+ if ( !type ) {+ continue;+ }++ // If event changes its type, use the special event handlers for the changed type+ special = jQuery.event.special[ type ] || {};++ // If selector defined, determine special event api type, otherwise given type+ type = ( selector ? special.delegateType : special.bindType ) || type;++ // Update special based on newly reset type+ special = jQuery.event.special[ type ] || {};++ // handleObj is passed to all event handlers+ handleObj = jQuery.extend({+ type: type,+ origType: origType,+ data: data,+ handler: handler,+ guid: handler.guid,+ selector: selector,+ needsContext: selector && jQuery.expr.match.needsContext.test( selector ),+ namespace: namespaces.join(".")+ }, handleObjIn );++ // Init the event handler queue if we're the first+ if ( !(handlers = events[ type ]) ) {+ handlers = events[ type ] = [];+ handlers.delegateCount = 0;++ // Only use addEventListener/attachEvent if the special events handler returns false+ if ( !special.setup || special.setup.call( elem, data, namespaces, eventHandle ) === false ) {+ // Bind the global event handler to the element+ if ( elem.addEventListener ) {+ elem.addEventListener( type, eventHandle, false );++ } else if ( elem.attachEvent ) {+ elem.attachEvent( "on" + type, eventHandle );+ }+ }+ }++ if ( special.add ) {+ special.add.call( elem, handleObj );++ if ( !handleObj.handler.guid ) {+ handleObj.handler.guid = handler.guid;+ }+ }++ // Add to the element's handler list, delegates in front+ if ( selector ) {+ handlers.splice( handlers.delegateCount++, 0, handleObj );+ } else {+ handlers.push( handleObj );+ }++ // Keep track of which events have ever been used, for event optimization+ jQuery.event.global[ type ] = true;+ }++ // Nullify elem to prevent memory leaks in IE+ elem = null;+ },++ // Detach an event or set of events from an element+ remove: function( elem, types, handler, selector, mappedTypes ) {+ var j, handleObj, tmp,+ origCount, t, events,+ special, handlers, type,+ namespaces, origType,+ elemData = jQuery.hasData( elem ) && jQuery._data( elem );++ if ( !elemData || !(events = elemData.events) ) {+ return;+ }++ // Once for each type.namespace in types; type may be omitted+ types = ( types || "" ).match( rnotwhite ) || [ "" ];+ t = types.length;+ while ( t-- ) {+ tmp = rtypenamespace.exec( types[t] ) || [];+ type = origType = tmp[1];+ namespaces = ( tmp[2] || "" ).split( "." ).sort();++ // Unbind all events (on this namespace, if provided) for the element+ if ( !type ) {+ for ( type in events ) {+ jQuery.event.remove( elem, type + types[ t ], handler, selector, true );+ }+ continue;+ }++ special = jQuery.event.special[ type ] || {};+ type = ( selector ? special.delegateType : special.bindType ) || type;+ handlers = events[ type ] || [];+ tmp = tmp[2] && new RegExp( "(^|\\.)" + namespaces.join("\\.(?:.*\\.|)") + "(\\.|$)" );++ // Remove matching events+ origCount = j = handlers.length;+ while ( j-- ) {+ handleObj = handlers[ j ];++ if ( ( mappedTypes || origType === handleObj.origType ) &&+ ( !handler || handler.guid === handleObj.guid ) &&+ ( !tmp || tmp.test( handleObj.namespace ) ) &&+ ( !selector || selector === handleObj.selector || selector === "**" && handleObj.selector ) ) {+ handlers.splice( j, 1 );++ if ( handleObj.selector ) {+ handlers.delegateCount--;+ }+ if ( special.remove ) {+ special.remove.call( elem, handleObj );+ }+ }+ }++ // Remove generic event handler if we removed something and no more handlers exist+ // (avoids potential for endless recursion during removal of special event handlers)+ if ( origCount && !handlers.length ) {+ if ( !special.teardown || special.teardown.call( elem, namespaces, elemData.handle ) === false ) {+ jQuery.removeEvent( elem, type, elemData.handle );+ }++ delete events[ type ];+ }+ }++ // Remove the expando if it's no longer used+ if ( jQuery.isEmptyObject( events ) ) {+ delete elemData.handle;++ // removeData also checks for emptiness and clears the expando if empty+ // so use it instead of delete+ jQuery._removeData( elem, "events" );+ }+ },++ trigger: function( event, data, elem, onlyHandlers ) {+ var handle, ontype, cur,+ bubbleType, special, tmp, i,+ eventPath = [ elem || document ],+ type = hasOwn.call( event, "type" ) ? event.type : event,+ namespaces = hasOwn.call( event, "namespace" ) ? event.namespace.split(".") : [];++ cur = tmp = elem = elem || document;++ // Don't do events on text and comment nodes+ if ( elem.nodeType === 3 || elem.nodeType === 8 ) {+ return;+ }++ // focus/blur morphs to focusin/out; ensure we're not firing them right now+ if ( rfocusMorph.test( type + jQuery.event.triggered ) ) {+ return;+ }++ if ( type.indexOf(".") >= 0 ) {+ // Namespaced trigger; create a regexp to match event type in handle()+ namespaces = type.split(".");+ type = namespaces.shift();+ namespaces.sort();+ }+ ontype = type.indexOf(":") < 0 && "on" + type;++ // Caller can pass in a jQuery.Event object, Object, or just an event type string+ event = event[ jQuery.expando ] ?+ event :+ new jQuery.Event( type, typeof event === "object" && event );++ // Trigger bitmask: & 1 for native handlers; & 2 for jQuery (always true)+ event.isTrigger = onlyHandlers ? 2 : 3;+ event.namespace = namespaces.join(".");+ event.namespace_re = event.namespace ?+ new RegExp( "(^|\\.)" + namespaces.join("\\.(?:.*\\.|)") + "(\\.|$)" ) :+ null;++ // Clean up the event in case it is being reused+ event.result = undefined;+ if ( !event.target ) {+ event.target = elem;+ }++ // Clone any incoming data and prepend the event, creating the handler arg list+ data = data == null ?+ [ event ] :+ jQuery.makeArray( data, [ event ] );++ // Allow special events to draw outside the lines+ special = jQuery.event.special[ type ] || {};+ if ( !onlyHandlers && special.trigger && special.trigger.apply( elem, data ) === false ) {+ return;+ }++ // Determine event propagation path in advance, per W3C events spec (#9951)+ // Bubble up to document, then to window; watch for a global ownerDocument var (#9724)+ if ( !onlyHandlers && !special.noBubble && !jQuery.isWindow( elem ) ) {++ bubbleType = special.delegateType || type;+ if ( !rfocusMorph.test( bubbleType + type ) ) {+ cur = cur.parentNode;+ }+ for ( ; cur; cur = cur.parentNode ) {+ eventPath.push( cur );+ tmp = cur;+ }++ // Only add window if we got to document (e.g., not plain obj or detached DOM)+ if ( tmp === (elem.ownerDocument || document) ) {+ eventPath.push( tmp.defaultView || tmp.parentWindow || window );+ }+ }++ // Fire handlers on the event path+ i = 0;+ while ( (cur = eventPath[i++]) && !event.isPropagationStopped() ) {++ event.type = i > 1 ?+ bubbleType :+ special.bindType || type;++ // jQuery handler+ handle = ( jQuery._data( cur, "events" ) || {} )[ event.type ] && jQuery._data( cur, "handle" );+ if ( handle ) {+ handle.apply( cur, data );+ }++ // Native handler+ handle = ontype && cur[ ontype ];+ if ( handle && handle.apply && jQuery.acceptData( cur ) ) {+ event.result = handle.apply( cur, data );+ if ( event.result === false ) {+ event.preventDefault();+ }+ }+ }+ event.type = type;++ // If nobody prevented the default action, do it now+ if ( !onlyHandlers && !event.isDefaultPrevented() ) {++ if ( (!special._default || special._default.apply( eventPath.pop(), data ) === false) &&+ jQuery.acceptData( elem ) ) {++ // Call a native DOM method on the target with the same name name as the event.+ // Can't use an .isFunction() check here because IE6/7 fails that test.+ // Don't do default actions on window, that's where global variables be (#6170)+ if ( ontype && elem[ type ] && !jQuery.isWindow( elem ) ) {++ // Don't re-trigger an onFOO event when we call its FOO() method+ tmp = elem[ ontype ];++ if ( tmp ) {+ elem[ ontype ] = null;+ }++ // Prevent re-triggering of the same event, since we already bubbled it above+ jQuery.event.triggered = type;+ try {+ elem[ type ]();+ } catch ( e ) {+ // IE<9 dies on focus/blur to hidden element (#1486,#12518)+ // only reproducible on winXP IE8 native, not IE9 in IE8 mode+ }+ jQuery.event.triggered = undefined;++ if ( tmp ) {+ elem[ ontype ] = tmp;+ }+ }+ }+ }++ return event.result;+ },++ dispatch: function( event ) {++ // Make a writable jQuery.Event from the native event object+ event = jQuery.event.fix( event );++ var i, ret, handleObj, matched, j,+ handlerQueue = [],+ args = slice.call( arguments ),+ handlers = ( jQuery._data( this, "events" ) || {} )[ event.type ] || [],+ special = jQuery.event.special[ event.type ] || {};++ // Use the fix-ed jQuery.Event rather than the (read-only) native event+ args[0] = event;+ event.delegateTarget = this;++ // Call the preDispatch hook for the mapped type, and let it bail if desired+ if ( special.preDispatch && special.preDispatch.call( this, event ) === false ) {+ return;+ }++ // Determine handlers+ handlerQueue = jQuery.event.handlers.call( this, event, handlers );++ // Run delegates first; they may want to stop propagation beneath us+ i = 0;+ while ( (matched = handlerQueue[ i++ ]) && !event.isPropagationStopped() ) {+ event.currentTarget = matched.elem;++ j = 0;+ while ( (handleObj = matched.handlers[ j++ ]) && !event.isImmediatePropagationStopped() ) {++ // Triggered event must either 1) have no namespace, or+ // 2) have namespace(s) a subset or equal to those in the bound event (both can have no namespace).+ if ( !event.namespace_re || event.namespace_re.test( handleObj.namespace ) ) {++ event.handleObj = handleObj;+ event.data = handleObj.data;++ ret = ( (jQuery.event.special[ handleObj.origType ] || {}).handle || handleObj.handler )+ .apply( matched.elem, args );++ if ( ret !== undefined ) {+ if ( (event.result = ret) === false ) {+ event.preventDefault();+ event.stopPropagation();+ }+ }+ }+ }+ }++ // Call the postDispatch hook for the mapped type+ if ( special.postDispatch ) {+ special.postDispatch.call( this, event );+ }++ return event.result;+ },++ handlers: function( event, handlers ) {+ var sel, handleObj, matches, i,+ handlerQueue = [],+ delegateCount = handlers.delegateCount,+ cur = event.target;++ // Find delegate handlers+ // Black-hole SVG <use> instance trees (#13180)+ // Avoid non-left-click bubbling in Firefox (#3861)+ if ( delegateCount && cur.nodeType && (!event.button || event.type !== "click") ) {++ /* jshint eqeqeq: false */+ for ( ; cur != this; cur = cur.parentNode || this ) {+ /* jshint eqeqeq: true */++ // Don't check non-elements (#13208)+ // Don't process clicks on disabled elements (#6911, #8165, #11382, #11764)+ if ( cur.nodeType === 1 && (cur.disabled !== true || event.type !== "click") ) {+ matches = [];+ for ( i = 0; i < delegateCount; i++ ) {+ handleObj = handlers[ i ];++ // Don't conflict with Object.prototype properties (#13203)+ sel = handleObj.selector + " ";++ if ( matches[ sel ] === undefined ) {+ matches[ sel ] = handleObj.needsContext ?+ jQuery( sel, this ).index( cur ) >= 0 :+ jQuery.find( sel, this, null, [ cur ] ).length;+ }+ if ( matches[ sel ] ) {+ matches.push( handleObj );+ }+ }+ if ( matches.length ) {+ handlerQueue.push({ elem: cur, handlers: matches });+ }+ }+ }+ }++ // Add the remaining (directly-bound) handlers+ if ( delegateCount < handlers.length ) {+ handlerQueue.push({ elem: this, handlers: handlers.slice( delegateCount ) });+ }++ return handlerQueue;+ },++ fix: function( event ) {+ if ( event[ jQuery.expando ] ) {+ return event;+ }++ // Create a writable copy of the event object and normalize some properties+ var i, prop, copy,+ type = event.type,+ originalEvent = event,+ fixHook = this.fixHooks[ type ];++ if ( !fixHook ) {+ this.fixHooks[ type ] = fixHook =+ rmouseEvent.test( type ) ? this.mouseHooks :+ rkeyEvent.test( type ) ? this.keyHooks :+ {};+ }+ copy = fixHook.props ? this.props.concat( fixHook.props ) : this.props;++ event = new jQuery.Event( originalEvent );++ i = copy.length;+ while ( i-- ) {+ prop = copy[ i ];+ event[ prop ] = originalEvent[ prop ];+ }++ // Support: IE<9+ // Fix target property (#1925)+ if ( !event.target ) {+ event.target = originalEvent.srcElement || document;+ }++ // Support: Chrome 23+, Safari?+ // Target should not be a text node (#504, #13143)+ if ( event.target.nodeType === 3 ) {+ event.target = event.target.parentNode;+ }++ // Support: IE<9+ // For mouse/key events, metaKey==false if it's undefined (#3368, #11328)+ event.metaKey = !!event.metaKey;++ return fixHook.filter ? fixHook.filter( event, originalEvent ) : event;+ },++ // Includes some event props shared by KeyEvent and MouseEvent+ props: "altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),++ fixHooks: {},++ keyHooks: {+ props: "char charCode key keyCode".split(" "),+ filter: function( event, original ) {++ // Add which for key events+ if ( event.which == null ) {+ event.which = original.charCode != null ? original.charCode : original.keyCode;+ }++ return event;+ }+ },++ mouseHooks: {+ props: "button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),+ filter: function( event, original ) {+ var body, eventDoc, doc,+ button = original.button,+ fromElement = original.fromElement;++ // Calculate pageX/Y if missing and clientX/Y available+ if ( event.pageX == null && original.clientX != null ) {+ eventDoc = event.target.ownerDocument || document;+ doc = eventDoc.documentElement;+ body = eventDoc.body;++ event.pageX = original.clientX + ( doc && doc.scrollLeft || body && body.scrollLeft || 0 ) - ( doc && doc.clientLeft || body && body.clientLeft || 0 );+ event.pageY = original.clientY + ( doc && doc.scrollTop || body && body.scrollTop || 0 ) - ( doc && doc.clientTop || body && body.clientTop || 0 );+ }++ // Add relatedTarget, if necessary+ if ( !event.relatedTarget && fromElement ) {+ event.relatedTarget = fromElement === event.target ? original.toElement : fromElement;+ }++ // Add which for click: 1 === left; 2 === middle; 3 === right+ // Note: button is not normalized, so don't use it+ if ( !event.which && button !== undefined ) {+ event.which = ( button & 1 ? 1 : ( button & 2 ? 3 : ( button & 4 ? 2 : 0 ) ) );+ }++ return event;+ }+ },++ special: {+ load: {+ // Prevent triggered image.load events from bubbling to window.load+ noBubble: true+ },+ focus: {+ // Fire native event if possible so blur/focus sequence is correct+ trigger: function() {+ if ( this !== safeActiveElement() && this.focus ) {+ try {+ this.focus();+ return false;+ } catch ( e ) {+ // Support: IE<9+ // If we error on focus to hidden element (#1486, #12518),+ // let .trigger() run the handlers+ }+ }+ },+ delegateType: "focusin"+ },+ blur: {+ trigger: function() {+ if ( this === safeActiveElement() && this.blur ) {+ this.blur();+ return false;+ }+ },+ delegateType: "focusout"+ },+ click: {+ // For checkbox, fire native event so checked state will be right+ trigger: function() {+ if ( jQuery.nodeName( this, "input" ) && this.type === "checkbox" && this.click ) {+ this.click();+ return false;+ }+ },++ // For cross-browser consistency, don't fire native .click() on links+ _default: function( event ) {+ return jQuery.nodeName( event.target, "a" );+ }+ },++ beforeunload: {+ postDispatch: function( event ) {++ // Support: Firefox 20++ // Firefox doesn't alert if the returnValue field is not set.+ if ( event.result !== undefined && event.originalEvent ) {+ event.originalEvent.returnValue = event.result;+ }+ }+ }+ },++ simulate: function( type, elem, event, bubble ) {+ // Piggyback on a donor event to simulate a different one.+ // Fake originalEvent to avoid donor's stopPropagation, but if the+ // simulated event prevents default then we do the same on the donor.+ var e = jQuery.extend(+ new jQuery.Event(),+ event,+ {+ type: type,+ isSimulated: true,+ originalEvent: {}+ }+ );+ if ( bubble ) {+ jQuery.event.trigger( e, null, elem );+ } else {+ jQuery.event.dispatch.call( elem, e );+ }+ if ( e.isDefaultPrevented() ) {+ event.preventDefault();+ }+ }+};++jQuery.removeEvent = document.removeEventListener ?+ function( elem, type, handle ) {+ if ( elem.removeEventListener ) {+ elem.removeEventListener( type, handle, false );+ }+ } :+ function( elem, type, handle ) {+ var name = "on" + type;++ if ( elem.detachEvent ) {++ // #8545, #7054, preventing memory leaks for custom events in IE6-8+ // detachEvent needed property on element, by name of that event, to properly expose it to GC+ if ( typeof elem[ name ] === strundefined ) {+ elem[ name ] = null;+ }++ elem.detachEvent( name, handle );+ }+ };++jQuery.Event = function( src, props ) {+ // Allow instantiation without the 'new' keyword+ if ( !(this instanceof jQuery.Event) ) {+ return new jQuery.Event( src, props );+ }++ // Event object+ if ( src && src.type ) {+ this.originalEvent = src;+ this.type = src.type;++ // Events bubbling up the document may have been marked as prevented+ // by a handler lower down the tree; reflect the correct value.+ this.isDefaultPrevented = src.defaultPrevented ||+ src.defaultPrevented === undefined &&+ // Support: IE < 9, Android < 4.0+ src.returnValue === false ?+ returnTrue :+ returnFalse;++ // Event type+ } else {+ this.type = src;+ }++ // Put explicitly provided properties onto the event object+ if ( props ) {+ jQuery.extend( this, props );+ }++ // Create a timestamp if incoming event doesn't have one+ this.timeStamp = src && src.timeStamp || jQuery.now();++ // Mark it as fixed+ this[ jQuery.expando ] = true;+};++// jQuery.Event is based on DOM3 Events as specified by the ECMAScript Language Binding+// http://www.w3.org/TR/2003/WD-DOM-Level-3-Events-20030331/ecma-script-binding.html+jQuery.Event.prototype = {+ isDefaultPrevented: returnFalse,+ isPropagationStopped: returnFalse,+ isImmediatePropagationStopped: returnFalse,++ preventDefault: function() {+ var e = this.originalEvent;++ this.isDefaultPrevented = returnTrue;+ if ( !e ) {+ return;+ }++ // If preventDefault exists, run it on the original event+ if ( e.preventDefault ) {+ e.preventDefault();++ // Support: IE+ // Otherwise set the returnValue property of the original event to false+ } else {+ e.returnValue = false;+ }+ },+ stopPropagation: function() {+ var e = this.originalEvent;++ this.isPropagationStopped = returnTrue;+ if ( !e ) {+ return;+ }+ // If stopPropagation exists, run it on the original event+ if ( e.stopPropagation ) {+ e.stopPropagation();+ }++ // Support: IE+ // Set the cancelBubble property of the original event to true+ e.cancelBubble = true;+ },+ stopImmediatePropagation: function() {+ var e = this.originalEvent;++ this.isImmediatePropagationStopped = returnTrue;++ if ( e && e.stopImmediatePropagation ) {+ e.stopImmediatePropagation();+ }++ this.stopPropagation();+ }+};++// Create mouseenter/leave events using mouseover/out and event-time checks+jQuery.each({+ mouseenter: "mouseover",+ mouseleave: "mouseout",+ pointerenter: "pointerover",+ pointerleave: "pointerout"+}, function( orig, fix ) {+ jQuery.event.special[ orig ] = {+ delegateType: fix,+ bindType: fix,++ handle: function( event ) {+ var ret,+ target = this,+ related = event.relatedTarget,+ handleObj = event.handleObj;++ // For mousenter/leave call the handler if related is outside the target.+ // NB: No relatedTarget if the mouse left/entered the browser window+ if ( !related || (related !== target && !jQuery.contains( target, related )) ) {+ event.type = handleObj.origType;+ ret = handleObj.handler.apply( this, arguments );+ event.type = fix;+ }+ return ret;+ }+ };+});++// IE submit delegation+if ( !support.submitBubbles ) {++ jQuery.event.special.submit = {+ setup: function() {+ // Only need this for delegated form submit events+ if ( jQuery.nodeName( this, "form" ) ) {+ return false;+ }++ // Lazy-add a submit handler when a descendant form may potentially be submitted+ jQuery.event.add( this, "click._submit keypress._submit", function( e ) {+ // Node name check avoids a VML-related crash in IE (#9807)+ var elem = e.target,+ form = jQuery.nodeName( elem, "input" ) || jQuery.nodeName( elem, "button" ) ? elem.form : undefined;+ if ( form && !jQuery._data( form, "submitBubbles" ) ) {+ jQuery.event.add( form, "submit._submit", function( event ) {+ event._submit_bubble = true;+ });+ jQuery._data( form, "submitBubbles", true );+ }+ });+ // return undefined since we don't need an event listener+ },++ postDispatch: function( event ) {+ // If form was submitted by the user, bubble the event up the tree+ if ( event._submit_bubble ) {+ delete event._submit_bubble;+ if ( this.parentNode && !event.isTrigger ) {+ jQuery.event.simulate( "submit", this.parentNode, event, true );+ }+ }+ },++ teardown: function() {+ // Only need this for delegated form submit events+ if ( jQuery.nodeName( this, "form" ) ) {+ return false;+ }++ // Remove delegated handlers; cleanData eventually reaps submit handlers attached above+ jQuery.event.remove( this, "._submit" );+ }+ };+}++// IE change delegation and checkbox/radio fix+if ( !support.changeBubbles ) {++ jQuery.event.special.change = {++ setup: function() {++ if ( rformElems.test( this.nodeName ) ) {+ // IE doesn't fire change on a check/radio until blur; trigger it on click+ // after a propertychange. Eat the blur-change in special.change.handle.+ // This still fires onchange a second time for check/radio after blur.+ if ( this.type === "checkbox" || this.type === "radio" ) {+ jQuery.event.add( this, "propertychange._change", function( event ) {+ if ( event.originalEvent.propertyName === "checked" ) {+ this._just_changed = true;+ }+ });+ jQuery.event.add( this, "click._change", function( event ) {+ if ( this._just_changed && !event.isTrigger ) {+ this._just_changed = false;+ }+ // Allow triggered, simulated change events (#11500)+ jQuery.event.simulate( "change", this, event, true );+ });+ }+ return false;+ }+ // Delegated event; lazy-add a change handler on descendant inputs+ jQuery.event.add( this, "beforeactivate._change", function( e ) {+ var elem = e.target;++ if ( rformElems.test( elem.nodeName ) && !jQuery._data( elem, "changeBubbles" ) ) {+ jQuery.event.add( elem, "change._change", function( event ) {+ if ( this.parentNode && !event.isSimulated && !event.isTrigger ) {+ jQuery.event.simulate( "change", this.parentNode, event, true );+ }+ });+ jQuery._data( elem, "changeBubbles", true );+ }+ });+ },++ handle: function( event ) {+ var elem = event.target;++ // Swallow native change events from checkbox/radio, we already triggered them above+ if ( this !== elem || event.isSimulated || event.isTrigger || (elem.type !== "radio" && elem.type !== "checkbox") ) {+ return event.handleObj.handler.apply( this, arguments );+ }+ },++ teardown: function() {+ jQuery.event.remove( this, "._change" );++ return !rformElems.test( this.nodeName );+ }+ };+}++// Create "bubbling" focus and blur events+if ( !support.focusinBubbles ) {+ jQuery.each({ focus: "focusin", blur: "focusout" }, function( orig, fix ) {++ // Attach a single capturing handler on the document while someone wants focusin/focusout+ var handler = function( event ) {+ jQuery.event.simulate( fix, event.target, jQuery.event.fix( event ), true );+ };++ jQuery.event.special[ fix ] = {+ setup: function() {+ var doc = this.ownerDocument || this,+ attaches = jQuery._data( doc, fix );++ if ( !attaches ) {+ doc.addEventListener( orig, handler, true );+ }+ jQuery._data( doc, fix, ( attaches || 0 ) + 1 );+ },+ teardown: function() {+ var doc = this.ownerDocument || this,+ attaches = jQuery._data( doc, fix ) - 1;++ if ( !attaches ) {+ doc.removeEventListener( orig, handler, true );+ jQuery._removeData( doc, fix );+ } else {+ jQuery._data( doc, fix, attaches );+ }+ }+ };+ });+}++jQuery.fn.extend({++ on: function( types, selector, data, fn, /*INTERNAL*/ one ) {+ var type, origFn;++ // Types can be a map of types/handlers+ if ( typeof types === "object" ) {+ // ( types-Object, selector, data )+ if ( typeof selector !== "string" ) {+ // ( types-Object, data )+ data = data || selector;+ selector = undefined;+ }+ for ( type in types ) {+ this.on( type, selector, data, types[ type ], one );+ }+ return this;+ }++ if ( data == null && fn == null ) {+ // ( types, fn )+ fn = selector;+ data = selector = undefined;+ } else if ( fn == null ) {+ if ( typeof selector === "string" ) {+ // ( types, selector, fn )+ fn = data;+ data = undefined;+ } else {+ // ( types, data, fn )+ fn = data;+ data = selector;+ selector = undefined;+ }+ }+ if ( fn === false ) {+ fn = returnFalse;+ } else if ( !fn ) {+ return this;+ }++ if ( one === 1 ) {+ origFn = fn;+ fn = function( event ) {+ // Can use an empty set, since event contains the info+ jQuery().off( event );+ return origFn.apply( this, arguments );+ };+ // Use same guid so caller can remove using origFn+ fn.guid = origFn.guid || ( origFn.guid = jQuery.guid++ );+ }+ return this.each( function() {+ jQuery.event.add( this, types, fn, data, selector );+ });+ },+ one: function( types, selector, data, fn ) {+ return this.on( types, selector, data, fn, 1 );+ },+ off: function( types, selector, fn ) {+ var handleObj, type;+ if ( types && types.preventDefault && types.handleObj ) {+ // ( event ) dispatched jQuery.Event+ handleObj = types.handleObj;+ jQuery( types.delegateTarget ).off(+ handleObj.namespace ? handleObj.origType + "." + handleObj.namespace : handleObj.origType,+ handleObj.selector,+ handleObj.handler+ );+ return this;+ }+ if ( typeof types === "object" ) {+ // ( types-object [, selector] )+ for ( type in types ) {+ this.off( type, selector, types[ type ] );+ }+ return this;+ }+ if ( selector === false || typeof selector === "function" ) {+ // ( types [, fn] )+ fn = selector;+ selector = undefined;+ }+ if ( fn === false ) {+ fn = returnFalse;+ }+ return this.each(function() {+ jQuery.event.remove( this, types, fn, selector );+ });+ },++ trigger: function( type, data ) {+ return this.each(function() {+ jQuery.event.trigger( type, data, this );+ });+ },+ triggerHandler: function( type, data ) {+ var elem = this[0];+ if ( elem ) {+ return jQuery.event.trigger( type, data, elem, true );+ }+ }+});+++function createSafeFragment( document ) {+ var list = nodeNames.split( "|" ),+ safeFrag = document.createDocumentFragment();++ if ( safeFrag.createElement ) {+ while ( list.length ) {+ safeFrag.createElement(+ list.pop()+ );+ }+ }+ return safeFrag;+}++var nodeNames = "abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|" ++ "header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",+ rinlinejQuery = / jQuery\d+="(?:null|\d+)"/g,+ rnoshimcache = new RegExp("<(?:" + nodeNames + ")[\\s/>]", "i"),+ rleadingWhitespace = /^\s+/,+ rxhtmlTag = /<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,+ rtagName = /<([\w:]+)/,+ rtbody = /<tbody/i,+ rhtml = /<|&#?\w+;/,+ rnoInnerhtml = /<(?:script|style|link)/i,+ // checked="checked" or checked+ rchecked = /checked\s*(?:[^=]|=\s*.checked.)/i,+ rscriptType = /^$|\/(?:java|ecma)script/i,+ rscriptTypeMasked = /^true\/(.*)/,+ rcleanScript = /^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,++ // We have to close these tags to support XHTML (#13200)+ wrapMap = {+ option: [ 1, "<select multiple='multiple'>", "</select>" ],+ legend: [ 1, "<fieldset>", "</fieldset>" ],+ area: [ 1, "<map>", "</map>" ],+ param: [ 1, "<object>", "</object>" ],+ thead: [ 1, "<table>", "</table>" ],+ tr: [ 2, "<table><tbody>", "</tbody></table>" ],+ col: [ 2, "<table><tbody></tbody><colgroup>", "</colgroup></table>" ],+ td: [ 3, "<table><tbody><tr>", "</tr></tbody></table>" ],++ // IE6-8 can't serialize link, script, style, or any html5 (NoScope) tags,+ // unless wrapped in a div with non-breaking characters in front of it.+ _default: support.htmlSerialize ? [ 0, "", "" ] : [ 1, "X<div>", "</div>" ]+ },+ safeFragment = createSafeFragment( document ),+ fragmentDiv = safeFragment.appendChild( document.createElement("div") );++wrapMap.optgroup = wrapMap.option;+wrapMap.tbody = wrapMap.tfoot = wrapMap.colgroup = wrapMap.caption = wrapMap.thead;+wrapMap.th = wrapMap.td;++function getAll( context, tag ) {+ var elems, elem,+ i = 0,+ found = typeof context.getElementsByTagName !== strundefined ? context.getElementsByTagName( tag || "*" ) :+ typeof context.querySelectorAll !== strundefined ? context.querySelectorAll( tag || "*" ) :+ undefined;++ if ( !found ) {+ for ( found = [], elems = context.childNodes || context; (elem = elems[i]) != null; i++ ) {+ if ( !tag || jQuery.nodeName( elem, tag ) ) {+ found.push( elem );+ } else {+ jQuery.merge( found, getAll( elem, tag ) );+ }+ }+ }++ return tag === undefined || tag && jQuery.nodeName( context, tag ) ?+ jQuery.merge( [ context ], found ) :+ found;+}++// Used in buildFragment, fixes the defaultChecked property+function fixDefaultChecked( elem ) {+ if ( rcheckableType.test( elem.type ) ) {+ elem.defaultChecked = elem.checked;+ }+}++// Support: IE<8+// Manipulating tables requires a tbody+function manipulationTarget( elem, content ) {+ return jQuery.nodeName( elem, "table" ) &&+ jQuery.nodeName( content.nodeType !== 11 ? content : content.firstChild, "tr" ) ?++ elem.getElementsByTagName("tbody")[0] ||+ elem.appendChild( elem.ownerDocument.createElement("tbody") ) :+ elem;+}++// Replace/restore the type attribute of script elements for safe DOM manipulation+function disableScript( elem ) {+ elem.type = (jQuery.find.attr( elem, "type" ) !== null) + "/" + elem.type;+ return elem;+}+function restoreScript( elem ) {+ var match = rscriptTypeMasked.exec( elem.type );+ if ( match ) {+ elem.type = match[1];+ } else {+ elem.removeAttribute("type");+ }+ return elem;+}++// Mark scripts as having already been evaluated+function setGlobalEval( elems, refElements ) {+ var elem,+ i = 0;+ for ( ; (elem = elems[i]) != null; i++ ) {+ jQuery._data( elem, "globalEval", !refElements || jQuery._data( refElements[i], "globalEval" ) );+ }+}++function cloneCopyEvent( src, dest ) {++ if ( dest.nodeType !== 1 || !jQuery.hasData( src ) ) {+ return;+ }++ var type, i, l,+ oldData = jQuery._data( src ),+ curData = jQuery._data( dest, oldData ),+ events = oldData.events;++ if ( events ) {+ delete curData.handle;+ curData.events = {};++ for ( type in events ) {+ for ( i = 0, l = events[ type ].length; i < l; i++ ) {+ jQuery.event.add( dest, type, events[ type ][ i ] );+ }+ }+ }++ // make the cloned public data object a copy from the original+ if ( curData.data ) {+ curData.data = jQuery.extend( {}, curData.data );+ }+}++function fixCloneNodeIssues( src, dest ) {+ var nodeName, e, data;++ // We do not need to do anything for non-Elements+ if ( dest.nodeType !== 1 ) {+ return;+ }++ nodeName = dest.nodeName.toLowerCase();++ // IE6-8 copies events bound via attachEvent when using cloneNode.+ if ( !support.noCloneEvent && dest[ jQuery.expando ] ) {+ data = jQuery._data( dest );++ for ( e in data.events ) {+ jQuery.removeEvent( dest, e, data.handle );+ }++ // Event data gets referenced instead of copied if the expando gets copied too+ dest.removeAttribute( jQuery.expando );+ }++ // IE blanks contents when cloning scripts, and tries to evaluate newly-set text+ if ( nodeName === "script" && dest.text !== src.text ) {+ disableScript( dest ).text = src.text;+ restoreScript( dest );++ // IE6-10 improperly clones children of object elements using classid.+ // IE10 throws NoModificationAllowedError if parent is null, #12132.+ } else if ( nodeName === "object" ) {+ if ( dest.parentNode ) {+ dest.outerHTML = src.outerHTML;+ }++ // This path appears unavoidable for IE9. When cloning an object+ // element in IE9, the outerHTML strategy above is not sufficient.+ // If the src has innerHTML and the destination does not,+ // copy the src.innerHTML into the dest.innerHTML. #10324+ if ( support.html5Clone && ( src.innerHTML && !jQuery.trim(dest.innerHTML) ) ) {+ dest.innerHTML = src.innerHTML;+ }++ } else if ( nodeName === "input" && rcheckableType.test( src.type ) ) {+ // IE6-8 fails to persist the checked state of a cloned checkbox+ // or radio button. Worse, IE6-7 fail to give the cloned element+ // a checked appearance if the defaultChecked value isn't also set++ dest.defaultChecked = dest.checked = src.checked;++ // IE6-7 get confused and end up setting the value of a cloned+ // checkbox/radio button to an empty string instead of "on"+ if ( dest.value !== src.value ) {+ dest.value = src.value;+ }++ // IE6-8 fails to return the selected option to the default selected+ // state when cloning options+ } else if ( nodeName === "option" ) {+ dest.defaultSelected = dest.selected = src.defaultSelected;++ // IE6-8 fails to set the defaultValue to the correct value when+ // cloning other types of input fields+ } else if ( nodeName === "input" || nodeName === "textarea" ) {+ dest.defaultValue = src.defaultValue;+ }+}++jQuery.extend({+ clone: function( elem, dataAndEvents, deepDataAndEvents ) {+ var destElements, node, clone, i, srcElements,+ inPage = jQuery.contains( elem.ownerDocument, elem );++ if ( support.html5Clone || jQuery.isXMLDoc(elem) || !rnoshimcache.test( "<" + elem.nodeName + ">" ) ) {+ clone = elem.cloneNode( true );++ // IE<=8 does not properly clone detached, unknown element nodes+ } else {+ fragmentDiv.innerHTML = elem.outerHTML;+ fragmentDiv.removeChild( clone = fragmentDiv.firstChild );+ }++ if ( (!support.noCloneEvent || !support.noCloneChecked) &&+ (elem.nodeType === 1 || elem.nodeType === 11) && !jQuery.isXMLDoc(elem) ) {++ // We eschew Sizzle here for performance reasons: http://jsperf.com/getall-vs-sizzle/2+ destElements = getAll( clone );+ srcElements = getAll( elem );++ // Fix all IE cloning issues+ for ( i = 0; (node = srcElements[i]) != null; ++i ) {+ // Ensure that the destination node is not null; Fixes #9587+ if ( destElements[i] ) {+ fixCloneNodeIssues( node, destElements[i] );+ }+ }+ }++ // Copy the events from the original to the clone+ if ( dataAndEvents ) {+ if ( deepDataAndEvents ) {+ srcElements = srcElements || getAll( elem );+ destElements = destElements || getAll( clone );++ for ( i = 0; (node = srcElements[i]) != null; i++ ) {+ cloneCopyEvent( node, destElements[i] );+ }+ } else {+ cloneCopyEvent( elem, clone );+ }+ }++ // Preserve script evaluation history+ destElements = getAll( clone, "script" );+ if ( destElements.length > 0 ) {+ setGlobalEval( destElements, !inPage && getAll( elem, "script" ) );+ }++ destElements = srcElements = node = null;++ // Return the cloned set+ return clone;+ },++ buildFragment: function( elems, context, scripts, selection ) {+ var j, elem, contains,+ tmp, tag, tbody, wrap,+ l = elems.length,++ // Ensure a safe fragment+ safe = createSafeFragment( context ),++ nodes = [],+ i = 0;++ for ( ; i < l; i++ ) {+ elem = elems[ i ];++ if ( elem || elem === 0 ) {++ // Add nodes directly+ if ( jQuery.type( elem ) === "object" ) {+ jQuery.merge( nodes, elem.nodeType ? [ elem ] : elem );++ // Convert non-html into a text node+ } else if ( !rhtml.test( elem ) ) {+ nodes.push( context.createTextNode( elem ) );++ // Convert html into DOM nodes+ } else {+ tmp = tmp || safe.appendChild( context.createElement("div") );++ // Deserialize a standard representation+ tag = (rtagName.exec( elem ) || [ "", "" ])[ 1 ].toLowerCase();+ wrap = wrapMap[ tag ] || wrapMap._default;++ tmp.innerHTML = wrap[1] + elem.replace( rxhtmlTag, "<$1></$2>" ) + wrap[2];++ // Descend through wrappers to the right content+ j = wrap[0];+ while ( j-- ) {+ tmp = tmp.lastChild;+ }++ // Manually add leading whitespace removed by IE+ if ( !support.leadingWhitespace && rleadingWhitespace.test( elem ) ) {+ nodes.push( context.createTextNode( rleadingWhitespace.exec( elem )[0] ) );+ }++ // Remove IE's autoinserted <tbody> from table fragments+ if ( !support.tbody ) {++ // String was a <table>, *may* have spurious <tbody>+ elem = tag === "table" && !rtbody.test( elem ) ?+ tmp.firstChild :++ // String was a bare <thead> or <tfoot>+ wrap[1] === "<table>" && !rtbody.test( elem ) ?+ tmp :+ 0;++ j = elem && elem.childNodes.length;+ while ( j-- ) {+ if ( jQuery.nodeName( (tbody = elem.childNodes[j]), "tbody" ) && !tbody.childNodes.length ) {+ elem.removeChild( tbody );+ }+ }+ }++ jQuery.merge( nodes, tmp.childNodes );++ // Fix #12392 for WebKit and IE > 9+ tmp.textContent = "";++ // Fix #12392 for oldIE+ while ( tmp.firstChild ) {+ tmp.removeChild( tmp.firstChild );+ }++ // Remember the top-level container for proper cleanup+ tmp = safe.lastChild;+ }+ }+ }++ // Fix #11356: Clear elements from fragment+ if ( tmp ) {+ safe.removeChild( tmp );+ }++ // Reset defaultChecked for any radios and checkboxes+ // about to be appended to the DOM in IE 6/7 (#8060)+ if ( !support.appendChecked ) {+ jQuery.grep( getAll( nodes, "input" ), fixDefaultChecked );+ }++ i = 0;+ while ( (elem = nodes[ i++ ]) ) {++ // #4087 - If origin and destination elements are the same, and this is+ // that element, do not do anything+ if ( selection && jQuery.inArray( elem, selection ) !== -1 ) {+ continue;+ }++ contains = jQuery.contains( elem.ownerDocument, elem );++ // Append to fragment+ tmp = getAll( safe.appendChild( elem ), "script" );++ // Preserve script evaluation history+ if ( contains ) {+ setGlobalEval( tmp );+ }++ // Capture executables+ if ( scripts ) {+ j = 0;+ while ( (elem = tmp[ j++ ]) ) {+ if ( rscriptType.test( elem.type || "" ) ) {+ scripts.push( elem );+ }+ }+ }+ }++ tmp = null;++ return safe;+ },++ cleanData: function( elems, /* internal */ acceptData ) {+ var elem, type, id, data,+ i = 0,+ internalKey = jQuery.expando,+ cache = jQuery.cache,+ deleteExpando = support.deleteExpando,+ special = jQuery.event.special;++ for ( ; (elem = elems[i]) != null; i++ ) {+ if ( acceptData || jQuery.acceptData( elem ) ) {++ id = elem[ internalKey ];+ data = id && cache[ id ];++ if ( data ) {+ if ( data.events ) {+ for ( type in data.events ) {+ if ( special[ type ] ) {+ jQuery.event.remove( elem, type );++ // This is a shortcut to avoid jQuery.event.remove's overhead+ } else {+ jQuery.removeEvent( elem, type, data.handle );+ }+ }+ }++ // Remove cache only if it was not already removed by jQuery.event.remove+ if ( cache[ id ] ) {++ delete cache[ id ];++ // IE does not allow us to delete expando properties from nodes,+ // nor does it have a removeAttribute function on Document nodes;+ // we must handle all of these cases+ if ( deleteExpando ) {+ delete elem[ internalKey ];++ } else if ( typeof elem.removeAttribute !== strundefined ) {+ elem.removeAttribute( internalKey );++ } else {+ elem[ internalKey ] = null;+ }++ deletedIds.push( id );+ }+ }+ }+ }+ }+});++jQuery.fn.extend({+ text: function( value ) {+ return access( this, function( value ) {+ return value === undefined ?+ jQuery.text( this ) :+ this.empty().append( ( this[0] && this[0].ownerDocument || document ).createTextNode( value ) );+ }, null, value, arguments.length );+ },++ append: function() {+ return this.domManip( arguments, function( elem ) {+ if ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) {+ var target = manipulationTarget( this, elem );+ target.appendChild( elem );+ }+ });+ },++ prepend: function() {+ return this.domManip( arguments, function( elem ) {+ if ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) {+ var target = manipulationTarget( this, elem );+ target.insertBefore( elem, target.firstChild );+ }+ });+ },++ before: function() {+ return this.domManip( arguments, function( elem ) {+ if ( this.parentNode ) {+ this.parentNode.insertBefore( elem, this );+ }+ });+ },++ after: function() {+ return this.domManip( arguments, function( elem ) {+ if ( this.parentNode ) {+ this.parentNode.insertBefore( elem, this.nextSibling );+ }+ });+ },++ remove: function( selector, keepData /* Internal Use Only */ ) {+ var elem,+ elems = selector ? jQuery.filter( selector, this ) : this,+ i = 0;++ for ( ; (elem = elems[i]) != null; i++ ) {++ if ( !keepData && elem.nodeType === 1 ) {+ jQuery.cleanData( getAll( elem ) );+ }++ if ( elem.parentNode ) {+ if ( keepData && jQuery.contains( elem.ownerDocument, elem ) ) {+ setGlobalEval( getAll( elem, "script" ) );+ }+ elem.parentNode.removeChild( elem );+ }+ }++ return this;+ },++ empty: function() {+ var elem,+ i = 0;++ for ( ; (elem = this[i]) != null; i++ ) {+ // Remove element nodes and prevent memory leaks+ if ( elem.nodeType === 1 ) {+ jQuery.cleanData( getAll( elem, false ) );+ }++ // Remove any remaining nodes+ while ( elem.firstChild ) {+ elem.removeChild( elem.firstChild );+ }++ // If this is a select, ensure that it displays empty (#12336)+ // Support: IE<9+ if ( elem.options && jQuery.nodeName( elem, "select" ) ) {+ elem.options.length = 0;+ }+ }++ return this;+ },++ clone: function( dataAndEvents, deepDataAndEvents ) {+ dataAndEvents = dataAndEvents == null ? false : dataAndEvents;+ deepDataAndEvents = deepDataAndEvents == null ? dataAndEvents : deepDataAndEvents;++ return this.map(function() {+ return jQuery.clone( this, dataAndEvents, deepDataAndEvents );+ });+ },++ html: function( value ) {+ return access( this, function( value ) {+ var elem = this[ 0 ] || {},+ i = 0,+ l = this.length;++ if ( value === undefined ) {+ return elem.nodeType === 1 ?+ elem.innerHTML.replace( rinlinejQuery, "" ) :+ undefined;+ }++ // See if we can take a shortcut and just use innerHTML+ if ( typeof value === "string" && !rnoInnerhtml.test( value ) &&+ ( support.htmlSerialize || !rnoshimcache.test( value ) ) &&+ ( support.leadingWhitespace || !rleadingWhitespace.test( value ) ) &&+ !wrapMap[ (rtagName.exec( value ) || [ "", "" ])[ 1 ].toLowerCase() ] ) {++ value = value.replace( rxhtmlTag, "<$1></$2>" );++ try {+ for (; i < l; i++ ) {+ // Remove element nodes and prevent memory leaks+ elem = this[i] || {};+ if ( elem.nodeType === 1 ) {+ jQuery.cleanData( getAll( elem, false ) );+ elem.innerHTML = value;+ }+ }++ elem = 0;++ // If using innerHTML throws an exception, use the fallback method+ } catch(e) {}+ }++ if ( elem ) {+ this.empty().append( value );+ }+ }, null, value, arguments.length );+ },++ replaceWith: function() {+ var arg = arguments[ 0 ];++ // Make the changes, replacing each context element with the new content+ this.domManip( arguments, function( elem ) {+ arg = this.parentNode;++ jQuery.cleanData( getAll( this ) );++ if ( arg ) {+ arg.replaceChild( elem, this );+ }+ });++ // Force removal if there was no new content (e.g., from empty arguments)+ return arg && (arg.length || arg.nodeType) ? this : this.remove();+ },++ detach: function( selector ) {+ return this.remove( selector, true );+ },++ domManip: function( args, callback ) {++ // Flatten any nested arrays+ args = concat.apply( [], args );++ var first, node, hasScripts,+ scripts, doc, fragment,+ i = 0,+ l = this.length,+ set = this,+ iNoClone = l - 1,+ value = args[0],+ isFunction = jQuery.isFunction( value );++ // We can't cloneNode fragments that contain checked, in WebKit+ if ( isFunction ||+ ( l > 1 && typeof value === "string" &&+ !support.checkClone && rchecked.test( value ) ) ) {+ return this.each(function( index ) {+ var self = set.eq( index );+ if ( isFunction ) {+ args[0] = value.call( this, index, self.html() );+ }+ self.domManip( args, callback );+ });+ }++ if ( l ) {+ fragment = jQuery.buildFragment( args, this[ 0 ].ownerDocument, false, this );+ first = fragment.firstChild;++ if ( fragment.childNodes.length === 1 ) {+ fragment = first;+ }++ if ( first ) {+ scripts = jQuery.map( getAll( fragment, "script" ), disableScript );+ hasScripts = scripts.length;++ // Use the original fragment for the last item instead of the first because it can end up+ // being emptied incorrectly in certain situations (#8070).+ for ( ; i < l; i++ ) {+ node = fragment;++ if ( i !== iNoClone ) {+ node = jQuery.clone( node, true, true );++ // Keep references to cloned scripts for later restoration+ if ( hasScripts ) {+ jQuery.merge( scripts, getAll( node, "script" ) );+ }+ }++ callback.call( this[i], node, i );+ }++ if ( hasScripts ) {+ doc = scripts[ scripts.length - 1 ].ownerDocument;++ // Reenable scripts+ jQuery.map( scripts, restoreScript );++ // Evaluate executable scripts on first document insertion+ for ( i = 0; i < hasScripts; i++ ) {+ node = scripts[ i ];+ if ( rscriptType.test( node.type || "" ) &&+ !jQuery._data( node, "globalEval" ) && jQuery.contains( doc, node ) ) {++ if ( node.src ) {+ // Optional AJAX dependency, but won't run scripts if not present+ if ( jQuery._evalUrl ) {+ jQuery._evalUrl( node.src );+ }+ } else {+ jQuery.globalEval( ( node.text || node.textContent || node.innerHTML || "" ).replace( rcleanScript, "" ) );+ }+ }+ }+ }++ // Fix #11809: Avoid leaking memory+ fragment = first = null;+ }+ }++ return this;+ }+});++jQuery.each({+ appendTo: "append",+ prependTo: "prepend",+ insertBefore: "before",+ insertAfter: "after",+ replaceAll: "replaceWith"+}, function( name, original ) {+ jQuery.fn[ name ] = function( selector ) {+ var elems,+ i = 0,+ ret = [],+ insert = jQuery( selector ),+ last = insert.length - 1;++ for ( ; i <= last; i++ ) {+ elems = i === last ? this : this.clone(true);+ jQuery( insert[i] )[ original ]( elems );++ // Modern browsers can apply jQuery collections as arrays, but oldIE needs a .get()+ push.apply( ret, elems.get() );+ }++ return this.pushStack( ret );+ };+});+++var iframe,+ elemdisplay = {};++/**+ * Retrieve the actual display of a element+ * @param {String} name nodeName of the element+ * @param {Object} doc Document object+ */+// Called only from within defaultDisplay+function actualDisplay( name, doc ) {+ var style,+ elem = jQuery( doc.createElement( name ) ).appendTo( doc.body ),++ // getDefaultComputedStyle might be reliably used only on attached element+ display = window.getDefaultComputedStyle && ( style = window.getDefaultComputedStyle( elem[ 0 ] ) ) ?++ // Use of this method is a temporary fix (more like optmization) until something better comes along,+ // since it was removed from specification and supported only in FF+ style.display : jQuery.css( elem[ 0 ], "display" );++ // We don't have any data stored on the element,+ // so use "detach" method as fast way to get rid of the element+ elem.detach();++ return display;+}++/**+ * Try to determine the default display value of an element+ * @param {String} nodeName+ */+function defaultDisplay( nodeName ) {+ var doc = document,+ display = elemdisplay[ nodeName ];++ if ( !display ) {+ display = actualDisplay( nodeName, doc );++ // If the simple way fails, read from inside an iframe+ if ( display === "none" || !display ) {++ // Use the already-created iframe if possible+ iframe = (iframe || jQuery( "<iframe frameborder='0' width='0' height='0'/>" )).appendTo( doc.documentElement );++ // Always write a new HTML skeleton so Webkit and Firefox don't choke on reuse+ doc = ( iframe[ 0 ].contentWindow || iframe[ 0 ].contentDocument ).document;++ // Support: IE+ doc.write();+ doc.close();++ display = actualDisplay( nodeName, doc );+ iframe.detach();+ }++ // Store the correct default display+ elemdisplay[ nodeName ] = display;+ }++ return display;+}+++(function() {+ var shrinkWrapBlocksVal;++ support.shrinkWrapBlocks = function() {+ if ( shrinkWrapBlocksVal != null ) {+ return shrinkWrapBlocksVal;+ }++ // Will be changed later if needed.+ shrinkWrapBlocksVal = false;++ // Minified: var b,c,d+ var div, body, container;++ body = document.getElementsByTagName( "body" )[ 0 ];+ if ( !body || !body.style ) {+ // Test fired too early or in an unsupported environment, exit.+ return;+ }++ // Setup+ div = document.createElement( "div" );+ container = document.createElement( "div" );+ container.style.cssText = "position:absolute;border:0;width:0;height:0;top:0;left:-9999px";+ body.appendChild( container ).appendChild( div );++ // Support: IE6+ // Check if elements with layout shrink-wrap their children+ if ( typeof div.style.zoom !== strundefined ) {+ // Reset CSS: box-sizing; display; margin; border+ div.style.cssText =+ // Support: Firefox<29, Android 2.3+ // Vendor-prefix box-sizing+ "-webkit-box-sizing:content-box;-moz-box-sizing:content-box;" ++ "box-sizing:content-box;display:block;margin:0;border:0;" ++ "padding:1px;width:1px;zoom:1";+ div.appendChild( document.createElement( "div" ) ).style.width = "5px";+ shrinkWrapBlocksVal = div.offsetWidth !== 3;+ }++ body.removeChild( container );++ return shrinkWrapBlocksVal;+ };++})();+var rmargin = (/^margin/);++var rnumnonpx = new RegExp( "^(" + pnum + ")(?!px)[a-z%]+$", "i" );++++var getStyles, curCSS,+ rposition = /^(top|right|bottom|left)$/;++if ( window.getComputedStyle ) {+ getStyles = function( elem ) {+ return elem.ownerDocument.defaultView.getComputedStyle( elem, null );+ };++ curCSS = function( elem, name, computed ) {+ var width, minWidth, maxWidth, ret,+ style = elem.style;++ computed = computed || getStyles( elem );++ // getPropertyValue is only needed for .css('filter') in IE9, see #12537+ ret = computed ? computed.getPropertyValue( name ) || computed[ name ] : undefined;++ if ( computed ) {++ if ( ret === "" && !jQuery.contains( elem.ownerDocument, elem ) ) {+ ret = jQuery.style( elem, name );+ }++ // A tribute to the "awesome hack by Dean Edwards"+ // Chrome < 17 and Safari 5.0 uses "computed value" instead of "used value" for margin-right+ // Safari 5.1.7 (at least) returns percentage for a larger set of values, but width seems to be reliably pixels+ // this is against the CSSOM draft spec: http://dev.w3.org/csswg/cssom/#resolved-values+ if ( rnumnonpx.test( ret ) && rmargin.test( name ) ) {++ // Remember the original values+ width = style.width;+ minWidth = style.minWidth;+ maxWidth = style.maxWidth;++ // Put in the new values to get a computed value out+ style.minWidth = style.maxWidth = style.width = ret;+ ret = computed.width;++ // Revert the changed values+ style.width = width;+ style.minWidth = minWidth;+ style.maxWidth = maxWidth;+ }+ }++ // Support: IE+ // IE returns zIndex value as an integer.+ return ret === undefined ?+ ret :+ ret + "";+ };+} else if ( document.documentElement.currentStyle ) {+ getStyles = function( elem ) {+ return elem.currentStyle;+ };++ curCSS = function( elem, name, computed ) {+ var left, rs, rsLeft, ret,+ style = elem.style;++ computed = computed || getStyles( elem );+ ret = computed ? computed[ name ] : undefined;++ // Avoid setting ret to empty string here+ // so we don't default to auto+ if ( ret == null && style && style[ name ] ) {+ ret = style[ name ];+ }++ // From the awesome hack by Dean Edwards+ // http://erik.eae.net/archives/2007/07/27/18.54.15/#comment-102291++ // If we're not dealing with a regular pixel number+ // but a number that has a weird ending, we need to convert it to pixels+ // but not position css attributes, as those are proportional to the parent element instead+ // and we can't measure the parent instead because it might trigger a "stacking dolls" problem+ if ( rnumnonpx.test( ret ) && !rposition.test( name ) ) {++ // Remember the original values+ left = style.left;+ rs = elem.runtimeStyle;+ rsLeft = rs && rs.left;++ // Put in the new values to get a computed value out+ if ( rsLeft ) {+ rs.left = elem.currentStyle.left;+ }+ style.left = name === "fontSize" ? "1em" : ret;+ ret = style.pixelLeft + "px";++ // Revert the changed values+ style.left = left;+ if ( rsLeft ) {+ rs.left = rsLeft;+ }+ }++ // Support: IE+ // IE returns zIndex value as an integer.+ return ret === undefined ?+ ret :+ ret + "" || "auto";+ };+}+++++function addGetHookIf( conditionFn, hookFn ) {+ // Define the hook, we'll check on the first run if it's really needed.+ return {+ get: function() {+ var condition = conditionFn();++ if ( condition == null ) {+ // The test was not ready at this point; screw the hook this time+ // but check again when needed next time.+ return;+ }++ if ( condition ) {+ // Hook not needed (or it's not possible to use it due to missing dependency),+ // remove it.+ // Since there are no other hooks for marginRight, remove the whole object.+ delete this.get;+ return;+ }++ // Hook needed; redefine it so that the support test is not executed again.++ return (this.get = hookFn).apply( this, arguments );+ }+ };+}+++(function() {+ // Minified: var b,c,d,e,f,g, h,i+ var div, style, a, pixelPositionVal, boxSizingReliableVal,+ reliableHiddenOffsetsVal, reliableMarginRightVal;++ // Setup+ div = document.createElement( "div" );+ div.innerHTML = " <link/><table></table><a href='/a'>a</a><input type='checkbox'/>";+ a = div.getElementsByTagName( "a" )[ 0 ];+ style = a && a.style;++ // Finish early in limited (non-browser) environments+ if ( !style ) {+ return;+ }++ style.cssText = "float:left;opacity:.5";++ // Support: IE<9+ // Make sure that element opacity exists (as opposed to filter)+ support.opacity = style.opacity === "0.5";++ // Verify style float existence+ // (IE uses styleFloat instead of cssFloat)+ support.cssFloat = !!style.cssFloat;++ div.style.backgroundClip = "content-box";+ div.cloneNode( true ).style.backgroundClip = "";+ support.clearCloneStyle = div.style.backgroundClip === "content-box";++ // Support: Firefox<29, Android 2.3+ // Vendor-prefix box-sizing+ support.boxSizing = style.boxSizing === "" || style.MozBoxSizing === "" ||+ style.WebkitBoxSizing === "";++ jQuery.extend(support, {+ reliableHiddenOffsets: function() {+ if ( reliableHiddenOffsetsVal == null ) {+ computeStyleTests();+ }+ return reliableHiddenOffsetsVal;+ },++ boxSizingReliable: function() {+ if ( boxSizingReliableVal == null ) {+ computeStyleTests();+ }+ return boxSizingReliableVal;+ },++ pixelPosition: function() {+ if ( pixelPositionVal == null ) {+ computeStyleTests();+ }+ return pixelPositionVal;+ },++ // Support: Android 2.3+ reliableMarginRight: function() {+ if ( reliableMarginRightVal == null ) {+ computeStyleTests();+ }+ return reliableMarginRightVal;+ }+ });++ function computeStyleTests() {+ // Minified: var b,c,d,j+ var div, body, container, contents;++ body = document.getElementsByTagName( "body" )[ 0 ];+ if ( !body || !body.style ) {+ // Test fired too early or in an unsupported environment, exit.+ return;+ }++ // Setup+ div = document.createElement( "div" );+ container = document.createElement( "div" );+ container.style.cssText = "position:absolute;border:0;width:0;height:0;top:0;left:-9999px";+ body.appendChild( container ).appendChild( div );++ div.style.cssText =+ // Support: Firefox<29, Android 2.3+ // Vendor-prefix box-sizing+ "-webkit-box-sizing:border-box;-moz-box-sizing:border-box;" ++ "box-sizing:border-box;display:block;margin-top:1%;top:1%;" ++ "border:1px;padding:1px;width:4px;position:absolute";++ // Support: IE<9+ // Assume reasonable values in the absence of getComputedStyle+ pixelPositionVal = boxSizingReliableVal = false;+ reliableMarginRightVal = true;++ // Check for getComputedStyle so that this code is not run in IE<9.+ if ( window.getComputedStyle ) {+ pixelPositionVal = ( window.getComputedStyle( div, null ) || {} ).top !== "1%";+ boxSizingReliableVal =+ ( window.getComputedStyle( div, null ) || { width: "4px" } ).width === "4px";++ // Support: Android 2.3+ // Div with explicit width and no margin-right incorrectly+ // gets computed margin-right based on width of container (#3333)+ // WebKit Bug 13343 - getComputedStyle returns wrong value for margin-right+ contents = div.appendChild( document.createElement( "div" ) );++ // Reset CSS: box-sizing; display; margin; border; padding+ contents.style.cssText = div.style.cssText =+ // Support: Firefox<29, Android 2.3+ // Vendor-prefix box-sizing+ "-webkit-box-sizing:content-box;-moz-box-sizing:content-box;" ++ "box-sizing:content-box;display:block;margin:0;border:0;padding:0";+ contents.style.marginRight = contents.style.width = "0";+ div.style.width = "1px";++ reliableMarginRightVal =+ !parseFloat( ( window.getComputedStyle( contents, null ) || {} ).marginRight );+ }++ // Support: IE8+ // Check if table cells still have offsetWidth/Height when they are set+ // to display:none and there are still other visible table cells in a+ // table row; if so, offsetWidth/Height are not reliable for use when+ // determining if an element has been hidden directly using+ // display:none (it is still safe to use offsets if a parent element is+ // hidden; don safety goggles and see bug #4512 for more information).+ div.innerHTML = "<table><tr><td></td><td>t</td></tr></table>";+ contents = div.getElementsByTagName( "td" );+ contents[ 0 ].style.cssText = "margin:0;border:0;padding:0;display:none";+ reliableHiddenOffsetsVal = contents[ 0 ].offsetHeight === 0;+ if ( reliableHiddenOffsetsVal ) {+ contents[ 0 ].style.display = "";+ contents[ 1 ].style.display = "none";+ reliableHiddenOffsetsVal = contents[ 0 ].offsetHeight === 0;+ }++ body.removeChild( container );+ }++})();+++// A method for quickly swapping in/out CSS properties to get correct calculations.+jQuery.swap = function( elem, options, callback, args ) {+ var ret, name,+ old = {};++ // Remember the old values, and insert the new ones+ for ( name in options ) {+ old[ name ] = elem.style[ name ];+ elem.style[ name ] = options[ name ];+ }++ ret = callback.apply( elem, args || [] );++ // Revert the old values+ for ( name in options ) {+ elem.style[ name ] = old[ name ];+ }++ return ret;+};+++var+ ralpha = /alpha\([^)]*\)/i,+ ropacity = /opacity\s*=\s*([^)]*)/,++ // swappable if display is none or starts with table except "table", "table-cell", or "table-caption"+ // see here for display values: https://developer.mozilla.org/en-US/docs/CSS/display+ rdisplayswap = /^(none|table(?!-c[ea]).+)/,+ rnumsplit = new RegExp( "^(" + pnum + ")(.*)$", "i" ),+ rrelNum = new RegExp( "^([+-])=(" + pnum + ")", "i" ),++ cssShow = { position: "absolute", visibility: "hidden", display: "block" },+ cssNormalTransform = {+ letterSpacing: "0",+ fontWeight: "400"+ },++ cssPrefixes = [ "Webkit", "O", "Moz", "ms" ];+++// return a css property mapped to a potentially vendor prefixed property+function vendorPropName( style, name ) {++ // shortcut for names that are not vendor prefixed+ if ( name in style ) {+ return name;+ }++ // check for vendor prefixed names+ var capName = name.charAt(0).toUpperCase() + name.slice(1),+ origName = name,+ i = cssPrefixes.length;++ while ( i-- ) {+ name = cssPrefixes[ i ] + capName;+ if ( name in style ) {+ return name;+ }+ }++ return origName;+}++function showHide( elements, show ) {+ var display, elem, hidden,+ values = [],+ index = 0,+ length = elements.length;++ for ( ; index < length; index++ ) {+ elem = elements[ index ];+ if ( !elem.style ) {+ continue;+ }++ values[ index ] = jQuery._data( elem, "olddisplay" );+ display = elem.style.display;+ if ( show ) {+ // Reset the inline display of this element to learn if it is+ // being hidden by cascaded rules or not+ if ( !values[ index ] && display === "none" ) {+ elem.style.display = "";+ }++ // Set elements which have been overridden with display: none+ // in a stylesheet to whatever the default browser style is+ // for such an element+ if ( elem.style.display === "" && isHidden( elem ) ) {+ values[ index ] = jQuery._data( elem, "olddisplay", defaultDisplay(elem.nodeName) );+ }+ } else {+ hidden = isHidden( elem );++ if ( display && display !== "none" || !hidden ) {+ jQuery._data( elem, "olddisplay", hidden ? display : jQuery.css( elem, "display" ) );+ }+ }+ }++ // Set the display of most of the elements in a second loop+ // to avoid the constant reflow+ for ( index = 0; index < length; index++ ) {+ elem = elements[ index ];+ if ( !elem.style ) {+ continue;+ }+ if ( !show || elem.style.display === "none" || elem.style.display === "" ) {+ elem.style.display = show ? values[ index ] || "" : "none";+ }+ }++ return elements;+}++function setPositiveNumber( elem, value, subtract ) {+ var matches = rnumsplit.exec( value );+ return matches ?+ // Guard against undefined "subtract", e.g., when used as in cssHooks+ Math.max( 0, matches[ 1 ] - ( subtract || 0 ) ) + ( matches[ 2 ] || "px" ) :+ value;+}++function augmentWidthOrHeight( elem, name, extra, isBorderBox, styles ) {+ var i = extra === ( isBorderBox ? "border" : "content" ) ?+ // If we already have the right measurement, avoid augmentation+ 4 :+ // Otherwise initialize for horizontal or vertical properties+ name === "width" ? 1 : 0,++ val = 0;++ for ( ; i < 4; i += 2 ) {+ // both box models exclude margin, so add it if we want it+ if ( extra === "margin" ) {+ val += jQuery.css( elem, extra + cssExpand[ i ], true, styles );+ }++ if ( isBorderBox ) {+ // border-box includes padding, so remove it if we want content+ if ( extra === "content" ) {+ val -= jQuery.css( elem, "padding" + cssExpand[ i ], true, styles );+ }++ // at this point, extra isn't border nor margin, so remove border+ if ( extra !== "margin" ) {+ val -= jQuery.css( elem, "border" + cssExpand[ i ] + "Width", true, styles );+ }+ } else {+ // at this point, extra isn't content, so add padding+ val += jQuery.css( elem, "padding" + cssExpand[ i ], true, styles );++ // at this point, extra isn't content nor padding, so add border+ if ( extra !== "padding" ) {+ val += jQuery.css( elem, "border" + cssExpand[ i ] + "Width", true, styles );+ }+ }+ }++ return val;+}++function getWidthOrHeight( elem, name, extra ) {++ // Start with offset property, which is equivalent to the border-box value+ var valueIsBorderBox = true,+ val = name === "width" ? elem.offsetWidth : elem.offsetHeight,+ styles = getStyles( elem ),+ isBorderBox = support.boxSizing && jQuery.css( elem, "boxSizing", false, styles ) === "border-box";++ // some non-html elements return undefined for offsetWidth, so check for null/undefined+ // svg - https://bugzilla.mozilla.org/show_bug.cgi?id=649285+ // MathML - https://bugzilla.mozilla.org/show_bug.cgi?id=491668+ if ( val <= 0 || val == null ) {+ // Fall back to computed then uncomputed css if necessary+ val = curCSS( elem, name, styles );+ if ( val < 0 || val == null ) {+ val = elem.style[ name ];+ }++ // Computed unit is not pixels. Stop here and return.+ if ( rnumnonpx.test(val) ) {+ return val;+ }++ // we need the check for style in case a browser which returns unreliable values+ // for getComputedStyle silently falls back to the reliable elem.style+ valueIsBorderBox = isBorderBox && ( support.boxSizingReliable() || val === elem.style[ name ] );++ // Normalize "", auto, and prepare for extra+ val = parseFloat( val ) || 0;+ }++ // use the active box-sizing model to add/subtract irrelevant styles+ return ( val ++ augmentWidthOrHeight(+ elem,+ name,+ extra || ( isBorderBox ? "border" : "content" ),+ valueIsBorderBox,+ styles+ )+ ) + "px";+}++jQuery.extend({+ // Add in style property hooks for overriding the default+ // behavior of getting and setting a style property+ cssHooks: {+ opacity: {+ get: function( elem, computed ) {+ if ( computed ) {+ // We should always get a number back from opacity+ var ret = curCSS( elem, "opacity" );+ return ret === "" ? "1" : ret;+ }+ }+ }+ },++ // Don't automatically add "px" to these possibly-unitless properties+ cssNumber: {+ "columnCount": true,+ "fillOpacity": true,+ "flexGrow": true,+ "flexShrink": true,+ "fontWeight": true,+ "lineHeight": true,+ "opacity": true,+ "order": true,+ "orphans": true,+ "widows": true,+ "zIndex": true,+ "zoom": true+ },++ // Add in properties whose names you wish to fix before+ // setting or getting the value+ cssProps: {+ // normalize float css property+ "float": support.cssFloat ? "cssFloat" : "styleFloat"+ },++ // Get and set the style property on a DOM Node+ style: function( elem, name, value, extra ) {+ // Don't set styles on text and comment nodes+ if ( !elem || elem.nodeType === 3 || elem.nodeType === 8 || !elem.style ) {+ return;+ }++ // Make sure that we're working with the right name+ var ret, type, hooks,+ origName = jQuery.camelCase( name ),+ style = elem.style;++ name = jQuery.cssProps[ origName ] || ( jQuery.cssProps[ origName ] = vendorPropName( style, origName ) );++ // gets hook for the prefixed version+ // followed by the unprefixed version+ hooks = jQuery.cssHooks[ name ] || jQuery.cssHooks[ origName ];++ // Check if we're setting a value+ if ( value !== undefined ) {+ type = typeof value;++ // convert relative number strings (+= or -=) to relative numbers. #7345+ if ( type === "string" && (ret = rrelNum.exec( value )) ) {+ value = ( ret[1] + 1 ) * ret[2] + parseFloat( jQuery.css( elem, name ) );+ // Fixes bug #9237+ type = "number";+ }++ // Make sure that null and NaN values aren't set. See: #7116+ if ( value == null || value !== value ) {+ return;+ }++ // If a number was passed in, add 'px' to the (except for certain CSS properties)+ if ( type === "number" && !jQuery.cssNumber[ origName ] ) {+ value += "px";+ }++ // Fixes #8908, it can be done more correctly by specifing setters in cssHooks,+ // but it would mean to define eight (for every problematic property) identical functions+ if ( !support.clearCloneStyle && value === "" && name.indexOf("background") === 0 ) {+ style[ name ] = "inherit";+ }++ // If a hook was provided, use that value, otherwise just set the specified value+ if ( !hooks || !("set" in hooks) || (value = hooks.set( elem, value, extra )) !== undefined ) {++ // Support: IE+ // Swallow errors from 'invalid' CSS values (#5509)+ try {+ style[ name ] = value;+ } catch(e) {}+ }++ } else {+ // If a hook was provided get the non-computed value from there+ if ( hooks && "get" in hooks && (ret = hooks.get( elem, false, extra )) !== undefined ) {+ return ret;+ }++ // Otherwise just get the value from the style object+ return style[ name ];+ }+ },++ css: function( elem, name, extra, styles ) {+ var num, val, hooks,+ origName = jQuery.camelCase( name );++ // Make sure that we're working with the right name+ name = jQuery.cssProps[ origName ] || ( jQuery.cssProps[ origName ] = vendorPropName( elem.style, origName ) );++ // gets hook for the prefixed version+ // followed by the unprefixed version+ hooks = jQuery.cssHooks[ name ] || jQuery.cssHooks[ origName ];++ // If a hook was provided get the computed value from there+ if ( hooks && "get" in hooks ) {+ val = hooks.get( elem, true, extra );+ }++ // Otherwise, if a way to get the computed value exists, use that+ if ( val === undefined ) {+ val = curCSS( elem, name, styles );+ }++ //convert "normal" to computed value+ if ( val === "normal" && name in cssNormalTransform ) {+ val = cssNormalTransform[ name ];+ }++ // Return, converting to number if forced or a qualifier was provided and val looks numeric+ if ( extra === "" || extra ) {+ num = parseFloat( val );+ return extra === true || jQuery.isNumeric( num ) ? num || 0 : val;+ }+ return val;+ }+});++jQuery.each([ "height", "width" ], function( i, name ) {+ jQuery.cssHooks[ name ] = {+ get: function( elem, computed, extra ) {+ if ( computed ) {+ // certain elements can have dimension info if we invisibly show them+ // however, it must have a current display style that would benefit from this+ return rdisplayswap.test( jQuery.css( elem, "display" ) ) && elem.offsetWidth === 0 ?+ jQuery.swap( elem, cssShow, function() {+ return getWidthOrHeight( elem, name, extra );+ }) :+ getWidthOrHeight( elem, name, extra );+ }+ },++ set: function( elem, value, extra ) {+ var styles = extra && getStyles( elem );+ return setPositiveNumber( elem, value, extra ?+ augmentWidthOrHeight(+ elem,+ name,+ extra,+ support.boxSizing && jQuery.css( elem, "boxSizing", false, styles ) === "border-box",+ styles+ ) : 0+ );+ }+ };+});++if ( !support.opacity ) {+ jQuery.cssHooks.opacity = {+ get: function( elem, computed ) {+ // IE uses filters for opacity+ return ropacity.test( (computed && elem.currentStyle ? elem.currentStyle.filter : elem.style.filter) || "" ) ?+ ( 0.01 * parseFloat( RegExp.$1 ) ) + "" :+ computed ? "1" : "";+ },++ set: function( elem, value ) {+ var style = elem.style,+ currentStyle = elem.currentStyle,+ opacity = jQuery.isNumeric( value ) ? "alpha(opacity=" + value * 100 + ")" : "",+ filter = currentStyle && currentStyle.filter || style.filter || "";++ // IE has trouble with opacity if it does not have layout+ // Force it by setting the zoom level+ style.zoom = 1;++ // if setting opacity to 1, and no other filters exist - attempt to remove filter attribute #6652+ // if value === "", then remove inline opacity #12685+ if ( ( value >= 1 || value === "" ) &&+ jQuery.trim( filter.replace( ralpha, "" ) ) === "" &&+ style.removeAttribute ) {++ // Setting style.filter to null, "" & " " still leave "filter:" in the cssText+ // if "filter:" is present at all, clearType is disabled, we want to avoid this+ // style.removeAttribute is IE Only, but so apparently is this code path...+ style.removeAttribute( "filter" );++ // if there is no filter style applied in a css rule or unset inline opacity, we are done+ if ( value === "" || currentStyle && !currentStyle.filter ) {+ return;+ }+ }++ // otherwise, set new filter values+ style.filter = ralpha.test( filter ) ?+ filter.replace( ralpha, opacity ) :+ filter + " " + opacity;+ }+ };+}++jQuery.cssHooks.marginRight = addGetHookIf( support.reliableMarginRight,+ function( elem, computed ) {+ if ( computed ) {+ // WebKit Bug 13343 - getComputedStyle returns wrong value for margin-right+ // Work around by temporarily setting element display to inline-block+ return jQuery.swap( elem, { "display": "inline-block" },+ curCSS, [ elem, "marginRight" ] );+ }+ }+);++// These hooks are used by animate to expand properties+jQuery.each({+ margin: "",+ padding: "",+ border: "Width"+}, function( prefix, suffix ) {+ jQuery.cssHooks[ prefix + suffix ] = {+ expand: function( value ) {+ var i = 0,+ expanded = {},++ // assumes a single number if not a string+ parts = typeof value === "string" ? value.split(" ") : [ value ];++ for ( ; i < 4; i++ ) {+ expanded[ prefix + cssExpand[ i ] + suffix ] =+ parts[ i ] || parts[ i - 2 ] || parts[ 0 ];+ }++ return expanded;+ }+ };++ if ( !rmargin.test( prefix ) ) {+ jQuery.cssHooks[ prefix + suffix ].set = setPositiveNumber;+ }+});++jQuery.fn.extend({+ css: function( name, value ) {+ return access( this, function( elem, name, value ) {+ var styles, len,+ map = {},+ i = 0;++ if ( jQuery.isArray( name ) ) {+ styles = getStyles( elem );+ len = name.length;++ for ( ; i < len; i++ ) {+ map[ name[ i ] ] = jQuery.css( elem, name[ i ], false, styles );+ }++ return map;+ }++ return value !== undefined ?+ jQuery.style( elem, name, value ) :+ jQuery.css( elem, name );+ }, name, value, arguments.length > 1 );+ },+ show: function() {+ return showHide( this, true );+ },+ hide: function() {+ return showHide( this );+ },+ toggle: function( state ) {+ if ( typeof state === "boolean" ) {+ return state ? this.show() : this.hide();+ }++ return this.each(function() {+ if ( isHidden( this ) ) {+ jQuery( this ).show();+ } else {+ jQuery( this ).hide();+ }+ });+ }+});+++function Tween( elem, options, prop, end, easing ) {+ return new Tween.prototype.init( elem, options, prop, end, easing );+}+jQuery.Tween = Tween;++Tween.prototype = {+ constructor: Tween,+ init: function( elem, options, prop, end, easing, unit ) {+ this.elem = elem;+ this.prop = prop;+ this.easing = easing || "swing";+ this.options = options;+ this.start = this.now = this.cur();+ this.end = end;+ this.unit = unit || ( jQuery.cssNumber[ prop ] ? "" : "px" );+ },+ cur: function() {+ var hooks = Tween.propHooks[ this.prop ];++ return hooks && hooks.get ?+ hooks.get( this ) :+ Tween.propHooks._default.get( this );+ },+ run: function( percent ) {+ var eased,+ hooks = Tween.propHooks[ this.prop ];++ if ( this.options.duration ) {+ this.pos = eased = jQuery.easing[ this.easing ](+ percent, this.options.duration * percent, 0, 1, this.options.duration+ );+ } else {+ this.pos = eased = percent;+ }+ this.now = ( this.end - this.start ) * eased + this.start;++ if ( this.options.step ) {+ this.options.step.call( this.elem, this.now, this );+ }++ if ( hooks && hooks.set ) {+ hooks.set( this );+ } else {+ Tween.propHooks._default.set( this );+ }+ return this;+ }+};++Tween.prototype.init.prototype = Tween.prototype;++Tween.propHooks = {+ _default: {+ get: function( tween ) {+ var result;++ if ( tween.elem[ tween.prop ] != null &&+ (!tween.elem.style || tween.elem.style[ tween.prop ] == null) ) {+ return tween.elem[ tween.prop ];+ }++ // passing an empty string as a 3rd parameter to .css will automatically+ // attempt a parseFloat and fallback to a string if the parse fails+ // so, simple values such as "10px" are parsed to Float.+ // complex values such as "rotate(1rad)" are returned as is.+ result = jQuery.css( tween.elem, tween.prop, "" );+ // Empty strings, null, undefined and "auto" are converted to 0.+ return !result || result === "auto" ? 0 : result;+ },+ set: function( tween ) {+ // use step hook for back compat - use cssHook if its there - use .style if its+ // available and use plain properties where available+ if ( jQuery.fx.step[ tween.prop ] ) {+ jQuery.fx.step[ tween.prop ]( tween );+ } else if ( tween.elem.style && ( tween.elem.style[ jQuery.cssProps[ tween.prop ] ] != null || jQuery.cssHooks[ tween.prop ] ) ) {+ jQuery.style( tween.elem, tween.prop, tween.now + tween.unit );+ } else {+ tween.elem[ tween.prop ] = tween.now;+ }+ }+ }+};++// Support: IE <=9+// Panic based approach to setting things on disconnected nodes++Tween.propHooks.scrollTop = Tween.propHooks.scrollLeft = {+ set: function( tween ) {+ if ( tween.elem.nodeType && tween.elem.parentNode ) {+ tween.elem[ tween.prop ] = tween.now;+ }+ }+};++jQuery.easing = {+ linear: function( p ) {+ return p;+ },+ swing: function( p ) {+ return 0.5 - Math.cos( p * Math.PI ) / 2;+ }+};++jQuery.fx = Tween.prototype.init;++// Back Compat <1.8 extension point+jQuery.fx.step = {};+++++var+ fxNow, timerId,+ rfxtypes = /^(?:toggle|show|hide)$/,+ rfxnum = new RegExp( "^(?:([+-])=|)(" + pnum + ")([a-z%]*)$", "i" ),+ rrun = /queueHooks$/,+ animationPrefilters = [ defaultPrefilter ],+ tweeners = {+ "*": [ function( prop, value ) {+ var tween = this.createTween( prop, value ),+ target = tween.cur(),+ parts = rfxnum.exec( value ),+ unit = parts && parts[ 3 ] || ( jQuery.cssNumber[ prop ] ? "" : "px" ),++ // Starting value computation is required for potential unit mismatches+ start = ( jQuery.cssNumber[ prop ] || unit !== "px" && +target ) &&+ rfxnum.exec( jQuery.css( tween.elem, prop ) ),+ scale = 1,+ maxIterations = 20;++ if ( start && start[ 3 ] !== unit ) {+ // Trust units reported by jQuery.css+ unit = unit || start[ 3 ];++ // Make sure we update the tween properties later on+ parts = parts || [];++ // Iteratively approximate from a nonzero starting point+ start = +target || 1;++ do {+ // If previous iteration zeroed out, double until we get *something*+ // Use a string for doubling factor so we don't accidentally see scale as unchanged below+ scale = scale || ".5";++ // Adjust and apply+ start = start / scale;+ jQuery.style( tween.elem, prop, start + unit );++ // Update scale, tolerating zero or NaN from tween.cur()+ // And breaking the loop if scale is unchanged or perfect, or if we've just had enough+ } while ( scale !== (scale = tween.cur() / target) && scale !== 1 && --maxIterations );+ }++ // Update tween properties+ if ( parts ) {+ start = tween.start = +start || +target || 0;+ tween.unit = unit;+ // If a +=/-= token was provided, we're doing a relative animation+ tween.end = parts[ 1 ] ?+ start + ( parts[ 1 ] + 1 ) * parts[ 2 ] :+ +parts[ 2 ];+ }++ return tween;+ } ]+ };++// Animations created synchronously will run synchronously+function createFxNow() {+ setTimeout(function() {+ fxNow = undefined;+ });+ return ( fxNow = jQuery.now() );+}++// Generate parameters to create a standard animation+function genFx( type, includeWidth ) {+ var which,+ attrs = { height: type },+ i = 0;++ // if we include width, step value is 1 to do all cssExpand values,+ // if we don't include width, step value is 2 to skip over Left and Right+ includeWidth = includeWidth ? 1 : 0;+ for ( ; i < 4 ; i += 2 - includeWidth ) {+ which = cssExpand[ i ];+ attrs[ "margin" + which ] = attrs[ "padding" + which ] = type;+ }++ if ( includeWidth ) {+ attrs.opacity = attrs.width = type;+ }++ return attrs;+}++function createTween( value, prop, animation ) {+ var tween,+ collection = ( tweeners[ prop ] || [] ).concat( tweeners[ "*" ] ),+ index = 0,+ length = collection.length;+ for ( ; index < length; index++ ) {+ if ( (tween = collection[ index ].call( animation, prop, value )) ) {++ // we're done with this property+ return tween;+ }+ }+}++function defaultPrefilter( elem, props, opts ) {+ /* jshint validthis: true */+ var prop, value, toggle, tween, hooks, oldfire, display, checkDisplay,+ anim = this,+ orig = {},+ style = elem.style,+ hidden = elem.nodeType && isHidden( elem ),+ dataShow = jQuery._data( elem, "fxshow" );++ // handle queue: false promises+ if ( !opts.queue ) {+ hooks = jQuery._queueHooks( elem, "fx" );+ if ( hooks.unqueued == null ) {+ hooks.unqueued = 0;+ oldfire = hooks.empty.fire;+ hooks.empty.fire = function() {+ if ( !hooks.unqueued ) {+ oldfire();+ }+ };+ }+ hooks.unqueued++;++ anim.always(function() {+ // doing this makes sure that the complete handler will be called+ // before this completes+ anim.always(function() {+ hooks.unqueued--;+ if ( !jQuery.queue( elem, "fx" ).length ) {+ hooks.empty.fire();+ }+ });+ });+ }++ // height/width overflow pass+ if ( elem.nodeType === 1 && ( "height" in props || "width" in props ) ) {+ // Make sure that nothing sneaks out+ // Record all 3 overflow attributes because IE does not+ // change the overflow attribute when overflowX and+ // overflowY are set to the same value+ opts.overflow = [ style.overflow, style.overflowX, style.overflowY ];++ // Set display property to inline-block for height/width+ // animations on inline elements that are having width/height animated+ display = jQuery.css( elem, "display" );++ // Test default display if display is currently "none"+ checkDisplay = display === "none" ?+ jQuery._data( elem, "olddisplay" ) || defaultDisplay( elem.nodeName ) : display;++ if ( checkDisplay === "inline" && jQuery.css( elem, "float" ) === "none" ) {++ // inline-level elements accept inline-block;+ // block-level elements need to be inline with layout+ if ( !support.inlineBlockNeedsLayout || defaultDisplay( elem.nodeName ) === "inline" ) {+ style.display = "inline-block";+ } else {+ style.zoom = 1;+ }+ }+ }++ if ( opts.overflow ) {+ style.overflow = "hidden";+ if ( !support.shrinkWrapBlocks() ) {+ anim.always(function() {+ style.overflow = opts.overflow[ 0 ];+ style.overflowX = opts.overflow[ 1 ];+ style.overflowY = opts.overflow[ 2 ];+ });+ }+ }++ // show/hide pass+ for ( prop in props ) {+ value = props[ prop ];+ if ( rfxtypes.exec( value ) ) {+ delete props[ prop ];+ toggle = toggle || value === "toggle";+ if ( value === ( hidden ? "hide" : "show" ) ) {++ // If there is dataShow left over from a stopped hide or show and we are going to proceed with show, we should pretend to be hidden+ if ( value === "show" && dataShow && dataShow[ prop ] !== undefined ) {+ hidden = true;+ } else {+ continue;+ }+ }+ orig[ prop ] = dataShow && dataShow[ prop ] || jQuery.style( elem, prop );++ // Any non-fx value stops us from restoring the original display value+ } else {+ display = undefined;+ }+ }++ if ( !jQuery.isEmptyObject( orig ) ) {+ if ( dataShow ) {+ if ( "hidden" in dataShow ) {+ hidden = dataShow.hidden;+ }+ } else {+ dataShow = jQuery._data( elem, "fxshow", {} );+ }++ // store state if its toggle - enables .stop().toggle() to "reverse"+ if ( toggle ) {+ dataShow.hidden = !hidden;+ }+ if ( hidden ) {+ jQuery( elem ).show();+ } else {+ anim.done(function() {+ jQuery( elem ).hide();+ });+ }+ anim.done(function() {+ var prop;+ jQuery._removeData( elem, "fxshow" );+ for ( prop in orig ) {+ jQuery.style( elem, prop, orig[ prop ] );+ }+ });+ for ( prop in orig ) {+ tween = createTween( hidden ? dataShow[ prop ] : 0, prop, anim );++ if ( !( prop in dataShow ) ) {+ dataShow[ prop ] = tween.start;+ if ( hidden ) {+ tween.end = tween.start;+ tween.start = prop === "width" || prop === "height" ? 1 : 0;+ }+ }+ }++ // If this is a noop like .hide().hide(), restore an overwritten display value+ } else if ( (display === "none" ? defaultDisplay( elem.nodeName ) : display) === "inline" ) {+ style.display = display;+ }+}++function propFilter( props, specialEasing ) {+ var index, name, easing, value, hooks;++ // camelCase, specialEasing and expand cssHook pass+ for ( index in props ) {+ name = jQuery.camelCase( index );+ easing = specialEasing[ name ];+ value = props[ index ];+ if ( jQuery.isArray( value ) ) {+ easing = value[ 1 ];+ value = props[ index ] = value[ 0 ];+ }++ if ( index !== name ) {+ props[ name ] = value;+ delete props[ index ];+ }++ hooks = jQuery.cssHooks[ name ];+ if ( hooks && "expand" in hooks ) {+ value = hooks.expand( value );+ delete props[ name ];++ // not quite $.extend, this wont overwrite keys already present.+ // also - reusing 'index' from above because we have the correct "name"+ for ( index in value ) {+ if ( !( index in props ) ) {+ props[ index ] = value[ index ];+ specialEasing[ index ] = easing;+ }+ }+ } else {+ specialEasing[ name ] = easing;+ }+ }+}++function Animation( elem, properties, options ) {+ var result,+ stopped,+ index = 0,+ length = animationPrefilters.length,+ deferred = jQuery.Deferred().always( function() {+ // don't match elem in the :animated selector+ delete tick.elem;+ }),+ tick = function() {+ if ( stopped ) {+ return false;+ }+ var currentTime = fxNow || createFxNow(),+ remaining = Math.max( 0, animation.startTime + animation.duration - currentTime ),+ // archaic crash bug won't allow us to use 1 - ( 0.5 || 0 ) (#12497)+ temp = remaining / animation.duration || 0,+ percent = 1 - temp,+ index = 0,+ length = animation.tweens.length;++ for ( ; index < length ; index++ ) {+ animation.tweens[ index ].run( percent );+ }++ deferred.notifyWith( elem, [ animation, percent, remaining ]);++ if ( percent < 1 && length ) {+ return remaining;+ } else {+ deferred.resolveWith( elem, [ animation ] );+ return false;+ }+ },+ animation = deferred.promise({+ elem: elem,+ props: jQuery.extend( {}, properties ),+ opts: jQuery.extend( true, { specialEasing: {} }, options ),+ originalProperties: properties,+ originalOptions: options,+ startTime: fxNow || createFxNow(),+ duration: options.duration,+ tweens: [],+ createTween: function( prop, end ) {+ var tween = jQuery.Tween( elem, animation.opts, prop, end,+ animation.opts.specialEasing[ prop ] || animation.opts.easing );+ animation.tweens.push( tween );+ return tween;+ },+ stop: function( gotoEnd ) {+ var index = 0,+ // if we are going to the end, we want to run all the tweens+ // otherwise we skip this part+ length = gotoEnd ? animation.tweens.length : 0;+ if ( stopped ) {+ return this;+ }+ stopped = true;+ for ( ; index < length ; index++ ) {+ animation.tweens[ index ].run( 1 );+ }++ // resolve when we played the last frame+ // otherwise, reject+ if ( gotoEnd ) {+ deferred.resolveWith( elem, [ animation, gotoEnd ] );+ } else {+ deferred.rejectWith( elem, [ animation, gotoEnd ] );+ }+ return this;+ }+ }),+ props = animation.props;++ propFilter( props, animation.opts.specialEasing );++ for ( ; index < length ; index++ ) {+ result = animationPrefilters[ index ].call( animation, elem, props, animation.opts );+ if ( result ) {+ return result;+ }+ }++ jQuery.map( props, createTween, animation );++ if ( jQuery.isFunction( animation.opts.start ) ) {+ animation.opts.start.call( elem, animation );+ }++ jQuery.fx.timer(+ jQuery.extend( tick, {+ elem: elem,+ anim: animation,+ queue: animation.opts.queue+ })+ );++ // attach callbacks from options+ return animation.progress( animation.opts.progress )+ .done( animation.opts.done, animation.opts.complete )+ .fail( animation.opts.fail )+ .always( animation.opts.always );+}++jQuery.Animation = jQuery.extend( Animation, {+ tweener: function( props, callback ) {+ if ( jQuery.isFunction( props ) ) {+ callback = props;+ props = [ "*" ];+ } else {+ props = props.split(" ");+ }++ var prop,+ index = 0,+ length = props.length;++ for ( ; index < length ; index++ ) {+ prop = props[ index ];+ tweeners[ prop ] = tweeners[ prop ] || [];+ tweeners[ prop ].unshift( callback );+ }+ },++ prefilter: function( callback, prepend ) {+ if ( prepend ) {+ animationPrefilters.unshift( callback );+ } else {+ animationPrefilters.push( callback );+ }+ }+});++jQuery.speed = function( speed, easing, fn ) {+ var opt = speed && typeof speed === "object" ? jQuery.extend( {}, speed ) : {+ complete: fn || !fn && easing ||+ jQuery.isFunction( speed ) && speed,+ duration: speed,+ easing: fn && easing || easing && !jQuery.isFunction( easing ) && easing+ };++ opt.duration = jQuery.fx.off ? 0 : typeof opt.duration === "number" ? opt.duration :+ opt.duration in jQuery.fx.speeds ? jQuery.fx.speeds[ opt.duration ] : jQuery.fx.speeds._default;++ // normalize opt.queue - true/undefined/null -> "fx"+ if ( opt.queue == null || opt.queue === true ) {+ opt.queue = "fx";+ }++ // Queueing+ opt.old = opt.complete;++ opt.complete = function() {+ if ( jQuery.isFunction( opt.old ) ) {+ opt.old.call( this );+ }++ if ( opt.queue ) {+ jQuery.dequeue( this, opt.queue );+ }+ };++ return opt;+};++jQuery.fn.extend({+ fadeTo: function( speed, to, easing, callback ) {++ // show any hidden elements after setting opacity to 0+ return this.filter( isHidden ).css( "opacity", 0 ).show()++ // animate to the value specified+ .end().animate({ opacity: to }, speed, easing, callback );+ },+ animate: function( prop, speed, easing, callback ) {+ var empty = jQuery.isEmptyObject( prop ),+ optall = jQuery.speed( speed, easing, callback ),+ doAnimation = function() {+ // Operate on a copy of prop so per-property easing won't be lost+ var anim = Animation( this, jQuery.extend( {}, prop ), optall );++ // Empty animations, or finishing resolves immediately+ if ( empty || jQuery._data( this, "finish" ) ) {+ anim.stop( true );+ }+ };+ doAnimation.finish = doAnimation;++ return empty || optall.queue === false ?+ this.each( doAnimation ) :+ this.queue( optall.queue, doAnimation );+ },+ stop: function( type, clearQueue, gotoEnd ) {+ var stopQueue = function( hooks ) {+ var stop = hooks.stop;+ delete hooks.stop;+ stop( gotoEnd );+ };++ if ( typeof type !== "string" ) {+ gotoEnd = clearQueue;+ clearQueue = type;+ type = undefined;+ }+ if ( clearQueue && type !== false ) {+ this.queue( type || "fx", [] );+ }++ return this.each(function() {+ var dequeue = true,+ index = type != null && type + "queueHooks",+ timers = jQuery.timers,+ data = jQuery._data( this );++ if ( index ) {+ if ( data[ index ] && data[ index ].stop ) {+ stopQueue( data[ index ] );+ }+ } else {+ for ( index in data ) {+ if ( data[ index ] && data[ index ].stop && rrun.test( index ) ) {+ stopQueue( data[ index ] );+ }+ }+ }++ for ( index = timers.length; index--; ) {+ if ( timers[ index ].elem === this && (type == null || timers[ index ].queue === type) ) {+ timers[ index ].anim.stop( gotoEnd );+ dequeue = false;+ timers.splice( index, 1 );+ }+ }++ // start the next in the queue if the last step wasn't forced+ // timers currently will call their complete callbacks, which will dequeue+ // but only if they were gotoEnd+ if ( dequeue || !gotoEnd ) {+ jQuery.dequeue( this, type );+ }+ });+ },+ finish: function( type ) {+ if ( type !== false ) {+ type = type || "fx";+ }+ return this.each(function() {+ var index,+ data = jQuery._data( this ),+ queue = data[ type + "queue" ],+ hooks = data[ type + "queueHooks" ],+ timers = jQuery.timers,+ length = queue ? queue.length : 0;++ // enable finishing flag on private data+ data.finish = true;++ // empty the queue first+ jQuery.queue( this, type, [] );++ if ( hooks && hooks.stop ) {+ hooks.stop.call( this, true );+ }++ // look for any active animations, and finish them+ for ( index = timers.length; index--; ) {+ if ( timers[ index ].elem === this && timers[ index ].queue === type ) {+ timers[ index ].anim.stop( true );+ timers.splice( index, 1 );+ }+ }++ // look for any animations in the old queue and finish them+ for ( index = 0; index < length; index++ ) {+ if ( queue[ index ] && queue[ index ].finish ) {+ queue[ index ].finish.call( this );+ }+ }++ // turn off finishing flag+ delete data.finish;+ });+ }+});++jQuery.each([ "toggle", "show", "hide" ], function( i, name ) {+ var cssFn = jQuery.fn[ name ];+ jQuery.fn[ name ] = function( speed, easing, callback ) {+ return speed == null || typeof speed === "boolean" ?+ cssFn.apply( this, arguments ) :+ this.animate( genFx( name, true ), speed, easing, callback );+ };+});++// Generate shortcuts for custom animations+jQuery.each({+ slideDown: genFx("show"),+ slideUp: genFx("hide"),+ slideToggle: genFx("toggle"),+ fadeIn: { opacity: "show" },+ fadeOut: { opacity: "hide" },+ fadeToggle: { opacity: "toggle" }+}, function( name, props ) {+ jQuery.fn[ name ] = function( speed, easing, callback ) {+ return this.animate( props, speed, easing, callback );+ };+});++jQuery.timers = [];+jQuery.fx.tick = function() {+ var timer,+ timers = jQuery.timers,+ i = 0;++ fxNow = jQuery.now();++ for ( ; i < timers.length; i++ ) {+ timer = timers[ i ];+ // Checks the timer has not already been removed+ if ( !timer() && timers[ i ] === timer ) {+ timers.splice( i--, 1 );+ }+ }++ if ( !timers.length ) {+ jQuery.fx.stop();+ }+ fxNow = undefined;+};++jQuery.fx.timer = function( timer ) {+ jQuery.timers.push( timer );+ if ( timer() ) {+ jQuery.fx.start();+ } else {+ jQuery.timers.pop();+ }+};++jQuery.fx.interval = 13;++jQuery.fx.start = function() {+ if ( !timerId ) {+ timerId = setInterval( jQuery.fx.tick, jQuery.fx.interval );+ }+};++jQuery.fx.stop = function() {+ clearInterval( timerId );+ timerId = null;+};++jQuery.fx.speeds = {+ slow: 600,+ fast: 200,+ // Default speed+ _default: 400+};+++// Based off of the plugin by Clint Helfers, with permission.+// http://blindsignals.com/index.php/2009/07/jquery-delay/+jQuery.fn.delay = function( time, type ) {+ time = jQuery.fx ? jQuery.fx.speeds[ time ] || time : time;+ type = type || "fx";++ return this.queue( type, function( next, hooks ) {+ var timeout = setTimeout( next, time );+ hooks.stop = function() {+ clearTimeout( timeout );+ };+ });+};+++(function() {+ // Minified: var a,b,c,d,e+ var input, div, select, a, opt;++ // Setup+ div = document.createElement( "div" );+ div.setAttribute( "className", "t" );+ div.innerHTML = " <link/><table></table><a href='/a'>a</a><input type='checkbox'/>";+ a = div.getElementsByTagName("a")[ 0 ];++ // First batch of tests.+ select = document.createElement("select");+ opt = select.appendChild( document.createElement("option") );+ input = div.getElementsByTagName("input")[ 0 ];++ a.style.cssText = "top:1px";++ // Test setAttribute on camelCase class. If it works, we need attrFixes when doing get/setAttribute (ie6/7)+ support.getSetAttribute = div.className !== "t";++ // Get the style information from getAttribute+ // (IE uses .cssText instead)+ support.style = /top/.test( a.getAttribute("style") );++ // Make sure that URLs aren't manipulated+ // (IE normalizes it by default)+ support.hrefNormalized = a.getAttribute("href") === "/a";++ // Check the default checkbox/radio value ("" on WebKit; "on" elsewhere)+ support.checkOn = !!input.value;++ // Make sure that a selected-by-default option has a working selected property.+ // (WebKit defaults to false instead of true, IE too, if it's in an optgroup)+ support.optSelected = opt.selected;++ // Tests for enctype support on a form (#6743)+ support.enctype = !!document.createElement("form").enctype;++ // Make sure that the options inside disabled selects aren't marked as disabled+ // (WebKit marks them as disabled)+ select.disabled = true;+ support.optDisabled = !opt.disabled;++ // Support: IE8 only+ // Check if we can trust getAttribute("value")+ input = document.createElement( "input" );+ input.setAttribute( "value", "" );+ support.input = input.getAttribute( "value" ) === "";++ // Check if an input maintains its value after becoming a radio+ input.value = "t";+ input.setAttribute( "type", "radio" );+ support.radioValue = input.value === "t";+})();+++var rreturn = /\r/g;++jQuery.fn.extend({+ val: function( value ) {+ var hooks, ret, isFunction,+ elem = this[0];++ if ( !arguments.length ) {+ if ( elem ) {+ hooks = jQuery.valHooks[ elem.type ] || jQuery.valHooks[ elem.nodeName.toLowerCase() ];++ if ( hooks && "get" in hooks && (ret = hooks.get( elem, "value" )) !== undefined ) {+ return ret;+ }++ ret = elem.value;++ return typeof ret === "string" ?+ // handle most common string cases+ ret.replace(rreturn, "") :+ // handle cases where value is null/undef or number+ ret == null ? "" : ret;+ }++ return;+ }++ isFunction = jQuery.isFunction( value );++ return this.each(function( i ) {+ var val;++ if ( this.nodeType !== 1 ) {+ return;+ }++ if ( isFunction ) {+ val = value.call( this, i, jQuery( this ).val() );+ } else {+ val = value;+ }++ // Treat null/undefined as ""; convert numbers to string+ if ( val == null ) {+ val = "";+ } else if ( typeof val === "number" ) {+ val += "";+ } else if ( jQuery.isArray( val ) ) {+ val = jQuery.map( val, function( value ) {+ return value == null ? "" : value + "";+ });+ }++ hooks = jQuery.valHooks[ this.type ] || jQuery.valHooks[ this.nodeName.toLowerCase() ];++ // If set returns undefined, fall back to normal setting+ if ( !hooks || !("set" in hooks) || hooks.set( this, val, "value" ) === undefined ) {+ this.value = val;+ }+ });+ }+});++jQuery.extend({+ valHooks: {+ option: {+ get: function( elem ) {+ var val = jQuery.find.attr( elem, "value" );+ return val != null ?+ val :+ // Support: IE10-11++ // option.text throws exceptions (#14686, #14858)+ jQuery.trim( jQuery.text( elem ) );+ }+ },+ select: {+ get: function( elem ) {+ var value, option,+ options = elem.options,+ index = elem.selectedIndex,+ one = elem.type === "select-one" || index < 0,+ values = one ? null : [],+ max = one ? index + 1 : options.length,+ i = index < 0 ?+ max :+ one ? index : 0;++ // Loop through all the selected options+ for ( ; i < max; i++ ) {+ option = options[ i ];++ // oldIE doesn't update selected after form reset (#2551)+ if ( ( option.selected || i === index ) &&+ // Don't return options that are disabled or in a disabled optgroup+ ( support.optDisabled ? !option.disabled : option.getAttribute("disabled") === null ) &&+ ( !option.parentNode.disabled || !jQuery.nodeName( option.parentNode, "optgroup" ) ) ) {++ // Get the specific value for the option+ value = jQuery( option ).val();++ // We don't need an array for one selects+ if ( one ) {+ return value;+ }++ // Multi-Selects return an array+ values.push( value );+ }+ }++ return values;+ },++ set: function( elem, value ) {+ var optionSet, option,+ options = elem.options,+ values = jQuery.makeArray( value ),+ i = options.length;++ while ( i-- ) {+ option = options[ i ];++ if ( jQuery.inArray( jQuery.valHooks.option.get( option ), values ) >= 0 ) {++ // Support: IE6+ // When new option element is added to select box we need to+ // force reflow of newly added node in order to workaround delay+ // of initialization properties+ try {+ option.selected = optionSet = true;++ } catch ( _ ) {++ // Will be executed only in IE6+ option.scrollHeight;+ }++ } else {+ option.selected = false;+ }+ }++ // Force browsers to behave consistently when non-matching value is set+ if ( !optionSet ) {+ elem.selectedIndex = -1;+ }++ return options;+ }+ }+ }+});++// Radios and checkboxes getter/setter+jQuery.each([ "radio", "checkbox" ], function() {+ jQuery.valHooks[ this ] = {+ set: function( elem, value ) {+ if ( jQuery.isArray( value ) ) {+ return ( elem.checked = jQuery.inArray( jQuery(elem).val(), value ) >= 0 );+ }+ }+ };+ if ( !support.checkOn ) {+ jQuery.valHooks[ this ].get = function( elem ) {+ // Support: Webkit+ // "" is returned instead of "on" if a value isn't specified+ return elem.getAttribute("value") === null ? "on" : elem.value;+ };+ }+});+++++var nodeHook, boolHook,+ attrHandle = jQuery.expr.attrHandle,+ ruseDefault = /^(?:checked|selected)$/i,+ getSetAttribute = support.getSetAttribute,+ getSetInput = support.input;++jQuery.fn.extend({+ attr: function( name, value ) {+ return access( this, jQuery.attr, name, value, arguments.length > 1 );+ },++ removeAttr: function( name ) {+ return this.each(function() {+ jQuery.removeAttr( this, name );+ });+ }+});++jQuery.extend({+ attr: function( elem, name, value ) {+ var hooks, ret,+ nType = elem.nodeType;++ // don't get/set attributes on text, comment and attribute nodes+ if ( !elem || nType === 3 || nType === 8 || nType === 2 ) {+ return;+ }++ // Fallback to prop when attributes are not supported+ if ( typeof elem.getAttribute === strundefined ) {+ return jQuery.prop( elem, name, value );+ }++ // All attributes are lowercase+ // Grab necessary hook if one is defined+ if ( nType !== 1 || !jQuery.isXMLDoc( elem ) ) {+ name = name.toLowerCase();+ hooks = jQuery.attrHooks[ name ] ||+ ( jQuery.expr.match.bool.test( name ) ? boolHook : nodeHook );+ }++ if ( value !== undefined ) {++ if ( value === null ) {+ jQuery.removeAttr( elem, name );++ } else if ( hooks && "set" in hooks && (ret = hooks.set( elem, value, name )) !== undefined ) {+ return ret;++ } else {+ elem.setAttribute( name, value + "" );+ return value;+ }++ } else if ( hooks && "get" in hooks && (ret = hooks.get( elem, name )) !== null ) {+ return ret;++ } else {+ ret = jQuery.find.attr( elem, name );++ // Non-existent attributes return null, we normalize to undefined+ return ret == null ?+ undefined :+ ret;+ }+ },++ removeAttr: function( elem, value ) {+ var name, propName,+ i = 0,+ attrNames = value && value.match( rnotwhite );++ if ( attrNames && elem.nodeType === 1 ) {+ while ( (name = attrNames[i++]) ) {+ propName = jQuery.propFix[ name ] || name;++ // Boolean attributes get special treatment (#10870)+ if ( jQuery.expr.match.bool.test( name ) ) {+ // Set corresponding property to false+ if ( getSetInput && getSetAttribute || !ruseDefault.test( name ) ) {+ elem[ propName ] = false;+ // Support: IE<9+ // Also clear defaultChecked/defaultSelected (if appropriate)+ } else {+ elem[ jQuery.camelCase( "default-" + name ) ] =+ elem[ propName ] = false;+ }++ // See #9699 for explanation of this approach (setting first, then removal)+ } else {+ jQuery.attr( elem, name, "" );+ }++ elem.removeAttribute( getSetAttribute ? name : propName );+ }+ }+ },++ attrHooks: {+ type: {+ set: function( elem, value ) {+ if ( !support.radioValue && value === "radio" && jQuery.nodeName(elem, "input") ) {+ // Setting the type on a radio button after the value resets the value in IE6-9+ // Reset value to default in case type is set after value during creation+ var val = elem.value;+ elem.setAttribute( "type", value );+ if ( val ) {+ elem.value = val;+ }+ return value;+ }+ }+ }+ }+});++// Hook for boolean attributes+boolHook = {+ set: function( elem, value, name ) {+ if ( value === false ) {+ // Remove boolean attributes when set to false+ jQuery.removeAttr( elem, name );+ } else if ( getSetInput && getSetAttribute || !ruseDefault.test( name ) ) {+ // IE<8 needs the *property* name+ elem.setAttribute( !getSetAttribute && jQuery.propFix[ name ] || name, name );++ // Use defaultChecked and defaultSelected for oldIE+ } else {+ elem[ jQuery.camelCase( "default-" + name ) ] = elem[ name ] = true;+ }++ return name;+ }+};++// Retrieve booleans specially+jQuery.each( jQuery.expr.match.bool.source.match( /\w+/g ), function( i, name ) {++ var getter = attrHandle[ name ] || jQuery.find.attr;++ attrHandle[ name ] = getSetInput && getSetAttribute || !ruseDefault.test( name ) ?+ function( elem, name, isXML ) {+ var ret, handle;+ if ( !isXML ) {+ // Avoid an infinite loop by temporarily removing this function from the getter+ handle = attrHandle[ name ];+ attrHandle[ name ] = ret;+ ret = getter( elem, name, isXML ) != null ?+ name.toLowerCase() :+ null;+ attrHandle[ name ] = handle;+ }+ return ret;+ } :+ function( elem, name, isXML ) {+ if ( !isXML ) {+ return elem[ jQuery.camelCase( "default-" + name ) ] ?+ name.toLowerCase() :+ null;+ }+ };+});++// fix oldIE attroperties+if ( !getSetInput || !getSetAttribute ) {+ jQuery.attrHooks.value = {+ set: function( elem, value, name ) {+ if ( jQuery.nodeName( elem, "input" ) ) {+ // Does not return so that setAttribute is also used+ elem.defaultValue = value;+ } else {+ // Use nodeHook if defined (#1954); otherwise setAttribute is fine+ return nodeHook && nodeHook.set( elem, value, name );+ }+ }+ };+}++// IE6/7 do not support getting/setting some attributes with get/setAttribute+if ( !getSetAttribute ) {++ // Use this for any attribute in IE6/7+ // This fixes almost every IE6/7 issue+ nodeHook = {+ set: function( elem, value, name ) {+ // Set the existing or create a new attribute node+ var ret = elem.getAttributeNode( name );+ if ( !ret ) {+ elem.setAttributeNode(+ (ret = elem.ownerDocument.createAttribute( name ))+ );+ }++ ret.value = value += "";++ // Break association with cloned elements by also using setAttribute (#9646)+ if ( name === "value" || value === elem.getAttribute( name ) ) {+ return value;+ }+ }+ };++ // Some attributes are constructed with empty-string values when not defined+ attrHandle.id = attrHandle.name = attrHandle.coords =+ function( elem, name, isXML ) {+ var ret;+ if ( !isXML ) {+ return (ret = elem.getAttributeNode( name )) && ret.value !== "" ?+ ret.value :+ null;+ }+ };++ // Fixing value retrieval on a button requires this module+ jQuery.valHooks.button = {+ get: function( elem, name ) {+ var ret = elem.getAttributeNode( name );+ if ( ret && ret.specified ) {+ return ret.value;+ }+ },+ set: nodeHook.set+ };++ // Set contenteditable to false on removals(#10429)+ // Setting to empty string throws an error as an invalid value+ jQuery.attrHooks.contenteditable = {+ set: function( elem, value, name ) {+ nodeHook.set( elem, value === "" ? false : value, name );+ }+ };++ // Set width and height to auto instead of 0 on empty string( Bug #8150 )+ // This is for removals+ jQuery.each([ "width", "height" ], function( i, name ) {+ jQuery.attrHooks[ name ] = {+ set: function( elem, value ) {+ if ( value === "" ) {+ elem.setAttribute( name, "auto" );+ return value;+ }+ }+ };+ });+}++if ( !support.style ) {+ jQuery.attrHooks.style = {+ get: function( elem ) {+ // Return undefined in the case of empty string+ // Note: IE uppercases css property names, but if we were to .toLowerCase()+ // .cssText, that would destroy case senstitivity in URL's, like in "background"+ return elem.style.cssText || undefined;+ },+ set: function( elem, value ) {+ return ( elem.style.cssText = value + "" );+ }+ };+}+++++var rfocusable = /^(?:input|select|textarea|button|object)$/i,+ rclickable = /^(?:a|area)$/i;++jQuery.fn.extend({+ prop: function( name, value ) {+ return access( this, jQuery.prop, name, value, arguments.length > 1 );+ },++ removeProp: function( name ) {+ name = jQuery.propFix[ name ] || name;+ return this.each(function() {+ // try/catch handles cases where IE balks (such as removing a property on window)+ try {+ this[ name ] = undefined;+ delete this[ name ];+ } catch( e ) {}+ });+ }+});++jQuery.extend({+ propFix: {+ "for": "htmlFor",+ "class": "className"+ },++ prop: function( elem, name, value ) {+ var ret, hooks, notxml,+ nType = elem.nodeType;++ // don't get/set properties on text, comment and attribute nodes+ if ( !elem || nType === 3 || nType === 8 || nType === 2 ) {+ return;+ }++ notxml = nType !== 1 || !jQuery.isXMLDoc( elem );++ if ( notxml ) {+ // Fix name and attach hooks+ name = jQuery.propFix[ name ] || name;+ hooks = jQuery.propHooks[ name ];+ }++ if ( value !== undefined ) {+ return hooks && "set" in hooks && (ret = hooks.set( elem, value, name )) !== undefined ?+ ret :+ ( elem[ name ] = value );++ } else {+ return hooks && "get" in hooks && (ret = hooks.get( elem, name )) !== null ?+ ret :+ elem[ name ];+ }+ },++ propHooks: {+ tabIndex: {+ get: function( elem ) {+ // elem.tabIndex doesn't always return the correct value when it hasn't been explicitly set+ // http://fluidproject.org/blog/2008/01/09/getting-setting-and-removing-tabindex-values-with-javascript/+ // Use proper attribute retrieval(#12072)+ var tabindex = jQuery.find.attr( elem, "tabindex" );++ return tabindex ?+ parseInt( tabindex, 10 ) :+ rfocusable.test( elem.nodeName ) || rclickable.test( elem.nodeName ) && elem.href ?+ 0 :+ -1;+ }+ }+ }+});++// Some attributes require a special call on IE+// http://msdn.microsoft.com/en-us/library/ms536429%28VS.85%29.aspx+if ( !support.hrefNormalized ) {+ // href/src property should get the full normalized URL (#10299/#12915)+ jQuery.each([ "href", "src" ], function( i, name ) {+ jQuery.propHooks[ name ] = {+ get: function( elem ) {+ return elem.getAttribute( name, 4 );+ }+ };+ });+}++// Support: Safari, IE9++// mis-reports the default selected property of an option+// Accessing the parent's selectedIndex property fixes it+if ( !support.optSelected ) {+ jQuery.propHooks.selected = {+ get: function( elem ) {+ var parent = elem.parentNode;++ if ( parent ) {+ parent.selectedIndex;++ // Make sure that it also works with optgroups, see #5701+ if ( parent.parentNode ) {+ parent.parentNode.selectedIndex;+ }+ }+ return null;+ }+ };+}++jQuery.each([+ "tabIndex",+ "readOnly",+ "maxLength",+ "cellSpacing",+ "cellPadding",+ "rowSpan",+ "colSpan",+ "useMap",+ "frameBorder",+ "contentEditable"+], function() {+ jQuery.propFix[ this.toLowerCase() ] = this;+});++// IE6/7 call enctype encoding+if ( !support.enctype ) {+ jQuery.propFix.enctype = "encoding";+}+++++var rclass = /[\t\r\n\f]/g;++jQuery.fn.extend({+ addClass: function( value ) {+ var classes, elem, cur, clazz, j, finalValue,+ i = 0,+ len = this.length,+ proceed = typeof value === "string" && value;++ if ( jQuery.isFunction( value ) ) {+ return this.each(function( j ) {+ jQuery( this ).addClass( value.call( this, j, this.className ) );+ });+ }++ if ( proceed ) {+ // The disjunction here is for better compressibility (see removeClass)+ classes = ( value || "" ).match( rnotwhite ) || [];++ for ( ; i < len; i++ ) {+ elem = this[ i ];+ cur = elem.nodeType === 1 && ( elem.className ?+ ( " " + elem.className + " " ).replace( rclass, " " ) :+ " "+ );++ if ( cur ) {+ j = 0;+ while ( (clazz = classes[j++]) ) {+ if ( cur.indexOf( " " + clazz + " " ) < 0 ) {+ cur += clazz + " ";+ }+ }++ // only assign if different to avoid unneeded rendering.+ finalValue = jQuery.trim( cur );+ if ( elem.className !== finalValue ) {+ elem.className = finalValue;+ }+ }+ }+ }++ return this;+ },++ removeClass: function( value ) {+ var classes, elem, cur, clazz, j, finalValue,+ i = 0,+ len = this.length,+ proceed = arguments.length === 0 || typeof value === "string" && value;++ if ( jQuery.isFunction( value ) ) {+ return this.each(function( j ) {+ jQuery( this ).removeClass( value.call( this, j, this.className ) );+ });+ }+ if ( proceed ) {+ classes = ( value || "" ).match( rnotwhite ) || [];++ for ( ; i < len; i++ ) {+ elem = this[ i ];+ // This expression is here for better compressibility (see addClass)+ cur = elem.nodeType === 1 && ( elem.className ?+ ( " " + elem.className + " " ).replace( rclass, " " ) :+ ""+ );++ if ( cur ) {+ j = 0;+ while ( (clazz = classes[j++]) ) {+ // Remove *all* instances+ while ( cur.indexOf( " " + clazz + " " ) >= 0 ) {+ cur = cur.replace( " " + clazz + " ", " " );+ }+ }++ // only assign if different to avoid unneeded rendering.+ finalValue = value ? jQuery.trim( cur ) : "";+ if ( elem.className !== finalValue ) {+ elem.className = finalValue;+ }+ }+ }+ }++ return this;+ },++ toggleClass: function( value, stateVal ) {+ var type = typeof value;++ if ( typeof stateVal === "boolean" && type === "string" ) {+ return stateVal ? this.addClass( value ) : this.removeClass( value );+ }++ if ( jQuery.isFunction( value ) ) {+ return this.each(function( i ) {+ jQuery( this ).toggleClass( value.call(this, i, this.className, stateVal), stateVal );+ });+ }++ return this.each(function() {+ if ( type === "string" ) {+ // toggle individual class names+ var className,+ i = 0,+ self = jQuery( this ),+ classNames = value.match( rnotwhite ) || [];++ while ( (className = classNames[ i++ ]) ) {+ // check each className given, space separated list+ if ( self.hasClass( className ) ) {+ self.removeClass( className );+ } else {+ self.addClass( className );+ }+ }++ // Toggle whole class name+ } else if ( type === strundefined || type === "boolean" ) {+ if ( this.className ) {+ // store className if set+ jQuery._data( this, "__className__", this.className );+ }++ // If the element has a class name or if we're passed "false",+ // then remove the whole classname (if there was one, the above saved it).+ // Otherwise bring back whatever was previously saved (if anything),+ // falling back to the empty string if nothing was stored.+ this.className = this.className || value === false ? "" : jQuery._data( this, "__className__" ) || "";+ }+ });+ },++ hasClass: function( selector ) {+ var className = " " + selector + " ",+ i = 0,+ l = this.length;+ for ( ; i < l; i++ ) {+ if ( this[i].nodeType === 1 && (" " + this[i].className + " ").replace(rclass, " ").indexOf( className ) >= 0 ) {+ return true;+ }+ }++ return false;+ }+});+++++// Return jQuery for attributes-only inclusion+++jQuery.each( ("blur focus focusin focusout load resize scroll unload click dblclick " ++ "mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave " ++ "change select submit keydown keypress keyup error contextmenu").split(" "), function( i, name ) {++ // Handle event binding+ jQuery.fn[ name ] = function( data, fn ) {+ return arguments.length > 0 ?+ this.on( name, null, data, fn ) :+ this.trigger( name );+ };+});++jQuery.fn.extend({+ hover: function( fnOver, fnOut ) {+ return this.mouseenter( fnOver ).mouseleave( fnOut || fnOver );+ },++ bind: function( types, data, fn ) {+ return this.on( types, null, data, fn );+ },+ unbind: function( types, fn ) {+ return this.off( types, null, fn );+ },++ delegate: function( selector, types, data, fn ) {+ return this.on( types, selector, data, fn );+ },+ undelegate: function( selector, types, fn ) {+ // ( namespace ) or ( selector, types [, fn] )+ return arguments.length === 1 ? this.off( selector, "**" ) : this.off( types, selector || "**", fn );+ }+});+++var nonce = jQuery.now();++var rquery = (/\?/);++++var rvalidtokens = /(,)|(\[|{)|(}|])|"(?:[^"\\\r\n]|\\["\\\/bfnrt]|\\u[\da-fA-F]{4})*"\s*:?|true|false|null|-?(?!0\d)\d+(?:\.\d+|)(?:[eE][+-]?\d+|)/g;++jQuery.parseJSON = function( data ) {+ // Attempt to parse using the native JSON parser first+ if ( window.JSON && window.JSON.parse ) {+ // Support: Android 2.3+ // Workaround failure to string-cast null input+ return window.JSON.parse( data + "" );+ }++ var requireNonComma,+ depth = null,+ str = jQuery.trim( data + "" );++ // Guard against invalid (and possibly dangerous) input by ensuring that nothing remains+ // after removing valid tokens+ return str && !jQuery.trim( str.replace( rvalidtokens, function( token, comma, open, close ) {++ // Force termination if we see a misplaced comma+ if ( requireNonComma && comma ) {+ depth = 0;+ }++ // Perform no more replacements after returning to outermost depth+ if ( depth === 0 ) {+ return token;+ }++ // Commas must not follow "[", "{", or ","+ requireNonComma = open || comma;++ // Determine new depth+ // array/object open ("[" or "{"): depth += true - false (increment)+ // array/object close ("]" or "}"): depth += false - true (decrement)+ // other cases ("," or primitive): depth += true - true (numeric cast)+ depth += !close - !open;++ // Remove this token+ return "";+ }) ) ?+ ( Function( "return " + str ) )() :+ jQuery.error( "Invalid JSON: " + data );+};+++// Cross-browser xml parsing+jQuery.parseXML = function( data ) {+ var xml, tmp;+ if ( !data || typeof data !== "string" ) {+ return null;+ }+ try {+ if ( window.DOMParser ) { // Standard+ tmp = new DOMParser();+ xml = tmp.parseFromString( data, "text/xml" );+ } else { // IE+ xml = new ActiveXObject( "Microsoft.XMLDOM" );+ xml.async = "false";+ xml.loadXML( data );+ }+ } catch( e ) {+ xml = undefined;+ }+ if ( !xml || !xml.documentElement || xml.getElementsByTagName( "parsererror" ).length ) {+ jQuery.error( "Invalid XML: " + data );+ }+ return xml;+};+++var+ // Document location+ ajaxLocParts,+ ajaxLocation,++ rhash = /#.*$/,+ rts = /([?&])_=[^&]*/,+ rheaders = /^(.*?):[ \t]*([^\r\n]*)\r?$/mg, // IE leaves an \r character at EOL+ // #7653, #8125, #8152: local protocol detection+ rlocalProtocol = /^(?:about|app|app-storage|.+-extension|file|res|widget):$/,+ rnoContent = /^(?:GET|HEAD)$/,+ rprotocol = /^\/\//,+ rurl = /^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/,++ /* Prefilters+ * 1) They are useful to introduce custom dataTypes (see ajax/jsonp.js for an example)+ * 2) These are called:+ * - BEFORE asking for a transport+ * - AFTER param serialization (s.data is a string if s.processData is true)+ * 3) key is the dataType+ * 4) the catchall symbol "*" can be used+ * 5) execution will start with transport dataType and THEN continue down to "*" if needed+ */+ prefilters = {},++ /* Transports bindings+ * 1) key is the dataType+ * 2) the catchall symbol "*" can be used+ * 3) selection will start with transport dataType and THEN go to "*" if needed+ */+ transports = {},++ // Avoid comment-prolog char sequence (#10098); must appease lint and evade compression+ allTypes = "*/".concat("*");++// #8138, IE may throw an exception when accessing+// a field from window.location if document.domain has been set+try {+ ajaxLocation = location.href;+} catch( e ) {+ // Use the href attribute of an A element+ // since IE will modify it given document.location+ ajaxLocation = document.createElement( "a" );+ ajaxLocation.href = "";+ ajaxLocation = ajaxLocation.href;+}++// Segment location into parts+ajaxLocParts = rurl.exec( ajaxLocation.toLowerCase() ) || [];++// Base "constructor" for jQuery.ajaxPrefilter and jQuery.ajaxTransport+function addToPrefiltersOrTransports( structure ) {++ // dataTypeExpression is optional and defaults to "*"+ return function( dataTypeExpression, func ) {++ if ( typeof dataTypeExpression !== "string" ) {+ func = dataTypeExpression;+ dataTypeExpression = "*";+ }++ var dataType,+ i = 0,+ dataTypes = dataTypeExpression.toLowerCase().match( rnotwhite ) || [];++ if ( jQuery.isFunction( func ) ) {+ // For each dataType in the dataTypeExpression+ while ( (dataType = dataTypes[i++]) ) {+ // Prepend if requested+ if ( dataType.charAt( 0 ) === "+" ) {+ dataType = dataType.slice( 1 ) || "*";+ (structure[ dataType ] = structure[ dataType ] || []).unshift( func );++ // Otherwise append+ } else {+ (structure[ dataType ] = structure[ dataType ] || []).push( func );+ }+ }+ }+ };+}++// Base inspection function for prefilters and transports+function inspectPrefiltersOrTransports( structure, options, originalOptions, jqXHR ) {++ var inspected = {},+ seekingTransport = ( structure === transports );++ function inspect( dataType ) {+ var selected;+ inspected[ dataType ] = true;+ jQuery.each( structure[ dataType ] || [], function( _, prefilterOrFactory ) {+ var dataTypeOrTransport = prefilterOrFactory( options, originalOptions, jqXHR );+ if ( typeof dataTypeOrTransport === "string" && !seekingTransport && !inspected[ dataTypeOrTransport ] ) {+ options.dataTypes.unshift( dataTypeOrTransport );+ inspect( dataTypeOrTransport );+ return false;+ } else if ( seekingTransport ) {+ return !( selected = dataTypeOrTransport );+ }+ });+ return selected;+ }++ return inspect( options.dataTypes[ 0 ] ) || !inspected[ "*" ] && inspect( "*" );+}++// A special extend for ajax options+// that takes "flat" options (not to be deep extended)+// Fixes #9887+function ajaxExtend( target, src ) {+ var deep, key,+ flatOptions = jQuery.ajaxSettings.flatOptions || {};++ for ( key in src ) {+ if ( src[ key ] !== undefined ) {+ ( flatOptions[ key ] ? target : ( deep || (deep = {}) ) )[ key ] = src[ key ];+ }+ }+ if ( deep ) {+ jQuery.extend( true, target, deep );+ }++ return target;+}++/* Handles responses to an ajax request:+ * - finds the right dataType (mediates between content-type and expected dataType)+ * - returns the corresponding response+ */+function ajaxHandleResponses( s, jqXHR, responses ) {+ var firstDataType, ct, finalDataType, type,+ contents = s.contents,+ dataTypes = s.dataTypes;++ // Remove auto dataType and get content-type in the process+ while ( dataTypes[ 0 ] === "*" ) {+ dataTypes.shift();+ if ( ct === undefined ) {+ ct = s.mimeType || jqXHR.getResponseHeader("Content-Type");+ }+ }++ // Check if we're dealing with a known content-type+ if ( ct ) {+ for ( type in contents ) {+ if ( contents[ type ] && contents[ type ].test( ct ) ) {+ dataTypes.unshift( type );+ break;+ }+ }+ }++ // Check to see if we have a response for the expected dataType+ if ( dataTypes[ 0 ] in responses ) {+ finalDataType = dataTypes[ 0 ];+ } else {+ // Try convertible dataTypes+ for ( type in responses ) {+ if ( !dataTypes[ 0 ] || s.converters[ type + " " + dataTypes[0] ] ) {+ finalDataType = type;+ break;+ }+ if ( !firstDataType ) {+ firstDataType = type;+ }+ }+ // Or just use first one+ finalDataType = finalDataType || firstDataType;+ }++ // If we found a dataType+ // We add the dataType to the list if needed+ // and return the corresponding response+ if ( finalDataType ) {+ if ( finalDataType !== dataTypes[ 0 ] ) {+ dataTypes.unshift( finalDataType );+ }+ return responses[ finalDataType ];+ }+}++/* Chain conversions given the request and the original response+ * Also sets the responseXXX fields on the jqXHR instance+ */+function ajaxConvert( s, response, jqXHR, isSuccess ) {+ var conv2, current, conv, tmp, prev,+ converters = {},+ // Work with a copy of dataTypes in case we need to modify it for conversion+ dataTypes = s.dataTypes.slice();++ // Create converters map with lowercased keys+ if ( dataTypes[ 1 ] ) {+ for ( conv in s.converters ) {+ converters[ conv.toLowerCase() ] = s.converters[ conv ];+ }+ }++ current = dataTypes.shift();++ // Convert to each sequential dataType+ while ( current ) {++ if ( s.responseFields[ current ] ) {+ jqXHR[ s.responseFields[ current ] ] = response;+ }++ // Apply the dataFilter if provided+ if ( !prev && isSuccess && s.dataFilter ) {+ response = s.dataFilter( response, s.dataType );+ }++ prev = current;+ current = dataTypes.shift();++ if ( current ) {++ // There's only work to do if current dataType is non-auto+ if ( current === "*" ) {++ current = prev;++ // Convert response if prev dataType is non-auto and differs from current+ } else if ( prev !== "*" && prev !== current ) {++ // Seek a direct converter+ conv = converters[ prev + " " + current ] || converters[ "* " + current ];++ // If none found, seek a pair+ if ( !conv ) {+ for ( conv2 in converters ) {++ // If conv2 outputs current+ tmp = conv2.split( " " );+ if ( tmp[ 1 ] === current ) {++ // If prev can be converted to accepted input+ conv = converters[ prev + " " + tmp[ 0 ] ] ||+ converters[ "* " + tmp[ 0 ] ];+ if ( conv ) {+ // Condense equivalence converters+ if ( conv === true ) {+ conv = converters[ conv2 ];++ // Otherwise, insert the intermediate dataType+ } else if ( converters[ conv2 ] !== true ) {+ current = tmp[ 0 ];+ dataTypes.unshift( tmp[ 1 ] );+ }+ break;+ }+ }+ }+ }++ // Apply converter (if not an equivalence)+ if ( conv !== true ) {++ // Unless errors are allowed to bubble, catch and return them+ if ( conv && s[ "throws" ] ) {+ response = conv( response );+ } else {+ try {+ response = conv( response );+ } catch ( e ) {+ return { state: "parsererror", error: conv ? e : "No conversion from " + prev + " to " + current };+ }+ }+ }+ }+ }+ }++ return { state: "success", data: response };+}++jQuery.extend({++ // Counter for holding the number of active queries+ active: 0,++ // Last-Modified header cache for next request+ lastModified: {},+ etag: {},++ ajaxSettings: {+ url: ajaxLocation,+ type: "GET",+ isLocal: rlocalProtocol.test( ajaxLocParts[ 1 ] ),+ global: true,+ processData: true,+ async: true,+ contentType: "application/x-www-form-urlencoded; charset=UTF-8",+ /*+ timeout: 0,+ data: null,+ dataType: null,+ username: null,+ password: null,+ cache: null,+ throws: false,+ traditional: false,+ headers: {},+ */++ accepts: {+ "*": allTypes,+ text: "text/plain",+ html: "text/html",+ xml: "application/xml, text/xml",+ json: "application/json, text/javascript"+ },++ contents: {+ xml: /xml/,+ html: /html/,+ json: /json/+ },++ responseFields: {+ xml: "responseXML",+ text: "responseText",+ json: "responseJSON"+ },++ // Data converters+ // Keys separate source (or catchall "*") and destination types with a single space+ converters: {++ // Convert anything to text+ "* text": String,++ // Text to html (true = no transformation)+ "text html": true,++ // Evaluate text as a json expression+ "text json": jQuery.parseJSON,++ // Parse text as xml+ "text xml": jQuery.parseXML+ },++ // For options that shouldn't be deep extended:+ // you can add your own custom options here if+ // and when you create one that shouldn't be+ // deep extended (see ajaxExtend)+ flatOptions: {+ url: true,+ context: true+ }+ },++ // Creates a full fledged settings object into target+ // with both ajaxSettings and settings fields.+ // If target is omitted, writes into ajaxSettings.+ ajaxSetup: function( target, settings ) {+ return settings ?++ // Building a settings object+ ajaxExtend( ajaxExtend( target, jQuery.ajaxSettings ), settings ) :++ // Extending ajaxSettings+ ajaxExtend( jQuery.ajaxSettings, target );+ },++ ajaxPrefilter: addToPrefiltersOrTransports( prefilters ),+ ajaxTransport: addToPrefiltersOrTransports( transports ),++ // Main method+ ajax: function( url, options ) {++ // If url is an object, simulate pre-1.5 signature+ if ( typeof url === "object" ) {+ options = url;+ url = undefined;+ }++ // Force options to be an object+ options = options || {};++ var // Cross-domain detection vars+ parts,+ // Loop variable+ i,+ // URL without anti-cache param+ cacheURL,+ // Response headers as string+ responseHeadersString,+ // timeout handle+ timeoutTimer,++ // To know if global events are to be dispatched+ fireGlobals,++ transport,+ // Response headers+ responseHeaders,+ // Create the final options object+ s = jQuery.ajaxSetup( {}, options ),+ // Callbacks context+ callbackContext = s.context || s,+ // Context for global events is callbackContext if it is a DOM node or jQuery collection+ globalEventContext = s.context && ( callbackContext.nodeType || callbackContext.jquery ) ?+ jQuery( callbackContext ) :+ jQuery.event,+ // Deferreds+ deferred = jQuery.Deferred(),+ completeDeferred = jQuery.Callbacks("once memory"),+ // Status-dependent callbacks+ statusCode = s.statusCode || {},+ // Headers (they are sent all at once)+ requestHeaders = {},+ requestHeadersNames = {},+ // The jqXHR state+ state = 0,+ // Default abort message+ strAbort = "canceled",+ // Fake xhr+ jqXHR = {+ readyState: 0,++ // Builds headers hashtable if needed+ getResponseHeader: function( key ) {+ var match;+ if ( state === 2 ) {+ if ( !responseHeaders ) {+ responseHeaders = {};+ while ( (match = rheaders.exec( responseHeadersString )) ) {+ responseHeaders[ match[1].toLowerCase() ] = match[ 2 ];+ }+ }+ match = responseHeaders[ key.toLowerCase() ];+ }+ return match == null ? null : match;+ },++ // Raw string+ getAllResponseHeaders: function() {+ return state === 2 ? responseHeadersString : null;+ },++ // Caches the header+ setRequestHeader: function( name, value ) {+ var lname = name.toLowerCase();+ if ( !state ) {+ name = requestHeadersNames[ lname ] = requestHeadersNames[ lname ] || name;+ requestHeaders[ name ] = value;+ }+ return this;+ },++ // Overrides response content-type header+ overrideMimeType: function( type ) {+ if ( !state ) {+ s.mimeType = type;+ }+ return this;+ },++ // Status-dependent callbacks+ statusCode: function( map ) {+ var code;+ if ( map ) {+ if ( state < 2 ) {+ for ( code in map ) {+ // Lazy-add the new callback in a way that preserves old ones+ statusCode[ code ] = [ statusCode[ code ], map[ code ] ];+ }+ } else {+ // Execute the appropriate callbacks+ jqXHR.always( map[ jqXHR.status ] );+ }+ }+ return this;+ },++ // Cancel the request+ abort: function( statusText ) {+ var finalText = statusText || strAbort;+ if ( transport ) {+ transport.abort( finalText );+ }+ done( 0, finalText );+ return this;+ }+ };++ // Attach deferreds+ deferred.promise( jqXHR ).complete = completeDeferred.add;+ jqXHR.success = jqXHR.done;+ jqXHR.error = jqXHR.fail;++ // Remove hash character (#7531: and string promotion)+ // Add protocol if not provided (#5866: IE7 issue with protocol-less urls)+ // Handle falsy url in the settings object (#10093: consistency with old signature)+ // We also use the url parameter if available+ s.url = ( ( url || s.url || ajaxLocation ) + "" ).replace( rhash, "" ).replace( rprotocol, ajaxLocParts[ 1 ] + "//" );++ // Alias method option to type as per ticket #12004+ s.type = options.method || options.type || s.method || s.type;++ // Extract dataTypes list+ s.dataTypes = jQuery.trim( s.dataType || "*" ).toLowerCase().match( rnotwhite ) || [ "" ];++ // A cross-domain request is in order when we have a protocol:host:port mismatch+ if ( s.crossDomain == null ) {+ parts = rurl.exec( s.url.toLowerCase() );+ s.crossDomain = !!( parts &&+ ( parts[ 1 ] !== ajaxLocParts[ 1 ] || parts[ 2 ] !== ajaxLocParts[ 2 ] ||+ ( parts[ 3 ] || ( parts[ 1 ] === "http:" ? "80" : "443" ) ) !==+ ( ajaxLocParts[ 3 ] || ( ajaxLocParts[ 1 ] === "http:" ? "80" : "443" ) ) )+ );+ }++ // Convert data if not already a string+ if ( s.data && s.processData && typeof s.data !== "string" ) {+ s.data = jQuery.param( s.data, s.traditional );+ }++ // Apply prefilters+ inspectPrefiltersOrTransports( prefilters, s, options, jqXHR );++ // If request was aborted inside a prefilter, stop there+ if ( state === 2 ) {+ return jqXHR;+ }++ // We can fire global events as of now if asked to+ fireGlobals = s.global;++ // Watch for a new set of requests+ if ( fireGlobals && jQuery.active++ === 0 ) {+ jQuery.event.trigger("ajaxStart");+ }++ // Uppercase the type+ s.type = s.type.toUpperCase();++ // Determine if request has content+ s.hasContent = !rnoContent.test( s.type );++ // Save the URL in case we're toying with the If-Modified-Since+ // and/or If-None-Match header later on+ cacheURL = s.url;++ // More options handling for requests with no content+ if ( !s.hasContent ) {++ // If data is available, append data to url+ if ( s.data ) {+ cacheURL = ( s.url += ( rquery.test( cacheURL ) ? "&" : "?" ) + s.data );+ // #9682: remove data so that it's not used in an eventual retry+ delete s.data;+ }++ // Add anti-cache in url if needed+ if ( s.cache === false ) {+ s.url = rts.test( cacheURL ) ?++ // If there is already a '_' parameter, set its value+ cacheURL.replace( rts, "$1_=" + nonce++ ) :++ // Otherwise add one to the end+ cacheURL + ( rquery.test( cacheURL ) ? "&" : "?" ) + "_=" + nonce++;+ }+ }++ // Set the If-Modified-Since and/or If-None-Match header, if in ifModified mode.+ if ( s.ifModified ) {+ if ( jQuery.lastModified[ cacheURL ] ) {+ jqXHR.setRequestHeader( "If-Modified-Since", jQuery.lastModified[ cacheURL ] );+ }+ if ( jQuery.etag[ cacheURL ] ) {+ jqXHR.setRequestHeader( "If-None-Match", jQuery.etag[ cacheURL ] );+ }+ }++ // Set the correct header, if data is being sent+ if ( s.data && s.hasContent && s.contentType !== false || options.contentType ) {+ jqXHR.setRequestHeader( "Content-Type", s.contentType );+ }++ // Set the Accepts header for the server, depending on the dataType+ jqXHR.setRequestHeader(+ "Accept",+ s.dataTypes[ 0 ] && s.accepts[ s.dataTypes[0] ] ?+ s.accepts[ s.dataTypes[0] ] + ( s.dataTypes[ 0 ] !== "*" ? ", " + allTypes + "; q=0.01" : "" ) :+ s.accepts[ "*" ]+ );++ // Check for headers option+ for ( i in s.headers ) {+ jqXHR.setRequestHeader( i, s.headers[ i ] );+ }++ // Allow custom headers/mimetypes and early abort+ if ( s.beforeSend && ( s.beforeSend.call( callbackContext, jqXHR, s ) === false || state === 2 ) ) {+ // Abort if not done already and return+ return jqXHR.abort();+ }++ // aborting is no longer a cancellation+ strAbort = "abort";++ // Install callbacks on deferreds+ for ( i in { success: 1, error: 1, complete: 1 } ) {+ jqXHR[ i ]( s[ i ] );+ }++ // Get transport+ transport = inspectPrefiltersOrTransports( transports, s, options, jqXHR );++ // If no transport, we auto-abort+ if ( !transport ) {+ done( -1, "No Transport" );+ } else {+ jqXHR.readyState = 1;++ // Send global event+ if ( fireGlobals ) {+ globalEventContext.trigger( "ajaxSend", [ jqXHR, s ] );+ }+ // Timeout+ if ( s.async && s.timeout > 0 ) {+ timeoutTimer = setTimeout(function() {+ jqXHR.abort("timeout");+ }, s.timeout );+ }++ try {+ state = 1;+ transport.send( requestHeaders, done );+ } catch ( e ) {+ // Propagate exception as error if not done+ if ( state < 2 ) {+ done( -1, e );+ // Simply rethrow otherwise+ } else {+ throw e;+ }+ }+ }++ // Callback for when everything is done+ function done( status, nativeStatusText, responses, headers ) {+ var isSuccess, success, error, response, modified,+ statusText = nativeStatusText;++ // Called once+ if ( state === 2 ) {+ return;+ }++ // State is "done" now+ state = 2;++ // Clear timeout if it exists+ if ( timeoutTimer ) {+ clearTimeout( timeoutTimer );+ }++ // Dereference transport for early garbage collection+ // (no matter how long the jqXHR object will be used)+ transport = undefined;++ // Cache response headers+ responseHeadersString = headers || "";++ // Set readyState+ jqXHR.readyState = status > 0 ? 4 : 0;++ // Determine if successful+ isSuccess = status >= 200 && status < 300 || status === 304;++ // Get response data+ if ( responses ) {+ response = ajaxHandleResponses( s, jqXHR, responses );+ }++ // Convert no matter what (that way responseXXX fields are always set)+ response = ajaxConvert( s, response, jqXHR, isSuccess );++ // If successful, handle type chaining+ if ( isSuccess ) {++ // Set the If-Modified-Since and/or If-None-Match header, if in ifModified mode.+ if ( s.ifModified ) {+ modified = jqXHR.getResponseHeader("Last-Modified");+ if ( modified ) {+ jQuery.lastModified[ cacheURL ] = modified;+ }+ modified = jqXHR.getResponseHeader("etag");+ if ( modified ) {+ jQuery.etag[ cacheURL ] = modified;+ }+ }++ // if no content+ if ( status === 204 || s.type === "HEAD" ) {+ statusText = "nocontent";++ // if not modified+ } else if ( status === 304 ) {+ statusText = "notmodified";++ // If we have data, let's convert it+ } else {+ statusText = response.state;+ success = response.data;+ error = response.error;+ isSuccess = !error;+ }+ } else {+ // We extract error from statusText+ // then normalize statusText and status for non-aborts+ error = statusText;+ if ( status || !statusText ) {+ statusText = "error";+ if ( status < 0 ) {+ status = 0;+ }+ }+ }++ // Set data for the fake xhr object+ jqXHR.status = status;+ jqXHR.statusText = ( nativeStatusText || statusText ) + "";++ // Success/Error+ if ( isSuccess ) {+ deferred.resolveWith( callbackContext, [ success, statusText, jqXHR ] );+ } else {+ deferred.rejectWith( callbackContext, [ jqXHR, statusText, error ] );+ }++ // Status-dependent callbacks+ jqXHR.statusCode( statusCode );+ statusCode = undefined;++ if ( fireGlobals ) {+ globalEventContext.trigger( isSuccess ? "ajaxSuccess" : "ajaxError",+ [ jqXHR, s, isSuccess ? success : error ] );+ }++ // Complete+ completeDeferred.fireWith( callbackContext, [ jqXHR, statusText ] );++ if ( fireGlobals ) {+ globalEventContext.trigger( "ajaxComplete", [ jqXHR, s ] );+ // Handle the global AJAX counter+ if ( !( --jQuery.active ) ) {+ jQuery.event.trigger("ajaxStop");+ }+ }+ }++ return jqXHR;+ },++ getJSON: function( url, data, callback ) {+ return jQuery.get( url, data, callback, "json" );+ },++ getScript: function( url, callback ) {+ return jQuery.get( url, undefined, callback, "script" );+ }+});++jQuery.each( [ "get", "post" ], function( i, method ) {+ jQuery[ method ] = function( url, data, callback, type ) {+ // shift arguments if data argument was omitted+ if ( jQuery.isFunction( data ) ) {+ type = type || callback;+ callback = data;+ data = undefined;+ }++ return jQuery.ajax({+ url: url,+ type: method,+ dataType: type,+ data: data,+ success: callback+ });+ };+});++// Attach a bunch of functions for handling common AJAX events+jQuery.each( [ "ajaxStart", "ajaxStop", "ajaxComplete", "ajaxError", "ajaxSuccess", "ajaxSend" ], function( i, type ) {+ jQuery.fn[ type ] = function( fn ) {+ return this.on( type, fn );+ };+});+++jQuery._evalUrl = function( url ) {+ return jQuery.ajax({+ url: url,+ type: "GET",+ dataType: "script",+ async: false,+ global: false,+ "throws": true+ });+};+++jQuery.fn.extend({+ wrapAll: function( html ) {+ if ( jQuery.isFunction( html ) ) {+ return this.each(function(i) {+ jQuery(this).wrapAll( html.call(this, i) );+ });+ }++ if ( this[0] ) {+ // The elements to wrap the target around+ var wrap = jQuery( html, this[0].ownerDocument ).eq(0).clone(true);++ if ( this[0].parentNode ) {+ wrap.insertBefore( this[0] );+ }++ wrap.map(function() {+ var elem = this;++ while ( elem.firstChild && elem.firstChild.nodeType === 1 ) {+ elem = elem.firstChild;+ }++ return elem;+ }).append( this );+ }++ return this;+ },++ wrapInner: function( html ) {+ if ( jQuery.isFunction( html ) ) {+ return this.each(function(i) {+ jQuery(this).wrapInner( html.call(this, i) );+ });+ }++ return this.each(function() {+ var self = jQuery( this ),+ contents = self.contents();++ if ( contents.length ) {+ contents.wrapAll( html );++ } else {+ self.append( html );+ }+ });+ },++ wrap: function( html ) {+ var isFunction = jQuery.isFunction( html );++ return this.each(function(i) {+ jQuery( this ).wrapAll( isFunction ? html.call(this, i) : html );+ });+ },++ unwrap: function() {+ return this.parent().each(function() {+ if ( !jQuery.nodeName( this, "body" ) ) {+ jQuery( this ).replaceWith( this.childNodes );+ }+ }).end();+ }+});+++jQuery.expr.filters.hidden = function( elem ) {+ // Support: Opera <= 12.12+ // Opera reports offsetWidths and offsetHeights less than zero on some elements+ return elem.offsetWidth <= 0 && elem.offsetHeight <= 0 ||+ (!support.reliableHiddenOffsets() &&+ ((elem.style && elem.style.display) || jQuery.css( elem, "display" )) === "none");+};++jQuery.expr.filters.visible = function( elem ) {+ return !jQuery.expr.filters.hidden( elem );+};+++++var r20 = /%20/g,+ rbracket = /\[\]$/,+ rCRLF = /\r?\n/g,+ rsubmitterTypes = /^(?:submit|button|image|reset|file)$/i,+ rsubmittable = /^(?:input|select|textarea|keygen)/i;++function buildParams( prefix, obj, traditional, add ) {+ var name;++ if ( jQuery.isArray( obj ) ) {+ // Serialize array item.+ jQuery.each( obj, function( i, v ) {+ if ( traditional || rbracket.test( prefix ) ) {+ // Treat each array item as a scalar.+ add( prefix, v );++ } else {+ // Item is non-scalar (array or object), encode its numeric index.+ buildParams( prefix + "[" + ( typeof v === "object" ? i : "" ) + "]", v, traditional, add );+ }+ });++ } else if ( !traditional && jQuery.type( obj ) === "object" ) {+ // Serialize object item.+ for ( name in obj ) {+ buildParams( prefix + "[" + name + "]", obj[ name ], traditional, add );+ }++ } else {+ // Serialize scalar item.+ add( prefix, obj );+ }+}++// Serialize an array of form elements or a set of+// key/values into a query string+jQuery.param = function( a, traditional ) {+ var prefix,+ s = [],+ add = function( key, value ) {+ // If value is a function, invoke it and return its value+ value = jQuery.isFunction( value ) ? value() : ( value == null ? "" : value );+ s[ s.length ] = encodeURIComponent( key ) + "=" + encodeURIComponent( value );+ };++ // Set traditional to true for jQuery <= 1.3.2 behavior.+ if ( traditional === undefined ) {+ traditional = jQuery.ajaxSettings && jQuery.ajaxSettings.traditional;+ }++ // If an array was passed in, assume that it is an array of form elements.+ if ( jQuery.isArray( a ) || ( a.jquery && !jQuery.isPlainObject( a ) ) ) {+ // Serialize the form elements+ jQuery.each( a, function() {+ add( this.name, this.value );+ });++ } else {+ // If traditional, encode the "old" way (the way 1.3.2 or older+ // did it), otherwise encode params recursively.+ for ( prefix in a ) {+ buildParams( prefix, a[ prefix ], traditional, add );+ }+ }++ // Return the resulting serialization+ return s.join( "&" ).replace( r20, "+" );+};++jQuery.fn.extend({+ serialize: function() {+ return jQuery.param( this.serializeArray() );+ },+ serializeArray: function() {+ return this.map(function() {+ // Can add propHook for "elements" to filter or add form elements+ var elements = jQuery.prop( this, "elements" );+ return elements ? jQuery.makeArray( elements ) : this;+ })+ .filter(function() {+ var type = this.type;+ // Use .is(":disabled") so that fieldset[disabled] works+ return this.name && !jQuery( this ).is( ":disabled" ) &&+ rsubmittable.test( this.nodeName ) && !rsubmitterTypes.test( type ) &&+ ( this.checked || !rcheckableType.test( type ) );+ })+ .map(function( i, elem ) {+ var val = jQuery( this ).val();++ return val == null ?+ null :+ jQuery.isArray( val ) ?+ jQuery.map( val, function( val ) {+ return { name: elem.name, value: val.replace( rCRLF, "\r\n" ) };+ }) :+ { name: elem.name, value: val.replace( rCRLF, "\r\n" ) };+ }).get();+ }+});+++// Create the request object+// (This is still attached to ajaxSettings for backward compatibility)+jQuery.ajaxSettings.xhr = window.ActiveXObject !== undefined ?+ // Support: IE6++ function() {++ // XHR cannot access local files, always use ActiveX for that case+ return !this.isLocal &&++ // Support: IE7-8+ // oldIE XHR does not support non-RFC2616 methods (#13240)+ // See http://msdn.microsoft.com/en-us/library/ie/ms536648(v=vs.85).aspx+ // and http://www.w3.org/Protocols/rfc2616/rfc2616-sec9.html#sec9+ // Although this check for six methods instead of eight+ // since IE also does not support "trace" and "connect"+ /^(get|post|head|put|delete|options)$/i.test( this.type ) &&++ createStandardXHR() || createActiveXHR();+ } :+ // For all other browsers, use the standard XMLHttpRequest object+ createStandardXHR;++var xhrId = 0,+ xhrCallbacks = {},+ xhrSupported = jQuery.ajaxSettings.xhr();++// Support: IE<10+// Open requests must be manually aborted on unload (#5280)+if ( window.ActiveXObject ) {+ jQuery( window ).on( "unload", function() {+ for ( var key in xhrCallbacks ) {+ xhrCallbacks[ key ]( undefined, true );+ }+ });+}++// Determine support properties+support.cors = !!xhrSupported && ( "withCredentials" in xhrSupported );+xhrSupported = support.ajax = !!xhrSupported;++// Create transport if the browser can provide an xhr+if ( xhrSupported ) {++ jQuery.ajaxTransport(function( options ) {+ // Cross domain only allowed if supported through XMLHttpRequest+ if ( !options.crossDomain || support.cors ) {++ var callback;++ return {+ send: function( headers, complete ) {+ var i,+ xhr = options.xhr(),+ id = ++xhrId;++ // Open the socket+ xhr.open( options.type, options.url, options.async, options.username, options.password );++ // Apply custom fields if provided+ if ( options.xhrFields ) {+ for ( i in options.xhrFields ) {+ xhr[ i ] = options.xhrFields[ i ];+ }+ }++ // Override mime type if needed+ if ( options.mimeType && xhr.overrideMimeType ) {+ xhr.overrideMimeType( options.mimeType );+ }++ // X-Requested-With header+ // For cross-domain requests, seeing as conditions for a preflight are+ // akin to a jigsaw puzzle, we simply never set it to be sure.+ // (it can always be set on a per-request basis or even using ajaxSetup)+ // For same-domain requests, won't change header if already provided.+ if ( !options.crossDomain && !headers["X-Requested-With"] ) {+ headers["X-Requested-With"] = "XMLHttpRequest";+ }++ // Set headers+ for ( i in headers ) {+ // Support: IE<9+ // IE's ActiveXObject throws a 'Type Mismatch' exception when setting+ // request header to a null-value.+ //+ // To keep consistent with other XHR implementations, cast the value+ // to string and ignore `undefined`.+ if ( headers[ i ] !== undefined ) {+ xhr.setRequestHeader( i, headers[ i ] + "" );+ }+ }++ // Do send the request+ // This may raise an exception which is actually+ // handled in jQuery.ajax (so no try/catch here)+ xhr.send( ( options.hasContent && options.data ) || null );++ // Listener+ callback = function( _, isAbort ) {+ var status, statusText, responses;++ // Was never called and is aborted or complete+ if ( callback && ( isAbort || xhr.readyState === 4 ) ) {+ // Clean up+ delete xhrCallbacks[ id ];+ callback = undefined;+ xhr.onreadystatechange = jQuery.noop;++ // Abort manually if needed+ if ( isAbort ) {+ if ( xhr.readyState !== 4 ) {+ xhr.abort();+ }+ } else {+ responses = {};+ status = xhr.status;++ // Support: IE<10+ // Accessing binary-data responseText throws an exception+ // (#11426)+ if ( typeof xhr.responseText === "string" ) {+ responses.text = xhr.responseText;+ }++ // Firefox throws an exception when accessing+ // statusText for faulty cross-domain requests+ try {+ statusText = xhr.statusText;+ } catch( e ) {+ // We normalize with Webkit giving an empty statusText+ statusText = "";+ }++ // Filter status for non standard behaviors++ // If the request is local and we have data: assume a success+ // (success with no data won't get notified, that's the best we+ // can do given current implementations)+ if ( !status && options.isLocal && !options.crossDomain ) {+ status = responses.text ? 200 : 404;+ // IE - #1450: sometimes returns 1223 when it should be 204+ } else if ( status === 1223 ) {+ status = 204;+ }+ }+ }++ // Call complete if needed+ if ( responses ) {+ complete( status, statusText, responses, xhr.getAllResponseHeaders() );+ }+ };++ if ( !options.async ) {+ // if we're in sync mode we fire the callback+ callback();+ } else if ( xhr.readyState === 4 ) {+ // (IE6 & IE7) if it's in cache and has been+ // retrieved directly we need to fire the callback+ setTimeout( callback );+ } else {+ // Add to the list of active xhr callbacks+ xhr.onreadystatechange = xhrCallbacks[ id ] = callback;+ }+ },++ abort: function() {+ if ( callback ) {+ callback( undefined, true );+ }+ }+ };+ }+ });+}++// Functions to create xhrs+function createStandardXHR() {+ try {+ return new window.XMLHttpRequest();+ } catch( e ) {}+}++function createActiveXHR() {+ try {+ return new window.ActiveXObject( "Microsoft.XMLHTTP" );+ } catch( e ) {}+}+++++// Install script dataType+jQuery.ajaxSetup({+ accepts: {+ script: "text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"+ },+ contents: {+ script: /(?:java|ecma)script/+ },+ converters: {+ "text script": function( text ) {+ jQuery.globalEval( text );+ return text;+ }+ }+});++// Handle cache's special case and global+jQuery.ajaxPrefilter( "script", function( s ) {+ if ( s.cache === undefined ) {+ s.cache = false;+ }+ if ( s.crossDomain ) {+ s.type = "GET";+ s.global = false;+ }+});++// Bind script tag hack transport+jQuery.ajaxTransport( "script", function(s) {++ // This transport only deals with cross domain requests+ if ( s.crossDomain ) {++ var script,+ head = document.head || jQuery("head")[0] || document.documentElement;++ return {++ send: function( _, callback ) {++ script = document.createElement("script");++ script.async = true;++ if ( s.scriptCharset ) {+ script.charset = s.scriptCharset;+ }++ script.src = s.url;++ // Attach handlers for all browsers+ script.onload = script.onreadystatechange = function( _, isAbort ) {++ if ( isAbort || !script.readyState || /loaded|complete/.test( script.readyState ) ) {++ // Handle memory leak in IE+ script.onload = script.onreadystatechange = null;++ // Remove the script+ if ( script.parentNode ) {+ script.parentNode.removeChild( script );+ }++ // Dereference the script+ script = null;++ // Callback if not abort+ if ( !isAbort ) {+ callback( 200, "success" );+ }+ }+ };++ // Circumvent IE6 bugs with base elements (#2709 and #4378) by prepending+ // Use native DOM manipulation to avoid our domManip AJAX trickery+ head.insertBefore( script, head.firstChild );+ },++ abort: function() {+ if ( script ) {+ script.onload( undefined, true );+ }+ }+ };+ }+});+++++var oldCallbacks = [],+ rjsonp = /(=)\?(?=&|$)|\?\?/;++// Default jsonp settings+jQuery.ajaxSetup({+ jsonp: "callback",+ jsonpCallback: function() {+ var callback = oldCallbacks.pop() || ( jQuery.expando + "_" + ( nonce++ ) );+ this[ callback ] = true;+ return callback;+ }+});++// Detect, normalize options and install callbacks for jsonp requests+jQuery.ajaxPrefilter( "json jsonp", function( s, originalSettings, jqXHR ) {++ var callbackName, overwritten, responseContainer,+ jsonProp = s.jsonp !== false && ( rjsonp.test( s.url ) ?+ "url" :+ typeof s.data === "string" && !( s.contentType || "" ).indexOf("application/x-www-form-urlencoded") && rjsonp.test( s.data ) && "data"+ );++ // Handle iff the expected data type is "jsonp" or we have a parameter to set+ if ( jsonProp || s.dataTypes[ 0 ] === "jsonp" ) {++ // Get callback name, remembering preexisting value associated with it+ callbackName = s.jsonpCallback = jQuery.isFunction( s.jsonpCallback ) ?+ s.jsonpCallback() :+ s.jsonpCallback;++ // Insert callback into url or form data+ if ( jsonProp ) {+ s[ jsonProp ] = s[ jsonProp ].replace( rjsonp, "$1" + callbackName );+ } else if ( s.jsonp !== false ) {+ s.url += ( rquery.test( s.url ) ? "&" : "?" ) + s.jsonp + "=" + callbackName;+ }++ // Use data converter to retrieve json after script execution+ s.converters["script json"] = function() {+ if ( !responseContainer ) {+ jQuery.error( callbackName + " was not called" );+ }+ return responseContainer[ 0 ];+ };++ // force json dataType+ s.dataTypes[ 0 ] = "json";++ // Install callback+ overwritten = window[ callbackName ];+ window[ callbackName ] = function() {+ responseContainer = arguments;+ };++ // Clean-up function (fires after converters)+ jqXHR.always(function() {+ // Restore preexisting value+ window[ callbackName ] = overwritten;++ // Save back as free+ if ( s[ callbackName ] ) {+ // make sure that re-using the options doesn't screw things around+ s.jsonpCallback = originalSettings.jsonpCallback;++ // save the callback name for future use+ oldCallbacks.push( callbackName );+ }++ // Call if it was a function and we have a response+ if ( responseContainer && jQuery.isFunction( overwritten ) ) {+ overwritten( responseContainer[ 0 ] );+ }++ responseContainer = overwritten = undefined;+ });++ // Delegate to script+ return "script";+ }+});+++++// data: string of html+// context (optional): If specified, the fragment will be created in this context, defaults to document+// keepScripts (optional): If true, will include scripts passed in the html string+jQuery.parseHTML = function( data, context, keepScripts ) {+ if ( !data || typeof data !== "string" ) {+ return null;+ }+ if ( typeof context === "boolean" ) {+ keepScripts = context;+ context = false;+ }+ context = context || document;++ var parsed = rsingleTag.exec( data ),+ scripts = !keepScripts && [];++ // Single tag+ if ( parsed ) {+ return [ context.createElement( parsed[1] ) ];+ }++ parsed = jQuery.buildFragment( [ data ], context, scripts );++ if ( scripts && scripts.length ) {+ jQuery( scripts ).remove();+ }++ return jQuery.merge( [], parsed.childNodes );+};+++// Keep a copy of the old load method+var _load = jQuery.fn.load;++/**+ * Load a url into a page+ */+jQuery.fn.load = function( url, params, callback ) {+ if ( typeof url !== "string" && _load ) {+ return _load.apply( this, arguments );+ }++ var selector, response, type,+ self = this,+ off = url.indexOf(" ");++ if ( off >= 0 ) {+ selector = jQuery.trim( url.slice( off, url.length ) );+ url = url.slice( 0, off );+ }++ // If it's a function+ if ( jQuery.isFunction( params ) ) {++ // We assume that it's the callback+ callback = params;+ params = undefined;++ // Otherwise, build a param string+ } else if ( params && typeof params === "object" ) {+ type = "POST";+ }++ // If we have elements to modify, make the request+ if ( self.length > 0 ) {+ jQuery.ajax({+ url: url,++ // if "type" variable is undefined, then "GET" method will be used+ type: type,+ dataType: "html",+ data: params+ }).done(function( responseText ) {++ // Save response for use in complete callback+ response = arguments;++ self.html( selector ?++ // If a selector was specified, locate the right elements in a dummy div+ // Exclude scripts to avoid IE 'Permission Denied' errors+ jQuery("<div>").append( jQuery.parseHTML( responseText ) ).find( selector ) :++ // Otherwise use the full result+ responseText );++ }).complete( callback && function( jqXHR, status ) {+ self.each( callback, response || [ jqXHR.responseText, status, jqXHR ] );+ });+ }++ return this;+};+++++jQuery.expr.filters.animated = function( elem ) {+ return jQuery.grep(jQuery.timers, function( fn ) {+ return elem === fn.elem;+ }).length;+};++++++var docElem = window.document.documentElement;++/**+ * Gets a window from an element+ */+function getWindow( elem ) {+ return jQuery.isWindow( elem ) ?+ elem :+ elem.nodeType === 9 ?+ elem.defaultView || elem.parentWindow :+ false;+}++jQuery.offset = {+ setOffset: function( elem, options, i ) {+ var curPosition, curLeft, curCSSTop, curTop, curOffset, curCSSLeft, calculatePosition,+ position = jQuery.css( elem, "position" ),+ curElem = jQuery( elem ),+ props = {};++ // set position first, in-case top/left are set even on static elem+ if ( position === "static" ) {+ elem.style.position = "relative";+ }++ curOffset = curElem.offset();+ curCSSTop = jQuery.css( elem, "top" );+ curCSSLeft = jQuery.css( elem, "left" );+ calculatePosition = ( position === "absolute" || position === "fixed" ) &&+ jQuery.inArray("auto", [ curCSSTop, curCSSLeft ] ) > -1;++ // need to be able to calculate position if either top or left is auto and position is either absolute or fixed+ if ( calculatePosition ) {+ curPosition = curElem.position();+ curTop = curPosition.top;+ curLeft = curPosition.left;+ } else {+ curTop = parseFloat( curCSSTop ) || 0;+ curLeft = parseFloat( curCSSLeft ) || 0;+ }++ if ( jQuery.isFunction( options ) ) {+ options = options.call( elem, i, curOffset );+ }++ if ( options.top != null ) {+ props.top = ( options.top - curOffset.top ) + curTop;+ }+ if ( options.left != null ) {+ props.left = ( options.left - curOffset.left ) + curLeft;+ }++ if ( "using" in options ) {+ options.using.call( elem, props );+ } else {+ curElem.css( props );+ }+ }+};++jQuery.fn.extend({+ offset: function( options ) {+ if ( arguments.length ) {+ return options === undefined ?+ this :+ this.each(function( i ) {+ jQuery.offset.setOffset( this, options, i );+ });+ }++ var docElem, win,+ box = { top: 0, left: 0 },+ elem = this[ 0 ],+ doc = elem && elem.ownerDocument;++ if ( !doc ) {+ return;+ }++ docElem = doc.documentElement;++ // Make sure it's not a disconnected DOM node+ if ( !jQuery.contains( docElem, elem ) ) {+ return box;+ }++ // If we don't have gBCR, just use 0,0 rather than error+ // BlackBerry 5, iOS 3 (original iPhone)+ if ( typeof elem.getBoundingClientRect !== strundefined ) {+ box = elem.getBoundingClientRect();+ }+ win = getWindow( doc );+ return {+ top: box.top + ( win.pageYOffset || docElem.scrollTop ) - ( docElem.clientTop || 0 ),+ left: box.left + ( win.pageXOffset || docElem.scrollLeft ) - ( docElem.clientLeft || 0 )+ };+ },++ position: function() {+ if ( !this[ 0 ] ) {+ return;+ }++ var offsetParent, offset,+ parentOffset = { top: 0, left: 0 },+ elem = this[ 0 ];++ // fixed elements are offset from window (parentOffset = {top:0, left: 0}, because it is its only offset parent+ if ( jQuery.css( elem, "position" ) === "fixed" ) {+ // we assume that getBoundingClientRect is available when computed position is fixed+ offset = elem.getBoundingClientRect();+ } else {+ // Get *real* offsetParent+ offsetParent = this.offsetParent();++ // Get correct offsets+ offset = this.offset();+ if ( !jQuery.nodeName( offsetParent[ 0 ], "html" ) ) {+ parentOffset = offsetParent.offset();+ }++ // Add offsetParent borders+ parentOffset.top += jQuery.css( offsetParent[ 0 ], "borderTopWidth", true );+ parentOffset.left += jQuery.css( offsetParent[ 0 ], "borderLeftWidth", true );+ }++ // Subtract parent offsets and element margins+ // note: when an element has margin: auto the offsetLeft and marginLeft+ // are the same in Safari causing offset.left to incorrectly be 0+ return {+ top: offset.top - parentOffset.top - jQuery.css( elem, "marginTop", true ),+ left: offset.left - parentOffset.left - jQuery.css( elem, "marginLeft", true)+ };+ },++ offsetParent: function() {+ return this.map(function() {+ var offsetParent = this.offsetParent || docElem;++ while ( offsetParent && ( !jQuery.nodeName( offsetParent, "html" ) && jQuery.css( offsetParent, "position" ) === "static" ) ) {+ offsetParent = offsetParent.offsetParent;+ }+ return offsetParent || docElem;+ });+ }+});++// Create scrollLeft and scrollTop methods+jQuery.each( { scrollLeft: "pageXOffset", scrollTop: "pageYOffset" }, function( method, prop ) {+ var top = /Y/.test( prop );++ jQuery.fn[ method ] = function( val ) {+ return access( this, function( elem, method, val ) {+ var win = getWindow( elem );++ if ( val === undefined ) {+ return win ? (prop in win) ? win[ prop ] :+ win.document.documentElement[ method ] :+ elem[ method ];+ }++ if ( win ) {+ win.scrollTo(+ !top ? val : jQuery( win ).scrollLeft(),+ top ? val : jQuery( win ).scrollTop()+ );++ } else {+ elem[ method ] = val;+ }+ }, method, val, arguments.length, null );+ };+});++// Add the top/left cssHooks using jQuery.fn.position+// Webkit bug: https://bugs.webkit.org/show_bug.cgi?id=29084+// getComputedStyle returns percent when specified for top/left/bottom/right+// rather than make the css module depend on the offset module, we just check for it here+jQuery.each( [ "top", "left" ], function( i, prop ) {+ jQuery.cssHooks[ prop ] = addGetHookIf( support.pixelPosition,+ function( elem, computed ) {+ if ( computed ) {+ computed = curCSS( elem, prop );+ // if curCSS returns percentage, fallback to offset+ return rnumnonpx.test( computed ) ?+ jQuery( elem ).position()[ prop ] + "px" :+ computed;+ }+ }+ );+});+++// Create innerHeight, innerWidth, height, width, outerHeight and outerWidth methods+jQuery.each( { Height: "height", Width: "width" }, function( name, type ) {+ jQuery.each( { padding: "inner" + name, content: type, "": "outer" + name }, function( defaultExtra, funcName ) {+ // margin is only for outerHeight, outerWidth+ jQuery.fn[ funcName ] = function( margin, value ) {+ var chainable = arguments.length && ( defaultExtra || typeof margin !== "boolean" ),+ extra = defaultExtra || ( margin === true || value === true ? "margin" : "border" );++ return access( this, function( elem, type, value ) {+ var doc;++ if ( jQuery.isWindow( elem ) ) {+ // As of 5/8/2012 this will yield incorrect results for Mobile Safari, but there+ // isn't a whole lot we can do. See pull request at this URL for discussion:+ // https://github.com/jquery/jquery/pull/764+ return elem.document.documentElement[ "client" + name ];+ }++ // Get document width or height+ if ( elem.nodeType === 9 ) {+ doc = elem.documentElement;++ // Either scroll[Width/Height] or offset[Width/Height] or client[Width/Height], whichever is greatest+ // unfortunately, this causes bug #3838 in IE6/8 only, but there is currently no good, small way to fix it.+ return Math.max(+ elem.body[ "scroll" + name ], doc[ "scroll" + name ],+ elem.body[ "offset" + name ], doc[ "offset" + name ],+ doc[ "client" + name ]+ );+ }++ return value === undefined ?+ // Get width or height on the element, requesting but not forcing parseFloat+ jQuery.css( elem, type, extra ) :++ // Set width or height on the element+ jQuery.style( elem, type, value, extra );+ }, type, chainable ? margin : undefined, chainable, null );+ };+ });+});+++// The number of elements contained in the matched element set+jQuery.fn.size = function() {+ return this.length;+};++jQuery.fn.andSelf = jQuery.fn.addBack;+++++// Register as a named AMD module, since jQuery can be concatenated with other+// files that may use define, but not via a proper concatenation script that+// understands anonymous AMD modules. A named AMD is safest and most robust+// way to register. Lowercase jquery is used because AMD module names are+// derived from file names, and jQuery is normally delivered in a lowercase+// file name. Do this after creating the global so that if an AMD module wants+// to call noConflict to hide this version of jQuery, it will work.++// Note that for maximum portability, libraries that are not jQuery should+// declare themselves as anonymous modules, and avoid setting a global if an+// AMD loader is present. jQuery is a special case. For more information, see+// https://github.com/jrburke/requirejs/wiki/Updating-existing-libraries#wiki-anon++if ( typeof define === "function" && define.amd ) {+ define( "jquery", [], function() {+ return jQuery;+ });+}+++++var+ // Map over jQuery in case of overwrite+ _jQuery = window.jQuery,++ // Map over the $ in case of overwrite+ _$ = window.$;++jQuery.noConflict = function( deep ) {+ if ( window.$ === jQuery ) {+ window.$ = _$;+ }++ if ( deep && window.jQuery === jQuery ) {+ window.jQuery = _jQuery;+ }++ return jQuery;+};++// Expose jQuery and $ identifiers, even in+// AMD (#7102#comment:10, https://github.com/jquery/jquery/pull/557)+// and CommonJS for browser emulators (#13566)+if ( typeof noGlobal === strundefined ) {+ window.jQuery = window.$ = jQuery;+}+++++return jQuery;++}));diff --git a/app/assets/javascripts/blazer/jquery.stickytableheaders.js b/app/assets/javascripts/blazer/jquery.stickytableheaders.jsnew file mode 100644index 00000000..7f9d90e8--- /dev/null+++ b/app/assets/javascripts/blazer/jquery.stickytableheaders.js@@ -0,0 +1,263 @@+/*! Copyright (c) 2011 by Jonas Mosbech - https://github.com/jmosbech/StickyTableHeaders+ MIT license info: https://github.com/jmosbech/StickyTableHeaders/blob/master/license.txt */++;(function ($, window, undefined) {+ 'use strict';++ var name = 'stickyTableHeaders',+ id = 0,+ defaults = {+ fixedOffset: 0,+ leftOffset: 0,+ scrollableArea: window+ };++ function Plugin (el, options) {+ // To avoid scope issues, use 'base' instead of 'this'+ // to reference this class from internal events and functions.+ var base = this;++ // Access to jQuery and DOM versions of element+ base.$el = $(el);+ base.el = el;+ base.id = id++;++ // Listen for destroyed, call teardown+ base.$el.bind('destroyed',+ $.proxy(base.teardown, base));++ // Cache DOM refs for performance reasons+ base.$clonedHeader = null;+ base.$originalHeader = null;++ // Keep track of state+ base.isSticky = false;+ base.hasBeenSticky = false;+ base.leftOffset = null;+ base.topOffset = null;++ base.init = function () {+ base.options = $.extend({}, defaults, options);++ base.$el.each(function () {+ var $this = $(this);++ // remove padding on <table> to fix issue #7+ $this.css('padding', 0);++ base.$scrollableArea = $(base.options.scrollableArea);++ base.$originalHeader = $('thead:first', this);+ base.$clonedHeader = base.$originalHeader.clone();+ $this.trigger('clonedHeader.' + name, [base.$clonedHeader]);++ base.$clonedHeader.addClass('tableFloatingHeader');+ base.$clonedHeader.css('display', 'none');++ base.$originalHeader.addClass('tableFloatingHeaderOriginal');++ base.$originalHeader.after(base.$clonedHeader);++ base.$printStyle = $('<style type="text/css" media="print">' ++ '.tableFloatingHeader{display:none !important;}' ++ '.tableFloatingHeaderOriginal{position:static !important;}' ++ '</style>');+ $('head').append(base.$printStyle);+ });++ base.updateWidth();+ base.toggleHeaders();++ base.bind();+ };++ base.destroy = function (){+ base.$el.unbind('destroyed', base.teardown);+ base.teardown();+ };++ base.teardown = function(){+ if (base.isSticky) {+ base.$originalHeader.css('position', 'static');+ }+ $.removeData(base.el, 'plugin_' + name);+ base.unbind();++ base.$clonedHeader.remove();+ base.$originalHeader.removeClass('tableFloatingHeaderOriginal');+ base.$originalHeader.css('visibility', 'visible');+ base.$printStyle.remove();++ base.el = null;+ base.$el = null;+ };++ base.bind = function(){+ base.$scrollableArea.on('scroll.' + name, base.toggleHeaders);+ if (!base.isWindowScrolling()) {+ $(window).on('scroll.' + name + base.id, base.setPositionValues);+ $(window).on('resize.' + name + base.id, base.toggleHeaders);+ }+ base.$scrollableArea.on('resize.' + name, base.toggleHeaders);+ base.$scrollableArea.on('resize.' + name, base.updateWidth);+ };++ base.unbind = function(){+ // unbind window events by specifying handle so we don't remove too much+ base.$scrollableArea.off('.' + name, base.toggleHeaders);+ if (!base.isWindowScrolling()) {+ $(window).off('.' + name + base.id, base.setPositionValues);+ $(window).off('.' + name + base.id, base.toggleHeaders);+ }+ base.$scrollableArea.off('.' + name, base.updateWidth);+ base.$el.off('.' + name);+ base.$el.find('*').off('.' + name);+ };++ base.toggleHeaders = function () {+ if (base.$el) {+ base.$el.each(function () {+ var $this = $(this),+ newLeft,+ newTopOffset = base.isWindowScrolling() ? (+ isNaN(base.options.fixedOffset) ?+ base.options.fixedOffset.outerHeight() :+ base.options.fixedOffset+ ) :+ base.$scrollableArea.offset().top + (!isNaN(base.options.fixedOffset) ? base.options.fixedOffset : 0),+ offset = $this.offset(),++ scrollTop = base.$scrollableArea.scrollTop() + newTopOffset,+ scrollLeft = base.$scrollableArea.scrollLeft(),++ scrolledPastTop = base.isWindowScrolling() ?+ scrollTop > offset.top :+ newTopOffset > offset.top,+ notScrolledPastBottom = (base.isWindowScrolling() ? scrollTop : 0) <+ (offset.top + $this.height() - base.$clonedHeader.height() - (base.isWindowScrolling() ? 0 : newTopOffset));++ if (scrolledPastTop && notScrolledPastBottom) {+ newLeft = offset.left - scrollLeft + base.options.leftOffset;+ base.$originalHeader.css({+ 'position': 'fixed',+ 'margin-top': 0,+ 'left': newLeft,+ 'z-index': 1 // #18: opacity bug+ });+ base.isSticky = true;+ base.leftOffset = newLeft;+ base.topOffset = newTopOffset;+ base.$clonedHeader.css('display', '');+ base.setPositionValues();+ // make sure the width is correct: the user might have resized the browser while in static mode+ base.updateWidth();+ } else if (base.isSticky) {+ base.$originalHeader.css('position', 'static');+ base.$clonedHeader.css('display', 'none');+ base.isSticky = false;+ base.resetWidth($("td,th", base.$clonedHeader), $("td,th", base.$originalHeader));+ }+ });+ }+ };++ base.isWindowScrolling = function() {+ return base.$scrollableArea[0] === window;+ };++ base.setPositionValues = function () {+ var winScrollTop = $(window).scrollTop(),+ winScrollLeft = $(window).scrollLeft();+ if (!base.isSticky ||+ winScrollTop < 0 || winScrollTop + $(window).height() > $(document).height() ||+ winScrollLeft < 0 || winScrollLeft + $(window).width() > $(document).width()) {+ return;+ }+ base.$originalHeader.css({+ 'top': base.topOffset - (base.isWindowScrolling() ? 0 : winScrollTop),+ 'left': base.leftOffset - (base.isWindowScrolling() ? 0 : winScrollLeft)+ });+ };++ base.updateWidth = function () {+ if (!base.isSticky) {+ return;+ }+ // Copy cell widths from clone+ if (!base.$originalHeaderCells) {+ base.$originalHeaderCells = $('th,td', base.$originalHeader);+ }+ if (!base.$clonedHeaderCells) {+ base.$clonedHeaderCells = $('th,td', base.$clonedHeader);+ }+ var cellWidths = base.getWidth(base.$clonedHeaderCells);+ base.setWidth(cellWidths, base.$clonedHeaderCells, base.$originalHeaderCells);++ // Copy row width from whole table+ base.$originalHeader.css('width', base.$clonedHeader.width());+ };++ base.getWidth = function ($clonedHeaders) {+ var widths = [];+ $clonedHeaders.each(function (index) {+ var width, $this = $(this);++ if ($this.css('box-sizing') === 'border-box') {+ width = $this.outerWidth(); // #39: border-box bug+ } else {+ width = $this.width();+ }++ widths[index] = width;+ });+ return widths;+ };++ base.setWidth = function (widths, $clonedHeaders, $origHeaders) {+ $clonedHeaders.each(function (index) {+ var width = widths[index];+ $origHeaders.eq(index).css({+ 'min-width': width,+ 'max-width': width+ });+ });+ };++ base.resetWidth = function ($clonedHeaders, $origHeaders) {+ $clonedHeaders.each(function (index) {+ var $this = $(this);+ $origHeaders.eq(index).css({+ 'min-width': $this.css("min-width"),+ 'max-width': $this.css("max-width")+ });+ });+ };++ base.updateOptions = function(options) {+ base.options = $.extend({}, defaults, options);+ base.updateWidth();+ base.toggleHeaders();+ };++ // Run initializer+ base.init();+ }++ // A plugin wrapper around the constructor,+ // preventing against multiple instantiations+ $.fn[name] = function ( options ) {+ return this.each(function () {+ var instance = $.data(this, 'plugin_' + name);+ if (instance) {+ if (typeof options === "string") {+ instance[options].apply(instance);+ } else {+ instance.updateOptions(options);+ }+ } else if(options !== 'destroy') {+ $.data(this, 'plugin_' + name, new Plugin( this, options ));+ }+ });+ };++})(jQuery, window);diff --git a/app/assets/javascripts/blazer/jquery_ujs.js b/app/assets/javascripts/blazer/jquery_ujs.jsnew file mode 100644index 00000000..ae4355c0--- /dev/null+++ b/app/assets/javascripts/blazer/jquery_ujs.js@@ -0,0 +1,469 @@+(function($, undefined) {++/**+ * Unobtrusive scripting adapter for jQuery+ * https://github.com/rails/jquery-ujs+ *+ * Requires jQuery 1.8.0 or later.+ *+ * Released under the MIT license+ *+ */++ // Cut down on the number of issues from people inadvertently including jquery_ujs twice+ // by detecting and raising an error when it happens.+ if ( $.rails !== undefined ) {+ $.error('jquery-ujs has already been loaded!');+ }++ // Shorthand to make it a little easier to call public rails functions from within rails.js+ var rails;+ var $document = $(document);++ $.rails = rails = {+ // Link elements bound by jquery-ujs+ linkClickSelector: 'a[data-confirm], a[data-method], a[data-remote], a[data-disable-with], a[data-disable]',++ // Button elements bound by jquery-ujs+ buttonClickSelector: 'button[data-remote]:not(form button), button[data-confirm]:not(form button)',++ // Select elements bound by jquery-ujs+ inputChangeSelector: 'select[data-remote], input[data-remote], textarea[data-remote]',++ // Form elements bound by jquery-ujs+ formSubmitSelector: 'form',++ // Form input elements bound by jquery-ujs+ formInputClickSelector: 'form input[type=submit], form input[type=image], form button[type=submit], form button:not([type]), input[type=submit][form], input[type=image][form], button[type=submit][form], button[form]:not([type])',++ // Form input elements disabled during form submission+ disableSelector: 'input[data-disable-with]:enabled, button[data-disable-with]:enabled, textarea[data-disable-with]:enabled, input[data-disable]:enabled, button[data-disable]:enabled, textarea[data-disable]:enabled',++ // Form input elements re-enabled after form submission+ enableSelector: 'input[data-disable-with]:disabled, button[data-disable-with]:disabled, textarea[data-disable-with]:disabled, input[data-disable]:disabled, button[data-disable]:disabled, textarea[data-disable]:disabled',++ // Form required input elements+ requiredInputSelector: 'input[name][required]:not([disabled]),textarea[name][required]:not([disabled])',++ // Form file input elements+ fileInputSelector: 'input[type=file]',++ // Link onClick disable selector with possible reenable after remote submission+ linkDisableSelector: 'a[data-disable-with], a[data-disable]',++ // Button onClick disable selector with possible reenable after remote submission+ buttonDisableSelector: 'button[data-remote][data-disable-with], button[data-remote][data-disable]',++ // Make sure that every Ajax request sends the CSRF token+ CSRFProtection: function(xhr) {+ var token = $('meta[name="csrf-token"]').attr('content');+ if (token) xhr.setRequestHeader('X-CSRF-Token', token);+ },++ // making sure that all forms have actual up-to-date token(cached forms contain old one)+ refreshCSRFTokens: function(){+ var csrfToken = $('meta[name=csrf-token]').attr('content');+ var csrfParam = $('meta[name=csrf-param]').attr('content');+ $('form input[name="' + csrfParam + '"]').val(csrfToken);+ },++ // Triggers an event on an element and returns false if the event result is false+ fire: function(obj, name, data) {+ var event = $.Event(name);+ obj.trigger(event, data);+ return event.result !== false;+ },++ // Default confirm dialog, may be overridden with custom confirm dialog in $.rails.confirm+ confirm: function(message) {+ return confirm(message);+ },++ // Default ajax function, may be overridden with custom function in $.rails.ajax+ ajax: function(options) {+ return $.ajax(options);+ },++ // Default way to get an element's href. May be overridden at $.rails.href.+ href: function(element) {+ return element.attr('href');+ },++ // Submits "remote" forms and links with ajax+ handleRemote: function(element) {+ var method, url, data, elCrossDomain, crossDomain, withCredentials, dataType, options;++ if (rails.fire(element, 'ajax:before')) {+ elCrossDomain = element.data('cross-domain');+ crossDomain = elCrossDomain === undefined ? null : elCrossDomain;+ withCredentials = element.data('with-credentials') || null;+ dataType = element.data('type') || ($.ajaxSettings && $.ajaxSettings.dataType);++ if (element.is('form')) {+ method = element.attr('method');+ url = element.attr('action');+ data = element.serializeArray();+ // memoized value from clicked submit button+ var button = element.data('ujs:submit-button');+ if (button) {+ data.push(button);+ element.data('ujs:submit-button', null);+ }+ } else if (element.is(rails.inputChangeSelector)) {+ method = element.data('method');+ url = element.data('url');+ data = element.serialize();+ if (element.data('params')) data = data + "&" + element.data('params');+ } else if (element.is(rails.buttonClickSelector)) {+ method = element.data('method') || 'get';+ url = element.data('url');+ data = element.serialize();+ if (element.data('params')) data = data + "&" + element.data('params');+ } else {+ method = element.data('method');+ url = rails.href(element);+ data = element.data('params') || null;+ }++ options = {+ type: method || 'GET', data: data, dataType: dataType,+ // stopping the "ajax:beforeSend" event will cancel the ajax request+ beforeSend: function(xhr, settings) {+ if (settings.dataType === undefined) {+ xhr.setRequestHeader('accept', '*/*;q=0.5, ' + settings.accepts.script);+ }+ if (rails.fire(element, 'ajax:beforeSend', [xhr, settings])) {+ element.trigger('ajax:send', xhr);+ } else {+ return false;+ }+ },+ success: function(data, status, xhr) {+ element.trigger('ajax:success', [data, status, xhr]);+ },+ complete: function(xhr, status) {+ element.trigger('ajax:complete', [xhr, status]);+ },+ error: function(xhr, status, error) {+ element.trigger('ajax:error', [xhr, status, error]);+ },+ crossDomain: crossDomain+ };++ // There is no withCredentials for IE6-8 when+ // "Enable native XMLHTTP support" is disabled+ if (withCredentials) {+ options.xhrFields = {+ withCredentials: withCredentials+ };+ }++ // Only pass url to `ajax` options if not blank+ if (url) { options.url = url; }++ return rails.ajax(options);+ } else {+ return false;+ }+ },++ // Handles "data-method" on links such as:+ // <a href="/users/5" data-method="delete" rel="nofollow" data-confirm="Are you sure?">Delete</a>+ handleMethod: function(link) {+ var href = rails.href(link),+ method = link.data('method'),+ target = link.attr('target'),+ csrfToken = $('meta[name=csrf-token]').attr('content'),+ csrfParam = $('meta[name=csrf-param]').attr('content'),+ form = $('<form method="post" action="' + href + '"></form>'),+ metadataInput = '<input name="_method" value="' + method + '" type="hidden" />';++ if (csrfParam !== undefined && csrfToken !== undefined) {+ metadataInput += '<input name="' + csrfParam + '" value="' + csrfToken + '" type="hidden" />';+ }++ if (target) { form.attr('target', target); }++ form.hide().append(metadataInput).appendTo('body');+ form.submit();+ },++ // Helper function that returns form elements that match the specified CSS selector+ // If form is actually a "form" element this will return associated elements outside the from that have+ // the html form attribute set+ formElements: function(form, selector) {+ return form.is('form') ? $(form[0].elements).filter(selector) : form.find(selector);+ },++ /* Disables form elements:+ - Caches element value in 'ujs:enable-with' data store+ - Replaces element text with value of 'data-disable-with' attribute+ - Sets disabled property to true+ */+ disableFormElements: function(form) {+ rails.formElements(form, rails.disableSelector).each(function() {+ rails.disableFormElement($(this));+ });+ },++ disableFormElement: function(element) {+ var method, replacement;++ method = element.is('button') ? 'html' : 'val';+ replacement = element.data('disable-with');++ element.data('ujs:enable-with', element[method]());+ if (replacement !== undefined) {+ element[method](replacement);+ }++ element.prop('disabled', true);+ },++ /* Re-enables disabled form elements:+ - Replaces element text with cached value from 'ujs:enable-with' data store (created in `disableFormElements`)+ - Sets disabled property to false+ */+ enableFormElements: function(form) {+ rails.formElements(form, rails.enableSelector).each(function() {+ rails.enableFormElement($(this));+ });+ },++ enableFormElement: function(element) {+ var method = element.is('button') ? 'html' : 'val';+ if (element.data('ujs:enable-with')) element[method](element.data('ujs:enable-with'));+ element.prop('disabled', false);+ },++ /* For 'data-confirm' attribute:+ - Fires `confirm` event+ - Shows the confirmation dialog+ - Fires the `confirm:complete` event++ Returns `true` if no function stops the chain and user chose yes; `false` otherwise.+ Attaching a handler to the element's `confirm` event that returns a `falsy` value cancels the confirmation dialog.+ Attaching a handler to the element's `confirm:complete` event that returns a `falsy` value makes this function+ return false. The `confirm:complete` event is fired whether or not the user answered true or false to the dialog.+ */+ allowAction: function(element) {+ var message = element.data('confirm'),+ answer = false, callback;+ if (!message) { return true; }++ if (rails.fire(element, 'confirm')) {+ answer = rails.confirm(message);+ callback = rails.fire(element, 'confirm:complete', [answer]);+ }+ return answer && callback;+ },++ // Helper function which checks for blank inputs in a form that match the specified CSS selector+ blankInputs: function(form, specifiedSelector, nonBlank) {+ var inputs = $(), input, valueToCheck,+ selector = specifiedSelector || 'input,textarea',+ allInputs = form.find(selector);++ allInputs.each(function() {+ input = $(this);+ valueToCheck = input.is('input[type=checkbox],input[type=radio]') ? input.is(':checked') : input.val();+ // If nonBlank and valueToCheck are both truthy, or nonBlank and valueToCheck are both falsey+ if (!valueToCheck === !nonBlank) {++ // Don't count unchecked required radio if other radio with same name is checked+ if (input.is('input[type=radio]') && allInputs.filter('input[type=radio]:checked[name="' + input.attr('name') + '"]').length) {+ return true; // Skip to next input+ }++ inputs = inputs.add(input);+ }+ });+ return inputs.length ? inputs : false;+ },++ // Helper function which checks for non-blank inputs in a form that match the specified CSS selector+ nonBlankInputs: function(form, specifiedSelector) {+ return rails.blankInputs(form, specifiedSelector, true); // true specifies nonBlank+ },++ // Helper function, needed to provide consistent behavior in IE+ stopEverything: function(e) {+ $(e.target).trigger('ujs:everythingStopped');+ e.stopImmediatePropagation();+ return false;+ },++ // replace element's html with the 'data-disable-with' after storing original html+ // and prevent clicking on it+ disableElement: function(element) {+ var replacement = element.data('disable-with');++ element.data('ujs:enable-with', element.html()); // store enabled state+ if (replacement !== undefined) {+ element.html(replacement);+ }++ element.bind('click.railsDisable', function(e) { // prevent further clicking+ return rails.stopEverything(e);+ });+ },++ // restore element to its original state which was disabled by 'disableElement' above+ enableElement: function(element) {+ if (element.data('ujs:enable-with') !== undefined) {+ element.html(element.data('ujs:enable-with')); // set to old enabled state+ element.removeData('ujs:enable-with'); // clean up cache+ }+ element.unbind('click.railsDisable'); // enable element+ }+ };++ if (rails.fire($document, 'rails:attachBindings')) {++ $.ajaxPrefilter(function(options, originalOptions, xhr){ if ( !options.crossDomain ) { rails.CSRFProtection(xhr); }});++ // This event works the same as the load event, except that it fires every+ // time the page is loaded.+ //+ // See https://github.com/rails/jquery-ujs/issues/357+ // See https://developer.mozilla.org/en-US/docs/Using_Firefox_1.5_caching+ $(window).on("pageshow.rails", function () {+ $($.rails.enableSelector).each(function () {+ var element = $(this);++ if (element.data("ujs:enable-with")) {+ $.rails.enableFormElement(element);+ }+ });++ $($.rails.linkDisableSelector).each(function () {+ var element = $(this);++ if (element.data("ujs:enable-with")) {+ $.rails.enableElement(element);+ }+ });+ });++ $document.delegate(rails.linkDisableSelector, 'ajax:complete', function() {+ rails.enableElement($(this));+ });++ $document.delegate(rails.buttonDisableSelector, 'ajax:complete', function() {+ rails.enableFormElement($(this));+ });++ $document.delegate(rails.linkClickSelector, 'click.rails', function(e) {+ var link = $(this), method = link.data('method'), data = link.data('params'), metaClick = e.metaKey || e.ctrlKey;+ if (!rails.allowAction(link)) return rails.stopEverything(e);++ if (!metaClick && link.is(rails.linkDisableSelector)) rails.disableElement(link);++ if (link.data('remote') !== undefined) {+ if (metaClick && (!method || method === 'GET') && !data) { return true; }++ var handleRemote = rails.handleRemote(link);+ // response from rails.handleRemote() will either be false or a deferred object promise.+ if (handleRemote === false) {+ rails.enableElement(link);+ } else {+ handleRemote.error( function() { rails.enableElement(link); } );+ }+ return false;++ } else if (link.data('method')) {+ rails.handleMethod(link);+ return false;+ }+ });++ $document.delegate(rails.buttonClickSelector, 'click.rails', function(e) {+ var button = $(this);++ if (!rails.allowAction(button)) return rails.stopEverything(e);++ if (button.is(rails.buttonDisableSelector)) rails.disableFormElement(button);++ var handleRemote = rails.handleRemote(button);+ // response from rails.handleRemote() will either be false or a deferred object promise.+ if (handleRemote === false) {+ rails.enableFormElement(button);+ } else {+ handleRemote.error( function() { rails.enableFormElement(button); } );+ }+ return false;+ });++ $document.delegate(rails.inputChangeSelector, 'change.rails', function(e) {+ var link = $(this);+ if (!rails.allowAction(link)) return rails.stopEverything(e);++ rails.handleRemote(link);+ return false;+ });++ $document.delegate(rails.formSubmitSelector, 'submit.rails', function(e) {+ var form = $(this),+ remote = form.data('remote') !== undefined,+ blankRequiredInputs,+ nonBlankFileInputs;++ if (!rails.allowAction(form)) return rails.stopEverything(e);++ // skip other logic when required values are missing or file upload is present+ if (form.attr('novalidate') == undefined) {+ blankRequiredInputs = rails.blankInputs(form, rails.requiredInputSelector);+ if (blankRequiredInputs && rails.fire(form, 'ajax:aborted:required', [blankRequiredInputs])) {+ return rails.stopEverything(e);+ }+ }++ if (remote) {+ nonBlankFileInputs = rails.nonBlankInputs(form, rails.fileInputSelector);+ if (nonBlankFileInputs) {+ // slight timeout so that the submit button gets properly serialized+ // (make it easy for event handler to serialize form without disabled values)+ setTimeout(function(){ rails.disableFormElements(form); }, 13);+ var aborted = rails.fire(form, 'ajax:aborted:file', [nonBlankFileInputs]);++ // re-enable form elements if event bindings return false (canceling normal form submission)+ if (!aborted) { setTimeout(function(){ rails.enableFormElements(form); }, 13); }++ return aborted;+ }++ rails.handleRemote(form);+ return false;++ } else {+ // slight timeout so that the submit button gets properly serialized+ setTimeout(function(){ rails.disableFormElements(form); }, 13);+ }+ });++ $document.delegate(rails.formInputClickSelector, 'click.rails', function(event) {+ var button = $(this);++ if (!rails.allowAction(button)) return rails.stopEverything(event);++ // register the pressed submit button+ var name = button.attr('name'),+ data = name ? {name:name, value:button.val()} : null;++ button.closest('form').data('ujs:submit-button', data);+ });++ $document.delegate(rails.formSubmitSelector, 'ajax:send.rails', function(event) {+ if (this == event.target) rails.disableFormElements($(this));+ });++ $document.delegate(rails.formSubmitSelector, 'ajax:complete.rails', function(event) {+ if (this == event.target) rails.enableFormElements($(this));+ });++ $(function(){+ rails.refreshCSRFTokens();+ });+ }++})( jQuery );diff --git a/app/assets/javascripts/blazer/list.js b/app/assets/javascripts/blazer/list.jsnew file mode 100644index 00000000..a88ca82e--- /dev/null+++ b/app/assets/javascripts/blazer/list.js@@ -0,0 +1,1474 @@+;(function(){++/**+ * Require the given path.+ *+ * @param {String} path+ * @return {Object} exports+ * @api public+ */++function require(path, parent, orig) {+ var resolved = require.resolve(path);++ // lookup failed+ if (null == resolved) {+ orig = orig || path;+ parent = parent || 'root';+ var err = new Error('Failed to require "' + orig + '" from "' + parent + '"');+ err.path = orig;+ err.parent = parent;+ err.require = true;+ throw err;+ }++ var module = require.modules[resolved];++ // perform real require()+ // by invoking the module's+ // registered function+ if (!module._resolving && !module.exports) {+ var mod = {};+ mod.exports = {};+ mod.client = mod.component = true;+ module._resolving = true;+ module.call(this, mod.exports, require.relative(resolved), mod);+ delete module._resolving;+ module.exports = mod.exports;+ }++ return module.exports;+}++/**+ * Registered modules.+ */++require.modules = {};++/**+ * Registered aliases.+ */++require.aliases = {};++/**+ * Resolve `path`.+ *+ * Lookup:+ *+ * - PATH/index.js+ * - PATH.js+ * - PATH+ *+ * @param {String} path+ * @return {String} path or null+ * @api private+ */++require.resolve = function(path) {+ if (path.charAt(0) === '/') path = path.slice(1);++ var paths = [+ path,+ path + '.js',+ path + '.json',+ path + '/index.js',+ path + '/index.json'+ ];++ for (var i = 0; i < paths.length; i++) {+ var path = paths[i];+ if (require.modules.hasOwnProperty(path)) return path;+ if (require.aliases.hasOwnProperty(path)) return require.aliases[path];+ }+};++/**+ * Normalize `path` relative to the current path.+ *+ * @param {String} curr+ * @param {String} path+ * @return {String}+ * @api private+ */++require.normalize = function(curr, path) {+ var segs = [];++ if ('.' != path.charAt(0)) return path;++ curr = curr.split('/');+ path = path.split('/');++ for (var i = 0; i < path.length; ++i) {+ if ('..' == path[i]) {+ curr.pop();+ } else if ('.' != path[i] && '' != path[i]) {+ segs.push(path[i]);+ }+ }++ return curr.concat(segs).join('/');+};++/**+ * Register module at `path` with callback `definition`.+ *+ * @param {String} path+ * @param {Function} definition+ * @api private+ */++require.register = function(path, definition) {+ require.modules[path] = definition;+};++/**+ * Alias a module definition.+ *+ * @param {String} from+ * @param {String} to+ * @api private+ */++require.alias = function(from, to) {+ if (!require.modules.hasOwnProperty(from)) {+ throw new Error('Failed to alias "' + from + '", it does not exist');+ }+ require.aliases[to] = from;+};++/**+ * Return a require function relative to the `parent` path.+ *+ * @param {String} parent+ * @return {Function}+ * @api private+ */++require.relative = function(parent) {+ var p = require.normalize(parent, '..');++ /**+ * lastIndexOf helper.+ */++ function lastIndexOf(arr, obj) {+ var i = arr.length;+ while (i--) {+ if (arr[i] === obj) return i;+ }+ return -1;+ }++ /**+ * The relative require() itself.+ */++ function localRequire(path) {+ var resolved = localRequire.resolve(path);+ return require(resolved, parent, path);+ }++ /**+ * Resolve relative to the parent.+ */++ localRequire.resolve = function(path) {+ var c = path.charAt(0);+ if ('/' == c) return path.slice(1);+ if ('.' == c) return require.normalize(p, path);++ // resolve deps by returning+ // the dep in the nearest "deps"+ // directory+ var segs = parent.split('/');+ var i = lastIndexOf(segs, 'deps') + 1;+ if (!i) i = 0;+ path = segs.slice(0, i + 1).join('/') + '/deps/' + path;+ return path;+ };++ /**+ * Check if module is defined at `path`.+ */++ localRequire.exists = function(path) {+ return require.modules.hasOwnProperty(localRequire.resolve(path));+ };++ return localRequire;+};+require.register("component-classes/index.js", function(exports, require, module){+/**+ * Module dependencies.+ */++var index = require('indexof');++/**+ * Whitespace regexp.+ */++var re = /\s+/;++/**+ * toString reference.+ */++var toString = Object.prototype.toString;++/**+ * Wrap `el` in a `ClassList`.+ *+ * @param {Element} el+ * @return {ClassList}+ * @api public+ */++module.exports = function(el){+ return new ClassList(el);+};++/**+ * Initialize a new ClassList for `el`.+ *+ * @param {Element} el+ * @api private+ */++function ClassList(el) {+ if (!el) throw new Error('A DOM element reference is required');+ this.el = el;+ this.list = el.classList;+}++/**+ * Add class `name` if not already present.+ *+ * @param {String} name+ * @return {ClassList}+ * @api public+ */++ClassList.prototype.add = function(name){+ // classList+ if (this.list) {+ this.list.add(name);+ return this;+ }++ // fallback+ var arr = this.array();+ var i = index(arr, name);+ if (!~i) arr.push(name);+ this.el.className = arr.join(' ');+ return this;+};++/**+ * Remove class `name` when present, or+ * pass a regular expression to remove+ * any which match.+ *+ * @param {String|RegExp} name+ * @return {ClassList}+ * @api public+ */++ClassList.prototype.remove = function(name){+ if ('[object RegExp]' == toString.call(name)) {+ return this.removeMatching(name);+ }++ // classList+ if (this.list) {+ this.list.remove(name);+ return this;+ }++ // fallback+ var arr = this.array();+ var i = index(arr, name);+ if (~i) arr.splice(i, 1);+ this.el.className = arr.join(' ');+ return this;+};++/**+ * Remove all classes matching `re`.+ *+ * @param {RegExp} re+ * @return {ClassList}+ * @api private+ */++ClassList.prototype.removeMatching = function(re){+ var arr = this.array();+ for (var i = 0; i < arr.length; i++) {+ if (re.test(arr[i])) {+ this.remove(arr[i]);+ }+ }+ return this;+};++/**+ * Toggle class `name`, can force state via `force`.+ *+ * For browsers that support classList, but do not support `force` yet,+ * the mistake will be detected and corrected.+ *+ * @param {String} name+ * @param {Boolean} force+ * @return {ClassList}+ * @api public+ */++ClassList.prototype.toggle = function(name, force){+ // classList+ if (this.list) {+ if ("undefined" !== typeof force) {+ if (force !== this.list.toggle(name, force)) {+ this.list.toggle(name); // toggle again to correct+ }+ } else {+ this.list.toggle(name);+ }+ return this;+ }++ // fallback+ if ("undefined" !== typeof force) {+ if (!force) {+ this.remove(name);+ } else {+ this.add(name);+ }+ } else {+ if (this.has(name)) {+ this.remove(name);+ } else {+ this.add(name);+ }+ }++ return this;+};++/**+ * Return an array of classes.+ *+ * @return {Array}+ * @api public+ */++ClassList.prototype.array = function(){+ var str = this.el.className.replace(/^\s+|\s+$/g, '');+ var arr = str.split(re);+ if ('' === arr[0]) arr.shift();+ return arr;+};++/**+ * Check if class `name` is present.+ *+ * @param {String} name+ * @return {ClassList}+ * @api public+ */++ClassList.prototype.has =+ClassList.prototype.contains = function(name){+ return this.list+ ? this.list.contains(name)+ : !! ~index(this.array(), name);+};++});+require.register("segmentio-extend/index.js", function(exports, require, module){++module.exports = function extend (object) {+ // Takes an unlimited number of extenders.+ var args = Array.prototype.slice.call(arguments, 1);++ // For each extender, copy their properties on our object.+ for (var i = 0, source; source = args[i]; i++) {+ if (!source) continue;+ for (var property in source) {+ object[property] = source[property];+ }+ }++ return object;+};+});+require.register("component-indexof/index.js", function(exports, require, module){+module.exports = function(arr, obj){+ if (arr.indexOf) return arr.indexOf(obj);+ for (var i = 0; i < arr.length; ++i) {+ if (arr[i] === obj) return i;+ }+ return -1;+};+});+require.register("component-event/index.js", function(exports, require, module){+var bind = window.addEventListener ? 'addEventListener' : 'attachEvent',+ unbind = window.removeEventListener ? 'removeEventListener' : 'detachEvent',+ prefix = bind !== 'addEventListener' ? 'on' : '';++/**+ * Bind `el` event `type` to `fn`.+ *+ * @param {Element} el+ * @param {String} type+ * @param {Function} fn+ * @param {Boolean} capture+ * @return {Function}+ * @api public+ */++exports.bind = function(el, type, fn, capture){+ el[bind](prefix + type, fn, capture || false);+ return fn;+};++/**+ * Unbind `el` event `type`'s callback `fn`.+ *+ * @param {Element} el+ * @param {String} type+ * @param {Function} fn+ * @param {Boolean} capture+ * @return {Function}+ * @api public+ */++exports.unbind = function(el, type, fn, capture){+ el[unbind](prefix + type, fn, capture || false);+ return fn;+};+});+require.register("timoxley-to-array/index.js", function(exports, require, module){+/**+ * Convert an array-like object into an `Array`.+ * If `collection` is already an `Array`, then will return a clone of `collection`.+ *+ * @param {Array | Mixed} collection An `Array` or array-like object to convert e.g. `arguments` or `NodeList`+ * @return {Array} Naive conversion of `collection` to a new `Array`.+ * @api public+ */++module.exports = function toArray(collection) {+ if (typeof collection === 'undefined') return []+ if (collection === null) return [null]+ if (collection === window) return [window]+ if (typeof collection === 'string') return [collection]+ if (isArray(collection)) return collection+ if (typeof collection.length != 'number') return [collection]+ if (typeof collection === 'function' && collection instanceof Function) return [collection]++ var arr = []+ for (var i = 0; i < collection.length; i++) {+ if (Object.prototype.hasOwnProperty.call(collection, i) || i in collection) {+ arr.push(collection[i])+ }+ }+ if (!arr.length) return []+ return arr+}++function isArray(arr) {+ return Object.prototype.toString.call(arr) === "[object Array]";+}++});+require.register("javve-events/index.js", function(exports, require, module){+var events = require('event'),+ toArray = require('to-array');++/**+ * Bind `el` event `type` to `fn`.+ *+ * @param {Element} el, NodeList, HTMLCollection or Array+ * @param {String} type+ * @param {Function} fn+ * @param {Boolean} capture+ * @api public+ */++exports.bind = function(el, type, fn, capture){+ el = toArray(el);+ for ( var i = 0; i < el.length; i++ ) {+ events.bind(el[i], type, fn, capture);+ }+};++/**+ * Unbind `el` event `type`'s callback `fn`.+ *+ * @param {Element} el, NodeList, HTMLCollection or Array+ * @param {String} type+ * @param {Function} fn+ * @param {Boolean} capture+ * @api public+ */++exports.unbind = function(el, type, fn, capture){+ el = toArray(el);+ for ( var i = 0; i < el.length; i++ ) {+ events.unbind(el[i], type, fn, capture);+ }+};++});+require.register("javve-get-by-class/index.js", function(exports, require, module){+/**+ * Find all elements with class `className` inside `container`.+ * Use `single = true` to increase performance in older browsers+ * when only one element is needed.+ *+ * @param {String} className+ * @param {Element} container+ * @param {Boolean} single+ * @api public+ */++module.exports = (function() {+ if (document.getElementsByClassName) {+ return function(container, className, single) {+ if (single) {+ return container.getElementsByClassName(className)[0];+ } else {+ return container.getElementsByClassName(className);+ }+ };+ } else if (document.querySelector) {+ return function(container, className, single) {+ className = '.' + className;+ if (single) {+ return container.querySelector(className);+ } else {+ return container.querySelectorAll(className);+ }+ };+ } else {+ return function(container, className, single) {+ var classElements = [],+ tag = '*';+ if (container == null) {+ container = document;+ }+ var els = container.getElementsByTagName(tag);+ var elsLen = els.length;+ var pattern = new RegExp("(^|\\s)"+className+"(\\s|$)");+ for (var i = 0, j = 0; i < elsLen; i++) {+ if ( pattern.test(els[i].className) ) {+ if (single) {+ return els[i];+ } else {+ classElements[j] = els[i];+ j++;+ }+ }+ }+ return classElements;+ };+ }+})();++});+require.register("javve-get-attribute/index.js", function(exports, require, module){+/**+ * Return the value for `attr` at `element`.+ *+ * @param {Element} el+ * @param {String} attr+ * @api public+ */++module.exports = function(el, attr) {+ var result = (el.getAttribute && el.getAttribute(attr)) || null;+ if( !result ) {+ var attrs = el.attributes;+ var length = attrs.length;+ for(var i = 0; i < length; i++) {+ if (attr[i] !== undefined) {+ if(attr[i].nodeName === attr) {+ result = attr[i].nodeValue;+ }+ }+ }+ }+ return result;+}+});+require.register("javve-natural-sort/index.js", function(exports, require, module){+/*+ * Natural Sort algorithm for Javascript - Version 0.7 - Released under MIT license+ * Author: Jim Palmer (based on chunking idea from Dave Koelle)+ */++module.exports = function(a, b, options) {+ var re = /(^-?[0-9]+(\.?[0-9]*)[df]?e?[0-9]?$|^0x[0-9a-f]+$|[0-9]+)/gi,+ sre = /(^[ ]*|[ ]*$)/g,+ dre = /(^([\w ]+,?[\w ]+)?[\w ]+,?[\w ]+\d+:\d+(:\d+)?[\w ]?|^\d{1,4}[\/\-]\d{1,4}[\/\-]\d{1,4}|^\w+, \w+ \d+, \d{4})/,+ hre = /^0x[0-9a-f]+$/i,+ ore = /^0/,+ options = options || {},+ i = function(s) { return options.insensitive && (''+s).toLowerCase() || ''+s },+ // convert all to strings strip whitespace+ x = i(a).replace(sre, '') || '',+ y = i(b).replace(sre, '') || '',+ // chunk/tokenize+ xN = x.replace(re, '\0$1\0').replace(/\0$/,'').replace(/^\0/,'').split('\0'),+ yN = y.replace(re, '\0$1\0').replace(/\0$/,'').replace(/^\0/,'').split('\0'),+ // numeric, hex or date detection+ xD = parseInt(x.match(hre)) || (xN.length != 1 && x.match(dre) && Date.parse(x)),+ yD = parseInt(y.match(hre)) || xD && y.match(dre) && Date.parse(y) || null,+ oFxNcL, oFyNcL,+ mult = options.desc ? -1 : 1;+ // first try and sort Hex codes or Dates+ if (yD)+ if ( xD < yD ) return -1 * mult;+ else if ( xD > yD ) return 1 * mult;+ // natural sorting through split numeric strings and default strings+ for(var cLoc=0, numS=Math.max(xN.length, yN.length); cLoc < numS; cLoc++) {+ // find floats not starting with '0', string or 0 if not defined (Clint Priest)+ oFxNcL = !(xN[cLoc] || '').match(ore) && parseFloat(xN[cLoc]) || xN[cLoc] || 0;+ oFyNcL = !(yN[cLoc] || '').match(ore) && parseFloat(yN[cLoc]) || yN[cLoc] || 0;+ // handle numeric vs string comparison - number < string - (Kyle Adams)+ if (isNaN(oFxNcL) !== isNaN(oFyNcL)) { return (isNaN(oFxNcL)) ? 1 : -1; }+ // rely on string comparison if different types - i.e. '02' < 2 != '02' < '2'+ else if (typeof oFxNcL !== typeof oFyNcL) {+ oFxNcL += '';+ oFyNcL += '';+ }+ if (oFxNcL < oFyNcL) return -1 * mult;+ if (oFxNcL > oFyNcL) return 1 * mult;+ }+ return 0;+};++/*+var defaultSort = getSortFunction();++module.exports = function(a, b, options) {+ if (arguments.length == 1) {+ options = a;+ return getSortFunction(options);+ } else {+ return defaultSort(a,b);+ }+}+*/+});+require.register("javve-to-string/index.js", function(exports, require, module){+module.exports = function(s) {+ s = (s === undefined) ? "" : s;+ s = (s === null) ? "" : s;+ s = s.toString();+ return s;+};++});+require.register("component-type/index.js", function(exports, require, module){+/**+ * toString ref.+ */++var toString = Object.prototype.toString;++/**+ * Return the type of `val`.+ *+ * @param {Mixed} val+ * @return {String}+ * @api public+ */++module.exports = function(val){+ switch (toString.call(val)) {+ case '[object Date]': return 'date';+ case '[object RegExp]': return 'regexp';+ case '[object Arguments]': return 'arguments';+ case '[object Array]': return 'array';+ case '[object Error]': return 'error';+ }++ if (val === null) return 'null';+ if (val === undefined) return 'undefined';+ if (val !== val) return 'nan';+ if (val && val.nodeType === 1) return 'element';++ return typeof val.valueOf();+};++});+require.register("list.js/index.js", function(exports, require, module){+/*+ListJS with beta 1.0.0+By Jonny Strömberg (www.jonnystromberg.com, www.listjs.com)+*/+(function( window, undefined ) {+"use strict";++var document = window.document,+ getByClass = require('get-by-class'),+ extend = require('extend'),+ indexOf = require('indexof');++var List = function(id, options, values) {++ var self = this,+ init,+ Item = require('./src/item')(self),+ addAsync = require('./src/add-async')(self),+ parse = require('./src/parse')(self);++ init = {+ start: function() {+ self.listClass = "list";+ self.searchClass = "search";+ self.sortClass = "sort";+ self.page = 1024;+ self.i = 1;+ self.items = [];+ self.visibleItems = [];+ self.matchingItems = [];+ self.searched = false;+ self.filtered = false;+ self.handlers = { 'updated': [] };+ self.plugins = {};+ self.helpers = {+ getByClass: getByClass,+ extend: extend,+ indexOf: indexOf+ };++ extend(self, options);++ self.listContainer = (typeof(id) === 'string') ? document.getElementById(id) : id;+ if (!self.listContainer) { return; }+ self.list = getByClass(self.listContainer, self.listClass, true);++ self.templater = require('./src/templater')(self);+ self.search = require('./src/search')(self);+ self.filter = require('./src/filter')(self);+ self.sort = require('./src/sort')(self);++ this.items();+ self.update();+ this.plugins();+ },+ items: function() {+ parse(self.list);+ if (values !== undefined) {+ self.add(values);+ }+ },+ plugins: function() {+ for (var i = 0; i < self.plugins.length; i++) {+ var plugin = self.plugins[i];+ self[plugin.name] = plugin;+ plugin.init(self);+ }+ }+ };+++ /*+ * Add object to list+ */+ this.add = function(values, callback) {+ if (callback) {+ addAsync(values, callback);+ return;+ }+ var added = [],+ notCreate = false;+ if (values[0] === undefined){+ values = [values];+ }+ for (var i = 0, il = values.length; i < il; i++) {+ var item = null;+ if (values[i] instanceof Item) {+ item = values[i];+ item.reload();+ } else {+ notCreate = (self.items.length > self.page) ? true : false;+ item = new Item(values[i], undefined, notCreate);+ }+ self.items.push(item);+ added.push(item);+ }+ self.update();+ return added;+ };++ this.show = function(i, page) {+ this.i = i;+ this.page = page;+ self.update();+ return self;+ };++ /* Removes object from list.+ * Loops through the list and removes objects where+ * property "valuename" === value+ */+ this.remove = function(valueName, value, options) {+ var found = 0;+ for (var i = 0, il = self.items.length; i < il; i++) {+ if (self.items[i].values()[valueName] == value) {+ self.templater.remove(self.items[i], options);+ self.items.splice(i,1);+ il--;+ i--;+ found++;+ }+ }+ self.update();+ return found;+ };++ /* Gets the objects in the list which+ * property "valueName" === value+ */+ this.get = function(valueName, value) {+ var matchedItems = [];+ for (var i = 0, il = self.items.length; i < il; i++) {+ var item = self.items[i];+ if (item.values()[valueName] == value) {+ matchedItems.push(item);+ }+ }+ return matchedItems;+ };++ /*+ * Get size of the list+ */+ this.size = function() {+ return self.items.length;+ };++ /*+ * Removes all items from the list+ */+ this.clear = function() {+ self.templater.clear();+ self.items = [];+ return self;+ };++ this.on = function(event, callback) {+ self.handlers[event].push(callback);+ return self;+ };++ this.off = function(event, callback) {+ var e = self.handlers[event];+ var index = indexOf(e, callback);+ if (index > -1) {+ e.splice(index, 1);+ }+ return self;+ };++ this.trigger = function(event) {+ var i = self.handlers[event].length;+ while(i--) {+ self.handlers[event][i](self);+ }+ return self;+ };++ this.reset = {+ filter: function() {+ var is = self.items,+ il = is.length;+ while (il--) {+ is[il].filtered = false;+ }+ return self;+ },+ search: function() {+ var is = self.items,+ il = is.length;+ while (il--) {+ is[il].found = false;+ }+ return self;+ }+ };++ this.update = function() {+ var is = self.items,+ il = is.length;++ self.visibleItems = [];+ self.matchingItems = [];+ self.templater.clear();+ for (var i = 0; i < il; i++) {+ if (is[i].matching() && ((self.matchingItems.length+1) >= self.i && self.visibleItems.length < self.page)) {+ is[i].show();+ self.visibleItems.push(is[i]);+ self.matchingItems.push(is[i]);+ } else if (is[i].matching()) {+ self.matchingItems.push(is[i]);+ is[i].hide();+ } else {+ is[i].hide();+ }+ }+ self.trigger('updated');+ return self;+ };++ init.start();+};++module.exports = List;++})(window);++});+require.register("list.js/src/search.js", function(exports, require, module){+var events = require('events'),+ getByClass = require('get-by-class'),+ toString = require('to-string');++module.exports = function(list) {+ var item,+ text,+ columns,+ searchString,+ customSearch;++ var prepare = {+ resetList: function() {+ list.i = 1;+ list.templater.clear();+ customSearch = undefined;+ },+ setOptions: function(args) {+ if (args.length == 2 && args[1] instanceof Array) {+ columns = args[1];+ } else if (args.length == 2 && typeof(args[1]) == "function") {+ customSearch = args[1];+ } else if (args.length == 3) {+ columns = args[1];+ customSearch = args[2];+ }+ },+ setColumns: function() {+ columns = (columns === undefined) ? prepare.toArray(list.items[0].values()) : columns;+ },+ setSearchString: function(s) {+ s = toString(s).toLowerCase();+ s = s.replace(/[-[\]{}()*+?.,\\^$|#]/g, "\\$&"); // Escape regular expression characters+ searchString = s;+ },+ toArray: function(values) {+ var tmpColumn = [];+ for (var name in values) {+ tmpColumn.push(name);+ }+ return tmpColumn;+ }+ };+ var search = {+ list: function() {+ for (var k = 0, kl = list.items.length; k < kl; k++) {+ search.item(list.items[k]);+ }+ },+ item: function(item) {+ item.found = false;+ for (var j = 0, jl = columns.length; j < jl; j++) {+ if (search.values(item.values(), columns[j])) {+ item.found = true;+ return;+ }+ }+ },+ values: function(values, column) {+ if (values.hasOwnProperty(column)) {+ text = toString(values[column]).toLowerCase();+ if ((searchString !== "") && (text.search(searchString) > -1)) {+ return true;+ }+ }+ return false;+ },+ reset: function() {+ list.reset.search();+ list.searched = false;+ }+ };++ var searchMethod = function(str) {+ list.trigger('searchStart');++ prepare.resetList();+ prepare.setSearchString(str);+ prepare.setOptions(arguments); // str, cols|searchFunction, searchFunction+ prepare.setColumns();++ if (searchString === "" ) {+ search.reset();+ } else {+ list.searched = true;+ if (customSearch) {+ customSearch(searchString, columns);+ } else {+ search.list();+ }+ }++ list.update();+ list.trigger('searchComplete');+ return list.visibleItems;+ };++ list.handlers.searchStart = list.handlers.searchStart || [];+ list.handlers.searchComplete = list.handlers.searchComplete || [];++ events.bind(getByClass(list.listContainer, list.searchClass), 'keyup', function(e) {+ var target = e.target || e.srcElement, // IE have srcElement+ alreadyCleared = (target.value === "" && !list.searched);+ if (!alreadyCleared) { // If oninput already have resetted the list, do nothing+ searchMethod(target.value);+ }+ });++ // Used to detect click on HTML5 clear button+ events.bind(getByClass(list.listContainer, list.searchClass), 'input', function(e) {+ var target = e.target || e.srcElement;+ if (target.value === "") {+ searchMethod('');+ }+ });++ list.helpers.toString = toString;+ return searchMethod;+};++});+require.register("list.js/src/sort.js", function(exports, require, module){+var naturalSort = require('natural-sort'),+ classes = require('classes'),+ events = require('events'),+ getByClass = require('get-by-class'),+ getAttribute = require('get-attribute');++module.exports = function(list) {+ list.sortFunction = list.sortFunction || function(itemA, itemB, options) {+ options.desc = options.order == "desc" ? true : false; // Natural sort uses this format+ return naturalSort(itemA.values()[options.valueName], itemB.values()[options.valueName], options);+ };++ var buttons = {+ els: undefined,+ clear: function() {+ for (var i = 0, il = buttons.els.length; i < il; i++) {+ classes(buttons.els[i]).remove('asc');+ classes(buttons.els[i]).remove('desc');+ }+ },+ getOrder: function(btn) {+ var predefinedOrder = getAttribute(btn, 'data-order');+ if (predefinedOrder == "asc" || predefinedOrder == "desc") {+ return predefinedOrder;+ } else if (classes(btn).has('desc')) {+ return "asc";+ } else if (classes(btn).has('asc')) {+ return "desc";+ } else {+ return "asc";+ }+ },+ getInSensitive: function(btn, options) {+ var insensitive = getAttribute(btn, 'data-insensitive');+ if (insensitive === "true") {+ options.insensitive = true;+ } else {+ options.insensitive = false;+ }+ },+ setOrder: function(options) {+ for (var i = 0, il = buttons.els.length; i < il; i++) {+ var btn = buttons.els[i];+ if (getAttribute(btn, 'data-sort') !== options.valueName) {+ continue;+ }+ var predefinedOrder = getAttribute(btn, 'data-order');+ if (predefinedOrder == "asc" || predefinedOrder == "desc") {+ if (predefinedOrder == options.order) {+ classes(btn).add(options.order);+ }+ } else {+ classes(btn).add(options.order);+ }+ }+ }+ };+ var sort = function() {+ list.trigger('sortStart');+ options = {};++ var target = arguments[0].currentTarget || arguments[0].srcElement || undefined;++ if (target) {+ options.valueName = getAttribute(target, 'data-sort');+ buttons.getInSensitive(target, options);+ options.order = buttons.getOrder(target);+ } else {+ options = arguments[1] || options;+ options.valueName = arguments[0];+ options.order = options.order || "asc";+ options.insensitive = (typeof options.insensitive == "undefined") ? true : options.insensitive;+ }+ buttons.clear();+ buttons.setOrder(options);++ options.sortFunction = options.sortFunction || list.sortFunction;+ list.items.sort(function(a, b) {+ return options.sortFunction(a, b, options);+ });+ list.update();+ list.trigger('sortComplete');+ };++ // Add handlers+ list.handlers.sortStart = list.handlers.sortStart || [];+ list.handlers.sortComplete = list.handlers.sortComplete || [];++ buttons.els = getByClass(list.listContainer, list.sortClass);+ events.bind(buttons.els, 'click', sort);+ list.on('searchStart', buttons.clear);+ list.on('filterStart', buttons.clear);++ // Helpers+ list.helpers.classes = classes;+ list.helpers.naturalSort = naturalSort;+ list.helpers.events = events;+ list.helpers.getAttribute = getAttribute;++ return sort;+};++});+require.register("list.js/src/item.js", function(exports, require, module){+module.exports = function(list) {+ return function(initValues, element, notCreate) {+ var item = this;++ this._values = {};++ this.found = false; // Show if list.searched == true and this.found == true+ this.filtered = false;// Show if list.filtered == true and this.filtered == true++ var init = function(initValues, element, notCreate) {+ if (element === undefined) {+ if (notCreate) {+ item.values(initValues, notCreate);+ } else {+ item.values(initValues);+ }+ } else {+ item.elm = element;+ var values = list.templater.get(item, initValues);+ item.values(values);+ }+ };+ this.values = function(newValues, notCreate) {+ if (newValues !== undefined) {+ for(var name in newValues) {+ item._values[name] = newValues[name];+ }+ if (notCreate !== true) {+ list.templater.set(item, item.values());+ }+ } else {+ return item._values;+ }+ };+ this.show = function() {+ list.templater.show(item);+ };+ this.hide = function() {+ list.templater.hide(item);+ };+ this.matching = function() {+ return (+ (list.filtered && list.searched && item.found && item.filtered) ||+ (list.filtered && !list.searched && item.filtered) ||+ (!list.filtered && list.searched && item.found) ||+ (!list.filtered && !list.searched)+ );+ };+ this.visible = function() {+ return (item.elm.parentNode == list.list) ? true : false;+ };+ init(initValues, element, notCreate);+ };+};++});+require.register("list.js/src/templater.js", function(exports, require, module){+var getByClass = require('get-by-class');++var Templater = function(list) {+ var itemSource = getItemSource(list.item),+ templater = this;++ function getItemSource(item) {+ if (item === undefined) {+ var nodes = list.list.childNodes,+ items = [];++ for (var i = 0, il = nodes.length; i < il; i++) {+ // Only textnodes have a data attribute+ if (nodes[i].data === undefined) {+ return nodes[i];+ }+ }+ return null;+ } else if (item.indexOf("<") !== -1) { // Try create html element of list, do not work for tables!!+ var div = document.createElement('div');+ div.innerHTML = item;+ return div.firstChild;+ } else {+ return document.getElementById(list.item);+ }+ }++ /* Get values from element */+ this.get = function(item, valueNames) {+ templater.create(item);+ var values = {};+ for(var i = 0, il = valueNames.length; i < il; i++) {+ var elm = getByClass(item.elm, valueNames[i], true);+ values[valueNames[i]] = elm ? elm.innerHTML : "";+ }+ return values;+ };++ /* Sets values at element */+ this.set = function(item, values) {+ if (!templater.create(item)) {+ for(var v in values) {+ if (values.hasOwnProperty(v)) {+ // TODO speed up if possible+ var elm = getByClass(item.elm, v, true);+ if (elm) {+ /* src attribute for image tag & text for other tags */+ if (elm.tagName === "IMG" && values[v] !== "") {+ elm.src = values[v];+ } else {+ elm.innerHTML = values[v];+ }+ }+ }+ }+ }+ };++ this.create = function(item) {+ if (item.elm !== undefined) {+ return false;+ }+ /* If item source does not exists, use the first item in list as+ source for new items */+ var newItem = itemSource.cloneNode(true);+ newItem.removeAttribute('id');+ item.elm = newItem;+ templater.set(item, item.values());+ return true;+ };+ this.remove = function(item) {+ list.list.removeChild(item.elm);+ };+ this.show = function(item) {+ templater.create(item);+ list.list.appendChild(item.elm);+ };+ this.hide = function(item) {+ if (item.elm !== undefined && item.elm.parentNode === list.list) {+ list.list.removeChild(item.elm);+ }+ };+ this.clear = function() {+ /* .innerHTML = ''; fucks up IE */+ if (list.list.hasChildNodes()) {+ while (list.list.childNodes.length >= 1)+ {+ list.list.removeChild(list.list.firstChild);+ }+ }+ };+};++module.exports = function(list) {+ return new Templater(list);+};++});+require.register("list.js/src/filter.js", function(exports, require, module){+module.exports = function(list) {++ // Add handlers+ list.handlers.filterStart = list.handlers.filterStart || [];+ list.handlers.filterComplete = list.handlers.filterComplete || [];++ return function(filterFunction) {+ list.trigger('filterStart');+ list.i = 1; // Reset paging+ list.reset.filter();+ if (filterFunction === undefined) {+ list.filtered = false;+ } else {+ list.filtered = true;+ var is = list.items;+ for (var i = 0, il = is.length; i < il; i++) {+ var item = is[i];+ if (filterFunction(item)) {+ item.filtered = true;+ } else {+ item.filtered = false;+ }+ }+ }+ list.update();+ list.trigger('filterComplete');+ return list.visibleItems;+ };+};++});+require.register("list.js/src/add-async.js", function(exports, require, module){+module.exports = function(list) {+ return function(values, callback, items) {+ var valuesToAdd = values.splice(0, 100);+ items = items || [];+ items = items.concat(list.add(valuesToAdd));+ if (values.length > 0) {+ setTimeout(function() {+ addAsync(values, callback, items);+ }, 10);+ } else {+ list.update();+ callback(items);+ }+ };+};+});+require.register("list.js/src/parse.js", function(exports, require, module){+module.exports = function(list) {++ var Item = require('./item')(list);++ var getChildren = function(parent) {+ var nodes = parent.childNodes,+ items = [];+ for (var i = 0, il = nodes.length; i < il; i++) {+ // Only textnodes have a data attribute+ if (nodes[i].data === undefined) {+ items.push(nodes[i]);+ }+ }+ return items;+ };++ var parse = function(itemElements, valueNames) {+ for (var i = 0, il = itemElements.length; i < il; i++) {+ list.items.push(new Item(valueNames, itemElements[i]));+ }+ };+ var parseAsync = function(itemElements, valueNames) {+ var itemsToIndex = itemElements.splice(0, 100); // TODO: If < 100 items, what happens in IE etc?+ parse(itemsToIndex, valueNames);+ if (itemElements.length > 0) {+ setTimeout(function() {+ init.items.indexAsync(itemElements, valueNames);+ }, 10);+ } else {+ list.update();+ // TODO: Add indexed callback+ }+ };++ return function() {+ var itemsToIndex = getChildren(list.list),+ valueNames = list.valueNames;++ if (list.indexAsync) {+ parseAsync(itemsToIndex, valueNames);+ } else {+ parse(itemsToIndex, valueNames);+ }+ };+};++});+++++++++++++++++++++require.alias("component-classes/index.js", "list.js/deps/classes/index.js");+require.alias("component-classes/index.js", "classes/index.js");+require.alias("component-indexof/index.js", "component-classes/deps/indexof/index.js");++require.alias("segmentio-extend/index.js", "list.js/deps/extend/index.js");+require.alias("segmentio-extend/index.js", "extend/index.js");++require.alias("component-indexof/index.js", "list.js/deps/indexof/index.js");+require.alias("component-indexof/index.js", "indexof/index.js");++require.alias("javve-events/index.js", "list.js/deps/events/index.js");+require.alias("javve-events/index.js", "events/index.js");+require.alias("component-event/index.js", "javve-events/deps/event/index.js");++require.alias("timoxley-to-array/index.js", "javve-events/deps/to-array/index.js");++require.alias("javve-get-by-class/index.js", "list.js/deps/get-by-class/index.js");+require.alias("javve-get-by-class/index.js", "get-by-class/index.js");++require.alias("javve-get-attribute/index.js", "list.js/deps/get-attribute/index.js");+require.alias("javve-get-attribute/index.js", "get-attribute/index.js");++require.alias("javve-natural-sort/index.js", "list.js/deps/natural-sort/index.js");+require.alias("javve-natural-sort/index.js", "natural-sort/index.js");++require.alias("javve-to-string/index.js", "list.js/deps/to-string/index.js");+require.alias("javve-to-string/index.js", "list.js/deps/to-string/index.js");+require.alias("javve-to-string/index.js", "to-string/index.js");+require.alias("javve-to-string/index.js", "javve-to-string/index.js");+require.alias("component-type/index.js", "list.js/deps/type/index.js");+require.alias("component-type/index.js", "type/index.js");+if (typeof exports == "object") {+ module.exports = require("list.js");+} else if (typeof define == "function" && define.amd) {+ define(function(){ return require("list.js"); });+} else {+ this["List"] = require("list.js");+}})();diff --git a/app/assets/javascripts/blazer/moment.js b/app/assets/javascripts/blazer/moment.jsnew file mode 100644index 00000000..b79da7f2--- /dev/null+++ b/app/assets/javascripts/blazer/moment.js@@ -0,0 +1,2400 @@+//! moment.js+//! version : 2.5.1+//! authors : Tim Wood, Iskren Chernev, Moment.js contributors+//! license : MIT+//! momentjs.com++(function (undefined) {++ /************************************+ Constants+ ************************************/++ var moment,+ VERSION = "2.5.1",+ global = this,+ round = Math.round,+ i,++ YEAR = 0,+ MONTH = 1,+ DATE = 2,+ HOUR = 3,+ MINUTE = 4,+ SECOND = 5,+ MILLISECOND = 6,++ // internal storage for language config files+ languages = {},++ // moment internal properties+ momentProperties = {+ _isAMomentObject: null,+ _i : null,+ _f : null,+ _l : null,+ _strict : null,+ _isUTC : null,+ _offset : null, // optional. Combine with _isUTC+ _pf : null,+ _lang : null // optional+ },++ // check for nodeJS+ hasModule = (typeof module !== 'undefined' && module.exports && typeof require !== 'undefined'),++ // ASP.NET json date format regex+ aspNetJsonRegex = /^\/?Date\((\-?\d+)/i,+ aspNetTimeSpanJsonRegex = /(\-)?(?:(\d*)\.)?(\d+)\:(\d+)(?:\:(\d+)\.?(\d{3})?)?/,++ // from http://docs.closure-library.googlecode.com/git/closure_goog_date_date.js.source.html+ // somewhat more in line with 4.4.3.2 2004 spec, but allows decimal anywhere+ isoDurationRegex = /^(-)?P(?:(?:([0-9,.]*)Y)?(?:([0-9,.]*)M)?(?:([0-9,.]*)D)?(?:T(?:([0-9,.]*)H)?(?:([0-9,.]*)M)?(?:([0-9,.]*)S)?)?|([0-9,.]*)W)$/,++ // format tokens+ formattingTokens = /(\[[^\[]*\])|(\\)?(Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|mm?|ss?|S{1,4}|X|zz?|ZZ?|.)/g,+ localFormattingTokens = /(\[[^\[]*\])|(\\)?(LT|LL?L?L?|l{1,4})/g,++ // parsing token regexes+ parseTokenOneOrTwoDigits = /\d\d?/, // 0 - 99+ parseTokenOneToThreeDigits = /\d{1,3}/, // 0 - 999+ parseTokenOneToFourDigits = /\d{1,4}/, // 0 - 9999+ parseTokenOneToSixDigits = /[+\-]?\d{1,6}/, // -999,999 - 999,999+ parseTokenDigits = /\d+/, // nonzero number of digits+ parseTokenWord = /[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF\/]+(\s*?[\u0600-\u06FF]+){1,2}/i, // any word (or two) characters or numbers including two/three word month in arabic.+ parseTokenTimezone = /Z|[\+\-]\d\d:?\d\d/gi, // +00:00 -00:00 +0000 -0000 or Z+ parseTokenT = /T/i, // T (ISO separator)+ parseTokenTimestampMs = /[\+\-]?\d+(\.\d{1,3})?/, // 123456789 123456789.123++ //strict parsing regexes+ parseTokenOneDigit = /\d/, // 0 - 9+ parseTokenTwoDigits = /\d\d/, // 00 - 99+ parseTokenThreeDigits = /\d{3}/, // 000 - 999+ parseTokenFourDigits = /\d{4}/, // 0000 - 9999+ parseTokenSixDigits = /[+-]?\d{6}/, // -999,999 - 999,999+ parseTokenSignedNumber = /[+-]?\d+/, // -inf - inf++ // iso 8601 regex+ // 0000-00-00 0000-W00 or 0000-W00-0 + T + 00 or 00:00 or 00:00:00 or 00:00:00.000 + +00:00 or +0000 or +00)+ isoRegex = /^\s*(?:[+-]\d{6}|\d{4})-(?:(\d\d-\d\d)|(W\d\d$)|(W\d\d-\d)|(\d\d\d))((T| )(\d\d(:\d\d(:\d\d(\.\d+)?)?)?)?([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,++ isoFormat = 'YYYY-MM-DDTHH:mm:ssZ',++ isoDates = [+ ['YYYYYY-MM-DD', /[+-]\d{6}-\d{2}-\d{2}/],+ ['YYYY-MM-DD', /\d{4}-\d{2}-\d{2}/],+ ['GGGG-[W]WW-E', /\d{4}-W\d{2}-\d/],+ ['GGGG-[W]WW', /\d{4}-W\d{2}/],+ ['YYYY-DDD', /\d{4}-\d{3}/]+ ],++ // iso time formats and regexes+ isoTimes = [+ ['HH:mm:ss.SSSS', /(T| )\d\d:\d\d:\d\d\.\d{1,3}/],+ ['HH:mm:ss', /(T| )\d\d:\d\d:\d\d/],+ ['HH:mm', /(T| )\d\d:\d\d/],+ ['HH', /(T| )\d\d/]+ ],++ // timezone chunker "+10:00" > ["10", "00"] or "-1530" > ["-15", "30"]+ parseTimezoneChunker = /([\+\-]|\d\d)/gi,++ // getter and setter names+ proxyGettersAndSetters = 'Date|Hours|Minutes|Seconds|Milliseconds'.split('|'),+ unitMillisecondFactors = {+ 'Milliseconds' : 1,+ 'Seconds' : 1e3,+ 'Minutes' : 6e4,+ 'Hours' : 36e5,+ 'Days' : 864e5,+ 'Months' : 2592e6,+ 'Years' : 31536e6+ },++ unitAliases = {+ ms : 'millisecond',+ s : 'second',+ m : 'minute',+ h : 'hour',+ d : 'day',+ D : 'date',+ w : 'week',+ W : 'isoWeek',+ M : 'month',+ y : 'year',+ DDD : 'dayOfYear',+ e : 'weekday',+ E : 'isoWeekday',+ gg: 'weekYear',+ GG: 'isoWeekYear'+ },++ camelFunctions = {+ dayofyear : 'dayOfYear',+ isoweekday : 'isoWeekday',+ isoweek : 'isoWeek',+ weekyear : 'weekYear',+ isoweekyear : 'isoWeekYear'+ },++ // format function strings+ formatFunctions = {},++ // tokens to ordinalize and pad+ ordinalizeTokens = 'DDD w W M D d'.split(' '),+ paddedTokens = 'M D H h m s w W'.split(' '),++ formatTokenFunctions = {+ M : function () {+ return this.month() + 1;+ },+ MMM : function (format) {+ return this.lang().monthsShort(this, format);+ },+ MMMM : function (format) {+ return this.lang().months(this, format);+ },+ D : function () {+ return this.date();+ },+ DDD : function () {+ return this.dayOfYear();+ },+ d : function () {+ return this.day();+ },+ dd : function (format) {+ return this.lang().weekdaysMin(this, format);+ },+ ddd : function (format) {+ return this.lang().weekdaysShort(this, format);+ },+ dddd : function (format) {+ return this.lang().weekdays(this, format);+ },+ w : function () {+ return this.week();+ },+ W : function () {+ return this.isoWeek();+ },+ YY : function () {+ return leftZeroFill(this.year() % 100, 2);+ },+ YYYY : function () {+ return leftZeroFill(this.year(), 4);+ },+ YYYYY : function () {+ return leftZeroFill(this.year(), 5);+ },+ YYYYYY : function () {+ var y = this.year(), sign = y >= 0 ? '+' : '-';+ return sign + leftZeroFill(Math.abs(y), 6);+ },+ gg : function () {+ return leftZeroFill(this.weekYear() % 100, 2);+ },+ gggg : function () {+ return leftZeroFill(this.weekYear(), 4);+ },+ ggggg : function () {+ return leftZeroFill(this.weekYear(), 5);+ },+ GG : function () {+ return leftZeroFill(this.isoWeekYear() % 100, 2);+ },+ GGGG : function () {+ return leftZeroFill(this.isoWeekYear(), 4);+ },+ GGGGG : function () {+ return leftZeroFill(this.isoWeekYear(), 5);+ },+ e : function () {+ return this.weekday();+ },+ E : function () {+ return this.isoWeekday();+ },+ a : function () {+ return this.lang().meridiem(this.hours(), this.minutes(), true);+ },+ A : function () {+ return this.lang().meridiem(this.hours(), this.minutes(), false);+ },+ H : function () {+ return this.hours();+ },+ h : function () {+ return this.hours() % 12 || 12;+ },+ m : function () {+ return this.minutes();+ },+ s : function () {+ return this.seconds();+ },+ S : function () {+ return toInt(this.milliseconds() / 100);+ },+ SS : function () {+ return leftZeroFill(toInt(this.milliseconds() / 10), 2);+ },+ SSS : function () {+ return leftZeroFill(this.milliseconds(), 3);+ },+ SSSS : function () {+ return leftZeroFill(this.milliseconds(), 3);+ },+ Z : function () {+ var a = -this.zone(),+ b = "+";+ if (a < 0) {+ a = -a;+ b = "-";+ }+ return b + leftZeroFill(toInt(a / 60), 2) + ":" + leftZeroFill(toInt(a) % 60, 2);+ },+ ZZ : function () {+ var a = -this.zone(),+ b = "+";+ if (a < 0) {+ a = -a;+ b = "-";+ }+ return b + leftZeroFill(toInt(a / 60), 2) + leftZeroFill(toInt(a) % 60, 2);+ },+ z : function () {+ return this.zoneAbbr();+ },+ zz : function () {+ return this.zoneName();+ },+ X : function () {+ return this.unix();+ },+ Q : function () {+ return this.quarter();+ }+ },++ lists = ['months', 'monthsShort', 'weekdays', 'weekdaysShort', 'weekdaysMin'];++ function defaultParsingFlags() {+ // We need to deep clone this object, and es5 standard is not very+ // helpful.+ return {+ empty : false,+ unusedTokens : [],+ unusedInput : [],+ overflow : -2,+ charsLeftOver : 0,+ nullInput : false,+ invalidMonth : null,+ invalidFormat : false,+ userInvalidated : false,+ iso: false+ };+ }++ function padToken(func, count) {+ return function (a) {+ return leftZeroFill(func.call(this, a), count);+ };+ }+ function ordinalizeToken(func, period) {+ return function (a) {+ return this.lang().ordinal(func.call(this, a), period);+ };+ }++ while (ordinalizeTokens.length) {+ i = ordinalizeTokens.pop();+ formatTokenFunctions[i + 'o'] = ordinalizeToken(formatTokenFunctions[i], i);+ }+ while (paddedTokens.length) {+ i = paddedTokens.pop();+ formatTokenFunctions[i + i] = padToken(formatTokenFunctions[i], 2);+ }+ formatTokenFunctions.DDDD = padToken(formatTokenFunctions.DDD, 3);+++ /************************************+ Constructors+ ************************************/++ function Language() {++ }++ // Moment prototype object+ function Moment(config) {+ checkOverflow(config);+ extend(this, config);+ }++ // Duration Constructor+ function Duration(duration) {+ var normalizedInput = normalizeObjectUnits(duration),+ years = normalizedInput.year || 0,+ months = normalizedInput.month || 0,+ weeks = normalizedInput.week || 0,+ days = normalizedInput.day || 0,+ hours = normalizedInput.hour || 0,+ minutes = normalizedInput.minute || 0,+ seconds = normalizedInput.second || 0,+ milliseconds = normalizedInput.millisecond || 0;++ // representation for dateAddRemove+ this._milliseconds = +milliseconds ++ seconds * 1e3 + // 1000+ minutes * 6e4 + // 1000 * 60+ hours * 36e5; // 1000 * 60 * 60+ // Because of dateAddRemove treats 24 hours as different from a+ // day when working around DST, we need to store them separately+ this._days = +days ++ weeks * 7;+ // It is impossible translate months into days without knowing+ // which months you are are talking about, so we have to store+ // it separately.+ this._months = +months ++ years * 12;++ this._data = {};++ this._bubble();+ }++ /************************************+ Helpers+ ************************************/+++ function extend(a, b) {+ for (var i in b) {+ if (b.hasOwnProperty(i)) {+ a[i] = b[i];+ }+ }++ if (b.hasOwnProperty("toString")) {+ a.toString = b.toString;+ }++ if (b.hasOwnProperty("valueOf")) {+ a.valueOf = b.valueOf;+ }++ return a;+ }++ function cloneMoment(m) {+ var result = {}, i;+ for (i in m) {+ if (m.hasOwnProperty(i) && momentProperties.hasOwnProperty(i)) {+ result[i] = m[i];+ }+ }++ return result;+ }++ function absRound(number) {+ if (number < 0) {+ return Math.ceil(number);+ } else {+ return Math.floor(number);+ }+ }++ // left zero fill a number+ // see http://jsperf.com/left-zero-filling for performance comparison+ function leftZeroFill(number, targetLength, forceSign) {+ var output = '' + Math.abs(number),+ sign = number >= 0;++ while (output.length < targetLength) {+ output = '0' + output;+ }+ return (sign ? (forceSign ? '+' : '') : '-') + output;+ }++ // helper function for _.addTime and _.subtractTime+ function addOrSubtractDurationFromMoment(mom, duration, isAdding, ignoreUpdateOffset) {+ var milliseconds = duration._milliseconds,+ days = duration._days,+ months = duration._months,+ minutes,+ hours;++ if (milliseconds) {+ mom._d.setTime(+mom._d + milliseconds * isAdding);+ }+ // store the minutes and hours so we can restore them+ if (days || months) {+ minutes = mom.minute();+ hours = mom.hour();+ }+ if (days) {+ mom.date(mom.date() + days * isAdding);+ }+ if (months) {+ mom.month(mom.month() + months * isAdding);+ }+ if (milliseconds && !ignoreUpdateOffset) {+ moment.updateOffset(mom);+ }+ // restore the minutes and hours after possibly changing dst+ if (days || months) {+ mom.minute(minutes);+ mom.hour(hours);+ }+ }++ // check if is an array+ function isArray(input) {+ return Object.prototype.toString.call(input) === '[object Array]';+ }++ function isDate(input) {+ return Object.prototype.toString.call(input) === '[object Date]' ||+ input instanceof Date;+ }++ // compare two arrays, return the number of differences+ function compareArrays(array1, array2, dontConvert) {+ var len = Math.min(array1.length, array2.length),+ lengthDiff = Math.abs(array1.length - array2.length),+ diffs = 0,+ i;+ for (i = 0; i < len; i++) {+ if ((dontConvert && array1[i] !== array2[i]) ||+ (!dontConvert && toInt(array1[i]) !== toInt(array2[i]))) {+ diffs++;+ }+ }+ return diffs + lengthDiff;+ }++ function normalizeUnits(units) {+ if (units) {+ var lowered = units.toLowerCase().replace(/(.)s$/, '$1');+ units = unitAliases[units] || camelFunctions[lowered] || lowered;+ }+ return units;+ }++ function normalizeObjectUnits(inputObject) {+ var normalizedInput = {},+ normalizedProp,+ prop;++ for (prop in inputObject) {+ if (inputObject.hasOwnProperty(prop)) {+ normalizedProp = normalizeUnits(prop);+ if (normalizedProp) {+ normalizedInput[normalizedProp] = inputObject[prop];+ }+ }+ }++ return normalizedInput;+ }++ function makeList(field) {+ var count, setter;++ if (field.indexOf('week') === 0) {+ count = 7;+ setter = 'day';+ }+ else if (field.indexOf('month') === 0) {+ count = 12;+ setter = 'month';+ }+ else {+ return;+ }++ moment[field] = function (format, index) {+ var i, getter,+ method = moment.fn._lang[field],+ results = [];++ if (typeof format === 'number') {+ index = format;+ format = undefined;+ }++ getter = function (i) {+ var m = moment().utc().set(setter, i);+ return method.call(moment.fn._lang, m, format || '');+ };++ if (index != null) {+ return getter(index);+ }+ else {+ for (i = 0; i < count; i++) {+ results.push(getter(i));+ }+ return results;+ }+ };+ }++ function toInt(argumentForCoercion) {+ var coercedNumber = +argumentForCoercion,+ value = 0;++ if (coercedNumber !== 0 && isFinite(coercedNumber)) {+ if (coercedNumber >= 0) {+ value = Math.floor(coercedNumber);+ } else {+ value = Math.ceil(coercedNumber);+ }+ }++ return value;+ }++ function daysInMonth(year, month) {+ return new Date(Date.UTC(year, month + 1, 0)).getUTCDate();+ }++ function daysInYear(year) {+ return isLeapYear(year) ? 366 : 365;+ }++ function isLeapYear(year) {+ return (year % 4 === 0 && year % 100 !== 0) || year % 400 === 0;+ }++ function checkOverflow(m) {+ var overflow;+ if (m._a && m._pf.overflow === -2) {+ overflow =+ m._a[MONTH] < 0 || m._a[MONTH] > 11 ? MONTH :+ m._a[DATE] < 1 || m._a[DATE] > daysInMonth(m._a[YEAR], m._a[MONTH]) ? DATE :+ m._a[HOUR] < 0 || m._a[HOUR] > 23 ? HOUR :+ m._a[MINUTE] < 0 || m._a[MINUTE] > 59 ? MINUTE :+ m._a[SECOND] < 0 || m._a[SECOND] > 59 ? SECOND :+ m._a[MILLISECOND] < 0 || m._a[MILLISECOND] > 999 ? MILLISECOND :+ -1;++ if (m._pf._overflowDayOfYear && (overflow < YEAR || overflow > DATE)) {+ overflow = DATE;+ }++ m._pf.overflow = overflow;+ }+ }++ function isValid(m) {+ if (m._isValid == null) {+ m._isValid = !isNaN(m._d.getTime()) &&+ m._pf.overflow < 0 &&+ !m._pf.empty &&+ !m._pf.invalidMonth &&+ !m._pf.nullInput &&+ !m._pf.invalidFormat &&+ !m._pf.userInvalidated;++ if (m._strict) {+ m._isValid = m._isValid &&+ m._pf.charsLeftOver === 0 &&+ m._pf.unusedTokens.length === 0;+ }+ }+ return m._isValid;+ }++ function normalizeLanguage(key) {+ return key ? key.toLowerCase().replace('_', '-') : key;+ }++ // Return a moment from input, that is local/utc/zone equivalent to model.+ function makeAs(input, model) {+ return model._isUTC ? moment(input).zone(model._offset || 0) :+ moment(input).local();+ }++ /************************************+ Languages+ ************************************/+++ extend(Language.prototype, {++ set : function (config) {+ var prop, i;+ for (i in config) {+ prop = config[i];+ if (typeof prop === 'function') {+ this[i] = prop;+ } else {+ this['_' + i] = prop;+ }+ }+ },++ _months : "January_February_March_April_May_June_July_August_September_October_November_December".split("_"),+ months : function (m) {+ return this._months[m.month()];+ },++ _monthsShort : "Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),+ monthsShort : function (m) {+ return this._monthsShort[m.month()];+ },++ monthsParse : function (monthName) {+ var i, mom, regex;++ if (!this._monthsParse) {+ this._monthsParse = [];+ }++ for (i = 0; i < 12; i++) {+ // make the regex if we don't have it already+ if (!this._monthsParse[i]) {+ mom = moment.utc([2000, i]);+ regex = '^' + this.months(mom, '') + '|^' + this.monthsShort(mom, '');+ this._monthsParse[i] = new RegExp(regex.replace('.', ''), 'i');+ }+ // test the regex+ if (this._monthsParse[i].test(monthName)) {+ return i;+ }+ }+ },++ _weekdays : "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),+ weekdays : function (m) {+ return this._weekdays[m.day()];+ },++ _weekdaysShort : "Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),+ weekdaysShort : function (m) {+ return this._weekdaysShort[m.day()];+ },++ _weekdaysMin : "Su_Mo_Tu_We_Th_Fr_Sa".split("_"),+ weekdaysMin : function (m) {+ return this._weekdaysMin[m.day()];+ },++ weekdaysParse : function (weekdayName) {+ var i, mom, regex;++ if (!this._weekdaysParse) {+ this._weekdaysParse = [];+ }++ for (i = 0; i < 7; i++) {+ // make the regex if we don't have it already+ if (!this._weekdaysParse[i]) {+ mom = moment([2000, 1]).day(i);+ regex = '^' + this.weekdays(mom, '') + '|^' + this.weekdaysShort(mom, '') + '|^' + this.weekdaysMin(mom, '');+ this._weekdaysParse[i] = new RegExp(regex.replace('.', ''), 'i');+ }+ // test the regex+ if (this._weekdaysParse[i].test(weekdayName)) {+ return i;+ }+ }+ },++ _longDateFormat : {+ LT : "h:mm A",+ L : "MM/DD/YYYY",+ LL : "MMMM D YYYY",+ LLL : "MMMM D YYYY LT",+ LLLL : "dddd, MMMM D YYYY LT"+ },+ longDateFormat : function (key) {+ var output = this._longDateFormat[key];+ if (!output && this._longDateFormat[key.toUpperCase()]) {+ output = this._longDateFormat[key.toUpperCase()].replace(/MMMM|MM|DD|dddd/g, function (val) {+ return val.slice(1);+ });+ this._longDateFormat[key] = output;+ }+ return output;+ },++ isPM : function (input) {+ // IE8 Quirks Mode & IE7 Standards Mode do not allow accessing strings like arrays+ // Using charAt should be more compatible.+ return ((input + '').toLowerCase().charAt(0) === 'p');+ },++ _meridiemParse : /[ap]\.?m?\.?/i,+ meridiem : function (hours, minutes, isLower) {+ if (hours > 11) {+ return isLower ? 'pm' : 'PM';+ } else {+ return isLower ? 'am' : 'AM';+ }+ },++ _calendar : {+ sameDay : '[Today at] LT',+ nextDay : '[Tomorrow at] LT',+ nextWeek : 'dddd [at] LT',+ lastDay : '[Yesterday at] LT',+ lastWeek : '[Last] dddd [at] LT',+ sameElse : 'L'+ },+ calendar : function (key, mom) {+ var output = this._calendar[key];+ return typeof output === 'function' ? output.apply(mom) : output;+ },++ _relativeTime : {+ future : "in %s",+ past : "%s ago",+ s : "a few seconds",+ m : "a minute",+ mm : "%d minutes",+ h : "an hour",+ hh : "%d hours",+ d : "a day",+ dd : "%d days",+ M : "a month",+ MM : "%d months",+ y : "a year",+ yy : "%d years"+ },+ relativeTime : function (number, withoutSuffix, string, isFuture) {+ var output = this._relativeTime[string];+ return (typeof output === 'function') ?+ output(number, withoutSuffix, string, isFuture) :+ output.replace(/%d/i, number);+ },+ pastFuture : function (diff, output) {+ var format = this._relativeTime[diff > 0 ? 'future' : 'past'];+ return typeof format === 'function' ? format(output) : format.replace(/%s/i, output);+ },++ ordinal : function (number) {+ return this._ordinal.replace("%d", number);+ },+ _ordinal : "%d",++ preparse : function (string) {+ return string;+ },++ postformat : function (string) {+ return string;+ },++ week : function (mom) {+ return weekOfYear(mom, this._week.dow, this._week.doy).week;+ },++ _week : {+ dow : 0, // Sunday is the first day of the week.+ doy : 6 // The week that contains Jan 1st is the first week of the year.+ },++ _invalidDate: 'Invalid date',+ invalidDate: function () {+ return this._invalidDate;+ }+ });++ // Loads a language definition into the `languages` cache. The function+ // takes a key and optionally values. If not in the browser and no values+ // are provided, it will load the language file module. As a convenience,+ // this function also returns the language values.+ function loadLang(key, values) {+ values.abbr = key;+ if (!languages[key]) {+ languages[key] = new Language();+ }+ languages[key].set(values);+ return languages[key];+ }++ // Remove a language from the `languages` cache. Mostly useful in tests.+ function unloadLang(key) {+ delete languages[key];+ }++ // Determines which language definition to use and returns it.+ //+ // With no parameters, it will return the global language. If you+ // pass in a language key, such as 'en', it will return the+ // definition for 'en', so long as 'en' has already been loaded using+ // moment.lang.+ function getLangDefinition(key) {+ var i = 0, j, lang, next, split,+ get = function (k) {+ if (!languages[k] && hasModule) {+ try {+ require('./lang/' + k);+ } catch (e) { }+ }+ return languages[k];+ };++ if (!key) {+ return moment.fn._lang;+ }++ if (!isArray(key)) {+ //short-circuit everything else+ lang = get(key);+ if (lang) {+ return lang;+ }+ key = [key];+ }++ //pick the language from the array+ //try ['en-au', 'en-gb'] as 'en-au', 'en-gb', 'en', as in move through the list trying each+ //substring from most specific to least, but move to the next array item if it's a more specific variant than the current root+ while (i < key.length) {+ split = normalizeLanguage(key[i]).split('-');+ j = split.length;+ next = normalizeLanguage(key[i + 1]);+ next = next ? next.split('-') : null;+ while (j > 0) {+ lang = get(split.slice(0, j).join('-'));+ if (lang) {+ return lang;+ }+ if (next && next.length >= j && compareArrays(split, next, true) >= j - 1) {+ //the next array item is better than a shallower substring of this one+ break;+ }+ j--;+ }+ i++;+ }+ return moment.fn._lang;+ }++ /************************************+ Formatting+ ************************************/+++ function removeFormattingTokens(input) {+ if (input.match(/\[[\s\S]/)) {+ return input.replace(/^\[|\]$/g, "");+ }+ return input.replace(/\\/g, "");+ }++ function makeFormatFunction(format) {+ var array = format.match(formattingTokens), i, length;++ for (i = 0, length = array.length; i < length; i++) {+ if (formatTokenFunctions[array[i]]) {+ array[i] = formatTokenFunctions[array[i]];+ } else {+ array[i] = removeFormattingTokens(array[i]);+ }+ }++ return function (mom) {+ var output = "";+ for (i = 0; i < length; i++) {+ output += array[i] instanceof Function ? array[i].call(mom, format) : array[i];+ }+ return output;+ };+ }++ // format date using native date object+ function formatMoment(m, format) {++ if (!m.isValid()) {+ return m.lang().invalidDate();+ }++ format = expandFormat(format, m.lang());++ if (!formatFunctions[format]) {+ formatFunctions[format] = makeFormatFunction(format);+ }++ return formatFunctions[format](m);+ }++ function expandFormat(format, lang) {+ var i = 5;++ function replaceLongDateFormatTokens(input) {+ return lang.longDateFormat(input) || input;+ }++ localFormattingTokens.lastIndex = 0;+ while (i >= 0 && localFormattingTokens.test(format)) {+ format = format.replace(localFormattingTokens, replaceLongDateFormatTokens);+ localFormattingTokens.lastIndex = 0;+ i -= 1;+ }++ return format;+ }+++ /************************************+ Parsing+ ************************************/+++ // get the regex to find the next token+ function getParseRegexForToken(token, config) {+ var a, strict = config._strict;+ switch (token) {+ case 'DDDD':+ return parseTokenThreeDigits;+ case 'YYYY':+ case 'GGGG':+ case 'gggg':+ return strict ? parseTokenFourDigits : parseTokenOneToFourDigits;+ case 'Y':+ case 'G':+ case 'g':+ return parseTokenSignedNumber;+ case 'YYYYYY':+ case 'YYYYY':+ case 'GGGGG':+ case 'ggggg':+ return strict ? parseTokenSixDigits : parseTokenOneToSixDigits;+ case 'S':+ if (strict) { return parseTokenOneDigit; }+ /* falls through */+ case 'SS':+ if (strict) { return parseTokenTwoDigits; }+ /* falls through */+ case 'SSS':+ if (strict) { return parseTokenThreeDigits; }+ /* falls through */+ case 'DDD':+ return parseTokenOneToThreeDigits;+ case 'MMM':+ case 'MMMM':+ case 'dd':+ case 'ddd':+ case 'dddd':+ return parseTokenWord;+ case 'a':+ case 'A':+ return getLangDefinition(config._l)._meridiemParse;+ case 'X':+ return parseTokenTimestampMs;+ case 'Z':+ case 'ZZ':+ return parseTokenTimezone;+ case 'T':+ return parseTokenT;+ case 'SSSS':+ return parseTokenDigits;+ case 'MM':+ case 'DD':+ case 'YY':+ case 'GG':+ case 'gg':+ case 'HH':+ case 'hh':+ case 'mm':+ case 'ss':+ case 'ww':+ case 'WW':+ return strict ? parseTokenTwoDigits : parseTokenOneOrTwoDigits;+ case 'M':+ case 'D':+ case 'd':+ case 'H':+ case 'h':+ case 'm':+ case 's':+ case 'w':+ case 'W':+ case 'e':+ case 'E':+ return parseTokenOneOrTwoDigits;+ default :+ a = new RegExp(regexpEscape(unescapeFormat(token.replace('\\', '')), "i"));+ return a;+ }+ }++ function timezoneMinutesFromString(string) {+ string = string || "";+ var possibleTzMatches = (string.match(parseTokenTimezone) || []),+ tzChunk = possibleTzMatches[possibleTzMatches.length - 1] || [],+ parts = (tzChunk + '').match(parseTimezoneChunker) || ['-', 0, 0],+ minutes = +(parts[1] * 60) + toInt(parts[2]);++ return parts[0] === '+' ? -minutes : minutes;+ }++ // function to convert string input to date+ function addTimeToArrayFromToken(token, input, config) {+ var a, datePartArray = config._a;++ switch (token) {+ // MONTH+ case 'M' : // fall through to MM+ case 'MM' :+ if (input != null) {+ datePartArray[MONTH] = toInt(input) - 1;+ }+ break;+ case 'MMM' : // fall through to MMMM+ case 'MMMM' :+ a = getLangDefinition(config._l).monthsParse(input);+ // if we didn't find a month name, mark the date as invalid.+ if (a != null) {+ datePartArray[MONTH] = a;+ } else {+ config._pf.invalidMonth = input;+ }+ break;+ // DAY OF MONTH+ case 'D' : // fall through to DD+ case 'DD' :+ if (input != null) {+ datePartArray[DATE] = toInt(input);+ }+ break;+ // DAY OF YEAR+ case 'DDD' : // fall through to DDDD+ case 'DDDD' :+ if (input != null) {+ config._dayOfYear = toInt(input);+ }++ break;+ // YEAR+ case 'YY' :+ datePartArray[YEAR] = toInt(input) + (toInt(input) > 68 ? 1900 : 2000);+ break;+ case 'YYYY' :+ case 'YYYYY' :+ case 'YYYYYY' :+ datePartArray[YEAR] = toInt(input);+ break;+ // AM / PM+ case 'a' : // fall through to A+ case 'A' :+ config._isPm = getLangDefinition(config._l).isPM(input);+ break;+ // 24 HOUR+ case 'H' : // fall through to hh+ case 'HH' : // fall through to hh+ case 'h' : // fall through to hh+ case 'hh' :+ datePartArray[HOUR] = toInt(input);+ break;+ // MINUTE+ case 'm' : // fall through to mm+ case 'mm' :+ datePartArray[MINUTE] = toInt(input);+ break;+ // SECOND+ case 's' : // fall through to ss+ case 'ss' :+ datePartArray[SECOND] = toInt(input);+ break;+ // MILLISECOND+ case 'S' :+ case 'SS' :+ case 'SSS' :+ case 'SSSS' :+ datePartArray[MILLISECOND] = toInt(('0.' + input) * 1000);+ break;+ // UNIX TIMESTAMP WITH MS+ case 'X':+ config._d = new Date(parseFloat(input) * 1000);+ break;+ // TIMEZONE+ case 'Z' : // fall through to ZZ+ case 'ZZ' :+ config._useUTC = true;+ config._tzm = timezoneMinutesFromString(input);+ break;+ case 'w':+ case 'ww':+ case 'W':+ case 'WW':+ case 'd':+ case 'dd':+ case 'ddd':+ case 'dddd':+ case 'e':+ case 'E':+ token = token.substr(0, 1);+ /* falls through */+ case 'gg':+ case 'gggg':+ case 'GG':+ case 'GGGG':+ case 'GGGGG':+ token = token.substr(0, 2);+ if (input) {+ config._w = config._w || {};+ config._w[token] = input;+ }+ break;+ }+ }++ // convert an array to a date.+ // the array should mirror the parameters below+ // note: all values past the year are optional and will default to the lowest possible value.+ // [year, month, day , hour, minute, second, millisecond]+ function dateFromConfig(config) {+ var i, date, input = [], currentDate,+ yearToUse, fixYear, w, temp, lang, weekday, week;++ if (config._d) {+ return;+ }++ currentDate = currentDateArray(config);++ //compute day of the year from weeks and weekdays+ if (config._w && config._a[DATE] == null && config._a[MONTH] == null) {+ fixYear = function (val) {+ var int_val = parseInt(val, 10);+ return val ?+ (val.length < 3 ? (int_val > 68 ? 1900 + int_val : 2000 + int_val) : int_val) :+ (config._a[YEAR] == null ? moment().weekYear() : config._a[YEAR]);+ };++ w = config._w;+ if (w.GG != null || w.W != null || w.E != null) {+ temp = dayOfYearFromWeeks(fixYear(w.GG), w.W || 1, w.E, 4, 1);+ }+ else {+ lang = getLangDefinition(config._l);+ weekday = w.d != null ? parseWeekday(w.d, lang) :+ (w.e != null ? parseInt(w.e, 10) + lang._week.dow : 0);++ week = parseInt(w.w, 10) || 1;++ //if we're parsing 'd', then the low day numbers may be next week+ if (w.d != null && weekday < lang._week.dow) {+ week++;+ }++ temp = dayOfYearFromWeeks(fixYear(w.gg), week, weekday, lang._week.doy, lang._week.dow);+ }++ config._a[YEAR] = temp.year;+ config._dayOfYear = temp.dayOfYear;+ }++ //if the day of the year is set, figure out what it is+ if (config._dayOfYear) {+ yearToUse = config._a[YEAR] == null ? currentDate[YEAR] : config._a[YEAR];++ if (config._dayOfYear > daysInYear(yearToUse)) {+ config._pf._overflowDayOfYear = true;+ }++ date = makeUTCDate(yearToUse, 0, config._dayOfYear);+ config._a[MONTH] = date.getUTCMonth();+ config._a[DATE] = date.getUTCDate();+ }++ // Default to current date.+ // * if no year, month, day of month are given, default to today+ // * if day of month is given, default month and year+ // * if month is given, default only year+ // * if year is given, don't default anything+ for (i = 0; i < 3 && config._a[i] == null; ++i) {+ config._a[i] = input[i] = currentDate[i];+ }++ // Zero out whatever was not defaulted, including time+ for (; i < 7; i++) {+ config._a[i] = input[i] = (config._a[i] == null) ? (i === 2 ? 1 : 0) : config._a[i];+ }++ // add the offsets to the time to be parsed so that we can have a clean array for checking isValid+ input[HOUR] += toInt((config._tzm || 0) / 60);+ input[MINUTE] += toInt((config._tzm || 0) % 60);++ config._d = (config._useUTC ? makeUTCDate : makeDate).apply(null, input);+ }++ function dateFromObject(config) {+ var normalizedInput;++ if (config._d) {+ return;+ }++ normalizedInput = normalizeObjectUnits(config._i);+ config._a = [+ normalizedInput.year,+ normalizedInput.month,+ normalizedInput.day,+ normalizedInput.hour,+ normalizedInput.minute,+ normalizedInput.second,+ normalizedInput.millisecond+ ];++ dateFromConfig(config);+ }++ function currentDateArray(config) {+ var now = new Date();+ if (config._useUTC) {+ return [+ now.getUTCFullYear(),+ now.getUTCMonth(),+ now.getUTCDate()+ ];+ } else {+ return [now.getFullYear(), now.getMonth(), now.getDate()];+ }+ }++ // date from string and format string+ function makeDateFromStringAndFormat(config) {++ config._a = [];+ config._pf.empty = true;++ // This array is used to make a Date, either with `new Date` or `Date.UTC`+ var lang = getLangDefinition(config._l),+ string = '' + config._i,+ i, parsedInput, tokens, token, skipped,+ stringLength = string.length,+ totalParsedInputLength = 0;++ tokens = expandFormat(config._f, lang).match(formattingTokens) || [];++ for (i = 0; i < tokens.length; i++) {+ token = tokens[i];+ parsedInput = (string.match(getParseRegexForToken(token, config)) || [])[0];+ if (parsedInput) {+ skipped = string.substr(0, string.indexOf(parsedInput));+ if (skipped.length > 0) {+ config._pf.unusedInput.push(skipped);+ }+ string = string.slice(string.indexOf(parsedInput) + parsedInput.length);+ totalParsedInputLength += parsedInput.length;+ }+ // don't parse if it's not a known token+ if (formatTokenFunctions[token]) {+ if (parsedInput) {+ config._pf.empty = false;+ }+ else {+ config._pf.unusedTokens.push(token);+ }+ addTimeToArrayFromToken(token, parsedInput, config);+ }+ else if (config._strict && !parsedInput) {+ config._pf.unusedTokens.push(token);+ }+ }++ // add remaining unparsed input length to the string+ config._pf.charsLeftOver = stringLength - totalParsedInputLength;+ if (string.length > 0) {+ config._pf.unusedInput.push(string);+ }++ // handle am pm+ if (config._isPm && config._a[HOUR] < 12) {+ config._a[HOUR] += 12;+ }+ // if is 12 am, change hours to 0+ if (config._isPm === false && config._a[HOUR] === 12) {+ config._a[HOUR] = 0;+ }++ dateFromConfig(config);+ checkOverflow(config);+ }++ function unescapeFormat(s) {+ return s.replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g, function (matched, p1, p2, p3, p4) {+ return p1 || p2 || p3 || p4;+ });+ }++ // Code from http://stackoverflow.com/questions/3561493/is-there-a-regexp-escape-function-in-javascript+ function regexpEscape(s) {+ return s.replace(/[-\/\\^$*+?.()|[\]{}]/g, '\\$&');+ }++ // date from string and array of format strings+ function makeDateFromStringAndArray(config) {+ var tempConfig,+ bestMoment,++ scoreToBeat,+ i,+ currentScore;++ if (config._f.length === 0) {+ config._pf.invalidFormat = true;+ config._d = new Date(NaN);+ return;+ }++ for (i = 0; i < config._f.length; i++) {+ currentScore = 0;+ tempConfig = extend({}, config);+ tempConfig._pf = defaultParsingFlags();+ tempConfig._f = config._f[i];+ makeDateFromStringAndFormat(tempConfig);++ if (!isValid(tempConfig)) {+ continue;+ }++ // if there is any input that was not parsed add a penalty for that format+ currentScore += tempConfig._pf.charsLeftOver;++ //or tokens+ currentScore += tempConfig._pf.unusedTokens.length * 10;++ tempConfig._pf.score = currentScore;++ if (scoreToBeat == null || currentScore < scoreToBeat) {+ scoreToBeat = currentScore;+ bestMoment = tempConfig;+ }+ }++ extend(config, bestMoment || tempConfig);+ }++ // date from iso format+ function makeDateFromString(config) {+ var i, l,+ string = config._i,+ match = isoRegex.exec(string);++ if (match) {+ config._pf.iso = true;+ for (i = 0, l = isoDates.length; i < l; i++) {+ if (isoDates[i][1].exec(string)) {+ // match[5] should be "T" or undefined+ config._f = isoDates[i][0] + (match[6] || " ");+ break;+ }+ }+ for (i = 0, l = isoTimes.length; i < l; i++) {+ if (isoTimes[i][1].exec(string)) {+ config._f += isoTimes[i][0];+ break;+ }+ }+ if (string.match(parseTokenTimezone)) {+ config._f += "Z";+ }+ makeDateFromStringAndFormat(config);+ }+ else {+ config._d = new Date(string);+ }+ }++ function makeDateFromInput(config) {+ var input = config._i,+ matched = aspNetJsonRegex.exec(input);++ if (input === undefined) {+ config._d = new Date();+ } else if (matched) {+ config._d = new Date(+matched[1]);+ } else if (typeof input === 'string') {+ makeDateFromString(config);+ } else if (isArray(input)) {+ config._a = input.slice(0);+ dateFromConfig(config);+ } else if (isDate(input)) {+ config._d = new Date(+input);+ } else if (typeof(input) === 'object') {+ dateFromObject(config);+ } else {+ config._d = new Date(input);+ }+ }++ function makeDate(y, m, d, h, M, s, ms) {+ //can't just apply() to create a date:+ //http://stackoverflow.com/questions/181348/instantiating-a-javascript-object-by-calling-prototype-constructor-apply+ var date = new Date(y, m, d, h, M, s, ms);++ //the date constructor doesn't accept years < 1970+ if (y < 1970) {+ date.setFullYear(y);+ }+ return date;+ }++ function makeUTCDate(y) {+ var date = new Date(Date.UTC.apply(null, arguments));+ if (y < 1970) {+ date.setUTCFullYear(y);+ }+ return date;+ }++ function parseWeekday(input, language) {+ if (typeof input === 'string') {+ if (!isNaN(input)) {+ input = parseInt(input, 10);+ }+ else {+ input = language.weekdaysParse(input);+ if (typeof input !== 'number') {+ return null;+ }+ }+ }+ return input;+ }++ /************************************+ Relative Time+ ************************************/+++ // helper function for moment.fn.from, moment.fn.fromNow, and moment.duration.fn.humanize+ function substituteTimeAgo(string, number, withoutSuffix, isFuture, lang) {+ return lang.relativeTime(number || 1, !!withoutSuffix, string, isFuture);+ }++ function relativeTime(milliseconds, withoutSuffix, lang) {+ var seconds = round(Math.abs(milliseconds) / 1000),+ minutes = round(seconds / 60),+ hours = round(minutes / 60),+ days = round(hours / 24),+ years = round(days / 365),+ args = seconds < 45 && ['s', seconds] ||+ minutes === 1 && ['m'] ||+ minutes < 45 && ['mm', minutes] ||+ hours === 1 && ['h'] ||+ hours < 22 && ['hh', hours] ||+ days === 1 && ['d'] ||+ days <= 25 && ['dd', days] ||+ days <= 45 && ['M'] ||+ days < 345 && ['MM', round(days / 30)] ||+ years === 1 && ['y'] || ['yy', years];+ args[2] = withoutSuffix;+ args[3] = milliseconds > 0;+ args[4] = lang;+ return substituteTimeAgo.apply({}, args);+ }+++ /************************************+ Week of Year+ ************************************/+++ // firstDayOfWeek 0 = sun, 6 = sat+ // the day of the week that starts the week+ // (usually sunday or monday)+ // firstDayOfWeekOfYear 0 = sun, 6 = sat+ // the first week is the week that contains the first+ // of this day of the week+ // (eg. ISO weeks use thursday (4))+ function weekOfYear(mom, firstDayOfWeek, firstDayOfWeekOfYear) {+ var end = firstDayOfWeekOfYear - firstDayOfWeek,+ daysToDayOfWeek = firstDayOfWeekOfYear - mom.day(),+ adjustedMoment;+++ if (daysToDayOfWeek > end) {+ daysToDayOfWeek -= 7;+ }++ if (daysToDayOfWeek < end - 7) {+ daysToDayOfWeek += 7;+ }++ adjustedMoment = moment(mom).add('d', daysToDayOfWeek);+ return {+ week: Math.ceil(adjustedMoment.dayOfYear() / 7),+ year: adjustedMoment.year()+ };+ }++ //http://en.wikipedia.org/wiki/ISO_week_date#Calculating_a_date_given_the_year.2C_week_number_and_weekday+ function dayOfYearFromWeeks(year, week, weekday, firstDayOfWeekOfYear, firstDayOfWeek) {+ var d = makeUTCDate(year, 0, 1).getUTCDay(), daysToAdd, dayOfYear;++ weekday = weekday != null ? weekday : firstDayOfWeek;+ daysToAdd = firstDayOfWeek - d + (d > firstDayOfWeekOfYear ? 7 : 0) - (d < firstDayOfWeek ? 7 : 0);+ dayOfYear = 7 * (week - 1) + (weekday - firstDayOfWeek) + daysToAdd + 1;++ return {+ year: dayOfYear > 0 ? year : year - 1,+ dayOfYear: dayOfYear > 0 ? dayOfYear : daysInYear(year - 1) + dayOfYear+ };+ }++ /************************************+ Top Level Functions+ ************************************/++ function makeMoment(config) {+ var input = config._i,+ format = config._f;++ if (input === null) {+ return moment.invalid({nullInput: true});+ }++ if (typeof input === 'string') {+ config._i = input = getLangDefinition().preparse(input);+ }++ if (moment.isMoment(input)) {+ config = cloneMoment(input);++ config._d = new Date(+input._d);+ } else if (format) {+ if (isArray(format)) {+ makeDateFromStringAndArray(config);+ } else {+ makeDateFromStringAndFormat(config);+ }+ } else {+ makeDateFromInput(config);+ }++ return new Moment(config);+ }++ moment = function (input, format, lang, strict) {+ var c;++ if (typeof(lang) === "boolean") {+ strict = lang;+ lang = undefined;+ }+ // object construction must be done this way.+ // https://github.com/moment/moment/issues/1423+ c = {};+ c._isAMomentObject = true;+ c._i = input;+ c._f = format;+ c._l = lang;+ c._strict = strict;+ c._isUTC = false;+ c._pf = defaultParsingFlags();++ return makeMoment(c);+ };++ // creating with utc+ moment.utc = function (input, format, lang, strict) {+ var c;++ if (typeof(lang) === "boolean") {+ strict = lang;+ lang = undefined;+ }+ // object construction must be done this way.+ // https://github.com/moment/moment/issues/1423+ c = {};+ c._isAMomentObject = true;+ c._useUTC = true;+ c._isUTC = true;+ c._l = lang;+ c._i = input;+ c._f = format;+ c._strict = strict;+ c._pf = defaultParsingFlags();++ return makeMoment(c).utc();+ };++ // creating with unix timestamp (in seconds)+ moment.unix = function (input) {+ return moment(input * 1000);+ };++ // duration+ moment.duration = function (input, key) {+ var duration = input,+ // matching against regexp is expensive, do it on demand+ match = null,+ sign,+ ret,+ parseIso;++ if (moment.isDuration(input)) {+ duration = {+ ms: input._milliseconds,+ d: input._days,+ M: input._months+ };+ } else if (typeof input === 'number') {+ duration = {};+ if (key) {+ duration[key] = input;+ } else {+ duration.milliseconds = input;+ }+ } else if (!!(match = aspNetTimeSpanJsonRegex.exec(input))) {+ sign = (match[1] === "-") ? -1 : 1;+ duration = {+ y: 0,+ d: toInt(match[DATE]) * sign,+ h: toInt(match[HOUR]) * sign,+ m: toInt(match[MINUTE]) * sign,+ s: toInt(match[SECOND]) * sign,+ ms: toInt(match[MILLISECOND]) * sign+ };+ } else if (!!(match = isoDurationRegex.exec(input))) {+ sign = (match[1] === "-") ? -1 : 1;+ parseIso = function (inp) {+ // We'd normally use ~~inp for this, but unfortunately it also+ // converts floats to ints.+ // inp may be undefined, so careful calling replace on it.+ var res = inp && parseFloat(inp.replace(',', '.'));+ // apply sign while we're at it+ return (isNaN(res) ? 0 : res) * sign;+ };+ duration = {+ y: parseIso(match[2]),+ M: parseIso(match[3]),+ d: parseIso(match[4]),+ h: parseIso(match[5]),+ m: parseIso(match[6]),+ s: parseIso(match[7]),+ w: parseIso(match[8])+ };+ }++ ret = new Duration(duration);++ if (moment.isDuration(input) && input.hasOwnProperty('_lang')) {+ ret._lang = input._lang;+ }++ return ret;+ };++ // version number+ moment.version = VERSION;++ // default format+ moment.defaultFormat = isoFormat;++ // This function will be called whenever a moment is mutated.+ // It is intended to keep the offset in sync with the timezone.+ moment.updateOffset = function () {};++ // This function will load languages and then set the global language. If+ // no arguments are passed in, it will simply return the current global+ // language key.+ moment.lang = function (key, values) {+ var r;+ if (!key) {+ return moment.fn._lang._abbr;+ }+ if (values) {+ loadLang(normalizeLanguage(key), values);+ } else if (values === null) {+ unloadLang(key);+ key = 'en';+ } else if (!languages[key]) {+ getLangDefinition(key);+ }+ r = moment.duration.fn._lang = moment.fn._lang = getLangDefinition(key);+ return r._abbr;+ };++ // returns language data+ moment.langData = function (key) {+ if (key && key._lang && key._lang._abbr) {+ key = key._lang._abbr;+ }+ return getLangDefinition(key);+ };++ // compare moment object+ moment.isMoment = function (obj) {+ return obj instanceof Moment ||+ (obj != null && obj.hasOwnProperty('_isAMomentObject'));+ };++ // for typechecking Duration objects+ moment.isDuration = function (obj) {+ return obj instanceof Duration;+ };++ for (i = lists.length - 1; i >= 0; --i) {+ makeList(lists[i]);+ }++ moment.normalizeUnits = function (units) {+ return normalizeUnits(units);+ };++ moment.invalid = function (flags) {+ var m = moment.utc(NaN);+ if (flags != null) {+ extend(m._pf, flags);+ }+ else {+ m._pf.userInvalidated = true;+ }++ return m;+ };++ moment.parseZone = function (input) {+ return moment(input).parseZone();+ };++ /************************************+ Moment Prototype+ ************************************/+++ extend(moment.fn = Moment.prototype, {++ clone : function () {+ return moment(this);+ },++ valueOf : function () {+ return +this._d + ((this._offset || 0) * 60000);+ },++ unix : function () {+ return Math.floor(+this / 1000);+ },++ toString : function () {+ return this.clone().lang('en').format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ");+ },++ toDate : function () {+ return this._offset ? new Date(+this) : this._d;+ },++ toISOString : function () {+ var m = moment(this).utc();+ if (0 < m.year() && m.year() <= 9999) {+ return formatMoment(m, 'YYYY-MM-DD[T]HH:mm:ss.SSS[Z]');+ } else {+ return formatMoment(m, 'YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]');+ }+ },++ toArray : function () {+ var m = this;+ return [+ m.year(),+ m.month(),+ m.date(),+ m.hours(),+ m.minutes(),+ m.seconds(),+ m.milliseconds()+ ];+ },++ isValid : function () {+ return isValid(this);+ },++ isDSTShifted : function () {++ if (this._a) {+ return this.isValid() && compareArrays(this._a, (this._isUTC ? moment.utc(this._a) : moment(this._a)).toArray()) > 0;+ }++ return false;+ },++ parsingFlags : function () {+ return extend({}, this._pf);+ },++ invalidAt: function () {+ return this._pf.overflow;+ },++ utc : function () {+ return this.zone(0);+ },++ local : function () {+ this.zone(0);+ this._isUTC = false;+ return this;+ },++ format : function (inputString) {+ var output = formatMoment(this, inputString || moment.defaultFormat);+ return this.lang().postformat(output);+ },++ add : function (input, val) {+ var dur;+ // switch args to support add('s', 1) and add(1, 's')+ if (typeof input === 'string') {+ dur = moment.duration(+val, input);+ } else {+ dur = moment.duration(input, val);+ }+ addOrSubtractDurationFromMoment(this, dur, 1);+ return this;+ },++ subtract : function (input, val) {+ var dur;+ // switch args to support subtract('s', 1) and subtract(1, 's')+ if (typeof input === 'string') {+ dur = moment.duration(+val, input);+ } else {+ dur = moment.duration(input, val);+ }+ addOrSubtractDurationFromMoment(this, dur, -1);+ return this;+ },++ diff : function (input, units, asFloat) {+ var that = makeAs(input, this),+ zoneDiff = (this.zone() - that.zone()) * 6e4,+ diff, output;++ units = normalizeUnits(units);++ if (units === 'year' || units === 'month') {+ // average number of days in the months in the given dates+ diff = (this.daysInMonth() + that.daysInMonth()) * 432e5; // 24 * 60 * 60 * 1000 / 2+ // difference in months+ output = ((this.year() - that.year()) * 12) + (this.month() - that.month());+ // adjust by taking difference in days, average number of days+ // and dst in the given months.+ output += ((this - moment(this).startOf('month')) -+ (that - moment(that).startOf('month'))) / diff;+ // same as above but with zones, to negate all dst+ output -= ((this.zone() - moment(this).startOf('month').zone()) -+ (that.zone() - moment(that).startOf('month').zone())) * 6e4 / diff;+ if (units === 'year') {+ output = output / 12;+ }+ } else {+ diff = (this - that);+ output = units === 'second' ? diff / 1e3 : // 1000+ units === 'minute' ? diff / 6e4 : // 1000 * 60+ units === 'hour' ? diff / 36e5 : // 1000 * 60 * 60+ units === 'day' ? (diff - zoneDiff) / 864e5 : // 1000 * 60 * 60 * 24, negate dst+ units === 'week' ? (diff - zoneDiff) / 6048e5 : // 1000 * 60 * 60 * 24 * 7, negate dst+ diff;+ }+ return asFloat ? output : absRound(output);+ },++ from : function (time, withoutSuffix) {+ return moment.duration(this.diff(time)).lang(this.lang()._abbr).humanize(!withoutSuffix);+ },++ fromNow : function (withoutSuffix) {+ return this.from(moment(), withoutSuffix);+ },++ calendar : function () {+ // We want to compare the start of today, vs this.+ // Getting start-of-today depends on whether we're zone'd or not.+ var sod = makeAs(moment(), this).startOf('day'),+ diff = this.diff(sod, 'days', true),+ format = diff < -6 ? 'sameElse' :+ diff < -1 ? 'lastWeek' :+ diff < 0 ? 'lastDay' :+ diff < 1 ? 'sameDay' :+ diff < 2 ? 'nextDay' :+ diff < 7 ? 'nextWeek' : 'sameElse';+ return this.format(this.lang().calendar(format, this));+ },++ isLeapYear : function () {+ return isLeapYear(this.year());+ },++ isDST : function () {+ return (this.zone() < this.clone().month(0).zone() ||+ this.zone() < this.clone().month(5).zone());+ },++ day : function (input) {+ var day = this._isUTC ? this._d.getUTCDay() : this._d.getDay();+ if (input != null) {+ input = parseWeekday(input, this.lang());+ return this.add({ d : input - day });+ } else {+ return day;+ }+ },++ month : function (input) {+ var utc = this._isUTC ? 'UTC' : '',+ dayOfMonth;++ if (input != null) {+ if (typeof input === 'string') {+ input = this.lang().monthsParse(input);+ if (typeof input !== 'number') {+ return this;+ }+ }++ dayOfMonth = this.date();+ this.date(1);+ this._d['set' + utc + 'Month'](input);+ this.date(Math.min(dayOfMonth, this.daysInMonth()));++ moment.updateOffset(this);+ return this;+ } else {+ return this._d['get' + utc + 'Month']();+ }+ },++ startOf: function (units) {+ units = normalizeUnits(units);+ // the following switch intentionally omits break keywords+ // to utilize falling through the cases.+ switch (units) {+ case 'year':+ this.month(0);+ /* falls through */+ case 'month':+ this.date(1);+ /* falls through */+ case 'week':+ case 'isoWeek':+ case 'day':+ this.hours(0);+ /* falls through */+ case 'hour':+ this.minutes(0);+ /* falls through */+ case 'minute':+ this.seconds(0);+ /* falls through */+ case 'second':+ this.milliseconds(0);+ /* falls through */+ }++ // weeks are a special case+ if (units === 'week') {+ this.weekday(0);+ } else if (units === 'isoWeek') {+ this.isoWeekday(1);+ }++ return this;+ },++ endOf: function (units) {+ units = normalizeUnits(units);+ return this.startOf(units).add((units === 'isoWeek' ? 'week' : units), 1).subtract('ms', 1);+ },++ isAfter: function (input, units) {+ units = typeof units !== 'undefined' ? units : 'millisecond';+ return +this.clone().startOf(units) > +moment(input).startOf(units);+ },++ isBefore: function (input, units) {+ units = typeof units !== 'undefined' ? units : 'millisecond';+ return +this.clone().startOf(units) < +moment(input).startOf(units);+ },++ isSame: function (input, units) {+ units = units || 'ms';+ return +this.clone().startOf(units) === +makeAs(input, this).startOf(units);+ },++ min: function (other) {+ other = moment.apply(null, arguments);+ return other < this ? this : other;+ },++ max: function (other) {+ other = moment.apply(null, arguments);+ return other > this ? this : other;+ },++ zone : function (input) {+ var offset = this._offset || 0;+ if (input != null) {+ if (typeof input === "string") {+ input = timezoneMinutesFromString(input);+ }+ if (Math.abs(input) < 16) {+ input = input * 60;+ }+ this._offset = input;+ this._isUTC = true;+ if (offset !== input) {+ addOrSubtractDurationFromMoment(this, moment.duration(offset - input, 'm'), 1, true);+ }+ } else {+ return this._isUTC ? offset : this._d.getTimezoneOffset();+ }+ return this;+ },++ zoneAbbr : function () {+ return this._isUTC ? "UTC" : "";+ },++ zoneName : function () {+ return this._isUTC ? "Coordinated Universal Time" : "";+ },++ parseZone : function () {+ if (this._tzm) {+ this.zone(this._tzm);+ } else if (typeof this._i === 'string') {+ this.zone(this._i);+ }+ return this;+ },++ hasAlignedHourOffset : function (input) {+ if (!input) {+ input = 0;+ }+ else {+ input = moment(input).zone();+ }++ return (this.zone() - input) % 60 === 0;+ },++ daysInMonth : function () {+ return daysInMonth(this.year(), this.month());+ },++ dayOfYear : function (input) {+ var dayOfYear = round((moment(this).startOf('day') - moment(this).startOf('year')) / 864e5) + 1;+ return input == null ? dayOfYear : this.add("d", (input - dayOfYear));+ },++ quarter : function () {+ return Math.ceil((this.month() + 1.0) / 3.0);+ },++ weekYear : function (input) {+ var year = weekOfYear(this, this.lang()._week.dow, this.lang()._week.doy).year;+ return input == null ? year : this.add("y", (input - year));+ },++ isoWeekYear : function (input) {+ var year = weekOfYear(this, 1, 4).year;+ return input == null ? year : this.add("y", (input - year));+ },++ week : function (input) {+ var week = this.lang().week(this);+ return input == null ? week : this.add("d", (input - week) * 7);+ },++ isoWeek : function (input) {+ var week = weekOfYear(this, 1, 4).week;+ return input == null ? week : this.add("d", (input - week) * 7);+ },++ weekday : function (input) {+ var weekday = (this.day() + 7 - this.lang()._week.dow) % 7;+ return input == null ? weekday : this.add("d", input - weekday);+ },++ isoWeekday : function (input) {+ // behaves the same as moment#day except+ // as a getter, returns 7 instead of 0 (1-7 range instead of 0-6)+ // as a setter, sunday should belong to the previous week.+ return input == null ? this.day() || 7 : this.day(this.day() % 7 ? input : input - 7);+ },++ get : function (units) {+ units = normalizeUnits(units);+ return this[units]();+ },++ set : function (units, value) {+ units = normalizeUnits(units);+ if (typeof this[units] === 'function') {+ this[units](value);+ }+ return this;+ },++ // If passed a language key, it will set the language for this+ // instance. Otherwise, it will return the language configuration+ // variables for this instance.+ lang : function (key) {+ if (key === undefined) {+ return this._lang;+ } else {+ this._lang = getLangDefinition(key);+ return this;+ }+ }+ });++ // helper for adding shortcuts+ function makeGetterAndSetter(name, key) {+ moment.fn[name] = moment.fn[name + 's'] = function (input) {+ var utc = this._isUTC ? 'UTC' : '';+ if (input != null) {+ this._d['set' + utc + key](input);+ moment.updateOffset(this);+ return this;+ } else {+ return this._d['get' + utc + key]();+ }+ };+ }++ // loop through and add shortcuts (Month, Date, Hours, Minutes, Seconds, Milliseconds)+ for (i = 0; i < proxyGettersAndSetters.length; i ++) {+ makeGetterAndSetter(proxyGettersAndSetters[i].toLowerCase().replace(/s$/, ''), proxyGettersAndSetters[i]);+ }++ // add shortcut for year (uses different syntax than the getter/setter 'year' == 'FullYear')+ makeGetterAndSetter('year', 'FullYear');++ // add plural methods+ moment.fn.days = moment.fn.day;+ moment.fn.months = moment.fn.month;+ moment.fn.weeks = moment.fn.week;+ moment.fn.isoWeeks = moment.fn.isoWeek;++ // add aliased format methods+ moment.fn.toJSON = moment.fn.toISOString;++ /************************************+ Duration Prototype+ ************************************/+++ extend(moment.duration.fn = Duration.prototype, {++ _bubble : function () {+ var milliseconds = this._milliseconds,+ days = this._days,+ months = this._months,+ data = this._data,+ seconds, minutes, hours, years;++ // The following code bubbles up values, see the tests for+ // examples of what that means.+ data.milliseconds = milliseconds % 1000;++ seconds = absRound(milliseconds / 1000);+ data.seconds = seconds % 60;++ minutes = absRound(seconds / 60);+ data.minutes = minutes % 60;++ hours = absRound(minutes / 60);+ data.hours = hours % 24;++ days += absRound(hours / 24);+ data.days = days % 30;++ months += absRound(days / 30);+ data.months = months % 12;++ years = absRound(months / 12);+ data.years = years;+ },++ weeks : function () {+ return absRound(this.days() / 7);+ },++ valueOf : function () {+ return this._milliseconds ++ this._days * 864e5 ++ (this._months % 12) * 2592e6 ++ toInt(this._months / 12) * 31536e6;+ },++ humanize : function (withSuffix) {+ var difference = +this,+ output = relativeTime(difference, !withSuffix, this.lang());++ if (withSuffix) {+ output = this.lang().pastFuture(difference, output);+ }++ return this.lang().postformat(output);+ },++ add : function (input, val) {+ // supports only 2.0-style add(1, 's') or add(moment)+ var dur = moment.duration(input, val);++ this._milliseconds += dur._milliseconds;+ this._days += dur._days;+ this._months += dur._months;++ this._bubble();++ return this;+ },++ subtract : function (input, val) {+ var dur = moment.duration(input, val);++ this._milliseconds -= dur._milliseconds;+ this._days -= dur._days;+ this._months -= dur._months;++ this._bubble();++ return this;+ },++ get : function (units) {+ units = normalizeUnits(units);+ return this[units.toLowerCase() + 's']();+ },++ as : function (units) {+ units = normalizeUnits(units);+ return this['as' + units.charAt(0).toUpperCase() + units.slice(1) + 's']();+ },++ lang : moment.fn.lang,++ toIsoString : function () {+ // inspired by https://github.com/dordille/moment-isoduration/blob/master/moment.isoduration.js+ var years = Math.abs(this.years()),+ months = Math.abs(this.months()),+ days = Math.abs(this.days()),+ hours = Math.abs(this.hours()),+ minutes = Math.abs(this.minutes()),+ seconds = Math.abs(this.seconds() + this.milliseconds() / 1000);++ if (!this.asSeconds()) {+ // this is the same as C#'s (Noda) and python (isodate)...+ // but not other JS (goog.date)+ return 'P0D';+ }++ return (this.asSeconds() < 0 ? '-' : '') ++ 'P' ++ (years ? years + 'Y' : '') ++ (months ? months + 'M' : '') ++ (days ? days + 'D' : '') ++ ((hours || minutes || seconds) ? 'T' : '') ++ (hours ? hours + 'H' : '') ++ (minutes ? minutes + 'M' : '') ++ (seconds ? seconds + 'S' : '');+ }+ });++ function makeDurationGetter(name) {+ moment.duration.fn[name] = function () {+ return this._data[name];+ };+ }++ function makeDurationAsGetter(name, factor) {+ moment.duration.fn['as' + name] = function () {+ return +this / factor;+ };+ }++ for (i in unitMillisecondFactors) {+ if (unitMillisecondFactors.hasOwnProperty(i)) {+ makeDurationAsGetter(i, unitMillisecondFactors[i]);+ makeDurationGetter(i.toLowerCase());+ }+ }++ makeDurationAsGetter('Weeks', 6048e5);+ moment.duration.fn.asMonths = function () {+ return (+this - this.years() * 31536e6) / 2592e6 + this.years() * 12;+ };+++ /************************************+ Default Lang+ ************************************/+++ // Set default language, other languages will inherit from English.+ moment.lang('en', {+ ordinal : function (number) {+ var b = number % 10,+ output = (toInt(number % 100 / 10) === 1) ? 'th' :+ (b === 1) ? 'st' :+ (b === 2) ? 'nd' :+ (b === 3) ? 'rd' : 'th';+ return number + output;+ }+ });++ /* EMBED_LANGUAGES */++ /************************************+ Exposing Moment+ ************************************/++ function makeGlobal(deprecate) {+ var warned = false, local_moment = moment;+ /*global ender:false */+ if (typeof ender !== 'undefined') {+ return;+ }+ // here, `this` means `window` in the browser, or `global` on the server+ // add `moment` as a global object via a string identifier,+ // for Closure Compiler "advanced" mode+ if (deprecate) {+ global.moment = function () {+ if (!warned && console && console.warn) {+ warned = true;+ console.warn(+ "Accessing Moment through the global scope is " ++ "deprecated, and will be removed in an upcoming " ++ "release.");+ }+ return local_moment.apply(null, arguments);+ };+ extend(global.moment, local_moment);+ } else {+ global['moment'] = moment;+ }+ }++ // CommonJS module is defined+ if (hasModule) {+ module.exports = moment;+ makeGlobal(true);+ } else if (typeof define === "function" && define.amd) {+ define("moment", function (require, exports, module) {+ if (module.config && module.config() && module.config().noGlobal !== true) {+ // If user provided noGlobal, he is aware of global+ makeGlobal(module.config().noGlobal === undefined);+ }++ return moment;+ });+ } else {+ makeGlobal();+ }+}).call(this);diff --git a/app/assets/javascripts/blazer/selectize.js b/app/assets/javascripts/blazer/selectize.jsnew file mode 100644index 00000000..882a5891--- /dev/null+++ b/app/assets/javascripts/blazer/selectize.js@@ -0,0 +1,3477 @@+/**+ * sifter.js+ * Copyright (c) 2013 Brian Reavis & contributors+ *+ * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this+ * file except in compliance with the License. You may obtain a copy of the License at:+ * http://www.apache.org/licenses/LICENSE-2.0+ *+ * Unless required by applicable law or agreed to in writing, software distributed under+ * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF+ * ANY KIND, either express or implied. See the License for the specific language+ * governing permissions and limitations under the License.+ *+ * @author Brian Reavis <[email protected]>+ */++(function(root, factory) {+ if (typeof define === 'function' && define.amd) {+ define('sifter', factory);+ } else if (typeof exports === 'object') {+ module.exports = factory();+ } else {+ root.Sifter = factory();+ }+}(this, function() {++ /**+ * Textually searches arrays and hashes of objects+ * by property (or multiple properties). Designed+ * specifically for autocomplete.+ *+ * @constructor+ * @param {array|object} items+ * @param {object} items+ */+ var Sifter = function(items, settings) {+ this.items = items;+ this.settings = settings || {diacritics: true};+ };++ /**+ * Splits a search string into an array of individual+ * regexps to be used to match results.+ *+ * @param {string} query+ * @returns {array}+ */+ Sifter.prototype.tokenize = function(query) {+ query = trim(String(query || '').toLowerCase());+ if (!query || !query.length) return [];++ var i, n, regex, letter;+ var tokens = [];+ var words = query.split(/ +/);++ for (i = 0, n = words.length; i < n; i++) {+ regex = escape_regex(words[i]);+ if (this.settings.diacritics) {+ for (letter in DIACRITICS) {+ if (DIACRITICS.hasOwnProperty(letter)) {+ regex = regex.replace(new RegExp(letter, 'g'), DIACRITICS[letter]);+ }+ }+ }+ tokens.push({+ string : words[i],+ regex : new RegExp(regex, 'i')+ });+ }++ return tokens;+ };++ /**+ * Iterates over arrays and hashes.+ *+ * ```+ * this.iterator(this.items, function(item, id) {+ * // invoked for each item+ * });+ * ```+ *+ * @param {array|object} object+ */+ Sifter.prototype.iterator = function(object, callback) {+ var iterator;+ if (is_array(object)) {+ iterator = Array.prototype.forEach || function(callback) {+ for (var i = 0, n = this.length; i < n; i++) {+ callback(this[i], i, this);+ }+ };+ } else {+ iterator = function(callback) {+ for (var key in this) {+ if (this.hasOwnProperty(key)) {+ callback(this[key], key, this);+ }+ }+ };+ }++ iterator.apply(object, [callback]);+ };++ /**+ * Returns a function to be used to score individual results.+ *+ * Good matches will have a higher score than poor matches.+ * If an item is not a match, 0 will be returned by the function.+ *+ * @param {object|string} search+ * @param {object} options (optional)+ * @returns {function}+ */+ Sifter.prototype.getScoreFunction = function(search, options) {+ var self, fields, tokens, token_count;++ self = this;+ search = self.prepareSearch(search, options);+ tokens = search.tokens;+ fields = search.options.fields;+ token_count = tokens.length;++ /**+ * Calculates how close of a match the+ * given value is against a search token.+ *+ * @param {mixed} value+ * @param {object} token+ * @return {number}+ */+ var scoreValue = function(value, token) {+ var score, pos;++ if (!value) return 0;+ value = String(value || '');+ pos = value.search(token.regex);+ if (pos === -1) return 0;+ score = token.string.length / value.length;+ if (pos === 0) score += 0.5;+ return score;+ };++ /**+ * Calculates the score of an object+ * against the search query.+ *+ * @param {object} token+ * @param {object} data+ * @return {number}+ */+ var scoreObject = (function() {+ var field_count = fields.length;+ if (!field_count) {+ return function() { return 0; };+ }+ if (field_count === 1) {+ return function(token, data) {+ return scoreValue(data[fields[0]], token);+ };+ }+ return function(token, data) {+ for (var i = 0, sum = 0; i < field_count; i++) {+ sum += scoreValue(data[fields[i]], token);+ }+ return sum / field_count;+ };+ })();++ if (!token_count) {+ return function() { return 0; };+ }+ if (token_count === 1) {+ return function(data) {+ return scoreObject(tokens[0], data);+ };+ }++ if (search.options.conjunction === 'and') {+ return function(data) {+ var score;+ for (var i = 0, sum = 0; i < token_count; i++) {+ score = scoreObject(tokens[i], data);+ if (score <= 0) return 0;+ sum += score;+ }+ return sum / token_count;+ };+ } else {+ return function(data) {+ for (var i = 0, sum = 0; i < token_count; i++) {+ sum += scoreObject(tokens[i], data);+ }+ return sum / token_count;+ };+ }+ };++ /**+ * Returns a function that can be used to compare two+ * results, for sorting purposes. If no sorting should+ * be performed, `null` will be returned.+ *+ * @param {string|object} search+ * @param {object} options+ * @return function(a,b)+ */+ Sifter.prototype.getSortFunction = function(search, options) {+ var i, n, self, field, fields, fields_count, multiplier, multipliers, get_field, implicit_score, sort;++ self = this;+ search = self.prepareSearch(search, options);+ sort = (!search.query && options.sort_empty) || options.sort;++ /**+ * Fetches the specified sort field value+ * from a search result item.+ *+ * @param {string} name+ * @param {object} result+ * @return {mixed}+ */+ get_field = function(name, result) {+ if (name === '$score') return result.score;+ return self.items[result.id][name];+ };++ // parse options+ fields = [];+ if (sort) {+ for (i = 0, n = sort.length; i < n; i++) {+ if (search.query || sort[i].field !== '$score') {+ fields.push(sort[i]);+ }+ }+ }++ // the "$score" field is implied to be the primary+ // sort field, unless it's manually specified+ if (search.query) {+ implicit_score = true;+ for (i = 0, n = fields.length; i < n; i++) {+ if (fields[i].field === '$score') {+ implicit_score = false;+ break;+ }+ }+ if (implicit_score) {+ fields.unshift({field: '$score', direction: 'desc'});+ }+ } else {+ for (i = 0, n = fields.length; i < n; i++) {+ if (fields[i].field === '$score') {+ fields.splice(i, 1);+ break;+ }+ }+ }++ multipliers = [];+ for (i = 0, n = fields.length; i < n; i++) {+ multipliers.push(fields[i].direction === 'desc' ? -1 : 1);+ }++ // build function+ fields_count = fields.length;+ if (!fields_count) {+ return null;+ } else if (fields_count === 1) {+ field = fields[0].field;+ multiplier = multipliers[0];+ return function(a, b) {+ return multiplier * cmp(+ get_field(field, a),+ get_field(field, b)+ );+ };+ } else {+ return function(a, b) {+ var i, result, a_value, b_value, field;+ for (i = 0; i < fields_count; i++) {+ field = fields[i].field;+ result = multipliers[i] * cmp(+ get_field(field, a),+ get_field(field, b)+ );+ if (result) return result;+ }+ return 0;+ };+ }+ };++ /**+ * Parses a search query and returns an object+ * with tokens and fields ready to be populated+ * with results.+ *+ * @param {string} query+ * @param {object} options+ * @returns {object}+ */+ Sifter.prototype.prepareSearch = function(query, options) {+ if (typeof query === 'object') return query;++ options = extend({}, options);++ var option_fields = options.fields;+ var option_sort = options.sort;+ var option_sort_empty = options.sort_empty;++ if (option_fields && !is_array(option_fields)) options.fields = [option_fields];+ if (option_sort && !is_array(option_sort)) options.sort = [option_sort];+ if (option_sort_empty && !is_array(option_sort_empty)) options.sort_empty = [option_sort_empty];++ return {+ options : options,+ query : String(query || '').toLowerCase(),+ tokens : this.tokenize(query),+ total : 0,+ items : []+ };+ };++ /**+ * Searches through all items and returns a sorted array of matches.+ *+ * The `options` parameter can contain:+ *+ * - fields {string|array}+ * - sort {array}+ * - score {function}+ * - filter {bool}+ * - limit {integer}+ *+ * Returns an object containing:+ *+ * - options {object}+ * - query {string}+ * - tokens {array}+ * - total {int}+ * - items {array}+ *+ * @param {string} query+ * @param {object} options+ * @returns {object}+ */+ Sifter.prototype.search = function(query, options) {+ var self = this, value, score, search, calculateScore;+ var fn_sort;+ var fn_score;++ search = this.prepareSearch(query, options);+ options = search.options;+ query = search.query;++ // generate result scoring function+ fn_score = options.score || self.getScoreFunction(search);++ // perform search and sort+ if (query.length) {+ self.iterator(self.items, function(item, id) {+ score = fn_score(item);+ if (options.filter === false || score > 0) {+ search.items.push({'score': score, 'id': id});+ }+ });+ } else {+ self.iterator(self.items, function(item, id) {+ search.items.push({'score': 1, 'id': id});+ });+ }++ fn_sort = self.getSortFunction(search, options);+ if (fn_sort) search.items.sort(fn_sort);++ // apply limits+ search.total = search.items.length;+ if (typeof options.limit === 'number') {+ search.items = search.items.slice(0, options.limit);+ }++ return search;+ };++ // utilities+ // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -++ var cmp = function(a, b) {+ if (typeof a === 'number' && typeof b === 'number') {+ return a > b ? 1 : (a < b ? -1 : 0);+ }+ a = String(a || '').toLowerCase();+ b = String(b || '').toLowerCase();+ if (a > b) return 1;+ if (b > a) return -1;+ return 0;+ };++ var extend = function(a, b) {+ var i, n, k, object;+ for (i = 1, n = arguments.length; i < n; i++) {+ object = arguments[i];+ if (!object) continue;+ for (k in object) {+ if (object.hasOwnProperty(k)) {+ a[k] = object[k];+ }+ }+ }+ return a;+ };++ var trim = function(str) {+ return (str + '').replace(/^\s+|\s+$|/g, '');+ };++ var escape_regex = function(str) {+ return (str + '').replace(/([.?*+^$[\]\\(){}|-])/g, '\\$1');+ };++ var is_array = Array.isArray || ($ && $.isArray) || function(object) {+ return Object.prototype.toString.call(object) === '[object Array]';+ };++ var DIACRITICS = {+ 'a': '[aÀÁÂÃÄÅàáâãäå]',+ 'c': '[cÇçćĆčČ]',+ 'd': '[dđĐďĎ]',+ 'e': '[eÈÉÊËèéêëěĚ]',+ 'i': '[iÌÍÎÏìíîï]',+ 'n': '[nÑñňŇ]',+ 'o': '[oÒÓÔÕÕÖØòóôõöø]',+ 'r': '[rřŘ]',+ 's': '[sŠš]',+ 't': '[tťŤ]',+ 'u': '[uÙÚÛÜùúûüůŮ]',+ 'y': '[yŸÿýÝ]',+ 'z': '[zŽž]'+ };++ // export+ // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -++ return Sifter;+}));++++/**+ * microplugin.js+ * Copyright (c) 2013 Brian Reavis & contributors+ *+ * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this+ * file except in compliance with the License. You may obtain a copy of the License at:+ * http://www.apache.org/licenses/LICENSE-2.0+ *+ * Unless required by applicable law or agreed to in writing, software distributed under+ * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF+ * ANY KIND, either express or implied. See the License for the specific language+ * governing permissions and limitations under the License.+ *+ * @author Brian Reavis <[email protected]>+ */++(function(root, factory) {+ if (typeof define === 'function' && define.amd) {+ define('microplugin', factory);+ } else if (typeof exports === 'object') {+ module.exports = factory();+ } else {+ root.MicroPlugin = factory();+ }+}(this, function() {+ var MicroPlugin = {};++ MicroPlugin.mixin = function(Interface) {+ Interface.plugins = {};++ /**+ * Initializes the listed plugins (with options).+ * Acceptable formats:+ *+ * List (without options):+ * ['a', 'b', 'c']+ *+ * List (with options):+ * [{'name': 'a', options: {}}, {'name': 'b', options: {}}]+ *+ * Hash (with options):+ * {'a': { ... }, 'b': { ... }, 'c': { ... }}+ *+ * @param {mixed} plugins+ */+ Interface.prototype.initializePlugins = function(plugins) {+ var i, n, key;+ var self = this;+ var queue = [];++ self.plugins = {+ names : [],+ settings : {},+ requested : {},+ loaded : {}+ };++ if (utils.isArray(plugins)) {+ for (i = 0, n = plugins.length; i < n; i++) {+ if (typeof plugins[i] === 'string') {+ queue.push(plugins[i]);+ } else {+ self.plugins.settings[plugins[i].name] = plugins[i].options;+ queue.push(plugins[i].name);+ }+ }+ } else if (plugins) {+ for (key in plugins) {+ if (plugins.hasOwnProperty(key)) {+ self.plugins.settings[key] = plugins[key];+ queue.push(key);+ }+ }+ }++ while (queue.length) {+ self.require(queue.shift());+ }+ };++ Interface.prototype.loadPlugin = function(name) {+ var self = this;+ var plugins = self.plugins;+ var plugin = Interface.plugins[name];++ if (!Interface.plugins.hasOwnProperty(name)) {+ throw new Error('Unable to find "' + name + '" plugin');+ }++ plugins.requested[name] = true;+ plugins.loaded[name] = plugin.fn.apply(self, [self.plugins.settings[name] || {}]);+ plugins.names.push(name);+ };++ /**+ * Initializes a plugin.+ *+ * @param {string} name+ */+ Interface.prototype.require = function(name) {+ var self = this;+ var plugins = self.plugins;++ if (!self.plugins.loaded.hasOwnProperty(name)) {+ if (plugins.requested[name]) {+ throw new Error('Plugin has circular dependency ("' + name + '")');+ }+ self.loadPlugin(name);+ }++ return plugins.loaded[name];+ };++ /**+ * Registers a plugin.+ *+ * @param {string} name+ * @param {function} fn+ */+ Interface.define = function(name, fn) {+ Interface.plugins[name] = {+ 'name' : name,+ 'fn' : fn+ };+ };+ };++ var utils = {+ isArray: Array.isArray || function(vArg) {+ return Object.prototype.toString.call(vArg) === '[object Array]';+ }+ };++ return MicroPlugin;+}));++/**+ * selectize.js (v0.10.1)+ * Copyright (c) 2013 Brian Reavis & contributors+ *+ * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this+ * file except in compliance with the License. You may obtain a copy of the License at:+ * http://www.apache.org/licenses/LICENSE-2.0+ *+ * Unless required by applicable law or agreed to in writing, software distributed under+ * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF+ * ANY KIND, either express or implied. See the License for the specific language+ * governing permissions and limitations under the License.+ *+ * @author Brian Reavis <[email protected]>+ */++/*jshint curly:false */+/*jshint browser:true */++(function(root, factory) {+ if (typeof define === 'function' && define.amd) {+ define('selectize', ['jquery','sifter','microplugin'], factory);+ } else if (typeof exports === 'object') {+ module.exports = factory(require('jquery'), require('sifter'), require('microplugin'));+ } else {+ root.Selectize = factory(root.jQuery, root.Sifter, root.MicroPlugin);+ }+}(this, function($, Sifter, MicroPlugin) {+ 'use strict';++ var highlight = function($element, pattern) {+ if (typeof pattern === 'string' && !pattern.length) return;+ var regex = (typeof pattern === 'string') ? new RegExp(pattern, 'i') : pattern;++ var highlight = function(node) {+ var skip = 0;+ if (node.nodeType === 3) {+ var pos = node.data.search(regex);+ if (pos >= 0 && node.data.length > 0) {+ var match = node.data.match(regex);+ var spannode = document.createElement('span');+ spannode.className = 'highlight';+ var middlebit = node.splitText(pos);+ var endbit = middlebit.splitText(match[0].length);+ var middleclone = middlebit.cloneNode(true);+ spannode.appendChild(middleclone);+ middlebit.parentNode.replaceChild(spannode, middlebit);+ skip = 1;+ }+ } else if (node.nodeType === 1 && node.childNodes && !/(script|style)/i.test(node.tagName)) {+ for (var i = 0; i < node.childNodes.length; ++i) {+ i += highlight(node.childNodes[i]);+ }+ }+ return skip;+ };++ return $element.each(function() {+ highlight(this);+ });+ };++ var MicroEvent = function() {};+ MicroEvent.prototype = {+ on: function(event, fct){+ this._events = this._events || {};+ this._events[event] = this._events[event] || [];+ this._events[event].push(fct);+ },+ off: function(event, fct){+ var n = arguments.length;+ if (n === 0) return delete this._events;+ if (n === 1) return delete this._events[event];++ this._events = this._events || {};+ if (event in this._events === false) return;+ this._events[event].splice(this._events[event].indexOf(fct), 1);+ },+ trigger: function(event /* , args... */){+ this._events = this._events || {};+ if (event in this._events === false) return;+ for (var i = 0; i < this._events[event].length; i++){+ this._events[event][i].apply(this, Array.prototype.slice.call(arguments, 1));+ }+ }+ };++ /**+ * Mixin will delegate all MicroEvent.js function in the destination object.+ *+ * - MicroEvent.mixin(Foobar) will make Foobar able to use MicroEvent+ *+ * @param {object} the object which will support MicroEvent+ */+ MicroEvent.mixin = function(destObject){+ var props = ['on', 'off', 'trigger'];+ for (var i = 0; i < props.length; i++){+ destObject.prototype[props[i]] = MicroEvent.prototype[props[i]];+ }+ };++ var IS_MAC = /Mac/.test(navigator.userAgent);++ var KEY_A = 65;+ var KEY_COMMA = 188;+ var KEY_RETURN = 13;+ var KEY_ESC = 27;+ var KEY_LEFT = 37;+ var KEY_UP = 38;+ var KEY_P = 80;+ var KEY_RIGHT = 39;+ var KEY_DOWN = 40;+ var KEY_N = 78;+ var KEY_BACKSPACE = 8;+ var KEY_DELETE = 46;+ var KEY_SHIFT = 16;+ var KEY_CMD = IS_MAC ? 91 : 17;+ var KEY_CTRL = IS_MAC ? 18 : 17;+ var KEY_TAB = 9;++ var TAG_SELECT = 1;+ var TAG_INPUT = 2;+++ var isset = function(object) {+ return typeof object !== 'undefined';+ };++ /**+ * Converts a scalar to its best string representation+ * for hash keys and HTML attribute values.+ *+ * Transformations:+ * 'str' -> 'str'+ * null -> ''+ * undefined -> ''+ * true -> '1'+ * false -> '0'+ * 0 -> '0'+ * 1 -> '1'+ *+ * @param {string} value+ * @returns {string}+ */+ var hash_key = function(value) {+ if (typeof value === 'undefined' || value === null) return '';+ if (typeof value === 'boolean') return value ? '1' : '0';+ return value + '';+ };++ /**+ * Escapes a string for use within HTML.+ *+ * @param {string} str+ * @returns {string}+ */+ var escape_html = function(str) {+ return (str + '')+ .replace(/&/g, '&')+ .replace(/</g, '<')+ .replace(/>/g, '>')+ .replace(/"/g, '"');+ };++ /**+ * Escapes "$" characters in replacement strings.+ *+ * @param {string} str+ * @returns {string}+ */+ var escape_replace = function(str) {+ return (str + '').replace(/\$/g, '$$$$');+ };++ var hook = {};++ /**+ * Wraps `method` on `self` so that `fn`+ * is invoked before the original method.+ *+ * @param {object} self+ * @param {string} method+ * @param {function} fn+ */+ hook.before = function(self, method, fn) {+ var original = self[method];+ self[method] = function() {+ fn.apply(self, arguments);+ return original.apply(self, arguments);+ };+ };++ /**+ * Wraps `method` on `self` so that `fn`+ * is invoked after the original method.+ *+ * @param {object} self+ * @param {string} method+ * @param {function} fn+ */+ hook.after = function(self, method, fn) {+ var original = self[method];+ self[method] = function() {+ var result = original.apply(self, arguments);+ fn.apply(self, arguments);+ return result;+ };+ };++ /**+ * Builds a hash table out of an array of+ * objects, using the specified `key` within+ * each object.+ *+ * @param {string} key+ * @param {mixed} objects+ */+ var build_hash_table = function(key, objects) {+ if (!$.isArray(objects)) return objects;+ var i, n, table = {};+ for (i = 0, n = objects.length; i < n; i++) {+ if (objects[i].hasOwnProperty(key)) {+ table[objects[i][key]] = objects[i];+ }+ }+ return table;+ };++ /**+ * Wraps `fn` so that it can only be invoked once.+ *+ * @param {function} fn+ * @returns {function}+ */+ var once = function(fn) {+ var called = false;+ return function() {+ if (called) return;+ called = true;+ fn.apply(this, arguments);+ };+ };++ /**+ * Wraps `fn` so that it can only be called once+ * every `delay` milliseconds (invoked on the falling edge).+ *+ * @param {function} fn+ * @param {int} delay+ * @returns {function}+ */+ var debounce = function(fn, delay) {+ var timeout;+ return function() {+ var self = this;+ var args = arguments;+ window.clearTimeout(timeout);+ timeout = window.setTimeout(function() {+ fn.apply(self, args);+ }, delay);+ };+ };++ /**+ * Debounce all fired events types listed in `types`+ * while executing the provided `fn`.+ *+ * @param {object} self+ * @param {array} types+ * @param {function} fn+ */+ var debounce_events = function(self, types, fn) {+ var type;+ var trigger = self.trigger;+ var event_args = {};++ // override trigger method+ self.trigger = function() {+ var type = arguments[0];+ if (types.indexOf(type) !== -1) {+ event_args[type] = arguments;+ } else {+ return trigger.apply(self, arguments);+ }+ };++ // invoke provided function+ fn.apply(self, []);+ self.trigger = trigger;++ // trigger queued events+ for (type in event_args) {+ if (event_args.hasOwnProperty(type)) {+ trigger.apply(self, event_args[type]);+ }+ }+ };++ /**+ * A workaround for http://bugs.jquery.com/ticket/6696+ *+ * @param {object} $parent - Parent element to listen on.+ * @param {string} event - Event name.+ * @param {string} selector - Descendant selector to filter by.+ * @param {function} fn - Event handler.+ */+ var watchChildEvent = function($parent, event, selector, fn) {+ $parent.on(event, selector, function(e) {+ var child = e.target;+ while (child && child.parentNode !== $parent[0]) {+ child = child.parentNode;+ }+ e.currentTarget = child;+ return fn.apply(this, [e]);+ });+ };++ /**+ * Determines the current selection within a text input control.+ * Returns an object containing:+ * - start+ * - length+ *+ * @param {object} input+ * @returns {object}+ */+ var getSelection = function(input) {+ var result = {};+ if ('selectionStart' in input) {+ result.start = input.selectionStart;+ result.length = input.selectionEnd - result.start;+ } else if (document.selection) {+ input.focus();+ var sel = document.selection.createRange();+ var selLen = document.selection.createRange().text.length;+ sel.moveStart('character', -input.value.length);+ result.start = sel.text.length - selLen;+ result.length = selLen;+ }+ return result;+ };++ /**+ * Copies CSS properties from one element to another.+ *+ * @param {object} $from+ * @param {object} $to+ * @param {array} properties+ */+ var transferStyles = function($from, $to, properties) {+ var i, n, styles = {};+ if (properties) {+ for (i = 0, n = properties.length; i < n; i++) {+ styles[properties[i]] = $from.css(properties[i]);+ }+ } else {+ styles = $from.css();+ }+ $to.css(styles);+ };++ /**+ * Measures the width of a string within a+ * parent element (in pixels).+ *+ * @param {string} str+ * @param {object} $parent+ * @returns {int}+ */+ var measureString = function(str, $parent) {+ if (!str) {+ return 0;+ }++ var $test = $('<test>').css({+ position: 'absolute',+ top: -99999,+ left: -99999,+ width: 'auto',+ padding: 0,+ whiteSpace: 'pre'+ }).text(str).appendTo('body');++ transferStyles($parent, $test, [+ 'letterSpacing',+ 'fontSize',+ 'fontFamily',+ 'fontWeight',+ 'textTransform'+ ]);++ var width = $test.width();+ $test.remove();++ return width;+ };++ /**+ * Sets up an input to grow horizontally as the user+ * types. If the value is changed manually, you can+ * trigger the "update" handler to resize:+ *+ * $input.trigger('update');+ *+ * @param {object} $input+ */+ var autoGrow = function($input) {+ var currentWidth = null;++ var update = function(e, options) {+ var value, keyCode, printable, placeholder, width;+ var shift, character, selection;+ e = e || window.event || {};+ options = options || {};++ if (e.metaKey || e.altKey) return;+ if (!options.force && $input.data('grow') === false) return;++ value = $input.val();+ if (e.type && e.type.toLowerCase() === 'keydown') {+ keyCode = e.keyCode;+ printable = (+ (keyCode >= 97 && keyCode <= 122) || // a-z+ (keyCode >= 65 && keyCode <= 90) || // A-Z+ (keyCode >= 48 && keyCode <= 57) || // 0-9+ keyCode === 32 // space+ );++ if (keyCode === KEY_DELETE || keyCode === KEY_BACKSPACE) {+ selection = getSelection($input[0]);+ if (selection.length) {+ value = value.substring(0, selection.start) + value.substring(selection.start + selection.length);+ } else if (keyCode === KEY_BACKSPACE && selection.start) {+ value = value.substring(0, selection.start - 1) + value.substring(selection.start + 1);+ } else if (keyCode === KEY_DELETE && typeof selection.start !== 'undefined') {+ value = value.substring(0, selection.start) + value.substring(selection.start + 1);+ }+ } else if (printable) {+ shift = e.shiftKey;+ character = String.fromCharCode(e.keyCode);+ if (shift) character = character.toUpperCase();+ else character = character.toLowerCase();+ value += character;+ }+ }++ placeholder = $input.attr('placeholder');+ if (!value && placeholder) {+ value = placeholder;+ }++ width = measureString(value, $input) + 4;+ if (width !== currentWidth) {+ currentWidth = width;+ $input.width(width);+ $input.triggerHandler('resize');+ }+ };++ $input.on('keydown keyup update blur', update);+ update();+ };++ var Selectize = function($input, settings) {+ var key, i, n, dir, input, self = this;+ input = $input[0];+ input.selectize = self;++ // detect rtl environment+ dir = window.getComputedStyle ? window.getComputedStyle(input, null).getPropertyValue('direction') : input.currentStyle && input.currentStyle.direction;+ dir = dir || $input.parents('[dir]:first').attr('dir') || '';++ // setup default state+ $.extend(self, {+ settings : settings,+ $input : $input,+ tagType : input.tagName.toLowerCase() === 'select' ? TAG_SELECT : TAG_INPUT,+ rtl : /rtl/i.test(dir),++ eventNS : '.selectize' + (++Selectize.count),+ highlightedValue : null,+ isOpen : false,+ isDisabled : false,+ isRequired : $input.is('[required]'),+ isInvalid : false,+ isLocked : false,+ isFocused : false,+ isInputHidden : false,+ isSetup : false,+ isShiftDown : false,+ isCmdDown : false,+ isCtrlDown : false,+ ignoreFocus : false,+ ignoreBlur : false,+ ignoreHover : false,+ hasOptions : false,+ currentResults : null,+ lastValue : '',+ caretPos : 0,+ loading : 0,+ loadedSearches : {},++ $activeOption : null,+ $activeItems : [],++ optgroups : {},+ options : {},+ userOptions : {},+ items : [],+ renderCache : {},+ onSearchChange : settings.loadThrottle === null ? self.onSearchChange : debounce(self.onSearchChange, settings.loadThrottle)+ });++ // search system+ self.sifter = new Sifter(this.options, {diacritics: settings.diacritics});++ // build options table+ $.extend(self.options, build_hash_table(settings.valueField, settings.options));+ delete self.settings.options;++ // build optgroup table+ $.extend(self.optgroups, build_hash_table(settings.optgroupValueField, settings.optgroups));+ delete self.settings.optgroups;++ // option-dependent defaults+ self.settings.mode = self.settings.mode || (self.settings.maxItems === 1 ? 'single' : 'multi');+ if (typeof self.settings.hideSelected !== 'boolean') {+ self.settings.hideSelected = self.settings.mode === 'multi';+ }++ if (self.settings.create) {+ self.canCreate = function(input) {+ var filter = self.settings.createFilter;+ return input.length+ && (typeof filter !== 'function' || filter.apply(self, [input]))+ && (typeof filter !== 'string' || new RegExp(filter).test(input))+ && (!(filter instanceof RegExp) || filter.test(input));+ };+ }++ self.initializePlugins(self.settings.plugins);+ self.setupCallbacks();+ self.setupTemplates();+ self.setup();+ };++ // mixins+ // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -++ MicroEvent.mixin(Selectize);+ MicroPlugin.mixin(Selectize);++ // methods+ // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -++ $.extend(Selectize.prototype, {++ /**+ * Creates all elements and sets up event bindings.+ */+ setup: function() {+ var self = this;+ var settings = self.settings;+ var eventNS = self.eventNS;+ var $window = $(window);+ var $document = $(document);+ var $input = self.$input;++ var $wrapper;+ var $control;+ var $control_input;+ var $dropdown;+ var $dropdown_content;+ var $dropdown_parent;+ var inputMode;+ var timeout_blur;+ var timeout_focus;+ var tab_index;+ var classes;+ var classes_plugins;++ inputMode = self.settings.mode;+ tab_index = $input.attr('tabindex') || '';+ classes = $input.attr('class') || '';++ $wrapper = $('<div>').addClass(settings.wrapperClass).addClass(classes).addClass(inputMode);+ $control = $('<div>').addClass(settings.inputClass).addClass('items').appendTo($wrapper);+ $control_input = $('<input type="text" autocomplete="off" />').appendTo($control).attr('tabindex', tab_index);+ $dropdown_parent = $(settings.dropdownParent || $wrapper);+ $dropdown = $('<div>').addClass(settings.dropdownClass).addClass(classes).addClass(inputMode).hide().appendTo($dropdown_parent);+ $dropdown_content = $('<div>').addClass(settings.dropdownContentClass).appendTo($dropdown);++ $wrapper.css({+ width: $input[0].style.width+ });++ if (self.plugins.names.length) {+ classes_plugins = 'plugin-' + self.plugins.names.join(' plugin-');+ $wrapper.addClass(classes_plugins);+ $dropdown.addClass(classes_plugins);+ }++ if ((settings.maxItems === null || settings.maxItems > 1) && self.tagType === TAG_SELECT) {+ $input.attr('multiple', 'multiple');+ }++ if (self.settings.placeholder) {+ $control_input.attr('placeholder', settings.placeholder);+ }++ if ($input.attr('autocorrect')) {+ $control_input.attr('autocorrect', $input.attr('autocorrect'));+ }++ if ($input.attr('autocapitalize')) {+ $control_input.attr('autocapitalize', $input.attr('autocapitalize'));+ }++ self.$wrapper = $wrapper;+ self.$control = $control;+ self.$control_input = $control_input;+ self.$dropdown = $dropdown;+ self.$dropdown_content = $dropdown_content;++ $dropdown.on('mouseenter', '[data-selectable]', function() { return self.onOptionHover.apply(self, arguments); });+ $dropdown.on('mousedown', '[data-selectable]', function() { return self.onOptionSelect.apply(self, arguments); });+ watchChildEvent($control, 'mousedown', '*:not(input)', function() { return self.onItemSelect.apply(self, arguments); });+ autoGrow($control_input);++ $control.on({+ mousedown : function() { return self.onMouseDown.apply(self, arguments); },+ click : function() { return self.onClick.apply(self, arguments); }+ });++ $control_input.on({+ mousedown : function(e) { e.stopPropagation(); },+ keydown : function() { return self.onKeyDown.apply(self, arguments); },+ keyup : function() { return self.onKeyUp.apply(self, arguments); },+ keypress : function() { return self.onKeyPress.apply(self, arguments); },+ resize : function() { self.positionDropdown.apply(self, []); },+ blur : function() { return self.onBlur.apply(self, arguments); },+ focus : function() { self.ignoreBlur = false; return self.onFocus.apply(self, arguments); },+ paste : function() { return self.onPaste.apply(self, arguments); }+ });++ $document.on('keydown' + eventNS, function(e) {+ self.isCmdDown = e[IS_MAC ? 'metaKey' : 'ctrlKey'];+ self.isCtrlDown = e[IS_MAC ? 'altKey' : 'ctrlKey'];+ self.isShiftDown = e.shiftKey;+ });++ $document.on('keyup' + eventNS, function(e) {+ if (e.keyCode === KEY_CTRL) self.isCtrlDown = false;+ if (e.keyCode === KEY_SHIFT) self.isShiftDown = false;+ if (e.keyCode === KEY_CMD) self.isCmdDown = false;+ });++ $document.on('mousedown' + eventNS, function(e) {+ if (self.isFocused) {+ // prevent events on the dropdown scrollbar from causing the control to blur+ if (e.target === self.$dropdown[0] || e.target.parentNode === self.$dropdown[0]) {+ return false;+ }+ // blur on click outside+ if (!self.$control.has(e.target).length && e.target !== self.$control[0]) {+ self.blur();+ }+ }+ });++ $window.on(['scroll' + eventNS, 'resize' + eventNS].join(' '), function() {+ if (self.isOpen) {+ self.positionDropdown.apply(self, arguments);+ }+ });+ $window.on('mousemove' + eventNS, function() {+ self.ignoreHover = false;+ });++ // store original children and tab index so that they can be+ // restored when the destroy() method is called.+ this.revertSettings = {+ $children : $input.children().detach(),+ tabindex : $input.attr('tabindex')+ };++ $input.attr('tabindex', -1).hide().after(self.$wrapper);++ if ($.isArray(settings.items)) {+ self.setValue(settings.items);+ delete settings.items;+ }++ // feature detect for the validation API+ if ($input[0].validity) {+ $input.on('invalid' + eventNS, function(e) {+ e.preventDefault();+ self.isInvalid = true;+ self.refreshState();+ });+ }++ self.updateOriginalInput();+ self.refreshItems();+ self.refreshState();+ self.updatePlaceholder();+ self.isSetup = true;++ if ($input.is(':disabled')) {+ self.disable();+ }++ self.on('change', this.onChange);++ $input.data('selectize', self);+ $input.addClass('selectized');+ self.trigger('initialize');++ // preload options+ if (settings.preload === true) {+ self.onSearchChange('');+ }++ },++ /**+ * Sets up default rendering functions.+ */+ setupTemplates: function() {+ var self = this;+ var field_label = self.settings.labelField;+ var field_optgroup = self.settings.optgroupLabelField;++ var templates = {+ 'optgroup': function(data) {+ return '<div class="optgroup">' + data.html + '</div>';+ },+ 'optgroup_header': function(data, escape) {+ return '<div class="optgroup-header">' + escape(data[field_optgroup]) + '</div>';+ },+ 'option': function(data, escape) {+ return '<div class="option">' + escape(data[field_label]) + '</div>';+ },+ 'item': function(data, escape) {+ return '<div class="item">' + escape(data[field_label]) + '</div>';+ },+ 'option_create': function(data, escape) {+ return '<div class="create">Add <strong>' + escape(data.input) + '</strong>…</div>';+ }+ };++ self.settings.render = $.extend({}, templates, self.settings.render);+ },++ /**+ * Maps fired events to callbacks provided+ * in the settings used when creating the control.+ */+ setupCallbacks: function() {+ var key, fn, callbacks = {+ 'initialize' : 'onInitialize',+ 'change' : 'onChange',+ 'item_add' : 'onItemAdd',+ 'item_remove' : 'onItemRemove',+ 'clear' : 'onClear',+ 'option_add' : 'onOptionAdd',+ 'option_remove' : 'onOptionRemove',+ 'option_clear' : 'onOptionClear',+ 'dropdown_open' : 'onDropdownOpen',+ 'dropdown_close' : 'onDropdownClose',+ 'type' : 'onType'+ };++ for (key in callbacks) {+ if (callbacks.hasOwnProperty(key)) {+ fn = this.settings[callbacks[key]];+ if (fn) this.on(key, fn);+ }+ }+ },++ /**+ * Triggered when the main control element+ * has a click event.+ *+ * @param {object} e+ * @return {boolean}+ */+ onClick: function(e) {+ var self = this;++ // necessary for mobile webkit devices (manual focus triggering+ // is ignored unless invoked within a click event)+ if (!self.isFocused) {+ self.focus();+ e.preventDefault();+ }+ },++ /**+ * Triggered when the main control element+ * has a mouse down event.+ *+ * @param {object} e+ * @return {boolean}+ */+ onMouseDown: function(e) {+ var self = this;+ var defaultPrevented = e.isDefaultPrevented();+ var $target = $(e.target);++ if (self.isFocused) {+ // retain focus by preventing native handling. if the+ // event target is the input it should not be modified.+ // otherwise, text selection within the input won't work.+ if (e.target !== self.$control_input[0]) {+ if (self.settings.mode === 'single') {+ // toggle dropdown+ self.isOpen ? self.close() : self.open();+ } else if (!defaultPrevented) {+ self.setActiveItem(null);+ }+ return false;+ }+ } else {+ // give control focus+ if (!defaultPrevented) {+ window.setTimeout(function() {+ self.focus();+ }, 0);+ }+ }+ },++ /**+ * Triggered when the value of the control has been changed.+ * This should propagate the event to the original DOM+ * input / select element.+ */+ onChange: function() {+ this.$input.trigger('change');+ },+++ /**+ * Triggered on <input> paste.+ *+ * @param {object} e+ * @returns {boolean}+ */+ onPaste: function(e) {+ var self = this;+ if (self.isFull() || self.isInputHidden || self.isLocked) {+ e.preventDefault();+ }+ },++ /**+ * Triggered on <input> keypress.+ *+ * @param {object} e+ * @returns {boolean}+ */+ onKeyPress: function(e) {+ if (this.isLocked) return e && e.preventDefault();+ var character = String.fromCharCode(e.keyCode || e.which);+ if (this.settings.create && character === this.settings.delimiter) {+ this.createItem();+ e.preventDefault();+ return false;+ }+ },++ /**+ * Triggered on <input> keydown.+ *+ * @param {object} e+ * @returns {boolean}+ */+ onKeyDown: function(e) {+ var isInput = e.target === this.$control_input[0];+ var self = this;++ if (self.isLocked) {+ if (e.keyCode !== KEY_TAB) {+ e.preventDefault();+ }+ return;+ }++ switch (e.keyCode) {+ case KEY_A:+ if (self.isCmdDown) {+ self.selectAll();+ return;+ }+ break;+ case KEY_ESC:+ self.close();+ return;+ case KEY_N:+ if (!e.ctrlKey || e.altKey) break;+ case KEY_DOWN:+ if (!self.isOpen && self.hasOptions) {+ self.open();+ } else if (self.$activeOption) {+ self.ignoreHover = true;+ var $next = self.getAdjacentOption(self.$activeOption, 1);+ if ($next.length) self.setActiveOption($next, true, true);+ }+ e.preventDefault();+ return;+ case KEY_P:+ if (!e.ctrlKey || e.altKey) break;+ case KEY_UP:+ if (self.$activeOption) {+ self.ignoreHover = true;+ var $prev = self.getAdjacentOption(self.$activeOption, -1);+ if ($prev.length) self.setActiveOption($prev, true, true);+ }+ e.preventDefault();+ return;+ case KEY_RETURN:+ if (self.isOpen && self.$activeOption) {+ self.onOptionSelect({currentTarget: self.$activeOption});+ }+ e.preventDefault();+ return;+ case KEY_LEFT:+ self.advanceSelection(-1, e);+ return;+ case KEY_RIGHT:+ self.advanceSelection(1, e);+ return;+ case KEY_TAB:+ if (self.settings.selectOnTab && self.isOpen && self.$activeOption) {+ self.onOptionSelect({currentTarget: self.$activeOption});+ e.preventDefault();+ }+ if (self.settings.create && self.createItem()) {+ e.preventDefault();+ }+ return;+ case KEY_BACKSPACE:+ case KEY_DELETE:+ self.deleteSelection(e);+ return;+ }++ if ((self.isFull() || self.isInputHidden) && !(IS_MAC ? e.metaKey : e.ctrlKey)) {+ e.preventDefault();+ return;+ }+ },++ /**+ * Triggered on <input> keyup.+ *+ * @param {object} e+ * @returns {boolean}+ */+ onKeyUp: function(e) {+ var self = this;++ if (self.isLocked) return e && e.preventDefault();+ var value = self.$control_input.val() || '';+ if (self.lastValue !== value) {+ self.lastValue = value;+ self.onSearchChange(value);+ self.refreshOptions();+ self.trigger('type', value);+ }+ },++ /**+ * Invokes the user-provide option provider / loader.+ *+ * Note: this function is debounced in the Selectize+ * constructor (by `settings.loadDelay` milliseconds)+ *+ * @param {string} value+ */+ onSearchChange: function(value) {+ var self = this;+ var fn = self.settings.load;+ if (!fn) return;+ if (self.loadedSearches.hasOwnProperty(value)) return;+ self.loadedSearches[value] = true;+ self.load(function(callback) {+ fn.apply(self, [value, callback]);+ });+ },++ /**+ * Triggered on <input> focus.+ *+ * @param {object} e (optional)+ * @returns {boolean}+ */+ onFocus: function(e) {+ var self = this;++ self.isFocused = true;+ if (self.isDisabled) {+ self.blur();+ e && e.preventDefault();+ return false;+ }++ if (self.ignoreFocus) return;+ if (self.settings.preload === 'focus') self.onSearchChange('');++ if (!self.$activeItems.length) {+ self.showInput();+ self.setActiveItem(null);+ self.refreshOptions(!!self.settings.openOnFocus);+ }++ self.refreshState();+ },++ /**+ * Triggered on <input> blur.+ *+ * @param {object} e+ * @returns {boolean}+ */+ onBlur: function(e) {+ var self = this;+ self.isFocused = false;+ if (self.ignoreFocus) return;++ // necessary to prevent IE closing the dropdown when the scrollbar is clicked+ if (!self.ignoreBlur && document.activeElement === self.$dropdown_content[0]) {+ self.ignoreBlur = true;+ self.onFocus(e);++ return;+ }++ if (self.settings.create && self.settings.createOnBlur) {+ self.createItem(false);+ }++ self.close();+ self.setTextboxValue('');+ self.setActiveItem(null);+ self.setActiveOption(null);+ self.setCaret(self.items.length);+ self.refreshState();+ },++ /**+ * Triggered when the user rolls over+ * an option in the autocomplete dropdown menu.+ *+ * @param {object} e+ * @returns {boolean}+ */+ onOptionHover: function(e) {+ if (this.ignoreHover) return;+ this.setActiveOption(e.currentTarget, false);+ },++ /**+ * Triggered when the user clicks on an option+ * in the autocomplete dropdown menu.+ *+ * @param {object} e+ * @returns {boolean}+ */+ onOptionSelect: function(e) {+ var value, $target, $option, self = this;++ if (e.preventDefault) {+ e.preventDefault();+ e.stopPropagation();+ }++ $target = $(e.currentTarget);+ if ($target.hasClass('create')) {+ self.createItem();+ } else {+ value = $target.attr('data-value');+ if (value) {+ self.lastQuery = null;+ self.setTextboxValue('');+ self.addItem(value);+ if (!self.settings.hideSelected && e.type && /mouse/.test(e.type)) {+ self.setActiveOption(self.getOption(value));+ }+ }+ }+ },++ /**+ * Triggered when the user clicks on an item+ * that has been selected.+ *+ * @param {object} e+ * @returns {boolean}+ */+ onItemSelect: function(e) {+ var self = this;++ if (self.isLocked) return;+ if (self.settings.mode === 'multi') {+ e.preventDefault();+ self.setActiveItem(e.currentTarget, e);+ }+ },++ /**+ * Invokes the provided method that provides+ * results to a callback---which are then added+ * as options to the control.+ *+ * @param {function} fn+ */+ load: function(fn) {+ var self = this;+ var $wrapper = self.$wrapper.addClass('loading');++ self.loading++;+ fn.apply(self, [function(results) {+ self.loading = Math.max(self.loading - 1, 0);+ if (results && results.length) {+ self.addOption(results);+ self.refreshOptions(self.isFocused && !self.isInputHidden);+ }+ if (!self.loading) {+ $wrapper.removeClass('loading');+ }+ self.trigger('load', results);+ }]);+ },++ /**+ * Sets the input field of the control to the specified value.+ *+ * @param {string} value+ */+ setTextboxValue: function(value) {+ var $input = this.$control_input;+ var changed = $input.val() !== value;+ if (changed) {+ $input.val(value).triggerHandler('update');+ this.lastValue = value;+ }+ },++ /**+ * Returns the value of the control. If multiple items+ * can be selected (e.g. <select multiple>), this returns+ * an array. If only one item can be selected, this+ * returns a string.+ *+ * @returns {mixed}+ */+ getValue: function() {+ if (this.tagType === TAG_SELECT && this.$input.attr('multiple')) {+ return this.items;+ } else {+ return this.items.join(this.settings.delimiter);+ }+ },++ /**+ * Resets the selected items to the given value.+ *+ * @param {mixed} value+ */+ setValue: function(value) {+ debounce_events(this, ['change'], function() {+ this.clear();+ this.addItems(value);+ });+ },++ /**+ * Sets the selected item.+ *+ * @param {object} $item+ * @param {object} e (optional)+ */+ setActiveItem: function($item, e) {+ var self = this;+ var eventName;+ var i, idx, begin, end, item, swap;+ var $last;++ if (self.settings.mode === 'single') return;+ $item = $($item);++ // clear the active selection+ if (!$item.length) {+ $(self.$activeItems).removeClass('active');+ self.$activeItems = [];+ if (self.isFocused) {+ self.showInput();+ }+ return;+ }++ // modify selection+ eventName = e && e.type.toLowerCase();++ if (eventName === 'mousedown' && self.isShiftDown && self.$activeItems.length) {+ $last = self.$control.children('.active:last');+ begin = Array.prototype.indexOf.apply(self.$control[0].childNodes, [$last[0]]);+ end = Array.prototype.indexOf.apply(self.$control[0].childNodes, [$item[0]]);+ if (begin > end) {+ swap = begin;+ begin = end;+ end = swap;+ }+ for (i = begin; i <= end; i++) {+ item = self.$control[0].childNodes[i];+ if (self.$activeItems.indexOf(item) === -1) {+ $(item).addClass('active');+ self.$activeItems.push(item);+ }+ }+ e.preventDefault();+ } else if ((eventName === 'mousedown' && self.isCtrlDown) || (eventName === 'keydown' && this.isShiftDown)) {+ if ($item.hasClass('active')) {+ idx = self.$activeItems.indexOf($item[0]);+ self.$activeItems.splice(idx, 1);+ $item.removeClass('active');+ } else {+ self.$activeItems.push($item.addClass('active')[0]);+ }+ } else {+ $(self.$activeItems).removeClass('active');+ self.$activeItems = [$item.addClass('active')[0]];+ }++ // ensure control has focus+ self.hideInput();+ if (!this.isFocused) {+ self.focus();+ }+ },++ /**+ * Sets the selected item in the dropdown menu+ * of available options.+ *+ * @param {object} $object+ * @param {boolean} scroll+ * @param {boolean} animate+ */+ setActiveOption: function($option, scroll, animate) {+ var height_menu, height_item, y;+ var scroll_top, scroll_bottom;+ var self = this;++ if (self.$activeOption) self.$activeOption.removeClass('active');+ self.$activeOption = null;++ $option = $($option);+ if (!$option.length) return;++ self.$activeOption = $option.addClass('active');++ if (scroll || !isset(scroll)) {++ height_menu = self.$dropdown_content.height();+ height_item = self.$activeOption.outerHeight(true);+ scroll = self.$dropdown_content.scrollTop() || 0;+ y = self.$activeOption.offset().top - self.$dropdown_content.offset().top + scroll;+ scroll_top = y;+ scroll_bottom = y - height_menu + height_item;++ if (y + height_item > height_menu + scroll) {+ self.$dropdown_content.stop().animate({scrollTop: scroll_bottom}, animate ? self.settings.scrollDuration : 0);+ } else if (y < scroll) {+ self.$dropdown_content.stop().animate({scrollTop: scroll_top}, animate ? self.settings.scrollDuration : 0);+ }++ }+ },++ /**+ * Selects all items (CTRL + A).+ */+ selectAll: function() {+ var self = this;+ if (self.settings.mode === 'single') return;++ self.$activeItems = Array.prototype.slice.apply(self.$control.children(':not(input)').addClass('active'));+ if (self.$activeItems.length) {+ self.hideInput();+ self.close();+ }+ self.focus();+ },++ /**+ * Hides the input element out of view, while+ * retaining its focus.+ */+ hideInput: function() {+ var self = this;++ self.setTextboxValue('');+ self.$control_input.css({opacity: 0, position: 'absolute', left: self.rtl ? 10000 : -10000});+ self.isInputHidden = true;+ },++ /**+ * Restores input visibility.+ */+ showInput: function() {+ this.$control_input.css({opacity: 1, position: 'relative', left: 0});+ this.isInputHidden = false;+ },++ /**+ * Gives the control focus. If "trigger" is falsy,+ * focus handlers won't be fired--causing the focus+ * to happen silently in the background.+ *+ * @param {boolean} trigger+ */+ focus: function() {+ var self = this;+ if (self.isDisabled) return;++ self.ignoreFocus = true;+ self.$control_input[0].focus();+ window.setTimeout(function() {+ self.ignoreFocus = false;+ self.onFocus();+ }, 0);+ },++ /**+ * Forces the control out of focus.+ */+ blur: function() {+ this.$control_input.trigger('blur');+ },++ /**+ * Returns a function that scores an object+ * to show how good of a match it is to the+ * provided query.+ *+ * @param {string} query+ * @param {object} options+ * @return {function}+ */+ getScoreFunction: function(query) {+ return this.sifter.getScoreFunction(query, this.getSearchOptions());+ },++ /**+ * Returns search options for sifter (the system+ * for scoring and sorting results).+ *+ * @see https://github.com/brianreavis/sifter.js+ * @return {object}+ */+ getSearchOptions: function() {+ var settings = this.settings;+ var sort = settings.sortField;+ if (typeof sort === 'string') {+ sort = {field: sort};+ }++ return {+ fields : settings.searchField,+ conjunction : settings.searchConjunction,+ sort : sort+ };+ },++ /**+ * Searches through available options and returns+ * a sorted array of matches.+ *+ * Returns an object containing:+ *+ * - query {string}+ * - tokens {array}+ * - total {int}+ * - items {array}+ *+ * @param {string} query+ * @returns {object}+ */+ search: function(query) {+ var i, value, score, result, calculateScore;+ var self = this;+ var settings = self.settings;+ var options = this.getSearchOptions();++ // validate user-provided result scoring function+ if (settings.score) {+ calculateScore = self.settings.score.apply(this, [query]);+ if (typeof calculateScore !== 'function') {+ throw new Error('Selectize "score" setting must be a function that returns a function');+ }+ }++ // perform search+ if (query !== self.lastQuery) {+ self.lastQuery = query;+ result = self.sifter.search(query, $.extend(options, {score: calculateScore}));+ self.currentResults = result;+ } else {+ result = $.extend(true, {}, self.currentResults);+ }++ // filter out selected items+ if (settings.hideSelected) {+ for (i = result.items.length - 1; i >= 0; i--) {+ if (self.items.indexOf(hash_key(result.items[i].id)) !== -1) {+ result.items.splice(i, 1);+ }+ }+ }++ return result;+ },++ /**+ * Refreshes the list of available options shown+ * in the autocomplete dropdown menu.+ *+ * @param {boolean} triggerDropdown+ */+ refreshOptions: function(triggerDropdown) {+ var i, j, k, n, groups, groups_order, option, option_html, optgroup, optgroups, html, html_children, has_create_option;+ var $active, $active_before, $create;++ if (typeof triggerDropdown === 'undefined') {+ triggerDropdown = true;+ }++ var self = this;+ var query = self.$control_input.val();+ var results = self.search(query);+ var $dropdown_content = self.$dropdown_content;+ var active_before = self.$activeOption && hash_key(self.$activeOption.attr('data-value'));++ // build markup+ n = results.items.length;+ if (typeof self.settings.maxOptions === 'number') {+ n = Math.min(n, self.settings.maxOptions);+ }++ // render and group available options individually+ groups = {};++ if (self.settings.optgroupOrder) {+ groups_order = self.settings.optgroupOrder;+ for (i = 0; i < groups_order.length; i++) {+ groups[groups_order[i]] = [];+ }+ } else {+ groups_order = [];+ }++ for (i = 0; i < n; i++) {+ option = self.options[results.items[i].id];+ option_html = self.render('option', option);+ optgroup = option[self.settings.optgroupField] || '';+ optgroups = $.isArray(optgroup) ? optgroup : [optgroup];++ for (j = 0, k = optgroups && optgroups.length; j < k; j++) {+ optgroup = optgroups[j];+ if (!self.optgroups.hasOwnProperty(optgroup)) {+ optgroup = '';+ }+ if (!groups.hasOwnProperty(optgroup)) {+ groups[optgroup] = [];+ groups_order.push(optgroup);+ }+ groups[optgroup].push(option_html);+ }+ }++ // render optgroup headers & join groups+ html = [];+ for (i = 0, n = groups_order.length; i < n; i++) {+ optgroup = groups_order[i];+ if (self.optgroups.hasOwnProperty(optgroup) && groups[optgroup].length) {+ // render the optgroup header and options within it,+ // then pass it to the wrapper template+ html_children = self.render('optgroup_header', self.optgroups[optgroup]) || '';+ html_children += groups[optgroup].join('');+ html.push(self.render('optgroup', $.extend({}, self.optgroups[optgroup], {+ html: html_children+ })));+ } else {+ html.push(groups[optgroup].join(''));+ }+ }++ $dropdown_content.html(html.join(''));++ // highlight matching terms inline+ if (self.settings.highlight && results.query.length && results.tokens.length) {+ for (i = 0, n = results.tokens.length; i < n; i++) {+ highlight($dropdown_content, results.tokens[i].regex);+ }+ }++ // add "selected" class to selected options+ if (!self.settings.hideSelected) {+ for (i = 0, n = self.items.length; i < n; i++) {+ self.getOption(self.items[i]).addClass('selected');+ }+ }++ // add create option+ has_create_option = self.settings.create && self.canCreate(results.query);+ if (has_create_option) {+ $dropdown_content.prepend(self.render('option_create', {input: query}));+ $create = $($dropdown_content[0].childNodes[0]);+ }++ // activate+ self.hasOptions = results.items.length > 0 || has_create_option;+ if (self.hasOptions) {+ if (results.items.length > 0) {+ $active_before = active_before && self.getOption(active_before);+ if ($active_before && $active_before.length) {+ $active = $active_before;+ } else if (self.settings.mode === 'single' && self.items.length) {+ $active = self.getOption(self.items[0]);+ }+ if (!$active || !$active.length) {+ if ($create && !self.settings.addPrecedence) {+ $active = self.getAdjacentOption($create, 1);+ } else {+ $active = $dropdown_content.find('[data-selectable]:first');+ }+ }+ } else {+ $active = $create;+ }+ self.setActiveOption($active);+ if (triggerDropdown && !self.isOpen) { self.open(); }+ } else {+ self.setActiveOption(null);+ if (triggerDropdown && self.isOpen) { self.close(); }+ }+ },++ /**+ * Adds an available option. If it already exists,+ * nothing will happen. Note: this does not refresh+ * the options list dropdown (use `refreshOptions`+ * for that).+ *+ * Usage:+ *+ * this.addOption(data)+ *+ * @param {object} data+ */+ addOption: function(data) {+ var i, n, optgroup, value, self = this;++ if ($.isArray(data)) {+ for (i = 0, n = data.length; i < n; i++) {+ self.addOption(data[i]);+ }+ return;+ }++ value = hash_key(data[self.settings.valueField]);+ if (!value || self.options.hasOwnProperty(value)) return;++ self.userOptions[value] = true;+ self.options[value] = data;+ self.lastQuery = null;+ self.trigger('option_add', value, data);+ },++ /**+ * Registers a new optgroup for options+ * to be bucketed into.+ *+ * @param {string} id+ * @param {object} data+ */+ addOptionGroup: function(id, data) {+ this.optgroups[id] = data;+ this.trigger('optgroup_add', id, data);+ },++ /**+ * Updates an option available for selection. If+ * it is visible in the selected items or options+ * dropdown, it will be re-rendered automatically.+ *+ * @param {string} value+ * @param {object} data+ */+ updateOption: function(value, data) {+ var self = this;+ var $item, $item_new;+ var value_new, index_item, cache_items, cache_options;++ value = hash_key(value);+ value_new = hash_key(data[self.settings.valueField]);++ // sanity checks+ if (!self.options.hasOwnProperty(value)) return;+ if (!value_new) throw new Error('Value must be set in option data');++ // update references+ if (value_new !== value) {+ delete self.options[value];+ index_item = self.items.indexOf(value);+ if (index_item !== -1) {+ self.items.splice(index_item, 1, value_new);+ }+ }+ self.options[value_new] = data;++ // invalidate render cache+ cache_items = self.renderCache['item'];+ cache_options = self.renderCache['option'];++ if (cache_items) {+ delete cache_items[value];+ delete cache_items[value_new];+ }+ if (cache_options) {+ delete cache_options[value];+ delete cache_options[value_new];+ }++ // update the item if it's selected+ if (self.items.indexOf(value_new) !== -1) {+ $item = self.getItem(value);+ $item_new = $(self.render('item', data));+ if ($item.hasClass('active')) $item_new.addClass('active');+ $item.replaceWith($item_new);+ }++ // update dropdown contents+ if (self.isOpen) {+ self.refreshOptions(false);+ }+ },++ /**+ * Removes a single option.+ *+ * @param {string} value+ */+ removeOption: function(value) {+ var self = this;+ value = hash_key(value);++ var cache_items = self.renderCache['item'];+ var cache_options = self.renderCache['option'];+ if (cache_items) delete cache_items[value];+ if (cache_options) delete cache_options[value];++ delete self.userOptions[value];+ delete self.options[value];+ self.lastQuery = null;+ self.trigger('option_remove', value);+ self.removeItem(value);+ },++ /**+ * Clears all options.+ */+ clearOptions: function() {+ var self = this;++ self.loadedSearches = {};+ self.userOptions = {};+ self.renderCache = {};+ self.options = self.sifter.items = {};+ self.lastQuery = null;+ self.trigger('option_clear');+ self.clear();+ },++ /**+ * Returns the jQuery element of the option+ * matching the given value.+ *+ * @param {string} value+ * @returns {object}+ */+ getOption: function(value) {+ return this.getElementWithValue(value, this.$dropdown_content.find('[data-selectable]'));+ },++ /**+ * Returns the jQuery element of the next or+ * previous selectable option.+ *+ * @param {object} $option+ * @param {int} direction can be 1 for next or -1 for previous+ * @return {object}+ */+ getAdjacentOption: function($option, direction) {+ var $options = this.$dropdown.find('[data-selectable]');+ var index = $options.index($option) + direction;++ return index >= 0 && index < $options.length ? $options.eq(index) : $();+ },++ /**+ * Finds the first element with a "data-value" attribute+ * that matches the given value.+ *+ * @param {mixed} value+ * @param {object} $els+ * @return {object}+ */+ getElementWithValue: function(value, $els) {+ value = hash_key(value);++ if (value) {+ for (var i = 0, n = $els.length; i < n; i++) {+ if ($els[i].getAttribute('data-value') === value) {+ return $($els[i]);+ }+ }+ }++ return $();+ },++ /**+ * Returns the jQuery element of the item+ * matching the given value.+ *+ * @param {string} value+ * @returns {object}+ */+ getItem: function(value) {+ return this.getElementWithValue(value, this.$control.children());+ },++ /**+ * "Selects" multiple items at once. Adds them to the list+ * at the current caret position.+ *+ * @param {string} value+ */+ addItems: function(values) {+ var items = $.isArray(values) ? values : [values];+ for (var i = 0, n = items.length; i < n; i++) {+ this.isPending = (i < n - 1);+ this.addItem(items[i]);+ }+ },++ /**+ * "Selects" an item. Adds it to the list+ * at the current caret position.+ *+ * @param {string} value+ */+ addItem: function(value) {+ debounce_events(this, ['change'], function() {+ var $item, $option, $options;+ var self = this;+ var inputMode = self.settings.mode;+ var i, active, value_next, wasFull;+ value = hash_key(value);++ if (self.items.indexOf(value) !== -1) {+ if (inputMode === 'single') self.close();+ return;+ }++ if (!self.options.hasOwnProperty(value)) return;+ if (inputMode === 'single') self.clear();+ if (inputMode === 'multi' && self.isFull()) return;++ $item = $(self.render('item', self.options[value]));+ wasFull = self.isFull();+ self.items.splice(self.caretPos, 0, value);+ self.insertAtCaret($item);+ if (!self.isPending || (!wasFull && self.isFull())) {+ self.refreshState();+ }++ if (self.isSetup) {+ $options = self.$dropdown_content.find('[data-selectable]');++ // update menu / remove the option (if this is not one item being added as part of series)+ if (!self.isPending) {+ $option = self.getOption(value);+ value_next = self.getAdjacentOption($option, 1).attr('data-value');+ self.refreshOptions(self.isFocused && inputMode !== 'single');+ if (value_next) {+ self.setActiveOption(self.getOption(value_next));+ }+ }++ // hide the menu if the maximum number of items have been selected or no options are left+ if (!$options.length || self.isFull()) {+ self.close();+ } else {+ self.positionDropdown();+ }++ self.updatePlaceholder();+ self.trigger('item_add', value, $item);+ self.updateOriginalInput();+ }+ });+ },++ /**+ * Removes the selected item matching+ * the provided value.+ *+ * @param {string} value+ */+ removeItem: function(value) {+ var self = this;+ var $item, i, idx;++ $item = (typeof value === 'object') ? value : self.getItem(value);+ value = hash_key($item.attr('data-value'));+ i = self.items.indexOf(value);++ if (i !== -1) {+ $item.remove();+ if ($item.hasClass('active')) {+ idx = self.$activeItems.indexOf($item[0]);+ self.$activeItems.splice(idx, 1);+ }++ self.items.splice(i, 1);+ self.lastQuery = null;+ if (!self.settings.persist && self.userOptions.hasOwnProperty(value)) {+ self.removeOption(value);+ }++ if (i < self.caretPos) {+ self.setCaret(self.caretPos - 1);+ }++ self.refreshState();+ self.updatePlaceholder();+ self.updateOriginalInput();+ self.positionDropdown();+ self.trigger('item_remove', value);+ }+ },++ /**+ * Invokes the `create` method provided in the+ * selectize options that should provide the data+ * for the new item, given the user input.+ *+ * Once this completes, it will be added+ * to the item list.+ *+ * @return {boolean}+ */+ createItem: function(triggerDropdown) {+ var self = this;+ var input = $.trim(self.$control_input.val() || '');+ var caret = self.caretPos;+ if (!self.canCreate(input)) return false;+ self.lock();++ if (typeof triggerDropdown === 'undefined') {+ triggerDropdown = true;+ }++ var setup = (typeof self.settings.create === 'function') ? this.settings.create : function(input) {+ var data = {};+ data[self.settings.labelField] = input;+ data[self.settings.valueField] = input;+ return data;+ };++ var create = once(function(data) {+ self.unlock();++ if (!data || typeof data !== 'object') return;+ var value = hash_key(data[self.settings.valueField]);+ if (!value) return;++ self.setTextboxValue('');+ self.addOption(data);+ self.setCaret(caret);+ self.addItem(value);+ self.refreshOptions(triggerDropdown && self.settings.mode !== 'single');+ });++ var output = setup.apply(this, [input, create]);+ if (typeof output !== 'undefined') {+ create(output);+ }++ return true;+ },++ /**+ * Re-renders the selected item lists.+ */+ refreshItems: function() {+ this.lastQuery = null;++ if (this.isSetup) {+ for (var i = 0; i < this.items.length; i++) {+ this.addItem(this.items);+ }+ }++ this.refreshState();+ this.updateOriginalInput();+ },++ /**+ * Updates all state-dependent attributes+ * and CSS classes.+ */+ refreshState: function() {+ var invalid, self = this;+ if (self.isRequired) {+ if (self.items.length) self.isInvalid = false;+ self.$control_input.prop('required', invalid);+ }+ self.refreshClasses();+ },++ /**+ * Updates all state-dependent CSS classes.+ */+ refreshClasses: function() {+ var self = this;+ var isFull = self.isFull();+ var isLocked = self.isLocked;++ self.$wrapper+ .toggleClass('rtl', self.rtl);++ self.$control+ .toggleClass('focus', self.isFocused)+ .toggleClass('disabled', self.isDisabled)+ .toggleClass('required', self.isRequired)+ .toggleClass('invalid', self.isInvalid)+ .toggleClass('locked', isLocked)+ .toggleClass('full', isFull).toggleClass('not-full', !isFull)+ .toggleClass('input-active', self.isFocused && !self.isInputHidden)+ .toggleClass('dropdown-active', self.isOpen)+ .toggleClass('has-options', !$.isEmptyObject(self.options))+ .toggleClass('has-items', self.items.length > 0);++ self.$control_input.data('grow', !isFull && !isLocked);+ },++ /**+ * Determines whether or not more items can be added+ * to the control without exceeding the user-defined maximum.+ *+ * @returns {boolean}+ */+ isFull: function() {+ return this.settings.maxItems !== null && this.items.length >= this.settings.maxItems;+ },++ /**+ * Refreshes the original <select> or <input>+ * element to reflect the current state.+ */+ updateOriginalInput: function() {+ var i, n, options, self = this;++ if (self.tagType === TAG_SELECT) {+ options = [];+ for (i = 0, n = self.items.length; i < n; i++) {+ options.push('<option value="' + escape_html(self.items[i]) + '" selected="selected"></option>');+ }+ if (!options.length && !this.$input.attr('multiple')) {+ options.push('<option value="" selected="selected"></option>');+ }+ self.$input.html(options.join(''));+ } else {+ self.$input.val(self.getValue());+ self.$input.attr('value',self.$input.val());+ }++ if (self.isSetup) {+ self.trigger('change', self.$input.val());+ }+ },++ /**+ * Shows/hide the input placeholder depending+ * on if there items in the list already.+ */+ updatePlaceholder: function() {+ if (!this.settings.placeholder) return;+ var $input = this.$control_input;++ if (this.items.length) {+ $input.removeAttr('placeholder');+ } else {+ $input.attr('placeholder', this.settings.placeholder);+ }+ $input.triggerHandler('update', {force: true});+ },++ /**+ * Shows the autocomplete dropdown containing+ * the available options.+ */+ open: function() {+ var self = this;++ if (self.isLocked || self.isOpen || (self.settings.mode === 'multi' && self.isFull())) return;+ self.focus();+ self.isOpen = true;+ self.refreshState();+ self.$dropdown.css({visibility: 'hidden', display: 'block'});+ self.positionDropdown();+ self.$dropdown.css({visibility: 'visible'});+ self.trigger('dropdown_open', self.$dropdown);+ },++ /**+ * Closes the autocomplete dropdown menu.+ */+ close: function() {+ var self = this;+ var trigger = self.isOpen;++ if (self.settings.mode === 'single' && self.items.length) {+ self.hideInput();+ }++ self.isOpen = false;+ self.$dropdown.hide();+ self.setActiveOption(null);+ self.refreshState();++ if (trigger) self.trigger('dropdown_close', self.$dropdown);+ },++ /**+ * Calculates and applies the appropriate+ * position of the dropdown.+ */+ positionDropdown: function() {+ var $control = this.$control;+ var offset = this.settings.dropdownParent === 'body' ? $control.offset() : $control.position();+ offset.top += $control.outerHeight(true);++ this.$dropdown.css({+ width : $control.outerWidth(),+ top : offset.top,+ left : offset.left+ });+ },++ /**+ * Resets / clears all selected items+ * from the control.+ */+ clear: function() {+ var self = this;++ if (!self.items.length) return;+ self.$control.children(':not(input)').remove();+ self.items = [];+ self.lastQuery = null;+ self.setCaret(0);+ self.setActiveItem(null);+ self.updatePlaceholder();+ self.updateOriginalInput();+ self.refreshState();+ self.showInput();+ self.trigger('clear');+ },++ /**+ * A helper method for inserting an element+ * at the current caret position.+ *+ * @param {object} $el+ */+ insertAtCaret: function($el) {+ var caret = Math.min(this.caretPos, this.items.length);+ if (caret === 0) {+ this.$control.prepend($el);+ } else {+ $(this.$control[0].childNodes[caret]).before($el);+ }+ this.setCaret(caret + 1);+ },++ /**+ * Removes the current selected item(s).+ *+ * @param {object} e (optional)+ * @returns {boolean}+ */+ deleteSelection: function(e) {+ var i, n, direction, selection, values, caret, option_select, $option_select, $tail;+ var self = this;++ direction = (e && e.keyCode === KEY_BACKSPACE) ? -1 : 1;+ selection = getSelection(self.$control_input[0]);++ if (self.$activeOption && !self.settings.hideSelected) {+ option_select = self.getAdjacentOption(self.$activeOption, -1).attr('data-value');+ }++ // determine items that will be removed+ values = [];++ if (self.$activeItems.length) {+ $tail = self.$control.children('.active:' + (direction > 0 ? 'last' : 'first'));+ caret = self.$control.children(':not(input)').index($tail);+ if (direction > 0) { caret++; }++ for (i = 0, n = self.$activeItems.length; i < n; i++) {+ values.push($(self.$activeItems[i]).attr('data-value'));+ }+ if (e) {+ e.preventDefault();+ e.stopPropagation();+ }+ } else if ((self.isFocused || self.settings.mode === 'single') && self.items.length) {+ if (direction < 0 && selection.start === 0 && selection.length === 0) {+ values.push(self.items[self.caretPos - 1]);+ } else if (direction > 0 && selection.start === self.$control_input.val().length) {+ values.push(self.items[self.caretPos]);+ }+ }++ // allow the callback to abort+ if (!values.length || (typeof self.settings.onDelete === 'function' && self.settings.onDelete.apply(self, [values]) === false)) {+ return false;+ }++ // perform removal+ if (typeof caret !== 'undefined') {+ self.setCaret(caret);+ }+ while (values.length) {+ self.removeItem(values.pop());+ }++ self.showInput();+ self.positionDropdown();+ self.refreshOptions(true);++ // select previous option+ if (option_select) {+ $option_select = self.getOption(option_select);+ if ($option_select.length) {+ self.setActiveOption($option_select);+ }+ }++ return true;+ },++ /**+ * Selects the previous / next item (depending+ * on the `direction` argument).+ *+ * > 0 - right+ * < 0 - left+ *+ * @param {int} direction+ * @param {object} e (optional)+ */+ advanceSelection: function(direction, e) {+ var tail, selection, idx, valueLength, cursorAtEdge, $tail;+ var self = this;++ if (direction === 0) return;+ if (self.rtl) direction *= -1;++ tail = direction > 0 ? 'last' : 'first';+ selection = getSelection(self.$control_input[0]);++ if (self.isFocused && !self.isInputHidden) {+ valueLength = self.$control_input.val().length;+ cursorAtEdge = direction < 0+ ? selection.start === 0 && selection.length === 0+ : selection.start === valueLength;++ if (cursorAtEdge && !valueLength) {+ self.advanceCaret(direction, e);+ }+ } else {+ $tail = self.$control.children('.active:' + tail);+ if ($tail.length) {+ idx = self.$control.children(':not(input)').index($tail);+ self.setActiveItem(null);+ self.setCaret(direction > 0 ? idx + 1 : idx);+ }+ }+ },++ /**+ * Moves the caret left / right.+ *+ * @param {int} direction+ * @param {object} e (optional)+ */+ advanceCaret: function(direction, e) {+ var self = this, fn, $adj;++ if (direction === 0) return;++ fn = direction > 0 ? 'next' : 'prev';+ if (self.isShiftDown) {+ $adj = self.$control_input[fn]();+ if ($adj.length) {+ self.hideInput();+ self.setActiveItem($adj);+ e && e.preventDefault();+ }+ } else {+ self.setCaret(self.caretPos + direction);+ }+ },++ /**+ * Moves the caret to the specified index.+ *+ * @param {int} i+ */+ setCaret: function(i) {+ var self = this;++ if (self.settings.mode === 'single') {+ i = self.items.length;+ } else {+ i = Math.max(0, Math.min(self.items.length, i));+ }++ if(!self.isPending) {+ // the input must be moved by leaving it in place and moving the+ // siblings, due to the fact that focus cannot be restored once lost+ // on mobile webkit devices+ var j, n, fn, $children, $child;+ $children = self.$control.children(':not(input)');+ for (j = 0, n = $children.length; j < n; j++) {+ $child = $($children[j]).detach();+ if (j < i) {+ self.$control_input.before($child);+ } else {+ self.$control.append($child);+ }+ }+ }++ self.caretPos = i;+ },++ /**+ * Disables user input on the control. Used while+ * items are being asynchronously created.+ */+ lock: function() {+ this.close();+ this.isLocked = true;+ this.refreshState();+ },++ /**+ * Re-enables user input on the control.+ */+ unlock: function() {+ this.isLocked = false;+ this.refreshState();+ },++ /**+ * Disables user input on the control completely.+ * While disabled, it cannot receive focus.+ */+ disable: function() {+ var self = this;+ self.$input.prop('disabled', true);+ self.isDisabled = true;+ self.lock();+ },++ /**+ * Enables the control so that it can respond+ * to focus and user input.+ */+ enable: function() {+ var self = this;+ self.$input.prop('disabled', false);+ self.isDisabled = false;+ self.unlock();+ },++ /**+ * Completely destroys the control and+ * unbinds all event listeners so that it can+ * be garbage collected.+ */+ destroy: function() {+ var self = this;+ var eventNS = self.eventNS;+ var revertSettings = self.revertSettings;++ self.trigger('destroy');+ self.off();+ self.$wrapper.remove();+ self.$dropdown.remove();++ self.$input+ .html('')+ .append(revertSettings.$children)+ .removeAttr('tabindex')+ .removeClass('selectized')+ .attr({tabindex: revertSettings.tabindex})+ .show();++ self.$control_input.removeData('grow');+ self.$input.removeData('selectize');++ $(window).off(eventNS);+ $(document).off(eventNS);+ $(document.body).off(eventNS);++ delete self.$input[0].selectize;+ },++ /**+ * A helper method for rendering "item" and+ * "option" templates, given the data.+ *+ * @param {string} templateName+ * @param {object} data+ * @returns {string}+ */+ render: function(templateName, data) {+ var value, id, label;+ var html = '';+ var cache = false;+ var self = this;+ var regex_tag = /^[\t ]*<([a-z][a-z0-9\-_]*(?:\:[a-z][a-z0-9\-_]*)?)/i;++ if (templateName === 'option' || templateName === 'item') {+ value = hash_key(data[self.settings.valueField]);+ cache = !!value;+ }++ // pull markup from cache if it exists+ if (cache) {+ if (!isset(self.renderCache[templateName])) {+ self.renderCache[templateName] = {};+ }+ if (self.renderCache[templateName].hasOwnProperty(value)) {+ return self.renderCache[templateName][value];+ }+ }++ // render markup+ html = self.settings.render[templateName].apply(this, [data, escape_html]);++ // add mandatory attributes+ if (templateName === 'option' || templateName === 'option_create') {+ html = html.replace(regex_tag, '<$1 data-selectable');+ }+ if (templateName === 'optgroup') {+ id = data[self.settings.optgroupValueField] || '';+ html = html.replace(regex_tag, '<$1 data-group="' + escape_replace(escape_html(id)) + '"');+ }+ if (templateName === 'option' || templateName === 'item') {+ html = html.replace(regex_tag, '<$1 data-value="' + escape_replace(escape_html(value || '')) + '"');+ }++ // update cache+ if (cache) {+ self.renderCache[templateName][value] = html;+ }++ return html;+ },++ /**+ * Clears the render cache for a template. If+ * no template is given, clears all render+ * caches.+ *+ * @param {string} templateName+ */+ clearCache: function(templateName) {+ var self = this;+ if (typeof templateName === 'undefined') {+ self.renderCache = {};+ } else {+ delete self.renderCache[templateName];+ }+ }+++ });+++ Selectize.count = 0;+ Selectize.defaults = {+ plugins: [],+ delimiter: ',',+ persist: true,+ diacritics: true,+ create: false,+ createOnBlur: false,+ createFilter: null,+ highlight: true,+ openOnFocus: true,+ maxOptions: 1000,+ maxItems: null,+ hideSelected: null,+ addPrecedence: false,+ selectOnTab: false,+ preload: false,++ scrollDuration: 60,+ loadThrottle: 300,++ dataAttr: 'data-data',+ optgroupField: 'optgroup',+ valueField: 'value',+ labelField: 'text',+ optgroupLabelField: 'label',+ optgroupValueField: 'value',+ optgroupOrder: null,++ sortField: '$order',+ searchField: ['text'],+ searchConjunction: 'and',++ mode: null,+ wrapperClass: 'selectize-control',+ inputClass: 'selectize-input',+ dropdownClass: 'selectize-dropdown',+ dropdownContentClass: 'selectize-dropdown-content',++ dropdownParent: null,++ /*+ load : null, // function(query, callback) { ... }+ score : null, // function(search) { ... }+ onInitialize : null, // function() { ... }+ onChange : null, // function(value) { ... }+ onItemAdd : null, // function(value, $item) { ... }+ onItemRemove : null, // function(value) { ... }+ onClear : null, // function() { ... }+ onOptionAdd : null, // function(value, data) { ... }+ onOptionRemove : null, // function(value) { ... }+ onOptionClear : null, // function() { ... }+ onDropdownOpen : null, // function($dropdown) { ... }+ onDropdownClose : null, // function($dropdown) { ... }+ onType : null, // function(str) { ... }+ onDelete : null, // function(values) { ... }+ */++ render: {+ /*+ item: null,+ optgroup: null,+ optgroup_header: null,+ option: null,+ option_create: null+ */+ }+ };++ $.fn.selectize = function(settings_user) {+ var defaults = $.fn.selectize.defaults;+ var settings = $.extend({}, defaults, settings_user);+ var attr_data = settings.dataAttr;+ var field_label = settings.labelField;+ var field_value = settings.valueField;+ var field_optgroup = settings.optgroupField;+ var field_optgroup_label = settings.optgroupLabelField;+ var field_optgroup_value = settings.optgroupValueField;++ /**+ * Initializes selectize from a <input type="text"> element.+ *+ * @param {object} $input+ * @param {object} settings_element+ */+ var init_textbox = function($input, settings_element) {+ var i, n, values, option, value = $.trim($input.val() || '');+ if (!value.length) return;++ values = value.split(settings.delimiter);+ for (i = 0, n = values.length; i < n; i++) {+ option = {};+ option[field_label] = values[i];+ option[field_value] = values[i];++ settings_element.options[values[i]] = option;+ }++ settings_element.items = values;+ };++ /**+ * Initializes selectize from a <select> element.+ *+ * @param {object} $input+ * @param {object} settings_element+ */+ var init_select = function($input, settings_element) {+ var i, n, tagName, $children, order = 0;+ var options = settings_element.options;++ var readData = function($el) {+ var data = attr_data && $el.attr(attr_data);+ if (typeof data === 'string' && data.length) {+ return JSON.parse(data);+ }+ return null;+ };++ var addOption = function($option, group) {+ var value, option;++ $option = $($option);++ value = $option.attr('value') || '';+ if (!value.length) return;++ // if the option already exists, it's probably been+ // duplicated in another optgroup. in this case, push+ // the current group to the "optgroup" property on the+ // existing option so that it's rendered in both places.+ if (options.hasOwnProperty(value)) {+ if (group) {+ if (!options[value].optgroup) {+ options[value].optgroup = group;+ } else if (!$.isArray(options[value].optgroup)) {+ options[value].optgroup = [options[value].optgroup, group];+ } else {+ options[value].optgroup.push(group);+ }+ }+ return;+ }++ option = readData($option) || {};+ option[field_label] = option[field_label] || $option.text();+ option[field_value] = option[field_value] || value;+ option[field_optgroup] = option[field_optgroup] || group;++ option.$order = ++order;+ options[value] = option;++ if ($option.is(':selected')) {+ settings_element.items.push(value);+ }+ };++ var addGroup = function($optgroup) {+ var i, n, id, optgroup, $options;++ $optgroup = $($optgroup);+ id = $optgroup.attr('label');++ if (id) {+ optgroup = readData($optgroup) || {};+ optgroup[field_optgroup_label] = id;+ optgroup[field_optgroup_value] = id;+ settings_element.optgroups[id] = optgroup;+ }++ $options = $('option', $optgroup);+ for (i = 0, n = $options.length; i < n; i++) {+ addOption($options[i], id);+ }+ };++ settings_element.maxItems = $input.attr('multiple') ? null : 1;++ $children = $input.children();+ for (i = 0, n = $children.length; i < n; i++) {+ tagName = $children[i].tagName.toLowerCase();+ if (tagName === 'optgroup') {+ addGroup($children[i]);+ } else if (tagName === 'option') {+ addOption($children[i]);+ }+ }+ };++ return this.each(function() {+ if (this.selectize) return;++ var instance;+ var $input = $(this);+ var tag_name = this.tagName.toLowerCase();+ var settings_element = {+ 'placeholder' : $input.children('option[value=""]').text() || $input.attr('placeholder'),+ 'options' : {},+ 'optgroups' : {},+ 'items' : []+ };++ if (tag_name === 'select') {+ init_select($input, settings_element);+ } else {+ init_textbox($input, settings_element);+ }++ instance = new Selectize($input, $.extend(true, {}, defaults, settings_element, settings_user));+ });+ };++ $.fn.selectize.defaults = Selectize.defaults;+++ Selectize.define('drag_drop', function(options) {+ if (!$.fn.sortable) throw new Error('The "drag_drop" plugin requires jQuery UI "sortable".');+ if (this.settings.mode !== 'multi') return;+ var self = this;++ self.lock = (function() {+ var original = self.lock;+ return function() {+ var sortable = self.$control.data('sortable');+ if (sortable) sortable.disable();+ return original.apply(self, arguments);+ };+ })();++ self.unlock = (function() {+ var original = self.unlock;+ return function() {+ var sortable = self.$control.data('sortable');+ if (sortable) sortable.enable();+ return original.apply(self, arguments);+ };+ })();++ self.setup = (function() {+ var original = self.setup;+ return function() {+ original.apply(this, arguments);++ var $control = self.$control.sortable({+ items: '[data-value]',+ forcePlaceholderSize: true,+ disabled: self.isLocked,+ start: function(e, ui) {+ ui.placeholder.css('width', ui.helper.css('width'));+ $control.css({overflow: 'visible'});+ },+ stop: function() {+ $control.css({overflow: 'hidden'});+ var active = self.$activeItems ? self.$activeItems.slice() : null;+ var values = [];+ $control.children('[data-value]').each(function() {+ values.push($(this).attr('data-value'));+ });+ self.setValue(values);+ self.setActiveItem(active);+ }+ });+ };+ })();++ });++ Selectize.define('dropdown_header', function(options) {+ var self = this;++ options = $.extend({+ title : 'Untitled',+ headerClass : 'selectize-dropdown-header',+ titleRowClass : 'selectize-dropdown-header-title',+ labelClass : 'selectize-dropdown-header-label',+ closeClass : 'selectize-dropdown-header-close',++ html: function(data) {+ return (+ '<div class="' + data.headerClass + '">' ++ '<div class="' + data.titleRowClass + '">' ++ '<span class="' + data.labelClass + '">' + data.title + '</span>' ++ '<a href="javascript:void(0)" class="' + data.closeClass + '">×</a>' ++ '</div>' ++ '</div>'+ );+ }+ }, options);++ self.setup = (function() {+ var original = self.setup;+ return function() {+ original.apply(self, arguments);+ self.$dropdown_header = $(options.html(options));+ self.$dropdown.prepend(self.$dropdown_header);+ };+ })();++ });++ Selectize.define('optgroup_columns', function(options) {+ var self = this;++ options = $.extend({+ equalizeWidth : true,+ equalizeHeight : true+ }, options);++ this.getAdjacentOption = function($option, direction) {+ var $options = $option.closest('[data-group]').find('[data-selectable]');+ var index = $options.index($option) + direction;++ return index >= 0 && index < $options.length ? $options.eq(index) : $();+ };++ this.onKeyDown = (function() {+ var original = self.onKeyDown;+ return function(e) {+ var index, $option, $options, $optgroup;++ if (this.isOpen && (e.keyCode === KEY_LEFT || e.keyCode === KEY_RIGHT)) {+ self.ignoreHover = true;+ $optgroup = this.$activeOption.closest('[data-group]');+ index = $optgroup.find('[data-selectable]').index(this.$activeOption);++ if(e.keyCode === KEY_LEFT) {+ $optgroup = $optgroup.prev('[data-group]');+ } else {+ $optgroup = $optgroup.next('[data-group]');+ }++ $options = $optgroup.find('[data-selectable]');+ $option = $options.eq(Math.min($options.length - 1, index));+ if ($option.length) {+ this.setActiveOption($option);+ }+ return;+ }++ return original.apply(this, arguments);+ };+ })();++ var getScrollbarWidth = function() {+ var div;+ var width = getScrollbarWidth.width;+ var doc = document;++ if (typeof width === 'undefined') {+ div = doc.createElement('div');+ div.innerHTML = '<div style="width:50px;height:50px;position:absolute;left:-50px;top:-50px;overflow:auto;"><div style="width:1px;height:100px;"></div></div>';+ div = div.firstChild;+ doc.body.appendChild(div);+ width = getScrollbarWidth.width = div.offsetWidth - div.clientWidth;+ doc.body.removeChild(div);+ }+ return width;+ };++ var equalizeSizes = function() {+ var i, n, height_max, width, width_last, width_parent, $optgroups;++ $optgroups = $('[data-group]', self.$dropdown_content);+ n = $optgroups.length;+ if (!n || !self.$dropdown_content.width()) return;++ if (options.equalizeHeight) {+ height_max = 0;+ for (i = 0; i < n; i++) {+ height_max = Math.max(height_max, $optgroups.eq(i).height());+ }+ $optgroups.css({height: height_max});+ }++ if (options.equalizeWidth) {+ width_parent = self.$dropdown_content.innerWidth() - getScrollbarWidth();+ width = Math.round(width_parent / n);+ $optgroups.css({width: width});+ if (n > 1) {+ width_last = width_parent - width * (n - 1);+ $optgroups.eq(n - 1).css({width: width_last});+ }+ }+ };++ if (options.equalizeHeight || options.equalizeWidth) {+ hook.after(this, 'positionDropdown', equalizeSizes);+ hook.after(this, 'refreshOptions', equalizeSizes);+ }+++ });++ Selectize.define('remove_button', function(options) {+ if (this.settings.mode === 'single') return;++ options = $.extend({+ label : '×',+ title : 'Remove',+ className : 'remove',+ append : true+ }, options);++ var self = this;+ var html = '<a href="javascript:void(0)" class="' + options.className + '" tabindex="-1" title="' + escape_html(options.title) + '">' + options.label + '</a>';++ /**+ * Appends an element as a child (with raw HTML).+ *+ * @param {string} html_container+ * @param {string} html_element+ * @return {string}+ */+ var append = function(html_container, html_element) {+ var pos = html_container.search(/(<\/[^>]+>\s*)$/);+ return html_container.substring(0, pos) + html_element + html_container.substring(pos);+ };++ this.setup = (function() {+ var original = self.setup;+ return function() {+ // override the item rendering method to add the button to each+ if (options.append) {+ var render_item = self.settings.render.item;+ self.settings.render.item = function(data) {+ return append(render_item.apply(this, arguments), html);+ };+ }++ original.apply(this, arguments);++ // add event listener+ this.$control.on('click', '.' + options.className, function(e) {+ e.preventDefault();+ if (self.isLocked) return;++ var $item = $(e.currentTarget).parent();+ self.setActiveItem($item);+ if (self.deleteSelection()) {+ self.setCaret(self.items.length);+ }+ });++ };+ })();++ });++ Selectize.define('restore_on_backspace', function(options) {+ var self = this;++ options.text = options.text || function(option) {+ return option[this.settings.labelField];+ };++ this.onKeyDown = (function(e) {+ var original = self.onKeyDown;+ return function(e) {+ var index, option;+ if (e.keyCode === KEY_BACKSPACE && this.$control_input.val() === '' && !this.$activeItems.length) {+ index = this.caretPos - 1;+ if (index >= 0 && index < this.items.length) {+ option = this.options[this.items[index]];+ if (this.deleteSelection(e)) {+ this.setTextboxValue(options.text.apply(this, [option]));+ this.refreshOptions(true);+ }+ e.preventDefault();+ return;+ }+ }+ return original.apply(this, arguments);+ };+ })();+ });++ return Selectize;+}));diff --git a/app/assets/javascripts/blazer/stupidtable.js b/app/assets/javascripts/blazer/stupidtable.jsnew file mode 100644index 00000000..238c63fa--- /dev/null+++ b/app/assets/javascripts/blazer/stupidtable.js@@ -0,0 +1,114 @@+// Stupid jQuery table plugin.++// Call on a table+// sortFns: Sort functions for your datatypes.+(function($) {++ $.fn.stupidtable = function(sortFns) {+ return this.each(function() {+ var $table = $(this);+ sortFns = sortFns || {};++ // Merge sort functions with some default sort functions.+ sortFns = $.extend({}, $.fn.stupidtable.default_sort_fns, sortFns);+++ // ==================================================== //+ // Begin execution! //+ // ==================================================== //++ // Do sorting when THs are clicked+ $table.on("click.stupidtable", "th", function() {+ var $this = $(this);+ var th_index = 0;+ var dir = $.fn.stupidtable.dir;++ $table.find("th").slice(0, $this.index()).each(function() {+ var cols = $(this).attr("colspan") || 1;+ th_index += parseInt(cols,10);+ });++ // Determine (and/or reverse) sorting direction, default `asc`+ var sort_dir = $this.data("sort-default") || dir.ASC;+ if ($this.data("sort-dir"))+ sort_dir = $this.data("sort-dir") === dir.ASC ? dir.DESC : dir.ASC;++ // Choose appropriate sorting function.+ var type = $this.data("sort") || null;++ // Prevent sorting if no type defined+ if (type === null) {+ return;+ }++ // Trigger `beforetablesort` event that calling scripts can hook into;+ // pass parameters for sorted column index and sorting direction+ $table.trigger("beforetablesort", {column: th_index, direction: sort_dir});+ // More reliable method of forcing a redraw+ $table.css("display");++ // Run sorting asynchronously on a timout to force browser redraw after+ // `beforetablesort` callback. Also avoids locking up the browser too much.+ setTimeout(function() {+ // Gather the elements for this column+ var column = [];+ var sortMethod = sortFns[type];+ var trs = $table.children("tbody").children("tr");++ // Extract the data for the column that needs to be sorted and pair it up+ // with the TR itself into a tuple+ trs.each(function(index,tr) {+ var $e = $(tr).children().eq(th_index);+ var sort_val = $e.data("sort-value");+ var order_by = typeof(sort_val) !== "undefined" ? sort_val : $e.text();+ column.push([order_by, tr]);+ });++ // Sort by the data-order-by value+ column.sort(function(a, b) { return sortMethod(a[0], b[0]); });+ if (sort_dir != dir.ASC)+ column.reverse();++ // Replace the content of tbody with the sorted rows. Strangely (and+ // conveniently!) enough, .append accomplishes this for us.+ trs = $.map(column, function(kv) { return kv[1]; });+ $table.children("tbody").append(trs);++ // Reset siblings+ $table.find("th").data("sort-dir", null).removeClass("sorting-desc sorting-asc");+ $this.data("sort-dir", sort_dir).addClass("sorting-"+sort_dir);++ // Trigger `aftertablesort` event. Similar to `beforetablesort`+ $table.trigger("aftertablesort", {column: th_index, direction: sort_dir});+ // More reliable method of forcing a redraw+ $table.css("display");+ }, 10);+ });+ });+ };++ // Enum containing sorting directions+ $.fn.stupidtable.dir = {ASC: "asc", DESC: "desc"};++ $.fn.stupidtable.default_sort_fns = {+ "int": function(a, b) {+ return parseInt(a.replace(/,/g, ''), 10) - parseInt(b.replace(/,/g, ''), 10);+ },+ "float": function(a, b) {+ return parseFloat(a) - parseFloat(b);+ },+ "string": function(a, b) {+ if (a < b) return -1;+ if (a > b) return +1;+ return 0;+ },+ "string-ins": function(a, b) {+ a = a.toLowerCase();+ b = b.toLowerCase();+ if (a < b) return -1;+ if (a > b) return +1;+ return 0;+ }+ };++})(jQuery);diff --git a/app/assets/stylesheets/blazer/application.css b/app/assets/stylesheets/blazer/application.cssnew file mode 100644index 00000000..b51644a3--- /dev/null+++ b/app/assets/stylesheets/blazer/application.css@@ -0,0 +1,66 @@+/*+ *= require ./bootstrap+ *= require ./selectize.default+ *= require ./github+ *= require ./daterangepicker-bs3+ *= require_self+ */++pre {+ border: none;+ border-radius: 0;+}++body {+ padding-top: 20px;+ padding-bottom: 20px;+}++#results th {+ cursor: pointer;+}++#results thead {+ background-color: #fff;+}++input.search {+ border: none;+ box-shadow: none;+}++input.search:focus {+ outline: none;+ box-shadow: none;+}++.button_to {+ display: inline-block;+}++.button_to input:focus {+ outline: none;+}++.form-inline .selectize-control, .text-right .selectize-control {+ display: inline-block;+ vertical-align: middle;+ margin-left: 5px;+ margin-right: 20px;+ text-align: left;+}++#editor-container {+ background-color: #141414;+ padding-top: 10px;+ padding-bottom: 10px;+}++#editor {+ display: none;+ height: 100px;+}++.ace_print-margin-layer {+ display: none;+}diff --git a/app/assets/stylesheets/blazer/bootstrap.css b/app/assets/stylesheets/blazer/bootstrap.cssnew file mode 100644index 00000000..037dd056--- /dev/null+++ b/app/assets/stylesheets/blazer/bootstrap.css@@ -0,0 +1,6203 @@+/*!+ * Bootstrap v3.2.0 (http://getbootstrap.com)+ * Copyright 2011-2014 Twitter, Inc.+ * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)+ */++/*! normalize.css v3.0.1 | MIT License | git.io/normalize */+html {+ font-family: sans-serif;+ -webkit-text-size-adjust: 100%;+ -ms-text-size-adjust: 100%;+}+body {+ margin: 0;+}+article,+aside,+details,+figcaption,+figure,+footer,+header,+hgroup,+main,+nav,+section,+summary {+ display: block;+}+audio,+canvas,+progress,+video {+ display: inline-block;+ vertical-align: baseline;+}+audio:not([controls]) {+ display: none;+ height: 0;+}+[hidden],+template {+ display: none;+}+a {+ background: transparent;+}+a:active,+a:hover {+ outline: 0;+}+abbr[title] {+ border-bottom: 1px dotted;+}+b,+strong {+ font-weight: bold;+}+dfn {+ font-style: italic;+}+h1 {+ margin: .67em 0;+ font-size: 2em;+}+mark {+ color: #000;+ background: #ff0;+}+small {+ font-size: 80%;+}+sub,+sup {+ position: relative;+ font-size: 75%;+ line-height: 0;+ vertical-align: baseline;+}+sup {+ top: -.5em;+}+sub {+ bottom: -.25em;+}+img {+ border: 0;+}+svg:not(:root) {+ overflow: hidden;+}+figure {+ margin: 1em 40px;+}+hr {+ height: 0;+ -webkit-box-sizing: content-box;+ -moz-box-sizing: content-box;+ box-sizing: content-box;+}+pre {+ overflow: auto;+}+code,+kbd,+pre,+samp {+ font-family: monospace, monospace;+ font-size: 1em;+}+button,+input,+optgroup,+select,+textarea {+ margin: 0;+ font: inherit;+ color: inherit;+}+button {+ overflow: visible;+}+button,+select {+ text-transform: none;+}+button,+html input[type="button"],+input[type="reset"],+input[type="submit"] {+ -webkit-appearance: button;+ cursor: pointer;+}+button[disabled],+html input[disabled] {+ cursor: default;+}+button::-moz-focus-inner,+input::-moz-focus-inner {+ padding: 0;+ border: 0;+}+input {+ line-height: normal;+}+input[type="checkbox"],+input[type="radio"] {+ -webkit-box-sizing: border-box;+ -moz-box-sizing: border-box;+ box-sizing: border-box;+ padding: 0;+}+input[type="number"]::-webkit-inner-spin-button,+input[type="number"]::-webkit-outer-spin-button {+ height: auto;+}+input[type="search"] {+ -webkit-box-sizing: content-box;+ -moz-box-sizing: content-box;+ box-sizing: content-box;+ -webkit-appearance: textfield;+}+input[type="search"]::-webkit-search-cancel-button,+input[type="search"]::-webkit-search-decoration {+ -webkit-appearance: none;+}+fieldset {+ padding: .35em .625em .75em;+ margin: 0 2px;+ border: 1px solid #c0c0c0;+}+legend {+ padding: 0;+ border: 0;+}+textarea {+ overflow: auto;+}+optgroup {+ font-weight: bold;+}+table {+ border-spacing: 0;+ border-collapse: collapse;+}+td,+th {+ padding: 0;+}+@media print {+ * {+ color: #000 !important;+ text-shadow: none !important;+ background: transparent !important;+ -webkit-box-shadow: none !important;+ box-shadow: none !important;+ }+ a,+ a:visited {+ text-decoration: underline;+ }+ a[href]:after {+ content: " (" attr(href) ")";+ }+ abbr[title]:after {+ content: " (" attr(title) ")";+ }+ a[href^="javascript:"]:after,+ a[href^="#"]:after {+ content: "";+ }+ pre,+ blockquote {+ border: 1px solid #999;++ page-break-inside: avoid;+ }+ thead {+ display: table-header-group;+ }+ tr,+ img {+ page-break-inside: avoid;+ }+ img {+ max-width: 100% !important;+ }+ p,+ h2,+ h3 {+ orphans: 3;+ widows: 3;+ }+ h2,+ h3 {+ page-break-after: avoid;+ }+ select {+ background: #fff !important;+ }+ .navbar {+ display: none;+ }+ .table td,+ .table th {+ background-color: #fff !important;+ }+ .btn > .caret,+ .dropup > .btn > .caret {+ border-top-color: #000 !important;+ }+ .label {+ border: 1px solid #000;+ }+ .table {+ border-collapse: collapse !important;+ }+ .table-bordered th,+ .table-bordered td {+ border: 1px solid #ddd !important;+ }+}+@font-face {+ font-family: 'Glyphicons Halflings';++ src: url('../fonts/glyphicons-halflings-regular.eot');+ src: url('../fonts/glyphicons-halflings-regular.eot?#iefix') format('embedded-opentype'), url('../fonts/glyphicons-halflings-regular.woff') format('woff'), url('../fonts/glyphicons-halflings-regular.ttf') format('truetype'), url('../fonts/glyphicons-halflings-regular.svg#glyphicons_halflingsregular') format('svg');+}+.glyphicon {+ position: relative;+ top: 1px;+ display: inline-block;+ font-family: 'Glyphicons Halflings';+ font-style: normal;+ font-weight: normal;+ line-height: 1;++ -webkit-font-smoothing: antialiased;+ -moz-osx-font-smoothing: grayscale;+}+.glyphicon-asterisk:before {+ content: "\2a";+}+.glyphicon-plus:before {+ content: "\2b";+}+.glyphicon-euro:before {+ content: "\20ac";+}+.glyphicon-minus:before {+ content: "\2212";+}+.glyphicon-cloud:before {+ content: "\2601";+}+.glyphicon-envelope:before {+ content: "\2709";+}+.glyphicon-pencil:before {+ content: "\270f";+}+.glyphicon-glass:before {+ content: "\e001";+}+.glyphicon-music:before {+ content: "\e002";+}+.glyphicon-search:before {+ content: "\e003";+}+.glyphicon-heart:before {+ content: "\e005";+}+.glyphicon-star:before {+ content: "\e006";+}+.glyphicon-star-empty:before {+ content: "\e007";+}+.glyphicon-user:before {+ content: "\e008";+}+.glyphicon-film:before {+ content: "\e009";+}+.glyphicon-th-large:before {+ content: "\e010";+}+.glyphicon-th:before {+ content: "\e011";+}+.glyphicon-th-list:before {+ content: "\e012";+}+.glyphicon-ok:before {+ content: "\e013";+}+.glyphicon-remove:before {+ content: "\e014";+}+.glyphicon-zoom-in:before {+ content: "\e015";+}+.glyphicon-zoom-out:before {+ content: "\e016";+}+.glyphicon-off:before {+ content: "\e017";+}+.glyphicon-signal:before {+ content: "\e018";+}+.glyphicon-cog:before {+ content: "\e019";+}+.glyphicon-trash:before {+ content: "\e020";+}+.glyphicon-home:before {+ content: "\e021";+}+.glyphicon-file:before {+ content: "\e022";+}+.glyphicon-time:before {+ content: "\e023";+}+.glyphicon-road:before {+ content: "\e024";+}+.glyphicon-download-alt:before {+ content: "\e025";+}+.glyphicon-download:before {+ content: "\e026";+}+.glyphicon-upload:before {+ content: "\e027";+}+.glyphicon-inbox:before {+ content: "\e028";+}+.glyphicon-play-circle:before {+ content: "\e029";+}+.glyphicon-repeat:before {+ content: "\e030";+}+.glyphicon-refresh:before {+ content: "\e031";+}+.glyphicon-list-alt:before {+ content: "\e032";+}+.glyphicon-lock:before {+ content: "\e033";+}+.glyphicon-flag:before {+ content: "\e034";+}+.glyphicon-headphones:before {+ content: "\e035";+}+.glyphicon-volume-off:before {+ content: "\e036";+}+.glyphicon-volume-down:before {+ content: "\e037";+}+.glyphicon-volume-up:before {+ content: "\e038";+}+.glyphicon-qrcode:before {+ content: "\e039";+}+.glyphicon-barcode:before {+ content: "\e040";+}+.glyphicon-tag:before {+ content: "\e041";+}+.glyphicon-tags:before {+ content: "\e042";+}+.glyphicon-book:before {+ content: "\e043";+}+.glyphicon-bookmark:before {+ content: "\e044";+}+.glyphicon-print:before {+ content: "\e045";+}+.glyphicon-camera:before {+ content: "\e046";+}+.glyphicon-font:before {+ content: "\e047";+}+.glyphicon-bold:before {+ content: "\e048";+}+.glyphicon-italic:before {+ content: "\e049";+}+.glyphicon-text-height:before {+ content: "\e050";+}+.glyphicon-text-width:before {+ content: "\e051";+}+.glyphicon-align-left:before {+ content: "\e052";+}+.glyphicon-align-center:before {+ content: "\e053";+}+.glyphicon-align-right:before {+ content: "\e054";+}+.glyphicon-align-justify:before {+ content: "\e055";+}+.glyphicon-list:before {+ content: "\e056";+}+.glyphicon-indent-left:before {+ content: "\e057";+}+.glyphicon-indent-right:before {+ content: "\e058";+}+.glyphicon-facetime-video:before {+ content: "\e059";+}+.glyphicon-picture:before {+ content: "\e060";+}+.glyphicon-map-marker:before {+ content: "\e062";+}+.glyphicon-adjust:before {+ content: "\e063";+}+.glyphicon-tint:before {+ content: "\e064";+}+.glyphicon-edit:before {+ content: "\e065";+}+.glyphicon-share:before {+ content: "\e066";+}+.glyphicon-check:before {+ content: "\e067";+}+.glyphicon-move:before {+ content: "\e068";+}+.glyphicon-step-backward:before {+ content: "\e069";+}+.glyphicon-fast-backward:before {+ content: "\e070";+}+.glyphicon-backward:before {+ content: "\e071";+}+.glyphicon-play:before {+ content: "\e072";+}+.glyphicon-pause:before {+ content: "\e073";+}+.glyphicon-stop:before {+ content: "\e074";+}+.glyphicon-forward:before {+ content: "\e075";+}+.glyphicon-fast-forward:before {+ content: "\e076";+}+.glyphicon-step-forward:before {+ content: "\e077";+}+.glyphicon-eject:before {+ content: "\e078";+}+.glyphicon-chevron-left:before {+ content: "\e079";+}+.glyphicon-chevron-right:before {+ content: "\e080";+}+.glyphicon-plus-sign:before {+ content: "\e081";+}+.glyphicon-minus-sign:before {+ content: "\e082";+}+.glyphicon-remove-sign:before {+ content: "\e083";+}+.glyphicon-ok-sign:before {+ content: "\e084";+}+.glyphicon-question-sign:before {+ content: "\e085";+}+.glyphicon-info-sign:before {+ content: "\e086";+}+.glyphicon-screenshot:before {+ content: "\e087";+}+.glyphicon-remove-circle:before {+ content: "\e088";+}+.glyphicon-ok-circle:before {+ content: "\e089";+}+.glyphicon-ban-circle:before {+ content: "\e090";+}+.glyphicon-arrow-left:before {+ content: "\e091";+}+.glyphicon-arrow-right:before {+ content: "\e092";+}+.glyphicon-arrow-up:before {+ content: "\e093";+}+.glyphicon-arrow-down:before {+ content: "\e094";+}+.glyphicon-share-alt:before {+ content: "\e095";+}+.glyphicon-resize-full:before {+ content: "\e096";+}+.glyphicon-resize-small:before {+ content: "\e097";+}+.glyphicon-exclamation-sign:before {+ content: "\e101";+}+.glyphicon-gift:before {+ content: "\e102";+}+.glyphicon-leaf:before {+ content: "\e103";+}+.glyphicon-fire:before {+ content: "\e104";+}+.glyphicon-eye-open:before {+ content: "\e105";+}+.glyphicon-eye-close:before {+ content: "\e106";+}+.glyphicon-warning-sign:before {+ content: "\e107";+}+.glyphicon-plane:before {+ content: "\e108";+}+.glyphicon-calendar:before {+ content: "\e109";+}+.glyphicon-random:before {+ content: "\e110";+}+.glyphicon-comment:before {+ content: "\e111";+}+.glyphicon-magnet:before {+ content: "\e112";+}+.glyphicon-chevron-up:before {+ content: "\e113";+}+.glyphicon-chevron-down:before {+ content: "\e114";+}+.glyphicon-retweet:before {+ content: "\e115";+}+.glyphicon-shopping-cart:before {+ content: "\e116";+}+.glyphicon-folder-close:before {+ content: "\e117";+}+.glyphicon-folder-open:before {+ content: "\e118";+}+.glyphicon-resize-vertical:before {+ content: "\e119";+}+.glyphicon-resize-horizontal:before {+ content: "\e120";+}+.glyphicon-hdd:before {+ content: "\e121";+}+.glyphicon-bullhorn:before {+ content: "\e122";+}+.glyphicon-bell:before {+ content: "\e123";+}+.glyphicon-certificate:before {+ content: "\e124";+}+.glyphicon-thumbs-up:before {+ content: "\e125";+}+.glyphicon-thumbs-down:before {+ content: "\e126";+}+.glyphicon-hand-right:before {+ content: "\e127";+}+.glyphicon-hand-left:before {+ content: "\e128";+}+.glyphicon-hand-up:before {+ content: "\e129";+}+.glyphicon-hand-down:before {+ content: "\e130";+}+.glyphicon-circle-arrow-right:before {+ content: "\e131";+}+.glyphicon-circle-arrow-left:before {+ content: "\e132";+}+.glyphicon-circle-arrow-up:before {+ content: "\e133";+}+.glyphicon-circle-arrow-down:before {+ content: "\e134";+}+.glyphicon-globe:before {+ content: "\e135";+}+.glyphicon-wrench:before {+ content: "\e136";+}+.glyphicon-tasks:before {+ content: "\e137";+}+.glyphicon-filter:before {+ content: "\e138";+}+.glyphicon-briefcase:before {+ content: "\e139";+}+.glyphicon-fullscreen:before {+ content: "\e140";+}+.glyphicon-dashboard:before {+ content: "\e141";+}+.glyphicon-paperclip:before {+ content: "\e142";+}+.glyphicon-heart-empty:before {+ content: "\e143";+}+.glyphicon-link:before {+ content: "\e144";+}+.glyphicon-phone:before {+ content: "\e145";+}+.glyphicon-pushpin:before {+ content: "\e146";+}+.glyphicon-usd:before {+ content: "\e148";+}+.glyphicon-gbp:before {+ content: "\e149";+}+.glyphicon-sort:before {+ content: "\e150";+}+.glyphicon-sort-by-alphabet:before {+ content: "\e151";+}+.glyphicon-sort-by-alphabet-alt:before {+ content: "\e152";+}+.glyphicon-sort-by-order:before {+ content: "\e153";+}+.glyphicon-sort-by-order-alt:before {+ content: "\e154";+}+.glyphicon-sort-by-attributes:before {+ content: "\e155";+}+.glyphicon-sort-by-attributes-alt:before {+ content: "\e156";+}+.glyphicon-unchecked:before {+ content: "\e157";+}+.glyphicon-expand:before {+ content: "\e158";+}+.glyphicon-collapse-down:before {+ content: "\e159";+}+.glyphicon-collapse-up:before {+ content: "\e160";+}+.glyphicon-log-in:before {+ content: "\e161";+}+.glyphicon-flash:before {+ content: "\e162";+}+.glyphicon-log-out:before {+ content: "\e163";+}+.glyphicon-new-window:before {+ content: "\e164";+}+.glyphicon-record:before {+ content: "\e165";+}+.glyphicon-save:before {+ content: "\e166";+}+.glyphicon-open:before {+ content: "\e167";+}+.glyphicon-saved:before {+ content: "\e168";+}+.glyphicon-import:before {+ content: "\e169";+}+.glyphicon-export:before {+ content: "\e170";+}+.glyphicon-send:before {+ content: "\e171";+}+.glyphicon-floppy-disk:before {+ content: "\e172";+}+.glyphicon-floppy-saved:before {+ content: "\e173";+}+.glyphicon-floppy-remove:before {+ content: "\e174";+}+.glyphicon-floppy-save:before {+ content: "\e175";+}+.glyphicon-floppy-open:before {+ content: "\e176";+}+.glyphicon-credit-card:before {+ content: "\e177";+}+.glyphicon-transfer:before {+ content: "\e178";+}+.glyphicon-cutlery:before {+ content: "\e179";+}+.glyphicon-header:before {+ content: "\e180";+}+.glyphicon-compressed:before {+ content: "\e181";+}+.glyphicon-earphone:before {+ content: "\e182";+}+.glyphicon-phone-alt:before {+ content: "\e183";+}+.glyphicon-tower:before {+ content: "\e184";+}+.glyphicon-stats:before {+ content: "\e185";+}+.glyphicon-sd-video:before {+ content: "\e186";+}+.glyphicon-hd-video:before {+ content: "\e187";+}+.glyphicon-subtitles:before {+ content: "\e188";+}+.glyphicon-sound-stereo:before {+ content: "\e189";+}+.glyphicon-sound-dolby:before {+ content: "\e190";+}+.glyphicon-sound-5-1:before {+ content: "\e191";+}+.glyphicon-sound-6-1:before {+ content: "\e192";+}+.glyphicon-sound-7-1:before {+ content: "\e193";+}+.glyphicon-copyright-mark:before {+ content: "\e194";+}+.glyphicon-registration-mark:before {+ content: "\e195";+}+.glyphicon-cloud-download:before {+ content: "\e197";+}+.glyphicon-cloud-upload:before {+ content: "\e198";+}+.glyphicon-tree-conifer:before {+ content: "\e199";+}+.glyphicon-tree-deciduous:before {+ content: "\e200";+}+* {+ -webkit-box-sizing: border-box;+ -moz-box-sizing: border-box;+ box-sizing: border-box;+}+*:before,+*:after {+ -webkit-box-sizing: border-box;+ -moz-box-sizing: border-box;+ box-sizing: border-box;+}+html {+ font-size: 10px;++ -webkit-tap-highlight-color: rgba(0, 0, 0, 0);+}+body {+ font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;+ font-size: 14px;+ line-height: 1.42857143;+ color: #333;+ background-color: #fff;+}+input,+button,+select,+textarea {+ font-family: inherit;+ font-size: inherit;+ line-height: inherit;+}+a {+ color: #428bca;+ text-decoration: none;+}+a:hover,+a:focus {+ color: #2a6496;+ text-decoration: underline;+}+a:focus {+ outline: thin dotted;+ outline: 5px auto -webkit-focus-ring-color;+ outline-offset: -2px;+}+figure {+ margin: 0;+}+img {+ vertical-align: middle;+}+.img-responsive,+.thumbnail > img,+.thumbnail a > img,+.carousel-inner > .item > img,+.carousel-inner > .item > a > img {+ display: block;+ width: 100% \9;+ max-width: 100%;+ height: auto;+}+.img-rounded {+ border-radius: 6px;+}+.img-thumbnail {+ display: inline-block;+ width: 100% \9;+ max-width: 100%;+ height: auto;+ padding: 4px;+ line-height: 1.42857143;+ background-color: #fff;+ border: 1px solid #ddd;+ border-radius: 4px;+ -webkit-transition: all .2s ease-in-out;+ -o-transition: all .2s ease-in-out;+ transition: all .2s ease-in-out;+}+.img-circle {+ border-radius: 50%;+}+hr {+ margin-top: 20px;+ margin-bottom: 20px;+ border: 0;+ border-top: 1px solid #eee;+}+.sr-only {+ position: absolute;+ width: 1px;+ height: 1px;+ padding: 0;+ margin: -1px;+ overflow: hidden;+ clip: rect(0, 0, 0, 0);+ border: 0;+}+.sr-only-focusable:active,+.sr-only-focusable:focus {+ position: static;+ width: auto;+ height: auto;+ margin: 0;+ overflow: visible;+ clip: auto;+}+h1,+h2,+h3,+h4,+h5,+h6,+.h1,+.h2,+.h3,+.h4,+.h5,+.h6 {+ font-family: inherit;+ font-weight: 500;+ line-height: 1.1;+ color: inherit;+}+h1 small,+h2 small,+h3 small,+h4 small,+h5 small,+h6 small,+.h1 small,+.h2 small,+.h3 small,+.h4 small,+.h5 small,+.h6 small,+h1 .small,+h2 .small,+h3 .small,+h4 .small,+h5 .small,+h6 .small,+.h1 .small,+.h2 .small,+.h3 .small,+.h4 .small,+.h5 .small,+.h6 .small {+ font-weight: normal;+ line-height: 1;+ color: #777;+}+h1,+.h1,+h2,+.h2,+h3,+.h3 {+ margin-top: 20px;+ margin-bottom: 10px;+}+h1 small,+.h1 small,+h2 small,+.h2 small,+h3 small,+.h3 small,+h1 .small,+.h1 .small,+h2 .small,+.h2 .small,+h3 .small,+.h3 .small {+ font-size: 65%;+}+h4,+.h4,+h5,+.h5,+h6,+.h6 {+ margin-top: 10px;+ margin-bottom: 10px;+}+h4 small,+.h4 small,+h5 small,+.h5 small,+h6 small,+.h6 small,+h4 .small,+.h4 .small,+h5 .small,+.h5 .small,+h6 .small,+.h6 .small {+ font-size: 75%;+}+h1,+.h1 {+ font-size: 36px;+}+h2,+.h2 {+ font-size: 30px;+}+h3,+.h3 {+ font-size: 24px;+}+h4,+.h4 {+ font-size: 18px;+}+h5,+.h5 {+ font-size: 14px;+}+h6,+.h6 {+ font-size: 12px;+}+p {+ margin: 0 0 10px;+}+.lead {+ margin-bottom: 20px;+ font-size: 16px;+ font-weight: 300;+ line-height: 1.4;+}+@media (min-width: 768px) {+ .lead {+ font-size: 21px;+ }+}+small,+.small {+ font-size: 85%;+}+cite {+ font-style: normal;+}+mark,+.mark {+ padding: .2em;+ background-color: #fcf8e3;+}+.text-left {+ text-align: left;+}+.text-right {+ text-align: right;+}+.text-center {+ text-align: center;+}+.text-justify {+ text-align: justify;+}+.text-nowrap {+ white-space: nowrap;+}+.text-lowercase {+ text-transform: lowercase;+}+.text-uppercase {+ text-transform: uppercase;+}+.text-capitalize {+ text-transform: capitalize;+}+.text-muted {+ color: #777;+}+.text-primary {+ color: #428bca;+}+a.text-primary:hover {+ color: #3071a9;+}+.text-success {+ color: #3c763d;+}+a.text-success:hover {+ color: #2b542c;+}+.text-info {+ color: #31708f;+}+a.text-info:hover {+ color: #245269;+}+.text-warning {+ color: #8a6d3b;+}+a.text-warning:hover {+ color: #66512c;+}+.text-danger {+ color: #a94442;+}+a.text-danger:hover {+ color: #843534;+}+.bg-primary {+ color: #fff;+ background-color: #428bca;+}+a.bg-primary:hover {+ background-color: #3071a9;+}+.bg-success {+ background-color: #dff0d8;+}+a.bg-success:hover {+ background-color: #c1e2b3;+}+.bg-info {+ background-color: #d9edf7;+}+a.bg-info:hover {+ background-color: #afd9ee;+}+.bg-warning {+ background-color: #fcf8e3;+}+a.bg-warning:hover {+ background-color: #f7ecb5;+}+.bg-danger {+ background-color: #f2dede;+}+a.bg-danger:hover {+ background-color: #e4b9b9;+}+.page-header {+ padding-bottom: 9px;+ margin: 40px 0 20px;+ border-bottom: 1px solid #eee;+}+ul,+ol {+ margin-top: 0;+ margin-bottom: 10px;+}+ul ul,+ol ul,+ul ol,+ol ol {+ margin-bottom: 0;+}+.list-unstyled {+ padding-left: 0;+ list-style: none;+}+.list-inline {+ padding-left: 0;+ margin-left: -5px;+ list-style: none;+}+.list-inline > li {+ display: inline-block;+ padding-right: 5px;+ padding-left: 5px;+}+dl {+ margin-top: 0;+ margin-bottom: 20px;+}+dt,+dd {+ line-height: 1.42857143;+}+dt {+ font-weight: bold;+}+dd {+ margin-left: 0;+}+@media (min-width: 768px) {+ .dl-horizontal dt {+ float: left;+ width: 160px;+ overflow: hidden;+ clear: left;+ text-align: right;+ text-overflow: ellipsis;+ white-space: nowrap;+ }+ .dl-horizontal dd {+ margin-left: 180px;+ }+}+abbr[title],+abbr[data-original-title] {+ cursor: help;+ border-bottom: 1px dotted #777;+}+.initialism {+ font-size: 90%;+ text-transform: uppercase;+}+blockquote {+ padding: 10px 20px;+ margin: 0 0 20px;+ font-size: 17.5px;+ border-left: 5px solid #eee;+}+blockquote p:last-child,+blockquote ul:last-child,+blockquote ol:last-child {+ margin-bottom: 0;+}+blockquote footer,+blockquote small,+blockquote .small {+ display: block;+ font-size: 80%;+ line-height: 1.42857143;+ color: #777;+}+blockquote footer:before,+blockquote small:before,+blockquote .small:before {+ content: '\2014 \00A0';+}+.blockquote-reverse,+blockquote.pull-right {+ padding-right: 15px;+ padding-left: 0;+ text-align: right;+ border-right: 5px solid #eee;+ border-left: 0;+}+.blockquote-reverse footer:before,+blockquote.pull-right footer:before,+.blockquote-reverse small:before,+blockquote.pull-right small:before,+.blockquote-reverse .small:before,+blockquote.pull-right .small:before {+ content: '';+}+.blockquote-reverse footer:after,+blockquote.pull-right footer:after,+.blockquote-reverse small:after,+blockquote.pull-right small:after,+.blockquote-reverse .small:after,+blockquote.pull-right .small:after {+ content: '\00A0 \2014';+}+blockquote:before,+blockquote:after {+ content: "";+}+address {+ margin-bottom: 20px;+ font-style: normal;+ line-height: 1.42857143;+}+code,+kbd,+pre,+samp {+ font-family: Menlo, Monaco, Consolas, "Courier New", monospace;+}+code {+ padding: 2px 4px;+ font-size: 90%;+ color: #c7254e;+ background-color: #f9f2f4;+ border-radius: 4px;+}+kbd {+ padding: 2px 4px;+ font-size: 90%;+ color: #fff;+ background-color: #333;+ border-radius: 3px;+ -webkit-box-shadow: inset 0 -1px 0 rgba(0, 0, 0, .25);+ box-shadow: inset 0 -1px 0 rgba(0, 0, 0, .25);+}+kbd kbd {+ padding: 0;+ font-size: 100%;+ -webkit-box-shadow: none;+ box-shadow: none;+}+pre {+ display: block;+ padding: 9.5px;+ margin: 0 0 10px;+ font-size: 13px;+ line-height: 1.42857143;+ color: #333;+ word-break: break-all;+ word-wrap: break-word;+ background-color: #f5f5f5;+ border: 1px solid #ccc;+ border-radius: 4px;+}+pre code {+ padding: 0;+ font-size: inherit;+ color: inherit;+ white-space: pre-wrap;+ background-color: transparent;+ border-radius: 0;+}+.pre-scrollable {+ max-height: 340px;+ overflow-y: scroll;+}+.container {+ padding-right: 15px;+ padding-left: 15px;+ margin-right: auto;+ margin-left: auto;+}+@media (min-width: 768px) {+ .container {+ width: 750px;+ }+}+@media (min-width: 992px) {+ .container {+ width: 970px;+ }+}+@media (min-width: 1200px) {+ .container {+ width: 1170px;+ }+}+.container-fluid {+ padding-right: 15px;+ padding-left: 15px;+ margin-right: auto;+ margin-left: auto;+}+.row {+ margin-right: -15px;+ margin-left: -15px;+}+.col-xs-1, .col-sm-1, .col-md-1, .col-lg-1, .col-xs-2, .col-sm-2, .col-md-2, .col-lg-2, .col-xs-3, .col-sm-3, .col-md-3, .col-lg-3, .col-xs-4, .col-sm-4, .col-md-4, .col-lg-4, .col-xs-5, .col-sm-5, .col-md-5, .col-lg-5, .col-xs-6, .col-sm-6, .col-md-6, .col-lg-6, .col-xs-7, .col-sm-7, .col-md-7, .col-lg-7, .col-xs-8, .col-sm-8, .col-md-8, .col-lg-8, .col-xs-9, .col-sm-9, .col-md-9, .col-lg-9, .col-xs-10, .col-sm-10, .col-md-10, .col-lg-10, .col-xs-11, .col-sm-11, .col-md-11, .col-lg-11, .col-xs-12, .col-sm-12, .col-md-12, .col-lg-12 {+ position: relative;+ min-height: 1px;+ padding-right: 15px;+ padding-left: 15px;+}+.col-xs-1, .col-xs-2, .col-xs-3, .col-xs-4, .col-xs-5, .col-xs-6, .col-xs-7, .col-xs-8, .col-xs-9, .col-xs-10, .col-xs-11, .col-xs-12 {+ float: left;+}+.col-xs-12 {+ width: 100%;+}+.col-xs-11 {+ width: 91.66666667%;+}+.col-xs-10 {+ width: 83.33333333%;+}+.col-xs-9 {+ width: 75%;+}+.col-xs-8 {+ width: 66.66666667%;+}+.col-xs-7 {+ width: 58.33333333%;+}+.col-xs-6 {+ width: 50%;+}+.col-xs-5 {+ width: 41.66666667%;+}+.col-xs-4 {+ width: 33.33333333%;+}+.col-xs-3 {+ width: 25%;+}+.col-xs-2 {+ width: 16.66666667%;+}+.col-xs-1 {+ width: 8.33333333%;+}+.col-xs-pull-12 {+ right: 100%;+}+.col-xs-pull-11 {+ right: 91.66666667%;+}+.col-xs-pull-10 {+ right: 83.33333333%;+}+.col-xs-pull-9 {+ right: 75%;+}+.col-xs-pull-8 {+ right: 66.66666667%;+}+.col-xs-pull-7 {+ right: 58.33333333%;+}+.col-xs-pull-6 {+ right: 50%;+}+.col-xs-pull-5 {+ right: 41.66666667%;+}+.col-xs-pull-4 {+ right: 33.33333333%;+}+.col-xs-pull-3 {+ right: 25%;+}+.col-xs-pull-2 {+ right: 16.66666667%;+}+.col-xs-pull-1 {+ right: 8.33333333%;+}+.col-xs-pull-0 {+ right: auto;+}+.col-xs-push-12 {+ left: 100%;+}+.col-xs-push-11 {+ left: 91.66666667%;+}+.col-xs-push-10 {+ left: 83.33333333%;+}+.col-xs-push-9 {+ left: 75%;+}+.col-xs-push-8 {+ left: 66.66666667%;+}+.col-xs-push-7 {+ left: 58.33333333%;+}+.col-xs-push-6 {+ left: 50%;+}+.col-xs-push-5 {+ left: 41.66666667%;+}+.col-xs-push-4 {+ left: 33.33333333%;+}+.col-xs-push-3 {+ left: 25%;+}+.col-xs-push-2 {+ left: 16.66666667%;+}+.col-xs-push-1 {+ left: 8.33333333%;+}+.col-xs-push-0 {+ left: auto;+}+.col-xs-offset-12 {+ margin-left: 100%;+}+.col-xs-offset-11 {+ margin-left: 91.66666667%;+}+.col-xs-offset-10 {+ margin-left: 83.33333333%;+}+.col-xs-offset-9 {+ margin-left: 75%;+}+.col-xs-offset-8 {+ margin-left: 66.66666667%;+}+.col-xs-offset-7 {+ margin-left: 58.33333333%;+}+.col-xs-offset-6 {+ margin-left: 50%;+}+.col-xs-offset-5 {+ margin-left: 41.66666667%;+}+.col-xs-offset-4 {+ margin-left: 33.33333333%;+}+.col-xs-offset-3 {+ margin-left: 25%;+}+.col-xs-offset-2 {+ margin-left: 16.66666667%;+}+.col-xs-offset-1 {+ margin-left: 8.33333333%;+}+.col-xs-offset-0 {+ margin-left: 0;+}+@media (min-width: 768px) {+ .col-sm-1, .col-sm-2, .col-sm-3, .col-sm-4, .col-sm-5, .col-sm-6, .col-sm-7, .col-sm-8, .col-sm-9, .col-sm-10, .col-sm-11, .col-sm-12 {+ float: left;+ }+ .col-sm-12 {+ width: 100%;+ }+ .col-sm-11 {+ width: 91.66666667%;+ }+ .col-sm-10 {+ width: 83.33333333%;+ }+ .col-sm-9 {+ width: 75%;+ }+ .col-sm-8 {+ width: 66.66666667%;+ }+ .col-sm-7 {+ width: 58.33333333%;+ }+ .col-sm-6 {+ width: 50%;+ }+ .col-sm-5 {+ width: 41.66666667%;+ }+ .col-sm-4 {+ width: 33.33333333%;+ }+ .col-sm-3 {+ width: 25%;+ }+ .col-sm-2 {+ width: 16.66666667%;+ }+ .col-sm-1 {+ width: 8.33333333%;+ }+ .col-sm-pull-12 {+ right: 100%;+ }+ .col-sm-pull-11 {+ right: 91.66666667%;+ }+ .col-sm-pull-10 {+ right: 83.33333333%;+ }+ .col-sm-pull-9 {+ right: 75%;+ }+ .col-sm-pull-8 {+ right: 66.66666667%;+ }+ .col-sm-pull-7 {+ right: 58.33333333%;+ }+ .col-sm-pull-6 {+ right: 50%;+ }+ .col-sm-pull-5 {+ right: 41.66666667%;+ }+ .col-sm-pull-4 {+ right: 33.33333333%;+ }+ .col-sm-pull-3 {+ right: 25%;+ }+ .col-sm-pull-2 {+ right: 16.66666667%;+ }+ .col-sm-pull-1 {+ right: 8.33333333%;+ }+ .col-sm-pull-0 {+ right: auto;+ }+ .col-sm-push-12 {+ left: 100%;+ }+ .col-sm-push-11 {+ left: 91.66666667%;+ }+ .col-sm-push-10 {+ left: 83.33333333%;+ }+ .col-sm-push-9 {+ left: 75%;+ }+ .col-sm-push-8 {+ left: 66.66666667%;+ }+ .col-sm-push-7 {+ left: 58.33333333%;+ }+ .col-sm-push-6 {+ left: 50%;+ }+ .col-sm-push-5 {+ left: 41.66666667%;+ }+ .col-sm-push-4 {+ left: 33.33333333%;+ }+ .col-sm-push-3 {+ left: 25%;+ }+ .col-sm-push-2 {+ left: 16.66666667%;+ }+ .col-sm-push-1 {+ left: 8.33333333%;+ }+ .col-sm-push-0 {+ left: auto;+ }+ .col-sm-offset-12 {+ margin-left: 100%;+ }+ .col-sm-offset-11 {+ margin-left: 91.66666667%;+ }+ .col-sm-offset-10 {+ margin-left: 83.33333333%;+ }+ .col-sm-offset-9 {+ margin-left: 75%;+ }+ .col-sm-offset-8 {+ margin-left: 66.66666667%;+ }+ .col-sm-offset-7 {+ margin-left: 58.33333333%;+ }+ .col-sm-offset-6 {+ margin-left: 50%;+ }+ .col-sm-offset-5 {+ margin-left: 41.66666667%;+ }+ .col-sm-offset-4 {+ margin-left: 33.33333333%;+ }+ .col-sm-offset-3 {+ margin-left: 25%;+ }+ .col-sm-offset-2 {+ margin-left: 16.66666667%;+ }+ .col-sm-offset-1 {+ margin-left: 8.33333333%;+ }+ .col-sm-offset-0 {+ margin-left: 0;+ }+}+@media (min-width: 992px) {+ .col-md-1, .col-md-2, .col-md-3, .col-md-4, .col-md-5, .col-md-6, .col-md-7, .col-md-8, .col-md-9, .col-md-10, .col-md-11, .col-md-12 {+ float: left;+ }+ .col-md-12 {+ width: 100%;+ }+ .col-md-11 {+ width: 91.66666667%;+ }+ .col-md-10 {+ width: 83.33333333%;+ }+ .col-md-9 {+ width: 75%;+ }+ .col-md-8 {+ width: 66.66666667%;+ }+ .col-md-7 {+ width: 58.33333333%;+ }+ .col-md-6 {+ width: 50%;+ }+ .col-md-5 {+ width: 41.66666667%;+ }+ .col-md-4 {+ width: 33.33333333%;+ }+ .col-md-3 {+ width: 25%;+ }+ .col-md-2 {+ width: 16.66666667%;+ }+ .col-md-1 {+ width: 8.33333333%;+ }+ .col-md-pull-12 {+ right: 100%;+ }+ .col-md-pull-11 {+ right: 91.66666667%;+ }+ .col-md-pull-10 {+ right: 83.33333333%;+ }+ .col-md-pull-9 {+ right: 75%;+ }+ .col-md-pull-8 {+ right: 66.66666667%;+ }+ .col-md-pull-7 {+ right: 58.33333333%;+ }+ .col-md-pull-6 {+ right: 50%;+ }+ .col-md-pull-5 {+ right: 41.66666667%;+ }+ .col-md-pull-4 {+ right: 33.33333333%;+ }+ .col-md-pull-3 {+ right: 25%;+ }+ .col-md-pull-2 {+ right: 16.66666667%;+ }+ .col-md-pull-1 {+ right: 8.33333333%;+ }+ .col-md-pull-0 {+ right: auto;+ }+ .col-md-push-12 {+ left: 100%;+ }+ .col-md-push-11 {+ left: 91.66666667%;+ }+ .col-md-push-10 {+ left: 83.33333333%;+ }+ .col-md-push-9 {+ left: 75%;+ }+ .col-md-push-8 {+ left: 66.66666667%;+ }+ .col-md-push-7 {+ left: 58.33333333%;+ }+ .col-md-push-6 {+ left: 50%;+ }+ .col-md-push-5 {+ left: 41.66666667%;+ }+ .col-md-push-4 {+ left: 33.33333333%;+ }+ .col-md-push-3 {+ left: 25%;+ }+ .col-md-push-2 {+ left: 16.66666667%;+ }+ .col-md-push-1 {+ left: 8.33333333%;+ }+ .col-md-push-0 {+ left: auto;+ }+ .col-md-offset-12 {+ margin-left: 100%;+ }+ .col-md-offset-11 {+ margin-left: 91.66666667%;+ }+ .col-md-offset-10 {+ margin-left: 83.33333333%;+ }+ .col-md-offset-9 {+ margin-left: 75%;+ }+ .col-md-offset-8 {+ margin-left: 66.66666667%;+ }+ .col-md-offset-7 {+ margin-left: 58.33333333%;+ }+ .col-md-offset-6 {+ margin-left: 50%;+ }+ .col-md-offset-5 {+ margin-left: 41.66666667%;+ }+ .col-md-offset-4 {+ margin-left: 33.33333333%;+ }+ .col-md-offset-3 {+ margin-left: 25%;+ }+ .col-md-offset-2 {+ margin-left: 16.66666667%;+ }+ .col-md-offset-1 {+ margin-left: 8.33333333%;+ }+ .col-md-offset-0 {+ margin-left: 0;+ }+}+@media (min-width: 1200px) {+ .col-lg-1, .col-lg-2, .col-lg-3, .col-lg-4, .col-lg-5, .col-lg-6, .col-lg-7, .col-lg-8, .col-lg-9, .col-lg-10, .col-lg-11, .col-lg-12 {+ float: left;+ }+ .col-lg-12 {+ width: 100%;+ }+ .col-lg-11 {+ width: 91.66666667%;+ }+ .col-lg-10 {+ width: 83.33333333%;+ }+ .col-lg-9 {+ width: 75%;+ }+ .col-lg-8 {+ width: 66.66666667%;+ }+ .col-lg-7 {+ width: 58.33333333%;+ }+ .col-lg-6 {+ width: 50%;+ }+ .col-lg-5 {+ width: 41.66666667%;+ }+ .col-lg-4 {+ width: 33.33333333%;+ }+ .col-lg-3 {+ width: 25%;+ }+ .col-lg-2 {+ width: 16.66666667%;+ }+ .col-lg-1 {+ width: 8.33333333%;+ }+ .col-lg-pull-12 {+ right: 100%;+ }+ .col-lg-pull-11 {+ right: 91.66666667%;+ }+ .col-lg-pull-10 {+ right: 83.33333333%;+ }+ .col-lg-pull-9 {+ right: 75%;+ }+ .col-lg-pull-8 {+ right: 66.66666667%;+ }+ .col-lg-pull-7 {+ right: 58.33333333%;+ }+ .col-lg-pull-6 {+ right: 50%;+ }+ .col-lg-pull-5 {+ right: 41.66666667%;+ }+ .col-lg-pull-4 {+ right: 33.33333333%;+ }+ .col-lg-pull-3 {+ right: 25%;+ }+ .col-lg-pull-2 {+ right: 16.66666667%;+ }+ .col-lg-pull-1 {+ right: 8.33333333%;+ }+ .col-lg-pull-0 {+ right: auto;+ }+ .col-lg-push-12 {+ left: 100%;+ }+ .col-lg-push-11 {+ left: 91.66666667%;+ }+ .col-lg-push-10 {+ left: 83.33333333%;+ }+ .col-lg-push-9 {+ left: 75%;+ }+ .col-lg-push-8 {+ left: 66.66666667%;+ }+ .col-lg-push-7 {+ left: 58.33333333%;+ }+ .col-lg-push-6 {+ left: 50%;+ }+ .col-lg-push-5 {+ left: 41.66666667%;+ }+ .col-lg-push-4 {+ left: 33.33333333%;+ }+ .col-lg-push-3 {+ left: 25%;+ }+ .col-lg-push-2 {+ left: 16.66666667%;+ }+ .col-lg-push-1 {+ left: 8.33333333%;+ }+ .col-lg-push-0 {+ left: auto;+ }+ .col-lg-offset-12 {+ margin-left: 100%;+ }+ .col-lg-offset-11 {+ margin-left: 91.66666667%;+ }+ .col-lg-offset-10 {+ margin-left: 83.33333333%;+ }+ .col-lg-offset-9 {+ margin-left: 75%;+ }+ .col-lg-offset-8 {+ margin-left: 66.66666667%;+ }+ .col-lg-offset-7 {+ margin-left: 58.33333333%;+ }+ .col-lg-offset-6 {+ margin-left: 50%;+ }+ .col-lg-offset-5 {+ margin-left: 41.66666667%;+ }+ .col-lg-offset-4 {+ margin-left: 33.33333333%;+ }+ .col-lg-offset-3 {+ margin-left: 25%;+ }+ .col-lg-offset-2 {+ margin-left: 16.66666667%;+ }+ .col-lg-offset-1 {+ margin-left: 8.33333333%;+ }+ .col-lg-offset-0 {+ margin-left: 0;+ }+}+table {+ background-color: transparent;+}+th {+ text-align: left;+}+.table {+ width: 100%;+ max-width: 100%;+ margin-bottom: 20px;+}+.table > thead > tr > th,+.table > tbody > tr > th,+.table > tfoot > tr > th,+.table > thead > tr > td,+.table > tbody > tr > td,+.table > tfoot > tr > td {+ padding: 8px;+ line-height: 1.42857143;+ vertical-align: top;+ border-top: 1px solid #ddd;+}+.table > thead > tr > th {+ vertical-align: bottom;+ border-bottom: 2px solid #ddd;+}+.table > caption + thead > tr:first-child > th,+.table > colgroup + thead > tr:first-child > th,+.table > thead:first-child > tr:first-child > th,+.table > caption + thead > tr:first-child > td,+.table > colgroup + thead > tr:first-child > td,+.table > thead:first-child > tr:first-child > td {+ border-top: 0;+}+.table > tbody + tbody {+ border-top: 2px solid #ddd;+}+.table .table {+ background-color: #fff;+}+.table-condensed > thead > tr > th,+.table-condensed > tbody > tr > th,+.table-condensed > tfoot > tr > th,+.table-condensed > thead > tr > td,+.table-condensed > tbody > tr > td,+.table-condensed > tfoot > tr > td {+ padding: 5px;+}+.table-bordered {+ border: 1px solid #ddd;+}+.table-bordered > thead > tr > th,+.table-bordered > tbody > tr > th,+.table-bordered > tfoot > tr > th,+.table-bordered > thead > tr > td,+.table-bordered > tbody > tr > td,+.table-bordered > tfoot > tr > td {+ border: 1px solid #ddd;+}+.table-bordered > thead > tr > th,+.table-bordered > thead > tr > td {+ border-bottom-width: 2px;+}+.table-striped > tbody > tr:nth-child(odd) > td,+.table-striped > tbody > tr:nth-child(odd) > th {+ background-color: #f9f9f9;+}+.table-hover > tbody > tr:hover > td,+.table-hover > tbody > tr:hover > th {+ background-color: #f5f5f5;+}+table col[class*="col-"] {+ position: static;+ display: table-column;+ float: none;+}+table td[class*="col-"],+table th[class*="col-"] {+ position: static;+ display: table-cell;+ float: none;+}+.table > thead > tr > td.active,+.table > tbody > tr > td.active,+.table > tfoot > tr > td.active,+.table > thead > tr > th.active,+.table > tbody > tr > th.active,+.table > tfoot > tr > th.active,+.table > thead > tr.active > td,+.table > tbody > tr.active > td,+.table > tfoot > tr.active > td,+.table > thead > tr.active > th,+.table > tbody > tr.active > th,+.table > tfoot > tr.active > th {+ background-color: #f5f5f5;+}+.table-hover > tbody > tr > td.active:hover,+.table-hover > tbody > tr > th.active:hover,+.table-hover > tbody > tr.active:hover > td,+.table-hover > tbody > tr:hover > .active,+.table-hover > tbody > tr.active:hover > th {+ background-color: #e8e8e8;+}+.table > thead > tr > td.success,+.table > tbody > tr > td.success,+.table > tfoot > tr > td.success,+.table > thead > tr > th.success,+.table > tbody > tr > th.success,+.table > tfoot > tr > th.success,+.table > thead > tr.success > td,+.table > tbody > tr.success > td,+.table > tfoot > tr.success > td,+.table > thead > tr.success > th,+.table > tbody > tr.success > th,+.table > tfoot > tr.success > th {+ background-color: #dff0d8;+}+.table-hover > tbody > tr > td.success:hover,+.table-hover > tbody > tr > th.success:hover,+.table-hover > tbody > tr.success:hover > td,+.table-hover > tbody > tr:hover > .success,+.table-hover > tbody > tr.success:hover > th {+ background-color: #d0e9c6;+}+.table > thead > tr > td.info,+.table > tbody > tr > td.info,+.table > tfoot > tr > td.info,+.table > thead > tr > th.info,+.table > tbody > tr > th.info,+.table > tfoot > tr > th.info,+.table > thead > tr.info > td,+.table > tbody > tr.info > td,+.table > tfoot > tr.info > td,+.table > thead > tr.info > th,+.table > tbody > tr.info > th,+.table > tfoot > tr.info > th {+ background-color: #d9edf7;+}+.table-hover > tbody > tr > td.info:hover,+.table-hover > tbody > tr > th.info:hover,+.table-hover > tbody > tr.info:hover > td,+.table-hover > tbody > tr:hover > .info,+.table-hover > tbody > tr.info:hover > th {+ background-color: #c4e3f3;+}+.table > thead > tr > td.warning,+.table > tbody > tr > td.warning,+.table > tfoot > tr > td.warning,+.table > thead > tr > th.warning,+.table > tbody > tr > th.warning,+.table > tfoot > tr > th.warning,+.table > thead > tr.warning > td,+.table > tbody > tr.warning > td,+.table > tfoot > tr.warning > td,+.table > thead > tr.warning > th,+.table > tbody > tr.warning > th,+.table > tfoot > tr.warning > th {+ background-color: #fcf8e3;+}+.table-hover > tbody > tr > td.warning:hover,+.table-hover > tbody > tr > th.warning:hover,+.table-hover > tbody > tr.warning:hover > td,+.table-hover > tbody > tr:hover > .warning,+.table-hover > tbody > tr.warning:hover > th {+ background-color: #faf2cc;+}+.table > thead > tr > td.danger,+.table > tbody > tr > td.danger,+.table > tfoot > tr > td.danger,+.table > thead > tr > th.danger,+.table > tbody > tr > th.danger,+.table > tfoot > tr > th.danger,+.table > thead > tr.danger > td,+.table > tbody > tr.danger > td,+.table > tfoot > tr.danger > td,+.table > thead > tr.danger > th,+.table > tbody > tr.danger > th,+.table > tfoot > tr.danger > th {+ background-color: #f2dede;+}+.table-hover > tbody > tr > td.danger:hover,+.table-hover > tbody > tr > th.danger:hover,+.table-hover > tbody > tr.danger:hover > td,+.table-hover > tbody > tr:hover > .danger,+.table-hover > tbody > tr.danger:hover > th {+ background-color: #ebcccc;+}+@media screen and (max-width: 767px) {+ .table-responsive {+ width: 100%;+ margin-bottom: 15px;+ overflow-x: auto;+ overflow-y: hidden;+ -webkit-overflow-scrolling: touch;+ -ms-overflow-style: -ms-autohiding-scrollbar;+ border: 1px solid #ddd;+ }+ .table-responsive > .table {+ margin-bottom: 0;+ }+ .table-responsive > .table > thead > tr > th,+ .table-responsive > .table > tbody > tr > th,+ .table-responsive > .table > tfoot > tr > th,+ .table-responsive > .table > thead > tr > td,+ .table-responsive > .table > tbody > tr > td,+ .table-responsive > .table > tfoot > tr > td {+ white-space: nowrap;+ }+ .table-responsive > .table-bordered {+ border: 0;+ }+ .table-responsive > .table-bordered > thead > tr > th:first-child,+ .table-responsive > .table-bordered > tbody > tr > th:first-child,+ .table-responsive > .table-bordered > tfoot > tr > th:first-child,+ .table-responsive > .table-bordered > thead > tr > td:first-child,+ .table-responsive > .table-bordered > tbody > tr > td:first-child,+ .table-responsive > .table-bordered > tfoot > tr > td:first-child {+ border-left: 0;+ }+ .table-responsive > .table-bordered > thead > tr > th:last-child,+ .table-responsive > .table-bordered > tbody > tr > th:last-child,+ .table-responsive > .table-bordered > tfoot > tr > th:last-child,+ .table-responsive > .table-bordered > thead > tr > td:last-child,+ .table-responsive > .table-bordered > tbody > tr > td:last-child,+ .table-responsive > .table-bordered > tfoot > tr > td:last-child {+ border-right: 0;+ }+ .table-responsive > .table-bordered > tbody > tr:last-child > th,+ .table-responsive > .table-bordered > tfoot > tr:last-child > th,+ .table-responsive > .table-bordered > tbody > tr:last-child > td,+ .table-responsive > .table-bordered > tfoot > tr:last-child > td {+ border-bottom: 0;+ }+}+fieldset {+ min-width: 0;+ padding: 0;+ margin: 0;+ border: 0;+}+legend {+ display: block;+ width: 100%;+ padding: 0;+ margin-bottom: 20px;+ font-size: 21px;+ line-height: inherit;+ color: #333;+ border: 0;+ border-bottom: 1px solid #e5e5e5;+}+label {+ display: inline-block;+ max-width: 100%;+ margin-bottom: 5px;+ font-weight: bold;+}+input[type="search"] {+ -webkit-box-sizing: border-box;+ -moz-box-sizing: border-box;+ box-sizing: border-box;+}+input[type="radio"],+input[type="checkbox"] {+ margin: 4px 0 0;+ margin-top: 1px \9;+ line-height: normal;+}+input[type="file"] {+ display: block;+}+input[type="range"] {+ display: block;+ width: 100%;+}+select[multiple],+select[size] {+ height: auto;+}+input[type="file"]:focus,+input[type="radio"]:focus,+input[type="checkbox"]:focus {+ outline: thin dotted;+ outline: 5px auto -webkit-focus-ring-color;+ outline-offset: -2px;+}+output {+ display: block;+ padding-top: 7px;+ font-size: 14px;+ line-height: 1.42857143;+ color: #555;+}+.form-control {+ display: block;+ width: 100%;+ height: 34px;+ padding: 6px 12px;+ font-size: 14px;+ line-height: 1.42857143;+ color: #555;+ background-color: #fff;+ background-image: none;+ border: 1px solid #ccc;+ border-radius: 4px;+ -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);+ box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);+ -webkit-transition: border-color ease-in-out .15s, -webkit-box-shadow ease-in-out .15s;+ -o-transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s;+ transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s;+}+.form-control:focus {+ border-color: #66afe9;+ outline: 0;+ -webkit-box-shadow: inset 0 1px 1px rgba(0,0,0,.075), 0 0 8px rgba(102, 175, 233, .6);+ box-shadow: inset 0 1px 1px rgba(0,0,0,.075), 0 0 8px rgba(102, 175, 233, .6);+}+.form-control::-moz-placeholder {+ color: #777;+ opacity: 1;+}+.form-control:-ms-input-placeholder {+ color: #777;+}+.form-control::-webkit-input-placeholder {+ color: #777;+}+.form-control[disabled],+.form-control[readonly],+fieldset[disabled] .form-control {+ cursor: not-allowed;+ background-color: #eee;+ opacity: 1;+}+textarea.form-control {+ height: auto;+}+input[type="search"] {+ -webkit-appearance: none;+}+input[type="date"],+input[type="time"],+input[type="datetime-local"],+input[type="month"] {+ line-height: 34px;+ line-height: 1.42857143 \0;+}+input[type="date"].input-sm,+input[type="time"].input-sm,+input[type="datetime-local"].input-sm,+input[type="month"].input-sm {+ line-height: 30px;+}+input[type="date"].input-lg,+input[type="time"].input-lg,+input[type="datetime-local"].input-lg,+input[type="month"].input-lg {+ line-height: 46px;+}+.form-group {+ margin-bottom: 15px;+}+.radio,+.checkbox {+ position: relative;+ display: block;+ min-height: 20px;+ margin-top: 10px;+ margin-bottom: 10px;+}+.radio label,+.checkbox label {+ padding-left: 20px;+ margin-bottom: 0;+ font-weight: normal;+ cursor: pointer;+}+.radio input[type="radio"],+.radio-inline input[type="radio"],+.checkbox input[type="checkbox"],+.checkbox-inline input[type="checkbox"] {+ position: absolute;+ margin-top: 4px \9;+ margin-left: -20px;+}+.radio + .radio,+.checkbox + .checkbox {+ margin-top: -5px;+}+.radio-inline,+.checkbox-inline {+ display: inline-block;+ padding-left: 20px;+ margin-bottom: 0;+ font-weight: normal;+ vertical-align: middle;+ cursor: pointer;+}+.radio-inline + .radio-inline,+.checkbox-inline + .checkbox-inline {+ margin-top: 0;+ margin-left: 10px;+}+input[type="radio"][disabled],+input[type="checkbox"][disabled],+input[type="radio"].disabled,+input[type="checkbox"].disabled,+fieldset[disabled] input[type="radio"],+fieldset[disabled] input[type="checkbox"] {+ cursor: not-allowed;+}+.radio-inline.disabled,+.checkbox-inline.disabled,+fieldset[disabled] .radio-inline,+fieldset[disabled] .checkbox-inline {+ cursor: not-allowed;+}+.radio.disabled label,+.checkbox.disabled label,+fieldset[disabled] .radio label,+fieldset[disabled] .checkbox label {+ cursor: not-allowed;+}+.form-control-static {+ padding-top: 7px;+ padding-bottom: 7px;+ margin-bottom: 0;+}+.form-control-static.input-lg,+.form-control-static.input-sm {+ padding-right: 0;+ padding-left: 0;+}+.input-sm,+.form-horizontal .form-group-sm .form-control {+ height: 30px;+ padding: 5px 10px;+ font-size: 12px;+ line-height: 1.5;+ border-radius: 3px;+}+select.input-sm {+ height: 30px;+ line-height: 30px;+}+textarea.input-sm,+select[multiple].input-sm {+ height: auto;+}+.input-lg,+.form-horizontal .form-group-lg .form-control {+ height: 46px;+ padding: 10px 16px;+ font-size: 18px;+ line-height: 1.33;+ border-radius: 6px;+}+select.input-lg {+ height: 46px;+ line-height: 46px;+}+textarea.input-lg,+select[multiple].input-lg {+ height: auto;+}+.has-feedback {+ position: relative;+}+.has-feedback .form-control {+ padding-right: 42.5px;+}+.form-control-feedback {+ position: absolute;+ top: 25px;+ right: 0;+ z-index: 2;+ display: block;+ width: 34px;+ height: 34px;+ line-height: 34px;+ text-align: center;+}+.input-lg + .form-control-feedback {+ width: 46px;+ height: 46px;+ line-height: 46px;+}+.input-sm + .form-control-feedback {+ width: 30px;+ height: 30px;+ line-height: 30px;+}+.has-success .help-block,+.has-success .control-label,+.has-success .radio,+.has-success .checkbox,+.has-success .radio-inline,+.has-success .checkbox-inline {+ color: #3c763d;+}+.has-success .form-control {+ border-color: #3c763d;+ -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);+ box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);+}+.has-success .form-control:focus {+ border-color: #2b542c;+ -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 6px #67b168;+ box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 6px #67b168;+}+.has-success .input-group-addon {+ color: #3c763d;+ background-color: #dff0d8;+ border-color: #3c763d;+}+.has-success .form-control-feedback {+ color: #3c763d;+}+.has-warning .help-block,+.has-warning .control-label,+.has-warning .radio,+.has-warning .checkbox,+.has-warning .radio-inline,+.has-warning .checkbox-inline {+ color: #8a6d3b;+}+.has-warning .form-control {+ border-color: #8a6d3b;+ -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);+ box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);+}+.has-warning .form-control:focus {+ border-color: #66512c;+ -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 6px #c0a16b;+ box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 6px #c0a16b;+}+.has-warning .input-group-addon {+ color: #8a6d3b;+ background-color: #fcf8e3;+ border-color: #8a6d3b;+}+.has-warning .form-control-feedback {+ color: #8a6d3b;+}+.has-error .help-block,+.has-error .control-label,+.has-error .radio,+.has-error .checkbox,+.has-error .radio-inline,+.has-error .checkbox-inline {+ color: #a94442;+}+.has-error .form-control {+ border-color: #a94442;+ -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);+ box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075);+}+.has-error .form-control:focus {+ border-color: #843534;+ -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 6px #ce8483;+ box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 6px #ce8483;+}+.has-error .input-group-addon {+ color: #a94442;+ background-color: #f2dede;+ border-color: #a94442;+}+.has-error .form-control-feedback {+ color: #a94442;+}+.has-feedback label.sr-only ~ .form-control-feedback {+ top: 0;+}+.help-block {+ display: block;+ margin-top: 5px;+ margin-bottom: 10px;+ color: #737373;+}+@media (min-width: 768px) {+ .form-inline .form-group {+ display: inline-block;+ margin-bottom: 0;+ vertical-align: middle;+ }+ .form-inline .form-control {+ display: inline-block;+ width: auto;+ vertical-align: middle;+ }+ .form-inline .input-group {+ display: inline-table;+ vertical-align: middle;+ }+ .form-inline .input-group .input-group-addon,+ .form-inline .input-group .input-group-btn,+ .form-inline .input-group .form-control {+ width: auto;+ }+ .form-inline .input-group > .form-control {+ width: 100%;+ }+ .form-inline .control-label {+ margin-bottom: 0;+ vertical-align: middle;+ }+ .form-inline .radio,+ .form-inline .checkbox {+ display: inline-block;+ margin-top: 0;+ margin-bottom: 0;+ vertical-align: middle;+ }+ .form-inline .radio label,+ .form-inline .checkbox label {+ padding-left: 0;+ }+ .form-inline .radio input[type="radio"],+ .form-inline .checkbox input[type="checkbox"] {+ position: relative;+ margin-left: 0;+ }+ .form-inline .has-feedback .form-control-feedback {+ top: 0;+ }+}+.form-horizontal .radio,+.form-horizontal .checkbox,+.form-horizontal .radio-inline,+.form-horizontal .checkbox-inline {+ padding-top: 7px;+ margin-top: 0;+ margin-bottom: 0;+}+.form-horizontal .radio,+.form-horizontal .checkbox {+ min-height: 27px;+}+.form-horizontal .form-group {+ margin-right: -15px;+ margin-left: -15px;+}+@media (min-width: 768px) {+ .form-horizontal .control-label {+ padding-top: 7px;+ margin-bottom: 0;+ text-align: right;+ }+}+.form-horizontal .has-feedback .form-control-feedback {+ top: 0;+ right: 15px;+}+@media (min-width: 768px) {+ .form-horizontal .form-group-lg .control-label {+ padding-top: 14.3px;+ }+}+@media (min-width: 768px) {+ .form-horizontal .form-group-sm .control-label {+ padding-top: 6px;+ }+}+.btn {+ display: inline-block;+ padding: 6px 12px;+ margin-bottom: 0;+ font-size: 14px;+ font-weight: normal;+ line-height: 1.42857143;+ text-align: center;+ white-space: nowrap;+ vertical-align: middle;+ cursor: pointer;+ -webkit-user-select: none;+ -moz-user-select: none;+ -ms-user-select: none;+ user-select: none;+ background-image: none;+ border: 1px solid transparent;+ border-radius: 4px;+}+.btn:focus,+.btn:active:focus,+.btn.active:focus {+ outline: thin dotted;+ outline: 5px auto -webkit-focus-ring-color;+ outline-offset: -2px;+}+.btn:hover,+.btn:focus {+ color: #333;+ text-decoration: none;+}+.btn:active,+.btn.active {+ background-image: none;+ outline: 0;+ -webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);+ box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);+}+.btn.disabled,+.btn[disabled],+fieldset[disabled] .btn {+ pointer-events: none;+ cursor: not-allowed;+ filter: alpha(opacity=65);+ -webkit-box-shadow: none;+ box-shadow: none;+ opacity: .65;+}+.btn-default {+ color: #333;+ background-color: #fff;+ border-color: #ccc;+}+.btn-default:hover,+.btn-default:focus,+.btn-default:active,+.btn-default.active,+.open > .dropdown-toggle.btn-default {+ color: #333;+ background-color: #e6e6e6;+ border-color: #adadad;+}+.btn-default:active,+.btn-default.active,+.open > .dropdown-toggle.btn-default {+ background-image: none;+}+.btn-default.disabled,+.btn-default[disabled],+fieldset[disabled] .btn-default,+.btn-default.disabled:hover,+.btn-default[disabled]:hover,+fieldset[disabled] .btn-default:hover,+.btn-default.disabled:focus,+.btn-default[disabled]:focus,+fieldset[disabled] .btn-default:focus,+.btn-default.disabled:active,+.btn-default[disabled]:active,+fieldset[disabled] .btn-default:active,+.btn-default.disabled.active,+.btn-default[disabled].active,+fieldset[disabled] .btn-default.active {+ background-color: #fff;+ border-color: #ccc;+}+.btn-default .badge {+ color: #fff;+ background-color: #333;+}+.btn-primary {+ color: #fff;+ background-color: #428bca;+ border-color: #357ebd;+}+.btn-primary:hover,+.btn-primary:focus,+.btn-primary:active,+.btn-primary.active,+.open > .dropdown-toggle.btn-primary {+ color: #fff;+ background-color: #3071a9;+ border-color: #285e8e;+}+.btn-primary:active,+.btn-primary.active,+.open > .dropdown-toggle.btn-primary {+ background-image: none;+}+.btn-primary.disabled,+.btn-primary[disabled],+fieldset[disabled] .btn-primary,+.btn-primary.disabled:hover,+.btn-primary[disabled]:hover,+fieldset[disabled] .btn-primary:hover,+.btn-primary.disabled:focus,+.btn-primary[disabled]:focus,+fieldset[disabled] .btn-primary:focus,+.btn-primary.disabled:active,+.btn-primary[disabled]:active,+fieldset[disabled] .btn-primary:active,+.btn-primary.disabled.active,+.btn-primary[disabled].active,+fieldset[disabled] .btn-primary.active {+ background-color: #428bca;+ border-color: #357ebd;+}+.btn-primary .badge {+ color: #428bca;+ background-color: #fff;+}+.btn-success {+ color: #fff;+ background-color: #5cb85c;+ border-color: #4cae4c;+}+.btn-success:hover,+.btn-success:focus,+.btn-success:active,+.btn-success.active,+.open > .dropdown-toggle.btn-success {+ color: #fff;+ background-color: #449d44;+ border-color: #398439;+}+.btn-success:active,+.btn-success.active,+.open > .dropdown-toggle.btn-success {+ background-image: none;+}+.btn-success.disabled,+.btn-success[disabled],+fieldset[disabled] .btn-success,+.btn-success.disabled:hover,+.btn-success[disabled]:hover,+fieldset[disabled] .btn-success:hover,+.btn-success.disabled:focus,+.btn-success[disabled]:focus,+fieldset[disabled] .btn-success:focus,+.btn-success.disabled:active,+.btn-success[disabled]:active,+fieldset[disabled] .btn-success:active,+.btn-success.disabled.active,+.btn-success[disabled].active,+fieldset[disabled] .btn-success.active {+ background-color: #5cb85c;+ border-color: #4cae4c;+}+.btn-success .badge {+ color: #5cb85c;+ background-color: #fff;+}+.btn-info {+ color: #fff;+ background-color: #5bc0de;+ border-color: #46b8da;+}+.btn-info:hover,+.btn-info:focus,+.btn-info:active,+.btn-info.active,+.open > .dropdown-toggle.btn-info {+ color: #fff;+ background-color: #31b0d5;+ border-color: #269abc;+}+.btn-info:active,+.btn-info.active,+.open > .dropdown-toggle.btn-info {+ background-image: none;+}+.btn-info.disabled,+.btn-info[disabled],+fieldset[disabled] .btn-info,+.btn-info.disabled:hover,+.btn-info[disabled]:hover,+fieldset[disabled] .btn-info:hover,+.btn-info.disabled:focus,+.btn-info[disabled]:focus,+fieldset[disabled] .btn-info:focus,+.btn-info.disabled:active,+.btn-info[disabled]:active,+fieldset[disabled] .btn-info:active,+.btn-info.disabled.active,+.btn-info[disabled].active,+fieldset[disabled] .btn-info.active {+ background-color: #5bc0de;+ border-color: #46b8da;+}+.btn-info .badge {+ color: #5bc0de;+ background-color: #fff;+}+.btn-warning {+ color: #fff;+ background-color: #f0ad4e;+ border-color: #eea236;+}+.btn-warning:hover,+.btn-warning:focus,+.btn-warning:active,+.btn-warning.active,+.open > .dropdown-toggle.btn-warning {+ color: #fff;+ background-color: #ec971f;+ border-color: #d58512;+}+.btn-warning:active,+.btn-warning.active,+.open > .dropdown-toggle.btn-warning {+ background-image: none;+}+.btn-warning.disabled,+.btn-warning[disabled],+fieldset[disabled] .btn-warning,+.btn-warning.disabled:hover,+.btn-warning[disabled]:hover,+fieldset[disabled] .btn-warning:hover,+.btn-warning.disabled:focus,+.btn-warning[disabled]:focus,+fieldset[disabled] .btn-warning:focus,+.btn-warning.disabled:active,+.btn-warning[disabled]:active,+fieldset[disabled] .btn-warning:active,+.btn-warning.disabled.active,+.btn-warning[disabled].active,+fieldset[disabled] .btn-warning.active {+ background-color: #f0ad4e;+ border-color: #eea236;+}+.btn-warning .badge {+ color: #f0ad4e;+ background-color: #fff;+}+.btn-danger {+ color: #fff;+ background-color: #d9534f;+ border-color: #d43f3a;+}+.btn-danger:hover,+.btn-danger:focus,+.btn-danger:active,+.btn-danger.active,+.open > .dropdown-toggle.btn-danger {+ color: #fff;+ background-color: #c9302c;+ border-color: #ac2925;+}+.btn-danger:active,+.btn-danger.active,+.open > .dropdown-toggle.btn-danger {+ background-image: none;+}+.btn-danger.disabled,+.btn-danger[disabled],+fieldset[disabled] .btn-danger,+.btn-danger.disabled:hover,+.btn-danger[disabled]:hover,+fieldset[disabled] .btn-danger:hover,+.btn-danger.disabled:focus,+.btn-danger[disabled]:focus,+fieldset[disabled] .btn-danger:focus,+.btn-danger.disabled:active,+.btn-danger[disabled]:active,+fieldset[disabled] .btn-danger:active,+.btn-danger.disabled.active,+.btn-danger[disabled].active,+fieldset[disabled] .btn-danger.active {+ background-color: #d9534f;+ border-color: #d43f3a;+}+.btn-danger .badge {+ color: #d9534f;+ background-color: #fff;+}+.btn-link {+ font-weight: normal;+ color: #428bca;+ cursor: pointer;+ border-radius: 0;+}+.btn-link,+.btn-link:active,+.btn-link[disabled],+fieldset[disabled] .btn-link {+ background-color: transparent;+ -webkit-box-shadow: none;+ box-shadow: none;+}+.btn-link,+.btn-link:hover,+.btn-link:focus,+.btn-link:active {+ border-color: transparent;+}+.btn-link:hover,+.btn-link:focus {+ color: #2a6496;+ text-decoration: underline;+ background-color: transparent;+}+.btn-link[disabled]:hover,+fieldset[disabled] .btn-link:hover,+.btn-link[disabled]:focus,+fieldset[disabled] .btn-link:focus {+ color: #777;+ text-decoration: none;+}+.btn-lg,+.btn-group-lg > .btn {+ padding: 10px 16px;+ font-size: 18px;+ line-height: 1.33;+ border-radius: 6px;+}+.btn-sm,+.btn-group-sm > .btn {+ padding: 5px 10px;+ font-size: 12px;+ line-height: 1.5;+ border-radius: 3px;+}+.btn-xs,+.btn-group-xs > .btn {+ padding: 1px 5px;+ font-size: 12px;+ line-height: 1.5;+ border-radius: 3px;+}+.btn-block {+ display: block;+ width: 100%;+}+.btn-block + .btn-block {+ margin-top: 5px;+}+input[type="submit"].btn-block,+input[type="reset"].btn-block,+input[type="button"].btn-block {+ width: 100%;+}+.fade {+ opacity: 0;+ -webkit-transition: opacity .15s linear;+ -o-transition: opacity .15s linear;+ transition: opacity .15s linear;+}+.fade.in {+ opacity: 1;+}+.collapse {+ display: none;+}+.collapse.in {+ display: block;+}+tr.collapse.in {+ display: table-row;+}+tbody.collapse.in {+ display: table-row-group;+}+.collapsing {+ position: relative;+ height: 0;+ overflow: hidden;+ -webkit-transition: height .35s ease;+ -o-transition: height .35s ease;+ transition: height .35s ease;+}+.caret {+ display: inline-block;+ width: 0;+ height: 0;+ margin-left: 2px;+ vertical-align: middle;+ border-top: 4px solid;+ border-right: 4px solid transparent;+ border-left: 4px solid transparent;+}+.dropdown {+ position: relative;+}+.dropdown-toggle:focus {+ outline: 0;+}+.dropdown-menu {+ position: absolute;+ top: 100%;+ left: 0;+ z-index: 1000;+ display: none;+ float: left;+ min-width: 160px;+ padding: 5px 0;+ margin: 2px 0 0;+ font-size: 14px;+ text-align: left;+ list-style: none;+ background-color: #fff;+ -webkit-background-clip: padding-box;+ background-clip: padding-box;+ border: 1px solid #ccc;+ border: 1px solid rgba(0, 0, 0, .15);+ border-radius: 4px;+ -webkit-box-shadow: 0 6px 12px rgba(0, 0, 0, .175);+ box-shadow: 0 6px 12px rgba(0, 0, 0, .175);+}+.dropdown-menu.pull-right {+ right: 0;+ left: auto;+}+.dropdown-menu .divider {+ height: 1px;+ margin: 9px 0;+ overflow: hidden;+ background-color: #e5e5e5;+}+.dropdown-menu > li > a {+ display: block;+ padding: 3px 20px;+ clear: both;+ font-weight: normal;+ line-height: 1.42857143;+ color: #333;+ white-space: nowrap;+}+.dropdown-menu > li > a:hover,+.dropdown-menu > li > a:focus {+ color: #262626;+ text-decoration: none;+ background-color: #f5f5f5;+}+.dropdown-menu > .active > a,+.dropdown-menu > .active > a:hover,+.dropdown-menu > .active > a:focus {+ color: #fff;+ text-decoration: none;+ background-color: #428bca;+ outline: 0;+}+.dropdown-menu > .disabled > a,+.dropdown-menu > .disabled > a:hover,+.dropdown-menu > .disabled > a:focus {+ color: #777;+}+.dropdown-menu > .disabled > a:hover,+.dropdown-menu > .disabled > a:focus {+ text-decoration: none;+ cursor: not-allowed;+ background-color: transparent;+ background-image: none;+ filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);+}+.open > .dropdown-menu {+ display: block;+}+.open > a {+ outline: 0;+}+.dropdown-menu-right {+ right: 0;+ left: auto;+}+.dropdown-menu-left {+ right: auto;+ left: 0;+}+.dropdown-header {+ display: block;+ padding: 3px 20px;+ font-size: 12px;+ line-height: 1.42857143;+ color: #777;+ white-space: nowrap;+}+.dropdown-backdrop {+ position: fixed;+ top: 0;+ right: 0;+ bottom: 0;+ left: 0;+ z-index: 990;+}+.pull-right > .dropdown-menu {+ right: 0;+ left: auto;+}+.dropup .caret,+.navbar-fixed-bottom .dropdown .caret {+ content: "";+ border-top: 0;+ border-bottom: 4px solid;+}+.dropup .dropdown-menu,+.navbar-fixed-bottom .dropdown .dropdown-menu {+ top: auto;+ bottom: 100%;+ margin-bottom: 1px;+}+@media (min-width: 768px) {+ .navbar-right .dropdown-menu {+ right: 0;+ left: auto;+ }+ .navbar-right .dropdown-menu-left {+ right: auto;+ left: 0;+ }+}+.btn-group,+.btn-group-vertical {+ position: relative;+ display: inline-block;+ vertical-align: middle;+}+.btn-group > .btn,+.btn-group-vertical > .btn {+ position: relative;+ float: left;+}+.btn-group > .btn:hover,+.btn-group-vertical > .btn:hover,+.btn-group > .btn:focus,+.btn-group-vertical > .btn:focus,+.btn-group > .btn:active,+.btn-group-vertical > .btn:active,+.btn-group > .btn.active,+.btn-group-vertical > .btn.active {+ z-index: 2;+}+.btn-group > .btn:focus,+.btn-group-vertical > .btn:focus {+ outline: 0;+}+.btn-group .btn + .btn,+.btn-group .btn + .btn-group,+.btn-group .btn-group + .btn,+.btn-group .btn-group + .btn-group {+ margin-left: -1px;+}+.btn-toolbar {+ margin-left: -5px;+}+.btn-toolbar .btn-group,+.btn-toolbar .input-group {+ float: left;+}+.btn-toolbar > .btn,+.btn-toolbar > .btn-group,+.btn-toolbar > .input-group {+ margin-left: 5px;+}+.btn-group > .btn:not(:first-child):not(:last-child):not(.dropdown-toggle) {+ border-radius: 0;+}+.btn-group > .btn:first-child {+ margin-left: 0;+}+.btn-group > .btn:first-child:not(:last-child):not(.dropdown-toggle) {+ border-top-right-radius: 0;+ border-bottom-right-radius: 0;+}+.btn-group > .btn:last-child:not(:first-child),+.btn-group > .dropdown-toggle:not(:first-child) {+ border-top-left-radius: 0;+ border-bottom-left-radius: 0;+}+.btn-group > .btn-group {+ float: left;+}+.btn-group > .btn-group:not(:first-child):not(:last-child) > .btn {+ border-radius: 0;+}+.btn-group > .btn-group:first-child > .btn:last-child,+.btn-group > .btn-group:first-child > .dropdown-toggle {+ border-top-right-radius: 0;+ border-bottom-right-radius: 0;+}+.btn-group > .btn-group:last-child > .btn:first-child {+ border-top-left-radius: 0;+ border-bottom-left-radius: 0;+}+.btn-group .dropdown-toggle:active,+.btn-group.open .dropdown-toggle {+ outline: 0;+}+.btn-group > .btn + .dropdown-toggle {+ padding-right: 8px;+ padding-left: 8px;+}+.btn-group > .btn-lg + .dropdown-toggle {+ padding-right: 12px;+ padding-left: 12px;+}+.btn-group.open .dropdown-toggle {+ -webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);+ box-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);+}+.btn-group.open .dropdown-toggle.btn-link {+ -webkit-box-shadow: none;+ box-shadow: none;+}+.btn .caret {+ margin-left: 0;+}+.btn-lg .caret {+ border-width: 5px 5px 0;+ border-bottom-width: 0;+}+.dropup .btn-lg .caret {+ border-width: 0 5px 5px;+}+.btn-group-vertical > .btn,+.btn-group-vertical > .btn-group,+.btn-group-vertical > .btn-group > .btn {+ display: block;+ float: none;+ width: 100%;+ max-width: 100%;+}+.btn-group-vertical > .btn-group > .btn {+ float: none;+}+.btn-group-vertical > .btn + .btn,+.btn-group-vertical > .btn + .btn-group,+.btn-group-vertical > .btn-group + .btn,+.btn-group-vertical > .btn-group + .btn-group {+ margin-top: -1px;+ margin-left: 0;+}+.btn-group-vertical > .btn:not(:first-child):not(:last-child) {+ border-radius: 0;+}+.btn-group-vertical > .btn:first-child:not(:last-child) {+ border-top-right-radius: 4px;+ border-bottom-right-radius: 0;+ border-bottom-left-radius: 0;+}+.btn-group-vertical > .btn:last-child:not(:first-child) {+ border-top-left-radius: 0;+ border-top-right-radius: 0;+ border-bottom-left-radius: 4px;+}+.btn-group-vertical > .btn-group:not(:first-child):not(:last-child) > .btn {+ border-radius: 0;+}+.btn-group-vertical > .btn-group:first-child:not(:last-child) > .btn:last-child,+.btn-group-vertical > .btn-group:first-child:not(:last-child) > .dropdown-toggle {+ border-bottom-right-radius: 0;+ border-bottom-left-radius: 0;+}+.btn-group-vertical > .btn-group:last-child:not(:first-child) > .btn:first-child {+ border-top-left-radius: 0;+ border-top-right-radius: 0;+}+.btn-group-justified {+ display: table;+ width: 100%;+ table-layout: fixed;+ border-collapse: separate;+}+.btn-group-justified > .btn,+.btn-group-justified > .btn-group {+ display: table-cell;+ float: none;+ width: 1%;+}+.btn-group-justified > .btn-group .btn {+ width: 100%;+}+.btn-group-justified > .btn-group .dropdown-menu {+ left: auto;+}+[data-toggle="buttons"] > .btn > input[type="radio"],+[data-toggle="buttons"] > .btn > input[type="checkbox"] {+ position: absolute;+ z-index: -1;+ filter: alpha(opacity=0);+ opacity: 0;+}+.input-group {+ position: relative;+ display: table;+ border-collapse: separate;+}+.input-group[class*="col-"] {+ float: none;+ padding-right: 0;+ padding-left: 0;+}+.input-group .form-control {+ position: relative;+ z-index: 2;+ float: left;+ width: 100%;+ margin-bottom: 0;+}+.input-group-lg > .form-control,+.input-group-lg > .input-group-addon,+.input-group-lg > .input-group-btn > .btn {+ height: 46px;+ padding: 10px 16px;+ font-size: 18px;+ line-height: 1.33;+ border-radius: 6px;+}+select.input-group-lg > .form-control,+select.input-group-lg > .input-group-addon,+select.input-group-lg > .input-group-btn > .btn {+ height: 46px;+ line-height: 46px;+}+textarea.input-group-lg > .form-control,+textarea.input-group-lg > .input-group-addon,+textarea.input-group-lg > .input-group-btn > .btn,+select[multiple].input-group-lg > .form-control,+select[multiple].input-group-lg > .input-group-addon,+select[multiple].input-group-lg > .input-group-btn > .btn {+ height: auto;+}+.input-group-sm > .form-control,+.input-group-sm > .input-group-addon,+.input-group-sm > .input-group-btn > .btn {+ height: 30px;+ padding: 5px 10px;+ font-size: 12px;+ line-height: 1.5;+ border-radius: 3px;+}+select.input-group-sm > .form-control,+select.input-group-sm > .input-group-addon,+select.input-group-sm > .input-group-btn > .btn {+ height: 30px;+ line-height: 30px;+}+textarea.input-group-sm > .form-control,+textarea.input-group-sm > .input-group-addon,+textarea.input-group-sm > .input-group-btn > .btn,+select[multiple].input-group-sm > .form-control,+select[multiple].input-group-sm > .input-group-addon,+select[multiple].input-group-sm > .input-group-btn > .btn {+ height: auto;+}+.input-group-addon,+.input-group-btn,+.input-group .form-control {+ display: table-cell;+}+.input-group-addon:not(:first-child):not(:last-child),+.input-group-btn:not(:first-child):not(:last-child),+.input-group .form-control:not(:first-child):not(:last-child) {+ border-radius: 0;+}+.input-group-addon,+.input-group-btn {+ width: 1%;+ white-space: nowrap;+ vertical-align: middle;+}+.input-group-addon {+ padding: 6px 12px;+ font-size: 14px;+ font-weight: normal;+ line-height: 1;+ color: #555;+ text-align: center;+ background-color: #eee;+ border: 1px solid #ccc;+ border-radius: 4px;+}+.input-group-addon.input-sm {+ padding: 5px 10px;+ font-size: 12px;+ border-radius: 3px;+}+.input-group-addon.input-lg {+ padding: 10px 16px;+ font-size: 18px;+ border-radius: 6px;+}+.input-group-addon input[type="radio"],+.input-group-addon input[type="checkbox"] {+ margin-top: 0;+}+.input-group .form-control:first-child,+.input-group-addon:first-child,+.input-group-btn:first-child > .btn,+.input-group-btn:first-child > .btn-group > .btn,+.input-group-btn:first-child > .dropdown-toggle,+.input-group-btn:last-child > .btn:not(:last-child):not(.dropdown-toggle),+.input-group-btn:last-child > .btn-group:not(:last-child) > .btn {+ border-top-right-radius: 0;+ border-bottom-right-radius: 0;+}+.input-group-addon:first-child {+ border-right: 0;+}+.input-group .form-control:last-child,+.input-group-addon:last-child,+.input-group-btn:last-child > .btn,+.input-group-btn:last-child > .btn-group > .btn,+.input-group-btn:last-child > .dropdown-toggle,+.input-group-btn:first-child > .btn:not(:first-child),+.input-group-btn:first-child > .btn-group:not(:first-child) > .btn {+ border-top-left-radius: 0;+ border-bottom-left-radius: 0;+}+.input-group-addon:last-child {+ border-left: 0;+}+.input-group-btn {+ position: relative;+ font-size: 0;+ white-space: nowrap;+}+.input-group-btn > .btn {+ position: relative;+}+.input-group-btn > .btn + .btn {+ margin-left: -1px;+}+.input-group-btn > .btn:hover,+.input-group-btn > .btn:focus,+.input-group-btn > .btn:active {+ z-index: 2;+}+.input-group-btn:first-child > .btn,+.input-group-btn:first-child > .btn-group {+ margin-right: -1px;+}+.input-group-btn:last-child > .btn,+.input-group-btn:last-child > .btn-group {+ margin-left: -1px;+}+.nav {+ padding-left: 0;+ margin-bottom: 0;+ list-style: none;+}+.nav > li {+ position: relative;+ display: block;+}+.nav > li > a {+ position: relative;+ display: block;+ padding: 10px 15px;+}+.nav > li > a:hover,+.nav > li > a:focus {+ text-decoration: none;+ background-color: #eee;+}+.nav > li.disabled > a {+ color: #777;+}+.nav > li.disabled > a:hover,+.nav > li.disabled > a:focus {+ color: #777;+ text-decoration: none;+ cursor: not-allowed;+ background-color: transparent;+}+.nav .open > a,+.nav .open > a:hover,+.nav .open > a:focus {+ background-color: #eee;+ border-color: #428bca;+}+.nav .nav-divider {+ height: 1px;+ margin: 9px 0;+ overflow: hidden;+ background-color: #e5e5e5;+}+.nav > li > a > img {+ max-width: none;+}+.nav-tabs {+ border-bottom: 1px solid #ddd;+}+.nav-tabs > li {+ float: left;+ margin-bottom: -1px;+}+.nav-tabs > li > a {+ margin-right: 2px;+ line-height: 1.42857143;+ border: 1px solid transparent;+ border-radius: 4px 4px 0 0;+}+.nav-tabs > li > a:hover {+ border-color: #eee #eee #ddd;+}+.nav-tabs > li.active > a,+.nav-tabs > li.active > a:hover,+.nav-tabs > li.active > a:focus {+ color: #555;+ cursor: default;+ background-color: #fff;+ border: 1px solid #ddd;+ border-bottom-color: transparent;+}+.nav-tabs.nav-justified {+ width: 100%;+ border-bottom: 0;+}+.nav-tabs.nav-justified > li {+ float: none;+}+.nav-tabs.nav-justified > li > a {+ margin-bottom: 5px;+ text-align: center;+}+.nav-tabs.nav-justified > .dropdown .dropdown-menu {+ top: auto;+ left: auto;+}+@media (min-width: 768px) {+ .nav-tabs.nav-justified > li {+ display: table-cell;+ width: 1%;+ }+ .nav-tabs.nav-justified > li > a {+ margin-bottom: 0;+ }+}+.nav-tabs.nav-justified > li > a {+ margin-right: 0;+ border-radius: 4px;+}+.nav-tabs.nav-justified > .active > a,+.nav-tabs.nav-justified > .active > a:hover,+.nav-tabs.nav-justified > .active > a:focus {+ border: 1px solid #ddd;+}+@media (min-width: 768px) {+ .nav-tabs.nav-justified > li > a {+ border-bottom: 1px solid #ddd;+ border-radius: 4px 4px 0 0;+ }+ .nav-tabs.nav-justified > .active > a,+ .nav-tabs.nav-justified > .active > a:hover,+ .nav-tabs.nav-justified > .active > a:focus {+ border-bottom-color: #fff;+ }+}+.nav-pills > li {+ float: left;+}+.nav-pills > li > a {+ border-radius: 4px;+}+.nav-pills > li + li {+ margin-left: 2px;+}+.nav-pills > li.active > a,+.nav-pills > li.active > a:hover,+.nav-pills > li.active > a:focus {+ color: #fff;+ background-color: #428bca;+}+.nav-stacked > li {+ float: none;+}+.nav-stacked > li + li {+ margin-top: 2px;+ margin-left: 0;+}+.nav-justified {+ width: 100%;+}+.nav-justified > li {+ float: none;+}+.nav-justified > li > a {+ margin-bottom: 5px;+ text-align: center;+}+.nav-justified > .dropdown .dropdown-menu {+ top: auto;+ left: auto;+}+@media (min-width: 768px) {+ .nav-justified > li {+ display: table-cell;+ width: 1%;+ }+ .nav-justified > li > a {+ margin-bottom: 0;+ }+}+.nav-tabs-justified {+ border-bottom: 0;+}+.nav-tabs-justified > li > a {+ margin-right: 0;+ border-radius: 4px;+}+.nav-tabs-justified > .active > a,+.nav-tabs-justified > .active > a:hover,+.nav-tabs-justified > .active > a:focus {+ border: 1px solid #ddd;+}+@media (min-width: 768px) {+ .nav-tabs-justified > li > a {+ border-bottom: 1px solid #ddd;+ border-radius: 4px 4px 0 0;+ }+ .nav-tabs-justified > .active > a,+ .nav-tabs-justified > .active > a:hover,+ .nav-tabs-justified > .active > a:focus {+ border-bottom-color: #fff;+ }+}+.tab-content > .tab-pane {+ display: none;+}+.tab-content > .active {+ display: block;+}+.nav-tabs .dropdown-menu {+ margin-top: -1px;+ border-top-left-radius: 0;+ border-top-right-radius: 0;+}+.navbar {+ position: relative;+ min-height: 50px;+ margin-bottom: 20px;+ border: 1px solid transparent;+}+@media (min-width: 768px) {+ .navbar {+ border-radius: 4px;+ }+}+@media (min-width: 768px) {+ .navbar-header {+ float: left;+ }+}+.navbar-collapse {+ padding-right: 15px;+ padding-left: 15px;+ overflow-x: visible;+ -webkit-overflow-scrolling: touch;+ border-top: 1px solid transparent;+ -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .1);+ box-shadow: inset 0 1px 0 rgba(255, 255, 255, .1);+}+.navbar-collapse.in {+ overflow-y: auto;+}+@media (min-width: 768px) {+ .navbar-collapse {+ width: auto;+ border-top: 0;+ -webkit-box-shadow: none;+ box-shadow: none;+ }+ .navbar-collapse.collapse {+ display: block !important;+ height: auto !important;+ padding-bottom: 0;+ overflow: visible !important;+ }+ .navbar-collapse.in {+ overflow-y: visible;+ }+ .navbar-fixed-top .navbar-collapse,+ .navbar-static-top .navbar-collapse,+ .navbar-fixed-bottom .navbar-collapse {+ padding-right: 0;+ padding-left: 0;+ }+}+.navbar-fixed-top .navbar-collapse,+.navbar-fixed-bottom .navbar-collapse {+ max-height: 340px;+}+@media (max-width: 480px) and (orientation: landscape) {+ .navbar-fixed-top .navbar-collapse,+ .navbar-fixed-bottom .navbar-collapse {+ max-height: 200px;+ }+}+.container > .navbar-header,+.container-fluid > .navbar-header,+.container > .navbar-collapse,+.container-fluid > .navbar-collapse {+ margin-right: -15px;+ margin-left: -15px;+}+@media (min-width: 768px) {+ .container > .navbar-header,+ .container-fluid > .navbar-header,+ .container > .navbar-collapse,+ .container-fluid > .navbar-collapse {+ margin-right: 0;+ margin-left: 0;+ }+}+.navbar-static-top {+ z-index: 1000;+ border-width: 0 0 1px;+}+@media (min-width: 768px) {+ .navbar-static-top {+ border-radius: 0;+ }+}+.navbar-fixed-top,+.navbar-fixed-bottom {+ position: fixed;+ right: 0;+ left: 0;+ z-index: 1030;+ -webkit-transform: translate3d(0, 0, 0);+ -o-transform: translate3d(0, 0, 0);+ transform: translate3d(0, 0, 0);+}+@media (min-width: 768px) {+ .navbar-fixed-top,+ .navbar-fixed-bottom {+ border-radius: 0;+ }+}+.navbar-fixed-top {+ top: 0;+ border-width: 0 0 1px;+}+.navbar-fixed-bottom {+ bottom: 0;+ margin-bottom: 0;+ border-width: 1px 0 0;+}+.navbar-brand {+ float: left;+ height: 50px;+ padding: 15px 15px;+ font-size: 18px;+ line-height: 20px;+}+.navbar-brand:hover,+.navbar-brand:focus {+ text-decoration: none;+}+@media (min-width: 768px) {+ .navbar > .container .navbar-brand,+ .navbar > .container-fluid .navbar-brand {+ margin-left: -15px;+ }+}+.navbar-toggle {+ position: relative;+ float: right;+ padding: 9px 10px;+ margin-top: 8px;+ margin-right: 15px;+ margin-bottom: 8px;+ background-color: transparent;+ background-image: none;+ border: 1px solid transparent;+ border-radius: 4px;+}+.navbar-toggle:focus {+ outline: 0;+}+.navbar-toggle .icon-bar {+ display: block;+ width: 22px;+ height: 2px;+ border-radius: 1px;+}+.navbar-toggle .icon-bar + .icon-bar {+ margin-top: 4px;+}+@media (min-width: 768px) {+ .navbar-toggle {+ display: none;+ }+}+.navbar-nav {+ margin: 7.5px -15px;+}+.navbar-nav > li > a {+ padding-top: 10px;+ padding-bottom: 10px;+ line-height: 20px;+}+@media (max-width: 767px) {+ .navbar-nav .open .dropdown-menu {+ position: static;+ float: none;+ width: auto;+ margin-top: 0;+ background-color: transparent;+ border: 0;+ -webkit-box-shadow: none;+ box-shadow: none;+ }+ .navbar-nav .open .dropdown-menu > li > a,+ .navbar-nav .open .dropdown-menu .dropdown-header {+ padding: 5px 15px 5px 25px;+ }+ .navbar-nav .open .dropdown-menu > li > a {+ line-height: 20px;+ }+ .navbar-nav .open .dropdown-menu > li > a:hover,+ .navbar-nav .open .dropdown-menu > li > a:focus {+ background-image: none;+ }+}+@media (min-width: 768px) {+ .navbar-nav {+ float: left;+ margin: 0;+ }+ .navbar-nav > li {+ float: left;+ }+ .navbar-nav > li > a {+ padding-top: 15px;+ padding-bottom: 15px;+ }+ .navbar-nav.navbar-right:last-child {+ margin-right: -15px;+ }+}+@media (min-width: 768px) {+ .navbar-left {+ float: left !important;+ }+ .navbar-right {+ float: right !important;+ }+}+.navbar-form {+ padding: 10px 15px;+ margin-top: 8px;+ margin-right: -15px;+ margin-bottom: 8px;+ margin-left: -15px;+ border-top: 1px solid transparent;+ border-bottom: 1px solid transparent;+ -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .1), 0 1px 0 rgba(255, 255, 255, .1);+ box-shadow: inset 0 1px 0 rgba(255, 255, 255, .1), 0 1px 0 rgba(255, 255, 255, .1);+}+@media (min-width: 768px) {+ .navbar-form .form-group {+ display: inline-block;+ margin-bottom: 0;+ vertical-align: middle;+ }+ .navbar-form .form-control {+ display: inline-block;+ width: auto;+ vertical-align: middle;+ }+ .navbar-form .input-group {+ display: inline-table;+ vertical-align: middle;+ }+ .navbar-form .input-group .input-group-addon,+ .navbar-form .input-group .input-group-btn,+ .navbar-form .input-group .form-control {+ width: auto;+ }+ .navbar-form .input-group > .form-control {+ width: 100%;+ }+ .navbar-form .control-label {+ margin-bottom: 0;+ vertical-align: middle;+ }+ .navbar-form .radio,+ .navbar-form .checkbox {+ display: inline-block;+ margin-top: 0;+ margin-bottom: 0;+ vertical-align: middle;+ }+ .navbar-form .radio label,+ .navbar-form .checkbox label {+ padding-left: 0;+ }+ .navbar-form .radio input[type="radio"],+ .navbar-form .checkbox input[type="checkbox"] {+ position: relative;+ margin-left: 0;+ }+ .navbar-form .has-feedback .form-control-feedback {+ top: 0;+ }+}+@media (max-width: 767px) {+ .navbar-form .form-group {+ margin-bottom: 5px;+ }+}+@media (min-width: 768px) {+ .navbar-form {+ width: auto;+ padding-top: 0;+ padding-bottom: 0;+ margin-right: 0;+ margin-left: 0;+ border: 0;+ -webkit-box-shadow: none;+ box-shadow: none;+ }+ .navbar-form.navbar-right:last-child {+ margin-right: -15px;+ }+}+.navbar-nav > li > .dropdown-menu {+ margin-top: 0;+ border-top-left-radius: 0;+ border-top-right-radius: 0;+}+.navbar-fixed-bottom .navbar-nav > li > .dropdown-menu {+ border-bottom-right-radius: 0;+ border-bottom-left-radius: 0;+}+.navbar-btn {+ margin-top: 8px;+ margin-bottom: 8px;+}+.navbar-btn.btn-sm {+ margin-top: 10px;+ margin-bottom: 10px;+}+.navbar-btn.btn-xs {+ margin-top: 14px;+ margin-bottom: 14px;+}+.navbar-text {+ margin-top: 15px;+ margin-bottom: 15px;+}+@media (min-width: 768px) {+ .navbar-text {+ float: left;+ margin-right: 15px;+ margin-left: 15px;+ }+ .navbar-text.navbar-right:last-child {+ margin-right: 0;+ }+}+.navbar-default {+ background-color: #f8f8f8;+ border-color: #e7e7e7;+}+.navbar-default .navbar-brand {+ color: #777;+}+.navbar-default .navbar-brand:hover,+.navbar-default .navbar-brand:focus {+ color: #5e5e5e;+ background-color: transparent;+}+.navbar-default .navbar-text {+ color: #777;+}+.navbar-default .navbar-nav > li > a {+ color: #777;+}+.navbar-default .navbar-nav > li > a:hover,+.navbar-default .navbar-nav > li > a:focus {+ color: #333;+ background-color: transparent;+}+.navbar-default .navbar-nav > .active > a,+.navbar-default .navbar-nav > .active > a:hover,+.navbar-default .navbar-nav > .active > a:focus {+ color: #555;+ background-color: #e7e7e7;+}+.navbar-default .navbar-nav > .disabled > a,+.navbar-default .navbar-nav > .disabled > a:hover,+.navbar-default .navbar-nav > .disabled > a:focus {+ color: #ccc;+ background-color: transparent;+}+.navbar-default .navbar-toggle {+ border-color: #ddd;+}+.navbar-default .navbar-toggle:hover,+.navbar-default .navbar-toggle:focus {+ background-color: #ddd;+}+.navbar-default .navbar-toggle .icon-bar {+ background-color: #888;+}+.navbar-default .navbar-collapse,+.navbar-default .navbar-form {+ border-color: #e7e7e7;+}+.navbar-default .navbar-nav > .open > a,+.navbar-default .navbar-nav > .open > a:hover,+.navbar-default .navbar-nav > .open > a:focus {+ color: #555;+ background-color: #e7e7e7;+}+@media (max-width: 767px) {+ .navbar-default .navbar-nav .open .dropdown-menu > li > a {+ color: #777;+ }+ .navbar-default .navbar-nav .open .dropdown-menu > li > a:hover,+ .navbar-default .navbar-nav .open .dropdown-menu > li > a:focus {+ color: #333;+ background-color: transparent;+ }+ .navbar-default .navbar-nav .open .dropdown-menu > .active > a,+ .navbar-default .navbar-nav .open .dropdown-menu > .active > a:hover,+ .navbar-default .navbar-nav .open .dropdown-menu > .active > a:focus {+ color: #555;+ background-color: #e7e7e7;+ }+ .navbar-default .navbar-nav .open .dropdown-menu > .disabled > a,+ .navbar-default .navbar-nav .open .dropdown-menu > .disabled > a:hover,+ .navbar-default .navbar-nav .open .dropdown-menu > .disabled > a:focus {+ color: #ccc;+ background-color: transparent;+ }+}+.navbar-default .navbar-link {+ color: #777;+}+.navbar-default .navbar-link:hover {+ color: #333;+}+.navbar-default .btn-link {+ color: #777;+}+.navbar-default .btn-link:hover,+.navbar-default .btn-link:focus {+ color: #333;+}+.navbar-default .btn-link[disabled]:hover,+fieldset[disabled] .navbar-default .btn-link:hover,+.navbar-default .btn-link[disabled]:focus,+fieldset[disabled] .navbar-default .btn-link:focus {+ color: #ccc;+}+.navbar-inverse {+ background-color: #222;+ border-color: #080808;+}+.navbar-inverse .navbar-brand {+ color: #777;+}+.navbar-inverse .navbar-brand:hover,+.navbar-inverse .navbar-brand:focus {+ color: #fff;+ background-color: transparent;+}+.navbar-inverse .navbar-text {+ color: #777;+}+.navbar-inverse .navbar-nav > li > a {+ color: #777;+}+.navbar-inverse .navbar-nav > li > a:hover,+.navbar-inverse .navbar-nav > li > a:focus {+ color: #fff;+ background-color: transparent;+}+.navbar-inverse .navbar-nav > .active > a,+.navbar-inverse .navbar-nav > .active > a:hover,+.navbar-inverse .navbar-nav > .active > a:focus {+ color: #fff;+ background-color: #080808;+}+.navbar-inverse .navbar-nav > .disabled > a,+.navbar-inverse .navbar-nav > .disabled > a:hover,+.navbar-inverse .navbar-nav > .disabled > a:focus {+ color: #444;+ background-color: transparent;+}+.navbar-inverse .navbar-toggle {+ border-color: #333;+}+.navbar-inverse .navbar-toggle:hover,+.navbar-inverse .navbar-toggle:focus {+ background-color: #333;+}+.navbar-inverse .navbar-toggle .icon-bar {+ background-color: #fff;+}+.navbar-inverse .navbar-collapse,+.navbar-inverse .navbar-form {+ border-color: #101010;+}+.navbar-inverse .navbar-nav > .open > a,+.navbar-inverse .navbar-nav > .open > a:hover,+.navbar-inverse .navbar-nav > .open > a:focus {+ color: #fff;+ background-color: #080808;+}+@media (max-width: 767px) {+ .navbar-inverse .navbar-nav .open .dropdown-menu > .dropdown-header {+ border-color: #080808;+ }+ .navbar-inverse .navbar-nav .open .dropdown-menu .divider {+ background-color: #080808;+ }+ .navbar-inverse .navbar-nav .open .dropdown-menu > li > a {+ color: #777;+ }+ .navbar-inverse .navbar-nav .open .dropdown-menu > li > a:hover,+ .navbar-inverse .navbar-nav .open .dropdown-menu > li > a:focus {+ color: #fff;+ background-color: transparent;+ }+ .navbar-inverse .navbar-nav .open .dropdown-menu > .active > a,+ .navbar-inverse .navbar-nav .open .dropdown-menu > .active > a:hover,+ .navbar-inverse .navbar-nav .open .dropdown-menu > .active > a:focus {+ color: #fff;+ background-color: #080808;+ }+ .navbar-inverse .navbar-nav .open .dropdown-menu > .disabled > a,+ .navbar-inverse .navbar-nav .open .dropdown-menu > .disabled > a:hover,+ .navbar-inverse .navbar-nav .open .dropdown-menu > .disabled > a:focus {+ color: #444;+ background-color: transparent;+ }+}+.navbar-inverse .navbar-link {+ color: #777;+}+.navbar-inverse .navbar-link:hover {+ color: #fff;+}+.navbar-inverse .btn-link {+ color: #777;+}+.navbar-inverse .btn-link:hover,+.navbar-inverse .btn-link:focus {+ color: #fff;+}+.navbar-inverse .btn-link[disabled]:hover,+fieldset[disabled] .navbar-inverse .btn-link:hover,+.navbar-inverse .btn-link[disabled]:focus,+fieldset[disabled] .navbar-inverse .btn-link:focus {+ color: #444;+}+.breadcrumb {+ padding: 8px 15px;+ margin-bottom: 20px;+ list-style: none;+ background-color: #f5f5f5;+ border-radius: 4px;+}+.breadcrumb > li {+ display: inline-block;+}+.breadcrumb > li + li:before {+ padding: 0 5px;+ color: #ccc;+ content: "/\00a0";+}+.breadcrumb > .active {+ color: #777;+}+.pagination {+ display: inline-block;+ padding-left: 0;+ margin: 20px 0;+ border-radius: 4px;+}+.pagination > li {+ display: inline;+}+.pagination > li > a,+.pagination > li > span {+ position: relative;+ float: left;+ padding: 6px 12px;+ margin-left: -1px;+ line-height: 1.42857143;+ color: #428bca;+ text-decoration: none;+ background-color: #fff;+ border: 1px solid #ddd;+}+.pagination > li:first-child > a,+.pagination > li:first-child > span {+ margin-left: 0;+ border-top-left-radius: 4px;+ border-bottom-left-radius: 4px;+}+.pagination > li:last-child > a,+.pagination > li:last-child > span {+ border-top-right-radius: 4px;+ border-bottom-right-radius: 4px;+}+.pagination > li > a:hover,+.pagination > li > span:hover,+.pagination > li > a:focus,+.pagination > li > span:focus {+ color: #2a6496;+ background-color: #eee;+ border-color: #ddd;+}+.pagination > .active > a,+.pagination > .active > span,+.pagination > .active > a:hover,+.pagination > .active > span:hover,+.pagination > .active > a:focus,+.pagination > .active > span:focus {+ z-index: 2;+ color: #fff;+ cursor: default;+ background-color: #428bca;+ border-color: #428bca;+}+.pagination > .disabled > span,+.pagination > .disabled > span:hover,+.pagination > .disabled > span:focus,+.pagination > .disabled > a,+.pagination > .disabled > a:hover,+.pagination > .disabled > a:focus {+ color: #777;+ cursor: not-allowed;+ background-color: #fff;+ border-color: #ddd;+}+.pagination-lg > li > a,+.pagination-lg > li > span {+ padding: 10px 16px;+ font-size: 18px;+}+.pagination-lg > li:first-child > a,+.pagination-lg > li:first-child > span {+ border-top-left-radius: 6px;+ border-bottom-left-radius: 6px;+}+.pagination-lg > li:last-child > a,+.pagination-lg > li:last-child > span {+ border-top-right-radius: 6px;+ border-bottom-right-radius: 6px;+}+.pagination-sm > li > a,+.pagination-sm > li > span {+ padding: 5px 10px;+ font-size: 12px;+}+.pagination-sm > li:first-child > a,+.pagination-sm > li:first-child > span {+ border-top-left-radius: 3px;+ border-bottom-left-radius: 3px;+}+.pagination-sm > li:last-child > a,+.pagination-sm > li:last-child > span {+ border-top-right-radius: 3px;+ border-bottom-right-radius: 3px;+}+.pager {+ padding-left: 0;+ margin: 20px 0;+ text-align: center;+ list-style: none;+}+.pager li {+ display: inline;+}+.pager li > a,+.pager li > span {+ display: inline-block;+ padding: 5px 14px;+ background-color: #fff;+ border: 1px solid #ddd;+ border-radius: 15px;+}+.pager li > a:hover,+.pager li > a:focus {+ text-decoration: none;+ background-color: #eee;+}+.pager .next > a,+.pager .next > span {+ float: right;+}+.pager .previous > a,+.pager .previous > span {+ float: left;+}+.pager .disabled > a,+.pager .disabled > a:hover,+.pager .disabled > a:focus,+.pager .disabled > span {+ color: #777;+ cursor: not-allowed;+ background-color: #fff;+}+.label {+ display: inline;+ padding: .2em .6em .3em;+ font-size: 75%;+ font-weight: bold;+ line-height: 1;+ color: #fff;+ text-align: center;+ white-space: nowrap;+ vertical-align: baseline;+ border-radius: .25em;+}+a.label:hover,+a.label:focus {+ color: #fff;+ text-decoration: none;+ cursor: pointer;+}+.label:empty {+ display: none;+}+.btn .label {+ position: relative;+ top: -1px;+}+.label-default {+ background-color: #777;+}+.label-default[href]:hover,+.label-default[href]:focus {+ background-color: #5e5e5e;+}+.label-primary {+ background-color: #428bca;+}+.label-primary[href]:hover,+.label-primary[href]:focus {+ background-color: #3071a9;+}+.label-success {+ background-color: #5cb85c;+}+.label-success[href]:hover,+.label-success[href]:focus {+ background-color: #449d44;+}+.label-info {+ background-color: #5bc0de;+}+.label-info[href]:hover,+.label-info[href]:focus {+ background-color: #31b0d5;+}+.label-warning {+ background-color: #f0ad4e;+}+.label-warning[href]:hover,+.label-warning[href]:focus {+ background-color: #ec971f;+}+.label-danger {+ background-color: #d9534f;+}+.label-danger[href]:hover,+.label-danger[href]:focus {+ background-color: #c9302c;+}+.badge {+ display: inline-block;+ min-width: 10px;+ padding: 3px 7px;+ font-size: 12px;+ font-weight: bold;+ line-height: 1;+ color: #fff;+ text-align: center;+ white-space: nowrap;+ vertical-align: baseline;+ background-color: #777;+ border-radius: 10px;+}+.badge:empty {+ display: none;+}+.btn .badge {+ position: relative;+ top: -1px;+}+.btn-xs .badge {+ top: 0;+ padding: 1px 5px;+}+a.badge:hover,+a.badge:focus {+ color: #fff;+ text-decoration: none;+ cursor: pointer;+}+a.list-group-item.active > .badge,+.nav-pills > .active > a > .badge {+ color: #428bca;+ background-color: #fff;+}+.nav-pills > li > a > .badge {+ margin-left: 3px;+}+.jumbotron {+ padding: 30px;+ margin-bottom: 30px;+ color: inherit;+ background-color: #eee;+}+.jumbotron h1,+.jumbotron .h1 {+ color: inherit;+}+.jumbotron p {+ margin-bottom: 15px;+ font-size: 21px;+ font-weight: 200;+}+.jumbotron > hr {+ border-top-color: #d5d5d5;+}+.container .jumbotron {+ border-radius: 6px;+}+.jumbotron .container {+ max-width: 100%;+}+@media screen and (min-width: 768px) {+ .jumbotron {+ padding-top: 48px;+ padding-bottom: 48px;+ }+ .container .jumbotron {+ padding-right: 60px;+ padding-left: 60px;+ }+ .jumbotron h1,+ .jumbotron .h1 {+ font-size: 63px;+ }+}+.thumbnail {+ display: block;+ padding: 4px;+ margin-bottom: 20px;+ line-height: 1.42857143;+ background-color: #fff;+ border: 1px solid #ddd;+ border-radius: 4px;+ -webkit-transition: all .2s ease-in-out;+ -o-transition: all .2s ease-in-out;+ transition: all .2s ease-in-out;+}+.thumbnail > img,+.thumbnail a > img {+ margin-right: auto;+ margin-left: auto;+}+a.thumbnail:hover,+a.thumbnail:focus,+a.thumbnail.active {+ border-color: #428bca;+}+.thumbnail .caption {+ padding: 9px;+ color: #333;+}+.alert {+ padding: 15px;+ margin-bottom: 20px;+ border: 1px solid transparent;+ border-radius: 4px;+}+.alert h4 {+ margin-top: 0;+ color: inherit;+}+.alert .alert-link {+ font-weight: bold;+}+.alert > p,+.alert > ul {+ margin-bottom: 0;+}+.alert > p + p {+ margin-top: 5px;+}+.alert-dismissable,+.alert-dismissible {+ padding-right: 35px;+}+.alert-dismissable .close,+.alert-dismissible .close {+ position: relative;+ top: -2px;+ right: -21px;+ color: inherit;+}+.alert-success {+ color: #3c763d;+ background-color: #dff0d8;+ border-color: #d6e9c6;+}+.alert-success hr {+ border-top-color: #c9e2b3;+}+.alert-success .alert-link {+ color: #2b542c;+}+.alert-info {+ color: #31708f;+ background-color: #d9edf7;+ border-color: #bce8f1;+}+.alert-info hr {+ border-top-color: #a6e1ec;+}+.alert-info .alert-link {+ color: #245269;+}+.alert-warning {+ color: #8a6d3b;+ background-color: #fcf8e3;+ border-color: #faebcc;+}+.alert-warning hr {+ border-top-color: #f7e1b5;+}+.alert-warning .alert-link {+ color: #66512c;+}+.alert-danger {+ color: #a94442;+ background-color: #f2dede;+ border-color: #ebccd1;+}+.alert-danger hr {+ border-top-color: #e4b9c0;+}+.alert-danger .alert-link {+ color: #843534;+}+@-webkit-keyframes progress-bar-stripes {+ from {+ background-position: 40px 0;+ }+ to {+ background-position: 0 0;+ }+}+@-o-keyframes progress-bar-stripes {+ from {+ background-position: 40px 0;+ }+ to {+ background-position: 0 0;+ }+}+@keyframes progress-bar-stripes {+ from {+ background-position: 40px 0;+ }+ to {+ background-position: 0 0;+ }+}+.progress {+ height: 20px;+ margin-bottom: 20px;+ overflow: hidden;+ background-color: #f5f5f5;+ border-radius: 4px;+ -webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, .1);+ box-shadow: inset 0 1px 2px rgba(0, 0, 0, .1);+}+.progress-bar {+ float: left;+ width: 0;+ height: 100%;+ font-size: 12px;+ line-height: 20px;+ color: #fff;+ text-align: center;+ background-color: #428bca;+ -webkit-box-shadow: inset 0 -1px 0 rgba(0, 0, 0, .15);+ box-shadow: inset 0 -1px 0 rgba(0, 0, 0, .15);+ -webkit-transition: width .6s ease;+ -o-transition: width .6s ease;+ transition: width .6s ease;+}+.progress-striped .progress-bar,+.progress-bar-striped {+ background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);+ background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);+ background-image: linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);+ -webkit-background-size: 40px 40px;+ background-size: 40px 40px;+}+.progress.active .progress-bar,+.progress-bar.active {+ -webkit-animation: progress-bar-stripes 2s linear infinite;+ -o-animation: progress-bar-stripes 2s linear infinite;+ animation: progress-bar-stripes 2s linear infinite;+}+.progress-bar[aria-valuenow="1"],+.progress-bar[aria-valuenow="2"] {+ min-width: 30px;+}+.progress-bar[aria-valuenow="0"] {+ min-width: 30px;+ color: #777;+ background-color: transparent;+ background-image: none;+ -webkit-box-shadow: none;+ box-shadow: none;+}+.progress-bar-success {+ background-color: #5cb85c;+}+.progress-striped .progress-bar-success {+ background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);+ background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);+ background-image: linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);+}+.progress-bar-info {+ background-color: #5bc0de;+}+.progress-striped .progress-bar-info {+ background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);+ background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);+ background-image: linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);+}+.progress-bar-warning {+ background-color: #f0ad4e;+}+.progress-striped .progress-bar-warning {+ background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);+ background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);+ background-image: linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);+}+.progress-bar-danger {+ background-color: #d9534f;+}+.progress-striped .progress-bar-danger {+ background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);+ background-image: -o-linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);+ background-image: linear-gradient(45deg, rgba(255, 255, 255, .15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%, transparent 75%, transparent);+}+.media,+.media-body {+ overflow: hidden;+ zoom: 1;+}+.media,+.media .media {+ margin-top: 15px;+}+.media:first-child {+ margin-top: 0;+}+.media-object {+ display: block;+}+.media-heading {+ margin: 0 0 5px;+}+.media > .pull-left {+ margin-right: 10px;+}+.media > .pull-right {+ margin-left: 10px;+}+.media-list {+ padding-left: 0;+ list-style: none;+}+.list-group {+ padding-left: 0;+ margin-bottom: 20px;+}+.list-group-item {+ position: relative;+ display: block;+ padding: 10px 15px;+ margin-bottom: -1px;+ background-color: #fff;+ border: 1px solid #ddd;+}+.list-group-item:first-child {+ border-top-left-radius: 4px;+ border-top-right-radius: 4px;+}+.list-group-item:last-child {+ margin-bottom: 0;+ border-bottom-right-radius: 4px;+ border-bottom-left-radius: 4px;+}+.list-group-item > .badge {+ float: right;+}+.list-group-item > .badge + .badge {+ margin-right: 5px;+}+a.list-group-item {+ color: #555;+}+a.list-group-item .list-group-item-heading {+ color: #333;+}+a.list-group-item:hover,+a.list-group-item:focus {+ color: #555;+ text-decoration: none;+ background-color: #f5f5f5;+}+.list-group-item.disabled,+.list-group-item.disabled:hover,+.list-group-item.disabled:focus {+ color: #777;+ background-color: #eee;+}+.list-group-item.disabled .list-group-item-heading,+.list-group-item.disabled:hover .list-group-item-heading,+.list-group-item.disabled:focus .list-group-item-heading {+ color: inherit;+}+.list-group-item.disabled .list-group-item-text,+.list-group-item.disabled:hover .list-group-item-text,+.list-group-item.disabled:focus .list-group-item-text {+ color: #777;+}+.list-group-item.active,+.list-group-item.active:hover,+.list-group-item.active:focus {+ z-index: 2;+ color: #fff;+ background-color: #428bca;+ border-color: #428bca;+}+.list-group-item.active .list-group-item-heading,+.list-group-item.active:hover .list-group-item-heading,+.list-group-item.active:focus .list-group-item-heading,+.list-group-item.active .list-group-item-heading > small,+.list-group-item.active:hover .list-group-item-heading > small,+.list-group-item.active:focus .list-group-item-heading > small,+.list-group-item.active .list-group-item-heading > .small,+.list-group-item.active:hover .list-group-item-heading > .small,+.list-group-item.active:focus .list-group-item-heading > .small {+ color: inherit;+}+.list-group-item.active .list-group-item-text,+.list-group-item.active:hover .list-group-item-text,+.list-group-item.active:focus .list-group-item-text {+ color: #e1edf7;+}+.list-group-item-success {+ color: #3c763d;+ background-color: #dff0d8;+}+a.list-group-item-success {+ color: #3c763d;+}+a.list-group-item-success .list-group-item-heading {+ color: inherit;+}+a.list-group-item-success:hover,+a.list-group-item-success:focus {+ color: #3c763d;+ background-color: #d0e9c6;+}+a.list-group-item-success.active,+a.list-group-item-success.active:hover,+a.list-group-item-success.active:focus {+ color: #fff;+ background-color: #3c763d;+ border-color: #3c763d;+}+.list-group-item-info {+ color: #31708f;+ background-color: #d9edf7;+}+a.list-group-item-info {+ color: #31708f;+}+a.list-group-item-info .list-group-item-heading {+ color: inherit;+}+a.list-group-item-info:hover,+a.list-group-item-info:focus {+ color: #31708f;+ background-color: #c4e3f3;+}+a.list-group-item-info.active,+a.list-group-item-info.active:hover,+a.list-group-item-info.active:focus {+ color: #fff;+ background-color: #31708f;+ border-color: #31708f;+}+.list-group-item-warning {+ color: #8a6d3b;+ background-color: #fcf8e3;+}+a.list-group-item-warning {+ color: #8a6d3b;+}+a.list-group-item-warning .list-group-item-heading {+ color: inherit;+}+a.list-group-item-warning:hover,+a.list-group-item-warning:focus {+ color: #8a6d3b;+ background-color: #faf2cc;+}+a.list-group-item-warning.active,+a.list-group-item-warning.active:hover,+a.list-group-item-warning.active:focus {+ color: #fff;+ background-color: #8a6d3b;+ border-color: #8a6d3b;+}+.list-group-item-danger {+ color: #a94442;+ background-color: #f2dede;+}+a.list-group-item-danger {+ color: #a94442;+}+a.list-group-item-danger .list-group-item-heading {+ color: inherit;+}+a.list-group-item-danger:hover,+a.list-group-item-danger:focus {+ color: #a94442;+ background-color: #ebcccc;+}+a.list-group-item-danger.active,+a.list-group-item-danger.active:hover,+a.list-group-item-danger.active:focus {+ color: #fff;+ background-color: #a94442;+ border-color: #a94442;+}+.list-group-item-heading {+ margin-top: 0;+ margin-bottom: 5px;+}+.list-group-item-text {+ margin-bottom: 0;+ line-height: 1.3;+}+.panel {+ margin-bottom: 20px;+ background-color: #fff;+ border: 1px solid transparent;+ border-radius: 4px;+ -webkit-box-shadow: 0 1px 1px rgba(0, 0, 0, .05);+ box-shadow: 0 1px 1px rgba(0, 0, 0, .05);+}+.panel-body {+ padding: 15px;+}+.panel-heading {+ padding: 10px 15px;+ border-bottom: 1px solid transparent;+ border-top-left-radius: 3px;+ border-top-right-radius: 3px;+}+.panel-heading > .dropdown .dropdown-toggle {+ color: inherit;+}+.panel-title {+ margin-top: 0;+ margin-bottom: 0;+ font-size: 16px;+ color: inherit;+}+.panel-title > a {+ color: inherit;+}+.panel-footer {+ padding: 10px 15px;+ background-color: #f5f5f5;+ border-top: 1px solid #ddd;+ border-bottom-right-radius: 3px;+ border-bottom-left-radius: 3px;+}+.panel > .list-group {+ margin-bottom: 0;+}+.panel > .list-group .list-group-item {+ border-width: 1px 0;+ border-radius: 0;+}+.panel > .list-group:first-child .list-group-item:first-child {+ border-top: 0;+ border-top-left-radius: 3px;+ border-top-right-radius: 3px;+}+.panel > .list-group:last-child .list-group-item:last-child {+ border-bottom: 0;+ border-bottom-right-radius: 3px;+ border-bottom-left-radius: 3px;+}+.panel-heading + .list-group .list-group-item:first-child {+ border-top-width: 0;+}+.list-group + .panel-footer {+ border-top-width: 0;+}+.panel > .table,+.panel > .table-responsive > .table,+.panel > .panel-collapse > .table {+ margin-bottom: 0;+}+.panel > .table:first-child,+.panel > .table-responsive:first-child > .table:first-child {+ border-top-left-radius: 3px;+ border-top-right-radius: 3px;+}+.panel > .table:first-child > thead:first-child > tr:first-child td:first-child,+.panel > .table-responsive:first-child > .table:first-child > thead:first-child > tr:first-child td:first-child,+.panel > .table:first-child > tbody:first-child > tr:first-child td:first-child,+.panel > .table-responsive:first-child > .table:first-child > tbody:first-child > tr:first-child td:first-child,+.panel > .table:first-child > thead:first-child > tr:first-child th:first-child,+.panel > .table-responsive:first-child > .table:first-child > thead:first-child > tr:first-child th:first-child,+.panel > .table:first-child > tbody:first-child > tr:first-child th:first-child,+.panel > .table-responsive:first-child > .table:first-child > tbody:first-child > tr:first-child th:first-child {+ border-top-left-radius: 3px;+}+.panel > .table:first-child > thead:first-child > tr:first-child td:last-child,+.panel > .table-responsive:first-child > .table:first-child > thead:first-child > tr:first-child td:last-child,+.panel > .table:first-child > tbody:first-child > tr:first-child td:last-child,+.panel > .table-responsive:first-child > .table:first-child > tbody:first-child > tr:first-child td:last-child,+.panel > .table:first-child > thead:first-child > tr:first-child th:last-child,+.panel > .table-responsive:first-child > .table:first-child > thead:first-child > tr:first-child th:last-child,+.panel > .table:first-child > tbody:first-child > tr:first-child th:last-child,+.panel > .table-responsive:first-child > .table:first-child > tbody:first-child > tr:first-child th:last-child {+ border-top-right-radius: 3px;+}+.panel > .table:last-child,+.panel > .table-responsive:last-child > .table:last-child {+ border-bottom-right-radius: 3px;+ border-bottom-left-radius: 3px;+}+.panel > .table:last-child > tbody:last-child > tr:last-child td:first-child,+.panel > .table-responsive:last-child > .table:last-child > tbody:last-child > tr:last-child td:first-child,+.panel > .table:last-child > tfoot:last-child > tr:last-child td:first-child,+.panel > .table-responsive:last-child > .table:last-child > tfoot:last-child > tr:last-child td:first-child,+.panel > .table:last-child > tbody:last-child > tr:last-child th:first-child,+.panel > .table-responsive:last-child > .table:last-child > tbody:last-child > tr:last-child th:first-child,+.panel > .table:last-child > tfoot:last-child > tr:last-child th:first-child,+.panel > .table-responsive:last-child > .table:last-child > tfoot:last-child > tr:last-child th:first-child {+ border-bottom-left-radius: 3px;+}+.panel > .table:last-child > tbody:last-child > tr:last-child td:last-child,+.panel > .table-responsive:last-child > .table:last-child > tbody:last-child > tr:last-child td:last-child,+.panel > .table:last-child > tfoot:last-child > tr:last-child td:last-child,+.panel > .table-responsive:last-child > .table:last-child > tfoot:last-child > tr:last-child td:last-child,+.panel > .table:last-child > tbody:last-child > tr:last-child th:last-child,+.panel > .table-responsive:last-child > .table:last-child > tbody:last-child > tr:last-child th:last-child,+.panel > .table:last-child > tfoot:last-child > tr:last-child th:last-child,+.panel > .table-responsive:last-child > .table:last-child > tfoot:last-child > tr:last-child th:last-child {+ border-bottom-right-radius: 3px;+}+.panel > .panel-body + .table,+.panel > .panel-body + .table-responsive {+ border-top: 1px solid #ddd;+}+.panel > .table > tbody:first-child > tr:first-child th,+.panel > .table > tbody:first-child > tr:first-child td {+ border-top: 0;+}+.panel > .table-bordered,+.panel > .table-responsive > .table-bordered {+ border: 0;+}+.panel > .table-bordered > thead > tr > th:first-child,+.panel > .table-responsive > .table-bordered > thead > tr > th:first-child,+.panel > .table-bordered > tbody > tr > th:first-child,+.panel > .table-responsive > .table-bordered > tbody > tr > th:first-child,+.panel > .table-bordered > tfoot > tr > th:first-child,+.panel > .table-responsive > .table-bordered > tfoot > tr > th:first-child,+.panel > .table-bordered > thead > tr > td:first-child,+.panel > .table-responsive > .table-bordered > thead > tr > td:first-child,+.panel > .table-bordered > tbody > tr > td:first-child,+.panel > .table-responsive > .table-bordered > tbody > tr > td:first-child,+.panel > .table-bordered > tfoot > tr > td:first-child,+.panel > .table-responsive > .table-bordered > tfoot > tr > td:first-child {+ border-left: 0;+}+.panel > .table-bordered > thead > tr > th:last-child,+.panel > .table-responsive > .table-bordered > thead > tr > th:last-child,+.panel > .table-bordered > tbody > tr > th:last-child,+.panel > .table-responsive > .table-bordered > tbody > tr > th:last-child,+.panel > .table-bordered > tfoot > tr > th:last-child,+.panel > .table-responsive > .table-bordered > tfoot > tr > th:last-child,+.panel > .table-bordered > thead > tr > td:last-child,+.panel > .table-responsive > .table-bordered > thead > tr > td:last-child,+.panel > .table-bordered > tbody > tr > td:last-child,+.panel > .table-responsive > .table-bordered > tbody > tr > td:last-child,+.panel > .table-bordered > tfoot > tr > td:last-child,+.panel > .table-responsive > .table-bordered > tfoot > tr > td:last-child {+ border-right: 0;+}+.panel > .table-bordered > thead > tr:first-child > td,+.panel > .table-responsive > .table-bordered > thead > tr:first-child > td,+.panel > .table-bordered > tbody > tr:first-child > td,+.panel > .table-responsive > .table-bordered > tbody > tr:first-child > td,+.panel > .table-bordered > thead > tr:first-child > th,+.panel > .table-responsive > .table-bordered > thead > tr:first-child > th,+.panel > .table-bordered > tbody > tr:first-child > th,+.panel > .table-responsive > .table-bordered > tbody > tr:first-child > th {+ border-bottom: 0;+}+.panel > .table-bordered > tbody > tr:last-child > td,+.panel > .table-responsive > .table-bordered > tbody > tr:last-child > td,+.panel > .table-bordered > tfoot > tr:last-child > td,+.panel > .table-responsive > .table-bordered > tfoot > tr:last-child > td,+.panel > .table-bordered > tbody > tr:last-child > th,+.panel > .table-responsive > .table-bordered > tbody > tr:last-child > th,+.panel > .table-bordered > tfoot > tr:last-child > th,+.panel > .table-responsive > .table-bordered > tfoot > tr:last-child > th {+ border-bottom: 0;+}+.panel > .table-responsive {+ margin-bottom: 0;+ border: 0;+}+.panel-group {+ margin-bottom: 20px;+}+.panel-group .panel {+ margin-bottom: 0;+ border-radius: 4px;+}+.panel-group .panel + .panel {+ margin-top: 5px;+}+.panel-group .panel-heading {+ border-bottom: 0;+}+.panel-group .panel-heading + .panel-collapse > .panel-body {+ border-top: 1px solid #ddd;+}+.panel-group .panel-footer {+ border-top: 0;+}+.panel-group .panel-footer + .panel-collapse .panel-body {+ border-bottom: 1px solid #ddd;+}+.panel-default {+ border-color: #ddd;+}+.panel-default > .panel-heading {+ color: #333;+ background-color: #f5f5f5;+ border-color: #ddd;+}+.panel-default > .panel-heading + .panel-collapse > .panel-body {+ border-top-color: #ddd;+}+.panel-default > .panel-heading .badge {+ color: #f5f5f5;+ background-color: #333;+}+.panel-default > .panel-footer + .panel-collapse > .panel-body {+ border-bottom-color: #ddd;+}+.panel-primary {+ border-color: #428bca;+}+.panel-primary > .panel-heading {+ color: #fff;+ background-color: #428bca;+ border-color: #428bca;+}+.panel-primary > .panel-heading + .panel-collapse > .panel-body {+ border-top-color: #428bca;+}+.panel-primary > .panel-heading .badge {+ color: #428bca;+ background-color: #fff;+}+.panel-primary > .panel-footer + .panel-collapse > .panel-body {+ border-bottom-color: #428bca;+}+.panel-success {+ border-color: #d6e9c6;+}+.panel-success > .panel-heading {+ color: #3c763d;+ background-color: #dff0d8;+ border-color: #d6e9c6;+}+.panel-success > .panel-heading + .panel-collapse > .panel-body {+ border-top-color: #d6e9c6;+}+.panel-success > .panel-heading .badge {+ color: #dff0d8;+ background-color: #3c763d;+}+.panel-success > .panel-footer + .panel-collapse > .panel-body {+ border-bottom-color: #d6e9c6;+}+.panel-info {+ border-color: #bce8f1;+}+.panel-info > .panel-heading {+ color: #31708f;+ background-color: #d9edf7;+ border-color: #bce8f1;+}+.panel-info > .panel-heading + .panel-collapse > .panel-body {+ border-top-color: #bce8f1;+}+.panel-info > .panel-heading .badge {+ color: #d9edf7;+ background-color: #31708f;+}+.panel-info > .panel-footer + .panel-collapse > .panel-body {+ border-bottom-color: #bce8f1;+}+.panel-warning {+ border-color: #faebcc;+}+.panel-warning > .panel-heading {+ color: #8a6d3b;+ background-color: #fcf8e3;+ border-color: #faebcc;+}+.panel-warning > .panel-heading + .panel-collapse > .panel-body {+ border-top-color: #faebcc;+}+.panel-warning > .panel-heading .badge {+ color: #fcf8e3;+ background-color: #8a6d3b;+}+.panel-warning > .panel-footer + .panel-collapse > .panel-body {+ border-bottom-color: #faebcc;+}+.panel-danger {+ border-color: #ebccd1;+}+.panel-danger > .panel-heading {+ color: #a94442;+ background-color: #f2dede;+ border-color: #ebccd1;+}+.panel-danger > .panel-heading + .panel-collapse > .panel-body {+ border-top-color: #ebccd1;+}+.panel-danger > .panel-heading .badge {+ color: #f2dede;+ background-color: #a94442;+}+.panel-danger > .panel-footer + .panel-collapse > .panel-body {+ border-bottom-color: #ebccd1;+}+.embed-responsive {+ position: relative;+ display: block;+ height: 0;+ padding: 0;+ overflow: hidden;+}+.embed-responsive .embed-responsive-item,+.embed-responsive iframe,+.embed-responsive embed,+.embed-responsive object {+ position: absolute;+ top: 0;+ bottom: 0;+ left: 0;+ width: 100%;+ height: 100%;+ border: 0;+}+.embed-responsive.embed-responsive-16by9 {+ padding-bottom: 56.25%;+}+.embed-responsive.embed-responsive-4by3 {+ padding-bottom: 75%;+}+.well {+ min-height: 20px;+ padding: 19px;+ margin-bottom: 20px;+ background-color: #f5f5f5;+ border: 1px solid #e3e3e3;+ border-radius: 4px;+ -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .05);+ box-shadow: inset 0 1px 1px rgba(0, 0, 0, .05);+}+.well blockquote {+ border-color: #ddd;+ border-color: rgba(0, 0, 0, .15);+}+.well-lg {+ padding: 24px;+ border-radius: 6px;+}+.well-sm {+ padding: 9px;+ border-radius: 3px;+}+.close {+ float: right;+ font-size: 21px;+ font-weight: bold;+ line-height: 1;+ color: #000;+ text-shadow: 0 1px 0 #fff;+ filter: alpha(opacity=20);+ opacity: .2;+}+.close:hover,+.close:focus {+ color: #000;+ text-decoration: none;+ cursor: pointer;+ filter: alpha(opacity=50);+ opacity: .5;+}+button.close {+ -webkit-appearance: none;+ padding: 0;+ cursor: pointer;+ background: transparent;+ border: 0;+}+.modal-open {+ overflow: hidden;+}+.modal {+ position: fixed;+ top: 0;+ right: 0;+ bottom: 0;+ left: 0;+ z-index: 1050;+ display: none;+ overflow: hidden;+ -webkit-overflow-scrolling: touch;+ outline: 0;+}+.modal.fade .modal-dialog {+ -webkit-transition: -webkit-transform .3s ease-out;+ -o-transition: -o-transform .3s ease-out;+ transition: transform .3s ease-out;+ -webkit-transform: translate3d(0, -25%, 0);+ -o-transform: translate3d(0, -25%, 0);+ transform: translate3d(0, -25%, 0);+}+.modal.in .modal-dialog {+ -webkit-transform: translate3d(0, 0, 0);+ -o-transform: translate3d(0, 0, 0);+ transform: translate3d(0, 0, 0);+}+.modal-open .modal {+ overflow-x: hidden;+ overflow-y: auto;+}+.modal-dialog {+ position: relative;+ width: auto;+ margin: 10px;+}+.modal-content {+ position: relative;+ background-color: #fff;+ -webkit-background-clip: padding-box;+ background-clip: padding-box;+ border: 1px solid #999;+ border: 1px solid rgba(0, 0, 0, .2);+ border-radius: 6px;+ outline: 0;+ -webkit-box-shadow: 0 3px 9px rgba(0, 0, 0, .5);+ box-shadow: 0 3px 9px rgba(0, 0, 0, .5);+}+.modal-backdrop {+ position: fixed;+ top: 0;+ right: 0;+ bottom: 0;+ left: 0;+ z-index: 1040;+ background-color: #000;+}+.modal-backdrop.fade {+ filter: alpha(opacity=0);+ opacity: 0;+}+.modal-backdrop.in {+ filter: alpha(opacity=50);+ opacity: .5;+}+.modal-header {+ min-height: 16.42857143px;+ padding: 15px;+ border-bottom: 1px solid #e5e5e5;+}+.modal-header .close {+ margin-top: -2px;+}+.modal-title {+ margin: 0;+ line-height: 1.42857143;+}+.modal-body {+ position: relative;+ padding: 15px;+}+.modal-footer {+ padding: 15px;+ text-align: right;+ border-top: 1px solid #e5e5e5;+}+.modal-footer .btn + .btn {+ margin-bottom: 0;+ margin-left: 5px;+}+.modal-footer .btn-group .btn + .btn {+ margin-left: -1px;+}+.modal-footer .btn-block + .btn-block {+ margin-left: 0;+}+.modal-scrollbar-measure {+ position: absolute;+ top: -9999px;+ width: 50px;+ height: 50px;+ overflow: scroll;+}+@media (min-width: 768px) {+ .modal-dialog {+ width: 600px;+ margin: 30px auto;+ }+ .modal-content {+ -webkit-box-shadow: 0 5px 15px rgba(0, 0, 0, .5);+ box-shadow: 0 5px 15px rgba(0, 0, 0, .5);+ }+ .modal-sm {+ width: 300px;+ }+}+@media (min-width: 992px) {+ .modal-lg {+ width: 900px;+ }+}+.tooltip {+ position: absolute;+ z-index: 1070;+ display: block;+ font-size: 12px;+ line-height: 1.4;+ visibility: visible;+ filter: alpha(opacity=0);+ opacity: 0;+}+.tooltip.in {+ filter: alpha(opacity=90);+ opacity: .9;+}+.tooltip.top {+ padding: 5px 0;+ margin-top: -3px;+}+.tooltip.right {+ padding: 0 5px;+ margin-left: 3px;+}+.tooltip.bottom {+ padding: 5px 0;+ margin-top: 3px;+}+.tooltip.left {+ padding: 0 5px;+ margin-left: -3px;+}+.tooltip-inner {+ max-width: 200px;+ padding: 3px 8px;+ color: #fff;+ text-align: center;+ text-decoration: none;+ background-color: #000;+ border-radius: 4px;+}+.tooltip-arrow {+ position: absolute;+ width: 0;+ height: 0;+ border-color: transparent;+ border-style: solid;+}+.tooltip.top .tooltip-arrow {+ bottom: 0;+ left: 50%;+ margin-left: -5px;+ border-width: 5px 5px 0;+ border-top-color: #000;+}+.tooltip.top-left .tooltip-arrow {+ bottom: 0;+ left: 5px;+ border-width: 5px 5px 0;+ border-top-color: #000;+}+.tooltip.top-right .tooltip-arrow {+ right: 5px;+ bottom: 0;+ border-width: 5px 5px 0;+ border-top-color: #000;+}+.tooltip.right .tooltip-arrow {+ top: 50%;+ left: 0;+ margin-top: -5px;+ border-width: 5px 5px 5px 0;+ border-right-color: #000;+}+.tooltip.left .tooltip-arrow {+ top: 50%;+ right: 0;+ margin-top: -5px;+ border-width: 5px 0 5px 5px;+ border-left-color: #000;+}+.tooltip.bottom .tooltip-arrow {+ top: 0;+ left: 50%;+ margin-left: -5px;+ border-width: 0 5px 5px;+ border-bottom-color: #000;+}+.tooltip.bottom-left .tooltip-arrow {+ top: 0;+ left: 5px;+ border-width: 0 5px 5px;+ border-bottom-color: #000;+}+.tooltip.bottom-right .tooltip-arrow {+ top: 0;+ right: 5px;+ border-width: 0 5px 5px;+ border-bottom-color: #000;+}+.popover {+ position: absolute;+ top: 0;+ left: 0;+ z-index: 1060;+ display: none;+ max-width: 276px;+ padding: 1px;+ text-align: left;+ white-space: normal;+ background-color: #fff;+ -webkit-background-clip: padding-box;+ background-clip: padding-box;+ border: 1px solid #ccc;+ border: 1px solid rgba(0, 0, 0, .2);+ border-radius: 6px;+ -webkit-box-shadow: 0 5px 10px rgba(0, 0, 0, .2);+ box-shadow: 0 5px 10px rgba(0, 0, 0, .2);+}+.popover.top {+ margin-top: -10px;+}+.popover.right {+ margin-left: 10px;+}+.popover.bottom {+ margin-top: 10px;+}+.popover.left {+ margin-left: -10px;+}+.popover-title {+ padding: 8px 14px;+ margin: 0;+ font-size: 14px;+ font-weight: normal;+ line-height: 18px;+ background-color: #f7f7f7;+ border-bottom: 1px solid #ebebeb;+ border-radius: 5px 5px 0 0;+}+.popover-content {+ padding: 9px 14px;+}+.popover > .arrow,+.popover > .arrow:after {+ position: absolute;+ display: block;+ width: 0;+ height: 0;+ border-color: transparent;+ border-style: solid;+}+.popover > .arrow {+ border-width: 11px;+}+.popover > .arrow:after {+ content: "";+ border-width: 10px;+}+.popover.top > .arrow {+ bottom: -11px;+ left: 50%;+ margin-left: -11px;+ border-top-color: #999;+ border-top-color: rgba(0, 0, 0, .25);+ border-bottom-width: 0;+}+.popover.top > .arrow:after {+ bottom: 1px;+ margin-left: -10px;+ content: " ";+ border-top-color: #fff;+ border-bottom-width: 0;+}+.popover.right > .arrow {+ top: 50%;+ left: -11px;+ margin-top: -11px;+ border-right-color: #999;+ border-right-color: rgba(0, 0, 0, .25);+ border-left-width: 0;+}+.popover.right > .arrow:after {+ bottom: -10px;+ left: 1px;+ content: " ";+ border-right-color: #fff;+ border-left-width: 0;+}+.popover.bottom > .arrow {+ top: -11px;+ left: 50%;+ margin-left: -11px;+ border-top-width: 0;+ border-bottom-color: #999;+ border-bottom-color: rgba(0, 0, 0, .25);+}+.popover.bottom > .arrow:after {+ top: 1px;+ margin-left: -10px;+ content: " ";+ border-top-width: 0;+ border-bottom-color: #fff;+}+.popover.left > .arrow {+ top: 50%;+ right: -11px;+ margin-top: -11px;+ border-right-width: 0;+ border-left-color: #999;+ border-left-color: rgba(0, 0, 0, .25);+}+.popover.left > .arrow:after {+ right: 1px;+ bottom: -10px;+ content: " ";+ border-right-width: 0;+ border-left-color: #fff;+}+.carousel {+ position: relative;+}+.carousel-inner {+ position: relative;+ width: 100%;+ overflow: hidden;+}+.carousel-inner > .item {+ position: relative;+ display: none;+ -webkit-transition: .6s ease-in-out left;+ -o-transition: .6s ease-in-out left;+ transition: .6s ease-in-out left;+}+.carousel-inner > .item > img,+.carousel-inner > .item > a > img {+ line-height: 1;+}+.carousel-inner > .active,+.carousel-inner > .next,+.carousel-inner > .prev {+ display: block;+}+.carousel-inner > .active {+ left: 0;+}+.carousel-inner > .next,+.carousel-inner > .prev {+ position: absolute;+ top: 0;+ width: 100%;+}+.carousel-inner > .next {+ left: 100%;+}+.carousel-inner > .prev {+ left: -100%;+}+.carousel-inner > .next.left,+.carousel-inner > .prev.right {+ left: 0;+}+.carousel-inner > .active.left {+ left: -100%;+}+.carousel-inner > .active.right {+ left: 100%;+}+.carousel-control {+ position: absolute;+ top: 0;+ bottom: 0;+ left: 0;+ width: 15%;+ font-size: 20px;+ color: #fff;+ text-align: center;+ text-shadow: 0 1px 2px rgba(0, 0, 0, .6);+ filter: alpha(opacity=50);+ opacity: .5;+}+.carousel-control.left {+ background-image: -webkit-linear-gradient(left, rgba(0, 0, 0, .5) 0%, rgba(0, 0, 0, .0001) 100%);+ background-image: -o-linear-gradient(left, rgba(0, 0, 0, .5) 0%, rgba(0, 0, 0, .0001) 100%);+ background-image: -webkit-gradient(linear, left top, right top, from(rgba(0, 0, 0, .5)), to(rgba(0, 0, 0, .0001)));+ background-image: linear-gradient(to right, rgba(0, 0, 0, .5) 0%, rgba(0, 0, 0, .0001) 100%);+ filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#80000000', endColorstr='#00000000', GradientType=1);+ background-repeat: repeat-x;+}+.carousel-control.right {+ right: 0;+ left: auto;+ background-image: -webkit-linear-gradient(left, rgba(0, 0, 0, .0001) 0%, rgba(0, 0, 0, .5) 100%);+ background-image: -o-linear-gradient(left, rgba(0, 0, 0, .0001) 0%, rgba(0, 0, 0, .5) 100%);+ background-image: -webkit-gradient(linear, left top, right top, from(rgba(0, 0, 0, .0001)), to(rgba(0, 0, 0, .5)));+ background-image: linear-gradient(to right, rgba(0, 0, 0, .0001) 0%, rgba(0, 0, 0, .5) 100%);+ filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#00000000', endColorstr='#80000000', GradientType=1);+ background-repeat: repeat-x;+}+.carousel-control:hover,+.carousel-control:focus {+ color: #fff;+ text-decoration: none;+ filter: alpha(opacity=90);+ outline: 0;+ opacity: .9;+}+.carousel-control .icon-prev,+.carousel-control .icon-next,+.carousel-control .glyphicon-chevron-left,+.carousel-control .glyphicon-chevron-right {+ position: absolute;+ top: 50%;+ z-index: 5;+ display: inline-block;+}+.carousel-control .icon-prev,+.carousel-control .glyphicon-chevron-left {+ left: 50%;+ margin-left: -10px;+}+.carousel-control .icon-next,+.carousel-control .glyphicon-chevron-right {+ right: 50%;+ margin-right: -10px;+}+.carousel-control .icon-prev,+.carousel-control .icon-next {+ width: 20px;+ height: 20px;+ margin-top: -10px;+ font-family: serif;+}+.carousel-control .icon-prev:before {+ content: '\2039';+}+.carousel-control .icon-next:before {+ content: '\203a';+}+.carousel-indicators {+ position: absolute;+ bottom: 10px;+ left: 50%;+ z-index: 15;+ width: 60%;+ padding-left: 0;+ margin-left: -30%;+ text-align: center;+ list-style: none;+}+.carousel-indicators li {+ display: inline-block;+ width: 10px;+ height: 10px;+ margin: 1px;+ text-indent: -999px;+ cursor: pointer;+ background-color: #000 \9;+ background-color: rgba(0, 0, 0, 0);+ border: 1px solid #fff;+ border-radius: 10px;+}+.carousel-indicators .active {+ width: 12px;+ height: 12px;+ margin: 0;+ background-color: #fff;+}+.carousel-caption {+ position: absolute;+ right: 15%;+ bottom: 20px;+ left: 15%;+ z-index: 10;+ padding-top: 20px;+ padding-bottom: 20px;+ color: #fff;+ text-align: center;+ text-shadow: 0 1px 2px rgba(0, 0, 0, .6);+}+.carousel-caption .btn {+ text-shadow: none;+}+@media screen and (min-width: 768px) {+ .carousel-control .glyphicon-chevron-left,+ .carousel-control .glyphicon-chevron-right,+ .carousel-control .icon-prev,+ .carousel-control .icon-next {+ width: 30px;+ height: 30px;+ margin-top: -15px;+ font-size: 30px;+ }+ .carousel-control .glyphicon-chevron-left,+ .carousel-control .icon-prev {+ margin-left: -15px;+ }+ .carousel-control .glyphicon-chevron-right,+ .carousel-control .icon-next {+ margin-right: -15px;+ }+ .carousel-caption {+ right: 20%;+ left: 20%;+ padding-bottom: 30px;+ }+ .carousel-indicators {+ bottom: 20px;+ }+}+.clearfix:before,+.clearfix:after,+.dl-horizontal dd:before,+.dl-horizontal dd:after,+.container:before,+.container:after,+.container-fluid:before,+.container-fluid:after,+.row:before,+.row:after,+.form-horizontal .form-group:before,+.form-horizontal .form-group:after,+.btn-toolbar:before,+.btn-toolbar:after,+.btn-group-vertical > .btn-group:before,+.btn-group-vertical > .btn-group:after,+.nav:before,+.nav:after,+.navbar:before,+.navbar:after,+.navbar-header:before,+.navbar-header:after,+.navbar-collapse:before,+.navbar-collapse:after,+.pager:before,+.pager:after,+.panel-body:before,+.panel-body:after,+.modal-footer:before,+.modal-footer:after {+ display: table;+ content: " ";+}+.clearfix:after,+.dl-horizontal dd:after,+.container:after,+.container-fluid:after,+.row:after,+.form-horizontal .form-group:after,+.btn-toolbar:after,+.btn-group-vertical > .btn-group:after,+.nav:after,+.navbar:after,+.navbar-header:after,+.navbar-collapse:after,+.pager:after,+.panel-body:after,+.modal-footer:after {+ clear: both;+}+.center-block {+ display: block;+ margin-right: auto;+ margin-left: auto;+}+.pull-right {+ float: right !important;+}+.pull-left {+ float: left !important;+}+.hide {+ display: none !important;+}+.show {+ display: block !important;+}+.invisible {+ visibility: hidden;+}+.text-hide {+ font: 0/0 a;+ color: transparent;+ text-shadow: none;+ background-color: transparent;+ border: 0;+}+.hidden {+ display: none !important;+ visibility: hidden !important;+}+.affix {+ position: fixed;+ -webkit-transform: translate3d(0, 0, 0);+ -o-transform: translate3d(0, 0, 0);+ transform: translate3d(0, 0, 0);+}+@-ms-viewport {+ width: device-width;+}+.visible-xs,+.visible-sm,+.visible-md,+.visible-lg {+ display: none !important;+}+.visible-xs-block,+.visible-xs-inline,+.visible-xs-inline-block,+.visible-sm-block,+.visible-sm-inline,+.visible-sm-inline-block,+.visible-md-block,+.visible-md-inline,+.visible-md-inline-block,+.visible-lg-block,+.visible-lg-inline,+.visible-lg-inline-block {+ display: none !important;+}+@media (max-width: 767px) {+ .visible-xs {+ display: block !important;+ }+ table.visible-xs {+ display: table;+ }+ tr.visible-xs {+ display: table-row !important;+ }+ th.visible-xs,+ td.visible-xs {+ display: table-cell !important;+ }+}+@media (max-width: 767px) {+ .visible-xs-block {+ display: block !important;+ }+}+@media (max-width: 767px) {+ .visible-xs-inline {+ display: inline !important;+ }+}+@media (max-width: 767px) {+ .visible-xs-inline-block {+ display: inline-block !important;+ }+}+@media (min-width: 768px) and (max-width: 991px) {+ .visible-sm {+ display: block !important;+ }+ table.visible-sm {+ display: table;+ }+ tr.visible-sm {+ display: table-row !important;+ }+ th.visible-sm,+ td.visible-sm {+ display: table-cell !important;+ }+}+@media (min-width: 768px) and (max-width: 991px) {+ .visible-sm-block {+ display: block !important;+ }+}+@media (min-width: 768px) and (max-width: 991px) {+ .visible-sm-inline {+ display: inline !important;+ }+}+@media (min-width: 768px) and (max-width: 991px) {+ .visible-sm-inline-block {+ display: inline-block !important;+ }+}+@media (min-width: 992px) and (max-width: 1199px) {+ .visible-md {+ display: block !important;+ }+ table.visible-md {+ display: table;+ }+ tr.visible-md {+ display: table-row !important;+ }+ th.visible-md,+ td.visible-md {+ display: table-cell !important;+ }+}+@media (min-width: 992px) and (max-width: 1199px) {+ .visible-md-block {+ display: block !important;+ }+}+@media (min-width: 992px) and (max-width: 1199px) {+ .visible-md-inline {+ display: inline !important;+ }+}+@media (min-width: 992px) and (max-width: 1199px) {+ .visible-md-inline-block {+ display: inline-block !important;+ }+}+@media (min-width: 1200px) {+ .visible-lg {+ display: block !important;+ }+ table.visible-lg {+ display: table;+ }+ tr.visible-lg {+ display: table-row !important;+ }+ th.visible-lg,+ td.visible-lg {+ display: table-cell !important;+ }+}+@media (min-width: 1200px) {+ .visible-lg-block {+ display: block !important;+ }+}+@media (min-width: 1200px) {+ .visible-lg-inline {+ display: inline !important;+ }+}+@media (min-width: 1200px) {+ .visible-lg-inline-block {+ display: inline-block !important;+ }+}+@media (max-width: 767px) {+ .hidden-xs {+ display: none !important;+ }+}+@media (min-width: 768px) and (max-width: 991px) {+ .hidden-sm {+ display: none !important;+ }+}+@media (min-width: 992px) and (max-width: 1199px) {+ .hidden-md {+ display: none !important;+ }+}+@media (min-width: 1200px) {+ .hidden-lg {+ display: none !important;+ }+}+.visible-print {+ display: none !important;+}+@media print {+ .visible-print {+ display: block !important;+ }+ table.visible-print {+ display: table;+ }+ tr.visible-print {+ display: table-row !important;+ }+ th.visible-print,+ td.visible-print {+ display: table-cell !important;+ }+}+.visible-print-block {+ display: none !important;+}+@media print {+ .visible-print-block {+ display: block !important;+ }+}+.visible-print-inline {+ display: none !important;+}+@media print {+ .visible-print-inline {+ display: inline !important;+ }+}+.visible-print-inline-block {+ display: none !important;+}+@media print {+ .visible-print-inline-block {+ display: inline-block !important;+ }+}+@media print {+ .hidden-print {+ display: none !important;+ }+}+/*# sourceMappingURL=bootstrap.css.map */diff --git a/app/assets/stylesheets/blazer/bootstrap.css.map b/app/assets/stylesheets/blazer/bootstrap.css.mapnew file mode 100644index 00000000..bfb56168--- /dev/null+++ b/app/assets/stylesheets/blazer/bootstrap.css.map@@ -0,0 +1 @@+{"version":3,"file":"bootstrap.css","sources":["bootstrap.css","less/normalize.less","less/print.less","less/glyphicons.less","less/scaffolding.less","less/mixins/vendor-prefixes.less","less/mixins/tab-focus.less","less/mixins/image.less","less/type.less","less/mixins/text-emphasis.less","less/mixins/background-variant.less","less/mixins/text-overflow.less","less/code.less","less/grid.less","less/mixins/grid.less","less/mixins/grid-framework.less","less/tables.less","less/mixins/table-row.less","less/forms.less","less/mixins/forms.less","less/buttons.less","less/mixins/buttons.less","less/mixins/opacity.less","less/component-animations.less","less/dropdowns.less","less/mixins/nav-divider.less","less/mixins/reset-filter.less","less/button-groups.less","less/mixins/border-radius.less","less/input-groups.less","less/navs.less","less/navbar.less","less/mixins/nav-vertical-align.less","less/utilities.less","less/breadcrumbs.less","less/pagination.less","less/mixins/pagination.less","less/pager.less","less/labels.less","less/mixins/labels.less","less/badges.less","less/jumbotron.less","less/thumbnails.less","less/alerts.less","less/mixins/alerts.less","less/progress-bars.less","less/mixins/gradients.less","less/mixins/progress-bar.less","less/media.less","less/list-group.less","less/mixins/list-group.less","less/panels.less","less/mixins/panels.less","less/responsive-embed.less","less/wells.less","less/close.less","less/modals.less","less/tooltip.less","less/popovers.less","less/carousel.less","less/mixins/clearfix.less","less/mixins/center-block.less","less/mixins/hide-text.less","less/responsive-utilities.less","less/mixins/responsive-visibility.less"],"names":[],"mappings":"AAAA,6DAA4D;ACQ5D;EACE,yBAAA;EACA,4BAAA;EACA,gCAAA;EDND;ACaD;EACE,WAAA;EDXD;ACuBD;;;;;;;;;;;;EAYE,gBAAA;EDrBD;AC6BD;;;;EAIE,uBAAA;EACA,0BAAA;ED3BD;ACmCD;EACE,eAAA;EACA,WAAA;EDjCD;ACyCD;;EAEE,eAAA;EDvCD;ACiDD;EACE,yBAAA;ED/CD;ACsDD;;EAEE,YAAA;EDpDD;AC8DD;EACE,2BAAA;ED5DD;ACmED;;EAEE,mBAAA;EDjED;ACwED;EACE,oBAAA;EDtED;AC8ED;EACE,gBAAA;EACA,kBAAA;ED5ED;ACmFD;EACE,kBAAA;EACA,aAAA;EDjFD;ACwFD;EACE,gBAAA;EDtFD;AC6FD;;EAEE,gBAAA;EACA,gBAAA;EACA,oBAAA;EACA,0BAAA;ED3FD;AC8FD;EACE,aAAA;ED5FD;AC+FD;EACE,iBAAA;ED7FD;ACuGD;EACE,WAAA;EDrGD;AC4GD;EACE,kBAAA;ED1GD;ACoHD;EACE,kBAAA;EDlHD;ACyHD;EACE,8BAAA;EACA,iCAAA;EAAA,yBAAA;EACA,WAAA;EDvHD;AC8HD;EACE,gBAAA;ED5HD;ACmID;;;;EAIE,mCAAA;EACA,gBAAA;EDjID;ACmJD;;;;;EAKE,gBAAA;EACA,eAAA;EACA,WAAA;EDjJD;ACwJD;EACE,mBAAA;EDtJD;ACgKD;;EAEE,sBAAA;ED9JD;ACyKD;;;;EAIE,4BAAA;EACA,iBAAA;EDvKD;AC8KD;;EAEE,iBAAA;ED5KD;ACmLD;;EAEE,WAAA;EACA,YAAA;EDjLD;ACyLD;EACE,qBAAA;EDvLD;ACkMD;;EAEE,gCAAA;EAAA,6BAAA;EAAA,wBAAA;EACA,YAAA;EDhMD;ACyMD;;EAEE,cAAA;EDvMD;ACgND;EACE,+BAAA;EACA,8BAAA;EACA,iCAAA;EACA,yBAAA;ED9MD;ACuND;;EAEE,0BAAA;EDrND;AC4ND;EACE,2BAAA;EACA,eAAA;EACA,gCAAA;ED1ND;ACkOD;EACE,WAAA;EACA,YAAA;EDhOD;ACuOD;EACE,gBAAA;EDrOD;AC6OD;EACE,mBAAA;ED3OD;ACqPD;EACE,2BAAA;EACA,mBAAA;EDnPD;ACsPD;;EAEE,YAAA;EDpPD;AE9ED;EA9FE;IACE,8BAAA;IACA,wBAAA;IACA,oCAAA;IACA,qCAAA;IAAA,6BAAA;IF+KD;EE5KD;;IAEE,4BAAA;IF8KD;EE3KD;IACE,8BAAA;IF6KD;EE1KD;IACE,+BAAA;IF4KD;EExKD;;IAEE,aAAA;IF0KD;EEvKD;;IAEE,wBAAA;IACA,0BAAA;IFyKD;EEtKD;IACE,6BAAA;IFwKD;EErKD;;IAEE,0BAAA;IFuKD;EEpKD;IACE,4BAAA;IFsKD;EEnKD;;;IAGE,YAAA;IACA,WAAA;IFqKD;EElKD;;IAEE,yBAAA;IFoKD;EE/JD;IACE,6BAAA;IFiKD;EE7JD;IACE,eAAA;IF+JD;EE7JD;;IAGI,mCAAA;IF8JH;EE3JD;;IAGI,mCAAA;IF4JH;EEzJD;IACE,wBAAA;IF2JD;EExJD;IACE,sCAAA;IF0JD;EExJD;;IAGI,mCAAA;IFyJH;EACF;AGhPD;EACE,qCAAA;EACA,uDAAA;EACA,6TAAA;EHkPD;AG3OD;EACE,oBAAA;EACA,UAAA;EACA,uBAAA;EACA,qCAAA;EACA,oBAAA;EACA,qBAAA;EACA,gBAAA;EACA,qCAAA;EACA,oCAAA;EH6OD;AGzOmC;EAAW,gBAAA;EH4O9C;AG3OmC;EAAW,gBAAA;EH8O9C;AG7OmC;EAAW,kBAAA;EHgP9C;AG/OmC;EAAW,kBAAA;EHkP9C;AGjPmC;EAAW,kBAAA;EHoP9C;AGnPmC;EAAW,kBAAA;EHsP9C;AGrPmC;EAAW,kBAAA;EHwP9C;AGvPmC;EAAW,kBAAA;EH0P9C;AGzPmC;EAAW,kBAAA;EH4P9C;AG3PmC;EAAW,kBAAA;EH8P9C;AG7PmC;EAAW,kBAAA;EHgQ9C;AG/PmC;EAAW,kBAAA;EHkQ9C;AGjQmC;EAAW,kBAAA;EHoQ9C;AGnQmC;EAAW,kBAAA;EHsQ9C;AGrQmC;EAAW,kBAAA;EHwQ9C;AGvQmC;EAAW,kBAAA;EH0Q9C;AGzQmC;EAAW,kBAAA;EH4Q9C;AG3QmC;EAAW,kBAAA;EH8Q9C;AG7QmC;EAAW,kBAAA;EHgR9C;AG/QmC;EAAW,kBAAA;EHkR9C;AGjRmC;EAAW,kBAAA;EHoR9C;AGnRmC;EAAW,kBAAA;EHsR9C;AGrRmC;EAAW,kBAAA;EHwR9C;AGvRmC;EAAW,kBAAA;EH0R9C;AGzRmC;EAAW,kBAAA;EH4R9C;AG3RmC;EAAW,kBAAA;EH8R9C;AG7RmC;EAAW,kBAAA;EHgS9C;AG/RmC;EAAW,kBAAA;EHkS9C;AGjSmC;EAAW,kBAAA;EHoS9C;AGnSmC;EAAW,kBAAA;EHsS9C;AGrSmC;EAAW,kBAAA;EHwS9C;AGvSmC;EAAW,kBAAA;EH0S9C;AGzSmC;EAAW,kBAAA;EH4S9C;AG3SmC;EAAW,kBAAA;EH8S9C;AG7SmC;EAAW,kBAAA;EHgT9C;AG/SmC;EAAW,kBAAA;EHkT9C;AGjTmC;EAAW,kBAAA;EHoT9C;AGnTmC;EAAW,kBAAA;EHsT9C;AGrTmC;EAAW,kBAAA;EHwT9C;AGvTmC;EAAW,kBAAA;EH0T9C;AGzTmC;EAAW,kBAAA;EH4T9C;AG3TmC;EAAW,kBAAA;EH8T9C;AG7TmC;EAAW,kBAAA;EHgU9C;AG/TmC;EAAW,kBAAA;EHkU9C;AGjUmC;EAAW,kBAAA;EHoU9C;AGnUmC;EAAW,kBAAA;EHsU9C;AGrUmC;EAAW,kBAAA;EHwU9C;AGvUmC;EAAW,kBAAA;EH0U9C;AGzUmC;EAAW,kBAAA;EH4U9C;AG3UmC;EAAW,kBAAA;EH8U9C;AG7UmC;EAAW,kBAAA;EHgV9C;AG/UmC;EAAW,kBAAA;EHkV9C;AGjVmC;EAAW,kBAAA;EHoV9C;AGnVmC;EAAW,kBAAA;EHsV9C;AGrVmC;EAAW,kBAAA;EHwV9C;AGvVmC;EAAW,kBAAA;EH0V9C;AGzVmC;EAAW,kBAAA;EH4V9C;AG3VmC;EAAW,kBAAA;EH8V9C;AG7VmC;EAAW,kBAAA;EHgW9C;AG/VmC;EAAW,kBAAA;EHkW9C;AGjWmC;EAAW,kBAAA;EHoW9C;AGnWmC;EAAW,kBAAA;EHsW9C;AGrWmC;EAAW,kBAAA;EHwW9C;AGvWmC;EAAW,kBAAA;EH0W9C;AGzWmC;EAAW,kBAAA;EH4W9C;AG3WmC;EAAW,kBAAA;EH8W9C;AG7WmC;EAAW,kBAAA;EHgX9C;AG/WmC;EAAW,kBAAA;EHkX9C;AGjXmC;EAAW,kBAAA;EHoX9C;AGnXmC;EAAW,kBAAA;EHsX9C;AGrXmC;EAAW,kBAAA;EHwX9C;AGvXmC;EAAW,kBAAA;EH0X9C;AGzXmC;EAAW,kBAAA;EH4X9C;AG3XmC;EAAW,kBAAA;EH8X9C;AG7XmC;EAAW,kBAAA;EHgY9C;AG/XmC;EAAW,kBAAA;EHkY9C;AGjYmC;EAAW,kBAAA;EHoY9C;AGnYmC;EAAW,kBAAA;EHsY9C;AGrYmC;EAAW,kBAAA;EHwY9C;AGvYmC;EAAW,kBAAA;EH0Y9C;AGzYmC;EAAW,kBAAA;EH4Y9C;AG3YmC;EAAW,kBAAA;EH8Y9C;AG7YmC;EAAW,kBAAA;EHgZ9C;AG/YmC;EAAW,kBAAA;EHkZ9C;AGjZmC;EAAW,kBAAA;EHoZ9C;AGnZmC;EAAW,kBAAA;EHsZ9C;AGrZmC;EAAW,kBAAA;EHwZ9C;AGvZmC;EAAW,kBAAA;EH0Z9C;AGzZmC;EAAW,kBAAA;EH4Z9C;AG3ZmC;EAAW,kBAAA;EH8Z9C;AG7ZmC;EAAW,kBAAA;EHga9C;AG/ZmC;EAAW,kBAAA;EHka9C;AGjamC;EAAW,kBAAA;EHoa9C;AGnamC;EAAW,kBAAA;EHsa9C;AGramC;EAAW,kBAAA;EHwa9C;AGvamC;EAAW,kBAAA;EH0a9C;AGzamC;EAAW,kBAAA;EH4a9C;AG3amC;EAAW,kBAAA;EH8a9C;AG7amC;EAAW,kBAAA;EHgb9C;AG/amC;EAAW,kBAAA;EHkb9C;AGjbmC;EAAW,kBAAA;EHob9C;AGnbmC;EAAW,kBAAA;EHsb9C;AGrbmC;EAAW,kBAAA;EHwb9C;AGvbmC;EAAW,kBAAA;EH0b9C;AGzbmC;EAAW,kBAAA;EH4b9C;AG3bmC;EAAW,kBAAA;EH8b9C;AG7bmC;EAAW,kBAAA;EHgc9C;AG/bmC;EAAW,kBAAA;EHkc9C;AGjcmC;EAAW,kBAAA;EHoc9C;AGncmC;EAAW,kBAAA;EHsc9C;AGrcmC;EAAW,kBAAA;EHwc9C;AGvcmC;EAAW,kBAAA;EH0c9C;AGzcmC;EAAW,kBAAA;EH4c9C;AG3cmC;EAAW,kBAAA;EH8c9C;AG7cmC;EAAW,kBAAA;EHgd9C;AG/cmC;EAAW,kBAAA;EHkd9C;AGjdmC;EAAW,kBAAA;EHod9C;AGndmC;EAAW,kBAAA;EHsd9C;AGrdmC;EAAW,kBAAA;EHwd9C;AGvdmC;EAAW,kBAAA;EH0d9C;AGzdmC;EAAW,kBAAA;EH4d9C;AG3dmC;EAAW,kBAAA;EH8d9C;AG7dmC;EAAW,kBAAA;EHge9C;AG/dmC;EAAW,kBAAA;EHke9C;AGjemC;EAAW,kBAAA;EHoe9C;AGnemC;EAAW,kBAAA;EHse9C;AGremC;EAAW,kBAAA;EHwe9C;AGvemC;EAAW,kBAAA;EH0e9C;AGzemC;EAAW,kBAAA;EH4e9C;AG3emC;EAAW,kBAAA;EH8e9C;AG7emC;EAAW,kBAAA;EHgf9C;AG/emC;EAAW,kBAAA;EHkf9C;AGjfmC;EAAW,kBAAA;EHof9C;AGnfmC;EAAW,kBAAA;EHsf9C;AGrfmC;EAAW,kBAAA;EHwf9C;AGvfmC;EAAW,kBAAA;EH0f9C;AGzfmC;EAAW,kBAAA;EH4f9C;AG3fmC;EAAW,kBAAA;EH8f9C;AG7fmC;EAAW,kBAAA;EHggB9C;AG/fmC;EAAW,kBAAA;EHkgB9C;AGjgBmC;EAAW,kBAAA;EHogB9C;AGngBmC;EAAW,kBAAA;EHsgB9C;AGrgBmC;EAAW,kBAAA;EHwgB9C;AGvgBmC;EAAW,kBAAA;EH0gB9C;AGzgBmC;EAAW,kBAAA;EH4gB9C;AG3gBmC;EAAW,kBAAA;EH8gB9C;AG7gBmC;EAAW,kBAAA;EHghB9C;AG/gBmC;EAAW,kBAAA;EHkhB9C;AGjhBmC;EAAW,kBAAA;EHohB9C;AGnhBmC;EAAW,kBAAA;EHshB9C;AGrhBmC;EAAW,kBAAA;EHwhB9C;AGvhBmC;EAAW,kBAAA;EH0hB9C;AGzhBmC;EAAW,kBAAA;EH4hB9C;AG3hBmC;EAAW,kBAAA;EH8hB9C;AG7hBmC;EAAW,kBAAA;EHgiB9C;AG/hBmC;EAAW,kBAAA;EHkiB9C;AGjiBmC;EAAW,kBAAA;EHoiB9C;AGniBmC;EAAW,kBAAA;EHsiB9C;AGriBmC;EAAW,kBAAA;EHwiB9C;AGviBmC;EAAW,kBAAA;EH0iB9C;AGziBmC;EAAW,kBAAA;EH4iB9C;AG3iBmC;EAAW,kBAAA;EH8iB9C;AG7iBmC;EAAW,kBAAA;EHgjB9C;AG/iBmC;EAAW,kBAAA;EHkjB9C;AGjjBmC;EAAW,kBAAA;EHojB9C;AGnjBmC;EAAW,kBAAA;EHsjB9C;AGrjBmC;EAAW,kBAAA;EHwjB9C;AGvjBmC;EAAW,kBAAA;EH0jB9C;AGzjBmC;EAAW,kBAAA;EH4jB9C;AG3jBmC;EAAW,kBAAA;EH8jB9C;AG7jBmC;EAAW,kBAAA;EHgkB9C;AG/jBmC;EAAW,kBAAA;EHkkB9C;AGjkBmC;EAAW,kBAAA;EHokB9C;AGnkBmC;EAAW,kBAAA;EHskB9C;AGrkBmC;EAAW,kBAAA;EHwkB9C;AGvkBmC;EAAW,kBAAA;EH0kB9C;AGzkBmC;EAAW,kBAAA;EH4kB9C;AG3kBmC;EAAW,kBAAA;EH8kB9C;AG7kBmC;EAAW,kBAAA;EHglB9C;AG/kBmC;EAAW,kBAAA;EHklB9C;AGjlBmC;EAAW,kBAAA;EHolB9C;AGnlBmC;EAAW,kBAAA;EHslB9C;AGrlBmC;EAAW,kBAAA;EHwlB9C;AGvlBmC;EAAW,kBAAA;EH0lB9C;AGzlBmC;EAAW,kBAAA;EH4lB9C;AG3lBmC;EAAW,kBAAA;EH8lB9C;AG7lBmC;EAAW,kBAAA;EHgmB9C;AG/lBmC;EAAW,kBAAA;EHkmB9C;AGjmBmC;EAAW,kBAAA;EHomB9C;AGnmBmC;EAAW,kBAAA;EHsmB9C;AGrmBmC;EAAW,kBAAA;EHwmB9C;AGvmBmC;EAAW,kBAAA;EH0mB9C;AGzmBmC;EAAW,kBAAA;EH4mB9C;AG3mBmC;EAAW,kBAAA;EH8mB9C;AG7mBmC;EAAW,kBAAA;EHgnB9C;AG/mBmC;EAAW,kBAAA;EHknB9C;AGjnBmC;EAAW,kBAAA;EHonB9C;AGnnBmC;EAAW,kBAAA;EHsnB9C;AGrnBmC;EAAW,kBAAA;EHwnB9C;AGvnBmC;EAAW,kBAAA;EH0nB9C;AIx1BD;ECgEE,gCAAA;EACG,6BAAA;EACK,wBAAA;EL2xBT;AI11BD;;EC6DE,gCAAA;EACG,6BAAA;EACK,wBAAA;ELiyBT;AIx1BD;EACE,iBAAA;EACA,+CAAA;EJ01BD;AIv1BD;EACE,6DAAA;EACA,iBAAA;EACA,yBAAA;EACA,gBAAA;EACA,2BAAA;EJy1BD;AIr1BD;;;;EAIE,sBAAA;EACA,oBAAA;EACA,sBAAA;EJu1BD;AIj1BD;EACE,gBAAA;EACA,uBAAA;EJm1BD;AIj1BC;;EAEE,gBAAA;EACA,4BAAA;EJm1BH;AIh1BC;EErDA,sBAAA;EAEA,4CAAA;EACA,sBAAA;ENu4BD;AI10BD;EACE,WAAA;EJ40BD;AIt0BD;EACE,wBAAA;EJw0BD;AIp0BD;;;;;EGvEE,gBAAA;EACA,gBAAA;EACA,iBAAA;EACA,cAAA;EPk5BD;AIz0BD;EACE,oBAAA;EJ20BD;AIr0BD;EACE,cAAA;EACA,yBAAA;EACA,2BAAA;EACA,2BAAA;EACA,oBAAA;EC0FA,0CAAA;EACK,qCAAA;EACG,kCAAA;EEpLR,uBAAA;EACA,gBAAA;EACA,iBAAA;EACA,cAAA;EPm6BD;AIt0BD;EACE,oBAAA;EJw0BD;AIl0BD;EACE,kBAAA;EACA,qBAAA;EACA,WAAA;EACA,+BAAA;EJo0BD;AI5zBD;EACE,oBAAA;EACA,YAAA;EACA,aAAA;EACA,cAAA;EACA,YAAA;EACA,kBAAA;EACA,wBAAA;EACA,WAAA;EJ8zBD;AItzBC;;EAEE,kBAAA;EACA,aAAA;EACA,cAAA;EACA,WAAA;EACA,mBAAA;EACA,YAAA;EJwzBH;AQn8BD;;;;;;;;;;;;EAEE,sBAAA;EACA,kBAAA;EACA,kBAAA;EACA,gBAAA;ER+8BD;AQp9BD;;;;;;;;;;;;;;;;;;;;;;;;EASI,qBAAA;EACA,gBAAA;EACA,gBAAA;ERq+BH;AQj+BD;;;;;;EAGE,kBAAA;EACA,qBAAA;ERs+BD;AQ1+BD;;;;;;;;;;;;EAQI,gBAAA;ERg/BH;AQ7+BD;;;;;;EAGE,kBAAA;EACA,qBAAA;ERk/BD;AQt/BD;;;;;;;;;;;;EAQI,gBAAA;ER4/BH;AQx/BD;;EAAU,iBAAA;ER4/BT;AQ3/BD;;EAAU,iBAAA;ER+/BT;AQ9/BD;;EAAU,iBAAA;ERkgCT;AQjgCD;;EAAU,iBAAA;ERqgCT;AQpgCD;;EAAU,iBAAA;ERwgCT;AQvgCD;;EAAU,iBAAA;ER2gCT;AQrgCD;EACE,kBAAA;ERugCD;AQpgCD;EACE,qBAAA;EACA,iBAAA;EACA,kBAAA;EACA,kBAAA;ERsgCD;AQjgCD;EAAA;IAFI,iBAAA;IRugCD;EACF;AQ//BD;;EAEE,gBAAA;ERigCD;AQ7/BD;EACE,oBAAA;ER+/BD;AQ5/BD;;EAEE,2BAAA;EACA,eAAA;ER8/BD;AQ1/BD;EAAuB,kBAAA;ER6/BtB;AQ5/BD;EAAuB,mBAAA;ER+/BtB;AQ9/BD;EAAuB,oBAAA;ERigCtB;AQhgCD;EAAuB,qBAAA;ERmgCtB;AQlgCD;EAAuB,qBAAA;ERqgCtB;AQlgCD;EAAuB,2BAAA;ERqgCtB;AQpgCD;EAAuB,2BAAA;ERugCtB;AQtgCD;EAAuB,4BAAA;ERygCtB;AQtgCD;EACE,gBAAA;ERwgCD;AQtgCD;EC1GE,gBAAA;ETmnCD;ASlnCC;EACE,gBAAA;ETonCH;AQzgCD;EC7GE,gBAAA;ETynCD;ASxnCC;EACE,gBAAA;ET0nCH;AQ5gCD;EChHE,gBAAA;ET+nCD;AS9nCC;EACE,gBAAA;ETgoCH;AQ/gCD;ECnHE,gBAAA;ETqoCD;ASpoCC;EACE,gBAAA;ETsoCH;AQlhCD;ECtHE,gBAAA;ET2oCD;AS1oCC;EACE,gBAAA;ET4oCH;AQjhCD;EAGE,aAAA;EEhIA,2BAAA;EVkpCD;AUjpCC;EACE,2BAAA;EVmpCH;AQlhCD;EEnIE,2BAAA;EVwpCD;AUvpCC;EACE,2BAAA;EVypCH;AQrhCD;EEtIE,2BAAA;EV8pCD;AU7pCC;EACE,2BAAA;EV+pCH;AQxhCD;EEzIE,2BAAA;EVoqCD;AUnqCC;EACE,2BAAA;EVqqCH;AQ3hCD;EE5IE,2BAAA;EV0qCD;AUzqCC;EACE,2BAAA;EV2qCH;AQzhCD;EACE,qBAAA;EACA,qBAAA;EACA,kCAAA;ER2hCD;AQnhCD;;EAEE,eAAA;EACA,qBAAA;ERqhCD;AQxhCD;;;;EAMI,kBAAA;ERwhCH;AQjhCD;EACE,iBAAA;EACA,kBAAA;ERmhCD;AQ/gCD;EALE,iBAAA;EACA,kBAAA;EAMA,mBAAA;ERkhCD;AQphCD;EAKI,uBAAA;EACA,mBAAA;EACA,oBAAA;ERkhCH;AQ7gCD;EACE,eAAA;EACA,qBAAA;ER+gCD;AQ7gCD;;EAEE,yBAAA;ER+gCD;AQ7gCD;EACE,mBAAA;ER+gCD;AQ7gCD;EACE,gBAAA;ER+gCD;AQt/BD;EAAA;IAVM,aAAA;IACA,cAAA;IACA,aAAA;IACA,mBAAA;IG3NJ,kBAAA;IACA,yBAAA;IACA,qBAAA;IXguCC;EQhgCH;IAHM,oBAAA;IRsgCH;EACF;AQ7/BD;;EAGE,cAAA;EACA,mCAAA;ER8/BD;AQ5/BD;EACE,gBAAA;EACA,2BAAA;ER8/BD;AQ1/BD;EACE,oBAAA;EACA,kBAAA;EACA,mBAAA;EACA,gCAAA;ER4/BD;AQv/BG;;;EACE,kBAAA;ER2/BL;AQrgCD;;;EAmBI,gBAAA;EACA,gBAAA;EACA,yBAAA;EACA,gBAAA;ERu/BH;AQr/BG;;;EACE,wBAAA;ERy/BL;AQj/BD;;EAEE,qBAAA;EACA,iBAAA;EACA,iCAAA;EACA,gBAAA;EACA,mBAAA;ERm/BD;AQ7+BG;;;;;;EAAW,aAAA;ERq/Bd;AQp/BG;;;;;;EACE,wBAAA;ER2/BL;AQr/BD;;EAEE,aAAA;ERu/BD;AQn/BD;EACE,qBAAA;EACA,oBAAA;EACA,yBAAA;ERq/BD;AYtyCD;;;;EAIE,gEAAA;EZwyCD;AYpyCD;EACE,kBAAA;EACA,gBAAA;EACA,gBAAA;EACA,2BAAA;EACA,oBAAA;EZsyCD;AYlyCD;EACE,kBAAA;EACA,gBAAA;EACA,gBAAA;EACA,2BAAA;EACA,oBAAA;EACA,wDAAA;EAAA,gDAAA;EZoyCD;AY1yCD;EASI,YAAA;EACA,iBAAA;EACA,0BAAA;EAAA,kBAAA;EZoyCH;AY/xCD;EACE,gBAAA;EACA,gBAAA;EACA,kBAAA;EACA,iBAAA;EACA,yBAAA;EACA,uBAAA;EACA,uBAAA;EACA,gBAAA;EACA,2BAAA;EACA,2BAAA;EACA,oBAAA;EZiyCD;AY5yCD;EAeI,YAAA;EACA,oBAAA;EACA,gBAAA;EACA,uBAAA;EACA,+BAAA;EACA,kBAAA;EZgyCH;AY3xCD;EACE,mBAAA;EACA,oBAAA;EZ6xCD;Aat1CD;ECHE,oBAAA;EACA,mBAAA;EACA,oBAAA;EACA,qBAAA;Ed41CD;Aat1CC;EAAA;IAFE,cAAA;Ib41CD;EACF;Aax1CC;EAAA;IAFE,cAAA;Ib81CD;EACF;Aa11CD;EAAA;IAFI,eAAA;Ibg2CD;EACF;Aav1CD;ECvBE,oBAAA;EACA,mBAAA;EACA,oBAAA;EACA,qBAAA;Edi3CD;Aap1CD;ECvBE,oBAAA;EACA,qBAAA;Ed82CD;Ae92CG;EACE,oBAAA;EAEA,iBAAA;EAEA,oBAAA;EACA,qBAAA;Ef82CL;Ae91CG;EACE,aAAA;Efg2CL;Aez1CC;EACE,aAAA;Ef21CH;Ae51CC;EACE,qBAAA;Ef81CH;Ae/1CC;EACE,qBAAA;Efi2CH;Ael2CC;EACE,YAAA;Efo2CH;Aer2CC;EACE,qBAAA;Efu2CH;Aex2CC;EACE,qBAAA;Ef02CH;Ae32CC;EACE,YAAA;Ef62CH;Ae92CC;EACE,qBAAA;Efg3CH;Aej3CC;EACE,qBAAA;Efm3CH;Aep3CC;EACE,YAAA;Efs3CH;Aev3CC;EACE,qBAAA;Efy3CH;Ae13CC;EACE,oBAAA;Ef43CH;Ae92CC;EACE,aAAA;Efg3CH;Aej3CC;EACE,qBAAA;Efm3CH;Aep3CC;EACE,qBAAA;Efs3CH;Aev3CC;EACE,YAAA;Efy3CH;Ae13CC;EACE,qBAAA;Ef43CH;Ae73CC;EACE,qBAAA;Ef+3CH;Aeh4CC;EACE,YAAA;Efk4CH;Aen4CC;EACE,qBAAA;Efq4CH;Aet4CC;EACE,qBAAA;Efw4CH;Aez4CC;EACE,YAAA;Ef24CH;Ae54CC;EACE,qBAAA;Ef84CH;Ae/4CC;EACE,oBAAA;Efi5CH;Ae74CC;EACE,aAAA;Ef+4CH;Ae/5CC;EACE,YAAA;Efi6CH;Ael6CC;EACE,oBAAA;Efo6CH;Aer6CC;EACE,oBAAA;Efu6CH;Aex6CC;EACE,WAAA;Ef06CH;Ae36CC;EACE,oBAAA;Ef66CH;Ae96CC;EACE,oBAAA;Efg7CH;Aej7CC;EACE,WAAA;Efm7CH;Aep7CC;EACE,oBAAA;Efs7CH;Aev7CC;EACE,oBAAA;Efy7CH;Ae17CC;EACE,WAAA;Ef47CH;Ae77CC;EACE,oBAAA;Ef+7CH;Aeh8CC;EACE,mBAAA;Efk8CH;Ae97CC;EACE,YAAA;Efg8CH;Ael7CC;EACE,mBAAA;Efo7CH;Aer7CC;EACE,2BAAA;Efu7CH;Aex7CC;EACE,2BAAA;Ef07CH;Ae37CC;EACE,kBAAA;Ef67CH;Ae97CC;EACE,2BAAA;Efg8CH;Aej8CC;EACE,2BAAA;Efm8CH;Aep8CC;EACE,kBAAA;Efs8CH;Aev8CC;EACE,2BAAA;Efy8CH;Ae18CC;EACE,2BAAA;Ef48CH;Ae78CC;EACE,kBAAA;Ef+8CH;Aeh9CC;EACE,2BAAA;Efk9CH;Aen9CC;EACE,0BAAA;Efq9CH;Aet9CC;EACE,iBAAA;Efw9CH;Aa59CD;EE9BI;IACE,aAAA;If6/CH;Eet/CD;IACE,aAAA;Ifw/CD;Eez/CD;IACE,qBAAA;If2/CD;Ee5/CD;IACE,qBAAA;If8/CD;Ee//CD;IACE,YAAA;IfigDD;EelgDD;IACE,qBAAA;IfogDD;EergDD;IACE,qBAAA;IfugDD;EexgDD;IACE,YAAA;If0gDD;Ee3gDD;IACE,qBAAA;If6gDD;Ee9gDD;IACE,qBAAA;IfghDD;EejhDD;IACE,YAAA;IfmhDD;EephDD;IACE,qBAAA;IfshDD;EevhDD;IACE,oBAAA;IfyhDD;Ee3gDD;IACE,aAAA;If6gDD;Ee9gDD;IACE,qBAAA;IfghDD;EejhDD;IACE,qBAAA;IfmhDD;EephDD;IACE,YAAA;IfshDD;EevhDD;IACE,qBAAA;IfyhDD;Ee1hDD;IACE,qBAAA;If4hDD;Ee7hDD;IACE,YAAA;If+hDD;EehiDD;IACE,qBAAA;IfkiDD;EeniDD;IACE,qBAAA;IfqiDD;EetiDD;IACE,YAAA;IfwiDD;EeziDD;IACE,qBAAA;If2iDD;Ee5iDD;IACE,oBAAA;If8iDD;Ee1iDD;IACE,aAAA;If4iDD;Ee5jDD;IACE,YAAA;If8jDD;Ee/jDD;IACE,oBAAA;IfikDD;EelkDD;IACE,oBAAA;IfokDD;EerkDD;IACE,WAAA;IfukDD;EexkDD;IACE,oBAAA;If0kDD;Ee3kDD;IACE,oBAAA;If6kDD;Ee9kDD;IACE,WAAA;IfglDD;EejlDD;IACE,oBAAA;IfmlDD;EeplDD;IACE,oBAAA;IfslDD;EevlDD;IACE,WAAA;IfylDD;Ee1lDD;IACE,oBAAA;If4lDD;Ee7lDD;IACE,mBAAA;If+lDD;Ee3lDD;IACE,YAAA;If6lDD;Ee/kDD;IACE,mBAAA;IfilDD;EellDD;IACE,2BAAA;IfolDD;EerlDD;IACE,2BAAA;IfulDD;EexlDD;IACE,kBAAA;If0lDD;Ee3lDD;IACE,2BAAA;If6lDD;Ee9lDD;IACE,2BAAA;IfgmDD;EejmDD;IACE,kBAAA;IfmmDD;EepmDD;IACE,2BAAA;IfsmDD;EevmDD;IACE,2BAAA;IfymDD;Ee1mDD;IACE,kBAAA;If4mDD;Ee7mDD;IACE,2BAAA;If+mDD;EehnDD;IACE,0BAAA;IfknDD;EennDD;IACE,iBAAA;IfqnDD;EACF;AajnDD;EEvCI;IACE,aAAA;If2pDH;EeppDD;IACE,aAAA;IfspDD;EevpDD;IACE,qBAAA;IfypDD;Ee1pDD;IACE,qBAAA;If4pDD;Ee7pDD;IACE,YAAA;If+pDD;EehqDD;IACE,qBAAA;IfkqDD;EenqDD;IACE,qBAAA;IfqqDD;EetqDD;IACE,YAAA;IfwqDD;EezqDD;IACE,qBAAA;If2qDD;Ee5qDD;IACE,qBAAA;If8qDD;Ee/qDD;IACE,YAAA;IfirDD;EelrDD;IACE,qBAAA;IforDD;EerrDD;IACE,oBAAA;IfurDD;EezqDD;IACE,aAAA;If2qDD;Ee5qDD;IACE,qBAAA;If8qDD;Ee/qDD;IACE,qBAAA;IfirDD;EelrDD;IACE,YAAA;IforDD;EerrDD;IACE,qBAAA;IfurDD;EexrDD;IACE,qBAAA;If0rDD;Ee3rDD;IACE,YAAA;If6rDD;Ee9rDD;IACE,qBAAA;IfgsDD;EejsDD;IACE,qBAAA;IfmsDD;EepsDD;IACE,YAAA;IfssDD;EevsDD;IACE,qBAAA;IfysDD;Ee1sDD;IACE,oBAAA;If4sDD;EexsDD;IACE,aAAA;If0sDD;Ee1tDD;IACE,YAAA;If4tDD;Ee7tDD;IACE,oBAAA;If+tDD;EehuDD;IACE,oBAAA;IfkuDD;EenuDD;IACE,WAAA;IfquDD;EetuDD;IACE,oBAAA;IfwuDD;EezuDD;IACE,oBAAA;If2uDD;Ee5uDD;IACE,WAAA;If8uDD;Ee/uDD;IACE,oBAAA;IfivDD;EelvDD;IACE,oBAAA;IfovDD;EervDD;IACE,WAAA;IfuvDD;EexvDD;IACE,oBAAA;If0vDD;Ee3vDD;IACE,mBAAA;If6vDD;EezvDD;IACE,YAAA;If2vDD;Ee7uDD;IACE,mBAAA;If+uDD;EehvDD;IACE,2BAAA;IfkvDD;EenvDD;IACE,2BAAA;IfqvDD;EetvDD;IACE,kBAAA;IfwvDD;EezvDD;IACE,2BAAA;If2vDD;Ee5vDD;IACE,2BAAA;If8vDD;Ee/vDD;IACE,kBAAA;IfiwDD;EelwDD;IACE,2BAAA;IfowDD;EerwDD;IACE,2BAAA;IfuwDD;EexwDD;IACE,kBAAA;If0wDD;Ee3wDD;IACE,2BAAA;If6wDD;Ee9wDD;IACE,0BAAA;IfgxDD;EejxDD;IACE,iBAAA;IfmxDD;EACF;AaxwDD;EE9CI;IACE,aAAA;IfyzDH;EelzDD;IACE,aAAA;IfozDD;EerzDD;IACE,qBAAA;IfuzDD;EexzDD;IACE,qBAAA;If0zDD;Ee3zDD;IACE,YAAA;If6zDD;Ee9zDD;IACE,qBAAA;Ifg0DD;Eej0DD;IACE,qBAAA;Ifm0DD;Eep0DD;IACE,YAAA;Ifs0DD;Eev0DD;IACE,qBAAA;Ify0DD;Ee10DD;IACE,qBAAA;If40DD;Ee70DD;IACE,YAAA;If+0DD;Eeh1DD;IACE,qBAAA;Ifk1DD;Een1DD;IACE,oBAAA;Ifq1DD;Eev0DD;IACE,aAAA;Ify0DD;Ee10DD;IACE,qBAAA;If40DD;Ee70DD;IACE,qBAAA;If+0DD;Eeh1DD;IACE,YAAA;Ifk1DD;Een1DD;IACE,qBAAA;Ifq1DD;Eet1DD;IACE,qBAAA;Ifw1DD;Eez1DD;IACE,YAAA;If21DD;Ee51DD;IACE,qBAAA;If81DD;Ee/1DD;IACE,qBAAA;Ifi2DD;Eel2DD;IACE,YAAA;Ifo2DD;Eer2DD;IACE,qBAAA;Ifu2DD;Eex2DD;IACE,oBAAA;If02DD;Eet2DD;IACE,aAAA;Ifw2DD;Eex3DD;IACE,YAAA;If03DD;Ee33DD;IACE,oBAAA;If63DD;Ee93DD;IACE,oBAAA;Ifg4DD;Eej4DD;IACE,WAAA;Ifm4DD;Eep4DD;IACE,oBAAA;Ifs4DD;Eev4DD;IACE,oBAAA;Ify4DD;Ee14DD;IACE,WAAA;If44DD;Ee74DD;IACE,oBAAA;If+4DD;Eeh5DD;IACE,oBAAA;Ifk5DD;Een5DD;IACE,WAAA;Ifq5DD;Eet5DD;IACE,oBAAA;Ifw5DD;Eez5DD;IACE,mBAAA;If25DD;Eev5DD;IACE,YAAA;Ify5DD;Ee34DD;IACE,mBAAA;If64DD;Ee94DD;IACE,2BAAA;Ifg5DD;Eej5DD;IACE,2BAAA;Ifm5DD;Eep5DD;IACE,kBAAA;Ifs5DD;Eev5DD;IACE,2BAAA;Ify5DD;Ee15DD;IACE,2BAAA;If45DD;Ee75DD;IACE,kBAAA;If+5DD;Eeh6DD;IACE,2BAAA;Ifk6DD;Een6DD;IACE,2BAAA;Ifq6DD;Eet6DD;IACE,kBAAA;Ifw6DD;Eez6DD;IACE,2BAAA;If26DD;Ee56DD;IACE,0BAAA;If86DD;Ee/6DD;IACE,iBAAA;Ifi7DD;EACF;AgBr/DD;EACE,+BAAA;EhBu/DD;AgBr/DD;EACE,kBAAA;EhBu/DD;AgBj/DD;EACE,aAAA;EACA,iBAAA;EACA,qBAAA;EhBm/DD;AgBt/DD;;;;;;EAWQ,cAAA;EACA,yBAAA;EACA,qBAAA;EACA,+BAAA;EhBm/DP;AgBjgED;EAoBI,wBAAA;EACA,kCAAA;EhBg/DH;AgBrgED;;;;;;EA8BQ,eAAA;EhB++DP;AgB7gED;EAoCI,+BAAA;EhB4+DH;AgBhhED;EAyCI,2BAAA;EhB0+DH;AgBn+DD;;;;;;EAOQ,cAAA;EhBo+DP;AgBz9DD;EACE,2BAAA;EhB29DD;AgB59DD;;;;;;EAQQ,2BAAA;EhB49DP;AgBp+DD;;EAeM,0BAAA;EhBy9DL;AgB/8DD;;EAIM,2BAAA;EhB+8DL;AgBr8DD;;EAIM,2BAAA;EhBq8DL;AgB37DD;EACE,kBAAA;EACA,aAAA;EACA,uBAAA;EhB67DD;AgBx7DG;;EACE,kBAAA;EACA,aAAA;EACA,qBAAA;EhB27DL;AiBvkEC;;;;;;;;;;;;EAOI,2BAAA;EjB8kEL;AiBxkEC;;;;;EAMI,2BAAA;EjBykEL;AiB5lEC;;;;;;;;;;;;EAOI,2BAAA;EjBmmEL;AiB7lEC;;;;;EAMI,2BAAA;EjB8lEL;AiBjnEC;;;;;;;;;;;;EAOI,2BAAA;EjBwnEL;AiBlnEC;;;;;EAMI,2BAAA;EjBmnEL;AiBtoEC;;;;;;;;;;;;EAOI,2BAAA;EjB6oEL;AiBvoEC;;;;;EAMI,2BAAA;EjBwoEL;AiB3pEC;;;;;;;;;;;;EAOI,2BAAA;EjBkqEL;AiB5pEC;;;;;EAMI,2BAAA;EjB6pEL;AgB78DD;EAAA;IA5DI,aAAA;IACA,qBAAA;IACA,oBAAA;IACA,kBAAA;IACA,8CAAA;IACA,2BAAA;IACA,mCAAA;IhB6gED;EgBv9DH;IAlDM,kBAAA;IhB4gEH;EgB19DH;;;;;;IAzCY,qBAAA;IhB2gET;EgBl+DH;IAjCM,WAAA;IhBsgEH;EgBr+DH;;;;;;IAxBY,gBAAA;IhBqgET;EgB7+DH;;;;;;IApBY,iBAAA;IhBygET;EgBr/DH;;;;IAPY,kBAAA;IhBkgET;EACF;AkB3tED;EACE,YAAA;EACA,WAAA;EACA,WAAA;EAIA,cAAA;ElB0tED;AkBvtED;EACE,gBAAA;EACA,aAAA;EACA,YAAA;EACA,qBAAA;EACA,iBAAA;EACA,sBAAA;EACA,gBAAA;EACA,WAAA;EACA,kCAAA;ElBytED;AkBttED;EACE,uBAAA;EACA,iBAAA;EACA,oBAAA;EACA,mBAAA;ElBwtED;AkB7sED;Eb4BE,gCAAA;EACG,6BAAA;EACK,wBAAA;ELorET;AkB7sED;;EAEE,iBAAA;EACA,oBAAA;EACA,qBAAA;ElB+sED;AkB3sED;EACE,gBAAA;ElB6sED;AkBzsED;EACE,gBAAA;EACA,aAAA;ElB2sED;AkBvsED;;EAEE,cAAA;ElBysED;AkBrsED;;;EZxEE,sBAAA;EAEA,4CAAA;EACA,sBAAA;ENixED;AkBrsED;EACE,gBAAA;EACA,kBAAA;EACA,iBAAA;EACA,yBAAA;EACA,gBAAA;ElBusED;AkB7qED;EACE,gBAAA;EACA,aAAA;EACA,cAAA;EACA,mBAAA;EACA,iBAAA;EACA,yBAAA;EACA,gBAAA;EACA,2BAAA;EACA,wBAAA;EACA,2BAAA;EACA,oBAAA;EbzDA,0DAAA;EACQ,kDAAA;EAsHR,wFAAA;EACK,2EAAA;EACG,wEAAA;ELonET;AmB7vEC;EACE,uBAAA;EACA,YAAA;EdcF,wFAAA;EACQ,gFAAA;ELkvET;AKltEC;EAAgC,gBAAA;EACA,YAAA;ELqtEjC;AKptEC;EAAgC,gBAAA;ELutEjC;AKttEC;EAAgC,gBAAA;ELytEjC;AkBrrEC;;;EAGE,qBAAA;EACA,2BAAA;EACA,YAAA;ElBurEH;AkBnrEC;EACE,cAAA;ElBqrEH;AkBzqED;EACE,0BAAA;ElB2qED;AkB/pED;;;;EAIE,mBAAA;EAEA,4BAAA;ElBgqED;AkB9pEC;;;;EACE,mBAAA;ElBmqEH;AkBjqEC;;;;EACE,mBAAA;ElBsqEH;AkB5pED;EACE,qBAAA;ElB8pED;AkBtpED;;EAEE,oBAAA;EACA,gBAAA;EACA,kBAAA;EACA,kBAAA;EACA,qBAAA;ElBwpED;AkB9pED;;EASI,oBAAA;EACA,kBAAA;EACA,qBAAA;EACA,iBAAA;ElBypEH;AkBtpED;;;;EAIE,oBAAA;EACA,oBAAA;EACA,oBAAA;ElBwpED;AkBrpED;;EAEE,kBAAA;ElBupED;AkBnpED;;EAEE,uBAAA;EACA,oBAAA;EACA,kBAAA;EACA,wBAAA;EACA,qBAAA;EACA,iBAAA;ElBqpED;AkBnpED;;EAEE,eAAA;EACA,mBAAA;ElBqpED;AkB5oEC;;;;;;EAGE,qBAAA;ElBipEH;AkB3oEC;;;;EAEE,qBAAA;ElB+oEH;AkBzoEC;;;;EAGI,qBAAA;ElB4oEL;AkBjoED;EAEE,kBAAA;EACA,qBAAA;EAEA,kBAAA;ElBioED;AkB/nEC;;EAEE,iBAAA;EACA,kBAAA;ElBioEH;AkBvnED;;ECnPE,cAAA;EACA,mBAAA;EACA,iBAAA;EACA,kBAAA;EACA,oBAAA;EnB82ED;AmB52EC;EACE,cAAA;EACA,mBAAA;EnB82EH;AmB32EC;;EAEE,cAAA;EnB62EH;AkBnoED;;ECvPE,cAAA;EACA,oBAAA;EACA,iBAAA;EACA,mBAAA;EACA,oBAAA;EnB83ED;AmB53EC;EACE,cAAA;EACA,mBAAA;EnB83EH;AmB33EC;;EAEE,cAAA;EnB63EH;AkB1oED;EAEE,oBAAA;ElB2oED;AkB7oED;EAMI,uBAAA;ElB0oEH;AkBtoED;EACE,oBAAA;EACA,WAAA;EACA,UAAA;EACA,YAAA;EACA,gBAAA;EACA,aAAA;EACA,cAAA;EACA,mBAAA;EACA,oBAAA;ElBwoED;AkBtoED;EACE,aAAA;EACA,cAAA;EACA,mBAAA;ElBwoED;AkBtoED;EACE,aAAA;EACA,cAAA;EACA,mBAAA;ElBwoED;AkBpoED;;;;;;ECrVI,gBAAA;EnBi+EH;AkB5oED;ECjVI,uBAAA;EdmDF,0DAAA;EACQ,kDAAA;EL86ET;AmBh+EG;EACE,uBAAA;EdgDJ,2EAAA;EACQ,mEAAA;ELm7ET;AkBtpED;ECvUI,gBAAA;EACA,uBAAA;EACA,2BAAA;EnBg+EH;AkB3pED;ECjUI,gBAAA;EnB+9EH;AkB3pED;;;;;;ECxVI,gBAAA;EnB2/EH;AkBnqED;ECpVI,uBAAA;EdmDF,0DAAA;EACQ,kDAAA;ELw8ET;AmB1/EG;EACE,uBAAA;EdgDJ,2EAAA;EACQ,mEAAA;EL68ET;AkB7qED;EC1UI,gBAAA;EACA,uBAAA;EACA,2BAAA;EnB0/EH;AkBlrED;ECpUI,gBAAA;EnBy/EH;AkBlrED;;;;;;EC3VI,gBAAA;EnBqhFH;AkB1rED;ECvVI,uBAAA;EdmDF,0DAAA;EACQ,kDAAA;ELk+ET;AmBphFG;EACE,uBAAA;EdgDJ,2EAAA;EACQ,mEAAA;ELu+ET;AkBpsED;EC7UI,gBAAA;EACA,uBAAA;EACA,2BAAA;EnBohFH;AkBzsED;ECvUI,gBAAA;EnBmhFH;AkBtsED;EACE,QAAA;ElBwsED;AkB/rED;EACE,gBAAA;EACA,iBAAA;EACA,qBAAA;EACA,gBAAA;ElBisED;AkB9mED;EAAA;IA7DM,uBAAA;IACA,kBAAA;IACA,wBAAA;IlB+qEH;EkBpnEH;IAtDM,uBAAA;IACA,aAAA;IACA,wBAAA;IlB6qEH;EkBznEH;IAhDM,uBAAA;IACA,wBAAA;IlB4qEH;EkB7nEH;;;IA1CQ,aAAA;IlB4qEL;EkBloEH;IApCM,aAAA;IlByqEH;EkBroEH;IAhCM,kBAAA;IACA,wBAAA;IlBwqEH;EkBzoEH;;IAvBM,uBAAA;IACA,eAAA;IACA,kBAAA;IACA,wBAAA;IlBoqEH;EkBhpEH;;IAjBQ,iBAAA;IlBqqEL;EkBppEH;;IAZM,oBAAA;IACA,gBAAA;IlBoqEH;EkBzpEH;IAHM,QAAA;IlB+pEH;EACF;AkBrpED;;;;EASI,eAAA;EACA,kBAAA;EACA,kBAAA;ElBkpEH;AkB7pED;;EAiBI,kBAAA;ElBgpEH;AkBjqED;EJxcE,oBAAA;EACA,qBAAA;Ed4mFD;AkBloEC;EAAA;IANI,mBAAA;IACA,kBAAA;IACA,kBAAA;IlB4oEH;EACF;AkB5qED;EAwCI,QAAA;EACA,aAAA;ElBuoEH;AkB1nEG;EAAA;IAHI,qBAAA;IlBioEL;EACF;AkBrnEG;EAAA;IAHI,kBAAA;IlB4nEL;EACF;AoBzoFD;EACE,uBAAA;EACA,kBAAA;EACA,qBAAA;EACA,oBAAA;EACA,wBAAA;EACA,iBAAA;EACA,wBAAA;EACA,+BAAA;EACA,qBAAA;EC4BA,mBAAA;EACA,iBAAA;EACA,yBAAA;EACA,oBAAA;EhB2KA,2BAAA;EACG,wBAAA;EACC,uBAAA;EACI,mBAAA;ELs8ET;AoB5oFG;;;EdpBF,sBAAA;EAEA,4CAAA;EACA,sBAAA;ENoqFD;AoB9oFC;;EAEE,gBAAA;EACA,uBAAA;EpBgpFH;AoB7oFC;;EAEE,YAAA;EACA,wBAAA;Ef8BF,0DAAA;EACQ,kDAAA;ELknFT;AoB7oFC;;;EAGE,qBAAA;EACA,sBAAA;EE3CF,eAAA;EAGA,2BAAA;EjB8DA,0BAAA;EACQ,kBAAA;EL4nFT;AoBzoFD;EClDE,gBAAA;EACA,2BAAA;EACA,uBAAA;ErB8rFD;AqB5rFC;;;;;EAKE,gBAAA;EACA,2BAAA;EACI,uBAAA;ErB8rFP;AqB5rFC;;;EAGE,wBAAA;ErB8rFH;AqBzrFG;;;;;;;;;;;;;;;EAKE,2BAAA;EACI,uBAAA;ErBqsFT;AoB9qFD;EClBI,gBAAA;EACA,2BAAA;ErBmsFH;AoB/qFD;ECrDE,gBAAA;EACA,2BAAA;EACA,uBAAA;ErBuuFD;AqBruFC;;;;;EAKE,gBAAA;EACA,2BAAA;EACI,uBAAA;ErBuuFP;AqBruFC;;;EAGE,wBAAA;ErBuuFH;AqBluFG;;;;;;;;;;;;;;;EAKE,2BAAA;EACI,uBAAA;ErB8uFT;AoBptFD;ECrBI,gBAAA;EACA,2BAAA;ErB4uFH;AoBptFD;ECzDE,gBAAA;EACA,2BAAA;EACA,uBAAA;ErBgxFD;AqB9wFC;;;;;EAKE,gBAAA;EACA,2BAAA;EACI,uBAAA;ErBgxFP;AqB9wFC;;;EAGE,wBAAA;ErBgxFH;AqB3wFG;;;;;;;;;;;;;;;EAKE,2BAAA;EACI,uBAAA;ErBuxFT;AoBzvFD;ECzBI,gBAAA;EACA,2BAAA;ErBqxFH;AoBzvFD;EC7DE,gBAAA;EACA,2BAAA;EACA,uBAAA;ErByzFD;AqBvzFC;;;;;EAKE,gBAAA;EACA,2BAAA;EACI,uBAAA;ErByzFP;AqBvzFC;;;EAGE,wBAAA;ErByzFH;AqBpzFG;;;;;;;;;;;;;;;EAKE,2BAAA;EACI,uBAAA;ErBg0FT;AoB9xFD;EC7BI,gBAAA;EACA,2BAAA;ErB8zFH;AoB9xFD;ECjEE,gBAAA;EACA,2BAAA;EACA,uBAAA;ErBk2FD;AqBh2FC;;;;;EAKE,gBAAA;EACA,2BAAA;EACI,uBAAA;ErBk2FP;AqBh2FC;;;EAGE,wBAAA;ErBk2FH;AqB71FG;;;;;;;;;;;;;;;EAKE,2BAAA;EACI,uBAAA;ErBy2FT;AoBn0FD;ECjCI,gBAAA;EACA,2BAAA;ErBu2FH;AoBn0FD;ECrEE,gBAAA;EACA,2BAAA;EACA,uBAAA;ErB24FD;AqBz4FC;;;;;EAKE,gBAAA;EACA,2BAAA;EACI,uBAAA;ErB24FP;AqBz4FC;;;EAGE,wBAAA;ErB24FH;AqBt4FG;;;;;;;;;;;;;;;EAKE,2BAAA;EACI,uBAAA;ErBk5FT;AoBx2FD;ECrCI,gBAAA;EACA,2BAAA;ErBg5FH;AoBn2FD;EACE,gBAAA;EACA,qBAAA;EACA,iBAAA;EACA,kBAAA;EpBq2FD;AoBn2FC;;;;EAIE,+BAAA;Ef1BF,0BAAA;EACQ,kBAAA;ELg4FT;AoBp2FC;;;;EAIE,2BAAA;EpBs2FH;AoBp2FC;;EAEE,gBAAA;EACA,4BAAA;EACA,+BAAA;EpBs2FH;AoBl2FG;;;;EAEE,gBAAA;EACA,uBAAA;EpBs2FL;AoB71FD;;EC9EE,oBAAA;EACA,iBAAA;EACA,mBAAA;EACA,oBAAA;ErB+6FD;AoBh2FD;;EClFE,mBAAA;EACA,iBAAA;EACA,kBAAA;EACA,oBAAA;ErBs7FD;AoBn2FD;;ECtFE,kBAAA;EACA,iBAAA;EACA,kBAAA;EACA,oBAAA;ErB67FD;AoBl2FD;EACE,gBAAA;EACA,aAAA;EpBo2FD;AoBh2FD;EACE,iBAAA;EpBk2FD;AoB31FC;;;EACE,aAAA;EpB+1FH;AuBh/FD;EACE,YAAA;ElBiLA,0CAAA;EACK,qCAAA;EACG,kCAAA;ELk0FT;AuBn/FC;EACE,YAAA;EvBq/FH;AuBj/FD;EACE,eAAA;EvBm/FD;AuBj/FC;EAAY,gBAAA;EvBo/Fb;AuBn/FC;EAAY,oBAAA;EvBs/Fb;AuBr/FC;EAAY,0BAAA;EvBw/Fb;AuBr/FD;EACE,oBAAA;EACA,WAAA;EACA,kBAAA;ElB+JA,uCAAA;EACK,kCAAA;EACG,+BAAA;ELy1FT;AwBhhGD;EACE,uBAAA;EACA,UAAA;EACA,WAAA;EACA,kBAAA;EACA,wBAAA;EACA,uBAAA;EACA,qCAAA;EACA,oCAAA;ExBkhGD;AwB9gGD;EACE,oBAAA;ExBghGD;AwB5gGD;EACE,YAAA;ExB8gGD;AwB1gGD;EACE,oBAAA;EACA,WAAA;EACA,SAAA;EACA,eAAA;EACA,eAAA;EACA,aAAA;EACA,kBAAA;EACA,gBAAA;EACA,iBAAA;EACA,kBAAA;EACA,iBAAA;EACA,kBAAA;EACA,2BAAA;EACA,2BAAA;EACA,uCAAA;EACA,oBAAA;EnBwBA,qDAAA;EACQ,6CAAA;EmBvBR,sCAAA;EAAA,8BAAA;ExB6gGD;AwBxgGC;EACE,UAAA;EACA,YAAA;ExB0gGH;AwBniGD;ECvBE,aAAA;EACA,eAAA;EACA,kBAAA;EACA,2BAAA;EzB6jGD;AwBziGD;EAmCI,gBAAA;EACA,mBAAA;EACA,aAAA;EACA,qBAAA;EACA,yBAAA;EACA,gBAAA;EACA,qBAAA;ExBygGH;AwBngGC;;EAEE,uBAAA;EACA,gBAAA;EACA,2BAAA;ExBqgGH;AwB//FC;;;EAGE,gBAAA;EACA,uBAAA;EACA,YAAA;EACA,2BAAA;ExBigGH;AwBx/FC;;;EAGE,gBAAA;ExB0/FH;AwBr/FC;;EAEE,uBAAA;EACA,+BAAA;EACA,wBAAA;EE1GF,qEAAA;EF4GE,qBAAA;ExBu/FH;AwBl/FD;EAGI,gBAAA;ExBk/FH;AwBr/FD;EAQI,YAAA;ExBg/FH;AwBx+FD;EACE,YAAA;EACA,UAAA;ExB0+FD;AwBl+FD;EACE,SAAA;EACA,aAAA;ExBo+FD;AwBh+FD;EACE,gBAAA;EACA,mBAAA;EACA,iBAAA;EACA,yBAAA;EACA,gBAAA;EACA,qBAAA;ExBk+FD;AwB99FD;EACE,iBAAA;EACA,SAAA;EACA,UAAA;EACA,WAAA;EACA,QAAA;EACA,cAAA;ExBg+FD;AwB59FD;EACE,UAAA;EACA,YAAA;ExB89FD;AwBt9FD;;EAII,eAAA;EACA,0BAAA;EACA,aAAA;ExBs9FH;AwB59FD;;EAUI,WAAA;EACA,cAAA;EACA,oBAAA;ExBs9FH;AwBh8FD;EAZE;IAnEA,YAAA;IACA,UAAA;IxBmhGC;EwBj9FD;IAzDA,SAAA;IACA,aAAA;IxB6gGC;EACF;A2B5pGD;;EAEE,oBAAA;EACA,uBAAA;EACA,wBAAA;E3B8pGD;A2BlqGD;;EAMI,oBAAA;EACA,aAAA;E3BgqGH;A2B9pGG;;;;;;;;EAIE,YAAA;E3BoqGL;A2BlqGG;;EAEE,YAAA;E3BoqGL;A2B9pGD;;;;EAKI,mBAAA;E3B+pGH;A2B1pGD;EACE,mBAAA;E3B4pGD;A2B7pGD;;EAMI,aAAA;E3B2pGH;A2BjqGD;;;EAWI,kBAAA;E3B2pGH;A2BvpGD;EACE,kBAAA;E3BypGD;A2BrpGD;EACE,gBAAA;E3BupGD;A2BtpGC;ECrDA,+BAAA;EACG,4BAAA;E5B8sGJ;A2BrpGD;;EClDE,8BAAA;EACG,2BAAA;E5B2sGJ;A2BppGD;EACE,aAAA;E3BspGD;A2BppGD;EACE,kBAAA;E3BspGD;A2BppGD;;ECtEE,+BAAA;EACG,4BAAA;E5B8tGJ;A2BnpGD;ECpEE,8BAAA;EACG,2BAAA;E5B0tGJ;A2BlpGD;;EAEE,YAAA;E3BopGD;A2BnoGD;EACE,mBAAA;EACA,oBAAA;E3BqoGD;A2BnoGD;EACE,oBAAA;EACA,qBAAA;E3BqoGD;A2BhoGD;EtBlDE,0DAAA;EACQ,kDAAA;ELqrGT;A2BhoGC;EtBtDA,0BAAA;EACQ,kBAAA;ELyrGT;A2B7nGD;EACE,gBAAA;E3B+nGD;A2B5nGD;EACE,yBAAA;EACA,wBAAA;E3B8nGD;A2B3nGD;EACE,yBAAA;E3B6nGD;A2BtnGD;;;EAII,gBAAA;EACA,aAAA;EACA,aAAA;EACA,iBAAA;E3BunGH;A2B9nGD;EAcM,aAAA;E3BmnGL;A2BjoGD;;;;EAsBI,kBAAA;EACA,gBAAA;E3BinGH;A2B5mGC;EACE,kBAAA;E3B8mGH;A2B5mGC;EACE,8BAAA;ECvKF,+BAAA;EACC,8BAAA;E5BsxGF;A2B7mGC;EACE,gCAAA;ECnLF,4BAAA;EACC,2BAAA;E5BmyGF;A2B7mGD;EACE,kBAAA;E3B+mGD;A2B7mGD;;EClLE,+BAAA;EACC,8BAAA;E5BmyGF;A2B5mGD;EChME,4BAAA;EACC,2BAAA;E5B+yGF;A2BvmGD;EACE,gBAAA;EACA,aAAA;EACA,qBAAA;EACA,2BAAA;E3BymGD;A2B7mGD;;EAOI,aAAA;EACA,qBAAA;EACA,WAAA;E3B0mGH;A2BnnGD;EAYI,aAAA;E3B0mGH;A2BtnGD;EAgBI,YAAA;E3BymGH;A2B3lGD;;EAEE,oBAAA;EACA,aAAA;EL1OA,YAAA;EAGA,0BAAA;EtBs0GD;A6Bt0GD;EACE,oBAAA;EACA,gBAAA;EACA,2BAAA;E7Bw0GD;A6Br0GC;EACE,aAAA;EACA,iBAAA;EACA,kBAAA;E7Bu0GH;A6Bh1GD;EAeI,oBAAA;EACA,YAAA;EAKA,aAAA;EAEA,aAAA;EACA,kBAAA;E7B+zGH;A6BtzGD;;;EV0BE,cAAA;EACA,oBAAA;EACA,iBAAA;EACA,mBAAA;EACA,oBAAA;EnBiyGD;AmB/xGC;;;EACE,cAAA;EACA,mBAAA;EnBmyGH;AmBhyGC;;;;;;EAEE,cAAA;EnBsyGH;A6Bx0GD;;;EVqBE,cAAA;EACA,mBAAA;EACA,iBAAA;EACA,kBAAA;EACA,oBAAA;EnBwzGD;AmBtzGC;;;EACE,cAAA;EACA,mBAAA;EnB0zGH;AmBvzGC;;;;;;EAEE,cAAA;EnB6zGH;A6Bt1GD;;;EAGE,qBAAA;E7Bw1GD;A6Bt1GC;;;EACE,kBAAA;E7B01GH;A6Bt1GD;;EAEE,WAAA;EACA,qBAAA;EACA,wBAAA;E7Bw1GD;A6Bn1GD;EACE,mBAAA;EACA,iBAAA;EACA,qBAAA;EACA,gBAAA;EACA,gBAAA;EACA,oBAAA;EACA,2BAAA;EACA,2BAAA;EACA,oBAAA;E7Bq1GD;A6Bl1GC;EACE,mBAAA;EACA,iBAAA;EACA,oBAAA;E7Bo1GH;A6Bl1GC;EACE,oBAAA;EACA,iBAAA;EACA,oBAAA;E7Bo1GH;A6Bx2GD;;EA0BI,eAAA;E7Bk1GH;A6B70GD;;;;;;;EDhGE,+BAAA;EACG,4BAAA;E5Bs7GJ;A6B90GD;EACE,iBAAA;E7Bg1GD;A6B90GD;;;;;;;EDpGE,8BAAA;EACG,2BAAA;E5B27GJ;A6B/0GD;EACE,gBAAA;E7Bi1GD;A6B50GD;EACE,oBAAA;EAGA,cAAA;EACA,qBAAA;E7B40GD;A6Bj1GD;EAUI,oBAAA;E7B00GH;A6Bp1GD;EAYM,mBAAA;E7B20GL;A6Bx0GG;;;EAGE,YAAA;E7B00GL;A6Br0GC;;EAGI,oBAAA;E7Bs0GL;A6Bn0GC;;EAGI,mBAAA;E7Bo0GL;A8B99GD;EACE,kBAAA;EACA,iBAAA;EACA,kBAAA;E9Bg+GD;A8Bn+GD;EAOI,oBAAA;EACA,gBAAA;E9B+9GH;A8Bv+GD;EAWM,oBAAA;EACA,gBAAA;EACA,oBAAA;E9B+9GL;A8B99GK;;EAEE,uBAAA;EACA,2BAAA;E9Bg+GP;A8B39GG;EACE,gBAAA;E9B69GL;A8B39GK;;EAEE,gBAAA;EACA,uBAAA;EACA,+BAAA;EACA,qBAAA;E9B69GP;A8Bt9GG;;;EAGE,2BAAA;EACA,uBAAA;E9Bw9GL;A8BjgHD;ELHE,aAAA;EACA,eAAA;EACA,kBAAA;EACA,2BAAA;EzBugHD;A8BvgHD;EA0DI,iBAAA;E9Bg9GH;A8Bv8GD;EACE,kCAAA;E9By8GD;A8B18GD;EAGI,aAAA;EAEA,qBAAA;E9By8GH;A8B98GD;EASM,mBAAA;EACA,yBAAA;EACA,+BAAA;EACA,4BAAA;E9Bw8GL;A8Bv8GK;EACE,uCAAA;E9By8GP;A8Bn8GK;;;EAGE,gBAAA;EACA,2BAAA;EACA,2BAAA;EACA,kCAAA;EACA,iBAAA;E9Bq8GP;A8Bh8GC;EAqDA,aAAA;EA8BA,kBAAA;E9Bi3GD;A8Bp8GC;EAwDE,aAAA;E9B+4GH;A8Bv8GC;EA0DI,oBAAA;EACA,oBAAA;E9Bg5GL;A8B38GC;EAgEE,WAAA;EACA,YAAA;E9B84GH;A8Bl4GD;EAAA;IAPM,qBAAA;IACA,WAAA;I9B64GH;E8Bv4GH;IAJQ,kBAAA;I9B84GL;EACF;A8Bx9GC;EAuFE,iBAAA;EACA,oBAAA;E9Bo4GH;A8B59GC;;;EA8FE,2BAAA;E9Bm4GH;A8Br3GD;EAAA;IATM,kCAAA;IACA,4BAAA;I9Bk4GH;E8B13GH;;;IAHM,8BAAA;I9Bk4GH;EACF;A8Bn+GD;EAEI,aAAA;E9Bo+GH;A8Bt+GD;EAMM,oBAAA;E9Bm+GL;A8Bz+GD;EASM,kBAAA;E9Bm+GL;A8B99GK;;;EAGE,gBAAA;EACA,2BAAA;E9Bg+GP;A8Bx9GD;EAEI,aAAA;E9By9GH;A8B39GD;EAIM,iBAAA;EACA,gBAAA;E9B09GL;A8B98GD;EACE,aAAA;E9Bg9GD;A8Bj9GD;EAII,aAAA;E9Bg9GH;A8Bp9GD;EAMM,oBAAA;EACA,oBAAA;E9Bi9GL;A8Bx9GD;EAYI,WAAA;EACA,YAAA;E9B+8GH;A8Bn8GD;EAAA;IAPM,qBAAA;IACA,WAAA;I9B88GH;E8Bx8GH;IAJQ,kBAAA;I9B+8GL;EACF;A8Bv8GD;EACE,kBAAA;E9By8GD;A8B18GD;EAKI,iBAAA;EACA,oBAAA;E9Bw8GH;A8B98GD;;;EAYI,2BAAA;E9Bu8GH;A8Bz7GD;EAAA;IATM,kCAAA;IACA,4BAAA;I9Bs8GH;E8B97GH;;;IAHM,8BAAA;I9Bs8GH;EACF;A8B77GD;EAEI,eAAA;E9B87GH;A8Bh8GD;EAKI,gBAAA;E9B87GH;A8Br7GD;EAEE,kBAAA;EF3OA,4BAAA;EACC,2BAAA;E5BkqHF;A+B5pHD;EACE,oBAAA;EACA,kBAAA;EACA,qBAAA;EACA,+BAAA;E/B8pHD;A+BtpHD;EAAA;IAFI,oBAAA;I/B4pHD;EACF;A+B7oHD;EAAA;IAFI,aAAA;I/BmpHD;EACF;A+BroHD;EACE,qBAAA;EACA,qBAAA;EACA,oBAAA;EACA,mCAAA;EACA,4DAAA;EAAA,oDAAA;EAEA,mCAAA;E/BsoHD;A+BpoHC;EACE,kBAAA;E/BsoHH;A+B1mHD;EAAA;IAxBI,aAAA;IACA,eAAA;IACA,0BAAA;IAAA,kBAAA;I/BsoHD;E+BpoHC;IACE,2BAAA;IACA,yBAAA;IACA,mBAAA;IACA,8BAAA;I/BsoHH;E+BnoHC;IACE,qBAAA;I/BqoHH;E+BhoHC;;;IAGE,iBAAA;IACA,kBAAA;I/BkoHH;EACF;A+B9nHD;;EAGI,mBAAA;E/B+nHH;A+B1nHC;EAAA;;IAFI,mBAAA;I/BioHH;EACF;A+BxnHD;;;;EAII,qBAAA;EACA,oBAAA;E/B0nHH;A+BpnHC;EAAA;;;;IAHI,iBAAA;IACA,gBAAA;I/B8nHH;EACF;A+BlnHD;EACE,eAAA;EACA,uBAAA;E/BonHD;A+B/mHD;EAAA;IAFI,kBAAA;I/BqnHD;EACF;A+BjnHD;;EAEE,iBAAA;EACA,UAAA;EACA,SAAA;EACA,eAAA;E1BGA,yCAAA;EACQ,oCAAA;EAAA,iCAAA;ELinHT;A+B9mHD;EAAA;;IAFI,kBAAA;I/BqnHD;EACF;A+BnnHD;EACE,QAAA;EACA,uBAAA;E/BqnHD;A+BnnHD;EACE,WAAA;EACA,kBAAA;EACA,uBAAA;E/BqnHD;A+B/mHD;EACE,aAAA;EACA,oBAAA;EACA,iBAAA;EACA,mBAAA;EACA,cAAA;E/BinHD;A+B/mHC;;EAEE,uBAAA;E/BinHH;A+BxmHD;EALI;;IAEE,oBAAA;I/BgnHH;EACF;A+BtmHD;EACE,oBAAA;EACA,cAAA;EACA,oBAAA;EACA,mBAAA;EC3LA,iBAAA;EACA,oBAAA;ED4LA,+BAAA;EACA,wBAAA;EACA,+BAAA;EACA,oBAAA;E/BymHD;A+BrmHC;EACE,YAAA;E/BumHH;A+BrnHD;EAmBI,gBAAA;EACA,aAAA;EACA,aAAA;EACA,oBAAA;E/BqmHH;A+B3nHD;EAyBI,iBAAA;E/BqmHH;A+B/lHD;EAAA;IAFI,eAAA;I/BqmHD;EACF;A+B5lHD;EACE,qBAAA;E/B8lHD;A+B/lHD;EAII,mBAAA;EACA,sBAAA;EACA,mBAAA;E/B8lHH;A+BnkHC;EAAA;IArBI,kBAAA;IACA,aAAA;IACA,aAAA;IACA,eAAA;IACA,+BAAA;IACA,WAAA;IACA,0BAAA;IAAA,kBAAA;I/B4lHH;E+B7kHD;;IAZM,4BAAA;I/B6lHL;E+BjlHD;IATM,mBAAA;I/B6lHL;E+B5lHK;;IAEE,wBAAA;I/B8lHP;EACF;A+BxkHD;EAAA;IAfI,aAAA;IACA,WAAA;I/B2lHD;E+B7kHH;IAXM,aAAA;I/B2lHH;E+BhlHH;IATQ,mBAAA;IACA,sBAAA;I/B4lHL;E+BxlHC;IACE,qBAAA;I/B0lHH;EACF;A+BzkHD;EALE;IE9QA,wBAAA;IjCg2HC;E+BjlHD;IElRA,yBAAA;IjCs2HC;EACF;A+B5kHD;EACE,oBAAA;EACA,qBAAA;EACA,oBAAA;EACA,mCAAA;EACA,sCAAA;E1B3OA,8FAAA;EACQ,sFAAA;E2B/DR,iBAAA;EACA,oBAAA;EhC03HD;AkBl7GD;EAAA;IA7DM,uBAAA;IACA,kBAAA;IACA,wBAAA;IlBm/GH;EkBx7GH;IAtDM,uBAAA;IACA,aAAA;IACA,wBAAA;IlBi/GH;EkB77GH;IAhDM,uBAAA;IACA,wBAAA;IlBg/GH;EkBj8GH;;;IA1CQ,aAAA;IlBg/GL;EkBt8GH;IApCM,aAAA;IlB6+GH;EkBz8GH;IAhCM,kBAAA;IACA,wBAAA;IlB4+GH;EkB78GH;;IAvBM,uBAAA;IACA,eAAA;IACA,kBAAA;IACA,wBAAA;IlBw+GH;EkBp9GH;;IAjBQ,iBAAA;IlBy+GL;EkBx9GH;;IAZM,oBAAA;IACA,gBAAA;IlBw+GH;EkB79GH;IAHM,QAAA;IlBm+GH;EACF;A+BtnHC;EAAA;IAFI,oBAAA;I/B4nHH;EACF;A+BvmHD;EAAA;IAbI,aAAA;IACA,WAAA;IACA,gBAAA;IACA,iBAAA;IACA,gBAAA;IACA,mBAAA;I1BlQF,0BAAA;IACQ,kBAAA;IL23HP;E+BtnHC;IACE,qBAAA;I/BwnHH;EACF;A+BhnHD;EACE,eAAA;EHlVA,4BAAA;EACC,2BAAA;E5Bq8HF;A+BhnHD;EH9UE,+BAAA;EACC,8BAAA;E5Bi8HF;A+B3mHD;EC5VE,iBAAA;EACA,oBAAA;EhC08HD;A+B5mHC;EC/VA,kBAAA;EACA,qBAAA;EhC88HD;A+B7mHC;EClWA,kBAAA;EACA,qBAAA;EhCk9HD;A+BvmHD;EC5WE,kBAAA;EACA,qBAAA;EhCs9HD;A+B9lHD;EAAA;IATI,aAAA;IACA,mBAAA;IACA,oBAAA;I/B2mHD;E+BxmHC;IACE,iBAAA;I/B0mHH;EACF;A+BlmHD;EACE,2BAAA;EACA,uBAAA;E/BomHD;A+BtmHD;EAKI,gBAAA;E/BomHH;A+BnmHG;;EAEE,gBAAA;EACA,+BAAA;E/BqmHL;A+B9mHD;EAcI,gBAAA;E/BmmHH;A+BjnHD;EAmBM,gBAAA;E/BimHL;A+B/lHK;;EAEE,gBAAA;EACA,+BAAA;E/BimHP;A+B7lHK;;;EAGE,gBAAA;EACA,2BAAA;E/B+lHP;A+B3lHK;;;EAGE,gBAAA;EACA,+BAAA;E/B6lHP;A+BroHD;EA8CI,uBAAA;E/B0lHH;A+BzlHG;;EAEE,2BAAA;E/B2lHL;A+B5oHD;EAoDM,2BAAA;E/B2lHL;A+B/oHD;;EA0DI,uBAAA;E/BylHH;A+BllHK;;;EAGE,2BAAA;EACA,gBAAA;E/BolHP;A+BnjHC;EAAA;IAzBQ,gBAAA;I/BglHP;E+B/kHO;;IAEE,gBAAA;IACA,+BAAA;I/BilHT;E+B7kHO;;;IAGE,gBAAA;IACA,2BAAA;I/B+kHT;E+B3kHO;;;IAGE,gBAAA;IACA,+BAAA;I/B6kHT;EACF;A+B/qHD;EA8GI,gBAAA;E/BokHH;A+BnkHG;EACE,gBAAA;E/BqkHL;A+BrrHD;EAqHI,gBAAA;E/BmkHH;A+BlkHG;;EAEE,gBAAA;E/BokHL;A+BhkHK;;;;EAEE,gBAAA;E/BokHP;A+B5jHD;EACE,2BAAA;EACA,uBAAA;E/B8jHD;A+BhkHD;EAKI,gBAAA;E/B8jHH;A+B7jHG;;EAEE,gBAAA;EACA,+BAAA;E/B+jHL;A+BxkHD;EAcI,gBAAA;E/B6jHH;A+B3kHD;EAmBM,gBAAA;E/B2jHL;A+BzjHK;;EAEE,gBAAA;EACA,+BAAA;E/B2jHP;A+BvjHK;;;EAGE,gBAAA;EACA,2BAAA;E/ByjHP;A+BrjHK;;;EAGE,gBAAA;EACA,+BAAA;E/BujHP;A+B/lHD;EA+CI,uBAAA;E/BmjHH;A+BljHG;;EAEE,2BAAA;E/BojHL;A+BtmHD;EAqDM,2BAAA;E/BojHL;A+BzmHD;;EA2DI,uBAAA;E/BkjHH;A+B5iHK;;;EAGE,2BAAA;EACA,gBAAA;E/B8iHP;A+BvgHC;EAAA;IA/BQ,uBAAA;I/B0iHP;E+B3gHD;IA5BQ,2BAAA;I/B0iHP;E+B9gHD;IAzBQ,gBAAA;I/B0iHP;E+BziHO;;IAEE,gBAAA;IACA,+BAAA;I/B2iHT;E+BviHO;;;IAGE,gBAAA;IACA,2BAAA;I/ByiHT;E+BriHO;;;IAGE,gBAAA;IACA,+BAAA;I/BuiHT;EACF;A+B/oHD;EA+GI,gBAAA;E/BmiHH;A+BliHG;EACE,gBAAA;E/BoiHL;A+BrpHD;EAsHI,gBAAA;E/BkiHH;A+BjiHG;;EAEE,gBAAA;E/BmiHL;A+B/hHK;;;;EAEE,gBAAA;E/BmiHP;AkCxqID;EACE,mBAAA;EACA,qBAAA;EACA,kBAAA;EACA,2BAAA;EACA,oBAAA;ElC0qID;AkC/qID;EAQI,uBAAA;ElC0qIH;AkClrID;EAWM,mBAAA;EACA,gBAAA;EACA,gBAAA;ElC0qIL;AkCvrID;EAkBI,gBAAA;ElCwqIH;AmC5rID;EACE,uBAAA;EACA,iBAAA;EACA,gBAAA;EACA,oBAAA;EnC8rID;AmClsID;EAOI,iBAAA;EnC8rIH;AmCrsID;;EAUM,oBAAA;EACA,aAAA;EACA,mBAAA;EACA,yBAAA;EACA,uBAAA;EACA,gBAAA;EACA,2BAAA;EACA,2BAAA;EACA,mBAAA;EnC+rIL;AmC7rIG;;EAGI,gBAAA;EPXN,gCAAA;EACG,6BAAA;E5B0sIJ;AmC5rIG;;EPvBF,iCAAA;EACG,8BAAA;E5ButIJ;AmCvrIG;;;;EAEE,gBAAA;EACA,2BAAA;EACA,uBAAA;EnC2rIL;AmCrrIG;;;;;;EAGE,YAAA;EACA,gBAAA;EACA,2BAAA;EACA,uBAAA;EACA,iBAAA;EnC0rIL;AmChvID;;;;;;EAiEM,gBAAA;EACA,2BAAA;EACA,uBAAA;EACA,qBAAA;EnCurIL;AmC9qID;;EC1EM,oBAAA;EACA,iBAAA;EpC4vIL;AoC1vIG;;ERMF,gCAAA;EACG,6BAAA;E5BwvIJ;AoCzvIG;;ERRF,iCAAA;EACG,8BAAA;E5BqwIJ;AmCxrID;;EC/EM,mBAAA;EACA,iBAAA;EpC2wIL;AoCzwIG;;ERMF,gCAAA;EACG,6BAAA;E5BuwIJ;AoCxwIG;;ERRF,iCAAA;EACG,8BAAA;E5BoxIJ;AqCvxID;EACE,iBAAA;EACA,gBAAA;EACA,kBAAA;EACA,oBAAA;ErCyxID;AqC7xID;EAOI,iBAAA;ErCyxIH;AqChyID;;EAUM,uBAAA;EACA,mBAAA;EACA,2BAAA;EACA,2BAAA;EACA,qBAAA;ErC0xIL;AqCxyID;;EAmBM,uBAAA;EACA,2BAAA;ErCyxIL;AqC7yID;;EA2BM,cAAA;ErCsxIL;AqCjzID;;EAkCM,aAAA;ErCmxIL;AqCrzID;;;;EA2CM,gBAAA;EACA,2BAAA;EACA,qBAAA;ErCgxIL;AsC9zID;EACE,iBAAA;EACA,yBAAA;EACA,gBAAA;EACA,mBAAA;EACA,gBAAA;EACA,gBAAA;EACA,oBAAA;EACA,qBAAA;EACA,0BAAA;EACA,sBAAA;EtCg0ID;AsC5zIG;;EAEE,gBAAA;EACA,uBAAA;EACA,iBAAA;EtC8zIL;AsCzzIC;EACE,eAAA;EtC2zIH;AsCvzIC;EACE,oBAAA;EACA,WAAA;EtCyzIH;AsClzID;ECtCE,2BAAA;EvC21ID;AuCx1IG;;EAEE,2BAAA;EvC01IL;AsCrzID;EC1CE,2BAAA;EvCk2ID;AuC/1IG;;EAEE,2BAAA;EvCi2IL;AsCxzID;EC9CE,2BAAA;EvCy2ID;AuCt2IG;;EAEE,2BAAA;EvCw2IL;AsC3zID;EClDE,2BAAA;EvCg3ID;AuC72IG;;EAEE,2BAAA;EvC+2IL;AsC9zID;ECtDE,2BAAA;EvCu3ID;AuCp3IG;;EAEE,2BAAA;EvCs3IL;AsCj0ID;EC1DE,2BAAA;EvC83ID;AuC33IG;;EAEE,2BAAA;EvC63IL;AwC/3ID;EACE,uBAAA;EACA,iBAAA;EACA,kBAAA;EACA,iBAAA;EACA,mBAAA;EACA,gBAAA;EACA,gBAAA;EACA,0BAAA;EACA,qBAAA;EACA,oBAAA;EACA,2BAAA;EACA,qBAAA;ExCi4ID;AwC93IC;EACE,eAAA;ExCg4IH;AwC53IC;EACE,oBAAA;EACA,WAAA;ExC83IH;AwC53IC;EACE,QAAA;EACA,kBAAA;ExC83IH;AwCz3IG;;EAEE,gBAAA;EACA,uBAAA;EACA,iBAAA;ExC23IL;AwCt3IC;;EAEE,gBAAA;EACA,2BAAA;ExCw3IH;AwCt3IC;EACE,kBAAA;ExCw3IH;AyCv6ID;EACE,eAAA;EACA,qBAAA;EACA,gBAAA;EACA,2BAAA;EzCy6ID;AyC76ID;;EAQI,gBAAA;EzCy6IH;AyCj7ID;EAWI,qBAAA;EACA,iBAAA;EACA,kBAAA;EzCy6IH;AyCt7ID;EAiBI,2BAAA;EzCw6IH;AyCr6IC;EACE,oBAAA;EzCu6IH;AyC57ID;EAyBI,iBAAA;EzCs6IH;AyCr5ID;EAAA;IAbI,mBAAA;IACA,sBAAA;IzCs6ID;EyCp6IC;IACE,oBAAA;IACA,qBAAA;IzCs6IH;EyC95IH;;IAHM,iBAAA;IzCq6IH;EACF;A0C58ID;EACE,gBAAA;EACA,cAAA;EACA,qBAAA;EACA,yBAAA;EACA,2BAAA;EACA,2BAAA;EACA,oBAAA;ErC8KA,0CAAA;EACK,qCAAA;EACG,kCAAA;ELiyIT;A0Cx9ID;;EAaI,mBAAA;EACA,oBAAA;E1C+8IH;A0C38IC;;;EAGE,uBAAA;E1C68IH;A0Cl+ID;EA0BI,cAAA;EACA,gBAAA;E1C28IH;A2Cp+ID;EACE,eAAA;EACA,qBAAA;EACA,+BAAA;EACA,oBAAA;E3Cs+ID;A2C1+ID;EAQI,eAAA;EAEA,gBAAA;E3Co+IH;A2C9+ID;EAcI,mBAAA;E3Cm+IH;A2Cj/ID;;EAoBI,kBAAA;E3Ci+IH;A2Cr/ID;EAuBI,iBAAA;E3Ci+IH;A2Cz9ID;;EAEE,qBAAA;E3C29ID;A2C79ID;;EAMI,oBAAA;EACA,WAAA;EACA,cAAA;EACA,gBAAA;E3C29IH;A2Cn9ID;ECrDE,2BAAA;EACA,uBAAA;EACA,gBAAA;E5C2gJD;A2Cx9ID;EChDI,2BAAA;E5C2gJH;A2C39ID;EC7CI,gBAAA;E5C2gJH;A2C39ID;ECxDE,2BAAA;EACA,uBAAA;EACA,gBAAA;E5CshJD;A2Ch+ID;ECnDI,2BAAA;E5CshJH;A2Cn+ID;EChDI,gBAAA;E5CshJH;A2Cn+ID;EC3DE,2BAAA;EACA,uBAAA;EACA,gBAAA;E5CiiJD;A2Cx+ID;ECtDI,2BAAA;E5CiiJH;A2C3+ID;ECnDI,gBAAA;E5CiiJH;A2C3+ID;EC9DE,2BAAA;EACA,uBAAA;EACA,gBAAA;E5C4iJD;A2Ch/ID;ECzDI,2BAAA;E5C4iJH;A2Cn/ID;ECtDI,gBAAA;E5C4iJH;A6C9iJD;EACE;IAAQ,6BAAA;I7CijJP;E6ChjJD;IAAQ,0BAAA;I7CmjJP;EACF;A6ChjJD;EACE;IAAQ,6BAAA;I7CmjJP;E6CljJD;IAAQ,0BAAA;I7CqjJP;EACF;A6CxjJD;EACE;IAAQ,6BAAA;I7CmjJP;E6CljJD;IAAQ,0BAAA;I7CqjJP;EACF;A6C7iJD;EACE,kBAAA;EACA,cAAA;EACA,qBAAA;EACA,2BAAA;EACA,oBAAA;ExCqCA,wDAAA;EACQ,gDAAA;EL2gJT;A6C5iJD;EACE,aAAA;EACA,WAAA;EACA,cAAA;EACA,iBAAA;EACA,mBAAA;EACA,gBAAA;EACA,oBAAA;EACA,2BAAA;ExCwBA,wDAAA;EACQ,gDAAA;EAsHR,qCAAA;EACK,gCAAA;EACG,6BAAA;ELk6IT;A6CziJD;;ECAI,+MAAA;EACA,0MAAA;EACA,uMAAA;EDCF,oCAAA;EAAA,4BAAA;E7C6iJD;A6CtiJD;;ExC7CE,4DAAA;EACK,uDAAA;EACG,oDAAA;ELulJT;A6CriJC;;EAEE,iBAAA;E7CuiJH;A6CpiJC;EACE,gBAAA;EACA,iBAAA;EACA,+BAAA;EACA,wBAAA;EACA,0BAAA;EAAA,kBAAA;E7CsiJH;A6C7hJD;EEvFE,2BAAA;E/CunJD;A+CpnJC;EDgDE,+MAAA;EACA,0MAAA;EACA,uMAAA;E9CukJH;A6CjiJD;EE3FE,2BAAA;E/C+nJD;A+C5nJC;EDgDE,+MAAA;EACA,0MAAA;EACA,uMAAA;E9C+kJH;A6CriJD;EE/FE,2BAAA;E/CuoJD;A+CpoJC;EDgDE,+MAAA;EACA,0MAAA;EACA,uMAAA;E9CulJH;A6CziJD;EEnGE,2BAAA;E/C+oJD;A+C5oJC;EDgDE,+MAAA;EACA,0MAAA;EACA,uMAAA;E9C+lJH;AgD9oJD;;EAEE,kBAAA;EACA,SAAA;EhDgpJD;AgD5oJD;;EAEE,kBAAA;EhD8oJD;AgD5oJD;EACE,eAAA;EhD8oJD;AgD1oJD;EACE,gBAAA;EhD4oJD;AgDxoJD;EACE,iBAAA;EhD0oJD;AgDnoJD;EAEI,oBAAA;EhDooJH;AgDtoJD;EAKI,mBAAA;EhDooJH;AgD3nJD;EACE,iBAAA;EACA,kBAAA;EhD6nJD;AiD1qJD;EAEE,qBAAA;EACA,iBAAA;EjD2qJD;AiDnqJD;EACE,oBAAA;EACA,gBAAA;EACA,oBAAA;EAEA,qBAAA;EACA,2BAAA;EACA,2BAAA;EjDoqJD;AiDjqJC;ErB3BA,8BAAA;EACC,6BAAA;E5B+rJF;AiDlqJC;EACE,kBAAA;ErBvBF,iCAAA;EACC,gCAAA;E5B4rJF;AiDprJD;EAoBI,cAAA;EjDmqJH;AiDvrJD;EAuBI,mBAAA;EjDmqJH;AiDzpJD;EACE,gBAAA;EjD2pJD;AiD5pJD;EAII,gBAAA;EjD2pJH;AiDvpJC;;EAEE,uBAAA;EACA,gBAAA;EACA,2BAAA;EjDypJH;AiDnpJC;;;EAGE,2BAAA;EACA,gBAAA;EjDqpJH;AiDzpJC;;;EAQI,gBAAA;EjDspJL;AiD9pJC;;;EAWI,gBAAA;EjDwpJL;AiDnpJC;;;EAGE,YAAA;EACA,gBAAA;EACA,2BAAA;EACA,uBAAA;EjDqpJH;AiD3pJC;;;;;;;;;EAYI,gBAAA;EjD0pJL;AiDtqJC;;;EAeI,gBAAA;EjD4pJL;AkD/vJC;EACE,gBAAA;EACA,2BAAA;ElDiwJH;AkD/vJG;EACE,gBAAA;ElDiwJL;AkDlwJG;EAII,gBAAA;ElDiwJP;AkD9vJK;;EAEE,gBAAA;EACA,2BAAA;ElDgwJP;AkD9vJK;;;EAGE,aAAA;EACA,2BAAA;EACA,uBAAA;ElDgwJP;AkDrxJC;EACE,gBAAA;EACA,2BAAA;ElDuxJH;AkDrxJG;EACE,gBAAA;ElDuxJL;AkDxxJG;EAII,gBAAA;ElDuxJP;AkDpxJK;;EAEE,gBAAA;EACA,2BAAA;ElDsxJP;AkDpxJK;;;EAGE,aAAA;EACA,2BAAA;EACA,uBAAA;ElDsxJP;AkD3yJC;EACE,gBAAA;EACA,2BAAA;ElD6yJH;AkD3yJG;EACE,gBAAA;ElD6yJL;AkD9yJG;EAII,gBAAA;ElD6yJP;AkD1yJK;;EAEE,gBAAA;EACA,2BAAA;ElD4yJP;AkD1yJK;;;EAGE,aAAA;EACA,2BAAA;EACA,uBAAA;ElD4yJP;AkDj0JC;EACE,gBAAA;EACA,2BAAA;ElDm0JH;AkDj0JG;EACE,gBAAA;ElDm0JL;AkDp0JG;EAII,gBAAA;ElDm0JP;AkDh0JK;;EAEE,gBAAA;EACA,2BAAA;ElDk0JP;AkDh0JK;;;EAGE,aAAA;EACA,2BAAA;EACA,uBAAA;ElDk0JP;AiD/tJD;EACE,eAAA;EACA,oBAAA;EjDiuJD;AiD/tJD;EACE,kBAAA;EACA,kBAAA;EjDiuJD;AmD51JD;EACE,qBAAA;EACA,2BAAA;EACA,+BAAA;EACA,oBAAA;E9C0DA,mDAAA;EACQ,2CAAA;ELqyJT;AmD31JD;EACE,eAAA;EnD61JD;AmDx1JD;EACE,oBAAA;EACA,sCAAA;EvBpBA,8BAAA;EACC,6BAAA;E5B+2JF;AmD91JD;EAMI,gBAAA;EnD21JH;AmDt1JD;EACE,eAAA;EACA,kBAAA;EACA,iBAAA;EACA,gBAAA;EnDw1JD;AmD51JD;EAOI,gBAAA;EnDw1JH;AmDn1JD;EACE,oBAAA;EACA,2BAAA;EACA,+BAAA;EvBpCA,iCAAA;EACC,gCAAA;E5B03JF;AmD70JD;EAEI,kBAAA;EnD80JH;AmDh1JD;EAKM,qBAAA;EACA,kBAAA;EnD80JL;AmD10JG;EAEI,eAAA;EvBlEN,8BAAA;EACC,6BAAA;E5B84JF;AmDx0JG;EAEI,kBAAA;EvBjEN,iCAAA;EACC,gCAAA;E5B24JF;AmDp0JD;EAEI,qBAAA;EnDq0JH;AmDl0JD;EACE,qBAAA;EnDo0JD;AmD5zJD;;;EAII,kBAAA;EnD6zJH;AmDj0JD;;EvB9FE,8BAAA;EACC,6BAAA;E5Bm6JF;AmDt0JD;;;;;;;;EAgBU,6BAAA;EnDg0JT;AmDh1JD;;;;;;;;EAoBU,8BAAA;EnDs0JT;AmD11JD;;EvBtFE,iCAAA;EACC,gCAAA;E5Bo7JF;AmD/1JD;;;;;;;;EAmCU,gCAAA;EnDs0JT;AmDz2JD;;;;;;;;EAuCU,iCAAA;EnD40JT;AmDn3JD;;EA8CI,+BAAA;EnDy0JH;AmDv3JD;;EAkDI,eAAA;EnDy0JH;AmD33JD;;EAsDI,WAAA;EnDy0JH;AmD/3JD;;;;;;;;;;;;EA6DU,gBAAA;EnDg1JT;AmD74JD;;;;;;;;;;;;EAiEU,iBAAA;EnD01JT;AmD35JD;;;;;;;;EA0EU,kBAAA;EnD21JT;AmDr6JD;;;;;;;;EAmFU,kBAAA;EnD41JT;AmD/6JD;EAyFI,WAAA;EACA,kBAAA;EnDy1JH;AmD/0JD;EACE,qBAAA;EnDi1JD;AmDl1JD;EAKI,kBAAA;EACA,oBAAA;EnDg1JH;AmDt1JD;EAQM,iBAAA;EnDi1JL;AmDz1JD;EAaI,kBAAA;EnD+0JH;AmD51JD;EAeM,+BAAA;EnDg1JL;AmD/1JD;EAmBI,eAAA;EnD+0JH;AmDl2JD;EAqBM,kCAAA;EnDg1JL;AmDz0JD;EC9NE,uBAAA;EpD0iKD;AoDxiKC;EACE,gBAAA;EACA,2BAAA;EACA,uBAAA;EpD0iKH;AoD7iKC;EAMI,2BAAA;EpD0iKL;AoDhjKC;EASI,gBAAA;EACA,2BAAA;EpD0iKL;AoDviKC;EAEI,8BAAA;EpDwiKL;AmDx1JD;ECjOE,uBAAA;EpD4jKD;AoD1jKC;EACE,gBAAA;EACA,2BAAA;EACA,uBAAA;EpD4jKH;AoD/jKC;EAMI,2BAAA;EpD4jKL;AoDlkKC;EASI,gBAAA;EACA,2BAAA;EpD4jKL;AoDzjKC;EAEI,8BAAA;EpD0jKL;AmDv2JD;ECpOE,uBAAA;EpD8kKD;AoD5kKC;EACE,gBAAA;EACA,2BAAA;EACA,uBAAA;EpD8kKH;AoDjlKC;EAMI,2BAAA;EpD8kKL;AoDplKC;EASI,gBAAA;EACA,2BAAA;EpD8kKL;AoD3kKC;EAEI,8BAAA;EpD4kKL;AmDt3JD;ECvOE,uBAAA;EpDgmKD;AoD9lKC;EACE,gBAAA;EACA,2BAAA;EACA,uBAAA;EpDgmKH;AoDnmKC;EAMI,2BAAA;EpDgmKL;AoDtmKC;EASI,gBAAA;EACA,2BAAA;EpDgmKL;AoD7lKC;EAEI,8BAAA;EpD8lKL;AmDr4JD;EC1OE,uBAAA;EpDknKD;AoDhnKC;EACE,gBAAA;EACA,2BAAA;EACA,uBAAA;EpDknKH;AoDrnKC;EAMI,2BAAA;EpDknKL;AoDxnKC;EASI,gBAAA;EACA,2BAAA;EpDknKL;AoD/mKC;EAEI,8BAAA;EpDgnKL;AmDp5JD;EC7OE,uBAAA;EpDooKD;AoDloKC;EACE,gBAAA;EACA,2BAAA;EACA,uBAAA;EpDooKH;AoDvoKC;EAMI,2BAAA;EpDooKL;AoD1oKC;EASI,gBAAA;EACA,2BAAA;EpDooKL;AoDjoKC;EAEI,8BAAA;EpDkoKL;AqDlpKD;EACE,oBAAA;EACA,gBAAA;EACA,WAAA;EACA,YAAA;EACA,kBAAA;ErDopKD;AqDzpKD;;;;EAWI,oBAAA;EACA,QAAA;EACA,SAAA;EACA,WAAA;EACA,cAAA;EACA,aAAA;EACA,WAAA;ErDopKH;AqDhpKC;EACE,wBAAA;ErDkpKH;AqD9oKC;EACE,qBAAA;ErDgpKH;AsDzqKD;EACE,kBAAA;EACA,eAAA;EACA,qBAAA;EACA,2BAAA;EACA,2BAAA;EACA,oBAAA;EjDwDA,yDAAA;EACQ,iDAAA;ELonKT;AsDnrKD;EASI,oBAAA;EACA,mCAAA;EtD6qKH;AsDxqKD;EACE,eAAA;EACA,oBAAA;EtD0qKD;AsDxqKD;EACE,cAAA;EACA,oBAAA;EtD0qKD;AuDhsKD;EACE,cAAA;EACA,iBAAA;EACA,mBAAA;EACA,gBAAA;EACA,gBAAA;EACA,8BAAA;EjCRA,cAAA;EAGA,2BAAA;EtBysKD;AuDjsKC;;EAEE,gBAAA;EACA,uBAAA;EACA,iBAAA;EjCfF,cAAA;EAGA,2BAAA;EtBitKD;AuD9rKC;EACE,YAAA;EACA,iBAAA;EACA,yBAAA;EACA,WAAA;EACA,0BAAA;EvDgsKH;AwDptKD;EACE,kBAAA;ExDstKD;AwDltKD;EACE,eAAA;EACA,kBAAA;EACA,iBAAA;EACA,QAAA;EACA,UAAA;EACA,WAAA;EACA,SAAA;EACA,eAAA;EACA,mCAAA;EAIA,YAAA;ExDitKD;AwD9sKC;EnDkHA,4CAAA;EACQ,uCAAA;EAAA,oCAAA;EA8DR,qDAAA;EAEK,2CAAA;EACG,qCAAA;ELkiKT;AwDltKC;EnD8GA,yCAAA;EACQ,oCAAA;EAAA,iCAAA;ELumKT;AwDptKD;EACE,oBAAA;EACA,kBAAA;ExDstKD;AwDltKD;EACE,oBAAA;EACA,aAAA;EACA,cAAA;ExDotKD;AwDhtKD;EACE,oBAAA;EACA,2BAAA;EACA,2BAAA;EACA,sCAAA;EACA,oBAAA;EnDaA,kDAAA;EACQ,0CAAA;EmDZR,sCAAA;EAAA,8BAAA;EAEA,YAAA;ExDktKD;AwD9sKD;EACE,iBAAA;EACA,QAAA;EACA,UAAA;EACA,WAAA;EACA,SAAA;EACA,eAAA;EACA,2BAAA;ExDgtKD;AwD9sKC;ElCrEA,YAAA;EAGA,0BAAA;EtBoxKD;AwDjtKC;ElCtEA,cAAA;EAGA,2BAAA;EtBwxKD;AwDhtKD;EACE,eAAA;EACA,kCAAA;EACA,2BAAA;ExDktKD;AwD/sKD;EACE,kBAAA;ExDitKD;AwD7sKD;EACE,WAAA;EACA,yBAAA;ExD+sKD;AwD1sKD;EACE,oBAAA;EACA,eAAA;ExD4sKD;AwDxsKD;EACE,eAAA;EACA,mBAAA;EACA,+BAAA;ExD0sKD;AwD7sKD;EAQI,kBAAA;EACA,kBAAA;ExDwsKH;AwDjtKD;EAaI,mBAAA;ExDusKH;AwDptKD;EAiBI,gBAAA;ExDssKH;AwDjsKD;EACE,oBAAA;EACA,cAAA;EACA,aAAA;EACA,cAAA;EACA,kBAAA;ExDmsKD;AwDjrKD;EAZE;IACE,cAAA;IACA,mBAAA;IxDgsKD;EwD9rKD;InDvEA,mDAAA;IACQ,2CAAA;ILwwKP;EwD7rKD;IAAY,cAAA;IxDgsKX;EACF;AwD3rKD;EAFE;IAAY,cAAA;IxDisKX;EACF;AyDh1KD;EACE,oBAAA;EACA,eAAA;EACA,gBAAA;EACA,qBAAA;EACA,iBAAA;EACA,kBAAA;EnCTA,YAAA;EAGA,0BAAA;EtB01KD;AyDj1KC;EnCZA,cAAA;EAGA,2BAAA;EtB81KD;AyDp1KC;EAAW,kBAAA;EAAmB,gBAAA;EzDw1K/B;AyDv1KC;EAAW,kBAAA;EAAmB,gBAAA;EzD21K/B;AyD11KC;EAAW,iBAAA;EAAmB,gBAAA;EzD81K/B;AyD71KC;EAAW,mBAAA;EAAmB,gBAAA;EzDi2K/B;AyD71KD;EACE,kBAAA;EACA,kBAAA;EACA,gBAAA;EACA,oBAAA;EACA,uBAAA;EACA,2BAAA;EACA,oBAAA;EzD+1KD;AyD31KD;EACE,oBAAA;EACA,UAAA;EACA,WAAA;EACA,2BAAA;EACA,qBAAA;EzD61KD;AyD11KC;EACE,WAAA;EACA,WAAA;EACA,mBAAA;EACA,yBAAA;EACA,2BAAA;EzD41KH;AyD11KC;EACE,WAAA;EACA,WAAA;EACA,yBAAA;EACA,2BAAA;EzD41KH;AyD11KC;EACE,WAAA;EACA,YAAA;EACA,yBAAA;EACA,2BAAA;EzD41KH;AyD11KC;EACE,UAAA;EACA,SAAA;EACA,kBAAA;EACA,6BAAA;EACA,6BAAA;EzD41KH;AyD11KC;EACE,UAAA;EACA,UAAA;EACA,kBAAA;EACA,6BAAA;EACA,4BAAA;EzD41KH;AyD11KC;EACE,QAAA;EACA,WAAA;EACA,mBAAA;EACA,yBAAA;EACA,8BAAA;EzD41KH;AyD11KC;EACE,QAAA;EACA,WAAA;EACA,yBAAA;EACA,8BAAA;EzD41KH;AyD11KC;EACE,QAAA;EACA,YAAA;EACA,yBAAA;EACA,8BAAA;EzD41KH;A0Dn7KD;EACE,oBAAA;EACA,QAAA;EACA,SAAA;EACA,eAAA;EACA,eAAA;EACA,kBAAA;EACA,cAAA;EACA,kBAAA;EACA,2BAAA;EACA,sCAAA;EAAA,8BAAA;EACA,2BAAA;EACA,sCAAA;EACA,oBAAA;ErDkDA,mDAAA;EACQ,2CAAA;EqD/CR,qBAAA;E1Do7KD;A0Dj7KC;EAAY,mBAAA;E1Do7Kb;A0Dn7KC;EAAY,mBAAA;E1Ds7Kb;A0Dr7KC;EAAY,kBAAA;E1Dw7Kb;A0Dv7KC;EAAY,oBAAA;E1D07Kb;A0Dv7KD;EACE,WAAA;EACA,mBAAA;EACA,iBAAA;EACA,qBAAA;EACA,mBAAA;EACA,2BAAA;EACA,kCAAA;EACA,4BAAA;E1Dy7KD;A0Dt7KD;EACE,mBAAA;E1Dw7KD;A0Dh7KC;;EAEE,oBAAA;EACA,gBAAA;EACA,UAAA;EACA,WAAA;EACA,2BAAA;EACA,qBAAA;E1Dk7KH;A0D/6KD;EACE,oBAAA;E1Di7KD;A0D/6KD;EACE,oBAAA;EACA,aAAA;E1Di7KD;A0D76KC;EACE,WAAA;EACA,oBAAA;EACA,wBAAA;EACA,2BAAA;EACA,uCAAA;EACA,eAAA;E1D+6KH;A0D96KG;EACE,cAAA;EACA,aAAA;EACA,oBAAA;EACA,wBAAA;EACA,2BAAA;E1Dg7KL;A0D76KC;EACE,UAAA;EACA,aAAA;EACA,mBAAA;EACA,sBAAA;EACA,6BAAA;EACA,yCAAA;E1D+6KH;A0D96KG;EACE,cAAA;EACA,WAAA;EACA,eAAA;EACA,sBAAA;EACA,6BAAA;E1Dg7KL;A0D76KC;EACE,WAAA;EACA,oBAAA;EACA,qBAAA;EACA,8BAAA;EACA,0CAAA;EACA,YAAA;E1D+6KH;A0D96KG;EACE,cAAA;EACA,UAAA;EACA,oBAAA;EACA,qBAAA;EACA,8BAAA;E1Dg7KL;A0D56KC;EACE,UAAA;EACA,cAAA;EACA,mBAAA;EACA,uBAAA;EACA,4BAAA;EACA,wCAAA;E1D86KH;A0D76KG;EACE,cAAA;EACA,YAAA;EACA,uBAAA;EACA,4BAAA;EACA,eAAA;E1D+6KL;A2DziLD;EACE,oBAAA;E3D2iLD;A2DxiLD;EACE,oBAAA;EACA,kBAAA;EACA,aAAA;E3D0iLD;A2D7iLD;EAMI,eAAA;EACA,oBAAA;EtD0KF,2CAAA;EACK,sCAAA;EACG,mCAAA;ELi4KT;A2DpjLD;;EAcM,gBAAA;E3D0iLL;A2DxjLD;;;EAqBI,gBAAA;E3DwiLH;A2D7jLD;EAyBI,SAAA;E3DuiLH;A2DhkLD;;EA8BI,oBAAA;EACA,QAAA;EACA,aAAA;E3DsiLH;A2DtkLD;EAoCI,YAAA;E3DqiLH;A2DzkLD;EAuCI,aAAA;E3DqiLH;A2D5kLD;;EA2CI,SAAA;E3DqiLH;A2DhlLD;EA+CI,aAAA;E3DoiLH;A2DnlLD;EAkDI,YAAA;E3DoiLH;A2D5hLD;EACE,oBAAA;EACA,QAAA;EACA,SAAA;EACA,WAAA;EACA,YAAA;ErCtEA,cAAA;EAGA,2BAAA;EqCqEA,iBAAA;EACA,gBAAA;EACA,oBAAA;EACA,2CAAA;E3D+hLD;A2D1hLC;Eb1EE,oGAAA;EACA,+FAAA;EACA,sHAAA;EAAA,gGAAA;EACA,6BAAA;EACA,wHAAA;E9CumLH;A2D9hLC;EACE,YAAA;EACA,UAAA;Eb/EA,oGAAA;EACA,+FAAA;EACA,sHAAA;EAAA,gGAAA;EACA,6BAAA;EACA,wHAAA;E9CgnLH;A2DhiLC;;EAEE,YAAA;EACA,gBAAA;EACA,uBAAA;ErC9FF,cAAA;EAGA,2BAAA;EtB+nLD;A2DjkLD;;;;EAsCI,oBAAA;EACA,UAAA;EACA,YAAA;EACA,uBAAA;E3DiiLH;A2D1kLD;;EA6CI,WAAA;EACA,oBAAA;E3DiiLH;A2D/kLD;;EAkDI,YAAA;EACA,qBAAA;E3DiiLH;A2DplLD;;EAuDI,aAAA;EACA,cAAA;EACA,mBAAA;EACA,oBAAA;E3DiiLH;A2D5hLG;EACE,kBAAA;E3D8hLL;A2D1hLG;EACE,kBAAA;E3D4hLL;A2DlhLD;EACE,oBAAA;EACA,cAAA;EACA,WAAA;EACA,aAAA;EACA,YAAA;EACA,mBAAA;EACA,iBAAA;EACA,kBAAA;EACA,oBAAA;E3DohLD;A2D7hLD;EAYI,uBAAA;EACA,aAAA;EACA,cAAA;EACA,aAAA;EACA,qBAAA;EACA,2BAAA;EACA,qBAAA;EACA,iBAAA;EAUA,2BAAA;EACA,oCAAA;E3D2gLH;A2DziLD;EAiCI,WAAA;EACA,aAAA;EACA,cAAA;EACA,2BAAA;E3D2gLH;A2DpgLD;EACE,oBAAA;EACA,WAAA;EACA,YAAA;EACA,cAAA;EACA,aAAA;EACA,mBAAA;EACA,sBAAA;EACA,gBAAA;EACA,oBAAA;EACA,2CAAA;E3DsgLD;A2DrgLC;EACE,mBAAA;E3DugLH;A2D99KD;EAhCE;;;;IAKI,aAAA;IACA,cAAA;IACA,mBAAA;IACA,iBAAA;I3DggLH;E2DxgLD;;IAYI,oBAAA;I3DggLH;E2D5gLD;;IAgBI,qBAAA;I3DggLH;E2D3/KD;IACE,WAAA;IACA,YAAA;IACA,sBAAA;I3D6/KD;E2Dz/KD;IACE,cAAA;I3D2/KD;EACF;A4D/tLC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAEE,cAAA;EACA,gBAAA;E5D6vLH;A4D3vLC;;;;;;;;;;;;;;;EACE,aAAA;E5D2wLH;AiCnxLD;E4BRE,gBAAA;EACA,mBAAA;EACA,oBAAA;E7D8xLD;AiCrxLD;EACE,yBAAA;EjCuxLD;AiCrxLD;EACE,wBAAA;EjCuxLD;AiC/wLD;EACE,0BAAA;EjCixLD;AiC/wLD;EACE,2BAAA;EjCixLD;AiC/wLD;EACE,oBAAA;EjCixLD;AiC/wLD;E6BzBE,aAAA;EACA,oBAAA;EACA,mBAAA;EACA,+BAAA;EACA,WAAA;E9D2yLD;AiC7wLD;EACE,0BAAA;EACA,+BAAA;EjC+wLD;AiCxwLD;EACE,iBAAA;E5B2FA,yCAAA;EACQ,oCAAA;EAAA,iCAAA;ELgrLT;A+D9yLD;EACE,qBAAA;E/DgzLD;A+D1yLD;;;;ECdE,0BAAA;EhE8zLD;A+DzyLD;;;;;;;;;;;;EAYE,0BAAA;E/D2yLD;A+DpyLD;EAAA;IChDE,2BAAA;IhEw1LC;EgEv1LD;IAAU,gBAAA;IhE01LT;EgEz1LD;IAAU,+BAAA;IhE41LT;EgE31LD;;IACU,gCAAA;IhE81LT;EACF;A+D9yLD;EAAA;IAFI,2BAAA;I/DozLD;EACF;A+D9yLD;EAAA;IAFI,4BAAA;I/DozLD;EACF;A+D9yLD;EAAA;IAFI,kCAAA;I/DozLD;EACF;A+D7yLD;EAAA;ICrEE,2BAAA;IhEs3LC;EgEr3LD;IAAU,gBAAA;IhEw3LT;EgEv3LD;IAAU,+BAAA;IhE03LT;EgEz3LD;;IACU,gCAAA;IhE43LT;EACF;A+DvzLD;EAAA;IAFI,2BAAA;I/D6zLD;EACF;A+DvzLD;EAAA;IAFI,4BAAA;I/D6zLD;EACF;A+DvzLD;EAAA;IAFI,kCAAA;I/D6zLD;EACF;A+DtzLD;EAAA;IC1FE,2BAAA;IhEo5LC;EgEn5LD;IAAU,gBAAA;IhEs5LT;EgEr5LD;IAAU,+BAAA;IhEw5LT;EgEv5LD;;IACU,gCAAA;IhE05LT;EACF;A+Dh0LD;EAAA;IAFI,2BAAA;I/Ds0LD;EACF;A+Dh0LD;EAAA;IAFI,4BAAA;I/Ds0LD;EACF;A+Dh0LD;EAAA;IAFI,kCAAA;I/Ds0LD;EACF;A+D/zLD;EAAA;IC/GE,2BAAA;IhEk7LC;EgEj7LD;IAAU,gBAAA;IhEo7LT;EgEn7LD;IAAU,+BAAA;IhEs7LT;EgEr7LD;;IACU,gCAAA;IhEw7LT;EACF;A+Dz0LD;EAAA;IAFI,2BAAA;I/D+0LD;EACF;A+Dz0LD;EAAA;IAFI,4BAAA;I/D+0LD;EACF;A+Dz0LD;EAAA;IAFI,kCAAA;I/D+0LD;EACF;A+Dx0LD;EAAA;IC5HE,0BAAA;IhEw8LC;EACF;A+Dx0LD;EAAA;ICjIE,0BAAA;IhE68LC;EACF;A+Dx0LD;EAAA;ICtIE,0BAAA;IhEk9LC;EACF;A+Dx0LD;EAAA;IC3IE,0BAAA;IhEu9LC;EACF;A+Dr0LD;ECnJE,0BAAA;EhE29LD;A+Dl0LD;EAAA;ICjKE,2BAAA;IhEu+LC;EgEt+LD;IAAU,gBAAA;IhEy+LT;EgEx+LD;IAAU,+BAAA;IhE2+LT;EgE1+LD;;IACU,gCAAA;IhE6+LT;EACF;A+Dh1LD;EACE,0BAAA;E/Dk1LD;A+D70LD;EAAA;IAFI,2BAAA;I/Dm1LD;EACF;A+Dj1LD;EACE,0BAAA;E/Dm1LD;A+D90LD;EAAA;IAFI,4BAAA;I/Do1LD;EACF;A+Dl1LD;EACE,0BAAA;E/Do1LD;A+D/0LD;EAAA;IAFI,kCAAA;I/Dq1LD;EACF;A+D90LD;EAAA;ICpLE,0BAAA;IhEsgMC;EACF","sourcesContent":[null,"/*! normalize.css v3.0.1 | MIT License | git.io/normalize */\n\n//\n// 1. Set default font family to sans-serif.\n// 2. Prevent iOS text size adjust after orientation change, without disabling\n// user zoom.\n//\n\nhtml {\n font-family: sans-serif; // 1\n -ms-text-size-adjust: 100%; // 2\n -webkit-text-size-adjust: 100%; // 2\n}\n\n//\n// Remove default margin.\n//\n\nbody {\n margin: 0;\n}\n\n// HTML5 display definitions\n// ==========================================================================\n\n//\n// Correct `block` display not defined for any HTML5 element in IE 8/9.\n// Correct `block` display not defined for `details` or `summary` in IE 10/11 and Firefox.\n// Correct `block` display not defined for `main` in IE 11.\n//\n\narticle,\naside,\ndetails,\nfigcaption,\nfigure,\nfooter,\nheader,\nhgroup,\nmain,\nnav,\nsection,\nsummary {\n display: block;\n}\n\n//\n// 1. Correct `inline-block` display not defined in IE 8/9.\n// 2. Normalize vertical alignment of `progress` in Chrome, Firefox, and Opera.\n//\n\naudio,\ncanvas,\nprogress,\nvideo {\n display: inline-block; // 1\n vertical-align: baseline; // 2\n}\n\n//\n// Prevent modern browsers from displaying `audio` without controls.\n// Remove excess height in iOS 5 devices.\n//\n\naudio:not([controls]) {\n display: none;\n height: 0;\n}\n\n//\n// Address `[hidden]` styling not present in IE 8/9/10.\n// Hide the `template` element in IE 8/9/11, Safari, and Firefox < 22.\n//\n\n[hidden],\ntemplate {\n display: none;\n}\n\n// Links\n// ==========================================================================\n\n//\n// Remove the gray background color from active links in IE 10.\n//\n\na {\n background: transparent;\n}\n\n//\n// Improve readability when focused and also mouse hovered in all browsers.\n//\n\na:active,\na:hover {\n outline: 0;\n}\n\n// Text-level semantics\n// ==========================================================================\n\n//\n// Address styling not present in IE 8/9/10/11, Safari, and Chrome.\n//\n\nabbr[title] {\n border-bottom: 1px dotted;\n}\n\n//\n// Address style set to `bolder` in Firefox 4+, Safari, and Chrome.\n//\n\nb,\nstrong {\n font-weight: bold;\n}\n\n//\n// Address styling not present in Safari and Chrome.\n//\n\ndfn {\n font-style: italic;\n}\n\n//\n// Address variable `h1` font-size and margin within `section` and `article`\n// contexts in Firefox 4+, Safari, and Chrome.\n//\n\nh1 {\n font-size: 2em;\n margin: 0.67em 0;\n}\n\n//\n// Address styling not present in IE 8/9.\n//\n\nmark {\n background: #ff0;\n color: #000;\n}\n\n//\n// Address inconsistent and variable font size in all browsers.\n//\n\nsmall {\n font-size: 80%;\n}\n\n//\n// Prevent `sub` and `sup` affecting `line-height` in all browsers.\n//\n\nsub,\nsup {\n font-size: 75%;\n line-height: 0;\n position: relative;\n vertical-align: baseline;\n}\n\nsup {\n top: -0.5em;\n}\n\nsub {\n bottom: -0.25em;\n}\n\n// Embedded content\n// ==========================================================================\n\n//\n// Remove border when inside `a` element in IE 8/9/10.\n//\n\nimg {\n border: 0;\n}\n\n//\n// Correct overflow not hidden in IE 9/10/11.\n//\n\nsvg:not(:root) {\n overflow: hidden;\n}\n\n// Grouping content\n// ==========================================================================\n\n//\n// Address margin not present in IE 8/9 and Safari.\n//\n\nfigure {\n margin: 1em 40px;\n}\n\n//\n// Address differences between Firefox and other browsers.\n//\n\nhr {\n -moz-box-sizing: content-box;\n box-sizing: content-box;\n height: 0;\n}\n\n//\n// Contain overflow in all browsers.\n//\n\npre {\n overflow: auto;\n}\n\n//\n// Address odd `em`-unit font size rendering in all browsers.\n//\n\ncode,\nkbd,\npre,\nsamp {\n font-family: monospace, monospace;\n font-size: 1em;\n}\n\n// Forms\n// ==========================================================================\n\n//\n// Known limitation: by default, Chrome and Safari on OS X allow very limited\n// styling of `select`, unless a `border` property is set.\n//\n\n//\n// 1. Correct color not being inherited.\n// Known issue: affects color of disabled elements.\n// 2. Correct font properties not being inherited.\n// 3. Address margins set differently in Firefox 4+, Safari, and Chrome.\n//\n\nbutton,\ninput,\noptgroup,\nselect,\ntextarea {\n color: inherit; // 1\n font: inherit; // 2\n margin: 0; // 3\n}\n\n//\n// Address `overflow` set to `hidden` in IE 8/9/10/11.\n//\n\nbutton {\n overflow: visible;\n}\n\n//\n// Address inconsistent `text-transform` inheritance for `button` and `select`.\n// All other form control elements do not inherit `text-transform` values.\n// Correct `button` style inheritance in Firefox, IE 8/9/10/11, and Opera.\n// Correct `select` style inheritance in Firefox.\n//\n\nbutton,\nselect {\n text-transform: none;\n}\n\n//\n// 1. Avoid the WebKit bug in Android 4.0.* where (2) destroys native `audio`\n// and `video` controls.\n// 2. Correct inability to style clickable `input` types in iOS.\n// 3. Improve usability and consistency of cursor style between image-type\n// `input` and others.\n//\n\nbutton,\nhtml input[type=\"button\"], // 1\ninput[type=\"reset\"],\ninput[type=\"submit\"] {\n -webkit-appearance: button; // 2\n cursor: pointer; // 3\n}\n\n//\n// Re-set default cursor for disabled elements.\n//\n\nbutton[disabled],\nhtml input[disabled] {\n cursor: default;\n}\n\n//\n// Remove inner padding and border in Firefox 4+.\n//\n\nbutton::-moz-focus-inner,\ninput::-moz-focus-inner {\n border: 0;\n padding: 0;\n}\n\n//\n// Address Firefox 4+ setting `line-height` on `input` using `!important` in\n// the UA stylesheet.\n//\n\ninput {\n line-height: normal;\n}\n\n//\n// It's recommended that you don't attempt to style these elements.\n// Firefox's implementation doesn't respect box-sizing, padding, or width.\n//\n// 1. Address box sizing set to `content-box` in IE 8/9/10.\n// 2. Remove excess padding in IE 8/9/10.\n//\n\ninput[type=\"checkbox\"],\ninput[type=\"radio\"] {\n box-sizing: border-box; // 1\n padding: 0; // 2\n}\n\n//\n// Fix the cursor style for Chrome's increment/decrement buttons. For certain\n// `font-size` values of the `input`, it causes the cursor style of the\n// decrement button to change from `default` to `text`.\n//\n\ninput[type=\"number\"]::-webkit-inner-spin-button,\ninput[type=\"number\"]::-webkit-outer-spin-button {\n height: auto;\n}\n\n//\n// 1. Address `appearance` set to `searchfield` in Safari and Chrome.\n// 2. Address `box-sizing` set to `border-box` in Safari and Chrome\n// (include `-moz` to future-proof).\n//\n\ninput[type=\"search\"] {\n -webkit-appearance: textfield; // 1\n -moz-box-sizing: content-box;\n -webkit-box-sizing: content-box; // 2\n box-sizing: content-box;\n}\n\n//\n// Remove inner padding and search cancel button in Safari and Chrome on OS X.\n// Safari (but not Chrome) clips the cancel button when the search input has\n// padding (and `textfield` appearance).\n//\n\ninput[type=\"search\"]::-webkit-search-cancel-button,\ninput[type=\"search\"]::-webkit-search-decoration {\n -webkit-appearance: none;\n}\n\n//\n// Define consistent border, margin, and padding.\n//\n\nfieldset {\n border: 1px solid #c0c0c0;\n margin: 0 2px;\n padding: 0.35em 0.625em 0.75em;\n}\n\n//\n// 1. Correct `color` not being inherited in IE 8/9/10/11.\n// 2. Remove padding so people aren't caught out if they zero out fieldsets.\n//\n\nlegend {\n border: 0; // 1\n padding: 0; // 2\n}\n\n//\n// Remove default vertical scrollbar in IE 8/9/10/11.\n//\n\ntextarea {\n overflow: auto;\n}\n\n//\n// Don't inherit the `font-weight` (applied by a rule above).\n// NOTE: the default cannot safely be changed in Chrome and Safari on OS X.\n//\n\noptgroup {\n font-weight: bold;\n}\n\n// Tables\n// ==========================================================================\n\n//\n// Remove most spacing between table cells.\n//\n\ntable {\n border-collapse: collapse;\n border-spacing: 0;\n}\n\ntd,\nth {\n padding: 0;\n}\n","//\n// Basic print styles\n// --------------------------------------------------\n// Source: https://github.com/h5bp/html5-boilerplate/blob/master/css/main.css\n\n@media print {\n\n * {\n text-shadow: none !important;\n color: #000 !important; // Black prints faster: h5bp.com/s\n background: transparent !important;\n box-shadow: none !important;\n }\n\n a,\n a:visited {\n text-decoration: underline;\n }\n\n a[href]:after {\n content: \" (\" attr(href) \")\";\n }\n\n abbr[title]:after {\n content: \" (\" attr(title) \")\";\n }\n\n // Don't show links for images, or javascript/internal links\n a[href^=\"javascript:\"]:after,\n a[href^=\"#\"]:after {\n content: \"\";\n }\n\n pre,\n blockquote {\n border: 1px solid #999;\n page-break-inside: avoid;\n }\n\n thead {\n display: table-header-group; // h5bp.com/t\n }\n\n tr,\n img {\n page-break-inside: avoid;\n }\n\n img {\n max-width: 100% !important;\n }\n\n p,\n h2,\n h3 {\n orphans: 3;\n widows: 3;\n }\n\n h2,\n h3 {\n page-break-after: avoid;\n }\n\n // Chrome (OSX) fix for https://github.com/twbs/bootstrap/issues/11245\n // Once fixed, we can just straight up remove this.\n select {\n background: #fff !important;\n }\n\n // Bootstrap components\n .navbar {\n display: none;\n }\n .table {\n td,\n th {\n background-color: #fff !important;\n }\n }\n .btn,\n .dropup > .btn {\n > .caret {\n border-top-color: #000 !important;\n }\n }\n .label {\n border: 1px solid #000;\n }\n\n .table {\n border-collapse: collapse !important;\n }\n .table-bordered {\n th,\n td {\n border: 1px solid #ddd !important;\n }\n }\n\n}\n","//\n// Glyphicons for Bootstrap\n//\n// Since icons are fonts, they can be placed anywhere text is placed and are\n// thus automatically sized to match the surrounding child. To use, create an\n// inline element with the appropriate classes, like so:\n//\n// <a href=\"#\"><span class=\"glyphicon glyphicon-star\"></span> Star</a>\n\n// Import the fonts\n@font-face {\n font-family: 'Glyphicons Halflings';\n src: url('@{icon-font-path}@{icon-font-name}.eot');\n src: url('@{icon-font-path}@{icon-font-name}.eot?#iefix') format('embedded-opentype'),\n url('@{icon-font-path}@{icon-font-name}.woff') format('woff'),\n url('@{icon-font-path}@{icon-font-name}.ttf') format('truetype'),\n url('@{icon-font-path}@{icon-font-name}.svg#@{icon-font-svg-id}') format('svg');\n}\n\n// Catchall baseclass\n.glyphicon {\n position: relative;\n top: 1px;\n display: inline-block;\n font-family: 'Glyphicons Halflings';\n font-style: normal;\n font-weight: normal;\n line-height: 1;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n}\n\n// Individual icons\n.glyphicon-asterisk { &:before { content: \"\\2a\"; } }\n.glyphicon-plus { &:before { content: \"\\2b\"; } }\n.glyphicon-euro { &:before { content: \"\\20ac\"; } }\n.glyphicon-minus { &:before { content: \"\\2212\"; } }\n.glyphicon-cloud { &:before { content: \"\\2601\"; } }\n.glyphicon-envelope { &:before { content: \"\\2709\"; } }\n.glyphicon-pencil { &:before { content: \"\\270f\"; } }\n.glyphicon-glass { &:before { content: \"\\e001\"; } }\n.glyphicon-music { &:before { content: \"\\e002\"; } }\n.glyphicon-search { &:before { content: \"\\e003\"; } }\n.glyphicon-heart { &:before { content: \"\\e005\"; } }\n.glyphicon-star { &:before { content: \"\\e006\"; } }\n.glyphicon-star-empty { &:before { content: \"\\e007\"; } }\n.glyphicon-user { &:before { content: \"\\e008\"; } }\n.glyphicon-film { &:before { content: \"\\e009\"; } }\n.glyphicon-th-large { &:before { content: \"\\e010\"; } }\n.glyphicon-th { &:before { content: \"\\e011\"; } }\n.glyphicon-th-list { &:before { content: \"\\e012\"; } }\n.glyphicon-ok { &:before { content: \"\\e013\"; } }\n.glyphicon-remove { &:before { content: \"\\e014\"; } }\n.glyphicon-zoom-in { &:before { content: \"\\e015\"; } }\n.glyphicon-zoom-out { &:before { content: \"\\e016\"; } }\n.glyphicon-off { &:before { content: \"\\e017\"; } }\n.glyphicon-signal { &:before { content: \"\\e018\"; } }\n.glyphicon-cog { &:before { content: \"\\e019\"; } }\n.glyphicon-trash { &:before { content: \"\\e020\"; } }\n.glyphicon-home { &:before { content: \"\\e021\"; } }\n.glyphicon-file { &:before { content: \"\\e022\"; } }\n.glyphicon-time { &:before { content: \"\\e023\"; } }\n.glyphicon-road { &:before { content: \"\\e024\"; } }\n.glyphicon-download-alt { &:before { content: \"\\e025\"; } }\n.glyphicon-download { &:before { content: \"\\e026\"; } }\n.glyphicon-upload { &:before { content: \"\\e027\"; } }\n.glyphicon-inbox { &:before { content: \"\\e028\"; } }\n.glyphicon-play-circle { &:before { content: \"\\e029\"; } }\n.glyphicon-repeat { &:before { content: \"\\e030\"; } }\n.glyphicon-refresh { &:before { content: \"\\e031\"; } }\n.glyphicon-list-alt { &:before { content: \"\\e032\"; } }\n.glyphicon-lock { &:before { content: \"\\e033\"; } }\n.glyphicon-flag { &:before { content: \"\\e034\"; } }\n.glyphicon-headphones { &:before { content: \"\\e035\"; } }\n.glyphicon-volume-off { &:before { content: \"\\e036\"; } }\n.glyphicon-volume-down { &:before { content: \"\\e037\"; } }\n.glyphicon-volume-up { &:before { content: \"\\e038\"; } }\n.glyphicon-qrcode { &:before { content: \"\\e039\"; } }\n.glyphicon-barcode { &:before { content: \"\\e040\"; } }\n.glyphicon-tag { &:before { content: \"\\e041\"; } }\n.glyphicon-tags { &:before { content: \"\\e042\"; } }\n.glyphicon-book { &:before { content: \"\\e043\"; } }\n.glyphicon-bookmark { &:before { content: \"\\e044\"; } }\n.glyphicon-print { &:before { content: \"\\e045\"; } }\n.glyphicon-camera { &:before { content: \"\\e046\"; } }\n.glyphicon-font { &:before { content: \"\\e047\"; } }\n.glyphicon-bold { &:before { content: \"\\e048\"; } }\n.glyphicon-italic { &:before { content: \"\\e049\"; } }\n.glyphicon-text-height { &:before { content: \"\\e050\"; } }\n.glyphicon-text-width { &:before { content: \"\\e051\"; } }\n.glyphicon-align-left { &:before { content: \"\\e052\"; } }\n.glyphicon-align-center { &:before { content: \"\\e053\"; } }\n.glyphicon-align-right { &:before { content: \"\\e054\"; } }\n.glyphicon-align-justify { &:before { content: \"\\e055\"; } }\n.glyphicon-list { &:before { content: \"\\e056\"; } }\n.glyphicon-indent-left { &:before { content: \"\\e057\"; } }\n.glyphicon-indent-right { &:before { content: \"\\e058\"; } }\n.glyphicon-facetime-video { &:before { content: \"\\e059\"; } }\n.glyphicon-picture { &:before { content: \"\\e060\"; } }\n.glyphicon-map-marker { &:before { content: \"\\e062\"; } }\n.glyphicon-adjust { &:before { content: \"\\e063\"; } }\n.glyphicon-tint { &:before { content: \"\\e064\"; } }\n.glyphicon-edit { &:before { content: \"\\e065\"; } }\n.glyphicon-share { &:before { content: \"\\e066\"; } }\n.glyphicon-check { &:before { content: \"\\e067\"; } }\n.glyphicon-move { &:before { content: \"\\e068\"; } }\n.glyphicon-step-backward { &:before { content: \"\\e069\"; } }\n.glyphicon-fast-backward { &:before { content: \"\\e070\"; } }\n.glyphicon-backward { &:before { content: \"\\e071\"; } }\n.glyphicon-play { &:before { content: \"\\e072\"; } }\n.glyphicon-pause { &:before { content: \"\\e073\"; } }\n.glyphicon-stop { &:before { content: \"\\e074\"; } }\n.glyphicon-forward { &:before { content: \"\\e075\"; } }\n.glyphicon-fast-forward { &:before { content: \"\\e076\"; } }\n.glyphicon-step-forward { &:before { content: \"\\e077\"; } }\n.glyphicon-eject { &:before { content: \"\\e078\"; } }\n.glyphicon-chevron-left { &:before { content: \"\\e079\"; } }\n.glyphicon-chevron-right { &:before { content: \"\\e080\"; } }\n.glyphicon-plus-sign { &:before { content: \"\\e081\"; } }\n.glyphicon-minus-sign { &:before { content: \"\\e082\"; } }\n.glyphicon-remove-sign { &:before { content: \"\\e083\"; } }\n.glyphicon-ok-sign { &:before { content: \"\\e084\"; } }\n.glyphicon-question-sign { &:before { content: \"\\e085\"; } }\n.glyphicon-info-sign { &:before { content: \"\\e086\"; } }\n.glyphicon-screenshot { &:before { content: \"\\e087\"; } }\n.glyphicon-remove-circle { &:before { content: \"\\e088\"; } }\n.glyphicon-ok-circle { &:before { content: \"\\e089\"; } }\n.glyphicon-ban-circle { &:before { content: \"\\e090\"; } }\n.glyphicon-arrow-left { &:before { content: \"\\e091\"; } }\n.glyphicon-arrow-right { &:before { content: \"\\e092\"; } }\n.glyphicon-arrow-up { &:before { content: \"\\e093\"; } }\n.glyphicon-arrow-down { &:before { content: \"\\e094\"; } }\n.glyphicon-share-alt { &:before { content: \"\\e095\"; } }\n.glyphicon-resize-full { &:before { content: \"\\e096\"; } }\n.glyphicon-resize-small { &:before { content: \"\\e097\"; } }\n.glyphicon-exclamation-sign { &:before { content: \"\\e101\"; } }\n.glyphicon-gift { &:before { content: \"\\e102\"; } }\n.glyphicon-leaf { &:before { content: \"\\e103\"; } }\n.glyphicon-fire { &:before { content: \"\\e104\"; } }\n.glyphicon-eye-open { &:before { content: \"\\e105\"; } }\n.glyphicon-eye-close { &:before { content: \"\\e106\"; } }\n.glyphicon-warning-sign { &:before { content: \"\\e107\"; } }\n.glyphicon-plane { &:before { content: \"\\e108\"; } }\n.glyphicon-calendar { &:before { content: \"\\e109\"; } }\n.glyphicon-random { &:before { content: \"\\e110\"; } }\n.glyphicon-comment { &:before { content: \"\\e111\"; } }\n.glyphicon-magnet { &:before { content: \"\\e112\"; } }\n.glyphicon-chevron-up { &:before { content: \"\\e113\"; } }\n.glyphicon-chevron-down { &:before { content: \"\\e114\"; } }\n.glyphicon-retweet { &:before { content: \"\\e115\"; } }\n.glyphicon-shopping-cart { &:before { content: \"\\e116\"; } }\n.glyphicon-folder-close { &:before { content: \"\\e117\"; } }\n.glyphicon-folder-open { &:before { content: \"\\e118\"; } }\n.glyphicon-resize-vertical { &:before { content: \"\\e119\"; } }\n.glyphicon-resize-horizontal { &:before { content: \"\\e120\"; } }\n.glyphicon-hdd { &:before { content: \"\\e121\"; } }\n.glyphicon-bullhorn { &:before { content: \"\\e122\"; } }\n.glyphicon-bell { &:before { content: \"\\e123\"; } }\n.glyphicon-certificate { &:before { content: \"\\e124\"; } }\n.glyphicon-thumbs-up { &:before { content: \"\\e125\"; } }\n.glyphicon-thumbs-down { &:before { content: \"\\e126\"; } }\n.glyphicon-hand-right { &:before { content: \"\\e127\"; } }\n.glyphicon-hand-left { &:before { content: \"\\e128\"; } }\n.glyphicon-hand-up { &:before { content: \"\\e129\"; } }\n.glyphicon-hand-down { &:before { content: \"\\e130\"; } }\n.glyphicon-circle-arrow-right { &:before { content: \"\\e131\"; } }\n.glyphicon-circle-arrow-left { &:before { content: \"\\e132\"; } }\n.glyphicon-circle-arrow-up { &:before { content: \"\\e133\"; } }\n.glyphicon-circle-arrow-down { &:before { content: \"\\e134\"; } }\n.glyphicon-globe { &:before { content: \"\\e135\"; } }\n.glyphicon-wrench { &:before { content: \"\\e136\"; } }\n.glyphicon-tasks { &:before { content: \"\\e137\"; } }\n.glyphicon-filter { &:before { content: \"\\e138\"; } }\n.glyphicon-briefcase { &:before { content: \"\\e139\"; } }\n.glyphicon-fullscreen { &:before { content: \"\\e140\"; } }\n.glyphicon-dashboard { &:before { content: \"\\e141\"; } }\n.glyphicon-paperclip { &:before { content: \"\\e142\"; } }\n.glyphicon-heart-empty { &:before { content: \"\\e143\"; } }\n.glyphicon-link { &:before { content: \"\\e144\"; } }\n.glyphicon-phone { &:before { content: \"\\e145\"; } }\n.glyphicon-pushpin { &:before { content: \"\\e146\"; } }\n.glyphicon-usd { &:before { content: \"\\e148\"; } }\n.glyphicon-gbp { &:before { content: \"\\e149\"; } }\n.glyphicon-sort { &:before { content: \"\\e150\"; } }\n.glyphicon-sort-by-alphabet { &:before { content: \"\\e151\"; } }\n.glyphicon-sort-by-alphabet-alt { &:before { content: \"\\e152\"; } }\n.glyphicon-sort-by-order { &:before { content: \"\\e153\"; } }\n.glyphicon-sort-by-order-alt { &:before { content: \"\\e154\"; } }\n.glyphicon-sort-by-attributes { &:before { content: \"\\e155\"; } }\n.glyphicon-sort-by-attributes-alt { &:before { content: \"\\e156\"; } }\n.glyphicon-unchecked { &:before { content: \"\\e157\"; } }\n.glyphicon-expand { &:before { content: \"\\e158\"; } }\n.glyphicon-collapse-down { &:before { content: \"\\e159\"; } }\n.glyphicon-collapse-up { &:before { content: \"\\e160\"; } }\n.glyphicon-log-in { &:before { content: \"\\e161\"; } }\n.glyphicon-flash { &:before { content: \"\\e162\"; } }\n.glyphicon-log-out { &:before { content: \"\\e163\"; } }\n.glyphicon-new-window { &:before { content: \"\\e164\"; } }\n.glyphicon-record { &:before { content: \"\\e165\"; } }\n.glyphicon-save { &:before { content: \"\\e166\"; } }\n.glyphicon-open { &:before { content: \"\\e167\"; } }\n.glyphicon-saved { &:before { content: \"\\e168\"; } }\n.glyphicon-import { &:before { content: \"\\e169\"; } }\n.glyphicon-export { &:before { content: \"\\e170\"; } }\n.glyphicon-send { &:before { content: \"\\e171\"; } }\n.glyphicon-floppy-disk { &:before { content: \"\\e172\"; } }\n.glyphicon-floppy-saved { &:before { content: \"\\e173\"; } }\n.glyphicon-floppy-remove { &:before { content: \"\\e174\"; } }\n.glyphicon-floppy-save { &:before { content: \"\\e175\"; } }\n.glyphicon-floppy-open { &:before { content: \"\\e176\"; } }\n.glyphicon-credit-card { &:before { content: \"\\e177\"; } }\n.glyphicon-transfer { &:before { content: \"\\e178\"; } }\n.glyphicon-cutlery { &:before { content: \"\\e179\"; } }\n.glyphicon-header { &:before { content: \"\\e180\"; } }\n.glyphicon-compressed { &:before { content: \"\\e181\"; } }\n.glyphicon-earphone { &:before { content: \"\\e182\"; } }\n.glyphicon-phone-alt { &:before { content: \"\\e183\"; } }\n.glyphicon-tower { &:before { content: \"\\e184\"; } }\n.glyphicon-stats { &:before { content: \"\\e185\"; } }\n.glyphicon-sd-video { &:before { content: \"\\e186\"; } }\n.glyphicon-hd-video { &:before { content: \"\\e187\"; } }\n.glyphicon-subtitles { &:before { content: \"\\e188\"; } }\n.glyphicon-sound-stereo { &:before { content: \"\\e189\"; } }\n.glyphicon-sound-dolby { &:before { content: \"\\e190\"; } }\n.glyphicon-sound-5-1 { &:before { content: \"\\e191\"; } }\n.glyphicon-sound-6-1 { &:before { content: \"\\e192\"; } }\n.glyphicon-sound-7-1 { &:before { content: \"\\e193\"; } }\n.glyphicon-copyright-mark { &:before { content: \"\\e194\"; } }\n.glyphicon-registration-mark { &:before { content: \"\\e195\"; } }\n.glyphicon-cloud-download { &:before { content: \"\\e197\"; } }\n.glyphicon-cloud-upload { &:before { content: \"\\e198\"; } }\n.glyphicon-tree-conifer { &:before { content: \"\\e199\"; } }\n.glyphicon-tree-deciduous { &:before { content: \"\\e200\"; } }\n","//\n// Scaffolding\n// --------------------------------------------------\n\n\n// Reset the box-sizing\n//\n// Heads up! This reset may cause conflicts with some third-party widgets.\n// For recommendations on resolving such conflicts, see\n// http://getbootstrap.com/getting-started/#third-box-sizing\n* {\n .box-sizing(border-box);\n}\n*:before,\n*:after {\n .box-sizing(border-box);\n}\n\n\n// Body reset\n\nhtml {\n font-size: 10px;\n -webkit-tap-highlight-color: rgba(0,0,0,0);\n}\n\nbody {\n font-family: @font-family-base;\n font-size: @font-size-base;\n line-height: @line-height-base;\n color: @text-color;\n background-color: @body-bg;\n}\n\n// Reset fonts for relevant elements\ninput,\nbutton,\nselect,\ntextarea {\n font-family: inherit;\n font-size: inherit;\n line-height: inherit;\n}\n\n\n// Links\n\na {\n color: @link-color;\n text-decoration: none;\n\n &:hover,\n &:focus {\n color: @link-hover-color;\n text-decoration: underline;\n }\n\n &:focus {\n .tab-focus();\n }\n}\n\n\n// Figures\n//\n// We reset this here because previously Normalize had no `figure` margins. This\n// ensures we don't break anyone's use of the element.\n\nfigure {\n margin: 0;\n}\n\n\n// Images\n\nimg {\n vertical-align: middle;\n}\n\n// Responsive images (ensure images don't scale beyond their parents)\n.img-responsive {\n .img-responsive();\n}\n\n// Rounded corners\n.img-rounded {\n border-radius: @border-radius-large;\n}\n\n// Image thumbnails\n//\n// Heads up! This is mixin-ed into thumbnails.less for `.thumbnail`.\n.img-thumbnail {\n padding: @thumbnail-padding;\n line-height: @line-height-base;\n background-color: @thumbnail-bg;\n border: 1px solid @thumbnail-border;\n border-radius: @thumbnail-border-radius;\n .transition(all .2s ease-in-out);\n\n // Keep them at most 100% wide\n .img-responsive(inline-block);\n}\n\n// Perfect circle\n.img-circle {\n border-radius: 50%; // set radius in percents\n}\n\n\n// Horizontal rules\n\nhr {\n margin-top: @line-height-computed;\n margin-bottom: @line-height-computed;\n border: 0;\n border-top: 1px solid @hr-border;\n}\n\n\n// Only display content to screen readers\n//\n// See: http://a11yproject.com/posts/how-to-hide-content/\n\n.sr-only {\n position: absolute;\n width: 1px;\n height: 1px;\n margin: -1px;\n padding: 0;\n overflow: hidden;\n clip: rect(0,0,0,0);\n border: 0;\n}\n\n// Use in conjunction with .sr-only to only display content when it's focused.\n// Useful for \"Skip to main content\" links; see http://www.w3.org/TR/2013/NOTE-WCAG20-TECHS-20130905/G1\n// Credit: HTML5 Boilerplate\n\n.sr-only-focusable {\n &:active,\n &:focus {\n position: static;\n width: auto;\n height: auto;\n margin: 0;\n overflow: visible;\n clip: auto;\n }\n}\n","// Vendor Prefixes\n//\n// All vendor mixins are deprecated as of v3.2.0 due to the introduction of\n// Autoprefixer in our Gruntfile. They will be removed in v4.\n\n// - Animations\n// - Backface visibility\n// - Box shadow\n// - Box sizing\n// - Content columns\n// - Hyphens\n// - Placeholder text\n// - Transformations\n// - Transitions\n// - User Select\n\n\n// Animations\n.animation(@animation) {\n -webkit-animation: @animation;\n -o-animation: @animation;\n animation: @animation;\n}\n.animation-name(@name) {\n -webkit-animation-name: @name;\n animation-name: @name;\n}\n.animation-duration(@duration) {\n -webkit-animation-duration: @duration;\n animation-duration: @duration;\n}\n.animation-timing-function(@timing-function) {\n -webkit-animation-timing-function: @timing-function;\n animation-timing-function: @timing-function;\n}\n.animation-delay(@delay) {\n -webkit-animation-delay: @delay;\n animation-delay: @delay;\n}\n.animation-iteration-count(@iteration-count) {\n -webkit-animation-iteration-count: @iteration-count;\n animation-iteration-count: @iteration-count;\n}\n.animation-direction(@direction) {\n -webkit-animation-direction: @direction;\n animation-direction: @direction;\n}\n.animation-fill-mode(@fill-mode) {\n -webkit-animation-fill-mode: @fill-mode;\n animation-fill-mode: @fill-mode;\n}\n\n// Backface visibility\n// Prevent browsers from flickering when using CSS 3D transforms.\n// Default value is `visible`, but can be changed to `hidden`\n\n.backface-visibility(@visibility){\n -webkit-backface-visibility: @visibility;\n -moz-backface-visibility: @visibility;\n backface-visibility: @visibility;\n}\n\n// Drop shadows\n//\n// Note: Deprecated `.box-shadow()` as of v3.1.0 since all of Bootstrap's\n// supported browsers that have box shadow capabilities now support it.\n\n.box-shadow(@shadow) {\n -webkit-box-shadow: @shadow; // iOS <4.3 & Android <4.1\n box-shadow: @shadow;\n}\n\n// Box sizing\n.box-sizing(@boxmodel) {\n -webkit-box-sizing: @boxmodel;\n -moz-box-sizing: @boxmodel;\n box-sizing: @boxmodel;\n}\n\n// CSS3 Content Columns\n.content-columns(@column-count; @column-gap: @grid-gutter-width) {\n -webkit-column-count: @column-count;\n -moz-column-count: @column-count;\n column-count: @column-count;\n -webkit-column-gap: @column-gap;\n -moz-column-gap: @column-gap;\n column-gap: @column-gap;\n}\n\n// Optional hyphenation\n.hyphens(@mode: auto) {\n word-wrap: break-word;\n -webkit-hyphens: @mode;\n -moz-hyphens: @mode;\n -ms-hyphens: @mode; // IE10+\n -o-hyphens: @mode;\n hyphens: @mode;\n}\n\n// Placeholder text\n.placeholder(@color: @input-color-placeholder) {\n &::-moz-placeholder { color: @color; // Firefox\n opacity: 1; } // See https://github.com/twbs/bootstrap/pull/11526\n &:-ms-input-placeholder { color: @color; } // Internet Explorer 10+\n &::-webkit-input-placeholder { color: @color; } // Safari and Chrome\n}\n\n// Transformations\n.scale(@ratio) {\n -webkit-transform: scale(@ratio);\n -ms-transform: scale(@ratio); // IE9 only\n -o-transform: scale(@ratio);\n transform: scale(@ratio);\n}\n.scale(@ratioX; @ratioY) {\n -webkit-transform: scale(@ratioX, @ratioY);\n -ms-transform: scale(@ratioX, @ratioY); // IE9 only\n -o-transform: scale(@ratioX, @ratioY);\n transform: scale(@ratioX, @ratioY);\n}\n.scaleX(@ratio) {\n -webkit-transform: scaleX(@ratio);\n -ms-transform: scaleX(@ratio); // IE9 only\n -o-transform: scaleX(@ratio);\n transform: scaleX(@ratio);\n}\n.scaleY(@ratio) {\n -webkit-transform: scaleY(@ratio);\n -ms-transform: scaleY(@ratio); // IE9 only\n -o-transform: scaleY(@ratio);\n transform: scaleY(@ratio);\n}\n.skew(@x; @y) {\n -webkit-transform: skewX(@x) skewY(@y);\n -ms-transform: skewX(@x) skewY(@y); // See https://github.com/twbs/bootstrap/issues/4885; IE9+\n -o-transform: skewX(@x) skewY(@y);\n transform: skewX(@x) skewY(@y);\n}\n.translate(@x; @y) {\n -webkit-transform: translate(@x, @y);\n -ms-transform: translate(@x, @y); // IE9 only\n -o-transform: translate(@x, @y);\n transform: translate(@x, @y);\n}\n.translate3d(@x; @y; @z) {\n -webkit-transform: translate3d(@x, @y, @z);\n transform: translate3d(@x, @y, @z);\n}\n.rotate(@degrees) {\n -webkit-transform: rotate(@degrees);\n -ms-transform: rotate(@degrees); // IE9 only\n -o-transform: rotate(@degrees);\n transform: rotate(@degrees);\n}\n.rotateX(@degrees) {\n -webkit-transform: rotateX(@degrees);\n -ms-transform: rotateX(@degrees); // IE9 only\n -o-transform: rotateX(@degrees);\n transform: rotateX(@degrees);\n}\n.rotateY(@degrees) {\n -webkit-transform: rotateY(@degrees);\n -ms-transform: rotateY(@degrees); // IE9 only\n -o-transform: rotateY(@degrees);\n transform: rotateY(@degrees);\n}\n.perspective(@perspective) {\n -webkit-perspective: @perspective;\n -moz-perspective: @perspective;\n perspective: @perspective;\n}\n.perspective-origin(@perspective) {\n -webkit-perspective-origin: @perspective;\n -moz-perspective-origin: @perspective;\n perspective-origin: @perspective;\n}\n.transform-origin(@origin) {\n -webkit-transform-origin: @origin;\n -moz-transform-origin: @origin;\n -ms-transform-origin: @origin; // IE9 only\n transform-origin: @origin;\n}\n\n\n// Transitions\n\n.transition(@transition) {\n -webkit-transition: @transition;\n -o-transition: @transition;\n transition: @transition;\n}\n.transition-property(@transition-property) {\n -webkit-transition-property: @transition-property;\n transition-property: @transition-property;\n}\n.transition-delay(@transition-delay) {\n -webkit-transition-delay: @transition-delay;\n transition-delay: @transition-delay;\n}\n.transition-duration(@transition-duration) {\n -webkit-transition-duration: @transition-duration;\n transition-duration: @transition-duration;\n}\n.transition-timing-function(@timing-function) {\n -webkit-transition-timing-function: @timing-function;\n transition-timing-function: @timing-function;\n}\n.transition-transform(@transition) {\n -webkit-transition: -webkit-transform @transition;\n -moz-transition: -moz-transform @transition;\n -o-transition: -o-transform @transition;\n transition: transform @transition;\n}\n\n\n// User select\n// For selecting text on the page\n\n.user-select(@select) {\n -webkit-user-select: @select;\n -moz-user-select: @select;\n -ms-user-select: @select; // IE10+\n user-select: @select;\n}\n","// WebKit-style focus\n\n.tab-focus() {\n // Default\n outline: thin dotted;\n // WebKit\n outline: 5px auto -webkit-focus-ring-color;\n outline-offset: -2px;\n}\n","// Image Mixins\n// - Responsive image\n// - Retina image\n\n\n// Responsive image\n//\n// Keep images from scaling beyond the width of their parents.\n.img-responsive(@display: block) {\n display: @display;\n width: 100% \\9; // Force IE10 and below to size SVG images correctly\n max-width: 100%; // Part 1: Set a maximum relative to the parent\n height: auto; // Part 2: Scale the height according to the width, otherwise you get stretching\n}\n\n\n// Retina image\n//\n// Short retina mixin for setting background-image and -size. Note that the\n// spelling of `min--moz-device-pixel-ratio` is intentional.\n.img-retina(@file-1x; @file-2x; @width-1x; @height-1x) {\n background-image: url(\"@{file-1x}\");\n\n @media\n only screen and (-webkit-min-device-pixel-ratio: 2),\n only screen and ( min--moz-device-pixel-ratio: 2),\n only screen and ( -o-min-device-pixel-ratio: 2/1),\n only screen and ( min-device-pixel-ratio: 2),\n only screen and ( min-resolution: 192dpi),\n only screen and ( min-resolution: 2dppx) {\n background-image: url(\"@{file-2x}\");\n background-size: @width-1x @height-1x;\n }\n}\n","//\n// Typography\n// --------------------------------------------------\n\n\n// Headings\n// -------------------------\n\nh1, h2, h3, h4, h5, h6,\n.h1, .h2, .h3, .h4, .h5, .h6 {\n font-family: @headings-font-family;\n font-weight: @headings-font-weight;\n line-height: @headings-line-height;\n color: @headings-color;\n\n small,\n .small {\n font-weight: normal;\n line-height: 1;\n color: @headings-small-color;\n }\n}\n\nh1, .h1,\nh2, .h2,\nh3, .h3 {\n margin-top: @line-height-computed;\n margin-bottom: (@line-height-computed / 2);\n\n small,\n .small {\n font-size: 65%;\n }\n}\nh4, .h4,\nh5, .h5,\nh6, .h6 {\n margin-top: (@line-height-computed / 2);\n margin-bottom: (@line-height-computed / 2);\n\n small,\n .small {\n font-size: 75%;\n }\n}\n\nh1, .h1 { font-size: @font-size-h1; }\nh2, .h2 { font-size: @font-size-h2; }\nh3, .h3 { font-size: @font-size-h3; }\nh4, .h4 { font-size: @font-size-h4; }\nh5, .h5 { font-size: @font-size-h5; }\nh6, .h6 { font-size: @font-size-h6; }\n\n\n// Body text\n// -------------------------\n\np {\n margin: 0 0 (@line-height-computed / 2);\n}\n\n.lead {\n margin-bottom: @line-height-computed;\n font-size: floor((@font-size-base * 1.15));\n font-weight: 300;\n line-height: 1.4;\n\n @media (min-width: @screen-sm-min) {\n font-size: (@font-size-base * 1.5);\n }\n}\n\n\n// Emphasis & misc\n// -------------------------\n\n// Ex: (12px small font / 14px base font) * 100% = about 85%\nsmall,\n.small {\n font-size: floor((100% * @font-size-small / @font-size-base));\n}\n\n// Undo browser default styling\ncite {\n font-style: normal;\n}\n\nmark,\n.mark {\n background-color: @state-warning-bg;\n padding: .2em;\n}\n\n// Alignment\n.text-left { text-align: left; }\n.text-right { text-align: right; }\n.text-center { text-align: center; }\n.text-justify { text-align: justify; }\n.text-nowrap { white-space: nowrap; }\n\n// Transformation\n.text-lowercase { text-transform: lowercase; }\n.text-uppercase { text-transform: uppercase; }\n.text-capitalize { text-transform: capitalize; }\n\n// Contextual colors\n.text-muted {\n color: @text-muted;\n}\n.text-primary {\n .text-emphasis-variant(@brand-primary);\n}\n.text-success {\n .text-emphasis-variant(@state-success-text);\n}\n.text-info {\n .text-emphasis-variant(@state-info-text);\n}\n.text-warning {\n .text-emphasis-variant(@state-warning-text);\n}\n.text-danger {\n .text-emphasis-variant(@state-danger-text);\n}\n\n// Contextual backgrounds\n// For now we'll leave these alongside the text classes until v4 when we can\n// safely shift things around (per SemVer rules).\n.bg-primary {\n // Given the contrast here, this is the only class to have its color inverted\n // automatically.\n color: #fff;\n .bg-variant(@brand-primary);\n}\n.bg-success {\n .bg-variant(@state-success-bg);\n}\n.bg-info {\n .bg-variant(@state-info-bg);\n}\n.bg-warning {\n .bg-variant(@state-warning-bg);\n}\n.bg-danger {\n .bg-variant(@state-danger-bg);\n}\n\n\n// Page header\n// -------------------------\n\n.page-header {\n padding-bottom: ((@line-height-computed / 2) - 1);\n margin: (@line-height-computed * 2) 0 @line-height-computed;\n border-bottom: 1px solid @page-header-border-color;\n}\n\n\n// Lists\n// -------------------------\n\n// Unordered and Ordered lists\nul,\nol {\n margin-top: 0;\n margin-bottom: (@line-height-computed / 2);\n ul,\n ol {\n margin-bottom: 0;\n }\n}\n\n// List options\n\n// Unstyled keeps list items block level, just removes default browser padding and list-style\n.list-unstyled {\n padding-left: 0;\n list-style: none;\n}\n\n// Inline turns list items into inline-block\n.list-inline {\n .list-unstyled();\n margin-left: -5px;\n\n > li {\n display: inline-block;\n padding-left: 5px;\n padding-right: 5px;\n }\n}\n\n// Description Lists\ndl {\n margin-top: 0; // Remove browser default\n margin-bottom: @line-height-computed;\n}\ndt,\ndd {\n line-height: @line-height-base;\n}\ndt {\n font-weight: bold;\n}\ndd {\n margin-left: 0; // Undo browser default\n}\n\n// Horizontal description lists\n//\n// Defaults to being stacked without any of the below styles applied, until the\n// grid breakpoint is reached (default of ~768px).\n\n.dl-horizontal {\n dd {\n &:extend(.clearfix all); // Clear the floated `dt` if an empty `dd` is present\n }\n\n @media (min-width: @grid-float-breakpoint) {\n dt {\n float: left;\n width: (@dl-horizontal-offset - 20);\n clear: left;\n text-align: right;\n .text-overflow();\n }\n dd {\n margin-left: @dl-horizontal-offset;\n }\n }\n}\n\n\n// Misc\n// -------------------------\n\n// Abbreviations and acronyms\nabbr[title],\n// Add data-* attribute to help out our tooltip plugin, per https://github.com/twbs/bootstrap/issues/5257\nabbr[data-original-title] {\n cursor: help;\n border-bottom: 1px dotted @abbr-border-color;\n}\n.initialism {\n font-size: 90%;\n text-transform: uppercase;\n}\n\n// Blockquotes\nblockquote {\n padding: (@line-height-computed / 2) @line-height-computed;\n margin: 0 0 @line-height-computed;\n font-size: @blockquote-font-size;\n border-left: 5px solid @blockquote-border-color;\n\n p,\n ul,\n ol {\n &:last-child {\n margin-bottom: 0;\n }\n }\n\n // Note: Deprecated small and .small as of v3.1.0\n // Context: https://github.com/twbs/bootstrap/issues/11660\n footer,\n small,\n .small {\n display: block;\n font-size: 80%; // back to default font-size\n line-height: @line-height-base;\n color: @blockquote-small-color;\n\n &:before {\n content: '\\2014 \\00A0'; // em dash, nbsp\n }\n }\n}\n\n// Opposite alignment of blockquote\n//\n// Heads up: `blockquote.pull-right` has been deprecated as of v3.1.0.\n.blockquote-reverse,\nblockquote.pull-right {\n padding-right: 15px;\n padding-left: 0;\n border-right: 5px solid @blockquote-border-color;\n border-left: 0;\n text-align: right;\n\n // Account for citation\n footer,\n small,\n .small {\n &:before { content: ''; }\n &:after {\n content: '\\00A0 \\2014'; // nbsp, em dash\n }\n }\n}\n\n// Quotes\nblockquote:before,\nblockquote:after {\n content: \"\";\n}\n\n// Addresses\naddress {\n margin-bottom: @line-height-computed;\n font-style: normal;\n line-height: @line-height-base;\n}\n","// Typography\n\n.text-emphasis-variant(@color) {\n color: @color;\n a&:hover {\n color: darken(@color, 10%);\n }\n}\n","// Contextual backgrounds\n\n.bg-variant(@color) {\n background-color: @color;\n a&:hover {\n background-color: darken(@color, 10%);\n }\n}\n","// Text overflow\n// Requires inline-block or block for proper styling\n\n.text-overflow() {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n","//\n// Code (inline and block)\n// --------------------------------------------------\n\n\n// Inline and block code styles\ncode,\nkbd,\npre,\nsamp {\n font-family: @font-family-monospace;\n}\n\n// Inline code\ncode {\n padding: 2px 4px;\n font-size: 90%;\n color: @code-color;\n background-color: @code-bg;\n border-radius: @border-radius-base;\n}\n\n// User input typically entered via keyboard\nkbd {\n padding: 2px 4px;\n font-size: 90%;\n color: @kbd-color;\n background-color: @kbd-bg;\n border-radius: @border-radius-small;\n box-shadow: inset 0 -1px 0 rgba(0,0,0,.25);\n\n kbd {\n padding: 0;\n font-size: 100%;\n box-shadow: none;\n }\n}\n\n// Blocks of code\npre {\n display: block;\n padding: ((@line-height-computed - 1) / 2);\n margin: 0 0 (@line-height-computed / 2);\n font-size: (@font-size-base - 1); // 14px to 13px\n line-height: @line-height-base;\n word-break: break-all;\n word-wrap: break-word;\n color: @pre-color;\n background-color: @pre-bg;\n border: 1px solid @pre-border-color;\n border-radius: @border-radius-base;\n\n // Account for some code outputs that place code tags in pre tags\n code {\n padding: 0;\n font-size: inherit;\n color: inherit;\n white-space: pre-wrap;\n background-color: transparent;\n border-radius: 0;\n }\n}\n\n// Enable scrollable blocks of code\n.pre-scrollable {\n max-height: @pre-scrollable-max-height;\n overflow-y: scroll;\n}\n","//\n// Grid system\n// --------------------------------------------------\n\n\n// Container widths\n//\n// Set the container width, and override it for fixed navbars in media queries.\n\n.container {\n .container-fixed();\n\n @media (min-width: @screen-sm-min) {\n width: @container-sm;\n }\n @media (min-width: @screen-md-min) {\n width: @container-md;\n }\n @media (min-width: @screen-lg-min) {\n width: @container-lg;\n }\n}\n\n\n// Fluid container\n//\n// Utilizes the mixin meant for fixed width containers, but without any defined\n// width for fluid, full width layouts.\n\n.container-fluid {\n .container-fixed();\n}\n\n\n// Row\n//\n// Rows contain and clear the floats of your columns.\n\n.row {\n .make-row();\n}\n\n\n// Columns\n//\n// Common styles for small and large grid columns\n\n.make-grid-columns();\n\n\n// Extra small grid\n//\n// Columns, offsets, pushes, and pulls for extra small devices like\n// smartphones.\n\n.make-grid(xs);\n\n\n// Small grid\n//\n// Columns, offsets, pushes, and pulls for the small device range, from phones\n// to tablets.\n\n@media (min-width: @screen-sm-min) {\n .make-grid(sm);\n}\n\n\n// Medium grid\n//\n// Columns, offsets, pushes, and pulls for the desktop device range.\n\n@media (min-width: @screen-md-min) {\n .make-grid(md);\n}\n\n\n// Large grid\n//\n// Columns, offsets, pushes, and pulls for the large desktop device range.\n\n@media (min-width: @screen-lg-min) {\n .make-grid(lg);\n}\n","// Grid system\n//\n// Generate semantic grid columns with these mixins.\n\n// Centered container element\n.container-fixed(@gutter: @grid-gutter-width) {\n margin-right: auto;\n margin-left: auto;\n padding-left: (@gutter / 2);\n padding-right: (@gutter / 2);\n &:extend(.clearfix all);\n}\n\n// Creates a wrapper for a series of columns\n.make-row(@gutter: @grid-gutter-width) {\n margin-left: (@gutter / -2);\n margin-right: (@gutter / -2);\n &:extend(.clearfix all);\n}\n\n// Generate the extra small columns\n.make-xs-column(@columns; @gutter: @grid-gutter-width) {\n position: relative;\n float: left;\n width: percentage((@columns / @grid-columns));\n min-height: 1px;\n padding-left: (@gutter / 2);\n padding-right: (@gutter / 2);\n}\n.make-xs-column-offset(@columns) {\n margin-left: percentage((@columns / @grid-columns));\n}\n.make-xs-column-push(@columns) {\n left: percentage((@columns / @grid-columns));\n}\n.make-xs-column-pull(@columns) {\n right: percentage((@columns / @grid-columns));\n}\n\n// Generate the small columns\n.make-sm-column(@columns; @gutter: @grid-gutter-width) {\n position: relative;\n min-height: 1px;\n padding-left: (@gutter / 2);\n padding-right: (@gutter / 2);\n\n @media (min-width: @screen-sm-min) {\n float: left;\n width: percentage((@columns / @grid-columns));\n }\n}\n.make-sm-column-offset(@columns) {\n @media (min-width: @screen-sm-min) {\n margin-left: percentage((@columns / @grid-columns));\n }\n}\n.make-sm-column-push(@columns) {\n @media (min-width: @screen-sm-min) {\n left: percentage((@columns / @grid-columns));\n }\n}\n.make-sm-column-pull(@columns) {\n @media (min-width: @screen-sm-min) {\n right: percentage((@columns / @grid-columns));\n }\n}\n\n// Generate the medium columns\n.make-md-column(@columns; @gutter: @grid-gutter-width) {\n position: relative;\n min-height: 1px;\n padding-left: (@gutter / 2);\n padding-right: (@gutter / 2);\n\n @media (min-width: @screen-md-min) {\n float: left;\n width: percentage((@columns / @grid-columns));\n }\n}\n.make-md-column-offset(@columns) {\n @media (min-width: @screen-md-min) {\n margin-left: percentage((@columns / @grid-columns));\n }\n}\n.make-md-column-push(@columns) {\n @media (min-width: @screen-md-min) {\n left: percentage((@columns / @grid-columns));\n }\n}\n.make-md-column-pull(@columns) {\n @media (min-width: @screen-md-min) {\n right: percentage((@columns / @grid-columns));\n }\n}\n\n// Generate the large columns\n.make-lg-column(@columns; @gutter: @grid-gutter-width) {\n position: relative;\n min-height: 1px;\n padding-left: (@gutter / 2);\n padding-right: (@gutter / 2);\n\n @media (min-width: @screen-lg-min) {\n float: left;\n width: percentage((@columns / @grid-columns));\n }\n}\n.make-lg-column-offset(@columns) {\n @media (min-width: @screen-lg-min) {\n margin-left: percentage((@columns / @grid-columns));\n }\n}\n.make-lg-column-push(@columns) {\n @media (min-width: @screen-lg-min) {\n left: percentage((@columns / @grid-columns));\n }\n}\n.make-lg-column-pull(@columns) {\n @media (min-width: @screen-lg-min) {\n right: percentage((@columns / @grid-columns));\n }\n}\n","// Framework grid generation\n//\n// Used only by Bootstrap to generate the correct number of grid classes given\n// any value of `@grid-columns`.\n\n.make-grid-columns() {\n // Common styles for all sizes of grid columns, widths 1-12\n .col(@index) when (@index = 1) { // initial\n @item: ~\".col-xs-@{index}, .col-sm-@{index}, .col-md-@{index}, .col-lg-@{index}\";\n .col((@index + 1), @item);\n }\n .col(@index, @list) when (@index =< @grid-columns) { // general; \"=<\" isn't a typo\n @item: ~\".col-xs-@{index}, .col-sm-@{index}, .col-md-@{index}, .col-lg-@{index}\";\n .col((@index + 1), ~\"@{list}, @{item}\");\n }\n .col(@index, @list) when (@index > @grid-columns) { // terminal\n @{list} {\n position: relative;\n // Prevent columns from collapsing when empty\n min-height: 1px;\n // Inner gutter via padding\n padding-left: (@grid-gutter-width / 2);\n padding-right: (@grid-gutter-width / 2);\n }\n }\n .col(1); // kickstart it\n}\n\n.float-grid-columns(@class) {\n .col(@index) when (@index = 1) { // initial\n @item: ~\".col-@{class}-@{index}\";\n .col((@index + 1), @item);\n }\n .col(@index, @list) when (@index =< @grid-columns) { // general\n @item: ~\".col-@{class}-@{index}\";\n .col((@index + 1), ~\"@{list}, @{item}\");\n }\n .col(@index, @list) when (@index > @grid-columns) { // terminal\n @{list} {\n float: left;\n }\n }\n .col(1); // kickstart it\n}\n\n.calc-grid-column(@index, @class, @type) when (@type = width) and (@index > 0) {\n .col-@{class}-@{index} {\n width: percentage((@index / @grid-columns));\n }\n}\n.calc-grid-column(@index, @class, @type) when (@type = push) and (@index > 0) {\n .col-@{class}-push-@{index} {\n left: percentage((@index / @grid-columns));\n }\n}\n.calc-grid-column(@index, @class, @type) when (@type = push) and (@index = 0) {\n .col-@{class}-push-0 {\n left: auto;\n }\n}\n.calc-grid-column(@index, @class, @type) when (@type = pull) and (@index > 0) {\n .col-@{class}-pull-@{index} {\n right: percentage((@index / @grid-columns));\n }\n}\n.calc-grid-column(@index, @class, @type) when (@type = pull) and (@index = 0) {\n .col-@{class}-pull-0 {\n right: auto;\n }\n}\n.calc-grid-column(@index, @class, @type) when (@type = offset) {\n .col-@{class}-offset-@{index} {\n margin-left: percentage((@index / @grid-columns));\n }\n}\n\n// Basic looping in LESS\n.loop-grid-columns(@index, @class, @type) when (@index >= 0) {\n .calc-grid-column(@index, @class, @type);\n // next iteration\n .loop-grid-columns((@index - 1), @class, @type);\n}\n\n// Create grid for specific class\n.make-grid(@class) {\n .float-grid-columns(@class);\n .loop-grid-columns(@grid-columns, @class, width);\n .loop-grid-columns(@grid-columns, @class, pull);\n .loop-grid-columns(@grid-columns, @class, push);\n .loop-grid-columns(@grid-columns, @class, offset);\n}\n","//\n// Tables\n// --------------------------------------------------\n\n\ntable {\n background-color: @table-bg;\n}\nth {\n text-align: left;\n}\n\n\n// Baseline styles\n\n.table {\n width: 100%;\n max-width: 100%;\n margin-bottom: @line-height-computed;\n // Cells\n > thead,\n > tbody,\n > tfoot {\n > tr {\n > th,\n > td {\n padding: @table-cell-padding;\n line-height: @line-height-base;\n vertical-align: top;\n border-top: 1px solid @table-border-color;\n }\n }\n }\n // Bottom align for column headings\n > thead > tr > th {\n vertical-align: bottom;\n border-bottom: 2px solid @table-border-color;\n }\n // Remove top border from thead by default\n > caption + thead,\n > colgroup + thead,\n > thead:first-child {\n > tr:first-child {\n > th,\n > td {\n border-top: 0;\n }\n }\n }\n // Account for multiple tbody instances\n > tbody + tbody {\n border-top: 2px solid @table-border-color;\n }\n\n // Nesting\n .table {\n background-color: @body-bg;\n }\n}\n\n\n// Condensed table w/ half padding\n\n.table-condensed {\n > thead,\n > tbody,\n > tfoot {\n > tr {\n > th,\n > td {\n padding: @table-condensed-cell-padding;\n }\n }\n }\n}\n\n\n// Bordered version\n//\n// Add borders all around the table and between all the columns.\n\n.table-bordered {\n border: 1px solid @table-border-color;\n > thead,\n > tbody,\n > tfoot {\n > tr {\n > th,\n > td {\n border: 1px solid @table-border-color;\n }\n }\n }\n > thead > tr {\n > th,\n > td {\n border-bottom-width: 2px;\n }\n }\n}\n\n\n// Zebra-striping\n//\n// Default zebra-stripe styles (alternating gray and transparent backgrounds)\n\n.table-striped {\n > tbody > tr:nth-child(odd) {\n > td,\n > th {\n background-color: @table-bg-accent;\n }\n }\n}\n\n\n// Hover effect\n//\n// Placed here since it has to come after the potential zebra striping\n\n.table-hover {\n > tbody > tr:hover {\n > td,\n > th {\n background-color: @table-bg-hover;\n }\n }\n}\n\n\n// Table cell sizing\n//\n// Reset default table behavior\n\ntable col[class*=\"col-\"] {\n position: static; // Prevent border hiding in Firefox and IE9/10 (see https://github.com/twbs/bootstrap/issues/11623)\n float: none;\n display: table-column;\n}\ntable {\n td,\n th {\n &[class*=\"col-\"] {\n position: static; // Prevent border hiding in Firefox and IE9/10 (see https://github.com/twbs/bootstrap/issues/11623)\n float: none;\n display: table-cell;\n }\n }\n}\n\n\n// Table backgrounds\n//\n// Exact selectors below required to override `.table-striped` and prevent\n// inheritance to nested tables.\n\n// Generate the contextual variants\n.table-row-variant(active; @table-bg-active);\n.table-row-variant(success; @state-success-bg);\n.table-row-variant(info; @state-info-bg);\n.table-row-variant(warning; @state-warning-bg);\n.table-row-variant(danger; @state-danger-bg);\n\n\n// Responsive tables\n//\n// Wrap your tables in `.table-responsive` and we'll make them mobile friendly\n// by enabling horizontal scrolling. Only applies <768px. Everything above that\n// will display normally.\n\n.table-responsive {\n @media screen and (max-width: @screen-xs-max) {\n width: 100%;\n margin-bottom: (@line-height-computed * 0.75);\n overflow-y: hidden;\n overflow-x: auto;\n -ms-overflow-style: -ms-autohiding-scrollbar;\n border: 1px solid @table-border-color;\n -webkit-overflow-scrolling: touch;\n\n // Tighten up spacing\n > .table {\n margin-bottom: 0;\n\n // Ensure the content doesn't wrap\n > thead,\n > tbody,\n > tfoot {\n > tr {\n > th,\n > td {\n white-space: nowrap;\n }\n }\n }\n }\n\n // Special overrides for the bordered tables\n > .table-bordered {\n border: 0;\n\n // Nuke the appropriate borders so that the parent can handle them\n > thead,\n > tbody,\n > tfoot {\n > tr {\n > th:first-child,\n > td:first-child {\n border-left: 0;\n }\n > th:last-child,\n > td:last-child {\n border-right: 0;\n }\n }\n }\n\n // Only nuke the last row's bottom-border in `tbody` and `tfoot` since\n // chances are there will be only one `tr` in a `thead` and that would\n // remove the border altogether.\n > tbody,\n > tfoot {\n > tr:last-child {\n > th,\n > td {\n border-bottom: 0;\n }\n }\n }\n\n }\n }\n}\n","// Tables\n\n.table-row-variant(@state; @background) {\n // Exact selectors below required to override `.table-striped` and prevent\n // inheritance to nested tables.\n .table > thead > tr,\n .table > tbody > tr,\n .table > tfoot > tr {\n > td.@{state},\n > th.@{state},\n &.@{state} > td,\n &.@{state} > th {\n background-color: @background;\n }\n }\n\n // Hover states for `.table-hover`\n // Note: this is not available for cells or rows within `thead` or `tfoot`.\n .table-hover > tbody > tr {\n > td.@{state}:hover,\n > th.@{state}:hover,\n &.@{state}:hover > td,\n &:hover > .@{state},\n &.@{state}:hover > th {\n background-color: darken(@background, 5%);\n }\n }\n}\n","//\n// Forms\n// --------------------------------------------------\n\n\n// Normalize non-controls\n//\n// Restyle and baseline non-control form elements.\n\nfieldset {\n padding: 0;\n margin: 0;\n border: 0;\n // Chrome and Firefox set a `min-width: min-content;` on fieldsets,\n // so we reset that to ensure it behaves more like a standard block element.\n // See https://github.com/twbs/bootstrap/issues/12359.\n min-width: 0;\n}\n\nlegend {\n display: block;\n width: 100%;\n padding: 0;\n margin-bottom: @line-height-computed;\n font-size: (@font-size-base * 1.5);\n line-height: inherit;\n color: @legend-color;\n border: 0;\n border-bottom: 1px solid @legend-border-color;\n}\n\nlabel {\n display: inline-block;\n max-width: 100%; // Force IE8 to wrap long content (see https://github.com/twbs/bootstrap/issues/13141)\n margin-bottom: 5px;\n font-weight: bold;\n}\n\n\n// Normalize form controls\n//\n// While most of our form styles require extra classes, some basic normalization\n// is required to ensure optimum display with or without those classes to better\n// address browser inconsistencies.\n\n// Override content-box in Normalize (* isn't specific enough)\ninput[type=\"search\"] {\n .box-sizing(border-box);\n}\n\n// Position radios and checkboxes better\ninput[type=\"radio\"],\ninput[type=\"checkbox\"] {\n margin: 4px 0 0;\n margin-top: 1px \\9; // IE8-9\n line-height: normal;\n}\n\n// Set the height of file controls to match text inputs\ninput[type=\"file\"] {\n display: block;\n}\n\n// Make range inputs behave like textual form controls\ninput[type=\"range\"] {\n display: block;\n width: 100%;\n}\n\n// Make multiple select elements height not fixed\nselect[multiple],\nselect[size] {\n height: auto;\n}\n\n// Focus for file, radio, and checkbox\ninput[type=\"file\"]:focus,\ninput[type=\"radio\"]:focus,\ninput[type=\"checkbox\"]:focus {\n .tab-focus();\n}\n\n// Adjust output element\noutput {\n display: block;\n padding-top: (@padding-base-vertical + 1);\n font-size: @font-size-base;\n line-height: @line-height-base;\n color: @input-color;\n}\n\n\n// Common form controls\n//\n// Shared size and type resets for form controls. Apply `.form-control` to any\n// of the following form controls:\n//\n// select\n// textarea\n// input[type=\"text\"]\n// input[type=\"password\"]\n// input[type=\"datetime\"]\n// input[type=\"datetime-local\"]\n// input[type=\"date\"]\n// input[type=\"month\"]\n// input[type=\"time\"]\n// input[type=\"week\"]\n// input[type=\"number\"]\n// input[type=\"email\"]\n// input[type=\"url\"]\n// input[type=\"search\"]\n// input[type=\"tel\"]\n// input[type=\"color\"]\n\n.form-control {\n display: block;\n width: 100%;\n height: @input-height-base; // Make inputs at least the height of their button counterpart (base line-height + padding + border)\n padding: @padding-base-vertical @padding-base-horizontal;\n font-size: @font-size-base;\n line-height: @line-height-base;\n color: @input-color;\n background-color: @input-bg;\n background-image: none; // Reset unusual Firefox-on-Android default style; see https://github.com/necolas/normalize.css/issues/214\n border: 1px solid @input-border;\n border-radius: @input-border-radius;\n .box-shadow(inset 0 1px 1px rgba(0,0,0,.075));\n .transition(~\"border-color ease-in-out .15s, box-shadow ease-in-out .15s\");\n\n // Customize the `:focus` state to imitate native WebKit styles.\n .form-control-focus();\n\n // Placeholder\n .placeholder();\n\n // Disabled and read-only inputs\n //\n // HTML5 says that controls under a fieldset > legend:first-child won't be\n // disabled if the fieldset is disabled. Due to implementation difficulty, we\n // don't honor that edge case; we style them as disabled anyway.\n &[disabled],\n &[readonly],\n fieldset[disabled] & {\n cursor: not-allowed;\n background-color: @input-bg-disabled;\n opacity: 1; // iOS fix for unreadable disabled content\n }\n\n // Reset height for `textarea`s\n textarea& {\n height: auto;\n }\n}\n\n\n// Search inputs in iOS\n//\n// This overrides the extra rounded corners on search inputs in iOS so that our\n// `.form-control` class can properly style them. Note that this cannot simply\n// be added to `.form-control` as it's not specific enough. For details, see\n// https://github.com/twbs/bootstrap/issues/11586.\n\ninput[type=\"search\"] {\n -webkit-appearance: none;\n}\n\n\n// Special styles for iOS temporal inputs\n//\n// In Mobile Safari, setting `display: block` on temporal inputs causes the\n// text within the input to become vertically misaligned.\n// As a workaround, we set a pixel line-height that matches the\n// given height of the input. Since this fucks up everything else, we have to\n// appropriately reset it for Internet Explorer and the size variations.\n\ninput[type=\"date\"],\ninput[type=\"time\"],\ninput[type=\"datetime-local\"],\ninput[type=\"month\"] {\n line-height: @input-height-base;\n // IE8+ misaligns the text within date inputs, so we reset\n line-height: @line-height-base ~\"\\0\";\n\n &.input-sm {\n line-height: @input-height-small;\n }\n &.input-lg {\n line-height: @input-height-large;\n }\n}\n\n\n// Form groups\n//\n// Designed to help with the organization and spacing of vertical forms. For\n// horizontal forms, use the predefined grid classes.\n\n.form-group {\n margin-bottom: 15px;\n}\n\n\n// Checkboxes and radios\n//\n// Indent the labels to position radios/checkboxes as hanging controls.\n\n.radio,\n.checkbox {\n position: relative;\n display: block;\n min-height: @line-height-computed; // clear the floating input if there is no label text\n margin-top: 10px;\n margin-bottom: 10px;\n\n label {\n padding-left: 20px;\n margin-bottom: 0;\n font-weight: normal;\n cursor: pointer;\n }\n}\n.radio input[type=\"radio\"],\n.radio-inline input[type=\"radio\"],\n.checkbox input[type=\"checkbox\"],\n.checkbox-inline input[type=\"checkbox\"] {\n position: absolute;\n margin-left: -20px;\n margin-top: 4px \\9;\n}\n\n.radio + .radio,\n.checkbox + .checkbox {\n margin-top: -5px; // Move up sibling radios or checkboxes for tighter spacing\n}\n\n// Radios and checkboxes on same line\n.radio-inline,\n.checkbox-inline {\n display: inline-block;\n padding-left: 20px;\n margin-bottom: 0;\n vertical-align: middle;\n font-weight: normal;\n cursor: pointer;\n}\n.radio-inline + .radio-inline,\n.checkbox-inline + .checkbox-inline {\n margin-top: 0;\n margin-left: 10px; // space out consecutive inline controls\n}\n\n// Apply same disabled cursor tweak as for inputs\n// Some special care is needed because <label>s don't inherit their parent's `cursor`.\n//\n// Note: Neither radios nor checkboxes can be readonly.\ninput[type=\"radio\"],\ninput[type=\"checkbox\"] {\n &[disabled],\n &.disabled,\n fieldset[disabled] & {\n cursor: not-allowed;\n }\n}\n// These classes are used directly on <label>s\n.radio-inline,\n.checkbox-inline {\n &.disabled,\n fieldset[disabled] & {\n cursor: not-allowed;\n }\n}\n// These classes are used on elements with <label> descendants\n.radio,\n.checkbox {\n &.disabled,\n fieldset[disabled] & {\n label {\n cursor: not-allowed;\n }\n }\n}\n\n\n// Static form control text\n//\n// Apply class to a `p` element to make any string of text align with labels in\n// a horizontal form layout.\n\n.form-control-static {\n // Size it appropriately next to real form controls\n padding-top: (@padding-base-vertical + 1);\n padding-bottom: (@padding-base-vertical + 1);\n // Remove default margin from `p`\n margin-bottom: 0;\n\n &.input-lg,\n &.input-sm {\n padding-left: 0;\n padding-right: 0;\n }\n}\n\n\n// Form control sizing\n//\n// Build on `.form-control` with modifier classes to decrease or increase the\n// height and font-size of form controls.\n\n.input-sm {\n .input-size(@input-height-small; @padding-small-vertical; @padding-small-horizontal; @font-size-small; @line-height-small; @border-radius-small);\n}\n\n.input-lg {\n .input-size(@input-height-large; @padding-large-vertical; @padding-large-horizontal; @font-size-large; @line-height-large; @border-radius-large);\n}\n\n\n// Form control feedback states\n//\n// Apply contextual and semantic states to individual form controls.\n\n.has-feedback {\n // Enable absolute positioning\n position: relative;\n\n // Ensure icons don't overlap text\n .form-control {\n padding-right: (@input-height-base * 1.25);\n }\n}\n// Feedback icon (requires .glyphicon classes)\n.form-control-feedback {\n position: absolute;\n top: (@line-height-computed + 5); // Height of the `label` and its margin\n right: 0;\n z-index: 2; // Ensure icon is above input groups\n display: block;\n width: @input-height-base;\n height: @input-height-base;\n line-height: @input-height-base;\n text-align: center;\n}\n.input-lg + .form-control-feedback {\n width: @input-height-large;\n height: @input-height-large;\n line-height: @input-height-large;\n}\n.input-sm + .form-control-feedback {\n width: @input-height-small;\n height: @input-height-small;\n line-height: @input-height-small;\n}\n\n// Feedback states\n.has-success {\n .form-control-validation(@state-success-text; @state-success-text; @state-success-bg);\n}\n.has-warning {\n .form-control-validation(@state-warning-text; @state-warning-text; @state-warning-bg);\n}\n.has-error {\n .form-control-validation(@state-danger-text; @state-danger-text; @state-danger-bg);\n}\n\n\n// Reposition feedback icon if label is hidden with \"screenreader only\" state\n.has-feedback label.sr-only ~ .form-control-feedback {\n top: 0;\n}\n\n\n// Help text\n//\n// Apply to any element you wish to create light text for placement immediately\n// below a form control. Use for general help, formatting, or instructional text.\n\n.help-block {\n display: block; // account for any element using help-block\n margin-top: 5px;\n margin-bottom: 10px;\n color: lighten(@text-color, 25%); // lighten the text some for contrast\n}\n\n\n\n// Inline forms\n//\n// Make forms appear inline(-block) by adding the `.form-inline` class. Inline\n// forms begin stacked on extra small (mobile) devices and then go inline when\n// viewports reach <768px.\n//\n// Requires wrapping inputs and labels with `.form-group` for proper display of\n// default HTML form controls and our custom form controls (e.g., input groups).\n//\n// Heads up! This is mixin-ed into `.navbar-form` in navbars.less.\n\n.form-inline {\n\n // Kick in the inline\n @media (min-width: @screen-sm-min) {\n // Inline-block all the things for \"inline\"\n .form-group {\n display: inline-block;\n margin-bottom: 0;\n vertical-align: middle;\n }\n\n // In navbar-form, allow folks to *not* use `.form-group`\n .form-control {\n display: inline-block;\n width: auto; // Prevent labels from stacking above inputs in `.form-group`\n vertical-align: middle;\n }\n\n .input-group {\n display: inline-table;\n vertical-align: middle;\n\n .input-group-addon,\n .input-group-btn,\n .form-control {\n width: auto;\n }\n }\n\n // Input groups need that 100% width though\n .input-group > .form-control {\n width: 100%;\n }\n\n .control-label {\n margin-bottom: 0;\n vertical-align: middle;\n }\n\n // Remove default margin on radios/checkboxes that were used for stacking, and\n // then undo the floating of radios and checkboxes to match (which also avoids\n // a bug in WebKit: https://github.com/twbs/bootstrap/issues/1969).\n .radio,\n .checkbox {\n display: inline-block;\n margin-top: 0;\n margin-bottom: 0;\n vertical-align: middle;\n\n label {\n padding-left: 0;\n }\n }\n .radio input[type=\"radio\"],\n .checkbox input[type=\"checkbox\"] {\n position: relative;\n margin-left: 0;\n }\n\n // Validation states\n //\n // Reposition the icon because it's now within a grid column and columns have\n // `position: relative;` on them. Also accounts for the grid gutter padding.\n .has-feedback .form-control-feedback {\n top: 0;\n }\n }\n}\n\n\n// Horizontal forms\n//\n// Horizontal forms are built on grid classes and allow you to create forms with\n// labels on the left and inputs on the right.\n\n.form-horizontal {\n\n // Consistent vertical alignment of radios and checkboxes\n //\n // Labels also get some reset styles, but that is scoped to a media query below.\n .radio,\n .checkbox,\n .radio-inline,\n .checkbox-inline {\n margin-top: 0;\n margin-bottom: 0;\n padding-top: (@padding-base-vertical + 1); // Default padding plus a border\n }\n // Account for padding we're adding to ensure the alignment and of help text\n // and other content below items\n .radio,\n .checkbox {\n min-height: (@line-height-computed + (@padding-base-vertical + 1));\n }\n\n // Make form groups behave like rows\n .form-group {\n .make-row();\n }\n\n // Reset spacing and right align labels, but scope to media queries so that\n // labels on narrow viewports stack the same as a default form example.\n @media (min-width: @screen-sm-min) {\n .control-label {\n text-align: right;\n margin-bottom: 0;\n padding-top: (@padding-base-vertical + 1); // Default padding plus a border\n }\n }\n\n // Validation states\n //\n // Reposition the icon because it's now within a grid column and columns have\n // `position: relative;` on them. Also accounts for the grid gutter padding.\n .has-feedback .form-control-feedback {\n top: 0;\n right: (@grid-gutter-width / 2);\n }\n\n // Form group sizes\n //\n // Quick utility class for applying `.input-lg` and `.input-sm` styles to the\n // inputs and labels within a `.form-group`.\n .form-group-lg {\n @media (min-width: @screen-sm-min) {\n .control-label {\n padding-top: ((@padding-large-vertical * @line-height-large) + 1);\n }\n }\n .form-control {\n &:extend(.input-lg);\n }\n }\n .form-group-sm {\n @media (min-width: @screen-sm-min) {\n .control-label {\n padding-top: (@padding-small-vertical + 1);\n }\n }\n .form-control {\n &:extend(.input-sm);\n }\n }\n}\n","// Form validation states\n//\n// Used in forms.less to generate the form validation CSS for warnings, errors,\n// and successes.\n\n.form-control-validation(@text-color: #555; @border-color: #ccc; @background-color: #f5f5f5) {\n // Color the label and help text\n .help-block,\n .control-label,\n .radio,\n .checkbox,\n .radio-inline,\n .checkbox-inline {\n color: @text-color;\n }\n // Set the border and box shadow on specific inputs to match\n .form-control {\n border-color: @border-color;\n .box-shadow(inset 0 1px 1px rgba(0,0,0,.075)); // Redeclare so transitions work\n &:focus {\n border-color: darken(@border-color, 10%);\n @shadow: inset 0 1px 1px rgba(0,0,0,.075), 0 0 6px lighten(@border-color, 20%);\n .box-shadow(@shadow);\n }\n }\n // Set validation states also for addons\n .input-group-addon {\n color: @text-color;\n border-color: @border-color;\n background-color: @background-color;\n }\n // Optional feedback icon\n .form-control-feedback {\n color: @text-color;\n }\n}\n\n\n// Form control focus state\n//\n// Generate a customized focus state and for any input with the specified color,\n// which defaults to the `@input-border-focus` variable.\n//\n// We highly encourage you to not customize the default value, but instead use\n// this to tweak colors on an as-needed basis. This aesthetic change is based on\n// WebKit's default styles, but applicable to a wider range of browsers. Its\n// usability and accessibility should be taken into account with any change.\n//\n// Example usage: change the default blue border and shadow to white for better\n// contrast against a dark gray background.\n.form-control-focus(@color: @input-border-focus) {\n @color-rgba: rgba(red(@color), green(@color), blue(@color), .6);\n &:focus {\n border-color: @color;\n outline: 0;\n .box-shadow(~\"inset 0 1px 1px rgba(0,0,0,.075), 0 0 8px @{color-rgba}\");\n }\n}\n\n// Form control sizing\n//\n// Relative text size, padding, and border-radii changes for form controls. For\n// horizontal sizing, wrap controls in the predefined grid classes. `<select>`\n// element gets special love because it's special, and that's a fact!\n.input-size(@input-height; @padding-vertical; @padding-horizontal; @font-size; @line-height; @border-radius) {\n height: @input-height;\n padding: @padding-vertical @padding-horizontal;\n font-size: @font-size;\n line-height: @line-height;\n border-radius: @border-radius;\n\n select& {\n height: @input-height;\n line-height: @input-height;\n }\n\n textarea&,\n select[multiple]& {\n height: auto;\n }\n}\n","//\n// Buttons\n// --------------------------------------------------\n\n\n// Base styles\n// --------------------------------------------------\n\n.btn {\n display: inline-block;\n margin-bottom: 0; // For input.btn\n font-weight: @btn-font-weight;\n text-align: center;\n vertical-align: middle;\n cursor: pointer;\n background-image: none; // Reset unusual Firefox-on-Android default style; see https://github.com/necolas/normalize.css/issues/214\n border: 1px solid transparent;\n white-space: nowrap;\n .button-size(@padding-base-vertical; @padding-base-horizontal; @font-size-base; @line-height-base; @border-radius-base);\n .user-select(none);\n\n &,\n &:active,\n &.active {\n &:focus {\n .tab-focus();\n }\n }\n\n &:hover,\n &:focus {\n color: @btn-default-color;\n text-decoration: none;\n }\n\n &:active,\n &.active {\n outline: 0;\n background-image: none;\n .box-shadow(inset 0 3px 5px rgba(0,0,0,.125));\n }\n\n &.disabled,\n &[disabled],\n fieldset[disabled] & {\n cursor: not-allowed;\n pointer-events: none; // Future-proof disabling of clicks\n .opacity(.65);\n .box-shadow(none);\n }\n}\n\n\n// Alternate buttons\n// --------------------------------------------------\n\n.btn-default {\n .button-variant(@btn-default-color; @btn-default-bg; @btn-default-border);\n}\n.btn-primary {\n .button-variant(@btn-primary-color; @btn-primary-bg; @btn-primary-border);\n}\n// Success appears as green\n.btn-success {\n .button-variant(@btn-success-color; @btn-success-bg; @btn-success-border);\n}\n// Info appears as blue-green\n.btn-info {\n .button-variant(@btn-info-color; @btn-info-bg; @btn-info-border);\n}\n// Warning appears as orange\n.btn-warning {\n .button-variant(@btn-warning-color; @btn-warning-bg; @btn-warning-border);\n}\n// Danger and error appear as red\n.btn-danger {\n .button-variant(@btn-danger-color; @btn-danger-bg; @btn-danger-border);\n}\n\n\n// Link buttons\n// -------------------------\n\n// Make a button look and behave like a link\n.btn-link {\n color: @link-color;\n font-weight: normal;\n cursor: pointer;\n border-radius: 0;\n\n &,\n &:active,\n &[disabled],\n fieldset[disabled] & {\n background-color: transparent;\n .box-shadow(none);\n }\n &,\n &:hover,\n &:focus,\n &:active {\n border-color: transparent;\n }\n &:hover,\n &:focus {\n color: @link-hover-color;\n text-decoration: underline;\n background-color: transparent;\n }\n &[disabled],\n fieldset[disabled] & {\n &:hover,\n &:focus {\n color: @btn-link-disabled-color;\n text-decoration: none;\n }\n }\n}\n\n\n// Button Sizes\n// --------------------------------------------------\n\n.btn-lg {\n // line-height: ensure even-numbered height of button next to large input\n .button-size(@padding-large-vertical; @padding-large-horizontal; @font-size-large; @line-height-large; @border-radius-large);\n}\n.btn-sm {\n // line-height: ensure proper height of button next to small input\n .button-size(@padding-small-vertical; @padding-small-horizontal; @font-size-small; @line-height-small; @border-radius-small);\n}\n.btn-xs {\n .button-size(@padding-xs-vertical; @padding-xs-horizontal; @font-size-small; @line-height-small; @border-radius-small);\n}\n\n\n// Block button\n// --------------------------------------------------\n\n.btn-block {\n display: block;\n width: 100%;\n}\n\n// Vertically space out multiple block buttons\n.btn-block + .btn-block {\n margin-top: 5px;\n}\n\n// Specificity overrides\ninput[type=\"submit\"],\ninput[type=\"reset\"],\ninput[type=\"button\"] {\n &.btn-block {\n width: 100%;\n }\n}\n","// Button variants\n//\n// Easily pump out default styles, as well as :hover, :focus, :active,\n// and disabled options for all buttons\n\n.button-variant(@color; @background; @border) {\n color: @color;\n background-color: @background;\n border-color: @border;\n\n &:hover,\n &:focus,\n &:active,\n &.active,\n .open > .dropdown-toggle& {\n color: @color;\n background-color: darken(@background, 10%);\n border-color: darken(@border, 12%);\n }\n &:active,\n &.active,\n .open > .dropdown-toggle& {\n background-image: none;\n }\n &.disabled,\n &[disabled],\n fieldset[disabled] & {\n &,\n &:hover,\n &:focus,\n &:active,\n &.active {\n background-color: @background;\n border-color: @border;\n }\n }\n\n .badge {\n color: @background;\n background-color: @color;\n }\n}\n\n// Button sizes\n.button-size(@padding-vertical; @padding-horizontal; @font-size; @line-height; @border-radius) {\n padding: @padding-vertical @padding-horizontal;\n font-size: @font-size;\n line-height: @line-height;\n border-radius: @border-radius;\n}\n","// Opacity\n\n.opacity(@opacity) {\n opacity: @opacity;\n // IE8 filter\n @opacity-ie: (@opacity * 100);\n filter: ~\"alpha(opacity=@{opacity-ie})\";\n}\n","//\n// Component animations\n// --------------------------------------------------\n\n// Heads up!\n//\n// We don't use the `.opacity()` mixin here since it causes a bug with text\n// fields in IE7-8. Source: https://github.com/twbs/bootstrap/pull/3552.\n\n.fade {\n opacity: 0;\n .transition(opacity .15s linear);\n &.in {\n opacity: 1;\n }\n}\n\n.collapse {\n display: none;\n\n &.in { display: block; }\n tr&.in { display: table-row; }\n tbody&.in { display: table-row-group; }\n}\n\n.collapsing {\n position: relative;\n height: 0;\n overflow: hidden;\n .transition(height .35s ease);\n}\n","//\n// Dropdown menus\n// --------------------------------------------------\n\n\n// Dropdown arrow/caret\n.caret {\n display: inline-block;\n width: 0;\n height: 0;\n margin-left: 2px;\n vertical-align: middle;\n border-top: @caret-width-base solid;\n border-right: @caret-width-base solid transparent;\n border-left: @caret-width-base solid transparent;\n}\n\n// The dropdown wrapper (div)\n.dropdown {\n position: relative;\n}\n\n// Prevent the focus on the dropdown toggle when closing dropdowns\n.dropdown-toggle:focus {\n outline: 0;\n}\n\n// The dropdown menu (ul)\n.dropdown-menu {\n position: absolute;\n top: 100%;\n left: 0;\n z-index: @zindex-dropdown;\n display: none; // none by default, but block on \"open\" of the menu\n float: left;\n min-width: 160px;\n padding: 5px 0;\n margin: 2px 0 0; // override default ul\n list-style: none;\n font-size: @font-size-base;\n text-align: left; // Ensures proper alignment if parent has it changed (e.g., modal footer)\n background-color: @dropdown-bg;\n border: 1px solid @dropdown-fallback-border; // IE8 fallback\n border: 1px solid @dropdown-border;\n border-radius: @border-radius-base;\n .box-shadow(0 6px 12px rgba(0,0,0,.175));\n background-clip: padding-box;\n\n // Aligns the dropdown menu to right\n //\n // Deprecated as of 3.1.0 in favor of `.dropdown-menu-[dir]`\n &.pull-right {\n right: 0;\n left: auto;\n }\n\n // Dividers (basically an hr) within the dropdown\n .divider {\n .nav-divider(@dropdown-divider-bg);\n }\n\n // Links within the dropdown menu\n > li > a {\n display: block;\n padding: 3px 20px;\n clear: both;\n font-weight: normal;\n line-height: @line-height-base;\n color: @dropdown-link-color;\n white-space: nowrap; // prevent links from randomly breaking onto new lines\n }\n}\n\n// Hover/Focus state\n.dropdown-menu > li > a {\n &:hover,\n &:focus {\n text-decoration: none;\n color: @dropdown-link-hover-color;\n background-color: @dropdown-link-hover-bg;\n }\n}\n\n// Active state\n.dropdown-menu > .active > a {\n &,\n &:hover,\n &:focus {\n color: @dropdown-link-active-color;\n text-decoration: none;\n outline: 0;\n background-color: @dropdown-link-active-bg;\n }\n}\n\n// Disabled state\n//\n// Gray out text and ensure the hover/focus state remains gray\n\n.dropdown-menu > .disabled > a {\n &,\n &:hover,\n &:focus {\n color: @dropdown-link-disabled-color;\n }\n}\n// Nuke hover/focus effects\n.dropdown-menu > .disabled > a {\n &:hover,\n &:focus {\n text-decoration: none;\n background-color: transparent;\n background-image: none; // Remove CSS gradient\n .reset-filter();\n cursor: not-allowed;\n }\n}\n\n// Open state for the dropdown\n.open {\n // Show the menu\n > .dropdown-menu {\n display: block;\n }\n\n // Remove the outline when :focus is triggered\n > a {\n outline: 0;\n }\n}\n\n// Menu positioning\n//\n// Add extra class to `.dropdown-menu` to flip the alignment of the dropdown\n// menu with the parent.\n.dropdown-menu-right {\n left: auto; // Reset the default from `.dropdown-menu`\n right: 0;\n}\n// With v3, we enabled auto-flipping if you have a dropdown within a right\n// aligned nav component. To enable the undoing of that, we provide an override\n// to restore the default dropdown menu alignment.\n//\n// This is only for left-aligning a dropdown menu within a `.navbar-right` or\n// `.pull-right` nav component.\n.dropdown-menu-left {\n left: 0;\n right: auto;\n}\n\n// Dropdown section headers\n.dropdown-header {\n display: block;\n padding: 3px 20px;\n font-size: @font-size-small;\n line-height: @line-height-base;\n color: @dropdown-header-color;\n white-space: nowrap; // as with > li > a\n}\n\n// Backdrop to catch body clicks on mobile, etc.\n.dropdown-backdrop {\n position: fixed;\n left: 0;\n right: 0;\n bottom: 0;\n top: 0;\n z-index: (@zindex-dropdown - 10);\n}\n\n// Right aligned dropdowns\n.pull-right > .dropdown-menu {\n right: 0;\n left: auto;\n}\n\n// Allow for dropdowns to go bottom up (aka, dropup-menu)\n//\n// Just add .dropup after the standard .dropdown class and you're set, bro.\n// TODO: abstract this so that the navbar fixed styles are not placed here?\n\n.dropup,\n.navbar-fixed-bottom .dropdown {\n // Reverse the caret\n .caret {\n border-top: 0;\n border-bottom: @caret-width-base solid;\n content: \"\";\n }\n // Different positioning for bottom up menu\n .dropdown-menu {\n top: auto;\n bottom: 100%;\n margin-bottom: 1px;\n }\n}\n\n\n// Component alignment\n//\n// Reiterate per navbar.less and the modified component alignment there.\n\n@media (min-width: @grid-float-breakpoint) {\n .navbar-right {\n .dropdown-menu {\n .dropdown-menu-right();\n }\n // Necessary for overrides of the default right aligned menu.\n // Will remove come v4 in all likelihood.\n .dropdown-menu-left {\n .dropdown-menu-left();\n }\n }\n}\n\n","// Horizontal dividers\n//\n// Dividers (basically an hr) within dropdowns and nav lists\n\n.nav-divider(@color: #e5e5e5) {\n height: 1px;\n margin: ((@line-height-computed / 2) - 1) 0;\n overflow: hidden;\n background-color: @color;\n}\n","// Reset filters for IE\n//\n// When you need to remove a gradient background, do not forget to use this to reset\n// the IE filter for IE9 and below.\n\n.reset-filter() {\n filter: e(%(\"progid:DXImageTransform.Microsoft.gradient(enabled = false)\"));\n}\n","//\n// Button groups\n// --------------------------------------------------\n\n// Make the div behave like a button\n.btn-group,\n.btn-group-vertical {\n position: relative;\n display: inline-block;\n vertical-align: middle; // match .btn alignment given font-size hack above\n > .btn {\n position: relative;\n float: left;\n // Bring the \"active\" button to the front\n &:hover,\n &:focus,\n &:active,\n &.active {\n z-index: 2;\n }\n &:focus {\n // Remove focus outline when dropdown JS adds it after closing the menu\n outline: 0;\n }\n }\n}\n\n// Prevent double borders when buttons are next to each other\n.btn-group {\n .btn + .btn,\n .btn + .btn-group,\n .btn-group + .btn,\n .btn-group + .btn-group {\n margin-left: -1px;\n }\n}\n\n// Optional: Group multiple button groups together for a toolbar\n.btn-toolbar {\n margin-left: -5px; // Offset the first child's margin\n &:extend(.clearfix all);\n\n .btn-group,\n .input-group {\n float: left;\n }\n > .btn,\n > .btn-group,\n > .input-group {\n margin-left: 5px;\n }\n}\n\n.btn-group > .btn:not(:first-child):not(:last-child):not(.dropdown-toggle) {\n border-radius: 0;\n}\n\n// Set corners individual because sometimes a single button can be in a .btn-group and we need :first-child and :last-child to both match\n.btn-group > .btn:first-child {\n margin-left: 0;\n &:not(:last-child):not(.dropdown-toggle) {\n .border-right-radius(0);\n }\n}\n// Need .dropdown-toggle since :last-child doesn't apply given a .dropdown-menu immediately after it\n.btn-group > .btn:last-child:not(:first-child),\n.btn-group > .dropdown-toggle:not(:first-child) {\n .border-left-radius(0);\n}\n\n// Custom edits for including btn-groups within btn-groups (useful for including dropdown buttons within a btn-group)\n.btn-group > .btn-group {\n float: left;\n}\n.btn-group > .btn-group:not(:first-child):not(:last-child) > .btn {\n border-radius: 0;\n}\n.btn-group > .btn-group:first-child {\n > .btn:last-child,\n > .dropdown-toggle {\n .border-right-radius(0);\n }\n}\n.btn-group > .btn-group:last-child > .btn:first-child {\n .border-left-radius(0);\n}\n\n// On active and open, don't show outline\n.btn-group .dropdown-toggle:active,\n.btn-group.open .dropdown-toggle {\n outline: 0;\n}\n\n\n// Sizing\n//\n// Remix the default button sizing classes into new ones for easier manipulation.\n\n.btn-group-xs > .btn { &:extend(.btn-xs); }\n.btn-group-sm > .btn { &:extend(.btn-sm); }\n.btn-group-lg > .btn { &:extend(.btn-lg); }\n\n\n// Split button dropdowns\n// ----------------------\n\n// Give the line between buttons some depth\n.btn-group > .btn + .dropdown-toggle {\n padding-left: 8px;\n padding-right: 8px;\n}\n.btn-group > .btn-lg + .dropdown-toggle {\n padding-left: 12px;\n padding-right: 12px;\n}\n\n// The clickable button for toggling the menu\n// Remove the gradient and set the same inset shadow as the :active state\n.btn-group.open .dropdown-toggle {\n .box-shadow(inset 0 3px 5px rgba(0,0,0,.125));\n\n // Show no shadow for `.btn-link` since it has no other button styles.\n &.btn-link {\n .box-shadow(none);\n }\n}\n\n\n// Reposition the caret\n.btn .caret {\n margin-left: 0;\n}\n// Carets in other button sizes\n.btn-lg .caret {\n border-width: @caret-width-large @caret-width-large 0;\n border-bottom-width: 0;\n}\n// Upside down carets for .dropup\n.dropup .btn-lg .caret {\n border-width: 0 @caret-width-large @caret-width-large;\n}\n\n\n// Vertical button groups\n// ----------------------\n\n.btn-group-vertical {\n > .btn,\n > .btn-group,\n > .btn-group > .btn {\n display: block;\n float: none;\n width: 100%;\n max-width: 100%;\n }\n\n // Clear floats so dropdown menus can be properly placed\n > .btn-group {\n &:extend(.clearfix all);\n > .btn {\n float: none;\n }\n }\n\n > .btn + .btn,\n > .btn + .btn-group,\n > .btn-group + .btn,\n > .btn-group + .btn-group {\n margin-top: -1px;\n margin-left: 0;\n }\n}\n\n.btn-group-vertical > .btn {\n &:not(:first-child):not(:last-child) {\n border-radius: 0;\n }\n &:first-child:not(:last-child) {\n border-top-right-radius: @border-radius-base;\n .border-bottom-radius(0);\n }\n &:last-child:not(:first-child) {\n border-bottom-left-radius: @border-radius-base;\n .border-top-radius(0);\n }\n}\n.btn-group-vertical > .btn-group:not(:first-child):not(:last-child) > .btn {\n border-radius: 0;\n}\n.btn-group-vertical > .btn-group:first-child:not(:last-child) {\n > .btn:last-child,\n > .dropdown-toggle {\n .border-bottom-radius(0);\n }\n}\n.btn-group-vertical > .btn-group:last-child:not(:first-child) > .btn:first-child {\n .border-top-radius(0);\n}\n\n\n\n// Justified button groups\n// ----------------------\n\n.btn-group-justified {\n display: table;\n width: 100%;\n table-layout: fixed;\n border-collapse: separate;\n > .btn,\n > .btn-group {\n float: none;\n display: table-cell;\n width: 1%;\n }\n > .btn-group .btn {\n width: 100%;\n }\n\n > .btn-group .dropdown-menu {\n left: auto;\n }\n}\n\n\n// Checkbox and radio options\n//\n// In order to support the browser's form validation feedback, powered by the\n// `required` attribute, we have to \"hide\" the inputs via `opacity`. We cannot\n// use `display: none;` or `visibility: hidden;` as that also hides the popover.\n// This way, we ensure a DOM element is visible to position the popover from.\n//\n// See https://github.com/twbs/bootstrap/pull/12794 for more.\n\n[data-toggle=\"buttons\"] > .btn > input[type=\"radio\"],\n[data-toggle=\"buttons\"] > .btn > input[type=\"checkbox\"] {\n position: absolute;\n z-index: -1;\n .opacity(0);\n}\n","// Single side border-radius\n\n.border-top-radius(@radius) {\n border-top-right-radius: @radius;\n border-top-left-radius: @radius;\n}\n.border-right-radius(@radius) {\n border-bottom-right-radius: @radius;\n border-top-right-radius: @radius;\n}\n.border-bottom-radius(@radius) {\n border-bottom-right-radius: @radius;\n border-bottom-left-radius: @radius;\n}\n.border-left-radius(@radius) {\n border-bottom-left-radius: @radius;\n border-top-left-radius: @radius;\n}\n","//\n// Input groups\n// --------------------------------------------------\n\n// Base styles\n// -------------------------\n.input-group {\n position: relative; // For dropdowns\n display: table;\n border-collapse: separate; // prevent input groups from inheriting border styles from table cells when placed within a table\n\n // Undo padding and float of grid classes\n &[class*=\"col-\"] {\n float: none;\n padding-left: 0;\n padding-right: 0;\n }\n\n .form-control {\n // Ensure that the input is always above the *appended* addon button for\n // proper border colors.\n position: relative;\n z-index: 2;\n\n // IE9 fubars the placeholder attribute in text inputs and the arrows on\n // select elements in input groups. To fix it, we float the input. Details:\n // https://github.com/twbs/bootstrap/issues/11561#issuecomment-28936855\n float: left;\n\n width: 100%;\n margin-bottom: 0;\n }\n}\n\n// Sizing options\n//\n// Remix the default form control sizing classes into new ones for easier\n// manipulation.\n\n.input-group-lg > .form-control,\n.input-group-lg > .input-group-addon,\n.input-group-lg > .input-group-btn > .btn {\n .input-lg();\n}\n.input-group-sm > .form-control,\n.input-group-sm > .input-group-addon,\n.input-group-sm > .input-group-btn > .btn {\n .input-sm();\n}\n\n\n// Display as table-cell\n// -------------------------\n.input-group-addon,\n.input-group-btn,\n.input-group .form-control {\n display: table-cell;\n\n &:not(:first-child):not(:last-child) {\n border-radius: 0;\n }\n}\n// Addon and addon wrapper for buttons\n.input-group-addon,\n.input-group-btn {\n width: 1%;\n white-space: nowrap;\n vertical-align: middle; // Match the inputs\n}\n\n// Text input groups\n// -------------------------\n.input-group-addon {\n padding: @padding-base-vertical @padding-base-horizontal;\n font-size: @font-size-base;\n font-weight: normal;\n line-height: 1;\n color: @input-color;\n text-align: center;\n background-color: @input-group-addon-bg;\n border: 1px solid @input-group-addon-border-color;\n border-radius: @border-radius-base;\n\n // Sizing\n &.input-sm {\n padding: @padding-small-vertical @padding-small-horizontal;\n font-size: @font-size-small;\n border-radius: @border-radius-small;\n }\n &.input-lg {\n padding: @padding-large-vertical @padding-large-horizontal;\n font-size: @font-size-large;\n border-radius: @border-radius-large;\n }\n\n // Nuke default margins from checkboxes and radios to vertically center within.\n input[type=\"radio\"],\n input[type=\"checkbox\"] {\n margin-top: 0;\n }\n}\n\n// Reset rounded corners\n.input-group .form-control:first-child,\n.input-group-addon:first-child,\n.input-group-btn:first-child > .btn,\n.input-group-btn:first-child > .btn-group > .btn,\n.input-group-btn:first-child > .dropdown-toggle,\n.input-group-btn:last-child > .btn:not(:last-child):not(.dropdown-toggle),\n.input-group-btn:last-child > .btn-group:not(:last-child) > .btn {\n .border-right-radius(0);\n}\n.input-group-addon:first-child {\n border-right: 0;\n}\n.input-group .form-control:last-child,\n.input-group-addon:last-child,\n.input-group-btn:last-child > .btn,\n.input-group-btn:last-child > .btn-group > .btn,\n.input-group-btn:last-child > .dropdown-toggle,\n.input-group-btn:first-child > .btn:not(:first-child),\n.input-group-btn:first-child > .btn-group:not(:first-child) > .btn {\n .border-left-radius(0);\n}\n.input-group-addon:last-child {\n border-left: 0;\n}\n\n// Button input groups\n// -------------------------\n.input-group-btn {\n position: relative;\n // Jankily prevent input button groups from wrapping with `white-space` and\n // `font-size` in combination with `inline-block` on buttons.\n font-size: 0;\n white-space: nowrap;\n\n // Negative margin for spacing, position for bringing hovered/focused/actived\n // element above the siblings.\n > .btn {\n position: relative;\n + .btn {\n margin-left: -1px;\n }\n // Bring the \"active\" button to the front\n &:hover,\n &:focus,\n &:active {\n z-index: 2;\n }\n }\n\n // Negative margin to only have a 1px border between the two\n &:first-child {\n > .btn,\n > .btn-group {\n margin-right: -1px;\n }\n }\n &:last-child {\n > .btn,\n > .btn-group {\n margin-left: -1px;\n }\n }\n}\n","//\n// Navs\n// --------------------------------------------------\n\n\n// Base class\n// --------------------------------------------------\n\n.nav {\n margin-bottom: 0;\n padding-left: 0; // Override default ul/ol\n list-style: none;\n &:extend(.clearfix all);\n\n > li {\n position: relative;\n display: block;\n\n > a {\n position: relative;\n display: block;\n padding: @nav-link-padding;\n &:hover,\n &:focus {\n text-decoration: none;\n background-color: @nav-link-hover-bg;\n }\n }\n\n // Disabled state sets text to gray and nukes hover/tab effects\n &.disabled > a {\n color: @nav-disabled-link-color;\n\n &:hover,\n &:focus {\n color: @nav-disabled-link-hover-color;\n text-decoration: none;\n background-color: transparent;\n cursor: not-allowed;\n }\n }\n }\n\n // Open dropdowns\n .open > a {\n &,\n &:hover,\n &:focus {\n background-color: @nav-link-hover-bg;\n border-color: @link-color;\n }\n }\n\n // Nav dividers (deprecated with v3.0.1)\n //\n // This should have been removed in v3 with the dropping of `.nav-list`, but\n // we missed it. We don't currently support this anywhere, but in the interest\n // of maintaining backward compatibility in case you use it, it's deprecated.\n .nav-divider {\n .nav-divider();\n }\n\n // Prevent IE8 from misplacing imgs\n //\n // See https://github.com/h5bp/html5-boilerplate/issues/984#issuecomment-3985989\n > li > a > img {\n max-width: none;\n }\n}\n\n\n// Tabs\n// -------------------------\n\n// Give the tabs something to sit on\n.nav-tabs {\n border-bottom: 1px solid @nav-tabs-border-color;\n > li {\n float: left;\n // Make the list-items overlay the bottom border\n margin-bottom: -1px;\n\n // Actual tabs (as links)\n > a {\n margin-right: 2px;\n line-height: @line-height-base;\n border: 1px solid transparent;\n border-radius: @border-radius-base @border-radius-base 0 0;\n &:hover {\n border-color: @nav-tabs-link-hover-border-color @nav-tabs-link-hover-border-color @nav-tabs-border-color;\n }\n }\n\n // Active state, and its :hover to override normal :hover\n &.active > a {\n &,\n &:hover,\n &:focus {\n color: @nav-tabs-active-link-hover-color;\n background-color: @nav-tabs-active-link-hover-bg;\n border: 1px solid @nav-tabs-active-link-hover-border-color;\n border-bottom-color: transparent;\n cursor: default;\n }\n }\n }\n // pulling this in mainly for less shorthand\n &.nav-justified {\n .nav-justified();\n .nav-tabs-justified();\n }\n}\n\n\n// Pills\n// -------------------------\n.nav-pills {\n > li {\n float: left;\n\n // Links rendered as pills\n > a {\n border-radius: @nav-pills-border-radius;\n }\n + li {\n margin-left: 2px;\n }\n\n // Active state\n &.active > a {\n &,\n &:hover,\n &:focus {\n color: @nav-pills-active-link-hover-color;\n background-color: @nav-pills-active-link-hover-bg;\n }\n }\n }\n}\n\n\n// Stacked pills\n.nav-stacked {\n > li {\n float: none;\n + li {\n margin-top: 2px;\n margin-left: 0; // no need for this gap between nav items\n }\n }\n}\n\n\n// Nav variations\n// --------------------------------------------------\n\n// Justified nav links\n// -------------------------\n\n.nav-justified {\n width: 100%;\n\n > li {\n float: none;\n > a {\n text-align: center;\n margin-bottom: 5px;\n }\n }\n\n > .dropdown .dropdown-menu {\n top: auto;\n left: auto;\n }\n\n @media (min-width: @screen-sm-min) {\n > li {\n display: table-cell;\n width: 1%;\n > a {\n margin-bottom: 0;\n }\n }\n }\n}\n\n// Move borders to anchors instead of bottom of list\n//\n// Mixin for adding on top the shared `.nav-justified` styles for our tabs\n.nav-tabs-justified {\n border-bottom: 0;\n\n > li > a {\n // Override margin from .nav-tabs\n margin-right: 0;\n border-radius: @border-radius-base;\n }\n\n > .active > a,\n > .active > a:hover,\n > .active > a:focus {\n border: 1px solid @nav-tabs-justified-link-border-color;\n }\n\n @media (min-width: @screen-sm-min) {\n > li > a {\n border-bottom: 1px solid @nav-tabs-justified-link-border-color;\n border-radius: @border-radius-base @border-radius-base 0 0;\n }\n > .active > a,\n > .active > a:hover,\n > .active > a:focus {\n border-bottom-color: @nav-tabs-justified-active-link-border-color;\n }\n }\n}\n\n\n// Tabbable tabs\n// -------------------------\n\n// Hide tabbable panes to start, show them when `.active`\n.tab-content {\n > .tab-pane {\n display: none;\n }\n > .active {\n display: block;\n }\n}\n\n\n// Dropdowns\n// -------------------------\n\n// Specific dropdowns\n.nav-tabs .dropdown-menu {\n // make dropdown border overlap tab border\n margin-top: -1px;\n // Remove the top rounded corners here since there is a hard edge above the menu\n .border-top-radius(0);\n}\n","//\n// Navbars\n// --------------------------------------------------\n\n\n// Wrapper and base class\n//\n// Provide a static navbar from which we expand to create full-width, fixed, and\n// other navbar variations.\n\n.navbar {\n position: relative;\n min-height: @navbar-height; // Ensure a navbar always shows (e.g., without a .navbar-brand in collapsed mode)\n margin-bottom: @navbar-margin-bottom;\n border: 1px solid transparent;\n\n // Prevent floats from breaking the navbar\n &:extend(.clearfix all);\n\n @media (min-width: @grid-float-breakpoint) {\n border-radius: @navbar-border-radius;\n }\n}\n\n\n// Navbar heading\n//\n// Groups `.navbar-brand` and `.navbar-toggle` into a single component for easy\n// styling of responsive aspects.\n\n.navbar-header {\n &:extend(.clearfix all);\n\n @media (min-width: @grid-float-breakpoint) {\n float: left;\n }\n}\n\n\n// Navbar collapse (body)\n//\n// Group your navbar content into this for easy collapsing and expanding across\n// various device sizes. By default, this content is collapsed when <768px, but\n// will expand past that for a horizontal display.\n//\n// To start (on mobile devices) the navbar links, forms, and buttons are stacked\n// vertically and include a `max-height` to overflow in case you have too much\n// content for the user's viewport.\n\n.navbar-collapse {\n overflow-x: visible;\n padding-right: @navbar-padding-horizontal;\n padding-left: @navbar-padding-horizontal;\n border-top: 1px solid transparent;\n box-shadow: inset 0 1px 0 rgba(255,255,255,.1);\n &:extend(.clearfix all);\n -webkit-overflow-scrolling: touch;\n\n &.in {\n overflow-y: auto;\n }\n\n @media (min-width: @grid-float-breakpoint) {\n width: auto;\n border-top: 0;\n box-shadow: none;\n\n &.collapse {\n display: block !important;\n height: auto !important;\n padding-bottom: 0; // Override default setting\n overflow: visible !important;\n }\n\n &.in {\n overflow-y: visible;\n }\n\n // Undo the collapse side padding for navbars with containers to ensure\n // alignment of right-aligned contents.\n .navbar-fixed-top &,\n .navbar-static-top &,\n .navbar-fixed-bottom & {\n padding-left: 0;\n padding-right: 0;\n }\n }\n}\n\n.navbar-fixed-top,\n.navbar-fixed-bottom {\n .navbar-collapse {\n max-height: @navbar-collapse-max-height;\n\n @media (max-width: @screen-xs-min) and (orientation: landscape) {\n max-height: 200px;\n }\n }\n}\n\n\n// Both navbar header and collapse\n//\n// When a container is present, change the behavior of the header and collapse.\n\n.container,\n.container-fluid {\n > .navbar-header,\n > .navbar-collapse {\n margin-right: -@navbar-padding-horizontal;\n margin-left: -@navbar-padding-horizontal;\n\n @media (min-width: @grid-float-breakpoint) {\n margin-right: 0;\n margin-left: 0;\n }\n }\n}\n\n\n//\n// Navbar alignment options\n//\n// Display the navbar across the entirety of the page or fixed it to the top or\n// bottom of the page.\n\n// Static top (unfixed, but 100% wide) navbar\n.navbar-static-top {\n z-index: @zindex-navbar;\n border-width: 0 0 1px;\n\n @media (min-width: @grid-float-breakpoint) {\n border-radius: 0;\n }\n}\n\n// Fix the top/bottom navbars when screen real estate supports it\n.navbar-fixed-top,\n.navbar-fixed-bottom {\n position: fixed;\n right: 0;\n left: 0;\n z-index: @zindex-navbar-fixed;\n .translate3d(0, 0, 0);\n\n // Undo the rounded corners\n @media (min-width: @grid-float-breakpoint) {\n border-radius: 0;\n }\n}\n.navbar-fixed-top {\n top: 0;\n border-width: 0 0 1px;\n}\n.navbar-fixed-bottom {\n bottom: 0;\n margin-bottom: 0; // override .navbar defaults\n border-width: 1px 0 0;\n}\n\n\n// Brand/project name\n\n.navbar-brand {\n float: left;\n padding: @navbar-padding-vertical @navbar-padding-horizontal;\n font-size: @font-size-large;\n line-height: @line-height-computed;\n height: @navbar-height;\n\n &:hover,\n &:focus {\n text-decoration: none;\n }\n\n @media (min-width: @grid-float-breakpoint) {\n .navbar > .container &,\n .navbar > .container-fluid & {\n margin-left: -@navbar-padding-horizontal;\n }\n }\n}\n\n\n// Navbar toggle\n//\n// Custom button for toggling the `.navbar-collapse`, powered by the collapse\n// JavaScript plugin.\n\n.navbar-toggle {\n position: relative;\n float: right;\n margin-right: @navbar-padding-horizontal;\n padding: 9px 10px;\n .navbar-vertical-align(34px);\n background-color: transparent;\n background-image: none; // Reset unusual Firefox-on-Android default style; see https://github.com/necolas/normalize.css/issues/214\n border: 1px solid transparent;\n border-radius: @border-radius-base;\n\n // We remove the `outline` here, but later compensate by attaching `:hover`\n // styles to `:focus`.\n &:focus {\n outline: 0;\n }\n\n // Bars\n .icon-bar {\n display: block;\n width: 22px;\n height: 2px;\n border-radius: 1px;\n }\n .icon-bar + .icon-bar {\n margin-top: 4px;\n }\n\n @media (min-width: @grid-float-breakpoint) {\n display: none;\n }\n}\n\n\n// Navbar nav links\n//\n// Builds on top of the `.nav` components with its own modifier class to make\n// the nav the full height of the horizontal nav (above 768px).\n\n.navbar-nav {\n margin: (@navbar-padding-vertical / 2) -@navbar-padding-horizontal;\n\n > li > a {\n padding-top: 10px;\n padding-bottom: 10px;\n line-height: @line-height-computed;\n }\n\n @media (max-width: @grid-float-breakpoint-max) {\n // Dropdowns get custom display when collapsed\n .open .dropdown-menu {\n position: static;\n float: none;\n width: auto;\n margin-top: 0;\n background-color: transparent;\n border: 0;\n box-shadow: none;\n > li > a,\n .dropdown-header {\n padding: 5px 15px 5px 25px;\n }\n > li > a {\n line-height: @line-height-computed;\n &:hover,\n &:focus {\n background-image: none;\n }\n }\n }\n }\n\n // Uncollapse the nav\n @media (min-width: @grid-float-breakpoint) {\n float: left;\n margin: 0;\n\n > li {\n float: left;\n > a {\n padding-top: @navbar-padding-vertical;\n padding-bottom: @navbar-padding-vertical;\n }\n }\n\n &.navbar-right:last-child {\n margin-right: -@navbar-padding-horizontal;\n }\n }\n}\n\n\n// Component alignment\n//\n// Repurpose the pull utilities as their own navbar utilities to avoid specificity\n// issues with parents and chaining. Only do this when the navbar is uncollapsed\n// though so that navbar contents properly stack and align in mobile.\n\n@media (min-width: @grid-float-breakpoint) {\n .navbar-left { .pull-left(); }\n .navbar-right { .pull-right(); }\n}\n\n\n// Navbar form\n//\n// Extension of the `.form-inline` with some extra flavor for optimum display in\n// our navbars.\n\n.navbar-form {\n margin-left: -@navbar-padding-horizontal;\n margin-right: -@navbar-padding-horizontal;\n padding: 10px @navbar-padding-horizontal;\n border-top: 1px solid transparent;\n border-bottom: 1px solid transparent;\n @shadow: inset 0 1px 0 rgba(255,255,255,.1), 0 1px 0 rgba(255,255,255,.1);\n .box-shadow(@shadow);\n\n // Mixin behavior for optimum display\n .form-inline();\n\n .form-group {\n @media (max-width: @grid-float-breakpoint-max) {\n margin-bottom: 5px;\n }\n }\n\n // Vertically center in expanded, horizontal navbar\n .navbar-vertical-align(@input-height-base);\n\n // Undo 100% width for pull classes\n @media (min-width: @grid-float-breakpoint) {\n width: auto;\n border: 0;\n margin-left: 0;\n margin-right: 0;\n padding-top: 0;\n padding-bottom: 0;\n .box-shadow(none);\n\n // Outdent the form if last child to line up with content down the page\n &.navbar-right:last-child {\n margin-right: -@navbar-padding-horizontal;\n }\n }\n}\n\n\n// Dropdown menus\n\n// Menu position and menu carets\n.navbar-nav > li > .dropdown-menu {\n margin-top: 0;\n .border-top-radius(0);\n}\n// Menu position and menu caret support for dropups via extra dropup class\n.navbar-fixed-bottom .navbar-nav > li > .dropdown-menu {\n .border-bottom-radius(0);\n}\n\n\n// Buttons in navbars\n//\n// Vertically center a button within a navbar (when *not* in a form).\n\n.navbar-btn {\n .navbar-vertical-align(@input-height-base);\n\n &.btn-sm {\n .navbar-vertical-align(@input-height-small);\n }\n &.btn-xs {\n .navbar-vertical-align(22);\n }\n}\n\n\n// Text in navbars\n//\n// Add a class to make any element properly align itself vertically within the navbars.\n\n.navbar-text {\n .navbar-vertical-align(@line-height-computed);\n\n @media (min-width: @grid-float-breakpoint) {\n float: left;\n margin-left: @navbar-padding-horizontal;\n margin-right: @navbar-padding-horizontal;\n\n // Outdent the form if last child to line up with content down the page\n &.navbar-right:last-child {\n margin-right: 0;\n }\n }\n}\n\n// Alternate navbars\n// --------------------------------------------------\n\n// Default navbar\n.navbar-default {\n background-color: @navbar-default-bg;\n border-color: @navbar-default-border;\n\n .navbar-brand {\n color: @navbar-default-brand-color;\n &:hover,\n &:focus {\n color: @navbar-default-brand-hover-color;\n background-color: @navbar-default-brand-hover-bg;\n }\n }\n\n .navbar-text {\n color: @navbar-default-color;\n }\n\n .navbar-nav {\n > li > a {\n color: @navbar-default-link-color;\n\n &:hover,\n &:focus {\n color: @navbar-default-link-hover-color;\n background-color: @navbar-default-link-hover-bg;\n }\n }\n > .active > a {\n &,\n &:hover,\n &:focus {\n color: @navbar-default-link-active-color;\n background-color: @navbar-default-link-active-bg;\n }\n }\n > .disabled > a {\n &,\n &:hover,\n &:focus {\n color: @navbar-default-link-disabled-color;\n background-color: @navbar-default-link-disabled-bg;\n }\n }\n }\n\n .navbar-toggle {\n border-color: @navbar-default-toggle-border-color;\n &:hover,\n &:focus {\n background-color: @navbar-default-toggle-hover-bg;\n }\n .icon-bar {\n background-color: @navbar-default-toggle-icon-bar-bg;\n }\n }\n\n .navbar-collapse,\n .navbar-form {\n border-color: @navbar-default-border;\n }\n\n // Dropdown menu items\n .navbar-nav {\n // Remove background color from open dropdown\n > .open > a {\n &,\n &:hover,\n &:focus {\n background-color: @navbar-default-link-active-bg;\n color: @navbar-default-link-active-color;\n }\n }\n\n @media (max-width: @grid-float-breakpoint-max) {\n // Dropdowns get custom display when collapsed\n .open .dropdown-menu {\n > li > a {\n color: @navbar-default-link-color;\n &:hover,\n &:focus {\n color: @navbar-default-link-hover-color;\n background-color: @navbar-default-link-hover-bg;\n }\n }\n > .active > a {\n &,\n &:hover,\n &:focus {\n color: @navbar-default-link-active-color;\n background-color: @navbar-default-link-active-bg;\n }\n }\n > .disabled > a {\n &,\n &:hover,\n &:focus {\n color: @navbar-default-link-disabled-color;\n background-color: @navbar-default-link-disabled-bg;\n }\n }\n }\n }\n }\n\n\n // Links in navbars\n //\n // Add a class to ensure links outside the navbar nav are colored correctly.\n\n .navbar-link {\n color: @navbar-default-link-color;\n &:hover {\n color: @navbar-default-link-hover-color;\n }\n }\n\n .btn-link {\n color: @navbar-default-link-color;\n &:hover,\n &:focus {\n color: @navbar-default-link-hover-color;\n }\n &[disabled],\n fieldset[disabled] & {\n &:hover,\n &:focus {\n color: @navbar-default-link-disabled-color;\n }\n }\n }\n}\n\n// Inverse navbar\n\n.navbar-inverse {\n background-color: @navbar-inverse-bg;\n border-color: @navbar-inverse-border;\n\n .navbar-brand {\n color: @navbar-inverse-brand-color;\n &:hover,\n &:focus {\n color: @navbar-inverse-brand-hover-color;\n background-color: @navbar-inverse-brand-hover-bg;\n }\n }\n\n .navbar-text {\n color: @navbar-inverse-color;\n }\n\n .navbar-nav {\n > li > a {\n color: @navbar-inverse-link-color;\n\n &:hover,\n &:focus {\n color: @navbar-inverse-link-hover-color;\n background-color: @navbar-inverse-link-hover-bg;\n }\n }\n > .active > a {\n &,\n &:hover,\n &:focus {\n color: @navbar-inverse-link-active-color;\n background-color: @navbar-inverse-link-active-bg;\n }\n }\n > .disabled > a {\n &,\n &:hover,\n &:focus {\n color: @navbar-inverse-link-disabled-color;\n background-color: @navbar-inverse-link-disabled-bg;\n }\n }\n }\n\n // Darken the responsive nav toggle\n .navbar-toggle {\n border-color: @navbar-inverse-toggle-border-color;\n &:hover,\n &:focus {\n background-color: @navbar-inverse-toggle-hover-bg;\n }\n .icon-bar {\n background-color: @navbar-inverse-toggle-icon-bar-bg;\n }\n }\n\n .navbar-collapse,\n .navbar-form {\n border-color: darken(@navbar-inverse-bg, 7%);\n }\n\n // Dropdowns\n .navbar-nav {\n > .open > a {\n &,\n &:hover,\n &:focus {\n background-color: @navbar-inverse-link-active-bg;\n color: @navbar-inverse-link-active-color;\n }\n }\n\n @media (max-width: @grid-float-breakpoint-max) {\n // Dropdowns get custom display\n .open .dropdown-menu {\n > .dropdown-header {\n border-color: @navbar-inverse-border;\n }\n .divider {\n background-color: @navbar-inverse-border;\n }\n > li > a {\n color: @navbar-inverse-link-color;\n &:hover,\n &:focus {\n color: @navbar-inverse-link-hover-color;\n background-color: @navbar-inverse-link-hover-bg;\n }\n }\n > .active > a {\n &,\n &:hover,\n &:focus {\n color: @navbar-inverse-link-active-color;\n background-color: @navbar-inverse-link-active-bg;\n }\n }\n > .disabled > a {\n &,\n &:hover,\n &:focus {\n color: @navbar-inverse-link-disabled-color;\n background-color: @navbar-inverse-link-disabled-bg;\n }\n }\n }\n }\n }\n\n .navbar-link {\n color: @navbar-inverse-link-color;\n &:hover {\n color: @navbar-inverse-link-hover-color;\n }\n }\n\n .btn-link {\n color: @navbar-inverse-link-color;\n &:hover,\n &:focus {\n color: @navbar-inverse-link-hover-color;\n }\n &[disabled],\n fieldset[disabled] & {\n &:hover,\n &:focus {\n color: @navbar-inverse-link-disabled-color;\n }\n }\n }\n}\n","// Navbar vertical align\n//\n// Vertically center elements in the navbar.\n// Example: an element has a height of 30px, so write out `.navbar-vertical-align(30px);` to calculate the appropriate top margin.\n\n.navbar-vertical-align(@element-height) {\n margin-top: ((@navbar-height - @element-height) / 2);\n margin-bottom: ((@navbar-height - @element-height) / 2);\n}\n","//\n// Utility classes\n// --------------------------------------------------\n\n\n// Floats\n// -------------------------\n\n.clearfix {\n .clearfix();\n}\n.center-block {\n .center-block();\n}\n.pull-right {\n float: right !important;\n}\n.pull-left {\n float: left !important;\n}\n\n\n// Toggling content\n// -------------------------\n\n// Note: Deprecated .hide in favor of .hidden or .sr-only (as appropriate) in v3.0.1\n.hide {\n display: none !important;\n}\n.show {\n display: block !important;\n}\n.invisible {\n visibility: hidden;\n}\n.text-hide {\n .text-hide();\n}\n\n\n// Hide from screenreaders and browsers\n//\n// Credit: HTML5 Boilerplate\n\n.hidden {\n display: none !important;\n visibility: hidden !important;\n}\n\n\n// For Affix plugin\n// -------------------------\n\n.affix {\n position: fixed;\n .translate3d(0, 0, 0);\n}\n","//\n// Breadcrumbs\n// --------------------------------------------------\n\n\n.breadcrumb {\n padding: @breadcrumb-padding-vertical @breadcrumb-padding-horizontal;\n margin-bottom: @line-height-computed;\n list-style: none;\n background-color: @breadcrumb-bg;\n border-radius: @border-radius-base;\n\n > li {\n display: inline-block;\n\n + li:before {\n content: \"@{breadcrumb-separator}\\00a0\"; // Unicode space added since inline-block means non-collapsing white-space\n padding: 0 5px;\n color: @breadcrumb-color;\n }\n }\n\n > .active {\n color: @breadcrumb-active-color;\n }\n}\n","//\n// Pagination (multiple pages)\n// --------------------------------------------------\n.pagination {\n display: inline-block;\n padding-left: 0;\n margin: @line-height-computed 0;\n border-radius: @border-radius-base;\n\n > li {\n display: inline; // Remove list-style and block-level defaults\n > a,\n > span {\n position: relative;\n float: left; // Collapse white-space\n padding: @padding-base-vertical @padding-base-horizontal;\n line-height: @line-height-base;\n text-decoration: none;\n color: @pagination-color;\n background-color: @pagination-bg;\n border: 1px solid @pagination-border;\n margin-left: -1px;\n }\n &:first-child {\n > a,\n > span {\n margin-left: 0;\n .border-left-radius(@border-radius-base);\n }\n }\n &:last-child {\n > a,\n > span {\n .border-right-radius(@border-radius-base);\n }\n }\n }\n\n > li > a,\n > li > span {\n &:hover,\n &:focus {\n color: @pagination-hover-color;\n background-color: @pagination-hover-bg;\n border-color: @pagination-hover-border;\n }\n }\n\n > .active > a,\n > .active > span {\n &,\n &:hover,\n &:focus {\n z-index: 2;\n color: @pagination-active-color;\n background-color: @pagination-active-bg;\n border-color: @pagination-active-border;\n cursor: default;\n }\n }\n\n > .disabled {\n > span,\n > span:hover,\n > span:focus,\n > a,\n > a:hover,\n > a:focus {\n color: @pagination-disabled-color;\n background-color: @pagination-disabled-bg;\n border-color: @pagination-disabled-border;\n cursor: not-allowed;\n }\n }\n}\n\n// Sizing\n// --------------------------------------------------\n\n// Large\n.pagination-lg {\n .pagination-size(@padding-large-vertical; @padding-large-horizontal; @font-size-large; @border-radius-large);\n}\n\n// Small\n.pagination-sm {\n .pagination-size(@padding-small-vertical; @padding-small-horizontal; @font-size-small; @border-radius-small);\n}\n","// Pagination\n\n.pagination-size(@padding-vertical; @padding-horizontal; @font-size; @border-radius) {\n > li {\n > a,\n > span {\n padding: @padding-vertical @padding-horizontal;\n font-size: @font-size;\n }\n &:first-child {\n > a,\n > span {\n .border-left-radius(@border-radius);\n }\n }\n &:last-child {\n > a,\n > span {\n .border-right-radius(@border-radius);\n }\n }\n }\n}\n","//\n// Pager pagination\n// --------------------------------------------------\n\n\n.pager {\n padding-left: 0;\n margin: @line-height-computed 0;\n list-style: none;\n text-align: center;\n &:extend(.clearfix all);\n li {\n display: inline;\n > a,\n > span {\n display: inline-block;\n padding: 5px 14px;\n background-color: @pager-bg;\n border: 1px solid @pager-border;\n border-radius: @pager-border-radius;\n }\n\n > a:hover,\n > a:focus {\n text-decoration: none;\n background-color: @pager-hover-bg;\n }\n }\n\n .next {\n > a,\n > span {\n float: right;\n }\n }\n\n .previous {\n > a,\n > span {\n float: left;\n }\n }\n\n .disabled {\n > a,\n > a:hover,\n > a:focus,\n > span {\n color: @pager-disabled-color;\n background-color: @pager-bg;\n cursor: not-allowed;\n }\n }\n\n}\n","//\n// Labels\n// --------------------------------------------------\n\n.label {\n display: inline;\n padding: .2em .6em .3em;\n font-size: 75%;\n font-weight: bold;\n line-height: 1;\n color: @label-color;\n text-align: center;\n white-space: nowrap;\n vertical-align: baseline;\n border-radius: .25em;\n\n // Add hover effects, but only for links\n a& {\n &:hover,\n &:focus {\n color: @label-link-hover-color;\n text-decoration: none;\n cursor: pointer;\n }\n }\n\n // Empty labels collapse automatically (not available in IE8)\n &:empty {\n display: none;\n }\n\n // Quick fix for labels in buttons\n .btn & {\n position: relative;\n top: -1px;\n }\n}\n\n// Colors\n// Contextual variations (linked labels get darker on :hover)\n\n.label-default {\n .label-variant(@label-default-bg);\n}\n\n.label-primary {\n .label-variant(@label-primary-bg);\n}\n\n.label-success {\n .label-variant(@label-success-bg);\n}\n\n.label-info {\n .label-variant(@label-info-bg);\n}\n\n.label-warning {\n .label-variant(@label-warning-bg);\n}\n\n.label-danger {\n .label-variant(@label-danger-bg);\n}\n","// Labels\n\n.label-variant(@color) {\n background-color: @color;\n \n &[href] {\n &:hover,\n &:focus {\n background-color: darken(@color, 10%);\n }\n }\n}\n","//\n// Badges\n// --------------------------------------------------\n\n\n// Base class\n.badge {\n display: inline-block;\n min-width: 10px;\n padding: 3px 7px;\n font-size: @font-size-small;\n font-weight: @badge-font-weight;\n color: @badge-color;\n line-height: @badge-line-height;\n vertical-align: baseline;\n white-space: nowrap;\n text-align: center;\n background-color: @badge-bg;\n border-radius: @badge-border-radius;\n\n // Empty badges collapse automatically (not available in IE8)\n &:empty {\n display: none;\n }\n\n // Quick fix for badges in buttons\n .btn & {\n position: relative;\n top: -1px;\n }\n .btn-xs & {\n top: 0;\n padding: 1px 5px;\n }\n\n // Hover state, but only for links\n a& {\n &:hover,\n &:focus {\n color: @badge-link-hover-color;\n text-decoration: none;\n cursor: pointer;\n }\n }\n\n // Account for badges in navs\n a.list-group-item.active > &,\n .nav-pills > .active > a > & {\n color: @badge-active-color;\n background-color: @badge-active-bg;\n }\n .nav-pills > li > a > & {\n margin-left: 3px;\n }\n}\n","//\n// Jumbotron\n// --------------------------------------------------\n\n\n.jumbotron {\n padding: @jumbotron-padding;\n margin-bottom: @jumbotron-padding;\n color: @jumbotron-color;\n background-color: @jumbotron-bg;\n\n h1,\n .h1 {\n color: @jumbotron-heading-color;\n }\n p {\n margin-bottom: (@jumbotron-padding / 2);\n font-size: @jumbotron-font-size;\n font-weight: 200;\n }\n\n > hr {\n border-top-color: darken(@jumbotron-bg, 10%);\n }\n\n .container & {\n border-radius: @border-radius-large; // Only round corners at higher resolutions if contained in a container\n }\n\n .container {\n max-width: 100%;\n }\n\n @media screen and (min-width: @screen-sm-min) {\n padding-top: (@jumbotron-padding * 1.6);\n padding-bottom: (@jumbotron-padding * 1.6);\n\n .container & {\n padding-left: (@jumbotron-padding * 2);\n padding-right: (@jumbotron-padding * 2);\n }\n\n h1,\n .h1 {\n font-size: (@font-size-base * 4.5);\n }\n }\n}\n","//\n// Thumbnails\n// --------------------------------------------------\n\n\n// Mixin and adjust the regular image class\n.thumbnail {\n display: block;\n padding: @thumbnail-padding;\n margin-bottom: @line-height-computed;\n line-height: @line-height-base;\n background-color: @thumbnail-bg;\n border: 1px solid @thumbnail-border;\n border-radius: @thumbnail-border-radius;\n .transition(all .2s ease-in-out);\n\n > img,\n a > img {\n &:extend(.img-responsive);\n margin-left: auto;\n margin-right: auto;\n }\n\n // Add a hover state for linked versions only\n a&:hover,\n a&:focus,\n a&.active {\n border-color: @link-color;\n }\n\n // Image captions\n .caption {\n padding: @thumbnail-caption-padding;\n color: @thumbnail-caption-color;\n }\n}\n","//\n// Alerts\n// --------------------------------------------------\n\n\n// Base styles\n// -------------------------\n\n.alert {\n padding: @alert-padding;\n margin-bottom: @line-height-computed;\n border: 1px solid transparent;\n border-radius: @alert-border-radius;\n\n // Headings for larger alerts\n h4 {\n margin-top: 0;\n // Specified for the h4 to prevent conflicts of changing @headings-color\n color: inherit;\n }\n // Provide class for links that match alerts\n .alert-link {\n font-weight: @alert-link-font-weight;\n }\n\n // Improve alignment and spacing of inner content\n > p,\n > ul {\n margin-bottom: 0;\n }\n > p + p {\n margin-top: 5px;\n }\n}\n\n// Dismissible alerts\n//\n// Expand the right padding and account for the close button's positioning.\n\n.alert-dismissable, // The misspelled .alert-dismissable was deprecated in 3.2.0.\n.alert-dismissible {\n padding-right: (@alert-padding + 20);\n\n // Adjust close link position\n .close {\n position: relative;\n top: -2px;\n right: -21px;\n color: inherit;\n }\n}\n\n// Alternate styles\n//\n// Generate contextual modifier classes for colorizing the alert.\n\n.alert-success {\n .alert-variant(@alert-success-bg; @alert-success-border; @alert-success-text);\n}\n.alert-info {\n .alert-variant(@alert-info-bg; @alert-info-border; @alert-info-text);\n}\n.alert-warning {\n .alert-variant(@alert-warning-bg; @alert-warning-border; @alert-warning-text);\n}\n.alert-danger {\n .alert-variant(@alert-danger-bg; @alert-danger-border; @alert-danger-text);\n}\n","// Alerts\n\n.alert-variant(@background; @border; @text-color) {\n background-color: @background;\n border-color: @border;\n color: @text-color;\n\n hr {\n border-top-color: darken(@border, 5%);\n }\n .alert-link {\n color: darken(@text-color, 10%);\n }\n}\n","//\n// Progress bars\n// --------------------------------------------------\n\n\n// Bar animations\n// -------------------------\n\n// WebKit\n@-webkit-keyframes progress-bar-stripes {\n from { background-position: 40px 0; }\n to { background-position: 0 0; }\n}\n\n// Spec and IE10+\n@keyframes progress-bar-stripes {\n from { background-position: 40px 0; }\n to { background-position: 0 0; }\n}\n\n\n\n// Bar itself\n// -------------------------\n\n// Outer container\n.progress {\n overflow: hidden;\n height: @line-height-computed;\n margin-bottom: @line-height-computed;\n background-color: @progress-bg;\n border-radius: @border-radius-base;\n .box-shadow(inset 0 1px 2px rgba(0,0,0,.1));\n}\n\n// Bar of progress\n.progress-bar {\n float: left;\n width: 0%;\n height: 100%;\n font-size: @font-size-small;\n line-height: @line-height-computed;\n color: @progress-bar-color;\n text-align: center;\n background-color: @progress-bar-bg;\n .box-shadow(inset 0 -1px 0 rgba(0,0,0,.15));\n .transition(width .6s ease);\n}\n\n// Striped bars\n//\n// `.progress-striped .progress-bar` is deprecated as of v3.2.0 in favor of the\n// `.progress-bar-striped` class, which you just add to an existing\n// `.progress-bar`.\n.progress-striped .progress-bar,\n.progress-bar-striped {\n #gradient > .striped();\n background-size: 40px 40px;\n}\n\n// Call animation for the active one\n//\n// `.progress.active .progress-bar` is deprecated as of v3.2.0 in favor of the\n// `.progress-bar.active` approach.\n.progress.active .progress-bar,\n.progress-bar.active {\n .animation(progress-bar-stripes 2s linear infinite);\n}\n\n// Account for lower percentages\n.progress-bar {\n &[aria-valuenow=\"1\"],\n &[aria-valuenow=\"2\"] {\n min-width: 30px;\n }\n\n &[aria-valuenow=\"0\"] {\n color: @gray-light;\n min-width: 30px;\n background-color: transparent;\n background-image: none;\n box-shadow: none;\n }\n}\n\n\n\n// Variations\n// -------------------------\n\n.progress-bar-success {\n .progress-bar-variant(@progress-bar-success-bg);\n}\n\n.progress-bar-info {\n .progress-bar-variant(@progress-bar-info-bg);\n}\n\n.progress-bar-warning {\n .progress-bar-variant(@progress-bar-warning-bg);\n}\n\n.progress-bar-danger {\n .progress-bar-variant(@progress-bar-danger-bg);\n}\n","// Gradients\n\n#gradient {\n\n // Horizontal gradient, from left to right\n //\n // Creates two color stops, start and end, by specifying a color and position for each color stop.\n // Color stops are not available in IE9 and below.\n .horizontal(@start-color: #555; @end-color: #333; @start-percent: 0%; @end-percent: 100%) {\n background-image: -webkit-linear-gradient(left, @start-color @start-percent, @end-color @end-percent); // Safari 5.1-6, Chrome 10+\n background-image: -o-linear-gradient(left, @start-color @start-percent, @end-color @end-percent); // Opera 12\n background-image: linear-gradient(to right, @start-color @start-percent, @end-color @end-percent); // Standard, IE10, Firefox 16+, Opera 12.10+, Safari 7+, Chrome 26+\n background-repeat: repeat-x;\n filter: e(%(\"progid:DXImageTransform.Microsoft.gradient(startColorstr='%d', endColorstr='%d', GradientType=1)\",argb(@start-color),argb(@end-color))); // IE9 and down\n }\n\n // Vertical gradient, from top to bottom\n //\n // Creates two color stops, start and end, by specifying a color and position for each color stop.\n // Color stops are not available in IE9 and below.\n .vertical(@start-color: #555; @end-color: #333; @start-percent: 0%; @end-percent: 100%) {\n background-image: -webkit-linear-gradient(top, @start-color @start-percent, @end-color @end-percent); // Safari 5.1-6, Chrome 10+\n background-image: -o-linear-gradient(top, @start-color @start-percent, @end-color @end-percent); // Opera 12\n background-image: linear-gradient(to bottom, @start-color @start-percent, @end-color @end-percent); // Standard, IE10, Firefox 16+, Opera 12.10+, Safari 7+, Chrome 26+\n background-repeat: repeat-x;\n filter: e(%(\"progid:DXImageTransform.Microsoft.gradient(startColorstr='%d', endColorstr='%d', GradientType=0)\",argb(@start-color),argb(@end-color))); // IE9 and down\n }\n\n .directional(@start-color: #555; @end-color: #333; @deg: 45deg) {\n background-repeat: repeat-x;\n background-image: -webkit-linear-gradient(@deg, @start-color, @end-color); // Safari 5.1-6, Chrome 10+\n background-image: -o-linear-gradient(@deg, @start-color, @end-color); // Opera 12\n background-image: linear-gradient(@deg, @start-color, @end-color); // Standard, IE10, Firefox 16+, Opera 12.10+, Safari 7+, Chrome 26+\n }\n .horizontal-three-colors(@start-color: #00b3ee; @mid-color: #7a43b6; @color-stop: 50%; @end-color: #c3325f) {\n background-image: -webkit-linear-gradient(left, @start-color, @mid-color @color-stop, @end-color);\n background-image: -o-linear-gradient(left, @start-color, @mid-color @color-stop, @end-color);\n background-image: linear-gradient(to right, @start-color, @mid-color @color-stop, @end-color);\n background-repeat: no-repeat;\n filter: e(%(\"progid:DXImageTransform.Microsoft.gradient(startColorstr='%d', endColorstr='%d', GradientType=1)\",argb(@start-color),argb(@end-color))); // IE9 and down, gets no color-stop at all for proper fallback\n }\n .vertical-three-colors(@start-color: #00b3ee; @mid-color: #7a43b6; @color-stop: 50%; @end-color: #c3325f) {\n background-image: -webkit-linear-gradient(@start-color, @mid-color @color-stop, @end-color);\n background-image: -o-linear-gradient(@start-color, @mid-color @color-stop, @end-color);\n background-image: linear-gradient(@start-color, @mid-color @color-stop, @end-color);\n background-repeat: no-repeat;\n filter: e(%(\"progid:DXImageTransform.Microsoft.gradient(startColorstr='%d', endColorstr='%d', GradientType=0)\",argb(@start-color),argb(@end-color))); // IE9 and down, gets no color-stop at all for proper fallback\n }\n .radial(@inner-color: #555; @outer-color: #333) {\n background-image: -webkit-radial-gradient(circle, @inner-color, @outer-color);\n background-image: radial-gradient(circle, @inner-color, @outer-color);\n background-repeat: no-repeat;\n }\n .striped(@color: rgba(255,255,255,.15); @angle: 45deg) {\n background-image: -webkit-linear-gradient(@angle, @color 25%, transparent 25%, transparent 50%, @color 50%, @color 75%, transparent 75%, transparent);\n background-image: -o-linear-gradient(@angle, @color 25%, transparent 25%, transparent 50%, @color 50%, @color 75%, transparent 75%, transparent);\n background-image: linear-gradient(@angle, @color 25%, transparent 25%, transparent 50%, @color 50%, @color 75%, transparent 75%, transparent);\n }\n}\n","// Progress bars\n\n.progress-bar-variant(@color) {\n background-color: @color;\n\n // Deprecated parent class requirement as of v3.2.0\n .progress-striped & {\n #gradient > .striped();\n }\n}\n","// Media objects\n// Source: http://stubbornella.org/content/?p=497\n// --------------------------------------------------\n\n\n// Common styles\n// -------------------------\n\n// Clear the floats\n.media,\n.media-body {\n overflow: hidden;\n zoom: 1;\n}\n\n// Proper spacing between instances of .media\n.media,\n.media .media {\n margin-top: 15px;\n}\n.media:first-child {\n margin-top: 0;\n}\n\n// For images and videos, set to block\n.media-object {\n display: block;\n}\n\n// Reset margins on headings for tighter default spacing\n.media-heading {\n margin: 0 0 5px;\n}\n\n\n// Media image alignment\n// -------------------------\n\n.media {\n > .pull-left {\n margin-right: 10px;\n }\n > .pull-right {\n margin-left: 10px;\n }\n}\n\n\n// Media list variation\n// -------------------------\n\n// Undo default ul/ol styles\n.media-list {\n padding-left: 0;\n list-style: none;\n}\n","//\n// List groups\n// --------------------------------------------------\n\n\n// Base class\n//\n// Easily usable on <ul>, <ol>, or <div>.\n\n.list-group {\n // No need to set list-style: none; since .list-group-item is block level\n margin-bottom: 20px;\n padding-left: 0; // reset padding because ul and ol\n}\n\n\n// Individual list items\n//\n// Use on `li`s or `div`s within the `.list-group` parent.\n\n.list-group-item {\n position: relative;\n display: block;\n padding: 10px 15px;\n // Place the border on the list items and negative margin up for better styling\n margin-bottom: -1px;\n background-color: @list-group-bg;\n border: 1px solid @list-group-border;\n\n // Round the first and last items\n &:first-child {\n .border-top-radius(@list-group-border-radius);\n }\n &:last-child {\n margin-bottom: 0;\n .border-bottom-radius(@list-group-border-radius);\n }\n\n // Align badges within list items\n > .badge {\n float: right;\n }\n > .badge + .badge {\n margin-right: 5px;\n }\n}\n\n\n// Linked list items\n//\n// Use anchor elements instead of `li`s or `div`s to create linked list items.\n// Includes an extra `.active` modifier class for showing selected items.\n\na.list-group-item {\n color: @list-group-link-color;\n\n .list-group-item-heading {\n color: @list-group-link-heading-color;\n }\n\n // Hover state\n &:hover,\n &:focus {\n text-decoration: none;\n color: @list-group-link-hover-color;\n background-color: @list-group-hover-bg;\n }\n}\n\n.list-group-item {\n // Disabled state\n &.disabled,\n &.disabled:hover,\n &.disabled:focus {\n background-color: @list-group-disabled-bg;\n color: @list-group-disabled-color;\n\n // Force color to inherit for custom content\n .list-group-item-heading {\n color: inherit;\n }\n .list-group-item-text {\n color: @list-group-disabled-text-color;\n }\n }\n\n // Active class on item itself, not parent\n &.active,\n &.active:hover,\n &.active:focus {\n z-index: 2; // Place active items above their siblings for proper border styling\n color: @list-group-active-color;\n background-color: @list-group-active-bg;\n border-color: @list-group-active-border;\n\n // Force color to inherit for custom content\n .list-group-item-heading,\n .list-group-item-heading > small,\n .list-group-item-heading > .small {\n color: inherit;\n }\n .list-group-item-text {\n color: @list-group-active-text-color;\n }\n }\n}\n\n\n// Contextual variants\n//\n// Add modifier classes to change text and background color on individual items.\n// Organizationally, this must come after the `:hover` states.\n\n.list-group-item-variant(success; @state-success-bg; @state-success-text);\n.list-group-item-variant(info; @state-info-bg; @state-info-text);\n.list-group-item-variant(warning; @state-warning-bg; @state-warning-text);\n.list-group-item-variant(danger; @state-danger-bg; @state-danger-text);\n\n\n// Custom content options\n//\n// Extra classes for creating well-formatted content within `.list-group-item`s.\n\n.list-group-item-heading {\n margin-top: 0;\n margin-bottom: 5px;\n}\n.list-group-item-text {\n margin-bottom: 0;\n line-height: 1.3;\n}\n","// List Groups\n\n.list-group-item-variant(@state; @background; @color) {\n .list-group-item-@{state} {\n color: @color;\n background-color: @background;\n\n a& {\n color: @color;\n\n .list-group-item-heading {\n color: inherit;\n }\n\n &:hover,\n &:focus {\n color: @color;\n background-color: darken(@background, 5%);\n }\n &.active,\n &.active:hover,\n &.active:focus {\n color: #fff;\n background-color: @color;\n border-color: @color;\n }\n }\n }\n}\n","//\n// Panels\n// --------------------------------------------------\n\n\n// Base class\n.panel {\n margin-bottom: @line-height-computed;\n background-color: @panel-bg;\n border: 1px solid transparent;\n border-radius: @panel-border-radius;\n .box-shadow(0 1px 1px rgba(0,0,0,.05));\n}\n\n// Panel contents\n.panel-body {\n padding: @panel-body-padding;\n &:extend(.clearfix all);\n}\n\n// Optional heading\n.panel-heading {\n padding: @panel-heading-padding;\n border-bottom: 1px solid transparent;\n .border-top-radius((@panel-border-radius - 1));\n\n > .dropdown .dropdown-toggle {\n color: inherit;\n }\n}\n\n// Within heading, strip any `h*` tag of its default margins for spacing.\n.panel-title {\n margin-top: 0;\n margin-bottom: 0;\n font-size: ceil((@font-size-base * 1.125));\n color: inherit;\n\n > a {\n color: inherit;\n }\n}\n\n// Optional footer (stays gray in every modifier class)\n.panel-footer {\n padding: @panel-footer-padding;\n background-color: @panel-footer-bg;\n border-top: 1px solid @panel-inner-border;\n .border-bottom-radius((@panel-border-radius - 1));\n}\n\n\n// List groups in panels\n//\n// By default, space out list group content from panel headings to account for\n// any kind of custom content between the two.\n\n.panel {\n > .list-group {\n margin-bottom: 0;\n\n .list-group-item {\n border-width: 1px 0;\n border-radius: 0;\n }\n\n // Add border top radius for first one\n &:first-child {\n .list-group-item:first-child {\n border-top: 0;\n .border-top-radius((@panel-border-radius - 1));\n }\n }\n // Add border bottom radius for last one\n &:last-child {\n .list-group-item:last-child {\n border-bottom: 0;\n .border-bottom-radius((@panel-border-radius - 1));\n }\n }\n }\n}\n// Collapse space between when there's no additional content.\n.panel-heading + .list-group {\n .list-group-item:first-child {\n border-top-width: 0;\n }\n}\n.list-group + .panel-footer {\n border-top-width: 0;\n}\n\n// Tables in panels\n//\n// Place a non-bordered `.table` within a panel (not within a `.panel-body`) and\n// watch it go full width.\n\n.panel {\n > .table,\n > .table-responsive > .table,\n > .panel-collapse > .table {\n margin-bottom: 0;\n }\n // Add border top radius for first one\n > .table:first-child,\n > .table-responsive:first-child > .table:first-child {\n .border-top-radius((@panel-border-radius - 1));\n\n > thead:first-child,\n > tbody:first-child {\n > tr:first-child {\n td:first-child,\n th:first-child {\n border-top-left-radius: (@panel-border-radius - 1);\n }\n td:last-child,\n th:last-child {\n border-top-right-radius: (@panel-border-radius - 1);\n }\n }\n }\n }\n // Add border bottom radius for last one\n > .table:last-child,\n > .table-responsive:last-child > .table:last-child {\n .border-bottom-radius((@panel-border-radius - 1));\n\n > tbody:last-child,\n > tfoot:last-child {\n > tr:last-child {\n td:first-child,\n th:first-child {\n border-bottom-left-radius: (@panel-border-radius - 1);\n }\n td:last-child,\n th:last-child {\n border-bottom-right-radius: (@panel-border-radius - 1);\n }\n }\n }\n }\n > .panel-body + .table,\n > .panel-body + .table-responsive {\n border-top: 1px solid @table-border-color;\n }\n > .table > tbody:first-child > tr:first-child th,\n > .table > tbody:first-child > tr:first-child td {\n border-top: 0;\n }\n > .table-bordered,\n > .table-responsive > .table-bordered {\n border: 0;\n > thead,\n > tbody,\n > tfoot {\n > tr {\n > th:first-child,\n > td:first-child {\n border-left: 0;\n }\n > th:last-child,\n > td:last-child {\n border-right: 0;\n }\n }\n }\n > thead,\n > tbody {\n > tr:first-child {\n > td,\n > th {\n border-bottom: 0;\n }\n }\n }\n > tbody,\n > tfoot {\n > tr:last-child {\n > td,\n > th {\n border-bottom: 0;\n }\n }\n }\n }\n > .table-responsive {\n border: 0;\n margin-bottom: 0;\n }\n}\n\n\n// Collapsable panels (aka, accordion)\n//\n// Wrap a series of panels in `.panel-group` to turn them into an accordion with\n// the help of our collapse JavaScript plugin.\n\n.panel-group {\n margin-bottom: @line-height-computed;\n\n // Tighten up margin so it's only between panels\n .panel {\n margin-bottom: 0;\n border-radius: @panel-border-radius;\n + .panel {\n margin-top: 5px;\n }\n }\n\n .panel-heading {\n border-bottom: 0;\n + .panel-collapse > .panel-body {\n border-top: 1px solid @panel-inner-border;\n }\n }\n .panel-footer {\n border-top: 0;\n + .panel-collapse .panel-body {\n border-bottom: 1px solid @panel-inner-border;\n }\n }\n}\n\n\n// Contextual variations\n.panel-default {\n .panel-variant(@panel-default-border; @panel-default-text; @panel-default-heading-bg; @panel-default-border);\n}\n.panel-primary {\n .panel-variant(@panel-primary-border; @panel-primary-text; @panel-primary-heading-bg; @panel-primary-border);\n}\n.panel-success {\n .panel-variant(@panel-success-border; @panel-success-text; @panel-success-heading-bg; @panel-success-border);\n}\n.panel-info {\n .panel-variant(@panel-info-border; @panel-info-text; @panel-info-heading-bg; @panel-info-border);\n}\n.panel-warning {\n .panel-variant(@panel-warning-border; @panel-warning-text; @panel-warning-heading-bg; @panel-warning-border);\n}\n.panel-danger {\n .panel-variant(@panel-danger-border; @panel-danger-text; @panel-danger-heading-bg; @panel-danger-border);\n}\n","// Panels\n\n.panel-variant(@border; @heading-text-color; @heading-bg-color; @heading-border) {\n border-color: @border;\n\n & > .panel-heading {\n color: @heading-text-color;\n background-color: @heading-bg-color;\n border-color: @heading-border;\n\n + .panel-collapse > .panel-body {\n border-top-color: @border;\n }\n .badge {\n color: @heading-bg-color;\n background-color: @heading-text-color;\n }\n }\n & > .panel-footer {\n + .panel-collapse > .panel-body {\n border-bottom-color: @border;\n }\n }\n}\n","// Embeds responsive\n//\n// Credit: Nicolas Gallagher and SUIT CSS.\n\n.embed-responsive {\n position: relative;\n display: block;\n height: 0;\n padding: 0;\n overflow: hidden;\n\n .embed-responsive-item,\n iframe,\n embed,\n object {\n position: absolute;\n top: 0;\n left: 0;\n bottom: 0;\n height: 100%;\n width: 100%;\n border: 0;\n }\n\n // Modifier class for 16:9 aspect ratio\n &.embed-responsive-16by9 {\n padding-bottom: 56.25%;\n }\n\n // Modifier class for 4:3 aspect ratio\n &.embed-responsive-4by3 {\n padding-bottom: 75%;\n }\n}\n","//\n// Wells\n// --------------------------------------------------\n\n\n// Base class\n.well {\n min-height: 20px;\n padding: 19px;\n margin-bottom: 20px;\n background-color: @well-bg;\n border: 1px solid @well-border;\n border-radius: @border-radius-base;\n .box-shadow(inset 0 1px 1px rgba(0,0,0,.05));\n blockquote {\n border-color: #ddd;\n border-color: rgba(0,0,0,.15);\n }\n}\n\n// Sizes\n.well-lg {\n padding: 24px;\n border-radius: @border-radius-large;\n}\n.well-sm {\n padding: 9px;\n border-radius: @border-radius-small;\n}\n","//\n// Close icons\n// --------------------------------------------------\n\n\n.close {\n float: right;\n font-size: (@font-size-base * 1.5);\n font-weight: @close-font-weight;\n line-height: 1;\n color: @close-color;\n text-shadow: @close-text-shadow;\n .opacity(.2);\n\n &:hover,\n &:focus {\n color: @close-color;\n text-decoration: none;\n cursor: pointer;\n .opacity(.5);\n }\n\n // Additional properties for button version\n // iOS requires the button element instead of an anchor tag.\n // If you want the anchor version, it requires `href=\"#\"`.\n button& {\n padding: 0;\n cursor: pointer;\n background: transparent;\n border: 0;\n -webkit-appearance: none;\n }\n}\n","//\n// Modals\n// --------------------------------------------------\n\n// .modal-open - body class for killing the scroll\n// .modal - container to scroll within\n// .modal-dialog - positioning shell for the actual modal\n// .modal-content - actual modal w/ bg and corners and shit\n\n// Kill the scroll on the body\n.modal-open {\n overflow: hidden;\n}\n\n// Container that the modal scrolls within\n.modal {\n display: none;\n overflow: hidden;\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: @zindex-modal;\n -webkit-overflow-scrolling: touch;\n\n // Prevent Chrome on Windows from adding a focus outline. For details, see\n // https://github.com/twbs/bootstrap/pull/10951.\n outline: 0;\n\n // When fading in the modal, animate it to slide down\n &.fade .modal-dialog {\n .translate3d(0, -25%, 0);\n .transition-transform(~\"0.3s ease-out\");\n }\n &.in .modal-dialog { .translate3d(0, 0, 0) }\n}\n.modal-open .modal {\n overflow-x: hidden;\n overflow-y: auto;\n}\n\n// Shell div to position the modal with bottom padding\n.modal-dialog {\n position: relative;\n width: auto;\n margin: 10px;\n}\n\n// Actual modal\n.modal-content {\n position: relative;\n background-color: @modal-content-bg;\n border: 1px solid @modal-content-fallback-border-color; //old browsers fallback (ie8 etc)\n border: 1px solid @modal-content-border-color;\n border-radius: @border-radius-large;\n .box-shadow(0 3px 9px rgba(0,0,0,.5));\n background-clip: padding-box;\n // Remove focus outline from opened modal\n outline: 0;\n}\n\n// Modal background\n.modal-backdrop {\n position: fixed;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: @zindex-modal-background;\n background-color: @modal-backdrop-bg;\n // Fade for backdrop\n &.fade { .opacity(0); }\n &.in { .opacity(@modal-backdrop-opacity); }\n}\n\n// Modal header\n// Top section of the modal w/ title and dismiss\n.modal-header {\n padding: @modal-title-padding;\n border-bottom: 1px solid @modal-header-border-color;\n min-height: (@modal-title-padding + @modal-title-line-height);\n}\n// Close icon\n.modal-header .close {\n margin-top: -2px;\n}\n\n// Title text within header\n.modal-title {\n margin: 0;\n line-height: @modal-title-line-height;\n}\n\n// Modal body\n// Where all modal content resides (sibling of .modal-header and .modal-footer)\n.modal-body {\n position: relative;\n padding: @modal-inner-padding;\n}\n\n// Footer (for actions)\n.modal-footer {\n padding: @modal-inner-padding;\n text-align: right; // right align buttons\n border-top: 1px solid @modal-footer-border-color;\n &:extend(.clearfix all); // clear it in case folks use .pull-* classes on buttons\n\n // Properly space out buttons\n .btn + .btn {\n margin-left: 5px;\n margin-bottom: 0; // account for input[type=\"submit\"] which gets the bottom margin like all other inputs\n }\n // but override that for button groups\n .btn-group .btn + .btn {\n margin-left: -1px;\n }\n // and override it for block buttons as well\n .btn-block + .btn-block {\n margin-left: 0;\n }\n}\n\n// Measure scrollbar width for padding body during modal show/hide\n.modal-scrollbar-measure {\n position: absolute;\n top: -9999px;\n width: 50px;\n height: 50px;\n overflow: scroll;\n}\n\n// Scale up the modal\n@media (min-width: @screen-sm-min) {\n // Automatically set modal's width for larger viewports\n .modal-dialog {\n width: @modal-md;\n margin: 30px auto;\n }\n .modal-content {\n .box-shadow(0 5px 15px rgba(0,0,0,.5));\n }\n\n // Modal sizes\n .modal-sm { width: @modal-sm; }\n}\n\n@media (min-width: @screen-md-min) {\n .modal-lg { width: @modal-lg; }\n}\n","//\n// Tooltips\n// --------------------------------------------------\n\n\n// Base class\n.tooltip {\n position: absolute;\n z-index: @zindex-tooltip;\n display: block;\n visibility: visible;\n font-size: @font-size-small;\n line-height: 1.4;\n .opacity(0);\n\n &.in { .opacity(@tooltip-opacity); }\n &.top { margin-top: -3px; padding: @tooltip-arrow-width 0; }\n &.right { margin-left: 3px; padding: 0 @tooltip-arrow-width; }\n &.bottom { margin-top: 3px; padding: @tooltip-arrow-width 0; }\n &.left { margin-left: -3px; padding: 0 @tooltip-arrow-width; }\n}\n\n// Wrapper for the tooltip content\n.tooltip-inner {\n max-width: @tooltip-max-width;\n padding: 3px 8px;\n color: @tooltip-color;\n text-align: center;\n text-decoration: none;\n background-color: @tooltip-bg;\n border-radius: @border-radius-base;\n}\n\n// Arrows\n.tooltip-arrow {\n position: absolute;\n width: 0;\n height: 0;\n border-color: transparent;\n border-style: solid;\n}\n.tooltip {\n &.top .tooltip-arrow {\n bottom: 0;\n left: 50%;\n margin-left: -@tooltip-arrow-width;\n border-width: @tooltip-arrow-width @tooltip-arrow-width 0;\n border-top-color: @tooltip-arrow-color;\n }\n &.top-left .tooltip-arrow {\n bottom: 0;\n left: @tooltip-arrow-width;\n border-width: @tooltip-arrow-width @tooltip-arrow-width 0;\n border-top-color: @tooltip-arrow-color;\n }\n &.top-right .tooltip-arrow {\n bottom: 0;\n right: @tooltip-arrow-width;\n border-width: @tooltip-arrow-width @tooltip-arrow-width 0;\n border-top-color: @tooltip-arrow-color;\n }\n &.right .tooltip-arrow {\n top: 50%;\n left: 0;\n margin-top: -@tooltip-arrow-width;\n border-width: @tooltip-arrow-width @tooltip-arrow-width @tooltip-arrow-width 0;\n border-right-color: @tooltip-arrow-color;\n }\n &.left .tooltip-arrow {\n top: 50%;\n right: 0;\n margin-top: -@tooltip-arrow-width;\n border-width: @tooltip-arrow-width 0 @tooltip-arrow-width @tooltip-arrow-width;\n border-left-color: @tooltip-arrow-color;\n }\n &.bottom .tooltip-arrow {\n top: 0;\n left: 50%;\n margin-left: -@tooltip-arrow-width;\n border-width: 0 @tooltip-arrow-width @tooltip-arrow-width;\n border-bottom-color: @tooltip-arrow-color;\n }\n &.bottom-left .tooltip-arrow {\n top: 0;\n left: @tooltip-arrow-width;\n border-width: 0 @tooltip-arrow-width @tooltip-arrow-width;\n border-bottom-color: @tooltip-arrow-color;\n }\n &.bottom-right .tooltip-arrow {\n top: 0;\n right: @tooltip-arrow-width;\n border-width: 0 @tooltip-arrow-width @tooltip-arrow-width;\n border-bottom-color: @tooltip-arrow-color;\n }\n}\n","//\n// Popovers\n// --------------------------------------------------\n\n\n.popover {\n position: absolute;\n top: 0;\n left: 0;\n z-index: @zindex-popover;\n display: none;\n max-width: @popover-max-width;\n padding: 1px;\n text-align: left; // Reset given new insertion method\n background-color: @popover-bg;\n background-clip: padding-box;\n border: 1px solid @popover-fallback-border-color;\n border: 1px solid @popover-border-color;\n border-radius: @border-radius-large;\n .box-shadow(0 5px 10px rgba(0,0,0,.2));\n\n // Overrides for proper insertion\n white-space: normal;\n\n // Offset the popover to account for the popover arrow\n &.top { margin-top: -@popover-arrow-width; }\n &.right { margin-left: @popover-arrow-width; }\n &.bottom { margin-top: @popover-arrow-width; }\n &.left { margin-left: -@popover-arrow-width; }\n}\n\n.popover-title {\n margin: 0; // reset heading margin\n padding: 8px 14px;\n font-size: @font-size-base;\n font-weight: normal;\n line-height: 18px;\n background-color: @popover-title-bg;\n border-bottom: 1px solid darken(@popover-title-bg, 5%);\n border-radius: (@border-radius-large - 1) (@border-radius-large - 1) 0 0;\n}\n\n.popover-content {\n padding: 9px 14px;\n}\n\n// Arrows\n//\n// .arrow is outer, .arrow:after is inner\n\n.popover > .arrow {\n &,\n &:after {\n position: absolute;\n display: block;\n width: 0;\n height: 0;\n border-color: transparent;\n border-style: solid;\n }\n}\n.popover > .arrow {\n border-width: @popover-arrow-outer-width;\n}\n.popover > .arrow:after {\n border-width: @popover-arrow-width;\n content: \"\";\n}\n\n.popover {\n &.top > .arrow {\n left: 50%;\n margin-left: -@popover-arrow-outer-width;\n border-bottom-width: 0;\n border-top-color: @popover-arrow-outer-fallback-color; // IE8 fallback\n border-top-color: @popover-arrow-outer-color;\n bottom: -@popover-arrow-outer-width;\n &:after {\n content: \" \";\n bottom: 1px;\n margin-left: -@popover-arrow-width;\n border-bottom-width: 0;\n border-top-color: @popover-arrow-color;\n }\n }\n &.right > .arrow {\n top: 50%;\n left: -@popover-arrow-outer-width;\n margin-top: -@popover-arrow-outer-width;\n border-left-width: 0;\n border-right-color: @popover-arrow-outer-fallback-color; // IE8 fallback\n border-right-color: @popover-arrow-outer-color;\n &:after {\n content: \" \";\n left: 1px;\n bottom: -@popover-arrow-width;\n border-left-width: 0;\n border-right-color: @popover-arrow-color;\n }\n }\n &.bottom > .arrow {\n left: 50%;\n margin-left: -@popover-arrow-outer-width;\n border-top-width: 0;\n border-bottom-color: @popover-arrow-outer-fallback-color; // IE8 fallback\n border-bottom-color: @popover-arrow-outer-color;\n top: -@popover-arrow-outer-width;\n &:after {\n content: \" \";\n top: 1px;\n margin-left: -@popover-arrow-width;\n border-top-width: 0;\n border-bottom-color: @popover-arrow-color;\n }\n }\n\n &.left > .arrow {\n top: 50%;\n right: -@popover-arrow-outer-width;\n margin-top: -@popover-arrow-outer-width;\n border-right-width: 0;\n border-left-color: @popover-arrow-outer-fallback-color; // IE8 fallback\n border-left-color: @popover-arrow-outer-color;\n &:after {\n content: \" \";\n right: 1px;\n border-right-width: 0;\n border-left-color: @popover-arrow-color;\n bottom: -@popover-arrow-width;\n }\n }\n\n}\n","//\n// Carousel\n// --------------------------------------------------\n\n\n// Wrapper for the slide container and indicators\n.carousel {\n position: relative;\n}\n\n.carousel-inner {\n position: relative;\n overflow: hidden;\n width: 100%;\n\n > .item {\n display: none;\n position: relative;\n .transition(.6s ease-in-out left);\n\n // Account for jankitude on images\n > img,\n > a > img {\n &:extend(.img-responsive);\n line-height: 1;\n }\n }\n\n > .active,\n > .next,\n > .prev {\n display: block;\n }\n\n > .active {\n left: 0;\n }\n\n > .next,\n > .prev {\n position: absolute;\n top: 0;\n width: 100%;\n }\n\n > .next {\n left: 100%;\n }\n > .prev {\n left: -100%;\n }\n > .next.left,\n > .prev.right {\n left: 0;\n }\n\n > .active.left {\n left: -100%;\n }\n > .active.right {\n left: 100%;\n }\n\n}\n\n// Left/right controls for nav\n// ---------------------------\n\n.carousel-control {\n position: absolute;\n top: 0;\n left: 0;\n bottom: 0;\n width: @carousel-control-width;\n .opacity(@carousel-control-opacity);\n font-size: @carousel-control-font-size;\n color: @carousel-control-color;\n text-align: center;\n text-shadow: @carousel-text-shadow;\n // We can't have this transition here because WebKit cancels the carousel\n // animation if you trip this while in the middle of another animation.\n\n // Set gradients for backgrounds\n &.left {\n #gradient > .horizontal(@start-color: rgba(0,0,0,.5); @end-color: rgba(0,0,0,.0001));\n }\n &.right {\n left: auto;\n right: 0;\n #gradient > .horizontal(@start-color: rgba(0,0,0,.0001); @end-color: rgba(0,0,0,.5));\n }\n\n // Hover/focus state\n &:hover,\n &:focus {\n outline: 0;\n color: @carousel-control-color;\n text-decoration: none;\n .opacity(.9);\n }\n\n // Toggles\n .icon-prev,\n .icon-next,\n .glyphicon-chevron-left,\n .glyphicon-chevron-right {\n position: absolute;\n top: 50%;\n z-index: 5;\n display: inline-block;\n }\n .icon-prev,\n .glyphicon-chevron-left {\n left: 50%;\n margin-left: -10px;\n }\n .icon-next,\n .glyphicon-chevron-right {\n right: 50%;\n margin-right: -10px;\n }\n .icon-prev,\n .icon-next {\n width: 20px;\n height: 20px;\n margin-top: -10px;\n font-family: serif;\n }\n\n\n .icon-prev {\n &:before {\n content: '\\2039';// SINGLE LEFT-POINTING ANGLE QUOTATION MARK (U+2039)\n }\n }\n .icon-next {\n &:before {\n content: '\\203a';// SINGLE RIGHT-POINTING ANGLE QUOTATION MARK (U+203A)\n }\n }\n}\n\n// Optional indicator pips\n//\n// Add an unordered list with the following class and add a list item for each\n// slide your carousel holds.\n\n.carousel-indicators {\n position: absolute;\n bottom: 10px;\n left: 50%;\n z-index: 15;\n width: 60%;\n margin-left: -30%;\n padding-left: 0;\n list-style: none;\n text-align: center;\n\n li {\n display: inline-block;\n width: 10px;\n height: 10px;\n margin: 1px;\n text-indent: -999px;\n border: 1px solid @carousel-indicator-border-color;\n border-radius: 10px;\n cursor: pointer;\n\n // IE8-9 hack for event handling\n //\n // Internet Explorer 8-9 does not support clicks on elements without a set\n // `background-color`. We cannot use `filter` since that's not viewed as a\n // background color by the browser. Thus, a hack is needed.\n //\n // For IE8, we set solid black as it doesn't support `rgba()`. For IE9, we\n // set alpha transparency for the best results possible.\n background-color: #000 \\9; // IE8\n background-color: rgba(0,0,0,0); // IE9\n }\n .active {\n margin: 0;\n width: 12px;\n height: 12px;\n background-color: @carousel-indicator-active-bg;\n }\n}\n\n// Optional captions\n// -----------------------------\n// Hidden by default for smaller viewports\n.carousel-caption {\n position: absolute;\n left: 15%;\n right: 15%;\n bottom: 20px;\n z-index: 10;\n padding-top: 20px;\n padding-bottom: 20px;\n color: @carousel-caption-color;\n text-align: center;\n text-shadow: @carousel-text-shadow;\n & .btn {\n text-shadow: none; // No shadow for button elements in carousel-caption\n }\n}\n\n\n// Scale up controls for tablets and up\n@media screen and (min-width: @screen-sm-min) {\n\n // Scale up the controls a smidge\n .carousel-control {\n .glyphicon-chevron-left,\n .glyphicon-chevron-right,\n .icon-prev,\n .icon-next {\n width: 30px;\n height: 30px;\n margin-top: -15px;\n font-size: 30px;\n }\n .glyphicon-chevron-left,\n .icon-prev {\n margin-left: -15px;\n }\n .glyphicon-chevron-right,\n .icon-next {\n margin-right: -15px;\n }\n }\n\n // Show and left align the captions\n .carousel-caption {\n left: 20%;\n right: 20%;\n padding-bottom: 30px;\n }\n\n // Move up the indicators\n .carousel-indicators {\n bottom: 20px;\n }\n}\n","// Clearfix\n//\n// For modern browsers\n// 1. The space content is one way to avoid an Opera bug when the\n// contenteditable attribute is included anywhere else in the document.\n// Otherwise it causes space to appear at the top and bottom of elements\n// that are clearfixed.\n// 2. The use of `table` rather than `block` is only necessary if using\n// `:before` to contain the top-margins of child elements.\n//\n// Source: http://nicolasgallagher.com/micro-clearfix-hack/\n\n.clearfix() {\n &:before,\n &:after {\n content: \" \"; // 1\n display: table; // 2\n }\n &:after {\n clear: both;\n }\n}\n","// Center-align a block level element\n\n.center-block() {\n display: block;\n margin-left: auto;\n margin-right: auto;\n}\n","// CSS image replacement\n//\n// Heads up! v3 launched with with only `.hide-text()`, but per our pattern for\n// mixins being reused as classes with the same name, this doesn't hold up. As\n// of v3.0.1 we have added `.text-hide()` and deprecated `.hide-text()`.\n//\n// Source: https://github.com/h5bp/html5-boilerplate/commit/aa0396eae757\n\n// Deprecated as of v3.0.1 (will be removed in v4)\n.hide-text() {\n font: ~\"0/0\" a;\n color: transparent;\n text-shadow: none;\n background-color: transparent;\n border: 0;\n}\n\n// New mixin to use as of v3.0.1\n.text-hide() {\n .hide-text();\n}\n","//\n// Responsive: Utility classes\n// --------------------------------------------------\n\n\n// IE10 in Windows (Phone) 8\n//\n// Support for responsive views via media queries is kind of borked in IE10, for\n// Surface/desktop in split view and for Windows Phone 8. This particular fix\n// must be accompanied by a snippet of JavaScript to sniff the user agent and\n// apply some conditional CSS to *only* the Surface/desktop Windows 8. Look at\n// our Getting Started page for more information on this bug.\n//\n// For more information, see the following:\n//\n// Issue: https://github.com/twbs/bootstrap/issues/10497\n// Docs: http://getbootstrap.com/getting-started/#support-ie10-width\n// Source: http://timkadlec.com/2013/01/windows-phone-8-and-device-width/\n// Source: http://timkadlec.com/2012/10/ie10-snap-mode-and-responsive-design/\n\n@-ms-viewport {\n width: device-width;\n}\n\n\n// Visibility utilities\n// Note: Deprecated .visible-xs, .visible-sm, .visible-md, and .visible-lg as of v3.2.0\n.visible-xs,\n.visible-sm,\n.visible-md,\n.visible-lg {\n .responsive-invisibility();\n}\n\n.visible-xs-block,\n.visible-xs-inline,\n.visible-xs-inline-block,\n.visible-sm-block,\n.visible-sm-inline,\n.visible-sm-inline-block,\n.visible-md-block,\n.visible-md-inline,\n.visible-md-inline-block,\n.visible-lg-block,\n.visible-lg-inline,\n.visible-lg-inline-block {\n display: none !important;\n}\n\n.visible-xs {\n @media (max-width: @screen-xs-max) {\n .responsive-visibility();\n }\n}\n.visible-xs-block {\n @media (max-width: @screen-xs-max) {\n display: block !important;\n }\n}\n.visible-xs-inline {\n @media (max-width: @screen-xs-max) {\n display: inline !important;\n }\n}\n.visible-xs-inline-block {\n @media (max-width: @screen-xs-max) {\n display: inline-block !important;\n }\n}\n\n.visible-sm {\n @media (min-width: @screen-sm-min) and (max-width: @screen-sm-max) {\n .responsive-visibility();\n }\n}\n.visible-sm-block {\n @media (min-width: @screen-sm-min) and (max-width: @screen-sm-max) {\n display: block !important;\n }\n}\n.visible-sm-inline {\n @media (min-width: @screen-sm-min) and (max-width: @screen-sm-max) {\n display: inline !important;\n }\n}\n.visible-sm-inline-block {\n @media (min-width: @screen-sm-min) and (max-width: @screen-sm-max) {\n display: inline-block !important;\n }\n}\n\n.visible-md {\n @media (min-width: @screen-md-min) and (max-width: @screen-md-max) {\n .responsive-visibility();\n }\n}\n.visible-md-block {\n @media (min-width: @screen-md-min) and (max-width: @screen-md-max) {\n display: block !important;\n }\n}\n.visible-md-inline {\n @media (min-width: @screen-md-min) and (max-width: @screen-md-max) {\n display: inline !important;\n }\n}\n.visible-md-inline-block {\n @media (min-width: @screen-md-min) and (max-width: @screen-md-max) {\n display: inline-block !important;\n }\n}\n\n.visible-lg {\n @media (min-width: @screen-lg-min) {\n .responsive-visibility();\n }\n}\n.visible-lg-block {\n @media (min-width: @screen-lg-min) {\n display: block !important;\n }\n}\n.visible-lg-inline {\n @media (min-width: @screen-lg-min) {\n display: inline !important;\n }\n}\n.visible-lg-inline-block {\n @media (min-width: @screen-lg-min) {\n display: inline-block !important;\n }\n}\n\n.hidden-xs {\n @media (max-width: @screen-xs-max) {\n .responsive-invisibility();\n }\n}\n.hidden-sm {\n @media (min-width: @screen-sm-min) and (max-width: @screen-sm-max) {\n .responsive-invisibility();\n }\n}\n.hidden-md {\n @media (min-width: @screen-md-min) and (max-width: @screen-md-max) {\n .responsive-invisibility();\n }\n}\n.hidden-lg {\n @media (min-width: @screen-lg-min) {\n .responsive-invisibility();\n }\n}\n\n\n// Print utilities\n//\n// Media queries are placed on the inside to be mixin-friendly.\n\n// Note: Deprecated .visible-print as of v3.2.0\n.visible-print {\n .responsive-invisibility();\n\n @media print {\n .responsive-visibility();\n }\n}\n.visible-print-block {\n display: none !important;\n\n @media print {\n display: block !important;\n }\n}\n.visible-print-inline {\n display: none !important;\n\n @media print {\n display: inline !important;\n }\n}\n.visible-print-inline-block {\n display: none !important;\n\n @media print {\n display: inline-block !important;\n }\n}\n\n.hidden-print {\n @media print {\n .responsive-invisibility();\n }\n}\n","// Responsive utilities\n\n//\n// More easily include all the states for responsive-utilities.less.\n.responsive-visibility() {\n display: block !important;\n table& { display: table; }\n tr& { display: table-row !important; }\n th&,\n td& { display: table-cell !important; }\n}\n\n.responsive-invisibility() {\n display: none !important;\n}\n"]}\ No newline at end of filediff --git a/app/assets/stylesheets/blazer/daterangepicker-bs3.css b/app/assets/stylesheets/blazer/daterangepicker-bs3.cssnew file mode 100644index 00000000..cf6e5626--- /dev/null+++ b/app/assets/stylesheets/blazer/daterangepicker-bs3.css@@ -0,0 +1,267 @@+/*!+ * Stylesheet for the Date Range Picker, for use with Bootstrap 3.x+ *+ * Copyright 2013 Dan Grossman ( http://www.dangrossman.info )+ * Licensed under the Apache License v2.0+ * http://www.apache.org/licenses/LICENSE-2.0+ *+ * Built for http://www.improvely.com+ */++ .daterangepicker.dropdown-menu {+ max-width: none;+ z-index: 3000;+}++.daterangepicker.opensleft .ranges, .daterangepicker.opensleft .calendar {+ float: left;+ margin: 4px;+}++.daterangepicker.opensright .ranges, .daterangepicker.opensright .calendar {+ float: right;+ margin: 4px;+}++.daterangepicker .ranges {+ width: 160px;+ text-align: left;+}++.daterangepicker .ranges .range_inputs>div {+ float: left;+}++.daterangepicker .ranges .range_inputs>div:nth-child(2) {+ padding-left: 11px;+}++.daterangepicker .calendar {+ display: none;+ max-width: 270px;+}++.daterangepicker.show-calendar .calendar {+ display: block;+}++.daterangepicker .calendar.single .calendar-date {+ border: none;+}++.daterangepicker .calendar th, .daterangepicker .calendar td {+ font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;+ white-space: nowrap;+ text-align: center;+ min-width: 32px;+}++.daterangepicker .daterangepicker_start_input label,+.daterangepicker .daterangepicker_end_input label {+ color: #333;+ display: block;+ font-size: 11px;+ font-weight: normal;+ height: 20px;+ line-height: 20px;+ margin-bottom: 2px;+ text-shadow: #fff 1px 1px 0px;+ text-transform: uppercase;+ width: 74px;+}++.daterangepicker .ranges input {+ font-size: 11px;+}++.daterangepicker .ranges .input-mini {+ background-color: #eee;+ border: 1px solid #ccc;+ border-radius: 4px;+ color: #555;+ display: block;+ font-size: 11px;+ height: 30px;+ line-height: 30px;+ vertical-align: middle;+ margin: 0 0 10px 0;+ padding: 0 6px;+ width: 74px;+}++.daterangepicker .ranges ul {+ list-style: none;+ margin: 0;+ padding: 0;+}++.daterangepicker .ranges li {+ font-size: 13px;+ background: #f5f5f5;+ border: 1px solid #f5f5f5;+ color: #08c;+ padding: 3px 12px;+ margin-bottom: 8px;+ -webkit-border-radius: 5px;+ -moz-border-radius: 5px;+ border-radius: 5px;+ cursor: pointer;+}++.daterangepicker .ranges li.active, .daterangepicker .ranges li:hover {+ background: #08c;+ border: 1px solid #08c;+ color: #fff;+}++.daterangepicker .calendar-date {+ border: 1px solid #ddd;+ padding: 4px;+ border-radius: 4px;+ background: #fff;+}++.daterangepicker .calendar-time {+ text-align: center;+ margin: 8px auto 0 auto;+ line-height: 30px;+}++.daterangepicker {+ position: absolute;+ background: #fff;+ top: 100px;+ left: 20px;+ padding: 4px;+ margin-top: 1px;+ -webkit-border-radius: 4px;+ -moz-border-radius: 4px;+ border-radius: 4px;+}++.daterangepicker.opensleft:before {+ position: absolute;+ top: -7px;+ right: 9px;+ display: inline-block;+ border-right: 7px solid transparent;+ border-bottom: 7px solid #ccc;+ border-left: 7px solid transparent;+ border-bottom-color: rgba(0, 0, 0, 0.2);+ content: '';+}++.daterangepicker.opensleft:after {+ position: absolute;+ top: -6px;+ right: 10px;+ display: inline-block;+ border-right: 6px solid transparent;+ border-bottom: 6px solid #fff;+ border-left: 6px solid transparent;+ content: '';+}++.daterangepicker.opensright:before {+ position: absolute;+ top: -7px;+ left: 9px;+ display: inline-block;+ border-right: 7px solid transparent;+ border-bottom: 7px solid #ccc;+ border-left: 7px solid transparent;+ border-bottom-color: rgba(0, 0, 0, 0.2);+ content: '';+}++.daterangepicker.opensright:after {+ position: absolute;+ top: -6px;+ left: 10px;+ display: inline-block;+ border-right: 6px solid transparent;+ border-bottom: 6px solid #fff;+ border-left: 6px solid transparent;+ content: '';+}++.daterangepicker table {+ width: 100%;+ margin: 0;+}++.daterangepicker td, .daterangepicker th {+ text-align: center;+ width: 20px;+ height: 20px;+ -webkit-border-radius: 4px;+ -moz-border-radius: 4px;+ border-radius: 4px;+ cursor: pointer;+ white-space: nowrap;+}++.daterangepicker td.off {+ color: #999;+}++.daterangepicker td.disabled {+ color: #999;+}++.daterangepicker td.available:hover, .daterangepicker th.available:hover {+ background: #eee;+}++.daterangepicker td.in-range {+ background: #ebf4f8;+ -webkit-border-radius: 0;+ -moz-border-radius: 0;+ border-radius: 0;+}++.daterangepicker td.active, .daterangepicker td.active:hover {+ background-color: #357ebd;+ border-color: #3071a9;+ color: #fff;+}++.daterangepicker td.week, .daterangepicker th.week {+ font-size: 80%;+ color: #ccc;+}++.daterangepicker select.monthselect, .daterangepicker select.yearselect {+ font-size: 12px;+ padding: 1px;+ height: auto;+ margin: 0;+ cursor: default;+}++.daterangepicker select.monthselect {+ margin-right: 2%;+ width: 56%;+}++.daterangepicker select.yearselect {+ width: 40%;+}++.daterangepicker select.hourselect, .daterangepicker select.minuteselect, .daterangepicker select.ampmselect {+ width: 50px;+ margin-bottom: 0;+}++.daterangepicker_start_input {+ float: left;+}++.daterangepicker_end_input {+ float: left;+ padding-left: 11px+}++.daterangepicker th.month {+ width: auto;+}diff --git a/app/assets/stylesheets/blazer/github.css b/app/assets/stylesheets/blazer/github.cssnew file mode 100644index 00000000..988bb922--- /dev/null+++ b/app/assets/stylesheets/blazer/github.css@@ -0,0 +1,126 @@+/*++github.com style (c) Vasily Polovnyov <[email protected]>++*/++.hljs {+ display: block; padding: 0.5em;+ color: #333;+ background: #f8f8f8+}++.hljs-comment,+.hljs-template_comment,+.diff .hljs-header,+.hljs-javadoc {+ color: #998;+ font-style: italic+}++.hljs-keyword,+.css .rule .hljs-keyword,+.hljs-winutils,+.javascript .hljs-title,+.nginx .hljs-title,+.hljs-subst,+.hljs-request,+.hljs-status {+ color: #333;+ font-weight: bold+}++.hljs-number,+.hljs-hexcolor,+.ruby .hljs-constant {+ color: #099;+}++.hljs-string,+.hljs-tag .hljs-value,+.hljs-phpdoc,+.tex .hljs-formula {+ color: #d14+}++.hljs-title,+.hljs-id,+.coffeescript .hljs-params,+.scss .hljs-preprocessor {+ color: #900;+ font-weight: bold+}++.javascript .hljs-title,+.lisp .hljs-title,+.clojure .hljs-title,+.hljs-subst {+ font-weight: normal+}++.hljs-class .hljs-title,+.haskell .hljs-type,+.vhdl .hljs-literal,+.tex .hljs-command {+ color: #458;+ font-weight: bold+}++.hljs-tag,+.hljs-tag .hljs-title,+.hljs-rules .hljs-property,+.django .hljs-tag .hljs-keyword {+ color: #000080;+ font-weight: normal+}++.hljs-attribute,+.lisp .hljs-body {+ color: #008080+}++.hljs-variable,+.hljs-regexp {+ color: #009926;+ font-weight: bold+}++.hljs-symbol,+.ruby .hljs-symbol .hljs-string,+.lisp .hljs-keyword,+.tex .hljs-special,+.hljs-prompt {+ color: #990073+}++.hljs-built_in,+.lisp .hljs-title,+.clojure .hljs-built_in {+ color: #0086b3+}++.hljs-preprocessor,+.hljs-pragma,+.hljs-pi,+.hljs-doctype,+.hljs-shebang,+.hljs-cdata {+ color: #999;+ font-weight: bold+}++.hljs-deletion {+ background: #fdd+}++.hljs-addition {+ background: #dfd+}++.diff .hljs-change {+ background: #0086b3+}++.hljs-chunk {+ color: #aaa+}diff --git a/app/assets/stylesheets/blazer/selectize.default.css b/app/assets/stylesheets/blazer/selectize.default.cssnew file mode 100644index 00000000..06d39647--- /dev/null+++ b/app/assets/stylesheets/blazer/selectize.default.css@@ -0,0 +1,386 @@+/**+ * selectize.default.css (v0.10.1) - Default Theme+ * Copyright (c) 2013 Brian Reavis & contributors+ *+ * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this+ * file except in compliance with the License. You may obtain a copy of the License at:+ * http://www.apache.org/licenses/LICENSE-2.0+ *+ * Unless required by applicable law or agreed to in writing, software distributed under+ * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF+ * ANY KIND, either express or implied. See the License for the specific language+ * governing permissions and limitations under the License.+ *+ * @author Brian Reavis <[email protected]>+ */+.selectize-control.plugin-drag_drop.multi > .selectize-input > div.ui-sortable-placeholder {+ visibility: visible !important;+ background: #f2f2f2 !important;+ background: rgba(0, 0, 0, 0.06) !important;+ border: 0 none !important;+ -webkit-box-shadow: inset 0 0 12px 4px #ffffff;+ box-shadow: inset 0 0 12px 4px #ffffff;+}+.selectize-control.plugin-drag_drop .ui-sortable-placeholder::after {+ content: '!';+ visibility: hidden;+}+.selectize-control.plugin-drag_drop .ui-sortable-helper {+ -webkit-box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);+ box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);+}+.selectize-dropdown-header {+ position: relative;+ padding: 5px 8px;+ border-bottom: 1px solid #d0d0d0;+ background: #f8f8f8;+ -webkit-border-radius: 3px 3px 0 0;+ -moz-border-radius: 3px 3px 0 0;+ border-radius: 3px 3px 0 0;+}+.selectize-dropdown-header-close {+ position: absolute;+ right: 8px;+ top: 50%;+ color: #303030;+ opacity: 0.4;+ margin-top: -12px;+ line-height: 20px;+ font-size: 20px !important;+}+.selectize-dropdown-header-close:hover {+ color: #000000;+}+.selectize-dropdown.plugin-optgroup_columns .optgroup {+ border-right: 1px solid #f2f2f2;+ border-top: 0 none;+ float: left;+ -webkit-box-sizing: border-box;+ -moz-box-sizing: border-box;+ box-sizing: border-box;+}+.selectize-dropdown.plugin-optgroup_columns .optgroup:last-child {+ border-right: 0 none;+}+.selectize-dropdown.plugin-optgroup_columns .optgroup:before {+ display: none;+}+.selectize-dropdown.plugin-optgroup_columns .optgroup-header {+ border-top: 0 none;+}+.selectize-control.plugin-remove_button [data-value] {+ position: relative;+ padding-right: 24px !important;+}+.selectize-control.plugin-remove_button [data-value] .remove {+ z-index: 1;+ /* fixes ie bug (see #392) */+ position: absolute;+ top: 0;+ right: 0;+ bottom: 0;+ width: 17px;+ text-align: center;+ font-weight: bold;+ font-size: 12px;+ color: inherit;+ text-decoration: none;+ vertical-align: middle;+ display: inline-block;+ padding: 2px 0 0 0;+ border-left: 1px solid #0073bb;+ -webkit-border-radius: 0 2px 2px 0;+ -moz-border-radius: 0 2px 2px 0;+ border-radius: 0 2px 2px 0;+ -webkit-box-sizing: border-box;+ -moz-box-sizing: border-box;+ box-sizing: border-box;+}+.selectize-control.plugin-remove_button [data-value] .remove:hover {+ background: rgba(0, 0, 0, 0.05);+}+.selectize-control.plugin-remove_button [data-value].active .remove {+ border-left-color: #00578d;+}+.selectize-control.plugin-remove_button .disabled [data-value] .remove:hover {+ background: none;+}+.selectize-control.plugin-remove_button .disabled [data-value] .remove {+ border-left-color: #aaaaaa;+}+.selectize-control {+ position: relative;+}+.selectize-dropdown,+.selectize-input,+.selectize-input input {+ color: #303030;+ font-family: inherit;+ font-size: 13px;+ line-height: 18px;+ -webkit-font-smoothing: inherit;+}+.selectize-input,+.selectize-control.single .selectize-input.input-active {+ background: #ffffff;+ cursor: text;+ display: inline-block;+}+.selectize-input {+ border: 1px solid #d0d0d0;+ padding: 8px 8px;+ display: inline-block;+ width: 100%;+ overflow: hidden;+ position: relative;+ z-index: 1;+ -webkit-box-sizing: border-box;+ -moz-box-sizing: border-box;+ box-sizing: border-box;+ -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.1);+ box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.1);+ -webkit-border-radius: 3px;+ -moz-border-radius: 3px;+ border-radius: 3px;+}+.selectize-control.multi .selectize-input.has-items {+ padding: 5px 8px 2px;+}+.selectize-input.full {+ background-color: #ffffff;+}+.selectize-input.disabled,+.selectize-input.disabled * {+ cursor: default !important;+}+.selectize-input.focus {+ -webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.15);+ box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.15);+}+.selectize-input.dropdown-active {+ -webkit-border-radius: 3px 3px 0 0;+ -moz-border-radius: 3px 3px 0 0;+ border-radius: 3px 3px 0 0;+}+.selectize-input > * {+ vertical-align: baseline;+ display: -moz-inline-stack;+ display: inline-block;+ zoom: 1;+ *display: inline;+}+.selectize-control.multi .selectize-input > div {+ cursor: pointer;+ margin: 0 3px 3px 0;+ padding: 2px 6px;+ background: #1da7ee;+ color: #ffffff;+ border: 1px solid #0073bb;+}+.selectize-control.multi .selectize-input > div.active {+ background: #92c836;+ color: #ffffff;+ border: 1px solid #00578d;+}+.selectize-control.multi .selectize-input.disabled > div,+.selectize-control.multi .selectize-input.disabled > div.active {+ color: #ffffff;+ background: #d2d2d2;+ border: 1px solid #aaaaaa;+}+.selectize-input > input {+ padding: 0 !important;+ min-height: 0 !important;+ max-height: none !important;+ max-width: 100% !important;+ margin: 0 1px !important;+ text-indent: 0 !important;+ border: 0 none !important;+ background: none !important;+ line-height: inherit !important;+ -webkit-user-select: auto !important;+ -webkit-box-shadow: none !important;+ box-shadow: none !important;+}+.selectize-input > input::-ms-clear {+ display: none;+}+.selectize-input > input:focus {+ outline: none !important;+}+.selectize-input::after {+ content: ' ';+ display: block;+ clear: left;+}+.selectize-input.dropdown-active::before {+ content: ' ';+ display: block;+ position: absolute;+ background: #f0f0f0;+ height: 1px;+ bottom: 0;+ left: 0;+ right: 0;+}+.selectize-dropdown {+ position: absolute;+ z-index: 10;+ border: 1px solid #d0d0d0;+ background: #ffffff;+ margin: -1px 0 0 0;+ border-top: 0 none;+ -webkit-box-sizing: border-box;+ -moz-box-sizing: border-box;+ box-sizing: border-box;+ -webkit-box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);+ box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);+ -webkit-border-radius: 0 0 3px 3px;+ -moz-border-radius: 0 0 3px 3px;+ border-radius: 0 0 3px 3px;+}+.selectize-dropdown [data-selectable] {+ cursor: pointer;+ overflow: hidden;+}+.selectize-dropdown [data-selectable] .highlight {+ background: rgba(125, 168, 208, 0.2);+ -webkit-border-radius: 1px;+ -moz-border-radius: 1px;+ border-radius: 1px;+}+.selectize-dropdown [data-selectable],+.selectize-dropdown .optgroup-header {+ padding: 5px 8px;+}+.selectize-dropdown .optgroup:first-child .optgroup-header {+ border-top: 0 none;+}+.selectize-dropdown .optgroup-header {+ color: #303030;+ background: #ffffff;+ cursor: default;+}+.selectize-dropdown .active {+ background-color: #f5fafd;+ color: #495c68;+}+.selectize-dropdown .active.create {+ color: #495c68;+}+.selectize-dropdown .create {+ color: rgba(48, 48, 48, 0.5);+}+.selectize-dropdown-content {+ overflow-y: auto;+ overflow-x: hidden;+ max-height: 200px;+}+.selectize-control.single .selectize-input,+.selectize-control.single .selectize-input input {+ cursor: pointer;+}+.selectize-control.single .selectize-input.input-active,+.selectize-control.single .selectize-input.input-active input {+ cursor: text;+}+.selectize-control.single .selectize-input:after {+ content: ' ';+ display: block;+ position: absolute;+ top: 50%;+ right: 15px;+ margin-top: -3px;+ width: 0;+ height: 0;+ border-style: solid;+ border-width: 5px 5px 0 5px;+ border-color: #808080 transparent transparent transparent;+}+.selectize-control.single .selectize-input.dropdown-active:after {+ margin-top: -4px;+ border-width: 0 5px 5px 5px;+ border-color: transparent transparent #808080 transparent;+}+.selectize-control.rtl.single .selectize-input:after {+ left: 15px;+ right: auto;+}+.selectize-control.rtl .selectize-input > input {+ margin: 0 4px 0 -2px !important;+}+.selectize-control .selectize-input.disabled {+ opacity: 0.5;+ background-color: #fafafa;+}+.selectize-control.multi .selectize-input.has-items {+ padding-left: 5px;+ padding-right: 5px;+}+.selectize-control.multi .selectize-input.disabled [data-value] {+ color: #999;+ text-shadow: none;+ background: none;+ -webkit-box-shadow: none;+ box-shadow: none;+}+.selectize-control.multi .selectize-input.disabled [data-value],+.selectize-control.multi .selectize-input.disabled [data-value] .remove {+ border-color: #e6e6e6;+}+.selectize-control.multi .selectize-input.disabled [data-value] .remove {+ background: none;+}+.selectize-control.multi .selectize-input [data-value] {+ text-shadow: 0 1px 0 rgba(0, 51, 83, 0.3);+ -webkit-border-radius: 3px;+ -moz-border-radius: 3px;+ border-radius: 3px;+ background-color: #1b9dec;+ background-image: -moz-linear-gradient(top, #1da7ee, #178ee9);+ background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#1da7ee), to(#178ee9));+ background-image: -webkit-linear-gradient(top, #1da7ee, #178ee9);+ background-image: -o-linear-gradient(top, #1da7ee, #178ee9);+ background-image: linear-gradient(to bottom, #1da7ee, #178ee9);+ background-repeat: repeat-x;+ filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff1da7ee', endColorstr='#ff178ee9', GradientType=0);+ -webkit-box-shadow: 0 1px 0 rgba(0,0,0,0.2),inset 0 1px rgba(255,255,255,0.03);+ box-shadow: 0 1px 0 rgba(0,0,0,0.2),inset 0 1px rgba(255,255,255,0.03);+}+.selectize-control.multi .selectize-input [data-value].active {+ background-color: #0085d4;+ background-image: -moz-linear-gradient(top, #008fd8, #0075cf);+ background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#008fd8), to(#0075cf));+ background-image: -webkit-linear-gradient(top, #008fd8, #0075cf);+ background-image: -o-linear-gradient(top, #008fd8, #0075cf);+ background-image: linear-gradient(to bottom, #008fd8, #0075cf);+ background-repeat: repeat-x;+ filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff008fd8', endColorstr='#ff0075cf', GradientType=0);+}+.selectize-control.single .selectize-input {+ -webkit-box-shadow: 0 1px 0 rgba(0,0,0,0.05), inset 0 1px 0 rgba(255,255,255,0.8);+ box-shadow: 0 1px 0 rgba(0,0,0,0.05), inset 0 1px 0 rgba(255,255,255,0.8);+ background-color: #f9f9f9;+ background-image: -moz-linear-gradient(top, #fefefe, #f2f2f2);+ background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#fefefe), to(#f2f2f2));+ background-image: -webkit-linear-gradient(top, #fefefe, #f2f2f2);+ background-image: -o-linear-gradient(top, #fefefe, #f2f2f2);+ background-image: linear-gradient(to bottom, #fefefe, #f2f2f2);+ background-repeat: repeat-x;+ filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffefefe', endColorstr='#fff2f2f2', GradientType=0);+}+.selectize-control.single .selectize-input,+.selectize-dropdown.single {+ border-color: #b8b8b8;+}+.selectize-dropdown .optgroup-header {+ padding-top: 7px;+ font-weight: bold;+ font-size: 0.85em;+}+.selectize-dropdown .optgroup {+ border-top: 1px solid #f0f0f0;+}+.selectize-dropdown .optgroup:first-child {+ border-top: 0 none;+}diff --git a/app/controllers/blazer/queries_controller.rb b/app/controllers/blazer/queries_controller.rbnew file mode 100644index 00000000..63f504b3--- /dev/null+++ b/app/controllers/blazer/queries_controller.rb@@ -0,0 +1,216 @@+module Blazer+ class QueriesController < ApplicationController+ # skip all filters+ skip_filter *_process_action_callbacks.map(&:filter)++ protect_from_forgery with: :exception++ if ENV["BLAZER_PASSWORD"]+ http_basic_authenticate_with name: ENV["BLAZER_USERNAME"], password: ENV["BLAZER_PASSWORD"]+ end++ layout "blazer/application"++ before_action :ensure_database_url+ before_action :set_query, only: [:show, :edit, :update, :destroy]++ def index+ @queries = Blazer::Query.order(:name)+ end++ def new+ @query = Blazer::Query.new(statement: params[:statement])+ end++ def create+ @query = Blazer::Query.new(query_params)+ @query.creator = current_user if respond_to?(:current_user)++ if @query.save+ redirect_to @query+ else+ render :new+ end+ end++ def show+ @statement = @query.statement+ process_vars(@statement)++ @smart_vars = {}+ @sql_errors = []+ @bind_vars.each do |var|+ query = smart_variables[var]+ if query+ rows, error = run_statement(query)+ @smart_vars[var] = rows.map{|v| v.values.reverse }+ @sql_errors << error if error+ end+ end+ end++ def edit+ end++ def run+ @statement = params[:statement]+ process_vars(@statement)++ if @success+ # audit+ if Blazer.audit+ audit = Blazer::Audit.new(statement: @statement)+ audit.user = current_user if respond_to?(:current_user)+ audit.save!+ end++ @rows, @error = run_statement(@statement)++ @columns = {}+ if @rows.any?+ @rows.first.each do |key, value|+ @columns[key] =+ case value+ when Integer+ "int"+ when Float+ "float"+ else+ "string-ins"+ end+ end+ end++ @query = Query.find_by(id: params[:query_id]) if params[:query_id]+ @filename = @query.name.parameterize if @query++ @min_width_types = (@rows.first || {}).select{|k, v| v.is_a?(Time) or v.is_a?(String) or smart_columns[k] }.keys++ @boom = {}+ @columns.keys.each do |key|+ query = smart_columns[key]+ if query+ values = @rows.map{|r| r[key] }.compact.uniq+ rows, error = run_statement(ActiveRecord::Base.send(:sanitize_sql_array, [query.sub("{value}", "(?)"), values]))+ @boom[key] = Hash[ rows.map(&:values) ]+ end+ end++ @linked_columns = linked_columns+ end++ respond_to do |format|+ format.html do+ render layout: false+ end+ format.csv do+ send_data csv_data(@rows), type: 'text/csv; charset=utf-8; header=present', disposition: "attachment; filename=\"#{@query ? @query.name.parameterize : "query"}.csv\""+ end+ end+ end++ def update+ if @query.update(query_params)+ redirect_to query_path(@query)+ else+ render :edit+ end+ end++ def destroy+ @query.destroy+ redirect_to root_url+ end++ private++ def ensure_database_url+ render text: "BLAZER_DATABASE_URL required" if !ENV["BLAZER_DATABASE_URL"]+ end++ def set_query+ @query = Blazer::Query.find(params[:id].to_s.split("-").first)+ end++ def query_params+ params.require(:query).permit(:name, :description, :statement)+ end++ def csv_data(rows)+ CSV.generate do |csv|+ if rows.any?+ csv << rows.first.keys+ end+ rows.each do |row|+ csv << row.values+ end+ end+ end++ def run_statement(statement)+ rows = []+ error = nil+ begin+ Blazer::Connection.transaction do+ result = Blazer::Connection.connection.select_all(statement)+ result.each do |untyped_row|+ row = {}+ untyped_row.each do |k, v|+ row[k] = result.column_types[k].type_cast(v)+ end+ rows << row+ end+ raise ActiveRecord::Rollback+ end+ rescue ActiveRecord::StatementInvalid => e+ error = e.message.sub(/.+ERROR: /, "")+ end+ [rows, error]+ end++ def extract_vars(statement)+ statement.scan(/\{.*?\}/).map{|v| v[1...-1] }.uniq+ end++ def process_vars(statement)+ @bind_vars = extract_vars(statement)+ @success = @bind_vars.all?{|v| params[v] }++ if @success+ @bind_vars.each do |var|+ value = params[var].presence+ value = value.to_i if value.to_i.to_s == value+ if var.end_with?("_at")+ value = Blazer.time_zone.parse(value) rescue nil+ end+ statement.gsub!("{#{var}}", ActiveRecord::Base.connection.quote(value))+ end+ end+ end++ def settings+ YAML.load(File.read(Rails.root.join("config", "blazer.yml")))+ end++ def linked_columns+ settings["linked_columns"] || {}+ end++ def smart_columns+ settings["smart_columns"] || {}+ end++ def smart_variables+ settings["smart_variables"] || {}+ end++ def tables+ default_schema = Blazer::Connection.connection.adapter_name == "PostgreSQL" ? "public" : Blazer::Connection.connection_config[:database]+ schema = Blazer::Connection.connection_config[:schema] || default_schema+ rows, error = run_statement(Blazer::Connection.send(:sanitize_sql_array, ["SELECT table_name, column_name, ordinal_position, data_type FROM information_schema.columns WHERE table_schema = ?", schema]))+ Hash[ rows.group_by{|r| r["table_name"] }.map{|t, f| [t, f.sort_by{|f| f["ordinal_position"] }.map{|f| f.slice("column_name", "data_type") }] }.sort_by{|t, f| t } ]+ end+ helper_method :tables++ end+enddiff --git a/app/helpers/blazer/queries_helper.rb b/app/helpers/blazer/queries_helper.rbnew file mode 100644index 00000000..101cc5cd--- /dev/null+++ b/app/helpers/blazer/queries_helper.rb@@ -0,0 +1,21 @@+module Blazer+ module QueriesHelper++ def title(title = nil)+ if title+ content_for(:title) { title }+ else+ content_for?(:title) ? content_for(:title) : nil+ end+ end++ def format_value(key, value)+ if value.is_a?(Integer) and !key.to_s.end_with?("id")+ number_with_delimiter(value)+ else+ value+ end+ end++ end+enddiff --git a/app/models/blazer/audit.rb b/app/models/blazer/audit.rbnew file mode 100644index 00000000..432f61ec--- /dev/null+++ b/app/models/blazer/audit.rb@@ -0,0 +1,5 @@+module Blazer+ class Audit < ActiveRecord::Base++ end+enddiff --git a/app/models/blazer/connection.rb b/app/models/blazer/connection.rbnew file mode 100644index 00000000..d7086694--- /dev/null+++ b/app/models/blazer/connection.rb@@ -0,0 +1,5 @@+module Blazer+ class Connection < ActiveRecord::Base+ establish_connection ENV["BLAZER_DATABASE_URL"] if ENV["BLAZER_DATABASE_URL"]+ end+enddiff --git a/app/models/blazer/query.rb b/app/models/blazer/query.rbnew file mode 100644index 00000000..ac1c8975--- /dev/null+++ b/app/models/blazer/query.rb@@ -0,0 +1,13 @@+module Blazer+ class Query < ActiveRecord::Base+ belongs_to :creator, class_name: "User"++ validates :name, presence: true+ validates :statement, presence: true++ def to_param+ [id, name.remove("'").parameterize].join("-")+ end++ end+enddiff --git a/app/views/blazer/queries/_form.html.erb b/app/views/blazer/queries/_form.html.erbnew file mode 100644index 00000000..28dc311d--- /dev/null+++ b/app/views/blazer/queries/_form.html.erb@@ -0,0 +1,84 @@+<% if @query.errors.any? %>+ <div class="alert alert-danger"><%= @query.errors.full_messages.first %></div>+<% end %>++<%= form_for @query, html: {class: "the_form", autocomplete: "off"} do |f| %>+ <div class="row">+ <div class="col-xs-8">+ <div class= "form-group">+ <%= f.hidden_field :statement %>+ <div id="editor-container">+ <div id="editor"><%= @query.statement %></div>+ </div>+ </div>+ <div class="form-group text-right">+ <div class="pull-left" style="margin-top: 6px;">+ <%= link_to "Back", :back %>+ <span class="text-muted" style="margin-left: 20px;"> Use {start_time} and {end_time} for time ranges</span>+ </div>+ <%= select_tag :table_names, options_for_select([["Preview table", nil]] + tables.keys), style: "margin-right: 20px; width: 240px;" %>+ <%= link_to "Run", "#", class: "btn btn-info", id: "run", style: "vertical-align: top;" %>+ </div>+ </div>+ <div class="col-xs-4">+ <div class="form-group">+ <%= f.text_field :name, placeholder: "Name", class: "form-control" %>+ </div>+ <div class="form-group">+ <%= f.text_area :description, placeholder: "Optional description", style: "height: 70px;", class: "form-control" %>+ </div>+ <div class="text-right">+ <% if @query.persisted? %>+ <%= link_to "Delete", query_path(@query), method: :delete, "data-confirm" => "Are you sure?", class: "btn btn-danger" %>+ <% end %>+ <%= f.submit "Save", class: "btn btn-success" %>+ </div>+ </div>+ </div>+<% end %>++<div id="results"></div>++<script>+ var editor = ace.edit("editor");+ editor.setTheme("ace/theme/twilight");+ editor.getSession().setMode("ace/mode/sql");+ editor.setOptions({+ enableBasicAutocompletion: false,+ enableSnippets: false,+ enableLiveAutocompletion: false,+ highlightActiveLine: false,+ fontSize: 12+ });+ editor.renderer.setShowGutter(false);+ editor.renderer.setPrintMarginColumn(false);+ editor.renderer.setPadding(10);+ editor.getSession().setUseWrapMode(true);+ $("#editor").show();++ $("#run").click( function (e) {+ e.preventDefault();+ $("#results").html('<p class="text-muted">Loading...</p>');+ $.post("<%= run_queries_path %>", {statement: editor.getValue()}, function (data) {+ $("#results").html(data);+ });+ });++ if ($("#query_statement").val() != "") {+ $("#run").click();+ }++ $("#table_names").selectize({+ }).change( function () {+ var val = $(this).val();+ if (val.length > 0) {+ editor.setValue("SELECT * FROM " + val + " LIMIT 10");+ $("#run").click();+ }+ });++ $("form.the_form").on("submit", function() {+ $("#query_statement").val(editor.getValue());+ return true;+ });+</script>diff --git a/app/views/blazer/queries/edit.html.erb b/app/views/blazer/queries/edit.html.erbnew file mode 100644index 00000000..d44c608b--- /dev/null+++ b/app/views/blazer/queries/edit.html.erb@@ -0,0 +1 @@+<%= render partial: "form" %>diff --git a/app/views/blazer/queries/index.html.erb b/app/views/blazer/queries/index.html.erbnew file mode 100644index 00000000..e810d6ea--- /dev/null+++ b/app/views/blazer/queries/index.html.erb@@ -0,0 +1,47 @@+<div id="queries">+ <div id="header" style="margin-bottom: 20px;">+ <div class="pull-right">+ <%= link_to "New Query", new_query_path, class: "btn btn-info" %>+ </div>+ <input type="text" placeholder="Start typing a query or person" style="width: 300px; display: inline-block;" autofocus=true class="search form-control" />+ </div>++ <table class="table">+ <thead>+ <tr>+ <th>Query</th>+ <th style="width: 20%; text-align: right;">Mastermind</th>+ </tr>+ </thead>+ <tbody class="list">+ <% @queries.each do |query| %>+ <tr>+ <td class="query">+ <%= link_to query.name, query %>+ <% if query.created_at > 2.days.ago %>+ <small style="font-weight: bold; color: #5cb85c;">NEW</small>+ <% end %>+ </td>+ <td class="creator text-right text-muted">+ <% if (creator = query.creator) and creator.respond_to?(:name) %>+ <% name = creator.name %>+ <% if respond_to?(:current_user) and creator == current_user %>+ you+ <div class="hide">me <%= name %></div>+ <% else %>+ <%= name %>+ <% end %>+ <% end %>+ </td>+ </tr>+ <% end %>+ </tbody>+ </table>+</div>++<script>+ var options = {+ valueNames: ['query', 'creator']+ };+ var userList = new List('queries', options);+</script>diff --git a/app/views/blazer/queries/new.html.erb b/app/views/blazer/queries/new.html.erbnew file mode 100644index 00000000..d44c608b--- /dev/null+++ b/app/views/blazer/queries/new.html.erb@@ -0,0 +1 @@+<%= render partial: "form" %>diff --git a/app/views/blazer/queries/run.html.erb b/app/views/blazer/queries/run.html.erbnew file mode 100644index 00000000..639cacaf--- /dev/null+++ b/app/views/blazer/queries/run.html.erb@@ -0,0 +1,50 @@+<% if @error %>+ <div class="alert alert-danger"><%= @error %></div>+<% elsif !@success %>+ <div class="alert alert-info">Can’t run queries with variables yet</div>+<% else %>+ <p class="text-muted"><%= pluralize(@rows.size, "row") %></p>+ <% if @rows.any? %>+ <% header_width = 100 / @rows.first.keys.size.to_f %>+ <table class="table">+ <thead>+ <tr>+ <% @columns.each do |key, type| %>+ <th style="width: <%= header_width %>%;" data-sort="<%= type %>">+ <div style="min-width: <%= @min_width_types.include?(key) ? 180 : 60 %>px;">+ <%= key %>+ </div>+ </th>+ <% end %>+ </tr>+ </thead>+ <tbody>+ <% @rows.each do |row| %>+ <tr>+ <% row.each do |k, v| %>+ <td>+ <% if v.is_a?(Time) %>+ <% v = v.in_time_zone(Blazer.time_zone) %>+ <% end %>++ <% unless v.nil? %>+ <% if v == "" %>+ <div class="text-muted">empty string</div>+ <% elsif @linked_columns[k] %>+ <%= link_to format_value(k, v), @linked_columns[k].gsub("{value}", u(v.to_s)), target: "_blank" %>+ <% else %>+ <%= format_value(k, v) %>+ <% end %>++ <% if v2 = (@boom[k] || {})[v] %>+ <div class="text-muted"><%= v2 %></div>+ <% end %>+ <% end %>+ </td>+ <% end %>+ </tr>+ <% end %>+ </tbody>+ </table>+ <% end %>+<% end %>diff --git a/app/views/blazer/queries/show.html.erb b/app/views/blazer/queries/show.html.erbnew file mode 100644index 00000000..3bc6004a--- /dev/null+++ b/app/views/blazer/queries/show.html.erb@@ -0,0 +1,138 @@+<% title @query.name %>++<div style="position: fixed; top: 0; left: 0; right: 0; background-color: whitesmoke; height: 60px; z-index: 1001;">+ <div class="container">+ <div class="row" style="padding-top: 13px;">+ <div class="col-sm-9">+ <h3 style="margin: 0; line-height: 34px;">+ <%= @query.name %>+ </h3>+ </div>+ <div class="col-sm-3 text-right">+ <%= link_to "Home", root_path, class: "btn btn-primary" %>+ <%= link_to "Edit", edit_query_path(@query), class: "btn btn-default" %>++ <% if !@error and @success %>+ <%= button_to "Download", run_queries_path(statement: @query.statement, query_id: @query.id, format: "csv"), class: "btn btn-info" %>+ <% end %>+ </div>+ </div>+ </div>+</div>++<div style="margin-bottom: 60px;"></div>++<% if @sql_errors.any? %>+ <div class="alert alert-danger">+ <ul>+ <% @sql_errors.each do |message| %>+ <li><%= message %></li>+ <% end %>+ </ul>+ </div>+<% end %>++<% if @query.description.present? %>+ <p><%= @query.description %></p>+<% end %>++<% if @bind_vars.any? %>+ <form id="bind" method="get" action="<%= url_for(params) %>" class="form-inline" style="margin-bottom: 10px;">+ <% date_vars = ["start_time", "end_time"] %>+ <% if (date_vars - @bind_vars).empty? %>+ <% @bind_vars = @bind_vars - date_vars %>+ <% else %>+ <% date_vars = nil %>+ <% end %>++ <% @bind_vars.each_with_index do |var, i| %>+ <%= label_tag var, var %>+ <% if (data = @smart_vars[var]) %>+ <%= select_tag var, options_for_select([[nil, nil]] + data, selected: params[var]), style: "margin-right: 20px; width: 200px;" %>+ <script>+ $("#<%= var %>").selectize({+ create: true+ });+ </script>+ <% else %>+ <%= text_field_tag var, params[var], style: "width: 120px; margin-right: 20px;", autofocus: i == 0 && !var.end_with?("_at") && !params[var], class: "form-control" %>+ <% if var.end_with?("_at") %>+ <script>+ $("#<%= var %>").datepicker({format: "yyyy-mm-dd", autoclose: true, todayBtn: "linked"})+ </script>+ <% end %>+ <% end %>+ <% end %>++ <% if date_vars %>+ <% date_vars.each do |var| %>+ <%= hidden_field_tag var, params[var] %>+ <% end %>++ <%= label_tag nil, date_vars.join(" & ") %>+ <div class="selectize-control single" style="width: 300px;">+ <div id="reportrange" class="selectize-input" style="display: inline-block;">+ <span>Select a time range</span>+ </div>+ </div>++ <script>+ $('#reportrange').daterangepicker(+ {+ ranges: {+ 'Today': [moment(), moment()],+ 'Last 7 Days': [moment().subtract('days', 6), moment()],+ 'Last 30 Days': [moment().subtract('days', 29), moment()]+ },+ startDate: moment().subtract('days', 29),+ endDate: moment(),+ opens: "left"+ },+ function(start, end) {+ $("#start_time").val(start.toISOString());+ $("#end_time").val(end.endOf("day").toISOString());+ $("#start_time").closest("form").submit();+ }+ ).on('apply.daterangepicker', function(ev, picker) {+ $("#start_time").val(picker.startDate.toISOString());+ $("#end_time").val(picker.endDate.endOf("day").toISOString());+ $('#reportrange span').html(picker.startDate.format('MMMM D, YYYY') + ' - ' + picker.endDate.format('MMMM D, YYYY'));+ })++ if ($("#start_time").val().length > 0) {+ var picker = $("#reportrange").data('daterangepicker');+ picker.setStartDate(moment($("#start_time").val()));+ picker.setEndDate(moment($("#end_time").val()));+ $("#reportrange").trigger('apply.daterangepicker', picker)+ }+ </script>+ <% end %>++ <input type="submit" class="btn btn-success" value="Run" style="vertical-align: top;" />+ </form>+<% end %>++<pre><code><%= @query.statement %></code></pre>++<% if @success %>+ <div id="results">+ <p class="text-muted">Loading...</p>+ </div>++ <script>+ $.post("<%= run_queries_path %>", <%= json_escape({statement: @query.statement, query_id: @query.id}.to_json).html_safe %>, function (data) {+ $("#results").html(data);+ $("#results table").stupidtable().stickyTableHeaders({fixedOffset: 60});+ });++ $(".form-inline input, .form-inline select").change( function () {+ if ($(this).val() != "") {+ $(this).closest("form").submit();+ }+ });+ </script>+<% end %>++<script>+ hljs.initHighlightingOnLoad();+</script>diff --git a/app/views/layouts/blazer/application.html.erb b/app/views/layouts/blazer/application.html.erbnew file mode 100644index 00000000..5a7851c4--- /dev/null+++ b/app/views/layouts/blazer/application.html.erb@@ -0,0 +1,17 @@+<!DOCTYPE html>+<html>+ <head>+ <title><%= title ? title : "Blazer" %></title>++ <meta charset="utf-8" />++ <%= stylesheet_link_tag "blazer/application" %>+ <%= javascript_include_tag "blazer/application" %>+ <%= csrf_meta_tags %>+ </head>+ <body>+ <div class="container">+ <%= yield %>+ </div>+ </body>+</html>diff --git a/blazer.gemspec b/blazer.gemspecnew file mode 100644index 00000000..f394f027--- /dev/null+++ b/blazer.gemspec@@ -0,0 +1,25 @@+# coding: utf-8+lib = File.expand_path('../lib', __FILE__)+$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)+require 'blazer/version'++Gem::Specification.new do |spec|+ spec.name = "blazer"+ spec.version = Blazer::VERSION+ spec.authors = ["Andrew Kane"]+ spec.email = ["[email protected]"]+ spec.summary = %q{Create and share SQL queries instantly}+ spec.description = %q{Create and share SQL queries instantly}+ spec.homepage = "https://github.com/ankane/blazer"+ spec.license = "MIT"++ spec.files = `git ls-files -z`.split("\x0")+ spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }+ spec.test_files = spec.files.grep(%r{^(test|spec|features)/})+ spec.require_paths = ["lib"]++ spec.add_dependency "rails"++ spec.add_development_dependency "bundler", "~> 1.7"+ spec.add_development_dependency "rake", "~> 10.0"+enddiff --git a/config/routes.rb b/config/routes.rbnew file mode 100644index 00000000..3669441c--- /dev/null+++ b/config/routes.rb@@ -0,0 +1,6 @@+Blazer::Engine.routes.draw do+ resources :queries, except: [:index] do+ post :run, on: :collection # err on the side of caution+ end+ root to: "queries#index"+enddiff --git a/lib/blazer.rb b/lib/blazer.rbnew file mode 100644index 00000000..1b4aca1e--- /dev/null+++ b/lib/blazer.rb@@ -0,0 +1,16 @@+require "csv"+require "blazer/version"+require "blazer/engine"++module Blazer+ class << self+ attr_accessor :audit+ attr_reader :time_zone+ end+ self.audit = true++ def self.time_zone=(time_zone)+ @time_zone = time_zone.is_a?(ActiveSupport::TimeZone) ? time_zone : ActiveSupport::TimeZone[time_zone.to_s]+ end+ self.time_zone = Time.zone+enddiff --git a/lib/blazer/engine.rb b/lib/blazer/engine.rbnew file mode 100644index 00000000..81f2249f--- /dev/null+++ b/lib/blazer/engine.rb@@ -0,0 +1,11 @@+module Blazer+ class Engine < ::Rails::Engine+ isolate_namespace Blazer++ initializer "precompile" do |app|+ # use a proc instead of a string+ app.config.assets.precompile << Proc.new{|path| path =~ /\Ablazer\/application\.(js|css)\z/ }+ end++ end+enddiff --git a/lib/blazer/version.rb b/lib/blazer/version.rbnew file mode 100644index 00000000..19fafcdf--- /dev/null+++ b/lib/blazer/version.rb@@ -0,0 +1,3 @@+module Blazer+ VERSION = "0.0.1"+enddiff --git a/lib/generators/blazer/install_generator.rb b/lib/generators/blazer/install_generator.rbnew file mode 100644index 00000000..2b0fae59--- /dev/null+++ b/lib/generators/blazer/install_generator.rb@@ -0,0 +1,33 @@+# taken from https://github.com/collectiveidea/audited/blob/master/lib/generators/audited/install_generator.rb+require "rails/generators"+require "rails/generators/migration"+require "active_record"+require "rails/generators/active_record"++module Blazer+ module Generators+ class InstallGenerator < Rails::Generators::Base+ include Rails::Generators::Migration++ source_root File.expand_path("../templates", __FILE__)++ # Implement the required interface for Rails::Generators::Migration.+ def self.next_migration_number(dirname) #:nodoc:+ next_migration_number = current_migration_number(dirname) + 1+ if ActiveRecord::Base.timestamped_migrations+ [Time.now.utc.strftime("%Y%m%d%H%M%S"), "%.14d" % next_migration_number].max+ else+ "%.3d" % next_migration_number+ end+ end++ def copy_migration+ migration_template "install.rb", "db/migrate/install_blazer.rb"+ end++ def copy_config+ template "config.yml", "config/blazer.yml"+ end+ end+ end+enddiff --git a/lib/generators/blazer/templates/config.yml b/lib/generators/blazer/templates/config.ymlnew file mode 100644index 00000000..b89bf535--- /dev/null+++ b/lib/generators/blazer/templates/config.yml@@ -0,0 +1,8 @@+linked_columns:+ # user_id: "/admin/users/{value}"++smart_columns:+ # user_id: "SELECT id, name FROM users WHERE id IN {value}"++smart_variables:+ # zone_id: "SELECT id, name FROM zones ORDER BY name ASC"diff --git a/lib/generators/blazer/templates/install.rb b/lib/generators/blazer/templates/install.rbnew file mode 100644index 00000000..cd90e93a--- /dev/null+++ b/lib/generators/blazer/templates/install.rb@@ -0,0 +1,17 @@+class <%= migration_class_name %> < ActiveRecord::Migration+ def change+ create_table :blazer_queries do |t|+ t.references :creator+ t.string :name+ t.text :description+ t.text :statement+ t.timestamps+ end++ create_table :blazer_audits do |t|+ t.references :user+ t.text :statement+ t.timestamp :created_at+ end+ end+end