target
stringlengths
5
300
feat_repo_name
stringlengths
6
76
text
stringlengths
26
1.05M
src/Components/ListTodo.js
jeanbauer/react-todo-playground-es6-hr-sass
import React from 'react'; import Todo from './Todo.js'; const ListTodo = (props) => ( <div className="group"> {props.data.length ? props.data.map((e,key) => <Todo key={key} time={e.time} description={e.description} />) : 0} </div> ); export default ListTodo;
websrc/components/dashboard/DashboardConfigTab.js
Ricky-Nz/react-relay-example
import React from 'react'; import Relay from 'react-relay'; import { Row, Col, Button, Input } from 'react-bootstrap'; import { LabelEditor, ProgressIndicator } from '../'; import { UpdateAppMutation } from '../../mutations'; class DashboardConfigTab extends React.Component { constructor(props) { super(props); this.state = this.onPropsChange(props); } componentWillReceiveProps(nextProps) { this.setState(this.onPropsChange(nextProps)); } render() { const { bannerCount, categories, labels, projectTypes } = this.state; return ( <Row> <Col xs={5} xsOffset={1} sm={3} smOffset={3}> <Input type='number' label='Home Banner Slot Count' value={bannerCount} onChange={e => this.setState({bannerCount: e.target.value})}/> </Col> <Col xs={10} xsOffset={1} sm={6} smOffset={3}> <LabelEditor labels={categories} title='Categories' placeholder='new category' onLabelChange={newValues => this.setState({categories: newValues})}/> <LabelEditor labels={labels} title='Labels' placeholder='new label' onLabelChange={newValues => this.setState({labels: newValues})}/> <LabelEditor labels={projectTypes} title='Project Types' placeholder='new type' onLabelChange={newValues => this.setState({projectTypes: newValues})}/> </Col> <Col xs={8} xsOffset={2} sm={4} smOffset={4}> <br/><br/> <Input ref='password' type='password' label='Submit' placeholder='password' buttonAfter={<Button bsStyle='primary' onClick={this.onSubmit.bind(this)}>Update</Button>}/> <ProgressIndicator ref='alert'/> </Col> </Row> ); } onPropsChange({app}) { return { bannerCount: app.bannerCount, categories: app.categories, labels: app.labels, projectTypes: app.projectTypes }; } onSubmit() { Relay.Store.update(new UpdateAppMutation( Object.assign({}, this.state, { password: this.refs.password.refs.input.value, app: this.props.app, })), { onFailure: this.onMutationFailure.bind(this), onSuccess: this.onMutationSuccess.bind(this) }); this.refs.alert.start(); } onMutationSuccess(response) { this.refs.alert.finish(true); } onMutationFailure(error) { this.refs.alert.finish(false); } } export default Relay.createContainer(DashboardConfigTab, { fragments: { app: () => Relay.QL` fragment on App { bannerCount, categories, labels, projectTypes, ${UpdateAppMutation.getFragment('app')} } ` } });
client/src/StudentsPhase.story.js
mit-teaching-systems-lab/swipe-right-for-cs
import React from 'react'; import { storiesOf } from '@storybook/react'; import { action } from '@storybook/addon-actions'; import {withFrameSwitcher} from './util/storybookFrames.js'; import {storybookStudents} from './util/fixtures.js'; import StudentsPhase from './StudentsPhase.js'; storiesOf('StudentsPhase', module) //eslint-disable-line no-undef .add('normal', () => { return withFrameSwitcher( <StudentsPhase students={storybookStudents} allowSkipAfter={5} onInteraction={(action('onInteraction'))} onDone={action('onDone')} /> ); }) .add('skip', () => { return withFrameSwitcher( <StudentsPhase students={storybookStudents} allowSkipAfter={0} onInteraction={(action('onInteraction'))} onDone={action('onDone')} /> ); }) .add('shouldAskOpenResponse', () => { return withFrameSwitcher( <StudentsPhase students={storybookStudents} allowSkipAfter={5} shouldAskOpenResponse={true} onInteraction={(action('onInteraction'))} onDone={action('onDone')} /> ); });
app/webroot/js/theme/lib/formwizard/js/jquery-1.4.2.min.js
LINUXADDICT/cakecrud
/*! * jQuery JavaScript Library v1.4.2 * http://jquery.com/ * * Copyright 2010, John Resig * Dual licensed under the MIT or GPL Version 2 licenses. * http://jquery.org/license * * Includes Sizzle.js * http://sizzlejs.com/ * Copyright 2010, The Dojo Foundation * Released under the MIT, BSD, and GPL Licenses. * * Date: Sat Feb 13 22:33:48 2010 -0500 */ (function(A,w){function ma(){if(!c.isReady){try{s.documentElement.doScroll("left")}catch(a){setTimeout(ma,1);return}c.ready()}}function Qa(a,b){b.src?c.ajax({url:b.src,async:false,dataType:"script"}):c.globalEval(b.text||b.textContent||b.innerHTML||"");b.parentNode&&b.parentNode.removeChild(b)}function X(a,b,d,f,e,j){var i=a.length;if(typeof b==="object"){for(var o in b)X(a,o,b[o],f,e,d);return a}if(d!==w){f=!j&&f&&c.isFunction(d);for(o=0;o<i;o++)e(a[o],b,f?d.call(a[o],o,e(a[o],b)):d,j);return a}return i? e(a[0],b):w}function J(){return(new Date).getTime()}function Y(){return false}function Z(){return true}function na(a,b,d){d[0].type=a;return c.event.handle.apply(b,d)}function oa(a){var b,d=[],f=[],e=arguments,j,i,o,k,n,r;i=c.data(this,"events");if(!(a.liveFired===this||!i||!i.live||a.button&&a.type==="click")){a.liveFired=this;var u=i.live.slice(0);for(k=0;k<u.length;k++){i=u[k];i.origType.replace(O,"")===a.type?f.push(i.selector):u.splice(k--,1)}j=c(a.target).closest(f,a.currentTarget);n=0;for(r= j.length;n<r;n++)for(k=0;k<u.length;k++){i=u[k];if(j[n].selector===i.selector){o=j[n].elem;f=null;if(i.preType==="mouseenter"||i.preType==="mouseleave")f=c(a.relatedTarget).closest(i.selector)[0];if(!f||f!==o)d.push({elem:o,handleObj:i})}}n=0;for(r=d.length;n<r;n++){j=d[n];a.currentTarget=j.elem;a.data=j.handleObj.data;a.handleObj=j.handleObj;if(j.handleObj.origHandler.apply(j.elem,e)===false){b=false;break}}return b}}function pa(a,b){return"live."+(a&&a!=="*"?a+".":"")+b.replace(/\./g,"`").replace(/ /g, "&")}function qa(a){return!a||!a.parentNode||a.parentNode.nodeType===11}function ra(a,b){var d=0;b.each(function(){if(this.nodeName===(a[d]&&a[d].nodeName)){var f=c.data(a[d++]),e=c.data(this,f);if(f=f&&f.events){delete e.handle;e.events={};for(var j in f)for(var i in f[j])c.event.add(this,j,f[j][i],f[j][i].data)}}})}function sa(a,b,d){var f,e,j;b=b&&b[0]?b[0].ownerDocument||b[0]:s;if(a.length===1&&typeof a[0]==="string"&&a[0].length<512&&b===s&&!ta.test(a[0])&&(c.support.checkClone||!ua.test(a[0]))){e= true;if(j=c.fragments[a[0]])if(j!==1)f=j}if(!f){f=b.createDocumentFragment();c.clean(a,b,f,d)}if(e)c.fragments[a[0]]=j?f:1;return{fragment:f,cacheable:e}}function K(a,b){var d={};c.each(va.concat.apply([],va.slice(0,b)),function(){d[this]=a});return d}function wa(a){return"scrollTo"in a&&a.document?a:a.nodeType===9?a.defaultView||a.parentWindow:false}var c=function(a,b){return new c.fn.init(a,b)},Ra=A.jQuery,Sa=A.$,s=A.document,T,Ta=/^[^<]*(<[\w\W]+>)[^>]*$|^#([\w-]+)$/,Ua=/^.[^:#\[\.,]*$/,Va=/\S/, Wa=/^(\s|\u00A0)+|(\s|\u00A0)+$/g,Xa=/^<(\w+)\s*\/?>(?:<\/\1>)?$/,P=navigator.userAgent,xa=false,Q=[],L,$=Object.prototype.toString,aa=Object.prototype.hasOwnProperty,ba=Array.prototype.push,R=Array.prototype.slice,ya=Array.prototype.indexOf;c.fn=c.prototype={init:function(a,b){var d,f;if(!a)return this;if(a.nodeType){this.context=this[0]=a;this.length=1;return this}if(a==="body"&&!b){this.context=s;this[0]=s.body;this.selector="body";this.length=1;return this}if(typeof a==="string")if((d=Ta.exec(a))&& (d[1]||!b))if(d[1]){f=b?b.ownerDocument||b:s;if(a=Xa.exec(a))if(c.isPlainObject(b)){a=[s.createElement(a[1])];c.fn.attr.call(a,b,true)}else a=[f.createElement(a[1])];else{a=sa([d[1]],[f]);a=(a.cacheable?a.fragment.cloneNode(true):a.fragment).childNodes}return c.merge(this,a)}else{if(b=s.getElementById(d[2])){if(b.id!==d[2])return T.find(a);this.length=1;this[0]=b}this.context=s;this.selector=a;return this}else if(!b&&/^\w+$/.test(a)){this.selector=a;this.context=s;a=s.getElementsByTagName(a);return c.merge(this, a)}else return!b||b.jquery?(b||T).find(a):c(b).find(a);else if(c.isFunction(a))return T.ready(a);if(a.selector!==w){this.selector=a.selector;this.context=a.context}return c.makeArray(a,this)},selector:"",jquery:"1.4.2",length:0,size:function(){return this.length},toArray:function(){return R.call(this,0)},get:function(a){return a==null?this.toArray():a<0?this.slice(a)[0]:this[a]},pushStack:function(a,b,d){var f=c();c.isArray(a)?ba.apply(f,a):c.merge(f,a);f.prevObject=this;f.context=this.context;if(b=== "find")f.selector=this.selector+(this.selector?" ":"")+d;else if(b)f.selector=this.selector+"."+b+"("+d+")";return f},each:function(a,b){return c.each(this,a,b)},ready:function(a){c.bindReady();if(c.isReady)a.call(s,c);else Q&&Q.push(a);return this},eq:function(a){return a===-1?this.slice(a):this.slice(a,+a+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},slice:function(){return this.pushStack(R.apply(this,arguments),"slice",R.call(arguments).join(","))},map:function(a){return this.pushStack(c.map(this, function(b,d){return a.call(b,d,b)}))},end:function(){return this.prevObject||c(null)},push:ba,sort:[].sort,splice:[].splice};c.fn.init.prototype=c.fn;c.extend=c.fn.extend=function(){var a=arguments[0]||{},b=1,d=arguments.length,f=false,e,j,i,o;if(typeof a==="boolean"){f=a;a=arguments[1]||{};b=2}if(typeof a!=="object"&&!c.isFunction(a))a={};if(d===b){a=this;--b}for(;b<d;b++)if((e=arguments[b])!=null)for(j in e){i=a[j];o=e[j];if(a!==o)if(f&&o&&(c.isPlainObject(o)||c.isArray(o))){i=i&&(c.isPlainObject(i)|| c.isArray(i))?i:c.isArray(o)?[]:{};a[j]=c.extend(f,i,o)}else if(o!==w)a[j]=o}return a};c.extend({noConflict:function(a){A.$=Sa;if(a)A.jQuery=Ra;return c},isReady:false,ready:function(){if(!c.isReady){if(!s.body)return setTimeout(c.ready,13);c.isReady=true;if(Q){for(var a,b=0;a=Q[b++];)a.call(s,c);Q=null}c.fn.triggerHandler&&c(s).triggerHandler("ready")}},bindReady:function(){if(!xa){xa=true;if(s.readyState==="complete")return c.ready();if(s.addEventListener){s.addEventListener("DOMContentLoaded", L,false);A.addEventListener("load",c.ready,false)}else if(s.attachEvent){s.attachEvent("onreadystatechange",L);A.attachEvent("onload",c.ready);var a=false;try{a=A.frameElement==null}catch(b){}s.documentElement.doScroll&&a&&ma()}}},isFunction:function(a){return $.call(a)==="[object Function]"},isArray:function(a){return $.call(a)==="[object Array]"},isPlainObject:function(a){if(!a||$.call(a)!=="[object Object]"||a.nodeType||a.setInterval)return false;if(a.constructor&&!aa.call(a,"constructor")&&!aa.call(a.constructor.prototype, "isPrototypeOf"))return false;var b;for(b in a);return b===w||aa.call(a,b)},isEmptyObject:function(a){for(var b in a)return false;return true},error:function(a){throw a;},parseJSON:function(a){if(typeof a!=="string"||!a)return null;a=c.trim(a);if(/^[\],:{}\s]*$/.test(a.replace(/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,"@").replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,"]").replace(/(?:^|:|,)(?:\s*\[)+/g,"")))return A.JSON&&A.JSON.parse?A.JSON.parse(a):(new Function("return "+ a))();else c.error("Invalid JSON: "+a)},noop:function(){},globalEval:function(a){if(a&&Va.test(a)){var b=s.getElementsByTagName("head")[0]||s.documentElement,d=s.createElement("script");d.type="text/javascript";if(c.support.scriptEval)d.appendChild(s.createTextNode(a));else d.text=a;b.insertBefore(d,b.firstChild);b.removeChild(d)}},nodeName:function(a,b){return a.nodeName&&a.nodeName.toUpperCase()===b.toUpperCase()},each:function(a,b,d){var f,e=0,j=a.length,i=j===w||c.isFunction(a);if(d)if(i)for(f in a){if(b.apply(a[f], d)===false)break}else for(;e<j;){if(b.apply(a[e++],d)===false)break}else if(i)for(f in a){if(b.call(a[f],f,a[f])===false)break}else for(d=a[0];e<j&&b.call(d,e,d)!==false;d=a[++e]);return a},trim:function(a){return(a||"").replace(Wa,"")},makeArray:function(a,b){b=b||[];if(a!=null)a.length==null||typeof a==="string"||c.isFunction(a)||typeof a!=="function"&&a.setInterval?ba.call(b,a):c.merge(b,a);return b},inArray:function(a,b){if(b.indexOf)return b.indexOf(a);for(var d=0,f=b.length;d<f;d++)if(b[d]=== a)return d;return-1},merge:function(a,b){var d=a.length,f=0;if(typeof b.length==="number")for(var e=b.length;f<e;f++)a[d++]=b[f];else for(;b[f]!==w;)a[d++]=b[f++];a.length=d;return a},grep:function(a,b,d){for(var f=[],e=0,j=a.length;e<j;e++)!d!==!b(a[e],e)&&f.push(a[e]);return f},map:function(a,b,d){for(var f=[],e,j=0,i=a.length;j<i;j++){e=b(a[j],j,d);if(e!=null)f[f.length]=e}return f.concat.apply([],f)},guid:1,proxy:function(a,b,d){if(arguments.length===2)if(typeof b==="string"){d=a;a=d[b];b=w}else if(b&& !c.isFunction(b)){d=b;b=w}if(!b&&a)b=function(){return a.apply(d||this,arguments)};if(a)b.guid=a.guid=a.guid||b.guid||c.guid++;return b},uaMatch:function(a){a=a.toLowerCase();a=/(webkit)[ \/]([\w.]+)/.exec(a)||/(opera)(?:.*version)?[ \/]([\w.]+)/.exec(a)||/(msie) ([\w.]+)/.exec(a)||!/compatible/.test(a)&&/(mozilla)(?:.*? rv:([\w.]+))?/.exec(a)||[];return{browser:a[1]||"",version:a[2]||"0"}},browser:{}});P=c.uaMatch(P);if(P.browser){c.browser[P.browser]=true;c.browser.version=P.version}if(c.browser.webkit)c.browser.safari= true;if(ya)c.inArray=function(a,b){return ya.call(b,a)};T=c(s);if(s.addEventListener)L=function(){s.removeEventListener("DOMContentLoaded",L,false);c.ready()};else if(s.attachEvent)L=function(){if(s.readyState==="complete"){s.detachEvent("onreadystatechange",L);c.ready()}};(function(){c.support={};var a=s.documentElement,b=s.createElement("script"),d=s.createElement("div"),f="script"+J();d.style.display="none";d.innerHTML=" <link/><table></table><a href='/a' style='color:red;float:left;opacity:.55;'>a</a><input type='checkbox'/>"; var e=d.getElementsByTagName("*"),j=d.getElementsByTagName("a")[0];if(!(!e||!e.length||!j)){c.support={leadingWhitespace:d.firstChild.nodeType===3,tbody:!d.getElementsByTagName("tbody").length,htmlSerialize:!!d.getElementsByTagName("link").length,style:/red/.test(j.getAttribute("style")),hrefNormalized:j.getAttribute("href")==="/a",opacity:/^0.55$/.test(j.style.opacity),cssFloat:!!j.style.cssFloat,checkOn:d.getElementsByTagName("input")[0].value==="on",optSelected:s.createElement("select").appendChild(s.createElement("option")).selected, parentNode:d.removeChild(d.appendChild(s.createElement("div"))).parentNode===null,deleteExpando:true,checkClone:false,scriptEval:false,noCloneEvent:true,boxModel:null};b.type="text/javascript";try{b.appendChild(s.createTextNode("window."+f+"=1;"))}catch(i){}a.insertBefore(b,a.firstChild);if(A[f]){c.support.scriptEval=true;delete A[f]}try{delete b.test}catch(o){c.support.deleteExpando=false}a.removeChild(b);if(d.attachEvent&&d.fireEvent){d.attachEvent("onclick",function k(){c.support.noCloneEvent= false;d.detachEvent("onclick",k)});d.cloneNode(true).fireEvent("onclick")}d=s.createElement("div");d.innerHTML="<input type='radio' name='radiotest' checked='checked'/>";a=s.createDocumentFragment();a.appendChild(d.firstChild);c.support.checkClone=a.cloneNode(true).cloneNode(true).lastChild.checked;c(function(){var k=s.createElement("div");k.style.width=k.style.paddingLeft="1px";s.body.appendChild(k);c.boxModel=c.support.boxModel=k.offsetWidth===2;s.body.removeChild(k).style.display="none"});a=function(k){var n= s.createElement("div");k="on"+k;var r=k in n;if(!r){n.setAttribute(k,"return;");r=typeof n[k]==="function"}return r};c.support.submitBubbles=a("submit");c.support.changeBubbles=a("change");a=b=d=e=j=null}})();c.props={"for":"htmlFor","class":"className",readonly:"readOnly",maxlength:"maxLength",cellspacing:"cellSpacing",rowspan:"rowSpan",colspan:"colSpan",tabindex:"tabIndex",usemap:"useMap",frameborder:"frameBorder"};var G="jQuery"+J(),Ya=0,za={};c.extend({cache:{},expando:G,noData:{embed:true,object:true, applet:true},data:function(a,b,d){if(!(a.nodeName&&c.noData[a.nodeName.toLowerCase()])){a=a==A?za:a;var f=a[G],e=c.cache;if(!f&&typeof b==="string"&&d===w)return null;f||(f=++Ya);if(typeof b==="object"){a[G]=f;e[f]=c.extend(true,{},b)}else if(!e[f]){a[G]=f;e[f]={}}a=e[f];if(d!==w)a[b]=d;return typeof b==="string"?a[b]:a}},removeData:function(a,b){if(!(a.nodeName&&c.noData[a.nodeName.toLowerCase()])){a=a==A?za:a;var d=a[G],f=c.cache,e=f[d];if(b){if(e){delete e[b];c.isEmptyObject(e)&&c.removeData(a)}}else{if(c.support.deleteExpando)delete a[c.expando]; else a.removeAttribute&&a.removeAttribute(c.expando);delete f[d]}}}});c.fn.extend({data:function(a,b){if(typeof a==="undefined"&&this.length)return c.data(this[0]);else if(typeof a==="object")return this.each(function(){c.data(this,a)});var d=a.split(".");d[1]=d[1]?"."+d[1]:"";if(b===w){var f=this.triggerHandler("getData"+d[1]+"!",[d[0]]);if(f===w&&this.length)f=c.data(this[0],a);return f===w&&d[1]?this.data(d[0]):f}else return this.trigger("setData"+d[1]+"!",[d[0],b]).each(function(){c.data(this, a,b)})},removeData:function(a){return this.each(function(){c.removeData(this,a)})}});c.extend({queue:function(a,b,d){if(a){b=(b||"fx")+"queue";var f=c.data(a,b);if(!d)return f||[];if(!f||c.isArray(d))f=c.data(a,b,c.makeArray(d));else f.push(d);return f}},dequeue:function(a,b){b=b||"fx";var d=c.queue(a,b),f=d.shift();if(f==="inprogress")f=d.shift();if(f){b==="fx"&&d.unshift("inprogress");f.call(a,function(){c.dequeue(a,b)})}}});c.fn.extend({queue:function(a,b){if(typeof a!=="string"){b=a;a="fx"}if(b=== w)return c.queue(this[0],a);return this.each(function(){var d=c.queue(this,a,b);a==="fx"&&d[0]!=="inprogress"&&c.dequeue(this,a)})},dequeue:function(a){return this.each(function(){c.dequeue(this,a)})},delay:function(a,b){a=c.fx?c.fx.speeds[a]||a:a;b=b||"fx";return this.queue(b,function(){var d=this;setTimeout(function(){c.dequeue(d,b)},a)})},clearQueue:function(a){return this.queue(a||"fx",[])}});var Aa=/[\n\t]/g,ca=/\s+/,Za=/\r/g,$a=/href|src|style/,ab=/(button|input)/i,bb=/(button|input|object|select|textarea)/i, cb=/^(a|area)$/i,Ba=/radio|checkbox/;c.fn.extend({attr:function(a,b){return X(this,a,b,true,c.attr)},removeAttr:function(a){return this.each(function(){c.attr(this,a,"");this.nodeType===1&&this.removeAttribute(a)})},addClass:function(a){if(c.isFunction(a))return this.each(function(n){var r=c(this);r.addClass(a.call(this,n,r.attr("class")))});if(a&&typeof a==="string")for(var b=(a||"").split(ca),d=0,f=this.length;d<f;d++){var e=this[d];if(e.nodeType===1)if(e.className){for(var j=" "+e.className+" ", i=e.className,o=0,k=b.length;o<k;o++)if(j.indexOf(" "+b[o]+" ")<0)i+=" "+b[o];e.className=c.trim(i)}else e.className=a}return this},removeClass:function(a){if(c.isFunction(a))return this.each(function(k){var n=c(this);n.removeClass(a.call(this,k,n.attr("class")))});if(a&&typeof a==="string"||a===w)for(var b=(a||"").split(ca),d=0,f=this.length;d<f;d++){var e=this[d];if(e.nodeType===1&&e.className)if(a){for(var j=(" "+e.className+" ").replace(Aa," "),i=0,o=b.length;i<o;i++)j=j.replace(" "+b[i]+" ", " ");e.className=c.trim(j)}else e.className=""}return this},toggleClass:function(a,b){var d=typeof a,f=typeof b==="boolean";if(c.isFunction(a))return this.each(function(e){var j=c(this);j.toggleClass(a.call(this,e,j.attr("class"),b),b)});return this.each(function(){if(d==="string")for(var e,j=0,i=c(this),o=b,k=a.split(ca);e=k[j++];){o=f?o:!i.hasClass(e);i[o?"addClass":"removeClass"](e)}else if(d==="undefined"||d==="boolean"){this.className&&c.data(this,"__className__",this.className);this.className= this.className||a===false?"":c.data(this,"__className__")||""}})},hasClass:function(a){a=" "+a+" ";for(var b=0,d=this.length;b<d;b++)if((" "+this[b].className+" ").replace(Aa," ").indexOf(a)>-1)return true;return false},val:function(a){if(a===w){var b=this[0];if(b){if(c.nodeName(b,"option"))return(b.attributes.value||{}).specified?b.value:b.text;if(c.nodeName(b,"select")){var d=b.selectedIndex,f=[],e=b.options;b=b.type==="select-one";if(d<0)return null;var j=b?d:0;for(d=b?d+1:e.length;j<d;j++){var i= e[j];if(i.selected){a=c(i).val();if(b)return a;f.push(a)}}return f}if(Ba.test(b.type)&&!c.support.checkOn)return b.getAttribute("value")===null?"on":b.value;return(b.value||"").replace(Za,"")}return w}var o=c.isFunction(a);return this.each(function(k){var n=c(this),r=a;if(this.nodeType===1){if(o)r=a.call(this,k,n.val());if(typeof r==="number")r+="";if(c.isArray(r)&&Ba.test(this.type))this.checked=c.inArray(n.val(),r)>=0;else if(c.nodeName(this,"select")){var u=c.makeArray(r);c("option",this).each(function(){this.selected= c.inArray(c(this).val(),u)>=0});if(!u.length)this.selectedIndex=-1}else this.value=r}})}});c.extend({attrFn:{val:true,css:true,html:true,text:true,data:true,width:true,height:true,offset:true},attr:function(a,b,d,f){if(!a||a.nodeType===3||a.nodeType===8)return w;if(f&&b in c.attrFn)return c(a)[b](d);f=a.nodeType!==1||!c.isXMLDoc(a);var e=d!==w;b=f&&c.props[b]||b;if(a.nodeType===1){var j=$a.test(b);if(b in a&&f&&!j){if(e){b==="type"&&ab.test(a.nodeName)&&a.parentNode&&c.error("type property can't be changed"); a[b]=d}if(c.nodeName(a,"form")&&a.getAttributeNode(b))return a.getAttributeNode(b).nodeValue;if(b==="tabIndex")return(b=a.getAttributeNode("tabIndex"))&&b.specified?b.value:bb.test(a.nodeName)||cb.test(a.nodeName)&&a.href?0:w;return a[b]}if(!c.support.style&&f&&b==="style"){if(e)a.style.cssText=""+d;return a.style.cssText}e&&a.setAttribute(b,""+d);a=!c.support.hrefNormalized&&f&&j?a.getAttribute(b,2):a.getAttribute(b);return a===null?w:a}return c.style(a,b,d)}});var O=/\.(.*)$/,db=function(a){return a.replace(/[^\w\s\.\|`]/g, function(b){return"\\"+b})};c.event={add:function(a,b,d,f){if(!(a.nodeType===3||a.nodeType===8)){if(a.setInterval&&a!==A&&!a.frameElement)a=A;var e,j;if(d.handler){e=d;d=e.handler}if(!d.guid)d.guid=c.guid++;if(j=c.data(a)){var i=j.events=j.events||{},o=j.handle;if(!o)j.handle=o=function(){return typeof c!=="undefined"&&!c.event.triggered?c.event.handle.apply(o.elem,arguments):w};o.elem=a;b=b.split(" ");for(var k,n=0,r;k=b[n++];){j=e?c.extend({},e):{handler:d,data:f};if(k.indexOf(".")>-1){r=k.split("."); k=r.shift();j.namespace=r.slice(0).sort().join(".")}else{r=[];j.namespace=""}j.type=k;j.guid=d.guid;var u=i[k],z=c.event.special[k]||{};if(!u){u=i[k]=[];if(!z.setup||z.setup.call(a,f,r,o)===false)if(a.addEventListener)a.addEventListener(k,o,false);else a.attachEvent&&a.attachEvent("on"+k,o)}if(z.add){z.add.call(a,j);if(!j.handler.guid)j.handler.guid=d.guid}u.push(j);c.event.global[k]=true}a=null}}},global:{},remove:function(a,b,d,f){if(!(a.nodeType===3||a.nodeType===8)){var e,j=0,i,o,k,n,r,u,z=c.data(a), C=z&&z.events;if(z&&C){if(b&&b.type){d=b.handler;b=b.type}if(!b||typeof b==="string"&&b.charAt(0)==="."){b=b||"";for(e in C)c.event.remove(a,e+b)}else{for(b=b.split(" ");e=b[j++];){n=e;i=e.indexOf(".")<0;o=[];if(!i){o=e.split(".");e=o.shift();k=new RegExp("(^|\\.)"+c.map(o.slice(0).sort(),db).join("\\.(?:.*\\.)?")+"(\\.|$)")}if(r=C[e])if(d){n=c.event.special[e]||{};for(B=f||0;B<r.length;B++){u=r[B];if(d.guid===u.guid){if(i||k.test(u.namespace)){f==null&&r.splice(B--,1);n.remove&&n.remove.call(a,u)}if(f!= null)break}}if(r.length===0||f!=null&&r.length===1){if(!n.teardown||n.teardown.call(a,o)===false)Ca(a,e,z.handle);delete C[e]}}else for(var B=0;B<r.length;B++){u=r[B];if(i||k.test(u.namespace)){c.event.remove(a,n,u.handler,B);r.splice(B--,1)}}}if(c.isEmptyObject(C)){if(b=z.handle)b.elem=null;delete z.events;delete z.handle;c.isEmptyObject(z)&&c.removeData(a)}}}}},trigger:function(a,b,d,f){var e=a.type||a;if(!f){a=typeof a==="object"?a[G]?a:c.extend(c.Event(e),a):c.Event(e);if(e.indexOf("!")>=0){a.type= e=e.slice(0,-1);a.exclusive=true}if(!d){a.stopPropagation();c.event.global[e]&&c.each(c.cache,function(){this.events&&this.events[e]&&c.event.trigger(a,b,this.handle.elem)})}if(!d||d.nodeType===3||d.nodeType===8)return w;a.result=w;a.target=d;b=c.makeArray(b);b.unshift(a)}a.currentTarget=d;(f=c.data(d,"handle"))&&f.apply(d,b);f=d.parentNode||d.ownerDocument;try{if(!(d&&d.nodeName&&c.noData[d.nodeName.toLowerCase()]))if(d["on"+e]&&d["on"+e].apply(d,b)===false)a.result=false}catch(j){}if(!a.isPropagationStopped()&& f)c.event.trigger(a,b,f,true);else if(!a.isDefaultPrevented()){f=a.target;var i,o=c.nodeName(f,"a")&&e==="click",k=c.event.special[e]||{};if((!k._default||k._default.call(d,a)===false)&&!o&&!(f&&f.nodeName&&c.noData[f.nodeName.toLowerCase()])){try{if(f[e]){if(i=f["on"+e])f["on"+e]=null;c.event.triggered=true;f[e]()}}catch(n){}if(i)f["on"+e]=i;c.event.triggered=false}}},handle:function(a){var b,d,f,e;a=arguments[0]=c.event.fix(a||A.event);a.currentTarget=this;b=a.type.indexOf(".")<0&&!a.exclusive; if(!b){d=a.type.split(".");a.type=d.shift();f=new RegExp("(^|\\.)"+d.slice(0).sort().join("\\.(?:.*\\.)?")+"(\\.|$)")}e=c.data(this,"events");d=e[a.type];if(e&&d){d=d.slice(0);e=0;for(var j=d.length;e<j;e++){var i=d[e];if(b||f.test(i.namespace)){a.handler=i.handler;a.data=i.data;a.handleObj=i;i=i.handler.apply(this,arguments);if(i!==w){a.result=i;if(i===false){a.preventDefault();a.stopPropagation()}}if(a.isImmediatePropagationStopped())break}}}return a.result},props:"altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode layerX layerY metaKey newValue offsetX offsetY originalTarget pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target toElement view wheelDelta which".split(" "), fix:function(a){if(a[G])return a;var b=a;a=c.Event(b);for(var d=this.props.length,f;d;){f=this.props[--d];a[f]=b[f]}if(!a.target)a.target=a.srcElement||s;if(a.target.nodeType===3)a.target=a.target.parentNode;if(!a.relatedTarget&&a.fromElement)a.relatedTarget=a.fromElement===a.target?a.toElement:a.fromElement;if(a.pageX==null&&a.clientX!=null){b=s.documentElement;d=s.body;a.pageX=a.clientX+(b&&b.scrollLeft||d&&d.scrollLeft||0)-(b&&b.clientLeft||d&&d.clientLeft||0);a.pageY=a.clientY+(b&&b.scrollTop|| d&&d.scrollTop||0)-(b&&b.clientTop||d&&d.clientTop||0)}if(!a.which&&(a.charCode||a.charCode===0?a.charCode:a.keyCode))a.which=a.charCode||a.keyCode;if(!a.metaKey&&a.ctrlKey)a.metaKey=a.ctrlKey;if(!a.which&&a.button!==w)a.which=a.button&1?1:a.button&2?3:a.button&4?2:0;return a},guid:1E8,proxy:c.proxy,special:{ready:{setup:c.bindReady,teardown:c.noop},live:{add:function(a){c.event.add(this,a.origType,c.extend({},a,{handler:oa}))},remove:function(a){var b=true,d=a.origType.replace(O,"");c.each(c.data(this, "events").live||[],function(){if(d===this.origType.replace(O,""))return b=false});b&&c.event.remove(this,a.origType,oa)}},beforeunload:{setup:function(a,b,d){if(this.setInterval)this.onbeforeunload=d;return false},teardown:function(a,b){if(this.onbeforeunload===b)this.onbeforeunload=null}}}};var Ca=s.removeEventListener?function(a,b,d){a.removeEventListener(b,d,false)}:function(a,b,d){a.detachEvent("on"+b,d)};c.Event=function(a){if(!this.preventDefault)return new c.Event(a);if(a&&a.type){this.originalEvent= a;this.type=a.type}else this.type=a;this.timeStamp=J();this[G]=true};c.Event.prototype={preventDefault:function(){this.isDefaultPrevented=Z;var a=this.originalEvent;if(a){a.preventDefault&&a.preventDefault();a.returnValue=false}},stopPropagation:function(){this.isPropagationStopped=Z;var a=this.originalEvent;if(a){a.stopPropagation&&a.stopPropagation();a.cancelBubble=true}},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=Z;this.stopPropagation()},isDefaultPrevented:Y,isPropagationStopped:Y, isImmediatePropagationStopped:Y};var Da=function(a){var b=a.relatedTarget;try{for(;b&&b!==this;)b=b.parentNode;if(b!==this){a.type=a.data;c.event.handle.apply(this,arguments)}}catch(d){}},Ea=function(a){a.type=a.data;c.event.handle.apply(this,arguments)};c.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(a,b){c.event.special[a]={setup:function(d){c.event.add(this,b,d&&d.selector?Ea:Da,a)},teardown:function(d){c.event.remove(this,b,d&&d.selector?Ea:Da)}}});if(!c.support.submitBubbles)c.event.special.submit= {setup:function(){if(this.nodeName.toLowerCase()!=="form"){c.event.add(this,"click.specialSubmit",function(a){var b=a.target,d=b.type;if((d==="submit"||d==="image")&&c(b).closest("form").length)return na("submit",this,arguments)});c.event.add(this,"keypress.specialSubmit",function(a){var b=a.target,d=b.type;if((d==="text"||d==="password")&&c(b).closest("form").length&&a.keyCode===13)return na("submit",this,arguments)})}else return false},teardown:function(){c.event.remove(this,".specialSubmit")}}; if(!c.support.changeBubbles){var da=/textarea|input|select/i,ea,Fa=function(a){var b=a.type,d=a.value;if(b==="radio"||b==="checkbox")d=a.checked;else if(b==="select-multiple")d=a.selectedIndex>-1?c.map(a.options,function(f){return f.selected}).join("-"):"";else if(a.nodeName.toLowerCase()==="select")d=a.selectedIndex;return d},fa=function(a,b){var d=a.target,f,e;if(!(!da.test(d.nodeName)||d.readOnly)){f=c.data(d,"_change_data");e=Fa(d);if(a.type!=="focusout"||d.type!=="radio")c.data(d,"_change_data", e);if(!(f===w||e===f))if(f!=null||e){a.type="change";return c.event.trigger(a,b,d)}}};c.event.special.change={filters:{focusout:fa,click:function(a){var b=a.target,d=b.type;if(d==="radio"||d==="checkbox"||b.nodeName.toLowerCase()==="select")return fa.call(this,a)},keydown:function(a){var b=a.target,d=b.type;if(a.keyCode===13&&b.nodeName.toLowerCase()!=="textarea"||a.keyCode===32&&(d==="checkbox"||d==="radio")||d==="select-multiple")return fa.call(this,a)},beforeactivate:function(a){a=a.target;c.data(a, "_change_data",Fa(a))}},setup:function(){if(this.type==="file")return false;for(var a in ea)c.event.add(this,a+".specialChange",ea[a]);return da.test(this.nodeName)},teardown:function(){c.event.remove(this,".specialChange");return da.test(this.nodeName)}};ea=c.event.special.change.filters}s.addEventListener&&c.each({focus:"focusin",blur:"focusout"},function(a,b){function d(f){f=c.event.fix(f);f.type=b;return c.event.handle.call(this,f)}c.event.special[b]={setup:function(){this.addEventListener(a, d,true)},teardown:function(){this.removeEventListener(a,d,true)}}});c.each(["bind","one"],function(a,b){c.fn[b]=function(d,f,e){if(typeof d==="object"){for(var j in d)this[b](j,f,d[j],e);return this}if(c.isFunction(f)){e=f;f=w}var i=b==="one"?c.proxy(e,function(k){c(this).unbind(k,i);return e.apply(this,arguments)}):e;if(d==="unload"&&b!=="one")this.one(d,f,e);else{j=0;for(var o=this.length;j<o;j++)c.event.add(this[j],d,i,f)}return this}});c.fn.extend({unbind:function(a,b){if(typeof a==="object"&& !a.preventDefault)for(var d in a)this.unbind(d,a[d]);else{d=0;for(var f=this.length;d<f;d++)c.event.remove(this[d],a,b)}return this},delegate:function(a,b,d,f){return this.live(b,d,f,a)},undelegate:function(a,b,d){return arguments.length===0?this.unbind("live"):this.die(b,null,d,a)},trigger:function(a,b){return this.each(function(){c.event.trigger(a,b,this)})},triggerHandler:function(a,b){if(this[0]){a=c.Event(a);a.preventDefault();a.stopPropagation();c.event.trigger(a,b,this[0]);return a.result}}, toggle:function(a){for(var b=arguments,d=1;d<b.length;)c.proxy(a,b[d++]);return this.click(c.proxy(a,function(f){var e=(c.data(this,"lastToggle"+a.guid)||0)%d;c.data(this,"lastToggle"+a.guid,e+1);f.preventDefault();return b[e].apply(this,arguments)||false}))},hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)}});var Ga={focus:"focusin",blur:"focusout",mouseenter:"mouseover",mouseleave:"mouseout"};c.each(["live","die"],function(a,b){c.fn[b]=function(d,f,e,j){var i,o=0,k,n,r=j||this.selector, u=j?this:c(this.context);if(c.isFunction(f)){e=f;f=w}for(d=(d||"").split(" ");(i=d[o++])!=null;){j=O.exec(i);k="";if(j){k=j[0];i=i.replace(O,"")}if(i==="hover")d.push("mouseenter"+k,"mouseleave"+k);else{n=i;if(i==="focus"||i==="blur"){d.push(Ga[i]+k);i+=k}else i=(Ga[i]||i)+k;b==="live"?u.each(function(){c.event.add(this,pa(i,r),{data:f,selector:r,handler:e,origType:i,origHandler:e,preType:n})}):u.unbind(pa(i,r),e)}}return this}});c.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".split(" "), function(a,b){c.fn[b]=function(d){return d?this.bind(b,d):this.trigger(b)};if(c.attrFn)c.attrFn[b]=true});A.attachEvent&&!A.addEventListener&&A.attachEvent("onunload",function(){for(var a in c.cache)if(c.cache[a].handle)try{c.event.remove(c.cache[a].handle.elem)}catch(b){}});(function(){function a(g){for(var h="",l,m=0;g[m];m++){l=g[m];if(l.nodeType===3||l.nodeType===4)h+=l.nodeValue;else if(l.nodeType!==8)h+=a(l.childNodes)}return h}function b(g,h,l,m,q,p){q=0;for(var v=m.length;q<v;q++){var t=m[q]; if(t){t=t[g];for(var y=false;t;){if(t.sizcache===l){y=m[t.sizset];break}if(t.nodeType===1&&!p){t.sizcache=l;t.sizset=q}if(t.nodeName.toLowerCase()===h){y=t;break}t=t[g]}m[q]=y}}}function d(g,h,l,m,q,p){q=0;for(var v=m.length;q<v;q++){var t=m[q];if(t){t=t[g];for(var y=false;t;){if(t.sizcache===l){y=m[t.sizset];break}if(t.nodeType===1){if(!p){t.sizcache=l;t.sizset=q}if(typeof h!=="string"){if(t===h){y=true;break}}else if(k.filter(h,[t]).length>0){y=t;break}}t=t[g]}m[q]=y}}}var f=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^[\]]*\]|['"][^'"]*['"]|[^[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g, e=0,j=Object.prototype.toString,i=false,o=true;[0,0].sort(function(){o=false;return 0});var k=function(g,h,l,m){l=l||[];var q=h=h||s;if(h.nodeType!==1&&h.nodeType!==9)return[];if(!g||typeof g!=="string")return l;for(var p=[],v,t,y,S,H=true,M=x(h),I=g;(f.exec(""),v=f.exec(I))!==null;){I=v[3];p.push(v[1]);if(v[2]){S=v[3];break}}if(p.length>1&&r.exec(g))if(p.length===2&&n.relative[p[0]])t=ga(p[0]+p[1],h);else for(t=n.relative[p[0]]?[h]:k(p.shift(),h);p.length;){g=p.shift();if(n.relative[g])g+=p.shift(); t=ga(g,t)}else{if(!m&&p.length>1&&h.nodeType===9&&!M&&n.match.ID.test(p[0])&&!n.match.ID.test(p[p.length-1])){v=k.find(p.shift(),h,M);h=v.expr?k.filter(v.expr,v.set)[0]:v.set[0]}if(h){v=m?{expr:p.pop(),set:z(m)}:k.find(p.pop(),p.length===1&&(p[0]==="~"||p[0]==="+")&&h.parentNode?h.parentNode:h,M);t=v.expr?k.filter(v.expr,v.set):v.set;if(p.length>0)y=z(t);else H=false;for(;p.length;){var D=p.pop();v=D;if(n.relative[D])v=p.pop();else D="";if(v==null)v=h;n.relative[D](y,v,M)}}else y=[]}y||(y=t);y||k.error(D|| g);if(j.call(y)==="[object Array]")if(H)if(h&&h.nodeType===1)for(g=0;y[g]!=null;g++){if(y[g]&&(y[g]===true||y[g].nodeType===1&&E(h,y[g])))l.push(t[g])}else for(g=0;y[g]!=null;g++)y[g]&&y[g].nodeType===1&&l.push(t[g]);else l.push.apply(l,y);else z(y,l);if(S){k(S,q,l,m);k.uniqueSort(l)}return l};k.uniqueSort=function(g){if(B){i=o;g.sort(B);if(i)for(var h=1;h<g.length;h++)g[h]===g[h-1]&&g.splice(h--,1)}return g};k.matches=function(g,h){return k(g,null,null,h)};k.find=function(g,h,l){var m,q;if(!g)return[]; for(var p=0,v=n.order.length;p<v;p++){var t=n.order[p];if(q=n.leftMatch[t].exec(g)){var y=q[1];q.splice(1,1);if(y.substr(y.length-1)!=="\\"){q[1]=(q[1]||"").replace(/\\/g,"");m=n.find[t](q,h,l);if(m!=null){g=g.replace(n.match[t],"");break}}}}m||(m=h.getElementsByTagName("*"));return{set:m,expr:g}};k.filter=function(g,h,l,m){for(var q=g,p=[],v=h,t,y,S=h&&h[0]&&x(h[0]);g&&h.length;){for(var H in n.filter)if((t=n.leftMatch[H].exec(g))!=null&&t[2]){var M=n.filter[H],I,D;D=t[1];y=false;t.splice(1,1);if(D.substr(D.length- 1)!=="\\"){if(v===p)p=[];if(n.preFilter[H])if(t=n.preFilter[H](t,v,l,p,m,S)){if(t===true)continue}else y=I=true;if(t)for(var U=0;(D=v[U])!=null;U++)if(D){I=M(D,t,U,v);var Ha=m^!!I;if(l&&I!=null)if(Ha)y=true;else v[U]=false;else if(Ha){p.push(D);y=true}}if(I!==w){l||(v=p);g=g.replace(n.match[H],"");if(!y)return[];break}}}if(g===q)if(y==null)k.error(g);else break;q=g}return v};k.error=function(g){throw"Syntax error, unrecognized expression: "+g;};var n=k.selectors={order:["ID","NAME","TAG"],match:{ID:/#((?:[\w\u00c0-\uFFFF-]|\\.)+)/, CLASS:/\.((?:[\w\u00c0-\uFFFF-]|\\.)+)/,NAME:/\[name=['"]*((?:[\w\u00c0-\uFFFF-]|\\.)+)['"]*\]/,ATTR:/\[\s*((?:[\w\u00c0-\uFFFF-]|\\.)+)\s*(?:(\S?=)\s*(['"]*)(.*?)\3|)\s*\]/,TAG:/^((?:[\w\u00c0-\uFFFF\*-]|\\.)+)/,CHILD:/:(only|nth|last|first)-child(?:\((even|odd|[\dn+-]*)\))?/,POS:/:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^-]|$)/,PSEUDO:/:((?:[\w\u00c0-\uFFFF-]|\\.)+)(?:\((['"]?)((?:\([^\)]+\)|[^\(\)]*)+)\2\))?/},leftMatch:{},attrMap:{"class":"className","for":"htmlFor"},attrHandle:{href:function(g){return g.getAttribute("href")}}, relative:{"+":function(g,h){var l=typeof h==="string",m=l&&!/\W/.test(h);l=l&&!m;if(m)h=h.toLowerCase();m=0;for(var q=g.length,p;m<q;m++)if(p=g[m]){for(;(p=p.previousSibling)&&p.nodeType!==1;);g[m]=l||p&&p.nodeName.toLowerCase()===h?p||false:p===h}l&&k.filter(h,g,true)},">":function(g,h){var l=typeof h==="string";if(l&&!/\W/.test(h)){h=h.toLowerCase();for(var m=0,q=g.length;m<q;m++){var p=g[m];if(p){l=p.parentNode;g[m]=l.nodeName.toLowerCase()===h?l:false}}}else{m=0;for(q=g.length;m<q;m++)if(p=g[m])g[m]= l?p.parentNode:p.parentNode===h;l&&k.filter(h,g,true)}},"":function(g,h,l){var m=e++,q=d;if(typeof h==="string"&&!/\W/.test(h)){var p=h=h.toLowerCase();q=b}q("parentNode",h,m,g,p,l)},"~":function(g,h,l){var m=e++,q=d;if(typeof h==="string"&&!/\W/.test(h)){var p=h=h.toLowerCase();q=b}q("previousSibling",h,m,g,p,l)}},find:{ID:function(g,h,l){if(typeof h.getElementById!=="undefined"&&!l)return(g=h.getElementById(g[1]))?[g]:[]},NAME:function(g,h){if(typeof h.getElementsByName!=="undefined"){var l=[]; h=h.getElementsByName(g[1]);for(var m=0,q=h.length;m<q;m++)h[m].getAttribute("name")===g[1]&&l.push(h[m]);return l.length===0?null:l}},TAG:function(g,h){return h.getElementsByTagName(g[1])}},preFilter:{CLASS:function(g,h,l,m,q,p){g=" "+g[1].replace(/\\/g,"")+" ";if(p)return g;p=0;for(var v;(v=h[p])!=null;p++)if(v)if(q^(v.className&&(" "+v.className+" ").replace(/[\t\n]/g," ").indexOf(g)>=0))l||m.push(v);else if(l)h[p]=false;return false},ID:function(g){return g[1].replace(/\\/g,"")},TAG:function(g){return g[1].toLowerCase()}, CHILD:function(g){if(g[1]==="nth"){var h=/(-?)(\d*)n((?:\+|-)?\d*)/.exec(g[2]==="even"&&"2n"||g[2]==="odd"&&"2n+1"||!/\D/.test(g[2])&&"0n+"+g[2]||g[2]);g[2]=h[1]+(h[2]||1)-0;g[3]=h[3]-0}g[0]=e++;return g},ATTR:function(g,h,l,m,q,p){h=g[1].replace(/\\/g,"");if(!p&&n.attrMap[h])g[1]=n.attrMap[h];if(g[2]==="~=")g[4]=" "+g[4]+" ";return g},PSEUDO:function(g,h,l,m,q){if(g[1]==="not")if((f.exec(g[3])||"").length>1||/^\w/.test(g[3]))g[3]=k(g[3],null,null,h);else{g=k.filter(g[3],h,l,true^q);l||m.push.apply(m, g);return false}else if(n.match.POS.test(g[0])||n.match.CHILD.test(g[0]))return true;return g},POS:function(g){g.unshift(true);return g}},filters:{enabled:function(g){return g.disabled===false&&g.type!=="hidden"},disabled:function(g){return g.disabled===true},checked:function(g){return g.checked===true},selected:function(g){return g.selected===true},parent:function(g){return!!g.firstChild},empty:function(g){return!g.firstChild},has:function(g,h,l){return!!k(l[3],g).length},header:function(g){return/h\d/i.test(g.nodeName)}, text:function(g){return"text"===g.type},radio:function(g){return"radio"===g.type},checkbox:function(g){return"checkbox"===g.type},file:function(g){return"file"===g.type},password:function(g){return"password"===g.type},submit:function(g){return"submit"===g.type},image:function(g){return"image"===g.type},reset:function(g){return"reset"===g.type},button:function(g){return"button"===g.type||g.nodeName.toLowerCase()==="button"},input:function(g){return/input|select|textarea|button/i.test(g.nodeName)}}, setFilters:{first:function(g,h){return h===0},last:function(g,h,l,m){return h===m.length-1},even:function(g,h){return h%2===0},odd:function(g,h){return h%2===1},lt:function(g,h,l){return h<l[3]-0},gt:function(g,h,l){return h>l[3]-0},nth:function(g,h,l){return l[3]-0===h},eq:function(g,h,l){return l[3]-0===h}},filter:{PSEUDO:function(g,h,l,m){var q=h[1],p=n.filters[q];if(p)return p(g,l,h,m);else if(q==="contains")return(g.textContent||g.innerText||a([g])||"").indexOf(h[3])>=0;else if(q==="not"){h= h[3];l=0;for(m=h.length;l<m;l++)if(h[l]===g)return false;return true}else k.error("Syntax error, unrecognized expression: "+q)},CHILD:function(g,h){var l=h[1],m=g;switch(l){case "only":case "first":for(;m=m.previousSibling;)if(m.nodeType===1)return false;if(l==="first")return true;m=g;case "last":for(;m=m.nextSibling;)if(m.nodeType===1)return false;return true;case "nth":l=h[2];var q=h[3];if(l===1&&q===0)return true;h=h[0];var p=g.parentNode;if(p&&(p.sizcache!==h||!g.nodeIndex)){var v=0;for(m=p.firstChild;m;m= m.nextSibling)if(m.nodeType===1)m.nodeIndex=++v;p.sizcache=h}g=g.nodeIndex-q;return l===0?g===0:g%l===0&&g/l>=0}},ID:function(g,h){return g.nodeType===1&&g.getAttribute("id")===h},TAG:function(g,h){return h==="*"&&g.nodeType===1||g.nodeName.toLowerCase()===h},CLASS:function(g,h){return(" "+(g.className||g.getAttribute("class"))+" ").indexOf(h)>-1},ATTR:function(g,h){var l=h[1];g=n.attrHandle[l]?n.attrHandle[l](g):g[l]!=null?g[l]:g.getAttribute(l);l=g+"";var m=h[2];h=h[4];return g==null?m==="!=":m=== "="?l===h:m==="*="?l.indexOf(h)>=0:m==="~="?(" "+l+" ").indexOf(h)>=0:!h?l&&g!==false:m==="!="?l!==h:m==="^="?l.indexOf(h)===0:m==="$="?l.substr(l.length-h.length)===h:m==="|="?l===h||l.substr(0,h.length+1)===h+"-":false},POS:function(g,h,l,m){var q=n.setFilters[h[2]];if(q)return q(g,l,h,m)}}},r=n.match.POS;for(var u in n.match){n.match[u]=new RegExp(n.match[u].source+/(?![^\[]*\])(?![^\(]*\))/.source);n.leftMatch[u]=new RegExp(/(^(?:.|\r|\n)*?)/.source+n.match[u].source.replace(/\\(\d+)/g,function(g, h){return"\\"+(h-0+1)}))}var z=function(g,h){g=Array.prototype.slice.call(g,0);if(h){h.push.apply(h,g);return h}return g};try{Array.prototype.slice.call(s.documentElement.childNodes,0)}catch(C){z=function(g,h){h=h||[];if(j.call(g)==="[object Array]")Array.prototype.push.apply(h,g);else if(typeof g.length==="number")for(var l=0,m=g.length;l<m;l++)h.push(g[l]);else for(l=0;g[l];l++)h.push(g[l]);return h}}var B;if(s.documentElement.compareDocumentPosition)B=function(g,h){if(!g.compareDocumentPosition|| !h.compareDocumentPosition){if(g==h)i=true;return g.compareDocumentPosition?-1:1}g=g.compareDocumentPosition(h)&4?-1:g===h?0:1;if(g===0)i=true;return g};else if("sourceIndex"in s.documentElement)B=function(g,h){if(!g.sourceIndex||!h.sourceIndex){if(g==h)i=true;return g.sourceIndex?-1:1}g=g.sourceIndex-h.sourceIndex;if(g===0)i=true;return g};else if(s.createRange)B=function(g,h){if(!g.ownerDocument||!h.ownerDocument){if(g==h)i=true;return g.ownerDocument?-1:1}var l=g.ownerDocument.createRange(),m= h.ownerDocument.createRange();l.setStart(g,0);l.setEnd(g,0);m.setStart(h,0);m.setEnd(h,0);g=l.compareBoundaryPoints(Range.START_TO_END,m);if(g===0)i=true;return g};(function(){var g=s.createElement("div"),h="script"+(new Date).getTime();g.innerHTML="<a name='"+h+"'/>";var l=s.documentElement;l.insertBefore(g,l.firstChild);if(s.getElementById(h)){n.find.ID=function(m,q,p){if(typeof q.getElementById!=="undefined"&&!p)return(q=q.getElementById(m[1]))?q.id===m[1]||typeof q.getAttributeNode!=="undefined"&& q.getAttributeNode("id").nodeValue===m[1]?[q]:w:[]};n.filter.ID=function(m,q){var p=typeof m.getAttributeNode!=="undefined"&&m.getAttributeNode("id");return m.nodeType===1&&p&&p.nodeValue===q}}l.removeChild(g);l=g=null})();(function(){var g=s.createElement("div");g.appendChild(s.createComment(""));if(g.getElementsByTagName("*").length>0)n.find.TAG=function(h,l){l=l.getElementsByTagName(h[1]);if(h[1]==="*"){h=[];for(var m=0;l[m];m++)l[m].nodeType===1&&h.push(l[m]);l=h}return l};g.innerHTML="<a href='#'></a>"; if(g.firstChild&&typeof g.firstChild.getAttribute!=="undefined"&&g.firstChild.getAttribute("href")!=="#")n.attrHandle.href=function(h){return h.getAttribute("href",2)};g=null})();s.querySelectorAll&&function(){var g=k,h=s.createElement("div");h.innerHTML="<p class='TEST'></p>";if(!(h.querySelectorAll&&h.querySelectorAll(".TEST").length===0)){k=function(m,q,p,v){q=q||s;if(!v&&q.nodeType===9&&!x(q))try{return z(q.querySelectorAll(m),p)}catch(t){}return g(m,q,p,v)};for(var l in g)k[l]=g[l];h=null}}(); (function(){var g=s.createElement("div");g.innerHTML="<div class='test e'></div><div class='test'></div>";if(!(!g.getElementsByClassName||g.getElementsByClassName("e").length===0)){g.lastChild.className="e";if(g.getElementsByClassName("e").length!==1){n.order.splice(1,0,"CLASS");n.find.CLASS=function(h,l,m){if(typeof l.getElementsByClassName!=="undefined"&&!m)return l.getElementsByClassName(h[1])};g=null}}})();var E=s.compareDocumentPosition?function(g,h){return!!(g.compareDocumentPosition(h)&16)}: function(g,h){return g!==h&&(g.contains?g.contains(h):true)},x=function(g){return(g=(g?g.ownerDocument||g:0).documentElement)?g.nodeName!=="HTML":false},ga=function(g,h){var l=[],m="",q;for(h=h.nodeType?[h]:h;q=n.match.PSEUDO.exec(g);){m+=q[0];g=g.replace(n.match.PSEUDO,"")}g=n.relative[g]?g+"*":g;q=0;for(var p=h.length;q<p;q++)k(g,h[q],l);return k.filter(m,l)};c.find=k;c.expr=k.selectors;c.expr[":"]=c.expr.filters;c.unique=k.uniqueSort;c.text=a;c.isXMLDoc=x;c.contains=E})();var eb=/Until$/,fb=/^(?:parents|prevUntil|prevAll)/, gb=/,/;R=Array.prototype.slice;var Ia=function(a,b,d){if(c.isFunction(b))return c.grep(a,function(e,j){return!!b.call(e,j,e)===d});else if(b.nodeType)return c.grep(a,function(e){return e===b===d});else if(typeof b==="string"){var f=c.grep(a,function(e){return e.nodeType===1});if(Ua.test(b))return c.filter(b,f,!d);else b=c.filter(b,f)}return c.grep(a,function(e){return c.inArray(e,b)>=0===d})};c.fn.extend({find:function(a){for(var b=this.pushStack("","find",a),d=0,f=0,e=this.length;f<e;f++){d=b.length; c.find(a,this[f],b);if(f>0)for(var j=d;j<b.length;j++)for(var i=0;i<d;i++)if(b[i]===b[j]){b.splice(j--,1);break}}return b},has:function(a){var b=c(a);return this.filter(function(){for(var d=0,f=b.length;d<f;d++)if(c.contains(this,b[d]))return true})},not:function(a){return this.pushStack(Ia(this,a,false),"not",a)},filter:function(a){return this.pushStack(Ia(this,a,true),"filter",a)},is:function(a){return!!a&&c.filter(a,this).length>0},closest:function(a,b){if(c.isArray(a)){var d=[],f=this[0],e,j= {},i;if(f&&a.length){e=0;for(var o=a.length;e<o;e++){i=a[e];j[i]||(j[i]=c.expr.match.POS.test(i)?c(i,b||this.context):i)}for(;f&&f.ownerDocument&&f!==b;){for(i in j){e=j[i];if(e.jquery?e.index(f)>-1:c(f).is(e)){d.push({selector:i,elem:f});delete j[i]}}f=f.parentNode}}return d}var k=c.expr.match.POS.test(a)?c(a,b||this.context):null;return this.map(function(n,r){for(;r&&r.ownerDocument&&r!==b;){if(k?k.index(r)>-1:c(r).is(a))return r;r=r.parentNode}return null})},index:function(a){if(!a||typeof a=== "string")return c.inArray(this[0],a?c(a):this.parent().children());return c.inArray(a.jquery?a[0]:a,this)},add:function(a,b){a=typeof a==="string"?c(a,b||this.context):c.makeArray(a);b=c.merge(this.get(),a);return this.pushStack(qa(a[0])||qa(b[0])?b:c.unique(b))},andSelf:function(){return this.add(this.prevObject)}});c.each({parent:function(a){return(a=a.parentNode)&&a.nodeType!==11?a:null},parents:function(a){return c.dir(a,"parentNode")},parentsUntil:function(a,b,d){return c.dir(a,"parentNode", d)},next:function(a){return c.nth(a,2,"nextSibling")},prev:function(a){return c.nth(a,2,"previousSibling")},nextAll:function(a){return c.dir(a,"nextSibling")},prevAll:function(a){return c.dir(a,"previousSibling")},nextUntil:function(a,b,d){return c.dir(a,"nextSibling",d)},prevUntil:function(a,b,d){return c.dir(a,"previousSibling",d)},siblings:function(a){return c.sibling(a.parentNode.firstChild,a)},children:function(a){return c.sibling(a.firstChild)},contents:function(a){return c.nodeName(a,"iframe")? a.contentDocument||a.contentWindow.document:c.makeArray(a.childNodes)}},function(a,b){c.fn[a]=function(d,f){var e=c.map(this,b,d);eb.test(a)||(f=d);if(f&&typeof f==="string")e=c.filter(f,e);e=this.length>1?c.unique(e):e;if((this.length>1||gb.test(f))&&fb.test(a))e=e.reverse();return this.pushStack(e,a,R.call(arguments).join(","))}});c.extend({filter:function(a,b,d){if(d)a=":not("+a+")";return c.find.matches(a,b)},dir:function(a,b,d){var f=[];for(a=a[b];a&&a.nodeType!==9&&(d===w||a.nodeType!==1||!c(a).is(d));){a.nodeType=== 1&&f.push(a);a=a[b]}return f},nth:function(a,b,d){b=b||1;for(var f=0;a;a=a[d])if(a.nodeType===1&&++f===b)break;return a},sibling:function(a,b){for(var d=[];a;a=a.nextSibling)a.nodeType===1&&a!==b&&d.push(a);return d}});var Ja=/ jQuery\d+="(?:\d+|null)"/g,V=/^\s+/,Ka=/(<([\w:]+)[^>]*?)\/>/g,hb=/^(?:area|br|col|embed|hr|img|input|link|meta|param)$/i,La=/<([\w:]+)/,ib=/<tbody/i,jb=/<|&#?\w+;/,ta=/<script|<object|<embed|<option|<style/i,ua=/checked\s*(?:[^=]|=\s*.checked.)/i,Ma=function(a,b,d){return hb.test(d)? a:b+"></"+d+">"},F={option:[1,"<select multiple='multiple'>","</select>"],legend:[1,"<fieldset>","</fieldset>"],thead:[1,"<table>","</table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],area:[1,"<map>","</map>"],_default:[0,"",""]};F.optgroup=F.option;F.tbody=F.tfoot=F.colgroup=F.caption=F.thead;F.th=F.td;if(!c.support.htmlSerialize)F._default=[1,"div<div>","</div>"];c.fn.extend({text:function(a){if(c.isFunction(a))return this.each(function(b){var d= c(this);d.text(a.call(this,b,d.text()))});if(typeof a!=="object"&&a!==w)return this.empty().append((this[0]&&this[0].ownerDocument||s).createTextNode(a));return c.text(this)},wrapAll:function(a){if(c.isFunction(a))return this.each(function(d){c(this).wrapAll(a.call(this,d))});if(this[0]){var b=c(a,this[0].ownerDocument).eq(0).clone(true);this[0].parentNode&&b.insertBefore(this[0]);b.map(function(){for(var d=this;d.firstChild&&d.firstChild.nodeType===1;)d=d.firstChild;return d}).append(this)}return this}, wrapInner:function(a){if(c.isFunction(a))return this.each(function(b){c(this).wrapInner(a.call(this,b))});return this.each(function(){var b=c(this),d=b.contents();d.length?d.wrapAll(a):b.append(a)})},wrap:function(a){return this.each(function(){c(this).wrapAll(a)})},unwrap:function(){return this.parent().each(function(){c.nodeName(this,"body")||c(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,true,function(a){this.nodeType===1&&this.appendChild(a)})}, prepend:function(){return this.domManip(arguments,true,function(a){this.nodeType===1&&this.insertBefore(a,this.firstChild)})},before:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,false,function(b){this.parentNode.insertBefore(b,this)});else if(arguments.length){var a=c(arguments[0]);a.push.apply(a,this.toArray());return this.pushStack(a,"before",arguments)}},after:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,false,function(b){this.parentNode.insertBefore(b, this.nextSibling)});else if(arguments.length){var a=this.pushStack(this,"after",arguments);a.push.apply(a,c(arguments[0]).toArray());return a}},remove:function(a,b){for(var d=0,f;(f=this[d])!=null;d++)if(!a||c.filter(a,[f]).length){if(!b&&f.nodeType===1){c.cleanData(f.getElementsByTagName("*"));c.cleanData([f])}f.parentNode&&f.parentNode.removeChild(f)}return this},empty:function(){for(var a=0,b;(b=this[a])!=null;a++)for(b.nodeType===1&&c.cleanData(b.getElementsByTagName("*"));b.firstChild;)b.removeChild(b.firstChild); return this},clone:function(a){var b=this.map(function(){if(!c.support.noCloneEvent&&!c.isXMLDoc(this)){var d=this.outerHTML,f=this.ownerDocument;if(!d){d=f.createElement("div");d.appendChild(this.cloneNode(true));d=d.innerHTML}return c.clean([d.replace(Ja,"").replace(/=([^="'>\s]+\/)>/g,'="$1">').replace(V,"")],f)[0]}else return this.cloneNode(true)});if(a===true){ra(this,b);ra(this.find("*"),b.find("*"))}return b},html:function(a){if(a===w)return this[0]&&this[0].nodeType===1?this[0].innerHTML.replace(Ja, ""):null;else if(typeof a==="string"&&!ta.test(a)&&(c.support.leadingWhitespace||!V.test(a))&&!F[(La.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(Ka,Ma);try{for(var b=0,d=this.length;b<d;b++)if(this[b].nodeType===1){c.cleanData(this[b].getElementsByTagName("*"));this[b].innerHTML=a}}catch(f){this.empty().append(a)}}else c.isFunction(a)?this.each(function(e){var j=c(this),i=j.html();j.empty().append(function(){return a.call(this,e,i)})}):this.empty().append(a);return this},replaceWith:function(a){if(this[0]&& this[0].parentNode){if(c.isFunction(a))return this.each(function(b){var d=c(this),f=d.html();d.replaceWith(a.call(this,b,f))});if(typeof a!=="string")a=c(a).detach();return this.each(function(){var b=this.nextSibling,d=this.parentNode;c(this).remove();b?c(b).before(a):c(d).append(a)})}else return this.pushStack(c(c.isFunction(a)?a():a),"replaceWith",a)},detach:function(a){return this.remove(a,true)},domManip:function(a,b,d){function f(u){return c.nodeName(u,"table")?u.getElementsByTagName("tbody")[0]|| u.appendChild(u.ownerDocument.createElement("tbody")):u}var e,j,i=a[0],o=[],k;if(!c.support.checkClone&&arguments.length===3&&typeof i==="string"&&ua.test(i))return this.each(function(){c(this).domManip(a,b,d,true)});if(c.isFunction(i))return this.each(function(u){var z=c(this);a[0]=i.call(this,u,b?z.html():w);z.domManip(a,b,d)});if(this[0]){e=i&&i.parentNode;e=c.support.parentNode&&e&&e.nodeType===11&&e.childNodes.length===this.length?{fragment:e}:sa(a,this,o);k=e.fragment;if(j=k.childNodes.length=== 1?(k=k.firstChild):k.firstChild){b=b&&c.nodeName(j,"tr");for(var n=0,r=this.length;n<r;n++)d.call(b?f(this[n],j):this[n],n>0||e.cacheable||this.length>1?k.cloneNode(true):k)}o.length&&c.each(o,Qa)}return this}});c.fragments={};c.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){c.fn[a]=function(d){var f=[];d=c(d);var e=this.length===1&&this[0].parentNode;if(e&&e.nodeType===11&&e.childNodes.length===1&&d.length===1){d[b](this[0]); return this}else{e=0;for(var j=d.length;e<j;e++){var i=(e>0?this.clone(true):this).get();c.fn[b].apply(c(d[e]),i);f=f.concat(i)}return this.pushStack(f,a,d.selector)}}});c.extend({clean:function(a,b,d,f){b=b||s;if(typeof b.createElement==="undefined")b=b.ownerDocument||b[0]&&b[0].ownerDocument||s;for(var e=[],j=0,i;(i=a[j])!=null;j++){if(typeof i==="number")i+="";if(i){if(typeof i==="string"&&!jb.test(i))i=b.createTextNode(i);else if(typeof i==="string"){i=i.replace(Ka,Ma);var o=(La.exec(i)||["", ""])[1].toLowerCase(),k=F[o]||F._default,n=k[0],r=b.createElement("div");for(r.innerHTML=k[1]+i+k[2];n--;)r=r.lastChild;if(!c.support.tbody){n=ib.test(i);o=o==="table"&&!n?r.firstChild&&r.firstChild.childNodes:k[1]==="<table>"&&!n?r.childNodes:[];for(k=o.length-1;k>=0;--k)c.nodeName(o[k],"tbody")&&!o[k].childNodes.length&&o[k].parentNode.removeChild(o[k])}!c.support.leadingWhitespace&&V.test(i)&&r.insertBefore(b.createTextNode(V.exec(i)[0]),r.firstChild);i=r.childNodes}if(i.nodeType)e.push(i);else e= c.merge(e,i)}}if(d)for(j=0;e[j];j++)if(f&&c.nodeName(e[j],"script")&&(!e[j].type||e[j].type.toLowerCase()==="text/javascript"))f.push(e[j].parentNode?e[j].parentNode.removeChild(e[j]):e[j]);else{e[j].nodeType===1&&e.splice.apply(e,[j+1,0].concat(c.makeArray(e[j].getElementsByTagName("script"))));d.appendChild(e[j])}return e},cleanData:function(a){for(var b,d,f=c.cache,e=c.event.special,j=c.support.deleteExpando,i=0,o;(o=a[i])!=null;i++)if(d=o[c.expando]){b=f[d];if(b.events)for(var k in b.events)e[k]? c.event.remove(o,k):Ca(o,k,b.handle);if(j)delete o[c.expando];else o.removeAttribute&&o.removeAttribute(c.expando);delete f[d]}}});var kb=/z-?index|font-?weight|opacity|zoom|line-?height/i,Na=/alpha\([^)]*\)/,Oa=/opacity=([^)]*)/,ha=/float/i,ia=/-([a-z])/ig,lb=/([A-Z])/g,mb=/^-?\d+(?:px)?$/i,nb=/^-?\d/,ob={position:"absolute",visibility:"hidden",display:"block"},pb=["Left","Right"],qb=["Top","Bottom"],rb=s.defaultView&&s.defaultView.getComputedStyle,Pa=c.support.cssFloat?"cssFloat":"styleFloat",ja= function(a,b){return b.toUpperCase()};c.fn.css=function(a,b){return X(this,a,b,true,function(d,f,e){if(e===w)return c.curCSS(d,f);if(typeof e==="number"&&!kb.test(f))e+="px";c.style(d,f,e)})};c.extend({style:function(a,b,d){if(!a||a.nodeType===3||a.nodeType===8)return w;if((b==="width"||b==="height")&&parseFloat(d)<0)d=w;var f=a.style||a,e=d!==w;if(!c.support.opacity&&b==="opacity"){if(e){f.zoom=1;b=parseInt(d,10)+""==="NaN"?"":"alpha(opacity="+d*100+")";a=f.filter||c.curCSS(a,"filter")||"";f.filter= Na.test(a)?a.replace(Na,b):b}return f.filter&&f.filter.indexOf("opacity=")>=0?parseFloat(Oa.exec(f.filter)[1])/100+"":""}if(ha.test(b))b=Pa;b=b.replace(ia,ja);if(e)f[b]=d;return f[b]},css:function(a,b,d,f){if(b==="width"||b==="height"){var e,j=b==="width"?pb:qb;function i(){e=b==="width"?a.offsetWidth:a.offsetHeight;f!=="border"&&c.each(j,function(){f||(e-=parseFloat(c.curCSS(a,"padding"+this,true))||0);if(f==="margin")e+=parseFloat(c.curCSS(a,"margin"+this,true))||0;else e-=parseFloat(c.curCSS(a, "border"+this+"Width",true))||0})}a.offsetWidth!==0?i():c.swap(a,ob,i);return Math.max(0,Math.round(e))}return c.curCSS(a,b,d)},curCSS:function(a,b,d){var f,e=a.style;if(!c.support.opacity&&b==="opacity"&&a.currentStyle){f=Oa.test(a.currentStyle.filter||"")?parseFloat(RegExp.$1)/100+"":"";return f===""?"1":f}if(ha.test(b))b=Pa;if(!d&&e&&e[b])f=e[b];else if(rb){if(ha.test(b))b="float";b=b.replace(lb,"-$1").toLowerCase();e=a.ownerDocument.defaultView;if(!e)return null;if(a=e.getComputedStyle(a,null))f= a.getPropertyValue(b);if(b==="opacity"&&f==="")f="1"}else if(a.currentStyle){d=b.replace(ia,ja);f=a.currentStyle[b]||a.currentStyle[d];if(!mb.test(f)&&nb.test(f)){b=e.left;var j=a.runtimeStyle.left;a.runtimeStyle.left=a.currentStyle.left;e.left=d==="fontSize"?"1em":f||0;f=e.pixelLeft+"px";e.left=b;a.runtimeStyle.left=j}}return f},swap:function(a,b,d){var f={};for(var e in b){f[e]=a.style[e];a.style[e]=b[e]}d.call(a);for(e in b)a.style[e]=f[e]}});if(c.expr&&c.expr.filters){c.expr.filters.hidden=function(a){var b= a.offsetWidth,d=a.offsetHeight,f=a.nodeName.toLowerCase()==="tr";return b===0&&d===0&&!f?true:b>0&&d>0&&!f?false:c.curCSS(a,"display")==="none"};c.expr.filters.visible=function(a){return!c.expr.filters.hidden(a)}}var sb=J(),tb=/<script(.|\s)*?\/script>/gi,ub=/select|textarea/i,vb=/color|date|datetime|email|hidden|month|number|password|range|search|tel|text|time|url|week/i,N=/=\?(&|$)/,ka=/\?/,wb=/(\?|&)_=.*?(&|$)/,xb=/^(\w+:)?\/\/([^\/?#]+)/,yb=/%20/g,zb=c.fn.load;c.fn.extend({load:function(a,b,d){if(typeof a!== "string")return zb.call(this,a);else if(!this.length)return this;var f=a.indexOf(" ");if(f>=0){var e=a.slice(f,a.length);a=a.slice(0,f)}f="GET";if(b)if(c.isFunction(b)){d=b;b=null}else if(typeof b==="object"){b=c.param(b,c.ajaxSettings.traditional);f="POST"}var j=this;c.ajax({url:a,type:f,dataType:"html",data:b,complete:function(i,o){if(o==="success"||o==="notmodified")j.html(e?c("<div />").append(i.responseText.replace(tb,"")).find(e):i.responseText);d&&j.each(d,[i.responseText,o,i])}});return this}, serialize:function(){return c.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?c.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||ub.test(this.nodeName)||vb.test(this.type))}).map(function(a,b){a=c(this).val();return a==null?null:c.isArray(a)?c.map(a,function(d){return{name:b.name,value:d}}):{name:b.name,value:a}}).get()}});c.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "), function(a,b){c.fn[b]=function(d){return this.bind(b,d)}});c.extend({get:function(a,b,d,f){if(c.isFunction(b)){f=f||d;d=b;b=null}return c.ajax({type:"GET",url:a,data:b,success:d,dataType:f})},getScript:function(a,b){return c.get(a,null,b,"script")},getJSON:function(a,b,d){return c.get(a,b,d,"json")},post:function(a,b,d,f){if(c.isFunction(b)){f=f||d;d=b;b={}}return c.ajax({type:"POST",url:a,data:b,success:d,dataType:f})},ajaxSetup:function(a){c.extend(c.ajaxSettings,a)},ajaxSettings:{url:location.href, global:true,type:"GET",contentType:"application/x-www-form-urlencoded",processData:true,async:true,xhr:A.XMLHttpRequest&&(A.location.protocol!=="file:"||!A.ActiveXObject)?function(){return new A.XMLHttpRequest}:function(){try{return new A.ActiveXObject("Microsoft.XMLHTTP")}catch(a){}},accepts:{xml:"application/xml, text/xml",html:"text/html",script:"text/javascript, application/javascript",json:"application/json, text/javascript",text:"text/plain",_default:"*/*"}},lastModified:{},etag:{},ajax:function(a){function b(){e.success&& e.success.call(k,o,i,x);e.global&&f("ajaxSuccess",[x,e])}function d(){e.complete&&e.complete.call(k,x,i);e.global&&f("ajaxComplete",[x,e]);e.global&&!--c.active&&c.event.trigger("ajaxStop")}function f(q,p){(e.context?c(e.context):c.event).trigger(q,p)}var e=c.extend(true,{},c.ajaxSettings,a),j,i,o,k=a&&a.context||e,n=e.type.toUpperCase();if(e.data&&e.processData&&typeof e.data!=="string")e.data=c.param(e.data,e.traditional);if(e.dataType==="jsonp"){if(n==="GET")N.test(e.url)||(e.url+=(ka.test(e.url)? "&":"?")+(e.jsonp||"callback")+"=?");else if(!e.data||!N.test(e.data))e.data=(e.data?e.data+"&":"")+(e.jsonp||"callback")+"=?";e.dataType="json"}if(e.dataType==="json"&&(e.data&&N.test(e.data)||N.test(e.url))){j=e.jsonpCallback||"jsonp"+sb++;if(e.data)e.data=(e.data+"").replace(N,"="+j+"$1");e.url=e.url.replace(N,"="+j+"$1");e.dataType="script";A[j]=A[j]||function(q){o=q;b();d();A[j]=w;try{delete A[j]}catch(p){}z&&z.removeChild(C)}}if(e.dataType==="script"&&e.cache===null)e.cache=false;if(e.cache=== false&&n==="GET"){var r=J(),u=e.url.replace(wb,"$1_="+r+"$2");e.url=u+(u===e.url?(ka.test(e.url)?"&":"?")+"_="+r:"")}if(e.data&&n==="GET")e.url+=(ka.test(e.url)?"&":"?")+e.data;e.global&&!c.active++&&c.event.trigger("ajaxStart");r=(r=xb.exec(e.url))&&(r[1]&&r[1]!==location.protocol||r[2]!==location.host);if(e.dataType==="script"&&n==="GET"&&r){var z=s.getElementsByTagName("head")[0]||s.documentElement,C=s.createElement("script");C.src=e.url;if(e.scriptCharset)C.charset=e.scriptCharset;if(!j){var B= false;C.onload=C.onreadystatechange=function(){if(!B&&(!this.readyState||this.readyState==="loaded"||this.readyState==="complete")){B=true;b();d();C.onload=C.onreadystatechange=null;z&&C.parentNode&&z.removeChild(C)}}}z.insertBefore(C,z.firstChild);return w}var E=false,x=e.xhr();if(x){e.username?x.open(n,e.url,e.async,e.username,e.password):x.open(n,e.url,e.async);try{if(e.data||a&&a.contentType)x.setRequestHeader("Content-Type",e.contentType);if(e.ifModified){c.lastModified[e.url]&&x.setRequestHeader("If-Modified-Since", c.lastModified[e.url]);c.etag[e.url]&&x.setRequestHeader("If-None-Match",c.etag[e.url])}r||x.setRequestHeader("X-Requested-With","XMLHttpRequest");x.setRequestHeader("Accept",e.dataType&&e.accepts[e.dataType]?e.accepts[e.dataType]+", */*":e.accepts._default)}catch(ga){}if(e.beforeSend&&e.beforeSend.call(k,x,e)===false){e.global&&!--c.active&&c.event.trigger("ajaxStop");x.abort();return false}e.global&&f("ajaxSend",[x,e]);var g=x.onreadystatechange=function(q){if(!x||x.readyState===0||q==="abort"){E|| d();E=true;if(x)x.onreadystatechange=c.noop}else if(!E&&x&&(x.readyState===4||q==="timeout")){E=true;x.onreadystatechange=c.noop;i=q==="timeout"?"timeout":!c.httpSuccess(x)?"error":e.ifModified&&c.httpNotModified(x,e.url)?"notmodified":"success";var p;if(i==="success")try{o=c.httpData(x,e.dataType,e)}catch(v){i="parsererror";p=v}if(i==="success"||i==="notmodified")j||b();else c.handleError(e,x,i,p);d();q==="timeout"&&x.abort();if(e.async)x=null}};try{var h=x.abort;x.abort=function(){x&&h.call(x); g("abort")}}catch(l){}e.async&&e.timeout>0&&setTimeout(function(){x&&!E&&g("timeout")},e.timeout);try{x.send(n==="POST"||n==="PUT"||n==="DELETE"?e.data:null)}catch(m){c.handleError(e,x,null,m);d()}e.async||g();return x}},handleError:function(a,b,d,f){if(a.error)a.error.call(a.context||a,b,d,f);if(a.global)(a.context?c(a.context):c.event).trigger("ajaxError",[b,a,f])},active:0,httpSuccess:function(a){try{return!a.status&&location.protocol==="file:"||a.status>=200&&a.status<300||a.status===304||a.status=== 1223||a.status===0}catch(b){}return false},httpNotModified:function(a,b){var d=a.getResponseHeader("Last-Modified"),f=a.getResponseHeader("Etag");if(d)c.lastModified[b]=d;if(f)c.etag[b]=f;return a.status===304||a.status===0},httpData:function(a,b,d){var f=a.getResponseHeader("content-type")||"",e=b==="xml"||!b&&f.indexOf("xml")>=0;a=e?a.responseXML:a.responseText;e&&a.documentElement.nodeName==="parsererror"&&c.error("parsererror");if(d&&d.dataFilter)a=d.dataFilter(a,b);if(typeof a==="string")if(b=== "json"||!b&&f.indexOf("json")>=0)a=c.parseJSON(a);else if(b==="script"||!b&&f.indexOf("javascript")>=0)c.globalEval(a);return a},param:function(a,b){function d(i,o){if(c.isArray(o))c.each(o,function(k,n){b||/\[\]$/.test(i)?f(i,n):d(i+"["+(typeof n==="object"||c.isArray(n)?k:"")+"]",n)});else!b&&o!=null&&typeof o==="object"?c.each(o,function(k,n){d(i+"["+k+"]",n)}):f(i,o)}function f(i,o){o=c.isFunction(o)?o():o;e[e.length]=encodeURIComponent(i)+"="+encodeURIComponent(o)}var e=[];if(b===w)b=c.ajaxSettings.traditional; if(c.isArray(a)||a.jquery)c.each(a,function(){f(this.name,this.value)});else for(var j in a)d(j,a[j]);return e.join("&").replace(yb,"+")}});var la={},Ab=/toggle|show|hide/,Bb=/^([+-]=)?([\d+-.]+)(.*)$/,W,va=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]];c.fn.extend({show:function(a,b){if(a||a===0)return this.animate(K("show",3),a,b);else{a=0;for(b=this.length;a<b;a++){var d=c.data(this[a],"olddisplay"); this[a].style.display=d||"";if(c.css(this[a],"display")==="none"){d=this[a].nodeName;var f;if(la[d])f=la[d];else{var e=c("<"+d+" />").appendTo("body");f=e.css("display");if(f==="none")f="block";e.remove();la[d]=f}c.data(this[a],"olddisplay",f)}}a=0;for(b=this.length;a<b;a++)this[a].style.display=c.data(this[a],"olddisplay")||"";return this}},hide:function(a,b){if(a||a===0)return this.animate(K("hide",3),a,b);else{a=0;for(b=this.length;a<b;a++){var d=c.data(this[a],"olddisplay");!d&&d!=="none"&&c.data(this[a], "olddisplay",c.css(this[a],"display"))}a=0;for(b=this.length;a<b;a++)this[a].style.display="none";return this}},_toggle:c.fn.toggle,toggle:function(a,b){var d=typeof a==="boolean";if(c.isFunction(a)&&c.isFunction(b))this._toggle.apply(this,arguments);else a==null||d?this.each(function(){var f=d?a:c(this).is(":hidden");c(this)[f?"show":"hide"]()}):this.animate(K("toggle",3),a,b);return this},fadeTo:function(a,b,d){return this.filter(":hidden").css("opacity",0).show().end().animate({opacity:b},a,d)}, animate:function(a,b,d,f){var e=c.speed(b,d,f);if(c.isEmptyObject(a))return this.each(e.complete);return this[e.queue===false?"each":"queue"](function(){var j=c.extend({},e),i,o=this.nodeType===1&&c(this).is(":hidden"),k=this;for(i in a){var n=i.replace(ia,ja);if(i!==n){a[n]=a[i];delete a[i];i=n}if(a[i]==="hide"&&o||a[i]==="show"&&!o)return j.complete.call(this);if((i==="height"||i==="width")&&this.style){j.display=c.css(this,"display");j.overflow=this.style.overflow}if(c.isArray(a[i])){(j.specialEasing= j.specialEasing||{})[i]=a[i][1];a[i]=a[i][0]}}if(j.overflow!=null)this.style.overflow="hidden";j.curAnim=c.extend({},a);c.each(a,function(r,u){var z=new c.fx(k,j,r);if(Ab.test(u))z[u==="toggle"?o?"show":"hide":u](a);else{var C=Bb.exec(u),B=z.cur(true)||0;if(C){u=parseFloat(C[2]);var E=C[3]||"px";if(E!=="px"){k.style[r]=(u||1)+E;B=(u||1)/z.cur(true)*B;k.style[r]=B+E}if(C[1])u=(C[1]==="-="?-1:1)*u+B;z.custom(B,u,E)}else z.custom(B,u,"")}});return true})},stop:function(a,b){var d=c.timers;a&&this.queue([]); this.each(function(){for(var f=d.length-1;f>=0;f--)if(d[f].elem===this){b&&d[f](true);d.splice(f,1)}});b||this.dequeue();return this}});c.each({slideDown:K("show",1),slideUp:K("hide",1),slideToggle:K("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"}},function(a,b){c.fn[a]=function(d,f){return this.animate(b,d,f)}});c.extend({speed:function(a,b,d){var f=a&&typeof a==="object"?a:{complete:d||!d&&b||c.isFunction(a)&&a,duration:a,easing:d&&b||b&&!c.isFunction(b)&&b};f.duration=c.fx.off?0:typeof f.duration=== "number"?f.duration:c.fx.speeds[f.duration]||c.fx.speeds._default;f.old=f.complete;f.complete=function(){f.queue!==false&&c(this).dequeue();c.isFunction(f.old)&&f.old.call(this)};return f},easing:{linear:function(a,b,d,f){return d+f*a},swing:function(a,b,d,f){return(-Math.cos(a*Math.PI)/2+0.5)*f+d}},timers:[],fx:function(a,b,d){this.options=b;this.elem=a;this.prop=d;if(!b.orig)b.orig={}}});c.fx.prototype={update:function(){this.options.step&&this.options.step.call(this.elem,this.now,this);(c.fx.step[this.prop]|| c.fx.step._default)(this);if((this.prop==="height"||this.prop==="width")&&this.elem.style)this.elem.style.display="block"},cur:function(a){if(this.elem[this.prop]!=null&&(!this.elem.style||this.elem.style[this.prop]==null))return this.elem[this.prop];return(a=parseFloat(c.css(this.elem,this.prop,a)))&&a>-10000?a:parseFloat(c.curCSS(this.elem,this.prop))||0},custom:function(a,b,d){function f(j){return e.step(j)}this.startTime=J();this.start=a;this.end=b;this.unit=d||this.unit||"px";this.now=this.start; this.pos=this.state=0;var e=this;f.elem=this.elem;if(f()&&c.timers.push(f)&&!W)W=setInterval(c.fx.tick,13)},show:function(){this.options.orig[this.prop]=c.style(this.elem,this.prop);this.options.show=true;this.custom(this.prop==="width"||this.prop==="height"?1:0,this.cur());c(this.elem).show()},hide:function(){this.options.orig[this.prop]=c.style(this.elem,this.prop);this.options.hide=true;this.custom(this.cur(),0)},step:function(a){var b=J(),d=true;if(a||b>=this.options.duration+this.startTime){this.now= this.end;this.pos=this.state=1;this.update();this.options.curAnim[this.prop]=true;for(var f in this.options.curAnim)if(this.options.curAnim[f]!==true)d=false;if(d){if(this.options.display!=null){this.elem.style.overflow=this.options.overflow;a=c.data(this.elem,"olddisplay");this.elem.style.display=a?a:this.options.display;if(c.css(this.elem,"display")==="none")this.elem.style.display="block"}this.options.hide&&c(this.elem).hide();if(this.options.hide||this.options.show)for(var e in this.options.curAnim)c.style(this.elem, e,this.options.orig[e]);this.options.complete.call(this.elem)}return false}else{e=b-this.startTime;this.state=e/this.options.duration;a=this.options.easing||(c.easing.swing?"swing":"linear");this.pos=c.easing[this.options.specialEasing&&this.options.specialEasing[this.prop]||a](this.state,e,0,1,this.options.duration);this.now=this.start+(this.end-this.start)*this.pos;this.update()}return true}};c.extend(c.fx,{tick:function(){for(var a=c.timers,b=0;b<a.length;b++)a[b]()||a.splice(b--,1);a.length|| c.fx.stop()},stop:function(){clearInterval(W);W=null},speeds:{slow:600,fast:200,_default:400},step:{opacity:function(a){c.style(a.elem,"opacity",a.now)},_default:function(a){if(a.elem.style&&a.elem.style[a.prop]!=null)a.elem.style[a.prop]=(a.prop==="width"||a.prop==="height"?Math.max(0,a.now):a.now)+a.unit;else a.elem[a.prop]=a.now}}});if(c.expr&&c.expr.filters)c.expr.filters.animated=function(a){return c.grep(c.timers,function(b){return a===b.elem}).length};c.fn.offset="getBoundingClientRect"in s.documentElement? function(a){var b=this[0];if(a)return this.each(function(e){c.offset.setOffset(this,a,e)});if(!b||!b.ownerDocument)return null;if(b===b.ownerDocument.body)return c.offset.bodyOffset(b);var d=b.getBoundingClientRect(),f=b.ownerDocument;b=f.body;f=f.documentElement;return{top:d.top+(self.pageYOffset||c.support.boxModel&&f.scrollTop||b.scrollTop)-(f.clientTop||b.clientTop||0),left:d.left+(self.pageXOffset||c.support.boxModel&&f.scrollLeft||b.scrollLeft)-(f.clientLeft||b.clientLeft||0)}}:function(a){var b= this[0];if(a)return this.each(function(r){c.offset.setOffset(this,a,r)});if(!b||!b.ownerDocument)return null;if(b===b.ownerDocument.body)return c.offset.bodyOffset(b);c.offset.initialize();var d=b.offsetParent,f=b,e=b.ownerDocument,j,i=e.documentElement,o=e.body;f=(e=e.defaultView)?e.getComputedStyle(b,null):b.currentStyle;for(var k=b.offsetTop,n=b.offsetLeft;(b=b.parentNode)&&b!==o&&b!==i;){if(c.offset.supportsFixedPosition&&f.position==="fixed")break;j=e?e.getComputedStyle(b,null):b.currentStyle; k-=b.scrollTop;n-=b.scrollLeft;if(b===d){k+=b.offsetTop;n+=b.offsetLeft;if(c.offset.doesNotAddBorder&&!(c.offset.doesAddBorderForTableAndCells&&/^t(able|d|h)$/i.test(b.nodeName))){k+=parseFloat(j.borderTopWidth)||0;n+=parseFloat(j.borderLeftWidth)||0}f=d;d=b.offsetParent}if(c.offset.subtractsBorderForOverflowNotVisible&&j.overflow!=="visible"){k+=parseFloat(j.borderTopWidth)||0;n+=parseFloat(j.borderLeftWidth)||0}f=j}if(f.position==="relative"||f.position==="static"){k+=o.offsetTop;n+=o.offsetLeft}if(c.offset.supportsFixedPosition&& f.position==="fixed"){k+=Math.max(i.scrollTop,o.scrollTop);n+=Math.max(i.scrollLeft,o.scrollLeft)}return{top:k,left:n}};c.offset={initialize:function(){var a=s.body,b=s.createElement("div"),d,f,e,j=parseFloat(c.curCSS(a,"marginTop",true))||0;c.extend(b.style,{position:"absolute",top:0,left:0,margin:0,border:0,width:"1px",height:"1px",visibility:"hidden"});b.innerHTML="<div style='position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;'><div></div></div><table style='position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;' cellpadding='0' cellspacing='0'><tr><td></td></tr></table>"; a.insertBefore(b,a.firstChild);d=b.firstChild;f=d.firstChild;e=d.nextSibling.firstChild.firstChild;this.doesNotAddBorder=f.offsetTop!==5;this.doesAddBorderForTableAndCells=e.offsetTop===5;f.style.position="fixed";f.style.top="20px";this.supportsFixedPosition=f.offsetTop===20||f.offsetTop===15;f.style.position=f.style.top="";d.style.overflow="hidden";d.style.position="relative";this.subtractsBorderForOverflowNotVisible=f.offsetTop===-5;this.doesNotIncludeMarginInBodyOffset=a.offsetTop!==j;a.removeChild(b); c.offset.initialize=c.noop},bodyOffset:function(a){var b=a.offsetTop,d=a.offsetLeft;c.offset.initialize();if(c.offset.doesNotIncludeMarginInBodyOffset){b+=parseFloat(c.curCSS(a,"marginTop",true))||0;d+=parseFloat(c.curCSS(a,"marginLeft",true))||0}return{top:b,left:d}},setOffset:function(a,b,d){if(/static/.test(c.curCSS(a,"position")))a.style.position="relative";var f=c(a),e=f.offset(),j=parseInt(c.curCSS(a,"top",true),10)||0,i=parseInt(c.curCSS(a,"left",true),10)||0;if(c.isFunction(b))b=b.call(a, d,e);d={top:b.top-e.top+j,left:b.left-e.left+i};"using"in b?b.using.call(a,d):f.css(d)}};c.fn.extend({position:function(){if(!this[0])return null;var a=this[0],b=this.offsetParent(),d=this.offset(),f=/^body|html$/i.test(b[0].nodeName)?{top:0,left:0}:b.offset();d.top-=parseFloat(c.curCSS(a,"marginTop",true))||0;d.left-=parseFloat(c.curCSS(a,"marginLeft",true))||0;f.top+=parseFloat(c.curCSS(b[0],"borderTopWidth",true))||0;f.left+=parseFloat(c.curCSS(b[0],"borderLeftWidth",true))||0;return{top:d.top- f.top,left:d.left-f.left}},offsetParent:function(){return this.map(function(){for(var a=this.offsetParent||s.body;a&&!/^body|html$/i.test(a.nodeName)&&c.css(a,"position")==="static";)a=a.offsetParent;return a})}});c.each(["Left","Top"],function(a,b){var d="scroll"+b;c.fn[d]=function(f){var e=this[0],j;if(!e)return null;if(f!==w)return this.each(function(){if(j=wa(this))j.scrollTo(!a?f:c(j).scrollLeft(),a?f:c(j).scrollTop());else this[d]=f});else return(j=wa(e))?"pageXOffset"in j?j[a?"pageYOffset": "pageXOffset"]:c.support.boxModel&&j.document.documentElement[d]||j.document.body[d]:e[d]}});c.each(["Height","Width"],function(a,b){var d=b.toLowerCase();c.fn["inner"+b]=function(){return this[0]?c.css(this[0],d,false,"padding"):null};c.fn["outer"+b]=function(f){return this[0]?c.css(this[0],d,false,f?"margin":"border"):null};c.fn[d]=function(f){var e=this[0];if(!e)return f==null?null:this;if(c.isFunction(f))return this.each(function(j){var i=c(this);i[d](f.call(this,j,i[d]()))});return"scrollTo"in e&&e.document?e.document.compatMode==="CSS1Compat"&&e.document.documentElement["client"+b]||e.document.body["client"+b]:e.nodeType===9?Math.max(e.documentElement["client"+b],e.body["scroll"+b],e.documentElement["scroll"+b],e.body["offset"+b],e.documentElement["offset"+b]):f===w?c.css(e,d):this.css(d,typeof f==="string"?f:f+"px")}});A.jQuery=A.$=c})(window);
src/widgets/containers/PetitionWidget.js
iris-dni/iris-frontend
import React from 'react'; import Helmet from 'react-helmet'; import { connect } from 'react-redux'; import { fetchPetition } from 'actions/PetitionActions'; import getPetitionSchema from 'selectors/petitionSchema'; import getPetitionMetaData from 'helpers/getPetitionMetaData'; import PetitionWidget from 'widgets/components/PetitionWidget'; import getPetitionWidget from 'widgets/selectors/petitionWidget'; const PetitionWidgetContainer = ({ petition, widget }) => ( <div> <Helmet title={petition.title} meta={petition.meta} script={[{ 'type': 'application/ld+json', 'innerHTML': JSON.stringify(petition.schema || {}) }]} /> <PetitionWidget {...widget} /> </div> ); PetitionWidgetContainer.fetchData = ({ store, params }) => { return store.dispatch(fetchPetition(params.id)); }; export const mapStateToProps = ({ petition }) => ({ petition: { title: petition.title, meta: getPetitionMetaData(petition), schema: getPetitionSchema(petition) }, widget: getPetitionWidget(petition) }); PetitionWidgetContainer.propTypes = { petition: React.PropTypes.shape({ title: React.PropTypes.string.isRequired, meta: React.PropTypes.array.isRequired, schema: React.PropTypes.object.isRequired }), widget: React.PropTypes.shape({ id: React.PropTypes.string.isRequired, title: React.PropTypes.string.isRequired, link: React.PropTypes.string.isRequired, byline: React.PropTypes.string.isRequired, image: React.PropTypes.object, stats: React.PropTypes.object.isRequired, progress: React.PropTypes.object.isRequired, tags: React.PropTypes.object.isRequired }) }; export default connect( mapStateToProps )(PetitionWidgetContainer);
src/components/footer.js
ahmadabugosh/client-react
//class based component import React, { Component } from 'react'; import { connect } from 'react-redux'; import { Link } from 'react-router-dom'; class Footer extends Component { render() { return ( <footer className="footer"> <span className="text-muted">Need help? Send us a message at: <a href="mailto:[email protected]">[email protected]</a> | ©2018 i7san</span> </footer> ); } } function mapStateToProps(state) { return { authenticated: state.auth.authenticated }; } export default connect(mapStateToProps)(Footer); // export plain unconnected component for testing export { Footer };
src/index.js
Theadd/endless-chartist
import React from 'react' import App from './app' React.render(<App />, document.getElementById('root'))
ajax/libs/babel-core/4.6.1/browser.js
yinghunglai/cdnjs
(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.babel=f()}})(function(){var define,module,exports;return function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s}({1:[function(require,module,exports){(function(global){"use strict";var transform=module.exports=require("../transformation");transform.version=require("../../../package").version;transform.transform=transform;transform.run=function(code){var opts=arguments[1]===undefined?{}:arguments[1];opts.sourceMap="inline";return new Function(transform(code,opts).code)()};transform.load=function(url,callback,_x,hold){var opts=arguments[2]===undefined?{}:arguments[2];var _opts=opts;if(!_opts.filename)_opts.filename=url;var xhr=global.ActiveXObject?new global.ActiveXObject("Microsoft.XMLHTTP"):new global.XMLHttpRequest;xhr.open("GET",url,true);if("overrideMimeType"in xhr)xhr.overrideMimeType("text/plain");xhr.onreadystatechange=function(){if(xhr.readyState!==4)return;var status=xhr.status;if(status===0||status===200){var param=[xhr.responseText,opts];if(!hold)transform.run.apply(transform,param);if(callback)callback(param)}else{throw new Error("Could not load "+url)}};xhr.send(null)};var runScripts=function runScripts(){var scripts=[];var types=["text/ecmascript-6","text/6to5","text/babel","module"];var index=0;var exec=function(_exec){var _execWrapper=function exec(){return _exec.apply(this,arguments)};_execWrapper.toString=function(){return _exec.toString()};return _execWrapper}(function(){var param=scripts[index];if(param instanceof Array){transform.run.apply(transform,param);index++;exec()}});var run=function run(script,i){var opts={};if(script.src){transform.load(script.src,function(param){scripts[i]=param;exec()},opts,true)}else{opts.filename="embedded";scripts[i]=[script.innerHTML,opts]}};var _scripts=global.document.getElementsByTagName("script");for(var i=0;i<_scripts.length;++i){var _script=_scripts[i];if(types.indexOf(_script.type)>=0)scripts.push(_script)}for(i in scripts){run(scripts[i],i)}exec()};if(global.addEventListener){global.addEventListener("DOMContentLoaded",runScripts,false)}else if(global.attachEvent){global.attachEvent("onload",runScripts)}}).call(this,typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{})},{"../../../package":342,"../transformation":43}],2:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var repeating=_interopRequire(require("repeating"));var trimRight=_interopRequire(require("trim-right"));var isBoolean=_interopRequire(require("lodash/lang/isBoolean"));var includes=_interopRequire(require("lodash/collection/includes"));var isNumber=_interopRequire(require("lodash/lang/isNumber"));var Buffer=function(){function Buffer(position,format){_classCallCheck(this,Buffer);this.position=position;this._indent=format.indent.base;this.format=format;this.buf=""}Buffer.prototype.get=function get(){return trimRight(this.buf)};Buffer.prototype.getIndent=function getIndent(){if(this.format.compact||this.format.concise){return""}else{return repeating(this.format.indent.style,this._indent)}};Buffer.prototype.indentSize=function indentSize(){return this.getIndent().length};Buffer.prototype.indent=function indent(){this._indent++};Buffer.prototype.dedent=function dedent(){this._indent--};Buffer.prototype.semicolon=function semicolon(){this.push(";")};Buffer.prototype.ensureSemicolon=function ensureSemicolon(){if(!this.isLast(";"))this.semicolon()};Buffer.prototype.rightBrace=function rightBrace(){this.newline(true);this.push("}")};Buffer.prototype.keyword=function keyword(name){this.push(name);this.space()};Buffer.prototype.space=function space(){if(this.format.compact)return;if(this.buf&&!this.isLast(" ")&&!this.isLast("\n")){this.push(" ")}};Buffer.prototype.removeLast=function removeLast(cha){if(this.format.compact)return;if(!this.isLast(cha))return;this.buf=this.buf.substr(0,this.buf.length-1);this.position.unshift(cha)};Buffer.prototype.newline=function newline(i,removeLast){if(this.format.compact)return;if(this.format.concise){this.space();return}if(!removeLast)removeLast=false;if(isNumber(i)){i=Math.min(2,i);if(this.endsWith("{\n")||this.endsWith(":\n"))i--;if(i<=0)return;while(i>0){this._newline(removeLast);i--}return}if(isBoolean(i)){removeLast=i}this._newline(removeLast)};Buffer.prototype._newline=function _newline(removeLast){if(this.endsWith("\n\n"))return;if(removeLast&&this.isLast("\n"))this.removeLast("\n");this.removeLast(" ");this._removeSpacesAfterLastNewline();this._push("\n")};Buffer.prototype._removeSpacesAfterLastNewline=function _removeSpacesAfterLastNewline(){var lastNewlineIndex=this.buf.lastIndexOf("\n");if(lastNewlineIndex===-1)return;var index=this.buf.length-1;while(index>lastNewlineIndex){if(this.buf[index]!==" "){break}index--}if(index===lastNewlineIndex){this.buf=this.buf.substring(0,index+1)}};Buffer.prototype.push=function push(str,noIndent){if(!this.format.compact&&this._indent&&!noIndent&&str!=="\n"){var indent=this.getIndent();str=str.replace(/\n/g,"\n"+indent);if(this.isLast("\n"))this._push(indent)}this._push(str)};Buffer.prototype._push=function _push(str){this.position.push(str);this.buf+=str};Buffer.prototype.endsWith=function endsWith(str){return this.buf.slice(-str.length)===str};Buffer.prototype.isLast=function isLast(cha){if(this.format.compact)return false;var buf=this.buf;var last=buf[buf.length-1];if(Array.isArray(cha)){return includes(cha,last)}else{return cha===last}};return Buffer}();module.exports=Buffer},{"lodash/collection/includes":204,"lodash/lang/isBoolean":288,"lodash/lang/isNumber":292,repeating:325,"trim-right":341}],3:[function(require,module,exports){"use strict";exports.File=File;exports.Program=Program;exports.BlockStatement=BlockStatement;function File(node,print){print(node.program)}function Program(node,print){print.sequence(node.body)}function BlockStatement(node,print){if(node.body.length===0){this.push("{}")}else{this.push("{");this.newline();print.sequence(node.body,{indent:true});this.removeLast("\n");this.rightBrace()}}exports.__esModule=true},{}],4:[function(require,module,exports){"use strict";exports.ClassBody=ClassBody;exports.MethodDefinition=MethodDefinition;exports.ClassExpression=exports.ClassDeclaration=function(node,print){this.push("class");if(node.id){this.space();print(node.id)}if(node.superClass){this.push(" extends ");print(node.superClass)}this.space();print(node.body)};function ClassBody(node,print){if(node.body.length===0){this.push("{}")}else{this.push("{");this.newline();this.indent();print.sequence(node.body);this.dedent();this.rightBrace()}}function MethodDefinition(node,print){if(node["static"]){this.push("static ")}this._method(node,print)}exports.__esModule=true},{}],5:[function(require,module,exports){"use strict";exports.ComprehensionBlock=ComprehensionBlock;exports.ComprehensionExpression=ComprehensionExpression;function ComprehensionBlock(node,print){this.keyword("for");this.push("(");print(node.left);this.push(" of ");print(node.right);this.push(")")}function ComprehensionExpression(node,print){this.push(node.generator?"(":"[");print.join(node.blocks,{separator:" "});this.space();if(node.filter){this.keyword("if");this.push("(");print(node.filter);this.push(")");this.space()}print(node.body);this.push(node.generator?")":"]")}exports.__esModule=true},{}],6:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.UnaryExpression=UnaryExpression;exports.UpdateExpression=UpdateExpression;exports.ConditionalExpression=ConditionalExpression;exports.NewExpression=NewExpression;exports.SequenceExpression=SequenceExpression;exports.ThisExpression=ThisExpression;exports.CallExpression=CallExpression;exports.EmptyStatement=EmptyStatement;exports.ExpressionStatement=ExpressionStatement;exports.MemberExpression=MemberExpression;var isInteger=_interopRequire(require("is-integer"));var isNumber=_interopRequire(require("lodash/lang/isNumber"));var t=_interopRequire(require("../../types"));function UnaryExpression(node,print){var hasSpace=/[a-z]$/.test(node.operator);var arg=node.argument;if(t.isUpdateExpression(arg)||t.isUnaryExpression(arg)){hasSpace=true}if(t.isUnaryExpression(arg)&&arg.operator==="!"){hasSpace=false}this.push(node.operator);if(hasSpace)this.push(" ");print(node.argument)}function UpdateExpression(node,print){if(node.prefix){this.push(node.operator);print(node.argument)}else{print(node.argument);this.push(node.operator)}}function ConditionalExpression(node,print){print(node.test);this.space();this.push("?");this.space();print(node.consequent);this.space();this.push(":");this.space();print(node.alternate)}function NewExpression(node,print){this.push("new ");print(node.callee);this.push("(");print.list(node.arguments);this.push(")")}function SequenceExpression(node,print){print.list(node.expressions)}function ThisExpression(){this.push("this")}function CallExpression(node,print){print(node.callee);this.push("(");var separator=",";if(node._prettyCall){separator+="\n";this.newline();this.indent()}else{separator+=" "}print.list(node.arguments,{separator:separator});if(node._prettyCall){this.newline();this.dedent()}this.push(")")}var buildYieldAwait=function buildYieldAwait(keyword){return function(node,print){this.push(keyword);if(node.delegate||node.all){this.push("*")}if(node.argument){this.space();print(node.argument)}}};var YieldExpression=exports.YieldExpression=buildYieldAwait("yield");var AwaitExpression=exports.AwaitExpression=buildYieldAwait("await");function EmptyStatement(){this.semicolon()}function ExpressionStatement(node,print){print(node.expression);this.semicolon()}exports.BinaryExpression=exports.LogicalExpression=exports.AssignmentPattern=exports.AssignmentExpression=function(node,print){print(node.left);this.push(" ");this.push(node.operator);this.push(" ");print(node.right)};var SCIENTIFIC_NOTATION=/e/i;function MemberExpression(node,print){var obj=node.object;print(obj);if(!node.computed&&t.isMemberExpression(node.property)){throw new TypeError("Got a MemberExpression for MemberExpression property")}var computed=node.computed;if(t.isLiteral(node.property)&&isNumber(node.property.value)){computed=true}if(computed){this.push("[");print(node.property);this.push("]")}else{if(t.isLiteral(obj)&&isInteger(obj.value)&&!SCIENTIFIC_NOTATION.test(obj.value.toString())){this.push(".")}this.push(".");print(node.property)}}exports.__esModule=true},{"../../types":122,"is-integer":188,"lodash/lang/isNumber":292}],7:[function(require,module,exports){"use strict";exports.AnyTypeAnnotation=exports.ArrayTypeAnnotation=exports.BooleanTypeAnnotation=exports.ClassProperty=exports.DeclareClass=exports.DeclareFunction=exports.DeclareModule=exports.DeclareVariable=exports.FunctionTypeAnnotation=exports.FunctionTypeParam=exports.GenericTypeAnnotation=exports.InterfaceExtends=exports.InterfaceDeclaration=exports.IntersectionTypeAnnotation=exports.NullableTypeAnnotation=exports.NumberTypeAnnotation=exports.StringLiteralTypeAnnotation=exports.StringTypeAnnotation=exports.TupleTypeAnnotation=exports.TypeofTypeAnnotation=exports.TypeAlias=exports.TypeAnnotation=exports.TypeParameterDeclaration=exports.TypeParameterInstantiation=exports.ObjectTypeAnnotation=exports.ObjectTypeCallProperty=exports.ObjectTypeIndexer=exports.ObjectTypeProperty=exports.QualifiedTypeIdentifier=exports.UnionTypeAnnotation=exports.TypeCastExpression=exports.VoidTypeAnnotation=function(){}},{}],8:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.JSXAttribute=JSXAttribute;exports.JSXIdentifier=JSXIdentifier;exports.JSXNamespacedName=JSXNamespacedName;exports.JSXMemberExpression=JSXMemberExpression;exports.JSXSpreadAttribute=JSXSpreadAttribute;exports.JSXExpressionContainer=JSXExpressionContainer;exports.JSXElement=JSXElement;exports.JSXOpeningElement=JSXOpeningElement;exports.JSXClosingElement=JSXClosingElement;exports.JSXEmptyExpression=JSXEmptyExpression;var each=_interopRequire(require("lodash/collection/each"));var t=_interopRequire(require("../../types"));function JSXAttribute(node,print){print(node.name);if(node.value){this.push("=");print(node.value)}}function JSXIdentifier(node){this.push(node.name)}function JSXNamespacedName(node,print){print(node.namespace);this.push(":");print(node.name)}function JSXMemberExpression(node,print){print(node.object);this.push(".");print(node.property)}function JSXSpreadAttribute(node,print){this.push("{...");print(node.argument);this.push("}")}function JSXExpressionContainer(node,print){this.push("{");print(node.expression);this.push("}")}function JSXElement(node,print){var _this=this;var open=node.openingElement;print(open);if(open.selfClosing)return;this.indent();each(node.children,function(child){if(t.isLiteral(child)){_this.push(child.value)}else{print(child)}});this.dedent();print(node.closingElement)}function JSXOpeningElement(node,print){this.push("<");print(node.name);if(node.attributes.length>0){this.push(" ");print.join(node.attributes,{separator:" "})}this.push(node.selfClosing?" />":">")}function JSXClosingElement(node,print){this.push("</");print(node.name);this.push(">")}function JSXEmptyExpression(){}exports.__esModule=true},{"../../types":122,"lodash/collection/each":201}],9:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports._params=_params;exports._method=_method;exports.ArrowFunctionExpression=ArrowFunctionExpression;var t=_interopRequire(require("../../types"));function _params(node,print){this.push("(");print.list(node.params);this.push(")")}function _method(node,print){var value=node.value;var kind=node.kind;var key=node.key;if(!kind||kind==="init"){if(value.generator){this.push("*")}}else{this.push(kind+" ")}if(value.async)this.push("async ");if(node.computed){this.push("[");print(key);this.push("]")}else{print(key)}this._params(value,print);this.push(" ");print(value.body)}exports.FunctionDeclaration=exports.FunctionExpression=function(node,print){if(node.async)this.push("async ");this.push("function");if(node.generator)this.push("*");if(node.id){this.push(" ");print(node.id)}else{this.space()}this._params(node,print);this.space();print(node.body)};function ArrowFunctionExpression(node,print){if(node.async)this.push("async ");if(node.params.length===1&&t.isIdentifier(node.params[0])){print(node.params[0])}else{this._params(node,print)}this.push(" => ");print(node.body)}exports.__esModule=true},{"../../types":122}],10:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.ImportSpecifier=ImportSpecifier;exports.ExportSpecifier=ExportSpecifier;exports.ExportBatchSpecifier=ExportBatchSpecifier;exports.ExportDeclaration=ExportDeclaration;exports.ImportDeclaration=ImportDeclaration;exports.ImportBatchSpecifier=ImportBatchSpecifier;var each=_interopRequire(require("lodash/collection/each"));var t=_interopRequire(require("../../types"));function ImportSpecifier(node,print){if(t.isSpecifierDefault(node)){print(t.getSpecifierName(node))}else{return exports.ExportSpecifier.apply(this,arguments)}}function ExportSpecifier(node,print){print(node.id);if(node.name){this.push(" as ");print(node.name)}}function ExportBatchSpecifier(){this.push("*")}function ExportDeclaration(node,print){this.push("export ");var specifiers=node.specifiers;if(node["default"]){this.push("default ")}if(node.declaration){print(node.declaration);if(t.isStatement(node.declaration))return}else{if(specifiers.length===1&&t.isExportBatchSpecifier(specifiers[0])){print(specifiers[0])}else{this.push("{");if(specifiers.length){this.space();print.join(specifiers,{separator:", "});this.space()}this.push("}")}if(node.source){this.push(" from ");print(node.source)}}this.ensureSemicolon()}function ImportDeclaration(node,print){var _this=this;this.push("import ");if(node.isType){this.push("type ")}var specfiers=node.specifiers;if(specfiers&&specfiers.length){var foundImportSpecifier=false;each(node.specifiers,function(spec,i){if(+i>0){_this.push(", ")}var isDefault=t.isSpecifierDefault(spec);if(!isDefault&&spec.type!=="ImportBatchSpecifier"&&!foundImportSpecifier){foundImportSpecifier=true;_this.push("{ ")}print(spec)});if(foundImportSpecifier){this.push(" }")}this.push(" from ")}print(node.source);this.semicolon()}function ImportBatchSpecifier(node,print){this.push("* as ");print(node.name)}exports.__esModule=true},{"../../types":122,"lodash/collection/each":201}],11:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var each=_interopRequire(require("lodash/collection/each"));each(["BindMemberExpression","BindFunctionExpression"],function(type){exports[type]=function(){throw new ReferenceError("Trying to render non-standard playground node "+JSON.stringify(type))}})},{"lodash/collection/each":201}],12:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.WithStatement=WithStatement;exports.IfStatement=IfStatement;exports.ForStatement=ForStatement;exports.WhileStatement=WhileStatement;exports.DoWhileStatement=DoWhileStatement;exports.LabeledStatement=LabeledStatement;exports.TryStatement=TryStatement;exports.CatchClause=CatchClause;exports.ThrowStatement=ThrowStatement;exports.SwitchStatement=SwitchStatement;exports.SwitchCase=SwitchCase;exports.DebuggerStatement=DebuggerStatement;exports.VariableDeclaration=VariableDeclaration;exports.PrivateDeclaration=PrivateDeclaration;exports.VariableDeclarator=VariableDeclarator;var repeating=_interopRequire(require("repeating"));var t=_interopRequire(require("../../types"));function WithStatement(node,print){this.keyword("with");this.push("(");print(node.object);this.push(")");print.block(node.body)}function IfStatement(node,print){this.keyword("if");this.push("(");print(node.test);this.push(")");this.space();print.indentOnComments(node.consequent);if(node.alternate){if(this.isLast("}"))this.space();this.push("else ");print.indentOnComments(node.alternate)}}function ForStatement(node,print){this.keyword("for");this.push("(");print(node.init);this.push(";");if(node.test){this.push(" ");print(node.test)}this.push(";");if(node.update){this.push(" ");print(node.update)}this.push(")");print.block(node.body)}function WhileStatement(node,print){this.keyword("while");this.push("(");print(node.test);this.push(")");print.block(node.body)}var buildForXStatement=function buildForXStatement(op){return function(node,print){this.keyword("for");this.push("(");print(node.left);this.push(" "+op+" ");print(node.right);this.push(")");print.block(node.body)}};var ForInStatement=exports.ForInStatement=buildForXStatement("in");var ForOfStatement=exports.ForOfStatement=buildForXStatement("of");function DoWhileStatement(node,print){this.keyword("do");print(node.body);this.space();this.keyword("while");this.push("(");print(node.test);this.push(");")}var buildLabelStatement=function buildLabelStatement(prefix,key){return function(node,print){this.push(prefix);var label=node[key||"label"];if(label){this.push(" ");print(label)}this.semicolon()}};var ContinueStatement=exports.ContinueStatement=buildLabelStatement("continue");var ReturnStatement=exports.ReturnStatement=buildLabelStatement("return","argument");var BreakStatement=exports.BreakStatement=buildLabelStatement("break");function LabeledStatement(node,print){print(node.label);this.push(": ");print(node.body)}function TryStatement(node,print){this.keyword("try");print(node.block);this.space();if(node.handlers){print(node.handlers[0])}else{print(node.handler)}if(node.finalizer){this.space();this.push("finally ");print(node.finalizer)}}function CatchClause(node,print){this.keyword("catch");this.push("(");print(node.param);this.push(") ");print(node.body)}function ThrowStatement(node,print){this.push("throw ");print(node.argument);this.semicolon()}function SwitchStatement(node,print){this.keyword("switch");this.push("(");print(node.discriminant);this.push(")");this.space();this.push("{");print.sequence(node.cases,{indent:true,addNewlines:function addNewlines(leading,cas){if(!leading&&node.cases[node.cases.length-1]===cas)return-1}});this.push("}")}function SwitchCase(node,print){if(node.test){this.push("case ");print(node.test);this.push(":")}else{this.push("default:")}if(node.consequent.length){this.newline();print.sequence(node.consequent,{indent:true})}}function DebuggerStatement(){this.push("debugger;")}function VariableDeclaration(node,print,parent){this.push(node.kind+" ");var hasInits=false;if(!t.isFor(parent)){for(var i=0;i<node.declarations.length;i++){if(node.declarations[i].init){hasInits=true}}}var sep=",";if(!this.format.compact&&hasInits){sep+="\n"+repeating(" ",node.kind.length+1)}else{sep+=" "}print.list(node.declarations,{separator:sep});if(!t.isFor(parent)){this.semicolon()}}function PrivateDeclaration(node,print){this.push("private ");print.join(node.declarations,{separator:", "});this.semicolon()}function VariableDeclarator(node,print){if(node.init){print(node.id);this.space();this.push("=");this.space();print(node.init)}else{print(node.id)}}exports.__esModule=true},{"../../types":122,repeating:325}],13:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.TaggedTemplateExpression=TaggedTemplateExpression;exports.TemplateElement=TemplateElement;exports.TemplateLiteral=TemplateLiteral;var each=_interopRequire(require("lodash/collection/each"));function TaggedTemplateExpression(node,print){print(node.tag);print(node.quasi)}function TemplateElement(node){this._push(node.value.raw)}function TemplateLiteral(node,print){var _this=this;this.push("`");var quasis=node.quasis;var len=quasis.length;each(quasis,function(quasi,i){print(quasi);if(i+1<len){_this.push("${ ");print(node.expressions[i]);_this.push(" }")}});this._push("`")}exports.__esModule=true},{"lodash/collection/each":201}],14:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.Identifier=Identifier;exports.VirtualPropertyExpression=VirtualPropertyExpression;exports.Property=Property;exports.Literal=Literal;var each=_interopRequire(require("lodash/collection/each"));function Identifier(node){this.push(node.name)}exports.RestElement=exports.SpreadElement=exports.SpreadProperty=function(node,print){this.push("...");print(node.argument)};function VirtualPropertyExpression(node,print){print(node.object);this.push("::");print(node.property)}exports.ObjectExpression=exports.ObjectPattern=function(node,print){var props=node.properties;if(props.length){this.push("{");this.space();print.list(props,{indent:true});this.space();this.push("}")}else{this.push("{}")}};function Property(node,print){if(node.method||node.kind==="get"||node.kind==="set"){this._method(node,print)}else{if(node.computed){this.push("[");print(node.key);this.push("]")}else{print(node.key);if(node.shorthand)return}this.push(":");this.space();print(node.value)}}exports.ArrayExpression=exports.ArrayPattern=function(node,print){var _this=this;var elems=node.elements;var len=elems.length;this.push("[");each(elems,function(elem,i){if(!elem){_this.push(",")}else{if(i>0)_this.push(" ");print(elem);if(i<len-1)_this.push(",")}});this.push("]")};function Literal(node){var val=node.value;var type=typeof val;if(type==="string"){val=JSON.stringify(val);val=val.replace(/[\u000A\u000D\u2028\u2029]/g,function(c){return"\\u"+("0000"+c.charCodeAt(0).toString(16)).slice(-4)});this.push(val)}else if(type==="number"){this.push(val+"")}else if(type==="boolean"){this.push(val?"true":"false")}else if(node.regex){this.push("/"+node.regex.pattern+"/"+node.regex.flags)}else if(val===null){this.push("null")}}exports.__esModule=true},{"lodash/collection/each":201}],15:[function(require,module,exports){"use strict";var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var detectIndent=_interopRequire(require("detect-indent"));var Whitespace=_interopRequire(require("./whitespace"));var repeating=_interopRequire(require("repeating"));var SourceMap=_interopRequire(require("./source-map"));var Position=_interopRequire(require("./position"));var messages=_interopRequireWildcard(require("../messages"));var Buffer=_interopRequire(require("./buffer"));var extend=_interopRequire(require("lodash/object/extend"));var each=_interopRequire(require("lodash/collection/each"));var n=_interopRequire(require("./node"));var t=_interopRequire(require("../types"));var CodeGenerator=function(){function CodeGenerator(ast,opts,code){_classCallCheck(this,CodeGenerator);if(!opts)opts={};this.comments=ast.comments||[];this.tokens=ast.tokens||[];this.format=CodeGenerator.normalizeOptions(code,opts);this.opts=opts;this.ast=ast;this.whitespace=new Whitespace(this.tokens,this.comments,this.format);this.position=new Position;this.map=new SourceMap(this.position,opts,code);this.buffer=new Buffer(this.position,this.format)}CodeGenerator.normalizeOptions=function normalizeOptions(code,opts){var style=" ";if(code){var indent=detectIndent(code).indent;if(indent&&indent!==" ")style=indent}var format={comments:opts.comments==null||opts.comments,compact:opts.compact,indent:{adjustMultilineComment:true,style:style,base:0}};if(format.compact==="auto"){format.compact=code.length>1e5;if(format.compact){console.error(messages.get("codeGeneratorDeopt",opts.filename,"100KB"))}}return format};CodeGenerator.generators={templateLiterals:require("./generators/template-literals"),comprehensions:require("./generators/comprehensions"),expressions:require("./generators/expressions"),statements:require("./generators/statements"),playground:require("./generators/playground"),classes:require("./generators/classes"),methods:require("./generators/methods"),modules:require("./generators/modules"),types:require("./generators/types"),flow:require("./generators/flow"),base:require("./generators/base"),jsx:require("./generators/jsx")};CodeGenerator.prototype.generate=function generate(){var ast=this.ast;this.print(ast);var comments=[];each(ast.comments,function(comment){if(!comment._displayed)comments.push(comment)});this._printComments(comments);return{map:this.map.get(),code:this.buffer.get()}};CodeGenerator.prototype.buildPrint=function buildPrint(parent){var _this=this;var print=function(node,opts){return _this.print(node,parent,opts)};print.sequence=function(nodes){var opts=arguments[1]===undefined?{}:arguments[1];opts.statement=true;return _this.printJoin(print,nodes,opts)};print.join=function(nodes,opts){return _this.printJoin(print,nodes,opts)};print.list=function(items){var opts=arguments[1]===undefined?{}:arguments[1];var _opts=opts;if(!_opts.separator)_opts.separator=", ";print.join(items,opts)};print.block=function(node){return _this.printBlock(print,node)};print.indentOnComments=function(node){return _this.printAndIndentOnComments(print,node)};return print};CodeGenerator.prototype.print=function print(node,parent){var _this=this;var opts=arguments[2]===undefined?{}:arguments[2];if(!node)return"";if(parent&&parent._compact){node._compact=true}var oldConcise=this.format.concise;if(node._compact){this.format.concise=true}var newline=function(leading){if(!opts.statement&&!n.isUserWhitespacable(node,parent)){return}var lines=0;if(node.start!=null&&!node._ignoreUserWhitespace){if(leading){lines=_this.whitespace.getNewlinesBefore(node)}else{lines=_this.whitespace.getNewlinesAfter(node)}}else{if(!leading)lines++;if(opts.addNewlines)lines+=opts.addNewlines(leading,node)||0;var needs=n.needsWhitespaceAfter;if(leading)needs=n.needsWhitespaceBefore;if(needs(node,parent))lines++;if(!_this.buffer.buf)lines=0}_this.newline(lines)};if(this[node.type]){var needsNoLineTermParens=n.needsParensNoLineTerminator(node,parent);var needsParens=needsNoLineTermParens||n.needsParens(node,parent);if(needsParens)this.push("(");if(needsNoLineTermParens)this.indent();this.printLeadingComments(node,parent);newline(true);if(opts.before)opts.before();this.map.mark(node,"start");this[node.type](node,this.buildPrint(node),parent);if(needsNoLineTermParens){this.newline();this.dedent()}if(needsParens)this.push(")");this.map.mark(node,"end");if(opts.after)opts.after();newline(false);this.printTrailingComments(node,parent)}else{throw new ReferenceError("unknown node of type "+JSON.stringify(node.type)+" with constructor "+JSON.stringify(node&&node.constructor.name))}this.format.concise=oldConcise};CodeGenerator.prototype.printJoin=function printJoin(print,nodes){var _this=this;var opts=arguments[2]===undefined?{}:arguments[2];if(!nodes||!nodes.length)return;var len=nodes.length;if(opts.indent)this.indent();each(nodes,function(node,i){print(node,{statement:opts.statement,addNewlines:opts.addNewlines,after:function(){if(opts.iterator){opts.iterator(node,i)}if(opts.separator&&i<len-1){_this.push(opts.separator)}}})});if(opts.indent)this.dedent()};CodeGenerator.prototype.printAndIndentOnComments=function printAndIndentOnComments(print,node){var indent=!!node.leadingComments;if(indent)this.indent();print(node);if(indent)this.dedent()};CodeGenerator.prototype.printBlock=function printBlock(print,node){if(t.isEmptyStatement(node)){this.semicolon()}else{this.push(" ");print(node)}};CodeGenerator.prototype.generateComment=function generateComment(comment){var val=comment.value;if(comment.type==="Line"){val="//"+val}else{val="/*"+val+"*/"}return val};CodeGenerator.prototype.printTrailingComments=function printTrailingComments(node,parent){this._printComments(this.getComments("trailingComments",node,parent))};CodeGenerator.prototype.printLeadingComments=function printLeadingComments(node,parent){this._printComments(this.getComments("leadingComments",node,parent))};CodeGenerator.prototype.getComments=function getComments(key,node,parent){var _this=this;if(t.isExpressionStatement(parent)){return[]}var comments=[];var nodes=[node];if(t.isExpressionStatement(node)){nodes.push(node.argument)}each(nodes,function(node){comments=comments.concat(_this._getComments(key,node))});return comments};CodeGenerator.prototype._getComments=function _getComments(key,node){return node&&node[key]||[]};CodeGenerator.prototype._printComments=function _printComments(comments){var _this=this;if(this.format.compact)return;if(!this.format.comments)return;if(!comments||!comments.length)return;each(comments,function(comment){var skip=false;each(_this.ast.comments,function(origComment){if(origComment.start===comment.start){if(origComment._displayed)skip=true;origComment._displayed=true;return false}});if(skip)return;_this.newline(_this.whitespace.getNewlinesBefore(comment));var column=_this.position.column; var val=_this.generateComment(comment);if(column&&!_this.isLast(["\n"," ","[","{"])){_this._push(" ");column++}if(comment.type==="Block"&&_this.format.indent.adjustMultilineComment){var offset=comment.loc.start.column;if(offset){var newlineRegex=new RegExp("\\n\\s{1,"+offset+"}","g");val=val.replace(newlineRegex,"\n")}var indent=Math.max(_this.indentSize(),column);val=val.replace(/\n/g,"\n"+repeating(" ",indent))}if(column===0){val=_this.getIndent()+val}_this._push(val);_this.newline(_this.whitespace.getNewlinesAfter(comment))})};return CodeGenerator}();each(Buffer.prototype,function(fn,key){CodeGenerator.prototype[key]=function(){return fn.apply(this.buffer,arguments)}});each(CodeGenerator.generators,function(generator){extend(CodeGenerator.prototype,generator)});module.exports=function(ast,opts,code){var gen=new CodeGenerator(ast,opts,code);return gen.generate()};module.exports.CodeGenerator=CodeGenerator},{"../messages":27,"../types":122,"./buffer":2,"./generators/base":3,"./generators/classes":4,"./generators/comprehensions":5,"./generators/expressions":6,"./generators/flow":7,"./generators/jsx":8,"./generators/methods":9,"./generators/modules":10,"./generators/playground":11,"./generators/statements":12,"./generators/template-literals":13,"./generators/types":14,"./node":16,"./position":19,"./source-map":20,"./whitespace":21,"detect-indent":180,"lodash/collection/each":201,"lodash/object/extend":299,repeating:325}],16:[function(require,module,exports){"use strict";var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var whitespace=_interopRequire(require("./whitespace"));var parens=_interopRequireWildcard(require("./parentheses"));var each=_interopRequire(require("lodash/collection/each"));var some=_interopRequire(require("lodash/collection/some"));var t=_interopRequire(require("../../types"));var find=function find(obj,node,parent){if(!obj)return;var result;var types=Object.keys(obj);for(var i=0;i<types.length;i++){var type=types[i];if(t.is(type,node)){var fn=obj[type];result=fn(node,parent);if(result!=null)break}}return result};var Node=function(){function Node(node,parent){_classCallCheck(this,Node);this.parent=parent;this.node=node}Node.isUserWhitespacable=function isUserWhitespacable(node){return t.isUserWhitespacable(node)};Node.needsWhitespace=function needsWhitespace(node,parent,type){if(!node)return 0;if(t.isExpressionStatement(node)){node=node.expression}var linesInfo=find(whitespace.nodes,node,parent);if(!linesInfo){var items=find(whitespace.list,node,parent);if(items){for(var i=0;i<items.length;i++){linesInfo=Node.needsWhitespace(items[i],node,type);if(linesInfo)break}}}return linesInfo&&linesInfo[type]||0};Node.needsWhitespaceBefore=function needsWhitespaceBefore(node,parent){return Node.needsWhitespace(node,parent,"before")};Node.needsWhitespaceAfter=function needsWhitespaceAfter(node,parent){return Node.needsWhitespace(node,parent,"after")};Node.needsParens=function needsParens(node,parent){if(!parent)return false;if(t.isNewExpression(parent)&&parent.callee===node){if(t.isCallExpression(node))return true;var hasCall=some(node,function(val){return t.isCallExpression(val)});if(hasCall)return true}return find(parens,node,parent)};Node.needsParensNoLineTerminator=function needsParensNoLineTerminator(node,parent){if(!parent)return false;if(!node.leadingComments||!node.leadingComments.length){return false}if(t.isYieldExpression(parent)||t.isAwaitExpression(parent)){return true}if(t.isContinueStatement(parent)||t.isBreakStatement(parent)||t.isReturnStatement(parent)||t.isThrowStatement(parent)){return true}return false};return Node}();module.exports=Node;each(Node,function(fn,key){Node.prototype[key]=function(){var args=new Array(arguments.length+2);args[0]=this.node;args[1]=this.parent;for(var i=0;i<args.length;i++){args[i+2]=arguments[i]}return Node[key].apply(null,args)}})},{"../../types":122,"./parentheses":17,"./whitespace":18,"lodash/collection/each":201,"lodash/collection/some":207}],17:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.UpdateExpression=UpdateExpression;exports.ObjectExpression=ObjectExpression;exports.Binary=Binary;exports.BinaryExpression=BinaryExpression;exports.SequenceExpression=SequenceExpression;exports.YieldExpression=YieldExpression;exports.ClassExpression=ClassExpression;exports.UnaryLike=UnaryLike;exports.FunctionExpression=FunctionExpression;var each=_interopRequire(require("lodash/collection/each"));var t=_interopRequire(require("../../types"));var PRECEDENCE={};each([["||"],["&&"],["|"],["^"],["&"],["==","===","!=","!=="],["<",">","<=",">=","in","instanceof"],[">>","<<",">>>"],["+","-"],["*","/","%"],["**"]],function(tier,i){each(tier,function(op){PRECEDENCE[op]=i})});function UpdateExpression(node,parent){if(t.isMemberExpression(parent)&&parent.object===node){return true}}function ObjectExpression(node,parent){if(t.isExpressionStatement(parent)){return true}if(t.isMemberExpression(parent)&&parent.object===node){return true}return false}function Binary(node,parent){if((t.isCallExpression(parent)||t.isNewExpression(parent))&&parent.callee===node){return true}if(t.isUnaryLike(parent)){return true}if(t.isMemberExpression(parent)&&parent.object===node){return true}if(t.isBinary(parent)){var parentOp=parent.operator;var parentPos=PRECEDENCE[parentOp];var nodeOp=node.operator;var nodePos=PRECEDENCE[nodeOp];if(parentPos>nodePos){return true}if(parentPos===nodePos&&parent.right===node){return true}}}function BinaryExpression(node,parent){if(node.operator==="in"){if(t.isVariableDeclarator(parent)){return true}if(t.isFor(parent)){return true}}}function SequenceExpression(node,parent){if(t.isForStatement(parent)){return false}if(t.isExpressionStatement(parent)&&parent.expression===node){return false}return true}function YieldExpression(node,parent){return t.isBinary(parent)||t.isUnaryLike(parent)||t.isCallExpression(parent)||t.isMemberExpression(parent)||t.isNewExpression(parent)||t.isConditionalExpression(parent)||t.isYieldExpression(parent)}function ClassExpression(node,parent){return t.isExpressionStatement(parent)}function UnaryLike(node,parent){return t.isMemberExpression(parent)&&parent.object===node}function FunctionExpression(node,parent){if(t.isExpressionStatement(parent)){return true}if(t.isMemberExpression(parent)&&parent.object===node){return true}if(t.isCallExpression(parent)&&parent.callee===node){return true}}exports.AssignmentExpression=exports.ConditionalExpression=function(node,parent){if(t.isUnaryLike(parent)){return true}if(t.isBinary(parent)){return true}if(t.isCallExpression(parent)||t.isNewExpression(parent)){if(parent.callee===node){return true}}if(t.isConditionalExpression(parent)&&parent.test===node){return true}if(t.isMemberExpression(parent)&&parent.object===node){return true}return false};exports.__esModule=true},{"../../types":122,"lodash/collection/each":201}],18:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var isBoolean=_interopRequire(require("lodash/lang/isBoolean"));var each=_interopRequire(require("lodash/collection/each"));var map=_interopRequire(require("lodash/collection/map"));var t=_interopRequire(require("../../types"));function crawl(node){var state=arguments[1]===undefined?{}:arguments[1];if(t.isMemberExpression(node)){crawl(node.object,state);if(node.computed)crawl(node.property,state)}else if(t.isBinary(node)||t.isAssignmentExpression(node)){crawl(node.left,state);crawl(node.right,state)}else if(t.isCallExpression(node)){state.hasCall=true;crawl(node.callee,state)}else if(t.isFunction(node)){state.hasFunction=true}else if(t.isIdentifier(node)){var _state=state;if(!_state.hasHelper)_state.hasHelper=isHelper(node.callee)}return state}function isHelper(node){if(t.isMemberExpression(node)){return isHelper(node.object)||isHelper(node.property)}else if(t.isIdentifier(node)){return node.name==="require"||node.name[0]==="_"}else if(t.isCallExpression(node)){return isHelper(node.callee)}else if(t.isBinary(node)||t.isAssignmentExpression(node)){return t.isIdentifier(node.left)&&isHelper(node.left)||isHelper(node.right)}else{return false}}function isType(node){return t.isLiteral(node)||t.isObjectExpression(node)||t.isArrayExpression(node)||t.isIdentifier(node)||t.isMemberExpression(node)}exports.nodes={AssignmentExpression:function AssignmentExpression(node){var state=crawl(node.right);if(state.hasCall&&state.hasHelper||state.hasFunction){return{before:state.hasFunction,after:true}}},SwitchCase:function SwitchCase(node,parent){return{before:node.consequent.length||parent.cases[0]===node}},LogicalExpression:function LogicalExpression(node){if(t.isFunction(node.left)||t.isFunction(node.right)){return{after:true}}},Literal:function Literal(node){if(node.value==="use strict"){return{after:true}}},CallExpression:function CallExpression(node){if(t.isFunction(node.callee)||isHelper(node)){return{before:true,after:true}}},VariableDeclaration:function VariableDeclaration(node){for(var i=0;i<node.declarations.length;i++){var declar=node.declarations[i];var enabled=isHelper(declar.id)&&!isType(declar.init);if(!enabled){var state=crawl(declar.init);enabled=isHelper(declar.init)&&state.hasCall||state.hasFunction}if(enabled){return{before:true,after:true}}}},IfStatement:function IfStatement(node){if(t.isBlockStatement(node.consequent)){return{before:true,after:true}}}};exports.nodes.Property=exports.nodes.SpreadProperty=function(node,parent){if(parent.properties[0]===node){return{before:true}}};exports.list={VariableDeclaration:function VariableDeclaration(node){return map(node.declarations,"init")},ArrayExpression:function ArrayExpression(node){return node.elements},ObjectExpression:function ObjectExpression(node){return node.properties}};each({Function:true,Class:true,Loop:true,LabeledStatement:true,SwitchStatement:true,TryStatement:true},function(amounts,type){if(isBoolean(amounts)){amounts={after:amounts,before:amounts}}each([type].concat(t.FLIPPED_ALIAS_KEYS[type]||[]),function(type){exports.nodes[type]=function(){return amounts}})})},{"../../types":122,"lodash/collection/each":201,"lodash/collection/map":205,"lodash/lang/isBoolean":288}],19:[function(require,module,exports){"use strict";var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var Position=function(){function Position(){_classCallCheck(this,Position);this.line=1;this.column=0}Position.prototype.push=function push(str){for(var i=0;i<str.length;i++){if(str[i]==="\n"){this.line++;this.column=0}else{this.column++}}};Position.prototype.unshift=function unshift(str){for(var i=0;i<str.length;i++){if(str[i]==="\n"){this.line--}else{this.column--}}};return Position}();module.exports=Position},{}],20:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var sourceMap=_interopRequire(require("source-map"));var t=_interopRequire(require("../types"));var SourceMap=function(){function SourceMap(position,opts,code){_classCallCheck(this,SourceMap);this.position=position;this.opts=opts;if(opts.sourceMap){this.map=new sourceMap.SourceMapGenerator({file:opts.sourceMapName,sourceRoot:opts.sourceRoot});this.map.setSourceContent(opts.sourceFileName,code)}else{this.map=null}}SourceMap.prototype.get=function get(){var map=this.map;if(map){return map.toJSON()}else{return map}};SourceMap.prototype.mark=function mark(node,type){var loc=node.loc;if(!loc)return;var map=this.map;if(!map)return;if(t.isProgram(node)||t.isFile(node))return;var position=this.position;var generated={line:position.line,column:position.column};var original=loc[type];map.addMapping({source:this.opts.sourceFileName,generated:generated,original:original})};return SourceMap}();module.exports=SourceMap},{"../types":122,"source-map":330}],21:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var sortBy=_interopRequire(require("lodash/collection/sortBy"));function getLookupIndex(i,base,max){i+=base;if(i>=max){i-=max}return i}var Whitespace=function(){function Whitespace(tokens,comments){_classCallCheck(this,Whitespace);this.tokens=sortBy(tokens.concat(comments),"start");this.used={};this._lastFoundIndex=0}Whitespace.prototype.getNewlinesBefore=function getNewlinesBefore(node){var startToken;var endToken;var tokens=this.tokens;var token;for(var j=0;j<tokens.length;j++){var i=getLookupIndex(j,this._lastFoundIndex,this.tokens.length);token=tokens[i];if(node.start===token.start){startToken=tokens[i-1];endToken=token;this._lastFoundIndex=i;break}}return this.getNewlinesBetween(startToken,endToken)};Whitespace.prototype.getNewlinesAfter=function getNewlinesAfter(node){var startToken;var endToken;var tokens=this.tokens;var token;for(var j=0;j<tokens.length;j++){var i=getLookupIndex(j,this._lastFoundIndex,this.tokens.length);token=tokens[i];if(node.end===token.end){startToken=token;endToken=tokens[i+1];this._lastFoundIndex=i;break}}if(endToken&&endToken.type.type==="eof"){return 1}else{var lines=this.getNewlinesBetween(startToken,endToken);if(node.type==="Line"&&!lines){return 1}else{return lines}}};Whitespace.prototype.getNewlinesBetween=function getNewlinesBetween(startToken,endToken){if(!endToken||!endToken.loc)return 0;var start=startToken?startToken.loc.end.line:1;var end=endToken.loc.start.line;var lines=0;for(var line=start;line<end;line++){if(typeof this.used[line]==="undefined"){this.used[line]=true;lines++}}return lines};return Whitespace}();module.exports=Whitespace},{"lodash/collection/sortBy":208}],22:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var lineNumbers=_interopRequire(require("line-numbers"));var repeating=_interopRequire(require("repeating"));var jsTokens=_interopRequire(require("js-tokens"));var esutils=_interopRequire(require("esutils"));var chalk=_interopRequire(require("chalk"));var ary=_interopRequire(require("lodash/function/ary"));var defs={string:chalk.red,punctuator:chalk.white.bold,curly:chalk.green,parens:chalk.blue.bold,square:chalk.yellow,name:chalk.white,keyword:chalk.cyan,number:chalk.magenta,regex:chalk.magenta,comment:chalk.grey,invalid:chalk.inverse};var newline=/\r\n|[\n\r\u2028\u2029]/;var highlight=function highlight(text){var tokenType=function tokenType(match){var token=jsTokens.matchToToken(match);if(token.type==="name"&&esutils.keyword.isReservedWordES6(token.value)){return"keyword"}if(token.type==="punctuator"){switch(token.value){case"{":case"}":return"curly";case"(":case")":return"parens";case"[":case"]":return"square"}}return token.type};return text.replace(jsTokens,function(match){var type=tokenType(arguments);if(type in defs){var colorize=ary(defs[type],1);return match.split(newline).map(colorize).join("\n")}return match})};module.exports=function(lines,lineNumber,colNumber){colNumber=Math.max(colNumber,0);if(chalk.supportsColor){lines=highlight(lines)}lines=lines.split(newline);var start=Math.max(lineNumber-3,0);var end=Math.min(lines.length,lineNumber+3);if(!lineNumber&&!colNumber){start=0;end=lines.length}return"\n"+lineNumbers(lines.slice(start,end),{start:start+1,before:" ",after:" | ",transform:function transform(params){if(params.number!==lineNumber){return}if(colNumber){params.line+="\n"+params.before+repeating(" ",params.width)+params.after+repeating(" ",colNumber-1)+"^"}params.before=params.before.replace(/^./,">")}}).join("\n")}},{chalk:168,esutils:185,"js-tokens":191,"line-numbers":193,"lodash/function/ary":210,repeating:325}],23:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var t=_interopRequire(require("../types"));module.exports=function(ast,comments,tokens){if(ast&&ast.type==="Program"){return t.file(ast,comments||[],tokens||[])}else{throw new Error("Not a valid ast?")}}},{"../types":122}],24:[function(require,module,exports){"use strict";module.exports=function(){return Object.create(null)}},{}],25:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var normalizeAst=_interopRequire(require("./normalize-ast"));var estraverse=_interopRequire(require("estraverse"));var codeFrame=_interopRequire(require("./code-frame"));var acorn=_interopRequire(require("acorn-babel"));module.exports=function(opts,code,callback){try{var comments=[];var tokens=[];var ast=acorn.parse(code,{allowImportExportEverywhere:opts.allowImportExportEverywhere,allowReturnOutsideFunction:!opts._anal,ecmaVersion:opts.experimental?7:6,playground:opts.playground,strictMode:opts.strictMode,onComment:comments,locations:true,onToken:tokens,ranges:true});estraverse.attachComments(ast,comments,tokens);ast=normalizeAst(ast,comments,tokens);if(callback){return callback(ast)}else{return ast}}catch(err){if(!err._babel){err._babel=true;var message=opts.filename+": "+err.message;var loc=err.loc;if(loc){var frame=codeFrame(code,loc.line,loc.column+1);message+=frame}if(err.stack)err.stack=err.stack.replace(err.message,message);err.message=message}throw err}}},{"./code-frame":22,"./normalize-ast":23,"acorn-babel":125,estraverse:181}],26:[function(require,module,exports){"use strict";module.exports=function toFastProperties(obj){function f(){}f.prototype=obj;return f;eval(obj)}},{}],27:[function(require,module,exports){"use strict";var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};exports.get=get;exports.parseArgs=parseArgs;var util=_interopRequireWildcard(require("util"));var messages=exports.messages={tailCallReassignmentDeopt:"Function reference has been reassigned so it's probably be dereferenced so we can't optimise this with confidence",JSXNamespacedTags:"Namespace tags are not supported. ReactJSX is not XML.",classesIllegalBareSuper:"Illegal use of bare super",classesIllegalSuperCall:"Direct super call is illegal in non-constructor, use super.$1() instead",classesIllegalConstructorKind:"Illegal kind for constructor method",scopeDuplicateDeclaration:"Duplicate declaration $1",undeclaredVariable:"Reference to undeclared variable $1",undeclaredVariableSuggestion:"Reference to undeclared variable $1 - did you mean $2?",settersInvalidParamLength:"Setters must have exactly one parameter",noAssignmentsInForHead:"No assignments allowed in for-in/of head",expectedMemberExpressionOrIdentifier:"Expected type MemeberExpression or Identifier",invalidParentForThisNode:"We don't know how to handle this node within the current parent - please open an issue",readOnly:"$1 is read-only",modulesIllegalExportName:"Illegal export $1",unknownForHead:"Unknown node type $1 in ForStatement",didYouMean:"Did you mean $1?",evalInStrictMode:"eval is not allowed in strict mode",codeGeneratorDeopt:"Note: The code generator has deoptimised the styling of $1 as it exceeds the max of $2."};function get(key){var msg=exports.messages[key];if(!msg)throw new ReferenceError("Unknown message `"+key+"`");var args=[];for(var i=1;i<arguments.length;i++){args.push(arguments[i])}args=exports.parseArgs(args);return msg.replace(/\$(\d+)/g,function(str,i){return args[--i]})}function parseArgs(args){return args.map(function(val){if(val!=null&&val.inspect){return val.inspect()}else{try{return JSON.stringify(val)||val+""}catch(e){return util.inspect(val)}}})}exports.__esModule=true},{util:167}],28:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var estraverse=_interopRequire(require("estraverse"));var extend=_interopRequire(require("lodash/object/extend"));var types=_interopRequire(require("ast-types"));var t=_interopRequire(require("./types"));extend(estraverse.VisitorKeys,t.VISITOR_KEYS);var def=types.Type.def;var or=types.Type.or;def("File").bases("Node").build("program").field("program",def("Program"));def("AssignmentPattern").bases("Pattern").build("left","right").field("left",def("Pattern")).field("right",def("Expression"));def("ImportBatchSpecifier").bases("Specifier").build("name").field("name",def("Identifier"));def("RestElement").bases("Pattern").build("argument").field("argument",def("expression"));def("VirtualPropertyExpression").bases("Expression").build("object","property").field("object",def("Expression")).field("property",or(def("Identifier"),def("Expression")));def("PrivateDeclaration").bases("Declaration").build("declarations").field("declarations",[def("Identifier")]);def("BindMemberExpression").bases("Expression").build("object","property","arguments").field("object",def("Expression")).field("property",or(def("Identifier"),def("Expression"))).field("arguments",[def("Expression")]);def("BindFunctionExpression").bases("Expression").build("callee","arguments").field("callee",def("Expression")).field("arguments",[def("Expression")]);types.finalize()},{"./types":122,"ast-types":139,estraverse:181,"lodash/object/extend":299}],29:[function(require,module,exports){"use strict";var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var sourceMapToComment=_interopRequire(require("source-map-to-comment"));var shebangRegex=_interopRequire(require("shebang-regex"));var isFunction=_interopRequire(require("lodash/lang/isFunction"));var transform=_interopRequire(require("./index"));var generate=_interopRequire(require("../generation"));var defaults=_interopRequire(require("lodash/object/defaults"));var includes=_interopRequire(require("lodash/collection/includes"));var assign=_interopRequire(require("lodash/object/assign"));var parse=_interopRequire(require("../helpers/parse"));var Scope=_interopRequire(require("../traversal/scope"));var slash=_interopRequire(require("slash"));var util=_interopRequireWildcard(require("../util"));var path=_interopRequire(require("path"));var each=_interopRequire(require("lodash/collection/each"));var t=_interopRequire(require("../types"));var checkTransformerVisitor={enter:function enter(node,parent,scope,state){checkNode(state.stack,node,scope)}};var checkNode=function checkNode(stack,node,scope){each(stack,function(pass){if(pass.shouldRun)return;pass.checkNode(node,scope)})};var File=function(){function File(opts){_classCallCheck(this,File);this.dynamicImportedNoDefault=[];this.dynamicImportIds={};this.dynamicImported=[];this.dynamicImports=[];this.usedHelpers={};this.dynamicData={};this.data={};this.lastStatements=[];this.opts=this.normalizeOptions(opts);this.ast={};this.buildTransformers()}File.helpers=["inherits","defaults","prototype-properties","apply-constructor","tagged-template-literal","tagged-template-literal-loose","interop-require","to-array","to-consumable-array","sliced-to-array","object-without-properties","has-own","slice","bind","define-property","async-to-generator","interop-require-wildcard","typeof","extends","get","set","class-call-check","object-destructuring-empty","temporal-undefined","temporal-assert-defined","self-global"];File.validOptions=["filename","filenameRelative","blacklist","whitelist","loose","optional","modules","sourceMap","sourceMapName","sourceFileName","sourceRoot","moduleRoot","moduleIds","comments","reactCompat","keepModuleIdExtensions","code","ast","playground","experimental","externalHelpers","auxiliaryComment","compact","returnUsedHelpers","resolveModuleSource","moduleId","format","ignore","only","extensions","accept"];File.prototype.normalizeOptions=function normalizeOptions(opts){opts=assign({},opts);for(var key in opts){if(key[0]!=="_"&&File.validOptions.indexOf(key)<0){throw new ReferenceError("Unknown option: "+key)}}defaults(opts,{keepModuleIdExtensions:false,resolveModuleSource:null,returnUsedHelpers:false,externalHelpers:false,auxilaryComment:"",experimental:false,reactCompat:false,playground:false,moduleIds:false,blacklist:[],whitelist:[],sourceMap:false,optional:[],comments:true,filename:"unknown",modules:"common",compact:"auto",loose:[],code:true,ast:true});opts.filename=slash(opts.filename);if(opts.sourceRoot){opts.sourceRoot=slash(opts.sourceRoot)}if(opts.moduleId){opts.moduleIds=true}opts.basename=path.basename(opts.filename,path.extname(opts.filename));opts.blacklist=util.arrayify(opts.blacklist);opts.whitelist=util.arrayify(opts.whitelist);opts.optional=util.arrayify(opts.optional);opts.compact=util.booleanify(opts.compact);opts.loose=util.arrayify(opts.loose);if(includes(opts.loose,"all")||includes(opts.loose,true)){opts.loose=Object.keys(transform.transformers)}defaults(opts,{moduleRoot:opts.sourceRoot});defaults(opts,{sourceRoot:opts.moduleRoot});defaults(opts,{filenameRelative:opts.filename});defaults(opts,{sourceFileName:opts.filenameRelative,sourceMapName:opts.filenameRelative});if(opts.playground){opts.experimental=true}if(opts.externalHelpers){this.set("helpersNamespace",t.identifier("babelHelpers"))}opts.blacklist=transform._ensureTransformerNames("blacklist",opts.blacklist);opts.whitelist=transform._ensureTransformerNames("whitelist",opts.whitelist);opts.optional=transform._ensureTransformerNames("optional",opts.optional);opts.loose=transform._ensureTransformerNames("loose",opts.loose);if(opts.reactCompat){opts.optional.push("reactCompat");console.error("The reactCompat option has been moved into the optional transformer `reactCompat`")}var ensureEnabled=function ensureEnabled(key){var namespace=transform.transformerNamespaces[key];if(namespace==="es7")opts.experimental=true;if(namespace==="playground")opts.playground=true};each(opts.whitelist,ensureEnabled);each(opts.optional,ensureEnabled);return opts};File.prototype.isLoose=function isLoose(key){return includes(this.opts.loose,key)};File.prototype.buildTransformers=function buildTransformers(){var file=this;var transformers={};var secondaryStack=[];var stack=[];each(transform.transformers,function(transformer,key){var pass=transformers[key]=transformer.buildPass(file);if(pass.canRun(file)){stack.push(pass);if(transformer.secondPass){secondaryStack.push(pass)}if(transformer.manipulateOptions){transformer.manipulateOptions(file.opts,file)}}});this.transformerStack=stack.concat(secondaryStack);this.transformers=transformers};File.prototype.debug=function debug(msg){var parts=this.opts.filename;if(msg)parts+=": "+msg;util.debug(parts)};File.prototype.getModuleFormatter=function getModuleFormatter(type){var ModuleFormatter=isFunction(type)?type:transform.moduleFormatters[type];if(!ModuleFormatter){var loc=util.resolve(type);if(loc)ModuleFormatter=require(loc)}if(!ModuleFormatter){throw new ReferenceError("Unknown module formatter type "+JSON.stringify(type))}return new ModuleFormatter(this)};File.prototype.parseShebang=function parseShebang(code){var shebangMatch=shebangRegex.exec(code);if(shebangMatch){this.shebang=shebangMatch[0];code=code.replace(shebangRegex,"")}return code};File.prototype.set=function set(key,val){return this.data[key]=val};File.prototype.setDynamic=function setDynamic(key,fn){this.dynamicData[key]=fn};File.prototype.get=function get(key){var data=this.data[key];if(data){return data}else{var dynamic=this.dynamicData[key];if(dynamic){return this.set(key,dynamic())}}};File.prototype.addImport=function addImport(source,name,noDefault){if(!name)name=source;var id=this.dynamicImportIds[name];if(!id){id=this.dynamicImportIds[name]=this.scope.generateUidIdentifier(name);var specifiers=[t.importSpecifier(t.identifier("default"),id)];var declar=t.importDeclaration(specifiers,t.literal(source));declar._blockHoist=3;this.dynamicImported.push(declar);if(noDefault)this.dynamicImportedNoDefault.push(declar);this.moduleFormatter.importSpecifier(specifiers[0],declar,this.dynamicImports)}return id};File.prototype.isConsequenceExpressionStatement=function isConsequenceExpressionStatement(node){return t.isExpressionStatement(node)&&this.lastStatements.indexOf(node)>=0};File.prototype.attachAuxiliaryComment=function attachAuxiliaryComment(node){var comment=this.opts.auxiliaryComment;if(comment){var _node=node;if(!_node.leadingComments)_node.leadingComments=[];node.leadingComments.push({type:"Line",value:" "+comment})}return node};File.prototype.addHelper=function addHelper(name){if(!includes(File.helpers,name)){throw new ReferenceError("Unknown helper "+name)}var program=this.ast.program;var declar=program._declarations&&program._declarations[name];if(declar)return declar.id;this.usedHelpers[name]=true;var runtime=this.get("helpersNamespace");if(runtime){name=t.identifier(t.toIdentifier(name));return t.memberExpression(runtime,name)}else{var ref=util.template(name);ref._compact=true;var uid=this.scope.generateUidIdentifier(name);this.scope.push({key:name,id:uid,init:ref});return uid}};File.prototype.logDeopt=function logDeopt(){};File.prototype.errorWithNode=function errorWithNode(node,msg){var Error=arguments[2]===undefined?SyntaxError:arguments[2];var loc=node.loc.start;var err=new Error("Line "+loc.line+": "+msg);err.loc=loc;return err};File.prototype.addCode=function addCode(code){code=(code||"")+"";this.code=code;return this.parseShebang(code)};File.prototype.parse=function(_parse){var _parseWrapper=function parse(_x){return _parse.apply(this,arguments)};_parseWrapper.toString=function(){return _parse.toString()};return _parseWrapper}(function(code){var _this=this;code=this.addCode(code);var opts=this.opts;opts.allowImportExportEverywhere=this.isLoose("es6.modules");opts.strictMode=this.transformers.useStrict.canRun();return parse(opts,code,function(tree){_this.transform(tree);return _this.generate()})});File.prototype.transform=function transform(ast){this.debug();this.ast=ast;this.lastStatements=t.getLastStatements(ast.program);this.scope=new Scope(ast.program,ast,null,this);var modFormatter=this.moduleFormatter=this.getModuleFormatter(this.opts.modules);if(modFormatter.init&&this.transformers["es6.modules"].canRun()){modFormatter.init()}this.checkNode(ast);this.call("pre");each(this.transformerStack,function(pass){pass.transform()});this.call("post")};File.prototype.call=function call(key){var stack=this.transformerStack;for(var i=0;i<stack.length;i++){var transformer=stack[i].transformer;if(transformer[key]){transformer[key](this)}}};File.prototype.checkNode=function(_checkNode){var _checkNodeWrapper=function checkNode(_x2,_x3){return _checkNode.apply(this,arguments)};_checkNodeWrapper.toString=function(){return _checkNode.toString()};return _checkNodeWrapper}(function(node,scope){var stack=this.transformerStack;if(!scope)scope=this.scope;checkNode(stack,node,scope);scope.traverse(node,checkTransformerVisitor,{stack:stack})});File.prototype.generate=function(_generate){var _generateWrapper=function generate(){return _generate.apply(this,arguments)};_generateWrapper.toString=function(){return _generate.toString()};return _generateWrapper}(function(){var opts=this.opts;var ast=this.ast;var result={code:"",map:null,ast:null};if(this.opts.returnUsedHelpers){result.usedHelpers=Object.keys(this.usedHelpers)}if(opts.ast)result.ast=ast;if(!opts.code)return result;var _result=generate(ast,opts,this.code);result.code=_result.code; result.map=_result.map;if(this.shebang){result.code=this.shebang+"\n"+result.code}if(opts.sourceMap==="inline"){result.code+="\n"+sourceMapToComment(result.map);result.map=null}return result});return File}();module.exports=File},{"../generation":15,"../helpers/parse":25,"../traversal/scope":119,"../types":122,"../util":124,"./index":43,"lodash/collection/each":201,"lodash/collection/includes":204,"lodash/lang/isFunction":290,"lodash/object/assign":297,"lodash/object/defaults":298,path:150,"shebang-regex":327,slash:328,"source-map-to-comment":329}],30:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var explode=_interopRequire(require("./explode-assignable-expression"));var t=_interopRequire(require("../../types"));module.exports=function(exports,opts){var isAssignment=function isAssignment(node){return node.operator===opts.operator+"="};var buildAssignment=function buildAssignment(left,right){return t.assignmentExpression("=",left,right)};exports.ExpressionStatement=function(node,parent,scope,file){if(file.isConsequenceExpressionStatement(node))return;var expr=node.expression;if(!isAssignment(expr))return;var nodes=[];var exploded=explode(expr.left,nodes,file,scope,true);nodes.push(t.expressionStatement(buildAssignment(exploded.ref,opts.build(exploded.uid,expr.right))));return nodes};exports.AssignmentExpression=function(node,parent,scope,file){if(!isAssignment(node))return;var nodes=[];var exploded=explode(node.left,nodes,file,scope);nodes.push(buildAssignment(exploded.ref,opts.build(exploded.uid,node.right)));return t.toSequenceExpression(nodes,scope)};exports.BinaryExpression=function(node){if(node.operator!==opts.operator)return;return opts.build(node.left,node.right)}}},{"../../types":122,"./explode-assignable-expression":35}],31:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var t=_interopRequire(require("../../types"));module.exports=function build(node,buildBody){var self=node.blocks.shift();if(!self)return;var child=build(node,buildBody);if(!child){child=buildBody();if(node.filter){child=t.ifStatement(node.filter,t.blockStatement([child]))}}return t.forOfStatement(t.variableDeclaration("let",[t.variableDeclarator(self.left)]),self.right,t.blockStatement([child]))}},{"../../types":122}],32:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var explode=_interopRequire(require("./explode-assignable-expression"));var t=_interopRequire(require("../../types"));module.exports=function(exports,opts){var buildAssignment=function buildAssignment(left,right){return t.assignmentExpression("=",left,right)};exports.ExpressionStatement=function(node,parent,scope,file){if(file.isConsequenceExpressionStatement(node))return;var expr=node.expression;if(!opts.is(expr,file))return;var nodes=[];var exploded=explode(expr.left,nodes,file,scope);nodes.push(t.ifStatement(opts.build(exploded.uid,file),t.expressionStatement(buildAssignment(exploded.ref,expr.right))));return nodes};exports.AssignmentExpression=function(node,parent,scope,file){if(!opts.is(node,file))return;var nodes=[];var exploded=explode(node.left,nodes,file,scope);nodes.push(t.logicalExpression("&&",opts.build(exploded.uid,file),buildAssignment(exploded.ref,node.right)));nodes.push(exploded.ref);return t.toSequenceExpression(nodes,scope)}}},{"../../types":122,"./explode-assignable-expression":35}],33:[function(require,module,exports){"use strict";var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var isString=_interopRequire(require("lodash/lang/isString"));var messages=_interopRequireWildcard(require("../../messages"));var esutils=_interopRequire(require("esutils"));var react=_interopRequire(require("./react"));var t=_interopRequire(require("../../types"));module.exports=function(exports,opts){exports.check=function(node){if(t.isJSX(node))return true;if(react.isCreateClass(node))return true;return false};exports.JSXIdentifier=function(node,parent){if(node.name==="this"&&t.isReferenced(node,parent)){return t.thisExpression()}else if(esutils.keyword.isIdentifierName(node.name)){node.type="Identifier"}else{return t.literal(node.name)}};exports.JSXNamespacedName=function(node,parent,scope,file){throw file.errorWithNode(node,messages.get("JSXNamespacedTags"))};exports.JSXMemberExpression={exit:function exit(node){node.computed=t.isLiteral(node.property);node.type="MemberExpression"}};exports.JSXExpressionContainer=function(node){return node.expression};exports.JSXAttribute={enter:function enter(node){var value=node.value;if(t.isLiteral(value)&&isString(value.value)){value.value=value.value.replace(/\n\s+/g," ")}},exit:function exit(node){var value=node.value||t.literal(true);return t.inherits(t.property("init",node.name,value),node)}};exports.JSXOpeningElement={exit:function exit(node,parent,scope,file){var tagExpr=node.name;var args=[];var tagName;if(t.isIdentifier(tagExpr)){tagName=tagExpr.name}else if(t.isLiteral(tagExpr)){tagName=tagExpr.value}var state={tagExpr:tagExpr,tagName:tagName,args:args};if(opts.pre){opts.pre(state,file)}var attribs=node.attributes;if(attribs.length){attribs=buildJSXOpeningElementAttributes(attribs,file)}else{attribs=t.literal(null)}args.push(attribs);if(opts.post){opts.post(state,file)}return state.call||t.callExpression(state.callee,args)}};var buildJSXOpeningElementAttributes=function buildJSXOpeningElementAttributes(attribs,file){var _props=[];var objs=[];var pushProps=function pushProps(){if(!_props.length)return;objs.push(t.objectExpression(_props));_props=[]};while(attribs.length){var prop=attribs.shift();if(t.isJSXSpreadAttribute(prop)){pushProps();objs.push(prop.argument)}else{_props.push(prop)}}pushProps();if(objs.length===1){attribs=objs[0]}else{if(!t.isObjectExpression(objs[0])){objs.unshift(t.objectExpression([]))}attribs=t.callExpression(file.addHelper("extends"),objs)}return attribs};exports.JSXElement={exit:function exit(node){var callExpr=node.openingElement;for(var i=0;i<node.children.length;i++){var child=node.children[i];if(t.isLiteral(child)&&typeof child.value==="string"){cleanJSXElementLiteralChild(child,callExpr.arguments);continue}else if(t.isJSXEmptyExpression(child)){continue}callExpr.arguments.push(child)}callExpr.arguments=flatten(callExpr.arguments);if(callExpr.arguments.length>=3){callExpr._prettyCall=true}return t.inherits(callExpr,node)}};var isStringLiteral=function isStringLiteral(node){return t.isLiteral(node)&&isString(node.value)};var flatten=function flatten(args){var flattened=[];var last;for(var i=0;i<args.length;i++){var arg=args[i];if(isStringLiteral(arg)&&isStringLiteral(last)){last.value+=arg.value}else{last=arg;flattened.push(arg)}}return flattened};var cleanJSXElementLiteralChild=function cleanJSXElementLiteralChild(child,args){var lines=child.value.split(/\r\n|\n|\r/);var lastNonEmptyLine=0;var i;for(i=0;i<lines.length;i++){if(lines[i].match(/[^ \t]/)){lastNonEmptyLine=i}}for(i=0;i<lines.length;i++){var line=lines[i];var isFirstLine=i===0;var isLastLine=i===lines.length-1;var isLastNonEmptyLine=i===lastNonEmptyLine;var trimmedLine=line.replace(/\t/g," ");if(!isFirstLine){trimmedLine=trimmedLine.replace(/^[ ]+/,"")}if(!isLastLine){trimmedLine=trimmedLine.replace(/[ ]+$/,"")}if(trimmedLine){if(!isLastNonEmptyLine){trimmedLine+=" "}args.push(t.literal(trimmedLine))}}};var addDisplayName=function addDisplayName(id,call){var props=call.arguments[0].properties;var safe=true;for(var i=0;i<props.length;i++){var prop=props[i];if(t.isIdentifier(prop.key,{name:"displayName"})){safe=false;break}}if(safe){props.unshift(t.property("init",t.identifier("displayName"),t.literal(id)))}};exports.ExportDeclaration=function(node,parent,scope,file){if(node["default"]&&react.isCreateClass(node.declaration)){addDisplayName(file.opts.basename,node.declaration)}};exports.AssignmentExpression=exports.Property=exports.VariableDeclarator=function(node){var left,right;if(t.isAssignmentExpression(node)){left=node.left;right=node.right}else if(t.isProperty(node)){left=node.key;right=node.value}else if(t.isVariableDeclarator(node)){left=node.id;right=node.init}if(t.isMemberExpression(left)){left=left.property}if(t.isIdentifier(left)&&react.isCreateClass(right)){addDisplayName(left.name,right)}}}},{"../../messages":27,"../../types":122,"./react":38,esutils:185,"lodash/lang/isString":295}],34:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var cloneDeep=_interopRequire(require("lodash/lang/cloneDeep"));var traverse=_interopRequire(require("../../traversal"));var clone=_interopRequire(require("lodash/lang/clone"));var each=_interopRequire(require("lodash/collection/each"));var has=_interopRequire(require("lodash/object/has"));var t=_interopRequire(require("../../types"));exports.push=function(mutatorMap,key,kind,computed,value){var alias;if(t.isIdentifier(key)){alias=key.name;if(computed)alias="computed:"+alias}else if(t.isLiteral(key)){alias=String(key.value)}else{alias=JSON.stringify(traverse.removeProperties(cloneDeep(key)))}var map;if(has(mutatorMap,alias)){map=mutatorMap[alias]}else{map={}}mutatorMap[alias]=map;map._key=key;if(computed){map._computed=true}map[kind]=value};exports.build=function(mutatorMap){var objExpr=t.objectExpression([]);each(mutatorMap,function(map){var mapNode=t.objectExpression([]);var propNode=t.property("init",map._key,mapNode,map._computed);if(!map.get&&!map.set){map.writable=t.literal(true)}if(map.enumerable===false){delete map.enumerable}else{map.enumerable=t.literal(true)}map.configurable=t.literal(true);each(map,function(node,key){if(key[0]==="_")return;node=clone(node);var inheritNode=node;if(t.isMethodDefinition(node))node=node.value;var prop=t.property("init",t.identifier(key),node);t.inheritsComments(prop,inheritNode);t.removeComments(inheritNode);mapNode.properties.push(prop)});objExpr.properties.push(propNode)});return objExpr}},{"../../traversal":117,"../../types":122,"lodash/collection/each":201,"lodash/lang/clone":284,"lodash/lang/cloneDeep":285,"lodash/object/has":300}],35:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var t=_interopRequire(require("../../types"));var getObjRef=function getObjRef(node,nodes,file,scope){var ref;if(t.isIdentifier(node)){if(scope.hasBinding(node.name)){return node}else{ref=node}}else if(t.isMemberExpression(node)){ref=node.object;if(t.isIdentifier(ref)&&scope.hasGlobal(ref.name)){return ref}}else{throw new Error("We can't explode this node type "+node.type)}var temp=scope.generateUidBasedOnNode(ref);nodes.push(t.variableDeclaration("var",[t.variableDeclarator(temp,ref)]));return temp};var getPropRef=function getPropRef(node,nodes,file,scope){var prop=node.property;var key=t.toComputedKey(node,prop);if(t.isLiteral(key))return key;var temp=scope.generateUidBasedOnNode(prop);nodes.push(t.variableDeclaration("var",[t.variableDeclarator(temp,prop)]));return temp};module.exports=function(node,nodes,file,scope,allowedSingleIdent){var obj;if(t.isIdentifier(node)&&allowedSingleIdent){obj=node}else{obj=getObjRef(node,nodes,file,scope)}var ref,uid;if(t.isIdentifier(node)){ref=node;uid=obj}else{var prop=getPropRef(node,nodes,file,scope);var computed=node.computed||t.isLiteral(prop);uid=ref=t.memberExpression(obj,prop,computed)}return{uid:uid,ref:ref}}},{"../../types":122}],36:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var t=_interopRequire(require("../../types"));module.exports=function(node){var lastNonDefault=0;for(var i=0;i<node.params.length;i++){if(!t.isAssignmentPattern(node.params[i]))lastNonDefault=i+1}return lastNonDefault}},{"../../types":122}],37:[function(require,module,exports){"use strict";var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var getFunctionArity=_interopRequire(require("./get-function-arity"));var util=_interopRequireWildcard(require("../../util"));var t=_interopRequire(require("../../types"));var visitor={enter:function enter(node,parent,scope,state){if(!t.isReferencedIdentifier(node,parent,{name:state.name}))return;var localDeclar=scope.getBindingIdentifier(state.name);if(localDeclar!==state.outerDeclar)return;state.selfReference=true;this.stop()}};var wrap=function wrap(state,method,id,scope){if(state.selfReference){var templateName="property-method-assignment-wrapper";if(method.generator)templateName+="-generator";var template=util.template(templateName,{FUNCTION:method,FUNCTION_ID:id,FUNCTION_KEY:scope.generateUidIdentifier(id.name),WRAPPER_KEY:scope.generateUidIdentifier(id.name+"Wrapper")});var params=template.callee.body.body[0].declarations[0].init.params;for(var i=0,len=getFunctionArity(method);i<len;i++){params.push(scope.generateUidIdentifier("x"))}return template}else{method.id=id;return method}};var visit=function visit(node,name,scope){var state={selfAssignment:false,selfReference:false,outerDeclar:scope.getBindingIdentifier(name),references:[],name:name};var bindingInfo=null;if(bindingInfo){if(bindingInfo.kind==="param"){state.selfReference=true}else{}}else{scope.traverse(node,visitor,state)}return state};exports.property=function(node,file,scope){var key=t.toComputedKey(node,node.key);if(!t.isLiteral(key))return node;var name=t.toIdentifier(key.value);var id=t.identifier(name);var method=node.value;var state=visit(method,name,scope);node.value=wrap(state,method,id,scope)};exports.bare=function(node,parent,scope){if(node.id)return;var id;if(t.isProperty(parent)&&parent.kind==="init"&&!parent.computed){id=parent.key}else if(t.isVariableDeclarator(parent)){id=parent.id}else{return}if(!t.isIdentifier(id))return;var name=t.toIdentifier(id.name);id=t.identifier(name);var state=visit(node,name,scope);return wrap(state,node,id,scope)}},{"../../types":122,"../../util":124,"./get-function-arity":36}],38:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var t=_interopRequire(require("../../types"));var isCreateClassCallExpression=t.buildMatchMemberExpression("React.createClass");exports.isCreateClass=function(node){if(!node||!t.isCallExpression(node))return false;if(!isCreateClassCallExpression(node.callee))return false;var args=node.arguments;if(args.length!==1)return false;var first=args[0];if(!t.isObjectExpression(first))return false;return true};exports.isReactComponent=t.buildMatchMemberExpression("React.Component");exports.isCompatTag=function(tagName){return tagName&&/^[a-z]|\-/.test(tagName)}},{"../../types":122}],39:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.is=is;exports.pullFlag=pullFlag;var pull=_interopRequire(require("lodash/array/pull"));var t=_interopRequire(require("../../types"));function is(node,flag){return t.isLiteral(node)&&node.regex&&node.regex.flags.indexOf(flag)>=0}function pullFlag(node,flag){var flags=node.regex.flags.split("");if(node.regex.flags.indexOf("u")<0)return;pull(flags,"u");node.regex.flags=flags.join("")}exports.__esModule=true},{"../../types":122,"lodash/array/pull":198}],40:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var t=_interopRequire(require("../../types"));var visitor={enter:function enter(node){if(t.isFunction(node))this.skip();if(t.isAwaitExpression(node)){node.type="YieldExpression";if(node.all){node.all=false;node.argument=t.callExpression(t.memberExpression(t.identifier("Promise"),t.identifier("all")),[node.argument])}}}};module.exports=function(node,callId,scope){node.async=false;node.generator=true;scope.traverse(node,visitor);var call=t.callExpression(callId,[node]);var id=node.id;delete node.id;if(t.isFunctionDeclaration(node)){var declar=t.variableDeclaration("let",[t.variableDeclarator(id,call)]);declar._blockHoist=true;return declar}else{return call}}},{"../../types":122}],41:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var _toConsumableArray=function(arr){if(Array.isArray(arr)){for(var i=0,arr2=Array(arr.length);i<arr.length;i++)arr2[i]=arr[i];return arr2}else{return Array.from(arr)}};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};module.exports=ReplaceSupers;var messages=_interopRequireWildcard(require("../../messages"));var t=_interopRequire(require("../../types"));function isIllegalBareSuper(node,parent){if(!isSuper(node,parent))return false;if(t.isMemberExpression(parent,{computed:false}))return false;if(t.isCallExpression(parent,{callee:node}))return false;return true}function isSuper(node,parent){return t.isIdentifier(node,{name:"super"})&&t.isReferenced(node,parent)}var visitor={enter:function enter(node,parent,scope,state){var topLevel=state.topLevel;var self=state.self;if(t.isFunction(node)&&!t.isArrowFunctionExpression(node)){self.traverseLevel(node,false);return this.skip()}if(t.isProperty(node,{method:true})||t.isMethodDefinition(node)){return this.skip()}var getThisReference=topLevel?t.thisExpression:self.getThisReference.bind(self);var callback=self.specHandle;if(self.isLoose)callback=self.looseHandle;return callback.call(self,getThisReference,node,parent)}};var ReplaceSupers=function(){function ReplaceSupers(opts,inClass){_classCallCheck(this,ReplaceSupers);this.topLevelThisReference=opts.topLevelThisReference;this.methodNode=opts.methodNode;this.className=opts.className;this.superName=opts.superName;this.isStatic=opts.isStatic;this.hasSuper=false;this.inClass=inClass;this.isLoose=opts.isLoose;this.scope=opts.scope;this.file=opts.file}ReplaceSupers.prototype.setSuperProperty=function setSuperProperty(property,value,isComputed,thisExpression){return t.callExpression(this.file.addHelper("set"),[t.callExpression(t.memberExpression(t.identifier("Object"),t.identifier("getPrototypeOf")),[this.isStatic?this.className:t.memberExpression(this.className,t.identifier("prototype"))]),isComputed?property:t.literal(property.name),value,thisExpression])};ReplaceSupers.prototype.getSuperProperty=function getSuperProperty(property,isComputed,thisExpression){return t.callExpression(this.file.addHelper("get"),[t.callExpression(t.memberExpression(t.identifier("Object"),t.identifier("getPrototypeOf")),[this.isStatic?this.className:t.memberExpression(this.className,t.identifier("prototype"))]),isComputed?property:t.literal(property.name),thisExpression])};ReplaceSupers.prototype.replace=function replace(){this.traverseLevel(this.methodNode.value,true)};ReplaceSupers.prototype.traverseLevel=function traverseLevel(node,topLevel){var state={self:this,topLevel:topLevel};this.scope.traverse(node,visitor,state)};ReplaceSupers.prototype.getThisReference=function getThisReference(){if(this.topLevelThisReference){return this.topLevelThisReference}else{var ref=this.topLevelThisReference=this.scope.generateUidIdentifier("this");this.methodNode.value.body.body.unshift(t.variableDeclaration("var",[t.variableDeclarator(this.topLevelThisReference,t.thisExpression())]));return ref}};ReplaceSupers.prototype.getLooseSuperProperty=function getLooseSuperProperty(id,parent){var methodNode=this.methodNode;var methodName=methodNode.key;var superName=this.superName||t.identifier("Function");if(parent.property===id){return}else if(t.isCallExpression(parent,{callee:id})){parent.arguments.unshift(t.thisExpression());if(methodName.name==="constructor"){return t.memberExpression(superName,t.identifier("call"))}else{id=superName;if(!methodNode["static"]){id=t.memberExpression(id,t.identifier("prototype"))}id=t.memberExpression(id,methodName,methodNode.computed);return t.memberExpression(id,t.identifier("call"))}}else if(t.isMemberExpression(parent)&&!methodNode["static"]){return t.memberExpression(superName,t.identifier("prototype"))}else{return superName}};ReplaceSupers.prototype.looseHandle=function looseHandle(getThisReference,node,parent){if(t.isIdentifier(node,{name:"super"})){this.hasSuper=true;return this.getLooseSuperProperty(node,parent)}else if(t.isCallExpression(node)){var callee=node.callee;if(!t.isMemberExpression(callee))return;if(callee.object.name!=="super")return;this.hasSuper=true;t.appendToMemberExpression(callee,t.identifier("call"));node.arguments.unshift(getThisReference())}};ReplaceSupers.prototype.specHandle=function specHandle(getThisReference,node,parent){var methodNode=this.methodNode;var property;var computed;var args;var thisReference;if(isIllegalBareSuper(node,parent)){throw this.file.errorWithNode(node,messages.get("classesIllegalBareSuper"))}if(t.isCallExpression(node)){var callee=node.callee;if(isSuper(callee,node)){property=methodNode.key;computed=methodNode.computed;args=node.arguments;if(methodNode.key.name!=="constructor"||!this.inClass){var methodName=methodNode.key.name||"METHOD_NAME";throw this.file.errorWithNode(node,messages.get("classesIllegalSuperCall",methodName))}}else if(t.isMemberExpression(callee)&&isSuper(callee.object,callee)){property=callee.property;computed=callee.computed;args=node.arguments}}else if(t.isMemberExpression(node)&&isSuper(node.object,node)){property=node.property;computed=node.computed}else if(t.isAssignmentExpression(node)&&isSuper(node.left.object,node.left)&&methodNode.kind==="set"){this.hasSuper=true;return this.setSuperProperty(node.left.property,node.right,node.left.computed,getThisReference())}if(!property)return;this.hasSuper=true;thisReference=getThisReference();var superProperty=this.getSuperProperty(property,computed,thisReference);if(args){if(args.length===1&&t.isSpreadElement(args[0])){return t.callExpression(t.memberExpression(superProperty,t.identifier("apply")),[thisReference,args[0].argument])}else{return t.callExpression(t.memberExpression(superProperty,t.identifier("call")),[thisReference].concat(_toConsumableArray(args)))}}else{return superProperty}};return ReplaceSupers}();module.exports=ReplaceSupers},{"../../messages":27,"../../types":122}],42:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var t=_interopRequire(require("../../types"));exports.has=function(node){var first=node.body[0];return t.isExpressionStatement(first)&&t.isLiteral(first.expression,{value:"use strict"})};exports.wrap=function(node,callback){var useStrictNode;if(exports.has(node)){useStrictNode=node.body.shift()}callback();if(useStrictNode){node.body.unshift(useStrictNode)}}},{"../../types":122}],43:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};module.exports=transform;var normalizeAst=_interopRequire(require("../helpers/normalize-ast"));var Transformer=_interopRequire(require("./transformer"));var object=_interopRequire(require("../helpers/object"));var File=_interopRequire(require("./file"));var each=_interopRequire(require("lodash/collection/each"));function transform(code,opts){var file=new File(opts);return file.parse(code)}transform.fromAst=function(ast,code,opts){ast=normalizeAst(ast);var file=new File(opts);file.addCode(code);file.transform(ast);return file.generate()};transform._ensureTransformerNames=function(type,rawKeys){var keys=[];for(var i=0;i<rawKeys.length;i++){var key=rawKeys[i];var deprecatedKey=transform.deprecatedTransformerMap[key];if(deprecatedKey){console.error("The transformer "+key+" has been renamed to "+deprecatedKey);rawKeys.push(deprecatedKey)}else if(transform.transformers[key]){keys.push(key)}else if(transform.namespaces[key]){keys=keys.concat(transform.namespaces[key])}else{throw new ReferenceError("Unknown transformer "+key+" specified in "+type)}}return keys};transform.transformerNamespaces=object();transform.transformers=object();transform.namespaces=object();transform.deprecatedTransformerMap=require("./transformers/deprecated");transform.moduleFormatters=require("./modules");var rawTransformers=_interopRequire(require("./transformers"));each(rawTransformers,function(transformer,key){var namespace=key.split(".")[0];var _transform$namespaces=transform.namespaces;var _namespace=namespace;if(!_transform$namespaces[_namespace])_transform$namespaces[_namespace]=[];transform.namespaces[namespace].push(key);transform.transformerNamespaces[key]=namespace;transform.transformers[key]=new Transformer(key,transformer)})},{"../helpers/normalize-ast":23,"../helpers/object":24,"./file":29,"./modules":51,"./transformer":56,"./transformers":83,"./transformers/deprecated":57,"lodash/collection/each":201}],44:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var messages=_interopRequireWildcard(require("../../messages"));var extend=_interopRequire(require("lodash/object/extend"));var object=_interopRequire(require("../../helpers/object"));var util=_interopRequireWildcard(require("../../util"));var t=_interopRequire(require("../../types"));var remapVisitor={enter:function enter(node,parent,scope,formatter){if(t.isUpdateExpression(node)&&formatter.isLocalReference(node.argument,scope)){this.skip();var assign=t.assignmentExpression(node.operator[0]+"=",node.argument,t.literal(1));var remapped=formatter.remapExportAssignment(assign);if(t.isExpressionStatement(parent)||node.prefix){return remapped}var nodes=[];nodes.push(remapped);var operator;if(node.operator==="--"){operator="+"}else{operator="-"}nodes.push(t.binaryExpression(operator,node.argument,t.literal(1)));return t.sequenceExpression(nodes)}if(t.isAssignmentExpression(node)&&formatter.isLocalReference(node.left,scope)){this.skip();return formatter.remapExportAssignment(node)}}};var importsVisitor={enter:function enter(node,parent,scope,formatter){if(t.isImportDeclaration(node)){formatter.hasLocalImports=true;extend(formatter.localImports,t.getBindingIdentifiers(node));formatter.bumpImportOccurences(node)}}};var exportsVisitor={enter:function enter(node,parent,scope,formatter){var declar=node&&node.declaration;if(t.isExportDeclaration(node)){formatter.hasLocalImports=true;if(declar&&t.isStatement(declar)){extend(formatter.localExports,t.getBindingIdentifiers(declar))}if(!node["default"]){formatter.hasNonDefaultExports=true}if(node.source){formatter.bumpImportOccurences(node)}}}};var DefaultFormatter=function(){function DefaultFormatter(file){_classCallCheck(this,DefaultFormatter);this.scope=file.scope;this.file=file;this.ids=object();this.hasNonDefaultExports=false;this.hasLocalExports=false;this.hasLocalImports=false;this.localImportOccurences=object();this.localExports=object();this.localImports=object();this.getLocalExports();this.getLocalImports();this.remapAssignments()}DefaultFormatter.prototype.doDefaultExportInterop=function doDefaultExportInterop(node){return node["default"]&&!this.noInteropRequireExport&&!this.hasNonDefaultExports};DefaultFormatter.prototype.bumpImportOccurences=function bumpImportOccurences(node){var source=node.source.value;var occurs=this.localImportOccurences;var _occurs=occurs;var _source=source;if(!_occurs[_source])_occurs[_source]=0;occurs[source]+=node.specifiers.length};DefaultFormatter.prototype.getLocalExports=function getLocalExports(){this.file.scope.traverse(this.file.ast,exportsVisitor,this)};DefaultFormatter.prototype.getLocalImports=function getLocalImports(){this.file.scope.traverse(this.file.ast,importsVisitor,this)};DefaultFormatter.prototype.remapAssignments=function remapAssignments(){if(this.hasLocalImports){this.file.scope.traverse(this.file.ast,remapVisitor,this)}};DefaultFormatter.prototype.isLocalReference=function isLocalReference(node){var localImports=this.localImports;return t.isIdentifier(node)&&localImports[node.name]&&localImports[node.name]!==node};DefaultFormatter.prototype.remapExportAssignment=function remapExportAssignment(node){return t.assignmentExpression("=",node.left,t.assignmentExpression(node.operator,t.memberExpression(t.identifier("exports"),node.left),node.right))};DefaultFormatter.prototype.isLocalReference=function isLocalReference(node,scope){var localExports=this.localExports;var name=node.name;return t.isIdentifier(node)&&localExports[name]&&localExports[name]===scope.getBindingIdentifier(name)};DefaultFormatter.prototype.getModuleName=function getModuleName(){var opts=this.file.opts;if(opts.moduleId)return opts.moduleId;var filenameRelative=opts.filenameRelative;var moduleName="";if(opts.moduleRoot){moduleName=opts.moduleRoot+"/"}if(!opts.filenameRelative){return moduleName+opts.filename.replace(/^\//,"")}if(opts.sourceRoot){var sourceRootRegEx=new RegExp("^"+opts.sourceRoot+"/?");filenameRelative=filenameRelative.replace(sourceRootRegEx,"")}if(!opts.keepModuleIdExtensions){filenameRelative=filenameRelative.replace(/\.(\w*?)$/,"")}moduleName+=filenameRelative;moduleName=moduleName.replace(/\\/g,"/");return moduleName};DefaultFormatter.prototype._pushStatement=function _pushStatement(ref,nodes){if(t.isClass(ref)||t.isFunction(ref)){if(ref.id){nodes.push(t.toStatement(ref));ref=ref.id}}return ref};DefaultFormatter.prototype._hoistExport=function _hoistExport(declar,assign,priority){if(t.isFunctionDeclaration(declar)){assign._blockHoist=priority||2}return assign};DefaultFormatter.prototype.getExternalReference=function getExternalReference(node,nodes){var ids=this.ids;var id=node.source.value;if(ids[id]){return ids[id]}else{return this.ids[id]=this._getExternalReference(node,nodes)}};DefaultFormatter.prototype.checkExportIdentifier=function checkExportIdentifier(node){if(t.isIdentifier(node,{name:"__esModule"})){throw this.file.errorWithNode(node,messages.get("modulesIllegalExportName",node.name))}};DefaultFormatter.prototype.exportSpecifier=function exportSpecifier(specifier,node,nodes){if(node.source){var ref=this.getExternalReference(node,nodes);if(t.isExportBatchSpecifier(specifier)){nodes.push(this.buildExportsWildcard(ref,node))}else{if(t.isSpecifierDefault(specifier)&&!this.noInteropRequireExport){ref=t.callExpression(this.file.addHelper("interop-require"),[ref])}else{ref=t.memberExpression(ref,t.getSpecifierId(specifier))}nodes.push(this.buildExportsAssignment(t.getSpecifierName(specifier),ref,node))}}else{nodes.push(this.buildExportsAssignment(t.getSpecifierName(specifier),specifier.id,node))}};DefaultFormatter.prototype.buildExportsWildcard=function buildExportsWildcard(objectIdentifier){return t.expressionStatement(t.callExpression(this.file.addHelper("defaults"),[t.identifier("exports"),t.callExpression(this.file.addHelper("interop-require-wildcard"),[objectIdentifier])]))};DefaultFormatter.prototype.buildExportsAssignment=function buildExportsAssignment(id,init){this.checkExportIdentifier(id);return util.template("exports-assign",{VALUE:init,KEY:id},true)};DefaultFormatter.prototype.exportDeclaration=function exportDeclaration(node,nodes){var declar=node.declaration;var id=declar.id;if(node["default"]){id=t.identifier("default")}var assign;if(t.isVariableDeclaration(declar)){for(var i=0;i<declar.declarations.length;i++){var decl=declar.declarations[i];decl.init=this.buildExportsAssignment(decl.id,decl.init,node).expression;var newDeclar=t.variableDeclaration(declar.kind,[decl]); if(i===0)t.inherits(newDeclar,declar);nodes.push(newDeclar)}}else{var ref=declar;if(t.isFunctionDeclaration(declar)||t.isClassDeclaration(declar)){ref=declar.id;nodes.push(declar)}assign=this.buildExportsAssignment(id,ref,node);nodes.push(assign);this._hoistExport(declar,assign)}};return DefaultFormatter}();module.exports=DefaultFormatter},{"../../helpers/object":24,"../../messages":27,"../../types":122,"../../util":124,"lodash/object/extend":299}],45:[function(require,module,exports){"use strict";var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var util=_interopRequireWildcard(require("../../util"));module.exports=function(Parent){var Constructor=function Constructor(){this.noInteropRequireImport=true;this.noInteropRequireExport=true;Parent.apply(this,arguments)};util.inherits(Constructor,Parent);return Constructor}},{"../../util":124}],46:[function(require,module,exports){"use strict";module.exports=require("./_strict")(require("./amd"))},{"./_strict":45,"./amd":47}],47:[function(require,module,exports){"use strict";var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _inherits=function(subClass,superClass){if(typeof superClass!=="function"&&superClass!==null){throw new TypeError("Super expression must either be null or a function, not "+typeof superClass)}subClass.prototype=Object.create(superClass&&superClass.prototype,{constructor:{value:subClass,enumerable:false,writable:true,configurable:true}});if(superClass)subClass.__proto__=superClass};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var DefaultFormatter=_interopRequire(require("./_default"));var CommonFormatter=_interopRequire(require("./common"));var includes=_interopRequire(require("lodash/collection/includes"));var values=_interopRequire(require("lodash/object/values"));var util=_interopRequireWildcard(require("../../util"));var t=_interopRequire(require("../../types"));var AMDFormatter=function(DefaultFormatter){function AMDFormatter(){this.init=CommonFormatter.prototype.init;_classCallCheck(this,AMDFormatter);if(DefaultFormatter!=null){DefaultFormatter.apply(this,arguments)}}_inherits(AMDFormatter,DefaultFormatter);AMDFormatter.prototype.buildDependencyLiterals=function buildDependencyLiterals(){var names=[];for(var name in this.ids){names.push(t.literal(name))}return names};AMDFormatter.prototype.transform=function transform(program){var body=program.body;var names=[t.literal("exports")];if(this.passModuleArg)names.push(t.literal("module"));names=names.concat(this.buildDependencyLiterals());names=t.arrayExpression(names);var params=values(this.ids);if(this.passModuleArg)params.unshift(t.identifier("module"));params.unshift(t.identifier("exports"));var container=t.functionExpression(null,params,t.blockStatement(body));var defineArgs=[names,container];var moduleName=this.getModuleName();if(moduleName)defineArgs.unshift(t.literal(moduleName));var call=t.callExpression(t.identifier("define"),defineArgs);program.body=[t.expressionStatement(call)]};AMDFormatter.prototype.getModuleName=function getModuleName(){if(this.file.opts.moduleIds){return DefaultFormatter.prototype.getModuleName.apply(this,arguments)}else{return null}};AMDFormatter.prototype._getExternalReference=function _getExternalReference(node){return this.scope.generateUidIdentifier(node.source.value)};AMDFormatter.prototype.importDeclaration=function importDeclaration(node){this.getExternalReference(node)};AMDFormatter.prototype.importSpecifier=function importSpecifier(specifier,node,nodes){var key=t.getSpecifierName(specifier);var ref=this.getExternalReference(node);if(includes(this.file.dynamicImportedNoDefault,node)){this.ids[node.source.value]=ref}else if(t.isImportBatchSpecifier(specifier)){}else if(!includes(this.file.dynamicImported,node)&&t.isSpecifierDefault(specifier)&&!this.noInteropRequireImport){ref=t.callExpression(this.file.addHelper("interop-require"),[ref])}else{ref=t.memberExpression(ref,t.getSpecifierId(specifier),false)}nodes.push(t.variableDeclaration("var",[t.variableDeclarator(key,ref)]))};AMDFormatter.prototype.exportDeclaration=function exportDeclaration(node){if(this.doDefaultExportInterop(node)){this.passModuleArg=true}CommonFormatter.prototype.exportDeclaration.apply(this,arguments)};return AMDFormatter}(DefaultFormatter);module.exports=AMDFormatter},{"../../types":122,"../../util":124,"./_default":44,"./common":49,"lodash/collection/includes":204,"lodash/object/values":303}],48:[function(require,module,exports){"use strict";module.exports=require("./_strict")(require("./common"))},{"./_strict":45,"./common":49}],49:[function(require,module,exports){"use strict";var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _inherits=function(subClass,superClass){if(typeof superClass!=="function"&&superClass!==null){throw new TypeError("Super expression must either be null or a function, not "+typeof superClass)}subClass.prototype=Object.create(superClass&&superClass.prototype,{constructor:{value:subClass,enumerable:false,writable:true,configurable:true}});if(superClass)subClass.__proto__=superClass};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var DefaultFormatter=_interopRequire(require("./_default"));var includes=_interopRequire(require("lodash/collection/includes"));var util=_interopRequireWildcard(require("../../util"));var t=_interopRequire(require("../../types"));var CommonJSFormatter=function(DefaultFormatter){function CommonJSFormatter(){_classCallCheck(this,CommonJSFormatter);if(DefaultFormatter!=null){DefaultFormatter.apply(this,arguments)}}_inherits(CommonJSFormatter,DefaultFormatter);CommonJSFormatter.prototype.init=function init(){var file=this.file;var scope=file.scope;scope.rename("module");if(!this.noInteropRequireImport&&this.hasNonDefaultExports){var templateName="exports-module-declaration";if(this.file.isLoose("es6.modules"))templateName+="-loose";file.ast.program.body.push(util.template(templateName,true))}};CommonJSFormatter.prototype.importSpecifier=function importSpecifier(specifier,node,nodes){var variableName=t.getSpecifierName(specifier);var ref=this.getExternalReference(node,nodes);if(t.isSpecifierDefault(specifier)){if(!includes(this.file.dynamicImportedNoDefault,node)){if(this.noInteropRequireImport||includes(this.file.dynamicImported,node)){ref=t.memberExpression(ref,t.identifier("default"))}else{ref=t.callExpression(this.file.addHelper("interop-require"),[ref])}}nodes.push(t.variableDeclaration("var",[t.variableDeclarator(variableName,ref)]))}else{if(specifier.type==="ImportBatchSpecifier"){if(!this.noInteropRequireImport){ref=t.callExpression(this.file.addHelper("interop-require-wildcard"),[ref])}nodes.push(t.variableDeclaration("var",[t.variableDeclarator(variableName,ref)]))}else{nodes.push(t.variableDeclaration("var",[t.variableDeclarator(variableName,t.memberExpression(ref,t.getSpecifierId(specifier)))]))}}};CommonJSFormatter.prototype.importDeclaration=function importDeclaration(node,nodes){nodes.push(util.template("require",{MODULE_NAME:node.source},true))};CommonJSFormatter.prototype.exportDeclaration=function exportDeclaration(node,nodes){if(this.doDefaultExportInterop(node)){var declar=node.declaration;var assign=util.template("exports-default-assign",{VALUE:this._pushStatement(declar,nodes)},true);if(t.isFunctionDeclaration(declar)){assign._blockHoist=3}nodes.push(assign);return}DefaultFormatter.prototype.exportDeclaration.apply(this,arguments)};CommonJSFormatter.prototype._getExternalReference=function _getExternalReference(node,nodes){var source=node.source.value;var call=t.callExpression(t.identifier("require"),[node.source]);if(this.localImportOccurences[source]>1){var uid=this.scope.generateUidIdentifier(source);nodes.push(t.variableDeclaration("var",[t.variableDeclarator(uid,call)]));return uid}else{return call}};return CommonJSFormatter}(DefaultFormatter);module.exports=CommonJSFormatter},{"../../types":122,"../../util":124,"./_default":44,"lodash/collection/includes":204}],50:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var t=_interopRequire(require("../../types"));var IgnoreFormatter=function(){function IgnoreFormatter(){_classCallCheck(this,IgnoreFormatter)}IgnoreFormatter.prototype.exportDeclaration=function exportDeclaration(node,nodes){var declar=t.toStatement(node.declaration,true);if(declar)nodes.push(t.inherits(declar,node))};IgnoreFormatter.prototype.importDeclaration=function importDeclaration(){};IgnoreFormatter.prototype.importSpecifier=function importSpecifier(){};IgnoreFormatter.prototype.exportSpecifier=function exportSpecifier(){};return IgnoreFormatter}();module.exports=IgnoreFormatter},{"../../types":122}],51:[function(require,module,exports){"use strict";module.exports={commonStrict:require("./common-strict"),amdStrict:require("./amd-strict"),umdStrict:require("./umd-strict"),common:require("./common"),system:require("./system"),ignore:require("./ignore"),amd:require("./amd"),umd:require("./umd")}},{"./amd":47,"./amd-strict":46,"./common":49,"./common-strict":48,"./ignore":50,"./system":52,"./umd":54,"./umd-strict":53}],52:[function(require,module,exports){"use strict";var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _inherits=function(subClass,superClass){if(typeof superClass!=="function"&&superClass!==null){throw new TypeError("Super expression must either be null or a function, not "+typeof superClass)}subClass.prototype=Object.create(superClass&&superClass.prototype,{constructor:{value:subClass,enumerable:false,writable:true,configurable:true}});if(superClass)subClass.__proto__=superClass};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var DefaultFormatter=_interopRequire(require("./_default"));var AMDFormatter=_interopRequire(require("./amd"));var util=_interopRequireWildcard(require("../../util"));var last=_interopRequire(require("lodash/array/last"));var each=_interopRequire(require("lodash/collection/each"));var map=_interopRequire(require("lodash/collection/map"));var t=_interopRequire(require("../../types"));var hoistVariablesVisitor={enter:function enter(node,parent,scope,hoistDeclarators){if(t.isFunction(node)){return this.skip()}if(t.isVariableDeclaration(node)){if(node.kind!=="var"&&!t.isProgram(parent)){return}if(node._blockHoist)return;var nodes=[];for(var i=0;i<node.declarations.length;i++){var declar=node.declarations[i];hoistDeclarators.push(t.variableDeclarator(declar.id));if(declar.init){var assign=t.expressionStatement(t.assignmentExpression("=",declar.id,declar.init));nodes.push(assign)}}if(t.isFor(parent)){if(parent.left===node){return node.declarations[0].id}if(parent.init===node){return t.toSequenceExpression(nodes,scope)}}return nodes}}};var hoistFunctionsVisitor={enter:function enter(node,parent,scope,handlerBody){if(t.isFunction(node))this.skip();if(t.isFunctionDeclaration(node)||node._blockHoist){handlerBody.push(node);this.remove()}}};var runnerSettersVisitor={enter:function enter(node,parent,scope,state){if(node._importSource===state.source){if(t.isVariableDeclaration(node)){each(node.declarations,function(declar){state.hoistDeclarators.push(t.variableDeclarator(declar.id));state.nodes.push(t.expressionStatement(t.assignmentExpression("=",declar.id,declar.init)))})}else{state.nodes.push(node)}this.remove()}}};var SystemFormatter=function(AMDFormatter){function SystemFormatter(file){_classCallCheck(this,SystemFormatter);this.exportIdentifier=file.scope.generateUidIdentifier("export");this.noInteropRequireExport=true;this.noInteropRequireImport=true;DefaultFormatter.apply(this,arguments)}_inherits(SystemFormatter,AMDFormatter);SystemFormatter.prototype.init=function init(){};SystemFormatter.prototype._addImportSource=function _addImportSource(node,exportNode){node._importSource=exportNode.source&&exportNode.source.value;return node};SystemFormatter.prototype.buildExportsWildcard=function buildExportsWildcard(objectIdentifier,node){var leftIdentifier=this.scope.generateUidIdentifier("key");var valIdentifier=t.memberExpression(objectIdentifier,leftIdentifier,true);var left=t.variableDeclaration("var",[t.variableDeclarator(leftIdentifier)]);var right=objectIdentifier;var block=t.blockStatement([t.expressionStatement(this.buildExportCall(leftIdentifier,valIdentifier))]);return this._addImportSource(t.forInStatement(left,right,block),node)};SystemFormatter.prototype.buildExportsAssignment=function buildExportsAssignment(id,init,node){var call=this.buildExportCall(t.literal(id.name),init,true);return this._addImportSource(call,node)};SystemFormatter.prototype.remapExportAssignment=function remapExportAssignment(node){return this.buildExportCall(t.literal(node.left.name),node)};SystemFormatter.prototype.buildExportCall=function buildExportCall(id,init,isStatement){var call=t.callExpression(this.exportIdentifier,[id,init]);if(isStatement){return t.expressionStatement(call)}else{return call}};SystemFormatter.prototype.importSpecifier=function importSpecifier(specifier,node,nodes){AMDFormatter.prototype.importSpecifier.apply(this,arguments);this._addImportSource(last(nodes),node)};SystemFormatter.prototype.buildRunnerSetters=function buildRunnerSetters(block,hoistDeclarators){var scope=this.file.scope;return t.arrayExpression(map(this.ids,function(uid,source){var state={source:source,nodes:[],hoistDeclarators:hoistDeclarators};scope.traverse(block,runnerSettersVisitor,state);return t.functionExpression(null,[uid],t.blockStatement(state.nodes))}))};SystemFormatter.prototype.transform=function transform(program){var hoistDeclarators=[];var moduleName=this.getModuleName();var moduleNameLiteral=t.literal(moduleName);var block=t.blockStatement(program.body);var runner=util.template("system",{MODULE_NAME:moduleNameLiteral,MODULE_DEPENDENCIES:t.arrayExpression(this.buildDependencyLiterals()),EXPORT_IDENTIFIER:this.exportIdentifier,SETTERS:this.buildRunnerSetters(block,hoistDeclarators),EXECUTE:t.functionExpression(null,[],block)},true);var handlerBody=runner.expression.arguments[2].body.body;if(!moduleName)runner.expression.arguments.shift();var returnStatement=handlerBody.pop();this.file.scope.traverse(block,hoistVariablesVisitor,hoistDeclarators);if(hoistDeclarators.length){var hoistDeclar=t.variableDeclaration("var",hoistDeclarators);hoistDeclar._blockHoist=true;handlerBody.unshift(hoistDeclar)}this.file.scope.traverse(block,hoistFunctionsVisitor,handlerBody);handlerBody.push(returnStatement);program.body=[runner]};return SystemFormatter}(AMDFormatter);module.exports=SystemFormatter},{"../../types":122,"../../util":124,"./_default":44,"./amd":47,"lodash/array/last":197,"lodash/collection/each":201,"lodash/collection/map":205}],53:[function(require,module,exports){"use strict";module.exports=require("./_strict")(require("./umd"))},{"./_strict":45,"./umd":54}],54:[function(require,module,exports){"use strict";var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _inherits=function(subClass,superClass){if(typeof superClass!=="function"&&superClass!==null){throw new TypeError("Super expression must either be null or a function, not "+typeof superClass)}subClass.prototype=Object.create(superClass&&superClass.prototype,{constructor:{value:subClass,enumerable:false,writable:true,configurable:true}});if(superClass)subClass.__proto__=superClass};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var AMDFormatter=_interopRequire(require("./amd"));var values=_interopRequire(require("lodash/object/values"));var util=_interopRequireWildcard(require("../../util"));var t=_interopRequire(require("../../types"));var UMDFormatter=function(AMDFormatter){function UMDFormatter(){_classCallCheck(this,UMDFormatter);if(AMDFormatter!=null){AMDFormatter.apply(this,arguments)}}_inherits(UMDFormatter,AMDFormatter);UMDFormatter.prototype.transform=function transform(program){var body=program.body;var names=[];for(var name in this.ids){names.push(t.literal(name))}var ids=values(this.ids);var args=[t.identifier("exports")];if(this.passModuleArg)args.push(t.identifier("module"));args=args.concat(ids);var factory=t.functionExpression(null,args,t.blockStatement(body));var defineArgs=[t.literal("exports")];if(this.passModuleArg)defineArgs.push(t.literal("module"));defineArgs=defineArgs.concat(names);defineArgs=[t.arrayExpression(defineArgs)];var testExports=util.template("test-exports");var testModule=util.template("test-module");var commonTests=this.passModuleArg?t.logicalExpression("&&",testExports,testModule):testExports;var commonArgs=[t.identifier("exports")];if(this.passModuleArg)commonArgs.push(t.identifier("module"));commonArgs=commonArgs.concat(names.map(function(name){return t.callExpression(t.identifier("require"),[name])}));var moduleName=this.getModuleName();if(moduleName)defineArgs.unshift(t.literal(moduleName));var runner=util.template("umd-runner-body",{AMD_ARGUMENTS:defineArgs,COMMON_TEST:commonTests,COMMON_ARGUMENTS:commonArgs});var call=t.callExpression(runner,[factory]);program.body=[t.expressionStatement(call)]};return UMDFormatter}(AMDFormatter);module.exports=UMDFormatter},{"../../types":122,"../../util":124,"./amd":47,"lodash/object/values":303}],55:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var includes=_interopRequire(require("lodash/collection/includes"));var TransformerPass=function(){function TransformerPass(file,transformer){_classCallCheck(this,TransformerPass);this.transformer=transformer;this.shouldRun=!transformer.check;this.handlers=transformer.handlers;this.file=file}TransformerPass.prototype.canRun=function canRun(){var transformer=this.transformer;var opts=this.file.opts;var key=transformer.key;if(key[0]==="_")return true;var blacklist=opts.blacklist;if(blacklist.length&&includes(blacklist,key))return false;var whitelist=opts.whitelist;if(whitelist.length)return includes(whitelist,key);if(transformer.optional&&!includes(opts.optional,key))return false;if(transformer.experimental&&!opts.experimental)return false;if(transformer.playground&&!opts.playground)return false;return true};TransformerPass.prototype.checkNode=function checkNode(node){var check=this.transformer.check;if(check){return this.shouldRun=check(node)}else{return true}};TransformerPass.prototype.transform=function transform(){if(!this.shouldRun)return;var file=this.file;file.debug("Running transformer "+this.transformer.key);file.scope.traverse(file.ast,this.handlers,file)};return TransformerPass}();module.exports=TransformerPass},{"lodash/collection/includes":204}],56:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var TransformerPass=_interopRequire(require("./transformer-pass"));var isFunction=_interopRequire(require("lodash/lang/isFunction"));var traverse=_interopRequire(require("../traversal"));var isObject=_interopRequire(require("lodash/lang/isObject"));var assign=_interopRequire(require("lodash/object/assign"));var each=_interopRequire(require("lodash/collection/each"));var Transformer=function(){function Transformer(transformerKey,transformer,opts){_classCallCheck(this,Transformer);transformer=assign({},transformer);var take=function take(key){var val=transformer[key];delete transformer[key];return val};this.manipulateOptions=take("manipulateOptions");this.check=take("check");this.post=take("post");this.pre=take("pre");this.experimental=!!take("experimental");this.playground=!!take("playground");this.secondPass=!!take("secondPass");this.optional=!!take("optional");this.handlers=this.normalize(transformer);var _ref=this;if(!_ref.opts)_ref.opts={};this.key=transformerKey}Transformer.prototype.normalize=function normalize(transformer){var _this=this;if(isFunction(transformer)){transformer={ast:transformer}}traverse.explode(transformer);each(transformer,function(fns,type){if(type[0]==="_"){_this[type]=fns;return}if(type==="enter"||type==="exit")return;if(isFunction(fns))fns={enter:fns};if(!isObject(fns))return;if(!fns.enter)fns.enter=function(){};if(!fns.exit)fns.exit=function(){};transformer[type]=fns});return transformer};Transformer.prototype.buildPass=function buildPass(file){return new TransformerPass(file,this)};return Transformer}();module.exports=Transformer},{"../traversal":117,"./transformer-pass":55,"lodash/collection/each":201,"lodash/lang/isFunction":290,"lodash/lang/isObject":293,"lodash/object/assign":297}],57:[function(require,module,exports){module.exports={selfContained:"runtime","unicode-regex":"regex.unicode"}},{}],58:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.MemberExpression=MemberExpression;var t=_interopRequire(require("../../../types"));function MemberExpression(node){var prop=node.property;if(node.computed&&t.isLiteral(prop)&&t.isValidIdentifier(prop.value)){node.property=t.identifier(prop.value);node.computed=false}else if(!node.computed&&t.isIdentifier(prop)&&!t.isValidIdentifier(prop.name)){node.property=t.literal(prop.name);node.computed=true}}exports.__esModule=true},{"../../../types":122}],59:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.Property=Property;var t=_interopRequire(require("../../../types"));function Property(node){var key=node.key;if(t.isLiteral(key)&&t.isValidIdentifier(key.value)){node.key=t.identifier(key.value);node.computed=false}else if(!node.computed&&t.isIdentifier(key)&&!t.isValidIdentifier(key.name)){node.key=t.literal(key.name)}}exports.__esModule=true},{"../../../types":122}],60:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.check=check;exports.ObjectExpression=ObjectExpression;var defineMap=_interopRequire(require("../../helpers/define-map"));var t=_interopRequire(require("../../../types"));function check(node){return t.isProperty(node)&&(node.kind==="get"||node.kind==="set")}function ObjectExpression(node){var mutatorMap={};var hasAny=false;node.properties=node.properties.filter(function(prop){if(prop.kind==="get"||prop.kind==="set"){hasAny=true;defineMap.push(mutatorMap,prop.key,prop.kind,prop.computed,prop.value);return false}else{return true}});if(!hasAny)return;return t.callExpression(t.memberExpression(t.identifier("Object"),t.identifier("defineProperties")),[node,defineMap.build(mutatorMap)])}exports.__esModule=true},{"../../../types":122,"../../helpers/define-map":34}],61:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.ArrowFunctionExpression=ArrowFunctionExpression;var t=_interopRequire(require("../../../types"));exports.check=t.isArrowFunctionExpression;function ArrowFunctionExpression(node){t.ensureBlock(node);node._aliasFunction="arrow";node.expression=false;node.type="FunctionExpression";return node}exports.__esModule=true},{"../../../types":122}],62:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var t=_interopRequire(require("../../../types"));var visitor={enter:function enter(node,parent,scope,state){if(!t.isReferencedIdentifier(node,parent))return;var declared=state.letRefs[node.name];if(!declared)return;if(scope.getBindingIdentifier(node.name)!==declared)return;var assert=t.callExpression(state.file.addHelper("temporal-assert-defined"),[node,t.literal(node.name),state.file.addHelper("temporal-undefined")]);this.skip();if(t.isAssignmentExpression(parent)||t.isUpdateExpression(parent)){if(parent._ignoreBlockScopingTDZ)return;this.parentPath.node=t.sequenceExpression([assert,parent])}else{return t.logicalExpression("&&",assert,node)}}};exports.optional=true;exports.Loop=exports.Program=exports.BlockStatement=function(node,parent,scope,file){var letRefs=node._letReferences;if(!letRefs)return;var state={letRefs:letRefs,file:file};scope.traverse(node,visitor,state)}},{"../../../types":122}],63:[function(require,module,exports){"use strict";var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var traverse=_interopRequire(require("../../../traversal"));var object=_interopRequire(require("../../../helpers/object"));var util=_interopRequireWildcard(require("../../../util"));var t=_interopRequire(require("../../../types"));var values=_interopRequire(require("lodash/object/values"));var extend=_interopRequire(require("lodash/object/extend"));exports.check=function(node){return t.isVariableDeclaration(node)&&(node.kind==="let"||node.kind==="const")};var isLet=function isLet(node,parent){if(!t.isVariableDeclaration(node))return false;if(node._let)return true;if(node.kind!=="let")return false;if(isLetInitable(node,parent)){for(var i=0;i<node.declarations.length;i++){var declar=node.declarations[i];var _declar=declar;if(!_declar.init)_declar.init=t.identifier("undefined")}}node._let=true;node.kind="var";return true};var isLetInitable=function isLetInitable(node,parent){return!t.isFor(parent)||!t.isFor(parent,{left:node})};var isVar=function isVar(node,parent){return t.isVariableDeclaration(node,{kind:"var"})&&!isLet(node,parent)};var standardizeLets=function standardizeLets(declars){for(var i=0;i<declars.length;i++){delete declars[i]._let}};exports.VariableDeclaration=function(node,parent,scope,file){if(!isLet(node,parent))return;if(isLetInitable(node)&&file.transformers["es6.blockScopingTDZ"].canRun()){var nodes=[node];for(var i=0;i<node.declarations.length;i++){var decl=node.declarations[i];if(decl.init){var assign=t.assignmentExpression("=",decl.id,decl.init);assign._ignoreBlockScopingTDZ=true;nodes.push(t.expressionStatement(assign))}decl.init=file.addHelper("temporal-undefined")}node._blockHoist=2;return nodes}};exports.Loop=function(node,parent,scope,file){var init=node.left||node.init;if(isLet(init,node)){t.ensureBlock(node);node.body._letDeclarators=[init]}var blockScoping=new BlockScoping(node,node.body,parent,scope,file);blockScoping.run()};exports.Program=exports.BlockStatement=function(block,parent,scope,file){if(!t.isLoop(parent)){var blockScoping=new BlockScoping(false,block,parent,scope,file);blockScoping.run()}};function replace(node,parent,scope,remaps){if(!t.isReferencedIdentifier(node,parent))return;var remap=remaps[node.name];if(!remap)return;var ownBinding=scope.getBindingIdentifier(node.name);if(ownBinding===remap.binding){node.name=remap.uid}else{if(this)this.skip()}}var replaceVisitor={enter:replace};function traverseReplace(node,parent,scope,remaps){replace(node,parent,scope,remaps);scope.traverse(node,replaceVisitor,remaps)}var letReferenceBlockVisitor={enter:function enter(node,parent,scope,state){if(t.isFunction(node)){scope.traverse(node,letReferenceFunctionVisitor,state);return this.skip()}}};var letReferenceFunctionVisitor={enter:function enter(node,parent,scope,state){if(!t.isReferencedIdentifier(node,parent))return;if(scope.hasOwnBinding(node.name))return;if(!state.letReferences[node.name])return;state.closurify=true}};var hoistVarDeclarationsVisitor={enter:function enter(node,parent,scope,self){if(t.isForStatement(node)){if(isVar(node.init,node)){node.init=t.sequenceExpression(self.pushDeclar(node.init))}}else if(t.isFor(node)){if(isVar(node.left,node)){node.left=node.left.declarations[0].id}}else if(isVar(node,parent)){return self.pushDeclar(node).map(t.expressionStatement)}else if(t.isFunction(node)){return this.skip()}}};var loopLabelVisitor={enter:function enter(node,parent,scope,state){if(t.isLabeledStatement(node)){state.innerLabels.push(node.label.name)}}};var loopNodeTo=function loopNodeTo(node){if(t.isBreakStatement(node)){return"break"}else if(t.isContinueStatement(node)){return"continue"}};var loopVisitor={enter:function enter(node,parent,scope,state){var replace;if(t.isLoop(node)){state.ignoreLabeless=true;scope.traverse(node,loopVisitor,state);state.ignoreLabeless=false}if(t.isFunction(node)||t.isLoop(node)){return this.skip()}var loopText=loopNodeTo(node);if(loopText){if(node.label){if(state.innerLabels.indexOf(node.label.name)>=0){return}loopText=loopText+"|"+node.label.name}else{if(state.ignoreLabeless)return;if(t.isBreakStatement(node)&&t.isSwitchCase(parent))return}state.hasBreakContinue=true;state.map[loopText]=node;replace=t.literal(loopText)}if(t.isReturnStatement(node)){state.hasReturn=true;replace=t.objectExpression([t.property("init",t.identifier("v"),node.argument||t.identifier("undefined"))])}if(replace){replace=t.returnStatement(replace);return t.inherits(replace,node)}}};var BlockScoping=function(){function BlockScoping(loopParent,block,parent,scope,file){_classCallCheck(this,BlockScoping);this.loopParent=loopParent;this.parent=parent;this.scope=scope;this.block=block;this.file=file;this.outsideLetReferences=object();this.hasLetReferences=false;this.letReferences=block._letReferences=object();this.body=[]}BlockScoping.prototype.run=function run(){var block=this.block;if(block._letDone)return;block._letDone=true;var needsClosure=this.getLetReferences();if(t.isFunction(this.parent)||t.isProgram(this.block))return;if(!this.hasLetReferences)return;if(needsClosure){this.wrapClosure()}else{this.remap()}};BlockScoping.prototype.remap=function remap(){var hasRemaps=false;var letRefs=this.letReferences;var scope=this.scope;var remaps=object();for(var key in letRefs){var ref=letRefs[key];if(scope.parentHasBinding(key)||scope.hasGlobal(key)){var uid=scope.generateUidIdentifier(ref.name).name;ref.name=uid;hasRemaps=true;remaps[key]=remaps[uid]={binding:ref,uid:uid}}}if(!hasRemaps)return;var loopParent=this.loopParent;if(loopParent){traverseReplace(loopParent.right,loopParent,scope,remaps);traverseReplace(loopParent.test,loopParent,scope,remaps);traverseReplace(loopParent.update,loopParent,scope,remaps)}scope.traverse(this.block,replaceVisitor,remaps)};BlockScoping.prototype.wrapClosure=function wrapClosure(){var block=this.block;var outsideRefs=this.outsideLetReferences;if(this.loopParent){for(var name in outsideRefs){var id=outsideRefs[name];if(this.scope.hasGlobal(id.name)){delete outsideRefs[id.name];delete this.letReferences[id.name];this.scope.rename(id.name);this.letReferences[id.name]=id;outsideRefs[id.name]=id}}}this.has=this.checkLoop();this.hoistVarDeclarations();var params=values(outsideRefs);var fn=t.functionExpression(null,params,t.blockStatement(block.body));fn._aliasFunction=true; block.body=this.body;var call=t.callExpression(fn,params);var ret=this.scope.generateUidIdentifier("ret");var hasYield=traverse.hasType(fn.body,this.scope,"YieldExpression",t.FUNCTION_TYPES);if(hasYield){fn.generator=true;call=t.yieldExpression(call,true)}var hasAsync=traverse.hasType(fn.body,this.scope,"AwaitExpression",t.FUNCTION_TYPES);if(hasAsync){fn.async=true;call=t.awaitExpression(call,true)}this.build(ret,call)};BlockScoping.prototype.getLetReferences=function getLetReferences(){var block=this.block;var declarators=block._letDeclarators||[];var declar;for(var i=0;i<declarators.length;i++){declar=declarators[i];extend(this.outsideLetReferences,t.getBindingIdentifiers(declar))}if(block.body){for(i=0;i<block.body.length;i++){declar=block.body[i];if(isLet(declar,block)){declarators=declarators.concat(declar.declarations)}}}for(i=0;i<declarators.length;i++){declar=declarators[i];var keys=t.getBindingIdentifiers(declar);extend(this.letReferences,keys);this.hasLetReferences=true}if(!this.hasLetReferences)return;standardizeLets(declarators);var state={letReferences:this.letReferences,closurify:false};this.scope.traverse(this.block,letReferenceBlockVisitor,state);return state.closurify};BlockScoping.prototype.checkLoop=function checkLoop(){var state={hasBreakContinue:false,ignoreLabeless:false,innerLabels:[],hasReturn:false,isLoop:!!this.loopParent,map:{}};this.scope.traverse(this.block,loopLabelVisitor,state);this.scope.traverse(this.block,loopVisitor,state);return state};BlockScoping.prototype.hoistVarDeclarations=function hoistVarDeclarations(){traverse(this.block,hoistVarDeclarationsVisitor,this.scope,this)};BlockScoping.prototype.pushDeclar=function pushDeclar(node){this.body.push(t.variableDeclaration(node.kind,node.declarations.map(function(declar){return t.variableDeclarator(declar.id)})));var replace=[];for(var i=0;i<node.declarations.length;i++){var declar=node.declarations[i];if(!declar.init)continue;var expr=t.assignmentExpression("=",declar.id,declar.init);replace.push(t.inherits(expr,declar))}return replace};BlockScoping.prototype.build=function build(ret,call){var has=this.has;if(has.hasReturn||has.hasBreakContinue){this.buildHas(ret,call)}else{this.body.push(t.expressionStatement(call))}};BlockScoping.prototype.buildHas=function buildHas(ret,call){var body=this.body;body.push(t.variableDeclaration("var",[t.variableDeclarator(ret,call)]));var loopParent=this.loopParent;var retCheck;var has=this.has;var cases=[];if(has.hasReturn){retCheck=util.template("let-scoping-return",{RETURN:ret})}if(has.hasBreakContinue){if(!loopParent){throw new Error("Has no loop parent but we're trying to reassign breaks "+"and continues, something is going wrong here.")}for(var key in has.map){cases.push(t.switchCase(t.literal(key),[has.map[key]]))}if(has.hasReturn){cases.push(t.switchCase(null,[retCheck]))}if(cases.length===1){var single=cases[0];body.push(this.file.attachAuxiliaryComment(t.ifStatement(t.binaryExpression("===",ret,single.test),single.consequent[0])))}else{body.push(this.file.attachAuxiliaryComment(t.switchStatement(ret,cases)))}}else{if(has.hasReturn){body.push(this.file.attachAuxiliaryComment(retCheck))}}};return BlockScoping}()},{"../../../helpers/object":24,"../../../traversal":117,"../../../types":122,"../../../util":124,"lodash/object/extend":299,"lodash/object/values":303}],64:[function(require,module,exports){"use strict";var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var ReplaceSupers=_interopRequire(require("../../helpers/replace-supers"));var nameMethod=_interopRequire(require("../../helpers/name-method"));var defineMap=_interopRequire(require("../../helpers/define-map"));var messages=_interopRequireWildcard(require("../../../messages"));var util=_interopRequireWildcard(require("../../../util"));var t=_interopRequire(require("../../../types"));exports.check=t.isClass;exports.ClassDeclaration=function(node,parent,scope,file){return new ClassTransformer(node,file,scope,true).run()};exports.ClassExpression=function(node,parent,scope,file){if(!node.id){if(t.isProperty(parent)&&parent.value===node&&!parent.computed&&t.isIdentifier(parent.key)){node.id=parent.key}if(t.isVariableDeclarator(parent)&&t.isIdentifier(parent.id)){node.id=parent.id}}return new ClassTransformer(node,file,scope,false).run()};var ClassTransformer=function(){function ClassTransformer(node,file,scope,isStatement){_classCallCheck(this,ClassTransformer);this.isStatement=isStatement;this.scope=scope;this.node=node;this.file=file;this.hasInstanceMutators=false;this.hasStaticMutators=false;this.instanceMutatorMap={};this.staticMutatorMap={};this.hasConstructor=false;this.className=node.id||scope.generateUidIdentifier("class");this.superName=node.superClass||t.identifier("Function");this.hasSuper=!!node.superClass;this.isLoose=file.isLoose("es6.classes")}ClassTransformer.prototype.run=function run(){var superName=this.superName;var className=this.className;var classBody=this.node.body.body;var file=this.file;var body=this.body=[];var constructorBody=t.blockStatement([t.expressionStatement(t.callExpression(file.addHelper("class-call-check"),[t.thisExpression(),className]))]);var constructor;if(this.node.id){constructor=t.functionDeclaration(className,[],constructorBody);body.push(constructor)}else{var constructorName=null;var containsOnlyConstructor=classBody.length===1&&classBody[0].key.name==="constructor";if(!this.hasSuper&&(classBody.length===0||containsOnlyConstructor)){constructorName=className}constructor=t.functionExpression(constructorName,[],constructorBody);body.push(t.variableDeclaration("var",[t.variableDeclarator(className,constructor)]))}this.constructor=constructor;var closureParams=[];var closureArgs=[];if(this.hasSuper){closureArgs.push(superName);if(!t.isIdentifier(superName)){superName=this.scope.generateUidBasedOnNode(superName,this.file)}closureParams.push(superName);this.superName=superName;body.push(t.expressionStatement(t.callExpression(file.addHelper("inherits"),[className,superName])))}this.buildBody();t.inheritsComments(body[0],this.node);var init;if(body.length===1){init=t.toExpression(constructor)}else{body.push(t.returnStatement(className));init=t.callExpression(t.functionExpression(null,closureParams,t.blockStatement(body)),closureArgs)}if(this.isStatement){return t.variableDeclaration("let",[t.variableDeclarator(className,init)])}else{return init}};ClassTransformer.prototype.buildBody=function buildBody(){var constructor=this.constructor;var className=this.className;var superName=this.superName;var classBody=this.node.body.body;var body=this.body;for(var i=0;i<classBody.length;i++){var node=classBody[i];if(t.isMethodDefinition(node)){var replaceSupers=new ReplaceSupers({methodNode:node,className:this.className,superName:this.superName,isStatic:node["static"],isLoose:this.isLoose,scope:this.scope,file:this.file},true);replaceSupers.replace();if(!node.computed&&t.isIdentifier(node.key,{name:"constructor"})||t.isLiteral(node.key,{value:"constructor"})){this.pushConstructor(node)}else{this.pushMethod(node)}}else if(t.isPrivateDeclaration(node)){this.closure=true;body.unshift(node)}else if(t.isClassProperty(node)){this.pushProperty(node)}}if(!this.hasConstructor&&this.hasSuper&&!t.isFalsyExpression(superName)){var helperName="class-super-constructor-call";if(this.isLoose)helperName+="-loose";constructor.body.body.push(util.template(helperName,{CLASS_NAME:className,SUPER_NAME:this.superName},true))}var instanceProps;var staticProps;if(this.hasInstanceMutators){instanceProps=defineMap.build(this.instanceMutatorMap)}if(this.hasStaticMutators){staticProps=defineMap.build(this.staticMutatorMap)}if(instanceProps||staticProps){if(!staticProps)staticProps=t.literal(null);var args=[className,staticProps];if(instanceProps)args.push(instanceProps);body.push(t.expressionStatement(t.callExpression(this.file.addHelper("prototype-properties"),args)))}};ClassTransformer.prototype.pushMethod=function pushMethod(node){var methodName=node.key;var kind=node.kind;if(kind===""){nameMethod.property(node,this.file,this.scope);if(this.isLoose){var className=this.className;if(!node["static"])className=t.memberExpression(className,t.identifier("prototype"));methodName=t.memberExpression(className,methodName,node.computed);var expr=t.expressionStatement(t.assignmentExpression("=",methodName,node.value));t.inheritsComments(expr,node);this.body.push(expr);return}kind="value"}var mutatorMap=this.instanceMutatorMap;if(node["static"]){this.hasStaticMutators=true;mutatorMap=this.staticMutatorMap}else{this.hasInstanceMutators=true}defineMap.push(mutatorMap,methodName,kind,node.computed,node);defineMap.push(mutatorMap,methodName,"enumerable",node.computed,false)};ClassTransformer.prototype.pushProperty=function pushProperty(node){if(!node.value)return;var key;if(node["static"]){key=t.memberExpression(this.className,node.key);this.body.push(t.expressionStatement(t.assignmentExpression("=",key,node.value)))}else{key=t.memberExpression(t.thisExpression(),node.key);this.constructor.body.body.unshift(t.expressionStatement(t.assignmentExpression("=",key,node.value)))}};ClassTransformer.prototype.pushConstructor=function pushConstructor(method){if(method.kind){throw this.file.errorWithNode(method,messages.get("classesIllegalConstructorKind"))}var construct=this.constructor;var fn=method.value;this.hasConstructor=true;t.inherits(construct,fn);t.inheritsComments(construct,method);construct._ignoreUserWhitespace=true;construct.params=fn.params;construct.body.body=construct.body.body.concat(fn.body.body)};return ClassTransformer}()},{"../../../messages":27,"../../../types":122,"../../../util":124,"../../helpers/define-map":34,"../../helpers/name-method":37,"../../helpers/replace-supers":41}],65:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var messages=_interopRequireWildcard(require("../../../messages"));var t=_interopRequire(require("../../../types"));exports.check=function(node){return t.isVariableDeclaration(node,{kind:"const"})};var visitor={enter:function enter(node,parent,scope,state){if(t.isAssignmentExpression(node)||t.isUpdateExpression(node)){var ids=t.getBindingIdentifiers(node);for(var name in ids){var id=ids[name];var constant=state.constants[name];if(!constant)continue;var constantIdentifier=constant.identifier;if(id===constantIdentifier)continue;if(!scope.bindingIdentifierEquals(name,constantIdentifier))continue;throw state.file.errorWithNode(id,messages.get("readOnly",name))}}else if(t.isScope(node,parent)){this.skip()}}};exports.Scopable=function(node,parent,scope,file){scope.traverse(node,visitor,{constants:scope.getAllBindingsOfKind("const"),file:file})};exports.VariableDeclaration=function(node){if(node.kind==="const")node.kind="let"}},{"../../../messages":27,"../../../types":122}],66:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var messages=_interopRequireWildcard(require("../../../messages"));var t=_interopRequire(require("../../../types"));exports.check=t.isPattern;exports.ForInStatement=exports.ForOfStatement=function(node,parent,scope,file){var left=node.left;if(t.isPattern(left)){var temp=scope.generateUidIdentifier("ref");node.left=t.variableDeclaration("var",[t.variableDeclarator(temp)]);t.ensureBlock(node);node.body.body.unshift(t.variableDeclaration("var",[t.variableDeclarator(left,temp)]));return}if(!t.isVariableDeclaration(left))return;var pattern=left.declarations[0].id;if(!t.isPattern(pattern))return;var key=scope.generateUidIdentifier("ref");node.left=t.variableDeclaration(left.kind,[t.variableDeclarator(key,null)]);var nodes=[];var destructuring=new DestructuringTransformer({kind:left.kind,file:file,scope:scope,nodes:nodes});destructuring.init(pattern,key);t.ensureBlock(node);var block=node.body;block.body=nodes.concat(block.body)};exports.Function=function(node,parent,scope,file){var nodes=[];var hasDestructuringTransformer=false;node.params=node.params.map(function(pattern,i){if(!t.isPattern(pattern))return pattern;hasDestructuringTransformer=true;var ref=scope.generateUidIdentifier("ref");var destructuring=new DestructuringTransformer({blockHoist:node.params.length-i,nodes:nodes,scope:scope,file:file,kind:"var"});destructuring.init(pattern,ref);return ref});if(!hasDestructuringTransformer)return;t.ensureBlock(node);var block=node.body;block.body=nodes.concat(block.body)};exports.CatchClause=function(node,parent,scope,file){var pattern=node.param;if(!t.isPattern(pattern))return;var ref=scope.generateUidIdentifier("ref");node.param=ref;var nodes=[];var destructuring=new DestructuringTransformer({kind:"let",file:file,scope:scope,nodes:nodes});destructuring.init(pattern,ref);node.body.body=nodes.concat(node.body.body);return node};exports.ExpressionStatement=function(node,parent,scope,file){var expr=node.expression;if(expr.type!=="AssignmentExpression")return;if(!t.isPattern(expr.left))return;if(file.isConsequenceExpressionStatement(node))return;var nodes=[];var ref=scope.generateUidIdentifier("ref");nodes.push(t.variableDeclaration("var",[t.variableDeclarator(ref,expr.right)]));var destructuring=new DestructuringTransformer({operator:expr.operator,file:file,scope:scope,nodes:nodes});destructuring.init(expr.left,ref);return nodes};exports.AssignmentExpression=function(node,parent,scope,file){if(!t.isPattern(node.left))return;var ref=scope.generateUidIdentifier("temp");scope.push({key:ref.name,id:ref});var nodes=[];nodes.push(t.assignmentExpression("=",ref,node.right));var destructuring=new DestructuringTransformer({operator:node.operator,file:file,scope:scope,nodes:nodes});destructuring.init(node.left,ref);nodes.push(ref);return t.toSequenceExpression(nodes,scope)};var variableDeclarationHasPattern=function variableDeclarationHasPattern(node){for(var i=0;i<node.declarations.length;i++){if(t.isPattern(node.declarations[i].id)){return true}}return false};exports.VariableDeclaration=function(node,parent,scope,file){if(t.isForInStatement(parent)||t.isForOfStatement(parent))return;if(!variableDeclarationHasPattern(node))return;var nodes=[];var declar;for(var i=0;i<node.declarations.length;i++){declar=node.declarations[i];var patternId=declar.init;var pattern=declar.id;var destructuring=new DestructuringTransformer({nodes:nodes,scope:scope,kind:node.kind,file:file});if(t.isPattern(pattern)&&patternId){destructuring.init(pattern,patternId);if(+i!==node.declarations.length-1){t.inherits(nodes[nodes.length-1],declar)}}else{nodes.push(t.inherits(destructuring.buildVariableAssignment(declar.id,declar.init),declar))}}if(!t.isProgram(parent)&&!t.isBlockStatement(parent)){declar=null;for(i=0;i<nodes.length;i++){node=nodes[i];if(!declar)declar=t.variableDeclaration(node.kind,[]);if(!t.isVariableDeclaration(node)&&declar.kind!==node.kind){throw file.errorWithNode(node,messages.get("invalidParentForThisNode"))}declar.declarations=declar.declarations.concat(node.declarations)}return declar}return nodes};var hasRest=function hasRest(pattern){for(var i=0;i<pattern.elements.length;i++){if(t.isRestElement(pattern.elements[i])){return true}}return false};var DestructuringTransformer=function(){function DestructuringTransformer(opts){_classCallCheck(this,DestructuringTransformer);this.blockHoist=opts.blockHoist;this.operator=opts.operator;this.nodes=opts.nodes;this.scope=opts.scope;this.file=opts.file;this.kind=opts.kind}DestructuringTransformer.prototype.buildVariableAssignment=function buildVariableAssignment(id,init){var op=this.operator;if(t.isMemberExpression(id))op="=";var node;if(op){node=t.expressionStatement(t.assignmentExpression(op,id,init))}else{node=t.variableDeclaration(this.kind,[t.variableDeclarator(id,init)])}node._blockHoist=this.blockHoist;return node};DestructuringTransformer.prototype.buildVariableDeclaration=function buildVariableDeclaration(id,init){var declar=t.variableDeclaration("var",[t.variableDeclarator(id,init)]);declar._blockHoist=this.blockHoist;return declar};DestructuringTransformer.prototype.push=function push(id,init){if(t.isObjectPattern(id)){this.pushObjectPattern(id,init)}else if(t.isArrayPattern(id)){this.pushArrayPattern(id,init)}else if(t.isAssignmentPattern(id)){this.pushAssignmentPattern(id,init)}else{this.nodes.push(this.buildVariableAssignment(id,init))}};DestructuringTransformer.prototype.pushAssignmentPattern=function pushAssignmentPattern(pattern,valueRef){var tempValueRef=this.scope.generateUidBasedOnNode(valueRef);var declar=t.variableDeclaration("var",[t.variableDeclarator(tempValueRef,valueRef)]);declar._blockHoist=this.blockHoist;this.nodes.push(declar);this.nodes.push(this.buildVariableAssignment(pattern.left,t.conditionalExpression(t.binaryExpression("===",tempValueRef,t.identifier("undefined")),pattern.right,tempValueRef)))};DestructuringTransformer.prototype.pushObjectSpread=function pushObjectSpread(pattern,objRef,spreadProp,spreadPropIndex){var keys=[];for(var i=0;i<pattern.properties.length;i++){var prop=pattern.properties[i];if(i>=spreadPropIndex)break;if(t.isSpreadProperty(prop))continue;var key=prop.key;if(t.isIdentifier(key))key=t.literal(prop.key.name);keys.push(key)}keys=t.arrayExpression(keys);var value=t.callExpression(this.file.addHelper("object-without-properties"),[objRef,keys]);this.nodes.push(this.buildVariableAssignment(spreadProp.argument,value))};DestructuringTransformer.prototype.pushObjectProperty=function pushObjectProperty(prop,propRef){if(t.isLiteral(prop.key))prop.computed=true;var pattern=prop.value;var objRef=t.memberExpression(propRef,prop.key,prop.computed);if(t.isPattern(pattern)){this.push(pattern,objRef)}else{this.nodes.push(this.buildVariableAssignment(pattern,objRef))}};DestructuringTransformer.prototype.pushObjectPattern=function pushObjectPattern(pattern,objRef){if(!pattern.properties.length){this.nodes.push(t.expressionStatement(t.callExpression(this.file.addHelper("object-destructuring-empty"),[objRef])))}if(pattern.properties.length>1&&t.isMemberExpression(objRef)){var temp=this.scope.generateUidBasedOnNode(objRef,this.file);this.nodes.push(this.buildVariableDeclaration(temp,objRef));objRef=temp}for(var i=0;i<pattern.properties.length;i++){var prop=pattern.properties[i];if(t.isSpreadProperty(prop)){this.pushObjectSpread(pattern,objRef,prop,i)}else{this.pushObjectProperty(prop,objRef)}}};DestructuringTransformer.prototype.canUnpackArrayPattern=function canUnpackArrayPattern(pattern,arr){if(!t.isArrayExpression(arr))return false;if(pattern.elements.length>arr.elements.length)return;if(pattern.elements.length<arr.elements.length&&!hasRest(pattern))return false;for(var i=0;i<pattern.elements.length;i++){if(!pattern.elements[i])return false}return true};DestructuringTransformer.prototype.pushUnpackedArrayPattern=function pushUnpackedArrayPattern(pattern,arr){for(var i=0;i<pattern.elements.length;i++){var elem=pattern.elements[i];if(t.isRestElement(elem)){this.push(elem.argument,t.arrayExpression(arr.elements.slice(i)))}else{this.push(elem,arr.elements[i])}}};DestructuringTransformer.prototype.pushArrayPattern=function pushArrayPattern(pattern,arrayRef){if(!pattern.elements)return;if(this.canUnpackArrayPattern(pattern,arrayRef)){return this.pushUnpackedArrayPattern(pattern,arrayRef)}var count=!hasRest(pattern)&&pattern.elements.length;var toArray=this.scope.toArray(arrayRef,count);if(t.isIdentifier(toArray)){arrayRef=toArray}else{arrayRef=this.scope.generateUidBasedOnNode(arrayRef);this.nodes.push(this.buildVariableDeclaration(arrayRef,toArray));this.scope.assignTypeGeneric(arrayRef.name,"Array")}for(var i=0;i<pattern.elements.length;i++){var elem=pattern.elements[i];if(!elem)continue;var elemRef;if(t.isRestElement(elem)){elemRef=this.scope.toArray(arrayRef);if(i>0){elemRef=t.callExpression(t.memberExpression(elemRef,t.identifier("slice")),[t.literal(i)])}elem=elem.argument}else{elemRef=t.memberExpression(arrayRef,t.literal(i),true)}this.push(elem,elemRef)}};DestructuringTransformer.prototype.init=function init(pattern,ref){if(!t.isArrayExpression(ref)&&!t.isMemberExpression(ref)&&!t.isIdentifier(ref)){var key=this.scope.generateUidBasedOnNode(ref);this.nodes.push(this.buildVariableDeclaration(key,ref));ref=key}this.push(pattern,ref)};return DestructuringTransformer}()},{"../../../messages":27,"../../../types":122}],67:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var messages=_interopRequireWildcard(require("../../../messages"));var util=_interopRequireWildcard(require("../../../util"));var t=_interopRequire(require("../../../types"));exports.check=t.isForOfStatement;exports.ForOfStatement=function(node,parent,scope,file){var callback=spec;if(file.isLoose("es6.forOf"))callback=loose;var build=callback(node,parent,scope,file);var declar=build.declar;var loop=build.loop;var block=loop.body;t.inheritsComments(loop,node);t.ensureBlock(node);if(declar){block.body.push(declar)}block.body=block.body.concat(node.body.body);t.inherits(loop,node);loop._scopeInfo=node._scopeInfo;return build.node};var breakVisitor={enter:function enter(node,parent,scope,state){if(t.isLoop(node)){state.ignoreLabeless=true;scope.traverse(node,breakVisitor,state);state.ignoreLabeless=false;return this.skip()}if(t.isBreakStatement(node)){if(!node.label&&state.ignoreLabeless)return;if(node.label&&node.label.name!==state.label)return;var ret=t.expressionStatement(t.callExpression(t.memberExpression(state.iteratorKey,t.identifier("return")),[]));ret=state.wrapReturn(ret);this.skip();return[ret,node]}}};var loose=function loose(node,parent,scope,file){var left=node.left;var declar,id;if(t.isIdentifier(left)||t.isPattern(left)||t.isMemberExpression(left)){id=left}else if(t.isVariableDeclaration(left)){id=scope.generateUidIdentifier("ref");declar=t.variableDeclaration(left.kind,[t.variableDeclarator(left.declarations[0].id,id)])}else{throw file.errorWithNode(left,messages.get("unknownForHead",left.type))}var iteratorKey=scope.generateUidIdentifier("iterator");var isArrayKey=scope.generateUidIdentifier("isArray");var loop=util.template("for-of-loose",{LOOP_OBJECT:iteratorKey,IS_ARRAY:isArrayKey,OBJECT:node.right,INDEX:scope.generateUidIdentifier("i"),ID:id});if(!declar){loop.body.body.shift()}scope.traverse(node,breakVisitor,{iteratorKey:iteratorKey,wrapReturn:function wrapReturn(node){return t.ifStatement(t.logicalExpression("&&",t.unaryExpression("!",isArrayKey,true),t.memberExpression(iteratorKey,t.identifier("return"))),node)},label:t.isLabeledStatement(parent)&&parent.label.name});return{declar:declar,node:loop,loop:loop}};var spec=function spec(node,parent,scope,file){var left=node.left;var declar;var stepKey=scope.generateUidIdentifier("step");var stepValue=t.memberExpression(stepKey,t.identifier("value"));if(t.isIdentifier(left)||t.isPattern(left)||t.isMemberExpression(left)){declar=t.expressionStatement(t.assignmentExpression("=",left,stepValue))}else if(t.isVariableDeclaration(left)){declar=t.variableDeclaration(left.kind,[t.variableDeclarator(left.declarations[0].id,stepValue)])}else{throw file.errorWithNode(left,messages.get("unknownForHead",left.type))}var iteratorKey=scope.generateUidIdentifier("iterator");var template=util.template("for-of",{ITERATOR_HAD_ERROR_KEY:scope.generateUidIdentifier("didIteratorError"),ITERATOR_COMPLETION:scope.generateUidIdentifier("iteratorNormalCompletion"),ITERATOR_ERROR_KEY:scope.generateUidIdentifier("iteratorError"),ITERATOR_KEY:iteratorKey,STEP_KEY:stepKey,OBJECT:node.right,BODY:null});var loop=template[3].block.body[0];scope.traverse(node,breakVisitor,{iteratorKey:iteratorKey,label:t.isLabeledStatement(parent)&&parent.label.name,wrapReturn:function wrapReturn(node){return t.ifStatement(t.memberExpression(iteratorKey,t.identifier("return")),node)}});return{declar:declar,loop:loop,node:template}}},{"../../../messages":27,"../../../types":122,"../../../util":124}],68:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.ImportDeclaration=ImportDeclaration;exports.ExportDeclaration=ExportDeclaration;var t=_interopRequire(require("../../../types"));exports.check=require("../internal/modules").check;function ImportDeclaration(node,parent,scope,file){if(node.isType)return;var nodes=[];if(node.specifiers.length){for(var i=0;i<node.specifiers.length;i++){file.moduleFormatter.importSpecifier(node.specifiers[i],node,nodes,parent)}}else{file.moduleFormatter.importDeclaration(node,nodes,parent)}if(nodes.length===1){nodes[0]._blockHoist=node._blockHoist}return nodes}function ExportDeclaration(node,parent,scope,file){if(t.isTypeAlias(node.declaration))return;var nodes=[];var i;if(node.declaration){if(t.isVariableDeclaration(node.declaration)){var declar=node.declaration.declarations[0];declar.init=declar.init||t.identifier("undefined")}file.moduleFormatter.exportDeclaration(node,nodes,parent)}else if(node.specifiers){for(i=0;i<node.specifiers.length;i++){file.moduleFormatter.exportSpecifier(node.specifiers[i],node,nodes,parent)}}if(node._blockHoist){for(i=0;i<nodes.length;i++){nodes[i]._blockHoist=node._blockHoist}}return nodes}exports.__esModule=true},{"../../../types":122,"../internal/modules":89}],69:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.check=check;exports.Property=Property;var ReplaceSupers=_interopRequire(require("../../helpers/replace-supers"));var t=_interopRequire(require("../../../types"));function check(node){return t.isIdentifier(node,{name:"super"})}function Property(node,parent,scope,file){if(!node.method)return;var value=node.value;var thisExpr=scope.generateUidIdentifier("this");var replaceSupers=new ReplaceSupers({topLevelThisReference:thisExpr,methodNode:node,className:thisExpr,isStatic:true,scope:scope,file:file});replaceSupers.replace();if(replaceSupers.hasSuper){value.body.body.unshift(t.variableDeclaration("var",[t.variableDeclarator(thisExpr,t.thisExpression())]))}}exports.__esModule=true},{"../../../types":122,"../../helpers/replace-supers":41}],70:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};exports.check=check;var util=_interopRequireWildcard(require("../../../util"));var t=_interopRequire(require("../../../types"));function check(node){return t.isFunction(node)&&hasDefaults(node)}var hasDefaults=function hasDefaults(node){for(var i=0;i<node.params.length;i++){if(!t.isIdentifier(node.params[i]))return true}return false};var iifeVisitor={enter:function enter(node,parent,scope,state){if(!t.isReferencedIdentifier(node,parent))return;if(!state.scope.hasOwnBinding(node.name))return;if(state.scope.bindingIdentifierEquals(node.name,node))return;state.iife=true;this.stop()}};exports.Function=function(node,parent,scope,file){if(!hasDefaults(node))return;t.ensureBlock(node);var body=[];var argsIdentifier=t.identifier("arguments");argsIdentifier._ignoreAliasFunctions=true;var lastNonDefaultParam=0;var state={iife:false,scope:scope};var pushDefNode=function pushDefNode(left,right,i){var defNode=util.template("default-parameter",{VARIABLE_NAME:left,DEFAULT_VALUE:right,ARGUMENT_KEY:t.literal(i),ARGUMENTS:argsIdentifier},true);file.checkNode(defNode);defNode._blockHoist=node.params.length-i;body.push(defNode)};for(var i=0;i<node.params.length;i++){var param=node.params[i];if(!t.isAssignmentPattern(param)){if(!t.isRestElement(param)){lastNonDefaultParam=i+1}if(!t.isIdentifier(param)){scope.traverse(param,iifeVisitor,state)}if(file.transformers["es6.blockScopingTDZ"].canRun()){pushDefNode(param,t.identifier("undefined"),i)}continue}var left=param.left;var right=param.right;var placeholder=scope.generateUidIdentifier("x");placeholder._isDefaultPlaceholder=true;node.params[i]=placeholder;if(!state.iife){if(t.isIdentifier(right)&&scope.hasOwnBinding(right.name)){state.iife=true}else{scope.traverse(right,iifeVisitor,state)}}pushDefNode(left,right,i)}node.params=node.params.slice(0,lastNonDefaultParam);if(state.iife){var container=t.functionExpression(null,[],node.body,node.generator);container._aliasFunction=true;body.push(t.returnStatement(t.callExpression(container,[])));node.body=t.blockStatement(body)}else{node.body.body=body.concat(node.body.body)}};exports.__esModule=true},{"../../../types":122,"../../../util":124}],71:[function(require,module,exports){"use strict";var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var isNumber=_interopRequire(require("lodash/lang/isNumber"));var util=_interopRequireWildcard(require("../../../util"));var t=_interopRequire(require("../../../types"));exports.check=t.isRestElement;var memberExpressionOptimisationVisitor={enter:function enter(node,parent,scope,state){if(t.isScope(node,parent)&&!scope.bindingIdentifierEquals(state.name,state.outerBinding)){return this.skip()}if(t.isFunctionDeclaration(node)||t.isFunctionExpression(node)){state.noOptimise=true;scope.traverse(node,memberExpressionOptimisationVisitor,state);state.noOptimise=false;return this.skip()}if(!t.isReferencedIdentifier(node,parent,{name:state.name}))return;if(!state.noOptimise&&t.isMemberExpression(parent)&&parent.computed){var prop=parent.property;if(isNumber(prop.value)||t.isUnaryExpression(prop)||t.isBinaryExpression(prop)){optimizeMemberExpression(node,parent,state.method.params.length);state.hasShorthand=true;return}}state.longForm=true}};function optimizeMemberExpression(node,parent,offset){var newExpr;var prop=parent.property;if(t.isLiteral(prop)){node.name="arguments";prop.value+=offset;prop.raw=String(prop.value)}else{node.name="arguments";newExpr=t.binaryExpression("+",prop,t.literal(offset));parent.property=newExpr}}var hasRest=function hasRest(node){return t.isRestElement(node.params[node.params.length-1])};exports.Function=function(node,parent,scope){if(!hasRest(node))return;var rest=node.params.pop().argument;var argsId=t.identifier("arguments");argsId._ignoreAliasFunctions=true;if(t.isPattern(rest)){var pattern=rest;rest=scope.generateUidIdentifier("ref");var declar=t.variableDeclaration("var",pattern.elements.map(function(elem,index){var accessExpr=t.memberExpression(rest,t.literal(index),true);return t.variableDeclarator(elem,accessExpr)}));node.body.body.unshift(declar)}var state={outerBinding:scope.getBindingIdentifier(rest.name),hasShorthand:true,longForm:false,method:node,name:rest.name};scope.traverse(node,memberExpressionOptimisationVisitor,state);if(!state.longForm&&state.hasShorthand)return;var start=t.literal(node.params.length);var key=scope.generateUidIdentifier("key");var len=scope.generateUidIdentifier("len");var arrKey=key;var arrLen=len;if(node.params.length){arrKey=t.binaryExpression("-",key,start);arrLen=t.conditionalExpression(t.binaryExpression(">",len,start),t.binaryExpression("-",len,start),t.literal(0))}scope.assignTypeGeneric(rest.name,"Array");var loop=util.template("rest",{ARGUMENTS:argsId,ARRAY_KEY:arrKey,ARRAY_LEN:arrLen,START:start,ARRAY:rest,KEY:key,LEN:len});loop._blockHoist=node.params.length+1; node.body.body.unshift(loop)}},{"../../../types":122,"../../../util":124,"lodash/lang/isNumber":292}],72:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.check=check;exports.ObjectExpression=ObjectExpression;var t=_interopRequire(require("../../../types"));function loose(node,body,objId){for(var i=0;i<node.properties.length;i++){var prop=node.properties[i];body.push(t.expressionStatement(t.assignmentExpression("=",t.memberExpression(objId,prop.key,prop.computed||t.isLiteral(prop.key)),prop.value)))}}function spec(node,body,objId,initProps,file){var props=node.properties;var prop,key;for(var i=0;i<props.length;i++){prop=props[i];if(prop.kind!=="init")continue;key=prop.key;if(!prop.computed&&t.isIdentifier(key)){prop.key=t.literal(key.name)}}var broken=false;for(i=0;i<props.length;i++){prop=props[i];if(prop.computed){broken=true}if(prop.kind!=="init"||!broken||t.isLiteral(t.toComputedKey(prop,prop.key),{value:"__proto__"})){initProps.push(prop);props[i]=null}}for(i=0;i<props.length;i++){prop=props[i];if(!prop)continue;key=prop.key;var bodyNode;if(prop.computed&&t.isMemberExpression(key)&&t.isIdentifier(key.object,{name:"Symbol"})){bodyNode=t.assignmentExpression("=",t.memberExpression(objId,key,true),prop.value)}else{bodyNode=t.callExpression(file.addHelper("define-property"),[objId,key,prop.value])}body.push(t.expressionStatement(bodyNode))}if(body.length===1){var first=body[0].expression;if(t.isCallExpression(first)){first.arguments[0]=t.objectExpression(initProps);return first}}}function check(node){return t.isProperty(node)&&node.computed}function ObjectExpression(node,parent,scope,file){var hasComputed=false;for(var i=0;i<node.properties.length;i++){hasComputed=t.isProperty(node.properties[i],{computed:true,kind:"init"});if(hasComputed)break}if(!hasComputed)return;var initProps=[];var objId=scope.generateUidBasedOnNode(parent);var body=[];var container=t.functionExpression(null,[],t.blockStatement(body));container._aliasFunction=true;var callback=spec;if(file.isLoose("es6.properties.computed"))callback=loose;var result=callback(node,body,objId,initProps,file);if(result)return result;body.unshift(t.variableDeclaration("var",[t.variableDeclarator(objId,t.objectExpression(initProps))]));body.push(t.returnStatement(objId));return t.callExpression(container,[])}exports.__esModule=true},{"../../../types":122}],73:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.check=check;exports.Property=Property;var clone=_interopRequire(require("lodash/lang/clone"));var t=_interopRequire(require("../../../types"));function check(node){return t.isProperty(node)&&(node.method||node.shorthand)}function Property(node){if(node.method){node.method=false}if(node.shorthand){node.shorthand=false;node.key=t.removeComments(clone(node.key))}}exports.__esModule=true},{"../../../types":122,"lodash/lang/clone":284}],74:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};exports.check=check;exports.Literal=Literal;var regex=_interopRequireWildcard(require("../../helpers/regex"));var t=_interopRequire(require("../../../types"));function check(node){return regex.is(node,"y")}function Literal(node){if(!regex.is(node,"y"))return;return t.newExpression(t.identifier("RegExp"),[t.literal(node.regex.pattern),t.literal(node.regex.flags)])}exports.__esModule=true},{"../../../types":122,"../../helpers/regex":39}],75:[function(require,module,exports){"use strict";var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.check=check;exports.Literal=Literal;var rewritePattern=_interopRequire(require("regexpu/rewrite-pattern"));var regex=_interopRequireWildcard(require("../../helpers/regex"));function check(node){return regex.is(node,"u")}function Literal(node){if(!regex.is(node,"u"))return;regex.pullFlag(node,"y");node.regex.pattern=rewritePattern(node.regex.pattern,node.regex.flags)}exports.__esModule=true},{"../../helpers/regex":39,"regexpu/rewrite-pattern":324}],76:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.ArrayExpression=ArrayExpression;exports.CallExpression=CallExpression;exports.NewExpression=NewExpression;var includes=_interopRequire(require("lodash/collection/includes"));var t=_interopRequire(require("../../../types"));exports.check=t.isSpreadElement;function getSpreadLiteral(spread,scope){return scope.toArray(spread.argument,true)}function hasSpread(nodes){for(var i=0;i<nodes.length;i++){if(t.isSpreadElement(nodes[i])){return true}}return false}function build(props,scope){var nodes=[];var _props=[];var push=function push(){if(!_props.length)return;nodes.push(t.arrayExpression(_props));_props=[]};for(var i=0;i<props.length;i++){var prop=props[i];if(t.isSpreadElement(prop)){push();nodes.push(getSpreadLiteral(prop,scope))}else{_props.push(prop)}}push();return nodes}function ArrayExpression(node,parent,scope){var elements=node.elements;if(!hasSpread(elements))return;var nodes=build(elements,scope);var first=nodes.shift();if(!t.isArrayExpression(first)){nodes.unshift(first);first=t.arrayExpression([])}return t.callExpression(t.memberExpression(first,t.identifier("concat")),nodes)}function CallExpression(node,parent,scope){var args=node.arguments;if(!hasSpread(args))return;var contextLiteral=t.identifier("undefined");node.arguments=[];var nodes;if(args.length===1&&args[0].argument.name==="arguments"){nodes=[args[0].argument]}else{nodes=build(args,scope)}var first=nodes.shift();if(nodes.length){node.arguments.push(t.callExpression(t.memberExpression(first,t.identifier("concat")),nodes))}else{node.arguments.push(first)}var callee=node.callee;if(t.isMemberExpression(callee)){var temp=scope.generateTempBasedOnNode(callee.object);if(temp){callee.object=t.assignmentExpression("=",temp,callee.object);contextLiteral=temp}else{contextLiteral=callee.object}t.appendToMemberExpression(callee,t.identifier("apply"))}else{node.callee=t.memberExpression(node.callee,t.identifier("apply"))}node.arguments.unshift(contextLiteral)}function NewExpression(node,parent,scope,file){var args=node.arguments;if(!hasSpread(args))return;var nativeType=t.isIdentifier(node.callee)&&includes(t.NATIVE_TYPE_NAMES,node.callee.name);var nodes=build(args,scope);if(nativeType){nodes.unshift(t.arrayExpression([t.literal(null)]))}var first=nodes.shift();if(nodes.length){args=t.callExpression(t.memberExpression(first,t.identifier("concat")),nodes)}else{args=first}if(nativeType){return t.newExpression(t.callExpression(t.memberExpression(file.addHelper("bind"),t.identifier("apply")),[node.callee,args]),[])}else{return t.callExpression(file.addHelper("apply-constructor"),[node.callee,args])}}exports.__esModule=true},{"../../../types":122,"lodash/collection/includes":204}],77:[function(require,module,exports){"use strict";var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var reduceRight=_interopRequire(require("lodash/collection/reduceRight"));var messages=_interopRequireWildcard(require("../../../messages"));var flatten=_interopRequire(require("lodash/array/flatten"));var util=_interopRequireWildcard(require("../../../util"));var map=_interopRequire(require("lodash/collection/map"));var t=_interopRequire(require("../../../types"));exports.Function=function(node,parent,scope,file){var tailCall=new TailCallTransformer(node,scope,file);tailCall.run()};function returnBlock(expr){return t.blockStatement([t.returnStatement(expr)])}var firstPass={enter:function enter(node,parent,scope,state){if(t.isIfStatement(node)){if(t.isReturnStatement(node.alternate)){t.ensureBlock(node,"alternate")}if(t.isReturnStatement(node.consequent)){t.ensureBlock(node,"consequent")}}else if(t.isReturnStatement(node)){this.skip();return state.subTransform(node.argument)}else if(t.isTryStatement(parent)){if(node===parent.block){this.skip()}else if(parent.finalizer&&node!==parent.finalizer){this.skip()}}else if(t.isFunction(node)){this.skip()}else if(t.isVariableDeclaration(node)){this.skip();state.vars.push(node)}}};var secondPass={enter:function enter(node,parent,scope,state){if(t.isThisExpression(node)){state.needsThis=true;return state.getThisId()}else if(t.isReferencedIdentifier(node,parent,{name:"arguments"})){state.needsArguments=true;return state.getArgumentsId()}else if(t.isFunction(node)){this.skip();if(t.isFunctionDeclaration(node)){node=t.variableDeclaration("var",[t.variableDeclarator(node.id,t.toExpression(node))]);node._blockHoist=2;return node}}}};var thirdPass={enter:function enter(node,parent,scope,state){if(!t.isExpressionStatement(node))return;var expr=node.expression;if(!t.isAssignmentExpression(expr))return;if(!state.needsThis&&expr.left===state.getThisId()){this.remove()}else if(!state.needsArguments&&expr.left===state.getArgumentsId()&&t.isArrayExpression(expr.right)){return map(expr.right.elements,function(elem){return t.expressionStatement(elem)})}}};var TailCallTransformer=function(){function TailCallTransformer(node,scope,file){_classCallCheck(this,TailCallTransformer);this.hasTailRecursion=false;this.needsArguments=false;this.setsArguments=false;this.needsThis=false;this.ownerId=node.id;this.vars=[];this.scope=scope;this.file=file;this.node=node}TailCallTransformer.prototype.getArgumentsId=function getArgumentsId(){var _ref;return _ref=this,!_ref.argumentsId&&(_ref.argumentsId=this.scope.generateUidIdentifier("arguments")),_ref.argumentsId};TailCallTransformer.prototype.getThisId=function getThisId(){var _ref;return _ref=this,!_ref.thisId&&(_ref.thisId=this.scope.generateUidIdentifier("this")),_ref.thisId};TailCallTransformer.prototype.getLeftId=function getLeftId(){var _ref;return _ref=this,!_ref.leftId&&(_ref.leftId=this.scope.generateUidIdentifier("left")),_ref.leftId};TailCallTransformer.prototype.getFunctionId=function getFunctionId(){var _ref;return _ref=this,!_ref.functionId&&(_ref.functionId=this.scope.generateUidIdentifier("function")),_ref.functionId};TailCallTransformer.prototype.getAgainId=function getAgainId(){var _ref;return _ref=this,!_ref.againId&&(_ref.againId=this.scope.generateUidIdentifier("again")),_ref.againId};TailCallTransformer.prototype.getParams=function getParams(){var params=this.params;if(!params){params=this.node.params;this.paramDecls=[];for(var i=0;i<params.length;i++){var param=params[i];if(!param._isDefaultPlaceholder){this.paramDecls.push(t.variableDeclarator(param,params[i]=this.scope.generateUidIdentifier("x")))}}}return this.params=params};TailCallTransformer.prototype.hasDeopt=function hasDeopt(){var ownerIdInfo=this.scope.getBindingInfo(this.ownerId.name);return ownerIdInfo&&ownerIdInfo.reassigned};TailCallTransformer.prototype.run=function run(){var scope=this.scope;var node=this.node;var ownerId=this.ownerId;if(!ownerId)return;scope.traverse(node,firstPass,this);if(!this.hasTailRecursion)return;if(this.hasDeopt()){this.file.logDeopt(node,messages.get("tailCallReassignmentDeopt"));return}scope.traverse(node,secondPass,this);if(!this.needsThis||!this.needsArguments){scope.traverse(node,thirdPass,this)}var body=t.ensureBlock(node).body;if(this.vars.length>0){var declarations=flatten(map(this.vars,function(decl){return decl.declarations},this));var statement=reduceRight(declarations,function(expr,decl){return t.assignmentExpression("=",decl.id,expr)},t.identifier("undefined"));body.unshift(t.expressionStatement(statement))}var paramDecls=this.paramDecls;if(paramDecls.length>0){body.unshift(t.variableDeclaration("var",paramDecls))}body.unshift(t.expressionStatement(t.assignmentExpression("=",this.getAgainId(),t.literal(false))));node.body=util.template("tail-call-body",{AGAIN_ID:this.getAgainId(),THIS_ID:this.thisId,ARGUMENTS_ID:this.argumentsId,FUNCTION_ID:this.getFunctionId(),BLOCK:node.body});var topVars=[];if(this.needsThis){topVars.push(t.variableDeclarator(this.getThisId(),t.thisExpression()))}if(this.needsArguments||this.setsArguments){var decl=t.variableDeclarator(this.getArgumentsId());if(this.needsArguments){decl.init=t.identifier("arguments")}topVars.push(decl)}var leftId=this.leftId;if(leftId){topVars.push(t.variableDeclarator(leftId))}if(topVars.length>0){node.body.body.unshift(t.variableDeclaration("var",topVars))}};TailCallTransformer.prototype.subTransform=function subTransform(node){if(!node)return;var handler=this["subTransform"+node.type];if(handler)return handler.call(this,node)};TailCallTransformer.prototype.subTransformConditionalExpression=function subTransformConditionalExpression(node){var callConsequent=this.subTransform(node.consequent);var callAlternate=this.subTransform(node.alternate);if(!callConsequent&&!callAlternate){return}node.type="IfStatement";node.consequent=callConsequent?t.toBlock(callConsequent):returnBlock(node.consequent);if(callAlternate){node.alternate=t.isIfStatement(callAlternate)?callAlternate:t.toBlock(callAlternate)}else{node.alternate=returnBlock(node.alternate)}return[node]};TailCallTransformer.prototype.subTransformLogicalExpression=function subTransformLogicalExpression(node){var callRight=this.subTransform(node.right);if(!callRight)return;var leftId=this.getLeftId();var testExpr=t.assignmentExpression("=",leftId,node.left);if(node.operator==="&&"){testExpr=t.unaryExpression("!",testExpr)}return[t.ifStatement(testExpr,returnBlock(leftId))].concat(callRight)};TailCallTransformer.prototype.subTransformSequenceExpression=function subTransformSequenceExpression(node){var seq=node.expressions;var lastCall=this.subTransform(seq[seq.length-1]);if(!lastCall){return}if(--seq.length===1){node=seq[0]}return[t.expressionStatement(node)].concat(lastCall)};TailCallTransformer.prototype.subTransformCallExpression=function subTransformCallExpression(node){var callee=node.callee,thisBinding,args;if(t.isMemberExpression(callee,{computed:false})&&t.isIdentifier(callee.property)){switch(callee.property.name){case"call":args=t.arrayExpression(node.arguments.slice(1));break;case"apply":args=node.arguments[1]||t.identifier("undefined");break;default:return}thisBinding=node.arguments[0];callee=callee.object}if(!t.isIdentifier(callee)||!this.scope.bindingIdentifierEquals(callee.name,this.ownerId)){return}this.hasTailRecursion=true;if(this.hasDeopt())return;var body=[];if(!t.isThisExpression(thisBinding)){body.push(t.expressionStatement(t.assignmentExpression("=",this.getThisId(),thisBinding||t.identifier("undefined"))))}if(!args){args=t.arrayExpression(node.arguments)}var argumentsId=this.getArgumentsId();var params=this.getParams();body.push(t.expressionStatement(t.assignmentExpression("=",argumentsId,args)));var i,param;if(t.isArrayExpression(args)){var elems=args.elements;for(i=0;i<elems.length&&i<params.length;i++){param=params[i];var elem=elems[i]||(elems[i]=t.identifier("undefined"));if(!param._isDefaultPlaceholder){elems[i]=t.assignmentExpression("=",param,elem)}}}else{this.setsArguments=true;for(i=0;i<params.length;i++){param=params[i];if(!param._isDefaultPlaceholder){body.push(t.expressionStatement(t.assignmentExpression("=",param,t.memberExpression(argumentsId,t.literal(i),true))))}}}body.push(t.expressionStatement(t.assignmentExpression("=",this.getAgainId(),t.literal(true))));body.push(t.continueStatement(this.getFunctionId()));return body};return TailCallTransformer}()},{"../../../messages":27,"../../../types":122,"../../../util":124,"lodash/array/flatten":196,"lodash/collection/map":205,"lodash/collection/reduceRight":206}],78:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.check=check;exports.TaggedTemplateExpression=TaggedTemplateExpression;exports.TemplateLiteral=TemplateLiteral;var t=_interopRequire(require("../../../types"));var buildBinaryExpression=function buildBinaryExpression(left,right){return t.binaryExpression("+",left,right)};function check(node){return t.isTemplateLiteral(node)||t.isTaggedTemplateExpression(node)}function TaggedTemplateExpression(node,parent,scope,file){var args=[];var quasi=node.quasi;var strings=[];var raw=[];for(var i=0;i<quasi.quasis.length;i++){var elem=quasi.quasis[i];strings.push(t.literal(elem.value.cooked));raw.push(t.literal(elem.value.raw))}strings=t.arrayExpression(strings);raw=t.arrayExpression(raw);var templateName="tagged-template-literal";if(file.isLoose("es6.templateLiterals"))templateName+="-loose";args.push(t.callExpression(file.addHelper(templateName),[strings,raw]));args=args.concat(quasi.expressions);return t.callExpression(node.tag,args)}function TemplateLiteral(node){var nodes=[];var i;for(i=0;i<node.quasis.length;i++){var elem=node.quasis[i];nodes.push(t.literal(elem.value.cooked));var expr=node.expressions.shift();if(expr)nodes.push(expr)}if(nodes.length>1){var last=nodes[nodes.length-1];if(t.isLiteral(last,{value:""}))nodes.pop();var root=buildBinaryExpression(nodes.shift(),nodes.shift());for(i=0;i<nodes.length;i++){root=buildBinaryExpression(root,nodes[i])}return root}else{return nodes[0]}}exports.__esModule=true},{"../../../types":122}],79:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};exports.AssignmentExpression=AssignmentExpression;exports.UnaryExpression=UnaryExpression;exports.CallExpression=CallExpression;exports.VirtualPropertyExpression=VirtualPropertyExpression;exports.PrivateDeclaration=PrivateDeclaration;var util=_interopRequireWildcard(require("../../../util"));var t=_interopRequire(require("../../../types"));var experimental=exports.experimental=true;var container=function container(parent,call,ret,file){if(t.isExpressionStatement(parent)&&!file.isConsequenceExpressionStatement(parent)){return call}else{var exprs=[];if(t.isSequenceExpression(call)){exprs=call.expressions}else{exprs.push(call)}exprs.push(ret);return t.sequenceExpression(exprs)}};function AssignmentExpression(node,parent,scope,file){var left=node.left;if(!t.isVirtualPropertyExpression(left))return;var value=node.right;var temp;if(!t.isExpressionStatement(parent)){temp=scope.generateTempBasedOnNode(node.right);if(temp)value=temp}if(node.operator!=="="){value=t.binaryExpression(node.operator[0],util.template("abstract-expression-get",{PROPERTY:node.property,OBJECT:node.object}),value)}var call=util.template("abstract-expression-set",{PROPERTY:left.property,OBJECT:left.object,VALUE:value});if(temp){call=t.sequenceExpression([t.assignmentExpression("=",temp,node.right),call])}return container(parent,call,value,file)}function UnaryExpression(node,parent,scope,file){var arg=node.argument;if(!t.isVirtualPropertyExpression(arg))return;if(node.operator!=="delete")return;var call=util.template("abstract-expression-delete",{PROPERTY:arg.property,OBJECT:arg.object});return container(parent,call,t.literal(true),file)}function CallExpression(node,parent,scope){var callee=node.callee;if(!t.isVirtualPropertyExpression(callee))return;var temp=scope.generateTempBasedOnNode(callee.object);var call=util.template("abstract-expression-call",{PROPERTY:callee.property,OBJECT:temp||callee.object});call.arguments=call.arguments.concat(node.arguments);if(temp){return t.sequenceExpression([t.assignmentExpression("=",temp,callee.object),call])}else{return call}}function VirtualPropertyExpression(node){return util.template("abstract-expression-get",{PROPERTY:node.property,OBJECT:node.object})}function PrivateDeclaration(node){return t.variableDeclaration("const",node.declarations.map(function(id){return t.variableDeclarator(id,t.newExpression(t.identifier("WeakMap"),[]))}))}exports.__esModule=true},{"../../../types":122,"../../../util":124}],80:[function(require,module,exports){"use strict";var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.ComprehensionExpression=ComprehensionExpression;var buildComprehension=_interopRequire(require("../../helpers/build-comprehension"));var traverse=_interopRequire(require("../../../traversal"));var util=_interopRequireWildcard(require("../../../util"));var t=_interopRequire(require("../../../types"));var experimental=exports.experimental=true;function ComprehensionExpression(node,parent,scope,file){var callback=array;if(node.generator)callback=generator;return callback(node,parent,scope,file)}function generator(node){var body=[];var container=t.functionExpression(null,[],t.blockStatement(body),true);container._aliasFunction=true;body.push(buildComprehension(node,function(){return t.expressionStatement(t.yieldExpression(node.body))}));return t.callExpression(container,[])}function array(node,parent,scope,file){var uid=scope.generateUidBasedOnNode(parent,file);var container=util.template("array-comprehension-container",{KEY:uid});container.callee._aliasFunction=true;var block=container.callee.body;var body=block.body;if(traverse.hasType(node,scope,"YieldExpression",t.FUNCTION_TYPES)){container.callee.generator=true;container=t.yieldExpression(container,true)}var returnStatement=body.pop();body.push(buildComprehension(node,function(){return util.template("array-push",{STATEMENT:node.body,KEY:uid},true)}));body.push(returnStatement);return container}exports.__esModule=true},{"../../../traversal":117,"../../../types":122,"../../../util":124,"../../helpers/build-comprehension":31}],81:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var build=_interopRequire(require("../../helpers/build-binary-assignment-operator-transformer"));var t=_interopRequire(require("../../../types"));var experimental=exports.experimental=true;var MATH_POW=t.memberExpression(t.identifier("Math"),t.identifier("pow"));build(exports,{operator:"**",build:function build(left,right){return t.callExpression(MATH_POW,[left,right])}});exports.__esModule=true},{"../../../types":122,"../../helpers/build-binary-assignment-operator-transformer":30}],82:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.manipulateOptions=manipulateOptions;exports.ObjectExpression=ObjectExpression;var t=_interopRequire(require("../../../types"));var experimental=exports.experimental=true;function manipulateOptions(opts){if(opts.whitelist.length)opts.whitelist.push("es6.destructuring")}var hasSpread=function hasSpread(node){for(var i=0;i<node.properties.length;i++){if(t.isSpreadProperty(node.properties[i])){return true}}return false};function ObjectExpression(node,parent,scope,file){if(!hasSpread(node))return;var args=[];var props=[];var push=function push(){if(!props.length)return;args.push(t.objectExpression(props));props=[]};for(var i=0;i<node.properties.length;i++){var prop=node.properties[i];if(t.isSpreadProperty(prop)){push();args.push(prop.argument)}else{props.push(prop)}}push();if(!t.isObjectExpression(args[0])){args.unshift(t.objectExpression([]))}return t.callExpression(file.addHelper("extends"),args)}exports.__esModule=true},{"../../../types":122}],83:[function(require,module,exports){"use strict";module.exports={useStrict:require("./other/use-strict"),"validation.undeclaredVariableCheck":require("./validation/undeclared-variable-check"),"validation.noForInOfAssignment":require("./validation/no-for-in-of-assignment"),"validation.setters":require("./validation/setters"),"validation.react":require("./validation/react"),"spec.functionName":require("./spec/function-name"),"spec.blockScopedFunctions":require("./spec/block-scoped-functions"),"es6.arrowFunctions":require("./es6/arrow-functions"),"playground.malletOperator":require("./playground/mallet-operator"),"playground.methodBinding":require("./playground/method-binding"),"playground.memoizationOperator":require("./playground/memoization-operator"),"playground.objectGetterMemoization":require("./playground/object-getter-memoization"),reactCompat:require("./other/react-compat"),flow:require("./other/flow"),react:require("./other/react"),_modules:require("./internal/modules"),"es7.comprehensions":require("./es7/comprehensions"),"es6.classes":require("./es6/classes"),asyncToGenerator:require("./other/async-to-generator"),bluebirdCoroutines:require("./other/bluebird-coroutines"),"es6.objectSuper":require("./es6/object-super"),"es7.objectRestSpread":require("./es7/object-rest-spread"),"es7.exponentiationOperator":require("./es7/exponentiation-operator"),"es6.templateLiterals":require("./es6/template-literals"),"es5.properties.mutators":require("./es5/properties.mutators"),"es6.properties.shorthand":require("./es6/properties.shorthand"),"es6.properties.computed":require("./es6/properties.computed"),"es6.forOf":require("./es6/for-of"),"es6.regex.sticky":require("./es6/regex.sticky"),"es6.regex.unicode":require("./es6/regex.unicode"),"es7.abstractReferences":require("./es7/abstract-references"),"es6.constants":require("./es6/constants"),"es6.parameters.rest":require("./es6/parameters.rest"),"es6.spread":require("./es6/spread"),"es6.parameters.default":require("./es6/parameters.default"),"es6.destructuring":require("./es6/destructuring"),"es6.blockScoping":require("./es6/block-scoping"),"es6.blockScopingTDZ":require("./es6/block-scoping-tdz"),"es6.tailCall":require("./es6/tail-call"),regenerator:require("./other/regenerator"),runtime:require("./other/runtime"),"es6.modules":require("./es6/modules"),_blockHoist:require("./internal/block-hoist"),"spec.protoToAssign":require("./spec/proto-to-assign"),_declarations:require("./internal/declarations"),_aliasFunctions:require("./internal/alias-functions"),"spec.typeofSymbol":require("./spec/typeof-symbol"),"spec.undefinedToVoid":require("./spec/undefined-to-void"),_useStrict:require("./internal/use-strict"),_moduleFormatter:require("./internal/module-formatter"),"es3.propertyLiterals":require("./es3/property-literals"),"es3.memberExpressionLiterals":require("./es3/member-expression-literals"),"minification.removeDebugger":require("./minification/remove-debugger"),"minification.removeConsoleCalls":require("./minification/remove-console-calls"),"minification.deadCodeElimination":require("./minification/dead-code-elimination"),"minification.renameLocalVariables":require("./minification/rename-local-variables"),_cleanUp:require("./internal/cleanup")}},{"./es3/member-expression-literals":58,"./es3/property-literals":59,"./es5/properties.mutators":60,"./es6/arrow-functions":61,"./es6/block-scoping":63,"./es6/block-scoping-tdz":62,"./es6/classes":64,"./es6/constants":65,"./es6/destructuring":66,"./es6/for-of":67,"./es6/modules":68,"./es6/object-super":69,"./es6/parameters.default":70,"./es6/parameters.rest":71,"./es6/properties.computed":72,"./es6/properties.shorthand":73,"./es6/regex.sticky":74,"./es6/regex.unicode":75,"./es6/spread":76,"./es6/tail-call":77,"./es6/template-literals":78,"./es7/abstract-references":79,"./es7/comprehensions":80,"./es7/exponentiation-operator":81,"./es7/object-rest-spread":82,"./internal/alias-functions":84,"./internal/block-hoist":85,"./internal/cleanup":86,"./internal/declarations":87,"./internal/module-formatter":88,"./internal/modules":89,"./internal/use-strict":90,"./minification/dead-code-elimination":91,"./minification/remove-console-calls":92,"./minification/remove-debugger":93,"./minification/rename-local-variables":94,"./other/async-to-generator":95,"./other/bluebird-coroutines":96,"./other/flow":97,"./other/react":99,"./other/react-compat":98,"./other/regenerator":100,"./other/runtime":101,"./other/use-strict":102,"./playground/mallet-operator":103,"./playground/memoization-operator":104,"./playground/method-binding":105,"./playground/object-getter-memoization":106,"./spec/block-scoped-functions":107,"./spec/function-name":108,"./spec/proto-to-assign":109,"./spec/typeof-symbol":110,"./spec/undefined-to-void":111,"./validation/no-for-in-of-assignment":112,"./validation/react":113,"./validation/setters":114,"./validation/undeclared-variable-check":115}],84:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var t=_interopRequire(require("../../../types"));var functionChildrenVisitor={enter:function enter(node,parent,scope,state){if(t.isFunction(node)&&!node._aliasFunction){return this.skip()}if(node._ignoreAliasFunctions)return this.skip();var getId;if(t.isIdentifier(node)&&node.name==="arguments"){getId=state.getArgumentsId}else if(t.isThisExpression(node)){getId=state.getThisId}else{return}if(t.isReferenced(node,parent))return getId()}};var functionVisitor={enter:function enter(node,parent,scope,state){if(!node._aliasFunction){if(t.isFunction(node)){return this.skip()}else{return}}scope.traverse(node,functionChildrenVisitor,state);return this.skip()}};var go=function go(getBody,node,scope){var argumentsId;var thisId;var state={getArgumentsId:function getArgumentsId(){return!argumentsId&&(argumentsId=scope.generateUidIdentifier("arguments")),argumentsId},getThisId:function getThisId(){return!thisId&&(thisId=scope.generateUidIdentifier("this")),thisId}};scope.traverse(node,functionVisitor,state);var body;var pushDeclaration=function pushDeclaration(id,init){if(!body)body=getBody();body.unshift(t.variableDeclaration("var",[t.variableDeclarator(id,init)]))};if(argumentsId){pushDeclaration(argumentsId,t.identifier("arguments"))}if(thisId){pushDeclaration(thisId,t.thisExpression())}};exports.Program=function(node,parent,scope){go(function(){return node.body},node,scope)};exports.FunctionDeclaration=exports.FunctionExpression=function(node,parent,scope){go(function(){t.ensureBlock(node);return node.body.body},node,scope)}},{"../../../types":122}],85:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var groupBy=_interopRequire(require("lodash/collection/groupBy"));var flatten=_interopRequire(require("lodash/array/flatten"));var values=_interopRequire(require("lodash/object/values"));exports.BlockStatement=exports.Program={exit:function exit(node){var hasChange=false;for(var i=0;i<node.body.length;i++){var bodyNode=node.body[i];if(bodyNode&&bodyNode._blockHoist!=null)hasChange=true}if(!hasChange)return;var nodePriorities=groupBy(node.body,function(bodyNode){var priority=bodyNode._blockHoist;if(priority==null)priority=1;if(priority===true)priority=2;return priority});node.body=flatten(values(nodePriorities).reverse())}}},{"lodash/array/flatten":196,"lodash/collection/groupBy":203,"lodash/object/values":303}],86:[function(require,module,exports){"use strict";exports.SequenceExpression=SequenceExpression;function SequenceExpression(node){if(node.expressions.length===1){return node.expressions[0]}}exports.__esModule=true},{}],87:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var useStrict=_interopRequire(require("../../helpers/use-strict"));var t=_interopRequire(require("../../../types"));var secondPass=exports.secondPass=true;exports.BlockStatement=exports.Program=function(node,parent,scope,file){if(!node._declarations)return;useStrict.wrap(node,function(){var kinds={};var kind;for(var i in node._declarations){var declar=node._declarations[i];kind=declar.kind||"var";var declarNode=t.variableDeclarator(declar.id,declar.init); if(declar.init){node.body.unshift(file.attachAuxiliaryComment(t.variableDeclaration(kind,[declarNode])))}else{var _kinds=kinds;var _kind=kind;if(!_kinds[_kind])_kinds[_kind]=[];kinds[kind].push(declarNode)}}for(kind in kinds){node.body.unshift(file.attachAuxiliaryComment(t.variableDeclaration(kind,kinds[kind])))}node._declarations=null})};exports.__esModule=true},{"../../../types":122,"../../helpers/use-strict":42}],88:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.Program=Program;var useStrict=_interopRequire(require("../../helpers/use-strict"));function Program(program,parent,scope,file){if(!file.transformers["es6.modules"].canRun())return;useStrict.wrap(program,function(){program.body=file.dynamicImports.concat(program.body)});if(file.moduleFormatter.transform){file.moduleFormatter.transform(program)}}exports.__esModule=true},{"../../helpers/use-strict":42}],89:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.check=check;exports.ImportDeclaration=ImportDeclaration;exports.ExportDeclaration=ExportDeclaration;var t=_interopRequire(require("../../../types"));function check(node){return t.isImportDeclaration(node)||t.isExportDeclaration(node)}function ImportDeclaration(node,parent,scope,file){var resolveModuleSource=file.opts.resolveModuleSource;if(node.source&&resolveModuleSource){node.source.value=resolveModuleSource(node.source.value)}}function ExportDeclaration(node,parent,scope){ImportDeclaration.apply(this,arguments);if(node.isType)return;var declar=node.declaration;var getDeclar=function getDeclar(){declar._ignoreUserWhitespace=true;return declar};if(node["default"]){if(t.isClassDeclaration(declar)){node.declaration=declar.id;return[getDeclar(),node]}else if(t.isClassExpression(declar)){var temp=scope.generateUidIdentifier("default");declar=t.variableDeclaration("var",[t.variableDeclarator(temp,declar)]);node.declaration=temp;return[getDeclar(),node]}else if(t.isFunctionDeclaration(declar)){node._blockHoist=2;node.declaration=declar.id;return[getDeclar(),node]}}else{if(t.isFunctionDeclaration(declar)){node.specifiers=[t.importSpecifier(declar.id,declar.id)];node.declaration=null;node._blockHoist=2;return[getDeclar(),node]}}}exports.__esModule=true},{"../../../types":122}],90:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.Program=Program;var t=_interopRequire(require("../../../types"));function Program(program,parent,scope,file){if(file.transformers.useStrict.canRun()){program.body.unshift(t.expressionStatement(t.literal("use strict")))}}exports.__esModule=true},{"../../../types":122}],91:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.ExpressionStatement=ExpressionStatement;var t=_interopRequire(require("../../../types"));var optional=exports.optional=true;function ExpressionStatement(node){var expr=node.expression;if(t.isLiteral(expr)||t.isIdentifier(node)&&t.hasBinding(node.name)){this.remove()}}var IfStatement=exports.IfStatement={exit:function exit(node){var consequent=node.consequent;var alternate=node.alternate;var test=node.test;if(t.isLiteral(test)&&test.value){return consequent}if(t.isFalsyExpression(test)){if(alternate){return alternate}else{return this.remove()}}if(t.isBlockStatement(alternate)&&!alternate.body.length){alternate=node.alternate=null}if(t.blockStatement(consequent)&&!consequent.body.length&&t.isBlockStatement(alternate)&&alternate.body.length){node.consequent=node.alternate;node.alternate=null;node.test=t.unaryExpression("!",test,true)}}};exports.__esModule=true},{"../../../types":122}],92:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.CallExpression=CallExpression;var t=_interopRequire(require("../../../types"));var isConsole=t.buildMatchMemberExpression("console",true);var optional=exports.optional=true;function CallExpression(node,parent){if(isConsole(node.callee)){if(t.isExpressionStatement(parent)){this.parentPath.remove()}else{this.remove()}}}exports.__esModule=true},{"../../../types":122}],93:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.ExpressionStatement=ExpressionStatement;var t=_interopRequire(require("../../../types"));var optional=exports.optional=true;function ExpressionStatement(node){if(t.isIdentifier(node.expression,{name:"debugger"})){this.remove()}}exports.__esModule=true},{"../../../types":122}],94:[function(require,module,exports){"use strict";exports.Scopable=Scopable;var optional=exports.optional=true;function Scopable(){}exports.__esModule=true},{}],95:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var remapAsyncToGenerator=_interopRequire(require("../../helpers/remap-async-to-generator"));exports.manipulateOptions=require("./bluebird-coroutines").manipulateOptions;var optional=exports.optional=true;exports.Function=function(node,parent,scope,file){if(!node.async||node.generator)return;return remapAsyncToGenerator(node,file.addHelper("async-to-generator"),scope)};exports.__esModule=true},{"../../helpers/remap-async-to-generator":40,"./bluebird-coroutines":96}],96:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.manipulateOptions=manipulateOptions;var remapAsyncToGenerator=_interopRequire(require("../../helpers/remap-async-to-generator"));var t=_interopRequire(require("../../../types"));function manipulateOptions(opts){opts.experimental=true;opts.blacklist.push("regenerator")}var optional=exports.optional=true;exports.Function=function(node,parent,scope,file){if(!node.async||node.generator)return;return remapAsyncToGenerator(node,t.memberExpression(file.addImport("bluebird",null,true),t.identifier("coroutine")),scope)};exports.__esModule=true},{"../../../types":122,"../../helpers/remap-async-to-generator":40}],97:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.TypeCastExpression=TypeCastExpression;exports.ImportDeclaration=ImportDeclaration;exports.ExportDeclaration=ExportDeclaration;var t=_interopRequire(require("../../../types"));function TypeCastExpression(node){return node.expression}function ImportDeclaration(node){if(node.isType)this.remove()}function ExportDeclaration(node){if(t.isTypeAlias(node.declaration))this.remove()}exports.__esModule=true},{"../../../types":122}],98:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.manipulateOptions=manipulateOptions;var react=_interopRequire(require("../../helpers/react"));var t=_interopRequire(require("../../../types"));function manipulateOptions(opts){opts.blacklist.push("react")}var optional=exports.optional=true;require("../../helpers/build-react-transformer")(exports,{pre:function pre(state){state.callee=state.tagExpr},post:function post(state){if(react.isCompatTag(state.tagName)){state.call=t.callExpression(t.memberExpression(t.memberExpression(t.identifier("React"),t.identifier("DOM")),state.tagExpr,t.isLiteral(state.tagExpr)),state.args)}}});exports.__esModule=true},{"../../../types":122,"../../helpers/build-react-transformer":33,"../../helpers/react":38}],99:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.Program=Program;var react=_interopRequire(require("../../helpers/react"));var t=_interopRequire(require("../../../types"));var JSX_ANNOTATION_REGEX=/^\*\s*@jsx\s+([^\s]+)/;function Program(node,parent,scope,file){var id="React.createElement";for(var i=0;i<file.ast.comments.length;i++){var comment=file.ast.comments[i];var matches=JSX_ANNOTATION_REGEX.exec(comment.value);if(matches){id=matches[1];if(id==="React.DOM"){throw file.errorWithNode(comment,"The @jsx React.DOM pragma has been deprecated as of React 0.12")}else{break}}}file.set("jsxIdentifier",id.split(".").map(t.identifier).reduce(function(object,property){return t.memberExpression(object,property)}))}require("../../helpers/build-react-transformer")(exports,{pre:function pre(state){var tagName=state.tagName;var args=state.args;if(react.isCompatTag(tagName)){args.push(t.literal(tagName))}else{args.push(state.tagExpr)}},post:function post(state,file){state.callee=file.get("jsxIdentifier")}});exports.__esModule=true},{"../../../types":122,"../../helpers/build-react-transformer":33,"../../helpers/react":38}],100:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.check=check;var regenerator=_interopRequire(require("regenerator-babel"));var t=_interopRequire(require("../../../types"));function check(node){return t.isFunction(node)&&(node.async||node.generator)}var Program=exports.Program={enter:function enter(ast){regenerator.transform(ast);this.stop()}};exports.__esModule=true},{"../../../types":122,"regenerator-babel":316}],101:[function(require,module,exports){"use strict";var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.manipulateOptions=manipulateOptions;exports.Program=Program;exports.pre=pre;exports.Identifier=Identifier;var includes=_interopRequire(require("lodash/collection/includes"));var util=_interopRequireWildcard(require("../../../util"));var core=_interopRequire(require("core-js/library"));var has=_interopRequire(require("lodash/object/has"));var t=_interopRequire(require("../../../types"));var isSymboliterator=t.buildMatchMemberExpression("Symbol.iterator");var coreHas=function coreHas(node){return node.name!=="_"&&has(core,node.name)};var ALIASABLE_CONSTRUCTORS=["Symbol","Promise","Map","WeakMap","Set","WeakSet"];var astVisitor={enter:function enter(node,parent,scope,file){var prop;if(t.isMemberExpression(node)&&t.isReferenced(node,parent)){var obj=node.object;prop=node.property;if(!t.isReferenced(obj,node))return;if(!node.computed&&coreHas(obj)&&has(core[obj.name],prop.name)&&!scope.getBindingIdentifier(obj.name)){this.skip();return t.prependToMemberExpression(node,file.get("coreIdentifier"))}}else if(t.isReferencedIdentifier(node,parent)&&!t.isMemberExpression(parent)&&includes(ALIASABLE_CONSTRUCTORS,node.name)&&!scope.getBindingIdentifier(node.name)){return t.memberExpression(file.get("coreIdentifier"),node)}else if(t.isCallExpression(node)){var callee=node.callee;if(node.arguments.length)return false;if(!t.isMemberExpression(callee))return false;if(!callee.computed)return false;prop=callee.property;if(!isSymboliterator(prop))return false;return util.template("corejs-iterator",{CORE_ID:file.get("coreIdentifier"),VALUE:callee.object})}else if(t.isBinaryExpression(node)){if(node.operator!=="in")return;var left=node.left;if(!isSymboliterator(left))return;return util.template("corejs-is-iterator",{CORE_ID:file.get("coreIdentifier"),VALUE:node.right})}}};var optional=exports.optional=true;function manipulateOptions(opts){if(opts.whitelist.length)opts.whitelist.push("es6.modules")}function Program(node,parent,scope,file){scope.traverse(node,astVisitor,file)}function pre(file){file.setDynamic("helpersNamespace",function(){return file.addImport("babel-runtime/helpers","babelHelpers")});file.setDynamic("coreIdentifier",function(){return file.addImport("babel-runtime/core-js","core")});file.setDynamic("regeneratorIdentifier",function(){return file.addImport("babel-runtime/regenerator","regeneratorRuntime")})}function Identifier(node,parent,scope,file){if(t.isReferencedIdentifier(node,parent,{name:"regeneratorRuntime"})){return file.get("regeneratorIdentifier")}}exports.__esModule=true},{"../../../types":122,"../../../util":124,"core-js/library":176,"lodash/collection/includes":204,"lodash/object/has":300}],102:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};exports.Program=Program;exports.ThisExpression=ThisExpression;exports.CallExpression=CallExpression;var messages=_interopRequireWildcard(require("../../../messages"));var t=_interopRequire(require("../../../types"));function Program(program){var first=program.body[0];if(t.isExpressionStatement(first)&&t.isLiteral(first.expression,{value:"use strict"})){program.body.shift()}}exports.FunctionDeclaration=exports.FunctionExpression=function(){this.skip()};function ThisExpression(){return t.identifier("undefined")}function CallExpression(node,parent,scope,file){if(t.isIdentifier(node.callee,{name:"eval"})){throw file.errorWithNode(node,messages.get("evalInStrictMode"))}}exports.__esModule=true},{"../../../messages":27,"../../../types":122}],103:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var messages=_interopRequireWildcard(require("../../../messages"));var build=_interopRequire(require("../../helpers/build-conditional-assignment-operator-transformer"));var t=_interopRequire(require("../../../types"));var playground=exports.playground=true;build(exports,{is:function(_is){var _isWrapper=function is(_x,_x2){return _is.apply(this,arguments)};_isWrapper.toString=function(){return _is.toString()};return _isWrapper}(function(node,file){var is=t.isAssignmentExpression(node)&&node.operator==="||=";if(is){var left=node.left;if(!t.isMemberExpression(left)&&!t.isIdentifier(left)){throw file.errorWithNode(left,messages.get("expectedMemberExpressionOrIdentifier"))}return true}}),build:function build(node){return t.unaryExpression("!",node,true)}});exports.__esModule=true},{"../../../messages":27,"../../../types":122,"../../helpers/build-conditional-assignment-operator-transformer":32}],104:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var build=_interopRequire(require("../../helpers/build-conditional-assignment-operator-transformer"));var t=_interopRequire(require("../../../types"));var playground=exports.playground=true;build(exports,{is:function(_is){var _isWrapper=function is(_x){return _is.apply(this,arguments)};_isWrapper.toString=function(){return _is.toString()};return _isWrapper}(function(node){var is=t.isAssignmentExpression(node)&&node.operator==="?=";if(is)t.assertMemberExpression(node.left);return is}),build:function build(node,file){return t.unaryExpression("!",t.callExpression(t.memberExpression(file.addHelper("has-own"),t.identifier("call")),[node.object,node.property]),true)}});exports.__esModule=true},{"../../../types":122,"../../helpers/build-conditional-assignment-operator-transformer":32}],105:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _toConsumableArray=function(arr){if(Array.isArray(arr)){for(var i=0,arr2=Array(arr.length);i<arr.length;i++)arr2[i]=arr[i];return arr2}else{return Array.from(arr)}};exports.BindMemberExpression=BindMemberExpression;exports.BindFunctionExpression=BindFunctionExpression;var t=_interopRequire(require("../../../types"));var playground=exports.playground=true;function BindMemberExpression(node,parent,scope){var object=node.object;var prop=node.property;var temp=scope.generateTempBasedOnNode(node.object);if(temp)object=temp;var call=t.callExpression(t.memberExpression(t.memberExpression(object,prop),t.identifier("bind")),[object].concat(_toConsumableArray(node.arguments)));if(temp){return t.sequenceExpression([t.assignmentExpression("=",temp,node.object),call])}else{return call}}function BindFunctionExpression(node,parent,scope){var buildCall=function buildCall(args){var param=scope.generateUidIdentifier("val");return t.functionExpression(null,[param],t.blockStatement([t.returnStatement(t.callExpression(t.memberExpression(param,node.callee),args))]))};var temp=scope.generateTemp("args");return t.sequenceExpression([t.assignmentExpression("=",temp,t.arrayExpression(node.arguments)),buildCall(node.arguments.map(function(node,i){return t.memberExpression(temp,t.literal(i),true)}))])}exports.__esModule=true},{"../../../types":122}],106:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var t=_interopRequire(require("../../../types"));var playground=exports.playground=true;var visitor={enter:function enter(node,parent,scope,state){if(t.isFunction(node))return this.skip();if(t.isReturnStatement(node)&&node.argument){node.argument=t.memberExpression(t.callExpression(state.file.addHelper("define-property"),[t.thisExpression(),state.key,node.argument]),state.key,true)}}};exports.Property=exports.MethodDefinition=function(node,parent,scope,file){if(node.kind!=="memo")return;node.kind="get";var value=node.value;t.ensureBlock(value);var key=node.key;if(t.isIdentifier(key)&&!node.computed){key=t.literal(key.name)}var state={key:key,file:file};scope.traverse(value,visitor,state);return node};exports.__esModule=true},{"../../../types":122}],107:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.BlockStatement=BlockStatement;var t=_interopRequire(require("../../../types"));function BlockStatement(node,parent,scope,file){if(t.isFunction(parent)&&parent.body===node||t.isExportDeclaration(parent)){return}for(var i=0;i<node.body.length;i++){var func=node.body[i];if(!t.isFunctionDeclaration(func))continue;var declar=t.variableDeclaration("let",[t.variableDeclarator(func.id,t.toExpression(func))]);declar._blockHoist=2;func.id=null;node.body[i]=declar;file.checkNode(declar)}}exports.__esModule=true},{"../../../types":122}],108:[function(require,module,exports){"use strict";exports.FunctionExpression=require("../../helpers/name-method").bare;exports.__esModule=true},{"../../helpers/name-method":37}],109:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.AssignmentExpression=AssignmentExpression;exports.ExpressionStatement=ExpressionStatement;exports.ObjectExpression=ObjectExpression;var t=_interopRequire(require("../../../types"));var pull=_interopRequire(require("lodash/array/pull"));function isProtoKey(node){return t.isLiteral(t.toComputedKey(node,node.key),{value:"__proto__"})}function isProtoAssignmentExpression(node){var left=node.left;return t.isMemberExpression(left)&&t.isLiteral(t.toComputedKey(left,left.property),{value:"__proto__"})}function buildDefaultsCallExpression(expr,ref,file){return t.expressionStatement(t.callExpression(file.addHelper("defaults"),[ref,expr.right]))}var secondPass=exports.secondPass=true;var optional=exports.optional=true;function AssignmentExpression(node,parent,scope,file){if(!isProtoAssignmentExpression(node))return;var nodes=[];var left=node.left.object;var temp=scope.generateTempBasedOnNode(node.left.object);nodes.push(t.expressionStatement(t.assignmentExpression("=",temp,left)));nodes.push(buildDefaultsCallExpression(node,temp,file));if(temp)nodes.push(temp);return t.toSequenceExpression(nodes)}function ExpressionStatement(node,parent,scope,file){var expr=node.expression;if(!t.isAssignmentExpression(expr,{operator:"="}))return;if(isProtoAssignmentExpression(expr)){return buildDefaultsCallExpression(expr,expr.left.object,file)}}function ObjectExpression(node,parent,scope,file){var proto;for(var i=0;i<node.properties.length;i++){var prop=node.properties[i];if(isProtoKey(prop)){proto=prop.value;pull(node.properties,prop)}}if(proto){var args=[t.objectExpression([]),proto];if(node.properties.length)args.push(node);return t.callExpression(file.addHelper("extends"),args)}}exports.__esModule=true},{"../../../types":122,"lodash/array/pull":198}],110:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.UnaryExpression=UnaryExpression;var t=_interopRequire(require("../../../types"));var optional=exports.optional=true;function UnaryExpression(node,parent,scope,file){this.skip();if(node.operator==="typeof"){var call=t.callExpression(file.addHelper("typeof"),[node.argument]);if(t.isIdentifier(node.argument)){var undefLiteral=t.literal("undefined");return t.conditionalExpression(t.binaryExpression("===",t.unaryExpression("typeof",node.argument),undefLiteral),undefLiteral,call)}else{return call}}}exports.__esModule=true},{"../../../types":122}],111:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.Identifier=Identifier;var t=_interopRequire(require("../../../types"));var optional=exports.optional=true;function Identifier(node,parent){if(node.name==="undefined"&&t.isReferenced(node,parent)){return t.unaryExpression("void",t.literal(0),true)}}exports.__esModule=true},{"../../../types":122}],112:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var messages=_interopRequireWildcard(require("../../../messages"));var _types=require("../../../types");var t=_interopRequire(_types);exports.check=_types.isFor;exports.ForInStatement=exports.ForOfStatement=function(node,parent,scope,file){var left=node.left;if(t.isVariableDeclaration(left)){var declar=left.declarations[0];if(declar.init)throw file.errorWithNode(declar,messages.get("noAssignmentsInForHead"))}};exports.__esModule=true},{"../../../messages":27,"../../../types":122}],113:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};exports.CallExpression=CallExpression;exports.ModuleDeclaration=ModuleDeclaration;var messages=_interopRequireWildcard(require("../../../messages"));var t=_interopRequire(require("../../../types"));var check=function check(source,file){if(t.isLiteral(source)){var name=source.value;var lower=name.toLowerCase();if(lower==="react"&&name!==lower){throw file.errorWithNode(source,messages.get("didYouMean","react"))}}};function CallExpression(node,parent,scope,file){if(t.isIdentifier(node.callee,{name:"require"})&&node.arguments.length===1){check(node.arguments[0],file)}}function ModuleDeclaration(node,parent,scope,file){check(node.source,file)}exports.__esModule=true},{"../../../messages":27,"../../../types":122}],114:[function(require,module,exports){"use strict";var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};exports.check=check;var messages=_interopRequireWildcard(require("../../../messages"));function check(node){return node.kind==="set"}exports.MethodDefinition=exports.Property=function(node,parent,scope,file){if(node.kind==="set"&&node.value.params.length!==1){throw file.errorWithNode(node.value,messages.get("settersInvalidParamLength"))}};exports.__esModule=true},{"../../../messages":27}],115:[function(require,module,exports){"use strict";var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj}};var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.Identifier=Identifier;var levenshtein=_interopRequire(require("leven"));var messages=_interopRequireWildcard(require("../../../messages"));var t=_interopRequire(require("../../../types"));var optional=exports.optional=true;function Identifier(node,parent,scope,file){if(!t.isReferenced(node,parent))return;if(scope.hasBinding(node.name))return;var bindings=scope.getAllBindings();var closest;var shortest=-1;for(var name in bindings){var distance=levenshtein(node.name,name);if(distance<=0||distance>3)continue;if(distance<=shortest)continue;closest=name;shortest=distance}var msg;if(closest){msg=messages.get("undeclaredVariableSuggestion",node.name,closest)}else{msg=messages.get("undeclaredVariable",node.name)}throw file.errorWithNode(node,msg,ReferenceError)}exports.__esModule=true},{"../../../messages":27,"../../../types":122,leven:192}],116:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var TraversalPath=_interopRequire(require("./path"));var flatten=_interopRequire(require("lodash/array/flatten"));var compact=_interopRequire(require("lodash/array/compact"));var TraversalConext=function(){function TraversalConext(scope,opts,state,parentPath){_classCallCheck(this,TraversalConext);this.shouldFlatten=false;this.parentPath=parentPath;this.scope=scope;this.state=state;this.opts=opts}TraversalConext.prototype.flatten=function flatten(){this.shouldFlatten=true};TraversalConext.prototype.visitNode=function visitNode(node,obj,key){var iteration=new TraversalPath(this,node,obj,key);return iteration.visit()};TraversalConext.prototype.visit=function visit(node,key){var nodes=node[key];if(!nodes)return;if(!Array.isArray(nodes)){return this.visitNode(node,node,key)}if(nodes.length===0){return}for(var i=0;i<nodes.length;i++){if(nodes[i]&&this.visitNode(node,nodes,i)){return true}}if(this.shouldFlatten){node[key]=flatten(node[key]);if(key==="body"){node[key]=compact(node[key])}}};return TraversalConext}();module.exports=TraversalConext},{"./path":118,"lodash/array/compact":195,"lodash/array/flatten":196}],117:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};module.exports=traverse;var TraversalContext=_interopRequire(require("./context"));var includes=_interopRequire(require("lodash/collection/includes"));var t=_interopRequire(require("../types"));function traverse(parent,opts,scope,state){if(!parent)return;if(!opts.noScope&&!scope){if(parent.type!=="Program"&&parent.type!=="File"){throw new Error("Must pass a scope unless traversing a Program/File got a "+parent.type+" node")}}if(!opts)opts={};if(!opts.enter)opts.enter=function(){};if(!opts.exit)opts.exit=function(){};if(Array.isArray(parent)){for(var i=0;i<parent.length;i++){traverse.node(parent[i],opts,scope,state)}}else{traverse.node(parent,opts,scope,state)}}traverse.node=function(node,opts,scope,state,parentPath){var keys=t.VISITOR_KEYS[node.type];if(!keys)return;var context=new TraversalContext(scope,opts,state,parentPath);for(var i=0;i<keys.length;i++){if(context.visit(node,keys[i])){return}}};function clearNode(node){node._declarations=null;node.extendedRange=null;node._scopeInfo=null;node.tokens=null;node.range=null;node.start=null;node.end=null;node.loc=null;node.raw=null;if(Array.isArray(node.trailingComments)){clearComments(node.trailingComments)}if(Array.isArray(node.leadingComments)){clearComments(node.leadingComments)}}var clearVisitor={noScope:true,enter:clearNode};function clearComments(comments){for(var i=0;i<comments.length;i++){clearNode(comments[i])}}traverse.removeProperties=function(tree){clearNode(tree);traverse(tree,clearVisitor);return tree};traverse.explode=function(obj){for(var type in obj){var fns=obj[type];var aliases=t.FLIPPED_ALIAS_KEYS[type];if(aliases){for(var i=0;i<aliases.length;i++){obj[aliases[i]]=fns}}}return obj};function hasBlacklistedType(node,parent,scope,state){if(node.type===state.type){state.has=true;this.skip()}}traverse.hasType=function(tree,scope,type,blacklistTypes){if(includes(blacklistTypes,tree.type))return false;if(tree.type===type)return true;var state={has:false,type:type};traverse(tree,{blacklist:blacklistTypes,enter:hasBlacklistedType},scope,state);return state.has}},{"../types":122,"./context":116,"lodash/collection/includes":204}],118:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _prototypeProperties=function(child,staticProps,instanceProps){if(staticProps)Object.defineProperties(child,staticProps);if(instanceProps)Object.defineProperties(child.prototype,instanceProps)};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var traverse=_interopRequire(require("./index"));var includes=_interopRequire(require("lodash/collection/includes"));var Scope=_interopRequire(require("./scope"));var t=_interopRequire(require("../types"));var TraversalPath=function(){function TraversalPath(context,parent,container,key){_classCallCheck(this,TraversalPath);this.shouldRemove=false;this.shouldSkip=false;this.shouldStop=false;this.parentPath=context.parentPath;this.context=context;this.state=this.context.state;this.opts=this.context.opts;this.container=container;this.key=key;this.parent=parent;this.state=context.state;this.setScope()}TraversalPath.getScope=function getScope(node,parent,scope){var ourScope=scope;if(t.isScope(node,parent)){ourScope=new Scope(node,parent,scope)}return ourScope};TraversalPath.prototype.setScope=function setScope(){this.scope=TraversalPath.getScope(this.node,this.parent,this.context.scope)};TraversalPath.prototype.remove=function remove(){this.shouldRemove=true;this.shouldSkip=true};TraversalPath.prototype.skip=function skip(){this.shouldSkip=true};TraversalPath.prototype.stop=function stop(){this.shouldStop=true;this.shouldSkip=true};TraversalPath.prototype.flatten=function flatten(){this.context.flatten()};TraversalPath.prototype.call=function call(key){var node=this.node;if(!node)return;var opts=this.opts;var fn=opts[key]||opts;if(opts[node.type])fn=opts[node.type][key]||fn;var replacement=fn.call(this,node,this.parent,this.scope,this.state);if(replacement){this.node=replacement}if(this.shouldRemove){this.container[this.key]=null;this.flatten()}};TraversalPath.prototype.visit=function visit(){var opts=this.opts;var node=this.node;if(opts.blacklist&&opts.blacklist.indexOf(node.type)>-1){return false}this.call("enter");if(this.shouldSkip){return this.shouldStop}node=this.node;if(Array.isArray(node)){for(var i=0;i<node.length;i++){traverse.node(node[i],opts,this.scope,this.state,this)}}else{traverse.node(node,opts,this.scope,this.state,this);this.call("exit")}return this.shouldStop};TraversalPath.prototype.isReferencedIdentifier=function isReferencedIdentifier(){return t.isReferencedIdentifier(this.node)};_prototypeProperties(TraversalPath,null,{node:{get:function(){return this.container[this.key]},set:function(replacement){var isArray=Array.isArray(replacement);var inheritTo=replacement;if(isArray)inheritTo=replacement[0];if(inheritTo)t.inheritsComments(inheritTo,this.node);this.container[this.key]=replacement;this.setScope();var file=this.scope&&this.scope.file;if(file){if(isArray){for(var i=0;i<replacement.length;i++){file.checkNode(replacement[i],this.scope)}}else{file.checkNode(replacement,this.scope)}}if(isArray){if(includes(t.STATEMENT_OR_BLOCK_KEYS,this.key)&&!t.isBlockStatement(this.container)){t.ensureBlock(this.container,this.key)}this.flatten()}},configurable:true}});return TraversalPath}();module.exports=TraversalPath},{"../types":122,"./index":117,"./scope":119,"lodash/collection/includes":204}],119:[function(require,module,exports){"use strict";var _interopRequireWildcard=function(obj){return obj&&obj.__esModule?obj:{"default":obj} };var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var _classCallCheck=function(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function")}};var includes=_interopRequire(require("lodash/collection/includes"));var traverse=_interopRequire(require("./index"));var defaults=_interopRequire(require("lodash/object/defaults"));var messages=_interopRequireWildcard(require("../messages"));var globals=_interopRequire(require("globals"));var flatten=_interopRequire(require("lodash/array/flatten"));var extend=_interopRequire(require("lodash/object/extend"));var object=_interopRequire(require("../helpers/object"));var each=_interopRequire(require("lodash/collection/each"));var t=_interopRequire(require("../types"));var functionVariableVisitor={enter:function enter(node,parent,scope,state){if(t.isFor(node)){each(t.FOR_INIT_KEYS,function(key){var declar=node[key];if(t.isVar(declar))state.scope.registerBinding("var",declar)})}if(t.isFunction(node))return this.skip();if(state.blockId&&node===state.blockId)return;if(t.isBlockScoped(node))return;if(t.isExportDeclaration(node)&&t.isDeclaration(node.declaration))return;if(t.isDeclaration(node))state.scope.registerDeclaration(node)}};var programReferenceVisitor={enter:function enter(node,parent,scope,state){if(t.isReferencedIdentifier(node,parent)&&!scope.hasBinding(node.name)){state.addGlobal(node)}else if(t.isLabeledStatement(node)){state.addGlobal(node)}else if(t.isAssignmentExpression(node)||t.isUpdateExpression(node)||t.isUnaryExpression(node)&&node.operator==="delete"){scope.registerBindingReassignment(node)}}};var blockVariableVisitor={enter:function enter(node,parent,scope,state){if(t.isFunctionDeclaration(node)||t.isBlockScoped(node)){state.registerDeclaration(node)}else if(t.isScope(node,parent)){this.skip()}}};var Scope=function(){function Scope(block,parentBlock,parent,file){_classCallCheck(this,Scope);this.parent=parent;this.file=parent?parent.file:file;this.parentBlock=parentBlock;this.block=block;this.crawl()}Scope.globals=flatten([globals.builtin,globals.browser,globals.node].map(Object.keys));Scope.prototype.traverse=function(_traverse){var _traverseWrapper=function traverse(_x,_x2,_x3){return _traverse.apply(this,arguments)};_traverseWrapper.toString=function(){return _traverse.toString()};return _traverseWrapper}(function(node,opts,state){traverse(node,opts,this,state)});Scope.prototype.generateTemp=function generateTemp(name){var id=this.generateUidIdentifier(name||"temp");this.push({key:id.name,id:id});return id};Scope.prototype.generateUidIdentifier=function generateUidIdentifier(name){var id=t.identifier(this.generateUid(name));this.getFunctionParent().registerBinding("uid",id);return id};Scope.prototype.generateUid=function generateUid(name){name=t.toIdentifier(name).replace(/^_+/,"");var uid;var i=0;do{uid=this._generateUid(name,i);i++}while(this.hasBinding(uid)||this.hasGlobal(uid));return uid};Scope.prototype._generateUid=function _generateUid(name,i){var id=name;if(i>1)id+=i;return"_"+id};Scope.prototype.generateUidBasedOnNode=function generateUidBasedOnNode(parent){var node=parent;if(t.isAssignmentExpression(parent)){node=parent.left}else if(t.isVariableDeclarator(parent)){node=parent.id}else if(t.isProperty(node)){node=node.key}var parts=[];var add=function(_add){var _addWrapper=function add(_x){return _add.apply(this,arguments)};_addWrapper.toString=function(){return _add.toString()};return _addWrapper}(function(node){if(t.isMemberExpression(node)){add(node.object);add(node.property)}else if(t.isIdentifier(node)){parts.push(node.name)}else if(t.isLiteral(node)){parts.push(node.value)}else if(t.isCallExpression(node)){add(node.callee)}});add(node);var id=parts.join("$");id=id.replace(/^_/,"")||"ref";return this.generateUidIdentifier(id)};Scope.prototype.generateTempBasedOnNode=function generateTempBasedOnNode(node){if(t.isIdentifier(node)&&this.hasBinding(node.name)){return null}var id=this.generateUidBasedOnNode(node);this.push({key:id.name,id:id});return id};Scope.prototype.checkBlockScopedCollisions=function checkBlockScopedCollisions(kind,name,id){var local=this.getOwnBindingInfo(name);if(!local)return;if(kind==="param")return;if(kind==="hoisted"&&local.kind==="let")return;if(local.kind==="let"||local.kind==="const"||local.kind==="module"){throw this.file.errorWithNode(id,messages.get("scopeDuplicateDeclaration",name),TypeError)}};Scope.prototype.rename=function rename(oldName,newName){if(!newName)newName=this.generateUidIdentifier(oldName).name;var info=this.getBindingInfo(oldName);if(!info)return;var binding=info.identifier;var scope=info.scope;scope.traverse(scope.block,{enter:function enter(node,parent,scope){if(t.isReferencedIdentifier(node,parent)&&node.name===oldName){node.name=newName}else if(t.isDeclaration(node)){var ids=t.getBindingIdentifiers(node);for(var name in ids){if(name===oldName)ids[name].name=newName}}else if(t.isScope(node,parent)){if(!scope.bindingIdentifierEquals(oldName,binding)){this.skip()}}}});this.clearOwnBinding(oldName);scope.bindings[newName]=info;binding.name=newName};Scope.prototype.inferType=function inferType(node){var target;if(t.isVariableDeclarator(node)){target=node.init}if(t.isArrayExpression(target)){return t.genericTypeAnnotation(t.identifier("Array"))}if(t.isObjectExpression(target)){return}if(t.isLiteral(target)){return}if(t.isCallExpression(target)&&t.isIdentifier(target.callee)){var funcInfo=this.getBindingInfo(target.callee.name);if(funcInfo){var funcNode=funcInfo.node;return!funcInfo.reassigned&&t.isFunction(funcNode)&&node.returnType}}if(t.isIdentifier(target)){return}};Scope.prototype.isTypeGeneric=function isTypeGeneric(name,genericName){var info=this.getBindingInfo(name);if(!info)return false;var type=info.typeAnnotation;return t.isGenericTypeAnnotation(type)&&t.isIdentifier(type.id,{name:genericName})};Scope.prototype.assignTypeGeneric=function assignTypeGeneric(name,type){this.assignType(name,t.genericTypeAnnotation(t.identifier(type)))};Scope.prototype.assignType=function assignType(name,type){var info=this.getBindingInfo(name);if(!info)return;info.identifier.typeAnnotation=info.typeAnnotation=type};Scope.prototype.getTypeAnnotation=function getTypeAnnotation(name,id,node){var info={annotation:null,inferred:false};var type;if(id.typeAnnotation){type=id.typeAnnotation}if(!type){info.inferred=true;type=this.inferType(node)}if(type){if(t.isTypeAnnotation(type))type=type.typeAnnotation;info.annotation=type}return info};Scope.prototype.toArray=function toArray(node,i){var file=this.file;if(t.isIdentifier(node)&&this.isTypeGeneric(node.name,"Array")){return node}if(t.isArrayExpression(node)){return node}if(t.isIdentifier(node,{name:"arguments"})){return t.callExpression(t.memberExpression(file.addHelper("slice"),t.identifier("call")),[node])}var helperName="to-array";var args=[node];if(i===true){helperName="to-consumable-array"}else if(i){args.push(t.literal(i));helperName="sliced-to-array"}return t.callExpression(file.addHelper(helperName),args)};Scope.prototype.clearOwnBinding=function clearOwnBinding(name){delete this.bindings[name]};Scope.prototype.registerDeclaration=function registerDeclaration(node){if(t.isFunctionDeclaration(node)){this.registerBinding("hoisted",node)}else if(t.isVariableDeclaration(node)){for(var i=0;i<node.declarations.length;i++){this.registerBinding(node.kind,node.declarations[i])}}else if(t.isClassDeclaration(node)){this.registerBinding("let",node)}else if(t.isImportDeclaration(node)||t.isExportDeclaration(node)){this.registerBinding("module",node)}else{this.registerBinding("unknown",node)}};Scope.prototype.registerBindingReassignment=function registerBindingReassignment(node){var ids=t.getBindingIdentifiers(node);for(var name in ids){var info=this.getBindingInfo(name);if(info){info.reassigned=true;if(info.typeAnnotationInferred){info.typeAnnotation=null}}}};Scope.prototype.registerBinding=function registerBinding(kind,node){if(!kind)throw new ReferenceError("no `kind`");var ids=t.getBindingIdentifiers(node);for(var name in ids){var id=ids[name];this.checkBlockScopedCollisions(kind,name,id);var typeInfo=this.getTypeAnnotation(name,id,node);this.bindings[name]={typeAnnotationInferred:typeInfo.inferred,typeAnnotation:typeInfo.annotation,reassigned:false,identifier:id,scope:this,node:node,kind:kind}}};Scope.prototype.registerVariableDeclaration=function registerVariableDeclaration(declar){var declars=declar.declarations;for(var i=0;i<declars.length;i++){this.registerBinding(declars[i],declar.kind)}};Scope.prototype.addGlobal=function addGlobal(node){this.globals[node.name]=node};Scope.prototype.hasGlobal=function hasGlobal(name){var scope=this;do{if(scope.globals[name])return true}while(scope=scope.parent);return false};Scope.prototype.crawl=function crawl(){var block=this.block;var i;var info=block._scopeInfo;if(info){extend(this,info);return}info=block._scopeInfo={bindings:object(),globals:object()};extend(this,info);if(t.isLoop(block)){for(i=0;i<t.FOR_INIT_KEYS.length;i++){var node=block[t.FOR_INIT_KEYS[i]];if(t.isBlockScoped(node))this.registerBinding("let",node)}if(t.isBlockStatement(block.body)){block=block.body}}if(t.isFunctionExpression(block)&&block.id){if(!t.isProperty(this.parentBlock,{method:true})){this.registerBinding("var",block.id)}}if(t.isFunction(block)){for(i=0;i<block.params.length;i++){this.registerBinding("param",block.params[i])}this.traverse(block.body,blockVariableVisitor,this)}if(t.isBlockStatement(block)||t.isProgram(block)){this.traverse(block,blockVariableVisitor,this)}if(t.isCatchClause(block)){this.registerBinding("let",block.param)}if(t.isComprehensionExpression(block)){this.registerBinding("let",block)}if(t.isProgram(block)||t.isFunction(block)){this.traverse(block,functionVariableVisitor,{blockId:block.id,scope:this})}if(t.isProgram(block)){this.traverse(block,programReferenceVisitor,this)}};Scope.prototype.push=function push(opts){var block=this.block;if(t.isLoop(block)||t.isCatchClause(block)||t.isFunction(block)){t.ensureBlock(block);block=block.body}if(t.isBlockStatement(block)||t.isProgram(block)){var _block=block;if(!_block._declarations)_block._declarations={};block._declarations[opts.key]={kind:opts.kind,id:opts.id,init:opts.init}}else{throw new TypeError("cannot add a declaration here in node type "+block.type)}};Scope.prototype.getFunctionParent=function getFunctionParent(){var scope=this;while(scope.parent&&!t.isFunction(scope.block)){scope=scope.parent}return scope};Scope.prototype.getAllBindings=function getAllBindings(){var ids=object();var scope=this;do{defaults(ids,scope.bindings);scope=scope.parent}while(scope);return ids};Scope.prototype.getAllBindingsOfKind=function getAllBindingsOfKind(kind){var ids=object();var scope=this;do{for(var name in scope.bindings){var binding=scope.bindings[name];if(binding.kind===kind)ids[name]=binding}scope=scope.parent}while(scope);return ids};Scope.prototype.bindingIdentifierEquals=function bindingIdentifierEquals(name,node){return this.getBindingIdentifier(name)===node};Scope.prototype.getBindingInfo=function getBindingInfo(name){var scope=this;do{var binding=scope.getOwnBindingInfo(name);if(binding)return binding}while(scope=scope.parent)};Scope.prototype.getOwnBindingInfo=function getOwnBindingInfo(name){return this.bindings[name]};Scope.prototype.getBindingIdentifier=function getBindingIdentifier(name){var info=this.getBindingInfo(name);return info&&info.identifier};Scope.prototype.getOwnBindingIdentifier=function getOwnBindingIdentifier(name){var binding=this.bindings[name];return binding&&binding.identifier};Scope.prototype.hasOwnBinding=function hasOwnBinding(name){return!!this.getOwnBindingInfo(name)};Scope.prototype.hasBinding=function hasBinding(name){if(!name)return false;if(this.hasOwnBinding(name))return true;if(this.parentHasBinding(name))return true;if(includes(Scope.globals,name))return true;return false};Scope.prototype.parentHasBinding=function parentHasBinding(name){return this.parent&&this.parent.hasBinding(name)};return Scope}();module.exports=Scope},{"../helpers/object":24,"../messages":27,"../types":122,"./index":117,globals:187,"lodash/array/flatten":196,"lodash/collection/each":201,"lodash/collection/includes":204,"lodash/object/defaults":298,"lodash/object/extend":299}],120:[function(require,module,exports){module.exports={ExpressionStatement:["Statement"],BreakStatement:["Statement"],ContinueStatement:["Statement"],DebuggerStatement:["Statement"],DoWhileStatement:["Statement","Loop","While","Scopable"],IfStatement:["Statement"],ReturnStatement:["Statement"],SwitchStatement:["Statement"],ThrowStatement:["Statement"],TryStatement:["Statement"],WhileStatement:["Statement","Loop","While","Scopable"],WithStatement:["Statement"],EmptyStatement:["Statement"],LabeledStatement:["Statement"],VariableDeclaration:["Statement","Declaration"],ExportDeclaration:["Statement","Declaration","ModuleDeclaration"],ImportDeclaration:["Statement","Declaration","ModuleDeclaration"],PrivateDeclaration:["Statement","Declaration"],ArrowFunctionExpression:["Scopable","Function","Expression"],FunctionDeclaration:["Scopable","Function","Statement","Declaration"],FunctionExpression:["Scopable","Function","Expression"],ImportSpecifier:["ModuleSpecifier"],ExportSpecifier:["ModuleSpecifier"],BlockStatement:["Statement","Scopable"],Program:["Scopable"],CatchClause:["Scopable"],LogicalExpression:["Binary","Expression"],BinaryExpression:["Binary","Expression"],UnaryExpression:["UnaryLike","Expression"],SpreadProperty:["UnaryLike"],SpreadElement:["UnaryLike"],ClassDeclaration:["Statement","Declaration","Class"],ClassExpression:["Class","Expression"],ForOfStatement:["Scopable","Statement","For","Loop"],ForInStatement:["Scopable","Statement","For","Loop"],ForStatement:["Scopable","Statement","For","Loop"],ObjectPattern:["Pattern"],ArrayPattern:["Pattern"],AssignmentPattern:["Pattern"],Property:["UserWhitespacable"],ArrayExpression:["Expression"],AssignmentExpression:["Expression"],AwaitExpression:["Expression"],BindFunctionExpression:["Expression"],BindMemberExpression:["Expression"],CallExpression:["Expression"],ComprehensionExpression:["Expression","Scopable"],ConditionalExpression:["Expression"],Identifier:["Expression"],Literal:["Expression"],MemberExpression:["Expression"],NewExpression:["Expression"],ObjectExpression:["Expression"],SequenceExpression:["Expression"],TaggedTemplateExpression:["Expression"],ThisExpression:["Expression"],UpdateExpression:["Expression"],VirtualPropertyExpression:["Expression"],JSXEmptyExpression:["Expression"],JSXMemberExpression:["Expression"],YieldExpression:["Expression"],JSXAttribute:["JSX"],JSXClosingElement:["JSX"],JSXElement:["JSX","Expression"],JSXEmptyExpression:["JSX"],JSXExpressionContainer:["JSX"],JSXIdentifier:["JSX"],JSXMemberExpression:["JSX"],JSXNamespacedName:["JSX"],JSXOpeningElement:["JSX"],JSXSpreadAttribute:["JSX"]}},{}],121:[function(require,module,exports){module.exports={ArrayExpression:{elements:null},ArrowFunctionExpression:{params:null,body:null},AssignmentExpression:{operator:null,left:null,right:null},BinaryExpression:{operator:null,left:null,right:null},BlockStatement:{body:null},CallExpression:{callee:null,arguments:null},ConditionalExpression:{test:null,consequent:null,alternate:null},ExpressionStatement:{expression:null},File:{program:null,comments:null,tokens:null},FunctionExpression:{id:null,params:null,body:null,generator:false},FunctionDeclaration:{id:null,params:null,body:null,generator:false},GenericTypeAnnotation:{id:null,typeParameters:null},Identifier:{name:null},IfStatement:{test:null,consequent:null,alternate:null},ImportDeclaration:{specifiers:null,source:null},ImportSpecifier:{id:null,name:null},Literal:{value:null},LogicalExpression:{operator:null,left:null,right:null},MemberExpression:{object:null,property:null,computed:false},MethodDefinition:{key:null,value:null,computed:false,"static":false,kind:null},NewExpression:{callee:null,arguments:null},ObjectExpression:{properties:null},Program:{body:null},Property:{kind:null,key:null,value:null,computed:false},ReturnStatement:{argument:null},SequenceExpression:{expressions:null},TemplateLiteral:{quasis:null,expressions:null},ThrowExpression:{argument:null},UnaryExpression:{operator:null,argument:null,prefix:null},VariableDeclaration:{kind:null,declarations:null},VariableDeclarator:{id:null,init:null},WithStatement:{object:null,body:null},YieldExpression:{argument:null,delegate:null}}},{}],122:[function(require,module,exports){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};var toFastProperties=_interopRequire(require("../helpers/to-fast-properties"));var isString=_interopRequire(require("lodash/lang/isString"));var compact=_interopRequire(require("lodash/array/compact"));var esutils=_interopRequire(require("esutils"));var object=_interopRequire(require("../helpers/object"));var each=_interopRequire(require("lodash/collection/each"));var uniq=_interopRequire(require("lodash/array/uniq"));var t={};module.exports=t;function registerType(type,skipAliasCheck){var is=t["is"+type]=function(node,opts){return t.is(type,node,opts,skipAliasCheck)};t["assert"+type]=function(node,opts){if(!opts)opts={};if(!is(node,opts)){throw new Error("Expected type "+JSON.stringify(type)+" with option "+JSON.stringify(opts))}}}t.STATEMENT_OR_BLOCK_KEYS=["consequent","body"];t.NATIVE_TYPE_NAMES=["Array","Object","Number","Boolean","Date","Array","String"];t.FOR_INIT_KEYS=["left","init"];t.VISITOR_KEYS=require("./visitor-keys");t.ALIAS_KEYS=require("./alias-keys");t.FLIPPED_ALIAS_KEYS={};each(t.VISITOR_KEYS,function(keys,type){registerType(type,true)});each(t.ALIAS_KEYS,function(aliases,type){each(aliases,function(alias){var types=t.FLIPPED_ALIAS_KEYS[alias]=t.FLIPPED_ALIAS_KEYS[alias]||[];types.push(type)})});each(t.FLIPPED_ALIAS_KEYS,function(types,type){t[type.toUpperCase()+"_TYPES"]=types;registerType(type,false)});t.is=function(type,node,opts,skipAliasCheck){if(!node)return false;var typeMatches=type===node.type;if(!typeMatches&&!skipAliasCheck){var aliases=t.FLIPPED_ALIAS_KEYS[type];if(typeof aliases!=="undefined"){typeMatches=aliases.indexOf(node.type)>-1}}if(!typeMatches){return false}if(typeof opts!=="undefined"){return t.shallowEqual(node,opts)}return true};t.BUILDER_KEYS=require("./builder-keys");each(t.VISITOR_KEYS,function(keys,type){if(t.BUILDER_KEYS[type])return;var defs={};each(keys,function(key){defs[key]=null});t.BUILDER_KEYS[type]=defs});each(t.BUILDER_KEYS,function(keys,type){t[type[0].toLowerCase()+type.slice(1)]=function(){var node={};node.start=null;node.type=type;var i=0;for(var key in keys){var arg=arguments[i++];if(arg===undefined)arg=keys[key];node[key]=arg}return node}});t.toComputedKey=function(node,key){if(!node.computed){if(t.isIdentifier(key))key=t.literal(key.name)}return key};t.isFalsyExpression=function(node){if(t.isLiteral(node)){return!node.value}else if(t.isIdentifier(node)){return node.name==="undefined"}return false};t.toSequenceExpression=function(nodes,scope){var exprs=[];each(nodes,function(node){if(t.isExpression(node)){exprs.push(node)}if(t.isExpressionStatement(node)){exprs.push(node.expression)}else if(t.isVariableDeclaration(node)){each(node.declarations,function(declar){scope.push({kind:node.kind,key:declar.id.name,id:declar.id});exprs.push(t.assignmentExpression("=",declar.id,declar.init))})}});if(exprs.length===1){return exprs[0]}else{return t.sequenceExpression(exprs)}};t.shallowEqual=function(actual,expected){var keys=Object.keys(expected);for(var i=0;i<keys.length;i++){var key=keys[i];if(actual[key]!==expected[key]){return false}}return true};t.appendToMemberExpression=function(member,append,computed){member.object=t.memberExpression(member.object,member.property,member.computed);member.property=append;member.computed=!!computed;return member};t.prependToMemberExpression=function(member,append){member.object=t.memberExpression(append,member.object);return member};t.isReferenced=function(node,parent){if(t.isMemberExpression(parent)){if(parent.property===node&&parent.computed){return true}else if(parent.object===node){return true}else{return false}}if(t.isProperty(parent)&&parent.key===node){return parent.computed}if(t.isVariableDeclarator(parent)){return parent.id!==node}if(t.isFunction(parent)){for(var i=0;i<parent.params.length;i++){var param=parent.params[i];if(param===node)return false}return parent.id!==node}if(t.isClass(parent)){return parent.id!==node}if(t.isMethodDefinition(parent)){return parent.key===node&&parent.computed}if(t.isLabeledStatement(parent)){return false}if(t.isCatchClause(parent)){return parent.param!==node}if(t.isRestElement(parent)){return false}if(t.isAssignmentPattern(parent)){return parent.right===node}if(t.isPattern(parent)){return false}if(t.isImportSpecifier(parent)){return false}if(t.isImportBatchSpecifier(parent)){return false}if(t.isPrivateDeclaration(parent)){return false}return true};t.isReferencedIdentifier=function(node,parent,opts){return t.isIdentifier(node,opts)&&t.isReferenced(node,parent)};t.isValidIdentifier=function(name){return isString(name)&&esutils.keyword.isIdentifierName(name)&&!esutils.keyword.isReservedWordES6(name,true)};t.toIdentifier=function(name){if(t.isIdentifier(name))return name.name;name=name+"";name=name.replace(/[^a-zA-Z0-9$_]/g,"-");name=name.replace(/^[-0-9]+/,"");name=name.replace(/[-\s]+(.)?/g,function(match,c){return c?c.toUpperCase():""});if(!t.isValidIdentifier(name)){name="_"+name}return name||"_"};t.ensureBlock=function(node,key){if(!key)key="body";return node[key]=t.toBlock(node[key],node)};t.buildMatchMemberExpression=function(match,allowPartial){var parts=match.split(".");return function(member){if(!t.isMemberExpression(member))return false;var search=[member];var i=0;while(search.length){var node=search.shift();if(allowPartial&&i===parts.length){return true}if(t.isIdentifier(node)){if(parts[i]!==node.name)return false}else if(t.isLiteral(node)){if(parts[i]!==node.value)return false}else if(t.isMemberExpression(node)){if(node.computed&&!t.isLiteral(node.property)){return false}else{search.push(node.object);search.push(node.property);continue}}else{return false}if(++i>parts.length){return false}}return true}};t.toStatement=function(node,ignore){if(t.isStatement(node)){return node}var mustHaveId=false;var newType;if(t.isClass(node)){mustHaveId=true;newType="ClassDeclaration"}else if(t.isFunction(node)){mustHaveId=true;newType="FunctionDeclaration"}else if(t.isAssignmentExpression(node)){return t.expressionStatement(node)}if(mustHaveId&&!node.id){newType=false}if(!newType){if(ignore){return false}else{throw new Error("cannot turn "+node.type+" to a statement")}}node.type=newType;return node};t.toExpression=function(node){if(t.isExpressionStatement(node)){node=node.expression}if(t.isClass(node)){node.type="ClassExpression"}else if(t.isFunction(node)){node.type="FunctionExpression"}if(t.isExpression(node)){return node}else{throw new Error("cannot turn "+node.type+" to an expression")}};t.toBlock=function(node,parent){if(t.isBlockStatement(node)){return node}if(t.isEmptyStatement(node)){node=[]}if(!Array.isArray(node)){if(!t.isStatement(node)){if(t.isFunction(parent)){node=t.returnStatement(node)}else{node=t.expressionStatement(node)}}node=[node]}return t.blockStatement(node)};t.getBindingIdentifiers=function(node){var search=[].concat(node);var ids=object();while(search.length){var id=search.shift();if(!id)continue;var keys=t.getBindingIdentifiers.keys[id.type];if(t.isIdentifier(id)){ids[id.name]=id}else if(t.isImportSpecifier(id)){search.push(id.name||id.id)}else if(t.isExportDeclaration(id)){if(t.isDeclaration(node.declaration)){search.push(node.declaration)}}else if(keys){for(var i=0;i<keys.length;i++){var key=keys[i];search=search.concat(id[key]||[])}}}return ids};t.getBindingIdentifiers.keys={UnaryExpression:["argument"],AssignmentExpression:["left"],ImportBatchSpecifier:["name"],VariableDeclarator:["id"],FunctionDeclaration:["id"],ClassDeclaration:["id"],SpreadElement:["argument"],RestElement:["argument"],UpdateExpression:["argument"],SpreadProperty:["argument"],Property:["value"],ComprehensionBlock:["left"],AssignmentPattern:["left"],PrivateDeclaration:["declarations"],ComprehensionExpression:["blocks"],ImportDeclaration:["specifiers"],VariableDeclaration:["declarations"],ArrayPattern:["elements"],ObjectPattern:["properties"]};t.isLet=function(node){return t.isVariableDeclaration(node)&&(node.kind!=="var"||node._let)};t.isBlockScoped=function(node){return t.isFunctionDeclaration(node)||t.isClassDeclaration(node)||t.isLet(node)};t.isVar=function(node){return t.isVariableDeclaration(node,{kind:"var"})&&!node._let};t.COMMENT_KEYS=["leadingComments","trailingComments"];t.removeComments=function(child){each(t.COMMENT_KEYS,function(key){delete child[key]});return child};t.inheritsComments=function(child,parent){each(t.COMMENT_KEYS,function(key){child[key]=uniq(compact([].concat(child[key],parent[key])))});return child};t.inherits=function(child,parent){child._declarations=parent._declarations;child._scopeInfo=parent._scopeInfo;child.range=parent.range;child.start=parent.start;child.loc=parent.loc;child.end=parent.end;t.inheritsComments(child,parent);return child};t.getLastStatements=function(node){var nodes=[];var add=function add(node){nodes=nodes.concat(t.getLastStatements(node))};if(t.isIfStatement(node)){add(node.consequent);add(node.alternate)}else if(t.isFor(node)||t.isWhile(node)){add(node.body)}else if(t.isProgram(node)||t.isBlockStatement(node)){add(node.body[node.body.length-1])}else if(node){nodes.push(node)}return nodes};t.getSpecifierName=function(specifier){return specifier.name||specifier.id};t.getSpecifierId=function(specifier){if(specifier["default"]){return t.identifier("default")}else{return specifier.id}};t.isSpecifierDefault=function(specifier){return specifier["default"]||t.isIdentifier(specifier.id)&&specifier.id.name==="default"};t.isScope=function(node,parent){if(t.isBlockStatement(node)){if(t.isLoop(parent.block,{body:node})){return false}if(t.isFunction(parent.block,{body:node})){return false}}return t.isScopable(node)};toFastProperties(t);toFastProperties(t.VISITOR_KEYS)},{"../helpers/object":24,"../helpers/to-fast-properties":26,"./alias-keys":120,"./builder-keys":121,"./visitor-keys":123,esutils:185,"lodash/array/compact":195,"lodash/array/uniq":199,"lodash/collection/each":201,"lodash/lang/isString":295}],123:[function(require,module,exports){module.exports={ArrayExpression:["elements"],ArrayPattern:["elements"],ArrowFunctionExpression:["params","defaults","rest","body"],AssignmentExpression:["left","right"],AssignmentPattern:["left","right"],AwaitExpression:["argument"],BinaryExpression:["left","right"],BindFunctionExpression:["callee","arguments"],BindMemberExpression:["object","property","arguments"],BlockStatement:["body"],BreakStatement:["label"],CallExpression:["callee","arguments"],CatchClause:["param","body"],ClassBody:["body"],ClassDeclaration:["id","body","superClass"],ClassExpression:["id","body","superClass"],ComprehensionBlock:["left","right","body"],ComprehensionExpression:["filter","blocks","body"],ConditionalExpression:["test","consequent","alternate"],ContinueStatement:["label"],DebuggerStatement:[],DoWhileStatement:["body","test"],EmptyStatement:[],ExportBatchSpecifier:[],ExportDeclaration:["declaration","specifiers","source"],ExportSpecifier:["id","name"],ExpressionStatement:["expression"],File:["program"],ForInStatement:["left","right","body"],ForOfStatement:["left","right","body"],ForStatement:["init","test","update","body"],FunctionDeclaration:["id","params","defaults","rest","body"],FunctionExpression:["id","params","defaults","rest","body"],Identifier:[],IfStatement:["test","consequent","alternate"],ImportBatchSpecifier:["id"],ImportDeclaration:["specifiers","source"],ImportSpecifier:["id","name"],LabeledStatement:["label","body"],Literal:[],LogicalExpression:["left","right"],MemberExpression:["object","property"],MethodDefinition:["key","value"],NewExpression:["callee","arguments"],ObjectExpression:["properties"],ObjectPattern:["properties"],PrivateDeclaration:["declarations"],Program:["body"],Property:["key","value"],RestElement:["argument"],ReturnStatement:["argument"],SequenceExpression:["expressions"],SpreadElement:["argument"],SpreadProperty:["argument"],SwitchCase:["test","consequent"],SwitchStatement:["discriminant","cases"],TaggedTemplateExpression:["tag","quasi"],TemplateElement:[],TemplateLiteral:["quasis","expressions"],ThisExpression:[],ThrowStatement:["argument"],TryStatement:["block","handlers","handler","guardedHandlers","finalizer"],UnaryExpression:["argument"],UpdateExpression:["argument"],VariableDeclaration:["declarations"],VariableDeclarator:["id","init"],VirtualPropertyExpression:["object","property"],WhileStatement:["test","body"],WithStatement:["object","body"],YieldExpression:["argument"],AnyTypeAnnotation:[],ArrayTypeAnnotation:[],BooleanTypeAnnotation:[],ClassProperty:["key","value"],DeclareClass:[],DeclareFunction:[],DeclareModule:[],DeclareVariable:[],FunctionTypeAnnotation:[],FunctionTypeParam:[],GenericTypeAnnotation:[],InterfaceExtends:[],InterfaceDeclaration:[],IntersectionTypeAnnotation:[],NullableTypeAnnotation:[],NumberTypeAnnotation:[],StringLiteralTypeAnnotation:[],StringTypeAnnotation:[],TupleTypeAnnotation:[],TypeofTypeAnnotation:[],TypeAlias:[],TypeAnnotation:[],TypeCastExpression:["expression"],TypeParameterDeclaration:[],TypeParameterInstantiation:[],ObjectTypeAnnotation:[],ObjectTypeCallProperty:[],ObjectTypeIndexer:[],ObjectTypeProperty:[],QualifiedTypeIdentifier:[],UnionTypeAnnotation:[],VoidTypeAnnotation:[],JSXAttribute:["name","value"],JSXClosingElement:["name"],JSXElement:["openingElement","closingElement","children"],JSXEmptyExpression:[],JSXExpressionContainer:["expression"],JSXIdentifier:[],JSXMemberExpression:["object","property"],JSXNamespacedName:["namespace","name"],JSXOpeningElement:["name","attributes"],JSXSpreadAttribute:["argument"]}},{}],124:[function(require,module,exports){(function(__dirname){"use strict";var _interopRequire=function(obj){return obj&&obj.__esModule?obj["default"]:obj};exports.canCompile=canCompile;exports.resolve=resolve;exports.list=list;exports.regexify=regexify;exports.arrayify=arrayify;exports.booleanify=booleanify;exports.template=template;exports.parseTemplate=parseTemplate;require("./patch");var buildDebug=_interopRequire(require("debug/node"));var cloneDeep=_interopRequire(require("lodash/lang/cloneDeep"));var isBoolean=_interopRequire(require("lodash/lang/isBoolean"));var contains=_interopRequire(require("lodash/collection/contains"));var traverse=_interopRequire(require("./traversal"));var isString=_interopRequire(require("lodash/lang/isString"));var isRegExp=_interopRequire(require("lodash/lang/isRegExp"));var isEmpty=_interopRequire(require("lodash/lang/isEmpty"));var parse=_interopRequire(require("./helpers/parse"));var path=_interopRequire(require("path"));var each=_interopRequire(require("lodash/collection/each"));var has=_interopRequire(require("lodash/object/has"));var fs=_interopRequire(require("fs"));var t=_interopRequire(require("./types"));exports.inherits=require("util").inherits;var debug=exports.debug=buildDebug("babel");function canCompile(filename,altExts){var exts=altExts||exports.canCompile.EXTENSIONS;var ext=path.extname(filename);return contains(exts,ext)}canCompile.EXTENSIONS=[".js",".jsx",".es6",".es"];function resolve(loc){try{return require.resolve(loc)}catch(err){return null}}function list(val){return val?val.split(","):[]}function regexify(val){if(!val)return new RegExp(/.^/);if(Array.isArray(val))val=val.join("|");if(isString(val))return new RegExp(val);if(isRegExp(val))return val;throw new TypeError("illegal type for regexify")}function arrayify(val){if(!val)return[];if(isBoolean(val))return[val];if(isString(val))return exports.list(val);if(Array.isArray(val))return val; throw new TypeError("illegal type for arrayify")}function booleanify(val){if(val==="true")return true;if(val==="false")return false;return val}var templateVisitor={enter:function enter(node,parent,scope,nodes){if(t.isExpressionStatement(node)){node=node.expression}if(t.isIdentifier(node)&&has(nodes,node.name)){this.skip();return nodes[node.name]}}};function template(name,nodes,keepExpression){var ast=exports.templates[name];if(!ast)throw new ReferenceError("unknown template "+name);if(nodes===true){keepExpression=true;nodes=null}ast=cloneDeep(ast);if(!isEmpty(nodes)){traverse(ast,templateVisitor,null,nodes)}if(ast.body.length>1)return ast.body;var node=ast.body[0];if(!keepExpression&&t.isExpressionStatement(node)){return node.expression}else{return node}}function parseTemplate(loc,code){var ast=parse({filename:loc},code).program;return traverse.removeProperties(ast)}function loadTemplates(){var templates={};var templatesLoc=path.join(__dirname,"transformation/templates");if(!fs.existsSync(templatesLoc)){throw new Error("no templates directory - this is most likely the "+"result of a broken `npm publish`. Please report to "+"https://github.com/babel/babel/issues")}each(fs.readdirSync(templatesLoc),function(name){if(name[0]===".")return;var key=path.basename(name,path.extname(name));var loc=path.join(templatesLoc,name);var code=fs.readFileSync(loc,"utf8");templates[key]=parseTemplate(loc,code)});return templates}try{exports.templates=require("../../templates.json")}catch(err){if(err.code!=="MODULE_NOT_FOUND")throw err;exports.templates=loadTemplates()}exports.__esModule=true}).call(this,"/lib/babel")},{"../../templates.json":343,"./helpers/parse":25,"./patch":28,"./traversal":117,"./types":122,"debug/node":178,fs:140,"lodash/collection/contains":200,"lodash/collection/each":201,"lodash/lang/cloneDeep":285,"lodash/lang/isBoolean":288,"lodash/lang/isEmpty":289,"lodash/lang/isRegExp":294,"lodash/lang/isString":295,"lodash/object/has":300,path:150,util:167}],125:[function(require,module,exports){(function(root,mod){if(typeof exports=="object"&&typeof module=="object")return mod(exports);if(typeof define=="function"&&define.amd)return define(["exports"],mod);mod(root.acorn||(root.acorn={}))})(this,function(exports){"use strict";exports.version="0.11.1";var options,input,inputLen,sourceFile;exports.parse=function(inpt,opts){input=String(inpt);inputLen=input.length;setOptions(opts);initTokenState();var startPos=options.locations?[tokPos,curPosition()]:tokPos;initParserState();if(options.strictMode){strict=true}return parseTopLevel(options.program||startNodeAt(startPos))};var defaultOptions=exports.defaultOptions={strictMode:false,playground:false,ecmaVersion:5,strictSemicolons:false,allowTrailingCommas:true,forbidReserved:false,allowReturnOutsideFunction:false,allowImportExportEverywhere:false,allowHashBang:false,locations:false,onToken:null,onComment:null,ranges:false,program:null,sourceFile:null,directSourceFile:null,preserveParens:false};exports.parseExpressionAt=function(inpt,pos,opts){input=String(inpt);inputLen=input.length;setOptions(opts);initTokenState(pos);initParserState();return parseExpression()};var isArray=function(obj){return Object.prototype.toString.call(obj)==="[object Array]"};function setOptions(opts){options={};for(var opt in defaultOptions)options[opt]=opts&&has(opts,opt)?opts[opt]:defaultOptions[opt];sourceFile=options.sourceFile||null;if(isArray(options.onToken)){var tokens=options.onToken;options.onToken=function(token){tokens.push(token)}}if(isArray(options.onComment)){var comments=options.onComment;options.onComment=function(block,text,start,end,startLoc,endLoc){var comment={type:block?"Block":"Line",value:text,start:start,end:end};if(options.locations){comment.loc=new SourceLocation;comment.loc.start=startLoc;comment.loc.end=endLoc}if(options.ranges)comment.range=[start,end];comments.push(comment)}}if(options.ecmaVersion>=6){isKeyword=isEcma6Keyword}else{isKeyword=isEcma5AndLessKeyword}}var getLineInfo=exports.getLineInfo=function(input,offset){for(var line=1,cur=0;;){lineBreak.lastIndex=cur;var match=lineBreak.exec(input);if(match&&match.index<offset){++line;cur=match.index+match[0].length}else break}return{line:line,column:offset-cur}};function Token(){this.type=tokType;this.value=tokVal;this.start=tokStart;this.end=tokEnd;if(options.locations){this.loc=new SourceLocation;this.loc.end=tokEndLoc}if(options.ranges)this.range=[tokStart,tokEnd]}exports.Token=Token;exports.tokenize=function(inpt,opts){input=String(inpt);inputLen=input.length;setOptions(opts);initTokenState();skipSpace();function getToken(){lastEnd=tokEnd;readToken();return new Token}getToken.jumpTo=function(pos,exprAllowed){tokPos=pos;if(options.locations){tokCurLine=1;tokLineStart=lineBreak.lastIndex=0;var match;while((match=lineBreak.exec(input))&&match.index<pos){++tokCurLine;tokLineStart=match.index+match[0].length}}tokExprAllowed=!!exprAllowed;skipSpace()};getToken.current=function(){return new Token};if(typeof Symbol!=="undefined"){getToken[Symbol.iterator]=function(){return{next:function(){var token=getToken();return{done:token.type===_eof,value:token}}}}}getToken.options=options;return getToken};var tokPos;var tokStart,tokEnd;var tokStartLoc,tokEndLoc;var tokType,tokVal;var tokContext,tokExprAllowed;var tokCurLine,tokLineStart;var lastStart,lastEnd,lastEndLoc;var inFunction,inGenerator,inAsync,labels,strict,inXJSChild,inXJSTag,inType;function initParserState(){lastStart=lastEnd=tokPos;if(options.locations)lastEndLoc=curPosition();inFunction=inGenerator=inAsync=false;labels=[];skipSpace();readToken()}function raise(pos,message){var loc=getLineInfo(input,pos);message+=" ("+loc.line+":"+loc.column+")";var err=new SyntaxError(message);err.pos=pos;err.loc=loc;err.raisedAt=tokPos;throw err}var empty=[];var _num={type:"num"},_regexp={type:"regexp"},_string={type:"string"};var _name={type:"name"},_eof={type:"eof"};var _jsxName={type:"jsxName"};var _xjsName={type:"xjsName"},_xjsText={type:"xjsText"};var _break={keyword:"break"},_case={keyword:"case",beforeExpr:true},_catch={keyword:"catch"};var _continue={keyword:"continue"},_debugger={keyword:"debugger"},_default={keyword:"default"};var _do={keyword:"do",isLoop:true},_else={keyword:"else",beforeExpr:true};var _finally={keyword:"finally"},_for={keyword:"for",isLoop:true},_function={keyword:"function"};var _if={keyword:"if"},_return={keyword:"return",beforeExpr:true},_switch={keyword:"switch"};var _throw={keyword:"throw",beforeExpr:true},_try={keyword:"try"},_var={keyword:"var"};var _let={keyword:"let"},_const={keyword:"const"};var _while={keyword:"while",isLoop:true},_with={keyword:"with"},_new={keyword:"new",beforeExpr:true};var _this={keyword:"this"};var _class={keyword:"class"},_extends={keyword:"extends",beforeExpr:true};var _export={keyword:"export"},_import={keyword:"import"};var _yield={keyword:"yield",beforeExpr:true};var _null={keyword:"null",atomValue:null},_true={keyword:"true",atomValue:true};var _false={keyword:"false",atomValue:false};var _in={keyword:"in",binop:7,beforeExpr:true};var keywordTypes={"break":_break,"case":_case,"catch":_catch,"continue":_continue,"debugger":_debugger,"default":_default,"do":_do,"else":_else,"finally":_finally,"for":_for,"function":_function,"if":_if,"return":_return,"switch":_switch,"throw":_throw,"try":_try,"var":_var,let:_let,"const":_const,"while":_while,"with":_with,"null":_null,"true":_true,"false":_false,"new":_new,"in":_in,"instanceof":{keyword:"instanceof",binop:7,beforeExpr:true},"this":_this,"typeof":{keyword:"typeof",prefix:true,beforeExpr:true},"void":{keyword:"void",prefix:true,beforeExpr:true},"delete":{keyword:"delete",prefix:true,beforeExpr:true},"class":_class,"extends":_extends,"export":_export,"import":_import,"yield":_yield};var _bracketL={type:"[",beforeExpr:true},_bracketR={type:"]"},_braceL={type:"{",beforeExpr:true};var _braceR={type:"}"},_parenL={type:"(",beforeExpr:true},_parenR={type:")"};var _comma={type:",",beforeExpr:true},_semi={type:";",beforeExpr:true};var _colon={type:":",beforeExpr:true},_dot={type:"."},_question={type:"?",beforeExpr:true};var _arrow={type:"=>",beforeExpr:true},_template={type:"template"};var _ellipsis={type:"...",beforeExpr:true};var _backQuote={type:"`"},_dollarBraceL={type:"${",beforeExpr:true};var _jsxText={type:"jsxText"};var _paamayimNekudotayim={type:"::",beforeExpr:true};var _hash={type:"#"};var _slash={binop:10,beforeExpr:true},_eq={isAssign:true,beforeExpr:true};var _assign={isAssign:true,beforeExpr:true};var _incDec={postfix:true,prefix:true,isUpdate:true},_prefix={prefix:true,beforeExpr:true};var _logicalOR={binop:1,beforeExpr:true};var _logicalAND={binop:2,beforeExpr:true};var _bitwiseOR={binop:3,beforeExpr:true};var _bitwiseXOR={binop:4,beforeExpr:true};var _bitwiseAND={binop:5,beforeExpr:true};var _equality={binop:6,beforeExpr:true};var _relational={binop:7,beforeExpr:true};var _bitShift={binop:8,beforeExpr:true};var _plusMin={binop:9,prefix:true,beforeExpr:true};var _modulo={binop:10,beforeExpr:true};var _star={binop:10,beforeExpr:true};var _exponent={binop:11,beforeExpr:true,rightAssociative:true};var _jsxTagStart={type:"jsxTagStart"},_jsxTagEnd={type:"jsxTagEnd"};exports.tokTypes={bracketL:_bracketL,bracketR:_bracketR,braceL:_braceL,braceR:_braceR,parenL:_parenL,parenR:_parenR,comma:_comma,semi:_semi,colon:_colon,dot:_dot,ellipsis:_ellipsis,question:_question,slash:_slash,eq:_eq,name:_name,eof:_eof,num:_num,regexp:_regexp,string:_string,paamayimNekudotayim:_paamayimNekudotayim,exponent:_exponent,hash:_hash,arrow:_arrow,template:_template,star:_star,assign:_assign,backQuote:_backQuote,dollarBraceL:_dollarBraceL,jsxName:_jsxName,jsxText:_jsxText,jsxTagStart:_jsxTagStart,jsxTagEnd:_jsxTagEnd};for(var kw in keywordTypes)exports.tokTypes["_"+kw]=keywordTypes[kw];var isReservedWord3=function anonymous(str){switch(str.length){case 6:switch(str){case"double":case"export":case"import":case"native":case"public":case"static":case"throws":return true}return false;case 4:switch(str){case"byte":case"char":case"enum":case"goto":case"long":return true}return false;case 5:switch(str){case"class":case"final":case"float":case"short":case"super":return true}return false;case 7:switch(str){case"boolean":case"extends":case"package":case"private":return true}return false;case 9:switch(str){case"interface":case"protected":case"transient":return true}return false;case 8:switch(str){case"abstract":case"volatile":return true}return false;case 10:return str==="implements";case 3:return str==="int";case 12:return str==="synchronized"}};var isReservedWord5=function anonymous(str){switch(str.length){case 5:switch(str){case"class":case"super":case"const":return true}return false;case 6:switch(str){case"export":case"import":return true}return false;case 4:return str==="enum";case 7:return str==="extends"}};var isStrictReservedWord=function anonymous(str){switch(str.length){case 9:switch(str){case"interface":case"protected":return true}return false;case 7:switch(str){case"package":case"private":return true}return false;case 6:switch(str){case"public":case"static":return true}return false;case 10:return str==="implements";case 3:return str==="let";case 5:return str==="yield"}};var isStrictBadIdWord=function anonymous(str){switch(str){case"eval":case"arguments":return true}return false};var ecma5AndLessKeywords="break case catch continue debugger default do else finally for function if return switch throw try var while with null true false instanceof typeof void delete new in this";var isEcma5AndLessKeyword=function anonymous(str){switch(str.length){case 4:switch(str){case"case":case"else":case"with":case"null":case"true":case"void":case"this":return true}return false;case 5:switch(str){case"break":case"catch":case"throw":case"while":case"false":return true}return false;case 3:switch(str){case"for":case"try":case"var":case"new":return true}return false;case 6:switch(str){case"return":case"switch":case"typeof":case"delete":return true}return false;case 8:switch(str){case"continue":case"debugger":case"function":return true}return false;case 2:switch(str){case"do":case"if":case"in":return true}return false;case 7:switch(str){case"default":case"finally":return true}return false;case 10:return str==="instanceof"}};var ecma6AndLessKeywords=ecma5AndLessKeywords+" let const class extends export import yield";var isEcma6Keyword=function anonymous(str){switch(str.length){case 5:switch(str){case"break":case"catch":case"throw":case"while":case"false":case"const":case"class":case"yield":return true}return false;case 4:switch(str){case"case":case"else":case"with":case"null":case"true":case"void":case"this":return true}return false;case 6:switch(str){case"return":case"switch":case"typeof":case"delete":case"export":case"import":return true}return false;case 3:switch(str){case"for":case"try":case"var":case"new":case"let":return true}return false;case 8:switch(str){case"continue":case"debugger":case"function":return true}return false;case 7:switch(str){case"default":case"finally":case"extends":return true}return false;case 2:switch(str){case"do":case"if":case"in":return true}return false;case 10:return str==="instanceof"}};var isKeyword=isEcma5AndLessKeyword;var nonASCIIwhitespace=/[\u1680\u180e\u2000-\u200a\u202f\u205f\u3000\ufeff]/;var nonASCIIidentifierStartChars="ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԯԱ-Ֆՙա-ևא-תװ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࢠ-ࢲऄ-हऽॐक़-ॡॱ-ঀঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-హఽౘౙౠౡಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽೞೠೡೱೲഅ-ഌഎ-ഐഒ-ഺഽൎൠൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄງຈຊຍດ-ທນ-ຟມ-ຣລວສຫອ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏼᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛸᜀ-ᜌᜎ-ᜑᜠ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡷᢀ-ᢨᢪᢰ-ᣵᤀ-ᤞᥐ-ᥭᥰ-ᥴᦀ-ᦫᧁ-ᧇᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭋᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᳩ-ᳬᳮ-ᳱᳵᳶᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕℙ-ℝℤΩℨK-ℭℯ-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-Ⱞⰰ-ⱞⱠ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞⸯ々-〇〡-〩〱-〵〸-〼ぁ-ゖゝ-ゟァ-ヺー-ヿㄅ-ㄭㄱ-ㆎㆠ-ㆺㇰ-ㇿ㐀-䶵一-鿌ꀀ-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚝꚠ-ꛯꜗ-ꜟꜢ-ꞈꞋ-ꞎꞐ-ꞭꞰꞱꟷ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꧠ-ꧤꧦ-ꧯꧺ-ꧾꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꩾ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚꭜ-ꭟꭤꭥꯀ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ";var nonASCIIidentifierChars="̀-ͯ҃-֑҇-ׇֽֿׁׂׅׄؐ-ًؚ-٩ٰۖ-ۜ۟-۪ۤۧۨ-ۭ۰-۹ܑܰ-݊ަ-ް߀-߉߫-߳ࠖ-࠙ࠛ-ࠣࠥ-ࠧࠩ-࡙࠭-࡛ࣤ-ःऺ-़ा-ॏ॑-ॗॢॣ०-९ঁ-ঃ়া-ৄেৈো-্ৗৢৣ০-৯ਁ-ਃ਼ਾ-ੂੇੈੋ-੍ੑ੦-ੱੵઁ-ઃ઼ા-ૅે-ૉો-્ૢૣ૦-૯ଁ-ଃ଼ା-ୄେୈୋ-୍ୖୗୢୣ୦-୯ஂா-ூெ-ைொ-்ௗ௦-௯ఀ-ఃా-ౄె-ైొ-్ౕౖౢౣ౦-౯ಁ-ಃ಼ಾ-ೄೆ-ೈೊ-್ೕೖೢೣ೦-೯ഁ-ഃാ-ൄെ-ൈൊ-്ൗൢൣ൦-൯ංඃ්ා-ුූෘ-ෟ෦-෯ෲෳัิ-ฺ็-๎๐-๙ັິ-ູົຼ່-ໍ໐-໙༘༙༠-༩༹༵༷༾༿ཱ-྄྆྇ྍ-ྗྙ-ྼ࿆ါ-ှ၀-၉ၖ-ၙၞ-ၠၢ-ၤၧ-ၭၱ-ၴႂ-ႍႏ-ႝ፝-፟ᜒ-᜔ᜲ-᜴ᝒᝓᝲᝳ឴-៓៝០-៩᠋-᠍᠐-᠙ᢩᤠ-ᤫᤰ-᤻᥆-᥏ᦰ-ᧀᧈᧉ᧐-᧙ᨗ-ᨛᩕ-ᩞ᩠-᩿᩼-᪉᪐-᪙᪰-᪽ᬀ-ᬄ᬴-᭄᭐-᭙᭫-᭳ᮀ-ᮂᮡ-ᮭ᮰-᮹᯦-᯳ᰤ-᰷᱀-᱉᱐-᱙᳐-᳔᳒-᳨᳭ᳲ-᳴᳸᳹᷀-᷵᷼-᷿‌‍‿⁀⁔⃐-⃥⃜⃡-⃰⳯-⵿⳱ⷠ-〪ⷿ-゙゚〯꘠-꘩꙯ꙴ-꙽ꚟ꛰꛱ꠂ꠆ꠋꠣ-ꠧꢀꢁꢴ-꣄꣐-꣙꣠-꣱꤀-꤉ꤦ-꤭ꥇ-꥓ꦀ-ꦃ꦳-꧀꧐-꧙ꧥ꧰-꧹ꨩ-ꨶꩃꩌꩍ꩐-꩙ꩻ-ꩽꪰꪲ-ꪴꪷꪸꪾ꪿꫁ꫫ-ꫯꫵ꫶ꯣ-ꯪ꯬꯭꯰-꯹ﬞ︀-️︠-︭︳︴﹍-﹏0-9_";var nonASCIIidentifierStart=new RegExp("["+nonASCIIidentifierStartChars+"]");var nonASCIIidentifier=new RegExp("["+nonASCIIidentifierStartChars+nonASCIIidentifierChars+"]");var decimalNumber=/^\d+$/;var hexNumber=/^[\da-fA-F]+$/;var newline=/[\n\r\u2028\u2029]/;function isNewLine(code){return code===10||code===13||code===8232||code==8233}var lineBreak=/\r\n|[\n\r\u2028\u2029]/g;var isIdentifierStart=exports.isIdentifierStart=function(code){if(code<65)return code===36;if(code<91)return true;if(code<97)return code===95;if(code<123)return true;return code>=170&&nonASCIIidentifierStart.test(String.fromCharCode(code))};var isIdentifierChar=exports.isIdentifierChar=function(code){if(code<48)return code===36;if(code<58)return true;if(code<65)return false;if(code<91)return true;if(code<97)return code===95;if(code<123)return true;return code>=170&&nonASCIIidentifier.test(String.fromCharCode(code))};function Position(line,col){this.line=line;this.column=col}Position.prototype.offset=function(n){return new Position(this.line,this.column+n)};function curPosition(){return new Position(tokCurLine,tokPos-tokLineStart)}function initTokenState(pos){if(pos){tokPos=pos;tokLineStart=Math.max(0,input.lastIndexOf("\n",pos));tokCurLine=input.slice(0,tokLineStart).split(newline).length}else{tokCurLine=1;tokPos=tokLineStart=0}tokType=_eof;tokContext=[b_stat];tokExprAllowed=true;inType=strict=false;if(tokPos===0&&options.allowHashBang&&input.slice(0,2)==="#!"){skipLineComment(2)}}var b_stat={token:"{",isExpr:false},b_expr={token:"{",isExpr:true},b_tmpl={token:"${",isExpr:true};var p_stat={token:"(",isExpr:false},p_expr={token:"(",isExpr:true};var q_tmpl={token:"`",isExpr:true},f_expr={token:"function",isExpr:true};var j_oTag={token:"<tag",isExpr:false},j_cTag={token:"</tag",isExpr:false},j_expr={token:"<tag>...</tag>",isExpr:true};function curTokContext(){return tokContext[tokContext.length-1]}function braceIsBlock(prevType){var parent;if(prevType===_colon&&(parent=curTokContext()).token=="{")return!parent.isExpr;if(prevType===_return)return newline.test(input.slice(lastEnd,tokStart));if(prevType===_else||prevType===_semi||prevType===_eof)return true;if(prevType==_braceL)return curTokContext()===b_stat;return!tokExprAllowed}function finishToken(type,val){tokEnd=tokPos;if(options.locations)tokEndLoc=curPosition();var prevType=tokType,preserveSpace=false;tokType=type;tokVal=val;if(type===_parenR||type===_braceR){var out=tokContext.pop();if(out===b_tmpl){preserveSpace=tokExprAllowed=true}else if(out===b_stat&&curTokContext()===f_expr){tokContext.pop();tokExprAllowed=false}else{tokExprAllowed=!(out&&out.isExpr)}}else if(type===_braceL){switch(curTokContext()){case j_oTag:tokContext.push(b_expr);break;case j_expr:tokContext.push(b_tmpl);break;default:tokContext.push(braceIsBlock(prevType)?b_stat:b_expr)}tokExprAllowed=true}else if(type===_dollarBraceL){tokContext.push(b_tmpl);tokExprAllowed=true}else if(type==_parenL){var statementParens=prevType===_if||prevType===_for||prevType===_with||prevType===_while;tokContext.push(statementParens?p_stat:p_expr);tokExprAllowed=true}else if(type==_incDec){}else if(type.keyword&&prevType==_dot){tokExprAllowed=false}else if(type==_function){if(curTokContext()!==b_stat){tokContext.push(f_expr)}tokExprAllowed=false}else if(type===_backQuote){if(curTokContext()===q_tmpl){tokContext.pop()}else{tokContext.push(q_tmpl);preserveSpace=true}tokExprAllowed=false}else if(type===_jsxTagStart){tokContext.push(j_expr);tokContext.push(j_oTag);tokExprAllowed=false}else if(type===_jsxTagEnd){var out=tokContext.pop();if(out===j_oTag&&prevType===_slash||out===j_cTag){tokContext.pop();preserveSpace=tokExprAllowed=curTokContext()===j_expr}else{preserveSpace=tokExprAllowed=true}}else if(type===_jsxText){preserveSpace=tokExprAllowed=true}else if(type===_slash&&prevType===_jsxTagStart){tokContext.length-=2;tokContext.push(j_cTag);tokExprAllowed=false}else{tokExprAllowed=type.beforeExpr}if(!preserveSpace)skipSpace()}function skipBlockComment(){var startLoc=options.onComment&&options.locations&&curPosition();var start=tokPos,end=input.indexOf("*/",tokPos+=2);if(end===-1)raise(tokPos-2,"Unterminated comment");tokPos=end+2;if(options.locations){lineBreak.lastIndex=start;var match;while((match=lineBreak.exec(input))&&match.index<tokPos){++tokCurLine;tokLineStart=match.index+match[0].length}}if(options.onComment)options.onComment(true,input.slice(start+2,end),start,tokPos,startLoc,options.locations&&curPosition())}function skipLineComment(startSkip){var start=tokPos;var startLoc=options.onComment&&options.locations&&curPosition();var ch=input.charCodeAt(tokPos+=startSkip);while(tokPos<inputLen&&ch!==10&&ch!==13&&ch!==8232&&ch!==8233){++tokPos;ch=input.charCodeAt(tokPos)}if(options.onComment)options.onComment(false,input.slice(start+startSkip,tokPos),start,tokPos,startLoc,options.locations&&curPosition())}function skipSpace(){while(tokPos<inputLen){var ch=input.charCodeAt(tokPos);if(ch===32){++tokPos}else if(ch===13){++tokPos;var next=input.charCodeAt(tokPos);if(next===10){++tokPos}if(options.locations){++tokCurLine;tokLineStart=tokPos}}else if(ch===10||ch===8232||ch===8233){++tokPos;if(options.locations){++tokCurLine;tokLineStart=tokPos}}else if(ch>8&&ch<14){++tokPos}else if(ch===47){var next=input.charCodeAt(tokPos+1);if(next===42){skipBlockComment()}else if(next===47){skipLineComment(2)}else break}else if(ch===160){++tokPos}else if(ch>=5760&&nonASCIIwhitespace.test(String.fromCharCode(ch))){++tokPos}else{break}}}function readToken_dot(){var next=input.charCodeAt(tokPos+1);if(next>=48&&next<=57)return readNumber(true);var next2=input.charCodeAt(tokPos+2);if(options.ecmaVersion>=6&&next===46&&next2===46){tokPos+=3;return finishToken(_ellipsis)}else{++tokPos;return finishToken(_dot)}}function readToken_slash(){var next=input.charCodeAt(tokPos+1);if(tokExprAllowed){++tokPos;return readRegexp()}if(next===61)return finishOp(_assign,2);return finishOp(_slash,1)}function readToken_modulo(){var next=input.charCodeAt(tokPos+1);if(next===61)return finishOp(_assign,2);return finishOp(_modulo,1)}function readToken_mult(){var type=_star;var width=1;var next=input.charCodeAt(tokPos+1);if(options.ecmaVersion>=7&&next===42){width++;next=input.charCodeAt(tokPos+2);type=_exponent}if(next===61){width++;type=_assign}return finishOp(type,width)}function readToken_pipe_amp(code){var next=input.charCodeAt(tokPos+1);if(next===code){if(options.playground&&input.charCodeAt(tokPos+2)===61)return finishOp(_assign,3);return finishOp(code===124?_logicalOR:_logicalAND,2)}if(next===61)return finishOp(_assign,2);return finishOp(code===124?_bitwiseOR:_bitwiseAND,1)}function readToken_caret(){var next=input.charCodeAt(tokPos+1);if(next===61)return finishOp(_assign,2);return finishOp(_bitwiseXOR,1)}function readToken_plus_min(code){var next=input.charCodeAt(tokPos+1);if(next===code){if(next==45&&input.charCodeAt(tokPos+2)==62&&newline.test(input.slice(lastEnd,tokPos))){skipLineComment(3);skipSpace();return readToken()}return finishOp(_incDec,2)}if(next===61)return finishOp(_assign,2);return finishOp(_plusMin,1)}function readToken_lt_gt(code){var next=input.charCodeAt(tokPos+1);var size=1;if(!inType&&next===code){size=code===62&&input.charCodeAt(tokPos+2)===62?3:2;if(input.charCodeAt(tokPos+size)===61)return finishOp(_assign,size+1);return finishOp(_bitShift,size)}if(next==33&&code==60&&input.charCodeAt(tokPos+2)==45&&input.charCodeAt(tokPos+3)==45){skipLineComment(4);skipSpace();return readToken()}if(!inType){if(tokExprAllowed&&code===60){++tokPos;return finishToken(_jsxTagStart)}if(code===62){var context=curTokContext();if(context===j_oTag||context===j_cTag){++tokPos;return finishToken(_jsxTagEnd)}}}if(next===61)size=input.charCodeAt(tokPos+2)===61?3:2;return finishOp(_relational,size)}function readToken_eq_excl(code){var next=input.charCodeAt(tokPos+1);if(next===61)return finishOp(_equality,input.charCodeAt(tokPos+2)===61?3:2);if(code===61&&next===62&&options.ecmaVersion>=6){tokPos+=2;return finishToken(_arrow)}return finishOp(code===61?_eq:_prefix,1)}function getTemplateToken(code){if(tokType===_string){if(code===96){++tokPos;return finishToken(_bquote)}else if(code===36&&input.charCodeAt(tokPos+1)===123){tokPos+=2;return finishToken(_dollarBraceL)}}return readTmplString()}function getTokenFromCode(code){switch(code){case 46:return readToken_dot();case 40:++tokPos;return finishToken(_parenL);case 41:++tokPos;return finishToken(_parenR);case 59:++tokPos;return finishToken(_semi);case 44:++tokPos;return finishToken(_comma);case 91:++tokPos;return finishToken(_bracketL);case 93:++tokPos;return finishToken(_bracketR);case 123:++tokPos;return finishToken(_braceL);case 125:++tokPos;return finishToken(_braceR);case 63:++tokPos;return finishToken(_question);case 35:if(options.playground){++tokPos;return finishToken(_hash)}case 58:++tokPos;if(options.ecmaVersion>=7){var next=input.charCodeAt(tokPos);if(next===58){++tokPos;return finishToken(_paamayimNekudotayim)}}return finishToken(_colon);case 96:if(options.ecmaVersion>=6){++tokPos;return finishToken(_backQuote)}else{return false}case 48:var next=input.charCodeAt(tokPos+1);if(next===120||next===88)return readRadixNumber(16);if(options.ecmaVersion>=6){if(next===111||next===79)return readRadixNumber(8);if(next===98||next===66)return readRadixNumber(2)}case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return readNumber(false);case 34:case 39:return inXJSTag?readXJSStringLiteral():readString(code);case 47:return readToken_slash();case 37:return readToken_modulo();case 42:return readToken_mult();case 124:case 38:return readToken_pipe_amp(code);case 94:return readToken_caret();case 43:case 45:return readToken_plus_min(code);case 60:case 62:return readToken_lt_gt(code);case 61:case 33:return readToken_eq_excl(code);case 126:return finishOp(_prefix,1)}return false}function readToken(){tokStart=tokPos;if(options.locations)tokStartLoc=curPosition();if(tokPos>=inputLen)return finishToken(_eof);var context=curTokContext();if(context===q_tmpl){return readTmplToken()}if(context===j_expr){return readJSXToken()}var code=input.charCodeAt(tokPos);if(context===j_oTag||context===j_cTag){if(isIdentifierStart(code))return readJSXWord()}else if(context===j_expr){return readJSXToken()}else{if(isIdentifierStart(code)||code===92)return readWord()}var tok=getTokenFromCode(code);if(tok===false){var ch=String.fromCharCode(code);if(ch==="\\"||nonASCIIidentifierStart.test(ch))return readWord();raise(tokPos,"Unexpected character '"+ch+"'")}return tok}function finishOp(type,size,shouldSkipSpace){var str=input.slice(tokPos,tokPos+size);tokPos+=size;finishToken(type,str,shouldSkipSpace)}var regexpUnicodeSupport=false;try{new RegExp("￿","u");regexpUnicodeSupport=true}catch(e){}function readRegexp(){var content="",escaped,inClass,start=tokPos;for(;;){if(tokPos>=inputLen)raise(start,"Unterminated regular expression");var ch=nextChar();if(newline.test(ch))raise(start,"Unterminated regular expression");if(!escaped){if(ch==="[")inClass=true;else if(ch==="]"&&inClass)inClass=false;else if(ch==="/"&&!inClass)break;escaped=ch==="\\"}else escaped=false;++tokPos}var content=input.slice(start,tokPos);++tokPos;var mods=readWord1();var tmp=content;if(mods){var validFlags=/^[gmsiy]*$/;if(options.ecmaVersion>=6)validFlags=/^[gmsiyu]*$/;if(!validFlags.test(mods))raise(start,"Invalid regular expression flag");if(mods.indexOf("u")>=0&&!regexpUnicodeSupport){tmp=tmp.replace(/\\u\{([0-9a-fA-F]{5,6})\}/g,"x").replace(/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,"x")}}try{new RegExp(tmp)}catch(e){if(e instanceof SyntaxError)raise(start,"Error parsing regular expression: "+e.message);raise(e)}try{var value=new RegExp(content,mods)}catch(err){value=null}return finishToken(_regexp,{pattern:content,flags:mods,value:value})}function readInt(radix,len){var start=tokPos,total=0;for(var i=0,e=len==null?Infinity:len;i<e;++i){var code=input.charCodeAt(tokPos),val;if(code>=97)val=code-97+10;else if(code>=65)val=code-65+10;else if(code>=48&&code<=57)val=code-48;else val=Infinity;if(val>=radix)break;++tokPos;total=total*radix+val}if(tokPos===start||len!=null&&tokPos-start!==len)return null;return total}function readRadixNumber(radix){tokPos+=2;var val=readInt(radix);if(val==null)raise(tokStart+2,"Expected number in radix "+radix);if(isIdentifierStart(input.charCodeAt(tokPos)))raise(tokPos,"Identifier directly after number");return finishToken(_num,val)}function readNumber(startsWithDot){var start=tokPos,isFloat=false,octal=input.charCodeAt(tokPos)===48;if(!startsWithDot&&readInt(10)===null)raise(start,"Invalid number");if(input.charCodeAt(tokPos)===46){++tokPos;readInt(10);isFloat=true}var next=input.charCodeAt(tokPos);if(next===69||next===101){next=input.charCodeAt(++tokPos);if(next===43||next===45)++tokPos;if(readInt(10)===null)raise(start,"Invalid number");isFloat=true}if(isIdentifierStart(input.charCodeAt(tokPos)))raise(tokPos,"Identifier directly after number");var str=input.slice(start,tokPos),val;if(isFloat)val=parseFloat(str);else if(!octal||str.length===1)val=parseInt(str,10);else if(/[89]/.test(str)||strict)raise(start,"Invalid number");else val=parseInt(str,8);return finishToken(_num,val)}function readCodePoint(){var ch=input.charCodeAt(tokPos),code;if(ch===123){if(options.ecmaVersion<6)unexpected();++tokPos;code=readHexChar(input.indexOf("}",tokPos)-tokPos);++tokPos;if(code>1114111)unexpected()}else{code=readHexChar(4)}if(code<=65535){return String.fromCharCode(code)}var cu1=(code-65536>>10)+55296;var cu2=(code-65536&1023)+56320;return String.fromCharCode(cu1,cu2)}function readString(quote){var isJSX=curTokContext()===j_oTag;var out="",chunkStart=++tokPos;for(;;){if(tokPos>=inputLen)raise(tokStart,"Unterminated string constant");var ch=input.charCodeAt(tokPos);if(ch===quote)break;if(ch===92&&!isJSX){out+=input.slice(chunkStart,tokPos);out+=readEscapedChar();chunkStart=tokPos}else if(ch===38&&isJSX){out+=input.slice(chunkStart,tokPos);out+=readJSXEntity();chunkStart=tokPos}else{if(isNewLine(ch)&&!isJSX)raise(tokStart,"Unterminated string constant");++tokPos}}out+=input.slice(chunkStart,tokPos++);return finishToken(_string,out)}function readTmplToken(){var out="",chunkStart=tokPos;for(;;){if(tokPos>=inputLen)raise(tokStart,"Unterminated template");var ch=input.charCodeAt(tokPos);if(ch===96||ch===36&&input.charCodeAt(tokPos+1)===123){if(tokPos===tokStart&&tokType===_template){if(ch===36){tokPos+=2;return finishToken(_dollarBraceL)}else{++tokPos;return finishToken(_backQuote)}}out+=input.slice(chunkStart,tokPos);return finishToken(_template,out)}if(ch===92){out+=input.slice(chunkStart,tokPos);out+=readEscapedChar();chunkStart=tokPos}else if(isNewLine(ch)){out+=input.slice(chunkStart,tokPos);++tokPos;if(ch===13&&input.charCodeAt(tokPos)===10){++tokPos;out+="\n"}else{out+=String.fromCharCode(ch)}if(options.locations){++tokCurLine;tokLineStart=tokPos}chunkStart=tokPos}else{++tokPos}}}var XHTMLEntities={quot:'"',amp:"&",apos:"'",lt:"<",gt:">",nbsp:" ",iexcl:"¡",cent:"¢",pound:"£",curren:"¤",yen:"¥",brvbar:"¦",sect:"§",uml:"¨",copy:"©",ordf:"ª",laquo:"«",not:"¬",shy:"­",reg:"®",macr:"¯",deg:"°",plusmn:"±",sup2:"²",sup3:"³",acute:"´",micro:"µ",para:"¶",middot:"·",cedil:"¸",sup1:"¹",ordm:"º",raquo:"»",frac14:"¼",frac12:"½",frac34:"¾",iquest:"¿",Agrave:"À",Aacute:"Á",Acirc:"Â",Atilde:"Ã",Auml:"Ä",Aring:"Å",AElig:"Æ",Ccedil:"Ç",Egrave:"È",Eacute:"É",Ecirc:"Ê",Euml:"Ë",Igrave:"Ì",Iacute:"Í",Icirc:"Î",Iuml:"Ï",ETH:"Ð",Ntilde:"Ñ",Ograve:"Ò",Oacute:"Ó",Ocirc:"Ô",Otilde:"Õ",Ouml:"Ö",times:"×",Oslash:"Ø",Ugrave:"Ù",Uacute:"Ú",Ucirc:"Û",Uuml:"Ü",Yacute:"Ý",THORN:"Þ",szlig:"ß",agrave:"à",aacute:"á",acirc:"â",atilde:"ã",auml:"ä",aring:"å",aelig:"æ",ccedil:"ç",egrave:"è",eacute:"é",ecirc:"ê",euml:"ë",igrave:"ì",iacute:"í",icirc:"î",iuml:"ï",eth:"ð",ntilde:"ñ",ograve:"ò",oacute:"ó",ocirc:"ô",otilde:"õ",ouml:"ö",divide:"÷",oslash:"ø",ugrave:"ù",uacute:"ú",ucirc:"û",uuml:"ü",yacute:"ý",thorn:"þ",yuml:"ÿ",OElig:"Œ",oelig:"œ",Scaron:"Š",scaron:"š",Yuml:"Ÿ",fnof:"ƒ",circ:"ˆ",tilde:"˜",Alpha:"Α",Beta:"Β",Gamma:"Γ",Delta:"Δ",Epsilon:"Ε",Zeta:"Ζ",Eta:"Η",Theta:"Θ",Iota:"Ι",Kappa:"Κ",Lambda:"Λ",Mu:"Μ",Nu:"Ν",Xi:"Ξ",Omicron:"Ο",Pi:"Π",Rho:"Ρ",Sigma:"Σ",Tau:"Τ",Upsilon:"Υ",Phi:"Φ",Chi:"Χ",Psi:"Ψ",Omega:"Ω",alpha:"α",beta:"β",gamma:"γ",delta:"δ",epsilon:"ε",zeta:"ζ",eta:"η",theta:"θ",iota:"ι",kappa:"κ",lambda:"λ",mu:"μ",nu:"ν",xi:"ξ",omicron:"ο",pi:"π",rho:"ρ",sigmaf:"ς",sigma:"σ",tau:"τ",upsilon:"υ",phi:"φ",chi:"χ",psi:"ψ",omega:"ω",thetasym:"ϑ",upsih:"ϒ",piv:"ϖ",ensp:" ",emsp:" ",thinsp:" ",zwnj:"‌",zwj:"‍",lrm:"‎",rlm:"‏",ndash:"–",mdash:"—",lsquo:"‘",rsquo:"’",sbquo:"‚",ldquo:"“",rdquo:"”",bdquo:"„",dagger:"†",Dagger:"‡",bull:"•",hellip:"…",permil:"‰",prime:"′",Prime:"″",lsaquo:"‹",rsaquo:"›",oline:"‾",frasl:"⁄",euro:"€",image:"ℑ",weierp:"℘",real:"ℜ",trade:"™",alefsym:"ℵ",larr:"←",uarr:"↑",rarr:"→",darr:"↓",harr:"↔",crarr:"↵",lArr:"⇐",uArr:"⇑",rArr:"⇒",dArr:"⇓",hArr:"⇔",forall:"∀",part:"∂",exist:"∃",empty:"∅",nabla:"∇",isin:"∈",notin:"∉",ni:"∋",prod:"∏",sum:"∑",minus:"−",lowast:"∗",radic:"√",prop:"∝",infin:"∞",ang:"∠",and:"∧",or:"∨",cap:"∩",cup:"∪","int":"∫",there4:"∴",sim:"∼",cong:"≅",asymp:"≈",ne:"≠",equiv:"≡",le:"≤",ge:"≥",sub:"⊂",sup:"⊃",nsub:"⊄",sube:"⊆",supe:"⊇",oplus:"⊕",otimes:"⊗",perp:"⊥",sdot:"⋅",lceil:"⌈",rceil:"⌉",lfloor:"⌊",rfloor:"⌋",lang:"〈",rang:"〉",loz:"◊",spades:"♠",clubs:"♣",hearts:"♥",diams:"♦"}; function readJSXEntity(){var str="",count=0,entity;var ch=input[tokPos];if(ch!=="&")raise(tokPos,"Entity must start with an ampersand");var startPos=++tokPos;while(tokPos<inputLen&&count++<10){ch=input[tokPos++];if(ch===";"){if(str[0]==="#"){if(str[1]==="x"){str=str.substr(2);if(hexNumber.test(str)){entity=String.fromCharCode(parseInt(str,16))}}else{str=str.substr(1);if(decimalNumber.test(str)){entity=String.fromCharCode(parseInt(str,10))}}}else{entity=XHTMLEntities[str]}break}str+=ch}if(!entity){tokPos=startPos;return"&"}return entity}function readJSXToken(){var out="",chunkStart=tokPos;for(;;){if(tokPos>=inputLen)raise(tokStart,"Unterminated JSX contents");var ch=input.charCodeAt(tokPos);switch(ch){case 123:case 60:if(tokPos===tokStart){return getTokenFromCode(ch)}out+=input.slice(chunkStart,tokPos);return finishToken(_jsxText,out);case 38:out+=input.slice(chunkStart,tokPos);out+=readJSXEntity();chunkStart=tokPos;break;default:if(isNewLine(ch)){out+=input.slice(chunkStart,tokPos);++tokPos;if(ch===13&&input.charCodeAt(tokPos)===10){++tokPos;out+="\n"}else{out+=String.fromCharCode(ch)}if(options.locations){++tokCurLine;tokLineStart=tokPos}chunkStart=tokPos}else{++tokPos}}}}function readEscapedChar(){var ch=input.charCodeAt(++tokPos);var octal=/^[0-7]+/.exec(input.slice(tokPos,tokPos+3));if(octal)octal=octal[0];while(octal&&parseInt(octal,8)>255)octal=octal.slice(0,-1);if(octal==="0")octal=null;++tokPos;if(octal){if(strict)raise(tokPos-2,"Octal literal in strict mode");tokPos+=octal.length-1;return String.fromCharCode(parseInt(octal,8))}else{switch(ch){case 110:return"\n";case 114:return"\r";case 120:return String.fromCharCode(readHexChar(2));case 117:return readCodePoint();case 116:return" ";case 98:return"\b";case 118:return" ";case 102:return"\f";case 48:return"\x00";case 13:if(input.charCodeAt(tokPos)===10)++tokPos;case 10:if(options.locations){tokLineStart=tokPos;++tokCurLine}return"";default:return String.fromCharCode(ch)}}}var XHTMLEntities={quot:'"',amp:"&",apos:"'",lt:"<",gt:">",nbsp:" ",iexcl:"¡",cent:"¢",pound:"£",curren:"¤",yen:"¥",brvbar:"¦",sect:"§",uml:"¨",copy:"©",ordf:"ª",laquo:"«",not:"¬",shy:"­",reg:"®",macr:"¯",deg:"°",plusmn:"±",sup2:"²",sup3:"³",acute:"´",micro:"µ",para:"¶",middot:"·",cedil:"¸",sup1:"¹",ordm:"º",raquo:"»",frac14:"¼",frac12:"½",frac34:"¾",iquest:"¿",Agrave:"À",Aacute:"Á",Acirc:"Â",Atilde:"Ã",Auml:"Ä",Aring:"Å",AElig:"Æ",Ccedil:"Ç",Egrave:"È",Eacute:"É",Ecirc:"Ê",Euml:"Ë",Igrave:"Ì",Iacute:"Í",Icirc:"Î",Iuml:"Ï",ETH:"Ð",Ntilde:"Ñ",Ograve:"Ò",Oacute:"Ó",Ocirc:"Ô",Otilde:"Õ",Ouml:"Ö",times:"×",Oslash:"Ø",Ugrave:"Ù",Uacute:"Ú",Ucirc:"Û",Uuml:"Ü",Yacute:"Ý",THORN:"Þ",szlig:"ß",agrave:"à",aacute:"á",acirc:"â",atilde:"ã",auml:"ä",aring:"å",aelig:"æ",ccedil:"ç",egrave:"è",eacute:"é",ecirc:"ê",euml:"ë",igrave:"ì",iacute:"í",icirc:"î",iuml:"ï",eth:"ð",ntilde:"ñ",ograve:"ò",oacute:"ó",ocirc:"ô",otilde:"õ",ouml:"ö",divide:"÷",oslash:"ø",ugrave:"ù",uacute:"ú",ucirc:"û",uuml:"ü",yacute:"ý",thorn:"þ",yuml:"ÿ",OElig:"Œ",oelig:"œ",Scaron:"Š",scaron:"š",Yuml:"Ÿ",fnof:"ƒ",circ:"ˆ",tilde:"˜",Alpha:"Α",Beta:"Β",Gamma:"Γ",Delta:"Δ",Epsilon:"Ε",Zeta:"Ζ",Eta:"Η",Theta:"Θ",Iota:"Ι",Kappa:"Κ",Lambda:"Λ",Mu:"Μ",Nu:"Ν",Xi:"Ξ",Omicron:"Ο",Pi:"Π",Rho:"Ρ",Sigma:"Σ",Tau:"Τ",Upsilon:"Υ",Phi:"Φ",Chi:"Χ",Psi:"Ψ",Omega:"Ω",alpha:"α",beta:"β",gamma:"γ",delta:"δ",epsilon:"ε",zeta:"ζ",eta:"η",theta:"θ",iota:"ι",kappa:"κ",lambda:"λ",mu:"μ",nu:"ν",xi:"ξ",omicron:"ο",pi:"π",rho:"ρ",sigmaf:"ς",sigma:"σ",tau:"τ",upsilon:"υ",phi:"φ",chi:"χ",psi:"ψ",omega:"ω",thetasym:"ϑ",upsih:"ϒ",piv:"ϖ",ensp:" ",emsp:" ",thinsp:" ",zwnj:"‌",zwj:"‍",lrm:"‎",rlm:"‏",ndash:"–",mdash:"—",lsquo:"‘",rsquo:"’",sbquo:"‚",ldquo:"“",rdquo:"”",bdquo:"„",dagger:"†",Dagger:"‡",bull:"•",hellip:"…",permil:"‰",prime:"′",Prime:"″",lsaquo:"‹",rsaquo:"›",oline:"‾",frasl:"⁄",euro:"€",image:"ℑ",weierp:"℘",real:"ℜ",trade:"™",alefsym:"ℵ",larr:"←",uarr:"↑",rarr:"→",darr:"↓",harr:"↔",crarr:"↵",lArr:"⇐",uArr:"⇑",rArr:"⇒",dArr:"⇓",hArr:"⇔",forall:"∀",part:"∂",exist:"∃",empty:"∅",nabla:"∇",isin:"∈",notin:"∉",ni:"∋",prod:"∏",sum:"∑",minus:"−",lowast:"∗",radic:"√",prop:"∝",infin:"∞",ang:"∠",and:"∧",or:"∨",cap:"∩",cup:"∪","int":"∫",there4:"∴",sim:"∼",cong:"≅",asymp:"≈",ne:"≠",equiv:"≡",le:"≤",ge:"≥",sub:"⊂",sup:"⊃",nsub:"⊄",sube:"⊆",supe:"⊇",oplus:"⊕",otimes:"⊗",perp:"⊥",sdot:"⋅",lceil:"⌈",rceil:"⌉",lfloor:"⌊",rfloor:"⌋",lang:"〈",rang:"〉",loz:"◊",spades:"♠",clubs:"♣",hearts:"♥",diams:"♦"};function readXJSEntity(){var str="",count=0,entity;var ch=nextChar();if(ch!=="&")raise(tokPos,"Entity must start with an ampersand");var startPos=++tokPos;while(tokPos<inputLen&&count++<10){ch=nextChar();tokPos++;if(ch===";"){if(str[0]==="#"){if(str[1]==="x"){str=str.substr(2);if(hexNumber.test(str)){entity=String.fromCharCode(parseInt(str,16))}}else{str=str.substr(1);if(decimalNumber.test(str)){entity=String.fromCharCode(parseInt(str,10))}}}else{entity=XHTMLEntities[str]}break}str+=ch}if(!entity){tokPos=startPos;return"&"}return entity}function readXJSText(stopChars){var str="";while(tokPos<inputLen){var ch=nextChar();if(stopChars.indexOf(ch)!==-1){break}if(ch==="&"){str+=readXJSEntity()}else{++tokPos;if(ch==="\r"&&nextChar()==="\n"){str+=ch;++tokPos;ch="\n"}if(ch==="\n"&&options.locations){tokLineStart=tokPos;++tokCurLine}str+=ch}}return finishToken(_xjsText,str)}function readXJSStringLiteral(){var quote=input.charCodeAt(tokPos);if(quote!==34&&quote!==39){raise("String literal must starts with a quote")}++tokPos;readXJSText([String.fromCharCode(quote)]);if(quote!==input.charCodeAt(tokPos)){unexpected()}++tokPos;return finishToken(tokType,tokVal)}function readHexChar(len){var n=readInt(16,len);if(n===null)raise(tokStart,"Bad character escape sequence");return n}var containsEsc;function readWord1(){containsEsc=false;var word="",first=true,chunkStart=tokPos;while(tokPos<inputLen){var ch=input.charCodeAt(tokPos);if(isIdentifierChar(ch)){++tokPos}else if(ch===92){containsEsc=true;word+=input.slice(chunkStart,tokPos);if(input.charCodeAt(++tokPos)!=117)raise(tokPos,"Expecting Unicode escape sequence \\uXXXX");++tokPos;var esc=readHexChar(4);var escStr=String.fromCharCode(esc);if(!escStr)raise(tokPos-1,"Invalid Unicode escape");if(!(first?isIdentifierStart(esc):isIdentifierChar(esc)))raise(tokPos-4,"Invalid Unicode escape");word+=escStr;chunkStart=tokPos}else{break}first=false}return word+input.slice(chunkStart,tokPos)}function readWord(){var word=readWord1();var type=inXJSTag?_xjsName:_name;if(!containsEsc&&isKeyword(word))type=keywordTypes[word];return finishToken(type,word)}function readJSXWord(){var ch,start=tokPos;do{ch=input.charCodeAt(++tokPos)}while(isIdentifierChar(ch)||ch===45);return finishToken(_jsxName,input.slice(start,tokPos))}function next(){if(options.onToken)options.onToken(new Token);lastStart=tokStart;lastEnd=tokEnd;lastEndLoc=tokEndLoc;readToken()}function setStrict(strct){strict=strct;if(tokType!==_num&&tokType!==_string)return;tokPos=tokStart;if(options.locations){while(tokPos<tokLineStart){tokLineStart=input.lastIndexOf("\n",tokLineStart-2)+1;--tokCurLine}}skipSpace();readToken()}function Node(){this.type=null;this.start=tokStart;this.end=null}exports.Node=Node;function SourceLocation(){this.start=tokStartLoc;this.end=null;if(sourceFile!==null)this.source=sourceFile}function startNode(){var node=new exports.Node;if(options.locations)node.loc=new SourceLocation;if(options.directSourceFile)node.sourceFile=options.directSourceFile;if(options.ranges)node.range=[tokStart,0];return node}function storeCurrentPos(){return options.locations?[tokStart,tokStartLoc]:tokStart}function startNodeAt(pos){var node=new exports.Node,start=pos;if(options.locations){node.loc=new SourceLocation;node.loc.start=start[1];start=pos[0]}node.start=start;if(options.directSourceFile)node.sourceFile=options.directSourceFile;if(options.ranges)node.range=[start,0];return node}function finishNode(node,type){node.type=type;node.end=lastEnd;if(options.locations)node.loc.end=lastEndLoc;if(options.ranges)node.range[1]=lastEnd;return node}function finishNodeAt(node,type,pos){if(options.locations){node.loc.end=pos[1];pos=pos[0]}node.type=type;node.end=pos;if(options.ranges)node.range[1]=pos;return node}function isUseStrict(stmt){return options.ecmaVersion>=5&&stmt.type==="ExpressionStatement"&&stmt.expression.type==="Literal"&&stmt.expression.value==="use strict"}function eat(type){if(tokType===type){next();return true}else{return false}}function isContextual(name){return tokType===_name&&tokVal===name}function eatContextual(name){return tokVal===name&&eat(_name)}function expectContextual(name){if(!eatContextual(name))unexpected()}function canInsertSemicolon(){return!options.strictSemicolons&&(tokType===_eof||tokType===_braceR||newline.test(input.slice(lastEnd,tokStart)))}function semicolon(){if(!eat(_semi)&&!canInsertSemicolon())unexpected()}function expect(type){eat(type)||unexpected()}function nextChar(){return input.charAt(tokPos)}function unexpected(pos){raise(pos!=null?pos:tokStart,"Unexpected token")}function has(obj,propName){return Object.prototype.hasOwnProperty.call(obj,propName)}function toAssignable(node,isBinding){if(options.ecmaVersion>=6&&node){switch(node.type){case"Identifier":case"VirtualPropertyExpression":case"MemberExpression":case"SpreadProperty":case"ObjectPattern":case"ArrayPattern":case"AssignmentPattern":break;case"ObjectExpression":node.type="ObjectPattern";for(var i=0;i<node.properties.length;i++){var prop=node.properties[i];if(prop.type==="SpreadProperty")continue;if(prop.kind!=="init")raise(prop.key.start,"Object pattern can't contain getter or setter");toAssignable(prop.value,isBinding)}break;case"ArrayExpression":node.type="ArrayPattern";toAssignableList(node.elements,isBinding);break;case"AssignmentExpression":if(node.operator==="="){node.type="AssignmentPattern"}else{raise(node.left.end,"Only '=' operator can be used for specifying default value.")}break;case"MemberExpression":if(!isBinding)break;default:raise(node.start,"Assigning to rvalue")}}return node}function toAssignableList(exprList,isBinding){if(exprList.length){for(var i=0;i<exprList.length-1;i++){toAssignable(exprList[i],isBinding)}var last=exprList[exprList.length-1];switch(last.type){case"RestElement":break;case"SpreadElement":last.type="RestElement";var arg=last.argument;toAssignable(arg,isBinding);if(arg.type!=="Identifier"&&arg.type!=="MemberExpression"&&arg.type!=="ArrayPattern")unexpected(arg.start);break;default:toAssignable(last,isBinding)}}return exprList}function parseSpread(refShorthandDefaultPos){var node=startNode();next();node.argument=parseMaybeAssign(refShorthandDefaultPos);return finishNode(node,"SpreadElement")}function parseRest(){var node=startNode();next();node.argument=tokType===_name||tokType===_bracketL?parseBindingAtom():unexpected();return finishNode(node,"RestElement")}function parseBindingAtom(){if(options.ecmaVersion<6)return parseIdent();switch(tokType){case _name:return parseIdent();case _bracketL:var node=startNode();next();node.elements=parseBindingList(_bracketR,true);return finishNode(node,"ArrayPattern");case _braceL:return parseObj(true);default:unexpected()}}function parseBindingList(close,allowEmpty){var elts=[],first=true;while(!eat(close)){first?first=false:expect(_comma);if(tokType===_ellipsis){elts.push(parseAssignableListItemTypes(parseRest()));expect(close);break}var elem;if(allowEmpty&&tokType===_comma){elem=null}else{var left=parseMaybeDefault();parseAssignableListItemTypes(left);elem=parseMaybeDefault(null,left)}elts.push(elem)}return elts}function parseAssignableListItemTypes(param){if(eat(_question)){param.optional=true}if(tokType===_colon){param.typeAnnotation=parseTypeAnnotation()}finishNode(param,param.type);return param}function parseMaybeDefault(startPos,left){startPos=startPos||storeCurrentPos();left=left||parseBindingAtom();if(!eat(_eq))return left;var node=startNodeAt(startPos);node.operator="=";node.left=left;node.right=parseMaybeAssign();return finishNode(node,"AssignmentPattern")}function checkFunctionParam(param,nameHash){switch(param.type){case"Identifier":if(isStrictReservedWord(param.name)||isStrictBadIdWord(param.name))raise(param.start,"Defining '"+param.name+"' in strict mode");if(has(nameHash,param.name))raise(param.start,"Argument name clash in strict mode");nameHash[param.name]=true;break;case"ObjectPattern":for(var i=0;i<param.properties.length;i++){var param2=param.properties[i];if(param2.type==="SpreadProperty"){checkFunctionParam(param2.argument,nameHash)}else{checkFunctionParam(param2.value,nameHash)}}break;case"ArrayPattern":for(var i=0;i<param.elements.length;i++){var elem=param.elements[i];if(elem)checkFunctionParam(elem,nameHash)}break;case"RestElement":return checkFunctionParam(param.argument,nameHash)}}function checkPropClash(prop,propHash){if(options.ecmaVersion>=6)return;var key=prop.key,name;switch(key.type){case"Identifier":name=key.name;break;case"Literal":name=String(key.value);break;default:return}var kind=prop.kind||"init",other;if(has(propHash,name)){other=propHash[name];var isGetSet=kind!=="init";if((strict||isGetSet)&&other[kind]||!(isGetSet^other.init))raise(key.start,"Redefinition of property")}else{other=propHash[name]={init:false,get:false,set:false}}other[kind]=true}function checkLVal(expr,isBinding){switch(expr.type){case"Identifier":if(strict&&(isStrictBadIdWord(expr.name)||isStrictReservedWord(expr.name)))raise(expr.start,(isBinding?"Binding ":"Assigning to ")+expr.name+" in strict mode");break;case"MemberExpression":if(isBinding)raise(expr.start,"Binding to member expression");break;case"ObjectPattern":for(var i=0;i<expr.properties.length;i++){var prop=expr.properties[i];if(prop.type==="Property")prop=prop.value;checkLVal(prop,isBinding)}break;case"ArrayPattern":for(var i=0;i<expr.elements.length;i++){var elem=expr.elements[i];if(elem)checkLVal(elem,isBinding)}break;case"AssignmentPattern":checkLVal(expr.left);break;case"SpreadProperty":case"VirtualPropertyExpression":break;case"RestElement":checkLVal(expr.argument);break;default:raise(expr.start,"Assigning to rvalue")}}function parseTopLevel(node){var first=true;if(!node.body)node.body=[];while(tokType!==_eof){var stmt=parseStatement(true,true);node.body.push(stmt);if(first&&isUseStrict(stmt))setStrict(true);first=false}next();return finishNode(node,"Program")}var loopLabel={kind:"loop"},switchLabel={kind:"switch"};function parseStatement(declaration,topLevel){var starttype=tokType,node=startNode();switch(starttype){case _break:case _continue:return parseBreakContinueStatement(node,starttype.keyword);case _debugger:return parseDebuggerStatement(node);case _do:return parseDoStatement(node);case _for:return parseForStatement(node);case _function:if(!declaration&&options.ecmaVersion>=6)unexpected();return parseFunctionStatement(node);case _class:if(!declaration)unexpected();return parseClass(node,true);case _if:return parseIfStatement(node);case _return:return parseReturnStatement(node);case _switch:return parseSwitchStatement(node);case _throw:return parseThrowStatement(node);case _try:return parseTryStatement(node);case _let:case _const:if(!declaration)unexpected();case _var:return parseVarStatement(node,starttype.keyword);case _while:return parseWhileStatement(node);case _with:return parseWithStatement(node);case _braceL:return parseBlock();case _semi:return parseEmptyStatement(node);case _export:case _import:if(!topLevel&&!options.allowImportExportEverywhere)raise(tokStart,"'import' and 'export' may only appear at the top level");return starttype===_import?parseImport(node):parseExport(node);case _name:if(options.ecmaVersion>=7&&tokType===_name){if(tokVal==="private"){next();return parsePrivate(node)}if(tokVal==="async"){if(input.slice(tokEnd+1,tokEnd+10)==="function "){next();expect(_function);return parseFunction(node,true,true)}}}default:var maybeName=tokVal,expr=parseExpression();if(starttype===_name&&expr.type==="Identifier"){if(eat(_colon)){return parseLabeledStatement(node,maybeName,expr)}if(expr.name==="declare"){if(tokType===_class||tokType===_name||tokType===_function||tokType===_var){return parseDeclare(node)}}else if(tokType===_name){if(expr.name==="interface"){return parseInterface(node)}else if(expr.name==="type"){return parseTypeAlias(node)}}}return parseExpressionStatement(node,expr)}}function parseBreakContinueStatement(node,keyword){var isBreak=keyword=="break";next();if(eat(_semi)||canInsertSemicolon())node.label=null;else if(tokType!==_name)unexpected();else{node.label=parseIdent();semicolon()}for(var i=0;i<labels.length;++i){var lab=labels[i];if(node.label==null||lab.name===node.label.name){if(lab.kind!=null&&(isBreak||lab.kind==="loop"))break;if(node.label&&isBreak)break}}if(i===labels.length)raise(node.start,"Unsyntactic "+keyword);return finishNode(node,isBreak?"BreakStatement":"ContinueStatement")}function parseDebuggerStatement(node){next();semicolon();return finishNode(node,"DebuggerStatement")}function parseDoStatement(node){next();labels.push(loopLabel);node.body=parseStatement(false);labels.pop();expect(_while);node.test=parseParenExpression();if(options.ecmaVersion>=6)eat(_semi);else semicolon();return finishNode(node,"DoWhileStatement")}function parseForStatement(node){next();labels.push(loopLabel);expect(_parenL);if(tokType===_semi)return parseFor(node,null);if(tokType===_var||tokType===_let){var init=startNode(),varKind=tokType.keyword,isLet=tokType===_let;next();parseVar(init,true,varKind);finishNode(init,"VariableDeclaration");if((tokType===_in||options.ecmaVersion>=6&&isContextual("of"))&&init.declarations.length===1&&!(isLet&&init.declarations[0].init))return parseForIn(node,init);return parseFor(node,init)}var refShorthandDefaultPos={start:0};var init=parseExpression(true,refShorthandDefaultPos);if(tokType===_in||options.ecmaVersion>=6&&isContextual("of")){toAssignable(init);checkLVal(init);return parseForIn(node,init)}else if(refShorthandDefaultPos.start){unexpected(refShorthandDefaultPos.start)}return parseFor(node,init)}function parseFunctionStatement(node){next();return parseFunction(node,true,false)}function parseIfStatement(node){next();node.test=parseParenExpression();node.consequent=parseStatement(false);node.alternate=eat(_else)?parseStatement(false):null;return finishNode(node,"IfStatement")}function parseReturnStatement(node){if(!inFunction&&!options.allowReturnOutsideFunction)raise(tokStart,"'return' outside of function");next();if(eat(_semi)||canInsertSemicolon())node.argument=null;else{node.argument=parseExpression();semicolon()}return finishNode(node,"ReturnStatement")}function parseSwitchStatement(node){next();node.discriminant=parseParenExpression();node.cases=[];expect(_braceL);labels.push(switchLabel);for(var cur,sawDefault;tokType!=_braceR;){if(tokType===_case||tokType===_default){var isCase=tokType===_case;if(cur)finishNode(cur,"SwitchCase");node.cases.push(cur=startNode());cur.consequent=[];next();if(isCase)cur.test=parseExpression();else{if(sawDefault)raise(lastStart,"Multiple default clauses");sawDefault=true;cur.test=null}expect(_colon)}else{if(!cur)unexpected();cur.consequent.push(parseStatement(true))}}if(cur)finishNode(cur,"SwitchCase");next();labels.pop();return finishNode(node,"SwitchStatement")}function parseThrowStatement(node){next();if(newline.test(input.slice(lastEnd,tokStart)))raise(lastEnd,"Illegal newline after throw");node.argument=parseExpression();semicolon();return finishNode(node,"ThrowStatement")}function parseTryStatement(node){next();node.block=parseBlock();node.handler=null;if(tokType===_catch){var clause=startNode();next();expect(_parenL);clause.param=parseBindingAtom();checkLVal(clause.param,true);expect(_parenR);clause.guard=null;clause.body=parseBlock();node.handler=finishNode(clause,"CatchClause")}node.guardedHandlers=empty;node.finalizer=eat(_finally)?parseBlock():null;if(!node.handler&&!node.finalizer)raise(node.start,"Missing catch or finally clause");return finishNode(node,"TryStatement")}function parseVarStatement(node,kind){next();parseVar(node,false,kind);semicolon();return finishNode(node,"VariableDeclaration")}function parseWhileStatement(node){next();node.test=parseParenExpression();labels.push(loopLabel);node.body=parseStatement(false);labels.pop();return finishNode(node,"WhileStatement")}function parseWithStatement(node){if(strict)raise(tokStart,"'with' in strict mode");next();node.object=parseParenExpression();node.body=parseStatement(false);return finishNode(node,"WithStatement")}function parseEmptyStatement(node){next();return finishNode(node,"EmptyStatement")}function parseLabeledStatement(node,maybeName,expr){for(var i=0;i<labels.length;++i)if(labels[i].name===maybeName)raise(expr.start,"Label '"+maybeName+"' is already declared");var kind=tokType.isLoop?"loop":tokType===_switch?"switch":null;labels.push({name:maybeName,kind:kind});node.body=parseStatement(true);labels.pop();node.label=expr;return finishNode(node,"LabeledStatement")}function parseExpressionStatement(node,expr){node.expression=expr;semicolon();return finishNode(node,"ExpressionStatement")}function parseParenExpression(){expect(_parenL);var val=parseExpression();expect(_parenR);return val}function parseBlock(allowStrict){var node=startNode(),first=true,oldStrict;node.body=[];expect(_braceL);while(!eat(_braceR)){var stmt=parseStatement(true);node.body.push(stmt);if(first&&allowStrict&&isUseStrict(stmt)){oldStrict=strict;setStrict(strict=true)}first=false}if(oldStrict===false)setStrict(false);return finishNode(node,"BlockStatement")}function parseFor(node,init){node.init=init;expect(_semi);node.test=tokType===_semi?null:parseExpression();expect(_semi);node.update=tokType===_parenR?null:parseExpression();expect(_parenR);node.body=parseStatement(false);labels.pop();return finishNode(node,"ForStatement")}function parseForIn(node,init){var type=tokType===_in?"ForInStatement":"ForOfStatement";next();node.left=init;node.right=parseExpression();expect(_parenR);node.body=parseStatement(false);labels.pop();return finishNode(node,type)}function parseVar(node,noIn,kind){node.declarations=[];node.kind=kind;for(;;){var decl=startNode();decl.id=parseBindingAtom();checkLVal(decl.id,true);if(tokType===_colon){decl.id.typeAnnotation=parseTypeAnnotation();finishNode(decl.id,decl.id.type)}decl.init=eat(_eq)?parseMaybeAssign(noIn):kind===_const.keyword?unexpected():null;node.declarations.push(finishNode(decl,"VariableDeclarator"));if(!eat(_comma))break}return node}function parseExpression(noIn,refShorthandDefaultPos){var start=storeCurrentPos();var expr=parseMaybeAssign(noIn,refShorthandDefaultPos);if(tokType===_comma){var node=startNodeAt(start);node.expressions=[expr];while(eat(_comma))node.expressions.push(parseMaybeAssign(noIn,refShorthandDefaultPos));return finishNode(node,"SequenceExpression")}return expr}function parseMaybeAssign(noIn,refShorthandDefaultPos,afterLeftParse){var failOnShorthandAssign;if(!refShorthandDefaultPos){refShorthandDefaultPos={start:0};failOnShorthandAssign=true}else{failOnShorthandAssign=false}var start=storeCurrentPos();var left=parseMaybeConditional(noIn,refShorthandDefaultPos);if(afterLeftParse)left=afterLeftParse(left,start);if(tokType.isAssign){var node=startNodeAt(start);node.operator=tokVal;node.left=tokType===_eq?toAssignable(left):left;refShorthandDefaultPos.start=0;checkLVal(left);next();node.right=parseMaybeAssign(noIn);return finishNode(node,"AssignmentExpression")}else if(failOnShorthandAssign&&refShorthandDefaultPos.start){unexpected(refShorthandDefaultPos.start)}return left}function parseMaybeConditional(noIn,refShorthandDefaultPos){var start=storeCurrentPos();var expr=parseExprOps(noIn,refShorthandDefaultPos);if(refShorthandDefaultPos&&refShorthandDefaultPos.start)return expr;if(eat(_question)){var node=startNodeAt(start);if(options.playground&&eat(_eq)){var left=node.left=toAssignable(expr);if(left.type!=="MemberExpression")raise(left.start,"You can only use member expressions in memoization assignment");node.right=parseMaybeAssign(noIn);node.operator="?=";return finishNode(node,"AssignmentExpression")}node.test=expr;node.consequent=parseMaybeAssign();expect(_colon);node.alternate=parseMaybeAssign(noIn);return finishNode(node,"ConditionalExpression")}return expr}function parseExprOps(noIn,refShorthandDefaultPos){var start=storeCurrentPos();var expr=parseMaybeUnary(refShorthandDefaultPos);if(refShorthandDefaultPos&&refShorthandDefaultPos.start)return expr;return parseExprOp(expr,start,-1,noIn)}function parseExprOp(left,leftStart,minPrec,noIn){var prec=tokType.binop;if(prec!=null&&(!noIn||tokType!==_in)){if(prec>minPrec){var node=startNodeAt(leftStart);node.left=left;node.operator=tokVal;var op=tokType;next();var start=storeCurrentPos();node.right=parseExprOp(parseMaybeUnary(),start,op.rightAssociative?prec-1:prec,noIn);finishNode(node,op===_logicalOR||op===_logicalAND?"LogicalExpression":"BinaryExpression");return parseExprOp(node,leftStart,minPrec,noIn)}}return left}function parseMaybeUnary(refShorthandDefaultPos){if(tokType.prefix){var node=startNode(),update=tokType.isUpdate;node.operator=tokVal;node.prefix=true;next();node.argument=parseMaybeUnary();if(refShorthandDefaultPos&&refShorthandDefaultPos.start)unexpected(refShorthandDefaultPos.start);if(update)checkLVal(node.argument);else if(strict&&node.operator==="delete"&&node.argument.type==="Identifier")raise(node.start,"Deleting local variable in strict mode");return finishNode(node,update?"UpdateExpression":"UnaryExpression")}var start=storeCurrentPos();var expr=parseExprSubscripts(refShorthandDefaultPos);if(refShorthandDefaultPos&&refShorthandDefaultPos.start)return expr;while(tokType.postfix&&!canInsertSemicolon()){var node=startNodeAt(start);node.operator=tokVal;node.prefix=false;node.argument=expr;checkLVal(expr);next();expr=finishNode(node,"UpdateExpression")}return expr}function parseExprSubscripts(refShorthandDefaultPos){var start=storeCurrentPos();var expr=parseExprAtom(refShorthandDefaultPos);if(refShorthandDefaultPos&&refShorthandDefaultPos.start)return expr;return parseSubscripts(expr,start)}function parseSubscripts(base,start,noCalls){if(options.playground&&eat(_hash)){var node=startNodeAt(start);node.object=base;node.property=parseIdent(true);if(eat(_parenL)){node.arguments=parseExprList(_parenR,false)}else{node.arguments=[]}return parseSubscripts(finishNode(node,"BindMemberExpression"),start,noCalls)}else if(eat(_paamayimNekudotayim)){var node=startNodeAt(start);node.object=base;node.property=parseIdent(true);return parseSubscripts(finishNode(node,"VirtualPropertyExpression"),start,noCalls)}else if(eat(_dot)){var node=startNodeAt(start);node.object=base;node.property=parseIdent(true);node.computed=false;return parseSubscripts(finishNode(node,"MemberExpression"),start,noCalls)}else if(eat(_bracketL)){var node=startNodeAt(start);node.object=base;node.property=parseExpression();node.computed=true;expect(_bracketR);return parseSubscripts(finishNode(node,"MemberExpression"),start,noCalls)}else if(!noCalls&&eat(_parenL)){var node=startNodeAt(start);node.callee=base;node.arguments=parseExprList(_parenR,false);return parseSubscripts(finishNode(node,"CallExpression"),start,noCalls)}else if(tokType===_backQuote){var node=startNodeAt(start);node.tag=base;node.quasi=parseTemplate();return parseSubscripts(finishNode(node,"TaggedTemplateExpression"),start,noCalls)}return base}function parseExprAtom(refShorthandDefaultPos){switch(tokType){case _this:var node=startNode();next();return finishNode(node,"ThisExpression");case _yield:if(inGenerator)return parseYield();case _name:var start=storeCurrentPos();var node=startNode();var id=parseIdent(tokType!==_name);if(options.ecmaVersion>=7){if(id.name==="async"){if(tokType===_parenL){var expr=parseParenAndDistinguishExpression(start,true);if(expr.type==="ArrowFunctionExpression"){return expr}else{node.callee=id;if(expr.type==="SequenceExpression"){node.arguments=expr.expressions}else{node.arguments=[expr]}return parseSubscripts(finishNode(node,"CallExpression"),start)}}else if(tokType===_name){id=parseIdent();expect(_arrow);return parseArrowExpression(node,[id],true)}if(tokType===_function&&!canInsertSemicolon()){next();return parseFunction(node,false,true)}}else if(id.name==="await"){if(inAsync)return parseAwait(node)}}if(!canInsertSemicolon()&&eat(_arrow)){return parseArrowExpression(startNodeAt(start),[id])}return id;case _regexp:var node=startNode();node.regex={pattern:tokVal.pattern,flags:tokVal.flags};node.value=tokVal.value;node.raw=input.slice(tokStart,tokEnd);next();return finishNode(node,"Literal");case _num:case _string:case _jsxText:var node=startNode();node.value=tokVal;node.raw=input.slice(tokStart,tokEnd);next();return finishNode(node,"Literal");case _null:case _true:case _false:var node=startNode();node.value=tokType.atomValue;node.raw=tokType.keyword;next();return finishNode(node,"Literal");case _parenL:return parseParenAndDistinguishExpression();case _bracketL:var node=startNode();next();if(options.ecmaVersion>=7&&tokType===_for){return parseComprehension(node,false)}node.elements=parseExprList(_bracketR,true,true,refShorthandDefaultPos);return finishNode(node,"ArrayExpression");case _braceL:return parseObj(false,refShorthandDefaultPos);case _function:var node=startNode();next();return parseFunction(node,false,false);case _class:return parseClass(startNode(),false);case _new:return parseNew();case _backQuote:return parseTemplate();case _hash:return parseBindFunctionExpression();case _jsxTagStart:return parseJSXElement();default:unexpected()}}function parseBindFunctionExpression(){var node=startNode();next();var start=storeCurrentPos();node.callee=parseSubscripts(parseExprAtom(),start,true);if(eat(_parenL)){node.arguments=parseExprList(_parenR,false)}else{node.arguments=[]}return finishNode(node,"BindFunctionExpression")}function parseParenAndDistinguishExpression(start,isAsync){start=start||storeCurrentPos();var val;if(options.ecmaVersion>=6){next();if(options.ecmaVersion>=7&&tokType===_for){return parseComprehension(startNodeAt(start),true)}var innerStart=storeCurrentPos(),exprList=[],first=true;var refShorthandDefaultPos={start:0},spreadStart,innerParenStart,typeStart;var parseParenItem=function(node,start){if(tokType===_colon){var typeCastNode=startNodeAt(start);typeCastNode.expression=node;typeCastNode.typeAnnotation=parseTypeAnnotation();return finishNode(typeCastNode,"TypeCastExpression")}else{return node}};while(tokType!==_parenR){first?first=false:expect(_comma);if(tokType===_ellipsis){var spreadNodeStart=storeCurrentPos();spreadStart=tokStart;exprList.push(parseParenItem(parseRest(),spreadNodeStart));break}else{if(tokType===_parenL&&!innerParenStart){innerParenStart=tokStart}exprList.push(parseMaybeAssign(false,refShorthandDefaultPos,parseParenItem))}}var innerEnd=storeCurrentPos();expect(_parenR);if(!canInsertSemicolon()&&eat(_arrow)){if(innerParenStart)unexpected(innerParenStart);for(var i=0;i<exprList.length;i++){var listItem=exprList[i];if(listItem.type==="TypeCastExpression"){var expr=listItem.expression;expr.returnType=listItem.typeAnnotation;exprList[i]=expr}}return parseArrowExpression(startNodeAt(start),exprList,isAsync)}if(!exprList.length)unexpected(lastStart);if(spreadStart)unexpected(spreadStart);if(refShorthandDefaultPos.start)unexpected(refShorthandDefaultPos.start);if(exprList.length>1){val=startNodeAt(innerStart);val.expressions=exprList;finishNodeAt(val,"SequenceExpression",innerEnd)}else{val=exprList[0]}}else{val=parseParenExpression()}if(options.preserveParens){var par=startNodeAt(start);par.expression=val;return finishNode(par,"ParenthesizedExpression")}else{return val}}function parseNew(){var node=startNode();next();var start=storeCurrentPos();node.callee=parseSubscripts(parseExprAtom(),start,true);if(eat(_parenL))node.arguments=parseExprList(_parenR,false);else node.arguments=empty;return finishNode(node,"NewExpression")}function parseTemplateElement(){var elem=startNode();elem.value={raw:input.slice(tokStart,tokEnd),cooked:tokVal};next();elem.tail=tokType===_backQuote;return finishNode(elem,"TemplateElement") }function parseTemplate(){var node=startNode();next();node.expressions=[];var curElt=parseTemplateElement();node.quasis=[curElt];while(!curElt.tail){expect(_dollarBraceL);node.expressions.push(parseExpression());expect(_braceR);node.quasis.push(curElt=parseTemplateElement())}next();return finishNode(node,"TemplateLiteral")}function parseObj(isPattern,refShorthandDefaultPos){var node=startNode(),first=true,propHash={};node.properties=[];next();while(!eat(_braceR)){if(!first){expect(_comma);if(options.allowTrailingCommas&&eat(_braceR))break}else first=false;var prop=startNode(),start,isGenerator=false,isAsync=false;if(options.ecmaVersion>=7&&tokType===_ellipsis){prop=parseSpread();prop.type="SpreadProperty";node.properties.push(prop);continue}if(options.ecmaVersion>=6){prop.method=false;prop.shorthand=false;if(isPattern||refShorthandDefaultPos){start=storeCurrentPos()}if(!isPattern){isGenerator=eat(_star)}}if(options.ecmaVersion>=7&&isContextual("async")){var asyncId=parseIdent();if(tokType===_colon||tokType===_parenL){prop.key=asyncId}else{isAsync=true;parsePropertyName(prop)}}else{parsePropertyName(prop)}var typeParameters;if(isRelational("<")){typeParameters=parseTypeParameterDeclaration();if(tokType!==_parenL)unexpected()}if(eat(_colon)){prop.value=isPattern?parseMaybeDefault():parseMaybeAssign(false,refShorthandDefaultPos);prop.kind="init"}else if(options.ecmaVersion>=6&&tokType===_parenL){if(isPattern)unexpected();prop.kind="init";prop.method=true;prop.value=parseMethod(isGenerator,isAsync)}else if(options.ecmaVersion>=5&&!prop.computed&&prop.key.type==="Identifier"&&(prop.key.name==="get"||prop.key.name==="set"||options.playground&&prop.key.name==="memo")&&(tokType!=_comma&&tokType!=_braceR)){if(isGenerator||isAsync||isPattern)unexpected();prop.kind=prop.key.name;parsePropertyName(prop);prop.value=parseMethod(false,false)}else if(options.ecmaVersion>=6&&!prop.computed&&prop.key.type==="Identifier"){prop.kind="init";if(isPattern){prop.value=parseMaybeDefault(start,prop.key)}else if(tokType===_eq&&refShorthandDefaultPos){if(!refShorthandDefaultPos.start)refShorthandDefaultPos.start=tokStart;prop.value=parseMaybeDefault(start,prop.key)}else{prop.value=prop.key}prop.shorthand=true}else unexpected();prop.value.typeParameters=typeParameters;checkPropClash(prop,propHash);node.properties.push(finishNode(prop,"Property"))}return finishNode(node,isPattern?"ObjectPattern":"ObjectExpression")}function parsePropertyName(prop){if(options.ecmaVersion>=6){if(eat(_bracketL)){prop.computed=true;prop.key=parseExpression();expect(_bracketR);return}else{prop.computed=false}}prop.key=tokType===_num||tokType===_string?parseExprAtom():parseIdent(true)}function initFunction(node,isAsync){node.id=null;if(options.ecmaVersion>=6){node.generator=false;node.expression=false}if(options.ecmaVersion>=7){node.async=isAsync}}function parseFunction(node,isStatement,isAsync,allowExpressionBody){initFunction(node,isAsync);if(options.ecmaVersion>=6){node.generator=eat(_star)}if(isStatement||tokType===_name){node.id=parseIdent()}if(isRelational("<")){node.typeParameters=parseTypeParameterDeclaration()}parseFunctionParams(node);parseFunctionBody(node,allowExpressionBody);return finishNode(node,isStatement?"FunctionDeclaration":"FunctionExpression")}function parseMethod(isGenerator,isAsync){var node=startNode();initFunction(node,isAsync);parseFunctionParams(node);var allowExpressionBody;if(options.ecmaVersion>=6){node.generator=isGenerator;allowExpressionBody=true}else{allowExpressionBody=false}parseFunctionBody(node,allowExpressionBody);return finishNode(node,"FunctionExpression")}function parseFunctionParams(node){expect(_parenL);node.params=parseBindingList(_parenR,false);if(tokType===_colon){node.returnType=parseTypeAnnotation()}}function parseArrowExpression(node,params,isAsync){initFunction(node,isAsync);node.params=toAssignableList(params,true);parseFunctionBody(node,true);return finishNode(node,"ArrowFunctionExpression")}function parseFunctionBody(node,allowExpression){var isExpression=allowExpression&&tokType!==_braceL;var oldInAsync=inAsync;inAsync=node.async;if(isExpression){node.body=parseMaybeAssign();node.expression=true}else{var oldInFunc=inFunction,oldInGen=inGenerator,oldLabels=labels;inFunction=true;inGenerator=node.generator;labels=[];node.body=parseBlock(true);node.expression=false;inFunction=oldInFunc;inGenerator=oldInGen;labels=oldLabels}inAsync=oldInAsync;if(strict||!isExpression&&node.body.body.length&&isUseStrict(node.body.body[0])){var nameHash={};if(node.id)checkFunctionParam(node.id,{});for(var i=0;i<node.params.length;i++)checkFunctionParam(node.params[i],nameHash)}}function parsePrivate(node){node.declarations=[];do{node.declarations.push(parseIdent())}while(eat(_comma));semicolon();return finishNode(node,"PrivateDeclaration")}function parseClass(node,isStatement){next();node.id=tokType===_name?parseIdent():isStatement?unexpected():null;if(isRelational("<")){node.typeParameters=parseTypeParameterDeclaration()}node.superClass=eat(_extends)?parseExprSubscripts():null;if(node.superClass&&isRelational("<")){node.superTypeParameters=parseTypeParameterInstantiation()}if(isContextual("implements")){next();node.implements=parseClassImplements()}var classBody=startNode();classBody.body=[];expect(_braceL);while(!eat(_braceR)){if(eat(_semi))continue;var method=startNode();if(options.ecmaVersion>=7&&isContextual("private")){next();classBody.body.push(parsePrivate(method));continue}var isGenerator=eat(_star);var isAsync=false;parsePropertyName(method);if(tokType!==_parenL&&!method.computed&&method.key.type==="Identifier"&&method.key.name==="static"){if(isGenerator||isAsync)unexpected();method["static"]=true;isGenerator=eat(_star);parsePropertyName(method)}else{method["static"]=false}if(tokType!==_parenL&&!method.computed&&method.key.type==="Identifier"&&method.key.name==="async"){isAsync=true;parsePropertyName(method)}if(tokType!==_parenL&&!method.computed&&method.key.type==="Identifier"&&(method.key.name==="get"||method.key.name==="set")||options.playground&&method.key.name==="memo"){if(isGenerator||isAsync)unexpected();method.kind=method.key.name;parsePropertyName(method)}else{method.kind=""}var classProperty=false;if(tokType===_colon){method.typeAnnotation=parseTypeAnnotation();classProperty=true}if(options.playground&&eat(_eq)){method.value=parseMaybeAssign();classProperty=true}if(classProperty){semicolon();classBody.body.push(finishNode(method,"ClassProperty"))}else{var typeParameters;if(isRelational("<")){typeParameters=parseTypeParameterDeclaration()}method.value=parseMethod(isGenerator,isAsync);method.value.typeParameters=typeParameters;classBody.body.push(finishNode(method,"MethodDefinition"));eat(_semi)}}node.body=finishNode(classBody,"ClassBody");return finishNode(node,isStatement?"ClassDeclaration":"ClassExpression")}function parseClassImplements(){var implemented=[];do{var node=startNode();node.id=parseIdent();if(isRelational("<")){node.typeParameters=parseTypeParameterInstantiation()}else{node.typeParameters=null}implemented.push(finishNode(node,"ClassImplements"))}while(eat(_comma));return implemented}function parseExprList(close,allowTrailingComma,allowEmpty,refShorthandDefaultPos){var elts=[],first=true;while(!eat(close)){if(!first){expect(_comma);if(allowTrailingComma&&options.allowTrailingCommas&&eat(close))break}else first=false;if(allowEmpty&&tokType===_comma){elts.push(null)}else{if(tokType===_ellipsis)elts.push(parseSpread(refShorthandDefaultPos));else elts.push(parseMaybeAssign(false,refShorthandDefaultPos))}}return elts}function parseIdent(liberal){var node=startNode();if(liberal&&options.forbidReserved=="everywhere")liberal=false;if(tokType===_name){if(!liberal&&(options.forbidReserved&&(options.ecmaVersion===3?isReservedWord3:isReservedWord5)(tokVal)||strict&&isStrictReservedWord(tokVal))&&input.slice(tokStart,tokEnd).indexOf("\\")==-1)raise(tokStart,"The keyword '"+tokVal+"' is reserved");node.name=tokVal}else if(liberal&&tokType.keyword){node.name=tokType.keyword}else{unexpected()}next();return finishNode(node,"Identifier")}function parseExport(node){next();if(tokType===_var||tokType===_const||tokType===_let||tokType===_function||tokType===_class||isContextual("async")||isContextual("type")){node.declaration=parseStatement(true);node["default"]=false;node.specifiers=null;node.source=null}else if(eat(_default)){var expr=parseMaybeAssign();if(expr.id){switch(expr.type){case"FunctionExpression":expr.type="FunctionDeclaration";break;case"ClassExpression":expr.type="ClassDeclaration";break}}node.declaration=expr;node["default"]=true;node.specifiers=null;node.source=null;semicolon()}else{var isBatch=tokType===_star;node.declaration=null;node["default"]=false;node.specifiers=parseExportSpecifiers();if(eatContextual("from")){node.source=tokType===_string?parseExprAtom():unexpected()}else{if(isBatch)unexpected();node.source=null}semicolon()}return finishNode(node,"ExportDeclaration")}function parseExportSpecifiers(){var nodes=[],first=true;if(tokType===_star){var node=startNode();next();nodes.push(finishNode(node,"ExportBatchSpecifier"))}else{expect(_braceL);while(!eat(_braceR)){if(!first){expect(_comma);if(options.allowTrailingCommas&&eat(_braceR))break}else first=false;var node=startNode();node.id=parseIdent(tokType===_default);node.name=eatContextual("as")?parseIdent(true):null;nodes.push(finishNode(node,"ExportSpecifier"))}}return nodes}function parseImport(node){next();node.isType=false;node.specifiers=[];var typeId;if(isContextual("type")){var start=storeCurrentPos();typeId=parseIdent();if(tokType===_name&&tokVal!=="from"||tokType===_braceL||tokType===_star){node.isType=true}else{node.specifiers.push(parseImportSpecifierDefault(typeId,start));eat(_comma)}}if(tokType===_string){if(typeId)unexpected(typeId.start);node.source=parseExprAtom()}else{if(!isContextual("from"))parseImportSpecifiers(node.specifiers);expectContextual("from");node.source=tokType===_string?parseExprAtom():unexpected()}semicolon();return finishNode(node,"ImportDeclaration")}function parseImportSpecifiers(nodes){var first=true;if(tokType===_name){var start=storeCurrentPos();var id=parseIdent();nodes.push(parseImportSpecifierDefault(id,start));if(!eat(_comma))return nodes}if(tokType===_star){var node=startNode();next();expectContextual("as");node.name=parseIdent();checkLVal(node.name,true);nodes.push(finishNode(node,"ImportBatchSpecifier"));return nodes}expect(_braceL);while(!eat(_braceR)){if(!first){expect(_comma);if(options.allowTrailingCommas&&eat(_braceR))break}else first=false;var node=startNode();node.id=parseIdent(true);node.name=eatContextual("as")?parseIdent():null;checkLVal(node.name||node.id,true);node["default"]=false;nodes.push(finishNode(node,"ImportSpecifier"))}return nodes}function parseImportSpecifierDefault(id,start){var node=startNodeAt(start);node.id=id;checkLVal(node.id,true);node.name=null;node["default"]=true;return finishNode(node,"ImportSpecifier")}function parseYield(){var node=startNode();next();if(eat(_semi)||canInsertSemicolon()){node.delegate=false;node.argument=null}else{node.delegate=eat(_star);node.argument=parseMaybeAssign()}return finishNode(node,"YieldExpression")}function parseAwait(node){if(eat(_semi)||canInsertSemicolon()){unexpected()}node.all=eat(_star);node.argument=parseMaybeAssign(true);return finishNode(node,"AwaitExpression")}function parseComprehension(node,isGenerator){node.blocks=[];while(tokType===_for){var block=startNode();next();expect(_parenL);block.left=parseBindingAtom();checkLVal(block.left,true);expectContextual("of");block.right=parseExpression();expect(_parenR);node.blocks.push(finishNode(block,"ComprehensionBlock"))}node.filter=eat(_if)?parseParenExpression():null;node.body=parseExpression();expect(isGenerator?_parenR:_bracketR);node.generator=isGenerator;return finishNode(node,"ComprehensionExpression")}function getQualifiedJSXName(object){if(object.type==="JSXIdentifier"){return object.name}if(object.type==="JSXNamespacedName"){return object.namespace.name+":"+object.name.name}if(object.type==="JSXMemberExpression"){return getQualifiedJSXName(object.object)+"."+getQualifiedJSXName(object.property)}}function parseJSXIdentifier(){var node=startNode();if(tokType===_jsxName){node.name=tokVal}else if(tokType.keyword){node.name=tokType.keyword}else{unexpected()}next();return finishNode(node,"JSXIdentifier")}function parseJSXNamespacedName(){var start=storeCurrentPos();var name=parseJSXIdentifier();if(!eat(_colon))return name;var node=startNodeAt(start);node.namespace=name;node.name=parseJSXIdentifier();return finishNode(node,"JSXNamespacedName")}function parseJSXElementName(){var start=storeCurrentPos();var node=parseJSXNamespacedName();while(eat(_dot)){var newNode=startNodeAt(start);newNode.object=node;newNode.property=parseJSXIdentifier();node=finishNode(newNode,"JSXMemberExpression")}return node}function parseJSXAttributeValue(){switch(tokType){case _braceL:var node=parseJSXExpressionContainer();if(node.expression.type==="JSXEmptyExpression"){raise(node.start,"JSX attributes must only be assigned a non-empty "+"expression")}return node;case _jsxTagStart:return parseJSXElement();case _jsxText:case _string:return parseExprAtom();default:raise(tokStart,"JSX value should be either an expression or a quoted JSX text")}}function parseJSXEmptyExpression(){if(tokType!==_braceR){unexpected()}var tmp;tmp=tokStart;tokStart=lastEnd;lastEnd=tmp;tmp=tokStartLoc;tokStartLoc=lastEndLoc;lastEndLoc=tmp;return finishNode(startNode(),"JSXEmptyExpression")}function parseJSXExpressionContainer(){var node=startNode();next();node.expression=tokType===_braceR?parseJSXEmptyExpression():parseExpression();expect(_braceR);return finishNode(node,"JSXExpressionContainer")}function parseJSXAttribute(){var node=startNode();if(eat(_braceL)){expect(_ellipsis);node.argument=parseMaybeAssign();expect(_braceR);return finishNode(node,"JSXSpreadAttribute")}node.name=parseJSXNamespacedName();node.value=eat(_eq)?parseJSXAttributeValue():null;return finishNode(node,"JSXAttribute")}function parseJSXOpeningElementAt(start){var node=startNodeAt(start);node.attributes=[];node.name=parseJSXElementName();while(tokType!==_slash&&tokType!==_jsxTagEnd){node.attributes.push(parseJSXAttribute())}node.selfClosing=eat(_slash);expect(_jsxTagEnd);return finishNode(node,"JSXOpeningElement")}function parseJSXClosingElementAt(start){var node=startNodeAt(start);node.name=parseJSXElementName();expect(_jsxTagEnd);return finishNode(node,"JSXClosingElement")}function parseJSXElementAt(start){var node=startNodeAt(start);var children=[];var openingElement=parseJSXOpeningElementAt(start);var closingElement=null;if(!openingElement.selfClosing){contents:for(;;){switch(tokType){case _jsxTagStart:start=storeCurrentPos();next();if(eat(_slash)){closingElement=parseJSXClosingElementAt(start);break contents}children.push(parseJSXElementAt(start));break;case _jsxText:children.push(parseExprAtom());break;case _braceL:children.push(parseJSXExpressionContainer());break;default:unexpected()}}if(getQualifiedJSXName(closingElement.name)!==getQualifiedJSXName(openingElement.name)){raise(closingElement.start,"Expected corresponding JSX closing tag for <"+getQualifiedJSXName(openingElement.name)+">")}}node.openingElement=openingElement;node.closingElement=closingElement;node.children=children;return finishNode(node,"JSXElement")}function isRelational(op){return tokType===_relational&&tokVal===op}function expectRelational(op){if(isRelational(op)){next()}else{unexpected()}}function parseJSXElement(){var start=storeCurrentPos();next();return parseJSXElementAt(start)}function parseDeclareClass(node){next();parseInterfaceish(node,true);return finishNode(node,"DeclareClass")}function parseDeclareFunction(node){next();var id=node.id=parseIdent();var typeNode=startNode();var typeContainer=startNode();if(isRelational("<")){typeNode.typeParameters=parseTypeParameterDeclaration()}else{typeNode.typeParameters=null}expect(_parenL);var tmp=parseFunctionTypeParams();typeNode.params=tmp.params;typeNode.rest=tmp.rest;expect(_parenR);expect(_colon);typeNode.returnType=parseType();typeContainer.typeAnnotation=finishNode(typeNode,"FunctionTypeAnnotation");id.typeAnnotation=finishNode(typeContainer,"TypeAnnotation");finishNode(id,id.type);semicolon();return finishNode(node,"DeclareFunction")}function parseDeclare(node){if(tokType===_class){return parseDeclareClass(node)}else if(tokType===_function){return parseDeclareFunction(node)}else if(tokType===_var){return parseDeclareVariable(node)}else if(isContextual("module")){return parseDeclareModule(node)}else{unexpected()}}function parseDeclareVariable(node){next();node.id=parseTypeAnnotatableIdentifier();semicolon();return finishNode(node,"DeclareVariable")}function parseDeclareModule(node){next();if(tokType===_string){node.id=parseExprAtom()}else{node.id=parseIdent()}var bodyNode=node.body=startNode();var body=bodyNode.body=[];expect(_braceL);while(tokType!==_braceR){var node2=startNode();next();body.push(parseDeclare(node2))}expect(_braceR);finishNode(bodyNode,"BlockStatement");return finishNode(node,"DeclareModule")}function parseInterfaceish(node,allowStatic){node.id=parseIdent();if(isRelational("<")){node.typeParameters=parseTypeParameterDeclaration()}else{node.typeParameters=null}node.extends=[];if(eat(_extends)){do{node.extends.push(parseInterfaceExtends())}while(eat(_comma))}node.body=parseObjectType(allowStatic)}function parseInterfaceExtends(){var node=startNode();node.id=parseIdent();if(isRelational("<")){node.typeParameters=parseTypeParameterInstantiation()}else{node.typeParameters=null}return finishNode(node,"InterfaceExtends")}function parseInterface(node){parseInterfaceish(node,false);return finishNode(node,"InterfaceDeclaration")}function parseTypeAlias(node){node.id=parseIdent();if(isRelational("<")){node.typeParameters=parseTypeParameterDeclaration()}else{node.typeParameters=null}expect(_eq);node.right=parseType();semicolon();return finishNode(node,"TypeAlias")}function parseTypeParameterDeclaration(){var node=startNode();node.params=[];expectRelational("<");while(!isRelational(">")){node.params.push(parseIdent());if(!isRelational(">")){expect(_comma)}}expectRelational(">");return finishNode(node,"TypeParameterDeclaration")}function parseTypeParameterInstantiation(){var node=startNode(),oldInType=inType;node.params=[];inType=true;expectRelational("<");while(!isRelational(">")){node.params.push(parseType());if(!isRelational(">")){expect(_comma)}}expectRelational(">");inType=oldInType;return finishNode(node,"TypeParameterInstantiation")}function parseObjectPropertyKey(){return tokType===_num||tokType===_string?parseExprAtom():parseIdent(true)}function parseObjectTypeIndexer(node,isStatic){node.static=isStatic;expect(_bracketL);node.id=parseObjectPropertyKey();expect(_colon);node.key=parseType();expect(_bracketR);expect(_colon);node.value=parseType();return finishNode(node,"ObjectTypeIndexer")}function parseObjectTypeMethodish(node){node.params=[];node.rest=null;node.typeParameters=null;if(isRelational("<")){node.typeParameters=parseTypeParameterDeclaration()}expect(_parenL);while(tokType===_name){node.params.push(parseFunctionTypeParam());if(tokType!==_parenR){expect(_comma)}}if(eat(_ellipsis)){node.rest=parseFunctionTypeParam()}expect(_parenR);expect(_colon);node.returnType=parseType();return finishNode(node,"FunctionTypeAnnotation")}function parseObjectTypeMethod(start,isStatic,key){var node=startNodeAt(start);node.value=parseObjectTypeMethodish(startNodeAt(start));node.static=isStatic;node.key=key;node.optional=false;return finishNode(node,"ObjectTypeProperty")}function parseObjectTypeCallProperty(node,isStatic){var valueNode=startNode();node.static=isStatic;node.value=parseObjectTypeMethodish(valueNode);return finishNode(node,"ObjectTypeCallProperty")}function parseObjectType(allowStatic){var nodeStart=startNode();var node;var optional=false;var property;var propertyKey;var propertyTypeAnnotation;var token;var isStatic;nodeStart.callProperties=[];nodeStart.properties=[];nodeStart.indexers=[];expect(_braceL);while(tokType!==_braceR){var start=storeCurrentPos();node=startNode();if(allowStatic&&isContextual("static")){next();isStatic=true}if(tokType===_bracketL){nodeStart.indexers.push(parseObjectTypeIndexer(node,isStatic))}else if(tokType===_parenL||isRelational("<")){nodeStart.callProperties.push(parseObjectTypeCallProperty(node,allowStatic))}else{if(isStatic&&tokType===_colon){propertyKey=parseIdent()}else{propertyKey=parseObjectPropertyKey()}if(isRelational("<")||tokType===_parenL){nodeStart.properties.push(parseObjectTypeMethod(start,isStatic,propertyKey))}else{if(eat(_question)){optional=true}expect(_colon);node.key=propertyKey;node.value=parseType();node.optional=optional;node.static=isStatic;nodeStart.properties.push(finishNode(node,"ObjectTypeProperty"))}}if(!eat(_semi)&&tokType!==_braceR){unexpected()}}expect(_braceR);return finishNode(nodeStart,"ObjectTypeAnnotation")}function parseGenericType(start,id){var node=startNodeAt(start);node.typeParameters=null;node.id=id;while(eat(_dot)){var node2=startNodeAt(start);node2.qualification=node.id;node2.id=parseIdent();node.id=finishNode(node2,"QualifiedTypeIdentifier")}if(isRelational("<")){node.typeParameters=parseTypeParameterInstantiation()}return finishNode(node,"GenericTypeAnnotation")}function parseVoidType(){var node=startNode();expect(keywordTypes["void"]);return finishNode(node,"VoidTypeAnnotation")}function parseTypeofType(){var node=startNode();expect(keywordTypes["typeof"]);node.argument=parsePrimaryType();return finishNode(node,"TypeofTypeAnnotation")}function parseTupleType(){var node=startNode();node.types=[];expect(_bracketL);while(tokPos<inputLen&&tokType!==_bracketR){node.types.push(parseType());if(tokType===_bracketR)break;expect(_comma)}expect(_bracketR);return finishNode(node,"TupleTypeAnnotation")}function parseFunctionTypeParam(){var optional=false;var node=startNode();node.name=parseIdent();if(eat(_question)){optional=true}expect(_colon);node.optional=optional;node.typeAnnotation=parseType();return finishNode(node,"FunctionTypeParam")}function parseFunctionTypeParams(){var ret={params:[],rest:null};while(tokType===_name){ret.params.push(parseFunctionTypeParam());if(tokType!==_parenR){expect(_comma)}}if(eat(_ellipsis)){ret.rest=parseFunctionTypeParam()}return ret}function identToTypeAnnotation(start,node,id){switch(id.name){case"any":return finishNode(node,"AnyTypeAnnotation");case"bool":case"boolean":return finishNode(node,"BooleanTypeAnnotation");case"number":return finishNode(node,"NumberTypeAnnotation");case"string":return finishNode(node,"StringTypeAnnotation");default:return parseGenericType(start,id)}}function parsePrimaryType(){var typeIdentifier=null;var params=null;var returnType=null;var start=storeCurrentPos();var node=startNode();var rest=null;var tmp;var typeParameters;var token;var type;var isGroupedType=false;switch(tokType){case _name:return identToTypeAnnotation(start,node,parseIdent());case _braceL:return parseObjectType();case _bracketL:return parseTupleType();case _relational:if(tokVal==="<"){node.typeParameters=parseTypeParameterDeclaration();expect(_parenL);tmp=parseFunctionTypeParams();node.params=tmp.params;node.rest=tmp.rest;expect(_parenR);expect(_arrow);node.returnType=parseType();return finishNode(node,"FunctionTypeAnnotation")}case _parenL:next();var tmpId;if(tokType!==_parenR&&tokType!==_ellipsis){if(tokType===_name){}else{isGroupedType=true}}if(isGroupedType){if(tmpId&&_parenR){type=tmpId}else{type=parseType();expect(_parenR)}if(eat(_arrow)){raise(node,"Unexpected token =>. It looks like "+"you are trying to write a function type, but you ended up "+"writing a grouped type followed by an =>, which is a syntax "+"error. Remember, function type parameters are named so function "+"types look like (name1: type1, name2: type2) => returnType. You "+"probably wrote (type1) => returnType")}return type}tmp=parseFunctionTypeParams();node.params=tmp.params;node.rest=tmp.rest;expect(_parenR);expect(_arrow);node.returnType=parseType();node.typeParameters=null;return finishNode(node,"FunctionTypeAnnotation");case _string:node.value=tokVal;node.raw=input.slice(tokStart,tokEnd);next();return finishNode(node,"StringLiteralTypeAnnotation");default:if(tokType.keyword){switch(tokType.keyword){case"void":return parseVoidType();case"typeof":return parseTypeofType()}}}unexpected()}function parsePostfixType(){var node=startNode();var type=node.elementType=parsePrimaryType();if(tokType===_bracketL){expect(_bracketL);expect(_bracketR);return finishNode(node,"ArrayTypeAnnotation")}return type}function parsePrefixType(){var node=startNode();if(eat(_question)){node.typeAnnotation=parsePrefixType();return finishNode(node,"NullableTypeAnnotation")}return parsePostfixType()}function parseIntersectionType(){var node=startNode();var type=parsePrefixType();node.types=[type];while(eat(_bitwiseAND)){node.types.push(parsePrefixType())}return node.types.length===1?type:finishNode(node,"IntersectionTypeAnnotation")}function parseUnionType(){var node=startNode();var type=parseIntersectionType();node.types=[type];while(eat(_bitwiseOR)){node.types.push(parseIntersectionType())}return node.types.length===1?type:finishNode(node,"UnionTypeAnnotation")}function parseType(){var oldInType=inType;inType=true;var type=parseUnionType();inType=oldInType;return type}function parseTypeAnnotation(){var node=startNode();var oldInType=inType;inType=true;expect(_colon);node.typeAnnotation=parseType();inType=oldInType;return finishNode(node,"TypeAnnotation")}function parseTypeAnnotatableIdentifier(requireTypeAnnotation,canBeOptionalParam){var node=startNode();var ident=parseIdent();var isOptionalParam=false;if(canBeOptionalParam&&eat(_question)){expect(_question);isOptionalParam=true}if(requireTypeAnnotation||tokType===_colon){ident.typeAnnotation=parseTypeAnnotation();finishNode(ident,ident.type)}if(isOptionalParam){ident.optional=true;finishNode(ident,ident.type)}return ident}})},{}],126:[function(require,module,exports){var types=require("../lib/types");var Type=types.Type;var def=Type.def;var or=Type.or;var builtin=types.builtInTypes;var isString=builtin.string;var isNumber=builtin.number;var isBoolean=builtin.boolean;var isRegExp=builtin.RegExp;var shared=require("../lib/shared");var defaults=shared.defaults;var geq=shared.geq;def("Printable").field("loc",or(def("SourceLocation"),null),defaults["null"],true);def("Node").bases("Printable").field("type",isString).field("comments",or([def("Comment")],null),defaults["null"],true);def("SourceLocation").build("start","end","source").field("start",def("Position")).field("end",def("Position")).field("source",or(isString,null),defaults["null"]);def("Position").build("line","column").field("line",geq(1)).field("column",geq(0));def("Program").bases("Node").build("body").field("body",[def("Statement")]);def("Function").bases("Node").field("id",or(def("Identifier"),null),defaults["null"]).field("params",[def("Pattern")]).field("body",or(def("BlockStatement"),def("Expression")));def("Statement").bases("Node");def("EmptyStatement").bases("Statement").build();def("BlockStatement").bases("Statement").build("body").field("body",[def("Statement")]);def("ExpressionStatement").bases("Statement").build("expression").field("expression",def("Expression"));def("IfStatement").bases("Statement").build("test","consequent","alternate").field("test",def("Expression")).field("consequent",def("Statement")).field("alternate",or(def("Statement"),null),defaults["null"]);def("LabeledStatement").bases("Statement").build("label","body").field("label",def("Identifier")).field("body",def("Statement"));def("BreakStatement").bases("Statement").build("label").field("label",or(def("Identifier"),null),defaults["null"]);def("ContinueStatement").bases("Statement").build("label").field("label",or(def("Identifier"),null),defaults["null"]);def("WithStatement").bases("Statement").build("object","body").field("object",def("Expression")).field("body",def("Statement"));def("SwitchStatement").bases("Statement").build("discriminant","cases","lexical").field("discriminant",def("Expression")).field("cases",[def("SwitchCase")]).field("lexical",isBoolean,defaults["false"]);def("ReturnStatement").bases("Statement").build("argument").field("argument",or(def("Expression"),null));def("ThrowStatement").bases("Statement").build("argument").field("argument",def("Expression"));def("TryStatement").bases("Statement").build("block","handler","finalizer").field("block",def("BlockStatement")).field("handler",or(def("CatchClause"),null),function(){return this.handlers&&this.handlers[0]||null}).field("handlers",[def("CatchClause")],function(){return this.handler?[this.handler]:[]},true).field("guardedHandlers",[def("CatchClause")],defaults.emptyArray).field("finalizer",or(def("BlockStatement"),null),defaults["null"]);def("CatchClause").bases("Node").build("param","guard","body").field("param",def("Pattern")).field("guard",or(def("Expression"),null),defaults["null"]).field("body",def("BlockStatement"));def("WhileStatement").bases("Statement").build("test","body").field("test",def("Expression")).field("body",def("Statement"));def("DoWhileStatement").bases("Statement").build("body","test").field("body",def("Statement")).field("test",def("Expression"));def("ForStatement").bases("Statement").build("init","test","update","body").field("init",or(def("VariableDeclaration"),def("Expression"),null)).field("test",or(def("Expression"),null)).field("update",or(def("Expression"),null)).field("body",def("Statement"));def("ForInStatement").bases("Statement").build("left","right","body","each").field("left",or(def("VariableDeclaration"),def("Expression"))).field("right",def("Expression")).field("body",def("Statement")).field("each",isBoolean);def("DebuggerStatement").bases("Statement").build();def("Declaration").bases("Statement");def("FunctionDeclaration").bases("Function","Declaration").build("id","params","body").field("id",def("Identifier"));def("FunctionExpression").bases("Function","Expression").build("id","params","body");def("VariableDeclaration").bases("Declaration").build("kind","declarations").field("kind",or("var","let","const")).field("declarations",[or(def("VariableDeclarator"),def("Identifier"))]);def("VariableDeclarator").bases("Node").build("id","init").field("id",def("Pattern")).field("init",or(def("Expression"),null));def("Expression").bases("Node","Pattern");def("ThisExpression").bases("Expression").build();def("ArrayExpression").bases("Expression").build("elements").field("elements",[or(def("Expression"),null)]);def("ObjectExpression").bases("Expression").build("properties").field("properties",[def("Property")]);def("Property").bases("Node").build("kind","key","value").field("kind",or("init","get","set")).field("key",or(def("Literal"),def("Identifier"))).field("value",or(def("Expression"),def("Pattern")));def("SequenceExpression").bases("Expression").build("expressions").field("expressions",[def("Expression")]);var UnaryOperator=or("-","+","!","~","typeof","void","delete");def("UnaryExpression").bases("Expression").build("operator","argument","prefix").field("operator",UnaryOperator).field("argument",def("Expression")).field("prefix",isBoolean,defaults["true"]);var BinaryOperator=or("==","!=","===","!==","<","<=",">",">=","<<",">>",">>>","+","-","*","/","%","&","|","^","in","instanceof","..");def("BinaryExpression").bases("Expression").build("operator","left","right").field("operator",BinaryOperator).field("left",def("Expression")).field("right",def("Expression"));var AssignmentOperator=or("=","+=","-=","*=","/=","%=","<<=",">>=",">>>=","|=","^=","&=");def("AssignmentExpression").bases("Expression").build("operator","left","right").field("operator",AssignmentOperator).field("left",def("Pattern")).field("right",def("Expression"));var UpdateOperator=or("++","--");def("UpdateExpression").bases("Expression").build("operator","argument","prefix").field("operator",UpdateOperator).field("argument",def("Expression")).field("prefix",isBoolean); var LogicalOperator=or("||","&&");def("LogicalExpression").bases("Expression").build("operator","left","right").field("operator",LogicalOperator).field("left",def("Expression")).field("right",def("Expression"));def("ConditionalExpression").bases("Expression").build("test","consequent","alternate").field("test",def("Expression")).field("consequent",def("Expression")).field("alternate",def("Expression"));def("NewExpression").bases("Expression").build("callee","arguments").field("callee",def("Expression")).field("arguments",[def("Expression")]);def("CallExpression").bases("Expression").build("callee","arguments").field("callee",def("Expression")).field("arguments",[def("Expression")]);def("MemberExpression").bases("Expression").build("object","property","computed").field("object",def("Expression")).field("property",or(def("Identifier"),def("Expression"))).field("computed",isBoolean);def("Pattern").bases("Node");def("ObjectPattern").bases("Pattern").build("properties").field("properties",[or(def("PropertyPattern"),def("Property"))]);def("PropertyPattern").bases("Pattern").build("key","pattern").field("key",or(def("Literal"),def("Identifier"))).field("pattern",def("Pattern"));def("ArrayPattern").bases("Pattern").build("elements").field("elements",[or(def("Pattern"),null)]);def("SwitchCase").bases("Node").build("test","consequent").field("test",or(def("Expression"),null)).field("consequent",[def("Statement")]);def("Identifier").bases("Node","Expression","Pattern").build("name").field("name",isString);def("Literal").bases("Node","Expression").build("value").field("value",or(isString,isBoolean,null,isNumber,isRegExp));def("Comment").bases("Printable").field("value",isString).field("leading",isBoolean,defaults["true"]).field("trailing",isBoolean,defaults["false"]);def("Block").bases("Comment").build("value","leading","trailing");def("Line").bases("Comment").build("value","leading","trailing")},{"../lib/shared":137,"../lib/types":138}],127:[function(require,module,exports){require("./core");var types=require("../lib/types");var def=types.Type.def;var or=types.Type.or;var builtin=types.builtInTypes;var isString=builtin.string;var isBoolean=builtin.boolean;def("XMLDefaultDeclaration").bases("Declaration").field("namespace",def("Expression"));def("XMLAnyName").bases("Expression");def("XMLQualifiedIdentifier").bases("Expression").field("left",or(def("Identifier"),def("XMLAnyName"))).field("right",or(def("Identifier"),def("Expression"))).field("computed",isBoolean);def("XMLFunctionQualifiedIdentifier").bases("Expression").field("right",or(def("Identifier"),def("Expression"))).field("computed",isBoolean);def("XMLAttributeSelector").bases("Expression").field("attribute",def("Expression"));def("XMLFilterExpression").bases("Expression").field("left",def("Expression")).field("right",def("Expression"));def("XMLElement").bases("XML","Expression").field("contents",[def("XML")]);def("XMLList").bases("XML","Expression").field("contents",[def("XML")]);def("XML").bases("Node");def("XMLEscape").bases("XML").field("expression",def("Expression"));def("XMLText").bases("XML").field("text",isString);def("XMLStartTag").bases("XML").field("contents",[def("XML")]);def("XMLEndTag").bases("XML").field("contents",[def("XML")]);def("XMLPointTag").bases("XML").field("contents",[def("XML")]);def("XMLName").bases("XML").field("contents",or(isString,[def("XML")]));def("XMLAttribute").bases("XML").field("value",isString);def("XMLCdata").bases("XML").field("contents",isString);def("XMLComment").bases("XML").field("contents",isString);def("XMLProcessingInstruction").bases("XML").field("target",isString).field("contents",or(isString,null))},{"../lib/types":138,"./core":126}],128:[function(require,module,exports){require("./core");var types=require("../lib/types");var def=types.Type.def;var or=types.Type.or;var builtin=types.builtInTypes;var isBoolean=builtin.boolean;var isObject=builtin.object;var isString=builtin.string;var defaults=require("../lib/shared").defaults;def("Function").field("generator",isBoolean,defaults["false"]).field("expression",isBoolean,defaults["false"]).field("defaults",[or(def("Expression"),null)],defaults.emptyArray).field("rest",or(def("Identifier"),null),defaults["null"]);def("FunctionDeclaration").build("id","params","body","generator","expression");def("FunctionExpression").build("id","params","body","generator","expression");def("ArrowFunctionExpression").bases("Function","Expression").build("params","body","expression").field("id",null,defaults["null"]).field("generator",false);def("YieldExpression").bases("Expression").build("argument","delegate").field("argument",or(def("Expression"),null)).field("delegate",isBoolean,defaults["false"]);def("GeneratorExpression").bases("Expression").build("body","blocks","filter").field("body",def("Expression")).field("blocks",[def("ComprehensionBlock")]).field("filter",or(def("Expression"),null));def("ComprehensionExpression").bases("Expression").build("body","blocks","filter").field("body",def("Expression")).field("blocks",[def("ComprehensionBlock")]).field("filter",or(def("Expression"),null));def("ComprehensionBlock").bases("Node").build("left","right","each").field("left",def("Pattern")).field("right",def("Expression")).field("each",isBoolean);def("ModuleSpecifier").bases("Literal").build("value").field("value",isString);def("Property").field("key",or(def("Literal"),def("Identifier"),def("Expression"))).field("method",isBoolean,defaults["false"]).field("shorthand",isBoolean,defaults["false"]).field("computed",isBoolean,defaults["false"]);def("PropertyPattern").field("key",or(def("Literal"),def("Identifier"),def("Expression"))).field("computed",isBoolean,defaults["false"]);def("MethodDefinition").bases("Declaration").build("kind","key","value").field("kind",or("init","get","set","")).field("key",or(def("Literal"),def("Identifier"),def("Expression"))).field("value",def("Function")).field("computed",isBoolean,defaults["false"]);def("SpreadElement").bases("Node").build("argument").field("argument",def("Expression"));def("ArrayExpression").field("elements",[or(def("Expression"),def("SpreadElement"),null)]);def("NewExpression").field("arguments",[or(def("Expression"),def("SpreadElement"))]);def("CallExpression").field("arguments",[or(def("Expression"),def("SpreadElement"))]);def("SpreadElementPattern").bases("Pattern").build("argument").field("argument",def("Pattern"));def("ArrayPattern").field("elements",[or(def("Pattern"),null,def("SpreadElement"))]);var ClassBodyElement=or(def("MethodDefinition"),def("VariableDeclarator"),def("ClassPropertyDefinition"),def("ClassProperty"));def("ClassProperty").bases("Declaration").build("key").field("key",or(def("Literal"),def("Identifier"),def("Expression"))).field("computed",isBoolean,defaults["false"]);def("ClassPropertyDefinition").bases("Declaration").build("definition").field("definition",ClassBodyElement);def("ClassBody").bases("Declaration").build("body").field("body",[ClassBodyElement]);def("ClassDeclaration").bases("Declaration").build("id","body","superClass").field("id",def("Identifier")).field("body",def("ClassBody")).field("superClass",or(def("Expression"),null),defaults["null"]);def("ClassExpression").bases("Expression").build("id","body","superClass").field("id",or(def("Identifier"),null),defaults["null"]).field("body",def("ClassBody")).field("superClass",or(def("Expression"),null),defaults["null"]).field("implements",[def("ClassImplements")],defaults.emptyArray);def("ClassImplements").bases("Node").build("id").field("id",def("Identifier")).field("superClass",or(def("Expression"),null),defaults["null"]);def("Specifier").bases("Node");def("NamedSpecifier").bases("Specifier").field("id",def("Identifier")).field("name",or(def("Identifier"),null),defaults["null"]);def("ExportSpecifier").bases("NamedSpecifier").build("id","name");def("ExportBatchSpecifier").bases("Specifier").build();def("ImportSpecifier").bases("NamedSpecifier").build("id","name");def("ImportNamespaceSpecifier").bases("Specifier").build("id").field("id",def("Identifier"));def("ImportDefaultSpecifier").bases("Specifier").build("id").field("id",def("Identifier"));def("ExportDeclaration").bases("Declaration").build("default","declaration","specifiers","source").field("default",isBoolean).field("declaration",or(def("Declaration"),def("Expression"),null)).field("specifiers",[or(def("ExportSpecifier"),def("ExportBatchSpecifier"))],defaults.emptyArray).field("source",or(def("ModuleSpecifier"),null),defaults["null"]);def("ImportDeclaration").bases("Declaration").build("specifiers","source").field("specifiers",[or(def("ImportSpecifier"),def("ImportNamespaceSpecifier"),def("ImportDefaultSpecifier"))],defaults.emptyArray).field("source",def("ModuleSpecifier"));def("TaggedTemplateExpression").bases("Expression").field("tag",def("Expression")).field("quasi",def("TemplateLiteral"));def("TemplateLiteral").bases("Expression").build("quasis","expressions").field("quasis",[def("TemplateElement")]).field("expressions",[def("Expression")]);def("TemplateElement").bases("Node").build("value","tail").field("value",{cooked:isString,raw:isString}).field("tail",isBoolean)},{"../lib/shared":137,"../lib/types":138,"./core":126}],129:[function(require,module,exports){require("./core");var types=require("../lib/types");var def=types.Type.def;var or=types.Type.or;var builtin=types.builtInTypes;var isBoolean=builtin.boolean;var defaults=require("../lib/shared").defaults;def("Function").field("async",isBoolean,defaults["false"]);def("SpreadProperty").bases("Node").build("argument").field("argument",def("Expression"));def("ObjectExpression").field("properties",[or(def("Property"),def("SpreadProperty"))]);def("SpreadPropertyPattern").bases("Pattern").build("argument").field("argument",def("Pattern"));def("ObjectPattern").field("properties",[or(def("PropertyPattern"),def("SpreadPropertyPattern"),def("Property"),def("SpreadProperty"))]);def("AwaitExpression").bases("Expression").build("argument","all").field("argument",or(def("Expression"),null)).field("all",isBoolean,defaults["false"])},{"../lib/shared":137,"../lib/types":138,"./core":126}],130:[function(require,module,exports){require("./core");var types=require("../lib/types");var def=types.Type.def;var or=types.Type.or;var builtin=types.builtInTypes;var isString=builtin.string;var isBoolean=builtin.boolean;var defaults=require("../lib/shared").defaults;def("XJSAttribute").bases("Node").build("name","value").field("name",or(def("XJSIdentifier"),def("XJSNamespacedName"))).field("value",or(def("Literal"),def("XJSExpressionContainer"),null),defaults["null"]);def("XJSIdentifier").bases("Node").build("name").field("name",isString);def("XJSNamespacedName").bases("Node").build("namespace","name").field("namespace",def("XJSIdentifier")).field("name",def("XJSIdentifier"));def("XJSMemberExpression").bases("MemberExpression").build("object","property").field("object",or(def("XJSIdentifier"),def("XJSMemberExpression"))).field("property",def("XJSIdentifier")).field("computed",isBoolean,defaults.false);var XJSElementName=or(def("XJSIdentifier"),def("XJSNamespacedName"),def("XJSMemberExpression"));def("XJSSpreadAttribute").bases("Node").build("argument").field("argument",def("Expression"));var XJSAttributes=[or(def("XJSAttribute"),def("XJSSpreadAttribute"))];def("XJSExpressionContainer").bases("Expression").build("expression").field("expression",def("Expression"));def("XJSElement").bases("Expression").build("openingElement","closingElement","children").field("openingElement",def("XJSOpeningElement")).field("closingElement",or(def("XJSClosingElement"),null),defaults["null"]).field("children",[or(def("XJSElement"),def("XJSExpressionContainer"),def("XJSText"),def("Literal"))],defaults.emptyArray).field("name",XJSElementName,function(){return this.openingElement.name}).field("selfClosing",isBoolean,function(){return this.openingElement.selfClosing}).field("attributes",XJSAttributes,function(){return this.openingElement.attributes});def("XJSOpeningElement").bases("Node").build("name","attributes","selfClosing").field("name",XJSElementName).field("attributes",XJSAttributes,defaults.emptyArray).field("selfClosing",isBoolean,defaults["false"]);def("XJSClosingElement").bases("Node").build("name").field("name",XJSElementName);def("XJSText").bases("Literal").build("value").field("value",isString);def("XJSEmptyExpression").bases("Expression").build();def("Type").bases("Node");def("AnyTypeAnnotation").bases("Type");def("VoidTypeAnnotation").bases("Type");def("NumberTypeAnnotation").bases("Type");def("StringTypeAnnotation").bases("Type");def("StringLiteralTypeAnnotation").bases("Type").build("value","raw").field("value",isString).field("raw",isString);def("BooleanTypeAnnotation").bases("Type");def("TypeAnnotation").bases("Node").build("typeAnnotation").field("typeAnnotation",def("Type"));def("NullableTypeAnnotation").bases("Type").build("typeAnnotation").field("typeAnnotation",def("Type"));def("FunctionTypeAnnotation").bases("Type").build("params","returnType","rest","typeParameters").field("params",[def("FunctionTypeParam")]).field("returnType",def("Type")).field("rest",or(def("FunctionTypeParam"),null)).field("typeParameters",or(def("TypeParameterDeclaration"),null));def("FunctionTypeParam").bases("Node").build("name","typeAnnotation","optional").field("name",def("Identifier")).field("typeAnnotation",def("Type")).field("optional",isBoolean);def("ArrayTypeAnnotation").bases("Type").build("elementType").field("elementType",def("Type"));def("ObjectTypeAnnotation").bases("Type").build("properties").field("properties",[def("ObjectTypeProperty")]).field("indexers",[def("ObjectTypeIndexer")],defaults.emptyArray).field("callProperties",[def("ObjectTypeCallProperty")],defaults.emptyArray);def("ObjectTypeProperty").bases("Node").build("key","value","optional").field("key",or(def("Literal"),def("Identifier"))).field("value",def("Type")).field("optional",isBoolean);def("ObjectTypeIndexer").bases("Node").build("id","key","value").field("id",def("Identifier")).field("key",def("Type")).field("value",def("Type"));def("ObjectTypeCallProperty").bases("Node").build("value").field("value",def("FunctionTypeAnnotation")).field("static",isBoolean,false);def("QualifiedTypeIdentifier").bases("Node").build("qualification","id").field("qualification",or(def("Identifier"),def("QualifiedTypeIdentifier"))).field("id",def("Identifier"));def("GenericTypeAnnotation").bases("Type").build("id","typeParameters").field("id",or(def("Identifier"),def("QualifiedTypeIdentifier"))).field("typeParameters",or(def("TypeParameterInstantiation"),null));def("MemberTypeAnnotation").bases("Type").build("object","property").field("object",def("Identifier")).field("property",or(def("MemberTypeAnnotation"),def("GenericTypeAnnotation")));def("UnionTypeAnnotation").bases("Type").build("types").field("types",[def("Type")]);def("IntersectionTypeAnnotation").bases("Type").build("types").field("types",[def("Type")]);def("TypeofTypeAnnotation").bases("Type").build("argument").field("argument",def("Type"));def("Identifier").field("typeAnnotation",or(def("TypeAnnotation"),null),defaults["null"]);def("TypeParameterDeclaration").bases("Node").build("params").field("params",[def("Identifier")]);def("TypeParameterInstantiation").bases("Node").build("params").field("params",[def("Type")]);def("Function").field("returnType",or(def("TypeAnnotation"),null),defaults["null"]).field("typeParameters",or(def("TypeParameterDeclaration"),null),defaults["null"]);def("ClassProperty").build("key","typeAnnotation").field("typeAnnotation",def("TypeAnnotation")).field("static",isBoolean,false);def("ClassImplements").field("typeParameters",or(def("TypeParameterInstantiation"),null),defaults["null"]);def("InterfaceDeclaration").bases("Statement").build("id","body","extends").field("id",def("Identifier")).field("typeParameters",or(def("TypeParameterDeclaration"),null),defaults["null"]).field("body",def("ObjectTypeAnnotation")).field("extends",[def("InterfaceExtends")]);def("InterfaceExtends").bases("Node").build("id").field("id",def("Identifier")).field("typeParameters",or(def("TypeParameterInstantiation"),null));def("TypeAlias").bases("Statement").build("id","typeParameters","right").field("id",def("Identifier")).field("typeParameters",or(def("TypeParameterDeclaration"),null)).field("right",def("Type"));def("TypeCastExpression").bases("Expression").build("expression","typeAnnotation").field("expression",def("Expression")).field("typeAnnotation",def("TypeAnnotation"));def("TupleTypeAnnotation").bases("Type").build("types").field("types",[def("Type")]);def("DeclareVariable").bases("Statement").build("id").field("id",def("Identifier"));def("DeclareFunction").bases("Statement").build("id").field("id",def("Identifier"));def("DeclareClass").bases("InterfaceDeclaration").build("id");def("DeclareModule").bases("Statement").build("id","body").field("id",or(def("Identifier"),def("Literal"))).field("body",def("BlockStatement"))},{"../lib/shared":137,"../lib/types":138,"./core":126}],131:[function(require,module,exports){require("./core");var types=require("../lib/types");var def=types.Type.def;var or=types.Type.or;var geq=require("../lib/shared").geq;def("ForOfStatement").bases("Statement").build("left","right","body").field("left",or(def("VariableDeclaration"),def("Expression"))).field("right",def("Expression")).field("body",def("Statement"));def("LetStatement").bases("Statement").build("head","body").field("head",[def("VariableDeclarator")]).field("body",def("Statement"));def("LetExpression").bases("Expression").build("head","body").field("head",[def("VariableDeclarator")]).field("body",def("Expression"));def("GraphExpression").bases("Expression").build("index","expression").field("index",geq(0)).field("expression",def("Literal"));def("GraphIndexExpression").bases("Expression").build("index").field("index",geq(0))},{"../lib/shared":137,"../lib/types":138,"./core":126}],132:[function(require,module,exports){var assert=require("assert");var types=require("../main");var getFieldNames=types.getFieldNames;var getFieldValue=types.getFieldValue;var isArray=types.builtInTypes.array;var isObject=types.builtInTypes.object;var isDate=types.builtInTypes.Date;var isRegExp=types.builtInTypes.RegExp;var hasOwn=Object.prototype.hasOwnProperty;function astNodesAreEquivalent(a,b,problemPath){if(isArray.check(problemPath)){problemPath.length=0}else{problemPath=null}return areEquivalent(a,b,problemPath)}astNodesAreEquivalent.assert=function(a,b){var problemPath=[];if(!astNodesAreEquivalent(a,b,problemPath)){if(problemPath.length===0){assert.strictEqual(a,b)}else{assert.ok(false,"Nodes differ in the following path: "+problemPath.map(subscriptForProperty).join(""))}}};function subscriptForProperty(property){if(/[_$a-z][_$a-z0-9]*/i.test(property)){return"."+property}return"["+JSON.stringify(property)+"]"}function areEquivalent(a,b,problemPath){if(a===b){return true}if(isArray.check(a)){return arraysAreEquivalent(a,b,problemPath)}if(isObject.check(a)){return objectsAreEquivalent(a,b,problemPath)}if(isDate.check(a)){return isDate.check(b)&&+a===+b}if(isRegExp.check(a)){return isRegExp.check(b)&&(a.source===b.source&&a.global===b.global&&a.multiline===b.multiline&&a.ignoreCase===b.ignoreCase)}return a==b}function arraysAreEquivalent(a,b,problemPath){isArray.assert(a);var aLength=a.length;if(!isArray.check(b)||b.length!==aLength){if(problemPath){problemPath.push("length")}return false}for(var i=0;i<aLength;++i){if(problemPath){problemPath.push(i)}if(i in a!==i in b){return false}if(!areEquivalent(a[i],b[i],problemPath)){return false}if(problemPath){assert.strictEqual(problemPath.pop(),i)}}return true}function objectsAreEquivalent(a,b,problemPath){isObject.assert(a);if(!isObject.check(b)){return false}if(a.type!==b.type){if(problemPath){problemPath.push("type")}return false}var aNames=getFieldNames(a);var aNameCount=aNames.length;var bNames=getFieldNames(b);var bNameCount=bNames.length;if(aNameCount===bNameCount){for(var i=0;i<aNameCount;++i){var name=aNames[i];var aChild=getFieldValue(a,name);var bChild=getFieldValue(b,name);if(problemPath){problemPath.push(name)}if(!areEquivalent(aChild,bChild,problemPath)){return false}if(problemPath){assert.strictEqual(problemPath.pop(),name)}}return true}if(!problemPath){return false}var seenNames=Object.create(null);for(i=0;i<aNameCount;++i){seenNames[aNames[i]]=true}for(i=0;i<bNameCount;++i){name=bNames[i];if(!hasOwn.call(seenNames,name)){problemPath.push(name);return false}delete seenNames[name]}for(name in seenNames){problemPath.push(name);break}return false}module.exports=astNodesAreEquivalent},{"../main":139,assert:141}],133:[function(require,module,exports){var assert=require("assert");var types=require("./types");var n=types.namedTypes;var b=types.builders;var isNumber=types.builtInTypes.number;var isArray=types.builtInTypes.array;var Path=require("./path");var Scope=require("./scope");function NodePath(value,parentPath,name){assert.ok(this instanceof NodePath);Path.call(this,value,parentPath,name)}require("util").inherits(NodePath,Path);var NPp=NodePath.prototype;Object.defineProperties(NPp,{node:{get:function(){Object.defineProperty(this,"node",{configurable:true,value:this._computeNode()});return this.node}},parent:{get:function(){Object.defineProperty(this,"parent",{configurable:true,value:this._computeParent()});return this.parent}},scope:{get:function(){Object.defineProperty(this,"scope",{configurable:true,value:this._computeScope()});return this.scope}}});NPp.replace=function(){delete this.node;delete this.parent;delete this.scope;return Path.prototype.replace.apply(this,arguments)};NPp.prune=function(){var remainingNodePath=this.parent;this.replace();return cleanUpNodesAfterPrune(remainingNodePath)};NPp._computeNode=function(){var value=this.value;if(n.Node.check(value)){return value}var pp=this.parentPath;return pp&&pp.node||null};NPp._computeParent=function(){var value=this.value;var pp=this.parentPath;if(!n.Node.check(value)){while(pp&&!n.Node.check(pp.value)){pp=pp.parentPath}if(pp){pp=pp.parentPath}}while(pp&&!n.Node.check(pp.value)){pp=pp.parentPath}return pp||null};NPp._computeScope=function(){var value=this.value;var pp=this.parentPath;var scope=pp&&pp.scope;if(n.Node.check(value)&&Scope.isEstablishedBy(value)){scope=new Scope(this,scope)}return scope||null};NPp.getValueProperty=function(name){return types.getFieldValue(this.value,name)};NPp.needsParens=function(assumeExpressionContext){var pp=this.parentPath;if(!pp){return false}var node=this.value;if(!n.Expression.check(node)){return false}if(node.type==="Identifier"){return false}while(!n.Node.check(pp.value)){pp=pp.parentPath;if(!pp){return false}}var parent=pp.value;switch(node.type){case"UnaryExpression":case"SpreadElement":case"SpreadProperty":return parent.type==="MemberExpression"&&this.name==="object"&&parent.object===node;case"BinaryExpression":case"LogicalExpression":switch(parent.type){case"CallExpression":return this.name==="callee"&&parent.callee===node;case"UnaryExpression":case"SpreadElement":case"SpreadProperty":return true;case"MemberExpression":return this.name==="object"&&parent.object===node;case"BinaryExpression":case"LogicalExpression":var po=parent.operator;var pp=PRECEDENCE[po];var no=node.operator;var np=PRECEDENCE[no];if(pp>np){return true}if(pp===np&&this.name==="right"){assert.strictEqual(parent.right,node);return true}default:return false}case"SequenceExpression":switch(parent.type){case"ForStatement":return false;case"ExpressionStatement":return this.name!=="expression";default:return true}case"YieldExpression":switch(parent.type){case"BinaryExpression":case"LogicalExpression":case"UnaryExpression":case"SpreadElement":case"SpreadProperty":case"CallExpression":case"MemberExpression":case"NewExpression":case"ConditionalExpression":case"YieldExpression":return true;default:return false}case"Literal":return parent.type==="MemberExpression"&&isNumber.check(node.value)&&this.name==="object"&&parent.object===node;case"AssignmentExpression":case"ConditionalExpression":switch(parent.type){case"UnaryExpression":case"SpreadElement":case"SpreadProperty":case"BinaryExpression":case"LogicalExpression":return true;case"CallExpression":return this.name==="callee"&&parent.callee===node;case"ConditionalExpression":return this.name==="test"&&parent.test===node;case"MemberExpression":return this.name==="object"&&parent.object===node;default:return false}default:if(parent.type==="NewExpression"&&this.name==="callee"&&parent.callee===node){return containsCallExpression(node)}}if(assumeExpressionContext!==true&&!this.canBeFirstInStatement()&&this.firstInStatement())return true;return false};function isBinary(node){return n.BinaryExpression.check(node)||n.LogicalExpression.check(node)}function isUnaryLike(node){return n.UnaryExpression.check(node)||n.SpreadElement&&n.SpreadElement.check(node)||n.SpreadProperty&&n.SpreadProperty.check(node)}var PRECEDENCE={};[["||"],["&&"],["|"],["^"],["&"],["==","===","!=","!=="],["<",">","<=",">=","in","instanceof"],[">>","<<",">>>"],["+","-"],["*","/","%"]].forEach(function(tier,i){tier.forEach(function(op){PRECEDENCE[op]=i})});function containsCallExpression(node){if(n.CallExpression.check(node)){return true}if(isArray.check(node)){return node.some(containsCallExpression)}if(n.Node.check(node)){return types.someField(node,function(name,child){return containsCallExpression(child)})}return false}NPp.canBeFirstInStatement=function(){var node=this.node;return!n.FunctionExpression.check(node)&&!n.ObjectExpression.check(node)};NPp.firstInStatement=function(){return firstInStatement(this)};function firstInStatement(path){for(var node,parent;path.parent;path=path.parent){node=path.node;parent=path.parent.node;if(n.BlockStatement.check(parent)&&path.parent.name==="body"&&path.name===0){assert.strictEqual(parent.body[0],node);return true}if(n.ExpressionStatement.check(parent)&&path.name==="expression"){assert.strictEqual(parent.expression,node);return true}if(n.SequenceExpression.check(parent)&&path.parent.name==="expressions"&&path.name===0){assert.strictEqual(parent.expressions[0],node);continue}if(n.CallExpression.check(parent)&&path.name==="callee"){assert.strictEqual(parent.callee,node);continue}if(n.MemberExpression.check(parent)&&path.name==="object"){assert.strictEqual(parent.object,node);continue}if(n.ConditionalExpression.check(parent)&&path.name==="test"){assert.strictEqual(parent.test,node);continue}if(isBinary(parent)&&path.name==="left"){assert.strictEqual(parent.left,node);continue}if(n.UnaryExpression.check(parent)&&!parent.prefix&&path.name==="argument"){assert.strictEqual(parent.argument,node);continue}return false}return true}function cleanUpNodesAfterPrune(remainingNodePath){if(n.VariableDeclaration.check(remainingNodePath.node)){var declarations=remainingNodePath.get("declarations").value;if(!declarations||declarations.length===0){return remainingNodePath.prune()}}else if(n.ExpressionStatement.check(remainingNodePath.node)){if(!remainingNodePath.get("expression").value){return remainingNodePath.prune()}}else if(n.IfStatement.check(remainingNodePath.node)){cleanUpIfStatementAfterPrune(remainingNodePath)}return remainingNodePath}function cleanUpIfStatementAfterPrune(ifStatement){var testExpression=ifStatement.get("test").value;var alternate=ifStatement.get("alternate").value;var consequent=ifStatement.get("consequent").value;if(!consequent&&!alternate){var testExpressionStatement=b.expressionStatement(testExpression);ifStatement.replace(testExpressionStatement)}else if(!consequent&&alternate){var negatedTestExpression=b.unaryExpression("!",testExpression,true);if(n.UnaryExpression.check(testExpression)&&testExpression.operator==="!"){negatedTestExpression=testExpression.argument}ifStatement.get("test").replace(negatedTestExpression);ifStatement.get("consequent").replace(alternate);ifStatement.get("alternate").replace()}}module.exports=NodePath},{"./path":135,"./scope":136,"./types":138,assert:141,util:167}],134:[function(require,module,exports){var assert=require("assert");var types=require("./types");var NodePath=require("./node-path");var Printable=types.namedTypes.Printable;var isArray=types.builtInTypes.array;var isObject=types.builtInTypes.object;var isFunction=types.builtInTypes.function;var hasOwn=Object.prototype.hasOwnProperty;var undefined;function PathVisitor(){assert.ok(this instanceof PathVisitor);this._reusableContextStack=[];this._methodNameTable=computeMethodNameTable(this);this._shouldVisitComments=hasOwn.call(this._methodNameTable,"Block")||hasOwn.call(this._methodNameTable,"Line");this.Context=makeContextConstructor(this);this._visiting=false;this._changeReported=false}function computeMethodNameTable(visitor){var typeNames=Object.create(null);for(var methodName in visitor){if(/^visit[A-Z]/.test(methodName)){typeNames[methodName.slice("visit".length)]=true}}var supertypeTable=types.computeSupertypeLookupTable(typeNames);var methodNameTable=Object.create(null);var typeNames=Object.keys(supertypeTable);var typeNameCount=typeNames.length;for(var i=0;i<typeNameCount;++i){var typeName=typeNames[i];methodName="visit"+supertypeTable[typeName];if(isFunction.check(visitor[methodName])){methodNameTable[typeName]=methodName}}return methodNameTable}PathVisitor.fromMethodsObject=function fromMethodsObject(methods){if(methods instanceof PathVisitor){return methods}if(!isObject.check(methods)){return new PathVisitor}function Visitor(){assert.ok(this instanceof Visitor);PathVisitor.call(this)}var Vp=Visitor.prototype=Object.create(PVp);Vp.constructor=Visitor;extend(Vp,methods);extend(Visitor,PathVisitor);isFunction.assert(Visitor.fromMethodsObject);isFunction.assert(Visitor.visit);return new Visitor};function extend(target,source){for(var property in source){if(hasOwn.call(source,property)){target[property]=source[property]}}return target}PathVisitor.visit=function visit(node,methods){return PathVisitor.fromMethodsObject(methods).visit(node)};var PVp=PathVisitor.prototype;var recursiveVisitWarning=["Recursively calling visitor.visit(path) resets visitor state.","Try this.visit(path) or this.traverse(path) instead."].join(" ");PVp.visit=function(){assert.ok(!this._visiting,recursiveVisitWarning);this._visiting=true;this._changeReported=false;this._abortRequested=false;var argc=arguments.length;var args=new Array(argc);for(var i=0;i<argc;++i){args[i]=arguments[i]}if(!(args[0]instanceof NodePath)){args[0]=new NodePath({root:args[0]}).get("root")}this.reset.apply(this,args);try{var root=this.visitWithoutReset(args[0]);var didNotThrow=true}finally{this._visiting=false;if(!didNotThrow&&this._abortRequested){return args[0].value}}return root};PVp.AbortRequest=function AbortRequest(){};PVp.abort=function(){var visitor=this;visitor._abortRequested=true;var request=new visitor.AbortRequest;request.cancel=function(){visitor._abortRequested=false};throw request};PVp.reset=function(path){};PVp.visitWithoutReset=function(path){if(this instanceof this.Context){return this.visitor.visitWithoutReset(path)}assert.ok(path instanceof NodePath);var value=path.value;var methodName=Printable.check(value)&&this._methodNameTable[value.type];if(methodName){var context=this.acquireContext(path);try{return context.invokeVisitorMethod(methodName)}finally{this.releaseContext(context)}}else{return visitChildren(path,this)}};function visitChildren(path,visitor){assert.ok(path instanceof NodePath);assert.ok(visitor instanceof PathVisitor);var value=path.value;if(isArray.check(value)){path.each(visitor.visitWithoutReset,visitor)}else if(!isObject.check(value)){}else{var childNames=types.getFieldNames(value);if(visitor._shouldVisitComments&&value.comments&&childNames.indexOf("comments")<0){childNames.push("comments")}var childCount=childNames.length;var childPaths=[];for(var i=0;i<childCount;++i){var childName=childNames[i];if(!hasOwn.call(value,childName)){value[childName]=types.getFieldValue(value,childName)}childPaths.push(path.get(childName)) }for(var i=0;i<childCount;++i){visitor.visitWithoutReset(childPaths[i])}}return path.value}PVp.acquireContext=function(path){if(this._reusableContextStack.length===0){return new this.Context(path)}return this._reusableContextStack.pop().reset(path)};PVp.releaseContext=function(context){assert.ok(context instanceof this.Context);this._reusableContextStack.push(context);context.currentPath=null};PVp.reportChanged=function(){this._changeReported=true};PVp.wasChangeReported=function(){return this._changeReported};function makeContextConstructor(visitor){function Context(path){assert.ok(this instanceof Context);assert.ok(this instanceof PathVisitor);assert.ok(path instanceof NodePath);Object.defineProperty(this,"visitor",{value:visitor,writable:false,enumerable:true,configurable:false});this.currentPath=path;this.needToCallTraverse=true;Object.seal(this)}assert.ok(visitor instanceof PathVisitor);var Cp=Context.prototype=Object.create(visitor);Cp.constructor=Context;extend(Cp,sharedContextProtoMethods);return Context}var sharedContextProtoMethods=Object.create(null);sharedContextProtoMethods.reset=function reset(path){assert.ok(this instanceof this.Context);assert.ok(path instanceof NodePath);this.currentPath=path;this.needToCallTraverse=true;return this};sharedContextProtoMethods.invokeVisitorMethod=function invokeVisitorMethod(methodName){assert.ok(this instanceof this.Context);assert.ok(this.currentPath instanceof NodePath);var result=this.visitor[methodName].call(this,this.currentPath);if(result===false){this.needToCallTraverse=false}else if(result!==undefined){this.currentPath=this.currentPath.replace(result)[0];if(this.needToCallTraverse){this.traverse(this.currentPath)}}assert.strictEqual(this.needToCallTraverse,false,"Must either call this.traverse or return false in "+methodName);var path=this.currentPath;return path&&path.value};sharedContextProtoMethods.traverse=function traverse(path,newVisitor){assert.ok(this instanceof this.Context);assert.ok(path instanceof NodePath);assert.ok(this.currentPath instanceof NodePath);this.needToCallTraverse=false;return visitChildren(path,PathVisitor.fromMethodsObject(newVisitor||this.visitor))};sharedContextProtoMethods.visit=function visit(path,newVisitor){assert.ok(this instanceof this.Context);assert.ok(path instanceof NodePath);assert.ok(this.currentPath instanceof NodePath);this.needToCallTraverse=false;return PathVisitor.fromMethodsObject(newVisitor||this.visitor).visitWithoutReset(path)};sharedContextProtoMethods.reportChanged=function reportChanged(){this.visitor.reportChanged()};sharedContextProtoMethods.abort=function abort(){this.needToCallTraverse=false;this.visitor.abort()};module.exports=PathVisitor},{"./node-path":133,"./types":138,assert:141}],135:[function(require,module,exports){var assert=require("assert");var Op=Object.prototype;var hasOwn=Op.hasOwnProperty;var types=require("./types");var isArray=types.builtInTypes.array;var isNumber=types.builtInTypes.number;var Ap=Array.prototype;var slice=Ap.slice;var map=Ap.map;function Path(value,parentPath,name){assert.ok(this instanceof Path);if(parentPath){assert.ok(parentPath instanceof Path)}else{parentPath=null;name=null}this.value=value;this.parentPath=parentPath;this.name=name;this.__childCache=null}var Pp=Path.prototype;function getChildCache(path){return path.__childCache||(path.__childCache=Object.create(null))}function getChildPath(path,name){var cache=getChildCache(path);var actualChildValue=path.getValueProperty(name);var childPath=cache[name];if(!hasOwn.call(cache,name)||childPath.value!==actualChildValue){childPath=cache[name]=new path.constructor(actualChildValue,path,name)}return childPath}Pp.getValueProperty=function getValueProperty(name){return this.value[name]};Pp.get=function get(name){var path=this;var names=arguments;var count=names.length;for(var i=0;i<count;++i){path=getChildPath(path,names[i])}return path};Pp.each=function each(callback,context){var childPaths=[];var len=this.value.length;var i=0;for(var i=0;i<len;++i){if(hasOwn.call(this.value,i)){childPaths[i]=this.get(i)}}context=context||this;for(i=0;i<len;++i){if(hasOwn.call(childPaths,i)){callback.call(context,childPaths[i])}}};Pp.map=function map(callback,context){var result=[];this.each(function(childPath){result.push(callback.call(this,childPath))},context);return result};Pp.filter=function filter(callback,context){var result=[];this.each(function(childPath){if(callback.call(this,childPath)){result.push(childPath)}},context);return result};function emptyMoves(){}function getMoves(path,offset,start,end){isArray.assert(path.value);if(offset===0){return emptyMoves}var length=path.value.length;if(length<1){return emptyMoves}var argc=arguments.length;if(argc===2){start=0;end=length}else if(argc===3){start=Math.max(start,0);end=length}else{start=Math.max(start,0);end=Math.min(end,length)}isNumber.assert(start);isNumber.assert(end);var moves=Object.create(null);var cache=getChildCache(path);for(var i=start;i<end;++i){if(hasOwn.call(path.value,i)){var childPath=path.get(i);assert.strictEqual(childPath.name,i);var newIndex=i+offset;childPath.name=newIndex;moves[newIndex]=childPath;delete cache[i]}}delete cache.length;return function(){for(var newIndex in moves){var childPath=moves[newIndex];assert.strictEqual(childPath.name,+newIndex);cache[newIndex]=childPath;path.value[newIndex]=childPath.value}}}Pp.shift=function shift(){var move=getMoves(this,-1);var result=this.value.shift();move();return result};Pp.unshift=function unshift(node){var move=getMoves(this,arguments.length);var result=this.value.unshift.apply(this.value,arguments);move();return result};Pp.push=function push(node){isArray.assert(this.value);delete getChildCache(this).length;return this.value.push.apply(this.value,arguments)};Pp.pop=function pop(){isArray.assert(this.value);var cache=getChildCache(this);delete cache[this.value.length-1];delete cache.length;return this.value.pop()};Pp.insertAt=function insertAt(index,node){var argc=arguments.length;var move=getMoves(this,argc-1,index);if(move===emptyMoves){return this}index=Math.max(index,0);for(var i=1;i<argc;++i){this.value[index+i-1]=arguments[i]}move();return this};Pp.insertBefore=function insertBefore(node){var pp=this.parentPath;var argc=arguments.length;var insertAtArgs=[this.name];for(var i=0;i<argc;++i){insertAtArgs.push(arguments[i])}return pp.insertAt.apply(pp,insertAtArgs)};Pp.insertAfter=function insertAfter(node){var pp=this.parentPath;var argc=arguments.length;var insertAtArgs=[this.name+1];for(var i=0;i<argc;++i){insertAtArgs.push(arguments[i])}return pp.insertAt.apply(pp,insertAtArgs)};function repairRelationshipWithParent(path){assert.ok(path instanceof Path);var pp=path.parentPath;if(!pp){return path}var parentValue=pp.value;var parentCache=getChildCache(pp);if(parentValue[path.name]===path.value){parentCache[path.name]=path}else if(isArray.check(parentValue)){var i=parentValue.indexOf(path.value);if(i>=0){parentCache[path.name=i]=path}}else{parentValue[path.name]=path.value;parentCache[path.name]=path}assert.strictEqual(parentValue[path.name],path.value);assert.strictEqual(path.parentPath.get(path.name),path);return path}Pp.replace=function replace(replacement){var results=[];var parentValue=this.parentPath.value;var parentCache=getChildCache(this.parentPath);var count=arguments.length;repairRelationshipWithParent(this);if(isArray.check(parentValue)){var originalLength=parentValue.length;var move=getMoves(this.parentPath,count-1,this.name+1);var spliceArgs=[this.name,1];for(var i=0;i<count;++i){spliceArgs.push(arguments[i])}var splicedOut=parentValue.splice.apply(parentValue,spliceArgs);assert.strictEqual(splicedOut[0],this.value);assert.strictEqual(parentValue.length,originalLength-1+count);move();if(count===0){delete this.value;delete parentCache[this.name];this.__childCache=null}else{assert.strictEqual(parentValue[this.name],replacement);if(this.value!==replacement){this.value=replacement;this.__childCache=null}for(i=0;i<count;++i){results.push(this.parentPath.get(this.name+i))}assert.strictEqual(results[0],this)}}else if(count===1){if(this.value!==replacement){this.__childCache=null}this.value=parentValue[this.name]=replacement;results.push(this)}else if(count===0){delete parentValue[this.name];delete this.value;this.__childCache=null}else{assert.ok(false,"Could not replace path")}return results};module.exports=Path},{"./types":138,assert:141}],136:[function(require,module,exports){var assert=require("assert");var types=require("./types");var Type=types.Type;var namedTypes=types.namedTypes;var Node=namedTypes.Node;var Expression=namedTypes.Expression;var isArray=types.builtInTypes.array;var hasOwn=Object.prototype.hasOwnProperty;var b=types.builders;function Scope(path,parentScope){assert.ok(this instanceof Scope);assert.ok(path instanceof require("./node-path"));ScopeType.assert(path.value);var depth;if(parentScope){assert.ok(parentScope instanceof Scope);depth=parentScope.depth+1}else{parentScope=null;depth=0}Object.defineProperties(this,{path:{value:path},node:{value:path.value},isGlobal:{value:!parentScope,enumerable:true},depth:{value:depth},parent:{value:parentScope},bindings:{value:{}}})}var scopeTypes=[namedTypes.Program,namedTypes.Function,namedTypes.CatchClause];var ScopeType=Type.or.apply(Type,scopeTypes);Scope.isEstablishedBy=function(node){return ScopeType.check(node)};var Sp=Scope.prototype;Sp.didScan=false;Sp.declares=function(name){this.scan();return hasOwn.call(this.bindings,name)};Sp.declareTemporary=function(prefix){if(prefix){assert.ok(/^[a-z$_]/i.test(prefix),prefix)}else{prefix="t$"}prefix+=this.depth.toString(36)+"$";this.scan();var index=0;while(this.declares(prefix+index)){++index}var name=prefix+index;return this.bindings[name]=types.builders.identifier(name)};Sp.injectTemporary=function(identifier,init){identifier||(identifier=this.declareTemporary());var bodyPath=this.path.get("body");if(namedTypes.BlockStatement.check(bodyPath.value)){bodyPath=bodyPath.get("body")}bodyPath.unshift(b.variableDeclaration("var",[b.variableDeclarator(identifier,init||null)]));return identifier};Sp.scan=function(force){if(force||!this.didScan){for(var name in this.bindings){delete this.bindings[name]}scanScope(this.path,this.bindings);this.didScan=true}};Sp.getBindings=function(){this.scan();return this.bindings};function scanScope(path,bindings){var node=path.value;ScopeType.assert(node);if(namedTypes.CatchClause.check(node)){addPattern(path.get("param"),bindings)}else{recursiveScanScope(path,bindings)}}function recursiveScanScope(path,bindings){var node=path.value;if(path.parent&&namedTypes.FunctionExpression.check(path.parent.node)&&path.parent.node.id){addPattern(path.parent.get("id"),bindings)}if(!node){}else if(isArray.check(node)){path.each(function(childPath){recursiveScanChild(childPath,bindings)})}else if(namedTypes.Function.check(node)){path.get("params").each(function(paramPath){addPattern(paramPath,bindings)});recursiveScanChild(path.get("body"),bindings)}else if(namedTypes.VariableDeclarator.check(node)){addPattern(path.get("id"),bindings);recursiveScanChild(path.get("init"),bindings)}else if(node.type==="ImportSpecifier"||node.type==="ImportNamespaceSpecifier"||node.type==="ImportDefaultSpecifier"){addPattern(node.name?path.get("name"):path.get("id"),bindings)}else if(Node.check(node)&&!Expression.check(node)){types.eachField(node,function(name,child){var childPath=path.get(name);assert.strictEqual(childPath.value,child);recursiveScanChild(childPath,bindings)})}}function recursiveScanChild(path,bindings){var node=path.value;if(!node||Expression.check(node)){}else if(namedTypes.FunctionDeclaration.check(node)){addPattern(path.get("id"),bindings)}else if(namedTypes.ClassDeclaration&&namedTypes.ClassDeclaration.check(node)){addPattern(path.get("id"),bindings)}else if(ScopeType.check(node)){if(namedTypes.CatchClause.check(node)){var catchParamName=node.param.name;var hadBinding=hasOwn.call(bindings,catchParamName);recursiveScanScope(path.get("body"),bindings);if(!hadBinding){delete bindings[catchParamName]}}}else{recursiveScanScope(path,bindings)}}function addPattern(patternPath,bindings){var pattern=patternPath.value;namedTypes.Pattern.assert(pattern);if(namedTypes.Identifier.check(pattern)){if(hasOwn.call(bindings,pattern.name)){bindings[pattern.name].push(patternPath)}else{bindings[pattern.name]=[patternPath]}}else if(namedTypes.ObjectPattern&&namedTypes.ObjectPattern.check(pattern)){patternPath.get("properties").each(function(propertyPath){var property=propertyPath.value;if(namedTypes.Pattern.check(property)){addPattern(propertyPath,bindings)}else if(namedTypes.Property.check(property)){addPattern(propertyPath.get("value"),bindings)}else if(namedTypes.SpreadProperty&&namedTypes.SpreadProperty.check(property)){addPattern(propertyPath.get("argument"),bindings)}})}else if(namedTypes.ArrayPattern&&namedTypes.ArrayPattern.check(pattern)){patternPath.get("elements").each(function(elementPath){var element=elementPath.value;if(namedTypes.Pattern.check(element)){addPattern(elementPath,bindings)}else if(namedTypes.SpreadElement&&namedTypes.SpreadElement.check(element)){addPattern(elementPath.get("argument"),bindings)}})}else if(namedTypes.PropertyPattern&&namedTypes.PropertyPattern.check(pattern)){addPattern(patternPath.get("pattern"),bindings)}else if(namedTypes.SpreadElementPattern&&namedTypes.SpreadElementPattern.check(pattern)||namedTypes.SpreadPropertyPattern&&namedTypes.SpreadPropertyPattern.check(pattern)){addPattern(patternPath.get("argument"),bindings)}}Sp.lookup=function(name){for(var scope=this;scope;scope=scope.parent)if(scope.declares(name))break;return scope};Sp.getGlobalScope=function(){var scope=this;while(!scope.isGlobal)scope=scope.parent;return scope};module.exports=Scope},{"./node-path":133,"./types":138,assert:141}],137:[function(require,module,exports){var types=require("../lib/types");var Type=types.Type;var builtin=types.builtInTypes;var isNumber=builtin.number;exports.geq=function(than){return new Type(function(value){return isNumber.check(value)&&value>=than},isNumber+" >= "+than)};exports.defaults={"null":function(){return null},emptyArray:function(){return[]},"false":function(){return false},"true":function(){return true},undefined:function(){}};var naiveIsPrimitive=Type.or(builtin.string,builtin.number,builtin.boolean,builtin.null,builtin.undefined);exports.isPrimitive=new Type(function(value){if(value===null)return true;var type=typeof value;return!(type==="object"||type==="function")},naiveIsPrimitive.toString())},{"../lib/types":138}],138:[function(require,module,exports){var assert=require("assert");var Ap=Array.prototype;var slice=Ap.slice;var map=Ap.map;var each=Ap.forEach;var Op=Object.prototype;var objToStr=Op.toString;var funObjStr=objToStr.call(function(){});var strObjStr=objToStr.call("");var hasOwn=Op.hasOwnProperty;function Type(check,name){var self=this;assert.ok(self instanceof Type,self);assert.strictEqual(objToStr.call(check),funObjStr,check+" is not a function");var nameObjStr=objToStr.call(name);assert.ok(nameObjStr===funObjStr||nameObjStr===strObjStr,name+" is neither a function nor a string");Object.defineProperties(self,{name:{value:name},check:{value:function(value,deep){var result=check.call(self,value,deep);if(!result&&deep&&objToStr.call(deep)===funObjStr)deep(self,value);return result}}})}var Tp=Type.prototype;exports.Type=Type;Tp.assert=function(value,deep){if(!this.check(value,deep)){var str=shallowStringify(value);assert.ok(false,str+" does not match type "+this);return false}return true};function shallowStringify(value){if(isObject.check(value))return"{"+Object.keys(value).map(function(key){return key+": "+value[key]}).join(", ")+"}";if(isArray.check(value))return"["+value.map(shallowStringify).join(", ")+"]";return JSON.stringify(value)}Tp.toString=function(){var name=this.name;if(isString.check(name))return name;if(isFunction.check(name))return name.call(this)+"";return name+" type"};var builtInTypes={};exports.builtInTypes=builtInTypes;function defBuiltInType(example,name){var objStr=objToStr.call(example);Object.defineProperty(builtInTypes,name,{enumerable:true,value:new Type(function(value){return objToStr.call(value)===objStr},name)});return builtInTypes[name]}var isString=defBuiltInType("","string");var isFunction=defBuiltInType(function(){},"function");var isArray=defBuiltInType([],"array");var isObject=defBuiltInType({},"object");var isRegExp=defBuiltInType(/./,"RegExp");var isDate=defBuiltInType(new Date,"Date");var isNumber=defBuiltInType(3,"number");var isBoolean=defBuiltInType(true,"boolean");var isNull=defBuiltInType(null,"null");var isUndefined=defBuiltInType(void 0,"undefined");function toType(from,name){if(from instanceof Type)return from;if(from instanceof Def)return from.type;if(isArray.check(from))return Type.fromArray(from);if(isObject.check(from))return Type.fromObject(from);if(isFunction.check(from))return new Type(from,name);return new Type(function(value){return value===from},isUndefined.check(name)?function(){return from+""}:name)}Type.or=function(){var types=[];var len=arguments.length;for(var i=0;i<len;++i)types.push(toType(arguments[i]));return new Type(function(value,deep){for(var i=0;i<len;++i)if(types[i].check(value,deep))return true;return false},function(){return types.join(" | ")})};Type.fromArray=function(arr){assert.ok(isArray.check(arr));assert.strictEqual(arr.length,1,"only one element type is permitted for typed arrays");return toType(arr[0]).arrayOf()};Tp.arrayOf=function(){var elemType=this;return new Type(function(value,deep){return isArray.check(value)&&value.every(function(elem){return elemType.check(elem,deep)})},function(){return"["+elemType+"]"})};Type.fromObject=function(obj){var fields=Object.keys(obj).map(function(name){return new Field(name,obj[name])});return new Type(function(value,deep){return isObject.check(value)&&fields.every(function(field){return field.type.check(value[field.name],deep)})},function(){return"{ "+fields.join(", ")+" }"})};function Field(name,type,defaultFn,hidden){var self=this;assert.ok(self instanceof Field);isString.assert(name);type=toType(type);var properties={name:{value:name},type:{value:type},hidden:{value:!!hidden}};if(isFunction.check(defaultFn)){properties.defaultFn={value:defaultFn}}Object.defineProperties(self,properties)}var Fp=Field.prototype;Fp.toString=function(){return JSON.stringify(this.name)+": "+this.type};Fp.getValue=function(obj){var value=obj[this.name];if(!isUndefined.check(value))return value;if(this.defaultFn)value=this.defaultFn.call(obj);return value};Type.def=function(typeName){isString.assert(typeName);return hasOwn.call(defCache,typeName)?defCache[typeName]:defCache[typeName]=new Def(typeName)};var defCache=Object.create(null);function Def(typeName){var self=this;assert.ok(self instanceof Def);Object.defineProperties(self,{typeName:{value:typeName},baseNames:{value:[]},ownFields:{value:Object.create(null)},allSupertypes:{value:Object.create(null)},supertypeList:{value:[]},allFields:{value:Object.create(null)},fieldNames:{value:[]},type:{value:new Type(function(value,deep){return self.check(value,deep)},typeName)}})}Def.fromValue=function(value){if(value&&typeof value==="object"){var type=value.type;if(typeof type==="string"&&hasOwn.call(defCache,type)){var d=defCache[type];if(d.finalized){return d}}}return null};var Dp=Def.prototype;Dp.isSupertypeOf=function(that){if(that instanceof Def){assert.strictEqual(this.finalized,true);assert.strictEqual(that.finalized,true);return hasOwn.call(that.allSupertypes,this.typeName)}else{assert.ok(false,that+" is not a Def")}};exports.getSupertypeNames=function(typeName){assert.ok(hasOwn.call(defCache,typeName));var d=defCache[typeName];assert.strictEqual(d.finalized,true);return d.supertypeList.slice(1)};exports.computeSupertypeLookupTable=function(candidates){var table={};var typeNames=Object.keys(defCache);var typeNameCount=typeNames.length;for(var i=0;i<typeNameCount;++i){var typeName=typeNames[i];var d=defCache[typeName];assert.strictEqual(d.finalized,true);for(var j=0;j<d.supertypeList.length;++j){var superTypeName=d.supertypeList[j];if(hasOwn.call(candidates,superTypeName)){table[typeName]=superTypeName;break}}}return table};Dp.checkAllFields=function(value,deep){var allFields=this.allFields;assert.strictEqual(this.finalized,true);function checkFieldByName(name){var field=allFields[name];var type=field.type;var child=field.getValue(value);return type.check(child,deep)}return isObject.check(value)&&Object.keys(allFields).every(checkFieldByName)};Dp.check=function(value,deep){assert.strictEqual(this.finalized,true,"prematurely checking unfinalized type "+this.typeName);if(!isObject.check(value))return false;var vDef=Def.fromValue(value);if(!vDef){if(this.typeName==="SourceLocation"||this.typeName==="Position"){return this.checkAllFields(value,deep)}return false}if(deep&&vDef===this)return this.checkAllFields(value,deep);if(!this.isSupertypeOf(vDef))return false;if(!deep)return true;return vDef.checkAllFields(value,deep)&&this.checkAllFields(value,false)};Dp.bases=function(){var bases=this.baseNames;assert.strictEqual(this.finalized,false);each.call(arguments,function(baseName){isString.assert(baseName);if(bases.indexOf(baseName)<0)bases.push(baseName)});return this};Object.defineProperty(Dp,"buildable",{value:false});var builders={};exports.builders=builders;var nodePrototype={};exports.defineMethod=function(name,func){var old=nodePrototype[name];if(isUndefined.check(func)){delete nodePrototype[name]}else{isFunction.assert(func);Object.defineProperty(nodePrototype,name,{enumerable:true,configurable:true,value:func})}return old};Dp.build=function(){var self=this;Object.defineProperty(self,"buildParams",{value:slice.call(arguments),writable:false,enumerable:false,configurable:true});assert.strictEqual(self.finalized,false);isString.arrayOf().assert(self.buildParams);if(self.buildable){return self}self.field("type",self.typeName,function(){return self.typeName});Object.defineProperty(self,"buildable",{value:true});Object.defineProperty(builders,getBuilderName(self.typeName),{enumerable:true,value:function(){var args=arguments;var argc=args.length;var built=Object.create(nodePrototype);assert.ok(self.finalized,"attempting to instantiate unfinalized type "+self.typeName);function add(param,i){if(hasOwn.call(built,param))return;var all=self.allFields;assert.ok(hasOwn.call(all,param),param);var field=all[param];var type=field.type;var value;if(isNumber.check(i)&&i<argc){value=args[i]}else if(field.defaultFn){value=field.defaultFn.call(built)}else{var message="no value or default function given for field "+JSON.stringify(param)+" of "+self.typeName+"("+self.buildParams.map(function(name){return all[name]}).join(", ")+")";assert.ok(false,message)}if(!type.check(value)){assert.ok(false,shallowStringify(value)+" does not match field "+field+" of type "+self.typeName)}built[param]=value}self.buildParams.forEach(function(param,i){add(param,i)});Object.keys(self.allFields).forEach(function(param){add(param)});assert.strictEqual(built.type,self.typeName);return built}});return self};function getBuilderName(typeName){return typeName.replace(/^[A-Z]+/,function(upperCasePrefix){var len=upperCasePrefix.length;switch(len){case 0:return"";case 1:return upperCasePrefix.toLowerCase();default:return upperCasePrefix.slice(0,len-1).toLowerCase()+upperCasePrefix.charAt(len-1)}})}Dp.field=function(name,type,defaultFn,hidden){assert.strictEqual(this.finalized,false);this.ownFields[name]=new Field(name,type,defaultFn,hidden);return this};var namedTypes={};exports.namedTypes=namedTypes;function getFieldNames(object){var d=Def.fromValue(object);if(d){return d.fieldNames.slice(0)}if("type"in object){assert.ok(false,"did not recognize object of type "+JSON.stringify(object.type))}return Object.keys(object)}exports.getFieldNames=getFieldNames;function getFieldValue(object,fieldName){var d=Def.fromValue(object);if(d){var field=d.allFields[fieldName];if(field){return field.getValue(object)}}return object[fieldName]}exports.getFieldValue=getFieldValue;exports.eachField=function(object,callback,context){getFieldNames(object).forEach(function(name){callback.call(this,name,getFieldValue(object,name))},context)};exports.someField=function(object,callback,context){return getFieldNames(object).some(function(name){return callback.call(this,name,getFieldValue(object,name))},context)};Object.defineProperty(Dp,"finalized",{value:false});Dp.finalize=function(){if(!this.finalized){var allFields=this.allFields;var allSupertypes=this.allSupertypes;this.baseNames.forEach(function(name){var def=defCache[name];def.finalize();extend(allFields,def.allFields);extend(allSupertypes,def.allSupertypes)});extend(allFields,this.ownFields);allSupertypes[this.typeName]=this;this.fieldNames.length=0;for(var fieldName in allFields){if(hasOwn.call(allFields,fieldName)&&!allFields[fieldName].hidden){this.fieldNames.push(fieldName)}}Object.defineProperty(namedTypes,this.typeName,{enumerable:true,value:this.type});Object.defineProperty(this,"finalized",{value:true});populateSupertypeList(this.typeName,this.supertypeList)}};function populateSupertypeList(typeName,list){list.length=0;list.push(typeName);var lastSeen=Object.create(null);for(var pos=0;pos<list.length;++pos){typeName=list[pos];var d=defCache[typeName];assert.strictEqual(d.finalized,true);if(hasOwn.call(lastSeen,typeName)){delete list[lastSeen[typeName]]}lastSeen[typeName]=pos;list.push.apply(list,d.baseNames)}for(var to=0,from=to,len=list.length;from<len;++from){if(hasOwn.call(list,from)){list[to++]=list[from]}}list.length=to}function extend(into,from){Object.keys(from).forEach(function(name){into[name]=from[name]});return into}exports.finalize=function(){Object.keys(defCache).forEach(function(name){defCache[name].finalize()})}},{assert:141}],139:[function(require,module,exports){var types=require("./lib/types");require("./def/core");require("./def/es6");require("./def/es7");require("./def/mozilla");require("./def/e4x");require("./def/fb-harmony");types.finalize();exports.Type=types.Type;exports.builtInTypes=types.builtInTypes;exports.namedTypes=types.namedTypes;exports.builders=types.builders;exports.defineMethod=types.defineMethod;exports.getFieldNames=types.getFieldNames;exports.getFieldValue=types.getFieldValue;exports.eachField=types.eachField;exports.someField=types.someField;exports.getSupertypeNames=types.getSupertypeNames;exports.astNodesAreEquivalent=require("./lib/equiv");exports.finalize=types.finalize;exports.NodePath=require("./lib/node-path");exports.PathVisitor=require("./lib/path-visitor");exports.visit=exports.PathVisitor.visit},{"./def/core":126,"./def/e4x":127,"./def/es6":128,"./def/es7":129,"./def/fb-harmony":130,"./def/mozilla":131,"./lib/equiv":132,"./lib/node-path":133,"./lib/path-visitor":134,"./lib/types":138}],140:[function(require,module,exports){},{}],141:[function(require,module,exports){var util=require("util/");var pSlice=Array.prototype.slice;var hasOwn=Object.prototype.hasOwnProperty;var assert=module.exports=ok;assert.AssertionError=function AssertionError(options){this.name="AssertionError";this.actual=options.actual;this.expected=options.expected;this.operator=options.operator;if(options.message){this.message=options.message;this.generatedMessage=false}else{this.message=getMessage(this);this.generatedMessage=true}var stackStartFunction=options.stackStartFunction||fail;if(Error.captureStackTrace){Error.captureStackTrace(this,stackStartFunction)}else{var err=new Error;if(err.stack){var out=err.stack;var fn_name=stackStartFunction.name;var idx=out.indexOf("\n"+fn_name);if(idx>=0){var next_line=out.indexOf("\n",idx+1);out=out.substring(next_line+1)}this.stack=out}}};util.inherits(assert.AssertionError,Error);function replacer(key,value){if(util.isUndefined(value)){return""+value}if(util.isNumber(value)&&!isFinite(value)){return value.toString()}if(util.isFunction(value)||util.isRegExp(value)){return value.toString()}return value}function truncate(s,n){if(util.isString(s)){return s.length<n?s:s.slice(0,n)}else{return s}}function getMessage(self){return truncate(JSON.stringify(self.actual,replacer),128)+" "+self.operator+" "+truncate(JSON.stringify(self.expected,replacer),128)}function fail(actual,expected,message,operator,stackStartFunction){throw new assert.AssertionError({message:message,actual:actual,expected:expected,operator:operator,stackStartFunction:stackStartFunction})}assert.fail=fail;function ok(value,message){if(!value)fail(value,true,message,"==",assert.ok)}assert.ok=ok;assert.equal=function equal(actual,expected,message){if(actual!=expected)fail(actual,expected,message,"==",assert.equal)};assert.notEqual=function notEqual(actual,expected,message){if(actual==expected){fail(actual,expected,message,"!=",assert.notEqual)}};assert.deepEqual=function deepEqual(actual,expected,message){if(!_deepEqual(actual,expected)){fail(actual,expected,message,"deepEqual",assert.deepEqual)}};function _deepEqual(actual,expected){if(actual===expected){return true}else if(util.isBuffer(actual)&&util.isBuffer(expected)){if(actual.length!=expected.length)return false;for(var i=0;i<actual.length;i++){if(actual[i]!==expected[i])return false}return true}else if(util.isDate(actual)&&util.isDate(expected)){return actual.getTime()===expected.getTime()}else if(util.isRegExp(actual)&&util.isRegExp(expected)){return actual.source===expected.source&&actual.global===expected.global&&actual.multiline===expected.multiline&&actual.lastIndex===expected.lastIndex&&actual.ignoreCase===expected.ignoreCase}else if(!util.isObject(actual)&&!util.isObject(expected)){return actual==expected}else{return objEquiv(actual,expected)}}function isArguments(object){return Object.prototype.toString.call(object)=="[object Arguments]"}function objEquiv(a,b){if(util.isNullOrUndefined(a)||util.isNullOrUndefined(b))return false;if(a.prototype!==b.prototype)return false;if(util.isPrimitive(a)||util.isPrimitive(b)){return a===b}var aIsArgs=isArguments(a),bIsArgs=isArguments(b);if(aIsArgs&&!bIsArgs||!aIsArgs&&bIsArgs)return false;if(aIsArgs){a=pSlice.call(a);b=pSlice.call(b);return _deepEqual(a,b)}var ka=objectKeys(a),kb=objectKeys(b),key,i;if(ka.length!=kb.length)return false;ka.sort();kb.sort();for(i=ka.length-1;i>=0;i--){if(ka[i]!=kb[i])return false}for(i=ka.length-1;i>=0;i--){key=ka[i];if(!_deepEqual(a[key],b[key]))return false}return true}assert.notDeepEqual=function notDeepEqual(actual,expected,message){if(_deepEqual(actual,expected)){fail(actual,expected,message,"notDeepEqual",assert.notDeepEqual)}};assert.strictEqual=function strictEqual(actual,expected,message){if(actual!==expected){fail(actual,expected,message,"===",assert.strictEqual)}};assert.notStrictEqual=function notStrictEqual(actual,expected,message){if(actual===expected){fail(actual,expected,message,"!==",assert.notStrictEqual)}};function expectedException(actual,expected){if(!actual||!expected){return false}if(Object.prototype.toString.call(expected)=="[object RegExp]"){return expected.test(actual)}else if(actual instanceof expected){return true}else if(expected.call({},actual)===true){return true}return false}function _throws(shouldThrow,block,expected,message){var actual;if(util.isString(expected)){message=expected;expected=null}try{block()}catch(e){actual=e}message=(expected&&expected.name?" ("+expected.name+").":".")+(message?" "+message:".");if(shouldThrow&&!actual){fail(actual,expected,"Missing expected exception"+message)}if(!shouldThrow&&expectedException(actual,expected)){fail(actual,expected,"Got unwanted exception"+message)}if(shouldThrow&&actual&&expected&&!expectedException(actual,expected)||!shouldThrow&&actual){throw actual}}assert.throws=function(block,error,message){_throws.apply(this,[true].concat(pSlice.call(arguments)))};assert.doesNotThrow=function(block,message){_throws.apply(this,[false].concat(pSlice.call(arguments)))};assert.ifError=function(err){if(err){throw err}};var objectKeys=Object.keys||function(obj){var keys=[]; for(var key in obj){if(hasOwn.call(obj,key))keys.push(key)}return keys}},{"util/":167}],142:[function(require,module,exports){arguments[4][140][0].apply(exports,arguments)},{dup:140}],143:[function(require,module,exports){var base64=require("base64-js");var ieee754=require("ieee754");var isArray=require("is-array");exports.Buffer=Buffer;exports.SlowBuffer=SlowBuffer;exports.INSPECT_MAX_BYTES=50;Buffer.poolSize=8192;var kMaxLength=1073741823;var rootParent={};Buffer.TYPED_ARRAY_SUPPORT=function(){try{var buf=new ArrayBuffer(0);var arr=new Uint8Array(buf);arr.foo=function(){return 42};return arr.foo()===42&&typeof arr.subarray==="function"&&new Uint8Array(1).subarray(1,1).byteLength===0}catch(e){return false}}();function Buffer(subject,encoding,noZero){if(!(this instanceof Buffer))return new Buffer(subject,encoding,noZero);var type=typeof subject;var length;if(type==="number"){length=+subject}else if(type==="string"){length=Buffer.byteLength(subject,encoding)}else if(type==="object"&&subject!==null){if(subject.type==="Buffer"&&isArray(subject.data))subject=subject.data;length=+subject.length}else{throw new TypeError("must start with number, buffer, array or string")}if(length>kMaxLength)throw new RangeError("Attempt to allocate Buffer larger than maximum "+"size: 0x"+kMaxLength.toString(16)+" bytes");if(length<0)length=0;else length>>>=0;var self=this;if(Buffer.TYPED_ARRAY_SUPPORT){self=Buffer._augment(new Uint8Array(length))}else{self.length=length;self._isBuffer=true}var i;if(Buffer.TYPED_ARRAY_SUPPORT&&typeof subject.byteLength==="number"){self._set(subject)}else if(isArrayish(subject)){if(Buffer.isBuffer(subject)){for(i=0;i<length;i++)self[i]=subject.readUInt8(i)}else{for(i=0;i<length;i++)self[i]=(subject[i]%256+256)%256}}else if(type==="string"){self.write(subject,0,encoding)}else if(type==="number"&&!Buffer.TYPED_ARRAY_SUPPORT&&!noZero){for(i=0;i<length;i++){self[i]=0}}if(length>0&&length<=Buffer.poolSize)self.parent=rootParent;return self}function SlowBuffer(subject,encoding,noZero){if(!(this instanceof SlowBuffer))return new SlowBuffer(subject,encoding,noZero);var buf=new Buffer(subject,encoding,noZero);delete buf.parent;return buf}Buffer.isBuffer=function(b){return!!(b!=null&&b._isBuffer)};Buffer.compare=function(a,b){if(!Buffer.isBuffer(a)||!Buffer.isBuffer(b))throw new TypeError("Arguments must be Buffers");if(a===b)return 0;var x=a.length;var y=b.length;for(var i=0,len=Math.min(x,y);i<len&&a[i]===b[i];i++){}if(i!==len){x=a[i];y=b[i]}if(x<y)return-1;if(y<x)return 1;return 0};Buffer.isEncoding=function(encoding){switch(String(encoding).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"raw":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return true;default:return false}};Buffer.concat=function(list,totalLength){if(!isArray(list))throw new TypeError("Usage: Buffer.concat(list[, length])");if(list.length===0){return new Buffer(0)}else if(list.length===1){return list[0]}var i;if(totalLength===undefined){totalLength=0;for(i=0;i<list.length;i++){totalLength+=list[i].length}}var buf=new Buffer(totalLength);var pos=0;for(i=0;i<list.length;i++){var item=list[i];item.copy(buf,pos);pos+=item.length}return buf};Buffer.byteLength=function(str,encoding){var ret;str=str+"";switch(encoding||"utf8"){case"ascii":case"binary":case"raw":ret=str.length;break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":ret=str.length*2;break;case"hex":ret=str.length>>>1;break;case"utf8":case"utf-8":ret=utf8ToBytes(str).length;break;case"base64":ret=base64ToBytes(str).length;break;default:ret=str.length}return ret};Buffer.prototype.length=undefined;Buffer.prototype.parent=undefined;Buffer.prototype.toString=function(encoding,start,end){var loweredCase=false;start=start>>>0;end=end===undefined||end===Infinity?this.length:end>>>0;if(!encoding)encoding="utf8";if(start<0)start=0;if(end>this.length)end=this.length;if(end<=start)return"";while(true){switch(encoding){case"hex":return hexSlice(this,start,end);case"utf8":case"utf-8":return utf8Slice(this,start,end);case"ascii":return asciiSlice(this,start,end);case"binary":return binarySlice(this,start,end);case"base64":return base64Slice(this,start,end);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return utf16leSlice(this,start,end);default:if(loweredCase)throw new TypeError("Unknown encoding: "+encoding);encoding=(encoding+"").toLowerCase();loweredCase=true}}};Buffer.prototype.equals=function(b){if(!Buffer.isBuffer(b))throw new TypeError("Argument must be a Buffer");if(this===b)return true;return Buffer.compare(this,b)===0};Buffer.prototype.inspect=function(){var str="";var max=exports.INSPECT_MAX_BYTES;if(this.length>0){str=this.toString("hex",0,max).match(/.{2}/g).join(" ");if(this.length>max)str+=" ... "}return"<Buffer "+str+">"};Buffer.prototype.compare=function(b){if(!Buffer.isBuffer(b))throw new TypeError("Argument must be a Buffer");if(this===b)return 0;return Buffer.compare(this,b)};Buffer.prototype.get=function(offset){console.log(".get() is deprecated. Access using array indexes instead.");return this.readUInt8(offset)};Buffer.prototype.set=function(v,offset){console.log(".set() is deprecated. Access using array indexes instead.");return this.writeUInt8(v,offset)};function hexWrite(buf,string,offset,length){offset=Number(offset)||0;var remaining=buf.length-offset;if(!length){length=remaining}else{length=Number(length);if(length>remaining){length=remaining}}var strLen=string.length;if(strLen%2!==0)throw new Error("Invalid hex string");if(length>strLen/2){length=strLen/2}for(var i=0;i<length;i++){var byte=parseInt(string.substr(i*2,2),16);if(isNaN(byte))throw new Error("Invalid hex string");buf[offset+i]=byte}return i}function utf8Write(buf,string,offset,length){var charsWritten=blitBuffer(utf8ToBytes(string,buf.length-offset),buf,offset,length);return charsWritten}function asciiWrite(buf,string,offset,length){var charsWritten=blitBuffer(asciiToBytes(string),buf,offset,length);return charsWritten}function binaryWrite(buf,string,offset,length){return asciiWrite(buf,string,offset,length)}function base64Write(buf,string,offset,length){var charsWritten=blitBuffer(base64ToBytes(string),buf,offset,length);return charsWritten}function utf16leWrite(buf,string,offset,length){var charsWritten=blitBuffer(utf16leToBytes(string,buf.length-offset),buf,offset,length);return charsWritten}Buffer.prototype.write=function(string,offset,length,encoding){if(isFinite(offset)){if(!isFinite(length)){encoding=length;length=undefined}}else{var swap=encoding;encoding=offset;offset=length;length=swap}offset=Number(offset)||0;if(length<0||offset<0||offset>this.length)throw new RangeError("attempt to write outside buffer bounds");var remaining=this.length-offset;if(!length){length=remaining}else{length=Number(length);if(length>remaining){length=remaining}}encoding=String(encoding||"utf8").toLowerCase();var ret;switch(encoding){case"hex":ret=hexWrite(this,string,offset,length);break;case"utf8":case"utf-8":ret=utf8Write(this,string,offset,length);break;case"ascii":ret=asciiWrite(this,string,offset,length);break;case"binary":ret=binaryWrite(this,string,offset,length);break;case"base64":ret=base64Write(this,string,offset,length);break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":ret=utf16leWrite(this,string,offset,length);break;default:throw new TypeError("Unknown encoding: "+encoding)}return ret};Buffer.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function base64Slice(buf,start,end){if(start===0&&end===buf.length){return base64.fromByteArray(buf)}else{return base64.fromByteArray(buf.slice(start,end))}}function utf8Slice(buf,start,end){var res="";var tmp="";end=Math.min(buf.length,end);for(var i=start;i<end;i++){if(buf[i]<=127){res+=decodeUtf8Char(tmp)+String.fromCharCode(buf[i]);tmp=""}else{tmp+="%"+buf[i].toString(16)}}return res+decodeUtf8Char(tmp)}function asciiSlice(buf,start,end){var ret="";end=Math.min(buf.length,end);for(var i=start;i<end;i++){ret+=String.fromCharCode(buf[i]&127)}return ret}function binarySlice(buf,start,end){var ret="";end=Math.min(buf.length,end);for(var i=start;i<end;i++){ret+=String.fromCharCode(buf[i])}return ret}function hexSlice(buf,start,end){var len=buf.length;if(!start||start<0)start=0;if(!end||end<0||end>len)end=len;var out="";for(var i=start;i<end;i++){out+=toHex(buf[i])}return out}function utf16leSlice(buf,start,end){var bytes=buf.slice(start,end);var res="";for(var i=0;i<bytes.length;i+=2){res+=String.fromCharCode(bytes[i]+bytes[i+1]*256)}return res}Buffer.prototype.slice=function(start,end){var len=this.length;start=~~start;end=end===undefined?len:~~end;if(start<0){start+=len;if(start<0)start=0}else if(start>len){start=len}if(end<0){end+=len;if(end<0)end=0}else if(end>len){end=len}if(end<start)end=start;var newBuf;if(Buffer.TYPED_ARRAY_SUPPORT){newBuf=Buffer._augment(this.subarray(start,end))}else{var sliceLen=end-start;newBuf=new Buffer(sliceLen,undefined,true);for(var i=0;i<sliceLen;i++){newBuf[i]=this[i+start]}}if(newBuf.length)newBuf.parent=this.parent||this;return newBuf};function checkOffset(offset,ext,length){if(offset%1!==0||offset<0)throw new RangeError("offset is not uint");if(offset+ext>length)throw new RangeError("Trying to access beyond buffer length")}Buffer.prototype.readUIntLE=function(offset,byteLength,noAssert){offset=offset>>>0;byteLength=byteLength>>>0;if(!noAssert)checkOffset(offset,byteLength,this.length);var val=this[offset];var mul=1;var i=0;while(++i<byteLength&&(mul*=256))val+=this[offset+i]*mul;return val};Buffer.prototype.readUIntBE=function(offset,byteLength,noAssert){offset=offset>>>0;byteLength=byteLength>>>0;if(!noAssert)checkOffset(offset,byteLength,this.length);var val=this[offset+--byteLength];var mul=1;while(byteLength>0&&(mul*=256))val+=this[offset+--byteLength]*mul;return val};Buffer.prototype.readUInt8=function(offset,noAssert){if(!noAssert)checkOffset(offset,1,this.length);return this[offset]};Buffer.prototype.readUInt16LE=function(offset,noAssert){if(!noAssert)checkOffset(offset,2,this.length);return this[offset]|this[offset+1]<<8};Buffer.prototype.readUInt16BE=function(offset,noAssert){if(!noAssert)checkOffset(offset,2,this.length);return this[offset]<<8|this[offset+1]};Buffer.prototype.readUInt32LE=function(offset,noAssert){if(!noAssert)checkOffset(offset,4,this.length);return(this[offset]|this[offset+1]<<8|this[offset+2]<<16)+this[offset+3]*16777216};Buffer.prototype.readUInt32BE=function(offset,noAssert){if(!noAssert)checkOffset(offset,4,this.length);return this[offset]*16777216+(this[offset+1]<<16|this[offset+2]<<8|this[offset+3])};Buffer.prototype.readIntLE=function(offset,byteLength,noAssert){offset=offset>>>0;byteLength=byteLength>>>0;if(!noAssert)checkOffset(offset,byteLength,this.length);var val=this[offset];var mul=1;var i=0;while(++i<byteLength&&(mul*=256))val+=this[offset+i]*mul;mul*=128;if(val>=mul)val-=Math.pow(2,8*byteLength);return val};Buffer.prototype.readIntBE=function(offset,byteLength,noAssert){offset=offset>>>0;byteLength=byteLength>>>0;if(!noAssert)checkOffset(offset,byteLength,this.length);var i=byteLength;var mul=1;var val=this[offset+--i];while(i>0&&(mul*=256))val+=this[offset+--i]*mul;mul*=128;if(val>=mul)val-=Math.pow(2,8*byteLength);return val};Buffer.prototype.readInt8=function(offset,noAssert){if(!noAssert)checkOffset(offset,1,this.length);if(!(this[offset]&128))return this[offset];return(255-this[offset]+1)*-1};Buffer.prototype.readInt16LE=function(offset,noAssert){if(!noAssert)checkOffset(offset,2,this.length);var val=this[offset]|this[offset+1]<<8;return val&32768?val|4294901760:val};Buffer.prototype.readInt16BE=function(offset,noAssert){if(!noAssert)checkOffset(offset,2,this.length);var val=this[offset+1]|this[offset]<<8;return val&32768?val|4294901760:val};Buffer.prototype.readInt32LE=function(offset,noAssert){if(!noAssert)checkOffset(offset,4,this.length);return this[offset]|this[offset+1]<<8|this[offset+2]<<16|this[offset+3]<<24};Buffer.prototype.readInt32BE=function(offset,noAssert){if(!noAssert)checkOffset(offset,4,this.length);return this[offset]<<24|this[offset+1]<<16|this[offset+2]<<8|this[offset+3]};Buffer.prototype.readFloatLE=function(offset,noAssert){if(!noAssert)checkOffset(offset,4,this.length);return ieee754.read(this,offset,true,23,4)};Buffer.prototype.readFloatBE=function(offset,noAssert){if(!noAssert)checkOffset(offset,4,this.length);return ieee754.read(this,offset,false,23,4)};Buffer.prototype.readDoubleLE=function(offset,noAssert){if(!noAssert)checkOffset(offset,8,this.length);return ieee754.read(this,offset,true,52,8)};Buffer.prototype.readDoubleBE=function(offset,noAssert){if(!noAssert)checkOffset(offset,8,this.length);return ieee754.read(this,offset,false,52,8)};function checkInt(buf,value,offset,ext,max,min){if(!Buffer.isBuffer(buf))throw new TypeError("buffer must be a Buffer instance");if(value>max||value<min)throw new RangeError("value is out of bounds");if(offset+ext>buf.length)throw new RangeError("index out of range")}Buffer.prototype.writeUIntLE=function(value,offset,byteLength,noAssert){value=+value;offset=offset>>>0;byteLength=byteLength>>>0;if(!noAssert)checkInt(this,value,offset,byteLength,Math.pow(2,8*byteLength),0);var mul=1;var i=0;this[offset]=value&255;while(++i<byteLength&&(mul*=256))this[offset+i]=value/mul>>>0&255;return offset+byteLength};Buffer.prototype.writeUIntBE=function(value,offset,byteLength,noAssert){value=+value;offset=offset>>>0;byteLength=byteLength>>>0;if(!noAssert)checkInt(this,value,offset,byteLength,Math.pow(2,8*byteLength),0);var i=byteLength-1;var mul=1;this[offset+i]=value&255;while(--i>=0&&(mul*=256))this[offset+i]=value/mul>>>0&255;return offset+byteLength};Buffer.prototype.writeUInt8=function(value,offset,noAssert){value=+value;offset=offset>>>0;if(!noAssert)checkInt(this,value,offset,1,255,0);if(!Buffer.TYPED_ARRAY_SUPPORT)value=Math.floor(value);this[offset]=value;return offset+1};function objectWriteUInt16(buf,value,offset,littleEndian){if(value<0)value=65535+value+1;for(var i=0,j=Math.min(buf.length-offset,2);i<j;i++){buf[offset+i]=(value&255<<8*(littleEndian?i:1-i))>>>(littleEndian?i:1-i)*8}}Buffer.prototype.writeUInt16LE=function(value,offset,noAssert){value=+value;offset=offset>>>0;if(!noAssert)checkInt(this,value,offset,2,65535,0);if(Buffer.TYPED_ARRAY_SUPPORT){this[offset]=value;this[offset+1]=value>>>8}else objectWriteUInt16(this,value,offset,true);return offset+2};Buffer.prototype.writeUInt16BE=function(value,offset,noAssert){value=+value;offset=offset>>>0;if(!noAssert)checkInt(this,value,offset,2,65535,0);if(Buffer.TYPED_ARRAY_SUPPORT){this[offset]=value>>>8;this[offset+1]=value}else objectWriteUInt16(this,value,offset,false);return offset+2};function objectWriteUInt32(buf,value,offset,littleEndian){if(value<0)value=4294967295+value+1;for(var i=0,j=Math.min(buf.length-offset,4);i<j;i++){buf[offset+i]=value>>>(littleEndian?i:3-i)*8&255}}Buffer.prototype.writeUInt32LE=function(value,offset,noAssert){value=+value;offset=offset>>>0;if(!noAssert)checkInt(this,value,offset,4,4294967295,0);if(Buffer.TYPED_ARRAY_SUPPORT){this[offset+3]=value>>>24;this[offset+2]=value>>>16;this[offset+1]=value>>>8;this[offset]=value}else objectWriteUInt32(this,value,offset,true);return offset+4};Buffer.prototype.writeUInt32BE=function(value,offset,noAssert){value=+value;offset=offset>>>0;if(!noAssert)checkInt(this,value,offset,4,4294967295,0);if(Buffer.TYPED_ARRAY_SUPPORT){this[offset]=value>>>24;this[offset+1]=value>>>16;this[offset+2]=value>>>8;this[offset+3]=value}else objectWriteUInt32(this,value,offset,false);return offset+4};Buffer.prototype.writeIntLE=function(value,offset,byteLength,noAssert){value=+value;offset=offset>>>0;if(!noAssert){checkInt(this,value,offset,byteLength,Math.pow(2,8*byteLength-1)-1,-Math.pow(2,8*byteLength-1))}var i=0;var mul=1;var sub=value<0?1:0;this[offset]=value&255;while(++i<byteLength&&(mul*=256))this[offset+i]=(value/mul>>0)-sub&255;return offset+byteLength};Buffer.prototype.writeIntBE=function(value,offset,byteLength,noAssert){value=+value;offset=offset>>>0;if(!noAssert){checkInt(this,value,offset,byteLength,Math.pow(2,8*byteLength-1)-1,-Math.pow(2,8*byteLength-1))}var i=byteLength-1;var mul=1;var sub=value<0?1:0;this[offset+i]=value&255;while(--i>=0&&(mul*=256))this[offset+i]=(value/mul>>0)-sub&255;return offset+byteLength};Buffer.prototype.writeInt8=function(value,offset,noAssert){value=+value;offset=offset>>>0;if(!noAssert)checkInt(this,value,offset,1,127,-128);if(!Buffer.TYPED_ARRAY_SUPPORT)value=Math.floor(value);if(value<0)value=255+value+1;this[offset]=value;return offset+1};Buffer.prototype.writeInt16LE=function(value,offset,noAssert){value=+value;offset=offset>>>0;if(!noAssert)checkInt(this,value,offset,2,32767,-32768);if(Buffer.TYPED_ARRAY_SUPPORT){this[offset]=value;this[offset+1]=value>>>8}else objectWriteUInt16(this,value,offset,true);return offset+2};Buffer.prototype.writeInt16BE=function(value,offset,noAssert){value=+value;offset=offset>>>0;if(!noAssert)checkInt(this,value,offset,2,32767,-32768);if(Buffer.TYPED_ARRAY_SUPPORT){this[offset]=value>>>8;this[offset+1]=value}else objectWriteUInt16(this,value,offset,false);return offset+2};Buffer.prototype.writeInt32LE=function(value,offset,noAssert){value=+value;offset=offset>>>0;if(!noAssert)checkInt(this,value,offset,4,2147483647,-2147483648);if(Buffer.TYPED_ARRAY_SUPPORT){this[offset]=value;this[offset+1]=value>>>8;this[offset+2]=value>>>16;this[offset+3]=value>>>24}else objectWriteUInt32(this,value,offset,true);return offset+4};Buffer.prototype.writeInt32BE=function(value,offset,noAssert){value=+value;offset=offset>>>0;if(!noAssert)checkInt(this,value,offset,4,2147483647,-2147483648);if(value<0)value=4294967295+value+1;if(Buffer.TYPED_ARRAY_SUPPORT){this[offset]=value>>>24;this[offset+1]=value>>>16;this[offset+2]=value>>>8;this[offset+3]=value}else objectWriteUInt32(this,value,offset,false);return offset+4};function checkIEEE754(buf,value,offset,ext,max,min){if(value>max||value<min)throw new RangeError("value is out of bounds");if(offset+ext>buf.length)throw new RangeError("index out of range");if(offset<0)throw new RangeError("index out of range")}function writeFloat(buf,value,offset,littleEndian,noAssert){if(!noAssert)checkIEEE754(buf,value,offset,4,3.4028234663852886e38,-3.4028234663852886e38);ieee754.write(buf,value,offset,littleEndian,23,4);return offset+4}Buffer.prototype.writeFloatLE=function(value,offset,noAssert){return writeFloat(this,value,offset,true,noAssert)};Buffer.prototype.writeFloatBE=function(value,offset,noAssert){return writeFloat(this,value,offset,false,noAssert)};function writeDouble(buf,value,offset,littleEndian,noAssert){if(!noAssert)checkIEEE754(buf,value,offset,8,1.7976931348623157e308,-1.7976931348623157e308);ieee754.write(buf,value,offset,littleEndian,52,8);return offset+8}Buffer.prototype.writeDoubleLE=function(value,offset,noAssert){return writeDouble(this,value,offset,true,noAssert)};Buffer.prototype.writeDoubleBE=function(value,offset,noAssert){return writeDouble(this,value,offset,false,noAssert)};Buffer.prototype.copy=function(target,target_start,start,end){var self=this;if(!start)start=0;if(!end&&end!==0)end=this.length;if(target_start>=target.length)target_start=target.length;if(!target_start)target_start=0;if(end>0&&end<start)end=start;if(end===start)return 0;if(target.length===0||self.length===0)return 0;if(target_start<0)throw new RangeError("targetStart out of bounds");if(start<0||start>=self.length)throw new RangeError("sourceStart out of bounds");if(end<0)throw new RangeError("sourceEnd out of bounds");if(end>this.length)end=this.length;if(target.length-target_start<end-start)end=target.length-target_start+start;var len=end-start;if(len<1e3||!Buffer.TYPED_ARRAY_SUPPORT){for(var i=0;i<len;i++){target[i+target_start]=this[i+start]}}else{target._set(this.subarray(start,start+len),target_start)}return len};Buffer.prototype.fill=function(value,start,end){if(!value)value=0;if(!start)start=0;if(!end)end=this.length;if(end<start)throw new RangeError("end < start");if(end===start)return;if(this.length===0)return;if(start<0||start>=this.length)throw new RangeError("start out of bounds");if(end<0||end>this.length)throw new RangeError("end out of bounds");var i;if(typeof value==="number"){for(i=start;i<end;i++){this[i]=value}}else{var bytes=utf8ToBytes(value.toString());var len=bytes.length;for(i=start;i<end;i++){this[i]=bytes[i%len]}}return this};Buffer.prototype.toArrayBuffer=function(){if(typeof Uint8Array!=="undefined"){if(Buffer.TYPED_ARRAY_SUPPORT){return new Buffer(this).buffer}else{var buf=new Uint8Array(this.length);for(var i=0,len=buf.length;i<len;i+=1){buf[i]=this[i]}return buf.buffer}}else{throw new TypeError("Buffer.toArrayBuffer not supported in this browser")}};var BP=Buffer.prototype;Buffer._augment=function(arr){arr.constructor=Buffer;arr._isBuffer=true;arr._get=arr.get;arr._set=arr.set;arr.get=BP.get;arr.set=BP.set;arr.write=BP.write;arr.toString=BP.toString;arr.toLocaleString=BP.toString;arr.toJSON=BP.toJSON;arr.equals=BP.equals;arr.compare=BP.compare;arr.copy=BP.copy;arr.slice=BP.slice;arr.readUIntLE=BP.readUIntLE;arr.readUIntBE=BP.readUIntBE;arr.readUInt8=BP.readUInt8;arr.readUInt16LE=BP.readUInt16LE;arr.readUInt16BE=BP.readUInt16BE;arr.readUInt32LE=BP.readUInt32LE;arr.readUInt32BE=BP.readUInt32BE;arr.readIntLE=BP.readIntLE;arr.readIntBE=BP.readIntBE;arr.readInt8=BP.readInt8;arr.readInt16LE=BP.readInt16LE;arr.readInt16BE=BP.readInt16BE;arr.readInt32LE=BP.readInt32LE;arr.readInt32BE=BP.readInt32BE;arr.readFloatLE=BP.readFloatLE;arr.readFloatBE=BP.readFloatBE;arr.readDoubleLE=BP.readDoubleLE;arr.readDoubleBE=BP.readDoubleBE;arr.writeUInt8=BP.writeUInt8;arr.writeUIntLE=BP.writeUIntLE;arr.writeUIntBE=BP.writeUIntBE;arr.writeUInt16LE=BP.writeUInt16LE;arr.writeUInt16BE=BP.writeUInt16BE;arr.writeUInt32LE=BP.writeUInt32LE;arr.writeUInt32BE=BP.writeUInt32BE;arr.writeIntLE=BP.writeIntLE;arr.writeIntBE=BP.writeIntBE;arr.writeInt8=BP.writeInt8;arr.writeInt16LE=BP.writeInt16LE;arr.writeInt16BE=BP.writeInt16BE;arr.writeInt32LE=BP.writeInt32LE;arr.writeInt32BE=BP.writeInt32BE;arr.writeFloatLE=BP.writeFloatLE;arr.writeFloatBE=BP.writeFloatBE;arr.writeDoubleLE=BP.writeDoubleLE;arr.writeDoubleBE=BP.writeDoubleBE;arr.fill=BP.fill;arr.inspect=BP.inspect;arr.toArrayBuffer=BP.toArrayBuffer;return arr};var INVALID_BASE64_RE=/[^+\/0-9A-z\-]/g;function base64clean(str){str=stringtrim(str).replace(INVALID_BASE64_RE,"");if(str.length<2)return"";while(str.length%4!==0){str=str+"="}return str}function stringtrim(str){if(str.trim)return str.trim();return str.replace(/^\s+|\s+$/g,"")}function isArrayish(subject){return isArray(subject)||Buffer.isBuffer(subject)||subject&&typeof subject==="object"&&typeof subject.length==="number"}function toHex(n){if(n<16)return"0"+n.toString(16);return n.toString(16)}function utf8ToBytes(string,units){units=units||Infinity;var codePoint;var length=string.length;var leadSurrogate=null;var bytes=[];var i=0;for(;i<length;i++){codePoint=string.charCodeAt(i);if(codePoint>55295&&codePoint<57344){if(leadSurrogate){if(codePoint<56320){if((units-=3)>-1)bytes.push(239,191,189);leadSurrogate=codePoint;continue}else{codePoint=leadSurrogate-55296<<10|codePoint-56320|65536;leadSurrogate=null}}else{if(codePoint>56319){if((units-=3)>-1)bytes.push(239,191,189);continue}else if(i+1===length){if((units-=3)>-1)bytes.push(239,191,189);continue}else{leadSurrogate=codePoint;continue}}}else if(leadSurrogate){if((units-=3)>-1)bytes.push(239,191,189);leadSurrogate=null}if(codePoint<128){if((units-=1)<0)break;bytes.push(codePoint)}else if(codePoint<2048){if((units-=2)<0)break;bytes.push(codePoint>>6|192,codePoint&63|128)}else if(codePoint<65536){if((units-=3)<0)break;bytes.push(codePoint>>12|224,codePoint>>6&63|128,codePoint&63|128)}else if(codePoint<2097152){if((units-=4)<0)break;bytes.push(codePoint>>18|240,codePoint>>12&63|128,codePoint>>6&63|128,codePoint&63|128)}else{throw new Error("Invalid code point")}}return bytes}function asciiToBytes(str){var byteArray=[];for(var i=0;i<str.length;i++){byteArray.push(str.charCodeAt(i)&255)}return byteArray}function utf16leToBytes(str,units){var c,hi,lo;var byteArray=[];for(var i=0;i<str.length;i++){if((units-=2)<0)break;c=str.charCodeAt(i);hi=c>>8;lo=c%256;byteArray.push(lo);byteArray.push(hi)}return byteArray}function base64ToBytes(str){return base64.toByteArray(base64clean(str))}function blitBuffer(src,dst,offset,length){for(var i=0;i<length;i++){if(i+offset>=dst.length||i>=src.length)break;dst[i+offset]=src[i]}return i}function decodeUtf8Char(str){try{return decodeURIComponent(str)}catch(err){return String.fromCharCode(65533)}}},{"base64-js":144,ieee754:145,"is-array":146}],144:[function(require,module,exports){var lookup="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";(function(exports){"use strict";var Arr=typeof Uint8Array!=="undefined"?Uint8Array:Array;var PLUS="+".charCodeAt(0);var SLASH="/".charCodeAt(0);var NUMBER="0".charCodeAt(0);var LOWER="a".charCodeAt(0);var UPPER="A".charCodeAt(0);var PLUS_URL_SAFE="-".charCodeAt(0);var SLASH_URL_SAFE="_".charCodeAt(0);function decode(elt){var code=elt.charCodeAt(0);if(code===PLUS||code===PLUS_URL_SAFE)return 62;if(code===SLASH||code===SLASH_URL_SAFE)return 63;if(code<NUMBER)return-1;if(code<NUMBER+10)return code-NUMBER+26+26;if(code<UPPER+26)return code-UPPER;if(code<LOWER+26)return code-LOWER+26}function b64ToByteArray(b64){var i,j,l,tmp,placeHolders,arr;if(b64.length%4>0){throw new Error("Invalid string. Length must be a multiple of 4")}var len=b64.length;placeHolders="="===b64.charAt(len-2)?2:"="===b64.charAt(len-1)?1:0;arr=new Arr(b64.length*3/4-placeHolders);l=placeHolders>0?b64.length-4:b64.length;var L=0;function push(v){arr[L++]=v}for(i=0,j=0;i<l;i+=4,j+=3){tmp=decode(b64.charAt(i))<<18|decode(b64.charAt(i+1))<<12|decode(b64.charAt(i+2))<<6|decode(b64.charAt(i+3));push((tmp&16711680)>>16);push((tmp&65280)>>8);push(tmp&255)}if(placeHolders===2){tmp=decode(b64.charAt(i))<<2|decode(b64.charAt(i+1))>>4;push(tmp&255)}else if(placeHolders===1){tmp=decode(b64.charAt(i))<<10|decode(b64.charAt(i+1))<<4|decode(b64.charAt(i+2))>>2;push(tmp>>8&255);push(tmp&255)}return arr}function uint8ToBase64(uint8){var i,extraBytes=uint8.length%3,output="",temp,length;function encode(num){return lookup.charAt(num)}function tripletToBase64(num){return encode(num>>18&63)+encode(num>>12&63)+encode(num>>6&63)+encode(num&63)}for(i=0,length=uint8.length-extraBytes;i<length;i+=3){temp=(uint8[i]<<16)+(uint8[i+1]<<8)+uint8[i+2];output+=tripletToBase64(temp)}switch(extraBytes){case 1:temp=uint8[uint8.length-1];output+=encode(temp>>2);output+=encode(temp<<4&63);output+="==";break;case 2:temp=(uint8[uint8.length-2]<<8)+uint8[uint8.length-1];output+=encode(temp>>10);output+=encode(temp>>4&63);output+=encode(temp<<2&63);output+="=";break}return output}exports.toByteArray=b64ToByteArray;exports.fromByteArray=uint8ToBase64})(typeof exports==="undefined"?this.base64js={}:exports)},{}],145:[function(require,module,exports){exports.read=function(buffer,offset,isLE,mLen,nBytes){var e,m,eLen=nBytes*8-mLen-1,eMax=(1<<eLen)-1,eBias=eMax>>1,nBits=-7,i=isLE?nBytes-1:0,d=isLE?-1:1,s=buffer[offset+i];i+=d;e=s&(1<<-nBits)-1;s>>=-nBits;nBits+=eLen;for(;nBits>0;e=e*256+buffer[offset+i],i+=d,nBits-=8);m=e&(1<<-nBits)-1;e>>=-nBits;nBits+=mLen;for(;nBits>0;m=m*256+buffer[offset+i],i+=d,nBits-=8);if(e===0){e=1-eBias}else if(e===eMax){return m?NaN:(s?-1:1)*Infinity}else{m=m+Math.pow(2,mLen);e=e-eBias}return(s?-1:1)*m*Math.pow(2,e-mLen)};exports.write=function(buffer,value,offset,isLE,mLen,nBytes){var e,m,c,eLen=nBytes*8-mLen-1,eMax=(1<<eLen)-1,eBias=eMax>>1,rt=mLen===23?Math.pow(2,-24)-Math.pow(2,-77):0,i=isLE?0:nBytes-1,d=isLE?1:-1,s=value<0||value===0&&1/value<0?1:0;value=Math.abs(value);if(isNaN(value)||value===Infinity){m=isNaN(value)?1:0;e=eMax}else{e=Math.floor(Math.log(value)/Math.LN2);if(value*(c=Math.pow(2,-e))<1){e--;c*=2}if(e+eBias>=1){value+=rt/c}else{value+=rt*Math.pow(2,1-eBias)}if(value*c>=2){e++;c/=2}if(e+eBias>=eMax){m=0;e=eMax}else if(e+eBias>=1){m=(value*c-1)*Math.pow(2,mLen);e=e+eBias}else{m=value*Math.pow(2,eBias-1)*Math.pow(2,mLen);e=0}}for(;mLen>=8;buffer[offset+i]=m&255,i+=d,m/=256,mLen-=8);e=e<<mLen|m;eLen+=mLen;for(;eLen>0;buffer[offset+i]=e&255,i+=d,e/=256,eLen-=8);buffer[offset+i-d]|=s*128}},{}],146:[function(require,module,exports){var isArray=Array.isArray;var str=Object.prototype.toString;module.exports=isArray||function(val){return!!val&&"[object Array]"==str.call(val)}},{}],147:[function(require,module,exports){function EventEmitter(){this._events=this._events||{};this._maxListeners=this._maxListeners||undefined}module.exports=EventEmitter;EventEmitter.EventEmitter=EventEmitter;EventEmitter.prototype._events=undefined;EventEmitter.prototype._maxListeners=undefined;EventEmitter.defaultMaxListeners=10;EventEmitter.prototype.setMaxListeners=function(n){if(!isNumber(n)||n<0||isNaN(n))throw TypeError("n must be a positive number");this._maxListeners=n;return this};EventEmitter.prototype.emit=function(type){var er,handler,len,args,i,listeners;if(!this._events)this._events={};if(type==="error"){if(!this._events.error||isObject(this._events.error)&&!this._events.error.length){er=arguments[1];if(er instanceof Error){throw er}throw TypeError('Uncaught, unspecified "error" event.')}}handler=this._events[type];if(isUndefined(handler))return false;if(isFunction(handler)){switch(arguments.length){case 1:handler.call(this);break;case 2:handler.call(this,arguments[1]);break;case 3:handler.call(this,arguments[1],arguments[2]);break;default:len=arguments.length;args=new Array(len-1);for(i=1;i<len;i++)args[i-1]=arguments[i];handler.apply(this,args)}}else if(isObject(handler)){len=arguments.length;args=new Array(len-1);for(i=1;i<len;i++)args[i-1]=arguments[i];listeners=handler.slice();len=listeners.length;for(i=0;i<len;i++)listeners[i].apply(this,args)}return true};EventEmitter.prototype.addListener=function(type,listener){var m;if(!isFunction(listener))throw TypeError("listener must be a function");if(!this._events)this._events={};if(this._events.newListener)this.emit("newListener",type,isFunction(listener.listener)?listener.listener:listener);if(!this._events[type])this._events[type]=listener;else if(isObject(this._events[type]))this._events[type].push(listener);else this._events[type]=[this._events[type],listener];if(isObject(this._events[type])&&!this._events[type].warned){var m;if(!isUndefined(this._maxListeners)){m=this._maxListeners}else{m=EventEmitter.defaultMaxListeners}if(m&&m>0&&this._events[type].length>m){this._events[type].warned=true;console.error("(node) warning: possible EventEmitter memory "+"leak detected. %d listeners added. "+"Use emitter.setMaxListeners() to increase limit.",this._events[type].length);if(typeof console.trace==="function"){console.trace()}}}return this};EventEmitter.prototype.on=EventEmitter.prototype.addListener;EventEmitter.prototype.once=function(type,listener){if(!isFunction(listener))throw TypeError("listener must be a function");var fired=false;function g(){this.removeListener(type,g);if(!fired){fired=true;listener.apply(this,arguments)}}g.listener=listener;this.on(type,g);return this};EventEmitter.prototype.removeListener=function(type,listener){var list,position,length,i;if(!isFunction(listener))throw TypeError("listener must be a function");if(!this._events||!this._events[type])return this;list=this._events[type];length=list.length;position=-1;if(list===listener||isFunction(list.listener)&&list.listener===listener){delete this._events[type];if(this._events.removeListener)this.emit("removeListener",type,listener)}else if(isObject(list)){for(i=length;i-->0;){if(list[i]===listener||list[i].listener&&list[i].listener===listener){position=i;break}}if(position<0)return this;if(list.length===1){list.length=0;delete this._events[type]}else{list.splice(position,1)}if(this._events.removeListener)this.emit("removeListener",type,listener)}return this};EventEmitter.prototype.removeAllListeners=function(type){var key,listeners; if(!this._events)return this;if(!this._events.removeListener){if(arguments.length===0)this._events={};else if(this._events[type])delete this._events[type];return this}if(arguments.length===0){for(key in this._events){if(key==="removeListener")continue;this.removeAllListeners(key)}this.removeAllListeners("removeListener");this._events={};return this}listeners=this._events[type];if(isFunction(listeners)){this.removeListener(type,listeners)}else{while(listeners.length)this.removeListener(type,listeners[listeners.length-1])}delete this._events[type];return this};EventEmitter.prototype.listeners=function(type){var ret;if(!this._events||!this._events[type])ret=[];else if(isFunction(this._events[type]))ret=[this._events[type]];else ret=this._events[type].slice();return ret};EventEmitter.listenerCount=function(emitter,type){var ret;if(!emitter._events||!emitter._events[type])ret=0;else if(isFunction(emitter._events[type]))ret=1;else ret=emitter._events[type].length;return ret};function isFunction(arg){return typeof arg==="function"}function isNumber(arg){return typeof arg==="number"}function isObject(arg){return typeof arg==="object"&&arg!==null}function isUndefined(arg){return arg===void 0}},{}],148:[function(require,module,exports){if(typeof Object.create==="function"){module.exports=function inherits(ctor,superCtor){ctor.super_=superCtor;ctor.prototype=Object.create(superCtor.prototype,{constructor:{value:ctor,enumerable:false,writable:true,configurable:true}})}}else{module.exports=function inherits(ctor,superCtor){ctor.super_=superCtor;var TempCtor=function(){};TempCtor.prototype=superCtor.prototype;ctor.prototype=new TempCtor;ctor.prototype.constructor=ctor}}},{}],149:[function(require,module,exports){module.exports=Array.isArray||function(arr){return Object.prototype.toString.call(arr)=="[object Array]"}},{}],150:[function(require,module,exports){(function(process){function normalizeArray(parts,allowAboveRoot){var up=0;for(var i=parts.length-1;i>=0;i--){var last=parts[i];if(last==="."){parts.splice(i,1)}else if(last===".."){parts.splice(i,1);up++}else if(up){parts.splice(i,1);up--}}if(allowAboveRoot){for(;up--;up){parts.unshift("..")}}return parts}var splitPathRe=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/;var splitPath=function(filename){return splitPathRe.exec(filename).slice(1)};exports.resolve=function(){var resolvedPath="",resolvedAbsolute=false;for(var i=arguments.length-1;i>=-1&&!resolvedAbsolute;i--){var path=i>=0?arguments[i]:process.cwd();if(typeof path!=="string"){throw new TypeError("Arguments to path.resolve must be strings")}else if(!path){continue}resolvedPath=path+"/"+resolvedPath;resolvedAbsolute=path.charAt(0)==="/"}resolvedPath=normalizeArray(filter(resolvedPath.split("/"),function(p){return!!p}),!resolvedAbsolute).join("/");return(resolvedAbsolute?"/":"")+resolvedPath||"."};exports.normalize=function(path){var isAbsolute=exports.isAbsolute(path),trailingSlash=substr(path,-1)==="/";path=normalizeArray(filter(path.split("/"),function(p){return!!p}),!isAbsolute).join("/");if(!path&&!isAbsolute){path="."}if(path&&trailingSlash){path+="/"}return(isAbsolute?"/":"")+path};exports.isAbsolute=function(path){return path.charAt(0)==="/"};exports.join=function(){var paths=Array.prototype.slice.call(arguments,0);return exports.normalize(filter(paths,function(p,index){if(typeof p!=="string"){throw new TypeError("Arguments to path.join must be strings")}return p}).join("/"))};exports.relative=function(from,to){from=exports.resolve(from).substr(1);to=exports.resolve(to).substr(1);function trim(arr){var start=0;for(;start<arr.length;start++){if(arr[start]!=="")break}var end=arr.length-1;for(;end>=0;end--){if(arr[end]!=="")break}if(start>end)return[];return arr.slice(start,end-start+1)}var fromParts=trim(from.split("/"));var toParts=trim(to.split("/"));var length=Math.min(fromParts.length,toParts.length);var samePartsLength=length;for(var i=0;i<length;i++){if(fromParts[i]!==toParts[i]){samePartsLength=i;break}}var outputParts=[];for(var i=samePartsLength;i<fromParts.length;i++){outputParts.push("..")}outputParts=outputParts.concat(toParts.slice(samePartsLength));return outputParts.join("/")};exports.sep="/";exports.delimiter=":";exports.dirname=function(path){var result=splitPath(path),root=result[0],dir=result[1];if(!root&&!dir){return"."}if(dir){dir=dir.substr(0,dir.length-1)}return root+dir};exports.basename=function(path,ext){var f=splitPath(path)[2];if(ext&&f.substr(-1*ext.length)===ext){f=f.substr(0,f.length-ext.length)}return f};exports.extname=function(path){return splitPath(path)[3]};function filter(xs,f){if(xs.filter)return xs.filter(f);var res=[];for(var i=0;i<xs.length;i++){if(f(xs[i],i,xs))res.push(xs[i])}return res}var substr="ab".substr(-1)==="b"?function(str,start,len){return str.substr(start,len)}:function(str,start,len){if(start<0)start=str.length+start;return str.substr(start,len)}}).call(this,require("_process"))},{_process:151}],151:[function(require,module,exports){var process=module.exports={};var queue=[];var draining=false;function drainQueue(){if(draining){return}draining=true;var currentQueue;var len=queue.length;while(len){currentQueue=queue;queue=[];var i=-1;while(++i<len){currentQueue[i]()}len=queue.length}draining=false}process.nextTick=function(fun){queue.push(fun);if(!draining){setTimeout(drainQueue,0)}};process.title="browser";process.browser=true;process.env={};process.argv=[];process.version="";function noop(){}process.on=noop;process.addListener=noop;process.once=noop;process.off=noop;process.removeListener=noop;process.removeAllListeners=noop;process.emit=noop;process.binding=function(name){throw new Error("process.binding is not supported")};process.cwd=function(){return"/"};process.chdir=function(dir){throw new Error("process.chdir is not supported")};process.umask=function(){return 0}},{}],152:[function(require,module,exports){module.exports=require("./lib/_stream_duplex.js")},{"./lib/_stream_duplex.js":153}],153:[function(require,module,exports){(function(process){module.exports=Duplex;var objectKeys=Object.keys||function(obj){var keys=[];for(var key in obj)keys.push(key);return keys};var util=require("core-util-is");util.inherits=require("inherits");var Readable=require("./_stream_readable");var Writable=require("./_stream_writable");util.inherits(Duplex,Readable);forEach(objectKeys(Writable.prototype),function(method){if(!Duplex.prototype[method])Duplex.prototype[method]=Writable.prototype[method]});function Duplex(options){if(!(this instanceof Duplex))return new Duplex(options);Readable.call(this,options);Writable.call(this,options);if(options&&options.readable===false)this.readable=false;if(options&&options.writable===false)this.writable=false;this.allowHalfOpen=true;if(options&&options.allowHalfOpen===false)this.allowHalfOpen=false;this.once("end",onend)}function onend(){if(this.allowHalfOpen||this._writableState.ended)return;process.nextTick(this.end.bind(this))}function forEach(xs,f){for(var i=0,l=xs.length;i<l;i++){f(xs[i],i)}}}).call(this,require("_process"))},{"./_stream_readable":155,"./_stream_writable":157,_process:151,"core-util-is":158,inherits:148}],154:[function(require,module,exports){module.exports=PassThrough;var Transform=require("./_stream_transform");var util=require("core-util-is");util.inherits=require("inherits");util.inherits(PassThrough,Transform);function PassThrough(options){if(!(this instanceof PassThrough))return new PassThrough(options);Transform.call(this,options)}PassThrough.prototype._transform=function(chunk,encoding,cb){cb(null,chunk)}},{"./_stream_transform":156,"core-util-is":158,inherits:148}],155:[function(require,module,exports){(function(process){module.exports=Readable;var isArray=require("isarray");var Buffer=require("buffer").Buffer;Readable.ReadableState=ReadableState;var EE=require("events").EventEmitter;if(!EE.listenerCount)EE.listenerCount=function(emitter,type){return emitter.listeners(type).length};var Stream=require("stream");var util=require("core-util-is");util.inherits=require("inherits");var StringDecoder;var debug=require("util");if(debug&&debug.debuglog){debug=debug.debuglog("stream")}else{debug=function(){}}util.inherits(Readable,Stream);function ReadableState(options,stream){var Duplex=require("./_stream_duplex");options=options||{};var hwm=options.highWaterMark;var defaultHwm=options.objectMode?16:16*1024;this.highWaterMark=hwm||hwm===0?hwm:defaultHwm;this.highWaterMark=~~this.highWaterMark;this.buffer=[];this.length=0;this.pipes=null;this.pipesCount=0;this.flowing=null;this.ended=false;this.endEmitted=false;this.reading=false;this.sync=true;this.needReadable=false;this.emittedReadable=false;this.readableListening=false;this.objectMode=!!options.objectMode;if(stream instanceof Duplex)this.objectMode=this.objectMode||!!options.readableObjectMode;this.defaultEncoding=options.defaultEncoding||"utf8";this.ranOut=false;this.awaitDrain=0;this.readingMore=false;this.decoder=null;this.encoding=null;if(options.encoding){if(!StringDecoder)StringDecoder=require("string_decoder/").StringDecoder;this.decoder=new StringDecoder(options.encoding);this.encoding=options.encoding}}function Readable(options){var Duplex=require("./_stream_duplex");if(!(this instanceof Readable))return new Readable(options);this._readableState=new ReadableState(options,this);this.readable=true;Stream.call(this)}Readable.prototype.push=function(chunk,encoding){var state=this._readableState;if(util.isString(chunk)&&!state.objectMode){encoding=encoding||state.defaultEncoding;if(encoding!==state.encoding){chunk=new Buffer(chunk,encoding);encoding=""}}return readableAddChunk(this,state,chunk,encoding,false)};Readable.prototype.unshift=function(chunk){var state=this._readableState;return readableAddChunk(this,state,chunk,"",true)};function readableAddChunk(stream,state,chunk,encoding,addToFront){var er=chunkInvalid(state,chunk);if(er){stream.emit("error",er)}else if(util.isNullOrUndefined(chunk)){state.reading=false;if(!state.ended)onEofChunk(stream,state)}else if(state.objectMode||chunk&&chunk.length>0){if(state.ended&&!addToFront){var e=new Error("stream.push() after EOF");stream.emit("error",e)}else if(state.endEmitted&&addToFront){var e=new Error("stream.unshift() after end event");stream.emit("error",e)}else{if(state.decoder&&!addToFront&&!encoding)chunk=state.decoder.write(chunk);if(!addToFront)state.reading=false;if(state.flowing&&state.length===0&&!state.sync){stream.emit("data",chunk);stream.read(0)}else{state.length+=state.objectMode?1:chunk.length;if(addToFront)state.buffer.unshift(chunk);else state.buffer.push(chunk);if(state.needReadable)emitReadable(stream)}maybeReadMore(stream,state)}}else if(!addToFront){state.reading=false}return needMoreData(state)}function needMoreData(state){return!state.ended&&(state.needReadable||state.length<state.highWaterMark||state.length===0)}Readable.prototype.setEncoding=function(enc){if(!StringDecoder)StringDecoder=require("string_decoder/").StringDecoder;this._readableState.decoder=new StringDecoder(enc);this._readableState.encoding=enc;return this};var MAX_HWM=8388608;function roundUpToNextPowerOf2(n){if(n>=MAX_HWM){n=MAX_HWM}else{n--;for(var p=1;p<32;p<<=1)n|=n>>p;n++}return n}function howMuchToRead(n,state){if(state.length===0&&state.ended)return 0;if(state.objectMode)return n===0?0:1;if(isNaN(n)||util.isNull(n)){if(state.flowing&&state.buffer.length)return state.buffer[0].length;else return state.length}if(n<=0)return 0;if(n>state.highWaterMark)state.highWaterMark=roundUpToNextPowerOf2(n);if(n>state.length){if(!state.ended){state.needReadable=true;return 0}else return state.length}return n}Readable.prototype.read=function(n){debug("read",n);var state=this._readableState;var nOrig=n;if(!util.isNumber(n)||n>0)state.emittedReadable=false;if(n===0&&state.needReadable&&(state.length>=state.highWaterMark||state.ended)){debug("read: emitReadable",state.length,state.ended);if(state.length===0&&state.ended)endReadable(this);else emitReadable(this);return null}n=howMuchToRead(n,state);if(n===0&&state.ended){if(state.length===0)endReadable(this);return null}var doRead=state.needReadable;debug("need readable",doRead);if(state.length===0||state.length-n<state.highWaterMark){doRead=true;debug("length less than watermark",doRead)}if(state.ended||state.reading){doRead=false;debug("reading or ended",doRead)}if(doRead){debug("do read");state.reading=true;state.sync=true;if(state.length===0)state.needReadable=true;this._read(state.highWaterMark);state.sync=false}if(doRead&&!state.reading)n=howMuchToRead(nOrig,state);var ret;if(n>0)ret=fromList(n,state);else ret=null;if(util.isNull(ret)){state.needReadable=true;n=0}state.length-=n;if(state.length===0&&!state.ended)state.needReadable=true;if(nOrig!==n&&state.ended&&state.length===0)endReadable(this);if(!util.isNull(ret))this.emit("data",ret);return ret};function chunkInvalid(state,chunk){var er=null;if(!util.isBuffer(chunk)&&!util.isString(chunk)&&!util.isNullOrUndefined(chunk)&&!state.objectMode){er=new TypeError("Invalid non-string/buffer chunk")}return er}function onEofChunk(stream,state){if(state.decoder&&!state.ended){var chunk=state.decoder.end();if(chunk&&chunk.length){state.buffer.push(chunk);state.length+=state.objectMode?1:chunk.length}}state.ended=true;emitReadable(stream)}function emitReadable(stream){var state=stream._readableState;state.needReadable=false;if(!state.emittedReadable){debug("emitReadable",state.flowing);state.emittedReadable=true;if(state.sync)process.nextTick(function(){emitReadable_(stream)});else emitReadable_(stream)}}function emitReadable_(stream){debug("emit readable");stream.emit("readable");flow(stream)}function maybeReadMore(stream,state){if(!state.readingMore){state.readingMore=true;process.nextTick(function(){maybeReadMore_(stream,state)})}}function maybeReadMore_(stream,state){var len=state.length;while(!state.reading&&!state.flowing&&!state.ended&&state.length<state.highWaterMark){debug("maybeReadMore read 0");stream.read(0);if(len===state.length)break;else len=state.length}state.readingMore=false}Readable.prototype._read=function(n){this.emit("error",new Error("not implemented"))};Readable.prototype.pipe=function(dest,pipeOpts){var src=this;var state=this._readableState;switch(state.pipesCount){case 0:state.pipes=dest;break;case 1:state.pipes=[state.pipes,dest];break;default:state.pipes.push(dest);break}state.pipesCount+=1;debug("pipe count=%d opts=%j",state.pipesCount,pipeOpts);var doEnd=(!pipeOpts||pipeOpts.end!==false)&&dest!==process.stdout&&dest!==process.stderr;var endFn=doEnd?onend:cleanup;if(state.endEmitted)process.nextTick(endFn);else src.once("end",endFn);dest.on("unpipe",onunpipe);function onunpipe(readable){debug("onunpipe");if(readable===src){cleanup()}}function onend(){debug("onend");dest.end()}var ondrain=pipeOnDrain(src);dest.on("drain",ondrain);function cleanup(){debug("cleanup");dest.removeListener("close",onclose);dest.removeListener("finish",onfinish);dest.removeListener("drain",ondrain);dest.removeListener("error",onerror);dest.removeListener("unpipe",onunpipe);src.removeListener("end",onend);src.removeListener("end",cleanup);src.removeListener("data",ondata);if(state.awaitDrain&&(!dest._writableState||dest._writableState.needDrain))ondrain()}src.on("data",ondata);function ondata(chunk){debug("ondata");var ret=dest.write(chunk);if(false===ret){debug("false write response, pause",src._readableState.awaitDrain);src._readableState.awaitDrain++;src.pause()}}function onerror(er){debug("onerror",er);unpipe();dest.removeListener("error",onerror);if(EE.listenerCount(dest,"error")===0)dest.emit("error",er)}if(!dest._events||!dest._events.error)dest.on("error",onerror);else if(isArray(dest._events.error))dest._events.error.unshift(onerror);else dest._events.error=[onerror,dest._events.error];function onclose(){dest.removeListener("finish",onfinish);unpipe()}dest.once("close",onclose);function onfinish(){debug("onfinish");dest.removeListener("close",onclose);unpipe()}dest.once("finish",onfinish);function unpipe(){debug("unpipe");src.unpipe(dest)}dest.emit("pipe",src);if(!state.flowing){debug("pipe resume");src.resume()}return dest};function pipeOnDrain(src){return function(){var state=src._readableState;debug("pipeOnDrain",state.awaitDrain);if(state.awaitDrain)state.awaitDrain--;if(state.awaitDrain===0&&EE.listenerCount(src,"data")){state.flowing=true;flow(src)}}}Readable.prototype.unpipe=function(dest){var state=this._readableState;if(state.pipesCount===0)return this;if(state.pipesCount===1){if(dest&&dest!==state.pipes)return this;if(!dest)dest=state.pipes;state.pipes=null;state.pipesCount=0;state.flowing=false;if(dest)dest.emit("unpipe",this);return this}if(!dest){var dests=state.pipes;var len=state.pipesCount;state.pipes=null;state.pipesCount=0;state.flowing=false;for(var i=0;i<len;i++)dests[i].emit("unpipe",this);return this}var i=indexOf(state.pipes,dest);if(i===-1)return this;state.pipes.splice(i,1);state.pipesCount-=1;if(state.pipesCount===1)state.pipes=state.pipes[0];dest.emit("unpipe",this);return this};Readable.prototype.on=function(ev,fn){var res=Stream.prototype.on.call(this,ev,fn);if(ev==="data"&&false!==this._readableState.flowing){this.resume()}if(ev==="readable"&&this.readable){var state=this._readableState;if(!state.readableListening){state.readableListening=true;state.emittedReadable=false;state.needReadable=true;if(!state.reading){var self=this;process.nextTick(function(){debug("readable nexttick read 0");self.read(0)})}else if(state.length){emitReadable(this,state)}}}return res};Readable.prototype.addListener=Readable.prototype.on;Readable.prototype.resume=function(){var state=this._readableState;if(!state.flowing){debug("resume");state.flowing=true;if(!state.reading){debug("resume read 0");this.read(0)}resume(this,state)}return this};function resume(stream,state){if(!state.resumeScheduled){state.resumeScheduled=true;process.nextTick(function(){resume_(stream,state)})}}function resume_(stream,state){state.resumeScheduled=false;stream.emit("resume");flow(stream);if(state.flowing&&!state.reading)stream.read(0)}Readable.prototype.pause=function(){debug("call pause flowing=%j",this._readableState.flowing);if(false!==this._readableState.flowing){debug("pause");this._readableState.flowing=false;this.emit("pause")}return this};function flow(stream){var state=stream._readableState;debug("flow",state.flowing);if(state.flowing){do{var chunk=stream.read()}while(null!==chunk&&state.flowing)}}Readable.prototype.wrap=function(stream){var state=this._readableState;var paused=false;var self=this;stream.on("end",function(){debug("wrapped end");if(state.decoder&&!state.ended){var chunk=state.decoder.end();if(chunk&&chunk.length)self.push(chunk)}self.push(null)});stream.on("data",function(chunk){debug("wrapped data");if(state.decoder)chunk=state.decoder.write(chunk);if(!chunk||!state.objectMode&&!chunk.length)return;var ret=self.push(chunk);if(!ret){paused=true;stream.pause()}});for(var i in stream){if(util.isFunction(stream[i])&&util.isUndefined(this[i])){this[i]=function(method){return function(){return stream[method].apply(stream,arguments)}}(i)}}var events=["error","close","destroy","pause","resume"];forEach(events,function(ev){stream.on(ev,self.emit.bind(self,ev))});self._read=function(n){debug("wrapped _read",n);if(paused){paused=false;stream.resume()}};return self};Readable._fromList=fromList;function fromList(n,state){var list=state.buffer;var length=state.length;var stringMode=!!state.decoder;var objectMode=!!state.objectMode;var ret;if(list.length===0)return null;if(length===0)ret=null;else if(objectMode)ret=list.shift();else if(!n||n>=length){if(stringMode)ret=list.join("");else ret=Buffer.concat(list,length);list.length=0}else{if(n<list[0].length){var buf=list[0];ret=buf.slice(0,n);list[0]=buf.slice(n)}else if(n===list[0].length){ret=list.shift()}else{if(stringMode)ret="";else ret=new Buffer(n);var c=0;for(var i=0,l=list.length;i<l&&c<n;i++){var buf=list[0];var cpy=Math.min(n-c,buf.length);if(stringMode)ret+=buf.slice(0,cpy);else buf.copy(ret,c,0,cpy);if(cpy<buf.length)list[0]=buf.slice(cpy);else list.shift();c+=cpy}}}return ret}function endReadable(stream){var state=stream._readableState;if(state.length>0)throw new Error("endReadable called on non-empty stream");if(!state.endEmitted){state.ended=true;process.nextTick(function(){if(!state.endEmitted&&state.length===0){state.endEmitted=true;stream.readable=false;stream.emit("end")}})}}function forEach(xs,f){for(var i=0,l=xs.length;i<l;i++){f(xs[i],i)}}function indexOf(xs,x){for(var i=0,l=xs.length;i<l;i++){if(xs[i]===x)return i}return-1}}).call(this,require("_process"))},{"./_stream_duplex":153,_process:151,buffer:143,"core-util-is":158,events:147,inherits:148,isarray:149,stream:163,"string_decoder/":164,util:142}],156:[function(require,module,exports){module.exports=Transform;var Duplex=require("./_stream_duplex");var util=require("core-util-is");util.inherits=require("inherits");util.inherits(Transform,Duplex);function TransformState(options,stream){this.afterTransform=function(er,data){return afterTransform(stream,er,data)};this.needTransform=false;this.transforming=false;this.writecb=null;this.writechunk=null}function afterTransform(stream,er,data){var ts=stream._transformState;ts.transforming=false;var cb=ts.writecb;if(!cb)return stream.emit("error",new Error("no writecb in Transform class"));ts.writechunk=null;ts.writecb=null;if(!util.isNullOrUndefined(data))stream.push(data);if(cb)cb(er);var rs=stream._readableState;rs.reading=false;if(rs.needReadable||rs.length<rs.highWaterMark){stream._read(rs.highWaterMark)}}function Transform(options){if(!(this instanceof Transform))return new Transform(options);Duplex.call(this,options);this._transformState=new TransformState(options,this);var stream=this;this._readableState.needReadable=true;this._readableState.sync=false;this.once("prefinish",function(){if(util.isFunction(this._flush))this._flush(function(er){done(stream,er)});else done(stream)})}Transform.prototype.push=function(chunk,encoding){this._transformState.needTransform=false;return Duplex.prototype.push.call(this,chunk,encoding)};Transform.prototype._transform=function(chunk,encoding,cb){throw new Error("not implemented")};Transform.prototype._write=function(chunk,encoding,cb){var ts=this._transformState;ts.writecb=cb;ts.writechunk=chunk;ts.writeencoding=encoding;if(!ts.transforming){var rs=this._readableState;if(ts.needTransform||rs.needReadable||rs.length<rs.highWaterMark)this._read(rs.highWaterMark)}};Transform.prototype._read=function(n){var ts=this._transformState;if(!util.isNull(ts.writechunk)&&ts.writecb&&!ts.transforming){ts.transforming=true;this._transform(ts.writechunk,ts.writeencoding,ts.afterTransform)}else{ts.needTransform=true}};function done(stream,er){if(er)return stream.emit("error",er);var ws=stream._writableState;var ts=stream._transformState;if(ws.length)throw new Error("calling transform done when ws.length != 0");if(ts.transforming)throw new Error("calling transform done when still transforming");return stream.push(null)}},{"./_stream_duplex":153,"core-util-is":158,inherits:148}],157:[function(require,module,exports){(function(process){module.exports=Writable;var Buffer=require("buffer").Buffer;Writable.WritableState=WritableState;var util=require("core-util-is");util.inherits=require("inherits");var Stream=require("stream");util.inherits(Writable,Stream);function WriteReq(chunk,encoding,cb){this.chunk=chunk;this.encoding=encoding;this.callback=cb}function WritableState(options,stream){var Duplex=require("./_stream_duplex");options=options||{};var hwm=options.highWaterMark;var defaultHwm=options.objectMode?16:16*1024;this.highWaterMark=hwm||hwm===0?hwm:defaultHwm;this.objectMode=!!options.objectMode;if(stream instanceof Duplex)this.objectMode=this.objectMode||!!options.writableObjectMode;this.highWaterMark=~~this.highWaterMark;this.needDrain=false;this.ending=false;this.ended=false;this.finished=false;var noDecode=options.decodeStrings===false;this.decodeStrings=!noDecode;this.defaultEncoding=options.defaultEncoding||"utf8";this.length=0;this.writing=false;this.corked=0;this.sync=true;this.bufferProcessing=false;this.onwrite=function(er){onwrite(stream,er)};this.writecb=null;this.writelen=0;this.buffer=[];this.pendingcb=0;this.prefinished=false;this.errorEmitted=false}function Writable(options){var Duplex=require("./_stream_duplex");if(!(this instanceof Writable)&&!(this instanceof Duplex))return new Writable(options);this._writableState=new WritableState(options,this);this.writable=true;Stream.call(this)}Writable.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe. Not readable."))};function writeAfterEnd(stream,state,cb){var er=new Error("write after end");stream.emit("error",er);process.nextTick(function(){cb(er)})}function validChunk(stream,state,chunk,cb){var valid=true;if(!util.isBuffer(chunk)&&!util.isString(chunk)&&!util.isNullOrUndefined(chunk)&&!state.objectMode){var er=new TypeError("Invalid non-string/buffer chunk");stream.emit("error",er);process.nextTick(function(){cb(er)});valid=false}return valid}Writable.prototype.write=function(chunk,encoding,cb){var state=this._writableState;var ret=false;if(util.isFunction(encoding)){cb=encoding;encoding=null}if(util.isBuffer(chunk))encoding="buffer";else if(!encoding)encoding=state.defaultEncoding;if(!util.isFunction(cb))cb=function(){};if(state.ended)writeAfterEnd(this,state,cb);else if(validChunk(this,state,chunk,cb)){state.pendingcb++;ret=writeOrBuffer(this,state,chunk,encoding,cb)}return ret};Writable.prototype.cork=function(){var state=this._writableState;state.corked++};Writable.prototype.uncork=function(){var state=this._writableState;if(state.corked){state.corked--;if(!state.writing&&!state.corked&&!state.finished&&!state.bufferProcessing&&state.buffer.length)clearBuffer(this,state)}};function decodeChunk(state,chunk,encoding){if(!state.objectMode&&state.decodeStrings!==false&&util.isString(chunk)){chunk=new Buffer(chunk,encoding)}return chunk}function writeOrBuffer(stream,state,chunk,encoding,cb){chunk=decodeChunk(state,chunk,encoding);if(util.isBuffer(chunk))encoding="buffer";var len=state.objectMode?1:chunk.length;state.length+=len;var ret=state.length<state.highWaterMark;if(!ret)state.needDrain=true;if(state.writing||state.corked)state.buffer.push(new WriteReq(chunk,encoding,cb));else doWrite(stream,state,false,len,chunk,encoding,cb);return ret}function doWrite(stream,state,writev,len,chunk,encoding,cb){state.writelen=len;state.writecb=cb;state.writing=true;state.sync=true;if(writev)stream._writev(chunk,state.onwrite);else stream._write(chunk,encoding,state.onwrite);state.sync=false}function onwriteError(stream,state,sync,er,cb){if(sync)process.nextTick(function(){state.pendingcb--;cb(er)});else{state.pendingcb--;cb(er)}stream._writableState.errorEmitted=true;stream.emit("error",er)}function onwriteStateUpdate(state){state.writing=false;state.writecb=null;state.length-=state.writelen;state.writelen=0}function onwrite(stream,er){var state=stream._writableState;var sync=state.sync;var cb=state.writecb;onwriteStateUpdate(state);if(er)onwriteError(stream,state,sync,er,cb);else{var finished=needFinish(stream,state);if(!finished&&!state.corked&&!state.bufferProcessing&&state.buffer.length){clearBuffer(stream,state)}if(sync){process.nextTick(function(){afterWrite(stream,state,finished,cb)})}else{afterWrite(stream,state,finished,cb)}}}function afterWrite(stream,state,finished,cb){if(!finished)onwriteDrain(stream,state);state.pendingcb--;cb();finishMaybe(stream,state)}function onwriteDrain(stream,state){if(state.length===0&&state.needDrain){state.needDrain=false;stream.emit("drain")}}function clearBuffer(stream,state){state.bufferProcessing=true;if(stream._writev&&state.buffer.length>1){var cbs=[];for(var c=0;c<state.buffer.length;c++)cbs.push(state.buffer[c].callback);state.pendingcb++;doWrite(stream,state,true,state.length,state.buffer,"",function(err){for(var i=0;i<cbs.length;i++){state.pendingcb--;cbs[i](err)}});state.buffer=[]}else{for(var c=0;c<state.buffer.length;c++){var entry=state.buffer[c];var chunk=entry.chunk;var encoding=entry.encoding;var cb=entry.callback;var len=state.objectMode?1:chunk.length;doWrite(stream,state,false,len,chunk,encoding,cb);if(state.writing){c++;break}}if(c<state.buffer.length)state.buffer=state.buffer.slice(c);else state.buffer.length=0}state.bufferProcessing=false}Writable.prototype._write=function(chunk,encoding,cb){cb(new Error("not implemented"))};Writable.prototype._writev=null;Writable.prototype.end=function(chunk,encoding,cb){var state=this._writableState;if(util.isFunction(chunk)){cb=chunk;chunk=null;encoding=null}else if(util.isFunction(encoding)){cb=encoding;encoding=null}if(!util.isNullOrUndefined(chunk))this.write(chunk,encoding);if(state.corked){state.corked=1;this.uncork()}if(!state.ending&&!state.finished)endWritable(this,state,cb)};function needFinish(stream,state){return state.ending&&state.length===0&&!state.finished&&!state.writing}function prefinish(stream,state){if(!state.prefinished){state.prefinished=true;stream.emit("prefinish")}}function finishMaybe(stream,state){var need=needFinish(stream,state);if(need){if(state.pendingcb===0){prefinish(stream,state);state.finished=true;stream.emit("finish")}else prefinish(stream,state)}return need}function endWritable(stream,state,cb){state.ending=true;finishMaybe(stream,state);if(cb){if(state.finished)process.nextTick(cb);else stream.once("finish",cb)}state.ended=true}}).call(this,require("_process"))},{"./_stream_duplex":153,_process:151,buffer:143,"core-util-is":158,inherits:148,stream:163}],158:[function(require,module,exports){(function(Buffer){function isArray(ar){return Array.isArray(ar)}exports.isArray=isArray;function isBoolean(arg){return typeof arg==="boolean"}exports.isBoolean=isBoolean;function isNull(arg){return arg===null}exports.isNull=isNull;function isNullOrUndefined(arg){return arg==null}exports.isNullOrUndefined=isNullOrUndefined;function isNumber(arg){return typeof arg==="number"}exports.isNumber=isNumber;function isString(arg){return typeof arg==="string"}exports.isString=isString;function isSymbol(arg){return typeof arg==="symbol"}exports.isSymbol=isSymbol;function isUndefined(arg){return arg===void 0}exports.isUndefined=isUndefined;function isRegExp(re){return isObject(re)&&objectToString(re)==="[object RegExp]"}exports.isRegExp=isRegExp;function isObject(arg){return typeof arg==="object"&&arg!==null}exports.isObject=isObject;function isDate(d){return isObject(d)&&objectToString(d)==="[object Date]"}exports.isDate=isDate;function isError(e){return isObject(e)&&(objectToString(e)==="[object Error]"||e instanceof Error)}exports.isError=isError;function isFunction(arg){return typeof arg==="function"}exports.isFunction=isFunction;function isPrimitive(arg){return arg===null||typeof arg==="boolean"||typeof arg==="number"||typeof arg==="string"||typeof arg==="symbol"||typeof arg==="undefined"}exports.isPrimitive=isPrimitive;function isBuffer(arg){return Buffer.isBuffer(arg)}exports.isBuffer=isBuffer;function objectToString(o){return Object.prototype.toString.call(o)}}).call(this,require("buffer").Buffer)},{buffer:143}],159:[function(require,module,exports){module.exports=require("./lib/_stream_passthrough.js")},{"./lib/_stream_passthrough.js":154}],160:[function(require,module,exports){exports=module.exports=require("./lib/_stream_readable.js");exports.Stream=require("stream");exports.Readable=exports;exports.Writable=require("./lib/_stream_writable.js");exports.Duplex=require("./lib/_stream_duplex.js");exports.Transform=require("./lib/_stream_transform.js");exports.PassThrough=require("./lib/_stream_passthrough.js")},{"./lib/_stream_duplex.js":153,"./lib/_stream_passthrough.js":154,"./lib/_stream_readable.js":155,"./lib/_stream_transform.js":156,"./lib/_stream_writable.js":157,stream:163}],161:[function(require,module,exports){module.exports=require("./lib/_stream_transform.js")},{"./lib/_stream_transform.js":156}],162:[function(require,module,exports){module.exports=require("./lib/_stream_writable.js") },{"./lib/_stream_writable.js":157}],163:[function(require,module,exports){module.exports=Stream;var EE=require("events").EventEmitter;var inherits=require("inherits");inherits(Stream,EE);Stream.Readable=require("readable-stream/readable.js");Stream.Writable=require("readable-stream/writable.js");Stream.Duplex=require("readable-stream/duplex.js");Stream.Transform=require("readable-stream/transform.js");Stream.PassThrough=require("readable-stream/passthrough.js");Stream.Stream=Stream;function Stream(){EE.call(this)}Stream.prototype.pipe=function(dest,options){var source=this;function ondata(chunk){if(dest.writable){if(false===dest.write(chunk)&&source.pause){source.pause()}}}source.on("data",ondata);function ondrain(){if(source.readable&&source.resume){source.resume()}}dest.on("drain",ondrain);if(!dest._isStdio&&(!options||options.end!==false)){source.on("end",onend);source.on("close",onclose)}var didOnEnd=false;function onend(){if(didOnEnd)return;didOnEnd=true;dest.end()}function onclose(){if(didOnEnd)return;didOnEnd=true;if(typeof dest.destroy==="function")dest.destroy()}function onerror(er){cleanup();if(EE.listenerCount(this,"error")===0){throw er}}source.on("error",onerror);dest.on("error",onerror);function cleanup(){source.removeListener("data",ondata);dest.removeListener("drain",ondrain);source.removeListener("end",onend);source.removeListener("close",onclose);source.removeListener("error",onerror);dest.removeListener("error",onerror);source.removeListener("end",cleanup);source.removeListener("close",cleanup);dest.removeListener("close",cleanup)}source.on("end",cleanup);source.on("close",cleanup);dest.on("close",cleanup);dest.emit("pipe",source);return dest}},{events:147,inherits:148,"readable-stream/duplex.js":152,"readable-stream/passthrough.js":159,"readable-stream/readable.js":160,"readable-stream/transform.js":161,"readable-stream/writable.js":162}],164:[function(require,module,exports){var Buffer=require("buffer").Buffer;var isBufferEncoding=Buffer.isEncoding||function(encoding){switch(encoding&&encoding.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return true;default:return false}};function assertEncoding(encoding){if(encoding&&!isBufferEncoding(encoding)){throw new Error("Unknown encoding: "+encoding)}}var StringDecoder=exports.StringDecoder=function(encoding){this.encoding=(encoding||"utf8").toLowerCase().replace(/[-_]/,"");assertEncoding(encoding);switch(this.encoding){case"utf8":this.surrogateSize=3;break;case"ucs2":case"utf16le":this.surrogateSize=2;this.detectIncompleteChar=utf16DetectIncompleteChar;break;case"base64":this.surrogateSize=3;this.detectIncompleteChar=base64DetectIncompleteChar;break;default:this.write=passThroughWrite;return}this.charBuffer=new Buffer(6);this.charReceived=0;this.charLength=0};StringDecoder.prototype.write=function(buffer){var charStr="";while(this.charLength){var available=buffer.length>=this.charLength-this.charReceived?this.charLength-this.charReceived:buffer.length;buffer.copy(this.charBuffer,this.charReceived,0,available);this.charReceived+=available;if(this.charReceived<this.charLength){return""}buffer=buffer.slice(available,buffer.length);charStr=this.charBuffer.slice(0,this.charLength).toString(this.encoding);var charCode=charStr.charCodeAt(charStr.length-1);if(charCode>=55296&&charCode<=56319){this.charLength+=this.surrogateSize;charStr="";continue}this.charReceived=this.charLength=0;if(buffer.length===0){return charStr}break}this.detectIncompleteChar(buffer);var end=buffer.length;if(this.charLength){buffer.copy(this.charBuffer,0,buffer.length-this.charReceived,end);end-=this.charReceived}charStr+=buffer.toString(this.encoding,0,end);var end=charStr.length-1;var charCode=charStr.charCodeAt(end);if(charCode>=55296&&charCode<=56319){var size=this.surrogateSize;this.charLength+=size;this.charReceived+=size;this.charBuffer.copy(this.charBuffer,size,0,size);buffer.copy(this.charBuffer,0,0,size);return charStr.substring(0,end)}return charStr};StringDecoder.prototype.detectIncompleteChar=function(buffer){var i=buffer.length>=3?3:buffer.length;for(;i>0;i--){var c=buffer[buffer.length-i];if(i==1&&c>>5==6){this.charLength=2;break}if(i<=2&&c>>4==14){this.charLength=3;break}if(i<=3&&c>>3==30){this.charLength=4;break}}this.charReceived=i};StringDecoder.prototype.end=function(buffer){var res="";if(buffer&&buffer.length)res=this.write(buffer);if(this.charReceived){var cr=this.charReceived;var buf=this.charBuffer;var enc=this.encoding;res+=buf.slice(0,cr).toString(enc)}return res};function passThroughWrite(buffer){return buffer.toString(this.encoding)}function utf16DetectIncompleteChar(buffer){this.charReceived=buffer.length%2;this.charLength=this.charReceived?2:0}function base64DetectIncompleteChar(buffer){this.charReceived=buffer.length%3;this.charLength=this.charReceived?3:0}},{buffer:143}],165:[function(require,module,exports){exports.isatty=function(){return false};function ReadStream(){throw new Error("tty.ReadStream is not implemented")}exports.ReadStream=ReadStream;function WriteStream(){throw new Error("tty.ReadStream is not implemented")}exports.WriteStream=WriteStream},{}],166:[function(require,module,exports){module.exports=function isBuffer(arg){return arg&&typeof arg==="object"&&typeof arg.copy==="function"&&typeof arg.fill==="function"&&typeof arg.readUInt8==="function"}},{}],167:[function(require,module,exports){(function(process,global){var formatRegExp=/%[sdj%]/g;exports.format=function(f){if(!isString(f)){var objects=[];for(var i=0;i<arguments.length;i++){objects.push(inspect(arguments[i]))}return objects.join(" ")}var i=1;var args=arguments;var len=args.length;var str=String(f).replace(formatRegExp,function(x){if(x==="%%")return"%";if(i>=len)return x;switch(x){case"%s":return String(args[i++]);case"%d":return Number(args[i++]);case"%j":try{return JSON.stringify(args[i++])}catch(_){return"[Circular]"}default:return x}});for(var x=args[i];i<len;x=args[++i]){if(isNull(x)||!isObject(x)){str+=" "+x}else{str+=" "+inspect(x)}}return str};exports.deprecate=function(fn,msg){if(isUndefined(global.process)){return function(){return exports.deprecate(fn,msg).apply(this,arguments)}}if(process.noDeprecation===true){return fn}var warned=false;function deprecated(){if(!warned){if(process.throwDeprecation){throw new Error(msg)}else if(process.traceDeprecation){console.trace(msg)}else{console.error(msg)}warned=true}return fn.apply(this,arguments)}return deprecated};var debugs={};var debugEnviron;exports.debuglog=function(set){if(isUndefined(debugEnviron))debugEnviron=process.env.NODE_DEBUG||"";set=set.toUpperCase();if(!debugs[set]){if(new RegExp("\\b"+set+"\\b","i").test(debugEnviron)){var pid=process.pid;debugs[set]=function(){var msg=exports.format.apply(exports,arguments);console.error("%s %d: %s",set,pid,msg)}}else{debugs[set]=function(){}}}return debugs[set]};function inspect(obj,opts){var ctx={seen:[],stylize:stylizeNoColor};if(arguments.length>=3)ctx.depth=arguments[2];if(arguments.length>=4)ctx.colors=arguments[3];if(isBoolean(opts)){ctx.showHidden=opts}else if(opts){exports._extend(ctx,opts)}if(isUndefined(ctx.showHidden))ctx.showHidden=false;if(isUndefined(ctx.depth))ctx.depth=2;if(isUndefined(ctx.colors))ctx.colors=false;if(isUndefined(ctx.customInspect))ctx.customInspect=true;if(ctx.colors)ctx.stylize=stylizeWithColor;return formatValue(ctx,obj,ctx.depth)}exports.inspect=inspect;inspect.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]};inspect.styles={special:"cyan",number:"yellow","boolean":"yellow",undefined:"grey","null":"bold",string:"green",date:"magenta",regexp:"red"};function stylizeWithColor(str,styleType){var style=inspect.styles[styleType];if(style){return"["+inspect.colors[style][0]+"m"+str+"["+inspect.colors[style][1]+"m"}else{return str}}function stylizeNoColor(str,styleType){return str}function arrayToHash(array){var hash={};array.forEach(function(val,idx){hash[val]=true});return hash}function formatValue(ctx,value,recurseTimes){if(ctx.customInspect&&value&&isFunction(value.inspect)&&value.inspect!==exports.inspect&&!(value.constructor&&value.constructor.prototype===value)){var ret=value.inspect(recurseTimes,ctx);if(!isString(ret)){ret=formatValue(ctx,ret,recurseTimes)}return ret}var primitive=formatPrimitive(ctx,value);if(primitive){return primitive}var keys=Object.keys(value);var visibleKeys=arrayToHash(keys);if(ctx.showHidden){keys=Object.getOwnPropertyNames(value)}if(isError(value)&&(keys.indexOf("message")>=0||keys.indexOf("description")>=0)){return formatError(value)}if(keys.length===0){if(isFunction(value)){var name=value.name?": "+value.name:"";return ctx.stylize("[Function"+name+"]","special")}if(isRegExp(value)){return ctx.stylize(RegExp.prototype.toString.call(value),"regexp")}if(isDate(value)){return ctx.stylize(Date.prototype.toString.call(value),"date")}if(isError(value)){return formatError(value)}}var base="",array=false,braces=["{","}"];if(isArray(value)){array=true;braces=["[","]"]}if(isFunction(value)){var n=value.name?": "+value.name:"";base=" [Function"+n+"]"}if(isRegExp(value)){base=" "+RegExp.prototype.toString.call(value)}if(isDate(value)){base=" "+Date.prototype.toUTCString.call(value)}if(isError(value)){base=" "+formatError(value)}if(keys.length===0&&(!array||value.length==0)){return braces[0]+base+braces[1]}if(recurseTimes<0){if(isRegExp(value)){return ctx.stylize(RegExp.prototype.toString.call(value),"regexp")}else{return ctx.stylize("[Object]","special")}}ctx.seen.push(value);var output;if(array){output=formatArray(ctx,value,recurseTimes,visibleKeys,keys)}else{output=keys.map(function(key){return formatProperty(ctx,value,recurseTimes,visibleKeys,key,array)})}ctx.seen.pop();return reduceToSingleString(output,base,braces)}function formatPrimitive(ctx,value){if(isUndefined(value))return ctx.stylize("undefined","undefined");if(isString(value)){var simple="'"+JSON.stringify(value).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return ctx.stylize(simple,"string")}if(isNumber(value))return ctx.stylize(""+value,"number");if(isBoolean(value))return ctx.stylize(""+value,"boolean");if(isNull(value))return ctx.stylize("null","null")}function formatError(value){return"["+Error.prototype.toString.call(value)+"]"}function formatArray(ctx,value,recurseTimes,visibleKeys,keys){var output=[];for(var i=0,l=value.length;i<l;++i){if(hasOwnProperty(value,String(i))){output.push(formatProperty(ctx,value,recurseTimes,visibleKeys,String(i),true))}else{output.push("")}}keys.forEach(function(key){if(!key.match(/^\d+$/)){output.push(formatProperty(ctx,value,recurseTimes,visibleKeys,key,true))}});return output}function formatProperty(ctx,value,recurseTimes,visibleKeys,key,array){var name,str,desc;desc=Object.getOwnPropertyDescriptor(value,key)||{value:value[key]};if(desc.get){if(desc.set){str=ctx.stylize("[Getter/Setter]","special")}else{str=ctx.stylize("[Getter]","special")}}else{if(desc.set){str=ctx.stylize("[Setter]","special")}}if(!hasOwnProperty(visibleKeys,key)){name="["+key+"]"}if(!str){if(ctx.seen.indexOf(desc.value)<0){if(isNull(recurseTimes)){str=formatValue(ctx,desc.value,null)}else{str=formatValue(ctx,desc.value,recurseTimes-1)}if(str.indexOf("\n")>-1){if(array){str=str.split("\n").map(function(line){return" "+line}).join("\n").substr(2)}else{str="\n"+str.split("\n").map(function(line){return" "+line}).join("\n")}}}else{str=ctx.stylize("[Circular]","special")}}if(isUndefined(name)){if(array&&key.match(/^\d+$/)){return str}name=JSON.stringify(""+key);if(name.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)){name=name.substr(1,name.length-2);name=ctx.stylize(name,"name")}else{name=name.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'");name=ctx.stylize(name,"string")}}return name+": "+str}function reduceToSingleString(output,base,braces){var numLinesEst=0;var length=output.reduce(function(prev,cur){numLinesEst++;if(cur.indexOf("\n")>=0)numLinesEst++;return prev+cur.replace(/\u001b\[\d\d?m/g,"").length+1},0);if(length>60){return braces[0]+(base===""?"":base+"\n ")+" "+output.join(",\n ")+" "+braces[1]}return braces[0]+base+" "+output.join(", ")+" "+braces[1]}function isArray(ar){return Array.isArray(ar)}exports.isArray=isArray;function isBoolean(arg){return typeof arg==="boolean"}exports.isBoolean=isBoolean;function isNull(arg){return arg===null}exports.isNull=isNull;function isNullOrUndefined(arg){return arg==null}exports.isNullOrUndefined=isNullOrUndefined;function isNumber(arg){return typeof arg==="number"}exports.isNumber=isNumber;function isString(arg){return typeof arg==="string"}exports.isString=isString;function isSymbol(arg){return typeof arg==="symbol"}exports.isSymbol=isSymbol;function isUndefined(arg){return arg===void 0}exports.isUndefined=isUndefined;function isRegExp(re){return isObject(re)&&objectToString(re)==="[object RegExp]"}exports.isRegExp=isRegExp;function isObject(arg){return typeof arg==="object"&&arg!==null}exports.isObject=isObject;function isDate(d){return isObject(d)&&objectToString(d)==="[object Date]"}exports.isDate=isDate;function isError(e){return isObject(e)&&(objectToString(e)==="[object Error]"||e instanceof Error)}exports.isError=isError;function isFunction(arg){return typeof arg==="function"}exports.isFunction=isFunction;function isPrimitive(arg){return arg===null||typeof arg==="boolean"||typeof arg==="number"||typeof arg==="string"||typeof arg==="symbol"||typeof arg==="undefined"}exports.isPrimitive=isPrimitive;exports.isBuffer=require("./support/isBuffer");function objectToString(o){return Object.prototype.toString.call(o)}function pad(n){return n<10?"0"+n.toString(10):n.toString(10)}var months=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function timestamp(){var d=new Date;var time=[pad(d.getHours()),pad(d.getMinutes()),pad(d.getSeconds())].join(":");return[d.getDate(),months[d.getMonth()],time].join(" ")}exports.log=function(){console.log("%s - %s",timestamp(),exports.format.apply(exports,arguments))};exports.inherits=require("inherits");exports._extend=function(origin,add){if(!add||!isObject(add))return origin;var keys=Object.keys(add);var i=keys.length;while(i--){origin[keys[i]]=add[keys[i]]}return origin};function hasOwnProperty(obj,prop){return Object.prototype.hasOwnProperty.call(obj,prop)}}).call(this,require("_process"),typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{})},{"./support/isBuffer":166,_process:151,inherits:148}],168:[function(require,module,exports){(function(process){"use strict";var escapeStringRegexp=require("escape-string-regexp");var ansiStyles=require("ansi-styles");var stripAnsi=require("strip-ansi");var hasAnsi=require("has-ansi");var supportsColor=require("supports-color");var defineProps=Object.defineProperties;function Chalk(options){this.enabled=!options||options.enabled===undefined?supportsColor:options.enabled}if(process.platform==="win32"){ansiStyles.blue.open=""}function build(_styles){var builder=function builder(){return applyStyle.apply(builder,arguments)};builder._styles=_styles;builder.enabled=this.enabled;builder.__proto__=proto;return builder}var styles=function(){var ret={};Object.keys(ansiStyles).forEach(function(key){ansiStyles[key].closeRe=new RegExp(escapeStringRegexp(ansiStyles[key].close),"g");ret[key]={get:function(){return build.call(this,this._styles.concat(key))}}});return ret}();var proto=defineProps(function chalk(){},styles);function applyStyle(){var args=arguments;var argsLen=args.length;var str=argsLen!==0&&String(arguments[0]);if(argsLen>1){for(var a=1;a<argsLen;a++){str+=" "+args[a]}}if(!this.enabled||!str){return str}var nestedStyles=this._styles;var i=nestedStyles.length;while(i--){var code=ansiStyles[nestedStyles[i]];str=code.open+str.replace(code.closeRe,code.open)+code.close}return str}function init(){var ret={};Object.keys(styles).forEach(function(name){ret[name]={get:function(){return build.call(this,[name])}}});return ret}defineProps(Chalk.prototype,init());module.exports=new Chalk;module.exports.styles=ansiStyles;module.exports.hasColor=hasAnsi;module.exports.stripColor=stripAnsi;module.exports.supportsColor=supportsColor}).call(this,require("_process"))},{_process:151,"ansi-styles":169,"escape-string-regexp":170,"has-ansi":171,"strip-ansi":173,"supports-color":175}],169:[function(require,module,exports){"use strict";var styles=module.exports={modifiers:{reset:[0,0],bold:[1,22],dim:[2,22],italic:[3,23],underline:[4,24],inverse:[7,27],hidden:[8,28],strikethrough:[9,29]},colors:{black:[30,39],red:[31,39],green:[32,39],yellow:[33,39],blue:[34,39],magenta:[35,39],cyan:[36,39],white:[37,39],gray:[90,39]},bgColors:{bgBlack:[40,49],bgRed:[41,49],bgGreen:[42,49],bgYellow:[43,49],bgBlue:[44,49],bgMagenta:[45,49],bgCyan:[46,49],bgWhite:[47,49]}};styles.colors.grey=styles.colors.gray;Object.keys(styles).forEach(function(groupName){var group=styles[groupName];Object.keys(group).forEach(function(styleName){var style=group[styleName];styles[styleName]=group[styleName]={open:"["+style[0]+"m",close:"["+style[1]+"m"}});Object.defineProperty(styles,groupName,{value:group,enumerable:false})})},{}],170:[function(require,module,exports){"use strict";var matchOperatorsRe=/[|\\{}()[\]^$+*?.]/g;module.exports=function(str){if(typeof str!=="string"){throw new TypeError("Expected a string")}return str.replace(matchOperatorsRe,"\\$&")}},{}],171:[function(require,module,exports){"use strict";var ansiRegex=require("ansi-regex");var re=new RegExp(ansiRegex().source);module.exports=re.test.bind(re)},{"ansi-regex":172}],172:[function(require,module,exports){"use strict";module.exports=function(){return/(?:(?:\u001b\[)|\u009b)(?:(?:[0-9]{1,3})?(?:(?:;[0-9]{0,3})*)?[A-M|f-m])|\u001b[A-M]/g}},{}],173:[function(require,module,exports){"use strict";var ansiRegex=require("ansi-regex")();module.exports=function(str){return typeof str==="string"?str.replace(ansiRegex,""):str}},{"ansi-regex":174}],174:[function(require,module,exports){arguments[4][172][0].apply(exports,arguments)},{dup:172}],175:[function(require,module,exports){(function(process){"use strict";var argv=process.argv;module.exports=function(){if("FORCE_COLOR"in process.env){return true}if(argv.indexOf("--no-color")!==-1||argv.indexOf("--no-colors")!==-1||argv.indexOf("--color=false")!==-1){return false}if(argv.indexOf("--color")!==-1||argv.indexOf("--colors")!==-1||argv.indexOf("--color=true")!==-1||argv.indexOf("--color=always")!==-1){return true}if(process.stdout&&!process.stdout.isTTY){return false}if("UPSTART_JOB"in process.env){return false}if(process.platform==="win32"){return true}if("COLORTERM"in process.env){return true}if(process.env.TERM==="dumb"){return false}if(/^screen|^xterm|^vt100|color|ansi|cygwin|linux/i.test(process.env.TERM)){return true}return false}()}).call(this,require("_process"))},{_process:151}],176:[function(require,module,exports){!function(global,framework,undefined){"use strict";var OBJECT="Object",FUNCTION="Function",ARRAY="Array",STRING="String",NUMBER="Number",REGEXP="RegExp",DATE="Date",MAP="Map",SET="Set",WEAKMAP="WeakMap",WEAKSET="WeakSet",SYMBOL="Symbol",PROMISE="Promise",MATH="Math",ARGUMENTS="Arguments",PROTOTYPE="prototype",CONSTRUCTOR="constructor",TO_STRING="toString",TO_STRING_TAG=TO_STRING+"Tag",TO_LOCALE="toLocaleString",HAS_OWN="hasOwnProperty",FOR_EACH="forEach",ITERATOR="iterator",FF_ITERATOR="@@"+ITERATOR,PROCESS="process",CREATE_ELEMENT="createElement",Function=global[FUNCTION],Object=global[OBJECT],Array=global[ARRAY],String=global[STRING],Number=global[NUMBER],RegExp=global[REGEXP],Date=global[DATE],Map=global[MAP],Set=global[SET],WeakMap=global[WEAKMAP],WeakSet=global[WEAKSET],Symbol=global[SYMBOL],Math=global[MATH],TypeError=global.TypeError,RangeError=global.RangeError,setTimeout=global.setTimeout,setImmediate=global.setImmediate,clearImmediate=global.clearImmediate,parseInt=global.parseInt,isFinite=global.isFinite,process=global[PROCESS],nextTick=process&&process.nextTick,document=global.document,html=document&&document.documentElement,navigator=global.navigator,define=global.define,console=global.console||{},ArrayProto=Array[PROTOTYPE],ObjectProto=Object[PROTOTYPE],FunctionProto=Function[PROTOTYPE],Infinity=1/0,DOT=".";function isObject(it){return it!==null&&(typeof it=="object"||typeof it=="function")}function isFunction(it){return typeof it=="function"}var isNative=ctx(/./.test,/\[native code\]\s*\}\s*$/,1);var toString=ObjectProto[TO_STRING];function setToStringTag(it,tag,stat){if(it&&!has(it=stat?it:it[PROTOTYPE],SYMBOL_TAG))hidden(it,SYMBOL_TAG,tag)}function cof(it){return toString.call(it).slice(8,-1)}function classof(it){var O,T;return it==undefined?it===undefined?"Undefined":"Null":typeof(T=(O=Object(it))[SYMBOL_TAG])=="string"?T:cof(O)}var call=FunctionProto.call,apply=FunctionProto.apply,REFERENCE_GET;function part(){var fn=assertFunction(this),length=arguments.length,args=Array(length),i=0,_=path._,holder=false;while(length>i)if((args[i]=arguments[i++])===_)holder=true;return function(){var that=this,_length=arguments.length,i=0,j=0,_args;if(!holder&&!_length)return invoke(fn,args,that);_args=args.slice();if(holder)for(;length>i;i++)if(_args[i]===_)_args[i]=arguments[j++];while(_length>j)_args.push(arguments[j++]);return invoke(fn,_args,that)}}function ctx(fn,that,length){assertFunction(fn);if(~length&&that===undefined)return fn;switch(length){case 1:return function(a){return fn.call(that,a)};case 2:return function(a,b){return fn.call(that,a,b)};case 3:return function(a,b,c){return fn.call(that,a,b,c)}}return function(){return fn.apply(that,arguments)}}function invoke(fn,args,that){var un=that===undefined;switch(args.length|0){case 0:return un?fn():fn.call(that);case 1:return un?fn(args[0]):fn.call(that,args[0]);case 2:return un?fn(args[0],args[1]):fn.call(that,args[0],args[1]);case 3:return un?fn(args[0],args[1],args[2]):fn.call(that,args[0],args[1],args[2]);case 4:return un?fn(args[0],args[1],args[2],args[3]):fn.call(that,args[0],args[1],args[2],args[3]);case 5:return un?fn(args[0],args[1],args[2],args[3],args[4]):fn.call(that,args[0],args[1],args[2],args[3],args[4])}return fn.apply(that,args)}var create=Object.create,getPrototypeOf=Object.getPrototypeOf,setPrototypeOf=Object.setPrototypeOf,defineProperty=Object.defineProperty,defineProperties=Object.defineProperties,getOwnDescriptor=Object.getOwnPropertyDescriptor,getKeys=Object.keys,getNames=Object.getOwnPropertyNames,getSymbols=Object.getOwnPropertySymbols,isFrozen=Object.isFrozen,has=ctx(call,ObjectProto[HAS_OWN],2),ES5Object=Object,Dict;function toObject(it){return ES5Object(assertDefined(it))}function returnIt(it){return it}function returnThis(){return this}function get(object,key){if(has(object,key))return object[key]}function ownKeys(it){assertObject(it);return getSymbols?getNames(it).concat(getSymbols(it)):getNames(it)}var assign=Object.assign||function(target,source){var T=Object(assertDefined(target)),l=arguments.length,i=1;while(l>i){var S=ES5Object(arguments[i++]),keys=getKeys(S),length=keys.length,j=0,key;while(length>j)T[key=keys[j++]]=S[key]}return T};function keyOf(object,el){var O=toObject(object),keys=getKeys(O),length=keys.length,index=0,key;while(length>index)if(O[key=keys[index++]]===el)return key}function array(it){return String(it).split(",")}var push=ArrayProto.push,unshift=ArrayProto.unshift,slice=ArrayProto.slice,splice=ArrayProto.splice,indexOf=ArrayProto.indexOf,forEach=ArrayProto[FOR_EACH];function createArrayMethod(type){var isMap=type==1,isFilter=type==2,isSome=type==3,isEvery=type==4,isFindIndex=type==6,noholes=type==5||isFindIndex;return function(callbackfn){var O=Object(assertDefined(this)),that=arguments[1],self=ES5Object(O),f=ctx(callbackfn,that,3),length=toLength(self.length),index=0,result=isMap?Array(length):isFilter?[]:undefined,val,res;for(;length>index;index++)if(noholes||index in self){val=self[index];res=f(val,index,O);if(type){if(isMap)result[index]=res;else if(res)switch(type){case 3:return true;case 5:return val;case 6:return index;case 2:result.push(val)}else if(isEvery)return false}}return isFindIndex?-1:isSome||isEvery?isEvery:result}}function createArrayContains(isContains){return function(el){var O=toObject(this),length=toLength(O.length),index=toIndex(arguments[1],length);if(isContains&&el!=el){for(;length>index;index++)if(sameNaN(O[index]))return isContains||index}else for(;length>index;index++)if(isContains||index in O){if(O[index]===el)return isContains||index}return!isContains&&-1}}function generic(A,B){return typeof A=="function"?A:B}var MAX_SAFE_INTEGER=9007199254740991,pow=Math.pow,abs=Math.abs,ceil=Math.ceil,floor=Math.floor,max=Math.max,min=Math.min,random=Math.random,trunc=Math.trunc||function(it){return(it>0?floor:ceil)(it)};function sameNaN(number){return number!=number}function toInteger(it){return isNaN(it)?0:trunc(it)}function toLength(it){return it>0?min(toInteger(it),MAX_SAFE_INTEGER):0}function toIndex(index,length){var index=toInteger(index);return index<0?max(index+length,0):min(index,length)}function lz(num){return num>9?num:"0"+num}function createReplacer(regExp,replace,isStatic){var replacer=isObject(replace)?function(part){return replace[part]}:replace;return function(it){return String(isStatic?it:this).replace(regExp,replacer)}}function createPointAt(toString){return function(pos){var s=String(assertDefined(this)),i=toInteger(pos),l=s.length,a,b;if(i<0||i>=l)return toString?"":undefined;a=s.charCodeAt(i);return a<55296||a>56319||i+1===l||(b=s.charCodeAt(i+1))<56320||b>57343?toString?s.charAt(i):a:toString?s.slice(i,i+2):(a-55296<<10)+(b-56320)+65536}}var REDUCE_ERROR="Reduce of empty object with no initial value";function assert(condition,msg1,msg2){if(!condition)throw TypeError(msg2?msg1+msg2:msg1)}function assertDefined(it){if(it==undefined)throw TypeError("Function called on null or undefined");return it}function assertFunction(it){assert(isFunction(it),it," is not a function!");return it}function assertObject(it){assert(isObject(it),it," is not an object!");return it}function assertInstance(it,Constructor,name){assert(it instanceof Constructor,name,": use the 'new' operator!")}function descriptor(bitmap,value){return{enumerable:!(bitmap&1),configurable:!(bitmap&2),writable:!(bitmap&4),value:value}}function simpleSet(object,key,value){object[key]=value;return object}function createDefiner(bitmap){return DESC?function(object,key,value){return defineProperty(object,key,descriptor(bitmap,value))}:simpleSet}function uid(key){return SYMBOL+"("+key+")_"+(++sid+random())[TO_STRING](36)}function getWellKnownSymbol(name,setter){return Symbol&&Symbol[name]||(setter?Symbol:safeSymbol)(SYMBOL+DOT+name)}var DESC=!!function(){try{return defineProperty({},"a",{get:function(){return 2}}).a==2}catch(e){}}(),sid=0,hidden=createDefiner(1),set=Symbol?simpleSet:hidden,safeSymbol=Symbol||uid;function assignHidden(target,src){for(var key in src)hidden(target,key,src[key]);return target}var SYMBOL_UNSCOPABLES=getWellKnownSymbol("unscopables"),ArrayUnscopables=ArrayProto[SYMBOL_UNSCOPABLES]||{},SYMBOL_TAG=getWellKnownSymbol(TO_STRING_TAG),SYMBOL_SPECIES=getWellKnownSymbol("species"),SYMBOL_ITERATOR;function setSpecies(C){if(DESC&&(framework||!isNative(C)))defineProperty(C,SYMBOL_SPECIES,{configurable:true,get:returnThis})}var NODE=cof(process)==PROCESS,core={},path=framework?global:core,old=global.core,exportGlobal,FORCED=1,GLOBAL=2,STATIC=4,PROTO=8,BIND=16,WRAP=32;function $define(type,name,source){var key,own,out,exp,isGlobal=type&GLOBAL,target=isGlobal?global:type&STATIC?global[name]:(global[name]||ObjectProto)[PROTOTYPE],exports=isGlobal?core:core[name]||(core[name]={});if(isGlobal)source=name;for(key in source){own=!(type&FORCED)&&target&&key in target&&(!isFunction(target[key])||isNative(target[key]));out=(own?target:source)[key];if(!framework&&isGlobal&&!isFunction(target[key]))exp=source[key];else if(type&BIND&&own)exp=ctx(out,global);else if(type&WRAP&&!framework&&target[key]==out){exp=function(param){return this instanceof out?new out(param):out(param)};exp[PROTOTYPE]=out[PROTOTYPE]}else exp=type&PROTO&&isFunction(out)?ctx(call,out):out;if(framework&&target&&!own){if(isGlobal)target[key]=out;else delete target[key]&&hidden(target,key,out)}if(exports[key]!=out)hidden(exports,key,exp)}}if(typeof module!="undefined"&&module.exports)module.exports=core;else if(isFunction(define)&&define.amd)define(function(){return core});else exportGlobal=true;if(exportGlobal||framework){core.noConflict=function(){global.core=old;return core};global.core=core}SYMBOL_ITERATOR=getWellKnownSymbol(ITERATOR);var ITER=safeSymbol("iter"),KEY=1,VALUE=2,Iterators={},IteratorPrototype={},BUGGY_ITERATORS="keys"in ArrayProto&&!("next"in[].keys());setIterator(IteratorPrototype,returnThis);function setIterator(O,value){hidden(O,SYMBOL_ITERATOR,value);FF_ITERATOR in ArrayProto&&hidden(O,FF_ITERATOR,value)}function createIterator(Constructor,NAME,next,proto){Constructor[PROTOTYPE]=create(proto||IteratorPrototype,{next:descriptor(1,next)});setToStringTag(Constructor,NAME+" Iterator")}function defineIterator(Constructor,NAME,value,DEFAULT){var proto=Constructor[PROTOTYPE],iter=get(proto,SYMBOL_ITERATOR)||get(proto,FF_ITERATOR)||DEFAULT&&get(proto,DEFAULT)||value;if(framework){setIterator(proto,iter);if(iter!==value){var iterProto=getPrototypeOf(iter.call(new Constructor));setToStringTag(iterProto,NAME+" Iterator",true);has(proto,FF_ITERATOR)&&setIterator(iterProto,returnThis)}}Iterators[NAME]=iter;Iterators[NAME+" Iterator"]=returnThis;return iter}function defineStdIterators(Base,NAME,Constructor,next,DEFAULT,IS_SET){function createIter(kind){return function(){return new Constructor(this,kind)}}createIterator(Constructor,NAME,next);var entries=createIter(KEY+VALUE),values=createIter(VALUE);if(DEFAULT==VALUE)values=defineIterator(Base,NAME,values,"values");else entries=defineIterator(Base,NAME,entries,"entries");if(DEFAULT){$define(PROTO+FORCED*BUGGY_ITERATORS,NAME,{entries:entries,keys:IS_SET?values:createIter(KEY),values:values})}}function iterResult(done,value){return{value:value,done:!!done}}function isIterable(it){var O=Object(it),Symbol=global[SYMBOL],hasExt=(Symbol&&Symbol[ITERATOR]||FF_ITERATOR)in O;return hasExt||SYMBOL_ITERATOR in O||has(Iterators,classof(O))}function getIterator(it){var Symbol=global[SYMBOL],ext=it[Symbol&&Symbol[ITERATOR]||FF_ITERATOR],getIter=ext||it[SYMBOL_ITERATOR]||Iterators[classof(it)];return assertObject(getIter.call(it))}function stepCall(fn,value,entries){return entries?invoke(fn,value):fn(value)}function checkDangerIterClosing(fn){var danger=true;var O={next:function(){throw 1},"return":function(){danger=false}};O[SYMBOL_ITERATOR]=returnThis;try{fn(O)}catch(e){}return danger}function closeIterator(iterator){var ret=iterator["return"];if(ret!==undefined)ret.call(iterator)}function safeIterClose(exec,iterator){try{exec(iterator)}catch(e){closeIterator(iterator);throw e}}function forOf(iterable,entries,fn,that){safeIterClose(function(iterator){var f=ctx(fn,that,entries?2:1),step;while(!(step=iterator.next()).done)if(stepCall(f,step.value,entries)===false){return closeIterator(iterator)}},getIterator(iterable))}!function(TAG,SymbolRegistry,AllSymbols,setter){if(!isNative(Symbol)){Symbol=function(description){assert(!(this instanceof Symbol),SYMBOL+" is not a "+CONSTRUCTOR);var tag=uid(description),sym=set(create(Symbol[PROTOTYPE]),TAG,tag);AllSymbols[tag]=sym;DESC&&setter&&defineProperty(ObjectProto,tag,{configurable:true,set:function(value){hidden(this,tag,value)}});return sym};hidden(Symbol[PROTOTYPE],TO_STRING,function(){return this[TAG]})}$define(GLOBAL+WRAP,{Symbol:Symbol});var symbolStatics={"for":function(key){return has(SymbolRegistry,key+="")?SymbolRegistry[key]:SymbolRegistry[key]=Symbol(key)},iterator:SYMBOL_ITERATOR||getWellKnownSymbol(ITERATOR),keyFor:part.call(keyOf,SymbolRegistry),species:SYMBOL_SPECIES,toStringTag:SYMBOL_TAG=getWellKnownSymbol(TO_STRING_TAG,true),unscopables:SYMBOL_UNSCOPABLES,pure:safeSymbol,set:set,useSetter:function(){setter=true },useSimple:function(){setter=false}};forEach.call(array("hasInstance,isConcatSpreadable,match,replace,search,split,toPrimitive"),function(it){symbolStatics[it]=getWellKnownSymbol(it)});$define(STATIC,SYMBOL,symbolStatics);setToStringTag(Symbol,SYMBOL);$define(STATIC+FORCED*!isNative(Symbol),OBJECT,{getOwnPropertyNames:function(it){var names=getNames(toObject(it)),result=[],key,i=0;while(names.length>i)has(AllSymbols,key=names[i++])||result.push(key);return result},getOwnPropertySymbols:function(it){var names=getNames(toObject(it)),result=[],key,i=0;while(names.length>i)has(AllSymbols,key=names[i++])&&result.push(AllSymbols[key]);return result}});setToStringTag(Math,MATH,true);setToStringTag(global.JSON,"JSON",true)}(safeSymbol("tag"),{},{},true);!function(){var objectStatic={assign:assign,is:function(x,y){return x===y?x!==0||1/x===1/y:x!=x&&y!=y}};"__proto__"in ObjectProto&&function(buggy,set){try{set=ctx(call,getOwnDescriptor(ObjectProto,"__proto__").set,2);set({},ArrayProto)}catch(e){buggy=true}objectStatic.setPrototypeOf=setPrototypeOf=setPrototypeOf||function(O,proto){assertObject(O);assert(proto===null||isObject(proto),proto,": can't set as prototype!");if(buggy)O.__proto__=proto;else set(O,proto);return O}}();$define(STATIC,OBJECT,objectStatic)}();!function(){function wrapObjectMethod(key,MODE){var fn=Object[key],exp=core[OBJECT][key],f=0,o={};if(!exp||isNative(exp)){o[key]=MODE==1?function(it){return isObject(it)?fn(it):it}:MODE==2?function(it){return isObject(it)?fn(it):true}:MODE==3?function(it){return isObject(it)?fn(it):false}:MODE==4?function(it,key){return fn(toObject(it),key)}:function(it){return fn(toObject(it))};try{fn(DOT)}catch(e){f=1}$define(STATIC+FORCED*f,OBJECT,o)}}wrapObjectMethod("freeze",1);wrapObjectMethod("seal",1);wrapObjectMethod("preventExtensions",1);wrapObjectMethod("isFrozen",2);wrapObjectMethod("isSealed",2);wrapObjectMethod("isExtensible",3);wrapObjectMethod("getOwnPropertyDescriptor",4);wrapObjectMethod("getPrototypeOf");wrapObjectMethod("keys");wrapObjectMethod("getOwnPropertyNames")}();!function(isInteger){$define(STATIC,NUMBER,{EPSILON:pow(2,-52),isFinite:function(it){return typeof it=="number"&&isFinite(it)},isInteger:isInteger,isNaN:sameNaN,isSafeInteger:function(number){return isInteger(number)&&abs(number)<=MAX_SAFE_INTEGER},MAX_SAFE_INTEGER:MAX_SAFE_INTEGER,MIN_SAFE_INTEGER:-MAX_SAFE_INTEGER,parseFloat:parseFloat,parseInt:parseInt})}(Number.isInteger||function(it){return!isObject(it)&&isFinite(it)&&floor(it)===it});!function(){var E=Math.E,exp=Math.exp,log=Math.log,sqrt=Math.sqrt,sign=Math.sign||function(x){return(x=+x)==0||x!=x?x:x<0?-1:1};function asinh(x){return!isFinite(x=+x)||x==0?x:x<0?-asinh(-x):log(x+sqrt(x*x+1))}function expm1(x){return(x=+x)==0?x:x>-1e-6&&x<1e-6?x+x*x/2:exp(x)-1}$define(STATIC,MATH,{acosh:function(x){return(x=+x)<1?NaN:isFinite(x)?log(x/E+sqrt(x+1)*sqrt(x-1)/E)+1:x},asinh:asinh,atanh:function(x){return(x=+x)==0?x:log((1+x)/(1-x))/2},cbrt:function(x){return sign(x=+x)*pow(abs(x),1/3)},clz32:function(x){return(x>>>=0)?32-x[TO_STRING](2).length:32},cosh:function(x){return(exp(x=+x)+exp(-x))/2},expm1:expm1,fround:function(x){return new Float32Array([x])[0]},hypot:function(value1,value2){var sum=0,len1=arguments.length,len2=len1,args=Array(len1),larg=-Infinity,arg;while(len1--){arg=args[len1]=+arguments[len1];if(arg==Infinity||arg==-Infinity)return Infinity;if(arg>larg)larg=arg}larg=arg||1;while(len2--)sum+=pow(args[len2]/larg,2);return larg*sqrt(sum)},imul:function(x,y){var UInt16=65535,xn=+x,yn=+y,xl=UInt16&xn,yl=UInt16&yn;return 0|xl*yl+((UInt16&xn>>>16)*yl+xl*(UInt16&yn>>>16)<<16>>>0)},log1p:function(x){return(x=+x)>-1e-8&&x<1e-8?x-x*x/2:log(1+x)},log10:function(x){return log(x)/Math.LN10},log2:function(x){return log(x)/Math.LN2},sign:sign,sinh:function(x){return abs(x=+x)<1?(expm1(x)-expm1(-x))/2:(exp(x-1)-exp(-x-1))*(E/2)},tanh:function(x){var a=expm1(x=+x),b=expm1(-x);return a==Infinity?1:b==Infinity?-1:(a-b)/(exp(x)+exp(-x))},trunc:trunc})}();!function(fromCharCode){function assertNotRegExp(it){if(cof(it)==REGEXP)throw TypeError()}$define(STATIC,STRING,{fromCodePoint:function(x){var res=[],len=arguments.length,i=0,code;while(len>i){code=+arguments[i++];if(toIndex(code,1114111)!==code)throw RangeError(code+" is not a valid code point");res.push(code<65536?fromCharCode(code):fromCharCode(((code-=65536)>>10)+55296,code%1024+56320))}return res.join("")},raw:function(callSite){var raw=toObject(callSite.raw),len=toLength(raw.length),sln=arguments.length,res=[],i=0;while(len>i){res.push(String(raw[i++]));if(i<sln)res.push(String(arguments[i]))}return res.join("")}});$define(PROTO,STRING,{codePointAt:createPointAt(false),endsWith:function(searchString){assertNotRegExp(searchString);var that=String(assertDefined(this)),endPosition=arguments[1],len=toLength(that.length),end=endPosition===undefined?len:min(toLength(endPosition),len);searchString+="";return that.slice(end-searchString.length,end)===searchString},includes:function(searchString){assertNotRegExp(searchString);return!!~String(assertDefined(this)).indexOf(searchString,arguments[1])},repeat:function(count){var str=String(assertDefined(this)),res="",n=toInteger(count);if(0>n||n==Infinity)throw RangeError("Count can't be negative");for(;n>0;(n>>>=1)&&(str+=str))if(n&1)res+=str;return res},startsWith:function(searchString){assertNotRegExp(searchString);var that=String(assertDefined(this)),index=toLength(min(arguments[1],that.length));searchString+="";return that.slice(index,index+searchString.length)===searchString}})}(String.fromCharCode);!function(){$define(STATIC+FORCED*checkDangerIterClosing(Array.from),ARRAY,{from:function(arrayLike){var O=Object(assertDefined(arrayLike)),mapfn=arguments[1],mapping=mapfn!==undefined,f=mapping?ctx(mapfn,arguments[2],2):undefined,index=0,length,result,step;if(isIterable(O)){result=new(generic(this,Array));safeIterClose(function(iterator){for(;!(step=iterator.next()).done;index++){result[index]=mapping?f(step.value,index):step.value}},getIterator(O))}else{result=new(generic(this,Array))(length=toLength(O.length));for(;length>index;index++){result[index]=mapping?f(O[index],index):O[index]}}result.length=index;return result}});$define(STATIC,ARRAY,{of:function(){var index=0,length=arguments.length,result=new(generic(this,Array))(length);while(length>index)result[index]=arguments[index++];result.length=length;return result}});setSpecies(Array)}();!function(){$define(PROTO,ARRAY,{copyWithin:function(target,start){var O=Object(assertDefined(this)),len=toLength(O.length),to=toIndex(target,len),from=toIndex(start,len),end=arguments[2],fin=end===undefined?len:toIndex(end,len),count=min(fin-from,len-to),inc=1;if(from<to&&to<from+count){inc=-1;from=from+count-1;to=to+count-1}while(count-->0){if(from in O)O[to]=O[from];else delete O[to];to+=inc;from+=inc}return O},fill:function(value){var O=Object(assertDefined(this)),length=toLength(O.length),index=toIndex(arguments[1],length),end=arguments[2],endPos=end===undefined?length:toIndex(end,length);while(endPos>index)O[index++]=value;return O},find:createArrayMethod(5),findIndex:createArrayMethod(6)});if(framework){forEach.call(array("find,findIndex,fill,copyWithin,entries,keys,values"),function(it){ArrayUnscopables[it]=true});SYMBOL_UNSCOPABLES in ArrayProto||hidden(ArrayProto,SYMBOL_UNSCOPABLES,ArrayUnscopables)}}();!function(at){defineStdIterators(Array,ARRAY,function(iterated,kind){set(this,ITER,{o:toObject(iterated),i:0,k:kind})},function(){var iter=this[ITER],O=iter.o,kind=iter.k,index=iter.i++;if(!O||index>=O.length){iter.o=undefined;return iterResult(1)}if(kind==KEY)return iterResult(0,index);if(kind==VALUE)return iterResult(0,O[index]);return iterResult(0,[index,O[index]])},VALUE);Iterators[ARGUMENTS]=Iterators[ARRAY];defineStdIterators(String,STRING,function(iterated){set(this,ITER,{o:String(iterated),i:0})},function(){var iter=this[ITER],O=iter.o,index=iter.i,point;if(index>=O.length)return iterResult(1);point=at.call(O,index);iter.i+=point.length;return iterResult(0,point)})}(createPointAt(true));isFunction(setImmediate)&&isFunction(clearImmediate)||function(ONREADYSTATECHANGE){var postMessage=global.postMessage,addEventListener=global.addEventListener,MessageChannel=global.MessageChannel,counter=0,queue={},defer,channel,port;setImmediate=function(fn){var args=[],i=1;while(arguments.length>i)args.push(arguments[i++]);queue[++counter]=function(){invoke(isFunction(fn)?fn:Function(fn),args)};defer(counter);return counter};clearImmediate=function(id){delete queue[id]};function run(id){if(has(queue,id)){var fn=queue[id];delete queue[id];fn()}}function listner(event){run(event.data)}if(NODE){defer=function(id){nextTick(part.call(run,id))}}else if(addEventListener&&isFunction(postMessage)&&!global.importScripts){defer=function(id){postMessage(id,"*")};addEventListener("message",listner,false)}else if(isFunction(MessageChannel)){channel=new MessageChannel;port=channel.port2;channel.port1.onmessage=listner;defer=ctx(port.postMessage,port,1)}else if(document&&ONREADYSTATECHANGE in document[CREATE_ELEMENT]("script")){defer=function(id){html.appendChild(document[CREATE_ELEMENT]("script"))[ONREADYSTATECHANGE]=function(){html.removeChild(this);run(id)}}}else{defer=function(id){setTimeout(run,0,id)}}}("onreadystatechange");$define(GLOBAL+BIND,{setImmediate:setImmediate,clearImmediate:clearImmediate});!function(Promise,test){isFunction(Promise)&&isFunction(Promise.resolve)&&Promise.resolve(test=new Promise(function(){}))==test||function(asap,RECORD){function isThenable(it){var then;if(isObject(it))then=it.then;return isFunction(then)?then:false}function handledRejectionOrHasOnRejected(promise){var record=promise[RECORD],chain=record.c,i=0,react;if(record.h)return true;while(chain.length>i){react=chain[i++];if(react.fail||handledRejectionOrHasOnRejected(react.P))return true}}function notify(record,reject){var chain=record.c;if(reject||chain.length)asap(function(){var promise=record.p,value=record.v,ok=record.s==1,i=0;if(reject&&!handledRejectionOrHasOnRejected(promise)){setTimeout(function(){if(!handledRejectionOrHasOnRejected(promise)){if(NODE){if(!process.emit("unhandledRejection",value,promise)){}}else if(isFunction(console.error)){console.error("Unhandled promise rejection",value)}}},1e3)}else while(chain.length>i)!function(react){var cb=ok?react.ok:react.fail,ret,then;try{if(cb){if(!ok)record.h=true;ret=cb===true?value:cb(value);if(ret===react.P){react.rej(TypeError(PROMISE+"-chain cycle"))}else if(then=isThenable(ret)){then.call(ret,react.res,react.rej)}else react.res(ret)}else react.rej(value)}catch(err){react.rej(err)}}(chain[i++]);chain.length=0})}function resolve(value){var record=this,then,wrapper;if(record.d)return;record.d=true;record=record.r||record;try{if(then=isThenable(value)){wrapper={r:record,d:false};then.call(value,ctx(resolve,wrapper,1),ctx(reject,wrapper,1))}else{record.v=value;record.s=1;notify(record)}}catch(err){reject.call(wrapper||{r:record,d:false},err)}}function reject(value){var record=this;if(record.d)return;record.d=true;record=record.r||record;record.v=value;record.s=2;notify(record,true)}function getConstructor(C){var S=assertObject(C)[SYMBOL_SPECIES];return S!=undefined?S:C}Promise=function(executor){assertFunction(executor);assertInstance(this,Promise,PROMISE);var record={p:this,c:[],s:0,d:false,v:undefined,h:false};hidden(this,RECORD,record);try{executor(ctx(resolve,record,1),ctx(reject,record,1))}catch(err){reject.call(record,err)}};assignHidden(Promise[PROTOTYPE],{then:function(onFulfilled,onRejected){var S=assertObject(assertObject(this)[CONSTRUCTOR])[SYMBOL_SPECIES];var react={ok:isFunction(onFulfilled)?onFulfilled:true,fail:isFunction(onRejected)?onRejected:false},P=react.P=new(S!=undefined?S:Promise)(function(resolve,reject){react.res=assertFunction(resolve);react.rej=assertFunction(reject)}),record=this[RECORD];record.c.push(react);record.s&&notify(record);return P},"catch":function(onRejected){return this.then(undefined,onRejected)}});assignHidden(Promise,{all:function(iterable){var Promise=getConstructor(this),values=[];return new Promise(function(resolve,reject){forOf(iterable,false,push,values);var remaining=values.length,results=Array(remaining);if(remaining)forEach.call(values,function(promise,index){Promise.resolve(promise).then(function(value){results[index]=value;--remaining||resolve(results)},reject)});else resolve(results)})},race:function(iterable){var Promise=getConstructor(this);return new Promise(function(resolve,reject){forOf(iterable,false,function(promise){Promise.resolve(promise).then(resolve,reject)})})},reject:function(r){return new(getConstructor(this))(function(resolve,reject){reject(r)})},resolve:function(x){return isObject(x)&&RECORD in x&&getPrototypeOf(x)===this[PROTOTYPE]?x:new(getConstructor(this))(function(resolve,reject){resolve(x)})}})}(nextTick||setImmediate,safeSymbol("record"));setToStringTag(Promise,PROMISE);setSpecies(Promise);$define(GLOBAL+FORCED*!isNative(Promise),{Promise:Promise})}(global[PROMISE]);!function(){var UID=safeSymbol("uid"),O1=safeSymbol("O1"),WEAK=safeSymbol("weak"),LEAK=safeSymbol("leak"),LAST=safeSymbol("last"),FIRST=safeSymbol("first"),SIZE=DESC?safeSymbol("size"):"size",uid=0,tmp={};function getCollection(C,NAME,methods,commonMethods,isMap,isWeak){var ADDER=isMap?"set":"add",proto=C&&C[PROTOTYPE],O={};function initFromIterable(that,iterable){if(iterable!=undefined)forOf(iterable,isMap,that[ADDER],that);return that}function fixSVZ(key,chain){var method=proto[key];if(framework)proto[key]=function(a,b){var result=method.call(this,a===0?0:a,b);return chain?this:result}}if(!isNative(C)||!(isWeak||!BUGGY_ITERATORS&&has(proto,FOR_EACH)&&has(proto,"entries"))){C=isWeak?function(iterable){assertInstance(this,C,NAME);set(this,UID,uid++);initFromIterable(this,iterable)}:function(iterable){var that=this;assertInstance(that,C,NAME);set(that,O1,create(null));set(that,SIZE,0);set(that,LAST,undefined);set(that,FIRST,undefined);initFromIterable(that,iterable)};assignHidden(assignHidden(C[PROTOTYPE],methods),commonMethods);isWeak||!DESC||defineProperty(C[PROTOTYPE],"size",{get:function(){return assertDefined(this[SIZE])}})}else{var Native=C,inst=new C,chain=inst[ADDER](isWeak?{}:-0,1),buggyZero;if(checkDangerIterClosing(function(O){new C(O)})){C=function(iterable){assertInstance(this,C,NAME);return initFromIterable(new Native,iterable)};C[PROTOTYPE]=proto;if(framework)proto[CONSTRUCTOR]=C}isWeak||inst[FOR_EACH](function(val,key){buggyZero=1/key===-Infinity});if(buggyZero){fixSVZ("delete");fixSVZ("has");isMap&&fixSVZ("get")}if(buggyZero||chain!==inst)fixSVZ(ADDER,true)}setToStringTag(C,NAME);setSpecies(C);O[NAME]=C;$define(GLOBAL+WRAP+FORCED*!isNative(C),O);isWeak||defineStdIterators(C,NAME,function(iterated,kind){set(this,ITER,{o:iterated,k:kind})},function(){var iter=this[ITER],kind=iter.k,entry=iter.l;while(entry&&entry.r)entry=entry.p;if(!iter.o||!(iter.l=entry=entry?entry.n:iter.o[FIRST])){iter.o=undefined;return iterResult(1)}if(kind==KEY)return iterResult(0,entry.k);if(kind==VALUE)return iterResult(0,entry.v);return iterResult(0,[entry.k,entry.v])},isMap?KEY+VALUE:VALUE,!isMap);return C}function fastKey(it,create){if(!isObject(it))return(typeof it=="string"?"S":"P")+it;if(isFrozen(it))return"F";if(!has(it,UID)){if(!create)return"E";hidden(it,UID,++uid)}return"O"+it[UID]}function getEntry(that,key){var index=fastKey(key),entry;if(index!="F")return that[O1][index];for(entry=that[FIRST];entry;entry=entry.n){if(entry.k==key)return entry}}function def(that,key,value){var entry=getEntry(that,key),prev,index;if(entry)entry.v=value;else{that[LAST]=entry={i:index=fastKey(key,true),k:key,v:value,p:prev=that[LAST],n:undefined,r:false};if(!that[FIRST])that[FIRST]=entry;if(prev)prev.n=entry;that[SIZE]++;if(index!="F")that[O1][index]=entry}return that}var collectionMethods={clear:function(){for(var that=this,data=that[O1],entry=that[FIRST];entry;entry=entry.n){entry.r=true;if(entry.p)entry.p=entry.p.n=undefined;delete data[entry.i]}that[FIRST]=that[LAST]=undefined;that[SIZE]=0},"delete":function(key){var that=this,entry=getEntry(that,key);if(entry){var next=entry.n,prev=entry.p;delete that[O1][entry.i];entry.r=true;if(prev)prev.n=next;if(next)next.p=prev;if(that[FIRST]==entry)that[FIRST]=next;if(that[LAST]==entry)that[LAST]=prev;that[SIZE]--}return!!entry},forEach:function(callbackfn){var f=ctx(callbackfn,arguments[1],3),entry;while(entry=entry?entry.n:this[FIRST]){f(entry.v,entry.k,this);while(entry&&entry.r)entry=entry.p}},has:function(key){return!!getEntry(this,key)}};Map=getCollection(Map,MAP,{get:function(key){var entry=getEntry(this,key);return entry&&entry.v},set:function(key,value){return def(this,key===0?0:key,value)}},collectionMethods,true);Set=getCollection(Set,SET,{add:function(value){return def(this,value=value===0?0:value,value)}},collectionMethods);function defWeak(that,key,value){if(isFrozen(assertObject(key)))leakStore(that).set(key,value);else{has(key,WEAK)||hidden(key,WEAK,{});key[WEAK][that[UID]]=value}return that}function leakStore(that){return that[LEAK]||hidden(that,LEAK,new Map)[LEAK]}var weakMethods={"delete":function(key){if(!isObject(key))return false;if(isFrozen(key))return leakStore(this)["delete"](key);return has(key,WEAK)&&has(key[WEAK],this[UID])&&delete key[WEAK][this[UID]]},has:function(key){if(!isObject(key))return false;if(isFrozen(key))return leakStore(this).has(key);return has(key,WEAK)&&has(key[WEAK],this[UID])}};WeakMap=getCollection(WeakMap,WEAKMAP,{get:function(key){if(isObject(key)){if(isFrozen(key))return leakStore(this).get(key);if(has(key,WEAK))return key[WEAK][this[UID]]}},set:function(key,value){return defWeak(this,key,value)}},weakMethods,true,true);if(framework&&(new WeakMap).set(Object.freeze(tmp),7).get(tmp)!=7){forEach.call(array("delete,has,get,set"),function(key){var method=WeakMap[PROTOTYPE][key];WeakMap[PROTOTYPE][key]=function(a,b){if(isObject(a)&&isFrozen(a)){var result=leakStore(this)[key](a,b);return key=="set"?this:result}return method.call(this,a,b)}})}WeakSet=getCollection(WeakSet,WEAKSET,{add:function(value){return defWeak(this,value,true)}},weakMethods,false,true)}();!function(){function Enumerate(iterated){var keys=[],key;for(key in iterated)keys.push(key);set(this,ITER,{o:iterated,a:keys,i:0})}createIterator(Enumerate,OBJECT,function(){var iter=this[ITER],keys=iter.a,key;do{if(iter.i>=keys.length)return iterResult(1)}while(!((key=keys[iter.i++])in iter.o));return iterResult(0,key)});function wrap(fn){return function(it){assertObject(it);try{return fn.apply(undefined,arguments),true}catch(e){return false}}}function reflectGet(target,propertyKey){var receiver=arguments.length<3?target:arguments[2],desc=getOwnDescriptor(assertObject(target),propertyKey),proto;if(desc)return has(desc,"value")?desc.value:desc.get===undefined?undefined:desc.get.call(receiver);return isObject(proto=getPrototypeOf(target))?reflectGet(proto,propertyKey,receiver):undefined}function reflectSet(target,propertyKey,V){var receiver=arguments.length<4?target:arguments[3],ownDesc=getOwnDescriptor(assertObject(target),propertyKey),existingDescriptor,proto;if(!ownDesc){if(isObject(proto=getPrototypeOf(target))){return reflectSet(proto,propertyKey,V,receiver)}ownDesc=descriptor(0)}if(has(ownDesc,"value")){if(ownDesc.writable===false||!isObject(receiver))return false;existingDescriptor=getOwnDescriptor(receiver,propertyKey)||descriptor(0);existingDescriptor.value=V;return defineProperty(receiver,propertyKey,existingDescriptor),true}return ownDesc.set===undefined?false:(ownDesc.set.call(receiver,V),true)}var isExtensible=Object.isExtensible||returnIt;var reflect={apply:ctx(call,apply,3),construct:function(target,argumentsList){var proto=assertFunction(arguments.length<3?target:arguments[2])[PROTOTYPE],instance=create(isObject(proto)?proto:ObjectProto),result=apply.call(target,instance,argumentsList);return isObject(result)?result:instance},defineProperty:wrap(defineProperty),deleteProperty:function(target,propertyKey){var desc=getOwnDescriptor(assertObject(target),propertyKey);return desc&&!desc.configurable?false:delete target[propertyKey]},enumerate:function(target){return new Enumerate(assertObject(target))},get:reflectGet,getOwnPropertyDescriptor:function(target,propertyKey){return getOwnDescriptor(assertObject(target),propertyKey)},getPrototypeOf:function(target){return getPrototypeOf(assertObject(target))},has:function(target,propertyKey){return propertyKey in target},isExtensible:function(target){return!!isExtensible(assertObject(target))},ownKeys:ownKeys,preventExtensions:wrap(Object.preventExtensions||returnIt),set:reflectSet};if(setPrototypeOf)reflect.setPrototypeOf=function(target,proto){return setPrototypeOf(assertObject(target),proto),true};$define(GLOBAL,{Reflect:{}});$define(STATIC,"Reflect",reflect)}();!function(){$define(PROTO,ARRAY,{includes:createArrayContains(true)});$define(PROTO,STRING,{at:createPointAt(true)});function createObjectToArray(isEntries){return function(object){var O=toObject(object),keys=getKeys(object),length=keys.length,i=0,result=Array(length),key;if(isEntries)while(length>i)result[i]=[key=keys[i++],O[key]];else while(length>i)result[i]=O[keys[i++]];return result}}$define(STATIC,OBJECT,{getOwnPropertyDescriptors:function(object){var O=toObject(object),result={};forEach.call(ownKeys(O),function(key){defineProperty(result,key,descriptor(0,getOwnDescriptor(O,key)))});return result},values:createObjectToArray(false),entries:createObjectToArray(true)});$define(STATIC,REGEXP,{escape:createReplacer(/([\\\-[\]{}()*+?.,^$|])/g,"\\$1",true)})}();!function(REFERENCE){REFERENCE_GET=getWellKnownSymbol(REFERENCE+"Get",true);var REFERENCE_SET=getWellKnownSymbol(REFERENCE+SET,true),REFERENCE_DELETE=getWellKnownSymbol(REFERENCE+"Delete",true);$define(STATIC,SYMBOL,{referenceGet:REFERENCE_GET,referenceSet:REFERENCE_SET,referenceDelete:REFERENCE_DELETE});hidden(FunctionProto,REFERENCE_GET,returnThis);function setMapMethods(Constructor){if(Constructor){var MapProto=Constructor[PROTOTYPE];hidden(MapProto,REFERENCE_GET,MapProto.get);hidden(MapProto,REFERENCE_SET,MapProto.set);hidden(MapProto,REFERENCE_DELETE,MapProto["delete"])}}setMapMethods(Map);setMapMethods(WeakMap)}("reference");!function(DICT){Dict=function(iterable){var dict=create(null);if(iterable!=undefined){if(isIterable(iterable)){forOf(iterable,true,function(key,value){dict[key]=value})}else assign(dict,iterable)}return dict};Dict[PROTOTYPE]=null;function DictIterator(iterated,kind){set(this,ITER,{o:toObject(iterated),a:getKeys(iterated),i:0,k:kind})}createIterator(DictIterator,DICT,function(){var iter=this[ITER],O=iter.o,keys=iter.a,kind=iter.k,key;do{if(iter.i>=keys.length){iter.o=undefined;return iterResult(1)}}while(!has(O,key=keys[iter.i++]));if(kind==KEY)return iterResult(0,key);if(kind==VALUE)return iterResult(0,O[key]);return iterResult(0,[key,O[key]])});function createDictIter(kind){return function(it){return new DictIterator(it,kind)}}function createDictMethod(type){var isMap=type==1,isEvery=type==4;return function(object,callbackfn,that){var f=ctx(callbackfn,that,3),O=toObject(object),result=isMap||type==7||type==2?new(generic(this,Dict)):undefined,key,val,res;for(key in O)if(has(O,key)){val=O[key];res=f(val,key,object);if(type){if(isMap)result[key]=res;else if(res)switch(type){case 2:result[key]=val;break;case 3:return true;case 5:return val;case 6:return key;case 7:result[res[0]]=res[1]}else if(isEvery)return false}}return type==3||isEvery?isEvery:result}}function createDictReduce(isTurn){return function(object,mapfn,init){assertFunction(mapfn);var O=toObject(object),keys=getKeys(O),length=keys.length,i=0,memo,key,result;if(isTurn)memo=init==undefined?new(generic(this,Dict)):Object(init);else if(arguments.length<3){assert(length,REDUCE_ERROR);memo=O[keys[i++]]}else memo=Object(init);while(length>i)if(has(O,key=keys[i++])){result=mapfn(memo,O[key],key,object);if(isTurn){if(result===false)break}else memo=result}return memo}}var findKey=createDictMethod(6);function includes(object,el){return(el==el?keyOf(object,el):findKey(object,sameNaN))!==undefined}var dictMethods={keys:createDictIter(KEY),values:createDictIter(VALUE),entries:createDictIter(KEY+VALUE),forEach:createDictMethod(0),map:createDictMethod(1),filter:createDictMethod(2),some:createDictMethod(3),every:createDictMethod(4),find:createDictMethod(5),findKey:findKey,mapPairs:createDictMethod(7),reduce:createDictReduce(false),turn:createDictReduce(true),keyOf:keyOf,includes:includes,has:has,get:get,set:createDefiner(0),isDict:function(it){return isObject(it)&&getPrototypeOf(it)===Dict[PROTOTYPE]}};if(REFERENCE_GET)for(var key in dictMethods)!function(fn){function method(){for(var args=[this],i=0;i<arguments.length;)args.push(arguments[i++]);return invoke(fn,args)}fn[REFERENCE_GET]=function(){return method}}(dictMethods[key]);$define(GLOBAL+FORCED,{Dict:assignHidden(Dict,dictMethods)})}("Dict");!function(ENTRIES,FN){function $for(iterable,entries){if(!(this instanceof $for))return new $for(iterable,entries);this[ITER]=getIterator(iterable);this[ENTRIES]=!!entries}createIterator($for,"Wrapper",function(){return this[ITER].next()});var $forProto=$for[PROTOTYPE];setIterator($forProto,function(){return this[ITER]});function createChainIterator(next){function Iter(I,fn,that){this[ITER]=getIterator(I);this[ENTRIES]=I[ENTRIES];this[FN]=ctx(fn,that,I[ENTRIES]?2:1)}createIterator(Iter,"Chain",next,$forProto);setIterator(Iter[PROTOTYPE],returnThis);return Iter}var MapIter=createChainIterator(function(){var step=this[ITER].next();return step.done?step:iterResult(0,stepCall(this[FN],step.value,this[ENTRIES]))});var FilterIter=createChainIterator(function(){for(;;){var step=this[ITER].next();if(step.done||stepCall(this[FN],step.value,this[ENTRIES]))return step}});assignHidden($forProto,{of:function(fn,that){forOf(this,this[ENTRIES],fn,that)},array:function(fn,that){var result=[];forOf(fn!=undefined?this.map(fn,that):this,false,push,result);return result},filter:function(fn,that){return new FilterIter(this,fn,that)},map:function(fn,that){return new MapIter(this,fn,that)}});$for.isIterable=isIterable;$for.getIterator=getIterator;$define(GLOBAL+FORCED,{$for:$for})}("entries",safeSymbol("fn"));$define(GLOBAL+FORCED,{delay:function(time){return new Promise(function(resolve){setTimeout(resolve,time,true)})}});!function(_,toLocaleString){core._=path._=path._||{};$define(PROTO+FORCED,FUNCTION,{part:part,only:function(numberArguments,that){var fn=assertFunction(this),n=toLength(numberArguments),isThat=arguments.length>1;return function(){var length=min(n,arguments.length),args=Array(length),i=0;while(length>i)args[i]=arguments[i++];return invoke(fn,args,isThat?that:this)}}});function tie(key){var that=this,bound={};return hidden(that,_,function(key){if(key===undefined||!(key in that))return toLocaleString.call(that);return has(bound,key)?bound[key]:bound[key]=ctx(that[key],that,-1)})[_](key)}hidden(path._,TO_STRING,function(){return _});hidden(ObjectProto,_,tie);DESC||hidden(ArrayProto,_,tie)}(DESC?uid("tie"):TO_LOCALE,ObjectProto[TO_LOCALE]);!function(){function define(target,mixin){var keys=ownKeys(toObject(mixin)),length=keys.length,i=0,key;while(length>i)defineProperty(target,key=keys[i++],getOwnDescriptor(mixin,key));return target}$define(STATIC+FORCED,OBJECT,{isObject:isObject,classof:classof,define:define,make:function(proto,mixin){return define(create(proto),mixin)}})}();$define(PROTO+FORCED,ARRAY,{turn:function(fn,target){assertFunction(fn);var memo=target==undefined?[]:Object(target),O=ES5Object(this),length=toLength(O.length),index=0;while(length>index)if(fn(memo,O[index],index++,this)===false)break;return memo}});if(framework)ArrayUnscopables.turn=true;!function(numberMethods){function NumberIterator(iterated){set(this,ITER,{l:toLength(iterated),i:0})}createIterator(NumberIterator,NUMBER,function(){var iter=this[ITER],i=iter.i++;return i<iter.l?iterResult(0,i):iterResult(1)});defineIterator(Number,NUMBER,function(){return new NumberIterator(this)});numberMethods.random=function(lim){var a=+this,b=lim==undefined?0:+lim,m=min(a,b);return random()*(max(a,b)-m)+m};forEach.call(array("round,floor,ceil,abs,sin,asin,cos,acos,tan,atan,exp,sqrt,max,min,pow,atan2,"+"acosh,asinh,atanh,cbrt,clz32,cosh,expm1,hypot,imul,log1p,log10,log2,sign,sinh,tanh,trunc"),function(key){var fn=Math[key];if(fn)numberMethods[key]=function(){var args=[+this],i=0;while(arguments.length>i)args.push(arguments[i++]);return invoke(fn,args)}});$define(PROTO+FORCED,NUMBER,numberMethods)}({});!function(){var escapeHTMLDict={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&apos;"},unescapeHTMLDict={},key;for(key in escapeHTMLDict)unescapeHTMLDict[escapeHTMLDict[key]]=key;$define(PROTO+FORCED,STRING,{escapeHTML:createReplacer(/[&<>"']/g,escapeHTMLDict),unescapeHTML:createReplacer(/&(?:amp|lt|gt|quot|apos);/g,unescapeHTMLDict)})}();!function(formatRegExp,flexioRegExp,locales,current,SECONDS,MINUTES,HOURS,MONTH,YEAR){function createFormat(prefix){return function(template,locale){var that=this,dict=locales[has(locales,locale)?locale:current];function get(unit){return that[prefix+unit]()}return String(template).replace(formatRegExp,function(part){switch(part){case"s":return get(SECONDS);case"ss":return lz(get(SECONDS));case"m":return get(MINUTES);case"mm":return lz(get(MINUTES));case"h":return get(HOURS);case"hh":return lz(get(HOURS));case"D":return get(DATE);case"DD":return lz(get(DATE));case"W":return dict[0][get("Day")];case"N":return get(MONTH)+1;case"NN":return lz(get(MONTH)+1);case"M":return dict[2][get(MONTH)];case"MM":return dict[1][get(MONTH)];case"Y":return get(YEAR);case"YY":return lz(get(YEAR)%100)}return part})}}function addLocale(lang,locale){function split(index){var result=[];forEach.call(array(locale.months),function(it){result.push(it.replace(flexioRegExp,"$"+index))});return result}locales[lang]=[array(locale.weekdays),split(1),split(2)];return core}$define(PROTO+FORCED,DATE,{format:createFormat("get"),formatUTC:createFormat("getUTC")});addLocale(current,{weekdays:"Sunday,Monday,Tuesday,Wednesday,Thursday,Friday,Saturday",months:"January,February,March,April,May,June,July,August,September,October,November,December"});addLocale("ru",{weekdays:"Воскресенье,Понедельник,Вторник,Среда,Четверг,Пятница,Суббота",months:"Январ:я|ь,Феврал:я|ь,Март:а|,Апрел:я|ь,Ма:я|й,Июн:я|ь,"+"Июл:я|ь,Август:а|,Сентябр:я|ь,Октябр:я|ь,Ноябр:я|ь,Декабр:я|ь"});core.locale=function(locale){return has(locales,locale)?current=locale:current};core.addLocale=addLocale}(/\b\w\w?\b/g,/:(.*)\|(.*)$/,{},"en","Seconds","Minutes","Hours","Month","FullYear");$define(GLOBAL+FORCED,{global:global});!function(arrayStatics){function setArrayStatics(keys,length){forEach.call(array(keys),function(key){if(key in ArrayProto)arrayStatics[key]=ctx(call,ArrayProto[key],length)})}setArrayStatics("pop,reverse,shift,keys,values,entries",1);setArrayStatics("indexOf,every,some,forEach,map,filter,find,findIndex,includes",3);setArrayStatics("join,slice,concat,push,splice,unshift,sort,lastIndexOf,"+"reduce,reduceRight,copyWithin,fill,turn");$define(STATIC,ARRAY,arrayStatics)}({});!function(NodeList){if(framework&&NodeList&&!(SYMBOL_ITERATOR in NodeList[PROTOTYPE])){hidden(NodeList[PROTOTYPE],SYMBOL_ITERATOR,Iterators[ARRAY])}Iterators.NodeList=Iterators[ARRAY]}(global.NodeList);!function(log,enabled){forEach.call(array("assert,clear,count,debug,dir,dirxml,error,exception,"+"group,groupCollapsed,groupEnd,info,isIndependentlyComposed,log,"+"markTimeline,profile,profileEnd,table,time,timeEnd,timeline,"+"timelineEnd,timeStamp,trace,warn"),function(key){log[key]=function(){if(enabled&&key in console)return apply.call(console[key],console,arguments)}});$define(GLOBAL+FORCED,{log:assign(log.log,log,{enable:function(){enabled=true},disable:function(){enabled=false}})})}({},true)}(typeof self!="undefined"&&self.Math===Math?self:Function("return this")(),false)},{}],177:[function(require,module,exports){exports=module.exports=debug;exports.coerce=coerce; exports.disable=disable;exports.enable=enable;exports.enabled=enabled;exports.humanize=require("ms");exports.names=[];exports.skips=[];exports.formatters={};var prevColor=0;var prevTime;function selectColor(){return exports.colors[prevColor++%exports.colors.length]}function debug(namespace){function disabled(){}disabled.enabled=false;function enabled(){var self=enabled;var curr=+new Date;var ms=curr-(prevTime||curr);self.diff=ms;self.prev=prevTime;self.curr=curr;prevTime=curr;if(null==self.useColors)self.useColors=exports.useColors();if(null==self.color&&self.useColors)self.color=selectColor();var args=Array.prototype.slice.call(arguments);args[0]=exports.coerce(args[0]);if("string"!==typeof args[0]){args=["%o"].concat(args)}var index=0;args[0]=args[0].replace(/%([a-z%])/g,function(match,format){if(match==="%%")return match;index++;var formatter=exports.formatters[format];if("function"===typeof formatter){var val=args[index];match=formatter.call(self,val);args.splice(index,1);index--}return match});if("function"===typeof exports.formatArgs){args=exports.formatArgs.apply(self,args)}var logFn=enabled.log||exports.log||console.log.bind(console);logFn.apply(self,args)}enabled.enabled=true;var fn=exports.enabled(namespace)?enabled:disabled;fn.namespace=namespace;return fn}function enable(namespaces){exports.save(namespaces);var split=(namespaces||"").split(/[\s,]+/);var len=split.length;for(var i=0;i<len;i++){if(!split[i])continue;namespaces=split[i].replace(/\*/g,".*?");if(namespaces[0]==="-"){exports.skips.push(new RegExp("^"+namespaces.substr(1)+"$"))}else{exports.names.push(new RegExp("^"+namespaces+"$"))}}}function disable(){exports.enable("")}function enabled(name){var i,len;for(i=0,len=exports.skips.length;i<len;i++){if(exports.skips[i].test(name)){return false}}for(i=0,len=exports.names.length;i<len;i++){if(exports.names[i].test(name)){return true}}return false}function coerce(val){if(val instanceof Error)return val.stack||val.message;return val}},{ms:179}],178:[function(require,module,exports){(function(process){var tty=require("tty");var util=require("util");exports=module.exports=require("./debug");exports.log=log;exports.formatArgs=formatArgs;exports.save=save;exports.load=load;exports.useColors=useColors;exports.colors=[6,2,3,4,5,1];var fd=parseInt(process.env.DEBUG_FD,10)||2;var stream=1===fd?process.stdout:2===fd?process.stderr:createWritableStdioStream(fd);function useColors(){var debugColors=(process.env.DEBUG_COLORS||"").trim().toLowerCase();if(0===debugColors.length){return tty.isatty(fd)}else{return"0"!==debugColors&&"no"!==debugColors&&"false"!==debugColors&&"disabled"!==debugColors}}var inspect=4===util.inspect.length?function(v,colors){return util.inspect(v,void 0,void 0,colors)}:function(v,colors){return util.inspect(v,{colors:colors})};exports.formatters.o=function(v){return inspect(v,this.useColors).replace(/\s*\n\s*/g," ")};function formatArgs(){var args=arguments;var useColors=this.useColors;var name=this.namespace;if(useColors){var c=this.color;args[0]=" [9"+c+"m"+name+" "+""+args[0]+"[3"+c+"m"+" +"+exports.humanize(this.diff)+""}else{args[0]=(new Date).toUTCString()+" "+name+" "+args[0]}return args}function log(){return stream.write(util.format.apply(this,arguments)+"\n")}function save(namespaces){if(null==namespaces){delete process.env.DEBUG}else{process.env.DEBUG=namespaces}}function load(){return process.env.DEBUG}function createWritableStdioStream(fd){var stream;var tty_wrap=process.binding("tty_wrap");switch(tty_wrap.guessHandleType(fd)){case"TTY":stream=new tty.WriteStream(fd);stream._type="tty";if(stream._handle&&stream._handle.unref){stream._handle.unref()}break;case"FILE":var fs=require("fs");stream=new fs.SyncWriteStream(fd,{autoClose:false});stream._type="fs";break;case"PIPE":case"TCP":var net=require("net");stream=new net.Socket({fd:fd,readable:false,writable:true});stream.readable=false;stream.read=null;stream._type="pipe";if(stream._handle&&stream._handle.unref){stream._handle.unref()}break;default:throw new Error("Implement me. Unknown stream file type!")}stream.fd=fd;stream._isStdio=true;return stream}exports.enable(load())}).call(this,require("_process"))},{"./debug":177,_process:151,fs:140,net:140,tty:165,util:167}],179:[function(require,module,exports){var s=1e3;var m=s*60;var h=m*60;var d=h*24;var y=d*365.25;module.exports=function(val,options){options=options||{};if("string"==typeof val)return parse(val);return options.long?long(val):short(val)};function parse(str){var match=/^((?:\d+)?\.?\d+) *(ms|seconds?|s|minutes?|m|hours?|h|days?|d|years?|y)?$/i.exec(str);if(!match)return;var n=parseFloat(match[1]);var type=(match[2]||"ms").toLowerCase();switch(type){case"years":case"year":case"y":return n*y;case"days":case"day":case"d":return n*d;case"hours":case"hour":case"h":return n*h;case"minutes":case"minute":case"m":return n*m;case"seconds":case"second":case"s":return n*s;case"ms":return n}}function short(ms){if(ms>=d)return Math.round(ms/d)+"d";if(ms>=h)return Math.round(ms/h)+"h";if(ms>=m)return Math.round(ms/m)+"m";if(ms>=s)return Math.round(ms/s)+"s";return ms+"ms"}function long(ms){return plural(ms,d,"day")||plural(ms,h,"hour")||plural(ms,m,"minute")||plural(ms,s,"second")||ms+" ms"}function plural(ms,n,name){if(ms<n)return;if(ms<n*1.5)return Math.floor(ms/n)+" "+name;return Math.ceil(ms/n)+" "+name+"s"}},{}],180:[function(require,module,exports){"use strict";var repeating=require("repeating");var INDENT_RE=/^(?:( )+|\t+)/;function getMostUsed(indents){var result=0;var maxUsed=0;var maxWeight=0;for(var n in indents){var indent=indents[n];var u=indent[0];var w=indent[1];if(u>maxUsed||u===maxUsed&&w>maxWeight){maxUsed=u;maxWeight=w;result=+n}}return result}module.exports=function(str){if(typeof str!=="string"){throw new TypeError("Expected a string")}var tabs=0;var spaces=0;var prev=0;var indents={};var current;var isIndent;str.split(/\n/g).forEach(function(line){if(!line){return}var indent;var matches=line.match(INDENT_RE);if(!matches){indent=0}else{indent=matches[0].length;if(matches[1]){spaces++}else{tabs++}}var diff=indent-prev;prev=indent;if(diff){isIndent=diff>0;current=indents[isIndent?diff:-diff];if(current){current[0]++}else{current=indents[diff]=[1,0]}}else if(current){current[1]+=+isIndent}});var amount=getMostUsed(indents);var type;var actual;if(!amount){type=null;actual=""}else if(spaces>=tabs){type="space";actual=repeating(" ",amount)}else{type="tab";actual=repeating(" ",amount)}return{amount:amount,type:type,indent:actual}}},{repeating:325}],181:[function(require,module,exports){(function(root,factory){"use strict";if(typeof define==="function"&&define.amd){define(["exports"],factory)}else if(typeof exports!=="undefined"){factory(exports)}else{factory(root.estraverse={})}})(this,function clone(exports){"use strict";var Syntax,isArray,VisitorOption,VisitorKeys,objectCreate,objectKeys,BREAK,SKIP,REMOVE;function ignoreJSHintError(){}isArray=Array.isArray;if(!isArray){isArray=function isArray(array){return Object.prototype.toString.call(array)==="[object Array]"}}function deepCopy(obj){var ret={},key,val;for(key in obj){if(obj.hasOwnProperty(key)){val=obj[key];if(typeof val==="object"&&val!==null){ret[key]=deepCopy(val)}else{ret[key]=val}}}return ret}function shallowCopy(obj){var ret={},key;for(key in obj){if(obj.hasOwnProperty(key)){ret[key]=obj[key]}}return ret}ignoreJSHintError(shallowCopy);function upperBound(array,func){var diff,len,i,current;len=array.length;i=0;while(len){diff=len>>>1;current=i+diff;if(func(array[current])){len=diff}else{i=current+1;len-=diff+1}}return i}function lowerBound(array,func){var diff,len,i,current;len=array.length;i=0;while(len){diff=len>>>1;current=i+diff;if(func(array[current])){i=current+1;len-=diff+1}else{len=diff}}return i}ignoreJSHintError(lowerBound);objectCreate=Object.create||function(){function F(){}return function(o){F.prototype=o;return new F}}();objectKeys=Object.keys||function(o){var keys=[],key;for(key in o){keys.push(key)}return keys};function extend(to,from){objectKeys(from).forEach(function(key){to[key]=from[key]});return to}Syntax={AssignmentExpression:"AssignmentExpression",ArrayExpression:"ArrayExpression",ArrayPattern:"ArrayPattern",ArrowFunctionExpression:"ArrowFunctionExpression",AwaitExpression:"AwaitExpression",BlockStatement:"BlockStatement",BinaryExpression:"BinaryExpression",BreakStatement:"BreakStatement",CallExpression:"CallExpression",CatchClause:"CatchClause",ClassBody:"ClassBody",ClassDeclaration:"ClassDeclaration",ClassExpression:"ClassExpression",ComprehensionBlock:"ComprehensionBlock",ComprehensionExpression:"ComprehensionExpression",ConditionalExpression:"ConditionalExpression",ContinueStatement:"ContinueStatement",DebuggerStatement:"DebuggerStatement",DirectiveStatement:"DirectiveStatement",DoWhileStatement:"DoWhileStatement",EmptyStatement:"EmptyStatement",ExportBatchSpecifier:"ExportBatchSpecifier",ExportDeclaration:"ExportDeclaration",ExportSpecifier:"ExportSpecifier",ExpressionStatement:"ExpressionStatement",ForStatement:"ForStatement",ForInStatement:"ForInStatement",ForOfStatement:"ForOfStatement",FunctionDeclaration:"FunctionDeclaration",FunctionExpression:"FunctionExpression",GeneratorExpression:"GeneratorExpression",Identifier:"Identifier",IfStatement:"IfStatement",ImportDeclaration:"ImportDeclaration",ImportDefaultSpecifier:"ImportDefaultSpecifier",ImportNamespaceSpecifier:"ImportNamespaceSpecifier",ImportSpecifier:"ImportSpecifier",Literal:"Literal",LabeledStatement:"LabeledStatement",LogicalExpression:"LogicalExpression",MemberExpression:"MemberExpression",MethodDefinition:"MethodDefinition",ModuleSpecifier:"ModuleSpecifier",NewExpression:"NewExpression",ObjectExpression:"ObjectExpression",ObjectPattern:"ObjectPattern",Program:"Program",Property:"Property",ReturnStatement:"ReturnStatement",SequenceExpression:"SequenceExpression",SpreadElement:"SpreadElement",SwitchStatement:"SwitchStatement",SwitchCase:"SwitchCase",TaggedTemplateExpression:"TaggedTemplateExpression",TemplateElement:"TemplateElement",TemplateLiteral:"TemplateLiteral",ThisExpression:"ThisExpression",ThrowStatement:"ThrowStatement",TryStatement:"TryStatement",UnaryExpression:"UnaryExpression",UpdateExpression:"UpdateExpression",VariableDeclaration:"VariableDeclaration",VariableDeclarator:"VariableDeclarator",WhileStatement:"WhileStatement",WithStatement:"WithStatement",YieldExpression:"YieldExpression"};VisitorKeys={AssignmentExpression:["left","right"],ArrayExpression:["elements"],ArrayPattern:["elements"],ArrowFunctionExpression:["params","defaults","rest","body"],AwaitExpression:["argument"],BlockStatement:["body"],BinaryExpression:["left","right"],BreakStatement:["label"],CallExpression:["callee","arguments"],CatchClause:["param","body"],ClassBody:["body"],ClassDeclaration:["id","body","superClass"],ClassExpression:["id","body","superClass"],ComprehensionBlock:["left","right"],ComprehensionExpression:["blocks","filter","body"],ConditionalExpression:["test","consequent","alternate"],ContinueStatement:["label"],DebuggerStatement:[],DirectiveStatement:[],DoWhileStatement:["body","test"],EmptyStatement:[],ExportBatchSpecifier:[],ExportDeclaration:["declaration","specifiers","source"],ExportSpecifier:["id","name"],ExpressionStatement:["expression"],ForStatement:["init","test","update","body"],ForInStatement:["left","right","body"],ForOfStatement:["left","right","body"],FunctionDeclaration:["id","params","defaults","rest","body"],FunctionExpression:["id","params","defaults","rest","body"],GeneratorExpression:["blocks","filter","body"],Identifier:[],IfStatement:["test","consequent","alternate"],ImportDeclaration:["specifiers","source"],ImportDefaultSpecifier:["id"],ImportNamespaceSpecifier:["id"],ImportSpecifier:["id","name"],Literal:[],LabeledStatement:["label","body"],LogicalExpression:["left","right"],MemberExpression:["object","property"],MethodDefinition:["key","value"],ModuleSpecifier:[],NewExpression:["callee","arguments"],ObjectExpression:["properties"],ObjectPattern:["properties"],Program:["body"],Property:["key","value"],ReturnStatement:["argument"],SequenceExpression:["expressions"],SpreadElement:["argument"],SwitchStatement:["discriminant","cases"],SwitchCase:["test","consequent"],TaggedTemplateExpression:["tag","quasi"],TemplateElement:[],TemplateLiteral:["quasis","expressions"],ThisExpression:[],ThrowStatement:["argument"],TryStatement:["block","handlers","handler","guardedHandlers","finalizer"],UnaryExpression:["argument"],UpdateExpression:["argument"],VariableDeclaration:["declarations"],VariableDeclarator:["id","init"],WhileStatement:["test","body"],WithStatement:["object","body"],YieldExpression:["argument"]};BREAK={};SKIP={};REMOVE={};VisitorOption={Break:BREAK,Skip:SKIP,Remove:REMOVE};function Reference(parent,key){this.parent=parent;this.key=key}Reference.prototype.replace=function replace(node){this.parent[this.key]=node};Reference.prototype.remove=function remove(){if(isArray(this.parent)){this.parent.splice(this.key,1);return true}else{this.replace(null);return false}};function Element(node,path,wrap,ref){this.node=node;this.path=path;this.wrap=wrap;this.ref=ref}function Controller(){}Controller.prototype.path=function path(){var i,iz,j,jz,result,element;function addToPath(result,path){if(isArray(path)){for(j=0,jz=path.length;j<jz;++j){result.push(path[j])}}else{result.push(path)}}if(!this.__current.path){return null}result=[];for(i=2,iz=this.__leavelist.length;i<iz;++i){element=this.__leavelist[i];addToPath(result,element.path)}addToPath(result,this.__current.path);return result};Controller.prototype.type=function(){var node=this.current();return node.type||this.__current.wrap};Controller.prototype.parents=function parents(){var i,iz,result;result=[];for(i=1,iz=this.__leavelist.length;i<iz;++i){result.push(this.__leavelist[i].node)}return result};Controller.prototype.current=function current(){return this.__current.node};Controller.prototype.__execute=function __execute(callback,element){var previous,result;result=undefined;previous=this.__current;this.__current=element;this.__state=null;if(callback){result=callback.call(this,element.node,this.__leavelist[this.__leavelist.length-1].node)}this.__current=previous;return result};Controller.prototype.notify=function notify(flag){this.__state=flag};Controller.prototype.skip=function(){this.notify(SKIP)};Controller.prototype["break"]=function(){this.notify(BREAK)};Controller.prototype.remove=function(){this.notify(REMOVE)};Controller.prototype.__initialize=function(root,visitor){this.visitor=visitor;this.root=root;this.__worklist=[];this.__leavelist=[];this.__current=null;this.__state=null;this.__fallback=visitor.fallback==="iteration";this.__keys=VisitorKeys;if(visitor.keys){this.__keys=extend(objectCreate(this.__keys),visitor.keys)}};function isNode(node){if(node==null){return false}return typeof node==="object"&&typeof node.type==="string"}function isProperty(nodeType,key){return(nodeType===Syntax.ObjectExpression||nodeType===Syntax.ObjectPattern)&&"properties"===key}Controller.prototype.traverse=function traverse(root,visitor){var worklist,leavelist,element,node,nodeType,ret,key,current,current2,candidates,candidate,sentinel;this.__initialize(root,visitor);sentinel={};worklist=this.__worklist;leavelist=this.__leavelist;worklist.push(new Element(root,null,null,null));leavelist.push(new Element(null,null,null,null));while(worklist.length){element=worklist.pop();if(element===sentinel){element=leavelist.pop();ret=this.__execute(visitor.leave,element);if(this.__state===BREAK||ret===BREAK){return}continue}if(element.node){ret=this.__execute(visitor.enter,element);if(this.__state===BREAK||ret===BREAK){return}worklist.push(sentinel);leavelist.push(element);if(this.__state===SKIP||ret===SKIP){continue}node=element.node;nodeType=element.wrap||node.type;candidates=this.__keys[nodeType];if(!candidates){if(this.__fallback){candidates=objectKeys(node)}else{throw new Error("Unknown node type "+nodeType+".")}}current=candidates.length;while((current-=1)>=0){key=candidates[current];candidate=node[key];if(!candidate){continue}if(isArray(candidate)){current2=candidate.length;while((current2-=1)>=0){if(!candidate[current2]){continue}if(isProperty(nodeType,candidates[current])){element=new Element(candidate[current2],[key,current2],"Property",null)}else if(isNode(candidate[current2])){element=new Element(candidate[current2],[key,current2],null,null)}else{continue}worklist.push(element)}}else if(isNode(candidate)){worklist.push(new Element(candidate,key,null,null))}}}}};Controller.prototype.replace=function replace(root,visitor){function removeElem(element){var i,key,nextElem,parent;if(element.ref.remove()){key=element.ref.key;parent=element.ref.parent;i=worklist.length;while(i--){nextElem=worklist[i];if(nextElem.ref&&nextElem.ref.parent===parent){if(nextElem.ref.key<key){break}--nextElem.ref.key}}}}var worklist,leavelist,node,nodeType,target,element,current,current2,candidates,candidate,sentinel,outer,key;this.__initialize(root,visitor);sentinel={};worklist=this.__worklist;leavelist=this.__leavelist;outer={root:root};element=new Element(root,null,null,new Reference(outer,"root"));worklist.push(element);leavelist.push(element);while(worklist.length){element=worklist.pop();if(element===sentinel){element=leavelist.pop();target=this.__execute(visitor.leave,element);if(target!==undefined&&target!==BREAK&&target!==SKIP&&target!==REMOVE){element.ref.replace(target)}if(this.__state===REMOVE||target===REMOVE){removeElem(element)}if(this.__state===BREAK||target===BREAK){return outer.root}continue}target=this.__execute(visitor.enter,element);if(target!==undefined&&target!==BREAK&&target!==SKIP&&target!==REMOVE){element.ref.replace(target);element.node=target}if(this.__state===REMOVE||target===REMOVE){removeElem(element);element.node=null}if(this.__state===BREAK||target===BREAK){return outer.root}node=element.node;if(!node){continue}worklist.push(sentinel);leavelist.push(element);if(this.__state===SKIP||target===SKIP){continue}nodeType=element.wrap||node.type;candidates=this.__keys[nodeType];if(!candidates){if(this.__fallback){candidates=objectKeys(node)}else{throw new Error("Unknown node type "+nodeType+".")}}current=candidates.length;while((current-=1)>=0){key=candidates[current];candidate=node[key];if(!candidate){continue}if(isArray(candidate)){current2=candidate.length;while((current2-=1)>=0){if(!candidate[current2]){continue}if(isProperty(nodeType,candidates[current])){element=new Element(candidate[current2],[key,current2],"Property",new Reference(candidate,current2))}else if(isNode(candidate[current2])){element=new Element(candidate[current2],[key,current2],null,new Reference(candidate,current2))}else{continue}worklist.push(element)}}else if(isNode(candidate)){worklist.push(new Element(candidate,key,null,new Reference(node,key)))}}}return outer.root};function traverse(root,visitor){var controller=new Controller;return controller.traverse(root,visitor)}function replace(root,visitor){var controller=new Controller;return controller.replace(root,visitor)}function extendCommentRange(comment,tokens){var target;target=upperBound(tokens,function search(token){return token.range[0]>comment.range[0]});comment.extendedRange=[comment.range[0],comment.range[1]];if(target!==tokens.length){comment.extendedRange[1]=tokens[target].range[0]}target-=1;if(target>=0){comment.extendedRange[0]=tokens[target].range[1]}return comment}function attachComments(tree,providedComments,tokens){var comments=[],comment,len,i,cursor;if(!tree.range){throw new Error("attachComments needs range information")}if(!tokens.length){if(providedComments.length){for(i=0,len=providedComments.length;i<len;i+=1){comment=deepCopy(providedComments[i]);comment.extendedRange=[0,tree.range[0]];comments.push(comment)}tree.leadingComments=comments}return tree}for(i=0,len=providedComments.length;i<len;i+=1){comments.push(extendCommentRange(deepCopy(providedComments[i]),tokens))}cursor=0;traverse(tree,{enter:function(node){var comment;while(cursor<comments.length){comment=comments[cursor];if(comment.extendedRange[1]>node.range[0]){break}if(comment.extendedRange[1]===node.range[0]){if(!node.leadingComments){node.leadingComments=[]}node.leadingComments.push(comment);comments.splice(cursor,1)}else{cursor+=1}}if(cursor===comments.length){return VisitorOption.Break}if(comments[cursor].extendedRange[0]>node.range[1]){return VisitorOption.Skip}}});cursor=0;traverse(tree,{leave:function(node){var comment;while(cursor<comments.length){comment=comments[cursor];if(node.range[1]<comment.extendedRange[0]){break}if(node.range[1]===comment.extendedRange[0]){if(!node.trailingComments){node.trailingComments=[]}node.trailingComments.push(comment);comments.splice(cursor,1)}else{cursor+=1}}if(cursor===comments.length){return VisitorOption.Break}if(comments[cursor].extendedRange[0]>node.range[1]){return VisitorOption.Skip}}});return tree}exports.version="1.8.1-dev";exports.Syntax=Syntax;exports.traverse=traverse;exports.replace=replace;exports.attachComments=attachComments;exports.VisitorKeys=VisitorKeys;exports.VisitorOption=VisitorOption;exports.Controller=Controller;exports.cloneEnvironment=function(){return clone({})};return exports})},{}],182:[function(require,module,exports){(function(){"use strict";function isExpression(node){if(node==null){return false}switch(node.type){case"ArrayExpression":case"AssignmentExpression":case"BinaryExpression":case"CallExpression":case"ConditionalExpression":case"FunctionExpression":case"Identifier":case"Literal":case"LogicalExpression":case"MemberExpression":case"NewExpression":case"ObjectExpression":case"SequenceExpression":case"ThisExpression":case"UnaryExpression":case"UpdateExpression":return true}return false}function isIterationStatement(node){if(node==null){return false}switch(node.type){case"DoWhileStatement":case"ForInStatement":case"ForStatement":case"WhileStatement":return true}return false}function isStatement(node){if(node==null){return false}switch(node.type){case"BlockStatement":case"BreakStatement":case"ContinueStatement":case"DebuggerStatement":case"DoWhileStatement":case"EmptyStatement":case"ExpressionStatement":case"ForInStatement":case"ForStatement":case"IfStatement":case"LabeledStatement":case"ReturnStatement":case"SwitchStatement":case"ThrowStatement":case"TryStatement":case"VariableDeclaration":case"WhileStatement":case"WithStatement":return true}return false}function isSourceElement(node){return isStatement(node)||node!=null&&node.type==="FunctionDeclaration"}function trailingStatement(node){switch(node.type){case"IfStatement":if(node.alternate!=null){return node.alternate}return node.consequent;case"LabeledStatement":case"ForStatement":case"ForInStatement":case"WhileStatement":case"WithStatement":return node.body}return null}function isProblematicIfStatement(node){var current;if(node.type!=="IfStatement"){return false}if(node.alternate==null){return false}current=node.consequent;do{if(current.type==="IfStatement"){if(current.alternate==null){return true}}current=trailingStatement(current)}while(current);return false}module.exports={isExpression:isExpression,isStatement:isStatement,isIterationStatement:isIterationStatement,isSourceElement:isSourceElement,isProblematicIfStatement:isProblematicIfStatement,trailingStatement:trailingStatement}})()},{}],183:[function(require,module,exports){(function(){"use strict";var Regex,NON_ASCII_WHITESPACES;Regex={NonAsciiIdentifierStart:new RegExp("[ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԧԱ-Ֆՙա-ևא-תװ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࢠࢢ-ࢬऄ-हऽॐक़-ॡॱ-ॷॹ-ॿঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-ళవ-హఽౘౙౠౡಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽೞೠೡೱೲഅ-ഌഎ-ഐഒ-ഺഽൎൠൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄງຈຊຍດ-ທນ-ຟມ-ຣລວສຫອ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏼᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛰᜀ-ᜌᜎ-ᜑᜠ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡷᢀ-ᢨᢪᢰ-ᣵᤀ-ᤜᥐ-ᥭᥰ-ᥴᦀ-ᦫᧁ-ᧇᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭋᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᳩ-ᳬᳮ-ᳱᳵᳶᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕℙ-ℝℤΩℨK-ℭℯ-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-Ⱞⰰ-ⱞⱠ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞⸯ々-〇〡-〩〱-〵〸-〼ぁ-ゖゝ-ゟァ-ヺー-ヿㄅ-ㄭㄱ-ㆎㆠ-ㆺㇰ-ㇿ㐀-䶵一-鿌ꀀ-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚗꚠ-ꛯꜗ-ꜟꜢ-ꞈꞋ-ꞎꞐ-ꞓꞠ-Ɦꟸ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꪀ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꯀ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ]"),NonAsciiIdentifierPart:new RegExp("[ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮ̀-ʹͶͷͺ-ͽΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁ҃-҇Ҋ-ԧԱ-Ֆՙա-և֑-ׇֽֿׁׂׅׄא-תװ-ײؐ-ؚؠ-٩ٮ-ۓە-ۜ۟-۪ۨ-ۼۿܐ-݊ݍ-ޱ߀-ߵߺࠀ-࠭ࡀ-࡛ࢠࢢ-ࢬࣤ-ࣾऀ-ॣ०-९ॱ-ॷॹ-ॿঁ-ঃঅ-ঌএঐও-নপ-রলশ-হ়-ৄেৈো-ৎৗড়ঢ়য়-ৣ০-ৱਁ-ਃਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹ਼ਾ-ੂੇੈੋ-੍ੑਖ਼-ੜਫ਼੦-ੵઁ-ઃઅ-ઍએ-ઑઓ-નપ-રલળવ-હ઼-ૅે-ૉો-્ૐૠ-ૣ૦-૯ଁ-ଃଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହ଼-ୄେୈୋ-୍ୖୗଡ଼ଢ଼ୟ-ୣ୦-୯ୱஂஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹா-ூெ-ைொ-்ௐௗ௦-௯ఁ-ఃఅ-ఌఎ-ఐఒ-నప-ళవ-హఽ-ౄె-ైొ-్ౕౖౘౙౠ-ౣ౦-౯ಂಃಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹ಼-ೄೆ-ೈೊ-್ೕೖೞೠ-ೣ೦-೯ೱೲംഃഅ-ഌഎ-ഐഒ-ഺഽ-ൄെ-ൈൊ-ൎൗൠ-ൣ൦-൯ൺ-ൿංඃඅ-ඖක-නඳ-රලව-ෆ්ා-ුූෘ-ෟෲෳก-ฺเ-๎๐-๙ກຂຄງຈຊຍດ-ທນ-ຟມ-ຣລວສຫອ-ູົ-ຽເ-ໄໆ່-ໍ໐-໙ໜ-ໟༀ༘༙༠-༩༹༵༷༾-ཇཉ-ཬཱ-྄྆-ྗྙ-ྼ࿆က-၉ၐ-ႝႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚ፝-፟ᎀ-ᎏᎠ-Ᏼᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛰᜀ-ᜌᜎ-᜔ᜠ-᜴ᝀ-ᝓᝠ-ᝬᝮ-ᝰᝲᝳក-៓ៗៜ៝០-៩᠋-᠍᠐-᠙ᠠ-ᡷᢀ-ᢪᢰ-ᣵᤀ-ᤜᤠ-ᤫᤰ-᤻᥆-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉ᧐-᧙ᨀ-ᨛᨠ-ᩞ᩠-᩿᩼-᪉᪐-᪙ᪧᬀ-ᭋ᭐-᭙᭫-᭳ᮀ-᯳ᰀ-᰷᱀-᱉ᱍ-ᱽ᳐-᳔᳒-ᳶᴀ-ᷦ᷼-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼ‌‍‿⁀⁔ⁱⁿₐ-ₜ⃐-⃥⃜⃡-⃰ℂℇℊ-ℓℕℙ-ℝℤΩℨK-ℭℯ-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-Ⱞⰰ-ⱞⱠ-ⳤⳫ-ⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯ⵿-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞⷠ-ⷿⸯ々-〇〡-〯〱-〵〸-〼ぁ-ゖ゙゚ゝ-ゟァ-ヺー-ヿㄅ-ㄭㄱ-ㆎㆠ-ㆺㇰ-ㇿ㐀-䶵一-鿌ꀀ-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘫꙀ-꙯ꙴ-꙽ꙿ-ꚗꚟ-꛱ꜗ-ꜟꜢ-ꞈꞋ-ꞎꞐ-ꞓꞠ-Ɦꟸ-ꠧꡀ-ꡳꢀ-꣄꣐-꣙꣠-ꣷꣻ꤀-꤭ꤰ-꥓ꥠ-ꥼꦀ-꧀ꧏ-꧙ꨀ-ꨶꩀ-ꩍ꩐-꩙ꩠ-ꩶꩺꩻꪀ-ꫂꫛ-ꫝꫠ-ꫯꫲ-꫶ꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꯀ-ꯪ꯬꯭꯰-꯹가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻ︀-️︠-︦︳︴﹍-﹏ﹰ-ﹴﹶ-ﻼ0-9A-Z_a-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ]")};function isDecimalDigit(ch){return ch>=48&&ch<=57}function isHexDigit(ch){return isDecimalDigit(ch)||97<=ch&&ch<=102||65<=ch&&ch<=70}function isOctalDigit(ch){return ch>=48&&ch<=55}NON_ASCII_WHITESPACES=[5760,6158,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8239,8287,12288,65279];function isWhiteSpace(ch){return ch===32||ch===9||ch===11||ch===12||ch===160||ch>=5760&&NON_ASCII_WHITESPACES.indexOf(ch)>=0}function isLineTerminator(ch){return ch===10||ch===13||ch===8232||ch===8233}function isIdentifierStart(ch){return ch>=97&&ch<=122||ch>=65&&ch<=90||ch===36||ch===95||ch===92||ch>=128&&Regex.NonAsciiIdentifierStart.test(String.fromCharCode(ch))}function isIdentifierPart(ch){return ch>=97&&ch<=122||ch>=65&&ch<=90||ch>=48&&ch<=57||ch===36||ch===95||ch===92||ch>=128&&Regex.NonAsciiIdentifierPart.test(String.fromCharCode(ch))}module.exports={isDecimalDigit:isDecimalDigit,isHexDigit:isHexDigit,isOctalDigit:isOctalDigit,isWhiteSpace:isWhiteSpace,isLineTerminator:isLineTerminator,isIdentifierStart:isIdentifierStart,isIdentifierPart:isIdentifierPart}})()},{}],184:[function(require,module,exports){(function(){"use strict";var code=require("./code");function isStrictModeReservedWordES6(id){switch(id){case"implements":case"interface":case"package":case"private":case"protected":case"public":case"static":case"let":return true;default:return false}}function isKeywordES5(id,strict){if(!strict&&id==="yield"){return false}return isKeywordES6(id,strict)}function isKeywordES6(id,strict){if(strict&&isStrictModeReservedWordES6(id)){return true}switch(id.length){case 2:return id==="if"||id==="in"||id==="do";case 3:return id==="var"||id==="for"||id==="new"||id==="try";case 4:return id==="this"||id==="else"||id==="case"||id==="void"||id==="with"||id==="enum";case 5:return id==="while"||id==="break"||id==="catch"||id==="throw"||id==="const"||id==="yield"||id==="class"||id==="super";case 6:return id==="return"||id==="typeof"||id==="delete"||id==="switch"||id==="export"||id==="import";case 7:return id==="default"||id==="finally"||id==="extends";case 8:return id==="function"||id==="continue"||id==="debugger";case 10:return id==="instanceof";default:return false}}function isReservedWordES5(id,strict){return id==="null"||id==="true"||id==="false"||isKeywordES5(id,strict)}function isReservedWordES6(id,strict){return id==="null"||id==="true"||id==="false"||isKeywordES6(id,strict)}function isRestrictedWord(id){return id==="eval"||id==="arguments"}function isIdentifierName(id){var i,iz,ch;if(id.length===0){return false}ch=id.charCodeAt(0);if(!code.isIdentifierStart(ch)||ch===92){return false}for(i=1,iz=id.length;i<iz;++i){ch=id.charCodeAt(i);if(!code.isIdentifierPart(ch)||ch===92){return false}}return true}function isIdentifierES5(id,strict){return isIdentifierName(id)&&!isReservedWordES5(id,strict)}function isIdentifierES6(id,strict){return isIdentifierName(id)&&!isReservedWordES6(id,strict)}module.exports={isKeywordES5:isKeywordES5,isKeywordES6:isKeywordES6,isReservedWordES5:isReservedWordES5,isReservedWordES6:isReservedWordES6,isRestrictedWord:isRestrictedWord,isIdentifierName:isIdentifierName,isIdentifierES5:isIdentifierES5,isIdentifierES6:isIdentifierES6}})()},{"./code":183}],185:[function(require,module,exports){(function(){"use strict";exports.ast=require("./ast");exports.code=require("./code");exports.keyword=require("./keyword")})()},{"./ast":182,"./code":183,"./keyword":184}],186:[function(require,module,exports){module.exports={builtin:{Array:false,ArrayBuffer:false,Boolean:false,constructor:false,Date:false,decodeURI:false,decodeURIComponent:false,encodeURI:false,encodeURIComponent:false,Error:false,eval:false,EvalError:false,Float32Array:false,Float64Array:false,Function:false,hasOwnProperty:false,Infinity:false,Int16Array:false,Int32Array:false,Int8Array:false,isFinite:false,isNaN:false,isPrototypeOf:false,JSON:false,Map:false,Math:false,NaN:false,Number:false,Object:false,parseFloat:false,parseInt:false,Promise:false,propertyIsEnumerable:false,Proxy:false,RangeError:false,ReferenceError:false,Reflect:false,RegExp:false,Set:false,String:false,Symbol:false,SyntaxError:false,System:false,toLocaleString:false,toString:false,TypeError:false,Uint16Array:false,Uint32Array:false,Uint8Array:false,Uint8ClampedArray:false,undefined:false,URIError:false,valueOf:false,WeakMap:false,WeakSet:false},nonstandard:{escape:false,unescape:false},browser:{addEventListener:false,alert:false,applicationCache:false,atob:false,Audio:false,AudioProcessingEvent:false,BeforeUnloadEvent:false,Blob:false,blur:false,btoa:false,cancelAnimationFrame:false,CanvasGradient:false,CanvasPattern:false,CanvasRenderingContext2D:false,clearInterval:false,clearTimeout:false,close:false,closed:false,CloseEvent:false,Comment:false,CompositionEvent:false,confirm:false,console:false,crypto:false,CSS:false,CustomEvent:false,DataView:false,Debug:false,defaultStatus:false,devicePixelRatio:false,dispatchEvent:false,document:false,Document:false,DocumentFragment:false,DOMParser:false,DragEvent:false,Element:false,ElementTimeControl:false,ErrorEvent:false,event:false,Event:false,FileReader:false,find:false,focus:false,FocusEvent:false,FormData:false,frameElement:false,frames:false,GamepadEvent:false,getComputedStyle:false,getSelection:false,HashChangeEvent:false,history:false,HTMLAnchorElement:false,HTMLBaseElement:false,HTMLBlockquoteElement:false,HTMLBodyElement:false,HTMLBRElement:false,HTMLButtonElement:false,HTMLCanvasElement:false,HTMLDirectoryElement:false,HTMLDivElement:false,HTMLDListElement:false,HTMLElement:false,HTMLFieldSetElement:false,HTMLFontElement:false,HTMLFormElement:false,HTMLFrameElement:false,HTMLFrameSetElement:false,HTMLHeadElement:false,HTMLHeadingElement:false,HTMLHRElement:false,HTMLHtmlElement:false,HTMLIFrameElement:false,HTMLImageElement:false,HTMLInputElement:false,HTMLIsIndexElement:false,HTMLLabelElement:false,HTMLLayerElement:false,HTMLLegendElement:false,HTMLLIElement:false,HTMLLinkElement:false,HTMLMapElement:false,HTMLMenuElement:false,HTMLMetaElement:false,HTMLModElement:false,HTMLObjectElement:false,HTMLOListElement:false,HTMLOptGroupElement:false,HTMLOptionElement:false,HTMLParagraphElement:false,HTMLParamElement:false,HTMLPreElement:false,HTMLQuoteElement:false,HTMLScriptElement:false,HTMLSelectElement:false,HTMLStyleElement:false,HTMLTableCaptionElement:false,HTMLTableCellElement:false,HTMLTableColElement:false,HTMLTableElement:false,HTMLTableRowElement:false,HTMLTableSectionElement:false,HTMLTextAreaElement:false,HTMLTitleElement:false,HTMLUListElement:false,HTMLVideoElement:false,IDBCursor:false,IDBCursorWithValue:false,IDBDatabase:false,IDBEnvironment:false,IDBFactory:false,IDBIndex:false,IDBKeyRange:false,IDBObjectStore:false,IDBOpenDBRequest:false,IDBRequest:false,IDBTransaction:false,IDBVersionChangeEvent:false,Image:false,indexedDB:false,innerHeight:false,innerWidth:false,InputEvent:false,Intl:false,KeyboardEvent:false,length:false,localStorage:false,location:false,matchMedia:false,MessageChannel:false,MessageEvent:false,MessagePort:false,MouseEvent:false,moveBy:false,moveTo:false,MutationObserver:false,name:false,navigator:false,Node:false,NodeFilter:false,NodeList:false,Notification:false,OfflineAudioCompletionEvent:false,onbeforeunload:true,onblur:true,onerror:true,onfocus:true,onload:true,onresize:true,onunload:true,open:false,openDatabase:false,opener:false,opera:false,Option:false,outerHeight:false,outerWidth:false,PageTransitionEvent:false,pageXOffset:false,pageYOffset:false,parent:false,PopStateEvent:false,postMessage:false,print:false,ProgressEvent:false,prompt:false,Range:false,removeEventListener:false,requestAnimationFrame:false,resizeBy:false,resizeTo:false,screen:false,screenX:false,screenY:false,scroll:false,scrollbars:false,scrollBy:false,scrollTo:false,scrollX:false,scrollY:false,self:false,sessionStorage:false,setInterval:false,setTimeout:false,SharedWorker:false,showModalDialog:false,status:false,stop:false,StorageEvent:false,SVGAElement:false,SVGAltGlyphDefElement:false,SVGAltGlyphElement:false,SVGAltGlyphItemElement:false,SVGAngle:false,SVGAnimateColorElement:false,SVGAnimatedAngle:false,SVGAnimatedBoolean:false,SVGAnimatedEnumeration:false,SVGAnimatedInteger:false,SVGAnimatedLength:false,SVGAnimatedLengthList:false,SVGAnimatedNumber:false,SVGAnimatedNumberList:false,SVGAnimatedPathData:false,SVGAnimatedPoints:false,SVGAnimatedPreserveAspectRatio:false,SVGAnimatedRect:false,SVGAnimatedString:false,SVGAnimatedTransformList:false,SVGAnimateElement:false,SVGAnimateMotionElement:false,SVGAnimateTransformElement:false,SVGAnimationElement:false,SVGCircleElement:false,SVGClipPathElement:false,SVGColor:false,SVGColorProfileElement:false,SVGColorProfileRule:false,SVGComponentTransferFunctionElement:false,SVGCSSRule:false,SVGCursorElement:false,SVGDefsElement:false,SVGDescElement:false,SVGDocument:false,SVGElement:false,SVGElementInstance:false,SVGElementInstanceList:false,SVGEllipseElement:false,SVGEvent:false,SVGExternalResourcesRequired:false,SVGFEBlendElement:false,SVGFEColorMatrixElement:false,SVGFEComponentTransferElement:false,SVGFECompositeElement:false,SVGFEConvolveMatrixElement:false,SVGFEDiffuseLightingElement:false,SVGFEDisplacementMapElement:false,SVGFEDistantLightElement:false,SVGFEFloodElement:false,SVGFEFuncAElement:false,SVGFEFuncBElement:false,SVGFEFuncGElement:false,SVGFEFuncRElement:false,SVGFEGaussianBlurElement:false,SVGFEImageElement:false,SVGFEMergeElement:false,SVGFEMergeNodeElement:false,SVGFEMorphologyElement:false,SVGFEOffsetElement:false,SVGFEPointLightElement:false,SVGFESpecularLightingElement:false,SVGFESpotLightElement:false,SVGFETileElement:false,SVGFETurbulenceElement:false,SVGFilterElement:false,SVGFilterPrimitiveStandardAttributes:false,SVGFitToViewBox:false,SVGFontElement:false,SVGFontFaceElement:false,SVGFontFaceFormatElement:false,SVGFontFaceNameElement:false,SVGFontFaceSrcElement:false,SVGFontFaceUriElement:false,SVGForeignObjectElement:false,SVGGElement:false,SVGGlyphElement:false,SVGGlyphRefElement:false,SVGGradientElement:false,SVGHKernElement:false,SVGICCColor:false,SVGImageElement:false,SVGLangSpace:false,SVGLength:false,SVGLengthList:false,SVGLinearGradientElement:false,SVGLineElement:false,SVGLocatable:false,SVGMarkerElement:false,SVGMaskElement:false,SVGMatrix:false,SVGMetadataElement:false,SVGMissingGlyphElement:false,SVGMPathElement:false,SVGNumber:false,SVGNumberList:false,SVGPaint:false,SVGPathElement:false,SVGPathSeg:false,SVGPathSegArcAbs:false,SVGPathSegArcRel:false,SVGPathSegClosePath:false,SVGPathSegCurvetoCubicAbs:false,SVGPathSegCurvetoCubicRel:false,SVGPathSegCurvetoCubicSmoothAbs:false,SVGPathSegCurvetoCubicSmoothRel:false,SVGPathSegCurvetoQuadraticAbs:false,SVGPathSegCurvetoQuadraticRel:false,SVGPathSegCurvetoQuadraticSmoothAbs:false,SVGPathSegCurvetoQuadraticSmoothRel:false,SVGPathSegLinetoAbs:false,SVGPathSegLinetoHorizontalAbs:false,SVGPathSegLinetoHorizontalRel:false,SVGPathSegLinetoRel:false,SVGPathSegLinetoVerticalAbs:false,SVGPathSegLinetoVerticalRel:false,SVGPathSegList:false,SVGPathSegMovetoAbs:false,SVGPathSegMovetoRel:false,SVGPatternElement:false,SVGPoint:false,SVGPointList:false,SVGPolygonElement:false,SVGPolylineElement:false,SVGPreserveAspectRatio:false,SVGRadialGradientElement:false,SVGRect:false,SVGRectElement:false,SVGRenderingIntent:false,SVGScriptElement:false,SVGSetElement:false,SVGStopElement:false,SVGStringList:false,SVGStylable:false,SVGStyleElement:false,SVGSVGElement:false,SVGSwitchElement:false,SVGSymbolElement:false,SVGTests:false,SVGTextContentElement:false,SVGTextElement:false,SVGTextPathElement:false,SVGTextPositioningElement:false,SVGTitleElement:false,SVGTransform:false,SVGTransformable:false,SVGTransformList:false,SVGTRefElement:false,SVGTSpanElement:false,SVGUnitTypes:false,SVGURIReference:false,SVGUseElement:false,SVGViewElement:false,SVGViewSpec:false,SVGVKernElement:false,SVGZoomAndPan:false,Text:false,TextDecoder:false,TextEncoder:false,TimeEvent:false,top:false,TouchEvent:false,UIEvent:false,URL:false,WebGLActiveInfo:false,WebGLBuffer:false,WebGLContextEvent:false,WebGLFramebuffer:false,WebGLProgram:false,WebGLRenderbuffer:false,WebGLRenderingContext:false,WebGLShader:false,WebGLShaderPrecisionFormat:false,WebGLTexture:false,WebGLUniformLocation:false,WebSocket:false,WheelEvent:false,window:false,Window:false,Worker:false,XDomainRequest:false,XMLHttpRequest:false,XMLSerializer:false,XPathEvaluator:false,XPathException:false,XPathExpression:false,XPathNamespace:false,XPathNSResolver:false,XPathResult:false},worker:{importScripts:true,postMessage:true,self:true},node:{__dirname:false,__filename:false,arguments:false,Buffer:false,clearImmediate:false,clearInterval:false,clearTimeout:false,console:false,DataView:false,exports:true,GLOBAL:false,global:false,module:false,process:false,require:false,setImmediate:false,setInterval:false,setTimeout:false},amd:{define:false,require:false},mocha:{after:false,afterEach:false,before:false,beforeEach:false,context:false,describe:false,it:false,setup:false,specify:false,suite:false,suiteSetup:false,suiteTeardown:false,teardown:false,test:false,xcontext:false,xdescribe:false,xit:false,xspecify:false},jasmine:{afterAll:false,afterEach:false,beforeAll:false,beforeEach:false,describe:false,expect:false,fail:false,fdescribe:false,fit:false,it:false,jasmine:false,pending:false,runs:false,spyOn:false,waits:false,waitsFor:false,xdescribe:false,xit:false},qunit:{asyncTest:false,deepEqual:false,equal:false,expect:false,module:false,notDeepEqual:false,notEqual:false,notPropEqual:false,notStrictEqual:false,ok:false,propEqual:false,QUnit:false,raises:false,start:false,stop:false,strictEqual:false,test:false,"throws":false},phantomjs:{console:true,exports:true,phantom:true,require:true,WebPage:true},couch:{emit:false,exports:false,getRow:false,log:false,module:false,provides:false,require:false,respond:false,send:false,start:false,sum:false},rhino:{defineClass:false,deserialize:false,gc:false,help:false,importClass:false,importPackage:false,java:false,load:false,loadClass:false,Packages:false,print:false,quit:false,readFile:false,readUrl:false,runCommand:false,seal:false,serialize:false,spawn:false,sync:false,toint32:false,version:false},wsh:{ActiveXObject:true,Enumerator:true,GetObject:true,ScriptEngine:true,ScriptEngineBuildVersion:true,ScriptEngineMajorVersion:true,ScriptEngineMinorVersion:true,VBArray:true,WScript:true,WSH:true,XDomainRequest:true},jquery:{$:false,jQuery:false},yui:{Y:false,YUI:false,YUI_config:false},shelljs:{cat:false,cd:false,chmod:false,config:false,cp:false,dirs:false,echo:false,env:false,error:false,exec:false,exit:false,find:false,grep:false,ls:false,mkdir:false,mv:false,popd:false,pushd:false,pwd:false,rm:false,sed:false,target:false,tempdir:false,test:false,which:false},prototypejs:{$:false,$$:false,$A:false,$break:false,$continue:false,$F:false,$H:false,$R:false,$w:false,Abstract:false,Ajax:false,Autocompleter:false,Builder:false,Class:false,Control:false,Draggable:false,Draggables:false,Droppables:false,Effect:false,Element:false,Enumerable:false,Event:false,Field:false,Form:false,Hash:false,Insertion:false,ObjectRange:false,PeriodicalExecuter:false,Position:false,Prototype:false,Scriptaculous:false,Selector:false,Sortable:false,SortableObserver:false,Sound:false,Template:false,Toggle:false,Try:false},meteor:{$:false,_:false,Accounts:false,App:false,Assets:false,Blaze:false,check:false,Cordova:false,DDP:false,DDPServer:false,Deps:false,EJSON:false,Email:false,HTTP:false,Log:false,Match:false,Meteor:false,Mongo:false,MongoInternals:false,Npm:false,Package:false,Plugin:false,process:false,Random:false,ReactiveDict:false,ReactiveVar:false,Router:false,Session:false,share:false,Spacebars:false,Template:false,Tinytest:false,Tracker:false,UI:false,Utils:false,WebApp:false,WebAppInternals:false},mongo:{_isWindows:false,_rand:false,BulkWriteResult:false,cat:false,cd:false,connect:false,db:false,getHostName:false,getMemInfo:false,hostname:false,listFiles:false,load:false,ls:false,md5sumFile:false,mkdir:false,Mongo:false,ObjectId:false,PlanCache:false,pwd:false,quit:false,removeFile:false,rs:false,sh:false,UUID:false,version:false,WriteResult:false}} },{}],187:[function(require,module,exports){module.exports=require("./globals.json")},{"./globals.json":186}],188:[function(require,module,exports){var isNaN=require("is-nan");var isFinite=require("is-finite");module.exports=Number.isInteger||function(val){return typeof val==="number"&&!isNaN(val)&&isFinite(val)&&parseInt(val,10)===val}},{"is-finite":189,"is-nan":190}],189:[function(require,module,exports){"use strict";module.exports=Number.isFinite||function(val){if(typeof val!=="number"||val!==val||val===Infinity||val===-Infinity){return false}return true}},{}],190:[function(require,module,exports){"use strict";module.exports=function isNaN(value){return value!==value}},{}],191:[function(require,module,exports){module.exports=/((['"])(?:(?!\2|\\).|\\(?:\r\n|[\s\S]))*(\2)?|`(?:[^`\\$]|\\[\s\S]|\$(?!\{)|\$\{(?:[^{}]|\{[^}]*\}?)*\}?)*(`)?)|(\/\/.*)|(\/\*(?:[^*]|\*(?!\/))*(\*\/)?)|(\/(?!\*)(?:\[(?:(?![\]\\]).|\\.)*\]|(?![\/\]\\]).|\\.)+\/(?:(?!\s*(?:\b|[\u0080-\uFFFF$\\'"~({]|[+\-!](?!=)|\.?\d))|[gmiyu]{1,5}\b(?![\u0080-\uFFFF$\\]|\s*(?:[+\-*%&|^<>!=?({]|\/(?![\/*])))))|((?:0[xX][\da-fA-F]+|0[oO][0-7]+|0[bB][01]+|(?:\d*\.\d+|\d+\.?)(?:[eE][+-]?\d+)?))|((?!\d)(?:(?!\s)[$\w\u0080-\uFFFF]|\\u[\da-fA-F]{4}|\\u\{[\da-fA-F]{1,6}\})+)|(--|\+\+|&&|\|\||=>|\.{3}|(?:[+\-*\/%&|^]|<{1,2}|>{1,3}|!=?|={1,2})=?|[?:~]|[;,.[\](){}])|(\s+)|(^$|[\s\S])/g;module.exports.matchToToken=function(match){token={type:"invalid",value:match[0]};if(match[1])token.type="string",token.closed=!!(match[3]||match[4]);else if(match[5])token.type="comment";else if(match[6])token.type="comment",token.closed=!!match[7];else if(match[8])token.type="regex";else if(match[9])token.type="number";else if(match[10])token.type="name";else if(match[11])token.type="punctuator";else if(match[12])token.type="whitespace";return token}},{}],192:[function(require,module,exports){var arr=[];var charCodeCache=[];module.exports=function(a,b){if(a===b){return 0}var aLen=a.length;var bLen=b.length;if(aLen===0){return bLen}if(bLen===0){return aLen}var bCharCode;var ret;var tmp;var tmp2;var i=0;var j=0;while(i<aLen){charCodeCache[i]=a.charCodeAt(i);arr[i]=++i}while(j<bLen){bCharCode=b.charCodeAt(j);tmp=j++;ret=j;for(i=0;i<aLen;i++){tmp2=bCharCode===charCodeCache[i]?tmp:tmp+1;tmp=arr[i];ret=arr[i]=tmp>ret?tmp2>ret?ret+1:tmp2:tmp2>tmp?tmp+1:tmp2}}return ret}},{}],193:[function(require,module,exports){var leftPad=require("left-pad");function get(options,key,defaultValue){return key in options?options[key]:defaultValue}function lineNumbers(code,options){var getOption=get.bind(null,options||{});var transform=getOption("transform",Function.prototype);var padding=getOption("padding"," ");var before=getOption("before"," ");var after=getOption("after"," | ");var start=getOption("start",1);var isArray=Array.isArray(code);var lines=isArray?code:code.split("\n");var end=start+lines.length-1;var width=String(end).length;var numbered=lines.map(function(line,index){var number=start+index;var params={before:before,number:number,width:width,after:after,line:line};transform(params);return params.before+leftPad(params.number,width,padding)+params.after+params.line});return isArray?numbered:numbered.join("\n")}module.exports=lineNumbers},{"left-pad":194}],194:[function(require,module,exports){module.exports=leftpad;function leftpad(str,len,ch){str=String(str);var i=-1;ch||(ch=" ");len=len-str.length;while(++i<len){str=ch+str}return str}},{}],195:[function(require,module,exports){function compact(array){var index=-1,length=array?array.length:0,resIndex=-1,result=[];while(++index<length){var value=array[index];if(value){result[++resIndex]=value}}return result}module.exports=compact},{}],196:[function(require,module,exports){var baseFlatten=require("../internal/baseFlatten"),isIterateeCall=require("../internal/isIterateeCall");function flatten(array,isDeep,guard){var length=array?array.length:0;if(guard&&isIterateeCall(array,isDeep,guard)){isDeep=false}return length?baseFlatten(array,isDeep):[]}module.exports=flatten},{"../internal/baseFlatten":226,"../internal/isIterateeCall":272}],197:[function(require,module,exports){function last(array){var length=array?array.length:0;return length?array[length-1]:undefined}module.exports=last},{}],198:[function(require,module,exports){var baseIndexOf=require("../internal/baseIndexOf");var arrayProto=Array.prototype;var splice=arrayProto.splice;function pull(){var array=arguments[0];if(!(array&&array.length)){return array}var index=0,indexOf=baseIndexOf,length=arguments.length;while(++index<length){var fromIndex=0,value=arguments[index];while((fromIndex=indexOf(array,value,fromIndex))>-1){splice.call(array,fromIndex,1)}}return array}module.exports=pull},{"../internal/baseIndexOf":231}],199:[function(require,module,exports){var baseCallback=require("../internal/baseCallback"),baseUniq=require("../internal/baseUniq"),isIterateeCall=require("../internal/isIterateeCall"),sortedUniq=require("../internal/sortedUniq");function uniq(array,isSorted,iteratee,thisArg){var length=array?array.length:0;if(!length){return[]}if(isSorted!=null&&typeof isSorted!="boolean"){thisArg=iteratee;iteratee=isIterateeCall(array,isSorted,thisArg)?null:isSorted;isSorted=false}iteratee=iteratee==null?iteratee:baseCallback(iteratee,thisArg,3);return isSorted?sortedUniq(array,iteratee):baseUniq(array,iteratee)}module.exports=uniq},{"../internal/baseCallback":219,"../internal/baseUniq":245,"../internal/isIterateeCall":272,"../internal/sortedUniq":282}],200:[function(require,module,exports){module.exports=require("./includes")},{"./includes":204}],201:[function(require,module,exports){module.exports=require("./forEach")},{"./forEach":202}],202:[function(require,module,exports){var arrayEach=require("../internal/arrayEach"),baseEach=require("../internal/baseEach"),bindCallback=require("../internal/bindCallback"),isArray=require("../lang/isArray");function forEach(collection,iteratee,thisArg){return typeof iteratee=="function"&&typeof thisArg=="undefined"&&isArray(collection)?arrayEach(collection,iteratee):baseEach(collection,bindCallback(iteratee,thisArg,3))}module.exports=forEach},{"../internal/arrayEach":213,"../internal/baseEach":224,"../internal/bindCallback":247,"../lang/isArray":287}],203:[function(require,module,exports){var createAggregator=require("../internal/createAggregator");var objectProto=Object.prototype;var hasOwnProperty=objectProto.hasOwnProperty;var groupBy=createAggregator(function(result,value,key){if(hasOwnProperty.call(result,key)){result[key].push(value)}else{result[key]=[value]}});module.exports=groupBy},{"../internal/createAggregator":254}],204:[function(require,module,exports){var baseIndexOf=require("../internal/baseIndexOf"),isArray=require("../lang/isArray"),isLength=require("../internal/isLength"),isString=require("../lang/isString"),values=require("../object/values");var nativeMax=Math.max;function includes(collection,target,fromIndex){var length=collection?collection.length:0;if(!isLength(length)){collection=values(collection);length=collection.length}if(!length){return false}if(typeof fromIndex=="number"){fromIndex=fromIndex<0?nativeMax(length+fromIndex,0):fromIndex||0}else{fromIndex=0}return typeof collection=="string"||!isArray(collection)&&isString(collection)?fromIndex<length&&collection.indexOf(target,fromIndex)>-1:baseIndexOf(collection,target,fromIndex)>-1}module.exports=includes},{"../internal/baseIndexOf":231,"../internal/isLength":273,"../lang/isArray":287,"../lang/isString":295,"../object/values":303}],205:[function(require,module,exports){var arrayMap=require("../internal/arrayMap"),baseCallback=require("../internal/baseCallback"),baseMap=require("../internal/baseMap"),isArray=require("../lang/isArray");function map(collection,iteratee,thisArg){var func=isArray(collection)?arrayMap:baseMap;iteratee=baseCallback(iteratee,thisArg,3);return func(collection,iteratee)}module.exports=map},{"../internal/arrayMap":214,"../internal/baseCallback":219,"../internal/baseMap":236,"../lang/isArray":287}],206:[function(require,module,exports){var arrayReduceRight=require("../internal/arrayReduceRight"),baseCallback=require("../internal/baseCallback"),baseEachRight=require("../internal/baseEachRight"),baseReduce=require("../internal/baseReduce"),isArray=require("../lang/isArray");function reduceRight(collection,iteratee,accumulator,thisArg){var func=isArray(collection)?arrayReduceRight:baseReduce;return func(collection,baseCallback(iteratee,thisArg,4),accumulator,arguments.length<3,baseEachRight)}module.exports=reduceRight},{"../internal/arrayReduceRight":215,"../internal/baseCallback":219,"../internal/baseEachRight":225,"../internal/baseReduce":240,"../lang/isArray":287}],207:[function(require,module,exports){var arraySome=require("../internal/arraySome"),baseCallback=require("../internal/baseCallback"),baseSome=require("../internal/baseSome"),isArray=require("../lang/isArray");function some(collection,predicate,thisArg){var func=isArray(collection)?arraySome:baseSome;if(typeof predicate!="function"||typeof thisArg!="undefined"){predicate=baseCallback(predicate,thisArg,3)}return func(collection,predicate)}module.exports=some},{"../internal/arraySome":216,"../internal/baseCallback":219,"../internal/baseSome":242,"../lang/isArray":287}],208:[function(require,module,exports){var baseCallback=require("../internal/baseCallback"),baseEach=require("../internal/baseEach"),baseSortBy=require("../internal/baseSortBy"),compareAscending=require("../internal/compareAscending"),isIterateeCall=require("../internal/isIterateeCall"),isLength=require("../internal/isLength");function sortBy(collection,iteratee,thisArg){var index=-1,length=collection?collection.length:0,result=isLength(length)?Array(length):[];if(thisArg&&isIterateeCall(collection,iteratee,thisArg)){iteratee=null}iteratee=baseCallback(iteratee,thisArg,3);baseEach(collection,function(value,key,collection){result[++index]={criteria:iteratee(value,key,collection),index:index,value:value}});return baseSortBy(result,compareAscending)}module.exports=sortBy},{"../internal/baseCallback":219,"../internal/baseEach":224,"../internal/baseSortBy":243,"../internal/compareAscending":251,"../internal/isIterateeCall":272,"../internal/isLength":273}],209:[function(require,module,exports){var isNative=require("../lang/isNative");var nativeNow=isNative(nativeNow=Date.now)&&nativeNow;var now=nativeNow||function(){return(new Date).getTime()};module.exports=now},{"../lang/isNative":291}],210:[function(require,module,exports){var createWrapper=require("../internal/createWrapper"),isIterateeCall=require("../internal/isIterateeCall");var ARY_FLAG=256;var nativeMax=Math.max;function ary(func,n,guard){if(guard&&isIterateeCall(func,n,guard)){n=null}n=func&&n==null?func.length:nativeMax(+n||0,0);return createWrapper(func,ARY_FLAG,null,null,null,null,n)}module.exports=ary},{"../internal/createWrapper":261,"../internal/isIterateeCall":272}],211:[function(require,module,exports){(function(global){var cachePush=require("./cachePush"),isNative=require("../lang/isNative");var Set=isNative(Set=global.Set)&&Set;var nativeCreate=isNative(nativeCreate=Object.create)&&nativeCreate;function SetCache(values){var length=values?values.length:0;this.data={hash:nativeCreate(null),set:new Set};while(length--){this.push(values[length])}}SetCache.prototype.push=cachePush;module.exports=SetCache}).call(this,typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{})},{"../lang/isNative":291,"./cachePush":250}],212:[function(require,module,exports){function arrayCopy(source,array){var index=-1,length=source.length;array||(array=Array(length));while(++index<length){array[index]=source[index]}return array}module.exports=arrayCopy},{}],213:[function(require,module,exports){function arrayEach(array,iteratee){var index=-1,length=array.length;while(++index<length){if(iteratee(array[index],index,array)===false){break}}return array}module.exports=arrayEach},{}],214:[function(require,module,exports){function arrayMap(array,iteratee){var index=-1,length=array.length,result=Array(length);while(++index<length){result[index]=iteratee(array[index],index,array)}return result}module.exports=arrayMap},{}],215:[function(require,module,exports){function arrayReduceRight(array,iteratee,accumulator,initFromArray){var length=array.length;if(initFromArray&&length){accumulator=array[--length]}while(length--){accumulator=iteratee(accumulator,array[length],length,array)}return accumulator}module.exports=arrayReduceRight},{}],216:[function(require,module,exports){function arraySome(array,predicate){var index=-1,length=array.length;while(++index<length){if(predicate(array[index],index,array)){return true}}return false}module.exports=arraySome},{}],217:[function(require,module,exports){function assignDefaults(objectValue,sourceValue){return typeof objectValue=="undefined"?sourceValue:objectValue}module.exports=assignDefaults},{}],218:[function(require,module,exports){var baseCopy=require("./baseCopy"),keys=require("../object/keys");function baseAssign(object,source,customizer){var props=keys(source);if(!customizer){return baseCopy(source,object,props)}var index=-1,length=props.length;while(++index<length){var key=props[index],value=object[key],result=customizer(value,source[key],key,object,source);if((result===result?result!==value:value===value)||typeof value=="undefined"&&!(key in object)){object[key]=result}}return object}module.exports=baseAssign},{"../object/keys":301,"./baseCopy":222}],219:[function(require,module,exports){var baseMatches=require("./baseMatches"),baseMatchesProperty=require("./baseMatchesProperty"),baseProperty=require("./baseProperty"),bindCallback=require("./bindCallback"),identity=require("../utility/identity"),isBindable=require("./isBindable");function baseCallback(func,thisArg,argCount){var type=typeof func;if(type=="function"){return typeof thisArg!="undefined"&&isBindable(func)?bindCallback(func,thisArg,argCount):func}if(func==null){return identity}if(type=="object"){return baseMatches(func)}return typeof thisArg=="undefined"?baseProperty(func+""):baseMatchesProperty(func+"",thisArg)}module.exports=baseCallback},{"../utility/identity":307,"./baseMatches":237,"./baseMatchesProperty":238,"./baseProperty":239,"./bindCallback":247,"./isBindable":270}],220:[function(require,module,exports){var arrayCopy=require("./arrayCopy"),arrayEach=require("./arrayEach"),baseCopy=require("./baseCopy"),baseForOwn=require("./baseForOwn"),initCloneArray=require("./initCloneArray"),initCloneByTag=require("./initCloneByTag"),initCloneObject=require("./initCloneObject"),isArray=require("../lang/isArray"),isObject=require("../lang/isObject"),keys=require("../object/keys");var argsTag="[object Arguments]",arrayTag="[object Array]",boolTag="[object Boolean]",dateTag="[object Date]",errorTag="[object Error]",funcTag="[object Function]",mapTag="[object Map]",numberTag="[object Number]",objectTag="[object Object]",regexpTag="[object RegExp]",setTag="[object Set]",stringTag="[object String]",weakMapTag="[object WeakMap]";var arrayBufferTag="[object ArrayBuffer]",float32Tag="[object Float32Array]",float64Tag="[object Float64Array]",int8Tag="[object Int8Array]",int16Tag="[object Int16Array]",int32Tag="[object Int32Array]",uint8Tag="[object Uint8Array]",uint8ClampedTag="[object Uint8ClampedArray]",uint16Tag="[object Uint16Array]",uint32Tag="[object Uint32Array]";var cloneableTags={};cloneableTags[argsTag]=cloneableTags[arrayTag]=cloneableTags[arrayBufferTag]=cloneableTags[boolTag]=cloneableTags[dateTag]=cloneableTags[float32Tag]=cloneableTags[float64Tag]=cloneableTags[int8Tag]=cloneableTags[int16Tag]=cloneableTags[int32Tag]=cloneableTags[numberTag]=cloneableTags[objectTag]=cloneableTags[regexpTag]=cloneableTags[stringTag]=cloneableTags[uint8Tag]=cloneableTags[uint8ClampedTag]=cloneableTags[uint16Tag]=cloneableTags[uint32Tag]=true;cloneableTags[errorTag]=cloneableTags[funcTag]=cloneableTags[mapTag]=cloneableTags[setTag]=cloneableTags[weakMapTag]=false;var objectProto=Object.prototype;var objToString=objectProto.toString;function baseClone(value,isDeep,customizer,key,object,stackA,stackB){var result;if(customizer){result=object?customizer(value,key,object):customizer(value)}if(typeof result!="undefined"){return result}if(!isObject(value)){return value}var isArr=isArray(value);if(isArr){result=initCloneArray(value);if(!isDeep){return arrayCopy(value,result)}}else{var tag=objToString.call(value),isFunc=tag==funcTag;if(tag==objectTag||tag==argsTag||isFunc&&!object){result=initCloneObject(isFunc?{}:value);if(!isDeep){return baseCopy(value,result,keys(value))}}else{return cloneableTags[tag]?initCloneByTag(value,tag,isDeep):object?value:{}}}stackA||(stackA=[]);stackB||(stackB=[]);var length=stackA.length;while(length--){if(stackA[length]==value){return stackB[length]}}stackA.push(value);stackB.push(result);(isArr?arrayEach:baseForOwn)(value,function(subValue,key){result[key]=baseClone(subValue,isDeep,customizer,key,value,stackA,stackB)});return result}module.exports=baseClone},{"../lang/isArray":287,"../lang/isObject":293,"../object/keys":301,"./arrayCopy":212,"./arrayEach":213,"./baseCopy":222,"./baseForOwn":228,"./initCloneArray":267,"./initCloneByTag":268,"./initCloneObject":269}],221:[function(require,module,exports){function baseCompareAscending(value,other){if(value!==other){var valIsReflexive=value===value,othIsReflexive=other===other;if(value>other||!valIsReflexive||typeof value=="undefined"&&othIsReflexive){return 1}if(value<other||!othIsReflexive||typeof other=="undefined"&&valIsReflexive){return-1}}return 0}module.exports=baseCompareAscending},{}],222:[function(require,module,exports){function baseCopy(source,object,props){if(!props){props=object;object={}}var index=-1,length=props.length;while(++index<length){var key=props[index];object[key]=source[key]}return object}module.exports=baseCopy},{}],223:[function(require,module,exports){(function(global){var isObject=require("../lang/isObject");var baseCreate=function(){function Object(){}return function(prototype){if(isObject(prototype)){Object.prototype=prototype;var result=new Object;Object.prototype=null}return result||global.Object()}}();module.exports=baseCreate}).call(this,typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{})},{"../lang/isObject":293}],224:[function(require,module,exports){var baseForOwn=require("./baseForOwn"),isLength=require("./isLength"),toObject=require("./toObject");function baseEach(collection,iteratee){var length=collection?collection.length:0;if(!isLength(length)){return baseForOwn(collection,iteratee)}var index=-1,iterable=toObject(collection);while(++index<length){if(iteratee(iterable[index],index,iterable)===false){break}}return collection}module.exports=baseEach},{"./baseForOwn":228,"./isLength":273,"./toObject":283}],225:[function(require,module,exports){var baseForOwnRight=require("./baseForOwnRight"),isLength=require("./isLength"),toObject=require("./toObject");function baseEachRight(collection,iteratee){var length=collection?collection.length:0;if(!isLength(length)){return baseForOwnRight(collection,iteratee)}var iterable=toObject(collection);while(length--){if(iteratee(iterable[length],length,iterable)===false){break}}return collection}module.exports=baseEachRight},{"./baseForOwnRight":229,"./isLength":273,"./toObject":283}],226:[function(require,module,exports){var isArguments=require("../lang/isArguments"),isArray=require("../lang/isArray"),isLength=require("./isLength"),isObjectLike=require("./isObjectLike");function baseFlatten(array,isDeep,isStrict,fromIndex){var index=(fromIndex||0)-1,length=array.length,resIndex=-1,result=[];while(++index<length){var value=array[index];if(isObjectLike(value)&&isLength(value.length)&&(isArray(value)||isArguments(value))){if(isDeep){value=baseFlatten(value,isDeep,isStrict)}var valIndex=-1,valLength=value.length;result.length+=valLength;while(++valIndex<valLength){result[++resIndex]=value[valIndex]}}else if(!isStrict){result[++resIndex]=value}}return result}module.exports=baseFlatten},{"../lang/isArguments":286,"../lang/isArray":287,"./isLength":273,"./isObjectLike":274}],227:[function(require,module,exports){var toObject=require("./toObject");function baseFor(object,iteratee,keysFunc){var index=-1,iterable=toObject(object),props=keysFunc(object),length=props.length;while(++index<length){var key=props[index];if(iteratee(iterable[key],key,iterable)===false){break}}return object}module.exports=baseFor},{"./toObject":283}],228:[function(require,module,exports){var baseFor=require("./baseFor"),keys=require("../object/keys");function baseForOwn(object,iteratee){return baseFor(object,iteratee,keys)}module.exports=baseForOwn},{"../object/keys":301,"./baseFor":227}],229:[function(require,module,exports){var baseForRight=require("./baseForRight"),keys=require("../object/keys");function baseForOwnRight(object,iteratee){return baseForRight(object,iteratee,keys)}module.exports=baseForOwnRight},{"../object/keys":301,"./baseForRight":230}],230:[function(require,module,exports){var toObject=require("./toObject");function baseForRight(object,iteratee,keysFunc){var iterable=toObject(object),props=keysFunc(object),length=props.length;while(length--){var key=props[length];if(iteratee(iterable[key],key,iterable)===false){break}}return object}module.exports=baseForRight},{"./toObject":283}],231:[function(require,module,exports){var indexOfNaN=require("./indexOfNaN");function baseIndexOf(array,value,fromIndex){if(value!==value){return indexOfNaN(array,fromIndex)}var index=(fromIndex||0)-1,length=array.length;while(++index<length){if(array[index]===value){return index}}return-1}module.exports=baseIndexOf},{"./indexOfNaN":266}],232:[function(require,module,exports){var baseIsEqualDeep=require("./baseIsEqualDeep");function baseIsEqual(value,other,customizer,isWhere,stackA,stackB){if(value===other){return value!==0||1/value==1/other}var valType=typeof value,othType=typeof other;if(valType!="function"&&valType!="object"&&othType!="function"&&othType!="object"||value==null||other==null){return value!==value&&other!==other}return baseIsEqualDeep(value,other,baseIsEqual,customizer,isWhere,stackA,stackB)}module.exports=baseIsEqual},{"./baseIsEqualDeep":233}],233:[function(require,module,exports){var equalArrays=require("./equalArrays"),equalByTag=require("./equalByTag"),equalObjects=require("./equalObjects"),isArray=require("../lang/isArray"),isTypedArray=require("../lang/isTypedArray");var argsTag="[object Arguments]",arrayTag="[object Array]",objectTag="[object Object]";var objectProto=Object.prototype;var hasOwnProperty=objectProto.hasOwnProperty;var objToString=objectProto.toString;function baseIsEqualDeep(object,other,equalFunc,customizer,isWhere,stackA,stackB){var objIsArr=isArray(object),othIsArr=isArray(other),objTag=arrayTag,othTag=arrayTag;if(!objIsArr){objTag=objToString.call(object);if(objTag==argsTag){objTag=objectTag}else if(objTag!=objectTag){objIsArr=isTypedArray(object)}}if(!othIsArr){othTag=objToString.call(other);if(othTag==argsTag){othTag=objectTag}else if(othTag!=objectTag){othIsArr=isTypedArray(other)}}var objIsObj=objTag==objectTag,othIsObj=othTag==objectTag,isSameTag=objTag==othTag;if(isSameTag&&!(objIsArr||objIsObj)){return equalByTag(object,other,objTag)}var valWrapped=objIsObj&&hasOwnProperty.call(object,"__wrapped__"),othWrapped=othIsObj&&hasOwnProperty.call(other,"__wrapped__");if(valWrapped||othWrapped){return equalFunc(valWrapped?object.value():object,othWrapped?other.value():other,customizer,isWhere,stackA,stackB)}if(!isSameTag){return false}stackA||(stackA=[]);stackB||(stackB=[]);var length=stackA.length;while(length--){if(stackA[length]==object){return stackB[length]==other}}stackA.push(object);stackB.push(other);var result=(objIsArr?equalArrays:equalObjects)(object,other,equalFunc,customizer,isWhere,stackA,stackB);stackA.pop();stackB.pop();return result}module.exports=baseIsEqualDeep},{"../lang/isArray":287,"../lang/isTypedArray":296,"./equalArrays":262,"./equalByTag":263,"./equalObjects":264}],234:[function(require,module,exports){function baseIsFunction(value){return typeof value=="function"||false}module.exports=baseIsFunction},{}],235:[function(require,module,exports){var baseIsEqual=require("./baseIsEqual");var objectProto=Object.prototype;var hasOwnProperty=objectProto.hasOwnProperty;function baseIsMatch(object,props,values,strictCompareFlags,customizer){var length=props.length;if(object==null){return!length}var index=-1,noCustomizer=!customizer;while(++index<length){if(noCustomizer&&strictCompareFlags[index]?values[index]!==object[props[index]]:!hasOwnProperty.call(object,props[index])){return false}}index=-1;while(++index<length){var key=props[index];if(noCustomizer&&strictCompareFlags[index]){var result=hasOwnProperty.call(object,key)}else{var objValue=object[key],srcValue=values[index];result=customizer?customizer(objValue,srcValue,key):undefined;if(typeof result=="undefined"){result=baseIsEqual(srcValue,objValue,customizer,true)}}if(!result){return false}}return true}module.exports=baseIsMatch},{"./baseIsEqual":232}],236:[function(require,module,exports){var baseEach=require("./baseEach");function baseMap(collection,iteratee){var result=[];baseEach(collection,function(value,key,collection){result.push(iteratee(value,key,collection))});return result}module.exports=baseMap},{"./baseEach":224}],237:[function(require,module,exports){var baseIsMatch=require("./baseIsMatch"),isStrictComparable=require("./isStrictComparable"),keys=require("../object/keys");var objectProto=Object.prototype;var hasOwnProperty=objectProto.hasOwnProperty;function baseMatches(source){var props=keys(source),length=props.length;if(length==1){var key=props[0],value=source[key];if(isStrictComparable(value)){return function(object){return object!=null&&object[key]===value&&hasOwnProperty.call(object,key)}}}var values=Array(length),strictCompareFlags=Array(length);while(length--){value=source[props[length]];values[length]=value;strictCompareFlags[length]=isStrictComparable(value)}return function(object){return baseIsMatch(object,props,values,strictCompareFlags)}}module.exports=baseMatches},{"../object/keys":301,"./baseIsMatch":235,"./isStrictComparable":275}],238:[function(require,module,exports){var baseIsEqual=require("./baseIsEqual"),isStrictComparable=require("./isStrictComparable");function baseMatchesProperty(key,value){if(isStrictComparable(value)){return function(object){return object!=null&&object[key]===value}}return function(object){return object!=null&&baseIsEqual(value,object[key],null,true)}}module.exports=baseMatchesProperty},{"./baseIsEqual":232,"./isStrictComparable":275}],239:[function(require,module,exports){function baseProperty(key){return function(object){return object==null?undefined:object[key]}}module.exports=baseProperty},{}],240:[function(require,module,exports){function baseReduce(collection,iteratee,accumulator,initFromCollection,eachFunc){eachFunc(collection,function(value,index,collection){accumulator=initFromCollection?(initFromCollection=false,value):iteratee(accumulator,value,index,collection)});return accumulator}module.exports=baseReduce},{}],241:[function(require,module,exports){var identity=require("../utility/identity"),metaMap=require("./metaMap");var baseSetData=!metaMap?identity:function(func,data){metaMap.set(func,data);return func};module.exports=baseSetData},{"../utility/identity":307,"./metaMap":277}],242:[function(require,module,exports){var baseEach=require("./baseEach");function baseSome(collection,predicate){var result;baseEach(collection,function(value,index,collection){result=predicate(value,index,collection);return!result});return!!result}module.exports=baseSome},{"./baseEach":224}],243:[function(require,module,exports){function baseSortBy(array,comparer){var length=array.length;array.sort(comparer);while(length--){array[length]=array[length].value}return array}module.exports=baseSortBy},{}],244:[function(require,module,exports){function baseToString(value){if(typeof value=="string"){return value}return value==null?"":value+""}module.exports=baseToString},{}],245:[function(require,module,exports){var baseIndexOf=require("./baseIndexOf"),cacheIndexOf=require("./cacheIndexOf"),createCache=require("./createCache");function baseUniq(array,iteratee){var index=-1,indexOf=baseIndexOf,length=array.length,isCommon=true,isLarge=isCommon&&length>=200,seen=isLarge?createCache():null,result=[];if(seen){indexOf=cacheIndexOf;isCommon=false}else{isLarge=false;seen=iteratee?[]:result}outer:while(++index<length){var value=array[index],computed=iteratee?iteratee(value,index,array):value;if(isCommon&&value===value){var seenIndex=seen.length;while(seenIndex--){if(seen[seenIndex]===computed){continue outer}}if(iteratee){seen.push(computed)}result.push(value)}else if(indexOf(seen,computed)<0){if(iteratee||isLarge){seen.push(computed)}result.push(value)}}return result}module.exports=baseUniq},{"./baseIndexOf":231,"./cacheIndexOf":249,"./createCache":257}],246:[function(require,module,exports){function baseValues(object,props){var index=-1,length=props.length,result=Array(length);while(++index<length){result[index]=object[props[index]]}return result}module.exports=baseValues},{}],247:[function(require,module,exports){var identity=require("../utility/identity");function bindCallback(func,thisArg,argCount){if(typeof func!="function"){return identity}if(typeof thisArg=="undefined"){return func}switch(argCount){case 1:return function(value){return func.call(thisArg,value)};case 3:return function(value,index,collection){return func.call(thisArg,value,index,collection)};case 4:return function(accumulator,value,index,collection){return func.call(thisArg,accumulator,value,index,collection)};case 5:return function(value,other,key,object,source){return func.call(thisArg,value,other,key,object,source)}}return function(){return func.apply(thisArg,arguments)}}module.exports=bindCallback},{"../utility/identity":307}],248:[function(require,module,exports){(function(global){var constant=require("../utility/constant"),isNative=require("../lang/isNative");var ArrayBuffer=isNative(ArrayBuffer=global.ArrayBuffer)&&ArrayBuffer,bufferSlice=isNative(bufferSlice=ArrayBuffer&&new ArrayBuffer(0).slice)&&bufferSlice,floor=Math.floor,Uint8Array=isNative(Uint8Array=global.Uint8Array)&&Uint8Array;var Float64Array=function(){try{var func=isNative(func=global.Float64Array)&&func,result=new func(new ArrayBuffer(10),0,1)&&func}catch(e){}return result}();var FLOAT64_BYTES_PER_ELEMENT=Float64Array?Float64Array.BYTES_PER_ELEMENT:0;function bufferClone(buffer){return bufferSlice.call(buffer,0)}if(!bufferSlice){bufferClone=!(ArrayBuffer&&Uint8Array)?constant(null):function(buffer){var byteLength=buffer.byteLength,floatLength=Float64Array?floor(byteLength/FLOAT64_BYTES_PER_ELEMENT):0,offset=floatLength*FLOAT64_BYTES_PER_ELEMENT,result=new ArrayBuffer(byteLength);if(floatLength){var view=new Float64Array(result,0,floatLength);view.set(new Float64Array(buffer,0,floatLength))}if(byteLength!=offset){view=new Uint8Array(result,offset);view.set(new Uint8Array(buffer,offset))}return result}}module.exports=bufferClone}).call(this,typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{})},{"../lang/isNative":291,"../utility/constant":306}],249:[function(require,module,exports){var isObject=require("../lang/isObject");function cacheIndexOf(cache,value){var data=cache.data,result=typeof value=="string"||isObject(value)?data.set.has(value):data.hash[value];return result?0:-1}module.exports=cacheIndexOf},{"../lang/isObject":293}],250:[function(require,module,exports){var isObject=require("../lang/isObject");function cachePush(value){var data=this.data;if(typeof value=="string"||isObject(value)){data.set.add(value)}else{data.hash[value]=true}}module.exports=cachePush},{"../lang/isObject":293}],251:[function(require,module,exports){var baseCompareAscending=require("./baseCompareAscending"); function compareAscending(object,other){return baseCompareAscending(object.criteria,other.criteria)||object.index-other.index}module.exports=compareAscending},{"./baseCompareAscending":221}],252:[function(require,module,exports){var nativeMax=Math.max;function composeArgs(args,partials,holders){var holdersLength=holders.length,argsIndex=-1,argsLength=nativeMax(args.length-holdersLength,0),leftIndex=-1,leftLength=partials.length,result=Array(argsLength+leftLength);while(++leftIndex<leftLength){result[leftIndex]=partials[leftIndex]}while(++argsIndex<holdersLength){result[holders[argsIndex]]=args[argsIndex]}while(argsLength--){result[leftIndex++]=args[argsIndex++]}return result}module.exports=composeArgs},{}],253:[function(require,module,exports){var nativeMax=Math.max;function composeArgsRight(args,partials,holders){var holdersIndex=-1,holdersLength=holders.length,argsIndex=-1,argsLength=nativeMax(args.length-holdersLength,0),rightIndex=-1,rightLength=partials.length,result=Array(argsLength+rightLength);while(++argsIndex<argsLength){result[argsIndex]=args[argsIndex]}var pad=argsIndex;while(++rightIndex<rightLength){result[pad+rightIndex]=partials[rightIndex]}while(++holdersIndex<holdersLength){result[pad+holders[holdersIndex]]=args[argsIndex++]}return result}module.exports=composeArgsRight},{}],254:[function(require,module,exports){var baseCallback=require("./baseCallback"),baseEach=require("./baseEach"),isArray=require("../lang/isArray");function createAggregator(setter,initializer){return function(collection,iteratee,thisArg){var result=initializer?initializer():{};iteratee=baseCallback(iteratee,thisArg,3);if(isArray(collection)){var index=-1,length=collection.length;while(++index<length){var value=collection[index];setter(result,value,iteratee(value,index,collection),collection)}}else{baseEach(collection,function(value,key,collection){setter(result,value,iteratee(value,key,collection),collection)})}return result}}module.exports=createAggregator},{"../lang/isArray":287,"./baseCallback":219,"./baseEach":224}],255:[function(require,module,exports){var bindCallback=require("./bindCallback"),isIterateeCall=require("./isIterateeCall");function createAssigner(assigner){return function(){var length=arguments.length,object=arguments[0];if(length<2||object==null){return object}if(length>3&&isIterateeCall(arguments[1],arguments[2],arguments[3])){length=2}if(length>3&&typeof arguments[length-2]=="function"){var customizer=bindCallback(arguments[--length-1],arguments[length--],5)}else if(length>2&&typeof arguments[length-1]=="function"){customizer=arguments[--length]}var index=0;while(++index<length){var source=arguments[index];if(source){assigner(object,source,customizer)}}return object}}module.exports=createAssigner},{"./bindCallback":247,"./isIterateeCall":272}],256:[function(require,module,exports){var createCtorWrapper=require("./createCtorWrapper");function createBindWrapper(func,thisArg){var Ctor=createCtorWrapper(func);function wrapper(){return(this instanceof wrapper?Ctor:func).apply(thisArg,arguments)}return wrapper}module.exports=createBindWrapper},{"./createCtorWrapper":258}],257:[function(require,module,exports){(function(global){var SetCache=require("./SetCache"),constant=require("../utility/constant"),isNative=require("../lang/isNative");var Set=isNative(Set=global.Set)&&Set;var nativeCreate=isNative(nativeCreate=Object.create)&&nativeCreate;var createCache=!(nativeCreate&&Set)?constant(null):function(values){return new SetCache(values)};module.exports=createCache}).call(this,typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{})},{"../lang/isNative":291,"../utility/constant":306,"./SetCache":211}],258:[function(require,module,exports){var baseCreate=require("./baseCreate"),isObject=require("../lang/isObject");function createCtorWrapper(Ctor){return function(){var thisBinding=baseCreate(Ctor.prototype),result=Ctor.apply(thisBinding,arguments);return isObject(result)?result:thisBinding}}module.exports=createCtorWrapper},{"../lang/isObject":293,"./baseCreate":223}],259:[function(require,module,exports){var arrayCopy=require("./arrayCopy"),composeArgs=require("./composeArgs"),composeArgsRight=require("./composeArgsRight"),createCtorWrapper=require("./createCtorWrapper"),reorder=require("./reorder"),replaceHolders=require("./replaceHolders");var BIND_FLAG=1,BIND_KEY_FLAG=2,CURRY_BOUND_FLAG=4,CURRY_FLAG=8,CURRY_RIGHT_FLAG=16,PARTIAL_FLAG=32,PARTIAL_RIGHT_FLAG=64,ARY_FLAG=256;var nativeMax=Math.max;function createHybridWrapper(func,bitmask,thisArg,partials,holders,partialsRight,holdersRight,argPos,ary,arity){var isAry=bitmask&ARY_FLAG,isBind=bitmask&BIND_FLAG,isBindKey=bitmask&BIND_KEY_FLAG,isCurry=bitmask&CURRY_FLAG,isCurryBound=bitmask&CURRY_BOUND_FLAG,isCurryRight=bitmask&CURRY_RIGHT_FLAG;var Ctor=!isBindKey&&createCtorWrapper(func),key=func;function wrapper(){var length=arguments.length,index=length,args=Array(length);while(index--){args[index]=arguments[index]}if(partials){args=composeArgs(args,partials,holders)}if(partialsRight){args=composeArgsRight(args,partialsRight,holdersRight)}if(isCurry||isCurryRight){var placeholder=wrapper.placeholder,argsHolders=replaceHolders(args,placeholder);length-=argsHolders.length;if(length<arity){var newArgPos=argPos?arrayCopy(argPos):null,newArity=nativeMax(arity-length,0),newsHolders=isCurry?argsHolders:null,newHoldersRight=isCurry?null:argsHolders,newPartials=isCurry?args:null,newPartialsRight=isCurry?null:args;bitmask|=isCurry?PARTIAL_FLAG:PARTIAL_RIGHT_FLAG;bitmask&=~(isCurry?PARTIAL_RIGHT_FLAG:PARTIAL_FLAG);if(!isCurryBound){bitmask&=~(BIND_FLAG|BIND_KEY_FLAG)}var result=createHybridWrapper(func,bitmask,thisArg,newPartials,newsHolders,newPartialsRight,newHoldersRight,newArgPos,ary,newArity);result.placeholder=placeholder;return result}}var thisBinding=isBind?thisArg:this;if(isBindKey){func=thisBinding[key]}if(argPos){args=reorder(args,argPos)}if(isAry&&ary<args.length){args.length=ary}return(this instanceof wrapper?Ctor||createCtorWrapper(func):func).apply(thisBinding,args)}return wrapper}module.exports=createHybridWrapper},{"./arrayCopy":212,"./composeArgs":252,"./composeArgsRight":253,"./createCtorWrapper":258,"./reorder":278,"./replaceHolders":279}],260:[function(require,module,exports){var createCtorWrapper=require("./createCtorWrapper");var BIND_FLAG=1;function createPartialWrapper(func,bitmask,thisArg,partials){var isBind=bitmask&BIND_FLAG,Ctor=createCtorWrapper(func);function wrapper(){var argsIndex=-1,argsLength=arguments.length,leftIndex=-1,leftLength=partials.length,args=Array(argsLength+leftLength);while(++leftIndex<leftLength){args[leftIndex]=partials[leftIndex]}while(argsLength--){args[leftIndex++]=arguments[++argsIndex]}return(this instanceof wrapper?Ctor:func).apply(isBind?thisArg:this,args)}return wrapper}module.exports=createPartialWrapper},{"./createCtorWrapper":258}],261:[function(require,module,exports){var baseSetData=require("./baseSetData"),createBindWrapper=require("./createBindWrapper"),createHybridWrapper=require("./createHybridWrapper"),createPartialWrapper=require("./createPartialWrapper"),getData=require("./getData"),mergeData=require("./mergeData"),setData=require("./setData");var BIND_FLAG=1,BIND_KEY_FLAG=2,PARTIAL_FLAG=32,PARTIAL_RIGHT_FLAG=64;var FUNC_ERROR_TEXT="Expected a function";var nativeMax=Math.max;function createWrapper(func,bitmask,thisArg,partials,holders,argPos,ary,arity){var isBindKey=bitmask&BIND_KEY_FLAG;if(!isBindKey&&typeof func!="function"){throw new TypeError(FUNC_ERROR_TEXT)}var length=partials?partials.length:0;if(!length){bitmask&=~(PARTIAL_FLAG|PARTIAL_RIGHT_FLAG);partials=holders=null}length-=holders?holders.length:0;if(bitmask&PARTIAL_RIGHT_FLAG){var partialsRight=partials,holdersRight=holders;partials=holders=null}var data=!isBindKey&&getData(func),newData=[func,bitmask,thisArg,partials,holders,partialsRight,holdersRight,argPos,ary,arity];if(data&&data!==true){mergeData(newData,data);bitmask=newData[1];arity=newData[9]}newData[9]=arity==null?isBindKey?0:func.length:nativeMax(arity-length,0)||0;if(bitmask==BIND_FLAG){var result=createBindWrapper(newData[0],newData[2])}else if((bitmask==PARTIAL_FLAG||bitmask==(BIND_FLAG|PARTIAL_FLAG))&&!newData[4].length){result=createPartialWrapper.apply(undefined,newData)}else{result=createHybridWrapper.apply(undefined,newData)}var setter=data?baseSetData:setData;return setter(result,newData)}module.exports=createWrapper},{"./baseSetData":241,"./createBindWrapper":256,"./createHybridWrapper":259,"./createPartialWrapper":260,"./getData":265,"./mergeData":276,"./setData":280}],262:[function(require,module,exports){function equalArrays(array,other,equalFunc,customizer,isWhere,stackA,stackB){var index=-1,arrLength=array.length,othLength=other.length,result=true;if(arrLength!=othLength&&!(isWhere&&othLength>arrLength)){return false}while(result&&++index<arrLength){var arrValue=array[index],othValue=other[index];result=undefined;if(customizer){result=isWhere?customizer(othValue,arrValue,index):customizer(arrValue,othValue,index)}if(typeof result=="undefined"){if(isWhere){var othIndex=othLength;while(othIndex--){othValue=other[othIndex];result=arrValue&&arrValue===othValue||equalFunc(arrValue,othValue,customizer,isWhere,stackA,stackB);if(result){break}}}else{result=arrValue&&arrValue===othValue||equalFunc(arrValue,othValue,customizer,isWhere,stackA,stackB)}}}return!!result}module.exports=equalArrays},{}],263:[function(require,module,exports){var boolTag="[object Boolean]",dateTag="[object Date]",errorTag="[object Error]",numberTag="[object Number]",regexpTag="[object RegExp]",stringTag="[object String]";function equalByTag(object,other,tag){switch(tag){case boolTag:case dateTag:return+object==+other;case errorTag:return object.name==other.name&&object.message==other.message;case numberTag:return object!=+object?other!=+other:object==0?1/object==1/other:object==+other;case regexpTag:case stringTag:return object==other+""}return false}module.exports=equalByTag},{}],264:[function(require,module,exports){var keys=require("../object/keys");var objectProto=Object.prototype;var hasOwnProperty=objectProto.hasOwnProperty;function equalObjects(object,other,equalFunc,customizer,isWhere,stackA,stackB){var objProps=keys(object),objLength=objProps.length,othProps=keys(other),othLength=othProps.length;if(objLength!=othLength&&!isWhere){return false}var hasCtor,index=-1;while(++index<objLength){var key=objProps[index],result=hasOwnProperty.call(other,key);if(result){var objValue=object[key],othValue=other[key];result=undefined;if(customizer){result=isWhere?customizer(othValue,objValue,key):customizer(objValue,othValue,key)}if(typeof result=="undefined"){result=objValue&&objValue===othValue||equalFunc(objValue,othValue,customizer,isWhere,stackA,stackB)}}if(!result){return false}hasCtor||(hasCtor=key=="constructor")}if(!hasCtor){var objCtor=object.constructor,othCtor=other.constructor;if(objCtor!=othCtor&&("constructor"in object&&"constructor"in other)&&!(typeof objCtor=="function"&&objCtor instanceof objCtor&&typeof othCtor=="function"&&othCtor instanceof othCtor)){return false}}return true}module.exports=equalObjects},{"../object/keys":301}],265:[function(require,module,exports){var metaMap=require("./metaMap"),noop=require("../utility/noop");var getData=!metaMap?noop:function(func){return metaMap.get(func)};module.exports=getData},{"../utility/noop":308,"./metaMap":277}],266:[function(require,module,exports){function indexOfNaN(array,fromIndex,fromRight){var length=array.length,index=fromRight?fromIndex||length:(fromIndex||0)-1;while(fromRight?index--:++index<length){var other=array[index];if(other!==other){return index}}return-1}module.exports=indexOfNaN},{}],267:[function(require,module,exports){var objectProto=Object.prototype;var hasOwnProperty=objectProto.hasOwnProperty;function initCloneArray(array){var length=array.length,result=new array.constructor(length);if(length&&typeof array[0]=="string"&&hasOwnProperty.call(array,"index")){result.index=array.index;result.input=array.input}return result}module.exports=initCloneArray},{}],268:[function(require,module,exports){var bufferClone=require("./bufferClone");var boolTag="[object Boolean]",dateTag="[object Date]",numberTag="[object Number]",regexpTag="[object RegExp]",stringTag="[object String]";var arrayBufferTag="[object ArrayBuffer]",float32Tag="[object Float32Array]",float64Tag="[object Float64Array]",int8Tag="[object Int8Array]",int16Tag="[object Int16Array]",int32Tag="[object Int32Array]",uint8Tag="[object Uint8Array]",uint8ClampedTag="[object Uint8ClampedArray]",uint16Tag="[object Uint16Array]",uint32Tag="[object Uint32Array]";var reFlags=/\w*$/;function initCloneByTag(object,tag,isDeep){var Ctor=object.constructor;switch(tag){case arrayBufferTag:return bufferClone(object);case boolTag:case dateTag:return new Ctor(+object);case float32Tag:case float64Tag:case int8Tag:case int16Tag:case int32Tag:case uint8Tag:case uint8ClampedTag:case uint16Tag:case uint32Tag:var buffer=object.buffer;return new Ctor(isDeep?bufferClone(buffer):buffer,object.byteOffset,object.length);case numberTag:case stringTag:return new Ctor(object);case regexpTag:var result=new Ctor(object.source,reFlags.exec(object));result.lastIndex=object.lastIndex}return result}module.exports=initCloneByTag},{"./bufferClone":248}],269:[function(require,module,exports){function initCloneObject(object){var Ctor=object.constructor;if(!(typeof Ctor=="function"&&Ctor instanceof Ctor)){Ctor=Object}return new Ctor}module.exports=initCloneObject},{}],270:[function(require,module,exports){var baseSetData=require("./baseSetData"),isNative=require("../lang/isNative"),support=require("../support");var reFuncName=/^\s*function[ \n\r\t]+\w/;var reThis=/\bthis\b/;var fnToString=Function.prototype.toString;function isBindable(func){var result=!(support.funcNames?func.name:support.funcDecomp);if(!result){var source=fnToString.call(func);if(!support.funcNames){result=!reFuncName.test(source)}if(!result){result=reThis.test(source)||isNative(func);baseSetData(func,result)}}return result}module.exports=isBindable},{"../lang/isNative":291,"../support":305,"./baseSetData":241}],271:[function(require,module,exports){var MAX_SAFE_INTEGER=Math.pow(2,53)-1;function isIndex(value,length){value=+value;length=length==null?MAX_SAFE_INTEGER:length;return value>-1&&value%1==0&&value<length}module.exports=isIndex},{}],272:[function(require,module,exports){var isIndex=require("./isIndex"),isLength=require("./isLength"),isObject=require("../lang/isObject");function isIterateeCall(value,index,object){if(!isObject(object)){return false}var type=typeof index;if(type=="number"){var length=object.length,prereq=isLength(length)&&isIndex(index,length)}else{prereq=type=="string"&&index in object}if(prereq){var other=object[index];return value===value?value===other:other!==other}return false}module.exports=isIterateeCall},{"../lang/isObject":293,"./isIndex":271,"./isLength":273}],273:[function(require,module,exports){var MAX_SAFE_INTEGER=Math.pow(2,53)-1;function isLength(value){return typeof value=="number"&&value>-1&&value%1==0&&value<=MAX_SAFE_INTEGER}module.exports=isLength},{}],274:[function(require,module,exports){function isObjectLike(value){return value&&typeof value=="object"||false}module.exports=isObjectLike},{}],275:[function(require,module,exports){var isObject=require("../lang/isObject");function isStrictComparable(value){return value===value&&(value===0?1/value>0:!isObject(value))}module.exports=isStrictComparable},{"../lang/isObject":293}],276:[function(require,module,exports){var arrayCopy=require("./arrayCopy"),composeArgs=require("./composeArgs"),composeArgsRight=require("./composeArgsRight"),replaceHolders=require("./replaceHolders");var BIND_FLAG=1,BIND_KEY_FLAG=2,CURRY_BOUND_FLAG=4,CURRY_RIGHT_FLAG=16,REARG_FLAG=128,ARY_FLAG=256;var PLACEHOLDER="__lodash_placeholder__";var nativeMin=Math.min;function mergeData(data,source){var bitmask=data[1],srcBitmask=source[1],newBitmask=bitmask|srcBitmask;var arityFlags=ARY_FLAG|REARG_FLAG,bindFlags=BIND_FLAG|BIND_KEY_FLAG,comboFlags=arityFlags|bindFlags|CURRY_BOUND_FLAG|CURRY_RIGHT_FLAG;var isAry=bitmask&ARY_FLAG&&!(srcBitmask&ARY_FLAG),isRearg=bitmask&REARG_FLAG&&!(srcBitmask&REARG_FLAG),argPos=(isRearg?data:source)[7],ary=(isAry?data:source)[8];var isCommon=!(bitmask>=REARG_FLAG&&srcBitmask>bindFlags)&&!(bitmask>bindFlags&&srcBitmask>=REARG_FLAG);var isCombo=newBitmask>=arityFlags&&newBitmask<=comboFlags&&(bitmask<REARG_FLAG||(isRearg||isAry)&&argPos.length<=ary);if(!(isCommon||isCombo)){return data}if(srcBitmask&BIND_FLAG){data[2]=source[2];newBitmask|=bitmask&BIND_FLAG?0:CURRY_BOUND_FLAG}var value=source[3];if(value){var partials=data[3];data[3]=partials?composeArgs(partials,value,source[4]):arrayCopy(value);data[4]=partials?replaceHolders(data[3],PLACEHOLDER):arrayCopy(source[4])}value=source[5];if(value){partials=data[5];data[5]=partials?composeArgsRight(partials,value,source[6]):arrayCopy(value);data[6]=partials?replaceHolders(data[5],PLACEHOLDER):arrayCopy(source[6])}value=source[7];if(value){data[7]=arrayCopy(value)}if(srcBitmask&ARY_FLAG){data[8]=data[8]==null?source[8]:nativeMin(data[8],source[8])}if(data[9]==null){data[9]=source[9]}data[0]=source[0];data[1]=newBitmask;return data}module.exports=mergeData},{"./arrayCopy":212,"./composeArgs":252,"./composeArgsRight":253,"./replaceHolders":279}],277:[function(require,module,exports){(function(global){var isNative=require("../lang/isNative");var WeakMap=isNative(WeakMap=global.WeakMap)&&WeakMap;var metaMap=WeakMap&&new WeakMap;module.exports=metaMap}).call(this,typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{})},{"../lang/isNative":291}],278:[function(require,module,exports){var arrayCopy=require("./arrayCopy"),isIndex=require("./isIndex");var nativeMin=Math.min;function reorder(array,indexes){var arrLength=array.length,length=nativeMin(indexes.length,arrLength),oldArray=arrayCopy(array);while(length--){var index=indexes[length];array[length]=isIndex(index,arrLength)?oldArray[index]:undefined}return array}module.exports=reorder},{"./arrayCopy":212,"./isIndex":271}],279:[function(require,module,exports){var PLACEHOLDER="__lodash_placeholder__";function replaceHolders(array,placeholder){var index=-1,length=array.length,resIndex=-1,result=[];while(++index<length){if(array[index]===placeholder){array[index]=PLACEHOLDER;result[++resIndex]=index}}return result}module.exports=replaceHolders},{}],280:[function(require,module,exports){var baseSetData=require("./baseSetData"),now=require("../date/now");var HOT_COUNT=150,HOT_SPAN=16;var setData=function(){var count=0,lastCalled=0;return function(key,value){var stamp=now(),remaining=HOT_SPAN-(stamp-lastCalled);lastCalled=stamp;if(remaining>0){if(++count>=HOT_COUNT){return key}}else{count=0}return baseSetData(key,value)}}();module.exports=setData},{"../date/now":209,"./baseSetData":241}],281:[function(require,module,exports){var isArguments=require("../lang/isArguments"),isArray=require("../lang/isArray"),isIndex=require("./isIndex"),isLength=require("./isLength"),keysIn=require("../object/keysIn"),support=require("../support");var objectProto=Object.prototype;var hasOwnProperty=objectProto.hasOwnProperty;function shimKeys(object){var props=keysIn(object),propsLength=props.length,length=propsLength&&object.length;var allowIndexes=length&&isLength(length)&&(isArray(object)||support.nonEnumArgs&&isArguments(object));var index=-1,result=[];while(++index<propsLength){var key=props[index];if(allowIndexes&&isIndex(key,length)||hasOwnProperty.call(object,key)){result.push(key)}}return result}module.exports=shimKeys},{"../lang/isArguments":286,"../lang/isArray":287,"../object/keysIn":302,"../support":305,"./isIndex":271,"./isLength":273}],282:[function(require,module,exports){function sortedUniq(array,iteratee){var seen,index=-1,length=array.length,resIndex=-1,result=[];while(++index<length){var value=array[index],computed=iteratee?iteratee(value,index,array):value;if(!index||seen!==computed){seen=computed;result[++resIndex]=value}}return result}module.exports=sortedUniq},{}],283:[function(require,module,exports){var isObject=require("../lang/isObject");function toObject(value){return isObject(value)?value:Object(value)}module.exports=toObject},{"../lang/isObject":293}],284:[function(require,module,exports){var baseClone=require("../internal/baseClone"),bindCallback=require("../internal/bindCallback"),isIterateeCall=require("../internal/isIterateeCall");function clone(value,isDeep,customizer,thisArg){if(isDeep&&typeof isDeep!="boolean"&&isIterateeCall(value,isDeep,customizer)){isDeep=false}else if(typeof isDeep=="function"){thisArg=customizer;customizer=isDeep;isDeep=false}customizer=typeof customizer=="function"&&bindCallback(customizer,thisArg,1);return baseClone(value,isDeep,customizer)}module.exports=clone},{"../internal/baseClone":220,"../internal/bindCallback":247,"../internal/isIterateeCall":272}],285:[function(require,module,exports){var baseClone=require("../internal/baseClone"),bindCallback=require("../internal/bindCallback");function cloneDeep(value,customizer,thisArg){customizer=typeof customizer=="function"&&bindCallback(customizer,thisArg,1);return baseClone(value,true,customizer)}module.exports=cloneDeep},{"../internal/baseClone":220,"../internal/bindCallback":247}],286:[function(require,module,exports){var isLength=require("../internal/isLength"),isObjectLike=require("../internal/isObjectLike");var argsTag="[object Arguments]";var objectProto=Object.prototype;var objToString=objectProto.toString;function isArguments(value){var length=isObjectLike(value)?value.length:undefined;return isLength(length)&&objToString.call(value)==argsTag||false}module.exports=isArguments},{"../internal/isLength":273,"../internal/isObjectLike":274}],287:[function(require,module,exports){var isLength=require("../internal/isLength"),isNative=require("./isNative"),isObjectLike=require("../internal/isObjectLike");var arrayTag="[object Array]";var objectProto=Object.prototype;var objToString=objectProto.toString;var nativeIsArray=isNative(nativeIsArray=Array.isArray)&&nativeIsArray;var isArray=nativeIsArray||function(value){return isObjectLike(value)&&isLength(value.length)&&objToString.call(value)==arrayTag||false};module.exports=isArray},{"../internal/isLength":273,"../internal/isObjectLike":274,"./isNative":291}],288:[function(require,module,exports){var isObjectLike=require("../internal/isObjectLike");var boolTag="[object Boolean]";var objectProto=Object.prototype;var objToString=objectProto.toString;function isBoolean(value){return value===true||value===false||isObjectLike(value)&&objToString.call(value)==boolTag||false}module.exports=isBoolean},{"../internal/isObjectLike":274}],289:[function(require,module,exports){var isArguments=require("./isArguments"),isArray=require("./isArray"),isFunction=require("./isFunction"),isLength=require("../internal/isLength"),isObjectLike=require("../internal/isObjectLike"),isString=require("./isString"),keys=require("../object/keys");function isEmpty(value){if(value==null){return true}var length=value.length;if(isLength(length)&&(isArray(value)||isString(value)||isArguments(value)||isObjectLike(value)&&isFunction(value.splice))){return!length}return!keys(value).length}module.exports=isEmpty},{"../internal/isLength":273,"../internal/isObjectLike":274,"../object/keys":301,"./isArguments":286,"./isArray":287,"./isFunction":290,"./isString":295}],290:[function(require,module,exports){(function(global){var baseIsFunction=require("../internal/baseIsFunction"),isNative=require("./isNative");var funcTag="[object Function]";var objectProto=Object.prototype;var objToString=objectProto.toString;var Uint8Array=isNative(Uint8Array=global.Uint8Array)&&Uint8Array;var isFunction=!(baseIsFunction(/x/)||Uint8Array&&!baseIsFunction(Uint8Array))?baseIsFunction:function(value){return objToString.call(value)==funcTag};module.exports=isFunction}).call(this,typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{})},{"../internal/baseIsFunction":234,"./isNative":291}],291:[function(require,module,exports){var escapeRegExp=require("../string/escapeRegExp"),isObjectLike=require("../internal/isObjectLike");var funcTag="[object Function]";var reHostCtor=/^\[object .+?Constructor\]$/;var objectProto=Object.prototype;var fnToString=Function.prototype.toString;var objToString=objectProto.toString;var reNative=RegExp("^"+escapeRegExp(objToString).replace(/toString|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function isNative(value){if(value==null){return false}if(objToString.call(value)==funcTag){return reNative.test(fnToString.call(value))}return isObjectLike(value)&&reHostCtor.test(value)||false}module.exports=isNative},{"../internal/isObjectLike":274,"../string/escapeRegExp":304}],292:[function(require,module,exports){var isObjectLike=require("../internal/isObjectLike");var numberTag="[object Number]";var objectProto=Object.prototype;var objToString=objectProto.toString;function isNumber(value){return typeof value=="number"||isObjectLike(value)&&objToString.call(value)==numberTag||false}module.exports=isNumber},{"../internal/isObjectLike":274}],293:[function(require,module,exports){function isObject(value){var type=typeof value;return type=="function"||value&&type=="object"||false}module.exports=isObject},{}],294:[function(require,module,exports){var isObjectLike=require("../internal/isObjectLike");var regexpTag="[object RegExp]";var objectProto=Object.prototype;var objToString=objectProto.toString;function isRegExp(value){return isObjectLike(value)&&objToString.call(value)==regexpTag||false}module.exports=isRegExp},{"../internal/isObjectLike":274}],295:[function(require,module,exports){var isObjectLike=require("../internal/isObjectLike");var stringTag="[object String]";var objectProto=Object.prototype;var objToString=objectProto.toString;function isString(value){return typeof value=="string"||isObjectLike(value)&&objToString.call(value)==stringTag||false}module.exports=isString},{"../internal/isObjectLike":274}],296:[function(require,module,exports){var isLength=require("../internal/isLength"),isObjectLike=require("../internal/isObjectLike");var argsTag="[object Arguments]",arrayTag="[object Array]",boolTag="[object Boolean]",dateTag="[object Date]",errorTag="[object Error]",funcTag="[object Function]",mapTag="[object Map]",numberTag="[object Number]",objectTag="[object Object]",regexpTag="[object RegExp]",setTag="[object Set]",stringTag="[object String]",weakMapTag="[object WeakMap]";var arrayBufferTag="[object ArrayBuffer]",float32Tag="[object Float32Array]",float64Tag="[object Float64Array]",int8Tag="[object Int8Array]",int16Tag="[object Int16Array]",int32Tag="[object Int32Array]",uint8Tag="[object Uint8Array]",uint8ClampedTag="[object Uint8ClampedArray]",uint16Tag="[object Uint16Array]",uint32Tag="[object Uint32Array]";var typedArrayTags={};typedArrayTags[float32Tag]=typedArrayTags[float64Tag]=typedArrayTags[int8Tag]=typedArrayTags[int16Tag]=typedArrayTags[int32Tag]=typedArrayTags[uint8Tag]=typedArrayTags[uint8ClampedTag]=typedArrayTags[uint16Tag]=typedArrayTags[uint32Tag]=true;typedArrayTags[argsTag]=typedArrayTags[arrayTag]=typedArrayTags[arrayBufferTag]=typedArrayTags[boolTag]=typedArrayTags[dateTag]=typedArrayTags[errorTag]=typedArrayTags[funcTag]=typedArrayTags[mapTag]=typedArrayTags[numberTag]=typedArrayTags[objectTag]=typedArrayTags[regexpTag]=typedArrayTags[setTag]=typedArrayTags[stringTag]=typedArrayTags[weakMapTag]=false;var objectProto=Object.prototype;var objToString=objectProto.toString;function isTypedArray(value){return isObjectLike(value)&&isLength(value.length)&&typedArrayTags[objToString.call(value)]||false}module.exports=isTypedArray},{"../internal/isLength":273,"../internal/isObjectLike":274}],297:[function(require,module,exports){var baseAssign=require("../internal/baseAssign"),createAssigner=require("../internal/createAssigner");var assign=createAssigner(baseAssign);module.exports=assign},{"../internal/baseAssign":218,"../internal/createAssigner":255}],298:[function(require,module,exports){var arrayCopy=require("../internal/arrayCopy"),assign=require("./assign"),assignDefaults=require("../internal/assignDefaults");function defaults(object){if(object==null){return object}var args=arrayCopy(arguments);args.push(assignDefaults);return assign.apply(undefined,args)}module.exports=defaults},{"../internal/arrayCopy":212,"../internal/assignDefaults":217,"./assign":297}],299:[function(require,module,exports){module.exports=require("./assign")},{"./assign":297}],300:[function(require,module,exports){var objectProto=Object.prototype;var hasOwnProperty=objectProto.hasOwnProperty;function has(object,key){return object?hasOwnProperty.call(object,key):false}module.exports=has},{}],301:[function(require,module,exports){var isLength=require("../internal/isLength"),isNative=require("../lang/isNative"),isObject=require("../lang/isObject"),shimKeys=require("../internal/shimKeys");var nativeKeys=isNative(nativeKeys=Object.keys)&&nativeKeys;var keys=!nativeKeys?shimKeys:function(object){if(object){var Ctor=object.constructor,length=object.length}if(typeof Ctor=="function"&&Ctor.prototype===object||typeof object!="function"&&(length&&isLength(length))){return shimKeys(object)}return isObject(object)?nativeKeys(object):[]};module.exports=keys},{"../internal/isLength":273,"../internal/shimKeys":281,"../lang/isNative":291,"../lang/isObject":293}],302:[function(require,module,exports){var isArguments=require("../lang/isArguments"),isArray=require("../lang/isArray"),isIndex=require("../internal/isIndex"),isLength=require("../internal/isLength"),isObject=require("../lang/isObject"),support=require("../support");var objectProto=Object.prototype;var hasOwnProperty=objectProto.hasOwnProperty;function keysIn(object){if(object==null){return[]}if(!isObject(object)){object=Object(object)}var length=object.length;length=length&&isLength(length)&&(isArray(object)||support.nonEnumArgs&&isArguments(object))&&length||0;var Ctor=object.constructor,index=-1,isProto=typeof Ctor=="function"&&Ctor.prototype===object,result=Array(length),skipIndexes=length>0;while(++index<length){result[index]=index+""}for(var key in object){if(!(skipIndexes&&isIndex(key,length))&&!(key=="constructor"&&(isProto||!hasOwnProperty.call(object,key)))){result.push(key)}}return result}module.exports=keysIn},{"../internal/isIndex":271,"../internal/isLength":273,"../lang/isArguments":286,"../lang/isArray":287,"../lang/isObject":293,"../support":305}],303:[function(require,module,exports){var baseValues=require("../internal/baseValues"),keys=require("./keys");function values(object){return baseValues(object,keys(object))}module.exports=values},{"../internal/baseValues":246,"./keys":301}],304:[function(require,module,exports){var baseToString=require("../internal/baseToString");var reRegExpChars=/[.*+?^${}()|[\]\/\\]/g,reHasRegExpChars=RegExp(reRegExpChars.source);function escapeRegExp(string){string=baseToString(string);return string&&reHasRegExpChars.test(string)?string.replace(reRegExpChars,"\\$&"):string}module.exports=escapeRegExp},{"../internal/baseToString":244}],305:[function(require,module,exports){(function(global){var isNative=require("./lang/isNative");var reThis=/\bthis\b/;var objectProto=Object.prototype;var document=(document=global.window)&&document.document;var propertyIsEnumerable=objectProto.propertyIsEnumerable;var support={};(function(x){support.funcDecomp=!isNative(global.WinRTError)&&reThis.test(function(){return this});support.funcNames=typeof Function.name=="string";try{support.dom=document.createDocumentFragment().nodeType===11}catch(e){support.dom=false}try{support.nonEnumArgs=!propertyIsEnumerable.call(arguments,1)}catch(e){support.nonEnumArgs=true}})(0,0);module.exports=support}).call(this,typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{}) },{"./lang/isNative":291}],306:[function(require,module,exports){function constant(value){return function(){return value}}module.exports=constant},{}],307:[function(require,module,exports){function identity(value){return value}module.exports=identity},{}],308:[function(require,module,exports){function noop(){}module.exports=noop},{}],309:[function(require,module,exports){"use strict";var originalObject=Object;var originalDefProp=Object.defineProperty;var originalCreate=Object.create;function defProp(obj,name,value){if(originalDefProp)try{originalDefProp.call(originalObject,obj,name,{value:value})}catch(definePropertyIsBrokenInIE8){obj[name]=value}else{obj[name]=value}}function makeSafeToCall(fun){if(fun){defProp(fun,"call",fun.call);defProp(fun,"apply",fun.apply)}return fun}makeSafeToCall(originalDefProp);makeSafeToCall(originalCreate);var hasOwn=makeSafeToCall(Object.prototype.hasOwnProperty);var numToStr=makeSafeToCall(Number.prototype.toString);var strSlice=makeSafeToCall(String.prototype.slice);var cloner=function(){};function create(prototype){if(originalCreate){return originalCreate.call(originalObject,prototype)}cloner.prototype=prototype||null;return new cloner}var rand=Math.random;var uniqueKeys=create(null);function makeUniqueKey(){do var uniqueKey=internString(strSlice.call(numToStr.call(rand(),36),2));while(hasOwn.call(uniqueKeys,uniqueKey));return uniqueKeys[uniqueKey]=uniqueKey}function internString(str){var obj={};obj[str]=true;return Object.keys(obj)[0]}defProp(exports,"makeUniqueKey",makeUniqueKey);var originalGetOPNs=Object.getOwnPropertyNames;Object.getOwnPropertyNames=function getOwnPropertyNames(object){for(var names=originalGetOPNs(object),src=0,dst=0,len=names.length;src<len;++src){if(!hasOwn.call(uniqueKeys,names[src])){if(src>dst){names[dst]=names[src]}++dst}}names.length=dst;return names};function defaultCreatorFn(object){return create(null)}function makeAccessor(secretCreatorFn){var brand=makeUniqueKey();var passkey=create(null);secretCreatorFn=secretCreatorFn||defaultCreatorFn;function register(object){var secret;function vault(key,forget){if(key===passkey){return forget?secret=null:secret||(secret=secretCreatorFn(object))}}defProp(object,brand,vault)}function accessor(object){if(!hasOwn.call(object,brand))register(object);return object[brand](passkey)}accessor.forget=function(object){if(hasOwn.call(object,brand))object[brand](passkey,true)};return accessor}defProp(exports,"makeAccessor",makeAccessor)},{}],310:[function(require,module,exports){var assert=require("assert");var types=require("ast-types");var isArray=types.builtInTypes.array;var b=types.builders;var n=types.namedTypes;var leap=require("./leap");var meta=require("./meta");var util=require("./util");var hasOwn=Object.prototype.hasOwnProperty;function Emitter(contextId){assert.ok(this instanceof Emitter);n.Identifier.assert(contextId);Object.defineProperties(this,{contextId:{value:contextId},listing:{value:[]},marked:{value:[true]},finalLoc:{value:loc()},tryEntries:{value:[]}});Object.defineProperties(this,{leapManager:{value:new leap.LeapManager(this)}})}var Ep=Emitter.prototype;exports.Emitter=Emitter;function loc(){return b.literal(-1)}Ep.mark=function(loc){n.Literal.assert(loc);var index=this.listing.length;if(loc.value===-1){loc.value=index}else{assert.strictEqual(loc.value,index)}this.marked[index]=true;return loc};Ep.emit=function(node){if(n.Expression.check(node))node=b.expressionStatement(node);n.Statement.assert(node);this.listing.push(node)};Ep.emitAssign=function(lhs,rhs){this.emit(this.assign(lhs,rhs));return lhs};Ep.assign=function(lhs,rhs){return b.expressionStatement(b.assignmentExpression("=",lhs,rhs))};Ep.contextProperty=function(name,computed){return b.memberExpression(this.contextId,computed?b.literal(name):b.identifier(name),!!computed)};var volatileContextPropertyNames={prev:true,next:true,sent:true,rval:true};Ep.isVolatileContextProperty=function(expr){if(n.MemberExpression.check(expr)){if(expr.computed){return true}if(n.Identifier.check(expr.object)&&n.Identifier.check(expr.property)&&expr.object.name===this.contextId.name&&hasOwn.call(volatileContextPropertyNames,expr.property.name)){return true}}return false};Ep.stop=function(rval){if(rval){this.setReturnValue(rval)}this.jump(this.finalLoc)};Ep.setReturnValue=function(valuePath){n.Expression.assert(valuePath.value);this.emitAssign(this.contextProperty("rval"),this.explodeExpression(valuePath))};Ep.clearPendingException=function(tryLoc,assignee){n.Literal.assert(tryLoc);var catchCall=b.callExpression(this.contextProperty("catch",true),[tryLoc]);if(assignee){this.emitAssign(assignee,catchCall)}else{this.emit(catchCall)}};Ep.jump=function(toLoc){this.emitAssign(this.contextProperty("next"),toLoc);this.emit(b.breakStatement())};Ep.jumpIf=function(test,toLoc){n.Expression.assert(test);n.Literal.assert(toLoc);this.emit(b.ifStatement(test,b.blockStatement([this.assign(this.contextProperty("next"),toLoc),b.breakStatement()])))};Ep.jumpIfNot=function(test,toLoc){n.Expression.assert(test);n.Literal.assert(toLoc);var negatedTest;if(n.UnaryExpression.check(test)&&test.operator==="!"){negatedTest=test.argument}else{negatedTest=b.unaryExpression("!",test)}this.emit(b.ifStatement(negatedTest,b.blockStatement([this.assign(this.contextProperty("next"),toLoc),b.breakStatement()])))};var nextTempId=0;Ep.makeTempVar=function(){return this.contextProperty("t"+nextTempId++)};Ep.getContextFunction=function(id){var func=b.functionExpression(id||null,[this.contextId],b.blockStatement([this.getDispatchLoop()]),false,false);func._aliasFunction=true;return func};Ep.getDispatchLoop=function(){var self=this;var cases=[];var current;var alreadyEnded=false;self.listing.forEach(function(stmt,i){if(self.marked.hasOwnProperty(i)){cases.push(b.switchCase(b.literal(i),current=[]));alreadyEnded=false}if(!alreadyEnded){current.push(stmt);if(isSwitchCaseEnder(stmt))alreadyEnded=true}});this.finalLoc.value=this.listing.length;cases.push(b.switchCase(this.finalLoc,[]),b.switchCase(b.literal("end"),[b.returnStatement(b.callExpression(this.contextProperty("stop"),[]))]));return b.whileStatement(b.literal(1),b.switchStatement(b.assignmentExpression("=",this.contextProperty("prev"),this.contextProperty("next")),cases))};function isSwitchCaseEnder(stmt){return n.BreakStatement.check(stmt)||n.ContinueStatement.check(stmt)||n.ReturnStatement.check(stmt)||n.ThrowStatement.check(stmt)}Ep.getTryLocsList=function(){if(this.tryEntries.length===0){return null}var lastLocValue=0;return b.arrayExpression(this.tryEntries.map(function(tryEntry){var thisLocValue=tryEntry.firstLoc.value;assert.ok(thisLocValue>=lastLocValue,"try entries out of order");lastLocValue=thisLocValue;var ce=tryEntry.catchEntry;var fe=tryEntry.finallyEntry;var locs=[tryEntry.firstLoc,ce?ce.firstLoc:null];if(fe){locs[2]=fe.firstLoc;locs[3]=fe.afterLoc}return b.arrayExpression(locs)}))};Ep.explode=function(path,ignoreResult){assert.ok(path instanceof types.NodePath);var node=path.value;var self=this;n.Node.assert(node);if(n.Statement.check(node))return self.explodeStatement(path);if(n.Expression.check(node))return self.explodeExpression(path,ignoreResult);if(n.Declaration.check(node))throw getDeclError(node);switch(node.type){case"Program":return path.get("body").map(self.explodeStatement,self);case"VariableDeclarator":throw getDeclError(node);case"Property":case"SwitchCase":case"CatchClause":throw new Error(node.type+" nodes should be handled by their parents");default:throw new Error("unknown Node of type "+JSON.stringify(node.type))}};function getDeclError(node){return new Error("all declarations should have been transformed into "+"assignments before the Exploder began its work: "+JSON.stringify(node))}Ep.explodeStatement=function(path,labelId){assert.ok(path instanceof types.NodePath);var stmt=path.value;var self=this;n.Statement.assert(stmt);if(labelId){n.Identifier.assert(labelId)}else{labelId=null}if(n.BlockStatement.check(stmt)){return path.get("body").each(self.explodeStatement,self)}if(!meta.containsLeap(stmt)){self.emit(stmt);return}switch(stmt.type){case"ExpressionStatement":self.explodeExpression(path.get("expression"),true);break;case"LabeledStatement":var after=loc();self.leapManager.withEntry(new leap.LabeledEntry(after,stmt.label),function(){self.explodeStatement(path.get("body"),stmt.label)});self.mark(after);break;case"WhileStatement":var before=loc();var after=loc();self.mark(before);self.jumpIfNot(self.explodeExpression(path.get("test")),after);self.leapManager.withEntry(new leap.LoopEntry(after,before,labelId),function(){self.explodeStatement(path.get("body"))});self.jump(before);self.mark(after);break;case"DoWhileStatement":var first=loc();var test=loc();var after=loc();self.mark(first);self.leapManager.withEntry(new leap.LoopEntry(after,test,labelId),function(){self.explode(path.get("body"))});self.mark(test);self.jumpIf(self.explodeExpression(path.get("test")),first);self.mark(after);break;case"ForStatement":var head=loc();var update=loc();var after=loc();if(stmt.init){self.explode(path.get("init"),true)}self.mark(head);if(stmt.test){self.jumpIfNot(self.explodeExpression(path.get("test")),after)}else{}self.leapManager.withEntry(new leap.LoopEntry(after,update,labelId),function(){self.explodeStatement(path.get("body"))});self.mark(update);if(stmt.update){self.explode(path.get("update"),true)}self.jump(head);self.mark(after);break;case"ForInStatement":n.Identifier.assert(stmt.left);var head=loc();var after=loc();var keyIterNextFn=self.makeTempVar();self.emitAssign(keyIterNextFn,b.callExpression(util.runtimeProperty("keys"),[self.explodeExpression(path.get("right"))]));self.mark(head);var keyInfoTmpVar=self.makeTempVar();self.jumpIf(b.memberExpression(b.assignmentExpression("=",keyInfoTmpVar,b.callExpression(keyIterNextFn,[])),b.identifier("done"),false),after);self.emitAssign(stmt.left,b.memberExpression(keyInfoTmpVar,b.identifier("value"),false));self.leapManager.withEntry(new leap.LoopEntry(after,head,labelId),function(){self.explodeStatement(path.get("body"))});self.jump(head);self.mark(after);break;case"BreakStatement":self.emitAbruptCompletion({type:"break",target:self.leapManager.getBreakLoc(stmt.label)});break;case"ContinueStatement":self.emitAbruptCompletion({type:"continue",target:self.leapManager.getContinueLoc(stmt.label)});break;case"SwitchStatement":var disc=self.emitAssign(self.makeTempVar(),self.explodeExpression(path.get("discriminant")));var after=loc();var defaultLoc=loc();var condition=defaultLoc;var caseLocs=[];var cases=stmt.cases||[];for(var i=cases.length-1;i>=0;--i){var c=cases[i];n.SwitchCase.assert(c);if(c.test){condition=b.conditionalExpression(b.binaryExpression("===",disc,c.test),caseLocs[i]=loc(),condition)}else{caseLocs[i]=defaultLoc}}self.jump(self.explodeExpression(new types.NodePath(condition,path,"discriminant")));self.leapManager.withEntry(new leap.SwitchEntry(after),function(){path.get("cases").each(function(casePath){var c=casePath.value;var i=casePath.name;self.mark(caseLocs[i]);casePath.get("consequent").each(self.explodeStatement,self)})});self.mark(after);if(defaultLoc.value===-1){self.mark(defaultLoc);assert.strictEqual(after.value,defaultLoc.value)}break;case"IfStatement":var elseLoc=stmt.alternate&&loc();var after=loc();self.jumpIfNot(self.explodeExpression(path.get("test")),elseLoc||after);self.explodeStatement(path.get("consequent"));if(elseLoc){self.jump(after);self.mark(elseLoc);self.explodeStatement(path.get("alternate"))}self.mark(after);break;case"ReturnStatement":self.emitAbruptCompletion({type:"return",value:self.explodeExpression(path.get("argument"))});break;case"WithStatement":throw new Error(node.type+" not supported in generator functions.");case"TryStatement":var after=loc();var handler=stmt.handler;if(!handler&&stmt.handlers){handler=stmt.handlers[0]||null}var catchLoc=handler&&loc();var catchEntry=catchLoc&&new leap.CatchEntry(catchLoc,handler.param);var finallyLoc=stmt.finalizer&&loc();var finallyEntry=finallyLoc&&new leap.FinallyEntry(finallyLoc,after);var tryEntry=new leap.TryEntry(self.getUnmarkedCurrentLoc(),catchEntry,finallyEntry);self.tryEntries.push(tryEntry);self.updateContextPrevLoc(tryEntry.firstLoc);self.leapManager.withEntry(tryEntry,function(){self.explodeStatement(path.get("block"));if(catchLoc){if(finallyLoc){self.jump(finallyLoc)}else{self.jump(after)}self.updateContextPrevLoc(self.mark(catchLoc));var bodyPath=path.get("handler","body");var safeParam=self.makeTempVar();self.clearPendingException(tryEntry.firstLoc,safeParam);var catchScope=bodyPath.scope;var catchParamName=handler.param.name;n.CatchClause.assert(catchScope.node);assert.strictEqual(catchScope.lookup(catchParamName),catchScope);types.visit(bodyPath,{visitIdentifier:function(path){if(util.isReference(path,catchParamName)&&path.scope.lookup(catchParamName)===catchScope){return safeParam}this.traverse(path)},visitFunction:function(path){if(path.scope.declares(catchParamName)){return false}this.traverse(path)}});self.leapManager.withEntry(catchEntry,function(){self.explodeStatement(bodyPath)})}if(finallyLoc){self.updateContextPrevLoc(self.mark(finallyLoc));self.leapManager.withEntry(finallyEntry,function(){self.explodeStatement(path.get("finalizer"))});self.emit(b.returnStatement(b.callExpression(self.contextProperty("finish"),[finallyEntry.firstLoc])))}});self.mark(after);break;case"ThrowStatement":self.emit(b.throwStatement(self.explodeExpression(path.get("argument"))));break;default:throw new Error("unknown Statement of type "+JSON.stringify(stmt.type))}};Ep.emitAbruptCompletion=function(record){if(!isValidCompletion(record)){assert.ok(false,"invalid completion record: "+JSON.stringify(record))}assert.notStrictEqual(record.type,"normal","normal completions are not abrupt");var abruptArgs=[b.literal(record.type)];if(record.type==="break"||record.type==="continue"){n.Literal.assert(record.target);abruptArgs[1]=record.target}else if(record.type==="return"||record.type==="throw"){if(record.value){n.Expression.assert(record.value);abruptArgs[1]=record.value}}this.emit(b.returnStatement(b.callExpression(this.contextProperty("abrupt"),abruptArgs)))};function isValidCompletion(record){var type=record.type;if(type==="normal"){return!hasOwn.call(record,"target")}if(type==="break"||type==="continue"){return!hasOwn.call(record,"value")&&n.Literal.check(record.target)}if(type==="return"||type==="throw"){return hasOwn.call(record,"value")&&!hasOwn.call(record,"target")}return false}Ep.getUnmarkedCurrentLoc=function(){return b.literal(this.listing.length)};Ep.updateContextPrevLoc=function(loc){if(loc){n.Literal.assert(loc);if(loc.value===-1){loc.value=this.listing.length}else{assert.strictEqual(loc.value,this.listing.length)}}else{loc=this.getUnmarkedCurrentLoc()}this.emitAssign(this.contextProperty("prev"),loc)};Ep.explodeExpression=function(path,ignoreResult){assert.ok(path instanceof types.NodePath);var expr=path.value;if(expr){n.Expression.assert(expr)}else{return expr}var self=this;var result;function finish(expr){n.Expression.assert(expr);if(ignoreResult){self.emit(expr)}else{return expr}}if(!meta.containsLeap(expr)){return finish(expr)}var hasLeapingChildren=meta.containsLeap.onlyChildren(expr);function explodeViaTempVar(tempVar,childPath,ignoreChildResult){assert.ok(childPath instanceof types.NodePath);assert.ok(!ignoreChildResult||!tempVar,"Ignoring the result of a child expression but forcing it to "+"be assigned to a temporary variable?");var result=self.explodeExpression(childPath,ignoreChildResult);if(ignoreChildResult){}else if(tempVar||hasLeapingChildren&&(self.isVolatileContextProperty(result)||meta.hasSideEffects(result))){result=self.emitAssign(tempVar||self.makeTempVar(),result)}return result}switch(expr.type){case"MemberExpression":return finish(b.memberExpression(self.explodeExpression(path.get("object")),expr.computed?explodeViaTempVar(null,path.get("property")):expr.property,expr.computed));case"CallExpression":var oldCalleePath=path.get("callee");var newCallee=self.explodeExpression(oldCalleePath);if(!n.MemberExpression.check(oldCalleePath.node)&&n.MemberExpression.check(newCallee)){newCallee=b.sequenceExpression([b.literal(0),newCallee])}return finish(b.callExpression(newCallee,path.get("arguments").map(function(argPath){return explodeViaTempVar(null,argPath)})));case"NewExpression":return finish(b.newExpression(explodeViaTempVar(null,path.get("callee")),path.get("arguments").map(function(argPath){return explodeViaTempVar(null,argPath)})));case"ObjectExpression":return finish(b.objectExpression(path.get("properties").map(function(propPath){return b.property(propPath.value.kind,propPath.value.key,explodeViaTempVar(null,propPath.get("value")))})));case"ArrayExpression":return finish(b.arrayExpression(path.get("elements").map(function(elemPath){return explodeViaTempVar(null,elemPath)})));case"SequenceExpression":var lastIndex=expr.expressions.length-1;path.get("expressions").each(function(exprPath){if(exprPath.name===lastIndex){result=self.explodeExpression(exprPath,ignoreResult)}else{self.explodeExpression(exprPath,true)}});return result;case"LogicalExpression":var after=loc();if(!ignoreResult){result=self.makeTempVar()}var left=explodeViaTempVar(result,path.get("left"));if(expr.operator==="&&"){self.jumpIfNot(left,after)}else{assert.strictEqual(expr.operator,"||");self.jumpIf(left,after)}explodeViaTempVar(result,path.get("right"),ignoreResult);self.mark(after);return result;case"ConditionalExpression":var elseLoc=loc();var after=loc();var test=self.explodeExpression(path.get("test"));self.jumpIfNot(test,elseLoc);if(!ignoreResult){result=self.makeTempVar()}explodeViaTempVar(result,path.get("consequent"),ignoreResult);self.jump(after);self.mark(elseLoc);explodeViaTempVar(result,path.get("alternate"),ignoreResult);self.mark(after);return result;case"UnaryExpression":return finish(b.unaryExpression(expr.operator,self.explodeExpression(path.get("argument")),!!expr.prefix));case"BinaryExpression":return finish(b.binaryExpression(expr.operator,explodeViaTempVar(null,path.get("left")),explodeViaTempVar(null,path.get("right"))));case"AssignmentExpression":return finish(b.assignmentExpression(expr.operator,self.explodeExpression(path.get("left")),self.explodeExpression(path.get("right"))));case"UpdateExpression":return finish(b.updateExpression(expr.operator,self.explodeExpression(path.get("argument")),expr.prefix));case"YieldExpression":var after=loc();var arg=expr.argument&&self.explodeExpression(path.get("argument"));if(arg&&expr.delegate){var result=self.makeTempVar();self.emit(b.returnStatement(b.callExpression(self.contextProperty("delegateYield"),[arg,b.literal(result.property.name),after])));self.mark(after);return result}self.emitAssign(self.contextProperty("next"),after);self.emit(b.returnStatement(arg||null));self.mark(after);return self.contextProperty("sent");default:throw new Error("unknown Expression of type "+JSON.stringify(expr.type))}}},{"./leap":312,"./meta":313,"./util":314,assert:141,"ast-types":139}],311:[function(require,module,exports){var assert=require("assert");var types=require("ast-types");var n=types.namedTypes;var b=types.builders;var hasOwn=Object.prototype.hasOwnProperty;exports.hoist=function(funPath){assert.ok(funPath instanceof types.NodePath);n.Function.assert(funPath.value);var vars={};function varDeclToExpr(vdec,includeIdentifiers){n.VariableDeclaration.assert(vdec);var exprs=[];vdec.declarations.forEach(function(dec){vars[dec.id.name]=dec.id;if(dec.init){exprs.push(b.assignmentExpression("=",dec.id,dec.init))}else if(includeIdentifiers){exprs.push(dec.id)}});if(exprs.length===0)return null;if(exprs.length===1)return exprs[0];return b.sequenceExpression(exprs)}types.visit(funPath.get("body"),{visitVariableDeclaration:function(path){var expr=varDeclToExpr(path.value,false);if(expr===null){path.replace()}else{return b.expressionStatement(expr)}return false},visitForStatement:function(path){var init=path.value.init;if(n.VariableDeclaration.check(init)){path.get("init").replace(varDeclToExpr(init,false))}this.traverse(path)},visitForInStatement:function(path){var left=path.value.left;if(n.VariableDeclaration.check(left)){path.get("left").replace(varDeclToExpr(left,true))}this.traverse(path)},visitFunctionDeclaration:function(path){var node=path.value;vars[node.id.name]=node.id;var parentNode=path.parent.node;var assignment=b.expressionStatement(b.assignmentExpression("=",node.id,b.functionExpression(node.id,node.params,node.body,node.generator,node.expression)));if(n.BlockStatement.check(path.parent.node)){path.parent.get("body").unshift(assignment);path.replace()}else{path.replace(assignment)}return false},visitFunctionExpression:function(path){return false}});var paramNames={};funPath.get("params").each(function(paramPath){var param=paramPath.value;if(n.Identifier.check(param)){paramNames[param.name]=param}else{}});var declarations=[];Object.keys(vars).forEach(function(name){if(!hasOwn.call(paramNames,name)){declarations.push(b.variableDeclarator(vars[name],null))}});if(declarations.length===0){return null}return b.variableDeclaration("var",declarations)}},{assert:141,"ast-types":139}],312:[function(require,module,exports){var assert=require("assert");var types=require("ast-types");var n=types.namedTypes;var b=types.builders;var inherits=require("util").inherits;var hasOwn=Object.prototype.hasOwnProperty;function Entry(){assert.ok(this instanceof Entry)}function FunctionEntry(returnLoc){Entry.call(this);n.Literal.assert(returnLoc);this.returnLoc=returnLoc}inherits(FunctionEntry,Entry);exports.FunctionEntry=FunctionEntry;function LoopEntry(breakLoc,continueLoc,label){Entry.call(this);n.Literal.assert(breakLoc);n.Literal.assert(continueLoc);if(label){n.Identifier.assert(label)}else{label=null}this.breakLoc=breakLoc;this.continueLoc=continueLoc;this.label=label}inherits(LoopEntry,Entry);exports.LoopEntry=LoopEntry;function SwitchEntry(breakLoc){Entry.call(this);n.Literal.assert(breakLoc);this.breakLoc=breakLoc}inherits(SwitchEntry,Entry);exports.SwitchEntry=SwitchEntry;function TryEntry(firstLoc,catchEntry,finallyEntry){Entry.call(this);n.Literal.assert(firstLoc);if(catchEntry){assert.ok(catchEntry instanceof CatchEntry)}else{catchEntry=null}if(finallyEntry){assert.ok(finallyEntry instanceof FinallyEntry)}else{finallyEntry=null}assert.ok(catchEntry||finallyEntry);this.firstLoc=firstLoc;this.catchEntry=catchEntry;this.finallyEntry=finallyEntry}inherits(TryEntry,Entry);exports.TryEntry=TryEntry;function CatchEntry(firstLoc,paramId){Entry.call(this);n.Literal.assert(firstLoc);n.Identifier.assert(paramId);this.firstLoc=firstLoc;this.paramId=paramId}inherits(CatchEntry,Entry);exports.CatchEntry=CatchEntry;function FinallyEntry(firstLoc,afterLoc){Entry.call(this);n.Literal.assert(firstLoc);n.Literal.assert(afterLoc);this.firstLoc=firstLoc;this.afterLoc=afterLoc}inherits(FinallyEntry,Entry);exports.FinallyEntry=FinallyEntry;function LabeledEntry(breakLoc,label){Entry.call(this);n.Literal.assert(breakLoc);n.Identifier.assert(label);this.breakLoc=breakLoc;this.label=label}inherits(LabeledEntry,Entry);exports.LabeledEntry=LabeledEntry;function LeapManager(emitter){assert.ok(this instanceof LeapManager);var Emitter=require("./emit").Emitter;assert.ok(emitter instanceof Emitter);this.emitter=emitter;this.entryStack=[new FunctionEntry(emitter.finalLoc)]}var LMp=LeapManager.prototype;exports.LeapManager=LeapManager;LMp.withEntry=function(entry,callback){assert.ok(entry instanceof Entry);this.entryStack.push(entry);try{callback.call(this.emitter)}finally{var popped=this.entryStack.pop();assert.strictEqual(popped,entry)}};LMp._findLeapLocation=function(property,label){for(var i=this.entryStack.length-1;i>=0;--i){var entry=this.entryStack[i];var loc=entry[property];if(loc){if(label){if(entry.label&&entry.label.name===label.name){return loc}}else if(entry instanceof LabeledEntry){}else{return loc}}}return null};LMp.getBreakLoc=function(label){return this._findLeapLocation("breakLoc",label)};LMp.getContinueLoc=function(label){return this._findLeapLocation("continueLoc",label)}},{"./emit":310,assert:141,"ast-types":139,util:167}],313:[function(require,module,exports){var assert=require("assert");var m=require("private").makeAccessor();var types=require("ast-types");var isArray=types.builtInTypes.array;var n=types.namedTypes;var hasOwn=Object.prototype.hasOwnProperty;function makePredicate(propertyName,knownTypes){function onlyChildren(node){n.Node.assert(node);var result=false;function check(child){if(result){}else if(isArray.check(child)){child.some(check)}else if(n.Node.check(child)){assert.strictEqual(result,false);result=predicate(child)}return result}types.eachField(node,function(name,child){check(child)});return result}function predicate(node){n.Node.assert(node);var meta=m(node);if(hasOwn.call(meta,propertyName))return meta[propertyName];if(hasOwn.call(opaqueTypes,node.type))return meta[propertyName]=false;if(hasOwn.call(knownTypes,node.type))return meta[propertyName]=true;return meta[propertyName]=onlyChildren(node)}predicate.onlyChildren=onlyChildren;return predicate}var opaqueTypes={FunctionExpression:true};var sideEffectTypes={CallExpression:true,ForInStatement:true,UnaryExpression:true,BinaryExpression:true,AssignmentExpression:true,UpdateExpression:true,NewExpression:true};var leapTypes={YieldExpression:true,BreakStatement:true,ContinueStatement:true,ReturnStatement:true,ThrowStatement:true};for(var type in leapTypes){if(hasOwn.call(leapTypes,type)){sideEffectTypes[type]=leapTypes[type]}}exports.hasSideEffects=makePredicate("hasSideEffects",sideEffectTypes);exports.containsLeap=makePredicate("containsLeap",leapTypes)},{assert:141,"ast-types":139,"private":309}],314:[function(require,module,exports){var assert=require("assert");var types=require("ast-types");var n=types.namedTypes;var b=types.builders;var hasOwn=Object.prototype.hasOwnProperty;exports.defaults=function(obj){var len=arguments.length;var extension;for(var i=1;i<len;++i){if(extension=arguments[i]){for(var key in extension){if(hasOwn.call(extension,key)&&!hasOwn.call(obj,key)){obj[key]=extension[key]}}}}return obj};exports.runtimeProperty=function(name){return b.memberExpression(b.identifier("regeneratorRuntime"),b.identifier(name),false)};exports.isReference=function(path,name){var node=path.value;if(!n.Identifier.check(node)){return false}if(name&&node.name!==name){return false}var parent=path.parent.value;switch(parent.type){case"VariableDeclarator":return path.name==="init";case"MemberExpression":return path.name==="object"||parent.computed&&path.name==="property";case"FunctionExpression":case"FunctionDeclaration":case"ArrowFunctionExpression":if(path.name==="id"){return false}if(parent.params===path.parentPath&&parent.params[path.name]===node){return false}return true;case"ClassDeclaration":case"ClassExpression":return path.name!=="id";case"CatchClause":return path.name!=="param";case"Property":case"MethodDefinition":return path.name!=="key";case"ImportSpecifier":case"ImportDefaultSpecifier":case"ImportNamespaceSpecifier":case"LabeledStatement":return false;default:return true}}},{assert:141,"ast-types":139}],315:[function(require,module,exports){var assert=require("assert");var fs=require("fs");var types=require("ast-types");var n=types.namedTypes;var b=types.builders;var isArray=types.builtInTypes.array;var isObject=types.builtInTypes.object;var NodePath=types.NodePath;var hoist=require("./hoist").hoist;var Emitter=require("./emit").Emitter;var runtimeProperty=require("./util").runtimeProperty;exports.transform=function transform(node,options){options=options||{};var path=node instanceof NodePath?node:new NodePath(node);visitor.visit(path,options);node=path.value;options.madeChanges=visitor.wasChangeReported();return node};var visitor=types.PathVisitor.fromMethodsObject({reset:function(node,options){this.options=options},visitFunction:function(path){this.traverse(path);var node=path.value;var shouldTransformAsync=node.async&&!this.options.disableAsync;if(!node.generator&&!shouldTransformAsync){return}this.reportChanged();node.generator=false;if(node.expression){node.expression=false;node.body=b.blockStatement([b.returnStatement(node.body)])}if(shouldTransformAsync){awaitVisitor.visit(path.get("body"))}var outerFnId=node.id||(node.id=path.scope.parent.declareTemporary("callee$"));var outerBody=[];var bodyBlock=path.value.body;bodyBlock.body=bodyBlock.body.filter(function(node){if(node&&node._blockHoist!=null){outerBody.push(node);return false}else{return true}});var innerFnId=b.identifier(node.id.name+"$");var contextId=path.scope.declareTemporary("context$");var vars=hoist(path);var emitter=new Emitter(contextId);emitter.explode(path.get("body"));if(vars&&vars.declarations.length>0){outerBody.push(vars)}var wrapArgs=[emitter.getContextFunction(innerFnId),shouldTransformAsync?b.literal(null):outerFnId,b.thisExpression()];var tryLocsList=emitter.getTryLocsList();if(tryLocsList){wrapArgs.push(tryLocsList)}var wrapCall=b.callExpression(shouldTransformAsync?runtimeProperty("async"):runtimeProperty("wrap"),wrapArgs);outerBody.push(b.returnStatement(wrapCall));node.body=b.blockStatement(outerBody);node.body._declarations=bodyBlock._declarations;if(shouldTransformAsync){node.async=false;return}if(n.FunctionDeclaration.check(node)){var pp=path.parent;while(pp&&!(n.BlockStatement.check(pp.value)||n.Program.check(pp.value))){pp=pp.parent}if(!pp){return}path.replace();node.type="FunctionExpression";var varDecl=b.variableDeclaration("var",[b.variableDeclarator(node.id,b.callExpression(runtimeProperty("mark"),[node]))]);if(node.comments){varDecl.leadingComments=node.leadingComments;varDecl.trailingComments=node.trailingComments;node.leadingComments=null;node.trailingComments=null}varDecl._blockHoist=3;var bodyPath=pp.get("body");var bodyLen=bodyPath.value.length;bodyPath.push(varDecl)}else{n.FunctionExpression.assert(node);return b.callExpression(runtimeProperty("mark"),[node])}}});function shouldNotHoistAbove(stmtPath){var value=stmtPath.value;n.Statement.assert(value);if(n.ExpressionStatement.check(value)&&n.Literal.check(value.expression)&&value.expression.value==="use strict"){return true}if(n.VariableDeclaration.check(value)){for(var i=0;i<value.declarations.length;++i){var decl=value.declarations[i];if(n.CallExpression.check(decl.init)&&types.astNodesAreEquivalent(decl.init.callee,runtimeProperty("mark"))){return true}}}return false}var awaitVisitor=types.PathVisitor.fromMethodsObject({visitFunction:function(path){return false},visitAwaitExpression:function(path){var argument=path.value.argument;if(path.value.all){argument=b.callExpression(b.memberExpression(b.identifier("Promise"),b.identifier("all"),false),[argument])}return b.yieldExpression(argument,false)}})},{"./emit":310,"./hoist":311,"./util":314,assert:141,"ast-types":139,fs:140}],316:[function(require,module,exports){(function(__dirname){var assert=require("assert");var path=require("path");var fs=require("fs");var through=require("through");var transform=require("./lib/visit").transform;var utils=require("./lib/util");var types=require("ast-types");var genOrAsyncFunExp=/\bfunction\s*\*|\basync\b/;var blockBindingExp=/\b(let|const)\s+/;function exports(file,options){var data=[];return through(write,end);function write(buf){data.push(buf)}function end(){this.queue(compile(data.join(""),options).code);this.queue(null)}}module.exports=exports;function runtime(){require("./runtime")}exports.runtime=runtime;runtime.path=path.join(__dirname,"runtime.js");exports.transform=transform}).call(this,"/node_modules/regenerator-babel")},{"./lib/util":314,"./lib/visit":315,"./runtime":318,assert:141,"ast-types":139,fs:140,path:150,through:317}],317:[function(require,module,exports){(function(process){var Stream=require("stream");exports=module.exports=through;through.through=through;function through(write,end,opts){write=write||function(data){this.queue(data)};end=end||function(){this.queue(null)};var ended=false,destroyed=false,buffer=[],_ended=false; var stream=new Stream;stream.readable=stream.writable=true;stream.paused=false;stream.autoDestroy=!(opts&&opts.autoDestroy===false);stream.write=function(data){write.call(this,data);return!stream.paused};function drain(){while(buffer.length&&!stream.paused){var data=buffer.shift();if(null===data)return stream.emit("end");else stream.emit("data",data)}}stream.queue=stream.push=function(data){if(_ended)return stream;if(data==null)_ended=true;buffer.push(data);drain();return stream};stream.on("end",function(){stream.readable=false;if(!stream.writable&&stream.autoDestroy)process.nextTick(function(){stream.destroy()})});function _end(){stream.writable=false;end.call(stream);if(!stream.readable&&stream.autoDestroy)stream.destroy()}stream.end=function(data){if(ended)return;ended=true;if(arguments.length)stream.write(data);_end();return stream};stream.destroy=function(){if(destroyed)return;destroyed=true;ended=true;buffer.length=0;stream.writable=stream.readable=false;stream.emit("close");return stream};stream.pause=function(){if(stream.paused)return;stream.paused=true;return stream};stream.resume=function(){if(stream.paused){stream.paused=false;stream.emit("resume")}drain();if(!stream.paused)stream.emit("drain");return stream};return stream}}).call(this,require("_process"))},{_process:151,stream:163}],318:[function(require,module,exports){(function(global){!function(global){"use strict";var hasOwn=Object.prototype.hasOwnProperty;var undefined;var iteratorSymbol=typeof Symbol==="function"&&Symbol.iterator||"@@iterator";var inModule=typeof module==="object";var runtime=global.regeneratorRuntime;if(runtime){if(inModule){module.exports=runtime}return}runtime=global.regeneratorRuntime=inModule?module.exports:{};function wrap(innerFn,outerFn,self,tryLocsList){return new Generator(innerFn,outerFn,self||null,tryLocsList||[])}runtime.wrap=wrap;function tryCatch(fn,obj,arg){try{return{type:"normal",arg:fn.call(obj,arg)}}catch(err){return{type:"throw",arg:err}}}var GenStateSuspendedStart="suspendedStart";var GenStateSuspendedYield="suspendedYield";var GenStateExecuting="executing";var GenStateCompleted="completed";var ContinueSentinel={};function GeneratorFunction(){}function GeneratorFunctionPrototype(){}var Gp=GeneratorFunctionPrototype.prototype=Generator.prototype;GeneratorFunction.prototype=Gp.constructor=GeneratorFunctionPrototype;GeneratorFunctionPrototype.constructor=GeneratorFunction;GeneratorFunction.displayName="GeneratorFunction";runtime.isGeneratorFunction=function(genFun){var ctor=typeof genFun==="function"&&genFun.constructor;return ctor?ctor===GeneratorFunction||(ctor.displayName||ctor.name)==="GeneratorFunction":false};runtime.mark=function(genFun){genFun.__proto__=GeneratorFunctionPrototype;genFun.prototype=Object.create(Gp);return genFun};runtime.async=function(innerFn,outerFn,self,tryLocsList){return new Promise(function(resolve,reject){var generator=wrap(innerFn,outerFn,self,tryLocsList);var callNext=step.bind(generator.next);var callThrow=step.bind(generator["throw"]);function step(arg){var record=tryCatch(this,null,arg);if(record.type==="throw"){reject(record.arg);return}var info=record.arg;if(info.done){resolve(info.value)}else{Promise.resolve(info.value).then(callNext,callThrow)}}callNext()})};function Generator(innerFn,outerFn,self,tryLocsList){var generator=outerFn?Object.create(outerFn.prototype):this;var context=new Context(tryLocsList);var state=GenStateSuspendedStart;function invoke(method,arg){if(state===GenStateExecuting){throw new Error("Generator is already running")}if(state===GenStateCompleted){return doneResult()}while(true){var delegate=context.delegate;if(delegate){var record=tryCatch(delegate.iterator[method],delegate.iterator,arg);if(record.type==="throw"){context.delegate=null;method="throw";arg=record.arg;continue}method="next";arg=undefined;var info=record.arg;if(info.done){context[delegate.resultName]=info.value;context.next=delegate.nextLoc}else{state=GenStateSuspendedYield;return info}context.delegate=null}if(method==="next"){if(state===GenStateSuspendedStart&&typeof arg!=="undefined"){throw new TypeError("attempt to send "+JSON.stringify(arg)+" to newborn generator")}if(state===GenStateSuspendedYield){context.sent=arg}else{delete context.sent}}else if(method==="throw"){if(state===GenStateSuspendedStart){state=GenStateCompleted;throw arg}if(context.dispatchException(arg)){method="next";arg=undefined}}else if(method==="return"){context.abrupt("return",arg)}state=GenStateExecuting;var record=tryCatch(innerFn,self,context);if(record.type==="normal"){state=context.done?GenStateCompleted:GenStateSuspendedYield;var info={value:record.arg,done:context.done};if(record.arg===ContinueSentinel){if(context.delegate&&method==="next"){arg=undefined}}else{return info}}else if(record.type==="throw"){state=GenStateCompleted;if(method==="next"){context.dispatchException(record.arg)}else{arg=record.arg}}}}generator.next=invoke.bind(generator,"next");generator["throw"]=invoke.bind(generator,"throw");generator["return"]=invoke.bind(generator,"return");return generator}Gp[iteratorSymbol]=function(){return this};Gp.toString=function(){return"[object Generator]"};function pushTryEntry(locs){var entry={tryLoc:locs[0]};if(1 in locs){entry.catchLoc=locs[1]}if(2 in locs){entry.finallyLoc=locs[2];entry.afterLoc=locs[3]}this.tryEntries.push(entry)}function resetTryEntry(entry){var record=entry.completion||{};record.type="normal";delete record.arg;entry.completion=record}function Context(tryLocsList){this.tryEntries=[{tryLoc:"root"}];tryLocsList.forEach(pushTryEntry,this);this.reset()}runtime.keys=function(object){var keys=[];for(var key in object){keys.push(key)}keys.reverse();return function next(){while(keys.length){var key=keys.pop();if(key in object){next.value=key;next.done=false;return next}}next.done=true;return next}};function values(iterable){if(iterable){var iteratorMethod=iterable[iteratorSymbol];if(iteratorMethod){return iteratorMethod.call(iterable)}if(typeof iterable.next==="function"){return iterable}if(!isNaN(iterable.length)){var i=-1,next=function next(){while(++i<iterable.length){if(hasOwn.call(iterable,i)){next.value=iterable[i];next.done=false;return next}}next.value=undefined;next.done=true;return next};return next.next=next}}return{next:doneResult}}runtime.values=values;function doneResult(){return{value:undefined,done:true}}Context.prototype={constructor:Context,reset:function(){this.prev=0;this.next=0;this.sent=undefined;this.done=false;this.delegate=null;this.tryEntries.forEach(resetTryEntry);for(var tempIndex=0,tempName;hasOwn.call(this,tempName="t"+tempIndex)||tempIndex<20;++tempIndex){this[tempName]=null}},stop:function(){this.done=true;var rootEntry=this.tryEntries[0];var rootRecord=rootEntry.completion;if(rootRecord.type==="throw"){throw rootRecord.arg}return this.rval},dispatchException:function(exception){if(this.done){throw exception}var context=this;function handle(loc,caught){record.type="throw";record.arg=exception;context.next=loc;return!!caught}for(var i=this.tryEntries.length-1;i>=0;--i){var entry=this.tryEntries[i];var record=entry.completion;if(entry.tryLoc==="root"){return handle("end")}if(entry.tryLoc<=this.prev){var hasCatch=hasOwn.call(entry,"catchLoc");var hasFinally=hasOwn.call(entry,"finallyLoc");if(hasCatch&&hasFinally){if(this.prev<entry.catchLoc){return handle(entry.catchLoc,true)}else if(this.prev<entry.finallyLoc){return handle(entry.finallyLoc)}}else if(hasCatch){if(this.prev<entry.catchLoc){return handle(entry.catchLoc,true)}}else if(hasFinally){if(this.prev<entry.finallyLoc){return handle(entry.finallyLoc)}}else{throw new Error("try statement without catch or finally")}}}},abrupt:function(type,arg){for(var i=this.tryEntries.length-1;i>=0;--i){var entry=this.tryEntries[i];if(entry.tryLoc<=this.prev&&hasOwn.call(entry,"finallyLoc")&&this.prev<entry.finallyLoc){var finallyEntry=entry;break}}if(finallyEntry&&(type==="break"||type==="continue")&&finallyEntry.tryLoc<=arg&&arg<finallyEntry.finallyLoc){finallyEntry=null}var record=finallyEntry?finallyEntry.completion:{};record.type=type;record.arg=arg;if(finallyEntry){this.next=finallyEntry.finallyLoc}else{this.complete(record)}return ContinueSentinel},complete:function(record,afterLoc){if(record.type==="throw"){throw record.arg}if(record.type==="break"||record.type==="continue"){this.next=record.arg}else if(record.type==="return"){this.rval=record.arg;this.next="end"}else if(record.type==="normal"&&afterLoc){this.next=afterLoc}return ContinueSentinel},finish:function(finallyLoc){for(var i=this.tryEntries.length-1;i>=0;--i){var entry=this.tryEntries[i];if(entry.finallyLoc===finallyLoc){return this.complete(entry.completion,entry.afterLoc)}}},"catch":function(tryLoc){for(var i=this.tryEntries.length-1;i>=0;--i){var entry=this.tryEntries[i];if(entry.tryLoc===tryLoc){var record=entry.completion;if(record.type==="throw"){var thrown=record.arg;resetTryEntry(entry)}return thrown}}throw new Error("illegal catch attempt")},delegateYield:function(iterable,resultName,nextLoc){this.delegate={iterator:values(iterable),resultName:resultName,nextLoc:nextLoc};return ContinueSentinel}}}(typeof global==="object"?global:typeof window==="object"?window:this)}).call(this,typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{})},{}],319:[function(require,module,exports){var regenerate=require("regenerate");exports.REGULAR={d:regenerate().addRange(48,57),D:regenerate().addRange(0,47).addRange(58,65535),s:regenerate(32,160,5760,6158,8239,8287,12288,65279).addRange(9,13).addRange(8192,8202).addRange(8232,8233),S:regenerate().addRange(0,8).addRange(14,31).addRange(33,159).addRange(161,5759).addRange(5761,6157).addRange(6159,8191).addRange(8203,8231).addRange(8234,8238).addRange(8240,8286).addRange(8288,12287).addRange(12289,65278).addRange(65280,65535),w:regenerate(95).addRange(48,57).addRange(65,90).addRange(97,122),W:regenerate(96).addRange(0,47).addRange(58,64).addRange(91,94).addRange(123,65535)};exports.UNICODE={d:regenerate().addRange(48,57),D:regenerate().addRange(0,47).addRange(58,1114111),s:regenerate(32,160,5760,6158,8239,8287,12288,65279).addRange(9,13).addRange(8192,8202).addRange(8232,8233),S:regenerate().addRange(0,8).addRange(14,31).addRange(33,159).addRange(161,5759).addRange(5761,6157).addRange(6159,8191).addRange(8203,8231).addRange(8234,8238).addRange(8240,8286).addRange(8288,12287).addRange(12289,65278).addRange(65280,1114111),w:regenerate(95).addRange(48,57).addRange(65,90).addRange(97,122),W:regenerate(96).addRange(0,47).addRange(58,64).addRange(91,94).addRange(123,1114111)};exports.UNICODE_IGNORE_CASE={d:regenerate().addRange(48,57),D:regenerate().addRange(0,47).addRange(58,1114111),s:regenerate(32,160,5760,6158,8239,8287,12288,65279).addRange(9,13).addRange(8192,8202).addRange(8232,8233),S:regenerate().addRange(0,8).addRange(14,31).addRange(33,159).addRange(161,5759).addRange(5761,6157).addRange(6159,8191).addRange(8203,8231).addRange(8234,8238).addRange(8240,8286).addRange(8288,12287).addRange(12289,65278).addRange(65280,1114111),w:regenerate(95,383,8490).addRange(48,57).addRange(65,90).addRange(97,122),W:regenerate(75,83,96).addRange(0,47).addRange(58,64).addRange(91,94).addRange(123,1114111)}},{regenerate:321}],320:[function(require,module,exports){module.exports={75:8490,83:383,107:8490,115:383,181:924,197:8491,383:83,452:453,453:452,455:456,456:455,458:459,459:458,497:498,498:497,837:8126,914:976,917:1013,920:1012,921:8126,922:1008,924:181,928:982,929:1009,931:962,934:981,937:8486,962:931,976:914,977:1012,981:934,982:928,1008:922,1009:929,1012:[920,977],1013:917,7776:7835,7835:7776,8126:[837,921],8486:937,8490:75,8491:197,66560:66600,66561:66601,66562:66602,66563:66603,66564:66604,66565:66605,66566:66606,66567:66607,66568:66608,66569:66609,66570:66610,66571:66611,66572:66612,66573:66613,66574:66614,66575:66615,66576:66616,66577:66617,66578:66618,66579:66619,66580:66620,66581:66621,66582:66622,66583:66623,66584:66624,66585:66625,66586:66626,66587:66627,66588:66628,66589:66629,66590:66630,66591:66631,66592:66632,66593:66633,66594:66634,66595:66635,66596:66636,66597:66637,66598:66638,66599:66639,66600:66560,66601:66561,66602:66562,66603:66563,66604:66564,66605:66565,66606:66566,66607:66567,66608:66568,66609:66569,66610:66570,66611:66571,66612:66572,66613:66573,66614:66574,66615:66575,66616:66576,66617:66577,66618:66578,66619:66579,66620:66580,66621:66581,66622:66582,66623:66583,66624:66584,66625:66585,66626:66586,66627:66587,66628:66588,66629:66589,66630:66590,66631:66591,66632:66592,66633:66593,66634:66594,66635:66595,66636:66596,66637:66597,66638:66598,66639:66599,71840:71872,71841:71873,71842:71874,71843:71875,71844:71876,71845:71877,71846:71878,71847:71879,71848:71880,71849:71881,71850:71882,71851:71883,71852:71884,71853:71885,71854:71886,71855:71887,71856:71888,71857:71889,71858:71890,71859:71891,71860:71892,71861:71893,71862:71894,71863:71895,71864:71896,71865:71897,71866:71898,71867:71899,71868:71900,71869:71901,71870:71902,71871:71903,71872:71840,71873:71841,71874:71842,71875:71843,71876:71844,71877:71845,71878:71846,71879:71847,71880:71848,71881:71849,71882:71850,71883:71851,71884:71852,71885:71853,71886:71854,71887:71855,71888:71856,71889:71857,71890:71858,71891:71859,71892:71860,71893:71861,71894:71862,71895:71863,71896:71864,71897:71865,71898:71866,71899:71867,71900:71868,71901:71869,71902:71870,71903:71871}},{}],321:[function(require,module,exports){(function(global){(function(root){var freeExports=typeof exports=="object"&&exports;var freeModule=typeof module=="object"&&module&&module.exports==freeExports&&module;var freeGlobal=typeof global=="object"&&global;if(freeGlobal.global===freeGlobal||freeGlobal.window===freeGlobal){root=freeGlobal}var ERRORS={rangeOrder:"A range’s `stop` value must be greater than or equal "+"to the `start` value.",codePointRange:"Invalid code point value. Code points range from "+"U+000000 to U+10FFFF."};var HIGH_SURROGATE_MIN=55296;var HIGH_SURROGATE_MAX=56319;var LOW_SURROGATE_MIN=56320;var LOW_SURROGATE_MAX=57343;var regexNull=/\\x00([^0123456789]|$)/g;var object={};var hasOwnProperty=object.hasOwnProperty;var extend=function(destination,source){var key;for(key in source){if(hasOwnProperty.call(source,key)){destination[key]=source[key]}}return destination};var forEach=function(array,callback){var index=-1;var length=array.length;while(++index<length){callback(array[index],index)}};var toString=object.toString;var isArray=function(value){return toString.call(value)=="[object Array]"};var isNumber=function(value){return typeof value=="number"||toString.call(value)=="[object Number]"};var zeroes="0000";var pad=function(number,totalCharacters){var string=String(number);return string.length<totalCharacters?(zeroes+string).slice(-totalCharacters):string};var hex=function(number){return Number(number).toString(16).toUpperCase()};var slice=[].slice;var dataFromCodePoints=function(codePoints){var index=-1;var length=codePoints.length;var max=length-1;var result=[];var isStart=true;var tmp;var previous=0;while(++index<length){tmp=codePoints[index];if(isStart){result.push(tmp);previous=tmp;isStart=false}else{if(tmp==previous+1){if(index!=max){previous=tmp;continue}else{isStart=true;result.push(tmp+1)}}else{result.push(previous+1,tmp);previous=tmp}}}if(!isStart){result.push(tmp+1)}return result};var dataRemove=function(data,codePoint){var index=0;var start;var end;var length=data.length;while(index<length){start=data[index];end=data[index+1];if(codePoint>=start&&codePoint<end){if(codePoint==start){if(end==start+1){data.splice(index,2);return data}else{data[index]=codePoint+1;return data}}else if(codePoint==end-1){data[index+1]=codePoint;return data}else{data.splice(index,2,start,codePoint,codePoint+1,end);return data}}index+=2}return data};var dataRemoveRange=function(data,rangeStart,rangeEnd){if(rangeEnd<rangeStart){throw Error(ERRORS.rangeOrder)}var index=0;var start;var end;while(index<data.length){start=data[index];end=data[index+1]-1;if(start>rangeEnd){return data}if(rangeStart<=start&&rangeEnd>=end){data.splice(index,2);continue}if(rangeStart>=start&&rangeEnd<end){if(rangeStart==start){data[index]=rangeEnd+1;data[index+1]=end+1;return data}data.splice(index,2,start,rangeStart,rangeEnd+1,end+1);return data}if(rangeStart>=start&&rangeStart<=end){data[index+1]=rangeStart}else if(rangeEnd>=start&&rangeEnd<=end){data[index]=rangeEnd+1;return data}index+=2}return data};var dataAdd=function(data,codePoint){var index=0;var start;var end;var lastIndex=null;var length=data.length;if(codePoint<0||codePoint>1114111){throw RangeError(ERRORS.codePointRange)}while(index<length){start=data[index];end=data[index+1];if(codePoint>=start&&codePoint<end){return data}if(codePoint==start-1){data[index]=codePoint;return data}if(start>codePoint){data.splice(lastIndex!=null?lastIndex+2:0,0,codePoint,codePoint+1);return data}if(codePoint==end){if(codePoint+1==data[index+2]){data.splice(index,4,start,data[index+3]);return data}data[index+1]=codePoint+1;return data}lastIndex=index;index+=2}data.push(codePoint,codePoint+1);return data};var dataAddData=function(dataA,dataB){var index=0;var start;var end;var data=dataA.slice();var length=dataB.length;while(index<length){start=dataB[index];end=dataB[index+1]-1;if(start==end){data=dataAdd(data,start)}else{data=dataAddRange(data,start,end)}index+=2}return data};var dataRemoveData=function(dataA,dataB){var index=0;var start;var end;var data=dataA.slice();var length=dataB.length;while(index<length){start=dataB[index];end=dataB[index+1]-1;if(start==end){data=dataRemove(data,start)}else{data=dataRemoveRange(data,start,end)}index+=2}return data};var dataAddRange=function(data,rangeStart,rangeEnd){if(rangeEnd<rangeStart){throw Error(ERRORS.rangeOrder)}if(rangeStart<0||rangeStart>1114111||rangeEnd<0||rangeEnd>1114111){throw RangeError(ERRORS.codePointRange)}var index=0;var start;var end;var added=false;var length=data.length;while(index<length){start=data[index];end=data[index+1];if(added){if(start==rangeEnd+1){data.splice(index-1,2);return data}if(start>rangeEnd){return data}if(start>=rangeStart&&start<=rangeEnd){if(end>rangeStart&&end-1<=rangeEnd){data.splice(index,2);index-=2}else{data.splice(index-1,2);index-=2}}}else if(start==rangeEnd+1){data[index]=rangeStart;return data}else if(start>rangeEnd){data.splice(index,0,rangeStart,rangeEnd+1);return data}else if(rangeStart>=start&&rangeStart<end&&rangeEnd+1<=end){return data}else if(rangeStart>=start&&rangeStart<end||end==rangeStart){data[index+1]=rangeEnd+1;added=true}else if(rangeStart<=start&&rangeEnd+1>=end){data[index]=rangeStart;data[index+1]=rangeEnd+1;added=true}index+=2}if(!added){data.push(rangeStart,rangeEnd+1)}return data};var dataContains=function(data,codePoint){var index=0;var length=data.length;var start=data[index];var end=data[length-1];if(length>=2){if(codePoint<start||codePoint>end){return false}}while(index<length){start=data[index];end=data[index+1];if(codePoint>=start&&codePoint<end){return true}index+=2}return false};var dataIntersection=function(data,codePoints){var index=0;var length=codePoints.length;var codePoint;var result=[];while(index<length){codePoint=codePoints[index];if(dataContains(data,codePoint)){result.push(codePoint)}++index}return dataFromCodePoints(result)};var dataIsEmpty=function(data){return!data.length};var dataIsSingleton=function(data){return data.length==2&&data[0]+1==data[1]};var dataToArray=function(data){var index=0;var start;var end;var result=[];var length=data.length;while(index<length){start=data[index];end=data[index+1];while(start<end){result.push(start);++start}index+=2}return result};var floor=Math.floor;var highSurrogate=function(codePoint){return parseInt(floor((codePoint-65536)/1024)+HIGH_SURROGATE_MIN,10)};var lowSurrogate=function(codePoint){return parseInt((codePoint-65536)%1024+LOW_SURROGATE_MIN,10)};var stringFromCharCode=String.fromCharCode;var codePointToString=function(codePoint){var string;if(codePoint==9){string="\\t"}else if(codePoint==10){string="\\n"}else if(codePoint==12){string="\\f"}else if(codePoint==13){string="\\r"}else if(codePoint==92){string="\\\\"}else if(codePoint==36||codePoint>=40&&codePoint<=43||codePoint==45||codePoint==46||codePoint==63||codePoint>=91&&codePoint<=94||codePoint>=123&&codePoint<=125){string="\\"+stringFromCharCode(codePoint)}else if(codePoint>=32&&codePoint<=126){string=stringFromCharCode(codePoint)}else if(codePoint<=255){string="\\x"+pad(hex(codePoint),2)}else{string="\\u"+pad(hex(codePoint),4)}return string};var symbolToCodePoint=function(symbol){var length=symbol.length;var first=symbol.charCodeAt(0);var second;if(first>=HIGH_SURROGATE_MIN&&first<=HIGH_SURROGATE_MAX&&length>1){second=symbol.charCodeAt(1);return(first-HIGH_SURROGATE_MIN)*1024+second-LOW_SURROGATE_MIN+65536}return first};var createBMPCharacterClasses=function(data){var result="";var index=0;var start;var end;var length=data.length;if(dataIsSingleton(data)){return codePointToString(data[0])}while(index<length){start=data[index];end=data[index+1]-1;if(start==end){result+=codePointToString(start)}else if(start+1==end){result+=codePointToString(start)+codePointToString(end)}else{result+=codePointToString(start)+"-"+codePointToString(end)}index+=2}return"["+result+"]"};var splitAtBMP=function(data){var loneHighSurrogates=[];var loneLowSurrogates=[];var bmp=[];var astral=[];var index=0;var start;var end;var length=data.length;while(index<length){start=data[index];end=data[index+1]-1;if(start<HIGH_SURROGATE_MIN){if(end<HIGH_SURROGATE_MIN){bmp.push(start,end+1)}if(end>=HIGH_SURROGATE_MIN&&end<=HIGH_SURROGATE_MAX){bmp.push(start,HIGH_SURROGATE_MIN);loneHighSurrogates.push(HIGH_SURROGATE_MIN,end+1)}if(end>=LOW_SURROGATE_MIN&&end<=LOW_SURROGATE_MAX){bmp.push(start,HIGH_SURROGATE_MIN);loneHighSurrogates.push(HIGH_SURROGATE_MIN,HIGH_SURROGATE_MAX+1);loneLowSurrogates.push(LOW_SURROGATE_MIN,end+1)}if(end>LOW_SURROGATE_MAX){bmp.push(start,HIGH_SURROGATE_MIN);loneHighSurrogates.push(HIGH_SURROGATE_MIN,HIGH_SURROGATE_MAX+1);loneLowSurrogates.push(LOW_SURROGATE_MIN,LOW_SURROGATE_MAX+1);if(end<=65535){bmp.push(LOW_SURROGATE_MAX+1,end+1)}else{bmp.push(LOW_SURROGATE_MAX+1,65535+1);astral.push(65535+1,end+1)}}}else if(start>=HIGH_SURROGATE_MIN&&start<=HIGH_SURROGATE_MAX){if(end>=HIGH_SURROGATE_MIN&&end<=HIGH_SURROGATE_MAX){loneHighSurrogates.push(start,end+1)}if(end>=LOW_SURROGATE_MIN&&end<=LOW_SURROGATE_MAX){loneHighSurrogates.push(start,HIGH_SURROGATE_MAX+1);loneLowSurrogates.push(LOW_SURROGATE_MIN,end+1)}if(end>LOW_SURROGATE_MAX){loneHighSurrogates.push(start,HIGH_SURROGATE_MAX+1);loneLowSurrogates.push(LOW_SURROGATE_MIN,LOW_SURROGATE_MAX+1);if(end<=65535){bmp.push(LOW_SURROGATE_MAX+1,end+1)}else{bmp.push(LOW_SURROGATE_MAX+1,65535+1);astral.push(65535+1,end+1)}}}else if(start>=LOW_SURROGATE_MIN&&start<=LOW_SURROGATE_MAX){if(end>=LOW_SURROGATE_MIN&&end<=LOW_SURROGATE_MAX){loneLowSurrogates.push(start,end+1)}if(end>LOW_SURROGATE_MAX){loneLowSurrogates.push(start,LOW_SURROGATE_MAX+1);if(end<=65535){bmp.push(LOW_SURROGATE_MAX+1,end+1)}else{bmp.push(LOW_SURROGATE_MAX+1,65535+1);astral.push(65535+1,end+1)}}}else if(start>LOW_SURROGATE_MAX&&start<=65535){if(end<=65535){bmp.push(start,end+1)}else{bmp.push(start,65535+1);astral.push(65535+1,end+1)}}else{astral.push(start,end+1)}index+=2}return{loneHighSurrogates:loneHighSurrogates,loneLowSurrogates:loneLowSurrogates,bmp:bmp,astral:astral}};var optimizeSurrogateMappings=function(surrogateMappings){var result=[];var tmpLow=[];var addLow=false;var mapping;var nextMapping;var highSurrogates;var lowSurrogates;var nextHighSurrogates;var nextLowSurrogates;var index=-1;var length=surrogateMappings.length;while(++index<length){mapping=surrogateMappings[index];nextMapping=surrogateMappings[index+1];if(!nextMapping){result.push(mapping);continue}highSurrogates=mapping[0];lowSurrogates=mapping[1];nextHighSurrogates=nextMapping[0];nextLowSurrogates=nextMapping[1];tmpLow=lowSurrogates;while(nextHighSurrogates&&highSurrogates[0]==nextHighSurrogates[0]&&highSurrogates[1]==nextHighSurrogates[1]){if(dataIsSingleton(nextLowSurrogates)){tmpLow=dataAdd(tmpLow,nextLowSurrogates[0])}else{tmpLow=dataAddRange(tmpLow,nextLowSurrogates[0],nextLowSurrogates[1]-1)}++index;mapping=surrogateMappings[index];highSurrogates=mapping[0];lowSurrogates=mapping[1];nextMapping=surrogateMappings[index+1];nextHighSurrogates=nextMapping&&nextMapping[0];nextLowSurrogates=nextMapping&&nextMapping[1];addLow=true}result.push([highSurrogates,addLow?tmpLow:lowSurrogates]);addLow=false}return optimizeByLowSurrogates(result)};var optimizeByLowSurrogates=function(surrogateMappings){if(surrogateMappings.length==1){return surrogateMappings}var index=-1;var innerIndex=-1;while(++index<surrogateMappings.length){var mapping=surrogateMappings[index];var lowSurrogates=mapping[1];var lowSurrogateStart=lowSurrogates[0];var lowSurrogateEnd=lowSurrogates[1];innerIndex=index;while(++innerIndex<surrogateMappings.length){var otherMapping=surrogateMappings[innerIndex];var otherLowSurrogates=otherMapping[1];var otherLowSurrogateStart=otherLowSurrogates[0];var otherLowSurrogateEnd=otherLowSurrogates[1];if(lowSurrogateStart==otherLowSurrogateStart&&lowSurrogateEnd==otherLowSurrogateEnd){if(dataIsSingleton(otherMapping[0])){mapping[0]=dataAdd(mapping[0],otherMapping[0][0])}else{mapping[0]=dataAddRange(mapping[0],otherMapping[0][0],otherMapping[0][1]-1)}surrogateMappings.splice(innerIndex,1);--innerIndex}}}return surrogateMappings};var surrogateSet=function(data){if(!data.length){return[]}var index=0;var start;var end;var startHigh;var startLow;var prevStartHigh=0;var prevEndHigh=0;var tmpLow=[];var endHigh;var endLow;var surrogateMappings=[];var length=data.length;var dataHigh=[];while(index<length){start=data[index];end=data[index+1]-1;startHigh=highSurrogate(start);startLow=lowSurrogate(start);endHigh=highSurrogate(end);endLow=lowSurrogate(end);var startsWithLowestLowSurrogate=startLow==LOW_SURROGATE_MIN;var endsWithHighestLowSurrogate=endLow==LOW_SURROGATE_MAX;var complete=false;if(startHigh==endHigh||startsWithLowestLowSurrogate&&endsWithHighestLowSurrogate){surrogateMappings.push([[startHigh,endHigh+1],[startLow,endLow+1]]);complete=true}else{surrogateMappings.push([[startHigh,startHigh+1],[startLow,LOW_SURROGATE_MAX+1]])}if(!complete&&startHigh+1<endHigh){if(endsWithHighestLowSurrogate){surrogateMappings.push([[startHigh+1,endHigh+1],[LOW_SURROGATE_MIN,endLow+1]]);complete=true}else{surrogateMappings.push([[startHigh+1,endHigh],[LOW_SURROGATE_MIN,LOW_SURROGATE_MAX+1]])}}if(!complete){surrogateMappings.push([[endHigh,endHigh+1],[LOW_SURROGATE_MIN,endLow+1]])}prevStartHigh=startHigh;prevEndHigh=endHigh;index+=2}return optimizeSurrogateMappings(surrogateMappings)};var createSurrogateCharacterClasses=function(surrogateMappings){var result=[];forEach(surrogateMappings,function(surrogateMapping){var highSurrogates=surrogateMapping[0];var lowSurrogates=surrogateMapping[1];result.push(createBMPCharacterClasses(highSurrogates)+createBMPCharacterClasses(lowSurrogates))});return result.join("|")};var createCharacterClassesFromData=function(data,bmpOnly){var result=[];var parts=splitAtBMP(data);var loneHighSurrogates=parts.loneHighSurrogates;var loneLowSurrogates=parts.loneLowSurrogates;var bmp=parts.bmp;var astral=parts.astral;var hasAstral=!dataIsEmpty(parts.astral);var hasLoneHighSurrogates=!dataIsEmpty(loneHighSurrogates);var hasLoneLowSurrogates=!dataIsEmpty(loneLowSurrogates);var surrogateMappings=surrogateSet(astral);if(bmpOnly){bmp=dataAddData(bmp,loneHighSurrogates);hasLoneHighSurrogates=false;bmp=dataAddData(bmp,loneLowSurrogates);hasLoneLowSurrogates=false}if(!dataIsEmpty(bmp)){result.push(createBMPCharacterClasses(bmp))}if(surrogateMappings.length){result.push(createSurrogateCharacterClasses(surrogateMappings))}if(hasLoneHighSurrogates){result.push(createBMPCharacterClasses(loneHighSurrogates)+"(?![\\uDC00-\\uDFFF])")}if(hasLoneLowSurrogates){result.push("(?:[^\\uD800-\\uDBFF]|^)"+createBMPCharacterClasses(loneLowSurrogates))}return result.join("|")};var regenerate=function(value){if(arguments.length>1){value=slice.call(arguments)}if(this instanceof regenerate){this.data=[];return value?this.add(value):this}return(new regenerate).add(value)};regenerate.version="1.2.0";var proto=regenerate.prototype;extend(proto,{add:function(value){var $this=this;if(value==null){return $this}if(value instanceof regenerate){$this.data=dataAddData($this.data,value.data);return $this}if(arguments.length>1){value=slice.call(arguments)}if(isArray(value)){forEach(value,function(item){$this.add(item)});return $this}$this.data=dataAdd($this.data,isNumber(value)?value:symbolToCodePoint(value));return $this},remove:function(value){var $this=this;if(value==null){return $this}if(value instanceof regenerate){$this.data=dataRemoveData($this.data,value.data);return $this}if(arguments.length>1){value=slice.call(arguments)}if(isArray(value)){forEach(value,function(item){$this.remove(item)});return $this}$this.data=dataRemove($this.data,isNumber(value)?value:symbolToCodePoint(value));return $this},addRange:function(start,end){var $this=this;$this.data=dataAddRange($this.data,isNumber(start)?start:symbolToCodePoint(start),isNumber(end)?end:symbolToCodePoint(end));return $this},removeRange:function(start,end){var $this=this;var startCodePoint=isNumber(start)?start:symbolToCodePoint(start);var endCodePoint=isNumber(end)?end:symbolToCodePoint(end);$this.data=dataRemoveRange($this.data,startCodePoint,endCodePoint);return $this},intersection:function(argument){var $this=this;var array=argument instanceof regenerate?dataToArray(argument.data):argument;$this.data=dataIntersection($this.data,array);return $this},contains:function(codePoint){return dataContains(this.data,isNumber(codePoint)?codePoint:symbolToCodePoint(codePoint))},clone:function(){var set=new regenerate;set.data=this.data.slice(0);return set},toString:function(options){var result=createCharacterClassesFromData(this.data,options?options.bmpOnly:false);return result.replace(regexNull,"\\0$1")},toRegExp:function(flags){return RegExp(this.toString(),flags||"")},valueOf:function(){return dataToArray(this.data)}});proto.toArray=proto.valueOf;if(typeof define=="function"&&typeof define.amd=="object"&&define.amd){define(function(){return regenerate})}else if(freeExports&&!freeExports.nodeType){if(freeModule){freeModule.exports=regenerate}else{freeExports.regenerate=regenerate}}else{root.regenerate=regenerate}})(this)}).call(this,typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{})},{}],322:[function(require,module,exports){(function(global){(function(){"use strict";var objectTypes={"function":true,object:true};var root=objectTypes[typeof window]&&window||this;var oldRoot=root;var freeExports=objectTypes[typeof exports]&&exports;var freeModule=objectTypes[typeof module]&&module&&!module.nodeType&&module;var freeGlobal=freeExports&&freeModule&&typeof global=="object"&&global;if(freeGlobal&&(freeGlobal.global===freeGlobal||freeGlobal.window===freeGlobal||freeGlobal.self===freeGlobal)){root=freeGlobal}var stringFromCharCode=String.fromCharCode;var floor=Math.floor;function fromCodePoint(){var MAX_SIZE=16384;var codeUnits=[];var highSurrogate;var lowSurrogate;var index=-1;var length=arguments.length;if(!length){return""}var result="";while(++index<length){var codePoint=Number(arguments[index]);if(!isFinite(codePoint)||codePoint<0||codePoint>1114111||floor(codePoint)!=codePoint){throw RangeError("Invalid code point: "+codePoint)}if(codePoint<=65535){codeUnits.push(codePoint)}else{codePoint-=65536;highSurrogate=(codePoint>>10)+55296;lowSurrogate=codePoint%1024+56320;codeUnits.push(highSurrogate,lowSurrogate)}if(index+1==length||codeUnits.length>MAX_SIZE){result+=stringFromCharCode.apply(null,codeUnits);codeUnits.length=0}}return result}function assertType(type,expected){if(expected.indexOf("|")==-1){if(type==expected){return}throw Error("Invalid node type: "+type) }expected=assertType.hasOwnProperty(expected)?assertType[expected]:assertType[expected]=RegExp("^(?:"+expected+")$");if(expected.test(type)){return}throw Error("Invalid node type: "+type)}function generate(node){var type=node.type;if(generate.hasOwnProperty(type)&&typeof generate[type]=="function"){return generate[type](node)}throw Error("Invalid node type: "+type)}function generateAlternative(node){assertType(node.type,"alternative");var terms=node.body,length=terms?terms.length:0;if(length==1){return generateTerm(terms[0])}else{var i=-1,result="";while(++i<length){result+=generateTerm(terms[i])}return result}}function generateAnchor(node){assertType(node.type,"anchor");switch(node.kind){case"start":return"^";case"end":return"$";case"boundary":return"\\b";case"not-boundary":return"\\B";default:throw Error("Invalid assertion")}}function generateAtom(node){assertType(node.type,"anchor|characterClass|characterClassEscape|dot|group|reference|value");return generate(node)}function generateCharacterClass(node){assertType(node.type,"characterClass");var classRanges=node.body,length=classRanges?classRanges.length:0;var i=-1,result="[";if(node.negative){result+="^"}while(++i<length){result+=generateClassAtom(classRanges[i])}result+="]";return result}function generateCharacterClassEscape(node){assertType(node.type,"characterClassEscape");return"\\"+node.value}function generateCharacterClassRange(node){assertType(node.type,"characterClassRange");var min=node.min,max=node.max;if(min.type=="characterClassRange"||max.type=="characterClassRange"){throw Error("Invalid character class range")}return generateClassAtom(min)+"-"+generateClassAtom(max)}function generateClassAtom(node){assertType(node.type,"anchor|characterClassEscape|characterClassRange|dot|value");return generate(node)}function generateDisjunction(node){assertType(node.type,"disjunction");var body=node.body,length=body?body.length:0;if(length==0){throw Error("No body")}else if(length==1){return generate(body[0])}else{var i=-1,result="";while(++i<length){if(i!=0){result+="|"}result+=generate(body[i])}return result}}function generateDot(node){assertType(node.type,"dot");return"."}function generateGroup(node){assertType(node.type,"group");var result="(";switch(node.behavior){case"normal":break;case"ignore":result+="?:";break;case"lookahead":result+="?=";break;case"negativeLookahead":result+="?!";break;default:throw Error("Invalid behaviour: "+node.behaviour)}var body=node.body,length=body?body.length:0;if(length==1){result+=generate(body[0])}else{var i=-1;while(++i<length){result+=generate(body[i])}}result+=")";return result}function generateQuantifier(node){assertType(node.type,"quantifier");var quantifier="",min=node.min,max=node.max;switch(max){case undefined:case null:switch(min){case 0:quantifier="*";break;case 1:quantifier="+";break;default:quantifier="{"+min+",}";break}break;default:if(min==max){quantifier="{"+min+"}"}else if(min==0&&max==1){quantifier="?"}else{quantifier="{"+min+","+max+"}"}break}if(!node.greedy){quantifier+="?"}return generateAtom(node.body[0])+quantifier}function generateReference(node){assertType(node.type,"reference");return"\\"+node.matchIndex}function generateTerm(node){assertType(node.type,"anchor|characterClass|characterClassEscape|empty|group|quantifier|reference|value");return generate(node)}function generateValue(node){assertType(node.type,"value");var kind=node.kind,codePoint=node.codePoint;switch(kind){case"controlLetter":return"\\c"+fromCodePoint(codePoint+64);case"hexadecimalEscape":return"\\x"+("00"+codePoint.toString(16).toUpperCase()).slice(-2);case"identifier":return"\\"+fromCodePoint(codePoint);case"null":return"\\"+codePoint;case"octal":return"\\"+codePoint.toString(8);case"singleEscape":switch(codePoint){case 8:return"\\b";case 9:return"\\t";case 10:return"\\n";case 11:return"\\v";case 12:return"\\f";case 13:return"\\r";default:throw Error("Invalid codepoint: "+codePoint)}case"symbol":return fromCodePoint(codePoint);case"unicodeEscape":return"\\u"+("0000"+codePoint.toString(16).toUpperCase()).slice(-4);case"unicodeCodePointEscape":return"\\u{"+codePoint.toString(16).toUpperCase()+"}";default:throw Error("Unsupported node kind: "+kind)}}generate.alternative=generateAlternative;generate.anchor=generateAnchor;generate.characterClass=generateCharacterClass;generate.characterClassEscape=generateCharacterClassEscape;generate.characterClassRange=generateCharacterClassRange;generate.disjunction=generateDisjunction;generate.dot=generateDot;generate.group=generateGroup;generate.quantifier=generateQuantifier;generate.reference=generateReference;generate.value=generateValue;if(typeof define=="function"&&typeof define.amd=="object"&&define.amd){define(function(){return{generate:generate}})}else if(freeExports&&freeModule){freeExports.generate=generate}else{root.regjsgen={generate:generate}}}).call(this)}).call(this,typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{})},{}],323:[function(require,module,exports){(function(){function parse(str,flags){var hasUnicodeFlag=(flags||"").indexOf("u")!==-1;var pos=0;var closedCaptureCounter=0;function addRaw(node){node.raw=str.substring(node.range[0],node.range[1]);return node}function updateRawStart(node,start){node.range[0]=start;return addRaw(node)}function createAnchor(kind,rawLength){return addRaw({type:"anchor",kind:kind,range:[pos-rawLength,pos]})}function createValue(kind,codePoint,from,to){return addRaw({type:"value",kind:kind,codePoint:codePoint,range:[from,to]})}function createEscaped(kind,codePoint,value,fromOffset){fromOffset=fromOffset||0;return createValue(kind,codePoint,pos-(value.length+fromOffset),pos)}function createCharacter(matches){var _char=matches[0];var first=_char.charCodeAt(0);if(hasUnicodeFlag){var second;if(_char.length===1&&first>=55296&&first<=56319){second=lookahead().charCodeAt(0);if(second>=56320&&second<=57343){pos++;return createValue("symbol",(first-55296)*1024+second-56320+65536,pos-2,pos)}}}return createValue("symbol",first,pos-1,pos)}function createDisjunction(alternatives,from,to){return addRaw({type:"disjunction",body:alternatives,range:[from,to]})}function createDot(){return addRaw({type:"dot",range:[pos-1,pos]})}function createCharacterClassEscape(value){return addRaw({type:"characterClassEscape",value:value,range:[pos-2,pos]})}function createReference(matchIndex){return addRaw({type:"reference",matchIndex:parseInt(matchIndex,10),range:[pos-1-matchIndex.length,pos]})}function createGroup(behavior,disjunction,from,to){return addRaw({type:"group",behavior:behavior,body:disjunction,range:[from,to]})}function createQuantifier(min,max,from,to){if(to==null){from=pos-1;to=pos}return addRaw({type:"quantifier",min:min,max:max,greedy:true,body:null,range:[from,to]})}function createAlternative(terms,from,to){return addRaw({type:"alternative",body:terms,range:[from,to]})}function createCharacterClass(classRanges,negative,from,to){return addRaw({type:"characterClass",body:classRanges,negative:negative,range:[from,to]})}function createClassRange(min,max,from,to){if(min.codePoint>max.codePoint){throw SyntaxError("invalid range in character class")}return addRaw({type:"characterClassRange",min:min,max:max,range:[from,to]})}function flattenBody(body){if(body.type==="alternative"){return body.body}else{return[body]}}function isEmpty(obj){return obj.type==="empty"}function incr(amount){amount=amount||1;var res=str.substring(pos,pos+amount);pos+=amount||1;return res}function skip(value){if(!match(value)){throw SyntaxError("character: "+value)}}function match(value){if(str.indexOf(value,pos)===pos){return incr(value.length)}}function lookahead(){return str[pos]}function current(value){return str.indexOf(value,pos)===pos}function next(value){return str[pos+1]===value}function matchReg(regExp){var subStr=str.substring(pos);var res=subStr.match(regExp);if(res){res.range=[];res.range[0]=pos;incr(res[0].length);res.range[1]=pos}return res}function parseDisjunction(){var res=[],from=pos;res.push(parseAlternative());while(match("|")){res.push(parseAlternative())}if(res.length===1){return res[0]}return createDisjunction(res,from,pos)}function parseAlternative(){var res=[],from=pos;var term;while(term=parseTerm()){res.push(term)}if(res.length===1){return res[0]}return createAlternative(res,from,pos)}function parseTerm(){if(pos>=str.length||current("|")||current(")")){return null}var anchor=parseAnchor();if(anchor){return anchor}var atom=parseAtom();if(!atom){throw SyntaxError("Expected atom")}var quantifier=parseQuantifier()||false;if(quantifier){quantifier.body=flattenBody(atom);updateRawStart(quantifier,atom.range[0]);return quantifier}return atom}function parseGroup(matchA,typeA,matchB,typeB){var type=null,from=pos;if(match(matchA)){type=typeA}else if(match(matchB)){type=typeB}else{return false}var body=parseDisjunction();if(!body){throw SyntaxError("Expected disjunction")}skip(")");var group=createGroup(type,flattenBody(body),from,pos);if(type=="normal"){closedCaptureCounter++}return group}function parseAnchor(){var res,from=pos;if(match("^")){return createAnchor("start",1)}else if(match("$")){return createAnchor("end",1)}else if(match("\\b")){return createAnchor("boundary",2)}else if(match("\\B")){return createAnchor("not-boundary",2)}else{return parseGroup("(?=","lookahead","(?!","negativeLookahead")}}function parseQuantifier(){var res;var quantifier;var min,max;if(match("*")){quantifier=createQuantifier(0)}else if(match("+")){quantifier=createQuantifier(1)}else if(match("?")){quantifier=createQuantifier(0,1)}else if(res=matchReg(/^\{([0-9]+)\}/)){min=parseInt(res[1],10);quantifier=createQuantifier(min,min,res.range[0],res.range[1])}else if(res=matchReg(/^\{([0-9]+),\}/)){min=parseInt(res[1],10);quantifier=createQuantifier(min,undefined,res.range[0],res.range[1])}else if(res=matchReg(/^\{([0-9]+),([0-9]+)\}/)){min=parseInt(res[1],10);max=parseInt(res[2],10);if(min>max){throw SyntaxError("numbers out of order in {} quantifier")}quantifier=createQuantifier(min,max,res.range[0],res.range[1])}if(quantifier){if(match("?")){quantifier.greedy=false;quantifier.range[1]+=1}}return quantifier}function parseAtom(){var res;if(res=matchReg(/^[^^$\\.*+?(){[|]/)){return createCharacter(res)}else if(match(".")){return createDot()}else if(match("\\")){res=parseAtomEscape();if(!res){throw SyntaxError("atomEscape")}return res}else if(res=parseCharacterClass()){return res}else{return parseGroup("(?:","ignore","(","normal")}}function parseUnicodeSurrogatePairEscape(firstEscape){if(hasUnicodeFlag){var first,second;if(firstEscape.kind=="unicodeEscape"&&(first=firstEscape.codePoint)>=55296&&first<=56319&&current("\\")&&next("u")){var prevPos=pos;pos++;var secondEscape=parseClassEscape();if(secondEscape.kind=="unicodeEscape"&&(second=secondEscape.codePoint)>=56320&&second<=57343){firstEscape.range[1]=secondEscape.range[1];firstEscape.codePoint=(first-55296)*1024+second-56320+65536;firstEscape.type="value";firstEscape.kind="unicodeCodePointEscape";addRaw(firstEscape)}else{pos=prevPos}}}return firstEscape}function parseClassEscape(){return parseAtomEscape(true)}function parseAtomEscape(insideCharacterClass){var res;res=parseDecimalEscape();if(res){return res}if(insideCharacterClass){if(match("b")){return createEscaped("singleEscape",8,"\\b")}else if(match("B")){throw SyntaxError("\\B not possible inside of CharacterClass")}}res=parseCharacterEscape();return res}function parseDecimalEscape(){var res,match;if(res=matchReg(/^(?!0)\d+/)){match=res[0];var refIdx=parseInt(res[0],10);if(refIdx<=closedCaptureCounter){return createReference(res[0])}else{incr(-res[0].length);if(res=matchReg(/^[0-7]{1,3}/)){return createEscaped("octal",parseInt(res[0],8),res[0],1)}else{res=createCharacter(matchReg(/^[89]/));return updateRawStart(res,res.range[0]-1)}}}else if(res=matchReg(/^[0-7]{1,3}/)){match=res[0];if(/^0{1,3}$/.test(match)){return createEscaped("null",0,"0",match.length+1)}else{return createEscaped("octal",parseInt(match,8),match,1)}}else if(res=matchReg(/^[dDsSwW]/)){return createCharacterClassEscape(res[0])}return false}function parseCharacterEscape(){var res;if(res=matchReg(/^[fnrtv]/)){var codePoint=0;switch(res[0]){case"t":codePoint=9;break;case"n":codePoint=10;break;case"v":codePoint=11;break;case"f":codePoint=12;break;case"r":codePoint=13;break}return createEscaped("singleEscape",codePoint,"\\"+res[0])}else if(res=matchReg(/^c([a-zA-Z])/)){return createEscaped("controlLetter",res[1].charCodeAt(0)%32,res[1],2)}else if(res=matchReg(/^x([0-9a-fA-F]{2})/)){return createEscaped("hexadecimalEscape",parseInt(res[1],16),res[1],2)}else if(res=matchReg(/^u([0-9a-fA-F]{4})/)){return parseUnicodeSurrogatePairEscape(createEscaped("unicodeEscape",parseInt(res[1],16),res[1],2))}else if(hasUnicodeFlag&&(res=matchReg(/^u\{([0-9a-fA-F]{1,})\}/))){return createEscaped("unicodeCodePointEscape",parseInt(res[1],16),res[1],4)}else{return parseIdentityEscape()}}function isIdentifierPart(ch){var NonAsciiIdentifierPart=new RegExp("[ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮ̀-ʹͶͷͺ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁ҃-҇Ҋ-ԯԱ-Ֆՙա-և֑-ׇֽֿׁׂׅׄא-תװ-ײؐ-ؚؠ-٩ٮ-ۓە-ۜ۟-۪ۨ-ۼۿܐ-݊ݍ-ޱ߀-ߵߺࠀ-࠭ࡀ-࡛ࢠ-ࢲࣤ-ॣ०-९ॱ-ঃঅ-ঌএঐও-নপ-রলশ-হ়-ৄেৈো-ৎৗড়ঢ়য়-ৣ০-ৱਁ-ਃਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹ਼ਾ-ੂੇੈੋ-੍ੑਖ਼-ੜਫ਼੦-ੵઁ-ઃઅ-ઍએ-ઑઓ-નપ-રલળવ-હ઼-ૅે-ૉો-્ૐૠ-ૣ૦-૯ଁ-ଃଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହ଼-ୄେୈୋ-୍ୖୗଡ଼ଢ଼ୟ-ୣ୦-୯ୱஂஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹா-ூெ-ைொ-்ௐௗ௦-௯ఀ-ఃఅ-ఌఎ-ఐఒ-నప-హఽ-ౄె-ైొ-్ౕౖౘౙౠ-ౣ౦-౯ಁ-ಃಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹ಼-ೄೆ-ೈೊ-್ೕೖೞೠ-ೣ೦-೯ೱೲഁ-ഃഅ-ഌഎ-ഐഒ-ഺഽ-ൄെ-ൈൊ-ൎൗൠ-ൣ൦-൯ൺ-ൿංඃඅ-ඖක-නඳ-රලව-ෆ්ා-ුූෘ-ෟ෦-෯ෲෳก-ฺเ-๎๐-๙ກຂຄງຈຊຍດ-ທນ-ຟມ-ຣລວສຫອ-ູົ-ຽເ-ໄໆ່-ໍ໐-໙ໜ-ໟༀ༘༙༠-༩༹༵༷༾-ཇཉ-ཬཱ-྄྆-ྗྙ-ྼ࿆က-၉ၐ-ႝႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚ፝-፟ᎀ-ᎏᎠ-Ᏼᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛸᜀ-ᜌᜎ-᜔ᜠ-᜴ᝀ-ᝓᝠ-ᝬᝮ-ᝰᝲᝳក-៓ៗៜ៝០-៩᠋-᠍᠐-᠙ᠠ-ᡷᢀ-ᢪᢰ-ᣵᤀ-ᤞᤠ-ᤫᤰ-᤻᥆-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧉ᧐-᧙ᨀ-ᨛᨠ-ᩞ᩠-᩿᩼-᪉᪐-᪙ᪧ᪰-᪽ᬀ-ᭋ᭐-᭙᭫-᭳ᮀ-᯳ᰀ-᰷᱀-᱉ᱍ-ᱽ᳐-᳔᳒-ᳶ᳸᳹ᴀ-᷵᷼-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼ‌‍‿⁀⁔ⁱⁿₐ-ₜ⃐-⃥⃜⃡-⃰ℂℇℊ-ℓℕℙ-ℝℤΩℨK-ℭℯ-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-Ⱞⰰ-ⱞⱠ-ⳤⳫ-ⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯ⵿-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞⷠ-ⷿⸯ々-〇〡-〯〱-〵〸-〼ぁ-ゖ゙゚ゝ-ゟァ-ヺー-ヿㄅ-ㄭㄱ-ㆎㆠ-ㆺㇰ-ㇿ㐀-䶵一-鿌ꀀ-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘫꙀ-꙯ꙴ-꙽ꙿ-ꚝꚟ-꛱ꜗ-ꜟꜢ-ꞈꞋ-ꞎꞐ-ꞭꞰꞱꟷ-ꠧꡀ-ꡳꢀ-꣄꣐-꣙꣠-ꣷꣻ꤀-꤭ꤰ-꥓ꥠ-ꥼꦀ-꧀ꧏ-꧙ꧠ-ꧾꨀ-ꨶꩀ-ꩍ꩐-꩙ꩠ-ꩶꩺ-ꫂꫛ-ꫝꫠ-ꫯꫲ-꫶ꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚꭜ-ꭟꭤꭥꯀ-ꯪ꯬꯭꯰-꯹가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻ︀-️︠-︭︳︴﹍-﹏ﹰ-ﹴﹶ-ﻼ0-9A-Z_a-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ]");return ch===36||ch===95||ch>=65&&ch<=90||ch>=97&&ch<=122||ch>=48&&ch<=57||ch===92||ch>=128&&NonAsciiIdentifierPart.test(String.fromCharCode(ch))}function parseIdentityEscape(){var ZWJ="‌";var ZWNJ="‍";var res;var tmp;if(!isIdentifierPart(lookahead())){tmp=incr();return createEscaped("identifier",tmp.charCodeAt(0),tmp,1)}if(match(ZWJ)){return createEscaped("identifier",8204,ZWJ)}else if(match(ZWNJ)){return createEscaped("identifier",8205,ZWNJ)}return null}function parseCharacterClass(){var res,from=pos;if(res=matchReg(/^\[\^/)){res=parseClassRanges();skip("]");return createCharacterClass(res,true,from,pos)}else if(match("[")){res=parseClassRanges();skip("]");return createCharacterClass(res,false,from,pos)}return null}function parseClassRanges(){var res;if(current("]")){return[]}else{res=parseNonemptyClassRanges();if(!res){throw SyntaxError("nonEmptyClassRanges")}return res}}function parseHelperClassRanges(atom){var from,to,res;if(current("-")&&!next("]")){skip("-");res=parseClassAtom();if(!res){throw SyntaxError("classAtom")}to=pos;var classRanges=parseClassRanges();if(!classRanges){throw SyntaxError("classRanges")}from=atom.range[0];if(classRanges.type==="empty"){return[createClassRange(atom,res,from,to)]}return[createClassRange(atom,res,from,to)].concat(classRanges)}res=parseNonemptyClassRangesNoDash();if(!res){throw SyntaxError("nonEmptyClassRangesNoDash")}return[atom].concat(res)}function parseNonemptyClassRanges(){var atom=parseClassAtom();if(!atom){throw SyntaxError("classAtom")}if(current("]")){return[atom]}return parseHelperClassRanges(atom)}function parseNonemptyClassRangesNoDash(){var res=parseClassAtom();if(!res){throw SyntaxError("classAtom")}if(current("]")){return res}return parseHelperClassRanges(res)}function parseClassAtom(){if(match("-")){return createCharacter("-")}else{return parseClassAtomNoDash()}}function parseClassAtomNoDash(){var res;if(res=matchReg(/^[^\\\]-]/)){return createCharacter(res[0])}else if(match("\\")){res=parseClassEscape();if(!res){throw SyntaxError("classEscape")}return parseUnicodeSurrogatePairEscape(res)}}str=String(str);if(str===""){str="(?:)"}var result=parseDisjunction();if(result.range[1]!==str.length){throw SyntaxError("Could not parse entire input - got stuck: "+str)}return result}var regjsparser={parse:parse};if(typeof module!=="undefined"&&module.exports){module.exports=regjsparser}else{window.regjsparser=regjsparser}})()},{}],324:[function(require,module,exports){var generate=require("regjsgen").generate;var parse=require("regjsparser").parse;var regenerate=require("regenerate");var iuMappings=require("./data/iu-mappings.json");var ESCAPE_SETS=require("./data/character-class-escape-sets.js");function getCharacterClassEscapeSet(character){if(unicode){if(ignoreCase){return ESCAPE_SETS.UNICODE_IGNORE_CASE[character]}return ESCAPE_SETS.UNICODE[character]}return ESCAPE_SETS.REGULAR[character]}var object={};var hasOwnProperty=object.hasOwnProperty;function has(object,property){return hasOwnProperty.call(object,property)}var UNICODE_SET=regenerate().addRange(0,1114111);var BMP_SET=regenerate().addRange(0,65535);var DOT_SET_UNICODE=UNICODE_SET.clone().remove(10,13,8232,8233);var DOT_SET=DOT_SET_UNICODE.clone().intersection(BMP_SET);regenerate.prototype.iuAddRange=function(min,max){var $this=this;do{var folded=caseFold(min);if(folded){$this.add(folded)}}while(++min<=max);return $this};function assign(target,source){for(var key in source){target[key]=source[key]}}function update(item,pattern){if(!pattern){return}var tree=parse(pattern,"");switch(tree.type){case"characterClass":case"group":case"value":break;default:tree=wrap(tree,pattern)}assign(item,tree)}function wrap(tree,pattern){return{type:"group",behavior:"ignore",body:[tree],raw:"(?:"+pattern+")"}}function caseFold(codePoint){return has(iuMappings,codePoint)?iuMappings[codePoint]:false}var ignoreCase=false;var unicode=false;function processCharacterClass(characterClassItem){var set=regenerate();var body=characterClassItem.body.forEach(function(item){switch(item.type){case"value":set.add(item.codePoint);if(ignoreCase&&unicode){var folded=caseFold(item.codePoint);if(folded){set.add(folded)}}break;case"characterClassRange":var min=item.min.codePoint;var max=item.max.codePoint;set.addRange(min,max);if(ignoreCase&&unicode){set.iuAddRange(min,max)}break;case"characterClassEscape":set.add(getCharacterClassEscapeSet(item.value));break;default:throw Error("Unknown term type: "+item.type)}});if(characterClassItem.negative){set=(unicode?UNICODE_SET:BMP_SET).clone().remove(set)}update(characterClassItem,set.toString());return characterClassItem}function processTerm(item){switch(item.type){case"dot":update(item,(unicode?DOT_SET_UNICODE:DOT_SET).toString());break;case"characterClass":item=processCharacterClass(item);break;case"characterClassEscape":update(item,getCharacterClassEscapeSet(item.value).toString());break;case"alternative":case"disjunction":case"group":case"quantifier":item.body=item.body.map(processTerm);break;case"value":var codePoint=item.codePoint;var set=regenerate(codePoint);if(ignoreCase&&unicode){var folded=caseFold(codePoint);if(folded){set.add(folded)}}update(item,set.toString());break;case"anchor":case"empty":case"group":case"reference":break;default:throw Error("Unknown term type: "+item.type)}return item}module.exports=function(pattern,flags){var tree=parse(pattern,flags);ignoreCase=flags?flags.indexOf("i")>-1:false;unicode=flags?flags.indexOf("u")>-1:false;assign(tree,processTerm(tree));return generate(tree)}},{"./data/character-class-escape-sets.js":319,"./data/iu-mappings.json":320,regenerate:321,regjsgen:322,regjsparser:323}],325:[function(require,module,exports){"use strict";var isFinite=require("is-finite");module.exports=function(str,n){if(typeof str!=="string"){throw new TypeError("Expected a string as the first argument")}if(n<0||!isFinite(n)){throw new TypeError("Expected a finite positive number")}var ret="";do{if(n&1){ret+=str}str+=str}while(n=n>>1);return ret}},{"is-finite":326}],326:[function(require,module,exports){arguments[4][189][0].apply(exports,arguments)},{dup:189}],327:[function(require,module,exports){"use strict";module.exports=/^#!.*/},{}],328:[function(require,module,exports){"use strict";module.exports=function(str){var isExtendedLengthPath=/^\\\\\?\\/.test(str);var hasNonAscii=/[^\x00-\x80]+/.test(str);if(isExtendedLengthPath||hasNonAscii){return str}return str.replace(/\\/g,"/")}},{}],329:[function(require,module,exports){(function(Buffer){"use strict";module.exports=function(val){var base64=new Buffer(JSON.stringify(val)).toString("base64");return"//# sourceMappingURL=data:application/json;base64,"+base64}}).call(this,require("buffer").Buffer)},{buffer:143}],330:[function(require,module,exports){exports.SourceMapGenerator=require("./source-map/source-map-generator").SourceMapGenerator;exports.SourceMapConsumer=require("./source-map/source-map-consumer").SourceMapConsumer;exports.SourceNode=require("./source-map/source-node").SourceNode},{"./source-map/source-map-consumer":336,"./source-map/source-map-generator":337,"./source-map/source-node":338}],331:[function(require,module,exports){if(typeof define!=="function"){var define=require("amdefine")(module,require)}define(function(require,exports,module){var util=require("./util");function ArraySet(){this._array=[];this._set={}}ArraySet.fromArray=function ArraySet_fromArray(aArray,aAllowDuplicates){var set=new ArraySet;for(var i=0,len=aArray.length;i<len;i++){set.add(aArray[i],aAllowDuplicates)}return set};ArraySet.prototype.add=function ArraySet_add(aStr,aAllowDuplicates){var isDuplicate=this.has(aStr);var idx=this._array.length;if(!isDuplicate||aAllowDuplicates){this._array.push(aStr)}if(!isDuplicate){this._set[util.toSetString(aStr)]=idx}};ArraySet.prototype.has=function ArraySet_has(aStr){return Object.prototype.hasOwnProperty.call(this._set,util.toSetString(aStr))};ArraySet.prototype.indexOf=function ArraySet_indexOf(aStr){if(this.has(aStr)){return this._set[util.toSetString(aStr)]}throw new Error('"'+aStr+'" is not in the set.')};ArraySet.prototype.at=function ArraySet_at(aIdx){if(aIdx>=0&&aIdx<this._array.length){return this._array[aIdx]}throw new Error("No element indexed by "+aIdx)};ArraySet.prototype.toArray=function ArraySet_toArray(){return this._array.slice()};exports.ArraySet=ArraySet})},{"./util":339,amdefine:340}],332:[function(require,module,exports){if(typeof define!=="function"){var define=require("amdefine")(module,require)}define(function(require,exports,module){var base64=require("./base64");var VLQ_BASE_SHIFT=5;var VLQ_BASE=1<<VLQ_BASE_SHIFT;var VLQ_BASE_MASK=VLQ_BASE-1;var VLQ_CONTINUATION_BIT=VLQ_BASE;function toVLQSigned(aValue){return aValue<0?(-aValue<<1)+1:(aValue<<1)+0}function fromVLQSigned(aValue){var isNegative=(aValue&1)===1;var shifted=aValue>>1;return isNegative?-shifted:shifted}exports.encode=function base64VLQ_encode(aValue){var encoded="";var digit;var vlq=toVLQSigned(aValue);do{digit=vlq&VLQ_BASE_MASK;vlq>>>=VLQ_BASE_SHIFT;if(vlq>0){digit|=VLQ_CONTINUATION_BIT}encoded+=base64.encode(digit)}while(vlq>0);return encoded};exports.decode=function base64VLQ_decode(aStr,aIndex,aOutParam){var strLen=aStr.length;var result=0;var shift=0;var continuation,digit;do{if(aIndex>=strLen){throw new Error("Expected more digits in base 64 VLQ value.")}digit=base64.decode(aStr.charAt(aIndex++));continuation=!!(digit&VLQ_CONTINUATION_BIT);digit&=VLQ_BASE_MASK;result=result+(digit<<shift);shift+=VLQ_BASE_SHIFT}while(continuation);aOutParam.value=fromVLQSigned(result);aOutParam.rest=aIndex}})},{"./base64":333,amdefine:340}],333:[function(require,module,exports){if(typeof define!=="function"){var define=require("amdefine")(module,require)}define(function(require,exports,module){var charToIntMap={};var intToCharMap={};"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split("").forEach(function(ch,index){charToIntMap[ch]=index;intToCharMap[index]=ch});exports.encode=function base64_encode(aNumber){if(aNumber in intToCharMap){return intToCharMap[aNumber]}throw new TypeError("Must be between 0 and 63: "+aNumber)};exports.decode=function base64_decode(aChar){if(aChar in charToIntMap){return charToIntMap[aChar]}throw new TypeError("Not a valid base 64 digit: "+aChar)}})},{amdefine:340}],334:[function(require,module,exports){if(typeof define!=="function"){var define=require("amdefine")(module,require)}define(function(require,exports,module){exports.GREATEST_LOWER_BOUND=1;exports.LEAST_UPPER_BOUND=2;function recursiveSearch(aLow,aHigh,aNeedle,aHaystack,aCompare,aBias){var mid=Math.floor((aHigh-aLow)/2)+aLow;var cmp=aCompare(aNeedle,aHaystack[mid],true);if(cmp===0){return mid}else if(cmp>0){if(aHigh-mid>1){return recursiveSearch(mid,aHigh,aNeedle,aHaystack,aCompare,aBias)}if(aBias==exports.LEAST_UPPER_BOUND){return aHigh<aHaystack.length?aHigh:-1}else{return mid}}else{if(mid-aLow>1){return recursiveSearch(aLow,mid,aNeedle,aHaystack,aCompare,aBias)}if(aBias==exports.LEAST_UPPER_BOUND){return mid}else{return aLow<0?-1:aLow}}}exports.search=function search(aNeedle,aHaystack,aCompare,aBias){if(aHaystack.length===0){return-1}return recursiveSearch(-1,aHaystack.length,aNeedle,aHaystack,aCompare,aBias||exports.GREATEST_LOWER_BOUND)}})},{amdefine:340}],335:[function(require,module,exports){if(typeof define!=="function"){var define=require("amdefine")(module,require)}define(function(require,exports,module){var util=require("./util");function generatedPositionAfter(mappingA,mappingB){var lineA=mappingA.generatedLine;var lineB=mappingB.generatedLine;var columnA=mappingA.generatedColumn;var columnB=mappingB.generatedColumn;return lineB>lineA||lineB==lineA&&columnB>=columnA||util.compareByGeneratedPositions(mappingA,mappingB)<=0}function MappingList(){this._array=[];this._sorted=true;this._last={generatedLine:-1,generatedColumn:0}}MappingList.prototype.unsortedForEach=function MappingList_forEach(aCallback,aThisArg){this._array.forEach(aCallback,aThisArg)};MappingList.prototype.add=function MappingList_add(aMapping){var mapping;if(generatedPositionAfter(this._last,aMapping)){this._last=aMapping;this._array.push(aMapping)}else{this._sorted=false;this._array.push(aMapping)}};MappingList.prototype.toArray=function MappingList_toArray(){if(!this._sorted){this._array.sort(util.compareByGeneratedPositions);this._sorted=true}return this._array};exports.MappingList=MappingList})},{"./util":339,amdefine:340}],336:[function(require,module,exports){if(typeof define!=="function"){var define=require("amdefine")(module,require)}define(function(require,exports,module){var util=require("./util");var binarySearch=require("./binary-search");var ArraySet=require("./array-set").ArraySet;var base64VLQ=require("./base64-vlq");function SourceMapConsumer(aSourceMap){var sourceMap=aSourceMap;if(typeof aSourceMap==="string"){sourceMap=JSON.parse(aSourceMap.replace(/^\)\]\}'/,""))}return sourceMap.sections!=null?new IndexedSourceMapConsumer(sourceMap):new BasicSourceMapConsumer(sourceMap)}SourceMapConsumer.fromSourceMap=function(aSourceMap){return BasicSourceMapConsumer.fromSourceMap(aSourceMap)};SourceMapConsumer.prototype._version=3;SourceMapConsumer.prototype.__generatedMappings=null;Object.defineProperty(SourceMapConsumer.prototype,"_generatedMappings",{get:function(){if(!this.__generatedMappings){this.__generatedMappings=[];this.__originalMappings=[];this._parseMappings(this._mappings,this.sourceRoot)}return this.__generatedMappings}});SourceMapConsumer.prototype.__originalMappings=null;Object.defineProperty(SourceMapConsumer.prototype,"_originalMappings",{get:function(){if(!this.__originalMappings){this.__generatedMappings=[];this.__originalMappings=[];this._parseMappings(this._mappings,this.sourceRoot)}return this.__originalMappings}});SourceMapConsumer.prototype._nextCharIsMappingSeparator=function SourceMapConsumer_nextCharIsMappingSeparator(aStr,index){var c=aStr.charAt(index);return c===";"||c===","};SourceMapConsumer.prototype._parseMappings=function SourceMapConsumer_parseMappings(aStr,aSourceRoot){throw new Error("Subclasses must implement _parseMappings")};SourceMapConsumer.GENERATED_ORDER=1;SourceMapConsumer.ORIGINAL_ORDER=2;SourceMapConsumer.GREATEST_LOWER_BOUND=1;SourceMapConsumer.LEAST_UPPER_BOUND=2;SourceMapConsumer.prototype.eachMapping=function SourceMapConsumer_eachMapping(aCallback,aContext,aOrder){var context=aContext||null;var order=aOrder||SourceMapConsumer.GENERATED_ORDER;var mappings;switch(order){case SourceMapConsumer.GENERATED_ORDER:mappings=this._generatedMappings;break;case SourceMapConsumer.ORIGINAL_ORDER:mappings=this._originalMappings;break;default:throw new Error("Unknown order of iteration.")}var sourceRoot=this.sourceRoot;mappings.map(function(mapping){var source=mapping.source;if(source!=null&&sourceRoot!=null){source=util.join(sourceRoot,source)}return{source:source,generatedLine:mapping.generatedLine,generatedColumn:mapping.generatedColumn,originalLine:mapping.originalLine,originalColumn:mapping.originalColumn,name:mapping.name}}).forEach(aCallback,context)};SourceMapConsumer.prototype.allGeneratedPositionsFor=function SourceMapConsumer_allGeneratedPositionsFor(aArgs){var needle={source:util.getArg(aArgs,"source"),originalLine:util.getArg(aArgs,"line"),originalColumn:0};if(this.sourceRoot!=null){needle.source=util.relative(this.sourceRoot,needle.source)}var mappings=[];var index=this._findMapping(needle,this._originalMappings,"originalLine","originalColumn",util.compareByOriginalPositions,binarySearch.LEAST_UPPER_BOUND);if(index>=0){var mapping=this._originalMappings[index];while(mapping&&mapping.originalLine===needle.originalLine){mappings.push({line:util.getArg(mapping,"generatedLine",null),column:util.getArg(mapping,"generatedColumn",null),lastColumn:util.getArg(mapping,"lastGeneratedColumn",null)});mapping=this._originalMappings[++index]}}return mappings};exports.SourceMapConsumer=SourceMapConsumer;function BasicSourceMapConsumer(aSourceMap){var sourceMap=aSourceMap;if(typeof aSourceMap==="string"){sourceMap=JSON.parse(aSourceMap.replace(/^\)\]\}'/,""))}var version=util.getArg(sourceMap,"version");var sources=util.getArg(sourceMap,"sources");var names=util.getArg(sourceMap,"names",[]);var sourceRoot=util.getArg(sourceMap,"sourceRoot",null);var sourcesContent=util.getArg(sourceMap,"sourcesContent",null);var mappings=util.getArg(sourceMap,"mappings");var file=util.getArg(sourceMap,"file",null);if(version!=this._version){throw new Error("Unsupported version: "+version)}sources=sources.map(util.normalize);this._names=ArraySet.fromArray(names,true);this._sources=ArraySet.fromArray(sources,true);this.sourceRoot=sourceRoot;this.sourcesContent=sourcesContent;this._mappings=mappings;this.file=file}BasicSourceMapConsumer.prototype=Object.create(SourceMapConsumer.prototype);BasicSourceMapConsumer.prototype.consumer=SourceMapConsumer;BasicSourceMapConsumer.fromSourceMap=function SourceMapConsumer_fromSourceMap(aSourceMap){var smc=Object.create(BasicSourceMapConsumer.prototype);smc._names=ArraySet.fromArray(aSourceMap._names.toArray(),true);smc._sources=ArraySet.fromArray(aSourceMap._sources.toArray(),true);smc.sourceRoot=aSourceMap._sourceRoot;smc.sourcesContent=aSourceMap._generateSourcesContent(smc._sources.toArray(),smc.sourceRoot);smc.file=aSourceMap._file;smc.__generatedMappings=aSourceMap._mappings.toArray().slice();smc.__originalMappings=aSourceMap._mappings.toArray().slice().sort(util.compareByOriginalPositions);return smc};BasicSourceMapConsumer.prototype._version=3;Object.defineProperty(BasicSourceMapConsumer.prototype,"sources",{get:function(){return this._sources.toArray().map(function(s){return this.sourceRoot!=null?util.join(this.sourceRoot,s):s},this)}});BasicSourceMapConsumer.prototype._parseMappings=function SourceMapConsumer_parseMappings(aStr,aSourceRoot){var generatedLine=1;var previousGeneratedColumn=0; var previousOriginalLine=0;var previousOriginalColumn=0;var previousSource=0;var previousName=0;var length=aStr.length;var index=0;var cachedValues={};var temp={};var mapping,str,values,end;while(index<length){if(aStr.charAt(index)===";"){generatedLine++;++index;previousGeneratedColumn=0}else if(aStr.charAt(index)===","){++index}else{mapping={};mapping.generatedLine=generatedLine;for(end=index;end<length;++end){if(this._nextCharIsMappingSeparator(aStr,end)){break}}str=aStr.slice(index,end);values=cachedValues[str];if(values){index+=str.length}else{values=[];while(index<end){base64VLQ.decode(aStr,index,temp);value=temp.value;index=temp.rest;values.push(value)}cachedValues[str]=values}mapping.generatedColumn=previousGeneratedColumn+values[0];previousGeneratedColumn=mapping.generatedColumn;if(values.length>1){mapping.source=this._sources.at(previousSource+values[1]);previousSource+=values[1];if(values.length===2){throw new Error("Found a source, but no line and column")}mapping.originalLine=previousOriginalLine+values[2];previousOriginalLine=mapping.originalLine;mapping.originalLine+=1;if(values.length===3){throw new Error("Found a source and line, but no column")}mapping.originalColumn=previousOriginalColumn+values[3];previousOriginalColumn=mapping.originalColumn;if(values.length>4){mapping.name=this._names.at(previousName+values[4]);previousName+=values[4]}}this.__generatedMappings.push(mapping);if(typeof mapping.originalLine==="number"){this.__originalMappings.push(mapping)}}}this.__generatedMappings.sort(util.compareByGeneratedPositions);this.__originalMappings.sort(util.compareByOriginalPositions)};BasicSourceMapConsumer.prototype._findMapping=function SourceMapConsumer_findMapping(aNeedle,aMappings,aLineName,aColumnName,aComparator,aBias){if(aNeedle[aLineName]<=0){throw new TypeError("Line must be greater than or equal to 1, got "+aNeedle[aLineName])}if(aNeedle[aColumnName]<0){throw new TypeError("Column must be greater than or equal to 0, got "+aNeedle[aColumnName])}return binarySearch.search(aNeedle,aMappings,aComparator,aBias)};BasicSourceMapConsumer.prototype.computeColumnSpans=function SourceMapConsumer_computeColumnSpans(){for(var index=0;index<this._generatedMappings.length;++index){var mapping=this._generatedMappings[index];if(index+1<this._generatedMappings.length){var nextMapping=this._generatedMappings[index+1];if(mapping.generatedLine===nextMapping.generatedLine){mapping.lastGeneratedColumn=nextMapping.generatedColumn-1;continue}}mapping.lastGeneratedColumn=Infinity}};BasicSourceMapConsumer.prototype.originalPositionFor=function SourceMapConsumer_originalPositionFor(aArgs){var needle={generatedLine:util.getArg(aArgs,"line"),generatedColumn:util.getArg(aArgs,"column")};var index=this._findMapping(needle,this._generatedMappings,"generatedLine","generatedColumn",util.compareByGeneratedPositions,util.getArg(aArgs,"bias",SourceMapConsumer.GREATEST_LOWER_BOUND));if(index>=0){var mapping=this._generatedMappings[index];if(mapping.generatedLine===needle.generatedLine){var source=util.getArg(mapping,"source",null);if(source!=null&&this.sourceRoot!=null){source=util.join(this.sourceRoot,source)}return{source:source,line:util.getArg(mapping,"originalLine",null),column:util.getArg(mapping,"originalColumn",null),name:util.getArg(mapping,"name",null)}}}return{source:null,line:null,column:null,name:null}};BasicSourceMapConsumer.prototype.sourceContentFor=function SourceMapConsumer_sourceContentFor(aSource,nullOnMissing){if(!this.sourcesContent){return null}if(this.sourceRoot!=null){aSource=util.relative(this.sourceRoot,aSource)}if(this._sources.has(aSource)){return this.sourcesContent[this._sources.indexOf(aSource)]}var url;if(this.sourceRoot!=null&&(url=util.urlParse(this.sourceRoot))){var fileUriAbsPath=aSource.replace(/^file:\/\//,"");if(url.scheme=="file"&&this._sources.has(fileUriAbsPath)){return this.sourcesContent[this._sources.indexOf(fileUriAbsPath)]}if((!url.path||url.path=="/")&&this._sources.has("/"+aSource)){return this.sourcesContent[this._sources.indexOf("/"+aSource)]}}if(nullOnMissing){return null}else{throw new Error('"'+aSource+'" is not in the SourceMap.')}};BasicSourceMapConsumer.prototype.generatedPositionFor=function SourceMapConsumer_generatedPositionFor(aArgs){var needle={source:util.getArg(aArgs,"source"),originalLine:util.getArg(aArgs,"line"),originalColumn:util.getArg(aArgs,"column")};if(this.sourceRoot!=null){needle.source=util.relative(this.sourceRoot,needle.source)}var index=this._findMapping(needle,this._originalMappings,"originalLine","originalColumn",util.compareByOriginalPositions,util.getArg(aArgs,"bias",SourceMapConsumer.GREATEST_LOWER_BOUND));if(index>=0){var mapping=this._originalMappings[index];return{line:util.getArg(mapping,"generatedLine",null),column:util.getArg(mapping,"generatedColumn",null),lastColumn:util.getArg(mapping,"lastGeneratedColumn",null)}}return{line:null,column:null,lastColumn:null}};exports.BasicSourceMapConsumer=BasicSourceMapConsumer;function IndexedSourceMapConsumer(aSourceMap){var sourceMap=aSourceMap;if(typeof aSourceMap==="string"){sourceMap=JSON.parse(aSourceMap.replace(/^\)\]\}'/,""))}var version=util.getArg(sourceMap,"version");var sections=util.getArg(sourceMap,"sections");if(version!=this._version){throw new Error("Unsupported version: "+version)}var lastOffset={line:-1,column:0};this._sections=sections.map(function(s){if(s.url){throw new Error("Support for url field in sections not implemented.")}var offset=util.getArg(s,"offset");var offsetLine=util.getArg(offset,"line");var offsetColumn=util.getArg(offset,"column");if(offsetLine<lastOffset.line||offsetLine===lastOffset.line&&offsetColumn<lastOffset.column){throw new Error("Section offsets must be ordered and non-overlapping.")}lastOffset=offset;return{generatedOffset:{generatedLine:offsetLine+1,generatedColumn:offsetColumn+1},consumer:new SourceMapConsumer(util.getArg(s,"map"))}})}IndexedSourceMapConsumer.prototype=Object.create(SourceMapConsumer.prototype);IndexedSourceMapConsumer.prototype.constructor=SourceMapConsumer;IndexedSourceMapConsumer.prototype._version=3;Object.defineProperty(IndexedSourceMapConsumer.prototype,"sources",{get:function(){var sources=[];for(var i=0;i<this._sections.length;i++){for(var j=0;j<this._sections[i].consumer.sources.length;j++){sources.push(this._sections[i].consumer.sources[j])}}return sources}});IndexedSourceMapConsumer.prototype.originalPositionFor=function IndexedSourceMapConsumer_originalPositionFor(aArgs){var needle={generatedLine:util.getArg(aArgs,"line"),generatedColumn:util.getArg(aArgs,"column")};var sectionIndex=binarySearch.search(needle,this._sections,function(needle,section){var cmp=needle.generatedLine-section.generatedOffset.generatedLine;if(cmp){return cmp}return needle.generatedColumn-section.generatedOffset.generatedColumn});var section=this._sections[sectionIndex];if(!section){return{source:null,line:null,column:null,name:null}}return section.consumer.originalPositionFor({line:needle.generatedLine-(section.generatedOffset.generatedLine-1),column:needle.generatedColumn-(section.generatedOffset.generatedLine===needle.generatedLine?section.generatedOffset.generatedColumn-1:0),bias:aArgs.bias})};IndexedSourceMapConsumer.prototype.sourceContentFor=function IndexedSourceMapConsumer_sourceContentFor(aSource,nullOnMissing){for(var i=0;i<this._sections.length;i++){var section=this._sections[i];var content=section.consumer.sourceContentFor(aSource,true);if(content){return content}}if(nullOnMissing){return null}else{throw new Error('"'+aSource+'" is not in the SourceMap.')}};IndexedSourceMapConsumer.prototype.generatedPositionFor=function IndexedSourceMapConsumer_generatedPositionFor(aArgs){for(var i=0;i<this._sections.length;i++){var section=this._sections[i];if(section.consumer.sources.indexOf(util.getArg(aArgs,"source"))===-1){continue}var generatedPosition=section.consumer.generatedPositionFor(aArgs);if(generatedPosition){var ret={line:generatedPosition.line+(section.generatedOffset.generatedLine-1),column:generatedPosition.column+(section.generatedOffset.generatedLine===generatedPosition.line?section.generatedOffset.generatedColumn-1:0)};return ret}}return{line:null,column:null}};IndexedSourceMapConsumer.prototype._parseMappings=function IndexedSourceMapConsumer_parseMappings(aStr,aSourceRoot){this.__generatedMappings=[];this.__originalMappings=[];for(var i=0;i<this._sections.length;i++){var section=this._sections[i];var sectionMappings=section.consumer._generatedMappings;for(var j=0;j<sectionMappings.length;j++){var mapping=sectionMappings[i];var source=mapping.source;var sourceRoot=section.consumer.sourceRoot;if(source!=null&&sourceRoot!=null){source=util.join(sourceRoot,source)}var adjustedMapping={source:source,generatedLine:mapping.generatedLine+(section.generatedOffset.generatedLine-1),generatedColumn:mapping.column+(section.generatedOffset.generatedLine===mapping.generatedLine)?section.generatedOffset.generatedColumn-1:0,originalLine:mapping.originalLine,originalColumn:mapping.originalColumn,name:mapping.name};this.__generatedMappings.push(adjustedMapping);if(typeof adjustedMapping.originalLine==="number"){this.__originalMappings.push(adjustedMapping)}}}this.__generatedMappings.sort(util.compareByGeneratedPositions);this.__originalMappings.sort(util.compareByOriginalPositions)};exports.IndexedSourceMapConsumer=IndexedSourceMapConsumer})},{"./array-set":331,"./base64-vlq":332,"./binary-search":334,"./util":339,amdefine:340}],337:[function(require,module,exports){if(typeof define!=="function"){var define=require("amdefine")(module,require)}define(function(require,exports,module){var base64VLQ=require("./base64-vlq");var util=require("./util");var ArraySet=require("./array-set").ArraySet;var MappingList=require("./mapping-list").MappingList;function SourceMapGenerator(aArgs){if(!aArgs){aArgs={}}this._file=util.getArg(aArgs,"file",null);this._sourceRoot=util.getArg(aArgs,"sourceRoot",null);this._skipValidation=util.getArg(aArgs,"skipValidation",false);this._sources=new ArraySet;this._names=new ArraySet;this._mappings=new MappingList;this._sourcesContents=null}SourceMapGenerator.prototype._version=3;SourceMapGenerator.fromSourceMap=function SourceMapGenerator_fromSourceMap(aSourceMapConsumer){var sourceRoot=aSourceMapConsumer.sourceRoot;var generator=new SourceMapGenerator({file:aSourceMapConsumer.file,sourceRoot:sourceRoot});aSourceMapConsumer.eachMapping(function(mapping){var newMapping={generated:{line:mapping.generatedLine,column:mapping.generatedColumn}};if(mapping.source!=null){newMapping.source=mapping.source;if(sourceRoot!=null){newMapping.source=util.relative(sourceRoot,newMapping.source)}newMapping.original={line:mapping.originalLine,column:mapping.originalColumn};if(mapping.name!=null){newMapping.name=mapping.name}}generator.addMapping(newMapping)});aSourceMapConsumer.sources.forEach(function(sourceFile){var content=aSourceMapConsumer.sourceContentFor(sourceFile);if(content!=null){generator.setSourceContent(sourceFile,content)}});return generator};SourceMapGenerator.prototype.addMapping=function SourceMapGenerator_addMapping(aArgs){var generated=util.getArg(aArgs,"generated");var original=util.getArg(aArgs,"original",null);var source=util.getArg(aArgs,"source",null);var name=util.getArg(aArgs,"name",null);if(!this._skipValidation){this._validateMapping(generated,original,source,name)}if(source!=null&&!this._sources.has(source)){this._sources.add(source)}if(name!=null&&!this._names.has(name)){this._names.add(name)}this._mappings.add({generatedLine:generated.line,generatedColumn:generated.column,originalLine:original!=null&&original.line,originalColumn:original!=null&&original.column,source:source,name:name})};SourceMapGenerator.prototype.setSourceContent=function SourceMapGenerator_setSourceContent(aSourceFile,aSourceContent){var source=aSourceFile;if(this._sourceRoot!=null){source=util.relative(this._sourceRoot,source)}if(aSourceContent!=null){if(!this._sourcesContents){this._sourcesContents={}}this._sourcesContents[util.toSetString(source)]=aSourceContent}else if(this._sourcesContents){delete this._sourcesContents[util.toSetString(source)];if(Object.keys(this._sourcesContents).length===0){this._sourcesContents=null}}};SourceMapGenerator.prototype.applySourceMap=function SourceMapGenerator_applySourceMap(aSourceMapConsumer,aSourceFile,aSourceMapPath){var sourceFile=aSourceFile;if(aSourceFile==null){if(aSourceMapConsumer.file==null){throw new Error("SourceMapGenerator.prototype.applySourceMap requires either an explicit source file, "+'or the source map\'s "file" property. Both were omitted.')}sourceFile=aSourceMapConsumer.file}var sourceRoot=this._sourceRoot;if(sourceRoot!=null){sourceFile=util.relative(sourceRoot,sourceFile)}var newSources=new ArraySet;var newNames=new ArraySet;this._mappings.unsortedForEach(function(mapping){if(mapping.source===sourceFile&&mapping.originalLine!=null){var original=aSourceMapConsumer.originalPositionFor({line:mapping.originalLine,column:mapping.originalColumn});if(original.source!=null){mapping.source=original.source;if(aSourceMapPath!=null){mapping.source=util.join(aSourceMapPath,mapping.source)}if(sourceRoot!=null){mapping.source=util.relative(sourceRoot,mapping.source)}mapping.originalLine=original.line;mapping.originalColumn=original.column;if(original.name!=null){mapping.name=original.name}}}var source=mapping.source;if(source!=null&&!newSources.has(source)){newSources.add(source)}var name=mapping.name;if(name!=null&&!newNames.has(name)){newNames.add(name)}},this);this._sources=newSources;this._names=newNames;aSourceMapConsumer.sources.forEach(function(sourceFile){var content=aSourceMapConsumer.sourceContentFor(sourceFile);if(content!=null){if(aSourceMapPath!=null){sourceFile=util.join(aSourceMapPath,sourceFile)}if(sourceRoot!=null){sourceFile=util.relative(sourceRoot,sourceFile)}this.setSourceContent(sourceFile,content)}},this)};SourceMapGenerator.prototype._validateMapping=function SourceMapGenerator_validateMapping(aGenerated,aOriginal,aSource,aName){if(aGenerated&&"line"in aGenerated&&"column"in aGenerated&&aGenerated.line>0&&aGenerated.column>=0&&!aOriginal&&!aSource&&!aName){return}else if(aGenerated&&"line"in aGenerated&&"column"in aGenerated&&aOriginal&&"line"in aOriginal&&"column"in aOriginal&&aGenerated.line>0&&aGenerated.column>=0&&aOriginal.line>0&&aOriginal.column>=0&&aSource){return}else{throw new Error("Invalid mapping: "+JSON.stringify({generated:aGenerated,source:aSource,original:aOriginal,name:aName}))}};SourceMapGenerator.prototype._serializeMappings=function SourceMapGenerator_serializeMappings(){var previousGeneratedColumn=0;var previousGeneratedLine=1;var previousOriginalColumn=0;var previousOriginalLine=0;var previousName=0;var previousSource=0;var result="";var mapping;var mappings=this._mappings.toArray();for(var i=0,len=mappings.length;i<len;i++){mapping=mappings[i];if(mapping.generatedLine!==previousGeneratedLine){previousGeneratedColumn=0;while(mapping.generatedLine!==previousGeneratedLine){result+=";";previousGeneratedLine++}}else{if(i>0){if(!util.compareByGeneratedPositions(mapping,mappings[i-1])){continue}result+=","}}result+=base64VLQ.encode(mapping.generatedColumn-previousGeneratedColumn);previousGeneratedColumn=mapping.generatedColumn;if(mapping.source!=null){result+=base64VLQ.encode(this._sources.indexOf(mapping.source)-previousSource);previousSource=this._sources.indexOf(mapping.source);result+=base64VLQ.encode(mapping.originalLine-1-previousOriginalLine);previousOriginalLine=mapping.originalLine-1;result+=base64VLQ.encode(mapping.originalColumn-previousOriginalColumn);previousOriginalColumn=mapping.originalColumn;if(mapping.name!=null){result+=base64VLQ.encode(this._names.indexOf(mapping.name)-previousName);previousName=this._names.indexOf(mapping.name)}}}return result};SourceMapGenerator.prototype._generateSourcesContent=function SourceMapGenerator_generateSourcesContent(aSources,aSourceRoot){return aSources.map(function(source){if(!this._sourcesContents){return null}if(aSourceRoot!=null){source=util.relative(aSourceRoot,source)}var key=util.toSetString(source);return Object.prototype.hasOwnProperty.call(this._sourcesContents,key)?this._sourcesContents[key]:null},this)};SourceMapGenerator.prototype.toJSON=function SourceMapGenerator_toJSON(){var map={version:this._version,sources:this._sources.toArray(),names:this._names.toArray(),mappings:this._serializeMappings()};if(this._file!=null){map.file=this._file}if(this._sourceRoot!=null){map.sourceRoot=this._sourceRoot}if(this._sourcesContents){map.sourcesContent=this._generateSourcesContent(map.sources,map.sourceRoot)}return map};SourceMapGenerator.prototype.toString=function SourceMapGenerator_toString(){return JSON.stringify(this.toJSON())};exports.SourceMapGenerator=SourceMapGenerator})},{"./array-set":331,"./base64-vlq":332,"./mapping-list":335,"./util":339,amdefine:340}],338:[function(require,module,exports){if(typeof define!=="function"){var define=require("amdefine")(module,require)}define(function(require,exports,module){var SourceMapGenerator=require("./source-map-generator").SourceMapGenerator;var util=require("./util");var REGEX_NEWLINE=/(\r?\n)/;var NEWLINE_CODE=10;var isSourceNode="$$$isSourceNode$$$";function SourceNode(aLine,aColumn,aSource,aChunks,aName){this.children=[];this.sourceContents={};this.line=aLine==null?null:aLine;this.column=aColumn==null?null:aColumn;this.source=aSource==null?null:aSource;this.name=aName==null?null:aName;this[isSourceNode]=true;if(aChunks!=null)this.add(aChunks)}SourceNode.fromStringWithSourceMap=function SourceNode_fromStringWithSourceMap(aGeneratedCode,aSourceMapConsumer,aRelativePath){var node=new SourceNode;var remainingLines=aGeneratedCode.split(REGEX_NEWLINE);var shiftNextLine=function(){var lineContents=remainingLines.shift();var newLine=remainingLines.shift()||"";return lineContents+newLine};var lastGeneratedLine=1,lastGeneratedColumn=0;var lastMapping=null;aSourceMapConsumer.eachMapping(function(mapping){if(lastMapping!==null){if(lastGeneratedLine<mapping.generatedLine){var code="";addMappingWithCode(lastMapping,shiftNextLine());lastGeneratedLine++;lastGeneratedColumn=0}else{var nextLine=remainingLines[0];var code=nextLine.substr(0,mapping.generatedColumn-lastGeneratedColumn);remainingLines[0]=nextLine.substr(mapping.generatedColumn-lastGeneratedColumn);lastGeneratedColumn=mapping.generatedColumn;addMappingWithCode(lastMapping,code);lastMapping=mapping;return}}while(lastGeneratedLine<mapping.generatedLine){node.add(shiftNextLine());lastGeneratedLine++}if(lastGeneratedColumn<mapping.generatedColumn){var nextLine=remainingLines[0];node.add(nextLine.substr(0,mapping.generatedColumn));remainingLines[0]=nextLine.substr(mapping.generatedColumn);lastGeneratedColumn=mapping.generatedColumn}lastMapping=mapping},this);if(remainingLines.length>0){if(lastMapping){addMappingWithCode(lastMapping,shiftNextLine())}node.add(remainingLines.join(""))}aSourceMapConsumer.sources.forEach(function(sourceFile){var content=aSourceMapConsumer.sourceContentFor(sourceFile);if(content!=null){if(aRelativePath!=null){sourceFile=util.join(aRelativePath,sourceFile)}node.setSourceContent(sourceFile,content)}});return node;function addMappingWithCode(mapping,code){if(mapping===null||mapping.source===undefined){node.add(code)}else{var source=aRelativePath?util.join(aRelativePath,mapping.source):mapping.source;node.add(new SourceNode(mapping.originalLine,mapping.originalColumn,source,code,mapping.name))}}};SourceNode.prototype.add=function SourceNode_add(aChunk){if(Array.isArray(aChunk)){aChunk.forEach(function(chunk){this.add(chunk)},this)}else if(aChunk[isSourceNode]||typeof aChunk==="string"){if(aChunk){this.children.push(aChunk)}}else{throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+aChunk)}return this};SourceNode.prototype.prepend=function SourceNode_prepend(aChunk){if(Array.isArray(aChunk)){for(var i=aChunk.length-1;i>=0;i--){this.prepend(aChunk[i])}}else if(aChunk[isSourceNode]||typeof aChunk==="string"){this.children.unshift(aChunk)}else{throw new TypeError("Expected a SourceNode, string, or an array of SourceNodes and strings. Got "+aChunk)}return this};SourceNode.prototype.walk=function SourceNode_walk(aFn){var chunk;for(var i=0,len=this.children.length;i<len;i++){chunk=this.children[i];if(chunk[isSourceNode]){chunk.walk(aFn)}else{if(chunk!==""){aFn(chunk,{source:this.source,line:this.line,column:this.column,name:this.name})}}}};SourceNode.prototype.join=function SourceNode_join(aSep){var newChildren;var i;var len=this.children.length;if(len>0){newChildren=[];for(i=0;i<len-1;i++){newChildren.push(this.children[i]);newChildren.push(aSep)}newChildren.push(this.children[i]);this.children=newChildren}return this};SourceNode.prototype.replaceRight=function SourceNode_replaceRight(aPattern,aReplacement){var lastChild=this.children[this.children.length-1];if(lastChild[isSourceNode]){lastChild.replaceRight(aPattern,aReplacement)}else if(typeof lastChild==="string"){this.children[this.children.length-1]=lastChild.replace(aPattern,aReplacement)}else{this.children.push("".replace(aPattern,aReplacement))}return this};SourceNode.prototype.setSourceContent=function SourceNode_setSourceContent(aSourceFile,aSourceContent){this.sourceContents[util.toSetString(aSourceFile)]=aSourceContent};SourceNode.prototype.walkSourceContents=function SourceNode_walkSourceContents(aFn){for(var i=0,len=this.children.length;i<len;i++){if(this.children[i][isSourceNode]){this.children[i].walkSourceContents(aFn)}}var sources=Object.keys(this.sourceContents);for(var i=0,len=sources.length;i<len;i++){aFn(util.fromSetString(sources[i]),this.sourceContents[sources[i]])}};SourceNode.prototype.toString=function SourceNode_toString(){var str="";this.walk(function(chunk){str+=chunk});return str};SourceNode.prototype.toStringWithSourceMap=function SourceNode_toStringWithSourceMap(aArgs){var generated={code:"",line:1,column:0};var map=new SourceMapGenerator(aArgs);var sourceMappingActive=false;var lastOriginalSource=null;var lastOriginalLine=null;var lastOriginalColumn=null;var lastOriginalName=null;this.walk(function(chunk,original){generated.code+=chunk;if(original.source!==null&&original.line!==null&&original.column!==null){if(lastOriginalSource!==original.source||lastOriginalLine!==original.line||lastOriginalColumn!==original.column||lastOriginalName!==original.name){map.addMapping({source:original.source,original:{line:original.line,column:original.column},generated:{line:generated.line,column:generated.column},name:original.name})}lastOriginalSource=original.source;lastOriginalLine=original.line;lastOriginalColumn=original.column;lastOriginalName=original.name;sourceMappingActive=true}else if(sourceMappingActive){map.addMapping({generated:{line:generated.line,column:generated.column}});lastOriginalSource=null;sourceMappingActive=false}for(var idx=0,length=chunk.length;idx<length;idx++){if(chunk.charCodeAt(idx)===NEWLINE_CODE){generated.line++;generated.column=0;if(idx+1===length){lastOriginalSource=null;sourceMappingActive=false}else if(sourceMappingActive){map.addMapping({source:original.source,original:{line:original.line,column:original.column},generated:{line:generated.line,column:generated.column},name:original.name})}}else{generated.column++}}});this.walkSourceContents(function(sourceFile,sourceContent){map.setSourceContent(sourceFile,sourceContent)});return{code:generated.code,map:map}};exports.SourceNode=SourceNode})},{"./source-map-generator":337,"./util":339,amdefine:340}],339:[function(require,module,exports){if(typeof define!=="function"){var define=require("amdefine")(module,require)}define(function(require,exports,module){function getArg(aArgs,aName,aDefaultValue){if(aName in aArgs){return aArgs[aName]}else if(arguments.length===3){return aDefaultValue}else{throw new Error('"'+aName+'" is a required argument.')}}exports.getArg=getArg;var urlRegexp=/^(?:([\w+\-.]+):)?\/\/(?:(\w+:\w+)@)?([\w.]*)(?::(\d+))?(\S*)$/;var dataUrlRegexp=/^data:.+\,.+$/;function urlParse(aUrl){var match=aUrl.match(urlRegexp);if(!match){return null}return{scheme:match[1],auth:match[2],host:match[3],port:match[4],path:match[5]}}exports.urlParse=urlParse;function urlGenerate(aParsedUrl){var url="";if(aParsedUrl.scheme){url+=aParsedUrl.scheme+":"}url+="//";if(aParsedUrl.auth){url+=aParsedUrl.auth+"@"}if(aParsedUrl.host){url+=aParsedUrl.host}if(aParsedUrl.port){url+=":"+aParsedUrl.port}if(aParsedUrl.path){url+=aParsedUrl.path}return url}exports.urlGenerate=urlGenerate;function normalize(aPath){var path=aPath;var url=urlParse(aPath);if(url){if(!url.path){return aPath}path=url.path}var isAbsolute=path.charAt(0)==="/";var parts=path.split(/\/+/);for(var part,up=0,i=parts.length-1;i>=0;i--){part=parts[i];if(part==="."){parts.splice(i,1)}else if(part===".."){up++}else if(up>0){if(part===""){parts.splice(i+1,up);up=0}else{parts.splice(i,2);up--}}}path=parts.join("/");if(path===""){path=isAbsolute?"/":"."}if(url){url.path=path;return urlGenerate(url)}return path}exports.normalize=normalize;function join(aRoot,aPath){if(aRoot===""){aRoot="."}if(aPath===""){aPath="."}var aPathUrl=urlParse(aPath);var aRootUrl=urlParse(aRoot);if(aRootUrl){aRoot=aRootUrl.path||"/"}if(aPathUrl&&!aPathUrl.scheme){if(aRootUrl){aPathUrl.scheme=aRootUrl.scheme}return urlGenerate(aPathUrl)}if(aPathUrl||aPath.match(dataUrlRegexp)){return aPath}if(aRootUrl&&!aRootUrl.host&&!aRootUrl.path){aRootUrl.host=aPath;return urlGenerate(aRootUrl)}var joined=aPath.charAt(0)==="/"?aPath:normalize(aRoot.replace(/\/+$/,"")+"/"+aPath);if(aRootUrl){aRootUrl.path=joined;return urlGenerate(aRootUrl)}return joined}exports.join=join;function relative(aRoot,aPath){if(aRoot===""){aRoot="."}aRoot=aRoot.replace(/\/$/,"");var url=urlParse(aRoot);if(aPath.charAt(0)=="/"&&url&&url.path=="/"){return aPath.slice(1)}return aPath.indexOf(aRoot+"/")===0?aPath.substr(aRoot.length+1):aPath}exports.relative=relative;function toSetString(aStr){return"$"+aStr}exports.toSetString=toSetString;function fromSetString(aStr){return aStr.substr(1)}exports.fromSetString=fromSetString;function strcmp(aStr1,aStr2){var s1=aStr1||"";var s2=aStr2||"";return(s1>s2)-(s1<s2)}function compareByOriginalPositions(mappingA,mappingB,onlyCompareOriginal){var cmp;cmp=strcmp(mappingA.source,mappingB.source);if(cmp){return cmp}cmp=mappingA.originalLine-mappingB.originalLine;if(cmp){return cmp}cmp=mappingA.originalColumn-mappingB.originalColumn;if(cmp||onlyCompareOriginal){return cmp}cmp=strcmp(mappingA.name,mappingB.name);if(cmp){return cmp}cmp=mappingA.generatedLine-mappingB.generatedLine;if(cmp){return cmp}return mappingA.generatedColumn-mappingB.generatedColumn}exports.compareByOriginalPositions=compareByOriginalPositions;function compareByGeneratedPositions(mappingA,mappingB,onlyCompareGenerated){var cmp;cmp=mappingA.generatedLine-mappingB.generatedLine;if(cmp){return cmp}cmp=mappingA.generatedColumn-mappingB.generatedColumn;if(cmp||onlyCompareGenerated){return cmp}cmp=strcmp(mappingA.source,mappingB.source);if(cmp){return cmp}cmp=mappingA.originalLine-mappingB.originalLine;if(cmp){return cmp}cmp=mappingA.originalColumn-mappingB.originalColumn;if(cmp){return cmp}return strcmp(mappingA.name,mappingB.name)}exports.compareByGeneratedPositions=compareByGeneratedPositions})},{amdefine:340}],340:[function(require,module,exports){(function(process,__filename){"use strict";function amdefine(module,requireFn){"use strict";var defineCache={},loaderCache={},alreadyCalled=false,path=require("path"),makeRequire,stringRequire;function trimDots(ary){var i,part;for(i=0;ary[i];i+=1){part=ary[i];if(part==="."){ary.splice(i,1);i-=1}else if(part===".."){if(i===1&&(ary[2]===".."||ary[0]==="..")){break}else if(i>0){ary.splice(i-1,2);i-=2}}}}function normalize(name,baseName){var baseParts;if(name&&name.charAt(0)==="."){if(baseName){baseParts=baseName.split("/");baseParts=baseParts.slice(0,baseParts.length-1);baseParts=baseParts.concat(name.split("/"));trimDots(baseParts);name=baseParts.join("/")}}return name}function makeNormalize(relName){return function(name){return normalize(name,relName)}}function makeLoad(id){function load(value){loaderCache[id]=value}load.fromText=function(id,text){throw new Error("amdefine does not implement load.fromText")};return load}makeRequire=function(systemRequire,exports,module,relId){function amdRequire(deps,callback){if(typeof deps==="string"){return stringRequire(systemRequire,exports,module,deps,relId)}else{deps=deps.map(function(depName){return stringRequire(systemRequire,exports,module,depName,relId)});process.nextTick(function(){callback.apply(null,deps)})}}amdRequire.toUrl=function(filePath){if(filePath.indexOf(".")===0){return normalize(filePath,path.dirname(module.filename))}else{return filePath}};return amdRequire};requireFn=requireFn||function req(){return module.require.apply(module,arguments)};function runFactory(id,deps,factory){var r,e,m,result;if(id){e=loaderCache[id]={};m={id:id,uri:__filename,exports:e};r=makeRequire(requireFn,e,m,id)}else{if(alreadyCalled){throw new Error("amdefine with no module ID cannot be called more than once per file.")}alreadyCalled=true;e=module.exports;m=module;r=makeRequire(requireFn,e,m,module.id)}if(deps){deps=deps.map(function(depName){return r(depName)})}if(typeof factory==="function"){result=factory.apply(m.exports,deps)}else{result=factory}if(result!==undefined){m.exports=result;if(id){loaderCache[id]=m.exports}}}stringRequire=function(systemRequire,exports,module,id,relId){var index=id.indexOf("!"),originalId=id,prefix,plugin;if(index===-1){id=normalize(id,relId);if(id==="require"){return makeRequire(systemRequire,exports,module,relId)}else if(id==="exports"){return exports}else if(id==="module"){return module}else if(loaderCache.hasOwnProperty(id)){return loaderCache[id]}else if(defineCache[id]){runFactory.apply(null,defineCache[id]);return loaderCache[id]}else{if(systemRequire){return systemRequire(originalId)}else{throw new Error("No module with ID: "+id)}}}else{prefix=id.substring(0,index);id=id.substring(index+1,id.length);plugin=stringRequire(systemRequire,exports,module,prefix,relId);if(plugin.normalize){id=plugin.normalize(id,makeNormalize(relId))}else{id=normalize(id,relId)}if(loaderCache[id]){return loaderCache[id]}else{plugin.load(id,makeRequire(systemRequire,exports,module,relId),makeLoad(id),{});return loaderCache[id]}}};function define(id,deps,factory){if(Array.isArray(id)){factory=deps;deps=id;id=undefined}else if(typeof id!=="string"){factory=id;id=deps=undefined}if(deps&&!Array.isArray(deps)){factory=deps;deps=undefined}if(!deps){deps=["require","exports","module"]}if(id){defineCache[id]=[id,deps,factory]}else{runFactory(id,deps,factory)}}define.require=function(id){if(loaderCache[id]){return loaderCache[id]}if(defineCache[id]){runFactory.apply(null,defineCache[id]);return loaderCache[id]}};define.amd={};return define}module.exports=amdefine}).call(this,require("_process"),"/node_modules/source-map/node_modules/amdefine/amdefine.js")},{_process:151,path:150}],341:[function(require,module,exports){"use strict";module.exports=function(str){return str.replace(/[\s\uFEFF\xA0]+$/g,"")}},{}],342:[function(require,module,exports){module.exports={name:"babel",description:"Turn ES6 code into readable vanilla ES5 with source maps",version:"4.6.1",author:"Sebastian McKenzie <[email protected]>",homepage:"https://babeljs.io/",repository:"babel/babel",preferGlobal:true,main:"lib/babel/api/node.js",browser:{"./lib/babel/api/register/node.js":"./lib/babel/api/register/browser.js"},bin:{"6to5":"./bin/deprecated/6to5","6to5-node":"./bin/deprecated/6to5-node","6to5-runtime":"./bin/deprecated/6to5-runtime",babel:"./bin/babel/index.js","babel-node":"./bin/babel-node","babel-external-helpers":"./bin/babel-external-helpers"},keywords:["harmony","classes","modules","let","const","var","es6","transpile","transpiler","6to5","babel"],scripts:{bench:"make bench",test:"make test"},dependencies:{"acorn-babel":"0.11.1-35","ast-types":"~0.6.1",chalk:"^1.0.0",chokidar:"^0.12.6",commander:"^2.6.0","core-js":"^0.6.1",debug:"^2.1.1","detect-indent":"^3.0.0",estraverse:"^1.9.1",esutils:"^1.1.6","fs-readdir-recursive":"^0.1.0",globals:"^6.2.0","is-integer":"^1.0.4","js-tokens":"1.0.0",leven:"^1.0.1","line-numbers":"0.2.0",lodash:"^3.2.0","output-file-sync":"^1.1.0","path-is-absolute":"^1.0.0","private":"^0.1.6","regenerator-babel":"0.8.13-1",regexpu:"^1.1.1",repeating:"^1.1.2","shebang-regex":"^1.0.0",slash:"^1.0.0","source-map":"^0.4.0","source-map-support":"^0.2.9","source-map-to-comment":"^1.0.0","trim-right":"^1.0.0"},devDependencies:{babel:"4.6.0",browserify:"^9.0.3",chai:"^2.0.0",eslint:"^0.15.1","babel-eslint":"^1.0.1",esvalid:"^1.1.0",istanbul:"^0.3.5",matcha:"^0.6.0",mocha:"^2.1.0",rimraf:"^2.2.8","uglify-js":"^2.4.16"}} },{}],343:[function(require,module,exports){module.exports={"abstract-expression-call":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"PROPERTY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Symbol",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"referenceGet",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"OBJECT",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"call",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"OBJECT",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"abstract-expression-delete":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"PROPERTY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Symbol",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"referenceDelete",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"OBJECT",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"abstract-expression-get":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"PROPERTY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Symbol",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"referenceGet",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"OBJECT",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"abstract-expression-set":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"PROPERTY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Symbol",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"referenceSet",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"OBJECT",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"VALUE",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"apply-constructor":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Constructor",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"args",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"instance",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"create",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Constructor",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"prototype",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"result",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Constructor",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"apply",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"instance",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"args",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"ConditionalExpression",start:null,end:null,loc:null,range:null,test:{type:"LogicalExpression",start:null,end:null,loc:null,range:null,left:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"result",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"!=",right:{type:"Literal",start:null,end:null,loc:null,range:null,value:null,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"&&",right:{type:"LogicalExpression",start:null,end:null,loc:null,range:null,left:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"UnaryExpression",start:null,end:null,loc:null,range:null,operator:"typeof",prefix:true,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"result",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"==",right:{type:"Literal",start:null,end:null,loc:null,range:null,value:"object",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"||",right:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"UnaryExpression",start:null,end:null,loc:null,range:null,operator:"typeof",prefix:true,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"result",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"==",right:{type:"Literal",start:null,end:null,loc:null,range:null,value:"function",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"result",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},alternate:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"instance",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"array-comprehension-container":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"ArrayExpression",start:null,end:null,loc:null,range:null,elements:[],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},arguments:[],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"array-from":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Array",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"from",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"VALUE",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"array-push":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"push",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"STATEMENT",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"async-to-generator":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"fn",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"gen",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"fn",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"apply",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"ThisExpression",start:null,end:null,loc:null,range:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arguments",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"NewExpression",start:null,end:null,loc:null,range:null,callee:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Promise",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"resolve",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"reject",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"callNext",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"step",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"bind",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Literal",start:null,end:null,loc:null,range:null,value:null,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},{type:"Literal",start:null,end:null,loc:null,range:null,value:"next",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"callThrow",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"step",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"bind",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Literal",start:null,end:null,loc:null,range:null,value:null,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},{type:"Literal",start:null,end:null,loc:null,range:null,value:"throw",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"FunctionDeclaration",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"step",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"key",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arg",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"TryStatement",start:null,end:null,loc:null,range:null,block:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"info",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"gen",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"key",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arg",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"info",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},handler:{type:"CatchClause",start:null,end:null,loc:null,range:null,param:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"error",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},guard:null,body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"reject",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"error",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},guardedHandlers:[],finalizer:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"info",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"done",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"resolve",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Promise",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"resolve",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"then",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"callNext",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"callThrow",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"callNext",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},bind:{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Function",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"prototype",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"bind",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},call:{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"OBJECT",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"call",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"CONTEXT",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"class-call-check":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"instance",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Constructor",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"UnaryExpression",start:null,end:null,loc:null,range:null,operator:"!",prefix:true,argument:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"instance",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"instanceof",right:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Constructor",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ThrowStatement",start:null,end:null,loc:null,range:null,argument:{type:"NewExpression",start:null,end:null,loc:null,range:null,callee:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"TypeError",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Literal",start:null,end:null,loc:null,range:null,value:"Cannot call a class as a function",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"class-super-constructor-call-loose":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"SUPER_NAME",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"!=",right:{type:"Literal",start:null,end:null,loc:null,range:null,value:null,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"SUPER_NAME",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"apply",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"ThisExpression",start:null,end:null,loc:null,range:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arguments",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"class-super-constructor-call":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"SUPER_NAME",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"!=",right:{type:"Literal",start:null,end:null,loc:null,range:null,value:null,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"SUPER_NAME",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"apply",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"ThisExpression",start:null,end:null,loc:null,range:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arguments",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"corejs-is-iterator":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"CORE_ID",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"$for",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"isIterable",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"VALUE",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"corejs-iterator":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"CORE_ID",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"$for",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"getIterator",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"VALUE",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"default-parameter":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"VARIABLE_NAME",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"ConditionalExpression",start:null,end:null,loc:null,range:null,test:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ARGUMENTS",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ARGUMENT_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"===",right:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"undefined",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"DEFAULT_VALUE",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},alternate:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ARGUMENTS",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ARGUMENT_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"let",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},defaults:{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"defaults",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"keys",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"getOwnPropertyNames",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"defaults",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ForStatement",start:null,end:null,loc:null,range:null,init:{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"i",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"Literal",start:null,end:null,loc:null,range:null,value:0,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},test:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"i",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"<",right:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"keys",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"length",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},update:{type:"UpdateExpression",start:null,end:null,loc:null,range:null,operator:"++",prefix:false,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"i",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"key",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"keys",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"i",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"getOwnPropertyDescriptor",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"defaults",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"key",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"LogicalExpression",start:null,end:null,loc:null,range:null,left:{type:"LogicalExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"&&",right:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"configurable",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"&&",right:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"key",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"===",right:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"undefined",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"defineProperty",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"key",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"define-property":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"key",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"defineProperty",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"key",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ObjectExpression",start:null,end:null,loc:null,range:null,properties:[{type:"Property",start:null,end:null,loc:null,range:null,method:false,shorthand:false,computed:false,key:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},value:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},kind:"init",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Property",start:null,end:null,loc:null,range:null,method:false,shorthand:false,computed:false,key:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"enumerable",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},value:{type:"Literal",start:null,end:null,loc:null,range:null,value:true,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},kind:"init",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Property",start:null,end:null,loc:null,range:null,method:false,shorthand:false,computed:false,key:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"configurable",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},value:{type:"Literal",start:null,end:null,loc:null,range:null,value:true,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},kind:"init",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Property",start:null,end:null,loc:null,range:null,method:false,shorthand:false,computed:false,key:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"writable",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},value:{type:"Literal",start:null,end:null,loc:null,range:null,value:true,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},kind:"init",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"exports-assign":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"exports",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"VALUE",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"exports-default-assign":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"module",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"exports",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"VALUE",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"exports-module-declaration-loose":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"exports",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"__esModule",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"Literal",start:null,end:null,loc:null,range:null,value:true,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"exports-module-declaration":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"defineProperty",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"exports",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Literal",start:null,end:null,loc:null,range:null,value:"__esModule",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},{type:"ObjectExpression",start:null,end:null,loc:null,range:null,properties:[{type:"Property",start:null,end:null,loc:null,range:null,method:false,shorthand:false,computed:false,key:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},value:{type:"Literal",start:null,end:null,loc:null,range:null,value:true,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},kind:"init",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"extends":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"LogicalExpression",start:null,end:null,loc:null,range:null,left:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"assign",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"||",right:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"target",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ForStatement",start:null,end:null,loc:null,range:null,init:{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"i",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"Literal",start:null,end:null,loc:null,range:null,value:1,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},test:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"i",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"<",right:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arguments",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"length",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},update:{type:"UpdateExpression",start:null,end:null,loc:null,range:null,operator:"++",prefix:false,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"i",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"source",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arguments",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"i",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ForInStatement",start:null,end:null,loc:null,range:null,left:{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"key",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"source",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"prototype",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"hasOwnProperty",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"call",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"source",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"key",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"target",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"key",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"source",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"key",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"target",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"for-of-loose":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ForStatement",start:null,end:null,loc:null,range:null,init:{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"LOOP_OBJECT",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"OBJECT",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"IS_ARRAY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Array",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"isArray",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"LOOP_OBJECT",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"INDEX",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"Literal",start:null,end:null,loc:null,range:null,value:0,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"LOOP_OBJECT",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"ConditionalExpression",start:null,end:null,loc:null,range:null,test:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"IS_ARRAY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"LOOP_OBJECT",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},alternate:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"LOOP_OBJECT",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Symbol",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"iterator",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},test:null,update:null,body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ID",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"IS_ARRAY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"INDEX",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:">=",right:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"LOOP_OBJECT",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"length",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BreakStatement",start:null,end:null,loc:null,range:null,label:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ID",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"LOOP_OBJECT",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"UpdateExpression",start:null,end:null,loc:null,range:null,operator:"++",prefix:false,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"INDEX",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"INDEX",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"LOOP_OBJECT",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"next",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"INDEX",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"done",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BreakStatement",start:null,end:null,loc:null,range:null,label:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ID",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"INDEX",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"for-of":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ITERATOR_COMPLETION",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"Literal",start:null,end:null,loc:null,range:null,value:true,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ITERATOR_HAD_ERROR_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"Literal",start:null,end:null,loc:null,range:null,value:false,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ITERATOR_ERROR_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"undefined",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"TryStatement",start:null,end:null,loc:null,range:null,block:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ForStatement",start:null,end:null,loc:null,range:null,init:{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ITERATOR_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"OBJECT",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Symbol",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"iterator",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"STEP_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},test:{type:"UnaryExpression",start:null,end:null,loc:null,range:null,operator:"!",prefix:true,argument:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ITERATOR_COMPLETION",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"STEP_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ITERATOR_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"next",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"done",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},update:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ITERATOR_COMPLETION",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"Literal",start:null,end:null,loc:null,range:null,value:true,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},handler:{type:"CatchClause",start:null,end:null,loc:null,range:null,param:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"err",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},guard:null,body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ITERATOR_HAD_ERROR_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"Literal",start:null,end:null,loc:null,range:null,value:true,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ITERATOR_ERROR_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"err",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},guardedHandlers:[],finalizer:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"TryStatement",start:null,end:null,loc:null,range:null,block:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"LogicalExpression",start:null,end:null,loc:null,range:null,left:{type:"UnaryExpression",start:null,end:null,loc:null,range:null,operator:"!",prefix:true,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ITERATOR_COMPLETION",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"&&",right:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ITERATOR_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Literal",start:null,end:null,loc:null,range:null,value:"return",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ITERATOR_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Literal",start:null,end:null,loc:null,range:null,value:"return",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},handler:null,guardedHandlers:[],finalizer:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ITERATOR_HAD_ERROR_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ThrowStatement",start:null,end:null,loc:null,range:null,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ITERATOR_ERROR_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},get:{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"get",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"property",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"receiver",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"desc",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"getOwnPropertyDescriptor",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"property",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"desc",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"===",right:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"undefined",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"parent",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"getPrototypeOf",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"parent",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"===",right:{type:"Literal",start:null,end:null,loc:null,range:null,value:null,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"undefined",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"get",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"parent",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"property",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"receiver",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"LogicalExpression",start:null,end:null,loc:null,range:null,left:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Literal",start:null,end:null,loc:null,range:null,value:"value",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},operator:"in",right:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"desc",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"&&",right:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"desc",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"writable",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"desc",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"getter",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"desc",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"get",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"getter",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"===",right:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"undefined",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"undefined",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"getter",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"call",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"receiver",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"has-own":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"prototype",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"hasOwnProperty",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},inherits:{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"subClass",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"superClass",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"LogicalExpression",start:null,end:null,loc:null,range:null,left:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"UnaryExpression",start:null,end:null,loc:null,range:null,operator:"typeof",prefix:true,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"superClass",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"!==",right:{type:"Literal",start:null,end:null,loc:null,range:null,value:"function",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"&&",right:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"superClass",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"!==",right:{type:"Literal",start:null,end:null,loc:null,range:null,value:null,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ThrowStatement",start:null,end:null,loc:null,range:null,argument:{type:"NewExpression",start:null,end:null,loc:null,range:null,callee:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"TypeError",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Literal",start:null,end:null,loc:null,range:null,value:"Super expression must either be null or a function, not ",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},operator:"+",right:{type:"UnaryExpression",start:null,end:null,loc:null,range:null,operator:"typeof",prefix:true,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"superClass",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"subClass",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"prototype",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"create",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"LogicalExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"superClass",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"&&",right:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"superClass",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"prototype",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ObjectExpression",start:null,end:null,loc:null,range:null,properties:[{type:"Property",start:null,end:null,loc:null,range:null,method:false,shorthand:false,computed:false,key:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"constructor",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},value:{type:"ObjectExpression",start:null,end:null,loc:null,range:null,properties:[{type:"Property",start:null,end:null,loc:null,range:null,method:false,shorthand:false,computed:false,key:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},value:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"subClass",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},kind:"init",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Property",start:null,end:null,loc:null,range:null,method:false,shorthand:false,computed:false,key:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"enumerable",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},value:{type:"Literal",start:null,end:null,loc:null,range:null,value:false,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},kind:"init",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Property",start:null,end:null,loc:null,range:null,method:false,shorthand:false,computed:false,key:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"writable",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},value:{type:"Literal",start:null,end:null,loc:null,range:null,value:true,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},kind:"init",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Property",start:null,end:null,loc:null,range:null,method:false,shorthand:false,computed:false,key:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"configurable",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},value:{type:"Literal",start:null,end:null,loc:null,range:null,value:true,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},kind:"init",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},kind:"init",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"superClass",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"subClass",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"__proto__",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"superClass",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"interop-require-wildcard":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"ConditionalExpression",start:null,end:null,loc:null,range:null,test:{type:"LogicalExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"&&",right:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"__esModule",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},alternate:{type:"ObjectExpression",start:null,end:null,loc:null,range:null,properties:[{type:"Property",start:null,end:null,loc:null,range:null,method:false,shorthand:false,computed:false,key:{type:"Literal",start:null,end:null,loc:null,range:null,value:"default",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},value:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},kind:"init",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"interop-require":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"ConditionalExpression",start:null,end:null,loc:null,range:null,test:{type:"LogicalExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"&&",right:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"__esModule",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Literal",start:null,end:null,loc:null,range:null,value:"default",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},alternate:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"let-scoping-return":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"UnaryExpression",start:null,end:null,loc:null,range:null,operator:"typeof",prefix:true,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"RETURN",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"===",right:{type:"Literal",start:null,end:null,loc:null,range:null,value:"object",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"RETURN",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"v",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"named-function":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"FunctionDeclaration",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"GET_OUTER_ID",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},generator:false,expression:false,params:[],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"FUNCTION_ID",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"FUNCTION",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},arguments:[],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"object-destructuring-empty":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"==",right:{type:"Literal",start:null,end:null,loc:null,range:null,value:null,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"ThrowStatement",start:null,end:null,loc:null,range:null,argument:{type:"NewExpression",start:null,end:null,loc:null,range:null,callee:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"TypeError",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Literal",start:null,end:null,loc:null,range:null,value:"Cannot destructure undefined",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"object-without-properties":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"keys",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"target",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"ObjectExpression",start:null,end:null,loc:null,range:null,properties:[],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ForInStatement",start:null,end:null,loc:null,range:null,left:{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"i",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"keys",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"indexOf",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"i",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:">=",right:{type:"Literal",start:null,end:null,loc:null,range:null,value:0,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"ContinueStatement",start:null,end:null,loc:null,range:null,label:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"UnaryExpression",start:null,end:null,loc:null,range:null,operator:"!",prefix:true,argument:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"prototype",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"hasOwnProperty",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"call",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"i",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"ContinueStatement",start:null,end:null,loc:null,range:null,label:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"target",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"i",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"i",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"target",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"property-method-assignment-wrapper-generator":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"FUNCTION_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"WRAPPER_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"FUNCTION_ID",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},generator:true,expression:false,params:[],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"YieldExpression",start:null,end:null,loc:null,range:null,delegate:true,argument:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"FUNCTION_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"apply",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"ThisExpression",start:null,end:null,loc:null,range:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arguments",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"WRAPPER_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"toString",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"FUNCTION_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"toString",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"WRAPPER_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"FUNCTION",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"property-method-assignment-wrapper":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"FUNCTION_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"WRAPPER_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"FUNCTION_ID",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},generator:false,expression:false,params:[],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"FUNCTION_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"apply",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"ThisExpression",start:null,end:null,loc:null,range:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arguments",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"WRAPPER_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"toString",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"FUNCTION_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"toString",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"WRAPPER_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"FUNCTION",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"prototype-identifier":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"CLASS_NAME",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"prototype",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"prototype-properties":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"child",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"staticProps",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"instanceProps",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"staticProps",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"defineProperties",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"child",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"staticProps",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"instanceProps",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"defineProperties",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"child",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"prototype",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"instanceProps",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"require-assign-key":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"VARIABLE_NAME",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"require",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"MODULE_NAME",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},require:{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"require",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"MODULE_NAME",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},rest:{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ForStatement",start:null,end:null,loc:null,range:null,init:{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"LEN",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ARGUMENTS",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"length",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ARRAY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Array",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ARRAY_LEN",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"START",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},test:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"<",right:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"LEN",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},update:{type:"UpdateExpression",start:null,end:null,loc:null,range:null,operator:"++",prefix:false,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ARRAY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ARRAY_KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ARGUMENTS",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"KEY",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"self-contained-helpers-head":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"helpers",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"exports",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Literal",start:null,end:null,loc:null,range:null,value:"default",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"ObjectExpression",start:null,end:null,loc:null,range:null,properties:[],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"exports",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"__esModule",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"Literal",start:null,end:null,loc:null,range:null,value:true,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"self-global":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"ConditionalExpression",start:null,end:null,loc:null,range:null,test:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"UnaryExpression",start:null,end:null,loc:null,range:null,operator:"typeof",prefix:true,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"global",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"===",right:{type:"Literal",start:null,end:null,loc:null,range:null,value:"undefined",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"self",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},alternate:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"global",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},set:{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"set",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"property",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"receiver",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"desc",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"getOwnPropertyDescriptor",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"property",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"desc",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"===",right:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"undefined",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"parent",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"getPrototypeOf",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"parent",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"!==",right:{type:"Literal",start:null,end:null,loc:null,range:null,value:null,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"set",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"parent",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"property",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"receiver",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"LogicalExpression",start:null,end:null,loc:null,range:null,left:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Literal",start:null,end:null,loc:null,range:null,value:"value",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},operator:"in",right:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"desc",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"&&",right:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"desc",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"writable",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"desc",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"setter",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"desc",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"set",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"setter",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"!==",right:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"undefined",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"setter",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"call",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"receiver",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},slice:{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Array",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"prototype",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"slice",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"sliced-to-array":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arr",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"i",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Array",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"isArray",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arr",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arr",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Symbol",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"iterator",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"in",right:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arr",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"_arr",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"ArrayExpression",start:null,end:null,loc:null,range:null,elements:[],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ForStatement",start:null,end:null,loc:null,range:null,init:{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"_iterator",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arr",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Symbol",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"iterator",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"_step",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},test:{type:"UnaryExpression",start:null,end:null,loc:null,range:null,operator:"!",prefix:true,argument:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"_step",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"_iterator",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"next",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"done",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},update:null,body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"_arr",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"push",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"_step",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"LogicalExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"i",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"&&",right:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"_arr",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"length",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"===",right:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"i",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BreakStatement",start:null,end:null,loc:null,range:null,label:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"_arr",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ThrowStatement",start:null,end:null,loc:null,range:null,argument:{type:"NewExpression",start:null,end:null,loc:null,range:null,callee:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"TypeError",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Literal",start:null,end:null,loc:null,range:null,value:"Invalid attempt to destructure non-iterable instance",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},system:{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"System",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"register",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"MODULE_NAME",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"MODULE_DEPENDENCIES",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"EXPORT_IDENTIFIER",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"ObjectExpression",start:null,end:null,loc:null,range:null,properties:[{type:"Property",start:null,end:null,loc:null,range:null,method:false,shorthand:false,computed:false,key:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"setters",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},value:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"SETTERS",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},kind:"init",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Property",start:null,end:null,loc:null,range:null,method:false,shorthand:false,computed:false,key:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"execute",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},value:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"EXECUTE",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},kind:"init",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"tagged-template-literal-loose":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"strings",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"raw",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"strings",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"raw",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"raw",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"strings",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"tagged-template-literal":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"strings",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"raw",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"freeze",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"defineProperties",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"strings",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ObjectExpression",start:null,end:null,loc:null,range:null,properties:[{type:"Property",start:null,end:null,loc:null,range:null,method:false,shorthand:false,computed:false,key:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"raw",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},value:{type:"ObjectExpression",start:null,end:null,loc:null,range:null,properties:[{type:"Property",start:null,end:null,loc:null,range:null,method:false,shorthand:false,computed:false,key:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"value",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},value:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Object",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"freeze",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"raw",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},kind:"init",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},kind:"init",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"tail-call-body":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"AGAIN_ID",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"Literal",start:null,end:null,loc:null,range:null,value:true,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"LabeledStatement",start:null,end:null,loc:null,range:null,body:{type:"WhileStatement",start:null,end:null,loc:null,range:null,test:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"AGAIN_ID",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},body:{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"BLOCK",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},label:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"FUNCTION_ID",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"temporal-assert-defined":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"val",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"name",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"undef",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"val",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"===",right:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"undef",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ThrowStatement",start:null,end:null,loc:null,range:null,argument:{type:"NewExpression",start:null,end:null,loc:null,range:null,callee:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"ReferenceError",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"name",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"+",right:{type:"Literal",start:null,end:null,loc:null,range:null,value:" is not defined - temporal dead zone",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"Literal",start:null,end:null,loc:null,range:null,value:true,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"temporal-undefined":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"ObjectExpression",start:null,end:null,loc:null,range:null,properties:[],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"test-exports":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"UnaryExpression",start:null,end:null,loc:null,range:null,operator:"typeof",prefix:true,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"exports",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"!==",right:{type:"Literal",start:null,end:null,loc:null,range:null,value:"undefined",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"test-module":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"UnaryExpression",start:null,end:null,loc:null,range:null,operator:"typeof",prefix:true,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"module",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"!==",right:{type:"Literal",start:null,end:null,loc:null,range:null,value:"undefined",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"to-array":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arr",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"ConditionalExpression",start:null,end:null,loc:null,range:null,test:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Array",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"isArray",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arr",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arr",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},alternate:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Array",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"from",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arr",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"to-consumable-array":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arr",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Array",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"isArray",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arr",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ForStatement",start:null,end:null,loc:null,range:null,init:{type:"VariableDeclaration",start:null,end:null,loc:null,range:null,declarations:[{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"i",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"Literal",start:null,end:null,loc:null,range:null,value:0,raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"VariableDeclarator",start:null,end:null,loc:null,range:null,id:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arr2",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},init:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Array",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arr",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"length",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],kind:"var",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},test:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"i",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"<",right:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arr",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"length",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},update:{type:"UpdateExpression",start:null,end:null,loc:null,range:null,operator:"++",prefix:false,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"i",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},body:{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"AssignmentExpression",start:null,end:null,loc:null,range:null,operator:"=",left:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arr2",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"i",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},right:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arr",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"i",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:true,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arr2",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Array",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"from",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"arr",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"typeof":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ReturnStatement",start:null,end:null,loc:null,range:null,argument:{type:"ConditionalExpression",start:null,end:null,loc:null,range:null,test:{type:"LogicalExpression",start:null,end:null,loc:null,range:null,left:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"&&",right:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"constructor",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"===",right:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"Symbol",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"Literal",start:null,end:null,loc:null,range:null,value:"symbol",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},alternate:{type:"UnaryExpression",start:null,end:null,loc:null,range:null,operator:"typeof",prefix:true,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"obj",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},"umd-runner-body":{type:"Program",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"FunctionExpression",start:null,end:null,loc:null,range:null,id:null,generator:false,expression:false,params:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"factory",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],body:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"LogicalExpression",start:null,end:null,loc:null,range:null,left:{type:"BinaryExpression",start:null,end:null,loc:null,range:null,left:{type:"UnaryExpression",start:null,end:null,loc:null,range:null,operator:"typeof",prefix:true,argument:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"define",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"===",right:{type:"Literal",start:null,end:null,loc:null,range:null,value:"function",raw:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},operator:"&&",right:{type:"MemberExpression",start:null,end:null,loc:null,range:null,object:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"define",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},property:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"amd",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},computed:false,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"define",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"AMD_ARGUMENTS",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},{type:"Identifier",start:null,end:null,loc:null,range:null,name:"factory",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:{type:"IfStatement",start:null,end:null,loc:null,range:null,test:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"COMMON_TEST",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},consequent:{type:"BlockStatement",start:null,end:null,loc:null,range:null,body:[{type:"ExpressionStatement",start:null,end:null,loc:null,range:null,expression:{type:"CallExpression",start:null,end:null,loc:null,range:null,callee:{type:"Identifier",start:null,end:null,loc:null,range:null,name:"factory",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},arguments:[{type:"Identifier",start:null,end:null,loc:null,range:null,name:"COMMON_ARGUMENTS",_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},alternate:null,_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_scopeInfo:null,_declarations:null,extendedRange:null,tokens:null,raw:null},_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}],_declarations:null,extendedRange:null,_scopeInfo:null,tokens:null,raw:null}} },{}]},{},[1])(1)});
react/gameday2/components/NoWebcasts.js
jaredhasenklein/the-blue-alliance
import React from 'react' import RaisedButton from 'material-ui/RaisedButton' export default () => ( <div className="no-webcasts-container"> <h1>No webcasts found</h1> <p>Looks like there aren&apos;t any events with webcasts this week. Check on The Blue Alliance for upcoming events!</p> <RaisedButton href="https://www.thebluealliance.com" label="Go to The Blue Alliance" /> </div> )
app/react-icons/fa/xing.js
scampersand/sonos-front
import React from 'react'; import IconBase from 'react-icon-base'; export default class FaXing extends React.Component { render() { return ( <IconBase viewBox="0 0 40 40" {...this.props}> <g><path d="m17.8 14.9q-0.2 0.4-5.7 10.2-0.6 1-1.5 1h-5.3q-0.5 0-0.7-0.4t0-0.8l5.7-10q0 0 0 0l-3.6-6.2q-0.3-0.5-0.1-0.9 0.2-0.3 0.8-0.3h5.3q0.9 0 1.5 1z m18-14.3q0.3 0.3 0 0.8l-11.8 20.8v0.1l7.5 13.7q0.3 0.4 0.1 0.8-0.3 0.3-0.8 0.3h-5.3q-0.9 0-1.5-1l-7.5-13.8 11.8-21.1q0.6-1 1.4-1h5.4q0.5 0 0.7 0.4z"/></g> </IconBase> ); } }
src/components/FullCalendar.js
jacobmischka/ics-merger
import React, { Component } from 'react'; import PropTypes from 'prop-types'; import { render } from 'react-dom'; import Color from 'color'; import $ from 'jquery'; import 'fullcalendar'; import 'fullcalendar/dist/gcal.js'; import 'fullcalendar/dist/fullcalendar.css'; import uniqueId from 'lodash/uniqueId'; import CalendarEvent from './CalendarEvent.js'; import { BREAKPOINTS, COLORS, OPACITIES } from '../constants.js'; const fcButtonHoverBackgroundColor = new Color(COLORS.ACCENT).alpha(OPACITIES.SECONDARY); export default class FullCalendar extends Component { constructor(props){ super(props); this.state = { calendarId: uniqueId() }; this.createCalendar = this.createCalendar.bind(this); this.destroyCalendar = this.destroyCalendar.bind(this); this.getCalendarState = this.getCalendarState.bind(this); this.receiveMessage = this.receiveMessage.bind(this); } render() { return ( <div className="fullcalendar-container"> <div id={this.state.calendarId}></div> <style jsx global>{` h2 { font-size: 2em; font-weight: normal; } .event-container { background-color: ${COLORS.BACKGROUND}; overflow: hidden; } .fc .fc-toolbar { display: flex; justify-content: space-between; flex-wrap: wrap; } .fc .fc-toolbar .fc-left { order: 1; } .fc .fc-toolbar .fc-center { order: 2; } .fc .fc-toolbar .fc-right { order: 3; } .fc button { height: auto; } .fc .fc-button { font-size: 1.1em; padding: 0.5em; } .fc .fc-button.fc-state-default { background: transparent; text-shadow: none; box-shadow: none; border: 2px solid ${COLORS.ACCENT}; color: ${COLORS.ACCENT}; } .fc .fc-button.fc-state-active { color: white; background: ${COLORS.ACCENT}; } .fc .fc-button:hover, .fc .fc-button:focus { outline: none; color: white; background: ${fcButtonHoverBackgroundColor} } .fc .fc-button.fc-state-disabled { cursor: not-allowed; background: none; color: ${COLORS.ACCENT}; } .fc-clear { display: none; } .fc-list-view .fc-scroller { /* HACK: Workaround for https://github.com/fullcalendar/fullcalendar/issues/3346 */ height: auto !important; } .fc .fc-list-table .fc-list-heading, .fc .fc-list-table .fc-list-heading .fc-widget-header { width: 100%; } @media (max-width: ${BREAKPOINTS.SMALL_DESKTOP}px) { .fc .fc-toolbar { justify-content: space-around; } .fc .fc-toolbar .fc-left { text-align: center; width: 100%; } } @media print { h2 { font-size: 1.25em; } .fc .fc-body .fc-day-number { font-size: 0.75em; } .fc .fc-head-container.fc-widget-header, .fc .fc-list-table .fc-widget-header { font-size: 0.7em; } .fc .fc-list-table .fc-widget-header { padding: 0.2em 0.75em; } .fc .fc-toolbar .fc-center, .fc .fc-toolbar .fc-right { display: none; } .fc-today { background: none !important; } } `}</style> </div> ); } shouldComponentUpdate(nextProps){ const propsToChange = [ 'apiKey', 'showCalendarNames', 'showLocations', 'showDescriptions', 'showPresenters' ]; for (let prop of propsToChange) { if (this.props[prop] !== nextProps[prop]) return true; } let eventSourcesToAdd = nextProps.eventSources.filter(newEventSource => !this.props.eventSources.some(oldEventSource => oldEventSource.googleCalendarId === newEventSource.googleCalendarId && oldEventSource.source === newEventSource.source && oldEventSource.color === newEventSource.color) ); let eventSourcesToRemove = this.props.eventSources.filter(oldEventSource => !nextProps.eventSources.some(newEventSource => newEventSource.googleCalendarId === oldEventSource.googleCalendarId && oldEventSource.source === newEventSource.source && newEventSource.color === oldEventSource.color) ); const calendar = $(`#${this.state.calendarId}`); if (eventSourcesToRemove && eventSourcesToRemove.length > 0) calendar.fullCalendar('removeEventSources', eventSourcesToRemove); if (eventSourcesToAdd && eventSourcesToAdd.length > 0){ eventSourcesToAdd.map(eventSourceToAdd => { calendar.fullCalendar('addEventSource', eventSourceToAdd); }); } if (nextProps.location && nextProps.location.search) { let params = new URLSearchParams(nextProps.location.search.slice(1)); let viewName = params.get('view'); let viewDate = params.get('date'); if ( this.getGenericViewName(viewName) !== this.getGenericViewName(this.viewName) || viewDate !== this.viewDate ) { this.viewName = viewName; this.viewDate = viewDate; $(`#${this.state.calendarId}`) .fullCalendar( 'changeView', this.getSpecificViewName(viewName), viewDate ); } } return false; } componentDidMount() { this.createCalendar(); if (this.props.trustedOrigins) { window.addEventListener('message', this.receiveMessage, false); } } UNSAFE_componentWillReceiveProps(nextProps) { const { eventId, setActiveEvent } = this.props; const calendar = $(`#${this.state.calendarId}`); if (nextProps.eventId && nextProps.eventId !== eventId) { let events = calendar.fullCalendar('clientEvents', nextProps.eventId); if (events.length > 0) { setActiveEvent(events[0]); } } } UNSAFE_componentWillUpdate() { this.destroyCalendar(); } componentDidUpdate() { this.createCalendar(); } componentWillUnmount() { this.destroyCalendar(); window.removeEventListener('message', this.receiveMessage); } receiveMessage(event) { // Allow extracting calendar state by posting message from trusted origin, // useful when calendar is embedded in iframe. if ( this.props.trustedOrigins && ( this.props.trustedOrigins.includes('*') || this.props.trustedOrigins.includes(event.origin) ) && event.data === 'getCalendarState' ) { const { customCalendars, showCalendarNames, showLocations, showDescriptions, showPresenters } = this.props; event.source.postMessage({ action: 'calendarStateResponse', calendarName: this.props.location.pathname.slice(1), calendarEvent: this.props.location.hash.slice(1), calendarView: this.getGenericViewName(this.viewName), calendarDate: this.viewDate, customCalendars, showCalendarNames, showLocations, showDescriptions, showPresenters }, event.origin); } } getGenericViewName(viewName) { switch (viewName) { case 'listWeek': case 'basicWeek': return 'week'; default: return viewName; } } getSpecificViewName(viewName) { switch (viewName) { case 'week': return window.innerWidth > BREAKPOINTS.SMALL_DESKTOP ? 'basicWeek' : 'listWeek'; default: return viewName; } } getCalendarState(view) { if (!this.props.history) return; let viewDate = view.intervalStart.toISOString(); if ( this.getSpecificViewName(this.viewName) !== view.name || this.viewDate !== viewDate ) { let newLocation = Object.assign({}, this.props.location); let params = new URLSearchParams(newLocation.search.slice(1)); params.set('view', view.name); params.set('date', viewDate); newLocation.search = params.toString(); this.viewName = view.name; this.viewDate = view.intervalStart.toString(); this.props.history.push(newLocation); } } destroyCalendar() { $(`#${this.state.calendarId}`).fullCalendar('destroy'); } createCalendar() { const { timezone = 'local', eventId, setActiveEventId, setActiveEvent, defaultDate, showCalendarNames, showLocations, showDescriptions, showPresenters } = this.props; let { defaultView } = this.props; if (defaultView) defaultView = this.getSpecificViewName(defaultView); else defaultView = window.innerWidth > BREAKPOINTS.SMALL_DESKTOP ? 'month' : 'listWeek'; this.viewName = defaultView; this.viewDate = defaultDate; const calendar = $(`#${this.state.calendarId}`); const getCalendarState = this.getCalendarState; calendar.fullCalendar(Object.assign({ timezone, googleCalendarApiKey: this.props.apiKey, eventSources: this.props.eventSources, height: 'auto', fixedWeekCount: false, header: { left: 'title', center: 'month,listWeek,basicWeek,agendaDay', right: 'today prev,next' }, defaultView, defaultDate, navLinks: true, eventRender(calEvent, element, view){ if (calEvent.id) { const clientEvents = calendar.fullCalendar('clientEvents', otherEvent => { return otherEvent.id === calEvent.id && momentsEqual(otherEvent.start, calEvent.start) && ( otherEvent.allDay && calEvent.allDay || momentsEqual(otherEvent.end, calEvent.end) ); }); if (clientEvents.length > 1) { const firstEvent = clientEvents[0]; if (firstEvent._id !== calEvent._id) { return false; } } } let container, calEventElement; if (view && view.name && view.name.startsWith('list')) { container = document.createElement('tr'); calEventElement = 'td'; } else { container = document.createElement('div'); calEventElement = 'div'; } container.className = 'event-container'; if (view && view.name && view.name.startsWith('agenda')) container.style.position = 'absolute'; const showCalendarName = showCalendarNames || (calEvent.calendar && calEvent.calendar.showCalendarName); render( <CalendarEvent event={calEvent} view={view} setActiveEventId={setActiveEventId} setActiveEvent={setActiveEvent} containerElement={calEventElement} showCalendarName={showCalendarName} showLocation={showLocations} showDescription={showDescriptions} showPresenters={showPresenters} />, container); return container; }, loading(isLoading) { if (!isLoading) { if (eventId) { let events = calendar.fullCalendar('clientEvents', eventId); if (events.length > 0) { setActiveEvent(events[0]); } } } }, viewRender: getCalendarState }, this.props.fullcalendarConfig)); } } function momentsEqual(d1, d2) { return d1 && d2 && d1.valueOf() === d2.valueOf(); } FullCalendar.propTypes = { trustedOrigins: PropTypes.array, apiKey: PropTypes.string.isRequired, eventSources: PropTypes.array.isRequired, customCalendars: PropTypes.array, setActiveEventId: PropTypes.func, setActiveEvent: PropTypes.func, eventId: PropTypes.string, fullcalendarConfig: PropTypes.object, defaultView: PropTypes.string, defaultDate: PropTypes.string, showCalendarNames: PropTypes.bool, showLocations: PropTypes.bool, showDescriptions: PropTypes.bool, showPresenters: PropTypes.bool, location: PropTypes.shape({ pathname: PropTypes.string, hash: PropTypes.string, search: PropTypes.string }), history: PropTypes.shape({ push: PropTypes.func.isRequired, listen: PropTypes.func.isRequired }) };
app/components/HotelPolicies/index.js
seanng/web-server
import React from 'react'; import { Editor, EditorState } from 'draft-js'; // import styled from 'styled-components'; import { Glyphicon, FormControl } from 'react-bootstrap'; import { createStructuredSelector } from 'reselect'; import { toggleHotelPoliciesMode } from 'containers/HotelProfile/actions' import { FormattedMessage } from 'react-intl'; import messages from './messages'; class HotelPolicies extends React.Component { _editHotelProfile = (e) => { this.props.editHotelProfile({ policies: e.target.value }) } _toggleEditMode = (e) => { this.props.toggleEditMode(); } _formattedPolicies () { const { policies } = this.props console.log('the policies in this props. ', policies) return ( <div> { policies } </div> ) } _editingPolicies () { const { policies } = this.props return ( <div> <FormControl componentClass="textarea" rows='12' placeholder="There are no policies set at the moment." value={policies} onChange={this._editHotelProfile} id='hotelPoliciesInput' /> </div> ) } render () { const glyphicon = this.props.isEditingMode ? 'glyphicon glyphicon-floppy-disk' : 'glyphicon glyphicon-pencil'; return ( <div className="row"> <div className="col-xs-11"> { this.props.isEditingMode ? this._editingPolicies() : this._formattedPolicies() } </div> <div className="col-xs-1"> <Glyphicon glyph={glyphicon} onClick={this._toggleEditMode} /> </div> </div> ); } } export default HotelPolicies;
src/pages/espaco-virtual.js
vitorbarbosa19/ziro-online
import React from 'react' import BrandGallery from '../components/BrandGallery' export default () => ( <BrandGallery brand='Espaco Virtual' /> )
src/components/A.js
lol-russo/designsystems.email
import React from 'react'; function A(props) { return ( <a href={props.href} className="link dim blue fw5"> {props.children} </a> ); } export default A;
docs/pages/components/hidden.js
lgollut/material-ui
import React from 'react'; import MarkdownDocs from 'docs/src/modules/components/MarkdownDocs'; import { prepareMarkdown } from 'docs/src/modules/utils/parseMarkdown'; const pageFilename = 'components/hidden'; const requireDemo = require.context('docs/src/pages/components/hidden', false, /\.(js|tsx)$/); const requireRaw = require.context( '!raw-loader!../../src/pages/components/hidden', false, /\.(js|md|tsx)$/, ); export default function Page({ demos, docs }) { return <MarkdownDocs demos={demos} docs={docs} requireDemo={requireDemo} />; } Page.getInitialProps = () => { const { demos, docs } = prepareMarkdown({ pageFilename, requireRaw }); return { demos, docs }; };
ajax/libs/forerunnerdb/1.3.611/fdb-all.min.js
dakshshah96/cdnjs
!function a(b,c,d){function e(g,h){if(!c[g]){if(!b[g]){var i="function"==typeof require&&require;if(!h&&i)return i(g,!0);if(f)return f(g,!0);var j=new Error("Cannot find module '"+g+"'");throw j.code="MODULE_NOT_FOUND",j}var k=c[g]={exports:{}};b[g][0].call(k.exports,function(a){var c=b[g][1][a];return e(c?c:a)},k,k.exports,a,b,c,d)}return c[g].exports}for(var f="function"==typeof require&&require,g=0;g<d.length;g++)e(d[g]);return e}({1:[function(a,b,c){var d=a("./core");a("../lib/CollectionGroup"),a("../lib/View"),a("../lib/Highchart"),a("../lib/Persist"),a("../lib/Document"),a("../lib/Overview"),a("../lib/Grid"),a("../lib/NodeApiClient"),a("../lib/BinaryLog");"undefined"!=typeof window&&(window.ForerunnerDB=d),b.exports=d},{"../lib/BinaryLog":4,"../lib/CollectionGroup":7,"../lib/Document":11,"../lib/Grid":13,"../lib/Highchart":14,"../lib/NodeApiClient":30,"../lib/Overview":33,"../lib/Persist":35,"../lib/View":42,"./core":2}],2:[function(a,b,c){var d=a("../lib/Core");a("../lib/Shim.IE8");"undefined"!=typeof window&&(window.ForerunnerDB=d),b.exports=d},{"../lib/Core":8,"../lib/Shim.IE8":41}],3:[function(a,b,c){"use strict";var d,e=a("./Shared"),f=a("./Path"),g=function(a){this._primaryKey="_id",this._keyArr=[],this._data=[],this._objLookup={},this._count=0,this._keyArr=d.parse(a,!0)};e.addModule("ActiveBucket",g),e.mixin(g.prototype,"Mixin.Sorting"),d=new f,e.synthesize(g.prototype,"primaryKey"),g.prototype.qs=function(a,b,c,d){if(!b.length)return 0;for(var e,f,g,h=-1,i=0,j=b.length-1;j>=i&&(e=Math.floor((i+j)/2),h!==e);)f=b[e],void 0!==f&&(g=d(this,a,c,f),g>0&&(i=e+1),0>g&&(j=e-1)),h=e;return g>0?e+1:e},g.prototype._sortFunc=function(a,b,c,e){var f,g,h,i=c.split(".:."),j=e.split(".:."),k=a._keyArr,l=k.length;for(f=0;l>f;f++)if(g=k[f],h=typeof d.get(b,g.path),"number"===h&&(i[f]=Number(i[f]),j[f]=Number(j[f])),i[f]!==j[f]){if(1===g.value)return a.sortAsc(i[f],j[f]);if(-1===g.value)return a.sortDesc(i[f],j[f])}},g.prototype.insert=function(a){var b,c;return b=this.documentKey(a),c=this._data.indexOf(b),-1===c?(c=this.qs(a,this._data,b,this._sortFunc),this._data.splice(c,0,b)):this._data.splice(c,0,b),this._objLookup[a[this._primaryKey]]=b,this._count++,c},g.prototype.remove=function(a){var b,c;return b=this._objLookup[a[this._primaryKey]],b?(c=this._data.indexOf(b),c>-1?(this._data.splice(c,1),delete this._objLookup[a[this._primaryKey]],this._count--,!0):!1):!1},g.prototype.index=function(a){var b,c;return b=this.documentKey(a),c=this._data.indexOf(b),-1===c&&(c=this.qs(a,this._data,b,this._sortFunc)),c},g.prototype.documentKey=function(a){var b,c,e="",f=this._keyArr,g=f.length;for(b=0;g>b;b++)c=f[b],e&&(e+=".:."),e+=d.get(a,c.path);return e+=".:."+a[this._primaryKey]},g.prototype.count=function(){return this._count},e.finishModule("ActiveBucket"),b.exports=g},{"./Path":34,"./Shared":40}],4:[function(a,b,c){"use strict";var d,e,f,g,h,i,j;d=a("./Shared"),j=function(){this.init.apply(this,arguments)},j.prototype.init=function(a){var b=this;b._logCounter=0,b._parent=a,b.size(1e3)},d.addModule("BinaryLog",j),d.mixin(j.prototype,"Mixin.Common"),d.mixin(j.prototype,"Mixin.ChainReactor"),d.mixin(j.prototype,"Mixin.Events"),f=d.modules.Collection,h=d.modules.Db,e=d.modules.ReactorIO,g=f.prototype.init,i=h.prototype.init,d.synthesize(j.prototype,"name"),d.synthesize(j.prototype,"size"),j.prototype.attachIO=function(){var a=this;a._io||(a._log=new f(a._parent.name()+"-BinaryLog",{capped:!0,size:a.size()}),a._log.objectId=function(b){return b||(b=++a._logCounter),b},a._io=new e(a._parent,a,function(b){switch(b.type){case"insert":a._log.insert({type:b.type,data:b.data});break;case"remove":a._log.insert({type:b.type,data:{query:b.data.query}});break;case"update":a._log.insert({type:b.type,data:{query:b.data.query,update:b.data.update}})}return!1}))},j.prototype.detachIO=function(){var a=this;a._io&&(a._log.drop(),a._io.drop(),delete a._log,delete a._io)},f.prototype.init=function(){g.apply(this,arguments),this._binaryLog=new j(this)},d.finishModule("BinaryLog"),b.exports=j},{"./Shared":40}],5:[function(a,b,c){"use strict";var d=a("./Shared"),e=a("./Path"),f=new e,g=function(a,b,c){this.init.apply(this,arguments)};g.prototype.init=function(a,b,c,d,e){this._store=[],this._keys=[],void 0!==c&&this.primaryKey(c),void 0!==b&&this.index(b),void 0!==d&&this.compareFunc(d),void 0!==e&&this.hashFunc(e),void 0!==a&&this.data(a)},d.addModule("BinaryTree",g),d.mixin(g.prototype,"Mixin.ChainReactor"),d.mixin(g.prototype,"Mixin.Sorting"),d.mixin(g.prototype,"Mixin.Common"),d.synthesize(g.prototype,"compareFunc"),d.synthesize(g.prototype,"hashFunc"),d.synthesize(g.prototype,"indexDir"),d.synthesize(g.prototype,"primaryKey"),d.synthesize(g.prototype,"keys"),d.synthesize(g.prototype,"index",function(a){return void 0!==a&&(this.debug()&&console.log("Setting index",a,f.parse(a,!0)),this.keys(f.parse(a,!0))),this.$super.call(this,a)}),g.prototype.clear=function(){delete this._data,delete this._left,delete this._right,this._store=[]},g.prototype.data=function(a){return void 0!==a?(this._data=a,this._hashFunc&&(this._hash=this._hashFunc(a)),this):this._data},g.prototype.push=function(a){return void 0!==a?(this._store.push(a),this):!1},g.prototype.pull=function(a){if(void 0!==a){var b=this._store.indexOf(a);if(b>-1)return this._store.splice(b,1),this}return!1},g.prototype._compareFunc=function(a,b){var c,d,e=0;for(c=0;c<this._keys.length;c++)if(d=this._keys[c],1===d.value?e=this.sortAsc(f.get(a,d.path),f.get(b,d.path)):-1===d.value&&(e=this.sortDesc(f.get(a,d.path),f.get(b,d.path))),this.debug()&&console.log("Compared %s with %s order %d in path %s and result was %d",f.get(a,d.path),f.get(b,d.path),d.value,d.path,e),0!==e)return this.debug()&&console.log("Retuning result %d",e),e;return this.debug()&&console.log("Retuning result %d",e),e},g.prototype._hashFunc=function(a){return a[this._keys[0].path]},g.prototype.removeChildNode=function(a){this._left===a?delete this._left:this._right===a&&delete this._right},g.prototype.nodeBranch=function(a){return this._left===a?"left":this._right===a?"right":void 0},g.prototype.insert=function(a){var b,c,d,e;if(a instanceof Array){for(c=[],d=[],e=0;e<a.length;e++)this.insert(a[e])?c.push(a[e]):d.push(a[e]);return{inserted:c,failed:d}}return this.debug()&&console.log("Inserting",a),this._data?(b=this._compareFunc(this._data,a),0===b?(this.debug()&&console.log("Data is equal (currrent, new)",this._data,a),this._left?this._left.insert(a):(this._left=new g(a,this._index,this._binaryTree,this._compareFunc,this._hashFunc),this._left._parent=this),!0):-1===b?(this.debug()&&console.log("Data is greater (currrent, new)",this._data,a),this._right?this._right.insert(a):(this._right=new g(a,this._index,this._binaryTree,this._compareFunc,this._hashFunc),this._right._parent=this),!0):1===b?(this.debug()&&console.log("Data is less (currrent, new)",this._data,a),this._left?this._left.insert(a):(this._left=new g(a,this._index,this._binaryTree,this._compareFunc,this._hashFunc),this._left._parent=this),!0):!1):(this.debug()&&console.log("Node has no data, setting data",a),this.data(a),!0)},g.prototype.remove=function(a){var b,c,d,e=this.primaryKey();if(a instanceof Array){for(c=[],d=0;d<a.length;d++)this.remove(a[d])&&c.push(a[d]);return c}return this.debug()&&console.log("Removing",a),this._data[e]===a[e]?this._remove(this):(b=this._compareFunc(this._data,a),-1===b&&this._right?this._right.remove(a):1===b&&this._left?this._left.remove(a):!1)},g.prototype._remove=function(a){var b,c;return this._left?(b=this._left,c=this._right,this._left=b._left,this._right=b._right,this._data=b._data,this._store=b._store,c&&(b.rightMost()._right=c)):this._right?(c=this._right,this._left=c._left,this._right=c._right,this._data=c._data,this._store=c._store):this.clear(),!0},g.prototype.leftMost=function(){return this._left?this._left.leftMost():this},g.prototype.rightMost=function(){return this._right?this._right.rightMost():this},g.prototype.lookup=function(a,b,c){var d=this._compareFunc(this._data,a);return c=c||[],0===d&&(this._left&&this._left.lookup(a,b,c),c.push(this._data),this._right&&this._right.lookup(a,b,c)),-1===d&&this._right&&this._right.lookup(a,b,c),1===d&&this._left&&this._left.lookup(a,b,c),c},g.prototype.inOrder=function(a,b){switch(b=b||[],this._left&&this._left.inOrder(a,b),a){case"hash":b.push(this._hash);break;case"data":b.push(this._data);break;default:b.push({key:this._data,arr:this._store})}return this._right&&this._right.inOrder(a,b),b},g.prototype.startsWith=function(a,b,c,d){var e,g,h=f.get(this._data,a),i=h.substr(0,b.length);return c=c||new RegExp("^"+b),d=d||[],void 0===d._visited&&(d._visited=0),d._visited++,g=this.sortAsc(h,b),e=i===b,0===g&&(this._left&&this._left.startsWith(a,b,c,d),e&&d.push(this._data),this._right&&this._right.startsWith(a,b,c,d)),-1===g&&(e&&d.push(this._data),this._right&&this._right.startsWith(a,b,c,d)),1===g&&(this._left&&this._left.startsWith(a,b,c,d),e&&d.push(this._data)),d},g.prototype.findRange=function(a,b,c,d,f,g){f=f||[],g=g||new e(b),this._left&&this._left.findRange(a,b,c,d,f,g);var h=g.value(this._data),i=this.sortAsc(h,c),j=this.sortAsc(h,d);if(!(0!==i&&1!==i||0!==j&&-1!==j))switch(a){case"hash":f.push(this._hash);break;case"data":f.push(this._data);break;default:f.push({key:this._data,arr:this._store})}return this._right&&this._right.findRange(a,b,c,d,f,g),f},g.prototype.match=function(a,b,c){var d,e,g,h=[],i=0;for(d=f.parseArr(this._index,{verbose:!0}),e=f.parseArr(a,c&&c.pathOptions?c.pathOptions:{ignore:/\$/,verbose:!0}),g=0;g<d.length;g++)e[g]===d[g]&&(i++,h.push(e[g]));return{matchedKeys:h,totalKeyCount:e.length,score:i}},d.finishModule("BinaryTree"),b.exports=g},{"./Path":34,"./Shared":40}],6:[function(a,b,c){"use strict";var d,e,f,g,h,i,j,k,l,m,n,o;d=a("./Shared");var p=function(a,b){this.init.apply(this,arguments)};p.prototype.init=function(a,b){this._primaryKey="_id",this._primaryIndex=new g("primary"),this._primaryCrc=new g("primaryCrc"),this._crcLookup=new g("crcLookup"),this._name=a,this._data=[],this._metrics=new f,this._options=b||{changeTimestamp:!1},this._options.db&&this.db(this._options.db),this._metaData={},this._deferQueue={insert:[],update:[],remove:[],upsert:[],async:[]},this._deferThreshold={insert:100,update:100,remove:100,upsert:100},this._deferTime={insert:1,update:1,remove:1,upsert:1},this._deferredCalls=!0,this.subsetOf(this)},d.addModule("Collection",p),d.mixin(p.prototype,"Mixin.Common"),d.mixin(p.prototype,"Mixin.Events"),d.mixin(p.prototype,"Mixin.ChainReactor"),d.mixin(p.prototype,"Mixin.CRUD"),d.mixin(p.prototype,"Mixin.Constants"),d.mixin(p.prototype,"Mixin.Triggers"),d.mixin(p.prototype,"Mixin.Sorting"),d.mixin(p.prototype,"Mixin.Matching"),d.mixin(p.prototype,"Mixin.Updating"),d.mixin(p.prototype,"Mixin.Tags"),f=a("./Metrics"),g=a("./KeyValueStore"),h=a("./Path"),i=a("./IndexHashMap"),j=a("./IndexBinaryTree"),k=a("./Index2d"),l=a("./Crc"),e=d.modules.Db,m=a("./Overload"),n=a("./ReactorIO"),o=new h,p.prototype.crc=l,d.synthesize(p.prototype,"deferredCalls"),d.synthesize(p.prototype,"state"),d.synthesize(p.prototype,"name"),d.synthesize(p.prototype,"metaData"),d.synthesize(p.prototype,"capped"),d.synthesize(p.prototype,"cappedSize"),p.prototype._asyncPending=function(a){this._deferQueue.async.push(a)},p.prototype._asyncComplete=function(a){for(var b=this._deferQueue.async.indexOf(a);b>-1;)this._deferQueue.async.splice(b,1),b=this._deferQueue.async.indexOf(a);0===this._deferQueue.async.length&&this.deferEmit("ready")},p.prototype.data=function(){return this._data},p.prototype.drop=function(a){var b;if(this.isDropped())return a&&a(!1,!0),!0;if(this._db&&this._db._collection&&this._name){if(this.debug()&&console.log(this.logIdentifier()+" Dropping"),this._state="dropped",this.emit("drop",this),delete this._db._collection[this._name],this._collate)for(b in this._collate)this._collate.hasOwnProperty(b)&&this.collateRemove(b);return delete this._primaryKey,delete this._primaryIndex,delete this._primaryCrc,delete this._crcLookup,delete this._name,delete this._data,delete this._metrics,delete this._listeners,a&&a(!1,!0),!0}return a&&a(!1,!0),!1},p.prototype.primaryKey=function(a){if(void 0!==a){if(this._primaryKey!==a){var b=this._primaryKey;this._primaryKey=a,this._primaryIndex.primaryKey(a),this.rebuildPrimaryKeyIndex(),this.chainSend("primaryKey",a,{oldData:b})}return this}return this._primaryKey},p.prototype._onInsert=function(a,b){this.emit("insert",a,b)},p.prototype._onUpdate=function(a){this.emit("update",a)},p.prototype._onRemove=function(a){this.emit("remove",a)},p.prototype._onChange=function(){this._options.changeTimestamp&&(this._metaData.lastChange=new Date)},d.synthesize(p.prototype,"db",function(a){return a&&"_id"===this.primaryKey()&&(this.primaryKey(a.primaryKey()),this.debug(a.debug())),this.$super.apply(this,arguments)}),d.synthesize(p.prototype,"mongoEmulation"),p.prototype.setData=function(a,b,c){if(this.isDropped())throw this.logIdentifier()+" Cannot operate in a dropped state!";if(a){var d=this._metrics.create("setData");d.start(),b=this.options(b),this.preSetData(a,b,c),b.$decouple&&(a=this.decouple(a)),a instanceof Array||(a=[a]),d.time("transformIn"),a=this.transformIn(a),d.time("transformIn");var e=[].concat(this._data);this._dataReplace(a),d.time("Rebuild Primary Key Index"),this.rebuildPrimaryKeyIndex(b),d.time("Rebuild Primary Key Index"),d.time("Rebuild All Other Indexes"),this._rebuildIndexes(),d.time("Rebuild All Other Indexes"),d.time("Resolve chains"),this.chainSend("setData",a,{oldData:e}),d.time("Resolve chains"),d.stop(),this._onChange(),this.emit("setData",this._data,e)}return c&&c(!1),this},p.prototype.rebuildPrimaryKeyIndex=function(a){a=a||{$ensureKeys:void 0,$violationCheck:void 0};var b,c,d,e,f=a&&void 0!==a.$ensureKeys?a.$ensureKeys:!0,g=a&&void 0!==a.$violationCheck?a.$violationCheck:!0,h=this._primaryIndex,i=this._primaryCrc,j=this._crcLookup,k=this._primaryKey;for(h.truncate(),i.truncate(),j.truncate(),b=this._data,c=b.length;c--;){if(d=b[c],f&&this.ensurePrimaryKey(d),g){if(!h.uniqueSet(d[k],d))throw this.logIdentifier()+" Call to setData on collection failed because your data violates the primary key unique constraint. One or more documents are using the same primary key: "+d[this._primaryKey]}else h.set(d[k],d);e=this.jStringify(d),i.set(d[k],e),j.set(e,d)}},p.prototype.ensurePrimaryKey=function(a){void 0===a[this._primaryKey]&&(a[this._primaryKey]=this.objectId())},p.prototype.truncate=function(){if(this.isDropped())throw this.logIdentifier()+" Cannot operate in a dropped state!";return this.emit("truncate",this._data),this._data.length=0,this._primaryIndex=new g("primary"),this._primaryCrc=new g("primaryCrc"),this._crcLookup=new g("crcLookup"),this._onChange(),this.emit("immediateChange",{type:"truncate"}),this.deferEmit("change",{type:"truncate"}),this},p.prototype.upsert=function(a,b){if(this.isDropped())throw this.logIdentifier()+" Cannot operate in a dropped state!";if(a){var c,d,e=this._deferQueue.upsert,f=this._deferThreshold.upsert,g={};if(a instanceof Array){if(this._deferredCalls&&a.length>f)return this._deferQueue.upsert=e.concat(a),this._asyncPending("upsert"),this.processQueue("upsert",b),{};for(g=[],d=0;d<a.length;d++)g.push(this.upsert(a[d]));return b&&b(),g}switch(a[this._primaryKey]?(c={},c[this._primaryKey]=a[this._primaryKey],this._primaryIndex.lookup(c)[0]?g.op="update":g.op="insert"):g.op="insert",g.op){case"insert":g.result=this.insert(a);break;case"update":g.result=this.update(c,a)}return g}return b&&b(),{}},p.prototype.filter=function(a,b,c){return this.find(a,c).filter(b)},p.prototype.filterUpdate=function(a,b,c){var d,e,f,g,h=this.find(a,c),i=[],j=this.primaryKey();for(g=0;g<h.length;g++)d=h[g],f=b(d),f&&(e={},e[j]=d[j],i.push(this.update(e,f)));return i},p.prototype.update=function(a,b,c){if(this.isDropped())throw this.logIdentifier()+" Cannot operate in a dropped state!";b=this.decouple(b),this.mongoEmulation()&&(this.convertToFdb(a),this.convertToFdb(b)),b=this.transformIn(b);var d,e,f=this,g=this._metrics.create("update"),h=function(d){var e,h,i,j=f.decouple(d);return f.willTrigger(f.TYPE_UPDATE,f.PHASE_BEFORE)||f.willTrigger(f.TYPE_UPDATE,f.PHASE_AFTER)?(e=f.decouple(d),h={type:"update",query:f.decouple(a),update:f.decouple(b),options:f.decouple(c),op:g},i=f.updateObject(e,h.update,h.query,h.options,""),f.processTrigger(h,f.TYPE_UPDATE,f.PHASE_BEFORE,d,e)!==!1?(i=f.updateObject(d,e,h.query,h.options,""),f.processTrigger(h,f.TYPE_UPDATE,f.PHASE_AFTER,j,e)):i=!1):i=f.updateObject(d,b,a,c,""),f._updateIndexes(j,d),i};return g.start(),g.time("Retrieve documents to update"),d=this.find(a,{$decouple:!1}),g.time("Retrieve documents to update"),d.length&&(g.time("Update documents"),e=d.filter(h),g.time("Update documents"),e.length&&(this.debug()&&console.log(this.logIdentifier()+" Updated some data"),g.time("Resolve chains"),this.chainSend("update",{query:a,update:b,dataSet:e},c),g.time("Resolve chains"),this._onUpdate(e),this._onChange(),this.emit("immediateChange",{type:"update",data:e}),this.deferEmit("change",{type:"update",data:e}))),g.stop(),e||[]},p.prototype._replaceObj=function(a,b){var c;this._removeFromIndexes(a);for(c in a)a.hasOwnProperty(c)&&delete a[c];for(c in b)b.hasOwnProperty(c)&&(a[c]=b[c]);if(!this._insertIntoIndexes(a))throw this.logIdentifier()+" Primary key violation in update! Key violated: "+a[this._primaryKey];return this},p.prototype.updateById=function(a,b){var c={};return c[this._primaryKey]=a,this.update(c,b)[0]},p.prototype.updateObject=function(a,b,c,d,e,f){b=this.decouple(b),e=e||"","."===e.substr(0,1)&&(e=e.substr(1,e.length-1));var g,i,j,k,l,m,n,o,p,q,r,s,t=!1,u=!1;for(s in b)if(b.hasOwnProperty(s)){if(g=!1,"$"===s.substr(0,1))switch(s){case"$key":case"$index":case"$data":case"$min":case"$max":g=!0;break;case"$each":for(g=!0,k=b.$each.length,j=0;k>j;j++)u=this.updateObject(a,b.$each[j],c,d,e),u&&(t=!0);t=t||u;break;case"$replace":g=!0,n=b.$replace,o=this.primaryKey();for(m in a)a.hasOwnProperty(m)&&m!==o&&void 0===n[m]&&(this._updateUnset(a,m),t=!0);for(m in n)n.hasOwnProperty(m)&&m!==o&&(this._updateOverwrite(a,m,n[m]),t=!0);break;default:g=!0,u=this.updateObject(a,b[s],c,d,e,s),t=t||u}if(this._isPositionalKey(s)&&(g=!0,s=s.substr(0,s.length-2),p=new h(e+"."+s),a[s]&&a[s]instanceof Array&&a[s].length)){for(i=[],j=0;j<a[s].length;j++)this._match(a[s][j],p.value(c)[0],d,"",{})&&i.push(j);for(j=0;j<i.length;j++)u=this.updateObject(a[s][i[j]],b[s+".$"],c,d,e+"."+s,f),t=t||u}if(!g)if(f||"object"!=typeof b[s])switch(f){case"$inc":var v=!0;b[s]>0?b.$max&&a[s]>=b.$max&&(v=!1):b[s]<0&&b.$min&&a[s]<=b.$min&&(v=!1),v&&(this._updateIncrement(a,s,b[s]),t=!0);break;case"$cast":switch(b[s]){case"array":a[s]instanceof Array||(this._updateProperty(a,s,b.$data||[]),t=!0);break;case"object":(!(a[s]instanceof Object)||a[s]instanceof Array)&&(this._updateProperty(a,s,b.$data||{}),t=!0);break;case"number":"number"!=typeof a[s]&&(this._updateProperty(a,s,Number(a[s])),t=!0);break;case"string":"string"!=typeof a[s]&&(this._updateProperty(a,s,String(a[s])),t=!0);break;default:throw this.logIdentifier()+" Cannot update cast to unknown type: "+b[s]}break;case"$push":if(void 0===a[s]&&this._updateProperty(a,s,[]),!(a[s]instanceof Array))throw this.logIdentifier()+" Cannot push to a key that is not an array! ("+s+")";if(void 0!==b[s].$position&&b[s].$each instanceof Array)for(l=b[s].$position,k=b[s].$each.length,j=0;k>j;j++)this._updateSplicePush(a[s],l+j,b[s].$each[j]);else if(b[s].$each instanceof Array)for(k=b[s].$each.length,j=0;k>j;j++)this._updatePush(a[s],b[s].$each[j]);else this._updatePush(a[s],b[s]);t=!0;break;case"$pull":if(a[s]instanceof Array){for(i=[],j=0;j<a[s].length;j++)this._match(a[s][j],b[s],d,"",{})&&i.push(j);for(k=i.length;k--;)this._updatePull(a[s],i[k]),t=!0}break;case"$pullAll":if(a[s]instanceof Array){if(!(b[s]instanceof Array))throw this.logIdentifier()+" Cannot pullAll without being given an array of values to pull! ("+s+")";if(i=a[s],k=i.length,k>0)for(;k--;){for(l=0;l<b[s].length;l++)i[k]===b[s][l]&&(this._updatePull(a[s],k),k--,t=!0);if(0>k)break}}break;case"$addToSet":if(void 0===a[s]&&this._updateProperty(a,s,[]),!(a[s]instanceof Array))throw this.logIdentifier()+" Cannot addToSet on a key that is not an array! ("+s+")";var w,x,y,z,A=a[s],B=A.length,C=!0,D=d&&d.$addToSet;for(b[s].$key?(y=!1,z=new h(b[s].$key),x=z.value(b[s])[0],delete b[s].$key):D&&D.key?(y=!1,z=new h(D.key),x=z.value(b[s])[0]):(x=this.jStringify(b[s]),y=!0),w=0;B>w;w++)if(y){if(this.jStringify(A[w])===x){C=!1;break}}else if(x===z.value(A[w])[0]){C=!1;break}C&&(this._updatePush(a[s],b[s]),t=!0);break;case"$splicePush":if(void 0===a[s]&&this._updateProperty(a,s,[]),!(a[s]instanceof Array))throw this.logIdentifier()+" Cannot splicePush with a key that is not an array! ("+s+")";if(l=b.$index,void 0===l)throw this.logIdentifier()+" Cannot splicePush without a $index integer value!";delete b.$index,l>a[s].length&&(l=a[s].length),this._updateSplicePush(a[s],l,b[s]),t=!0;break;case"$move":if(!(a[s]instanceof Array))throw this.logIdentifier()+" Cannot move on a key that is not an array! ("+s+")";for(j=0;j<a[s].length;j++)if(this._match(a[s][j],b[s],d,"",{})){var E=b.$index;if(void 0===E)throw this.logIdentifier()+" Cannot move without a $index integer value!";delete b.$index,this._updateSpliceMove(a[s],j,E),t=!0;break}break;case"$mul":this._updateMultiply(a,s,b[s]),t=!0;break;case"$rename":this._updateRename(a,s,b[s]),t=!0;break;case"$overwrite":this._updateOverwrite(a,s,b[s]),t=!0;break;case"$unset":this._updateUnset(a,s),t=!0;break;case"$clear":this._updateClear(a,s),t=!0;break;case"$pop":if(!(a[s]instanceof Array))throw this.logIdentifier()+" Cannot pop from a key that is not an array! ("+s+")";this._updatePop(a[s],b[s])&&(t=!0);break;case"$toggle":this._updateProperty(a,s,!a[s]),t=!0;break;default:a[s]!==b[s]&&(this._updateProperty(a,s,b[s]),t=!0)}else if(null!==a[s]&&"object"==typeof a[s])if(q=a[s]instanceof Array,r=b[s]instanceof Array,q||r)if(!r&&q)for(j=0;j<a[s].length;j++)u=this.updateObject(a[s][j],b[s],c,d,e+"."+s,f),t=t||u;else a[s]!==b[s]&&(this._updateProperty(a,s,b[s]),t=!0);else u=this.updateObject(a[s],b[s],c,d,e+"."+s,f),t=t||u;else a[s]!==b[s]&&(this._updateProperty(a,s,b[s]),t=!0)}return t},p.prototype._isPositionalKey=function(a){return".$"===a.substr(a.length-2,2)},p.prototype.remove=function(a,b,c){if(this.isDropped())throw this.logIdentifier()+" Cannot operate in a dropped state!";var d,e,f,g,h,i,j,k,l=this;if("function"==typeof b&&(c=b,b={}),this.mongoEmulation()&&this.convertToFdb(a),a instanceof Array){for(g=[],f=0;f<a.length;f++)g.push(this.remove(a[f],{noEmit:!0}));return(!b||b&&!b.noEmit)&&this._onRemove(g),c&&c(!1,g),g}if(g=[],d=this.find(a,{$decouple:!1}),d.length){h=function(a){l._removeFromIndexes(a),e=l._data.indexOf(a),l._dataRemoveAtIndex(e),g.push(a)};for(var m=0;m<d.length;m++)j=d[m],l.willTrigger(l.TYPE_REMOVE,l.PHASE_BEFORE)||l.willTrigger(l.TYPE_REMOVE,l.PHASE_AFTER)?(i={type:"remove"},k=l.decouple(j),l.processTrigger(i,l.TYPE_REMOVE,l.PHASE_BEFORE,k,k)!==!1&&(h(j),l.processTrigger(i,l.TYPE_REMOVE,l.PHASE_AFTER,k,k))):h(j);g.length&&(l.chainSend("remove",{query:a,dataSet:g},b),(!b||b&&!b.noEmit)&&this._onRemove(g),this._onChange(),this.emit("immediateChange",{type:"remove",data:g}),this.deferEmit("change",{type:"remove",data:g}))}return c&&c(!1,g),g},p.prototype.removeById=function(a){var b={};return b[this._primaryKey]=a,this.remove(b)[0]},p.prototype.processQueue=function(a,b,c){var d,e,f=this,g=this._deferQueue[a],h=this._deferThreshold[a],i=this._deferTime[a];if(c=c||{deferred:!0},g.length){switch(d=g.length>h?g.splice(0,h):g.splice(0,g.length),e=f[a](d),a){case"insert":c.inserted=c.inserted||[],c.failed=c.failed||[],c.inserted=c.inserted.concat(e.inserted),c.failed=c.failed.concat(e.failed)}setTimeout(function(){f.processQueue.call(f,a,b,c)},i)}else b&&b(c),this._asyncComplete(a);this.isProcessingQueue()||this.deferEmit("queuesComplete")},p.prototype.isProcessingQueue=function(){var a;for(a in this._deferQueue)if(this._deferQueue.hasOwnProperty(a)&&this._deferQueue[a].length)return!0;return!1},p.prototype.insert=function(a,b,c){if(this.isDropped())throw this.logIdentifier()+" Cannot operate in a dropped state!";return"function"==typeof b?(c=b,b=this._data.length):void 0===b&&(b=this._data.length),a=this.transformIn(a),this._insertHandle(a,b,c)},p.prototype._insertHandle=function(a,b,c){var d,e,f,g=this._deferQueue.insert,h=this._deferThreshold.insert,i=[],j=[];if(a instanceof Array){if(this._deferredCalls&&a.length>h)return this._deferQueue.insert=g.concat(a),this._asyncPending("insert"),void this.processQueue("insert",c);for(f=0;f<a.length;f++)d=this._insert(a[f],b+f),d===!0?i.push(a[f]):j.push({doc:a[f],reason:d})}else d=this._insert(a,b),d===!0?i.push(a):j.push({doc:a,reason:d});return e={deferred:!1,inserted:i,failed:j},this._onInsert(i,j),c&&c(e),this._onChange(),this.emit("immediateChange",{type:"insert",data:i}),this.deferEmit("change",{type:"insert",data:i}),e},p.prototype._insert=function(a,b){if(a){var c,d,e,f,g=this,h=this.capped(),i=this.cappedSize();if(this.ensurePrimaryKey(a),c=this.insertIndexViolation(a),e=function(a){g._insertIntoIndexes(a),b>g._data.length&&(b=g._data.length),g._dataInsertAtIndex(b,a),h&&g._data.length>i&&g.removeById(g._data[0][g._primaryKey]),g.chainSend("insert",a,{index:b})},c)return"Index violation in index: "+c;if(g.willTrigger(g.TYPE_INSERT,g.PHASE_BEFORE)||g.willTrigger(g.TYPE_INSERT,g.PHASE_AFTER)){if(d={type:"insert"},g.processTrigger(d,g.TYPE_INSERT,g.PHASE_BEFORE,{},a)===!1)return"Trigger cancelled operation";e(a),g.willTrigger(g.TYPE_INSERT,g.PHASE_AFTER)&&(f=g.decouple(a),g.processTrigger(d,g.TYPE_INSERT,g.PHASE_AFTER,{},f))}else e(a);return!0}return"No document passed to insert"},p.prototype._dataInsertAtIndex=function(a,b){this._data.splice(a,0,b)},p.prototype._dataRemoveAtIndex=function(a){this._data.splice(a,1)},p.prototype._dataReplace=function(a){for(;this._data.length;)this._data.pop();this._data=this._data.concat(a)},p.prototype._insertIntoIndexes=function(a){var b,c,d=this._indexByName,e=this.jStringify(a);c=this._primaryIndex.uniqueSet(a[this._primaryKey],a),this._primaryCrc.uniqueSet(a[this._primaryKey],e),this._crcLookup.uniqueSet(e,a);for(b in d)d.hasOwnProperty(b)&&d[b].insert(a);return c},p.prototype._removeFromIndexes=function(a){var b,c=this._indexByName,d=this.jStringify(a);this._primaryIndex.unSet(a[this._primaryKey]),this._primaryCrc.unSet(a[this._primaryKey]),this._crcLookup.unSet(d);for(b in c)c.hasOwnProperty(b)&&c[b].remove(a)},p.prototype._updateIndexes=function(a,b){this._removeFromIndexes(a),this._insertIntoIndexes(b)},p.prototype._rebuildIndexes=function(){var a,b=this._indexByName;for(a in b)b.hasOwnProperty(a)&&b[a].rebuild()},p.prototype.subset=function(a,b){var c,d=this.find(a,b);return c=new p,c.db(this._db),c.subsetOf(this).primaryKey(this._primaryKey).setData(d),c},d.synthesize(p.prototype,"subsetOf"),p.prototype.isSubsetOf=function(a){return this._subsetOf===a},p.prototype.distinct=function(a,b,c){if(this.isDropped())throw this.logIdentifier()+" Cannot operate in a dropped state!";var d,e,f=this.find(b,c),g=new h(a),i={},j=[];for(e=0;e<f.length;e++)d=g.value(f[e])[0],d&&!i[d]&&(i[d]=!0,j.push(d));return j},p.prototype.findById=function(a,b){var c={};return c[this._primaryKey]=a,this.find(c,b)[0]},p.prototype.peek=function(a,b){var c,d,e=this._data,f=e.length,g=new p,h=typeof a;if("string"===h){for(c=0;f>c;c++)d=this.jStringify(e[c]),d.indexOf(a)>-1&&g.insert(e[c]);return g.find({},b)}return this.find(a,b)},p.prototype.explain=function(a,b){var c=this.find(a,b);return c.__fdbOp._data},p.prototype.options=function(a){return a=a||{},a.$decouple=void 0!==a.$decouple?a.$decouple:!0,a.$explain=void 0!==a.$explain?a.$explain:!1,a},p.prototype.find=function(a,b,c){return this.mongoEmulation()&&this.convertToFdb(a),c?(c("Callbacks for the find() operation are not yet implemented!",[]),[]):this._find.call(this,a,b,c)},p.prototype._find=function(a,b){if(this.isDropped())throw this.logIdentifier()+" Cannot operate in a dropped state!";a=a||{};var c,d,e,f,g,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,A,B,C,D,E,F,G,H,I,J,K,L=this._metrics.create("find"),M=this.primaryKey(),N=this,O=!0,P={},Q=[],R=[],S=[],T={},U={};if(b instanceof Array||(b=this.options(b)),K=function(c){return N._match(c,a,b,"and",T)},L.start(),a){if(a instanceof Array){for(J=this,A=0;A<a.length;A++)J=J.subset(a[A],b&&b[A]?b[A]:{});return J.find()}if(a.$findSub){if(!a.$findSub.$path)throw"$findSub missing $path property!";return this.findSub(a.$findSub.$query,a.$findSub.$path,a.$findSub.$subQuery,a.$findSub.$subOptions)}if(a.$findSubOne){if(!a.$findSubOne.$path)throw"$findSubOne missing $path property!";return this.findSubOne(a.$findSubOne.$query,a.$findSubOne.$path,a.$findSubOne.$subQuery,a.$findSubOne.$subOptions)}if(L.time("analyseQuery"),c=this._analyseQuery(N.decouple(a),b,L),L.time("analyseQuery"),L.data("analysis",c),c.hasJoin&&c.queriesJoin){for(L.time("joinReferences"),g=0;g<c.joinsOn.length;g++)k=c.joinsOn[g],j=new h(c.joinQueries[k]),i=j.value(a)[0],P[c.joinsOn[g]]=this._db.collection(c.joinsOn[g]).subset(i),delete a[c.joinQueries[k]];L.time("joinReferences")}if(c.indexMatch.length&&(!b||b&&!b.$skipIndex)?(L.data("index.potential",c.indexMatch),L.data("index.used",c.indexMatch[0].index),L.time("indexLookup"),e=c.indexMatch[0].lookup||[],L.time("indexLookup"),c.indexMatch[0].keyData.totalKeyCount===c.indexMatch[0].keyData.score&&(O=!1)):L.flag("usedIndex",!1),O&&(e&&e.length?(d=e.length,L.time("tableScan: "+d),e=e.filter(K)):(d=this._data.length,L.time("tableScan: "+d),e=this._data.filter(K)),L.time("tableScan: "+d)),b.$orderBy&&(L.time("sort"),e=this.sort(b.$orderBy,e),L.time("sort")),void 0!==b.$page&&void 0!==b.$limit&&(U.page=b.$page,U.pages=Math.ceil(e.length/b.$limit),U.records=e.length,b.$page&&b.$limit>0&&(L.data("cursor",U),e.splice(0,b.$page*b.$limit))),b.$skip&&(U.skip=b.$skip,e.splice(0,b.$skip),L.data("skip",b.$skip)),b.$limit&&e&&e.length>b.$limit&&(U.limit=b.$limit,e.length=b.$limit,L.data("limit",b.$limit)),b.$decouple&&(L.time("decouple"),e=this.decouple(e),L.time("decouple"),L.data("flag.decouple",!0)),b.$join){for(f=0;f<b.$join.length;f++)for(k in b.$join[f])if(b.$join[f].hasOwnProperty(k))for(x=k,l=P[k]?P[k]:this._db.collection(k),m=b.$join[f][k],y=0;y<e.length;y++){o={},q=!1,r=!1,v="";for(n in m)if(m.hasOwnProperty(n))if(w=m[n],"$"===n.substr(0,1))switch(n){case"$where":if(!w.$query&&!w.$options)throw'$join $where clause requires "$query" and / or "$options" keys to work!';w.$query&&(o=N._resolveDynamicQuery(w.$query,e[y])),w.$options&&(p=w.$options);break;case"$as":x=w;break;case"$multi":q=w;break;case"$require":r=w;break;case"$prefix":v=w}else o[n]=N._resolveDynamicQuery(w,e[y]);if(s=l.find(o,p),!r||r&&s[0])if("$root"===x){if(q!==!1)throw this.logIdentifier()+' Cannot combine [$as: "$root"] with [$multi: true] in $join clause!';t=s[0],u=e[y];for(D in t)t.hasOwnProperty(D)&&void 0===u[v+D]&&(u[v+D]=t[D])}else e[y][x]=q===!1?s[0]:s;else Q.push(e[y])}L.data("flag.join",!0)}if(Q.length){for(L.time("removalQueue"),A=0;A<Q.length;A++)z=e.indexOf(Q[A]),z>-1&&e.splice(z,1);L.time("removalQueue")}if(b.$transform){for(L.time("transform"),A=0;A<e.length;A++)e.splice(A,1,b.$transform(e[A]));L.time("transform"),L.data("flag.transform",!0)}this._transformEnabled&&this._transformOut&&(L.time("transformOut"),e=this.transformOut(e),L.time("transformOut")),L.data("results",e.length)}else e=[];if(!b.$aggregate){L.time("scanFields");for(A in b)b.hasOwnProperty(A)&&0!==A.indexOf("$")&&(1===b[A]?R.push(A):0===b[A]&&S.push(A));if(L.time("scanFields"),R.length||S.length){for(L.data("flag.limitFields",!0),L.data("limitFields.on",R),L.data("limitFields.off",S),L.time("limitFields"),A=0;A<e.length;A++){H=e[A];for(B in H)H.hasOwnProperty(B)&&(R.length&&B!==M&&-1===R.indexOf(B)&&delete H[B],S.length&&S.indexOf(B)>-1&&delete H[B])}L.time("limitFields")}if(b.$elemMatch){ L.data("flag.elemMatch",!0),L.time("projection-elemMatch");for(A in b.$elemMatch)if(b.$elemMatch.hasOwnProperty(A))for(E=new h(A),B=0;B<e.length;B++)if(F=E.value(e[B])[0],F&&F.length)for(C=0;C<F.length;C++)if(N._match(F[C],b.$elemMatch[A],b,"",{})){E.set(e[B],A,[F[C]]);break}L.time("projection-elemMatch")}if(b.$elemsMatch){L.data("flag.elemsMatch",!0),L.time("projection-elemsMatch");for(A in b.$elemsMatch)if(b.$elemsMatch.hasOwnProperty(A))for(E=new h(A),B=0;B<e.length;B++)if(F=E.value(e[B])[0],F&&F.length){for(G=[],C=0;C<F.length;C++)N._match(F[C],b.$elemsMatch[A],b,"",{})&&G.push(F[C]);E.set(e[B],A,G)}L.time("projection-elemsMatch")}}return b.$aggregate&&(L.data("flag.aggregate",!0),L.time("aggregate"),I=new h(b.$aggregate),e=I.value(e),L.time("aggregate")),L.stop(),e.__fdbOp=L,e.$cursor=U,e},p.prototype._resolveDynamicQuery=function(a,b){var c,d,e,f,g,i=this;if("string"==typeof a)return f="$$."===a.substr(0,3)?new h(a.substr(3,a.length-3)).value(b):new h(a).value(b),f.length>1?{$in:f}:f[0];c={};for(g in a)if(a.hasOwnProperty(g))switch(d=typeof a[g],e=a[g],d){case"string":"$$."===e.substr(0,3)?c[g]=new h(e.substr(3,e.length-3)).value(b)[0]:c[g]=e;break;case"object":c[g]=i._resolveDynamicQuery(e,b);break;default:c[g]=e}return c},p.prototype.findOne=function(){return this.find.apply(this,arguments)[0]},p.prototype.indexOf=function(a,b){var c,d=this.find(a,{$decouple:!1})[0];return d?!b||b&&!b.$orderBy?this._data.indexOf(d):(b.$decouple=!1,c=this.find(a,b),c.indexOf(d)):-1},p.prototype.indexOfDocById=function(a,b){var c,d;return c="object"!=typeof a?this._primaryIndex.get(a):this._primaryIndex.get(a[this._primaryKey]),c?!b||b&&!b.$orderBy?this._data.indexOf(c):(b.$decouple=!1,d=this.find({},b),d.indexOf(c)):-1},p.prototype.removeByIndex=function(a){var b,c;return b=this._data[a],void 0!==b?(b=this.decouple(b),c=b[this.primaryKey()],this.removeById(c)):!1},p.prototype.transform=function(a){return void 0!==a?("object"==typeof a?(void 0!==a.enabled&&(this._transformEnabled=a.enabled),void 0!==a.dataIn&&(this._transformIn=a.dataIn),void 0!==a.dataOut&&(this._transformOut=a.dataOut)):this._transformEnabled=a!==!1,this):{enabled:this._transformEnabled,dataIn:this._transformIn,dataOut:this._transformOut}},p.prototype.transformIn=function(a){if(this._transformEnabled&&this._transformIn){if(a instanceof Array){var b,c,d=[];for(c=0;c<a.length;c++)b=this._transformIn(a[c]),b instanceof Array?d=d.concat(b):d.push(b);return d}return this._transformIn(a)}return a},p.prototype.transformOut=function(a){if(this._transformEnabled&&this._transformOut){if(a instanceof Array){var b,c,d=[];for(c=0;c<a.length;c++)b=this._transformOut(a[c]),b instanceof Array?d=d.concat(b):d.push(b);return d}return this._transformOut(a)}return a},p.prototype.sort=function(a,b){var c=this,d=o.parse(a,!0);return d.length&&b.sort(function(a,b){var e,f,g=0;for(e=0;e<d.length;e++)if(f=d[e],1===f.value?g=c.sortAsc(o.get(a,f.path),o.get(b,f.path)):-1===f.value&&(g=c.sortDesc(o.get(a,f.path),o.get(b,f.path))),0!==g)return g;return g}),b},p.prototype._sort=function(a,b){var c,d=this,e=new h,f=e.parse(a,!0)[0];if(e.path(f.path),1===f.value)c=function(a,b){var c=e.value(a)[0],f=e.value(b)[0];return d.sortAsc(c,f)};else{if(-1!==f.value)throw this.logIdentifier()+" $orderBy clause has invalid direction: "+f.value+", accepted values are 1 or -1 for ascending or descending!";c=function(a,b){var c=e.value(a)[0],f=e.value(b)[0];return d.sortDesc(c,f)}}return b.sort(c)},p.prototype._analyseQuery=function(a,b,c){var d,e,f,g,i,j,k,l,m,n,o,p,q,r={queriesOn:[this._name],indexMatch:[],hasJoin:!1,queriesJoin:!1,joinQueries:{},query:a,options:b},s=[],t=[];if(c.time("checkIndexes"),m=new h,n=m.parseArr(a,{ignore:/\$/,verbose:!0}).length){void 0!==a[this._primaryKey]&&(o=typeof a[this._primaryKey],("string"===o||"number"===o||a[this._primaryKey]instanceof Array)&&(c.time("checkIndexMatch: Primary Key"),p=this._primaryIndex.lookup(a,b),r.indexMatch.push({lookup:p,keyData:{matchedKeys:[this._primaryKey],totalKeyCount:n,score:1},index:this._primaryIndex}),c.time("checkIndexMatch: Primary Key")));for(q in this._indexById)if(this._indexById.hasOwnProperty(q)&&(j=this._indexById[q],k=j.name(),c.time("checkIndexMatch: "+k),i=j.match(a,b),i.score>0&&(l=j.lookup(a,b),r.indexMatch.push({lookup:l,keyData:i,index:j})),c.time("checkIndexMatch: "+k),i.score===n))break;c.time("checkIndexes"),r.indexMatch.length>1&&(c.time("findOptimalIndex"),r.indexMatch.sort(function(a,b){return a.keyData.score>b.keyData.score?-1:a.keyData.score<b.keyData.score?1:a.keyData.score===b.keyData.score?a.lookup.length-b.lookup.length:void 0}),c.time("findOptimalIndex"))}if(b.$join){for(r.hasJoin=!0,d=0;d<b.$join.length;d++)for(e in b.$join[d])b.$join[d].hasOwnProperty(e)&&(s.push(e),"$as"in b.$join[d][e]?t.push(b.$join[d][e].$as):t.push(e));for(g=0;g<t.length;g++)f=this._queryReferencesCollection(a,t[g],""),f&&(r.joinQueries[s[g]]=f,r.queriesJoin=!0);r.joinsOn=s,r.queriesOn=r.queriesOn.concat(s)}return r},p.prototype._queryReferencesCollection=function(a,b,c){var d;for(d in a)if(a.hasOwnProperty(d)){if(d===b)return c&&(c+="."),c+d;if("object"==typeof a[d])return c&&(c+="."),c+=d,this._queryReferencesCollection(a[d],b,c)}return!1},p.prototype.count=function(a,b){return a?this.find(a,b).length:this._data.length},p.prototype.findSub=function(a,b,c,d){return this._findSub(this.find(a),b,c,d)},p.prototype._findSub=function(a,b,c,d){var e,f,g,i=new h(b),j=a.length,k=new p("__FDB_temp_"+this.objectId()).db(this._db),l={parents:j,subDocTotal:0,subDocs:[],pathFound:!1,err:""};for(d=d||{},e=0;j>e;e++)if(f=i.value(a[e])[0]){if(k.setData(f),g=k.find(c,d),d.returnFirst&&g.length)return g[0];d.$split?l.subDocs.push(g):l.subDocs=l.subDocs.concat(g),l.subDocTotal+=g.length,l.pathFound=!0}return k.drop(),l.pathFound||(l.err="No objects found in the parent documents with a matching path of: "+b),d.$stats?l:l.subDocs},p.prototype.findSubOne=function(a,b,c,d){return this.findSub(a,b,c,d)[0]},p.prototype.insertIndexViolation=function(a){var b,c,d,e=this._indexByName;if(this._primaryIndex.get(a[this._primaryKey]))b=this._primaryIndex;else for(c in e)if(e.hasOwnProperty(c)&&(d=e[c],d.unique()&&d.violation(a))){b=d;break}return b?b.name():!1},p.prototype.ensureIndex=function(a,b){if(this.isDropped())throw this.logIdentifier()+" Cannot operate in a dropped state!";this._indexByName=this._indexByName||{},this._indexById=this._indexById||{};var c,d={start:(new Date).getTime()};if(b)switch(b.type){case"hashed":c=new i(a,b,this);break;case"btree":c=new j(a,b,this);break;case"2d":c=new k(a,b,this);break;default:c=new i(a,b,this)}else c=new i(a,b,this);return this._indexByName[c.name()]?{err:"Index with that name already exists"}:(c.rebuild(),this._indexByName[c.name()]=c,this._indexById[c.id()]=c,d.end=(new Date).getTime(),d.total=d.end-d.start,this._lastOp={type:"ensureIndex",stats:{time:d}},{index:c,id:c.id(),name:c.name(),state:c.state()})},p.prototype.index=function(a){return this._indexByName?this._indexByName[a]:void 0},p.prototype.lastOp=function(){return this._metrics.list()},p.prototype.diff=function(a){var b,c,d,e,f={insert:[],update:[],remove:[]},g=this.primaryKey();if(g!==a.primaryKey())throw this.logIdentifier()+" Diffing requires that both collections have the same primary key!";for(b=a._data;b&&!(b instanceof Array);)a=b,b=a._data;for(e=b.length,c=0;e>c;c++)d=b[c],this._primaryIndex.get(d[g])?this._primaryCrc.get(d[g])!==a._primaryCrc.get(d[g])&&f.update.push(d):f.insert.push(d);for(b=this._data,e=b.length,c=0;e>c;c++)d=b[c],a._primaryIndex.get(d[g])||f.remove.push(d);return f},p.prototype.collateAdd=new m({"object, string":function(a,b){var c=this;c.collateAdd(a,function(d){var e,f;switch(d.type){case"insert":b?(e={$push:{}},e.$push[b]=c.decouple(d.data),c.update({},e)):c.insert(d.data);break;case"update":b?(e={},f={},e[b]=d.data.query,f[b+".$"]=d.data.update,c.update(e,f)):c.update(d.data.query,d.data.update);break;case"remove":b?(e={$pull:{}},e.$pull[b]={},e.$pull[b][c.primaryKey()]=d.data.dataSet[0][a.primaryKey()],c.update({},e)):c.remove(d.data)}})},"object, function":function(a,b){if("string"==typeof a&&(a=this._db.collection(a,{autoCreate:!1,throwError:!1})),a)return this._collate=this._collate||{},this._collate[a.name()]=new n(a,this,b),this;throw"Cannot collate from a non-existent collection!"}}),p.prototype.collateRemove=function(a){if("object"==typeof a&&(a=a.name()),a)return this._collate[a].drop(),delete this._collate[a],this;throw"No collection name passed to collateRemove() or collection not found!"},e.prototype.collection=new m({"":function(){return this.$main.call(this,{name:this.objectId()})},object:function(a){return a instanceof p?"droppped"!==a.state()?a:this.$main.call(this,{name:a.name()}):this.$main.call(this,a)},string:function(a){return this.$main.call(this,{name:a})},"string, string":function(a,b){return this.$main.call(this,{name:a,primaryKey:b})},"string, object":function(a,b){return b.name=a,this.$main.call(this,b)},"string, string, object":function(a,b,c){return c.name=a,c.primaryKey=b,this.$main.call(this,c)},$main:function(a){var b=this,c=a.name;if(c){if(this._collection[c])return this._collection[c];if(a&&a.autoCreate===!1){if(a&&a.throwError!==!1)throw this.logIdentifier()+" Cannot get collection "+c+" because it does not exist and auto-create has been disabled!";return}if(this.debug()&&console.log(this.logIdentifier()+" Creating collection "+c),this._collection[c]=this._collection[c]||new p(c,a).db(this),this._collection[c].mongoEmulation(this.mongoEmulation()),void 0!==a.primaryKey&&this._collection[c].primaryKey(a.primaryKey),void 0!==a.capped){if(void 0===a.size)throw this.logIdentifier()+" Cannot create a capped collection without specifying a size!";this._collection[c].capped(a.capped),this._collection[c].cappedSize(a.size)}return b._collection[c].on("change",function(){b.emit("change",b._collection[c],"collection",c)}),b.emit("create",b._collection[c],"collection",c),this._collection[c]}if(!a||a&&a.throwError!==!1)throw this.logIdentifier()+" Cannot get collection with undefined name!"}}),e.prototype.collectionExists=function(a){return Boolean(this._collection[a])},e.prototype.collections=function(a){var b,c,d=[],e=this._collection;a&&(a instanceof RegExp||(a=new RegExp(a)));for(c in e)e.hasOwnProperty(c)&&(b=e[c],a?a.exec(c)&&d.push({name:c,count:b.count(),linked:void 0!==b.isLinked?b.isLinked():!1}):d.push({name:c,count:b.count(),linked:void 0!==b.isLinked?b.isLinked():!1}));return d.sort(function(a,b){return a.name.localeCompare(b.name)}),d},d.finishModule("Collection"),b.exports=p},{"./Crc":9,"./Index2d":15,"./IndexBinaryTree":16,"./IndexHashMap":17,"./KeyValueStore":18,"./Metrics":19,"./Overload":32,"./Path":34,"./ReactorIO":38,"./Shared":40}],7:[function(a,b,c){"use strict";var d,e,f,g;d=a("./Shared");var h=function(){this.init.apply(this,arguments)};h.prototype.init=function(a){var b=this;b._name=a,b._data=new g("__FDB__cg_data_"+b._name),b._collections=[],b._view=[]},d.addModule("CollectionGroup",h),d.mixin(h.prototype,"Mixin.Common"),d.mixin(h.prototype,"Mixin.ChainReactor"),d.mixin(h.prototype,"Mixin.Constants"),d.mixin(h.prototype,"Mixin.Triggers"),d.mixin(h.prototype,"Mixin.Tags"),g=a("./Collection"),e=d.modules.Db,f=d.modules.Db.prototype.init,h.prototype.on=function(){this._data.on.apply(this._data,arguments)},h.prototype.off=function(){this._data.off.apply(this._data,arguments)},h.prototype.emit=function(){this._data.emit.apply(this._data,arguments)},h.prototype.primaryKey=function(a){return void 0!==a?(this._primaryKey=a,this):this._primaryKey},d.synthesize(h.prototype,"state"),d.synthesize(h.prototype,"db"),d.synthesize(h.prototype,"name"),h.prototype.addCollection=function(a){if(a&&-1===this._collections.indexOf(a)){if(this._collections.length){if(this._primaryKey!==a.primaryKey())throw this.logIdentifier()+" All collections in a collection group must have the same primary key!"}else this.primaryKey(a.primaryKey());this._collections.push(a),a._groups=a._groups||[],a._groups.push(this),a.chain(this),a.on("drop",function(){if(a._groups&&a._groups.length){var b,c=[];for(b=0;b<a._groups.length;b++)c.push(a._groups[b]);for(b=0;b<c.length;b++)a._groups[b].removeCollection(a)}delete a._groups}),this._data.insert(a.find())}return this},h.prototype.removeCollection=function(a){if(a){var b,c=this._collections.indexOf(a);-1!==c&&(a.unChain(this),this._collections.splice(c,1),a._groups=a._groups||[],b=a._groups.indexOf(this),-1!==b&&a._groups.splice(b,1),a.off("drop")),0===this._collections.length&&delete this._primaryKey}return this},h.prototype._chainHandler=function(a){switch(a.type){case"setData":a.data=this.decouple(a.data),this._data.remove(a.options.oldData),this._data.insert(a.data);break;case"insert":a.data=this.decouple(a.data),this._data.insert(a.data);break;case"update":this._data.update(a.data.query,a.data.update,a.options);break;case"remove":this._data.remove(a.data.query,a.options)}},h.prototype.insert=function(){this._collectionsRun("insert",arguments)},h.prototype.update=function(){this._collectionsRun("update",arguments)},h.prototype.updateById=function(){this._collectionsRun("updateById",arguments)},h.prototype.remove=function(){this._collectionsRun("remove",arguments)},h.prototype._collectionsRun=function(a,b){for(var c=0;c<this._collections.length;c++)this._collections[c][a].apply(this._collections[c],b)},h.prototype.find=function(a,b){return this._data.find(a,b)},h.prototype.removeById=function(a){for(var b=0;b<this._collections.length;b++)this._collections[b].removeById(a)},h.prototype.subset=function(a,b){var c=this.find(a,b);return(new g).subsetOf(this).primaryKey(this._primaryKey).setData(c)},h.prototype.drop=function(a){if(!this.isDropped()){var b,c,d;if(this._debug&&console.log(this.logIdentifier()+" Dropping"),this._state="dropped",this._collections&&this._collections.length)for(c=[].concat(this._collections),b=0;b<c.length;b++)this.removeCollection(c[b]);if(this._view&&this._view.length)for(d=[].concat(this._view),b=0;b<d.length;b++)this._removeView(d[b]);this.emit("drop",this),delete this._listeners,a&&a(!1,!0)}return!0},e.prototype.init=function(){this._collectionGroup={},f.apply(this,arguments)},e.prototype.collectionGroup=function(a){return a?a instanceof h?a:(this._collectionGroup[a]=this._collectionGroup[a]||new h(a).db(this),this._collectionGroup[a]):this._collectionGroup},e.prototype.collectionGroups=function(){var a,b=[];for(a in this._collectionGroup)this._collectionGroup.hasOwnProperty(a)&&b.push({name:a});return b},b.exports=h},{"./Collection":6,"./Shared":40}],8:[function(a,b,c){"use strict";var d,e,f,g,h=[];d=a("./Shared"),g=a("./Overload");var i=function(a){this.init.apply(this,arguments)};i.prototype.init=function(a){this._db={},this._debug={},this._name=a||"ForerunnerDB",h.push(this)},i.prototype.instantiatedCount=function(){return h.length},i.prototype.instances=function(a){return void 0!==a?h[a]:h},i.prototype.namedInstances=function(a){var b,c;{if(void 0===a){for(c=[],b=0;b<h.length;b++)c.push(h[b].name);return c}for(b=0;b<h.length;b++)if(h[b].name===a)return h[b]}},i.prototype.moduleLoaded=new g({string:function(a){if(void 0!==a){a=a.replace(/ /g,"");var b,c=a.split(",");for(b=0;b<c.length;b++)if(!d.modules[c[b]])return!1;return!0}return!1},"string, function":function(a,b){if(void 0!==a){a=a.replace(/ /g,"");var c,e=a.split(",");for(c=0;c<e.length;c++)if(!d.modules[e[c]])return!1;b&&b()}},"array, function":function(a,b){var c,e;for(e=0;e<a.length;e++)if(c=a[e],void 0!==c){c=c.replace(/ /g,"");var f,g=c.split(",");for(f=0;f<g.length;f++)if(!d.modules[g[f]])return!1}b&&b()},"string, function, function":function(a,b,c){if(void 0!==a){a=a.replace(/ /g,"");var e,f=a.split(",");for(e=0;e<f.length;e++)if(!d.modules[f[e]])return c(),!1;b()}}}),i.prototype.version=function(a,b){return void 0!==a?0===d.version.indexOf(a)?(b&&b(),!0):!1:d.version},i.moduleLoaded=i.prototype.moduleLoaded,i.version=i.prototype.version,i.instances=i.prototype.instances,i.instantiatedCount=i.prototype.instantiatedCount,i.shared=d,i.prototype.shared=d,d.addModule("Core",i),d.mixin(i.prototype,"Mixin.Common"),d.mixin(i.prototype,"Mixin.Constants"),e=a("./Db.js"),f=a("./Metrics.js"),d.synthesize(i.prototype,"name"),d.synthesize(i.prototype,"mongoEmulation"),i.prototype._isServer=!1,i.prototype.isClient=function(){return!this._isServer},i.prototype.isServer=function(){return this._isServer},i.prototype.collection=function(){throw"ForerunnerDB's instantiation has changed since version 1.3.36 to support multiple database instances. Please see the readme.md file for the minor change you have to make to get your project back up and running, or see the issue related to this change at https://github.com/Irrelon/ForerunnerDB/issues/44"},b.exports=i},{"./Db.js":10,"./Metrics.js":19,"./Overload":32,"./Shared":40}],9:[function(a,b,c){"use strict";var d=function(){var a,b,c,d=[];for(b=0;256>b;b++){for(a=b,c=0;8>c;c++)a=1&a?3988292384^a>>>1:a>>>1;d[b]=a}return d}();b.exports=function(a){var b,c=-1;for(b=0;b<a.length;b++)c=c>>>8^d[255&(c^a.charCodeAt(b))];return(-1^c)>>>0}},{}],10:[function(a,b,c){"use strict";var d,e,f,g,h,i;d=a("./Shared"),i=a("./Overload");var j=function(a,b){this.init.apply(this,arguments)};j.prototype.init=function(a,b){this.core(b),this._primaryKey="_id",this._name=a,this._collection={},this._debug={}},d.addModule("Db",j),j.prototype.moduleLoaded=new i({string:function(a){if(void 0!==a){a=a.replace(/ /g,"");var b,c=a.split(",");for(b=0;b<c.length;b++)if(!d.modules[c[b]])return!1;return!0}return!1},"string, function":function(a,b){if(void 0!==a){a=a.replace(/ /g,"");var c,e=a.split(",");for(c=0;c<e.length;c++)if(!d.modules[e[c]])return!1;b&&b()}},"string, function, function":function(a,b,c){if(void 0!==a){a=a.replace(/ /g,"");var e,f=a.split(",");for(e=0;e<f.length;e++)if(!d.modules[f[e]])return c(),!1;b()}}}),j.prototype.version=function(a,b){return void 0!==a?0===d.version.indexOf(a)?(b&&b(),!0):!1:d.version},j.moduleLoaded=j.prototype.moduleLoaded,j.version=j.prototype.version,j.shared=d,j.prototype.shared=d,d.addModule("Db",j),d.mixin(j.prototype,"Mixin.Common"),d.mixin(j.prototype,"Mixin.ChainReactor"),d.mixin(j.prototype,"Mixin.Constants"),d.mixin(j.prototype,"Mixin.Tags"),e=d.modules.Core,f=a("./Collection.js"),g=a("./Metrics.js"),h=a("./Crc.js"),j.prototype._isServer=!1,d.synthesize(j.prototype,"core"),d.synthesize(j.prototype,"primaryKey"),d.synthesize(j.prototype,"state"),d.synthesize(j.prototype,"name"),d.synthesize(j.prototype,"mongoEmulation"),j.prototype.isClient=function(){return!this._isServer},j.prototype.isServer=function(){return this._isServer},j.prototype.crc=h,j.prototype.isClient=function(){return!this._isServer},j.prototype.isServer=function(){return this._isServer},j.prototype.arrayToCollection=function(a){return(new f).setData(a)},j.prototype.on=function(a,b){return this._listeners=this._listeners||{},this._listeners[a]=this._listeners[a]||[],this._listeners[a].push(b),this},j.prototype.off=function(a,b){if(a in this._listeners){var c=this._listeners[a],d=c.indexOf(b);d>-1&&c.splice(d,1)}return this},j.prototype.emit=function(a,b){if(this._listeners=this._listeners||{},a in this._listeners){var c,d=this._listeners[a],e=d.length;for(c=0;e>c;c++)d[c].apply(this,Array.prototype.slice.call(arguments,1))}return this},j.prototype.peek=function(a){var b,c,d=[],e=typeof a;for(b in this._collection)this._collection.hasOwnProperty(b)&&(c=this._collection[b],d="string"===e?d.concat(c.peek(a)):d.concat(c.find(a)));return d},j.prototype.peek=function(a){var b,c,d=[],e=typeof a;for(b in this._collection)this._collection.hasOwnProperty(b)&&(c=this._collection[b],d="string"===e?d.concat(c.peek(a)):d.concat(c.find(a)));return d},j.prototype.peekCat=function(a){var b,c,d,e={},f=typeof a;for(b in this._collection)this._collection.hasOwnProperty(b)&&(c=this._collection[b],"string"===f?(d=c.peek(a),d&&d.length&&(e[c.name()]=d)):(d=c.find(a),d&&d.length&&(e[c.name()]=d)));return e},j.prototype.drop=new i({"":function(){if(!this.isDropped()){var a,b=this.collections(),c=b.length;for(this._state="dropped",a=0;c>a;a++)this.collection(b[a].name).drop(),delete this._collection[b[a].name];this.emit("drop",this),delete this._listeners,delete this._core._db[this._name]}return!0},"function":function(a){if(!this.isDropped()){var b,c=this.collections(),d=c.length,e=0,f=function(){e++,e===d&&a&&a()};for(this._state="dropped",b=0;d>b;b++)this.collection(c[b].name).drop(f),delete this._collection[c[b].name];this.emit("drop",this),delete this._listeners,delete this._core._db[this._name]}return!0},"boolean":function(a){if(!this.isDropped()){var b,c=this.collections(),d=c.length;for(this._state="dropped",b=0;d>b;b++)this.collection(c[b].name).drop(a),delete this._collection[c[b].name];this.emit("drop",this),delete this._listeners,delete this._core._db[this._name]}return!0},"boolean, function":function(a,b){if(!this.isDropped()){var c,d=this.collections(),e=d.length,f=0,g=function(){f++,f===e&&b&&b()};for(this._state="dropped",c=0;e>c;c++)this.collection(d[c].name).drop(a,g),delete this._collection[d[c].name];this.emit("drop",this),delete this._listeners,delete this._core._db[this._name]}return!0}}),e.prototype.db=function(a){return a instanceof j?a:(a||(a=this.objectId()),this._db[a]=this._db[a]||new j(a,this),this._db[a].mongoEmulation(this.mongoEmulation()),this._db[a])},e.prototype.databases=function(a){var b,c,d,e=[];a&&(a instanceof RegExp||(a=new RegExp(a)));for(d in this._db)this._db.hasOwnProperty(d)&&(c=!0,a&&(a.exec(d)||(c=!1)),c&&(b={name:d,children:[]},this.shared.moduleExists("Collection")&&b.children.push({module:"collection",moduleName:"Collections",count:this._db[d].collections().length}),this.shared.moduleExists("CollectionGroup")&&b.children.push({module:"collectionGroup",moduleName:"Collection Groups",count:this._db[d].collectionGroups().length}),this.shared.moduleExists("Document")&&b.children.push({module:"document",moduleName:"Documents",count:this._db[d].documents().length}),this.shared.moduleExists("Grid")&&b.children.push({module:"grid",moduleName:"Grids",count:this._db[d].grids().length}),this.shared.moduleExists("Overview")&&b.children.push({module:"overview",moduleName:"Overviews",count:this._db[d].overviews().length}),this.shared.moduleExists("View")&&b.children.push({module:"view",moduleName:"Views",count:this._db[d].views().length}),e.push(b)));return e.sort(function(a,b){return a.name.localeCompare(b.name)}),e},d.finishModule("Db"),b.exports=j},{"./Collection.js":6,"./Crc.js":9,"./Metrics.js":19,"./Overload":32,"./Shared":40}],11:[function(a,b,c){"use strict";var d,e,f;d=a("./Shared");var g=function(){this.init.apply(this,arguments)};g.prototype.init=function(a){this._name=a,this._data={}},d.addModule("Document",g),d.mixin(g.prototype,"Mixin.Common"),d.mixin(g.prototype,"Mixin.Events"),d.mixin(g.prototype,"Mixin.ChainReactor"),d.mixin(g.prototype,"Mixin.Constants"),d.mixin(g.prototype,"Mixin.Triggers"),d.mixin(g.prototype,"Mixin.Matching"),d.mixin(g.prototype,"Mixin.Updating"),d.mixin(g.prototype,"Mixin.Tags"),e=a("./Collection"),f=d.modules.Db,d.synthesize(g.prototype,"state"),d.synthesize(g.prototype,"db"),d.synthesize(g.prototype,"name"),g.prototype.setData=function(a,b){var c,d;if(a){if(b=b||{$decouple:!0},b&&b.$decouple===!0&&(a=this.decouple(a)),this._linked){d={};for(c in this._data)"jQuery"!==c.substr(0,6)&&this._data.hasOwnProperty(c)&&void 0===a[c]&&(d[c]=1);a.$unset=d,this.updateObject(this._data,a,{})}else this._data=a;this.deferEmit("change",{type:"setData",data:this.decouple(this._data)})}return this},g.prototype.find=function(a,b){var c;return c=b&&b.$decouple===!1?this._data:this.decouple(this._data)},g.prototype.update=function(a,b,c){var d=this.updateObject(this._data,b,a,c);d&&this.deferEmit("change",{type:"update",data:this.decouple(this._data)})},g.prototype.updateObject=e.prototype.updateObject,g.prototype._isPositionalKey=function(a){return".$"===a.substr(a.length-2,2)},g.prototype._updateProperty=function(a,b,c){this._linked?(window.jQuery.observable(a).setProperty(b,c),this.debug()&&console.log(this.logIdentifier()+' Setting data-bound document property "'+b+'"')):(a[b]=c,this.debug()&&console.log(this.logIdentifier()+' Setting non-data-bound document property "'+b+'"'))},g.prototype._updateIncrement=function(a,b,c){this._linked?window.jQuery.observable(a).setProperty(b,a[b]+c):a[b]+=c},g.prototype._updateSpliceMove=function(a,b,c){this._linked?(window.jQuery.observable(a).move(b,c),this.debug()&&console.log(this.logIdentifier()+' Moving data-bound document array index from "'+b+'" to "'+c+'"')):(a.splice(c,0,a.splice(b,1)[0]),this.debug()&&console.log(this.logIdentifier()+' Moving non-data-bound document array index from "'+b+'" to "'+c+'"'))},g.prototype._updateSplicePush=function(a,b,c){a.length>b?this._linked?window.jQuery.observable(a).insert(b,c):a.splice(b,0,c):this._linked?window.jQuery.observable(a).insert(c):a.push(c)},g.prototype._updatePush=function(a,b){this._linked?window.jQuery.observable(a).insert(b):a.push(b)},g.prototype._updatePull=function(a,b){this._linked?window.jQuery.observable(a).remove(b):a.splice(b,1)},g.prototype._updateMultiply=function(a,b,c){this._linked?window.jQuery.observable(a).setProperty(b,a[b]*c):a[b]*=c},g.prototype._updateRename=function(a,b,c){var d=a[b];this._linked?(window.jQuery.observable(a).setProperty(c,d),window.jQuery.observable(a).removeProperty(b)):(a[c]=d,delete a[b])},g.prototype._updateUnset=function(a,b){this._linked?window.jQuery.observable(a).removeProperty(b):delete a[b]},g.prototype.drop=function(a){return this.isDropped()?!0:this._db&&this._name&&this._db&&this._db._document&&this._db._document[this._name]?(this._state="dropped",delete this._db._document[this._name],delete this._data,this.emit("drop",this),a&&a(!1,!0),delete this._listeners,!0):!1},f.prototype.document=function(a){if(a){if(a instanceof g){if("droppped"!==a.state())return a;a=a.name()}return this._document=this._document||{},this._document[a]=this._document[a]||new g(a).db(this),this._document[a]}return this._document},f.prototype.documents=function(){var a,b,c=[];for(b in this._document)this._document.hasOwnProperty(b)&&(a=this._document[b],c.push({name:b,linked:void 0!==a.isLinked?a.isLinked():!1}));return c},d.finishModule("Document"),b.exports=g},{"./Collection":6,"./Shared":40}],12:[function(a,b,c){"use strict";var d,e,f,g;d=[16,8,4,2,1],e="0123456789bcdefghjkmnpqrstuvwxyz",f={right:{even:"bc01fg45238967deuvhjyznpkmstqrwx"},left:{even:"238967debc01fg45kmstqrwxuvhjyznp"},top:{even:"p0r21436x8zb9dcf5h7kjnmqesgutwvy"},bottom:{even:"14365h7k9dcfesgujnmqp0r2twvyx8zb"}},g={right:{even:"bcfguvyz"},left:{even:"0145hjnp"},top:{even:"prxz"},bottom:{even:"028b"}},f.bottom.odd=f.left.even,f.top.odd=f.right.even,f.left.odd=f.bottom.even,f.right.odd=f.top.even,g.bottom.odd=g.left.even,g.top.odd=g.right.even,g.left.odd=g.bottom.even,g.right.odd=g.top.even;var h=function(){};h.prototype.refineInterval=function(a,b,c){b&c?a[0]=(a[0]+a[1])/2:a[1]=(a[0]+a[1])/2},h.prototype.calculateNeighbours=function(a,b){var c;return b&&"object"!==b.type?(c=[],c[4]=a,c[3]=this.calculateAdjacent(a,"left"),c[5]=this.calculateAdjacent(a,"right"),c[1]=this.calculateAdjacent(a,"top"),c[7]=this.calculateAdjacent(a,"bottom"),c[0]=this.calculateAdjacent(c[3],"top"),c[2]=this.calculateAdjacent(c[5],"top"),c[6]=this.calculateAdjacent(c[3],"bottom"),c[8]=this.calculateAdjacent(c[5],"bottom")):(c={center:a,left:this.calculateAdjacent(a,"left"),right:this.calculateAdjacent(a,"right"),top:this.calculateAdjacent(a,"top"),bottom:this.calculateAdjacent(a,"bottom")},c.topLeft=this.calculateAdjacent(c.left,"top"),c.topRight=this.calculateAdjacent(c.right,"top"),c.bottomLeft=this.calculateAdjacent(c.left,"bottom"),c.bottomRight=this.calculateAdjacent(c.right,"bottom")),c},h.prototype.calculateAdjacent=function(a,b){a=a.toLowerCase();var c=a.charAt(a.length-1),d=a.length%2?"odd":"even",h=a.substring(0,a.length-1);return-1!==g[b][d].indexOf(c)&&(h=this.calculateAdjacent(h,b)),h+e[f[b][d].indexOf(c)]},h.prototype.decode=function(a){var b,c,f,g,h,i,j,k=1,l=[],m=[];for(l[0]=-90,l[1]=90,m[0]=-180,m[1]=180,i=90,j=180,b=0;b<a.length;b++)for(c=a[b],f=e.indexOf(c),g=0;5>g;g++)h=d[g],k?(j/=2,this.refineInterval(m,f,h)):(i/=2,this.refineInterval(l,f,h)),k=!k;return l[2]=(l[0]+l[1])/2,m[2]=(m[0]+m[1])/2,{latitude:l,longitude:m}},h.prototype.encode=function(a,b,c){var f,g=1,h=[],i=[],j=0,k=0,l="";for(c||(c=12),h[0]=-90,h[1]=90,i[0]=-180,i[1]=180;l.length<c;)g?(f=(i[0]+i[1])/2,b>f?(k|=d[j],i[0]=f):i[1]=f):(f=(h[0]+h[1])/2,a>f?(k|=d[j],h[0]=f):h[1]=f),g=!g,4>j?j++:(l+=e[k],j=0,k=0);return l},b.exports=h},{}],13:[function(a,b,c){"use strict";var d,e,f,g,h,i,j,k;d=a("./Shared");var l=function(a,b,c){this.init.apply(this,arguments)};l.prototype.init=function(a,b,c){var d=this;this._selector=a,this._template=b,this._options=c||{},this._debug={},this._id=this.objectId(),this._collectionDroppedWrap=function(){d._collectionDropped.apply(d,arguments)}},d.addModule("Grid",l),d.mixin(l.prototype,"Mixin.Common"),d.mixin(l.prototype,"Mixin.ChainReactor"),d.mixin(l.prototype,"Mixin.Constants"),d.mixin(l.prototype,"Mixin.Triggers"),d.mixin(l.prototype,"Mixin.Events"),d.mixin(l.prototype,"Mixin.Tags"),f=a("./Collection"),g=a("./CollectionGroup"),h=a("./View"),k=a("./ReactorIO"),i=f.prototype.init,e=d.modules.Db,j=e.prototype.init,d.synthesize(l.prototype,"state"),d.synthesize(l.prototype,"name"),l.prototype.insert=function(){this._from.insert.apply(this._from,arguments)},l.prototype.update=function(){this._from.update.apply(this._from,arguments)},l.prototype.updateById=function(){this._from.updateById.apply(this._from,arguments)},l.prototype.remove=function(){this._from.remove.apply(this._from,arguments)},l.prototype.from=function(a){return void 0!==a&&(this._from&&(this._from.off("drop",this._collectionDroppedWrap),this._from._removeGrid(this)),"string"==typeof a&&(a=this._db.collection(a)),this._from=a,this._from.on("drop",this._collectionDroppedWrap),this.refresh()),this},d.synthesize(l.prototype,"db",function(a){return a&&this.debug(a.debug()),this.$super.apply(this,arguments)}),l.prototype._collectionDropped=function(a){a&&delete this._from},l.prototype.drop=function(a){return this.isDropped()?!0:this._from?(this._from.unlink(this._selector,this.template()),this._from.off("drop",this._collectionDroppedWrap),this._from._removeGrid(this),(this.debug()||this._db&&this._db.debug())&&console.log(this.logIdentifier()+" Dropping grid "+this._selector),this._state="dropped",this._db&&this._selector&&delete this._db._grid[this._selector],this.emit("drop",this),a&&a(!1,!0),delete this._selector,delete this._template,delete this._from,delete this._db,delete this._listeners,!0):!1},l.prototype.template=function(a){return void 0!==a?(this._template=a,this):this._template},l.prototype._sortGridClick=function(a){var b,c=window.jQuery(a.currentTarget),e=c.attr("data-grid-sort")||"",f=-1===parseInt(c.attr("data-grid-dir")||"-1",10)?1:-1,g=e.split(","),h={};for(window.jQuery(this._selector).find("[data-grid-dir]").removeAttr("data-grid-dir"),c.attr("data-grid-dir",f),b=0;b<g.length;b++)h[g]=f;d.mixin(h,this._options.$orderBy),this._from.orderBy(h),this.emit("sort",h)},l.prototype.refresh=function(){if(this._from){if(!this._from.link)throw"Grid requires the AutoBind module in order to operate!";var a=this,b=window.jQuery(this._selector),c=function(){a._sortGridClick.apply(a,arguments)};if(b.html(""),a._from.orderBy&&b.off("click","[data-grid-sort]",c),a._from.query&&b.off("click","[data-grid-filter]",c),a._options.$wrap=a._options.$wrap||"gridRow",a._from.link(a._selector,a.template(),a._options),a._from.orderBy&&b.on("click","[data-grid-sort]",c),a._from.query){var d={};b.find("[data-grid-filter]").each(function(c,e){e=window.jQuery(e);var f,g,h,i,j=e.attr("data-grid-filter"),k=e.attr("data-grid-vartype"),l={},m=e.html(),n=a._db.view("tmpGridFilter_"+a._id+"_"+j); l[j]=1,i={$distinct:l},n.query(i).orderBy(l).from(a._from._from),h=['<div class="dropdown" id="'+a._id+"_"+j+'">','<button class="btn btn-default dropdown-toggle" type="button" id="'+a._id+"_"+j+'_dropdownButton" data-toggle="dropdown" aria-expanded="true">',m+' <span class="caret"></span>',"</button>","</div>"],f=window.jQuery(h.join("")),g=window.jQuery('<ul class="dropdown-menu" role="menu" id="'+a._id+"_"+j+'_dropdownMenu"></ul>'),f.append(g),e.html(f),n.link(g,{template:['<li role="presentation" class="input-group" style="width: 240px; padding-left: 10px; padding-right: 10px; padding-top: 5px;">','<input type="search" class="form-control gridFilterSearch" placeholder="Search...">','<span class="input-group-btn">','<button class="btn btn-default gridFilterClearSearch" type="button"><span class="glyphicon glyphicon-remove-circle glyphicons glyphicons-remove"></span></button>',"</span>","</li>",'<li role="presentation" class="divider"></li>','<li role="presentation" data-val="$all">','<a role="menuitem" tabindex="-1">','<input type="checkbox" checked>&nbsp;All',"</a>","</li>",'<li role="presentation" class="divider"></li>',"{^{for options}}",'<li role="presentation" data-link="data-val{:'+j+'}">','<a role="menuitem" tabindex="-1">','<input type="checkbox">&nbsp;{^{:'+j+"}}","</a>","</li>","{{/for}}"].join("")},{$wrap:"options"}),b.on("keyup","#"+a._id+"_"+j+"_dropdownMenu .gridFilterSearch",function(a){var b=window.jQuery(this),c=n.query(),d=b.val();d?c[j]=new RegExp(d,"gi"):delete c[j],n.query(c)}),b.on("click","#"+a._id+"_"+j+"_dropdownMenu .gridFilterClearSearch",function(a){window.jQuery(this).parents("li").find(".gridFilterSearch").val("");var b=n.query();delete b[j],n.query(b)}),b.on("click","#"+a._id+"_"+j+"_dropdownMenu li",function(b){b.stopPropagation();var c,e,f,g,h,i=$(this),l=i.find('input[type="checkbox"]'),m=!0;if(window.jQuery(b.target).is("input")?(l.prop("checked",l.prop("checked")),e=l.is(":checked")):(l.prop("checked",!l.prop("checked")),e=l.is(":checked")),g=window.jQuery(this),c=g.attr("data-val"),"$all"===c)delete d[j],g.parent().find('li[data-val!="$all"]').find('input[type="checkbox"]').prop("checked",!1);else{switch(g.parent().find('[data-val="$all"]').find('input[type="checkbox"]').prop("checked",!1),k){case"integer":c=parseInt(c,10);break;case"float":c=parseFloat(c)}for(d[j]=d[j]||{$in:[]},f=d[j].$in,h=0;h<f.length;h++)if(f[h]===c){e===!1&&f.splice(h,1),m=!1;break}m&&e&&f.push(c),f.length||delete d[j]}a._from.queryData(d),a._from.pageFirst&&a._from.pageFirst()})})}a.emit("refresh")}return this},l.prototype.count=function(){return this._from.count()},f.prototype.grid=h.prototype.grid=function(a,b,c){if(this._db&&this._db._grid){if(void 0!==a){if(void 0!==b){if(this._db._grid[a])throw this.logIdentifier()+" Cannot create a grid because a grid with this name already exists: "+a;var d=new l(a,b,c).db(this._db).from(this);return this._grid=this._grid||[],this._grid.push(d),this._db._grid[a]=d,d}return this._db._grid[a]}return this._db._grid}},f.prototype.unGrid=h.prototype.unGrid=function(a,b,c){var d,e;if(this._db&&this._db._grid){if(a&&b){if(this._db._grid[a])return e=this._db._grid[a],delete this._db._grid[a],e.drop();throw this.logIdentifier()+" Cannot remove grid because a grid with this name does not exist: "+name}for(d in this._db._grid)this._db._grid.hasOwnProperty(d)&&(e=this._db._grid[d],delete this._db._grid[d],e.drop(),this.debug()&&console.log(this.logIdentifier()+' Removed grid binding "'+d+'"'));this._db._grid={}}},f.prototype._addGrid=g.prototype._addGrid=h.prototype._addGrid=function(a){return void 0!==a&&(this._grid=this._grid||[],this._grid.push(a)),this},f.prototype._removeGrid=g.prototype._removeGrid=h.prototype._removeGrid=function(a){if(void 0!==a&&this._grid){var b=this._grid.indexOf(a);b>-1&&this._grid.splice(b,1)}return this},e.prototype.init=function(){this._grid={},j.apply(this,arguments)},e.prototype.gridExists=function(a){return Boolean(this._grid[a])},e.prototype.grid=function(a,b,c){return this._grid[a]||(this.debug()||this._db&&this._db.debug())&&console.log(this.logIdentifier()+" Creating grid "+a),this._grid[a]=this._grid[a]||new l(a,b,c).db(this),this._grid[a]},e.prototype.unGrid=function(a,b,c){return this._grid[a]||(this.debug()||this._db&&this._db.debug())&&console.log(this.logIdentifier()+" Creating grid "+a),this._grid[a]=this._grid[a]||new l(a,b,c).db(this),this._grid[a]},e.prototype.grids=function(){var a,b,c=[];for(b in this._grid)this._grid.hasOwnProperty(b)&&(a=this._grid[b],c.push({name:b,count:a.count(),linked:void 0!==a.isLinked?a.isLinked():!1}));return c},d.finishModule("Grid"),b.exports=l},{"./Collection":6,"./CollectionGroup":7,"./ReactorIO":38,"./Shared":40,"./View":42}],14:[function(a,b,c){"use strict";var d,e,f,g;d=a("./Shared"),g=a("./Overload");var h=function(a,b){this.init.apply(this,arguments)};h.prototype.init=function(a,b){if(this._options=b,this._selector=window.jQuery(this._options.selector),!this._selector[0])throw this.classIdentifier()+' "'+a.name()+'": Chart target element does not exist via selector: '+this._options.selector;this._listeners={},this._collection=a,this._options.series=[],b.chartOptions=b.chartOptions||{},b.chartOptions.credits=!1;var c,d,e;switch(this._options.type){case"pie":this._selector.highcharts(this._options.chartOptions),this._chart=this._selector.highcharts(),c=this._collection.find(),d={allowPointSelect:!0,cursor:"pointer",dataLabels:{enabled:!0,format:"<b>{point.name}</b>: {y} ({point.percentage:.0f}%)",style:{color:window.Highcharts.theme&&window.Highcharts.theme.contrastTextColor||"black"}}},e=this.pieDataFromCollectionData(c,this._options.keyField,this._options.valField),window.jQuery.extend(d,this._options.seriesOptions),window.jQuery.extend(d,{name:this._options.seriesName,data:e}),this._chart.addSeries(d,!0,!0);break;case"line":case"area":case"column":case"bar":e=this.seriesDataFromCollectionData(this._options.seriesField,this._options.keyField,this._options.valField,this._options.orderBy,this._options),this._options.chartOptions.xAxis=e.xAxis,this._options.chartOptions.series=e.series,this._selector.highcharts(this._options.chartOptions),this._chart=this._selector.highcharts();break;default:throw this.classIdentifier()+' "'+a.name()+'": Chart type specified is not currently supported by ForerunnerDB: '+this._options.type}this._hookEvents()},d.addModule("Highchart",h),e=d.modules.Collection,f=e.prototype.init,d.mixin(h.prototype,"Mixin.Common"),d.mixin(h.prototype,"Mixin.Events"),d.synthesize(h.prototype,"state"),h.prototype.pieDataFromCollectionData=function(a,b,c){var d,e=[];for(d=0;d<a.length;d++)e.push([a[d][b],a[d][c]]);return e},h.prototype.seriesDataFromCollectionData=function(a,b,c,d,e){var f,g,h,i,j,k,l,m=this._collection.distinct(a),n=[],o=e&&e.chartOptions&&e.chartOptions.xAxis?e.chartOptions.xAxis:{categories:[]};for(k=0;k<m.length;k++){for(f=m[k],g={},g[a]=f,i=[],h=this._collection.find(g,{orderBy:d}),l=0;l<h.length;l++)o.categories?(o.categories.push(h[l][b]),i.push(h[l][c])):i.push([h[l][b],h[l][c]]);if(j={name:f,data:i},e.seriesOptions)for(l in e.seriesOptions)e.seriesOptions.hasOwnProperty(l)&&(j[l]=e.seriesOptions[l]);n.push(j)}return{xAxis:o,series:n}},h.prototype._hookEvents=function(){var a=this;a._collection.on("change",function(){a._changeListener.apply(a,arguments)}),a._collection.on("drop",function(){a.drop.apply(a)})},h.prototype._changeListener=function(){var a=this;if("undefined"!=typeof a._collection&&a._chart){var b,c=a._collection.find();switch(a._options.type){case"pie":a._chart.series[0].setData(a.pieDataFromCollectionData(c,a._options.keyField,a._options.valField),!0,!0);break;case"bar":case"line":case"area":case"column":var d=a.seriesDataFromCollectionData(a._options.seriesField,a._options.keyField,a._options.valField,a._options.orderBy,a._options);for(d.xAxis.categories&&a._chart.xAxis[0].setCategories(d.xAxis.categories),b=0;b<d.series.length;b++)a._chart.series[b]?a._chart.series[b].setData(d.series[b].data,!0,!0):a._chart.addSeries(d.series[b],!0,!0)}}},h.prototype.drop=function(a){return this.isDropped()?!0:(this._state="dropped",this._chart&&this._chart.destroy(),this._collection&&(this._collection.off("change",this._changeListener),this._collection.off("drop",this.drop),this._collection._highcharts&&delete this._collection._highcharts[this._options.selector]),delete this._chart,delete this._options,delete this._collection,this.emit("drop",this),a&&a(!1,!0),delete this._listeners,!0)},e.prototype.init=function(){this._highcharts={},f.apply(this,arguments)},e.prototype.pieChart=new g({object:function(a){return a.type="pie",a.chartOptions=a.chartOptions||{},a.chartOptions.chart=a.chartOptions.chart||{},a.chartOptions.chart.type="pie",this._highcharts[a.selector]||(this._highcharts[a.selector]=new h(this,a)),this._highcharts[a.selector]},"*, string, string, string, ...":function(a,b,c,d,e){e=e||{},e.selector=a,e.keyField=b,e.valField=c,e.seriesName=d,this.pieChart(e)}}),e.prototype.lineChart=new g({string:function(a){return this._highcharts[a]},object:function(a){return a.type="line",a.chartOptions=a.chartOptions||{},a.chartOptions.chart=a.chartOptions.chart||{},a.chartOptions.chart.type="line",this._highcharts[a.selector]||(this._highcharts[a.selector]=new h(this,a)),this._highcharts[a.selector]},"*, string, string, string, ...":function(a,b,c,d,e){e=e||{},e.seriesField=b,e.selector=a,e.keyField=c,e.valField=d,this.lineChart(e)}}),e.prototype.areaChart=new g({object:function(a){return a.type="area",a.chartOptions=a.chartOptions||{},a.chartOptions.chart=a.chartOptions.chart||{},a.chartOptions.chart.type="area",this._highcharts[a.selector]||(this._highcharts[a.selector]=new h(this,a)),this._highcharts[a.selector]},"*, string, string, string, ...":function(a,b,c,d,e){e=e||{},e.seriesField=b,e.selector=a,e.keyField=c,e.valField=d,this.areaChart(e)}}),e.prototype.columnChart=new g({object:function(a){return a.type="column",a.chartOptions=a.chartOptions||{},a.chartOptions.chart=a.chartOptions.chart||{},a.chartOptions.chart.type="column",this._highcharts[a.selector]||(this._highcharts[a.selector]=new h(this,a)),this._highcharts[a.selector]},"*, string, string, string, ...":function(a,b,c,d,e){e=e||{},e.seriesField=b,e.selector=a,e.keyField=c,e.valField=d,this.columnChart(e)}}),e.prototype.barChart=new g({object:function(a){return a.type="bar",a.chartOptions=a.chartOptions||{},a.chartOptions.chart=a.chartOptions.chart||{},a.chartOptions.chart.type="bar",this._highcharts[a.selector]||(this._highcharts[a.selector]=new h(this,a)),this._highcharts[a.selector]},"*, string, string, string, ...":function(a,b,c,d,e){e=e||{},e.seriesField=b,e.selector=a,e.keyField=c,e.valField=d,this.barChart(e)}}),e.prototype.stackedBarChart=new g({object:function(a){return a.type="bar",a.chartOptions=a.chartOptions||{},a.chartOptions.chart=a.chartOptions.chart||{},a.chartOptions.chart.type="bar",a.plotOptions=a.plotOptions||{},a.plotOptions.series=a.plotOptions.series||{},a.plotOptions.series.stacking=a.plotOptions.series.stacking||"normal",this._highcharts[a.selector]||(this._highcharts[a.selector]=new h(this,a)),this._highcharts[a.selector]},"*, string, string, string, ...":function(a,b,c,d,e){e=e||{},e.seriesField=b,e.selector=a,e.keyField=c,e.valField=d,this.stackedBarChart(e)}}),e.prototype.dropChart=function(a){this._highcharts&&this._highcharts[a]&&this._highcharts[a].drop()},d.finishModule("Highchart"),b.exports=h},{"./Overload":32,"./Shared":40}],15:[function(a,b,c){"use strict";var d=a("./Shared"),e=a("./Path"),f=a("./BinaryTree"),g=a("./GeoHash"),h=new e,i=new g,j=[5e3,1250,156,39.1,4.89,1.22,.153,.0382,.00477,.00119,149e-6,372e-7],k=function(){this.init.apply(this,arguments)};k.prototype.init=function(a,b,c){this._btree=new f,this._btree.index(a),this._size=0,this._id=this._itemKeyHash(a,a),this._debug=b&&b.debug?b.debug:!1,this.unique(b&&b.unique?b.unique:!1),void 0!==a&&this.keys(a),void 0!==c&&(this.collection(c),this._btree.primaryKey(c.primaryKey())),this.name(b&&b.name?b.name:this._id),this._btree.debug(this._debug)},d.addModule("Index2d",k),d.mixin(k.prototype,"Mixin.Common"),d.mixin(k.prototype,"Mixin.ChainReactor"),d.mixin(k.prototype,"Mixin.Sorting"),k.prototype.id=function(){return this._id},k.prototype.state=function(){return this._state},k.prototype.size=function(){return this._size},d.synthesize(k.prototype,"data"),d.synthesize(k.prototype,"name"),d.synthesize(k.prototype,"collection"),d.synthesize(k.prototype,"type"),d.synthesize(k.prototype,"unique"),k.prototype.keys=function(a){return void 0!==a?(this._keys=a,this._keyCount=h.parse(this._keys).length,this):this._keys},k.prototype.rebuild=function(){if(this._collection){var a,b=this._collection.subset({},{$decouple:!1,$orderBy:this._keys}),c=b.find(),d=c.length;for(this._btree.clear(),this._size=0,this._unique&&(this._uniqueLookup={}),a=0;d>a;a++)this.insert(c[a])}this._state={name:this._name,keys:this._keys,indexSize:this._size,built:new Date,updated:new Date,ok:!0}},k.prototype.insert=function(a,b){var c,d=this._unique;a=this.decouple(a),d&&(c=this._itemHash(a,this._keys),this._uniqueLookup[c]=a);var e,f,g,j,k,l=this._btree.keys();for(k=0;k<l.length;k++)e=h.get(a,l[k].path),e instanceof Array&&(g=e[0],j=e[1],f=i.encode(g,j),h.set(a,l[k].path,f));return this._btree.insert(a)?(this._size++,!0):!1},k.prototype.remove=function(a,b){var c,d=this._unique;return d&&(c=this._itemHash(a,this._keys),delete this._uniqueLookup[c]),this._btree.remove(a)?(this._size--,!0):!1},k.prototype.violation=function(a){var b=this._itemHash(a,this._keys);return Boolean(this._uniqueLookup[b])},k.prototype.hashViolation=function(a){return Boolean(this._uniqueLookup[a])},k.prototype.lookup=function(a,b){var c,d,e,f,g=this._btree.keys();for(f=0;f<g.length;f++)if(c=g[f].path,d=h.get(a,c),"object"==typeof d)return d.$near&&(e=[],e=e.concat(this.near(c,d.$near,b))),d.$geoWithin&&(e=[],e=e.concat(this.geoWithin(c,d.$geoWithin,b))),e;return this._btree.lookup(a,b)},k.prototype.near=function(a,b,c){var d,e,f,g,k,l,m,n,o,p,q,r=this,s=[],t=this._collection.primaryKey();if("km"===b.$distanceUnits){for(m=b.$maxDistance,q=0;q<j.length;q++)if(m>j[q]){l=q;break}0===l&&(l=1)}else if("miles"===b.$distanceUnits){for(m=1.60934*b.$maxDistance,q=0;q<j.length;q++)if(m>j[q]){l=q;break}0===l&&(l=1)}for(d=i.encode(b.$point[0],b.$point[1],l),e=i.calculateNeighbours(d,{type:"array"}),k=[],f=0,q=0;9>q;q++)g=this._btree.startsWith(a,e[q]),f+=g._visited,k=k.concat(g);if(k=this._collection._primaryIndex.lookup(k),k.length){for(n={},q=0;q<k.length;q++)p=h.get(k[q],a),o=n[k[q][t]]=this.distanceBetweenPoints(b.$point[0],b.$point[1],p[0],p[1]),m>=o&&s.push(k[q]);s.sort(function(a,b){return r.sortAsc(n[a[t]],n[b[t]])})}return s},k.prototype.geoWithin=function(a,b,c){return[]},k.prototype.distanceBetweenPoints=function(a,b,c,d){var e=6371,f=this.toRadians(a),g=this.toRadians(c),h=this.toRadians(c-a),i=this.toRadians(d-b),j=Math.sin(h/2)*Math.sin(h/2)+Math.cos(f)*Math.cos(g)*Math.sin(i/2)*Math.sin(i/2),k=2*Math.atan2(Math.sqrt(j),Math.sqrt(1-j));return e*k},k.prototype.toRadians=function(a){return.01747722222222*a},k.prototype.match=function(a,b){return this._btree.match(a,b)},k.prototype._itemHash=function(a,b){var c,d,f=new e,g="";for(c=f.parse(b),d=0;d<c.length;d++)g&&(g+="_"),g+=f.value(a,c[d].path).join(":");return g},k.prototype._itemKeyHash=function(a,b){var c,d,f=new e,g="";for(c=f.parse(b),d=0;d<c.length;d++)g&&(g+="_"),g+=f.keyValue(a,c[d].path);return g},k.prototype._itemHashArr=function(a,b){var c,d,f,g,h,i=new e,j=[];for(c=i.parse(b),g=0;g<c.length;g++)for(d=i.value(a,c[g].path),f=0;f<d.length;f++)if(0===g)j.push(d[f]);else for(h=0;h<j.length;h++)j[h]=j[h]+"_"+d[f];return j},d.finishModule("Index2d"),b.exports=k},{"./BinaryTree":5,"./GeoHash":12,"./Path":34,"./Shared":40}],16:[function(a,b,c){"use strict";var d=a("./Shared"),e=a("./Path"),f=a("./BinaryTree"),g=function(){this.init.apply(this,arguments)};g.prototype.init=function(a,b,c){this._btree=new f,this._btree.index(a),this._size=0,this._id=this._itemKeyHash(a,a),this._debug=b&&b.debug?b.debug:!1,this.unique(b&&b.unique?b.unique:!1),void 0!==a&&this.keys(a),void 0!==c&&(this.collection(c),this._btree.primaryKey(c.primaryKey())),this.name(b&&b.name?b.name:this._id),this._btree.debug(this._debug)},d.addModule("IndexBinaryTree",g),d.mixin(g.prototype,"Mixin.ChainReactor"),d.mixin(g.prototype,"Mixin.Sorting"),g.prototype.id=function(){return this._id},g.prototype.state=function(){return this._state},g.prototype.size=function(){return this._size},d.synthesize(g.prototype,"data"),d.synthesize(g.prototype,"name"),d.synthesize(g.prototype,"collection"),d.synthesize(g.prototype,"type"),d.synthesize(g.prototype,"unique"),g.prototype.keys=function(a){return void 0!==a?(this._keys=a,this._keyCount=(new e).parse(this._keys).length,this):this._keys},g.prototype.rebuild=function(){if(this._collection){var a,b=this._collection.subset({},{$decouple:!1,$orderBy:this._keys}),c=b.find(),d=c.length;for(this._btree.clear(),this._size=0,this._unique&&(this._uniqueLookup={}),a=0;d>a;a++)this.insert(c[a])}this._state={name:this._name,keys:this._keys,indexSize:this._size,built:new Date,updated:new Date,ok:!0}},g.prototype.insert=function(a,b){var c,d=this._unique;return d&&(c=this._itemHash(a,this._keys),this._uniqueLookup[c]=a),this._btree.insert(a)?(this._size++,!0):!1},g.prototype.remove=function(a,b){var c,d=this._unique;return d&&(c=this._itemHash(a,this._keys),delete this._uniqueLookup[c]),this._btree.remove(a)?(this._size--,!0):!1},g.prototype.violation=function(a){var b=this._itemHash(a,this._keys);return Boolean(this._uniqueLookup[b])},g.prototype.hashViolation=function(a){return Boolean(this._uniqueLookup[a])},g.prototype.lookup=function(a,b){return this._btree.lookup(a,b)},g.prototype.match=function(a,b){return this._btree.match(a,b)},g.prototype._itemHash=function(a,b){var c,d,f=new e,g="";for(c=f.parse(b),d=0;d<c.length;d++)g&&(g+="_"),g+=f.value(a,c[d].path).join(":");return g},g.prototype._itemKeyHash=function(a,b){var c,d,f=new e,g="";for(c=f.parse(b),d=0;d<c.length;d++)g&&(g+="_"),g+=f.keyValue(a,c[d].path);return g},g.prototype._itemHashArr=function(a,b){var c,d,f,g,h,i=new e,j=[];for(c=i.parse(b),g=0;g<c.length;g++)for(d=i.value(a,c[g].path),f=0;f<d.length;f++)if(0===g)j.push(d[f]);else for(h=0;h<j.length;h++)j[h]=j[h]+"_"+d[f];return j},d.finishModule("IndexBinaryTree"),b.exports=g},{"./BinaryTree":5,"./Path":34,"./Shared":40}],17:[function(a,b,c){"use strict";var d=a("./Shared"),e=a("./Path"),f=function(){this.init.apply(this,arguments)};f.prototype.init=function(a,b,c){this._crossRef={},this._size=0,this._id=this._itemKeyHash(a,a),this.data({}),this.unique(b&&b.unique?b.unique:!1),void 0!==a&&this.keys(a),void 0!==c&&this.collection(c),this.name(b&&b.name?b.name:this._id)},d.addModule("IndexHashMap",f),d.mixin(f.prototype,"Mixin.ChainReactor"),f.prototype.id=function(){return this._id},f.prototype.state=function(){return this._state},f.prototype.size=function(){return this._size},d.synthesize(f.prototype,"data"),d.synthesize(f.prototype,"name"),d.synthesize(f.prototype,"collection"),d.synthesize(f.prototype,"type"),d.synthesize(f.prototype,"unique"),f.prototype.keys=function(a){return void 0!==a?(this._keys=a,this._keyCount=(new e).parse(this._keys).length,this):this._keys},f.prototype.rebuild=function(){if(this._collection){var a,b=this._collection.subset({},{$decouple:!1,$orderBy:this._keys}),c=b.find(),d=c.length;for(this._data={},this._size=0,this._unique&&(this._uniqueLookup={}),a=0;d>a;a++)this.insert(c[a])}this._state={name:this._name,keys:this._keys,indexSize:this._size,built:new Date,updated:new Date,ok:!0}},f.prototype.insert=function(a,b){var c,d,e,f=this._unique;for(f&&(c=this._itemHash(a,this._keys),this._uniqueLookup[c]=a),d=this._itemHashArr(a,this._keys),e=0;e<d.length;e++)this.pushToPathValue(d[e],a)},f.prototype.update=function(a,b){},f.prototype.remove=function(a,b){var c,d,e,f=this._unique;for(f&&(c=this._itemHash(a,this._keys),delete this._uniqueLookup[c]),d=this._itemHashArr(a,this._keys),e=0;e<d.length;e++)this.pullFromPathValue(d[e],a)},f.prototype.violation=function(a){var b=this._itemHash(a,this._keys);return Boolean(this._uniqueLookup[b])},f.prototype.hashViolation=function(a){return Boolean(this._uniqueLookup[a])},f.prototype.pushToPathValue=function(a,b){var c=this._data[a]=this._data[a]||[];-1===c.indexOf(b)&&(c.push(b),this._size++,this.pushToCrossRef(b,c))},f.prototype.pullFromPathValue=function(a,b){var c,d=this._data[a];c=d.indexOf(b),c>-1&&(d.splice(c,1),this._size--,this.pullFromCrossRef(b,d)),d.length||delete this._data[a]},f.prototype.pull=function(a){var b,c,d=a[this._collection.primaryKey()],e=this._crossRef[d],f=e.length;for(b=0;f>b;b++)c=e[b],this._pullFromArray(c,a);this._size--,delete this._crossRef[d]},f.prototype._pullFromArray=function(a,b){for(var c=a.length;c--;)a[c]===b&&a.splice(c,1)},f.prototype.pushToCrossRef=function(a,b){var c,d=a[this._collection.primaryKey()];this._crossRef[d]=this._crossRef[d]||[],c=this._crossRef[d],-1===c.indexOf(b)&&c.push(b)},f.prototype.pullFromCrossRef=function(a,b){var c=a[this._collection.primaryKey()];delete this._crossRef[c]},f.prototype.lookup=function(a){return this._data[this._itemHash(a,this._keys)]||[]},f.prototype.match=function(a,b){var c,d=new e,f=d.parseArr(this._keys),g=d.parseArr(a),h=[],i=0;for(c=0;c<f.length;c++){if(g[c]!==f[c])return{matchedKeys:[],totalKeyCount:g.length,score:0};i++,h.push(g[c])}return{matchedKeys:h,totalKeyCount:g.length,score:i}},f.prototype._itemHash=function(a,b){var c,d,f=new e,g="";for(c=f.parse(b),d=0;d<c.length;d++)g&&(g+="_"),g+=f.value(a,c[d].path).join(":");return g},f.prototype._itemKeyHash=function(a,b){var c,d,f=new e,g="";for(c=f.parse(b),d=0;d<c.length;d++)g&&(g+="_"),g+=f.keyValue(a,c[d].path);return g},f.prototype._itemHashArr=function(a,b){var c,d,f,g,h,i=new e,j=[];for(c=i.parse(b),g=0;g<c.length;g++)for(d=i.value(a,c[g].path),f=0;f<d.length;f++)if(0===g)j.push(d[f]);else for(h=0;h<j.length;h++)j[h]=j[h]+"_"+d[f];return j},d.finishModule("IndexHashMap"),b.exports=f},{"./Path":34,"./Shared":40}],18:[function(a,b,c){"use strict";var d=a("./Shared"),e=function(a){this.init.apply(this,arguments)};e.prototype.init=function(a){this._name=a,this._data={},this._primaryKey="_id"},d.addModule("KeyValueStore",e),d.mixin(e.prototype,"Mixin.ChainReactor"),d.synthesize(e.prototype,"name"),e.prototype.primaryKey=function(a){return void 0!==a?(this._primaryKey=a,this):this._primaryKey},e.prototype.truncate=function(){return this._data={},this},e.prototype.set=function(a,b){return this._data[a]=b?b:!0,this},e.prototype.get=function(a){return this._data[a]},e.prototype.lookup=function(a){var b,c,d,e=this._primaryKey,f=typeof a,g=[];if("string"===f||"number"===f)return d=this.get(a),void 0!==d?[d]:[];if("object"===f){if(a instanceof Array){for(c=a.length,g=[],b=0;c>b;b++)d=this.lookup(a[b]),d&&(d instanceof Array?g=g.concat(d):g.push(d));return g}if(a[e])return this.lookup(a[e])}},e.prototype.unSet=function(a){return delete this._data[a],this},e.prototype.uniqueSet=function(a,b){return void 0===this._data[a]?(this._data[a]=b,!0):!1},d.finishModule("KeyValueStore"),b.exports=e},{"./Shared":40}],19:[function(a,b,c){"use strict";var d=a("./Shared"),e=a("./Operation"),f=function(){this.init.apply(this,arguments)};f.prototype.init=function(){this._data=[]},d.addModule("Metrics",f),d.mixin(f.prototype,"Mixin.ChainReactor"),f.prototype.create=function(a){var b=new e(a);return this._enabled&&this._data.push(b),b},f.prototype.start=function(){return this._enabled=!0,this},f.prototype.stop=function(){return this._enabled=!1,this},f.prototype.clear=function(){return this._data=[],this},f.prototype.list=function(){return this._data},d.finishModule("Metrics"),b.exports=f},{"./Operation":31,"./Shared":40}],20:[function(a,b,c){"use strict";var d={preSetData:function(){},postSetData:function(){}};b.exports=d},{}],21:[function(a,b,c){"use strict";var d={chain:function(a){this.debug&&this.debug()&&(a._reactorIn&&a._reactorOut?console.log(a._reactorIn.logIdentifier()+' Adding target "'+a._reactorOut.instanceIdentifier()+'" to the chain reactor target list'):console.log(this.logIdentifier()+' Adding target "'+a.instanceIdentifier()+'" to the chain reactor target list')),this._chain=this._chain||[];var b=this._chain.indexOf(a);-1===b&&this._chain.push(a)},unChain:function(a){if(this.debug&&this.debug()&&(a._reactorIn&&a._reactorOut?console.log(a._reactorIn.logIdentifier()+' Removing target "'+a._reactorOut.instanceIdentifier()+'" from the chain reactor target list'):console.log(this.logIdentifier()+' Removing target "'+a.instanceIdentifier()+'" from the chain reactor target list')),this._chain){var b=this._chain.indexOf(a);b>-1&&this._chain.splice(b,1)}},chainSend:function(a,b,c){if(this._chain){var d,e,f=this._chain,g=f.length;for(e=0;g>e;e++){if(d=f[e],d._state&&(!d._state||d.isDropped()))throw console.log("Reactor Data:",a,b,c),console.log("Reactor Node:",d),"Chain reactor attempting to send data to target reactor node that is in a dropped state!";this.debug&&this.debug()&&(d._reactorIn&&d._reactorOut?console.log(d._reactorIn.logIdentifier()+' Sending data down the chain reactor pipe to "'+d._reactorOut.instanceIdentifier()+'"'):console.log(this.logIdentifier()+' Sending data down the chain reactor pipe to "'+d.instanceIdentifier()+'"')),d.chainReceive&&d.chainReceive(this,a,b,c)}}},chainReceive:function(a,b,c,d){var e={sender:a,type:b,data:c,options:d};this.debug&&this.debug()&&console.log(this.logIdentifier()+"Received data from parent reactor node"),(!this._chainHandler||this._chainHandler&&!this._chainHandler(e))&&this.chainSend(e.type,e.data,e.options)}};b.exports=d},{}],22:[function(a,b,c){"use strict";var d,e=0,f=a("./Overload"),g=a("./Serialiser"),h=new g;d={serialiser:h,store:function(a,b){if(void 0!==a){if(void 0!==b)return this._store=this._store||{},this._store[a]=b,this;if(this._store)return this._store[a]}},unStore:function(a){return void 0!==a&&delete this._store[a],this},decouple:function(a,b){if(void 0!==a&&""!==a){if(b){var c,d=this.jStringify(a),e=[];for(c=0;b>c;c++)e.push(this.jParse(d));return e}return this.jParse(this.jStringify(a))}},jParse:function(a){return h.parse(a)},jStringify:function(a){return h.stringify(a)},objectId:function(a){var b,c=Math.pow(10,17);if(a){var d,f=0,g=a.length;for(d=0;g>d;d++)f+=a.charCodeAt(d)*c;b=f.toString(16)}else e++,b=(e+(Math.random()*c+Math.random()*c+Math.random()*c+Math.random()*c)).toString(16);return b},debug:new f([function(){return this._debug&&this._debug.all},function(a){return void 0!==a?"boolean"==typeof a?(this._debug=this._debug||{},this._debug.all=a,this.chainSend("debug",this._debug),this):this._debug&&this._debug[a]||this._db&&this._db._debug&&this._db._debug[a]||this._debug&&this._debug.all:this._debug&&this._debug.all},function(a,b){return void 0!==a?void 0!==b?(this._debug=this._debug||{},this._debug[a]=b,this.chainSend("debug",this._debug),this):this._debug&&this._debug[b]||this._db&&this._db._debug&&this._db._debug[a]:this._debug&&this._debug.all}]),classIdentifier:function(){return"ForerunnerDB."+this.className},instanceIdentifier:function(){return"["+this.className+"]"+this.name()},logIdentifier:function(){return this.classIdentifier()+": "+this.instanceIdentifier()},convertToFdb:function(a){var b,c,d,e;for(e in a)if(a.hasOwnProperty(e)&&(d=a,e.indexOf(".")>-1)){for(e=e.replace(".$","[|$|]"),c=e.split(".");b=c.shift();)b=b.replace("[|$|]",".$"),c.length?d[b]={}:d[b]=a[e],d=d[b];delete a[e]}},isDropped:function(){return"dropped"===this._state},debounce:function(a,b,c){var d,e=this;e._debounce=e._debounce||{},e._debounce[a]&&clearTimeout(e._debounce[a].timeout),d={callback:b,timeout:setTimeout(function(){delete e._debounce[a],b()},c)},e._debounce[a]=d}},b.exports=d},{"./Overload":32,"./Serialiser":39}],23:[function(a,b,c){"use strict";var d={TYPE_INSERT:0,TYPE_UPDATE:1,TYPE_REMOVE:2,PHASE_BEFORE:0,PHASE_AFTER:1};b.exports=d},{}],24:[function(a,b,c){"use strict";var d=a("./Overload"),e={on:new d({"string, function":function(a,b){return this._listeners=this._listeners||{},this._listeners[a]=this._listeners[a]||{},this._listeners[a]["*"]=this._listeners[a]["*"]||[],this._listeners[a]["*"].push(b),this},"string, *, function":function(a,b,c){return this._listeners=this._listeners||{},this._listeners[a]=this._listeners[a]||{},this._listeners[a][b]=this._listeners[a][b]||[],this._listeners[a][b].push(c),this}}),once:new d({"string, function":function(a,b){var c=this,d=function(){c.off(a,d),b.apply(c,arguments)};return this.on(a,d)},"string, *, function":function(a,b,c){var d=this,e=function(){d.off(a,b,e),c.apply(d,arguments)};return this.on(a,b,e)}}),off:new d({string:function(a){return this._listeners&&this._listeners[a]&&a in this._listeners&&delete this._listeners[a],this},"string, function":function(a,b){var c,d;return"string"==typeof b?this._listeners&&this._listeners[a]&&this._listeners[a][b]&&delete this._listeners[a][b]:this._listeners&&a in this._listeners&&(c=this._listeners[a]["*"],d=c.indexOf(b),d>-1&&c.splice(d,1)),this},"string, *, function":function(a,b,c){if(this._listeners&&a in this._listeners&&b in this.listeners[a]){var d=this._listeners[a][b],e=d.indexOf(c);e>-1&&d.splice(e,1)}},"string, *":function(a,b){this._listeners&&a in this._listeners&&b in this._listeners[a]&&delete this._listeners[a][b]}}),emit:function(a,b){if(this._listeners=this._listeners||{},a in this._listeners){var c,d,e,f,g,h,i;if(this._listeners[a]["*"])for(f=this._listeners[a]["*"],d=f.length,c=0;d>c;c++)e=f[c],"function"==typeof e&&e.apply(this,Array.prototype.slice.call(arguments,1));if(b instanceof Array&&b[0]&&b[0][this._primaryKey])for(g=this._listeners[a],d=b.length,c=0;d>c;c++)if(g[b[c][this._primaryKey]])for(h=g[b[c][this._primaryKey]].length,i=0;h>i;i++)e=g[b[c][this._primaryKey]][i],"function"==typeof e&&g[b[c][this._primaryKey]][i].apply(this,Array.prototype.slice.call(arguments,1))}return this},deferEmit:function(a,b){var c,d=this;return this._noEmitDefer||this._db&&(!this._db||this._db._noEmitDefer)?this.emit.apply(this,arguments):(c=arguments,this._deferTimeout=this._deferTimeout||{},this._deferTimeout[a]&&clearTimeout(this._deferTimeout[a]),this._deferTimeout[a]=setTimeout(function(){d.debug()&&console.log(d.logIdentifier()+" Emitting "+c[0]),d.emit.apply(d,c)},1)),this}};b.exports=e},{"./Overload":32}],25:[function(a,b,c){"use strict";var d={_match:function(a,b,c,d,e){var f,g,h,i,j,k,l=d,m=typeof a,n=typeof b,o=!0;if(e=e||{},c=c||{},e.$rootQuery||(e.$rootQuery=b),e.$rootSource||(e.$rootSource=a),e.$currentQuery=b,e.$rootData=e.$rootData||{},"string"!==m&&"number"!==m||"string"!==n&&"number"!==n){if(("string"===m||"number"===m)&&"object"===n&&b instanceof RegExp)b.test(a)||(o=!1);else for(k in b)if(b.hasOwnProperty(k)){if(e.$previousQuery=e.$parent,e.$parent={query:b[k],key:k,parent:e.$previousQuery},f=!1,j=k.substr(0,2),"//"===j)continue;if(0===j.indexOf("$")&&(i=this._matchOp(k,a,b[k],c,e),i>-1)){if(i){if("or"===d)return!0}else o=i;f=!0}if(!f&&b[k]instanceof RegExp)if(f=!0,"object"===m&&void 0!==a[k]&&b[k].test(a[k])){if("or"===d)return!0}else o=!1;if(!f)if("object"==typeof b[k])if(void 0!==a[k])if(a[k]instanceof Array&&!(b[k]instanceof Array)){for(g=!1,h=0;h<a[k].length&&!(g=this._match(a[k][h],b[k],c,l,e));h++);if(g){if("or"===d)return!0}else o=!1}else if(!(a[k]instanceof Array)&&b[k]instanceof Array){for(g=!1,h=0;h<b[k].length&&!(g=this._match(a[k],b[k][h],c,l,e));h++);if(g){if("or"===d)return!0}else o=!1}else if("object"==typeof a)if(g=this._match(a[k],b[k],c,l,e)){if("or"===d)return!0}else o=!1;else if(g=this._match(void 0,b[k],c,l,e)){if("or"===d)return!0}else o=!1;else if(b[k]&&void 0!==b[k].$exists)if(g=this._match(void 0,b[k],c,l,e)){if("or"===d)return!0}else o=!1;else o=!1;else if(a&&a[k]===b[k]){if("or"===d)return!0}else if(a&&a[k]&&a[k]instanceof Array&&b[k]&&"object"!=typeof b[k]){ for(g=!1,h=0;h<a[k].length&&!(g=this._match(a[k][h],b[k],c,l,e));h++);if(g){if("or"===d)return!0}else o=!1}else o=!1;if("and"===d&&!o)return!1}}else"number"===m?a!==b&&(o=!1):a.localeCompare(b)&&(o=!1);return o},_matchOp:function(a,b,c,d,e){switch(a){case"$gt":return b>c;case"$gte":return b>=c;case"$lt":return c>b;case"$lte":return c>=b;case"$exists":return void 0===b!==c;case"$eq":return b==c;case"$eeq":return b===c;case"$ne":return b!=c;case"$nee":return b!==c;case"$or":for(var f=0;f<c.length;f++)if(this._match(b,c[f],d,"and",e))return!0;return!1;case"$and":for(var g=0;g<c.length;g++)if(!this._match(b,c[g],d,"and",e))return!1;return!0;case"$in":if(c instanceof Array){var h,i=c,j=i.length;for(h=0;j>h;h++)if(this._match(b,i[h],d,"and",e))return!0;return!1}if("object"==typeof c)return this._match(b,c,d,"and",e);throw this.logIdentifier()+" Cannot use an $in operator on a non-array key: "+a;case"$nin":if(c instanceof Array){var k,l=c,m=l.length;for(k=0;m>k;k++)if(this._match(b,l[k],d,"and",e))return!1;return!0}if("object"==typeof c)return this._match(b,c,d,"and",e);throw this.logIdentifier()+" Cannot use a $nin operator on a non-array key: "+a;case"$distinct":e.$rootData["//distinctLookup"]=e.$rootData["//distinctLookup"]||{};for(var n in c)if(c.hasOwnProperty(n))return e.$rootData["//distinctLookup"][n]=e.$rootData["//distinctLookup"][n]||{},e.$rootData["//distinctLookup"][n][b[n]]?!1:(e.$rootData["//distinctLookup"][n][b[n]]=!0,!0);break;case"$count":var o,p,q;for(o in c)if(c.hasOwnProperty(o)&&(p=b[o],q="object"==typeof p&&p instanceof Array?p.length:0,!this._match(q,c[o],d,"and",e)))return!1;return!0;case"$find":case"$findOne":case"$findSub":var r,s,t,u,v,w,x="collection",y={};if(!c.$from)throw a+" missing $from property!";if(c.$fromType&&(x=c.$fromType,!this.db()[x]||"function"!=typeof this.db()[x]))throw a+' cannot operate against $fromType "'+x+'" because the database does not recognise this type of object!';if(r=c.$query||{},s=c.$options||{},"$findSub"===a){if(!c.$path)throw a+" missing $path property!";if(v=c.$path,t=c.$subQuery||{},u=c.$subOptions||{},!(e.$parent&&e.$parent.parent&&e.$parent.parent.key))return this._match(b,r,{},"and",e)&&(w=this._findSub([b],v,t,u)),w&&w.length>0;w=this.db()[x](c.$from).findSub(r,v,t,u)}else w=this.db()[x](c.$from)[a.substr(1)](r,s);return y[e.$parent.parent.key]=w,this._match(b,y,d,"and",e)}return-1}};b.exports=d},{}],26:[function(a,b,c){"use strict";var d={sortAsc:function(a,b){return"string"==typeof a&&"string"==typeof b?a.localeCompare(b):a>b?1:b>a?-1:0},sortDesc:function(a,b){return"string"==typeof a&&"string"==typeof b?b.localeCompare(a):a>b?-1:b>a?1:0}};b.exports=d},{}],27:[function(a,b,c){"use strict";var d,e={};d={tagAdd:function(a){var b,c=this,d=e[a]=e[a]||[];for(b=0;b<d.length;b++)if(d[b]===c)return!0;return d.push(c),c.on&&c.on("drop",function(){c.tagRemove(a)}),!0},tagRemove:function(a){var b,c=e[a];if(c)for(b=0;b<c.length;b++)if(c[b]===this)return c.splice(b,1),!0;return!1},tagLookup:function(a){return e[a]||[]},tagDrop:function(a,b){var c,d,e,f=this.tagLookup(a);if(c=function(){d--,b&&0===d&&b(!1)},f.length)for(d=f.length,e=f.length-1;e>=0;e--)f[e].drop(c);return!0}},b.exports=d},{}],28:[function(a,b,c){"use strict";var d=a("./Overload"),e={addTrigger:function(a,b,c,d){var e,f=this;return e=f._triggerIndexOf(a,b,c),-1===e?(f._trigger=f._trigger||{},f._trigger[b]=f._trigger[b]||{},f._trigger[b][c]=f._trigger[b][c]||[],f._trigger[b][c].push({id:a,method:d,enabled:!0}),!0):!1},removeTrigger:function(a,b,c){var d,e=this;return d=e._triggerIndexOf(a,b,c),d>-1&&e._trigger[b][c].splice(d,1),!1},enableTrigger:new d({string:function(a){var b,c,d,e,f,g=this,h=g._trigger,i=!1;if(h)for(f in h)if(h.hasOwnProperty(f)&&(b=h[f]))for(d in b)if(b.hasOwnProperty(d))for(c=b[d],e=0;e<c.length;e++)c[e].id===a&&(c[e].enabled=!0,i=!0);return i},number:function(a){var b,c,d,e=this,f=e._trigger[a],g=!1;if(f)for(c in f)if(f.hasOwnProperty(c))for(b=f[c],d=0;d<b.length;d++)b[d].enabled=!0,g=!0;return g},"number, number":function(a,b){var c,d,e=this,f=e._trigger[a],g=!1;if(f&&(c=f[b]))for(d=0;d<c.length;d++)c[d].enabled=!0,g=!0;return g},"string, number, number":function(a,b,c){var d=this,e=d._triggerIndexOf(a,b,c);return e>-1?(d._trigger[b][c][e].enabled=!0,!0):!1}}),disableTrigger:new d({string:function(a){var b,c,d,e,f,g=this,h=g._trigger,i=!1;if(h)for(f in h)if(h.hasOwnProperty(f)&&(b=h[f]))for(d in b)if(b.hasOwnProperty(d))for(c=b[d],e=0;e<c.length;e++)c[e].id===a&&(c[e].enabled=!1,i=!0);return i},number:function(a){var b,c,d,e=this,f=e._trigger[a],g=!1;if(f)for(c in f)if(f.hasOwnProperty(c))for(b=f[c],d=0;d<b.length;d++)b[d].enabled=!1,g=!0;return g},"number, number":function(a,b){var c,d,e=this,f=e._trigger[a],g=!1;if(f&&(c=f[b]))for(d=0;d<c.length;d++)c[d].enabled=!1,g=!0;return g},"string, number, number":function(a,b,c){var d=this,e=d._triggerIndexOf(a,b,c);return e>-1?(d._trigger[b][c][e].enabled=!1,!0):!1}}),willTrigger:function(a,b){if(this._trigger&&this._trigger[a]&&this._trigger[a][b]&&this._trigger[a][b].length){var c,d=this._trigger[a][b];for(c=0;c<d.length;c++)if(d[c].enabled)return!0}return!1},processTrigger:function(a,b,c,d,e){var f,g,h,i,j,k=this;if(k._trigger&&k._trigger[b]&&k._trigger[b][c]){for(f=k._trigger[b][c],h=f.length,g=0;h>g;g++)if(i=f[g],i.enabled){if(this.debug()){var l,m;switch(b){case this.TYPE_INSERT:l="insert";break;case this.TYPE_UPDATE:l="update";break;case this.TYPE_REMOVE:l="remove";break;default:l=""}switch(c){case this.PHASE_BEFORE:m="before";break;case this.PHASE_AFTER:m="after";break;default:m=""}}if(j=i.method.call(k,a,d,e),j===!1)return!1;if(void 0!==j&&j!==!0&&j!==!1)throw"ForerunnerDB.Mixin.Triggers: Trigger error: "+j}return!0}},_triggerIndexOf:function(a,b,c){var d,e,f,g=this;if(g._trigger&&g._trigger[b]&&g._trigger[b][c])for(d=g._trigger[b][c],e=d.length,f=0;e>f;f++)if(d[f].id===a)return f;return-1}};b.exports=e},{"./Overload":32}],29:[function(a,b,c){"use strict";var d={_updateProperty:function(a,b,c){a[b]=c,this.debug()&&console.log(this.logIdentifier()+' Setting non-data-bound document property "'+b+'"')},_updateIncrement:function(a,b,c){a[b]+=c},_updateSpliceMove:function(a,b,c){a.splice(c,0,a.splice(b,1)[0]),this.debug()&&console.log(this.logIdentifier()+' Moving non-data-bound document array index from "'+b+'" to "'+c+'"')},_updateSplicePush:function(a,b,c){a.length>b?a.splice(b,0,c):a.push(c)},_updatePush:function(a,b){a.push(b)},_updatePull:function(a,b){a.splice(b,1)},_updateMultiply:function(a,b,c){a[b]*=c},_updateRename:function(a,b,c){a[c]=a[b],delete a[b]},_updateOverwrite:function(a,b,c){a[b]=c},_updateUnset:function(a,b){delete a[b]},_updateClear:function(a,b){var c,d=a[b];if(d&&"object"==typeof d)for(c in d)d.hasOwnProperty(c)&&this._updateUnset(d,c)},_updatePop:function(a,b){var c,d=!1;if(a.length>0)if(b>0){for(c=0;b>c;c++)a.pop();d=!0}else if(0>b){for(c=0;c>b;c--)a.shift();d=!0}return d}};b.exports=d},{}],30:[function(a,b,c){"use strict";var d,e,f,g,h,i=a("./Shared");g=function(){this.init.apply(this,arguments)},g.prototype.init=function(a){var b=this;b._core=a},i.addModule("NodeApiClient",g),i.mixin(g.prototype,"Mixin.Common"),i.mixin(g.prototype,"Mixin.ChainReactor"),d=i.modules.Core,e=d.prototype.init,f=i.modules.Collection,h=i.overload,i.synthesize(g.prototype,"server",function(a){return void 0!==a&&"/"===a.substr(a.length-1,1)&&(a=a.substr(0,a.length-1)),this.$super.call(this,a)}),g.prototype.http=function(a,b,c,d,e){var f,g,h,i=this,j=new XMLHttpRequest;switch(a=a.toUpperCase(),j.onreadystatechange=function(){4===j.readyState&&(200===j.status?e(!1,i.jParse(j.responseText)):e(j.status,j.responseText))},a){case"GET":case"DELETE":case"HEAD":this._sessionData&&(c=void 0!==c?c:{},c[this._sessionData.key]=this._sessionData.obj),f=b+(void 0!==c?"?"+i.jStringify(c):""),h=null;break;case"POST":case"PUT":case"PATCH":this._sessionData&&(g={},g[this._sessionData.key]=this._sessionData.obj),f=b+(void 0!==g?"?"+i.jStringify(g):""),h=void 0!==c?i.jStringify(c):null;break;default:return!1}return j.open(a,f,!0),j.setRequestHeader("Content-Type","application/json;charset=UTF-8"),j.send(h),this},g.prototype.head=new h({"string, function":function(a,b){return this.$main.call(this,a,void 0,{},b)},"string, *, function":function(a,b,c){return this.$main.call(this,a,b,{},c)},"string, *, object, function":function(a,b,c,d){return this.$main.call(this,a,b,c,d)},$main:function(a,b,c,d){return this.http("HEAD",this.server()+a,b,c,d)}}),g.prototype.get=new h({"string, function":function(a,b){return this.$main.call(this,a,void 0,{},b)},"string, *, function":function(a,b,c){return this.$main.call(this,a,b,{},c)},"string, *, object, function":function(a,b,c,d){return this.$main.call(this,a,b,c,d)},$main:function(a,b,c,d){return this.http("GET",this.server()+a,b,c,d)}}),g.prototype.put=new h({"string, function":function(a,b){return this.$main.call(this,a,void 0,{},b)},"string, *, function":function(a,b,c){return this.$main.call(this,a,b,{},c)},"string, *, object, function":function(a,b,c,d){return this.$main.call(this,a,b,c,d)},$main:function(a,b,c,d){return this.http("PUT",this.server()+a,b,c,d)}}),g.prototype.post=new h({"string, function":function(a,b){return this.$main.call(this,a,void 0,{},b)},"string, *, function":function(a,b,c){return this.$main.call(this,a,b,{},c)},"string, *, object, function":function(a,b,c,d){return this.$main.call(this,a,b,c,d)},$main:function(a,b,c,d){return this.http("POST",this.server()+a,b,c,d)}}),g.prototype.patch=new h({"string, function":function(a,b){return this.$main.call(this,a,void 0,{},b)},"string, *, function":function(a,b,c){return this.$main.call(this,a,b,{},c)},"string, *, object, function":function(a,b,c,d){return this.$main.call(this,a,b,c,d)},$main:function(a,b,c,d){return this.http("PATCH",this.server()+a,b,c,d)}}),g.prototype.postPatch=function(a,b,c,d,e){this.head(a+"/"+b,void 0,{},function(c,f){return c?"404"===c?this.http("POST",this.server()+a,f,d,e):void e(c,f):this.http("PATCH",this.server()+a+"/"+b,f,d,e)})},g.prototype["delete"]=new h({"string, function":function(a,b){return this.$main.call(this,a,void 0,{},b)},"string, *, function":function(a,b,c){return this.$main.call(this,a,b,{},c)},"string, *, object, function":function(a,b,c,d){return this.$main.call(this,a,b,c,d)},$main:function(a,b,c,d){return this.http("DELETE",this.server()+a,b,c,d)}}),g.prototype.session=function(a,b){return void 0!==a&&void 0!==b?(this._sessionData={key:a,obj:b},this):this._sessionData},g.prototype.sync=function(a,b,c,d,e){var f,g,h,j=this,k="";this.debug()&&console.log(this.logIdentifier()+" Connecting to API server "+this.server()+b),g=this.server()+b+"/_sync",this._sessionData&&(h=h||{},this._sessionData.key?h[this._sessionData.key]=this._sessionData.obj:i.mixin(h,this._sessionData.obj)),c&&(h=h||{},h.$query=c),d&&(h=h||{},void 0===d.$initialData&&(d.$initialData=!0),h.$options=d),h&&(k=this.jStringify(h),g+="?"+k),f=new EventSource(g),a.__apiConnection=f,f.addEventListener("open",function(c){(!d||d&&d.$initialData)&&j.get(b,h,function(b,c){b||a.upsert(c)})},!1),f.addEventListener("error",function(b){2===f.readyState&&a.unSync()},!1),f.addEventListener("insert",function(b){var c=j.jParse(b.data);a.insert(c)},!1),f.addEventListener("update",function(b){var c=j.jParse(b.data);a.update(c.query,c.update)},!1),f.addEventListener("remove",function(b){var c=j.jParse(b.data);a.remove(c.query)},!1),e&&f.addEventListener("connected",function(a){e(!1)},!1)},f.prototype.sync=new h({"function":function(a){this.$main.call(this,"/"+this._db.name()+"/collection/"+this.name(),null,null,a)},"string, function":function(a,b){this.$main.call(this,"/"+this._db.name()+"/collection/"+a,null,null,b)},"object, function":function(a,b){this.$main.call(this,"/"+this._db.name()+"/collection/"+this.name(),a,null,b)},"string, string, function":function(a,b,c){this.$main.call(this,"/"+this._db.name()+"/"+a+"/"+b,null,null,c)},"string, object, function":function(a,b,c){this.$main.call(this,"/"+this._db.name()+"/collection/"+a,b,null,c)},"string, string, object, function":function(a,b,c,d){this.$main.call(this,"/"+this._db.name()+"/"+a+"/"+b,c,null,d)},"object, object, function":function(a,b,c){this.$main.call(this,"/"+this._db.name()+"/collection/"+this.name(),a,b,c)},"string, object, object, function":function(a,b,c,d){this.$main.call(this,"/"+this._db.name()+"/collection/"+a,b,c,d)},"string, string, object, object, function":function(a,b,c,d,e){this.$main.call(this,"/"+this._db.name()+"/"+a+"/"+b,c,d,e)},$main:function(a,b,c,d){var e=this;if(!this._db||!this._db._core)throw this.logIdentifier()+" Cannot sync for an anonymous collection! (Collection must be attached to a database)";this.unSync(),this._db._core.api.sync(this,a,b,c,d),this.on("drop",function(){e.unSync()})}}),f.prototype.unSync=function(){return this.__apiConnection?(2!==this.__apiConnection.readyState&&this.__apiConnection.close(),delete this.__apiConnection,!0):!1},f.prototype.http=new h({"string, function":function(a,b){this.$main.call(this,a,"/"+this._db.name()+"/collection/"+this.name(),void 0,void 0,{},b)},$main:function(a,b,c,d,e,f){if(this._db&&this._db._core)return this._db._core.api.http("GET",this._db._core.api.server()+b,{$query:c,$options:d},e,f);throw this.logIdentifier()+" Cannot do HTTP for an anonymous collection! (Collection must be attached to a database)"}}),f.prototype.autoHttp=new h({"string, function":function(a,b){this.$main.call(this,a,"/"+this._db.name()+"/collection/"+this.name(),void 0,void 0,{},b)},"string, string, function":function(a,b,c){this.$main.call(this,a,"/"+this._db.name()+"/collection/"+b,void 0,void 0,{},c)},"string, string, string, function":function(a,b,c,d){this.$main.call(this,a,"/"+this._db.name()+"/"+b+"/"+c,void 0,void 0,{},d)},$main:function(a,b,c,d,e,f){var g=this;if(this._db&&this._db._core)return this._db._core.api.http("GET",this._db._core.api.server()+b,{$query:c,$options:d},e,function(b,c){var d;if(!b&&c)switch(a){case"GET":g.insert(c);break;case"POST":c.inserted&&c.inserted.length&&g.insert(c.inserted);break;case"PUT":case"PATCH":if(c instanceof Array)for(d=0;d<c.length;d++)g.updateById(c[d]._id,{$overwrite:c[d]});else g.updateById(c._id,{$overwrite:c});break;case"DELETE":g.remove(c)}f(b,c)});throw this.logIdentifier()+" Cannot do HTTP for an anonymous collection! (Collection must be attached to a database)"}}),d.prototype.init=function(){e.apply(this,arguments),this.api=new g(this)},i.finishModule("NodeApiClient"),b.exports=g},{"./Shared":40}],31:[function(a,b,c){"use strict";var d=a("./Shared"),e=a("./Path"),f=function(a){this.pathSolver=new e,this.counter=0,this.init.apply(this,arguments)};f.prototype.init=function(a){this._data={operation:a,index:{potential:[],used:!1},steps:[],time:{startMs:0,stopMs:0,totalMs:0,process:{}},flag:{},log:[]}},d.addModule("Operation",f),d.mixin(f.prototype,"Mixin.ChainReactor"),f.prototype.start=function(){this._data.time.startMs=(new Date).getTime()},f.prototype.log=function(a){if(a){var b=this._log.length>0?this._data.log[this._data.log.length-1].time:0,c={event:a,time:(new Date).getTime(),delta:0};return this._data.log.push(c),b&&(c.delta=c.time-b),this}return this._data.log},f.prototype.time=function(a){if(void 0!==a){var b=this._data.time.process,c=b[a]=b[a]||{};return c.startMs?(c.stopMs=(new Date).getTime(),c.totalMs=c.stopMs-c.startMs,c.stepObj.totalMs=c.totalMs,delete c.stepObj):(c.startMs=(new Date).getTime(),c.stepObj={name:a},this._data.steps.push(c.stepObj)),this}return this._data.time},f.prototype.flag=function(a,b){return void 0===a||void 0===b?void 0!==a?this._data.flag[a]:this._data.flag:void(this._data.flag[a]=b)},f.prototype.data=function(a,b,c){return void 0!==b?(this.pathSolver.set(this._data,a,b),this):this.pathSolver.get(this._data,a)},f.prototype.pushData=function(a,b,c){this.pathSolver.push(this._data,a,b)},f.prototype.stop=function(){this._data.time.stopMs=(new Date).getTime(),this._data.time.totalMs=this._data.time.stopMs-this._data.time.startMs},d.finishModule("Operation"),b.exports=f},{"./Path":34,"./Shared":40}],32:[function(a,b,c){"use strict";var d=function(a){if(a){var b,c,d,e,f,g,h=this;if(!(a instanceof Array)){d={};for(b in a)if(a.hasOwnProperty(b))if(e=b.replace(/ /g,""),-1===e.indexOf("*"))d[e]=a[b];else for(g=this.generateSignaturePermutations(e),f=0;f<g.length;f++)d[g[f]]||(d[g[f]]=a[b]);a=d}return function(){var d,e,f,g=[];if(a instanceof Array){for(c=a.length,b=0;c>b;b++)if(a[b].length===arguments.length)return h.callExtend(this,"$main",a,a[b],arguments)}else{for(b=0;b<arguments.length&&(e=typeof arguments[b],"object"===e&&arguments[b]instanceof Array&&(e="array"),1!==arguments.length||"undefined"!==e);b++)g.push(e);if(d=g.join(","),a[d])return h.callExtend(this,"$main",a,a[d],arguments);for(b=g.length;b>=0;b--)if(d=g.slice(0,b).join(","),a[d+",..."])return h.callExtend(this,"$main",a,a[d+",..."],arguments)}throw f="function"==typeof this.name?this.name():"Unknown",console.log("Overload: ",a),'ForerunnerDB.Overload "'+f+'": Overloaded method does not have a matching signature "'+d+'" for the passed arguments: '+this.jStringify(g)}}return function(){}};d.prototype.generateSignaturePermutations=function(a){var b,c,d=[],e=["string","object","number","function","undefined"];if(a.indexOf("*")>-1)for(c=0;c<e.length;c++)b=a.replace("*",e[c]),d=d.concat(this.generateSignaturePermutations(b));else d.push(a);return d},d.prototype.callExtend=function(a,b,c,d,e){var f,g;return a&&c[b]?(f=a[b],a[b]=c[b],g=d.apply(a,e),a[b]=f,g):d.apply(a,e)},b.exports=d},{}],33:[function(a,b,c){"use strict";var d,e,f,g;d=a("./Shared");var h=function(){this.init.apply(this,arguments)};h.prototype.init=function(a){var b=this;this._name=a,this._data=new g("__FDB__dc_data_"+this._name),this._collData=new f,this._sources=[],this._sourceDroppedWrap=function(){b._sourceDropped.apply(b,arguments)}},d.addModule("Overview",h),d.mixin(h.prototype,"Mixin.Common"),d.mixin(h.prototype,"Mixin.ChainReactor"),d.mixin(h.prototype,"Mixin.Constants"),d.mixin(h.prototype,"Mixin.Triggers"),d.mixin(h.prototype,"Mixin.Events"),d.mixin(h.prototype,"Mixin.Tags"),f=a("./Collection"),g=a("./Document"),e=d.modules.Db,d.synthesize(h.prototype,"state"),d.synthesize(h.prototype,"db"),d.synthesize(h.prototype,"name"),d.synthesize(h.prototype,"query",function(a){var b=this.$super(a);return void 0!==a&&this._refresh(),b}),d.synthesize(h.prototype,"queryOptions",function(a){var b=this.$super(a);return void 0!==a&&this._refresh(),b}),d.synthesize(h.prototype,"reduce",function(a){var b=this.$super(a);return void 0!==a&&this._refresh(),b}),h.prototype.from=function(a){return void 0!==a?("string"==typeof a&&(a=this._db.collection(a)),this._setFrom(a),this):this._sources},h.prototype.find=function(){return this._collData.find.apply(this._collData,arguments)},h.prototype.exec=function(){var a=this.reduce();return a?a.apply(this):void 0},h.prototype.count=function(){return this._collData.count.apply(this._collData,arguments)},h.prototype._setFrom=function(a){for(;this._sources.length;)this._removeSource(this._sources[0]);return this._addSource(a),this},h.prototype._addSource=function(a){return a&&"View"===a.className&&(a=a.privateData(),this.debug()&&console.log(this.logIdentifier()+' Using internal private data "'+a.instanceIdentifier()+'" for IO graph linking')),-1===this._sources.indexOf(a)&&(this._sources.push(a),a.chain(this),a.on("drop",this._sourceDroppedWrap),this._refresh()),this},h.prototype._removeSource=function(a){a&&"View"===a.className&&(a=a.privateData(),this.debug()&&console.log(this.logIdentifier()+' Using internal private data "'+a.instanceIdentifier()+'" for IO graph linking'));var b=this._sources.indexOf(a);return b>-1&&(this._sources.splice(a,1),a.unChain(this),a.off("drop",this._sourceDroppedWrap),this._refresh()),this},h.prototype._sourceDropped=function(a){a&&this._removeSource(a)},h.prototype._refresh=function(){if(!this.isDropped()){if(this._sources&&this._sources[0]){this._collData.primaryKey(this._sources[0].primaryKey());var a,b=[];for(a=0;a<this._sources.length;a++)b=b.concat(this._sources[a].find(this._query,this._queryOptions));this._collData.setData(b)}if(this._reduce){var c=this._reduce.apply(this);this._data.setData(c)}}},h.prototype._chainHandler=function(a){switch(a.type){case"setData":case"insert":case"update":case"remove":this._refresh()}},h.prototype.data=function(){return this._data},h.prototype.drop=function(a){if(!this.isDropped()){for(this._state="dropped",delete this._data,delete this._collData;this._sources.length;)this._removeSource(this._sources[0]);delete this._sources,this._db&&this._name&&delete this._db._overview[this._name],delete this._name,this.emit("drop",this),a&&a(!1,!0),delete this._listeners}return!0},e.prototype.overview=function(a){return a?a instanceof h?a:(this._overview=this._overview||{},this._overview[a]=this._overview[a]||new h(a).db(this),this._overview[a]):this._overview||{}},e.prototype.overviews=function(){var a,b,c=[];for(b in this._overview)this._overview.hasOwnProperty(b)&&(a=this._overview[b],c.push({name:b,count:a.count(),linked:void 0!==a.isLinked?a.isLinked():!1}));return c},d.finishModule("Overview"),b.exports=h},{"./Collection":6,"./Document":11,"./Shared":40}],34:[function(a,b,c){"use strict";var d=a("./Shared"),e=function(a){this.init.apply(this,arguments)};e.prototype.init=function(a){a&&this.path(a)},d.addModule("Path",e),d.mixin(e.prototype,"Mixin.Common"),d.mixin(e.prototype,"Mixin.ChainReactor"),e.prototype.path=function(a){return void 0!==a?(this._path=this.clean(a),this._pathParts=this._path.split("."),this):this._path},e.prototype.hasObjectPaths=function(a,b){var c,d=!0;for(c in a)if(a.hasOwnProperty(c)){if(void 0===b[c])return!1;if("object"==typeof a[c]&&(d=this.hasObjectPaths(a[c],b[c]),!d))return!1}return d},e.prototype.countKeys=function(a){var b,c=0;for(b in a)a.hasOwnProperty(b)&&void 0!==a[b]&&("object"!=typeof a[b]?c++:c+=this.countKeys(a[b]));return c},e.prototype.countObjectPaths=function(a,b){var c,d,e={},f=0,g=0;for(d in b)b.hasOwnProperty(d)&&("object"==typeof b[d]?(c=this.countObjectPaths(a[d],b[d]),e[d]=c.matchedKeys,g+=c.totalKeyCount,f+=c.matchedKeyCount):(g++,a&&a[d]&&"object"!=typeof a[d]?(e[d]=!0,f++):e[d]=!1));return{matchedKeys:e,matchedKeyCount:f,totalKeyCount:g}},e.prototype.parse=function(a,b){var c,d,e,f=[],g="";for(d in a)if(a.hasOwnProperty(d))if(g=d,"object"==typeof a[d])if(b)for(c=this.parse(a[d],b),e=0;e<c.length;e++)f.push({path:g+"."+c[e].path,value:c[e].value});else for(c=this.parse(a[d]),e=0;e<c.length;e++)f.push({path:g+"."+c[e].path});else b?f.push({path:g,value:a[d]}):f.push({path:g});return f},e.prototype.parseArr=function(a,b){return b=b||{},this._parseArr(a,"",[],b)},e.prototype._parseArr=function(a,b,c,d){var e,f="";b=b||"",c=c||[];for(e in a)a.hasOwnProperty(e)&&(!d.ignore||d.ignore&&!d.ignore.test(e))&&(f=b?b+"."+e:e,"object"==typeof a[e]?(d.verbose&&c.push(f),this._parseArr(a[e],f,c,d)):c.push(f));return c},e.prototype.set=function(a,b,c){if(void 0!==a&&void 0!==b){var d,e;b=this.clean(b),d=b.split("."),e=d.shift(),d.length?(a[e]=a[e]||{},this.set(a[e],d.join("."),c)):a[e]=c}return a},e.prototype.get=function(a,b){return this.value(a,b)[0]},e.prototype.value=function(a,b,c){var d,e,f,g,h,i,j,k,l;if(b&&-1===b.indexOf("."))return[a[b]];if(void 0!==a&&"object"==typeof a){if((!c||c&&!c.skipArrCheck)&&a instanceof Array){for(j=[],k=0;k<a.length;k++)j.push(this.get(a[k],b));return j}for(i=[],void 0!==b&&(b=this.clean(b),d=b.split(".")),e=d||this._pathParts,f=e.length,g=a,k=0;f>k;k++){if(g=g[e[k]],h instanceof Array){for(l=0;l<h.length;l++)i=i.concat(this.value(h,l+"."+e[k],{skipArrCheck:!0}));return i}if(!g||"object"!=typeof g)break;h=g}return[g]}return[]},e.prototype.push=function(a,b,c){if(void 0!==a&&void 0!==b){var d,e;if(b=this.clean(b),d=b.split("."),e=d.shift(),d.length)a[e]=a[e]||{},this.set(a[e],d.join("."),c);else{if(a[e]=a[e]||[],!(a[e]instanceof Array))throw"ForerunnerDB.Path: Cannot push to a path whose endpoint is not an array!";a[e].push(c)}}return a},e.prototype.keyValue=function(a,b){var c,d,e,f,g,h,i;for(void 0!==b&&(b=this.clean(b),c=b.split(".")),d=c||this._pathParts,e=d.length,f=a,i=0;e>i;i++){if(f=f[d[i]],!f||"object"!=typeof f){h=d[i]+":"+f;break}g=f}return h},e.prototype.set=function(a,b,c){if(void 0!==a&&void 0!==b){var d,e;b=this.clean(b),d=b.split("."),e=d.shift(),d.length?(a[e]=a[e]||{},this.set(a[e],d.join("."),c)):a[e]=c}return a},e.prototype.clean=function(a){return"."===a.substr(0,1)&&(a=a.substr(1,a.length-1)),a},d.finishModule("Path"),b.exports=e},{"./Shared":40}],35:[function(a,b,c){"use strict";var d,e,f,g,h,i,j,k,l,m=a("./Shared"),n=a("async"),o=a("localforage");a("./PersistCompress"),a("./PersistCrypto");k=function(){this.init.apply(this,arguments)},k.prototype.localforage=o,k.prototype.init=function(a){var b=this;this._encodeSteps=[function(){return b._encode.apply(b,arguments)}],this._decodeSteps=[function(){return b._decode.apply(b,arguments)}],a.isClient()&&void 0!==window.Storage&&(this.mode("localforage"),o.config({driver:[o.INDEXEDDB,o.WEBSQL,o.LOCALSTORAGE],name:String(a.core().name()),storeName:"FDB"}))},m.addModule("Persist",k),m.mixin(k.prototype,"Mixin.ChainReactor"),m.mixin(k.prototype,"Mixin.Common"),d=m.modules.Db,e=a("./Collection"),f=e.prototype.drop,g=a("./CollectionGroup"),h=e.prototype.init,i=d.prototype.init,j=d.prototype.drop,l=m.overload,m.synthesize(k.prototype,"auto",function(a){var b=this;return void 0!==a&&(a?(this._db.on("create",function(){b._autoLoad.apply(b,arguments)}),this._db.on("change",function(){b._autoSave.apply(b,arguments)}),this._db.debug()&&console.log(this._db.logIdentifier()+" Automatic load/save enabled")):(this._db.off("create",this._autoLoad),this._db.off("change",this._autoSave),this._db.debug()&&console.log(this._db.logIdentifier()+" Automatic load/save disbled"))),this.$super.call(this,a)}),k.prototype._autoLoad=function(a,b,c){var d=this;"function"==typeof a.load?(d._db.debug()&&console.log(d._db.logIdentifier()+" Auto-loading data for "+b+":",c),a.load(function(a,b){a&&d._db.debug()&&console.log(d._db.logIdentifier()+" Automatic load failed:",a),d.emit("load",a,b)})):d._db.debug()&&console.log(d._db.logIdentifier()+" Auto-load for "+b+":",c,"no load method, skipping")},k.prototype._autoSave=function(a,b,c){var d=this;"function"==typeof a.save&&(d._db.debug()&&console.log(d._db.logIdentifier()+" Auto-saving data for "+b+":",c),a.save(function(a,b){a&&d._db.debug()&&console.log(d._db.logIdentifier()+" Automatic save failed:",a),d.emit("save",a,b)}))},k.prototype.mode=function(a){return void 0!==a?(this._mode=a,this):this._mode},k.prototype.driver=function(a){if(void 0!==a){switch(a.toUpperCase()){case"LOCALSTORAGE":o.setDriver(o.LOCALSTORAGE);break;case"WEBSQL":o.setDriver(o.WEBSQL);break;case"INDEXEDDB":o.setDriver(o.INDEXEDDB);break;default:throw"ForerunnerDB.Persist: The persistence driver you have specified is not found. Please use either IndexedDB, WebSQL or LocalStorage!"}return this}return o.driver()},k.prototype.decode=function(a,b){n.waterfall([function(b){b&&b(!1,a,{})}].concat(this._decodeSteps),b)},k.prototype.encode=function(a,b){n.waterfall([function(b){b&&b(!1,a,{})}].concat(this._encodeSteps),b)},m.synthesize(k.prototype,"encodeSteps"),m.synthesize(k.prototype,"decodeSteps"),k.prototype.addStep=new l({object:function(a){this.$main.call(this,function(){a.encode.apply(a,arguments)},function(){a.decode.apply(a,arguments)},0)},"function, function":function(a,b){this.$main.call(this,a,b,0)},"function, function, number":function(a,b,c){this.$main.call(this,a,b,c)},$main:function(a,b,c){0===c||void 0===c?(this._encodeSteps.push(a),this._decodeSteps.unshift(b)):(this._encodeSteps.splice(c,0,a),this._decodeSteps.splice(this._decodeSteps.length-c,0,b))}}),k.prototype.unwrap=function(a){var b,c=a.split("::fdb::");switch(c[0]){case"json":b=this.jParse(c[1]);break;case"raw":b=c[1]}},k.prototype._decode=function(a,b,c){var d,e;if(a){switch(d=a.split("::fdb::"),d[0]){case"json":e=this.jParse(d[1]);break;case"raw":e=d[1]}e?(b.foundData=!0,b.rowCount=e.length):b.foundData=!1,c&&c(!1,e,b)}else b.foundData=!1,b.rowCount=0,c&&c(!1,a,b)},k.prototype._encode=function(a,b,c){var d=a;a="object"==typeof a?"json::fdb::"+this.jStringify(a):"raw::fdb::"+a,d?(b.foundData=!0,b.rowCount=d.length):b.foundData=!1,c&&c(!1,a,b)},k.prototype.save=function(a,b,c){switch(this.mode()){case"localforage":this.encode(b,function(b,d,e){o.setItem(a,d).then(function(a){c&&c(!1,a,e)},function(a){c&&c(a)})});break;default:c&&c("No data handler.")}},k.prototype.load=function(a,b){var c=this;switch(this.mode()){case"localforage":o.getItem(a).then(function(a){c.decode(a,b)},function(a){b&&b(a)});break;default:b&&b("No data handler or unrecognised data type.")}},k.prototype.drop=function(a,b){switch(this.mode()){case"localforage":o.removeItem(a).then(function(){b&&b(!1)},function(a){b&&b(a)});break;default:b&&b("No data handler or unrecognised data type.")}},e.prototype.drop=new l({"":function(){this.isDropped()||this.drop(!0)},"function":function(a){this.isDropped()||this.drop(!0,a)},"boolean":function(a){if(!this.isDropped()){if(a){if(!this._name)throw"ForerunnerDB.Persist: Cannot drop a collection's persistent storage when no name assigned to collection!";this._db&&(this._db.persist.drop(this._db._name+"-"+this._name),this._db.persist.drop(this._db._name+"-"+this._name+"-metaData"))}f.call(this)}},"boolean, function":function(a,b){var c=this;if(!this.isDropped()){if(!a)return f.call(this,b);if(this._name){if(this._db)return this._db.persist.drop(this._db._name+"-"+this._name,function(){c._db.persist.drop(c._db._name+"-"+c._name+"-metaData",b)}),f.call(this);b&&b("Cannot drop a collection's persistent storage when the collection is not attached to a database!")}else b&&b("Cannot drop a collection's persistent storage when no name assigned to collection!")}}}),e.prototype.save=function(a){var b,c=this;c._name?c._db?(b=function(){c._db.persist.save(c._db._name+"-"+c._name,c._data,function(b,d,e){b?a&&a(b):c._db.persist.save(c._db._name+"-"+c._name+"-metaData",c.metaData(),function(b,c,d){a&&a(b,c,e,d)})})},c.isProcessingQueue()?c.on("queuesComplete",function(){b()}):b()):a&&a("Cannot save a collection that is not attached to a database!"):a&&a("Cannot save a collection with no assigned name!")},e.prototype.load=function(a){var b=this;b._name?b._db?b._db.persist.load(b._db._name+"-"+b._name,function(c,d,e){c?a&&a(c):(d&&(b.remove({}),b.insert(d)),b._db.persist.load(b._db._name+"-"+b._name+"-metaData",function(c,d,f){c||d&&b.metaData(d),a&&a(c,e,f)}))}):a&&a("Cannot load a collection that is not attached to a database!"):a&&a("Cannot load a collection with no assigned name!")},e.prototype.saveCustom=function(a){var b,c=this,d={};c._name?c._db?(b=function(){c.encode(c._data,function(b,e,f){b?a(b):(d.data={name:c._db._name+"-"+c._name,store:e,tableStats:f},c.encode(c._data,function(b,e,f){b?a(b):(d.metaData={name:c._db._name+"-"+c._name+"-metaData",store:e,tableStats:f},a(!1,d))}))})},c.isProcessingQueue()?c.on("queuesComplete",function(){b()}):b()):a&&a("Cannot save a collection that is not attached to a database!"):a&&a("Cannot save a collection with no assigned name!")},e.prototype.loadCustom=function(a,b){var c=this;c._name?c._db?a.data&&a.data.store?a.metaData&&a.metaData.store?c.decode(a.data.store,function(d,e,f){d?b(d):e&&(c.remove({}),c.insert(e),c.decode(a.metaData.store,function(a,d,e){a?b(a):d&&(c.metaData(d),b&&b(a,f,e))}))}):b('No "metaData" key found in passed object!'):b('No "data" key found in passed object!'):b&&b("Cannot load a collection that is not attached to a database!"):b&&b("Cannot load a collection with no assigned name!")},d.prototype.init=function(){i.apply(this,arguments),this.persist=new k(this)},d.prototype.load=new l({"function":function(a){this.$main.call(this,{},a)},"object, function":function(a,b){this.$main.call(this,a,b)},$main:function(a,b){var c,d,e=this._collection,f=e.keys(),g=f.length; c=function(a){a?b&&b(a):(g--,0===g&&b&&b(!1))};for(d in e)e.hasOwnProperty(d)&&(a?e[d].loadCustom(a,c):e[d].load(c))}}),d.prototype.save=new l({"function":function(a){this.$main.call(this,{},a)},"object, function":function(a,b){this.$main.call(this,a,b)},$main:function(a,b){var c,d,e=this._collection,f=e.keys(),g=f.length;c=function(a){a?b&&b(a):(g--,0===g&&b&&b(!1))};for(d in e)e.hasOwnProperty(d)&&(a.custom?e[d].saveCustom(c):e[d].save(c))}}),m.finishModule("Persist"),b.exports=k},{"./Collection":6,"./CollectionGroup":7,"./PersistCompress":36,"./PersistCrypto":37,"./Shared":40,async:43,localforage:79}],36:[function(a,b,c){"use strict";var d=a("./Shared"),e=a("pako"),f=function(){this.init.apply(this,arguments)};f.prototype.init=function(a){},d.mixin(f.prototype,"Mixin.Common"),f.prototype.encode=function(a,b,c){var d,f,g,h={data:a,type:"fdbCompress",enabled:!1};d=a.length,g=e.deflate(a,{to:"string"}),f=g.length,d>f&&(h.data=g,h.enabled=!0),b.compression={enabled:h.enabled,compressedBytes:f,uncompressedBytes:d,effect:Math.round(100/d*f)+"%"},c(!1,this.jStringify(h),b)},f.prototype.decode=function(a,b,c){var d,f=!1;a?(a=this.jParse(a),a.enabled?(d=e.inflate(a.data,{to:"string"}),f=!0):(d=a.data,f=!1),b.compression={enabled:f},c&&c(!1,d,b)):c&&c(!1,d,b)},d.plugins.FdbCompress=f,b.exports=f},{"./Shared":40,pako:80}],37:[function(a,b,c){"use strict";var d=a("./Shared"),e=a("crypto-js"),f=function(){this.init.apply(this,arguments)};f.prototype.init=function(a){if(!a||!a.pass)throw'Cannot initialise persistent storage encryption without a passphrase provided in the passed options object as the "pass" field.';this._algo=a.algo||"AES",this._pass=a.pass},d.mixin(f.prototype,"Mixin.Common"),d.synthesize(f.prototype,"pass"),f.prototype.stringify=function(a){var b={ct:a.ciphertext.toString(e.enc.Base64)};return a.iv&&(b.iv=a.iv.toString()),a.salt&&(b.s=a.salt.toString()),this.jStringify(b)},f.prototype.parse=function(a){var b=this.jParse(a),c=e.lib.CipherParams.create({ciphertext:e.enc.Base64.parse(b.ct)});return b.iv&&(c.iv=e.enc.Hex.parse(b.iv)),b.s&&(c.salt=e.enc.Hex.parse(b.s)),c},f.prototype.encode=function(a,b,c){var d,f=this,g={type:"fdbCrypto"};d=e[this._algo].encrypt(a,this._pass,{format:{stringify:function(){return f.stringify.apply(f,arguments)},parse:function(){return f.parse.apply(f,arguments)}}}),g.data=d.toString(),g.enabled=!0,b.encryption={enabled:g.enabled},c&&c(!1,this.jStringify(g),b)},f.prototype.decode=function(a,b,c){var d,f=this;a?(a=this.jParse(a),d=e[this._algo].decrypt(a.data,this._pass,{format:{stringify:function(){return f.stringify.apply(f,arguments)},parse:function(){return f.parse.apply(f,arguments)}}}).toString(e.enc.Utf8),c&&c(!1,d,b)):c&&c(!1,a,b)},d.plugins.FdbCrypto=f,b.exports=f},{"./Shared":40,"crypto-js":52}],38:[function(a,b,c){"use strict";var d=a("./Shared"),e=function(a,b,c){if(!(a&&b&&c))throw"ForerunnerDB.ReactorIO: ReactorIO requires in, out and process arguments to instantiate!";if(this._reactorIn=a,this._reactorOut=b,this._chainHandler=c,!a.chain)throw"ForerunnerDB.ReactorIO: ReactorIO requires passed in and out objects to implement the ChainReactor mixin!";a.chain(this),this.chain(b)};d.addModule("ReactorIO",e),e.prototype.drop=function(){return this.isDropped()||(this._state="dropped",this._reactorIn&&this._reactorIn.unChain(this),this._reactorOut&&this.unChain(this._reactorOut),delete this._reactorIn,delete this._reactorOut,delete this._chainHandler,this.emit("drop",this),delete this._listeners),!0},d.synthesize(e.prototype,"state"),d.mixin(e.prototype,"Mixin.Common"),d.mixin(e.prototype,"Mixin.ChainReactor"),d.mixin(e.prototype,"Mixin.Events"),d.finishModule("ReactorIO"),b.exports=e},{"./Shared":40}],39:[function(a,b,c){"use strict";var d=function(){this.init.apply(this,arguments)};d.prototype.init=function(){this._encoder=[],this._decoder={},this.registerEncoder("$date",function(a){return a instanceof Date?a.toISOString():void 0}),this.registerDecoder("$date",function(a){return new Date(a)}),this.registerEncoder("$regexp",function(a){return a instanceof RegExp?{source:a.source,params:""+(a.global?"g":"")+(a.ignoreCase?"i":"")}:void 0}),this.registerDecoder("$regexp",function(a){var b=typeof a;return"object"===b?new RegExp(a.source,a.params):"string"===b?new RegExp(a):void 0})},d.prototype.registerEncoder=function(a,b){this._encoder.push(function(c){var d,e=b(c);return void 0!==e&&(d={},d[a]=e),d})},d.prototype.registerDecoder=function(a,b){this._decoder[a]=b},d.prototype._encode=function(a){for(var b,c=this._encoder.length;c--&&!b;)b=this._encoder[c](a);return b},d.prototype.parse=function(a){return this._parse(JSON.parse(a))},d.prototype._parse=function(a,b){var c;if("object"==typeof a&&null!==a){b=a instanceof Array?b||[]:b||{};for(c in a)if(a.hasOwnProperty(c)){if("$"===c.substr(0,1)&&this._decoder[c])return this._decoder[c](a[c]);b[c]=this._parse(a[c],b[c])}}else b=a;return b},d.prototype.stringify=function(a){return JSON.stringify(this._stringify(a))},d.prototype._stringify=function(a,b){var c,d;if("object"==typeof a&&null!==a){if(c=this._encode(a))return c;b=a instanceof Array?b||[]:b||{};for(d in a)a.hasOwnProperty(d)&&(b[d]=this._stringify(a[d],b[d]))}else b=a;return b},b.exports=d},{}],40:[function(a,b,c){"use strict";var d=a("./Overload"),e={version:"1.3.611",modules:{},plugins:{},_synth:{},addModule:function(a,b){this.modules[a]=b,this.emit("moduleLoad",[a,b])},finishModule:function(a){if(!this.modules[a])throw"ForerunnerDB.Shared: finishModule called on a module that has not been registered with addModule(): "+a;this.modules[a]._fdbFinished=!0,this.modules[a].prototype?this.modules[a].prototype.className=a:this.modules[a].className=a,this.emit("moduleFinished",[a,this.modules[a]])},moduleFinished:function(a,b){this.modules[a]&&this.modules[a]._fdbFinished?b&&b(a,this.modules[a]):this.on("moduleFinished",b)},moduleExists:function(a){return Boolean(this.modules[a])},mixin:new d({"object, string":function(a,b){var c;if("string"==typeof b&&(c=this.mixins[b],!c))throw"ForerunnerDB.Shared: Cannot find mixin named: "+b;return this.$main.call(this,a,c)},"object, *":function(a,b){return this.$main.call(this,a,b)},$main:function(a,b){if(b&&"object"==typeof b)for(var c in b)b.hasOwnProperty(c)&&(a[c]=b[c]);return a}}),synthesize:function(a,b,c){if(this._synth[b]=this._synth[b]||function(a){return void 0!==a?(this["_"+b]=a,this):this["_"+b]},c){var d=this;a[b]=function(){var a,e=this.$super;return this.$super=d._synth[b],a=c.apply(this,arguments),this.$super=e,a}}else a[b]=this._synth[b]},overload:d,mixins:{"Mixin.Common":a("./Mixin.Common"),"Mixin.Events":a("./Mixin.Events"),"Mixin.ChainReactor":a("./Mixin.ChainReactor"),"Mixin.CRUD":a("./Mixin.CRUD"),"Mixin.Constants":a("./Mixin.Constants"),"Mixin.Triggers":a("./Mixin.Triggers"),"Mixin.Sorting":a("./Mixin.Sorting"),"Mixin.Matching":a("./Mixin.Matching"),"Mixin.Updating":a("./Mixin.Updating"),"Mixin.Tags":a("./Mixin.Tags")}};e.mixin(e,"Mixin.Events"),b.exports=e},{"./Mixin.CRUD":20,"./Mixin.ChainReactor":21,"./Mixin.Common":22,"./Mixin.Constants":23,"./Mixin.Events":24,"./Mixin.Matching":25,"./Mixin.Sorting":26,"./Mixin.Tags":27,"./Mixin.Triggers":28,"./Mixin.Updating":29,"./Overload":32}],41:[function(a,b,c){Array.prototype.filter||(Array.prototype.filter=function(a){if(void 0===this||null===this)throw new TypeError;var b=Object(this),c=b.length>>>0;if("function"!=typeof a)throw new TypeError;for(var d=[],e=arguments.length>=2?arguments[1]:void 0,f=0;c>f;f++)if(f in b){var g=b[f];a.call(e,g,f,b)&&d.push(g)}return d}),"function"!=typeof Object.create&&(Object.create=function(){var a=function(){};return function(b){if(arguments.length>1)throw Error("Second argument not supported");if("object"!=typeof b)throw TypeError("Argument must be an object");a.prototype=b;var c=new a;return a.prototype=null,c}}()),Array.prototype.indexOf||(Array.prototype.indexOf=function(a,b){var c;if(null===this)throw new TypeError('"this" is null or not defined');var d=Object(this),e=d.length>>>0;if(0===e)return-1;var f=+b||0;if(Math.abs(f)===1/0&&(f=0),f>=e)return-1;for(c=Math.max(f>=0?f:e-Math.abs(f),0);e>c;){if(c in d&&d[c]===a)return c;c++}return-1}),b.exports={}},{}],42:[function(a,b,c){"use strict";var d,e,f,g,h,i,j,k,l=a("./Overload");d=a("./Shared");var m=function(a,b,c){this.init.apply(this,arguments)};m.prototype.init=function(a,b,c){var d=this;this._name=a,this._listeners={},this._querySettings={},this._debug={},this.query(b,c,!1),this._collectionDroppedWrap=function(){d._collectionDropped.apply(d,arguments)},this._privateData=new f(this.name()+"_internalPrivate"),this.on("joinChange",function(){d.refresh()})},d.addModule("View",m),d.mixin(m.prototype,"Mixin.Common"),d.mixin(m.prototype,"Mixin.ChainReactor"),d.mixin(m.prototype,"Mixin.Constants"),d.mixin(m.prototype,"Mixin.Triggers"),d.mixin(m.prototype,"Mixin.Tags"),f=a("./Collection"),g=a("./CollectionGroup"),k=a("./ActiveBucket"),j=a("./ReactorIO"),h=f.prototype.init,e=d.modules.Db,i=e.prototype.init,d.synthesize(m.prototype,"state"),d.synthesize(m.prototype,"name"),d.synthesize(m.prototype,"cursor",function(a){return void 0===a?this._cursor||{}:void this.$super.apply(this,arguments)}),m.prototype.insert=function(){this._from.insert.apply(this._from,arguments)},m.prototype.update=function(){this._from.update.apply(this._from,arguments)},m.prototype.updateById=function(){this._from.updateById.apply(this._from,arguments)},m.prototype.remove=function(){this._from.remove.apply(this._from,arguments)},m.prototype.find=function(a,b){return this.publicData().find(a,b)},m.prototype.findOne=function(a,b){return this.publicData().findOne(a,b)},m.prototype.findById=function(a,b){return this.publicData().findById(a,b)},m.prototype.findSub=function(a,b,c,d){return this.publicData().findSub(a,b,c,d)},m.prototype.findSubOne=function(a,b,c,d){return this.publicData().findSubOne(a,b,c,d)},m.prototype.data=function(){return this._privateData},m.prototype.from=function(a,b){var c=this;if(void 0!==a){this._from&&(this._from.off("drop",this._collectionDroppedWrap),delete this._from),this._io&&(this._io.drop(),delete this._io),"string"==typeof a&&(a=this._db.collection(a)),"View"===a.className&&(a=a.privateData(),this.debug()&&console.log(this.logIdentifier()+' Using internal private data "'+a.instanceIdentifier()+'" for IO graph linking')),this._from=a,this._from.on("drop",this._collectionDroppedWrap),this._io=new j(a,this,function(a){var b,d,e,f,g,h,i;if(c&&!c.isDropped()&&c._querySettings.query){if("insert"===a.type){if(b=a.data,b instanceof Array)for(f=[],i=0;i<b.length;i++)c._privateData._match(b[i],c._querySettings.query,c._querySettings.options,"and",{})&&(f.push(b[i]),g=!0);else c._privateData._match(b,c._querySettings.query,c._querySettings.options,"and",{})&&(f=b,g=!0);return g&&this.chainSend("insert",f),!0}if("update"===a.type){if(d=c._privateData.diff(c._from.subset(c._querySettings.query,c._querySettings.options)),d.insert.length||d.remove.length){if(d.insert.length&&this.chainSend("insert",d.insert),d.update.length)for(h=c._privateData.primaryKey(),i=0;i<d.update.length;i++)e={},e[h]=d.update[i][h],this.chainSend("update",{query:e,update:d.update[i]});if(d.remove.length){h=c._privateData.primaryKey();var j=[],k={query:{$or:j}};for(i=0;i<d.remove.length;i++)j.push({_id:d.remove[i][h]});this.chainSend("remove",k)}return!0}return!1}}return!1});var d=a.find(this._querySettings.query,this._querySettings.options);return this._privateData.primaryKey(a.primaryKey()),this._privateData.setData(d,{},b),this._querySettings.options&&this._querySettings.options.$orderBy?this.rebuildActiveBucket(this._querySettings.options.$orderBy):this.rebuildActiveBucket(),this}return this._from},m.prototype._collectionDropped=function(a){a&&delete this._from},m.prototype.ensureIndex=function(){return this._privateData.ensureIndex.apply(this._privateData,arguments)},m.prototype._chainHandler=function(a){var b,c,d,e,f,g,h,i;switch(this.debug()&&console.log(this.logIdentifier()+" Received chain reactor data"),a.type){case"setData":this.debug()&&console.log(this.logIdentifier()+' Setting data in underlying (internal) view collection "'+this._privateData.name()+'"');var j=this._from.find(this._querySettings.query,this._querySettings.options);this._privateData.setData(j);break;case"insert":if(this.debug()&&console.log(this.logIdentifier()+' Inserting some data into underlying (internal) view collection "'+this._privateData.name()+'"'),a.data=this.decouple(a.data),a.data instanceof Array||(a.data=[a.data]),this._querySettings.options&&this._querySettings.options.$orderBy)for(b=a.data,c=b.length,d=0;c>d;d++)e=this._activeBucket.insert(b[d]),this._privateData._insertHandle(a.data,e);else e=this._privateData._data.length,this._privateData._insertHandle(a.data,e);break;case"update":if(this.debug()&&console.log(this.logIdentifier()+' Updating some data in underlying (internal) view collection "'+this._privateData.name()+'"'),g=this._privateData.primaryKey(),f=this._privateData.update(a.data.query,a.data.update,a.data.options),this._querySettings.options&&this._querySettings.options.$orderBy)for(c=f.length,d=0;c>d;d++)h=f[d],this._activeBucket.remove(h),i=this._privateData._data.indexOf(h),e=this._activeBucket.insert(h),i!==e&&this._privateData._updateSpliceMove(this._privateData._data,i,e);break;case"remove":this.debug()&&console.log(this.logIdentifier()+' Removing some data from underlying (internal) view collection "'+this._privateData.name()+'"'),this._privateData.remove(a.data.query,a.options)}},m.prototype.on=function(){return this._privateData.on.apply(this._privateData,arguments)},m.prototype.off=function(){return this._privateData.off.apply(this._privateData,arguments)},m.prototype.emit=function(){return this._privateData.emit.apply(this._privateData,arguments)},m.prototype.deferEmit=function(){return this._privateData.deferEmit.apply(this._privateData,arguments)},m.prototype.distinct=function(a,b,c){var d=this.publicData();return d.distinct.apply(d,arguments)},m.prototype.primaryKey=function(){return this.publicData().primaryKey()},m.prototype.drop=function(a){return this.isDropped()?!1:(this._from&&(this._from.off("drop",this._collectionDroppedWrap),this._from._removeView(this)),(this.debug()||this._db&&this._db.debug())&&console.log(this.logIdentifier()+" Dropping"),this._state="dropped",this._io&&this._io.drop(),this._privateData&&this._privateData.drop(),this._publicData&&this._publicData!==this._privateData&&this._publicData.drop(),this._db&&this._name&&delete this._db._view[this._name],this.emit("drop",this),a&&a(!1,!0),delete this._chain,delete this._from,delete this._privateData,delete this._io,delete this._listeners,delete this._querySettings,delete this._db,!0)},d.synthesize(m.prototype,"db",function(a){return a&&(this.privateData().db(a),this.publicData().db(a),this.debug(a.debug()),this.privateData().debug(a.debug()),this.publicData().debug(a.debug())),this.$super.apply(this,arguments)}),m.prototype.queryData=function(a,b,c){return void 0!==a&&(this._querySettings.query=a,a.$findSub&&!a.$findSub.$from&&(a.$findSub.$from=this._privateData.name()),a.$findSubOne&&!a.$findSubOne.$from&&(a.$findSubOne.$from=this._privateData.name())),void 0!==b&&(this._querySettings.options=b),void 0!==a||void 0!==b?((void 0===c||c===!0)&&this.refresh(),this):this._querySettings},m.prototype.queryAdd=function(a,b,c){this._querySettings.query=this._querySettings.query||{};var d,e=this._querySettings.query;if(void 0!==a)for(d in a)a.hasOwnProperty(d)&&(void 0===e[d]||void 0!==e[d]&&b!==!1)&&(e[d]=a[d]);(void 0===c||c===!0)&&this.refresh()},m.prototype.queryRemove=function(a,b){var c,d=this._querySettings.query;if(d){if(void 0!==a)for(c in a)a.hasOwnProperty(c)&&delete d[c];(void 0===b||b===!0)&&this.refresh()}},m.prototype.query=new l({"":function(){return this._querySettings.query},object:function(a){return this.$main.call(this,a,void 0,!0)},"*, boolean":function(a,b){return this.$main.call(this,a,void 0,b)},"object, object":function(a,b){return this.$main.call(this,a,b,!0)},"*, *, boolean":function(a,b,c){return this.$main.call(this,a,b,c)},$main:function(a,b,c){return void 0!==a&&(this._querySettings.query=a,a.$findSub&&!a.$findSub.$from&&(a.$findSub.$from=this._privateData.name()),a.$findSubOne&&!a.$findSubOne.$from&&(a.$findSubOne.$from=this._privateData.name())),void 0!==b&&(this._querySettings.options=b),void 0!==a||void 0!==b?((void 0===c||c===!0)&&this.refresh(),this):this._querySettings}}),m.prototype._joinChange=function(a,b){this.emit("joinChange")},m.prototype.orderBy=function(a){if(void 0!==a){var b=this.queryOptions()||{};return b.$orderBy=a,this.queryOptions(b),this}return(this.queryOptions()||{}).$orderBy},m.prototype.page=function(a){if(void 0!==a){var b=this.queryOptions()||{};return a!==b.$page&&(b.$page=a,this.queryOptions(b)),this}return(this.queryOptions()||{}).$page},m.prototype.pageFirst=function(){return this.page(0)},m.prototype.pageLast=function(){var a=this.cursor().pages,b=void 0!==a?a:0;return this.page(b-1)},m.prototype.pageScan=function(a){if(void 0!==a){var b=this.cursor().pages,c=this.queryOptions()||{},d=void 0!==c.$page?c.$page:0;return d+=a,0>d&&(d=0),d>=b&&(d=b-1),this.page(d)}},m.prototype.queryOptions=function(a,b){return void 0!==a?(this._querySettings.options=a,void 0===a.$decouple&&(a.$decouple=!0),void 0===b||b===!0?this.refresh():this.rebuildActiveBucket(a.$orderBy),this):this._querySettings.options},m.prototype.rebuildActiveBucket=function(a){if(a){var b=this._privateData._data,c=b.length;this._activeBucket=new k(a),this._activeBucket.primaryKey(this._privateData.primaryKey());for(var d=0;c>d;d++)this._activeBucket.insert(b[d])}else delete this._activeBucket},m.prototype.refresh=function(){var a,b,c,d,e,f=this;if(this._from&&(a=this.publicData(),f.__joinChange=f.__joinChange||function(){f._joinChange()},this._privateData.remove(),b=this._from.find(this._querySettings.query,this._querySettings.options),this.cursor(b.$cursor),this._privateData.insert(b),this._privateData._data.$cursor=b.$cursor,a._data.$cursor=b.$cursor),this._querySettings&&this._querySettings.options&&this._querySettings.options.$join&&this._querySettings.options.$join.length){if(this._joinCollections&&this._joinCollections.length)for(d=0;d<this._joinCollections.length;d++)this._db.collection(this._joinCollections[d]).off("immediateChange",f.__joinChange);for(c=this._querySettings.options.$join,this._joinCollections=[],d=0;d<c.length;d++)for(e in c[d])c[d].hasOwnProperty(e)&&this._joinCollections.push(e);if(this._joinCollections.length)for(d=0;d<this._joinCollections.length;d++)this._db.collection(this._joinCollections[d]).on("immediateChange",f.__joinChange)}return this._querySettings.options&&this._querySettings.options.$orderBy?this.rebuildActiveBucket(this._querySettings.options.$orderBy):this.rebuildActiveBucket(),this},m.prototype.count=function(){return this.publicData()?this.publicData().count.apply(this.publicData(),arguments):0},m.prototype.subset=function(){return this.publicData().subset.apply(this._privateData,arguments)},m.prototype.transform=function(a){var b=this;return void 0!==a?("object"==typeof a?(void 0!==a.enabled&&(this._transformEnabled=a.enabled),void 0!==a.dataIn&&(this._transformIn=a.dataIn),void 0!==a.dataOut&&(this._transformOut=a.dataOut)):this._transformEnabled=a!==!1,this._transformEnabled?(this._publicData||(this._publicData=new f("__FDB__view_publicData_"+this._name),this._publicData.db(this._privateData._db),this._publicData.transform({enabled:!0,dataIn:this._transformIn,dataOut:this._transformOut}),this._transformIo=new j(this._privateData,this._publicData,function(a){var c=a.data;switch(a.type){case"primaryKey":b._publicData.primaryKey(c),this.chainSend("primaryKey",c);break;case"setData":b._publicData.setData(c),this.chainSend("setData",c);break;case"insert":b._publicData.insert(c),this.chainSend("insert",c);break;case"update":b._publicData.update(c.query,c.update,c.options),this.chainSend("update",c);break;case"remove":b._publicData.remove(c.query,a.options),this.chainSend("remove",c)}})),this._publicData.primaryKey(this.privateData().primaryKey()),this._publicData.setData(this.privateData().find())):this._publicData&&(this._publicData.drop(),delete this._publicData,this._transformIo&&(this._transformIo.drop(),delete this._transformIo)),this):{enabled:this._transformEnabled,dataIn:this._transformIn,dataOut:this._transformOut}},m.prototype.filter=function(a,b,c){return this.publicData().filter(a,b,c)},m.prototype.privateData=function(){return this._privateData},m.prototype.publicData=function(){return this._transformEnabled?this._publicData:this._privateData},f.prototype.init=function(){this._view=[],h.apply(this,arguments)},f.prototype.view=function(a,b,c){if(this._db&&this._db._view){if(this._db._view[a])throw this.logIdentifier()+" Cannot create a view using this collection because a view with this name already exists: "+a;var d=new m(a,b,c).db(this._db).from(this);return this._view=this._view||[],this._view.push(d),d}},f.prototype._addView=g.prototype._addView=function(a){return void 0!==a&&this._view.push(a),this},f.prototype._removeView=g.prototype._removeView=function(a){if(void 0!==a){var b=this._view.indexOf(a);b>-1&&this._view.splice(b,1)}return this},e.prototype.init=function(){this._view={},i.apply(this,arguments)},e.prototype.view=function(a){var b=this;return a instanceof m?a:this._view[a]?this._view[a]:((this.debug()||this._db&&this._db.debug())&&console.log(this.logIdentifier()+" Creating view "+a),this._view[a]=this._view[a]||new m(a).db(this),b.emit("create",[b._view[a],"view",a]),this._view[a])},e.prototype.viewExists=function(a){return Boolean(this._view[a])},e.prototype.views=function(){var a,b,c=[];for(b in this._view)this._view.hasOwnProperty(b)&&(a=this._view[b],c.push({name:b,count:a.count(),linked:void 0!==a.isLinked?a.isLinked():!1}));return c},d.finishModule("View"),b.exports=m},{"./ActiveBucket":3,"./Collection":6,"./CollectionGroup":7,"./Overload":32,"./ReactorIO":38,"./Shared":40}],43:[function(a,b,c){(function(a,c){!function(){function d(){}function e(a){return a}function f(a){return!!a}function g(a){return!a}function h(a){return function(){if(null===a)throw new Error("Callback was already called.");a.apply(this,arguments),a=null}}function i(a){return function(){null!==a&&(a.apply(this,arguments),a=null)}}function j(a){return N(a)||"number"==typeof a.length&&a.length>=0&&a.length%1===0}function k(a,b){for(var c=-1,d=a.length;++c<d;)b(a[c],c,a)}function l(a,b){for(var c=-1,d=a.length,e=Array(d);++c<d;)e[c]=b(a[c],c,a);return e}function m(a){return l(Array(a),function(a,b){return b})}function n(a,b,c){return k(a,function(a,d,e){c=b(c,a,d,e)}),c}function o(a,b){k(P(a),function(c){b(a[c],c)})}function p(a,b){for(var c=0;c<a.length;c++)if(a[c]===b)return c;return-1}function q(a){var b,c,d=-1;return j(a)?(b=a.length,function(){return d++,b>d?d:null}):(c=P(a),b=c.length,function(){return d++,b>d?c[d]:null})}function r(a,b){return b=null==b?a.length-1:+b,function(){for(var c=Math.max(arguments.length-b,0),d=Array(c),e=0;c>e;e++)d[e]=arguments[e+b];switch(b){case 0:return a.call(this,d);case 1:return a.call(this,arguments[0],d)}}}function s(a){return function(b,c,d){return a(b,d)}}function t(a){return function(b,c,e){e=i(e||d),b=b||[];var f=q(b);if(0>=a)return e(null);var g=!1,j=0,k=!1;!function l(){if(g&&0>=j)return e(null);for(;a>j&&!k;){var d=f();if(null===d)return g=!0,void(0>=j&&e(null));j+=1,c(b[d],d,h(function(a){j-=1,a?(e(a),k=!0):l()}))}}()}}function u(a){return function(b,c,d){return a(K.eachOf,b,c,d)}}function v(a){return function(b,c,d,e){return a(t(c),b,d,e)}}function w(a){return function(b,c,d){return a(K.eachOfSeries,b,c,d)}}function x(a,b,c,e){e=i(e||d),b=b||[];var f=j(b)?[]:{};a(b,function(a,b,d){c(a,function(a,c){f[b]=c,d(a)})},function(a){e(a,f)})}function y(a,b,c,d){var e=[];a(b,function(a,b,d){c(a,function(c){c&&e.push({index:b,value:a}),d()})},function(){d(l(e.sort(function(a,b){return a.index-b.index}),function(a){return a.value}))})}function z(a,b,c,d){y(a,b,function(a,b){c(a,function(a){b(!a)})},d)}function A(a,b,c){return function(d,e,f,g){function h(){g&&g(c(!1,void 0))}function i(a,d,e){return g?void f(a,function(d){g&&b(d)&&(g(c(!0,a)),g=f=!1),e()}):e()}arguments.length>3?a(d,e,i,h):(g=f,f=e,a(d,i,h))}}function B(a,b){return b}function C(a,b,c){c=c||d;var e=j(b)?[]:{};a(b,function(a,b,c){a(r(function(a,d){d.length<=1&&(d=d[0]),e[b]=d,c(a)}))},function(a){c(a,e)})}function D(a,b,c,d){var e=[];a(b,function(a,b,d){c(a,function(a,b){e=e.concat(b||[]),d(a)})},function(a){d(a,e)})}function E(a,b,c){function e(a,b,c,e){if(null!=e&&"function"!=typeof e)throw new Error("task callback must be a function");return a.started=!0,N(b)||(b=[b]),0===b.length&&a.idle()?K.setImmediate(function(){a.drain()}):(k(b,function(b){var f={data:b,callback:e||d};c?a.tasks.unshift(f):a.tasks.push(f),a.tasks.length===a.concurrency&&a.saturated()}),void K.setImmediate(a.process))}function f(a,b){return function(){g-=1;var c=!1,d=arguments;k(b,function(a){k(i,function(b,d){b!==a||c||(i.splice(d,1),c=!0)}),a.callback.apply(a,d)}),a.tasks.length+g===0&&a.drain(),a.process()}}if(null==b)b=1;else if(0===b)throw new Error("Concurrency must not be zero");var g=0,i=[],j={tasks:[],concurrency:b,payload:c,saturated:d,empty:d,drain:d,started:!1,paused:!1,push:function(a,b){e(j,a,!1,b)},kill:function(){j.drain=d,j.tasks=[]},unshift:function(a,b){e(j,a,!0,b)},process:function(){if(!j.paused&&g<j.concurrency&&j.tasks.length)for(;g<j.concurrency&&j.tasks.length;){var b=j.payload?j.tasks.splice(0,j.payload):j.tasks.splice(0,j.tasks.length),c=l(b,function(a){return a.data});0===j.tasks.length&&j.empty(),g+=1,i.push(b[0]);var d=h(f(j,b));a(c,d)}},length:function(){return j.tasks.length},running:function(){return g},workersList:function(){return i},idle:function(){return j.tasks.length+g===0},pause:function(){j.paused=!0},resume:function(){if(j.paused!==!1){j.paused=!1;for(var a=Math.min(j.concurrency,j.tasks.length),b=1;a>=b;b++)K.setImmediate(j.process)}}};return j}function F(a){return r(function(b,c){b.apply(null,c.concat([r(function(b,c){"object"==typeof console&&(b?console.error&&console.error(b):console[a]&&k(c,function(b){console[a](b)}))})]))})}function G(a){return function(b,c,d){a(m(b),c,d)}}function H(a){return r(function(b,c){var d=r(function(c){var d=this,e=c.pop();return a(b,function(a,b,e){a.apply(d,c.concat([e]))},e)});return c.length?d.apply(this,c):d})}function I(a){return r(function(b){var c=b.pop();b.push(function(){var a=arguments;d?K.setImmediate(function(){c.apply(null,a)}):c.apply(null,a)});var d=!0;a.apply(this,b),d=!1})}var J,K={},L="object"==typeof self&&self.self===self&&self||"object"==typeof c&&c.global===c&&c||this;null!=L&&(J=L.async),K.noConflict=function(){return L.async=J,K};var M=Object.prototype.toString,N=Array.isArray||function(a){return"[object Array]"===M.call(a)},O=function(a){var b=typeof a;return"function"===b||"object"===b&&!!a},P=Object.keys||function(a){var b=[];for(var c in a)a.hasOwnProperty(c)&&b.push(c);return b},Q="function"==typeof setImmediate&&setImmediate,R=Q?function(a){Q(a)}:function(a){setTimeout(a,0)};"object"==typeof a&&"function"==typeof a.nextTick?K.nextTick=a.nextTick:K.nextTick=R,K.setImmediate=Q?R:K.nextTick,K.forEach=K.each=function(a,b,c){return K.eachOf(a,s(b),c)},K.forEachSeries=K.eachSeries=function(a,b,c){return K.eachOfSeries(a,s(b),c)},K.forEachLimit=K.eachLimit=function(a,b,c,d){return t(b)(a,s(c),d)},K.forEachOf=K.eachOf=function(a,b,c){function e(a){j--,a?c(a):null===f&&0>=j&&c(null)}c=i(c||d),a=a||[];for(var f,g=q(a),j=0;null!=(f=g());)j+=1,b(a[f],f,h(e));0===j&&c(null)},K.forEachOfSeries=K.eachOfSeries=function(a,b,c){function e(){var d=!0;return null===g?c(null):(b(a[g],g,h(function(a){if(a)c(a);else{if(g=f(),null===g)return c(null);d?K.setImmediate(e):e()}})),void(d=!1))}c=i(c||d),a=a||[];var f=q(a),g=f();e()},K.forEachOfLimit=K.eachOfLimit=function(a,b,c,d){t(b)(a,c,d)},K.map=u(x),K.mapSeries=w(x),K.mapLimit=v(x),K.inject=K.foldl=K.reduce=function(a,b,c,d){K.eachOfSeries(a,function(a,d,e){c(b,a,function(a,c){b=c,e(a)})},function(a){d(a,b)})},K.foldr=K.reduceRight=function(a,b,c,d){var f=l(a,e).reverse();K.reduce(f,b,c,d)},K.transform=function(a,b,c,d){3===arguments.length&&(d=c,c=b,b=N(a)?[]:{}),K.eachOf(a,function(a,d,e){c(b,a,d,e)},function(a){d(a,b)})},K.select=K.filter=u(y),K.selectLimit=K.filterLimit=v(y),K.selectSeries=K.filterSeries=w(y),K.reject=u(z),K.rejectLimit=v(z),K.rejectSeries=w(z),K.any=K.some=A(K.eachOf,f,e),K.someLimit=A(K.eachOfLimit,f,e),K.all=K.every=A(K.eachOf,g,g),K.everyLimit=A(K.eachOfLimit,g,g),K.detect=A(K.eachOf,e,B),K.detectSeries=A(K.eachOfSeries,e,B),K.detectLimit=A(K.eachOfLimit,e,B),K.sortBy=function(a,b,c){function d(a,b){var c=a.criteria,d=b.criteria;return d>c?-1:c>d?1:0}K.map(a,function(a,c){b(a,function(b,d){b?c(b):c(null,{value:a,criteria:d})})},function(a,b){return a?c(a):void c(null,l(b.sort(d),function(a){return a.value}))})},K.auto=function(a,b,c){function e(a){q.unshift(a)}function f(a){var b=p(q,a);b>=0&&q.splice(b,1)}function g(){j--,k(q.slice(0),function(a){a()})}c||(c=b,b=null),c=i(c||d);var h=P(a),j=h.length;if(!j)return c(null);b||(b=j);var l={},m=0,q=[];e(function(){j||c(null,l)}),k(h,function(d){function h(){return b>m&&n(s,function(a,b){return a&&l.hasOwnProperty(b)},!0)&&!l.hasOwnProperty(d)}function i(){h()&&(m++,f(i),k[k.length-1](q,l))}for(var j,k=N(a[d])?a[d]:[a[d]],q=r(function(a,b){if(m--,b.length<=1&&(b=b[0]),a){var e={};o(l,function(a,b){e[b]=a}),e[d]=b,c(a,e)}else l[d]=b,K.setImmediate(g)}),s=k.slice(0,k.length-1),t=s.length;t--;){if(!(j=a[s[t]]))throw new Error("Has inexistant dependency");if(N(j)&&p(j,d)>=0)throw new Error("Has cyclic dependencies")}h()?(m++,k[k.length-1](q,l)):e(i)})},K.retry=function(a,b,c){function d(a,b){if("number"==typeof b)a.times=parseInt(b,10)||f;else{if("object"!=typeof b)throw new Error("Unsupported argument type for 'times': "+typeof b);a.times=parseInt(b.times,10)||f,a.interval=parseInt(b.interval,10)||g}}function e(a,b){function c(a,c){return function(d){a(function(a,b){d(!a||c,{err:a,result:b})},b)}}function d(a){return function(b){setTimeout(function(){b(null)},a)}}for(;i.times;){var e=!(i.times-=1);h.push(c(i.task,e)),!e&&i.interval>0&&h.push(d(i.interval))}K.series(h,function(b,c){c=c[c.length-1],(a||i.callback)(c.err,c.result)})}var f=5,g=0,h=[],i={times:f,interval:g},j=arguments.length;if(1>j||j>3)throw new Error("Invalid arguments - must be either (task), (task, callback), (times, task) or (times, task, callback)");return 2>=j&&"function"==typeof a&&(c=b,b=a),"function"!=typeof a&&d(i,a),i.callback=c,i.task=b,i.callback?e():e},K.waterfall=function(a,b){function c(a){return r(function(d,e){if(d)b.apply(null,[d].concat(e));else{var f=a.next();f?e.push(c(f)):e.push(b),I(a).apply(null,e)}})}if(b=i(b||d),!N(a)){var e=new Error("First argument to waterfall must be an array of functions");return b(e)}return a.length?void c(K.iterator(a))():b()},K.parallel=function(a,b){C(K.eachOf,a,b)},K.parallelLimit=function(a,b,c){C(t(b),a,c)},K.series=function(a,b){C(K.eachOfSeries,a,b)},K.iterator=function(a){function b(c){function d(){return a.length&&a[c].apply(null,arguments),d.next()}return d.next=function(){return c<a.length-1?b(c+1):null},d}return b(0)},K.apply=r(function(a,b){return r(function(c){return a.apply(null,b.concat(c))})}),K.concat=u(D),K.concatSeries=w(D),K.whilst=function(a,b,c){if(c=c||d,a()){var e=r(function(d,f){d?c(d):a.apply(this,f)?b(e):c(null)});b(e)}else c(null)},K.doWhilst=function(a,b,c){var d=0;return K.whilst(function(){return++d<=1||b.apply(this,arguments)},a,c)},K.until=function(a,b,c){return K.whilst(function(){return!a.apply(this,arguments)},b,c)},K.doUntil=function(a,b,c){return K.doWhilst(a,function(){return!b.apply(this,arguments)},c)},K.during=function(a,b,c){c=c||d;var e=r(function(b,d){b?c(b):(d.push(f),a.apply(this,d))}),f=function(a,d){a?c(a):d?b(e):c(null); };a(f)},K.doDuring=function(a,b,c){var d=0;K.during(function(a){d++<1?a(null,!0):b.apply(this,arguments)},a,c)},K.queue=function(a,b){var c=E(function(b,c){a(b[0],c)},b,1);return c},K.priorityQueue=function(a,b){function c(a,b){return a.priority-b.priority}function e(a,b,c){for(var d=-1,e=a.length-1;e>d;){var f=d+(e-d+1>>>1);c(b,a[f])>=0?d=f:e=f-1}return d}function f(a,b,f,g){if(null!=g&&"function"!=typeof g)throw new Error("task callback must be a function");return a.started=!0,N(b)||(b=[b]),0===b.length?K.setImmediate(function(){a.drain()}):void k(b,function(b){var h={data:b,priority:f,callback:"function"==typeof g?g:d};a.tasks.splice(e(a.tasks,h,c)+1,0,h),a.tasks.length===a.concurrency&&a.saturated(),K.setImmediate(a.process)})}var g=K.queue(a,b);return g.push=function(a,b,c){f(g,a,b,c)},delete g.unshift,g},K.cargo=function(a,b){return E(a,1,b)},K.log=F("log"),K.dir=F("dir"),K.memoize=function(a,b){var c={},d={};b=b||e;var f=r(function(e){var f=e.pop(),g=b.apply(null,e);g in c?K.setImmediate(function(){f.apply(null,c[g])}):g in d?d[g].push(f):(d[g]=[f],a.apply(null,e.concat([r(function(a){c[g]=a;var b=d[g];delete d[g];for(var e=0,f=b.length;f>e;e++)b[e].apply(null,a)})])))});return f.memo=c,f.unmemoized=a,f},K.unmemoize=function(a){return function(){return(a.unmemoized||a).apply(null,arguments)}},K.times=G(K.map),K.timesSeries=G(K.mapSeries),K.timesLimit=function(a,b,c,d){return K.mapLimit(m(a),b,c,d)},K.seq=function(){var a=arguments;return r(function(b){var c=this,e=b[b.length-1];"function"==typeof e?b.pop():e=d,K.reduce(a,b,function(a,b,d){b.apply(c,a.concat([r(function(a,b){d(a,b)})]))},function(a,b){e.apply(c,[a].concat(b))})})},K.compose=function(){return K.seq.apply(null,Array.prototype.reverse.call(arguments))},K.applyEach=H(K.eachOf),K.applyEachSeries=H(K.eachOfSeries),K.forever=function(a,b){function c(a){return a?e(a):void f(c)}var e=h(b||d),f=I(a);c()},K.ensureAsync=I,K.constant=r(function(a){var b=[null].concat(a);return function(a){return a.apply(this,b)}}),K.wrapSync=K.asyncify=function(a){return r(function(b){var c,d=b.pop();try{c=a.apply(this,b)}catch(e){return d(e)}O(c)&&"function"==typeof c.then?c.then(function(a){d(null,a)})["catch"](function(a){d(a.message?a:new Error(a))}):d(null,c)})},"object"==typeof b&&b.exports?b.exports=K:"function"==typeof define&&define.amd?define([],function(){return K}):L.async=K}()}).call(this,a("_process"),"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{_process:78}],44:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./enc-base64"),a("./md5"),a("./evpkdf"),a("./cipher-core")):"function"==typeof define&&define.amd?define(["./core","./enc-base64","./md5","./evpkdf","./cipher-core"],e):e(d.CryptoJS)}(this,function(a){return function(){var b=a,c=b.lib,d=c.BlockCipher,e=b.algo,f=[],g=[],h=[],i=[],j=[],k=[],l=[],m=[],n=[],o=[];!function(){for(var a=[],b=0;256>b;b++)128>b?a[b]=b<<1:a[b]=b<<1^283;for(var c=0,d=0,b=0;256>b;b++){var e=d^d<<1^d<<2^d<<3^d<<4;e=e>>>8^255&e^99,f[c]=e,g[e]=c;var p=a[c],q=a[p],r=a[q],s=257*a[e]^16843008*e;h[c]=s<<24|s>>>8,i[c]=s<<16|s>>>16,j[c]=s<<8|s>>>24,k[c]=s;var s=16843009*r^65537*q^257*p^16843008*c;l[e]=s<<24|s>>>8,m[e]=s<<16|s>>>16,n[e]=s<<8|s>>>24,o[e]=s,c?(c=p^a[a[a[r^p]]],d^=a[a[d]]):c=d=1}}();var p=[0,1,2,4,8,16,32,64,128,27,54],q=e.AES=d.extend({_doReset:function(){for(var a=this._key,b=a.words,c=a.sigBytes/4,d=this._nRounds=c+6,e=4*(d+1),g=this._keySchedule=[],h=0;e>h;h++)if(c>h)g[h]=b[h];else{var i=g[h-1];h%c?c>6&&h%c==4&&(i=f[i>>>24]<<24|f[i>>>16&255]<<16|f[i>>>8&255]<<8|f[255&i]):(i=i<<8|i>>>24,i=f[i>>>24]<<24|f[i>>>16&255]<<16|f[i>>>8&255]<<8|f[255&i],i^=p[h/c|0]<<24),g[h]=g[h-c]^i}for(var j=this._invKeySchedule=[],k=0;e>k;k++){var h=e-k;if(k%4)var i=g[h];else var i=g[h-4];4>k||4>=h?j[k]=i:j[k]=l[f[i>>>24]]^m[f[i>>>16&255]]^n[f[i>>>8&255]]^o[f[255&i]]}},encryptBlock:function(a,b){this._doCryptBlock(a,b,this._keySchedule,h,i,j,k,f)},decryptBlock:function(a,b){var c=a[b+1];a[b+1]=a[b+3],a[b+3]=c,this._doCryptBlock(a,b,this._invKeySchedule,l,m,n,o,g);var c=a[b+1];a[b+1]=a[b+3],a[b+3]=c},_doCryptBlock:function(a,b,c,d,e,f,g,h){for(var i=this._nRounds,j=a[b]^c[0],k=a[b+1]^c[1],l=a[b+2]^c[2],m=a[b+3]^c[3],n=4,o=1;i>o;o++){var p=d[j>>>24]^e[k>>>16&255]^f[l>>>8&255]^g[255&m]^c[n++],q=d[k>>>24]^e[l>>>16&255]^f[m>>>8&255]^g[255&j]^c[n++],r=d[l>>>24]^e[m>>>16&255]^f[j>>>8&255]^g[255&k]^c[n++],s=d[m>>>24]^e[j>>>16&255]^f[k>>>8&255]^g[255&l]^c[n++];j=p,k=q,l=r,m=s}var p=(h[j>>>24]<<24|h[k>>>16&255]<<16|h[l>>>8&255]<<8|h[255&m])^c[n++],q=(h[k>>>24]<<24|h[l>>>16&255]<<16|h[m>>>8&255]<<8|h[255&j])^c[n++],r=(h[l>>>24]<<24|h[m>>>16&255]<<16|h[j>>>8&255]<<8|h[255&k])^c[n++],s=(h[m>>>24]<<24|h[j>>>16&255]<<16|h[k>>>8&255]<<8|h[255&l])^c[n++];a[b]=p,a[b+1]=q,a[b+2]=r,a[b+3]=s},keySize:8});b.AES=d._createHelper(q)}(),a.AES})},{"./cipher-core":45,"./core":46,"./enc-base64":47,"./evpkdf":49,"./md5":54}],45:[function(a,b,c){!function(d,e){"object"==typeof c?b.exports=c=e(a("./core")):"function"==typeof define&&define.amd?define(["./core"],e):e(d.CryptoJS)}(this,function(a){a.lib.Cipher||function(b){var c=a,d=c.lib,e=d.Base,f=d.WordArray,g=d.BufferedBlockAlgorithm,h=c.enc,i=(h.Utf8,h.Base64),j=c.algo,k=j.EvpKDF,l=d.Cipher=g.extend({cfg:e.extend(),createEncryptor:function(a,b){return this.create(this._ENC_XFORM_MODE,a,b)},createDecryptor:function(a,b){return this.create(this._DEC_XFORM_MODE,a,b)},init:function(a,b,c){this.cfg=this.cfg.extend(c),this._xformMode=a,this._key=b,this.reset()},reset:function(){g.reset.call(this),this._doReset()},process:function(a){return this._append(a),this._process()},finalize:function(a){a&&this._append(a);var b=this._doFinalize();return b},keySize:4,ivSize:4,_ENC_XFORM_MODE:1,_DEC_XFORM_MODE:2,_createHelper:function(){function a(a){return"string"==typeof a?x:u}return function(b){return{encrypt:function(c,d,e){return a(d).encrypt(b,c,d,e)},decrypt:function(c,d,e){return a(d).decrypt(b,c,d,e)}}}}()}),m=(d.StreamCipher=l.extend({_doFinalize:function(){var a=this._process(!0);return a},blockSize:1}),c.mode={}),n=d.BlockCipherMode=e.extend({createEncryptor:function(a,b){return this.Encryptor.create(a,b)},createDecryptor:function(a,b){return this.Decryptor.create(a,b)},init:function(a,b){this._cipher=a,this._iv=b}}),o=m.CBC=function(){function a(a,c,d){var e=this._iv;if(e){var f=e;this._iv=b}else var f=this._prevBlock;for(var g=0;d>g;g++)a[c+g]^=f[g]}var c=n.extend();return c.Encryptor=c.extend({processBlock:function(b,c){var d=this._cipher,e=d.blockSize;a.call(this,b,c,e),d.encryptBlock(b,c),this._prevBlock=b.slice(c,c+e)}}),c.Decryptor=c.extend({processBlock:function(b,c){var d=this._cipher,e=d.blockSize,f=b.slice(c,c+e);d.decryptBlock(b,c),a.call(this,b,c,e),this._prevBlock=f}}),c}(),p=c.pad={},q=p.Pkcs7={pad:function(a,b){for(var c=4*b,d=c-a.sigBytes%c,e=d<<24|d<<16|d<<8|d,g=[],h=0;d>h;h+=4)g.push(e);var i=f.create(g,d);a.concat(i)},unpad:function(a){var b=255&a.words[a.sigBytes-1>>>2];a.sigBytes-=b}},r=(d.BlockCipher=l.extend({cfg:l.cfg.extend({mode:o,padding:q}),reset:function(){l.reset.call(this);var a=this.cfg,b=a.iv,c=a.mode;if(this._xformMode==this._ENC_XFORM_MODE)var d=c.createEncryptor;else{var d=c.createDecryptor;this._minBufferSize=1}this._mode=d.call(c,this,b&&b.words)},_doProcessBlock:function(a,b){this._mode.processBlock(a,b)},_doFinalize:function(){var a=this.cfg.padding;if(this._xformMode==this._ENC_XFORM_MODE){a.pad(this._data,this.blockSize);var b=this._process(!0)}else{var b=this._process(!0);a.unpad(b)}return b},blockSize:4}),d.CipherParams=e.extend({init:function(a){this.mixIn(a)},toString:function(a){return(a||this.formatter).stringify(this)}})),s=c.format={},t=s.OpenSSL={stringify:function(a){var b=a.ciphertext,c=a.salt;if(c)var d=f.create([1398893684,1701076831]).concat(c).concat(b);else var d=b;return d.toString(i)},parse:function(a){var b=i.parse(a),c=b.words;if(1398893684==c[0]&&1701076831==c[1]){var d=f.create(c.slice(2,4));c.splice(0,4),b.sigBytes-=16}return r.create({ciphertext:b,salt:d})}},u=d.SerializableCipher=e.extend({cfg:e.extend({format:t}),encrypt:function(a,b,c,d){d=this.cfg.extend(d);var e=a.createEncryptor(c,d),f=e.finalize(b),g=e.cfg;return r.create({ciphertext:f,key:c,iv:g.iv,algorithm:a,mode:g.mode,padding:g.padding,blockSize:a.blockSize,formatter:d.format})},decrypt:function(a,b,c,d){d=this.cfg.extend(d),b=this._parse(b,d.format);var e=a.createDecryptor(c,d).finalize(b.ciphertext);return e},_parse:function(a,b){return"string"==typeof a?b.parse(a,this):a}}),v=c.kdf={},w=v.OpenSSL={execute:function(a,b,c,d){d||(d=f.random(8));var e=k.create({keySize:b+c}).compute(a,d),g=f.create(e.words.slice(b),4*c);return e.sigBytes=4*b,r.create({key:e,iv:g,salt:d})}},x=d.PasswordBasedCipher=u.extend({cfg:u.cfg.extend({kdf:w}),encrypt:function(a,b,c,d){d=this.cfg.extend(d);var e=d.kdf.execute(c,a.keySize,a.ivSize);d.iv=e.iv;var f=u.encrypt.call(this,a,b,e.key,d);return f.mixIn(e),f},decrypt:function(a,b,c,d){d=this.cfg.extend(d),b=this._parse(b,d.format);var e=d.kdf.execute(c,a.keySize,a.ivSize,b.salt);d.iv=e.iv;var f=u.decrypt.call(this,a,b,e.key,d);return f}})}()})},{"./core":46}],46:[function(a,b,c){!function(a,d){"object"==typeof c?b.exports=c=d():"function"==typeof define&&define.amd?define([],d):a.CryptoJS=d()}(this,function(){var a=a||function(a,b){var c={},d=c.lib={},e=d.Base=function(){function a(){}return{extend:function(b){a.prototype=this;var c=new a;return b&&c.mixIn(b),c.hasOwnProperty("init")||(c.init=function(){c.$super.init.apply(this,arguments)}),c.init.prototype=c,c.$super=this,c},create:function(){var a=this.extend();return a.init.apply(a,arguments),a},init:function(){},mixIn:function(a){for(var b in a)a.hasOwnProperty(b)&&(this[b]=a[b]);a.hasOwnProperty("toString")&&(this.toString=a.toString)},clone:function(){return this.init.prototype.extend(this)}}}(),f=d.WordArray=e.extend({init:function(a,c){a=this.words=a||[],c!=b?this.sigBytes=c:this.sigBytes=4*a.length},toString:function(a){return(a||h).stringify(this)},concat:function(a){var b=this.words,c=a.words,d=this.sigBytes,e=a.sigBytes;if(this.clamp(),d%4)for(var f=0;e>f;f++){var g=c[f>>>2]>>>24-f%4*8&255;b[d+f>>>2]|=g<<24-(d+f)%4*8}else for(var f=0;e>f;f+=4)b[d+f>>>2]=c[f>>>2];return this.sigBytes+=e,this},clamp:function(){var b=this.words,c=this.sigBytes;b[c>>>2]&=4294967295<<32-c%4*8,b.length=a.ceil(c/4)},clone:function(){var a=e.clone.call(this);return a.words=this.words.slice(0),a},random:function(b){for(var c,d=[],e=function(b){var b=b,c=987654321,d=4294967295;return function(){c=36969*(65535&c)+(c>>16)&d,b=18e3*(65535&b)+(b>>16)&d;var e=(c<<16)+b&d;return e/=4294967296,e+=.5,e*(a.random()>.5?1:-1)}},g=0;b>g;g+=4){var h=e(4294967296*(c||a.random()));c=987654071*h(),d.push(4294967296*h()|0)}return new f.init(d,b)}}),g=c.enc={},h=g.Hex={stringify:function(a){for(var b=a.words,c=a.sigBytes,d=[],e=0;c>e;e++){var f=b[e>>>2]>>>24-e%4*8&255;d.push((f>>>4).toString(16)),d.push((15&f).toString(16))}return d.join("")},parse:function(a){for(var b=a.length,c=[],d=0;b>d;d+=2)c[d>>>3]|=parseInt(a.substr(d,2),16)<<24-d%8*4;return new f.init(c,b/2)}},i=g.Latin1={stringify:function(a){for(var b=a.words,c=a.sigBytes,d=[],e=0;c>e;e++){var f=b[e>>>2]>>>24-e%4*8&255;d.push(String.fromCharCode(f))}return d.join("")},parse:function(a){for(var b=a.length,c=[],d=0;b>d;d++)c[d>>>2]|=(255&a.charCodeAt(d))<<24-d%4*8;return new f.init(c,b)}},j=g.Utf8={stringify:function(a){try{return decodeURIComponent(escape(i.stringify(a)))}catch(b){throw new Error("Malformed UTF-8 data")}},parse:function(a){return i.parse(unescape(encodeURIComponent(a)))}},k=d.BufferedBlockAlgorithm=e.extend({reset:function(){this._data=new f.init,this._nDataBytes=0},_append:function(a){"string"==typeof a&&(a=j.parse(a)),this._data.concat(a),this._nDataBytes+=a.sigBytes},_process:function(b){var c=this._data,d=c.words,e=c.sigBytes,g=this.blockSize,h=4*g,i=e/h;i=b?a.ceil(i):a.max((0|i)-this._minBufferSize,0);var j=i*g,k=a.min(4*j,e);if(j){for(var l=0;j>l;l+=g)this._doProcessBlock(d,l);var m=d.splice(0,j);c.sigBytes-=k}return new f.init(m,k)},clone:function(){var a=e.clone.call(this);return a._data=this._data.clone(),a},_minBufferSize:0}),l=(d.Hasher=k.extend({cfg:e.extend(),init:function(a){this.cfg=this.cfg.extend(a),this.reset()},reset:function(){k.reset.call(this),this._doReset()},update:function(a){return this._append(a),this._process(),this},finalize:function(a){a&&this._append(a);var b=this._doFinalize();return b},blockSize:16,_createHelper:function(a){return function(b,c){return new a.init(c).finalize(b)}},_createHmacHelper:function(a){return function(b,c){return new l.HMAC.init(a,c).finalize(b)}}}),c.algo={});return c}(Math);return a})},{}],47:[function(a,b,c){!function(d,e){"object"==typeof c?b.exports=c=e(a("./core")):"function"==typeof define&&define.amd?define(["./core"],e):e(d.CryptoJS)}(this,function(a){return function(){var b=a,c=b.lib,d=c.WordArray,e=b.enc;e.Base64={stringify:function(a){var b=a.words,c=a.sigBytes,d=this._map;a.clamp();for(var e=[],f=0;c>f;f+=3)for(var g=b[f>>>2]>>>24-f%4*8&255,h=b[f+1>>>2]>>>24-(f+1)%4*8&255,i=b[f+2>>>2]>>>24-(f+2)%4*8&255,j=g<<16|h<<8|i,k=0;4>k&&c>f+.75*k;k++)e.push(d.charAt(j>>>6*(3-k)&63));var l=d.charAt(64);if(l)for(;e.length%4;)e.push(l);return e.join("")},parse:function(a){var b=a.length,c=this._map,e=c.charAt(64);if(e){var f=a.indexOf(e);-1!=f&&(b=f)}for(var g=[],h=0,i=0;b>i;i++)if(i%4){var j=c.indexOf(a.charAt(i-1))<<i%4*2,k=c.indexOf(a.charAt(i))>>>6-i%4*2;g[h>>>2]|=(j|k)<<24-h%4*8,h++}return d.create(g,h)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="}}(),a.enc.Base64})},{"./core":46}],48:[function(a,b,c){!function(d,e){"object"==typeof c?b.exports=c=e(a("./core")):"function"==typeof define&&define.amd?define(["./core"],e):e(d.CryptoJS)}(this,function(a){return function(){function b(a){return a<<8&4278255360|a>>>8&16711935}var c=a,d=c.lib,e=d.WordArray,f=c.enc;f.Utf16=f.Utf16BE={stringify:function(a){for(var b=a.words,c=a.sigBytes,d=[],e=0;c>e;e+=2){var f=b[e>>>2]>>>16-e%4*8&65535;d.push(String.fromCharCode(f))}return d.join("")},parse:function(a){for(var b=a.length,c=[],d=0;b>d;d++)c[d>>>1]|=a.charCodeAt(d)<<16-d%2*16;return e.create(c,2*b)}};f.Utf16LE={stringify:function(a){for(var c=a.words,d=a.sigBytes,e=[],f=0;d>f;f+=2){var g=b(c[f>>>2]>>>16-f%4*8&65535);e.push(String.fromCharCode(g))}return e.join("")},parse:function(a){for(var c=a.length,d=[],f=0;c>f;f++)d[f>>>1]|=b(a.charCodeAt(f)<<16-f%2*16);return e.create(d,2*c)}}}(),a.enc.Utf16})},{"./core":46}],49:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./sha1"),a("./hmac")):"function"==typeof define&&define.amd?define(["./core","./sha1","./hmac"],e):e(d.CryptoJS)}(this,function(a){return function(){var b=a,c=b.lib,d=c.Base,e=c.WordArray,f=b.algo,g=f.MD5,h=f.EvpKDF=d.extend({cfg:d.extend({keySize:4,hasher:g,iterations:1}),init:function(a){this.cfg=this.cfg.extend(a)},compute:function(a,b){for(var c=this.cfg,d=c.hasher.create(),f=e.create(),g=f.words,h=c.keySize,i=c.iterations;g.length<h;){j&&d.update(j);var j=d.update(a).finalize(b);d.reset();for(var k=1;i>k;k++)j=d.finalize(j),d.reset();f.concat(j)}return f.sigBytes=4*h,f}});b.EvpKDF=function(a,b,c){return h.create(c).compute(a,b)}}(),a.EvpKDF})},{"./core":46,"./hmac":51,"./sha1":70}],50:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./cipher-core")):"function"==typeof define&&define.amd?define(["./core","./cipher-core"],e):e(d.CryptoJS)}(this,function(a){return function(b){var c=a,d=c.lib,e=d.CipherParams,f=c.enc,g=f.Hex,h=c.format;h.Hex={stringify:function(a){return a.ciphertext.toString(g)},parse:function(a){var b=g.parse(a);return e.create({ciphertext:b})}}}(),a.format.Hex})},{"./cipher-core":45,"./core":46}],51:[function(a,b,c){!function(d,e){"object"==typeof c?b.exports=c=e(a("./core")):"function"==typeof define&&define.amd?define(["./core"],e):e(d.CryptoJS)}(this,function(a){!function(){var b=a,c=b.lib,d=c.Base,e=b.enc,f=e.Utf8,g=b.algo;g.HMAC=d.extend({init:function(a,b){a=this._hasher=new a.init,"string"==typeof b&&(b=f.parse(b));var c=a.blockSize,d=4*c;b.sigBytes>d&&(b=a.finalize(b)),b.clamp();for(var e=this._oKey=b.clone(),g=this._iKey=b.clone(),h=e.words,i=g.words,j=0;c>j;j++)h[j]^=1549556828,i[j]^=909522486;e.sigBytes=g.sigBytes=d,this.reset()},reset:function(){var a=this._hasher;a.reset(),a.update(this._iKey)},update:function(a){return this._hasher.update(a),this},finalize:function(a){var b=this._hasher,c=b.finalize(a);b.reset();var d=b.finalize(this._oKey.clone().concat(c));return d}})}()})},{"./core":46}],52:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./x64-core"),a("./lib-typedarrays"),a("./enc-utf16"),a("./enc-base64"),a("./md5"),a("./sha1"),a("./sha256"),a("./sha224"),a("./sha512"),a("./sha384"),a("./sha3"),a("./ripemd160"),a("./hmac"),a("./pbkdf2"),a("./evpkdf"),a("./cipher-core"),a("./mode-cfb"),a("./mode-ctr"),a("./mode-ctr-gladman"),a("./mode-ofb"),a("./mode-ecb"),a("./pad-ansix923"),a("./pad-iso10126"),a("./pad-iso97971"),a("./pad-zeropadding"),a("./pad-nopadding"),a("./format-hex"),a("./aes"),a("./tripledes"),a("./rc4"),a("./rabbit"),a("./rabbit-legacy")):"function"==typeof define&&define.amd?define(["./core","./x64-core","./lib-typedarrays","./enc-utf16","./enc-base64","./md5","./sha1","./sha256","./sha224","./sha512","./sha384","./sha3","./ripemd160","./hmac","./pbkdf2","./evpkdf","./cipher-core","./mode-cfb","./mode-ctr","./mode-ctr-gladman","./mode-ofb","./mode-ecb","./pad-ansix923","./pad-iso10126","./pad-iso97971","./pad-zeropadding","./pad-nopadding","./format-hex","./aes","./tripledes","./rc4","./rabbit","./rabbit-legacy"],e):d.CryptoJS=e(d.CryptoJS)}(this,function(a){return a})},{"./aes":44,"./cipher-core":45,"./core":46,"./enc-base64":47,"./enc-utf16":48,"./evpkdf":49,"./format-hex":50,"./hmac":51,"./lib-typedarrays":53,"./md5":54,"./mode-cfb":55,"./mode-ctr":57,"./mode-ctr-gladman":56,"./mode-ecb":58,"./mode-ofb":59,"./pad-ansix923":60,"./pad-iso10126":61,"./pad-iso97971":62,"./pad-nopadding":63,"./pad-zeropadding":64,"./pbkdf2":65,"./rabbit":67,"./rabbit-legacy":66,"./rc4":68,"./ripemd160":69,"./sha1":70,"./sha224":71,"./sha256":72,"./sha3":73,"./sha384":74,"./sha512":75,"./tripledes":76,"./x64-core":77}],53:[function(a,b,c){!function(d,e){"object"==typeof c?b.exports=c=e(a("./core")):"function"==typeof define&&define.amd?define(["./core"],e):e(d.CryptoJS)}(this,function(a){return function(){if("function"==typeof ArrayBuffer){var b=a,c=b.lib,d=c.WordArray,e=d.init,f=d.init=function(a){if(a instanceof ArrayBuffer&&(a=new Uint8Array(a)),(a instanceof Int8Array||"undefined"!=typeof Uint8ClampedArray&&a instanceof Uint8ClampedArray||a instanceof Int16Array||a instanceof Uint16Array||a instanceof Int32Array||a instanceof Uint32Array||a instanceof Float32Array||a instanceof Float64Array)&&(a=new Uint8Array(a.buffer,a.byteOffset,a.byteLength)),a instanceof Uint8Array){for(var b=a.byteLength,c=[],d=0;b>d;d++)c[d>>>2]|=a[d]<<24-d%4*8;e.call(this,c,b)}else e.apply(this,arguments)};f.prototype=d}}(),a.lib.WordArray})},{"./core":46}],54:[function(a,b,c){!function(d,e){"object"==typeof c?b.exports=c=e(a("./core")):"function"==typeof define&&define.amd?define(["./core"],e):e(d.CryptoJS)}(this,function(a){return function(b){function c(a,b,c,d,e,f,g){var h=a+(b&c|~b&d)+e+g;return(h<<f|h>>>32-f)+b}function d(a,b,c,d,e,f,g){var h=a+(b&d|c&~d)+e+g;return(h<<f|h>>>32-f)+b}function e(a,b,c,d,e,f,g){var h=a+(b^c^d)+e+g;return(h<<f|h>>>32-f)+b}function f(a,b,c,d,e,f,g){var h=a+(c^(b|~d))+e+g;return(h<<f|h>>>32-f)+b}var g=a,h=g.lib,i=h.WordArray,j=h.Hasher,k=g.algo,l=[];!function(){for(var a=0;64>a;a++)l[a]=4294967296*b.abs(b.sin(a+1))|0}();var m=k.MD5=j.extend({_doReset:function(){this._hash=new i.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(a,b){for(var g=0;16>g;g++){var h=b+g,i=a[h];a[h]=16711935&(i<<8|i>>>24)|4278255360&(i<<24|i>>>8)}var j=this._hash.words,k=a[b+0],m=a[b+1],n=a[b+2],o=a[b+3],p=a[b+4],q=a[b+5],r=a[b+6],s=a[b+7],t=a[b+8],u=a[b+9],v=a[b+10],w=a[b+11],x=a[b+12],y=a[b+13],z=a[b+14],A=a[b+15],B=j[0],C=j[1],D=j[2],E=j[3];B=c(B,C,D,E,k,7,l[0]),E=c(E,B,C,D,m,12,l[1]),D=c(D,E,B,C,n,17,l[2]),C=c(C,D,E,B,o,22,l[3]),B=c(B,C,D,E,p,7,l[4]),E=c(E,B,C,D,q,12,l[5]),D=c(D,E,B,C,r,17,l[6]),C=c(C,D,E,B,s,22,l[7]),B=c(B,C,D,E,t,7,l[8]),E=c(E,B,C,D,u,12,l[9]),D=c(D,E,B,C,v,17,l[10]),C=c(C,D,E,B,w,22,l[11]),B=c(B,C,D,E,x,7,l[12]),E=c(E,B,C,D,y,12,l[13]),D=c(D,E,B,C,z,17,l[14]),C=c(C,D,E,B,A,22,l[15]),B=d(B,C,D,E,m,5,l[16]),E=d(E,B,C,D,r,9,l[17]),D=d(D,E,B,C,w,14,l[18]),C=d(C,D,E,B,k,20,l[19]),B=d(B,C,D,E,q,5,l[20]),E=d(E,B,C,D,v,9,l[21]),D=d(D,E,B,C,A,14,l[22]),C=d(C,D,E,B,p,20,l[23]),B=d(B,C,D,E,u,5,l[24]),E=d(E,B,C,D,z,9,l[25]),D=d(D,E,B,C,o,14,l[26]),C=d(C,D,E,B,t,20,l[27]),B=d(B,C,D,E,y,5,l[28]),E=d(E,B,C,D,n,9,l[29]),D=d(D,E,B,C,s,14,l[30]),C=d(C,D,E,B,x,20,l[31]),B=e(B,C,D,E,q,4,l[32]),E=e(E,B,C,D,t,11,l[33]),D=e(D,E,B,C,w,16,l[34]),C=e(C,D,E,B,z,23,l[35]),B=e(B,C,D,E,m,4,l[36]),E=e(E,B,C,D,p,11,l[37]),D=e(D,E,B,C,s,16,l[38]),C=e(C,D,E,B,v,23,l[39]),B=e(B,C,D,E,y,4,l[40]),E=e(E,B,C,D,k,11,l[41]),D=e(D,E,B,C,o,16,l[42]),C=e(C,D,E,B,r,23,l[43]),B=e(B,C,D,E,u,4,l[44]),E=e(E,B,C,D,x,11,l[45]),D=e(D,E,B,C,A,16,l[46]),C=e(C,D,E,B,n,23,l[47]),B=f(B,C,D,E,k,6,l[48]),E=f(E,B,C,D,s,10,l[49]),D=f(D,E,B,C,z,15,l[50]),C=f(C,D,E,B,q,21,l[51]),B=f(B,C,D,E,x,6,l[52]),E=f(E,B,C,D,o,10,l[53]),D=f(D,E,B,C,v,15,l[54]),C=f(C,D,E,B,m,21,l[55]),B=f(B,C,D,E,t,6,l[56]),E=f(E,B,C,D,A,10,l[57]),D=f(D,E,B,C,r,15,l[58]),C=f(C,D,E,B,y,21,l[59]),B=f(B,C,D,E,p,6,l[60]),E=f(E,B,C,D,w,10,l[61]),D=f(D,E,B,C,n,15,l[62]),C=f(C,D,E,B,u,21,l[63]),j[0]=j[0]+B|0,j[1]=j[1]+C|0,j[2]=j[2]+D|0,j[3]=j[3]+E|0},_doFinalize:function(){var a=this._data,c=a.words,d=8*this._nDataBytes,e=8*a.sigBytes;c[e>>>5]|=128<<24-e%32;var f=b.floor(d/4294967296),g=d;c[(e+64>>>9<<4)+15]=16711935&(f<<8|f>>>24)|4278255360&(f<<24|f>>>8),c[(e+64>>>9<<4)+14]=16711935&(g<<8|g>>>24)|4278255360&(g<<24|g>>>8),a.sigBytes=4*(c.length+1),this._process();for(var h=this._hash,i=h.words,j=0;4>j;j++){var k=i[j];i[j]=16711935&(k<<8|k>>>24)|4278255360&(k<<24|k>>>8)}return h},clone:function(){var a=j.clone.call(this);return a._hash=this._hash.clone(),a}});g.MD5=j._createHelper(m),g.HmacMD5=j._createHmacHelper(m)}(Math),a.MD5})},{"./core":46}],55:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./cipher-core")):"function"==typeof define&&define.amd?define(["./core","./cipher-core"],e):e(d.CryptoJS)}(this,function(a){return a.mode.CFB=function(){function b(a,b,c,d){var e=this._iv;if(e){var f=e.slice(0);this._iv=void 0}else var f=this._prevBlock;d.encryptBlock(f,0);for(var g=0;c>g;g++)a[b+g]^=f[g]}var c=a.lib.BlockCipherMode.extend();return c.Encryptor=c.extend({processBlock:function(a,c){var d=this._cipher,e=d.blockSize;b.call(this,a,c,e,d),this._prevBlock=a.slice(c,c+e)}}),c.Decryptor=c.extend({processBlock:function(a,c){var d=this._cipher,e=d.blockSize,f=a.slice(c,c+e);b.call(this,a,c,e,d),this._prevBlock=f}}),c}(),a.mode.CFB})},{"./cipher-core":45,"./core":46}],56:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./cipher-core")):"function"==typeof define&&define.amd?define(["./core","./cipher-core"],e):e(d.CryptoJS)}(this,function(a){return a.mode.CTRGladman=function(){function b(a){if(255===(a>>24&255)){var b=a>>16&255,c=a>>8&255,d=255&a;255===b?(b=0,255===c?(c=0,255===d?d=0:++d):++c):++b,a=0,a+=b<<16,a+=c<<8,a+=d}else a+=1<<24;return a}function c(a){return 0===(a[0]=b(a[0]))&&(a[1]=b(a[1])),a}var d=a.lib.BlockCipherMode.extend(),e=d.Encryptor=d.extend({processBlock:function(a,b){var d=this._cipher,e=d.blockSize,f=this._iv,g=this._counter;f&&(g=this._counter=f.slice(0),this._iv=void 0),c(g);var h=g.slice(0);d.encryptBlock(h,0);for(var i=0;e>i;i++)a[b+i]^=h[i]}});return d.Decryptor=e,d}(),a.mode.CTRGladman})},{"./cipher-core":45,"./core":46}],57:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./cipher-core")):"function"==typeof define&&define.amd?define(["./core","./cipher-core"],e):e(d.CryptoJS)}(this,function(a){return a.mode.CTR=function(){var b=a.lib.BlockCipherMode.extend(),c=b.Encryptor=b.extend({processBlock:function(a,b){var c=this._cipher,d=c.blockSize,e=this._iv,f=this._counter;e&&(f=this._counter=e.slice(0),this._iv=void 0);var g=f.slice(0);c.encryptBlock(g,0),f[d-1]=f[d-1]+1|0;for(var h=0;d>h;h++)a[b+h]^=g[h]}});return b.Decryptor=c,b}(),a.mode.CTR})},{"./cipher-core":45,"./core":46}],58:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./cipher-core")):"function"==typeof define&&define.amd?define(["./core","./cipher-core"],e):e(d.CryptoJS)}(this,function(a){return a.mode.ECB=function(){var b=a.lib.BlockCipherMode.extend();return b.Encryptor=b.extend({processBlock:function(a,b){this._cipher.encryptBlock(a,b)}}),b.Decryptor=b.extend({processBlock:function(a,b){this._cipher.decryptBlock(a,b)}}),b}(),a.mode.ECB})},{"./cipher-core":45,"./core":46}],59:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./cipher-core")):"function"==typeof define&&define.amd?define(["./core","./cipher-core"],e):e(d.CryptoJS)}(this,function(a){return a.mode.OFB=function(){var b=a.lib.BlockCipherMode.extend(),c=b.Encryptor=b.extend({processBlock:function(a,b){var c=this._cipher,d=c.blockSize,e=this._iv,f=this._keystream;e&&(f=this._keystream=e.slice(0),this._iv=void 0),c.encryptBlock(f,0);for(var g=0;d>g;g++)a[b+g]^=f[g]}});return b.Decryptor=c,b}(),a.mode.OFB})},{"./cipher-core":45,"./core":46}],60:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./cipher-core")):"function"==typeof define&&define.amd?define(["./core","./cipher-core"],e):e(d.CryptoJS)}(this,function(a){return a.pad.AnsiX923={pad:function(a,b){var c=a.sigBytes,d=4*b,e=d-c%d,f=c+e-1;a.clamp(),a.words[f>>>2]|=e<<24-f%4*8,a.sigBytes+=e},unpad:function(a){var b=255&a.words[a.sigBytes-1>>>2];a.sigBytes-=b}},a.pad.Ansix923})},{"./cipher-core":45,"./core":46}],61:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./cipher-core")):"function"==typeof define&&define.amd?define(["./core","./cipher-core"],e):e(d.CryptoJS)}(this,function(a){return a.pad.Iso10126={pad:function(b,c){var d=4*c,e=d-b.sigBytes%d;b.concat(a.lib.WordArray.random(e-1)).concat(a.lib.WordArray.create([e<<24],1))},unpad:function(a){var b=255&a.words[a.sigBytes-1>>>2];a.sigBytes-=b}},a.pad.Iso10126})},{"./cipher-core":45,"./core":46}],62:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./cipher-core")):"function"==typeof define&&define.amd?define(["./core","./cipher-core"],e):e(d.CryptoJS)}(this,function(a){return a.pad.Iso97971={pad:function(b,c){b.concat(a.lib.WordArray.create([2147483648],1)),a.pad.ZeroPadding.pad(b,c)},unpad:function(b){a.pad.ZeroPadding.unpad(b),b.sigBytes--}},a.pad.Iso97971})},{"./cipher-core":45,"./core":46}],63:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./cipher-core")):"function"==typeof define&&define.amd?define(["./core","./cipher-core"],e):e(d.CryptoJS)}(this,function(a){return a.pad.NoPadding={pad:function(){},unpad:function(){}},a.pad.NoPadding})},{"./cipher-core":45,"./core":46}],64:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./cipher-core")):"function"==typeof define&&define.amd?define(["./core","./cipher-core"],e):e(d.CryptoJS)}(this,function(a){return a.pad.ZeroPadding={pad:function(a,b){var c=4*b;a.clamp(),a.sigBytes+=c-(a.sigBytes%c||c)},unpad:function(a){for(var b=a.words,c=a.sigBytes-1;!(b[c>>>2]>>>24-c%4*8&255);)c--;a.sigBytes=c+1}},a.pad.ZeroPadding})},{"./cipher-core":45,"./core":46}],65:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./sha1"),a("./hmac")):"function"==typeof define&&define.amd?define(["./core","./sha1","./hmac"],e):e(d.CryptoJS)}(this,function(a){return function(){var b=a,c=b.lib,d=c.Base,e=c.WordArray,f=b.algo,g=f.SHA1,h=f.HMAC,i=f.PBKDF2=d.extend({cfg:d.extend({keySize:4,hasher:g,iterations:1}),init:function(a){this.cfg=this.cfg.extend(a)},compute:function(a,b){for(var c=this.cfg,d=h.create(c.hasher,a),f=e.create(),g=e.create([1]),i=f.words,j=g.words,k=c.keySize,l=c.iterations;i.length<k;){var m=d.update(b).finalize(g);d.reset();for(var n=m.words,o=n.length,p=m,q=1;l>q;q++){p=d.finalize(p),d.reset();for(var r=p.words,s=0;o>s;s++)n[s]^=r[s]}f.concat(m),j[0]++}return f.sigBytes=4*k,f}});b.PBKDF2=function(a,b,c){return i.create(c).compute(a,b)}}(),a.PBKDF2})},{"./core":46,"./hmac":51,"./sha1":70}],66:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./enc-base64"),a("./md5"),a("./evpkdf"),a("./cipher-core")):"function"==typeof define&&define.amd?define(["./core","./enc-base64","./md5","./evpkdf","./cipher-core"],e):e(d.CryptoJS)}(this,function(a){return function(){function b(){for(var a=this._X,b=this._C,c=0;8>c;c++)h[c]=b[c];b[0]=b[0]+1295307597+this._b|0,b[1]=b[1]+3545052371+(b[0]>>>0<h[0]>>>0?1:0)|0,b[2]=b[2]+886263092+(b[1]>>>0<h[1]>>>0?1:0)|0,b[3]=b[3]+1295307597+(b[2]>>>0<h[2]>>>0?1:0)|0,b[4]=b[4]+3545052371+(b[3]>>>0<h[3]>>>0?1:0)|0,b[5]=b[5]+886263092+(b[4]>>>0<h[4]>>>0?1:0)|0,b[6]=b[6]+1295307597+(b[5]>>>0<h[5]>>>0?1:0)|0,b[7]=b[7]+3545052371+(b[6]>>>0<h[6]>>>0?1:0)|0,this._b=b[7]>>>0<h[7]>>>0?1:0;for(var c=0;8>c;c++){var d=a[c]+b[c],e=65535&d,f=d>>>16,g=((e*e>>>17)+e*f>>>15)+f*f,j=((4294901760&d)*d|0)+((65535&d)*d|0);i[c]=g^j}a[0]=i[0]+(i[7]<<16|i[7]>>>16)+(i[6]<<16|i[6]>>>16)|0,a[1]=i[1]+(i[0]<<8|i[0]>>>24)+i[7]|0,a[2]=i[2]+(i[1]<<16|i[1]>>>16)+(i[0]<<16|i[0]>>>16)|0,a[3]=i[3]+(i[2]<<8|i[2]>>>24)+i[1]|0,a[4]=i[4]+(i[3]<<16|i[3]>>>16)+(i[2]<<16|i[2]>>>16)|0,a[5]=i[5]+(i[4]<<8|i[4]>>>24)+i[3]|0,a[6]=i[6]+(i[5]<<16|i[5]>>>16)+(i[4]<<16|i[4]>>>16)|0,a[7]=i[7]+(i[6]<<8|i[6]>>>24)+i[5]|0}var c=a,d=c.lib,e=d.StreamCipher,f=c.algo,g=[],h=[],i=[],j=f.RabbitLegacy=e.extend({_doReset:function(){var a=this._key.words,c=this.cfg.iv,d=this._X=[a[0],a[3]<<16|a[2]>>>16,a[1],a[0]<<16|a[3]>>>16,a[2],a[1]<<16|a[0]>>>16,a[3],a[2]<<16|a[1]>>>16],e=this._C=[a[2]<<16|a[2]>>>16,4294901760&a[0]|65535&a[1],a[3]<<16|a[3]>>>16,4294901760&a[1]|65535&a[2],a[0]<<16|a[0]>>>16,4294901760&a[2]|65535&a[3],a[1]<<16|a[1]>>>16,4294901760&a[3]|65535&a[0]];this._b=0;for(var f=0;4>f;f++)b.call(this);for(var f=0;8>f;f++)e[f]^=d[f+4&7];if(c){var g=c.words,h=g[0],i=g[1],j=16711935&(h<<8|h>>>24)|4278255360&(h<<24|h>>>8),k=16711935&(i<<8|i>>>24)|4278255360&(i<<24|i>>>8),l=j>>>16|4294901760&k,m=k<<16|65535&j;e[0]^=j,e[1]^=l,e[2]^=k,e[3]^=m,e[4]^=j,e[5]^=l,e[6]^=k,e[7]^=m;for(var f=0;4>f;f++)b.call(this)}},_doProcessBlock:function(a,c){var d=this._X;b.call(this),g[0]=d[0]^d[5]>>>16^d[3]<<16,g[1]=d[2]^d[7]>>>16^d[5]<<16,g[2]=d[4]^d[1]>>>16^d[7]<<16,g[3]=d[6]^d[3]>>>16^d[1]<<16;for(var e=0;4>e;e++)g[e]=16711935&(g[e]<<8|g[e]>>>24)|4278255360&(g[e]<<24|g[e]>>>8),a[c+e]^=g[e]},blockSize:4,ivSize:2});c.RabbitLegacy=e._createHelper(j)}(),a.RabbitLegacy})},{"./cipher-core":45,"./core":46,"./enc-base64":47,"./evpkdf":49,"./md5":54}],67:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./enc-base64"),a("./md5"),a("./evpkdf"),a("./cipher-core")):"function"==typeof define&&define.amd?define(["./core","./enc-base64","./md5","./evpkdf","./cipher-core"],e):e(d.CryptoJS)}(this,function(a){return function(){function b(){for(var a=this._X,b=this._C,c=0;8>c;c++)h[c]=b[c];b[0]=b[0]+1295307597+this._b|0,b[1]=b[1]+3545052371+(b[0]>>>0<h[0]>>>0?1:0)|0,b[2]=b[2]+886263092+(b[1]>>>0<h[1]>>>0?1:0)|0,b[3]=b[3]+1295307597+(b[2]>>>0<h[2]>>>0?1:0)|0,b[4]=b[4]+3545052371+(b[3]>>>0<h[3]>>>0?1:0)|0,b[5]=b[5]+886263092+(b[4]>>>0<h[4]>>>0?1:0)|0,b[6]=b[6]+1295307597+(b[5]>>>0<h[5]>>>0?1:0)|0,b[7]=b[7]+3545052371+(b[6]>>>0<h[6]>>>0?1:0)|0,this._b=b[7]>>>0<h[7]>>>0?1:0;for(var c=0;8>c;c++){var d=a[c]+b[c],e=65535&d,f=d>>>16,g=((e*e>>>17)+e*f>>>15)+f*f,j=((4294901760&d)*d|0)+((65535&d)*d|0); i[c]=g^j}a[0]=i[0]+(i[7]<<16|i[7]>>>16)+(i[6]<<16|i[6]>>>16)|0,a[1]=i[1]+(i[0]<<8|i[0]>>>24)+i[7]|0,a[2]=i[2]+(i[1]<<16|i[1]>>>16)+(i[0]<<16|i[0]>>>16)|0,a[3]=i[3]+(i[2]<<8|i[2]>>>24)+i[1]|0,a[4]=i[4]+(i[3]<<16|i[3]>>>16)+(i[2]<<16|i[2]>>>16)|0,a[5]=i[5]+(i[4]<<8|i[4]>>>24)+i[3]|0,a[6]=i[6]+(i[5]<<16|i[5]>>>16)+(i[4]<<16|i[4]>>>16)|0,a[7]=i[7]+(i[6]<<8|i[6]>>>24)+i[5]|0}var c=a,d=c.lib,e=d.StreamCipher,f=c.algo,g=[],h=[],i=[],j=f.Rabbit=e.extend({_doReset:function(){for(var a=this._key.words,c=this.cfg.iv,d=0;4>d;d++)a[d]=16711935&(a[d]<<8|a[d]>>>24)|4278255360&(a[d]<<24|a[d]>>>8);var e=this._X=[a[0],a[3]<<16|a[2]>>>16,a[1],a[0]<<16|a[3]>>>16,a[2],a[1]<<16|a[0]>>>16,a[3],a[2]<<16|a[1]>>>16],f=this._C=[a[2]<<16|a[2]>>>16,4294901760&a[0]|65535&a[1],a[3]<<16|a[3]>>>16,4294901760&a[1]|65535&a[2],a[0]<<16|a[0]>>>16,4294901760&a[2]|65535&a[3],a[1]<<16|a[1]>>>16,4294901760&a[3]|65535&a[0]];this._b=0;for(var d=0;4>d;d++)b.call(this);for(var d=0;8>d;d++)f[d]^=e[d+4&7];if(c){var g=c.words,h=g[0],i=g[1],j=16711935&(h<<8|h>>>24)|4278255360&(h<<24|h>>>8),k=16711935&(i<<8|i>>>24)|4278255360&(i<<24|i>>>8),l=j>>>16|4294901760&k,m=k<<16|65535&j;f[0]^=j,f[1]^=l,f[2]^=k,f[3]^=m,f[4]^=j,f[5]^=l,f[6]^=k,f[7]^=m;for(var d=0;4>d;d++)b.call(this)}},_doProcessBlock:function(a,c){var d=this._X;b.call(this),g[0]=d[0]^d[5]>>>16^d[3]<<16,g[1]=d[2]^d[7]>>>16^d[5]<<16,g[2]=d[4]^d[1]>>>16^d[7]<<16,g[3]=d[6]^d[3]>>>16^d[1]<<16;for(var e=0;4>e;e++)g[e]=16711935&(g[e]<<8|g[e]>>>24)|4278255360&(g[e]<<24|g[e]>>>8),a[c+e]^=g[e]},blockSize:4,ivSize:2});c.Rabbit=e._createHelper(j)}(),a.Rabbit})},{"./cipher-core":45,"./core":46,"./enc-base64":47,"./evpkdf":49,"./md5":54}],68:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./enc-base64"),a("./md5"),a("./evpkdf"),a("./cipher-core")):"function"==typeof define&&define.amd?define(["./core","./enc-base64","./md5","./evpkdf","./cipher-core"],e):e(d.CryptoJS)}(this,function(a){return function(){function b(){for(var a=this._S,b=this._i,c=this._j,d=0,e=0;4>e;e++){b=(b+1)%256,c=(c+a[b])%256;var f=a[b];a[b]=a[c],a[c]=f,d|=a[(a[b]+a[c])%256]<<24-8*e}return this._i=b,this._j=c,d}var c=a,d=c.lib,e=d.StreamCipher,f=c.algo,g=f.RC4=e.extend({_doReset:function(){for(var a=this._key,b=a.words,c=a.sigBytes,d=this._S=[],e=0;256>e;e++)d[e]=e;for(var e=0,f=0;256>e;e++){var g=e%c,h=b[g>>>2]>>>24-g%4*8&255;f=(f+d[e]+h)%256;var i=d[e];d[e]=d[f],d[f]=i}this._i=this._j=0},_doProcessBlock:function(a,c){a[c]^=b.call(this)},keySize:8,ivSize:0});c.RC4=e._createHelper(g);var h=f.RC4Drop=g.extend({cfg:g.cfg.extend({drop:192}),_doReset:function(){g._doReset.call(this);for(var a=this.cfg.drop;a>0;a--)b.call(this)}});c.RC4Drop=e._createHelper(h)}(),a.RC4})},{"./cipher-core":45,"./core":46,"./enc-base64":47,"./evpkdf":49,"./md5":54}],69:[function(a,b,c){!function(d,e){"object"==typeof c?b.exports=c=e(a("./core")):"function"==typeof define&&define.amd?define(["./core"],e):e(d.CryptoJS)}(this,function(a){return function(b){function c(a,b,c){return a^b^c}function d(a,b,c){return a&b|~a&c}function e(a,b,c){return(a|~b)^c}function f(a,b,c){return a&c|b&~c}function g(a,b,c){return a^(b|~c)}function h(a,b){return a<<b|a>>>32-b}var i=a,j=i.lib,k=j.WordArray,l=j.Hasher,m=i.algo,n=k.create([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13]),o=k.create([5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11]),p=k.create([11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6]),q=k.create([8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11]),r=k.create([0,1518500249,1859775393,2400959708,2840853838]),s=k.create([1352829926,1548603684,1836072691,2053994217,0]),t=m.RIPEMD160=l.extend({_doReset:function(){this._hash=k.create([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(a,b){for(var i=0;16>i;i++){var j=b+i,k=a[j];a[j]=16711935&(k<<8|k>>>24)|4278255360&(k<<24|k>>>8)}var l,m,t,u,v,w,x,y,z,A,B=this._hash.words,C=r.words,D=s.words,E=n.words,F=o.words,G=p.words,H=q.words;w=l=B[0],x=m=B[1],y=t=B[2],z=u=B[3],A=v=B[4];for(var I,i=0;80>i;i+=1)I=l+a[b+E[i]]|0,I+=16>i?c(m,t,u)+C[0]:32>i?d(m,t,u)+C[1]:48>i?e(m,t,u)+C[2]:64>i?f(m,t,u)+C[3]:g(m,t,u)+C[4],I=0|I,I=h(I,G[i]),I=I+v|0,l=v,v=u,u=h(t,10),t=m,m=I,I=w+a[b+F[i]]|0,I+=16>i?g(x,y,z)+D[0]:32>i?f(x,y,z)+D[1]:48>i?e(x,y,z)+D[2]:64>i?d(x,y,z)+D[3]:c(x,y,z)+D[4],I=0|I,I=h(I,H[i]),I=I+A|0,w=A,A=z,z=h(y,10),y=x,x=I;I=B[1]+t+z|0,B[1]=B[2]+u+A|0,B[2]=B[3]+v+w|0,B[3]=B[4]+l+x|0,B[4]=B[0]+m+y|0,B[0]=I},_doFinalize:function(){var a=this._data,b=a.words,c=8*this._nDataBytes,d=8*a.sigBytes;b[d>>>5]|=128<<24-d%32,b[(d+64>>>9<<4)+14]=16711935&(c<<8|c>>>24)|4278255360&(c<<24|c>>>8),a.sigBytes=4*(b.length+1),this._process();for(var e=this._hash,f=e.words,g=0;5>g;g++){var h=f[g];f[g]=16711935&(h<<8|h>>>24)|4278255360&(h<<24|h>>>8)}return e},clone:function(){var a=l.clone.call(this);return a._hash=this._hash.clone(),a}});i.RIPEMD160=l._createHelper(t),i.HmacRIPEMD160=l._createHmacHelper(t)}(Math),a.RIPEMD160})},{"./core":46}],70:[function(a,b,c){!function(d,e){"object"==typeof c?b.exports=c=e(a("./core")):"function"==typeof define&&define.amd?define(["./core"],e):e(d.CryptoJS)}(this,function(a){return function(){var b=a,c=b.lib,d=c.WordArray,e=c.Hasher,f=b.algo,g=[],h=f.SHA1=e.extend({_doReset:function(){this._hash=new d.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(a,b){for(var c=this._hash.words,d=c[0],e=c[1],f=c[2],h=c[3],i=c[4],j=0;80>j;j++){if(16>j)g[j]=0|a[b+j];else{var k=g[j-3]^g[j-8]^g[j-14]^g[j-16];g[j]=k<<1|k>>>31}var l=(d<<5|d>>>27)+i+g[j];l+=20>j?(e&f|~e&h)+1518500249:40>j?(e^f^h)+1859775393:60>j?(e&f|e&h|f&h)-1894007588:(e^f^h)-899497514,i=h,h=f,f=e<<30|e>>>2,e=d,d=l}c[0]=c[0]+d|0,c[1]=c[1]+e|0,c[2]=c[2]+f|0,c[3]=c[3]+h|0,c[4]=c[4]+i|0},_doFinalize:function(){var a=this._data,b=a.words,c=8*this._nDataBytes,d=8*a.sigBytes;return b[d>>>5]|=128<<24-d%32,b[(d+64>>>9<<4)+14]=Math.floor(c/4294967296),b[(d+64>>>9<<4)+15]=c,a.sigBytes=4*b.length,this._process(),this._hash},clone:function(){var a=e.clone.call(this);return a._hash=this._hash.clone(),a}});b.SHA1=e._createHelper(h),b.HmacSHA1=e._createHmacHelper(h)}(),a.SHA1})},{"./core":46}],71:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./sha256")):"function"==typeof define&&define.amd?define(["./core","./sha256"],e):e(d.CryptoJS)}(this,function(a){return function(){var b=a,c=b.lib,d=c.WordArray,e=b.algo,f=e.SHA256,g=e.SHA224=f.extend({_doReset:function(){this._hash=new d.init([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428])},_doFinalize:function(){var a=f._doFinalize.call(this);return a.sigBytes-=4,a}});b.SHA224=f._createHelper(g),b.HmacSHA224=f._createHmacHelper(g)}(),a.SHA224})},{"./core":46,"./sha256":72}],72:[function(a,b,c){!function(d,e){"object"==typeof c?b.exports=c=e(a("./core")):"function"==typeof define&&define.amd?define(["./core"],e):e(d.CryptoJS)}(this,function(a){return function(b){var c=a,d=c.lib,e=d.WordArray,f=d.Hasher,g=c.algo,h=[],i=[];!function(){function a(a){for(var c=b.sqrt(a),d=2;c>=d;d++)if(!(a%d))return!1;return!0}function c(a){return 4294967296*(a-(0|a))|0}for(var d=2,e=0;64>e;)a(d)&&(8>e&&(h[e]=c(b.pow(d,.5))),i[e]=c(b.pow(d,1/3)),e++),d++}();var j=[],k=g.SHA256=f.extend({_doReset:function(){this._hash=new e.init(h.slice(0))},_doProcessBlock:function(a,b){for(var c=this._hash.words,d=c[0],e=c[1],f=c[2],g=c[3],h=c[4],k=c[5],l=c[6],m=c[7],n=0;64>n;n++){if(16>n)j[n]=0|a[b+n];else{var o=j[n-15],p=(o<<25|o>>>7)^(o<<14|o>>>18)^o>>>3,q=j[n-2],r=(q<<15|q>>>17)^(q<<13|q>>>19)^q>>>10;j[n]=p+j[n-7]+r+j[n-16]}var s=h&k^~h&l,t=d&e^d&f^e&f,u=(d<<30|d>>>2)^(d<<19|d>>>13)^(d<<10|d>>>22),v=(h<<26|h>>>6)^(h<<21|h>>>11)^(h<<7|h>>>25),w=m+v+s+i[n]+j[n],x=u+t;m=l,l=k,k=h,h=g+w|0,g=f,f=e,e=d,d=w+x|0}c[0]=c[0]+d|0,c[1]=c[1]+e|0,c[2]=c[2]+f|0,c[3]=c[3]+g|0,c[4]=c[4]+h|0,c[5]=c[5]+k|0,c[6]=c[6]+l|0,c[7]=c[7]+m|0},_doFinalize:function(){var a=this._data,c=a.words,d=8*this._nDataBytes,e=8*a.sigBytes;return c[e>>>5]|=128<<24-e%32,c[(e+64>>>9<<4)+14]=b.floor(d/4294967296),c[(e+64>>>9<<4)+15]=d,a.sigBytes=4*c.length,this._process(),this._hash},clone:function(){var a=f.clone.call(this);return a._hash=this._hash.clone(),a}});c.SHA256=f._createHelper(k),c.HmacSHA256=f._createHmacHelper(k)}(Math),a.SHA256})},{"./core":46}],73:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./x64-core")):"function"==typeof define&&define.amd?define(["./core","./x64-core"],e):e(d.CryptoJS)}(this,function(a){return function(b){var c=a,d=c.lib,e=d.WordArray,f=d.Hasher,g=c.x64,h=g.Word,i=c.algo,j=[],k=[],l=[];!function(){for(var a=1,b=0,c=0;24>c;c++){j[a+5*b]=(c+1)*(c+2)/2%64;var d=b%5,e=(2*a+3*b)%5;a=d,b=e}for(var a=0;5>a;a++)for(var b=0;5>b;b++)k[a+5*b]=b+(2*a+3*b)%5*5;for(var f=1,g=0;24>g;g++){for(var i=0,m=0,n=0;7>n;n++){if(1&f){var o=(1<<n)-1;32>o?m^=1<<o:i^=1<<o-32}128&f?f=f<<1^113:f<<=1}l[g]=h.create(i,m)}}();var m=[];!function(){for(var a=0;25>a;a++)m[a]=h.create()}();var n=i.SHA3=f.extend({cfg:f.cfg.extend({outputLength:512}),_doReset:function(){for(var a=this._state=[],b=0;25>b;b++)a[b]=new h.init;this.blockSize=(1600-2*this.cfg.outputLength)/32},_doProcessBlock:function(a,b){for(var c=this._state,d=this.blockSize/2,e=0;d>e;e++){var f=a[b+2*e],g=a[b+2*e+1];f=16711935&(f<<8|f>>>24)|4278255360&(f<<24|f>>>8),g=16711935&(g<<8|g>>>24)|4278255360&(g<<24|g>>>8);var h=c[e];h.high^=g,h.low^=f}for(var i=0;24>i;i++){for(var n=0;5>n;n++){for(var o=0,p=0,q=0;5>q;q++){var h=c[n+5*q];o^=h.high,p^=h.low}var r=m[n];r.high=o,r.low=p}for(var n=0;5>n;n++)for(var s=m[(n+4)%5],t=m[(n+1)%5],u=t.high,v=t.low,o=s.high^(u<<1|v>>>31),p=s.low^(v<<1|u>>>31),q=0;5>q;q++){var h=c[n+5*q];h.high^=o,h.low^=p}for(var w=1;25>w;w++){var h=c[w],x=h.high,y=h.low,z=j[w];if(32>z)var o=x<<z|y>>>32-z,p=y<<z|x>>>32-z;else var o=y<<z-32|x>>>64-z,p=x<<z-32|y>>>64-z;var A=m[k[w]];A.high=o,A.low=p}var B=m[0],C=c[0];B.high=C.high,B.low=C.low;for(var n=0;5>n;n++)for(var q=0;5>q;q++){var w=n+5*q,h=c[w],D=m[w],E=m[(n+1)%5+5*q],F=m[(n+2)%5+5*q];h.high=D.high^~E.high&F.high,h.low=D.low^~E.low&F.low}var h=c[0],G=l[i];h.high^=G.high,h.low^=G.low}},_doFinalize:function(){var a=this._data,c=a.words,d=(8*this._nDataBytes,8*a.sigBytes),f=32*this.blockSize;c[d>>>5]|=1<<24-d%32,c[(b.ceil((d+1)/f)*f>>>5)-1]|=128,a.sigBytes=4*c.length,this._process();for(var g=this._state,h=this.cfg.outputLength/8,i=h/8,j=[],k=0;i>k;k++){var l=g[k],m=l.high,n=l.low;m=16711935&(m<<8|m>>>24)|4278255360&(m<<24|m>>>8),n=16711935&(n<<8|n>>>24)|4278255360&(n<<24|n>>>8),j.push(n),j.push(m)}return new e.init(j,h)},clone:function(){for(var a=f.clone.call(this),b=a._state=this._state.slice(0),c=0;25>c;c++)b[c]=b[c].clone();return a}});c.SHA3=f._createHelper(n),c.HmacSHA3=f._createHmacHelper(n)}(Math),a.SHA3})},{"./core":46,"./x64-core":77}],74:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./x64-core"),a("./sha512")):"function"==typeof define&&define.amd?define(["./core","./x64-core","./sha512"],e):e(d.CryptoJS)}(this,function(a){return function(){var b=a,c=b.x64,d=c.Word,e=c.WordArray,f=b.algo,g=f.SHA512,h=f.SHA384=g.extend({_doReset:function(){this._hash=new e.init([new d.init(3418070365,3238371032),new d.init(1654270250,914150663),new d.init(2438529370,812702999),new d.init(355462360,4144912697),new d.init(1731405415,4290775857),new d.init(2394180231,1750603025),new d.init(3675008525,1694076839),new d.init(1203062813,3204075428)])},_doFinalize:function(){var a=g._doFinalize.call(this);return a.sigBytes-=16,a}});b.SHA384=g._createHelper(h),b.HmacSHA384=g._createHmacHelper(h)}(),a.SHA384})},{"./core":46,"./sha512":75,"./x64-core":77}],75:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./x64-core")):"function"==typeof define&&define.amd?define(["./core","./x64-core"],e):e(d.CryptoJS)}(this,function(a){return function(){function b(){return g.create.apply(g,arguments)}var c=a,d=c.lib,e=d.Hasher,f=c.x64,g=f.Word,h=f.WordArray,i=c.algo,j=[b(1116352408,3609767458),b(1899447441,602891725),b(3049323471,3964484399),b(3921009573,2173295548),b(961987163,4081628472),b(1508970993,3053834265),b(2453635748,2937671579),b(2870763221,3664609560),b(3624381080,2734883394),b(310598401,1164996542),b(607225278,1323610764),b(1426881987,3590304994),b(1925078388,4068182383),b(2162078206,991336113),b(2614888103,633803317),b(3248222580,3479774868),b(3835390401,2666613458),b(4022224774,944711139),b(264347078,2341262773),b(604807628,2007800933),b(770255983,1495990901),b(1249150122,1856431235),b(1555081692,3175218132),b(1996064986,2198950837),b(2554220882,3999719339),b(2821834349,766784016),b(2952996808,2566594879),b(3210313671,3203337956),b(3336571891,1034457026),b(3584528711,2466948901),b(113926993,3758326383),b(338241895,168717936),b(666307205,1188179964),b(773529912,1546045734),b(1294757372,1522805485),b(1396182291,2643833823),b(1695183700,2343527390),b(1986661051,1014477480),b(2177026350,1206759142),b(2456956037,344077627),b(2730485921,1290863460),b(2820302411,3158454273),b(3259730800,3505952657),b(3345764771,106217008),b(3516065817,3606008344),b(3600352804,1432725776),b(4094571909,1467031594),b(275423344,851169720),b(430227734,3100823752),b(506948616,1363258195),b(659060556,3750685593),b(883997877,3785050280),b(958139571,3318307427),b(1322822218,3812723403),b(1537002063,2003034995),b(1747873779,3602036899),b(1955562222,1575990012),b(2024104815,1125592928),b(2227730452,2716904306),b(2361852424,442776044),b(2428436474,593698344),b(2756734187,3733110249),b(3204031479,2999351573),b(3329325298,3815920427),b(3391569614,3928383900),b(3515267271,566280711),b(3940187606,3454069534),b(4118630271,4000239992),b(116418474,1914138554),b(174292421,2731055270),b(289380356,3203993006),b(460393269,320620315),b(685471733,587496836),b(852142971,1086792851),b(1017036298,365543100),b(1126000580,2618297676),b(1288033470,3409855158),b(1501505948,4234509866),b(1607167915,987167468),b(1816402316,1246189591)],k=[];!function(){for(var a=0;80>a;a++)k[a]=b()}();var l=i.SHA512=e.extend({_doReset:function(){this._hash=new h.init([new g.init(1779033703,4089235720),new g.init(3144134277,2227873595),new g.init(1013904242,4271175723),new g.init(2773480762,1595750129),new g.init(1359893119,2917565137),new g.init(2600822924,725511199),new g.init(528734635,4215389547),new g.init(1541459225,327033209)])},_doProcessBlock:function(a,b){for(var c=this._hash.words,d=c[0],e=c[1],f=c[2],g=c[3],h=c[4],i=c[5],l=c[6],m=c[7],n=d.high,o=d.low,p=e.high,q=e.low,r=f.high,s=f.low,t=g.high,u=g.low,v=h.high,w=h.low,x=i.high,y=i.low,z=l.high,A=l.low,B=m.high,C=m.low,D=n,E=o,F=p,G=q,H=r,I=s,J=t,K=u,L=v,M=w,N=x,O=y,P=z,Q=A,R=B,S=C,T=0;80>T;T++){var U=k[T];if(16>T)var V=U.high=0|a[b+2*T],W=U.low=0|a[b+2*T+1];else{var X=k[T-15],Y=X.high,Z=X.low,$=(Y>>>1|Z<<31)^(Y>>>8|Z<<24)^Y>>>7,_=(Z>>>1|Y<<31)^(Z>>>8|Y<<24)^(Z>>>7|Y<<25),aa=k[T-2],ba=aa.high,ca=aa.low,da=(ba>>>19|ca<<13)^(ba<<3|ca>>>29)^ba>>>6,ea=(ca>>>19|ba<<13)^(ca<<3|ba>>>29)^(ca>>>6|ba<<26),fa=k[T-7],ga=fa.high,ha=fa.low,ia=k[T-16],ja=ia.high,ka=ia.low,W=_+ha,V=$+ga+(_>>>0>W>>>0?1:0),W=W+ea,V=V+da+(ea>>>0>W>>>0?1:0),W=W+ka,V=V+ja+(ka>>>0>W>>>0?1:0);U.high=V,U.low=W}var la=L&N^~L&P,ma=M&O^~M&Q,na=D&F^D&H^F&H,oa=E&G^E&I^G&I,pa=(D>>>28|E<<4)^(D<<30|E>>>2)^(D<<25|E>>>7),qa=(E>>>28|D<<4)^(E<<30|D>>>2)^(E<<25|D>>>7),ra=(L>>>14|M<<18)^(L>>>18|M<<14)^(L<<23|M>>>9),sa=(M>>>14|L<<18)^(M>>>18|L<<14)^(M<<23|L>>>9),ta=j[T],ua=ta.high,va=ta.low,wa=S+sa,xa=R+ra+(S>>>0>wa>>>0?1:0),wa=wa+ma,xa=xa+la+(ma>>>0>wa>>>0?1:0),wa=wa+va,xa=xa+ua+(va>>>0>wa>>>0?1:0),wa=wa+W,xa=xa+V+(W>>>0>wa>>>0?1:0),ya=qa+oa,za=pa+na+(qa>>>0>ya>>>0?1:0);R=P,S=Q,P=N,Q=O,N=L,O=M,M=K+wa|0,L=J+xa+(K>>>0>M>>>0?1:0)|0,J=H,K=I,H=F,I=G,F=D,G=E,E=wa+ya|0,D=xa+za+(wa>>>0>E>>>0?1:0)|0}o=d.low=o+E,d.high=n+D+(E>>>0>o>>>0?1:0),q=e.low=q+G,e.high=p+F+(G>>>0>q>>>0?1:0),s=f.low=s+I,f.high=r+H+(I>>>0>s>>>0?1:0),u=g.low=u+K,g.high=t+J+(K>>>0>u>>>0?1:0),w=h.low=w+M,h.high=v+L+(M>>>0>w>>>0?1:0),y=i.low=y+O,i.high=x+N+(O>>>0>y>>>0?1:0),A=l.low=A+Q,l.high=z+P+(Q>>>0>A>>>0?1:0),C=m.low=C+S,m.high=B+R+(S>>>0>C>>>0?1:0)},_doFinalize:function(){var a=this._data,b=a.words,c=8*this._nDataBytes,d=8*a.sigBytes;b[d>>>5]|=128<<24-d%32,b[(d+128>>>10<<5)+30]=Math.floor(c/4294967296),b[(d+128>>>10<<5)+31]=c,a.sigBytes=4*b.length,this._process();var e=this._hash.toX32();return e},clone:function(){var a=e.clone.call(this);return a._hash=this._hash.clone(),a},blockSize:32});c.SHA512=e._createHelper(l),c.HmacSHA512=e._createHmacHelper(l)}(),a.SHA512})},{"./core":46,"./x64-core":77}],76:[function(a,b,c){!function(d,e,f){"object"==typeof c?b.exports=c=e(a("./core"),a("./enc-base64"),a("./md5"),a("./evpkdf"),a("./cipher-core")):"function"==typeof define&&define.amd?define(["./core","./enc-base64","./md5","./evpkdf","./cipher-core"],e):e(d.CryptoJS)}(this,function(a){return function(){function b(a,b){var c=(this._lBlock>>>a^this._rBlock)&b;this._rBlock^=c,this._lBlock^=c<<a}function c(a,b){var c=(this._rBlock>>>a^this._lBlock)&b;this._lBlock^=c,this._rBlock^=c<<a}var d=a,e=d.lib,f=e.WordArray,g=e.BlockCipher,h=d.algo,i=[57,49,41,33,25,17,9,1,58,50,42,34,26,18,10,2,59,51,43,35,27,19,11,3,60,52,44,36,63,55,47,39,31,23,15,7,62,54,46,38,30,22,14,6,61,53,45,37,29,21,13,5,28,20,12,4],j=[14,17,11,24,1,5,3,28,15,6,21,10,23,19,12,4,26,8,16,7,27,20,13,2,41,52,31,37,47,55,30,40,51,45,33,48,44,49,39,56,34,53,46,42,50,36,29,32],k=[1,2,4,6,8,10,12,14,15,17,19,21,23,25,27,28],l=[{0:8421888,268435456:32768,536870912:8421378,805306368:2,1073741824:512,1342177280:8421890,1610612736:8389122,1879048192:8388608,2147483648:514,2415919104:8389120,2684354560:33280,2952790016:8421376,3221225472:32770,3489660928:8388610,3758096384:0,4026531840:33282,134217728:0,402653184:8421890,671088640:33282,939524096:32768,1207959552:8421888,1476395008:512,1744830464:8421378,2013265920:2,2281701376:8389120,2550136832:33280,2818572288:8421376,3087007744:8389122,3355443200:8388610,3623878656:32770,3892314112:514,4160749568:8388608,1:32768,268435457:2,536870913:8421888,805306369:8388608,1073741825:8421378,1342177281:33280,1610612737:512,1879048193:8389122,2147483649:8421890,2415919105:8421376,2684354561:8388610,2952790017:33282,3221225473:514,3489660929:8389120,3758096385:32770,4026531841:0,134217729:8421890,402653185:8421376,671088641:8388608,939524097:512,1207959553:32768,1476395009:8388610,1744830465:2,2013265921:33282,2281701377:32770,2550136833:8389122,2818572289:514,3087007745:8421888,3355443201:8389120,3623878657:0,3892314113:33280,4160749569:8421378},{0:1074282512,16777216:16384,33554432:524288,50331648:1074266128,67108864:1073741840,83886080:1074282496,100663296:1073758208,117440512:16,134217728:540672,150994944:1073758224,167772160:1073741824,184549376:540688,201326592:524304,218103808:0,234881024:16400,251658240:1074266112,8388608:1073758208,25165824:540688,41943040:16,58720256:1073758224,75497472:1074282512,92274688:1073741824,109051904:524288,125829120:1074266128,142606336:524304,159383552:0,176160768:16384,192937984:1074266112,209715200:1073741840,226492416:540672,243269632:1074282496,260046848:16400,268435456:0,285212672:1074266128,301989888:1073758224,318767104:1074282496,335544320:1074266112,352321536:16,369098752:540688,385875968:16384,402653184:16400,419430400:524288,436207616:524304,452984832:1073741840,469762048:540672,486539264:1073758208,503316480:1073741824,520093696:1074282512,276824064:540688,293601280:524288,310378496:1074266112,327155712:16384,343932928:1073758208,360710144:1074282512,377487360:16,394264576:1073741824,411041792:1074282496,427819008:1073741840,444596224:1073758224,461373440:524304,478150656:0,494927872:16400,511705088:1074266128,528482304:540672},{0:260,1048576:0,2097152:67109120,3145728:65796,4194304:65540,5242880:67108868,6291456:67174660,7340032:67174400,8388608:67108864,9437184:67174656,10485760:65792,11534336:67174404,12582912:67109124,13631488:65536,14680064:4,15728640:256,524288:67174656,1572864:67174404,2621440:0,3670016:67109120,4718592:67108868,5767168:65536,6815744:65540,7864320:260,8912896:4,9961472:256,11010048:67174400,12058624:65796,13107200:65792,14155776:67109124,15204352:67174660,16252928:67108864,16777216:67174656,17825792:65540,18874368:65536,19922944:67109120,20971520:256,22020096:67174660,23068672:67108868,24117248:0,25165824:67109124,26214400:67108864,27262976:4,28311552:65792,29360128:67174400,30408704:260,31457280:65796,32505856:67174404,17301504:67108864,18350080:260,19398656:67174656,20447232:0,21495808:65540,22544384:67109120,23592960:256,24641536:67174404,25690112:65536,26738688:67174660,27787264:65796,28835840:67108868,29884416:67109124,30932992:67174400,31981568:4,33030144:65792},{0:2151682048,65536:2147487808,131072:4198464,196608:2151677952,262144:0,327680:4198400,393216:2147483712,458752:4194368,524288:2147483648,589824:4194304,655360:64,720896:2147487744,786432:2151678016,851968:4160,917504:4096,983040:2151682112,32768:2147487808,98304:64,163840:2151678016,229376:2147487744,294912:4198400,360448:2151682112,425984:0,491520:2151677952,557056:4096,622592:2151682048,688128:4194304,753664:4160,819200:2147483648,884736:4194368,950272:4198464,1015808:2147483712,1048576:4194368,1114112:4198400,1179648:2147483712,1245184:0,1310720:4160,1376256:2151678016,1441792:2151682048,1507328:2147487808,1572864:2151682112,1638400:2147483648,1703936:2151677952,1769472:4198464,1835008:2147487744,1900544:4194304,1966080:64,2031616:4096,1081344:2151677952,1146880:2151682112,1212416:0,1277952:4198400,1343488:4194368,1409024:2147483648,1474560:2147487808,1540096:64,1605632:2147483712,1671168:4096,1736704:2147487744,1802240:2151678016,1867776:4160,1933312:2151682048,1998848:4194304,2064384:4198464},{0:128,4096:17039360,8192:262144,12288:536870912,16384:537133184,20480:16777344,24576:553648256,28672:262272,32768:16777216,36864:537133056,40960:536871040,45056:553910400,49152:553910272,53248:0,57344:17039488,61440:553648128,2048:17039488,6144:553648256,10240:128,14336:17039360,18432:262144,22528:537133184,26624:553910272,30720:536870912,34816:537133056,38912:0,43008:553910400,47104:16777344,51200:536871040,55296:553648128,59392:16777216,63488:262272,65536:262144,69632:128,73728:536870912,77824:553648256,81920:16777344,86016:553910272,90112:537133184,94208:16777216,98304:553910400,102400:553648128,106496:17039360,110592:537133056,114688:262272,118784:536871040,122880:0,126976:17039488,67584:553648256,71680:16777216,75776:17039360,79872:537133184,83968:536870912,88064:17039488,92160:128,96256:553910272,100352:262272,104448:553910400,108544:0,112640:553648128,116736:16777344,120832:262144,124928:537133056,129024:536871040},{0:268435464,256:8192,512:270532608,768:270540808,1024:268443648,1280:2097152,1536:2097160,1792:268435456,2048:0,2304:268443656,2560:2105344,2816:8,3072:270532616,3328:2105352,3584:8200,3840:270540800,128:270532608,384:270540808,640:8,896:2097152,1152:2105352,1408:268435464,1664:268443648,1920:8200,2176:2097160,2432:8192,2688:268443656,2944:270532616,3200:0,3456:270540800,3712:2105344,3968:268435456,4096:268443648,4352:270532616,4608:270540808,4864:8200,5120:2097152,5376:268435456,5632:268435464,5888:2105344,6144:2105352,6400:0,6656:8,6912:270532608,7168:8192,7424:268443656,7680:270540800,7936:2097160,4224:8,4480:2105344,4736:2097152,4992:268435464,5248:268443648,5504:8200,5760:270540808,6016:270532608,6272:270540800,6528:270532616,6784:8192,7040:2105352,7296:2097160,7552:0,7808:268435456,8064:268443656},{0:1048576,16:33555457,32:1024,48:1049601,64:34604033,80:0,96:1,112:34603009,128:33555456,144:1048577,160:33554433,176:34604032,192:34603008,208:1025,224:1049600,240:33554432,8:34603009,24:0,40:33555457,56:34604032,72:1048576,88:33554433,104:33554432,120:1025,136:1049601,152:33555456,168:34603008,184:1048577,200:1024,216:34604033,232:1,248:1049600,256:33554432,272:1048576,288:33555457,304:34603009,320:1048577,336:33555456,352:34604032,368:1049601,384:1025,400:34604033,416:1049600,432:1,448:0,464:34603008,480:33554433,496:1024,264:1049600,280:33555457,296:34603009,312:1,328:33554432,344:1048576,360:1025,376:34604032,392:33554433,408:34603008,424:0,440:34604033,456:1049601,472:1024,488:33555456,504:1048577},{0:134219808,1:131072,2:134217728,3:32,4:131104,5:134350880,6:134350848,7:2048,8:134348800,9:134219776,10:133120,11:134348832,12:2080,13:0,14:134217760,15:133152,2147483648:2048,2147483649:134350880,2147483650:134219808,2147483651:134217728,2147483652:134348800,2147483653:133120,2147483654:133152,2147483655:32,2147483656:134217760,2147483657:2080,2147483658:131104,2147483659:134350848,2147483660:0,2147483661:134348832,2147483662:134219776,2147483663:131072,16:133152,17:134350848,18:32,19:2048,20:134219776,21:134217760,22:134348832,23:131072,24:0,25:131104,26:134348800,27:134219808,28:134350880,29:133120,30:2080,31:134217728,2147483664:131072,2147483665:2048,2147483666:134348832,2147483667:133152,2147483668:32,2147483669:134348800,2147483670:134217728,2147483671:134219808,2147483672:134350880,2147483673:134217760,2147483674:134219776,2147483675:0,2147483676:133120,2147483677:2080,2147483678:131104,2147483679:134350848}],m=[4160749569,528482304,33030144,2064384,129024,8064,504,2147483679],n=h.DES=g.extend({_doReset:function(){for(var a=this._key,b=a.words,c=[],d=0;56>d;d++){var e=i[d]-1;c[d]=b[e>>>5]>>>31-e%32&1}for(var f=this._subKeys=[],g=0;16>g;g++){for(var h=f[g]=[],l=k[g],d=0;24>d;d++)h[d/6|0]|=c[(j[d]-1+l)%28]<<31-d%6,h[4+(d/6|0)]|=c[28+(j[d+24]-1+l)%28]<<31-d%6;h[0]=h[0]<<1|h[0]>>>31;for(var d=1;7>d;d++)h[d]=h[d]>>>4*(d-1)+3;h[7]=h[7]<<5|h[7]>>>27}for(var m=this._invSubKeys=[],d=0;16>d;d++)m[d]=f[15-d]},encryptBlock:function(a,b){this._doCryptBlock(a,b,this._subKeys)},decryptBlock:function(a,b){this._doCryptBlock(a,b,this._invSubKeys)},_doCryptBlock:function(a,d,e){this._lBlock=a[d],this._rBlock=a[d+1],b.call(this,4,252645135),b.call(this,16,65535),c.call(this,2,858993459),c.call(this,8,16711935),b.call(this,1,1431655765);for(var f=0;16>f;f++){for(var g=e[f],h=this._lBlock,i=this._rBlock,j=0,k=0;8>k;k++)j|=l[k][((i^g[k])&m[k])>>>0];this._lBlock=i,this._rBlock=h^j}var n=this._lBlock;this._lBlock=this._rBlock,this._rBlock=n,b.call(this,1,1431655765),c.call(this,8,16711935),c.call(this,2,858993459),b.call(this,16,65535),b.call(this,4,252645135),a[d]=this._lBlock,a[d+1]=this._rBlock},keySize:2,ivSize:2,blockSize:2});d.DES=g._createHelper(n);var o=h.TripleDES=g.extend({_doReset:function(){var a=this._key,b=a.words;this._des1=n.createEncryptor(f.create(b.slice(0,2))),this._des2=n.createEncryptor(f.create(b.slice(2,4))),this._des3=n.createEncryptor(f.create(b.slice(4,6)))},encryptBlock:function(a,b){this._des1.encryptBlock(a,b),this._des2.decryptBlock(a,b),this._des3.encryptBlock(a,b)},decryptBlock:function(a,b){this._des3.decryptBlock(a,b),this._des2.encryptBlock(a,b),this._des1.decryptBlock(a,b)},keySize:6,ivSize:2,blockSize:2});d.TripleDES=g._createHelper(o)}(),a.TripleDES})},{"./cipher-core":45,"./core":46,"./enc-base64":47,"./evpkdf":49,"./md5":54}],77:[function(a,b,c){!function(d,e){"object"==typeof c?b.exports=c=e(a("./core")):"function"==typeof define&&define.amd?define(["./core"],e):e(d.CryptoJS)}(this,function(a){return function(b){var c=a,d=c.lib,e=d.Base,f=d.WordArray,g=c.x64={};g.Word=e.extend({init:function(a,b){this.high=a,this.low=b}}),g.WordArray=e.extend({init:function(a,c){a=this.words=a||[],c!=b?this.sigBytes=c:this.sigBytes=8*a.length},toX32:function(){for(var a=this.words,b=a.length,c=[],d=0;b>d;d++){var e=a[d];c.push(e.high),c.push(e.low)}return f.create(c,this.sigBytes)},clone:function(){for(var a=e.clone.call(this),b=a.words=this.words.slice(0),c=b.length,d=0;c>d;d++)b[d]=b[d].clone();return a}})}(),a})},{"./core":46}],78:[function(a,b,c){function d(){k=!1,h.length?j=h.concat(j):l=-1,j.length&&e()}function e(){if(!k){var a=setTimeout(d);k=!0;for(var b=j.length;b;){for(h=j,j=[];++l<b;)h&&h[l].run();l=-1,b=j.length}h=null,k=!1,clearTimeout(a)}}function f(a,b){this.fun=a,this.array=b}function g(){}var h,i=b.exports={},j=[],k=!1,l=-1;i.nextTick=function(a){var b=new Array(arguments.length-1);if(arguments.length>1)for(var c=1;c<arguments.length;c++)b[c-1]=arguments[c];j.push(new f(a,b)),1!==j.length||k||setTimeout(e,0)},f.prototype.run=function(){this.fun.apply(null,this.array)},i.title="browser",i.browser=!0,i.env={},i.argv=[],i.version="",i.versions={},i.on=g,i.addListener=g,i.once=g,i.off=g,i.removeListener=g,i.removeAllListeners=g,i.emit=g,i.binding=function(a){throw new Error("process.binding is not supported")},i.cwd=function(){return"/"},i.chdir=function(a){throw new Error("process.chdir is not supported")},i.umask=function(){return 0}},{}],79:[function(a,b,c){(function(a,d){!function(){var b,c,e,f;!function(){var a={},d={};b=function(b,c,d){a[b]={deps:c,callback:d}},f=e=c=function(b){function e(a){if("."!==a.charAt(0))return a;for(var c=a.split("/"),d=b.split("/").slice(0,-1),e=0,f=c.length;f>e;e++){var g=c[e];if(".."===g)d.pop();else{if("."===g)continue;d.push(g)}}return d.join("/")}if(f._eak_seen=a,d[b])return d[b];if(d[b]={},!a[b])throw new Error("Could not find module "+b);for(var g,h=a[b],i=h.deps,j=h.callback,k=[],l=0,m=i.length;m>l;l++)"exports"===i[l]?k.push(g={}):k.push(c(e(i[l])));var n=j.apply(this,k);return d[b]=g||n}}(),b("promise/all",["./utils","exports"],function(a,b){"use strict";function c(a){var b=this;if(!d(a))throw new TypeError("You must pass an array to all.");return new b(function(b,c){function d(a){return function(b){f(a,b)}}function f(a,c){h[a]=c,0===--i&&b(h)}var g,h=[],i=a.length;0===i&&b([]);for(var j=0;j<a.length;j++)g=a[j],g&&e(g.then)?g.then(d(j),c):f(j,g)})}var d=a.isArray,e=a.isFunction;b.all=c}),b("promise/asap",["exports"],function(b){"use strict";function c(){return function(){a.nextTick(g)}}function e(){var a=0,b=new k(g),c=document.createTextNode("");return b.observe(c,{characterData:!0}),function(){c.data=a=++a%2}}function f(){return function(){l.setTimeout(g,1)}}function g(){for(var a=0;a<m.length;a++){var b=m[a],c=b[0],d=b[1];c(d)}m=[]}function h(a,b){var c=m.push([a,b]);1===c&&i()}var i,j="undefined"!=typeof window?window:{},k=j.MutationObserver||j.WebKitMutationObserver,l="undefined"!=typeof d?d:void 0===this?window:this,m=[];i="undefined"!=typeof a&&"[object process]"==={}.toString.call(a)?c():k?e():f(),b.asap=h}),b("promise/config",["exports"],function(a){"use strict";function b(a,b){return 2!==arguments.length?c[a]:void(c[a]=b)}var c={instrument:!1};a.config=c,a.configure=b}),b("promise/polyfill",["./promise","./utils","exports"],function(a,b,c){"use strict";function e(){var a;a="undefined"!=typeof d?d:"undefined"!=typeof window&&window.document?window:self;var b="Promise"in a&&"resolve"in a.Promise&&"reject"in a.Promise&&"all"in a.Promise&&"race"in a.Promise&&function(){var b;return new a.Promise(function(a){b=a}),g(b)}();b||(a.Promise=f)}var f=a.Promise,g=b.isFunction;c.polyfill=e}),b("promise/promise",["./config","./utils","./all","./race","./resolve","./reject","./asap","exports"],function(a,b,c,d,e,f,g,h){"use strict";function i(a){if(!v(a))throw new TypeError("You must pass a resolver function as the first argument to the promise constructor");if(!(this instanceof i))throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.");this._subscribers=[],j(a,this)}function j(a,b){function c(a){o(b,a)}function d(a){q(b,a)}try{a(c,d)}catch(e){d(e)}}function k(a,b,c,d){var e,f,g,h,i=v(c);if(i)try{e=c(d),g=!0}catch(j){h=!0,f=j}else e=d,g=!0;n(b,e)||(i&&g?o(b,e):h?q(b,f):a===D?o(b,e):a===E&&q(b,e)); }function l(a,b,c,d){var e=a._subscribers,f=e.length;e[f]=b,e[f+D]=c,e[f+E]=d}function m(a,b){for(var c,d,e=a._subscribers,f=a._detail,g=0;g<e.length;g+=3)c=e[g],d=e[g+b],k(b,c,d,f);a._subscribers=null}function n(a,b){var c,d=null;try{if(a===b)throw new TypeError("A promises callback cannot return that same promise.");if(u(b)&&(d=b.then,v(d)))return d.call(b,function(d){return c?!0:(c=!0,void(b!==d?o(a,d):p(a,d)))},function(b){return c?!0:(c=!0,void q(a,b))}),!0}catch(e){return c?!0:(q(a,e),!0)}return!1}function o(a,b){a===b?p(a,b):n(a,b)||p(a,b)}function p(a,b){a._state===B&&(a._state=C,a._detail=b,t.async(r,a))}function q(a,b){a._state===B&&(a._state=C,a._detail=b,t.async(s,a))}function r(a){m(a,a._state=D)}function s(a){m(a,a._state=E)}var t=a.config,u=(a.configure,b.objectOrFunction),v=b.isFunction,w=(b.now,c.all),x=d.race,y=e.resolve,z=f.reject,A=g.asap;t.async=A;var B=void 0,C=0,D=1,E=2;i.prototype={constructor:i,_state:void 0,_detail:void 0,_subscribers:void 0,then:function(a,b){var c=this,d=new this.constructor(function(){});if(this._state){var e=arguments;t.async(function(){k(c._state,d,e[c._state-1],c._detail)})}else l(this,d,a,b);return d},"catch":function(a){return this.then(null,a)}},i.all=w,i.race=x,i.resolve=y,i.reject=z,h.Promise=i}),b("promise/race",["./utils","exports"],function(a,b){"use strict";function c(a){var b=this;if(!d(a))throw new TypeError("You must pass an array to race.");return new b(function(b,c){for(var d,e=0;e<a.length;e++)d=a[e],d&&"function"==typeof d.then?d.then(b,c):b(d)})}var d=a.isArray;b.race=c}),b("promise/reject",["exports"],function(a){"use strict";function b(a){var b=this;return new b(function(b,c){c(a)})}a.reject=b}),b("promise/resolve",["exports"],function(a){"use strict";function b(a){if(a&&"object"==typeof a&&a.constructor===this)return a;var b=this;return new b(function(b){b(a)})}a.resolve=b}),b("promise/utils",["exports"],function(a){"use strict";function b(a){return c(a)||"object"==typeof a&&null!==a}function c(a){return"function"==typeof a}function d(a){return"[object Array]"===Object.prototype.toString.call(a)}var e=Date.now||function(){return(new Date).getTime()};a.objectOrFunction=b,a.isFunction=c,a.isArray=d,a.now=e}),c("promise/polyfill").polyfill()}(),function(a,d){"object"==typeof c&&"object"==typeof b?b.exports=d():"function"==typeof define&&define.amd?define([],d):"object"==typeof c?c.localforage=d():a.localforage=d()}(this,function(){return function(a){function b(d){if(c[d])return c[d].exports;var e=c[d]={exports:{},id:d,loaded:!1};return a[d].call(e.exports,e,e.exports,b),e.loaded=!0,e.exports}var c={};return b.m=a,b.c=c,b.p="",b(0)}([function(a,b,c){"use strict";function d(a,b){if(!(a instanceof b))throw new TypeError("Cannot call a class as a function")}b.__esModule=!0,function(){function a(a,b){a[b]=function(){var c=arguments;return a.ready().then(function(){return a[b].apply(a,c)})}}function e(){for(var a=1;a<arguments.length;a++){var b=arguments[a];if(b)for(var c in b)b.hasOwnProperty(c)&&(m(b[c])?arguments[0][c]=b[c].slice():arguments[0][c]=b[c])}return arguments[0]}function f(a){for(var b in h)if(h.hasOwnProperty(b)&&h[b]===a)return!0;return!1}var g={},h={INDEXEDDB:"asyncStorage",LOCALSTORAGE:"localStorageWrapper",WEBSQL:"webSQLStorage"},i=[h.INDEXEDDB,h.WEBSQL,h.LOCALSTORAGE],j=["clear","getItem","iterate","key","keys","length","removeItem","setItem"],k={description:"",driver:i.slice(),name:"localforage",size:4980736,storeName:"keyvaluepairs",version:1},l=function(a){var b=b||a.indexedDB||a.webkitIndexedDB||a.mozIndexedDB||a.OIndexedDB||a.msIndexedDB,c={};return c[h.WEBSQL]=!!a.openDatabase,c[h.INDEXEDDB]=!!function(){if("undefined"!=typeof a.openDatabase&&a.navigator&&a.navigator.userAgent&&/Safari/.test(a.navigator.userAgent)&&!/Chrome/.test(a.navigator.userAgent))return!1;try{return b&&"function"==typeof b.open&&"undefined"!=typeof a.IDBKeyRange}catch(c){return!1}}(),c[h.LOCALSTORAGE]=!!function(){try{return a.localStorage&&"setItem"in a.localStorage&&a.localStorage.setItem}catch(b){return!1}}(),c}(this),m=Array.isArray||function(a){return"[object Array]"===Object.prototype.toString.call(a)},n=function(){function b(a){d(this,b),this.INDEXEDDB=h.INDEXEDDB,this.LOCALSTORAGE=h.LOCALSTORAGE,this.WEBSQL=h.WEBSQL,this._defaultConfig=e({},k),this._config=e({},this._defaultConfig,a),this._driverSet=null,this._initDriver=null,this._ready=!1,this._dbInfo=null,this._wrapLibraryMethodsWithReady(),this.setDriver(this._config.driver)}return b.prototype.config=function(a){if("object"==typeof a){if(this._ready)return new Error("Can't call config() after localforage has been used.");for(var b in a)"storeName"===b&&(a[b]=a[b].replace(/\W/g,"_")),this._config[b]=a[b];return"driver"in a&&a.driver&&this.setDriver(this._config.driver),!0}return"string"==typeof a?this._config[a]:this._config},b.prototype.defineDriver=function(a,b,c){var d=new Promise(function(b,c){try{var d=a._driver,e=new Error("Custom driver not compliant; see https://mozilla.github.io/localForage/#definedriver"),h=new Error("Custom driver name already in use: "+a._driver);if(!a._driver)return void c(e);if(f(a._driver))return void c(h);for(var i=j.concat("_initStorage"),k=0;k<i.length;k++){var m=i[k];if(!m||!a[m]||"function"!=typeof a[m])return void c(e)}var n=Promise.resolve(!0);"_support"in a&&(n=a._support&&"function"==typeof a._support?a._support():Promise.resolve(!!a._support)),n.then(function(c){l[d]=c,g[d]=a,b()},c)}catch(o){c(o)}});return d.then(b,c),d},b.prototype.driver=function(){return this._driver||null},b.prototype.getDriver=function(a,b,d){var e=this,h=function(){if(f(a))switch(a){case e.INDEXEDDB:return new Promise(function(a,b){a(c(1))});case e.LOCALSTORAGE:return new Promise(function(a,b){a(c(2))});case e.WEBSQL:return new Promise(function(a,b){a(c(4))})}else if(g[a])return Promise.resolve(g[a]);return Promise.reject(new Error("Driver not found."))}();return h.then(b,d),h},b.prototype.getSerializer=function(a){var b=new Promise(function(a,b){a(c(3))});return a&&"function"==typeof a&&b.then(function(b){a(b)}),b},b.prototype.ready=function(a){var b=this,c=b._driverSet.then(function(){return null===b._ready&&(b._ready=b._initDriver()),b._ready});return c.then(a,a),c},b.prototype.setDriver=function(a,b,c){function d(){f._config.driver=f.driver()}function e(a){return function(){function b(){for(;c<a.length;){var e=a[c];return c++,f._dbInfo=null,f._ready=null,f.getDriver(e).then(function(a){return f._extend(a),d(),f._ready=f._initStorage(f._config),f._ready})["catch"](b)}d();var g=new Error("No available storage method found.");return f._driverSet=Promise.reject(g),f._driverSet}var c=0;return b()}}var f=this;m(a)||(a=[a]);var g=this._getSupportedDrivers(a),h=null!==this._driverSet?this._driverSet["catch"](function(){return Promise.resolve()}):Promise.resolve();return this._driverSet=h.then(function(){var a=g[0];return f._dbInfo=null,f._ready=null,f.getDriver(a).then(function(a){f._driver=a._driver,d(),f._wrapLibraryMethodsWithReady(),f._initDriver=e(g)})})["catch"](function(){d();var a=new Error("No available storage method found.");return f._driverSet=Promise.reject(a),f._driverSet}),this._driverSet.then(b,c),this._driverSet},b.prototype.supports=function(a){return!!l[a]},b.prototype._extend=function(a){e(this,a)},b.prototype._getSupportedDrivers=function(a){for(var b=[],c=0,d=a.length;d>c;c++){var e=a[c];this.supports(e)&&b.push(e)}return b},b.prototype._wrapLibraryMethodsWithReady=function(){for(var b=0;b<j.length;b++)a(this,j[b])},b.prototype.createInstance=function(a){return new b(a)},b}(),o=new n;b["default"]=o}.call("undefined"!=typeof window?window:self),a.exports=b["default"]},function(a,b){"use strict";b.__esModule=!0,function(){function a(a,b){a=a||[],b=b||{};try{return new Blob(a,b)}catch(c){if("TypeError"!==c.name)throw c;for(var d=x.BlobBuilder||x.MSBlobBuilder||x.MozBlobBuilder||x.WebKitBlobBuilder,e=new d,f=0;f<a.length;f+=1)e.append(a[f]);return e.getBlob(b.type)}}function c(a){for(var b=a.length,c=new ArrayBuffer(b),d=new Uint8Array(c),e=0;b>e;e++)d[e]=a.charCodeAt(e);return c}function d(a){return new Promise(function(b,c){var d=new XMLHttpRequest;d.open("GET",a),d.withCredentials=!0,d.responseType="arraybuffer",d.onreadystatechange=function(){return 4===d.readyState?200===d.status?b({response:d.response,type:d.getResponseHeader("Content-Type")}):void c({status:d.status,response:d.response}):void 0},d.send()})}function e(b){return new Promise(function(c,e){var f=a([""],{type:"image/png"}),g=b.transaction([B],"readwrite");g.objectStore(B).put(f,"key"),g.oncomplete=function(){var a=b.transaction([B],"readwrite"),f=a.objectStore(B).get("key");f.onerror=e,f.onsuccess=function(a){var b=a.target.result,e=URL.createObjectURL(b);d(e).then(function(a){c(!(!a||"image/png"!==a.type))},function(){c(!1)}).then(function(){URL.revokeObjectURL(e)})}}})["catch"](function(){return!1})}function f(a){return"boolean"==typeof z?Promise.resolve(z):e(a).then(function(a){return z=a})}function g(a){return new Promise(function(b,c){var d=new FileReader;d.onerror=c,d.onloadend=function(c){var d=btoa(c.target.result||"");b({__local_forage_encoded_blob:!0,data:d,type:a.type})},d.readAsBinaryString(a)})}function h(b){var d=c(atob(b.data));return a([d],{type:b.type})}function i(a){return a&&a.__local_forage_encoded_blob}function j(a){function b(){return Promise.resolve()}var c=this,d={db:null};if(a)for(var e in a)d[e]=a[e];A||(A={});var f=A[d.name];f||(f={forages:[],db:null},A[d.name]=f),f.forages.push(this);for(var g=[],h=0;h<f.forages.length;h++){var i=f.forages[h];i!==this&&g.push(i.ready()["catch"](b))}var j=f.forages.slice(0);return Promise.all(g).then(function(){return d.db=f.db,k(d)}).then(function(a){return d.db=a,n(d,c._defaultConfig.version)?l(d):a}).then(function(a){d.db=f.db=a,c._dbInfo=d;for(var b in j){var e=j[b];e!==c&&(e._dbInfo.db=d.db,e._dbInfo.version=d.version)}})}function k(a){return m(a,!1)}function l(a){return m(a,!0)}function m(a,b){return new Promise(function(c,d){if(a.db){if(!b)return c(a.db);a.db.close()}var e=[a.name];b&&e.push(a.version);var f=y.open.apply(y,e);b&&(f.onupgradeneeded=function(b){var c=f.result;try{c.createObjectStore(a.storeName),b.oldVersion<=1&&c.createObjectStore(B)}catch(d){if("ConstraintError"!==d.name)throw d;x.console.warn('The database "'+a.name+'" has been upgraded from version '+b.oldVersion+" to version "+b.newVersion+', but the storage "'+a.storeName+'" already exists.')}}),f.onerror=function(){d(f.error)},f.onsuccess=function(){c(f.result)}})}function n(a,b){if(!a.db)return!0;var c=!a.db.objectStoreNames.contains(a.storeName),d=a.version<a.db.version,e=a.version>a.db.version;if(d&&(a.version!==b&&x.console.warn('The database "'+a.name+"\" can't be downgraded from version "+a.db.version+" to version "+a.version+"."),a.version=a.db.version),e||c){if(c){var f=a.db.version+1;f>a.version&&(a.version=f)}return!0}return!1}function o(a,b){var c=this;"string"!=typeof a&&(x.console.warn(a+" used as a key, but it is not a string."),a=String(a));var d=new Promise(function(b,d){c.ready().then(function(){var e=c._dbInfo,f=e.db.transaction(e.storeName,"readonly").objectStore(e.storeName),g=f.get(a);g.onsuccess=function(){var a=g.result;void 0===a&&(a=null),i(a)&&(a=h(a)),b(a)},g.onerror=function(){d(g.error)}})["catch"](d)});return w(d,b),d}function p(a,b){var c=this,d=new Promise(function(b,d){c.ready().then(function(){var e=c._dbInfo,f=e.db.transaction(e.storeName,"readonly").objectStore(e.storeName),g=f.openCursor(),j=1;g.onsuccess=function(){var c=g.result;if(c){var d=c.value;i(d)&&(d=h(d));var e=a(d,c.key,j++);void 0!==e?b(e):c["continue"]()}else b()},g.onerror=function(){d(g.error)}})["catch"](d)});return w(d,b),d}function q(a,b,c){var d=this;"string"!=typeof a&&(x.console.warn(a+" used as a key, but it is not a string."),a=String(a));var e=new Promise(function(c,e){var h;d.ready().then(function(){return h=d._dbInfo,f(h.db)}).then(function(a){return!a&&b instanceof Blob?g(b):b}).then(function(b){var d=h.db.transaction(h.storeName,"readwrite"),f=d.objectStore(h.storeName);null===b&&(b=void 0);var g=f.put(b,a);d.oncomplete=function(){void 0===b&&(b=null),c(b)},d.onabort=d.onerror=function(){var a=g.error?g.error:g.transaction.error;e(a)}})["catch"](e)});return w(e,c),e}function r(a,b){var c=this;"string"!=typeof a&&(x.console.warn(a+" used as a key, but it is not a string."),a=String(a));var d=new Promise(function(b,d){c.ready().then(function(){var e=c._dbInfo,f=e.db.transaction(e.storeName,"readwrite"),g=f.objectStore(e.storeName),h=g["delete"](a);f.oncomplete=function(){b()},f.onerror=function(){d(h.error)},f.onabort=function(){var a=h.error?h.error:h.transaction.error;d(a)}})["catch"](d)});return w(d,b),d}function s(a){var b=this,c=new Promise(function(a,c){b.ready().then(function(){var d=b._dbInfo,e=d.db.transaction(d.storeName,"readwrite"),f=e.objectStore(d.storeName),g=f.clear();e.oncomplete=function(){a()},e.onabort=e.onerror=function(){var a=g.error?g.error:g.transaction.error;c(a)}})["catch"](c)});return w(c,a),c}function t(a){var b=this,c=new Promise(function(a,c){b.ready().then(function(){var d=b._dbInfo,e=d.db.transaction(d.storeName,"readonly").objectStore(d.storeName),f=e.count();f.onsuccess=function(){a(f.result)},f.onerror=function(){c(f.error)}})["catch"](c)});return w(c,a),c}function u(a,b){var c=this,d=new Promise(function(b,d){return 0>a?void b(null):void c.ready().then(function(){var e=c._dbInfo,f=e.db.transaction(e.storeName,"readonly").objectStore(e.storeName),g=!1,h=f.openCursor();h.onsuccess=function(){var c=h.result;return c?void(0===a?b(c.key):g?b(c.key):(g=!0,c.advance(a))):void b(null)},h.onerror=function(){d(h.error)}})["catch"](d)});return w(d,b),d}function v(a){var b=this,c=new Promise(function(a,c){b.ready().then(function(){var d=b._dbInfo,e=d.db.transaction(d.storeName,"readonly").objectStore(d.storeName),f=e.openCursor(),g=[];f.onsuccess=function(){var b=f.result;return b?(g.push(b.key),void b["continue"]()):void a(g)},f.onerror=function(){c(f.error)}})["catch"](c)});return w(c,a),c}function w(a,b){b&&a.then(function(a){b(null,a)},function(a){b(a)})}var x=this,y=y||this.indexedDB||this.webkitIndexedDB||this.mozIndexedDB||this.OIndexedDB||this.msIndexedDB;if(y){var z,A,B="local-forage-detect-blob-support",C={_driver:"asyncStorage",_initStorage:j,iterate:p,getItem:o,setItem:q,removeItem:r,clear:s,length:t,key:u,keys:v};b["default"]=C}}.call("undefined"!=typeof window?window:self),a.exports=b["default"]},function(a,b,c){"use strict";b.__esModule=!0,function(){function a(a){var b=this,d={};if(a)for(var e in a)d[e]=a[e];return d.keyPrefix=d.name+"/",d.storeName!==b._defaultConfig.storeName&&(d.keyPrefix+=d.storeName+"/"),b._dbInfo=d,new Promise(function(a,b){a(c(3))}).then(function(a){return d.serializer=a,Promise.resolve()})}function d(a){var b=this,c=b.ready().then(function(){for(var a=b._dbInfo.keyPrefix,c=n.length-1;c>=0;c--){var d=n.key(c);0===d.indexOf(a)&&n.removeItem(d)}});return l(c,a),c}function e(a,b){var c=this;"string"!=typeof a&&(m.console.warn(a+" used as a key, but it is not a string."),a=String(a));var d=c.ready().then(function(){var b=c._dbInfo,d=n.getItem(b.keyPrefix+a);return d&&(d=b.serializer.deserialize(d)),d});return l(d,b),d}function f(a,b){var c=this,d=c.ready().then(function(){for(var b=c._dbInfo,d=b.keyPrefix,e=d.length,f=n.length,g=1,h=0;f>h;h++){var i=n.key(h);if(0===i.indexOf(d)){var j=n.getItem(i);if(j&&(j=b.serializer.deserialize(j)),j=a(j,i.substring(e),g++),void 0!==j)return j}}});return l(d,b),d}function g(a,b){var c=this,d=c.ready().then(function(){var b,d=c._dbInfo;try{b=n.key(a)}catch(e){b=null}return b&&(b=b.substring(d.keyPrefix.length)),b});return l(d,b),d}function h(a){var b=this,c=b.ready().then(function(){for(var a=b._dbInfo,c=n.length,d=[],e=0;c>e;e++)0===n.key(e).indexOf(a.keyPrefix)&&d.push(n.key(e).substring(a.keyPrefix.length));return d});return l(c,a),c}function i(a){var b=this,c=b.keys().then(function(a){return a.length});return l(c,a),c}function j(a,b){var c=this;"string"!=typeof a&&(m.console.warn(a+" used as a key, but it is not a string."),a=String(a));var d=c.ready().then(function(){var b=c._dbInfo;n.removeItem(b.keyPrefix+a)});return l(d,b),d}function k(a,b,c){var d=this;"string"!=typeof a&&(m.console.warn(a+" used as a key, but it is not a string."),a=String(a));var e=d.ready().then(function(){void 0===b&&(b=null);var c=b;return new Promise(function(e,f){var g=d._dbInfo;g.serializer.serialize(b,function(b,d){if(d)f(d);else try{n.setItem(g.keyPrefix+a,b),e(c)}catch(h){("QuotaExceededError"===h.name||"NS_ERROR_DOM_QUOTA_REACHED"===h.name)&&f(h),f(h)}})})});return l(e,c),e}function l(a,b){b&&a.then(function(a){b(null,a)},function(a){b(a)})}var m=this,n=null;try{if(!(this.localStorage&&"setItem"in this.localStorage))return;n=this.localStorage}catch(o){return}var p={_driver:"localStorageWrapper",_initStorage:a,iterate:f,getItem:e,setItem:k,removeItem:j,clear:d,length:i,key:g,keys:h};b["default"]=p}.call("undefined"!=typeof window?window:self),a.exports=b["default"]},function(a,b){"use strict";b.__esModule=!0,function(){function a(a,b){a=a||[],b=b||{};try{return new Blob(a,b)}catch(c){if("TypeError"!==c.name)throw c;for(var d=x.BlobBuilder||x.MSBlobBuilder||x.MozBlobBuilder||x.WebKitBlobBuilder,e=new d,f=0;f<a.length;f+=1)e.append(a[f]);return e.getBlob(b.type)}}function c(a,b){var c="";if(a&&(c=a.toString()),a&&("[object ArrayBuffer]"===a.toString()||a.buffer&&"[object ArrayBuffer]"===a.buffer.toString())){var d,e=j;a instanceof ArrayBuffer?(d=a,e+=l):(d=a.buffer,"[object Int8Array]"===c?e+=n:"[object Uint8Array]"===c?e+=o:"[object Uint8ClampedArray]"===c?e+=p:"[object Int16Array]"===c?e+=q:"[object Uint16Array]"===c?e+=s:"[object Int32Array]"===c?e+=r:"[object Uint32Array]"===c?e+=t:"[object Float32Array]"===c?e+=u:"[object Float64Array]"===c?e+=v:b(new Error("Failed to get type for BinaryArray"))),b(e+f(d))}else if("[object Blob]"===c){var g=new FileReader;g.onload=function(){var c=h+a.type+"~"+f(this.result);b(j+m+c)},g.readAsArrayBuffer(a)}else try{b(JSON.stringify(a))}catch(i){console.error("Couldn't convert value into a JSON string: ",a),b(null,i)}}function d(b){if(b.substring(0,k)!==j)return JSON.parse(b);var c,d=b.substring(w),f=b.substring(k,w);if(f===m&&i.test(d)){var g=d.match(i);c=g[1],d=d.substring(g[0].length)}var h=e(d);switch(f){case l:return h;case m:return a([h],{type:c});case n:return new Int8Array(h);case o:return new Uint8Array(h);case p:return new Uint8ClampedArray(h);case q:return new Int16Array(h);case s:return new Uint16Array(h);case r:return new Int32Array(h);case t:return new Uint32Array(h);case u:return new Float32Array(h);case v:return new Float64Array(h);default:throw new Error("Unkown type: "+f)}}function e(a){var b,c,d,e,f,h=.75*a.length,i=a.length,j=0;"="===a[a.length-1]&&(h--,"="===a[a.length-2]&&h--);var k=new ArrayBuffer(h),l=new Uint8Array(k);for(b=0;i>b;b+=4)c=g.indexOf(a[b]),d=g.indexOf(a[b+1]),e=g.indexOf(a[b+2]),f=g.indexOf(a[b+3]),l[j++]=c<<2|d>>4,l[j++]=(15&d)<<4|e>>2,l[j++]=(3&e)<<6|63&f;return k}function f(a){var b,c=new Uint8Array(a),d="";for(b=0;b<c.length;b+=3)d+=g[c[b]>>2],d+=g[(3&c[b])<<4|c[b+1]>>4],d+=g[(15&c[b+1])<<2|c[b+2]>>6],d+=g[63&c[b+2]];return c.length%3===2?d=d.substring(0,d.length-1)+"=":c.length%3===1&&(d=d.substring(0,d.length-2)+"=="),d}var g="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",h="~~local_forage_type~",i=/^~~local_forage_type~([^~]+)~/,j="__lfsc__:",k=j.length,l="arbf",m="blob",n="si08",o="ui08",p="uic8",q="si16",r="si32",s="ur16",t="ui32",u="fl32",v="fl64",w=k+l.length,x=this,y={serialize:c,deserialize:d,stringToBuffer:e,bufferToString:f};b["default"]=y}.call("undefined"!=typeof window?window:self),a.exports=b["default"]},function(a,b,c){"use strict";b.__esModule=!0,function(){function a(a){var b=this,d={db:null};if(a)for(var e in a)d[e]="string"!=typeof a[e]?a[e].toString():a[e];var f=new Promise(function(c,e){try{d.db=n(d.name,String(d.version),d.description,d.size)}catch(f){return b.setDriver(b.LOCALSTORAGE).then(function(){return b._initStorage(a)}).then(c)["catch"](e)}d.db.transaction(function(a){a.executeSql("CREATE TABLE IF NOT EXISTS "+d.storeName+" (id INTEGER PRIMARY KEY, key unique, value)",[],function(){b._dbInfo=d,c()},function(a,b){e(b)})})});return new Promise(function(a,b){a(c(3))}).then(function(a){return d.serializer=a,f})}function d(a,b){var c=this;"string"!=typeof a&&(m.console.warn(a+" used as a key, but it is not a string."),a=String(a));var d=new Promise(function(b,d){c.ready().then(function(){var e=c._dbInfo;e.db.transaction(function(c){c.executeSql("SELECT * FROM "+e.storeName+" WHERE key = ? LIMIT 1",[a],function(a,c){var d=c.rows.length?c.rows.item(0).value:null;d&&(d=e.serializer.deserialize(d)),b(d)},function(a,b){d(b)})})})["catch"](d)});return l(d,b),d}function e(a,b){var c=this,d=new Promise(function(b,d){c.ready().then(function(){var e=c._dbInfo;e.db.transaction(function(c){c.executeSql("SELECT * FROM "+e.storeName,[],function(c,d){for(var f=d.rows,g=f.length,h=0;g>h;h++){var i=f.item(h),j=i.value;if(j&&(j=e.serializer.deserialize(j)),j=a(j,i.key,h+1),void 0!==j)return void b(j)}b()},function(a,b){d(b)})})})["catch"](d)});return l(d,b),d}function f(a,b,c){var d=this;"string"!=typeof a&&(m.console.warn(a+" used as a key, but it is not a string."),a=String(a));var e=new Promise(function(c,e){d.ready().then(function(){void 0===b&&(b=null);var f=b,g=d._dbInfo;g.serializer.serialize(b,function(b,d){d?e(d):g.db.transaction(function(d){d.executeSql("INSERT OR REPLACE INTO "+g.storeName+" (key, value) VALUES (?, ?)",[a,b],function(){c(f)},function(a,b){e(b)})},function(a){a.code===a.QUOTA_ERR&&e(a)})})})["catch"](e)});return l(e,c),e}function g(a,b){var c=this;"string"!=typeof a&&(m.console.warn(a+" used as a key, but it is not a string."),a=String(a));var d=new Promise(function(b,d){c.ready().then(function(){var e=c._dbInfo;e.db.transaction(function(c){c.executeSql("DELETE FROM "+e.storeName+" WHERE key = ?",[a],function(){b()},function(a,b){d(b)})})})["catch"](d)});return l(d,b),d}function h(a){var b=this,c=new Promise(function(a,c){b.ready().then(function(){var d=b._dbInfo;d.db.transaction(function(b){b.executeSql("DELETE FROM "+d.storeName,[],function(){a()},function(a,b){c(b)})})})["catch"](c)});return l(c,a),c}function i(a){var b=this,c=new Promise(function(a,c){b.ready().then(function(){var d=b._dbInfo;d.db.transaction(function(b){b.executeSql("SELECT COUNT(key) as c FROM "+d.storeName,[],function(b,c){var d=c.rows.item(0).c;a(d)},function(a,b){c(b)})})})["catch"](c)});return l(c,a),c}function j(a,b){var c=this,d=new Promise(function(b,d){c.ready().then(function(){var e=c._dbInfo;e.db.transaction(function(c){c.executeSql("SELECT key FROM "+e.storeName+" WHERE id = ? LIMIT 1",[a+1],function(a,c){var d=c.rows.length?c.rows.item(0).key:null;b(d)},function(a,b){d(b)})})})["catch"](d)});return l(d,b),d}function k(a){var b=this,c=new Promise(function(a,c){b.ready().then(function(){var d=b._dbInfo;d.db.transaction(function(b){b.executeSql("SELECT key FROM "+d.storeName,[],function(b,c){for(var d=[],e=0;e<c.rows.length;e++)d.push(c.rows.item(e).key);a(d)},function(a,b){c(b)})})})["catch"](c)});return l(c,a),c}function l(a,b){b&&a.then(function(a){b(null,a)},function(a){b(a)})}var m=this,n=this.openDatabase;if(n){var o={_driver:"webSQLStorage",_initStorage:a,iterate:e,getItem:d,setItem:f,removeItem:g,clear:h,length:i,key:j,keys:k};b["default"]=o}}.call("undefined"!=typeof window?window:self),a.exports=b["default"]}])})}).call(this,a("_process"),"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{_process:78}],80:[function(a,b,c){"use strict";var d=a("./lib/utils/common").assign,e=a("./lib/deflate"),f=a("./lib/inflate"),g=a("./lib/zlib/constants"),h={};d(h,e,f,g),b.exports=h},{"./lib/deflate":81,"./lib/inflate":82,"./lib/utils/common":83,"./lib/zlib/constants":86}],81:[function(a,b,c){"use strict";function d(a,b){var c=new u(b);if(c.push(a,!0),c.err)throw c.msg;return c.result}function e(a,b){return b=b||{},b.raw=!0,d(a,b)}function f(a,b){return b=b||{},b.gzip=!0,d(a,b)}var g=a("./zlib/deflate.js"),h=a("./utils/common"),i=a("./utils/strings"),j=a("./zlib/messages"),k=a("./zlib/zstream"),l=Object.prototype.toString,m=0,n=4,o=0,p=1,q=2,r=-1,s=0,t=8,u=function(a){this.options=h.assign({level:r,method:t,chunkSize:16384,windowBits:15,memLevel:8,strategy:s,to:""},a||{});var b=this.options;b.raw&&b.windowBits>0?b.windowBits=-b.windowBits:b.gzip&&b.windowBits>0&&b.windowBits<16&&(b.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new k,this.strm.avail_out=0;var c=g.deflateInit2(this.strm,b.level,b.method,b.windowBits,b.memLevel,b.strategy);if(c!==o)throw new Error(j[c]);b.header&&g.deflateSetHeader(this.strm,b.header)};u.prototype.push=function(a,b){var c,d,e=this.strm,f=this.options.chunkSize;if(this.ended)return!1;d=b===~~b?b:b===!0?n:m,"string"==typeof a?e.input=i.string2buf(a):"[object ArrayBuffer]"===l.call(a)?e.input=new Uint8Array(a):e.input=a,e.next_in=0,e.avail_in=e.input.length;do{if(0===e.avail_out&&(e.output=new h.Buf8(f),e.next_out=0,e.avail_out=f),c=g.deflate(e,d),c!==p&&c!==o)return this.onEnd(c),this.ended=!0,!1;(0===e.avail_out||0===e.avail_in&&(d===n||d===q))&&("string"===this.options.to?this.onData(i.buf2binstring(h.shrinkBuf(e.output,e.next_out))):this.onData(h.shrinkBuf(e.output,e.next_out)))}while((e.avail_in>0||0===e.avail_out)&&c!==p);return d===n?(c=g.deflateEnd(this.strm),this.onEnd(c),this.ended=!0,c===o):d===q?(this.onEnd(o),e.avail_out=0,!0):!0},u.prototype.onData=function(a){this.chunks.push(a)},u.prototype.onEnd=function(a){a===o&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=h.flattenChunks(this.chunks)),this.chunks=[],this.err=a,this.msg=this.strm.msg},c.Deflate=u,c.deflate=d,c.deflateRaw=e,c.gzip=f},{"./utils/common":83,"./utils/strings":84,"./zlib/deflate.js":88,"./zlib/messages":93,"./zlib/zstream":95}],82:[function(a,b,c){"use strict";function d(a,b){var c=new n(b);if(c.push(a,!0),c.err)throw c.msg;return c.result}function e(a,b){return b=b||{},b.raw=!0,d(a,b)}var f=a("./zlib/inflate.js"),g=a("./utils/common"),h=a("./utils/strings"),i=a("./zlib/constants"),j=a("./zlib/messages"),k=a("./zlib/zstream"),l=a("./zlib/gzheader"),m=Object.prototype.toString,n=function(a){this.options=g.assign({chunkSize:16384,windowBits:0,to:""},a||{});var b=this.options;b.raw&&b.windowBits>=0&&b.windowBits<16&&(b.windowBits=-b.windowBits,0===b.windowBits&&(b.windowBits=-15)),!(b.windowBits>=0&&b.windowBits<16)||a&&a.windowBits||(b.windowBits+=32),b.windowBits>15&&b.windowBits<48&&0===(15&b.windowBits)&&(b.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new k,this.strm.avail_out=0;var c=f.inflateInit2(this.strm,b.windowBits);if(c!==i.Z_OK)throw new Error(j[c]);this.header=new l,f.inflateGetHeader(this.strm,this.header)};n.prototype.push=function(a,b){var c,d,e,j,k,l=this.strm,n=this.options.chunkSize,o=!1;if(this.ended)return!1;d=b===~~b?b:b===!0?i.Z_FINISH:i.Z_NO_FLUSH,"string"==typeof a?l.input=h.binstring2buf(a):"[object ArrayBuffer]"===m.call(a)?l.input=new Uint8Array(a):l.input=a,l.next_in=0,l.avail_in=l.input.length;do{if(0===l.avail_out&&(l.output=new g.Buf8(n),l.next_out=0,l.avail_out=n),c=f.inflate(l,i.Z_NO_FLUSH),c===i.Z_BUF_ERROR&&o===!0&&(c=i.Z_OK,o=!1),c!==i.Z_STREAM_END&&c!==i.Z_OK)return this.onEnd(c),this.ended=!0,!1;l.next_out&&(0===l.avail_out||c===i.Z_STREAM_END||0===l.avail_in&&(d===i.Z_FINISH||d===i.Z_SYNC_FLUSH))&&("string"===this.options.to?(e=h.utf8border(l.output,l.next_out),j=l.next_out-e,k=h.buf2string(l.output,e),l.next_out=j,l.avail_out=n-j,j&&g.arraySet(l.output,l.output,e,j,0),this.onData(k)):this.onData(g.shrinkBuf(l.output,l.next_out))),0===l.avail_in&&0===l.avail_out&&(o=!0)}while((l.avail_in>0||0===l.avail_out)&&c!==i.Z_STREAM_END);return c===i.Z_STREAM_END&&(d=i.Z_FINISH),d===i.Z_FINISH?(c=f.inflateEnd(this.strm),this.onEnd(c),this.ended=!0,c===i.Z_OK):d===i.Z_SYNC_FLUSH?(this.onEnd(i.Z_OK),l.avail_out=0,!0):!0},n.prototype.onData=function(a){this.chunks.push(a)},n.prototype.onEnd=function(a){a===i.Z_OK&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=g.flattenChunks(this.chunks)),this.chunks=[],this.err=a,this.msg=this.strm.msg},c.Inflate=n,c.inflate=d,c.inflateRaw=e,c.ungzip=d},{"./utils/common":83,"./utils/strings":84,"./zlib/constants":86,"./zlib/gzheader":89,"./zlib/inflate.js":91,"./zlib/messages":93,"./zlib/zstream":95}],83:[function(a,b,c){"use strict";var d="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Int32Array;c.assign=function(a){for(var b=Array.prototype.slice.call(arguments,1);b.length;){var c=b.shift();if(c){if("object"!=typeof c)throw new TypeError(c+"must be non-object");for(var d in c)c.hasOwnProperty(d)&&(a[d]=c[d])}}return a},c.shrinkBuf=function(a,b){return a.length===b?a:a.subarray?a.subarray(0,b):(a.length=b,a)};var e={arraySet:function(a,b,c,d,e){if(b.subarray&&a.subarray)return void a.set(b.subarray(c,c+d),e);for(var f=0;d>f;f++)a[e+f]=b[c+f]},flattenChunks:function(a){var b,c,d,e,f,g;for(d=0,b=0,c=a.length;c>b;b++)d+=a[b].length;for(g=new Uint8Array(d),e=0,b=0,c=a.length;c>b;b++)f=a[b],g.set(f,e),e+=f.length;return g}},f={arraySet:function(a,b,c,d,e){for(var f=0;d>f;f++)a[e+f]=b[c+f]},flattenChunks:function(a){return[].concat.apply([],a)}};c.setTyped=function(a){a?(c.Buf8=Uint8Array,c.Buf16=Uint16Array,c.Buf32=Int32Array,c.assign(c,e)):(c.Buf8=Array,c.Buf16=Array,c.Buf32=Array,c.assign(c,f))},c.setTyped(d)},{}],84:[function(a,b,c){"use strict";function d(a,b){if(65537>b&&(a.subarray&&g||!a.subarray&&f))return String.fromCharCode.apply(null,e.shrinkBuf(a,b));for(var c="",d=0;b>d;d++)c+=String.fromCharCode(a[d]);return c}var e=a("./common"),f=!0,g=!0;try{String.fromCharCode.apply(null,[0])}catch(h){f=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch(h){g=!1}for(var i=new e.Buf8(256),j=0;256>j;j++)i[j]=j>=252?6:j>=248?5:j>=240?4:j>=224?3:j>=192?2:1;i[254]=i[254]=1,c.string2buf=function(a){var b,c,d,f,g,h=a.length,i=0;for(f=0;h>f;f++)c=a.charCodeAt(f),55296===(64512&c)&&h>f+1&&(d=a.charCodeAt(f+1),56320===(64512&d)&&(c=65536+(c-55296<<10)+(d-56320),f++)),i+=128>c?1:2048>c?2:65536>c?3:4;for(b=new e.Buf8(i),g=0,f=0;i>g;f++)c=a.charCodeAt(f),55296===(64512&c)&&h>f+1&&(d=a.charCodeAt(f+1),56320===(64512&d)&&(c=65536+(c-55296<<10)+(d-56320),f++)),128>c?b[g++]=c:2048>c?(b[g++]=192|c>>>6,b[g++]=128|63&c):65536>c?(b[g++]=224|c>>>12,b[g++]=128|c>>>6&63,b[g++]=128|63&c):(b[g++]=240|c>>>18,b[g++]=128|c>>>12&63,b[g++]=128|c>>>6&63,b[g++]=128|63&c);return b},c.buf2binstring=function(a){return d(a,a.length)},c.binstring2buf=function(a){for(var b=new e.Buf8(a.length),c=0,d=b.length;d>c;c++)b[c]=a.charCodeAt(c);return b},c.buf2string=function(a,b){var c,e,f,g,h=b||a.length,j=new Array(2*h);for(e=0,c=0;h>c;)if(f=a[c++],128>f)j[e++]=f;else if(g=i[f],g>4)j[e++]=65533,c+=g-1;else{for(f&=2===g?31:3===g?15:7;g>1&&h>c;)f=f<<6|63&a[c++],g--;g>1?j[e++]=65533:65536>f?j[e++]=f:(f-=65536,j[e++]=55296|f>>10&1023,j[e++]=56320|1023&f)}return d(j,e)},c.utf8border=function(a,b){var c;for(b=b||a.length,b>a.length&&(b=a.length),c=b-1;c>=0&&128===(192&a[c]);)c--;return 0>c?b:0===c?b:c+i[a[c]]>b?c:b}},{"./common":83}],85:[function(a,b,c){"use strict";function d(a,b,c,d){for(var e=65535&a|0,f=a>>>16&65535|0,g=0;0!==c;){g=c>2e3?2e3:c,c-=g;do e=e+b[d++]|0,f=f+e|0;while(--g);e%=65521,f%=65521}return e|f<<16|0}b.exports=d},{}],86:[function(a,b,c){b.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],87:[function(a,b,c){"use strict";function d(){for(var a,b=[],c=0;256>c;c++){ a=c;for(var d=0;8>d;d++)a=1&a?3988292384^a>>>1:a>>>1;b[c]=a}return b}function e(a,b,c,d){var e=f,g=d+c;a=-1^a;for(var h=d;g>h;h++)a=a>>>8^e[255&(a^b[h])];return-1^a}var f=d();b.exports=e},{}],88:[function(a,b,c){"use strict";function d(a,b){return a.msg=G[b],b}function e(a){return(a<<1)-(a>4?9:0)}function f(a){for(var b=a.length;--b>=0;)a[b]=0}function g(a){var b=a.state,c=b.pending;c>a.avail_out&&(c=a.avail_out),0!==c&&(C.arraySet(a.output,b.pending_buf,b.pending_out,c,a.next_out),a.next_out+=c,b.pending_out+=c,a.total_out+=c,a.avail_out-=c,b.pending-=c,0===b.pending&&(b.pending_out=0))}function h(a,b){D._tr_flush_block(a,a.block_start>=0?a.block_start:-1,a.strstart-a.block_start,b),a.block_start=a.strstart,g(a.strm)}function i(a,b){a.pending_buf[a.pending++]=b}function j(a,b){a.pending_buf[a.pending++]=b>>>8&255,a.pending_buf[a.pending++]=255&b}function k(a,b,c,d){var e=a.avail_in;return e>d&&(e=d),0===e?0:(a.avail_in-=e,C.arraySet(b,a.input,a.next_in,e,c),1===a.state.wrap?a.adler=E(a.adler,b,e,c):2===a.state.wrap&&(a.adler=F(a.adler,b,e,c)),a.next_in+=e,a.total_in+=e,e)}function l(a,b){var c,d,e=a.max_chain_length,f=a.strstart,g=a.prev_length,h=a.nice_match,i=a.strstart>a.w_size-ja?a.strstart-(a.w_size-ja):0,j=a.window,k=a.w_mask,l=a.prev,m=a.strstart+ia,n=j[f+g-1],o=j[f+g];a.prev_length>=a.good_match&&(e>>=2),h>a.lookahead&&(h=a.lookahead);do if(c=b,j[c+g]===o&&j[c+g-1]===n&&j[c]===j[f]&&j[++c]===j[f+1]){f+=2,c++;do;while(j[++f]===j[++c]&&j[++f]===j[++c]&&j[++f]===j[++c]&&j[++f]===j[++c]&&j[++f]===j[++c]&&j[++f]===j[++c]&&j[++f]===j[++c]&&j[++f]===j[++c]&&m>f);if(d=ia-(m-f),f=m-ia,d>g){if(a.match_start=b,g=d,d>=h)break;n=j[f+g-1],o=j[f+g]}}while((b=l[b&k])>i&&0!==--e);return g<=a.lookahead?g:a.lookahead}function m(a){var b,c,d,e,f,g=a.w_size;do{if(e=a.window_size-a.lookahead-a.strstart,a.strstart>=g+(g-ja)){C.arraySet(a.window,a.window,g,g,0),a.match_start-=g,a.strstart-=g,a.block_start-=g,c=a.hash_size,b=c;do d=a.head[--b],a.head[b]=d>=g?d-g:0;while(--c);c=g,b=c;do d=a.prev[--b],a.prev[b]=d>=g?d-g:0;while(--c);e+=g}if(0===a.strm.avail_in)break;if(c=k(a.strm,a.window,a.strstart+a.lookahead,e),a.lookahead+=c,a.lookahead+a.insert>=ha)for(f=a.strstart-a.insert,a.ins_h=a.window[f],a.ins_h=(a.ins_h<<a.hash_shift^a.window[f+1])&a.hash_mask;a.insert&&(a.ins_h=(a.ins_h<<a.hash_shift^a.window[f+ha-1])&a.hash_mask,a.prev[f&a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=f,f++,a.insert--,!(a.lookahead+a.insert<ha)););}while(a.lookahead<ja&&0!==a.strm.avail_in)}function n(a,b){var c=65535;for(c>a.pending_buf_size-5&&(c=a.pending_buf_size-5);;){if(a.lookahead<=1){if(m(a),0===a.lookahead&&b===H)return sa;if(0===a.lookahead)break}a.strstart+=a.lookahead,a.lookahead=0;var d=a.block_start+c;if((0===a.strstart||a.strstart>=d)&&(a.lookahead=a.strstart-d,a.strstart=d,h(a,!1),0===a.strm.avail_out))return sa;if(a.strstart-a.block_start>=a.w_size-ja&&(h(a,!1),0===a.strm.avail_out))return sa}return a.insert=0,b===K?(h(a,!0),0===a.strm.avail_out?ua:va):a.strstart>a.block_start&&(h(a,!1),0===a.strm.avail_out)?sa:sa}function o(a,b){for(var c,d;;){if(a.lookahead<ja){if(m(a),a.lookahead<ja&&b===H)return sa;if(0===a.lookahead)break}if(c=0,a.lookahead>=ha&&(a.ins_h=(a.ins_h<<a.hash_shift^a.window[a.strstart+ha-1])&a.hash_mask,c=a.prev[a.strstart&a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=a.strstart),0!==c&&a.strstart-c<=a.w_size-ja&&(a.match_length=l(a,c)),a.match_length>=ha)if(d=D._tr_tally(a,a.strstart-a.match_start,a.match_length-ha),a.lookahead-=a.match_length,a.match_length<=a.max_lazy_match&&a.lookahead>=ha){a.match_length--;do a.strstart++,a.ins_h=(a.ins_h<<a.hash_shift^a.window[a.strstart+ha-1])&a.hash_mask,c=a.prev[a.strstart&a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=a.strstart;while(0!==--a.match_length);a.strstart++}else a.strstart+=a.match_length,a.match_length=0,a.ins_h=a.window[a.strstart],a.ins_h=(a.ins_h<<a.hash_shift^a.window[a.strstart+1])&a.hash_mask;else d=D._tr_tally(a,0,a.window[a.strstart]),a.lookahead--,a.strstart++;if(d&&(h(a,!1),0===a.strm.avail_out))return sa}return a.insert=a.strstart<ha-1?a.strstart:ha-1,b===K?(h(a,!0),0===a.strm.avail_out?ua:va):a.last_lit&&(h(a,!1),0===a.strm.avail_out)?sa:ta}function p(a,b){for(var c,d,e;;){if(a.lookahead<ja){if(m(a),a.lookahead<ja&&b===H)return sa;if(0===a.lookahead)break}if(c=0,a.lookahead>=ha&&(a.ins_h=(a.ins_h<<a.hash_shift^a.window[a.strstart+ha-1])&a.hash_mask,c=a.prev[a.strstart&a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=a.strstart),a.prev_length=a.match_length,a.prev_match=a.match_start,a.match_length=ha-1,0!==c&&a.prev_length<a.max_lazy_match&&a.strstart-c<=a.w_size-ja&&(a.match_length=l(a,c),a.match_length<=5&&(a.strategy===S||a.match_length===ha&&a.strstart-a.match_start>4096)&&(a.match_length=ha-1)),a.prev_length>=ha&&a.match_length<=a.prev_length){e=a.strstart+a.lookahead-ha,d=D._tr_tally(a,a.strstart-1-a.prev_match,a.prev_length-ha),a.lookahead-=a.prev_length-1,a.prev_length-=2;do++a.strstart<=e&&(a.ins_h=(a.ins_h<<a.hash_shift^a.window[a.strstart+ha-1])&a.hash_mask,c=a.prev[a.strstart&a.w_mask]=a.head[a.ins_h],a.head[a.ins_h]=a.strstart);while(0!==--a.prev_length);if(a.match_available=0,a.match_length=ha-1,a.strstart++,d&&(h(a,!1),0===a.strm.avail_out))return sa}else if(a.match_available){if(d=D._tr_tally(a,0,a.window[a.strstart-1]),d&&h(a,!1),a.strstart++,a.lookahead--,0===a.strm.avail_out)return sa}else a.match_available=1,a.strstart++,a.lookahead--}return a.match_available&&(d=D._tr_tally(a,0,a.window[a.strstart-1]),a.match_available=0),a.insert=a.strstart<ha-1?a.strstart:ha-1,b===K?(h(a,!0),0===a.strm.avail_out?ua:va):a.last_lit&&(h(a,!1),0===a.strm.avail_out)?sa:ta}function q(a,b){for(var c,d,e,f,g=a.window;;){if(a.lookahead<=ia){if(m(a),a.lookahead<=ia&&b===H)return sa;if(0===a.lookahead)break}if(a.match_length=0,a.lookahead>=ha&&a.strstart>0&&(e=a.strstart-1,d=g[e],d===g[++e]&&d===g[++e]&&d===g[++e])){f=a.strstart+ia;do;while(d===g[++e]&&d===g[++e]&&d===g[++e]&&d===g[++e]&&d===g[++e]&&d===g[++e]&&d===g[++e]&&d===g[++e]&&f>e);a.match_length=ia-(f-e),a.match_length>a.lookahead&&(a.match_length=a.lookahead)}if(a.match_length>=ha?(c=D._tr_tally(a,1,a.match_length-ha),a.lookahead-=a.match_length,a.strstart+=a.match_length,a.match_length=0):(c=D._tr_tally(a,0,a.window[a.strstart]),a.lookahead--,a.strstart++),c&&(h(a,!1),0===a.strm.avail_out))return sa}return a.insert=0,b===K?(h(a,!0),0===a.strm.avail_out?ua:va):a.last_lit&&(h(a,!1),0===a.strm.avail_out)?sa:ta}function r(a,b){for(var c;;){if(0===a.lookahead&&(m(a),0===a.lookahead)){if(b===H)return sa;break}if(a.match_length=0,c=D._tr_tally(a,0,a.window[a.strstart]),a.lookahead--,a.strstart++,c&&(h(a,!1),0===a.strm.avail_out))return sa}return a.insert=0,b===K?(h(a,!0),0===a.strm.avail_out?ua:va):a.last_lit&&(h(a,!1),0===a.strm.avail_out)?sa:ta}function s(a){a.window_size=2*a.w_size,f(a.head),a.max_lazy_match=B[a.level].max_lazy,a.good_match=B[a.level].good_length,a.nice_match=B[a.level].nice_length,a.max_chain_length=B[a.level].max_chain,a.strstart=0,a.block_start=0,a.lookahead=0,a.insert=0,a.match_length=a.prev_length=ha-1,a.match_available=0,a.ins_h=0}function t(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=Y,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new C.Buf16(2*fa),this.dyn_dtree=new C.Buf16(2*(2*da+1)),this.bl_tree=new C.Buf16(2*(2*ea+1)),f(this.dyn_ltree),f(this.dyn_dtree),f(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new C.Buf16(ga+1),this.heap=new C.Buf16(2*ca+1),f(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new C.Buf16(2*ca+1),f(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function u(a){var b;return a&&a.state?(a.total_in=a.total_out=0,a.data_type=X,b=a.state,b.pending=0,b.pending_out=0,b.wrap<0&&(b.wrap=-b.wrap),b.status=b.wrap?la:qa,a.adler=2===b.wrap?0:1,b.last_flush=H,D._tr_init(b),M):d(a,O)}function v(a){var b=u(a);return b===M&&s(a.state),b}function w(a,b){return a&&a.state?2!==a.state.wrap?O:(a.state.gzhead=b,M):O}function x(a,b,c,e,f,g){if(!a)return O;var h=1;if(b===R&&(b=6),0>e?(h=0,e=-e):e>15&&(h=2,e-=16),1>f||f>Z||c!==Y||8>e||e>15||0>b||b>9||0>g||g>V)return d(a,O);8===e&&(e=9);var i=new t;return a.state=i,i.strm=a,i.wrap=h,i.gzhead=null,i.w_bits=e,i.w_size=1<<i.w_bits,i.w_mask=i.w_size-1,i.hash_bits=f+7,i.hash_size=1<<i.hash_bits,i.hash_mask=i.hash_size-1,i.hash_shift=~~((i.hash_bits+ha-1)/ha),i.window=new C.Buf8(2*i.w_size),i.head=new C.Buf16(i.hash_size),i.prev=new C.Buf16(i.w_size),i.lit_bufsize=1<<f+6,i.pending_buf_size=4*i.lit_bufsize,i.pending_buf=new C.Buf8(i.pending_buf_size),i.d_buf=i.lit_bufsize>>1,i.l_buf=3*i.lit_bufsize,i.level=b,i.strategy=g,i.method=c,v(a)}function y(a,b){return x(a,b,Y,$,_,W)}function z(a,b){var c,h,k,l;if(!a||!a.state||b>L||0>b)return a?d(a,O):O;if(h=a.state,!a.output||!a.input&&0!==a.avail_in||h.status===ra&&b!==K)return d(a,0===a.avail_out?Q:O);if(h.strm=a,c=h.last_flush,h.last_flush=b,h.status===la)if(2===h.wrap)a.adler=0,i(h,31),i(h,139),i(h,8),h.gzhead?(i(h,(h.gzhead.text?1:0)+(h.gzhead.hcrc?2:0)+(h.gzhead.extra?4:0)+(h.gzhead.name?8:0)+(h.gzhead.comment?16:0)),i(h,255&h.gzhead.time),i(h,h.gzhead.time>>8&255),i(h,h.gzhead.time>>16&255),i(h,h.gzhead.time>>24&255),i(h,9===h.level?2:h.strategy>=T||h.level<2?4:0),i(h,255&h.gzhead.os),h.gzhead.extra&&h.gzhead.extra.length&&(i(h,255&h.gzhead.extra.length),i(h,h.gzhead.extra.length>>8&255)),h.gzhead.hcrc&&(a.adler=F(a.adler,h.pending_buf,h.pending,0)),h.gzindex=0,h.status=ma):(i(h,0),i(h,0),i(h,0),i(h,0),i(h,0),i(h,9===h.level?2:h.strategy>=T||h.level<2?4:0),i(h,wa),h.status=qa);else{var m=Y+(h.w_bits-8<<4)<<8,n=-1;n=h.strategy>=T||h.level<2?0:h.level<6?1:6===h.level?2:3,m|=n<<6,0!==h.strstart&&(m|=ka),m+=31-m%31,h.status=qa,j(h,m),0!==h.strstart&&(j(h,a.adler>>>16),j(h,65535&a.adler)),a.adler=1}if(h.status===ma)if(h.gzhead.extra){for(k=h.pending;h.gzindex<(65535&h.gzhead.extra.length)&&(h.pending!==h.pending_buf_size||(h.gzhead.hcrc&&h.pending>k&&(a.adler=F(a.adler,h.pending_buf,h.pending-k,k)),g(a),k=h.pending,h.pending!==h.pending_buf_size));)i(h,255&h.gzhead.extra[h.gzindex]),h.gzindex++;h.gzhead.hcrc&&h.pending>k&&(a.adler=F(a.adler,h.pending_buf,h.pending-k,k)),h.gzindex===h.gzhead.extra.length&&(h.gzindex=0,h.status=na)}else h.status=na;if(h.status===na)if(h.gzhead.name){k=h.pending;do{if(h.pending===h.pending_buf_size&&(h.gzhead.hcrc&&h.pending>k&&(a.adler=F(a.adler,h.pending_buf,h.pending-k,k)),g(a),k=h.pending,h.pending===h.pending_buf_size)){l=1;break}l=h.gzindex<h.gzhead.name.length?255&h.gzhead.name.charCodeAt(h.gzindex++):0,i(h,l)}while(0!==l);h.gzhead.hcrc&&h.pending>k&&(a.adler=F(a.adler,h.pending_buf,h.pending-k,k)),0===l&&(h.gzindex=0,h.status=oa)}else h.status=oa;if(h.status===oa)if(h.gzhead.comment){k=h.pending;do{if(h.pending===h.pending_buf_size&&(h.gzhead.hcrc&&h.pending>k&&(a.adler=F(a.adler,h.pending_buf,h.pending-k,k)),g(a),k=h.pending,h.pending===h.pending_buf_size)){l=1;break}l=h.gzindex<h.gzhead.comment.length?255&h.gzhead.comment.charCodeAt(h.gzindex++):0,i(h,l)}while(0!==l);h.gzhead.hcrc&&h.pending>k&&(a.adler=F(a.adler,h.pending_buf,h.pending-k,k)),0===l&&(h.status=pa)}else h.status=pa;if(h.status===pa&&(h.gzhead.hcrc?(h.pending+2>h.pending_buf_size&&g(a),h.pending+2<=h.pending_buf_size&&(i(h,255&a.adler),i(h,a.adler>>8&255),a.adler=0,h.status=qa)):h.status=qa),0!==h.pending){if(g(a),0===a.avail_out)return h.last_flush=-1,M}else if(0===a.avail_in&&e(b)<=e(c)&&b!==K)return d(a,Q);if(h.status===ra&&0!==a.avail_in)return d(a,Q);if(0!==a.avail_in||0!==h.lookahead||b!==H&&h.status!==ra){var o=h.strategy===T?r(h,b):h.strategy===U?q(h,b):B[h.level].func(h,b);if((o===ua||o===va)&&(h.status=ra),o===sa||o===ua)return 0===a.avail_out&&(h.last_flush=-1),M;if(o===ta&&(b===I?D._tr_align(h):b!==L&&(D._tr_stored_block(h,0,0,!1),b===J&&(f(h.head),0===h.lookahead&&(h.strstart=0,h.block_start=0,h.insert=0))),g(a),0===a.avail_out))return h.last_flush=-1,M}return b!==K?M:h.wrap<=0?N:(2===h.wrap?(i(h,255&a.adler),i(h,a.adler>>8&255),i(h,a.adler>>16&255),i(h,a.adler>>24&255),i(h,255&a.total_in),i(h,a.total_in>>8&255),i(h,a.total_in>>16&255),i(h,a.total_in>>24&255)):(j(h,a.adler>>>16),j(h,65535&a.adler)),g(a),h.wrap>0&&(h.wrap=-h.wrap),0!==h.pending?M:N)}function A(a){var b;return a&&a.state?(b=a.state.status,b!==la&&b!==ma&&b!==na&&b!==oa&&b!==pa&&b!==qa&&b!==ra?d(a,O):(a.state=null,b===qa?d(a,P):M)):O}var B,C=a("../utils/common"),D=a("./trees"),E=a("./adler32"),F=a("./crc32"),G=a("./messages"),H=0,I=1,J=3,K=4,L=5,M=0,N=1,O=-2,P=-3,Q=-5,R=-1,S=1,T=2,U=3,V=4,W=0,X=2,Y=8,Z=9,$=15,_=8,aa=29,ba=256,ca=ba+1+aa,da=30,ea=19,fa=2*ca+1,ga=15,ha=3,ia=258,ja=ia+ha+1,ka=32,la=42,ma=69,na=73,oa=91,pa=103,qa=113,ra=666,sa=1,ta=2,ua=3,va=4,wa=3,xa=function(a,b,c,d,e){this.good_length=a,this.max_lazy=b,this.nice_length=c,this.max_chain=d,this.func=e};B=[new xa(0,0,0,0,n),new xa(4,4,8,4,o),new xa(4,5,16,8,o),new xa(4,6,32,32,o),new xa(4,4,16,16,p),new xa(8,16,32,32,p),new xa(8,16,128,128,p),new xa(8,32,128,256,p),new xa(32,128,258,1024,p),new xa(32,258,258,4096,p)],c.deflateInit=y,c.deflateInit2=x,c.deflateReset=v,c.deflateResetKeep=u,c.deflateSetHeader=w,c.deflate=z,c.deflateEnd=A,c.deflateInfo="pako deflate (from Nodeca project)"},{"../utils/common":83,"./adler32":85,"./crc32":87,"./messages":93,"./trees":94}],89:[function(a,b,c){"use strict";function d(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}b.exports=d},{}],90:[function(a,b,c){"use strict";var d=30,e=12;b.exports=function(a,b){var c,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,A,B,C;c=a.state,f=a.next_in,B=a.input,g=f+(a.avail_in-5),h=a.next_out,C=a.output,i=h-(b-a.avail_out),j=h+(a.avail_out-257),k=c.dmax,l=c.wsize,m=c.whave,n=c.wnext,o=c.window,p=c.hold,q=c.bits,r=c.lencode,s=c.distcode,t=(1<<c.lenbits)-1,u=(1<<c.distbits)-1;a:do{15>q&&(p+=B[f++]<<q,q+=8,p+=B[f++]<<q,q+=8),v=r[p&t];b:for(;;){if(w=v>>>24,p>>>=w,q-=w,w=v>>>16&255,0===w)C[h++]=65535&v;else{if(!(16&w)){if(0===(64&w)){v=r[(65535&v)+(p&(1<<w)-1)];continue b}if(32&w){c.mode=e;break a}a.msg="invalid literal/length code",c.mode=d;break a}x=65535&v,w&=15,w&&(w>q&&(p+=B[f++]<<q,q+=8),x+=p&(1<<w)-1,p>>>=w,q-=w),15>q&&(p+=B[f++]<<q,q+=8,p+=B[f++]<<q,q+=8),v=s[p&u];c:for(;;){if(w=v>>>24,p>>>=w,q-=w,w=v>>>16&255,!(16&w)){if(0===(64&w)){v=s[(65535&v)+(p&(1<<w)-1)];continue c}a.msg="invalid distance code",c.mode=d;break a}if(y=65535&v,w&=15,w>q&&(p+=B[f++]<<q,q+=8,w>q&&(p+=B[f++]<<q,q+=8)),y+=p&(1<<w)-1,y>k){a.msg="invalid distance too far back",c.mode=d;break a}if(p>>>=w,q-=w,w=h-i,y>w){if(w=y-w,w>m&&c.sane){a.msg="invalid distance too far back",c.mode=d;break a}if(z=0,A=o,0===n){if(z+=l-w,x>w){x-=w;do C[h++]=o[z++];while(--w);z=h-y,A=C}}else if(w>n){if(z+=l+n-w,w-=n,x>w){x-=w;do C[h++]=o[z++];while(--w);if(z=0,x>n){w=n,x-=w;do C[h++]=o[z++];while(--w);z=h-y,A=C}}}else if(z+=n-w,x>w){x-=w;do C[h++]=o[z++];while(--w);z=h-y,A=C}for(;x>2;)C[h++]=A[z++],C[h++]=A[z++],C[h++]=A[z++],x-=3;x&&(C[h++]=A[z++],x>1&&(C[h++]=A[z++]))}else{z=h-y;do C[h++]=C[z++],C[h++]=C[z++],C[h++]=C[z++],x-=3;while(x>2);x&&(C[h++]=C[z++],x>1&&(C[h++]=C[z++]))}break}}break}}while(g>f&&j>h);x=q>>3,f-=x,q-=x<<3,p&=(1<<q)-1,a.next_in=f,a.next_out=h,a.avail_in=g>f?5+(g-f):5-(f-g),a.avail_out=j>h?257+(j-h):257-(h-j),c.hold=p,c.bits=q}},{}],91:[function(a,b,c){"use strict";function d(a){return(a>>>24&255)+(a>>>8&65280)+((65280&a)<<8)+((255&a)<<24)}function e(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new r.Buf16(320),this.work=new r.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function f(a){var b;return a&&a.state?(b=a.state,a.total_in=a.total_out=b.total=0,a.msg="",b.wrap&&(a.adler=1&b.wrap),b.mode=K,b.last=0,b.havedict=0,b.dmax=32768,b.head=null,b.hold=0,b.bits=0,b.lencode=b.lendyn=new r.Buf32(oa),b.distcode=b.distdyn=new r.Buf32(pa),b.sane=1,b.back=-1,C):F}function g(a){var b;return a&&a.state?(b=a.state,b.wsize=0,b.whave=0,b.wnext=0,f(a)):F}function h(a,b){var c,d;return a&&a.state?(d=a.state,0>b?(c=0,b=-b):(c=(b>>4)+1,48>b&&(b&=15)),b&&(8>b||b>15)?F:(null!==d.window&&d.wbits!==b&&(d.window=null),d.wrap=c,d.wbits=b,g(a))):F}function i(a,b){var c,d;return a?(d=new e,a.state=d,d.window=null,c=h(a,b),c!==C&&(a.state=null),c):F}function j(a){return i(a,ra)}function k(a){if(sa){var b;for(p=new r.Buf32(512),q=new r.Buf32(32),b=0;144>b;)a.lens[b++]=8;for(;256>b;)a.lens[b++]=9;for(;280>b;)a.lens[b++]=7;for(;288>b;)a.lens[b++]=8;for(v(x,a.lens,0,288,p,0,a.work,{bits:9}),b=0;32>b;)a.lens[b++]=5;v(y,a.lens,0,32,q,0,a.work,{bits:5}),sa=!1}a.lencode=p,a.lenbits=9,a.distcode=q,a.distbits=5}function l(a,b,c,d){var e,f=a.state;return null===f.window&&(f.wsize=1<<f.wbits,f.wnext=0,f.whave=0,f.window=new r.Buf8(f.wsize)),d>=f.wsize?(r.arraySet(f.window,b,c-f.wsize,f.wsize,0),f.wnext=0,f.whave=f.wsize):(e=f.wsize-f.wnext,e>d&&(e=d),r.arraySet(f.window,b,c-d,e,f.wnext),d-=e,d?(r.arraySet(f.window,b,c-d,d,0),f.wnext=d,f.whave=f.wsize):(f.wnext+=e,f.wnext===f.wsize&&(f.wnext=0),f.whave<f.wsize&&(f.whave+=e))),0}function m(a,b){var c,e,f,g,h,i,j,m,n,o,p,q,oa,pa,qa,ra,sa,ta,ua,va,wa,xa,ya,za,Aa=0,Ba=new r.Buf8(4),Ca=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!a||!a.state||!a.output||!a.input&&0!==a.avail_in)return F;c=a.state,c.mode===V&&(c.mode=W),h=a.next_out,f=a.output,j=a.avail_out,g=a.next_in,e=a.input,i=a.avail_in,m=c.hold,n=c.bits,o=i,p=j,xa=C;a:for(;;)switch(c.mode){case K:if(0===c.wrap){c.mode=W;break}for(;16>n;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}if(2&c.wrap&&35615===m){c.check=0,Ba[0]=255&m,Ba[1]=m>>>8&255,c.check=t(c.check,Ba,2,0),m=0,n=0,c.mode=L;break}if(c.flags=0,c.head&&(c.head.done=!1),!(1&c.wrap)||(((255&m)<<8)+(m>>8))%31){a.msg="incorrect header check",c.mode=la;break}if((15&m)!==J){a.msg="unknown compression method",c.mode=la;break}if(m>>>=4,n-=4,wa=(15&m)+8,0===c.wbits)c.wbits=wa;else if(wa>c.wbits){a.msg="invalid window size",c.mode=la;break}c.dmax=1<<wa,a.adler=c.check=1,c.mode=512&m?T:V,m=0,n=0;break;case L:for(;16>n;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}if(c.flags=m,(255&c.flags)!==J){a.msg="unknown compression method",c.mode=la;break}if(57344&c.flags){a.msg="unknown header flags set",c.mode=la;break}c.head&&(c.head.text=m>>8&1),512&c.flags&&(Ba[0]=255&m,Ba[1]=m>>>8&255,c.check=t(c.check,Ba,2,0)),m=0,n=0,c.mode=M;case M:for(;32>n;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}c.head&&(c.head.time=m),512&c.flags&&(Ba[0]=255&m,Ba[1]=m>>>8&255,Ba[2]=m>>>16&255,Ba[3]=m>>>24&255,c.check=t(c.check,Ba,4,0)),m=0,n=0,c.mode=N;case N:for(;16>n;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}c.head&&(c.head.xflags=255&m,c.head.os=m>>8),512&c.flags&&(Ba[0]=255&m,Ba[1]=m>>>8&255,c.check=t(c.check,Ba,2,0)),m=0,n=0,c.mode=O;case O:if(1024&c.flags){for(;16>n;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}c.length=m,c.head&&(c.head.extra_len=m),512&c.flags&&(Ba[0]=255&m,Ba[1]=m>>>8&255,c.check=t(c.check,Ba,2,0)),m=0,n=0}else c.head&&(c.head.extra=null);c.mode=P;case P:if(1024&c.flags&&(q=c.length,q>i&&(q=i),q&&(c.head&&(wa=c.head.extra_len-c.length,c.head.extra||(c.head.extra=new Array(c.head.extra_len)),r.arraySet(c.head.extra,e,g,q,wa)),512&c.flags&&(c.check=t(c.check,e,q,g)),i-=q,g+=q,c.length-=q),c.length))break a;c.length=0,c.mode=Q;case Q:if(2048&c.flags){if(0===i)break a;q=0;do wa=e[g+q++],c.head&&wa&&c.length<65536&&(c.head.name+=String.fromCharCode(wa));while(wa&&i>q);if(512&c.flags&&(c.check=t(c.check,e,q,g)),i-=q,g+=q,wa)break a}else c.head&&(c.head.name=null);c.length=0,c.mode=R;case R:if(4096&c.flags){if(0===i)break a;q=0;do wa=e[g+q++],c.head&&wa&&c.length<65536&&(c.head.comment+=String.fromCharCode(wa));while(wa&&i>q);if(512&c.flags&&(c.check=t(c.check,e,q,g)),i-=q,g+=q,wa)break a}else c.head&&(c.head.comment=null);c.mode=S;case S:if(512&c.flags){for(;16>n;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}if(m!==(65535&c.check)){a.msg="header crc mismatch",c.mode=la;break}m=0,n=0}c.head&&(c.head.hcrc=c.flags>>9&1,c.head.done=!0),a.adler=c.check=0,c.mode=V;break;case T:for(;32>n;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}a.adler=c.check=d(m),m=0,n=0,c.mode=U;case U:if(0===c.havedict)return a.next_out=h,a.avail_out=j,a.next_in=g,a.avail_in=i,c.hold=m,c.bits=n,E;a.adler=c.check=1,c.mode=V;case V:if(b===A||b===B)break a;case W:if(c.last){m>>>=7&n,n-=7&n,c.mode=ia;break}for(;3>n;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}switch(c.last=1&m,m>>>=1,n-=1,3&m){case 0:c.mode=X;break;case 1:if(k(c),c.mode=ba,b===B){m>>>=2,n-=2;break a}break;case 2:c.mode=$;break;case 3:a.msg="invalid block type",c.mode=la}m>>>=2,n-=2;break;case X:for(m>>>=7&n,n-=7&n;32>n;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}if((65535&m)!==(m>>>16^65535)){a.msg="invalid stored block lengths",c.mode=la;break}if(c.length=65535&m,m=0,n=0,c.mode=Y,b===B)break a;case Y:c.mode=Z;case Z:if(q=c.length){if(q>i&&(q=i),q>j&&(q=j),0===q)break a;r.arraySet(f,e,g,q,h),i-=q,g+=q,j-=q,h+=q,c.length-=q;break}c.mode=V;break;case $:for(;14>n;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}if(c.nlen=(31&m)+257,m>>>=5,n-=5,c.ndist=(31&m)+1,m>>>=5,n-=5,c.ncode=(15&m)+4,m>>>=4,n-=4,c.nlen>286||c.ndist>30){a.msg="too many length or distance symbols",c.mode=la;break}c.have=0,c.mode=_;case _:for(;c.have<c.ncode;){for(;3>n;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}c.lens[Ca[c.have++]]=7&m,m>>>=3,n-=3}for(;c.have<19;)c.lens[Ca[c.have++]]=0;if(c.lencode=c.lendyn,c.lenbits=7,ya={bits:c.lenbits},xa=v(w,c.lens,0,19,c.lencode,0,c.work,ya),c.lenbits=ya.bits,xa){a.msg="invalid code lengths set",c.mode=la;break}c.have=0,c.mode=aa;case aa:for(;c.have<c.nlen+c.ndist;){for(;Aa=c.lencode[m&(1<<c.lenbits)-1],qa=Aa>>>24,ra=Aa>>>16&255,sa=65535&Aa,!(n>=qa);){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}if(16>sa)m>>>=qa,n-=qa,c.lens[c.have++]=sa;else{if(16===sa){for(za=qa+2;za>n;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}if(m>>>=qa,n-=qa,0===c.have){a.msg="invalid bit length repeat",c.mode=la;break}wa=c.lens[c.have-1],q=3+(3&m),m>>>=2,n-=2}else if(17===sa){for(za=qa+3;za>n;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}m>>>=qa,n-=qa,wa=0,q=3+(7&m),m>>>=3,n-=3}else{for(za=qa+7;za>n;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}m>>>=qa,n-=qa,wa=0,q=11+(127&m),m>>>=7,n-=7}if(c.have+q>c.nlen+c.ndist){a.msg="invalid bit length repeat",c.mode=la;break}for(;q--;)c.lens[c.have++]=wa}}if(c.mode===la)break;if(0===c.lens[256]){a.msg="invalid code -- missing end-of-block",c.mode=la;break}if(c.lenbits=9,ya={bits:c.lenbits},xa=v(x,c.lens,0,c.nlen,c.lencode,0,c.work,ya),c.lenbits=ya.bits,xa){a.msg="invalid literal/lengths set",c.mode=la;break}if(c.distbits=6,c.distcode=c.distdyn,ya={bits:c.distbits},xa=v(y,c.lens,c.nlen,c.ndist,c.distcode,0,c.work,ya),c.distbits=ya.bits,xa){a.msg="invalid distances set",c.mode=la;break}if(c.mode=ba,b===B)break a;case ba:c.mode=ca;case ca:if(i>=6&&j>=258){a.next_out=h,a.avail_out=j,a.next_in=g,a.avail_in=i,c.hold=m,c.bits=n,u(a,p),h=a.next_out,f=a.output,j=a.avail_out,g=a.next_in,e=a.input,i=a.avail_in,m=c.hold,n=c.bits,c.mode===V&&(c.back=-1);break}for(c.back=0;Aa=c.lencode[m&(1<<c.lenbits)-1],qa=Aa>>>24,ra=Aa>>>16&255,sa=65535&Aa,!(n>=qa);){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}if(ra&&0===(240&ra)){for(ta=qa,ua=ra,va=sa;Aa=c.lencode[va+((m&(1<<ta+ua)-1)>>ta)],qa=Aa>>>24,ra=Aa>>>16&255,sa=65535&Aa,!(n>=ta+qa);){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}m>>>=ta,n-=ta,c.back+=ta}if(m>>>=qa,n-=qa,c.back+=qa,c.length=sa,0===ra){c.mode=ha;break}if(32&ra){c.back=-1,c.mode=V;break}if(64&ra){a.msg="invalid literal/length code",c.mode=la;break}c.extra=15&ra,c.mode=da;case da:if(c.extra){for(za=c.extra;za>n;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}c.length+=m&(1<<c.extra)-1,m>>>=c.extra,n-=c.extra,c.back+=c.extra}c.was=c.length,c.mode=ea;case ea:for(;Aa=c.distcode[m&(1<<c.distbits)-1],qa=Aa>>>24,ra=Aa>>>16&255,sa=65535&Aa,!(n>=qa);){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}if(0===(240&ra)){for(ta=qa,ua=ra,va=sa;Aa=c.distcode[va+((m&(1<<ta+ua)-1)>>ta)],qa=Aa>>>24,ra=Aa>>>16&255,sa=65535&Aa,!(n>=ta+qa);){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}m>>>=ta,n-=ta,c.back+=ta}if(m>>>=qa,n-=qa,c.back+=qa,64&ra){a.msg="invalid distance code",c.mode=la;break}c.offset=sa,c.extra=15&ra,c.mode=fa;case fa:if(c.extra){for(za=c.extra;za>n;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}c.offset+=m&(1<<c.extra)-1,m>>>=c.extra,n-=c.extra,c.back+=c.extra}if(c.offset>c.dmax){a.msg="invalid distance too far back",c.mode=la;break}c.mode=ga;case ga:if(0===j)break a;if(q=p-j,c.offset>q){if(q=c.offset-q,q>c.whave&&c.sane){a.msg="invalid distance too far back",c.mode=la;break}q>c.wnext?(q-=c.wnext,oa=c.wsize-q):oa=c.wnext-q,q>c.length&&(q=c.length),pa=c.window}else pa=f,oa=h-c.offset,q=c.length;q>j&&(q=j),j-=q,c.length-=q;do f[h++]=pa[oa++];while(--q);0===c.length&&(c.mode=ca);break;case ha:if(0===j)break a;f[h++]=c.length,j--,c.mode=ca;break;case ia:if(c.wrap){for(;32>n;){if(0===i)break a;i--,m|=e[g++]<<n,n+=8}if(p-=j,a.total_out+=p,c.total+=p,p&&(a.adler=c.check=c.flags?t(c.check,f,p,h-p):s(c.check,f,p,h-p)),p=j,(c.flags?m:d(m))!==c.check){a.msg="incorrect data check",c.mode=la;break}m=0,n=0}c.mode=ja;case ja:if(c.wrap&&c.flags){for(;32>n;){if(0===i)break a;i--,m+=e[g++]<<n,n+=8}if(m!==(4294967295&c.total)){a.msg="incorrect length check",c.mode=la;break}m=0,n=0}c.mode=ka;case ka:xa=D;break a;case la:xa=G;break a;case ma:return H;case na:default:return F}return a.next_out=h,a.avail_out=j,a.next_in=g,a.avail_in=i,c.hold=m,c.bits=n,(c.wsize||p!==a.avail_out&&c.mode<la&&(c.mode<ia||b!==z))&&l(a,a.output,a.next_out,p-a.avail_out)?(c.mode=ma,H):(o-=a.avail_in,p-=a.avail_out,a.total_in+=o,a.total_out+=p,c.total+=p,c.wrap&&p&&(a.adler=c.check=c.flags?t(c.check,f,p,a.next_out-p):s(c.check,f,p,a.next_out-p)),a.data_type=c.bits+(c.last?64:0)+(c.mode===V?128:0)+(c.mode===ba||c.mode===Y?256:0),(0===o&&0===p||b===z)&&xa===C&&(xa=I),xa)}function n(a){if(!a||!a.state)return F;var b=a.state;return b.window&&(b.window=null),a.state=null,C}function o(a,b){var c;return a&&a.state?(c=a.state,0===(2&c.wrap)?F:(c.head=b,b.done=!1,C)):F}var p,q,r=a("../utils/common"),s=a("./adler32"),t=a("./crc32"),u=a("./inffast"),v=a("./inftrees"),w=0,x=1,y=2,z=4,A=5,B=6,C=0,D=1,E=2,F=-2,G=-3,H=-4,I=-5,J=8,K=1,L=2,M=3,N=4,O=5,P=6,Q=7,R=8,S=9,T=10,U=11,V=12,W=13,X=14,Y=15,Z=16,$=17,_=18,aa=19,ba=20,ca=21,da=22,ea=23,fa=24,ga=25,ha=26,ia=27,ja=28,ka=29,la=30,ma=31,na=32,oa=852,pa=592,qa=15,ra=qa,sa=!0;c.inflateReset=g,c.inflateReset2=h,c.inflateResetKeep=f,c.inflateInit=j,c.inflateInit2=i,c.inflate=m,c.inflateEnd=n,c.inflateGetHeader=o,c.inflateInfo="pako inflate (from Nodeca project)"},{"../utils/common":83,"./adler32":85,"./crc32":87,"./inffast":90,"./inftrees":92}],92:[function(a,b,c){"use strict";var d=a("../utils/common"),e=15,f=852,g=592,h=0,i=1,j=2,k=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],l=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],m=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],n=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];b.exports=function(a,b,c,o,p,q,r,s){var t,u,v,w,x,y,z,A,B,C=s.bits,D=0,E=0,F=0,G=0,H=0,I=0,J=0,K=0,L=0,M=0,N=null,O=0,P=new d.Buf16(e+1),Q=new d.Buf16(e+1),R=null,S=0;for(D=0;e>=D;D++)P[D]=0;for(E=0;o>E;E++)P[b[c+E]]++;for(H=C,G=e;G>=1&&0===P[G];G--);if(H>G&&(H=G),0===G)return p[q++]=20971520,p[q++]=20971520,s.bits=1,0;for(F=1;G>F&&0===P[F];F++);for(F>H&&(H=F),K=1,D=1;e>=D;D++)if(K<<=1,K-=P[D],0>K)return-1;if(K>0&&(a===h||1!==G))return-1;for(Q[1]=0,D=1;e>D;D++)Q[D+1]=Q[D]+P[D];for(E=0;o>E;E++)0!==b[c+E]&&(r[Q[b[c+E]]++]=E);if(a===h?(N=R=r,y=19):a===i?(N=k,O-=257,R=l,S-=257,y=256):(N=m,R=n,y=-1),M=0,E=0,D=F,x=q,I=H,J=0,v=-1,L=1<<H,w=L-1,a===i&&L>f||a===j&&L>g)return 1;for(var T=0;;){T++,z=D-J,r[E]<y?(A=0,B=r[E]):r[E]>y?(A=R[S+r[E]],B=N[O+r[E]]):(A=96,B=0),t=1<<D-J,u=1<<I,F=u;do u-=t,p[x+(M>>J)+u]=z<<24|A<<16|B|0;while(0!==u);for(t=1<<D-1;M&t;)t>>=1;if(0!==t?(M&=t-1,M+=t):M=0,E++,0===--P[D]){if(D===G)break;D=b[c+r[E]]}if(D>H&&(M&w)!==v){for(0===J&&(J=H),x+=F,I=D-J,K=1<<I;G>I+J&&(K-=P[I+J],!(0>=K));)I++,K<<=1;if(L+=1<<I,a===i&&L>f||a===j&&L>g)return 1;v=M&w,p[v]=H<<24|I<<16|x-q|0}}return 0!==M&&(p[x+M]=D-J<<24|64<<16|0),s.bits=H,0}},{"../utils/common":83}],93:[function(a,b,c){"use strict";b.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],94:[function(a,b,c){"use strict";function d(a){for(var b=a.length;--b>=0;)a[b]=0}function e(a){return 256>a?ga[a]:ga[256+(a>>>7)]}function f(a,b){a.pending_buf[a.pending++]=255&b,a.pending_buf[a.pending++]=b>>>8&255}function g(a,b,c){a.bi_valid>V-c?(a.bi_buf|=b<<a.bi_valid&65535,f(a,a.bi_buf),a.bi_buf=b>>V-a.bi_valid,a.bi_valid+=c-V):(a.bi_buf|=b<<a.bi_valid&65535,a.bi_valid+=c)}function h(a,b,c){g(a,c[2*b],c[2*b+1])}function i(a,b){var c=0;do c|=1&a,a>>>=1,c<<=1;while(--b>0);return c>>>1}function j(a){16===a.bi_valid?(f(a,a.bi_buf),a.bi_buf=0,a.bi_valid=0):a.bi_valid>=8&&(a.pending_buf[a.pending++]=255&a.bi_buf,a.bi_buf>>=8,a.bi_valid-=8)}function k(a,b){var c,d,e,f,g,h,i=b.dyn_tree,j=b.max_code,k=b.stat_desc.static_tree,l=b.stat_desc.has_stree,m=b.stat_desc.extra_bits,n=b.stat_desc.extra_base,o=b.stat_desc.max_length,p=0;for(f=0;U>=f;f++)a.bl_count[f]=0;for(i[2*a.heap[a.heap_max]+1]=0,c=a.heap_max+1;T>c;c++)d=a.heap[c],f=i[2*i[2*d+1]+1]+1,f>o&&(f=o,p++),i[2*d+1]=f,d>j||(a.bl_count[f]++,g=0,d>=n&&(g=m[d-n]),h=i[2*d],a.opt_len+=h*(f+g),l&&(a.static_len+=h*(k[2*d+1]+g)));if(0!==p){do{for(f=o-1;0===a.bl_count[f];)f--;a.bl_count[f]--,a.bl_count[f+1]+=2,a.bl_count[o]--,p-=2}while(p>0);for(f=o;0!==f;f--)for(d=a.bl_count[f];0!==d;)e=a.heap[--c],e>j||(i[2*e+1]!==f&&(a.opt_len+=(f-i[2*e+1])*i[2*e],i[2*e+1]=f),d--)}}function l(a,b,c){var d,e,f=new Array(U+1),g=0;for(d=1;U>=d;d++)f[d]=g=g+c[d-1]<<1;for(e=0;b>=e;e++){var h=a[2*e+1];0!==h&&(a[2*e]=i(f[h]++,h))}}function m(){var a,b,c,d,e,f=new Array(U+1);for(c=0,d=0;O-1>d;d++)for(ia[d]=c,a=0;a<1<<_[d];a++)ha[c++]=d;for(ha[c-1]=d,e=0,d=0;16>d;d++)for(ja[d]=e,a=0;a<1<<aa[d];a++)ga[e++]=d;for(e>>=7;R>d;d++)for(ja[d]=e<<7,a=0;a<1<<aa[d]-7;a++)ga[256+e++]=d;for(b=0;U>=b;b++)f[b]=0;for(a=0;143>=a;)ea[2*a+1]=8,a++,f[8]++;for(;255>=a;)ea[2*a+1]=9,a++,f[9]++;for(;279>=a;)ea[2*a+1]=7,a++,f[7]++;for(;287>=a;)ea[2*a+1]=8,a++,f[8]++;for(l(ea,Q+1,f),a=0;R>a;a++)fa[2*a+1]=5,fa[2*a]=i(a,5);ka=new na(ea,_,P+1,Q,U),la=new na(fa,aa,0,R,U),ma=new na(new Array(0),ba,0,S,W)}function n(a){var b;for(b=0;Q>b;b++)a.dyn_ltree[2*b]=0;for(b=0;R>b;b++)a.dyn_dtree[2*b]=0;for(b=0;S>b;b++)a.bl_tree[2*b]=0;a.dyn_ltree[2*X]=1,a.opt_len=a.static_len=0,a.last_lit=a.matches=0}function o(a){a.bi_valid>8?f(a,a.bi_buf):a.bi_valid>0&&(a.pending_buf[a.pending++]=a.bi_buf),a.bi_buf=0,a.bi_valid=0}function p(a,b,c,d){o(a),d&&(f(a,c),f(a,~c)),E.arraySet(a.pending_buf,a.window,b,c,a.pending),a.pending+=c}function q(a,b,c,d){var e=2*b,f=2*c;return a[e]<a[f]||a[e]===a[f]&&d[b]<=d[c]}function r(a,b,c){for(var d=a.heap[c],e=c<<1;e<=a.heap_len&&(e<a.heap_len&&q(b,a.heap[e+1],a.heap[e],a.depth)&&e++,!q(b,d,a.heap[e],a.depth));)a.heap[c]=a.heap[e], c=e,e<<=1;a.heap[c]=d}function s(a,b,c){var d,f,i,j,k=0;if(0!==a.last_lit)do d=a.pending_buf[a.d_buf+2*k]<<8|a.pending_buf[a.d_buf+2*k+1],f=a.pending_buf[a.l_buf+k],k++,0===d?h(a,f,b):(i=ha[f],h(a,i+P+1,b),j=_[i],0!==j&&(f-=ia[i],g(a,f,j)),d--,i=e(d),h(a,i,c),j=aa[i],0!==j&&(d-=ja[i],g(a,d,j)));while(k<a.last_lit);h(a,X,b)}function t(a,b){var c,d,e,f=b.dyn_tree,g=b.stat_desc.static_tree,h=b.stat_desc.has_stree,i=b.stat_desc.elems,j=-1;for(a.heap_len=0,a.heap_max=T,c=0;i>c;c++)0!==f[2*c]?(a.heap[++a.heap_len]=j=c,a.depth[c]=0):f[2*c+1]=0;for(;a.heap_len<2;)e=a.heap[++a.heap_len]=2>j?++j:0,f[2*e]=1,a.depth[e]=0,a.opt_len--,h&&(a.static_len-=g[2*e+1]);for(b.max_code=j,c=a.heap_len>>1;c>=1;c--)r(a,f,c);e=i;do c=a.heap[1],a.heap[1]=a.heap[a.heap_len--],r(a,f,1),d=a.heap[1],a.heap[--a.heap_max]=c,a.heap[--a.heap_max]=d,f[2*e]=f[2*c]+f[2*d],a.depth[e]=(a.depth[c]>=a.depth[d]?a.depth[c]:a.depth[d])+1,f[2*c+1]=f[2*d+1]=e,a.heap[1]=e++,r(a,f,1);while(a.heap_len>=2);a.heap[--a.heap_max]=a.heap[1],k(a,b),l(f,j,a.bl_count)}function u(a,b,c){var d,e,f=-1,g=b[1],h=0,i=7,j=4;for(0===g&&(i=138,j=3),b[2*(c+1)+1]=65535,d=0;c>=d;d++)e=g,g=b[2*(d+1)+1],++h<i&&e===g||(j>h?a.bl_tree[2*e]+=h:0!==e?(e!==f&&a.bl_tree[2*e]++,a.bl_tree[2*Y]++):10>=h?a.bl_tree[2*Z]++:a.bl_tree[2*$]++,h=0,f=e,0===g?(i=138,j=3):e===g?(i=6,j=3):(i=7,j=4))}function v(a,b,c){var d,e,f=-1,i=b[1],j=0,k=7,l=4;for(0===i&&(k=138,l=3),d=0;c>=d;d++)if(e=i,i=b[2*(d+1)+1],!(++j<k&&e===i)){if(l>j){do h(a,e,a.bl_tree);while(0!==--j)}else 0!==e?(e!==f&&(h(a,e,a.bl_tree),j--),h(a,Y,a.bl_tree),g(a,j-3,2)):10>=j?(h(a,Z,a.bl_tree),g(a,j-3,3)):(h(a,$,a.bl_tree),g(a,j-11,7));j=0,f=e,0===i?(k=138,l=3):e===i?(k=6,l=3):(k=7,l=4)}}function w(a){var b;for(u(a,a.dyn_ltree,a.l_desc.max_code),u(a,a.dyn_dtree,a.d_desc.max_code),t(a,a.bl_desc),b=S-1;b>=3&&0===a.bl_tree[2*ca[b]+1];b--);return a.opt_len+=3*(b+1)+5+5+4,b}function x(a,b,c,d){var e;for(g(a,b-257,5),g(a,c-1,5),g(a,d-4,4),e=0;d>e;e++)g(a,a.bl_tree[2*ca[e]+1],3);v(a,a.dyn_ltree,b-1),v(a,a.dyn_dtree,c-1)}function y(a){var b,c=4093624447;for(b=0;31>=b;b++,c>>>=1)if(1&c&&0!==a.dyn_ltree[2*b])return G;if(0!==a.dyn_ltree[18]||0!==a.dyn_ltree[20]||0!==a.dyn_ltree[26])return H;for(b=32;P>b;b++)if(0!==a.dyn_ltree[2*b])return H;return G}function z(a){pa||(m(),pa=!0),a.l_desc=new oa(a.dyn_ltree,ka),a.d_desc=new oa(a.dyn_dtree,la),a.bl_desc=new oa(a.bl_tree,ma),a.bi_buf=0,a.bi_valid=0,n(a)}function A(a,b,c,d){g(a,(J<<1)+(d?1:0),3),p(a,b,c,!0)}function B(a){g(a,K<<1,3),h(a,X,ea),j(a)}function C(a,b,c,d){var e,f,h=0;a.level>0?(a.strm.data_type===I&&(a.strm.data_type=y(a)),t(a,a.l_desc),t(a,a.d_desc),h=w(a),e=a.opt_len+3+7>>>3,f=a.static_len+3+7>>>3,e>=f&&(e=f)):e=f=c+5,e>=c+4&&-1!==b?A(a,b,c,d):a.strategy===F||f===e?(g(a,(K<<1)+(d?1:0),3),s(a,ea,fa)):(g(a,(L<<1)+(d?1:0),3),x(a,a.l_desc.max_code+1,a.d_desc.max_code+1,h+1),s(a,a.dyn_ltree,a.dyn_dtree)),n(a),d&&o(a)}function D(a,b,c){return a.pending_buf[a.d_buf+2*a.last_lit]=b>>>8&255,a.pending_buf[a.d_buf+2*a.last_lit+1]=255&b,a.pending_buf[a.l_buf+a.last_lit]=255&c,a.last_lit++,0===b?a.dyn_ltree[2*c]++:(a.matches++,b--,a.dyn_ltree[2*(ha[c]+P+1)]++,a.dyn_dtree[2*e(b)]++),a.last_lit===a.lit_bufsize-1}var E=a("../utils/common"),F=4,G=0,H=1,I=2,J=0,K=1,L=2,M=3,N=258,O=29,P=256,Q=P+1+O,R=30,S=19,T=2*Q+1,U=15,V=16,W=7,X=256,Y=16,Z=17,$=18,_=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],aa=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],ba=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],ca=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],da=512,ea=new Array(2*(Q+2));d(ea);var fa=new Array(2*R);d(fa);var ga=new Array(da);d(ga);var ha=new Array(N-M+1);d(ha);var ia=new Array(O);d(ia);var ja=new Array(R);d(ja);var ka,la,ma,na=function(a,b,c,d,e){this.static_tree=a,this.extra_bits=b,this.extra_base=c,this.elems=d,this.max_length=e,this.has_stree=a&&a.length},oa=function(a,b){this.dyn_tree=a,this.max_code=0,this.stat_desc=b},pa=!1;c._tr_init=z,c._tr_stored_block=A,c._tr_flush_block=C,c._tr_tally=D,c._tr_align=B},{"../utils/common":83}],95:[function(a,b,c){"use strict";function d(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}b.exports=d},{}]},{},[1]);
index.js
joelburget/d4
import React from 'react'; import ReactDOM from 'react-dom'; import {RadioGroup, Radio} from 'react-radio-group' import BarChart from './demo/bar'; import Delaunay from './demo/delaunay-color-mesh'; import DynamicBarChart from './demo/dynamic-bar'; import DynamicHexbin from './demo/dynamic-hexbin'; import PopulationChoropleth from './demo/population-choropleth'; import TileBoundingBox from './demo/tile-bounding-box'; import Voronoi from './demo/voronoi-color-mesh'; import Now from './demo/now'; import Markdown from './md'; const descriptions = { DynamicHexbin: ` Computing hexbins from a constantly-fluctuating sample of 2,000 random points. Compare [the original](https://bl.ocks.org/mbostock/7833311) to the [d4 version](https://github.com/joelburget/d4/blob/master/demo/dynamic-hexbin.js) `, PopulationChoropleth: ` A translation of [Population Choropleth](https://bl.ocks.org/mbostock/6320825) (shaded by population density) Compare [the original](https://bl.ocks.org/mbostock/6320825) to the [d4 version](https://github.com/joelburget/d4/blob/master/demo/population-choropleth.js) `, TileBoundingBox: ` A translation of [Tile by Bounding Box](https://bl.ocks.org/mbostock/eb0c48375fcdcdc00c54a92724733d0d) -- A demo of d3-tile when projecting to fit a bounding box. Compare [the original](https://bl.ocks.org/mbostock/eb0c48375fcdcdc00c54a92724733d0d) to the [d4 version](https://github.com/joelburget/d4/blob/master/demo/tile-bounding-box.js) `, Voronoi: ` A translation of [Color Mesh](https://bl.ocks.org/mbostock/99049112373e12709381) Compare [the original](https://bl.ocks.org/mbostock/99049112373e12709381) to the [d4 version](https://github.com/joelburget/d4/blob/master/demo/voronoi-color-mesh.js) `, Now: ` A translation of [Now + Solar Terminator](https://bl.ocks.org/mbostock/9232962) -- A south polar azimuthal equidistant projection, oriented so that noon is as 12 o'clock, as in [xkcd:1335](http://xkcd.com/1335/). The map updates continuously. Compare [the original](https://bl.ocks.org/mbostock/9232962) to the [d4 version](https://github.com/joelburget/d4/blob/master/demo/now.js) `, }; const componentMap = { // BarChart, // Delaunay, // DynamicBarChart, DynamicHexbin, PopulationChoropleth, TileBoundingBox, Voronoi, Now, }; class Demos extends React.Component { constructor() { super(); this.state = {selected: 'DynamicHexbin'}; this.handleChange = selected => this._handleChange(selected); } _handleChange(selected) { this.setState({selected}); } render() { return ( <div> <h2>Select Demo</h2> <RadioGroup className="demo-group" name="demo" selectedValue={this.state.selected} onChange={this.handleChange} > <label><Radio value="DynamicHexbin" /><span>dynamic hexbin</span></label> <label><Radio value="PopulationChoropleth" /><span>population choropleth</span></label> <label><Radio value="TileBoundingBox" /><span>tile bounding box</span></label> <label><Radio value="Voronoi" /><span>voronoi color mesh</span></label> <label><Radio value="Now" /><span>now + solar terminator</span></label> </RadioGroup> <Markdown source={descriptions[this.state.selected]} /> {React.createElement(componentMap[this.state.selected])} </div> ); } } ReactDOM.render(<Demos />, document.getElementById('inject'));
code/web/node_modules/react-bootstrap/es/NavbarHeader.js
zyxcambridge/RecordExistence
import _extends from 'babel-runtime/helpers/extends'; import _objectWithoutProperties from 'babel-runtime/helpers/objectWithoutProperties'; import _classCallCheck from 'babel-runtime/helpers/classCallCheck'; import _possibleConstructorReturn from 'babel-runtime/helpers/possibleConstructorReturn'; import _inherits from 'babel-runtime/helpers/inherits'; import classNames from 'classnames'; import React from 'react'; import { prefix } from './utils/bootstrapUtils'; var contextTypes = { $bs_navbar: React.PropTypes.shape({ bsClass: React.PropTypes.string }) }; var NavbarHeader = function (_React$Component) { _inherits(NavbarHeader, _React$Component); function NavbarHeader() { _classCallCheck(this, NavbarHeader); return _possibleConstructorReturn(this, _React$Component.apply(this, arguments)); } NavbarHeader.prototype.render = function render() { var _props = this.props; var className = _props.className; var props = _objectWithoutProperties(_props, ['className']); var navbarProps = this.context.$bs_navbar || { bsClass: 'navbar' }; var bsClassName = prefix(navbarProps, 'header'); return React.createElement('div', _extends({}, props, { className: classNames(className, bsClassName) })); }; return NavbarHeader; }(React.Component); NavbarHeader.contextTypes = contextTypes; export default NavbarHeader;
client2/src/components/react-burger-menu/test/stack.spec.js
ibulmer/Board
'use strict'; import React from 'react'; import TestUtils from 'react-addons-test-utils'; import { expect } from 'chai'; import createShallowComponent from './utils/createShallowComponent'; import BurgerMenu from '../lib/BurgerMenu'; const Menu = BurgerMenu.stack; describe('stack', () => { let component, menuWrap, menu, itemList, firstItem; beforeEach(() => { component = createShallowComponent(<Menu><div>An item</div></Menu>); menuWrap = component.props.children[1]; }); it('has correct menuWrap styles', () => { expect(menuWrap.props.style.position).to.equal('fixed'); expect(menuWrap.props.style.zIndex).to.equal(2); expect(menuWrap.props.style.width).to.equal(300); expect(menuWrap.props.style.height).to.equal('100%'); }); it('has correct menu styles', () => { component = TestUtils.renderIntoDocument(<Menu><div>An item</div></Menu>); menu = TestUtils.findRenderedDOMComponentWithClass(component, 'bm-menu'); expect(menu.style.height).to.equal('100%'); expect(menu.style.boxSizing).to.equal('border-box'); }); it('has correct itemList styles', () => { component = TestUtils.renderIntoDocument(<Menu pageWrapId={ 'page-wrap' } outerContainerId={ 'outer-container' }><div>An item</div></Menu>); itemList = TestUtils.findRenderedDOMComponentWithClass(component, 'bm-item-list'); expect(itemList.style.height).to.equal('100%'); }); it('has correct item styles', () => { component = TestUtils.renderIntoDocument(<Menu><div>An item</div></Menu>); firstItem = TestUtils.findRenderedDOMComponentWithClass(component, 'bm-item-list').children[0]; expect(firstItem.style.display).to.equal('block'); expect(firstItem.style.outline).to.equal('none'); }); it('can be positioned on the right', () => { component = TestUtils.renderIntoDocument(<Menu right><div>An item</div></Menu>); menuWrap = TestUtils.findRenderedDOMComponentWithClass(component, 'bm-menu-wrap'); expect(menuWrap.style.right).to.equal('0px'); }); });
src/svg-icons/action/face.js
lawrence-yu/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ActionFace = (props) => ( <SvgIcon {...props}> <path d="M9 11.75c-.69 0-1.25.56-1.25 1.25s.56 1.25 1.25 1.25 1.25-.56 1.25-1.25-.56-1.25-1.25-1.25zm6 0c-.69 0-1.25.56-1.25 1.25s.56 1.25 1.25 1.25 1.25-.56 1.25-1.25-.56-1.25-1.25-1.25zM12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8 0-.29.02-.58.05-.86 2.36-1.05 4.23-2.98 5.21-5.37C11.07 8.33 14.05 10 17.42 10c.78 0 1.53-.09 2.25-.26.21.71.33 1.47.33 2.26 0 4.41-3.59 8-8 8z"/> </SvgIcon> ); ActionFace = pure(ActionFace); ActionFace.displayName = 'ActionFace'; ActionFace.muiName = 'SvgIcon'; export default ActionFace;
ajax/libs/6to5/3.3.4/browser-polyfill.js
sympmarc/cdnjs
(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){(function(global){"use strict";if(global._6to5Polyfill){throw new Error("only one instance of 6to5/polyfill is allowed")}global._6to5Polyfill=true;require("core-js/shim");require("regenerator-6to5/runtime")}).call(this,typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{})},{"core-js/shim":2,"regenerator-6to5/runtime":3}],2:[function(require,module,exports){!function(global,framework,undefined){"use strict";var OBJECT="Object",FUNCTION="Function",ARRAY="Array",STRING="String",NUMBER="Number",REGEXP="RegExp",DATE="Date",MAP="Map",SET="Set",WEAKMAP="WeakMap",WEAKSET="WeakSet",SYMBOL="Symbol",PROMISE="Promise",MATH="Math",ARGUMENTS="Arguments",PROTOTYPE="prototype",CONSTRUCTOR="constructor",TO_STRING="toString",TO_STRING_TAG=TO_STRING+"Tag",TO_LOCALE="toLocaleString",HAS_OWN="hasOwnProperty",FOR_EACH="forEach",ITERATOR="iterator",FF_ITERATOR="@@"+ITERATOR,PROCESS="process",CREATE_ELEMENT="createElement",Function=global[FUNCTION],Object=global[OBJECT],Array=global[ARRAY],String=global[STRING],Number=global[NUMBER],RegExp=global[REGEXP],Date=global[DATE],Map=global[MAP],Set=global[SET],WeakMap=global[WEAKMAP],WeakSet=global[WEAKSET],Symbol=global[SYMBOL],Math=global[MATH],TypeError=global.TypeError,setTimeout=global.setTimeout,setImmediate=global.setImmediate,clearImmediate=global.clearImmediate,process=global[PROCESS],nextTick=process&&process.nextTick,document=global.document,html=document&&document.documentElement,navigator=global.navigator,define=global.define,ArrayProto=Array[PROTOTYPE],ObjectProto=Object[PROTOTYPE],FunctionProto=Function[PROTOTYPE],Infinity=1/0,DOT=".";function isObject(it){return it!=null&&(typeof it=="object"||typeof it=="function")}function isFunction(it){return typeof it=="function"}var isNative=ctx(/./.test,/\[native code\]\s*\}\s*$/,1);var buildIn={Undefined:1,Null:1,Array:1,String:1,Arguments:1,Function:1,Error:1,Boolean:1,Number:1,Date:1,RegExp:1},toString=ObjectProto[TO_STRING];function setToStringTag(it,tag,stat){if(it&&!has(it=stat?it:it[PROTOTYPE],SYMBOL_TAG))hidden(it,SYMBOL_TAG,tag)}function cof(it){return it==undefined?it===undefined?"Undefined":"Null":toString.call(it).slice(8,-1)}function classof(it){var klass=cof(it),tag;return klass==OBJECT&&(tag=it[SYMBOL_TAG])?has(buildIn,tag)?"~"+tag:tag:klass}var call=FunctionProto.call,apply=FunctionProto.apply,REFERENCE_GET;function part(){var fn=assertFunction(this),length=arguments.length,args=Array(length),i=0,_=path._,holder=false;while(length>i)if((args[i]=arguments[i++])===_)holder=true;return function(){var that=this,_length=arguments.length,i=0,j=0,_args;if(!holder&&!_length)return invoke(fn,args,that);_args=args.slice();if(holder)for(;length>i;i++)if(_args[i]===_)_args[i]=arguments[j++];while(_length>j)_args.push(arguments[j++]);return invoke(fn,_args,that)}}function ctx(fn,that,length){assertFunction(fn);if(~length&&that===undefined)return fn;switch(length){case 1:return function(a){return fn.call(that,a)};case 2:return function(a,b){return fn.call(that,a,b)};case 3:return function(a,b,c){return fn.call(that,a,b,c)}}return function(){return fn.apply(that,arguments)}}function invoke(fn,args,that){var un=that===undefined;switch(args.length|0){case 0:return un?fn():fn.call(that);case 1:return un?fn(args[0]):fn.call(that,args[0]);case 2:return un?fn(args[0],args[1]):fn.call(that,args[0],args[1]);case 3:return un?fn(args[0],args[1],args[2]):fn.call(that,args[0],args[1],args[2]);case 4:return un?fn(args[0],args[1],args[2],args[3]):fn.call(that,args[0],args[1],args[2],args[3]);case 5:return un?fn(args[0],args[1],args[2],args[3],args[4]):fn.call(that,args[0],args[1],args[2],args[3],args[4])}return fn.apply(that,args)}function construct(target,argumentsList){var proto=assertFunction(arguments.length<3?target:arguments[2])[PROTOTYPE],instance=create(isObject(proto)?proto:ObjectProto),result=apply.call(target,instance,argumentsList);return isObject(result)?result:instance}var create=Object.create,getPrototypeOf=Object.getPrototypeOf,setPrototypeOf=Object.setPrototypeOf,defineProperty=Object.defineProperty,defineProperties=Object.defineProperties,getOwnDescriptor=Object.getOwnPropertyDescriptor,getKeys=Object.keys,getNames=Object.getOwnPropertyNames,getSymbols=Object.getOwnPropertySymbols,isFrozen=Object.isFrozen,has=ctx(call,ObjectProto[HAS_OWN],2),ES5Object=Object,Dict;function toObject(it){return ES5Object(assertDefined(it))}function returnIt(it){return it}function returnThis(){return this}function get(object,key){if(has(object,key))return object[key]}function ownKeys(it){assertObject(it);return getSymbols?getNames(it).concat(getSymbols(it)):getNames(it)}var assign=Object.assign||function(target,source){var T=Object(assertDefined(target)),l=arguments.length,i=1;while(l>i){var S=ES5Object(arguments[i++]),keys=getKeys(S),length=keys.length,j=0,key;while(length>j)T[key=keys[j++]]=S[key]}return T};function keyOf(object,el){var O=toObject(object),keys=getKeys(O),length=keys.length,index=0,key;while(length>index)if(O[key=keys[index++]]===el)return key}function array(it){return String(it).split(",")}var push=ArrayProto.push,unshift=ArrayProto.unshift,slice=ArrayProto.slice,splice=ArrayProto.splice,indexOf=ArrayProto.indexOf,forEach=ArrayProto[FOR_EACH];function createArrayMethod(type){var isMap=type==1,isFilter=type==2,isSome=type==3,isEvery=type==4,isFindIndex=type==6,noholes=type==5||isFindIndex;return function(callbackfn){var O=Object(assertDefined(this)),that=arguments[1],self=ES5Object(O),f=ctx(callbackfn,that,3),length=toLength(self.length),index=0,result=isMap?Array(length):isFilter?[]:undefined,val,res;for(;length>index;index++)if(noholes||index in self){val=self[index];res=f(val,index,O);if(type){if(isMap)result[index]=res;else if(res)switch(type){case 3:return true;case 5:return val;case 6:return index;case 2:result.push(val)}else if(isEvery)return false}}return isFindIndex?-1:isSome||isEvery?isEvery:result}}function createArrayContains(isContains){return function(el){var O=toObject(this),length=toLength(O.length),index=toIndex(arguments[1],length);if(isContains&&el!=el){for(;length>index;index++)if(sameNaN(O[index]))return isContains||index}else for(;length>index;index++)if(isContains||index in O){if(O[index]===el)return isContains||index}return!isContains&&-1}}function generic(A,B){return typeof A=="function"?A:B}var MAX_SAFE_INTEGER=9007199254740991,ceil=Math.ceil,floor=Math.floor,max=Math.max,min=Math.min,random=Math.random,trunc=Math.trunc||function(it){return(it>0?floor:ceil)(it)};function sameNaN(number){return number!=number}function toInteger(it){return isNaN(it)?0:trunc(it)}function toLength(it){return it>0?min(toInteger(it),MAX_SAFE_INTEGER):0}function toIndex(index,length){var index=toInteger(index);return index<0?max(index+length,0):min(index,length)}function createReplacer(regExp,replace,isStatic){var replacer=isObject(replace)?function(part){return replace[part]}:replace;return function(it){return String(isStatic?it:this).replace(regExp,replacer)}}function createPointAt(toString){return function(pos){var s=String(assertDefined(this)),i=toInteger(pos),l=s.length,a,b;if(i<0||i>=l)return toString?"":undefined;a=s.charCodeAt(i);return a<55296||a>56319||i+1===l||(b=s.charCodeAt(i+1))<56320||b>57343?toString?s.charAt(i):a:toString?s.slice(i,i+2):(a-55296<<10)+(b-56320)+65536}}var REDUCE_ERROR="Reduce of empty object with no initial value";function assert(condition,msg1,msg2){if(!condition)throw TypeError(msg2?msg1+msg2:msg1)}function assertDefined(it){if(it==undefined)throw TypeError("Function called on null or undefined");return it}function assertFunction(it){assert(isFunction(it),it," is not a function!");return it}function assertObject(it){assert(isObject(it),it," is not an object!");return it}function assertInstance(it,Constructor,name){assert(it instanceof Constructor,name,": use the 'new' operator!")}function descriptor(bitmap,value){return{enumerable:!(bitmap&1),configurable:!(bitmap&2),writable:!(bitmap&4),value:value}}function simpleSet(object,key,value){object[key]=value;return object}function createDefiner(bitmap){return DESC?function(object,key,value){return defineProperty(object,key,descriptor(bitmap,value))}:simpleSet}function uid(key){return SYMBOL+"("+key+")_"+(++sid+random())[TO_STRING](36)}function getWellKnownSymbol(name,setter){return Symbol&&Symbol[name]||(setter?Symbol:safeSymbol)(SYMBOL+DOT+name)}var DESC=!!function(){try{return defineProperty({},DOT,ObjectProto)}catch(e){}}(),sid=0,hidden=createDefiner(1),set=Symbol?simpleSet:hidden,safeSymbol=Symbol||uid;function assignHidden(target,src){for(var key in src)hidden(target,key,src[key]);return target}var SYMBOL_UNSCOPABLES=getWellKnownSymbol("unscopables"),ArrayUnscopables=ArrayProto[SYMBOL_UNSCOPABLES]||{},SYMBOL_SPECIES=getWellKnownSymbol("species");function setSpecies(C){if(framework||!isNative(C))defineProperty(C,SYMBOL_SPECIES,{configurable:true,get:returnThis})}var SYMBOL_ITERATOR=getWellKnownSymbol(ITERATOR),SYMBOL_TAG=getWellKnownSymbol(TO_STRING_TAG),SUPPORT_FF_ITER=FF_ITERATOR in ArrayProto,ITER=safeSymbol("iter"),KEY=1,VALUE=2,Iterators={},IteratorPrototype={},NATIVE_ITERATORS=SYMBOL_ITERATOR in ArrayProto,BUGGY_ITERATORS="keys"in ArrayProto&&!("next"in[].keys());setIterator(IteratorPrototype,returnThis);function setIterator(O,value){hidden(O,SYMBOL_ITERATOR,value);SUPPORT_FF_ITER&&hidden(O,FF_ITERATOR,value)}function createIterator(Constructor,NAME,next,proto){Constructor[PROTOTYPE]=create(proto||IteratorPrototype,{next:descriptor(1,next)});setToStringTag(Constructor,NAME+" Iterator")}function defineIterator(Constructor,NAME,value,DEFAULT){var proto=Constructor[PROTOTYPE],iter=get(proto,SYMBOL_ITERATOR)||get(proto,FF_ITERATOR)||DEFAULT&&get(proto,DEFAULT)||value;if(framework){setIterator(proto,iter);if(iter!==value){var iterProto=getPrototypeOf(iter.call(new Constructor));setToStringTag(iterProto,NAME+" Iterator",true);has(proto,FF_ITERATOR)&&setIterator(iterProto,returnThis)}}Iterators[NAME]=iter;Iterators[NAME+" Iterator"]=returnThis;return iter}function defineStdIterators(Base,NAME,Constructor,next,DEFAULT,IS_SET){function createIter(kind){return function(){return new Constructor(this,kind)}}createIterator(Constructor,NAME,next);var entries=createIter(KEY+VALUE),values=createIter(VALUE);if(DEFAULT==VALUE)values=defineIterator(Base,NAME,values,"values");else entries=defineIterator(Base,NAME,entries,"entries");if(DEFAULT){$define(PROTO+FORCED*BUGGY_ITERATORS,NAME,{entries:entries,keys:IS_SET?values:createIter(KEY),values:values})}}function iterResult(done,value){return{value:value,done:!!done}}function isIterable(it){var O=Object(it),Symbol=global[SYMBOL],hasExt=(Symbol&&Symbol[ITERATOR]||FF_ITERATOR)in O;return hasExt||SYMBOL_ITERATOR in O||has(Iterators,classof(O))}function getIterator(it){var Symbol=global[SYMBOL],ext=it[Symbol&&Symbol[ITERATOR]||FF_ITERATOR],getIter=ext||it[SYMBOL_ITERATOR]||Iterators[classof(it)];return assertObject(getIter.call(it))}function stepCall(fn,value,entries){return entries?invoke(fn,value):fn(value)}function forOf(iterable,entries,fn,that){var iterator=getIterator(iterable),f=ctx(fn,that,entries?2:1),step;while(!(step=iterator.next()).done)if(stepCall(f,step.value,entries)===false)return}var NODE=cof(process)==PROCESS,core={},path=framework?global:core,old=global.core,exportGlobal,FORCED=1,GLOBAL=2,STATIC=4,PROTO=8,BIND=16,WRAP=32;function $define(type,name,source){var key,own,out,exp,isGlobal=type&GLOBAL,target=isGlobal?global:type&STATIC?global[name]:(global[name]||ObjectProto)[PROTOTYPE],exports=isGlobal?core:core[name]||(core[name]={});if(isGlobal)source=name;for(key in source){own=!(type&FORCED)&&target&&key in target&&(!isFunction(target[key])||isNative(target[key]));out=(own?target:source)[key];if(type&BIND&&own)exp=ctx(out,global);else if(type&WRAP&&!framework&&target[key]==out){exp=function(param){return this instanceof out?new out(param):out(param)};exp[PROTOTYPE]=out[PROTOTYPE]}else exp=type&PROTO&&isFunction(out)?ctx(call,out):out;if(exports[key]!=out)hidden(exports,key,exp);if(framework&&target&&!own){if(isGlobal)target[key]=out;else delete target[key]&&hidden(target,key,out)}}}if(typeof module!="undefined"&&module.exports)module.exports=core;else if(isFunction(define)&&define.amd)define(function(){return core});else exportGlobal=true;if(exportGlobal||framework){core.noConflict=function(){global.core=old;return core};global.core=core}$define(GLOBAL+FORCED,{global:global});!function(TAG,SymbolRegistry,AllSymbols,setter){if(!isNative(Symbol)){Symbol=function(description){assert(!(this instanceof Symbol),SYMBOL+" is not a "+CONSTRUCTOR);var tag=uid(description);AllSymbols[tag]=true;DESC&&setter&&defineProperty(ObjectProto,tag,{configurable:true,set:function(value){hidden(this,tag,value)}});return set(create(Symbol[PROTOTYPE]),TAG,tag)};hidden(Symbol[PROTOTYPE],TO_STRING,function(){return this[TAG]})}$define(GLOBAL+WRAP,{Symbol:Symbol});var symbolStatics={"for":function(key){return has(SymbolRegistry,key+="")?SymbolRegistry[key]:SymbolRegistry[key]=Symbol(key)},iterator:SYMBOL_ITERATOR,keyFor:part.call(keyOf,SymbolRegistry),species:SYMBOL_SPECIES,toStringTag:SYMBOL_TAG=getWellKnownSymbol(TO_STRING_TAG,true),unscopables:SYMBOL_UNSCOPABLES,pure:safeSymbol,set:set,useSetter:function(){setter=true},useSimple:function(){setter=false}};forEach.call(array("hasInstance,isConcatSpreadable,match,replace,search,split,toPrimitive"),function(it){symbolStatics[it]=getWellKnownSymbol(it)});$define(STATIC,SYMBOL,symbolStatics);setToStringTag(Symbol,SYMBOL);$define(STATIC+FORCED*!isNative(Symbol),OBJECT,{getOwnPropertyNames:function(it){var names=getNames(toObject(it)),result=[],key,i=0;while(names.length>i)has(AllSymbols,key=names[i++])||result.push(key);return result},getOwnPropertySymbols:function(it){var names=getNames(toObject(it)),result=[],key,i=0;while(names.length>i)has(AllSymbols,key=names[i++])&&result.push(key);return result}})}(safeSymbol("tag"),{},{},true);!function(RegExpProto,isFinite,tmp,NAME){var RangeError=global.RangeError,isInteger=Number.isInteger||function(it){return!isObject(it)&&isFinite(it)&&floor(it)===it},sign=Math.sign||function sign(x){return(x=+x)==0||x!=x?x:x<0?-1:1},E=Math.E,pow=Math.pow,abs=Math.abs,exp=Math.exp,log=Math.log,sqrt=Math.sqrt,fcc=String.fromCharCode,at=createPointAt(true);var objectStatic={assign:assign,is:function(x,y){return x===y?x!==0||1/x===1/y:x!=x&&y!=y}};"__proto__"in ObjectProto&&function(buggy,set){try{set=ctx(call,getOwnDescriptor(ObjectProto,"__proto__").set,2);set({},ArrayProto)}catch(e){buggy=true}objectStatic.setPrototypeOf=setPrototypeOf=setPrototypeOf||function(O,proto){assertObject(O);assert(proto===null||isObject(proto),proto,": can't set as prototype!");if(buggy)O.__proto__=proto;else set(O,proto);return O}}();$define(STATIC,OBJECT,objectStatic);function asinh(x){return!isFinite(x=+x)||x==0?x:x<0?-asinh(-x):log(x+sqrt(x*x+1))}function expm1(x){return(x=+x)==0?x:x>-1e-6&&x<1e-6?x+x*x/2:exp(x)-1}$define(STATIC,NUMBER,{EPSILON:pow(2,-52),isFinite:function(it){return typeof it=="number"&&isFinite(it)},isInteger:isInteger,isNaN:sameNaN,isSafeInteger:function(number){return isInteger(number)&&abs(number)<=MAX_SAFE_INTEGER},MAX_SAFE_INTEGER:MAX_SAFE_INTEGER,MIN_SAFE_INTEGER:-MAX_SAFE_INTEGER,parseFloat:parseFloat,parseInt:parseInt});$define(STATIC,MATH,{acosh:function(x){return(x=+x)<1?NaN:isFinite(x)?log(x/E+sqrt(x+1)*sqrt(x-1)/E)+1:x},asinh:asinh,atanh:function(x){return(x=+x)==0?x:log((1+x)/(1-x))/2},cbrt:function(x){return sign(x=+x)*pow(abs(x),1/3)},clz32:function(x){return(x>>>=0)?32-x[TO_STRING](2).length:32},cosh:function(x){return(exp(x=+x)+exp(-x))/2},expm1:expm1,fround:function(x){return new Float32Array([x])[0]},hypot:function(value1,value2){var sum=0,len1=arguments.length,len2=len1,args=Array(len1),larg=-Infinity,arg;while(len1--){arg=args[len1]=+arguments[len1];if(arg==Infinity||arg==-Infinity)return Infinity;if(arg>larg)larg=arg}larg=arg||1;while(len2--)sum+=pow(args[len2]/larg,2);return larg*sqrt(sum)},imul:function(x,y){var UInt16=65535,xn=+x,yn=+y,xl=UInt16&xn,yl=UInt16&yn;return 0|xl*yl+((UInt16&xn>>>16)*yl+xl*(UInt16&yn>>>16)<<16>>>0)},log1p:function(x){return(x=+x)>-1e-8&&x<1e-8?x-x*x/2:log(1+x)},log10:function(x){return log(x)/Math.LN10},log2:function(x){return log(x)/Math.LN2},sign:sign,sinh:function(x){return abs(x=+x)<1?(expm1(x)-expm1(-x))/2:(exp(x-1)-exp(-x-1))*(E/2)},tanh:function(x){var a=expm1(x=+x),b=expm1(-x);return a==Infinity?1:b==Infinity?-1:(a-b)/(exp(x)+exp(-x))},trunc:trunc});setToStringTag(Math,MATH,true);function assertNotRegExp(it){if(cof(it)==REGEXP)throw TypeError()}$define(STATIC,STRING,{fromCodePoint:function(x){var res=[],len=arguments.length,i=0,code;while(len>i){code=+arguments[i++];if(toIndex(code,1114111)!==code)throw RangeError(code+" is not a valid code point");res.push(code<65536?fcc(code):fcc(((code-=65536)>>10)+55296,code%1024+56320))}return res.join("")},raw:function(callSite){var raw=toObject(callSite.raw),len=toLength(raw.length),sln=arguments.length,res=[],i=0;while(len>i){res.push(String(raw[i++]));if(i<sln)res.push(String(arguments[i]))}return res.join("")}});$define(PROTO,STRING,{codePointAt:createPointAt(false),endsWith:function(searchString){assertNotRegExp(searchString);var that=String(assertDefined(this)),endPosition=arguments[1],len=toLength(that.length),end=endPosition===undefined?len:min(toLength(endPosition),len);searchString+="";return that.slice(end-searchString.length,end)===searchString},includes:function(searchString){assertNotRegExp(searchString);return!!~String(assertDefined(this)).indexOf(searchString,arguments[1])},repeat:function(count){var str=String(assertDefined(this)),res="",n=toInteger(count);if(0>n||n==Infinity)throw RangeError("Count can't be negative");for(;n>0;(n>>>=1)&&(str+=str))if(n&1)res+=str;return res},startsWith:function(searchString){assertNotRegExp(searchString);var that=String(assertDefined(this)),index=toLength(min(arguments[1],that.length));searchString+="";return that.slice(index,index+searchString.length)===searchString}});defineStdIterators(String,STRING,function(iterated){set(this,ITER,{o:String(iterated),i:0})},function(){var iter=this[ITER],O=iter.o,index=iter.i,point;if(index>=O.length)return iterResult(1);point=at.call(O,index);iter.i+=point.length;return iterResult(0,point)});$define(STATIC,ARRAY,{from:function(arrayLike){var O=Object(assertDefined(arrayLike)),result=new(generic(this,Array)),mapfn=arguments[1],that=arguments[2],mapping=mapfn!==undefined,f=mapping?ctx(mapfn,that,2):undefined,index=0,length;if(isIterable(O))for(var iter=getIterator(O),step;!(step=iter.next()).done;index++){result[index]=mapping?f(step.value,index):step.value}else for(length=toLength(O.length);length>index;index++){result[index]=mapping?f(O[index],index):O[index]}result.length=index;return result},of:function(){var index=0,length=arguments.length,result=new(generic(this,Array))(length);while(length>index)result[index]=arguments[index++];result.length=length;return result}});$define(PROTO,ARRAY,{copyWithin:function(target,start){var O=Object(assertDefined(this)),len=toLength(O.length),to=toIndex(target,len),from=toIndex(start,len),end=arguments[2],fin=end===undefined?len:toIndex(end,len),count=min(fin-from,len-to),inc=1;if(from<to&&to<from+count){inc=-1;from=from+count-1;to=to+count-1}while(count-->0){if(from in O)O[to]=O[from];else delete O[to];to+=inc;from+=inc}return O},fill:function(value){var O=Object(assertDefined(this)),length=toLength(O.length),index=toIndex(arguments[1],length),end=arguments[2],endPos=end===undefined?length:toIndex(end,length);while(endPos>index)O[index++]=value;return O},find:createArrayMethod(5),findIndex:createArrayMethod(6)});defineStdIterators(Array,ARRAY,function(iterated,kind){set(this,ITER,{o:toObject(iterated),i:0,k:kind})},function(){var iter=this[ITER],O=iter.o,kind=iter.k,index=iter.i++;if(!O||index>=O.length)return iter.o=undefined,iterResult(1);if(kind==KEY)return iterResult(0,index);if(kind==VALUE)return iterResult(0,O[index]);return iterResult(0,[index,O[index]])},VALUE);Iterators[ARGUMENTS]=Iterators[ARRAY];setToStringTag(global.JSON,"JSON",true);function wrapObjectMethod(key,MODE){var fn=Object[key],exp=core[OBJECT][key],f=0,o={};if(!exp||isNative(exp)){o[key]=MODE==1?function(it){return isObject(it)?fn(it):it}:MODE==2?function(it){return isObject(it)?fn(it):true}:MODE==3?function(it){return isObject(it)?fn(it):false}:MODE==4?function(it,key){return fn(toObject(it),key)}:function(it){return fn(toObject(it))};try{fn(DOT)}catch(e){f=1}$define(STATIC+FORCED*f,OBJECT,o)}}wrapObjectMethod("freeze",1);wrapObjectMethod("seal",1);wrapObjectMethod("preventExtensions",1);wrapObjectMethod("isFrozen",2);wrapObjectMethod("isSealed",2);wrapObjectMethod("isExtensible",3);wrapObjectMethod("getOwnPropertyDescriptor",4);wrapObjectMethod("getPrototypeOf");wrapObjectMethod("keys");wrapObjectMethod("getOwnPropertyNames");if(framework){tmp[SYMBOL_TAG]=DOT;if(cof(tmp)!=DOT)hidden(ObjectProto,TO_STRING,function(){return"[object "+classof(this)+"]"});NAME in FunctionProto||defineProperty(FunctionProto,NAME,{configurable:true,get:function(){var match=String(this).match(/^\s*function ([^ (]*)/),name=match?match[1]:"";has(this,NAME)||defineProperty(this,NAME,descriptor(5,name));return name},set:function(value){has(this,NAME)||defineProperty(this,NAME,descriptor(0,value))}});if(DESC&&!function(){try{return RegExp(/a/g,"i")=="/a/i"}catch(e){}}()){var _RegExp=RegExp;RegExp=function RegExp(pattern,flags){return new _RegExp(cof(pattern)==REGEXP&&flags!==undefined?pattern.source:pattern,flags)};forEach.call(getNames(_RegExp),function(key){key in RegExp||defineProperty(RegExp,key,{configurable:true,get:function(){return _RegExp[key]},set:function(it){_RegExp[key]=it}})});RegExpProto[CONSTRUCTOR]=RegExp;RegExp[PROTOTYPE]=RegExpProto;hidden(global,REGEXP,RegExp)}if(/./g.flags!="g")defineProperty(RegExpProto,"flags",{configurable:true,get:createReplacer(/^.*\/(\w*)$/,"$1")});forEach.call(array("find,findIndex,fill,copyWithin,entries,keys,values"),function(it){ArrayUnscopables[it]=true});SYMBOL_UNSCOPABLES in ArrayProto||hidden(ArrayProto,SYMBOL_UNSCOPABLES,ArrayUnscopables)}setSpecies(RegExp);setSpecies(Array)}(RegExp[PROTOTYPE],isFinite,{},"name");isFunction(setImmediate)&&isFunction(clearImmediate)||function(ONREADYSTATECHANGE){var postMessage=global.postMessage,addEventListener=global.addEventListener,MessageChannel=global.MessageChannel,counter=0,queue={},defer,channel,port;setImmediate=function(fn){var args=[],i=1;while(arguments.length>i)args.push(arguments[i++]);queue[++counter]=function(){invoke(isFunction(fn)?fn:Function(fn),args)};defer(counter);return counter};clearImmediate=function(id){delete queue[id]};function run(id){if(has(queue,id)){var fn=queue[id];delete queue[id];fn()}}function listner(event){run(event.data)}if(NODE){defer=function(id){nextTick(part.call(run,id))}}else if(addEventListener&&isFunction(postMessage)&&!global.importScripts){defer=function(id){postMessage(id,"*")};addEventListener("message",listner,false)}else if(isFunction(MessageChannel)){channel=new MessageChannel;port=channel.port2;channel.port1.onmessage=listner;defer=ctx(port.postMessage,port,1)}else if(document&&ONREADYSTATECHANGE in document[CREATE_ELEMENT]("script")){defer=function(id){html.appendChild(document[CREATE_ELEMENT]("script"))[ONREADYSTATECHANGE]=function(){html.removeChild(this);run(id)}}}else{defer=function(id){setTimeout(part.call(run,id),0)}}}("onreadystatechange");$define(GLOBAL+BIND,{setImmediate:setImmediate,clearImmediate:clearImmediate});!function(Promise,test){isFunction(Promise)&&isFunction(Promise.resolve)&&Promise.resolve(test=new Promise(function(){}))==test||function(asap,DEF){function isThenable(o){var then;if(isObject(o))then=o.then;return isFunction(then)?then:false}function notify(def){var chain=def.chain;chain.length&&asap(function(){var msg=def.msg,ok=def.state==1,i=0;while(chain.length>i)!function(react){var cb=ok?react.ok:react.fail,ret,then;try{if(cb){ret=cb===true?msg:cb(msg);if(ret===react.P){react.rej(TypeError(PROMISE+"-chain cycle"))}else if(then=isThenable(ret)){then.call(ret,react.res,react.rej)}else react.res(ret)}else react.rej(msg)}catch(err){react.rej(err)}}(chain[i++]);chain.length=0})}function resolve(msg){var def=this,then,wrapper;if(def.done)return;def.done=true;def=def.def||def;try{if(then=isThenable(msg)){wrapper={def:def,done:false};then.call(msg,ctx(resolve,wrapper,1),ctx(reject,wrapper,1))}else{def.msg=msg;def.state=1;notify(def)}}catch(err){reject.call(wrapper||{def:def,done:false},err)}}function reject(msg){var def=this;if(def.done)return;def.done=true;def=def.def||def;def.msg=msg;def.state=2;notify(def)}function getConstructor(C){var S=assertObject(C)[SYMBOL_SPECIES];return S!=undefined?S:C}Promise=function(executor){assertFunction(executor);assertInstance(this,Promise,PROMISE);var def={chain:[],state:0,done:false,msg:undefined};hidden(this,DEF,def);try{executor(ctx(resolve,def,1),ctx(reject,def,1))}catch(err){reject.call(def,err)}};assignHidden(Promise[PROTOTYPE],{then:function(onFulfilled,onRejected){var S=assertObject(assertObject(this)[CONSTRUCTOR])[SYMBOL_SPECIES];var react={ok:isFunction(onFulfilled)?onFulfilled:true,fail:isFunction(onRejected)?onRejected:false},P=react.P=new(S!=undefined?S:Promise)(function(resolve,reject){react.res=assertFunction(resolve);react.rej=assertFunction(reject)}),def=this[DEF];def.chain.push(react);def.state&&notify(def);return P},"catch":function(onRejected){return this.then(undefined,onRejected)}});assignHidden(Promise,{all:function(iterable){var Promise=getConstructor(this),values=[];return new Promise(function(resolve,reject){forOf(iterable,false,push,values);var remaining=values.length,results=Array(remaining);if(remaining)forEach.call(values,function(promise,index){Promise.resolve(promise).then(function(value){results[index]=value;--remaining||resolve(results)},reject)});else resolve(results)})},race:function(iterable){var Promise=getConstructor(this);return new Promise(function(resolve,reject){forOf(iterable,false,function(promise){Promise.resolve(promise).then(resolve,reject)})})},reject:function(r){return new(getConstructor(this))(function(resolve,reject){reject(r)})},resolve:function(x){return isObject(x)&&DEF in x&&getPrototypeOf(x)===this[PROTOTYPE]?x:new(getConstructor(this))(function(resolve,reject){resolve(x)})}})}(nextTick||setImmediate,safeSymbol("def"));setToStringTag(Promise,PROMISE);setSpecies(Promise);$define(GLOBAL+FORCED*!isNative(Promise),{Promise:Promise})}(global[PROMISE]);!function(){var UID=safeSymbol("uid"),O1=safeSymbol("O1"),WEAK=safeSymbol("weak"),LEAK=safeSymbol("leak"),LAST=safeSymbol("last"),FIRST=safeSymbol("first"),SIZE=DESC?safeSymbol("size"):"size",uid=0,tmp={};function getCollection(C,NAME,methods,commonMethods,isMap,isWeak){var ADDER=isMap?"set":"add",proto=C&&C[PROTOTYPE],O={};function initFromIterable(that,iterable){if(iterable!=undefined)forOf(iterable,isMap,that[ADDER],that);return that}function fixSVZ(key,chain){var method=proto[key];if(framework)proto[key]=function(a,b){var result=method.call(this,a===0?0:a,b);return chain?this:result}}if(!isNative(C)||!(isWeak||!BUGGY_ITERATORS&&has(proto,FOR_EACH)&&has(proto,"entries"))){C=isWeak?function(iterable){assertInstance(this,C,NAME);set(this,UID,uid++);initFromIterable(this,iterable)}:function(iterable){var that=this;assertInstance(that,C,NAME);set(that,O1,create(null));set(that,SIZE,0);set(that,LAST,undefined);set(that,FIRST,undefined);initFromIterable(that,iterable)};assignHidden(assignHidden(C[PROTOTYPE],methods),commonMethods);isWeak||defineProperty(C[PROTOTYPE],"size",{get:function(){return assertDefined(this[SIZE])}})}else{var Native=C,inst=new C,chain=inst[ADDER](isWeak?{}:-0,1),buggyZero;if(!NATIVE_ITERATORS||!C.length){C=function(iterable){assertInstance(this,C,NAME);return initFromIterable(new Native,iterable)};C[PROTOTYPE]=proto;if(framework)proto[CONSTRUCTOR]=C}isWeak||inst[FOR_EACH](function(val,key){buggyZero=1/key===-Infinity});if(buggyZero){fixSVZ("delete");fixSVZ("has");isMap&&fixSVZ("get")}if(buggyZero||chain!==inst)fixSVZ(ADDER,true)}setToStringTag(C,NAME);setSpecies(C);O[NAME]=C;$define(GLOBAL+WRAP+FORCED*!isNative(C),O);isWeak||defineStdIterators(C,NAME,function(iterated,kind){set(this,ITER,{o:iterated,k:kind})},function(){var iter=this[ITER],kind=iter.k,entry=iter.l;while(entry&&entry.r)entry=entry.p;if(!iter.o||!(iter.l=entry=entry?entry.n:iter.o[FIRST])){return iter.o=undefined,iterResult(1)}if(kind==KEY)return iterResult(0,entry.k);if(kind==VALUE)return iterResult(0,entry.v);return iterResult(0,[entry.k,entry.v])},isMap?KEY+VALUE:VALUE,!isMap);return C}function fastKey(it,create){if(!isObject(it))return(typeof it=="string"?"S":"P")+it;if(isFrozen(it))return"F";if(!has(it,UID)){if(!create)return"E";hidden(it,UID,++uid)}return"O"+it[UID]}function getEntry(that,key){var index=fastKey(key),entry;if(index!="F")return that[O1][index];for(entry=that[FIRST];entry;entry=entry.n){if(entry.k==key)return entry}}function def(that,key,value){var entry=getEntry(that,key),prev,index;if(entry)entry.v=value;else{that[LAST]=entry={i:index=fastKey(key,true),k:key,v:value,p:prev=that[LAST],n:undefined,r:false};if(!that[FIRST])that[FIRST]=entry;if(prev)prev.n=entry;that[SIZE]++;if(index!="F")that[O1][index]=entry}return that}var collectionMethods={clear:function(){for(var that=this,data=that[O1],entry=that[FIRST];entry;entry=entry.n){entry.r=true;entry.p=entry.n=undefined;delete data[entry.i]}that[FIRST]=that[LAST]=undefined;that[SIZE]=0},"delete":function(key){var that=this,entry=getEntry(that,key);if(entry){var next=entry.n,prev=entry.p;delete that[O1][entry.i];entry.r=true;if(prev)prev.n=next;if(next)next.p=prev;if(that[FIRST]==entry)that[FIRST]=next;if(that[LAST]==entry)that[LAST]=prev;that[SIZE]--}return!!entry},forEach:function(callbackfn){var f=ctx(callbackfn,arguments[1],3),entry;while(entry=entry?entry.n:this[FIRST]){f(entry.v,entry.k,this);while(entry&&entry.r)entry=entry.p}},has:function(key){return!!getEntry(this,key)}};Map=getCollection(Map,MAP,{get:function(key){var entry=getEntry(this,key);return entry&&entry.v},set:function(key,value){return def(this,key===0?0:key,value)}},collectionMethods,true);Set=getCollection(Set,SET,{add:function(value){return def(this,value=value===0?0:value,value)}},collectionMethods);function defWeak(that,key,value){if(isFrozen(assertObject(key)))leakStore(that).set(key,value);else{has(key,WEAK)||hidden(key,WEAK,{});key[WEAK][that[UID]]=value}return that}function leakStore(that){return that[LEAK]||hidden(that,LEAK,new Map)[LEAK]}var weakMethods={"delete":function(key){if(!isObject(key))return false;if(isFrozen(key))return leakStore(this)["delete"](key);return has(key,WEAK)&&has(key[WEAK],this[UID])&&delete key[WEAK][this[UID]]},has:function(key){if(!isObject(key))return false;if(isFrozen(key))return leakStore(this).has(key);return has(key,WEAK)&&has(key[WEAK],this[UID])}};WeakMap=getCollection(WeakMap,WEAKMAP,{get:function(key){if(isObject(key)){if(isFrozen(key))return leakStore(this).get(key);if(has(key,WEAK))return key[WEAK][this[UID]]}},set:function(key,value){return defWeak(this,key,value)}},weakMethods,true,true);if(framework&&DESC&&new WeakMap([[Object.freeze(tmp),7]]).get(tmp)!=7){forEach.call(array("delete,has,get,set"),function(key){var method=WeakMap[PROTOTYPE][key];WeakMap[PROTOTYPE][key]=function(a,b){if(isObject(a)&&isFrozen(a)){var result=leakStore(this)[key](a,b);return key=="set"?this:result }return method.call(this,a,b)}})}WeakSet=getCollection(WeakSet,WEAKSET,{add:function(value){return defWeak(this,value,true)}},weakMethods,false,true)}();!function(){function Enumerate(iterated){var keys=[],key;for(key in iterated)keys.push(key);set(this,ITER,{o:iterated,a:keys,i:0})}createIterator(Enumerate,OBJECT,function(){var iter=this[ITER],keys=iter.a,key;do{if(iter.i>=keys.length)return iterResult(1)}while(!((key=keys[iter.i++])in iter.o));return iterResult(0,key)});function wrap(fn){return function(it){assertObject(it);try{return fn.apply(undefined,arguments),true}catch(e){return false}}}function reflectGet(target,propertyKey){var receiver=arguments.length<3?target:arguments[2],desc=getOwnDescriptor(assertObject(target),propertyKey),proto;if(desc)return desc.get?desc.get.call(receiver):desc.value;return isObject(proto=getPrototypeOf(target))?reflectGet(proto,propertyKey,receiver):undefined}function reflectSet(target,propertyKey,V){var receiver=arguments.length<4?target:arguments[3],desc=getOwnDescriptor(assertObject(target),propertyKey),proto;if(desc){if(desc.writable===false)return false;if(desc.set)return desc.set.call(receiver,V),true}if(isObject(proto=getPrototypeOf(target)))return reflectSet(proto,propertyKey,V,receiver);desc=getOwnDescriptor(receiver,propertyKey)||descriptor(0);desc.value=V;return defineProperty(receiver,propertyKey,desc),true}var isExtensible=Object.isExtensible||returnIt;var reflect={apply:ctx(call,apply,3),construct:construct,defineProperty:wrap(defineProperty),deleteProperty:function(target,propertyKey){var desc=getOwnDescriptor(assertObject(target),propertyKey);return desc&&!desc.configurable?false:delete target[propertyKey]},enumerate:function(target){return new Enumerate(assertObject(target))},get:reflectGet,getOwnPropertyDescriptor:function(target,propertyKey){return getOwnDescriptor(assertObject(target),propertyKey)},getPrototypeOf:function(target){return getPrototypeOf(assertObject(target))},has:function(target,propertyKey){return propertyKey in target},isExtensible:function(target){return!!isExtensible(assertObject(target))},ownKeys:ownKeys,preventExtensions:wrap(Object.preventExtensions||returnIt),set:reflectSet};if(setPrototypeOf)reflect.setPrototypeOf=function(target,proto){return setPrototypeOf(assertObject(target),proto),true};$define(GLOBAL,{Reflect:{}});$define(STATIC,"Reflect",reflect)}();!function(){$define(PROTO,ARRAY,{includes:createArrayContains(true)});$define(PROTO,STRING,{at:createPointAt(true)});function createObjectToArray(isEntries){return function(object){var O=toObject(object),keys=getKeys(object),length=keys.length,i=0,result=Array(length),key;if(isEntries)while(length>i)result[i]=[key=keys[i++],O[key]];else while(length>i)result[i]=O[keys[i++]];return result}}$define(STATIC,OBJECT,{values:createObjectToArray(false),entries:createObjectToArray(true)});$define(STATIC,REGEXP,{escape:createReplacer(/([\\\-[\]{}()*+?.,^$|])/g,"\\$1",true)})}();!function(REFERENCE){REFERENCE_GET=getWellKnownSymbol(REFERENCE+"Get",true);var REFERENCE_SET=getWellKnownSymbol(REFERENCE+SET,true),REFERENCE_DELETE=getWellKnownSymbol(REFERENCE+"Delete",true);$define(STATIC,SYMBOL,{referenceGet:REFERENCE_GET,referenceSet:REFERENCE_SET,referenceDelete:REFERENCE_DELETE});hidden(FunctionProto,REFERENCE_GET,returnThis);function setMapMethods(Constructor){if(Constructor){var MapProto=Constructor[PROTOTYPE];hidden(MapProto,REFERENCE_GET,MapProto.get);hidden(MapProto,REFERENCE_SET,MapProto.set);hidden(MapProto,REFERENCE_DELETE,MapProto["delete"])}}setMapMethods(Map);setMapMethods(WeakMap)}("reference");!function(NodeList){if(framework&&NodeList&&!(SYMBOL_ITERATOR in NodeList[PROTOTYPE])){hidden(NodeList[PROTOTYPE],SYMBOL_ITERATOR,Iterators[ARRAY])}Iterators.NodeList=Iterators[ARRAY]}(global.NodeList);!function(arrayStatics){function setArrayStatics(keys,length){forEach.call(array(keys),function(key){if(key in ArrayProto)arrayStatics[key]=ctx(call,ArrayProto[key],length)})}setArrayStatics("pop,reverse,shift,keys,values,entries",1);setArrayStatics("indexOf,every,some,forEach,map,filter,find,findIndex,includes",3);setArrayStatics("join,slice,concat,push,splice,unshift,sort,lastIndexOf,"+"reduce,reduceRight,copyWithin,fill,turn");$define(STATIC,ARRAY,arrayStatics)}({})}(typeof self!="undefined"&&self.Math===Math?self:Function("return this")(),true)},{}],3:[function(require,module,exports){(function(global){!function(global){"use strict";var hasOwn=Object.prototype.hasOwnProperty;var undefined;var iteratorSymbol=typeof Symbol==="function"&&Symbol.iterator||"@@iterator";var inModule=typeof module==="object";var runtime=global.regeneratorRuntime;if(runtime){if(inModule){module.exports=runtime}return}runtime=global.regeneratorRuntime=inModule?module.exports:{};function wrap(innerFn,outerFn,self,tryList){return new Generator(innerFn,outerFn,self||null,tryList||[])}runtime.wrap=wrap;function tryCatch(fn,obj,arg){try{return{type:"normal",arg:fn.call(obj,arg)}}catch(err){return{type:"throw",arg:err}}}var GenStateSuspendedStart="suspendedStart";var GenStateSuspendedYield="suspendedYield";var GenStateExecuting="executing";var GenStateCompleted="completed";var ContinueSentinel={};function GeneratorFunction(){}function GeneratorFunctionPrototype(){}var Gp=GeneratorFunctionPrototype.prototype=Generator.prototype;GeneratorFunction.prototype=Gp.constructor=GeneratorFunctionPrototype;GeneratorFunctionPrototype.constructor=GeneratorFunction;GeneratorFunction.displayName="GeneratorFunction";runtime.isGeneratorFunction=function(genFun){var ctor=typeof genFun==="function"&&genFun.constructor;return ctor?ctor===GeneratorFunction||(ctor.displayName||ctor.name)==="GeneratorFunction":false};runtime.mark=function(genFun){genFun.__proto__=GeneratorFunctionPrototype;genFun.prototype=Object.create(Gp);return genFun};runtime.async=function(innerFn,outerFn,self,tryList){return new Promise(function(resolve,reject){var generator=wrap(innerFn,outerFn,self,tryList);var callNext=step.bind(generator.next);var callThrow=step.bind(generator["throw"]);function step(arg){var record=tryCatch(this,null,arg);if(record.type==="throw"){reject(record.arg);return}var info=record.arg;if(info.done){resolve(info.value)}else{Promise.resolve(info.value).then(callNext,callThrow)}}callNext()})};function Generator(innerFn,outerFn,self,tryList){var generator=outerFn?Object.create(outerFn.prototype):this;var context=new Context(tryList);var state=GenStateSuspendedStart;function invoke(method,arg){if(state===GenStateExecuting){throw new Error("Generator is already running")}if(state===GenStateCompleted){return doneResult()}while(true){var delegate=context.delegate;if(delegate){var record=tryCatch(delegate.iterator[method],delegate.iterator,arg);if(record.type==="throw"){context.delegate=null;method="throw";arg=record.arg;continue}method="next";arg=undefined;var info=record.arg;if(info.done){context[delegate.resultName]=info.value;context.next=delegate.nextLoc}else{state=GenStateSuspendedYield;return info}context.delegate=null}if(method==="next"){if(state===GenStateSuspendedStart&&typeof arg!=="undefined"){throw new TypeError("attempt to send "+JSON.stringify(arg)+" to newborn generator")}if(state===GenStateSuspendedYield){context.sent=arg}else{delete context.sent}}else if(method==="throw"){if(state===GenStateSuspendedStart){state=GenStateCompleted;throw arg}if(context.dispatchException(arg)){method="next";arg=undefined}}else if(method==="return"){context.abrupt("return",arg)}state=GenStateExecuting;var record=tryCatch(innerFn,self,context);if(record.type==="normal"){state=context.done?GenStateCompleted:GenStateSuspendedYield;var info={value:record.arg,done:context.done};if(record.arg===ContinueSentinel){if(context.delegate&&method==="next"){arg=undefined}}else{return info}}else if(record.type==="throw"){state=GenStateCompleted;if(method==="next"){context.dispatchException(record.arg)}else{arg=record.arg}}}}generator.next=invoke.bind(generator,"next");generator["throw"]=invoke.bind(generator,"throw");generator["return"]=invoke.bind(generator,"return");return generator}Gp[iteratorSymbol]=function(){return this};Gp.toString=function(){return"[object Generator]"};function pushTryEntry(triple){var entry={tryLoc:triple[0]};if(1 in triple){entry.catchLoc=triple[1]}if(2 in triple){entry.finallyLoc=triple[2]}this.tryEntries.push(entry)}function resetTryEntry(entry,i){var record=entry.completion||{};record.type=i===0?"normal":"return";delete record.arg;entry.completion=record}function Context(tryList){this.tryEntries=[{tryLoc:"root"}];tryList.forEach(pushTryEntry,this);this.reset()}runtime.keys=function(object){var keys=[];for(var key in object){keys.push(key)}keys.reverse();return function next(){while(keys.length){var key=keys.pop();if(key in object){next.value=key;next.done=false;return next}}next.done=true;return next}};function values(iterable){if(iterable){var iteratorMethod=iterable[iteratorSymbol];if(iteratorMethod){return iteratorMethod.call(iterable)}if(typeof iterable.next==="function"){return iterable}if(!isNaN(iterable.length)){var i=-1,next=function next(){while(++i<iterable.length){if(hasOwn.call(iterable,i)){next.value=iterable[i];next.done=false;return next}}next.value=undefined;next.done=true;return next};return next.next=next}}return{next:doneResult}}runtime.values=values;function doneResult(){return{value:undefined,done:true}}Context.prototype={constructor:Context,reset:function(){this.prev=0;this.next=0;this.sent=undefined;this.done=false;this.delegate=null;this.tryEntries.forEach(resetTryEntry);for(var tempIndex=0,tempName;hasOwn.call(this,tempName="t"+tempIndex)||tempIndex<20;++tempIndex){this[tempName]=null}},stop:function(){this.done=true;var rootEntry=this.tryEntries[0];var rootRecord=rootEntry.completion;if(rootRecord.type==="throw"){throw rootRecord.arg}return this.rval},dispatchException:function(exception){if(this.done){throw exception}var context=this;function handle(loc,caught){record.type="throw";record.arg=exception;context.next=loc;return!!caught}for(var i=this.tryEntries.length-1;i>=0;--i){var entry=this.tryEntries[i];var record=entry.completion;if(entry.tryLoc==="root"){return handle("end")}if(entry.tryLoc<=this.prev){var hasCatch=hasOwn.call(entry,"catchLoc");var hasFinally=hasOwn.call(entry,"finallyLoc");if(hasCatch&&hasFinally){if(this.prev<entry.catchLoc){return handle(entry.catchLoc,true)}else if(this.prev<entry.finallyLoc){return handle(entry.finallyLoc)}}else if(hasCatch){if(this.prev<entry.catchLoc){return handle(entry.catchLoc,true)}}else if(hasFinally){if(this.prev<entry.finallyLoc){return handle(entry.finallyLoc)}}else{throw new Error("try statement without catch or finally")}}}},_findFinallyEntry:function(finallyLoc){for(var i=this.tryEntries.length-1;i>=0;--i){var entry=this.tryEntries[i];if(entry.tryLoc<=this.prev&&hasOwn.call(entry,"finallyLoc")&&(entry.finallyLoc===finallyLoc||this.prev<entry.finallyLoc)){return entry}}},abrupt:function(type,arg){var entry=this._findFinallyEntry();var record=entry?entry.completion:{};record.type=type;record.arg=arg;if(entry){this.next=entry.finallyLoc}else{this.complete(record)}return ContinueSentinel},complete:function(record){if(record.type==="throw"){throw record.arg}if(record.type==="break"||record.type==="continue"){this.next=record.arg}else if(record.type==="return"){this.rval=record.arg;this.next="end"}return ContinueSentinel},finish:function(finallyLoc){var entry=this._findFinallyEntry(finallyLoc);return this.complete(entry.completion)},"catch":function(tryLoc){for(var i=this.tryEntries.length-1;i>=0;--i){var entry=this.tryEntries[i];if(entry.tryLoc===tryLoc){var record=entry.completion;if(record.type==="throw"){var thrown=record.arg;resetTryEntry(entry,i)}return thrown}}throw new Error("illegal catch attempt")},delegateYield:function(iterable,resultName,nextLoc){this.delegate={iterator:values(iterable),resultName:resultName,nextLoc:nextLoc};return ContinueSentinel}}}(typeof global==="object"?global:typeof window==="object"?window:this)}).call(this,typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{})},{}]},{},[1]);
ajax/libs/zxcvbn/1.0.7/zxcvbn.js
dakshshah96/cdnjs
(function(){var x,p,s,y,J,K,L,M,N,O,P,Q,z,q,A,R,S,T,U,V,W;P=function(b){var a,c;c=[];for(a in b)c.push(a);return 0===c.length};z=function(b,a){return b.push.apply(b,a)};V=function(b,a){var c,e,f,d,g;d=b.split("");g=[];e=0;for(f=d.length;e<f;e++)c=d[e],g.push(a[c]||c);return g.join("")};R=function(b,a){var c,e,f,d;d=[];c=0;for(e=a.length;c<e;c++)f=a[c],z(d,f(b));return d.sort(function(b,a){return b.i-a.i||b.j-a.j})};N=function(b,a){var c,e,f,d,g,h,j,i,k,l,m;l=[];d=b.length;h=b.toLowerCase();for(c= f=0;0<=d?f<d:f>d;c=0<=d?++f:--f){e=g=i=c;for(k=d;i<=k?g<k:g>k;e=i<=k?++g:--g)if(h.slice(c,+e+1||9E9)in a)m=h.slice(c,+e+1||9E9),j=a[m],l.push({pattern:"dictionary",i:c,j:e,token:b.slice(c,+e+1||9E9),matched_word:m,rank:j})}return l};s=function(b){var a,c,e,f,d;f={};a=1;c=0;for(e=b.length;c<e;c++)d=b[c],f[d]=a,a+=1;return f};p=function(b,a){return function(c){var e,f,d;d=N(c,a);c=0;for(e=d.length;c<e;c++)f=d[c],f.dictionary_name=b;return d}};A={a:["4","@"],b:["8"],c:["(","{","[","<"],e:["3"],g:["6", "9"],i:["1","!","|"],l:["1","|","7"],o:["0"],s:["$","5"],t:["+","7"],x:["%"],z:["2"]};S=function(b){var a,c,e,f,d;f={};d=b.split("");a=0;for(c=d.length;a<c;a++)b=d[a],f[b]=!0;b={};for(e in A){c=A[e];var g=d=void 0,h=void 0,h=[],g=0;for(d=c.length;g<d;g++)a=c[g],a in f&&h.push(a);a=h;0<a.length&&(b[e]=a)}return b};Q=function(b){var a,c,e,f,d,g,h,j,i,k,l,m,r;d=function(){var a;a=[];for(f in b)a.push(f);return a}();r=[[]];c=function(a){var b,c,d,e,g,j,h,i;c=[];j={};d=0;for(g=a.length;d<g;d++)h=a[d], b=function(){var a,b,c;c=[];i=b=0;for(a=h.length;b<a;i=++b)f=h[i],c.push([f,i]);return c}(),b.sort(),e=function(){var a,c,d;d=[];i=c=0;for(a=b.length;c<a;i=++c)f=b[i],d.push(f+","+i);return d}().join("-"),e in j||(j[e]=!0,c.push(h));return c};e=function(a){var d,f,g,i,h,j,k,l,m,n,p,s,q;if(a.length){f=a[0];s=a.slice(1);l=[];n=b[f];a=0;for(h=n.length;a<h;a++){i=n[a];k=0;for(j=r.length;k<j;k++){q=r[k];d=-1;g=m=0;for(p=q.length;0<=p?m<p:m>p;g=0<=p?++m:--m)if(q[g][0]===i){d=g;break}-1===d?(d=q.concat([[i, f]]),l.push(d)):(g=q.slice(0),g.splice(d,1),g.push([i,f]),l.push(q),l.push(g))}}r=c(l);return e(s)}};e(d);m=[];d=0;for(h=r.length;d<h;d++){k=r[d];l={};i=0;for(j=k.length;i<j;i++)a=k[i],g=a[0],a=a[1],l[g]=a;m.push(l)}return m};U=function(b,a,c){var e,f,d,g,h,j,i,k,l,m,r,o,n;r=[];for(j=0;j<b.length-1;){i=j+1;l=null;for(o=n=0;;){e=b.charAt(i-1);h=!1;g=-1;f=a[e]||[];if(i<b.length){d=b.charAt(i);k=0;for(m=f.length;k<m;k++)if(e=f[k],g+=1,e&&-1!==e.indexOf(d)){h=!0;1===e.indexOf(d)&&(o+=1);l!==g&&(n+=1, l=g);break}}if(h)i+=1;else{2<i-j&&r.push({pattern:"spatial",i:j,j:i-1,token:b.slice(j,i),graph:c,turns:n,shifted_count:o});j=i;break}}}return r};x={lower:"abcdefghijklmnopqrstuvwxyz",upper:"ABCDEFGHIJKLMNOPQRSTUVWXYZ",digits:"01234567890"};T=function(b,a){var c,e;e=[];for(c=1;1<=a?c<=a:c>=a;1<=a?++c:--c)e.push(b);return e.join("")};q=function(b,a){var c,e;for(e=[];;){c=b.match(a);if(!c)break;c.i=c.index;c.j=c.index+c[0].length-1;e.push(c);b=b.replace(c[0],T(" ",c[0].length))}return e};O=/\d{3,}/; W=/19\d\d|200\d|201\d/;M=function(b){var a,c,e,f,d,g,h,j,i,k,l,m,r,o;f=[];r=q(b,/\d{4,8}/);j=0;for(i=r.length;j<i;j++){g=r[j];h=[g.i,g.j];g=h[0];h=h[1];e=b.slice(g,+h+1||9E9);a=e.length;c=[];6>=e.length&&(c.push({daymonth:e.slice(2),year:e.slice(0,2),i:g,j:h}),c.push({daymonth:e.slice(0,a-2),year:e.slice(a-2),i:g,j:h}));6<=e.length&&(c.push({daymonth:e.slice(4),year:e.slice(0,4),i:g,j:h}),c.push({daymonth:e.slice(0,a-4),year:e.slice(a-4),i:g,j:h}));e=[];l=0;for(k=c.length;l<k;l++)switch(a=c[l],a.daymonth.length){case 2:e.push({day:a.daymonth[0], month:a.daymonth[1],year:a.year,i:a.i,j:a.j});break;case 3:e.push({day:a.daymonth.slice(0,2),month:a.daymonth[2],year:a.year,i:a.i,j:a.j});e.push({day:a.daymonth[0],month:a.daymonth.slice(1,3),year:a.year,i:a.i,j:a.j});break;case 4:e.push({day:a.daymonth.slice(0,2),month:a.daymonth.slice(2,4),year:a.year,i:a.i,j:a.j})}k=0;for(c=e.length;k<c;k++)a=e[k],d=parseInt(a.day),m=parseInt(a.month),o=parseInt(a.year),d=y(d,m,o),l=d[0],o=d[1],d=o[0],m=o[1],o=o[2],l&&f.push({pattern:"date",i:a.i,j:a.j,token:b.slice(g, +h+1||9E9),separator:"",day:d,month:m,year:o})}return f};K=/(\d{1,2})(\s|-|\/|\\|_|\.)(\d{1,2})\2(19\d{2}|200\d|201\d|\d{2})/;J=/(19\d{2}|200\d|201\d|\d{2})(\s|-|\/|\\|_|\.)(\d{1,2})\2(\d{1,2})/;L=function(b){var a,c,e,f,d,g,h,j,i,k;g=[];j=q(b,K);e=0;for(f=j.length;e<f;e++)d=j[e],i=function(){var a,b,e,f;e=[1,3,4];f=[];b=0;for(a=e.length;b<a;b++)c=e[b],f.push(parseInt(d[c]));return f}(),d.day=i[0],d.month=i[1],d.year=i[2],d.sep=d[2],g.push(d);j=q(b,J);f=0;for(e=j.length;f<e;f++)d=j[f],i=function(){var a, b,e,f;e=[4,3,1];f=[];b=0;for(a=e.length;b<a;b++)c=e[b],f.push(parseInt(d[c]));return f}(),d.day=i[0],d.month=i[1],d.year=i[2],d.sep=d[2],g.push(d);j=[];f=0;for(e=g.length;f<e;f++)d=g[f],a=y(d.day,d.month,d.year),i=a[0],k=a[1],a=k[0],h=k[1],k=k[2],i&&j.push({pattern:"date",i:d.i,j:d.j,token:b.slice(d.i,+d.j+1||9E9),separator:d.sep,day:a,month:h,year:k});return j};y=function(b,a,c){12<=a&&31>=a&&12>=b&&(a=[a,b],b=a[0],a=a[1]);return 31<b||12<a||!(1900<=c&&2019>=c)?[!1,[]]:[!0,[b,a,c]]};var X,Y,Z,$, B,aa,ba,ca,da,ea,fa,ga,ha,ia,n,ja,u,ka,C,la,ma,na;u=function(b,a){var c,e,f;if(a>b)return 0;if(0===a)return 1;for(c=e=f=1;1<=a?e<=a:e>=a;c=1<=a?++e:--e)f*=b,f/=c,b-=1;return f};n=function(b){return Math.log(b)/Math.log(2)};ja=function(b,a){var c,e,f,d,g,h,j,i,k,l,m;e=B(b);m=[];c=[];d=h=0;for(l=b.length;0<=l?h<l:h>l;d=0<=l?++h:--h){m[d]=(m[d-1]||0)+n(e);c[d]=null;i=0;for(j=a.length;i<j;i++)k=a[i],k.j===d&&(g=[k.i,k.j],f=g[0],g=g[1],f=(m[f-1]||0)+aa(k),f<m[g]&&(m[g]=f,c[g]=k))}h=[];for(d=b.length-1;0<= d;)(k=c[d])?(h.push(k),d=k.i-1):d-=1;h.reverse();j=function(a,c){return{pattern:"bruteforce",i:a,j:c,token:b.slice(a,+c+1||9E9),entropy:n(Math.pow(e,c-a+1)),cardinality:e}};d=0;i=[];l=0;for(c=h.length;l<c;l++)k=h[l],g=[k.i,k.j],f=g[0],g=g[1],0<f-d&&i.push(j(d,f-1)),d=g+1,i.push(k);d<b.length&&i.push(j(d,b.length-1));h=i;k=m[b.length-1]||0;d=ga(k);return{password:b,entropy:C(k,3),match_sequence:h,crack_time:C(d,3),crack_time_display:fa(d),score:ba(d)}};C=function(b,a){return Math.round(b*Math.pow(10, a))/Math.pow(10,a)};ga=function(b){return 5.0E-5*Math.pow(2,b)};ba=function(b){return b<Math.pow(10,2)?0:b<Math.pow(10,4)?1:b<Math.pow(10,6)?2:b<Math.pow(10,8)?3:4};aa=function(b){var a;if(null!=b.entropy)return b.entropy;a=function(){switch(b.pattern){case "repeat":return ka;case "sequence":return la;case "digits":return ea;case "year":return na;case "date":return ca;case "spatial":return ma;case "dictionary":return da}}();return b.entropy=a(b)};ka=function(b){var a;a=B(b.token);return n(a*b.token.length)}; la=function(b){var a;a=b.token.charAt(0);a="a"===a||"1"===a?1:a.match(/\d/)?n(10):a.match(/[a-z]/)?n(26):n(26)+1;b.ascending||(a+=1);return a+n(b.token.length)};ea=function(b){return n(Math.pow(10,b.token.length))};na=function(){return n(119)};ca=function(b){var a;a=100>b.year?n(37200):n(44268);b.separator&&(a+=2);return a};ma=function(b){var a,c,e,f,d,g,h,j,i,k;"qwerty"===(e=b.graph)||"dvorak"===e?(i=oa,c=pa):(i=qa,c=ra);h=0;a=b.token.length;k=b.turns;for(e=d=2;2<=a?d<=a:d>=a;e=2<=a?++d:--d){j=Math.min(k, e-1);for(f=g=1;1<=j?g<=j:g>=j;f=1<=j?++g:--g)h+=u(e-1,f-1)*i*Math.pow(c,f)}c=n(h);if(b.shifted_count){a=b.shifted_count;b=b.token.length-b.shifted_count;e=f=h=0;for(d=Math.min(a,b);0<=d?f<=d:f>=d;e=0<=d?++f:--f)h+=u(a+b,e);c+=n(h)}return c};da=function(b){b.base_entropy=n(b.rank);b.uppercase_entropy=ia(b);b.l33t_entropy=ha(b);return b.base_entropy+b.uppercase_entropy+b.l33t_entropy};$=/^[A-Z][^A-Z]+$/;Z=/^[^A-Z]+[A-Z]$/;Y=/^[^a-z]+$/;X=/^[^A-Z]+$/;ia=function(b){var a,c,e,f,d,g,h;h=b.token;if(h.match(X))return 0; e=[$,Z,Y];b=0;for(a=e.length;b<a;b++)if(f=e[b],h.match(f))return 1;a=function(){var a,b,d,e;d=h.split("");e=[];b=0;for(a=d.length;b<a;b++)c=d[b],c.match(/[A-Z]/)&&e.push(c);return e}().length;b=function(){var a,b,d,e;d=h.split("");e=[];b=0;for(a=d.length;b<a;b++)c=d[b],c.match(/[a-z]/)&&e.push(c);return e}().length;e=f=d=0;for(g=Math.min(a,b);0<=g?f<=g:f>=g;e=0<=g?++f:--f)d+=u(a+b,e);return n(d)};ha=function(b){var a,c,e,f,d,g,h,j,i,k;if(!b.l33t)return 0;g=0;h=b.sub;for(i in h){k=h[i];a=function(){var a, d,c,f;c=b.token.split("");f=[];a=0;for(d=c.length;a<d;a++)e=c[a],e===i&&f.push(e);return f}().length;c=function(){var a,d,c,f;c=b.token.split("");f=[];a=0;for(d=c.length;a<d;a++)e=c[a],e===k&&f.push(e);return f}().length;f=d=0;for(j=Math.min(c,a);0<=j?d<=j:d>=j;f=0<=j?++d:--d)g+=u(c+a,f)}return n(g)||1};B=function(b){var a,c,e,f,d,g,h,j;d=[!1,!1,!1,!1,!1];f=d[0];j=d[1];c=d[2];h=d[3];d=d[4];g=b.split("");b=0;for(e=g.length;b<e;b++)a=g[b],a=a.charCodeAt(0),48<=a&&57>=a?c=!0:65<=a&&90>=a?j=!0:97<=a&& 122>=a?f=!0:127>=a?h=!0:d=!0;b=0;c&&(b+=10);j&&(b+=26);f&&(b+=26);h&&(b+=33);d&&(b+=100);return b};fa=function(b){return 60>b?"instant":3600>b?1+Math.ceil(b/60)+" minutes":86400>b?1+Math.ceil(b/3600)+" hours":2678400>b?1+Math.ceil(b/86400)+" days":32140800>b?1+Math.ceil(b/2678400)+" months":321408E4>b?1+Math.ceil(b/32140800)+" years":"centuries"};var D={"!":["`~",null,null,"2@","qQ",null],'"':[";:","[{","]}",null,null,"/?"],"#":["2@",null,null,"4$","eE","wW"],$:["3#",null,null,"5%","rR","eE"],"%":["4$", null,null,"6^","tT","rR"],"&":["6^",null,null,"8*","uU","yY"],"'":[";:","[{","]}",null,null,"/?"],"(":["8*",null,null,"0)","oO","iI"],")":["9(",null,null,"-_","pP","oO"],"*":["7&",null,null,"9(","iI","uU"],"+":["-_",null,null,null,"]}","[{"],",":["mM","kK","lL",".>",null,null],"-":["0)",null,null,"=+","[{","pP"],".":[",<","lL",";:","/?",null,null],"/":[".>",";:","'\"",null,null,null],"0":["9(",null,null,"-_","pP","oO"],1:["`~",null,null,"2@","qQ",null],2:["1!",null,null,"3#","wW","qQ"],3:["2@",null, null,"4$","eE","wW"],4:["3#",null,null,"5%","rR","eE"],5:["4$",null,null,"6^","tT","rR"],6:["5%",null,null,"7&","yY","tT"],7:["6^",null,null,"8*","uU","yY"],8:["7&",null,null,"9(","iI","uU"],9:["8*",null,null,"0)","oO","iI"],":":"lL,pP,[{,'\",/?,.>".split(","),";":"lL,pP,[{,'\",/?,.>".split(","),"<":["mM","kK","lL",".>",null,null],"=":["-_",null,null,null,"]}","[{"],">":[",<","lL",";:","/?",null,null],"?":[".>",";:","'\"",null,null,null],"@":["1!",null,null,"3#","wW","qQ"],A:[null,"qQ","wW","sS", "zZ",null],B:["vV","gG","hH","nN",null,null],C:["xX","dD","fF","vV",null,null],D:"sS,eE,rR,fF,cC,xX".split(","),E:"wW,3#,4$,rR,dD,sS".split(","),F:"dD,rR,tT,gG,vV,cC".split(","),G:"fF,tT,yY,hH,bB,vV".split(","),H:"gG,yY,uU,jJ,nN,bB".split(","),I:"uU,8*,9(,oO,kK,jJ".split(","),J:"hH,uU,iI,kK,mM,nN".split(","),K:"jJ iI oO lL ,< mM".split(" "),L:"kK oO pP ;: .> ,<".split(" "),M:["nN","jJ","kK",",<",null,null],N:["bB","hH","jJ","mM",null,null],O:"iI,9(,0),pP,lL,kK".split(","),P:"oO,0),-_,[{,;:,lL".split(","), Q:[null,"1!","2@","wW","aA",null],R:"eE,4$,5%,tT,fF,dD".split(","),S:"aA,wW,eE,dD,xX,zZ".split(","),T:"rR,5%,6^,yY,gG,fF".split(","),U:"yY,7&,8*,iI,jJ,hH".split(","),V:["cC","fF","gG","bB",null,null],W:"qQ,2@,3#,eE,sS,aA".split(","),X:["zZ","sS","dD","cC",null,null],Y:"tT,6^,7&,uU,hH,gG".split(","),Z:[null,"aA","sS","xX",null,null],"[":"pP,-_,=+,]},'\",;:".split(","),"\\":["]}",null,null,null,null,null],"]":["[{","=+",null,"\\|",null,"'\""],"^":["5%",null,null,"7&","yY","tT"],_:["0)",null,null,"=+", "[{","pP"],"`":[null,null,null,"1!",null,null],a:[null,"qQ","wW","sS","zZ",null],b:["vV","gG","hH","nN",null,null],c:["xX","dD","fF","vV",null,null],d:"sS,eE,rR,fF,cC,xX".split(","),e:"wW,3#,4$,rR,dD,sS".split(","),f:"dD,rR,tT,gG,vV,cC".split(","),g:"fF,tT,yY,hH,bB,vV".split(","),h:"gG,yY,uU,jJ,nN,bB".split(","),i:"uU,8*,9(,oO,kK,jJ".split(","),j:"hH,uU,iI,kK,mM,nN".split(","),k:"jJ iI oO lL ,< mM".split(" "),l:"kK oO pP ;: .> ,<".split(" "),m:["nN","jJ","kK",",<",null,null],n:["bB","hH","jJ","mM", null,null],o:"iI,9(,0),pP,lL,kK".split(","),p:"oO,0),-_,[{,;:,lL".split(","),q:[null,"1!","2@","wW","aA",null],r:"eE,4$,5%,tT,fF,dD".split(","),s:"aA,wW,eE,dD,xX,zZ".split(","),t:"rR,5%,6^,yY,gG,fF".split(","),u:"yY,7&,8*,iI,jJ,hH".split(","),v:["cC","fF","gG","bB",null,null],w:"qQ,2@,3#,eE,sS,aA".split(","),x:["zZ","sS","dD","cC",null,null],y:"tT,6^,7&,uU,hH,gG".split(","),z:[null,"aA","sS","xX",null,null],"{":"pP,-_,=+,]},'\",;:".split(","),"|":["]}",null,null,null,null,null],"}":["[{","=+",null, "\\|",null,"'\""],"~":[null,null,null,"1!",null,null]},E={"*":["/",null,null,null,"-","+","9","8"],"+":["9","*","-",null,null,null,null,"6"],"-":["*",null,null,null,null,null,"+","9"],".":["0","2","3",null,null,null,null,null],"/":[null,null,null,null,"*","9","8","7"],"0":[null,"1","2","3",".",null,null,null],1:[null,null,"4","5","2","0",null,null],2:["1","4","5","6","3",".","0",null],3:["2","5","6",null,null,null,".","0"],4:[null,null,"7","8","5","2","1",null],5:"4,7,8,9,6,3,2,1".split(","),6:["5", "8","9","+",null,null,"3","2"],7:[null,null,null,"/","8","5","4",null],8:["7",null,"/","*","9","6","5","4"],9:["8","/","*","-","+",null,"6","5"]},v,F,pa,oa,ra,qa,sa,G,w,H,I;v=[p("passwords",s("password,123456,12345678,1234,qwerty,12345,dragon,pussy,baseball,football,letmein,monkey,696969,abc123,mustang,shadow,master,111111,2000,jordan,superman,harley,1234567,fuckme,hunter,fuckyou,trustno1,ranger,buster,tigger,soccer,fuck,batman,test,pass,killer,hockey,charlie,love,sunshine,asshole,6969,pepper,access,123456789,654321,maggie,starwars,silver,dallas,yankees,123123,666666,hello,orange,biteme,freedom,computer,sexy,thunder,ginger,hammer,summer,corvette,fucker,austin,1111,merlin,121212,golfer,cheese,princess,chelsea,diamond,yellow,bigdog,secret,asdfgh,sparky,cowboy,camaro,matrix,falcon,iloveyou,guitar,purple,scooter,phoenix,aaaaaa,tigers,porsche,mickey,maverick,cookie,nascar,peanut,131313,money,horny,samantha,panties,steelers,snoopy,boomer,whatever,iceman,smokey,gateway,dakota,cowboys,eagles,chicken,dick,black,zxcvbn,ferrari,knight,hardcore,compaq,coffee,booboo,bitch,bulldog,xxxxxx,welcome,player,ncc1701,wizard,scooby,junior,internet,bigdick,brandy,tennis,blowjob,banana,monster,spider,lakers,rabbit,enter,mercedes,fender,yamaha,diablo,boston,tiger,marine,chicago,rangers,gandalf,winter,bigtits,barney,raiders,porn,badboy,blowme,spanky,bigdaddy,chester,london,midnight,blue,fishing,000000,hannah,slayer,11111111,sexsex,redsox,thx1138,asdf,marlboro,panther,zxcvbnm,arsenal,qazwsx,mother,7777777,jasper,winner,golden,butthead,viking,iwantu,angels,prince,cameron,girls,madison,hooters,startrek,captain,maddog,jasmine,butter,booger,golf,rocket,theman,liverpoo,flower,forever,muffin,turtle,sophie,redskins,toyota,sierra,winston,giants,packers,newyork,casper,bubba,112233,lovers,mountain,united,driver,helpme,fucking,pookie,lucky,maxwell,8675309,bear,suckit,gators,5150,222222,shithead,fuckoff,jaguar,hotdog,tits,gemini,lover,xxxxxxxx,777777,canada,florida,88888888,rosebud,metallic,doctor,trouble,success,stupid,tomcat,warrior,peaches,apples,fish,qwertyui,magic,buddy,dolphins,rainbow,gunner,987654,freddy,alexis,braves,cock,2112,1212,cocacola,xavier,dolphin,testing,bond007,member,voodoo,7777,samson,apollo,fire,tester,beavis,voyager,porno,rush2112,beer,apple,scorpio,skippy,sydney,red123,power,beaver,star,jackass,flyers,boobs,232323,zzzzzz,scorpion,doggie,legend,ou812,yankee,blazer,runner,birdie,bitches,555555,topgun,asdfasdf,heaven,viper,animal,2222,bigboy,4444,private,godzilla,lifehack,phantom,rock,august,sammy,cool,platinum,jake,bronco,heka6w2,copper,cumshot,garfield,willow,cunt,slut,69696969,kitten,super,jordan23,eagle1,shelby,america,11111,free,123321,chevy,bullshit,broncos,horney,surfer,nissan,999999,saturn,airborne,elephant,shit,action,adidas,qwert,1313,explorer,police,christin,december,wolf,sweet,therock,online,dickhead,brooklyn,cricket,racing,penis,0000,teens,redwings,dreams,michigan,hentai,magnum,87654321,donkey,trinity,digital,333333,cartman,guinness,123abc,speedy,buffalo,kitty,pimpin,eagle,einstein,nirvana,vampire,xxxx,playboy,pumpkin,snowball,test123,sucker,mexico,beatles,fantasy,celtic,cherry,cassie,888888,sniper,genesis,hotrod,reddog,alexande,college,jester,passw0rd,bigcock,lasvegas,slipknot,3333,death,1q2w3e,eclipse,1q2w3e4r,drummer,montana,music,aaaa,carolina,colorado,creative,hello1,goober,friday,bollocks,scotty,abcdef,bubbles,hawaii,fluffy,horses,thumper,5555,pussies,darkness,asdfghjk,boobies,buddha,sandman,naughty,honda,azerty,6666,shorty,money1,beach,loveme,4321,simple,poohbear,444444,badass,destiny,vikings,lizard,assman,nintendo,123qwe,november,xxxxx,october,leather,bastard,101010,extreme,password1,pussy1,lacrosse,hotmail,spooky,amateur,alaska,badger,paradise,maryjane,poop,mozart,video,vagina,spitfire,cherokee,cougar,420420,horse,enigma,raider,brazil,blonde,55555,dude,drowssap,lovely,1qaz2wsx,booty,snickers,nipples,diesel,rocks,eminem,westside,suzuki,passion,hummer,ladies,alpha,suckme,147147,pirate,semperfi,jupiter,redrum,freeuser,wanker,stinky,ducati,paris,babygirl,windows,spirit,pantera,monday,patches,brutus,smooth,penguin,marley,forest,cream,212121,flash,maximus,nipple,vision,pokemon,champion,fireman,indian,softball,picard,system,cobra,enjoy,lucky1,boogie,marines,security,dirty,admin,wildcats,pimp,dancer,hardon,fucked,abcd1234,abcdefg,ironman,wolverin,freepass,bigred,squirt,justice,hobbes,pearljam,mercury,domino,9999,rascal,hitman,mistress,bbbbbb,peekaboo,naked,budlight,electric,sluts,stargate,saints,bondage,bigman,zombie,swimming,duke,qwerty1,babes,scotland,disney,rooster,mookie,swordfis,hunting,blink182,8888,samsung,bubba1,whore,general,passport,aaaaaaaa,erotic,liberty,arizona,abcd,newport,skipper,rolltide,balls,happy1,galore,christ,weasel,242424,wombat,digger,classic,bulldogs,poopoo,accord,popcorn,turkey,bunny,mouse,007007,titanic,liverpool,dreamer,everton,chevelle,psycho,nemesis,pontiac,connor,eatme,lickme,cumming,ireland,spiderma,patriots,goblue,devils,empire,asdfg,cardinal,shaggy,froggy,qwer,kawasaki,kodiak,phpbb,54321,chopper,hooker,whynot,lesbian,snake,teen,ncc1701d,qqqqqq,airplane,britney,avalon,sugar,sublime,wildcat,raven,scarface,elizabet,123654,trucks,wolfpack,pervert,redhead,american,bambam,woody,shaved,snowman,tiger1,chicks,raptor,1969,stingray,shooter,france,stars,madmax,sports,789456,simpsons,lights,chronic,hahaha,packard,hendrix,service,spring,srinivas,spike,252525,bigmac,suck,single,popeye,tattoo,texas,bullet,taurus,sailor,wolves,panthers,japan,strike,pussycat,chris1,loverboy,berlin,sticky,tarheels,russia,wolfgang,testtest,mature,catch22,juice,michael1,nigger,159753,alpha1,trooper,hawkeye,freaky,dodgers,pakistan,machine,pyramid,vegeta,katana,moose,tinker,coyote,infinity,pepsi,letmein1,bang,hercules,james1,tickle,outlaw,browns,billybob,pickle,test1,sucks,pavilion,changeme,caesar,prelude,darkside,bowling,wutang,sunset,alabama,danger,zeppelin,pppppp,2001,ping,darkstar,madonna,qwe123,bigone,casino,charlie1,mmmmmm,integra,wrangler,apache,tweety,qwerty12,bobafett,transam,2323,seattle,ssssss,openup,pandora,pussys,trucker,indigo,storm,malibu,weed,review,babydoll,doggy,dilbert,pegasus,joker,catfish,flipper,fuckit,detroit,cheyenne,bruins,smoke,marino,fetish,xfiles,stinger,pizza,babe,stealth,manutd,gundam,cessna,longhorn,presario,mnbvcxz,wicked,mustang1,victory,21122112,awesome,athena,q1w2e3r4,holiday,knicks,redneck,12341234,gizmo,scully,dragon1,devildog,triumph,bluebird,shotgun,peewee,angel1,metallica,madman,impala,lennon,omega,access14,enterpri,search,smitty,blizzard,unicorn,tight,asdf1234,trigger,truck,beauty,thailand,1234567890,cadillac,castle,bobcat,buddy1,sunny,stones,asian,butt,loveyou,hellfire,hotsex,indiana,panzer,lonewolf,trumpet,colors,blaster,12121212,fireball,precious,jungle,atlanta,gold,corona,polaris,timber,theone,baller,chipper,skyline,dragons,dogs,licker,engineer,kong,pencil,basketba,hornet,barbie,wetpussy,indians,redman,foobar,travel,morpheus,target,141414,hotstuff,photos,rocky1,fuck_inside,dollar,turbo,design,hottie,202020,blondes,4128,lestat,avatar,goforit,random,abgrtyu,jjjjjj,cancer,q1w2e3,smiley,express,virgin,zipper,wrinkle1,babylon,consumer,monkey1,serenity,samurai,99999999,bigboobs,skeeter,joejoe,master1,aaaaa,chocolat,christia,stephani,tang,1234qwer,98765432,sexual,maxima,77777777,buckeye,highland,seminole,reaper,bassman,nugget,lucifer,airforce,nasty,warlock,2121,dodge,chrissy,burger,snatch,pink,gang,maddie,huskers,piglet,photo,dodger,paladin,chubby,buckeyes,hamlet,abcdefgh,bigfoot,sunday,manson,goldfish,garden,deftones,icecream,blondie,spartan,charger,stormy,juventus,galaxy,escort,zxcvb,planet,blues,david1,ncc1701e,1966,51505150,cavalier,gambit,ripper,oicu812,nylons,aardvark,whiskey,bing,plastic,anal,babylon5,loser,racecar,insane,yankees1,mememe,hansolo,chiefs,fredfred,freak,frog,salmon,concrete,zxcv,shamrock,atlantis,wordpass,rommel,1010,predator,massive,cats,sammy1,mister,stud,marathon,rubber,ding,trunks,desire,montreal,justme,faster,irish,1999,jessica1,alpine,diamonds,00000,swinger,shan,stallion,pitbull,letmein2,ming,shadow1,clitoris,fuckers,jackoff,bluesky,sundance,renegade,hollywoo,151515,wolfman,soldier,ling,goddess,manager,sweety,titans,fang,ficken,niners,bubble,hello123,ibanez,sweetpea,stocking,323232,tornado,content,aragorn,trojan,christop,rockstar,geronimo,pascal,crimson,google,fatcat,lovelove,cunts,stimpy,finger,wheels,viper1,latin,greenday,987654321,creampie,hiphop,snapper,funtime,duck,trombone,adult,cookies,mulder,westham,latino,jeep,ravens,drizzt,madness,energy,kinky,314159,slick,rocker,55555555,mongoose,speed,dddddd,catdog,cheng,ghost,gogogo,tottenha,curious,butterfl,mission,january,shark,techno,lancer,lalala,chichi,orion,trixie,delta,bobbob,bomber,kang,1968,spunky,liquid,beagle,granny,network,kkkkkk,1973,biggie,beetle,teacher,toronto,anakin,genius,cocks,dang,karate,snakes,bangkok,fuckyou2,pacific,daytona,infantry,skywalke,sailing,raistlin,vanhalen,huang,blackie,tarzan,strider,sherlock,gong,dietcoke,ultimate,shai,sprite,ting,artist,chai,chao,devil,python,ninja,ytrewq,superfly,456789,tian,jing,jesus1,freedom1,drpepper,chou,hobbit,shen,nolimit,mylove,biscuit,yahoo,shasta,sex4me,smoker,pebbles,pics,philly,tong,tintin,lesbians,cactus,frank1,tttttt,chun,danni,emerald,showme,pirates,lian,dogg,xiao,xian,tazman,tanker,toshiba,gotcha,rang,keng,jazz,bigguy,yuan,tomtom,chaos,fossil,racerx,creamy,bobo,musicman,warcraft,blade,shuang,shun,lick,jian,microsoft,rong,feng,getsome,quality,1977,beng,wwwwww,yoyoyo,zhang,seng,harder,qazxsw,qian,cong,chuan,deng,nang,boeing,keeper,western,1963,subaru,sheng,thuglife,teng,jiong,miao,mang,maniac,pussie,a1b2c3,zhou,zhuang,xing,stonecol,spyder,liang,jiang,memphis,ceng,magic1,logitech,chuang,sesame,shao,poison,titty,kuan,kuai,mian,guan,hamster,guai,ferret,geng,duan,pang,maiden,quan,velvet,nong,neng,nookie,buttons,bian,bingo,biao,zhong,zeng,zhun,ying,zong,xuan,zang,0.0.000,suan,shei,shui,sharks,shang,shua,peng,pian,piao,liao,meng,miami,reng,guang,cang,ruan,diao,luan,qing,chui,chuo,cuan,nuan,ning,heng,huan,kansas,muscle,weng,1passwor,bluemoon,zhui,zhua,xiang,zheng,zhen,zhei,zhao,zhan,yomama,zhai,zhuo,zuan,tarheel,shou,shuo,tiao,leng,kuang,jiao,13579,basket,qiao,qiong,qiang,chuai,nian,niao,niang,huai,22222222,zhuan,zhuai,shuan,shuai,stardust,jumper,66666666,charlott,qwertz,bones,waterloo,2002,11223344,oldman,trains,vertigo,246810,black1,swallow,smiles,standard,alexandr,parrot,user,1976,surfing,pioneer,apple1,asdasd,auburn,hannibal,frontier,panama,welcome1,vette,blue22,shemale,111222,baggins,groovy,global,181818,1979,blades,spanking,byteme,lobster,dawg,japanese,1970,1964,2424,polo,coco,deedee,mikey,1972,171717,1701,strip,jersey,green1,capital,putter,vader,seven7,banshee,grendel,dicks,hidden,iloveu,1980,ledzep,147258,female,bugger,buffett,molson,2020,wookie,sprint,jericho,102030,ranger1,trebor,deepthroat,bonehead,molly1,mirage,models,1984,2468,showtime,squirrel,pentium,anime,gator,powder,twister,connect,neptune,engine,eatshit,mustangs,woody1,shogun,septembe,pooh,jimbo,russian,sabine,voyeur,2525,363636,camel,germany,giant,qqqq,nudist,bone,sleepy,tequila,fighter,obiwan,makaveli,vacation,walnut,1974,ladybug,cantona,ccbill,satan,rusty1,passwor1,columbia,kissme,motorola,william1,1967,zzzz,skater,smut,matthew1,valley,coolio,dagger,boner,bull,horndog,jason1,penguins,rescue,griffey,8j4ye3uz,californ,champs,qwertyuiop,portland,colt45,xxxxxxx,xanadu,tacoma,carpet,gggggg,safety,palace,italia,picturs,picasso,thongs,tempest,asd123,hairy,foxtrot,nimrod,hotboy,343434,1111111,asdfghjkl,goose,overlord,stranger,454545,shaolin,sooners,socrates,spiderman,peanuts,13131313,andrew1,filthy,ohyeah,africa,intrepid,pickles,assass,fright,potato,hhhhhh,kingdom,weezer,424242,pepsi1,throat,looker,puppy,butch,sweets,megadeth,analsex,nymets,ddddddd,bigballs,oakland,oooooo,qweasd,chucky,carrot,chargers,discover,dookie,condor,horny1,sunrise,sinner,jojo,megapass,martini,assfuck,ffffff,mushroom,jamaica,7654321,77777,cccccc,gizmodo,tractor,mypass,hongkong,1975,blue123,pissing,thomas1,redred,basketball,satan666,dublin,bollox,kingkong,1971,22222,272727,sexx,bbbb,grizzly,passat,defiant,bowler,knickers,monitor,wisdom,slappy,thor,letsgo,robert1,brownie,098765,playtime,lightnin,atomic,goku,llllll,qwaszx,cosmos,bosco,knights,beast,slapshot,assword,frosty,dumbass,mallard,dddd,159357,titleist,aussie,golfing,doobie,loveit,werewolf,vipers,1965,blabla,surf,sucking,tardis,thegame,legion,rebels,sarah1,onelove,loulou,toto,blackcat,0007,tacobell,soccer1,jedi,method,poopie,boob,breast,kittycat,belly,pikachu,thunder1,thankyou,celtics,frogger,scoobydo,sabbath,coltrane,budman,jackal,zzzzz,licking,gopher,geheim,lonestar,primus,pooper,newpass,brasil,heather1,husker,element,moomoo,beefcake,zzzzzzzz,shitty,smokin,jjjj,anthony1,anubis,backup,gorilla,fuckface,lowrider,punkrock,traffic,delta1,amazon,fatass,dodgeram,dingdong,qqqqqqqq,breasts,boots,honda1,spidey,poker,temp,johnjohn,147852,asshole1,dogdog,tricky,crusader,syracuse,spankme,speaker,meridian,amadeus,harley1,falcons,turkey50,kenwood,keyboard,ilovesex,1978,shazam,shalom,lickit,jimbob,roller,fatman,sandiego,magnus,cooldude,clover,mobile,plumber,texas1,tool,topper,mariners,rebel,caliente,celica,oxford,osiris,orgasm,punkin,porsche9,tuesday,breeze,bossman,kangaroo,latinas,astros,scruffy,qwertyu,hearts,jammer,java,1122,goodtime,chelsea1,freckles,flyboy,doodle,nebraska,bootie,kicker,webmaster,vulcan,191919,blueeyes,321321,farside,rugby,director,pussy69,power1,hershey,hermes,monopoly,birdman,blessed,blackjac,southern,peterpan,thumbs,fuckyou1,rrrrrr,a1b2c3d4,coke,bohica,elvis1,blacky,sentinel,snake1,richard1,1234abcd,guardian,candyman,fisting,scarlet,dildo,pancho,mandingo,lucky7,condom,munchkin,billyboy,summer1,sword,skiing,site,sony,thong,rootbeer,assassin,fffff,fitness,durango,postal,achilles,kisses,warriors,plymouth,topdog,asterix,hallo,cameltoe,fuckfuck,eeeeee,sithlord,theking,avenger,backdoor,chevrole,trance,cosworth,houses,homers,eternity,kingpin,verbatim,incubus,1961,blond,zaphod,shiloh,spurs,mighty,aliens,charly,dogman,omega1,printer,aggies,deadhead,bitch1,stone55,pineappl,thekid,rockets,camels,formula,oracle,pussey,porkchop,abcde,clancy,mystic,inferno,blackdog,steve1,alfa,grumpy,flames,puffy,proxy,valhalla,unreal,herbie,engage,yyyyyy,010101,pistol,celeb,gggg,portugal,a12345,newbie,mmmm,1qazxsw2,zorro,writer,stripper,sebastia,spread,links,metal,1221,565656,funfun,trojans,cyber,hurrican,moneys,1x2zkg8w,zeus,tomato,lion,atlantic,usa123,trans,aaaaaaa,homerun,hyperion,kevin1,blacks,44444444,skittles,fart,gangbang,fubar,sailboat,oilers,buster1,hithere,immortal,sticks,pilot,lexmark,jerkoff,maryland,cheers,possum,cutter,muppet,swordfish,sport,sonic,peter1,jethro,rockon,asdfghj,pass123,pornos,ncc1701a,bootys,buttman,bonjour,1960,bears,362436,spartans,tinman,threesom,maxmax,1414,bbbbb,camelot,chewie,gogo,fusion,saint,dilligaf,nopass,hustler,hunter1,whitey,beast1,yesyes,spank,smudge,pinkfloy,patriot,lespaul,hammers,formula1,sausage,scooter1,orioles,oscar1,colombia,cramps,exotic,iguana,suckers,slave,topcat,lancelot,magelan,racer,crunch,british,steph,456123,skinny,seeking,rockhard,filter,freaks,sakura,pacman,poontang,newlife,homer1,klingon,watcher,walleye,tasty,sinatra,starship,steel,starbuck,poncho,amber1,gonzo,catherin,candle,firefly,goblin,scotch,diver,usmc,huskies,kentucky,kitkat,beckham,bicycle,yourmom,studio,33333333,splash,jimmy1,12344321,sapphire,mailman,raiders1,ddddd,excalibu,illini,imperial,lansing,maxx,gothic,golfball,facial,front242,macdaddy,qwer1234,vectra,cowboys1,crazy1,dannyboy,aquarius,franky,ffff,sassy,pppp,pppppppp,prodigy,noodle,eatpussy,vortex,wanking,billy1,siemens,phillies,groups,chevy1,cccc,gggggggg,doughboy,dracula,nurses,loco,lollipop,utopia,chrono,cooler,nevada,wibble,summit,1225,capone,fugazi,panda,qazwsxed,puppies,triton,9876,nnnnnn,momoney,iforgot,wolfie,studly,hamburg,81fukkc,741852,catman,china,gagging,scott1,oregon,qweqwe,crazybab,daniel1,cutlass,holes,mothers,music1,walrus,1957,bigtime,xtreme,simba,ssss,rookie,bathing,rotten,maestro,turbo1,99999,butthole,hhhh,yoda,shania,phish,thecat,rightnow,baddog,greatone,gateway1,abstr,napster,brian1,bogart,hitler,wildfire,jackson1,1981,beaner,yoyo,0.0.0.000,super1,select,snuggles,slutty,phoenix1,technics,toon,raven1,rayray,123789,1066,albion,greens,gesperrt,brucelee,hehehe,kelly1,mojo,1998,bikini,woofwoof,yyyy,strap,sites,central,f**k,nyjets,punisher,username,vanilla,twisted,bunghole,viagra,veritas,pony,titts,labtec,jenny1,masterbate,mayhem,redbull,govols,gremlin,505050,gmoney,rovers,diamond1,trident,abnormal,deskjet,cuddles,bristol,milano,vh5150,jarhead,1982,bigbird,bizkit,sixers,slider,star69,starfish,penetration,tommy1,john316,caligula,flicks,films,railroad,cosmo,cthulhu,br0d3r,bearbear,swedish,spawn,patrick1,reds,anarchy,groove,fuckher,oooo,airbus,cobra1,clips,delete,duster,kitty1,mouse1,monkeys,jazzman,1919,262626,swinging,stroke,stocks,sting,pippen,labrador,jordan1,justdoit,meatball,females,vector,cooter,defender,nike,bubbas,bonkers,kahuna,wildman,4121,sirius,static,piercing,terror,teenage,leelee,microsof,mechanic,robotech,rated,chaser,salsero,macross,quantum,tsunami,daddy1,cruise,newpass6,nudes,hellyeah,1959,zaq12wsx,striker,spice,spectrum,smegma,thumb,jjjjjjjj,mellow,cancun,cartoon,sabres,samiam,oranges,oklahoma,lust,denali,nude,noodles,brest,hooter,mmmmmmmm,warthog,blueblue,zappa,wolverine,sniffing,jjjjj,calico,freee,rover,pooter,closeup,bonsai,emily1,keystone,iiii,1955,yzerman,theboss,tolkien,megaman,rasta,bbbbbbbb,hal9000,goofy,gringo,gofish,gizmo1,samsam,scuba,onlyme,tttttttt,corrado,clown,clapton,bulls,jayhawk,wwww,sharky,seeker,ssssssss,pillow,thesims,lighter,lkjhgf,melissa1,marcius2,guiness,gymnast,casey1,goalie,godsmack,lolo,rangers1,poppy,clemson,clipper,deeznuts,holly1,eeee,kingston,yosemite,sucked,sex123,sexy69,pic\\'s,tommyboy,masterbating,gretzky,happyday,frisco,orchid,orange1,manchest,aberdeen,ne1469,boxing,korn,intercourse,161616,1985,ziggy,supersta,stoney,amature,babyboy,bcfields,goliath,hack,hardrock,frodo,scout,scrappy,qazqaz,tracker,active,craving,commando,cohiba,cyclone,bubba69,katie1,mpegs,vsegda,irish1,sexy1,smelly,squerting,lions,jokers,jojojo,meathead,ashley1,groucho,cheetah,champ,firefox,gandalf1,packer,love69,tyler1,typhoon,tundra,bobby1,kenworth,village,volley,wolf359,0420,000007,swimmer,skydive,smokes,peugeot,pompey,legolas,redhot,rodman,redalert,grapes,4runner,carrera,floppy,ou8122,quattro,cloud9,davids,nofear,busty,homemade,mmmmm,whisper,vermont,webmaste,wives,insertion,jayjay,philips,topher,temptress,midget,ripken,havefun,canon,celebrity,ghetto,ragnarok,usnavy,conover,cruiser,dalshe,nicole1,buzzard,hottest,kingfish,misfit,milfnew,warlord,wassup,bigsexy,blackhaw,zippy,tights,kungfu,labia,meatloaf,area51,batman1,bananas,636363,ggggg,paradox,queens,adults,aikido,cigars,hoosier,eeyore,moose1,warez,interacial,streaming,313131,pertinant,pool6123,mayday,animated,banker,baddest,gordon24,ccccc,fantasies,aisan,deadman,homepage,ejaculation,whocares,iscool,jamesbon,1956,1pussy,womam,sweden,skidoo,spock,sssss,pepper1,pinhead,micron,allsop,amsterda,gunnar,666999,february,fletch,george1,sapper,sasha1,luckydog,lover1,magick,popopo,ultima,cypress,businessbabe,brandon1,vulva,vvvv,jabroni,bigbear,yummy,010203,searay,secret1,sinbad,sexxxx,soleil,software,piccolo,thirteen,leopard,legacy,memorex,redwing,rasputin,134679,anfield,greenbay,catcat,feather,scanner,pa55word,contortionist,danzig,daisy1,hores,exodus,iiiiii,1001,subway,snapple,sneakers,sonyfuck,picks,poodle,test1234,llll,junebug,marker,mellon,ronaldo,roadkill,amanda1,asdfjkl,beaches,great1,cheerleaers,doitnow,ozzy,boxster,brighton,housewifes,kkkk,mnbvcx,moocow,vides,1717,bigmoney,blonds,1000,storys,stereo,4545,420247,seductive,sexygirl,lesbean,justin1,124578,cabbage,canadian,gangbanged,dodge1,dimas,malaka,puss,probes,coolman,nacked,hotpussy,erotica,kool,implants,intruder,bigass,zenith,woohoo,womans,tango,pisces,laguna,maxell,andyod22,barcelon,chainsaw,chickens,flash1,orgasms,magicman,profit,pusyy,pothead,coconut,chuckie,clevelan,builder,budweise,hotshot,horizon,experienced,mondeo,wifes,1962,stumpy,smiths,slacker,pitchers,passwords,laptop,allmine,alliance,bbbbbbb,asscock,halflife,88888,chacha,saratoga,sandy1,doogie,qwert40,transexual,close-up,ib6ub9,volvo,jacob1,iiiii,beastie,sunnyday,stoned,sonics,starfire,snapon,pictuers,pepe,testing1,tiberius,lisalisa,lesbain,litle,retard,ripple,austin1,badgirl,golfgolf,flounder,royals,dragoon,dickie,passwor,majestic,poppop,trailers,nokia,bobobo,br549,minime,mikemike,whitesox,1954,3232,353535,seamus,solo,sluttey,pictere,titten,lback,1024,goodluck,fingerig,gallaries,goat,passme,oasis,lockerroom,logan1,rainman,treasure,custom,cyclops,nipper,bucket,homepage-,hhhhh,momsuck,indain,2345,beerbeer,bimmer,stunner,456456,tootsie,testerer,reefer,1012,harcore,gollum,545454,chico,caveman,fordf150,fishes,gaymen,saleen,doodoo,pa55w0rd,presto,qqqqq,cigar,bogey,helloo,dutch,kamikaze,wasser,vietnam,visa,japanees,0123,swords,slapper,peach,masterbaiting,redwood,1005,ametuer,chiks,fucing,sadie1,panasoni,mamas,rambo,unknown,absolut,dallas1,housewife,keywest,kipper,18436572,1515,zxczxc,303030,shaman,terrapin,masturbation,mick,redfish,1492,angus,goirish,hardcock,forfun,galary,freeporn,duchess,olivier,lotus,pornographic,ramses,purdue,traveler,crave,brando,enter1,killme,moneyman,welder,windsor,wifey,indon,yyyyy,taylor1,4417,picher,pickup,thumbnils,johnboy,jets,ameteur,amateurs,apollo13,hambone,goldwing,5050,sally1,doghouse,padres,pounding,quest,truelove,underdog,trader,climber,bolitas,hohoho,beanie,beretta,wrestlin,stroker,sexyman,jewels,johannes,mets,rhino,bdsm,balloons,grils,happy123,flamingo,route66,devo,outkast,paintbal,magpie,llllllll,twilight,critter,cupcake,nickel,bullseye,knickerless,videoes,binladen,xerxes,slim,slinky,pinky,thanatos,meister,menace,retired,albatros,balloon,goten,5551212,getsdown,donuts,nwo4life,tttt,comet,deer,dddddddd,deeznutz,nasty1,nonono,enterprise,eeeee,misfit99,milkman,vvvvvv,1818,blueboy,bigbutt,tech,toolman,juggalo,jetski,barefoot,50spanks,gobears,scandinavian,cubbies,nitram,kings,bilbo,yumyum,zzzzzzz,stylus,321654,shannon1,server,squash,starman,steeler,phrases,techniques,laser,135790,athens,cbr600,chemical,fester,gangsta,fucku2,droopy,objects,passwd,lllll,manchester,vedder,clit,chunky,darkman,buckshot,buddah,boobed,henti,winter1,bigmike,beta,zidane,talon,slave1,pissoff,thegreat,lexus,matador,readers,armani,goldstar,5656,fmale,fuking,fucku,ggggggg,sauron,diggler,pacers,looser,pounded,premier,triangle,cosmic,depeche,norway,helmet,mustard,misty1,jagger,3x7pxr,silver1,snowboar,penetrating,photoes,lesbens,lindros,roadking,rockford,1357,143143,asasas,goodboy,898989,chicago1,ferrari1,galeries,godfathe,gawker,gargoyle,gangster,rubble,rrrr,onetime,pussyman,pooppoop,trapper,cinder,newcastl,boricua,bunny1,boxer,hotred,hockey1,edward1,moscow,mortgage,bigtit,snoopdog,joshua1,july,1230,assholes,frisky,sanity,divine,dharma,lucky13,akira,butterfly,hotbox,hootie,howdy,earthlink,kiteboy,westwood,1988,blackbir,biggles,wrench,wrestle,slippery,pheonix,penny1,pianoman,thedude,jenn,jonjon,jones1,roadrunn,arrow,azzer,seahawks,diehard,dotcom,tunafish,chivas,cinnamon,clouds,deluxe,northern,boobie,momomo,modles,volume,23232323,bluedog,wwwwwww,zerocool,yousuck,pluto,limewire,joung,awnyce,gonavy,haha,films+pic+galeries,girsl,fuckthis,girfriend,uncencored,a123456,chrisbln,combat,cygnus,cupoi,netscape,hhhhhhhh,eagles1,elite,knockers,1958,tazmania,shonuf,pharmacy,thedog,midway,arsenal1,anaconda,australi,gromit,gotohell,787878,66666,carmex2,camber,gator1,ginger1,fuzzy,seadoo,lovesex,rancid,uuuuuu,911911,bulldog1,heater,monalisa,mmmmmmm,whiteout,virtual,jamie1,japanes,james007,2727,2469,blam,bitchass,zephyr,stiffy,sweet1,southpar,spectre,tigger1,tekken,lakota,lionking,jjjjjjj,megatron,1369,hawaiian,gymnastic,golfer1,gunners,7779311,515151,sanfran,optimus,panther1,love1,maggie1,pudding,aaron1,delphi,niceass,bounce,house1,killer1,momo,musashi,jammin,2003,234567,wp2003wp,submit,sssssss,spikes,sleeper,passwort,kume,meme,medusa,mantis,reebok,1017,artemis,harry1,cafc91,fettish,oceans,oooooooo,mango,ppppp,trainer,uuuu,909090,death1,bullfrog,hokies,holyshit,eeeeeee,jasmine1,&amp,&amp;,spinner,jockey,babyblue,gooner,474747,cheeks,pass1234,parola,okokok,poseidon,989898,crusher,cubswin,nnnn,kotaku,mittens,whatsup,vvvvv,iomega,insertions,bengals,biit,yellow1,012345,spike1,sowhat,pitures,pecker,theend,hayabusa,hawkeyes,florian,qaz123,usarmy,twinkle,chuckles,hounddog,hover,hothot,europa,kenshin,kojak,mikey1,water1,196969,wraith,zebra,wwwww,33333,simon1,spider1,snuffy,philippe,thunderb,teddy1,marino13,maria1,redline,renault,aloha,handyman,cerberus,gamecock,gobucks,freesex,duffman,ooooo,nuggets,magician,longbow,preacher,porno1,chrysler,contains,dalejr,navy,buffy1,hedgehog,hoosiers,honey1,hott,heyhey,dutchess,everest,wareagle,ihateyou,sunflowe,3434,senators,shag,spoon,sonoma,stalker,poochie,terminal,terefon,maradona,1007,142536,alibaba,america1,bartman,astro,goth,chicken1,cheater,ghost1,passpass,oral,r2d2c3po,civic,cicero,myxworld,kkkkk,missouri,wishbone,infiniti,1a2b3c,1qwerty,wonderboy,shojou,sparky1,smeghead,poiuy,titanium,lantern,jelly,1213,bayern,basset,gsxr750,cattle,fishing1,fullmoon,gilles,dima,obelix,popo,prissy,ramrod,bummer,hotone,dynasty,entry,konyor,missy1,282828,xyz123,426hemi,404040,seinfeld,pingpong,lazarus,marine1,12345a,beamer,babyface,greece,gustav,7007,ccccccc,faggot,foxy,gladiato,duckie,dogfood,packers1,longjohn,radical,tuna,clarinet,danny1,novell,bonbon,kashmir,kiki,mortimer,modelsne,moondog,vladimir,insert,1953,zxc123,supreme,3131,sexxx,softail,poipoi,pong,mars,martin1,rogue,avalanch,audia4,55bgates,cccccccc,came11,figaro,dogboy,dnsadm,dipshit,paradigm,othello,operator,tripod,chopin,coucou,cocksuck,borussia,heritage,hiziad,homerj,mullet,whisky,4242,speedo,starcraf,skylar,spaceman,piggy,tiger2,legos,jezebel,joker1,mazda,727272,chester1,rrrrrrrr,dundee,lumber,ppppppp,tranny,aaliyah,admiral,comics,delight,buttfuck,homeboy,eternal,kilroy,violin,wingman,walmart,bigblue,blaze,beemer,beowulf,bigfish,yyyyyyy,woodie,yeahbaby,0123456,tbone,syzygy,starter,linda1,merlot,mexican,11235813,banner,bangbang,badman,barfly,grease,charles1,ffffffff,doberman,dogshit,overkill,coolguy,claymore,demo,nomore,hhhhhhh,hondas,iamgod,enterme,electron,eastside,minimoni,mybaby,wildbill,wildcard,ipswich,200000,bearcat,zigzag,yyyyyyyy,sweetnes,369369,skyler,skywalker,pigeon,tipper,asdf123,alphabet,asdzxc,babybaby,banane,guyver,graphics,chinook,florida1,flexible,fuckinside,ursitesux,tototo,adam12,christma,chrome,buddie,bombers,hippie,misfits,292929,woofer,wwwwwwww,stubby,sheep,sparta,stang,spud,sporty,pinball,just4fun,maxxxx,rebecca1,fffffff,freeway,garion,rrrrr,sancho,outback,maggot,puddin,987456,hoops,mydick,19691969,bigcat,shiner,silverad,templar,lamer,juicy,mike1,maximum,1223,10101010,arrows,alucard,haggis,cheech,safari,dog123,orion1,paloma,qwerasdf,presiden,vegitto,969696,adonis,cookie1,newyork1,buddyboy,hellos,heineken,eraser,moritz,millwall,visual,jaybird,1983,beautifu,zodiac,steven1,sinister,slammer,smashing,slick1,sponge,teddybea,ticklish,jonny,1211,aptiva,applepie,bailey1,guitar1,canyon,gagged,fuckme1,digital1,dinosaur,98765,90210,clowns,cubs,deejay,nigga,naruto,boxcar,icehouse,hotties,electra,widget,1986,2004,bluefish,bingo1,*****,stratus,sultan,storm1,44444,4200,sentnece,sexyboy,sigma,smokie,spam,pippo,temppass,manman,1022,bacchus,aztnm,axio,bamboo,hakr,gregor,hahahaha,5678,camero1,dolphin1,paddle,magnet,qwert1,pyon,porsche1,tripper,noway,burrito,bozo,highheel,hookem,eddie1,entropy,kkkkkkkk,kkkkkkk,illinois,1945,1951,24680,21212121,100000,stonecold,taco,subzero,sexxxy,skolko,skyhawk,spurs1,sputnik,testpass,jiggaman,1224,hannah1,525252,4ever,carbon,scorpio1,rt6ytere,madison1,loki,coolness,coldbeer,citadel,monarch,morgan1,washingt,1997,bella1,yaya,superb,taxman,studman,3636,pizzas,tiffany1,lassie,larry1,joseph1,mephisto,reptile,razor,1013,hammer1,gypsy,grande,camper,chippy,cat123,chimera,fiesta,glock,domain,dieter,dragonba,onetwo,nygiants,password2,quartz,prowler,prophet,towers,ultra,cocker,corleone,dakota1,cumm,nnnnnnn,boxers,heynow,iceberg,kittykat,wasabi,vikings1,beerman,splinter,snoopy1,pipeline,mickey1,mermaid,micro,meowmeow,redbird,baura,chevys,caravan,frogman,diving,dogger,draven,drifter,oatmeal,paris1,longdong,quant4307s,rachel1,vegitta,cobras,corsair,dadada,mylife,bowwow,hotrats,eastwood,moonligh,modena,illusion,iiiiiii,jayhawks,swingers,shocker,shrimp,sexgod,squall,poiu,tigers1,toejam,tickler,julie1,jimbo1,jefferso,michael2,rodeo,robot,1023,annie1,bball,happy2,charter,flasher,falcon1,fiction,fastball,gadget,scrabble,diaper,dirtbike,oliver1,paco,macman,poopy,popper,postman,ttttttt,acura,cowboy1,conan,daewoo,nemrac58,nnnnn,nextel,bobdylan,eureka,kimmie,kcj9wx5n,killbill,musica,volkswag,wage,windmill,wert,vintage,iloveyou1,itsme,zippo,311311,starligh,smokey1,snappy,soulmate,plasma,krusty,just4me,marius,rebel1,1123,audi,fick,goaway,rusty2,dogbone,doofus,ooooooo,oblivion,mankind,mahler,lllllll,pumper,puck,pulsar,valkyrie,tupac,compass,concorde,cougars,delaware,niceguy,nocturne,bob123,boating,bronze,herewego,hewlett,houhou,earnhard,eeeeeeee,mingus,mobydick,venture,verizon,imation,1950,1948,1949,223344,bigbig,wowwow,sissy,spiker,snooker,sluggo,player1,jsbach,jumbo,medic,reddevil,reckless,123456a,1125,1031,astra,gumby,757575,585858,chillin,fuck1,radiohea,upyours,trek,coolcool,classics,choochoo,nikki1,nitro,boytoy,excite,kirsty,wingnut,wireless,icu812,1master,beatle,bigblock,wolfen,summer99,sugar1,tartar,sexysexy,senna,sexman,soprano,platypus,pixies,telephon,laura1,laurent,rimmer,1020,12qwaszx,hamish,halifax,fishhead,forum,dododo,doit,paramedi,lonesome,mandy1,uuuuu,uranus,ttttt,bruce1,helper,hopeful,eduard,dusty1,kathy1,moonbeam,muscles,monster1,monkeybo,windsurf,vvvvvvv,vivid,install,1947,187187,1941,1952,susan1,31415926,sinned,sexxy,smoothie,snowflak,playstat,playa,playboy1,toaster,jerry1,marie1,mason1,merlin1,roger1,roadster,112358,1121,andrea1,bacardi,hardware,789789,5555555,captain1,fergus,sascha,rrrrrrr,dome,onion,lololo,qqqqqqq,undertak,uuuuuuuu,uuuuuuu,cobain,cindy1,coors,descent,nimbus,nomad,nanook,norwich,bombay,broker,hookup,kiwi,winners,jackpot,1a2b3c4d,1776,beardog,bighead,bird33,0987,spooge,pelican,peepee,titan,thedoors,jeremy1,altima,baba,hardone,5454,catwoman,finance,farmboy,farscape,genesis1,salomon,loser1,r2d2,pumpkins,chriss,cumcum,ninjas,ninja1,killers,miller1,islander,jamesbond,intel,19841984,2626,bizzare,blue12,biker,yoyoma,sushi,shitface,spanker,steffi,sphinx,please1,paulie,pistons,tiburon,maxwell1,mdogg,rockies,armstron,alejandr,arctic,banger,audio,asimov,753951,4you,chilly,care1839,flyfish,fantasia,freefall,sandrine,oreo,ohshit,macbeth,madcat,loveya,qwerqwer,colnago,chocha,cobalt,crystal1,dabears,nevets,nineinch,broncos1,epsilon,kestrel,winston1,warrior1,iiiiiiii,iloveyou2,1616,woowoo,sloppy,specialk,tinkerbe,jellybea,reader,redsox1,1215,1112,arcadia,baggio,555666,cayman,cbr900rr,gabriell,glennwei,sausages,disco,pass1,lovebug,macmac,puffin,vanguard,trinitro,airwolf,aaa111,cocaine,cisco,datsun,bricks,bumper,eldorado,kidrock,wizard1,whiskers,wildwood,istheman,25802580,bigones,woodland,wolfpac,strawber,3030,sheba1,sixpack,peace1,physics,tigger2,toad,megan1,meow,ringo,amsterdam,717171,686868,5424,canuck,football1,footjob,fulham,seagull,orgy,lobo,mancity,vancouve,vauxhall,acidburn,derf,myspace1,boozer,buttercu,hola,minemine,munch,1dragon,biology,bestbuy,bigpoppa,blackout,blowfish,bmw325,bigbob,stream,talisman,tazz,sundevil,3333333,skate,shutup,shanghai,spencer1,slowhand,pinky1,tootie,thecrow,jubilee,jingle,matrix1,manowar,messiah,resident,redbaron,romans,andromed,athlon,beach1,badgers,guitars,harald,harddick,gotribe,6996,7grout,5wr2i7h8,635241,chase1,fallout,fiddle,fenris,francesc,fortuna,fairlane,felix1,gasman,fucks,sahara,sassy1,dogpound,dogbert,divx1,manila,pornporn,quasar,venom,987987,access1,clippers,daman,crusty,nathan1,nnnnnnnn,bruno1,budapest,kittens,kerouac,mother1,waldo1,whistler,whatwhat,wanderer,idontkno,1942,1946,bigdawg,bigpimp,zaqwsx,414141,3000gt,434343,serpent,smurf,pasword,thisisit,john1,robotics,redeye,rebelz,1011,alatam,asians,bama,banzai,harvest,575757,5329,fatty,fender1,flower2,funky,sambo,drummer1,dogcat,oedipus,osama,prozac,private1,rampage,concord,cinema,cornwall,cleaner,ciccio,clutch,corvet07,daemon,bruiser,boiler,hjkl,egghead,mordor,jamess,iverson3,bluesman,zouzou,090909,1002,stone1,4040,sexo,smith1,sperma,sneaky,polska,thewho,terminat,krypton,lekker,johnson1,johann,rockie,aspire,goodie,cheese1,fenway,fishon,fishin,fuckoff1,girls1,doomsday,pornking,ramones,rabbits,transit,aaaaa1,boyz,bookworm,bongo,bunnies,buceta,highbury,henry1,eastern,mischief,mopar,ministry,vienna,wildone,bigbooty,beavis1,xxxxxx1,yogibear,000001,0815,zulu,420000,sigmar,sprout,stalin,lkjhgfds,lagnaf,rolex,redfox,referee,123123123,1231,angus1,ballin,attila,greedy,grunt,747474,carpedie,caramel,foxylady,gatorade,futbol,frosch,saiyan,drums,donner,doggy1,drum,doudou,nutmeg,quebec,valdepen,tosser,tuscl,comein,cola,deadpool,bremen,hotass,hotmail1,eskimo,eggman,koko,kieran,katrin,kordell1,komodo,mone,munich,vvvvvvvv,jackson5,2222222,bergkamp,bigben,zanzibar,xxx123,sunny1,373737,slayer1,snoop,peachy,thecure,little1,jennaj,rasta69,1114,aries,havana,gratis,calgary,checkers,flanker,salope,dirty1,draco,dogface,luv2epus,rainbow6,qwerty123,umpire,turnip,vbnm,tucson,troll,codered,commande,neon,nico,nightwin,boomer1,bushido,hotmail0,enternow,keepout,karen1,mnbv,viewsoni,volcom,wizards,1995,berkeley,woodstoc,tarpon,shinobi,starstar,phat,toolbox,julien,johnny1,joebob,riders,reflex,120676,1235,angelus,anthrax,atlas,grandam,harlem,hawaii50,655321,cabron,challeng,callisto,firewall,firefire,flyer,flower1,gambler,frodo1,sam123,scania,dingo,papito,passmast,ou8123,randy1,twiggy,travis1,treetop,addict,admin1,963852,aceace,cirrus,bobdole,bonjovi,bootsy,boater,elway7,kenny1,moonshin,montag,wayne1,white1,jazzy,jakejake,1994,1991,2828,bluejays,belmont,sensei,southpark,peeper,pharao,pigpen,tomahawk,teensex,leedsutd,jeepster,jimjim,josephin,melons,matthias,robocop,1003,1027,antelope,azsxdc,gordo,hazard,granada,8989,7894,ceasar,cabernet,cheshire,chelle,candy1,fergie,fidelio,giorgio,fuckhead,dominion,qawsed,trucking,chloe1,daddyo,nostromo,boyboy,booster,bucky,honolulu,esquire,dynamite,mollydog,windows1,waffle,wealth,vincent1,jabber,jaguars,javelin,irishman,idefix,bigdog1,blue42,blanked,blue32,biteme1,bearcats,yessir,sylveste,sunfire,tbird,stryker,3ip76k2,sevens,pilgrim,tenchi,titman,leeds,lithium,linkin,marijuan,mariner,markie,midnite,reddwarf,1129,123asd,12312312,allstar,albany,asdf12,aspen,hardball,goldfing,7734,49ers,carnage,callum,carlos1,fitter,fandango,gofast,gamma,fucmy69,scrapper,dogwood,django,magneto,premium,9999999,abc1234,newyear,bookie,bounty,brown1,bologna,elway,killjoy,klondike,mouser,wayer,impreza,insomnia,24682468,2580,24242424,billbill,bellaco,blues1,blunts,teaser,sf49ers,shovel,solitude,spikey,pimpdadd,timeout,toffee,lefty,johndoe,johndeer,mega,manolo,ratman,robin1,1124,1210,1028,1226,babylove,barbados,gramma,646464,carpente,chaos1,fishbone,fireblad,frogs,screamer,scuba1,ducks,doggies,dicky,obsidian,rams,tottenham,aikman,comanche,corolla,cumslut,cyborg,boston1,houdini,helmut,elvisp,keksa12,monty1,wetter,watford,wiseguy,1989,1987,20202020,biatch,beezer,bigguns,blueball,bitchy,wyoming,yankees2,wrestler,stupid1,sealteam,sidekick,simple1,smackdow,sporting,spiral,smeller,plato,tophat,test2,toomuch,jello,junkie,maxim,maxime,meadow,remingto,roofer,124038,1018,1269,1227,123457,arkansas,aramis,beaker,barcelona,baltimor,googoo,goochi,852456,4711,catcher,champ1,fortress,fishfish,firefigh,geezer,rsalinas,samuel1,saigon,scooby1,dick1,doom,dontknow,magpies,manfred,vader1,universa,tulips,mygirl,bowtie,holycow,honeys,enforcer,waterboy,1992,23skidoo,bimbo,blue11,birddog,zildjian,030303,stinker,stoppedby,sexybabe,speakers,slugger,spotty,smoke1,polopolo,perfect1,torpedo,lakeside,jimmys,junior1,masamune,1214,april1,grinch,767676,5252,cherries,chipmunk,cezer121,carnival,capecod,finder,fearless,goats,funstuff,gideon,savior,seabee,sandro,schalke,salasana,disney1,duckman,pancake,pantera1,malice,love123,qwert123,tracer,creation,cwoui,nascar24,hookers,erection,ericsson,edthom,kokoko,kokomo,mooses,inter,1michael,1993,19781978,25252525,shibby,shamus,skibum,sheepdog,sex69,spliff,slipper,spoons,spanner,snowbird,toriamos,temp123,tennesse,lakers1,jomama,mazdarx7,recon,revolver,1025,1101,barney1,babycake,gotham,gravity,hallowee,616161,515000,caca,cannabis,chilli,fdsa,getout,fuck69,gators1,sable,rumble,dolemite,dork,duffer,dodgers1,onions,logger,lookout,magic32,poon,twat,coventry,citroen,civicsi,cocksucker,coochie,compaq1,nancy1,buzzer,boulder,butkus,bungle,hogtied,hotgirls,heidi1,eggplant,mustang6,monkey12,wapapapa,wendy1,volleyba,vibrate,blink,birthday4,xxxxx1,stephen1,suburban,sheeba,start1,soccer10,starcraft,soccer12,peanut1,plastics,penthous,peterbil,tetsuo,torino,tennis1,termite,lemmein,lakewood,jughead,melrose,megane,redone,angela1,goodgirl,gonzo1,golden1,gotyoass,656565,626262,capricor,chains,calvin1,getmoney,gabber,runaway,salami,dungeon,dudedude,opus,paragon,panhead,pasadena,opendoor,odyssey,magellan,printing,prince1,trustme,nono,buffet,hound,kajak,killkill,moto,winner1,vixen,whiteboy,versace,voyager1,indy,jackjack,bigal,beech,biggun,blake1,blue99,big1,synergy,success1,336699,sixty9,shark1,simba1,sebring,spongebo,spunk,springs,sliver,phialpha,password9,pizza1,pookey,tickling,lexingky,lawman,joe123,mike123,romeo1,redheads,apple123,backbone,aviation,green123,carlitos,byebye,cartman1,camden,chewy,camaross,favorite6,forumwp,ginscoot,fruity,sabrina1,devil666,doughnut,pantie,oldone,paintball,lumina,rainbow1,prosper,umbrella,ajax,951753,achtung,abc12345,compact,corndog,deerhunt,darklord,dank,nimitz,brandy1,hetfield,holein1,hillbill,hugetits,evolutio,kenobi,whiplash,wg8e3wjf,istanbul,invis,1996,bigjohn,bluebell,beater,benji,bluejay,xyzzy,suckdick,taichi,stellar,shaker,semper,splurge,squeak,pearls,playball,pooky,titfuck,joemama,johnny5,marcello,maxi,rhubarb,ratboy,reload,1029,1030,1220,bbking,baritone,gryphon,57chevy,494949,celeron,fishy,gladiator,fucker1,roswell,dougie,dicker,diva,donjuan,nympho,racers,truck1,trample,acer,cricket1,climax,denmark,cuervo,notnow,nittany,neutron,bosco1,buffa,breaker,hello2,hydro,kisskiss,kittys,montecar,modem,mississi,20012001,bigdick1,benfica,yahoo1,striper,tabasco,supra,383838,456654,seneca,shuttle,penguin1,pathfind,testibil,thethe,jeter2,marma,mark1,metoo,republic,rollin,redleg,redbone,redskin,1245,anthony7,altoids,barley,asswipe,bauhaus,bbbbbb1,gohome,harrier,golfpro,goldeney,818181,6666666,5000,5rxypn,cameron1,checker,calibra,freefree,faith1,fdm7ed,giraffe,giggles,fringe,scamper,rrpass1,screwyou,dimples,pacino,ontario,passthie,oberon,quest1,postov1000,puppydog,puffer,qwerty7,tribal,adam25,a1234567,collie,cleopatr,davide,namaste,buffalo1,bonovox,bukkake,burner,bordeaux,burly,hun999,enters,mohawk,vgirl,jayden,1812,1943,222333,bigjim,bigd,zoom,wordup,ziggy1,yahooo,workout,young1,xmas,zzzzzz1,surfer1,strife,sunlight,tasha1,skunk,sprinter,peaches1,pinetree,plum,pimping,theforce,thedon,toocool,laddie,lkjh,jupiter1,matty,redrose,1200,102938,antares,austin31,goose1,737373,78945612,789987,6464,calimero,caster,casper1,cement,chevrolet,chessie,caddy,canucks,fellatio,f00tball,gateway2,gamecube,rugby1,scheisse,dshade,dixie1,offshore,lucas1,macaroni,manga,pringles,puff,trouble1,ussy,coolhand,colonial,colt,darthvad,cygnusx1,natalie1,newark,hiking,errors,elcamino,koolaid,knight1,murphy1,volcano,idunno,2005,2233,blueberr,biguns,yamahar1,zapper,zorro1,0911,3006,sixsix,shopper,sextoy,snowboard,speedway,pokey,playboy2,titi,toonarmy,lambda,joecool,juniper,max123,mariposa,met2002,reggae,ricky1,1236,1228,1016,all4one,baberuth,asgard,484848,5683,6669,catnip,charisma,capslock,cashmone,galant,frenchy,gizmodo1,girlies,screwy,doubled,divers,dte4uw,dragonfl,treble,twinkie,tropical,crescent,cococo,dabomb,daffy,dandfa,cyrano,nathanie,boners,helium,hellas,espresso,killa,kikimora,w4g8at,ilikeit,iforget,1944,20002000,birthday1,beatles1,blue1,bigdicks,beethove,blacklab,blazers,benny1,woodwork,0069,0101,taffy,4567,shodan,pavlov,pinnacle,petunia,tito,teenie,lemonade,lalakers,lebowski,lalalala,ladyboy,jeeper,joyjoy,mercury1,mantle,mannn,rocknrol,riversid,123aaa,11112222,121314,1021,1004,1120,allen1,ambers,amstel,alice1,alleycat,allegro,ambrosia,gspot,goodsex,hattrick,harpoon,878787,8inches,4wwvte,cassandr,charlie123,gatsby,generic,gareth,fuckme2,samm,seadog,satchmo,scxakv,santafe,dipper,outoutout,madmad,london1,qbg26i,pussy123,tzpvaw,vamp,comp,cowgirl,coldplay,dawgs,nt5d27,novifarm,notredam,newness,mykids,bryan1,bouncer,hihihi,honeybee,iceman1,hotlips,dynamo,kappa,kahlua,muffy,mizzou,wannabe,wednesda,whatup,waterfal,willy1,bear1,billabon,youknow,yyyyyy1,zachary1,01234567,070462,zurich,superstar,stiletto,strat,427900,sigmachi,shells,sexy123,smile1,sophie1,stayout,somerset,playmate,pinkfloyd,phish1,payday,thebear,telefon,laetitia,kswbdu,jerky,metro,revoluti,1216,1201,1204,1222,1115,archange,barry1,handball,676767,chewbacc,furball,gocubs,fullback,gman,dewalt,dominiqu,diver1,dhip6a,olemiss,mandrake,mangos,pretzel,pusssy,tripleh,vagabond,clovis,dandan,csfbr5yy,deadspin,ninguna,ncc74656,bootsie,bp2002,bourbon,bumble,heyyou,houston1,hemlock,hippo,hornets,horseman,excess,extensa,muffin1,virginie,werdna,idontknow,jack1,1bitch,151nxjmt,bendover,bmwbmw,zaq123,wxcvbn,supernov,tahoe,shakur,sexyone,seviyi,smart1,speed1,pepito,phantom1,playoffs,terry1,terrier,laser1,lite,lancia,johngalt,jenjen,midori,maserati,matteo,miami1,riffraff,ronald1,1218,1026,123987,1015,1103,armada,architec,austria,gotmilk,cambridg,camero,flex,foreplay,getoff,glacier,glotest,froggie,gerbil,rugger,sanity72,donna1,orchard,oyster,palmtree,pajero,m5wkqf,magenta,luckyone,treefrog,vantage,usmarine,tyvugq,uptown,abacab,aaaaaa1,chuck1,darkange,cyclones,navajo,bubba123,iawgk2,hrfzlz,dylan1,enrico,encore,eclipse1,mutant,mizuno,mustang2,video1,viewer,weed420,whales,jaguar1,1990,159159,1love,bears1,bigtruck,bigboss,blitz,xqgann,yeahyeah,zeke,zardoz,stickman,3825,sentra,shiva,skipper1,singapor,southpaw,sonora,squid,slamdunk,slimjim,placid,photon,placebo,pearl1,test12,therock1,tiger123,leinad,legman,jeepers,joeblow,mike23,redcar,rhinos,rjw7x4,1102,13576479,112211,gwju3g,greywolf,7bgiqk,7878,535353,4snz9g,candyass,cccccc1,catfight,cali,fister,fosters,finland,frankie1,gizzmo,royalty,rugrat,dodo,oemdlg,out3xf,paddy,opennow,puppy1,qazwsxedc,ramjet,abraxas,cn42qj,dancer1,death666,nudity,nimda2k,buick,bobb,braves1,henrik,hooligan,everlast,karachi,mortis,monies,motocros,wally1,willie1,inspiron,1test,2929,bigblack,xytfu7,yackwin,zaq1xsw2,yy5rbfsc,100100,0660,tahiti,takehana,332211,3535,sedona,seawolf,skydiver,spleen,slash,spjfet,special1,slimshad,sopranos,spock1,penis1,patches1,thierry,thething,toohot,limpone,mash4077,matchbox,masterp,maxdog,ribbit,rockin,redhat,1113,14789632,1331,allday,aladin,andrey,amethyst,baseball1,athome,goofy1,greenman,goofball,ha8fyp,goodday,778899,charon,chappy,caracas,cardiff,capitals,canada1,cajun,catter,freddy1,favorite2,forme,forsaken,feelgood,gfxqx686,saskia,sanjose,salsa,dilbert1,dukeduke,downhill,longhair,locutus,lockdown,malachi,mamacita,lolipop,rainyday,pumpkin1,punker,prospect,rambo1,rainbows,quake,trinity1,trooper1,citation,coolcat,default,deniro,d9ungl,daddys,nautica,nermal,bukowski,bubbles1,bogota,buds,hulk,hitachi,ender,export,kikiki,kcchiefs,kram,morticia,montrose,mongo,waqw3p,wizzard,whdbtp,whkzyc,154ugeiu,1fuck,binky,bigred1,blubber,becky1,year2005,wonderfu,xrated,0001,tampabay,survey,tammy1,stuffer,3mpz4r,3000,3some,sierra1,shampoo,shyshy,slapnuts,standby,spartan1,sprocket,stanley1,poker1,theshit,lavalamp,light1,laserjet,jediknig,jjjjj1,mazda626,menthol,margaux,medic1,rhino1,1209,1234321,amigos,apricot,asdfgh1,hairball,hatter,grimace,7xm5rq,6789,cartoons,capcom,cashflow,carrots,fanatic,format,girlie,safeway,dogfart,dondon,outsider,odin,opiate,lollol,love12,mallrats,prague,primetime21,pugsley,r29hqq,valleywa,airman,abcdefg1,darkone,cummer,natedogg,nineball,ndeyl5,natchez,newone,normandy,nicetits,buddy123,buddys,homely,husky,iceland,hr3ytm,highlife,holla,earthlin,exeter,eatmenow,kimkim,k2trix,kernel,money123,moonman,miles1,mufasa,mousey,whites,warhamme,jackass1,2277,20spanks,blobby,blinky,bikers,blackjack,becca,blue23,xman,wyvern,085tzzqi,zxzxzx,zsmj2v,suede,t26gn4,sugars,tantra,swoosh,4226,4271,321123,383pdjvl,shane1,shelby1,spades,smother,sparhawk,pisser,photo1,pebble,peavey,pavement,thistle,kronos,lilbit,linux,melanie1,marbles,redlight,1208,1138,1008,alchemy,aolsucks,alexalex,atticus,auditt,b929ezzh,goodyear,gubber,863abgsg,7474,797979,464646,543210,4zqauf,4949,ch5nmk,carlito,chewey,carebear,checkmat,cheddar,chachi,forgetit,forlife,giants1,getit,gerhard,galileo,g3ujwg,ganja,rufus1,rushmore,discus,dudeman,olympus,oscars,osprey,madcow,locust,loyola,mammoth,proton,rabbit1,ptfe3xxp,pwxd5x,purple1,punkass,prophecy,uyxnyd,tyson1,aircraft,access99,abcabc,colts,civilwar,claudia1,contour,dddddd1,cypher,dapzu455,daisydog,noles,hoochie,hoser,eldiablo,kingrich,mudvayne,motown,mp8o6d,vipergts,italiano,2055,2211,bloke,blade1,yamato,zooropa,yqlgr667,050505,zxcvbnm1,zw6syj,suckcock,tango1,swampy,445566,333666,380zliki,sexpot,sexylady,sixtynin,sickboy,spiffy,skylark,sparkles,pintail,phreak,teller,timtim,thighs,latex,letsdoit,lkjhg,landmark,lizzard,marlins,marauder,metal1,manu,righton,1127,alain,alcat,amigo,basebal1,azertyui,azrael,hamper,gotenks,golfgti,hawkwind,h2slca,grace1,6chid8,789654,canine,casio,cazzo,cbr900,cabrio,calypso,capetown,feline,flathead,fisherma,flipmode,fungus,g9zns4,giggle,gabriel1,fuck123,saffron,dogmeat,dreamcas,dirtydog,douche,dresden,dickdick,destiny1,pappy,oaktree,luft4,puta,ramada,trumpet1,vcradq,tulip,tracy71,tycoon,aaaaaaa1,conquest,chitown,creepers,cornhole,danman,dada,density,d9ebk7,darth,nirvana1,nestle,brenda1,bonanza,hotspur,hufmqw,electro,erasure,elisabet,etvww4,ewyuza,eric1,kenken,kismet,klaatu,milamber,willi,isacs155,igor,1million,1letmein,x35v8l,yogi,ywvxpz,xngwoj,zippy1,020202,****,stonewal,sentry,sexsexsex,sonysony,smirnoff,star12,solace,star1,pkxe62,pilot1,pommes,paulpaul,tical,tictac,lighthou,lemans,kubrick,letmein22,letmesee,jys6wz,jonesy,jjjjjj1,jigga,redstorm,riley1,14141414,1126,allison1,badboy1,asthma,auggie,hardwood,gumbo,616913,57np39,56qhxs,4mnveh,fatluvr69,fqkw5m,fidelity,feathers,fresno,godiva,gecko,gibson1,gogators,general1,saxman,rowing,sammys,scotts,scout1,sasasa,samoht,dragon69,ducky,dragonball,driller,p3wqaw,papillon,oneone,openit,optimist,longshot,rapier,pussy2,ralphie,tuxedo,undertow,copenhag,delldell,culinary,deltas,mytime,noname,noles1,bucker,bopper,burnout,ibilltes,hihje863,hitter,ekim,espana,eatme69,elpaso,express1,eeeeee1,eatme1,karaoke,mustang5,wellingt,willem,waterski,webcam,jasons,infinite,iloveyou!,jakarta,belair,bigdad,beerme,yoshi,yinyang,x24ik3,063dyjuy,0000007,ztmfcq,stopit,stooges,symow8,strato,2hot4u,skins,shakes,sex1,snacks,softtail,slimed123,pizzaman,tigercat,tonton,lager,lizzy,juju,john123,jesse1,jingles,martian,mario1,rootedit,rochard,redwine,requiem,riverrat,1117,1014,1205,amor,amiga,alpina,atreides,banana1,bahamut,golfman,happines,7uftyx,5432,5353,5151,4747,foxfire,ffvdj474,foreskin,gayboy,gggggg1,gameover,glitter,funny1,scoobydoo,saxophon,dingbat,digimon,omicron,panda1,loloxx,macintos,lululu,lollypop,racer1,queen1,qwertzui,upnfmc,tyrant,trout1,9skw5g,aceman,acls2h,aaabbb,acapulco,aggie,comcast,cloudy,cq2kph,d6o8pm,cybersex,davecole,darian,crumbs,davedave,dasani,mzepab,myporn,narnia,booger1,bravo1,budgie,btnjey,highlander,hotel6,humbug,ewtosi,kristin1,kobe,knuckles,keith1,katarina,muff,muschi,montana1,wingchun,wiggle,whatthe,vette1,vols,virago,intj3a,ishmael,jachin,illmatic,199999,2010,blender,bigpenis,bengal,blue1234,zaqxsw,xray,xxxxxxx1,zebras,yanks,tadpole,stripes,3737,4343,3728,4444444,368ejhih,solar,sonne,sniffer,sonata,squirts,playstation,pktmxr,pescator,texaco,lesbos,l8v53x,jo9k2jw2,jimbeam,jimi,jupiter2,jurassic,marines1,rocket1,14725836,12345679,1219,123098,1233,alessand,althor,arch,alpha123,basher,barefeet,balboa,bbbbb1,badabing,gopack,golfnut,gsxr1000,gregory1,766rglqy,8520,753159,8dihc6,69camaro,666777,cheeba,chino,cheeky,camel1,fishcake,flubber,gianni,gnasher23,frisbee,fuzzy1,fuzzball,save13tx,russell1,sandra1,scrotum,scumbag,sabre,samdog,dripping,dragon12,dragster,orwell,mainland,maine,qn632o,poophead,rapper,porn4life,rapunzel,velocity,vanessa1,trueblue,vampire1,abacus,902100,crispy,chooch,d6wnro,dabulls,dehpye,navyseal,njqcw4,nownow,nigger1,nightowl,nonenone,nightmar,bustle,buddy2,boingo,bugman,bosshog,hybrid,hillside,hilltop,hotlegs,hzze929b,hhhhh1,hellohel,evilone,edgewise,e5pftu,eded,embalmer,excalibur,elefant,kenzie,killah,kleenex,mouses,mounta1n,motors,mutley,muffdive,vivitron,w00t88,iloveit,jarjar,incest,indycar,17171717,1664,17011701,222777,2663,beelch,benben,yitbos,yyyyy1,zzzzz1,stooge,tangerin,taztaz,stewart1,summer69,system1,surveyor,stirling,3qvqod,3way,456321,sizzle,simhrq,sparty,ssptx452,sphere,persian,ploppy,pn5jvw,poobear,pianos,plaster,testme,tiff,thriller,master12,rockey,1229,1217,1478,1009,anastasi,amonra,argentin,albino,azazel,grinder,6uldv8,83y6pv,8888888,4tlved,515051,carsten,flyers88,ffffff1,firehawk,firedog,flashman,ggggg1,godspeed,galway,giveitup,funtimes,gohan,giveme,geryfe,frenchie,sayang,rudeboy,sandals,dougal,drag0n,dga9la,desktop,onlyone,otter,pandas,mafia,luckys,lovelife,manders,qqh92r,qcmfd454,radar1,punani,ptbdhw,turtles,undertaker,trs8f7,ugejvp,abba,911turbo,acdc,abcd123,crash1,colony,delboy,davinci,notebook,nitrox,borabora,bonzai,brisbane,heeled,hooyah,hotgirl,i62gbq,horse1,hpk2qc,epvjb6,mnbvc,mommy1,munster,wiccan,2369,bettyboo,blondy,bismark,beanbag,bjhgfi,blackice,yvtte545,ynot,yess,zlzfrh,wolvie,007bond,******,tailgate,tanya1,sxhq65,stinky1,3234412,3ki42x,seville,shimmer,sienna,shitshit,skillet,sooners1,solaris,smartass,pedros,pennywis,pfloyd,tobydog,thetruth,letme1n,mario66,micky,rocky2,rewq,reindeer,1128,1207,1104,1432,aprilia,allstate,bagels,baggies,barrage,guru,72d5tn,606060,4wcqjn,chance1,flange,fartman,geil,gbhcf2,fussball,fuaqz4,gameboy,geneviev,rotary,seahawk,saab,samadams,devlt4,ditto,drevil,drinker,deuce,dipstick,octopus,ottawa,losangel,loverman,porky,q9umoz,rapture,pussy4me,triplex,ue8fpw,turbos,aaa340,churchil,crazyman,cutiepie,ddddd1,dejavu,cuxldv,nbvibt,nikon,niko,nascar1,bubba2,boobear,boogers,bullwink,bulldawg,horsemen,escalade,eagle2,dynamic,efyreg,minnesot,mogwai,msnxbi,mwq6qlzo,werder,verygood,voodoo1,iiiiii1,159951,1624,1911a1,2244,bellagio,bedlam,belkin,bill1,xirt2k,??????,susieq,sundown,sukebe,swifty,2fast4u,sexe,shroom,seaweed,skeeter1,snicker,spanky1,spook,phaedrus,pilots,peddler,thumper1,tiger7,tmjxn151,thematri,l2g7k3,letmeinn,jeffjeff,johnmish,mantra,mike69,mazda6,riptide,robots,1107,1130,142857,11001001,1134,armored,allnight,amatuers,bartok,astral,baboon,balls1,bassoon,hcleeb,happyman,granite,graywolf,golf1,gomets,8vjzus,7890,789123,8uiazp,5757,474jdvff,551scasi,50cent,camaro1,cherry1,chemist,firenze,fishtank,freewill,glendale,frogfrog,ganesh,scirocco,devilman,doodles,okinawa,olympic,orpheus,ohmygod,paisley,pallmall,lunchbox,manhatta,mahalo,mandarin,qwqwqw,qguvyt,pxx3eftp,rambler,poppy1,turk182,vdlxuc,tugboat,valiant,uwrl7c,chris123,cmfnpu,decimal,debbie1,dandy,daedalus,natasha1,nissan1,nancy123,nevermin,napalm,newcastle,bonghit,ibxnsm,hhhhhh1,holger,edmonton,equinox,dvader,kimmy,knulla,mustafa,monsoon,mistral,morgana,monica1,mojave,monterey,mrbill,vkaxcs,victor1,violator,vfdhif,wilson1,wavpzt,wildstar,winter99,iqzzt580,imback,1914,19741974,1monkey,1q2w3e4r5t,2500,2255,bigshow,bigbucks,blackcoc,zoomer,wtcacq,wobble,xmen,xjznq5,yesterda,yhwnqc,zzzxxx,393939,2fchbg,skinhead,skilled,shadow12,seaside,sinful,silicon,smk7366,snapshot,sniper1,soccer11,smutty,peepers,plokij,pdiddy,pimpdaddy,thrust,terran,topaz,today1,lionhear,littlema,lauren1,lincoln1,lgnu9d,juneau,methos,rogue1,romulus,redshift,1202,1469,12locked,arizona1,alfarome,al9agd,aol123,altec,apollo1,arse,baker1,bbb747,axeman,astro1,hawthorn,goodfell,hawks1,gstring,hannes,8543852,868686,4ng62t,554uzpad,5401,567890,5232,catfood,fire1,flipflop,fffff1,fozzie,fluff,fzappa,rustydog,scarab,satin,ruger,samsung1,destin,diablo2,dreamer1,detectiv,doqvq3,drywall,paladin1,papabear,offroad,panasonic,nyyankee,luetdi,qcfmtz,pyf8ah,puddles,pussyeat,ralph1,princeto,trivia,trewq,tri5a3,advent,9898,agyvorc,clarkie,coach1,courier,christo,chowder,cyzkhw,davidb,dad2ownu,daredevi,de7mdf,nazgul,booboo1,bonzo,butch1,huskers1,hgfdsa,hornyman,elektra,england1,elodie,kermit1,kaboom,morten,mocha,monday1,morgoth,weewee,weenie,vorlon,wahoo,ilovegod,insider,jayman,1911,1dallas,1900,1ranger,201jedlz,2501,1qaz,bignuts,bigbad,beebee,billows,belize,wvj5np,wu4etd,yamaha1,wrinkle5,zebra1,yankee1,zoomzoom,09876543,0311,?????,stjabn,tainted,3tmnej,skooter,skelter,starlite,spice1,stacey1,smithy,pollux,peternorth,pixie,piston,poets,toons,topspin,kugm7b,legends,jeepjeep,joystick,junkmail,jojojojo,jonboy,midland,mayfair,riches,reznor,rockrock,reboot,renee1,roadway,rasta220,1411,1478963,1019,archery,andyandy,barks,bagpuss,auckland,gooseman,hazmat,gucci,grammy,happydog,7kbe9d,7676,6bjvpe,5lyedn,5858,5291,charlie2,c7lrwu,candys,chateau,ccccc1,cardinals,fihdfv,fortune12,gocats,gaelic,fwsadn,godboy,gldmeo,fx3tuo,fubar1,generals,gforce,rxmtkp,rulz,sairam,dunhill,dogggg,ozlq6qwm,ov3ajy,lockout,makayla,macgyver,mallorca,prima,pvjegu,qhxbij,prelude1,totoro,tusymo,trousers,tulane,turtle1,tracy1,aerosmit,abbey1,clticic,cooper1,comets,delpiero,cyprus,dante1,dave1,nounours,nexus6,nogard,norfolk,brent1,booyah,bootleg,bulls23,bulls1,booper,heretic,icecube,hellno,hounds,honeydew,hooters1,hoes,hevnm4,hugohugo,epson,evangeli,eeeee1,eyphed".split(","))), p("english",s("you,i,to,the,a,and,that,it,of,me,what,is,in,this,know,i'm,for,no,have,my,don't,just,not,do,be,on,your,was,we,it's,with,so,but,all,well,are,he,oh,about,right,you're,get,here,out,going,like,yeah,if,her,she,can,up,want,think,that's,now,go,him,at,how,got,there,one,did,why,see,come,good,they,really,as,would,look,when,time,will,okay,back,can't,mean,tell,i'll,from,hey,were,he's,could,didn't,yes,his,been,or,something,who,because,some,had,then,say,ok,take,an,way,us,little,make,need,gonna,never,we're,too,she's,i've,sure,them,more,over,our,sorry,where,what's,let,thing,am,maybe,down,man,has,uh,very,by,there's,should,anything,said,much,any,life,even,off,doing,thank,give,only,thought,help,two,talk,people,god,still,wait,into,find,nothing,again,things,let's,doesn't,call,told,great,before,better,ever,night,than,away,first,believe,other,feel,everything,work,you've,fine,home,after,last,these,day,keep,does,put,around,stop,they're,i'd,guy,isn't,always,listen,wanted,mr,guys,huh,those,big,lot,happened,thanks,won't,trying,kind,wrong,through,talking,made,new,being,guess,hi,care,bad,mom,remember,getting,we'll,together,dad,leave,place,understand,wouldn't,actually,hear,baby,nice,father,else,stay,done,wasn't,their,course,might,mind,every,enough,try,hell,came,someone,you'll,own,family,whole,another,house,yourself,idea,ask,best,must,coming,old,looking,woman,which,years,room,left,knew,tonight,real,son,hope,name,same,went,um,hmm,happy,pretty,saw,girl,sir,show,friend,already,saying,next,three,job,problem,minute,found,world,thinking,haven't,heard,honey,matter,myself,couldn't,exactly,having,ah,probably,happen,we've,hurt,boy,both,while,dead,gotta,alone,since,excuse,start,kill,hard,you'd,today,car,ready,until,without,wants,hold,wanna,yet,seen,deal,took,once,gone,called,morning,supposed,friends,head,stuff,most,used,worry,second,part,live,truth,school,face,forget,true,business,each,cause,soon,knows,few,telling,wife,who's,use,chance,run,move,anyone,person,bye,somebody,dr,heart,such,miss,married,point,later,making,meet,anyway,many,phone,reason,damn,lost,looks,bring,case,turn,wish,tomorrow,kids,trust,check,change,end,late,anymore,five,least,town,aren't,ha,working,year,makes,taking,means,brother,play,hate,ago,says,beautiful,gave,fact,crazy,party,sit,open,afraid,between,important,rest,fun,kid,word,watch,glad,everyone,days,sister,minutes,everybody,bit,couple,whoa,either,mrs,feeling,daughter,wow,gets,asked,under,break,promise,door,set,close,hand,easy,question,tried,far,walk,needs,mine,though,times,different,killed,hospital,anybody,alright,wedding,shut,able,die,perfect,stand,comes,hit,story,ya,mm,waiting,dinner,against,funny,husband,almost,pay,answer,four,office,eyes,news,child,shouldn't,half,side,yours,moment,sleep,read,where's,started,men,sounds,sonny,pick,sometimes,em,bed,also,date,line,plan,hours,lose,hands,serious,behind,inside,high,ahead,week,wonderful,fight,past,cut,quite,number,he'll,sick,it'll,game,eat,nobody,goes,along,save,seems,finally,lives,worried,upset,carly,met,book,brought,seem,sort,safe,living,children,weren't,leaving,front,shot,loved,asking,running,clear,figure,hot,felt,six,parents,drink,absolutely,how's,daddy,alive,sense,meant,happens,special,bet,blood,ain't,kidding,lie,full,meeting,dear,seeing,sound,fault,water,ten,women,buy,months,hour,speak,lady,jen,thinks,christmas,body,order,outside,hang,possible,worse,company,mistake,ooh,handle,spend,totally,giving,control,here's,marriage,realize,president,unless,sex,send,needed,taken,died,scared,picture,talked,ass,hundred,changed,completely,explain,playing,certainly,sign,boys,relationship,loves,hair,lying,choice,anywhere,future,weird,luck,she'll,turned,known,touch,kiss,crane,questions,obviously,wonder,pain,calling,somewhere,throw,straight,cold,fast,words,food,none,drive,feelings,they'll,worked,marry,light,drop,cannot,sent,city,dream,protect,twenty,class,surprise,its,sweetheart,poor,looked,mad,except,gun,y'know,dance,takes,appreciate,especially,situation,besides,pull,himself,hasn't,act,worth,sheridan,amazing,top,given,expect,rather,involved,swear,piece,busy,law,decided,happening,movie,we'd,catch,country,less,perhaps,step,fall,watching,kept,darling,dog,win,air,honor,personal,moving,till,admit,problems,murder,he'd,evil,definitely,feels,information,honest,eye,broke,missed,longer,dollars,tired,evening,human,starting,red,entire,trip,club,niles,suppose,calm,imagine,fair,caught,blame,street,sitting,favor,apartment,court,terrible,clean,learn,works,frasier,relax,million,accident,wake,prove,smart,message,missing,forgot,interested,table,nbsp,become,mouth,pregnant,middle,ring,careful,shall,team,ride,figured,wear,shoot,stick,follow,angry,instead,write,stopped,early,ran,war,standing,forgive,jail,wearing,kinda,lunch,cristian,eight,greenlee,gotten,hoping,phoebe,thousand,ridge,paper,tough,tape,state,count,boyfriend,proud,agree,birthday,seven,they've,history,share,offer,hurry,feet,wondering,decision,building,ones,finish,voice,herself,would've,list,mess,deserve,evidence,cute,dress,interesting,hotel,quiet,concerned,road,staying,beat,sweetie,mention,clothes,finished,fell,neither,mmm,fix,respect,spent,prison,attention,holding,calls,near,surprised,bar,keeping,gift,hadn't,putting,dark,self,owe,using,ice,helping,normal,aunt,lawyer,apart,certain,plans,jax,girlfriend,floor,whether,everything's,present,earth,box,cover,judge,upstairs,sake,mommy,possibly,worst,station,acting,accept,blow,strange,saved,conversation,plane,mama,yesterday,lied,quick,lately,stuck,report,difference,rid,store,she'd,bag,bought,doubt,listening,walking,cops,deep,dangerous,buffy,sleeping,chloe,rafe,shh,record,lord,moved,join,card,crime,gentlemen,willing,window,return,walked,guilty,likes,fighting,difficult,soul,joke,favorite,uncle,promised,public,bother,island,seriously,cell,lead,knowing,broken,advice,somehow,paid,losing,push,helped,killing,usually,earlier,boss,beginning,liked,innocent,doc,rules,cop,learned,thirty,risk,letting,speaking,officer,ridiculous,support,afternoon,born,apologize,seat,nervous,across,song,charge,patient,boat,how'd,hide,detective,planning,nine,huge,breakfast,horrible,age,awful,pleasure,driving,hanging,picked,sell,quit,apparently,dying,notice,congratulations,chief,one's,month,visit,could've,c'mon,letter,decide,double,sad,press,forward,fool,showed,smell,seemed,spell,memory,pictures,slow,seconds,hungry,board,position,hearing,roz,kitchen,ma'am,force,fly,during,space,should've,realized,experience,kick,others,grab,mother's,discuss,third,cat,fifty,responsible,fat,reading,idiot,yep,suddenly,agent,destroy,bucks,track,shoes,scene,peace,arms,demon,low,livvie,consider,papers,medical,incredible,witch,drunk,attorney,tells,knock,ways,gives,department,nose,skye,turns,keeps,jealous,drug,sooner,cares,plenty,extra,tea,won,attack,ground,whose,outta,weekend,matters,wrote,type,father's,gosh,opportunity,impossible,books,waste,pretend,named,jump,eating,proof,complete,slept,career,arrest,breathe,perfectly,warm,pulled,twice,easier,goin,dating,suit,romantic,drugs,comfortable,finds,checked,fit,divorce,begin,ourselves,closer,ruin,although,smile,laugh,treat,god's,fear,what'd,guy's,otherwise,excited,mail,hiding,cost,stole,pacey,noticed,fired,excellent,lived,bringing,pop,bottom,note,sudden,bathroom,flight,honestly,sing,foot,games,remind,bank,charges,witness,finding,places,tree,dare,hardly,that'll,interest,steal,silly,contact,teach,shop,plus,colonel,fresh,trial,invited,roll,radio,reach,heh,choose,emergency,dropped,credit,obvious,cry,locked,loving,positive,nuts,agreed,prue,goodbye,condition,guard,fuckin,grow,cake,mood,dad's,total,crap,crying,belong,lay,partner,trick,pressure,ohh,arm,dressed,cup,lies,bus,taste,neck,south,something's,nurse,raise,lots,carry,group,whoever,drinking,they'd,breaking,file,lock,wine,closed,writing,spot,paying,study,assume,asleep,man's,turning,legal,viki,bedroom,shower,nikolas,camera,fill,reasons,forty,bigger,nope,breath,doctors,pants,level,movies,gee,area,folks,ugh,continue,focus,wild,truly,desk,convince,client,threw,band,hurts,spending,allow,grand,answers,shirt,chair,allowed,rough,doin,sees,government,ought,empty,round,hat,wind,shows,aware,dealing,pack,meaning,hurting,ship,subject,guest,mom's,pal,match,arrested,salem,confused,surgery,expecting,deacon,unfortunately,goddamn,lab,passed,bottle,beyond,whenever,pool,opinion,held,common,starts,jerk,secrets,falling,played,necessary,barely,dancing,health,tests,copy,cousin,planned,dry,ahem,twelve,simply,tess,skin,often,fifteen,speech,names,issue,orders,nah,final,results,code,believed,complicated,umm,research,nowhere,escape,biggest,restaurant,grateful,usual,burn,address,within,someplace,screw,everywhere,train,film,regret,goodness,mistakes,details,responsibility,suspect,corner,hero,dumb,terrific,further,gas,whoo,hole,memories,o'clock,following,ended,nobody's,teeth,ruined,split,airport,bite,stenbeck,older,liar,showing,project,cards,desperate,themselves,pathetic,damage,spoke,quickly,scare,marah,afford,vote,settle,mentioned,due,stayed,rule,checking,tie,hired,upon,heads,concern,blew,natural,alcazar,champagne,connection,tickets,happiness,form,saving,kissing,hated,personally,suggest,prepared,build,leg,onto,leaves,downstairs,ticket,it'd,taught,loose,holy,staff,sea,duty,convinced,throwing,defense,kissed,legs,according,loud,practice,saturday,babies,army,where'd,warning,miracle,carrying,flying,blind,ugly,shopping,hates,someone's,sight,bride,coat,account,states,clearly,celebrate,brilliant,wanting,add,forrester,lips,custody,center,screwed,buying,size,toast,thoughts,student,stories,however,professional,reality,birth,lexie,attitude,advantage,grandfather,sami,sold,opened,grandma,beg,changes,someday,grade,roof,brothers,signed,ahh,marrying,powerful,grown,grandmother,fake,opening,expected,eventually,must've,ideas,exciting,covered,familiar,bomb,bout,television,harmony,color,heavy,schedule,records,capable,practically,including,correct,clue,forgotten,immediately,appointment,social,nature,deserves,threat,bloody,lonely,ordered,shame,local,jacket,hook,destroyed,scary,investigation,above,invite,shooting,port,lesson,criminal,growing,caused,victim,professor,followed,funeral,nothing's,considering,burning,strength,loss,view,gia,sisters,everybody's,several,pushed,written,somebody's,shock,pushing,heat,chocolate,greatest,miserable,corinthos,nightmare,brings,zander,character,became,famous,enemy,crash,chances,sending,recognize,healthy,boring,feed,engaged,percent,headed,lines,treated,purpose,knife,rights,drag,san,fan,badly,hire,paint,pardon,built,behavior,closet,warn,gorgeous,milk,survive,forced,operation,offered,ends,dump,rent,remembered,lieutenant,trade,thanksgiving,rain,revenge,physical,available,program,prefer,baby's,spare,pray,disappeared,aside,statement,sometime,meat,fantastic,breathing,laughing,itself,tip,stood,market,affair,ours,depends,main,protecting,jury,national,brave,large,jack's,interview,fingers,murdered,explanation,process,picking,based,style,pieces,blah,assistant,stronger,aah,pie,handsome,unbelievable,anytime,nearly,shake,everyone's,oakdale,cars,wherever,serve,pulling,points,medicine,facts,waited,lousy,circumstances,stage,disappointed,weak,trusted,license,nothin,community,trash,understanding,slip,cab,sounded,awake,friendship,stomach,weapon,threatened,mystery,official,regular,river,vegas,understood,contract,race,basically,switch,frankly,issues,cheap,lifetime,deny,painting,ear,clock,weight,garbage,why'd,tear,ears,dig,selling,setting,indeed,changing,singing,tiny,particular,draw,decent,avoid,messed,filled,touched,score,people's,disappear,exact,pills,kicked,harm,recently,fortune,pretending,raised,insurance,fancy,drove,cared,belongs,nights,shape,lorelai,base,lift,stock,sonny's,fashion,timing,guarantee,chest,bridge,woke,source,patients,theory,original,burned,watched,heading,selfish,oil,drinks,failed,period,doll,committed,elevator,freeze,noise,exist,science,pair,edge,wasting,sat,ceremony,pig,uncomfortable,peg,guns,staring,files,bike,weather,name's,mostly,stress,permission,arrived,thrown,possibility,example,borrow,release,ate,notes,hoo,library,property,negative,fabulous,event,doors,screaming,xander,term,what're,meal,fellow,apology,anger,honeymoon,wet,bail,parking,non,protection,fixed,families,chinese,campaign,map,wash,stolen,sensitive,stealing,chose,lets,comfort,worrying,whom,pocket,mateo,bleeding,students,shoulder,ignore,fourth,neighborhood,fbi,talent,tied,garage,dies,demons,dumped,witches,training,rude,crack,model,bothering,radar,grew,remain,soft,meantime,gimme,connected,kinds,cast,sky,likely,fate,buried,hug,brother's,concentrate,prom,messages,east,unit,intend,crew,ashamed,somethin,manage,guilt,weapons,terms,interrupt,guts,tongue,distance,conference,treatment,shoe,basement,sentence,purse,glasses,cabin,universe,towards,repeat,mirror,wound,travers,tall,reaction,odd,engagement,therapy,letters,emotional,runs,magazine,jeez,decisions,soup,daughter's,thrilled,society,managed,stake,chef,moves,extremely,entirely,moments,expensive,counting,shots,kidnapped,square,son's,cleaning,shift,plate,impressed,smells,trapped,male,tour,aidan,knocked,charming,attractive,argue,puts,whip,language,embarrassed,settled,package,laid,animals,hitting,disease,bust,stairs,alarm,pure,nail,nerve,incredibly,walks,dirt,stamp,sister's,becoming,terribly,friendly,easily,damned,jobs,suffering,disgusting,stopping,deliver,riding,helps,federal,disaster,bars,dna,crossed,rate,create,trap,claim,california,talks,eggs,effect,chick,threatening,spoken,introduce,confession,embarrassing,bags,impression,gate,year's,reputation,attacked,among,knowledge,presents,inn,europe,chat,suffer,argument,talkin,crowd,homework,fought,coincidence,cancel,accepted,rip,pride,solve,hopefully,pounds,pine,mate,illegal,generous,streets,con,separate,outfit,maid,bath,punch,mayor,freaked,begging,recall,enjoying,bug,woman's,prepare,parts,wheel,signal,direction,defend,signs,painful,yourselves,rat,maris,amount,that'd,suspicious,flat,cooking,button,warned,sixty,pity,parties,crisis,coach,row,yelling,leads,awhile,pen,confidence,offering,falls,image,farm,pleased,panic,hers,gettin,role,refuse,determined,hell's,grandpa,progress,testify,passing,military,choices,uhh,gym,cruel,wings,bodies,mental,gentleman,coma,cutting,proteus,guests,girl's,expert,benefit,faces,cases,led,jumped,toilet,secretary,sneak,mix,firm,halloween,agreement,privacy,dates,anniversary,smoking,reminds,pot,created,twins,swing,successful,season,scream,considered,solid,options,commitment,senior,ill,else's,crush,ambulance,wallet,discovered,officially,til,rise,reached,eleven,option,laundry,former,assure,stays,skip,fail,accused,wide,challenge,popular,learning,discussion,clinic,plant,exchange,betrayed,bro,sticking,university,members,lower,bored,mansion,soda,sheriff,suite,handled,busted,senator,load,happier,younger,studying,romance,procedure,ocean,section,sec,commit,assignment,suicide,minds,swim,ending,bat,yell,llanview,league,chasing,seats,proper,command,believes,humor,hopes,fifth,winning,solution,leader,theresa's,sale,lawyers,nor,material,latest,highly,escaped,audience,parent,tricks,insist,dropping,cheer,medication,higher,flesh,district,routine,century,shared,sandwich,handed,false,beating,appear,warrant,family's,awfully,odds,article,treating,thin,suggesting,fever,sweat,silent,specific,clever,sweater,request,prize,mall,tries,mile,fully,estate,union,sharing,assuming,judgment,goodnight,divorced,despite,surely,steps,jet,confess,math,listened,comin,answered,vulnerable,bless,dreaming,rooms,chip,zero,potential,pissed,nate,kills,tears,knees,chill,carly's,brains,agency,harvard,degree,unusual,wife's,joint,packed,dreamed,cure,covering,newspaper,lookin,coast,grave,egg,direct,cheating,breaks,quarter,mixed,locker,husband's,gifts,awkward,toy,thursday,rare,policy,kid's,joking,competition,classes,assumed,reasonable,dozen,curse,quartermaine,millions,dessert,rolling,detail,alien,served,delicious,closing,vampires,released,ancient,wore,value,tail,secure,salad,murderer,hits,toward,spit,screen,offense,dust,conscience,bread,answering,admitted,lame,invitation,grief,smiling,path,stands,bowl,pregnancy,hollywood,prisoner,delivery,guards,virus,shrink,influence,freezing,concert,wreck,partners,massimo,chain,birds,life's,wire,technically,presence,blown,anxious,cave,version,holidays,cleared,wishes,survived,caring,candles,bound,related,charm,yup,pulse,jumping,jokes,frame,boom,vice,performance,occasion,silence,opera,nonsense,frightened,downtown,americans,slipped,dimera,blowing,world's,session,relationships,kidnapping,actual,spin,civil,roxy,packing,education,blaming,wrap,obsessed,fruit,torture,personality,location,effort,daddy's,commander,trees,there'll,owner,fairy,per,other's,necessarily,county,contest,seventy,print,motel,fallen,directly,underwear,grams,exhausted,believing,particularly,freaking,carefully,trace,touching,messing,committee,recovery,intention,consequences,belt,sacrifice,courage,officers,enjoyed,lack,attracted,appears,bay,yard,returned,remove,nut,carried,today's,testimony,intense,granted,violence,heal,defending,attempt,unfair,relieved,political,loyal,approach,slowly,plays,normally,buzz,alcohol,actor,surprises,psychiatrist,pre,plain,attic,who'd,uniform,terrified,sons,pet,cleaned,zach,threaten,teaching,mum,motion,fella,enemies,desert,collection,incident,failure,satisfied,imagination,hooked,headache,forgetting,counselor,andie,acted,opposite,highest,equipment,badge,italian,visiting,naturally,frozen,commissioner,sakes,labor,appropriate,trunk,armed,thousands,received,dunno,costume,temporary,sixteen,impressive,zone,kicking,junk,hon,grabbed,unlike,understands,describe,clients,owns,affect,witnesses,starving,instincts,happily,discussing,deserved,strangers,leading,intelligence,host,authority,surveillance,cow,commercial,admire,questioning,fund,dragged,barn,object,deeply,amp,wrapped,wasted,tense,route,reports,hoped,fellas,election,roommate,mortal,fascinating,chosen,stops,shown,arranged,abandoned,sides,delivered,becomes,arrangements,agenda,began,theater,series,literally,propose,honesty,underneath,forces,services,sauce,promises,lecture,eighty,torn,shocked,relief,explained,counter,circle,victims,transfer,response,channel,identity,differently,campus,spy,ninety,interests,guide,deck,biological,pheebs,ease,creep,will's,waitress,skills,telephone,ripped,raising,scratch,rings,prints,wave,thee,arguing,figures,ephram,asks,reception,pin,oops,diner,annoying,agents,taggert,goal,mass,ability,sergeant,julian's,international,gig,blast,basic,tradition,towel,earned,rub,president's,habit,customers,creature,bermuda,actions,snap,react,prime,paranoid,wha,handling,eaten,therapist,comment,charged,tax,sink,reporter,beats,priority,interrupting,gain,fed,warehouse,shy,pattern,loyalty,inspector,events,pleasant,media,excuses,threats,permanent,guessing,financial,demand,assault,tend,praying,motive,los,unconscious,trained,museum,tracks,range,nap,mysterious,unhappy,tone,switched,rappaport,award,sookie,neighbor,loaded,gut,childhood,causing,swore,piss,hundreds,balance,background,toss,mob,misery,valentine's,thief,squeeze,lobby,hah,goa'uld,geez,exercise,ego,drama,al's,forth,facing,booked,boo,songs,sandburg,eighteen,d'you,bury,perform,everyday,digging,creepy,compared,wondered,trail,liver,hmmm,drawn,device,magical,journey,fits,discussed,supply,moral,helpful,attached,timmy's,searching,flew,depressed,aisle,underground,pro,daughters,cris,amen,vows,proposal,pit,neighbors,darn,cents,arrange,annulment,uses,useless,squad,represent,product,joined,afterwards,adventure,resist,protected,net,fourteen,celebrating,piano,inch,flag,debt,violent,tag,sand,gum,dammit,teal'c,hip,celebration,below,reminded,claims,tonight's,replace,phones,paperwork,emotions,typical,stubborn,stable,sheridan's,pound,papa,lap,designed,current,bum,tension,tank,suffered,steady,provide,overnight,meanwhile,chips,beef,wins,suits,boxes,salt,cassadine,collect,boy's,tragedy,therefore,spoil,realm,profile,degrees,wipe,surgeon,stretch,stepped,nephew,neat,limo,confident,anti,perspective,designer,climb,title,suggested,punishment,finest,ethan's,springfield,occurred,hint,furniture,blanket,twist,surrounded,surface,proceed,lip,fries,worries,refused,niece,gloves,soap,signature,disappoint,crawl,convicted,zoo,result,pages,lit,flip,counsel,doubts,crimes,accusing,when's,shaking,remembering,phase,hallway,halfway,bothered,useful,makeup,madam,gather,concerns,cia,cameras,blackmail,symptoms,rope,ordinary,imagined,concept,cigarette,supportive,memorial,explosion,yay,woo,trauma,ouch,leo's,furious,cheat,avoiding,whew,thick,oooh,boarding,approve,urgent,shhh,misunderstanding,minister,drawer,sin,phony,joining,jam,interfere,governor,chapter,catching,bargain,tragic,schools,respond,punish,penthouse,hop,thou,remains,rach,ohhh,insult,doctor's,bugs,beside,begged,absolute,strictly,stefano,socks,senses,ups,sneaking,yah,serving,reward,polite,checks,tale,physically,instructions,fooled,blows,tabby,internal,bitter,adorable,y'all,tested,suggestion,string,jewelry,debate,com,alike,pitch,fax,distracted,shelter,lessons,foreign,average,twin,friend's,damnit,constable,circus,audition,tune,shoulders,mud,mask,helpless,feeding,explains,dated,robbery,objection,behave,valuable,shadows,courtroom,confusing,tub,talented,struck,smarter,mistaken,italy,customer,bizarre,scaring,punk,motherfucker,holds,focused,alert,activity,vecchio,reverend,highway,foolish,compliment,bastards,attend,scheme,aid,worker,wheelchair,protective,poetry,gentle,script,reverse,picnic,knee,intended,construction,cage,wednesday,voices,toes,stink,scares,pour,effects,cheated,tower,time's,slide,ruining,recent,jewish,filling,exit,cottage,corporate,upside,supplies,proves,parked,instance,grounds,diary,complaining,basis,wounded,thing's,politics,confessed,pipe,merely,massage,data,chop,budget,brief,spill,prayer,costs,betray,begins,arrangement,waiter,scam,rats,fraud,flu,brush,anyone's,adopted,tables,sympathy,pill,pee,web,seventeen,landed,expression,entrance,employee,drawing,cap,bracelet,principal,pays,jen's,fairly,facility,dru,deeper,arrive,unique,tracking,spite,shed,recommend,oughta,nanny,naive,menu,grades,diet,corn,authorities,separated,roses,patch,dime,devastated,description,tap,subtle,include,citizen,bullets,beans,ric,pile,las,executive,confirm,toe,strings,parade,harbor,charity's,bow,borrowed,toys,straighten,steak,status,remote,premonition,poem,planted,honored,youth,specifically,meetings,exam,convenient,traveling,matches,laying,insisted,apply,units,technology,dish,aitoro,sis,kindly,grandson,donor,temper,teenager,strategy,richard's,proven,iron,denial,couples,backwards,tent,swell,noon,happiest,episode,drives,thinkin,spirits,potion,fence,affairs,acts,whatsoever,rehearsal,proved,overheard,nuclear,lemme,hostage,faced,constant,bench,tryin,taxi,shove,sets,moron,limits,impress,entitled,needle,limit,lad,intelligent,instant,forms,disagree,stinks,rianna,recover,paul's,losers,groom,gesture,developed,constantly,blocks,bartender,tunnel,suspects,sealed,removed,legally,illness,hears,dresses,aye,vehicle,thy,teachers,sheet,receive,psychic,night's,denied,knocking,judging,bible,behalf,accidentally,waking,ton,superior,seek,rumor,natalie's,manners,homeless,hollow,desperately,critical,theme,tapes,referring,personnel,item,genoa,gear,majesty,fans,exposed,cried,tons,spells,producer,launch,instinct,belief,quote,motorcycle,convincing,appeal,advance,greater,fashioned,aids,accomplished,mommy's,grip,bump,upsetting,soldiers,scheduled,production,needing,invisible,forgiveness,feds,complex,compare,bothers,tooth,territory,sacred,mon,jessica's,inviting,inner,earn,compromise,cocktail,tramp,temperature,signing,landing,jabot,intimate,dignity,dealt,souls,informed,gods,entertainment,dressing,cigarettes,blessing,billion,alistair,upper,manner,lightning,leak,heaven's,fond,corky,alternative,seduce,players,operate,modern,liquor,fingerprints,enchantment,butters,stuffed,stavros,rome,filed,emotionally,division,conditions,uhm,transplant,tips,passes,oxygen,nicely,lunatic,hid,drill,designs,complain,announcement,visitors,unfortunate,slap,prayers,plug,organization,opens,oath,o'neill,mutual,graduate,confirmed,broad,yacht,spa,remembers,fried,extraordinary,bait,appearance,abuse,warton,sworn,stare,safely,reunion,plot,burst,aha,might've,experiment,dive,commission,cells,aboard,returning,independent,expose,environment,buddies,trusting,smaller,mountains,booze,sweep,sore,scudder,properly,parole,manhattan,effective,ditch,decides,canceled,bra,antonio's,speaks,spanish,reaching,glow,foundation,women's,wears,thirsty,skull,ringing,dorm,dining,bend,unexpected,systems,sob,pancakes,michael's,harsh,flattered,existence,ahhh,troubles,proposed,fights,favourite,eats,driven,computers,rage,luke's,causes,border,undercover,spoiled,sloane,shine,rug,identify,destroying,deputy,deliberately,conspiracy,clothing,thoughtful,similar,sandwiches,plates,nails,miracles,investment,fridge,drank,contrary,beloved,allergic,washed,stalking,solved,sack,misses,hope's,forgiven,erica's,cuz,bent,approval,practical,organized,maciver,involve,industry,fuel,dragging,cooked,possession,pointing,foul,editor,dull,beneath,ages,horror,heels,grass,faking,deaf,stunt,portrait,painted,jealousy,hopeless,fears,cuts,conclusion,volunteer,scenario,satellite,necklace,men's,crashed,chapel,accuse,restraining,jason's,humans,homicide,helicopter,formal,firing,shortly,safer,devoted,auction,videotape,tore,stores,reservations,pops,appetite,anybody's,wounds,vanquish,symbol,prevent,patrol,ironic,flow,fathers,excitement,anyhow,tearing,sends,sam's,rape,laughed,function,core,charmed,whatever's,sub,lucy's,dealer,cooperate,bachelor,accomplish,wakes,struggle,spotted,sorts,reservation,ashes,yards,votes,tastes,supposedly,loft,intentions,integrity,wished,towels,suspected,slightly,qualified,log,investigating,inappropriate,immediate,companies,backed,pan,owned,lipstick,lawn,compassion,cafeteria,belonged,affected,scarf,precisely,obsession,management,loses,lighten,jake's,infection,granddaughter,explode,chemistry,balcony,this'll,storage,spying,publicity,exists,employees,depend,cue,cracked,conscious,aww,ally,ace,accounts,absurd,vicious,tools,strongly,rap,invented,forbid,directions,defendant,bare,announce,alcazar's,screwing,salesman,robbed,leap,lakeview,insanity,injury,genetic,document,why's,reveal,religious,possibilities,kidnap,gown,entering,chairs,wishing,statue,setup,serial,punished,dramatic,dismissed,criminals,seventh,regrets,raped,quarters,produce,lamp,dentist,anyways,anonymous,added,semester,risks,regarding,owes,magazines,machines,lungs,explaining,delicate,child's,tricked,oldest,liv,eager,doomed,cafe,bureau,adoption,traditional,surrender,stab,sickness,scum,loop,independence,generation,floating,envelope,entered,combination,chamber,worn,vault,sorel,pretended,potatoes,plea,photograph,payback,misunderstood,kiddo,healing,cascade,capeside,application,stabbed,remarkable,cabinet,brat,wrestling,sixth,scale,privilege,passionate,nerves,lawsuit,kidney,disturbed,crossing,cozy,associate,tire,shirts,required,posted,oven,ordering,mill,journal,gallery,delay,clubs,risky,nest,monsters,honorable,grounded,favour,culture,closest,brenda's,breakdown,attempted,tony's,placed,conflict,bald,actress,abandon,steam,scar,pole,duh,collar,worthless,standards,resources,photographs,introduced,injured,graduation,enormous,disturbing,disturb,distract,deals,conclusions,vodka,situations,require,mid,measure,dishes,crawling,congress,children's,briefcase,wiped,whistle,sits,roast,rented,pigs,greek,flirting,existed,deposit,damaged,bottles,vanessa's,types,topic,riot,overreacting,minimum,logical,impact,hostile,embarrass,casual,beacon,amusing,altar,values,recognized,maintain,goods,covers,claus,battery,survival,skirt,shave,prisoners,porch,med,ghosts,favors,drops,dizzy,chili,begun,beaten,advise,transferred,strikes,rehab,raw,photographer,peaceful,leery,heavens,fortunately,fooling,expectations,draft,citizens,weakness,ski,ships,ranch,practicing,musical,movement,individual,homes,executed,examine,documents,cranes,column,bribe,task,species,sail,rum,resort,prescription,operating,hush,fragile,forensics,expense,drugged,differences,cows,conduct,comic,bells,avenue,attacking,assigned,visitor,suitcase,sources,sorta,scan,payment,motor,mini,manticore,inspired,insecure,imagining,hardest,clerk,yea,wrist,what'll,tube,starters,silk,pump,pale,nicer,haul,flies,demands,boot,arts,african,there'd,limited,how're,elders,connections,quietly,pulls,idiots,factor,erase,denying,attacks,ankle,amnesia,accepting,ooo,heartbeat,gal,devane,confront,backing,phrase,operations,minus,meets,legitimate,hurricane,fixing,communication,boats,auto,arrogant,supper,studies,slightest,sins,sayin,recipe,pier,paternity,humiliating,genuine,catholic,snack,rational,pointed,minded,guessed,grace's,display,dip,brooke's,advanced,weddings,unh,tumor,teams,reported,humiliated,destruction,copies,closely,bid,aspirin,academy,wig,throughout,spray,occur,logic,eyed,equal,drowning,contacts,shakespeare,ritual,perfume,kelly's,hiring,hating,generally,error,elected,docks,creatures,visions,thanking,thankful,sock,replaced,nineteen,nick's,fork,comedy,analysis,yale,throws,teenagers,studied,stressed,slice,rolls,requires,plead,ladder,kicks,detectives,assured,alison's,widow,tomorrow's,tissue,tellin,shallow,responsibilities,repay,rejected,permanently,girlfriends,deadly,comforting,ceiling,bonus,verdict,maintenance,jar,insensitive,factory,aim,triple,spilled,respected,recovered,messy,interrupted,halliwell,car's,bleed,benefits,wardrobe,takin,significant,objective,murders,doo,chart,backs,workers,waves,underestimate,ties,registered,multiple,justify,harmless,frustrated,fold,enzo,convention,communicate,bugging,attraction,arson,whack,salary,rumors,residence,party's,obligation,medium,liking,laura's,development,develop,dearest,david's,danny's,congratulate,vengeance,switzerland,severe,rack,puzzle,puerto,guidance,fires,courtesy,caller,blamed,tops,repair,quiz,prep,now's,involves,headquarters,curiosity,codes,circles,barbecue,troops,sunnydale,spinning,scores,pursue,psychotic,cough,claimed,accusations,shares,resent,money's,laughs,gathered,freshman,envy,drown,cristian's,bartlet,asses,sofa,scientist,poster,islands,highness,dock,apologies,welfare,victor's,theirs,stat,stall,spots,somewhat,ryan's,realizes,psych,fools,finishing,album,wee,understandable,unable,treats,theatre,succeed,stir,relaxed,makin,inches,gratitude,faithful,bin,accent,zip,witter,wandering,regardless,que,locate,inevitable,gretel,deed,crushed,controlling,taxes,smelled,settlement,robe,poet,opposed,marked,greenlee's,gossip,gambling,determine,cuba,cosmetics,cent,accidents,surprising,stiff,sincere,shield,rushed,resume,reporting,refrigerator,reference,preparing,nightmares,mijo,ignoring,hunch,fog,fireworks,drowned,crown,cooperation,brass,accurate,whispering,sophisticated,religion,luggage,investigate,hike,explore,emotion,creek,crashing,contacted,complications,ceo,acid,shining,rolled,righteous,reconsider,inspiration,goody,geek,frightening,festival,ethics,creeps,courthouse,camping,assistance,affection,vow,smythe,protest,lodge,haircut,forcing,essay,chairman,baked,apologized,vibe,respects,receipt,mami,includes,hats,exclusive,destructive,define,defeat,adore,adopt,voted,tracked,signals,shorts,rory's,reminding,relative,ninth,floors,dough,creations,continues,cancelled,cabot,barrel,adam's,snuck,slight,reporters,rear,pressing,novel,newspapers,magnificent,madame,lazy,glorious,fiancee,candidate,brick,bits,australia,activities,visitation,scholarship,sane,previous,kindness,ivy's,shoulda,rescued,mattress,maria's,lounge,lifted,label,importantly,glove,enterprises,driver's,disappointment,condo,cemetery,beings,admitting,yelled,waving,screech,satisfaction,requested,reads,plants,nun,nailed,described,dedicated,certificate,centuries,annual,worm,tick,resting,primary,polish,marvelous,fuss,funds,defensive,cortlandt,compete,chased,provided,pockets,luckily,lilith,filing,depression,conversations,consideration,consciousness,worlds,innocence,indicate,grandmother's,forehead,bam,appeared,aggressive,trailer,slam,retirement,quitting,pry,person's,narrow,levels,kay's,inform,encourage,dug,delighted,daylight,danced,currently,confidential,billy's,ben's,aunts,washing,vic,tossed,spectra,rick's,permit,marrow,lined,implying,hatred,grill,efforts,corpse,clues,sober,relatives,promotion,offended,morgue,larger,infected,humanity,eww,emily's,electricity,electrical,distraction,cart,broadcast,wired,violation,suspended,promising,harassment,glue,gathering,d'angelo,cursed,controlled,calendar,brutal,assets,warlocks,wagon,unpleasant,proving,priorities,observation,mustn't,lease,grows,flame,domestic,disappearance,depressing,thrill,sitter,ribs,offers,naw,flush,exception,earrings,deadline,corporal,collapsed,update,snapped,smack,orleans,offices,melt,figuring,delusional,coulda,burnt,actors,trips,tender,sperm,specialist,scientific,realise,pork,popped,planes,kev,interrogation,institution,included,esteem,communications,choosing,choir,undo,pres,prayed,plague,manipulate,lifestyle,insulting,honour,detention,delightful,coffeehouse,chess,betrayal,apologizing,adjust,wrecked,wont,whipped,rides,reminder,psychological,principle,monsieur,injuries,fame,faint,confusion,christ's,bon,bake,nearest,korea,industries,execution,distress,definition,creating,correctly,complaint,blocked,trophy,tortured,structure,rot,risking,pointless,household,heir,handing,eighth,dumping,cups,chloe's,alibi,absence,vital,tokyo,thus,struggling,shiny,risked,refer,mummy,mint,joey's,involvement,hose,hobby,fortunate,fleischman,fitting,curtain,counseling,addition,wit,transport,technical,rode,puppet,opportunities,modeling,memo,irresponsible,humiliation,hiya,freakin,fez,felony,choke,blackmailing,appreciated,tabloid,suspicion,recovering,rally,psychology,pledge,panicked,nursery,louder,jeans,investigator,identified,homecoming,helena's,height,graduated,frustrating,fabric,distant,buys,busting,buff,wax,sleeve,products,philosophy,irony,hospitals,dope,declare,autopsy,workin,torch,substitute,scandal,prick,limb,leaf,lady's,hysterical,growth,goddamnit,fetch,dimension,day's,crowded,clip,climbing,bonding,approved,yeh,woah,ultimately,trusts,returns,negotiate,millennium,majority,lethal,length,iced,deeds,bore,babysitter,questioned,outrageous,medal,kiriakis,insulted,grudge,established,driveway,deserted,definite,capture,beep,wires,suggestions,searched,owed,originally,nickname,lighting,lend,drunken,demanding,costanza,conviction,characters,bumped,weigh,touches,tempted,shout,resolve,relate,poisoned,pip,phoebe's,pete's,occasionally,molly's,meals,maker,invitations,haunted,fur,footage,depending,bogus,autograph,affects,tolerate,stepping,spontaneous,sleeps,probation,presentation,performed,manny,identical,fist,cycle,associates,aaron's,streak,spectacular,sector,lasted,isaac's,increase,hostages,heroin,havin,habits,encouraging,cult,consult,burgers,boyfriends,bailed,baggage,association,wealthy,watches,versus,troubled,torturing,teasing,sweetest,stations,sip,shawn's,rag,qualities,postpone,pad,overwhelmed,malkovich,impulse,hut,follows,classy,charging,barbara's,angel's,amazed,scenes,rising,revealed,representing,policeman,offensive,mug,hypocrite,humiliate,hideous,finals,experiences,d'ya,courts,costumes,captured,bluffing,betting,bein,bedtime,alcoholic,vegetable,tray,suspicions,spreading,splendid,shouting,roots,pressed,nooo,liza's,jew,intent,grieving,gladly,fling,eliminate,disorder,courtney's,cereal,arrives,aaah,yum,technique,statements,sonofabitch,servant,roads,republican,paralyzed,orb,lotta,locks,guaranteed,european,dummy,discipline,despise,dental,corporation,carries,briefing,bluff,batteries,atmosphere,whatta,tux,sounding,servants,rifle,presume,kevin's,handwriting,goals,gin,fainted,elements,dried,cape,allright,allowing,acknowledge,whacked,toxic,skating,reliable,quicker,penalty,panel,overwhelming,nearby,lining,importance,harassing,fatal,endless,elsewhere,dolls,convict,bold,ballet,whatcha,unlikely,spiritual,shutting,separation,recording,positively,overcome,goddam,failing,essence,dose,diagnosis,cured,claiming,bully,airline,ahold,yearbook,various,tempting,shelf,rig,pursuit,prosecution,pouring,possessed,partnership,miguel's,lindsay's,countries,wonders,tsk,thorough,spine,rath,psychiatric,meaningless,latte,jammed,ignored,fiance,exposure,exhibit,evidently,duties,contempt,compromised,capacity,cans,weekends,urge,theft,suing,shipment,scissors,responding,refuses,proposition,noises,matching,located,ink,hormones,hiv,hail,grandchildren,godfather,gently,establish,crane's,contracts,compound,buffy's,worldwide,smashed,sexually,sentimental,senor,scored,patient's,nicest,marketing,manipulated,jaw,intern,handcuffs,framed,errands,entertaining,discovery,crib,carriage,barge,awards,attending,ambassador,videos,tab,spends,slipping,seated,rubbing,rely,reject,recommendation,reckon,ratings,headaches,float,embrace,corners,whining,sweating,sole,skipped,restore,receiving,population,pep,mountie,motives,mama's,listens,korean,heroes,heart's,cristobel,controls,cheerleader,balsom,unnecessary,stunning,shipping,scent,santa's,quartermaines,praise,pose,montega,luxury,loosen,kyle's,keri's,info,hum,haunt,gracious,git,forgiving,fleet,errand,emperor,cakes,blames,abortion,worship,theories,strict,sketch,shifts,plotting,physician,perimeter,passage,pals,mere,mattered,lonigan,longest,jews,interference,eyewitness,enthusiasm,encounter,diapers,craig's,artists,strongest,shaken,serves,punched,projects,portal,outer,nazi,hal's,colleagues,catches,bearing,backyard,academic,winds,terrorists,sabotage,pea,organs,needy,mentor,measures,listed,lex,cuff,civilization,caribbean,articles,writes,woof,who'll,viki's,valid,rarely,rabbi,prank,performing,obnoxious,mates,improve,hereby,gabby,faked,cellar,whitelighter,void,substance,strangle,sour,skill,senate,purchase,native,muffins,interfering,hoh,gina's,demonic,colored,clearing,civilian,buildings,boutique,barrington,trading,terrace,smoked,seed,righty,relations,quack,published,preliminary,petey,pact,outstanding,opinions,knot,ketchup,items,examined,disappearing,cordy,coin,circuit,assist,administration,walt,uptight,ticking,terrifying,tease,tabitha's,syd,swamp,secretly,rejection,reflection,realizing,rays,pennsylvania,partly,mentally,marone,jurisdiction,frasier's,doubted,deception,crucial,congressman,cheesy,arrival,visited,supporting,stalling,scouts,scoop,ribbon,reserve,raid,notion,income,immune,grandma's,expects,edition,destined,constitution,classroom,bets,appreciation,appointed,accomplice,whitney's,wander,shoved,sewer,scroll,retire,paintings,lasts,fugitive,freezer,discount,cranky,crank,clearance,bodyguard,anxiety,accountant,abby's,whoops,volunteered,terrorist,tales,talents,stinking,resolved,remotely,protocol,livvie's,garlic,decency,cord,beds,asa's,areas,altogether,uniforms,tremendous,restaurants,rank,profession,popping,philadelphia,outa,observe,lung,largest,hangs,feelin,experts,enforcement,encouraged,economy,dudes,donation,disguise,diane's,curb,continued,competitive,businessman,bites,antique,advertising,ads,toothbrush,retreat,represents,realistic,profits,predict,nora's,lid,landlord,hourglass,hesitate,frank's,focusing,equally,consolation,boyfriend's,babbling,aged,troy's,tipped,stranded,smartest,sabrina's,rhythm,replacement,repeating,puke,psst,paycheck,overreacted,macho,leadership,kendall's,juvenile,john's,images,grocery,freshen,disposal,cuffs,consent,caffeine,arguments,agrees,abigail's,vanished,unfinished,tobacco,tin,syndrome,ripping,pinch,missiles,isolated,flattering,expenses,dinners,cos,colleague,ciao,buh,belthazor,belle's,attorneys,amber's,woulda,whereabouts,wars,waitin,visits,truce,tripped,tee,tasted,stu,steer,ruling,poisoning,nursing,manipulative,immature,husbands,heel,granddad,delivering,deaths,condoms,automatically,anchor,trashed,tournament,throne,raining,prices,pasta,needles,leaning,leaders,judges,ideal,detector,coolest,casting,batch,approximately,appointments,almighty,achieve,vegetables,sum,spark,ruled,revolution,principles,perfection,pains,momma,mole,interviews,initiative,hairs,getaway,employment,den,cracking,counted,compliments,behold,verge,tougher,timer,tapped,taped,stakes,specialty,snooping,shoots,semi,rendezvous,pentagon,passenger,leverage,jeopardize,janitor,grandparents,forbidden,examination,communist,clueless,cities,bidding,arriving,adding,ungrateful,unacceptable,tutor,soviet,shaped,serum,scuse,savings,pub,pajamas,mouths,modest,methods,lure,irrational,depth,cries,classified,bombs,beautifully,arresting,approaching,vessel,variety,traitor,sympathetic,smug,smash,rental,prostitute,premonitions,mild,jumps,inventory,ing,improved,grandfather's,developing,darlin,committing,caleb's,banging,asap,amendment,worms,violated,vent,traumatic,traced,tow,swiss,sweaty,shaft,recommended,overboard,literature,insight,healed,grasp,fluid,experiencing,crappy,crab,connecticut,chunk,chandler's,awww,applied,witnessed,traveled,stain,shack,reacted,pronounce,presented,poured,occupied,moms,marriages,jabez,invested,handful,gob,gag,flipped,fireplace,expertise,embarrassment,disappears,concussion,bruises,brakes,anything's,week's,twisting,tide,swept,summon,splitting,settling,scientists,reschedule,regard,purposes,ohio,notch,mike's,improvement,hooray,grabbing,extend,exquisite,disrespect,complaints,colin's,armor,voting,thornhart,sustained,straw,slapped,simon's,shipped,shattered,ruthless,reva's,refill,recorded,payroll,numb,mourning,marijuana,manly,jerry's,involving,hunk,entertain,earthquake,drift,dreadful,doorstep,confirmation,chops,bridget's,appreciates,announced,vague,tires,stressful,stem,stashed,stash,sensed,preoccupied,predictable,noticing,madly,halls,gunshot,embassy,dozens,dinner's,confuse,cleaners,charade,chalk,cappuccino,breed,bouquet,amulet,addiction,who've,warming,unlock,transition,satisfy,sacrificed,relaxing,lone,input,hampshire,girlfriend's,elaborate,concerning,completed,channels,category,cal,blocking,blend,blankets,america's,addicted,yuck,voters,professionals,positions,monica's,mode,initial,hunger,hamburger,greeting,greet,gravy,gram,dreamt,dice,declared,collecting,caution,brady's,backpack,agreeing,writers,whale,tribe,taller,supervisor,sacrifices,radiation,poo,phew,outcome,ounce,missile,meter,likewise,irrelevant,gran,felon,feature,favorites,farther,fade,experiments,erased,easiest,disk,convenience,conceived,compassionate,challenged,cane,blair's,backstage,agony,adores,veins,tweek,thieves,surgical,strangely,stetson,recital,proposing,productive,meaningful,marching,immunity,hassle,goddamned,frighten,directors,dearly,comments,closure,cease,ambition,wisconsin,unstable,sweetness,salvage,richer,refusing,raging,pumping,pressuring,petition,mortals,lowlife,jus,intimidated,intentionally,inspire,forgave,eric's,devotion,despicable,deciding,dash,comfy,breach,bo's,bark,alternate,aaaah,switching,swallowed,stove,slot,screamed,scars,russians,relevant,poof,pipes,persons,pawn,losses,legit,invest,generations,farewell,experimental,difficulty,curtains,civilized,championship,caviar,boost,token,tends,temporarily,superstition,supernatural,sunk,sadness,reduced,recorder,psyched,presidential,owners,motivated,microwave,lands,karen's,hallelujah,gap,fraternity,engines,dryer,cocoa,chewing,additional,acceptable,unbelievably,survivor,smiled,smelling,sized,simpler,sentenced,respectable,remarks,registration,premises,passengers,organ,occasional,khasinau,indication,gutter,grabs,goo,fulfill,flashlight,ellenor,courses,blooded,blessings,beware,beth's,bands,advised,water's,uhhh,turf,swings,slips,shocking,resistance,privately,olivia's,mirrors,lyrics,locking,instrument,historical,heartless,fras,decades,comparison,childish,cassie's,cardiac,admission,utterly,tuscany,ticked,suspension,stunned,statesville,sadly,resolution,reserved,purely,opponent,noted,lowest,kiddin,jerks,hitch,flirt,fare,extension,establishment,equals,dismiss,delayed,decade,christening,casket,c'mere,breakup,brad's,biting,antibiotics,accusation,abducted,witchcraft,whoever's,traded,thread,spelling,so's,school's,runnin,remaining,punching,protein,printed,paramedics,newest,murdering,mine's,masks,lawndale,intact,ins,initials,heights,grampa,democracy,deceased,colleen's,choking,charms,careless,bushes,buns,bummed,accounting,travels,taylor's,shred,saves,saddle,rethink,regards,references,precinct,persuade,patterns,meds,manipulating,llanfair,leash,kenny's,housing,hearted,guarantees,flown,feast,extent,educated,disgrace,determination,deposition,coverage,corridor,burial,bookstore,boil,abilities,vitals,veil,trespassing,teaches,sidewalk,sensible,punishing,overtime,optimistic,occasions,obsessing,oak,notify,mornin,jeopardy,jaffa,injection,hilarious,distinct,directed,desires,curve,confide,challenging,cautious,alter,yada,wilderness,where're,vindictive,vial,tomb,teeny,subjects,stroll,sittin,scrub,rebuild,rachel's,posters,parallel,ordeal,orbit,o'brien,nuns,max's,jennifer's,intimacy,inheritance,fails,exploded,donate,distracting,despair,democratic,defended,crackers,commercials,bryant's,ammunition,wildwind,virtue,thoroughly,tails,spicy,sketches,sights,sheer,shaving,seize,scarecrow,refreshing,prosecute,possess,platter,phillip's,napkin,misplaced,merchandise,membership,loony,jinx,heroic,frankenstein,fag,efficient,devil's,corps,clan,boundaries,attract,ambitious,virtually,syrup,solitary,resignation,resemblance,reacting,pursuing,premature,pod,liz's,lavery,journalist,honors,harvey's,genes,flashes,erm,contribution,company's,client's,cheque,charts,cargo,awright,acquainted,wrapping,untie,salute,ruins,resign,realised,priceless,partying,myth,moonlight,lightly,lifting,kasnoff,insisting,glowing,generator,flowing,explosives,employer,cutie,confronted,clause,buts,breakthrough,blouse,ballistic,antidote,analyze,allowance,adjourned,vet,unto,understatement,tucked,touchy,toll,subconscious,sequence,screws,sarge,roommates,reaches,rambaldi,programs,offend,nerd,knives,kin,irresistible,inherited,incapable,hostility,goddammit,fuse,frat,equation,curfew,centered,blackmailed,allows,alleged,walkin,transmission,text,starve,sleigh,sarcastic,recess,rebound,procedures,pinned,parlor,outfits,livin,issued,institute,industrial,heartache,head's,haired,fundraiser,doorman,documentary,discreet,dilucca,detect,cracks,cracker,considerate,climbed,catering,author,apophis,zoey,vacuum,urine,tunnels,todd's,tanks,strung,stitches,sordid,sark,referred,protector,portion,phoned,pets,paths,mat,lengths,kindergarten,hostess,flaw,flavor,discharge,deveraux,consumed,confidentiality,automatic,amongst,viktor,victim's,tactics,straightened,specials,spaghetti,soil,prettier,powerless,por,poems,playin,playground,parker's,paranoia,nsa,mainly,mac's,joe's,instantly,havoc,exaggerating,evaluation,eavesdropping,doughnuts,diversion,deepest,cutest,companion,comb,bela,behaving,avoided,anyplace,agh,accessory,zap,whereas,translate,stuffing,speeding,slime,polls,personalities,payments,musician,marital,lurking,lottery,journalism,interior,imaginary,hog,guinea,greetings,game's,fairwinds,ethical,equipped,environmental,elegant,elbow,customs,cuban,credibility,credentials,consistent,collapse,cloth,claws,chopped,challenges,bridal,boards,bedside,babysitting,authorized,assumption,ant,youngest,witty,vast,unforgivable,underworld,tempt,tabs,succeeded,sophomore,selfless,secrecy,runway,restless,programming,professionally,okey,movin,metaphor,messes,meltdown,lecter,incoming,hence,gasoline,gained,funding,episodes,diefenbaker,contain,comedian,collected,cam,buckle,assembly,ancestors,admired,adjustment,acceptance,weekly,warmth,throats,seduced,ridge's,reform,rebecca's,queer,poll,parenting,noses,luckiest,graveyard,gifted,footsteps,dimeras,cynical,assassination,wedded,voyage,volunteers,verbal,unpredictable,tuned,stoop,slides,sinking,show's,rio,rigged,regulations,region,promoted,plumbing,lingerie,layer,katie's,hankey,greed,everwood,essential,elope,dresser,departure,dat,dances,coup,chauffeur,bulletin,bugged,bouncing,website,tubes,temptation,supported,strangest,sorel's,slammed,selection,sarcasm,rib,primitive,platform,pending,partial,packages,orderly,obsessive,nevertheless,nbc,murderers,motto,meteor,inconvenience,glimpse,froze,fiber,execute,etc,ensure,drivers,dispute,damages,crop,courageous,consulate,closes,bosses,bees,amends,wuss,wolfram,wacky,unemployed,traces,town's,testifying,tendency,syringe,symphony,stew,startled,sorrow,sleazy,shaky,screams,rsquo,remark,poke,phone's,philip's,nutty,nobel,mentioning,mend,mayor's,iowa,inspiring,impulsive,housekeeper,germans,formed,foam,fingernails,economic,divide,conditioning,baking,whine,thug,starved,sedative,rose's,reversed,publishing,programmed,picket,paged,nowadays,newman's,mines,margo's,invasion,homosexual,homo,hips,forgets,flipping,flea,flatter,dwell,dumpster,consultant,choo,banking,assignments,apartments,ants,affecting,advisor,vile,unreasonable,tossing,thanked,steals,souvenir,screening,scratched,rep,psychopath,proportion,outs,operative,obstruction,obey,neutral,lump,lily's,insists,ian's,harass,gloat,flights,filth,extended,electronic,edgy,diseases,didn,coroner,confessing,cologne,cedar,bruise,betraying,bailing,attempting,appealing,adebisi,wrath,wandered,waist,vain,traps,transportation,stepfather,publicly,presidents,poking,obligated,marshal,lexie's,instructed,heavenly,halt,employed,diplomatic,dilemma,crazed,contagious,coaster,cheering,carved,bundle,approached,appearances,vomit,thingy,stadium,speeches,robbing,reflect,raft,qualify,pumped,pillows,peep,pageant,packs,neo,neglected,m'kay,loneliness,liberal,intrude,indicates,helluva,gardener,freely,forresters,err,drooling,continuing,betcha,alan's,addressed,acquired,vase,supermarket,squat,spitting,spaces,slaves,rhyme,relieve,receipts,racket,purchased,preserve,pictured,pause,overdue,officials,nod,motivation,morgendorffer,lucky's,lacking,kidnapper,introduction,insect,hunters,horns,feminine,eyeballs,dumps,disc,disappointing,difficulties,crock,convertible,context,claw,clamp,canned,cambias,bathtub,avanya,artery,weep,warmer,vendetta,tenth,suspense,summoned,stuff's,spiders,sings,reiber,raving,pushy,produced,poverty,postponed,ohhhh,noooo,mold,mice,laughter,incompetent,hugging,groceries,frequency,fastest,drip,differ,daphne's,communicating,body's,beliefs,bats,bases,auntie,adios,wraps,willingly,weirdest,voila,timmih,thinner,swelling,swat,steroids,sensitivity,scrape,rehearse,quarterback,organic,matched,ledge,justified,insults,increased,heavily,hateful,handles,feared,doorway,decorations,colour,chatting,buyer,buckaroo,bedrooms,batting,askin,ammo,tutoring,subpoena,span,scratching,requests,privileges,pager,mart,kel,intriguing,idiotic,hotels,grape,enlighten,dum,door's,dixie's,demonstrate,dairy,corrupt,combined,brunch,bridesmaid,barking,architect,applause,alongside,ale,acquaintance,yuh,wretched,superficial,sufficient,sued,soak,smoothly,sensing,restraint,quo,pow,posing,pleading,pittsburgh,peru,payoff,participate,organize,oprah,nemo,morals,loans,loaf,lists,laboratory,jumpy,intervention,ignorant,herbal,hangin,germs,generosity,flashing,country's,convent,clumsy,chocolates,captive,bianca's,behaved,apologise,vanity,trials,stumbled,republicans,represented,recognition,preview,poisonous,perjury,parental,onboard,mugged,minding,linen,learns,knots,interviewing,inmates,ingredients,humour,grind,greasy,goons,estimate,elementary,edmund's,drastic,database,coop,comparing,cocky,clearer,bruised,brag,bind,axe,asset,apparent,ann's,worthwhile,whoop,wedding's,vanquishing,tabloids,survivors,stenbeck's,sprung,spotlight,shops,sentencing,sentences,revealing,reduce,ram,racist,provoke,piper's,pining,overly,oui,ops,mop,louisiana,locket,king's,jab,imply,impatient,hovering,hotter,fest,endure,dots,doren,dim,diagnosed,debts,cultures,crawled,contained,condemned,chained,brit,breaths,adds,weirdo,warmed,wand,utah,troubling,tok'ra,stripped,strapped,soaked,skipping,sharon's,scrambled,rattle,profound,musta,mocking,mnh,misunderstand,merit,loading,linked,limousine,kacl,investors,interviewed,hustle,forensic,foods,enthusiastic,duct,drawers,devastating,democrats,conquer,concentration,comeback,clarify,chores,cheerleaders,cheaper,charlie's,callin,blushing,barging,abused,yoga,wrecking,wits,waffles,virginity,vibes,uninvited,unfaithful,underwater,tribute,strangled,state's,scheming,ropes,responded,residents,rescuing,rave,priests,postcard,overseas,orientation,ongoing,o'reily,newly,neil's,morphine,lotion,limitations,lesser,lectures,lads,kidneys,judgement,jog,itch,intellectual,installed,infant,indefinitely,grenade,glamorous,genetically,freud,faculty,engineering,doh,discretion,delusions,declaration,crate,competent,commonwealth,catalog,bakery,attempts,asylum,argh,applying,ahhhh,yesterday's,wedge,wager,unfit,tripping,treatments,torment,superhero,stirring,spinal,sorority,seminar,scenery,repairs,rabble,pneumonia,perks,owl,override,ooooh,moo,mija,manslaughter,mailed,love's,lime,lettuce,intimidate,instructor,guarded,grieve,grad,globe,frustration,extensive,exploring,exercises,eve's,doorbell,devices,deal's,dam,cultural,ctu,credits,commerce,chinatown,chemicals,baltimore,authentic,arraignment,annulled,altered,allergies,wanta,verify,vegetarian,tunes,tourist,tighter,telegram,suitable,stalk,specimen,spared,solving,shoo,satisfying,saddam,requesting,publisher,pens,overprotective,obstacles,notified,negro,nasedo,judged,jill's,identification,grandchild,genuinely,founded,flushed,fluids,floss,escaping,ditched,demon's,decorated,criticism,cramp,corny,contribute,connecting,bunk,bombing,bitten,billions,bankrupt,yikes,wrists,ultrasound,ultimatum,thirst,spelled,sniff,scope,ross's,room's,retrieve,releasing,reassuring,pumps,properties,predicted,neurotic,negotiating,needn't,multi,monitors,millionaire,microphone,mechanical,lydecker,limp,incriminating,hatchet,gracias,gordie,fills,feeds,egypt,doubting,dedication,decaf,dawson's,competing,cellular,biopsy,whiz,voluntarily,visible,ventilator,unpack,unload,universal,tomatoes,targets,suggests,strawberry,spooked,snitch,schillinger,sap,reassure,providing,prey,pressure's,persuasive,mystical,mysteries,mri,moment's,mixing,matrimony,mary's,mails,lighthouse,liability,kgb,jock,headline,frankie's,factors,explosive,explanations,dispatch,detailed,curly,cupid,condolences,comrade,cassadines,bulb,brittany's,bragging,awaits,assaulted,ambush,adolescent,adjusted,abort,yank,whit,verse,vaguely,undermine,tying,trim,swamped,stitch,stan's,stabbing,slippers,skye's,sincerely,sigh,setback,secondly,rotting,rev,retail,proceedings,preparation,precaution,pox,pcpd,nonetheless,melting,materials,mar,liaison,hots,hooking,headlines,hag,ganz,fury,felicity,fangs,expelled,encouragement,earring,dreidel,draws,dory,donut,dog's,dis,dictate,dependent,decorating,coordinates,cocktails,bumps,blueberry,believable,backfired,backfire,apron,anticipated,adjusting,activated,vous,vouch,vitamins,vista,urn,uncertain,ummm,tourists,tattoos,surrounding,sponsor,slimy,singles,sibling,shhhh,restored,representative,renting,reign,publish,planets,peculiar,parasite,paddington,noo,marries,mailbox,magically,lovebirds,listeners,knocks,kane's,informant,grain,exits,elf,drazen,distractions,disconnected,dinosaurs,designing,dashwood,crooked,conveniently,contents,argued,wink,warped,underestimated,testified,tacky,substantial,steve's,steering,staged,stability,shoving,seizure,reset,repeatedly,radius,pushes,pitching,pairs,opener,mornings,mississippi,matthew's,mash,investigations,invent,indulge,horribly,hallucinating,festive,eyebrows,expand,enjoys,dictionary,dialogue,desperation,dealers,darkest,daph,critic,consulting,cartman's,canal,boragora,belts,bagel,authorization,auditions,associated,ape,amy's,agitated,adventures,withdraw,wishful,wimp,vehicles,vanish,unbearable,tonic,tom's,tackle,suffice,suction,slaying,singapore,safest,rosanna's,rocking,relive,rates,puttin,prettiest,oval,noisy,newlyweds,nauseous,moi,misguided,mildly,midst,maps,liable,kristina's,judgmental,introducing,individuals,hunted,hen,givin,frequent,fisherman,fascinated,elephants,dislike,diploma,deluded,decorate,crummy,contractions,carve,careers,bottled,bonded,bahamas,unavailable,twenties,trustworthy,translation,traditions,surviving,surgeons,stupidity,skies,secured,salvation,remorse,rafe's,princeton,preferably,pies,photography,operational,nuh,northwest,nausea,napkins,mule,mourn,melted,mechanism,mashed,julia's,inherit,holdings,hel,greatness,golly,excused,edges,dumbo,drifting,delirious,damaging,cubicle,compelled,comm,colleges,cole's,chooses,checkup,chad's,certified,candidates,boredom,bob's,bandages,baldwin's,bah,automobile,athletic,alarms,absorbed,absent,windshield,who're,whaddya,vitamin,transparent,surprisingly,sunglasses,starring,slit,sided,schemes,roar,relatively,reade,quarry,prosecutor,prognosis,probe,potentially,pitiful,persistent,perception,percentage,peas,oww,nosy,neighbourhood,nagging,morons,molecular,meters,masterpiece,martinis,limbo,liars,jax's,irritating,inclined,hump,hoynes,haw,gauge,functions,fiasco,educational,eatin,donated,destination,dense,cubans,continent,concentrating,commanding,colorful,clam,cider,brochure,behaviour,barto,bargaining,awe,artistic,welcoming,weighing,villain,vein,vanquished,striking,stains,sooo,smear,sire,simone's,secondary,roughly,rituals,resentment,psychologist,preferred,pint,pension,passive,overhear,origin,orchestra,negotiations,mounted,morality,landingham,labs,kisser,jackson's,icy,hoot,holling,handshake,grilled,functioning,formality,elevators,edward's,depths,confirms,civilians,bypass,briefly,boathouse,binding,acres,accidental,westbridge,wacko,ulterior,transferring,tis,thugs,tangled,stirred,stefano's,sought,snag,smallest,sling,sleaze,seeds,rumour,ripe,remarried,reluctant,regularly,puddle,promote,precise,popularity,pins,perceptive,miraculous,memorable,maternal,lucinda's,longing,lockup,locals,librarian,job's,inspection,impressions,immoral,hypothetically,guarding,gourmet,gabe,fighters,fees,features,faxed,extortion,expressed,essentially,downright,digest,der,crosses,cranberry,city's,chorus,casualties,bygones,buzzing,burying,bikes,attended,allah,all's,weary,viewing,viewers,transmitter,taping,takeout,sweeping,stepmother,stating,stale,seating,seaborn,resigned,rating,prue's,pros,pepperoni,ownership,occurs,nicole's,newborn,merger,mandatory,malcolm's,ludicrous,jan's,injected,holden's,henry's,heating,geeks,forged,faults,expressing,eddie's,drue,dire,dief,desi,deceiving,centre,celebrities,caterer,calmed,businesses,budge,ashley's,applications,ankles,vending,typing,tribbiani,there're,squared,speculation,snowing,shades,sexist,scudder's,scattered,sanctuary,rewrite,regretted,regain,raises,processing,picky,orphan,mural,misjudged,miscarriage,memorize,marshall's,mark's,licensed,lens,leaking,launched,larry's,languages,judge's,jitters,invade,interruption,implied,illegally,handicapped,glitch,gittes,finer,fewer,engineered,distraught,dispose,dishonest,digs,dahlia's,dads,cruelty,conducting,clinical,circling,champions,canceling,butterflies,belongings,barbrady,amusement,allegations,alias,aging,zombies,where've,unborn,tri,swearing,stables,squeezed,spaulding's,slavery,sew,sensational,revolutionary,resisting,removing,radioactive,races,questionable,privileged,portofino,par,owning,overlook,overhead,orson,oddly,nazis,musicians,interrogate,instruments,imperative,impeccable,icu,hurtful,hors,heap,harley's,graduating,graders,glance,endangered,disgust,devious,destruct,demonstration,creates,crazier,countdown,coffee's,chump,cheeseburger,cat's,burglar,brotherhood,berries,ballroom,assumptions,ark,annoyed,allies,allergy,advantages,admirer,admirable,addresses,activate,accompany,wed,victoria's,valve,underpants,twit,triggered,teacher's,tack,strokes,stool,starr's,sham,seasons,sculpture,scrap,sailed,retarded,resourceful,remarkably,refresh,ranks,pressured,precautions,pointy,obligations,nightclub,mustache,month's,minority,mind's,maui,lace,isabella's,improving,iii,hunh,hubby,flare,fierce,farmers,dont,dokey,divided,demise,demanded,dangerously,crushing,considerable,complained,clinging,choked,chem,cheerleading,checkbook,cashmere,calmly,blush,believer,aspect,amazingly,alas,acute,a's,yak,whores,what've,tuition,trey's,tolerance,toilets,tactical,tacos,stairwell,spur,spirited,slower,sewing,separately,rubbed,restricted,punches,protects,partially,ole,nuisance,niagara,motherfuckers,mingle,mia's,kynaston,knack,kinkle,impose,hosting,harry's,gullible,grid,godmother,funniest,friggin,folding,financially,filming,fashions,eater,dysfunctional,drool,distinguished,defence,defeated,cruising,crude,criticize,corruption,contractor,conceive,clone,circulation,cedars,caliber,brighter,blinded,birthdays,bio,bill's,banquet,artificial,anticipate,annoy,achievement,whim,whichever,volatile,veto,vested,uncle's,supports,successfully,shroud,severely,rests,representation,quarantine,premiere,pleases,parent's,painless,pads,orphans,orphanage,offence,obliged,nip,niggers,negotiation,narcotics,nag,mistletoe,meddling,manifest,lookit,loo,lilah,investigated,intrigued,injustice,homicidal,hayward's,gigantic,exposing,elves,disturbance,disastrous,depended,demented,correction,cooped,colby's,cheerful,buyers,brownies,beverage,basics,attorney's,atm,arvin,arcade,weighs,upsets,unethical,tidy,swollen,sweaters,swap,stupidest,sensation,scalpel,rail,prototype,props,prescribed,pompous,poetic,ploy,paws,operates,objections,mushrooms,mulwray,monitoring,manipulation,lured,lays,lasting,kung,keg,jell,internship,insignificant,inmate,incentive,gandhi,fulfilled,flooded,expedition,evolution,discharged,disagreement,dine,dean's,crypt,coroner's,cornered,copied,confrontation,cds,catalogue,brightest,beethoven,banned,attendant,athlete,amaze,airlines,yogurt,wyndemere,wool,vocabulary,vcr,tulsa,tags,tactic,stuffy,slug,sexuality,seniors,segment,revelation,respirator,pulp,prop,producing,processed,pretends,polygraph,perp,pennies,ordinarily,opposition,olives,necks,morally,martyr,martial,lisa's,leftovers,joints,jimmy's,irs,invaded,imported,hopping,homey,hints,helicopters,heed,heated,heartbroken,gulf,greatly,forge,florist,firsthand,fiend,expanding,emma's,defenses,crippled,cousin's,corrected,conniving,conditioner,clears,chemo,bubbly,bladder,beeper,baptism,apb,answer's,anna's,angles,ache,womb,wiring,wench,weaknesses,volunteering,violating,unlocked,unemployment,tummy,tibet,threshold,surrogate,submarine,subid,stray,stated,startle,specifics,snob,slowing,sled,scoot,robbers,rightful,richest,quid,qfxmjrie,puffs,probable,pitched,pierced,pencils,paralysis,nuke,managing,makeover,luncheon,lords,linksynergy,jury's,jacuzzi,ish,interstate,hitched,historic,hangover,gasp,fracture,flock,firemen,drawings,disgusted,darned,coal,clams,chez,cables,broadcasting,brew,borrowing,banged,achieved,wildest,weirder,unauthorized,stunts,sleeves,sixties,shush,shalt,senora,rises,retro,quits,pupils,politicians,pegged,painfully,paging,outlet,omelet,observed,ned's,memorized,lawfully,jackets,interpretation,intercept,ingredient,grownup,glued,gaining,fulfilling,flee,enchanted,dvd,delusion,daring,conservative,conducted,compelling,charitable,carton,bronx,bridesmaids,bribed,boiling,bathrooms,bandage,awareness,awaiting,assign,arrogance,antiques,ainsley,turkeys,travelling,trashing,tic,takeover,sync,supervision,stockings,stalked,stabilized,spacecraft,slob,skates,sirs,sedated,robes,reviews,respecting,rat's,psyche,prominent,prizes,presumptuous,prejudice,platoon,permitted,paragraph,mush,mum's,movements,mist,missions,mints,mating,mantan,lorne,lord's,loads,listener,legendary,itinerary,hugs,hepatitis,heave,guesses,gender,flags,fading,exams,examining,elizabeth's,egyptian,dumbest,dishwasher,dimera's,describing,deceive,cunning,cripple,cove,convictions,congressional,confided,compulsive,compromising,burglary,bun,bumpy,brainwashed,benes,arnie,alvy,affirmative,adrenaline,adamant,watchin,waitresses,uncommon,treaty,transgenic,toughest,toby's,surround,stormed,spree,spilling,spectacle,soaking,significance,shreds,sewers,severed,scarce,scamming,scalp,sami's,salem's,rewind,rehearsing,pretentious,potions,possessions,planner,placing,periods,overrated,obstacle,notices,nerds,meems,medieval,mcmurphy,maturity,maternity,masses,maneuver,lyin,loathe,lawyer's,irv,investigators,hep,grin,gospel,gals,formation,fertility,facilities,exterior,epidemic,eloping,ecstatic,ecstasy,duly,divorcing,distribution,dignan,debut,costing,coaching,clubhouse,clot,clocks,classical,candid,bursting,breather,braces,bennett's,bending,australian,attendance,arsonist,applies,adored,accepts,absorb,vacant,uuh,uphold,unarmed,turd,topolsky,thrilling,thigh,terminate,tempo,sustain,spaceship,snore,sneeze,smuggling,shrine,sera,scott's,salty,salon,ramp,quaint,prostitution,prof,policies,patronize,patio,nasa,morbid,marlo's,mamma,locations,licence,kettle,joyous,invincible,interpret,insecurities,insects,inquiry,infamous,impulses,illusions,holed,glen's,fragments,forrester's,exploit,economics,drivin,des,defy,defenseless,dedicate,cradle,cpr,coupon,countless,conjure,confined,celebrated,cardboard,booking,blur,bleach,ban,backseat,austin's,alternatives,afterward,accomplishment,wordsworth,wisely,wildlife,valet,vaccine,urges,unnatural,unlucky,truths,traumatized,tit,tennessee,tasting,swears,strawberries,steaks,stats,skank,seducing,secretive,screwdriver,schedules,rooting,rightfully,rattled,qualifies,puppets,provides,prospects,pronto,prevented,powered,posse,poorly,polling,pedestal,palms,muddy,morty,miniature,microscope,merci,margin,lecturing,inject,incriminate,hygiene,hospital's,grapefruit,gazebo,funnier,freight,flooding,equivalent,eliminated,elaine's,dios,deacon's,cuter,continental,container,cons,compensation,clap,cbs,cavity,caves,capricorn,canvas,calculations,bossy,booby,bacteria,aides,zende,winthrop,wider,warrants,valentines,undressed,underage,truthfully,tampered,suffers,stored,statute,speechless,sparkling,sod,socially,sidelines,shrek,sank,roy's,raul's,railing,puberty,practices,pesky,parachute,outrage,outdoors,operated,openly,nominated,motions,moods,lunches,litter,kidnappers,itching,intuition,index,imitation,icky,humility,hassling,gallons,firmly,excessive,evolved,employ,eligible,elections,elderly,drugstore,dosage,disrupt,directing,dipping,deranged,debating,cuckoo,cremated,craziness,cooperating,compatible,circumstantial,chimney,bonnie's,blinking,biscuits,belgium,arise,analyzed,admiring,acquire,accounted,willow's,weeping,volumes,views,triad,trashy,transaction,tilt,soothing,slumber,slayers,skirts,siren,ship's,shindig,sentiment,sally's,rosco,riddance,rewarded,quaid,purity,proceeding,pretzels,practiced,politician,polar,panicking,overall,occupation,naming,minimal,mckechnie,massacre,marah's,lovin,leaked,layers,isolation,intruding,impersonating,ignorance,hoop,hamburgers,gwen's,fruits,footprints,fluke,fleas,festivities,fences,feisty,evacuate,emergencies,diabetes,detained,democrat,deceived,creeping,craziest,corpses,conned,coincidences,charleston,bums,brussels,bounced,bodyguards,blasted,bitterness,baloney,ashtray,apocalypse,advances,zillion,watergate,wallpaper,viable,tory's,tenants,telesave,sympathize,sweeter,swam,sup,startin,stages,spencer's,sodas,snowed,sleepover,signor,seein,reviewing,reunited,retainer,restroom,rested,replacing,repercussions,reliving,reef,reconciliation,reconcile,recognise,prevail,preaching,planting,overreact,oof,omen,o'neil,numerous,noose,moustache,morning's,manicure,maids,mah,lorelei's,landlady,hypothetical,hopped,homesick,hives,hesitation,herbs,hectic,heartbreak,haunting,gangs,frown,fingerprint,extract,expired,exhausting,exchanged,exceptional,everytime,encountered,disregard,daytime,cooperative,constitutional,cling,chevron,chaperone,buenos,blinding,bitty,beads,battling,badgering,anticipation,advocate,zander's,waterfront,upstanding,unprofessional,unity,unhealthy,undead,turmoil,truthful,toothpaste,tippin,thoughtless,tagataya,stretching,strategic,spun,shortage,shooters,sheriff's,shady,senseless,sailors,rewarding,refuge,rapid,rah,pun,propane,pronounced,preposterous,pottery,portable,pigeons,pastry,overhearing,ogre,obscene,novels,negotiable,mtv,morgan's,monthly,loner,leisure,leagues,jogging,jaws,itchy,insinuating,insides,induced,immigration,hospitality,hormone,hilda's,hearst,grandpa's,frequently,forthcoming,fists,fifties,etiquette,endings,elevated,editing,dunk,distinction,disabled,dibs,destroys,despises,desired,designers,deprived,dancers,dah,cuddy,crust,conductor,communists,cloak,circumstance,chewed,casserole,bora,bidder,bearer,assessment,artoo,applaud,appalling,amounts,admissions,withdrawal,weights,vowed,virgins,vigilante,vatican,undone,trench,touchdown,throttle,thaw,tha,testosterone,tailor,symptom,swoop,suited,suitcases,stomp,sticker,stakeout,spoiling,snatched,smoochy,smitten,shameless,restraints,researching,renew,relay,regional,refund,reclaim,rapids,raoul,rags,puzzles,purposely,punks,prosecuted,plaid,pineapple,picturing,pickin,pbs,parasites,offspring,nyah,mysteriously,multiply,mineral,masculine,mascara,laps,kramer's,jukebox,interruptions,hoax,gunfire,gays,furnace,exceptions,engraved,elbows,duplicate,drapes,designated,deliberate,deli,decoy,cub,cryptic,crowds,critics,coupla,convert,conventional,condemn,complicate,combine,colossal,clerks,clarity,cassadine's,byes,brushed,bride's,banished,arrests,argon,andy's,alarmed,worships,versa,uncanny,troop,treasury,transformation,terminated,telescope,technicality,sydney's,sundae,stumble,stripping,shuts,separating,schmuck,saliva,robber,retain,remained,relentless,reconnect,recipes,rearrange,ray's,rainy,psychiatrists,producers,policemen,plunge,plugged,patched,overload,ofc,obtained,obsolete,o'malley,numbered,number's,nay,moth,module,mkay,mindless,menus,lullaby,lotte,leavin,layout,knob,killin,karinsky,irregular,invalid,hides,grownups,griff,flaws,flashy,flaming,fettes,evicted,epic,encoded,dread,dil,degrassi,dealings,dangers,cushion,console,concluded,casey's,bowel,beginnings,barged,apes,announcing,amanda's,admits,abroad,abide,abandoning,workshop,wonderfully,woak,warfare,wait'll,wad,violate,turkish,tim's,ter,targeted,susan's,suicidal,stayin,sorted,slamming,sketchy,shoplifting,shapes,selected,sarah's,retiring,raiser,quizmaster,pursued,pupkin,profitable,prefers,politically,phenomenon,palmer's,olympics,needless,nature's,mutt,motherhood,momentarily,migraine,lizzie's,lilo,lifts,leukemia,leftover,law's,keepin,idol,hinks,hellhole,h'mm,gowns,goodies,gallon,futures,friction,finale,farms,extraction,entertained,electronics,eighties,earth's,dmv,darker,daniel's,cum,conspiring,consequence,cheery,caps,calf,cadet,builds,benign,barney's,aspects,artillery,apiece,allison's,aggression,adjustments,abusive,abduction,wiping,whipping,welles,unspeakable,unlimited,unidentified,trivial,transcripts,threatens,textbook,tenant,supervise,superstitious,stricken,stretched,story's,stimulating,steep,statistics,spielberg,sodium,slices,shelves,scratches,saudi,sabotaged,roxy's,retrieval,repressed,relation,rejecting,quickie,promoting,ponies,peeking,paw,paolo,outraged,observer,o'connell,moping,moaning,mausoleum,males,licked,kovich,klutz,iraq,interrogating,interfered,intensive,insulin,infested,incompetence,hyper,horrified,handedly,hacked,guiding,glamour,geoff,gekko,fraid,fractured,formerly,flour,firearms,fend,executives,examiner,evaluate,eloped,duke's,disoriented,delivers,dashing,crystals,crossroads,crashdown,court's,conclude,coffees,cockroach,climate,chipped,camps,brushing,boulevard,bombed,bolts,begs,baths,baptized,astronaut,assurance,anemia,allegiance,aiming,abuela,abiding,workplace,withholding,weave,wearin,weaker,warnings,usa,tours,thesis,terrorism,suffocating,straws,straightforward,stench,steamed,starboard,sideways,shrinks,shortcut,sean's,scram,roasted,roaming,riviera,respectfully,repulsive,recognizes,receiver,psychiatry,provoked,penitentiary,peed,pas,painkillers,oink,norm,ninotchka,muslim,montgomery's,mitzvah,milligrams,mil,midge,marshmallows,markets,macy's,looky,lapse,kubelik,knit,jeb,investments,intellect,improvise,implant,hometown,hanged,handicap,halo,governor's,goa'ulds,giddy,gia's,geniuses,fruitcake,footing,flop,findings,fightin,fib,editorial,drinkin,doork,discovering,detour,danish,cuddle,crashes,coordinate,combo,colonnade,collector,cheats,cetera,canadians,bip,bailiff,auditioning,assed,amused,alienate,algebra,alexi,aiding,aching,woe,wah,unwanted,typically,tug,topless,tongues,tiniest,them's,symbols,superiors,soy,soften,sheldrake,sensors,seller,seas,ruler,rival,rips,renowned,recruiting,reasoning,rawley,raisins,racial,presses,preservation,portfolio,oversight,organizing,obtain,observing,nessa,narrowed,minions,midwest,meth,merciful,manages,magistrate,lawsuits,labour,invention,intimidating,infirmary,indicated,inconvenient,imposter,hugged,honoring,holdin,hades,godforsaken,fumes,forgery,foremost,foolproof,folder,folded,flattery,fingertips,financing,fifteenth,exterminator,explodes,eccentric,drained,dodging,documented,disguised,developments,currency,crafts,constructive,concealed,compartment,chute,chinpokomon,captains,capitol,calculated,buses,bodily,astronauts,alimony,accustomed,accessories,abdominal,zen,zach's,wrinkle,wallow,viv,vicinity,venue,valued,valium,valerie's,upgrade,upcoming,untrue,uncover,twig,twelfth,trembling,treasures,torched,toenails,timed,termites,telly,taunting,taransky,tar,talker,succubus,statues,smarts,sliding,sizes,sighting,semen,seizures,scarred,savvy,sauna,saddest,sacrificing,rubbish,riled,ricky's,rican,revive,recruit,ratted,rationally,provenance,professors,prestigious,pms,phonse,perky,pedal,overdose,organism,nasal,nanites,mushy,movers,moot,missus,midterm,merits,melodramatic,manure,magnetic,knockout,knitting,jig,invading,interpol,incapacitated,idle,hotline,horse's,highlight,hauling,hair's,gunpoint,greenwich,grail,ganza,framing,formally,fleeing,flap,flannel,fin,fibers,faded,existing,email,eavesdrop,dwelling,dwarf,donations,detected,desserts,dar,corporations,constellation,collision,chic,calories,businessmen,buchanan's,breathtaking,bleak,blacked,batter,balanced,ante,aggravated,agencies,abu,yanked,wuh,withdrawn,wigand,whoah,wham,vocal,unwind,undoubtedly,unattractive,twitch,trimester,torrance,timetable,taxpayers,strained,stationed,stared,slapping,sincerity,signatures,siding,siblings,shit's,shenanigans,shacking,seer,satellites,sappy,samaritan,rune,regained,rebellion,proceeds,privy,power's,poorer,politely,paste,oysters,overruled,olaf,nightcap,networks,necessity,mosquito,millimeter,michelle's,merrier,massachusetts,manuscript,manufacture,manhood,lunar,lug,lucked,loaned,kilos,ignition,hurl,hauled,harmed,goodwill,freshmen,forming,fenmore,fasten,farce,failures,exploding,erratic,elm,drunks,ditching,d'artagnan,crops,cramped,contacting,coalition,closets,clientele,chimp,cavalry,casa,cabs,bled,bargained,arranging,archives,anesthesia,amuse,altering,afternoons,accountable,abetting,wrinkles,wolek,waved,unite,uneasy,unaware,ufo,toot,toddy,tens,tattooed,tad's,sway,stained,spauldings,solely,sliced,sirens,schibetta,scatter,rumours,roger's,robbie's,rinse,remo,remedy,redemption,queen's,progressive,pleasures,picture's,philosopher,pacey's,optimism,oblige,natives,muy,measuring,measured,masked,mascot,malicious,mailing,luca,lifelong,kosher,koji,kiddies,judas,isolate,intercepted,insecurity,initially,inferior,incidentally,ifs,hun,heals,headlights,guided,growl,grilling,glazed,gem,gel,gaps,fundamental,flunk,floats,fiery,fairness,exercising,excellency,evenings,ere,enrolled,disclosure,det,department's,damp,curling,cupboard,counterfeit,cooling,condescending,conclusive,clicked,cleans,cholesterol,chap,cashed,brow,broccoli,brats,blueprints,blindfold,biz,billing,barracks,attach,aquarium,appalled,altitude,alrighty,aimed,yawn,xander's,wynant,winslow's,welcomed,violations,upright,unsolved,unreliable,toots,tighten,symbolic,sweatshirt,steinbrenner,steamy,spouse,sox,sonogram,slowed,slots,sleepless,skeleton,shines,roles,retaliate,representatives,rephrase,repeated,renaissance,redeem,rapidly,rambling,quilt,quarrel,prying,proverbial,priced,presiding,presidency,prescribe,prepped,pranks,possessive,plaintiff,philosophical,pest,persuaded,perk,pediatrics,paige's,overlooked,outcast,oop,odor,notorious,nightgown,mythology,mumbo,monitored,mediocre,master's,mademoiselle,lunchtime,lifesaver,legislation,leaned,lambs,lag,killings,interns,intensity,increasing,identities,hounding,hem,hellmouth,goon,goner,ghoul,germ,gardening,frenzy,foyer,food's,extras,extinct,exhibition,exaggerate,everlasting,enlightened,drilling,doubles,digits,dialed,devote,defined,deceitful,d'oeuvres,csi,cosmetic,contaminated,conspired,conning,colonies,cerebral,cavern,cathedral,carving,butting,boiled,blurry,beams,barf,babysit,assistants,ascension,architecture,approaches,albums,albanian,aaaaah,wildly,whoopee,whiny,weiskopf,walkie,vultures,veteran,vacations,upfront,unresolved,tile,tampering,struggled,stockholders,specially,snaps,sleepwalking,shrunk,sermon,seeks,seduction,scenarios,scams,ridden,revolve,repaired,regulation,reasonably,reactor,quotes,preserved,phenomenal,patrolling,paranormal,ounces,omigod,offs,nonstop,nightfall,nat,militia,meeting's,logs,lineup,libby's,lava,lashing,labels,kilometers,kate's,invites,investigative,innocents,infierno,incision,import,implications,humming,highlights,haunts,greeks,gloss,gloating,general's,frannie,flute,fled,fitted,finishes,fiji,fetal,feeny,entrapment,edit,dyin,download,discomfort,dimensions,detonator,dependable,deke,decree,dax,cot,confiscated,concludes,concede,complication,commotion,commence,chulak,caucasian,casually,canary,brainer,bolie,ballpark,arm's,anwar,anatomy,analyzing,accommodations,yukon,youse,wring,wharf,wallowing,uranium,unclear,treason,transgenics,thrive,think's,thermal,territories,tedious,survives,stylish,strippers,sterile,squeezing,squeaky,sprained,solemn,snoring,sic,shifting,shattering,shabby,seams,scrawny,rotation,risen,revoked,residue,reeks,recite,reap,ranting,quoting,primal,pressures,predicament,precision,plugs,pits,pinpoint,petrified,petite,persona,pathological,passports,oughtta,nods,nighter,navigate,nashville,namely,museums,morale,milwaukee,meditation,mathematics,martin's,malta,logan's,latter,kippie,jackie's,intrigue,intentional,insufferable,incomplete,inability,imprisoned,hup,hunky,how've,horrifying,hearty,headmaster,hath,har,hank's,handbook,hamptons,grazie,goof,george's,funerals,fuck's,fraction,forks,finances,fetched,excruciating,enjoyable,enhanced,enhance,endanger,efficiency,dumber,drying,diabolical,destroyer,desirable,defendants,debris,darts,cuisine,cucumber,cube,crossword,contestant,considers,comprehend,club's,clipped,classmates,choppers,certificates,carmen's,canoe,candlelight,building's,brutally,brutality,boarded,bathrobe,backward,authorize,audrey's,atom,assemble,appeals,airports,aerobics,ado,abbott's,wholesome,whiff,vessels,vermin,varsity,trophies,trait,tragically,toying,titles,tissues,testy,team's,tasteful,surge,sun's,studios,strips,stocked,stephen's,staircase,squares,spinach,sow,southwest,southeast,sookie's,slayer's,sipping,singers,sidetracked,seldom,scrubbing,scraping,sanctity,russell's,ruse,robberies,rink,ridin,retribution,reinstated,refrain,rec,realities,readings,radiant,protesting,projector,posed,plutonium,plaque,pilar's,payin,parting,pans,o'reilly,nooooo,motorcycles,motherfucking,mein,measly,marv,manic,line's,lice,liam,lenses,lama,lalita,juggling,jerking,jamie's,intro,inevitably,imprisonment,hypnosis,huddle,horrendous,hobbies,heavier,heartfelt,harlin,hairdresser,grub,gramps,gonorrhea,gardens,fussing,fragment,fleeting,flawless,flashed,fetus,exclusively,eulogy,equality,enforce,distinctly,disrespectful,denies,crossbow,crest,cregg,crabs,cowardly,countess,contrast,contraction,contingency,consulted,connects,confirming,condone,coffins,cleansing,cheesecake,certainty,captain's,cages,c'est,briefed,brewing,bravest,bosom,boils,binoculars,bachelorette,aunt's,atta,assess,appetizer,ambushed,alerted,woozy,withhold,weighed,vulgar,viral,utmost,unusually,unleashed,unholy,unhappiness,underway,uncovered,unconditional,typewriter,typed,twists,sweeps,supervised,supermodel,suburbs,subpoenaed,stringing,snyder's,snot,skeptical,skateboard,shifted,secret's,scottish,schoolgirl,romantically,rocked,revoir,reviewed,respiratory,reopen,regiment,reflects,refined,puncture,pta,prone,produces,preach,pools,polished,pods,planetarium,penicillin,peacefully,partner's,nurturing,nation's,more'n,monastery,mmhmm,midgets,marklar,machinery,lodged,lifeline,joanna's,jer,jellyfish,infiltrate,implies,illegitimate,hutch,horseback,henri,heist,gents,frickin,freezes,forfeit,followers,flakes,flair,fathered,fascist,eternally,eta,epiphany,enlisted,eleventh,elect,effectively,dos,disgruntled,discrimination,discouraged,delinquent,decipher,danvers,dab,cubes,credible,coping,concession,cnn,clash,chills,cherished,catastrophe,caretaker,bulk,bras,branches,bombshell,birthright,billionaire,awol,ample,alumni,affections,admiration,abbotts,zelda's,whatnot,watering,vinegar,vietnamese,unthinkable,unseen,unprepared,unorthodox,underhanded,uncool,transmitted,traits,timeless,thump,thermometer,theoretically,theoretical,testament,tapping,tagged,tac,synthetic,syndicate,swung,surplus,supplier,stares,spiked,soviets,solves,smuggle,scheduling,scarier,saucer,reinforcements,recruited,rant,quitter,prudent,projection,previously,powdered,poked,pointers,placement,peril,penetrate,penance,patriotic,passions,opium,nudge,nostrils,nevermind,neurological,muslims,mow,momentum,mockery,mobster,mining,medically,magnitude,maggie's,loudly,listing,killer's,kar,jim's,insights,indicted,implicate,hypocritical,humanly,holiness,healthier,hammered,haldeman,gunman,graphic,gloom,geography,gary's,freshly,francs,formidable,flunked,flawed,feminist,faux,ewww,escorted,escapes,emptiness,emerge,drugging,dozer,doc's,directorate,diana's,derevko,deprive,deodorant,cryin,crusade,crocodile,creativity,controversial,commands,coloring,colder,cognac,clocked,clippings,christine's,chit,charades,chanting,certifiable,caterers,brute,brochures,briefs,bran,botched,blinders,bitchin,bauer's,banter,babu,appearing,adequate,accompanied,abrupt,abdomen,zones,wooo,woken,winding,vip,venezuela,unanimous,ulcer,tread,thirteenth,thankfully,tame,tabby's,swine,swimsuit,swans,suv,stressing,steaming,stamped,stabilize,squirm,spokesman,snooze,shuffle,shredded,seoul,seized,seafood,scratchy,savor,sadistic,roster,rica,rhetorical,revlon,realist,reactions,prosecuting,prophecies,prisons,precedent,polyester,petals,persuasion,paddles,o'leary,nuthin,neighbour,negroes,naval,mute,muster,muck,minnesota,meningitis,matron,mastered,markers,maris's,manufactured,lot's,lockers,letterman,legged,launching,lanes,journals,indictment,indicating,hypnotized,housekeeping,hopelessly,hmph,hallucinations,grader,goldilocks,girly,furthermore,frames,flask,expansion,envelopes,engaging,downside,doves,doorknob,distinctive,dissolve,discourage,disapprove,diabetic,departed,deliveries,decorator,deaq,crossfire,criminally,containment,comrades,complimentary,commitments,chum,chatter,chapters,catchy,cashier,cartel,caribou,cardiologist,bull's,buffer,brawl,bowls,booted,boat's,billboard,biblical,barbershop,awakening,aryan,angst,administer,acquitted,acquisition,aces,accommodate,zellie,yield,wreak,witch's,william's,whistles,wart,vandalism,vamps,uterus,upstate,unstoppable,unrelated,understudy,tristin,transporting,transcript,tranquilizer,trails,trafficking,toxins,tonsils,timing's,therapeutic,tex,subscription,submitted,stephanie's,stempel,spotting,spectator,spatula,soho,softer,snotty,slinging,showered,sexiest,sensual,scoring,sadder,roam,rimbaud,rim,rewards,restrain,resilient,remission,reinstate,rehash,recollection,rabies,quinn's,presenting,preference,prairie,popsicle,plausible,plantation,pharmaceutical,pediatric,patronizing,patent,participation,outdoor,ostrich,ortolani,oooooh,omelette,neighbor's,neglect,nachos,movie's,mixture,mistrial,mio,mcginty's,marseilles,mare,mandate,malt,luv,loophole,literary,liberation,laughin,lacey's,kevvy,jah,irritated,intends,initiation,initiated,initiate,influenced,infidelity,indigenous,inc,idaho,hypothermia,horrific,hive,heroine,groupie,grinding,graceful,government's,goodspeed,gestures,gah,frantic,extradition,evil's,engineers,echelon,earning,disks,discussions,demolition,definitive,dawnie,dave's,date's,dared,dan's,damsel,curled,courtyard,constitutes,combustion,collective,collateral,collage,col,chant,cassette,carol's,carl's,calculating,bumping,britain,bribes,boardwalk,blinds,blindly,bleeds,blake's,bickering,beasts,battlefield,bankruptcy,backside,avenge,apprehended,annie's,anguish,afghanistan,acknowledged,abusing,youthful,yells,yanking,whomever,when'd,waterfall,vomiting,vine,vengeful,utility,unpacking,unfamiliar,undying,tumble,trolls,treacherous,todo,tipping,tantrum,tanked,summons,strategies,straps,stomped,stinkin,stings,stance,staked,squirrels,sprinkles,speculate,specialists,sorting,skinned,sicko,sicker,shootin,shep,shatter,seeya,schnapps,s'posed,rows,rounded,ronee,rite,revolves,respectful,resource,reply,rendered,regroup,regretting,reeling,reckoned,rebuilding,randy's,ramifications,qualifications,pulitzer,puddy,projections,preschool,pots,potassium,plissken,platonic,peter's,permalash,performer,peasant,outdone,outburst,ogh,obscure,mutants,mugging,molecules,misfortune,miserably,miraculously,medications,medals,margaritas,manpower,lovemaking,long's,logo,logically,leeches,latrine,lamps,lacks,kneel,johnny's,jenny's,inflict,impostor,icon,hypocrisy,hype,hosts,hippies,heterosexual,heightened,hecuba's,hecuba,healer,habitat,gunned,grooming,groo,groin,gras,gory,gooey,gloomy,frying,friendships,fredo,foil,fishermen,firepower,fess,fathom,exhaustion,evils,epi,endeavor,ehh,eggnog,dreaded,drafted,dimensional,detached,deficit,d'arcy,crotch,coughing,coronary,cookin,contributed,consummate,congrats,concerts,companionship,caved,caspar,bulletproof,bris,brilliance,breakin,brash,blasting,beak,arabia,analyst,aluminum,aloud,alligator,airtight,advising,advertise,adultery,administered,aches,abstract,aahh,wronged,wal,voluntary,ventilation,upbeat,uncertainty,trot,trillion,tricia's,trades,tots,tol,tightly,thingies,tending,technician,tarts,surreal,summer's,strengths,specs,specialize,spat,spade,slogan,sloane's,shrew,shaping,seth's,selves,seemingly,schoolwork,roomie,requirements,redundant,redo,recuperating,recommendations,ratio,rabid,quart,pseudo,provocative,proudly,principal's,pretenses,prenatal,pillar,photographers,photographed,pharmaceuticals,patron,pacing,overworked,originals,nicotine,newsletter,neighbours,murderous,miller's,mileage,mechanics,mayonnaise,massages,maroon,lucrative,losin,lil,lending,legislative,kat,juno,iran,interrogated,instruction,injunction,impartial,homing,heartbreaker,harm's,hacks,glands,giver,fraizh,flows,flips,flaunt,excellence,estimated,espionage,englishman,electrocuted,eisenhower,dusting,ducking,drifted,donna's,donating,dom,distribute,diem,daydream,cylon,curves,crutches,crates,cowards,covenant,converted,contributions,composed,comfortably,cod,cockpit,chummy,chitchat,childbirth,charities,businesswoman,brood,brewery,bp's,blatant,bethy,barring,bagged,awakened,assumes,assembled,asbestos,arty,artwork,arc,anthony's,aka,airplanes,accelerated,worshipped,winnings,why're,whilst,wesley's,volleyball,visualize,unprotected,unleash,unexpectedly,twentieth,turnpike,trays,translated,tones,three's,thicker,therapists,takeoff,sums,stub,streisand,storm's,storeroom,stethoscope,stacked,sponsors,spiteful,solutions,sneaks,snapping,slaughtered,slashed,simplest,silverware,shits,secluded,scruples,scrubs,scraps,scholar,ruptured,rubs,roaring,relying,reflected,refers,receptionist,recap,reborn,raisin,rainforest,rae's,raditch,radiator,pushover,pout,plastered,pharmacist,petroleum,perverse,perpetrator,passages,ornament,ointment,occupy,nineties,napping,nannies,mousse,mort,morocco,moors,momentary,modified,mitch's,misunderstandings,marina's,marcy's,marched,manipulator,malfunction,loot,limbs,latitude,lapd,laced,kivar,kickin,interface,infuriating,impressionable,imposing,holdup,hires,hick,hesitated,hebrew,hearings,headphones,hammering,groundwork,grotesque,greenhouse,gradually,graces,genetics,gauze,garter,gangsters,g's,frivolous,freelance,freeing,fours,forwarding,feud,ferrars,faulty,fantasizing,extracurricular,exhaust,empathy,educate,divorces,detonate,depraved,demeaning,declaring,deadlines,dea,daria's,dalai,cursing,cufflink,crows,coupons,countryside,coo,consultation,composer,comply,comforted,clive,claustrophobic,chef's,casinos,caroline's,capsule,camped,cairo,busboy,bred,bravery,bluth,biography,berserk,bennetts,baskets,attacker,aplastic,angrier,affectionate,zit,zapped,yorker,yarn,wormhole,weaken,vat,unrealistic,unravel,unimportant,unforgettable,twain,tv's,tush,turnout,trio,towed,tofu,textbooks,territorial,suspend,supplied,superbowl,sundays,stutter,stewardess,stepson,standin,sshh,specializes,spandex,souvenirs,sociopath,snails,slope,skeletons,shivering,sexier,sequel,sensory,selfishness,scrapbook,romania,riverside,rites,ritalin,rift,ribbons,reunite,remarry,relaxation,reduction,realization,rattling,rapist,quad,pup,psychosis,promotions,presumed,prepping,posture,poses,pleasing,pisses,piling,photographic,pfft,persecuted,pear,part's,pantyhose,padded,outline,organizations,operatives,oohh,obituary,northeast,nina's,neural,negotiator,nba,natty,nathan's,minimize,merl,menopause,mennihan,marty's,martimmys,makers,loyalties,literal,lest,laynie,lando,justifies,josh's,intimately,interact,integrated,inning,inexperienced,impotent,immortality,imminent,ich,horrors,hooky,holders,hinges,heartbreaking,handcuffed,gypsies,guacamole,grovel,graziella,goggles,gestapo,fussy,functional,filmmaker,ferragamo,feeble,eyesight,explosions,experimenting,enzo's,endorsement,enchanting,eee,ed's,duration,doubtful,dizziness,dismantle,disciplinary,disability,detectors,deserving,depot,defective,decor,decline,dangling,dancin,crumble,criteria,creamed,cramping,cooled,conceal,component,competitors,clockwork,clark's,circuits,chrissakes,chrissake,chopping,cabinets,buttercup,brooding,bonfire,blurt,bluestar,bloated,blackmailer,beforehand,bathed,bathe,barcode,banjo,banish,badges,babble,await,attentive,artifacts,aroused,antibodies,animosity,administrator,accomplishments,ya'll,wrinkled,wonderland,willed,whisk,waltzing,waitressing,vis,vin,vila,vigilant,upbringing,unselfish,unpopular,unmarried,uncles,trendy,trajectory,targeting,surroundings,stun,striped,starbucks,stamina,stalled,staking,stag,spoils,snuff,snooty,snide,shrinking,senorita,securities,secretaries,scrutiny,scoundrel,saline,salads,sails,rundown,roz's,roommate's,riddles,responses,resistant,requirement,relapse,refugees,recommending,raspberry,raced,prosperity,programme,presumably,preparations,posts,pom,plight,pleaded,pilot's,peers,pecan,particles,pantry,overturned,overslept,ornaments,opposing,niner,nfl,negligent,negligence,nailing,mutually,mucho,mouthed,monstrous,monarchy,minsk,matt's,mateo's,marking,manufacturing,manager's,malpractice,maintaining,lowly,loitering,logged,lingering,light's,lettin,lattes,kim's,kamal,justification,juror,junction,julie's,joys,johnson's,jillefsky,jacked,irritate,intrusion,inscription,insatiable,infect,inadequate,impromptu,icing,hmmmm,hefty,grammar,generate,gdc,gasket,frightens,flapping,firstborn,fire's,fig,faucet,exaggerated,estranged,envious,eighteenth,edible,downward,dopey,doesn,disposition,disposable,disasters,disappointments,dipped,diminished,dignified,diaries,deported,deficiency,deceit,dealership,deadbeat,curses,coven,counselors,convey,consume,concierge,clutches,christians,cdc,casbah,carefree,callous,cahoots,caf,brotherly,britches,brides,bop,bona,bethie,beige,barrels,ballot,ave,autographed,attendants,attachment,attaboy,astonishing,ashore,appreciative,antibiotic,aneurysm,afterlife,affidavit,zuko,zoning,work's,whats,whaddaya,weakened,watermelon,vasectomy,unsuspecting,trial's,trailing,toula,topanga,tonio,toasted,tiring,thereby,terrorized,tenderness,tch,tailing,syllable,sweats,suffocated,sucky,subconsciously,starvin,staging,sprouts,spineless,sorrows,snowstorm,smirk,slicery,sledding,slander,simmer,signora,sigmund,siege,siberia,seventies,sedate,scented,sampling,sal's,rowdy,rollers,rodent,revenue,retraction,resurrection,resigning,relocate,releases,refusal,referendum,recuperate,receptive,ranking,racketeering,queasy,proximity,provoking,promptly,probability,priors,princes,prerogative,premed,pornography,porcelain,poles,podium,pinched,pig's,pendant,packet,owner's,outsiders,outpost,orbing,opportunist,olanov,observations,nurse's,nobility,neurologist,nate's,nanobot,muscular,mommies,molested,misread,melon,mediterranean,mea,mastermind,mannered,maintained,mackenzie's,liberated,lesions,lee's,laundromat,landscape,lagoon,labeled,jolt,intercom,inspect,insanely,infrared,infatuation,indulgent,indiscretion,inconsiderate,incidents,impaired,hurrah,hungarian,howling,honorary,herpes,hasta,harassed,hanukkah,guides,groveling,groosalug,geographic,gaze,gander,galactica,futile,fridays,flier,fixes,fide,fer,feedback,exploiting,exorcism,exile,evasive,ensemble,endorse,emptied,dreary,dreamy,downloaded,dodged,doctored,displayed,disobeyed,disneyland,disable,diego's,dehydrated,defect,customary,csc,criticizing,contracted,contemplating,consists,concepts,compensate,commonly,colours,coins,coconuts,cockroaches,clogged,cincinnati,churches,chronicle,chilling,chaperon,ceremonies,catalina's,cant,cameraman,bulbs,bucklands,bribing,brava,bracelets,bowels,bobby's,bmw,bluepoint,baton,barred,balm,audit,astronomy,aruba,appetizers,appendix,antics,anointed,analogy,almonds,albuquerque,abruptly,yore,yammering,winch,white's,weston's,weirdness,wangler,vibrations,vendor,unmarked,unannounced,twerp,trespass,tres,travesty,transported,transfusion,trainee,towelie,topics,tock,tiresome,thru,theatrical,terrain,suspect's,straightening,staggering,spaced,sonar,socializing,sitcom,sinus,sinners,shambles,serene,scraped,scones,scepter,sarris,saberhagen,rouge,rigid,ridiculously,ridicule,reveals,rents,reflecting,reconciled,rate's,radios,quota,quixote,publicist,pubes,prune,prude,provider,propaganda,prolonged,projecting,prestige,precrime,postponing,pluck,perpetual,permits,perish,peppermint,peeled,particle,parliament,overdo,oriented,optional,nutshell,notre,notions,nostalgic,nomination,mulan,mouthing,monkey's,mistook,mis,milhouse,mel's,meddle,maybourne,martimmy,loon,lobotomy,livelihood,litigation,lippman,likeness,laurie's,kindest,kare,kaffee,jocks,jerked,jeopardizing,jazzed,investing,insured,inquisition,inhale,ingenious,inflation,incorrect,igby,ideals,holier,highways,hereditary,helmets,heirloom,heinous,haste,harmsway,hardship,hanky,gutters,gruesome,groping,governments,goofing,godson,glare,garment,founding,fortunes,foe,finesse,figuratively,ferrie,fda,external,examples,evacuation,ethnic,est,endangerment,enclosed,emphasis,dyed,dud,dreading,dozed,dorky,dmitri,divert,dissertation,discredit,director's,dialing,describes,decks,cufflinks,crutch,creator,craps,corrupted,coronation,contemporary,consumption,considerably,comprehensive,cocoon,cleavage,chile,carriers,carcass,cannery,bystander,brushes,bruising,bribery,brainstorm,bolted,binge,bart's,barracuda,baroness,ballistics,b's,astute,arroway,arabian,ambitions,alexandra's,afar,adventurous,adoptive,addicts,addictive,accessible,yadda,wilson's,wigs,whitelighters,wematanye,weeds,wedlock,wallets,walker's,vulnerability,vroom,vibrant,vertical,vents,uuuh,urgh,upped,unsettling,unofficial,unharmed,underlying,trippin,trifle,tracing,tox,tormenting,timothy's,threads,theaters,thats,tavern,taiwan,syphilis,susceptible,summary,suites,subtext,stickin,spices,sores,smacked,slumming,sixteenth,sinks,signore,shitting,shameful,shacked,sergei,septic,seedy,security's,searches,righteousness,removal,relish,relevance,rectify,recruits,recipient,ravishing,quickest,pupil,productions,precedence,potent,pooch,pledged,phoebs,perverted,peeing,pedicure,pastrami,passionately,ozone,overlooking,outnumbered,outlook,oregano,offender,nukes,novelty,nosed,nighty,nifty,mugs,mounties,motivate,moons,misinterpreted,miners,mercenary,mentality,mas,marsellus,mapped,malls,lupus,lumbar,lovesick,longitude,lobsters,likelihood,leaky,laundering,latch,japs,jafar,instinctively,inspires,inflicted,inflammation,indoors,incarcerated,imagery,hundredth,hula,hemisphere,handkerchief,hand's,gynecologist,guittierez,groundhog,grinning,graduates,goodbyes,georgetown,geese,fullest,ftl,floral,flashback,eyelashes,eyelash,excluded,evening's,evacuated,enquirer,endlessly,encounters,elusive,disarm,detest,deluding,dangle,crabby,cotillion,corsage,copenhagen,conjugal,confessional,cones,commandment,coded,coals,chuckle,christmastime,christina's,cheeseburgers,chardonnay,ceremonial,cept,cello,celery,carter's,campfire,calming,burritos,burp,buggy,brundle,broflovski,brighten,bows,borderline,blinked,bling,beauties,bauers,battered,athletes,assisting,articulate,alot,alienated,aleksandr,ahhhhh,agreements,agamemnon,accountants,zat,y'see,wrongful,writer's,wrapper,workaholic,wok,winnebago,whispered,warts,vikki's,verified,vacate,updated,unworthy,unprecedented,unanswered,trend,transformed,transform,trademark,tote,tonane,tolerated,throwin,throbbing,thriving,thrills,thorns,thereof,there've,terminator,tendencies,tarot,tailed,swab,sunscreen,stretcher,stereotype,spike's,soggy,sobbing,slopes,skis,skim,sizable,sightings,shucks,shrapnel,sever,senile,sections,seaboard,scripts,scorned,saver,roxanne's,resemble,red's,rebellious,rained,putty,proposals,prenup,positioned,portuguese,pores,pinching,pilgrims,pertinent,peeping,pamphlet,paints,ovulating,outbreak,oppression,opposites,occult,nutcracker,nutcase,nominee,newt,newsstand,newfound,nepal,mocked,midterms,marshmallow,manufacturer,managers,majesty's,maclaren,luscious,lowered,loops,leans,laurence's,krudski,knowingly,keycard,katherine's,junkies,juilliard,judicial,jolinar,jase,irritable,invaluable,inuit,intoxicating,instruct,insolent,inexcusable,induce,incubator,illustrious,hydrogen,hunsecker,hub,houseguest,honk,homosexuals,homeroom,holly's,hindu,hernia,harming,handgun,hallways,hallucination,gunshots,gums,guineas,groupies,groggy,goiter,gingerbread,giggling,geometry,genre,funded,frontal,frigging,fledged,fedex,feat,fairies,eyeball,extending,exchanging,exaggeration,esteemed,ergo,enlist,enlightenment,encyclopedia,drags,disrupted,dispense,disloyal,disconnect,dimitri,desks,dentists,delhi,delacroix,degenerate,deemed,decay,daydreaming,cushions,cuddly,corroborate,contender,congregation,conflicts,confessions,complexion,completion,compensated,cobbler,closeness,chilled,checkmate,channing,carousel,calms,bylaws,bud's,benefactor,belonging,ballgame,baiting,backstabbing,assassins,artifact,armies,appoint,anthropology,anthropologist,alzheimer's,allegedly,alex's,airspace,adversary,adolf,actin,acre,aced,accuses,accelerant,abundantly,abstinence,abc,zsa,zissou,zandt,yom,yapping,wop,witchy,winter's,willows,whee,whadaya,want's,walter's,waah,viruses,vilandra,veiled,unwilling,undress,undivided,underestimating,ultimatums,twirl,truckload,tremble,traditionally,touring,touche,toasting,tingling,tiles,tents,tempered,sussex,sulking,stunk,stretches,sponges,spills,softly,snipers,slid,sedan,screens,scourge,rooftop,rog,rivalry,rifles,riana,revolting,revisit,resisted,rejects,refreshments,redecorating,recurring,recapture,raysy,randomly,purchases,prostitutes,proportions,proceeded,prevents,pretense,prejudiced,precogs,pouting,poppie,poofs,pimple,piles,pediatrician,patrick's,pathology,padre,packets,paces,orvelle,oblivious,objectivity,nikki's,nighttime,nervosa,navigation,moist,moan,minors,mic,mexicans,meurice,melts,mau,mats,matchmaker,markings,maeby,lugosi,lipnik,leprechaun,kissy,kafka,italians,introductions,intestines,intervene,inspirational,insightful,inseparable,injections,informal,influential,inadvertently,illustrated,hussy,huckabees,hmo,hittin,hiss,hemorrhaging,headin,hazy,haystack,hallowed,haiti,haa,grudges,grenades,granilith,grandkids,grading,gracefully,godsend,gobbles,fyi,future's,fun's,fret,frau,fragrance,fliers,firms,finchley,fbi's,farts,eyewitnesses,expendable,existential,endured,embraced,elk,ekg,dude's,dragonfly,dorms,domination,directory,depart,demonstrated,delaying,degrading,deduction,darlings,dante's,danes,cylons,counsellor,cortex,cop's,coordinator,contraire,consensus,consciously,conjuring,congratulating,compares,commentary,commandant,cokes,centimeters,cc's,caucus,casablanca,buffay,buddy's,brooch,bony,boggle,blood's,bitching,bistro,bijou,bewitched,benevolent,bends,bearings,barren,arr,aptitude,antenna,amish,amazes,alcatraz,acquisitions,abomination,worldly,woodstock,withstand,whispers,whadda,wayward,wayne's,wailing,vinyl,variables,vanishing,upscale,untouchable,unspoken,uncontrollable,unavoidable,unattended,tuning,trite,transvestite,toupee,timid,timers,themes,terrorizing,teamed,taipei,t's,swana,surrendered,suppressed,suppress,stumped,strolling,stripe,storybook,storming,stomachs,stoked,stationery,springtime,spontaneity,sponsored,spits,spins,soiree,sociology,soaps,smarty,shootout,shar,settings,sentiments,senator's,scramble,scouting,scone,runners,rooftops,retract,restrictions,residency,replay,remainder,regime,reflexes,recycling,rcmp,rawdon,ragged,quirky,quantico,psychologically,prodigal,primo,pounce,potty,portraits,pleasantries,plane's,pints,phd,petting,perceive,patrons,parameters,outright,outgoing,onstage,officer's,o'connor,notwithstanding,noah's,nibble,newmans,neutralize,mutilated,mortality,monumental,ministers,millionaires,mentions,mcdonald's,mayflower,masquerade,mangy,macreedy,lunatics,luau,lover's,lovable,louie's,locating,lizards,limping,lasagna,largely,kwang,keepers,juvie,jaded,ironing,intuitive,intensely,insure,installation,increases,incantation,identifying,hysteria,hypnotize,humping,heavyweight,happenin,gung,griet,grasping,glorified,glib,ganging,g'night,fueled,focker,flunking,flimsy,flaunting,fixated,fitzwallace,fictional,fearing,fainting,eyebrow,exonerated,ether,ers,electrician,egotistical,earthly,dusted,dues,donors,divisions,distinguish,displays,dismissal,dignify,detonation,deploy,departments,debrief,dazzling,dawn's,dan'l,damnedest,daisies,crushes,crucify,cordelia's,controversy,contraband,contestants,confronting,communion,collapsing,cocked,clock's,clicks,cliche,circular,circled,chord,characteristics,chandelier,casualty,carburetor,callers,bup,broads,breathes,boca,bobbie's,bloodshed,blindsided,blabbing,binary,bialystock,bashing,ballerina,ball's,aviva,avalanche,arteries,appliances,anthem,anomaly,anglo,airstrip,agonizing,adjourn,abandonment,zack's,you's,yearning,yams,wrecker,word's,witnessing,winged,whence,wept,warsaw,warp,warhead,wagons,visibility,usc,unsure,unions,unheard,unfreeze,unfold,unbalanced,ugliest,troublemaker,tolerant,toddler,tiptoe,threesome,thirties,thermostat,tampa,sycamore,switches,swipe,surgically,supervising,subtlety,stung,stumbling,stubs,struggles,stride,strangling,stamp's,spruce,sprayed,socket,snuggle,smuggled,skulls,simplicity,showering,shhhhh,sensor,sci,sac,sabotaging,rumson,rounding,risotto,riots,revival,responds,reserves,reps,reproduction,repairman,rematch,rehearsed,reelection,redi,recognizing,ratty,ragging,radiology,racquetball,racking,quieter,quicksand,pyramids,pulmonary,puh,publication,prowl,provisions,prompt,premeditated,prematurely,prancing,porcupine,plated,pinocchio,perceived,peeked,peddle,pasture,panting,overweight,oversee,overrun,outing,outgrown,obsess,o'donnell,nyu,nursed,northwestern,norma's,nodding,negativity,negatives,musketeers,mugger,mounting,motorcade,monument,merrily,matured,massimo's,masquerading,marvellous,marlena's,margins,maniacs,mag,lumpy,lovey,louse,linger,lilies,libido,lawful,kudos,knuckle,kitchen's,kennedy's,juices,judgments,joshua's,jars,jams,jamal's,jag,itches,intolerable,intermission,interaction,institutions,infectious,inept,incentives,incarceration,improper,implication,imaginative,ight,hussein,humanitarian,huckleberry,horatio,holster,heiress,heartburn,hayley's,hap,gunna,guitarist,groomed,greta's,granting,graciously,glee,gentleman's,fulfillment,fugitives,fronts,founder,forsaking,forgives,foreseeable,flavors,flares,fixation,figment,fickle,featuring,featured,fantasize,famished,faith's,fades,expiration,exclamation,evolve,euro,erasing,emphasize,elevator's,eiffel,eerie,earful,duped,dulles,distributor,distorted,dissing,dissect,dispenser,dilated,digit,differential,diagnostic,detergent,desdemona,debriefing,dazzle,damper,cylinder,curing,crowbar,crispina,crafty,crackpot,courting,corrections,cordial,copying,consuming,conjunction,conflicted,comprehension,commie,collects,cleanup,chiropractor,charmer,chariot,charcoal,chaplain,challenger,census,cd's,cauldron,catatonic,capabilities,calculate,bullied,buckets,brilliantly,breathed,boss's,booths,bombings,boardroom,blowout,blower,blip,blindness,blazing,birthday's,biologically,bibles,biased,beseech,barbaric,band's,balraj,auditorium,audacity,assisted,appropriations,applicants,anticipating,alcoholics,airhead,agendas,aft,admittedly,adapt,absolution,abbot,zing,youre,yippee,wittlesey,withheld,willingness,willful,whammy,webber's,weakest,washes,virtuous,violently,videotapes,vials,vee,unplugged,unpacked,unfairly,und,turbulence,tumbling,troopers,tricking,trenches,tremendously,travelled,travelers,traitors,torches,tommy's,tinga,thyroid,texture,temperatures,teased,tawdry,tat,taker,sympathies,swiped,swallows,sundaes,suave,strut,structural,stone's,stewie,stepdad,spewing,spasm,socialize,slither,sky's,simulator,sighted,shutters,shrewd,shocks,sherry's,sgc,semantics,scout's,schizophrenic,scans,savages,satisfactory,rya'c,runny,ruckus,royally,roadblocks,riff,rewriting,revoke,reversal,repent,renovation,relating,rehearsals,regal,redecorate,recovers,recourse,reconnaissance,receives,ratched,ramali,racquet,quince,quiche,puppeteer,puking,puffed,prospective,projected,problemo,preventing,praises,pouch,posting,postcards,pooped,poised,piled,phoney,phobia,performances,patty's,patching,participating,parenthood,pardner,oppose,oozing,oils,ohm,ohhhhh,nypd,numbing,novelist,nostril,nosey,nominate,noir,neatly,nato,naps,nappa,nameless,muzzle,muh,mortuary,moronic,modesty,mitz,missionary,mimi's,midwife,mercenaries,mcclane,maxie's,matuka,mano,mam,maitre,lush,lumps,lucid,loosened,loosely,loins,lawnmower,lane's,lamotta,kroehner,kristen's,juggle,jude's,joins,jinxy,jessep,jaya,jamming,jailhouse,jacking,ironically,intruders,inhuman,infections,infatuated,indoor,indigestion,improvements,implore,implanted,id's,hormonal,hoboken,hillbilly,heartwarming,headway,headless,haute,hatched,hartmans,harping,hari,grapevine,graffiti,gps,gon,gogh,gnome,ged,forties,foreigners,fool's,flyin,flirted,fingernail,fdr,exploration,expectation,exhilarating,entrusted,enjoyment,embark,earliest,dumper,duel,dubious,drell,dormant,docking,disqualified,disillusioned,dishonor,disbarred,directive,dicey,denny's,deleted,del's,declined,custodial,crunchy,crises,counterproductive,correspondent,corned,cords,cor,coot,contributing,contemplate,containers,concur,conceivable,commissioned,cobblepot,cliffs,clad,chief's,chickened,chewbacca,checkout,carpe,cap'n,campers,calcium,buyin,buttocks,bullies,brown's,brigade,brain's,braid,boxed,bouncy,blueberries,blubbering,bloodstream,bigamy,bel,beeped,bearable,bank's,awarded,autographs,attracts,attracting,asteroid,arbor,arab,apprentice,announces,andie's,ammonia,alarming,aidan's,ahoy,ahm,zan,wretch,wimps,widows,widower,whirlwind,whirl,weather's,warms,war's,wack,villagers,vie,vandelay,unveiling,uno,undoing,unbecoming,ucla,turnaround,tribunal,togetherness,tickles,ticker,tended,teensy,taunt,system's,sweethearts,superintendent,subcommittee,strengthen,stomach's,stitched,standpoint,staffers,spotless,splits,soothe,sonnet,smothered,sickening,showdown,shouted,shepherds,shelters,shawl,seriousness,separates,sen,schooled,schoolboy,scat,sats,sacramento,s'mores,roped,ritchie's,resembles,reminders,regulars,refinery,raggedy,profiles,preemptive,plucked,pheromones,particulars,pardoned,overpriced,overbearing,outrun,outlets,onward,oho,ohmigod,nosing,norwegian,nightly,nicked,neanderthal,mosquitoes,mortified,moisture,moat,mime,milky,messin,mecha,markinson,marivellas,mannequin,manderley,maid's,madder,macready,maciver's,lookie,locusts,lisbon,lifetimes,leg's,lanna,lakhi,kholi,joke's,invasive,impersonate,impending,immigrants,ick,i's,hyperdrive,horrid,hopin,hombre,hogging,hens,hearsay,haze,harpy,harboring,hairdo,hafta,hacking,gun's,guardians,grasshopper,graded,gobble,gatehouse,fourteenth,foosball,floozy,fitzgerald's,fished,firewood,finalize,fever's,fencing,felons,falsely,fad,exploited,euphemism,entourage,enlarged,ell,elitist,elegance,eldest,duo,drought,drokken,drier,dredge,dramas,dossier,doses,diseased,dictator,diarrhea,diagnose,despised,defuse,defendant's,d'amour,crowned,cooper's,continually,contesting,consistently,conserve,conscientious,conjured,completing,commune,commissioner's,collars,coaches,clogs,chenille,chatty,chartered,chamomile,casing,calculus,calculator,brittle,breached,boycott,blurted,birthing,bikinis,bankers,balancing,astounding,assaulting,aroma,arbitration,appliance,antsy,amnio,alienating,aliases,aires,adolescence,administrative,addressing,achieving,xerox,wrongs,workload,willona,whistling,werewolves,wallaby,veterans,usin,updates,unwelcome,unsuccessful,unseemly,unplug,undermining,ugliness,tyranny,tuesdays,trumpets,transference,traction,ticks,tete,tangible,tagging,swallowing,superheroes,sufficiently,studs,strep,stowed,stow,stomping,steffy,stature,stairway,sssh,sprain,spouting,sponsoring,snug,sneezing,smeared,slop,slink,slew,skid,simultaneously,simulation,sheltered,shakin,sewed,sewage,seatbelt,scariest,scammed,scab,sanctimonious,samir,rushes,rugged,routes,romanov,roasting,rightly,retinal,rethinking,resulted,resented,reruns,replica,renewed,remover,raiding,raided,racks,quantity,purest,progressing,primarily,presidente,prehistoric,preeclampsia,postponement,portals,poppa,pop's,pollution,polka,pliers,playful,pinning,pharaoh,perv,pennant,pelvic,paved,patented,paso,parted,paramedic,panels,pampered,painters,padding,overjoyed,orthodox,organizer,one'll,octavius,occupational,oakdale's,nous,nite,nicknames,neurosurgeon,narrows,mitt,misled,mislead,mishap,milltown,milking,microscopic,meticulous,mediocrity,meatballs,measurements,mandy's,malaria,machete,lydecker's,lurch,lorelai's,linda's,layin,lavish,lard,knockin,khruschev,kelso's,jurors,jumpin,jugular,journalists,jour,jeweler,jabba,intersection,intellectually,integral,installment,inquiries,indulging,indestructible,indebted,implicated,imitate,ignores,hyperventilating,hyenas,hurrying,huron,horizontal,hermano,hellish,heheh,header,hazardous,hart's,harshly,harper's,handout,handbag,grunemann,gots,glum,gland,glances,giveaway,getup,gerome,furthest,funhouse,frosting,franchise,frail,fowl,forwarded,forceful,flavored,flank,flammable,flaky,fingered,finalists,fatherly,famine,fags,facilitate,exempt,exceptionally,ethic,essays,equity,entrepreneur,enduring,empowered,employers,embezzlement,eels,dusk,duffel,downfall,dotted,doth,doke,distressed,disobey,disappearances,disadvantage,dinky,diminish,diaphragm,deuces,deployed,delia's,davidson's,curriculum,curator,creme,courteous,correspondence,conquered,comforts,coerced,coached,clots,clarification,cite,chunks,chickie,chick's,chases,chaperoning,ceramic,ceased,cartons,capri,caper,cannons,cameron's,calves,caged,bustin,bungee,bulging,bringin,brie,boomhauer,blowin,blindfolded,blab,biscotti,bird's,beneficial,bastard's,ballplayer,bagging,automated,auster,assurances,aschen,arraigned,anonymity,annex,animation,andi,anchorage,alters,alistair's,albatross,agreeable,advancement,adoring,accurately,abduct,wolfi,width,weirded,watchers,washroom,warheads,voltage,vincennes,villains,victorian,urgency,upward,understandably,uncomplicated,uhuh,uhhhh,twitching,trig,treadmill,transactions,topped,tiffany's,they's,thermos,termination,tenorman,tater,tangle,talkative,swarm,surrendering,summoning,substances,strive,stilts,stickers,stationary,squish,squashed,spraying,spew,sparring,sorrel's,soaring,snout,snort,sneezed,slaps,skanky,singin,sidle,shreck,shortness,shorthand,shepherd's,sharper,shamed,sculptures,scanning,saga,sadist,rydell,rusik,roulette,rodi's,rockefeller,revised,resumes,restoring,respiration,reiber's,reek,recycle,recount,reacts,rabbit's,purge,purgatory,purchasing,providence,prostate,princesses,presentable,poultry,ponytail,plotted,playwright,pinot,pigtails,pianist,phillippe,philippines,peddling,paroled,owww,orchestrated,orbed,opted,offends,o'hara,noticeable,nominations,nancy's,myrtle's,music's,mope,moonlit,moines,minefield,metaphors,memoirs,mecca,maureen's,manning's,malignant,mainframe,magicks,maggots,maclaine,lobe,loathing,linking,leper,leaps,leaping,lashed,larch,larceny,lapses,ladyship,juncture,jiffy,jane's,jakov,invoke,interpreted,internally,intake,infantile,increasingly,inadmissible,implement,immense,howl,horoscope,hoof,homage,histories,hinting,hideaway,hesitating,hellbent,heddy,heckles,hat's,harmony's,hairline,gunpowder,guidelines,guatemala,gripe,gratifying,grants,governess,gorge,goebbels,gigolo,generated,gears,fuzz,frigid,freddo,freddie's,foresee,filters,filmed,fertile,fellowship,feeling's,fascination,extinction,exemplary,executioner,evident,etcetera,estimates,escorts,entity,endearing,encourages,electoral,eaters,earplugs,draped,distributors,disrupting,disagrees,dimes,devastate,detain,deposits,depositions,delicacy,delays,darklighter,dana's,cynicism,cyanide,cutters,cronus,convoy,continuous,continuance,conquering,confiding,concentrated,compartments,companions,commodity,combing,cofell,clingy,cleanse,christmases,cheered,cheekbones,charismatic,cabaret,buttle,burdened,buddhist,bruenell,broomstick,brin,brained,bozos,bontecou,bluntman,blazes,blameless,bizarro,benny's,bellboy,beaucoup,barry's,barkeep,bali,bala,bacterial,axis,awaken,astray,assailant,aslan,arlington,aria,appease,aphrodisiac,announcements,alleys,albania,aitoro's,activation,acme,yesss,wrecks,woodpecker,wondrous,window's,wimpy,willpower,widowed,wheeling,weepy,waxing,waive,vulture,videotaped,veritable,vascular,variations,untouched,unlisted,unfounded,unforeseen,two's,twinge,truffles,triggers,traipsing,toxin,tombstone,titties,tidal,thumping,thor's,thirds,therein,testicles,tenure,tenor,telephones,technicians,tarmac,talby,tackled,systematically,swirling,suicides,suckered,subtitles,sturdy,strangler,stockbroker,stitching,steered,staple,standup,squeal,sprinkler,spontaneously,splendor,spiking,spender,sovereign,snipe,snip,snagged,slum,skimming,significantly,siddown,showroom,showcase,shovels,shotguns,shoelaces,shitload,shifty,shellfish,sharpest,shadowy,sewn,seizing,seekers,scrounge,scapegoat,sayonara,satan's,saddled,rung,rummaging,roomful,romp,retained,residual,requiring,reproductive,renounce,reggie's,reformed,reconsidered,recharge,realistically,radioed,quirks,quadrant,punctual,public's,presently,practising,pours,possesses,poolhouse,poltergeist,pocketbook,plural,plots,pleasure's,plainly,plagued,pity's,pillars,picnics,pesto,pawing,passageway,partied,para,owing,openings,oneself,oats,numero,nostalgia,nocturnal,nitwit,nile,nexus,neuro,negotiated,muss,moths,mono,molecule,mixer,medicines,meanest,mcbeal,matinee,margate,marce,manipulations,manhunt,manger,magicians,maddie's,loafers,litvack,lightheaded,lifeguard,lawns,laughingstock,kodak,kink,jewellery,jessie's,jacko,itty,inhibitor,ingested,informing,indignation,incorporate,inconceivable,imposition,impersonal,imbecile,ichabod,huddled,housewarming,horizons,homicides,hobo,historically,hiccups,helsinki,hehe,hearse,harmful,hardened,gushing,gushie,greased,goddamit,gigs,freelancer,forging,fonzie,fondue,flustered,flung,flinch,flicker,flak,fixin,finalized,fibre,festivus,fertilizer,fenmore's,farted,faggots,expanded,exonerate,exceeded,evict,establishing,enormously,enforced,encrypted,emdash,embracing,embedded,elliot's,elimination,dynamics,duress,dupres,dowser,doormat,dominant,districts,dissatisfied,disfigured,disciplined,discarded,dibbs,diagram,detailing,descend,depository,defining,decorative,decoration,deathbed,death's,dazzled,da's,cuttin,cures,crowding,crepe,crater,crammed,costly,cosmopolitan,cortlandt's,copycat,coordinated,conversion,contradict,containing,constructed,confidant,condemning,conceited,computer's,commute,comatose,coleman's,coherent,clinics,clapping,circumference,chuppah,chore,choksondik,chestnuts,catastrophic,capitalist,campaigning,cabins,briault,bottomless,boop,bonnet,board's,bloomingdale's,blokes,blob,bids,berluti,beret,behavioral,beggars,bar's,bankroll,bania,athos,assassinate,arsenic,apperantly,ancestor,akron,ahhhhhh,afloat,adjacent,actresses,accordingly,accents,abe's,zipped,zeros,zeroes,zamir,yuppie,youngsters,yorkers,writ,wisest,wipes,wield,whyn't,weirdos,wednesdays,villages,vicksburg,variable,upchuck,untraceable,unsupervised,unpleasantness,unpaid,unhook,unconscionable,uncalled,turks,tumors,trappings,translating,tragedies,townie,timely,tiki,thurgood,things'll,thine,tetanus,terrorize,temptations,teamwork,tanning,tampons,tact,swarming,surfaced,supporter,stuart's,stranger's,straitjacket,stint,stimulation,steroid,statistically,startling,starry,squander,speculating,source's,sollozzo,sobriety,soar,sneaked,smithsonian,slugs,slaw,skit,skedaddle,sinker,similarities,silky,shortcomings,shipments,sheila's,severity,sellin,selective,seattle's,seasoned,scrubbed,scrooge,screwup,scrapes,schooling,scarves,saturdays,satchel,sandburg's,sandbox,salesmen,rooming,romances,revolving,revere,resulting,reptiles,reproach,reprieve,recreational,rearranging,realtor,ravine,rationalize,raffle,quoted,punchy,psychobabble,provocation,profoundly,problematic,prescriptions,preferable,praised,polishing,poached,plow,pledges,planetary,plan's,pirelli,perverts,peaked,pastures,pant,oversized,overdressed,outdid,outdated,oriental,ordinance,orbs,opponents,occurrence,nuptials,nominees,nineteenth,nefarious,mutiny,mouthpiece,motels,mopping,moon's,mongrel,monetary,mommie,missin,metaphorically,merv,mertin,memos,memento,melodrama,melancholy,measles,meaner,marches,mantel,maneuvers,maneuvering,mailroom,machine's,luring,listenin,lion's,lifeless,liege,licks,libraries,liberties,levon,legwork,lanka,lacked,kneecaps,kippur,kiddie,kaput,justifiable,jigsaw,issuing,islamic,insistent,insidious,innuendo,innit,inhabitants,individually,indicator,indecent,imaginable,illicit,hymn,hurling,humane,hospitalized,horseshit,hops,hondo,hemorrhoid,hella,healthiest,haywire,hamsters,halibut,hairbrush,hackers,guam,grouchy,grisly,griffin's,gratuitous,glutton,glimmer,gibberish,ghastly,geologist,gentler,generously,generators,geeky,gaga,furs,fuhrer,fronting,forklift,foolin,fluorescent,flats,flan,financed,filmmaking,fight's,faxes,faceless,extinguisher,expressions,expel,etched,entertainer,engagements,endangering,empress,egos,educator,ducked,dual,dramatically,dodgeball,dives,diverted,dissolved,dislocated,discrepancy,discovers,dink,devour,destroyers,derail,deputies,dementia,decisive,daycare,daft,cynic,crumbling,cowardice,cow's,covet,cornwallis,corkscrew,cookbook,conditioned,commendation,commandments,columns,coincidental,cobwebs,clouded,clogging,clicking,clasp,citizenship,chopsticks,chefs,chaps,catherine's,castles,cashing,carat,calmer,burgundy,bulldog's,brightly,brazen,brainwashing,bradys,bowing,booties,bookcase,boned,bloodsucking,blending,bleachers,bleached,belgian,bedpan,bearded,barrenger,bachelors,awwww,atop,assures,assigning,asparagus,arabs,apprehend,anecdote,amoral,alterations,alli,aladdin,aggravation,afoot,acquaintances,accommodating,accelerate,yakking,wreckage,worshipping,wladek,willya,willies,wigged,whoosh,whisked,wavelength,watered,warpath,warehouses,volts,vitro,violates,viewed,vicar,valuables,users,urging,uphill,unwise,untimely,unsavory,unresponsive,unpunished,unexplained,unconventional,tubby,trolling,treasurer,transfers,toxicology,totaled,tortoise,tormented,toothache,tingly,tina's,timmiihh,tibetan,thursdays,thoreau,terrifies,temperature's,temperamental,telegrams,ted's,technologies,teaming,teal'c's,talkie,takers,table's,symbiote,swirl,suffocate,subsequently,stupider,strapping,store's,steckler,standardized,stampede,stainless,springing,spreads,spokesperson,speeds,someway,snowflake,sleepyhead,sledgehammer,slant,slams,situation's,showgirl,shoveling,shmoopy,sharkbait,shan't,seminars,scrambling,schizophrenia,schematics,schedule's,scenic,sanitary,sandeman,saloon,sabbatical,rural,runt,rummy,rotate,reykjavik,revert,retrieved,responsive,rescheduled,requisition,renovations,remake,relinquish,rejoice,rehabilitation,recreation,reckoning,recant,rebuilt,rebadow,reassurance,reassigned,rattlesnake,ramble,racism,quor,prowess,prob,primed,pricey,predictions,prance,pothole,pocus,plains,pitches,pistols,persist,perpetrated,penal,pekar,peeling,patter,pastime,parmesan,paper's,papa's,panty,pail,pacemaker,overdrive,optic,operas,ominous,offa,observant,nothings,noooooo,nonexistent,nodded,nieces,neia,neglecting,nauseating,mutton,mutated,musket,munson's,mumbling,mowing,mouthful,mooseport,monologue,momma's,moly,mistrust,meetin,maximize,masseuse,martha's,marigold,mantini,mailer,madre,lowlifes,locksmith,livid,liven,limos,licenses,liberating,lhasa,lenin,leniency,leering,learnt,laughable,lashes,lasagne,laceration,korben,katan,kalen,jordan's,jittery,jesse's,jammies,irreplaceable,intubate,intolerant,inhaler,inhaled,indifferent,indifference,impound,imposed,impolite,humbly,holocaust,heroics,heigh,gunk,guillotine,guesthouse,grounding,groundbreaking,groom's,grips,grant's,gossiping,goatee,gnomes,gellar,fusion's,fumble,frutt,frobisher,freudian,frenchman,foolishness,flagged,fixture,femme,feeder,favored,favorable,fatso,fatigue,fatherhood,farmer's,fantasized,fairest,faintest,factories,eyelids,extravagant,extraterrestrial,extraordinarily,explicit,escalator,eros,endurance,encryption,enchantment's,eliminating,elevate,editors,dysfunction,drivel,dribble,dominican,dissed,dispatched,dismal,disarray,dinnertime,devastation,dermatologist,delicately,defrost,debutante,debacle,damone,dainty,cuvee,culpa,crucified,creeped,crayons,courtship,counsel's,convene,continents,conspicuous,congresswoman,confinement,conferences,confederate,concocted,compromises,comprende,composition,communism,comma,collectors,coleslaw,clothed,clinically,chug,chickenshit,checkin,chaotic,cesspool,caskets,cancellation,calzone,brothel,boomerang,bodega,bloods,blasphemy,black's,bitsy,bink,biff,bicentennial,berlini,beatin,beards,barbas,barbarians,backpacking,audiences,artist's,arrhythmia,array,arousing,arbitrator,aqui,appropriately,antagonize,angling,anesthetic,altercation,alice's,aggressor,adversity,adopting,acne,accordance,acathla,aaahhh,wreaking,workup,workings,wonderin,wolf's,wither,wielding,whopper,what'm,what'cha,waxed,vibrating,veterinarian,versions,venting,vasey,valor,validate,urged,upholstery,upgraded,untied,unscathed,unsafe,unlawful,uninterrupted,unforgiving,undies,uncut,twinkies,tucking,tuba,truffle,truck's,triplets,treatable,treasured,transmit,tranquility,townspeople,torso,tomei,tipsy,tinsel,timeline,tidings,thirtieth,tensions,teapot,tasks,tantrums,tamper,talky,swayed,swapping,sven,sulk,suitor,subjected,stylist,stroller,storing,stirs,statistical,standoff,staffed,squadron,sprinklers,springsteen,specimens,sparkly,song's,snowy,snobby,snatcher,smoother,smith's,sleepin,shrug,shortest,shoebox,shel,sheesh,shee,shackles,setbacks,sedatives,screeching,scorched,scanned,satyr,sammy's,sahib,rosemary's,rooted,rods,roadblock,riverbank,rivals,ridiculed,resentful,repellent,relates,registry,regarded,refugee,recreate,reconvene,recalled,rebuttal,realmedia,quizzes,questionnaire,quartet,pusher,punctured,pucker,propulsion,promo,prolong,professionalism,prized,premise,predators,portions,pleasantly,planet's,pigsty,physicist,phil's,penniless,pedestrian,paychecks,patiently,paternal,parading,pa's,overactive,ovaries,orderlies,oracles,omaha,oiled,offending,nudie,neonatal,neighborly,nectar,nautical,naught,moops,moonlighting,mobilize,mite,misleading,milkshake,mickey's,metropolitan,menial,meats,mayan,maxed,marketplace,mangled,magua,lunacy,luckier,llanview's,livestock,liters,liter,licorice,libyan,legislature,lasers,lansbury,kremlin,koreans,kooky,knowin,kilt,junkyard,jiggle,jest,jeopardized,jags,intending,inkling,inhalation,influences,inflated,inflammatory,infecting,incense,inbound,impractical,impenetrable,iffy,idealistic,i'mma,hypocrites,hurtin,humbled,hosted,homosexuality,hologram,hokey,hocus,hitchhiking,hemorrhoids,headhunter,hassled,harts,hardworking,haircuts,hacksaw,guerrilla,genitals,gazillion,gatherings,ganza's,gammy,gamesphere,fugue,fuels,forests,footwear,folly,folds,flexibility,flattened,flashlights,fives,filet,field's,famously,extenuating,explored,exceed,estrogen,envisioned,entails,emerged,embezzled,eloquent,egomaniac,dummies,duds,ducts,drowsy,drones,dragon's,drafts,doree,donovon,donny's,docked,dixon's,distributed,disorders,disguises,disclose,diggin,dickie's,detachment,deserting,depriving,demographic,delegation,defying,deductible,decorum,decked,daylights,daybreak,dashboard,darien,damnation,d'angelo's,cuddling,crunching,crickets,crazies,crayon,councilman,coughed,coordination,conundrum,contractors,contend,considerations,compose,complimented,compliance,cohaagen,clutching,cluster,clued,climbs,clader,chuck's,chromosome,cheques,checkpoint,chats,channeling,ceases,catholics,cassius,carver's,carasco,capped,capisce,cantaloupe,cancelling,campsite,camouflage,cambodia,burglars,bureaucracy,breakfasts,branding,bra'tac,book's,blueprint,bleedin,blaze's,blabbed,bisexual,bile,big's,beverages,beneficiary,battery's,basing,avert,avail,autobiography,atone,army's,arlyn,ares,architectural,approves,apothecary,anus,antiseptic,analytical,amnesty,alphabetical,alignment,aligned,aleikuum,advisory,advisors,advisement,adulthood,acquiring,accessed,zombie's,zadir,wrestled,wobbly,withnail,wheeled,whattaya,whacking,wedged,wanders,walkman,visionary,virtues,vincent's,vega's,vaginal,usage,unnamed,uniquely,unimaginable,undeniable,unconditionally,uncharted,unbridled,tweezers,tvmegasite,trumped,triumphant,trimming,tribes,treading,translates,tranquilizers,towing,tout,toontown,thunk,taps,taboo,suture,suppressing,succeeding,submission,strays,stonewall,stogie,stepdaughter,stalls,stace,squint,spouses,splashed,speakin,sounder,sorrier,sorrel,sorcerer,sombrero,solemnly,softened,socialist,snobs,snippy,snare,smoothing,slump,slimeball,slaving,sips,singular,silently,sicily,shiller,shayne's,shareholders,shakedown,sensations,seagulls,scrying,scrumptious,screamin,saucy,santoses,santos's,sanctions,roundup,roughed,rosary,robechaux,roadside,riley's,retrospect,resurrected,restoration,reside,researched,rescind,reproduce,reprehensible,repel,rendering,remodeling,religions,reconsidering,reciprocate,ratchet,rambaldi's,railroaded,raccoon,quasi,psychics,psat,promos,proclamation,problem's,prob'ly,pristine,printout,priestess,prenuptial,prediction,precedes,pouty,potter's,phoning,petersburg,peppy,pariah,parched,parcel,panes,overloaded,overdoing,operators,oldies,obesity,nymphs,nother,notebooks,nook,nikolai,nearing,nearer,mutation,municipal,monstrosity,minister's,milady,mieke,mephesto,memory's,melissa's,medicated,marshals,manilow,mammogram,mainstream,madhouse,m'lady,luxurious,luck's,lucas's,lotsa,loopy,logging,liquids,lifeboat,lesion,lenient,learner,lateral,laszlo,larva,kross,kinks,jinxed,involuntary,inventor,interim,insubordination,inherent,ingrate,inflatable,independently,incarnate,inane,imaging,hypoglycemia,huntin,humorous,humongous,hoodlum,honoured,honking,hitler's,hemorrhage,helpin,hearing's,hathor,hatching,hangar,halftime,guise,guggenheim,grrr,grotto,grandson's,grandmama,gorillas,godless,girlish,ghouls,gershwin,frosted,friday's,forwards,flutter,flourish,flagpole,finely,finder's,fetching,fatter,fated,faithfully,faction,fabrics,exposition,expo,exploits,exert,exclude,eviction,everwood's,evasion,espn,escorting,escalate,enticing,enroll,enhancement,endowed,enchantress,emerging,elopement,drills,drat,downtime,downloading,dorks,doorways,doctorate,divulge,dissociative,diss,disgraceful,disconcerting,dirtbag,deteriorating,deteriorate,destinies,depressive,dented,denim,defeating,decruz,decidedly,deactivate,daydreams,czar,curls,culprit,cues,crybaby,cruelest,critique,crippling,cretin,cranberries,cous,coupled,corvis,copped,convicts,converts,contingent,contests,complement,commend,commemorate,combinations,coastguard,cloning,cirque,churning,chock,chivalry,chemotherapy,charlotte's,chancellor's,catalogues,cartwheels,carpets,carols,canister,camera's,buttered,bureaucratic,bundt,buljanoff,bubbling,brokers,broaden,brimstone,brainless,borneo,bores,boing,bodied,billie's,biceps,beijing,bead,badmouthing,bad's,avec,autopilot,attractions,attire,atoms,atheist,ascertain,artificially,archbishop,aorta,amps,ampata,amok,alloy,allied,allenby,align,albeit,aired,aint,adjoining,accosted,abyss,absolve,aborted,aaagh,aaaaaah,your's,yonder,yellin,yearly,wyndham,wrongdoing,woodsboro,wigging,whup,wasteland,warranty,waltzed,walnuts,wallace's,vividly,vibration,verses,veggie,variation,validation,unnecessarily,unloaded,unicorns,understated,undefeated,unclean,umbrellas,tyke,twirling,turpentine,turnover,tupperware,tugger,triangles,triage,treehouse,tract,toil,tidbit,tickled,thud,threes,thousandth,thingie,terminally,temporal,teething,tassel,talkies,syndication,syllables,swoon,switchboard,swerved,suspiciously,superiority,successor,subsequentlyne,subsequent,subscribe,strudel,stroking,strictest,steven's,stensland,stefan's,starsky,starin,stannart,squirming,squealing,sorely,solidarity,softie,snookums,sniveling,snail,smidge,smallpox,sloth,slab,skulking,singled,simian,silo,sightseeing,siamese,shudder,shoppers,shax,sharpen,shannen,semtex,sellout,secondhand,season's,seance,screenplay,scowl,scorn,scandals,santiago's,safekeeping,sacked,russe,rummage,rosie's,roshman,roomies,roaches,rinds,retrace,retires,resuscitate,restrained,residential,reservoir,rerun,reputations,rekall,rejoin,refreshment,reenactment,recluse,ravioli,raves,ranked,rampant,rama,rallies,raking,purses,punishable,punchline,puked,provincial,prosky,prompted,processor,previews,prepares,poughkeepsie,poppins,polluted,placenta,pissy,petulant,peterson's,perseverance,persecution,pent,peasants,pears,pawns,patrols,pastries,partake,paramount,panky,palate,overzealous,overthrow,overs,oswald's,oskar,originated,orchids,optical,onset,offenses,obstructing,objectively,obituaries,obedient,obedience,novice,nothingness,nitrate,newer,nets,mwah,musty,mung,motherly,mooning,monique's,momentous,moby,mistaking,mistakenly,minutemen,milos,microchip,meself,merciless,menelaus,mazel,mauser,masturbate,marsh's,manufacturers,mahogany,lysistrata,lillienfield,likable,lightweight,liberate,leveled,letdown,leer,leeloo,larynx,lardass,lainey,lagged,lab's,klorel,klan,kidnappings,keyed,karmic,jive,jiggy,jeebies,isabel's,irate,iraqi,iota,iodine,invulnerable,investor,intrusive,intricate,intimidation,interestingly,inserted,insemination,inquire,innate,injecting,inhabited,informative,informants,incorporation,inclination,impure,impasse,imbalance,illiterate,i'ma,i'ii,hurled,hunts,hispanic,hematoma,help's,helen's,headstrong,harmonica,hark,handmade,handiwork,gymnasium,growling,governors,govern,gorky,gook,girdle,getcha,gesundheit,gazing,gazette,garde,galley,funnel,fred's,fossils,foolishly,fondness,flushing,floris,firearm,ferocious,feathered,fateful,fancies,fakes,faker,expressway,expire,exec,ever'body,estates,essentials,eskimos,equations,eons,enlightening,energetic,enchilada,emmi,emissary,embolism,elsinore,ecklie,drenched,drazi,doped,dogging,documentation,doable,diverse,disposed,dislikes,dishonesty,disengage,discouraging,diplomat,diplomacy,deviant,descended,derailed,depleted,demi,deformed,deflect,defines,defer,defcon,deactivated,crips,creditors,counters,corridors,cordy's,conversation's,constellations,congressmen,congo,complimenting,colombian,clubbing,clog,clint's,clawing,chromium,chimes,chicken's,chews,cheatin,chaste,ceremony's,cellblock,ceilings,cece,caving,catered,catacombs,calamari,cabbie,bursts,bullying,bucking,brulee,brits,brisk,breezes,brandon's,bounces,boudoir,blockbuster,binks,better'n,beluga,bellied,behrani,behaves,bedding,battalion,barriers,banderas,balmy,bakersfield,badmouth,backers,avenging,atat,aspiring,aromatherapy,armpit,armoire,anythin,another's,anonymously,anniversaries,alonzo's,aftershave,affordable,affliction,adrift,admissible,adieu,activist,acquittal,yucky,yearn,wrongly,wino,whitter,whirlpool,wendigo,watchdog,wannabes,walkers,wakey,vomited,voicemail,verb,vans,valedictorian,vacancy,uttered,up's,unwed,unrequited,unnoticed,unnerving,unkind,unjust,uniformed,unconfirmed,unadulterated,unaccounted,uglier,tyler's,twix,turnoff,trough,trolley,trampled,tramell,traci's,tort,toads,titled,timbuktu,thwarted,throwback,thon,thinker,thimble,tasteless,tarantula,tammy's,tamale,takeovers,symposium,symmetry,swish,supposing,supporters,suns,sully,streaking,strands,statutory,starlight,stargher,starch,stanzi,stabs,squeamish,spokane,splattered,spiritually,spilt,sped,speciality,spacious,soundtrack,smacking,slain,slag,slacking,skywire,skips,skeet,skaara,simpatico,shredding,showin,shortcuts,shite,shielding,sheep's,shamelessly,serafine,sentimentality,sect,secretary's,seasick,scientifically,scholars,schemer,scandalous,saturday's,salts,saks,sainted,rustic,rugs,riedenschneider,ric's,rhyming,rhetoric,revolt,reversing,revel,retractor,retards,retaliation,resurrect,remiss,reminiscing,remanded,reluctance,relocating,relied,reiben,regions,regains,refuel,refresher,redoing,redheaded,redeemed,recycled,reassured,rearranged,rapport,qumar,prowling,promotional,promoter,preserving,prejudices,precarious,powwow,pondering,plunger,plunged,pleasantville,playpen,playback,pioneers,physicians,phlegm,perfected,pancreas,pakistani,oxide,ovary,output,outbursts,oppressed,opal's,ooohhh,omoroca,offed,o'toole,nurture,nursemaid,nosebleed,nixon's,necktie,muttering,munchies,mucking,mogul,mitosis,misdemeanor,miscarried,minx,millionth,migraines,midler,methane,metabolism,merchants,medicinal,margaret's,manifestation,manicurist,mandelbaum,manageable,mambo,malfunctioned,mais,magnesium,magnanimous,loudmouth,longed,lifestyles,liddy,lickety,leprechauns,lengthy,komako,koji's,klute,kennel,kathy's,justifying,jerusalem,israelis,isle,irreversible,inventing,invariably,intervals,intergalactic,instrumental,instability,insinuate,inquiring,ingenuity,inconclusive,incessant,improv,impersonation,impeachment,immigrant,id'd,hyena,humperdinck,humm,hubba,housework,homeland,holistic,hoffa,hither,hissy,hippy,hijacked,hero's,heparin,hellooo,heat's,hearth,hassles,handcuff,hairstyle,hadda,gymnastics,guys'll,gutted,gulp,gulls,guard's,gritty,grievous,gravitational,graft,gossamer,gooder,glory's,gere,gash,gaming,gambled,galaxies,gadgets,fundamentals,frustrations,frolicking,frock,frilly,fraser's,francais,foreseen,footloose,fondly,fluent,flirtation,flinched,flight's,flatten,fiscal,fiercely,felicia's,fashionable,farting,farthest,farming,facade,extends,exposer,exercised,evading,escrow,errr,enzymes,energies,empathize,embryos,embodiment,ellsberg,electromagnetic,ebola,earnings,dulcinea,dreamin,drawbacks,drains,doyle's,doubling,doting,doose's,doose,doofy,dominated,dividing,diversity,disturbs,disorderly,disliked,disgusts,devoid,detox,descriptions,denominator,demonstrating,demeanor,deliriously,decode,debauchery,dartmouth,d'oh,croissant,cravings,cranked,coworkers,councilor,council's,convergence,conventions,consistency,consist,conquests,conglomerate,confuses,confiscate,confines,confesses,conduit,compress,committee's,commanded,combed,colonel's,coated,clouding,clamps,circulating,circa,cinch,chinnery,celebratory,catalogs,carpenters,carnal,carla's,captures,capitan,capability,canin,canes,caitlin's,cadets,cadaver,cable's,bundys,bulldozer,buggers,bueller,bruno's,breakers,brazilian,branded,brainy,booming,bookstores,bloodbath,blister,bittersweet,biologist,billed,betty's,bellhop,beeping,beaut,beanstalk,beady,baudelaire,bartenders,bargains,ballad,backgrounds,averted,avatar's,atmospheric,assert,assassinated,armadillo,archive,appreciating,appraised,antlers,anterior,alps,aloof,allowances,alleyway,agriculture,agent's,affleck,acknowledging,achievements,accordion,accelerator,abracadabra,abject,zinc,zilch,yule,yemen,xanax,wrenching,wreath,wouldn,witted,widely,wicca,whorehouse,whooo,whips,westchester,websites,weaponry,wasn,walsh's,vouchers,vigorous,viet,victimized,vicodin,untested,unsolicited,unofficially,unfocused,unfettered,unfeeling,unexplainable,uneven,understaffed,underbelly,tutorial,tuberculosis,tryst,trois,trix,transmitting,trampoline,towering,topeka,tirade,thieving,thang,tentacles,teflon,teachings,tablets,swimmin,swiftly,swayzak,suspecting,supplying,suppliers,superstitions,superhuman,subs,stubbornness,structures,streamers,strattman,stonewalling,stimulate,stiffs,station's,stacking,squishy,spout,splice,spec,sonrisa,smarmy,slows,slicing,sisterly,sierra's,sicilian,shrill,shined,shift's,seniority,seine,seeming,sedley,seatbelts,scour,scold,schoolyard,scarring,sash,sark's,salieri,rustling,roxbury,richly,rexy,rex's,rewire,revved,retriever,respective,reputable,repulsed,repeats,rendition,remodel,relocated,reins,reincarnation,regression,reconstruction,readiness,rationale,rance,rafters,radiohead,radio's,rackets,quarterly,quadruple,pumbaa,prosperous,propeller,proclaim,probing,privates,pried,prewedding,premeditation,posturing,posterity,posh,pleasurable,pizzeria,pish,piranha,pimps,penmanship,penchant,penalties,pelvis,patriotism,pasa,papaya,packaging,overturn,overture,overstepped,overcoat,ovens,outsmart,outed,orient,ordained,ooohh,oncologist,omission,olly,offhand,odour,occurring,nyazian,notarized,nobody'll,nightie,nightclubs,newsweek,nesting,navel,nationwide,nabbed,naah,mystique,musk,mover,mortician,morose,moratorium,monster's,moderate,mockingbird,mobsters,misconduct,mingling,mikey's,methinks,metaphysical,messengered,merge,merde,medallion,mathematical,mater,mason's,masochist,martouf,martians,marinara,manray,manned,mammal,majorly,magnifying,mackerel,mabel's,lyme,lurid,lugging,lonnegan,loathsome,llantano,liszt,listings,limiting,liberace,leprosy,latinos,lanterns,lamest,laferette,ladybird,kraut,kook,kits,kipling,joyride,inward,intestine,innocencia,inhibitions,ineffectual,indisposed,incurable,incumbent,incorporated,inconvenienced,inanimate,improbable,implode,idea's,hypothesis,hydrant,hustling,hustled,huevos,how'm,horseshoe,hooey,hoods,honcho,hinge,hijack,heroism,hermit,heimlich,harvesting,hamunaptra,haladki,haiku,haggle,haaa,gutsy,grunting,grueling,grit,grifter,grievances,gribbs,greevy,greeted,green's,grandstanding,godparents,glows,glistening,glider,gimmick,genocide,gaping,fraiser,formalities,foreigner,forecast,footprint,folders,foggy,flaps,fitty,fiends,femmes,fearful,fe'nos,favours,fabio,eyeing,extort,experimentation,expedite,escalating,erect,epinephrine,entitles,entice,enriched,enable,emissions,eminence,eights,ehhh,educating,eden's,earthquakes,earthlings,eagerly,dunville,dugout,draining,doublemeat,doling,disperse,dispensing,dispatches,dispatcher,discoloration,disapproval,diners,dieu,diddly,dictates,diazepam,descendants,derogatory,deposited,delights,defies,decoder,debates,dealio,danson,cutthroat,crumbles,crud,croissants,crematorium,craftsmanship,crafted,could'a,correctional,cordless,cools,contradiction,constitute,conked,confine,concealing,composite,complicates,communique,columbian,cockamamie,coasters,clusters,clobbered,clipping,clipboard,clergy,clemenza,cleanser,circumcision,cindy's,chisel,character's,chanukah,certainaly,centerpiece,cellmate,cartoonist,cancels,cadmium,buzzed,busiest,bumstead,bucko,browsing,broth,broader,break's,braver,boundary,boggling,bobbing,blurred,birkhead,bethesda,benet,belvedere,bellies,begrudge,beckworth,bebe's,banky,baldness,bagpipes,baggy,babysitters,aversion,auxiliary,attributes,attain,astonished,asta,assorted,aspirations,arnold's,area's,appetites,apparel,apocalyptic,apartment's,announcer,angina,amiss,ambulances,allo,alleviate,alibis,algeria,alaskan,airway,affiliated,aerial,advocating,adrenalin,admires,adhesive,actively,accompanying,zeta,yoyou,yoke,yachts,wreaked,wracking,woooo,wooing,wised,winnie's,wind's,wilshire,wedgie,watson's,warden's,waging,violets,vincey,victorious,victories,velcro,vastly,valves,valley's,uplifting,untrustworthy,unmitigated,universities,uneventful,undressing,underprivileged,unburden,umbilical,twigs,tweet,tweaking,turquoise,trustees,truckers,trimmed,triggering,treachery,trapping,tourism,tosses,torching,toothpick,toga,toasty,toasts,tiamat,thickens,ther,tereza,tenacious,temperament,televised,teldar,taxis,taint,swill,sweatin,sustaining,surgery's,surgeries,succeeds,subtly,subterranean,subject's,subdural,streep,stopwatch,stockholder,stillwater,steamer,stang's,stalkers,squished,squeegee,splinters,spliced,splat,spied,specialized,spaz,spackle,sophistication,snapshots,smoky,smite,sluggish,slithered,skin's,skeeters,sidewalks,sickly,shrugs,shrubbery,shrieking,shitless,shithole,settin,servers,serge,sentinels,selfishly,segments,scarcely,sawdust,sanitation,sangria,sanctum,samantha's,sahjhan,sacrament,saber,rustle,rupture,rump,roving,rousing,rosomorf,rosario's,rodents,robust,rigs,riddled,rhythms,revelations,restart,responsibly,repression,reporter's,replied,repairing,renoir,remoray,remedial,relocation,relies,reinforcement,refundable,redirect,recheck,ravenwood,rationalizing,ramus,ramsey's,ramelle,rails,radish,quivering,pyjamas,puny,psychos,prussian,provocations,prouder,protestors,protesters,prohibited,prohibit,progression,prodded,proctologist,proclaimed,primordial,pricks,prickly,predatory,precedents,praising,pragmatic,powerhouse,posterior,postage,porthos,populated,poly,pointe,pivotal,pinata,persistence,performers,pentangeli,pele,pecs,pathetically,parka,parakeet,panicky,pandora's,pamphlets,paired,overthruster,outsmarted,ottoman,orthopedic,oncoming,oily,offing,nutritious,nuthouse,nourishment,nietzsche,nibbling,newlywed,newcomers,need's,nautilus,narcissist,myths,mythical,mutilation,mundane,mummy's,mummies,mumble,mowed,morvern,mortem,mortal's,mopes,mongolian,molasses,modification,misplace,miscommunication,miney,militant,midlife,mens,menacing,memorizing,memorabilia,membrane,massaging,masking,maritime,mapping,manually,magnets,ma's,luxuries,lows,lowering,lowdown,lounging,lothario,longtime,liposuction,lieutenant's,lidocaine,libbets,lewd,levitate,leslie's,leeway,lectured,lauren's,launcher,launcelot,latent,larek,lagos,lackeys,kumbaya,kryptonite,knapsack,keyhole,kensington,katarangura,kann,junior's,juiced,jugs,joyful,jihad,janitor's,jakey,ironclad,invoice,intertwined,interlude,interferes,insurrection,injure,initiating,infernal,india's,indeedy,incur,incorrigible,incantations,imprint,impediment,immersion,immensely,illustrate,ike's,igloo,idly,ideally,hysterectomy,hyah,house's,hour's,hounded,hooch,honeymoon's,hollering,hogs,hindsight,highs,high's,hiatus,helix,heirs,heebie,havesham,hassan's,hasenfuss,hankering,hangers,hakuna,gutless,gusto,grubbing,grrrr,greg's,grazed,gratification,grandeur,gorak,godammit,gnawing,glanced,gladiators,generating,galahad,gaius,furnished,funeral's,fundamentally,frostbite,frees,frazzled,fraulein,fraternizing,fortuneteller,formaldehyde,followup,foggiest,flunky,flickering,flashbacks,fixtures,firecrackers,fines,filly,figger,fetuses,fella's,feasible,fates,eyeliner,extremities,extradited,expires,experimented,exiting,exhibits,exhibited,exes,excursion,exceedingly,evaporate,erupt,equilibrium,epileptic,ephram's,entrails,entities,emporium,egregious,eggshells,easing,duwayne,drone,droll,dreyfuss,drastically,dovey,doubly,doozy,donkeys,donde,dominate,distrust,distributing,distressing,disintegrate,discreetly,disagreements,diff,dick's,devised,determines,descending,deprivation,delegate,dela,degradation,decision's,decapitated,dealin,deader,dashed,darkroom,dares,daddies,dabble,cycles,cushy,currents,cupcakes,cuffed,croupier,croak,criticized,crapped,coursing,cornerstone,copyright,coolers,continuum,contaminate,cont,consummated,construed,construct,condos,concoction,compulsion,committees,commish,columnist,collapses,coercion,coed,coastal,clemency,clairvoyant,circulate,chords,chesterton,checkered,charlatan,chaperones,categorically,cataracts,carano,capsules,capitalize,cache,butcher's,burdon,bullshitting,bulge,buck's,brewed,brethren,bren,breathless,breasted,brainstorming,bossing,borealis,bonsoir,bobka,boast,blimp,bleu,bleep,bleeder,blackouts,bisque,binford's,billboards,bernie's,beecher's,beatings,bayberry,bashed,bartlet's,bapu,bamboozled,ballon,balding,baklava,baffled,backfires,babak,awkwardness,attributed,attest,attachments,assembling,assaults,asphalt,arthur's,arthritis,armenian,arbitrary,apologizes,anyhoo,antiquated,alcante,agency's,advisable,advertisement,adventurer,abundance,aahhh,aaahh,zatarc,yous,york's,yeti,yellowstone,yearbooks,yakuza,wuddya,wringing,woogie,womanhood,witless,winging,whatsa,wetting,wessex,wendy's,way's,waterproof,wastin,washington's,wary,voom,volition,volcanic,vogelman,vocation,visually,violinist,vindicated,vigilance,viewpoint,vicariously,venza,vasily,validity,vacuuming,utensils,uplink,unveil,unloved,unloading,uninhibited,unattached,ukraine,typo,tweaked,twas,turnips,tunisia,tsch,trinkets,tribune,transmitters,translator,train's,toured,toughen,toting,topside,topical,toothed,tippy,tides,theology,terrors,terrify,tentative,technologically,tarnish,target's,tallest,tailored,tagliati,szpilman,swimmers,swanky,susie's,surly,supple,sunken,summation,suds,suckin,substantially,structured,stockholm,stepmom,squeaking,springfield's,spooks,splashmore,spanked,souffle,solitaire,solicitation,solarium,smooch,smokers,smog,slugged,slobbering,skylight,skimpy,situated,sinuses,simplify,silenced,sideburns,sid's,shutdown,shrinkage,shoddy,shhhhhh,shelling,shelled,shareef,shangri,shakey's,seuss,servicing,serenade,securing,scuffle,scrolls,scoff,scholarships,scanners,sauerkraut,satisfies,satanic,sars,sardines,sarcophagus,santino,sandi's,salvy,rusted,russells,ruby's,rowboat,routines,routed,rotating,rolfsky,ringside,rigging,revered,retreated,respectability,resonance,resembling,reparations,reopened,renewal,renegotiate,reminisce,reluctantly,reimburse,regimen,regaining,rectum,recommends,recognizable,realism,reactive,rawhide,rappaport's,raincoat,quibble,puzzled,pursuits,purposefully,puns,pubic,psychotherapy,prosecution's,proofs,proofing,professor's,prevention,prescribing,prelim,positioning,pore,poisons,poaching,pizza's,pertaining,personalized,personable,peroxide,performs,pentonville,penetrated,peggy's,payphone,payoffs,participated,park's,parisian,palp,paleontology,overhaul,overflowing,organised,oompa,ojai,offenders,oddest,objecting,o'hare,o'daniel,notches,noggin,nobody'd,nitrogen,nightstand,niece's,nicky's,neutralized,nervousness,nerdy,needlessly,navigational,narrative,narc,naquadah,nappy,nantucket,nambla,myriad,mussolini,mulberry,mountaineer,mound,motherfuckin,morrie,monopolizing,mohel,mistreated,misreading,misbehave,miramax,minstrel,minivan,milligram,milkshakes,milestone,middleweight,michelangelo,metamorphosis,mesh,medics,mckinnon's,mattresses,mathesar,matchbook,matata,marys,marco's,malucci,majored,magilla,magic's,lymphoma,lowers,lordy,logistics,linens,lineage,lindenmeyer,limelight,libel,leery's,leased,leapt,laxative,lather,lapel,lamppost,laguardia,labyrinth,kindling,key's,kegs,kegger,kawalsky,juries,judo,jokin,jesminder,janine's,izzy,israeli,interning,insulation,institutionalized,inspected,innings,innermost,injun,infallible,industrious,indulgence,indonesia,incinerator,impossibility,imports,impart,illuminate,iguanas,hypnotic,hyped,huns,housed,hostilities,hospitable,hoses,horton's,homemaker,history's,historian,hirschmuller,highlighted,hideout,helpers,headset,guardianship,guapo,guantanamo,grubby,greyhound,grazing,granola,granddaddy,gotham's,goren,goblet,gluttony,glucose,globes,giorno,gillian's,getter,geritol,gassed,gang's,gaggle,freighter,freebie,frederick's,fractures,foxhole,foundations,fouled,foretold,forcibly,folklore,floorboards,floods,floated,flippers,flavour,flaked,firstly,fireflies,feedings,fashionably,fascism,farragut,fallback,factions,facials,exterminate,exited,existent,exiled,exhibiting,excites,everything'll,evenin,evaluated,ethically,entree,entirety,ensue,enema,empath,embryo,eluded,eloquently,elle,eliminates,eject,edited,edema,echoes,earns,dumpling,drumming,droppings,drazen's,drab,dolled,doll's,doctrine,distasteful,disputing,disputes,displeasure,disdain,disciples,diamond's,develops,deterrent,detection,dehydration,defied,defiance,decomposing,debated,dawned,darken,daredevil,dailies,cyst,custodian,crusts,crucifix,crowning,crier,crept,credited,craze,crawls,coveted,couple's,couldn,corresponding,correcting,corkmaster,copperfield,cooties,coopers,cooperated,controller,contraption,consumes,constituents,conspire,consenting,consented,conquers,congeniality,computerized,compute,completes,complains,communicator,communal,commits,commendable,colonels,collide,coladas,colada,clout,clooney,classmate,classifieds,clammy,claire's,civility,cirrhosis,chink,chemically,characterize,censor,catskills,cath,caterpillar,catalyst,carvers,carts,carpool,carelessness,career's,cardio,carbs,captivity,capeside's,capades,butabi,busmalis,bushel,burping,buren,burdens,bunks,buncha,bulldozers,browse,brockovich,bria,breezy,breeds,breakthroughs,bravado,brandy's,bracket,boogety,bolshevik,blossoms,bloomington,blooming,bloodsucker,blockade,blight,blacksmith,betterton,betrayer,bestseller,bennigan's,belittle,beeps,bawling,barts,bartending,barbed,bankbooks,back's,babs,babish,authors,authenticity,atropine,astronomical,assertive,arterial,armbrust,armageddon,aristotle,arches,anyanka,annoyance,anemic,anck,anago,ali's,algiers,airways,airwaves,air's,aimlessly,ails,ahab,afflicted,adverse,adhere,accuracy,aaargh,aaand,zest,yoghurt,yeast,wyndham's,writings,writhing,woven,workable,winking,winded,widen,whooping,whiter,whip's,whatya,whacko,we's,wazoo,wasp,waived,vlad,virile,vino,vic's,veterinary,vests,vestibule,versed,venetian,vaughn's,vanishes,vacancies,urkel,upwards,uproot,unwarranted,unscheduled,unparalleled,undertaking,undergrad,tweedle,turtleneck,turban,trickery,travolta,transylvania,transponder,toyed,townhouse,tonto,toed,tion,tier,thyself,thunderstorm,thnk,thinning,thinkers,theatres,thawed,tether,tempus,telegraph,technicalities,tau'ri,tarp,tarnished,tara's,taggert's,taffeta,tada,tacked,systolic,symbolize,swerve,sweepstakes,swami,swabs,suspenders,surfers,superwoman,sunsets,sumo,summertime,succulent,successes,subpoenas,stumper,stosh,stomachache,stewed,steppin,stepatech,stateside,starvation,staff's,squads,spicoli,spic,sparing,soulless,soul's,sonnets,sockets,snit,sneaker,snatching,smothering,slush,sloman,slashing,sitters,simpson's,simpleton,signify,signal's,sighs,sidra,sideshow,sickens,shunned,shrunken,showbiz,shopped,shootings,shimmering,shakespeare's,shagging,seventeenth,semblance,segue,sedation,scuzzlebutt,scumbags,scribble,screwin,scoundrels,scarsdale,scamp,scabs,saucers,sanctioned,saintly,saddened,runaways,runaround,rumored,rudimentary,rubies,rsvp,rots,roman's,ripley's,rheya,revived,residing,resenting,researcher,repertoire,rehashing,rehabilitated,regrettable,regimental,refreshed,reese's,redial,reconnecting,rebirth,ravenous,raping,ralph's,railroads,rafting,rache,quandary,pylea,putrid,punitive,puffing,psychopathic,prunes,protests,protestant,prosecutors,proportional,progressed,prod,probate,prince's,primate,predicting,prayin,practitioner,possessing,pomegranate,polgara,plummeting,planners,planing,plaintiffs,plagues,pitt's,pithy,photographer's,philharmonic,petrol,perversion,personals,perpetrators,perm,peripheral,periodic,perfecto,perched,pees,peeps,pedigree,peckish,pavarotti,partnered,palette,pajama,packin,pacifier,oyez,overstepping,outpatient,optimum,okama,obstetrician,nutso,nuance,noun,noting,normalcy,normal's,nonnegotiable,nomak,nobleman,ninny,nines,nicey,newsflash,nevermore,neutered,nether,nephew's,negligee,necrosis,nebula,navigating,narcissistic,namesake,mylie,muses,munitions,motivational,momento,moisturizer,moderation,mmph,misinformed,misconception,minnifield,mikkos,methodical,mechanisms,mebbe,meager,maybes,matchmaking,masry,markovic,manifesto,malakai,madagascar,m'am,luzhin,lusting,lumberjack,louvre,loopholes,loaning,lightening,liberals,lesbo,leotard,leafs,leader's,layman's,launder,lamaze,kubla,kneeling,kilo,kibosh,kelp,keith's,jumpsuit,joy's,jovi,joliet,jogger,janover,jakovasaurs,irreparable,intervened,inspectors,innovation,innocently,inigo,infomercial,inexplicable,indispensable,indicative,incognito,impregnated,impossibly,imperfect,immaculate,imitating,illnesses,icarus,hunches,hummus,humidity,housewives,houmfort,hothead,hostiles,hooves,hoopla,hooligans,homos,homie,hisself,himalayas,hidy,hickory,heyyy,hesitant,hangout,handsomest,handouts,haitian,hairless,gwennie,guzzling,guinevere,grungy,grunge,grenada,gout,gordon's,goading,gliders,glaring,geology,gems,gavel,garments,gardino,gannon's,gangrene,gaff,gabrielle's,fundraising,fruitful,friendlier,frequencies,freckle,freakish,forthright,forearm,footnote,footer,foot's,flops,flamenco,fixer,firm's,firecracker,finito,figgered,fezzik,favourites,fastened,farfetched,fanciful,familiarize,faire,failsafe,fahrenheit,fabrication,extravaganza,extracted,expulsion,exploratory,exploitation,explanatory,exclusion,evolutionary,everglades,evenly,eunuch,estas,escapade,erasers,entries,enforcing,endorsements,enabling,emptying,emperor's,emblem,embarassing,ecosystem,ebby,ebay,dweeb,dutiful,dumplings,drilled,drafty,doug's,dolt,dollhouse,displaced,dismissing,disgraced,discrepancies,disbelief,disagreeing,disagreed,digestion,didnt,deviled,deviated,deterioration,departmental,departing,demoted,demerol,delectable,deco,decaying,decadent,dears,daze,dateless,d'algout,cultured,cultivating,cryto,crusades,crumpled,crumbled,cronies,critters,crew's,crease,craves,cozying,cortland,corduroy,cook's,consumers,congratulated,conflicting,confidante,condensed,concessions,compressor,compressions,compression,complicating,complexity,compadre,communicated,coerce,coding,coating,coarse,clown's,clockwise,clerk's,classier,clandestine,chums,chumash,christopher's,choreography,choirs,chivalrous,chinpoko,chilean,chihuahua,cheerio,charred,chafing,celibacy,casts,caste,cashier's,carted,carryin,carpeting,carp,carotid,cannibals,candor,caen,cab's,butterscotch,busts,busier,bullcrap,buggin,budding,brookside,brodski,bristow's,brig,bridesmaid's,brassiere,brainwash,brainiac,botrelle,boatload,blimey,blaring,blackness,bipolar,bipartisan,bins,bimbos,bigamist,biebe,biding,betrayals,bestow,bellerophon,beefy,bedpans,battleship,bathroom's,bassinet,basking,basin,barzini,barnyard,barfed,barbarian,bandit,balances,baker's,backups,avid,augh,audited,attribute,attitudes,at's,astor,asteroids,assortment,associations,asinine,asalaam,arouse,architects,aqua,applejack,apparatus,antiquities,annoys,angela's,anew,anchovies,anchors,analysts,ampule,alphabetically,aloe,allure,alameida,aisles,airfield,ahah,aggressively,aggravate,aftermath,affiliation,aesthetic,advertised,advancing,adept,adage,accomplices,accessing,academics,aagh,zoned,zoey's,zeal,yokel,y'ever,wynant's,wringer,witwer,withdrew,withdrawing,withdrawals,windward,wimbledon,wily,willfully,whorfin,whimsical,whimpering,welding,weddin,weathered,wealthiest,weakening,warmest,wanton,waif,volant,vivo,vive,visceral,vindication,vikram,vigorously,verification,veggies,urinate,uproar,upload,unwritten,unwrap,unsung,unsubstantiated,unspeakably,unscrupulous,unraveling,unquote,unqualified,unfulfilled,undetectable,underlined,unconstitutional,unattainable,unappreciated,ummmm,ulcers,tylenol,tweak,tutu,turnin,turk's,tucker's,tuatha,tropez,trends,trellis,traffic's,torque,toppings,tootin,toodles,toodle,tivo,tinkering,thursday's,thrives,thorne's,thespis,thereafter,theatrics,thatherton,texts,testicle,terr,tempers,teammates,taxpayer,tavington,tampon,tackling,systematic,syndicated,synagogue,swelled,sweeney's,sutures,sustenance,surfaces,superstars,sunflowers,sumatra,sublet,subjective,stubbins,strutting,strewn,streams,stowaway,stoic,sternin,stereotypes,steadily,star's,stalker's,stabilizing,sprang,spotter,spiraling,spinster,spell's,speedometer,specified,speakeasy,sparked,soooo,songwriter,soiled,sneakin,smithereens,smelt,smacks,sloan's,slaughterhouse,slang,slacks,skids,sketching,skateboards,sizzling,sixes,sirree,simplistic,sift,side's,shouts,shorted,shoelace,sheeit,shaw's,shards,shackled,sequestered,selmak,seduces,seclusion,seasonal,seamstress,seabeas,scry,scripted,scotia,scoops,scooped,schillinger's,scavenger,saturation,satch,salaries,safety's,s'more,s'il,rudeness,rostov,romanian,romancing,robo,robert's,rioja,rifkin,rieper,revise,reunions,repugnant,replicating,replacements,repaid,renewing,remembrance,relic,relaxes,rekindle,regulate,regrettably,registering,regenerate,referenced,reels,reducing,reconstruct,reciting,reared,reappear,readin,ratting,rapes,rancho,rancher,rammed,rainstorm,railroading,queers,punxsutawney,punishes,pssst,prudy,proudest,protectors,prohibits,profiling,productivity,procrastinating,procession,proactive,priss,primaries,potomac,postmortem,pompoms,polio,poise,piping,pickups,pickings,physiology,philanthropist,phenomena,pheasant,perfectionist,peretti,people'll,peninsula,pecking,peaks,pave,patrolman,participant,paralegal,paragraphs,paparazzi,pankot,pampering,pain's,overstep,overpower,ovation,outweigh,outlawed,orion's,openness,omnipotent,oleg,okra,okie,odious,nuwanda,nurtured,niles's,newsroom,netherlands,nephews,neeson,needlepoint,necklaces,neato,nationals,muggers,muffler,mousy,mourned,mosey,morn,mormon,mopey,mongolians,moldy,moderately,modelling,misinterpret,minneapolis,minion,minibar,millenium,microfilm,metals,mendola,mended,melissande,me's,mathematician,masturbating,massacred,masbath,marler's,manipulates,manifold,malp,maimed,mailboxes,magnetism,magna,m'lord,m'honey,lymph,lunge,lull,luka,lt's,lovelier,loser's,lonigan's,lode,locally,literacy,liners,linear,lefferts,leezak,ledgers,larraby,lamborghini,laloosh,kundun,kozinski,knockoff,kissin,kiosk,khasinau's,kennedys,kellman,karlo,kaleidoscope,jumble,juggernaut,joseph's,jiminy,jesuits,jeffy,jaywalking,jailbird,itsy,irregularities,inventive,introduces,interpreter,instructing,installing,inquest,inhabit,infraction,informer,infarction,incidence,impulsively,impressing,importing,impersonated,impeach,idiocy,hyperbole,hydra,hurray,hungary,humped,huhuh,hsing,hotspot,horsepower,hordes,hoodlums,honky,hitchhiker,hind,hideously,henchmen,heaving,heathrow,heather's,heathcliff,healthcare,headgear,headboard,hazing,hawking,harem,handprint,halves,hairspray,gutiurrez,greener,grandstand,goosebumps,good's,gondola,gnaw,gnat,glitches,glide,gees,gasping,gases,garrison's,frolic,fresca,freeways,frayed,fortnight,fortitude,forgetful,forefathers,foley's,foiled,focuses,foaming,flossing,flailing,fitzgeralds,firehouse,finders,filmmakers,fiftieth,fiddler,fellah,feats,fawning,farquaad,faraway,fancied,extremists,extremes,expresses,exorcist,exhale,excel,evaluations,ethros,escalated,epilepsy,entrust,enraged,ennui,energized,endowment,encephalitis,empties,embezzling,elster,ellie's,ellen's,elixir,electrolytes,elective,elastic,edged,econ,eclectic,eagle's,duplex,dryers,drexl,dredging,drawback,drafting,don'ts,docs,dobisch,divorcee,ditches,distinguishing,distances,disrespected,disprove,disobeying,disobedience,disinfectant,discs,discoveries,dips,diplomas,dingy,digress,dignitaries,digestive,dieting,dictatorship,dictating,devoured,devise,devane's,detonators,detecting,desist,deserter,derriere,deron,derive,derivative,delegates,defects,defeats,deceptive,debilitating,deathwok,dat's,darryl's,dago,daffodils,curtsy,cursory,cuppa,cumin,cultivate,cujo,cubic,cronkite,cremation,credence,cranking,coverup,courted,countin,counselling,cornball,converting,contentment,contention,contamination,consortium,consequently,consensual,consecutive,compressed,compounds,compost,components,comparative,comparable,commenting,color's,collections,coleridge,coincidentally,cluett,cleverly,cleansed,cleanliness,clea,clare's,citizen's,chopec,chomp,cholera,chins,chime,cheswick,chessler,cheapest,chatted,cauliflower,catharsis,categories,catchin,caress,cardigan,capitalism,canopy,cana,camcorder,calorie,cackling,cabot's,bystanders,buttoned,buttering,butted,buries,burgel,bullpen,buffoon,brogna,brah,bragged,boutros,boosted,bohemian,bogeyman,boar,blurting,blurb,blowup,bloodhound,blissful,birthmark,biotech,bigot,bestest,benefited,belted,belligerent,bell's,beggin,befall,beeswax,beer's,becky's,beatnik,beaming,bazaar,bashful,barricade,banners,bangers,baja,baggoli,badness,awry,awoke,autonomy,automobiles,attica,astoria,assessing,ashram,artsy,artful,aroun,armpits,arming,arithmetic,annihilate,anise,angiogram,andre's,anaesthetic,amorous,ambiguous,ambiance,alligators,afforded,adoration,admittance,administering,adama,aclu,abydos,absorption,zonked,zhivago,zealand,zazu,youngster,yorkin,wrongfully,writin,wrappers,worrywart,woops,wonderfalls,womanly,wickedness,wichita,whoopie,wholesale,wholeheartedly,whimper,which'll,wherein,wheelchairs,what'ya,west's,wellness,welcomes,wavy,warren's,warranted,wankers,waltham,wallop,wading,wade's,wacked,vogue,virginal,vill,vets,vermouth,vermeil,verger,verbs,verbally,ventriss,veneer,vecchio's,vampira,utero,ushers,urgently,untoward,unshakable,unsettled,unruly,unrest,unmanned,unlocks,unified,ungodly,undue,undermined,undergoing,undergo,uncooperative,uncontrollably,unbeatable,twitchy,tunh,tumbler,tubs,truest,troublesome,triumphs,triplicate,tribbey,trent's,transmissions,tortures,torpedoes,torah,tongaree,tommi,tightening,thunderbolt,thunderbird,thorazine,thinly,theta,theres,testifies,terre,teenaged,technological,tearful,taxing,taldor,takashi,tach,symbolizes,symbolism,syllabus,swoops,swingin,swede,sutra,suspending,supplement,sunday's,sunburn,succumbed,subtitled,substituting,subsidiary,subdued,stuttering,stupor,stumps,strummer,strides,strategize,strangulation,stooped,stipulation,stingy,stigma,stewart's,statistic,startup,starlet,stapled,squeaks,squawking,spoilsport,splicing,spiel,spencers,specifications,spawned,spasms,spaniard,sous,softener,sodding,soapbox,snow's,smoldering,smithbauer,slogans,slicker,slasher,skittish,skepticism,simulated,similarity,silvio,signifies,signaling,sifting,sickest,sicilians,shuffling,shrivel,shortstop,sensibility,sender,seminary,selecting,segretti,seeping,securely,scurrying,scrunch,scrote,screwups,schoolteacher,schibetta's,schenkman,sawing,savin,satine,saps,sapiens,salvaging,salmonella,safeguard,sacrilege,rumpus,ruffle,rube,routing,roughing,rotted,roshman's,rondall,road's,ridding,rickshaw,rialto,rhinestone,reversible,revenues,retina,restrooms,resides,reroute,requisite,repress,replicate,repetition,removes,relationship's,regent,regatta,reflective,rednecks,redeeming,rectory,recordings,reasoned,rayed,ravell,raked,rainstorm's,raincheck,raids,raffi,racked,query,quantities,pushin,prototypes,proprietor,promotes,prometheus,promenade,projectile,progeny,profess,prodding,procure,primetime,presuming,preppy,prednisone,predecessor,potted,posttraumatic,poppies,poorhouse,pool's,polaroid,podiatrist,plucky,plowed,pledging,playroom,playhouse,play's,plait,placate,pitchfork,pissant,pinback,picketing,photographing,pharoah,petrak,petal,persecuting,perchance,penny's,pellets,peeved,peerless,payable,pauses,pathways,pathologist,pat's,parchment,papi,pagliacci,owls,overwrought,overwhelmingly,overreaction,overqualified,overheated,outward,outlines,outcasts,otherworldly,originality,organisms,opinionated,oodles,oftentimes,octane,occured,obstinate,observatory,o'er,nutritionist,nutrition,numbness,nubile,notification,notary,nooooooo,nodes,nobodies,nepotism,neighborhoods,neanderthals,musicals,mushu,murphy's,multimedia,mucus,mothering,mothballs,monogrammed,monk's,molesting,misspoke,misspelled,misconstrued,miscellaneous,miscalculated,minimums,mince,mildew,mighta,middleman,metabolic,messengers,mementos,mellowed,meditate,medicare,mayol,maximilian,mauled,massaged,marmalade,mardi,mannie,mandates,mammals,malaysia,makings,major's,maim,lundegaard,lovingly,lout,louisville,loudest,lotto,loosing,loompa,looming,longs,lodging,loathes,littlest,littering,linebacker,lifelike,li'l,legalities,lavery's,laundered,lapdog,lacerations,kopalski,knobs,knitted,kittridge,kidnaps,kerosene,katya,karras,jungles,juke,joes,jockeys,jeremy's,jefe,janeiro,jacqueline's,ithaca,irrigation,iranoff,invoices,invigorating,intestinal,interactive,integration,insolence,insincere,insectopia,inhumane,inhaling,ingrates,infrastructure,infestation,infants,individuality,indianapolis,indeterminate,indefinite,inconsistent,incomprehensible,inaugural,inadequacy,impropriety,importer,imaginations,illuminating,ignited,ignite,iggy,i'da,hysterics,hypodermic,hyperventilate,hypertension,hyperactive,humoring,hotdogs,honeymooning,honed,hoist,hoarding,hitching,hinted,hill's,hiker,hijo,hightail,highlands,hemoglobin,helo,hell'd,heinie,hanoi,hags,gush,guerrillas,growin,grog,grissom's,gregory's,grasped,grandparent,granddaughters,gouged,goblins,gleam,glades,gigantor,get'em,geriatric,geared,gawk,gawd,gatekeeper,gargoyles,gardenias,garcon,garbo,gallows,gabe's,gabby's,gabbing,futon,fulla,frightful,freshener,freedoms,fountains,fortuitous,formulas,forceps,fogged,fodder,foamy,flogging,flaun,flared,fireplaces,firefighters,fins,filtered,feverish,favell,fattest,fattening,fate's,fallow,faculties,fabricated,extraordinaire,expressly,expressive,explorers,evade,evacuating,euclid,ethanol,errant,envied,enchant,enamored,enact,embarking,election's,egocentric,eeny,dussander,dunwitty,dullest,dru's,dropout,dredged,dorsia,dormitory,doot,doornail,dongs,dogged,dodgy,do's,ditty,dishonorable,discriminating,discontinue,dings,dilly,diffuse,diets,dictation,dialysis,deteriorated,delly,delightfully,definitions,decreased,declining,deadliest,daryll,dandruff,cynthia's,cush,cruddy,croquet,crocodiles,cringe,crimp,credo,cranial,crackling,coyotes,courtside,coupling,counteroffer,counterfeiting,corrupting,corrective,copter,copping,conway's,conveyor,contusions,contusion,conspirator,consoling,connoisseur,conjecture,confetti,composure,competitor,compel,commanders,coloured,collector's,colic,coldest,coincide,coddle,cocksuckers,coax,coattails,cloned,cliff's,clerical,claustrophobia,classrooms,clamoring,civics,churn,chugga,chromosomes,christened,chopper's,chirping,chasin,characterized,chapped,chalkboard,centimeter,caymans,catheter,caspian,casings,cartilage,carlton's,card's,caprica,capelli,cannolis,cannoli,canals,campaigns,camogli,camembert,butchers,butchered,busboys,bureaucrats,bungalow,buildup,budweiser,buckled,bubbe,brownstone,bravely,brackley,bouquets,botox,boozing,boosters,bodhi,blunders,blunder,blockage,blended,blackberry,bitch's,birthplace,biocyte,biking,bike's,betrays,bestowed,bested,beryllium,beheading,beginner's,beggar,begbie,beamed,bayou,bastille,bask,barstool,barricades,baron's,barbecues,barbecued,barb's,bandwagon,bandits,ballots,ballads,backfiring,bacarra,avoidance,avenged,autopsies,austrian,aunties,attache,atrium,associating,artichoke,arrowhead,arrivals,arose,armory,appendage,apostrophe,apostles,apathy,antacid,ansel,anon,annul,annihilation,andrew's,anderson's,anastasia's,amuses,amped,amicable,amendments,amberg,alluring,allotted,alfalfa,alcoholism,airs,ailing,affinity,adversaries,admirers,adlai,adjective,acupuncture,acorn,abnormality,aaaahhhh,zooming,zippity,zipping,zeroed,yuletide,yoyodyne,yengeese,yeahhh,xena,wrinkly,wracked,wording,withered,winks,windmills,widow's,whopping,wholly,wendle,weigart,weekend's,waterworks,waterford,waterbed,watchful,wantin,wally's,wail,wagging,waal,waaah,vying,voter,ville,vertebrae,versatile,ventures,ventricle,varnish,vacuumed,uugh,utilities,uptake,updating,unreachable,unprovoked,unmistakable,unky,unfriendly,unfolding,undesirable,undertake,underpaid,uncuff,unchanged,unappealing,unabomber,ufos,tyres,typhoid,tweek's,tuxedos,tushie,turret,turds,tumnus,tude,truman's,troubadour,tropic,trinium,treaters,treads,transpired,transient,transgression,tournaments,tought,touchdowns,totem,tolstoy,thready,thins,thinners,thas,terrible's,television's,techs,teary,tattaglia,tassels,tarzana,tape's,tanking,tallahassee,tablecloths,synonymous,synchronize,symptomatic,symmetrical,sycophant,swimmingly,sweatshop,surrounds,surfboard,superpowers,sunroom,sunflower,sunblock,sugarplum,sudan,subsidies,stupidly,strumpet,streetcar,strategically,strapless,straits,stooping,stools,stifler,stems,stealthy,stalks,stairmaster,staffer,sshhh,squatting,squatters,spores,spelt,spectacularly,spaniel,soulful,sorbet,socked,society's,sociable,snubbed,snub,snorting,sniffles,snazzy,snakebite,smuggler,smorgasbord,smooching,slurping,sludge,slouch,slingshot,slicer,slaved,skimmed,skier,sisterhood,silliest,sideline,sidarthur,shrink's,shipwreck,shimmy,sheraton,shebang,sharpening,shanghaied,shakers,sendoff,scurvy,scoliosis,scaredy,scaled,scagnetti,saxophone,sawchuk,saviour,saugus,saturated,sasquatch,sandbag,saltines,s'pose,royalties,routinely,roundabout,roston,rostle,riveting,ristle,righ,rifling,revulsion,reverently,retrograde,restriction,restful,resolving,resents,rescinded,reptilian,repository,reorganize,rentals,rent's,renovating,renal,remedies,reiterate,reinvent,reinmar,reibers,reechard,recuse,recorders,record's,reconciling,recognizance,recognised,reclaiming,recitation,recieved,rebate,reacquainted,rations,rascals,raptors,railly,quintuplets,quahog,pygmies,puzzling,punctuality,psychoanalysis,psalm,prosthetic,proposes,proms,proliferation,prohibition,probie,printers,preys,pretext,preserver,preppie,prag,practise,postmaster,portrayed,pollen,polled,poachers,plummet,plumbers,pled,plannin,pitying,pitfalls,piqued,pinecrest,pinches,pillage,pigheaded,pied,physique,pessimistic,persecute,perjure,perch,percentile,pentothal,pensky,penises,peking,peini,peacetime,pazzi,pastels,partisan,parlour,parkway,parallels,paperweight,pamper,palsy,palaces,pained,overwhelm,overview,overalls,ovarian,outrank,outpouring,outhouse,outage,ouija,orbital,old's,offset,offer's,occupying,obstructed,obsessions,objectives,obeying,obese,o'riley,o'neal,o'higgins,nylon,notoriously,nosebleeds,norman's,norad,noooooooo,nononono,nonchalant,nominal,nome,nitrous,nippy,neurosis,nekhorvich,necronomicon,nativity,naquada,nano,nani,n'est,mystik,mystified,mums,mumps,multinational,muddle,mothership,moped,monumentally,monogamous,mondesi,molded,mixes,misogynistic,misinterpreting,miranda's,mindlock,mimic,midtown,microphones,mending,megaphone,meeny,medicating,meanings,meanie,masseur,maru,marshal's,markstrom,marklars,mariachi,margueritas,manifesting,maintains,mail's,maharajah,lurk,lulu's,lukewarm,loveliest,loveable,lordship,looting,lizardo,liquored,lipped,lingers,limey,limestone,lieutenants,lemkin,leisurely,laureate,lathe,latched,lars,lapping,ladle,kuala,krevlorneswath,kosygin,khakis,kenaru,keats,kath,kaitlan,justin's,julliard,juliet's,journeys,jollies,jiff,jaundice,jargon,jackals,jabot's,invoked,invisibility,interacting,instituted,insipid,innovative,inflamed,infinitely,inferiority,inexperience,indirectly,indications,incompatible,incinerated,incinerate,incidental,incendiary,incan,inbred,implicitly,implicating,impersonator,impacted,ida's,ichiro,iago,hypo,hurricanes,hunks,host's,hospice,horsing,hooded,honey's,homestead,hippopotamus,hindus,hiked,hetson,hetero,hessian,henslowe,hendler,hellstrom,hecate,headstone,hayloft,hater,hast,harold's,harbucks,handguns,hallucinate,halliwell's,haldol,hailing,haggling,hadj,gynaecologist,gumball,gulag,guilder,guaranteeing,groundskeeper,ground's,grindstone,grimoir,grievance,griddle,gribbit,greystone,graceland,gooders,goeth,glossy,glam,giddyup,gentlemanly,gels,gelatin,gazelle,gawking,gaulle,gate's,ganged,fused,fukes,fromby,frenchmen,franny,foursome,forsley,foreman's,forbids,footwork,foothold,fonz,fois,foie,floater,flinging,flicking,fittest,fistfight,fireballs,filtration,fillings,fiddling,festivals,fertilization,fennyman,felonious,felonies,feces,favoritism,fatten,fanfare,fanatics,faceman,extensions,executions,executing,excusing,excepted,examiner's,ex's,evaluating,eugh,erroneous,enzyme,envoy,entwined,entrances,ensconced,enrollment,england's,enemy's,emit,emerges,embankment,em's,ellison's,electrons,eladio,ehrlichman,easterland,dylan's,dwellers,dueling,dubbed,dribbling,drape,doze,downtrodden,doused,dosed,dorleen,dopamine,domesticated,dokie,doggone,disturbances,distort,displeased,disown,dismount,disinherited,disarmed,disapproves,disabilities,diperna,dioxide,dined,diligent,dicaprio,diameter,dialect,detonated,destitute,designate,depress,demolish,demographics,degraded,deficient,decoded,debatable,dealey,darsh,dapper,damsels,damning,daisy's,dad'll,d'oeuvre,cutter's,curlers,curie,cubed,cryo,critically,crikey,crepes,crackhead,countrymen,count's,correlation,cornfield,coppers,copilot,copier,coordinating,cooing,converge,contributor,conspiracies,consolidated,consigliere,consecrated,configuration,conducts,condoning,condemnation,communities,commoner,commies,commented,comical,combust,comas,colds,clod,clique,clay's,clawed,clamped,cici,christianity,choosy,chomping,chimps,chigorin,chianti,cheval,chet's,cheep,checkups,check's,cheaters,chase's,charted,celibate,cautiously,cautionary,castell,carpentry,caroling,carjacking,caritas,caregiver,cardiology,carb,capturing,canteen,candlesticks,candies,candidacy,canasta,calendars,cain't,caboose,buster's,burro,burnin,buon,bunking,bumming,bullwinkle,budgets,brummel,brooms,broadcasts,britt's,brews,breech,breathin,braslow,bracing,bouts,botulism,bosnia,boorish,bluenote,bloodless,blayne,blatantly,blankie,birdy,bene,beetles,bedbugs,becuase,becks,bearers,bazooka,baywatch,bavarian,baseman,bartender's,barrister,barmaid,barges,bared,baracus,banal,bambino,baltic,baku,bakes,badminton,bacon's,backpacks,authorizing,aurelius,attentions,atrocious,ativan,athame,asunder,astound,assuring,aspirins,asphyxiation,ashtrays,aryans,artistry,arnon,aren,approximate,apprehension,appraisal,applauding,anya's,anvil,antiquing,antidepressants,annoyingly,amputate,altruistic,alotta,allegation,alienation,algerian,algae,alerting,airport's,aided,agricultural,afterthought,affront,affirm,adapted,actuality,acoustics,acoustic,accumulate,accountability,abysmal,absentee,zimm,yves,yoohoo,ymca,yeller,yakushova,wuzzy,wriggle,worrier,workmen,woogyman,womanizer,windpipe,windex,windbag,willy's,willin,widening,whisking,whimsy,wendall,weeny,weensy,weasels,watery,watcha,wasteful,waski,washcloth,wartime,waaay,vowel,vouched,volkswagen,viznick,visuals,visitor's,veteran's,ventriloquist,venomous,vendors,vendettas,veils,vehicular,vayhue,vary,varies,van's,vamanos,vadimus,uuhh,upstage,uppity,upheaval,unsaid,unlocking,universally,unintentionally,undisputed,undetected,undergraduate,undergone,undecided,uncaring,unbearably,twos,tween,tuscan,turkey's,tumor's,tryout,trotting,tropics,trini,trimmings,trickier,tree's,treatin,treadstone,trashcan,transports,transistor,transcendent,tramps,toxicity,townsfolk,torturous,torrid,toothpicks,tombs,tolerable,toenail,tireless,tiptoeing,tins,tinkerbell,tink,timmay,tillinghouse,tidying,tibia,thumbing,thrusters,thrashing,thompson's,these'll,testicular,terminology,teriyaki,tenors,tenacity,tellers,telemetry,teas,tea's,tarragon,taliban,switchblade,swicker,swells,sweatshirts,swatches,swatch,swapped,suzanne's,surging,supremely,suntan,sump'n,suga,succumb,subsidize,subordinate,stumbles,stuffs,stronghold,stoppin,stipulate,stewie's,stenographer,steamroll,stds,stately,stasis,stagger,squandered,splint,splendidly,splatter,splashy,splashing,spectra's,specter,sorry's,sorcerers,soot,somewheres,somber,solvent,soldier's,soir,snuggled,snowmobile,snowball's,sniffed,snake's,snags,smugglers,smudged,smirking,smearing,slings,sleet,sleepovers,sleek,slackers,skirmish,siree,siphoning,singed,sincerest,signifying,sidney's,sickened,shuffled,shriveled,shorthanded,shittin,shish,shipwrecked,shins,shingle,sheetrock,shawshank,shamu,sha're,servitude,sequins,seinfeld's,seat's,seascape,seam,sculptor,scripture,scrapings,scoured,scoreboard,scorching,sciences,sara's,sandpaper,salvaged,saluting,salud,salamander,rugrats,ruffles,ruffled,rudolph's,router,roughnecks,rougher,rosslyn,rosses,rosco's,roost,roomy,romping,romeo's,robs,roadie,ride's,riddler,rianna's,revolutionize,revisions,reuniting,retake,retaining,restitution,restaurant's,resorts,reputed,reprimanded,replies,renovate,remnants,refute,refrigerated,reforms,reeled,reefs,reed's,redundancies,rectangle,rectal,recklessly,receding,reassignment,rearing,reapers,realms,readout,ration,raring,ramblings,racetrack,raccoons,quoi,quell,quarantined,quaker,pursuant,purr,purging,punters,pulpit,publishers,publications,psychologists,psychically,provinces,proust,protocols,prose,prophets,project's,priesthood,prevailed,premarital,pregnancies,predisposed,precautionary,poppin,pollute,pollo,podunk,plums,plaything,plateau,pixilated,pivot,pitting,piranhas,pieced,piddles,pickled,picker,photogenic,phosphorous,phases,pffft,petey's,pests,pestilence,pessimist,pesos,peruvian,perspiration,perps,penticoff,pedals,payload,passageways,pardons,paprika,paperboy,panics,pancamo,pam's,paleontologist,painting's,pacifist,ozzie,overwhelms,overstating,overseeing,overpaid,overlap,overflow,overdid,outspoken,outlive,outlaws,orthodontist,orin,orgies,oreos,ordover,ordinates,ooooooh,oooohhh,omelettes,officiate,obtuse,obits,oakwood,nymph,nutritional,nuremberg,nozzle,novocaine,notable,noooooooooo,node,nipping,nilly,nikko,nightstick,nicaragua,neurology,nelson's,negate,neatness,natured,narrowly,narcotic,narcissism,napoleon's,nana's,namun,nakatomi,murky,muchacho,mouthwash,motzah,motherfucker's,mortar,morsel,morrison's,morph,morlocks,moreover,mooch,monoxide,moloch,molest,molding,mohra,modus,modicum,mockolate,mobility,missionaries,misdemeanors,miscalculation,minorities,middies,metric,mermaids,meringue,mercilessly,merchandising,ment,meditating,me'n,mayakovsky,maximillian,martinique,marlee,markovski,marissa's,marginal,mansions,manitoba,maniacal,maneuvered,mags,magnificence,maddening,lyrical,lutze,lunged,lovelies,lou's,lorry,loosening,lookee,liver's,liva,littered,lilac,lightened,lighted,licensing,lexington,lettering,legality,launches,larvae,laredo,landings,lancelot's,laker,ladyship's,laces,kurzon,kurtzweil,kobo,knowledgeable,kinship,kind've,kimono,kenji,kembu,keanu,kazuo,kayaking,juniors,jonesing,joad,jilted,jiggling,jewelers,jewbilee,jeffrey's,jamey's,jacqnoud,jacksons,jabs,ivories,isnt,irritation,iraqis,intellectuals,insurmountable,instances,installments,innocuous,innkeeper,inna,influencing,infantery,indulged,indescribable,incorrectly,incoherent,inactive,inaccurate,improperly,impervious,impertinent,imperfections,imhotep,ideology,identifies,i'il,hymns,huts,hurdles,hunnert,humpty,huffy,hourly,horsies,horseradish,hooo,honours,honduras,hollowed,hogwash,hockley,hissing,hiromitsu,hierarchy,hidin,hereafter,helpmann,haughty,happenings,hankie,handsomely,halliwells,haklar,haise,gunsights,gunn's,grossly,grossed,grope,grocer,grits,gripping,greenpeace,granddad's,grabby,glorificus,gizzard,gilardi,gibarian,geminon,gasses,garnish,galloping,galactic,gairwyn,gail's,futterman,futility,fumigated,fruitless,friendless,freon,fraternities,franc,fractions,foxes,foregone,forego,foliage,flux,floored,flighty,fleshy,flapjacks,fizzled,fittings,fisherman's,finalist,ficus,festering,ferragamo's,federation,fatalities,farbman,familial,famed,factual,fabricate,eyghon,extricate,exchanges,exalted,evolving,eventful,esophagus,eruption,envision,entre,enterprising,entail,ensuring,enrolling,endor,emphatically,eminent,embarrasses,electroshock,electronically,electrodes,efficiently,edinburgh,ecstacy,ecological,easel,dwarves,duffle,drumsticks,drake's,downstream,downed,dollface,divas,distortion,dissent,dissection,dissected,disruptive,disposing,disparaging,disorientation,disintegrated,discounts,disarming,dictated,devoting,deviation,detective's,dessaline,deprecating,deplorable,delve,deity,degenerative,deficiencies,deduct,decomposed,deceased's,debbie's,deathly,dearie,daunting,dankova,czechoslovakia,cyclotron,cyberspace,cutbacks,cusp,culpable,cuddled,crypto,crumpets,cruises,cruisers,cruelly,crowns,crouching,cristo,crip,criminology,cranium,cramming,cowering,couric,counties,cosy,corky's,cordesh,conversational,conservatory,conklin's,conducive,conclusively,competitions,compatibility,coeur,clung,cloud's,clotting,cleanest,classify,clambake,civilizations,cited,cipher,cinematic,chlorine,chipping,china's,chimpanzee,chests,checkpoints,cheapen,chainsaws,censure,censorship,cemeteries,celebrates,ceej,cavities,catapult,cassettes,cartridge,caravaggio,carats,captivating,cancers,campuses,campbell's,calrissian,calibre,calcutta,calamity,butt's,butlers,busybody,bussing,bureau's,bunion,bundy's,bulimic,bulgaria,budging,brung,browbeat,brokerage,brokenhearted,brecher,breakdowns,braun's,bracebridge,boyhood,botanical,bonuses,boning,blowhard,bloc,blisters,blackboard,blackbird,births,birdies,bigotry,biggy,bibliography,bialy,bhamra,bethlehem,bet's,bended,belgrade,begat,bayonet,bawl,battering,baste,basquiat,barrymore,barrington's,barricaded,barometer,balsom's,balled,ballast,baited,badenweiler,backhand,aztec,axle,auschwitz,astrophysics,ascenscion,argumentative,arguably,arby's,arboretum,aramaic,appendicitis,apparition,aphrodite,anxiously,antagonistic,anomalies,anne's,angora,anecdotes,anand,anacott,amniotic,amenities,ambience,alonna,aleck,albert's,akashic,airing,ageless,afro,affiliates,advertisers,adobe,adjustable,acrobat,accommodation,accelerating,absorbing,abouts,abortions,abnormalities,aawwww,aaaaarrrrrrggghhh,zuko's,zoloft,zendi,zamboni,yuppies,yodel,y'hear,wyck,wrangle,wounding,worshippers,worker's,worf,wombosi,wittle,withstanding,wisecracks,williamsburg,wilder's,wiggly,wiggling,wierd,whittlesley,whipper,whattya,whatsamatter,whatchamacallit,whassup,whad'ya,weighted,weakling,waxy,waverly,wasps,warhol,warfarin,waponis,wampum,walled,wadn't,waco,vorash,vogler's,vizzini,visas,virtucon,viridiana,veve,vetoed,vertically,veracity,ventricular,ventilated,varicose,varcon,vandalized,vampire's,vamos,vamoose,val's,vaccinated,vacationing,usted,urinal,uppers,upkeep,unwittingly,unsigned,unsealed,unplanned,unhinged,unhand,unfathomable,unequivocally,unearthed,unbreakable,unanimously,unadvisedly,udall,tynacorp,twisty,tuxes,tussle,turati,tunic,tubing,tsavo,trussed,troublemakers,trollop,trip's,trinket,trilogy,tremors,trekkie,transsexual,transitional,transfusions,tractors,toothbrushes,toned,toke,toddlers,titan's,tita,tinted,timon,timeslot,tightened,thundering,thorpey,thoracic,this'd,thespian,therapist's,theorem,thaddius,texan,tenuous,tenths,tenement,telethon,teleprompter,technicolor,teaspoon,teammate,teacup,taunted,tattle,tardiness,taraka,tappy,tapioca,tapeworm,tanith,tandem,talons,talcum,tais,tacks,synchronized,swivel,swig,swaying,swann's,suppression,supplements,superpower,summed,summarize,sumbitch,sultry,sulfur,sues,subversive,suburbia,substantive,styrofoam,stylings,struts,strolls,strobe,streaks,strategist,stockpile,stewardesses,sterilized,sterilize,stealin,starred,stakeouts,stad,squawk,squalor,squabble,sprinkled,sportsmanship,spokes,spiritus,spectators,specialties,sparklers,spareribs,sowing,sororities,sorbonne,sonovabitch,solicit,softy,softness,softening,socialite,snuggling,snatchers,snarling,snarky,snacking,smythe's,smears,slumped,slowest,slithering,sleepers,sleazebag,slayed,slaughtering,skynet,skidded,skated,sivapathasundaram,sitter's,sitcoms,sissies,sinai,silliness,silences,sidecar,sicced,siam,shylock,shtick,shrugged,shriek,shredder,shoves,should'a,shorten,shortcake,shockingly,shirking,shelly's,shedding,shaves,shatner,sharpener,shapely,shafted,sexless,sequencing,septum,semitic,selflessness,sega,sectors,seabea,scuff,screwball,screened,scoping,scooch,scolding,scholarly,schnitzel,schemed,scalper,sayings,saws,sashimi,santy,sankara,sanest,sanatorium,sampled,samoan,salzburg,saltwater,salma,salesperson,sakulos,safehouse,sabers,rwanda,ruth's,runes,rumblings,rumbling,ruijven,roxie's,round's,ringers,rigorous,righto,rhinestones,reviving,retrieving,resorted,reneging,remodelling,reliance,relentlessly,relegated,relativity,reinforced,reigning,regurgitate,regulated,refills,referencing,reeking,reduces,recreated,reclusive,recklessness,recanted,ranges,ranchers,rallied,rafer,racy,quintet,quaking,quacks,pulses,provision,prophesied,propensity,pronunciation,programmer,profusely,procedural,problema,principals,prided,prerequisite,preferences,preceded,preached,prays,postmark,popsicles,poodles,pollyanna,policing,policeman's,polecat,polaroids,polarity,pokes,poignant,poconos,pocketful,plunging,plugging,pleeease,pleaser,platters,pitied,pinetti,piercings,phyllis's,phooey,phonies,pestering,periscope,perennial,perceptions,pentagram,pelts,patronized,parliamentary,paramour,paralyze,paraguay,parachutes,pancreatic,pales,paella,paducci,oxymoron,owatta,overpass,overgrown,overdone,overcrowded,overcompensating,overcoming,ostracized,orphaned,organise,organisation,ordinate,orbiting,optometrist,oprah's,operandi,oncology,on's,omoc,omens,okayed,oedipal,occupants,obscured,oboe,nuys,nuttier,nuptial,nunheim,noxious,nourish,notepad,notation,nordic,nitroglycerin,niki's,nightmare's,nightlife,nibblet,neuroses,neighbour's,navy's,nationally,nassau,nanosecond,nabbit,mythic,murdock's,munchkins,multiplied,multimillion,mulroney,mulch,mucous,muchas,moxie,mouth's,mountaintop,mounds,morlin,mongorians,moneymaker,moneybags,monde,mom'll,molto,mixup,mitchell's,misgivings,misery's,minerals,mindset,milo's,michalchuk,mesquite,mesmerized,merman,mensa,megan's,media's,meaty,mbwun,materialize,materialistic,mastery,masterminded,mastercard,mario's,marginally,mapuhe,manuscripts,manny's,malvern,malfunctioning,mahatma,mahal,magnify,macnamara,macinerney,machinations,macarena,macadamia,lysol,luxembourg,lurks,lumpur,luminous,lube,lovelorn,lopsided,locator,lobbying,litback,litany,linea,limousines,limo's,limes,lighters,liechtenstein,liebkind,lids,libya,levity,levelheaded,letterhead,lester's,lesabre,leron,lepers,legions,lefts,leftenant,learner's,laziness,layaway,laughlan,lascivious,laryngitis,laptops,lapsed,laos,landok,landfill,laminated,laden,ladders,labelled,kyoto,kurten,kobol,koala,knucklehead,knowed,knotted,kit's,kinsa,kiln,kickboxing,karnovsky,karat,kacl's,judiciary,judaism,journalistic,jolla,joked,jimson,jettison,jet's,jeric,jeeves,jay's,jawed,jankis,janitors,janice's,jango,jamaican,jalopy,jailbreak,jackers,jackasses,j'ai,ivig,invalidate,intoxicated,interstellar,internationally,intercepting,intercede,integrate,instructors,insinuations,insignia,inn's,inflicting,infiltrated,infertile,ineffective,indies,indie,impetuous,imperialist,impaled,immerse,immaterial,imbeciles,imam,imagines,idyllic,idolized,icebox,i'd've,hypochondriac,hyphen,hydraulic,hurtling,hurried,hunchback,hums,humid,hullo,hugger,hubby's,howard's,hostel,horsting,horned,hoooo,homies,homeboys,hollywood's,hollandaise,hoity,hijinks,heya,hesitates,herrero,herndorff,hemp,helplessly,heeyy,heathen,hearin,headband,harv,harrassment,harpies,harmonious,harcourt,harbors,hannah's,hamstring,halstrom,hahahahaha,hackett's,hacer,gunmen,guff,grumbling,grimlocks,grift,greets,grandmothers,grander,granddaughter's,gran's,grafts,governing,gordievsky,gondorff,godorsky,goddesses,glscripts,gillman's,geyser,gettysburg,geological,gentlemen's,genome,gauntlet,gaudy,gastric,gardeners,gardener's,gandolf,gale's,gainful,fuses,fukienese,fucker's,frizzy,freshness,freshening,freb,fraught,frantically,fran's,foxbooks,fortieth,forked,forfeited,forbidding,footed,foibles,flunkies,fleur,fleece,flatbed,flagship,fisted,firefight,fingerpaint,fined,filibuster,fiancee's,fhloston,ferrets,fenceline,femur,fellow's,fatigues,farmhouse,fanucci,fantastically,familiars,falafel,fabulously,eyesore,extracting,extermination,expedient,expectancy,exiles,executor,excluding,ewwww,eviscerated,eventual,evac,eucalyptus,ethnicity,erogenous,equestrian,equator,epidural,enrich,endeavors,enchante,embroidered,embarassed,embarass,embalming,emails,elude,elspeth,electrocute,electrified,eigth,eheh,eggshell,eeyy,echinacea,eases,earpiece,earlobe,dwarfs,dumpsters,dumbshit,dumbasses,duloc,duisberg,drummed,drinkers,dressy,drainage,dracula's,dorma,dolittle,doily,divvy,diverting,ditz,dissuade,disrespecting,displacement,displace,disorganized,dismantled,disgustingly,discriminate,discord,disapproving,dinero,dimwit,diligence,digitally,didja,diddy,dickless,diced,devouring,devlin's,detach,destructing,desperado,desolate,designation,derek's,deposed,dependency,dentist's,demonstrates,demerits,delirium,degrade,deevak,deemesa,deductions,deduce,debriefed,deadbeats,dazs,dateline,darndest,damnable,dalliance,daiquiri,d'agosta,cuvee's,cussing,curate,cryss,cripes,cretins,creature's,crapper,crackerjack,cower,coveting,couriers,countermission,cotswolds,cornholio,copa,convinces,convertibles,conversationalist,contributes,conspirators,consorting,consoled,conservation,consarn,confronts,conformity,confides,confidentially,confederacy,concise,competence,commited,commissioners,commiserate,commencing,comme,commandos,comforter,comeuppance,combative,comanches,colosseum,colling,collaboration,coli,coexist,coaxing,cliffside,clayton's,clauses,cia's,chuy,chutes,chucked,christian's,chokes,chinaman,childlike,childhoods,chickening,chicano,chenowith,chassis,charmingly,changin,championships,chameleon,ceos,catsup,carvings,carlotta's,captioning,capsize,cappucino,capiche,cannonball,cannibal,candlewell,cams,call's,calculation,cakewalk,cagey,caesar's,caddie,buxley,bumbling,bulky,bulgarian,bugle,buggered,brussel,brunettes,brumby,brotha,bros,bronck,brisket,bridegroom,breathing's,breakout,braveheart,braided,bowled,bowed,bovary,bordering,bookkeeper,bluster,bluh,blue's,blot,bloodline,blissfully,blarney,binds,billionaires,billiard,bide,bicycles,bicker,berrisford,bereft,berating,berate,bendy,benches,bellevue,belive,believers,belated,beikoku,beens,bedspread,bed's,bear's,bawdy,barrett's,barreling,baptize,banya,balthazar,balmoral,bakshi,bails,badgered,backstreet,backdrop,awkwardly,avoids,avocado,auras,attuned,attends,atheists,astaire,assuredly,art's,arrivederci,armaments,arises,argyle,argument's,argentine,appetit,appendectomy,appealed,apologetic,antihistamine,antigua,anesthesiologist,amulets,algonquin,alexander's,ales,albie,alarmist,aiight,agility,aforementioned,adstream,adolescents,admirably,adjectives,addison's,activists,acquaint,acids,abound,abominable,abolish,abode,abfc,aaaaaaah,zorg,zoltan,zoe's,zekes,zatunica,yama,wussy,wrcw,worded,wooed,woodrell,wiretap,windowsill,windjammer,windfall,whitey's,whitaker's,whisker,whims,whatiya,whadya,westerns,welded,weirdly,weenies,webster's,waunt,washout,wanto,waning,vitality,vineyards,victimless,vicki's,verdad,veranda,vegan,veer,vandaley,vancouver,vancomycin,valise,validated,vaguest,usefulness,upshot,uprising,upgrading,unzip,unwashed,untrained,unsuitable,unstuck,unprincipled,unmentionables,unjustly,unit's,unfolds,unemployable,uneducated,unduly,undercut,uncovering,unconsciousness,unconsciously,unbeknownst,unaffected,ubiquitous,tyndareus,tutors,turncoat,turlock,tulle,tuesday's,tryouts,truth's,trouper,triplette,trepkos,tremor,treeger,treatment's,traveller,traveler's,trapeze,traipse,tradeoff,trach,torin,tommorow,tollan,toity,timpani,tilted,thumbprint,throat's,this's,theater's,thankless,terrestrial,tenney's,tell'em,telepathy,telemarketing,telekinesis,teevee,teeming,tc's,tarred,tankers,tambourine,talentless,taki,takagi,swooped,switcheroo,swirly,sweatpants,surpassed,surgeon's,supermarkets,sunstroke,suitors,suggestive,sugarcoat,succession,subways,subterfuge,subservient,submitting,subletting,stunningly,student's,strongbox,striptease,stravanavitch,stradling,stoolie,stodgy,stocky,stimuli,stigmata,stifle,stealer,statewide,stark's,stardom,stalemate,staggered,squeezes,squatter,squarely,sprouted,spool,spirit's,spindly,spellman's,speedos,specify,specializing,spacey,soups,soundly,soulmates,somethin's,somebody'll,soliciting,solenoid,sobering,snowflakes,snowballs,snores,slung,slimming,slender,skyscrapers,skulk,skivvies,skillful,skewered,skewer,skaters,sizing,sistine,sidebar,sickos,shushing,shunt,shugga,shone,shol'va,shiv,shifter,sharply,sharpened,shareholder,shapeshifter,shadowing,shadoe,serviced,selwyn,selectman,sefelt,seared,seamen,scrounging,scribbling,scotty's,scooping,scintillating,schmoozing,schenectady,scene's,scattering,scampi,scallops,sat's,sapphires,sans,sanitarium,sanded,sanction,safes,sacrificial,rudely,roust,rosebush,rosasharn,rondell,roadhouse,riveted,rile,ricochet,rhinoceros,rewrote,reverence,revamp,retaliatory,rescues,reprimand,reportedly,replicators,replaceable,repeal,reopening,renown,remo's,remedied,rembrandt,relinquishing,relieving,rejoicing,reincarnated,reimbursed,refinement,referral,reevaluate,redundancy,redid,redefine,recreating,reconnected,recession,rebelling,reassign,rearview,reappeared,readily,rayne,ravings,ravage,ratso,rambunctious,rallying,radiologist,quiver,quiero,queef,quark,qualms,pyrotechnics,pyro,puritan,punky,pulsating,publisher's,psychosomatic,provisional,proverb,protested,proprietary,promiscuous,profanity,prisoner's,prioritize,preying,predisposition,precocious,precludes,preceding,prattling,prankster,povich,potting,postpartum,portray,porter's,porridge,polluting,pogo,plowing,plating,plankton,pistachio,pissin,pinecone,pickpocket,physicists,physicals,pesticides,peruse,pertains,personified,personalize,permitting,perjured,perished,pericles,perfecting,percentages,pepys,pepperdine,pembry,peering,peels,pedophile,patties,pathogen,passkey,parrots,paratroopers,paratrooper,paraphernalia,paralyzing,panned,pandering,paltry,palpable,painkiller,pagers,pachyderm,paced,overtaken,overstay,overestimated,overbite,outwit,outskirts,outgrow,outbid,origins,ordnance,ooze,ooops,oomph,oohhh,omni,oldie,olas,oddball,observers,obscurity,obliterate,oblique,objectionable,objected,oars,o'keefe,nygma,nyet,nouveau,notting,nothin's,noches,nnno,nitty,nighters,nigger's,niche,newsstands,newfoundland,newborns,neurosurgery,networking,nellie's,nein,neighboring,negligible,necron,nauseated,nastiest,nasedo's,narrowing,narrator,narcolepsy,napa,nala,nairobi,mutilate,muscled,murmur,mulva,multitude,multiplex,mulling,mules,mukada,muffled,mueller's,motorized,motif,mortgages,morgues,moonbeams,monogamy,mondays,mollusk,molester,molestation,molars,modifications,modeled,moans,misuse,misprint,mismatched,mirth,minnow,mindful,mimosas,millander,mikhail,mescaline,mercutio,menstrual,menage,mellowing,medicaid,mediator,medevac,meddlesome,mcgarry's,matey,massively,massacres,marky,many's,manifests,manifested,manicures,malevolent,malaysian,majoring,madmen,mache,macarthur's,macaroons,lydell,lycra,lunchroom,lunching,lozenges,lorenzo's,looped,look's,lolly,lofty,lobbyist,litigious,liquidate,linoleum,lingk,lincoln's,limitless,limitation,limber,lilacs,ligature,liftoff,lifeboats,lemmiwinks,leggo,learnin,lazarre,lawyered,landmarks,lament,lambchop,lactose,kringle,knocker,knelt,kirk's,kins,kiev,keynote,kenyon's,kenosha,kemosabe,kazi,kayak,kaon,kama,jussy,junky,joyce's,journey's,jordy,jo's,jimmies,jetson,jeriko,jean's,janet's,jakovasaur,jailed,jace,issacs,isotopes,isabela,irresponsibility,ironed,intravenous,intoxication,intermittent,insufficient,insinuated,inhibitors,inherits,inherently,ingest,ingenue,informs,influenza,inflexible,inflame,inevitability,inefficient,inedible,inducement,indignant,indictments,indentured,indefensible,inconsistencies,incomparable,incommunicado,in's,improvising,impounded,illogical,ignoramus,igneous,idlewild,hydrochloric,hydrate,hungover,humorless,humiliations,humanoid,huhh,hugest,hudson's,hoverdrone,hovel,honor's,hoagie,hmmph,hitters,hitchhike,hit's,hindenburg,hibernating,hermione,herds,henchman,helloooo,heirlooms,heaviest,heartsick,headshot,headdress,hatches,hastily,hartsfield's,harrison's,harrisburg,harebrained,hardships,hapless,hanen,handsomer,hallows,habitual,habeas,guten,gus's,gummy,guiltier,guidebook,gstaad,grunts,gruff,griss,grieved,grids,grey's,greenville,grata,granny's,gorignak,goosed,goofed,goat's,gnarly,glowed,glitz,glimpses,glancing,gilmores,gilligan's,gianelli,geraniums,georgie's,genitalia,gaydar,gart,garroway,gardenia,gangbusters,gamblers,gamble's,galls,fuddy,frumpy,frowning,frothy,fro'tak,friars,frere,freddy's,fragrances,founders,forgettin,footsie,follicles,foes,flowery,flophouse,floor's,floatin,flirts,flings,flatfoot,firefighter,fingerprinting,fingerprinted,fingering,finald,film's,fillet,file's,fianc,femoral,fellini,federated,federales,faze,fawkes,fatally,fascists,fascinates,farfel,familiarity,fambly,falsified,fait,fabricating,fables,extremist,exterminators,extensively,expectant,excusez,excrement,excercises,excavation,examinations,evian,evah,etins,esther's,esque,esophageal,equivalency,equate,equalizer,environmentally,entrees,enquire,enough's,engine's,endorsed,endearment,emulate,empathetic,embodies,emailed,eggroll,edna's,economist,ecology,eased,earmuffs,eared,dyslexic,duper,dupe,dungeons,duncan's,duesouth,drunker,drummers,druggie,dreadfully,dramatics,dragnet,dragline,dowry,downplay,downers,doritos,dominatrix,doers,docket,docile,diversify,distracts,disruption,disloyalty,disinterested,disciple,discharging,disagreeable,dirtier,diplomats,dinghy,diner's,dimwitted,dimoxinil,dimmy,dietary,didi,diatribe,dialects,diagrams,diagnostics,devonshire,devising,deviate,detriment,desertion,derp,derm,dept,depressants,depravity,dependence,denounced,deniability,demolished,delinquents,defiled,defends,defamation,deepcore,deductive,decrease,declares,declarations,decimated,decimate,deb's,deadbolt,dauthuille,dastardly,darla's,dans,daiquiris,daggers,dachau,d'ah,cymbals,customized,curved,curiouser,curdled,cupid's,cults,cucamonga,cruller,cruces,crow's,crosswalk,crossover,crinkle,crescendo,cremate,creeper,craftsman,cox's,counteract,counseled,couches,coronet,cornea,cornbread,corday,copernicus,conveyed,contrition,contracting,contested,contemptible,consultants,constructing,constipated,conqueror,connor's,conjoined,congenital,confounded,condescend,concubine,concoct,conch,concerto,conceded,compounded,compensating,comparisons,commoners,committment,commencement,commandeered,comely,coined,cognitive,codex,coddled,cockfight,cluttered,clunky,clownfish,cloaked,cliches,clenched,cleft,cleanin,cleaner's,civilised,circumcised,cimmeria,cilantro,chutzpah,chutney,chucking,chucker,chronicles,chiseled,chicka,chicago's,chattering,charting,characteristic,chaise,chair's,cervix,cereals,cayenne,carrey,carpal,carnations,caricature,cappuccinos,candy's,candied,cancer's,cameo,calluses,calisthenics,cadre,buzzsaw,bushy,burners,bundled,bum's,budington,buchanans,brock's,britons,brimming,breeders,breakaway,braids,bradley's,boycotting,bouncers,botticelli,botherin,boosting,bookkeeping,booga,bogyman,bogged,bluepoint's,bloodthirsty,blintzes,blanky,blak,biosphere,binturong,billable,bigboote,bewildered,betas,bernard's,bequeath,beirut,behoove,beheaded,beginners,beginner,befriend,beet,bedpost,bedded,bay's,baudelaires,barty,barreled,barboni,barbeque,bangin,baltus,bailout,bag's,backstabber,baccarat,awning,awaited,avenues,austen,augie,auditioned,auctions,astrology,assistant's,assassinations,aspiration,armenians,aristocrat,arguillo,archway,archaeologist,arcane,arabic,apricots,applicant,apologising,antennas,annyong,angered,andretti,anchorman,anchored,amritsar,amour,amidst,amid,americana,amenable,ambassadors,ambassador's,amazement,allspice,alannis,airliner,airfare,airbags,ahhhhhhhhh,ahhhhhhhh,ahhhhhhh,agitator,afternoon's,afghan,affirmation,affiliate,aegean,adrenal,actor's,acidosis,achy,achoo,accessorizing,accentuate,academically,abuses,abrasions,abilene,abductor,aaaahhh,zuzu,zoot,zeroing,zelner,zeldy,yo's,yevgeny,yeup,yeska,yellows,yeesh,yeahh,yamuri,yaks,wyatt's,wspr,writing's,wrestlers,wouldn't've,workmanship,woodsman,winnin,winked,wildness,widespread,whoring,whitewash,whiney,when're,wheezer,wheelman,wheelbarrow,whaling,westerburg,wegener's,weekdays,weeding,weaving,watermelons,watcher's,washboard,warmly,wards,waltzes,walt's,walkway,waged,wafting,voulez,voluptuous,vitone,vision's,villa's,vigilantes,videotaping,viciously,vices,veruca,vermeer,verifying,ventured,vaya,vaults,vases,vasculitis,varieties,vapor,valets,upriver,upholstered,upholding,unwavering,unused,untold,unsympathetic,unromantic,unrecognizable,unpredictability,unmask,unleashing,unintentional,unilaterally,unglued,unequivocal,underside,underrated,underfoot,unchecked,unbutton,unbind,unbiased,unagi,uhhhhh,turnovers,tugging,trouble's,triads,trespasses,treehorn,traviata,trappers,transplants,transforming,trannie,tramping,trainers,traders,tracheotomy,tourniquet,tooty,toothless,tomarrow,toasters,tine,tilting,thruster,thoughtfulness,thornwood,therapies,thanksgiving's,tha's,terri's,tengo,tenfold,telltale,telephoto,telephoned,telemarketer,teddy's,tearin,tastic,tastefully,tasking,taser,tamed,tallow,taketh,taillight,tadpoles,tachibana,syringes,sweated,swarthy,swagger,surrey,surges,surf's,supermodels,superhighway,sunup,sun'll,summaries,sumerian,sulu,sulphur,sullivan's,sulfa,suis,sugarless,sufficed,substituted,subside,submerged,subdue,styling,strolled,stringy,strengthens,street's,straightest,straightens,storyteller,storefront,stopper,stockpiling,stimulant,stiffed,steyne,sternum,stereotypical,stepladder,stepbrother,steers,steeple,steelheads,steakhouse,statue's,stathis,stankylecartmankennymr,standoffish,stalwart,stallions,stacy's,squirted,squeaker,squad's,spuds,spritz,sprig,sprawl,spousal,sportsman,sphincter,spenders,spearmint,spatter,sparrows,spangled,southey,soured,sonuvabitch,somethng,societies,snuffed,snowfall,snowboarding,sniffs,snafu,smokescreen,smilin,slurred,slurpee,slums,slobs,sleepwalker,sleds,slays,slayage,skydiving,sketched,skateboarding,skanks,sixed,siri,sired,siphoned,siphon,singer's,simpering,silencer,sigfried,siena,sidearm,siddons,sickie,siberian,shuteye,shuk,shuffleboard,shrubberies,shrouded,showmanship,shower's,shouldn't've,shortwave,shoplift,shooter's,shiatsu,sheriffs,shak,shafts,serendipity,serena's,sentries,sentance,sensuality,semesters,seething,sedition,secular,secretions,searing,scuttlebutt,sculpt,scowling,scouring,scorecard,schwarzenegger,schoolers,schmucks,scepters,scaly,scalps,scaling,scaffolding,sauces,sartorius,santen,sampler,salivating,salinger,sainthood,said's,saget,saddens,rygalski,rusting,rumson's,ruination,rueland,rudabaga,rubles,rowr,rottweiler,rotations,roofies,romantics,rollerblading,roldy,rob's,roadshow,rike,rickets,rible,rheza,revisiting,revisited,reverted,retrospective,retentive,resurface,restores,respite,resounding,resorting,resolutions,resists,repulse,repressing,repaying,reneged,relays,relayed,reinforce,regulator,registers,refunds,reflections,rediscover,redecorated,recruitment,reconstructive,reconstructed,recommitted,recollect,recoil,recited,receptor,receptacle,receivers,reassess,reanimation,realtors,razinin,ravaged,ratios,rationalization,ratified,ratatouille,rashum,rasczak,rarer,rapping,rancheros,rampler,rain's,railway,racehorse,quotient,quizzing,quips,question's,quartered,qualification,purring,pummeling,puede,publicized,psychedelic,proximo,proteins,protege,prospectus,pronouncing,pronoun,prolonging,program's,proficient,procreation,proclamations,prio,principled,prides,pricing,presbyterian,preoccupation,prego,preferential,predicts,precog,prattle,pounced,potshots,potpourri,portsmouth,porque,poppie's,poms,pomeranian,pomegranates,polynesian,polymer,polenta,plying,plume,plumber's,pluie,plough,plesac,playoff,playmates,planter,plantains,plaintiff's,pituitary,pisano's,pillowcase,piddle,pickers,phys,photocopied,philistine,pfeiffer's,peyton's,petitioned,persuading,perpetuate,perpetually,periodically,perilous,pensacola,pawned,pausing,pauper,patterned,pats,patronage,passover,partition,parter,parlez,parlay,parkinson's,parades,paperwork's,pally,pairing,ovulation,overtake,overstate,overpowering,overpowered,overconfident,overbooked,ovaltine,ouzo,outweighs,outings,outfit's,out's,ottos,orrin,originate,orifice,orangutan,optimal,optics,opportunistic,ooww,oopsy,ooooooooh,ooohhhh,onyx,onslaught,oldsmobile,ocular,ocean's,obstruct,obscenely,o'dwyer,o'brien's,nutjob,nunur,notifying,nostrand,nonny,nonfat,noblest,nimble,nikes,nicht,newsworthy,network's,nestled,nessie,necessities,nearsighted,ne'er,nazareth,navidad,nastier,nasa's,narco,nakedness,muted,mummified,multiplying,mudda,mtv's,mozzarella,moxica,motorists,motivator,motility,mothafucka,mortmain,mortgaged,mortally,moroccan,mores,moonshine,mongers,moe's,modify,mobster's,mobilization,mobbed,mitigating,mistah,misrepresented,mishke,misfortunes,misdirection,mischievous,mirrored,mineshaft,mimosa,millers,millaney,miho,midday,microwaves,mick's,metzenbaum,metres,merc,mentoring,medicine's,mccovey,maya's,mau's,masterful,masochistic,martie,marliston,market's,marijawana,marie's,marian's,manya,manuals,mantumbi,mannheim,mania,mane,mami's,malarkey,magnifique,magics,magician's,madrona,madox,madison's,machida,m'mm,m'hm,m'hidi,lyric,luxe,luther's,lusty,lullabies,loveliness,lotions,looka,lompoc,loader,litterbug,litigator,lithe,liquorice,lins,linguistics,linds,limericks,lightbulb,lewises,letch,lemec,lecter's,leavenworth,leasing,leases,layover,layered,lavatory,laurels,launchers,laude,latvian,lateness,lasky's,laparotomy,landlord's,laboring,la's,kumquat,kuato,kroff,krispy,kree,krauts,kona,knuckleheads,knighthood,kiva,kitschy,kippers,kip's,kimbrow,kike,keypad,keepsake,kebab,keane's,kazakhstan,karloff,justices,junket,juicer,judy's,judgemental,jsut,jointed,jogs,jezzie,jetting,jekyll,jehovah's,jeff's,jeeze,jeeter,jeesus,jeebs,janeane,jalapeno,jails,jailbait,jagged,jackin,jackhammer,jacket's,ixnay,ivanovich,issue's,isotope,island's,irritates,irritability,irrevocable,irrefutable,irma's,irked,invoking,intricacies,interferon,intents,inte,insubordinate,instructive,instinctive,inspector's,inserting,inscribed,inquisitive,inlay,injuns,inhibited,infringement,information's,infer,inebriated,indignity,indecisive,incisors,incacha,inauguration,inalienable,impresses,impregnate,impregnable,implosion,immersed,ikea,idolizes,ideological,idealism,icepick,hypothyroidism,hypoglycemic,hyde's,hutz,huseni,humvee,hummingbird,hugely,huddling,housekeeper's,honing,hobnobbing,hobnob,histrionics,histamine,hirohito,hippocratic,hindquarters,hinder,himalayan,hikita,hikes,hightailed,hieroglyphics,heyy,heuh,heretofore,herbalist,her's,henryk,henceforth,hehey,hedriks,heartstrings,headmistress,headlight,harvested,hardheaded,happend,handlers,handlebars,hagitha,habla,gyroscope,guys'd,guy'd,guttersnipe,grump,growed,grovelling,grooves,groan,greenbacks,greats,gravedigger,grating,grasshoppers,grappling,graph,granger's,grandiose,grandest,gram's,grains,grafted,gradual,grabthar's,goop,gooood,goood,gooks,godsakes,goaded,gloria's,glamorama,giveth,gingham,ghostbusters,germane,georgy,geisha,gazzo,gazelles,gargle,garbled,galgenstein,galapagos,gaffe,g'day,fyarl,furnish,furies,fulfills,frowns,frowned,frommer's,frighteningly,fresco,freebies,freakshow,freakishly,fraudulent,fragrant,forewarned,foreclose,forearms,fordson,ford's,fonics,follies,foghorn,fly's,flushes,fluffy's,flitting,flintstone,flemmer,flatline,flamboyant,flabby,fishbowl,firsts,finger's,financier,figs,fidgeting,fictitious,fevers,feur,ferns,feminism,fema,feigning,faxing,fatigued,fathoms,fatherless,fares,fancier,fanatical,fairs,factored,eyelid,eyeglasses,eye's,expresso,exponentially,expletive,expectin,excruciatingly,evidentiary,ever'thing,evelyn's,eurotrash,euphoria,eugene's,eubie,ethiopian,ethiopia,estrangement,espanol,erupted,ernie's,erlich,eres,epitome,epitaph,environments,environmentalists,entrap,enthusiastically,entertainers,entangled,enclose,encased,empowering,empires,emphysema,embers,embargo,emasculating,elizabethan,elephant's,eighths,egyptians,effigy,editions,echoing,eardrum,dyslexia,duplicitous,duplicated,dumpty,dumbledore,dufus,dudley's,duddy,duck's,duchamp,drunkenness,drumlin,drowns,droid,drinky,drifts,drawbridge,dramamine,downey's,douggie,douchebag,dostoyevsky,dorian's,doodling,don'tcha,domo,domineering,doings,dogcatcher,documenting,doctoring,doctoral,dockers,divides,ditzy,dissimilar,dissecting,disparage,disliking,disintegrating,dishwalla,dishonored,dishing,disengaged,discretionary,discard,disavowed,directives,dippy,diorama,dimmed,diminishing,dilate,dijon,digitalis,diggory,dicing,diagnosing,devout,devola,developmental,deter,destiny's,desolation,descendant,derived,derevko's,deployment,dennings,denials,deliverance,deliciously,delicacies,degenerates,degas,deflector,defile,deference,defenders,deduced,decrepit,decreed,decoding,deciphered,dazed,dawdle,dauphine,daresay,dangles,dampen,damndest,customer's,curricular,cucumbers,cucaracha,cryogenically,cruella,crowd's,croaks,croaked,criticise,crit,crisper,creepiest,creep's,credit's,creams,crawford's,crackle,crackin,covertly,cover's,county's,counterintelligence,corrosive,corpsman,cordially,cops'll,convulsions,convoluted,convincingly,conversing,contradictions,conga,confucius,confrontational,confab,condolence,conditional,condition's,condiments,composing,complicit,compiled,compile,compiegne,commuter,commodus,commissions,comings,cometh,combining,colossus,collusion,collared,cockeyed,coastline,clobber,clemonds,clashes,clarithromycin,clarified,cinq,cienega,chronological,christmasy,christmassy,chloroform,chippie,childless,chested,chemistry's,cheerios,cheeco,checklist,chaz,chauvinist,char,chang's,chandlers,chamois,chambermaid,chakras,chak,censored,cemented,cellophane,celestial,celebrations,caveat,catholicism,cataloguing,cartmanland,carples,carny,carded,caramels,captors,caption,cappy,caped,canvassing,cannibalism,canada's,camille's,callback,calibrated,calamine,cal's,cabo,bypassed,buzzy,buttermilk,butterfingers,bushed,burlesque,bunsen,bung,bulimia,bukatari,buildin,budged,bronck's,brom,brobich,bringer,brine,brendell,brawling,bratty,brasi,braking,braised,brackett's,braced,boyish,boundless,botch,borough,boosh,bookies,bonbons,bois,bodes,bobunk,bluntly,blossoming,bloopers,bloomers,bloodstains,bloodhounds,blitzen,blinker,blech,blasts,blanca's,bitterly,biter,biometric,bioethics,bilk,bijan,bigoted,bicep,betrothed,bergdorf's,bereaved,bequeathed,belo,bellowing,belching,beholden,befriended,beached,bawk,battled,batmobile,batman's,baseline,baseball's,barcodes,barch,barbie's,barbecuing,bandanna,baldy,bailey's,baghdad,backwater,backtrack,backdraft,ayuh,awgh,augustino,auctioned,attaching,attaches,atrophy,atrocity,atley,athletics,atchoo,asymmetrical,asthmatic,assoc,assists,ascending,ascend,articulated,arrr,armstrong's,armchair,arisen,archeology,archeological,arachnids,aptly,applesauce,appetizing,antisocial,antagonizing,anorexia,anini,angie's,andersons,anarchist,anagram,amputation,amherst,alleluia,algorithms,albemarle,ajar,airlock,airbag,aims,aimless,ailments,agua,agonized,agitate,aggravating,affirming,aerosol,aerosmith,aeroplane,acing,accumulated,accomplishing,accolades,accidently,academia,abuser,abstain,abso,abnormally,aberration,abandons,aaww,aaaaahh,zlotys,zesty,zerzura,zapruder,zany,zantopia,yugoslavia,youo,yoru,yipe,yeow,yello,yelburton,yeess,yaah,y'knowwhati'msayin,wwhat,wussies,wrenched,would'a,worryin,wormser,wooooo,wookiee,wolfe's,wolchek,woes,wishin,wiseguys,winston's,winky,wine's,windbreaker,wiggy,wieners,wiedersehen,whoopin,whittled,whey,whet,wherefore,wharvey,welts,welt,wellstone,weee,wednesday's,wedges,wavered,watchit,wastebasket,ward's,wank,wango,wallet's,wall's,waken,waiver,waitressed,wacquiem,wabbit,vrykolaka,voula,vote's,volt,volga,volcanoes,vocals,vitally,visualizing,viscous,virgo,virg,violet's,viciousness,vewy,vespers,vertes,verily,vegetarians,vater,vaseline,varied,vaporize,vannacutt,vallens,valenti's,vacated,uterine,usta,ussher,urns,urinating,urchin,upping,upheld,unwitting,untreated,untangle,untamed,unsanitary,unraveled,unopened,unisex,uninvolved,uninteresting,unintelligible,unimaginative,undisclosed,undeserving,undermines,undergarments,unconcerned,unbroken,ukrainian,tyrants,typist,tykes,tybalt,twosome,twits,tutti,turndown,tularemia,tuberculoma,tsimshian,truffaut,truer,truant,trove,triumphed,tripe,trigonometry,trifled,trifecta,tricycle,trickle,tribulations,trevor's,tremont,tremoille,treaties,trawler,translators,transcends,trafficker,touchin,tonnage,tomfoolery,tolls,tokens,tinkered,tinfoil,tightrope,ticket's,thth,thousan,thoracotomy,theses,thesaurus,theologian,themed,thawing,thatta,thar,textiles,testimonies,tessio,terminating,temps,taxidermist,tator,tarkin,tangent,tactile,tachycardia,t'akaya,synthesize,symbolically,swelco,sweetbreads,swedes,swatting,swastika,swamps,suze,supernova,supercollider,sunbathing,summarily,suffocation,sueleen,succinct,subtitle,subsided,submissive,subjecting,subbing,subatomic,stupendous,stunted,stubble,stubbed,striving,streetwalker,strategizing,straining,straightaway,storyline,stoli,stock's,stipulated,stimulus,stiffer,stickup,stens,steamroller,steadwell,steadfast,stave,statutes,stateroom,stans,stacey's,sshhhh,squishing,squinting,squealed,sprouting,sprimp,spreadsheets,sprawled,spotlights,spooning,spoiler,spirals,spinner's,speedboat,spectacles,speakerphone,spar,spaniards,spacing,sovereignty,southglen,souse,soundproof,soothsayer,soon's,sommes,somethings,solidify,soars,snorted,snorkeling,snitches,sniping,sniper's,snifter,sniffin,snickering,sneer,snarl,smila,slinking,sleuth,slater's,slated,slanted,slanderous,slammin,skyscraper,skimp,skilosh,skeletal,skag,siteid,sirloin,singe,simulate,signaled,sighing,sidekicks,sicken,shrubs,shrub,showstopper,shot's,shostakovich,shoreline,shoppin,shoplifter,shop's,shoe's,shoal,shitter,shirt's,shimokawa,sherborne,sheds,shawna's,shavadai,sharpshooters,sharking,shane's,shakespearean,shagged,shaddup,sexism,sexes,sesterces,serotonin,sequences,sentient,sensuous,seminal,selections,seismic,seashell,seaplane,sealing,seahaven,seagrave,scuttled,scullery,scow,scots,scorcher,scorch,schotzie,schnoz,schmooze,schlep,schizo,schindler's,scents,scalping,scalped,scallop,scalding,sayeth,saybrooke,sawed,savoring,sardine,sandy's,sandstorm,sandalwood,samoa,samo,salutations,salad's,saki,sailor's,sagman,s'okay,rudy's,rsvp'd,royale,rousted,rootin,roofs,romper,romanovs,rollercoaster,rolfie,rockers,rock's,robinsons,ritzy,ritualistic,ringwald,rhymed,rheingold,rewrites,revolved,revolutionaries,revoking,reviewer,reverts,retrofit,retort,retinas,resurfaced,respirations,respectively,resolute,resin,reprobate,replaying,repayment,repaint,renquist,renege,renders,rename,remarked,relapsing,rekindled,rejuvenating,rejuvenated,reinstating,reinstatement,reigns,referendums,recriminations,recitals,rechecked,reception's,recaptured,rebounds,reassemble,rears,reamed,realty,reader's,reacquaint,rayanne,ravish,rava,rathole,raspail,rarest,rapists,rants,ramone,ragnar,radiating,radial,racketeer,quotation,quittin,quitters,quintessential,quincy's,queremos,quellek,quelle,quasimodo,quarterbacks,quarter's,pyromaniac,puttanesca,puritanical,purged,purer,puree,punishments,pungent,pummel,puedo,pudge,puce,psychotherapist,psycho's,prosecutorial,prosciutto,propositioning,propellers,pronouns,progresses,procured,procrastination,processes,probationary,primping,primates,priest's,preventative,prevails,presided,preserves,preservatives,prefix,predecessors,preachy,prancer,praetorians,practicality,powders,potus,pot's,postop,positives,poser,portolano,portokalos,poolside,poltergeists,pocketed,poach,plunder,plummeted,plucking,plop,plimpton,plethora,playthings,player's,playboys,plastique,plainclothes,pious,pinpointed,pinkus,pinks,pilgrimage,pigskin,piffle,pictionary,piccata,photocopy,phobias,persia,permissible,perils,perignon,perfumes,peon,penned,penalized,peg's,pecks,pecked,paving,patriarch,patents,patently,passable,participants,parasitic,parasailing,paramus,paramilitary,parabolic,parable,papier,paperback,paintbrush,pacer,paaiint,oxen,owen's,overtures,overthink,overstayed,overrule,overlapping,overestimate,overcooked,outlandish,outgrew,outdoorsy,outdo,outbound,ostensibly,originating,orchestrate,orally,oppress,opposable,opponent's,operation's,oooohh,oomupwah,omitted,okeydokey,okaaay,ohashi,offerings,of'em,od'd,occurrences,occupant,observable,obscenities,obligatory,oakie,o'malley's,o'gar,nyah's,nurection,nun's,nougat,nostradamus,norther,norcom,nooch,nonviolent,nonsensical,nominating,nomadic,noel's,nkay,nipped,nimbala,nigeria,nigel's,nicklaus,newscast,nervously,nell's,nehru,neckline,nebbleman,navigator,nasdaq,narwhal,nametag,n'n't,mycenae,myanmar,muzak,muumuu,murderer's,mumbled,mulvehill,multiplication,multiples,muggings,muffet,mozart's,mouthy,motorbike,motivations,motivates,motaba,mortars,mordred,mops,moocher,moniker,mongi,mondo,monday's,moley,molds,moisturize,mohair,mocky,mmkay,mistuh,missis,mission's,misdeeds,minuscule,minty,mined,mincemeat,milton's,milt,millennia,mikes,miggs,miffed,mieke's,midwestern,methadone,metaphysics,messieur,merging,mergers,menopausal,menagerie,meee,mckenna's,mcgillicuddy,mayflowers,maxim's,matrimonial,matisse,matick,masculinity,mascots,masai,marzipan,marika,maplewood,manzelle,manufactures,manticore's,mannequins,manhole,manhandle,manatee,mallory's,malfunctions,mainline,magua's,madwoman,madeline's,machiavelli,lynley,lynching,lynched,lurconis,lujack,lubricant,looove,loons,loom,loofah,longevity,lonelyhearts,lollipops,loca,llama,liquidation,lineswoman,lindsey's,lindbergh,lilith's,lila's,lifers,lichen,liberty's,lias,lexter,levee,letter's,lessen,lepner,leonard's,lemony,leggy,leafy,leaflets,leadeth,lazerus,lazare,lawford,languishing,langford's,landslide,landlords,lagoda,ladman,lad's,kuwait,kundera,krist's,krinkle,krendler,kreigel,kowolski,kosovo,knockdown,knifed,kneed,kneecap,kids'll,kevlar,kennie,keeled,kazootie,kaufman's,katzenmoyer,kasdan,karl's,karak,kapowski,kakistos,jumpers,julyan,juanito,jockstrap,jobless,jiggly,jesuit,jaunt,jarring,jabbering,israelites,irrigate,irrevocably,irrationally,ironies,ions,invitro,inventions,intrigues,intimated,interview's,intervening,interchangeable,intently,intentioned,intelligently,insulated,institutional,instill,instigator,instigated,instep,inopportune,innuendoes,inheriting,inflate,infiltration,infects,infamy,inducing,indiscretions,indiscreet,indio,indignities,indict,indecision,incurred,incubation,inconspicuous,inappropriately,impunity,impudent,improves,impotence,implicates,implausible,imperfection,impatience,immutable,immobilize,illustration,illumination,idiot's,idealized,idealist,icelandic,iambic,hysterically,hyperspace,hygienist,hydraulics,hydrated,huzzah,husks,hurricane's,hunt's,hunched,huffed,hubris,hubbub,hovercraft,houngan,hotel's,hosed,horoscopes,hoppy,hopelessness,hoodwinked,honourable,honorably,honeysuckle,homeowners,homegirl,holiest,hoisted,hoho,ho's,hippity,hildie,hikers,hieroglyphs,hexton,herein,helicopter's,heckle,heats,heartbeat's,heaping,healthilizer,headmaster's,headfirst,hawk's,haviland's,hatsue,harlot,hardwired,hanno's,hams,hamilton's,halothane,hairstyles,hails,hailed,haagen,haaaaa,gyno,gutting,gurl,gumshoe,gummi,gull,guerilla,gttk,grover's,grouping,groundless,groaning,gristle,grills,graynamore,grassy,graham's,grabbin,governmental,goodes,goggle,godlike,glittering,glint,gliding,gleaming,glassy,girth,gimbal,gilmore's,gibson's,giblets,gert,geometric,geographical,genealogy,gellers,geller's,geezers,geeze,garshaw,gargantuan,garfunkel,gardner's,garcia's,garb,gangway,gandarium,gamut,galoshes,gallivanting,galleries,gainfully,gack,gachnar,fusionlips,fusilli,furiously,fulfil,fugu,frugal,fron,friendship's,fricking,frederika,freckling,frauds,fraternal,fountainhead,forthwith,forgo,forgettable,foresight,foresaw,footnotes,fondling,fondled,fondle,folksy,fluttering,flutie,fluffing,floundering,florin,florentine,flirtatious,flexing,flatterer,flaring,fizz,fixating,five's,fishnet,firs,firestorm,finchy,figurehead,fifths,fiendish,fertilize,ferment,fending,fellahs,feeny's,feelers,feeders,fatality,fascinate,fantabulous,falsify,fallopian,faithless,fairy's,fairer,fair's,fainter,failings,facto,facets,facetious,eyepatch,exxon,extraterrestrials,extradite,extracurriculars,extinguish,expunged,exports,expenditure,expelling,exorbitant,exigent,exhilarated,exertion,exerting,exemption,excursions,excludes,excessively,excercise,exceeds,exceeding,everbody,evaporated,euthanasia,euros,europeans,escargot,escapee,erases,epizootics,epithelials,ephrum,enthusiast,entanglements,enslaved,enslave,engrossed,endeavour,enables,enabled,empowerment,employer's,emphatic,emeralds,embroiled,embraces,ember,embellished,emancipated,ello,elisa's,elevates,ejaculate,ego's,effeminate,economically,eccentricities,easygoing,earshot,durp,dunks,dunes,dullness,dulli,dulled,drumstick,dropper,driftwood,dregs,dreck,dreamboat,draggin,downsizing,dost,doofer,donowitz,dominoes,dominance,doe's,diversions,distinctions,distillery,distended,dissolving,dissipate,disraeli,disqualify,disowned,dishwashing,discusses,discontent,disclosed,disciplining,discerning,disappoints,dinged,diluted,digested,dicking,diablos,deux,detonating,destinations,despising,designer's,deserts,derelict,depressor,depose,deport,dents,demonstrations,deliberations,defused,deflection,deflecting,decryption,decoys,decoupage,decompress,decibel,decadence,dealer's,deafening,deadlock,dawning,dater,darkened,darcy's,dappy,dancing's,damon's,dallying,dagon,d'etat,czechoslovakians,cuticles,cuteness,curacao,cupboards,cumulative,culottes,culmination,culminating,csi's,cruisin,crosshairs,cronyn,croc,criminalistics,crimean,creatively,creaming,crapping,cranny,cowed,countermeasures,corsica,corinne's,corey's,cooker,convened,contradicting,continuity,constitutionally,constipation,consort,consolidate,consisted,connection's,confining,confidences,confessor,confederates,condensation,concluding,conceiving,conceivably,concealment,compulsively,complainin,complacent,compiling,compels,communing,commonplace,commode,commission's,commissary,comming,commensurate,columnists,colonoscopy,colonists,collagen,collaborate,colchicine,coddling,clump,clubbed,clowning,closet's,clones,clinton's,clinic's,cliffhanger,classification,clang,citrus,cissy,circuitry,chronology,christophe,choosers,choker,chloride,chippewa,chip's,chiffon,chesty,chesapeake,chernobyl,chants,channeled,champagne's,chalet,chaka,cervical,cellphone,cellmates,caverns,catwalk,cathartic,catcher's,cassandra's,caseload,carpenter's,carolyn's,carnivorous,carjack,carbohydrates,capt,capitalists,canvass,cantonese,canisters,candlestick,candlelit,canaries,camry,camel's,calzones,calitri,caldy,cabin's,byline,butterball,bustier,burmese,burlap,burgeoning,bureaucrat,buffoons,buenas,bryan's,brookline,bronzed,broiled,broda,briss,brioche,briar,breathable,brea,brays,brassieres,braille,brahms,braddock's,boysenberry,bowman's,bowline,boutiques,botticelli's,boooo,boonies,booklets,bookish,boogeyman,boogey,bomb's,boldly,bogs,bogas,boardinghouse,bluuch,blundering,bluffs,bluer,blowed,blotto,blotchy,blossomed,blooms,bloodwork,bloodied,blithering,blinks,blathering,blasphemous,blacking,bison,birdson,bings,bilateral,bfmid,bfast,berserker,berkshires,bequest,benjamins,benevolence,benched,benatar,belthazor's,bellybutton,belabor,bela's,behooves,beddy,beaujolais,beattle,baxworth,batted,baseless,baring,barfing,barbi,bannish,bankrolled,banek,ballsy,ballpoint,balkans,balconies,bakers,bahama,baffling,badder,badda,bada,bactine,backgammon,baako,aztreonam,aztecs,awed,avon,autobiographical,autistic,authoritah,auspicious,august's,auditing,audible,auctioning,attitude's,atrocities,athlete's,astronomer,assessed,ascot,aristocratic,arid,argues,arachtoids,arachnid,aquaman,apropos,aprons,apprised,apprehensive,apex,anythng,antivenin,antichrist,antennae,anorexic,anoint,annum,annihilated,animal's,anguished,angioplasty,angio,amply,ampicillin,amphetamines,amino,american's,ambiguity,ambient,amarillo,alyssa's,alternator,alcove,albacore,alarm's,alabaster,airlifted,ahta,agrabah,affidavits,advocacy,advises,adversely,admonished,admonish,adler's,addled,addendum,acknowledgement,accuser,accompli,acclaim,acceleration,abut,abundant,absurdity,absolved,abrusso,abreast,abrasive,aboot,abductions,abducting,abbots,aback,ababwa,aand,aaahhhh,zorin,zinthar,zinfandel,zimbabwe,zillions,zephyrs,zatarcs,zacks,youuu,youths,yokels,yech,yardstick,yammer,y'understand,wynette,wrung,wrought,wreaths,wowed,wouldn'ta,worshiped,worming,wormed,workday,wops,woolly,wooh,woodsy,woodshed,woodchuck,wojadubakowski,withering,witching,wiseass,wiretaps,winner's,wining,willoby,wiccaning,whupped,whoopi,whoomp,wholesaler,whiteness,whiner,whatchya,wharves,whah,wetlands,westward,wenus,weirdoes,weds,webs,weaver's,wearer,weaning,watusi,wastes,warlock's,warfield's,waponi,waiting's,waistband,waht,wackos,vouching,votre,voight's,voiced,vivica,viveca,vivant,vivacious,visor,visitin,visage,virgil's,violins,vinny,vinci's,villas,vigor,video's,vicrum,vibrator,vetted,versailles,vernon's,venues,ventriloquism,venison,venerable,varnsen,variant,variance,vaporized,vapid,vanstock,vandals,vader's,vaccination,uuuuh,utilize,ushering,usda,usable,urur,urologist,urination,urinary,upstart,uprooted,unsubtitled,unspoiled,unseat,unseasonably,unseal,unsatisfying,unnerve,unlikable,unleaded,university's,universe's,uninsured,uninspired,uniformity,unicycle,unhooked,ungh,unfunny,unfreezing,unflattering,unfairness,unexpressed,unending,unencumbered,unearth,undiscovered,undisciplined,undertaken,understan,undershirt,underlings,underline,undercurrent,uncontrolled,uncivilized,uncharacteristic,umpteenth,uglies,u're,tut's,turner's,turbine,tunnel's,tuney,trustee,trumps,truckasaurus,trubshaw,trouser,trippy,tringle,trifling,trickster,triangular,trespassers,trespasser,traverse,traumas,trattoria,trashes,transgressions,tranquil,trampling,trainees,tracy's,tp'ed,toxoplasmosis,tounge,tortillas,torrent,torpedoed,topsy,topple,topnotch,top's,tonsil,tippin's,tions,timmuh,timithious,tilney,tighty,tightness,tightens,tidbits,ticketed,thyme,thrones,threepio,thoughtfully,thornhart's,thorkel,thommo,thing'll,theological,thel,theh,thefts,that've,thanksgivings,tetherball,testikov,terraforming,terminus,tepid,tendonitis,tenboom,telex,teleport,telepathic,teenybopper,taxicab,taxed,taut,tattered,tattaglias,tapered,tantric,tanneke,takedown,tailspin,tacs,tacit,tablet,tablecloth,systemic,syria,syphon,synthesis,symbiotic,swooping,swizzle,swiping,swindled,swilling,swerving,sweatshops,swayzak's,swaddling,swackhammer,svetkoff,suzie's,surpass,supossed,superdad,super's,sumptuous,sula,suit's,sugary,sugar's,sugai,suey,subvert,suburb,substantiate,subsidy,submersible,sublimating,subjugation,styx,stymied,stuntman,studded,strychnine,strikingly,strenuous,streetlights,strassmans,stranglehold,strangeness,straddling,straddle,stowaways,stotch,stockbrokers,stifling,stepford,stepdad's,steerage,steena,staunch,statuary,starlets,stanza,stanley's,stagnant,staggeringly,ssshhh,squaw,spurt,spungeon,sprightly,sprays,sportswear,spoonful,splittin,splitsville,spirituality,spiny,spider's,speedily,speculative,specialise,spatial,spastic,spas,sparrin,soybean,souvlaki,southie,southampton,sourpuss,soupy,soup's,soundstage,sophie's,soothes,somebody'd,solicited,softest,sociopathic,socialized,socialism,snyders,snowmobiles,snowballed,snatches,smugness,smoothest,smashes,slurp,slur,sloshed,sleight,skyrocket,skied,skewed,sizeable,sixpence,sipowicz,singling,simulations,simulates,similarly,silvery,silverstone,siesta,siempre,sidewinder,shyness,shuvanis,showoff,shortsighted,shopkeeper,shoehorn,shithouse,shirtless,shipshape,shingles,shifu,shes,sherman's,shelve,shelbyville,sheepskin,shat,sharpens,shaquille,shaq,shanshu,shania's,set's,servings,serpico,sequined,sensibilities,seizes,seesaw,seep,seconded,sebastian's,seashells,scrapped,scrambler,scorpions,scopes,schnauzer,schmo,schizoid,scampered,scag,savagely,saudis,satire,santas,sanskrit,sandovals,sanding,sandal,salient,saleswoman,sagging,s'cuse,rutting,ruthlessly,runoff,runneth,rulers,ruffians,rubes,roughriders,rotates,rotated,roswell's,rosalita,rookies,ron's,rollerblades,rohypnol,rogues,robinson's,roasts,roadies,river's,ritten,rippling,ripples,ring's,rigor,rigoletto,richardo,ribbed,revolutions,revlon's,reverend's,retreating,retractable,rethought,retaliated,retailers,reshoot,reserving,reseda,researchers,rescuer,reread,requisitions,repute,reprogram,representations,report's,replenish,repetitive,repetitious,repentance,reorganizing,renton,renee's,remodeled,religiously,relics,reinventing,reinvented,reheat,rehabilitate,registrar,regeneration,refueling,refrigerators,refining,reenter,redress,recruiter,recliner,reciprocal,reappears,razors,rawdy,rashes,rarity,ranging,rajeski,raison,raisers,rainier,ragtime,rages,radar's,quinine,questscape,queller,quartermaine's,pyre,pygmalion,pushers,pusan,purview,purification,pumpin,puller,pubescent,psychiatrist's,prudes,provolone,protestants,prospero,propriety,propped,prom's,procrastinate,processors,processional,princely,preyed,preventive,pretrial,preside,premiums,preface,preachers,pounder,ports,portrays,portrayal,portent,populations,poorest,pooling,poofy,pontoon,pompeii,polymerization,polloi,policia,poacher,pluses,pleasuring,pleads,playgrounds,platitudes,platforms,plateaued,plate's,plantations,plaguing,pittance,pitcher's,pinky's,pinheads,pincushion,pimply,pimped,piggyback,pierce's,piecing,physiological,physician's,phosphate,phillipe,philipse,philby,phased,pharaohs,petyr,petitioner,peshtigo,pesaram,perspectives,persnickety,perpetrate,percolating,pepto,pensions,penne,penell,pemmican,peeks,pedaling,peacemaker,pawnshop,patting,pathologically,patchouli,pasts,pasties,passin,parlors,panda's,panache,paltrow,palamon,padlock,paddy's,paddling,oversleep,overheating,overdosed,overcharge,overcame,overblown,outset,outrageously,outfitted,orsini's,ornery,origami,orgasmic,orga,order's,opportune,ooow,oooooooooh,oohhhh,olympian,olfactory,okum,ohhhhhh,ogres,odysseus,odorless,occupations,occupancy,obscenity,obliterated,nyong,nymphomaniac,nutsack,numa,ntozake,novocain,nough,noth,nosh,norwegians,northstar,nonnie,nonissue,nodules,nightmarish,nightline,nighthawk,niggas,nicu,nicolae,nicknamed,niceties,newsman,neverland,negatively,needra,nedry,necking,navour,nauseam,nauls,narim,nanda,namath,nagged,nads,naboo,n'sync,mythological,mysticism,myslexia,mutator,mustafi,mussels,muskie,musketeer,murtaugh,murderess,murder's,murals,munching,mumsy,muley,mouseville,mosque,mosh,mortifying,morgendorffers,moola,montel,mongoloid,molten,molestered,moldings,mocarbies,mo'ss,mixers,misrell,misnomer,misheard,mishandled,miscreant,misconceptions,miniscule,minimalist,millie's,millgate,migrate,michelangelo's,mettle,metricconverter,methodology,meter's,meteors,mesozoic,menorah,mengele,mendy's,membranes,melding,meanness,mcneil's,mcgruff,mcarnold,matzoh,matted,mathematically,materialized,mated,masterpieces,mastectomy,massager,masons,marveling,marta's,marquee,marooned,marone's,marmaduke,marick,marcie's,manhandled,mangoes,manatees,managerial,man'll,maltin,maliciously,malfeasance,malahide,maketh,makeshift,makeovers,maiming,magazine's,machismo,maarten,lutheran,lumpectomy,lumbering,luigi's,luge,lubrication,lording,lorca,lookouts,loogie,loners,london's,loin,lodgings,locomotive,lobes,loathed,lissen,linus,lighthearted,ligament,lifetime's,lifer,lier,lido,lickin,lewen,levitation,lestercorp,lessee,lentils,lena's,lemur,lein,legislate,legalizing,lederhosen,lawmen,laundry's,lasskopf,lardner,landscapes,landfall,lambeau,lamagra,lagging,ladonn,lactic,lacquer,laborers,labatier,kwan's,krit,krabappel,kpxy,kooks,knobby,knickknacks,klutzy,kleynach,klendathu,kinross,kinko's,kinkaid,kind'a,kimberly's,kilometer,khruschev's,khaki,keyboards,kewl,ketch,kesher,ken's,karikos,karenina,kanamits,junshi,juno's,jumbled,jujitsu,judith's,jt's,joust,journeyed,jotted,jonathan's,jizz,jingling,jigalong,jerseys,jerries,jellybean,jellies,jeeps,jeannie's,javna,jamestown,james's,jamboree,jail's,islanders,irresistable,irene's,ious,investigation's,investigates,invaders,inundated,introductory,interviewer,interrupts,interpreting,interplanetary,internist,intercranial,inspections,inspecting,inseminated,inquisitor,inland,infused,infuriate,influx,inflating,infidelities,inference,inexpensive,industrialist,incessantly,inception,incensed,incase,incapacitate,inca,inasmuch,inaccuracies,imus,improvised,imploding,impeding,impediments,immaturity,ills,illegible,idols,iditarod,identifiable,id'n,icicles,ibuprofen,i'i'm,hymie,hydrolase,hybrids,hunsecker's,hunker,humps,humons,humidor,humdinger,humbling,humankind,huggin,huffing,households,housecleaning,hothouse,hotcakes,hosty,hootenanny,hootchie,hoosegow,honouring,honks,honeymooners,homophobic,homily,homeopathic,hoffman's,hnnn,hitchhikers,hissed,hispanics,hillnigger,hexavalent,hewwo,heston's,hershe,herodotus,hermey,hergott,heresy,henny,hennigans,henhouse,hemolytic,hells,helipad,heifer,hebrews,hebbing,heaved,heartland,heah,headlock,hatchback,harvard's,harrowing,harnessed,harding's,happy's,hannibal's,hangovers,handi,handbasket,handbags,halloween's,hall's,halfrek,halfback,hagrid,hacene,gyges,guys're,gut's,gundersons,gumption,guardia,gruntmaster,grubs,group's,grouch,grossie,grosser,groped,grins,grime,grigio,griff's,greaseball,gravesite,gratuity,graphite,granma,grandfathers,grandbaby,gradski,gracing,got's,gossips,goonie,gooble,goobers,goners,golitsyn,gofer,godsake,goddaughter,gnats,gluing,glub,global's,glares,gizmos,givers,ginza,gimmie,gimmee,georgia's,gennero,gazpacho,gazed,gato,gated,gassy,gargling,gandhiji,galvanized,gallery's,gallbladder,gabriel's,gaaah,furtive,furthering,fungal,fumigation,fudd,fucka,fronkonsteen,fromby's,frills,fresher,freezin,freewald,freeloader,franklin's,framework,frailty,fortified,forger,forestry,foreclosure,forbade,foray,football's,foolhardy,fondest,fomin,followin,follower,follicle,flue,flowering,flotation,flopping,floodgates,flogged,flog,flicked,flenders,fleabag,flanks,fixings,fixable,fistful,firewater,firestarter,firelight,fingerbang,finalizing,fillin,filipov,fido,fiderer,feminists,felling,feldberg,feign,favorably,fave,faunia,faun,fatale,fasting,farkus,fared,fallible,faithfulness,factoring,facilitated,fable,eyeful,extramarital,extracts,extinguished,exterminated,exposes,exporter,exponential,exhumed,exhume,exasperated,eviscerate,evidenced,evanston,estoy,estimating,esmerelda,esme,escapades,erosion,erie,equitable,epsom,epoxy,enticed,enthused,entendre,ensued,enhances,engulfed,engrossing,engraving,endorphins,enamel,emptive,empirical,emmys,emission,eminently,embody,embezzler,embarressed,embarrassingly,embalmed,emancipation,eludes,eling,elevation,electorate,elated,eirie,egotitis,effecting,eerily,eeew,eecom,editorials,edict,eczema,ecumenical,ecklie's,earthy,earlobes,eally,dyeing,dwells,dvds,duvet,duncans,dulcet,duckling,droves,droppin,drools,drey'auc,dreamers,dowser's,downriver,downgraded,doping,doodie,dominicans,dominating,domesticity,dollop,doesnt,doer,dobler,divulged,divisional,diversionary,distancing,dissolves,dissipated,displaying,dispensers,dispensation,disorienting,disneyworld,dismissive,dismantling,disingenuous,disheveled,disfiguring,discourse,discontinued,disallowed,dinning,dimming,diminutive,diligently,dilettante,dilation,diggity,diggers,dickensian,diaphragms,diagnoses,dewy,developer,devastatingly,determining,destabilize,desecrate,derives,deposing,denzel,denouncing,denominations,denominational,deniece,demony,delving,delt,delicates,deigned,degrassi's,degeneration,defraud,deflower,defibrillator,defiantly,deferred,defenceless,defacing,dedicating,deconstruction,decompose,deciphering,decibels,deceptively,deceptions,decapitation,debutantes,debonair,deadlier,dawdling,davic,databases,darwinism,darnit,darks,danke,danieljackson,dangled,daimler,cytoxan,cylinders,cutout,cutlery,cuss,cushing's,curveball,curiously,curfews,cummerbund,cuckoo's,crunches,crucifixion,crouched,croix,criterion,crisps,cripples,crilly,cribs,crewman,cretaceous,creepin,creeds,credenza,creak,crawly,crawlin,crawlers,crated,crasher,crackheads,coworker,counterpart,councillor,coun,couldn't've,cots,costanza's,cosgrove's,corwins,corset,correspondents,coriander,copiously,convenes,contraceptives,continuously,contingencies,contaminating,consul,constantinople,conniption,connie's,conk,conjugate,condiment,concurrently,concocting,conclave,concert's,con's,comprehending,compliant,complacency,compilation,competitiveness,commendatore,comedies,comedians,comebacks,combines,com'on,colonized,colonization,collided,collectively,collarbone,collaborating,collaborated,colitis,coldly,coiffure,coffers,coeds,codependent,cocksucking,cockney,cockles,clutched,cluett's,cloverleaf,closeted,cloistered,clinched,clicker,cleve,clergyman,cleats,clarifying,clapped,citations,cinnabar,cinco,chunnel,chumps,chucks,christof,cholinesterase,choirboy,chocolatey,chlamydia,chili's,chigliak,cheesie,cheeses,chechnya,chauvinistic,chasm,chartreuse,charnier,chapil,chapel's,chalked,chadway,cerveza,cerulean,certifiably,celsius,cellulite,celled,ceiling's,cavalry's,cavalcade,catty,caters,cataloging,casy,castrated,cassio,cashman's,cashews,carwash,cartouche,carnivore,carcinogens,carasco's,carano's,capulet,captives,captivated,capt'n,capsized,canoes,cannes,candidate's,cancellations,camshaft,campin,callate,callar,calendar's,calculators,cair,caffeinated,cadavers,cacophony,cackle,byproduct,bwana,buzzes,buyout,buttoning,busload,burglaries,burbs,bura,buona,bunions,bungalows,bundles,bunches,bullheaded,buffs,bucyk,buckling,bruschetta,browbeating,broomsticks,broody,bromly,brolin,brigadier,briefings,bridgeport,brewskies,breathalyzer,breakups,breadth,bratwurst,brania,branching,braiding,brags,braggin,bradywood,bozo's,bottomed,bottom's,bottling,botany,boston's,bossa,bordello,booo,bookshelf,boogida,bondsman,bolsheviks,bolder,boggles,boarder,boar's,bludgeoned,blowtorch,blotter,blips,blends,blemish,bleaching,blainetologists,blading,blabbermouth,bismarck,bishops,biscayne,birdseed,birdcage,bionic,biographies,biographical,bimmel,biloxi,biggly,bianchinni,bette's,betadine,berg's,berenson,belus,belt's,belly's,belloq,bella's,belfast,behavior's,begets,befitting,beethoven's,beepers,beelzebub,beefed,bedroom's,bedrock,bedridden,bedevere,beckons,beckett's,beauty's,beaded,baubles,bauble,battlestar,battleground,battle's,bathrobes,basketballs,basements,barroom,barnacle,barkin,barked,barium,baretta,bangles,bangler,banality,bambang,baltar,ballplayers,baio,bahrain,bagman,baffles,backstroke,backroom,bachelor's,babysat,babylonian,baboons,aviv,avez,averse,availability,augmentation,auditory,auditor,audiotape,auctioneer,atten,attained,attackers,atcha,astonishment,asshole's,assembler,arugula,arsonist's,arroz,arigato,arif,ardent,archaic,approximation,approving,appointing,apartheid,antihistamines,antarctica,annoyances,annals,annabelle's,angrily,angelou,angelo's,anesthesiology,android,anatomically,anarchists,analyse,anachronism,amiable,amex,ambivalent,amassed,amaretto,alumnus,alternating,alternates,alteration,aloft,alluding,allen's,allahu,alight,alfred's,alfie,airlift,aimin,ailment,aground,agile,ageing,afterglow,africans,affronte,affectionately,aerobic,adviser,advil,adventist,advancements,adrenals,admiral's,administrators,adjutant,adherence,adequately,additives,additions,adapting,adaptable,actualization,activating,acrost,ached,accursed,accoutrements,absconded,aboveboard,abou,abetted,abbot's,abbey's,aargh,aaaahh,zuzu's,zuwicky,zolda,zits,ziploc,zakamatak,yutz,yumm,youve,yolk,yippie,yields,yiddish,yesterdays,yella,yearns,yearnings,yearned,yawning,yalta,yahtzee,yacht's,y'mean,y'are,xand,wuthering,wreaks,woul,worsened,worrisome,workstation,workiiing,worcestershire,woop,wooooooo,wooded,wonky,womanizing,wolodarsky,wnkw,wnat,wiwith,withdraws,wishy,wisht,wipers,wiper,winos,winery,windthorne,windsurfing,windermere,wiggles,wiggled,wiggen,whys,whwhat,whuh,whos,whore's,whodunit,whoaaa,whittling,whitesnake,whirling,whereof,wheezing,wheeze,whatley's,whatd'ya,whataya,whammo,whackin,wets,westbound,wellll,wellesley,welch's,weirdo's,weightless,weevil,wedgies,webbing,weasly,weapon's,wean,wayside,waxes,wavelengths,waturi,washy,washrooms,warton's,wandell,wakeup,waitaminute,waddya,wabash,waaaah,vornac,voir,voicing,vocational,vocalist,vixens,vishnoor,viscount,virulent,virtuoso,vindictiveness,vinceres,vince's,villier,viii,vigeous,viennese,viceroy,vestigial,vernacular,venza's,ventilate,vented,venereal,vell,vegetative,veering,veered,veddy,vaslova,valosky,vailsburg,vaginas,vagas,vacation's,uuml,urethra,upstaged,uploading,upgrades,unwrapping,unwieldy,untenable,untapped,unsatisfied,unsatisfactory,unquenchable,unnerved,unmentionable,unlovable,unknowns,universes,uninformed,unimpressed,unhappily,unguarded,unexplored,underpass,undergarment,underdeveloped,undeniably,uncompromising,unclench,unclaimed,uncharacteristically,unbuttoned,unblemished,unas,umpa,ululd,uhhhm,tweeze,tutsami,tusk,tushy,tuscarora,turkle,turghan,turbulent,turbinium,tuffy,tubers,tsun,trucoat,troxa,trou,tropicana,triquetra,tripled,trimmers,triceps,tribeca,trespassed,traya,travellers,traumatizing,transvestites,transatlantic,tran's,trainors,tradin,trackers,townies,tourelles,toughness,toucha,totals,totalled,tossin,tortious,topshop,topes,tonics,tongs,tomsk,tomorrows,toiling,toddle,tobs,tizzy,tiramisu,tippers,timmi,timbre,thwap,thusly,ththe,thruway,thrusts,throwers,throwed,throughway,thrice,thomas's,thickening,thia,thermonuclear,therapy's,thelwall,thataway,th's,textile,texans,terry's,terrifically,tenets,tendons,tendon,telescopic,teleportation,telepathically,telekinetic,teetering,teaspoons,teamsters,taunts,tatoo,tarantulas,tapas,tanzania,tanned,tank's,tangling,tangerine,tamales,tallied,tailors,tai's,tahitian,tag's,tactful,tackles,tachy,tablespoon,tableau,syrah,syne,synchronicity,synch,synaptic,synapses,swooning,switchman,swimsuits,swimmer's,sweltering,swelling's,sweetly,sweeper,suvolte,suss,suslov,surname,surfed,supremacy,supposition,suppertime,supervillains,superman's,superfluous,superego,sunspots,sunnydale's,sunny's,sunning,sunless,sundress,sump,suki,suffolk,sue's,suckah,succotash,substation,subscriptions,submarines,sublevel,subbasement,styled,studious,studio's,striping,stresses,strenuously,streamlined,strains,straights,stony,stonewalled,stonehenge,stomper,stipulates,stinging,stimulated,stillness,stilettos,stewards,stevesy,steno,sten,stemmed,steenwyck,statesmen,statehood,stargates,standstill,stammering,staedert,squiggly,squiggle,squashing,squaring,spurred,sprints,spreadsheet,spramp,spotters,sporto,spooking,sponsorship,splendido,spittin,spirulina,spiky,speculations,spectral,spate,spartacus,spans,spacerun,sown,southbound,sorr,sorcery,soonest,sono,sondheim,something'll,someth,somepin,someone'll,solicitor,sofas,sodomy,sobs,soberly,sobered,soared,soapy,snowmen,snowbank,snowballing,snorkel,snivelling,sniffling,snakeskin,snagging,smush,smooter,smidgen,smackers,smackdown,slumlord,slugging,slossum,slimmer,slighted,sleepwalk,sleazeball,skokie,skirmishes,skipper's,skeptic,sitka,sitarides,sistah,sipped,sindell,simpletons,simp,simony,simba's,silkwood,silks,silken,silicone,sightless,sideboard,shuttles,shrugging,shrouds,showy,shoveled,shouldn'ta,shoplifters,shitstorm,shipyard,shielded,sheldon's,sheeny,shaven,shapetype,shankar,shaming,shallows,shale,shading,shackle,shabbily,shabbas,severus,settlements,seppuku,senility,semite,semiautomatic,semester's,selznick,secretarial,sebacio,sear,seamless,scuzzy,scummy,scud,scrutinized,scrunchie,scriptures,scribbled,scouted,scotches,scolded,scissor,schooner,schmidt's,schlub,scavenging,scarin,scarfing,scarecrow's,scant,scallions,scald,scabby,say's,savour,savored,sarcoidosis,sandbar,saluted,salted,salish,saith,sailboats,sagittarius,sagan,safeguards,sacre,saccharine,sacamano,sabe,rushdie,rumpled,rumba,rulebook,rubbers,roughage,rotterdam,roto,rotisserie,rosebuds,rootie,roosters,roosevelt's,rooney's,roofy,roofie,romanticize,roma's,rolodex,rolf's,roland's,rodney's,robotic,robin's,rittle,ristorante,rippin,rioting,rinsing,ringin,rincess,rickety,rewritten,revising,reveling,rety,retreats,retest,retaliating,resumed,restructuring,restrict,restorative,reston,restaurateur,residences,reshoots,resetting,resentments,rescuers,rerouted,reprogramming,reprisals,reprisal,repossess,repartee,renzo,renfield,remore,remitting,remeber,reliability,relaxants,rejuvenate,rejections,rehu,regularity,registrar's,regionals,regimes,regenerated,regency,refocus,referrals,reeno,reelected,redevelopment,recycles,recrimination,recombinant,reclining,recanting,recalling,reattach,reassigning,realises,reactors,reactionary,rbis,razor's,razgul,raved,rattlesnakes,rattles,rashly,raquetball,rappers,rapido,ransack,rankings,rajah,raisinettes,raheem,radisson,radishes,radically,radiance,rabbi's,raban,quoth,qumari,quints,quilts,quilting,quien,queue,quarreled,qualifying,pygmy,purty,puritans,purblind,puppy's,punctuation,punchbowl,puget,publically,psychotics,psychopaths,psychoanalyze,pruning,provasik,protruding,protracted,protons,protections,protectin,prospector,prosecutor's,propping,proportioned,prophylactic,propelled,proofed,prompting,prompter,professed,procreate,proclivities,prioritizing,prinze,princess's,pricked,press'll,presets,prescribes,preocupe,prejudicial,prefex,preconceived,precipice,preamble,pram,pralines,pragmatist,powering,powerbar,pottie,pottersville,potsie,potholes,potency,posses,posner's,posies,portkey,porterhouse,pornographers,poring,poppycock,poppet,poppers,poopsie,pomponi,pokin,poitier,poes,podiatry,plush,pleeze,pleadings,playbook,platelets,plane'arium,placebos,place'll,pj's,pixels,pitted,pistachios,pisa,pirated,pirate's,pinochle,pineapples,pinafore,pimples,piggly,piggies,pie's,piddling,picon,pickpockets,picchu,physiologically,physic,photo's,phobic,philosophies,philosophers,philly's,philandering,phenomenally,pheasants,phasing,phantoms,pewter,petticoat,petronis,petitioning,perturbed,perth,persists,persians,perpetuating,permutat,perishable,periphery,perimeters,perfumed,percocet,per'sus,pepperjack,pensioners,penalize,pelting,pellet,peignoir,pedicures,pedestrians,peckers,pecans,payback's,pay's,pawning,paulsson,pattycake,patrolmen,patrolled,patois,pathos,pasted,passer,partnerships,parp,parishioners,parishioner,parcheesi,parachuting,pappa,paperclip,papayas,paolo's,pantheon,pantaloons,panhandle,pampers,palpitations,paler,palantine,paintballing,pago,owow,overtired,overstress,oversensitive,overnights,overexcited,overanxious,overachiever,outwitted,outvoted,outnumber,outlived,outlined,outlast,outlander,outfield,out've,ortolani's,orphey,ornate,ornamental,orienteering,orchestrating,orator,oppressive,operator's,openers,opec,ooky,oliver's,olde,okies,okee,ohhhhhhhhh,ohhhhhhhh,ogling,offline,offbeat,oceanographic,obsessively,obeyed,oaths,o'leary's,o'hana,o'bannon,o'bannion,numpce,nummy,nuked,nuff,nuances,nourishing,noticeably,notably,nosedive,northeastern,norbu,nomlies,nomine,nomads,noge,nixed,niro,nihilist,nightshift,newmeat,nevis,nemo's,neighborhood's,neglectful,neediness,needin,necromancer,neck's,ncic,nathaniel's,nashua,naphthalene,nanotechnology,nanocytes,nanite,naivete,nacho,n'yeah,mystifying,myhnegon,mutating,muskrat,musing,museum's,muppets,mumbles,mulled,muggy,muerto,muckraker,muchachos,mris,move's,mourners,mountainside,moulin,mould,motherless,motherfuck,mosquitos,morphed,mopped,moodoo,montage,monsignor,moncho,monarchs,mollem,moisturiser,moil,mohicans,moderator,mocks,mobs,mizz,mites,mistresses,misspent,misinterpretation,mishka,miscarry,minuses,minotaur,minoan,mindee,mimicking,millisecond,milked,militants,migration,mightn't,mightier,mierzwiak,midwives,micronesia,microchips,microbes,michele's,mhmm,mezzanine,meyerling,meticulously,meteorite,metaphorical,mesmerizing,mershaw,meir,meg's,meecrob,medicate,medea,meddled,mckinnons,mcgewan,mcdunnough,mcats,mbien,maytag,mayors,matzah,matriarch,matic,mathematicians,masturbated,masselin,marxist,martyrs,martini's,martialed,marten's,marlboros,marksmanship,marishka,marion's,marinate,marge's,marchin,manifestations,manicured,mandela,mamma's,mame,malnourished,malk,malign,majorek,maidens,mahoney's,magnon,magnificently,maestro's,macking,machiavellian,macdougal,macchiato,macaws,macanaw,m'self,lynx,lynn's,lyman's,lydells,lusts,lures,luna's,ludwig's,lucite,lubricants,louise's,lopper,lopped,loneliest,lonelier,lomez,lojack,localized,locale,loath,lloyd's,literate,liquidated,liquefy,lippy,linguistic,limps,lillian's,likin,lightness,liesl,liebchen,licious,libris,libation,lhamo,lewis's,leveraged,leticia's,leotards,leopards,leonid,leonardo's,lemmings,leland's,legitimacy,leanin,laxatives,lavished,latka,later's,larval,lanyard,lans,lanky,landscaping,landmines,lameness,lakeshore,laddies,lackluster,lacerated,labored,laboratories,l'amour,kyrgyzstan,kreskin,krazy,kovitch,kournikova,kootchy,konoss,know's,knknow,knickety,knackety,kmart,klicks,kiwanis,kitty's,kitties,kites,kissable,kirby's,kingdoms,kindergartners,kimota,kimble's,kilter,kidnet,kidman,kid'll,kicky,kickbacks,kickback,kickass,khrushchev,kholokov,kewpie,kent's,keno,kendo,keller's,kcdm,katrina's,katra,kareoke,kaia,kafelnikov,kabob,ka's,junjun,jumba,julep,jordie,jondy,jolson,jinnah,jeweler's,jerkin,jenoff,jefferson's,jaye's,jawbone,janitorial,janiro,janie's,iron's,ipecac,invigorated,inverted,intruded,intros,intravenously,interruptus,interrogations,interracial,interpretive,internment,intermediate,intermediary,interject,interfacing,interestin,insuring,instilled,instantaneous,insistence,insensitivity,inscrutable,inroads,innards,inlaid,injector,initiatives,inhe,ingratitude,infuriates,infra,informational,infliction,infighting,induction,indonesian,indochina,indistinguishable,indicators,indian's,indelicate,incubators,incrimination,increments,inconveniencing,inconsolable,incite,incestuous,incas,incarnation,incarcerate,inbreeding,inaccessible,impudence,impressionists,implemented,impeached,impassioned,impacts,imipenem,idling,idiosyncrasies,icicle,icebreaker,icebergs,i'se,hyundai,hypotensive,hydrochloride,huuh,hushed,humus,humph,hummm,hulking,hubcaps,hubald,http,howya,howbout,how'll,houseguests,housebroken,hotwire,hotspots,hotheaded,horticulture,horrace,horde,horace's,hopsfield,honto,honkin,honeymoons,homophobia,homewrecker,hombres,hollow's,hollers,hollerin,hokkaido,hohh,hogwarts,hoedown,hoboes,hobbling,hobble,hoarse,hinky,himmler,hillcrest,hijacking,highlighters,hiccup,hibernation,hexes,heru'ur,hernias,herding,heppleman,henderson's,hell're,heine's,heighten,heheheheheh,heheheh,hedging,heckling,heckled,heavyset,heatshield,heathens,heartthrob,headpiece,headliner,he'p,hazelnut,hazards,hayseed,haveo,hauls,hattie's,hathor's,hasten,harriers,harridan,harpoons,harlin's,hardens,harcesis,harbouring,hangouts,hangman,handheld,halkein,haleh,halberstam,hairpin,hairnet,hairdressers,hacky,haah,haaaa,h'yah,gyms,gusta,gushy,gusher,gurgling,gunnery,guilted,guilt's,gruel,grudging,grrrrrr,grouse,grossing,grosses,groomsmen,griping,gretchen's,gregorian,gray's,gravest,gratified,grated,graphs,grandad,goulash,goopy,goonies,goona,goodman's,goodly,goldwater,godliness,godawful,godamn,gobs,gob's,glycerin,glutes,glowy,glop,globetrotters,glimpsed,glenville,glaucoma,girlscout,giraffes,gimp,gilbey,gil's,gigglepuss,ghora,gestating,geologists,geographically,gelato,gekko's,geishas,geek's,gearshift,gear's,gayness,gasped,gaslighting,garretts,garba,gams,gags,gablyczyck,g'head,fungi,fumigating,fumbling,fulton's,fudged,fuckwad,fuck're,fuchsia,fruition,freud's,fretting,freshest,frenchies,freezers,fredrica,fraziers,francesca's,fraidy,foxholes,fourty,fossilized,forsake,formulate,forfeits,foreword,foreclosed,foreal,foraging,footsies,focussed,focal,florists,flopped,floorshow,floorboard,flinching,flecks,flavours,flaubert,flatware,flatulence,flatlined,flashdance,flail,flagging,fizzle,fiver,fitzy,fishsticks,finster,finetti,finelli,finagle,filko,filipino,figurines,figurative,fifi,fieldstone,fibber,fiance's,feuds,feta,ferrini,female's,feedin,fedora,fect,feasting,favore,fathering,farrouhk,farmin,far's,fanny's,fajita,fairytale,fairservice,fairgrounds,fads,factoid,facet,facedown,fabled,eyeballin,extortionist,exquisitely,exporting,explicitly,expenditures,expedited,expands,exorcise,existentialist,exhaustive,execs,exculpatory,excommunicated,exacerbate,everthing,eventuality,evander,eustace,euphoric,euphemisms,eton,esto,estimation,estamos,establishes,erred,environmentalist,entrepreneurial,entitle,enquiries,enormity,engages,enfants,enen,endive,end's,encyclopedias,emulating,emts,employee's,emphasized,embossed,embittered,embassies,eliot,elicit,electrolyte,ejection,effortless,effectiveness,edvard,educators,edmonton's,ecuador,ectopic,ecirc,easely,earphones,earmarks,earmarked,earl's,dysentery,dwindling,dwight's,dweller,dusky,durslar,durned,dunois,dunking,dunked,dumdum,dullard,dudleys,duce,druthers,druggist,drug's,drossos,drosophila,drooled,driveways,drippy,dreamless,drawstring,drang,drainpipe,dragoons,dozing,down's,dour,dougie's,dotes,dorsal,dorkface,doorknobs,doohickey,donnell's,donnatella,doncha,don's,dominates,domicile,dokos,dobermans,djez,dizzying,divola,dividends,ditsy,distaste,disservice,disregarded,dispensed,dismay,dislodged,dislodge,disinherit,disinformation,discrete,discounting,disciplines,disapproved,dirtball,dinka,dimly,dilute,dilucca's,digesting,diello,diddling,dictatorships,dictators,diagonal,diagnostician,devours,devilishly,detract,detoxing,detours,detente,destructs,desecrated,descends,derris,deplore,deplete,depicts,depiction,depicted,denver's,denounce,demure,demolitions,demean,deluge,dell's,delish,deliberation,delbruck,delaford,deities,degaulle,deftly,deft,deformity,deflate,definatly,defense's,defector,deducted,decrypted,decontamination,decker's,decapitate,decanter,deadline's,dardis,danger's,dampener,damme,daddy'll,dabbling,dabbled,d'etre,d'argent,d'alene,d'agnasti,czechs,czechoslovakian,cyrillic,cymbal,cyberdyne,cutoffs,cuticle,cut's,curvaceous,curiousity,curfew's,culturally,cued,cubby,cruised,crucible,crowing,crowed,croutons,cropped,croaker,cristobel's,criminy,crested,crescentis,cred,cream's,crashers,crapola,cranwell,coverin,cousteau,courtrooms,counterattack,countenance,counselor's,cottages,cosmically,cosign,cosa,corroboration,corresponds,correspond,coroners,coro,cornflakes,corbett's,copy's,copperpot,copperhead,copacetic,coordsize,convulsing,contradicted,contract's,continuation,consults,consultations,constraints,conjures,congenial,confluence,conferring,confederation,condominium,concourse,concealer,compulsory,complexities,comparatively,compactor,commodities,commercialism,colleague's,collaborator,cokey,coiled,cognizant,cofell's,cobweb,co's,cnbc,clyde's,clunkers,clumsily,clucking,cloves,cloven,cloths,clothe,clop,clods,clocking,clings,climbers,clef,clearances,clavicle,claudia's,classless,clashing,clanking,clanging,clamping,civvies,citywide,citing,circulatory,circuited,circ,chung's,chronisters,chromic,choppy,choos,chongo,chloroformed,chilton's,chillun,chil,chicky,cheetos,cheesed,chatterbox,charlies,chaperoned,channukah,chamberlain's,chairman's,chaim,cessation,cerebellum,centred,centerpieces,centerfold,cellars,ceecee,ccedil,cavorting,cavemen,cavaliers,cauterized,caustic,cauldwell,catting,cathy's,caterine,castor's,cassiopeia,cascade's,carves,cartwheel,cartridges,carpeted,carob,carlsbad,caressing,carelessly,careening,carcinoma,capricious,capitalistic,capillaries,capes,candle's,candidly,canaan,camaraderie,calumet,callously,calligraphy,calfskin,cake's,caddies,cabinet's,buzzers,buttholes,butler's,busywork,busses,burps,burgomeister,buoy,bunny's,bunkhouse,bungchow,bulkhead,builders,bugler,buffets,buffed,buckaroo's,brutish,brusque,browser,bronchitis,bromden,brolly,brody's,broached,brewskis,brewski,brewin,brewers,brean,breadwinner,brana,brackets,bozz,bountiful,bounder,bouncin,bosoms,borgnine,bopping,bootlegs,booing,bons,boneyard,bombosity,bolting,bolivia,boilerplate,boba,bluey,blowback,blouses,bloodsuckers,bloodstained,blonde's,bloat,bleeth,blazed,blaine's,blackhawk,blackface,blackest,blackened,blacken,blackballed,blabs,blabbering,birdbrain,bipartisanship,biodegradable,binghamton,biltmore,billiards,bilked,big'uns,bidwell's,bidet,bessie's,besotted,beset,berth,bernheim,benson's,beni,benegas,bendiga,belushi,beltway,bellboys,belittling,belinda's,behinds,behemoth,begone,beeline,beehive,bedsheets,beckoning,beaute,beaudine,beastly,beachfront,be's,bauk,bathes,batak,bastion,baser,baseballs,barker's,barber's,barbella,bans,bankrolling,bangladesh,bandaged,bamba,bally's,bagpipe,bagger,baerly,backlog,backin,babying,azkaban,ayatollah,axes,awwwww,awakens,aviary,avery's,autonomic,authorizes,austero,aunty,augustine's,attics,atreus,astronomers,astounded,astonish,assertion,asserting,assailants,asha's,artemus,arses,arousal,armin,arintero,argon's,arduous,archers,archdiocese,archaeology,arbitrarily,ararat,appropriated,appraiser,applicable,apathetic,anybody'd,anxieties,anwar's,anticlimactic,antar,ankle's,anima,anglos,angleman,anesthetist,androscoggin,andromeda,andover,andolini,andale,anan,amway,amuck,amphibian,amniocentesis,amnesiac,ammonium,americano,amara,alway,alvah,alum,altruism,alternapalooza,alphabetize,alpaca,almanac,ally's,allus,alluded,allocation,alliances,allergist,alleges,alexandros,alec's,alaikum,alabam,akimbo,airy,ahab's,agoraphobia,agides,aggrhh,agatha's,aftertaste,affiliations,aegis,adoptions,adjuster,addictions,adamantium,acumen,activator,activates,acrylic,accomplishes,acclaimed,absorbs,aberrant,abbu,aarp,aaaaargh,aaaaaaaaaaaaa,a'ight,zucchini,zoos,zookeeper,zirconia,zippers,zequiel,zephyr's,zellary,zeitgeist,zanuck,zambia,zagat,ylang,yielded,yes'm,yenta,yegg,yecchh,yecch,yayo,yawp,yawns,yankin,yahdah,yaaah,y'got,xeroxed,wwooww,wristwatch,wrangled,wouldst,worthiness,wort,worshiping,worsen,wormy,wormtail,wormholes,woosh,woodworking,wonka,womens,wolverines,wollsten,wolfing,woefully,wobbling,witter's,wisp,wiry,wire's,wintry,wingding,windstorm,windowtext,wiluna,wilting,wilted,willick,willenholly,wildflowers,wildebeest,wilco,wiggum,wields,widened,whyyy,whoppers,whoaa,whizzing,whizz,whitest,whitefish,whistled,whist,whinny,whereupon,whereby,wheelies,wheaties,whazzup,whatwhatwhaaat,whato,whatdya,what'dya,whar,whacks,wexler's,wewell,wewe,wetsuit,wetland,westport,welluh,weight's,weeps,webpage,waylander,wavin,watercolors,wassail,wasnt,warships,warns,warneford,warbucks,waltons,wallbanger,waiving,waitwait,vowing,voucher,vornoff,vork,vorhees,voldemort,vivre,vittles,vishnu,vips,vindaloo,videogames,victors,vicky's,vichyssoise,vicarious,vet's,vesuvius,verve,verguenza,venturing,ventura's,venezuelan,ven't,velveteen,velour,velociraptor,vegetation,vaudeville,vastness,vasectomies,vapors,vanderhof,valmont,validates,valiantly,valerian,vacuums,vaccines,uzbekistan,usurp,usernum,us'll,urinals,unyielding,unwillingness,unvarnished,unturned,untouchables,untangled,unsecured,unscramble,unreturned,unremarkable,unregistered,unpublished,unpretentious,unopposed,unnerstand,unmade,unlicensed,unites,union's,uninhabited,unimpeachable,unilateral,unicef,unfolded,unfashionable,undisturbed,underwriting,underwrite,underlining,underling,underestimates,underappreciated,undamaged,uncouth,uncork,uncontested,uncommonly,unclog,uncircumcised,unchallenged,uncas,unbuttoning,unapproved,unamerican,unafraid,umpteen,umhmm,uhwhy,uhmm,ughuh,ughh,ufo's,typewriters,twitches,twitched,twirly,twinkling,twink,twinges,twiddling,twiddle,tutored,tutelage,turners,turnabout,ture,tunisian,tumultuous,tumour,tumblin,tryed,truckin,trubshaw's,trowel,trousseau,trivialize,trifles,tribianni,trib,triangulation,trenchcoat,trembled,traumatize,transplanted,translations,transitory,transients,transfuse,transforms,transcribing,transcend,tranq,trampy,traipsed,trainin,trail's,trafalgar,trachea,traceable,touristy,toughie,totality,totaling,toscanini,tortola,tortilla,tories,toreador,tooo,tonka,tommorrow,tollbooth,tollans,toidy,togs,togas,tofurkey,toddling,toddies,tobruk,toasties,toadstool,to've,tive,tingles,timin,timey,timetables,tightest,tide's,tibetans,thunderstorms,thuggee,thrusting,thrombus,throes,throated,thrifty,thoroughbred,thornharts,thinnest,thicket,thetas,thesulac,tethered,testimonial,testaburger,tersenadine,terrif,teresa's,terdlington,tepui,tenured,tentacle,temping,temperance,temp's,teller's,televisions,telefono,tele,teddies,tector,taxidermy,taxi's,taxation,tastebuds,tasker's,tartlets,tartabull,tard,tar'd,tantamount,tans,tangy,tangles,tamer,talmud,taiwan's,tabula,tabletops,tabithia,tabernacle,szechwan,syrian,synthedyne,synopsis,synonyms,swaps,swahili,svenjolly,svengali,suvs,sush,survivalists,surmise,surfboards,surefire,suprise,supremacists,suppositories,supervisors,superstore,supermen,supercop,supercilious,suntac,sunburned,summercliff,sullied,suite's,sugared,sufficiency,suerte,suckle,sucker's,sucka,succumbing,subtleties,substantiated,subsidiaries,subsides,subliminal,subhuman,stst,strowman,stroked,stroganoff,strikers,strengthening,streetlight,straying,strainer,straighter,straightener,storytelling,stoplight,stockade,stirrups,stink's,sting's,stimulates,stifler's,stewing,stetson's,stereotyping,ster,stepmommy,stephano,steeped,statesman,stashing,starshine,stand's,stamping,stamford,stairwells,stabilization,squatsie,squandering,squalid,squabbling,squab,sprinkling,spring's,spreader,spongy,spongebob,spokeswoman,spokesmen,splintered,spittle,spitter,spiced,spews,spendin,spect,speckled,spearchucker,spatulas,sparse,sparking,spares,spaceboy,soybeans,southtown,southside,southport,southland,soused,sotheby's,soshi,sorter,sorrowful,sorceress,sooth,songwriters,some'in,solstice,soliloquy,sods,sodomized,sode,sociologist,sobriki,soaping,snows,snowcone,snowcat,snitching,snitched,sneering,snausages,snaking,smoothed,smoochies,smolensk,smarten,smallish,slushy,slurring,sluman,slobber,slithers,slippin,sleuthing,sleeveless,slade's,skinner's,skinless,skillfully,sketchbook,skagnetti,sista,sioux,sinning,sinjin,singularly,sinewy,sinclair's,simultaneous,silverlake,silva's,siguto,signorina,signature's,signalling,sieve,sids,sidearms,shyster,shying,shunning,shtud,shrooms,shrieks,shorting,shortbread,shopkeepers,shmuck,shmancy,shizzit,shitheads,shitfaced,shitbag,shipmates,shiftless,sherpa,shelving,shelley's,sheik,shedlow,shecky,sheath,shavings,shatters,sharifa,shampoos,shallots,shafter,sha'nauc,sextant,settlers,setter,seti,serviceable,serrated,serbian,sequentially,sepsis,senores,sendin,semis,semanski,seller's,selflessly,selects,selectively,seinfelds,seers,seer's,seeps,see's,seductress,sedimentary,sediment,second's,secaucus,seater,seashore,sealant,seaborn's,scuttling,scusa,sculpting,scrunched,scrimmage,screenwriter,scotsman,scorer,sclerosis,scissorhands,schreber,scholastic,schmancy,schlong,scathing,scandinavia,scamps,scalloped,savoir,savagery,sasha's,sarong,sarnia,santangel,samool,samba,salons,sallow,salino,safecracker,sadism,saddles,sacrilegious,sabrini,sabath,s'aright,ruttheimer,russia's,rudest,rubbery,rousting,rotarian,roslin,rosey,rosa's,roomed,romari,romanticism,romanica,rolltop,rolfski,rod's,rockland,rockettes,roared,riverfront,rinpoche,ringleader,rims,riker's,riffing,ricans,ribcage,riana's,rhythmic,rhah,rewired,retroactive,retrial,reting,reticulum,resuscitated,resuming,restricting,restorations,restock,resilience,reservoirs,resembled,resale,requisitioned,reprogrammed,reproducing,repressive,replicant,repentant,repellant,repays,repainting,reorganization,renounced,renegotiating,rendez,renamed,reminiscent,remem,remade,relived,relinquishes,reliant,relearn,relaxant,rekindling,rehydrate,regulatory,regiments,regan's,refueled,refrigeration,refreshingly,reflector,refine,refilling,reexamine,reeseman,redness,redirected,redeemable,redder,redcoats,rectangles,recoup,reconstituted,reciprocated,recipients,recessed,recalls,rebounded,reassessing,realy,reality's,realisation,realer,reachin,re'kali,rawlston,ravages,rattlers,rasa,raps,rappaports,ramoray,ramming,ramadan,raindrops,rahesh,radioactivity,radials,racists,racin,rabartu,quotas,quintus,quiches,ques,queries,quench,quel,quarrels,quarreling,quaintly,quagmire,quadrants,pylon,putumayo,put'em,purifier,purified,pureed,punitis,pullout,pukin,pudgy,puddings,puckering,puccini,pterodactyl,psychodrama,pseudonym,psats,proximal,providers,protestations,protectee,prospered,prosaic,propositioned,prolific,progressively,proficiency,professions,prodigious,proclivity,probed,probabilities,pro's,prison's,printouts,principally,prig,prevision,prevailing,presumptive,pressers,preset,presentations,preposition,preparatory,preliminaries,preempt,preemie,predetermined,preconceptions,precipitate,prancan,powerpuff,powerfully,potties,potters,potpie,poseur,portraying,portico,porthole,portfolios,poops,pooping,pone,pomp,pomade,polyps,polymerized,politic,politeness,polisher,polack,pokers,pocketknife,poatia,plebeian,playgroup,platonically,plato's,platitude,platelet,plastering,plasmapheresis,plaques,plaids,placemats,place's,pizzazz,piracy,pipelines,pip's,pintauro,pinstripes,pinpoints,pinkner,pincer,pimento,pillaged,pileup,pilates,pigment,pigmen,pieter,pieeee,picturesque,piano's,phrasing,phrased,photojournalist,photocopies,phosphorus,phonograph,phoebes,phoe,philistines,philippine,philanderer,pheromone,phasers,pharaoh's,pfff,pfeffernuesse,petrov,petitions,peterman's,peso,pervs,perspire,personify,perservere,perplexed,perpetrating,perp's,perkiness,perjurer,periodontist,perfunctory,performa,perdido,percodan,penzance,pentameter,pentagon's,pentacle,pensive,pensione,pennybaker,pennbrooke,penhall,pengin,penetti,penetrates,pegs,pegnoir,peeve,peephole,pectorals,peckin,peaky,peaksville,payout,paxcow,paused,pauline's,patted,pasteur,passe,parochial,parkland,parkishoff,parkers,pardoning,paraplegic,paraphrasing,parapet,paperers,papered,panoramic,pangs,paneling,pander,pandemonium,pamela's,palooza,palmed,palmdale,palisades,palestinian,paleolithic,palatable,pakistanis,pageants,packaged,pacify,pacified,oyes,owwwww,overthrown,overt,oversexed,overriding,overrides,overpaying,overdrawn,overcompensate,overcomes,overcharged,outtakes,outmaneuver,outlying,outlining,outfoxed,ousted,oust,ouse,ould,oughtn't,ough,othe,ostentatious,oshun,oscillation,orthopedist,organizational,organization's,orca,orbits,or'derves,opting,ophthalmologist,operatic,operagirl,oozes,oooooooh,only's,onesie,omnis,omelets,oktoberfest,okeydoke,ofthe,ofher,obstetrics,obstetrical,obeys,obeah,o'rourke,o'reily's,o'henry,nyquil,nyanyanyanyah,nuttin,nutsy,nutrients,nutball,nurhachi,numbskull,nullifies,nullification,nucking,nubbin,ntnt,nourished,notoriety,northland,nonspecific,nonfiction,noing,noinch,nohoho,nobler,nitwits,nitric,nips,nibs,nibbles,newton's,newsprint,newspaperman,newspaper's,newscaster,never's,neuter,neuropathy,netherworld,nests,nerf,neee,neediest,neath,navasky,naturalization,nat's,narcissists,napped,nando,nags,nafta,myocardial,mylie's,mykonos,mutilating,mutherfucker,mutha,mutations,mutates,mutate,musn't,muskets,murray's,murchy,mulwray's,multitasking,muldoon's,mujeeb,muerte,mudslinging,muckraking,mrsa,mown,mousie,mousetrap,mourns,mournful,motivating,motherland,motherf,mostro,mosaic,morphing,morphate,mormons,moralistic,moored,moochy,mooching,monotonous,monorail,monopolize,monogram,monocle,molehill,molar,moland,mofet,modestly,mockup,moca,mobilizing,mitzvahs,mitre,mistreating,misstep,misrepresentation,misjudge,misinformation,miserables,misdirected,miscarriages,minute's,miniskirt,minimizing,mindwarped,minced,milquetoast,millimeters,miguelito,migrating,mightily,midsummer,midstream,midriff,mideast,midas,microbe,metropolis,methuselah,mesdames,mescal,mercury's,menudo,menu's,mentors,men'll,memorial's,memma,melvins,melanie's,megaton,megara,megalomaniac,meeee,medulla,medivac,mediate,meaninglessness,mcnuggets,mccarthyism,maypole,may've,mauve,maturing,matter's,mateys,mate's,mastering,masher,marxism,martimmy's,marshack,marseille,markles,marketed,marketable,mansiere,manservant,manse,manhandling,manco's,manana,maman,malnutrition,mallomars,malkovich's,malcontent,malaise,makeup's,majesties,mainsail,mailmen,mahandra,magnolias,magnified,magev,maelstrom,madcap,mack's,machu,macfarlane's,macado,ma'm,m'boy,m'appelle,lying's,lustrous,lureen,lunges,lumped,lumberyard,lulled,luego,lucks,lubricated,loveseat,loused,lounger,loski,lorre,loora,looong,loonies,lonnegan's,lola's,loire,loincloth,logistical,lofts,lodges,lodgers,lobbing,loaner,livered,lithuania,liqueur,linkage,ling's,lillienfield's,ligourin,lighter's,lifesaving,lifeguards,lifeblood,library's,liberte,liaisons,liabilities,let'em,lesbianism,lenny's,lennart,lence,lemonlyman,legz,legitimize,legalized,legalization,leadin,lazars,lazarro,layoffs,lawyering,lawson's,lawndale's,laugher,laudanum,latte's,latrines,lations,laters,lastly,lapels,lansing's,lan's,lakefront,lait,lahit,lafortunata,lachrymose,laborer,l'italien,l'il,kwaini,kuzmich,kuato's,kruczynski,kramerica,krakatoa,kowtow,kovinsky,koufax,korsekov,kopek,knoxville,knowakowski,knievel,knacks,klux,klein's,kiran,kiowas,kinshasa,kinkle's,kincaid's,killington,kidnapper's,kickoff,kickball,khan's,keyworth,keymaster,kevie,keveral,kenyons,keggers,keepsakes,kechner,keaty,kavorka,katmandu,katan's,karajan,kamerev,kamal's,kaggs,juvi,jurisdictional,jujyfruit,judeo,jostled,joni's,jonestown,jokey,joists,joint's,johnnie's,jocko,jimmied,jiggled,jig's,jests,jessy,jenzen,jensen's,jenko,jellyman,jeet,jedediah,jealitosis,jaya's,jaunty,jarmel,jankle,jagoff,jagielski,jacky,jackrabbits,jabbing,jabberjaw,izzat,iuml,isolating,irreverent,irresponsibly,irrepressible,irregularity,irredeemable,investigator's,inuvik,intuitions,intubated,introspective,intrinsically,intra,intimates,interval,intersections,interred,interned,interminable,interloper,intercostal,interchange,integer,intangible,instyle,instrumentation,instigate,instantaneously,innumerable,inns,injustices,ining,inhabits,ings,ingrown,inglewood,ingestion,ingesting,infusion,infusing,infringing,infringe,inflection,infinitum,infact,inexplicably,inequities,ineligible,industry's,induces,indubitably,indisputable,indirect,indescribably,independents,indentation,indefinable,incursion,incontrovertible,inconsequential,incompletes,incoherently,inclement,inciting,incidentals,inarticulate,inadequacies,imprudent,improvisation,improprieties,imprison,imprinted,impressively,impostors,importante,implicit,imperious,impale,immortalized,immodest,immobile,imbued,imbedded,imbecilic,illustrates,illegals,iliad,idn't,idiom,icons,hysteric,hypotenuse,hygienic,hyeah,hushpuppies,hunhh,hungarians,humpback,humored,hummed,humiliates,humidifier,huggy,huggers,huckster,html,hows,howlin,hoth,hotbed,hosing,hosers,horsehair,homegrown,homebody,homebake,holographic,holing,holies,hoisting,hogwallop,hogan's,hocks,hobbits,hoaxes,hmmmmm,hisses,hippos,hippest,hindrance,hindi,him's,hillbillies,hilarity,highball,hibiscus,heyday,heurh,hershey's,herniated,hermaphrodite,hera,hennifer,hemlines,hemline,hemery,helplessness,helmsley,hellhound,heheheheh,heey,heeey,hedda,heck's,heartbeats,heaped,healers,headstart,headsets,headlong,headlining,hawkland,havta,havana's,haulin,hastened,hasn,harvey'll,harpo,hardass,haps,hanta,hansom,hangnail,handstand,handrail,handoff,hander,han's,hamlet's,hallucinogen,hallor,halitosis,halen,hahah,hado,haberdashery,gypped,guy'll,guni,gumbel,gulch,gues,guerillas,guava,guatemalan,guardrail,guadalajara,grunther,grunick,grunemann's,growers,groppi,groomer,grodin,gris,gripes,grinds,grimaldi's,grifters,griffins,gridlock,gretch,greevey,greasing,graveyards,grandkid,grainy,graced,governed,gouging,gordie's,gooney,googly,golfers,goldmuff,goldenrod,goingo,godly,gobbledygook,gobbledegook,goa'uld's,glues,gloriously,glengarry,glassware,glamor,glaciers,ginseng,gimmicks,gimlet,gilded,giggly,gig's,giambetti,ghoulish,ghettos,ghandi,ghali,gether,get's,gestation,geriatrics,gerbils,gerace's,geosynchronous,georgio,geopolitical,genus,gente,genital,geneticist,generation's,generates,gendarme,gelbman,gazillionth,gayest,gauging,gastro,gaslight,gasbag,garters,garish,garas,garages,gantu,gangy,gangly,gangland,gamer,galling,galilee,galactica's,gaiety,gadda,gacy,futuristic,futs,furrowed,funny's,funnies,funkytown,fundraisers,fundamentalist,fulcrum,fugimotto,fuente,fueling,fudging,fuckup,fuckeen,frutt's,frustrates,froufrou,froot,frontiers,fromberge,frog's,frizzies,fritters,fringes,frightfully,frigate,friendliest,freeloading,freelancing,fredonia,freakazoid,fraternization,frankfurter,francine's,franchises,framers,fostered,fortune's,fornication,fornicating,formulating,formations,forman's,forgeries,forethought,forage,footstool,foisting,focussing,focking,foal,flutes,flurries,fluffed,flourished,florida's,floe,flintstones,fleischman's,fledgling,fledermaus,flayed,flay,flawlessly,flatters,flashbang,flapped,flanking,flamer,fission,fishies,firmer,fireproof,fireman's,firebug,firebird,fingerpainting,finessed,findin,financials,finality,fillets,fighter's,fiercest,fiefdom,fibrosis,fiberglass,fibbing,feudal,festus,fervor,fervent,fentanyl,fenelon,fenders,fedorchuk,feckless,feathering,fearsome,fauna,faucets,farmland,farewells,fantasyland,fanaticism,faltered,fallacy,fairway,faggy,faberge,extremism,extorting,extorted,exterminating,exhumation,exhilaration,exhausts,exfoliate,exemptions,excesses,excels,exasperating,exacting,evoked,evocative,everyman,everybody'd,evasions,evangelical,establishments,espressos,esoteric,esmail,errrr,erratically,eroding,erode,ernswiler,episcopalian,ephemeral,epcot,entrenched,entomology,entomologist,enthralled,ensuing,ensenada,enriching,enrage,enlisting,enhancer,enhancements,endorsing,endear,encrusted,encino,enacted,employing,emperors,empathic,embodied,embezzle,embarked,emanates,elton's,eloquence,eloi,elmwood,elliptical,ellenor's,elemental,electricians,electing,elapsed,eking,egomaniacal,eggo,egging,effected,effacing,eeww,edits,editor's,edging,ectoplasm,economical,ecch,eavesdropped,eastbound,earwig,e'er,durable,dunbar's,dummkopf,dugray,duchaisne,duality,drusilla's,drunkard,drudge,drucilla's,droop,droids,drips,dripped,dribbles,drew's,dressings,drazens,downy,downsize,downpour,dowager,dote,dosages,dorothy's,doppler,doppelganger,dopes,doorman's,doohicky,doof,dontcha,donovon's,doneghy,domi,domes,dojo,documentaries,divinity,divining,divest,diuretics,diuretic,distrustful,distortions,dissident,disrupts,disruptions,disproportionate,dispensary,disparity,dismemberment,dismember,disinfect,disillusionment,disheartening,discriminated,discourteous,discotheque,discolored,disassembled,disabling,dirtiest,diphtheria,dinks,dimpled,digg,diffusion,differs,didya,dickweed,dickwad,dickson's,diatribes,diathesis,diabetics,dewars,deviants,detrimental,detonates,detests,detestable,detaining,despondent,desecration,descriptive,derision,derailing,deputized,depressors,depo,depicting,depict,dependant,dentures,denominators,demur,demonstrators,demonology,delts,dellarte,delinquency,delacour,deflated,definitively,defib,defected,defaced,deeded,decorators,debit,deaqon,davola,datin,dasilva's,darwinian,darling's,darklighters,dandelions,dandelion,dancer's,dampened,dame's,damaskinos,dama,dalrimple,dagobah,dack,d'peshu,d'hoffryn,d'astier,cystic,cynics,cybernetic,cutoff,cutesy,cutaway,customarily,curtain's,cursive,curmudgeon,curdle,cuneiform,cultivated,culpability,culo,cuisinart,cuffing,crypts,cryptid,cryogenic,crux,crunched,crumblers,crudely,crosscheck,croon,crissake,crime's,cribbage,crevasse,creswood,creepo,creases,creased,creaky,cranks,cran,craftsmen,crafting,crabgrass,cowboy's,coveralls,couple'a,councilors,coughs,cotton's,cosmology,coslaw,corresponded,corporeal,corollary,cornucopia,cornering,corks,cordoned,coolly,coolin,cooley's,coolant,cookbooks,converging,contrived,contrite,contributors,contradictory,contra,contours,contented,contenders,contemplated,contact's,constrictor,congressman's,congestion,confrontations,confound,conform,confit,confiscating,conferred,condoned,conditioners,concussions,concentric,conceding,coms,comprised,comprise,comprendo,composers,commuted,commercially,commentator,commentaries,commemorating,commander's,comers,comedic,combustible,combusted,columbo,columbia's,colourful,colonials,collingswood,coliseum,coldness,cojones,coitus,cohesive,cohesion,cohen's,coffey's,codicil,cochran's,coasting,clydesdale,cluttering,clunker,clunk,clumsiness,clumps,clotted,clothesline,clinches,clincher,cleverness,clench,clein,cleave,cleanses,claymores,clarisse,clarissa's,clammed,civilisation,ciudad,circumvent,circulated,circuit's,cinnamon's,cind,church's,chugging,chronically,christsakes,chris's,choque,chompers,choco,chiseling,chirpy,chirp,chinks,chingachgook,chigger,chicklet,chickenpox,chickadee,chewin,chessboard,cherub,chemo's,chauffeur's,chaucer,chariots,chargin,characterizing,chanteuse,chandeliers,chamdo,chalupa,chagrined,chaff,certs,certify,certification,certainties,cerreno,cerebrum,cerebro,century's,centennial,censured,cemetary,cellist,celine's,cedar's,cayo,caterwauling,caterpillars,categorized,catchers,cataclysmic,cassidy's,casitas,casino's,cased,carvel,cartographers,carting,cartels,carriages,carrear,carr's,carolling,carolinas,carolers,carnie,carne,cardiovascular,cardiogram,carbuncle,caramba,capulets,capping,canyons,canines,candaules,canape,canadiens,campaigned,cambodian,camberwell,caldecott,calamitous,caff,cadillacs,cachet,cabeza,cabdriver,byzantium,buzzkill,buzzards,buzz's,buyer's,butai,bustling,businesswomen,bunyan,bungled,bumpkins,bummers,bulletins,bullet's,bulldoze,bulbous,bug's,buffybot,budgeted,budda,bubut,bubbies,brunei,brrrrr,brownout,brouhaha,bronzing,bronchial,broiler,broadening,briskly,briefcases,bricked,breezing,breeher,breckinridge,breakwater,breakable,breadstick,bravenet,braved,brass's,brandies,brandeis,branched,brainwaves,brainiest,braggart,bradlee,boys're,boys'll,boys'd,boyd's,boutonniere,bottle's,bossed,bosomy,bosnian,borans,boosts,boombox,bookshelves,bookmark,booklet,bookends,bontecou's,bongos,boneless,bone's,bond's,bombarding,bombarded,bollo,boinked,boink,boilers,bogart's,bobbo,bobbin,bluest,bluebells,blowjobs,bloodshot,blondie's,blockhead,blockbusters,blithely,blim,bleh,blather,blasters,blankly,bladders,blackhawks,blackbeard,bjorn,bitte,bippy,bios,biohazard,biogenetics,biochemistry,biochemist,bilingual,bilge,bigmouth,bighorn,bigglesworth,bicuspids,beususe,betaseron,besmirch,besieged,bernece,bergman's,bereavement,bentonville,benthic,benjie,benji's,benefactors,benchley,benching,bembe,bellyaching,bellhops,belie,beleaguered,being's,behrle,beginnin,begining,beenie,beefs,beechwood,bee's,bedbug,becau,beaverhausen,beakers,beacon's,bazillion,baudouin,bat's,bartlett's,barrytown,barringtons,baroque,baronet,barneys,barbs,barbers,barbatus,baptists,bankrupted,banker's,bamn,bambi's,ballon's,balinese,bakeries,bailiffs,backslide,baby'd,baaad,b'fore,awwwk,aways,awakes,averages,avengers,avatars,autonomous,automotive,automaton,automatics,autism,authoritative,authenticated,authenticate,aught,audition's,aubyn,attired,attagirl,atrophied,atonement,atherton's,asystole,astroturf,assimilated,assimilate,assertiveness,assemblies,assassin's,artiste,article's,artichokes,arsehole,arrears,arquillians,arnie's,aright,archenemy,arched,arcade's,aquatic,apps,appraise,applauded,appendages,appeased,apostle,apollo's,antwerp,antler,antiquity,antin,antidepressant,antibody,anthropologists,anthology,anthea,antagonism,ant's,anspaugh,annually,anka,angola,anesthetics,anda,ancients,anchoring,anaphylactic,anaheim,ana's,amtrak,amscray,amputated,amounted,americas,amended,ambivalence,amalio,amah,altoid,alriiight,alphabetized,alpena,alouette,allowable,allora,alliteration,allenwood,alleging,allegiances,aligning,algerians,alerts,alchemist,alcerro,alastor,airway's,airmen,ahaha,ah'm,agitators,agitation,aforethought,afis,aesthetics,aerospace,aerodynamics,advertises,advert,advantageous,admonition,administration's,adirondacks,adenoids,adebisi's,acupuncturist,acula,actuarial,activators,actionable,acme's,acknowledges,achmed,achingly,acetate,accusers,accumulation,accorded,acclimated,acclimate,absurdly,absorbent,absolvo,absolutes,absences,abraham's,aboriginal,ablaze,abdomenizer,aaaaaaaaah,aaaaaaaaaa,a'right".split(","))), p("male_names",s("james,john,robert,michael,william,david,richard,charles,joseph,thomas,christopher,daniel,paul,mark,donald,george,kenneth,steven,edward,brian,ronald,anthony,kevin,jason,matthew,gary,timothy,jose,larry,jeffrey,frank,scott,eric,stephen,andrew,raymond,gregory,joshua,jerry,dennis,walter,patrick,peter,harold,douglas,henry,carl,arthur,ryan,roger,joe,juan,jack,albert,jonathan,justin,terry,gerald,keith,samuel,willie,ralph,lawrence,nicholas,roy,benjamin,bruce,brandon,adam,harry,fred,wayne,billy,steve,louis,jeremy,aaron,randy,eugene,carlos,russell,bobby,victor,ernest,phillip,todd,jesse,craig,alan,shawn,clarence,sean,philip,chris,johnny,earl,jimmy,antonio,danny,bryan,tony,luis,mike,stanley,leonard,nathan,dale,manuel,rodney,curtis,norman,marvin,vincent,glenn,jeffery,travis,jeff,chad,jacob,melvin,alfred,kyle,francis,bradley,jesus,herbert,frederick,ray,joel,edwin,don,eddie,ricky,troy,randall,barry,bernard,mario,leroy,francisco,marcus,micheal,theodore,clifford,miguel,oscar,jay,jim,tom,calvin,alex,jon,ronnie,bill,lloyd,tommy,leon,derek,darrell,jerome,floyd,leo,alvin,tim,wesley,dean,greg,jorge,dustin,pedro,derrick,dan,zachary,corey,herman,maurice,vernon,roberto,clyde,glen,hector,shane,ricardo,sam,rick,lester,brent,ramon,tyler,gilbert,gene,marc,reginald,ruben,brett,angel,nathaniel,rafael,edgar,milton,raul,ben,cecil,duane,andre,elmer,brad,gabriel,ron,roland,jared,adrian,karl,cory,claude,erik,darryl,neil,christian,javier,fernando,clinton,ted,mathew,tyrone,darren,lonnie,lance,cody,julio,kurt,allan,clayton,hugh,max,dwayne,dwight,armando,felix,jimmie,everett,ian,ken,bob,jaime,casey,alfredo,alberto,dave,ivan,johnnie,sidney,byron,julian,isaac,clifton,willard,daryl,virgil,andy,salvador,kirk,sergio,seth,kent,terrance,rene,eduardo,terrence,enrique,freddie,stuart,fredrick,arturo,alejandro,joey,nick,luther,wendell,jeremiah,evan,julius,donnie,otis,trevor,luke,homer,gerard,doug,kenny,hubert,angelo,shaun,lyle,matt,alfonso,orlando,rex,carlton,ernesto,pablo,lorenzo,omar,wilbur,blake,horace,roderick,kerry,abraham,rickey,ira,andres,cesar,johnathan,malcolm,rudolph,damon,kelvin,rudy,preston,alton,archie,marco,wm,pete,randolph,garry,geoffrey,jonathon,felipe,bennie,gerardo,ed,dominic,loren,delbert,colin,guillermo,earnest,benny,noel,rodolfo,myron,edmund,salvatore,cedric,lowell,gregg,sherman,devin,sylvester,roosevelt,israel,jermaine,forrest,wilbert,leland,simon,irving,owen,rufus,woodrow,kristopher,levi,marcos,gustavo,lionel,marty,gilberto,clint,nicolas,laurence,ismael,orville,drew,ervin,dewey,al,wilfred,josh,hugo,ignacio,caleb,tomas,sheldon,erick,frankie,darrel,rogelio,terence,alonzo,elias,bert,elbert,ramiro,conrad,noah,grady,phil,cornelius,lamar,rolando,clay,percy,dexter,bradford,merle,darin,amos,terrell,moses,irvin,saul,roman,darnell,randal,tommie,timmy,darrin,brendan,toby,van,abel,dominick,emilio,elijah,cary,domingo,aubrey,emmett,marlon,emanuel,jerald,edmond,emil,dewayne,otto,teddy,reynaldo,bret,jess,trent,humberto,emmanuel,stephan,louie,vicente,lamont,garland,micah,efrain,heath,rodger,demetrius,ethan,eldon,rocky,pierre,eli,bryce,antoine,robbie,kendall,royce,sterling,grover,elton,cleveland,dylan,chuck,damian,reuben,stan,leonardo,russel,erwin,benito,hans,monte,blaine,ernie,curt,quentin,agustin,jamal,devon,adolfo,tyson,wilfredo,bart,jarrod,vance,denis,damien,joaquin,harlan,desmond,elliot,darwin,gregorio,kermit,roscoe,esteban,anton,solomon,norbert,elvin,nolan,carey,rod,quinton,hal,brain,rob,elwood,kendrick,darius,moises,marlin,fidel,thaddeus,cliff,marcel,ali,raphael,bryon,armand,alvaro,jeffry,dane,joesph,thurman,ned,sammie,rusty,michel,monty,rory,fabian,reggie,kris,isaiah,gus,avery,loyd,diego,adolph,millard,rocco,gonzalo,derick,rodrigo,gerry,rigoberto,alphonso,ty,rickie,noe,vern,elvis,bernardo,mauricio,hiram,donovan,basil,nickolas,scot,vince,quincy,eddy,sebastian,federico,ulysses,heriberto,donnell,denny,gavin,emery,romeo,jayson,dion,dante,clement,coy,odell,jarvis,bruno,issac,dudley,sanford,colby,carmelo,nestor,hollis,stefan,donny,art,linwood,beau,weldon,galen,isidro,truman,delmar,johnathon,silas,frederic,irwin,merrill,charley,marcelino,carlo,trenton,kurtis,aurelio,winfred,vito,collin,denver,leonel,emory,pasquale,mohammad,mariano,danial,landon,dirk,branden,adan,numbers,clair,buford,german,bernie,wilmer,emerson,zachery,jacques,errol,josue,edwardo,wilford,theron,raymundo,daren,tristan,robby,lincoln,jame,genaro,octavio,cornell,hung,arron,antony,herschel,alva,giovanni,garth,cyrus,cyril,ronny,stevie,lon,kennith,carmine,augustine,erich,chadwick,wilburn,russ,myles,jonas,mitchel,mervin,zane,jamel,lazaro,alphonse,randell,major,johnie,jarrett,ariel,abdul,dusty,luciano,seymour,scottie,eugenio,mohammed,valentin,arnulfo,lucien,ferdinand,thad,ezra,aldo,rubin,royal,mitch,earle,abe,marquis,lanny,kareem,jamar,boris,isiah,emile,elmo,aron,leopoldo,everette,josef,eloy,dorian,rodrick,reinaldo,lucio,jerrod,weston,hershel,lemuel,lavern,burt,jules,gil,eliseo,ahmad,nigel,efren,antwan,alden,margarito,refugio,dino,osvaldo,les,deandre,normand,kieth,ivory,trey,norberto,napoleon,jerold,fritz,rosendo,milford,sang,deon,christoper,alfonzo,lyman,josiah,brant,wilton,rico,jamaal,dewitt,brenton,yong,olin,faustino,claudio,judson,gino,edgardo,alec,jarred,donn,trinidad,tad,porfirio,odis,lenard,chauncey,tod,mel,marcelo,kory,augustus,keven,hilario,bud,sal,orval,mauro,dannie,zachariah,olen,anibal,milo,jed,thanh,amado,lenny,tory,richie,horacio,brice,mohamed,delmer,dario,mac,jonah,jerrold,robt,hank,sung,rupert,rolland,kenton,damion,chi,antone,waldo,fredric,bradly,kip,burl,tyree,jefferey,ahmed,willy,stanford,oren,moshe,mikel,enoch,brendon,quintin,jamison,florencio,darrick,tobias,minh,hassan,giuseppe,demarcus,cletus,tyrell,lyndon,keenan,werner,theo,geraldo,columbus,chet,bertram,markus,huey,hilton,dwain,donte,tyron,omer,isaias,hipolito,fermin,chung,adalberto,jamey,teodoro,mckinley,maximo,sol,raleigh,lawerence,abram,rashad,emmitt,daron,chong,samual,otha,miquel,eusebio,dong,domenic,darron,wilber,renato,hoyt,haywood,ezekiel,chas,florentino,elroy,clemente,arden,neville,edison,deshawn,carrol,shayne,nathanial,jordon,danilo,claud,val,sherwood,raymon,rayford,cristobal,ambrose,titus,hyman,felton,ezequiel,erasmo,lonny,len,ike,milan,lino,jarod,herb,andreas,rhett,jude,douglass,cordell,oswaldo,ellsworth,virgilio,toney,nathanael,del,benedict,mose,hong,isreal,garret,fausto,asa,arlen,zack,modesto,francesco,manual,jae,gaylord,gaston,filiberto,deangelo,michale,granville,wes,malik,zackary,tuan,nicky,cristopher,antione,malcom,korey,jospeh,colton,waylon,von,hosea,shad,santo,rudolf,rolf,rey,renaldo,marcellus,lucius,kristofer,harland,arnoldo,rueben,leandro,kraig,jerrell,jeromy,hobert,cedrick,arlie,winford,wally,luigi,keneth,jacinto,graig,franklyn,edmundo,sid,leif,jeramy,willian,vincenzo,shon,michal,lynwood,jere,hai,elden,darell,broderick,alonso".split(","))), p("female_names",s("mary,patricia,linda,barbara,elizabeth,jennifer,maria,susan,margaret,dorothy,lisa,nancy,karen,betty,helen,sandra,donna,carol,ruth,sharon,michelle,laura,sarah,kimberly,deborah,jessica,shirley,cynthia,angela,melissa,brenda,amy,anna,rebecca,virginia,kathleen,pamela,martha,debra,amanda,stephanie,carolyn,christine,marie,janet,catherine,frances,ann,joyce,diane,alice,julie,heather,teresa,doris,gloria,evelyn,jean,cheryl,mildred,katherine,joan,ashley,judith,rose,janice,kelly,nicole,judy,christina,kathy,theresa,beverly,denise,tammy,irene,jane,lori,rachel,marilyn,andrea,kathryn,louise,sara,anne,jacqueline,wanda,bonnie,julia,ruby,lois,tina,phyllis,norma,paula,diana,annie,lillian,emily,robin,peggy,crystal,gladys,rita,dawn,connie,florence,tracy,edna,tiffany,carmen,rosa,cindy,grace,wendy,victoria,edith,kim,sherry,sylvia,josephine,thelma,shannon,sheila,ethel,ellen,elaine,marjorie,carrie,charlotte,monica,esther,pauline,emma,juanita,anita,rhonda,hazel,amber,eva,debbie,april,leslie,clara,lucille,jamie,joanne,eleanor,valerie,danielle,megan,alicia,suzanne,michele,gail,bertha,darlene,veronica,jill,erin,geraldine,lauren,cathy,joann,lorraine,lynn,sally,regina,erica,beatrice,dolores,bernice,audrey,yvonne,annette,june,marion,dana,stacy,ana,renee,ida,vivian,roberta,holly,brittany,melanie,loretta,yolanda,jeanette,laurie,katie,kristen,vanessa,alma,sue,elsie,beth,jeanne,vicki,carla,tara,rosemary,eileen,terri,gertrude,lucy,tonya,ella,stacey,wilma,gina,kristin,jessie,natalie,agnes,vera,charlene,bessie,delores,melinda,pearl,arlene,maureen,colleen,allison,tamara,joy,georgia,constance,lillie,claudia,jackie,marcia,tanya,nellie,minnie,marlene,heidi,glenda,lydia,viola,courtney,marian,stella,caroline,dora,jo,vickie,mattie,maxine,irma,mabel,marsha,myrtle,lena,christy,deanna,patsy,hilda,gwendolyn,jennie,nora,margie,nina,cassandra,leah,penny,kay,priscilla,naomi,carole,olga,billie,dianne,tracey,leona,jenny,felicia,sonia,miriam,velma,becky,bobbie,violet,kristina,toni,misty,mae,shelly,daisy,ramona,sherri,erika,katrina,claire,lindsey,lindsay,geneva,guadalupe,belinda,margarita,sheryl,cora,faye,ada,natasha,sabrina,isabel,marguerite,hattie,harriet,molly,cecilia,kristi,brandi,blanche,sandy,rosie,joanna,iris,eunice,angie,inez,lynda,madeline,amelia,alberta,genevieve,monique,jodi,janie,kayla,sonya,jan,kristine,candace,fannie,maryann,opal,alison,yvette,melody,luz,susie,olivia,flora,shelley,kristy,mamie,lula,lola,verna,beulah,antoinette,candice,juana,jeannette,pam,kelli,whitney,bridget,karla,celia,latoya,patty,shelia,gayle,della,vicky,lynne,sheri,marianne,kara,jacquelyn,erma,blanca,myra,leticia,pat,krista,roxanne,angelica,robyn,adrienne,rosalie,alexandra,brooke,bethany,sadie,bernadette,traci,jody,kendra,nichole,rachael,mable,ernestine,muriel,marcella,elena,krystal,angelina,nadine,kari,estelle,dianna,paulette,lora,mona,doreen,rosemarie,desiree,antonia,janis,betsy,christie,freda,meredith,lynette,teri,cristina,eula,leigh,meghan,sophia,eloise,rochelle,gretchen,cecelia,raquel,henrietta,alyssa,jana,gwen,jenna,tricia,laverne,olive,tasha,silvia,elvira,delia,kate,patti,lorena,kellie,sonja,lila,lana,darla,mindy,essie,mandy,lorene,elsa,josefina,jeannie,miranda,dixie,lucia,marta,faith,lela,johanna,shari,camille,tami,shawna,elisa,ebony,melba,ora,nettie,tabitha,ollie,winifred,kristie,marina,alisha,aimee,rena,myrna,marla,tammie,latasha,bonita,patrice,ronda,sherrie,addie,francine,deloris,stacie,adriana,cheri,abigail,celeste,jewel,cara,adele,rebekah,lucinda,dorthy,effie,trina,reba,sallie,aurora,lenora,etta,lottie,kerri,trisha,nikki,estella,francisca,josie,tracie,marissa,karin,brittney,janelle,lourdes,laurel,helene,fern,elva,corinne,kelsey,ina,bettie,elisabeth,aida,caitlin,ingrid,iva,eugenia,christa,goldie,maude,jenifer,therese,dena,lorna,janette,latonya,candy,consuelo,tamika,rosetta,debora,cherie,polly,dina,jewell,fay,jillian,dorothea,nell,trudy,esperanza,patrica,kimberley,shanna,helena,cleo,stefanie,rosario,ola,janine,mollie,lupe,alisa,lou,maribel,susanne,bette,susana,elise,cecile,isabelle,lesley,jocelyn,paige,joni,rachelle,leola,daphne,alta,ester,petra,graciela,imogene,jolene,keisha,lacey,glenna,gabriela,keri,ursula,lizzie,kirsten,shana,adeline,mayra,jayne,jaclyn,gracie,sondra,carmela,marisa,rosalind,charity,tonia,beatriz,marisol,clarice,jeanine,sheena,angeline,frieda,lily,shauna,millie,claudette,cathleen,angelia,gabrielle,autumn,katharine,jodie,staci,lea,christi,justine,elma,luella,margret,dominique,socorro,martina,margo,mavis,callie,bobbi,maritza,lucile,leanne,jeannine,deana,aileen,lorie,ladonna,willa,manuela,gale,selma,dolly,sybil,abby,ivy,dee,winnie,marcy,luisa,jeri,magdalena,ofelia,meagan,audra,matilda,leila,cornelia,bianca,simone,bettye,randi,virgie,latisha,barbra,georgina,eliza,leann,bridgette,rhoda,haley,adela,nola,bernadine,flossie,ila,greta,ruthie,nelda,minerva,lilly,terrie,letha,hilary,estela,valarie,brianna,rosalyn,earline,catalina,ava,mia,clarissa,lidia,corrine,alexandria,concepcion,tia,sharron,rae,dona,ericka,jami,elnora,chandra,lenore,neva,marylou,melisa,tabatha,serena,avis,allie,sofia,jeanie,odessa,nannie,harriett,loraine,penelope,milagros,emilia,benita,allyson,ashlee,tania,esmeralda,karina,eve,pearlie,zelma,malinda,noreen,tameka,saundra,hillary,amie,althea,rosalinda,lilia,alana,clare,alejandra,elinor,lorrie,jerri,darcy,earnestine,carmella,noemi,marcie,liza,annabelle,louisa,earlene,mallory,carlene,nita,selena,tanisha,katy,julianne,lakisha,edwina,maricela,margery,kenya,dollie,roxie,roslyn,kathrine,nanette,charmaine,lavonne,ilene,tammi,suzette,corine,kaye,chrystal,lina,deanne,lilian,juliana,aline,luann,kasey,maryanne,evangeline,colette,melva,lawanda,yesenia,nadia,madge,kathie,ophelia,valeria,nona,mitzi,mari,georgette,claudine,fran,alissa,roseann,lakeisha,susanna,reva,deidre,chasity,sheree,elvia,alyce,deirdre,gena,briana,araceli,katelyn,rosanne,wendi,tessa,berta,marva,imelda,marietta,marci,leonor,arline,sasha,madelyn,janna,juliette,deena,aurelia,josefa,augusta,liliana,lessie,amalia,savannah,anastasia,vilma,natalia,rosella,lynnette,corina,alfreda,leanna,amparo,coleen,tamra,aisha,wilda,karyn,queen,maura,mai,evangelina,rosanna,hallie,erna,enid,mariana,lacy,juliet,jacklyn,freida,madeleine,mara,cathryn,lelia,casandra,bridgett,angelita,jannie,dionne,annmarie,katina,beryl,millicent,katheryn,diann,carissa,maryellen,liz,lauri,helga,gilda,rhea,marquita,hollie,tisha,tamera,angelique,francesca,kaitlin,lolita,florine,rowena,reyna,twila,fanny,janell,ines,concetta,bertie,alba,brigitte,alyson,vonda,pansy,elba,noelle,letitia,deann,brandie,louella,leta,felecia,sharlene,lesa,beverley,isabella,herminia,terra,celina,tori,octavia,jade,denice,germaine,michell,cortney,nelly,doretha,deidra,monika,lashonda,judi,chelsey,antionette,margot,adelaide,nan,leeann,elisha,dessie,libby,kathi,gayla,latanya,mina,mellisa,kimberlee,jasmin,renae,zelda,elda,justina,gussie,emilie,camilla,abbie,rocio,kaitlyn,edythe,ashleigh,selina,lakesha,geri,allene,pamala,michaela,dayna,caryn,rosalia,sun,jacquline,rebeca,marybeth,krystle,iola,dottie,belle,griselda,ernestina,elida,adrianne,demetria,delma,jaqueline,arleen,virgina,retha,fatima,tillie,eleanore,cari,treva,wilhelmina,rosalee,maurine,latrice,jena,taryn,elia,debby,maudie,jeanna,delilah,catrina,shonda,hortencia,theodora,teresita,robbin,danette,delphine,brianne,nilda,danna,cindi,bess,iona,winona,vida,rosita,marianna,racheal,guillermina,eloisa,celestine,caren,malissa,lona,chantel,shellie,marisela,leora,agatha,soledad,migdalia,ivette,christen,janel,veda,pattie,tessie,tera,marilynn,lucretia,karrie,dinah,daniela,alecia,adelina,vernice,shiela,portia,merry,lashawn,dara,tawana,oma,verda,alene,zella,sandi,rafaela,maya,kira,candida,alvina,suzan,shayla,lyn,lettie,samatha,oralia,matilde,larissa,vesta,renita,india,delois,shanda,phillis,lorri,erlinda,cathrine,barb,zoe,isabell,ione,gisela,roxanna,mayme,kisha,ellie,mellissa,dorris,dalia,bella,annetta,zoila,reta,reina,lauretta,kylie,christal,pilar,charla,elissa,tiffani,tana,paulina,leota,breanna,jayme,carmel,vernell,tomasa,mandi,dominga,santa,melodie,lura,alexa,tamela,mirna,kerrie,venus,felicita,cristy,carmelita,berniece,annemarie,tiara,roseanne,missy,cori,roxana,pricilla,kristal,jung,elyse,haydee,aletha,bettina,marge,gillian,filomena,zenaida,harriette,caridad,vada,una,aretha,pearline,marjory,marcela,flor,evette,elouise,alina,damaris,catharine,belva,nakia,marlena,luanne,lorine,karon,dorene,danita,brenna,tatiana,louann,julianna,andria,philomena,lucila,leonora,dovie,romona,mimi,jacquelin,gaye,tonja,misti,chastity,stacia,roxann,micaela,nikita,mei,velda,marlys,johnna,aura,ivonne,hayley,nicki,majorie,herlinda,yadira,perla,gregoria,antonette,shelli,mozelle,mariah,joelle,cordelia,josette,chiquita,trista,laquita,georgiana,candi,shanon,hildegard,valentina,stephany,magda,karol,gabriella,tiana,roma,richelle,oleta,jacque,idella,alaina,suzanna,jovita,tosha,nereida,marlyn,kyla,delfina,tena,stephenie,sabina,nathalie,marcelle,gertie,darleen,thea,sharonda,shantel,belen,venessa,rosalina,ona,genoveva,clementine,rosalba,renate,renata,georgianna,floy,dorcas,ariana,tyra,theda,mariam,juli,jesica,vikki,verla,roselyn,melvina,jannette,ginny,debrah,corrie,asia,violeta,myrtis,latricia,collette,charleen,anissa,viviana,twyla,nedra,latonia,lan,hellen,fabiola,annamarie,adell,sharyn,chantal,niki,maud,lizette,lindy,kia,kesha,jeana,danelle,charline,chanel,valorie,lia,dortha,cristal,leone,leilani,gerri,debi,andra,keshia,ima,eulalia,easter,dulce,natividad,linnie,kami,georgie,catina,brook,alda,winnifred,sharla,ruthann,meaghan,magdalene,lissette,adelaida,venita,trena,shirlene,shameka,elizebeth,dian,shanta,latosha,carlotta,windy,rosina,mariann,leisa,jonnie,dawna,cathie,astrid,laureen,janeen,holli,fawn,vickey,teressa,shante,rubye,marcelina,chanda,terese,scarlett,marnie,lulu,lisette,jeniffer,elenor,dorinda,donita,carman,bernita,altagracia,aleta,adrianna,zoraida,nicola,lyndsey,janina,ami,starla,phylis,phuong,kyra,charisse,blanch,sanjuanita,rona,nanci,marilee,maranda,brigette,sanjuana,marita,kassandra,joycelyn,felipa,chelsie,bonny,mireya,lorenza,kyong,ileana,candelaria,sherie,lucie,leatrice,lakeshia,gerda,edie,bambi,marylin,lavon,hortense,garnet,evie,tressa,shayna,lavina,kyung,jeanetta,sherrill,shara,phyliss,mittie,anabel,alesia,thuy,tawanda,joanie,tiffanie,lashanda,karissa,enriqueta,daria,daniella,corinna,alanna,abbey,roxane,roseanna,magnolia,lida,joellen,era,coral,carleen,tresa,peggie,novella,nila,maybelle,jenelle,carina,nova,melina,marquerite,margarette,josephina,evonne,cinthia,albina,toya,tawnya,sherita,myriam,lizabeth,lise,keely,jenni,giselle,cheryle,ardith,ardis,alesha,adriane,shaina,linnea,karolyn,felisha,dori,darci,artie,armida,zola,xiomara,vergie,shamika,nena,nannette,maxie,lovie,jeane,jaimie,inge,farrah,elaina,caitlyn,felicitas,cherly,caryl,yolonda,yasmin,teena,prudence,pennie,nydia,mackenzie,orpha,marvel,lizbeth,laurette,jerrie,hermelinda,carolee,tierra,mirian,meta,melony,kori,jennette,jamila,ena,anh,yoshiko,susannah,salina,rhiannon,joleen,cristine,ashton,aracely,tomeka,shalonda,marti,lacie,kala,jada,ilse,hailey,brittani,zona,syble,sherryl,nidia,marlo,kandice,kandi,deb,alycia,ronna,norene,mercy,ingeborg,giovanna,gemma,christel,audry,zora,vita,trish,stephaine,shirlee,shanika,melonie,mazie,jazmin,inga,hoa,hettie,geralyn,fonda,estrella,adella,sarita,rina,milissa,maribeth,golda,evon,ethelyn,enedina,cherise,chana,velva,tawanna,sade,mirta,karie,jacinta,elna,davina,cierra,ashlie,albertha,tanesha,nelle,mindi,lorinda,larue,florene,demetra,dedra,ciara,chantelle,ashly,suzy,rosalva,noelia,lyda,leatha,krystyna,kristan,karri,darline,darcie,cinda,cherrie,awilda,almeda,rolanda,lanette,jerilyn,gisele,evalyn,cyndi,cleta,carin,zina,zena,velia,tanika,charissa,talia,margarete,lavonda,kaylee,kathlene,jonna,irena,ilona,idalia,candis,candance,brandee,anitra,alida,sigrid,nicolette,maryjo,linette,hedwig,christiana,alexia,tressie,modesta,lupita,lita,gladis,evelia,davida,cherri,cecily,ashely,annabel,agustina,wanita,shirly,rosaura,hulda,eun,yetta,verona,thomasina,sibyl,shannan,mechelle,lue,leandra,lani,kylee,kandy,jolynn,ferne,eboni,corene,alysia,zula,nada,moira,lyndsay,lorretta,jammie,hortensia,gaynell,adria,vina,vicenta,tangela,stephine,norine,nella,liana,leslee,kimberely,iliana,glory,felica,emogene,elfriede,eden,eartha,carma,bea,ocie,lennie,kiara,jacalyn,carlota,arielle,otilia,kirstin,kacey,johnetta,joetta,jeraldine,jaunita,elana,dorthea,cami,amada,adelia,vernita,tamar,siobhan,renea,rashida,ouida,nilsa,meryl,kristyn,julieta,danica,breanne,aurea,anglea,sherron,odette,malia,lorelei,leesa,kenna,kathlyn,fiona,charlette,suzie,shantell,sabra,racquel,myong,mira,martine,lucienne,lavada,juliann,elvera,delphia,christiane,charolette,carri,asha,angella,paola,ninfa,leda,lai,eda,stefani,shanell,palma,machelle,lissa,kecia,kathryne,karlene,julissa,jettie,jenniffer,hui,corrina,carolann,alena,rosaria,myrtice,marylee,liane,kenyatta,judie,janey,elmira,eldora,denna,cristi,cathi,zaida,vonnie,viva,vernie,rosaline,mariela,luciana,lesli,karan,felice,deneen,adina,wynona,tarsha,sheron,shanita,shani,shandra,randa,pinkie,nelida,marilou,lyla,laurene,laci,joi,janene,dorotha,daniele,dani,carolynn,carlyn,berenice,ayesha,anneliese,alethea,thersa,tamiko,rufina,oliva,mozell,marylyn,kristian,kathyrn,kasandra,kandace,janae,domenica,debbra,dannielle,arcelia,aja,zenobia,sharen,sharee,lavinia,kum,kacie,jackeline,huong,felisa,emelia,eleanora,cythia,cristin,claribel,anastacia,zulma,zandra,yoko,tenisha,susann,sherilyn,shay,shawanda,romana,mathilda,linsey,keiko,joana,isela,gretta,georgetta,eugenie,desirae,delora,corazon,antonina,anika,willene,tracee,tamatha,nichelle,mickie,maegan,luana,lanita,kelsie,edelmira,bree,afton,teodora,tamie,shena,meg,linh,keli,kaci,danyelle,arlette,albertine,adelle,tiffiny,simona,nicolasa,nichol,nia,nakisha,mee,maira,loreen,kizzy,fallon,christene,bobbye,vincenza,tanja,rubie,roni,queenie,margarett,kimberli,irmgard,idell,hilma,evelina,esta,emilee,dennise,dania,carie,wai,risa,rikki,particia,mui,masako,luvenia,loree,loni,lien,gigi,florencia,denita,billye,tomika,sharita,rana,nikole,neoma,margarite,madalyn,lucina,laila,kali,jenette,gabriele,evelyne,elenora,clementina,alejandrina,zulema,violette,vannessa,thresa,retta,pia,patience,noella,nickie,jonell,chaya,camelia,bethel,anya,suzann,shu,mila,lilla,laverna,keesha,kattie,georgene,eveline,estell,elizbeth,vivienne,vallie,trudie,stephane,magaly,madie,kenyetta,karren,janetta,hermine,drucilla,debbi,celestina,candie,britni,beckie,amina,zita,yun,yolande,vivien,vernetta,trudi,sommer,pearle,patrina,ossie,nicolle,loyce,letty,larisa,katharina,joselyn,jonelle,jenell,iesha,heide,florinda,florentina,flo,elodia,dorine,brunilda,brigid,ashli,ardella,twana,thu,tarah,shavon,serina,rayna,ramonita,nga,margurite,lucrecia,kourtney,kati,jesenia,crista,ayana,alica,alia,vinnie,suellen,romelia,rachell,olympia,michiko,kathaleen,jolie,jessi,janessa,hana,elease,carletta,britany,shona,salome,rosamond,regena,raina,ngoc,nelia,louvenia,lesia,latrina,laticia,larhonda,jina,jacki,emmy,deeann,coretta,arnetta,thalia,shanice,neta,mikki,micki,lonna,leana,lashunda,kiley,joye,jacqulyn,ignacia,hyun,hiroko,henriette,elayne,delinda,dahlia,coreen,consuela,conchita,celine,babette,ayanna,anette,albertina,shawnee,shaneka,quiana,pamelia,min,merri,merlene,margit,kiesha,kiera,kaylene,jodee,jenise,erlene,emmie,dalila,daisey,casie,belia,babara,versie,vanesa,shelba,shawnda,nikia,naoma,marna,margeret,madaline,lawana,kindra,jutta,jazmine,janett,hannelore,glendora,gertrud,garnett,freeda,frederica,florance,flavia,carline,beverlee,anjanette,valda,tamala,shonna,sha,sarina,oneida,merilyn,marleen,lurline,lenna,katherin,jin,jeni,hae,gracia,glady,farah,enola,ema,dominque,devona,delana,cecila,caprice,alysha,alethia,vena,theresia,tawny,shakira,samara,sachiko,rachele,pamella,marni,mariel,maren,malisa,ligia,lera,latoria,larae,kimber,kathern,karey,jennefer,janeth,halina,fredia,delisa,debroah,ciera,angelika,andree,altha,yen,vivan,terresa,tanna,suk,sudie,soo,signe,salena,ronni,rebbecca,myrtie,malika,maida,loan,leonarda,kayleigh,ethyl,ellyn,dayle,cammie,brittni,birgit,avelina,asuncion,arianna,akiko,venice,tyesha,tonie,tiesha,takisha,steffanie,sindy,meghann,manda,macie,kellye,kellee,joslyn,inger,indira,glinda,glennis,fernanda,faustina,eneida,elicia,dot,digna,dell,arletta,willia,tammara,tabetha,sherrell,sari,rebbeca,pauletta,natosha,nakita,mammie,kenisha,kazuko,kassie,earlean,daphine,corliss,clotilde,carolyne,bernetta,augustina,audrea,annis,annabell,yan,tennille,tamica,selene,rosana,regenia,qiana,markita,macy,leeanne,laurine,kym,jessenia,janita,georgine,genie,emiko,elvie,deandra,dagmar,corie,collen,cherish,romaine,porsha,pearlene,micheline,merna,margorie,margaretta,lore,jenine,hermina,fredericka,elke,drusilla,dorathy,dione,celena,brigida,angeles,allegra,tamekia,synthia,sook,slyvia,rosann,reatha,raye,marquetta,margart,layla,kymberly,kiana,kayleen,katlyn,karmen,joella,irina,emelda,eleni,detra,clemmie,cheryll,chantell,cathey,arnita,arla,angle,angelic,alyse,zofia,thomasine,tennie,sherly,sherley,sharyl,remedios,petrina,nickole,myung,myrle,mozella,louanne,lisha,latia,krysta,julienne,jeanene,jacqualine,isaura,gwenda,earleen,cleopatra,carlie,audie,antonietta,alise,verdell,tomoko,thao,talisha,shemika,savanna,santina,rosia,raeann,odilia,nana,minna,magan,lynelle,karma,joeann,ivana,inell,ilana,hye,hee,gudrun,dreama,crissy,chante,carmelina,arvilla,annamae,alvera,aleida,yanira,vanda,tianna,tam,stefania,shira,nicol,nancie,monserrate,melynda,melany,lovella,laure,kacy,jacquelynn,hyon,gertha,eliana,christena,christeen,charise,caterina,carley,candyce,arlena,ammie,willette,vanita,tuyet,syreeta,penney,nyla,maryam,marya,magen,ludie,loma,livia,lanell,kimberlie,julee,donetta,diedra,denisha,deane,dawne,clarine,cherryl,bronwyn,alla,valery,tonda,sueann,soraya,shoshana,shela,sharleen,shanelle,nerissa,meridith,mellie,maye,maple,magaret,lili,leonila,leonie,leeanna,lavonia,lavera,kristel,kathey,kathe,jann,ilda,hildred,hildegarde,genia,fumiko,evelin,ermelinda,elly,dung,doloris,dionna,danae,berneice,annice,alix,verena,verdie,shawnna,shawana,shaunna,rozella,randee,ranae,milagro,lynell,luise,loida,lisbeth,karleen,junita,jona,isis,hyacinth,hedy,gwenn,ethelene,erline,donya,domonique,delicia,dannette,cicely,branda,blythe,bethann,ashlyn,annalee,alline,yuko,vella,trang,towanda,tesha,sherlyn,narcisa,miguelina,meri,maybell,marlana,marguerita,madlyn,lory,loriann,leonore,leighann,laurice,latesha,laronda,katrice,kasie,kaley,jadwiga,glennie,gearldine,francina,epifania,dyan,dorie,diedre,denese,demetrice,delena,cristie,cleora,catarina,carisa,barbera,almeta,trula,tereasa,solange,sheilah,shavonne,sanora,rochell,mathilde,margareta,maia,lynsey,lawanna,launa,kena,keena,katia,glynda,gaylene,elvina,elanor,danuta,danika,cristen,cordie,coletta,clarita,carmon,brynn,azucena,aundrea,angele,verlie,verlene,tamesha,silvana,sebrina,samira,reda,raylene,penni,norah,noma,mireille,melissia,maryalice,laraine,kimbery,karyl,karine,kam,jolanda,johana,jesusa,jaleesa,jacquelyne,iluminada,hilaria,hanh,gennie,francie,floretta,exie,edda,drema,delpha,bev,barbar,assunta,ardell,annalisa,alisia,yukiko,yolando,wonda,wei,waltraud,veta,temeka,tameika,shirleen,shenita,piedad,ozella,mirtha,marilu,kimiko,juliane,jenice,janay,jacquiline,hilde,fae,elois,echo,devorah,chau,brinda,betsey,arminda,aracelis,apryl,annett,alishia,veola,usha,toshiko,theola,tashia,talitha,shery,renetta,reiko,rasheeda,obdulia,mika,melaine,meggan,marlen,marget,marceline,mana,magdalen,librada,lezlie,latashia,lasandra,kelle,isidra,isa,inocencia,gwyn,francoise,erminia,erinn,dimple,devora,criselda,armanda,arie,ariane,angelena,aliza,adriene,adaline,xochitl,twanna,tomiko,tamisha,taisha,susy,siu,rutha,rhona,noriko,natashia,merrie,marinda,mariko,margert,loris,lizzette,leisha,kaila,joannie,jerrica,jene,jannet,janee,jacinda,herta,elenore,doretta,delaine,daniell,claudie,britta,apolonia,amberly,alease,yuri,yuk,wen,waneta,ute,tomi,sharri,sandie,roselle,reynalda,raguel,phylicia,patria,olimpia,odelia,mitzie,minda,mignon,mica,mendy,marivel,maile,lynetta,lavette,lauryn,latrisha,lakiesha,kiersten,kary,josphine,jolyn,jetta,janise,jacquie,ivelisse,glynis,gianna,gaynelle,danyell,danille,dacia,coralee,cher,ceola,arianne,aleshia,yung,williemae,trinh,thora,tai,svetlana,sherika,shemeka,shaunda,roseline,ricki,melda,mallie,lavonna,latina,laquanda,lala,lachelle,klara,kandis,johna,jeanmarie,jaye,grayce,gertude,emerita,ebonie,clorinda,ching,chery,carola,breann,blossom,bernardine,becki,arletha,argelia,ara,alita,yulanda,yon,yessenia,tobi,tasia,sylvie,shirl,shirely,shella,shantelle,sacha,rebecka,providencia,paulene,misha,miki,marline,marica,lorita,latoyia,lasonya,kerstin,kenda,keitha,kathrin,jaymie,gricelda,ginette,eryn,elina,elfrieda,danyel,cheree,chanelle,barrie,aurore,annamaria,alleen,ailene,aide,yasmine,vashti,treasa,tiffaney,sheryll,sharie,shanae,sau,raisa,neda,mitsuko,mirella,milda,maryanna,maragret,mabelle,luetta,lorina,letisha,latarsha,lanelle,lajuana,krissy,karly,karena,jessika,jerica,jeanelle,jalisa,jacelyn,izola,euna,etha,domitila,dominica,daina,creola,carli,camie,brittny,ashanti,anisha,aleen,adah,yasuko,valrie,tona,tinisha,thi,terisa,taneka,simonne,shalanda,serita,ressie,refugia,olene,margherita,mandie,maire,lyndia,luci,lorriane,loreta,leonia,lavona,lashawnda,lakia,kyoko,krystina,krysten,kenia,kelsi,jeanice,isobel,georgiann,genny,felicidad,eilene,deloise,conception,clora,cherilyn,calandra,armandina,anisa,ula,tiera,theressa,stephania,sima,shyla,shonta,shera,shaquita,shala,rossana,nohemi,nery,moriah,melita,melida,melani,marylynn,marisha,mariette,malorie,madelene,ludivina,loria,lorette,loralee,lianne,lavenia,laurinda,lashon,kit,kimi,keila,katelynn,kai,jone,joane,jayna,janella,hue,hertha,francene,elinore,despina,delsie,deedra,clemencia,carolin,bulah,brittanie,bok,blondell,bibi,beaulah,beata,annita,agripina,virgen,valene,twanda,tommye,toi,tarra,tari,tammera,shakia,sadye,ruthanne,rochel,rivka,pura,nenita,natisha,merrilee,melodee,marvis,lucilla,leena,laveta,larita,lanie,keren,ileen,georgeann,genna,frida,ewa,eufemia,emely,ela,edyth,deonna,deadra,darlena,chanell,cathern,cassondra,cassaundra,bernarda,berna,arlinda,anamaria,vertie,valeri,torri,tatyana,stasia,sherise,sherill,sanda,ruthe,rosy,robbi,ranee,quyen,pearly,palmira,onita,nisha,niesha,nida,nam,merlyn,mayola,marylouise,marth,margene,madelaine,londa,leontine,leoma,leia,lauralee,lanora,lakita,kiyoko,keturah,katelin,kareen,jonie,johnette,jenee,jeanett,izetta,hiedi,heike,hassie,giuseppina,georgann,fidela,fernande,elwanda,ellamae,eliz,dusti,dotty,cyndy,coralie,celesta,argentina,alverta,xenia,wava,vanetta,torrie,tashina,tandy,tambra,tama,stepanie,shila,shaunta,sharan,shaniqua,shae,setsuko,serafina,sandee,rosamaria,priscila,olinda,nadene,muoi,michelina,mercedez,maryrose,marcene,mao,magali,mafalda,lannie,kayce,karoline,kamilah,kamala,justa,joline,jennine,jacquetta,iraida,georgeanna,franchesca,emeline,elane,ehtel,earlie,dulcie,dalene,classie,chere,charis,caroyln,carmina,carita,bethanie,ayako,arica,alysa,alessandra,akilah,adrien,zetta,youlanda,yelena,yahaira,wendolyn,tijuana,terina,teresia,suzi,sherell,shavonda,shaunte,sharda,shakita,sena,ryann,rubi,riva,reginia,rachal,parthenia,pamula,monnie,monet,michaele,melia,malka,maisha,lisandra,lekisha,lean,lakendra,krystin,kortney,kizzie,kittie,kera,kendal,kemberly,kanisha,julene,jule,johanne,jamee,halley,gidget,galina,fredricka,fleta,fatimah,eusebia,elza,eleonore,dorthey,doria,donella,dinorah,delorse,claretha,christinia,charlyn,bong,belkis,azzie,andera,aiko,adena,yer,yajaira,wan,vania,ulrike,toshia,tifany,stefany,shizue,shenika,shawanna,sharolyn,sharilyn,shaquana,shantay,rozanne,roselee,remona,reanna,raelene,phung,petronila,natacha,nancey,myrl,miyoko,miesha,merideth,marvella,marquitta,marhta,marchelle,lizeth,libbie,lahoma,ladawn,kina,katheleen,katharyn,karisa,kaleigh,junie,julieann,johnsie,janean,jaimee,jackqueline,hisako,herma,helaine,gwyneth,gita,eustolia,emelina,elin,edris,donnette,donnetta,dierdre,denae,darcel,clarisa,cinderella,chia,charlesetta,charita,celsa,cassy,cassi,carlee,bruna,brittaney,brande,billi,bao,antonetta,angla,angelyn,analisa,alane,wenona,wendie,veronique,vannesa,tobie,tempie,sumiko,sulema,sparkle,somer,sheba,sharice,shanel,shalon,rosio,roselia,renay,rema,reena,ozie,oretha,oralee,oda,ngan,nakesha,milly,marybelle,margrett,maragaret,manie,lurlene,lillia,lieselotte,lavelle,lashaunda,lakeesha,kaycee,kalyn,joya,joette,jenae,janiece,illa,grisel,glayds,genevie,gala,fredda,eleonor,debera,deandrea,corrinne,cordia,contessa,colene,cleotilde,chantay,cecille,beatris,azalee,arlean,ardath,anjelica,anja,alfredia,aleisha,zada,yuonne,willodean,vennie,vanna,tyisha,tova,torie,tonisha,tilda,tien,sirena,sherril,shanti,senaida,samella,robbyn,renda,reita,phebe,paulita,nobuko,nguyet,neomi,mikaela,melania,maximina,marg,maisie,lynna,lilli,lashaun,lakenya,lael,kirstie,kathline,kasha,karlyn,karima,jovan,josefine,jennell,jacqui,jackelyn,hyo,hien,grazyna,florrie,floria,eleonora,dwana,dorla,delmy,deja,dede,dann,crysta,clelia,claris,chieko,cherlyn,cherelle,charmain,chara,cammy,bee,arnette,ardelle,annika,amiee,amee,allena,yvone,yuki,yoshie,yevette,yael,willetta,voncile,venetta,tula,tonette,timika,temika,telma,teisha,taren,stacee,shawnta,saturnina,ricarda,pok,pasty,onie,nubia,marielle,mariella,marianela,mardell,luanna,loise,lisabeth,lindsy,lilliana,lilliam,lelah,leigha,leanora,kristeen,khalilah,keeley,kandra,junko,joaquina,jerlene,jani,jamika,hsiu,hermila,genevive,evia,eugena,emmaline,elfreda,elene,donette,delcie,deeanna,darcey,cuc,clarinda,cira,chae,celinda,catheryn,casimira,carmelia,camellia,breana,bobette,bernardina,bebe,basilia,arlyne,amal,alayna,zonia,zenia,yuriko,yaeko,wynell,willena,vernia,tora,terrilyn,terica,tenesha,tawna,tajuana,taina,stephnie,sona,sina,shondra,shizuko,sherlene,sherice,sharika,rossie,rosena,rima,ria,rheba,renna,natalya,nancee,melodi,meda,matha,marketta,maricruz,marcelene,malvina,luba,louetta,leida,lecia,lauran,lashawna,laine,khadijah,katerine,kasi,kallie,julietta,jesusita,jestine,jessia,jeffie,janyce,isadora,georgianne,fidelia,evita,eura,eulah,estefana,elsy,eladia,dodie,dia,denisse,deloras,delila,daysi,crystle,concha,claretta,charlsie,charlena,carylon,bettyann,asley,ashlea,amira,agueda,agnus,yuette,vinita,victorina,tynisha,treena,toccara,tish,thomasena,tegan,soila,shenna,sharmaine,shantae,shandi,september,saran,sarai,sana,rosette,rolande,regine,otelia,olevia,nicholle,necole,naida,myrta,myesha,mitsue,minta,mertie,margy,mahalia,madalene,loura,lorean,lesha,leonida,lenita,lavone,lashell,lashandra,lamonica,kimbra,katherina,karry,kanesha,jong,jeneva,jaquelyn,hwa,gilma,ghislaine,gertrudis,fransisca,fermina,ettie,etsuko,ellan,elidia,edra,dorethea,doreatha,denyse,deetta,daine,cyrstal,corrin,cayla,carlita,camila,burma,bula,buena,barabara,avril,alaine,zana,wilhemina,wanetta,veronika,verline,vasiliki,tonita,tisa,teofila,tayna,taunya,tandra,takako,sunni,suanne,sixta,sharell,seema,rosenda,robena,raymonde,pei,pamila,ozell,neida,mistie,micha,merissa,maurita,maryln,maryetta,marcell,malena,makeda,lovetta,lourie,lorrine,lorilee,laurena,lashay,larraine,laree,lacresha,kristle,krishna,keva,keira,karole,joie,jinny,jeannetta,jama,heidy,gilberte,gema,faviola,evelynn,enda,elli,ellena,divina,dagny,collene,codi,cindie,chassidy,chasidy,catrice,catherina,cassey,caroll,carlena,candra,calista,bryanna,britteny,beula,bari,audrie,audria,ardelia,annelle,angila,alona,allyn".split(","))), p("surnames",s("smith,johnson,williams,jones,brown,davis,miller,wilson,moore,taylor,anderson,jackson,white,harris,martin,thompson,garcia,martinez,robinson,clark,rodriguez,lewis,lee,walker,hall,allen,young,hernandez,king,wright,lopez,hill,green,adams,baker,gonzalez,nelson,carter,mitchell,perez,roberts,turner,phillips,campbell,parker,evans,edwards,collins,stewart,sanchez,morris,rogers,reed,cook,morgan,bell,murphy,bailey,rivera,cooper,richardson,cox,howard,ward,torres,peterson,gray,ramirez,watson,brooks,sanders,price,bennett,wood,barnes,ross,henderson,coleman,jenkins,perry,powell,long,patterson,hughes,flores,washington,butler,simmons,foster,gonzales,bryant,alexander,griffin,diaz,hayes,myers,ford,hamilton,graham,sullivan,wallace,woods,cole,west,owens,reynolds,fisher,ellis,harrison,gibson,mcdonald,cruz,marshall,ortiz,gomez,murray,freeman,wells,webb,simpson,stevens,tucker,porter,hicks,crawford,boyd,mason,morales,kennedy,warren,dixon,ramos,reyes,burns,gordon,shaw,holmes,rice,robertson,hunt,daniels,palmer,mills,nichols,grant,ferguson,stone,hawkins,dunn,perkins,hudson,spencer,gardner,stephens,payne,pierce,berry,matthews,arnold,wagner,willis,watkins,olson,carroll,duncan,snyder,hart,cunningham,lane,andrews,ruiz,harper,fox,riley,armstrong,carpenter,weaver,greene,elliott,chavez,sims,peters,kelley,franklin,lawson,fields,gutierrez,schmidt,carr,vasquez,castillo,wheeler,chapman,oliver,montgomery,richards,williamson,johnston,banks,meyer,bishop,mccoy,howell,alvarez,morrison,hansen,fernandez,garza,burton,nguyen,jacobs,reid,fuller,lynch,garrett,romero,welch,larson,frazier,burke,hanson,mendoza,moreno,bowman,medina,fowler,brewer,hoffman,carlson,silva,pearson,holland,fleming,jensen,vargas,byrd,davidson,hopkins,may,herrera,wade,soto,walters,neal,caldwell,lowe,jennings,barnett,graves,jimenez,horton,shelton,barrett,obrien,castro,sutton,mckinney,lucas,miles,rodriquez,chambers,holt,lambert,fletcher,watts,bates,hale,rhodes,pena,beck,newman,haynes,mcdaniel,mendez,bush,vaughn,parks,dawson,santiago,norris,hardy,steele,curry,powers,schultz,barker,guzman,page,munoz,ball,keller,chandler,weber,walsh,lyons,ramsey,wolfe,schneider,mullins,benson,sharp,bowen,barber,cummings,hines,baldwin,griffith,valdez,hubbard,salazar,reeves,warner,stevenson,burgess,santos,tate,cross,garner,mann,mack,moss,thornton,mcgee,farmer,delgado,aguilar,vega,glover,manning,cohen,harmon,rodgers,robbins,newton,blair,higgins,ingram,reese,cannon,strickland,townsend,potter,goodwin,walton,rowe,hampton,ortega,patton,swanson,goodman,maldonado,yates,becker,erickson,hodges,rios,conner,adkins,webster,malone,hammond,flowers,cobb,moody,quinn,pope,osborne,mccarthy,guerrero,estrada,sandoval,gibbs,gross,fitzgerald,stokes,doyle,saunders,wise,colon,gill,alvarado,greer,padilla,waters,nunez,ballard,schwartz,mcbride,houston,christensen,klein,pratt,briggs,parsons,mclaughlin,zimmerman,french,buchanan,moran,copeland,pittman,brady,mccormick,holloway,brock,poole,logan,bass,marsh,drake,wong,jefferson,park,morton,abbott,sparks,norton,huff,massey,figueroa,carson,bowers,roberson,barton,tran,lamb,harrington,boone,cortez,clarke,mathis,singleton,wilkins,cain,underwood,hogan,mckenzie,collier,luna,phelps,mcguire,bridges,wilkerson,nash,summers,atkins,wilcox,pitts,conley,marquez,burnett,cochran,chase,davenport,hood,gates,ayala,sawyer,vazquez,dickerson,hodge,acosta,flynn,espinoza,nicholson,monroe,morrow,whitaker,oconnor,skinner,ware,molina,kirby,huffman,gilmore,dominguez,oneal,lang,combs,kramer,hancock,gallagher,gaines,shaffer,short,wiggins,mathews,mcclain,fischer,wall,small,melton,hensley,bond,dyer,grimes,contreras,wyatt,baxter,snow,mosley,shepherd,larsen,hoover,beasley,petersen,whitehead,meyers,garrison,shields,horn,savage,olsen,schroeder,hartman,woodard,mueller,kemp,deleon,booth,patel,calhoun,wiley,eaton,cline,navarro,harrell,humphrey,parrish,duran,hutchinson,hess,dorsey,bullock,robles,beard,dalton,avila,rich,blackwell,york,johns,blankenship,trevino,salinas,campos,pruitt,callahan,montoya,hardin,guerra,mcdowell,stafford,gallegos,henson,wilkinson,booker,merritt,atkinson,orr,decker,hobbs,tanner,knox,pacheco,stephenson,glass,rojas,serrano,marks,hickman,english,sweeney,strong,mcclure,conway,roth,maynard,farrell,lowery,hurst,nixon,weiss,trujillo,ellison,sloan,juarez,winters,mclean,boyer,villarreal,mccall,gentry,carrillo,ayers,lara,sexton,pace,hull,leblanc,browning,velasquez,leach,chang,sellers,herring,noble,foley,bartlett,mercado,landry,durham,walls,barr,mckee,bauer,rivers,bradshaw,pugh,velez,rush,estes,dodson,morse,sheppard,weeks,camacho,bean,barron,livingston,middleton,spears,branch,blevins,chen,kerr,mcconnell,hatfield,harding,solis,frost,giles,blackburn,pennington,woodward,finley,mcintosh,koch,mccullough,blanchard,rivas,brennan,mejia,kane,benton,buckley,valentine,maddox,russo,mcknight,buck,moon,mcmillan,crosby,berg,dotson,mays,roach,church,chan,richmond,meadows,faulkner,oneill,knapp,kline,ochoa,jacobson,gay,hendricks,horne,shepard,hebert,cardenas,mcintyre,waller,holman,donaldson,cantu,morin,gillespie,fuentes,tillman,bentley,peck,key,salas,rollins,gamble,dickson,battle,santana,cabrera,cervantes,howe,hinton,hurley,spence,zamora,yang,mcneil,suarez,petty,gould,mcfarland,sampson,carver,bray,macdonald,stout,hester,melendez,dillon,farley,hopper,galloway,potts,joyner,stein,aguirre,osborn,mercer,bender,franco,rowland,sykes,pickett,sears,mayo,dunlap,hayden,wilder,mckay,coffey,mccarty,ewing,cooley,vaughan,bonner,cotton,holder,stark,ferrell,cantrell,fulton,lott,calderon,pollard,hooper,burch,mullen,fry,riddle,levy,odonnell,britt,daugherty,berger,dillard,alston,frye,riggs,chaney,odom,duffy,fitzpatrick,valenzuela,mayer,alford,mcpherson,acevedo,barrera,cote,reilly,compton,mooney,mcgowan,craft,clemons,wynn,nielsen,baird,stanton,snider,rosales,bright,witt,hays,holden,rutledge,kinney,clements,castaneda,slater,hahn,burks,delaney,pate,lancaster,sharpe,whitfield,talley,macias,burris,ratliff,mccray,madden,kaufman,goff,cash,bolton,mcfadden,levine,byers,kirkland,kidd,workman,carney,mcleod,holcomb,england,finch,sosa,haney,franks,sargent,nieves,downs,rasmussen,bird,hewitt,foreman,valencia,oneil,delacruz,vinson,dejesus,hyde,forbes,gilliam,guthrie,wooten,huber,barlow,boyle,mcmahon,buckner,rocha,puckett,langley,knowles,cooke,velazquez,whitley,vang,shea,rouse,hartley,mayfield,elder,rankin,hanna,cowan,lucero,arroyo,slaughter,haas,oconnell,minor,boucher,archer,boggs,dougherty,andersen,newell,crowe,wang,friedman,bland,swain,holley,pearce,childs,yarbrough,galvan,proctor,meeks,lozano,mora,rangel,bacon,villanueva,schaefer,rosado,helms,boyce,goss,stinson,lake,ibarra,hutchins,covington,crowley,hatcher,mackey,bunch,womack,polk,dodd,childress,childers,camp,villa,dye,springer,mahoney,dailey,belcher,lockhart,griggs,costa,brandt,walden,moser,tatum,mccann,akers,lutz,pryor,orozco,mcallister,lugo,davies,shoemaker,rutherford,newsome,magee,chamberlain,blanton,simms,godfrey,flanagan,crum,cordova,escobar,downing,sinclair,donahue,krueger,mcginnis,gore,farris,webber,corbett,andrade,starr,lyon,yoder,hastings,mcgrath,spivey,krause,harden,crabtree,kirkpatrick,arrington,ritter,mcghee,bolden,maloney,gagnon,dunbar,ponce,pike,mayes,beatty,mobley,kimball,butts,montes,eldridge,braun,hamm,gibbons,moyer,manley,herron,plummer,elmore,cramer,rucker,pierson,fontenot,field,rubio,goldstein,elkins,wills,novak,hickey,worley,gorman,katz,dickinson,broussard,woodruff,crow,britton,nance,lehman,bingham,zuniga,whaley,shafer,coffman,steward,delarosa,nix,neely,mata,davila,mccabe,kessler,hinkle,welsh,pagan,goldberg,goins,crouch,cuevas,quinones,mcdermott,hendrickson,samuels,denton,bergeron,lam,ivey,locke,haines,snell,hoskins,byrne,arias,roe,corbin,beltran,chappell,downey,dooley,tuttle,couch,payton,mcelroy,crockett,groves,cartwright,dickey,mcgill,dubois,muniz,tolbert,dempsey,cisneros,sewell,latham,vigil,tapia,rainey,norwood,stroud,meade,tipton,kuhn,hilliard,bonilla,teague,gunn,greenwood,correa,reece,poe,pineda,phipps,frey,kaiser,ames,gunter,schmitt,milligan,espinosa,bowden,vickers,lowry,pritchard,costello,piper,mcclellan,lovell,sheehan,hatch,dobson,singh,jeffries,hollingsworth,sorensen,meza,fink,donnelly,burrell,tomlinson,colbert,billings,ritchie,helton,sutherland,peoples,mcqueen,thomason,givens,crocker,vogel,robison,dunham,coker,swartz,keys,ladner,richter,hargrove,edmonds,brantley,albright,murdock,boswell,muller,quintero,padgett,kenney,daly,connolly,inman,quintana,lund,barnard,villegas,simons,land,huggins,tidwell,sanderson,bullard,mcclendon,duarte,draper,marrero,dwyer,abrams,stover,goode,fraser,crews,bernal,godwin,conklin,mcneal,baca,esparza,crowder,bower,brewster,mcneill,rodrigues,leal,coates,raines,mccain,mccord,miner,holbrook,swift,dukes,carlisle,aldridge,ackerman,starks,ricks,holliday,ferris,hairston,sheffield,lange,fountain,doss,betts,kaplan,carmichael,bloom,ruffin,penn,kern,bowles,sizemore,larkin,dupree,seals,metcalf,hutchison,henley,farr,mccauley,hankins,gustafson,curran,ash,waddell,ramey,cates,pollock,cummins,messer,heller,lin,funk,cornett,palacios,galindo,cano,hathaway,singer,pham,enriquez,salgado,pelletier,painter,wiseman,blount,feliciano,temple,houser,doherty,mead,mcgraw,swan,capps,blanco,blackmon,thomson,mcmanus,burkett,post,gleason,ott,dickens,cormier,voss,rushing,rosenberg,hurd,dumas,benitez,arellano,marin,caudill,bragg,jaramillo,huerta,gipson,colvin,biggs,vela,platt,cassidy,tompkins,mccollum,dolan,daley,crump,sneed,kilgore,grove,grimm,davison,brunson,prater,marcum,devine,stratton,rosas,choi,tripp,ledbetter,hightower,feldman,epps,yeager,posey,scruggs,cope,stubbs,richey,overton,trotter,sprague,cordero,butcher,stiles,burgos,woodson,horner,bassett,purcell,haskins,akins,ziegler,spaulding,hadley,grubbs,sumner,murillo,zavala,shook,lockwood,driscoll,dahl,thorpe,redmond,putnam,mcwilliams,mcrae,romano,joiner,sadler,hedrick,hager,hagen,fitch,coulter,thacker,mansfield,langston,guidry,ferreira,corley,conn,rossi,lackey,baez,saenz,mcnamara,mcmullen,mckenna,mcdonough,link,engel,browne,roper,peacock,eubanks,drummond,stringer,pritchett,parham,mims,landers,ham,grayson,schafer,egan,timmons,ohara,keen,hamlin,finn,cortes,mcnair,nadeau,moseley,michaud,rosen,oakes,kurtz,jeffers,calloway,beal,bautista,winn,suggs,stern,stapleton,lyles,laird,montano,dawkins,hagan,goldman,bryson,barajas,lovett,segura,metz,lockett,langford,hinson,eastman,hooks,smallwood,shapiro,crowell,whalen,triplett,chatman,aldrich,cahill,youngblood,ybarra,stallings,sheets,reeder,connelly,bateman,abernathy,winkler,wilkes,masters,hackett,granger,gillis,schmitz,sapp,napier,souza,lanier,gomes,weir,otero,ledford,burroughs,babcock,ventura,siegel,dugan,bledsoe,atwood,wray,varner,spangler,anaya,staley,kraft,fournier,belanger,wolff,thorne,bynum,burnette,boykin,swenson,purvis,pina,khan,duvall,darby,xiong,kauffman,healy,engle,benoit,valle,steiner,spicer,shaver,randle,lundy,dow,chin,calvert,staton,neff,kearney,darden,oakley,medeiros,mccracken,crenshaw,block,perdue,dill,whittaker,tobin,washburn,hogue,goodrich,easley,bravo,dennison,shipley,kerns,jorgensen,crain,villalobos,maurer,longoria,keene,coon,witherspoon,staples,pettit,kincaid,eason,madrid,echols,lusk,stahl,currie,thayer,shultz,mcnally,seay,north,maher,gagne,barrow,nava,moreland,honeycutt,hearn,diggs,caron,whitten,westbrook,stovall,ragland,munson,meier,looney,kimble,jolly,hobson,goddard,culver,burr,presley,negron,connell,tovar,huddleston,ashby,salter,root,pendleton,oleary,nickerson,myrick,judd,jacobsen,bain,adair,starnes,matos,busby,herndon,hanley,bellamy,doty,bartley,yazzie,rowell,parson,gifford,cullen,christiansen,benavides,barnhart,talbot,mock,crandall,connors,bonds,whitt,gage,bergman,arredondo,addison,lujan,dowdy,jernigan,huynh,bouchard,dutton,rhoades,ouellette,kiser,herrington,hare,blackman,babb,allred,rudd,paulson,ogden,koenig,geiger,begay,parra,lassiter,hawk,esposito,cho,waldron,ransom,prather,chacon,vick,sands,roark,parr,mayberry,greenberg,coley,bruner,whitman,skaggs,shipman,leary,hutton,romo,medrano,ladd,kruse,askew,schulz,alfaro,tabor,mohr,gallo,bermudez,pereira,bliss,reaves,flint,comer,woodall,naquin,guevara,delong,carrier,pickens,brand,tilley,schaffer,lim,knutson,fenton,doran,chu,vogt,vann,prescott,mclain,landis,corcoran,zapata,hyatt,hemphill,faulk,dove,boudreaux,aragon,whitlock,trejo,tackett,shearer,saldana,hanks,mckinnon,koehler,bourgeois,keyes,goodson,foote,lunsford,goldsmith,flood,winslow,sams,reagan,mccloud,hough,esquivel,naylor,loomis,coronado,ludwig,braswell,bearden,fagan,ezell,edmondson,cyr,cronin,nunn,lemon,guillory,grier,dubose,traylor,ryder,dobbins,coyle,aponte,whitmore,smalls,rowan,malloy,cardona,braxton,borden,humphries,carrasco,ruff,metzger,huntley,hinojosa,finney,madsen,hills,ernst,dozier,burkhart,bowser,peralta,daigle,whittington,sorenson,saucedo,roche,redding,fugate,avalos,waite,lind,huston,hay,hawthorne,hamby,boyles,boles,regan,faust,crook,beam,barger,hinds,gallardo,willoughby,willingham,eckert,busch,zepeda,worthington,tinsley,hoff,hawley,carmona,varela,rector,newcomb,kinsey,dube,whatley,ragsdale,bernstein,becerra,yost,mattson,felder,cheek,handy,grossman,gauthier,escobedo,braden,beckman,mott,hillman,flaherty,dykes,doe,stockton,stearns,lofton,coats,cavazos,beavers,barrios,parish,mosher,cardwell,coles,burnham,weller,lemons,beebe,aguilera,parnell,harman,couture,alley,schumacher,redd,dobbs,blum,blalock,merchant,ennis,denson,cottrell,brannon,bagley,aviles,watt,sousa,rosenthal,rooney,dietz,blank,paquette,mcclelland,duff,velasco,lentz,grubb,burrows,barbour,ulrich,shockley,rader,beyer,mixon,layton,altman,weathers,stoner,squires,shipp,priest,lipscomb,cutler,caballero,zimmer,willett,thurston,storey,medley,epperson,shah,mcmillian,baggett,torrez,laws,hirsch,dent,poirier,peachey,farrar,creech,barth,trimble,dupre,albrecht,sample,lawler,crisp,conroy,wetzel,nesbitt,murry,jameson,wilhelm,patten,minton,matson,kimbrough,iverson,guinn,croft,toth,pulliam,nugent,newby,littlejohn,dias,canales,bernier,baron,singletary,renteria,pruett,mchugh,mabry,landrum,brower,stoddard,cagle,stjohn,scales,kohler,kellogg,hopson,gant,tharp,gann,zeigler,pringle,hammons,fairchild,deaton,chavis,carnes,rowley,matlock,kearns,irizarry,carrington,starkey,lopes,jarrell,craven,baum,spain,littlefield,linn,humphreys,etheridge,cuellar,chastain,bundy,speer,skelton,quiroz,pyle,portillo,ponder,moulton,machado,liu,killian,hutson,hitchcock,dowling,cloud,burdick,spann,pedersen,levin,leggett,hayward,hacker,dietrich,beaulieu,barksdale,wakefield,snowden,briscoe,bowie,berman,ogle,mcgregor,laughlin,helm,burden,wheatley,schreiber,pressley,parris,alaniz,agee,urban,swann,snodgrass,schuster,radford,monk,mattingly,harp,girard,cheney,yancey,wagoner,ridley,lombardo,lau,hudgins,gaskins,duckworth,coe,coburn,willey,prado,newberry,magana,hammonds,elam,whipple,slade,serna,ojeda,liles,dorman,diehl,upton,reardon,michaels,goetz,eller,bauman,baer,layne,hummel,brenner,amaya,adamson,ornelas,dowell,cloutier,castellanos,wing,wellman,saylor,orourke,moya,montalvo,kilpatrick,durbin,shell,oldham,garvin,foss,branham,bartholomew,templeton,maguire,holton,rider,monahan,mccormack,beaty,anders,streeter,nieto,nielson,moffett,lankford,keating,heck,gatlin,delatorre,callaway,adcock,worrell,unger,robinette,nowak,jeter,brunner,steen,parrott,overstreet,nobles,montanez,clevenger,brinkley,trahan,quarles,pickering,pederson,jansen,grantham,gilchrist,crespo,aiken,schell,schaeffer,lorenz,leyva,harms,dyson,wallis,pease,leavitt,cavanaugh,batts,warden,seaman,rockwell,quezada,paxton,linder,houck,fontaine,durant,caruso,adler,pimentel,mize,lytle,cleary,cason,acker,switzer,isaacs,higginbotham,han,waterman,vandyke,stamper,sisk,shuler,riddick,mcmahan,levesque,hatton,bronson,bollinger,arnett,okeefe,gerber,gannon,farnsworth,baughman,silverman,satterfield,mccrary,kowalski,grigsby,greco,cabral,trout,rinehart,mahon,linton,gooden,curley,baugh,wyman,weiner,schwab,schuler,morrissey,mahan,bunn,thrasher,spear,waggoner,qualls,purdy,mcwhorter,mauldin,gilman,perryman,newsom,menard,martino,graf,billingsley,artis,simpkins,salisbury,quintanilla,gilliland,fraley,foust,crouse,scarborough,ngo,grissom,fultz,marlow,markham,madrigal,lawton,barfield,whiting,varney,schwarz,gooch,arce,wheat,truong,poulin,hurtado,selby,gaither,fortner,culpepper,coughlin,brinson,boudreau,barkley,bales,stepp,holm,tan,schilling,morrell,kahn,heaton,gamez,causey,turpin,shanks,schrader,meek,isom,hardison,carranza,yanez,scroggins,schofield,runyon,ratcliff,murrell,moeller,irby,currier,butterfield,yee,ralston,pullen,pinson,estep,carbone,hawks,ellington,casillas,spurlock,sikes,motley,mccartney,kruger,isbell,houle,burk,tomlin,quigley,neumann,lovelace,fennell,cheatham,bustamante,skidmore,hidalgo,forman,culp,bowens,betancourt,aquino,robb,rea,milner,martel,gresham,wiles,ricketts,dowd,collazo,bostic,blakely,sherrod,kenyon,gandy,ebert,deloach,allard,sauer,robins,olivares,gillette,chestnut,bourque,paine,hite,hauser,devore,crawley,chapa,talbert,poindexter,meador,mcduffie,mattox,kraus,harkins,choate,wren,sledge,sanborn,kinder,geary,cornwell,barclay,abney,seward,rhoads,howland,fortier,benner,vines,tubbs,troutman,rapp,mccurdy,deluca,westmoreland,havens,guajardo,ely,clary,seal,meehan,herzog,guillen,ashcraft,waugh,renner,milam,elrod,churchill,breaux,bolin,asher,windham,tirado,pemberton,nolen,noland,knott,emmons,cornish,christenson,brownlee,barbee,waldrop,pitt,olvera,lombardi,gruber,gaffney,eggleston,banda,archuleta,slone,prewitt,pfeiffer,nettles,mena,mcadams,henning,gardiner,cromwell,chisholm,burleson,vest,oglesby,mccarter,lumpkin,grey,wofford,vanhorn,thorn,teel,swafford,stclair,stanfield,ocampo,herrmann,hannon,arsenault,roush,mcalister,hiatt,gunderson,forsythe,duggan,delvalle,cintron,wilks,weinstein,uribe,rizzo,noyes,mclendon,gurley,bethea,winstead,maples,guyton,giordano,alderman,valdes,polanco,pappas,lively,grogan,griffiths,arevalo,whitson,sowell,rendon,fernandes,farrow,benavidez,ayres,alicea,stump,smalley,seitz,schulte,gilley,gallant,canfield,wolford,omalley,mcnutt,mcnulty,mcgovern,hardman,harbin,cowart,chavarria,brink,beckett,bagwell,armstead,anglin,abreu,reynoso,krebs,jett,hoffmann,greenfield,forte,burney,broome,sisson,trammell,partridge,mace,lomax,lemieux,gossett,frantz,fogle,cooney,broughton,pence,paulsen,muncy,mcarthur,hollins,beauchamp,withers,osorio,mulligan,hoyle,foy,dockery,cockrell,begley,amador,roby,rains,lindquist,gentile,everhart,bohannon,wylie,sommers,purnell,fortin,dunning,breeden,vail,phelan,phan,marx,cosby,colburn,boling,biddle,ledesma,gaddis,denney,chow,bueno,berrios,wicker,tolliver,thibodeaux,nagle,lavoie,fisk,crist,barbosa,reedy,march,locklear,kolb,himes,behrens,beckwith,weems,wahl,shorter,shackelford,rees,muse,cerda,valadez,thibodeau,saavedra,ridgeway,reiter,mchenry,majors,lachance,keaton,ferrara,clemens,blocker,applegate,paz,needham,mojica,kuykendall,hamel,escamilla,doughty,burchett,ainsworth,vidal,upchurch,thigpen,strauss,spruill,sowers,riggins,ricker,mccombs,harlow,buffington,sotelo,olivas,negrete,morey,macon,logsdon,lapointe,bigelow,bello,westfall,stubblefield,peak,lindley,hein,hawes,farrington,breen,birch,wilde,steed,sepulveda,reinhardt,proffitt,minter,messina,mcnabb,maier,keeler,gamboa,donohue,basham,shinn,crooks,cota,borders,bills,bachman,tisdale,tavares,schmid,pickard,gulley,fonseca,delossantos,condon,batista,wicks,wadsworth,martell,littleton,ison,haag,folsom,brumfield,broyles,brito,mireles,mcdonnell,leclair,hamblin,gough,fanning,binder,winfield,whitworth,soriano,palumbo,newkirk,mangum,hutcherson,comstock,carlin,beall,bair,wendt,watters,walling,putman,otoole,morley,mares,lemus,keener,hundley,dial,damico,billups,strother,mcfarlane,lamm,eaves,crutcher,caraballo,canty,atwell,taft,siler,rust,rawls,rawlings,prieto,mcneely,mcafee,hulsey,hackney,galvez,escalante,delagarza,crider,charlton,bandy,wilbanks,stowe,steinberg,renfro,masterson,massie,lanham,haskell,hamrick,fort,dehart,burdette,branson,bourne,babin,aleman,worthy,tibbs,smoot,slack,paradis,mull,luce,houghton,gantt,furman,danner,christianson,burge,ashford,arndt,almeida,stallworth,shade,searcy,sager,noonan,mclemore,mcintire,maxey,lavigne,jobe,ferrer,falk,coffin,byrnes,aranda,apodaca,stamps,rounds,peek,olmstead,lewandowski,kaminski,dunaway,bruns,brackett,amato,reich,mcclung,lacroix,koontz,herrick,hardesty,flanders,cousins,cato,cade,vickery,shank,nagel,dupuis,croteau,cotter,cable,stuckey,stine,porterfield,pauley,nye,moffitt,knudsen,hardwick,goforth,dupont,blunt,barrows,barnhill,shull,rash,loftis,lemay,kitchens,horvath,grenier,fuchs,fairbanks,culbertson,calkins,burnside,beattie,ashworth,albertson,wertz,vaught,vallejo,turk,tuck,tijerina,sage,peterman,marroquin,marr,lantz,hoang,demarco,daily,cone,berube,barnette,wharton,stinnett,slocum,scanlon,sander,pinto,mancuso,lima,headley,epstein,counts,clarkson,carnahan,boren,arteaga,adame,zook,whittle,whitehurst,wenzel,saxton,reddick,puente,handley,haggerty,earley,devlin,chaffin,cady,acuna,solano,sigler,pollack,pendergrass,ostrander,janes,francois,crutchfield,chamberlin,brubaker,baptiste,willson,reis,neeley,mullin,mercier,lira,layman,keeling,higdon,espinal,chapin,warfield,toledo,pulido,peebles,nagy,montague,mello,lear,jaeger,hogg,graff,furr,soliz,poore,mendenhall,mclaurin,maestas,gable,barraza,tillery,snead,pond,neill,mcculloch,mccorkle,lightfoot,hutchings,holloman,harness,dorn,council,bock,zielinski,turley,treadwell,stpierre,starling,somers,oswald,merrick,easterling,bivens,truitt,poston,parry,ontiveros,olivarez,moreau,medlin,lenz,knowlton,fairley,cobbs,chisolm,bannister,woodworth,toler,ocasio,noriega,neuman,moye,milburn,mcclanahan,lilley,hanes,flannery,dellinger,danielson,conti,blodgett,beers,weatherford,strain,karr,hitt,denham,custer,coble,clough,casteel,bolduc,batchelor,ammons,whitlow,tierney,staten,sibley,seifert,schubert,salcedo,mattison,laney,haggard,grooms,dix,dees,cromer,cooks,colson,caswell,zarate,swisher,shin,ragan,pridgen,mcvey,matheny,lafleur,franz,ferraro,dugger,whiteside,rigsby,mcmurray,lehmann,jacoby,hildebrand,hendrick,headrick,goad,fincher,drury,borges,archibald,albers,woodcock,trapp,soares,seaton,monson,luckett,lindberg,kopp,keeton,hsu,healey,garvey,gaddy,fain,burchfield,wentworth,strand,stack,spooner,saucier,sales,ricci,plunkett,pannell,ness,leger,hoy,freitas,fong,elizondo,duval,beaudoin,urbina,rickard,partin,moe,mcgrew,mcclintock,ledoux,forsyth,faison,devries,bertrand,wasson,tilton,scarbrough,leung,irvine,garber,denning,corral,colley,castleberry,bowlin,bogan,beale,baines,trice,rayburn,parkinson,pak,nunes,mcmillen,leahy,kimmel,higgs,fulmer,carden,bedford,taggart,spearman,register,prichard,morrill,koonce,heinz,hedges,guenther,grice,findley,dover,creighton,boothe,bayer,arreola,vitale,valles,raney,osgood,hanlon,burley,bounds,worden,weatherly,vetter,tanaka,stiltner,nevarez,mosby,montero,melancon,harter,hamer,goble,gladden,gist,ginn,akin,zaragoza,towns,tarver,sammons,royster,oreilly,muir,morehead,luster,kingsley,kelso,grisham,glynn,baumann,alves,yount,tamayo,paterson,oates,menendez,longo,hargis,gillen,desantis,breedlove,sumpter,scherer,rupp,reichert,heredia,creel,cohn,clemmons,casas,bickford,belton,bach,williford,whitcomb,tennant,sutter,stull,sessions,mccallum,langlois,keel,keegan,dangelo,dancy,damron,clapp,clanton,bankston,oliveira,mintz,mcinnis,martens,mabe,laster,jolley,hildreth,hefner,glaser,duckett,demers,brockman,blais,alcorn,agnew,toliver,tice,seeley,najera,musser,mcfall,laplante,galvin,fajardo,doan,coyne,copley,clawson,cheung,barone,wynne,woodley,tremblay,stoll,sparrow,sparkman,schweitzer,sasser,samples,roney,legg,heim,farias,colwell,christman,bratcher,winchester,upshaw,southerland,sorrell,sells,mount,mccloskey,martindale,luttrell,loveless,lovejoy,linares,latimer,embry,coombs,bratton,bostick,venable,tuggle,toro,staggs,sandlin,jefferies,heckman,griffis,crayton,clem,browder,thorton,sturgill,sprouse,royer,rousseau,ridenour,pogue,perales,peeples,metzler,mesa,mccutcheon,mcbee,hornsby,heffner,corrigan,armijo,vue,plante,peyton,paredes,macklin,hussey,hodgson,granados,frias,becnel,batten,almanza,turney,teal,sturgeon,meeker,mcdaniels,limon,keeney,kee,hutto,holguin,gorham,fishman,fierro,blanchette,rodrigue,reddy,osburn,oden,lerma,kirkwood,keefer,haugen,hammett,chalmers,brinkman,baumgartner,valerio,tellez,steffen,shumate,sauls,ripley,kemper,jacks,guffey,evers,craddock,carvalho,blaylock,banuelos,balderas,wooden,wheaton,turnbull,shuman,pointer,mosier,mccue,ligon,kozlowski,johansen,ingle,herr,briones,snipes,rickman,pipkin,pantoja,orosco,moniz,lawless,kunkel,hibbard,galarza,enos,bussey,schott,salcido,perreault,mcdougal,mccool,haight,garris,ferry,easton,conyers,atherton,wimberly,utley,spellman,smithson,slagle,ritchey,rand,petit,osullivan,oaks,nutt,mcvay,mccreary,mayhew,knoll,jewett,harwood,cardoza,ashe,arriaga,zeller,wirth,whitmire,stauffer,rountree,redden,mccaffrey,martz,larose,langdon,humes,gaskin,faber,devito,cass,almond,wingfield,wingate,villareal,tyner,smothers,severson,reno,pennell,maupin,leighton,janssen,hassell,hallman,halcomb,folse,fitzsimmons,fahey,cranford,bolen,battles,battaglia,wooldridge,trask,rosser,regalado,mcewen,keefe,fuqua,echevarria,caro,boynton,andrus,viera,vanmeter,taber,spradlin,seibert,provost,prentice,oliphant,laporte,hwang,hatchett,hass,greiner,freedman,covert,chilton,byars,wiese,venegas,swank,shrader,roberge,mullis,mortensen,mccune,marlowe,kirchner,keck,isaacson,hostetler,halverson,gunther,griswold,fenner,durden,blackwood,ahrens,sawyers,savoy,nabors,mcswain,mackay,loy,lavender,lash,labbe,jessup,fullerton,cruse,crittenden,correia,centeno,caudle,canady,callender,alarcon,ahern,winfrey,tribble,styles,salley,roden,musgrove,minnick,fortenberry,carrion,bunting,batiste,whited,underhill,stillwell,rauch,pippin,perrin,messenger,mancini,lister,kinard,hartmann,fleck,broadway,wilt,treadway,thornhill,spalding,rafferty,pitre,patino,ordonez,linkous,kelleher,homan,galbraith,feeney,curtin,coward,camarillo,buss,bunnell,bolt,beeler,autry,alcala,witte,wentz,stidham,shively,nunley,meacham,martins,lemke,lefebvre,hynes,horowitz,hoppe,holcombe,dunne,derr,cochrane,brittain,bedard,beauregard,torrence,strunk,soria,simonson,shumaker,scoggins,oconner,moriarty,kuntz,ives,hutcheson,horan,hales,garmon,fitts,bohn,atchison,wisniewski,vanwinkle,sturm,sallee,prosser,moen,lundberg,kunz,kohl,keane,jorgenson,jaynes,funderburk,freed,durr,creamer,cosgrove,batson,vanhoose,thomsen,teeter,smyth,redmon,orellana,maness,heflin,goulet,frick,forney,bunker,asbury,aguiar,talbott,southard,mowery,mears,lemmon,krieger,hickson,elston,duong,delgadillo,dayton,dasilva,conaway,catron,bruton,bradbury,bordelon,bivins,bittner,bergstrom,beals,abell,whelan,tejada,pulley,pino,norfleet,nealy,maes,loper,gatewood,frierson,freund,finnegan,cupp,covey,catalano,boehm,bader,yoon,walston,tenney,sipes,rawlins,medlock,mccaskill,mccallister,marcotte,maclean,hughey,henke,harwell,gladney,gilson,dew,chism,caskey,brandenburg,baylor,villasenor,veal,thatcher,stegall,shore,petrie,nowlin,navarrete,muhammad,lombard,loftin,lemaster,kroll,kovach,kimbrell,kidwell,hershberger,fulcher,eng,cantwell,bustos,boland,bobbitt,binkley,wester,weis,verdin,tiller,sisco,sharkey,seymore,rosenbaum,rohr,quinonez,pinkston,nation,malley,logue,lessard,lerner,lebron,krauss,klinger,halstead,haller,getz,burrow,alger,shores,pfeifer,perron,nelms,munn,mcmaster,mckenney,manns,knudson,hutchens,huskey,goebel,flagg,cushman,click,castellano,carder,bumgarner,wampler,spinks,robson,neel,mcreynolds,mathias,maas,loera,kasper,jenson,florez,coons,buckingham,brogan,berryman,wilmoth,wilhite,thrash,shephard,seidel,schulze,roldan,pettis,obryan,maki,mackie,hatley,frazer,fiore,chesser,bui,bottoms,bisson,benefield,allman,wilke,trudeau,timm,shifflett,rau,mundy,milliken,mayers,leake,kohn,huntington,horsley,hermann,guerin,fryer,frizzell,foret,flemming,fife,criswell,carbajal,bozeman,boisvert,angulo,wallen,tapp,silvers,ramsay,oshea,orta,moll,mckeever,mcgehee,linville,kiefer,ketchum,howerton,groce,gass,fusco,corbitt,betz,bartels,amaral,aiello,yoo,weddle,sperry,seiler,runyan,raley,overby,osteen,olds,mckeown,matney,lauer,lattimore,hindman,hartwell,fredrickson,fredericks,espino,clegg,carswell,cambell,burkholder,woodbury,welker,totten,thornburg,theriault,stitt,stamm,stackhouse,scholl,saxon,rife,razo,quinlan,pinkerton,olivo,nesmith,nall,mattos,lafferty,justus,giron,geer,fielder,drayton,dortch,conners,conger,boatwright,billiot,barden,armenta,tibbetts,steadman,slattery,rinaldi,raynor,pinckney,pettigrew,milne,matteson,halsey,gonsalves,fellows,durand,desimone,cowley,cowles,brill,barham,barela,barba,ashmore,withrow,valenti,tejeda,spriggs,sayre,salerno,peltier,peel,merriman,matheson,lowman,lindstrom,hyland,giroux,earls,dugas,dabney,collado,briseno,baxley,whyte,wenger,vanover,vanburen,thiel,schindler,schiller,rigby,pomeroy,passmore,marble,manzo,mahaffey,lindgren,laflamme,greathouse,fite,calabrese,bayne,yamamoto,wick,townes,thames,reinhart,peeler,naranjo,montez,mcdade,mast,markley,marchand,leeper,kellum,hudgens,hennessey,hadden,gainey,coppola,borrego,bolling,beane,ault,slaton,poland,pape,null,mulkey,lightner,langer,hillard,glasgow,ethridge,enright,derosa,baskin,weinberg,turman,somerville,pardo,noll,lashley,ingraham,hiller,hendon,glaze,cothran,cooksey,conte,carrico,abner,wooley,swope,summerlin,sturgis,sturdivant,stott,spurgeon,spillman,speight,roussel,popp,nutter,mckeon,mazza,magnuson,lanning,kozak,jankowski,heyward,forster,corwin,callaghan,bays,wortham,usher,theriot,sayers,sabo,poling,loya,lieberman,laroche,labelle,howes,harr,garay,fogarty,everson,durkin,dominquez,chaves,chambliss,witcher,vieira,vandiver,terrill,stoker,schreiner,moorman,liddell,lew,lawhorn,krug,irons,hylton,hollenbeck,herrin,hembree,goolsby,goodin,gilmer,foltz,dinkins,daughtry,caban,brim,briley,bilodeau,wyant,vergara,tallent,swearingen,stroup,scribner,quillen,pitman,monaco,mccants,maxfield,martinson,holtz,flournoy,brookins,brody,baumgardner,straub,sills,roybal,roundtree,oswalt,mcgriff,mcdougall,mccleary,maggard,gragg,gooding,godinez,doolittle,donato,cowell,cassell,bracken,appel,zambrano,reuter,perea,nakamura,monaghan,mickens,mcclinton,mcclary,marler,kish,judkins,gilbreath,freese,flanigan,felts,erdmann,dodds,chew,brownell,boatright,barreto,slayton,sandberg,saldivar,pettway,odum,narvaez,moultrie,montemayor,merrell,lees,keyser,hoke,hardaway,hannan,gilbertson,fogg,dumont,deberry,coggins,buxton,bucher,broadnax,beeson,araujo,appleton,amundson,aguayo,ackley,yocum,worsham,shivers,sanches,sacco,robey,rhoden,pender,ochs,mccurry,madera,luong,knotts,jackman,heinrich,hargrave,gault,comeaux,chitwood,caraway,boettcher,bernhardt,barrientos,zink,wickham,whiteman,thorp,stillman,settles,schoonover,roque,riddell,pilcher,phifer,novotny,macleod,hardee,haase,grider,doucette,clausen,bevins,beamon,badillo,tolley,tindall,soule,snook,seale,pitcher,pinkney,pellegrino,nowell,nemeth,mondragon,mclane,lundgren,ingalls,hudspeth,hixson,gearhart,furlong,downes,dibble,deyoung,cornejo,camara,brookshire,boyette,wolcott,surratt,sellars,segal,salyer,reeve,rausch,labonte,haro,gower,freeland,fawcett,eads,driggers,donley,collett,bromley,boatman,ballinger,baldridge,volz,trombley,stonge,shanahan,rivard,rhyne,pedroza,matias,jamieson,hedgepeth,hartnett,estevez,eskridge,denman,chiu,chinn,catlett,carmack,buie,bechtel,beardsley,bard,ballou,ulmer,skeen,robledo,rincon,reitz,piazza,munger,moten,mcmichael,loftus,ledet,kersey,groff,fowlkes,folk,crumpton,clouse,bettis,villagomez,timmerman,strom,santoro,roddy,penrod,musselman,macpherson,leboeuf,harless,haddad,guido,golding,fulkerson,fannin,dulaney,dowdell,cottle,ceja,cate,bosley,benge,albritton,voigt,trowbridge,soileau,seely,rohde,pearsall,paulk,orth,nason,mota,mcmullin,marquardt,madigan,hoag,gillum,gabbard,fenwick,eck,danforth,cushing,cress,creed,cazares,casanova,bey,bettencourt,barringer,baber,stansberry,schramm,rutter,rivero,oquendo,necaise,mouton,montenegro,miley,mcgough,marra,macmillan,lamontagne,jasso,horst,hetrick,heilman,gaytan,gall,fortney,dingle,desjardins,dabbs,burbank,brigham,breland,beaman,arriola,yarborough,wallin,toscano,stowers,reiss,pichardo,orton,michels,mcnamee,mccrory,leatherman,kell,keister,horning,hargett,guay,ferro,deboer,dagostino,carper,blanks,beaudry,towle,tafoya,stricklin,strader,soper,sonnier,sigmon,schenk,saddler,pedigo,mendes,lunn,lohr,lahr,kingsbury,jarman,hume,holliman,hofmann,haworth,harrelson,hambrick,flick,edmunds,dacosta,crossman,colston,chaplin,carrell,budd,weiler,waits,valentino,trantham,tarr,solorio,roebuck,powe,plank,pettus,palm,pagano,mink,luker,leathers,joslin,hartzell,gambrell,deutsch,cepeda,carty,caputo,brewington,bedell,ballew,applewhite,warnock,walz,urena,tudor,reel,pigg,parton,mickelson,meagher,mclellan,mcculley,mandel,leech,lavallee,kraemer,kling,kipp,kehoe,hochstetler,harriman,gregoire,grabowski,gosselin,gammon,fancher,edens,desai,brannan,armendariz,woolsey,whitehouse,whetstone,ussery,towne,testa,tallman,studer,strait,steinmetz,sorrells,sauceda,rolfe,paddock,mitchem,mcginn,mccrea,lovato,hazen,gilpin,gaynor,fike,devoe,delrio,curiel,burkhardt,bode,backus,zinn,watanabe,wachter,vanpelt,turnage,shaner,schroder,sato,riordan,quimby,portis,natale,mckoy,mccown,kilmer,hotchkiss,hesse,halbert,gwinn,godsey,delisle,chrisman,canter,arbogast,angell,acree,yancy,woolley,wesson,weatherspoon,trainor,stockman,spiller,sipe,rooks,reavis,propst,porras,neilson,mullens,loucks,llewellyn,kumar,koester,klingensmith,kirsch,kester,honaker,hodson,hennessy,helmick,garrity,garibay,fee,drain,casarez,callis,botello,aycock,avant,wingard,wayman,tully,theisen,szymanski,stansbury,segovia,rainwater,preece,pirtle,padron,mincey,mckelvey,mathes,larrabee,kornegay,klug,ingersoll,hecht,germain,eggers,dykstra,deering,decoteau,deason,dearing,cofield,carrigan,bonham,bahr,aucoin,appleby,almonte,yager,womble,wimmer,weimer,vanderpool,stancil,sprinkle,romine,remington,pfaff,peckham,olivera,meraz,maze,lathrop,koehn,hazelton,halvorson,hallock,haddock,ducharme,dehaven,caruthers,brehm,bosworth,bost,bias,beeman,basile,bane,aikens,wold,walther,tabb,suber,strawn,stocker,shirey,schlosser,riedel,rembert,reimer,pyles,peele,merriweather,letourneau,latta,kidder,hixon,hillis,hight,herbst,henriquez,haygood,hamill,gabel,fritts,eubank,dawes,correll,cha,bushey,buchholz,brotherton,botts,barnwell,auger,atchley,westphal,veilleux,ulloa,stutzman,shriver,ryals,prior,pilkington,moyers,marrs,mangrum,maddux,lockard,laing,kuhl,harney,hammock,hamlett,felker,doerr,depriest,carrasquillo,carothers,bogle,bischoff,bergen,albanese,wyckoff,vermillion,vansickle,thibault,tetreault,stickney,shoemake,ruggiero,rawson,racine,philpot,paschal,mcelhaney,mathison,legrand,lapierre,kwan,kremer,jiles,hilbert,geyer,faircloth,ehlers,egbert,desrosiers,dalrymple,cotten,cashman,cadena,breeding,boardman,alcaraz,ahn,wyrick,therrien,tankersley,strickler,puryear,plourde,pattison,pardue,mcginty,mcevoy,landreth,kuhns,koon,hewett,giddens,emerick,eades,deangelis,cosme,ceballos,birdsong,benham,bemis,armour,anguiano,welborn,tsosie,storms,shoup,sessoms,samaniego,rood,rojo,rhinehart,raby,northcutt,myer,munguia,morehouse,mcdevitt,mallett,lozada,lemoine,kuehn,hallett,grim,gillard,gaylor,garman,gallaher,feaster,faris,darrow,dardar,coney,carreon,braithwaite,boylan,boyett,bixler,bigham,benford,barragan,barnum,zuber,wyche,westcott,vining,stoltzfus,simonds,shupe,sabin,ruble,rittenhouse,richman,perrone,mulholland,millan,lomeli,kite,jemison,hulett,holler,hickerson,herold,hazelwood,griffen,gause,forde,eisenberg,dilworth,charron,chaisson,brodie,bristow,breunig,brace,boutwell,bentz,belk,bayless,batchelder,baran,baeza,zimmermann,weathersby,volk,toole,theis,tedesco,searle,schenck,satterwhite,ruelas,rankins,partida,nesbit,morel,menchaca,levasseur,kaylor,johnstone,hulse,hollar,hersey,harrigan,harbison,guyer,gish,giese,gerlach,geller,geisler,falcone,elwell,doucet,deese,darr,corder,chafin,byler,bussell,burdett,brasher,bowe,bellinger,bastian,barner,alleyne,wilborn,weil,wegner,wales,tatro,spitzer,smithers,schoen,resendez,parisi,overman,obrian,mudd,moy,mclaren,maggio,lindner,lalonde,lacasse,laboy,killion,kahl,jessen,jamerson,houk,henshaw,gustin,graber,durst,duenas,davey,cundiff,conlon,colunga,coakley,chiles,capers,buell,bricker,bissonnette,birmingham,bartz,bagby,zayas,volpe,treece,toombs,thom,terrazas,swinney,skiles,silveira,shouse,senn,ramage,nez,moua,langham,kyles,holston,hoagland,herd,feller,denison,carraway,burford,bickel,ambriz,abercrombie,yamada,weidner,waddle,verduzco,thurmond,swindle,schrock,sanabria,rosenberger,probst,peabody,olinger,nazario,mccafferty,mcbroom,mcabee,mazur,matherne,mapes,leverett,killingsworth,heisler,griego,gosnell,frankel,franke,ferrante,fenn,ehrlich,christopherso,chasse,chancellor,caton,brunelle,bly,bloomfield,babbitt,azevedo,abramson,ables,abeyta,youmans,wozniak,wainwright,stowell,smitherman,samuelson,runge,rothman,rosenfeld,peake,owings,olmos,munro,moreira,leatherwood,larkins,krantz,kovacs,kizer,kindred,karnes,jaffe,hubbell,hosey,hauck,goodell,erdman,dvorak,doane,cureton,cofer,buehler,bierman,berndt,banta,abdullah,warwick,waltz,turcotte,torrey,stith,seger,sachs,quesada,pinder,peppers,pascual,paschall,parkhurst,ozuna,oster,nicholls,lheureux,lavalley,kimura,jablonski,haun,gourley,gilligan,derby,croy,cotto,cargill,burwell,burgett,buckman,booher,adorno,wrenn,whittemore,urias,szabo,sayles,saiz,rutland,rael,pharr,pelkey,ogrady,nickell,musick,moats,mather,massa,kirschner,kieffer,kellar,hendershot,gott,godoy,gadson,furtado,fiedler,erskine,dutcher,dever,daggett,chevalier,brake,ballesteros,amerson,wingo,waldon,trott,silvey,showers,schlegel,rue,ritz,pepin,pelayo,parsley,palermo,moorehead,mchale,lett,kocher,kilburn,iglesias,humble,hulbert,huckaby,hix,haven,hartford,hardiman,gurney,grigg,grasso,goings,fillmore,farber,depew,dandrea,dame,cowen,covarrubias,burrus,bracy,ardoin,thompkins,standley,radcliffe,pohl,persaud,parenteau,pabon,newson,newhouse,napolitano,mulcahy,malave,keim,hooten,hernandes,heffernan,hearne,greenleaf,glick,fuhrman,fetter,faria,dishman,dickenson,crites,criss,clapper,chenault,castor,casto,bugg,bove,bonney,ard,anderton,allgood,alderson,woodman,warrick,toomey,tooley,tarrant,summerville,stebbins,sokol,searles,schutz,schumann,scheer,remillard,raper,proulx,palmore,monroy,messier,melo,melanson,mashburn,manzano,lussier,jenks,huneycutt,hartwig,grimsley,fulk,fielding,fidler,engstrom,eldred,dantzler,crandell,calder,brumley,breton,brann,bramlett,boykins,bianco,bancroft,almaraz,alcantar,whitmer,whitener,welton,vineyard,rahn,paquin,mizell,mcmillin,mckean,marston,maciel,lundquist,liggins,lampkin,kranz,koski,kirkham,jiminez,hazzard,harrod,graziano,grammer,gendron,garrido,fordham,englert,dryden,demoss,deluna,crabb,comeau,brummett,blume,benally,wessel,vanbuskirk,thorson,stumpf,stockwell,reams,radtke,rackley,pelton,niemi,newland,nelsen,morrissette,miramontes,mcginley,mccluskey,marchant,luevano,lampe,lail,jeffcoat,infante,hinman,gaona,erb,eady,desmarais,decosta,dansby,choe,breckenridge,bostwick,borg,bianchi,alberts,wilkie,whorton,vargo,tait,soucy,schuman,ousley,mumford,lum,lippert,leath,lavergne,laliberte,kirksey,kenner,johnsen,izzo,hiles,gullett,greenwell,gaspar,galbreath,gaitan,ericson,delapaz,croom,cottingham,clift,bushnell,bice,beason,arrowood,waring,voorhees,truax,shreve,shockey,schatz,sandifer,rubino,rozier,roseberry,pieper,peden,nester,nave,murphey,malinowski,macgregor,lafrance,kunkle,kirkman,hipp,hasty,haddix,gervais,gerdes,gamache,fouts,fitzwater,dillingham,deming,deanda,cedeno,cannady,burson,bouldin,arceneaux,woodhouse,whitford,wescott,welty,weigel,torgerson,toms,surber,sunderland,sterner,setzer,riojas,pumphrey,puga,metts,mcgarry,mccandless,magill,lupo,loveland,llamas,leclerc,koons,kahler,huss,holbert,heintz,haupt,grimmett,gaskill,ellingson,dorr,dingess,deweese,desilva,crossley,cordeiro,converse,conde,caldera,cairns,burmeister,burkhalter,brawner,bott,youngs,vierra,valladares,shrum,shropshire,sevilla,rusk,rodarte,pedraza,nino,merino,mcminn,markle,mapp,lajoie,koerner,kittrell,kato,hyder,hollifield,heiser,hazlett,greenwald,fant,eldredge,dreher,delafuente,cravens,claypool,beecher,aronson,alanis,worthen,wojcik,winger,whitacre,wellington,valverde,valdivia,troupe,thrower,swindell,suttles,suh,stroman,spires,slate,shealy,sarver,sartin,sadowski,rondeau,rolon,rascon,priddy,paulino,nolte,munroe,molloy,mciver,lykins,loggins,lenoir,klotz,kempf,hupp,hollowell,hollander,haynie,harkness,harker,gottlieb,frith,eddins,driskell,doggett,densmore,charette,cassady,byrum,burcham,buggs,benn,whitted,warrington,vandusen,vaillancourt,steger,siebert,scofield,quirk,purser,plumb,orcutt,nordstrom,mosely,michalski,mcphail,mcdavid,mccraw,marchese,mannino,lefevre,largent,lanza,kress,isham,hunsaker,hoch,hildebrandt,guarino,grijalva,graybill,ewell,ewald,cusick,crumley,coston,cathcart,carruthers,bullington,bowes,blain,blackford,barboza,yingling,weiland,varga,silverstein,sievers,shuster,shumway,runnels,rumsey,renfroe,provencher,polley,mohler,middlebrooks,kutz,koster,groth,glidden,fazio,deen,chipman,chenoweth,champlin,cedillo,carrero,carmody,buckles,brien,boutin,bosch,berkowitz,altamirano,wilfong,wiegand,waites,truesdale,toussaint,tobey,tedder,steelman,sirois,schnell,robichaud,richburg,plumley,pizarro,piercy,ortego,oberg,neace,mertz,mcnew,matta,lapp,lair,kibler,howlett,hollister,hofer,hatten,hagler,falgoust,engelhardt,eberle,dombrowski,dinsmore,daye,casares,braud,balch,autrey,wendel,tyndall,strobel,stoltz,spinelli,serrato,rochester,reber,rathbone,palomino,nickels,mayle,mathers,mach,loeffler,littrell,levinson,leong,lemire,lejeune,lazo,lasley,koller,kennard,hoelscher,hintz,hagerman,greaves,fore,eudy,engler,corrales,cordes,brunet,bidwell,bennet,tyrrell,tharpe,swinton,stribling,southworth,sisneros,savoie,samons,ruvalcaba,ries,ramer,omara,mosqueda,millar,mcpeak,macomber,luckey,litton,lehr,lavin,hubbs,hoard,hibbs,hagans,futrell,exum,evenson,culler,carbaugh,callen,brashear,bloomer,blakeney,bigler,addington,woodford,unruh,tolentino,sumrall,stgermain,smock,sherer,rayner,pooler,oquinn,nero,mcglothlin,linden,kowal,kerrigan,ibrahim,harvell,hanrahan,goodall,geist,fussell,fung,ferebee,eley,eggert,dorsett,dingman,destefano,colucci,clemmer,burnell,brumbaugh,boddie,berryhill,avelar,alcantara,winder,winchell,vandenberg,trotman,thurber,thibeault,stlouis,stilwell,sperling,shattuck,sarmiento,ruppert,rumph,renaud,randazzo,rademacher,quiles,pearman,palomo,mercurio,lowrey,lindeman,lawlor,larosa,lander,labrecque,hovis,holifield,henninger,hawkes,hartfield,hann,hague,genovese,garrick,fudge,frink,eddings,dinh,cribbs,calvillo,bunton,brodeur,bolding,blanding,agosto,zahn,wiener,trussell,tew,tello,teixeira,speck,sharma,shanklin,sealy,scanlan,santamaria,roundy,robichaux,ringer,rigney,prevost,polson,nord,moxley,medford,mccaslin,mcardle,macarthur,lewin,lasher,ketcham,keiser,heine,hackworth,grose,grizzle,gillman,gartner,frazee,fleury,edson,edmonson,derry,cronk,conant,burress,burgin,broom,brockington,bolick,boger,birchfield,billington,baily,bahena,armbruster,anson,yoho,wilcher,tinney,timberlake,thoma,thielen,sutphin,stultz,sikora,serra,schulman,scheffler,santillan,rego,preciado,pinkham,mickle,luu,lomas,lizotte,lent,kellerman,keil,johanson,hernadez,hartsfield,haber,gorski,farkas,eberhardt,duquette,delano,cropper,cozart,cockerham,chamblee,cartagena,cahoon,buzzell,brister,brewton,blackshear,benfield,aston,ashburn,arruda,wetmore,weise,vaccaro,tucci,sudduth,stromberg,stoops,showalter,shears,runion,rowden,rosenblum,riffle,renfrow,peres,obryant,leftwich,lark,landeros,kistler,killough,kerley,kastner,hoggard,hartung,guertin,govan,gatling,gailey,fullmer,fulford,flatt,esquibel,endicott,edmiston,edelstein,dufresne,dressler,dickman,chee,busse,bonnett,berard,arena,yoshida,velarde,veach,vanhouten,vachon,tolson,tolman,tennyson,stites,soler,shutt,ruggles,rhone,pegues,ong,neese,muro,moncrief,mefford,mcphee,mcmorris,mceachern,mcclurg,mansour,mader,leija,lecompte,lafountain,labrie,jaquez,heald,hash,hartle,gainer,frisby,farina,eidson,edgerton,dyke,durrett,duhon,cuomo,cobos,cervantez,bybee,brockway,borowski,binion,beery,arguello,amaro,acton,yuen,winton,wigfall,weekley,vidrine,vannoy,tardiff,shoop,shilling,schick,safford,prendergast,pellerin,osuna,nissen,nalley,moller,messner,messick,merrifield,mcguinness,matherly,marcano,mahone,lemos,lebrun,jara,hoffer,herren,hecker,haws,haug,gwin,gober,gilliard,fredette,favela,echeverria,downer,donofrio,desrochers,crozier,corson,bechtold,argueta,aparicio,zamudio,westover,westerman,utter,troyer,thies,tapley,slavin,shirk,sandler,roop,raymer,radcliff,otten,moorer,millet,mckibben,mccutchen,mcavoy,mcadoo,mayorga,mastin,martineau,marek,madore,leflore,kroeger,kennon,jimerson,hostetter,hornback,hendley,hance,guardado,granado,gowen,goodale,flinn,fleetwood,fitz,durkee,duprey,dipietro,dilley,clyburn,brawley,beckley,arana,weatherby,vollmer,vestal,tunnell,trigg,tingle,takahashi,sweatt,storer,snapp,shiver,rooker,rathbun,poisson,perrine,perri,pastor,parmer,parke,pare,palmieri,nottingham,midkiff,mecham,mccomas,mcalpine,lovelady,lillard,lally,knopp,kile,kiger,haile,gupta,goldsberry,gilreath,fulks,friesen,franzen,flack,findlay,ferland,dreyer,dore,dennard,deckard,debose,crim,coulombe,cork,chancey,cantor,branton,bissell,barns,woolard,witham,wasserman,spiegel,shoffner,scholz,ruch,rossman,petry,palacio,paez,neary,mortenson,millsap,miele,menke,mckim,mcanally,martines,manor,lemley,larochelle,klaus,klatt,kaufmann,kapp,helmer,hedge,halloran,glisson,frechette,fontana,eagan,distefano,danley,creekmore,chartier,chaffee,carillo,burg,bolinger,berkley,benz,basso,bash,barrier,zelaya,woodring,witkowski,wilmot,wilkens,wieland,verdugo,urquhart,tsai,timms,swiger,swaim,sussman,pires,molnar,mcatee,lowder,loos,linker,landes,kingery,hufford,higa,hendren,hammack,hamann,gillam,gerhardt,edelman,eby,delk,deans,curl,constantine,cleaver,claar,casiano,carruth,carlyle,brophy,bolanos,bibbs,bessette,beggs,baugher,bartel,averill,andresen,amin,adames,via,valente,turnbow,tse,swink,sublett,stroh,stringfellow,ridgway,pugliese,poteat,ohare,neubauer,murchison,mingo,lemmons,kwon,kellam,kean,jarmon,hyden,hudak,hollinger,henkel,hemingway,hasson,hansel,halter,haire,ginsberg,gillispie,fogel,flory,etter,elledge,eckman,deas,currin,crafton,coomer,colter,claxton,bulter,braddock,bowyer,binns,bellows,baskerville,barros,ansley,woolf,wight,waldman,wadley,tull,trull,tesch,stouffer,stadler,slay,shubert,sedillo,santacruz,reinke,poynter,neri,neale,mowry,moralez,monger,mitchum,merryman,manion,macdougall,lux,litchfield,ley,levitt,lepage,lasalle,khoury,kavanagh,karns,ivie,huebner,hodgkins,halpin,garica,eversole,dutra,dunagan,duffey,dillman,dillion,deville,dearborn,damato,courson,coulson,burdine,bousquet,bonin,bish,atencio,westbrooks,wages,vaca,tye,toner,tillis,swett,struble,stanfill,solorzano,slusher,sipple,sim,silvas,shults,schexnayder,saez,rodas,rager,pulver,plaza,penton,paniagua,meneses,mcfarlin,mcauley,matz,maloy,magruder,lohman,landa,lacombe,jaimes,hom,holzer,holst,heil,hackler,grundy,gilkey,farnham,durfee,dunton,dunston,duda,dews,craver,corriveau,conwell,colella,chambless,bremer,boutte,bourassa,blaisdell,backman,babineaux,audette,alleman,towner,taveras,tarango,sullins,suiter,stallard,solberg,schlueter,poulos,pimental,owsley,okelley,nations,moffatt,metcalfe,meekins,medellin,mcglynn,mccowan,marriott,marable,lennox,lamoureux,koss,kerby,karp,isenberg,howze,hockenberry,highsmith,harbour,hallmark,gusman,greeley,giddings,gaudet,gallup,fleenor,eicher,edington,dimaggio,dement,demello,decastro,bushman,brundage,brooker,bourg,blackstock,bergmann,beaton,banister,argo,appling,wortman,watterson,villalpando,tillotson,tighe,sundberg,sternberg,stamey,shipe,seeger,scarberry,sattler,sain,rothstein,poteet,plowman,pettiford,penland,partain,pankey,oyler,ogletree,ogburn,moton,merkel,lucier,lakey,kratz,kinser,kershaw,josephson,imhoff,hendry,hammon,frisbie,friedrich,frawley,fraga,forester,eskew,emmert,drennan,doyon,dandridge,cawley,carvajal,bracey,belisle,batey,ahner,wysocki,weiser,veliz,tincher,sansone,sankey,sandstrom,rohrer,risner,pridemore,pfeffer,persinger,peery,oubre,nowicki,musgrave,murdoch,mullinax,mccary,mathieu,livengood,kyser,klink,kimes,kellner,kavanaugh,kasten,imes,hoey,hinshaw,hake,gurule,grube,grillo,geter,gatto,garver,garretson,farwell,eiland,dunford,decarlo,corso,colman,collard,cleghorn,chasteen,cavender,carlile,calvo,byerly,brogdon,broadwater,breault,bono,bergin,behr,ballenger,amick,tamez,stiffler,steinke,simmon,shankle,schaller,salmons,sackett,saad,rideout,ratcliffe,rao,ranson,plascencia,petterson,olszewski,olney,olguin,nilsson,nevels,morelli,montiel,monge,michaelson,mertens,mcchesney,mcalpin,mathewson,loudermilk,lineberry,liggett,kinlaw,kight,jost,hereford,hardeman,halpern,halliday,hafer,gaul,friel,freitag,forsberg,evangelista,doering,dicarlo,dendy,delp,deguzman,dameron,curtiss,cosper,cauthen,cao,bradberry,bouton,bonnell,bixby,bieber,beveridge,bedwell,barhorst,bannon,baltazar,baier,ayotte,attaway,arenas,abrego,turgeon,tunstall,thaxton,thai,tenorio,stotts,sthilaire,shedd,seabolt,scalf,salyers,ruhl,rowlett,robinett,pfister,perlman,parkman,nunnally,norvell,napper,modlin,mckellar,mcclean,mascarenas,leibowitz,ledezma,kuhlman,kobayashi,hunley,holmquist,hinkley,hartsell,gribble,gravely,fifield,eliason,doak,crossland,carleton,bridgeman,bojorquez,boggess,auten,woosley,whiteley,wexler,twomey,tullis,townley,standridge,santoyo,rueda,riendeau,revell,pless,ottinger,nigro,nickles,mulvey,menefee,mcshane,mcloughlin,mckinzie,markey,lockridge,lipsey,knisley,knepper,kitts,kiel,jinks,hathcock,godin,gallego,fikes,fecteau,estabrook,ellinger,dunlop,dudek,countryman,chauvin,chatham,bullins,brownfield,boughton,bloodworth,bibb,baucom,barbieri,aubin,armitage,alessi,absher,abbate,zito,woolery,wiggs,wacker,tynes,tolle,telles,tarter,swarey,strode,stockdale,stalnaker,spina,schiff,saari,risley,rameriz,rakes,pettaway,penner,paulus,palladino,omeara,montelongo,melnick,mehta,mcgary,mccourt,mccollough,marchetti,manzanares,lowther,leiva,lauderdale,lafontaine,kowalczyk,knighton,joubert,jaworski,ide,huth,hurdle,housley,hackman,gulick,gordy,gilstrap,gehrke,gebhart,gaudette,foxworth,essex,endres,dunkle,cimino,caddell,brauer,braley,bodine,blackmore,belden,backer,ayer,andress,wisner,vuong,valliere,twigg,tso,tavarez,strahan,steib,staub,sowder,seiber,schutt,scharf,schade,rodriques,risinger,renshaw,rahman,presnell,piatt,nieman,nevins,mcilwain,mcgaha,mccully,mccomb,massengale,macedo,lesher,kearse,jauregui,husted,hudnall,holmberg,hertel,hardie,glidewell,frausto,fassett,dalessandro,dahlgren,corum,constantino,conlin,colquitt,colombo,claycomb,cardin,buller,boney,bocanegra,biggers,benedetto,araiza,andino,albin,zorn,werth,weisman,walley,vanegas,ulibarri,towe,tedford,teasley,suttle,steffens,stcyr,squire,singley,sifuentes,shuck,schram,sass,rieger,ridenhour,rickert,richerson,rayborn,rabe,raab,pendley,pastore,ordway,moynihan,mellott,mckissick,mcgann,mccready,mauney,marrufo,lenhart,lazar,lafave,keele,kautz,jardine,jahnke,jacobo,hord,hardcastle,hageman,giglio,gehring,fortson,duque,duplessis,dicken,derosier,deitz,dalessio,cram,castleman,candelario,callison,caceres,bozarth,biles,bejarano,bashaw,avina,armentrout,alverez,acord,waterhouse,vereen,vanlandingham,uhl,strawser,shotwell,severance,seltzer,schoonmaker,schock,schaub,schaffner,roeder,rodrigez,riffe,rhine,rasberry,rancourt,railey,quade,pursley,prouty,perdomo,oxley,osterman,nickens,murphree,mounts,merida,maus,mattern,masse,martinelli,mangan,lutes,ludwick,loney,laureano,lasater,knighten,kissinger,kimsey,kessinger,honea,hollingshead,hockett,heyer,heron,gurrola,gove,glasscock,gillett,galan,featherstone,eckhardt,duron,dunson,dasher,culbreth,cowden,cowans,claypoole,churchwell,chabot,caviness,cater,caston,callan,byington,burkey,boden,beckford,atwater,archambault,alvey,alsup,whisenant,weese,voyles,verret,tsang,tessier,sweitzer,sherwin,shaughnessy,revis,remy,prine,philpott,peavy,paynter,parmenter,ovalle,offutt,nightingale,newlin,nakano,myatt,muth,mohan,mcmillon,mccarley,mccaleb,maxson,marinelli,maley,liston,letendre,kain,huntsman,hirst,hagerty,gulledge,greenway,grajeda,gorton,goines,gittens,frederickson,fanelli,embree,eichelberger,dunkin,dixson,dillow,defelice,chumley,burleigh,borkowski,binette,biggerstaff,berglund,beller,audet,arbuckle,allain,alfano,youngman,wittman,weintraub,vanzant,vaden,twitty,stollings,standifer,sines,shope,scalise,saville,posada,pisano,otte,nolasco,napoli,mier,merkle,mendiola,melcher,mejias,mcmurry,mccalla,markowitz,manis,mallette,macfarlane,lough,looper,landin,kittle,kinsella,kinnard,hobart,herald,helman,hellman,hartsock,halford,hage,gordan,glasser,gayton,gattis,gastelum,gaspard,frisch,fitzhugh,eckstein,eberly,dowden,despain,crumpler,crotty,cornelison,chouinard,chamness,catlin,cann,bumgardner,budde,branum,bradfield,braddy,borst,birdwell,bazan,banas,bade,arango,ahearn,addis,zumwalt,wurth,wilk,widener,wagstaff,urrutia,terwilliger,tart,steinman,staats,sloat,rives,riggle,revels,reichard,prickett,poff,pitzer,petro,pell,northrup,nicks,moline,mielke,maynor,mallon,magness,lingle,lindell,lieb,lesko,lebeau,lammers,lafond,kiernan,ketron,jurado,holmgren,hilburn,hayashi,hashimoto,harbaugh,guillot,gard,froehlich,feinberg,falco,dufour,drees,doney,diep,delao,daves,dail,crowson,coss,congdon,carner,camarena,butterworth,burlingame,bouffard,bloch,bilyeu,barta,bakke,baillargeon,avent,aquilar,ake,aho,zeringue,yarber,wolfson,vogler,voelker,truss,troxell,thrift,strouse,spielman,sistrunk,sevigny,schuller,schaaf,ruffner,routh,roseman,ricciardi,peraza,pegram,overturf,olander,odaniel,neu,millner,melchor,maroney,machuca,macaluso,livesay,layfield,laskowski,kwiatkowski,kilby,hovey,heywood,hayman,havard,harville,haigh,hagood,grieco,glassman,gebhardt,fleischer,fann,elson,eccles,cunha,crumb,blakley,bardwell,abshire,woodham,wines,welter,wargo,varnado,tutt,traynor,swaney,svoboda,stricker,stoffel,stambaugh,sickler,shackleford,selman,seaver,sansom,sanmiguel,royston,rourke,rockett,rioux,puleo,pitchford,nardi,mulvaney,middaugh,malek,leos,lathan,kujawa,kimbro,killebrew,houlihan,hinckley,herod,hepler,hamner,hammel,hallowell,gonsalez,gingerich,gambill,funkhouser,fricke,fewell,falkner,endsley,dulin,drennen,deaver,dambrosio,chadwell,castanon,burkes,brune,brisco,brinker,bowker,boldt,berner,beaumont,beaird,bazemore,barrick,albano,younts,wunderlich,weidman,vanness,toland,theobald,stickler,steiger,stanger,spies,spector,sollars,smedley,seibel,scoville,saito,rye,rummel,rowles,rouleau,roos,rogan,roemer,ream,raya,purkey,priester,perreira,penick,paulin,parkins,overcash,oleson,neves,muldrow,minard,midgett,michalak,melgar,mcentire,mcauliffe,marte,lydon,lindholm,leyba,langevin,lagasse,lafayette,kesler,kelton,kao,kaminsky,jaggers,humbert,huck,howarth,hinrichs,higley,gupton,guimond,gravois,giguere,fretwell,fontes,feeley,faucher,eichhorn,ecker,earp,dole,dinger,derryberry,demars,deel,copenhaver,collinsworth,colangelo,cloyd,claiborne,caulfield,carlsen,calzada,caffey,broadus,brenneman,bouie,bodnar,blaney,blanc,beltz,behling,barahona,yockey,winkle,windom,wimer,villatoro,trexler,teran,taliaferro,sydnor,swinson,snelling,smtih,simonton,simoneaux,simoneau,sherrer,seavey,scheel,rushton,rupe,ruano,rippy,reiner,reiff,rabinowitz,quach,penley,odle,nock,minnich,mckown,mccarver,mcandrew,longley,laux,lamothe,lafreniere,kropp,krick,kates,jepson,huie,howse,howie,henriques,haydon,haught,hartzog,harkey,grimaldo,goshorn,gormley,gluck,gilroy,gillenwater,giffin,fluker,feder,eyre,eshelman,eakins,detwiler,delrosario,davisson,catalan,canning,calton,brammer,botelho,blakney,bartell,averett,askins,aker,zak,worcester,witmer,wiser,winkelman,widmer,whittier,weitzel,wardell,wagers,ullman,tupper,tingley,tilghman,talton,simard,seda,scheller,sala,rundell,rost,roa,ribeiro,rabideau,primm,pinon,peart,ostrom,ober,nystrom,nussbaum,naughton,murr,moorhead,monti,monteiro,melson,meissner,mclin,mcgruder,marotta,makowski,majewski,madewell,lunt,lukens,leininger,lebel,lakin,kepler,jaques,hunnicutt,hungerford,hoopes,hertz,heins,halliburton,grosso,gravitt,glasper,gallman,gallaway,funke,fulbright,falgout,eakin,dostie,dorado,dewberry,derose,cutshall,crampton,costanzo,colletti,cloninger,claytor,chiang,canterbury,campagna,burd,brokaw,broaddus,bretz,brainard,binford,bilbrey,alpert,aitken,ahlers,zajac,woolfolk,witten,windle,wayland,tramel,tittle,talavera,suter,straley,specht,sommerville,soloman,skeens,sigman,sibert,shavers,schuck,schmit,sartain,sabol,rosenblatt,rollo,rashid,rabb,province,polston,nyberg,northrop,navarra,muldoon,mikesell,mcdougald,mcburney,mariscal,lui,lozier,lingerfelt,legere,latour,lagunas,lacour,kurth,killen,kiely,kayser,kahle,isley,huertas,hower,hinz,haugh,gumm,galicia,fortunato,flake,dunleavy,duggins,doby,digiovanni,devaney,deltoro,cribb,corpuz,coronel,coen,charbonneau,caine,burchette,blakey,blakemore,bergquist,beene,beaudette,bayles,ballance,bakker,bailes,asberry,arwood,zucker,willman,whitesell,wald,walcott,vancleave,trump,strasser,simas,shick,schleicher,schaal,saleh,rotz,resnick,rainer,partee,ollis,oller,oday,munday,mong,millican,merwin,mazzola,mansell,magallanes,llanes,lewellen,lepore,kisner,keesee,jeanlouis,ingham,hornbeck,hawn,hartz,harber,haffner,gutshall,guth,grays,gowan,finlay,finkelstein,eyler,enloe,dungan,diez,dearman,cull,crosson,chronister,cassity,campion,callihan,butz,breazeale,blumenthal,berkey,batty,batton,arvizu,alderete,aldana,albaugh,abernethy,wolter,wille,tweed,tollefson,thomasson,teter,testerman,sproul,spates,southwick,soukup,skelly,senter,sealey,sawicki,sargeant,rossiter,rosemond,repp,pifer,ormsby,nickelson,naumann,morabito,monzon,millsaps,millen,mcelrath,marcoux,mantooth,madson,macneil,mackinnon,louque,leister,lampley,kushner,krouse,kirwan,jessee,janson,jahn,jacquez,islas,hutt,holladay,hillyer,hepburn,hensel,harrold,gingrich,geis,gales,fults,finnell,ferri,featherston,epley,ebersole,eames,dunigan,drye,dismuke,devaughn,delorenzo,damiano,confer,collum,clower,clow,claussen,clack,caylor,cawthon,casias,carreno,bluhm,bingaman,bewley,belew,beckner,auld,amey,wolfenbarger,wilkey,wicklund,waltman,villalba,valero,valdovinos,ung,ullrich,tyus,twyman,trost,tardif,tanguay,stripling,steinbach,shumpert,sasaki,sappington,sandusky,reinhold,reinert,quijano,pye,placencia,pinkard,phinney,perrotta,pernell,parrett,oxendine,owensby,orman,nuno,mori,mcroberts,mcneese,mckamey,mccullum,markel,mardis,maines,lueck,lubin,lefler,leffler,larios,labarbera,kershner,josey,jeanbaptiste,izaguirre,hermosillo,haviland,hartshorn,hafner,ginter,getty,franck,fiske,dufrene,doody,davie,dangerfield,dahlberg,cuthbertson,crone,coffelt,chidester,chesson,cauley,caudell,cantara,campo,caines,bullis,bucci,brochu,bogard,bickerstaff,benning,arzola,antonelli,adkinson,zellers,wulf,worsley,woolridge,whitton,westerfield,walczak,vassar,truett,trueblood,trawick,townsley,topping,tobar,telford,steverson,stagg,sitton,sill,sergent,schoenfeld,sarabia,rutkowski,rubenstein,rigdon,prentiss,pomerleau,plumlee,philbrick,peer,patnode,oloughlin,obregon,nuss,morell,mikell,mele,mcinerney,mcguigan,mcbrayer,lor,lollar,lakes,kuehl,kinzer,kamp,joplin,jacobi,howells,holstein,hedden,hassler,harty,halle,greig,gouge,goodrum,gerhart,geier,geddes,gast,forehand,ferree,fendley,feltner,esqueda,encarnacion,eichler,egger,edmundson,eatmon,doud,donohoe,donelson,dilorenzo,digiacomo,diggins,delozier,dejong,danford,crippen,coppage,cogswell,clardy,cioffi,cabe,brunette,bresnahan,bramble,blomquist,blackstone,biller,bevis,bevan,bethune,benbow,baty,basinger,balcom,andes,aman,aguero,adkisson,yandell,wilds,whisenhunt,weigand,weeden,voight,villar,trottier,tillett,suazo,setser,scurry,schuh,schreck,schauer,samora,roane,rinker,reimers,ratchford,popovich,parkin,natal,melville,mcbryde,magdaleno,loehr,lockman,lingo,leduc,larocca,lao,lamere,laclair,krall,korte,koger,jalbert,hughs,higbee,henton,heaney,haith,gump,greeson,goodloe,gholston,gasper,gagliardi,fregoso,farthing,fabrizio,ensor,elswick,elgin,eklund,eaddy,drouin,dorton,dizon,derouen,deherrera,davy,dampier,cullum,culley,cowgill,cardoso,cardinale,brodsky,broadbent,brimmer,briceno,branscum,bolyard,boley,bennington,beadle,baur,ballentine,azure,aultman,arciniega,aguila,aceves,yepez,yap,woodrum,wethington,weissman,veloz,trusty,troup,trammel,tarpley,stivers,steck,sprayberry,spraggins,spitler,spiers,sohn,seagraves,schiffman,rudnick,rizo,riccio,rennie,quackenbush,puma,plott,pearcy,parada,paiz,munford,moskowitz,mease,mcnary,mccusker,lozoya,longmire,loesch,lasky,kuhlmann,krieg,koziol,kowalewski,konrad,kindle,jowers,jolin,jaco,hua,horgan,hine,hileman,hepner,heise,heady,hawkinson,hannigan,haberman,guilford,grimaldi,garton,gagliano,fruge,follett,fiscus,ferretti,ebner,easterday,eanes,dirks,dimarco,depalma,deforest,cruce,craighead,christner,candler,cadwell,burchell,buettner,brinton,brazier,brannen,brame,bova,bomar,blakeslee,belknap,bangs,balzer,athey,armes,alvis,alverson,alvardo,yeung,wheelock,westlund,wessels,volkman,threadgill,thelen,tague,symons,swinford,sturtevant,straka,stier,stagner,segarra,seawright,rutan,roux,ringler,riker,ramsdell,quattlebaum,purifoy,poulson,permenter,peloquin,pasley,pagel,osman,obannon,nygaard,newcomer,munos,motta,meadors,mcquiston,mcniel,mcmann,mccrae,mayne,matte,legault,lechner,kucera,krohn,kratzer,koopman,jeske,horrocks,hock,hibbler,hesson,hersh,harvin,halvorsen,griner,grindle,gladstone,garofalo,frampton,forbis,eddington,diorio,dingus,dewar,desalvo,curcio,creasy,cortese,cordoba,connally,cluff,cascio,capuano,canaday,calabro,bussard,brayton,borja,bigley,arnone,arguelles,acuff,zamarripa,wooton,widner,wideman,threatt,thiele,templin,teeters,synder,swint,swick,sturges,stogner,stedman,spratt,siegfried,shetler,scull,savino,sather,rothwell,rook,rone,rhee,quevedo,privett,pouliot,poche,pickel,petrillo,pellegrini,peaslee,partlow,otey,nunnery,morelock,morello,meunier,messinger,mckie,mccubbin,mccarron,lerch,lavine,laverty,lariviere,lamkin,kugler,krol,kissel,keeter,hubble,hickox,hetzel,hayner,hagy,hadlock,groh,gottschalk,goodsell,gassaway,garrard,galligan,fye,firth,fenderson,feinstein,etienne,engleman,emrick,ellender,drews,doiron,degraw,deegan,dart,crissman,corr,cookson,coil,cleaves,charest,chapple,chaparro,castano,carpio,byer,bufford,bridgewater,bridgers,brandes,borrero,bonanno,aube,ancheta,abarca,abad,yim,wooster,wimbush,willhite,willams,wigley,weisberg,wardlaw,vigue,vanhook,unknow,torre,tasker,tarbox,strachan,slover,shamblin,semple,schuyler,schrimsher,sayer,salzman,rubalcava,riles,reneau,reichel,rayfield,rabon,pyatt,prindle,poss,polito,plemmons,pesce,perrault,pereyra,ostrowski,nilsen,niemeyer,munsey,mundell,moncada,miceli,meader,mcmasters,mckeehan,matsumoto,marron,marden,lizarraga,lingenfelter,lewallen,langan,lamanna,kovac,kinsler,kephart,keown,kass,kammerer,jeffreys,hysell,householder,hosmer,hardnett,hanner,guyette,greening,glazer,ginder,fromm,fluellen,finkle,fey,fessler,essary,eisele,duren,dittmer,crochet,cosentino,cogan,coelho,cavin,carrizales,campuzano,brough,bopp,bookman,blouin,beesley,battista,bascom,bakken,badgett,arneson,anselmo,ahumada,woodyard,wolters,wireman,willison,warman,waldrup,vowell,vantassel,vale,twombly,toomer,tennison,teets,tedeschi,swanner,stutz,stelly,sheehy,schermerhorn,scala,sandidge,salters,salo,saechao,roseboro,rolle,ressler,renz,renn,redford,raposa,rainbolt,pelfrey,orndorff,oney,nolin,nimmons,ney,nardone,myhre,morman,menjivar,mcglone,mccammon,maxon,marciano,manus,lowrance,lorenzen,lonergan,lollis,littles,lindahl,lamas,lach,kuster,krawczyk,knuth,knecht,kirkendall,keitt,keever,kantor,jarboe,hoye,houchens,holter,holsinger,hickok,helwig,helgeson,hassett,harner,hamman,hames,hadfield,goree,goldfarb,gaughan,gaudreau,gantz,gallion,frady,foti,flesher,ferrin,faught,engram,donegan,desouza,degroot,cutright,crowl,criner,coan,clinkscales,chewning,chavira,catchings,carlock,bulger,buenrostro,bramblett,brack,boulware,bookout,bitner,birt,baranowski,baisden,augustin,allmon,acklin,yoakum,wilbourn,whisler,weinberger,washer,vasques,vanzandt,vanatta,troxler,tomes,tindle,tims,throckmorton,thach,stpeter,stlaurent,stenson,spry,spitz,songer,snavely,sly,shroyer,shortridge,shenk,sevier,seabrook,scrivner,saltzman,rosenberry,rockwood,robeson,roan,reiser,ramires,raber,posner,popham,piotrowski,pinard,peterkin,pelham,peiffer,peay,nadler,musso,millett,mestas,mcgowen,marques,marasco,manriquez,manos,mair,lipps,leiker,krumm,knorr,kinslow,kessel,kendricks,kelm,ito,irick,ickes,hurlburt,horta,hoekstra,heuer,helmuth,heatherly,hampson,hagar,haga,greenlaw,grau,godbey,gingras,gillies,gibb,gayden,gauvin,garrow,fontanez,florio,finke,fasano,ezzell,ewers,eveland,eckenrode,duclos,drumm,dimmick,delancey,defazio,dashiell,cusack,crowther,crigger,cray,coolidge,coldiron,cleland,chalfant,cassel,camire,cabrales,broomfield,brittingham,brisson,brickey,braziel,brazell,bragdon,boulanger,bos,boman,bohannan,beem,barre,baptist,azar,ashbaugh,armistead,almazan,adamski,zendejas,winburn,willaims,wilhoit,westberry,wentzel,wendling,visser,vanscoy,vankirk,vallee,tweedy,thornberry,sweeny,spradling,spano,smelser,shim,sechrist,schall,scaife,rugg,rothrock,roesler,riehl,ridings,render,ransdell,radke,pinero,petree,pendergast,peluso,pecoraro,pascoe,panek,oshiro,navarrette,murguia,moores,moberg,michaelis,mcwhirter,mcsweeney,mcquade,mccay,mauk,mariani,marceau,mandeville,maeda,lunde,ludlow,loeb,lindo,linderman,leveille,leith,larock,lambrecht,kulp,kinsley,kimberlin,kesterson,hoyos,helfrich,hanke,grisby,goyette,gouveia,glazier,gile,gerena,gelinas,gasaway,funches,fujimoto,flynt,fenske,fellers,fehr,eslinger,escalera,enciso,duley,dittman,dineen,diller,devault,dao,collings,clymer,clowers,chavers,charland,castorena,castello,camargo,bunce,bullen,boyes,borchers,borchardt,birnbaum,birdsall,billman,benites,bankhead,ange,ammerman,adkison,winegar,wickman,warr,warnke,villeneuve,veasey,vassallo,vannatta,vadnais,twilley,towery,tomblin,tippett,theiss,talkington,talamantes,swart,swanger,streit,stines,stabler,spurling,sobel,sine,simmers,shippy,shiflett,shearin,sauter,sanderlin,rusch,runkle,ruckman,rorie,roesch,richert,rehm,randel,ragin,quesenberry,puentes,plyler,plotkin,paugh,oshaughnessy,ohalloran,norsworthy,niemann,nader,moorefield,mooneyham,modica,miyamoto,mickel,mebane,mckinnie,mazurek,mancilla,lukas,lovins,loughlin,lotz,lindsley,liddle,levan,lederman,leclaire,lasseter,lapoint,lamoreaux,lafollette,kubiak,kirtley,keffer,kaczmarek,housman,hiers,hibbert,herrod,hegarty,hathorn,greenhaw,grafton,govea,futch,furst,franko,forcier,foran,flickinger,fairfield,eure,emrich,embrey,edgington,ecklund,eckard,durante,deyo,delvecchio,dade,currey,creswell,cottrill,casavant,cartier,cargile,capel,cammack,calfee,burse,burruss,brust,brousseau,bridwell,braaten,borkholder,bloomquist,bjork,bartelt,arp,amburgey,yeary,yao,whitefield,vinyard,vanvalkenburg,twitchell,timmins,tapper,stringham,starcher,spotts,slaugh,simonsen,sheffer,sequeira,rosati,rhymes,reza,quint,pollak,peirce,patillo,parkerson,paiva,nilson,nevin,narcisse,nair,mitton,merriam,merced,meiners,mckain,mcelveen,mcbeth,marsden,marez,manke,mahurin,mabrey,luper,krull,kees,iles,hunsicker,hornbuckle,holtzclaw,hirt,hinnant,heston,hering,hemenway,hegwood,hearns,halterman,guiterrez,grote,granillo,grainger,glasco,gilder,garren,garlock,garey,fryar,fredricks,fraizer,foxx,foshee,ferrel,felty,everitt,evens,esser,elkin,eberhart,durso,duguay,driskill,doster,dewall,deveau,demps,demaio,delreal,deleo,deem,darrah,cumberbatch,culberson,cranmer,cordle,colgan,chesley,cavallo,castellon,castelli,carreras,carnell,carlucci,bontrager,blumberg,blasingame,becton,ayon,artrip,andujar,alkire,alder,agan,zukowski,zuckerman,zehr,wroblewski,wrigley,woodside,wigginton,westman,westgate,werts,washam,wardlow,walser,waiters,tadlock,stringfield,stimpson,stickley,standish,spurlin,spindler,speller,spaeth,sotomayor,sok,sluder,shryock,shepardson,shatley,scannell,santistevan,rosner,rhode,resto,reinhard,rathburn,prisco,poulsen,pinney,phares,pennock,pastrana,oviedo,ostler,noto,nauman,mulford,moise,moberly,mirabal,metoyer,metheny,mentzer,meldrum,mcinturff,mcelyea,mcdougle,massaro,lumpkins,loveday,lofgren,loe,lirette,lesperance,lefkowitz,ledger,lauzon,lain,lachapelle,kurz,klassen,keough,kempton,kaelin,jeffords,huot,hsieh,hoyer,horwitz,hopp,hoeft,hennig,haskin,gourdine,golightly,girouard,fulgham,fritsch,freer,frasher,foulk,firestone,fiorentino,fedor,ensley,englehart,eells,ebel,dunphy,donahoe,dileo,dibenedetto,dabrowski,crick,coonrod,conder,coddington,chunn,choy,chaput,cerna,carreiro,calahan,braggs,bourdon,bollman,bittle,behm,bauder,batt,barreras,aubuchon,anzalone,adamo,zerbe,wirt,willcox,westberg,weikel,waymire,vroman,vinci,vallejos,truesdell,troutt,trotta,tollison,toles,tichenor,symonds,surles,strayer,stgeorge,sroka,sorrentino,solares,snelson,silvestri,sikorski,shawver,schumaker,schorr,schooley,scates,satterlee,satchell,sacks,rymer,roselli,robitaille,riegel,regis,reames,provenzano,priestley,plaisance,pettey,palomares,oman,nowakowski,nace,monette,minyard,mclamb,mchone,mccarroll,masson,magoon,maddy,lundin,loza,licata,leonhardt,lema,landwehr,kircher,kinch,karpinski,johannsen,hussain,houghtaling,hoskinson,hollaway,holeman,hobgood,hilt,hiebert,gros,goggin,geissler,gadbois,gabaldon,fleshman,flannigan,fairman,epp,eilers,dycus,dunmire,duffield,dowler,deloatch,dehaan,deemer,clayborn,christofferso,chilson,chesney,chatfield,carron,canale,brigman,branstetter,bosse,borton,bonar,blau,biron,barroso,arispe,zacharias,zabel,yaeger,woolford,whetzel,weakley,veatch,vandeusen,tufts,troxel,troche,traver,townsel,tosh,talarico,swilley,sterrett,stenger,speakman,sowards,sours,souders,souder,soles,sobers,snoddy,smither,sias,shute,shoaf,shahan,schuetz,scaggs,santini,rosson,rolen,robidoux,rentas,recio,pixley,pawlowski,pawlak,paull,overbey,orear,oliveri,oldenburg,nutting,naugle,mote,mossman,moor,misner,milazzo,michelson,mcentee,mccullar,mccree,mcaleer,mazzone,mandell,manahan,malott,maisonet,mailloux,lumley,lowrie,louviere,lipinski,lindemann,leppert,leopold,leasure,labarge,kubik,knisely,knepp,kenworthy,kennelly,kelch,karg,kanter,hyer,houchin,hosley,hosler,hollon,holleman,heitman,hebb,haggins,gwaltney,guin,goulding,gorden,geraci,georges,gathers,frison,feagin,falconer,espada,erving,erikson,eisenhauer,eder,ebeling,durgin,dowdle,dinwiddie,delcastillo,dedrick,crimmins,covell,cournoyer,coria,cohan,cataldo,carpentier,canas,campa,brode,brashears,blaser,bicknell,berk,bednar,barwick,ascencio,althoff,almodovar,alamo,zirkle,zabala,wolverton,winebrenner,wetherell,westlake,wegener,weddington,vong,tuten,trosclair,tressler,theroux,teske,swinehart,swensen,sundquist,southall,socha,sizer,silverberg,shortt,shimizu,sherrard,shaeffer,scheid,scheetz,saravia,sanner,rubinstein,rozell,romer,rheaume,reisinger,randles,pullum,petrella,payan,papp,nordin,norcross,nicoletti,nicholes,newbold,nakagawa,mraz,monteith,milstead,milliner,mellen,mccardle,luft,liptak,lipp,leitch,latimore,larrison,landau,laborde,koval,izquierdo,hymel,hoskin,holte,hoefer,hayworth,hausman,harrill,harrel,hardt,gully,groover,grinnell,greenspan,graver,grandberry,gorrell,goldenberg,goguen,gilleland,garr,fuson,foye,feldmann,everly,dyess,dyal,dunnigan,downie,dolby,deatherage,cosey,cheever,celaya,caver,cashion,caplinger,cansler,byrge,bruder,breuer,breslin,brazelton,botkin,bonneau,bondurant,bohanan,bogue,boes,bodner,boatner,blatt,bickley,belliveau,beiler,beier,beckstead,bachmann,atkin,altizer,alloway,allaire,albro,abron,zellmer,yetter,yelverton,wiltshire,wiens,whidden,viramontes,vanwormer,tarantino,tanksley,sumlin,strauch,strang,stice,spahn,sosebee,sigala,shrout,seamon,schrum,schneck,schantz,ruddy,romig,roehl,renninger,reding,pyne,polak,pohlman,pasillas,oldfield,oldaker,ohanlon,ogilvie,norberg,nolette,nies,neufeld,nellis,mummert,mulvihill,mullaney,monteleone,mendonca,meisner,mcmullan,mccluney,mattis,massengill,manfredi,luedtke,lounsbury,liberatore,leek,lamphere,laforge,kuo,koo,jourdan,ismail,iorio,iniguez,ikeda,hubler,hodgdon,hocking,heacock,haslam,haralson,hanshaw,hannum,hallam,haden,garnes,garces,gammage,gambino,finkel,faucett,fahy,ehrhardt,eggen,dusek,durrant,dubay,dones,dey,depasquale,delucia,degraff,decamp,davalos,cullins,conard,clouser,clontz,cifuentes,chappel,chaffins,celis,carwile,byram,bruggeman,bressler,brathwaite,brasfield,bradburn,boose,boon,bodie,blosser,blas,bise,bertsch,bernardi,bernabe,bengtson,barrette,astorga,alday,albee,abrahamson,yarnell,wiltse,wile,wiebe,waguespack,vasser,upham,tyre,turek,traxler,torain,tomaszewski,tinnin,tiner,tindell,teed,styron,stahlman,staab,skiba,shih,sheperd,seidl,secor,schutte,sanfilippo,ruder,rondon,rearick,procter,prochaska,pettengill,pauly,neilsen,nally,mutter,mullenax,morano,meads,mcnaughton,mcmurtry,mcmath,mckinsey,matthes,massenburg,marlar,margolis,malin,magallon,mackin,lovette,loughran,loring,longstreet,loiselle,lenihan,laub,kunze,kull,koepke,kerwin,kalinowski,kagan,innis,innes,holtzman,heinemann,harshman,haider,haack,guss,grondin,grissett,greenawalt,gravel,goudy,goodlett,goldston,gokey,gardea,galaviz,gafford,gabrielson,furlow,fritch,fordyce,folger,elizalde,ehlert,eckhoff,eccleston,ealey,dubin,diemer,deschamps,delapena,decicco,debolt,daum,cullinan,crittendon,crase,cossey,coppock,coots,colyer,cluck,chamberland,burkhead,bumpus,buchan,borman,bork,boe,birkholz,berardi,benda,behnke,barter,auer,amezquita,wotring,wirtz,wingert,wiesner,whitesides,weyant,wainscott,venezia,varnell,tussey,thurlow,tabares,stiver,stell,starke,stanhope,stanek,sisler,sinnott,siciliano,shehan,selph,seager,scurlock,scranton,santucci,santangelo,saltsman,ruel,ropp,rogge,rettig,renwick,reidy,reider,redfield,quam,premo,peet,parente,paolucci,palmquist,orme,ohler,ogg,netherton,mutchler,morita,mistretta,minnis,middendorf,menzel,mendosa,mendelson,meaux,mcspadden,mcquaid,mcnatt,manigault,maney,mager,lukes,lopresti,liriano,lipton,letson,lechuga,lazenby,lauria,larimore,kwok,kwak,krupp,krupa,krum,kopec,kinchen,kifer,kerney,kerner,kennison,kegley,kays,karcher,justis,johson,jellison,janke,huskins,holzman,hinojos,hefley,hatmaker,harte,halloway,hallenbeck,goodwyn,glaspie,geise,fullwood,fryman,frew,frakes,fraire,farrer,enlow,engen,ellzey,eckles,earles,ealy,dunkley,drinkard,dreiling,draeger,dinardo,dills,desroches,desantiago,curlee,crumbley,critchlow,coury,courtright,coffield,cleek,charpentier,cardone,caples,cantin,buntin,bugbee,brinkerhoff,brackin,bourland,bohl,bogdan,blassingame,beacham,banning,auguste,andreasen,amann,almon,alejo,adelman,abston,zeno,yerger,wymer,woodberry,windley,whiteaker,westfield,weibel,wanner,waldrep,villani,vanarsdale,utterback,updike,triggs,topete,tolar,tigner,thoms,tauber,tarvin,tally,swiney,sweatman,studebaker,stennett,starrett,stannard,stalvey,sonnenberg,smithey,sieber,sickles,shinault,segars,sanger,salmeron,rothe,rizzi,rine,ricard,restrepo,ralls,ragusa,quiroga,pero,pegg,pavlik,papenfuss,oropeza,okane,neer,nee,mudge,mozingo,molinaro,mcvicker,mcgarvey,mcfalls,mccraney,matus,magers,llanos,livermore,liss,linehan,leto,leitner,laymon,lawing,lacourse,kwong,kollar,kneeland,keo,kennett,kellett,kangas,janzen,hutter,huse,huling,hoss,hohn,hofmeister,hewes,hern,harjo,habib,gust,guice,grullon,greggs,grayer,granier,grable,gowdy,giannini,getchell,gartman,garnica,ganey,gallimore,fray,fetters,fergerson,farlow,fagundes,exley,esteves,enders,edenfield,easterwood,drakeford,dipasquale,desousa,deshields,deeter,dedmon,debord,daughtery,cutts,courtemanche,coursey,copple,coomes,collis,coll,cogburn,clopton,choquette,chaidez,castrejon,calhoon,burbach,bulloch,buchman,bruhn,bohon,blough,bien,baynes,barstow,zeman,zackery,yardley,yamashita,wulff,wilken,wiliams,wickersham,wible,whipkey,wedgeworth,walmsley,walkup,vreeland,verrill,valera,umana,traub,swingle,summey,stroupe,stockstill,steffey,stefanski,statler,stapp,speights,solari,soderberg,shunk,shorey,shewmaker,sheilds,schiffer,schank,schaff,sagers,rochon,riser,rickett,reale,raglin,polen,plata,pitcock,percival,palen,pahl,orona,oberle,nocera,navas,nault,mullings,moos,montejano,monreal,minick,middlebrook,meece,mcmillion,mccullen,mauck,marshburn,maillet,mahaney,magner,maclin,lucey,litteral,lippincott,leite,leis,leaks,lamarre,kost,jurgens,jerkins,jager,hurwitz,hughley,hotaling,horstman,hohman,hocker,hively,hipps,hile,hessler,hermanson,hepworth,henn,helland,hedlund,harkless,haigler,gutierez,grindstaff,glantz,giardina,gerken,gadsden,finnerty,feld,farnum,encinas,drakes,dennie,cutlip,curtsinger,couto,cortinas,corby,chiasson,carle,carballo,brindle,borum,bober,blagg,birk,berthiaume,beahm,batres,basnight,backes,axtell,aust,atterberry,alvares,alt,alegria,yow,yip,woodell,wojciechowski,winfree,winbush,wiest,wesner,wamsley,wakeman,verner,truex,trafton,toman,thorsen,theus,tellier,tallant,szeto,strope,stills,sorg,simkins,shuey,shaul,servin,serio,serafin,salguero,saba,ryerson,rudder,ruark,rother,rohrbaugh,rohrbach,rohan,rogerson,risher,rigg,reeser,pryce,prokop,prins,priebe,prejean,pinheiro,petrone,petri,penson,pearlman,parikh,natoli,murakami,mullikin,mullane,motes,morningstar,monks,mcveigh,mcgrady,mcgaughey,mccurley,masi,marchan,manske,maez,lusby,linde,lile,likens,licon,leroux,lemaire,legette,lax,laskey,laprade,laplant,kolar,kittredge,kinley,kerber,kanagy,jetton,janik,ippolito,inouye,hunsinger,howley,howery,horrell,holthaus,hiner,hilson,hilderbrand,hasan,hartzler,harnish,harada,hansford,halligan,hagedorn,gwynn,gudino,greenstein,greear,gracey,goudeau,gose,goodner,ginsburg,gerth,gerner,fyfe,fujii,frier,frenette,folmar,fleisher,fleischmann,fetzer,eisenman,earhart,dupuy,dunkelberger,drexler,dillinger,dilbeck,dewald,demby,deford,dake,craine,como,chesnut,casady,carstens,carrick,carino,carignan,canchola,cale,bushong,burman,buono,brownlow,broach,britten,brickhouse,boyden,boulton,borne,borland,bohrer,blubaugh,bever,berggren,benevides,arocho,arends,amezcua,almendarez,zalewski,witzel,winkfield,wilhoite,vara,vangundy,vanfleet,vanetten,vandergriff,urbanski,troiano,thibodaux,straus,stoneking,stjean,stillings,stange,speicher,speegle,sowa,smeltzer,slawson,simmonds,shuttleworth,serpa,senger,seidman,schweiger,schloss,schimmel,schechter,sayler,sabb,sabatini,ronan,rodiguez,riggleman,richins,reep,reamer,prunty,porath,plunk,piland,philbrook,pettitt,perna,peralez,pascale,padula,oboyle,nivens,nickols,murph,mundt,munden,montijo,mcmanis,mcgrane,mccrimmon,manzi,mangold,malick,mahar,maddock,losey,litten,liner,leff,leedy,leavell,ladue,krahn,kluge,junker,iversen,imler,hurtt,huizar,hubbert,howington,hollomon,holdren,hoisington,hise,heiden,hauge,hartigan,gutirrez,griffie,greenhill,gratton,granata,gottfried,gertz,gautreaux,furry,furey,funderburg,flippen,fitzgibbon,dyar,drucker,donoghue,dildy,devers,detweiler,despres,denby,degeorge,cueto,cranston,courville,clukey,cirillo,chon,chivers,caudillo,catt,butera,bulluck,buckmaster,braunstein,bracamonte,bourdeau,bonnette,bobadilla,boaz,blackledge,beshears,bernhard,bergeson,baver,barthel,balsamo,bak,aziz,awad,authement,altom,altieri,abels,zigler,zhu,younker,yeomans,yearwood,wurster,winget,whitsett,wechsler,weatherwax,wathen,warriner,wanamaker,walraven,viens,vandemark,vancamp,uchida,triana,tinoco,terpstra,tellis,tarin,taranto,takacs,studdard,struthers,strout,stiller,spataro,soderquist,sliger,silberman,shurtleff,sheetz,ritch,reif,raybon,ratzlaff,radley,putt,putney,pinette,piner,petrin,parise,osbourne,nyman,northington,noblitt,nishimura,neher,nalls,naccarato,mucha,mounce,miron,millis,meaney,mcnichols,mckinnis,mcjunkin,mcduffy,manrique,mannion,mangual,malveaux,mains,lumsden,lohmann,lipe,lightsey,lemasters,leist,laxton,laverriere,latorre,lamons,kral,kopf,knauer,kitt,kaul,karas,kamps,jusino,islam,hullinger,huges,hornung,hiser,hempel,helsel,hassinger,hargraves,hammes,hallberg,gutman,gumbs,gruver,graddy,gonsales,goncalves,glennon,gilford,geno,freshour,flippo,fifer,fason,farrish,fallin,ewert,estepp,escudero,ensminger,emberton,elms,ellerbe,eide,dysart,dougan,dierking,dicus,detrick,deroche,depue,demartino,delosreyes,dalke,culbreath,crownover,crisler,crass,corsi,chagnon,centers,cavanagh,casson,carollo,cadwallader,burnley,burciaga,burchard,broadhead,bolte,berens,bellman,bellard,baril,antonucci,wolfgram,winsor,wimbish,wier,wallach,viveros,vento,varley,vanslyke,vangorder,touchstone,tomko,tiemann,throop,tamura,talmadge,swayze,sturdevant,strauser,stolz,stenberg,stayton,spohn,spillers,spillane,sluss,slavens,simonetti,shofner,shead,senecal,seales,schueler,schley,schacht,sauve,sarno,salsbury,rothschild,rosier,rines,reveles,rein,redus,redfern,reck,ranney,raggs,prout,prill,preble,prager,plemons,pilon,piccirillo,pewitt,pesina,pecora,otani,orsini,oestreich,odea,ocallaghan,northup,niehaus,newberg,nasser,narron,monarrez,mishler,mcsherry,mcelfresh,mayon,mauer,mattice,marrone,marmolejo,marini,malm,machen,lunceford,loewen,liverman,litwin,linscott,levins,lenox,legaspi,leeman,leavy,lannon,lamson,lambdin,labarre,knouse,klemm,kleinschmidt,kirklin,keels,juliano,howser,hosier,hopwood,holyfield,hodnett,hirsh,heimann,heckel,harger,hamil,hajek,gurganus,gunning,grange,gonzalas,goggins,gerow,gaydos,garduno,ganley,galey,farner,engles,emond,emert,ellenburg,edick,duell,dorazio,dimond,diederich,depuy,dempster,demaria,dehoyos,dearth,dealba,czech,crose,crespin,cogdill,clinard,cipriano,chretien,cerny,ceniceros,celestin,caple,cacho,burrill,buhr,buckland,branam,boysen,bovee,boos,boler,blom,blasko,beyers,belz,belmonte,bednarz,beckmann,beaudin,bazile,barbeau,balentine,abrahams,zielke,yunker,yeates,wrobel,wike,whisnant,wherry,wagnon,vogan,vansant,vannest,vallo,ullery,towles,towell,thill,taormina,tannehill,taing,storrs,stickles,stetler,sparling,solt,silcox,sheard,shadle,seman,selleck,schlemmer,scher,sapien,sainz,roye,romain,rizzuto,resch,rentz,rasch,ranieri,purtell,primmer,portwood,pontius,pons,pletcher,pledger,pirkle,pillsbury,pentecost,paxson,ortez,oles,mullett,muirhead,mouzon,mork,mollett,mohn,mitcham,melillo,medders,mcmiller,mccleery,mccaughey,mak,maciejewski,macaulay,lute,lipman,lewter,larocque,langton,kriner,knipp,killeen,karn,kalish,kaczor,jonson,jerez,jarrard,janda,hymes,hollman,hollandsworth,holl,hobdy,hennen,hemmer,hagins,haddox,guitierrez,guernsey,gorsuch,gholson,genova,gazaway,gauna,gammons,freels,fonville,fetterman,fava,farquhar,farish,fabela,escoto,eisen,dossett,dority,dorfman,demmer,dehn,dawley,darbonne,damore,damm,crosley,cron,crompton,crichton,cotner,cordon,conerly,colvard,clauson,cheeseman,cavallaro,castille,cabello,burgan,buffum,bruss,brassfield,bowerman,bothwell,borgen,bonaparte,bombard,boivin,boissonneault,bogner,bodden,boan,bittinger,bickham,bedolla,bale,bainbridge,aybar,avendano,ashlock,amidon,almanzar,akridge,ackermann,zager,worrall,winans,wilsey,wightman,westrick,wenner,warne,warford,verville,utecht,upson,tuma,tseng,troncoso,trollinger,torbert,taulbee,sutterfield,stough,storch,stonebraker,stolle,stilson,stiefel,steptoe,stepney,stender,stemple,staggers,spurrier,spinney,spengler,smartt,skoog,silvis,sieg,shuford,selfridge,seguin,sedgwick,sease,scotti,schroer,schlenker,schill,savarese,sapienza,sanson,sandefur,salamone,rusnak,rudisill,rothermel,roca,resendiz,reliford,rasco,raiford,quisenberry,quijada,pullins,puccio,postell,poppe,pinter,piche,petrucci,pellegrin,pelaez,paton,pasco,parkes,paden,pabst,olmsted,newlon,mynatt,mower,morrone,moree,moffat,mixson,minner,millette,mederos,mcgahan,mcconville,maughan,massingill,marano,macri,lovern,lichtenstein,leonetti,lehner,lawley,laramie,lappin,lahti,lago,lacayo,kuester,kincade,juhl,jiron,jessop,jarosz,jain,hults,hoge,hodgins,hoban,hinkson,hillyard,herzig,hervey,henriksen,hawker,hause,hankerson,gregson,golliday,gilcrease,gessner,gerace,garwood,garst,gaillard,flinchum,fishel,fishback,filkins,fentress,fabre,ethier,eisner,ehrhart,efird,drennon,dominy,domingue,dipaolo,dinan,dimartino,deskins,dengler,defreitas,defranco,dahlin,cutshaw,cuthbert,croyle,crothers,critchfield,cowie,costner,coppedge,copes,ciccone,caufield,capo,cambron,cambridge,buser,burnes,buhl,buendia,brindley,brecht,bourgoin,blackshire,birge,benninger,bembry,beil,begaye,barrentine,banton,balmer,baity,auerbach,ambler,alexandre,ackerson,zurcher,zell,wynkoop,wallick,waid,vos,vizcaino,vester,veale,vandermark,vanderford,tuthill,trivette,thiessen,tewksbury,tao,tabron,swasey,swanigan,stoughton,stoudt,stimson,stecker,stead,spady,souther,smoak,sklar,simcox,sidwell,seybert,sesco,seeman,schwenk,schmeling,rossignol,robillard,robicheaux,riveria,rippeon,ridgley,remaley,rehkop,reddish,rauscher,quirion,pusey,pruden,pressler,potvin,pospisil,paradiso,pangburn,palmateer,ownby,otwell,osterberg,osmond,olsson,oberlander,nusbaum,novack,nokes,nicastro,nehls,naber,mulhern,motter,moretz,milian,mckeel,mcclay,mccart,matsuda,martucci,marple,marko,marciniak,manes,mancia,macrae,lybarger,lint,lineberger,levingston,lecroy,lattimer,laseter,kulick,krier,knutsen,klem,kinne,kinkade,ketterman,kerstetter,kersten,karam,joshi,jent,jefcoat,hillier,hillhouse,hettinger,henthorn,henline,helzer,heitzman,heineman,heenan,haughton,haris,harbert,haman,grinstead,gremillion,gorby,giraldo,gioia,gerardi,geraghty,gaunt,gatson,gardin,gans,gammill,friedlander,frahm,fossett,fosdick,forbush,fondren,fleckenstein,fitchett,filer,feliz,feist,ewart,esters,elsner,edgin,easterly,dussault,durazo,devereaux,deshotel,deckert,dargan,cornman,conkle,condit,claunch,clabaugh,cheesman,chea,charney,casella,carone,carbonell,canipe,campana,calles,cabezas,cabell,buttram,bustillos,buskirk,boyland,bourke,blakeley,berumen,berrier,belli,behrendt,baumbach,bartsch,baney,arambula,alldredge,allbritton,ziemba,zanders,youngquist,yoshioka,yohe,wunder,woodfin,wojtowicz,winkel,wilmore,willbanks,wesolowski,wendland,walko,votaw,vanek,uriarte,urbano,turnipseed,triche,trautman,towler,tokarz,temples,tefft,teegarden,syed,swigart,stoller,stapler,stansfield,smit,smelley,sicard,shulman,shew,shear,sheahan,sharpton,selvidge,schlesinger,savell,sandford,sabatino,rosenbloom,roepke,rish,rhames,renken,reger,quarterman,puig,prasad,poplar,pizano,pigott,phair,petrick,patt,pascua,paramore,papineau,olivieri,ogren,norden,noga,nisbet,munk,morvant,moro,moloney,merz,meltzer,mellinger,mehl,mcnealy,mckernan,mchaney,mccleskey,mcandrews,mayton,markert,maresca,maner,mandujano,malpass,macintyre,lytton,lyall,lummus,longshore,longfellow,lokey,locher,leverette,lepe,lefever,leeson,lederer,lampert,lagrone,kreider,korth,knopf,kleist,keltner,kelling,kaspar,kappler,josephs,huckins,holub,hofstetter,hoehn,higginson,hennings,heid,havel,hauer,harnden,hargreaves,hanger,guild,guidi,grate,grandy,grandstaff,goza,goodridge,goodfellow,goggans,godley,giusti,gilyard,geoghegan,galyon,gaeta,funes,font,flanary,fales,erlandson,ellett,edinger,dziedzic,duerr,draughn,donoho,dimatteo,devos,dematteo,degnan,darlington,danis,dahlstrom,dahlke,czajkowski,cumbie,culbert,crosier,croley,corry,clinger,chalker,cephas,caywood,capehart,cales,cadiz,bussiere,burriss,burkart,brundidge,bronstein,bradt,boydston,bostrom,borel,bolles,blay,blackwelder,bissett,bevers,bester,bernardino,benefiel,belote,beedle,beckles,baysinger,bassler,bartee,barlett,bargas,barefield,baptista,arterburn,armas,apperson,amoroso,amedee,zullo,zellner,yelton,willems,wilkin,wiggin,widman,welk,weingarten,walla,viers,vess,verdi,veazey,vannote,tullos,trudell,trower,trosper,trimm,trew,tousignant,topp,tocco,thoreson,terhune,tatom,suniga,sumter,steeves,stansell,soltis,sloss,slaven,shisler,shanley,servantes,selders,segrest,seese,seeber,schaible,savala,sartor,rutt,rumbaugh,ruis,roten,roessler,ritenour,riney,restivo,renard,rakestraw,rake,quiros,pullin,prudhomme,primeaux,prestridge,presswood,ponte,polzin,poarch,pittenger,piggott,pickell,phaneuf,parvin,parmley,palmeri,ozment,ormond,ordaz,ono,olea,obanion,oakman,novick,nicklas,nemec,nappi,mund,morfin,mera,melgoza,melby,mcgoldrick,mcelwain,mcchristian,mccaw,marquart,marlatt,markovich,mahr,lupton,lucus,lorusso,lerman,leddy,leaman,leachman,lavalle,laduke,kummer,koury,konopka,koh,koepp,kloss,klock,khalil,kernan,kappel,jakes,inoue,hutsell,howle,honore,hockman,hockaday,hiltz,hetherington,hesser,hershman,heffron,headen,haskett,hartline,harned,guillemette,guglielmo,guercio,greenbaum,goris,glines,gilmour,gardella,gadd,gabler,gabbert,fuselier,freudenburg,fragoso,follis,flemings,feltman,febus,farren,fallis,evert,ekstrom,eastridge,dyck,dufault,dubreuil,drapeau,domingues,dolezal,dinkel,didonato,devitt,demott,daughtrey,daubert,das,creason,crary,costilla,chipps,cheatwood,carmean,canton,caffrey,burgher,buker,brunk,brodbeck,brantner,bolivar,boerner,bodkin,biel,bencomo,bellino,beliveau,beauvais,beaupre,baylis,baskett,barcus,baltz,asay,arney,arcuri,ankney,agostini,addy,zwilling,zubia,zollinger,zeitz,yanes,winship,winningham,wickline,webre,waddington,vosburgh,verrett,varnum,vandeventer,vacca,usry,towry,touchet,tookes,tonkin,timko,tibbitts,thedford,tarleton,talty,talamantez,tafolla,sugg,strecker,steffan,spiva,slape,shatzer,seyler,seamans,schmaltz,schipper,sasso,ruppe,roudebush,riemer,richarson,revilla,reichenbach,ratley,railsback,quayle,poplin,poorman,ponton,pollitt,poitras,piscitelli,piedra,pew,perera,penwell,pelt,parkhill,paladino,ore,oram,olmo,oliveras,olivarria,ogorman,naron,muncie,mowbray,morones,moretti,monn,mitts,minks,minarik,mimms,milliron,millington,millhouse,messersmith,mcnett,mckinstry,mcgeorge,mcdill,mcateer,mazzeo,matchett,mahood,mabery,lundell,louden,losoya,lisk,lezama,leib,lebo,lanoue,lanford,lafortune,kump,krone,kreps,kott,kopecky,kolodziej,kinman,kimmons,kelty,kaster,karlson,kania,joyal,jenner,jasinski,jandreau,isenhour,hunziker,huhn,houde,houchins,holtman,hodo,heyman,hentges,hedberg,hayne,haycraft,harshbarger,harshaw,harriss,haring,hansell,hanford,handler,hamblen,gunnell,groat,gorecki,gochenour,gleeson,genest,geiser,fulghum,friese,fridley,freeborn,frailey,flaugher,fiala,ettinger,etheredge,espitia,eriksen,engelbrecht,engebretson,elie,eickhoff,edney,edelen,eberhard,eastin,eakes,driggs,doner,donaghy,disalvo,deshong,dahms,dahlquist,curren,cripe,cree,creager,corle,conatser,commons,coggin,coder,coaxum,closson,clodfelter,classen,chittenden,castilleja,casale,cartee,carriere,canup,canizales,burgoon,bunger,bugarin,buchanon,bruning,bruck,brookes,broadwell,brier,brekke,breese,bracero,bowley,bowersox,bose,bogar,blauser,blacker,bjorklund,baumer,basler,baize,baden,auman,amundsen,amore,alvarenga,adamczyk,yerkes,yerby,yamaguchi,worthey,wolk,wixom,wiersma,wieczorek,whiddon,weyer,wetherington,wein,watchman,warf,wansley,vesely,velazco,vannorman,valasquez,utz,urso,turco,turbeville,trivett,toothaker,toohey,tondreau,thaler,sylvain,swindler,swigert,swider,stiner,stever,steffes,stampley,stair,smidt,skeete,silvestre,shutts,shealey,seigler,schweizer,schuldt,schlichting,scherr,saulsberry,saner,rosin,rosato,roling,rohn,rix,rister,remley,remick,recinos,ramm,raabe,pursell,poythress,poli,pokorny,pettry,petrey,petitt,penman,payson,paquet,pappalardo,outland,orenstein,nuttall,nuckols,nott,nimmo,murtagh,mousseau,moulder,mooneyhan,moak,minch,miera,mercuri,meighan,mcnelly,mcguffin,mccreery,mcclaskey,mainor,luongo,lundstrom,loughman,lobb,linhart,lever,leu,leiter,lehoux,lehn,lares,lapan,langhorne,lamon,ladwig,ladson,kuzma,kreitzer,knop,keech,kea,kadlec,jhonson,jantz,inglis,husk,hulme,housel,hofman,hillery,heidenreich,heaps,haslett,harting,hartig,hamler,halton,hallum,gutierres,guida,guerrier,grossi,gress,greenhalgh,gravelle,gow,goslin,gonyea,gipe,gerstner,gasser,garceau,gannaway,gama,gallop,gaiser,fullilove,foutz,fossum,flannagan,farrior,faller,ericksen,entrekin,enochs,englund,ellenberger,eastland,earwood,dudash,drozd,desoto,delph,dekker,dejohn,degarmo,defeo,defalco,deblois,dacus,cudd,crossen,crooms,cronan,costin,cordray,comerford,colegrove,coldwell,claassen,chartrand,castiglione,carte,cardella,carberry,capp,capobianco,cangelosi,buch,brunell,brucker,brockett,brizendine,brinegar,brimer,brase,bosque,bonk,bolger,bohanon,bohan,blazek,berning,bergan,bennette,beauchemin,battiste,barra,balogh,avallone,aubry,ashcroft,asencio,arledge,anchondo,alvord,acheson,zaleski,yonker,wyss,wycoff,woodburn,wininger,winders,willmon,wiechmann,westley,weatherholt,warnick,wardle,warburton,volkert,villanveva,veit,vass,vanallen,tung,toribio,toothman,tiggs,thornsberry,thome,tepper,teeple,tebo,tassone,tann,stucker,stotler,stoneman,stehle,stanback,stallcup,spurr,speers,spada,solum,smolen,sinn,silvernail,sholes,shives,shain,secrest,seagle,schuette,schoch,schnieders,schild,schiavone,schiavo,scharff,santee,sandell,salvo,rollings,rivenburg,ritzman,rist,reynosa,retana,regnier,rarick,ransome,rall,propes,prall,poyner,ponds,poitra,pippins,pinion,phu,perillo,penrose,pendergraft,pelchat,patenaude,palko,odoms,oddo,novoa,noone,newburn,negri,nantz,mosser,moshier,molter,molinari,moler,millman,meurer,mendel,mcray,mcnicholas,mcnerney,mckillip,mcilvain,mcadory,marmol,marinez,manzer,mankin,makris,majeski,maffei,luoma,luman,luebke,luby,lomonaco,loar,litchford,lintz,licht,levenson,legge,lanigan,krom,kreger,koop,kober,klima,kitterman,kinkead,kimbell,kilian,kibbe,kendig,kemmer,kash,jenkin,inniss,hurlbut,hunsucker,huckabee,hoxie,hoglund,hockensmith,hoadley,hinkel,higuera,herrman,heiner,hausmann,haubrich,hassen,hanlin,hallinan,haglund,hagberg,gullo,gullion,groner,greenwalt,gobert,glowacki,glessner,gines,gildersleeve,gildea,gerke,gebhard,gatton,gately,galasso,fralick,fouse,fluharty,faucette,fairfax,evanoff,elser,ellard,egerton,ector,ebling,dunkel,duhart,drysdale,dostal,dorey,dolph,doles,dismukes,digregorio,digby,dewees,deramus,denniston,dennett,deloney,delaughter,cuneo,cumberland,crotts,crosswhite,cremeans,creasey,cottman,cothern,costales,cosner,corpus,colligan,cobble,clutter,chupp,chevez,chatmon,chaires,caplan,caffee,cabana,burrough,burditt,buckler,brunswick,brouillard,broady,bowlby,bouley,borgman,boltz,boddy,blackston,birdsell,bedgood,bate,bartos,barriga,barna,barcenas,banach,baccus,auclair,ashman,arter,arendt,ansell,allums,allender,alber,albarran,adelson,zoll,wysong,wimbley,wildes,whitis,whitehill,whicker,weymouth,weldy,wark,wareham,waddy,viveiros,vath,vandoren,vanderhoof,unrein,uecker,tsan,trepanier,tregre,torkelson,tobler,tineo,timmer,swopes,swofford,sweeten,swarts,summerfield,sumler,stucky,strozier,stigall,stickel,stennis,stelzer,steely,slayden,skillern,shurtz,shelor,shellenbarger,shand,shabazz,seo,scroggs,schwandt,schrecengost,schoenrock,schirmer,sandridge,ruzicka,rozek,rowlands,roser,rosendahl,romanowski,rolston,riggio,reichman,redondo,reay,rawlinson,raskin,raine,quandt,purpura,pruneda,prevatte,prettyman,pinedo,pierro,pidgeon,phillippi,pfeil,penix,peasley,paro,ospina,ortegon,ogata,ogara,normandin,nordman,nims,nassar,motz,morlan,mooring,moles,moir,mizrahi,mire,minaya,millwood,mikula,messmer,meikle,mctaggart,mcgonagle,mcewan,mccasland,mccane,mccaffery,mcalexander,mattocks,matranga,martone,markland,maravilla,manno,mancha,mallery,magno,lorentz,locklin,livingstone,lipford,lininger,lepley,leming,lemelin,leadbetter,lawhon,lattin,langworthy,lampman,lambeth,lamarr,lahey,krajewski,klopp,kinnison,kestner,kennell,karim,jozwiak,jakubowski,ivery,iliff,iddings,hudkins,houseman,holz,holderman,hoehne,highfill,hiett,heskett,heldt,hedman,hayslett,hatchell,hasse,hamon,hamada,hakala,haislip,haffey,hackbarth,guo,gullickson,guerrette,greenblatt,goudreau,gongora,godbout,glaude,gills,gillison,gigliotti,gargano,gallucci,galli,galante,frasure,fodor,fizer,fishburn,finkbeiner,finck,fager,estey,espiritu,eppinger,epperly,emig,eckley,dray,dorsch,dille,devita,deslauriers,demery,delorme,delbosque,dauphin,dantonio,curd,crume,cozad,cossette,comacho,climer,chadbourne,cespedes,cayton,castaldo,carpino,carls,capozzi,canela,buzard,busick,burlison,brinkmann,bridgeforth,bourbeau,bornstein,bonfiglio,boice,boese,biondi,bilski,betton,berwick,berlanga,behan,becraft,barrientez,banh,balke,balderrama,bahe,bachand,armer,arceo,aliff,alatorre,zermeno,younce,yeoman,yamasaki,wroten,woodby,winer,willits,wilcoxon,wehmeyer,waterbury,wass,wann,wachtel,vizcarra,veitch,vanderbilt,vallone,vallery,ureno,tyer,tipps,tiedeman,theberge,texeira,taub,tapscott,stutts,stults,stukes,spink,sottile,smithwick,slane,simeone,silvester,siegrist,shiffer,sheedy,sheaffer,severin,sellman,scotto,schupp,schueller,schreier,schoolcraft,schoenberger,schnabel,sangster,samford,saliba,ryles,ryans,rossetti,rodriguz,risch,riel,rezendes,rester,rencher,recker,rathjen,profitt,poteete,polizzi,perrigo,patridge,osby,orvis,opperman,oppenheim,onorato,olaughlin,ohagan,ogles,oehler,obyrne,nuzzo,nickle,nease,neagle,navarette,nagata,musto,morison,montz,mogensen,mizer,miraglia,migliore,menges,mellor,mcnear,mcnab,mcloud,mcelligott,mccollom,maynes,marquette,markowski,marcantonio,maldanado,macey,lundeen,longino,lisle,linthicum,limones,lesure,lesage,lauver,laubach,latshaw,lary,lapham,lacoste,lacher,kutcher,knickerbocker,klos,klingler,kleiman,kittleson,kimbrel,kemmerer,kelson,keese,kallas,jurgensen,junkins,juergens,jolliff,jelks,janicki,jang,ingles,huguley,huggard,howton,hone,holford,hogle,hipple,heimbach,heider,heidel,havener,hattaway,harrah,hanscom,hankinson,hamdan,gridley,goulette,goulart,goodrow,girardi,gent,gautreau,gandara,gamblin,galipeau,fyffe,furrow,fulp,fricks,frase,frandsen,fout,foulks,fouche,foskey,forgey,foor,fobbs,finklea,fincham,figueiredo,festa,ferrier,fellman,eslick,eilerman,eckart,eaglin,dunfee,dumond,drewry,douse,dimick,diener,dickert,deines,declue,daw,dattilo,danko,custodio,cuccia,crunk,crispin,corp,corea,coppin,considine,coniglio,conboy,cockrum,clute,clewis,christiano,channell,cerrato,cecere,catoe,castillon,castile,carstarphen,carmouche,caperton,buteau,bumpers,brey,brazeal,brassard,braga,bradham,bourget,borrelli,borba,boothby,bohr,bohm,boehme,bodin,bloss,blocher,bizzell,bieker,berthelot,bernardini,berends,benard,belser,baze,bartling,barrientes,barras,barcia,banfield,aurand,artman,arnott,arend,amon,almaguer,allee,albarado,alameda,abdo,zuehlke,zoeller,yokoyama,yocom,wyllie,woolum,wint,winland,wilner,wilmes,whitlatch,westervelt,walthall,walkowiak,walburn,viviano,vanderhoff,valez,ugalde,trumbull,todaro,tilford,tidd,tibbits,terranova,templeman,tannenbaum,talmage,tabarez,swearengin,swartwood,svendsen,strum,strack,storie,stockard,steinbeck,starns,stanko,stankiewicz,stacks,stach,sproles,spenser,smotherman,slusser,sinha,silber,siefert,siddiqui,shuff,sherburne,seldon,seddon,schweigert,schroeter,schmucker,saffold,rutz,rundle,rosinski,rosenow,rogalski,ridout,rhymer,replogle,raygoza,ratner,rascoe,rahm,quast,pressnell,predmore,pou,porto,pleasants,pigford,pavone,patnaude,parramore,papadopoulos,palmatier,ouzts,oshields,ortis,olmeda,olden,okamoto,norby,nitz,niebuhr,nevius,neiman,neidig,neece,murawski,mroz,moylan,moultry,mosteller,moring,morganti,mook,moffet,mettler,merlo,mengel,mendelsohn,meli,melchior,mcmeans,mcfaddin,mccullers,mccollister,mccloy,mcclaine,maury,maser,martelli,manthey,malkin,maio,magwood,maginnis,mabon,luton,lusher,lucht,lobato,levis,letellier,legendre,latson,larmon,largo,landreneau,landgraf,lamberson,kurland,kresge,korman,korando,klapper,kitson,kinyon,kincheloe,kawamoto,kawakami,jenney,jeanpierre,ivers,issa,ince,hollier,hollars,hoerner,hodgkinson,hiott,hibbitts,herlihy,henricks,heavner,hayhurst,harvill,harewood,hanselman,hanning,gustavson,grizzard,graybeal,gravley,gorney,goll,goehring,godines,gobeil,glickman,giuliano,gimbel,geib,gayhart,gatti,gains,gadberry,frei,fraise,fouch,forst,forsman,folden,fogleman,fetty,feely,fabry,eury,estill,epling,elamin,echavarria,dutil,duryea,dumais,drago,downard,douthit,doolin,dobos,dison,dinges,diebold,desilets,deshazo,depaz,degennaro,dall,cyphers,cryer,croce,crisman,credle,coriell,copp,compos,colmenero,cogar,carnevale,campanella,caley,calderone,burtch,brouwer,brehmer,brassell,brafford,bourquin,bourn,bohnert,blewett,blass,blakes,bhakta,besser,berge,bellis,balfour,avera,applin,ammon,alsop,aleshire,akbar,zoller,zapien,wymore,wyble,wolken,wix,wickstrom,whobrey,whigham,westerlund,welsch,weisser,weisner,weinstock,wehner,watlington,wakeland,wafer,victorino,veltri,veith,urich,uresti,umberger,twedt,tuohy,tschida,trumble,troia,trimmer,topps,tonn,tiernan,threet,thrall,thetford,teneyck,tartaglia,strohl,streater,strausbaugh,stradley,stonecipher,steadham,stansel,stalcup,stabile,sprenger,spradley,speier,southwood,sorrels,slezak,skow,sirmans,simental,sifford,sievert,shover,sheley,selzer,scriven,schwindt,schwan,schroth,saylors,saragosa,sant,salaam,saephan,routt,rousey,ros,rolfes,rieke,rieder,richeson,redinger,rasnick,rapoza,rambert,quist,pyron,pullman,przybylski,pridmore,pooley,pines,perkinson,perine,perham,pecor,peavler,partington,panton,oliverio,olague,ohman,ohearn,noyola,nicolai,nebel,murtha,mowrey,moroney,morgenstern,morant,monsour,moffit,mijares,meriwether,mendieta,melendrez,mejorado,mckittrick,mckey,mckenny,mckelvy,mcelvain,mccoin,mazzarella,mazon,maurin,matthies,maston,maske,marzano,marmon,marburger,mangus,mangino,mallet,luo,losada,londono,lobdell,lipson,lesniak,leighty,lei,lavallie,lareau,laperle,lape,laforce,laffey,kuehner,kravitz,kowalsky,kohr,kinsman,keppler,kennemer,keiper,kaler,jun,jelinek,jarnagin,isakson,hypes,hutzler,huls,horak,hitz,hice,herrell,henslee,heitz,heiss,heiman,hasting,hartwick,harmer,hammontree,hakes,guse,guillotte,groleau,greve,greenough,golub,golson,goldschmidt,golder,godbolt,gilmartin,gies,gibby,geren,genthner,gendreau,gemmill,gaymon,galyean,galeano,friar,folkerts,fleeman,fitzgibbons,ferranti,felan,farrand,eoff,enger,engels,ducksworth,duby,drumheller,douthitt,donis,dixion,dittrich,dials,descoteaux,depaul,denker,demuth,demelo,delacerda,deforge,danos,dalley,daigneault,cybulski,cothren,corns,corkery,copas,clubb,clore,chitty,chichester,chace,catanzaro,castonguay,cassella,carlberg,cammarata,calle,cajigas,byas,buzbee,busey,burling,bufkin,brzezinski,brun,brickner,brabham,boller,bockman,bleich,blakeman,bisbee,bier,bezanson,bevilacqua,besaw,berrian,bequette,beauford,baumgarten,baudoin,batie,basaldua,bardin,bangert,banes,backlund,avitia,artz,archey,apel,amico,alam,aden,zebrowski,yokota,wormley,wootton,womac,wiltz,wigington,whitehorn,whisman,weisgerber,weigle,weedman,watkin,wasilewski,wadlington,wadkins,viverette,vidaurri,vidales,vezina,vanleer,vanhoy,vanguilder,vanbrunt,updegraff,tylor,trinkle,touchette,tilson,tilman,tengan,tarkington,surrett,summy,streetman,straughter,steere,spruell,spadaro,solley,smathers,silvera,siems,shreffler,sholar,selden,schaper,samayoa,ruggeri,rowen,rosso,rosenbalm,roose,ronquillo,rogowski,rexford,repass,renzi,renick,rehberg,ranck,raffa,rackers,raap,puglisi,prinz,pounders,pon,pompa,plasencia,pipkins,petrosky,pelley,pauls,pauli,parkison,parisien,pangle,pancoast,palazzolo,owenby,overbay,orris,orlowski,nipp,newbern,nedd,nealon,najar,mysliwiec,myres,musson,murrieta,munsell,mumma,muldowney,moyle,mowen,morejon,moodie,monier,mikkelsen,miers,metzinger,melin,mcquay,mcpeek,mcneeley,mcglothin,mcghie,mcdonell,mccumber,mccranie,mcbean,mayhugh,marts,marenco,manges,lynam,lupien,luff,luebbert,loh,loflin,lococo,loch,lis,linke,lightle,lewellyn,leishman,lebow,lebouef,leanos,lanz,landy,landaverde,lacefield,kyler,kuebler,kropf,kroeker,kluesner,klass,kimberling,kilkenny,kiker,ketter,kelemen,keasler,kawamura,karst,kardos,igo,huseman,huseby,hurlbert,huard,hottinger,hornberger,hopps,holdsworth,hensen,heilig,heeter,harpole,haak,gutowski,gunnels,grimmer,gravatt,granderson,gotcher,gleaves,genao,garfinkel,frerichs,foushee,flanery,finnie,feldt,fagin,ewalt,ellefson,eiler,eckhart,eastep,digirolamo,didomenico,devera,delavega,defilippo,debusk,daub,damiani,cupples,crofoot,courter,coto,costigan,corning,corman,corlett,cooperman,collison,coghlan,cobbins,coady,coachman,clothier,cipolla,chmielewski,chiodo,chatterton,chappelle,chairez,ceron,casperson,casler,casados,carrow,carlino,carico,cardillo,caouette,canto,canavan,cambra,byard,buterbaugh,buse,bucy,buckwalter,bubb,bryd,brissette,brault,bradwell,boshears,borchert,blansett,biondo,biehl,bessey,belles,beeks,beekman,beaufort,bayliss,bardsley,avilla,astudillo,ardito,antunez,aderholt,abate,yowell,yin,yearby,wurst,woolverton,woolbright,wildermuth,whittenburg,whitely,wetherbee,wenz,welliver,welling,wason,warlick,voorhies,vivier,villines,verde,veiga,varghese,vanwyk,vanwingerden,vanhorne,umstead,twiggs,tusing,trego,tompson,tinkle,thoman,thole,tatman,tartt,suda,studley,strock,strawbridge,stokely,stec,stalter,speidel,spafford,sontag,sokolowski,skillman,skelley,skalski,sison,sippel,sinquefield,siegle,sher,sharrow,setliff,sellner,selig,seibold,seery,scriber,schull,schrupp,schippers,saulsbury,sao,santillo,sanor,rubalcaba,roosa,ronk,robbs,roache,riebe,reinoso,quin,preuss,pottorff,pontiff,plouffe,picou,picklesimer,pettyjohn,petti,penaloza,parmelee,pardee,palazzo,overholt,ogawa,ofarrell,nolting,noda,nickson,nevitt,neveu,navarre,murrow,munz,mulloy,monzo,milliman,metivier,merlino,mcpeters,mckissack,mckeen,mcgurk,mcfee,mcfarren,mcelwee,mceachin,mcdonagh,mccarville,mayhall,mattoon,martello,marconi,marbury,manzella,maly,malec,maitland,maheu,maclennan,lyke,luera,lowenstein,losh,lopiccolo,longacre,loman,loden,loaiza,lieber,libbey,lenhardt,lefebre,lauterbach,lauritsen,lass,larocco,larimer,lansford,lanclos,lamay,lal,kulikowski,kriebel,kosinski,kleinman,kleiner,kleckner,kistner,kissner,kissell,keisler,keeble,keaney,kale,joly,jimison,ikner,hursey,hruska,hove,hou,hosking,hoose,holle,hoeppner,hittle,hitchens,hirth,hinerman,higby,hertzog,hentz,hensler,heier,hegg,hassel,harpe,hara,hain,hagopian,grimshaw,grado,gowin,gowans,googe,goodlow,goering,gleaton,gidley,giannone,gascon,garneau,gambrel,galaz,fuentez,frisina,fresquez,fraher,feuerstein,felten,everman,ertel,erazo,ensign,endo,ellerman,eichorn,edgell,ebron,eaker,dundas,duncanson,duchene,ducan,dombroski,doman,dickison,dewoody,deloera,delahoussaye,dejean,degroat,decaro,dearmond,dashner,dales,crossett,cressey,cowger,cornette,corbo,coplin,coover,condie,cokley,ceaser,cannaday,callanan,cadle,buscher,bullion,bucklin,bruening,bruckner,brose,branan,bradway,botsford,bortz,borelli,bonetti,bolan,boerger,bloomberg,bingman,bilger,berns,beringer,beres,beets,beede,beaudet,beachum,baughn,bator,bastien,basquez,barreiro,barga,baratta,balser,baillie,axford,attebery,arakaki,annunziata,andrzejewski,ament,amendola,adcox,abril,zenon,zeitler,zambrana,ybanez,yagi,wolak,wilcoxson,whitesel,whitehair,weyand,westendorf,welke,weinmann,weesner,weekes,wedel,weatherall,warthen,vose,villalta,viator,vaz,valtierra,urbanek,tulley,trojanowski,trapani,toups,torpey,tomita,tindal,tieman,tevis,tedrow,taul,tash,tammaro,sylva,swiderski,sweeting,sund,stutler,stich,sterns,stegner,stalder,splawn,speirs,southwell,soltys,smead,slye,skipworth,sipos,simmerman,sidhu,shuffler,shingleton,shadwick,sermons,seefeldt,scipio,schwanke,schreffler,schiro,scheiber,sandoz,samsel,ruddell,royse,rouillard,rotella,rosalez,romriell,rizer,riner,rickards,rhoton,rhem,reppert,rayl,raulston,raposo,rainville,radel,quinney,purdie,pizzo,pincus,petrus,pendelton,pendarvis,peltz,peguero,peete,patricio,patchett,parrino,papke,palafox,ottley,ostby,oritz,ogan,odegaard,oatman,noell,nicoll,newhall,newbill,netzer,nettleton,neblett,murley,mungo,mulhall,mosca,morissette,morford,monsen,mitzel,miskell,minder,mehaffey,mcquillen,mclennan,mcgrail,mccreight,mayville,maysonet,maust,mathieson,mastrangelo,maskell,manz,malmberg,makela,madruga,lotts,longnecker,logston,littell,liska,lindauer,lillibridge,levron,letchworth,lesh,leffel,leday,leamon,kulas,kula,kucharski,kromer,kraatz,konieczny,konen,komar,kivett,kirts,kinnear,kersh,keithley,keifer,judah,jimenes,jeppesen,jansson,huntsberry,hund,huitt,huffine,hosford,holmstrom,hollen,hodgin,hirschman,hiltner,hilliker,hibner,hennis,helt,heidelberg,heger,heer,hartness,hardrick,halladay,gula,guillaume,guerriero,grunewald,grosse,griffeth,grenz,grassi,grandison,ginther,gimenez,gillingham,gillham,gess,gelman,gearheart,gaskell,gariepy,gamino,gallien,galentine,fuquay,froman,froelich,friedel,foos,fomby,focht,flythe,fiqueroa,filson,filip,fierros,fett,fedele,fasching,farney,fargo,everts,etzel,elzey,eichner,eger,eatman,ducker,duchesne,donati,domenech,dollard,dodrill,dinapoli,denn,delfino,delcid,delaune,delatte,deems,daluz,cusson,cullison,cuadrado,crumrine,cruickshank,crosland,croll,criddle,crepeau,coutu,couey,cort,coppinger,collman,cockburn,coca,clayborne,claflin,cissell,chowdhury,chicoine,chenier,causby,caulder,cassano,casner,cardiel,brunton,bruch,broxton,brosius,brooking,branco,bracco,bourgault,bosserman,bonet,bolds,bolander,bohman,boelter,blohm,blea,blaise,bischof,beus,bellew,bastarache,bast,bartolome,barcomb,barco,balk,balas,bakos,avey,atnip,ashbrook,arno,arbour,aquirre,appell,aldaco,alban,ahlstrom,abadie,zylstra,zick,yother,wyse,wunsch,whitty,weist,vrooman,villalon,vidrio,vavra,vasbinder,vanmatre,vandorn,ugarte,turberville,tuel,trogdon,toupin,toone,tolleson,tinkham,tinch,tiano,teston,teer,tawney,taplin,tant,tansey,swayne,sutcliffe,sunderman,strothers,stromain,stork,stoneburner,stolte,stolp,stoehr,stingley,stegman,stangl,spinella,spier,soules,sommerfield,sipp,simek,siders,shufelt,shue,shor,shires,shellenberger,sheely,sepe,seaberg,schwing,scherrer,scalzo,sasse,sarvis,santora,sansbury,salls,saleem,ryland,rybicki,ruggieri,rothenberg,rosenstein,roquemore,rollison,rodden,rivet,ridlon,riche,riccardi,reiley,regner,rech,rayo,raff,radabaugh,quon,quill,privette,prange,pickrell,perino,penning,pankratz,orlandi,nyquist,norrell,noren,naples,nale,nakashima,musselwhite,murrin,murch,mullinix,mullican,mullan,morneau,mondor,molinar,minjares,minix,minchew,milewski,mikkelson,mifflin,merkley,meis,meas,mcroy,mcphearson,mcneel,mcmunn,mcmorrow,mcdorman,mccroskey,mccoll,mcclusky,mcclaran,mccampbell,mazzariello,mauzy,mauch,mastro,martinek,marsala,marcantel,mahle,luciani,lubbers,lobel,linch,liller,legros,layden,lapine,lansberry,lage,laforest,labriola,koga,knupp,klimek,kittinger,kirchoff,kinzel,killinger,kilbourne,ketner,kepley,kemble,kells,kear,kaya,karsten,kaneshiro,kamm,joines,joachim,jacobus,iler,holgate,hoar,hisey,hird,hilyard,heslin,herzberg,hennigan,hegland,hartl,haner,handel,gualtieri,greenly,grasser,goetsch,godbold,gilland,gidney,gibney,giancola,gettinger,garzon,galle,galgano,gaier,gaertner,fuston,freel,fortes,fiorillo,figgs,fenstermacher,fedler,facer,fabiano,evins,euler,esquer,enyeart,elem,eich,edgerly,durocher,durgan,duffin,drolet,drewes,dotts,dossantos,dockins,dirksen,difiore,dierks,dickerman,dery,denault,demaree,delmonte,delcambre,daulton,darst,dahle,curnutt,cully,culligan,cueva,crosslin,croskey,cromartie,crofts,covin,coutee,coppa,coogan,condrey,concannon,coger,cloer,clatterbuck,cieslak,chumbley,choudhury,chiaramonte,charboneau,carneal,cappello,campisi,callicoat,burgoyne,bucholz,brumback,brosnan,brogden,broder,brendle,breece,bown,bou,boser,bondy,bolster,boll,bluford,blandon,biscoe,bevill,bence,battin,basel,bartram,barnaby,barmore,balbuena,badgley,backstrom,auyeung,ater,arrellano,arant,ansari,alling,alejandre,alcock,alaimo,aguinaldo,aarons,zurita,zeiger,zawacki,yutzy,yarger,wygant,wurm,wuest,witherell,wisneski,whitby,whelchel,weisz,weisinger,weishaar,wehr,waxman,waldschmidt,walck,waggener,vosburg,villela,vercher,venters,vanscyoc,vandyne,valenza,utt,urick,ungar,ulm,tumlin,tsao,tryon,trudel,treiber,tober,tipler,tillson,tiedemann,thornley,tetrault,temme,tarrance,tackitt,sykora,sweetman,swatzell,sutliff,suhr,sturtz,strub,strayhorn,stormer,steveson,stengel,steinfeldt,spiro,spieker,speth,spero,soza,souliere,soucie,snedeker,slifer,skillings,situ,siniard,simeon,signorelli,siggers,shultis,shrewsbury,shippee,shimp,shepler,sharpless,shadrick,severt,severs,semon,semmes,seiter,segers,sclafani,sciortino,schroyer,schrack,schoenberg,schober,scheidt,scheele,satter,sartori,sarratt,salvaggio,saladino,sakamoto,saine,ryman,rumley,ruggerio,rucks,roughton,robards,ricca,rexroad,resler,reny,rentschler,redrick,redick,reagle,raymo,raker,racette,pyburn,pritt,presson,pressman,pough,pisani,perz,perras,pelzer,pedrosa,palos,palmisano,paille,orem,orbison,oliveros,nourse,nordquist,newbury,nelligan,nawrocki,myler,mumaw,morphis,moldenhauer,miyashiro,mignone,mickelsen,michalec,mesta,mcree,mcqueary,mcninch,mcneilly,mclelland,mclawhorn,mcgreevy,mcconkey,mattes,maselli,marten,marcucci,manseau,manjarrez,malbrough,machin,mabie,lynde,lykes,lueras,lokken,loken,linzy,lillis,lilienthal,levey,legler,leedom,lebowitz,lazzaro,larabee,lapinski,langner,langenfeld,lampkins,lamotte,lambright,lagarde,ladouceur,labounty,lablanc,laberge,kyte,kroon,kron,kraker,kouba,kirwin,kincer,kimbler,kegler,keach,katzman,katzer,kalman,jimmerson,jenning,janus,iacovelli,hust,huson,husby,humphery,hufnagel,honig,holsey,holoman,hohl,hogge,hinderliter,hildebrant,hemby,helle,heintzelman,heidrick,hearon,hazelip,hauk,hasbrouck,harton,hartin,harpster,hansley,hanchett,haar,guthridge,gulbranson,guill,guerrera,grund,grosvenor,grist,grell,grear,granberry,gonser,giunta,giuliani,gillon,gillmore,gillan,gibbon,gettys,gelb,gano,galliher,fullen,frese,frates,foxwell,fleishman,fleener,fielden,ferrera,fells,feemster,fauntleroy,evatt,espy,eno,emmerich,edler,eastham,dunavant,duca,drinnon,dowe,dorgan,dollinger,dipalma,difranco,dietrick,denzer,demarest,delee,delariva,delany,decesare,debellis,deavers,deardorff,dawe,darosa,darley,dalzell,dahlen,curto,cupps,cunniff,cude,crivello,cripps,cresswell,cousar,cotta,compo,clyne,clayson,cearley,catania,carini,cantero,buttrey,buttler,burpee,bulkley,buitron,buda,bublitz,bryer,bryden,brouillette,brott,brookman,bronk,breshears,brennen,brannum,brandl,braman,bracewell,boyter,bomberger,bogen,boeding,blauvelt,blandford,biermann,bielecki,bibby,berthold,berkman,belvin,bellomy,beland,behne,beecham,becher,bax,bassham,barret,baley,auxier,atkison,ary,arocha,arechiga,anspach,algarin,alcott,alberty,ager,ackman,abdallah,zwick,ziemer,zastrow,zajicek,yokum,yokley,wittrock,winebarger,wilker,wilham,whitham,wetzler,westling,westbury,wendler,wellborn,weitzman,weitz,wallner,waldroup,vrabel,vowels,volker,vitiello,visconti,villicana,vibbert,vesey,vannatter,vangilder,vandervort,vandegrift,vanalstyne,vallecillo,usrey,tynan,turpen,tuller,trisler,townson,tillmon,threlkeld,thornell,terrio,taunton,tarry,tardy,swoboda,swihart,sustaita,suitt,stuber,strine,stookey,stmartin,stiger,stainbrook,solem,smail,sligh,siple,sieben,shumake,shriner,showman,sheen,sheckler,seim,secrist,scoggin,schultheis,schmalz,schendel,schacher,savard,saulter,santillanes,sandiford,sande,salzer,salvato,saltz,sakai,ryckman,ryant,ruck,rittenberry,ristau,richart,rhynes,reyer,reulet,reser,redington,reddington,rebello,reasor,raftery,rabago,raasch,quintanar,pylant,purington,provencal,prioleau,prestwood,pothier,popa,polster,politte,poffenberger,pinner,pietrzak,pettie,penaflor,pellot,pellham,paylor,payeur,papas,paik,oyola,osbourn,orzechowski,oppenheimer,olesen,oja,ohl,nuckolls,nordberg,noonkester,nold,nitta,niblett,neuhaus,nesler,nanney,myrie,mutch,mosquera,morena,montalto,montagna,mizelle,mincy,millikan,millay,miler,milbourn,mikels,migues,miesner,mershon,merrow,meigs,mealey,mcraney,mcmartin,mclachlan,mcgeehan,mcferren,mcdole,mccaulley,mcanulty,maziarz,maul,mateer,martinsen,marson,mariotti,manna,mance,malbon,magnusson,maclachlan,macek,lurie,luc,lown,loranger,lonon,lisenby,linsley,lenk,leavens,lauritzen,lathem,lashbrook,landman,lamarche,lamantia,laguerre,lagrange,kogan,klingbeil,kist,kimpel,kime,kier,kerfoot,kennamer,kellems,kammer,kamen,jepsen,jarnigan,isler,ishee,hux,hungate,hummell,hultgren,huffaker,hruby,hornick,hooser,hooley,hoggan,hirano,hilley,higham,heuser,henrickson,henegar,hellwig,hedley,hasegawa,hartt,hambright,halfacre,hafley,guion,guinan,grunwald,grothe,gries,greaney,granda,grabill,gothard,gossman,gosser,gossard,gosha,goldner,gobin,ginyard,gilkes,gilden,gerson,gephart,gengler,gautier,gassett,garon,galusha,gallager,galdamez,fulmore,fritsche,fowles,foutch,footman,fludd,ferriera,ferrero,ferreri,fenimore,fegley,fegan,fearn,farrier,fansler,fane,falzone,fairweather,etherton,elsberry,dykema,duppstadt,dunnam,dunklin,duet,dudgeon,dubuc,doxey,donmoyer,dodgen,disanto,dingler,dimattia,dilday,digennaro,diedrich,derossett,depp,demasi,degraffenreid,deakins,deady,davin,daigre,daddario,czerwinski,cullens,cubbage,cracraft,combest,coletti,coghill,claybrooks,christofferse,chiesa,chason,chamorro,celentano,cayer,carolan,carnegie,capetillo,callier,cadogan,caba,byrom,byrns,burrowes,burket,burdge,burbage,buchholtz,brunt,brungardt,brunetti,brumbelow,brugger,broadhurst,brigance,brandow,bouknight,bottorff,bottomley,bosarge,borger,bombardier,boggan,blumer,blecha,birney,birkland,betances,beran,belin,belgrave,bealer,bauch,bashir,bartow,baro,barnhouse,barile,ballweg,baisley,bains,baehr,badilla,bachus,bacher,bachelder,auzenne,aten,astle,allis,agarwal,adger,adamek,ziolkowski,zinke,zazueta,zamorano,younkin,wittig,witman,winsett,winkles,wiedman,whitner,whitcher,wetherby,westra,westhoff,wehrle,wagaman,voris,vicknair,veasley,vaugh,vanderburg,valletta,tunney,trumbo,truluck,trueman,truby,trombly,tourville,tostado,titcomb,timpson,tignor,thrush,thresher,thiede,tews,tamplin,taff,tacker,syverson,sylvestre,summerall,stumbaugh,strouth,straker,stradford,stokley,steinhoff,steinberger,spigner,soltero,snively,sletten,sinkler,sinegal,simoes,siller,sigel,shire,shinkle,shellman,sheller,sheats,sharer,selvage,sedlak,schriver,schimke,scheuerman,schanz,savory,saulters,sauers,sais,rusin,rumfelt,ruhland,rozar,rosborough,ronning,rolph,roloff,robie,rimer,riehle,ricco,rhein,retzlaff,reisman,reimann,rayes,raub,raminez,quesinberry,pua,procopio,priolo,printz,prewett,preas,prahl,poovey,ploof,platz,plaisted,pinzon,pineiro,pickney,petrovich,perl,pehrson,peets,pavon,pautz,pascarella,paras,paolini,pafford,oyer,ovellette,outten,outen,orduna,odriscoll,oberlin,nosal,niven,nisbett,nevers,nathanson,mukai,mozee,mowers,motyka,morency,montford,mollica,molden,mitten,miser,millender,midgette,messerly,melendy,meisel,meidinger,meany,mcnitt,mcnemar,mcmakin,mcgaugh,mccaa,mauriello,maudlin,matzke,mattia,matsumura,masuda,mangels,maloof,malizia,mahmoud,maglione,maddix,lucchesi,lochner,linquist,lietz,leventhal,lemanski,leiser,laury,lauber,lamberth,kuss,kulik,kuiper,krout,kotter,kort,kohlmeier,koffler,koeller,knipe,knauss,kleiber,kissee,kirst,kirch,kilgo,kerlin,kellison,kehl,kalb,jorden,jantzen,inabinet,ikard,husman,hunsberger,hundt,hucks,houtz,houseknecht,hoots,hogsett,hogans,hintze,hession,henault,hemming,helsley,heinen,heffington,heberling,heasley,hazley,hazeltine,hayton,hayse,hawke,haston,harward,harrow,hanneman,hafford,hadnot,guerro,grahm,gowins,gordillo,goosby,glatt,gibbens,ghent,gerrard,germann,gebo,gean,garling,gardenhire,garbutt,gagner,furguson,funchess,fujiwara,fujita,friley,frigo,forshee,folkes,filler,fernald,ferber,feingold,faul,farrelly,fairbank,failla,espey,eshleman,ertl,erhart,erhardt,erbe,elsea,ells,ellman,eisenhart,ehmann,earnhardt,duplantis,dulac,ducote,draves,dosch,dolce,divito,dimauro,derringer,demeo,demartini,delima,dehner,degen,defrancisco,defoor,dedeaux,debnam,cypert,cutrer,cusumano,custis,croker,courtois,costantino,cormack,corbeil,copher,conlan,conkling,cogdell,cilley,chapdelaine,cendejas,castiglia,cashin,carstensen,caprio,calcote,calaway,byfield,butner,bushway,burritt,browner,brobst,briner,bridger,brickley,brendel,bratten,bratt,brainerd,brackman,bowne,bouck,borunda,bordner,bonenfant,boer,boehmer,bodiford,bleau,blankinship,blane,blaha,bitting,bissonette,bigby,bibeau,bermudes,berke,bergevin,bergerson,bendel,belville,bechard,bearce,beadles,batz,bartlow,ayoub,avans,aumiller,arviso,arpin,arnwine,armwood,arent,arehart,arcand,antle,ambrosino,alongi,alm,allshouse,ahart,aguon,ziebarth,zeledon,zakrzewski,yuhas,yingst,yedinak,wommack,winnett,wingler,wilcoxen,whitmarsh,wayt,watley,warkentin,voll,vogelsang,voegele,vivanco,vinton,villafane,viles,ver,venne,vanwagoner,vanwagenen,vanleuven,vanauken,uselton,uren,trumbauer,tritt,treadaway,tozier,tope,tomczak,tomberlin,tomasini,tollett,toller,titsworth,tirrell,tilly,tavera,tarnowski,tanouye,swarthout,sutera,surette,styers,styer,stipe,stickland,stembridge,stearn,starkes,stanberry,stahr,spino,spicher,sperber,speece,sonntag,sneller,smalling,slowik,slocumb,sliva,slemp,slama,sitz,sisto,sisemore,sindelar,shipton,shillings,sheeley,sharber,shaddix,severns,severino,sensabaugh,seder,seawell,seamons,schrantz,schooler,scheffer,scheerer,scalia,saum,santibanez,sano,sanjuan,sampley,sailer,sabella,sabbagh,royall,rottman,rivenbark,rikard,ricketson,rickel,rethman,reily,reddin,reasoner,rast,ranallo,quintal,pung,pucci,proto,prosperie,prim,preusser,preslar,powley,postma,pinnix,pilla,pietsch,pickerel,pica,pharris,petway,petillo,perin,pereda,pennypacker,pennebaker,pedrick,patin,patchell,parodi,parman,pantano,padua,padro,osterhout,orner,olivar,ohlson,odonoghue,oceguera,oberry,novello,noguera,newquist,newcombe,neihoff,nehring,nees,nebeker,mundo,mullenix,morrisey,moronta,morillo,morefield,mongillo,molino,minto,midgley,michie,menzies,medved,mechling,mealy,mcshan,mcquaig,mcnees,mcglade,mcgarity,mcgahey,mcduff,mayweather,mastropietro,masten,maranto,maniscalco,maize,mahmood,maddocks,maday,macha,maag,luken,lopp,lolley,llanas,litz,litherland,lindenberg,lieu,letcher,lentini,lemelle,leet,lecuyer,leber,laursen,larrick,lantigua,langlinais,lalli,lafever,labat,labadie,krogman,kohut,knarr,klimas,klar,kittelson,kirschbaum,kintzel,kincannon,kimmell,killgore,kettner,kelsch,karle,kapoor,johansson,jenkinson,janney,iraheta,insley,hyslop,huckstep,holleran,hoerr,hinze,hinnenkamp,hilger,higgin,hicklin,heroux,henkle,helfer,heikkinen,heckstall,heckler,heavener,haydel,haveman,haubert,harrop,harnois,hansard,hanover,hammitt,haliburton,haefner,hadsell,haakenson,guynn,guizar,grout,grosz,gomer,golla,godby,glanz,glancy,givan,giesen,gerst,gayman,garraway,gabor,furness,frisk,fremont,frary,forand,fessenden,ferrigno,fearon,favreau,faulks,falbo,ewen,eurich,etchison,esterly,entwistle,ellingsworth,eisenbarth,edelson,eckel,earnshaw,dunneback,doyal,donnellan,dolin,dibiase,deschenes,dermody,degregorio,darnall,dant,dansereau,danaher,dammann,dames,czarnecki,cuyler,custard,cummingham,cuffie,cuffee,cudney,cuadra,crigler,creger,coughlan,corvin,cortright,corchado,connery,conforti,condron,colosimo,colclough,cohee,ciotti,chien,chacko,cevallos,cavitt,cavins,castagna,cashwell,carrozza,carrara,capra,campas,callas,caison,caggiano,bynoe,buswell,burpo,burnam,burges,buerger,buelow,bueche,bruni,brummitt,brodersen,briese,breit,brakebill,braatz,boyers,boughner,borror,borquez,bonelli,bohner,blaker,blackmer,bissette,bibbins,bhatt,bhatia,bessler,bergh,beresford,bensen,benningfield,bellantoni,behler,beehler,beazley,beauchesne,bargo,bannerman,baltes,balog,ballantyne,axelson,apgar,aoki,anstett,alejos,alcocer,albury,aichele,ackles,zerangue,zehner,zank,zacarias,youngberg,yorke,yarbro,wydra,worthley,wolbert,wittmer,witherington,wishart,winkleman,willilams,willer,wiedeman,whittingham,whitbeck,whetsel,wheless,westerberg,welcher,wegman,waterfield,wasinger,warfel,wannamaker,walborn,wada,vogl,vizcarrondo,vitela,villeda,veras,venuti,veney,ulrey,uhlig,turcios,tremper,torian,torbett,thrailkill,terrones,teitelbaum,teems,swoope,sunseri,stutes,stthomas,strohm,stroble,striegel,streicher,stodola,stinchcomb,steves,steppe,steller,staudt,starner,stamant,stam,stackpole,sprankle,speciale,spahr,sowders,sova,soluri,soderlund,slinkard,sjogren,sirianni,siewert,sickels,sica,shugart,shoults,shive,shimer,shier,shepley,sheeran,sevin,seto,segundo,sedlacek,scuderi,schurman,schuelke,scholten,schlater,schisler,schiefelbein,schalk,sanon,sabala,ruyle,ruybal,rueb,rowsey,rosol,rocheleau,rishel,rippey,ringgold,rieves,ridinger,retherford,rempe,reith,rafter,raffaele,quinto,putz,purdom,puls,pulaski,propp,principato,preiss,prada,polansky,poch,plath,pittard,pinnock,pfarr,pfannenstiel,penniman,pauling,patchen,paschke,parkey,pando,ouimet,ottman,ostlund,ormiston,occhipinti,nowacki,norred,noack,nishida,nilles,nicodemus,neth,nealey,myricks,murff,mungia,motsinger,moscato,morado,monnier,molyneux,modzelewski,miura,minich,militello,milbrandt,michalik,meserve,mendivil,melara,mcnish,mcelhannon,mccroy,mccrady,mazzella,maule,mattera,mathena,matas,mascorro,marinello,marguez,manwaring,manhart,mangano,maggi,lymon,luter,luse,lukasik,luiz,ludlum,luczak,lowenthal,lossett,lorentzen,loredo,longworth,lomanto,lisi,lish,lipsky,linck,liedtke,levering,lessman,lemond,lembo,ledonne,leatham,laufer,lanphear,langlais,lamphear,lamberton,lafon,lade,lacross,kyzer,krok,kring,krell,krehbiel,kratochvil,krach,kovar,kostka,knudtson,knaack,kliebert,klahn,kirkley,kimzey,kerrick,kennerson,keesler,karlin,janousek,imel,icenhour,hyler,hudock,houpt,holquin,holiman,holahan,hodapp,hillen,hickmon,hersom,henrich,helvey,heidt,heideman,hedstrom,hedin,hebron,hayter,harn,hardage,halsted,hahne,hagemann,guzik,guel,groesbeck,gritton,grego,graziani,grasty,graney,gouin,gossage,golston,goheen,godina,glade,giorgi,giambrone,gerrity,gerrish,gero,gerling,gaulke,garlick,galiano,gaiter,gahagan,gagnier,friddle,fredericksen,franqui,follansbee,foerster,flury,fitzmaurice,fiorini,finlayson,fiecke,fickes,fichter,ferron,farrel,fackler,eyman,escarcega,errico,erler,erby,engman,engelmann,elsass,elliston,eddleman,eadie,dummer,drost,dorrough,dorrance,doolan,donalson,domenico,ditullio,dittmar,dishon,dionisio,dike,devinney,desir,deschamp,derrickson,delamora,deitch,dechant,danek,dahmen,curci,cudjoe,croxton,creasman,craney,crader,cowling,coulston,cortina,corlew,corl,copland,convery,cohrs,clune,clausing,cipriani,cianciolo,chubb,chittum,chenard,charlesworth,charlebois,champine,chamlee,chagoya,casselman,cardello,capasso,cannella,calderwood,byford,buttars,bushee,burrage,buentello,brzozowski,bryner,brumit,brookover,bronner,bromberg,brixey,brinn,briganti,bremner,brawn,branscome,brannigan,bradsher,bozek,boulay,bormann,bongiorno,bollin,bohler,bogert,bodenhamer,blose,bivona,billips,bibler,benfer,benedetti,belue,bellanger,belford,behn,barnhardt,baltzell,balling,balducci,bainter,babineau,babich,baade,attwood,asmus,asaro,artiaga,applebaum,anding,amar,amaker,allsup,alligood,alers,agin,agar,achenbach,abramowitz,abbas,aasen,zehnder,yopp,yelle,yeldell,wynter,woodmansee,wooding,woll,winborne,willsey,willeford,widger,whiten,whitchurch,whang,weissinger,weinman,weingartner,weidler,waltrip,wagar,wafford,vitagliano,villalvazo,villacorta,vigna,vickrey,vicini,ventimiglia,vandenbosch,valvo,valazquez,utsey,urbaniak,unzueta,trombetta,trevizo,trembley,tremaine,traverso,tores,tolan,tillison,tietjen,teachout,taube,tatham,tarwater,tarbell,sydow,swims,swader,striplin,stoltenberg,steinhauer,steil,steigerwald,starkweather,stallman,squier,sparacino,spadafora,shiflet,shibata,shevlin,sherrick,sessums,servais,senters,seevers,seelye,searfoss,seabrooks,scoles,schwager,schrom,schmeltzer,scheffel,sawin,saterfiel,sardina,sanroman,sandin,salamanca,saladin,sabia,rustin,rushin,ruley,rueter,rotter,rosenzweig,rohe,roder,riter,rieth,ried,ridder,rennick,remmers,remer,relyea,reilley,reder,rasheed,rakowski,rabin,queener,pursel,prowell,pritts,presler,pouncy,porche,porcaro,pollman,pleas,planas,pinkley,pinegar,pilger,philson,petties,perrodin,pendergrast,patao,pasternak,passarelli,pasko,parshall,panos,panella,palombo,padillo,oyama,overlock,overbeck,otterson,orrell,ornellas,opitz,okelly,obando,noggle,nicosia,netto,negrin,natali,nakayama,nagao,nadel,musial,murrill,murrah,munsch,mucci,mrozek,moyes,mowrer,moris,morais,moorhouse,monico,mondy,moncayo,miltenberger,milsap,milone,millikin,milardo,micheals,micco,meyerson,mericle,mendell,meinhardt,meachum,mcleroy,mcgray,mcgonigal,maultsby,matis,matheney,matamoros,marro,marcil,marcial,mantz,mannings,maltby,malchow,maiorano,mahn,mahlum,maglio,maberry,lustig,luellen,longwell,longenecker,lofland,locascio,linney,linneman,lighty,levell,levay,lenahan,lemen,lehto,lebaron,lanctot,lamy,lainez,laffoon,labombard,kujawski,kroger,kreutzer,korhonen,kondo,kollman,kohan,kogut,knaus,kivi,kittel,kinner,kindig,kindel,kiesel,kibby,khang,kettler,ketterer,kepner,kelliher,keenum,kanode,kail,juhasz,jowett,jolicoeur,jeon,iser,ingrassia,imai,hutchcraft,humiston,hulings,hukill,huizenga,hugley,hornyak,hodder,hisle,hillenbrand,hille,higuchi,hertzler,herdon,heppner,hepp,heitmann,heckart,hazlewood,hayles,hayek,hawkin,haugland,hasler,harbuck,happel,hambly,hambleton,hagaman,guzzi,gullette,guinyard,grogg,grise,griffing,goto,gosney,goley,goldblatt,gledhill,girton,giltner,gillock,gilham,gilfillan,giblin,gentner,gehlert,gehl,garten,garney,garlow,garett,galles,galeana,futral,fuhr,friedland,franson,fransen,foulds,follmer,foland,flax,flavin,firkins,fillion,figueredo,ferrill,fenster,fenley,fauver,farfan,eustice,eppler,engelman,engelke,emmer,elzy,ellwood,ellerbee,elks,ehret,ebbert,durrah,dupras,dubuque,dragoo,donlon,dolloff,dibella,derrico,demko,demar,darrington,czapla,crooker,creagh,cranor,craner,crabill,coyer,cowman,cowherd,cottone,costillo,coster,costas,cosenza,corker,collinson,coello,clingman,clingerman,claborn,chmura,chausse,chaudhry,chapell,chancy,cerrone,caverly,caulkins,carn,campfield,campanelli,callaham,cadorette,butkovich,buske,burrier,burkley,bunyard,buckelew,buchheit,broman,brescia,brasel,boyster,booe,bonomo,bondi,bohnsack,blomberg,blanford,bilderback,biggins,bently,behrends,beegle,bedoya,bechtol,beaubien,bayerl,baumgart,baumeister,barratt,barlowe,barkman,barbagallo,baldree,baine,baggs,bacote,aylward,ashurst,arvidson,arthurs,arrieta,arrey,arreguin,arrant,arner,arizmendi,anker,amis,amend,alphin,allbright,aikin,zupan,zuchowski,zeolla,zanchez,zahradnik,zahler,younan,yeater,yearta,yarrington,yantis,woomer,wollard,wolfinger,woerner,witek,wishon,wisener,wingerter,willet,wilding,wiedemann,weisel,wedeking,waybright,wardwell,walkins,waldorf,voth,voit,virden,viloria,villagran,vasta,vashon,vaquera,vantassell,vanderlinden,vandergrift,vancuren,valenta,underdahl,tygart,twining,twiford,turlington,tullius,tubman,trowell,trieu,transue,tousant,torgersen,tooker,tome,toma,tocci,tippins,tinner,timlin,tillinghast,tidmore,teti,tedrick,tacey,swanberg,sunde,summitt,summerford,summa,stratman,strandberg,storck,stober,steitz,stayer,stauber,staiger,sponaugle,spofford,sparano,spagnola,sokoloski,snay,slough,skowronski,sieck,shimkus,sheth,sherk,shankles,shahid,sevy,senegal,seiden,seidell,searls,searight,schwalm,schug,schilke,schier,scheck,sawtelle,santore,sanks,sandquist,sanden,saling,saathoff,ryberg,rustad,ruffing,rudnicki,ruane,rozzi,rowse,rosenau,rodes,risser,riggin,riess,riese,rhoten,reinecke,reigle,reichling,redner,rebelo,raynes,raimondi,rahe,rada,querry,quellette,pulsifer,prochnow,prato,poulton,poudrier,policastro,polhemus,polasek,poissant,pohlmann,plotner,pitkin,pita,pinkett,piekarski,pichon,pfau,petroff,petermann,peplinski,peller,pecinovsky,pearse,pattillo,patague,parlier,parenti,parchman,pane,paff,ortner,oros,nolley,noakes,nigh,nicolosi,nicolay,newnam,netter,nass,napoles,nakata,nakamoto,morlock,moraga,montilla,mongeau,molitor,mohney,mitchener,meyerhoff,medel,mcniff,mcmonagle,mcglown,mcglinchey,mcgarrity,mccright,mccorvey,mcconnel,mccargo,mazzei,matula,mastroianni,massingale,maring,maricle,mans,mannon,mannix,manney,manalo,malo,malan,mahony,madril,mackowiak,macko,macintosh,lurry,luczynski,lucke,lucarelli,losee,lorence,loiacono,lohse,loder,lipari,linebarger,lindamood,limbaugh,letts,leleux,leep,leeder,leard,laxson,lawry,laverdiere,laughton,lastra,kurek,kriss,krishnan,kretschmer,krebsbach,kontos,knobel,knauf,klick,kleven,klawitter,kitchin,kirkendoll,kinkel,kingrey,kilbourn,kensinger,kennerly,kamin,justiniano,jurek,junkin,judon,jordahl,jeanes,jarrells,iwamoto,ishida,immel,iman,ihle,hyre,hurn,hunn,hultman,huffstetler,huffer,hubner,howey,hooton,holts,holscher,holen,hoggatt,hilaire,herz,henne,helstrom,hellickson,heinlein,heckathorn,heckard,headlee,hauptman,haughey,hatt,harring,harford,hammill,hamed,halperin,haig,hagwood,hagstrom,gunnells,gundlach,guardiola,greeno,greenland,gonce,goldsby,gobel,gisi,gillins,gillie,germano,geibel,gauger,garriott,garbarino,gajewski,funari,fullbright,fuell,fritzler,freshwater,freas,fortino,forbus,flohr,flemister,fisch,finks,fenstermaker,feldstein,farhat,fankhauser,fagg,fader,exline,emigh,eguia,edman,eckler,eastburn,dunmore,dubuisson,dubinsky,drayer,doverspike,doubleday,doten,dorner,dolson,dohrmann,disla,direnzo,dipaola,dines,diblasi,dewolf,desanti,dennehy,demming,delker,decola,davilla,daughtridge,darville,darland,danzy,dagenais,culotta,cruzado,crudup,croswell,coverdale,covelli,couts,corbell,coplan,coolbaugh,conyer,conlee,conigliaro,comiskey,coberly,clendening,clairmont,cienfuegos,chojnacki,chilcote,champney,cassara,casazza,casado,carew,carbin,carabajal,calcagni,cail,busbee,burts,burbridge,bunge,bundick,buhler,bucholtz,bruen,broce,brite,brignac,brierly,bridgman,braham,bradish,boyington,borjas,bonn,bonhomme,bohlen,bogardus,bockelman,blick,blackerby,bizier,biro,binney,bertolini,bertin,berti,bento,beno,belgarde,belding,beckel,becerril,bazaldua,bayes,bayard,barrus,barris,baros,bara,ballow,bakewell,baginski,badalamenti,backhaus,avilez,auvil,atteberry,ardon,anzaldua,anello,amsler,ambrosio,althouse,alles,alberti,alberson,aitchison,aguinaga,ziemann,zickefoose,zerr,zeck,zartman,zahm,zabriskie,yohn,yellowhair,yeaton,yarnall,yaple,wolski,wixon,willner,willms,whitsitt,wheelwright,weyandt,wess,wengerd,weatherholtz,wattenbarger,walrath,walpole,waldrip,voges,vinzant,viars,veres,veneziano,veillon,vawter,vaughns,vanwart,vanostrand,valiente,valderas,uhrig,tunison,tulloch,trostle,treaster,traywick,toye,tomson,tomasello,tomasek,tippit,tinajero,tift,tienda,thorington,thieme,thibeau,thakkar,tewell,telfer,sweetser,stratford,stracener,stoke,stiverson,stelling,spatz,spagnoli,sorge,slevin,slabaugh,simson,shupp,shoultz,shotts,shiroma,shetley,sherrow,sheffey,shawgo,shamburger,sester,segraves,seelig,scioneaux,schwartzkopf,schwabe,scholes,schluter,schlecht,schillaci,schildgen,schieber,schewe,schecter,scarpelli,scaglione,sautter,santelli,salmi,sabado,ryer,rydberg,ryba,rushford,runk,ruddick,rotondo,rote,rosenfield,roesner,rocchio,ritzer,rippel,rimes,riffel,richison,ribble,reynold,resh,rehn,ratti,rasor,rasnake,rappold,rando,radosevich,pulice,prichett,pribble,poynor,plowden,pitzen,pittsley,pitter,philyaw,philipps,pestana,perro,perone,pera,peil,pedone,pawlowicz,pattee,parten,parlin,pariseau,paredez,paek,pacifico,otts,ostrow,osornio,oslund,orso,ooten,onken,oniel,onan,ollison,ohlsen,ohlinger,odowd,niemiec,neubert,nembhard,neaves,neathery,nakasone,myerson,muto,muntz,munez,mumme,mumm,mujica,muise,muench,morriss,molock,mishoe,minier,metzgar,mero,meiser,meese,mcsween,mcquire,mcquinn,mcpheeters,mckeller,mcilrath,mcgown,mcdavis,mccuen,mcclenton,maxham,matsui,marriner,marlette,mansur,mancino,maland,majka,maisch,maheux,madry,madriz,mackley,macke,lydick,lutterman,luppino,lundahl,lovingood,loudon,longmore,liefer,leveque,lescarbeau,lemmer,ledgerwood,lawver,lawrie,lattea,lasko,lahman,kulpa,kukowski,kukla,kubota,kubala,krizan,kriz,krikorian,kravetz,kramp,kowaleski,knobloch,klosterman,kloster,klepper,kirven,kinnaman,kinnaird,killam,kiesling,kesner,keebler,keagle,karls,kapinos,kantner,kaba,junious,jefferys,jacquet,izzi,ishii,irion,ifill,hotard,horman,hoppes,hopkin,hokanson,hoda,hocutt,hoaglin,hites,hirai,hindle,hinch,hilty,hild,hier,hickle,hibler,henrichs,hempstead,helmers,hellard,heims,heidler,hawbaker,harkleroad,harari,hanney,hannaford,hamid,haltom,hallford,guilliams,guerette,gryder,groseclose,groen,grimley,greenidge,graffam,goucher,goodenough,goldsborough,gloster,glanton,gladson,gladding,ghee,gethers,gerstein,geesey,geddie,gayer,gaver,gauntt,gartland,garriga,garoutte,fronk,fritze,frenzel,forgione,fluitt,flinchbaugh,flach,fiorito,finan,finamore,fimbres,fillman,figeroa,ficklin,feher,feddersen,fambro,fairbairn,eves,escalona,elsey,eisenstein,ehrenberg,eargle,drane,dogan,dively,dewolfe,dettman,desiderio,desch,dennen,denk,demaris,delsignore,dejarnette,deere,dedman,daws,dauphinais,danz,dantin,dannenberg,dalby,currence,culwell,cuesta,croston,crossno,cromley,crisci,craw,coryell,condra,colpitts,colas,clink,clevinger,clermont,cistrunk,cirilo,chirico,chiarello,cephus,cecena,cavaliere,caughey,casimir,carwell,carlon,carbonaro,caraveo,cantley,callejas,cagney,cadieux,cabaniss,bushard,burlew,buras,budzinski,bucklew,bruneau,brummer,brueggemann,brotzman,bross,brittian,brimage,briles,brickman,breneman,breitenstein,brandel,brackins,boydstun,botta,bosket,boros,borgmann,bordeau,bonifacio,bolten,boehman,blundell,bloodsaw,bjerke,biffle,bickett,bickers,beville,bergren,bergey,benzing,belfiore,beirne,beckert,bebout,baumert,battey,barrs,barriere,barcelo,barbe,balliet,baham,babst,auton,asper,asbell,arzate,argento,arel,araki,arai,antley,amodeo,ammann,allensworth,aldape,akey,abeita,zweifel,zeiler,zamor,zalenski,yzaguirre,yousef,yetman,wyer,woolwine,wohlgemuth,wohlers,wittenberg,wingrove,wimsatt,willimas,wilkenson,wildey,wilderman,wilczynski,wigton,whorley,wellons,welle,weirich,weideman,weide,weast,wasmund,warshaw,walson,waldner,walch,walberg,wagener,wageman,vrieze,vossen,vorce,voorhis,vonderheide,viruet,vicari,verne,velasques,vautour,vartanian,varona,vankeuren,vandine,vandermeer,ursery,underdown,uhrich,uhlman,tworek,twine,twellman,tweedie,tutino,turmelle,tubb,trivedi,triano,trevathan,treese,treanor,treacy,traina,topham,toenjes,tippetts,tieu,thomure,thatch,tetzlaff,tetterton,teamer,tappan,talcott,tagg,szczepanski,syring,surace,sulzer,sugrue,sugarman,suess,styons,stwart,stupka,strey,straube,strate,stoddart,stockbridge,stjames,steimle,steenberg,stamand,staller,stahly,stager,spurgin,sprow,sponsler,speas,spainhour,sones,smits,smelcer,slovak,slaten,singleterry,simien,sidebottom,sibrian,shellhammer,shelburne,shambo,sepeda,seigel,scogin,scianna,schmoll,schmelzer,scheu,schachter,savant,sauseda,satcher,sandor,sampsell,rugh,rufener,rotenberry,rossow,rossbach,rollman,rodrique,rodreguez,rodkey,roda,rini,riggan,rients,riedl,rhines,ress,reinbold,raschke,rardin,racicot,quillin,pushard,primrose,pries,pressey,precourt,pratts,postel,poppell,plumer,pingree,pieroni,pflug,petre,petrarca,peterka,perkin,pergande,peranio,penna,paulhus,pasquariello,parras,parmentier,pamplin,oviatt,osterhoudt,ostendorf,osmun,ortman,orloff,orban,onofrio,olveda,oltman,okeeffe,ocana,nunemaker,novy,noffsinger,nish,niday,nethery,nemitz,neidert,nadal,nack,muszynski,munsterman,mulherin,mortimore,morter,montesino,montalvan,montalbano,momon,moman,mogan,minns,millward,milling,michelsen,mewborn,metayer,mensch,meloy,meggs,meaders,mcsorley,mcmenamin,mclead,mclauchlin,mcguffey,mcguckin,mcglaughlin,mcferron,mcentyre,mccrum,mccawley,mcbain,mayhue,matzen,matton,marsee,marrin,marland,markum,mantilla,manfre,makuch,madlock,macauley,luzier,luthy,lufkin,lucena,loudin,lothrop,lorch,loll,loadholt,lippold,lichtman,liberto,liakos,lewicki,levett,lentine,leja,legree,lawhead,lauro,lauder,lanman,lank,laning,lalor,krob,kriger,kriegel,krejci,kreisel,kozel,konkel,kolstad,koenen,kocsis,knoblock,knebel,klopfer,klee,kilday,kesten,kerbs,kempker,keathley,kazee,kaur,kamer,kamaka,kallenbach,jehle,jaycox,jardin,jahns,ivester,hyppolite,hyche,huppert,hulin,hubley,horsey,hornak,holzwarth,holmon,hollabaugh,holaway,hodes,hoak,hinesley,hillwig,hillebrand,highfield,heslop,herrada,hendryx,hellums,heit,heishman,heindel,hayslip,hayford,hastie,hartgrove,hanus,hakim,hains,hadnott,gundersen,gulino,guidroz,guebert,gressett,graydon,gramling,grahn,goupil,gorelick,goodreau,goodnough,golay,goers,glatz,gillikin,gieseke,giammarino,getman,gensler,gazda,garibaldi,gahan,funderburke,fukuda,fugitt,fuerst,fortman,forsgren,formica,flink,fitton,feltz,fekete,feit,fehrenbach,farone,farinas,faries,fagen,ewin,esquilin,esch,enderle,ellery,ellers,ekberg,egli,effinger,dymond,dulle,dula,duhe,dudney,dowless,dower,dorminey,dopp,dooling,domer,disher,dillenbeck,difilippo,dibernardo,deyoe,devillier,denley,deland,defibaugh,deeb,debow,dauer,datta,darcangelo,daoust,damelio,dahm,dahlman,curlin,cupit,culton,cuenca,cropp,croke,cremer,crace,cosio,corzine,coombe,coman,colone,coloma,collingwood,coderre,cocke,cobler,claybrook,cincotta,cimmino,christoff,chisum,chillemi,chevere,chachere,cervone,cermak,cefalu,cauble,cather,caso,carns,carcamo,carbo,capoccia,capello,capell,canino,cambareri,calvi,cabiness,bushell,burtt,burstein,burkle,bunner,bundren,buechler,bryand,bruso,brownstein,brouse,brodt,brisbin,brightman,brenes,breitenbach,brazzell,brazee,bramwell,bramhall,bradstreet,boyton,bowland,boulter,bossert,bonura,bonebrake,bonacci,boeck,blystone,birchard,bilal,biddy,bibee,bevans,bethke,bertelsen,berney,bergfeld,benware,bellon,bellah,batterton,barberio,bamber,bagdon,badeaux,averitt,augsburger,ates,arvie,aronowitz,arens,araya,angelos,andrada,amell,amante,almy,almquist,alls,aispuro,aguillon,agudelo,aceto,abalos,zdenek,zaremba,zaccaria,youssef,wrona,wrede,wotton,woolston,wolpert,wollman,wince,wimberley,willmore,willetts,wikoff,wieder,wickert,whitenack,wernick,welte,welden,weisenberger,weich,wallington,walder,vossler,vore,vigo,vierling,victorine,verdun,vencill,vazguez,vassel,vanzile,vanvliet,vantrease,vannostrand,vanderveer,vanderveen,vancil,uyeda,umphrey,uhler,uber,tutson,turrentine,tullier,tugwell,trundy,tripodi,tomer,tomasi,tomaselli,tokarski,tisher,tibbets,thweatt,tharrington,tesar,telesco,teasdale,tatem,taniguchi,suriel,sudler,stutsman,sturman,strite,strelow,streight,strawder,stransky,strahl,stours,stong,stinebaugh,stillson,steyer,stelle,steffensmeier,statham,squillante,spiess,spargo,southward,soller,soden,snuggs,snellgrove,smyers,smiddy,slonaker,skyles,skowron,sivils,siqueiros,siers,siddall,shontz,shingler,shiley,shibley,sherard,shelnutt,shedrick,shasteen,sereno,selke,scovil,scola,schuett,schuessler,schreckengost,schranz,schoepp,schneiderman,schlanger,schiele,scheuermann,schertz,scheidler,scheff,schaner,schamber,scardina,savedra,saulnier,sater,sarro,sambrano,salomone,sabourin,ruud,rutten,ruffino,ruddock,rowser,roussell,rosengarten,rominger,rollinson,rohman,roeser,rodenberg,roberds,ridgell,rhodus,reynaga,rexrode,revelle,rempel,remigio,reising,reiling,reetz,rayos,ravenscroft,ravenell,raulerson,rasmusson,rask,rase,ragon,quesnel,quashie,puzo,puterbaugh,ptak,prost,prisbrey,principe,pricer,pratte,pouncey,portman,pontious,pomerantz,planck,pilkenton,pilarski,phegley,pertuit,penta,pelc,peffer,pech,peagler,pavelka,pavao,patman,paskett,parrilla,pardini,papazian,panter,palin,paley,paetzold,packett,pacheo,ostrem,orsborn,olmedo,okamura,oiler,oglesbee,oatis,nuckles,notter,nordyke,nogueira,niswander,nibert,nesby,neloms,nading,naab,munns,mullarkey,moudy,moret,monnin,molder,modisette,moczygemba,moctezuma,mischke,miro,mings,milot,milledge,milhorn,milera,mieles,mickley,micek,metellus,mersch,merola,mercure,mencer,mellin,mell,meinke,mcquillan,mcmurtrie,mckillop,mckiernan,mckendrick,mckamie,mcilvaine,mcguffie,mcgonigle,mcgarrah,mcfetridge,mcenaney,mcdow,mccutchan,mccallie,mcadam,maycock,maybee,mattei,massi,masser,masiello,marshell,marmo,marksberry,markell,marchal,manross,manganaro,mally,mallow,mailhot,magyar,madero,madding,maddalena,macfarland,lynes,lugar,luckie,lucca,lovitt,loveridge,loux,loth,loso,lorenzana,lorance,lockley,lockamy,littler,litman,litke,liebel,lichtenberger,licea,leverich,letarte,lesesne,leno,legleiter,leffew,laurin,launius,laswell,lassen,lasala,laraway,laramore,landrith,lancon,lanahan,laiche,laford,lachermeier,kunst,kugel,kuck,kuchta,kube,korus,koppes,kolbe,koerber,kochan,knittel,kluck,kleve,kleine,kitch,kirton,kirker,kintz,kinghorn,kindell,kimrey,kilduff,kilcrease,kicklighter,kibble,kervin,keplinger,keogh,kellog,keeth,kealey,kazmierczak,karner,kamel,kalina,kaczynski,juel,jerman,jeppson,jawad,jasik,jaqua,janusz,janco,inskeep,inks,ingold,hyndman,hymer,hunte,hunkins,humber,huffstutler,huffines,hudon,hudec,hovland,houze,hout,hougland,hopf,holsapple,holness,hollenbach,hoffmeister,hitchings,hirata,hieber,hickel,hewey,herriman,hermansen,herandez,henze,heffelfinger,hedgecock,hazlitt,hazelrigg,haycock,harren,harnage,harling,harcrow,hannold,hanline,hanel,hanberry,hammersley,hamernik,hajduk,haithcock,haff,hadaway,haan,gullatt,guilbault,guidotti,gruner,grisson,grieves,granato,grabert,gover,gorka,glueck,girardin,giesler,gersten,gering,geers,gaut,gaulin,gaskamp,garbett,gallivan,galland,gaeth,fullenkamp,fullam,friedrichs,freire,freeney,fredenburg,frappier,fowkes,foree,fleurant,fleig,fleagle,fitzsimons,fischetti,fiorenza,finneran,filippi,figueras,fesler,fertig,fennel,feltmann,felps,felmlee,fannon,familia,fairall,fadden,esslinger,enfinger,elsasser,elmendorf,ellisor,einhorn,ehrman,egner,edmisten,edlund,ebinger,dyment,dykeman,durling,dunstan,dunsmore,dugal,duer,drescher,doyel,dossey,donelan,dockstader,dobyns,divis,dilks,didier,desrosier,desanto,deppe,delosh,delange,defrank,debo,dauber,dartez,daquila,dankert,dahn,cygan,cusic,curfman,croghan,croff,criger,creviston,crays,cravey,crandle,crail,crago,craghead,cousineau,couchman,cothron,corella,conine,coller,colberg,cogley,coatney,coale,clendenin,claywell,clagon,cifaldi,choiniere,chickering,chica,chennault,chavarin,chattin,chaloux,challis,cesario,cazarez,caughman,catledge,casebolt,carrel,carra,carlow,capote,canez,camillo,caliendo,calbert,bylsma,buskey,buschman,burkhard,burghardt,burgard,buonocore,bunkley,bungard,bundrick,bumbrey,buice,buffkin,brundige,brockwell,brion,briant,bredeson,bransford,brannock,brakefield,brackens,brabant,bowdoin,bouyer,bothe,boor,bonavita,bollig,blurton,blunk,blanke,blanck,birden,bierbaum,bevington,beutler,betters,bettcher,bera,benway,bengston,benesh,behar,bedsole,becenti,beachy,battersby,basta,bartmess,bartle,bartkowiak,barsky,barrio,barletta,barfoot,banegas,baldonado,azcona,avants,austell,aungst,aune,aumann,audia,atterbury,asselin,asmussen,ashline,asbill,arvizo,arnot,ariola,ardrey,angstadt,anastasio,amsden,amerman,alred,allington,alewine,alcina,alberico,ahlgren,aguas,agrawal,agosta,adolphsen,acey,aburto,abler,zwiebel,zepp,zentz,ybarbo,yarberry,yamauchi,yamashiro,wurtz,wronski,worster,wootten,wongus,woltz,wolanski,witzke,withey,wisecarver,wingham,wineinger,winegarden,windholz,wilgus,wiesen,wieck,widrick,wickliffe,whittenberg,westby,werley,wengert,wendorf,weimar,weick,weckerly,watrous,wasden,walford,wainright,wahlstrom,wadlow,vrba,voisin,vives,vivas,vitello,villescas,villavicencio,villanova,vialpando,vetrano,vensel,vassell,varano,vanriper,vankleeck,vanduyne,vanderpol,vanantwerp,valenzula,udell,turnquist,tuff,trickett,tramble,tingey,timbers,tietz,thiem,tercero,tenner,tenaglia,teaster,tarlton,taitt,tabon,sward,swaby,suydam,surita,suman,suddeth,stumbo,studivant,strobl,streich,stoodley,stoecker,stillwagon,stickle,stellmacher,stefanik,steedley,starbird,stainback,stacker,speir,spath,sommerfeld,soltani,solie,sojka,sobota,sobieski,sobczak,smullen,sleeth,slaymaker,skolnick,skoglund,sires,singler,silliman,shrock,shott,shirah,shimek,shepperd,sheffler,sheeler,sharrock,sharman,shalash,seyfried,seybold,selander,seip,seifried,sedor,sedlock,sebesta,seago,scutt,scrivens,sciacca,schultze,schoemaker,schleifer,schlagel,schlachter,schempp,scheider,scarboro,santi,sandhu,salim,saia,rylander,ryburn,rutigliano,ruocco,ruland,rudloff,rott,rosenburg,rosenbeck,romberger,romanelli,rohloff,rohlfing,rodda,rodd,ritacco,rielly,rieck,rickles,rickenbacker,respass,reisner,reineck,reighard,rehbein,rega,reddix,rawles,raver,rattler,ratledge,rathman,ramsburg,raisor,radovich,radigan,quail,puskar,purtee,priestly,prestidge,presti,pressly,pozo,pottinger,portier,porta,porcelli,poplawski,polin,poeppelman,pocock,plump,plantz,placek,piro,pinnell,pinkowski,pietz,picone,philbeck,pflum,peveto,perret,pentz,payer,patlan,paterno,papageorge,overmyer,overland,osier,orwig,orum,orosz,oquin,opie,ochsner,oathout,nygard,norville,northway,niver,nicolson,newhart,neitzel,nath,nanez,murnane,mortellaro,morreale,morino,moriarity,morgado,moorehouse,mongiello,molton,mirza,minnix,millspaugh,milby,miland,miguez,mickles,michaux,mento,melugin,melito,meinecke,mehr,meares,mcneece,mckane,mcglasson,mcgirt,mcgilvery,mcculler,mccowen,mccook,mcclintic,mccallon,mazzotta,maza,mayse,mayeda,matousek,matley,martyn,marney,marnell,marling,manuelito,maltos,malson,mahi,maffucci,macken,maass,lyttle,lynd,lyden,lukasiewicz,luebbers,lovering,loveall,longtin,lobue,loberg,lipka,lightbody,lichty,levert,lettieri,letsinger,lepak,lemmond,lembke,leitz,lasso,lasiter,lango,landsman,lamirande,lamey,laber,kuta,kulesza,krenz,kreiner,krein,kreiger,kraushaar,kottke,koser,kornreich,kopczynski,konecny,koff,koehl,kocian,knaub,kmetz,kluender,klenke,kleeman,kitzmiller,kirsh,kilman,kildow,kielbasa,ketelsen,kesinger,kehr,keef,kauzlarich,karter,kahre,jobin,jinkins,jines,jeffress,jaquith,jaillet,jablonowski,ishikawa,irey,ingerson,indelicato,huntzinger,huisman,huett,howson,houge,hosack,hora,hoobler,holtzen,holtsclaw,hollingworth,hollin,hoberg,hobaugh,hilker,hilgefort,higgenbotham,heyen,hetzler,hessel,hennessee,hendrie,hellmann,heft,heesch,haymond,haymon,haye,havlik,havis,haverland,haus,harstad,harriston,harju,hardegree,hammell,hamaker,halbrook,halberg,guptill,guntrum,gunderman,gunder,gularte,guarnieri,groll,grippo,greely,gramlich,goewey,goetzinger,goding,giraud,giefer,giberson,gennaro,gemmell,gearing,gayles,gaudin,gatz,gatts,gasca,garn,gandee,gammel,galindez,galati,gagliardo,fulop,fukushima,friedt,fretz,frenz,freeberg,fravel,fountaine,forry,forck,fonner,flippin,flewelling,flansburg,filippone,fettig,fenlon,felter,felkins,fein,favero,faulcon,farver,farless,fahnestock,facemire,faas,eyer,evett,esses,escareno,ensey,ennals,engelking,empey,ellithorpe,effler,edling,edgley,durrell,dunkerson,draheim,domina,dombrosky,doescher,dobbin,divens,dinatale,dieguez,diede,devivo,devilbiss,devaul,determan,desjardin,deshaies,delpozo,delorey,delman,delapp,delamater,deibert,degroff,debelak,dapolito,dano,dacruz,dacanay,cushenberry,cruze,crosbie,cregan,cousino,corrao,corney,cookingham,conry,collingsworth,coldren,cobian,coate,clauss,christenberry,chmiel,chauez,charters,chait,cesare,cella,caya,castenada,cashen,cantrelle,canova,campione,calixte,caicedo,byerley,buttery,burda,burchill,bulmer,bulman,buesing,buczek,buckholz,buchner,buchler,buban,bryne,brunkhorst,brumsey,brumer,brownson,brodnax,brezinski,brazile,braverman,branning,boye,boulden,bough,bossard,bosak,borth,borgmeyer,borge,blowers,blaschke,blann,blankenbaker,bisceglia,billingslea,bialek,beverlin,besecker,berquist,benigno,benavente,belizaire,beisner,behrman,beausoleil,baylon,bayley,bassi,basnett,basilio,basden,basco,banerjee,balli,bagnell,bady,averette,arzu,archambeault,arboleda,arbaugh,arata,antrim,amrhein,amerine,alpers,alfrey,alcon,albus,albertini,aguiniga,aday,acquaviva,accardi,zygmont,zych,zollner,zobel,zinck,zertuche,zaragosa,zale,zaldivar,yeadon,wykoff,woullard,wolfrum,wohlford,wison,wiseley,wisecup,winchenbach,wiltsie,whittlesey,whitelow,whiteford,wever,westrich,wertman,wensel,wenrich,weisbrod,weglarz,wedderburn,weatherhead,wease,warring,wadleigh,voltz,vise,villano,vicario,vermeulen,vazques,vasko,varughese,vangieson,vanfossen,vanepps,vanderploeg,vancleve,valerius,uyehara,unsworth,twersky,turrell,tuner,tsui,trunzo,trousdale,trentham,traughber,torgrimson,toppin,tokar,tobia,tippens,tigue,thiry,thackston,terhaar,tenny,tassin,tadeo,sweigart,sutherlin,sumrell,suen,stuhr,strzelecki,strosnider,streiff,stottlemyer,storment,storlie,stonesifer,stogsdill,stenzel,stemen,stellhorn,steidl,stecklein,statton,stangle,spratling,spoor,spight,spelman,spece,spanos,spadoni,southers,sola,sobol,smyre,slaybaugh,sizelove,sirmons,simington,silversmith,siguenza,sieren,shelman,sharples,sharif,sessler,serrata,serino,serafini,semien,selvey,seedorf,seckman,seawood,scoby,scicchitano,schorn,schommer,schnitzer,schleusner,schlabach,schiel,schepers,schaber,scally,sautner,sartwell,santerre,sandage,salvia,salvetti,salsman,sallis,salais,saeger,sabat,saar,ruther,russom,ruoff,rumery,rubottom,rozelle,rowton,routon,rotolo,rostad,roseborough,rorick,ronco,roher,roberie,robare,ritts,rison,rippe,rinke,ringwood,righter,rieser,rideaux,rickerson,renfrew,releford,reinsch,reiman,reifsteck,reidhead,redfearn,reddout,reaux,rado,radebaugh,quinby,quigg,provo,provenza,provence,pridgeon,praylow,powel,poulter,portner,pontbriand,poirrier,poirer,platero,pixler,pintor,pigman,piersall,piel,pichette,phou,pharis,phalen,petsche,perrier,penfield,pelosi,pebley,peat,pawloski,pawlik,pavlick,pavel,patz,patout,pascucci,pasch,parrinello,parekh,pantaleo,pannone,pankow,pangborn,pagani,pacelli,orsi,oriley,orduno,oommen,olivero,okada,ocon,ocheltree,oberman,nyland,noss,norling,nolton,nobile,nitti,nishimoto,nghiem,neuner,neuberger,neifert,negus,nagler,mullally,moulden,morra,morquecho,moots,mizzell,mirsky,mirabito,minardi,milholland,mikus,mijangos,michener,michalek,methvin,merrit,menter,meneely,meiers,mehring,mees,mcwhirt,mcwain,mcphatter,mcnichol,mcnaught,mclarty,mcivor,mcginness,mcgaughy,mcferrin,mcfate,mcclenny,mcclard,mccaskey,mccallion,mcamis,mathisen,marton,marsico,marchi,mani,mangione,macaraeg,lupi,lunday,lukowski,lucious,locicero,loach,littlewood,litt,lipham,linley,lindon,lightford,lieser,leyendecker,lewey,lesane,lenzi,lenart,leisinger,lehrman,lefebure,lazard,laycock,laver,launer,lastrapes,lastinger,lasker,larkey,lanser,lanphere,landey,lampton,lamark,kumm,kullman,krzeminski,krasner,koran,koning,kohls,kohen,kobel,kniffen,knick,kneip,knappenberger,klumpp,klausner,kitamura,kisling,kirshner,kinloch,kingman,kimery,kestler,kellen,keleher,keehn,kearley,kasprzak,kampf,kamerer,kalis,kahan,kaestner,kadel,kabel,junge,juckett,joynt,jorstad,jetter,jelley,jefferis,jeansonne,janecek,jaffee,izzard,istre,isherwood,ipock,iannuzzi,hypolite,humfeld,hotz,hosein,honahni,holzworth,holdridge,holdaway,holaday,hodak,hitchman,hippler,hinchey,hillin,hiler,hibdon,hevey,heth,hepfer,henneman,hemsley,hemmings,hemminger,helbert,helberg,heinze,heeren,heber,haver,hauff,haswell,harvison,hartson,harshberger,harryman,harries,hane,hamsher,haggett,hagemeier,haecker,haddon,haberkorn,guttman,guttierrez,guthmiller,guillet,guilbert,gugino,grumbles,griffy,gregerson,grana,goya,goranson,gonsoulin,goettl,goertz,godlewski,glandon,gilsdorf,gillogly,gilkison,giard,giampaolo,gheen,gettings,gesell,gershon,gaumer,gartrell,garside,garrigan,garmany,garlitz,garlington,gamet,furlough,funston,funaro,frix,frasca,francoeur,forshey,foose,flatley,flagler,fils,fillers,fickett,feth,fennelly,fencl,felch,fedrick,febres,fazekas,farnan,fairless,ewan,etsitty,enterline,elsworth,elliff,eleby,eldreth,eidem,edgecomb,edds,ebarb,dworkin,dusenberry,durrance,duropan,durfey,dungy,dundon,dumbleton,dubon,dubberly,droz,drinkwater,dressel,doughtie,doshier,dorrell,dople,doonan,donadio,dollison,doig,ditzler,dishner,discher,dimaio,digman,difalco,devino,devens,derosia,deppen,depaola,deniz,denardo,demos,demay,delgiudice,davi,danielsen,dally,dais,dahmer,cutsforth,cusimano,curington,cumbee,cryan,crusoe,crowden,crete,cressman,crapo,cowens,coupe,councill,coty,cotnoir,correira,copen,consiglio,combes,coffer,cockrill,coad,clogston,clasen,chesnutt,charrier,chadburn,cerniglia,cebula,castruita,castilla,castaldi,casebeer,casagrande,carta,carrales,carnley,cardon,capshaw,capron,cappiello,capito,canney,candela,caminiti,califano,calabria,caiazzo,cahall,buscemi,burtner,burgdorf,burdo,buffaloe,buchwald,brwon,brunke,brummond,brumm,broe,brocious,brocato,briski,brisker,brightwell,bresett,breiner,brazeau,braz,brayman,brandis,bramer,bradeen,boyko,bossi,boshart,bortle,boniello,bomgardner,bolz,bolenbaugh,bohling,bohland,bochenek,blust,bloxham,blowe,blish,blackwater,bjelland,biros,biederman,bickle,bialaszewski,bevil,beumer,bettinger,besse,bernett,bermejo,bement,belfield,beckler,baxendale,batdorf,bastin,bashore,bascombe,bartlebaugh,barsh,ballantine,bahl,badon,autin,astin,askey,ascher,arrigo,arbeiter,antes,angers,amburn,amarante,alvidrez,althaus,allmond,alfieri,aldinger,akerley,akana,aikins,ader,acebedo,accardo,abila,aberle,abele,abboud,zollars,zimmerer,zieman,zerby,zelman,zellars,yoshimura,yonts,yeats,yant,yamanaka,wyland,wuensche,worman,wordlaw,wohl,winslett,winberg,wilmeth,willcutt,wiers,wiemer,wickwire,wichman,whitting,whidbee,westergard,wemmer,wellner,weishaupt,weinert,weedon,waynick,wasielewski,waren,walworth,wallingford,walke,waechter,viviani,vitti,villagrana,vien,vicks,venema,varnes,varnadoe,varden,vanpatten,vanorden,vanderzee,vandenburg,vandehey,valls,vallarta,valderrama,valade,urman,ulery,tusa,tuft,tripoli,trimpe,trickey,tortora,torrens,torchia,toft,tjaden,tison,tindel,thurmon,thode,tardugno,tancredi,taketa,taillon,tagle,sytsma,symes,swindall,swicegood,swartout,sundstrom,sumners,sulton,studstill,stroop,stonerock,stmarie,stlawrence,stemm,steinhauser,steinert,steffensen,stefaniak,starck,stalzer,spidle,spake,sowinski,sosnowski,sorber,somma,soliday,soldner,soja,soderstrom,soder,sockwell,sobus,sloop,sinkfield,simerly,silguero,sigg,siemers,siegmund,shum,sholtis,shkreli,sheikh,shattles,sharlow,shambaugh,shaikh,serrao,serafino,selley,selle,seel,sedberry,secord,schunk,schuch,schor,scholze,schnee,schmieder,schleich,schimpf,scherf,satterthwaite,sasson,sarkisian,sarinana,sanzone,salvas,salone,salido,saiki,sahr,rusher,rusek,ruppel,rubel,rothfuss,rothenberger,rossell,rosenquist,rosebrook,romito,romines,rolan,roker,roehrig,rockhold,rocca,robuck,riss,rinaldo,riggenbach,rezentes,reuther,renolds,rench,remus,remsen,reller,relf,reitzel,reiher,rehder,redeker,ramero,rahaim,radice,quijas,qualey,purgason,prum,proudfoot,prock,probert,printup,primer,primavera,prenatt,pratico,polich,podkowka,podesta,plattner,plasse,plamondon,pittmon,pippenger,pineo,pierpont,petzold,petz,pettiway,petters,petroski,petrik,pesola,pershall,perlmutter,penepent,peevy,pechacek,peaden,pazos,pavia,pascarelli,parm,parillo,parfait,paoletti,palomba,palencia,pagaduan,oxner,overfield,overcast,oullette,ostroff,osei,omarah,olenick,olah,odem,nygren,notaro,northcott,nodine,nilges,neyman,neve,neuendorf,neisler,neault,narciso,naff,muscarella,morrisette,morphew,morein,montville,montufar,montesinos,monterroso,mongold,mojarro,moitoso,mirarchi,mirando,minogue,milici,miga,midyett,michna,meuser,messana,menzie,menz,mendicino,melone,mellish,meller,melle,meints,mechem,mealer,mcwilliam,mcwhite,mcquiggan,mcphillips,mcpartland,mcnellis,mcmackin,mclaughin,mckinny,mckeithan,mcguirk,mcgillivray,mcgarr,mcgahee,mcfaul,mcfadin,mceuen,mccullah,mcconico,mcclaren,mccaul,mccalley,mccalister,mazer,mayson,mayhan,maugeri,mauger,mattix,mattews,maslowski,masek,martir,marsch,marquess,maron,markwell,markow,marinaro,marcinek,mannella,mallen,majeed,mahnke,mahabir,magby,magallan,madere,machnik,lybrand,luque,lundholm,lueders,lucian,lubinski,lowy,loew,lippard,linson,lindblad,lightcap,levitsky,levens,leonardi,lenton,lengyel,leitzel,leicht,leaver,laubscher,lashua,larusso,larrimore,lanterman,lanni,lanasa,lamoureaux,lambros,lamborn,lamberti,lall,lafuente,laferriere,laconte,kyger,kupiec,kunzman,kuehne,kuder,kubat,krogh,kreidler,krawiec,krauth,kratky,kottwitz,korb,kono,kolman,kolesar,koeppel,knapper,klingenberg,kjos,keppel,kennan,keltz,kealoha,kasel,karney,kanne,kamrowski,kagawa,johnosn,jilek,jarvie,jarret,jansky,jacquemin,jacox,jacome,iriarte,ingwersen,imboden,iglesia,huyser,hurston,hursh,huntoon,hudman,hoying,horsman,horrigan,hornbaker,horiuchi,hopewell,hommel,homeyer,holzinger,holmer,hipsher,hinchman,hilts,higginbottom,hieb,heyne,hessling,hesler,hertlein,herford,heras,henricksen,hennemann,henery,hendershott,hemstreet,heiney,heckert,heatley,hazell,hazan,hayashida,hausler,hartsoe,harth,harriott,harriger,harpin,hardisty,hardge,hannaman,hannahs,hamp,hammersmith,hamiton,halsell,halderman,hagge,habel,gusler,gushiken,gurr,gummer,gullick,grunden,grosch,greenburg,greb,greaver,gratz,grajales,gourlay,gotto,gorley,goodpasture,godard,glorioso,gloor,glascock,gizzi,giroir,gibeault,gauldin,gauer,gartin,garrels,gamber,gallogly,gade,fusaro,fripp,freyer,freiberg,franzoni,fragale,foston,forti,forness,folts,followell,foard,flom,flett,fleitas,flamm,fino,finnen,finchum,filippelli,fickel,feucht,feiler,feenstra,feagins,faver,faulkenberry,farabaugh,fandel,faler,faivre,fairey,facey,exner,evensen,erion,erben,epting,epping,ephraim,engberg,elsen,ellingwood,eisenmann,eichman,ehle,edsall,durall,dupler,dunker,dumlao,duford,duffie,dudding,dries,doung,dorantes,donahoo,domenick,dollins,dobles,dipiazza,dimeo,diehm,dicicco,devenport,desormeaux,derrow,depaolo,demas,delpriore,delosantos,degreenia,degenhardt,defrancesco,defenbaugh,deets,debonis,deary,dazey,dargie,dambrosia,dalal,dagen,cuen,crupi,crossan,crichlow,creque,coutts,counce,coram,constante,connon,collelo,coit,cocklin,coblentz,cobey,coard,clutts,clingan,clampitt,claeys,ciulla,cimini,ciampa,christon,choat,chiou,chenail,chavous,catto,catalfamo,casterline,cassinelli,caspers,carroway,carlen,carithers,cappel,calo,callow,cagley,cafferty,byun,byam,buttner,buth,burtenshaw,burget,burfield,buresh,bunt,bultman,bulow,buchta,buchmann,brunett,bruemmer,brueggeman,britto,briney,brimhall,bribiesca,bresler,brazan,brashier,brar,brandstetter,boze,boonstra,bluitt,blomgren,blattner,blasi,bladen,bitterman,bilby,bierce,biello,bettes,bertone,berrey,bernat,berberich,benshoof,bendickson,bellefeuille,bednarski,beddingfield,beckerman,beaston,bavaro,batalla,basye,baskins,bartolotta,bartkowski,barranco,barkett,banaszak,bame,bamberger,balsley,ballas,balicki,badura,aymond,aylor,aylesworth,axley,axelrod,aubert,armond,ariza,apicella,anstine,ankrom,angevine,andreotti,alto,alspaugh,alpaugh,almada,allinder,alequin,aguillard,agron,agena,afanador,ackerley,abrev,abdalla,aaronson,zynda,zucco,zipp,zetina,zenz,zelinski,youngren,yochum,yearsley,yankey,woodfork,wohlwend,woelfel,wiste,wismer,winzer,winker,wilkison,wigger,wierenga,whipps,westray,wesch,weld,weible,wedell,weddell,wawrzyniak,wasko,washinton,wantz,walts,wallander,wain,wahlen,wachowiak,voshell,viteri,vire,villafuerte,vieyra,viau,vescio,verrier,verhey,vause,vandermolen,vanderhorst,valois,valla,valcourt,vacek,uzzle,umland,ulman,ulland,turvey,tuley,trembath,trabert,towsend,totman,toews,tisch,tisby,tierce,thivierge,tenenbaum,teagle,tacy,tabler,szewczyk,swearngin,suire,sturrock,stubbe,stronach,stoute,stoudemire,stoneberg,sterba,stejskal,steier,stehr,steckel,stearman,steakley,stanforth,stancill,srour,sprowl,spevak,sokoloff,soderman,snover,sleeman,slaubaugh,sitzman,simes,siegal,sidoti,sidler,sider,sidener,siddiqi,shireman,shima,sheroan,shadduck,seyal,sentell,sennett,senko,seligman,seipel,seekins,seabaugh,scouten,schweinsberg,schwartzberg,schurr,schult,schrick,schoening,schmitmeyer,schlicher,schlager,schack,schaar,scavuzzo,scarpa,sassano,santigo,sandavol,sampsel,samms,samet,salzano,salyards,salva,saidi,sabir,saam,runions,rundquist,rousselle,rotunno,rosch,romney,rohner,roff,rockhill,rocamora,ringle,riggie,ricklefs,rexroat,reves,reuss,repka,rentfro,reineke,recore,recalde,rease,rawling,ravencraft,ravelo,rappa,randol,ramsier,ramerez,rahimi,rahim,radney,racey,raborn,rabalais,quebedeaux,pujol,puchalski,prothro,proffit,prigge,prideaux,prevo,portales,porco,popovic,popek,popejoy,pompei,plude,platner,pizzuto,pizer,pistone,piller,pierri,piehl,pickert,piasecki,phong,philipp,peugh,pesqueira,perrett,perfetti,percell,penhollow,pelto,pellett,pavlak,paulo,pastorius,parsell,parrales,pareja,parcell,pappan,pajak,owusu,ovitt,orrick,oniell,olliff,olberding,oesterling,odwyer,ocegueda,obermiller,nylander,nulph,nottage,northam,norgard,nodal,niel,nicols,newhard,nellum,neira,nazzaro,nassif,narducci,nalbandian,musil,murga,muraoka,mumper,mulroy,mountjoy,mossey,moreton,morea,montoro,montesdeoca,montealegre,montanye,montandon,moisan,mohl,modeste,mitra,minson,minjarez,milbourne,michaelsen,metheney,mestre,mescher,mervis,mennenga,melgarejo,meisinger,meininger,mcwaters,mckern,mckendree,mchargue,mcglothlen,mcgibbon,mcgavock,mcduffee,mcclurkin,mccausland,mccardell,mccambridge,mazzoni,mayen,maxton,mawson,mauffray,mattinson,mattila,matsunaga,mascia,marse,marotz,marois,markin,markee,marcinko,marcin,manville,mantyla,manser,manry,manderscheid,mallari,malecha,malcomb,majerus,macinnis,mabey,lyford,luth,lupercio,luhman,luedke,lovick,lossing,lookabaugh,longway,loisel,logiudice,loffredo,lobaugh,lizaola,livers,littlepage,linnen,limmer,liebsch,liebman,leyden,levitan,levison,levier,leven,levalley,lettinga,lessley,lessig,lepine,leight,leick,leggio,leffingwell,leffert,lefevers,ledlow,leaton,leander,leaming,lazos,laviolette,lauffer,latz,lasorsa,lasch,larin,laporta,lanter,langstaff,landi,lamica,lambson,lambe,lamarca,laman,lamagna,lajeunesse,lafontant,lafler,labrum,laakso,kush,kuether,kuchar,kruk,kroner,kroh,kridler,kreuzer,kovats,koprowski,kohout,knicely,knell,klutts,kindrick,kiddy,khanna,ketcher,kerschner,kerfien,kensey,kenley,kenan,kemplin,kellerhouse,keesling,keas,kaplin,kanady,kampen,jutras,jungers,jeschke,janowski,janas,iskra,imperato,ikerd,igoe,hyneman,hynek,husain,hurrell,hultquist,hullett,hulen,huberty,hoyte,hossain,hornstein,hori,hopton,holms,hollmann,holdman,holdeman,holben,hoffert,himel,hillsman,herdt,hellyer,heister,heimer,heidecker,hedgpeth,hedgepath,hebel,heatwole,hayer,hausner,haskew,haselden,hartranft,harsch,harres,harps,hardimon,halm,hallee,hallahan,hackley,hackenberg,hachey,haapala,guynes,gunnerson,gunby,gulotta,gudger,groman,grignon,griebel,gregori,greenan,grauer,gourd,gorin,gorgone,gooslin,goold,goltz,goldberger,glotfelty,glassford,gladwin,giuffre,gilpatrick,gerdts,geisel,gayler,gaunce,gaulding,gateley,gassman,garson,garron,garand,gangestad,gallow,galbo,gabrielli,fullington,fucci,frum,frieden,friberg,frasco,francese,fowle,foucher,fothergill,foraker,fonder,foisy,fogal,flurry,flenniken,fitzhenry,fishbein,finton,filmore,filice,feola,felberbaum,fausnaught,fasciano,farquharson,faires,estridge,essman,enriques,emmick,ekker,ekdahl,eisman,eggleton,eddinger,eakle,eagar,durio,dunwoody,duhaime,duenes,duden,dudas,dresher,dresel,doutt,donlan,donathan,domke,dobrowolski,dingee,dimmitt,dimery,dilullo,deveaux,devalle,desper,desnoyers,desautels,derouin,derbyshire,denmon,demski,delucca,delpino,delmont,deller,dejulio,deibler,dehne,deharo,degner,defore,deerman,decuir,deckman,deasy,dease,deaner,dawdy,daughdrill,darrigo,darity,dalbey,dagenhart,daffron,curro,curnutte,curatolo,cruikshank,crosswell,croslin,croney,crofton,criado,crecelius,coscia,conniff,commodore,coltharp,colonna,collyer,collington,cobbley,coache,clonts,cloe,cliett,clemans,chrisp,chiarini,cheatam,cheadle,chand,chadd,cervera,cerulli,cerezo,cedano,cayetano,cawthorne,cavalieri,cattaneo,cartlidge,carrithers,carreira,carranco,cargle,candanoza,camburn,calender,calderin,calcagno,cahn,cadden,byham,buttry,burry,burruel,burkitt,burgio,burgener,buescher,buckalew,brymer,brumett,brugnoli,brugman,brosnahan,bronder,broeckel,broderson,brisbon,brinsfield,brinks,bresee,bregman,branner,brambila,brailsford,bouska,boster,borucki,bortner,boroughs,borgeson,bonier,bomba,bolender,boesch,boeke,bloyd,bley,binger,bilbro,biery,bichrest,bezio,bevel,berrett,bermeo,bergdoll,bercier,benzel,bentler,belnap,bellini,beitz,behrend,bednarczyk,bearse,bartolini,bartol,barretta,barbero,barbaro,banvelos,bankes,ballengee,baldon,ausmus,atilano,atienza,aschenbrenner,arora,armstong,aquilino,appleberry,applebee,apolinar,antos,andrepont,ancona,amesquita,alvino,altschuler,allin,alire,ainslie,agular,aeschliman,accetta,abdulla,abbe,zwart,zufelt,zirbel,zingaro,zilnicki,zenteno,zent,zemke,zayac,zarrella,yoshimoto,yearout,womer,woltman,wolin,wolery,woldt,witts,wittner,witherow,winward,winrow,wiemann,wichmann,whitwell,whitelaw,wheeless,whalley,wessner,wenzl,wene,weatherbee,waye,wattles,wanke,walkes,waldeck,vonruden,voisine,vogus,vittetoe,villalva,villacis,venturini,venturi,venson,vanloan,vanhooser,vanduzer,vandever,vanderwal,vanderheyden,vanbeek,vanbebber,vallance,vales,vahle,urbain,upshur,umfleet,tsuji,trybus,triolo,trimarchi,trezza,trenholm,tovey,tourigny,torry,torrain,torgeson,tomey,tischler,tinkler,tinder,ticknor,tibbles,tibbals,throneberry,thormahlen,thibert,thibeaux,theurer,templet,tegeler,tavernier,taubman,tamashiro,tallon,tallarico,taboada,sypher,sybert,swyers,switalski,swedberg,suther,surprenant,sullen,sulik,sugden,suder,suchan,strube,stroope,strittmatter,streett,straughn,strasburg,stjacques,stimage,stimac,stifter,stgelais,steinhart,stehlik,steffenson,steenbergen,stanbery,stallone,spraggs,spoto,spilman,speno,spanbauer,spalla,spagnolo,soliman,solan,sobolik,snelgrove,snedden,smale,sliter,slankard,sircy,shutter,shurtliff,shur,shirkey,shewmake,shams,shadley,shaddox,sgro,serfass,seppala,segawa,segalla,seaberry,scruton,scism,schwein,schwartzman,schwantes,schomer,schoenborn,schlottmann,schissler,scheurer,schepis,scheidegger,saunier,sauders,sassman,sannicolas,sanderfur,salser,sagar,saffer,saeed,sadberry,saban,ryce,rybak,rumore,rummell,rudasill,rozman,rota,rossin,rosell,rosel,romberg,rojero,rochin,robideau,robarge,roath,risko,ringel,ringdahl,riera,riemann,ribas,revard,renegar,reinwald,rehman,redel,raysor,rathke,rapozo,rampton,ramaker,rakow,raia,radin,raco,rackham,racca,racanelli,rabun,quaranta,purves,pundt,protsman,prezioso,presutti,presgraves,poydras,portnoy,portalatin,pontes,poehler,poblete,poat,plumadore,pleiman,pizana,piscopo,piraino,pinelli,pillai,picken,picha,piccoli,philen,petteway,petros,peskin,perugini,perrella,pernice,peper,pensinger,pembleton,passman,parrent,panetta,pallas,palka,pais,paglia,padmore,ottesen,oser,ortmann,ormand,oriol,orick,oler,okafor,ohair,obert,oberholtzer,nowland,nosek,nordeen,nolf,nogle,nobriga,nicley,niccum,newingham,neumeister,neugebauer,netherland,nerney,neiss,neis,neider,neeld,nailor,mustain,mussman,musante,murton,murden,munyon,muldrew,motton,moscoso,moschella,moroz,morelos,morace,moone,montesano,montemurro,montas,montalbo,molander,mleczko,miyake,mitschke,minger,minelli,minear,millener,mihelich,miedema,miah,metzer,mery,merrigan,merck,mennella,membreno,melecio,melder,mehling,mehler,medcalf,meche,mealing,mcqueeney,mcphaul,mcmickle,mcmeen,mcmains,mclees,mcgowin,mcfarlain,mcdivitt,mccotter,mcconn,mccaster,mcbay,mcbath,mayoral,mayeux,matsuo,masur,massman,marzette,martensen,marlett,markgraf,marcinkowski,marchbanks,mansir,mandez,mancil,malagon,magnani,madonia,madill,madia,mackiewicz,macgillivray,macdowell,mabee,lundblad,lovvorn,lovings,loreto,linz,linnell,linebaugh,lindstedt,lindbloom,limberg,liebig,lickteig,lichtenberg,licari,lewison,levario,levar,lepper,lenzen,lenderman,lemarr,leinen,leider,legrande,lefort,lebleu,leask,leacock,lazano,lawalin,laven,laplaca,lant,langsam,langone,landress,landen,lande,lamorte,lairsey,laidlaw,laffin,lackner,lacaze,labuda,labree,labella,labar,kyer,kuyper,kulinski,kulig,kuhnert,kuchera,kubicek,kruckeberg,kruchten,krider,kotch,kornfeld,koren,koogler,koll,kole,kohnke,kohli,kofoed,koelling,kluth,klump,klopfenstein,klippel,klinge,klett,klemp,kleis,klann,kitzman,kinnan,kingsberry,kilmon,killpack,kilbane,kijowski,kies,kierstead,kettering,kesselman,kennington,keniston,kehrer,kearl,keala,kassa,kasahara,kantz,kalin,kaina,jupin,juntunen,juares,joynes,jovel,joos,jiggetts,jervis,jerabek,jennison,jaso,janz,izatt,ishibashi,iannotti,hymas,huneke,hulet,hougen,horvat,horstmann,hopple,holtkamp,holsten,hohenstein,hoefle,hoback,hiney,hiemstra,herwig,herter,herriott,hermsen,herdman,herder,herbig,helling,helbig,heitkamp,heinrichs,heinecke,heileman,heffley,heavrin,heaston,haymaker,hauenstein,hartlage,harig,hardenbrook,hankin,hamiter,hagens,hagel,grizzell,griest,griese,grennan,graden,gosse,gorder,goldin,goatley,gillespi,gilbride,giel,ghoston,gershman,geisinger,gehringer,gedeon,gebert,gaxiola,gawronski,gathright,gatchell,gargiulo,garg,galang,gadison,fyock,furniss,furby,funnell,frizell,frenkel,freeburg,frankhouser,franchi,foulger,formby,forkey,fonte,folson,follette,flavell,finegan,filippini,ferencz,ference,fennessey,feggins,feehan,fazzino,fazenbaker,faunce,farraj,farnell,farler,farabee,falkowski,facio,etzler,ethington,esterline,esper,esker,erxleben,engh,emling,elridge,ellenwood,elfrink,ekhoff,eisert,eifert,eichenlaub,egnor,eggebrecht,edlin,edberg,eble,eber,easler,duwe,dutta,dutremble,dusseault,durney,dunworth,dumire,dukeman,dufner,duey,duble,dreese,dozal,douville,ditmore,distin,dimuzio,dildine,dieterich,dieckman,didonna,dhillon,dezern,devereux,devall,detty,detamore,derksen,deremer,deras,denslow,deno,denicola,denbow,demma,demille,delira,delawder,delara,delahanty,dejonge,deininger,dedios,dederick,decelles,debus,debruyn,deborde,deak,dauenhauer,darsey,dansie,dalman,dakin,dagley,czaja,cybart,cutchin,currington,curbelo,croucher,crinklaw,cremin,cratty,cranfield,crafford,cowher,couvillion,couturier,corter,coombes,contos,consolini,connaughton,conely,collom,cockett,clepper,cleavenger,claro,clarkin,ciriaco,ciesla,cichon,ciancio,cianci,chynoweth,chrzanowski,christion,cholewa,chipley,chilcott,cheyne,cheslock,chenevert,charlot,chagolla,chabolla,cesena,cerutti,cava,caul,cassone,cassin,cassese,casaus,casali,cartledge,cardamone,carcia,carbonneau,carboni,carabello,capozzoli,capella,cannata,campoverde,campeau,cambre,camberos,calvery,calnan,calmes,calley,callery,calise,cacciotti,cacciatore,butterbaugh,burgo,burgamy,burell,bunde,bumbalough,buel,buechner,buchannon,brunn,brost,broadfoot,brittan,brevard,breda,brazel,brayboy,brasier,boyea,boxx,boso,bosio,boruff,borda,bongiovanni,bolerjack,boedeker,blye,blumstein,blumenfeld,blinn,bleakley,blatter,blan,bjornson,bisignano,billick,bieniek,bhatti,bevacqua,berra,berenbaum,bensinger,bennefield,belvins,belson,bellin,beighley,beecroft,beaudreau,baynard,bautch,bausch,basch,bartleson,barthelemy,barak,balzano,balistreri,bailer,bagnall,bagg,auston,augustyn,aslinger,ashalintubbi,arjona,arebalo,appelbaum,angert,angelucci,andry,andersson,amorim,amavisca,alward,alvelo,alvear,alumbaugh,alsobrook,allgeier,allende,aldrete,akiyama,ahlquist,adolphson,addario,acoff,abelson,abasta,zulauf,zirkind,zeoli,zemlicka,zawislak,zappia,zanella,yelvington,yeatman,yanni,wragg,wissing,wischmeier,wirta,wiren,wilmouth,williard,willert,willaert,wildt,whelpley,weingart,weidenbach,weidemann,weatherman,weakland,watwood,wattley,waterson,wambach,walzer,waldow,waag,vorpahl,volkmann,vitolo,visitacion,vincelette,viggiano,vieth,vidana,vert,verges,verdejo,venzon,velardi,varian,vargus,vandermeulen,vandam,vanasse,vanaman,utzinger,uriostegui,uplinger,twiss,tumlinson,tschanz,trunnell,troung,troublefield,trojacek,treloar,tranmer,touchton,torsiello,torina,tootle,toki,toepfer,tippie,thronson,thomes,tezeno,texada,testani,tessmer,terrel,terlizzi,tempel,temblador,tayler,tawil,tasch,tames,talor,talerico,swinderman,sweetland,swager,sulser,sullens,subia,sturgell,stumpff,stufflebeam,stucki,strohmeyer,strebel,straughan,strackbein,stobaugh,stetz,stelter,steinmann,steinfeld,stecher,stanwood,stanislawski,stander,speziale,soppe,soni,sobotka,smuin,slee,skerrett,sjoberg,sittig,simonelli,simo,silverio,silveria,silsby,sillman,sienkiewicz,shomo,shoff,shoener,shiba,sherfey,shehane,sexson,setton,sergi,selvy,seiders,seegmiller,sebree,seabury,scroggin,sconyers,schwalb,schurg,schulenberg,schuld,schrage,schow,schon,schnur,schneller,schmidtke,schlatter,schieffer,schenkel,scheeler,schauwecker,schartz,schacherer,scafe,sayegh,savidge,saur,sarles,sarkissian,sarkis,sarcone,sagucio,saffell,saenger,sacher,rylee,ruvolo,ruston,ruple,rulison,ruge,ruffo,ruehl,rueckert,rudman,rudie,rubert,rozeboom,roysden,roylance,rothchild,rosse,rosecrans,rodi,rockmore,robnett,roberti,rivett,ritzel,rierson,ricotta,ricken,rezac,rendell,reitman,reindl,reeb,reddic,reddell,rebuck,reali,raso,ramthun,ramsden,rameau,ralphs,rago,racz,quinteros,quinter,quinley,quiggle,purvines,purinton,purdum,pummill,puglia,puett,ptacek,przybyla,prowse,prestwich,pracht,poutre,poucher,portera,polinsky,poage,platts,pineau,pinckard,pilson,pilling,pilkins,pili,pikes,pigram,pietila,pickron,philippi,philhower,pflueger,pfalzgraf,pettibone,pett,petrosino,persing,perrino,perotti,periera,peri,peredo,peralto,pennywell,pennel,pellegren,pella,pedroso,paulos,paulding,pates,pasek,paramo,paolino,panganiban,paneto,paluch,ozaki,ownbey,overfelt,outman,opper,onstad,oland,okuda,oertel,oelke,normandeau,nordby,nordahl,noecker,noblin,niswonger,nishioka,nett,negley,nedeau,natera,nachman,naas,musich,mungin,mourer,mounsey,mottola,mothershed,moskal,mosbey,morini,moreles,montaluo,moneypenny,monda,moench,moates,moad,missildine,misiewicz,mirabella,minott,mincks,milum,milani,mikelson,mestayer,mertes,merrihew,merlos,meritt,melnyk,medlen,meder,mcvea,mcquarrie,mcquain,mclucas,mclester,mckitrick,mckennon,mcinnes,mcgrory,mcgranahan,mcglamery,mcgivney,mcgilvray,mccuiston,mccuin,mccrystal,mccolley,mcclerkin,mcclenon,mccamey,mcaninch,mazariegos,maynez,mattioli,mastronardi,masone,marzett,marsland,margulies,margolin,malatesta,mainer,maietta,magrath,maese,madkins,madeiros,madamba,mackson,maben,lytch,lundgreen,lumb,lukach,luick,luetkemeyer,luechtefeld,ludy,ludden,luckow,lubinsky,lowes,lorenson,loran,lopinto,looby,lones,livsey,liskey,lisby,lintner,lindow,lindblom,liming,liechty,leth,lesniewski,lenig,lemonds,leisy,lehrer,lehnen,lehmkuhl,leeth,leeks,lechler,lebsock,lavere,lautenschlage,laughridge,lauderback,laudenslager,lassonde,laroque,laramee,laracuente,lapeyrouse,lampron,lamers,laino,lague,lafromboise,lafata,lacount,lachowicz,kysar,kwiecien,kuffel,kueter,kronenberg,kristensen,kristek,krings,kriesel,krey,krebbs,kreamer,krabbe,kossman,kosakowski,kosak,kopacz,konkol,koepsell,koening,koen,knerr,knapik,kluttz,klocke,klenk,klemme,klapp,kitchell,kita,kissane,kirkbride,kirchhoff,kinter,kinsel,kingsland,kimmer,kimler,killoran,kieser,khalsa,khalaf,kettel,kerekes,keplin,kentner,kennebrew,kenison,kellough,keatts,keasey,kauppi,katon,kanner,kampa,kall,kaczorowski,kaczmarski,juarbe,jordison,jobst,jezierski,jeanbart,jarquin,jagodzinski,ishak,isett,infantino,imburgia,illingworth,hysmith,hynson,hydrick,hurla,hunton,hunnell,humbertson,housand,hottle,hosch,hoos,honn,hohlt,hodel,hochmuth,hixenbaugh,hislop,hisaw,hintzen,hilgendorf,hilchey,higgens,hersman,herrara,hendrixson,hendriks,hemond,hemmingway,heminger,helgren,heisey,heilmann,hehn,hegna,heffern,hawrylak,haverty,hauger,haslem,harnett,harb,happ,hanzlik,hanway,hanby,hanan,hamric,hammaker,halas,hagenbuch,habeck,gwozdz,gunia,guadarrama,grubaugh,grivas,griffieth,grieb,grewell,gregorich,grazier,graeber,graciano,gowens,goodpaster,gondek,gohr,goffney,godbee,gitlin,gisler,gillyard,gillooly,gilchrest,gilbo,gierlach,giebler,giang,geske,gervasio,gertner,gehling,geeter,gaus,gattison,gatica,gathings,gath,gassner,gassert,garabedian,gamon,gameros,galban,gabourel,gaal,fuoco,fullenwider,fudala,friscia,franceschini,foronda,fontanilla,florey,flore,flegle,flecha,fisler,fischbach,fiorita,figura,figgins,fichera,ferra,fawley,fawbush,fausett,farnes,farago,fairclough,fahie,fabiani,evanson,eutsey,eshbaugh,ertle,eppley,englehardt,engelhard,emswiler,elling,elderkin,eland,efaw,edstrom,edgemon,ecton,echeverri,ebright,earheart,dynes,dygert,dyches,dulmage,duhn,duhamel,dubrey,dubray,dubbs,drey,drewery,dreier,dorval,dorough,dorais,donlin,donatelli,dohm,doetsch,dobek,disbrow,dinardi,dillahunty,dillahunt,diers,dier,diekmann,diangelo,deskin,deschaine,depaoli,denner,demyan,demont,demaray,delillo,deleeuw,deibel,decato,deblasio,debartolo,daubenspeck,darner,dardon,danziger,danials,damewood,dalpiaz,dallman,dallaire,cunniffe,cumpston,cumbo,cubero,cruzan,cronkhite,critelli,crimi,creegan,crean,craycraft,cranfill,coyt,courchesne,coufal,corradino,corprew,colville,cocco,coby,clinch,clickner,clavette,claggett,cirigliano,ciesielski,christain,chesbro,chavera,chard,casteneda,castanedo,casseus,caruana,carnero,cappelli,capellan,canedy,cancro,camilleri,calero,cada,burghart,burbidge,bulfer,buis,budniewski,bruney,brugh,brossard,brodmerkel,brockmann,brigmond,briere,bremmer,breck,breau,brautigam,brasch,brandenberger,bragan,bozell,bowsher,bosh,borgia,borey,boomhower,bonneville,bonam,bolland,boise,boeve,boettger,boersma,boateng,bliven,blazier,blahnik,bjornstad,bitton,biss,birkett,billingsly,biagioni,bettle,bertucci,bertolino,bermea,bergner,berber,bensley,bendixen,beltrami,bellone,belland,behringer,begum,bayona,batiz,bassin,baskette,bartolomeo,bartolo,bartholow,barkan,barish,barett,bardo,bamburg,ballerini,balla,balis,bakley,bailon,bachicha,babiarz,ayars,axton,axel,awong,awalt,auslander,ausherman,aumick,atha,atchinson,aslett,askren,arrowsmith,arras,arnhold,armagost,arey,arcos,archibeque,antunes,antilla,andras,amyx,amison,amero,alzate,alper,aller,alioto,aigner,agtarap,agbayani,adami,achorn,aceuedo,acedo,abundis,aber,abee,zuccaro,ziglar,zier,ziebell,zieba,zamzow,zahl,yurko,yurick,yonkers,yerian,yeaman,yarman,yann,yahn,yadon,yadao,woodbridge,wolske,wollenberg,wojtczak,wnuk,witherite,winther,winick,widell,wickens,whichard,wheelis,wesely,wentzell,wenthold,wemple,weisenburger,wehling,weger,weaks,wassink,walquist,wadman,wacaster,waage,voliva,vlcek,villafana,vigliotti,viger,viernes,viands,veselka,versteeg,vero,verhoeven,vendetti,velardo,vatter,vasconcellos,varn,vanwagner,vanvoorhis,vanhecke,vanduyn,vandervoort,vanderslice,valone,vallier,vails,uvalle,ursua,urenda,uphoff,tustin,turton,turnbough,turck,tullio,tuch,truehart,tropea,troester,trippe,tricarico,trevarthen,trembly,trabue,traber,tosi,toal,tinley,tingler,timoteo,tiffin,ticer,thorman,therriault,theel,tessman,tekulve,tejera,tebbs,tavernia,tarpey,tallmadge,takemoto,szot,sylvest,swindoll,swearinger,swantek,swaner,swainston,susi,surrette,sullenger,sudderth,suddarth,suckow,strege,strassburg,stoval,stotz,stoneham,stilley,stille,stierwalt,stfleur,steuck,stermer,stclaire,stano,staker,stahler,stablein,srinivasan,squillace,sprvill,sproull,sprau,sporer,spore,spittler,speelman,sparr,sparkes,spang,spagnuolo,sosinski,sorto,sorkin,sondag,sollers,socia,snarr,smrekar,smolka,slyter,slovinsky,sliwa,slavik,slatter,skiver,skeem,skala,sitzes,sitsler,sitler,sinko,simser,siegler,sideris,shrewsberry,shoopman,shoaff,shindler,shimmin,shill,shenkel,shemwell,shehorn,severa,semones,selsor,sekulski,segui,sechrest,schwer,schwebach,schur,schmiesing,schlick,schlender,schebler,schear,schapiro,sauro,saunder,sauage,satterly,saraiva,saracino,saperstein,sanmartin,sanluis,sandt,sandrock,sammet,sama,salk,sakata,saini,sackrider,russum,russi,russaw,rozzell,roza,rowlette,rothberg,rossano,rosebrock,romanski,romanik,romani,roiger,roig,roehr,rodenberger,rodela,rochford,ristow,rispoli,rigo,riesgo,riebel,ribera,ribaudo,reys,resendes,repine,reisdorf,reisch,rebman,rasmus,raske,ranum,rames,rambin,raman,rajewski,raffield,rady,radich,raatz,quinnie,pyper,puthoff,prow,proehl,pribyl,pretti,prete,presby,poyer,powelson,porteous,poquette,pooser,pollan,ploss,plewa,placide,pion,pinnick,pinales,pillot,pille,pilato,piggee,pietrowski,piermarini,pickford,piccard,phenix,pevey,petrowski,petrillose,pesek,perrotti,peppler,peppard,penfold,pellitier,pelland,pehowic,pedretti,paules,passero,pasha,panza,pallante,palau,pakele,pacetti,paavola,overy,overson,outler,osegueda,oplinger,oldenkamp,ohern,oetting,odums,nowlen,nowack,nordlund,noblett,nobbe,nierman,nichelson,niblock,newbrough,nemetz,needleman,navin,nastasi,naslund,naramore,nakken,nakanishi,najarro,mushrush,muma,mulero,morganfield,moreman,morain,moquin,monterrosa,monsivais,monroig,monje,monfort,moffa,moeckel,mobbs,misiak,mires,mirelez,mineo,mineau,milnes,mikeska,michelin,michalowski,meszaros,messineo,meshell,merten,meola,menton,mends,mende,memmott,melius,mehan,mcnickle,mcmorran,mclennon,mcleish,mclaine,mckendry,mckell,mckeighan,mcisaac,mcie,mcguinn,mcgillis,mcfatridge,mcfarling,mcelravy,mcdonalds,mcculla,mcconnaughy,mcconnaughey,mcchriston,mcbeath,mayr,matyas,matthiesen,matsuura,matinez,mathys,matarazzo,masker,masden,mascio,martis,marrinan,marinucci,margerum,marengo,manthe,mansker,manoogian,mankey,manigo,manier,mangini,maltese,malsam,mallo,maliszewski,mainolfi,maharaj,maggart,magar,maffett,macmaster,macky,macdonnell,lyvers,luzzi,lutman,lovan,lonzo,longerbeam,lofthouse,loethen,lodi,llorens,lizama,litscher,lisowski,lipski,lipsett,lipkin,linzey,lineman,limerick,limas,lige,lierman,liebold,liberti,leverton,levene,lesueur,lenser,lenker,legnon,lefrancois,ledwell,lavecchia,laurich,lauricella,lannigan,landor,lamprecht,lamountain,lamore,lammert,lamboy,lamarque,lamacchia,lalley,lagace,lacorte,lacomb,kyllonen,kyker,kuschel,kupfer,kunde,kucinski,kubacki,kroenke,krech,koziel,kovacich,kothari,koth,kotek,kostelnik,kosloski,knoles,knabe,kmiecik,klingman,kliethermes,kleffman,klees,klaiber,kittell,kissling,kisinger,kintner,kinoshita,kiener,khouri,kerman,kelii,keirn,keezer,kaup,kathan,kaser,karlsen,kapur,kandoll,kammel,kahele,justesen,jonason,johnsrud,joerling,jochim,jespersen,jeong,jenness,jedlicka,jakob,isaman,inghram,ingenito,iadarola,hynd,huxtable,huwe,hurless,humpal,hughston,hughart,huggett,hugar,huether,howdyshell,houtchens,houseworth,hoskie,holshouser,holmen,holloran,hohler,hoefler,hodsdon,hochman,hjort,hippert,hippe,hinzman,hillock,hilden,heyn,heyden,heyd,hergert,henrikson,henningsen,hendel,helget,helf,helbing,heintzman,heggie,hege,hecox,heatherington,heare,haxton,haverstock,haverly,hatler,haselton,hase,hartzfeld,harten,harken,hargrow,haran,hanton,hammar,hamamoto,halper,halko,hackathorn,haberle,haake,gunnoe,gunkel,gulyas,guiney,guilbeau,guider,guerrant,gudgel,guarisco,grossen,grossberg,gropp,groome,grobe,gremminger,greenley,grauberger,grabenstein,gowers,gostomski,gosier,goodenow,gonzoles,goliday,goettle,goens,goates,glymph,glavin,glassco,gladfelter,glackin,githens,girgis,gimpel,gilbreth,gilbeau,giffen,giannotti,gholar,gervasi,gertsch,gernatt,gephardt,genco,gehr,geddis,gase,garrott,garrette,gapinski,ganter,ganser,gangi,gangemi,gallina,galdi,gailes,gaetano,gadomski,gaccione,fuschetto,furtick,furfaro,fullman,frutos,fruchter,frogge,freytag,freudenthal,fregoe,franzone,frankum,francia,franceschi,forys,forero,folkers,flug,flitter,flemons,fitzer,firpo,finizio,filiault,figg,fichtner,fetterolf,ferringer,feil,fayne,farro,faddis,ezzo,ezelle,eynon,evitt,eutsler,euell,escovedo,erne,eriksson,enriguez,empson,elkington,eisenmenger,eidt,eichenberger,ehrmann,ediger,earlywine,eacret,duzan,dunnington,ducasse,dubiel,drovin,drager,drage,donham,donat,dolinger,dokken,doepke,dodwell,docherty,distasio,disandro,diniz,digangi,didion,dezzutti,detmer,deshon,derrigo,dentler,demoura,demeter,demeritt,demayo,demark,demario,delzell,delnero,delgrosso,dejarnett,debernardi,dearmas,dashnaw,daris,danks,danker,dangler,daignault,dafoe,dace,curet,cumberledge,culkin,crowner,crocket,crawshaw,craun,cranshaw,cragle,courser,costella,cornforth,corkill,coopersmith,conzemius,connett,connely,condict,condello,comley,cohoon,coday,clugston,clowney,clippard,clinkenbeard,clines,clelland,clapham,clancey,clabough,cichy,cicalese,chua,chittick,chisom,chisley,chinchilla,cheramie,cerritos,cercone,cena,cawood,cavness,catanzarite,casada,carvell,carmicheal,carll,cardozo,caplin,candia,canby,cammon,callister,calligan,calkin,caillouet,buzzelli,bute,bustillo,bursey,burgeson,bupp,bulson,buist,buffey,buczkowski,buckbee,bucio,brueckner,broz,brookhart,brong,brockmeyer,broberg,brittenham,brisbois,bridgmon,breyer,brede,breakfield,breakey,brauner,branigan,brandewie,branche,brager,brader,bovell,bouthot,bostock,bosma,boseman,boschee,borthwick,borneman,borer,borek,boomershine,boni,bommarito,bolman,boleware,boisse,boehlke,bodle,blash,blasco,blakesley,blacklock,blackley,bittick,birks,birdin,bircher,bilbao,bick,biby,bertoni,bertino,bertini,berson,bern,berkebile,bergstresser,benne,benevento,belzer,beltre,bellomo,bellerose,beilke,begeman,bebee,beazer,beaven,beamish,baymon,baston,bastidas,basom,basey,bartles,baroni,barocio,barnet,barclift,banville,balthazor,balleza,balkcom,baires,bailie,baik,baggott,bagen,bachner,babington,babel,asmar,arvelo,artega,arrendondo,arreaga,arrambide,arquette,aronoff,arico,argentieri,arevalos,archbold,apuzzo,antczak,ankeny,angelle,angelini,anfinson,amer,amarillas,altier,altenburg,alspach,alosa,allsbrook,alexopoulos,aleem,aldred,albertsen,akerson,agler,adley,addams,acoba,achille,abplanalp,abella,abare,zwolinski,zollicoffer,zins,ziff,zenner,zender,zelnick,zelenka,zeches,zaucha,zauala,zangari,zagorski,youtsey,yasso,yarde,yarbough,woolever,woodsmall,woodfolk,wobig,wixson,wittwer,wirtanen,winson,wingerd,wilkening,wilhelms,wierzbicki,wiechman,weyrick,wessell,wenrick,wenning,weltz,weinrich,weiand,wehunt,wareing,walth,waibel,wahlquist,vona,voelkel,vitek,vinsant,vincente,vilar,viel,vicars,vermette,verma,venner,veazie,vayda,vashaw,varon,vardeman,vandevelde,vanbrocklin,vaccarezza,urquidez,urie,urbach,uram,ungaro,umali,ulsh,tutwiler,turnbaugh,tumminello,tuite,tueller,trulove,troha,trivino,trisdale,trippett,tribbett,treptow,tremain,travelstead,trautwein,trautmann,tram,traeger,tonelli,tomsic,tomich,tomasulo,tomasino,tole,todhunter,toborg,tischer,tirpak,tircuit,tinnon,tinnel,tines,timbs,tilden,tiede,thumm,throgmorton,thorndike,thornburgh,thoren,thomann,therrell,thau,thammavong,tetrick,tessitore,tesreau,teicher,teaford,tauscher,tauer,tanabe,talamo,takeuchi,taite,tadych,sweeton,swecker,swartzentrube,swarner,surrell,surbaugh,suppa,sumbry,suchy,stuteville,studt,stromer,strome,streng,stonestreet,stockley,stmichel,stfort,sternisha,stensrud,steinhardt,steinback,steichen,stauble,stasiak,starzyk,stango,standerfer,stachowiak,springston,spratlin,spracklen,sponseller,spilker,spiegelman,spellacy,speiser,spaziani,spader,spackman,sorum,sopha,sollis,sollenberger,solivan,solheim,sokolsky,sogge,smyser,smitley,sloas,slinker,skora,skiff,skare,siverd,sivels,siska,siordia,simmering,simko,sime,silmon,silano,sieger,siebold,shukla,shreves,shoun,shortle,shonkwiler,shoals,shimmel,shiel,shieh,sherbondy,shenkman,shein,shearon,shean,shatz,shanholtz,shafran,shaff,shackett,sgroi,sewall,severy,sethi,sessa,sequra,sepulvado,seper,senteno,sendejo,semmens,seipp,segler,seegers,sedwick,sedore,sechler,sebastiano,scovel,scotton,scopel,schwend,schwarting,schutter,schrier,schons,scholtes,schnetzer,schnelle,schmutz,schlichter,schelling,schams,schamp,scarber,scallan,scalisi,scaffidi,saxby,sawrey,sauvageau,sauder,sarrett,sanzo,santizo,santella,santander,sandez,sandel,sammon,salsedo,salge,sagun,safi,sader,sacchetti,sablan,saade,runnion,runkel,rumbo,ruesch,ruegg,ruckle,ruchti,rubens,rubano,rozycki,roupe,roufs,rossel,rosmarin,rosero,rosenwald,ronca,romos,rolla,rohling,rohleder,roell,roehm,rochefort,roch,robotham,rivenburgh,riopel,riederer,ridlen,rias,rhudy,reynard,retter,respess,reppond,repko,rengifo,reinking,reichelt,reeh,redenius,rebolledo,rauh,ratajczak,rapley,ranalli,ramie,raitt,radloff,radle,rabbitt,quay,quant,pusateri,puffinberger,puerta,provencio,proano,privitera,prenger,prellwitz,pousson,potier,portz,portlock,porth,portela,portee,porchia,pollick,polinski,polfer,polanski,polachek,pluta,plourd,plauche,pitner,piontkowski,pileggi,pierotti,pico,piacente,phinisee,phaup,pfost,pettinger,pettet,petrich,peto,persley,persad,perlstein,perko,pere,penders,peifer,peco,pawley,pash,parrack,parady,papen,pangilinan,pandolfo,palone,palmertree,padin,ottey,ottem,ostroski,ornstein,ormonde,onstott,oncale,oltremari,olcott,olan,oishi,oien,odonell,odonald,obeso,obeirne,oatley,nusser,novo,novicki,nitschke,nistler,nikkel,niese,nierenberg,nield,niedzwiecki,niebla,niebel,nicklin,neyhart,newsum,nevares,nageotte,nagai,mutz,murata,muralles,munnerlyn,mumpower,muegge,muckle,muchmore,moulthrop,motl,moskos,mortland,morring,mormile,morimoto,morikawa,morgon,mordecai,montour,mont,mongan,monell,miyasato,mish,minshew,mimbs,millin,milliard,mihm,middlemiss,miano,mesick,merlan,mendonsa,mench,melonson,melling,meachem,mctighe,mcnelis,mcmurtrey,mckesson,mckenrick,mckelvie,mcjunkins,mcgory,mcgirr,mcgeever,mcfield,mcelhinney,mccrossen,mccommon,mccannon,mazyck,mawyer,maull,matute,mathies,maschino,marzan,martinie,marrotte,marmion,markarian,marinacci,margolies,margeson,marak,maraia,maracle,manygoats,manker,mank,mandich,manderson,maltz,malmquist,malacara,majette,magnan,magliocca,madina,madara,macwilliams,macqueen,maccallum,lyde,lyday,lutrick,lurz,lurvey,lumbreras,luhrs,luhr,lowrimore,lowndes,lourenco,lougee,lorona,longstreth,loht,lofquist,loewenstein,lobos,lizardi,lionberger,limoli,liljenquist,liguori,liebl,liburd,leukhardt,letizia,lesinski,lepisto,lenzini,leisenring,leipold,leier,leggitt,legare,leaphart,lazor,lazaga,lavey,laue,laudermilk,lauck,lassalle,larsson,larison,lanzo,lantzy,lanners,langtry,landford,lancour,lamour,lambertson,lalone,lairson,lainhart,lagreca,lacina,labranche,labate,kurtenbach,kuipers,kuechle,kubo,krinsky,krauser,kraeger,kracht,kozeliski,kozar,kowalik,kotler,kotecki,koslosky,kosel,koob,kolasinski,koizumi,kohlman,koffman,knutt,knore,knaff,kmiec,klamm,kittler,kitner,kirkeby,kiper,kindler,kilmartin,kilbride,kerchner,kendell,keddy,keaveney,kearsley,karlsson,karalis,kappes,kapadia,kallman,kallio,kalil,kader,jurkiewicz,jitchaku,jillson,jeune,jarratt,jarchow,janak,ivins,ivans,isenhart,inocencio,inoa,imhof,iacono,hynds,hutching,hutchin,hulsman,hulsizer,hueston,huddleson,hrbek,howry,housey,hounshell,hosick,hortman,horky,horine,hootman,honeywell,honeyestewa,holste,holien,holbrooks,hoffmeyer,hoese,hoenig,hirschfeld,hildenbrand,higson,higney,hibert,hibbetts,hewlin,hesley,herrold,hermon,hepker,henwood,helbling,heinzman,heidtbrink,hedger,havey,hatheway,hartshorne,harpel,haning,handelman,hamalainen,hamad,halasz,haigwood,haggans,hackshaw,guzzo,gundrum,guilbeault,gugliuzza,guglielmi,guderian,gruwell,grunow,grundman,gruen,grotzke,grossnickle,groomes,grode,grochowski,grob,grein,greif,greenwall,greenup,grassl,grannis,grandfield,grames,grabski,grabe,gouldsberry,gosch,goodling,goodermote,gonzale,golebiowski,goldson,godlove,glanville,gillin,gilkerson,giessler,giambalvo,giacomini,giacobbe,ghio,gergen,gentz,genrich,gelormino,gelber,geitner,geimer,gauthreaux,gaultney,garvie,gareau,garbacz,ganoe,gangwer,gandarilla,galyen,galt,galluzzo,galardo,gager,gaddie,gaber,gabehart,gaarder,fusilier,furnari,furbee,fugua,fruth,frohman,friske,frilot,fridman,frescas,freier,frayer,franzese,frankenberry,frain,fosse,foresman,forbess,flook,fletes,fleer,fleek,fleegle,fishburne,fiscalini,finnigan,fini,filipiak,figueira,fiero,ficek,fiaschetti,ferren,ferrando,ferman,fergusson,fenech,feiner,feig,faulds,fariss,falor,falke,ewings,eversley,everding,etling,essen,erskin,enstrom,engebretsen,eitel,eichberger,ehler,eekhoff,edrington,edmonston,edgmon,edes,eberlein,dwinell,dupee,dunklee,dungey,dunagin,dumoulin,duggar,duenez,dudzic,dudenhoeffer,ducey,drouillard,dreibelbis,dreger,dreesman,draughon,downen,dorminy,dombeck,dolman,doebler,dittberner,dishaw,disanti,dinicola,dinham,dimino,dilling,difrancesco,dicello,dibert,deshazer,deserio,descoteau,deruyter,dering,depinto,dente,demus,demattos,demarsico,delude,dekok,debrito,debois,deakin,dayley,dawsey,dauria,datson,darty,darsow,darragh,darensbourg,dalleva,dalbec,dadd,cutcher,cung,cuello,cuadros,crute,crutchley,crispino,crislip,crisco,crevier,creekmur,crance,cragg,crager,cozby,coyan,coxon,covalt,couillard,costley,costilow,cossairt,corvino,corigliano,cordaro,corbridge,corban,coor,conkel,conary,coltrain,collopy,colgin,colen,colbath,coiro,coffie,cochrum,cobbett,clopper,cliburn,clendenon,clemon,clementi,clausi,cirino,cina,churchman,chilcutt,cherney,cheetham,cheatom,chatelain,chalifour,cesa,cervenka,cerullo,cerreta,cerbone,cecchini,ceccarelli,cawthorn,cavalero,castner,castlen,castine,casimiro,casdorph,cartmill,cartmell,carro,carriger,carias,caravella,cappas,capen,cantey,canedo,camuso,campanaro,cambria,calzado,callejo,caligiuri,cafaro,cadotte,cacace,byrant,busbey,burtle,burres,burnworth,burggraf,burback,bunte,bunke,bulle,bugos,budlong,buckhalter,buccellato,brummet,bruff,brubeck,brouk,broten,brosky,broner,brislin,brimm,brillhart,bridgham,brideau,brennecke,breer,breeland,bredesen,brackney,brackeen,boza,boyum,bowdry,bowdish,bouwens,bouvier,bougie,bouche,bottenfield,bostian,bossie,bosler,boschert,boroff,borello,bonser,bonfield,bole,boldue,bogacz,boemer,bloxom,blickenstaff,blessinger,bleazard,blatz,blanchet,blacksher,birchler,binning,binkowski,biltz,bilotta,bilagody,bigbee,bieri,biehle,bidlack,betker,bethers,bethell,bero,bernacchi,bermingham,berkshire,benvenuto,bensman,benoff,bencivenga,beman,bellow,bellany,belflower,belch,bekker,bejar,beisel,beichner,beedy,beas,beanblossom,bawek,baus,baugus,battie,battershell,bateson,basque,basford,bartone,barritt,barko,bann,bamford,baltrip,balon,balliew,ballam,baldus,ayling,avelino,ashwell,ashland,arseneau,arroyos,armendarez,arita,argust,archuletta,arcement,antonacci,anthis,antal,annan,anderman,amster,amiri,amadon,alveraz,altomari,altmann,altenhofen,allers,allbee,allaway,aleo,alcoser,alcorta,akhtar,ahuna,agramonte,agard,adkerson,achord,abdi,abair,zurn,zoellner,zirk,zion,zarro,zarco,zambo,zaiser,zaino,zachry,youd,yonan,yniguez,yepes,yellock,yellen,yeatts,yearling,yatsko,yannone,wyler,woodridge,wolfrom,wolaver,wolanin,wojnar,wojciak,wittmann,wittich,wiswell,wisser,wintersteen,wineland,willford,wiginton,wigfield,wierman,wice,wiater,whitsel,whitbread,wheller,wettstein,werling,wente,wenig,wempe,welz,weinhold,weigelt,weichman,wedemeyer,weddel,wayment,waycaster,wauneka,watzka,watton,warnell,warnecke,warmack,warder,wands,waldvogel,waldridge,wahs,wagganer,waddill,vyas,vought,votta,voiles,virga,viner,villella,villaverde,villaneda,viele,vickroy,vicencio,vetere,vermilyea,verley,verburg,ventresca,veno,venard,venancio,velaquez,veenstra,vasil,vanzee,vanwie,vantine,vant,vanschoyck,vannice,vankampen,vanicek,vandersloot,vanderpoel,vanderlinde,vallieres,uzzell,uzelac,uranga,uptain,updyke,uong,untiedt,umbrell,umbaugh,umbarger,ulysse,ullmann,ullah,tutko,turturro,turnmire,turnley,turcott,turbyfill,turano,tuminello,tumbleson,tsou,truscott,trulson,troutner,trone,trinklein,tremmel,tredway,trease,traynham,traw,totty,torti,torregrossa,torok,tomkins,tomaino,tkach,tirey,tinsman,timpe,tiefenauer,tiedt,tidball,thwaites,thulin,throneburg,thorell,thorburn,thiemann,thieman,thesing,tham,terrien,telfair,taybron,tasson,tasso,tarro,tanenbaum,taddeo,taborn,tabios,szekely,szatkowski,sylve,swineford,swartzfager,swanton,swagerty,surrency,sunderlin,sumerlin,suero,suddith,sublette,stumpe,stueve,stuckert,strycker,struve,struss,strubbe,strough,strothmann,strahle,stoutner,stooksbury,stonebarger,stokey,stoffer,stimmel,stief,stephans,stemper,steltenpohl,stellato,steinle,stegeman,steffler,steege,steckman,stapel,stansbery,stanaland,stahley,stagnaro,stachowski,squibb,sprunger,sproule,sprehe,spreen,sprecher,sposato,spivery,souter,sopher,sommerfeldt,soffer,snowberger,snape,smylie,smyer,slaydon,slatton,slaght,skovira,skeans,sjolund,sjodin,siragusa,singelton,silis,siebenaler,shuffield,shobe,shiring,shimabukuro,shilts,sherbert,shelden,sheil,shedlock,shearn,shaub,sharbono,shapley,shands,shaheen,shaffner,servantez,sentz,seney,selin,seitzinger,seider,sehr,sego,segall,sebastien,scimeca,schwenck,schweiss,schwark,schwalbe,schucker,schronce,schrag,schouten,schoppe,schomaker,schnarr,schmied,schmader,schlicht,schlag,schield,schiano,scheve,scherbarth,schaumburg,schauman,scarpino,savinon,sassaman,saporito,sanville,santilli,santaana,salzmann,salman,sagraves,safran,saccone,rutty,russett,rupard,rumbley,ruffins,ruacho,rozema,roxas,routson,rourk,rought,rotunda,rotermund,rosman,rork,rooke,rolin,rohm,rohlman,rohl,roeske,roecker,rober,robenson,riso,rinne,riina,rigsbee,riggles,riester,rials,rhinehardt,reynaud,reyburn,rewis,revermann,reutzel,retz,rende,rendall,reistad,reinders,reichardt,rehrig,rehrer,recendez,reamy,rauls,ratz,rattray,rasband,rapone,ragle,ragins,radican,raczka,rachels,raburn,rabren,raboin,quesnell,quaintance,puccinelli,pruner,prouse,prosise,proffer,prochazka,probasco,previte,portell,porcher,popoca,pomroy,poma,polsky,polsgrove,polidore,podraza,plymale,plescia,pleau,platte,pizzi,pinchon,picot,piccione,picazo,philibert,phebus,pfohl,petell,pesso,pesante,pervis,perrins,perley,perkey,pereida,penate,peloso,pellerito,peffley,peddicord,pecina,peale,payette,paxman,pawlikowski,pavy,patry,patmon,patil,pater,patak,pasqua,pasche,partyka,parody,parmeter,pares,pardi,paonessa,panozzo,panameno,paletta,pait,oyervides,ossman,oshima,ortlieb,orsak,onley,oldroyd,okano,ohora,offley,oestreicher,odonovan,odham,odegard,obst,obriant,obrecht,nuccio,nowling,nowden,novelli,nost,norstrom,nordgren,nopper,noller,nisonger,niskanen,nienhuis,nienaber,neuwirth,neumeyer,neice,naugher,naiman,nagamine,mustin,murrietta,murdaugh,munar,muhlbauer,mroczkowski,mowdy,mouw,mousel,mountcastle,moscowitz,mosco,morro,moresi,morago,moomaw,montroy,montpas,montieth,montanaro,mongelli,mollison,mollette,moldovan,mohar,mitchelle,mishra,misenheimer,minshall,minozzi,minniefield,milhous,migliaccio,migdal,mickell,meyering,methot,mester,mesler,meriweather,mensing,mensah,menge,mendibles,meloche,melnik,mellas,meinert,mehrhoff,medas,meckler,mctague,mcspirit,mcshea,mcquown,mcquiller,mclarney,mckiney,mckearney,mcguyer,mcfarlan,mcfadyen,mcdanial,mcdanel,mccurtis,mccrohan,mccorry,mcclune,mccant,mccanna,mccandlish,mcaloon,mayall,maver,maune,matza,matsuzaki,matott,mathey,mateos,masoner,masino,marzullo,marz,marsolek,marquard,marchetta,marberry,manzione,manthei,manka,mangram,mangle,mangel,mandato,mancillas,mammen,malina,maletta,malecki,majkut,mages,maestre,macphail,maco,macneill,macadam,lysiak,lyne,luxton,luptak,lundmark,luginbill,lovallo,louthan,lousteau,loupe,lotti,lopresto,lonsdale,longsworth,lohnes,loghry,logemann,lofaro,loeber,locastro,livings,litzinger,litts,liotta,lingard,lineback,lindhorst,lill,lide,lickliter,liberman,lewinski,levandowski,leimbach,leifer,leidholt,leiby,leibel,leibee,lehrke,lehnherr,lego,leese,leen,ledo,lech,leblond,leahey,lazzari,lawrance,lawlis,lawhorne,lawes,lavigna,lavell,lauzier,lauter,laumann,latsha,latourette,latona,latney,laska,larner,larmore,larke,larence,lapier,lanzarin,lammey,lamke,laminack,lamastus,lamaster,lacewell,labarr,laabs,kutch,kuper,kuna,kubis,krzemien,krupinski,krepps,kreeger,kraner,krammer,kountz,kothe,korpela,komara,kolenda,kolek,kohnen,koelzer,koelsch,kocurek,knoke,knauff,knaggs,knab,kluver,klose,klien,klahr,kitagawa,kissler,kirstein,kinnon,kinnebrew,kinnamon,kimmins,kilgour,kilcoyne,kiester,kiehm,kesselring,kerestes,kenniston,kennamore,kenebrew,kelderman,keitel,kefauver,katzenberger,katt,kast,kassel,kamara,kalmbach,kaizer,kaiwi,kainz,jurczyk,jumonville,juliar,jourdain,johndrow,johanning,johannesen,joffrion,jobes,jerde,jentzsch,jenkens,jendro,jellerson,jefferds,jaure,jaquish,janeway,jago,iwasaki,ishman,isaza,inmon,inlow,inclan,ildefonso,iezzi,ianni,iacovetto,hyldahl,huxhold,huser,humpherys,humburg,hult,hullender,hulburt,huckabay,howeth,hovermale,hoven,houtman,hourigan,hosek,hopgood,homrich,holstine,holsclaw,hokama,hoffpauir,hoffner,hochstein,hochstatter,hochberg,hjelm,hiscox,hinsley,hineman,hineline,hinck,hilbun,hewins,herzing,hertzberg,hertenstein,herrea,herington,henrie,henman,hengst,hemmen,helmke,helgerson,heinsohn,heigl,hegstad,heggen,hegge,hefti,heathcock,haylett,haupert,haufler,hatala,haslip,hartless,hartje,hartis,harpold,harmsen,harbach,hanten,hanington,hammen,hameister,hallstrom,habersham,habegger,gussman,gundy,guitterez,guisinger,guilfoyle,groulx,grismer,griesbach,grawe,grall,graben,goulden,gornick,gori,gookin,gonzalaz,gonyer,gonder,golphin,goller,goergen,glosson,glor,gladin,girdler,gillim,gillians,gillaspie,gilhooly,gildon,gignac,gibler,gibbins,giardino,giampietro,gettman,gerringer,gerrald,gerlich,georgiou,georgi,geiselman,gehman,gangl,gamage,gallian,gallen,gallatin,galea,gainor,gahr,furbush,fulfer,fuhrmann,fritter,friis,friedly,freudenberger,freemon,fratus,frans,foulke,fosler,forquer,fontan,folwell,foeller,fodge,fobes,florek,fliss,flesner,flegel,fitzloff,fiser,firmin,firestine,finfrock,fineberg,fiegel,fickling,fesperman,fernadez,felber,feimster,feazel,favre,faughn,fatula,fasone,farron,faron,farino,falvey,falkenberg,faley,faletti,faeth,fackrell,espe,eskola,escott,esaw,erps,erker,erath,enfield,emfinger,embury,embleton,emanuele,elvers,ellwanger,ellegood,eichinger,egge,egeland,edgett,echard,eblen,eastmond,duteau,durland,dure,dunlavy,dungee,dukette,dugay,duboise,dubey,dsouza,druck,dralle,doubek,dorta,dorch,dorce,dopson,dolney,dockter,distler,dippel,dichiara,dicerbo,dewindt,dewan,deveney,devargas,deutscher,deuel,detter,dess,derrington,deroberts,dern,deponte,denogean,denardi,denard,demary,demarais,delucas,deloe,delmonico,delisi,delio,delduca,deihl,dehmer,decoste,dechick,decatur,debruce,debold,debell,deats,daunt,daquilante,dambrosi,damas,dalin,dahman,dahlem,daffin,dacquel,cutrell,cusano,curtner,currens,curnow,cuppett,cummiskey,cullers,culhane,crull,crossin,cropsey,cromie,crofford,criscuolo,crisafulli,crego,creeden,covello,covel,corse,correra,cordner,cordier,coplen,copeman,contini,conteras,consalvo,conduff,compher,colliver,colan,cohill,cohenour,cogliano,codd,cockayne,clum,clowdus,clarida,clance,clairday,clagg,citron,citino,ciriello,cicciarelli,chrostowski,christley,chrisco,chrest,chisler,chieffo,cherne,cherico,cherian,cheirs,chauhan,chamblin,cerra,cepero,cellini,celedon,cejka,cavagnaro,cauffman,catanese,castrillo,castrellon,casserly,caseres,carthen,carse,carragher,carpentieri,carmony,carmer,carlozzi,caradine,cappola,capece,capaldi,cantres,cantos,canevari,canete,calcaterra,cadigan,cabbell,byrn,bykowski,butchko,busler,bushaw,buschmann,burow,buri,burgman,bunselmeyer,bunning,buhrman,budnick,buckson,buckhannon,brunjes,brumleve,bruckman,brouhard,brougham,brostrom,broerman,brocks,brison,brining,brindisi,brereton,breon,breitling,breedon,brasseaux,branaman,bramon,brackenridge,boyan,boxley,bouman,bouillion,botting,botti,bosshart,borup,borner,bordonaro,bonsignore,bonsall,bolter,bojko,bohne,bohlmann,bogdon,boen,bodenschatz,bockoven,bobrow,blondin,blissett,bligen,blasini,blankenburg,bjorkman,bistline,bisset,birdow,biondolillo,bielski,biele,biddix,biddinger,bianchini,bevens,bevard,betancur,bernskoetter,bernet,bernardez,berliner,berland,berkheimer,berent,bensch,benesch,belleau,bedingfield,beckstrom,beckim,bechler,beachler,bazzell,basa,bartoszek,barsch,barrell,barnas,barnaba,barillas,barbier,baltodano,baltierra,balle,balint,baldi,balderson,balderama,baldauf,balcazar,balay,baiz,bairos,azim,aversa,avellaneda,ausburn,auila,augusto,atwill,artiles,arterberry,arnow,arnaud,arnall,arenz,arduini,archila,arakawa,appleman,aplin,antonini,anstey,anglen,andros,amweg,amstutz,amari,amadeo,alteri,aloi,allebach,aley,alamillo,airhart,ahrendt,aegerter,adragna,admas,adderly,adderley,addair,abelar,abbamonte,abadi,zurek,zundel,zuidema,zuelke,zuck,zogg,zody,zets,zech,zecca,zavaleta,zarr,yousif,yoes,yoast,yeagley,yaney,yanda,yackel,wyles,wyke,woolman,woollard,woodis,woodin,wonderly,wombles,woloszyn,wollam,wnek,wittie,withee,wissman,wisham,wintle,winokur,wilmarth,willhoite,wildner,wikel,wieser,wien,wicke,wiatrek,whitehall,whetstine,wheelus,weyrauch,weyers,westerling,wendelken,welner,weinreb,weinheimer,weilbacher,weihe,weider,wecker,wead,watler,watkinson,wasmer,waskiewicz,wasik,warneke,wares,wangerin,wamble,walken,waker,wakeley,wahlgren,wahlberg,wagler,wachob,vorhies,vonseggern,vittitow,vink,villarruel,villamil,villamar,villalovos,vidmar,victorero,vespa,vertrees,verissimo,veltman,vecchione,veals,varrone,varma,vanveen,vanterpool,vaneck,vandyck,vancise,vanausdal,vanalphen,valdiviezo,urton,urey,updegrove,unrue,ulbrich,tysinger,twiddy,tunson,trueheart,troyan,trier,traweek,trafford,tozzi,toulouse,tosto,toste,torez,tooke,tonini,tonge,tomerlin,tolmie,tobe,tippen,tierno,tichy,thuss,thran,thornbury,thone,theunissen,thelmon,theall,textor,teters,tesh,tench,tekautz,tehrani,teat,teare,tavenner,tartaglione,tanski,tanis,tanguma,tangeman,taney,tammen,tamburri,tamburello,talsma,tallie,takeda,taira,taheri,tademy,taddei,taaffe,szymczak,szczepaniak,szafranski,swygert,swem,swartzlander,sutley,supernaw,sundell,sullivant,suderman,sudbury,suares,stueber,stromme,streeper,streck,strebe,stonehouse,stoia,stohr,stodghill,stirewalt,sterry,stenstrom,stene,steinbrecher,stear,stdenis,stanphill,staniszewski,stanard,stahlhut,stachowicz,srivastava,spong,spomer,spinosa,spindel,spera,soward,sopp,sooter,sonnek,soland,sojourner,soeder,sobolewski,snellings,smola,smetana,smeal,smarr,sloma,sligar,skenandore,skalsky,sissom,sirko,simkin,silverthorn,silman,sikkink,signorile,siddens,shumsky,shrider,shoulta,shonk,shomaker,shippey,shimada,shillingburg,shifflet,shiels,shepheard,sheerin,shedden,sheckles,sharrieff,sharpley,shappell,shaneyfelt,shampine,shaefer,shaddock,shadd,sforza,severtson,setzler,sepich,senne,senatore,sementilli,selway,selover,sellick,seigworth,sefton,seegars,sebourn,seaquist,sealock,seabreeze,scriver,scinto,schumer,schulke,schryver,schriner,schramek,schoon,schoolfield,schonberger,schnieder,schnider,schlitz,schlather,schirtzinger,scherman,schenker,scheiner,scheible,schaus,schakel,schaad,saxe,savely,savary,sardinas,santarelli,sanschagrin,sanpedro,sandine,sandigo,sandgren,sanderford,sandahl,salzwedel,salzar,salvino,salvatierra,salminen,salierno,salberg,sahagun,saelee,sabel,rynearson,ryker,rupprecht,runquist,rumrill,ruhnke,rovira,rottenberg,rosoff,rosete,rosebrough,roppolo,roope,romas,roley,rohrback,rohlfs,rogriguez,roel,rodriguiz,rodewald,roback,rizor,ritt,rippee,riolo,rinkenberger,riggsby,rigel,rieman,riedesel,rideau,ricke,rhinebolt,rheault,revak,relford,reinsmith,reichmann,regula,redlinger,rayno,raycroft,raus,raupp,rathmann,rastorfer,rasey,raponi,rantz,ranno,ranes,ramnauth,rahal,raddatz,quattrocchi,quang,pullis,pulanco,pryde,prohaska,primiano,prez,prevatt,prechtl,pottle,potenza,portes,porowski,poppleton,pontillo,politz,politi,poggi,plonka,plaskett,placzek,pizzuti,pizzaro,pisciotta,pippens,pinkins,pinilla,pini,pingitore,piercey,piccola,piccioni,picciano,philps,philp,philo,philmon,philbin,pflieger,pezzullo,petruso,petrea,petitti,peth,peshlakai,peschel,persico,persichetti,persechino,perris,perlow,perico,pergola,penniston,pembroke,pellman,pekarek,peirson,pearcey,pealer,pavlicek,passino,pasquarello,pasion,parzych,parziale,parga,papalia,papadakis,paino,pacini,oyen,ownes,owczarzak,outley,ouelette,ottosen,otting,ostwinkle,osment,oshita,osario,orlow,oriordan,orefice,orantes,oran,orahood,opel,olpin,oliveria,okon,okerlund,okazaki,ohta,offerman,nyce,nutall,northey,norcia,noor,niehoff,niederhauser,nickolson,nguy,neylon,newstrom,nevill,netz,nesselrodt,nemes,neally,nauyen,nascimento,nardella,nanni,myren,murchinson,munter,mundschenk,mujalli,muckleroy,moussa,mouret,moulds,mottram,motte,morre,montreuil,monton,montellano,monninger,monhollen,mongeon,monestime,monegro,mondesir,monceaux,mola,moga,moening,moccia,misko,miske,mishaw,minturn,mingione,milstein,milla,milks,michl,micheletti,michals,mesia,merson,meras,menifee,meluso,mella,melick,mehlman,meffert,medoza,mecum,meaker,meahl,mczeal,mcwatters,mcomber,mcmonigle,mckiddy,mcgranor,mcgeary,mcgaw,mcenery,mcelderry,mcduffey,mccuistion,mccrudden,mccrossin,mccosh,mccolgan,mcclish,mcclenahan,mcclam,mccartt,mccarrell,mcbane,maybury,mayben,maulden,mauceri,matko,mathie,matheis,mathai,masucci,massiah,martorano,martnez,martindelcamp,marschke,marovich,markiewicz,marinaccio,marhefka,marcrum,manton,mannarino,manlove,mangham,manasco,malpica,mallernee,malinsky,malhotra,maish,maisel,mainville,maharrey,magid,maertz,mada,maclaughlin,macina,macdermott,macallister,macadangdang,maack,lynk,lydic,luyando,lutke,lupinacci,lunz,lundsten,lujano,luhn,luecke,luebbe,ludolph,luckman,lucker,luckenbill,luckenbach,lucido,lowney,lowitz,lovaglio,louro,louk,loudy,louderback,lorick,lorenzini,lorensen,lorenc,lomuscio,loguidice,lockner,lockart,lochridge,litaker,lisowe,liptrap,linnane,linhares,lindfors,lindenmuth,lincourt,liew,liebowitz,levengood,leskovec,lesch,leoni,lennard,legner,leaser,leas,leadingham,lazarski,layland,laurito,laulu,laughner,laughman,laughery,laube,latiolais,lasserre,lasser,larrow,larrea,lapsley,lantrip,lanthier,langwell,langelier,landaker,lampi,lamond,lamblin,lambie,lakins,laipple,lagrimas,lafrancois,laffitte,laday,lacko,lacava,labianca,kutsch,kuske,kunert,kubly,kuamoo,krummel,krise,krenek,kreiser,krausz,kraska,krakowski,kradel,kozik,koza,kotowski,koslow,korber,kojima,kochel,knabjian,klunder,klugh,klinkhammer,kliewer,klever,kleber,klages,klaas,kizziar,kitchel,kishimoto,kirschenman,kirschenbaum,kinnick,kinn,kiner,kindla,kindall,kincaide,kilson,killins,kightlinger,kienzle,kiah,khim,ketcherside,kerl,kelsoe,kelker,keizer,keir,kawano,kawa,kaveney,kasparek,kaplowitz,kantrowitz,kant,kanoff,kano,kamalii,kalt,kaleta,kalbach,kalauli,kalata,kalas,kaigler,kachel,juran,jubb,jonker,jonke,jolivette,joles,joas,jividen,jeffus,jeanty,jarvi,jardon,janvier,janosko,janoski,janiszewski,janish,janek,iwanski,iuliano,irle,ingmire,imber,ijames,iiams,ihrig,ichikawa,hynum,hutzel,hutts,huskin,husak,hurndon,huntsinger,hulette,huitron,huguenin,hugg,hugee,huelskamp,huch,howen,hovanec,hoston,hostettler,horsfall,horodyski,holzhauer,hollimon,hollender,hogarth,hoffelmeyer,histand,hissem,hisel,hirayama,hinegardner,hinde,hinchcliffe,hiltbrand,hilsinger,hillstrom,hiley,hickenbottom,hickam,hibley,heying,hewson,hetland,hersch,herlong,herda,henzel,henshall,helson,helfen,heinbach,heikkila,heggs,hefferon,hebard,heathcote,hearl,heaberlin,hauth,hauschild,haughney,hauch,hattori,hasley,hartpence,harroun,harelson,hardgrove,hardel,hansbrough,handshoe,handly,haluska,hally,halling,halfhill,halferty,hakanson,haist,hairgrove,hahner,hagg,hafele,haaland,guttierez,gutknecht,gunnarson,gunlock,gummersheimer,gullatte,guity,guilmette,guhl,guenette,guardino,groshong,grober,gripp,grillot,grilli,greulich,gretzinger,greenwaldt,graven,grassman,granberg,graeser,graeff,graef,grabow,grabau,gotchy,goswick,gosa,gordineer,gorczyca,goodchild,golz,gollihue,goldwire,goldbach,goffredo,glassburn,glaeser,gillilan,gigante,giere,gieger,gidcumb,giarrusso,giannelli,gettle,gesualdi,geschke,gerwig,gervase,geoffrion,gentilcore,genther,gemes,gemberling,gelles,geitz,geeslin,gedney,gebauer,gawron,gavia,gautney,gaustad,gasmen,gargus,ganske,ganger,galvis,gallinger,gallichio,galletta,gaede,gadlin,gaby,gabrielsen,gaboriault,furlan,furgerson,fujioka,fugett,fuehrer,frint,frigon,frevert,frautschi,fraker,fradette,foulkes,forslund,forni,fontenette,fones,folz,folmer,follman,folkman,flourney,flickner,flemmings,fleischacker,flander,flament,fithian,fiorello,fiorelli,fioravanti,fieck,ficke,fiallos,fiacco,feuer,ferrington,fernholz,feria,fergurson,feick,febles,favila,faulkingham,fath,farnam,falter,fakhouri,fairhurst,fahs,estrello,essick,espree,esmond,eskelson,escue,escatel,erebia,epperley,epler,enyart,engelbert,enderson,emch,elisondo,elford,ekman,eick,eichmann,ehrich,ehlen,edwardson,edley,edghill,edel,eastes,easterbrooks,eagleson,eagen,eade,dyle,dutkiewicz,dunnagan,duncil,duling,drumgoole,droney,dreyfus,dragan,dowty,doscher,dornan,doremus,doogan,donaho,donahey,dombkowski,dolton,dolen,dobratz,diveley,dittemore,ditsch,disque,dishmon,disch,dirickson,dippolito,dimuccio,dilger,diefenderfer,dicola,diblasio,dibello,devan,dettmer,deschner,desbiens,derusha,denkins,demonbreun,demchak,delucchi,delprete,deloy,deliz,deline,delap,deiter,deignan,degiacomo,degaetano,defusco,deboard,debiase,deaville,deadwyler,davanzo,daughton,darter,danser,dandrade,dando,dampeer,dalziel,dalen,dain,dague,czekanski,cutwright,cutliff,curle,cuozzo,cunnington,cunnigham,cumings,crowston,crittle,crispell,crisostomo,crear,creach,craigue,crabbs,cozzi,cozza,coxe,cowsert,coviello,couse,coull,cottier,costagliola,corra,corpening,cormany,corless,corkern,conteh,conkey,conditt,conaty,colomb,collura,colledge,colins,colgate,coleson,colemon,coffland,coccia,clougherty,clewell,cleckley,cleaveland,clarno,civils,cillo,cifelli,ciesluk,christison,chowning,chouteau,choung,childres,cherrington,chenette,cheeves,cheairs,chaddock,cernoch,cerino,cazier,castel,casselberry,caserta,carvey,carris,carmant,cariello,cardarelli,caras,caracciolo,capitano,cantoni,cantave,cancio,campillo,callens,caldero,calamia,cahee,cahan,cahalan,cabanilla,cabal,bywater,bynes,byassee,busker,bushby,busack,burtis,burrola,buroker,burnias,burlock,burham,burak,bulla,buffin,buening,budney,buchannan,buchalter,brule,brugler,broxson,broun,brosh,brissey,brisby,brinlee,brinkmeyer,brimley,brickell,breth,breger,brees,brank,braker,bozak,bowlds,bowersock,bousman,boushie,botz,bordwell,bonkowski,bonine,bonifay,bonesteel,boldin,bohringer,bohlander,boecker,bocook,bocock,boblett,bobbett,boas,boarman,bleser,blazejewski,blaustein,blausey,blancarte,blaize,blackson,blacketer,blackard,bisch,birchett,billa,bilder,bierner,bienvenu,bielinski,bialas,biagini,beynon,beyl,bettini,betcher,bessent,beshara,besch,bernd,bergemann,bergeaux,berdan,bens,benedicto,bendall,beltron,beltram,bellville,beisch,behney,beechler,beckum,batzer,batte,bastida,bassette,basley,bartosh,bartolone,barraclough,barnick,barket,barkdoll,baringer,barella,barbian,barbati,bannan,balles,baldo,balasubramani,baig,bahn,bachmeier,babyak,baas,baars,ayuso,avinger,avella,ausbrooks,aull,augello,atkeson,atkerson,atherley,athan,assad,asebedo,arrison,armon,armfield,arkin,archambeau,antonellis,angotti,amorose,amini,amborn,amano,aluarez,allgaier,allegood,alen,aldama,aird,ahsing,ahmann,aguado,agostino,agostinelli,adwell,adsit,adelstein,actis,acierno,achee,abbs,abbitt,zwagerman,zuercher,zinno,zettler,zeff,zavalza,zaugg,zarzycki,zappulla,zanotti,zachman,zacher,yundt,yslas,younes,yontz,yglesias,yeske,yeargin,yauger,yamane,xang,wylam,wrobleski,wratchford,woodlee,wolsey,wolfinbarger,wohlenhaus,wittler,wittenmyer,witkop,wishman,wintz,winkelmann,windus,winborn,wims,wiltrout,willmott,williston,wilemon,wilbourne,wiedyk,widmann,wickland,wickes,wichert,whitsell,whisenand,whidby,wetz,westmeyer,wertheim,wernert,werle,werkheiser,weldin,weissenborn,weingard,weinfeld,weihl,weightman,weichel,wehrheim,wegrzyn,wegmann,waszak,wankum,walthour,waltermire,walstad,waldren,walbert,walawender,wahlund,wahlert,wahlers,wach,vuncannon,vredenburgh,vonk,vollmar,voisinet,vlahos,viscardi,vires,vipperman,violante,vidro,vessey,vesper,veron,vergari,verbeck,venturino,velastegui,vegter,varas,vanwey,vanvranken,vanvalkenbur,vanorsdale,vanoli,vanochten,vanier,vanevery,vane,vanduser,vandersteen,vandell,vandall,vallot,vallon,vallez,vallely,vadenais,uthe,usery,unga,ultsch,ullom,tyminski,twogood,tursi,turay,tungate,truxillo,trulock,trovato,troise,tripi,trinks,trimboli,trickel,trezise,trefry,treen,trebilcock,travieso,trachtenberg,touhey,tougas,tortorella,tormey,torelli,torborg,toran,tomek,tomassi,tollerson,tolden,toda,tobon,tjelmeland,titmus,tilbury,tietje,thurner,thum,thrope,thornbrough,thibaudeau,thackeray,tesoro,territo,ternes,teich,tecson,teater,teagarden,tatsch,tarallo,tapanes,tanberg,tamm,sylvis,swenor,swedlund,sutfin,sura,sundt,sundin,summerson,sumatzkuku,sultemeier,sulivan,suggitt,suermann,sturkie,sturgess,stumph,stuemke,struckhoff,strose,stroder,stricklen,strick,streib,strei,strawther,stratis,strahm,stortz,storrer,storino,stohler,stohl,stockel,stinnette,stile,stieber,steffenhagen,stefanowicz,steever,steagall,statum,stapley,stanish,standiford,standen,stamos,stahlecker,stadtler,spratley,spraker,sposito,spickard,spehar,spees,spearing,spangle,spallone,soulard,sora,sopko,sood,sonnen,solly,solesbee,soldano,sobey,sobczyk,snedegar,sneddon,smolinski,smolik,slota,slavick,skorupski,skolnik,skirvin,skeels,skains,skahan,skaar,siwiec,siverly,siver,sivak,sirk,sinton,sinor,sincell,silberstein,sieminski,sidelinger,shurman,shunnarah,shirer,shidler,sherlin,shepperson,shemanski,sharum,shartrand,shapard,shanafelt,shamp,shader,shackelton,seyer,seroka,sernas,seright,serano,sengupta,selinger,seith,seidler,seehusen,seefried,scovell,scorzelli,sconiers,schwind,schwichtenber,schwerin,schwenke,schwaderer,schussler,schuneman,schumpert,schultheiss,schroll,schroepfer,schroeden,schrimpf,schook,schoof,schomburg,schoenfeldt,schoener,schnoor,schmick,schlereth,schindele,schildt,schildknecht,schemmel,scharfenberg,schanno,schane,schaer,schad,scearce,scardino,sawka,sawinski,savoca,savery,saults,sarpy,saris,sardinha,sarafin,sankar,sanjurjo,sanderfer,sanagustin,samudio,sammartino,samas,salz,salmen,salkeld,salamon,sakurai,sakoda,safley,sada,sachse,ryden,ryback,russow,russey,ruprecht,rumple,ruffini,rudzinski,rudel,rudden,rovero,routledge,roussin,rousse,rouser,rougeau,rosica,romey,romaniello,rolfs,rogoff,rogne,rodriquz,rodrequez,rodin,rocray,rocke,riviere,rivette,riske,risenhoover,rindfleisch,rinaudo,rimbey,riha,righi,ridner,ridling,riden,rhue,reyome,reynoldson,reusch,rensing,rensch,rennels,renderos,reininger,reiners,reigel,rehmer,regier,reff,redlin,recchia,reaume,reagor,rawe,rattigan,raska,rashed,ranta,ranft,randlett,ramiez,ramella,rallis,rajan,raisbeck,raimondo,raible,ragone,rackliffe,quirino,quiring,quero,quaife,pyke,purugganan,pursifull,purkett,purdon,pulos,puccia,provance,propper,preis,prehn,prata,prasek,pranger,pradier,portor,portley,porte,popiel,popescu,pomales,polowy,pollett,politis,polit,poley,pohler,poggio,podolak,poag,plymel,ploeger,planty,piskura,pirrone,pirro,piroso,pinsky,pilant,pickerill,piccolomini,picart,piascik,phann,petruzzelli,petosa,persson,perretta,perkowski,perilli,percifield,perault,peppel,pember,pelotte,pelcher,peixoto,pehl,peatross,pearlstein,peacher,payden,paya,pawelek,pavey,pauda,pathak,parrillo,parness,parlee,paoli,pannebaker,palomar,palo,palmberg,paganelli,paffrath,padovano,padden,pachucki,ovando,othman,osowski,osler,osika,orsburn,orlowsky,oregel,oppelt,opfer,opdyke,onell,olivos,okumura,okoro,ogas,oelschlaeger,oder,ocanas,obrion,obarr,oare,nyhus,nyenhuis,nunnelley,nunamaker,nuckels,noyd,nowlan,novakovich,noteboom,norviel,nortz,norment,norland,nolt,nolie,nixson,nitka,nissley,nishiyama,niland,niewiadomski,niemeier,nieland,nickey,nicholsen,neugent,neto,nerren,neikirk,neigh,nedrow,neave,nazaire,navaro,navalta,nasworthy,nasif,nalepa,nakao,nakai,nadolny,myklebust,mussel,murthy,muratore,murat,mundie,mulverhill,muilenburg,muetzel,mudra,mudgett,mrozinski,moura,mottinger,morson,moretto,morentin,mordan,mooreland,mooers,monts,montone,montondo,montiero,monie,monat,monares,mollo,mollet,molacek,mokry,mohrmann,mohabir,mogavero,moes,moceri,miyoshi,mitzner,misra,mirr,minish,minge,minckler,milroy,mille,mileski,milanesi,miko,mihok,mihalik,mieczkowski,messerli,meskill,mesenbrink,merton,merryweather,merkl,menser,menner,menk,menden,menapace,melbourne,mekus,meinzer,meers,mctigue,mcquitty,mcpheron,mcmurdie,mcleary,mclafferty,mckinzy,mckibbin,mckethan,mcintee,mcgurl,mceachran,mcdowall,mcdermitt,mccuaig,mccreedy,mccoskey,mcclosky,mcclintick,mccleese,mccanless,mazzucco,mazzocco,mazurkiewicz,mazariego,mayhorn,maxcy,mavity,mauzey,maulding,matuszewski,mattsson,mattke,matsushita,matsuno,matsko,matkin,mathur,masterman,massett,massart,massari,mashni,martella,marren,margotta,marder,marczak,maran,maradiaga,manwarren,manter,mantelli,manso,mangone,manfredonia,malden,malboeuf,malanga,makara,maison,maisano,mairs,mailhiot,magri,madron,madole,mackall,macduff,macartney,lynds,lusane,luffman,louth,loughmiller,lougheed,lotspeich,lorenzi,loosli,longe,longanecker,lonero,lohmeyer,loeza,lobstein,lobner,lober,littman,litalien,lippe,lints,lijewski,ligas,liebert,liebermann,liberati,lezcano,levinthal,lessor,lesieur,lenning,lengel,lempke,lemp,lemar,leitzke,leinweber,legrone,lege,leder,lawnicki,lauth,laun,laughary,lassley,lashway,larrivee,largen,lare,lanouette,lanno,langille,langen,lamonte,lalin,laible,lafratta,laforte,lacuesta,lacer,labore,laboe,labeau,kwasniewski,kunselman,kuhr,kuchler,krugman,kruckenberg,krotzer,kroemer,krist,krigbaum,kreke,kreisman,kreisler,kreft,krasnow,kras,krag,kouyate,kough,kotz,kostura,korner,kornblum,korczynski,koppa,kopczyk,konz,komorowski,kollen,kolander,koepnick,koehne,kochis,knoch,knippers,knaebel,klipp,klinedinst,klimczyk,klier,klement,klaphake,kisler,kinzie,kines,kindley,kimple,kimm,kimbel,kilker,kilborn,kibbey,khong,ketchie,kerbow,kennemore,kennebeck,kenneally,kenndy,kenmore,kemnitz,kemler,kemery,kelnhofer,kellstrom,kellis,kellams,keiter,keirstead,keeny,keelin,keefauver,keams,kautzman,kaus,katayama,kasson,kassim,kasparian,kase,karwoski,kapuscinski,kaneko,kamerling,kamada,kalka,kalar,kakacek,kaczmarczyk,jurica,junes,journell,jolliffe,johnsey,jindra,jimenz,jette,jesperson,jerido,jenrette,jencks,jech,jayroe,jayo,javens,jaskot,jaros,jaquet,janowiak,jaegers,jackel,izumi,irelan,inzunza,imoto,imme,iglehart,iannone,iannacone,huyler,hussaini,hurlock,hurlbutt,huprich,humphry,hulslander,huelsman,hudelson,hudecek,hsia,hreha,hoyland,howk,housholder,housden,houff,horkey,honan,homme,holtzberg,hollyfield,hollings,hollenbaugh,hokenson,hogrefe,hogland,hoel,hodgkin,hochhalter,hjelle,hittson,hinderman,hinchliffe,hime,hilyer,hilby,hibshman,heydt,hewell,heward,hetu,hestand,heslep,herridge,herner,hernande,hermandez,hermance,herbold,heon,henthorne,henion,henao,heming,helmkamp,hellberg,heidgerken,heichel,hehl,hegedus,heckathorne,hearron,haymer,haycook,havlicek,hausladen,haseman,hartsook,hartog,harns,harne,harmann,haren,hanserd,hanners,hanekamp,hamra,hamley,hamelin,hamblet,hakimi,hagle,hagin,haehn,haeck,hackleman,haacke,gulan,guirand,guiles,guggemos,guerrieri,guerreiro,guereca,gudiel,guccione,gubler,gruenwald,gritz,grieser,grewe,grenon,gregersen,grefe,grech,grecco,gravette,grassia,granholm,graner,grandi,grahan,gradowski,gradney,graczyk,gouthier,gottschall,goracke,gootee,goodknight,goodine,gonzalea,gonterman,gonalez,gomm,goleman,goldtooth,goldstone,goldey,golan,goen,goeller,goel,goecke,godek,goan,glunz,gloyd,glodowski,glinski,glawe,girod,girdley,gindi,gillings,gildner,giger,giesbrecht,gierke,gier,giboney,giaquinto,giannakopoulo,giaimo,giaccio,giacalone,gessel,gerould,gerlt,gerhold,geralds,genson,genereux,gellatly,geigel,gehrig,gehle,geerdes,geagan,gawel,gavina,gauss,gatwood,gathman,gaster,garske,garratt,garms,garis,gansburg,gammell,gambale,gamba,galimore,gadway,gadoury,furrer,furino,fullard,fukui,fryou,friesner,friedli,friedl,friedberg,freyermuth,fremin,fredell,fraze,franken,foth,fote,fortini,fornea,formanek,forker,forgette,folan,foister,foglesong,flinck,flewellen,flaten,flaig,fitgerald,fischels,firman,finstad,finkelman,finister,fina,fetterhoff,ferriter,ferch,fennessy,feltus,feltes,feinman,farve,farry,farrall,farag,falzarano,falck,falanga,fakhoury,fairbrother,fagley,faggins,facteau,ewer,ewbank,evola,evener,eustis,estwick,estel,essa,espinola,escutia,eschmann,erpelding,ernsberger,erling,entz,engelhart,enbody,emick,elsinger,ellinwood,ellingsen,ellicott,elkind,eisinger,eisenbeisz,eischen,eimer,eigner,eichhorst,ehmke,egleston,eggett,efurd,edgeworth,eckels,ebey,eberling,eagleton,dwiggins,dweck,dunnings,dunnavant,dumler,duman,dugue,duerksen,dudeck,dreisbach,drawdy,drawbaugh,draine,draggoo,dowse,dovel,doughton,douds,doubrava,dort,dorshorst,dornier,doolen,donavan,dominik,domingez,dolder,dold,dobies,diskin,disano,dirden,diponio,dipirro,dimock,diltz,dillabough,diley,dikes,digges,digerolamo,diel,dicharry,dicecco,dibartolomeo,diamant,dewire,devone,dessecker,dertinger,derousselle,derk,depauw,depalo,denherder,demeyer,demetro,demastus,delvillar,deloye,delosrios,delgreco,delarge,delangel,dejongh,deitsch,degiorgio,degidio,defreese,defoe,decambra,debenedetto,deaderick,daza,dauzat,daughenbaugh,dato,dass,darwish,dantuono,danton,dammeyer,daloia,daleo,dagg,dacey,curts,cuny,cunneen,culverhouse,cucinella,cubit,crumm,crudo,crowford,crout,crotteau,crossfield,crooke,crom,critz,cristaldi,crickmore,cribbin,cremeens,crayne,cradduck,couvertier,cottam,cossio,correy,cordrey,coplon,copass,coone,coody,contois,consla,connelley,connard,congleton,condry,coltey,colindres,colgrove,colfer,colasurdo,cochell,cobbin,clouthier,closs,cloonan,clizbe,clennon,clayburn,claybourn,clausell,clasby,clagett,ciskowski,cirrincione,cinque,cinelli,cimaglia,ciaburri,christiani,christeson,chladek,chizmar,chinnici,chiarella,chevrier,cheves,chernow,cheong,chelton,chanin,cham,chaligoj,celestino,cayce,cavey,cavaretta,caughron,catmull,catapano,cashaw,carullo,carualho,carthon,cartelli,carruba,carrere,carolus,carlstrom,carfora,carello,carbary,caplette,cannell,cancilla,campell,cammarota,camilo,camejo,camarata,caisse,cacioppo,cabbagestalk,cabatu,cabanas,byles,buxbaum,butland,burrington,burnsed,burningham,burlingham,burgy,buitrago,bueti,buehring,buday,bucknell,buchbinder,bucey,bruster,brunston,brouillet,brosious,broomes,brodin,broddy,brochard,britsch,britcher,brierley,brezina,bressi,bressette,breslow,brenden,breier,brei,braymer,brasuell,branscomb,branin,brandley,brahler,bracht,bracamontes,brabson,boyne,boxell,bowery,bovard,boutelle,boulette,bottini,botkins,bosen,boscia,boscarino,borich,boreman,bordoy,bordley,bordenet,boquet,boocks,bolner,boissy,boilard,bohnen,bohall,boening,boccia,boccella,bobe,blyth,biviano,bitto,bisel,binstock,bines,billiter,bigsby,bighorse,bielawski,bickmore,bettin,bettenhausen,besson,beseau,berton,berroa,berntson,bernas,berisford,berhow,bergsma,benyo,benyard,bente,bennion,benko,belsky,bellavance,belasco,belardo,beidler,behring,begnaud,bega,befort,beek,bedore,beddard,becknell,beardslee,beardall,beagan,bayly,bauza,bautz,bausman,baumler,batterson,battenfield,bassford,basse,basemore,baruch,bartholf,barman,baray,barabas,banghart,banez,balsam,ballester,ballagh,baldock,bagnoli,bagheri,bacus,bacho,baccam,axson,averhart,aver,austill,auberry,athans,atcitty,atay,astarita,ascolese,artzer,arrasmith,argenbright,aresco,aranjo,appleyard,appenzeller,apilado,antonetti,antis,annas,angwin,andris,andries,andreozzi,ando,andis,anderegg,amyot,aminov,amelung,amelio,amason,alviar,allendorf,aldredge,alcivar,alaya,alapai,airington,aina,ailor,ahrns,ahmadi,agresta,affolter,aeschlimann,adney,aderhold,adachi,ackiss,aben,abdelhamid,abar,aase,zorilla,zordan,zollman,zoch,zipfel,zimmerle,zike,ziel,zens,zelada,zaman,zahner,zadora,zachar,zaborowski,zabinski,yzquierdo,yoshizawa,yori,yielding,yerton,yehl,yeargain,yeakley,yamaoka,yagle,yablonski,wynia,wyne,wyers,wrzesinski,wrye,wriston,woolums,woolen,woodlock,woodle,wonser,wombacher,wollschlager,wollen,wolfley,wolfer,wisse,wisell,wirsing,winstanley,winsley,winiecki,winiarski,winge,winesett,windell,winberry,willyard,willemsen,wilkosz,wilensky,wikle,wiford,wienke,wieneke,wiederhold,wiebold,widick,wickenhauser,whitrock,whisner,whinery,wherley,whedbee,wheadon,whary,wessling,wessells,wenninger,wendroth,wende,wellard,weirick,weinkauf,wehrman,weech,weathersbee,warncke,wardrip,walstrom,walkowski,walcutt,waight,wagman,waggett,wadford,vowles,vormwald,vondran,vohs,vitt,vitalo,viser,vinas,villena,villaneuva,villafranca,villaflor,vilain,vicory,viana,vian,verucchi,verra,venzke,venske,veley,veile,veeder,vaske,vasconez,vargason,varble,vanwert,vantol,vanscooter,vanmetre,vanmaanen,vanhise,vaneaton,vandyk,vandriel,vandorp,vandewater,vandervelden,vanderstelt,vanderhoef,vanderbeck,vanbibber,vanalstine,vanacore,valdespino,vaill,vailes,vagliardo,ursini,urrea,urive,uriegas,umphress,ucci,uballe,tynon,twiner,tutton,tudela,tuazon,troisi,tripplett,trias,trescott,treichel,tredo,tranter,tozer,toxey,tortorici,tornow,topolski,topia,topel,topalian,tonne,tondre,tola,toepke,tisdell,tiscareno,thornborrow,thomison,thilges,theuret,therien,thagard,thacher,texter,terzo,tenpenny,tempesta,teetz,teaff,tavella,taussig,tatton,tasler,tarrence,tardie,tarazon,tantillo,tanney,tankson,tangen,tamburo,tabone,szilagyi,syphers,swistak,swiatkowski,sweigert,swayzer,swapp,svehla,sutphen,sutch,susa,surma,surls,sundermeyer,sundeen,sulek,sughrue,sudol,sturms,stupar,stum,stuckman,strole,strohman,streed,strebeck,strausser,strassel,stpaul,storts,storr,stommes,stmary,stjulien,stika,stiggers,sthill,stevick,sterman,stepanek,stemler,stelman,stelmack,steinkamp,steinbock,stcroix,stcharles,staudinger,stanly,stallsworth,stalley,srock,spritzer,spracklin,spinuzzi,spidell,speyrer,sperbeck,spendlove,speckman,spargur,spangenberg,spaid,sowle,soulier,sotolongo,sostre,sorey,sonier,somogyi,somera,soldo,soderholm,snoots,snooks,snoke,snodderly,snee,smithhart,smillie,smay,smallman,sliwinski,slentz,sledd,slager,skogen,skog,skarda,skalicky,siwek,sitterson,sisti,sissel,sinopoli,similton,simila,simenson,silvertooth,silos,siggins,sieler,siburt,sianez,shurley,shular,shuecraft,shreeves,shollenberger,shoen,shishido,shipps,shipes,shinall,sherfield,shawe,sharrett,sharrard,shankman,sessum,serviss,servello,serice,serda,semler,semenza,selmon,sellen,seley,seidner,seib,sehgal,seelbach,sedivy,sebren,sebo,seanez,seagroves,seagren,seabron,schwertner,schwegel,schwarzer,schrunk,schriefer,schreder,schrank,schopp,schonfeld,schoenwetter,schnall,schnackenberg,schnack,schmutzler,schmierer,schmidgall,schlup,schloemer,schlitt,schermann,scherff,schellenberg,schain,schaedler,schabel,scaccia,saye,saurez,sasseen,sasnett,sarti,sarra,sarber,santoy,santeramo,sansoucy,sando,sandles,sandau,samra,samaha,salizar,salam,saindon,sagaser,saeteun,sadusky,sackman,sabater,saas,ruthven,ruszkowski,rusche,rumpf,ruhter,ruhenkamp,rufo,rudge,ruddle,rowlee,rowand,routhier,rougeot,rotramel,rotan,rosten,rosillo,rookard,roode,rongstad,rollie,roider,roffe,roettger,rodick,rochez,rochat,rivkin,rivadeneira,riston,risso,rinderknecht,riis,riggsbee,rieker,riegle,riedy,richwine,richmon,ricciuti,riccardo,ricardson,rhew,revier,remsberg,remiszewski,rembold,rella,reinken,reiland,reidel,reichart,rehak,redway,rednour,redifer,redgate,redenbaugh,redburn,readus,raybuck,rauhuff,rauda,ratte,rathje,rappley,rands,ramseyer,ramseur,ramsdale,ramo,ramariz,raitz,raisch,rainone,rahr,ragasa,rafalski,radunz,quenzer,queja,queenan,pyun,putzier,puskas,purrington,puri,punt,pullar,pruse,pring,primeau,prevette,preuett,prestage,pownell,pownall,potthoff,potratz,poth,poter,posthuma,posen,porritt,popkin,poormon,polidoro,polcyn,pokora,poer,pluviose,plock,pleva,placke,pioli,pingleton,pinchback,pieretti,piccone,piatkowski,philley,phibbs,phay,phagan,pfund,peyer,pettersen,petter,petrucelli,petropoulos,petras,petix,pester,pepperman,pennick,penado,pelot,pelis,peeden,pechon,peal,pazmino,patchin,pasierb,parran,parilla,pardy,parcells,paragas,paradee,papin,panko,pangrazio,pangelinan,pandya,pancheri,panas,palmiter,pallares,palinkas,palek,pagliaro,packham,pacitti,ozier,overbaugh,oursler,ouimette,otteson,otsuka,othon,osmundson,oroz,orgill,ordeneaux,orama,oppy,opheim,onkst,oltmanns,olstad,olofson,ollivier,olejniczak,okura,okuna,ohrt,oharra,oguendo,ogier,offermann,oetzel,oechsle,odoherty,oddi,ockerman,occhiogrosso,obryon,obremski,nyreen,nylund,nylen,nyholm,nuon,nuanes,norrick,noris,nordell,norbury,nooner,nomura,nole,nolden,nofsinger,nocito,niedbala,niebergall,nicolini,nevils,neuburger,nemerofsky,nemecek,nazareno,nastri,nast,nagorski,myre,muzzey,mutschler,muther,musumeci,muranaka,muramoto,murad,murach,muns,munno,muncrief,mugrage,muecke,mozer,moyet,mowles,mottern,mosman,mosconi,morine,morge,moravec,morad,mones,moncur,monarez,molzahn,moglia,moesch,mody,modisett,mitnick,mithcell,mitchiner,mistry,misercola,mirabile,minvielle,mino,minkler,minifield,minichiello,mindell,minasian,milteer,millwee,millstein,millien,mikrut,mihaly,miggins,michard,mezo,metzner,mesquita,merriwether,merk,merfeld,mercik,mercadante,menna,mendizabal,mender,melusky,melquist,mellado,meler,melendes,mekeel,meiggs,megginson,meck,mcwherter,mcwayne,mcsparren,mcrea,mcneff,mcnease,mcmurrin,mckeag,mchughes,mcguiness,mcgilton,mcelreath,mcelhone,mcelhenney,mceldowney,mccurtain,mccure,mccosker,mccory,mccormic,mccline,mccleave,mcclatchey,mccarney,mccanse,mcallen,mazzie,mazin,mazanec,mayette,mautz,maun,mattas,mathurin,mathiesen,massmann,masri,masias,mascolo,mascetti,mascagni,marzolf,maruska,martain,marszalek,marolf,marmas,marlor,markwood,marinero,marier,marich,marcom,marciante,marchman,marchio,marbach,manzone,mantey,mannina,manhardt,manaois,malmgren,mallonee,mallin,mallary,malette,makinson,makins,makarewicz,mainwaring,maiava,magro,magouyrk,magett,maeder,madyun,maduena,maden,madeira,mackins,mackel,macinnes,macia,macgowan,lyssy,lyerly,lyalls,lutter,lunney,luksa,ludeman,lucidi,lucci,lowden,lovier,loughridge,losch,lorson,lorenzano,lorden,lorber,lopardo,loosier,loomer,longsdorf,longchamps,loncar,loker,logwood,loeffelholz,lockmiller,livoti,linford,linenberger,lindloff,lindenbaum,limoges,liley,lighthill,lightbourne,lieske,leza,levandoski,leuck,lepere,leonhart,lenon,lemma,lemler,leising,leinonen,lehtinen,lehan,leetch,leeming,ledyard,ledwith,ledingham,leclere,leck,lebert,leandry,lazzell,layo,laye,laxen,lawther,lawerance,lavoy,lavertu,laverde,latouche,latner,lathen,laskin,lashbaugh,lascala,larroque,larick,laraia,laplume,lanzilotta,lannom,landrigan,landolt,landess,lamkins,lalla,lalk,lakeman,lakatos,laib,lahay,lagrave,lagerquist,lafoy,lafleche,lader,labrada,kwiecinski,kutner,kunshier,kulakowski,kujak,kuehnle,kubisiak,krzyminski,krugh,krois,kritikos,krill,kriener,krewson,kretzschmar,kretz,kresse,kreiter,kreischer,krebel,krans,kraling,krahenbuhl,kouns,kotson,kossow,kopriva,konkle,kolter,kolk,kolich,kohner,koeppen,koenigs,kock,kochanski,kobus,knowling,knouff,knoerzer,knippel,kloberdanz,kleinert,klarich,klaassen,kisamore,kirn,kiraly,kipps,kinson,kinneman,kington,kine,kimbriel,kille,kibodeaux,khamvongsa,keylon,kever,keser,kertz,kercheval,kendrix,kendle,kempt,kemple,keesey,keatley,kazmierski,kazda,kazarian,kawashima,katsch,kasun,kassner,kassem,kasperski,kasinger,kaschak,karels,kantola,kana,kamai,kalthoff,kalla,kalani,kahrs,kahanek,kacher,jurasek,jungels,jukes,juelfs,judice,juda,josselyn,jonsson,jonak,joens,jobson,jegede,jeanjacques,jaworowski,jaspers,jannsen,janner,jankowiak,jank,janiak,jackowski,jacklin,jabbour,iyer,iveson,isner,iniquez,ingwerson,ingber,imbrogno,ille,ikehara,iannelli,hyson,huxford,huseth,hurns,hurney,hurles,hunnings,humbarger,hulan,huisinga,hughett,hughen,hudler,hubiak,hricko,hoversten,hottel,hosaka,horsch,hormann,hordge,honzell,homburg,holten,holme,hollopeter,hollinsworth,hollibaugh,holberg,hohmann,hoenstine,hodell,hodde,hiter,hirko,hinzmann,hinrichsen,hinger,hincks,hilz,hilborn,highley,higashi,hieatt,hicken,heverly,hesch,hervert,hershkowitz,herreras,hermanns,herget,henriguez,hennon,hengel,helmlinger,helmig,heldman,heizer,heinitz,heifner,heidorn,heglin,heffler,hebner,heathman,heaslip,hazlip,haymes,hayase,hawver,havermale,havas,hauber,hashim,hasenauer,harvel,hartney,hartel,harsha,harpine,harkrider,harkin,harer,harclerode,hanzely,hanni,hannagan,hampel,hammerschmidt,hamar,hallums,hallin,hainline,haid,haggart,hafen,haer,hadiaris,hadad,hackford,habeeb,guymon,guttery,gunnett,guillette,guiliano,guilbeaux,guiher,guignard,guerry,gude,gucman,guadian,grzybowski,grzelak,grussendorf,grumet,gruenhagen,grudzinski,grossmann,grof,grisso,grisanti,griffitts,griesbaum,grella,gregston,graveline,grandusky,grandinetti,gramm,goynes,gowing,goudie,gosman,gort,gorsline,goralski,goodstein,goodroe,goodlin,goodheart,goodhart,gonzelez,gonthier,goldsworthy,goldade,goettel,goerlitz,goepfert,goehner,goben,gobeille,gliem,gleich,glasson,glascoe,gladwell,giusto,girdner,gipple,giller,giesing,giammona,ghormley,germon,geringer,gergely,gerberich,gepner,gens,genier,gemme,gelsinger,geigle,gebbia,gayner,gavitt,gatrell,gastineau,gasiewski,gascoigne,garro,garin,ganong,ganga,galpin,gallus,galizia,gajda,gahm,gagen,gaffigan,furno,furnia,furgason,fronczak,frishman,friess,frierdich,freestone,franta,frankovich,fors,forres,forrer,florido,flis,flicek,flens,flegal,finkler,finkenbinder,finefrock,filpo,filion,fierman,fieldman,ferreyra,fernendez,fergeson,fera,fencil,feith,feight,federici,federer,fechtner,feagan,fausnaugh,faubert,fata,farman,farinella,fantauzzi,fanara,falso,falardeau,fagnani,fabro,excell,ewton,evey,everetts,evarts,etherington,estremera,estis,estabrooks,essig,esplin,espenschied,ernzen,eppes,eppard,entwisle,emison,elison,elguezabal,eledge,elbaz,eisler,eiden,eichorst,eichert,egle,eggler,eggimann,edey,eckerman,echelberger,ebbs,ebanks,dziak,dyche,dyce,dusch,duross,durley,durate,dunsworth,dumke,dulek,duhl,duggin,dufford,dudziak,ducrepin,dubree,dubre,dubie,dubas,droste,drisko,drewniak,doxtator,dowtin,downum,doubet,dottle,dosier,doshi,dorst,dorset,dornbusch,donze,donica,domanski,domagala,dohse,doerner,doerfler,doble,dobkins,dilts,digiulio,digaetano,dietzel,diddle,dickel,dezarn,devoy,devoss,devilla,devere,deters,desvergnes,deshay,desena,deross,depedro,densley,demorest,demore,demora,demirjian,demerchant,dematteis,demateo,delgardo,delfavero,delaurentis,delamar,delacy,deitrich,deisher,degracia,degraaf,defries,defilippis,decoursey,debruin,debiasi,debar,dearden,dealy,dayhoff,davino,darvin,darrisaw,darbyshire,daquino,daprile,danh,danahy,dalsanto,dallavalle,dagel,dadamo,dacy,dacunha,dabadie,czyz,cutsinger,curney,cuppernell,cunliffe,cumby,cullop,cullinane,cugini,cudmore,cuda,cucuzza,cuch,crumby,crouser,critton,critchley,cremona,cremar,crehan,creary,crasco,crall,crabbe,cozzolino,cozier,coyner,couvillier,counterman,coulthard,coudriet,cottom,corzo,cornutt,corkran,corda,copelin,coonan,consolo,conrow,conran,connerton,conkwright,condren,comly,comisky,colli,collet,colello,colbeck,colarusso,coiner,cohron,codere,cobia,clure,clowser,clingenpeel,clenney,clendaniel,clemenson,cleere,cleckler,claybaugh,clason,cirullo,ciraulo,ciolek,ciampi,christopherse,chovanec,chopra,chol,chiem,chestnutt,chesterman,chernoff,chermak,chelette,checketts,charpia,charo,chargois,champman,challender,chafins,cerruto,celi,cazenave,cavaluzzi,cauthon,caudy,catino,catano,cassaro,cassarino,carrano,carozza,carow,carmickle,carlyon,carlew,cardena,caputi,capley,capalbo,canseco,candella,campton,camposano,calleros,calleja,callegari,calica,calarco,calais,caillier,cahue,cadenhead,cadenas,cabera,buzzo,busto,bussmann,busenbark,burzynski,bursley,bursell,burle,burkleo,burkette,burczyk,bullett,buikema,buenaventura,buege,buechel,budreau,budhram,bucknam,brye,brushwood,brumbalow,brulotte,bruington,bruderer,brougher,bromfield,broege,brodhead,brocklesby,broadie,brizuela,britz,brisendine,brilla,briggeman,brierton,bridgeford,breyfogle,brevig,breuninger,bresse,bresette,brelsford,breitbach,brayley,braund,branscom,brandner,brahm,braboy,brabble,bozman,boyte,boynes,boyken,bowell,bowan,boutet,bouse,boulet,boule,bottcher,bosquez,borrell,boria,bordes,borchard,bonson,bonino,bonas,bonamico,bolstad,bolser,bollis,bolich,bolf,boker,boileau,bohac,bogucki,bogren,boeger,bodziony,bodo,bodley,boback,blyther,blenker,blazina,blase,blamer,blacknall,blackmond,bitz,biser,biscardi,binz,bilton,billotte,billafuerte,bigford,biegler,bibber,bhandari,beyersdorf,bevelle,bettendorf,bessard,bertsche,berne,berlinger,berish,beranek,bentson,bentsen,benskin,benoy,benoist,benitz,belongia,belmore,belka,beitzel,beiter,beitel,behrns,becka,beaudion,beary,beare,beames,beabout,beaber,bazzano,bazinet,baucum,batrez,baswell,bastos,bascomb,bartha,barstad,barrilleaux,barretto,barresi,barona,barkhurst,barke,bardales,barczak,barca,barash,banfill,balonek,balmes,balko,balestrieri,baldino,baldelli,baken,baiza,bahner,baek,badour,badley,badia,backmon,bacich,bacca,ayscue,aynes,ausiello,auringer,auiles,aspinwall,askwith,artiga,arroliga,arns,arman,arellanes,aracena,antwine,antuna,anselmi,annen,angelino,angeli,angarola,andrae,amodio,ameen,alwine,alverio,altro,altobello,altemus,alquicira,allphin,allemand,allam,alessio,akpan,akerman,aiona,agyeman,agredano,adamik,adamczak,acrey,acevado,abreo,abrahamsen,abild,zwicker,zweig,zuvich,zumpano,zuluaga,zubek,zornes,zoglmann,ziminski,zimbelman,zhanel,zenor,zechman,zauner,zamarron,zaffino,yusuf,ytuarte,yett,yerkovich,yelder,yasuda,yapp,yaden,yackley,yaccarino,wytch,wyre,wussow,worthing,wormwood,wormack,wordell,woodroof,woodington,woodhams,wooddell,wollner,wojtkowski,wojcicki,wogan,wlodarczyk,wixted,withington,withem,wisler,wirick,winterhalter,winski,winne,winemiller,wimett,wiltfong,willibrand,willes,wilkos,wilbon,wiktor,wiggers,wigg,wiegmann,wickliff,wiberg,whittler,whittenton,whitling,whitledge,whitherspoon,whiters,whitecotton,whitebird,wheary,wetherill,westmark,westaby,wertenberger,wentland,wenstrom,wenker,wellen,weier,wegleitner,wedekind,wawers,wassel,warehime,wandersee,waltmon,waltersheid,walbridge,wakely,wakeham,wajda,waithe,waidelich,wahler,wahington,wagster,wadel,vuyovich,vuolo,vulich,vukovich,volmer,vollrath,vollbrecht,vogelgesang,voeller,vlach,vivar,vitullo,vitanza,visker,visalli,viray,vinning,viniard,villapando,villaman,vier,viar,viall,verstraete,vermilya,verdon,venn,velten,velis,vanoven,vanorder,vanlue,vanheel,vanderwoude,vanderheide,vandenheuvel,vandenbos,vandeberg,vandal,vanblarcom,vanaken,vanacker,vallian,valine,valent,vaine,vaile,vadner,uttech,urioste,urbanik,unrath,unnasch,underkofler,uehara,tyrer,tyburski,twaddle,turntine,tunis,tullock,tropp,troilo,tritsch,triola,trigo,tribou,tribley,trethewey,tress,trela,treharne,trefethen,trayler,trax,traut,tranel,trager,traczyk,towsley,torrecillas,tornatore,tork,torivio,toriello,tooles,tomme,tolosa,tolen,toca,titterington,tipsword,tinklenberg,tigney,tigert,thygerson,thurn,thur,thorstad,thornberg,thoresen,thomaston,tholen,thicke,theiler,thebeau,theaux,thaker,tewani,teufel,tetley,terrebonne,terrano,terpening,tela,teig,teichert,tegethoff,teele,tatar,tashjian,tarte,tanton,tanimoto,tamimi,tamas,talman,taal,szydlowski,szostak,swoyer,swerdlow,sweeden,sweda,swanke,swander,suyama,suriano,suri,surdam,suprenant,sundet,summerton,sult,suleiman,suffridge,suby,stych,studeny,strupp,struckman,strief,strictland,stremcha,strehl,stramel,stoy,stoutamire,storozuk,stordahl,stopher,stolley,stolfi,stoeger,stockhausen,stjulian,stivanson,stinton,stinchfield,stigler,stieglitz,stgermaine,steuer,steuber,steuart,stepter,stepnowski,stepanian,steimer,stefanelli,stebner,stears,steans,stayner,staubin,statz,stasik,starn,starmer,stargel,stanzione,stankovich,stamour,staib,stadelman,stadel,stachura,squadrito,springstead,spragg,spigelmyer,spieler,spaur,sovocool,soundara,soulia,souffrant,sorce,sonkin,sodhi,soble,sniffen,smouse,smittle,smithee,smedick,slowinski,slovacek,slominski,skowronek,skokan,skanes,sivertson,sinyard,sinka,sinard,simonin,simonian,simmions,silcott,silberg,siefken,siddon,shuttlesworth,shubin,shubeck,shiro,shiraki,shipper,shina,shilt,shikles,shideler,shenton,shelvey,shellito,shelhorse,shawcroft,shatto,shanholtzer,shamonsky,shadden,seymer,seyfarth,setlock,serratos,serr,sepulueda,senay,semmel,semans,selvig,selkirk,selk,seligson,seldin,seiple,seiersen,seidling,seidensticker,secker,searson,scordo,scollard,scoggan,scobee,sciandra,scialdone,schwimmer,schwieger,schweer,schwanz,schutzenhofer,schuetze,schrodt,schriever,schriber,schremp,schrecongost,schraeder,schonberg,scholtz,scholle,schoettle,schoenemann,schoene,schnitker,schmuhl,schmith,schlotterbeck,schleppenbach,schlee,schickel,schibi,schein,scheide,scheibe,scheib,schaumberg,schardein,schaalma,scantlin,scantlebury,sayle,sausedo,saurer,sassone,sarracino,saric,sanz,santarpia,santano,santaniello,sangha,sandvik,sandoral,sandobal,sandercock,sanantonio,salviejo,salsberry,salois,salazer,sagon,saglibene,sagel,sagal,saetern,saefong,sadiq,sabori,saballos,rygiel,rushlow,runco,rulli,ruller,ruffcorn,ruess,ruebush,rudlong,rudin,rudgers,rudesill,ruderman,rucki,rucinski,rubner,rubinson,rubiano,roznowski,rozanski,rowson,rower,rounsaville,roudabush,rotundo,rothell,rotchford,rosiles,roshak,rosetti,rosenkranz,rorer,rollyson,rokosz,rojek,roitman,rohrs,rogel,roewe,rodriges,rodocker,rodgerson,rodan,rodak,rocque,rochholz,robicheau,robbinson,roady,ritchotte,ripplinger,rippetoe,ringstaff,ringenberg,rinard,rigler,rightmire,riesen,riek,ridges,richner,richberg,riback,rial,rhyner,rhees,resse,renno,rendleman,reisz,reisenauer,reinschmidt,reinholt,reinard,reifsnyder,rehfeld,reha,regester,reffitt,redler,rediske,reckner,reckart,rebolloso,rebollar,reasonover,reasner,reaser,reano,reagh,raval,ratterman,ratigan,rater,rasp,raneses,randolf,ramil,ramdas,ramberg,rajaniemi,raggio,ragel,ragain,rade,radaker,racioppi,rabinovich,quickle,quertermous,queal,quartucci,quander,quain,pynes,putzel,purl,pulizzi,pugliares,prusak,prueter,protano,propps,primack,prieur,presta,preister,prawl,pratley,pozzo,powless,povey,pottorf,pote,postley,porzio,portney,ponzi,pontoriero,ponto,pont,poncedeleon,polimeni,polhamus,polan,poetker,poellnitz,podgurski,plotts,pliego,plaugher,plantenberg,plair,plagmann,pizzitola,pittinger,pitcavage,pischke,piontek,pintar,pinnow,pinneo,pinley,pingel,pinello,pimenta,pillard,piker,pietras,piere,phillps,pfleger,pfahl,pezzuti,petruccelli,petrello,peteet,pescatore,peruzzi,perusse,perotta,perona,perini,perelman,perciful,peppin,pennix,pennino,penalosa,pemble,pelz,peltzer,pelphrey,pelote,pellum,pellecchia,pelikan,peitz,pebworth,peary,pawlicki,pavelich,paster,pasquarella,paskey,paseur,paschel,parslow,parrow,parlow,parlett,parler,pargo,parco,paprocki,panepinto,panebianco,pandy,pandey,pamphile,pamintuan,pamer,paluso,paleo,paker,pagett,paczkowski,ozburn,ovington,overmeyer,ouellet,osterlund,oslin,oseguera,osaki,orrock,ormsbee,orlikowski,organista,oregan,orebaugh,orabuena,openshaw,ontiveroz,ondo,omohundro,ollom,ollivierre,olivencia,oley,olazabal,okino,offenberger,oestmann,ocker,obar,oakeson,nuzum,nurre,nowinski,novosel,norquist,nordlie,noorani,nonnemacher,nolder,njoku,niznik,niwa,niss,ninneman,nimtz,niemczyk,nieder,nicolo,nichlos,niblack,newtown,newill,newcom,neverson,neuhart,neuenschwande,nestler,nenno,nejman,neiffer,neidlinger,neglia,nazarian,navor,nary,narayan,nangle,nakama,naish,naik,nadolski,muscato,murphrey,murdick,murchie,muratalla,munnis,mundwiller,muncey,munce,mullenbach,mulhearn,mulcahey,muhammed,muchow,mountford,moudry,mosko,morvay,morrical,morr,moros,mormann,morgen,moredock,morden,mordarski,moravek,morandi,mooradian,montejo,montegut,montan,monsanto,monford,moncus,molinas,molek,mohd,moehrle,moehring,modzeleski,modafferi,moala,moake,miyahira,mitani,mischel,minges,minella,mimes,milles,milbrett,milanes,mikolajczyk,mikami,meucci,metler,methven,metge,messmore,messerschmidt,mesrobian,meservey,merseal,menor,menon,menear,melott,melley,melfi,meinhart,megivern,megeath,meester,meeler,meegan,medoff,medler,meckley,meath,mearns,mcquigg,mcpadden,mclure,mckellips,mckeithen,mcglathery,mcginnes,mcghan,mcdonel,mccullom,mccraken,mccrackin,mcconathy,mccloe,mcclaughry,mcclaflin,mccarren,mccaig,mcaulay,mcaffee,mazzuca,maytubby,mayner,maymi,mattiello,matthis,matthees,matthai,mathiason,mastrogiovann,masteller,mashack,marucci,martorana,martiniz,marter,martellaro,marsteller,marris,marrara,maroni,marolda,marocco,maritn,maresh,maready,marchione,marbut,maranan,maragno,mapps,manrriquez,mannis,manni,mangina,manganelli,mancera,mamon,maloch,mallozzi,maller,majchrzak,majano,mainella,mahanna,maertens,madon,macumber,macioce,machuga,machlin,machala,mabra,lybbert,luvert,lutts,luttrull,lupez,lukehart,ludewig,luchsinger,lovecchio,louissaint,loughney,lostroh,lorton,lopeman,loparo,londo,lombera,lokietek,loiko,lohrenz,lohan,lofties,locklar,lockaby,lobianco,llano,livesey,litster,liske,linsky,linne,lindbeck,licudine,leyua,levie,leonelli,lenzo,lenze,lents,leitao,leidecker,leibold,lehne,legan,lefave,leehy,ledue,lecount,lecea,leadley,lazzara,lazcano,lazalde,lavi,lavancha,lavan,latu,latty,lato,larranaga,lapidus,lapenta,langridge,langeveld,langel,landowski,landgren,landfried,lamattina,lallier,lairmore,lahaie,lagazo,lagan,lafoe,lafluer,laflame,lafevers,lada,lacoss,lachney,labreck,labreche,labay,kwasnik,kuzyk,kutzner,kushnir,kusek,kurtzman,kurian,kulhanek,kuklinski,kueny,kuczynski,kubitz,kruschke,krous,krompel,kritz,krimple,kriese,krenzer,kreis,kratzke,krane,krage,kraebel,kozub,kozma,kouri,koudelka,kotcher,kotas,kostic,kosh,kosar,kopko,kopka,kooy,konigsberg,konarski,kolmer,kohlmeyer,kobbe,knoop,knoedler,knocke,knipple,knippenberg,knickrehm,kneisel,kluss,klossner,klipfel,klawiter,klasen,kittles,kissack,kirtland,kirschenmann,kirckof,kiphart,kinstler,kinion,kilton,killman,kiehl,kief,kett,kesling,keske,kerstein,kepple,keneipp,kempson,kempel,kehm,kehler,keeran,keedy,kebert,keast,kearbey,kawaguchi,kaupu,kauble,katzenbach,katcher,kartes,karpowicz,karpf,karban,kanzler,kanarek,kamper,kaman,kalsow,kalafut,kaeser,kaercher,kaeo,kaeding,jurewicz,julson,jozwick,jollie,johnigan,johll,jochum,jewkes,jestes,jeska,jereb,jaurez,jarecki,jansma,janosik,jandris,jamin,jahr,jacot,ivens,itson,isenhower,iovino,ionescu,ingrum,ingels,imrie,imlay,ihlenfeld,ihde,igou,ibach,huyett,huppe,hultberg,hullihen,hugi,hueso,huesman,hsiao,hronek,hovde,housewright,houlahan,hougham,houchen,hostler,hoster,hosang,hornik,hornes,horio,honyumptewa,honeyman,honer,hommerding,holsworth,hollobaugh,hollinshead,hollands,hollan,holecek,holdorf,hokes,hogston,hoesly,hodkinson,hodgman,hodgens,hochstedler,hochhauser,hobbie,hoare,hnat,hiskey,hirschy,hinostroza,hink,hing,hillmer,hillian,hillerman,hietala,hierro,hickling,hickingbottom,heye,heubusch,hesselschward,herriot,hernon,hermida,hermans,hentschel,henningson,henneke,henk,heninger,heltsley,helmle,helminiak,helmes,hellner,hellmuth,helke,heitmeyer,heird,heinle,heinicke,heinandez,heimsoth,heibel,hegyi,heggan,hefel,heeralall,hedrington,heacox,hazlegrove,hazelett,haymore,havenhill,hautala,hascall,harvie,hartrick,hartling,harrer,harles,hargenrader,hanshew,hanly,hankla,hanisch,hancox,hammann,hambelton,halseth,hallisey,halleck,hallas,haisley,hairr,hainey,hainer,hailstock,haertel,guzek,guyett,guster,gussler,gurwitz,gurka,gunsolus,guinane,guiden,gugliotti,guevin,guevarra,guerard,gudaitis,guadeloupe,gschwind,grupe,grumbach,gruenes,gruenberg,grom,grodski,groden,grizzel,gritten,griswald,grishaber,grinage,grimwood,grims,griffon,griffies,gribben,gressley,gren,greenstreet,grealish,gravett,grantz,granfield,granade,gowell,gossom,gorsky,goring,goodnow,goodfriend,goodemote,golob,gollnick,golladay,goldwyn,goldsboro,golds,goldrick,gohring,gohn,goettsch,goertzen,goelz,godinho,goans,glumac,gleisner,gleen,glassner,glanzer,gladue,gjelaj,givhan,girty,girone,girgenti,giorgianni,gilpatric,gillihan,gillet,gilbar,gierut,gierhart,gibert,gianotti,giannetto,giambanco,gharing,geurts,gettis,gettel,gest,germani,gerdis,gerbitz,geppert,gennings,gemmer,gelvin,gellert,gehler,geddings,gearon,geach,gazaille,gayheart,gauld,gaukel,gaudio,gathing,gasque,garstka,garsee,garringer,garofano,garo,garnsey,garigen,garcias,garbe,ganoung,ganfield,ganaway,gamero,galuska,galster,gallacher,galinski,galimi,galik,galeazzi,galdo,galdames,galas,galanis,gaglio,gaeddert,gadapee,fussner,furukawa,fuhs,fuerte,fuerstenberg,fryrear,froese,fringer,frieson,friesenhahn,frieler,friede,freymuth,freyman,freudenberg,freman,fredricksen,frech,frasch,frantum,frankin,franca,frago,fragnoli,fouquet,fossen,foskett,forner,formosa,formisano,fooks,fons,folino,flott,flesch,flener,flemmons,flanagin,flamino,flamand,fitzerald,findling,filsinger,fillyaw,fillinger,fiechter,ferre,ferdon,feldkamp,fazzio,favia,faulconer,faughnan,faubel,fassler,faso,farrey,farrare,farnworth,farland,fairrow,faille,faherty,fagnant,fabula,fabbri,eylicio,esteve,estala,espericueta,escajeda,equia,enrriquez,enomoto,enmon,engemann,emmerson,emmel,emler,elstad,ellwein,ellerson,eliott,eliassen,elchert,eisenbeis,eisel,eikenberry,eichholz,ehmer,edgerson,echenique,eberley,eans,dziuk,dykhouse,dworak,dutt,dupas,duntz,dunshee,dunovant,dunnaway,dummermuth,duerson,ducotey,duchon,duchesneau,ducci,dubord,duberry,dubach,drummonds,droege,drish,drexel,dresch,dresbach,drenner,drechsler,dowen,dotter,dosreis,doser,dorward,dorin,dorf,domeier,doler,doleman,dolbow,dolbin,dobrunz,dobransky,dobberstein,dlouhy,diosdado,dingmann,dimmer,dimarino,dimaria,dillenburg,dilaura,dieken,dickhaus,dibbles,dibben,diamante,dewilde,dewaard,devich,devenney,devaux,dettinger,desroberts,dershem,dersch,derita,derickson,depina,deorio,deoliveira,denzler,dentremont,denoble,demshar,demond,demint,demichele,demel,delzer,delval,delorbe,delli,delbridge,delanoy,delancy,delahoya,dekle,deitrick,deis,dehnert,degrate,defrance,deetz,deeg,decoster,decena,dearment,daughety,datt,darrough,danzer,danielovich,dandurand,dancause,dalo,dalgleish,daisley,dadlani,daddona,daddio,dacpano,cyprian,cutillo,curz,curvin,cuna,cumber,cullom,cudworth,cubas,crysler,cryderman,crummey,crumbly,crookshanks,croes,criscione,crespi,cresci,creaser,craton,cowin,cowdrey,coutcher,cotterman,cosselman,cosgriff,cortner,corsini,corporan,corniel,cornick,cordts,copening,connick,conlisk,conelli,comito,colten,colletta,coldivar,colclasure,colantuono,colaizzi,coggeshall,cockman,cockfield,cobourn,cobo,cobarrubias,clyatt,cloney,clonch,climes,cleckner,clearo,claybourne,clavin,claridge,claffey,ciufo,cisnero,cipollone,cieslik,ciejka,cichocki,cicchetti,cianflone,chrusciel,christesen,chmielowiec,chirino,chillis,chhoun,chevas,chehab,chaviano,chavaria,chasten,charbonnet,chanley,champoux,champa,chalifoux,cerio,cedotal,cech,cavett,cavendish,catoire,castronovo,castellucci,castellow,castaner,casso,cassels,cassatt,cassar,cashon,cartright,carros,carrisalez,carrig,carrejo,carnicelli,carnett,carlise,carhart,cardova,cardell,carchi,caram,caquias,capper,capizzi,capano,cannedy,campese,calvello,callon,callins,callies,callicutt,calix,calin,califf,calderaro,caldeira,cadriel,cadmus,cadman,caccamise,buttermore,butay,bustamente,busa,burmester,burkard,burhans,burgert,bure,burdin,bullman,bulin,buelna,buehner,budin,buco,buckhanon,bryars,brutger,brus,brumitt,brum,bruer,brucato,broyhill,broy,brownrigg,brossart,brookings,broden,brocklehurst,brockert,bristo,briskey,bringle,bries,bressman,branyan,brands,bramson,brammell,brallier,bozich,boysel,bowthorpe,bowron,bowin,boutilier,boulos,boullion,boughter,bottiglieri,borruso,borreggine,borns,borkoski,borghese,borenstein,boran,booton,bonvillain,bonini,bonello,bolls,boitnott,boike,bohnet,bohnenkamp,bohmer,boeson,boeneke,bodey,bocchino,bobrowski,bobic,bluestein,bloomingdale,blogg,blewitt,blenman,bleck,blaszak,blankenbeckle,blando,blanchfield,blancato,blalack,blakenship,blackett,bisping,birkner,birckhead,bingle,bineau,billiel,bigness,bies,bierer,bhalla,beyerlein,betesh,besler,berzins,bertalan,berntsen,bergo,berganza,bennis,benney,benkert,benjamen,benincasa,bengochia,bendle,bendana,benchoff,benbrook,belsito,belshaw,belinsky,belak,beigert,beidleman,behen,befus,beel,bedonie,beckstrand,beckerle,beato,bauguess,baughan,bauerle,battis,batis,bastone,bassetti,bashor,bary,bartunek,bartoletti,barro,barno,barnicle,barlage,barkus,barkdull,barcellos,barbarino,baranski,baranick,bankert,banchero,bambrick,bamberg,bambenek,balthrop,balmaceda,ballman,balistrieri,balcomb,balboni,balbi,bagner,bagent,badasci,bacot,bache,babione,babic,babers,babbs,avitabile,avers,avena,avance,ausley,auker,audas,aubut,athearn,atcheson,astorino,asplund,aslanian,askari,ashmead,asby,asai,arterbury,artalejo,arqueta,arquero,arostegui,arnell,armeli,arista,arender,arca,arballo,aprea,applen,applegarth,apfel,antonello,antolin,antkowiak,angis,angione,angerman,angelilli,andujo,andrick,anderberg,amigon,amalfitano,alviso,alvez,altice,altes,almarez,allton,allston,allgeyer,allegretti,aliaga,algood,alberg,albarez,albaladejo,akre,aitkin,ahles,ahlberg,agnello,adinolfi,adamis,abramek,abolt,abitong,zurawski,zufall,zubke,zizzo,zipperer,zinner,zinda,ziller,zill,zevallos,zesati,zenzen,zentner,zellmann,zelinsky,zboral,zarcone,zapalac,zaldana,zakes,zaker,zahniser,zacherl,zabawa,zabaneh,youree,younis,yorty,yonce,yero,yerkey,yeck,yeargan,yauch,yashinski,yambo,wrinn,wrightsman,worton,wortley,worland,woolworth,woolfrey,woodhead,woltjer,wolfenden,wolden,wolchesky,wojick,woessner,witters,witchard,wissler,wisnieski,wisinski,winnike,winkowski,winkels,wingenter,wineman,winegardner,wilridge,wilmont,willians,williamsen,wilhide,wilhelmsen,wilhelmi,wildrick,wilden,wiland,wiker,wigglesworth,wiebusch,widdowson,wiant,wiacek,whittet,whitelock,whiteis,whiley,westrope,westpfahl,westin,wessman,wessinger,wesemann,wesby,wertheimer,weppler,wenke,wengler,wender,welp,weitzner,weissberg,weisenborn,weipert,weiman,weidmann,wehrsig,wehrenberg,weemes,weeman,wayner,waston,wasicek,wascom,wasco,warmath,warbritton,waltner,wallenstein,waldoch,waldal,wala,waide,wadlinger,wadhams,vullo,voorheis,vonbargen,volner,vollstedt,vollman,vold,voge,vittorio,violett,viney,vinciguerra,vinal,villata,villarrvel,vilanova,vigneault,vielma,veyna,vessella,versteegh,verderber,venier,venditti,velotta,vejarano,vecchia,vecchi,vastine,vasguez,varella,vanry,vannah,vanhyning,vanhuss,vanhoff,vanhoesen,vandivort,vandevender,vanderlip,vanderkooi,vandebrink,vancott,vallien,vallas,vallandingham,valiquette,valasek,vahey,vagott,uyematsu,urbani,uran,umbach,tyon,tyma,twyford,twombley,twohig,tutterrow,turnes,turkington,turchi,tunks,tumey,tumbaga,tuinstra,tsukamoto,tschetter,trussel,trubey,trovillion,troth,trostel,tron,trinka,trine,triarsi,treto,trautz,tragesser,tooman,toolson,tonozzi,tomkiewicz,tomasso,tolin,tolfree,toelle,tisor,tiry,tinstman,timmermann,tickner,tiburcio,thunberg,thronton,thompsom,theil,thayne,thaggard,teschner,tensley,tenery,tellman,tellado,telep,teigen,teator,teall,tayag,tavis,tattersall,tassoni,tarshis,tappin,tappe,tansley,talone,talford,tainter,taha,taguchi,tacheny,tabak,szymczyk,szwaja,szopinski,syvertsen,swogger,switcher,swist,swierczek,swiech,swickard,swiatek,swezey,swepson,sweezy,swaringen,swanagan,swailes,swade,sveum,svenningsen,svec,suttie,supry,sunga,summerhill,summars,sulit,stys,stutesman,stupak,stumpo,stuller,stuekerjuerge,stuckett,stuckel,stuchlik,stuard,strutton,strop,stromski,stroebel,strehlow,strause,strano,straney,stoyle,stormo,stopyra,stoots,stonis,stoltenburg,stoiber,stoessel,stitzer,stien,stichter,stezzi,stewert,stepler,steinkraus,stegemann,steeples,steenburg,steeley,staszak,stasko,starkson,stanwick,stanke,stanifer,stangel,stai,squiers,spraglin,spragins,spraberry,spoelstra,spisak,spirko,spille,spidel,speyer,speroni,spenst,spartz,sparlin,sparacio,spaman,spainhower,souers,souchet,sosbee,sorn,sorice,sorbo,soqui,solon,soehl,sodergren,sobie,smucker,smsith,smoley,smolensky,smolenski,smolder,smethers,slusar,slowey,slonski,slemmons,slatkin,slates,slaney,slagter,slacum,skutnik,skrzypek,skibbe,sjostrom,sjoquist,sivret,sitko,sisca,sinnett,sineath,simoni,simar,simao,silvestro,silleman,silha,silfies,silberhorn,silacci,sigrist,sieczkowski,sieczka,shure,shulz,shugrue,shrode,shovlin,shortell,shonka,shiyou,shiraishi,shiplett,sheu,shermer,sherick,sheeks,shantz,shakir,shaheed,shadoan,shadid,shackford,shabot,seung,seufert,setty,setters,servis,serres,serrell,serpas,sensenig,senft,semenec,semas,semaan,selvera,sellmeyer,segar,seever,seeney,seeliger,seehafer,seebach,sebben,seaward,seary,searl,searby,scordino,scolieri,scolaro,schwiebert,schwartze,schwaner,schuur,schupbach,schumacker,schum,schudel,schubbe,schroader,schramel,schollmeyer,schoenherr,schoeffler,schoeder,schnurr,schnorr,schneeman,schnake,schnaible,schmaus,schlotter,schinke,schimming,schimek,schikora,scheulen,scherping,schermer,scherb,schember,schellhase,schedler,schanck,schaffhauser,schaffert,schadler,scarola,scarfo,scarff,scantling,scaff,sayward,sayas,saxbury,savel,savastano,sault,satre,sarkar,santellan,sandmeier,sampica,salvesen,saltis,salloum,salling,salce,salatino,salata,salamy,sadowsky,sadlier,sabbatini,sabatelli,sabal,sabados,rydzewski,rybka,rybczyk,rusconi,rupright,rufino,ruffalo,rudiger,rudig,ruda,rubyor,royea,roxberry,rouzer,roumeliotis,rossmann,rosko,rosene,rosenbluth,roseland,rosasco,rosano,rosal,rorabaugh,romie,romaro,rolstad,rollow,rohrich,roghair,rogala,roets,roen,roemmich,roelfs,roeker,roedl,roedel,rodeheaver,roddenberry,rockstad,rocchi,robirds,robben,robasciotti,robaina,rizzotto,rizzio,ritcher,rissman,riseden,ripa,rion,rintharamy,rinehimer,rinck,riling,rietschlin,riesenberg,riemenschneid,rieland,rickenbaugh,rickenbach,rhody,revells,reutter,respress,resnik,remmel,reitmeyer,reitan,reister,reinstein,reino,reinkemeyer,reifschneider,reierson,reichle,rehmeier,rehl,reeds,rede,recar,rebeiro,raybourn,rawl,rautio,raugust,raudenbush,raudales,rattan,rapuano,rapoport,rantanen,ransbottom,raner,ramkissoon,rambousek,raio,rainford,radakovich,rabenhorst,quivers,quispe,quinoes,quilici,quattrone,quates,quance,quale,purswell,purpora,pulera,pulcher,puckhaber,pryer,pruyne,pruit,prudencio,prows,protzman,prothero,prosperi,prospal,privott,pritchet,priem,prest,prell,preer,pree,preddy,preda,pravata,pradhan,potocki,postier,postema,posadas,poremba,popichak,ponti,pomrenke,pomarico,pollok,polkinghorn,polino,pock,plater,plagman,pipher,pinzone,pinkleton,pillette,pillers,pilapil,pignone,pignatelli,piersol,piepho,picton,pickrel,pichard,picchi,piatek,pharo,phanthanouvon,pettingill,pettinato,petrovits,pethtel,petersheim,pershing,perrez,perra,pergram,peretz,perego,perches,pennello,pennella,pendry,penaz,pellish,pecanty,peare,paysour,pavlovich,pavick,pavelko,paustian,patzer,patete,patadia,paszkiewicz,pase,pasculli,pascascio,parrotte,parajon,paparo,papandrea,paone,pantaleon,panning,paniccia,panarello,palmeter,pallan,palardy,pahmeier,padget,padel,oxborrow,oveson,outwater,ottaway,otake,ostermeyer,osmer,osinski,osiecki,oroak,orndoff,orms,orkin,ordiway,opatz,onsurez,onishi,oliger,okubo,okoye,ohlmann,offord,offner,offerdahl,oesterle,oesch,odonnel,odeh,odebralski,obie,obermeier,oberhausen,obenshain,obenchain,nute,nulty,norrington,norlin,nore,nordling,nordhoff,norder,nordan,norals,nogales,noboa,nitsche,niermann,nienhaus,niedringhaus,niedbalski,nicolella,nicolais,nickleberry,nicewander,newfield,neurohr,neumeier,netterville,nersesian,nern,nerio,nerby,nerbonne,neitz,neidecker,neason,nead,navratil,naves,nastase,nasir,nasca,narine,narimatsu,nard,narayanan,nappo,namm,nalbone,nakonechny,nabarro,myott,muthler,muscatello,murriel,murin,muoio,mundel,munafo,mukherjee,muffoletto,muessig,muckey,mucher,mruk,moyd,mowell,mowatt,moutray,motzer,moster,morgenroth,morga,morataya,montross,montezuma,monterroza,montemarano,montello,montbriand,montavon,montaque,monigold,monforte,molgard,moleski,mohsin,mohead,mofield,moerbe,moeder,mochizuki,miyazaki,miyasaki,mital,miskin,mischler,minniear,minero,milosevic,mildenhall,mielsch,midden,michonski,michniak,michitsch,michelotti,micheli,michelfelder,michand,metelus,merkt,merando,meranda,mentz,meneley,menaker,melino,mehaffy,meehl,meech,meczywor,mcweeney,mcumber,mcredmond,mcneer,mcnay,mcmikle,mcmaken,mclaurine,mclauglin,mclaney,mckune,mckinnies,mckague,mchattie,mcgrapth,mcglothen,mcgath,mcfolley,mcdannell,mccurty,mccort,mcclymonds,mcclimon,mcclamy,mccaughan,mccartan,mccan,mccadden,mcburnie,mcburnett,mcbryar,mcannally,mcalevy,mcaleese,maytorena,mayrant,mayland,mayeaux,mauter,matthewson,mathiew,matern,matera,maslow,mashore,masaki,maruco,martorell,martenez,marrujo,marrison,maroun,markway,markos,markoff,markman,marello,marbry,marban,maphis,manuele,mansel,manganello,mandrell,mandoza,manard,manago,maltba,mallick,mallak,maline,malikowski,majure,majcher,maise,mahl,maffit,maffeo,madueno,madlem,madariaga,macvane,mackler,macconnell,macchi,maccarone,lyng,lynchard,lunning,luneau,lunden,lumbra,lumbert,lueth,ludington,luckado,lucchini,lucatero,luallen,lozeau,lowen,lovera,lovelock,louck,lothian,lorio,lorimer,lorge,loretto,longhenry,lonas,loiseau,lohrman,logel,lockie,llerena,livington,liuzzi,liscomb,lippeatt,liou,linhardt,lindelof,lindbo,limehouse,limage,lillo,lilburn,liggons,lidster,liddick,lich,liberato,leysath,lewelling,lesney,leser,lescano,leonette,lentsch,lenius,lemmo,lemming,lemcke,leggette,legerski,legard,leever,leete,ledin,lecomte,lecocq,leakes,leab,lazarz,layous,lawrey,lawery,lauze,lautz,laughinghouse,latulippe,lattus,lattanzio,lascano,larmer,laris,larcher,laprise,lapin,lapage,lano,langseth,langman,langland,landstrom,landsberg,landsaw,landram,lamphier,lamendola,lamberty,lakhani,lajara,lagrow,lagman,ladewig,laderman,ladden,lacrue,laclaire,lachut,lachner,kwit,kvamme,kvam,kutscher,kushi,kurgan,kunsch,kundert,kulju,kukene,kudo,kubin,kubes,kuberski,krystofiak,kruppa,krul,krukowski,kruegel,kronemeyer,krock,kriston,kretzer,krenn,kralik,krafft,krabill,kozisek,koverman,kovatch,kovarik,kotlowski,kosmala,kosky,kosir,kosa,korpi,kornbluth,koppen,kooistra,kohlhepp,kofahl,koeneman,koebel,koczur,kobrin,kobashigawa,koba,knuteson,knoff,knoble,knipper,knierim,kneisley,klusman,kloc,klitzing,klinko,klinefelter,klemetson,kleinpeter,klauser,klatte,klaren,klare,kissam,kirkhart,kirchmeier,kinzinger,kindt,kincy,kincey,kimoto,killingworth,kilcullen,kilbury,kietzman,kienle,kiedrowski,kidane,khamo,khalili,ketterling,ketchem,kessenich,kessell,kepp,kenon,kenning,kennady,kendzior,kemppainen,kellermann,keirns,keilen,keiffer,kehew,keelan,keawe,keator,kealy,keady,kathman,kastler,kastanes,kassab,karpin,karau,karathanasis,kaps,kaplun,kapaun,kannenberg,kanipe,kander,kandel,kanas,kanan,kamke,kaltenbach,kallenberger,kallam,kafton,kafer,kabler,kaaihue,jundt,jovanovich,jojola,johnstad,jodon,joachin,jinright,jessick,jeronimo,jenne,jelsma,jeannotte,jeangilles,jaworsky,jaubert,jarry,jarrette,jarreau,jarett,janos,janecka,janczak,jalomo,jagoda,jagla,jacquier,jaber,iwata,ivanoff,isola,iserman,isais,isaacks,inverso,infinger,ibsen,hyser,hylan,hybarger,hwee,hutchenson,hutchcroft,husar,hurlebaus,hunsley,humberson,hulst,hulon,huhtala,hugill,hugghins,huffmaster,huckeba,hrabovsky,howden,hoverson,houts,houskeeper,housh,hosten,horras,horchler,hopke,hooke,honie,holtsoi,holsomback,holoway,holmstead,hoistion,hohnstein,hoheisel,hoguet,hoggle,hogenson,hoffstetter,hoffler,hofe,hoefling,hoague,hizer,hirschfield,hironaka,hiraldo,hinote,hingston,hinaman,hillie,hillesheim,hilderman,hiestand,heyser,heys,hews,hertler,herrandez,heppe,henle,henkensiefken,henigan,henandez,henagan,hemberger,heman,helser,helmich,hellinger,helfrick,heldenbrand,heinonen,heineck,heikes,heidkamp,heglar,heffren,heelan,hedgebeth,heckmann,heckaman,hechmer,hazelhurst,hawken,haverkamp,havatone,hausauer,hasch,harwick,hartse,harrower,harle,hargroder,hardway,hardinger,hardemon,harbeck,hant,hamre,hamberg,hallback,haisten,hailstone,hahl,hagner,hagman,hagemeyer,haeussler,hackwell,haby,haataja,gverrero,gustovich,gustave,guske,gushee,gurski,gurnett,gura,gunto,gunselman,gugler,gudmundson,gudinas,guarneri,grumbine,gruis,grotz,grosskopf,grosman,grosbier,grinter,grilley,grieger,grewal,gressler,greaser,graus,grasman,graser,grannan,granath,gramer,graboski,goyne,gowler,gottwald,gottesman,goshay,gorr,gorovitz,gores,goossens,goodier,goodhue,gonzeles,gonzalos,gonnella,golomb,golick,golembiewski,goeke,godzik,goar,glosser,glendenning,glendening,glatter,glas,gittings,gitter,gisin,giscombe,gimlin,gillitzer,gillick,gilliand,gilb,gigler,gidden,gibeau,gibble,gianunzio,giannattasio,gertelman,gerosa,gerold,gerland,gerig,gerecke,gerbino,genz,genovesi,genet,gelrud,geitgey,geiszler,gehrlein,gawrys,gavilanes,gaulden,garthwaite,garmoe,gargis,gara,gannett,galligher,galler,galleher,gallahan,galford,gahn,gacek,gabert,fuster,furuya,furse,fujihara,fuhriman,frueh,fromme,froemming,friskney,frietas,freiler,freelove,freber,frear,frankl,frankenfield,franey,francke,foxworthy,formella,foringer,forgue,fonnesbeck,fonceca,folland,fodera,fode,floresca,fleurent,fleshner,flentge,fleischhacker,fleeger,flecher,flam,flaim,fivecoat,firebaugh,fioretti,finucane,filley,figuroa,figuerda,fiddelke,feurtado,fetterly,fessel,femia,feild,fehling,fegett,fedde,fechter,fawver,faulhaber,fatchett,fassnacht,fashaw,fasel,farrugia,farran,farness,farhart,fama,falwell,falvo,falkenstein,falin,failor,faigin,fagundo,fague,fagnan,fagerstrom,faden,eytchison,eyles,everage,evangelist,estrin,estorga,esponda,espindola,escher,esche,escarsega,escandon,erven,erding,eplin,enix,englade,engdahl,enck,emmette,embery,emberson,eltzroth,elsayed,ellerby,ellens,elhard,elfers,elazegui,eisermann,eilertson,eiben,ehrhard,ehresman,egolf,egnew,eggins,efron,effland,edminster,edgeston,eckstrom,eckhard,eckford,echoles,ebsen,eatherly,eastlick,earnheart,dykhuizen,dyas,duttweiler,dutka,dusenbury,dusenbery,durre,durnil,durnell,durie,durhan,durando,dupriest,dunsmoor,dunseith,dunnum,dunman,dunlevy,duma,dulude,dulong,duignan,dugar,dufek,ducos,duchaine,duch,dubow,drowne,dross,drollinger,droke,driggars,drawhorn,drach,drabek,doyne,doukas,dorvil,dorow,doroski,dornak,dormer,donnelson,donivan,dondero,dompe,dolle,doakes,diza,divirgilio,ditore,distel,disimone,disbro,dipiero,dingson,diluzio,dillehay,digiorgio,diflorio,dietzler,dietsch,dieterle,dierolf,dierker,dicostanzo,dicesare,dexheimer,dewitte,dewing,devoti,devincentis,devary,deutschman,dettloff,detienne,destasio,dest,despard,desmet,deslatte,desfosses,derise,derenzo,deppner,depolo,denoyer,denoon,denno,denne,deniston,denike,denes,demoya,demick,demicco,demetriou,demange,delva,delorge,delley,delisio,delhoyo,delgrande,delgatto,delcour,delair,deinert,degruy,degrave,degeyter,defino,deffenbaugh,deener,decook,decant,deboe,deblanc,deatley,dearmitt,deale,deaguiar,dayan,daus,dauberman,datz,dase,dary,dartt,darocha,dari,danowski,dancel,dami,dallmann,dalere,dalba,dakan,daise,dailing,dahan,dagnan,daggs,dagan,czarkowski,czaplinski,cutten,curtice,curenton,curboy,cura,culliton,culberth,cucchiara,cubbison,csaszar,crytser,crotzer,crossgrove,crosser,croshaw,crocco,critzer,creveling,cressy,creps,creese,cratic,craigo,craigen,craib,cracchiolo,crable,coykendall,cowick,coville,couzens,coutch,cousens,cousain,counselman,coult,cotterell,cott,cotham,corsaut,corriere,corredor,cornet,corkum,coreas,cordoza,corbet,corathers,conwill,contreas,consuegra,constanza,conolly,conedy,comins,combee,colosi,colom,colmenares,collymore,colleran,colina,colaw,colatruglio,colantro,colantonio,cohea,cogill,codner,codding,cockram,cocanougher,cobine,cluckey,clucas,cloward,cloke,clisham,clinebell,cliffe,clendenen,cisowski,cirelli,ciraolo,ciocca,cintora,ciesco,cibrian,chupka,chugg,christmann,choma,chiverton,chirinos,chinen,chimenti,chima,cheuvront,chesla,chesher,chesebro,chern,chehebar,cheatum,chastine,chapnick,chapelle,chambley,cercy,celius,celano,cayea,cavicchi,cattell,catanach,catacutan,castelluccio,castellani,cassmeyer,cassetta,cassada,caspi,cashmore,casebier,casanas,carrothers,carrizal,carriveau,carretero,carradine,carosella,carnine,carloni,carkhuff,cardosi,cardo,carchidi,caravello,caranza,carandang,cantrall,canpos,canoy,cannizzaro,canion,canida,canham,cangemi,cange,cancelliere,canard,camarda,calverley,calogero,callendar,calame,cadrette,cachero,caccavale,cabreros,cabrero,cabrara,cabler,butzer,butte,butrick,butala,bustios,busser,busic,bushorn,busher,burmaster,burkland,burkins,burkert,burgueno,burgraff,burel,burck,burby,bumford,bulock,bujnowski,buggie,budine,bucciero,bubier,brzoska,brydges,brumlow,brosseau,brooksher,brokke,broeker,brittin,bristle,briano,briand,brettschneide,bresnan,brentson,brenneis,brender,brazle,brassil,brasington,branstrom,branon,branker,brandwein,brandau,bralley,brailey,brague,brade,bozzi,bownds,bowmer,bournes,bour,bouchey,botto,boteler,borroel,borra,boroski,boothroyd,boord,bonga,bonato,bonadonna,bolejack,boldman,boiser,boggio,bogacki,boerboom,boehnlein,boehle,bodah,bobst,boak,bluemel,blockmon,blitch,blincoe,bleier,blaydes,blasius,bittel,binsfeld,bindel,bilotti,billiott,bilbrew,bihm,biersner,bielat,bidrowski,bickler,biasi,bhola,bhat,bewick,betzen,bettridge,betti,betsch,besley,beshero,besa,bertoli,berstein,berrien,berrie,berrell,bermel,berenguer,benzer,bensing,benedix,bemo,belile,beilman,behunin,behrmann,bedient,becht,beaule,beaudreault,bealle,beagley,bayuk,bayot,bayliff,baugess,battistoni,batrum,basinski,basgall,bartolomei,bartnik,bartl,bartko,bartholomay,barthlow,bartgis,barsness,barski,barlette,barickman,bargen,bardon,barcliff,barbu,barakat,baracani,baraban,banos,banko,bambach,balok,balogun,bally,baldini,balck,balcer,balash,baim,bailor,bahm,bahar,bagshaw,baggerly,badie,badal,backues,babino,aydelott,awbrey,aversano,avansino,auyon,aukamp,aujla,augenstein,astacio,asplin,asato,asano,aruizu,artale,arrick,arneecher,armelin,armbrester,armacost,arkell,argrave,areizaga,apolo,anzures,anzualda,antwi,antillon,antenor,annand,anhalt,angove,anglemyer,anglada,angiano,angeloni,andaya,ancrum,anagnos,ammirati,amescua,ambrosius,amacker,amacher,amabile,alvizo,alvernaz,alvara,altobelli,altobell,althauser,alterman,altavilla,alsip,almeyda,almeter,alman,allscheid,allaman,aliotta,aliberti,alghamdi,albiston,alberding,alarie,alano,ailes,ahsan,ahrenstorff,ahler,aerni,ackland,achor,acero,acebo,abshier,abruzzo,abrom,abood,abnet,abend,abegg,abbruzzese,aaberg,zysk,zutell,zumstein,zummo,zuhlke,zuehlsdorff,zuch,zucconi,zortman,zohn,zingone,zingg,zingale,zima,zientek,zieg,zervas,zerger,zenk,zeldin,zeiss,zeiders,zediker,zavodny,zarazua,zappone,zappala,zapanta,zaniboni,zanchi,zampedri,zaller,zakrajsek,zagar,zadrozny,zablocki,zable,yust,yunk,youngkin,yosten,yockers,yochim,yerke,yerena,yanos,wysinger,wyner,wrisley,woznicki,wortz,worsell,wooters,woon,woolcock,woodke,wonnacott,wolnik,wittstock,witting,witry,witfield,witcraft,wissmann,wissink,wisehart,wiscount,wironen,wipf,winterrowd,wingett,windon,windish,windisch,windes,wiltbank,willmarth,wiler,wieseler,wiedmaier,wiederstein,wiedenheft,wieberg,wickware,wickkiser,wickell,whittmore,whitker,whitegoat,whitcraft,whisonant,whisby,whetsell,whedon,westry,westcoat,wernimont,wentling,wendlandt,wencl,weisgarber,weininger,weikle,weigold,weigl,weichbrodt,wehrli,wehe,weege,weare,watland,wassmann,warzecha,warrix,warrell,warnack,waples,wantland,wanger,wandrei,wanat,wampole,waltjen,walterscheid,waligora,walding,waldie,walczyk,wakins,waitman,wair,wainio,wahpekeche,wahlman,wagley,wagenknecht,wadle,waddoups,wadding,vuono,vuillemot,vugteveen,vosmus,vorkink,vories,vondra,voelz,vlashi,vitelli,vitali,viscarra,vinet,vimont,villega,villard,vignola,viereck,videtto,vicoy,vessell,vescovi,verros,vernier,vernaglia,vergin,verdone,verdier,verastequi,vejar,vasile,vasi,varnadore,vardaro,vanzanten,vansumeren,vanschuyver,vanleeuwen,vanhowe,vanhoozer,vaness,vandewalker,vandevoorde,vandeveer,vanderzwaag,vanderweide,vanderhyde,vandellen,vanamburg,vanalst,vallin,valk,valentini,valcarcel,valasco,valadao,vacher,urquijo,unterreiner,unsicker,unser,unrau,undercoffler,uffelman,uemura,ueda,tyszko,tyska,tymon,tyce,tyacke,twinam,tutas,tussing,turmel,turkowski,turkel,turchetta,tupick,tukes,tufte,tufo,tuey,tuell,tuckerman,tsutsumi,tsuchiya,trossbach,trivitt,trippi,trippensee,trimbach,trillo,triller,trible,tribby,trevisan,tresch,tramonte,traff,trad,tousey,totaro,torregrosa,torralba,tolly,tofil,tofani,tobiassen,tiogangco,tino,tinnes,tingstrom,tingen,tindol,tifft,tiffee,tiet,thuesen,thruston,throndson,thornsbury,thornes,thiery,thielman,thie,theilen,thede,thate,thane,thalacker,thaden,teuscher,terracina,terell,terada,tepfer,tenneson,temores,temkin,telleria,teaque,tealer,teachey,tavakoli,tauras,taucher,tartaglino,tarpy,tannery,tani,tams,tamlin,tambe,tallis,talamante,takayama,takaki,taibl,taffe,tadesse,tade,tabeling,tabag,szoke,szoc,szala,szady,sysak,sylver,syler,swonger,swiggett,swensson,sweis,sweers,sweene,sweany,sweaney,swartwout,swamy,swales,susman,surman,sundblad,summerset,summerhays,sumerall,sule,sugimoto,subramanian,sturch,stupp,stunkard,stumpp,struiksma,stropes,stromyer,stromquist,strede,strazza,strauf,storniolo,storjohann,stonum,stonier,stonecypher,stoneberger,stollar,stokke,stokan,stoetzel,stoeckel,stockner,stockinger,stockert,stockdill,stobbe,stitzel,stitely,stirgus,stigers,stettner,stettler,sterlin,sterbenz,stemp,stelluti,steinmeyer,steininger,steinauer,steigerwalt,steider,stavrou,staufenberger,stassi,stankus,stanaway,stammer,stakem,staino,stahlnecker,stagnitta,staelens,staal,srsen,sprott,sprigg,sprenkle,sprenkel,spreitzer,spraque,sprandel,sporn,spivak,spira,spiewak,spieth,spiering,sperow,speh,specking,spease,spead,sparger,spanier,spall,sower,southcott,sosna,soran,sookram,sonders,solak,sohr,sohl,sofranko,soderling,sochor,sobon,smutz,smudrick,smithj,smid,slosser,sliker,slenker,sleger,slaby,skousen,skilling,skibinski,skees,skane,skafidas,sivic,sivertsen,sivers,sitra,sito,siracusa,sinicki,simpers,simley,simbeck,silberberg,siever,siegwarth,sidman,siddle,sibbett,shumard,shubrooks,shough,shorb,shoptaw,sholty,shoffstall,shiverdecker,shininger,shimasaki,shifrin,shiffler,sheston,sherr,shere,shepeard,shelquist,sheler,shauf,sharrar,sharpnack,shamsiddeen,shambley,shallenberger,shadler,shaban,sferra,seys,sexauer,sevey,severo,setlak,seta,sesko,sersen,serratore,serdula,senechal,seldomridge,seilhamer,seifer,seidlitz,sehnert,sedam,sebron,seber,sebek,seavers,scullark,scroger,scovill,sciascia,sciarra,schweers,schwarze,schummer,schultes,schuchardt,schuchard,schrieber,schrenk,schreifels,schowalter,schoultz,scholer,schofill,schoff,schnuerer,schnettler,schmitke,schmiege,schloop,schlinger,schlessman,schlesser,schlageter,schiess,schiefer,schiavoni,scherzer,scherich,schechtman,schebel,scharpman,schaich,schaap,scappaticci,scadlock,savocchia,savini,savers,savageau,sauvage,sause,sauerwein,sary,sarwary,sarnicola,santone,santoli,santalucia,santacruce,sansoucie,sankoff,sanes,sandri,sanderman,sammartano,salmonson,salmela,salmans,sallaz,salis,sakuma,sakowski,sajdak,sahm,sagredo,safrit,sackey,sabio,sabino,rybolt,ruzzo,ruthstrom,ruta,russin,russak,rusko,ruskin,rusiecki,ruscher,rupar,rumberger,rullan,ruliffson,ruhlman,rufenacht,ruelle,rudisell,rudi,rucci,rublee,ruberto,rubeck,rowett,rottinghaus,roton,rothgeb,rothgaber,rothermich,rostek,rossini,roskelley,rosing,rosi,rosewell,rosberg,roon,ronin,romesburg,romelus,rolley,rollerson,rollefson,rolins,rolens,rois,rohrig,rohrbacher,rohland,rohen,rogness,roes,roering,roehrick,roebke,rodregez,rodabaugh,rockingham,roblee,robel,roadcap,rizzolo,riviezzo,rivest,riveron,risto,rissler,rippentrop,ripka,rinn,ringuette,ringering,rindone,rindels,rieffer,riedman,riede,riecke,riebow,riddlebarger,rhome,rhodd,rhatigan,rhame,reyers,rewitzer,revalee,retzer,rettinger,reschke,requa,reper,reopell,renzelman,renne,renker,renk,renicker,rendina,rendel,remund,remmele,remiasz,remaklus,remak,reitsma,reitmeier,reiswig,reishus,reining,reim,reidinger,reick,reiche,regans,reffett,reesor,reekie,redpath,redditt,rechtzigel,recht,rearden,raynoso,raxter,ratkowski,rasulo,rassmussen,rassel,raser,rappleye,rappe,randrup,randleman,ramson,rampey,radziewicz,quirarte,quintyne,quickel,quattrini,quakenbush,quaile,pytel,pushaw,pusch,purslow,punzo,pullam,pugmire,puello,przekop,pruss,pruiett,provow,prophete,procaccini,pritz,prillaman,priess,pretlow,prestia,presha,prescod,preast,praytor,prashad,praino,pozzi,pottenger,potash,porada,popplewell,ponzo,ponter,pommier,polland,polidori,polasky,pola,poisso,poire,pofahl,podolsky,podell,plueger,plowe,plotz,plotnik,ploch,pliska,plessner,plaut,platzer,plake,pizzino,pirog,piquette,pipho,pioche,pintos,pinkert,pinet,pilkerton,pilch,pilarz,pignataro,piermatteo,picozzi,pickler,pickette,pichler,philogene,phare,phang,pfrogner,pfisterer,pettinelli,petruzzi,petrovic,petretti,petermeier,pestone,pesterfield,pessin,pesch,persky,perruzza,perrott,perritt,perretti,perrera,peroutka,peroni,peron,peret,perdew,perazzo,peppe,peno,penberthy,penagos,peles,pelech,peiper,peight,pefferman,peddie,peckenpaugh,pean,payen,pavloski,pavlica,paullin,patteson,passon,passey,passalacqua,pasquini,paskel,partch,parriott,parrella,parraz,parmely,parizo,papelian,papasergi,pantojz,panto,panich,panchal,palys,pallone,palinski,pali,palevic,pagels,paciorek,pacho,pacella,paar,ozbun,overweg,overholser,ovalles,outcalt,otterbein,otta,ostergren,osher,osbon,orzech,orwick,orrico,oropesa,ormes,orillion,onorati,onnen,omary,olding,okonski,okimoto,ohlrich,ohayon,oguin,ogley,oftedahl,offen,ofallon,oeltjen,odam,ockmond,ockimey,obermeyer,oberdorf,obanner,oballe,oard,oakden,nyhan,nydam,numan,noyer,notte,nothstein,notestine,noser,nork,nolde,nishihara,nishi,nikolic,nihart,nietupski,niesen,niehus,nidiffer,nicoulin,nicolaysen,nicklow,nickl,nickeson,nichter,nicholl,ngyun,newsham,newmann,neveux,neuzil,neumayer,netland,nessen,nesheim,nelli,nelke,necochea,nazari,navorro,navarez,navan,natter,natt,nater,nasta,narvaiz,nardelli,napp,nakahara,nairn,nagg,nager,nagano,nafziger,naffziger,nadelson,muzzillo,murri,murrey,murgia,murcia,muno,munier,mulqueen,mulliniks,mulkins,mulik,muhs,muffley,moynahan,mounger,mottley,motil,moseman,moseby,mosakowski,mortell,morrisroe,morrero,mormino,morland,morger,morgenthaler,moren,morelle,morawski,morasca,morang,morand,moog,montney,montera,montee,montane,montagne,mons,monohan,monnett,monkhouse,moncure,momphard,molyneaux,molles,mollenkopf,molette,mohs,mohmand,mohlke,moessner,moers,mockus,moccio,mlinar,mizzelle,mittler,mitri,mitchusson,mitchen,mistrot,mistler,misch,miriello,minkin,mininger,minerich,minehart,minderman,minden,minahan,milonas,millon,millholland,milleson,millerbernd,millage,militante,milionis,milhoan,mildenberger,milbury,mikolajczak,miklos,mikkola,migneault,mifsud,mietus,mieszala,mielnicki,midy,michon,michioka,micheau,michaeli,micali,methe,metallo,messler,mesch,merow,meroney,mergenthaler,meres,menuey,menousek,menning,menn,menghini,mendia,memmer,melot,mellenthin,melland,meland,meixner,meisenheimer,meineke,meinders,mehrens,mehlig,meglio,medsker,medero,mederios,meabon,mcwright,mcright,mcreath,mcrary,mcquirter,mcquerry,mcquary,mcphie,mcnurlen,mcnelley,mcnee,mcnairy,mcmanamy,mcmahen,mckowen,mckiver,mckinlay,mckearin,mcirvin,mcintrye,mchorse,mchaffie,mcgroarty,mcgoff,mcgivern,mceniry,mcelhiney,mcdiarmid,mccullars,mccubbins,mccrimon,mccovery,mccommons,mcclour,mccarrick,mccarey,mccallen,mcbrien,mcarthy,mayone,maybin,maxam,maurais,maughn,matzek,matts,matin,mathre,mathia,mateen,matava,masso,massar,massanet,masingale,mascaro,marthaler,martes,marso,marshman,marsalis,marrano,marolt,marold,markins,margulis,mardirosian,marchiano,marchak,marandola,marana,manues,mante,mansukhani,mansi,mannan,maniccia,mangine,manery,mandigo,mancell,mamo,malstrom,malouf,malenfant,maldenado,malandruccolo,malak,malabanan,makino,maisonave,mainord,maino,mainard,maillard,mahmud,mahdi,mahapatra,mahaley,mahaffy,magouirk,maglaras,magat,maga,maffia,madrazo,madrano,maditz,mackert,mackellar,mackell,macht,macchia,maccarthy,maahs,lytal,luzar,luzader,lutjen,lunger,lunan,luma,lukins,luhmann,luers,ludvigsen,ludlam,ludemann,luchini,lucente,lubrano,lubow,luber,lubeck,lowing,loven,loup,louge,losco,lorts,lormand,lorenzetti,longford,longden,longbrake,lokhmatov,loge,loeven,loeser,locey,locatelli,litka,lista,lisonbee,lisenbee,liscano,liranzo,liquori,liptrot,lionetti,linscomb,linkovich,linington,lingefelt,lindler,lindig,lindall,lincks,linander,linan,limburg,limbrick,limbach,likos,lighthall,liford,lietzke,liebe,liddicoat,lickley,lichter,liapis,lezo,lewan,levitz,levesgue,leverson,levander,leuthauser,letbetter,lesuer,lesmeister,lesly,lerer,leppanen,lepinski,lenherr,lembrick,lelonek,leisten,leiss,leins,leingang,leinberger,leinbach,leikam,leidig,lehtonen,lehnert,lehew,legier,lefchik,lecy,leconte,lecher,lebrecht,leaper,lawter,lawrenz,lavy,laur,lauderbaugh,lauden,laudato,latting,latsko,latini,lassere,lasseigne,laspina,laso,laslie,laskowitz,laske,lasenby,lascola,lariosa,larcade,lapete,laperouse,lanuza,lanting,lantagne,lansdale,lanphier,langmaid,langella,lanese,landrus,lampros,lamens,laizure,laitinen,laigle,lahm,lagueux,lagorio,lagomarsino,lagasca,lagana,lafont,laflen,lafavor,lafarge,laducer,ladnier,ladesma,lacognata,lackland,lacerte,labuff,laborin,labine,labauve,kuzio,kusterer,kussman,kusel,kusch,kurutz,kurdyla,kupka,kunzler,kunsman,kuni,kuney,kunc,kulish,kuliga,kulaga,kuilan,kuhre,kuhnke,kuemmerle,kueker,kudla,kudelka,kubinski,kubicki,kubal,krzyzanowski,krupicka,krumwiede,krumme,kropidlowski,krokos,kroell,kritzer,kribs,kreitlow,kreisher,kraynak,krass,kranzler,kramb,kozyra,kozicki,kovalik,kovalchik,kovacevic,kotula,kotrba,koteles,kosowski,koskela,kosiba,koscinski,kosch,korab,kopple,kopper,koppelman,koppel,konwinski,kolosky,koloski,kolinsky,kolinski,kolbeck,kolasa,koepf,koda,kochevar,kochert,kobs,knust,knueppel,knoy,knieriem,knier,kneller,knappert,klitz,klintworth,klinkenberg,klinck,kleindienst,kleeb,klecker,kjellberg,kitsmiller,kisor,kisiel,kise,kirbo,kinzle,kingsford,kingry,kimpton,kimel,killmon,killick,kilgallon,kilcher,kihn,kiggins,kiecker,kher,khaleel,keziah,kettell,ketchen,keshishian,kersting,kersch,kerins,kercher,kenefick,kemph,kempa,kelsheimer,kelln,kellenberger,kekahuna,keisling,keirnan,keimig,kehn,keal,kaupp,kaufhold,kauffmann,katzenberg,katona,kaszynski,kaszuba,kassebaum,kasa,kartye,kartchner,karstens,karpinsky,karmely,karel,karasek,kapral,kaper,kanelos,kanahele,kampmann,kampe,kalp,kallus,kallevig,kallen,kaliszewski,kaleohano,kalchthaler,kalama,kalahiki,kaili,kahawai,kagey,justiss,jurkowski,jurgensmeyer,juilfs,jopling,jondahl,jomes,joice,johannessen,joeckel,jezewski,jezek,jeswald,jervey,jeppsen,jenniges,jennett,jemmott,jeffs,jaurequi,janisch,janick,jacek,jacaruso,iwanicki,ishihara,isenberger,isbister,iruegas,inzer,inyart,inscore,innocenti,inglish,infantolino,indovina,inaba,imondi,imdieke,imbert,illes,iarocci,iannucci,huver,hutley,husser,husmann,hupf,huntsberger,hunnewell,hullum,huit,huish,hughson,huft,hufstetler,hueser,hudnell,hovden,housen,houghtling,hossack,hoshaw,horsford,horry,hornbacher,hoppenstedt,hopkinson,honza,homann,holzmeister,holycross,holverson,holtzlander,holroyd,holmlund,holderness,holderfield,holck,hojnacki,hohlfeld,hohenberger,hoganson,hogancamp,hoffses,hoerauf,hoell,hoefert,hodum,hoder,hockenbury,hoage,hisserich,hislip,hirons,hippensteel,hippen,hinkston,hindes,hinchcliff,himmel,hillberry,hildring,hiester,hiefnar,hibberd,hibben,heyliger,heyl,heyes,hevia,hettrick,hert,hersha,hernandz,herkel,herber,henscheid,hennesy,henly,henegan,henebry,hench,hemsath,hemm,hemken,hemann,heltzel,hellriegel,hejny,heinl,heinke,heidinger,hegeman,hefferan,hedglin,hebdon,hearnen,heape,heagy,headings,headd,hazelbaker,havlick,hauschildt,haury,hassenfritz,hasenbeck,haseltine,hartstein,hartry,hartnell,harston,harpool,harmen,hardister,hardey,harders,harbolt,harbinson,haraway,haque,hansmann,hanser,hansch,hansberry,hankel,hanigan,haneline,hampe,hamons,hammerstone,hammerle,hamme,hammargren,hamelton,hamberger,hamasaki,halprin,halman,hallihan,haldane,haifley,hages,hagadorn,hadwin,habicht,habermehl,gyles,gutzman,gutekunst,gustason,gusewelle,gurnsey,gurnee,gunterman,gumina,gulliver,gulbrandson,guiterez,guerino,guedry,gucwa,guardarrama,guagliano,guadagno,grulke,groote,groody,groft,groeneweg,grochow,grippe,grimstead,griepentrog,greenfeld,greenaway,grebe,graziosi,graw,gravina,grassie,granzow,grandjean,granby,gramacy,gozalez,goyer,gotch,gosden,gorny,gormont,goodgion,gonya,gonnerman,gompert,golish,goligoski,goldmann,goike,goetze,godeaux,glaza,glassel,glaspy,glander,giumarro,gitelman,gisondi,gismondi,girvan,girten,gironda,giovinco,ginkel,gilster,giesy,gierman,giddins,giardini,gianino,ghea,geurin,gett,getson,gerrero,germond,gentsy,genta,gennette,genito,genis,gendler,geltz,geiss,gehret,gegenheimer,geffert,geeting,gebel,gavette,gavenda,gaumond,gaudioso,gatzke,gatza,gattshall,gaton,gatchel,gasperi,gaska,gasiorowski,garritson,garrigus,garnier,garnick,gardinier,gardenas,garcy,garate,gandolfi,gamm,gamel,gambel,gallmon,gallemore,gallati,gainous,gainforth,gahring,gaffey,gaebler,gadzinski,gadbury,gabri,gaba,fyke,furtaw,furnas,furcron,funn,funck,fulwood,fulvio,fullmore,fukumoto,fuest,fuery,frymire,frush,frohlich,froedge,frodge,fritzinger,fricker,frericks,frein,freid,freggiaro,fratto,franzi,franciscus,fralix,fowble,fotheringham,foslien,foshie,fortmann,forsey,forkner,foppiano,fontanetta,fonohema,fogler,fockler,fluty,flusche,flud,flori,flenory,fleharty,fleeks,flaxman,fiumara,fitzmorris,finnicum,finkley,fineran,fillhart,filipi,fijal,fieldson,ficarra,festerman,ferryman,ferner,fergason,ferell,fennern,femmer,feldmeier,feeser,feenan,federick,fedak,febbo,feazell,fazzone,fauth,fauset,faurote,faulker,faubion,fatzinger,fasick,fanguy,fambrough,falks,fahl,faaita,exler,ewens,estrado,esten,esteen,esquivez,espejo,esmiol,esguerra,esco,ertz,erspamer,ernstes,erisman,erhard,ereaux,ercanbrack,erbes,epple,entsminger,entriken,enslow,ennett,engquist,englebert,englander,engesser,engert,engeman,enge,enerson,emhoff,emge,elting,ellner,ellenberg,ellenbecker,elio,elfert,elawar,ekstrand,eison,eismont,eisenbrandt,eiseman,eischens,ehrgott,egley,egert,eddlemon,eckerson,eckersley,eckberg,echeverry,eberts,earthman,earnhart,eapen,eachus,dykas,dusi,durning,durdan,dunomes,duncombe,dume,dullen,dullea,dulay,duffett,dubs,dubard,drook,drenth,drahos,dragone,downin,downham,dowis,dowhower,doward,dovalina,dopazo,donson,donnan,dominski,dollarhide,dolinar,dolecki,dolbee,doege,dockus,dobkin,dobias,divoll,diviney,ditter,ditman,dissinger,dismang,dirlam,dinneen,dini,dingwall,diloreto,dilmore,dillaman,dikeman,diiorio,dighton,diffley,dieudonne,dietel,dieringer,diercks,dienhart,diekrager,diefendorf,dicke,dicamillo,dibrito,dibona,dezeeuw,dewhurst,devins,deviney,deupree,detherage,despino,desmith,desjarlais,deshner,desha,desanctis,derring,derousse,derobertis,deridder,derego,derden,deprospero,deprofio,depping,deperro,denty,denoncourt,dencklau,demler,demirchyan,demichiel,demesa,demere,demaggio,delung,deluise,delmoral,delmastro,delmas,delligatti,delle,delasbour,delarme,delargy,delagrange,delafontaine,deist,deiss,deighan,dehoff,degrazia,degman,defosses,deforrest,deeks,decoux,decarolis,debuhr,deberg,debarr,debari,dearmon,deare,deardurff,daywalt,dayer,davoren,davignon,daviau,dauteuil,dauterive,daul,darnley,darakjy,dapice,dannunzio,danison,daniello,damario,dalonzo,dallis,daleske,dalenberg,daiz,dains,daines,dagnese,dady,dadey,czyzewski,czapor,czaplewski,czajka,cyganiewicz,cuttino,cutrona,cussins,cusanelli,cuperus,cundy,cumiskey,cumins,cuizon,cuffia,cuffe,cuffari,cuccaro,cubie,cryder,cruson,crounse,cromedy,cring,creer,credeur,crea,cozort,cozine,cowee,cowdery,couser,courtway,courington,cotman,costlow,costell,corton,corsaro,corrieri,corrick,corradini,coron,coren,corbi,corado,copus,coppenger,cooperwood,coontz,coonce,contrera,connealy,conell,comtois,compere,commins,commings,comegys,colyar,colo,collister,collick,collella,coler,colborn,cohran,cogbill,coffen,cocuzzo,clynes,closter,clipp,clingingsmith,clemence,clayman,classon,clas,clarey,clague,ciubal,citrino,citarella,cirone,cipponeri,cindrich,cimo,ciliberto,cichowski,ciccarello,cicala,chura,chubbuck,chronis,christlieb,chizek,chittester,chiquito,chimento,childree,chianese,chevrette,checo,chastang,chargualaf,chapmon,chantry,chahal,chafetz,cezar,ceruantes,cerrillo,cerrano,cerecedes,cerami,cegielski,cavallero,catinella,cassata,caslin,casano,casacchia,caruth,cartrette,carten,carodine,carnrike,carnall,carmicle,carlan,carlacci,caris,cariaga,cardine,cardimino,cardani,carbonara,capua,capponi,cappellano,caporale,canupp,cantrel,cantone,canterberry,cannizzo,cannan,canelo,caneer,candill,candee,campbel,caminero,camble,caluya,callicott,calk,caito,caffie,caden,cadavid,cacy,cachu,cachola,cabreja,cabiles,cabada,caamano,byran,byon,buyck,bussman,bussie,bushner,burston,burnison,burkman,burkhammer,bures,burdeshaw,bumpass,bullinger,bullers,bulgrin,bugay,budak,buczynski,buckendorf,buccieri,bubrig,brynteson,brunz,brunmeier,brunkow,brunetto,brunelli,brumwell,bruggman,brucki,brucculeri,brozovich,browing,brotman,brocker,broadstreet,brix,britson,brinck,brimmage,brierre,bridenstine,brezenski,brezee,brevik,brentlinger,brentley,breidenbach,breckel,brech,brazzle,braughton,brauch,brattin,brattain,branhan,branford,braner,brander,braly,braegelmann,brabec,boyt,boyack,bowren,bovian,boughan,botton,botner,bosques,borzea,borre,boron,bornhorst,borgstrom,borella,bontempo,bonniwell,bonnes,bonillo,bonano,bolek,bohol,bohaty,boffa,boetcher,boesen,boepple,boehler,boedecker,boeckx,bodi,boal,bloodsworth,bloodgood,blome,blockett,blixt,blanchett,blackhurst,blackaby,bjornberg,bitzer,bittenbender,bitler,birchall,binnicker,binggeli,billett,bilberry,biglow,bierly,bielby,biegel,berzas,berte,bertagnolli,berreth,bernhart,bergum,berentson,berdy,bercegeay,bentle,bentivegna,bentham,benscoter,benns,bennick,benjamine,beneze,benett,beneke,bendure,bendix,bendick,benauides,belman,bellus,bellott,bellefleur,bellas,beljan,belgard,beith,beinlich,beierle,behme,beevers,beermann,beeching,bedward,bedrosian,bedner,bedeker,bechel,becera,beaubrun,beardmore,bealmear,bazin,bazer,baumhoer,baumgarner,bauknecht,battson,battiest,basulto,baster,basques,basista,basiliere,bashi,barzey,barz,bartus,bartucca,bartek,barrero,barreca,barnoski,barndt,barklow,baribeau,barette,bares,barentine,bareilles,barbre,barberi,barbagelata,baraw,baratto,baranoski,baptise,bankson,bankey,bankard,banik,baltzley,ballen,balkey,balius,balderston,bakula,bakalar,baffuto,baerga,badoni,backous,bachtel,bachrach,baccari,babine,babilonia,baar,azbill,azad,aycox,ayalla,avolio,austerberry,aughtry,aufderheide,auch,attanasio,athayde,atcher,asselta,aslin,aslam,ashwood,ashraf,ashbacher,asbridge,asakura,arzaga,arriaza,arrez,arrequin,arrants,armiger,armenteros,armbrister,arko,argumedo,arguijo,ardolino,arcia,arbizo,aravjo,aper,anzaldo,antu,antrikin,antonetty,antinoro,anthon,antenucci,anstead,annese,ankrum,andreason,andrado,andaverde,anastos,anable,amspoker,amrine,amrein,amorin,amel,ambrosini,alsbrook,alnutt,almasi,allessio,allateef,aldous,alderink,aldaz,akmal,akard,aiton,aites,ainscough,aikey,ahrends,ahlm,aguada,agans,adelmann,addesso,adaway,adamaitis,ackison,abud,abendroth,abdur,abdool,aamodt,zywiec,zwiefelhofer,zwahlen,zunino,zuehl,zmuda,zmolek,zizza,ziska,zinser,zinkievich,zinger,zingarelli,ziesmer,ziegenfuss,ziebol,zettlemoyer,zettel,zervos,zenke,zembower,zelechowski,zelasko,zeise,zeek,zeeb,zarlenga,zarek,zaidi,zahnow,zahnke,zaharis,zacate,zabrocki,zaborac,yurchak,yuengling,younie,youngers,youell,yott,yoshino,yorks,yordy,yochem,yerico,yerdon,yeiser,yearous,yearick,yeaney,ybarro,yasutake,yasin,yanke,yanish,yanik,yamazaki,yamat,yaggi,ximenez,wyzard,wynder,wyly,wykle,wutzke,wuori,wuertz,wuebker,wrightsel,worobel,worlie,worford,worek,woolson,woodrome,woodly,woodling,wontor,wondra,woltemath,wollmer,wolinski,wolfert,wojtanik,wojtak,wohlfarth,woeste,wobbleton,witz,wittmeyer,witchey,wisotzkey,wisnewski,wisman,wirch,wippert,wineberg,wimpee,wilusz,wiltsey,willig,williar,willers,willadsen,wildhaber,wilday,wigham,wiewel,wieting,wietbrock,wiesel,wiesehan,wiersema,wiegert,widney,widmark,wickson,wickings,wichern,whtie,whittie,whitlinger,whitfill,whitebread,whispell,whetten,wheeley,wheeles,wheelen,whatcott,weyland,weter,westrup,westphalen,westly,westland,wessler,wesolick,wesler,wesche,werry,wero,wernecke,werkhoven,wellspeak,wellings,welford,welander,weissgerber,weisheit,weins,weill,weigner,wehrmann,wehrley,wehmeier,wege,weers,weavers,watring,wassum,wassman,wassil,washabaugh,wascher,warth,warbington,wanca,wammack,wamboldt,walterman,walkington,walkenhorst,walinski,wakley,wagg,wadell,vuckovich,voogd,voller,vokes,vogle,vogelsberg,vodicka,vissering,vipond,vincik,villalona,vickerman,vettel,veteto,vesperman,vesco,vertucci,versaw,verba,ventris,venecia,vendela,venanzi,veldhuizen,vehrs,vaughen,vasilopoulos,vascocu,varvel,varno,varlas,varland,vario,vareschi,vanwyhe,vanweelden,vansciver,vannaman,vanluven,vanloo,vanlaningham,vankomen,vanhout,vanhampler,vangorp,vangorden,vanella,vandresar,vandis,vandeyacht,vandewerker,vandevsen,vanderwall,vandercook,vanderberg,vanbergen,valko,valesquez,valeriano,valen,vachula,vacha,uzee,uselman,urizar,urion,urben,upthegrove,unzicker,unsell,unick,umscheid,umin,umanzor,ullo,ulicki,uhlir,uddin,tytler,tymeson,tyger,twisdale,twedell,tweddle,turrey,tures,turell,tupa,tuitt,tuberville,tryner,trumpower,trumbore,troglen,troff,troesch,trivisonno,tritto,tritten,tritle,trippany,tringali,tretheway,treon,trejos,tregoning,treffert,traycheff,travali,trauth,trauernicht,transou,trane,trana,toves,tosta,torp,tornquist,tornes,torchio,toor,tooks,tonks,tomblinson,tomala,tollinchi,tolles,tokich,tofte,todman,titze,timpone,tillema,tienken,tiblier,thyberg,thursby,thurrell,thurm,thruman,thorsted,thorley,thomer,thoen,thissen,theimer,thayn,thanpaeng,thammavongsa,thalman,texiera,texidor,teverbaugh,teska,ternullo,teplica,tepe,teno,tenholder,tenbusch,tenbrink,temby,tejedor,teitsworth,teichmann,tehan,tegtmeyer,tees,teem,tays,taubert,tauares,taschler,tartamella,tarquinio,tarbutton,tappendorf,tapija,tansil,tannahill,tamondong,talahytewa,takashima,taecker,tabora,tabin,tabbert,szymkowski,szymanowski,syversen,syrett,synnott,sydnes,swimm,sweney,swearegene,swartzel,swanstrom,svedin,suryan,supplice,supnet,suoboda,sundby,sumaya,sumabat,sulzen,sukovaty,sukhu,sugerman,sugalski,sudweeks,sudbeck,sucharski,stutheit,stumfoll,stuffle,struyk,strutz,strumpf,strowbridge,strothman,strojny,strohschein,stroffolino,stribble,strevel,strenke,stremming,strehle,stranak,stram,stracke,stoudamire,storks,stopp,stonebreaker,stolt,stoica,stofer,stockham,stockfisch,stjuste,stiteler,stiman,stillions,stillabower,stierle,sterlace,sterk,stepps,stenquist,stenner,stellman,steines,steinbaugh,steinbacher,steiling,steidel,steffee,stavinoha,staver,stastny,stasiuk,starrick,starliper,starlin,staniford,staner,standre,standefer,standafer,stanczyk,stallsmith,stagliano,staehle,staebler,stady,stadtmiller,squyres,spurbeck,sprunk,spranger,spoonamore,spoden,spilde,spezio,speros,sperandio,specchio,spearin,spayer,spallina,spadafino,sovie,sotello,sortor,sortino,soros,sorola,sorbello,sonner,sonday,somes,soloway,soens,soellner,soderblom,sobin,sniezek,sneary,smyly,smutnick,smoots,smoldt,smitz,smitreski,smallen,smades,slunaker,sluka,slown,slovick,slocomb,slinger,slife,sleeter,slanker,skufca,skubis,skrocki,skov,skjei,skilton,skarke,skalka,skalak,skaff,sixkiller,sitze,siter,sisko,sirman,sirls,sinotte,sinon,sincock,sincebaugh,simmoms,similien,silvius,silton,silloway,sikkema,sieracki,sienko,siemon,siemer,siefker,sieberg,siebens,siebe,sicurella,sicola,sickle,shumock,shumiloff,shuffstall,shuemaker,shuart,shroff,shreeve,shostak,shortes,shorr,shivley,shintaku,shindo,shimomura,shiigi,sherow,sherburn,shepps,shenefield,shelvin,shelstad,shelp,sheild,sheaman,shaulis,sharrer,sharps,sharpes,shappy,shapero,shanor,shandy,seyller,severn,sessom,sesley,servidio,serrin,sero,septon,septer,sennott,sengstock,senff,senese,semprini,semone,sembrat,selva,sella,selbig,seiner,seif,seidt,sehrt,seemann,seelbinder,sedlay,sebert,seaholm,seacord,seaburg,scungio,scroggie,scritchfield,scrimpsher,scrabeck,scorca,scobey,scivally,schwulst,schwinn,schwieson,schwery,schweppe,schwartzenbur,schurz,schumm,schulenburg,schuff,schuerholz,schryer,schrager,schorsch,schonhardt,schoenfelder,schoeck,schoeb,schnitzler,schnick,schnautz,schmig,schmelter,schmeichel,schluneger,schlosberg,schlobohm,schlenz,schlembach,schleisman,schleining,schleiff,schleider,schink,schilz,schiffler,schiavi,scheuer,schemonia,scheman,schelb,schaul,schaufelberge,scharer,schardt,scharbach,schabacker,scee,scavone,scarth,scarfone,scalese,sayne,sayed,savitz,satterlund,sattazahn,satow,sastre,sarr,sarjeant,sarff,sardella,santoya,santoni,santai,sankowski,sanft,sandow,sandoe,sandhaus,sandefer,sampey,samperi,sammarco,samia,samek,samay,samaan,salvadore,saltness,salsgiver,saller,salaz,salano,sakal,saka,saintlouis,saile,sahota,saggese,sagastume,sadri,sadak,sachez,saalfrank,saal,saadeh,rynn,ryley,ryle,rygg,rybarczyk,ruzich,ruyter,ruvo,rupel,ruopp,rundlett,runde,rundall,runck,rukavina,ruggiano,rufi,ruef,rubright,rubbo,rowbottom,rotner,rotman,rothweiler,rothlisberger,rosseau,rossean,rossa,roso,rosiek,roshia,rosenkrans,rosener,rosencrantz,rosencrans,rosello,roques,rookstool,rondo,romasanta,romack,rokus,rohweder,roethler,roediger,rodwell,rodrigus,rodenbeck,rodefer,rodarmel,rockman,rockholt,rochow,roches,roblin,roblez,roble,robers,roat,rizza,rizvi,rizk,rixie,riveiro,rius,ritschard,ritrovato,risi,rishe,rippon,rinks,ringley,ringgenberg,ringeisen,rimando,rilley,rijos,rieks,rieken,riechman,riddley,ricord,rickabaugh,richmeier,richesin,reyolds,rexach,requena,reppucci,reposa,renzulli,renter,remondini,reither,reisig,reifsnider,reifer,reibsome,reibert,rehor,rehmann,reedus,redshaw,reczek,recupero,recor,reckard,recher,realbuto,razer,rayman,raycraft,rayas,rawle,raviscioni,ravetto,ravenelle,rauth,raup,rattliff,rattley,rathfon,rataj,rasnic,rappleyea,rapaport,ransford,rann,rampersad,ramis,ramcharan,rainha,rainforth,ragans,ragains,rafidi,raffety,raducha,radsky,radler,radatz,raczkowski,rabenold,quraishi,quinerly,quercia,quarnstrom,pusser,puppo,pullan,pulis,pugel,puca,pruna,prowant,provines,pronk,prinkleton,prindall,primas,priesmeyer,pridgett,prevento,preti,presser,presnall,preseren,presas,presa,prchal,prattis,pratillo,praska,prak,powis,powderly,postlewait,postle,posch,porteus,porraz,popwell,popoff,poplaski,poniatoski,pollina,polle,polhill,poletti,polaski,pokorney,pointdexter,poinsette,ploszaj,plitt,pletz,pletsch,plemel,pleitez,playford,plaxco,platek,plambeck,plagens,placido,pisarski,pinuelas,pinnette,pinick,pinell,pinciaro,pinal,pilz,piltz,pillion,pilkinton,pikul,piepenburg,piening,piehler,piedrahita,piechocki,picknell,pickelsimer,pich,picariello,phoeuk,phillipson,philbert,pherigo,phelka,peverini,petrash,petramale,petraglia,pery,personius,perrington,perrill,perpall,perot,perman,peragine,pentland,pennycuff,penninger,pennachio,pendexter,penalver,pelzel,pelter,pelow,pelo,peli,peinado,pedley,pecue,pecore,pechar,peairs,paynes,payano,pawelk,pavlock,pavlich,pavich,pavek,pautler,paulik,patmore,patella,patee,patalano,passini,passeri,paskell,parrigan,parmar,parayno,paparelli,pantuso,pante,panico,panduro,panagos,pama,palmo,pallotta,paling,palamino,pake,pajtas,pailthorpe,pahler,pagon,paglinawan,pagley,paget,paetz,paet,padley,pacleb,pachelo,paccione,pabey,ozley,ozimek,ozawa,owney,outram,ouillette,oudekerk,ostrosky,ostermiller,ostermann,osterloh,osterfeld,ossenfort,osoria,oshell,orsino,orscheln,orrison,ororke,orellano,orejuela,ordoyne,opsahl,opland,onofre,onaga,omahony,olszowka,olshan,ollig,oliff,olien,olexy,oldridge,oldfather,olalde,okun,okumoto,oktavec,okin,ohme,ohlemacher,ohanesian,odneal,odgers,oderkirk,odden,ocain,obradovich,oakey,nussey,nunziato,nunoz,nunnenkamp,nuncio,noviello,novacek,nothstine,northum,norsen,norlander,norkus,norgaard,norena,nored,nobrega,niziolek,ninnemann,nievas,nieratko,nieng,niedermeyer,niedermaier,nicolls,newham,newcome,newberger,nevills,nevens,nevel,neumiller,netti,nessler,neria,nemet,nelon,nellon,neller,neisen,neilly,neifer,neid,neering,neehouse,neef,needler,nebergall,nealis,naumoff,naufzinger,narum,narro,narramore,naraine,napps,nansteel,namisnak,namanny,nallie,nakhle,naito,naccari,nabb,myracle,myhand,mwakitwile,muzzy,muscolino,musco,muscente,muscat,muscara,musacchia,musa,murrish,murfin,muray,munnelly,munley,munivez,mundine,mundahl,munari,mullennex,mullendore,mulkhey,mulinix,mulders,muhl,muenchow,muellner,mudget,mudger,muckenfuss,muchler,mozena,movius,mouldin,motola,mosseri,mossa,moselle,mory,morsell,morrish,morles,morie,morguson,moresco,morck,moppin,moosman,montuori,montono,montogomery,montis,monterio,monter,monsalve,mongomery,mongar,mondello,moncivais,monard,monagan,molt,mollenhauer,moldrem,moldonado,molano,mokler,moisant,moilanen,mohrman,mohamad,moger,mogel,modine,modin,modic,modha,mlynek,miya,mittiga,mittan,mitcheltree,misfeldt,misener,mirchandani,miralles,miotke,miosky,mintey,mins,minassian,minar,mimis,milon,milloy,millison,milito,milfort,milbradt,mikulich,mikos,miklas,mihelcic,migliorisi,migliori,miesch,midura,miclette,michela,micale,mezey,mews,mewes,mettert,mesker,mesich,mesecher,merthie,mersman,mersereau,merrithew,merriott,merring,merenda,merchen,mercardo,merati,mentzel,mentis,mentel,menotti,meno,mengle,mendolia,mellick,mellett,melichar,melhorn,melendres,melchiorre,meitzler,mehtani,mehrtens,meditz,medeiras,meckes,mcteer,mctee,mcparland,mcniell,mcnealey,mcmanaway,mcleon,mclay,mclavrin,mcklveen,mckinzey,mcken,mckeand,mckale,mcilwraith,mcilroy,mcgreal,mcgougan,mcgettigan,mcgarey,mcfeeters,mcelhany,mcdaris,mccomis,mccomber,mccolm,mccollins,mccollin,mccollam,mccoach,mcclory,mcclennon,mccathern,mccarthey,mccarson,mccarrel,mccargar,mccandles,mccamish,mccally,mccage,mcbrearty,mcaneny,mcanallen,mcalarney,mcaferty,mazzo,mazy,mazurowski,mazique,mayoras,mayden,maxberry,mauller,matusiak,mattsen,matthey,matkins,mathiasen,mathe,mateus,matalka,masullo,massay,mashak,mascroft,martinex,martenson,marsiglia,marsella,maroudas,marotte,marner,markes,maret,mareno,marean,marcinkiewicz,marchel,marasigan,manzueta,manzanilla,manternach,manring,manquero,manoni,manne,mankowski,manjarres,mangen,mangat,mandonado,mandia,mancias,manbeck,mamros,maltez,mallia,mallar,malla,malen,malaspina,malahan,malagisi,malachowski,makowsky,makinen,makepeace,majkowski,majid,majercin,maisey,mainguy,mailliard,maignan,mahlman,maha,magsamen,magpusao,magnano,magley,magedanz,magarelli,magaddino,maenner,madnick,maddrey,madaffari,macnaughton,macmullen,macksey,macknight,macki,macisaac,maciejczyk,maciag,machenry,machamer,macguire,macdaniel,maccormack,maccabe,mabbott,mabb,lynott,lycan,lutwin,luscombe,lusco,lusardi,luria,lunetta,lundsford,lumas,luisi,luevanos,lueckenhoff,ludgate,ludd,lucherini,lubbs,lozado,lourens,lounsberry,loughrey,loughary,lotton,losser,loshbaugh,loseke,loscalzo,lortz,loperena,loots,loosle,looman,longstaff,longobardi,longbottom,lomay,lomasney,lohrmann,lohmiller,logalbo,loetz,loeffel,lodwick,lodrigue,lockrem,llera,llarena,littrel,littmann,lisser,lippa,lipner,linnemann,lingg,lindemuth,lindeen,lillig,likins,lieurance,liesmann,liesman,liendo,lickert,lichliter,leyvas,leyrer,lewy,leubner,lesslie,lesnick,lesmerises,lerno,lequire,lepera,lepard,lenske,leneau,lempka,lemmen,lemm,lemere,leinhart,leichner,leicher,leibman,lehmberg,leggins,lebeda,leavengood,leanard,lazaroff,laventure,lavant,lauster,laumea,latigo,lasota,lashure,lasecki,lascurain,lartigue,larouche,lappe,laplaunt,laplace,lanum,lansdell,lanpher,lanoie,lankard,laniado,langowski,langhorn,langfield,langfeldt,landt,landerman,landavazo,lampo,lampke,lamper,lamery,lambey,lamadrid,lallemand,laisure,laigo,laguer,lagerman,lageman,lagares,lacosse,lachappelle,laborn,labonne,kuzia,kutt,kutil,kurylo,kurowski,kuriger,kupcho,kulzer,kulesa,kules,kuhs,kuhne,krutz,krus,krupka,kronberg,kromka,kroese,krizek,krivanek,kringel,kreiss,kratofil,krapp,krakowsky,kracke,kozlow,kowald,kover,kovaleski,kothakota,kosten,koskinen,kositzke,korff,korbar,kopplin,koplin,koos,konyn,konczak,komp,komo,kolber,kolash,kolakowski,kohm,kogen,koestner,koegler,kodama,kocik,kochheiser,kobler,kobara,knezevich,kneifl,knapchuck,knabb,klugman,klosner,klingel,klimesh,klice,kley,kleppe,klemke,kleinmann,kleinhans,kleinberg,kleffner,kleckley,klase,kisto,kissick,kisselburg,kirschman,kirks,kirkner,kirkey,kirchman,kinville,kinnunen,kimmey,kimmerle,kimbley,kilty,kilts,killmeyer,killilea,killay,kiest,kierce,kiepert,kielman,khalid,kewal,keszler,kesson,kesich,kerwood,kerksiek,kerkhoff,kerbo,keranen,keomuangtai,kenter,kennelley,keniry,kendzierski,kempner,kemmis,kemerling,kelsay,kelchner,kela,keithly,keipe,kegg,keer,keahey,kaywood,kayes,kawahara,kasuboski,kastendieck,kassin,kasprzyk,karraker,karnofski,karman,karger,karge,karella,karbowski,kapphahn,kannel,kamrath,kaminer,kamansky,kalua,kaltz,kalpakoff,kalkbrenner,kaku,kaib,kaehler,kackley,kaber,justo,juris,jurich,jurgenson,jurez,junor,juniel,juncker,jugo,jubert,jowell,jovanovic,joosten,joncas,joma,johnso,johanns,jodoin,jockers,joans,jinwright,jinenez,jimeson,jerrett,jergens,jerden,jerdee,jepperson,jendras,jeanfrancois,jazwa,jaussi,jaster,jarzombek,jarencio,janocha,jakab,jadlowiec,jacobsma,jach,izaquirre,iwaoka,ivaska,iturbe,israelson,isles,isachsen,isaak,irland,inzerillo,insogna,ingegneri,ingalsbe,inciong,inagaki,icenogle,hyett,hyers,huyck,hutti,hutten,hutnak,hussar,hurrle,hurford,hurde,hupper,hunkin,hunkele,hunke,humann,huhtasaari,hugel,hufft,huegel,hrobsky,hren,hoyles,hovsepian,hovenga,hovatter,houdek,hotze,hossler,hossfeld,hosseini,horten,hort,horr,horgen,horen,hoopii,hoon,hoogland,hontz,honnold,homewood,holway,holtgrewe,holtan,holstrom,holstege,hollway,hollingshed,hollenback,hollard,holberton,hoines,hogeland,hofstad,hoetger,hoen,hoaglund,hirota,hintermeister,hinnen,hinders,hinderer,hinchee,himelfarb,himber,hilzer,hilling,hillers,hillegas,hildinger,hignight,highman,hierholzer,heyde,hettich,hesketh,herzfeld,herzer,hershenson,hershberg,hernando,hermenegildo,hereth,hererra,hereda,herbin,heraty,herard,hepa,henschel,henrichsen,hennes,henneberger,heningburg,henig,hendron,hendericks,hemple,hempe,hemmingsen,hemler,helvie,helmly,helmbrecht,heling,helin,helfrey,helble,helaire,heizman,heisser,heiny,heinbaugh,heidemann,heidema,heiberger,hegel,heerdt,heeg,heefner,heckerman,heckendorf,heavin,headman,haynesworth,haylock,hayakawa,hawksley,haverstick,haut,hausen,hauke,haubold,hattan,hattabaugh,hasstedt,hashem,haselhorst,harrist,harpst,haroldsen,harmison,harkema,harison,hariri,harcus,harcum,harcharik,hanzel,hanvey,hantz,hansche,hansberger,hannig,hanken,hanhardt,hanf,hanauer,hamberlin,halward,halsall,hals,hallquist,hallmon,halk,halbach,halat,hajdas,hainsworth,haik,hahm,hagger,haggar,hader,hadel,haddick,hackmann,haasch,haaf,guzzetta,guzy,gutterman,gutmann,gutkowski,gustine,gursky,gurner,gunsolley,gumpert,gulla,guilmain,guiliani,guier,guers,guerero,guerena,guebara,guadiana,grunder,grothoff,grosland,grosh,groos,grohs,grohmann,groepper,grodi,grizzaffi,grissinger,grippi,grinde,griffee,grether,greninger,greigo,gregorski,greger,grega,greenberger,graza,grattan,grasse,grano,gramby,gradilla,govin,goutremout,goulas,gotay,gosling,gorey,gordner,goossen,goodwater,gonzaga,gonyo,gonska,gongalves,gomillion,gombos,golonka,gollman,goldtrap,goldammer,golas,golab,gola,gogan,goffman,goeppinger,godkin,godette,glore,glomb,glauner,glassey,glasner,gividen,giuffrida,gishal,giovanelli,ginoza,ginns,gindlesperger,gindhart,gillem,gilger,giggey,giebner,gibbson,giacomo,giacolone,giaccone,giacchino,ghere,gherardini,gherardi,gfeller,getts,gerwitz,gervin,gerstle,gerfin,geremia,gercak,gener,gencarelli,gehron,gehrmann,geffers,geery,geater,gawlik,gaudino,garsia,garrahan,garrabrant,garofolo,garigliano,garfinkle,garelick,gardocki,garafola,gappa,gantner,ganther,gangelhoff,gamarra,galstad,gally,gallik,gallier,galimba,gali,galassi,gaige,gadsby,gabbin,gabak,fyall,furney,funez,fulwider,fulson,fukunaga,fujikawa,fugere,fuertes,fuda,fryson,frump,frothingham,froning,froncillo,frohling,froberg,froats,fritchman,frische,friedrichsen,friedmann,friddell,frid,fresch,frentzel,freno,frelow,freimuth,freidel,freehan,freeby,freeburn,fredieu,frederiksen,fredeen,frazell,frayser,fratzke,frattini,franze,franich,francescon,framer,fragman,frack,foxe,fowlston,fosberg,fortna,fornataro,forden,foots,foody,fogt,foglia,fogerty,fogelson,flygare,flowe,flinner,flem,flath,flater,flahaven,flad,fjeld,fitanides,fistler,fishbaugh,firsching,finzel,finical,fingar,filosa,filicetti,filby,fierst,fierra,ficklen,ficher,fersner,ferrufino,ferrucci,fero,ferlenda,ferko,fergerstrom,ferge,fenty,fent,fennimore,fendt,femat,felux,felman,feldhaus,feisthamel,feijoo,feiertag,fehrman,fehl,feezell,feeback,fedigan,fedder,fechner,feary,fayson,faylor,fauteux,faustini,faure,fauci,fauber,fattig,farruggio,farrens,faraci,fantini,fantin,fanno,fannings,faniel,fallaw,falker,falkenhagen,fajen,fahrner,fabel,fabacher,eytcheson,eyster,exford,exel,evetts,evenstad,evanko,euresti,euber,etcitty,estler,essner,essinger,esplain,espenshade,espaillat,escribano,escorcia,errington,errett,errera,erlanger,erenrich,erekson,erber,entinger,ensworth,ensell,enno,ennen,englin,engblom,engberson,encinias,enama,emel,elzie,elsbree,elman,ellebracht,elkan,elfstrom,elerson,eleazer,eleam,eldrige,elcock,einspahr,eike,eidschun,eickman,eichele,eiche,ehlke,eguchi,eggink,edouard,edgehill,eckes,eblin,ebberts,eavenson,earvin,eardley,eagon,eader,dzubak,dylla,dyckman,dwire,dutrow,dutile,dusza,dustman,dusing,duryee,durupan,durtschi,durtsche,durell,dunny,dunnegan,dunken,dumm,dulak,duker,dukelow,dufort,dufilho,duffee,duett,dueck,dudzinski,dudasik,duckwall,duchemin,dubrow,dubis,dubicki,duba,drust,druckman,drinnen,drewett,drewel,dreitzler,dreckman,drappo,draffen,drabant,doyen,dowding,doub,dorson,dorschner,dorrington,dorney,dormaier,dorff,dorcy,donges,donelly,donel,domangue,dols,dollahite,dolese,doldo,doiley,dohrman,dohn,doheny,doceti,dobry,dobrinski,dobey,divincenzo,dischinger,dirusso,dirocco,dipiano,diop,dinitto,dinehart,dimsdale,diminich,dimalanta,dillavou,dilello,difusco,diffey,diffenderfer,diffee,difelice,difabio,dietzman,dieteman,diepenbrock,dieckmann,dicampli,dibari,diazdeleon,diallo,dewitz,dewiel,devoll,devol,devincent,devier,devendorf,devalk,detten,detraglia,dethomas,detemple,desler,desharnais,desanty,derocco,dermer,derks,derito,derhammer,deraney,dequattro,depass,depadua,denyes,denyer,dentino,denlinger,deneal,demory,demopoulos,demontigny,demonte,demeza,delsol,delrosso,delpit,delpapa,delouise,delone,delo,delmundo,delmore,dellapaolera,delfin,delfierro,deleonardis,delenick,delcarlo,delcampo,delcamp,delawyer,delaroca,delaluz,delahunt,delaguardia,dekeyser,dekay,dejaeger,dejackome,dehay,dehass,degraffenried,degenhart,degan,deever,deedrick,deckelbaum,dechico,dececco,decasas,debrock,debona,debeaumont,debarros,debaca,dearmore,deangelus,dealmeida,dawood,davney,daudt,datri,dasgupta,darring,darracott,darcus,daoud,dansbury,dannels,danielski,danehy,dancey,damour,dambra,dalcour,dahlheimer,dadisman,dacunto,dacamara,dabe,cyrulik,cyphert,cwik,cussen,curles,curit,curby,curbo,cunas,cunard,cunanan,cumpton,culcasi,cucinotta,cucco,csubak,cruthird,crumwell,crummitt,crumedy,crouthamel,cronce,cromack,crisafi,crimin,cresto,crescenzo,cremonese,creedon,crankshaw,cozzens,coval,courtwright,courcelle,coupland,counihan,coullard,cotrell,cosgrave,cornelio,corish,cordoua,corbit,coppersmith,coonfield,conville,contrell,contento,conser,conrod,connole,congrove,conery,condray,colver,coltman,colflesh,colcord,colavito,colar,coile,coggan,coenen,codling,coda,cockroft,cockrel,cockerill,cocca,coberley,clouden,clos,clish,clinkscale,clester,clammer,cittadino,citrano,ciresi,cillis,ciccarelli,ciborowski,ciarlo,ciardullo,chritton,chopp,chirco,chilcoat,chevarie,cheslak,chernak,chay,chatterjee,chatten,chatagnier,chastin,chappuis,channey,champlain,chalupsky,chalfin,chaffer,chadek,chadderton,cestone,cestero,cestari,cerros,cermeno,centola,cedrone,cayouette,cavan,cavaliero,casuse,castricone,castoreno,casten,castanada,castagnola,casstevens,cassanova,caspari,casher,cashatt,casco,casassa,casad,carville,cartland,cartegena,carsey,carsen,carrino,carrilo,carpinteyro,carmley,carlston,carlsson,cariddi,caricofe,carel,cardy,carducci,carby,carangelo,capriotti,capria,caprario,capelo,canul,cantua,cantlow,canny,cangialosi,canepa,candland,campolo,campi,camors,camino,camfield,camelo,camarero,camaeho,calvano,calliste,caldarella,calcutt,calcano,caissie,cager,caccamo,cabotage,cabble,byman,buzby,butkowski,bussler,busico,bushovisky,busbin,busard,busalacchi,burtman,burrous,burridge,burrer,burno,burin,burgette,burdock,burdier,burckhard,bunten,bungay,bundage,bumby,bultema,bulinski,bulan,bukhari,buganski,buerkle,buen,buehl,budzynski,buckham,bryk,brydon,bruyere,brunsvold,brunnett,brunker,brunfield,brumble,brue,brozina,brossman,brosey,brookens,broersma,brodrick,brockmeier,brockhouse,brisky,brinkly,brincefield,brighenti,brigante,brieno,briede,bridenbaugh,brickett,breske,brener,brenchley,breitkreutz,breitbart,breister,breining,breighner,breidel,brehon,breheny,breard,breakell,brazill,braymiller,braum,brau,brashaw,bransom,brandolino,brancato,branagan,braff,brading,bracker,brackenbury,bracher,braasch,boylen,boyda,boyanton,bowlus,bowditch,boutot,bouthillette,boursiquot,bourjolly,bouret,boulerice,bouer,bouchillon,bouchie,bottin,boteilho,bosko,bosack,borys,bors,borla,borjon,borghi,borah,booten,boore,bonuz,bonne,bongers,boneta,bonawitz,bonanni,bomer,bollen,bollard,bolla,bolio,boisseau,boies,boiani,bohorquez,boghossian,boespflug,boeser,boehl,boegel,bodrick,bodkins,bodenstein,bodell,bockover,bocci,bobbs,boals,boahn,boadway,bluma,bluett,bloor,blomker,blevens,blethen,bleecker,blayney,blaske,blasetti,blancas,blackner,bjorkquist,bjerk,bizub,bisono,bisges,bisaillon,birr,birnie,bires,birdtail,birdine,bina,billock,billinger,billig,billet,bigwood,bigalk,bielicki,biddick,biccum,biafore,bhagat,beza,beyah,bevier,bevell,beute,betzer,betthauser,bethay,bethard,beshaw,bertholf,bertels,berridge,bernot,bernath,bernabei,berkson,berkovitz,berkich,bergsten,berget,berezny,berdin,beougher,benthin,benhaim,benenati,benejan,bemiss,beloate,bellucci,bellotti,belling,bellido,bellaire,bellafiore,bekins,bekele,beish,behnken,beerly,beddo,becket,becke,bebeau,beauchaine,beaucage,beadling,beacher,bazar,baysmore".split(",")))]; sa=v.concat([function(b){var a,c,e,f,d,g,h,j,i,k,l,m,n,o,p,t;k=[];m=Q(S(b));e=0;for(f=m.length;e<f;e++){o=m[e];if(P(o))break;h=0;for(d=v.length;h<d;h++){g=v[h];j=V(b,o);n=g(j);l=0;for(g=n.length;l<g;l++)if(j=n[l],t=b.slice(j.i,+j.j+1||9E9),t.toLowerCase()!==j.matched_word){i={};for(p in o)a=o[p],-1!==t.indexOf(p)&&(i[p]=a);j.l33t=!0;j.token=t;j.sub=i;t=j;var q=void 0,q=[];for(c in i)a=i[c],q.push(c+" -> "+a);t.sub_display=q.join(", ");k.push(j)}}}return k},function(b){var a,c,e,f,d,g;d=q(b,O);g=[]; e=0;for(f=d.length;e<f;e++)a=d[e],c=[a.i,a.j],a=c[0],c=c[1],g.push({pattern:"digits",i:a,j:c,token:b.slice(a,+c+1||9E9)});return g},function(b){var a,c,e,f,d,g;d=q(b,W);g=[];e=0;for(f=d.length;e<f;e++)a=d[e],c=[a.i,a.j],a=c[0],c=c[1],g.push({pattern:"year",i:a,j:c,token:b.slice(a,+c+1||9E9)});return g},function(b){return M(b).concat(L(b))},function(b){var a,c,e;e=[];for(a=0;a<b.length;){for(c=a+1;;)if(b.slice(c-1,+c+1||9E9),b.charAt(c-1)===b.charAt(c))c+=1;else{2<c-a&&e.push({pattern:"repeat",i:a, j:c-1,token:b.slice(a,c),repeated_char:b.charAt(a)});break}a=c}return e},function(b){var a,c,e,f,d,g,h,j,i,k,l,m,n;j=[];for(d=0;d<b.length;){g=d+1;m=n=i=null;for(l in x)if(k=x[l],e=function(){var c,e,f,h;f=[b.charAt(d),b.charAt(g)];h=[];c=0;for(e=f.length;c<e;c++)a=f[c],h.push(k.indexOf(a));return h}(),f=e[0],e=e[1],-1<f&&-1<e&&(f=e-f,1===f||-1===f)){i=k;n=l;m=f;break}if(i)for(;;)if(f=b.slice(g-1,+g+1||9E9),h=f[0],c=f[1],e=function(){var b,d,e,f;e=[h,c];f=[];b=0;for(d=e.length;b<d;b++)a=e[b],f.push(k.indexOf(a)); return f}(),f=e[0],e=e[1],e-f===m)g+=1;else{2<g-d&&j.push({pattern:"sequence",i:d,j:g-1,token:b.slice(d,g),sequence_name:n,sequence_space:i.length,ascending:1===m});break}d=g}return j},function(b){var a,c,e;e=[];for(c in F)a=F[c],z(e,U(b,a,c));return e}]);F={qwerty:D,dvorak:{"!":["`~",null,null,"2@","'\"",null],'"':[null,"1!","2@",",<","aA",null],"#":["2@",null,null,"4$",".>",",<"],$:["3#",null,null,"5%","pP",".>"],"%":["4$",null,null,"6^","yY","pP"],"&":["6^",null,null,"8*","gG","fF"],"'":[null, "1!","2@",",<","aA",null],"(":["8*",null,null,"0)","rR","cC"],")":["9(",null,null,"[{","lL","rR"],"*":["7&",null,null,"9(","cC","gG"],"+":["/?","]}",null,"\\|",null,"-_"],",":"'\",2@,3#,.>,oO,aA".split(","),"-":["sS","/?","=+",null,null,"zZ"],".":",< 3# 4$ pP eE oO".split(" "),"/":"lL,[{,]},=+,-_,sS".split(","),"0":["9(",null,null,"[{","lL","rR"],1:["`~",null,null,"2@","'\"",null],2:["1!",null,null,"3#",",<","'\""],3:["2@",null,null,"4$",".>",",<"],4:["3#",null,null,"5%","pP",".>"],5:["4$",null,null, "6^","yY","pP"],6:["5%",null,null,"7&","fF","yY"],7:["6^",null,null,"8*","gG","fF"],8:["7&",null,null,"9(","cC","gG"],9:["8*",null,null,"0)","rR","cC"],":":[null,"aA","oO","qQ",null,null],";":[null,"aA","oO","qQ",null,null],"<":"'\",2@,3#,.>,oO,aA".split(","),"=":["/?","]}",null,"\\|",null,"-_"],">":",< 3# 4$ pP eE oO".split(" "),"?":"lL,[{,]},=+,-_,sS".split(","),"@":["1!",null,null,"3#",",<","'\""],A:[null,"'\"",",<","oO",";:",null],B:["xX","dD","hH","mM",null,null],C:"gG,8*,9(,rR,tT,hH".split(","), D:"iI,fF,gG,hH,bB,xX".split(","),E:"oO,.>,pP,uU,jJ,qQ".split(","),F:"yY,6^,7&,gG,dD,iI".split(","),G:"fF,7&,8*,cC,hH,dD".split(","),H:"dD,gG,cC,tT,mM,bB".split(","),I:"uU,yY,fF,dD,xX,kK".split(","),J:["qQ","eE","uU","kK",null,null],K:["jJ","uU","iI","xX",null,null],L:"rR,0),[{,/?,sS,nN".split(","),M:["bB","hH","tT","wW",null,null],N:"tT,rR,lL,sS,vV,wW".split(","),O:"aA ,< .> eE qQ ;:".split(" "),P:".>,4$,5%,yY,uU,eE".split(","),Q:[";:","oO","eE","jJ",null,null],R:"cC,9(,0),lL,nN,tT".split(","),S:"nN,lL,/?,-_,zZ,vV".split(","), T:"hH,cC,rR,nN,wW,mM".split(","),U:"eE,pP,yY,iI,kK,jJ".split(","),V:["wW","nN","sS","zZ",null,null],W:["mM","tT","nN","vV",null,null],X:["kK","iI","dD","bB",null,null],Y:"pP,5%,6^,fF,iI,uU".split(","),Z:["vV","sS","-_",null,null,null],"[":["0)",null,null,"]}","/?","lL"],"\\":["=+",null,null,null,null,null],"]":["[{",null,null,null,"=+","/?"],"^":["5%",null,null,"7&","fF","yY"],_:["sS","/?","=+",null,null,"zZ"],"`":[null,null,null,"1!",null,null],a:[null,"'\"",",<","oO",";:",null],b:["xX","dD","hH", "mM",null,null],c:"gG,8*,9(,rR,tT,hH".split(","),d:"iI,fF,gG,hH,bB,xX".split(","),e:"oO,.>,pP,uU,jJ,qQ".split(","),f:"yY,6^,7&,gG,dD,iI".split(","),g:"fF,7&,8*,cC,hH,dD".split(","),h:"dD,gG,cC,tT,mM,bB".split(","),i:"uU,yY,fF,dD,xX,kK".split(","),j:["qQ","eE","uU","kK",null,null],k:["jJ","uU","iI","xX",null,null],l:"rR,0),[{,/?,sS,nN".split(","),m:["bB","hH","tT","wW",null,null],n:"tT,rR,lL,sS,vV,wW".split(","),o:"aA ,< .> eE qQ ;:".split(" "),p:".>,4$,5%,yY,uU,eE".split(","),q:[";:","oO","eE","jJ", null,null],r:"cC,9(,0),lL,nN,tT".split(","),s:"nN,lL,/?,-_,zZ,vV".split(","),t:"hH,cC,rR,nN,wW,mM".split(","),u:"eE,pP,yY,iI,kK,jJ".split(","),v:["wW","nN","sS","zZ",null,null],w:["mM","tT","nN","vV",null,null],x:["kK","iI","dD","bB",null,null],y:"pP,5%,6^,fF,iI,uU".split(","),z:["vV","sS","-_",null,null,null],"{":["0)",null,null,"]}","/?","lL"],"|":["=+",null,null,null,null,null],"}":["[{",null,null,null,"=+","/?"],"~":[null,null,null,"1!",null,null]},keypad:E,mac_keypad:{"*":["/",null,null,null, null,null,"-","9"],"+":["6","9","-",null,null,null,null,"3"],"-":["9","/","*",null,null,null,"+","6"],".":["0","2","3",null,null,null,null,null],"/":["=",null,null,null,"*","-","9","8"],"0":[null,"1","2","3",".",null,null,null],1:[null,null,"4","5","2","0",null,null],2:["1","4","5","6","3",".","0",null],3:["2","5","6","+",null,null,".","0"],4:[null,null,"7","8","5","2","1",null],5:"4,7,8,9,6,3,2,1".split(","),6:["5","8","9","-","+",null,"3","2"],7:[null,null,null,"=","8","5","4",null],8:["7",null, "=","/","9","6","5","4"],9:"8,=,/,*,-,+,6,5".split(","),"=":[null,null,null,null,"/","9","8","7"]}};G=function(b){var a,c,e,f,d;a=0;for(e in b)d=b[e],a+=function(){var a,b,c;c=[];a=0;for(b=d.length;a<b;a++)(f=d[a])&&c.push(f);return c}().length;return a/=function(){var a;a=[];for(c in b)a.push(c);return a}().length};pa=G(D);ra=G(E);oa=function(){var b;b=[];for(w in D)b.push(w);return b}().length;qa=function(){var b;b=[];for(w in E)b.push(w);return b}().length;H=function(){return(new Date).getTime()}; I=function(b,a){var c,e,f,d,g;null==a&&(a=[]);g=H();d=[];e=0;for(f=a.length;e<f;e++)c=a[e],null!=c&&d.push(c.toString().toLowerCase());c=p("user_inputs",s(d));c=R(b,sa.concat(c));c=ja(b,c);c.calc_time=H()-g;return c};(function(b,a){"function"===typeof define&&null!=define.amd?define(["exports"],a):"object"===typeof exports?a(exports):b.zxcvbn=I;return"function"===typeof b.zxcvbn_load_hook?b.zxcvbn_load_hook():void 0})(this,function(b){return b.zxcvbn=I})})();
packages/cf-component-icon/src/reactsvgs/List.js
jroyal/cf-ui
import React from 'react'; import PropTypes from 'prop-types'; const List = ({ className, label }) => ( <svg className={className} aria-label={label} xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" > <rect x="1.589" y="2.539" width="1.98" height="1.98" /> <rect x="5.425" y="2.539" width="8.986" height="1.98" /> <rect x="1.589" y="6.979" width="1.98" height="1.98" /> <rect x="5.425" y="6.979" width="8.986" height="1.98" /> <rect x="1.589" y="11.481" width="1.98" height="1.98" /> <rect x="5.425" y="11.481" width="4.992" height="1.98" /> </svg> ); List.propTypes = { className: PropTypes.string.isRequired, label: PropTypes.string.isRequired }; export default List;
packages/material-ui-icons/custom/Telegram.js
lgollut/material-ui
import * as React from 'react'; import createSvgIcon from './utils/createSvgIcon'; export default createSvgIcon( <path d="M9.78 18.65l.28-4.23 7.68-6.92c.34-.31-.07-.46-.52-.19L7.74 13.3 3.64 12c-.88-.25-.89-.86.2-1.3l15.97-6.16c.73-.33 1.43.18 1.15 1.3l-2.72 12.81c-.19.91-.74 1.13-1.5.71L12.6 16.3l-1.99 1.93c-.23.23-.42.42-.83.42z" />, 'Telegram', );
packages/components/src/VirtualizedList/CellTitle/CellTitle.component.js
Talend/ui
import PropTypes from 'prop-types'; import React from 'react'; import isEqual from 'lodash/isEqual'; import classNames from 'classnames'; import Icon from '../../Icon'; import TooltipTrigger from '../../TooltipTrigger'; import CellTitleSelector from './CellTitleSelector.component'; import CellTitleActions from './CellTitleActions.component'; import { cellTitleDisplayModes, listTypes } from '../utils/constants'; import theme from './CellTitle.scss'; const { LARGE } = listTypes; const { TITLE_MODE_TEXT } = cellTitleDisplayModes; /** * Cell that renders the item's title. * A title is composed by * - an optional icon (rowData[columnData.iconKey]) * - a button with a click action (columnData.onClick) * - actions (rowData[columnData.actionsKey]) */ class CellTitle extends React.Component { shouldComponentUpdate(nextProps) { return ( this.props.cellData !== nextProps.cellData || !isEqual(this.props.columnData, nextProps.columnData) || this.props.getComponent !== nextProps.getComponent || this.props.rowData !== nextProps.rowData || this.props.rowIndex !== nextProps.rowIndex || this.props.type !== nextProps.type ); } render() { const { cellData, columnData, getComponent, rowData, rowIndex, type } = this.props; let cellColumnData = columnData; if (typeof columnData === 'function') { cellColumnData = columnData(rowData); } const { id, onClick, actionsKey, persistentActionsKey, displayModeKey, getRowState, iconKey, iconLabelKey, onEditCancel, onEditSubmit, ...columnDataRest } = cellColumnData; const displayMode = rowData[displayModeKey] || TITLE_MODE_TEXT; const { disabled = false, tooltip } = (getRowState && getRowState(rowData)) || {}; const titleId = id && `${id}-${rowIndex}-title-cell`; const actionsId = id && `${id}-${rowIndex}-title-actions`; let icon = null; if (iconKey && rowData[iconKey]) { icon = <Icon name={rowData[iconKey]} className={theme.icon} />; } if (icon && iconLabelKey && rowData[iconLabelKey]) { icon = ( <TooltipTrigger label={rowData[iconLabelKey]} tooltipPlacement="top"> <span> <Icon name={rowData[iconKey]} className={theme.icon} /> </span> </TooltipTrigger> ); } const defaultTitle = ( <React.Fragment> <CellTitleSelector id={titleId} cellData={cellData} className={theme['main-title']} displayMode={displayMode} onClick={onClick} onEditCancel={onEditCancel} onEditSubmit={onEditSubmit} rowData={rowData} columnData={columnDataRest} tooltip={tooltip} /> <CellTitleActions getComponent={getComponent} id={actionsId} rowData={rowData} actionsKey={actionsKey} persistentActionsKey={persistentActionsKey} displayMode={displayMode} type={type} /> </React.Fragment> ); return ( <div id={titleId} className={classNames(theme['tc-list-title'], 'tc-list-title', { [theme['tc-list-title-filter']]: onClick, [theme['tc-list-title-disabled']]: disabled, 'tc-list-title-filter': onClick, })} > {icon} {disabled ? ( <TooltipTrigger label={tooltip || cellData} tooltipPlacement="top"> <span id={titleId} className={theme['main-title']}> {cellData} </span> </TooltipTrigger> ) : ( defaultTitle )} </div> ); } } CellTitle.displayName = 'VirtualizedList(CellTitle)'; CellTitle.propTypes = { // The cell value : props.rowData[props.dataKey] cellData: PropTypes.string, // The custom props passed to <VirtualizedList.Content columnData={}>. columnData: PropTypes.oneOfType([ PropTypes.func, PropTypes.shape({ // The List id. This is used as the title parts ids prefix. id: PropTypes.string, // The onClick callback triggered on title main button click. onClick: PropTypes.func, // The actions property key. Actions = props.rowData[props.actionsKey] actionsKey: PropTypes.string, // The persistent actions property key. Actions = props.rowData[props.persistentActionsKey] persistentActionsKey: PropTypes.string, // The display mode property key. DisplayMode = props.rowData[props.displayModeKey] displayModeKey: PropTypes.string, // The icon property key. Icon = props.rowData[props.iconKey] iconKey: PropTypes.string, // The icon tooltip label key. tooltiplabel = props.rowData[iconLabelKey] iconLabelKey: PropTypes.string, // Input mode : the cancel callback on ESC keydown. onEditCancel: PropTypes.func, // Input mode : the submit callback on ENTER keydown or blur. onEditSubmit: PropTypes.func, }), ]), getComponent: PropTypes.func, // The collection item. rowData: PropTypes.object, // eslint-disable-line // The collection item index. rowIndex: PropTypes.number, // The type of display type: PropTypes.oneOf([LARGE]), }; export default CellTitle;
src/containers/pages/decks/deck-selection/right-container/decklist/topbar/topbar-item.js
vFujin/HearthLounge
import React from 'react'; import PropTypes from 'prop-types'; import _ from 'lodash'; const TopbarItem = ({title, className}) => { return ( <li className={`decks__decklist--snippet-${className || title}`}>{_.startCase(title)}</li> ) }; TopbarItem.propTypes = { title: PropTypes.string.isRequired, className: PropTypes.string }; TopbarItem.defaultProps = { title: undefined, className: undefined }; export default TopbarItem;
src/svg-icons/device/screen-rotation.js
IsenrichO/mui-with-arrows
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let DeviceScreenRotation = (props) => ( <SvgIcon {...props}> <path d="M16.48 2.52c3.27 1.55 5.61 4.72 5.97 8.48h1.5C23.44 4.84 18.29 0 12 0l-.66.03 3.81 3.81 1.33-1.32zm-6.25-.77c-.59-.59-1.54-.59-2.12 0L1.75 8.11c-.59.59-.59 1.54 0 2.12l12.02 12.02c.59.59 1.54.59 2.12 0l6.36-6.36c.59-.59.59-1.54 0-2.12L10.23 1.75zm4.6 19.44L2.81 9.17l6.36-6.36 12.02 12.02-6.36 6.36zm-7.31.29C4.25 19.94 1.91 16.76 1.55 13H.05C.56 19.16 5.71 24 12 24l.66-.03-3.81-3.81-1.33 1.32z"/> </SvgIcon> ); DeviceScreenRotation = pure(DeviceScreenRotation); DeviceScreenRotation.displayName = 'DeviceScreenRotation'; DeviceScreenRotation.muiName = 'SvgIcon'; export default DeviceScreenRotation;
src/svg-icons/action/settings-overscan.js
hwo411/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ActionSettingsOverscan = (props) => ( <SvgIcon {...props}> <path d="M12.01 5.5L10 8h4l-1.99-2.5zM18 10v4l2.5-1.99L18 10zM6 10l-2.5 2.01L6 14v-4zm8 6h-4l2.01 2.5L14 16zm7-13H3c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16.01H3V4.99h18v14.02z"/> </SvgIcon> ); ActionSettingsOverscan = pure(ActionSettingsOverscan); ActionSettingsOverscan.displayName = 'ActionSettingsOverscan'; ActionSettingsOverscan.muiName = 'SvgIcon'; export default ActionSettingsOverscan;
src/admin/components/media/media.js
ccetc/platform
import React from 'react' import { connect } from 'react-redux' import * as actions from './actions' import Image from './image' import Video from './video' class Media extends React.Component { render() { const { mode } = this.props if(mode === 'image') { return <Image /> } else if(mode === 'video') { return <Video /> } return ( <div className="chrome-modal-panel"> <div className="chrome-modal-panel-header"> <div className="chrome-modal-panel-header-cancel"> Back </div> <div className="chrome-modal-panel-header-title"> Media </div> <div className="chrome-modal-panel-header-proceed"> Next </div> </div> <div className="chrome-modal-panel-body"> <a onClick={ this._changeMode.bind(this, 'image')}>Image</a> <a onClick={ this._changeMode.bind(this, 'video')}>Video</a> </div> </div> ) } _changeMode(mode) { this.props.onChangeMode(mode) } } const mapStateToProps = (state, props) => ({ mode: state.media.mode }) const mapDispatchToProps = { onChangeMode: actions.changeMode } export default connect(mapStateToProps, mapDispatchToProps)(Media)
media/jui/js/jquery.min.js
tstahl-git/joomla-cms
/*! jQuery v1.12.4-joomla | (c) jQuery Foundation | jquery.org/license */ !function(e,t){"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(e,t){var n=[],r=e.document,i=n.slice,o=n.concat,a=n.push,s=n.indexOf,u={},l=u.toString,c=u.hasOwnProperty,f={},d=function(e,t){return new d.fn.init(e,t)},p=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,h=/^-ms-/,g=/-([\da-z])/gi,m=function(e,t){return t.toUpperCase()};function v(e){var t=!!e&&"length"in e&&e.length,n=d.type(e);return"function"!==n&&!d.isWindow(e)&&("array"===n||0===t||"number"==typeof t&&t>0&&t-1 in e)}d.fn=d.prototype={jquery:"1.12.4",constructor:d,selector:"",length:0,toArray:function(){return i.call(this)},get:function(e){return null!=e?e<0?this[e+this.length]:this[e]:i.call(this)},pushStack:function(e){var t=d.merge(this.constructor(),e);return t.prevObject=this,t.context=this.context,t},each:function(e){return d.each(this,e)},map:function(e){return this.pushStack(d.map(this,function(t,n){return e.call(t,n,t)}))},slice:function(){return this.pushStack(i.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(e){var t=this.length,n=+e+(e<0?t:0);return this.pushStack(n>=0&&n<t?[this[n]]:[])},end:function(){return this.prevObject||this.constructor()},push:a,sort:n.sort,splice:n.splice},d.extend=d.fn.extend=function(){var e,t,n,r,i,o,a=arguments[0]||{},s=1,u=arguments.length,l=!1;for("boolean"==typeof a&&(l=a,a=arguments[s]||{},s++),"object"==typeof a||d.isFunction(a)||(a={}),s===u&&(a=this,s--);s<u;s++)if(null!=(i=arguments[s]))for(r in i)e=a[r],n=i[r],"__proto__"!==r&&a!==n&&(l&&n&&(d.isPlainObject(n)||(t=d.isArray(n)))?(t?(t=!1,o=e&&d.isArray(e)?e:[]):o=e&&d.isPlainObject(e)?e:{},a[r]=d.extend(l,o,n)):void 0!==n&&(a[r]=n));return a},d.extend({expando:"jQuery"+("1.12.4"+Math.random()).replace(/\D/g,""),isReady:!0,error:function(e){throw new Error(e)},noop:function(){},isFunction:function(e){return"function"===d.type(e)},isArray:Array.isArray||function(e){return"array"===d.type(e)},isWindow:function(e){return null!=e&&e==e.window},isNumeric:function(e){var t=e&&e.toString();return!d.isArray(e)&&t-parseFloat(t)+1>=0},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},isPlainObject:function(e){var t;if(!e||"object"!==d.type(e)||e.nodeType||d.isWindow(e))return!1;try{if(e.constructor&&!c.call(e,"constructor")&&!c.call(e.constructor.prototype,"isPrototypeOf"))return!1}catch(e){return!1}if(!f.ownFirst)for(t in e)return c.call(e,t);for(t in e);return void 0===t||c.call(e,t)},type:function(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?u[l.call(e)]||"object":typeof e},globalEval:function(t){t&&d.trim(t)&&(e.execScript||function(t){e.eval.call(e,t)})(t)},camelCase:function(e){return e.replace(h,"ms-").replace(g,m)},nodeName:function(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()},each:function(e,t){var n,r=0;if(v(e))for(n=e.length;r<n&&!1!==t.call(e[r],r,e[r]);r++);else for(r in e)if(!1===t.call(e[r],r,e[r]))break;return e},trim:function(e){return null==e?"":(e+"").replace(p,"")},makeArray:function(e,t){var n=t||[];return null!=e&&(v(Object(e))?d.merge(n,"string"==typeof e?[e]:e):a.call(n,e)),n},inArray:function(e,t,n){var r;if(t){if(s)return s.call(t,e,n);for(r=t.length,n=n?n<0?Math.max(0,r+n):n:0;n<r;n++)if(n in t&&t[n]===e)return n}return-1},merge:function(e,t){for(var n=+t.length,r=0,i=e.length;r<n;)e[i++]=t[r++];if(n!=n)for(;void 0!==t[r];)e[i++]=t[r++];return e.length=i,e},grep:function(e,t,n){for(var r=[],i=0,o=e.length,a=!n;i<o;i++)!t(e[i],i)!==a&&r.push(e[i]);return r},map:function(e,t,n){var r,i,a=0,s=[];if(v(e))for(r=e.length;a<r;a++)null!=(i=t(e[a],a,n))&&s.push(i);else for(a in e)null!=(i=t(e[a],a,n))&&s.push(i);return o.apply([],s)},guid:1,proxy:function(e,t){var n,r,o;if("string"==typeof t&&(o=e[t],t=e,e=o),d.isFunction(e))return n=i.call(arguments,2),(r=function(){return e.apply(t||this,n.concat(i.call(arguments)))}).guid=e.guid=e.guid||d.guid++,r},now:function(){return+new Date},support:f}),"function"==typeof Symbol&&(d.fn[Symbol.iterator]=n[Symbol.iterator]),d.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(e,t){u["[object "+t+"]"]=t.toLowerCase()});var y=function(e){var t,n,r,i,o,a,s,u,l,c,f,d,p,h,g,m,v,y,x,b="sizzle"+1*new Date,w=e.document,T=0,C=0,E=oe(),N=oe(),k=oe(),S=function(e,t){return e===t&&(f=!0),0},A=1<<31,D={}.hasOwnProperty,j=[],L=j.pop,H=j.push,q=j.push,_=j.slice,M=function(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1},F="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",O="[\\x20\\t\\r\\n\\f]",R="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",P="\\["+O+"*("+R+")(?:"+O+"*([*^$|!~]?=)"+O+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+R+"))|)"+O+"*\\]",B=":("+R+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+P+")*)|.*)\\)|)",W=new RegExp(O+"+","g"),I=new RegExp("^"+O+"+|((?:^|[^\\\\])(?:\\\\.)*)"+O+"+$","g"),$=new RegExp("^"+O+"*,"+O+"*"),z=new RegExp("^"+O+"*([>+~]|"+O+")"+O+"*"),X=new RegExp("="+O+"*([^\\]'\"]*?)"+O+"*\\]","g"),U=new RegExp(B),V=new RegExp("^"+R+"$"),Y={ID:new RegExp("^#("+R+")"),CLASS:new RegExp("^\\.("+R+")"),TAG:new RegExp("^("+R+"|[*])"),ATTR:new RegExp("^"+P),PSEUDO:new RegExp("^"+B),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+O+"*(even|odd|(([+-]|)(\\d*)n|)"+O+"*(?:([+-]|)"+O+"*(\\d+)|))"+O+"*\\)|)","i"),bool:new RegExp("^(?:"+F+")$","i"),needsContext:new RegExp("^"+O+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+O+"*((?:-\\d)?\\d*)"+O+"*\\)|)(?=[^-]|$)","i")},J=/^(?:input|select|textarea|button)$/i,G=/^h\d$/i,Q=/^[^{]+\{\s*\[native \w/,K=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,Z=/[+~]/,ee=/'|\\/g,te=new RegExp("\\\\([\\da-f]{1,6}"+O+"?|("+O+")|.)","ig"),ne=function(e,t,n){var r="0x"+t-65536;return r!=r||n?t:r<0?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,1023&r|56320)},re=function(){d()};try{q.apply(j=_.call(w.childNodes),w.childNodes),j[w.childNodes.length].nodeType}catch(e){q={apply:j.length?function(e,t){H.apply(e,_.call(t))}:function(e,t){for(var n=e.length,r=0;e[n++]=t[r++];);e.length=n-1}}}function ie(e,t,r,i){var o,s,l,c,f,h,v,y,T=t&&t.ownerDocument,C=t?t.nodeType:9;if(r=r||[],"string"!=typeof e||!e||1!==C&&9!==C&&11!==C)return r;if(!i&&((t?t.ownerDocument||t:w)!==p&&d(t),t=t||p,g)){if(11!==C&&(h=K.exec(e)))if(o=h[1]){if(9===C){if(!(l=t.getElementById(o)))return r;if(l.id===o)return r.push(l),r}else if(T&&(l=T.getElementById(o))&&x(t,l)&&l.id===o)return r.push(l),r}else{if(h[2])return q.apply(r,t.getElementsByTagName(e)),r;if((o=h[3])&&n.getElementsByClassName&&t.getElementsByClassName)return q.apply(r,t.getElementsByClassName(o)),r}if(n.qsa&&!k[e+" "]&&(!m||!m.test(e))){if(1!==C)T=t,y=e;else if("object"!==t.nodeName.toLowerCase()){for((c=t.getAttribute("id"))?c=c.replace(ee,"\\$&"):t.setAttribute("id",c=b),s=(v=a(e)).length,f=V.test(c)?"#"+c:"[id='"+c+"']";s--;)v[s]=f+" "+ge(v[s]);y=v.join(","),T=Z.test(e)&&pe(t.parentNode)||t}if(y)try{return q.apply(r,T.querySelectorAll(y)),r}catch(e){}finally{c===b&&t.removeAttribute("id")}}}return u(e.replace(I,"$1"),t,r,i)}function oe(){var e=[];return function t(n,i){return e.push(n+" ")>r.cacheLength&&delete t[e.shift()],t[n+" "]=i}}function ae(e){return e[b]=!0,e}function se(e){var t=p.createElement("div");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function ue(e,t){for(var n=e.split("|"),i=n.length;i--;)r.attrHandle[n[i]]=t}function le(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&(~t.sourceIndex||A)-(~e.sourceIndex||A);if(r)return r;if(n)for(;n=n.nextSibling;)if(n===t)return-1;return e?1:-1}function ce(e){return function(t){return"input"===t.nodeName.toLowerCase()&&t.type===e}}function fe(e){return function(t){var n=t.nodeName.toLowerCase();return("input"===n||"button"===n)&&t.type===e}}function de(e){return ae(function(t){return t=+t,ae(function(n,r){for(var i,o=e([],n.length,t),a=o.length;a--;)n[i=o[a]]&&(n[i]=!(r[i]=n[i]))})})}function pe(e){return e&&void 0!==e.getElementsByTagName&&e}for(t in n=ie.support={},o=ie.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return!!t&&"HTML"!==t.nodeName},d=ie.setDocument=function(e){var t,i,a=e?e.ownerDocument||e:w;return a!==p&&9===a.nodeType&&a.documentElement?(h=(p=a).documentElement,g=!o(p),(i=p.defaultView)&&i.top!==i&&(i.addEventListener?i.addEventListener("unload",re,!1):i.attachEvent&&i.attachEvent("onunload",re)),n.attributes=se(function(e){return e.className="i",!e.getAttribute("className")}),n.getElementsByTagName=se(function(e){return e.appendChild(p.createComment("")),!e.getElementsByTagName("*").length}),n.getElementsByClassName=Q.test(p.getElementsByClassName),n.getById=se(function(e){return h.appendChild(e).id=b,!p.getElementsByName||!p.getElementsByName(b).length}),n.getById?(r.find.ID=function(e,t){if(void 0!==t.getElementById&&g){var n=t.getElementById(e);return n?[n]:[]}},r.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute("id")===t}}):(delete r.find.ID,r.filter.ID=function(e){var t=e.replace(te,ne);return function(e){var n=void 0!==e.getAttributeNode&&e.getAttributeNode("id");return n&&n.value===t}}),r.find.TAG=n.getElementsByTagName?function(e,t){return void 0!==t.getElementsByTagName?t.getElementsByTagName(e):n.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){for(;n=o[i++];)1===n.nodeType&&r.push(n);return r}return o},r.find.CLASS=n.getElementsByClassName&&function(e,t){if(void 0!==t.getElementsByClassName&&g)return t.getElementsByClassName(e)},v=[],m=[],(n.qsa=Q.test(p.querySelectorAll))&&(se(function(e){h.appendChild(e).innerHTML="<a id='"+b+"'></a><select id='"+b+"-\r\\' msallowcapture=''><option selected=''></option></select>",e.querySelectorAll("[msallowcapture^='']").length&&m.push("[*^$]="+O+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||m.push("\\["+O+"*(?:value|"+F+")"),e.querySelectorAll("[id~="+b+"-]").length||m.push("~="),e.querySelectorAll(":checked").length||m.push(":checked"),e.querySelectorAll("a#"+b+"+*").length||m.push(".#.+[+~]")}),se(function(e){var t=p.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&m.push("name"+O+"*[*^$|!~]?="),e.querySelectorAll(":enabled").length||m.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),m.push(",.*:")})),(n.matchesSelector=Q.test(y=h.matches||h.webkitMatchesSelector||h.mozMatchesSelector||h.oMatchesSelector||h.msMatchesSelector))&&se(function(e){n.disconnectedMatch=y.call(e,"div"),y.call(e,"[s!='']:x"),v.push("!=",B)}),m=m.length&&new RegExp(m.join("|")),v=v.length&&new RegExp(v.join("|")),t=Q.test(h.compareDocumentPosition),x=t||Q.test(h.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)for(;t=t.parentNode;)if(t===e)return!0;return!1},S=t?function(e,t){if(e===t)return f=!0,0;var r=!e.compareDocumentPosition-!t.compareDocumentPosition;return r||(1&(r=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!n.sortDetached&&t.compareDocumentPosition(e)===r?e===p||e.ownerDocument===w&&x(w,e)?-1:t===p||t.ownerDocument===w&&x(w,t)?1:c?M(c,e)-M(c,t):0:4&r?-1:1)}:function(e,t){if(e===t)return f=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e===p?-1:t===p?1:i?-1:o?1:c?M(c,e)-M(c,t):0;if(i===o)return le(e,t);for(n=e;n=n.parentNode;)a.unshift(n);for(n=t;n=n.parentNode;)s.unshift(n);for(;a[r]===s[r];)r++;return r?le(a[r],s[r]):a[r]===w?-1:s[r]===w?1:0},p):p},ie.matches=function(e,t){return ie(e,null,null,t)},ie.matchesSelector=function(e,t){if((e.ownerDocument||e)!==p&&d(e),t=t.replace(X,"='$1']"),n.matchesSelector&&g&&!k[t+" "]&&(!v||!v.test(t))&&(!m||!m.test(t)))try{var r=y.call(e,t);if(r||n.disconnectedMatch||e.document&&11!==e.document.nodeType)return r}catch(e){}return ie(t,p,null,[e]).length>0},ie.contains=function(e,t){return(e.ownerDocument||e)!==p&&d(e),x(e,t)},ie.attr=function(e,t){(e.ownerDocument||e)!==p&&d(e);var i=r.attrHandle[t.toLowerCase()],o=i&&D.call(r.attrHandle,t.toLowerCase())?i(e,t,!g):void 0;return void 0!==o?o:n.attributes||!g?e.getAttribute(t):(o=e.getAttributeNode(t))&&o.specified?o.value:null},ie.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},ie.uniqueSort=function(e){var t,r=[],i=0,o=0;if(f=!n.detectDuplicates,c=!n.sortStable&&e.slice(0),e.sort(S),f){for(;t=e[o++];)t===e[o]&&(i=r.push(o));for(;i--;)e.splice(r[i],1)}return c=null,e},i=ie.getText=function(e){var t,n="",r=0,o=e.nodeType;if(o){if(1===o||9===o||11===o){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=i(e)}else if(3===o||4===o)return e.nodeValue}else for(;t=e[r++];)n+=i(t);return n},(r=ie.selectors={cacheLength:50,createPseudo:ae,match:Y,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(te,ne),e[3]=(e[3]||e[4]||e[5]||"").replace(te,ne),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||ie.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&ie.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return Y.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&U.test(n)&&(t=a(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(te,ne).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=E[e+" "];return t||(t=new RegExp("(^|"+O+")"+e+"("+O+"|$)"))&&E(e,function(e){return t.test("string"==typeof e.className&&e.className||void 0!==e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(e,t,n){return function(r){var i=ie.attr(r,e);return null==i?"!="===t:!t||(i+="","="===t?i===n:"!="===t?i!==n:"^="===t?n&&0===i.indexOf(n):"*="===t?n&&i.indexOf(n)>-1:"$="===t?n&&i.slice(-n.length)===n:"~="===t?(" "+i.replace(W," ")+" ").indexOf(n)>-1:"|="===t&&(i===n||i.slice(0,n.length+1)===n+"-"))}},CHILD:function(e,t,n,r,i){var o="nth"!==e.slice(0,3),a="last"!==e.slice(-4),s="of-type"===t;return 1===r&&0===i?function(e){return!!e.parentNode}:function(t,n,u){var l,c,f,d,p,h,g=o!==a?"nextSibling":"previousSibling",m=t.parentNode,v=s&&t.nodeName.toLowerCase(),y=!u&&!s,x=!1;if(m){if(o){for(;g;){for(d=t;d=d[g];)if(s?d.nodeName.toLowerCase()===v:1===d.nodeType)return!1;h=g="only"===e&&!h&&"nextSibling"}return!0}if(h=[a?m.firstChild:m.lastChild],a&&y){for(x=(p=(l=(c=(f=(d=m)[b]||(d[b]={}))[d.uniqueID]||(f[d.uniqueID]={}))[e]||[])[0]===T&&l[1])&&l[2],d=p&&m.childNodes[p];d=++p&&d&&d[g]||(x=p=0)||h.pop();)if(1===d.nodeType&&++x&&d===t){c[e]=[T,p,x];break}}else if(y&&(x=p=(l=(c=(f=(d=t)[b]||(d[b]={}))[d.uniqueID]||(f[d.uniqueID]={}))[e]||[])[0]===T&&l[1]),!1===x)for(;(d=++p&&d&&d[g]||(x=p=0)||h.pop())&&((s?d.nodeName.toLowerCase()!==v:1!==d.nodeType)||!++x||(y&&((c=(f=d[b]||(d[b]={}))[d.uniqueID]||(f[d.uniqueID]={}))[e]=[T,x]),d!==t)););return(x-=i)===r||x%r==0&&x/r>=0}}},PSEUDO:function(e,t){var n,i=r.pseudos[e]||r.setFilters[e.toLowerCase()]||ie.error("unsupported pseudo: "+e);return i[b]?i(t):i.length>1?(n=[e,e,"",t],r.setFilters.hasOwnProperty(e.toLowerCase())?ae(function(e,n){for(var r,o=i(e,t),a=o.length;a--;)e[r=M(e,o[a])]=!(n[r]=o[a])}):function(e){return i(e,0,n)}):i}},pseudos:{not:ae(function(e){var t=[],n=[],r=s(e.replace(I,"$1"));return r[b]?ae(function(e,t,n,i){for(var o,a=r(e,null,i,[]),s=e.length;s--;)(o=a[s])&&(e[s]=!(t[s]=o))}):function(e,i,o){return t[0]=e,r(t,null,o,n),t[0]=null,!n.pop()}}),has:ae(function(e){return function(t){return ie(e,t).length>0}}),contains:ae(function(e){return e=e.replace(te,ne),function(t){return(t.textContent||t.innerText||i(t)).indexOf(e)>-1}}),lang:ae(function(e){return V.test(e||"")||ie.error("unsupported lang: "+e),e=e.replace(te,ne).toLowerCase(),function(t){var n;do{if(n=g?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return(n=n.toLowerCase())===e||0===n.indexOf(e+"-")}while((t=t.parentNode)&&1===t.nodeType);return!1}}),target:function(t){var n=e.location&&e.location.hash;return n&&n.slice(1)===t.id},root:function(e){return e===h},focus:function(e){return e===p.activeElement&&(!p.hasFocus||p.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:function(e){return!1===e.disabled},disabled:function(e){return!0===e.disabled},checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,!0===e.selected},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!r.pseudos.empty(e)},header:function(e){return G.test(e.nodeName)},input:function(e){return J.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||"text"===t.toLowerCase())},first:de(function(){return[0]}),last:de(function(e,t){return[t-1]}),eq:de(function(e,t,n){return[n<0?n+t:n]}),even:de(function(e,t){for(var n=0;n<t;n+=2)e.push(n);return e}),odd:de(function(e,t){for(var n=1;n<t;n+=2)e.push(n);return e}),lt:de(function(e,t,n){for(var r=n<0?n+t:n;--r>=0;)e.push(r);return e}),gt:de(function(e,t,n){for(var r=n<0?n+t:n;++r<t;)e.push(r);return e})}}).pseudos.nth=r.pseudos.eq,{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})r.pseudos[t]=ce(t);for(t in{submit:!0,reset:!0})r.pseudos[t]=fe(t);function he(){}function ge(e){for(var t=0,n=e.length,r="";t<n;t++)r+=e[t].value;return r}function me(e,t,n){var r=t.dir,i=n&&"parentNode"===r,o=C++;return t.first?function(t,n,o){for(;t=t[r];)if(1===t.nodeType||i)return e(t,n,o)}:function(t,n,a){var s,u,l,c=[T,o];if(a){for(;t=t[r];)if((1===t.nodeType||i)&&e(t,n,a))return!0}else for(;t=t[r];)if(1===t.nodeType||i){if((s=(u=(l=t[b]||(t[b]={}))[t.uniqueID]||(l[t.uniqueID]={}))[r])&&s[0]===T&&s[1]===o)return c[2]=s[2];if(u[r]=c,c[2]=e(t,n,a))return!0}}}function ve(e){return e.length>1?function(t,n,r){for(var i=e.length;i--;)if(!e[i](t,n,r))return!1;return!0}:e[0]}function ye(e,t,n,r,i){for(var o,a=[],s=0,u=e.length,l=null!=t;s<u;s++)(o=e[s])&&(n&&!n(o,r,i)||(a.push(o),l&&t.push(s)));return a}function xe(e,t,n,r,i,o){return r&&!r[b]&&(r=xe(r)),i&&!i[b]&&(i=xe(i,o)),ae(function(o,a,s,u){var l,c,f,d=[],p=[],h=a.length,g=o||function(e,t,n){for(var r=0,i=t.length;r<i;r++)ie(e,t[r],n);return n}(t||"*",s.nodeType?[s]:s,[]),m=!e||!o&&t?g:ye(g,d,e,s,u),v=n?i||(o?e:h||r)?[]:a:m;if(n&&n(m,v,s,u),r)for(l=ye(v,p),r(l,[],s,u),c=l.length;c--;)(f=l[c])&&(v[p[c]]=!(m[p[c]]=f));if(o){if(i||e){if(i){for(l=[],c=v.length;c--;)(f=v[c])&&l.push(m[c]=f);i(null,v=[],l,u)}for(c=v.length;c--;)(f=v[c])&&(l=i?M(o,f):d[c])>-1&&(o[l]=!(a[l]=f))}}else v=ye(v===a?v.splice(h,v.length):v),i?i(null,a,v,u):q.apply(a,v)})}function be(e){for(var t,n,i,o=e.length,a=r.relative[e[0].type],s=a||r.relative[" "],u=a?1:0,c=me(function(e){return e===t},s,!0),f=me(function(e){return M(t,e)>-1},s,!0),d=[function(e,n,r){var i=!a&&(r||n!==l)||((t=n).nodeType?c(e,n,r):f(e,n,r));return t=null,i}];u<o;u++)if(n=r.relative[e[u].type])d=[me(ve(d),n)];else{if((n=r.filter[e[u].type].apply(null,e[u].matches))[b]){for(i=++u;i<o&&!r.relative[e[i].type];i++);return xe(u>1&&ve(d),u>1&&ge(e.slice(0,u-1).concat({value:" "===e[u-2].type?"*":""})).replace(I,"$1"),n,u<i&&be(e.slice(u,i)),i<o&&be(e=e.slice(i)),i<o&&ge(e))}d.push(n)}return ve(d)}return he.prototype=r.filters=r.pseudos,r.setFilters=new he,a=ie.tokenize=function(e,t){var n,i,o,a,s,u,l,c=N[e+" "];if(c)return t?0:c.slice(0);for(s=e,u=[],l=r.preFilter;s;){for(a in n&&!(i=$.exec(s))||(i&&(s=s.slice(i[0].length)||s),u.push(o=[])),n=!1,(i=z.exec(s))&&(n=i.shift(),o.push({value:n,type:i[0].replace(I," ")}),s=s.slice(n.length)),r.filter)!(i=Y[a].exec(s))||l[a]&&!(i=l[a](i))||(n=i.shift(),o.push({value:n,type:a,matches:i}),s=s.slice(n.length));if(!n)break}return t?s.length:s?ie.error(e):N(e,u).slice(0)},s=ie.compile=function(e,t){var n,i=[],o=[],s=k[e+" "];if(!s){for(t||(t=a(e)),n=t.length;n--;)(s=be(t[n]))[b]?i.push(s):o.push(s);(s=k(e,function(e,t){var n=t.length>0,i=e.length>0,o=function(o,a,s,u,c){var f,h,m,v=0,y="0",x=o&&[],b=[],w=l,C=o||i&&r.find.TAG("*",c),E=T+=null==w?1:Math.random()||.1,N=C.length;for(c&&(l=a===p||a||c);y!==N&&null!=(f=C[y]);y++){if(i&&f){for(h=0,a||f.ownerDocument===p||(d(f),s=!g);m=e[h++];)if(m(f,a||p,s)){u.push(f);break}c&&(T=E)}n&&((f=!m&&f)&&v--,o&&x.push(f))}if(v+=y,n&&y!==v){for(h=0;m=t[h++];)m(x,b,a,s);if(o){if(v>0)for(;y--;)x[y]||b[y]||(b[y]=L.call(u));b=ye(b)}q.apply(u,b),c&&!o&&b.length>0&&v+t.length>1&&ie.uniqueSort(u)}return c&&(T=E,l=w),x};return n?ae(o):o}(o,i))).selector=e}return s},u=ie.select=function(e,t,i,o){var u,l,c,f,d,p="function"==typeof e&&e,h=!o&&a(e=p.selector||e);if(i=i||[],1===h.length){if((l=h[0]=h[0].slice(0)).length>2&&"ID"===(c=l[0]).type&&n.getById&&9===t.nodeType&&g&&r.relative[l[1].type]){if(!(t=(r.find.ID(c.matches[0].replace(te,ne),t)||[])[0]))return i;p&&(t=t.parentNode),e=e.slice(l.shift().value.length)}for(u=Y.needsContext.test(e)?0:l.length;u--&&(c=l[u],!r.relative[f=c.type]);)if((d=r.find[f])&&(o=d(c.matches[0].replace(te,ne),Z.test(l[0].type)&&pe(t.parentNode)||t))){if(l.splice(u,1),!(e=o.length&&ge(l)))return q.apply(i,o),i;break}}return(p||s(e,h))(o,t,!g,i,!t||Z.test(e)&&pe(t.parentNode)||t),i},n.sortStable=b.split("").sort(S).join("")===b,n.detectDuplicates=!!f,d(),n.sortDetached=se(function(e){return 1&e.compareDocumentPosition(p.createElement("div"))}),se(function(e){return e.innerHTML="<a href='#'></a>","#"===e.firstChild.getAttribute("href")})||ue("type|href|height|width",function(e,t,n){if(!n)return e.getAttribute(t,"type"===t.toLowerCase()?1:2)}),n.attributes&&se(function(e){return e.innerHTML="<input/>",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")})||ue("value",function(e,t,n){if(!n&&"input"===e.nodeName.toLowerCase())return e.defaultValue}),se(function(e){return null==e.getAttribute("disabled")})||ue(F,function(e,t,n){var r;if(!n)return!0===e[t]?t.toLowerCase():(r=e.getAttributeNode(t))&&r.specified?r.value:null}),ie}(e);d.find=y,d.expr=y.selectors,d.expr[":"]=d.expr.pseudos,d.uniqueSort=d.unique=y.uniqueSort,d.text=y.getText,d.isXMLDoc=y.isXML,d.contains=y.contains;var x=function(e,t,n){for(var r=[],i=void 0!==n;(e=e[t])&&9!==e.nodeType;)if(1===e.nodeType){if(i&&d(e).is(n))break;r.push(e)}return r},b=function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n},w=d.expr.match.needsContext,T=/^<([\w-]+)\s*\/?>(?:<\/\1>|)$/,C=/^.[^:#\[\.,]*$/;function E(e,t,n){if(d.isFunction(t))return d.grep(e,function(e,r){return!!t.call(e,r,e)!==n});if(t.nodeType)return d.grep(e,function(e){return e===t!==n});if("string"==typeof t){if(C.test(t))return d.filter(t,e,n);t=d.filter(t,e)}return d.grep(e,function(e){return d.inArray(e,t)>-1!==n})}d.filter=function(e,t,n){var r=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===r.nodeType?d.find.matchesSelector(r,e)?[r]:[]:d.find.matches(e,d.grep(t,function(e){return 1===e.nodeType}))},d.fn.extend({find:function(e){var t,n=[],r=this,i=r.length;if("string"!=typeof e)return this.pushStack(d(e).filter(function(){for(t=0;t<i;t++)if(d.contains(r[t],this))return!0}));for(t=0;t<i;t++)d.find(e,r[t],n);return(n=this.pushStack(i>1?d.unique(n):n)).selector=this.selector?this.selector+" "+e:e,n},filter:function(e){return this.pushStack(E(this,e||[],!1))},not:function(e){return this.pushStack(E(this,e||[],!0))},is:function(e){return!!E(this,"string"==typeof e&&w.test(e)?d(e):e||[],!1).length}});var N,k=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/;(d.fn.init=function(e,t,n){var i,o;if(!e)return this;if(n=n||N,"string"==typeof e){if(!(i="<"===e.charAt(0)&&">"===e.charAt(e.length-1)&&e.length>=3?[null,e,null]:k.exec(e))||!i[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(i[1]){if(t=t instanceof d?t[0]:t,d.merge(this,d.parseHTML(i[1],t&&t.nodeType?t.ownerDocument||t:r,!0)),T.test(i[1])&&d.isPlainObject(t))for(i in t)d.isFunction(this[i])?this[i](t[i]):this.attr(i,t[i]);return this}if((o=r.getElementById(i[2]))&&o.parentNode){if(o.id!==i[2])return N.find(e);this.length=1,this[0]=o}return this.context=r,this.selector=e,this}return e.nodeType?(this.context=this[0]=e,this.length=1,this):d.isFunction(e)?void 0!==n.ready?n.ready(e):e(d):(void 0!==e.selector&&(this.selector=e.selector,this.context=e.context),d.makeArray(e,this))}).prototype=d.fn,N=d(r);var S=/^(?:parents|prev(?:Until|All))/,A={children:!0,contents:!0,next:!0,prev:!0};function D(e,t){do{e=e[t]}while(e&&1!==e.nodeType);return e}d.fn.extend({has:function(e){var t,n=d(e,this),r=n.length;return this.filter(function(){for(t=0;t<r;t++)if(d.contains(this,n[t]))return!0})},closest:function(e,t){for(var n,r=0,i=this.length,o=[],a=w.test(e)||"string"!=typeof e?d(e,t||this.context):0;r<i;r++)for(n=this[r];n&&n!==t;n=n.parentNode)if(n.nodeType<11&&(a?a.index(n)>-1:1===n.nodeType&&d.find.matchesSelector(n,e))){o.push(n);break}return this.pushStack(o.length>1?d.uniqueSort(o):o)},index:function(e){return e?"string"==typeof e?d.inArray(this[0],d(e)):d.inArray(e.jquery?e[0]:e,this):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(d.uniqueSort(d.merge(this.get(),d(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),d.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return x(e,"parentNode")},parentsUntil:function(e,t,n){return x(e,"parentNode",n)},next:function(e){return D(e,"nextSibling")},prev:function(e){return D(e,"previousSibling")},nextAll:function(e){return x(e,"nextSibling")},prevAll:function(e){return x(e,"previousSibling")},nextUntil:function(e,t,n){return x(e,"nextSibling",n)},prevUntil:function(e,t,n){return x(e,"previousSibling",n)},siblings:function(e){return b((e.parentNode||{}).firstChild,e)},children:function(e){return b(e.firstChild)},contents:function(e){return d.nodeName(e,"iframe")?e.contentDocument||e.contentWindow.document:d.merge([],e.childNodes)}},function(e,t){d.fn[e]=function(n,r){var i=d.map(this,t,n);return"Until"!==e.slice(-5)&&(r=n),r&&"string"==typeof r&&(i=d.filter(r,i)),this.length>1&&(A[e]||(i=d.uniqueSort(i)),S.test(e)&&(i=i.reverse())),this.pushStack(i)}});var j,L,H=/\S+/g;function q(){r.addEventListener?(r.removeEventListener("DOMContentLoaded",_),e.removeEventListener("load",_)):(r.detachEvent("onreadystatechange",_),e.detachEvent("onload",_))}function _(){(r.addEventListener||"load"===e.event.type||"complete"===r.readyState)&&(q(),d.ready())}for(L in d.Callbacks=function(e){e="string"==typeof e?function(e){var t={};return d.each(e.match(H)||[],function(e,n){t[n]=!0}),t}(e):d.extend({},e);var t,n,r,i,o=[],a=[],s=-1,u=function(){for(i=e.once,r=t=!0;a.length;s=-1)for(n=a.shift();++s<o.length;)!1===o[s].apply(n[0],n[1])&&e.stopOnFalse&&(s=o.length,n=!1);e.memory||(n=!1),t=!1,i&&(o=n?[]:"")},l={add:function(){return o&&(n&&!t&&(s=o.length-1,a.push(n)),function t(n){d.each(n,function(n,r){d.isFunction(r)?e.unique&&l.has(r)||o.push(r):r&&r.length&&"string"!==d.type(r)&&t(r)})}(arguments),n&&!t&&u()),this},remove:function(){return d.each(arguments,function(e,t){for(var n;(n=d.inArray(t,o,n))>-1;)o.splice(n,1),n<=s&&s--}),this},has:function(e){return e?d.inArray(e,o)>-1:o.length>0},empty:function(){return o&&(o=[]),this},disable:function(){return i=a=[],o=n="",this},disabled:function(){return!o},lock:function(){return i=!0,n||l.disable(),this},locked:function(){return!!i},fireWith:function(e,n){return i||(n=[e,(n=n||[]).slice?n.slice():n],a.push(n),t||u()),this},fire:function(){return l.fireWith(this,arguments),this},fired:function(){return!!r}};return l},d.extend({Deferred:function(e){var t=[["resolve","done",d.Callbacks("once memory"),"resolved"],["reject","fail",d.Callbacks("once memory"),"rejected"],["notify","progress",d.Callbacks("memory")]],n="pending",r={state:function(){return n},always:function(){return i.done(arguments).fail(arguments),this},then:function(){var e=arguments;return d.Deferred(function(n){d.each(t,function(t,o){var a=d.isFunction(e[t])&&e[t];i[o[1]](function(){var e=a&&a.apply(this,arguments);e&&d.isFunction(e.promise)?e.promise().progress(n.notify).done(n.resolve).fail(n.reject):n[o[0]+"With"](this===r?n.promise():this,a?[e]:arguments)})}),e=null}).promise()},promise:function(e){return null!=e?d.extend(e,r):r}},i={};return r.pipe=r.then,d.each(t,function(e,o){var a=o[2],s=o[3];r[o[1]]=a.add,s&&a.add(function(){n=s},t[1^e][2].disable,t[2][2].lock),i[o[0]]=function(){return i[o[0]+"With"](this===i?r:this,arguments),this},i[o[0]+"With"]=a.fireWith}),r.promise(i),e&&e.call(i,i),i},when:function(e){var t,n,r,o=0,a=i.call(arguments),s=a.length,u=1!==s||e&&d.isFunction(e.promise)?s:0,l=1===u?e:d.Deferred(),c=function(e,n,r){return function(o){n[e]=this,r[e]=arguments.length>1?i.call(arguments):o,r===t?l.notifyWith(n,r):--u||l.resolveWith(n,r)}};if(s>1)for(t=new Array(s),n=new Array(s),r=new Array(s);o<s;o++)a[o]&&d.isFunction(a[o].promise)?a[o].promise().progress(c(o,n,t)).done(c(o,r,a)).fail(l.reject):--u;return u||l.resolveWith(r,a),l.promise()}}),d.fn.ready=function(e){return d.ready.promise().done(e),this},d.extend({isReady:!1,readyWait:1,holdReady:function(e){e?d.readyWait++:d.ready(!0)},ready:function(e){(!0===e?--d.readyWait:d.isReady)||(d.isReady=!0,!0!==e&&--d.readyWait>0||(j.resolveWith(r,[d]),d.fn.triggerHandler&&(d(r).triggerHandler("ready"),d(r).off("ready"))))}}),d.ready.promise=function(t){if(!j)if(j=d.Deferred(),"complete"===r.readyState||"loading"!==r.readyState&&!r.documentElement.doScroll)e.setTimeout(d.ready);else if(r.addEventListener)r.addEventListener("DOMContentLoaded",_),e.addEventListener("load",_);else{r.attachEvent("onreadystatechange",_),e.attachEvent("onload",_);var n=!1;try{n=null==e.frameElement&&r.documentElement}catch(e){}n&&n.doScroll&&function t(){if(!d.isReady){try{n.doScroll("left")}catch(n){return e.setTimeout(t,50)}q(),d.ready()}}()}return j.promise(t)},d.ready.promise(),d(f))break;f.ownFirst="0"===L,f.inlineBlockNeedsLayout=!1,d(function(){var e,t,n,i;(n=r.getElementsByTagName("body")[0])&&n.style&&(t=r.createElement("div"),(i=r.createElement("div")).style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",n.appendChild(i).appendChild(t),void 0!==t.style.zoom&&(t.style.cssText="display:inline;margin:0;border:0;padding:1px;width:1px;zoom:1",f.inlineBlockNeedsLayout=e=3===t.offsetWidth,e&&(n.style.zoom=1)),n.removeChild(i))}),function(){var e=r.createElement("div");f.deleteExpando=!0;try{delete e.test}catch(e){f.deleteExpando=!1}e=null}();var M,F=function(e){var t=d.noData[(e.nodeName+" ").toLowerCase()],n=+e.nodeType||1;return(1===n||9===n)&&(!t||!0!==t&&e.getAttribute("classid")===t)},O=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,R=/([A-Z])/g;function P(e,t,n){if(void 0===n&&1===e.nodeType){var r="data-"+t.replace(R,"-$1").toLowerCase();if("string"==typeof(n=e.getAttribute(r))){try{n="true"===n||"false"!==n&&("null"===n?null:+n+""===n?+n:O.test(n)?d.parseJSON(n):n)}catch(e){}d.data(e,t,n)}else n=void 0}return n}function B(e){var t;for(t in e)if(("data"!==t||!d.isEmptyObject(e[t]))&&"toJSON"!==t)return!1;return!0}function W(e,t,r,i){if(F(e)){var o,a,s=d.expando,u=e.nodeType,l=u?d.cache:e,c=u?e[s]:e[s]&&s;if(c&&l[c]&&(i||l[c].data)||void 0!==r||"string"!=typeof t)return c||(c=u?e[s]=n.pop()||d.guid++:s),l[c]||(l[c]=u?{}:{toJSON:d.noop}),"object"!=typeof t&&"function"!=typeof t||(i?l[c]=d.extend(l[c],t):l[c].data=d.extend(l[c].data,t)),a=l[c],i||(a.data||(a.data={}),a=a.data),void 0!==r&&(a[d.camelCase(t)]=r),"string"==typeof t?null==(o=a[t])&&(o=a[d.camelCase(t)]):o=a,o}}function I(e,t,n){if(F(e)){var r,i,o=e.nodeType,a=o?d.cache:e,s=o?e[d.expando]:d.expando;if(a[s]){if(t&&(r=n?a[s]:a[s].data)){i=(t=d.isArray(t)?t.concat(d.map(t,d.camelCase)):t in r?[t]:(t=d.camelCase(t))in r?[t]:t.split(" ")).length;for(;i--;)delete r[t[i]];if(n?!B(r):!d.isEmptyObject(r))return}(n||(delete a[s].data,B(a[s])))&&(o?d.cleanData([e],!0):f.deleteExpando||a!=a.window?delete a[s]:a[s]=void 0)}}}d.extend({cache:{},noData:{"applet ":!0,"embed ":!0,"object ":"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"},hasData:function(e){return!!(e=e.nodeType?d.cache[e[d.expando]]:e[d.expando])&&!B(e)},data:function(e,t,n){return W(e,t,n)},removeData:function(e,t){return I(e,t)},_data:function(e,t,n){return W(e,t,n,!0)},_removeData:function(e,t){return I(e,t,!0)}}),d.fn.extend({data:function(e,t){var n,r,i,o=this[0],a=o&&o.attributes;if(void 0===e){if(this.length&&(i=d.data(o),1===o.nodeType&&!d._data(o,"parsedAttrs"))){for(n=a.length;n--;)a[n]&&0===(r=a[n].name).indexOf("data-")&&P(o,r=d.camelCase(r.slice(5)),i[r]);d._data(o,"parsedAttrs",!0)}return i}return"object"==typeof e?this.each(function(){d.data(this,e)}):arguments.length>1?this.each(function(){d.data(this,e,t)}):o?P(o,e,d.data(o,e)):void 0},removeData:function(e){return this.each(function(){d.removeData(this,e)})}}),d.extend({queue:function(e,t,n){var r;if(e)return t=(t||"fx")+"queue",r=d._data(e,t),n&&(!r||d.isArray(n)?r=d._data(e,t,d.makeArray(n)):r.push(n)),r||[]},dequeue:function(e,t){t=t||"fx";var n=d.queue(e,t),r=n.length,i=n.shift(),o=d._queueHooks(e,t);"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===t&&n.unshift("inprogress"),delete o.stop,i.call(e,function(){d.dequeue(e,t)},o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return d._data(e,n)||d._data(e,n,{empty:d.Callbacks("once memory").add(function(){d._removeData(e,t+"queue"),d._removeData(e,n)})})}}),d.fn.extend({queue:function(e,t){var n=2;return"string"!=typeof e&&(t=e,e="fx",n--),arguments.length<n?d.queue(this[0],e):void 0===t?this:this.each(function(){var n=d.queue(this,e,t);d._queueHooks(this,e),"fx"===e&&"inprogress"!==n[0]&&d.dequeue(this,e)})},dequeue:function(e){return this.each(function(){d.dequeue(this,e)})},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,t){var n,r=1,i=d.Deferred(),o=this,a=this.length,s=function(){--r||i.resolveWith(o,[o])};for("string"!=typeof e&&(t=e,e=void 0),e=e||"fx";a--;)(n=d._data(o[a],e+"queueHooks"))&&n.empty&&(r++,n.empty.add(s));return s(),i.promise(t)}}),f.shrinkWrapBlocks=function(){return null!=M?M:(M=!1,(t=r.getElementsByTagName("body")[0])&&t.style?(e=r.createElement("div"),(n=r.createElement("div")).style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",t.appendChild(n).appendChild(e),void 0!==e.style.zoom&&(e.style.cssText="-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",e.appendChild(r.createElement("div")).style.width="5px",M=3!==e.offsetWidth),t.removeChild(n),M):void 0);var e,t,n};var $=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,z=new RegExp("^(?:([+-])=|)("+$+")([a-z%]*)$","i"),X=["Top","Right","Bottom","Left"],U=function(e,t){return e=t||e,"none"===d.css(e,"display")||!d.contains(e.ownerDocument,e)};function V(e,t,n,r){var i,o=1,a=20,s=r?function(){return r.cur()}:function(){return d.css(e,t,"")},u=s(),l=n&&n[3]||(d.cssNumber[t]?"":"px"),c=(d.cssNumber[t]||"px"!==l&&+u)&&z.exec(d.css(e,t));if(c&&c[3]!==l){l=l||c[3],n=n||[],c=+u||1;do{c/=o=o||".5",d.style(e,t,c+l)}while(o!==(o=s()/u)&&1!==o&&--a)}return n&&(c=+c||+u||0,i=n[1]?c+(n[1]+1)*n[2]:+n[2],r&&(r.unit=l,r.start=c,r.end=i)),i}var Y,J,G,Q=function(e,t,n,r,i,o,a){var s=0,u=e.length,l=null==n;if("object"===d.type(n))for(s in i=!0,n)Q(e,t,s,n[s],!0,o,a);else if(void 0!==r&&(i=!0,d.isFunction(r)||(a=!0),l&&(a?(t.call(e,r),t=null):(l=t,t=function(e,t,n){return l.call(d(e),n)})),t))for(;s<u;s++)t(e[s],n,a?r:r.call(e[s],s,t(e[s],n)));return i?e:l?t.call(e):u?t(e[0],n):o},K=/^(?:checkbox|radio)$/i,Z=/<([\w:-]+)/,ee=/^$|\/(?:java|ecma)script/i,te=/^\s+/,ne="abbr|article|aside|audio|bdi|canvas|data|datalist|details|dialog|figcaption|figure|footer|header|hgroup|main|mark|meter|nav|output|picture|progress|section|summary|template|time|video";function re(e){var t=ne.split("|"),n=e.createDocumentFragment();if(n.createElement)for(;t.length;)n.createElement(t.pop());return n}Y=r.createElement("div"),J=r.createDocumentFragment(),G=r.createElement("input"),Y.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",f.leadingWhitespace=3===Y.firstChild.nodeType,f.tbody=!Y.getElementsByTagName("tbody").length,f.htmlSerialize=!!Y.getElementsByTagName("link").length,f.html5Clone="<:nav></:nav>"!==r.createElement("nav").cloneNode(!0).outerHTML,G.type="checkbox",G.checked=!0,J.appendChild(G),f.appendChecked=G.checked,Y.innerHTML="<textarea>x</textarea>",f.noCloneChecked=!!Y.cloneNode(!0).lastChild.defaultValue,Y.innerHTML="<option></option>",f.option=!!Y.lastChild,J.appendChild(Y),(G=r.createElement("input")).setAttribute("type","radio"),G.setAttribute("checked","checked"),G.setAttribute("name","t"),Y.appendChild(G),f.checkClone=Y.cloneNode(!0).cloneNode(!0).lastChild.checked,f.noCloneEvent=!!Y.addEventListener,Y[d.expando]=1,f.attributes=!Y.getAttribute(d.expando);var ie={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>"],_default:f.htmlSerialize?[0,"",""]:[1,"X<div>","</div>"]};function oe(e,t){var n,r,i=0,o=void 0!==e.getElementsByTagName?e.getElementsByTagName(t||"*"):void 0!==e.querySelectorAll?e.querySelectorAll(t||"*"):void 0;if(!o)for(o=[],n=e.childNodes||e;null!=(r=n[i]);i++)!t||d.nodeName(r,t)?o.push(r):d.merge(o,oe(r,t));return void 0===t||t&&d.nodeName(e,t)?d.merge([e],o):o}function ae(e,t){for(var n,r=0;null!=(n=e[r]);r++)d._data(n,"globalEval",!t||d._data(t[r],"globalEval"))}ie.tbody=ie.tfoot=ie.colgroup=ie.caption=ie.thead,ie.th=ie.td,f.option||(ie.optgroup=ie.option=[1,"<select multiple='multiple'>","</select>"]);var se=/<|&#?\w+;/,ue=/<tbody/i;function le(e){K.test(e.type)&&(e.defaultChecked=e.checked)}function ce(e,t,n,r,i){for(var o,a,s,u,l,c,p,h=e.length,g=re(t),m=[],v=0;v<h;v++)if((a=e[v])||0===a)if("object"===d.type(a))d.merge(m,a.nodeType?[a]:a);else if(se.test(a)){for(u=u||g.appendChild(t.createElement("div")),l=(Z.exec(a)||["",""])[1].toLowerCase(),p=ie[l]||ie._default,u.innerHTML=p[1]+d.htmlPrefilter(a)+p[2],o=p[0];o--;)u=u.lastChild;if(!f.leadingWhitespace&&te.test(a)&&m.push(t.createTextNode(te.exec(a)[0])),!f.tbody)for(o=(a="table"!==l||ue.test(a)?"<table>"!==p[1]||ue.test(a)?0:u:u.firstChild)&&a.childNodes.length;o--;)d.nodeName(c=a.childNodes[o],"tbody")&&!c.childNodes.length&&a.removeChild(c);for(d.merge(m,u.childNodes),u.textContent="";u.firstChild;)u.removeChild(u.firstChild);u=g.lastChild}else m.push(t.createTextNode(a));for(u&&g.removeChild(u),f.appendChecked||d.grep(oe(m,"input"),le),v=0;a=m[v++];)if(r&&d.inArray(a,r)>-1)i&&i.push(a);else if(s=d.contains(a.ownerDocument,a),u=oe(g.appendChild(a),"script"),s&&ae(u),n)for(o=0;a=u[o++];)ee.test(a.type||"")&&n.push(a);return u=null,g}!function(){var t,n,i=r.createElement("div");for(t in{submit:!0,change:!0,focusin:!0})n="on"+t,(f[t]=n in e)||(i.setAttribute(n,"t"),f[t]=!1===i.attributes[n].expando);i=null}();var fe=/^(?:input|select|textarea)$/i,de=/^key/,pe=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,he=/^(?:focusinfocus|focusoutblur)$/,ge=/^([^.]*)(?:\.(.+)|)/;function me(){return!0}function ve(){return!1}function ye(){try{return r.activeElement}catch(e){}}function xe(e,t,n,r,i,o){var a,s;if("object"==typeof t){for(s in"string"!=typeof n&&(r=r||n,n=void 0),t)xe(e,s,n,r,t[s],o);return e}if(null==r&&null==i?(i=n,r=n=void 0):null==i&&("string"==typeof n?(i=r,r=void 0):(i=r,r=n,n=void 0)),!1===i)i=ve;else if(!i)return e;return 1===o&&(a=i,(i=function(e){return d().off(e),a.apply(this,arguments)}).guid=a.guid||(a.guid=d.guid++)),e.each(function(){d.event.add(this,t,i,r,n)})}d.event={global:{},add:function(e,t,n,r,i){var o,a,s,u,l,c,f,p,h,g,m,v=d._data(e);if(v){for(n.handler&&(n=(u=n).handler,i=u.selector),n.guid||(n.guid=d.guid++),(a=v.events)||(a=v.events={}),(c=v.handle)||((c=v.handle=function(e){return void 0===d||e&&d.event.triggered===e.type?void 0:d.event.dispatch.apply(c.elem,arguments)}).elem=e),s=(t=(t||"").match(H)||[""]).length;s--;)h=m=(o=ge.exec(t[s])||[])[1],g=(o[2]||"").split(".").sort(),h&&(l=d.event.special[h]||{},h=(i?l.delegateType:l.bindType)||h,l=d.event.special[h]||{},f=d.extend({type:h,origType:m,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&d.expr.match.needsContext.test(i),namespace:g.join(".")},u),(p=a[h])||((p=a[h]=[]).delegateCount=0,l.setup&&!1!==l.setup.call(e,r,g,c)||(e.addEventListener?e.addEventListener(h,c,!1):e.attachEvent&&e.attachEvent("on"+h,c))),l.add&&(l.add.call(e,f),f.handler.guid||(f.handler.guid=n.guid)),i?p.splice(p.delegateCount++,0,f):p.push(f),d.event.global[h]=!0);e=null}},remove:function(e,t,n,r,i){var o,a,s,u,l,c,f,p,h,g,m,v=d.hasData(e)&&d._data(e);if(v&&(c=v.events)){for(l=(t=(t||"").match(H)||[""]).length;l--;)if(h=m=(s=ge.exec(t[l])||[])[1],g=(s[2]||"").split(".").sort(),h){for(f=d.event.special[h]||{},p=c[h=(r?f.delegateType:f.bindType)||h]||[],s=s[2]&&new RegExp("(^|\\.)"+g.join("\\.(?:.*\\.|)")+"(\\.|$)"),u=o=p.length;o--;)a=p[o],!i&&m!==a.origType||n&&n.guid!==a.guid||s&&!s.test(a.namespace)||r&&r!==a.selector&&("**"!==r||!a.selector)||(p.splice(o,1),a.selector&&p.delegateCount--,f.remove&&f.remove.call(e,a));u&&!p.length&&(f.teardown&&!1!==f.teardown.call(e,g,v.handle)||d.removeEvent(e,h,v.handle),delete c[h])}else for(h in c)d.event.remove(e,h+t[l],n,r,!0);d.isEmptyObject(c)&&(delete v.handle,d._removeData(e,"events"))}},trigger:function(t,n,i,o){var a,s,u,l,f,p,h,g=[i||r],m=c.call(t,"type")?t.type:t,v=c.call(t,"namespace")?t.namespace.split("."):[];if(u=p=i=i||r,3!==i.nodeType&&8!==i.nodeType&&!he.test(m+d.event.triggered)&&(m.indexOf(".")>-1&&(v=m.split("."),m=v.shift(),v.sort()),s=m.indexOf(":")<0&&"on"+m,(t=t[d.expando]?t:new d.Event(m,"object"==typeof t&&t)).isTrigger=o?2:3,t.namespace=v.join("."),t.rnamespace=t.namespace?new RegExp("(^|\\.)"+v.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,t.result=void 0,t.target||(t.target=i),n=null==n?[t]:d.makeArray(n,[t]),f=d.event.special[m]||{},o||!f.trigger||!1!==f.trigger.apply(i,n))){if(!o&&!f.noBubble&&!d.isWindow(i)){for(l=f.delegateType||m,he.test(l+m)||(u=u.parentNode);u;u=u.parentNode)g.push(u),p=u;p===(i.ownerDocument||r)&&g.push(p.defaultView||p.parentWindow||e)}for(h=0;(u=g[h++])&&!t.isPropagationStopped();)t.type=h>1?l:f.bindType||m,(a=(d._data(u,"events")||{})[t.type]&&d._data(u,"handle"))&&a.apply(u,n),(a=s&&u[s])&&a.apply&&F(u)&&(t.result=a.apply(u,n),!1===t.result&&t.preventDefault());if(t.type=m,!o&&!t.isDefaultPrevented()&&(!f._default||!1===f._default.apply(g.pop(),n))&&F(i)&&s&&i[m]&&!d.isWindow(i)){(p=i[s])&&(i[s]=null),d.event.triggered=m;try{i[m]()}catch(e){}d.event.triggered=void 0,p&&(i[s]=p)}return t.result}},dispatch:function(e){e=d.event.fix(e);var t,n,r,o,a,s,u=i.call(arguments),l=(d._data(this,"events")||{})[e.type]||[],c=d.event.special[e.type]||{};if(u[0]=e,e.delegateTarget=this,!c.preDispatch||!1!==c.preDispatch.call(this,e)){for(s=d.event.handlers.call(this,e,l),t=0;(o=s[t++])&&!e.isPropagationStopped();)for(e.currentTarget=o.elem,n=0;(a=o.handlers[n++])&&!e.isImmediatePropagationStopped();)e.rnamespace&&!e.rnamespace.test(a.namespace)||(e.handleObj=a,e.data=a.data,void 0!==(r=((d.event.special[a.origType]||{}).handle||a.handler).apply(o.elem,u))&&!1===(e.result=r)&&(e.preventDefault(),e.stopPropagation()));return c.postDispatch&&c.postDispatch.call(this,e),e.result}},handlers:function(e,t){var n,r,i,o,a=[],s=t.delegateCount,u=e.target;if(s&&u.nodeType&&("click"!==e.type||isNaN(e.button)||e.button<1))for(;u!=this;u=u.parentNode||this)if(1===u.nodeType&&(!0!==u.disabled||"click"!==e.type)){for(r=[],n=0;n<s;n++)void 0===r[i=(o=t[n]).selector+" "]&&(r[i]=o.needsContext?d(i,this).index(u)>-1:d.find(i,this,null,[u]).length),r[i]&&r.push(o);r.length&&a.push({elem:u,handlers:r})}return s<t.length&&a.push({elem:this,handlers:t.slice(s)}),a},fix:function(e){if(e[d.expando])return e;var t,n,i,o=e.type,a=e,s=this.fixHooks[o];for(s||(this.fixHooks[o]=s=pe.test(o)?this.mouseHooks:de.test(o)?this.keyHooks:{}),i=s.props?this.props.concat(s.props):this.props,e=new d.Event(a),t=i.length;t--;)e[n=i[t]]=a[n];return e.target||(e.target=a.srcElement||r),3===e.target.nodeType&&(e.target=e.target.parentNode),e.metaKey=!!e.metaKey,s.filter?s.filter(e,a):e},props:"altKey bubbles cancelable ctrlKey currentTarget detail eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(e,t){return null==e.which&&(e.which=null!=t.charCode?t.charCode:t.keyCode),e}},mouseHooks:{props:"button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(e,t){var n,i,o,a=t.button,s=t.fromElement;return null==e.pageX&&null!=t.clientX&&(o=(i=e.target.ownerDocument||r).documentElement,n=i.body,e.pageX=t.clientX+(o&&o.scrollLeft||n&&n.scrollLeft||0)-(o&&o.clientLeft||n&&n.clientLeft||0),e.pageY=t.clientY+(o&&o.scrollTop||n&&n.scrollTop||0)-(o&&o.clientTop||n&&n.clientTop||0)),!e.relatedTarget&&s&&(e.relatedTarget=s===e.target?t.toElement:s),e.which||void 0===a||(e.which=1&a?1:2&a?3:4&a?2:0),e}},special:{load:{noBubble:!0},focus:{trigger:function(){if(this!==ye()&&this.focus)try{return this.focus(),!1}catch(e){}},delegateType:"focusin"},blur:{trigger:function(){if(this===ye()&&this.blur)return this.blur(),!1},delegateType:"focusout"},click:{trigger:function(){if(d.nodeName(this,"input")&&"checkbox"===this.type&&this.click)return this.click(),!1},_default:function(e){return d.nodeName(e.target,"a")}},beforeunload:{postDispatch:function(e){void 0!==e.result&&e.originalEvent&&(e.originalEvent.returnValue=e.result)}}},simulate:function(e,t,n){var r=d.extend(new d.Event,n,{type:e,isSimulated:!0});d.event.trigger(r,null,t),r.isDefaultPrevented()&&n.preventDefault()}},d.removeEvent=r.removeEventListener?function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n)}:function(e,t,n){var r="on"+t;e.detachEvent&&(void 0===e[r]&&(e[r]=null),e.detachEvent(r,n))},d.Event=function(e,t){if(!(this instanceof d.Event))return new d.Event(e,t);e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||void 0===e.defaultPrevented&&!1===e.returnValue?me:ve):this.type=e,t&&d.extend(this,t),this.timeStamp=e&&e.timeStamp||d.now(),this[d.expando]=!0},d.Event.prototype={constructor:d.Event,isDefaultPrevented:ve,isPropagationStopped:ve,isImmediatePropagationStopped:ve,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=me,e&&(e.preventDefault?e.preventDefault():e.returnValue=!1)},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=me,e&&!this.isSimulated&&(e.stopPropagation&&e.stopPropagation(),e.cancelBubble=!0)},stopImmediatePropagation:function(){var e=this.originalEvent;this.isImmediatePropagationStopped=me,e&&e.stopImmediatePropagation&&e.stopImmediatePropagation(),this.stopPropagation()}},d.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(e,t){d.event.special[e]={delegateType:t,bindType:t,handle:function(e){var n,r=e.relatedTarget,i=e.handleObj;return r&&(r===this||d.contains(this,r))||(e.type=i.origType,n=i.handler.apply(this,arguments),e.type=t),n}}}),f.submit||(d.event.special.submit={setup:function(){if(d.nodeName(this,"form"))return!1;d.event.add(this,"click._submit keypress._submit",function(e){var t=e.target,n=d.nodeName(t,"input")||d.nodeName(t,"button")?d.prop(t,"form"):void 0;n&&!d._data(n,"submit")&&(d.event.add(n,"submit._submit",function(e){e._submitBubble=!0}),d._data(n,"submit",!0))})},postDispatch:function(e){e._submitBubble&&(delete e._submitBubble,this.parentNode&&!e.isTrigger&&d.event.simulate("submit",this.parentNode,e))},teardown:function(){if(d.nodeName(this,"form"))return!1;d.event.remove(this,"._submit")}}),f.change||(d.event.special.change={setup:function(){if(fe.test(this.nodeName))return"checkbox"!==this.type&&"radio"!==this.type||(d.event.add(this,"propertychange._change",function(e){"checked"===e.originalEvent.propertyName&&(this._justChanged=!0)}),d.event.add(this,"click._change",function(e){this._justChanged&&!e.isTrigger&&(this._justChanged=!1),d.event.simulate("change",this,e)})),!1;d.event.add(this,"beforeactivate._change",function(e){var t=e.target;fe.test(t.nodeName)&&!d._data(t,"change")&&(d.event.add(t,"change._change",function(e){!this.parentNode||e.isSimulated||e.isTrigger||d.event.simulate("change",this.parentNode,e)}),d._data(t,"change",!0))})},handle:function(e){var t=e.target;if(this!==t||e.isSimulated||e.isTrigger||"radio"!==t.type&&"checkbox"!==t.type)return e.handleObj.handler.apply(this,arguments)},teardown:function(){return d.event.remove(this,"._change"),!fe.test(this.nodeName)}}),f.focusin||d.each({focus:"focusin",blur:"focusout"},function(e,t){var n=function(e){d.event.simulate(t,e.target,d.event.fix(e))};d.event.special[t]={setup:function(){var r=this.ownerDocument||this,i=d._data(r,t);i||r.addEventListener(e,n,!0),d._data(r,t,(i||0)+1)},teardown:function(){var r=this.ownerDocument||this,i=d._data(r,t)-1;i?d._data(r,t,i):(r.removeEventListener(e,n,!0),d._removeData(r,t))}}}),d.fn.extend({on:function(e,t,n,r){return xe(this,e,t,n,r)},one:function(e,t,n,r){return xe(this,e,t,n,r,1)},off:function(e,t,n){var r,i;if(e&&e.preventDefault&&e.handleObj)return r=e.handleObj,d(e.delegateTarget).off(r.namespace?r.origType+"."+r.namespace:r.origType,r.selector,r.handler),this;if("object"==typeof e){for(i in e)this.off(i,t,e[i]);return this}return!1!==t&&"function"!=typeof t||(n=t,t=void 0),!1===n&&(n=ve),this.each(function(){d.event.remove(this,e,n,t)})},trigger:function(e,t){return this.each(function(){d.event.trigger(e,t,this)})},triggerHandler:function(e,t){var n=this[0];if(n)return d.event.trigger(e,t,n,!0)}});var be=/ jQuery\d+="(?:null|\d+)"/g,we=new RegExp("<(?:"+ne+")[\\s/>]","i"),Te=/<script|<style|<link/i,Ce=/checked\s*(?:[^=]|=\s*.checked.)/i,Ee=/^true\/(.*)/,Ne=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,ke=re(r).appendChild(r.createElement("div"));function Se(e,t){return d.nodeName(e,"table")&&d.nodeName(11!==t.nodeType?t:t.firstChild,"tr")?e.getElementsByTagName("tbody")[0]||e.appendChild(e.ownerDocument.createElement("tbody")):e}function Ae(e){return e.type=(null!==d.find.attr(e,"type"))+"/"+e.type,e}function De(e){var t=Ee.exec(e.type);return t?e.type=t[1]:e.removeAttribute("type"),e}function je(e,t){if(1===t.nodeType&&d.hasData(e)){var n,r,i,o=d._data(e),a=d._data(t,o),s=o.events;if(s)for(n in delete a.handle,a.events={},s)for(r=0,i=s[n].length;r<i;r++)d.event.add(t,n,s[n][r]);a.data&&(a.data=d.extend({},a.data))}}function Le(e,t){var n,r,i;if(1===t.nodeType){if(n=t.nodeName.toLowerCase(),!f.noCloneEvent&&t[d.expando]){for(r in(i=d._data(t)).events)d.removeEvent(t,r,i.handle);t.removeAttribute(d.expando)}"script"===n&&t.text!==e.text?(Ae(t).text=e.text,De(t)):"object"===n?(t.parentNode&&(t.outerHTML=e.outerHTML),f.html5Clone&&e.innerHTML&&!d.trim(t.innerHTML)&&(t.innerHTML=e.innerHTML)):"input"===n&&K.test(e.type)?(t.defaultChecked=t.checked=e.checked,t.value!==e.value&&(t.value=e.value)):"option"===n?t.defaultSelected=t.selected=e.defaultSelected:"input"!==n&&"textarea"!==n||(t.defaultValue=e.defaultValue)}}function He(e,t,n,r){t=o.apply([],t);var i,a,s,u,l,c,p=0,h=e.length,g=h-1,m=t[0],v=d.isFunction(m);if(v||h>1&&"string"==typeof m&&!f.checkClone&&Ce.test(m))return e.each(function(i){var o=e.eq(i);v&&(t[0]=m.call(this,i,o.html())),He(o,t,n,r)});if(h&&(i=(c=ce(t,e[0].ownerDocument,!1,e,r)).firstChild,1===c.childNodes.length&&(c=i),i||r)){for(s=(u=d.map(oe(c,"script"),Ae)).length;p<h;p++)a=c,p!==g&&(a=d.clone(a,!0,!0),s&&d.merge(u,oe(a,"script"))),n.call(e[p],a,p);if(s)for(l=u[u.length-1].ownerDocument,d.map(u,De),p=0;p<s;p++)a=u[p],ee.test(a.type||"")&&!d._data(a,"globalEval")&&d.contains(l,a)&&(a.src?d._evalUrl&&d._evalUrl(a.src):d.globalEval((a.text||a.textContent||a.innerHTML||"").replace(Ne,"")));c=i=null}return e}function qe(e,t,n){for(var r,i=t?d.filter(t,e):e,o=0;null!=(r=i[o]);o++)n||1!==r.nodeType||d.cleanData(oe(r)),r.parentNode&&(n&&d.contains(r.ownerDocument,r)&&ae(oe(r,"script")),r.parentNode.removeChild(r));return e}d.extend({htmlPrefilter:function(e){return e},clone:function(e,t,n){var r,i,o,a,s,u=d.contains(e.ownerDocument,e);if(f.html5Clone||d.isXMLDoc(e)||!we.test("<"+e.nodeName+">")?o=e.cloneNode(!0):(ke.innerHTML=e.outerHTML,ke.removeChild(o=ke.firstChild)),!(f.noCloneEvent&&f.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||d.isXMLDoc(e)))for(r=oe(o),s=oe(e),a=0;null!=(i=s[a]);++a)r[a]&&Le(i,r[a]);if(t)if(n)for(s=s||oe(e),r=r||oe(o),a=0;null!=(i=s[a]);a++)je(i,r[a]);else je(e,o);return(r=oe(o,"script")).length>0&&ae(r,!u&&oe(e,"script")),r=s=i=null,o},cleanData:function(e,t){for(var r,i,o,a,s=0,u=d.expando,l=d.cache,c=f.attributes,p=d.event.special;null!=(r=e[s]);s++)if((t||F(r))&&(a=(o=r[u])&&l[o])){if(a.events)for(i in a.events)p[i]?d.event.remove(r,i):d.removeEvent(r,i,a.handle);l[o]&&(delete l[o],c||void 0===r.removeAttribute?r[u]=void 0:r.removeAttribute(u),n.push(o))}}}),d.fn.extend({domManip:He,detach:function(e){return qe(this,e,!0)},remove:function(e){return qe(this,e)},text:function(e){return Q(this,function(e){return void 0===e?d.text(this):this.empty().append((this[0]&&this[0].ownerDocument||r).createTextNode(e))},null,e,arguments.length)},append:function(){return He(this,arguments,function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||Se(this,e).appendChild(e)})},prepend:function(){return He(this,arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=Se(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return He(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return He(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)})},empty:function(){for(var e,t=0;null!=(e=this[t]);t++){for(1===e.nodeType&&d.cleanData(oe(e,!1));e.firstChild;)e.removeChild(e.firstChild);e.options&&d.nodeName(e,"select")&&(e.options.length=0)}return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map(function(){return d.clone(this,e,t)})},html:function(e){return Q(this,function(e){var t=this[0]||{},n=0,r=this.length;if(void 0===e)return 1===t.nodeType?t.innerHTML.replace(be,""):void 0;if("string"==typeof e&&!Te.test(e)&&(f.htmlSerialize||!we.test(e))&&(f.leadingWhitespace||!te.test(e))&&!ie[(Z.exec(e)||["",""])[1].toLowerCase()]){e=d.htmlPrefilter(e);try{for(;n<r;n++)1===(t=this[n]||{}).nodeType&&(d.cleanData(oe(t,!1)),t.innerHTML=e);t=0}catch(e){}}t&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var e=[];return He(this,arguments,function(t){var n=this.parentNode;d.inArray(this,e)<0&&(d.cleanData(oe(this)),n&&n.replaceChild(t,this))},e)}}),d.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(e,t){d.fn[e]=function(e){for(var n,r=0,i=[],o=d(e),s=o.length-1;r<=s;r++)n=r===s?this:this.clone(!0),d(o[r])[t](n),a.apply(i,n.get());return this.pushStack(i)}});var _e,Me={HTML:"block",BODY:"block"};function Fe(e,t){var n=d(t.createElement(e)).appendTo(t.body),r=d.css(n[0],"display");return n.detach(),r}function Oe(e){var t=r,n=Me[e];return n||("none"!==(n=Fe(e,t))&&n||((t=((_e=(_e||d("<iframe frameborder='0' width='0' height='0'/>")).appendTo(t.documentElement))[0].contentWindow||_e[0].contentDocument).document).write(),t.close(),n=Fe(e,t),_e.detach()),Me[e]=n),n}var Re=/^margin/,Pe=new RegExp("^("+$+")(?!px)[a-z%]+$","i"),Be=function(e,t,n,r){var i,o,a={};for(o in t)a[o]=e.style[o],e.style[o]=t[o];for(o in i=n.apply(e,r||[]),t)e.style[o]=a[o];return i},We=r.documentElement;!function(){var t,n,i,o,a,s,u=r.createElement("div"),l=r.createElement("div");function c(){var c,f,d=r.documentElement;d.appendChild(u),l.style.cssText="-webkit-box-sizing:border-box;box-sizing:border-box;position:relative;display:block;margin:auto;border:1px;padding:1px;top:1%;width:50%",t=i=s=!1,n=a=!0,e.getComputedStyle&&(f=e.getComputedStyle(l),t="1%"!==(f||{}).top,s="2px"===(f||{}).marginLeft,i="4px"===(f||{width:"4px"}).width,l.style.marginRight="50%",n="4px"===(f||{marginRight:"4px"}).marginRight,(c=l.appendChild(r.createElement("div"))).style.cssText=l.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:0",c.style.marginRight=c.style.width="0",l.style.width="1px",a=!parseFloat((e.getComputedStyle(c)||{}).marginRight),l.removeChild(c)),l.style.display="none",(o=0===l.getClientRects().length)&&(l.style.display="",l.innerHTML="<table><tr><td></td><td>t</td></tr></table>",l.childNodes[0].style.borderCollapse="separate",(c=l.getElementsByTagName("td"))[0].style.cssText="margin:0;border:0;padding:0;display:none",(o=0===c[0].offsetHeight)&&(c[0].style.display="",c[1].style.display="none",o=0===c[0].offsetHeight)),d.removeChild(u)}l.style&&(l.style.cssText="float:left;opacity:.5",f.opacity="0.5"===l.style.opacity,f.cssFloat=!!l.style.cssFloat,l.style.backgroundClip="content-box",l.cloneNode(!0).style.backgroundClip="",f.clearCloneStyle="content-box"===l.style.backgroundClip,(u=r.createElement("div")).style.cssText="border:0;width:8px;height:0;top:0;left:-9999px;padding:0;margin-top:1px;position:absolute",l.innerHTML="",u.appendChild(l),f.boxSizing=""===l.style.boxSizing||""===l.style.MozBoxSizing||""===l.style.WebkitBoxSizing,d.extend(f,{reliableHiddenOffsets:function(){return null==t&&c(),o},boxSizingReliable:function(){return null==t&&c(),i},pixelMarginRight:function(){return null==t&&c(),n},pixelPosition:function(){return null==t&&c(),t},reliableMarginRight:function(){return null==t&&c(),a},reliableMarginLeft:function(){return null==t&&c(),s}}))}();var Ie,$e,ze=/^(top|right|bottom|left)$/;function Xe(e,t){return{get:function(){if(!e())return(this.get=t).apply(this,arguments);delete this.get}}}e.getComputedStyle?(Ie=function(t){var n=t.ownerDocument.defaultView;return n&&n.opener||(n=e),n.getComputedStyle(t)},$e=function(e,t,n){var r,i,o,a,s=e.style;return""!==(a=(n=n||Ie(e))?n.getPropertyValue(t)||n[t]:void 0)&&void 0!==a||d.contains(e.ownerDocument,e)||(a=d.style(e,t)),n&&!f.pixelMarginRight()&&Pe.test(a)&&Re.test(t)&&(r=s.width,i=s.minWidth,o=s.maxWidth,s.minWidth=s.maxWidth=s.width=a,a=n.width,s.width=r,s.minWidth=i,s.maxWidth=o),void 0===a?a:a+""}):We.currentStyle&&(Ie=function(e){return e.currentStyle},$e=function(e,t,n){var r,i,o,a,s=e.style;return null==(a=(n=n||Ie(e))?n[t]:void 0)&&s&&s[t]&&(a=s[t]),Pe.test(a)&&!ze.test(t)&&(r=s.left,(o=(i=e.runtimeStyle)&&i.left)&&(i.left=e.currentStyle.left),s.left="fontSize"===t?"1em":a,a=s.pixelLeft+"px",s.left=r,o&&(i.left=o)),void 0===a?a:a+""||"auto"});var Ue=/alpha\([^)]*\)/i,Ve=/opacity\s*=\s*([^)]*)/i,Ye=/^(none|table(?!-c[ea]).+)/,Je=new RegExp("^("+$+")(.*)$","i"),Ge={position:"absolute",visibility:"hidden",display:"block"},Qe={letterSpacing:"0",fontWeight:"400"},Ke=["Webkit","O","Moz","ms"],Ze=r.createElement("div").style;function et(e){if(e in Ze)return e;for(var t=e.charAt(0).toUpperCase()+e.slice(1),n=Ke.length;n--;)if((e=Ke[n]+t)in Ze)return e}function tt(e,t){for(var n,r,i,o=[],a=0,s=e.length;a<s;a++)(r=e[a]).style&&(o[a]=d._data(r,"olddisplay"),n=r.style.display,t?(o[a]||"none"!==n||(r.style.display=""),""===r.style.display&&U(r)&&(o[a]=d._data(r,"olddisplay",Oe(r.nodeName)))):(i=U(r),(n&&"none"!==n||!i)&&d._data(r,"olddisplay",i?n:d.css(r,"display"))));for(a=0;a<s;a++)(r=e[a]).style&&(t&&"none"!==r.style.display&&""!==r.style.display||(r.style.display=t?o[a]||"":"none"));return e}function nt(e,t,n){var r=Je.exec(t);return r?Math.max(0,r[1]-(n||0))+(r[2]||"px"):t}function rt(e,t,n,r,i){for(var o=n===(r?"border":"content")?4:"width"===t?1:0,a=0;o<4;o+=2)"margin"===n&&(a+=d.css(e,n+X[o],!0,i)),r?("content"===n&&(a-=d.css(e,"padding"+X[o],!0,i)),"margin"!==n&&(a-=d.css(e,"border"+X[o]+"Width",!0,i))):(a+=d.css(e,"padding"+X[o],!0,i),"padding"!==n&&(a+=d.css(e,"border"+X[o]+"Width",!0,i)));return a}function it(e,t,n){var r=!0,i="width"===t?e.offsetWidth:e.offsetHeight,o=Ie(e),a=f.boxSizing&&"border-box"===d.css(e,"boxSizing",!1,o);if(i<=0||null==i){if(((i=$e(e,t,o))<0||null==i)&&(i=e.style[t]),Pe.test(i))return i;r=a&&(f.boxSizingReliable()||i===e.style[t]),i=parseFloat(i)||0}return i+rt(e,t,n||(a?"border":"content"),r,o)+"px"}function ot(e,t,n,r,i){return new ot.prototype.init(e,t,n,r,i)}d.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=$e(e,"opacity");return""===n?"1":n}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{float:f.cssFloat?"cssFloat":"styleFloat"},style:function(e,t,n,r){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var i,o,a,s=d.camelCase(t),u=e.style;if(t=d.cssProps[s]||(d.cssProps[s]=et(s)||s),a=d.cssHooks[t]||d.cssHooks[s],void 0===n)return a&&"get"in a&&void 0!==(i=a.get(e,!1,r))?i:u[t];if("string"===(o=typeof n)&&(i=z.exec(n))&&i[1]&&(n=V(e,t,i),o="number"),null!=n&&n==n&&("number"===o&&(n+=i&&i[3]||(d.cssNumber[s]?"":"px")),f.clearCloneStyle||""!==n||0!==t.indexOf("background")||(u[t]="inherit"),!(a&&"set"in a&&void 0===(n=a.set(e,n,r)))))try{u[t]=n}catch(e){}}},css:function(e,t,n,r){var i,o,a,s=d.camelCase(t);return t=d.cssProps[s]||(d.cssProps[s]=et(s)||s),(a=d.cssHooks[t]||d.cssHooks[s])&&"get"in a&&(o=a.get(e,!0,n)),void 0===o&&(o=$e(e,t,r)),"normal"===o&&t in Qe&&(o=Qe[t]),""===n||n?(i=parseFloat(o),!0===n||isFinite(i)?i||0:o):o}}),d.each(["height","width"],function(e,t){d.cssHooks[t]={get:function(e,n,r){if(n)return Ye.test(d.css(e,"display"))&&0===e.offsetWidth?Be(e,Ge,function(){return it(e,t,r)}):it(e,t,r)},set:function(e,n,r){var i=r&&Ie(e);return nt(0,n,r?rt(e,t,r,f.boxSizing&&"border-box"===d.css(e,"boxSizing",!1,i),i):0)}}}),f.opacity||(d.cssHooks.opacity={get:function(e,t){return Ve.test((t&&e.currentStyle?e.currentStyle.filter:e.style.filter)||"")?.01*parseFloat(RegExp.$1)+"":t?"1":""},set:function(e,t){var n=e.style,r=e.currentStyle,i=d.isNumeric(t)?"alpha(opacity="+100*t+")":"",o=r&&r.filter||n.filter||"";n.zoom=1,(t>=1||""===t)&&""===d.trim(o.replace(Ue,""))&&n.removeAttribute&&(n.removeAttribute("filter"),""===t||r&&!r.filter)||(n.filter=Ue.test(o)?o.replace(Ue,i):o+" "+i)}}),d.cssHooks.marginRight=Xe(f.reliableMarginRight,function(e,t){if(t)return Be(e,{display:"inline-block"},$e,[e,"marginRight"])}),d.cssHooks.marginLeft=Xe(f.reliableMarginLeft,function(e,t){if(t)return(parseFloat($e(e,"marginLeft"))||(d.contains(e.ownerDocument,e)?e.getBoundingClientRect().left-Be(e,{marginLeft:0},function(){return e.getBoundingClientRect().left}):0))+"px"}),d.each({margin:"",padding:"",border:"Width"},function(e,t){d.cssHooks[e+t]={expand:function(n){for(var r=0,i={},o="string"==typeof n?n.split(" "):[n];r<4;r++)i[e+X[r]+t]=o[r]||o[r-2]||o[0];return i}},Re.test(e)||(d.cssHooks[e+t].set=nt)}),d.fn.extend({css:function(e,t){return Q(this,function(e,t,n){var r,i,o={},a=0;if(d.isArray(t)){for(r=Ie(e),i=t.length;a<i;a++)o[t[a]]=d.css(e,t[a],!1,r);return o}return void 0!==n?d.style(e,t,n):d.css(e,t)},e,t,arguments.length>1)},show:function(){return tt(this,!0)},hide:function(){return tt(this)},toggle:function(e){return"boolean"==typeof e?e?this.show():this.hide():this.each(function(){U(this)?d(this).show():d(this).hide()})}}),d.Tween=ot,ot.prototype={constructor:ot,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||d.easing._default,this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(d.cssNumber[n]?"":"px")},cur:function(){var e=ot.propHooks[this.prop];return e&&e.get?e.get(this):ot.propHooks._default.get(this)},run:function(e){var t,n=ot.propHooks[this.prop];return this.options.duration?this.pos=t=d.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):this.pos=t=e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):ot.propHooks._default.set(this),this}},ot.prototype.init.prototype=ot.prototype,ot.propHooks={_default:{get:function(e){var t;return 1!==e.elem.nodeType||null!=e.elem[e.prop]&&null==e.elem.style[e.prop]?e.elem[e.prop]:(t=d.css(e.elem,e.prop,""))&&"auto"!==t?t:0},set:function(e){d.fx.step[e.prop]?d.fx.step[e.prop](e):1!==e.elem.nodeType||null==e.elem.style[d.cssProps[e.prop]]&&!d.cssHooks[e.prop]?e.elem[e.prop]=e.now:d.style(e.elem,e.prop,e.now+e.unit)}}},ot.propHooks.scrollTop=ot.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},d.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},_default:"swing"},d.fx=ot.prototype.init,d.fx.step={};var at,st,ut=/^(?:toggle|show|hide)$/,lt=/queueHooks$/;function ct(){return e.setTimeout(function(){at=void 0}),at=d.now()}function ft(e,t){var n,r={height:e},i=0;for(t=t?1:0;i<4;i+=2-t)r["margin"+(n=X[i])]=r["padding"+n]=e;return t&&(r.opacity=r.width=e),r}function dt(e,t,n){for(var r,i=(pt.tweeners[t]||[]).concat(pt.tweeners["*"]),o=0,a=i.length;o<a;o++)if(r=i[o].call(n,t,e))return r}function pt(e,t,n){var r,i,o=0,a=pt.prefilters.length,s=d.Deferred().always(function(){delete u.elem}),u=function(){if(i)return!1;for(var t=at||ct(),n=Math.max(0,l.startTime+l.duration-t),r=1-(n/l.duration||0),o=0,a=l.tweens.length;o<a;o++)l.tweens[o].run(r);return s.notifyWith(e,[l,r,n]),r<1&&a?n:(s.resolveWith(e,[l]),!1)},l=s.promise({elem:e,props:d.extend({},t),opts:d.extend(!0,{specialEasing:{},easing:d.easing._default},n),originalProperties:t,originalOptions:n,startTime:at||ct(),duration:n.duration,tweens:[],createTween:function(t,n){var r=d.Tween(e,l.opts,t,n,l.opts.specialEasing[t]||l.opts.easing);return l.tweens.push(r),r},stop:function(t){var n=0,r=t?l.tweens.length:0;if(i)return this;for(i=!0;n<r;n++)l.tweens[n].run(1);return t?(s.notifyWith(e,[l,1,0]),s.resolveWith(e,[l,t])):s.rejectWith(e,[l,t]),this}}),c=l.props;for(!function(e,t){var n,r,i,o,a;for(n in e)if(i=t[r=d.camelCase(n)],o=e[n],d.isArray(o)&&(i=o[1],o=e[n]=o[0]),n!==r&&(e[r]=o,delete e[n]),(a=d.cssHooks[r])&&"expand"in a)for(n in o=a.expand(o),delete e[r],o)n in e||(e[n]=o[n],t[n]=i);else t[r]=i}(c,l.opts.specialEasing);o<a;o++)if(r=pt.prefilters[o].call(l,e,c,l.opts))return d.isFunction(r.stop)&&(d._queueHooks(l.elem,l.opts.queue).stop=d.proxy(r.stop,r)),r;return d.map(c,dt,l),d.isFunction(l.opts.start)&&l.opts.start.call(e,l),d.fx.timer(d.extend(u,{elem:e,anim:l,queue:l.opts.queue})),l.progress(l.opts.progress).done(l.opts.done,l.opts.complete).fail(l.opts.fail).always(l.opts.always)}d.Animation=d.extend(pt,{tweeners:{"*":[function(e,t){var n=this.createTween(e,t);return V(n.elem,e,z.exec(t),n),n}]},tweener:function(e,t){d.isFunction(e)?(t=e,e=["*"]):e=e.match(H);for(var n,r=0,i=e.length;r<i;r++)n=e[r],pt.tweeners[n]=pt.tweeners[n]||[],pt.tweeners[n].unshift(t)},prefilters:[function(e,t,n){var r,i,o,a,s,u,l,c=this,p={},h=e.style,g=e.nodeType&&U(e),m=d._data(e,"fxshow");for(r in n.queue||(null==(s=d._queueHooks(e,"fx")).unqueued&&(s.unqueued=0,u=s.empty.fire,s.empty.fire=function(){s.unqueued||u()}),s.unqueued++,c.always(function(){c.always(function(){s.unqueued--,d.queue(e,"fx").length||s.empty.fire()})})),1===e.nodeType&&("height"in t||"width"in t)&&(n.overflow=[h.overflow,h.overflowX,h.overflowY],"inline"===("none"===(l=d.css(e,"display"))?d._data(e,"olddisplay")||Oe(e.nodeName):l)&&"none"===d.css(e,"float")&&(f.inlineBlockNeedsLayout&&"inline"!==Oe(e.nodeName)?h.zoom=1:h.display="inline-block")),n.overflow&&(h.overflow="hidden",f.shrinkWrapBlocks()||c.always(function(){h.overflow=n.overflow[0],h.overflowX=n.overflow[1],h.overflowY=n.overflow[2]})),t)if(i=t[r],ut.exec(i)){if(delete t[r],o=o||"toggle"===i,i===(g?"hide":"show")){if("show"!==i||!m||void 0===m[r])continue;g=!0}p[r]=m&&m[r]||d.style(e,r)}else l=void 0;if(d.isEmptyObject(p))"inline"===("none"===l?Oe(e.nodeName):l)&&(h.display=l);else for(r in m?"hidden"in m&&(g=m.hidden):m=d._data(e,"fxshow",{}),o&&(m.hidden=!g),g?d(e).show():c.done(function(){d(e).hide()}),c.done(function(){var t;for(t in d._removeData(e,"fxshow"),p)d.style(e,t,p[t])}),p)a=dt(g?m[r]:0,r,c),r in m||(m[r]=a.start,g&&(a.end=a.start,a.start="width"===r||"height"===r?1:0))}],prefilter:function(e,t){t?pt.prefilters.unshift(e):pt.prefilters.push(e)}}),d.speed=function(e,t,n){var r=e&&"object"==typeof e?d.extend({},e):{complete:n||!n&&t||d.isFunction(e)&&e,duration:e,easing:n&&t||t&&!d.isFunction(t)&&t};return r.duration=d.fx.off?0:"number"==typeof r.duration?r.duration:r.duration in d.fx.speeds?d.fx.speeds[r.duration]:d.fx.speeds._default,null!=r.queue&&!0!==r.queue||(r.queue="fx"),r.old=r.complete,r.complete=function(){d.isFunction(r.old)&&r.old.call(this),r.queue&&d.dequeue(this,r.queue)},r},d.fn.extend({fadeTo:function(e,t,n,r){return this.filter(U).css("opacity",0).show().end().animate({opacity:t},e,n,r)},animate:function(e,t,n,r){var i=d.isEmptyObject(e),o=d.speed(t,n,r),a=function(){var t=pt(this,d.extend({},e),o);(i||d._data(this,"finish"))&&t.stop(!0)};return a.finish=a,i||!1===o.queue?this.each(a):this.queue(o.queue,a)},stop:function(e,t,n){var r=function(e){var t=e.stop;delete e.stop,t(n)};return"string"!=typeof e&&(n=t,t=e,e=void 0),t&&!1!==e&&this.queue(e||"fx",[]),this.each(function(){var t=!0,i=null!=e&&e+"queueHooks",o=d.timers,a=d._data(this);if(i)a[i]&&a[i].stop&&r(a[i]);else for(i in a)a[i]&&a[i].stop&&lt.test(i)&&r(a[i]);for(i=o.length;i--;)o[i].elem!==this||null!=e&&o[i].queue!==e||(o[i].anim.stop(n),t=!1,o.splice(i,1));!t&&n||d.dequeue(this,e)})},finish:function(e){return!1!==e&&(e=e||"fx"),this.each(function(){var t,n=d._data(this),r=n[e+"queue"],i=n[e+"queueHooks"],o=d.timers,a=r?r.length:0;for(n.finish=!0,d.queue(this,e,[]),i&&i.stop&&i.stop.call(this,!0),t=o.length;t--;)o[t].elem===this&&o[t].queue===e&&(o[t].anim.stop(!0),o.splice(t,1));for(t=0;t<a;t++)r[t]&&r[t].finish&&r[t].finish.call(this);delete n.finish})}}),d.each(["toggle","show","hide"],function(e,t){var n=d.fn[t];d.fn[t]=function(e,r,i){return null==e||"boolean"==typeof e?n.apply(this,arguments):this.animate(ft(t,!0),e,r,i)}}),d.each({slideDown:ft("show"),slideUp:ft("hide"),slideToggle:ft("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(e,t){d.fn[e]=function(e,n,r){return this.animate(t,e,n,r)}}),d.timers=[],d.fx.tick=function(){var e,t=d.timers,n=0;for(at=d.now();n<t.length;n++)(e=t[n])()||t[n]!==e||t.splice(n--,1);t.length||d.fx.stop(),at=void 0},d.fx.timer=function(e){d.timers.push(e),e()?d.fx.start():d.timers.pop()},d.fx.interval=13,d.fx.start=function(){st||(st=e.setInterval(d.fx.tick,d.fx.interval))},d.fx.stop=function(){e.clearInterval(st),st=null},d.fx.speeds={slow:600,fast:200,_default:400},d.fn.delay=function(t,n){return t=d.fx&&d.fx.speeds[t]||t,n=n||"fx",this.queue(n,function(n,r){var i=e.setTimeout(n,t);r.stop=function(){e.clearTimeout(i)}})},function(){var e,t=r.createElement("input"),n=r.createElement("div"),i=r.createElement("select"),o=i.appendChild(r.createElement("option"));(n=r.createElement("div")).setAttribute("className","t"),n.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",e=n.getElementsByTagName("a")[0],t.setAttribute("type","checkbox"),n.appendChild(t),(e=n.getElementsByTagName("a")[0]).style.cssText="top:1px",f.getSetAttribute="t"!==n.className,f.style=/top/.test(e.getAttribute("style")),f.hrefNormalized="/a"===e.getAttribute("href"),f.checkOn=!!t.value,f.optSelected=o.selected,f.enctype=!!r.createElement("form").enctype,i.disabled=!0,f.optDisabled=!o.disabled,(t=r.createElement("input")).setAttribute("value",""),f.input=""===t.getAttribute("value"),t.value="t",t.setAttribute("type","radio"),f.radioValue="t"===t.value}();var ht=/\r/g,gt=/[\x20\t\r\n\f]+/g;d.fn.extend({val:function(e){var t,n,r,i=this[0];return arguments.length?(r=d.isFunction(e),this.each(function(n){var i;1===this.nodeType&&(null==(i=r?e.call(this,n,d(this).val()):e)?i="":"number"==typeof i?i+="":d.isArray(i)&&(i=d.map(i,function(e){return null==e?"":e+""})),(t=d.valHooks[this.type]||d.valHooks[this.nodeName.toLowerCase()])&&"set"in t&&void 0!==t.set(this,i,"value")||(this.value=i))})):i?(t=d.valHooks[i.type]||d.valHooks[i.nodeName.toLowerCase()])&&"get"in t&&void 0!==(n=t.get(i,"value"))?n:"string"==typeof(n=i.value)?n.replace(ht,""):null==n?"":n:void 0}}),d.extend({valHooks:{option:{get:function(e){var t=d.find.attr(e,"value");return null!=t?t:d.trim(d.text(e)).replace(gt," ")}},select:{get:function(e){for(var t,n,r=e.options,i=e.selectedIndex,o="select-one"===e.type||i<0,a=o?null:[],s=o?i+1:r.length,u=i<0?s:o?i:0;u<s;u++)if(((n=r[u]).selected||u===i)&&(f.optDisabled?!n.disabled:null===n.getAttribute("disabled"))&&(!n.parentNode.disabled||!d.nodeName(n.parentNode,"optgroup"))){if(t=d(n).val(),o)return t;a.push(t)}return a},set:function(e,t){for(var n,r,i=e.options,o=d.makeArray(t),a=i.length;a--;)if(r=i[a],d.inArray(d.valHooks.option.get(r),o)>-1)try{r.selected=n=!0}catch(e){r.scrollHeight}else r.selected=!1;return n||(e.selectedIndex=-1),i}}}}),d.each(["radio","checkbox"],function(){d.valHooks[this]={set:function(e,t){if(d.isArray(t))return e.checked=d.inArray(d(e).val(),t)>-1}},f.checkOn||(d.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})});var mt,vt,yt=d.expr.attrHandle,xt=/^(?:checked|selected)$/i,bt=f.getSetAttribute,wt=f.input;d.fn.extend({attr:function(e,t){return Q(this,d.attr,e,t,arguments.length>1)},removeAttr:function(e){return this.each(function(){d.removeAttr(this,e)})}}),d.extend({attr:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return void 0===e.getAttribute?d.prop(e,t,n):(1===o&&d.isXMLDoc(e)||(t=t.toLowerCase(),i=d.attrHooks[t]||(d.expr.match.bool.test(t)?vt:mt)),void 0!==n?null===n?void d.removeAttr(e,t):i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:(e.setAttribute(t,n+""),n):i&&"get"in i&&null!==(r=i.get(e,t))?r:null==(r=d.find.attr(e,t))?void 0:r)},attrHooks:{type:{set:function(e,t){if(!f.radioValue&&"radio"===t&&d.nodeName(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}},removeAttr:function(e,t){var n,r,i=0,o=t&&t.match(H);if(o&&1===e.nodeType)for(;n=o[i++];)r=d.propFix[n]||n,d.expr.match.bool.test(n)?wt&&bt||!xt.test(n)?e[r]=!1:e[d.camelCase("default-"+n)]=e[r]=!1:d.attr(e,n,""),e.removeAttribute(bt?n:r)}}),vt={set:function(e,t,n){return!1===t?d.removeAttr(e,n):wt&&bt||!xt.test(n)?e.setAttribute(!bt&&d.propFix[n]||n,n):e[d.camelCase("default-"+n)]=e[n]=!0,n}},d.each(d.expr.match.bool.source.match(/\w+/g),function(e,t){var n=yt[t]||d.find.attr;wt&&bt||!xt.test(t)?yt[t]=function(e,t,r){var i,o;return r||(o=yt[t],yt[t]=i,i=null!=n(e,t,r)?t.toLowerCase():null,yt[t]=o),i}:yt[t]=function(e,t,n){if(!n)return e[d.camelCase("default-"+t)]?t.toLowerCase():null}}),wt&&bt||(d.attrHooks.value={set:function(e,t,n){if(!d.nodeName(e,"input"))return mt&&mt.set(e,t,n);e.defaultValue=t}}),bt||(mt={set:function(e,t,n){var r=e.getAttributeNode(n);if(r||e.setAttributeNode(r=e.ownerDocument.createAttribute(n)),r.value=t+="","value"===n||t===e.getAttribute(n))return t}},yt.id=yt.name=yt.coords=function(e,t,n){var r;if(!n)return(r=e.getAttributeNode(t))&&""!==r.value?r.value:null},d.valHooks.button={get:function(e,t){var n=e.getAttributeNode(t);if(n&&n.specified)return n.value},set:mt.set},d.attrHooks.contenteditable={set:function(e,t,n){mt.set(e,""!==t&&t,n)}},d.each(["width","height"],function(e,t){d.attrHooks[t]={set:function(e,n){if(""===n)return e.setAttribute(t,"auto"),n}}})),f.style||(d.attrHooks.style={get:function(e){return e.style.cssText||void 0},set:function(e,t){return e.style.cssText=t+""}});var Tt=/^(?:input|select|textarea|button|object)$/i,Ct=/^(?:a|area)$/i;d.fn.extend({prop:function(e,t){return Q(this,d.prop,e,t,arguments.length>1)},removeProp:function(e){return e=d.propFix[e]||e,this.each(function(){try{this[e]=void 0,delete this[e]}catch(e){}})}}),d.extend({prop:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&d.isXMLDoc(e)||(t=d.propFix[t]||t,i=d.propHooks[t]),void 0!==n?i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:e[t]=n:i&&"get"in i&&null!==(r=i.get(e,t))?r:e[t]},propHooks:{tabIndex:{get:function(e){var t=d.find.attr(e,"tabindex");return t?parseInt(t,10):Tt.test(e.nodeName)||Ct.test(e.nodeName)&&e.href?0:-1}}},propFix:{for:"htmlFor",class:"className"}}),f.hrefNormalized||d.each(["href","src"],function(e,t){d.propHooks[t]={get:function(e){return e.getAttribute(t,4)}}}),f.optSelected||(d.propHooks.selected={get:function(e){var t=e.parentNode;return t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex),null},set:function(e){var t=e.parentNode;t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex)}}),d.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){d.propFix[this.toLowerCase()]=this}),f.enctype||(d.propFix.enctype="encoding");var Et=/[\t\r\n\f]/g;function Nt(e){return d.attr(e,"class")||""}d.fn.extend({addClass:function(e){var t,n,r,i,o,a,s,u=0;if(d.isFunction(e))return this.each(function(t){d(this).addClass(e.call(this,t,Nt(this)))});if("string"==typeof e&&e)for(t=e.match(H)||[];n=this[u++];)if(i=Nt(n),r=1===n.nodeType&&(" "+i+" ").replace(Et," ")){for(a=0;o=t[a++];)r.indexOf(" "+o+" ")<0&&(r+=o+" ");i!==(s=d.trim(r))&&d.attr(n,"class",s)}return this},removeClass:function(e){var t,n,r,i,o,a,s,u=0;if(d.isFunction(e))return this.each(function(t){d(this).removeClass(e.call(this,t,Nt(this)))});if(!arguments.length)return this.attr("class","");if("string"==typeof e&&e)for(t=e.match(H)||[];n=this[u++];)if(i=Nt(n),r=1===n.nodeType&&(" "+i+" ").replace(Et," ")){for(a=0;o=t[a++];)for(;r.indexOf(" "+o+" ")>-1;)r=r.replace(" "+o+" "," ");i!==(s=d.trim(r))&&d.attr(n,"class",s)}return this},toggleClass:function(e,t){var n=typeof e;return"boolean"==typeof t&&"string"===n?t?this.addClass(e):this.removeClass(e):d.isFunction(e)?this.each(function(n){d(this).toggleClass(e.call(this,n,Nt(this),t),t)}):this.each(function(){var t,r,i,o;if("string"===n)for(r=0,i=d(this),o=e.match(H)||[];t=o[r++];)i.hasClass(t)?i.removeClass(t):i.addClass(t);else void 0!==e&&"boolean"!==n||((t=Nt(this))&&d._data(this,"__className__",t),d.attr(this,"class",t||!1===e?"":d._data(this,"__className__")||""))})},hasClass:function(e){var t,n,r=0;for(t=" "+e+" ";n=this[r++];)if(1===n.nodeType&&(" "+Nt(n)+" ").replace(Et," ").indexOf(t)>-1)return!0;return!1}}),d.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(e,t){d.fn[t]=function(e,n){return arguments.length>0?this.on(t,null,e,n):this.trigger(t)}}),d.fn.extend({hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}});var kt=e.location,St=d.now(),At=/\?/,Dt=/(,)|(\[|{)|(}|])|"(?:[^"\\\r\n]|\\["\\\/bfnrt]|\\u[\da-fA-F]{4})*"\s*:?|true|false|null|-?(?!0\d)\d+(?:\.\d+|)(?:[eE][+-]?\d+|)/g;d.parseJSON=function(t){if(e.JSON&&e.JSON.parse)return e.JSON.parse(t+"");var n,r=null,i=d.trim(t+"");return i&&!d.trim(i.replace(Dt,function(e,t,i,o){return n&&t&&(r=0),0===r?e:(n=i||t,r+=!o-!i,"")}))?Function("return "+i)():d.error("Invalid JSON: "+t)},d.parseXML=function(t){var n;if(!t||"string"!=typeof t)return null;try{e.DOMParser?n=(new e.DOMParser).parseFromString(t,"text/xml"):((n=new e.ActiveXObject("Microsoft.XMLDOM")).async="false",n.loadXML(t))}catch(e){n=void 0}return n&&n.documentElement&&!n.getElementsByTagName("parsererror").length||d.error("Invalid XML: "+t),n};var jt=/#.*$/,Lt=/([?&])_=[^&]*/,Ht=/^(.*?):[ \t]*([^\r\n]*)\r?$/gm,qt=/^(?:GET|HEAD)$/,_t=/^\/\//,Mt=/^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/,Ft={},Ot={},Rt="*/".concat("*"),Pt=kt.href,Bt=Mt.exec(Pt.toLowerCase())||[];function Wt(e){return function(t,n){"string"!=typeof t&&(n=t,t="*");var r,i=0,o=t.toLowerCase().match(H)||[];if(d.isFunction(n))for(;r=o[i++];)"+"===r.charAt(0)?(r=r.slice(1)||"*",(e[r]=e[r]||[]).unshift(n)):(e[r]=e[r]||[]).push(n)}}function It(e,t,n,r){var i={},o=e===Ot;function a(s){var u;return i[s]=!0,d.each(e[s]||[],function(e,s){var l=s(t,n,r);return"string"!=typeof l||o||i[l]?o?!(u=l):void 0:(t.dataTypes.unshift(l),a(l),!1)}),u}return a(t.dataTypes[0])||!i["*"]&&a("*")}function $t(e,t){var n,r,i=d.ajaxSettings.flatOptions||{};for(r in t)void 0!==t[r]&&((i[r]?e:n||(n={}))[r]=t[r]);return n&&d.extend(!0,e,n),e}function zt(e){return e.style&&e.style.display||d.css(e,"display")}d.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Pt,type:"GET",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(Bt[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Rt,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":d.parseJSON,"text xml":d.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?$t($t(e,d.ajaxSettings),t):$t(d.ajaxSettings,e)},ajaxPrefilter:Wt(Ft),ajaxTransport:Wt(Ot),ajax:function(t,n){"object"==typeof t&&(n=t,t=void 0),n=n||{};var r,i,o,a,s,u,l,c,f=d.ajaxSetup({},n),p=f.context||f,h=f.context&&(p.nodeType||p.jquery)?d(p):d.event,g=d.Deferred(),m=d.Callbacks("once memory"),v=f.statusCode||{},y={},x={},b=0,w="canceled",T={readyState:0,getResponseHeader:function(e){var t;if(2===b){if(!c)for(c={};t=Ht.exec(a);)c[t[1].toLowerCase()]=t[2];t=c[e.toLowerCase()]}return null==t?null:t},getAllResponseHeaders:function(){return 2===b?a:null},setRequestHeader:function(e,t){var n=e.toLowerCase();return b||(e=x[n]=x[n]||e,y[e]=t),this},overrideMimeType:function(e){return b||(f.mimeType=e),this},statusCode:function(e){var t;if(e)if(b<2)for(t in e)v[t]=[v[t],e[t]];else T.always(e[T.status]);return this},abort:function(e){var t=e||w;return l&&l.abort(t),C(0,t),this}};if(g.promise(T).complete=m.add,T.success=T.done,T.error=T.fail,f.url=((t||f.url||Pt)+"").replace(jt,"").replace(_t,Bt[1]+"//"),f.type=n.method||n.type||f.method||f.type,f.dataTypes=d.trim(f.dataType||"*").toLowerCase().match(H)||[""],null==f.crossDomain&&(r=Mt.exec(f.url.toLowerCase()),f.crossDomain=!(!r||r[1]===Bt[1]&&r[2]===Bt[2]&&(r[3]||("http:"===r[1]?"80":"443"))===(Bt[3]||("http:"===Bt[1]?"80":"443")))),f.data&&f.processData&&"string"!=typeof f.data&&(f.data=d.param(f.data,f.traditional)),It(Ft,f,n,T),2===b)return T;for(i in(u=d.event&&f.global)&&0==d.active++&&d.event.trigger("ajaxStart"),f.type=f.type.toUpperCase(),f.hasContent=!qt.test(f.type),o=f.url,f.hasContent||(f.data&&(o=f.url+=(At.test(o)?"&":"?")+f.data,delete f.data),!1===f.cache&&(f.url=Lt.test(o)?o.replace(Lt,"$1_="+St++):o+(At.test(o)?"&":"?")+"_="+St++)),f.ifModified&&(d.lastModified[o]&&T.setRequestHeader("If-Modified-Since",d.lastModified[o]),d.etag[o]&&T.setRequestHeader("If-None-Match",d.etag[o])),(f.data&&f.hasContent&&!1!==f.contentType||n.contentType)&&T.setRequestHeader("Content-Type",f.contentType),T.setRequestHeader("Accept",f.dataTypes[0]&&f.accepts[f.dataTypes[0]]?f.accepts[f.dataTypes[0]]+("*"!==f.dataTypes[0]?", "+Rt+"; q=0.01":""):f.accepts["*"]),f.headers)T.setRequestHeader(i,f.headers[i]);if(f.beforeSend&&(!1===f.beforeSend.call(p,T,f)||2===b))return T.abort();for(i in w="abort",{success:1,error:1,complete:1})T[i](f[i]);if(l=It(Ot,f,n,T)){if(T.readyState=1,u&&h.trigger("ajaxSend",[T,f]),2===b)return T;f.async&&f.timeout>0&&(s=e.setTimeout(function(){T.abort("timeout")},f.timeout));try{b=1,l.send(y,C)}catch(e){if(!(b<2))throw e;C(-1,e)}}else C(-1,"No Transport");function C(t,n,r,i){var c,y,x,w,C,E=n;2!==b&&(b=2,s&&e.clearTimeout(s),l=void 0,a=i||"",T.readyState=t>0?4:0,c=t>=200&&t<300||304===t,r&&(w=function(e,t,n){for(var r,i,o,a,s=e.contents,u=e.dataTypes;"*"===u[0];)u.shift(),void 0===i&&(i=e.mimeType||t.getResponseHeader("Content-Type"));if(i)for(a in s)if(s[a]&&s[a].test(i)){u.unshift(a);break}if(u[0]in n)o=u[0];else{for(a in n){if(!u[0]||e.converters[a+" "+u[0]]){o=a;break}r||(r=a)}o=o||r}if(o)return o!==u[0]&&u.unshift(o),n[o]}(f,T,r)),w=function(e,t,n,r){var i,o,a,s,u,l={},c=e.dataTypes.slice();if(c[1])for(a in e.converters)l[a.toLowerCase()]=e.converters[a];for(o=c.shift();o;)if(e.responseFields[o]&&(n[e.responseFields[o]]=t),!u&&r&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),u=o,o=c.shift())if("*"===o)o=u;else if("*"!==u&&u!==o){if(e.crossDomain&&"script"===o)continue;if(!(a=l[u+" "+o]||l["* "+o]))for(i in l)if((s=i.split(" "))[1]===o&&(a=l[u+" "+s[0]]||l["* "+s[0]])){!0===a?a=l[i]:!0!==l[i]&&(o=s[0],c.unshift(s[1]));break}if(!0!==a)if(a&&e.throws)t=a(t);else try{t=a(t)}catch(e){return{state:"parsererror",error:a?e:"No conversion from "+u+" to "+o}}}return{state:"success",data:t}}(f,w,T,c),c?(f.ifModified&&((C=T.getResponseHeader("Last-Modified"))&&(d.lastModified[o]=C),(C=T.getResponseHeader("etag"))&&(d.etag[o]=C)),204===t||"HEAD"===f.type?E="nocontent":304===t?E="notmodified":(E=w.state,y=w.data,c=!(x=w.error))):(x=E,!t&&E||(E="error",t<0&&(t=0))),T.status=t,T.statusText=(n||E)+"",c?g.resolveWith(p,[y,E,T]):g.rejectWith(p,[T,E,x]),T.statusCode(v),v=void 0,u&&h.trigger(c?"ajaxSuccess":"ajaxError",[T,f,c?y:x]),m.fireWith(p,[T,E]),u&&(h.trigger("ajaxComplete",[T,f]),--d.active||d.event.trigger("ajaxStop")))}return T},getJSON:function(e,t,n){return d.get(e,t,n,"json")},getScript:function(e,t){return d.get(e,void 0,t,"script")}}),d.each(["get","post"],function(e,t){d[t]=function(e,n,r,i){return d.isFunction(n)&&(i=i||r,r=n,n=void 0),d.ajax(d.extend({url:e,type:t,dataType:i,data:n,success:r},d.isPlainObject(e)&&e))}}),d._evalUrl=function(e){return d.ajax({url:e,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,throws:!0})},d.fn.extend({wrapAll:function(e){if(d.isFunction(e))return this.each(function(t){d(this).wrapAll(e.call(this,t))});if(this[0]){var t=d(e,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){for(var e=this;e.firstChild&&1===e.firstChild.nodeType;)e=e.firstChild;return e}).append(this)}return this},wrapInner:function(e){return d.isFunction(e)?this.each(function(t){d(this).wrapInner(e.call(this,t))}):this.each(function(){var t=d(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)})},wrap:function(e){var t=d.isFunction(e);return this.each(function(n){d(this).wrapAll(t?e.call(this,n):e)})},unwrap:function(){return this.parent().each(function(){d.nodeName(this,"body")||d(this).replaceWith(this.childNodes)}).end()}}),d.expr.filters.hidden=function(e){return f.reliableHiddenOffsets()?e.offsetWidth<=0&&e.offsetHeight<=0&&!e.getClientRects().length:function(e){if(!d.contains(e.ownerDocument||r,e))return!0;for(;e&&1===e.nodeType;){if("none"===zt(e)||"hidden"===e.type)return!0;e=e.parentNode}return!1}(e)},d.expr.filters.visible=function(e){return!d.expr.filters.hidden(e)};var Xt=/%20/g,Ut=/\[\]$/,Vt=/\r?\n/g,Yt=/^(?:submit|button|image|reset|file)$/i,Jt=/^(?:input|select|textarea|keygen)/i;function Gt(e,t,n,r){var i;if(d.isArray(t))d.each(t,function(t,i){n||Ut.test(e)?r(e,i):Gt(e+"["+("object"==typeof i&&null!=i?t:"")+"]",i,n,r)});else if(n||"object"!==d.type(t))r(e,t);else for(i in t)Gt(e+"["+i+"]",t[i],n,r)}d.param=function(e,t){var n,r=[],i=function(e,t){t=d.isFunction(t)?t():null==t?"":t,r[r.length]=encodeURIComponent(e)+"="+encodeURIComponent(t)};if(void 0===t&&(t=d.ajaxSettings&&d.ajaxSettings.traditional),d.isArray(e)||e.jquery&&!d.isPlainObject(e))d.each(e,function(){i(this.name,this.value)});else for(n in e)Gt(n,e[n],t,i);return r.join("&").replace(Xt,"+")},d.fn.extend({serialize:function(){return d.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=d.prop(this,"elements");return e?d.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!d(this).is(":disabled")&&Jt.test(this.nodeName)&&!Yt.test(e)&&(this.checked||!K.test(e))}).map(function(e,t){var n=d(this).val();return null==n?null:d.isArray(n)?d.map(n,function(e){return{name:t.name,value:e.replace(Vt,"\r\n")}}):{name:t.name,value:n.replace(Vt,"\r\n")}}).get()}}),d.ajaxSettings.xhr=void 0!==e.ActiveXObject?function(){return this.isLocal?tn():r.documentMode>8?en():/^(get|post|head|put|delete|options)$/i.test(this.type)&&en()||tn()}:en;var Qt=0,Kt={},Zt=d.ajaxSettings.xhr();function en(){try{return new e.XMLHttpRequest}catch(e){}}function tn(){try{return new e.ActiveXObject("Microsoft.XMLHTTP")}catch(e){}}e.attachEvent&&e.attachEvent("onunload",function(){for(var e in Kt)Kt[e](void 0,!0)}),f.cors=!!Zt&&"withCredentials"in Zt,(Zt=f.ajax=!!Zt)&&d.ajaxTransport(function(t){var n;if(!t.crossDomain||f.cors)return{send:function(r,i){var o,a=t.xhr(),s=++Qt;if(a.open(t.type,t.url,t.async,t.username,t.password),t.xhrFields)for(o in t.xhrFields)a[o]=t.xhrFields[o];for(o in t.mimeType&&a.overrideMimeType&&a.overrideMimeType(t.mimeType),t.crossDomain||r["X-Requested-With"]||(r["X-Requested-With"]="XMLHttpRequest"),r)void 0!==r[o]&&a.setRequestHeader(o,r[o]+"");a.send(t.hasContent&&t.data||null),n=function(e,r){var o,u,l;if(n&&(r||4===a.readyState))if(delete Kt[s],n=void 0,a.onreadystatechange=d.noop,r)4!==a.readyState&&a.abort();else{l={},o=a.status,"string"==typeof a.responseText&&(l.text=a.responseText);try{u=a.statusText}catch(e){u=""}o||!t.isLocal||t.crossDomain?1223===o&&(o=204):o=l.text?200:404}l&&i(o,u,l,a.getAllResponseHeaders())},t.async?4===a.readyState?e.setTimeout(n):a.onreadystatechange=Kt[s]=n:n()},abort:function(){n&&n(void 0,!0)}}}),d.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(e){return d.globalEval(e),e}}}),d.ajaxPrefilter("script",function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type="GET",e.global=!1)}),d.ajaxTransport("script",function(e){if(e.crossDomain){var t,n=r.head||d("head")[0]||r.documentElement;return{send:function(i,o){(t=r.createElement("script")).async=!0,e.scriptCharset&&(t.charset=e.scriptCharset),t.src=e.url,t.onload=t.onreadystatechange=function(e,n){(n||!t.readyState||/loaded|complete/.test(t.readyState))&&(t.onload=t.onreadystatechange=null,t.parentNode&&t.parentNode.removeChild(t),t=null,n||o(200,"success"))},n.insertBefore(t,n.firstChild)},abort:function(){t&&t.onload(void 0,!0)}}}});var nn=[],rn=/(=)\?(?=&|$)|\?\?/;d.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=nn.pop()||d.expando+"_"+St++;return this[e]=!0,e}}),d.ajaxPrefilter("json jsonp",function(t,n,r){var i,o,a,s=!1!==t.jsonp&&(rn.test(t.url)?"url":"string"==typeof t.data&&0===(t.contentType||"").indexOf("application/x-www-form-urlencoded")&&rn.test(t.data)&&"data");if(s||"jsonp"===t.dataTypes[0])return i=t.jsonpCallback=d.isFunction(t.jsonpCallback)?t.jsonpCallback():t.jsonpCallback,s?t[s]=t[s].replace(rn,"$1"+i):!1!==t.jsonp&&(t.url+=(At.test(t.url)?"&":"?")+t.jsonp+"="+i),t.converters["script json"]=function(){return a||d.error(i+" was not called"),a[0]},t.dataTypes[0]="json",o=e[i],e[i]=function(){a=arguments},r.always(function(){void 0===o?d(e).removeProp(i):e[i]=o,t[i]&&(t.jsonpCallback=n.jsonpCallback,nn.push(i)),a&&d.isFunction(o)&&o(a[0]),a=o=void 0}),"script"}),d.parseHTML=function(e,t,n){if(!e||"string"!=typeof e)return null;"boolean"==typeof t&&(n=t,t=!1),t=t||r;var i=T.exec(e),o=!n&&[];return i?[t.createElement(i[1])]:(i=ce([e],t,o),o&&o.length&&d(o).remove(),d.merge([],i.childNodes))};var on=d.fn.load;function an(e){return d.isWindow(e)?e:9===e.nodeType&&(e.defaultView||e.parentWindow)}d.fn.load=function(e,t,n){if("string"!=typeof e&&on)return on.apply(this,arguments);var r,i,o,a=this,s=e.indexOf(" ");return s>-1&&(r=d.trim(e.slice(s,e.length)),e=e.slice(0,s)),d.isFunction(t)?(n=t,t=void 0):t&&"object"==typeof t&&(i="POST"),a.length>0&&d.ajax({url:e,type:i||"GET",dataType:"html",data:t}).done(function(e){o=arguments,a.html(r?d("<div>").append(d.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},d.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){d.fn[t]=function(e){return this.on(t,e)}}),d.expr.filters.animated=function(e){return d.grep(d.timers,function(t){return e===t.elem}).length},d.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l=d.css(e,"position"),c=d(e),f={};"static"===l&&(e.style.position="relative"),s=c.offset(),o=d.css(e,"top"),u=d.css(e,"left"),("absolute"===l||"fixed"===l)&&d.inArray("auto",[o,u])>-1?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),d.isFunction(t)&&(t=t.call(e,n,d.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),"using"in t?t.using.call(e,f):c.css(f)}},d.fn.extend({offset:function(e){if(arguments.length)return void 0===e?this:this.each(function(t){d.offset.setOffset(this,e,t)});var t,n,r={top:0,left:0},i=this[0],o=i&&i.ownerDocument;return o?(t=o.documentElement,d.contains(t,i)?(void 0!==i.getBoundingClientRect&&(r=i.getBoundingClientRect()),n=an(o),{top:r.top+(n.pageYOffset||t.scrollTop)-(t.clientTop||0),left:r.left+(n.pageXOffset||t.scrollLeft)-(t.clientLeft||0)}):r):void 0},position:function(){if(this[0]){var e,t,n={top:0,left:0},r=this[0];return"fixed"===d.css(r,"position")?t=r.getBoundingClientRect():(e=this.offsetParent(),t=this.offset(),d.nodeName(e[0],"html")||(n=e.offset()),n.top+=d.css(e[0],"borderTopWidth",!0),n.left+=d.css(e[0],"borderLeftWidth",!0)),{top:t.top-n.top-d.css(r,"marginTop",!0),left:t.left-n.left-d.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){for(var e=this.offsetParent;e&&!d.nodeName(e,"html")&&"static"===d.css(e,"position");)e=e.offsetParent;return e||We})}}),d.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(e,t){var n=/Y/.test(t);d.fn[e]=function(r){return Q(this,function(e,r,i){var o=an(e);if(void 0===i)return o?t in o?o[t]:o.document.documentElement[r]:e[r];o?o.scrollTo(n?d(o).scrollLeft():i,n?i:d(o).scrollTop()):e[r]=i},e,r,arguments.length,null)}}),d.each(["top","left"],function(e,t){d.cssHooks[t]=Xe(f.pixelPosition,function(e,n){if(n)return n=$e(e,t),Pe.test(n)?d(e).position()[t]+"px":n})}),d.each({Height:"height",Width:"width"},function(e,t){d.each({padding:"inner"+e,content:t,"":"outer"+e},function(n,r){d.fn[r]=function(r,i){var o=arguments.length&&(n||"boolean"!=typeof r),a=n||(!0===r||!0===i?"margin":"border");return Q(this,function(t,n,r){var i;return d.isWindow(t)?t.document.documentElement["client"+e]:9===t.nodeType?(i=t.documentElement,Math.max(t.body["scroll"+e],i["scroll"+e],t.body["offset"+e],i["offset"+e],i["client"+e])):void 0===r?d.css(t,n,a):d.style(t,n,r,a)},t,o?r:void 0,o,null)}})}),d.fn.extend({bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)}}),d.fn.size=function(){return this.length},d.fn.andSelf=d.fn.addBack,"function"==typeof define&&define.amd&&define("jquery",[],function(){return d});var sn=e.jQuery,un=e.$;return d.noConflict=function(t){return e.$===d&&(e.$=un),t&&e.jQuery===d&&(e.jQuery=sn),d},t||(e.jQuery=e.$=d),d}),function(e){var t=e.fn.jquery.split("."),n=parseInt(t[0]),r=parseInt(t[1]);if(!(n>3||3===n&&r>=5)){var i="("+["a","abbr","address","article","aside","audio","b","bdi","bdo","blockquote","button","canvas","caption","cite","code","data","datalist","dd","del","details","dfn","div","dl","dt","em","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hgroup","i","ins","kbd","label","legend","li","main","map","mark","menu","meter","nav","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","small","source","span","strong","sub","summary","sup","table","tbody","td","tfoot","th","thead","time","tr","u","ul","var","video"].join("|")+")",o=new RegExp("<"+i+"\\/>","gi"),a=new RegExp("<"+i+"([\\x20\\t\\r\\n\\f][^>]*)\\/>","gi"),s=/<([a-z][^\/\0>\x20\t\r\n\f]*)/i;e.extend({htmlPrefilter:function(e){var t=(s.exec(e)||["",""])[1].toLowerCase();return"option"!==t&&"optgroup"!==t||!e.match(/<\/?select/i)||(e=""),e=(e=e.replace(o,"<$1></$1>")).replace(a,"<$1$2></$1>")}})}}(jQuery);
src/messages/MessageGroup.js
Sekhmet/busy
import React from 'react'; import { FormattedTime } from 'react-intl'; import { Link } from 'react-router'; import Body from '../post/Body'; import Avatar from '../widgets/Avatar'; import { ProfileTooltipOrigin } from '../widgets/tooltip/ProfileTooltip'; const MessageGroup = (props) => { const { model } = props; const receivedAt = model[0].receivedAt; const senderUsername = (model[0].senderUsername || model[0].sentBy); return ( <div className="Message mx-4"> <div data-uuid={model[0].uuid}> <div className="Message__left"> <ProfileTooltipOrigin username={senderUsername}> <Link to={`/@${senderUsername}`}> <Avatar sm username={senderUsername} /> </Link> </ProfileTooltipOrigin> </div> <div className="ml-5"> <div className="media-heading"> <b> <ProfileTooltipOrigin username={senderUsername}> <Link to={`/@${senderUsername}`}> {senderUsername} </Link> </ProfileTooltipOrigin> </b>{' '} <span className="text-info"> <FormattedTime value={receivedAt} /> </span> </div> <Body body={model[0].text} /> </div> </div> {model.slice(1).map((message, i) => { const { text, uuid, receivedAt: mreceivedAt } = message; return ( <div className="Message__item" key={i} data-uuid={uuid}> <div className="Message__timestamp"> <FormattedTime value={new Date(mreceivedAt)} /> </div> <div className="ml-5"> <Body body={text} /> </div> </div> ); })} </div> ); }; export default MessageGroup;
plugins/react/frontend/components/form/Grid/Row/index.js
pure-ui/styleguide
import React from 'react'; import styles from './styles.css'; const Row = ({ children, ...otherProps }) => ( <div {...otherProps} className={styles.root}> {children} <div className={styles.clearfix} /> </div> ); export default Row;
frontend/src/Album/Details/AlbumDetailsMedium.js
lidarr/Lidarr
import PropTypes from 'prop-types'; import React, { Component } from 'react'; import Icon from 'Components/Icon'; import Label from 'Components/Label'; import IconButton from 'Components/Link/IconButton'; import Link from 'Components/Link/Link'; import Table from 'Components/Table/Table'; import TableBody from 'Components/Table/TableBody'; import { icons, kinds, sizes } from 'Helpers/Props'; import TrackRowConnector from './TrackRowConnector'; import styles from './AlbumDetailsMedium.css'; function getMediumStatistics(tracks) { let trackCount = 0; let trackFileCount = 0; let totalTrackCount = 0; tracks.forEach((track) => { if (track.trackFileId) { trackCount++; trackFileCount++; } else { trackCount++; } totalTrackCount++; }); return { trackCount, trackFileCount, totalTrackCount }; } function getTrackCountKind(monitored, trackFileCount, trackCount) { if (trackFileCount === trackCount && trackCount > 0) { return kinds.SUCCESS; } if (!monitored) { return kinds.WARNING; } return kinds.DANGER; } class AlbumDetailsMedium extends Component { // // Lifecycle componentDidMount() { this._expandByDefault(); } componentDidUpdate(prevProps) { if (prevProps.albumId !== this.props.albumId) { this._expandByDefault(); } } // // Control _expandByDefault() { const { mediumNumber, onExpandPress } = this.props; onExpandPress(mediumNumber, mediumNumber === 1); } // // Listeners onExpandPress = () => { const { mediumNumber, isExpanded } = this.props; this.props.onExpandPress(mediumNumber, !isExpanded); } // // Render render() { const { mediumNumber, mediumFormat, albumMonitored, items, columns, onTableOptionChange, isExpanded, isSmallScreen } = this.props; const { trackCount, trackFileCount, totalTrackCount } = getMediumStatistics(items); return ( <div className={styles.medium} > <div className={styles.header}> <div className={styles.left}> { <div> <span className={styles.mediumNumber}> {mediumFormat} {mediumNumber} </span> </div> } <Label title={`${totalTrackCount} tracks total. ${trackFileCount} tracks with files.`} kind={getTrackCountKind(albumMonitored, trackFileCount, trackCount)} size={sizes.LARGE} > { <span>{trackFileCount} / {trackCount}</span> } </Label> </div> <Link className={styles.expandButton} onPress={this.onExpandPress} > <Icon className={styles.expandButtonIcon} name={isExpanded ? icons.COLLAPSE : icons.EXPAND} title={isExpanded ? 'Hide tracks' : 'Show tracks'} size={24} /> { !isSmallScreen && <span>&nbsp;</span> } </Link> </div> <div> { isExpanded && <div className={styles.tracks}> { items.length ? <Table columns={columns} onTableOptionChange={onTableOptionChange} > <TableBody> { items.map((item) => { return ( <TrackRowConnector key={item.id} columns={columns} {...item} /> ); }) } </TableBody> </Table> : <div className={styles.noTracks}> No tracks in this medium </div> } <div className={styles.collapseButtonContainer}> <IconButton name={icons.COLLAPSE} size={20} title="Hide tracks" onPress={this.onExpandPress} /> </div> </div> } </div> </div> ); } } AlbumDetailsMedium.propTypes = { albumId: PropTypes.number.isRequired, albumMonitored: PropTypes.bool.isRequired, mediumNumber: PropTypes.number.isRequired, mediumFormat: PropTypes.string.isRequired, items: PropTypes.arrayOf(PropTypes.object).isRequired, columns: PropTypes.arrayOf(PropTypes.object).isRequired, isSaving: PropTypes.bool, isExpanded: PropTypes.bool, isSmallScreen: PropTypes.bool.isRequired, onTableOptionChange: PropTypes.func.isRequired, onExpandPress: PropTypes.func.isRequired }; export default AlbumDetailsMedium;
src/Divider/Divider.spec.js
xmityaz/material-ui
/* eslint-env mocha */ import React from 'react'; import {shallow} from 'enzyme'; import {assert} from 'chai'; import Divider from './Divider'; import getMuiTheme from '../styles/getMuiTheme'; describe('<Divider />', () => { const muiTheme = getMuiTheme(); const shallowWithContext = (node) => shallow(node, {context: {muiTheme}}); it('renders className', () => { const wrapper = shallowWithContext( <Divider className="test-class-name" /> ); assert.ok(wrapper.is('.test-class-name'), 'should contain the className'); }); it('renders inset', () => { const wrapper = shallowWithContext( <Divider inset={true} /> ); const cheerioDivider = wrapper.render().children(); assert.strictEqual(cheerioDivider.css('margin-left'), '72px'); }); it('overwrite styles', () => { const style = { backgroundColor: 'red', }; const wrapper = shallowWithContext( <Divider style={style} /> ); assert.strictEqual(wrapper.prop('style').backgroundColor, 'red', 'should have red backgroundColor'); }); });
client/pages/Home/Title/Title.js
b3j0f/lechangement
import './Title.css'; import React, { Component } from 'react'; class Home extends Component { render() { return ( <div className="title center"> <h1>Le changement</h1> <h5>Réapproprions-nous la politique</h5> </div> ); } } export default Home;
src/views/app/index.js
bogdan-dumitru/padkontrol
import React, { Component } from 'react'; import Controls from '../controls'; import Grid from '../grid'; import Sequencer from '../sequencer'; import _style from './index.css'; export default class App extends Component { render() { return ( <div className="App clearfix"> <div className="Controls-container"> <Controls /> </div> <div className="Grid-container"> <Grid /> </div> <div className="Sequencer-container"> <Sequencer /> </div> </div> ); } }
ajax/libs/autonumeric/2.0.9/autoNumeric.js
dakshshah96/cdnjs
(function webpackUniversalModuleDefinition(root, factory) { if(typeof exports === 'object' && typeof module === 'object') module.exports = factory(require("jquery")); else if(typeof define === 'function' && define.amd) define(["jquery"], factory); else if(typeof exports === 'object') exports["autonumeric"] = factory(require("jquery")); else root["autonumeric"] = factory(root["jQuery"]); })(this, function(__WEBPACK_EXTERNAL_MODULE_1__) { return /******/ (function(modules) { // webpackBootstrap /******/ // The module cache /******/ var installedModules = {}; /******/ // The require function /******/ function __webpack_require__(moduleId) { /******/ // Check if module is in cache /******/ if(installedModules[moduleId]) /******/ return installedModules[moduleId].exports; /******/ // Create a new module (and put it into the cache) /******/ var module = installedModules[moduleId] = { /******/ exports: {}, /******/ id: moduleId, /******/ loaded: false /******/ }; /******/ // Execute the module function /******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); /******/ // Flag the module as loaded /******/ module.loaded = true; /******/ // Return the exports of the module /******/ return module.exports; /******/ } /******/ // expose the modules object (__webpack_modules__) /******/ __webpack_require__.m = modules; /******/ // expose the module cache /******/ __webpack_require__.c = installedModules; /******/ // __webpack_public_path__ /******/ __webpack_require__.p = ""; /******/ // Load entry module and return exports /******/ return __webpack_require__(0); /******/ }) /************************************************************************/ /******/ ([ /* 0 */ /***/ function(module, exports, __webpack_require__) { eval("var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;/*** IMPORTS FROM imports-loader ***/\nvar jQuery = __webpack_require__(1);\nvar $ = __webpack_require__(1);\n(function() {\n\n'use strict';\n\nObject.defineProperty(exports, \"__esModule\", {\n value: true\n});\n\nvar _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if (\"value\" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();\n\nvar _slicedToArray = function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i[\"return\"]) _i[\"return\"](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError(\"Invalid attempt to destructure non-iterable instance\"); } }; }();\n\nvar _typeof = typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj; };\n\nfunction _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(\"Cannot call a class as a function\"); } }\n\n/**\n * autoNumeric.js\n *\n * @version 2.0.9\n * @date 2017-02-28 UTC 14:00\n *\n * @author Bob Knothe\n * @contributors Alexandre Bonneau, Sokolov Yura and other Github users,\n * cf. AUTHORS.md.\n * @copyright 2009 Robert J. Knothe http://www.decorplanit.com/plugin/\n * @since 2009-08-09\n *\n * @summary autoNumeric is a library that provides live as-you-type\n * formatting for international numbers and currencies.\n *\n * Note : Some functions are borrowed from big.js\n * @link https://github.com/MikeMcl/big.js/\n *\n * Please report any bugs to https://github.com/BobKnothe/autoNumeric\n *\n * @license Released under the MIT License\n * @link http://www.opensource.org/licenses/mit-license.php\n *\n * Permission is hereby granted, free of charge, to any person\n * obtaining a copy of this software and associated documentation\n * files (the \"Software\"), to deal in the Software without\n * restriction, including without limitation the rights to use,\n * copy, modify, merge, publish, distribute, sub license, and/or sell\n * copies of the Software, and to permit persons to whom the\n * Software is furnished to do so, subject to the following\n * conditions:\n *\n * The above copyright notice and this permission notice shall be\n * included in all copies or substantial portions of the Software.\n *\n * THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\n * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES\n * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\n * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT\n * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,\n * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\n * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR\n * OTHER DEALINGS IN THE SOFTWARE.\n */\n\n/* global module, require, define */\n\n// Functions names for ES6 exports\nvar autoFormat = void 0;\nvar autoUnFormat = void 0;\nvar getDefaultConfig = void 0;\nvar getLanguages = void 0;\nvar validate = void 0;\nvar areSettingsValid = void 0;\n\n// AutoNumeric default settings\n/**\n * List of allowed tag on which autoNumeric can be used.\n */\nvar allowedTagList = ['b', 'caption', 'cite', 'code', 'const', 'dd', 'del', 'div', 'dfn', 'dt', 'em', 'h1', 'h2', 'h3', 'h4', 'h5', 'h6', 'ins', 'kdb', 'label', 'li', 'option', 'output', 'p', 'q', 's', 'sample', 'span', 'strong', 'td', 'th', 'u'];\n\n/**\n * Defaults options are public - these can be overridden by the following method:\n * - HTML5 data attributes (ie. `<input type=\"text\" data-currency-symbol=\" €\">`)\n * - Options passed by the 'init' or 'update' methods (ie. `aNInput.autoNumeric('update', { currencySymbol: ' €' });`)\n * - Use jQuery's `$.extend` method for global changes - also a great way to pass ASP.NET current culture settings\n */\nvar defaultSettings = {\n /* Allowed thousand grouping separator characters :\n * ',' // Comma\n * '.' // Dot\n * ' ' // Normal space\n * '\\u2009' // Thin-space\n * '\\u202f' // Narrow no-break space\n * '\\u00a0' // No-break space\n * '' // No separator\n * \"'\" // Apostrophe\n * '٬' // Arabic thousands separator\n * '˙' // Dot above\n * Deprecated older option name : aSep\n */\n digitGroupSeparator: ',',\n\n /* Remove the thousand separator on focus, currency symbol and suffix on focus\n * example if the input value \"$ 1,999.88 suffix\"\n * on \"focusin\" it becomes \"1999.88\" and back to \"$ 1,999.88 suffix\" on focus out.\n * Deprecated older option name : nSep\n */\n noSeparatorOnFocus: false,\n\n /* Digital grouping for the thousand separator used in Format\n * digitalGroupSpacing: \"2\", results in 99,99,99,999 India's lakhs\n * digitalGroupSpacing: \"2s\", results in 99,999,99,99,999 India's lakhs scaled\n * digitalGroupSpacing: \"3\", results in 999,999,999 default\n * digitalGroupSpacing: \"4\", results in 9999,9999,9999 used in some Asian countries\n * Deprecated older option name : dGroup\n */\n digitalGroupSpacing: '3',\n\n /* Allowed decimal separator characters :\n * ',' : Comma\n * '.' : Dot\n * '·' : Middle-dot\n * '٫' : Arabic decimal separator\n * '⎖' : Decimal separator key symbol\n * Deprecated older option name : aDec\n */\n decimalCharacter: '.',\n\n /* Allow to declare an alternative decimal separator which is automatically replaced by `decimalCharacter` when typed.\n * This is used by countries that use a comma \",\" as the decimal character and have keyboards\\numeric pads that have\n * a period 'full stop' as the decimal characters (France or Spain for instance).\n * Deprecated older option name : altDec\n */\n decimalCharacterAlternative: null,\n\n /* currencySymbol = allowed currency symbol\n * Must be in quotes currencySymbol: \"$\"\n * space to the right of the currency symbol currencySymbol: '$ '\n * space to the left of the currency symbol currencySymbol: ' $'\n * Deprecated older option name : aSign\n */\n currencySymbol: '',\n\n /* currencySymbolPlacement = placement of currency sign as a p=prefix or s=suffix\n * for prefix currencySymbolPlacement: \"p\" (default)\n * for suffix currencySymbolPlacement: \"s\"\n * Deprecated older option name : pSign\n */\n //TODO Rename the options to more explicit names ('p' => 'prefix', etc.)\n currencySymbolPlacement: 'p',\n\n /* Placement of negative/positive sign relative to the currencySymbol option l=left, r=right, p=prefix & s=suffix\n * -1,234.56 => default no options required\n * -$1,234.56 => {currencySymbol: \"$\"} or {currencySymbol: \"$\", negativePositiveSignPlacement: \"l\"}\n * $-1,234.56 => {currencySymbol: \"$\", negativePositiveSignPlacement: \"r\"} // Default if negativePositiveSignPlacement is 'null' and currencySymbol is not empty\n * -1,234.56$ => {currencySymbol: \"$\", currencySymbolPlacement: \"s\", negativePositiveSignPlacement: \"p\"} // Default if negativePositiveSignPlacement is 'null' and currencySymbol is not empty\n * 1,234.56- => {negativePositiveSignPlacement: \"s\"}\n * $1,234.56- => {currencySymbol: \"$\", negativePositiveSignPlacement: \"s\"}\n * 1,234.56-$ => {currencySymbol: \"$\", currencySymbolPlacement: \"s\"}\n * 1,234.56$- => {currencySymbol: \"$\", currencySymbolPlacement: \"s\", negativePositiveSignPlacement: \"r\"}\n * Deprecated older option name : pNeg\n */\n //TODO Rename the options to more explicit names ('p' => 'prefix', etc.)\n negativePositiveSignPlacement: null,\n\n /* Allow the positive sign symbol `+` to be displayed for positive numbers.\n * By default, this positive sign is not shown.\n * The sign placement is controlled by the 'negativePositiveSignPlacement' option, mimicking the negative sign placement rules.\n */\n showPositiveSign: false,\n\n /* Additional suffix\n * Must be in quotes suffixText: 'gross', a space is allowed suffixText: ' dollars'\n * Numeric characters and negative sign not allowed'\n * Deprecated older option name : aSuffix\n */\n suffixText: '',\n\n /* Override min max limits\n * overrideMinMaxLimits: \"ceiling\" adheres to maximumValue and ignores minimumValue settings\n * overrideMinMaxLimits: \"floor\" adheres to minimumValue and ignores maximumValue settings\n * overrideMinMaxLimits: \"ignore\" ignores both minimumValue & maximumValue\n * Deprecated older option name : oLimits\n */\n overrideMinMaxLimits: null,\n\n /* Maximum possible value\n * value must be enclosed in quotes and use the period for the decimal point\n * value must be larger than minimumValue\n * Deprecated older option name : vMax\n */\n maximumValue: '9999999999999.99', // 9.999.999.999.999,99 ~= 10000 billions\n\n /* Minimum possible value\n * value must be enclosed in quotes and use the period for the decimal point\n * value must be smaller than maximumValue\n * Deprecated older option name : vMin\n */\n minimumValue: '-9999999999999.99', // -9.999.999.999.999,99 ~= 10000 billions\n\n /* Maximum number of decimal places = used to override decimal places set by the minimumValue & maximumValue values\n * Deprecated older option name : mDec\n */\n decimalPlacesOverride: null,\n\n /* Expanded decimal places visible when input has focus - example:\n * {decimalPlacesShownOnFocus: \"5\"} and the default 2 decimal places with focus \"1,000.12345\" without focus \"1,000.12\" the results depends on the rounding method used\n * the \"get\" method returns the extended decimal places\n * Deprecated older option name : eDec\n */\n decimalPlacesShownOnFocus: null,\n\n /* The next three options (scaleDivisor, scaleDecimalPlaces & scaleSymbol) handle scaling of the input when the input does not have focus\n * Please note that the non-scaled value is held in data and it is advised that you use the \"saveValueToSessionStorage\" option to ensure retaining the value\n * [\"divisor\", \"decimal places\", \"symbol\"]\n * Example: with the following options set {scaleDivisor: '1000', scaleDecimalPlaces: '1', scaleSymbol: ' K'}\n * Example: focusin value \"1,111.11\" focusout value \"1.1 K\"\n */\n\n /* The `scaleDivisor` decides the on focus value and places the result in the input on focusout\n * Example {scaleDivisor: '1000'} or <input data-scale-divisor=\"1000\">\n * The divisor value - does not need to be whole number but please understand that Javascript has limited accuracy in math\n * The \"get\" method returns the full value, including the 'hidden' decimals.\n */\n scaleDivisor: null,\n\n /*\n * The `scaleDecimalPlaces` option is the number of decimal place when not in focus - for this to work, `scaledDivisor` must not be `null`.\n * This is optional ; if omitted the decimal places will be the same when the input has the focus.\n * Deprecated older option name : scaleDecimal\n */\n scaleDecimalPlaces: null,\n\n /*\n * The `scaleSymbol` option is a symbol placed as a suffix when not in focus.\n * This is optional too.\n */\n scaleSymbol: null,\n\n /* Set to true to allow the decimalPlacesShownOnFocus value to be saved with sessionStorage\n * if ie 6 or 7 the value will be saved as a session cookie\n * Deprecated older option name : aStor\n */\n saveValueToSessionStorage: false,\n\n /*\n * Manage how autoNumeric react when the user tries to paste an invalid number.\n * - 'error' : (This is the default behavior) The input value is not changed and an error is output in the console.\n * - 'ignore' : idem than 'error', but fail silently without outputting any error/warning in the console.\n * - 'clamp' : if the pasted value is either too small or too big regarding the minimumValue and maximumValue range, then the result is clamped to those limits.\n * - 'truncate' : autoNumeric will insert as many pasted numbers it can at the initial caret/selection, until everything is pasted, or the range limit is hit.\n * The non-pasted numbers are dropped and therefore not used at all.\n * - 'replace' : autoNumeric will first insert as many pasted numbers it can at the initial caret/selection, then if the range limit is hit, it will try\n * to replace one by one the remaining initial numbers (on the right side of the caret) with the rest of the pasted numbers.\n *\n * Note 1 : A paste content starting with a negative sign '-' will be accepted anywhere in the input, and will set the resulting value as a negative number\n * Note 2 : A paste content starting with a number will be accepted, even if the rest is gibberish (ie. '123foobar456').\n * Only the first number will be used (here '123').\n * Note 3 : The paste event works with the `decimalPlacesShownOnFocus` option too.\n */\n //TODO Shouldn't we use `truncate` as the default value?\n onInvalidPaste: 'error',\n\n /* method used for rounding\n * roundingMethod: \"S\", Round-Half-Up Symmetric (default)\n * roundingMethod: \"A\", Round-Half-Up Asymmetric\n * roundingMethod: \"s\", Round-Half-Down Symmetric (lower case s)\n * roundingMethod: \"a\", Round-Half-Down Asymmetric (lower case a)\n * roundingMethod: \"B\", Round-Half-Even \"Bankers Rounding\"\n * roundingMethod: \"U\", Round Up \"Round-Away-From-Zero\"\n * roundingMethod: \"D\", Round Down \"Round-Toward-Zero\" - same as truncate\n * roundingMethod: \"C\", Round to Ceiling \"Toward Positive Infinity\"\n * roundingMethod: \"F\", Round to Floor \"Toward Negative Infinity\"\n * roundingMethod: \"N05\" Rounds to the nearest .05 => same as \"CHF\" used in 1.9X and still valid\n * roundingMethod: \"U05\" Rounds up to next .05\n * roundingMethod: \"D05\" Rounds down to next .05\n * Deprecated older option name : mRound\n */\n //TODO Rename the options to more explicit names ('S' => 'RoundHalfUpSymmetric', etc.)\n //TODO Add an `an.roundingMethod` object that enum those options clearly\n roundingMethod: 'S',\n\n /* Allow padding the decimal places with zeros\n * allowDecimalPadding: true - always Pad decimals with zeros\n * allowDecimalPadding: false - does not pad with zeros.\n * Note: setting allowDecimalPadding to 'false' will override the 'decimalPlacesOverride' setting.\n *\n * thanks to Jonas Johansson for the suggestion\n * Deprecated older option name : aPad\n */\n allowDecimalPadding: true,\n\n /* Adds brackets on negative values (ie. transforms '-$ 999.99' to '(999.99)')\n * Those brackets are visible only when the field does NOT have the focus.\n * The left and right symbols should be enclosed in quotes and separated by a comma\n * This option can be of the following values :\n * null, // This is the default value, which deactivate this feature\n * '(,)',\n * '[,]',\n * '<,>' or\n * '{,}'\n * Deprecated older option name : nBracket\n */\n //TODO Rename the options to more explicit names ('(,)' => 'parentheses', etc.)\n negativeBracketsTypeOnBlur: null,\n\n /* Displayed on empty string \"\"\n * emptyInputBehavior: \"focus\" - (default) currency sign displayed and the input receives focus\n * emptyInputBehavior: \"press\" - currency sign displays on any key being pressed\n * emptyInputBehavior: \"always\" - always displays the currency sign only\n * emptyInputBehavior: \"zero\" - if the input has no value on focus out displays a zero \"rounded\" with or without a currency sign\n * Deprecated older option name : wEmpty\n */\n emptyInputBehavior: 'focus',\n\n /* Controls leading zero behavior\n * leadingZero: \"allow\", - allows leading zeros to be entered. Zeros will be truncated when entering additional digits. On focusout zeros will be deleted.\n * leadingZero: \"deny\", - allows only one leading zero on values less than one\n * leadingZero: \"keep\", - allows leading zeros to be entered. on focusout zeros will be retained.\n * Deprecated older option name : lZero\n */\n leadingZero: 'deny',\n\n /* Determine if the default value will be formatted on initialization.\n * true = automatically formats the default value on initialization\n * false = will not format the default value on initialization\n * Deprecated older option name : aForm\n */\n formatOnPageLoad: true,\n\n /* Determine if the select all keyboard command will select the complete input text, or only the input numeric value\n * Note : If the currency symbol is between the numeric value and the negative sign, only the numeric value will selected\n * Deprecated older option name : sNumber\n */\n selectNumberOnly: false,\n\n /* Helper option for ASP.NET postback\n * should be the value of the unformatted default value\n * examples:\n * no default value=\"\" {defaultValueOverride: \"\"}\n * value=1234.56 {defaultValueOverride: '1234.56'}\n * Deprecated older option name : anDefault\n */\n defaultValueOverride: null,\n\n /* Removes formatting on submit event\n * this output format: positive nnnn.nn, negative -nnnn.nn\n * review the 'unSet' method for other formats\n * Deprecated older option name : unSetOnSubmit\n */\n unformatOnSubmit: false,\n\n /* Allows the output to be in the locale format via the \"get\", \"getString\" & \"getArray\" methods\n * null or 'string' => 'nnnn.nn' or '-nnnn.nn' as text type. This is the default behavior.\n * 'number' => nnnn.nn or -nnnn.nn as a Number (Warning: this works only for integers inferior to Number.MAX_SAFE_INTEGER)\n * ',' or '-,' => 'nnnn,nn' or '-nnnn,nn'\n * '.-' => 'nnnn.nn' or 'nnnn.nn-'\n * ',-' => 'nnnn,nn' or 'nnnn,nn-'\n * Deprecated older option name : outputType\n */\n outputFormat: null,\n\n /* Defines if warnings should be shown\n * Error handling function\n * true => all warning are shown\n * false => no warnings are shown, only the thrown errors\n * Deprecated older option name : debug\n */\n showWarnings: true,\n\n /*\n * This option is the 'strict mode' (aka 'debug' mode), which allows autoNumeric to strictly analyse the options passed, and fails if an unknown options is used in the settings object.\n * You should set that to 'TRUE' if you want to make sure you are only using 'pure' autoNumeric settings objects in your code.\n * If you see uncaught errors in the console and your code starts to fail, this means somehow those options gets corrupted by another program.\n */\n failOnUnknownOption: false\n};\n\n/**\n * Wrapper variable that hold named keyboard keys with their respective keyCode as seen in DOM events.\n * //TODO Replace every call to this object with a call to `keyName`\n * @deprecated\n */\nvar keyCode = {\n Backspace: 8,\n Tab: 9,\n Enter: 13,\n Shift: 16,\n Ctrl: 17,\n Alt: 18,\n PauseBreak: 19,\n CapsLock: 20,\n Esc: 27,\n Space: 32,\n PageUp: 33,\n PageDown: 34,\n End: 35,\n Home: 36,\n LeftArrow: 37,\n UpArrow: 38,\n RightArrow: 39,\n DownArrow: 40,\n Insert: 45,\n Delete: 46,\n num0: 48,\n num1: 49,\n num2: 50,\n num3: 51,\n num4: 52,\n num5: 53,\n num6: 54,\n num7: 55,\n num8: 56,\n num9: 57,\n a: 65,\n b: 66,\n c: 67,\n d: 68,\n e: 69,\n f: 70,\n g: 71,\n h: 72,\n i: 73,\n j: 74,\n k: 75,\n l: 76,\n m: 77,\n n: 78,\n o: 79,\n p: 80,\n q: 81,\n r: 82,\n s: 83,\n t: 84,\n u: 85,\n v: 86,\n w: 87,\n x: 88,\n y: 89,\n z: 90,\n Windows: 91,\n RightClick: 93,\n numpad0: 96,\n numpad1: 97,\n numpad2: 98,\n numpad3: 99,\n numpad4: 100,\n numpad5: 101,\n numpad6: 102,\n numpad7: 103,\n numpad8: 104,\n numpad9: 105,\n MultiplyNumpad: 106,\n PlusNumpad: 107,\n MinusNumpad: 109,\n DotNumpad: 110,\n SlashNumpad: 111,\n F1: 112,\n F2: 113,\n F3: 114,\n F4: 115,\n F5: 116,\n F6: 117,\n F7: 118,\n F8: 119,\n F9: 120,\n F10: 121,\n F11: 122,\n F12: 123,\n NumLock: 144,\n ScrollLock: 145,\n MyComputer: 182,\n MyCalculator: 183,\n Semicolon: 186,\n Equal: 187,\n Comma: 188,\n Hyphen: 189,\n Dot: 190,\n Slash: 191,\n Backquote: 192,\n LeftBracket: 219,\n Backslash: 220,\n RightBracket: 221,\n Quote: 222,\n Command: 224\n};\n\n/**\n * Wrapper variable that hold named keyboard keys with their respective key name (as set in KeyboardEvent.key).\n * Those names are listed here :\n * @link https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key/Key_Values\n */\nvar keyName = {\n // Special values\n Unidentified: 'Unidentified',\n\n // Modifier keys\n Alt: 'Alt',\n AltGr: 'AltGraph',\n CapsLock: 'CapsLock', // Under Chrome, e.key is empty for CapsLock\n Ctrl: 'Control',\n Fn: 'Fn',\n FnLock: 'FnLock',\n Hyper: 'Hyper', // 'OS' under Firefox\n Meta: 'Meta', // The Windows, Command or ⌘ key // 'OS' under Firefox and IE9\n Windows: 'Meta', // This is a non-official key name\n Command: 'Meta', // This is a non-official key name\n NumLock: 'NumLock',\n ScrollLock: 'ScrollLock',\n Shift: 'Shift',\n Super: 'Super', // 'OS' under Firefox\n Symbol: 'Symbol',\n SymbolLock: 'SymbolLock',\n\n // Whitespace keys\n Enter: 'Enter',\n Tab: 'Tab',\n Space: ' ', // 'Spacebar' for Firefox <37, and IE9\n\n // Navigation keys\n DownArrow: 'ArrowDown', // 'Down' for Firefox <=36, and IE9\n LeftArrow: 'ArrowLeft', // 'Left' for Firefox <=36, and IE9\n RightArrow: 'ArrowRight', // 'Right' for Firefox <=36, and IE9\n UpArrow: 'ArrowUp', // 'Up' for Firefox <=36, and IE9\n End: 'End',\n Home: 'Home',\n PageDown: 'PageDown',\n PageUp: 'PageUp',\n\n // Editing keys\n Backspace: 'Backspace',\n Clear: 'Clear',\n Copy: 'Copy',\n CrSel: 'CrSel', // 'Crsel' for Firefox <=36, and IE9\n Cut: 'Cut',\n Delete: 'Delete', // 'Del' for Firefox <=36, and IE9\n EraseEof: 'EraseEof',\n ExSel: 'ExSel', // 'Exsel' for Firefox <=36, and IE9\n Insert: 'Insert',\n Paste: 'Paste',\n Redo: 'Redo',\n Undo: 'Undo',\n\n // UI keys\n Accept: 'Accept',\n Again: 'Again',\n Attn: 'Attn', // 'Unidentified' for Firefox, Chrome, and IE9 ('KanaMode' when using the Japanese keyboard layout)\n Cancel: 'Cancel',\n ContextMenu: 'ContextMenu', // 'Apps' for Firefox <=36, and IE9\n Esc: 'Escape', // 'Esc' for Firefox <=36, and IE9\n Execute: 'Execute',\n Find: 'Find',\n Finish: 'Finish', // 'Unidentified' for Firefox, Chrome, and IE9 ('Katakana' when using the Japanese keyboard layout)\n Help: 'Help',\n Pause: 'Pause',\n Play: 'Play',\n Props: 'Props',\n Select: 'Select',\n ZoomIn: 'ZoomIn',\n ZoomOut: 'ZoomOut',\n\n // Device keys\n BrightnessDown: 'BrightnessDown',\n BrightnessUp: 'BrightnessUp',\n Eject: 'Eject',\n LogOff: 'LogOff',\n Power: 'Power',\n PowerOff: 'PowerOff',\n PrintScreen: 'PrintScreen',\n Hibernate: 'Hibernate', // 'Unidentified' for Firefox <=37\n Standby: 'Standby', // 'Unidentified' for Firefox <=36, and IE9\n WakeUp: 'WakeUp',\n\n // IME and composition keys\n Compose: 'Compose',\n Dead: 'Dead',\n\n // Function keys\n F1: 'F1',\n F2: 'F2',\n F3: 'F3',\n F4: 'F4',\n F5: 'F5',\n F6: 'F6',\n F7: 'F7',\n F8: 'F8',\n F9: 'F9',\n F10: 'F10',\n F11: 'F11',\n F12: 'F12',\n\n // Document keys\n Print: 'Print',\n\n // 'Normal' keys\n num0: '0',\n num1: '1',\n num2: '2',\n num3: '3',\n num4: '4',\n num5: '5',\n num6: '6',\n num7: '7',\n num8: '8',\n num9: '9',\n numpad0: '0',\n numpad1: '1',\n numpad2: '2',\n numpad3: '3',\n numpad4: '4',\n numpad5: '5',\n numpad6: '6',\n numpad7: '7',\n numpad8: '8',\n numpad9: '9',\n a: 'a',\n b: 'b',\n c: 'c',\n d: 'd',\n e: 'e',\n f: 'f',\n g: 'g',\n h: 'h',\n i: 'i',\n j: 'j',\n k: 'k',\n l: 'l',\n m: 'm',\n n: 'n',\n o: 'o',\n p: 'p',\n q: 'q',\n r: 'r',\n s: 's',\n t: 't',\n u: 'u',\n v: 'v',\n w: 'w',\n x: 'x',\n y: 'y',\n z: 'z',\n MultiplyNumpad: '*',\n PlusNumpad: '+',\n MinusNumpad: '-',\n DotNumpad: '.',\n SlashNumpad: '/',\n Semicolon: ';',\n Equal: '=',\n Comma: ',',\n Hyphen: '-',\n Minus: '-',\n Plus: '+',\n Dot: '.',\n Slash: '/',\n Backquote: '`',\n LeftBracket: '[',\n RightBracket: ']',\n Backslash: '\\\\',\n Quote: \"'\",\n NumpadDot: '.',\n NumpadDotAlt: ',', // Modern browsers automatically adapt the character sent by this key to the decimal character of the current language\n NumpadMultiply: '*',\n NumpadPlus: '+',\n NumpadMinus: '-',\n NumpadSlash: '/',\n NumpadDotObsoleteBrowsers: 'Decimal',\n NumpadMultiplyObsoleteBrowsers: 'Multiply',\n NumpadPlusObsoleteBrowsers: 'Add',\n NumpadMinusObsoleteBrowsers: 'Subtract',\n NumpadSlashObsoleteBrowsers: 'Divide'\n};\n\nvar defaultMinimumValue = '-999999999999.99';\nvar defaultMaximumValue = '999999999999.99';\nvar defaultRoundingMethod = 'U';\nvar defaultLeadingZero = 'deny';\nvar defaultSelectNumberOnly = true;\n\n/**\n * Predefined options for the most common languages\n */\nvar languageOption = {\n French: { // Français\n digitGroupSeparator: '.', // or '\\u202f'\n decimalCharacter: ',',\n decimalCharacterAlternative: '.',\n currencySymbol: '\\u202F\\u20AC',\n currencySymbolPlacement: 's',\n selectNumberOnly: defaultSelectNumberOnly,\n roundingMethod: defaultRoundingMethod,\n leadingZero: defaultLeadingZero,\n minimumValue: defaultMinimumValue,\n maximumValue: defaultMaximumValue\n },\n NorthAmerican: {\n digitGroupSeparator: ',',\n decimalCharacter: '.',\n currencySymbol: '$',\n currencySymbolPlacement: 'p',\n selectNumberOnly: defaultSelectNumberOnly,\n roundingMethod: defaultRoundingMethod,\n leadingZero: defaultLeadingZero,\n minimumValue: defaultMinimumValue,\n maximumValue: defaultMaximumValue\n },\n British: {\n digitGroupSeparator: ',',\n decimalCharacter: '.',\n currencySymbol: '£',\n currencySymbolPlacement: 'p',\n selectNumberOnly: defaultSelectNumberOnly,\n roundingMethod: defaultRoundingMethod,\n leadingZero: defaultLeadingZero,\n minimumValue: defaultMinimumValue,\n maximumValue: defaultMaximumValue\n },\n Swiss: { // Suisse\n digitGroupSeparator: '\\'',\n decimalCharacter: '.',\n currencySymbol: '\\u202FCHF',\n currencySymbolPlacement: 's',\n selectNumberOnly: defaultSelectNumberOnly,\n roundingMethod: defaultRoundingMethod,\n leadingZero: defaultLeadingZero,\n minimumValue: defaultMinimumValue,\n maximumValue: defaultMaximumValue\n },\n Japanese: { // 日本語\n digitGroupSeparator: ',',\n decimalCharacter: '.',\n currencySymbol: '¥',\n currencySymbolPlacement: 'p',\n selectNumberOnly: defaultSelectNumberOnly,\n roundingMethod: defaultRoundingMethod,\n leadingZero: defaultLeadingZero,\n minimumValue: defaultMinimumValue,\n maximumValue: defaultMaximumValue\n }\n};\nlanguageOption.Spanish = languageOption.French; // Español (idem French)\nlanguageOption.Chinese = languageOption.Japanese; // 中国語 (Chinese)\n\n/**\n * UMD structure\n */\n(function (factory) {\n //TODO This surely can be improved by letting webpack take care of generating this UMD part\n if (true) {\n // AMD. Register as an anonymous module.\n !(__WEBPACK_AMD_DEFINE_ARRAY__ = [__webpack_require__(1)], __WEBPACK_AMD_DEFINE_FACTORY__ = (factory), __WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ? (__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));\n } else if ((typeof module === 'undefined' ? 'undefined' : _typeof(module)) === 'object' && module.exports) {\n // Node/CommonJS\n module.exports = factory(require('jquery'));\n } else {\n // Browser globals\n factory(window.jQuery);\n }\n})(function ($) {\n // Helper functions\n\n /**\n * Return TRUE if the `value` is null\n *\n * @static\n * @param {*} value The value to test\n * @returns {boolean} Return TRUE if the `value` is null, FALSE otherwise\n */\n function isNull(value) {\n return value === null;\n }\n\n /**\n * Return TRUE if the `value` is undefined\n *\n * @static\n * @param {*} value The value to test\n * @returns {boolean} Return TRUE if the `value` is undefined, FALSE otherwise\n */\n function isUndefined(value) {\n return value === void 0;\n }\n\n /**\n * Return TRUE if the `value` is undefined, null or empty\n *\n * @param {*} value\n * @returns {boolean}\n */\n function isUndefinedOrNullOrEmpty(value) {\n return value === null || value === void 0 || '' === value;\n }\n\n /**\n * Return TRUE if the given parameter is a String\n *\n * @param {*} str\n * @returns {boolean}\n */\n function isString(str) {\n return typeof str === 'string' || str instanceof String;\n }\n\n /**\n * Return TRUE if the parameter is a boolean\n *\n * @static\n * @param {*} value\n * @returns {boolean}\n */\n function isBoolean(value) {\n return typeof value === 'boolean';\n }\n\n /**\n * Return TRUE if the parameter is a string 'true' or 'false'\n *\n * This function accepts any cases for those strings.\n * @param {string} value\n * @returns {boolean}\n */\n function isTrueOrFalseString(value) {\n var lowercaseValue = String(value).toLowerCase();\n return lowercaseValue === 'true' || lowercaseValue === 'false';\n }\n\n /**\n * Return TRUE if the parameter is an object\n *\n * @param {*} reference\n * @returns {boolean}\n */\n function isObject(reference) {\n return (typeof reference === 'undefined' ? 'undefined' : _typeof(reference)) === 'object' && reference !== null && !Array.isArray(reference);\n }\n\n /**\n * Return TRUE if the given object is empty\n * cf. http://stackoverflow.com/questions/679915/how-do-i-test-for-an-empty-javascript-object and http://jsperf.com/empty-object-test\n *\n * @param {object} obj\n * @returns {boolean}\n */\n function isEmptyObj(obj) {\n for (var prop in obj) {\n if (obj.hasOwnProperty(prop)) {\n return false;\n }\n }\n return true;\n }\n\n /**\n * Return TRUE if the parameter is a number (or a number written as a string).\n *\n * @param {*} n\n * @returns {boolean}\n */\n function isNumber(n) {\n return !isArray(n) && !isNaN(parseFloat(n)) && isFinite(n);\n }\n\n /**\n * Return TRUE if the parameter is an integer (and not a float).\n *\n * @param {*} n\n * @returns {boolean}\n */\n function isInt(n) {\n return typeof n === 'number' && parseFloat(n) === parseInt(n, 10) && !isNaN(n);\n }\n\n /**\n * Return the pasted text that will be used.\n *\n * @param {string} text\n * @param {AutoNumericHolder} holder\n * @returns {string|void|XML|*}\n */\n function preparePastedText(text, holder) {\n return stripAllNonNumberCharacters(text, holder.settingsClone, true).replace(holder.settingsClone.decimalCharacter, '.');\n }\n\n /**\n * Return TRUE is the string `str` contains the string `needle`\n * Note: this function does not coerce the parameters types\n *\n * @param {string} str\n * @param {string} needle\n * @returns {boolean}\n */\n function contains(str, needle) {\n if (!isString(str) || !isString(needle) || str === '' || needle === '') {\n return false;\n }\n\n return str.indexOf(needle) !== -1;\n }\n\n /**\n * Return TRUE if the `needle` is in the array\n *\n * @param {*} needle\n * @param {Array} array\n * @returns {boolean}\n */\n function isInArray(needle, array) {\n if (!isArray(array) || array === [] || isUndefined(needle)) {\n return false;\n }\n\n return array.indexOf(needle) !== -1;\n }\n\n /**\n * Return TRUE if the parameter is an Array\n *\n * @param {*} arr\n * @throws Error\n * @returns {*|boolean}\n */\n function isArray(arr) {\n if (Object.prototype.toString.call([]) === '[object Array]') {\n // Make sure an array has a class attribute of [object Array]\n // Test passed, now check if is an Array\n return Array.isArray(arr) || (typeof arr === 'undefined' ? 'undefined' : _typeof(arr)) === 'object' && Object.prototype.toString.call(arr) === '[object Array]';\n } else {\n throw new Error('toString message changed for Object Array'); // Verify that the string returned by `toString` does not change in the future (cf. http://stackoverflow.com/a/8365215)\n }\n }\n\n /**\n * Return TRUE if the parameter is a string that represents a float number, and that number has a decimal part\n *\n * @param {string} str\n * @returns {boolean}\n */\n // function hasDecimals(str) {\n // const [, decimalPart] = str.split('.');\n // return !isUndefined(decimalPart);\n // }\n\n /**\n * Return the number of decimal places if the parameter is a string that represents a float number, and that number has a decimal part.\n *\n * @param {string} str\n * @returns {int}\n */\n function decimalPlaces(str) {\n var _str$split = str.split('.'),\n _str$split2 = _slicedToArray(_str$split, 2),\n decimalPart = _str$split2[1];\n\n if (!isUndefined(decimalPart)) {\n return decimalPart.length;\n }\n\n return 0;\n }\n\n /**\n * Return the code for the key used to generate the given event.\n *\n * @param {Event} event\n * @returns {string|Number}\n */\n function keyCodeNumber(event) {\n // `event.keyCode` and `event.which` are deprecated, `KeyboardEvent.key` (https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key) must be used now\n return typeof event.which === 'undefined' ? event.keyCode : event.which;\n }\n\n /**\n * Return the character from the event key code.\n * @example character(50) => '2'\n *\n * @param {Event} event\n * @returns {string}\n */\n function character(event) {\n if (typeof event.key === 'undefined' || event.key === 'Unidentified') {\n return String.fromCharCode(this.keyCodeNumber(event));\n } else {\n // Special case for obsolete browsers like IE that return the old names\n var result = void 0;\n switch (event.key) {\n case 'Decimal':\n result = keyName.NumpadDot;\n break;\n case 'Multiply':\n result = keyName.NumpadMultiply;\n break;\n case 'Add':\n result = keyName.NumpadPlus;\n break;\n case 'Subtract':\n result = keyName.NumpadMinus;\n break;\n case 'Divide':\n result = keyName.NumpadSlash;\n break;\n case 'Del':\n // Special workaround for the obsolete browser IE11 which output a 'Delete' key when using the numpad 'dot' one! This fixes issue #401 //FIXME à terminer\n result = keyName.Dot; // as of version 2.0.8 the character() function is only called on keypress event. The 'Del' does not throw the keypress event.\n break;\n default:\n result = event.key;\n }\n\n return result;\n }\n }\n\n /**\n * Return TRUE if the given value (a number as a string) is within the range set in the settings `minimumValue` and `maximumValue`, FALSE otherwise.\n *\n * @param {string} value\n * @param {object} parsedMinValue Parsed via the `parseStr()` function\n * @param {object} parsedMaxValue Parsed via the `parseStr()` function\n * @returns {boolean}\n */\n function checkIfInRange(value, parsedMinValue, parsedMaxValue) {\n var parsedValue = parseStr(value);\n return testMinMax(parsedMinValue, parsedValue) > -1 && testMinMax(parsedMaxValue, parsedValue) < 1;\n }\n\n /**\n * Return TRUE if the given string contains a negative sign :\n * - everywhere in the string (by default), or\n * - on the first character only if the `checkEverywhere` parameter is set to `false`.\n *\n * @param {string} numericString A number represented by a string\n * @param {boolean} checkEverywhere If TRUE, then the negative sign is search everywhere in the numeric string (this is needed for instance if the string is '1234.56-')\n * @returns {boolean}\n */\n function isNegative(numericString) {\n var checkEverywhere = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;\n\n //TODO Use the `negativeSignCharacter` from the settings here\n if (checkEverywhere) {\n return contains(numericString, '-');\n }\n\n return isNegativeStrict(numericString);\n }\n\n /**\n * Return TRUE if the given string contains a negative sign on the first character (on the far left).\n *\n * @example isNegativeStrict('1234.56') => false\n * @example isNegativeStrict('1234.56-') => false\n * @example isNegativeStrict('-1234.56') => true\n * @example isNegativeStrict('-1,234.56 €') => true\n *\n * @param {string} numericString\n * @returns {boolean}\n */\n function isNegativeStrict(numericString) {\n //TODO Using the `negativeSignCharacter` from the settings here\n return numericString.charAt(0) === '-';\n }\n\n /**\n * Return TRUE if the formatted or unformatted numeric string represent the value 0 (ie. '0,00 €'), or is empty (' €').\n * This works since we test if there are any numbers from 1 to 9 in the string. If there is none, then the number is zero (or the string is empty).\n *\n * @param {string} numericString\n * @returns {boolean}\n */\n function isZeroOrHasNoValue(numericString) {\n return !/[1-9]/g.test(numericString);\n }\n\n /**\n * Return the negative version of the value (represented as a string) given as a parameter.\n *\n * @param {string} value\n * @returns {*}\n */\n function setRawNegativeSign(value) {\n if (!isNegativeStrict(value)) {\n return '-' + value;\n }\n\n return value;\n }\n\n /**\n * Replace the character at the position `index` in the string `string` by the character(s) `newCharacter`.\n *\n * @param {string} string\n * @param {int} index\n * @param {string} newCharacter\n * @returns {string}\n */\n function replaceCharAt(string, index, newCharacter) {\n return '' + string.substr(0, index) + newCharacter + string.substr(index + newCharacter.length);\n }\n\n /**\n * Return the value clamped to the nearest minimum/maximum value, as defined in the settings.\n *\n * @param {string|number} value\n * @param {object} settings\n * @returns {number}\n */\n function clampToRangeLimits(value, settings) {\n //XXX This function always assume `settings.minimumValue` is lower than `settings.maximumValue`\n return Math.max(settings.minimumValue, Math.min(settings.maximumValue, value));\n }\n\n /**\n * Return the number of number or dot characters on the left side of the caret, in a formatted number.\n *\n * @param {string} formattedNumberString\n * @param {int} caretPosition This must be a positive integer\n * @param {string} decimalCharacter\n * @returns {number}\n */\n function countNumberCharactersOnTheCaretLeftSide(formattedNumberString, caretPosition, decimalCharacter) {\n // Here we count the dot and report it as a number character too, since it will 'stay' in the Javascript number when unformatted\n var numberDotOrNegativeSign = new RegExp('[0-9' + decimalCharacter + '-]'); // No need to escape the decimal character here, since it's in `[]`\n\n var numberDotAndNegativeSignCount = 0;\n for (var i = 0; i < caretPosition; i++) {\n // Test if the character is a number, a dot or an hyphen. If it is, count it, otherwise ignore it\n if (numberDotOrNegativeSign.test(formattedNumberString[i])) {\n numberDotAndNegativeSignCount++;\n }\n }\n\n return numberDotAndNegativeSignCount;\n }\n\n /**\n * Walk the `formattedNumberString` from left to right, one char by one, counting the `formattedNumberStringIndex`.\n * If the char is in the `rawNumberString` (starting at index 0), then `rawNumberStringIndex++`, and continue until\n * there is no more characters in `rawNumberString`) or that `rawNumberStringIndex === caretPositionInRawValue`.\n * When you stop, the `formattedNumberStringIndex` is the position where the caret should be set.\n *\n * @example\n * 1234567|89.01 : position 7 (rawNumberString)\n * 123.456.7|89,01 : position 9 (formattedNumberString)\n *\n * @param {string} rawNumberString\n * @param {int} caretPositionInRawValue\n * @param {string} formattedNumberString\n * @param {string} decimalCharacter\n * @returns {*}\n */\n function findCaretPositionInFormattedNumber(rawNumberString, caretPositionInRawValue, formattedNumberString, decimalCharacter) {\n var formattedNumberStringSize = formattedNumberString.length;\n var rawNumberStringSize = rawNumberString.length;\n\n var formattedNumberStringIndex = void 0;\n var rawNumberStringIndex = 0;\n for (formattedNumberStringIndex = 0; formattedNumberStringIndex < formattedNumberStringSize && rawNumberStringIndex < rawNumberStringSize && rawNumberStringIndex < caretPositionInRawValue; formattedNumberStringIndex++) {\n if (rawNumberString[rawNumberStringIndex] === formattedNumberString[formattedNumberStringIndex] || rawNumberString[rawNumberStringIndex] === '.' && formattedNumberString[formattedNumberStringIndex] === decimalCharacter) {\n rawNumberStringIndex++;\n }\n }\n\n return formattedNumberStringIndex;\n }\n\n /**\n * Count the number of occurrence of the given character, in the given text.\n *\n * @param {string} character\n * @param {string} text\n * @returns {number}\n */\n function countCharInText(character, text) {\n var charCounter = 0;\n for (var i = 0; i < text.length; i++) {\n if (text[i] === character) {\n charCounter++;\n }\n }\n\n return charCounter;\n }\n\n /**\n * Return the index that can be used to set the caret position.\n * This takes into account that the position is starting at '0', not 1.\n *\n * @param {int} characterCount\n * @returns {number}\n */\n function convertCharacterCountToIndexPosition(characterCount) {\n return Math.max(characterCount, characterCount - 1);\n }\n\n /**\n * Cross browser routine for getting selected range/cursor position\n *\n * @param {HTMLElement|EventTarget} that\n * @returns {{}}\n */\n function getElementSelection(that) {\n var position = {};\n if (isUndefined(that.selectionStart)) {\n that.focus();\n var select = document.selection.createRange();\n position.length = select.text.length;\n select.moveStart('character', -that.value.length);\n position.end = select.text.length;\n position.start = position.end - position.length;\n } else {\n position.start = that.selectionStart;\n position.end = that.selectionEnd;\n position.length = position.end - position.start;\n }\n\n return position;\n }\n\n /**\n * Cross browser routine for setting selected range/cursor position\n *\n * @param {HTMLElement|EventTarget} that\n * @param {int} start\n * @param {int|null} end\n */\n function setElementSelection(that, start) {\n var end = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;\n\n if (isUndefinedOrNullOrEmpty(end)) {\n end = start;\n }\n\n if (isUndefined(that.selectionStart)) {\n that.focus();\n var range = that.createTextRange();\n range.collapse(true);\n range.moveEnd('character', end);\n range.moveStart('character', start);\n range.select();\n } else {\n that.selectionStart = start;\n that.selectionEnd = end;\n }\n }\n\n /**\n * Function that throw error messages\n *\n * @param {string} message\n */\n function throwError(message) {\n throw new Error(message);\n }\n\n /**\n * Function that display a warning messages, according to the debug level.\n *\n * @param {string} message\n * @param {boolean} showWarning If FALSE, then the warning message is not displayed\n */\n function warning(message) {\n var showWarning = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;\n\n if (showWarning) {\n /* eslint no-console: 0 */\n console.warn('Warning: ' + message);\n }\n }\n\n // autoNumeric-specific functions\n\n /**\n * Run any callbacks found in the settings object.\n * Any parameter could be a callback:\n * - a function, which invoked with jQuery element, parameters and this parameter name and returns parameter value\n * - a name of function, attached to $(selector).autoNumeric.functionName(){} - which was called previously\n * @param {object} $this jQuery-selected DOM element\n * @param {object} settings\n */\n function runCallbacksFoundInTheSettingsObject($this, settings) {\n // Loops through the settings object (option array) to find the following\n $.each(settings, function (k, val) {\n if (typeof val === 'function') {\n settings[k] = val($this, settings, k);\n } else if (typeof $this.autoNumeric[val] === 'function') {\n // Calls the attached function from the html5 data example: data-a-sign=\"functionName\"\n settings[k] = $this.autoNumeric[val]($this, settings, k);\n }\n });\n }\n\n /**\n * Determine the maximum decimal length from the minimumValue and maximumValue settings\n *\n * @param {string} minimumValue\n * @param {string} maximumValue\n * @returns {number}\n */\n function maximumVMinAndVMaxDecimalLength(minimumValue, maximumValue) {\n return Math.max(decimalPlaces(minimumValue), decimalPlaces(maximumValue));\n }\n\n /**\n * Strip all unwanted non-number characters.\n * This keeps the numbers, the negative sign as well as the custom decimal character.\n *\n * @param {string} s\n * @param {object} settings\n * @param {boolean} leftOrAll\n * @returns {string|*}\n */\n function stripAllNonNumberCharacters(s, settings, leftOrAll) {\n //TODO This function is called 10 times (sic!) on each key input, couldn't we lower that number? cf. issue #325\n //TODO Refactor this with `convertToNumericString()` if possible?\n if (settings.currencySymbol !== '') {\n // Remove currency sign\n s = s.replace(settings.currencySymbol, '');\n }\n if (settings.suffixText) {\n // Remove suffix\n while (contains(s, settings.suffixText)) {\n s = s.replace(settings.suffixText, '');\n }\n }\n\n // First replace anything before digits\n s = s.replace(settings.skipFirstAutoStrip, '$1$2');\n\n if ((settings.negativePositiveSignPlacement === 's' || settings.currencySymbolPlacement === 's' && settings.negativePositiveSignPlacement !== 'p') && isNegative(s) && s !== '') {\n settings.trailingNegative = true;\n }\n\n // Then replace anything after digits\n s = s.replace(settings.skipLastAutoStrip, '$1');\n\n // Then remove any uninteresting characters\n s = s.replace(settings.allowedAutoStrip, '');\n if (settings.decimalCharacterAlternative) {\n s = s.replace(settings.decimalCharacterAlternative, settings.decimalCharacter);\n }\n\n // Get only number string\n var m = s.match(settings.numRegAutoStrip);\n s = m ? [m[1], m[2], m[3]].join('') : '';\n\n if (settings.leadingZero === 'allow' || settings.leadingZero === 'keep') {\n var nSign = '';\n\n var _s$split = s.split(settings.decimalCharacter),\n _s$split2 = _slicedToArray(_s$split, 2),\n integerPart = _s$split2[0],\n decimalPart = _s$split2[1];\n\n var modifiedIntegerPart = integerPart;\n if (contains(modifiedIntegerPart, settings.negativeSignCharacter)) {\n nSign = settings.negativeSignCharacter;\n modifiedIntegerPart = modifiedIntegerPart.replace(settings.negativeSignCharacter, '');\n }\n\n // Strip leading zero on positive value if need\n if (nSign === '' && modifiedIntegerPart.length > settings.mIntPos && modifiedIntegerPart.charAt(0) === '0') {\n modifiedIntegerPart = modifiedIntegerPart.slice(1);\n }\n\n // Strip leading zero on negative value if need\n if (nSign !== '' && modifiedIntegerPart.length > settings.mIntNeg && modifiedIntegerPart.charAt(0) === '0') {\n modifiedIntegerPart = modifiedIntegerPart.slice(1);\n }\n\n s = '' + nSign + modifiedIntegerPart + (isUndefined(decimalPart) ? '' : settings.decimalCharacter + decimalPart);\n }\n\n if (leftOrAll && settings.leadingZero === 'deny' || !settings.hasFocus && settings.leadingZero === 'allow') {\n s = s.replace(settings.stripReg, '$1$2');\n }\n\n return s;\n }\n\n /**\n * Sets or removes brackets on negative values, depending on the focus state.\n * The focus state is 'stored' in the settings object under the `settings.hasFocus` attribute.\n * //TODO Use another object to keep track of internal data that are not settings\n *\n * @param {string} s\n * @param {object} settings\n * @returns {*}\n */\n function toggleNegativeBracket(s, settings) {\n if (settings.currencySymbolPlacement === 'p' && settings.negativePositiveSignPlacement === 'l' || settings.currencySymbolPlacement === 's' && settings.negativePositiveSignPlacement === 'p') {\n //TODO Split the first and last bracket only once during the settings initialization\n var _settings$negativeBra = settings.negativeBracketsTypeOnBlur.split(','),\n _settings$negativeBra2 = _slicedToArray(_settings$negativeBra, 2),\n firstBracket = _settings$negativeBra2[0],\n lastBracket = _settings$negativeBra2[1];\n\n if (!settings.hasFocus) {\n // Add brackets\n s = s.replace(settings.negativeSignCharacter, '');\n s = firstBracket + s + lastBracket;\n } else if (settings.hasFocus && s.charAt(0) === firstBracket) {\n // Remove brackets\n //TODO Quid if the negative sign is not on the left, shouldn't we replace the '-' sign at the right place?\n s = s.replace(firstBracket, settings.negativeSignCharacter);\n s = s.replace(lastBracket, '');\n }\n }\n\n return s;\n }\n\n /**\n * Return a number as a numeric string that can be typecast to a Number that Javascript will understand.\n *\n * This function return the given string by stripping the currency sign (currencySymbol), the grouping separators (digitalGroupSpacing) and by replacing the decimal character (decimalCharacter) by a dot.\n * Lastly, it also put the negative sign back to its normal position if needed.\n *\n * @param {string} s\n * @param {object} settings\n * @returns {string|void|XML|*}\n */\n function convertToNumericString(s, settings) {\n // Remove the currency symbol\n s = s.replace(settings.currencySymbol, '');\n\n // Remove the grouping separators (thousands separators usually)\n s = s.replace(settings.digitGroupSeparator, '');\n\n // Replace the decimal character by a dot\n if (settings.decimalCharacter !== '.') {\n s = s.replace(settings.decimalCharacter, '.');\n }\n\n // Move the trailing negative sign to the right position, if any\n if (isNegative(s) && s.lastIndexOf('-') === s.length - 1) {\n s = s.replace('-', '');\n s = '-' + s;\n }\n\n // Convert any arabic numbers to latin ones\n var temp = arabicToLatinNumbers(s, true, false, false);\n if (!isNaN(temp)) {\n s = temp.toString();\n }\n\n return s;\n }\n\n /**\n * Converts the ISO numeric string to the locale decimal and minus sign placement.\n * See the \"outputFormat\" option definition for more details.\n *\n * @param {string|null} value\n * @param {string} locale\n * @returns {*}\n */\n function toLocale(value, locale) {\n if (isNull(locale) || locale === 'string') {\n return value;\n }\n\n var result = void 0;\n switch (locale) {\n case 'number':\n result = Number(value);\n break;\n case '.-':\n result = isNegative(value) ? value.replace('-', '') + '-' : value;\n break;\n case ',':\n case '-,':\n result = value.replace('.', ',');\n break;\n case ',-':\n result = value.replace('.', ',');\n result = isNegative(result) ? result.replace('-', '') + '-' : result;\n break;\n // The default case\n case '.':\n case '-.':\n result = value;\n break;\n default:\n throwError('The given outputFormat [' + locale + '] option is not recognized.');\n }\n\n return result;\n }\n\n /**\n * Modify the negative sign and the decimal character of the given string value to an hyphen (-) and a dot (.) in order to make that value 'typecastable' to a real number.\n *\n * @param {string} s\n * @param {object} settings\n * @returns {string}\n */\n function modifyNegativeSignAndDecimalCharacterForRawValue(s, settings) {\n if (settings.decimalCharacter !== '.') {\n s = s.replace(settings.decimalCharacter, '.');\n }\n if (settings.negativeSignCharacter !== '-' && settings.negativeSignCharacter !== '') {\n s = s.replace(settings.negativeSignCharacter, '-');\n }\n if (!s.match(/\\d/)) {\n // The default value returned by `get` is not formatted with decimals\n s += '0';\n }\n\n return s;\n }\n\n /**\n * Modify the negative sign and the decimal character to use those defined in the settings.\n *\n * @param {string} s\n * @param {object} settings\n * @returns {string}\n */\n function modifyNegativeSignAndDecimalCharacterForFormattedValue(s, settings) {\n if (settings.negativeSignCharacter !== '-' && settings.negativeSignCharacter !== '') {\n s = s.replace('-', settings.negativeSignCharacter);\n }\n if (settings.decimalCharacter !== '.') {\n s = s.replace('.', settings.decimalCharacter);\n }\n\n return s;\n }\n\n /**\n * Private function to check for empty value\n * //TODO Modify this function so that it return either TRUE or FALSE if the value is empty. Then create another function to return the input value if it's not empty.\n *\n * @param {string} inputValue\n * @param {object} settings\n * @param {boolean} signOnEmpty\n * @returns {*}\n */\n function checkEmpty(inputValue, settings, signOnEmpty) {\n if (inputValue === '' || inputValue === settings.negativeSignCharacter) {\n if (settings.emptyInputBehavior === 'always' || signOnEmpty) {\n return settings.negativePositiveSignPlacement === 'l' ? inputValue + settings.currencySymbol + settings.suffixText : settings.currencySymbol + inputValue + settings.suffixText;\n }\n\n return inputValue;\n }\n\n return null;\n }\n\n /**\n * Modify the input value by adding the group separators, as defined in the settings.\n *\n * @param {string} inputValue\n * @param {object} settings\n * @returns {*}\n */\n function addGroupSeparators(inputValue, settings) {\n if (settings.strip) {\n inputValue = stripAllNonNumberCharacters(inputValue, settings, false);\n }\n\n //TODO This function `addGroupSeparators()` add group separators. Adding the negative sign as well is out of its scope. Move that to another function.\n if (settings.trailingNegative && !isNegative(inputValue)) {\n inputValue = '-' + inputValue;\n }\n\n var empty = checkEmpty(inputValue, settings, true);\n var isValueNegative = isNegative(inputValue);\n var isZero = isZeroOrHasNoValue(inputValue);\n if (isValueNegative) {\n inputValue = inputValue.replace('-', '');\n }\n\n if (!isNull(empty)) {\n return empty;\n }\n\n settings.digitalGroupSpacing = settings.digitalGroupSpacing.toString();\n var digitalGroup = void 0;\n switch (settings.digitalGroupSpacing) {\n case '2':\n digitalGroup = /(\\d)((\\d)(\\d{2}?)+)$/;\n break;\n case '2s':\n digitalGroup = /(\\d)((?:\\d{2}){0,2}\\d{3}(?:(?:\\d{2}){2}\\d{3})*?)$/;\n break;\n case '4':\n digitalGroup = /(\\d)((\\d{4}?)+)$/;\n break;\n default:\n digitalGroup = /(\\d)((\\d{3}?)+)$/;\n }\n\n // Splits the string at the decimal string\n\n var _inputValue$split = inputValue.split(settings.decimalCharacter),\n _inputValue$split2 = _slicedToArray(_inputValue$split, 2),\n integerPart = _inputValue$split2[0],\n decimalPart = _inputValue$split2[1];\n\n if (settings.decimalCharacterAlternative && isUndefined(decimalPart)) {\n var _inputValue$split3 = inputValue.split(settings.decimalCharacterAlternative);\n\n var _inputValue$split4 = _slicedToArray(_inputValue$split3, 2);\n\n integerPart = _inputValue$split4[0];\n decimalPart = _inputValue$split4[1];\n }\n\n if (settings.digitGroupSeparator !== '') {\n // Re-inserts the thousand separator via a regular expression\n while (digitalGroup.test(integerPart)) {\n integerPart = integerPart.replace(digitalGroup, '$1' + settings.digitGroupSeparator + '$2');\n }\n }\n\n if (settings.decimalPlacesOverride !== 0 && !isUndefined(decimalPart)) {\n if (decimalPart.length > settings.decimalPlacesOverride) {\n decimalPart = decimalPart.substring(0, settings.decimalPlacesOverride);\n }\n\n // Joins the whole number with the decimal value\n inputValue = integerPart + settings.decimalCharacter + decimalPart;\n } else {\n // Otherwise if it's an integer\n inputValue = integerPart;\n }\n\n settings.trailingNegative = false;\n\n if (settings.currencySymbolPlacement === 'p') {\n if (isValueNegative) {\n switch (settings.negativePositiveSignPlacement) {\n case 'l':\n inputValue = '' + settings.negativeSignCharacter + settings.currencySymbol + inputValue;\n break;\n case 'r':\n inputValue = '' + settings.currencySymbol + settings.negativeSignCharacter + inputValue;\n break;\n case 's':\n inputValue = '' + settings.currencySymbol + inputValue + settings.negativeSignCharacter;\n settings.trailingNegative = true;\n break;\n default:\n //\n }\n } else if (settings.showPositiveSign && !isZero) {\n switch (settings.negativePositiveSignPlacement) {\n case 'l':\n inputValue = '' + settings.positiveSignCharacter + settings.currencySymbol + inputValue;\n break;\n case 'r':\n inputValue = '' + settings.currencySymbol + settings.positiveSignCharacter + inputValue;\n break;\n case 's':\n inputValue = '' + settings.currencySymbol + inputValue + settings.positiveSignCharacter;\n break;\n default:\n //\n }\n } else {\n inputValue = settings.currencySymbol + inputValue;\n }\n }\n\n if (settings.currencySymbolPlacement === 's') {\n if (isValueNegative) {\n switch (settings.negativePositiveSignPlacement) {\n case 'r':\n inputValue = '' + inputValue + settings.currencySymbol + settings.negativeSignCharacter;\n settings.trailingNegative = true;\n break;\n case 'l':\n inputValue = '' + inputValue + settings.negativeSignCharacter + settings.currencySymbol;\n settings.trailingNegative = true;\n break;\n case 'p':\n inputValue = '' + settings.negativeSignCharacter + inputValue + settings.currencySymbol;\n break;\n default:\n //\n }\n } else if (settings.showPositiveSign && !isZero) {\n switch (settings.negativePositiveSignPlacement) {\n case 'r':\n inputValue = '' + inputValue + settings.currencySymbol + settings.positiveSignCharacter;\n break;\n case 'l':\n inputValue = '' + inputValue + settings.positiveSignCharacter + settings.currencySymbol;\n break;\n case 'p':\n inputValue = '' + settings.positiveSignCharacter + inputValue + settings.currencySymbol;\n break;\n default:\n //\n }\n } else {\n inputValue = inputValue + settings.currencySymbol;\n }\n }\n\n // Removes the negative sign and places brackets\n if (settings.negativeBracketsTypeOnBlur !== null && (settings.rawValue < 0 || isNegativeStrict(inputValue))) {\n inputValue = toggleNegativeBracket(inputValue, settings);\n }\n\n return inputValue + settings.suffixText;\n }\n\n /**\n * Truncate not needed zeros\n *\n * @param {string} roundedInputValue\n * @param {int} temporaryDecimalPlacesOverride\n * @returns {void|XML|string|*}\n */\n function truncateZeros(roundedInputValue, temporaryDecimalPlacesOverride) {\n var regex = void 0;\n switch (temporaryDecimalPlacesOverride) {\n case 0:\n // Prevents padding - removes trailing zeros until the first significant digit is encountered\n regex = /(\\.(?:\\d*[1-9])?)0*$/;\n break;\n case 1:\n // Allows padding when decimalPlacesOverride equals one - leaves one zero trailing the decimal character\n regex = /(\\.\\d(?:\\d*[1-9])?)0*$/;\n break;\n default:\n // Removes access zeros to the decimalPlacesOverride length when allowDecimalPadding is set to true\n regex = new RegExp('(\\\\.\\\\d{' + temporaryDecimalPlacesOverride + '}(?:\\\\d*[1-9])?)0*');\n }\n\n // If there are no decimal places, we don't need a decimal point at the end\n roundedInputValue = roundedInputValue.replace(regex, '$1');\n if (temporaryDecimalPlacesOverride === 0) {\n roundedInputValue = roundedInputValue.replace(/\\.$/, '');\n }\n\n return roundedInputValue;\n }\n\n /**\n * Round the input value using the rounding method defined in the settings.\n * This function accepts multiple rounding methods. See the documentation for more details about those.\n *\n * Note : This is handled as text since JavaScript math function can return inaccurate values.\n *\n * @param {string} inputValue\n * @param {object} settings\n * @returns {*}\n */\n function roundValue(inputValue, settings) {\n inputValue = inputValue === '' ? '0' : inputValue.toString();\n if (settings.roundingMethod === 'N05' || settings.roundingMethod === 'CHF' || settings.roundingMethod === 'U05' || settings.roundingMethod === 'D05') {\n switch (settings.roundingMethod) {\n case 'N05':\n inputValue = (Math.round(inputValue * 20) / 20).toString();\n break;\n case 'U05':\n inputValue = (Math.ceil(inputValue * 20) / 20).toString();\n break;\n default:\n inputValue = (Math.floor(inputValue * 20) / 20).toString();\n }\n\n var result = void 0;\n if (!contains(inputValue, '.')) {\n result = inputValue + '.00';\n } else if (inputValue.length - inputValue.indexOf('.') < 3) {\n result = inputValue + '0';\n } else {\n result = inputValue;\n }\n return result;\n }\n\n var ivRounded = '';\n var i = 0;\n var nSign = '';\n var temporaryDecimalPlacesOverride = void 0;\n\n // sets the truncate zero method\n if (settings.allowDecimalPadding) {\n temporaryDecimalPlacesOverride = settings.decimalPlacesOverride;\n } else {\n temporaryDecimalPlacesOverride = 0;\n }\n\n // Checks if the inputValue (input Value) is a negative value\n if (isNegativeStrict(inputValue)) {\n nSign = '-';\n\n // Removes the negative sign that will be added back later if required\n inputValue = inputValue.replace('-', '');\n }\n\n // Append a zero if the first character is not a digit (then it is likely to be a dot)\n if (!inputValue.match(/^\\d/)) {\n inputValue = '0' + inputValue;\n }\n\n // Determines if the value is equal to zero. If it is, remove the negative sign\n if (Number(inputValue) === 0) {\n nSign = '';\n }\n\n // Trims leading zero's as needed\n if (Number(inputValue) > 0 && settings.leadingZero !== 'keep' || inputValue.length > 0 && settings.leadingZero === 'allow') {\n inputValue = inputValue.replace(/^0*(\\d)/, '$1');\n }\n\n var dPos = inputValue.lastIndexOf('.');\n var inputValueHasADot = dPos === -1;\n\n // Virtual decimal position\n var vdPos = inputValueHasADot ? inputValue.length - 1 : dPos;\n\n // Checks decimal places to determine if rounding is required :\n // Check if no rounding is required\n var cDec = inputValue.length - 1 - vdPos;\n\n if (cDec <= settings.decimalPlacesOverride) {\n // Check if we need to pad with zeros\n ivRounded = inputValue;\n if (cDec < temporaryDecimalPlacesOverride) {\n if (inputValueHasADot) {\n ivRounded += settings.decimalCharacter;\n }\n\n var zeros = '000000';\n while (cDec < temporaryDecimalPlacesOverride) {\n zeros = zeros.substring(0, temporaryDecimalPlacesOverride - cDec);\n ivRounded += zeros;\n cDec += zeros.length;\n }\n } else if (cDec > temporaryDecimalPlacesOverride) {\n ivRounded = truncateZeros(ivRounded, temporaryDecimalPlacesOverride);\n } else if (cDec === 0 && temporaryDecimalPlacesOverride === 0) {\n ivRounded = ivRounded.replace(/\\.$/, '');\n }\n\n return Number(ivRounded) === 0 ? ivRounded : nSign + ivRounded;\n }\n\n // Rounded length of the string after rounding\n var rLength = void 0;\n if (inputValueHasADot) {\n rLength = settings.decimalPlacesOverride - 1;\n } else {\n rLength = settings.decimalPlacesOverride + dPos;\n }\n\n var tRound = Number(inputValue.charAt(rLength + 1));\n var odd = inputValue.charAt(rLength) === '.' ? inputValue.charAt(rLength - 1) % 2 : inputValue.charAt(rLength) % 2;\n var ivArray = inputValue.substring(0, rLength + 1).split('');\n\n if (tRound > 4 && settings.roundingMethod === 'S' || // Round half up symmetric\n tRound > 4 && settings.roundingMethod === 'A' && nSign === '' || // Round half up asymmetric positive values\n tRound > 5 && settings.roundingMethod === 'A' && nSign === '-' || // Round half up asymmetric negative values\n tRound > 5 && settings.roundingMethod === 's' || // Round half down symmetric\n tRound > 5 && settings.roundingMethod === 'a' && nSign === '' || // Round half down asymmetric positive values\n tRound > 4 && settings.roundingMethod === 'a' && nSign === '-' || // Round half down asymmetric negative values\n tRound > 5 && settings.roundingMethod === 'B' || // Round half even \"Banker's Rounding\"\n tRound === 5 && settings.roundingMethod === 'B' && odd === 1 || // Round half even \"Banker's Rounding\"\n tRound > 0 && settings.roundingMethod === 'C' && nSign === '' || // Round to ceiling toward positive infinite\n tRound > 0 && settings.roundingMethod === 'F' && nSign === '-' || // Round to floor toward negative infinite\n tRound > 0 && settings.roundingMethod === 'U') {\n // Round up away from zero\n // Round up the last digit if required, and continue until no more 9's are found\n for (i = ivArray.length - 1; i >= 0; i -= 1) {\n if (ivArray[i] !== '.') {\n ivArray[i] = +ivArray[i] + 1;\n if (ivArray[i] < 10) {\n break;\n }\n\n if (i > 0) {\n ivArray[i] = '0';\n }\n }\n }\n }\n\n // Reconstruct the string, converting any 10's to 0's\n ivArray = ivArray.slice(0, rLength + 1);\n\n // Return the rounded value\n ivRounded = truncateZeros(ivArray.join(''), temporaryDecimalPlacesOverride);\n\n return Number(ivRounded) === 0 ? ivRounded : nSign + ivRounded;\n }\n\n /**\n * Truncates the decimal part of a number.\n *\n * @param {string} s\n * @param {object} settings\n * @param {boolean} isPaste\n * @returns {*}\n */\n function truncateDecimal(s, settings, isPaste) {\n s = isPaste ? roundValue(s, settings) : s;\n\n if (settings.decimalCharacter && settings.decimalPlacesOverride) {\n var _s$split3 = s.split(settings.decimalCharacter),\n _s$split4 = _slicedToArray(_s$split3, 2),\n integerPart = _s$split4[0],\n decimalPart = _s$split4[1];\n\n // truncate decimal part to satisfying length since we would round it anyway\n\n\n if (decimalPart && decimalPart.length > settings.decimalPlacesOverride) {\n if (settings.decimalPlacesOverride > 0) {\n var modifiedDecimalPart = decimalPart.substring(0, settings.decimalPlacesOverride);\n s = '' + integerPart + settings.decimalCharacter + modifiedDecimalPart;\n } else {\n s = integerPart;\n }\n }\n }\n\n return s;\n }\n\n /**\n * Function to parse minimumValue, maximumValue & the input value to prepare for testing to determine if the value falls within the min / max range.\n * Return an object example: minimumValue: \"999999999999999.99\" returns the following \"{s: -1, e: 12, c: Array[15]}\".\n *\n * This function is adapted from Big.js https://github.com/MikeMcl/big.js/. Many thanks to Mike.\n *\n * @param {number|string} n A numeric value.\n * @returns {{}}\n */\n function parseStr(n) {\n var x = {}; // A Big number instance.\n var e = void 0;\n var i = void 0;\n var nL = void 0;\n var j = void 0;\n\n // Minus zero?\n if (n === 0 && 1 / n < 0) {\n n = '-0';\n }\n\n // Determine sign. 1 positive, -1 negative\n n = n.toString();\n if (isNegativeStrict(n)) {\n n = n.slice(1);\n x.s = -1;\n } else {\n x.s = 1;\n }\n\n // Decimal point?\n e = n.indexOf('.');\n if (e > -1) {\n n = n.replace('.', '');\n }\n\n // length of string if no decimal character\n if (e < 0) {\n // Integer\n e = n.length;\n }\n\n // Determine leading zeros\n i = n.search(/[1-9]/i) === -1 ? n.length : n.search(/[1-9]/i);\n nL = n.length;\n if (i === nL) {\n // Zero\n x.e = 0;\n x.c = [0];\n } else {\n // Determine trailing zeros\n for (j = nL - 1; n.charAt(j) === '0'; j -= 1) {\n nL -= 1;\n }\n nL -= 1;\n\n // Decimal location\n x.e = e - i - 1;\n x.c = [];\n\n // Convert string to array of digits without leading/trailing zeros\n for (e = 0; i <= nL; i += 1) {\n x.c[e] = +n.charAt(i);\n e += 1;\n }\n }\n\n return x;\n }\n\n /**\n * Function to test if the input value falls with the Min / Max settings.\n * This uses the parsed strings for the above parseStr function.\n *\n * This function is adapted from Big.js https://github.com/MikeMcl/big.js/. Many thanks to Mike.\n *\n * @param {object} y Big number instance\n * @param {object} x Big number instance\n * @returns {*}\n */\n function testMinMax(y, x) {\n var xc = x.c;\n var yc = y.c;\n var i = x.s;\n var j = y.s;\n var k = x.e;\n var l = y.e;\n\n // Either zero?\n if (!xc[0] || !yc[0]) {\n var _result = void 0;\n if (!xc[0]) {\n _result = !yc[0] ? 0 : -j;\n } else {\n _result = i;\n }\n return _result;\n }\n\n // Signs differ?\n if (i !== j) {\n return i;\n }\n var xNeg = i < 0;\n\n // Compare exponents\n if (k !== l) {\n return k > l ^ xNeg ? 1 : -1;\n }\n i = -1;\n k = xc.length;\n l = yc.length;\n j = k < l ? k : l;\n\n // Compare digit by digit\n for (i += 1; i < j; i += 1) {\n if (xc[i] !== yc[i]) {\n return xc[i] > yc[i] ^ xNeg ? 1 : -1;\n }\n }\n\n // Compare lengths\n var result = void 0;\n if (k === l) {\n result = 0;\n } else {\n result = k > l ^ xNeg ? 1 : -1;\n }\n\n return result;\n }\n\n /**\n * Check that the number satisfy the format conditions\n * and lays between settings.minimumValue and settings.maximumValue\n * and the string length does not exceed the digits in settings.minimumValue and settings.maximumValue\n *\n * @param {string} s\n * @param {object} settings\n * @returns {*}\n */\n function checkIfInRangeWithOverrideOption(s, settings) {\n s = s.toString();\n s = s.replace(',', '.');\n var minParse = parseStr(settings.minimumValue);\n var maxParse = parseStr(settings.maximumValue);\n var valParse = parseStr(s);\n\n var result = void 0;\n switch (settings.overrideMinMaxLimits) {\n case 'floor':\n result = [testMinMax(minParse, valParse) > -1, true];\n break;\n case 'ceiling':\n result = [true, testMinMax(maxParse, valParse) < 1];\n break;\n case 'ignore':\n result = [true, true];\n break;\n default:\n result = [testMinMax(minParse, valParse) > -1, testMinMax(maxParse, valParse) < 1];\n }\n\n return result;\n }\n\n /**\n * Thanks to Anthony & Evan C\n *\n * @param {Element|string} element\n * @returns {*|jQuery|HTMLElement}\n */\n function getCurrentElement(element) {\n /*\n * If the parameter is a string (and therefore is a CSS selector), then we need to modify this string in order\n * for jQuery to be able to parse the selector correctly.\n * cf. http://learn.jquery.com/using-jquery-core/faq/how-do-i-select-an-element-by-an-id-that-has-characters-used-in-css-notation/\n */\n if (isString(element)) {\n //TODO This block is apparently never entered. We should remove it after making sure that's 100% the case\n element = '#' + element.replace(/(:|\\.|\\[|]|,|=)/g, '\\\\$1');\n }\n\n return $(element);\n }\n\n /**\n * Function that attach the autoNumeric field properties to the DOM element via an AutoNumericHolder object.\n *\n * @param {object} $this jQuery-selected DOM element\n * @param {object} settings\n * @param {boolean} update\n * @returns {*}\n */\n function getAutoNumericHolder($this, settings) {\n var update = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;\n\n var data = $this.data('autoNumeric');\n if (!data) {\n data = {};\n $this.data('autoNumeric', data);\n }\n\n var holder = data.holder;\n if (update || isUndefined(holder) && settings) {\n holder = new AutoNumericHolder($this.get(0), settings);\n data.holder = holder;\n }\n\n return holder;\n }\n\n /**\n * Original settings saved for use when decimalPlacesShownOnFocus & noSeparatorOnFocus options are being used.\n * Those original settings are used exclusively in the `focusin` and `focusout` event handlers.\n *\n * @param {object} settings\n */\n function keepAnOriginalSettingsCopy(settings) {\n //TODO Rename the old option names to the new ones\n settings.oDec = settings.decimalPlacesOverride;\n settings.oPad = settings.allowDecimalPadding;\n settings.oBracket = settings.negativeBracketsTypeOnBlur;\n settings.oSep = settings.digitGroupSeparator;\n settings.oSign = settings.currencySymbol;\n settings.oSuffix = settings.suffixText;\n }\n\n /**\n * Original settings saved for use when `decimalPlacesShownOnFocus` & `noSeparatorOnFocus` options are being used.\n * This is taken from Quirksmode.\n *\n * @param {string} name\n * @returns {*}\n */\n function readCookie(name) {\n var nameEQ = name + '=';\n var ca = document.cookie.split(';');\n var c = '';\n for (var i = 0; i < ca.length; i += 1) {\n c = ca[i];\n while (c.charAt(0) === ' ') {\n c = c.substring(1, c.length);\n }\n if (c.indexOf(nameEQ) === 0) {\n return c.substring(nameEQ.length, c.length);\n }\n }\n\n return null;\n }\n\n /**\n * Test if sessionStorage is supported.\n * This is taken from Modernizr.\n *\n * @returns {boolean}\n */\n function storageTest() {\n var mod = 'modernizr';\n try {\n sessionStorage.setItem(mod, mod);\n sessionStorage.removeItem(mod);\n return true;\n } catch (e) {\n return false;\n }\n }\n\n /**\n * properly formats the string to a numeric when leadingZero does not 'keep'.\n *\n * @param {string} value\n * @param {object} settings\n * @returns {string}\n */\n function cleanLeadingTrailingZeros(value, settings) {\n // Return the empty string is the value is already empty. This prevent converting that value to '0'.\n if (value === '') {\n return '';\n }\n\n // Return '0' if the value is zero\n if (Number(value) === 0 && settings.leadingZero !== 'keep') {\n return '0';\n }\n\n if (settings.leadingZero !== 'keep') {\n // Trim leading zero's - leaves one zero to the left of the decimal point\n value = value.replace(/^(-)?0+(?=\\d)/g, '$1');\n\n //TODO remove this from that function and use `trimPaddedZerosFromDecimalPlaces()` instead. Also create a new `trailingZero` option.\n if (contains(value, '.')) {\n // Trims trailing zeros after the decimal point\n value = value.replace(/(\\.[0-9]*?)0+$/, '$1');\n }\n }\n // Strips trailing decimal point\n value = value.replace(/\\.$/, '');\n\n return value;\n }\n\n /**\n * Remove the trailing zeros in the decimal part of a number.\n *\n * @param {string} numericString\n * @returns {*}\n */\n function trimPaddedZerosFromDecimalPlaces(numericString) {\n var _numericString$split = numericString.split('.'),\n _numericString$split2 = _slicedToArray(_numericString$split, 2),\n integerPart = _numericString$split2[0],\n decimalPart = _numericString$split2[1];\n\n if (isUndefinedOrNullOrEmpty(decimalPart)) {\n return integerPart;\n }\n\n var trimmedDecimalPart = decimalPart.replace(/0+$/g, '');\n\n var result = void 0;\n if (trimmedDecimalPart === '') {\n result = integerPart;\n } else {\n result = integerPart + '.' + trimmedDecimalPart;\n }\n\n return result;\n }\n\n /**\n * Creates or removes sessionStorage or cookie depending on what the browser is supporting.\n *\n * @param {Element|EventTarget} element\n * @param {object} settings\n * @param {string} action\n * @returns {*}\n */\n function saveValueToPersistentStorage(element, settings, action) {\n if (settings.saveValueToSessionStorage) {\n var storedName = element.name !== '' && !isUndefined(element.name) ? 'AUTO_' + decodeURIComponent(element.name) : 'AUTO_' + element.id;\n var date = void 0;\n var expires = void 0;\n\n // Sets cookie for browser that do not support sessionStorage IE 6 & IE 7\n if (storageTest() === false) {\n switch (action) {\n case 'set':\n document.cookie = storedName + '=' + settings.rawValue + '; expires= ; path=/';\n break;\n case 'wipe':\n date = new Date();\n date.setTime(date.getTime() + -1 * 24 * 60 * 60 * 1000);\n expires = '; expires=' + date.toUTCString(); // Note : `toGMTString()` has been deprecated (cf. https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toGMTString)\n document.cookie = storedName + '=\\'\\' ;' + expires + '; path=/';\n break;\n case 'get':\n return readCookie(storedName);\n }\n } else {\n switch (action) {\n case 'set':\n sessionStorage.setItem(storedName, settings.rawValue);\n break;\n case 'wipe':\n sessionStorage.removeItem(storedName);\n break;\n case 'get':\n return sessionStorage.getItem(storedName);\n }\n }\n }\n }\n\n /**\n * Holder object for field properties\n */\n\n var AutoNumericHolder = function () {\n /**\n * Class constructor\n *\n * @param {HTMLElement} that - A reference to the current DOM element\n * @param {object} settings\n */\n function AutoNumericHolder(that, settings) {\n _classCallCheck(this, AutoNumericHolder);\n\n this.settings = settings;\n this.that = that;\n this.$that = $(that);\n this.formatted = false;\n this.settingsClone = settings;\n this.value = that.value;\n }\n\n /**\n * Update the value and the selection values inside the AutoNumericHolder object.\n * This keeps tracks of the input value, as well as the current selection.\n * This also resets the 'processed' and 'formatted' state.\n *\n * Note : Those two can change between the keydown, keypress and keyup events, that's why\n * this function is called on each event handler.\n *\n * @private\n */\n\n\n _createClass(AutoNumericHolder, [{\n key: '_updateAutoNumericHolderProperties',\n value: function _updateAutoNumericHolderProperties() {\n this.value = this.that.value;\n this.selection = getElementSelection(this.that);\n this.processed = false;\n this.formatted = false;\n }\n\n /**\n * Update the keycode of the key that triggered the given event.\n * Note : e.which is sometimes different than e.keyCode during the keypress event, when entering a printable character key (ie. 't'). `e.which` equals 0 for non-printable characters.\n *\n * //TODO Switch to the non-deprecated e.key attribute, instead of inconsistant e.which and e.keyCode.\n * e.key describe the key name used to trigger the event.\n * e.keyCode being deprecated : https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/keyCode\n * How e.key works : https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key\n * The key list is described here\n * @link https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/key/Key_Values\n *\n * @param {Event} e\n * @private\n */\n\n }, {\n key: '_updateAutoNumericHolderEventKeycode',\n value: function _updateAutoNumericHolderEventKeycode(e) {\n // Note: the keypress event overwrites meaningful value of e.keyCode, hence we do not update that value on 'keypress'\n this.eventKeyCode = keyCodeNumber(e);\n }\n\n /**\n * Set the text selection inside the input with the given start and end position.\n *\n * @param {int} start\n * @param {int} end\n * @param {undefined|boolean} setReal\n * @private\n */\n\n }, {\n key: '_setSelection',\n value: function _setSelection(start, end, setReal) {\n //TODO Modify setReal to be more explicit (and a boolean)\n start = Math.max(start, 0);\n end = Math.min(end, this.that.value.length); //TODO Replace `this.that.value.length` with `this.value.length`\n this.selection = {\n start: start,\n end: end,\n length: end - start\n };\n\n if (isUndefined(setReal) || setReal) {\n setElementSelection(this.that, start, end);\n }\n }\n\n /**\n * Set the caret position inside the input at the given position.\n *\n * @param {int} pos\n * @param {undefined|boolean} setReal\n * @private\n */\n\n }, {\n key: '_setCaretPosition',\n value: function _setCaretPosition(pos, setReal) {\n //TODO Modify setReal to be more explicit (and a boolean)\n this._setSelection(pos, pos, setReal);\n }\n\n /**\n * Return an array containing the string parts located on the left and right side of the caret or selection.\n * Those parts are left 'untouched', ie. formatted by autoNumeric.\n *\n * @returns {[string, string]} The parts on the left and right of the caret or selection\n * @private\n */\n\n }, {\n key: '_getLeftAndRightPartAroundTheSelection',\n value: function _getLeftAndRightPartAroundTheSelection() {\n var value = this.value;\n var left = value.substring(0, this.selection.start);\n var right = value.substring(this.selection.end, value.length);\n\n return [left, right];\n }\n\n /**\n * Return an array containing the string parts located on the left and right side of the caret or selection.\n * Those parts are unformatted (stripped) of any non-numbers characters.\n *\n * @returns {[string, string]} The parts on the left and right of the caret or selection, unformatted.\n * @private\n */\n\n }, {\n key: '_getUnformattedLeftAndRightPartAroundTheSelection',\n value: function _getUnformattedLeftAndRightPartAroundTheSelection() {\n var settingsClone = this.settingsClone;\n\n var _getLeftAndRightPartA = this._getLeftAndRightPartAroundTheSelection(),\n _getLeftAndRightPartA2 = _slicedToArray(_getLeftAndRightPartA, 2),\n left = _getLeftAndRightPartA2[0],\n right = _getLeftAndRightPartA2[1];\n\n if (left === '' && right === '') {\n settingsClone.trailingNegative = false;\n }\n // if changing the sign and left is equal to the number zero - prevents stripping the leading zeros\n var stripZeros = true;\n if (this.eventKeyCode === keyCode.Hyphen && Number(left) === 0) {\n stripZeros = false;\n }\n left = stripAllNonNumberCharacters(left, this.settingsClone, stripZeros);\n right = stripAllNonNumberCharacters(right, this.settingsClone, false);\n\n if (settingsClone.trailingNegative && !isNegative(left)) {\n left = '-' + left;\n right = right === '-' ? '' : right;\n settingsClone.trailingNegative = false;\n }\n\n return [left, right];\n }\n\n /**\n * Strip parts from excess characters and leading zeros.\n *\n * @param {string} left\n * @param {string} right\n * @returns {[*,*]}\n * @private\n */\n\n }, {\n key: '_normalizeParts',\n value: function _normalizeParts(left, right) {\n var settingsClone = this.settingsClone;\n\n // if changing the sign and left is equal to the number zero - prevents stripping the leading zeros\n var stripZeros = true;\n if (this.eventKeyCode === keyCode.Hyphen && Number(left) === 0) {\n stripZeros = false;\n }\n left = stripAllNonNumberCharacters(left, settingsClone, stripZeros);\n\n // If right is not empty and first character is not decimalCharacter\n right = stripAllNonNumberCharacters(right, settingsClone, false);\n\n // Prevents multiple leading zeros from being entered\n if (settingsClone.leadingZero === 'deny' && (this.eventKeyCode === keyCode.num0 || this.eventKeyCode === keyCode.numpad0) && Number(left) === 0 && !contains(left, settingsClone.decimalCharacter) && right !== '') {\n left = left.substring(0, left.length - 1);\n }\n\n if (settingsClone.trailingNegative && !isNegative(left)) {\n left = '-' + left;\n settingsClone.trailingNegative = false;\n }\n\n // Insert zero if has leading dot\n this.newValue = left + right;\n if (settingsClone.decimalCharacter) {\n var m = this.newValue.match(new RegExp('^' + settingsClone.aNegRegAutoStrip + '\\\\' + settingsClone.decimalCharacter));\n if (m) {\n left = left.replace(m[1], m[1] + '0');\n this.newValue = left + right;\n }\n }\n\n return [left, right];\n }\n\n /**\n * Set part of number to value while keeping the cursor position. //TODO What about the cursor selection?\n *\n * @param {string} left\n * @param {string} right\n * @param {boolean} isPaste\n * @returns {boolean}\n * @private\n */\n\n }, {\n key: '_setValueParts',\n value: function _setValueParts(left, right) {\n var isPaste = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;\n\n var settingsClone = this.settingsClone;\n var parts = this._normalizeParts(left, right);\n\n var _checkIfInRangeWithOv = checkIfInRangeWithOverrideOption(this.newValue, settingsClone),\n _checkIfInRangeWithOv2 = _slicedToArray(_checkIfInRangeWithOv, 2),\n minTest = _checkIfInRangeWithOv2[0],\n maxTest = _checkIfInRangeWithOv2[1];\n\n var position = parts[0].length;\n this.newValue = parts.join('');\n\n if (minTest && maxTest) {\n this.newValue = truncateDecimal(this.newValue, settingsClone, isPaste);\n //TODO Check if we need to replace the hard-coded ',' with settings.decimalCharacter\n var testValue = contains(this.newValue, ',') ? this.newValue.replace(',', '.') : this.newValue;\n if (testValue === '' || testValue === settingsClone.negativeSignCharacter) {\n settingsClone.rawValue = settingsClone.emptyInputBehavior === 'zero' ? '0' : '';\n } else {\n settingsClone.rawValue = cleanLeadingTrailingZeros(testValue, settingsClone);\n }\n\n if (position > this.newValue.length) {\n position = this.newValue.length;\n }\n\n // Make sure when the user enter a '0' on the far left with a leading zero option set to 'deny', that the caret does not moves since the input is dropped (fix issue #283)\n if (position === 1 && parts[0] === '0' && settingsClone.leadingZero === 'deny') {\n // If the user enter `0`, then the caret is put on the right side of it (Fix issue #299)\n if (parts[1] === '' || parts[0] === '0' && parts[1] !== '') {\n position = 1;\n } else {\n position = 0;\n }\n }\n\n this.value = this.newValue;\n this._setCaretPosition(position, false);\n\n return true;\n }\n\n if (!minTest) {\n this.$that.trigger('autoNumeric:minExceeded');\n } else if (!maxTest) {\n this.$that.trigger('autoNumeric:maxExceeded');\n }\n\n return false;\n }\n\n /**\n * Helper function for `_expandSelectionOnSign()`.\n *\n * @returns {*} Sign position of a formatted value\n * @private\n */\n\n }, {\n key: '_getSignPosition',\n value: function _getSignPosition() {\n var settingsClone = this.settingsClone;\n var currencySymbol = settingsClone.currencySymbol;\n var that = this.that;\n\n if (currencySymbol) {\n var currencySymbolLen = currencySymbol.length;\n if (settingsClone.currencySymbolPlacement === 'p') {\n var hasNeg = settingsClone.negativeSignCharacter && that.value && that.value.charAt(0) === settingsClone.negativeSignCharacter;\n return hasNeg ? [1, currencySymbolLen + 1] : [0, currencySymbolLen];\n }\n var valueLen = that.value.length;\n return [valueLen - currencySymbolLen, valueLen];\n }\n\n return [1000, -1];\n }\n\n /**\n * Expands selection to cover whole sign\n * Prevents partial deletion/copying/overwriting of a sign\n *\n * @param {undefined|boolean} setReal\n * @private\n */\n\n }, {\n key: '_expandSelectionOnSign',\n value: function _expandSelectionOnSign(setReal) {\n //TODO Modify setReal to be more explicit (and a boolean only)\n //TODO Use array destructuring here to set signPosition to more explicit variables\n var signPosition = this._getSignPosition();\n var selection = this.selection;\n\n // If selection catches something except sign and catches only space from sign\n if (selection.start < signPosition[1] && selection.end > signPosition[0]) {\n // Then select without empty space\n if ((selection.start < signPosition[0] || selection.end > signPosition[1]) && this.value.substring(Math.max(selection.start, signPosition[0]), Math.min(selection.end, signPosition[1])).match(/^\\s*$/)) {\n if (selection.start < signPosition[0]) {\n this._setSelection(selection.start, signPosition[0], setReal);\n } else {\n this._setSelection(signPosition[1], selection.end, setReal);\n }\n } else {\n // Else select with whole sign\n this._setSelection(Math.min(selection.start, signPosition[0]), Math.max(selection.end, signPosition[1]), setReal);\n }\n }\n }\n\n /**\n * Try to strip pasted value to digits\n */\n\n }, {\n key: '_checkPaste',\n value: function _checkPaste() {\n if (!isUndefined(this.valuePartsBeforePaste)) {\n var oldParts = this.valuePartsBeforePaste;\n\n var _getLeftAndRightPartA3 = this._getLeftAndRightPartAroundTheSelection(),\n _getLeftAndRightPartA4 = _slicedToArray(_getLeftAndRightPartA3, 2),\n left = _getLeftAndRightPartA4[0],\n right = _getLeftAndRightPartA4[1];\n\n // Try to strip the pasted value first\n\n\n delete this.valuePartsBeforePaste;\n\n var modifiedLeftPart = left.substr(0, oldParts[0].length) + stripAllNonNumberCharacters(left.substr(oldParts[0].length), this.settingsClone, true);\n if (!this._setValueParts(modifiedLeftPart, right, true)) {\n this.value = oldParts.join('');\n this._setCaretPosition(oldParts[0].length, false);\n }\n }\n }\n\n /**\n * Process pasting, cursor moving and skipping of not interesting keys.\n * If this function returns TRUE, then further processing is not performed.\n *\n * @param {Event} e\n * @returns {boolean}\n * @private\n */\n\n }, {\n key: '_skipAlways',\n value: function _skipAlways(e) {\n // Catch the ctrl up on ctrl-v\n if ((e.ctrlKey || e.metaKey) && e.type === 'keyup' && !isUndefined(this.valuePartsBeforePaste) || e.shiftKey && this.eventKeyCode === keyCode.Insert) {\n //TODO Move this test inside the `onKeyup` handler\n this._checkPaste();\n return false;\n }\n\n // Skip all function keys (F1-F12), Windows keys, tab and other special keys\n if (this.eventKeyCode >= keyCode.F1 && this.eventKeyCode <= keyCode.F12 || this.eventKeyCode >= keyCode.Windows && this.eventKeyCode <= keyCode.RightClick || this.eventKeyCode >= keyCode.Tab && this.eventKeyCode < keyCode.Space ||\n // `e.which` is sometimes different than `this.eventKeyCode` during the keypress event when entering a printable character key (ie. 't'). Also, `e.which` equals 0 for non-printable characters.\n this.eventKeyCode < keyCode.Backspace && (e.which === 0 || e.which === this.eventKeyCode) || this.eventKeyCode === keyCode.NumLock || this.eventKeyCode === keyCode.ScrollLock || this.eventKeyCode === keyCode.Insert || this.eventKeyCode === keyCode.Command) {\n return true;\n }\n\n // If a \"Select all\" keyboard shortcut is detected (ctrl + a)\n if ((e.ctrlKey || e.metaKey) && this.eventKeyCode === keyCode.a) {\n if (this.settings.selectNumberOnly) {\n // `preventDefault()` is used here to prevent the browser to first select all the input text (including the currency sign), otherwise we would see that whole selection first in a flash, then the selection with only the number part without the currency sign.\n e.preventDefault();\n var valueLen = this.that.value.length;\n var currencySymbolLen = this.settings.currencySymbol.length;\n var negLen = !isNegative(this.that.value) ? 0 : 1;\n var suffixTextLen = this.settings.suffixText.length;\n var currencySymbolPlacement = this.settings.currencySymbolPlacement;\n var negativePositiveSignPlacement = this.settings.negativePositiveSignPlacement;\n\n var start = void 0;\n if (currencySymbolPlacement === 's') {\n start = 0;\n } else {\n start = negativePositiveSignPlacement === 'l' && negLen === 1 && currencySymbolLen > 0 ? currencySymbolLen + 1 : currencySymbolLen;\n }\n\n var end = void 0;\n if (currencySymbolPlacement === 'p') {\n end = valueLen - suffixTextLen;\n } else {\n switch (negativePositiveSignPlacement) {\n case 'l':\n end = valueLen - (suffixTextLen + currencySymbolLen);\n break;\n case 'r':\n end = currencySymbolLen > 0 ? valueLen - (currencySymbolLen + negLen + suffixTextLen) : valueLen - (currencySymbolLen + suffixTextLen);\n break;\n default:\n end = valueLen - (currencySymbolLen + suffixTextLen);\n }\n }\n\n setElementSelection(this.that, start, end);\n }\n\n return true;\n }\n\n // If a \"Copy\", \"Paste\" or \"Cut\" keyboard shortcut is detected (respectively 'ctrl + c', 'ctrl + v' or 'ctrl + x')\n if ((e.ctrlKey || e.metaKey) && (this.eventKeyCode === keyCode.c || this.eventKeyCode === keyCode.v || this.eventKeyCode === keyCode.x)) {\n if (e.type === 'keydown') {\n this._expandSelectionOnSign();\n }\n\n // Try to prevent wrong paste\n if (this.eventKeyCode === keyCode.v || this.eventKeyCode === keyCode.Insert) {\n if (e.type === 'keydown' || e.type === 'keypress') {\n if (isUndefined(this.valuePartsBeforePaste)) {\n this.valuePartsBeforePaste = this._getLeftAndRightPartAroundTheSelection();\n }\n } else {\n this._checkPaste();\n }\n }\n\n return e.type === 'keydown' || e.type === 'keypress' || this.eventKeyCode === keyCode.c;\n }\n\n if (e.ctrlKey || e.metaKey) {\n return true;\n }\n\n // Jump over thousand separator\n //TODO Move this test inside the `onKeydown` handler\n if (this.eventKeyCode === keyCode.LeftArrow || this.eventKeyCode === keyCode.RightArrow) {\n if (e.type === 'keydown' && !e.shiftKey) {\n if (this.eventKeyCode === keyCode.LeftArrow && (this.that.value.charAt(this.selection.start - 2) === this.settingsClone.digitGroupSeparator || this.that.value.charAt(this.selection.start - 2) === this.settingsClone.decimalCharacter)) {\n this._setCaretPosition(this.selection.start - 1);\n } else if (this.eventKeyCode === keyCode.RightArrow && (this.that.value.charAt(this.selection.start + 1) === this.settingsClone.digitGroupSeparator || this.that.value.charAt(this.selection.start + 1) === this.settingsClone.decimalCharacter)) {\n this._setCaretPosition(this.selection.start + 1);\n }\n }\n return true;\n }\n\n return this.eventKeyCode >= keyCode.PageDown && this.eventKeyCode <= keyCode.DownArrow;\n }\n\n /**\n * Process deletion of characters when the minus sign is to the right of the numeric characters.\n *\n * @param {string} left The part on the left of the caret or selection\n * @param {string} right The part on the right of the caret or selection\n * @returns {[string, string]}\n * @private\n */\n\n }, {\n key: '_processCharacterDeletionIfTrailingNegativeSign',\n value: function _processCharacterDeletionIfTrailingNegativeSign(_ref) {\n var _ref2 = _slicedToArray(_ref, 2),\n left = _ref2[0],\n right = _ref2[1];\n\n var settingsClone = this.settingsClone;\n if (settingsClone.currencySymbolPlacement === 'p' && settingsClone.negativePositiveSignPlacement === 's') {\n if (this.eventKeyCode === keyCode.Backspace) {\n settingsClone.caretFix = this.selection.start >= this.value.indexOf(settingsClone.suffixText) && settingsClone.suffixText !== '';\n if (this.value.charAt(this.selection.start - 1) === '-') {\n left = left.substring(1);\n } else if (this.selection.start <= this.value.length - settingsClone.suffixText.length) {\n left = left.substring(0, left.length - 1);\n }\n } else {\n settingsClone.caretFix = this.selection.start >= this.value.indexOf(settingsClone.suffixText) && settingsClone.suffixText !== '';\n if (this.selection.start >= this.value.indexOf(settingsClone.currencySymbol) + settingsClone.currencySymbol.length) {\n right = right.substring(1, right.length);\n }\n if (isNegative(left) && this.value.charAt(this.selection.start) === '-') {\n left = left.substring(1);\n }\n }\n }\n\n //TODO Merge the two following 'if' blocks into one `if (settingsClone.currencySymbolPlacement === 's') {` and a switch on settingsClone.negativePositiveSignPlacement\n if (settingsClone.currencySymbolPlacement === 's' && settingsClone.negativePositiveSignPlacement === 'l') {\n settingsClone.caretFix = this.selection.start >= this.value.indexOf(settingsClone.negativeSignCharacter) + settingsClone.negativeSignCharacter.length;\n if (this.eventKeyCode === keyCode.Backspace) {\n if (this.selection.start === this.value.indexOf(settingsClone.negativeSignCharacter) + settingsClone.negativeSignCharacter.length && contains(this.value, settingsClone.negativeSignCharacter)) {\n left = left.substring(1);\n } else if (left !== '-' && (this.selection.start <= this.value.indexOf(settingsClone.negativeSignCharacter) || !contains(this.value, settingsClone.negativeSignCharacter))) {\n left = left.substring(0, left.length - 1);\n }\n } else {\n if (left[0] === '-') {\n right = right.substring(1);\n }\n if (this.selection.start === this.value.indexOf(settingsClone.negativeSignCharacter) && contains(this.value, settingsClone.negativeSignCharacter)) {\n left = left.substring(1);\n }\n }\n }\n\n if (settingsClone.currencySymbolPlacement === 's' && settingsClone.negativePositiveSignPlacement === 'r') {\n settingsClone.caretFix = this.selection.start >= this.value.indexOf(settingsClone.negativeSignCharacter) + settingsClone.negativeSignCharacter.length;\n if (this.eventKeyCode === keyCode.Backspace) {\n if (this.selection.start === this.value.indexOf(settingsClone.negativeSignCharacter) + settingsClone.negativeSignCharacter.length) {\n left = left.substring(1);\n } else if (left !== '-' && this.selection.start <= this.value.indexOf(settingsClone.negativeSignCharacter) - settingsClone.currencySymbol.length) {\n left = left.substring(0, left.length - 1);\n } else if (left !== '' && !contains(this.value, settingsClone.negativeSignCharacter)) {\n left = left.substring(0, left.length - 1);\n }\n } else {\n settingsClone.caretFix = this.selection.start >= this.value.indexOf(settingsClone.currencySymbol) && settingsClone.currencySymbol !== '';\n if (this.selection.start === this.value.indexOf(settingsClone.negativeSignCharacter)) {\n left = left.substring(1);\n }\n right = right.substring(1);\n }\n }\n\n return [left, right];\n }\n\n /**\n * Process the deletion of characters.\n */\n\n }, {\n key: '_processCharacterDeletion',\n value: function _processCharacterDeletion() {\n var settingsClone = this.settingsClone;\n\n var left = void 0;\n var right = void 0;\n\n if (!this.selection.length) {\n var _getUnformattedLeftAn = this._getUnformattedLeftAndRightPartAroundTheSelection();\n\n var _getUnformattedLeftAn2 = _slicedToArray(_getUnformattedLeftAn, 2);\n\n left = _getUnformattedLeftAn2[0];\n right = _getUnformattedLeftAn2[1];\n\n if (left === '' && right === '') {\n settingsClone.throwInput = false;\n }\n\n if ((settingsClone.currencySymbolPlacement === 'p' && settingsClone.negativePositiveSignPlacement === 's' || settingsClone.currencySymbolPlacement === 's' && (settingsClone.negativePositiveSignPlacement === 'l' || settingsClone.negativePositiveSignPlacement === 'r')) && isNegative(this.value)) {\n var _processCharacterDele = this._processCharacterDeletionIfTrailingNegativeSign([left, right]); //TODO Change `this.value` to `this.that.value`?\n\n\n var _processCharacterDele2 = _slicedToArray(_processCharacterDele, 2);\n\n left = _processCharacterDele2[0];\n right = _processCharacterDele2[1];\n } else {\n if (this.eventKeyCode === keyCode.Backspace) {\n left = left.substring(0, left.length - 1);\n } else {\n right = right.substring(1, right.length);\n }\n }\n } else {\n this._expandSelectionOnSign(false);\n\n var _getUnformattedLeftAn3 = this._getUnformattedLeftAndRightPartAroundTheSelection();\n\n var _getUnformattedLeftAn4 = _slicedToArray(_getUnformattedLeftAn3, 2);\n\n left = _getUnformattedLeftAn4[0];\n right = _getUnformattedLeftAn4[1];\n }\n\n this._setValueParts(left, right);\n }\n\n /**\n * This function decides if the key pressed should be dropped or accepted, and modify the value 'on-the-fly' accordingly.\n * Returns TRUE if the keycode is allowed.\n * This functions also modify the value on-the-fly. //FIXME This should use another function in order to separate the test and the modification\n *\n * @param {Event} e\n * @returns {boolean}\n */\n\n }, {\n key: '_processCharacterInsertion',\n value: function _processCharacterInsertion(e) {\n var settingsClone = this.settingsClone;\n\n var _getUnformattedLeftAn5 = this._getUnformattedLeftAndRightPartAroundTheSelection(),\n _getUnformattedLeftAn6 = _slicedToArray(_getUnformattedLeftAn5, 2),\n left = _getUnformattedLeftAn6[0],\n right = _getUnformattedLeftAn6[1];\n\n settingsClone.throwInput = true;\n\n // Retrieve the real character that has been entered (ie. 'a' instead of the key code)\n var eventCharacter = character(e);\n\n // Start rules when the decimal character key is pressed always use numeric pad dot to insert decimal separator\n // Do not allow decimal character if no decimal part allowed\n if (eventCharacter === settingsClone.decimalCharacter || settingsClone.decimalCharacterAlternative && eventCharacter === settingsClone.decimalCharacterAlternative || (eventCharacter === '.' || eventCharacter === ',') && this.eventKeyCode === keyCode.DotNumpad) {\n if (!settingsClone.decimalPlacesOverride || !settingsClone.decimalCharacter) {\n return true;\n }\n\n // Do not allow decimal character before negativeSignCharacter character\n if (settingsClone.negativeSignCharacter && contains(right, settingsClone.negativeSignCharacter)) {\n return true;\n }\n\n // Do not allow decimal character if other decimal character present\n if (contains(left, settingsClone.decimalCharacter)) {\n return true;\n }\n\n if (right.indexOf(settingsClone.decimalCharacter) > 0) {\n return true;\n }\n\n if (right.indexOf(settingsClone.decimalCharacter) === 0) {\n right = right.substr(1);\n }\n\n this._setValueParts(left + settingsClone.decimalCharacter, right);\n\n return true;\n }\n\n // Prevent minus if not allowed\n if ((eventCharacter === '-' || eventCharacter === '+') && settingsClone.negativeSignCharacter === '-') {\n if (!settingsClone) {\n return true;\n }\n\n // Caret is always after minus\n if (settingsClone.currencySymbolPlacement === 'p' && settingsClone.negativePositiveSignPlacement === 's' || settingsClone.currencySymbolPlacement === 's' && settingsClone.negativePositiveSignPlacement !== 'p') {\n if (left === '' && contains(right, settingsClone.negativeSignCharacter)) {\n left = settingsClone.negativeSignCharacter;\n right = right.substring(1, right.length);\n }\n\n // Change number sign, remove part if should\n if (isNegativeStrict(left) || contains(left, settingsClone.negativeSignCharacter)) {\n left = left.substring(1, left.length);\n } else {\n left = eventCharacter === '-' ? settingsClone.negativeSignCharacter + left : left;\n }\n } else {\n if (left === '' && contains(right, settingsClone.negativeSignCharacter)) {\n left = settingsClone.negativeSignCharacter;\n right = right.substring(1, right.length);\n }\n\n // Change number sign, remove part if should\n if (left.charAt(0) === settingsClone.negativeSignCharacter) {\n left = left.substring(1, left.length);\n } else {\n left = eventCharacter === '-' ? settingsClone.negativeSignCharacter + left : left;\n }\n }\n\n this._setValueParts(left, right);\n\n return true;\n }\n\n // If the user tries to insert digit before minus sign\n var eventNumber = Number(eventCharacter);\n if (eventNumber >= 0 && eventNumber <= 9) {\n if (settingsClone.negativeSignCharacter && left === '' && contains(right, settingsClone.negativeSignCharacter)) {\n left = settingsClone.negativeSignCharacter;\n right = right.substring(1, right.length);\n }\n\n if (settingsClone.maximumValue <= 0 && settingsClone.minimumValue < settingsClone.maximumValue && !contains(this.value, settingsClone.negativeSignCharacter) && eventCharacter !== '0') {\n left = settingsClone.negativeSignCharacter + left;\n }\n\n this._setValueParts(left + eventCharacter, right);\n\n return true;\n }\n\n // Prevent any other character\n settingsClone.throwInput = false;\n\n return false;\n }\n\n /**\n * Formatting of just processed value while keeping the cursor position\n *\n * @param {Event} e\n * @private\n */\n\n }, {\n key: '_formatValue',\n value: function _formatValue(e) {\n var _this = this;\n\n var settingsClone = this.settingsClone;\n var leftLength = this.value;\n\n var _getUnformattedLeftAn7 = this._getUnformattedLeftAndRightPartAroundTheSelection(),\n _getUnformattedLeftAn8 = _slicedToArray(_getUnformattedLeftAn7, 1),\n left = _getUnformattedLeftAn8[0];\n\n // No grouping separator and no currency sign\n\n\n if ((settingsClone.digitGroupSeparator === '' || settingsClone.digitGroupSeparator !== '' && !contains(leftLength, settingsClone.digitGroupSeparator)) && (settingsClone.currencySymbol === '' || settingsClone.currencySymbol !== '' && !contains(leftLength, settingsClone.currencySymbol))) {\n var _leftLength$split = leftLength.split(settingsClone.decimalCharacter),\n _leftLength$split2 = _slicedToArray(_leftLength$split, 1),\n subParts = _leftLength$split2[0];\n\n var nSign = '';\n if (isNegative(subParts)) {\n nSign = '-';\n subParts = subParts.replace('-', '');\n left = left.replace('-', '');\n }\n\n // Strip leading zero on positive value if needed\n if (nSign === '' && subParts.length > settingsClone.mIntPos && left.charAt(0) === '0') {\n left = left.slice(1);\n }\n\n // Strip leading zero on negative value if needed\n if (nSign === '-' && subParts.length > settingsClone.mIntNeg && left.charAt(0) === '0') {\n left = left.slice(1);\n }\n\n left = nSign + left;\n }\n\n var value = addGroupSeparators(this.value, this.settingsClone);\n var position = value.length;\n if (value) {\n // Prepare regexp which searches for cursor position from unformatted left part\n var leftAr = left.split('');\n\n // Fixes caret position with trailing minus sign\n if ((settingsClone.negativePositiveSignPlacement === 's' || settingsClone.currencySymbolPlacement === 's' && settingsClone.negativePositiveSignPlacement !== 'p') && leftAr[0] === '-' && settingsClone.negativeSignCharacter !== '') {\n leftAr.shift();\n\n if ((this.eventKeyCode === keyCode.Backspace || this.eventKeyCode === keyCode.Delete) && settingsClone.caretFix) {\n if (settingsClone.currencySymbolPlacement === 's' && settingsClone.negativePositiveSignPlacement === 'l') {\n leftAr.push('-');\n settingsClone.caretFix = e.type === 'keydown';\n }\n\n if (settingsClone.currencySymbolPlacement === 'p' && settingsClone.negativePositiveSignPlacement === 's') {\n leftAr.push('-');\n settingsClone.caretFix = e.type === 'keydown';\n }\n\n if (settingsClone.currencySymbolPlacement === 's' && settingsClone.negativePositiveSignPlacement === 'r') {\n (function () {\n var signParts = settingsClone.currencySymbol.split('');\n var escapeChr = ['\\\\', '^', '$', '.', '|', '?', '*', '+', '(', ')', '['];\n var escapedParts = [];\n $.each(signParts, function (i, miniParts) {\n miniParts = signParts[i];\n if (isInArray(miniParts, escapeChr)) {\n escapedParts.push('\\\\' + miniParts);\n } else {\n escapedParts.push(miniParts);\n }\n });\n\n if (_this.eventKeyCode === keyCode.Backspace) {\n escapedParts.push('-');\n }\n\n // Pushing the escaped sign\n leftAr.push(escapedParts.join(''));\n settingsClone.caretFix = e.type === 'keydown';\n })();\n }\n }\n }\n\n for (var i = 0; i < leftAr.length; i++) {\n if (!leftAr[i].match('\\\\d')) {\n leftAr[i] = '\\\\' + leftAr[i];\n }\n }\n\n var leftReg = new RegExp('^.*?' + leftAr.join('.*?'));\n\n // Search cursor position in formatted value\n var newLeft = value.match(leftReg);\n if (newLeft) {\n position = newLeft[0].length;\n\n // If the positive sign is shown, calculate the caret position accordingly\n if (settingsClone.showPositiveSign) {\n if (position === 0 && newLeft.input.charAt(0) === settingsClone.positiveSignCharacter) {\n position = newLeft.input.indexOf(settingsClone.currencySymbol) === 1 ? settingsClone.currencySymbol.length + 1 : 1;\n }\n\n if (position === 0 && newLeft.input.charAt(settingsClone.currencySymbol.length) === settingsClone.positiveSignCharacter) {\n position = settingsClone.currencySymbol.length + 1;\n }\n }\n\n // If we are just before the sign which is in prefix position\n if ((position === 0 && value.charAt(0) !== settingsClone.negativeSignCharacter || position === 1 && value.charAt(0) === settingsClone.negativeSignCharacter) && settingsClone.currencySymbol && settingsClone.currencySymbolPlacement === 'p') {\n // Place caret after prefix sign\n //TODO Should the test be 'isNegative' instead of 'isNegativeStrict' in order to search for '-' everywhere in the string?\n position = this.settingsClone.currencySymbol.length + (isNegativeStrict(value) ? 1 : 0);\n }\n } else {\n if (settingsClone.currencySymbol && settingsClone.currencySymbolPlacement === 's') {\n // If we could not find a place for cursor and have a sign as a suffix\n // Place caret before suffix currency sign\n position -= settingsClone.currencySymbol.length;\n }\n\n if (settingsClone.suffixText) {\n // If we could not find a place for cursor and have a suffix\n // Place caret before suffix\n position -= settingsClone.suffixText.length;\n }\n }\n }\n\n // Only update the value if it has changed. This prevents modifying the selection, if any.\n if (value !== this.that.value || value === this.that.value && (this.eventKeyCode === keyCode.num0 || this.eventKeyCode === keyCode.numpad0)) {\n this.that.value = value;\n this._setCaretPosition(position);\n }\n\n this.formatted = true; //TODO Rename `this.formatted` to `this._formatExecuted`, since it's possible this function does not need to format anything (in the case where the keycode is dropped for instance)\n }\n }]);\n\n return AutoNumericHolder;\n }();\n\n /**\n * This function factorise the `getString()` and `getArray()` functions since they share quite a lot of code.\n *\n * The \"getString\" method uses jQuery's .serialize() method that creates a text string in standard URL-encoded notation.\n * The \"getArray\" method on the other hand uses jQuery's .serializeArray() method that creates array or objects that can be encoded as a JSON string.\n *\n * It then loops through the string and un-formats the inputs with autoNumeric.\n * By defaults values returned as ISO numeric string \"1234.56\" or \"-1234.56\" where the decimal character is a period\n * Locale formats are supported \"1234.56-\" or \"1234,56\" or \"-1234,56 or \"1234,56-\", or even plain numbers => please see option \"outputFormat\" for more details\n *\n * @param {boolean} getArrayBehavior - If set to TRUE, then this function behave like `getArray()`, otherwise if set to FALSE, it behave like `getString()`\n * @param {HTMLElement} that - A reference to the current DOM element\n * @returns {*}\n * @private\n */\n\n\n function _getStringOrArray() {\n var getArrayBehavior = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;\n var that = arguments[1];\n\n var $this = getCurrentElement(that);\n var formIndex = $('form').index($this);\n var allFormElements = $('form:eq(' + formIndex + ')')[0];\n var aiIndex = [];\n\n // all input index\n var scIndex = [];\n\n // successful control index\n var rSubmitterTypes = /^(?:submit|button|image|reset|file)$/i;\n\n // from jQuery serialize method\n var rSubmittable = /^(?:input|select|textarea|keygen)/i;\n\n // from jQuery serialize method\n var rCheckableType = /^(?:checkbox|radio)$/i;\n var rNonAutoNumericTypes = /^(?:button|checkbox|color|date|datetime|datetime-local|email|file|image|month|number|password|radio|range|reset|search|submit|time|url|week)/i;\n\n var count = 0;\n\n // index of successful elements\n $.each(allFormElements, function (i, field) {\n if (field.name !== '' && rSubmittable.test(field.localName) && !rSubmitterTypes.test(field.type) && !field.disabled && (field.checked || !rCheckableType.test(field.type))) {\n scIndex.push(count);\n count++;\n } else {\n scIndex.push(-1);\n }\n });\n\n // index of all inputs tags except checkbox\n count = 0;\n $.each(allFormElements, function (i, field) {\n if (field.localName === 'input' && (field.type === '' || field.type === 'text' || field.type === 'hidden' || field.type === 'tel')) {\n aiIndex.push(count);\n count++;\n } else {\n aiIndex.push(-1);\n if (field.localName === 'input' && rNonAutoNumericTypes.test(field.type)) {\n count++;\n }\n }\n });\n\n if (getArrayBehavior) {\n var formFields = $this.serializeArray();\n\n $.each(formFields, function (i, field) {\n var scElement = scIndex.indexOf(i);\n\n if (scElement > -1 && aiIndex[scElement] > -1) {\n var testInput = $('form:eq(' + formIndex + ') input:eq(' + aiIndex[scElement] + ')');\n var settings = testInput.data('autoNumeric');\n\n if ((typeof settings === 'undefined' ? 'undefined' : _typeof(settings)) === 'object') {\n field.value = testInput.autoNumeric('getLocalized').toString();\n }\n }\n });\n\n return formFields;\n } else {\n var _ret2 = function () {\n // getString() behavior\n var formFields = $this.serialize();\n var formParts = formFields.split('&');\n\n $.each(formParts, function (i) {\n var _formParts$i$split = formParts[i].split('='),\n _formParts$i$split2 = _slicedToArray(_formParts$i$split, 2),\n inputName = _formParts$i$split2[0],\n inputValue = _formParts$i$split2[1];\n\n var scElement = scIndex.indexOf(i);\n\n // If the current element is a valid element\n if (scElement > -1 && aiIndex[scElement] > -1) {\n var testInput = $('form:eq(' + formIndex + ') input:eq(' + aiIndex[scElement] + ')');\n var settings = testInput.data('autoNumeric');\n\n if ((typeof settings === 'undefined' ? 'undefined' : _typeof(settings)) === 'object') {\n if (inputValue !== null) {\n var modifiedInputValue = testInput.autoNumeric('getLocalized').toString();\n formParts[i] = inputName + '=' + modifiedInputValue;\n }\n }\n }\n });\n\n return {\n v: formParts.join('&')\n };\n }();\n\n if ((typeof _ret2 === 'undefined' ? 'undefined' : _typeof(_ret2)) === \"object\") return _ret2.v;\n }\n }\n\n /**\n * Handler for 'focusin' events\n *\n * @param {object} $this jQuery-selected DOM element\n * @param {AutoNumericHolder} holder\n * @param {Event} e\n */\n function onFocusInAndMouseEnter($this, holder, e) {\n var settings = holder.settingsClone;\n\n if (e.type === 'focusin' || e.type === 'mouseenter' && !$this.is(':focus') && settings.emptyInputBehavior === 'focus') {\n settings.hasFocus = true;\n\n if (settings.negativeBracketsTypeOnBlur !== null && settings.negativeSignCharacter !== '') {\n $this.val(toggleNegativeBracket(e.target.value, settings));\n }\n\n // clean the value to compare to rawValue\n var result = stripAllNonNumberCharacters(e.target.value, settings, true);\n result = convertToNumericString(result, settings);\n result = cleanLeadingTrailingZeros(result, settings);\n if (settings.trailingNegative) {\n result = '-' + result;\n }\n\n var roundedValue = void 0;\n if (settings.decimalPlacesShownOnFocus) {\n settings.decimalPlacesOverride = settings.decimalPlacesShownOnFocus;\n roundedValue = roundValue(settings.rawValue, settings);\n $this.val(addGroupSeparators(roundedValue, settings));\n } else if (settings.scaleDivisor) {\n settings.decimalPlacesOverride = Number(settings.oDec);\n roundedValue = roundValue(settings.rawValue, settings);\n $this.val(addGroupSeparators(roundedValue, settings));\n } else if (settings.noSeparatorOnFocus) {\n settings.digitGroupSeparator = '';\n settings.currencySymbol = '';\n settings.suffixText = '';\n roundedValue = roundValue(settings.rawValue, settings);\n $this.val(addGroupSeparators(roundedValue, settings));\n } else if (result !== settings.rawValue) {\n // updates the rawValue\n $this.autoNumeric('set', result);\n }\n\n // In order to send a 'native' change event when blurring the input, we need to first store the initial input value on focus.\n holder.valueOnFocus = e.target.value;\n holder.lastVal = holder.valueOnFocus;\n var onEmpty = checkEmpty(holder.valueOnFocus, settings, true);\n if (onEmpty !== null && onEmpty !== '' && settings.emptyInputBehavior === 'focus') {\n $this.val(onEmpty);\n if (onEmpty === settings.currencySymbol && settings.currencySymbolPlacement === 's') {\n setElementSelection(e.target, 0, 0);\n }\n }\n }\n }\n\n /**\n * Handler for 'keydown' events.\n * The user just started pushing any key, hence one event is sent.\n *\n * Note :\n * By default a 'normal' input output those events in the right order when inputting a character key (ie. 'a') :\n * - keydown\n * - keypress\n * - input\n * - keyup\n *\n * ...when inputting a modifier key (ie. 'ctrl') :\n * - keydown\n * - keyup\n *\n * If 'delete' or 'backspace' is entered, the following events are sent :\n * - keydown\n * - input\n * - keyup\n *\n * If 'enter' is entered and the value has not changed, the following events are sent :\n * - keydown\n * - keypress\n * - keyup\n *\n * If 'enter' is entered and the value has been changed, the following events are sent :\n * - keydown\n * - keypress\n * - change\n * - keyup\n *\n * When a paste is done, the following events are sent :\n * - input (if paste is done with the mouse)\n *\n * - keydown (if paste is done with ctrl+v)\n * - keydown\n * - input\n * - keyup\n * - keyup\n *\n * @param {AutoNumericHolder} holder\n * @param {Event} e\n */\n function onKeydown(holder, e) {\n //TODO Create a function that retrieve the element value (either by using `e.target.value` when the element is an <input>, or by using `element.textContent` when the element as its `contenteditable` set to true)\n holder._updateAutoNumericHolderEventKeycode(e);\n holder.initialValueOnKeydown = e.target.value; // This is needed in `onKeyup()` to check if the value as changed during the key press\n\n if (holder.that.readOnly) {\n holder.processed = true;\n\n return;\n }\n\n // The \"enter\" key throws a `change` event if the value has changed since the `focus` event\n if (holder.eventKeyCode === keyCode.Enter && holder.valueOnFocus !== e.target.value) {\n triggerEvent('change', e.target);\n holder.valueOnFocus = e.target.value;\n }\n\n holder._updateAutoNumericHolderProperties(e);\n\n if (holder._skipAlways(e)) {\n holder.processed = true;\n\n return;\n }\n\n // Check if the key is a delete/backspace key\n if (holder.eventKeyCode === keyCode.Backspace || holder.eventKeyCode === keyCode.Delete) {\n holder._processCharacterDeletion(); // Because backspace and delete only triggers keydown and keyup events, not keypress\n holder.processed = true;\n holder._formatValue(e);\n\n // If and only if the resulting value has changed after that backspace/delete, then we have to send an 'input' event like browsers normally do.\n if (e.target.value !== holder.lastVal && holder.settingsClone.throwInput) {\n // Throw an input event when a character deletion is detected\n triggerEvent('input', e.target);\n e.preventDefault(); // ...and immediately prevent the browser to delete a second character\n }\n\n holder.lastVal = e.target.value;\n holder.settingsClone.throwInput = true;\n\n return;\n }\n\n holder.formatted = false; //TODO Is this line needed?\n }\n\n /**\n * Handler for 'keypress' events.\n * The user is still pressing the key, which will output a character (ie. '2') continuously until it releases the key.\n * Note: 'keypress' events are not sent for delete keys like Backspace/Delete.\n *\n * @param {AutoNumericHolder} holder\n * @param {Event} e\n */\n function onKeypress(holder, e) {\n // Retrieve the real character that has been entered (ie. 'a' instead of the key code)\n var eventCharacter = character(e);\n\n // Firefox generate a 'keypress' event (e.keyCode === 0) for the keys that do not print a character (ie. 'Insert', 'Delete', 'Fn' keys, 'PageUp', 'PageDown' etc.). 'Shift' on the other hand does not generate a keypress event.\n if (eventCharacter === keyName.Insert) {\n return;\n }\n\n var processed = holder.processed;\n holder._updateAutoNumericHolderProperties(e);\n\n if (holder._skipAlways(e)) {\n return;\n }\n\n if (processed) {\n e.preventDefault();\n\n return;\n }\n\n var isCharacterInsertionAllowed = holder._processCharacterInsertion(e);\n if (isCharacterInsertionAllowed) {\n holder._formatValue(e);\n if (e.target.value !== holder.lastVal && holder.settingsClone.throwInput) {\n // Throws input event on adding a character\n triggerEvent('input', e.target);\n e.preventDefault(); // ...and immediately prevent the browser to add a second character\n } else {\n if ((eventCharacter === holder.settings.decimalCharacter || eventCharacter === holder.settings.decimalCharacterAlternative) && getElementSelection(e.target).start === getElementSelection(e.target).end && getElementSelection(e.target).start === e.target.value.indexOf(holder.settings.decimalCharacter)) {\n var position = getElementSelection(e.target).start + 1;\n setElementSelection(e.target, position, position);\n }\n e.preventDefault();\n }\n\n holder.lastVal = e.target.value;\n holder.settingsClone.throwInput = true;\n\n return;\n }\n\n e.preventDefault();\n\n holder.formatted = false;\n }\n\n /**\n * Handler for 'keyup' events.\n * The user just released any key, hence one event is sent.\n *\n * @param {AutoNumericHolder} holder\n * @param {object} settings\n * @param {Event} e\n */\n function onKeyup(holder, settings, e) {\n holder._updateAutoNumericHolderProperties(e);\n\n var skip = holder._skipAlways(e);\n delete holder.valuePartsBeforePaste;\n if (skip || e.target.value === '') {\n return;\n }\n\n // Added to properly place the caret when only the currency sign is present\n if (e.target.value === holder.settingsClone.currencySymbol) {\n if (holder.settingsClone.currencySymbolPlacement === 's') {\n setElementSelection(e.target, 0, 0);\n } else {\n setElementSelection(e.target, holder.settingsClone.currencySymbol.length, holder.settingsClone.currencySymbol.length);\n }\n } else if (holder.eventKeyCode === keyCode.Tab) {\n setElementSelection(e.target, 0, e.target.value.length);\n }\n\n if (e.target.value === holder.settingsClone.suffixText || holder.settingsClone.rawValue === '' && holder.settingsClone.currencySymbol !== '' && holder.settingsClone.suffixText !== '') {\n setElementSelection(e.target, 0, 0);\n }\n\n // Saves the extended decimal to preserve the data when navigating away from the page\n if (holder.settingsClone.decimalPlacesShownOnFocus !== null && holder.settingsClone.saveValueToSessionStorage) {\n saveValueToPersistentStorage(e.target, settings, 'set');\n }\n\n if (!holder.formatted) {\n holder._formatValue(e);\n }\n\n // If the input value has changed during the key press event chain, an event is sent to alert that a formatting has been done (cf. Issue #187)\n if (e.target.value !== holder.initialValueOnKeydown) {\n triggerEvent('autoNumeric:formatted', e.target);\n }\n }\n\n /**\n * Handler for 'focusout' events\n *\n * @param {object} $this jQuery-selected DOM element\n * @param {AutoNumericHolder} holder\n * @param {Event} e\n */\n function onFocusOutAndMouseLeave($this, holder, e) {\n if (!$this.is(':focus')) {\n var value = e.target.value;\n var origValue = value;\n var settings = holder.settingsClone;\n settings.hasFocus = false;\n\n if (settings.saveValueToSessionStorage) {\n saveValueToPersistentStorage(e.target, settings, 'set');\n }\n\n if (settings.noSeparatorOnFocus === true) {\n settings.digitGroupSeparator = settings.oSep;\n settings.currencySymbol = settings.oSign;\n settings.suffixText = settings.oSuffix;\n }\n\n if (settings.decimalPlacesShownOnFocus !== null) {\n settings.decimalPlacesOverride = settings.oDec;\n settings.allowDecimalPadding = settings.oPad;\n settings.negativeBracketsTypeOnBlur = settings.oBracket;\n }\n\n value = stripAllNonNumberCharacters(value, settings, true);\n\n if (value !== '') {\n if (settings.trailingNegative && !isNegative(value)) {\n value = '-' + value;\n settings.trailingNegative = false;\n }\n\n var _checkIfInRangeWithOv3 = checkIfInRangeWithOverrideOption(value, settings),\n _checkIfInRangeWithOv4 = _slicedToArray(_checkIfInRangeWithOv3, 2),\n minTest = _checkIfInRangeWithOv4[0],\n maxTest = _checkIfInRangeWithOv4[1];\n\n if (checkEmpty(value, settings, false) === null && minTest && maxTest) {\n value = modifyNegativeSignAndDecimalCharacterForRawValue(value, settings);\n settings.rawValue = cleanLeadingTrailingZeros(value, settings);\n\n if (settings.scaleDivisor) {\n value = value / settings.scaleDivisor;\n value = value.toString();\n }\n\n settings.decimalPlacesOverride = settings.scaleDivisor && settings.scaleDecimalPlaces ? Number(settings.scaleDecimalPlaces) : settings.decimalPlacesOverride;\n value = roundValue(value, settings);\n value = modifyNegativeSignAndDecimalCharacterForFormattedValue(value, settings);\n } else {\n if (!minTest) {\n $this.trigger('autoNumeric:minExceeded');\n }\n if (!maxTest) {\n $this.trigger('autoNumeric:maxExceeded');\n }\n\n value = settings.rawValue;\n }\n } else {\n if (settings.emptyInputBehavior === 'zero') {\n settings.rawValue = '0';\n value = roundValue('0', settings);\n } else {\n settings.rawValue = '';\n }\n }\n\n var groupedValue = checkEmpty(value, settings, false);\n if (groupedValue === null) {\n groupedValue = addGroupSeparators(value, settings);\n }\n\n if (groupedValue !== origValue) {\n groupedValue = settings.scaleSymbol ? groupedValue + settings.scaleSymbol : groupedValue;\n $this.val(groupedValue);\n }\n\n if (groupedValue !== holder.valueOnFocus) {\n $this.change();\n delete holder.valueOnFocus;\n }\n }\n }\n\n /**\n * Handler for 'paste' events\n *\n * @param {object} $this jQuery-selected DOM element\n * @param {AutoNumericHolder} holder\n * @param {Event} e\n */\n function onPaste($this, holder, e) {\n //TODO Using ctrl+z after a paste should cancel it -> How would that affect other frameworks/component built with that feature in mind though?\n //FIXME When pasting '000' on a thousand group selection, the whole selection gets deleted, and only one '0' is pasted (cf. issue #302)\n // The event is prevented by default, since otherwise the user would be able to paste invalid characters into the input\n e.preventDefault();\n\n var rawPastedText = e.clipboardData.getData('text/plain');\n\n // 0. Special case if the user has selected all the input text before pasting\n var initialFormattedValue = e.target.value;\n var selectionStart = e.target.selectionStart || 0;\n var selectionEnd = e.target.selectionEnd || 0;\n var selectionSize = selectionEnd - selectionStart;\n var isAllInputTextSelected = false;\n\n if (selectionSize === initialFormattedValue.length) {\n isAllInputTextSelected = true;\n }\n\n // 1. Check if the paste has a negative sign (only if it's the first character), and store that information for later use\n var isPasteNegative = isNegativeStrict(rawPastedText);\n if (isPasteNegative) {\n // 1a. Remove the negative sign from the pasted text\n rawPastedText = rawPastedText.slice(1, rawPastedText.length);\n }\n\n // 2. Strip all thousand separators, brackets and currency sign, and convert the decimal character to a dot\n var untranslatedPastedText = preparePastedText(rawPastedText, holder);\n\n var pastedText = void 0;\n if (untranslatedPastedText === '.') {\n // Special case : If the user tries to paste a single decimal character (that has been translated to '.' already)\n pastedText = '.';\n } else {\n // Normal case\n // Allow pasting arabic numbers\n pastedText = arabicToLatinNumbers(untranslatedPastedText, false, false, false);\n }\n\n // 3. Test if the paste is valid (only has numbers and eventually a decimal character). If it's not valid, stop here.\n if (pastedText !== '.' && (!isNumber(pastedText) || pastedText === '')) {\n if (holder.settings.onInvalidPaste === 'error') {\n //TODO Should we send a warning instead of throwing an error?\n throwError('The pasted value \\'' + rawPastedText + '\\' is not a valid paste content.');\n }\n\n return;\n }\n\n // 4. Calculate the paste result\n var caretPositionOnInitialTextAfterPasting = void 0;\n var initialUnformattedNumber = void 0;\n if (e.target.value === '') {\n // autoNumeric 'get' returns '0.00' if the input is empty, hence we need to store the 'real' empty initial value when needed\n //FIXME This has been fixed in a previous commit, get should return '' on an empty input. Remove this unneeded 'if'\n initialUnformattedNumber = '';\n } else {\n initialUnformattedNumber = $this.autoNumeric('get');\n }\n var isInitialValueNegative = isNegativeStrict(initialUnformattedNumber);\n var isPasteNegativeAndInitialValueIsPositive = void 0;\n var result = void 0;\n\n // If the pasted content is negative, then the result will be negative too\n if (isPasteNegative && !isInitialValueNegative) {\n initialUnformattedNumber = '-' + initialUnformattedNumber;\n isInitialValueNegative = true;\n isPasteNegativeAndInitialValueIsPositive = true;\n } else {\n isPasteNegativeAndInitialValueIsPositive = false;\n }\n\n var leftPartContainedADot = false;\n switch (holder.settings.onInvalidPaste) {\n /* 4a. Truncate paste behavior:\n * Insert as many numbers as possible on the right hand side of the caret from the pasted text content, until the input reach its range limit.\n * If there is more characters in the clipboard once a limit is reached, drop the extraneous characters.\n * Otherwise paste all the numbers in the clipboard.\n * While doing so, we check if the result is within the minimum and maximum values allowed, and stop as soon as we encounter one of those.\n *\n * 4b. Replace paste behavior:\n * Idem than the 'truncate' paste behavior, except that when a range limit is hit, we try to replace the subsequent initial numbers with the pasted ones, until we hit the range limit a second (and last) time, or we run out of numbers to paste\n */\n /* eslint no-case-declarations: 0 */\n case 'truncate':\n case 'replace':\n var leftFormattedPart = initialFormattedValue.slice(0, selectionStart);\n var rightFormattedPart = initialFormattedValue.slice(selectionEnd, initialFormattedValue.length);\n\n if (selectionStart !== selectionEnd) {\n // a. If there is a selection, remove the selected part, and return the left and right part\n result = preparePastedText(leftFormattedPart + rightFormattedPart, holder);\n } else {\n // b. Else if this is only one caret (and therefore no selection), then return the left and right part\n result = preparePastedText(initialFormattedValue, holder);\n }\n\n // Add back the negative sign if needed\n if (isInitialValueNegative) {\n result = setRawNegativeSign(result);\n }\n\n // Build the unformatted result string\n caretPositionOnInitialTextAfterPasting = convertCharacterCountToIndexPosition(countNumberCharactersOnTheCaretLeftSide(initialFormattedValue, selectionStart, holder.settings.decimalCharacter));\n if (isPasteNegativeAndInitialValueIsPositive) {\n // If the initial paste is negative and the initial value is not, then I must offset the caret position by one place to the right to take the additional hyphen into account\n caretPositionOnInitialTextAfterPasting++;\n //TODO Quid if the negative sign is not on the left (negativePositiveSignPlacement and currencySymbolPlacement)?\n }\n\n var leftPart = result.slice(0, caretPositionOnInitialTextAfterPasting);\n var rightPart = result.slice(caretPositionOnInitialTextAfterPasting, result.length);\n if (pastedText === '.') {\n if (contains(leftPart, '.')) {\n // If I remove a dot here, then I need to update the caret position (decrement it by 1) when positioning it\n // To do so, we keep that info in order to modify the caret position later\n leftPartContainedADot = true;\n leftPart = leftPart.replace('.', '');\n }\n rightPart = rightPart.replace('.', '');\n }\n // -- Here, we are good to go to continue on the same basis\n\n // c. Add numbers one by one at the caret position, while testing if the result is valid and within the range of the minimum and maximum value\n // Continue until you either run out of numbers to paste, or that you get out of the range limits\n var minParse = parseStr(holder.settings.minimumValue);\n var maxParse = parseStr(holder.settings.maximumValue);\n var lastGoodKnownResult = result; // This is set as the default, in case we do not add even one number\n var pastedTextIndex = 0;\n var modifiedLeftPart = leftPart;\n\n while (pastedTextIndex < pastedText.length) {\n // Modify the result with another pasted character\n modifiedLeftPart += pastedText[pastedTextIndex];\n result = modifiedLeftPart + rightPart;\n\n // Check the range limits\n if (!checkIfInRange(result, minParse, maxParse)) {\n // The result is out of the range limits, stop the loop here\n break;\n }\n\n // Save the last good known result\n lastGoodKnownResult = result;\n\n // Update the local variables for the next loop\n pastedTextIndex++;\n }\n\n // Update the last caret position where to insert a new number\n caretPositionOnInitialTextAfterPasting += pastedTextIndex;\n\n //XXX Here we have the result for the `truncate` option\n if (holder.settings.onInvalidPaste === 'truncate') {\n //TODO If the user as defined a truncate callback and there are still some numbers (that will be dropped), then call this callback with the initial paste as well as the remaining numbers\n result = lastGoodKnownResult;\n\n if (leftPartContainedADot) {\n // If a dot has been removed for the part on the left of the caret, we decrement the caret index position\n caretPositionOnInitialTextAfterPasting--;\n }\n break;\n }\n //XXX ...else we need to continue modifying the result for the 'replace' option\n\n // d. Until there are numbers to paste, replace the initial numbers one by one, and still do the range test.\n // Stop when you have no more numbers to paste, or if you are out of the range limits.\n // If you do get to the range limits, use the previous known good value within those limits.\n // Note: The numbers are replaced one by one, in the integer then decimal part, while ignoring the decimal character\n //TODO What should happen if the user try to paste a decimal number? Should we override the current initial decimal character in favor of this new one? If we do, then we have to recalculate the vMin/vMax from the start in order to take into account this new decimal character position..\n var lastGoodKnownResultIndex = caretPositionOnInitialTextAfterPasting;\n var lastGoodKnownResultSize = lastGoodKnownResult.length;\n\n while (pastedTextIndex < pastedText.length && lastGoodKnownResultIndex < lastGoodKnownResultSize) {\n if (lastGoodKnownResult[lastGoodKnownResultIndex] === '.') {\n // We skip the decimal character 'replacement'. That way, we do not change the decimal character position regarding the remaining numbers.\n lastGoodKnownResultIndex++;\n continue;\n }\n\n // This replace one character at a time\n result = replaceCharAt(lastGoodKnownResult, lastGoodKnownResultIndex, pastedText[pastedTextIndex]);\n\n // Check the range limits\n if (!checkIfInRange(result, minParse, maxParse)) {\n // The result is out of the range limits, stop the loop here\n break;\n }\n\n // Save the last good known result\n lastGoodKnownResult = result;\n\n // Update the local variables for the next loop\n pastedTextIndex++;\n lastGoodKnownResultIndex++;\n }\n\n // Update the last caret position where to insert a new number\n caretPositionOnInitialTextAfterPasting = lastGoodKnownResultIndex;\n\n if (leftPartContainedADot) {\n // If a dot has been removed for the part on the left of the caret, we decrement the caret index position\n caretPositionOnInitialTextAfterPasting--;\n }\n\n result = lastGoodKnownResult;\n\n break;\n /* 4c. Normal paste behavior:\n * Insert the pasted number inside the current unformatted text, at the right caret position or selection\n */\n case 'error':\n case 'ignore':\n case 'clamp':\n default:\n // 1. Generate the unformatted result\n var leftFormattedPart2 = initialFormattedValue.slice(0, selectionStart);\n var rightFormattedPart2 = initialFormattedValue.slice(selectionEnd, initialFormattedValue.length);\n\n if (selectionStart !== selectionEnd) {\n // a. If there is a selection, remove the selected part, and return the left and right part\n result = preparePastedText(leftFormattedPart2 + rightFormattedPart2, holder);\n } else {\n // b. Else if this is only one caret (and therefore no selection), then return the left and right part\n result = preparePastedText(initialFormattedValue, holder);\n }\n\n // Add back the negative sign if needed\n if (isInitialValueNegative) {\n result = setRawNegativeSign(result);\n }\n\n // Build the unformatted result string\n caretPositionOnInitialTextAfterPasting = convertCharacterCountToIndexPosition(countNumberCharactersOnTheCaretLeftSide(initialFormattedValue, selectionStart, holder.settings.decimalCharacter));\n if (isPasteNegativeAndInitialValueIsPositive) {\n // If the initial paste is negative and the initial value is not, then I must offset the caret position by one place to the right to take the additional hyphen into account\n caretPositionOnInitialTextAfterPasting++;\n //TODO Quid if the negative sign is not on the left (negativePositiveSignPlacement and currencySymbolPlacement)?\n }\n\n leftPart = result.slice(0, caretPositionOnInitialTextAfterPasting);\n rightPart = result.slice(caretPositionOnInitialTextAfterPasting, result.length);\n if (pastedText === '.') {\n // If the user only paste a single decimal character, then we remove the previously existing one (if any)\n if (contains(leftPart, '.')) {\n // If I remove a dot here, then I need to update the caret position (decrement it by 1) when positioning it\n // To do so, we keep that info in order to modify the caret position later\n leftPartContainedADot = true;\n leftPart = leftPart.replace('.', '');\n }\n rightPart = rightPart.replace('.', '');\n }\n // -- Here, we are good to go to continue on the same basis\n\n // Generate the unformatted result\n result = '' + leftPart + pastedText + rightPart;\n\n // 2. Calculate the caret position in the unformatted value, for later use\n if (selectionStart === selectionEnd) {\n // There is no selection, then the caret position is set after the pasted text\n var indexWherePastedTextHasBeenInserted = convertCharacterCountToIndexPosition(countNumberCharactersOnTheCaretLeftSide(initialFormattedValue, selectionStart, holder.settings.decimalCharacter));\n caretPositionOnInitialTextAfterPasting = indexWherePastedTextHasBeenInserted + pastedText.length; // I must not count the characters that have been removed from the pasted text (ie. '.')\n } else {\n if (isAllInputTextSelected) {\n // Special case when all the input text is selected before pasting, which means we'll completely erase its content and paste only the clipboard content\n caretPositionOnInitialTextAfterPasting = result.length;\n } else if (rightPart === '') {\n // If the user selected from the caret position to the end of the input (on the far right)\n caretPositionOnInitialTextAfterPasting = convertCharacterCountToIndexPosition(countNumberCharactersOnTheCaretLeftSide(initialFormattedValue, selectionStart, holder.settings.decimalCharacter)) + pastedText.length;\n } else {\n // Normal case\n var indexSelectionEndInRawValue = convertCharacterCountToIndexPosition(countNumberCharactersOnTheCaretLeftSide(initialFormattedValue, selectionEnd, holder.settings.decimalCharacter));\n\n // Here I must not count the characters that have been removed from the pasted text (ie. '.'), or the thousand separators in the initial selected text\n var selectedText = e.target.value.slice(selectionStart, selectionEnd);\n caretPositionOnInitialTextAfterPasting = indexSelectionEndInRawValue - selectionSize + countCharInText(holder.settings.digitGroupSeparator, selectedText) + pastedText.length;\n }\n }\n\n // Modify the caret position for special cases, only if the whole input has not been selected\n if (!isAllInputTextSelected) {\n if (isPasteNegativeAndInitialValueIsPositive) {\n // If the pasted value has a '-' sign, but the initial value does not, offset the index by one\n caretPositionOnInitialTextAfterPasting++;\n }\n\n if (leftPartContainedADot) {\n // If a dot has been removed for the part on the left of the caret, we decrement the caret index position\n caretPositionOnInitialTextAfterPasting--;\n }\n }\n }\n\n // 5. Check if the result is a valid number, if not, drop the paste and do nothing.\n if (!isNumber(result) || result === '') {\n if (holder.settings.onInvalidPaste === 'error') {\n throwError('The pasted value \\'' + rawPastedText + '\\' would result into an invalid content \\'' + result + '\\'.'); //TODO Should we send a warning instead of throwing an error?\n //TODO This is not DRY ; refactor with above\n }\n return;\n }\n\n // 6. If it's a valid number, check if it falls inside the minimum and maximum value. If this fails, modify the value following this procedure :\n /*\n * If 'error' (this is the default) :\n * - Normal paste behavior.\n * - Try to set the new value, if it fails, then throw an error in the console.\n * - Do not change the input value, do not change the current selection.\n * If 'ignore' :\n * - Normal paste behavior.\n * - Try to set the new value, if it fails, do nothing more.\n * - Do not change the input value, do not change the current selection.\n * If 'clamp' :\n * - Normal paste behavior.\n * - Try to set the new value, if it fails, set the value to the minimum or maximum limit, whichever is closest to the\n * paste result.\n * - Change the caret position to be positioned on the left hand side of the decimal character.\n * If 'truncate' :\n * - Truncate paste behavior.\n * - Try to set the new value, until it fails (if the result is out of the min and max value limits).\n * - Drop the remaining non-pasted numbers, and keep the last known non-failing result.\n * - Change the caret position to be positioned after the last pasted character.\n * If 'replace' :\n * - Replace paste behavior.\n * - Try to set the new value, until it fails (if the result is out of the min and max value limits).\n * - Then try to replace as many numbers as possible with the pasted ones. Once it fails, keep the last known non-failing result.\n * - Change the caret position to be positioned after the last pasted character.\n */\n var valueHasBeenSet = false;\n var valueHasBeenClamped = false;\n try {\n $this.autoNumeric('set', result);\n valueHasBeenSet = true;\n } catch (error) {\n var clampedValue = void 0;\n switch (holder.settings.onInvalidPaste) {\n case 'clamp':\n clampedValue = clampToRangeLimits(result, holder.settings);\n try {\n $this.autoNumeric('set', clampedValue);\n } catch (error) {\n throwError('Fatal error: Unable to set the clamped value \\'' + clampedValue + '\\'.');\n }\n\n valueHasBeenClamped = true;\n valueHasBeenSet = true;\n result = clampedValue; // This is used only for setting the caret position later\n break;\n case 'error':\n case 'truncate':\n case 'replace':\n // Throw an error message\n throwError('The pasted value \\'' + rawPastedText + '\\' results in a value \\'' + result + '\\' that is outside of the minimum [' + holder.settings.minimumValue + '] and maximum [' + holder.settings.maximumValue + '] value range.');\n // falls through\n case 'ignore':\n // Do nothing\n // falls through\n default:\n return; // ...and nothing else should be changed\n }\n }\n\n // 7. Then lastly, set the caret position at the right logical place\n var caretPositionInFormattedNumber = void 0;\n if (valueHasBeenSet) {\n switch (holder.settings.onInvalidPaste) {\n case 'clamp':\n if (valueHasBeenClamped) {\n if (holder.settings.currencySymbolPlacement === 's') {\n setElementSelection(e.target, e.target.value.length - holder.settings.currencySymbol.length); // This puts the caret on the right of the last decimal place\n } else {\n setElementSelection(e.target, e.target.value.length); // ..and this on the far right\n }\n\n break;\n } // else if the value has not been clamped, the default behavior is used...\n // falls through\n case 'error':\n case 'ignore':\n case 'truncate':\n case 'replace':\n default:\n // Whenever one or multiple characters are pasted, this means we have to manage the potential thousand separators that could be added by the formatting\n caretPositionInFormattedNumber = findCaretPositionInFormattedNumber(result, caretPositionOnInitialTextAfterPasting, e.target.value, holder.settings.decimalCharacter);\n setElementSelection(e.target, caretPositionInFormattedNumber);\n }\n }\n\n // 8. We make sure we send an input event only if the result is different than the initial value before the paste\n if (valueHasBeenSet && initialFormattedValue !== e.target.value) {\n // On a 'normal' non-autoNumeric input, an `input` event is sent when a paste is done. We mimic that.\n triggerEvent('input', e.target);\n }\n }\n\n /**\n * When focusing out of the input, we check if the value has changed, and if it has, then we send a `change` event (since the native one would have been prevented by `e.preventDefault()` called in the other event listeners).\n *\n * @param {AutoNumericHolder} holder\n * @param {Event} e\n */\n function onBlur(holder, e) {\n if (e.target.value !== holder.valueOnFocus) {\n triggerEvent('change', e.target);\n // e.preventDefault(); // ...and immediately prevent the browser to send a second change event (that somehow gets picked up by jQuery, but not by `addEventListener()` //FIXME KNOWN BUG : This does not prevent the second change event to be picked up by jQuery, which adds '.00' at the end of an integer\n }\n }\n\n /**\n * Handler for 'submit' events\n *\n * @param {object} $this jQuery-selected DOM element\n * @param {AutoNumericHolder} holder\n */\n function onSubmit($this, holder) {\n $this.closest('form').on('submit.autoNumeric', function () {\n if (holder) {\n var $settings = holder.settingsClone;\n\n if ($settings.unformatOnSubmit) {\n $this.val($settings.rawValue);\n }\n }\n });\n }\n\n /**\n * Return the jQuery selected input if the tag and type are supported by autoNumeric.\n *\n * @param {object} $this jQuery-selected DOM element\n * @returns {boolean|*}\n */\n function getInputIfSupportedTagAndType($this) {\n // Supported input type\n var $input = $this.is('input[type=text], input[type=hidden], input[type=tel], input:not([type])');\n\n // Checks for non-supported input types\n if (!$input && $this.prop('tagName').toLowerCase() === 'input') {\n throwError('The input type \"' + $this.prop('type') + '\" is not supported by autoNumeric');\n }\n\n // Checks for non-supported tags\n var currentElementTag = $this.prop('tagName').toLowerCase();\n if (currentElementTag !== 'input' && !isInArray(currentElementTag, allowedTagList)) {\n throwError('The <' + currentElementTag + '> tag is not supported by autoNumeric');\n }\n\n return $input;\n }\n\n /**\n * Formats the default value on page load.\n * This is called only if the `formatOnPageLoad` option is set to `true`.\n *\n * @param {object} settings\n * @param {object} $input jQuery-selected <input> element\n * @param {object} $this jQuery-selected DOM element\n */\n function formatDefaultValueOnPageLoad(settings, $input, $this) {\n var setValue = true;\n\n if ($input) {\n var currentValue = $this.val();\n /*\n * If the input value has been set by the dev, but not directly as an attribute in the html, then it takes\n * precedence and should get formatted on init (if this input value is a valid number and that the\n * developer wants it formatted on init (cf. `settings.formatOnPageLoad`)).\n * Note; this is true whatever the developer has set for `data-an-default` in the html (asp.net users).\n *\n * In other words : if `defaultValueOverride` is not null, it means the developer is trying to prevent postback problems.\n * But if `input.value` is set to a number, and `$this.attr('value')` is not set, then it means the dev has\n * changed the input value, and then it means we should not overwrite his own decision to do so.\n * Hence, if `defaultValueOverride` is not null, but `input.value` is a number and `$this.attr('value')` is not set,\n * we should ignore `defaultValueOverride` altogether.\n */\n var unLocalizedCurrentValue = toNumericValue(currentValue, settings); // This allows to use a localized value on startup oDec\n if (settings.formatOnPageLoad && currentValue !== '' && isUndefinedOrNullOrEmpty($this.attr('value'))) {\n // Check if the `value` is valid or not\n if (!isNaN(unLocalizedCurrentValue) && Infinity !== unLocalizedCurrentValue) {\n $this.autoNumeric('set', unLocalizedCurrentValue);\n setValue = false;\n } else {\n // If not, inform the developer that nothing usable has been provided\n throwError('The value [' + currentValue + '] used in the input is not a valid value autoNumeric can work with.');\n }\n } else {\n /* Checks for :\n * - page reload from back button, and\n * - ASP.net form post back\n * The following HTML data attribute is REQUIRED (data-an-default=\"same value as the value attribute\")\n * example: <asp:TextBox runat=\"server\" id=\"someID\" text=\"1234.56\" data-an-default=\"1234.56\">\n */\n if (settings.defaultValueOverride !== null && settings.defaultValueOverride.toString() !== currentValue || settings.defaultValueOverride === null && currentValue !== '' && currentValue !== $this.attr('value') || currentValue !== '' && $this.attr('type') === 'hidden' && !isNumber(unLocalizedCurrentValue)) {\n if (settings.decimalPlacesShownOnFocus !== null && settings.saveValueToSessionStorage || settings.scaleDivisor && settings.saveValueToSessionStorage) {\n settings.rawValue = saveValueToPersistentStorage($this[0], settings, 'get');\n }\n\n // If the decimalPlacesShownOnFocus value should NOT be saved in sessionStorage\n if (!settings.saveValueToSessionStorage) {\n var toStrip = void 0;\n\n if (settings.negativeBracketsTypeOnBlur !== null && settings.negativeSignCharacter !== '') {\n settings.hasFocus = true;\n toStrip = toggleNegativeBracket(currentValue, settings);\n } else {\n toStrip = currentValue;\n }\n\n if ((settings.negativePositiveSignPlacement === 's' || settings.negativePositiveSignPlacement !== 'p' && settings.currencySymbolPlacement === 's') && settings.negativeSignCharacter !== '' && isNegative(currentValue)) {\n settings.rawValue = settings.negativeSignCharacter + stripAllNonNumberCharacters(toStrip, settings, true);\n } else {\n settings.rawValue = stripAllNonNumberCharacters(toStrip, settings, true);\n }\n }\n\n setValue = false;\n }\n }\n\n if (currentValue === '') {\n switch (settings.emptyInputBehavior) {\n case 'focus':\n setValue = false;\n break;\n case 'always':\n $this.val(settings.currencySymbol);\n setValue = false;\n break;\n case 'zero':\n $this.autoNumeric('set', '0');\n setValue = false;\n break;\n default:\n //\n }\n } else if (setValue && currentValue === $this.attr('value')) {\n $this.autoNumeric('set', currentValue);\n }\n }\n\n if (isInArray($this.prop('tagName').toLowerCase(), settings.tagList) && $this.text() !== '') {\n if (settings.defaultValueOverride !== null) {\n if (settings.defaultValueOverride === $this.text()) {\n $this.autoNumeric('set', $this.text());\n }\n } else {\n $this.autoNumeric('set', $this.text());\n }\n }\n }\n\n /**\n * Enhance the user experience by modifying the default `negativePositiveSignPlacement` option depending on `currencySymbol` and `currencySymbolPlacement`.\n *\n * If the user has not set the placement of the negative sign (`negativePositiveSignPlacement`), but has set a currency symbol (`currencySymbol`),\n * then we modify the default value of `negativePositiveSignPlacement` in order to keep the resulting output logical by default :\n * - \"$-1,234.56\" instead of \"-$1,234.56\" ({currencySymbol: \"$\", negativePositiveSignPlacement: \"r\"})\n * - \"-1,234.56$\" instead of \"1,234.56-$\" ({currencySymbol: \"$\", currencySymbolPlacement: \"s\", negativePositiveSignPlacement: \"p\"})\n *\n * @param {object} settings\n */\n function correctNegativePositiveSignPlacementOption(settings) {\n // If negativePositiveSignPlacement is already set, we do not overwrite it\n if (!isNull(settings.negativePositiveSignPlacement)) {\n return;\n }\n\n if (!isUndefined(settings) && isUndefinedOrNullOrEmpty(settings.negativePositiveSignPlacement) && !isUndefinedOrNullOrEmpty(settings.currencySymbol)) {\n switch (settings.currencySymbolPlacement) {\n case 's':\n settings.negativePositiveSignPlacement = 'p'; // Default -1,234.56 €\n break;\n case 'p':\n settings.negativePositiveSignPlacement = 'l'; // Default -$1,234.56\n break;\n default:\n //\n }\n } else {\n // Sets the default value if `negativePositiveSignPlacement` is `null`\n settings.negativePositiveSignPlacement = 'l';\n }\n }\n\n /**\n * Analyze and save the minimumValue and maximumValue integer size for later uses\n *\n * @param {object} settings\n */\n function calculateVMinAndVMaxIntegerSizes(settings) {\n var _settings$maximumValu = settings.maximumValue.toString().split('.'),\n _settings$maximumValu2 = _slicedToArray(_settings$maximumValu, 1),\n maximumValueIntegerPart = _settings$maximumValu2[0];\n\n var _ref3 = !settings.minimumValue && settings.minimumValue !== 0 ? [] : settings.minimumValue.toString().split('.'),\n _ref4 = _slicedToArray(_ref3, 1),\n minimumValueIntegerPart = _ref4[0];\n\n maximumValueIntegerPart = maximumValueIntegerPart.replace('-', '');\n minimumValueIntegerPart = minimumValueIntegerPart.replace('-', '');\n\n settings.mIntPos = Math.max(maximumValueIntegerPart.length, 1);\n settings.mIntNeg = Math.max(minimumValueIntegerPart.length, 1);\n }\n\n /**\n * Modify `decimalPlacesOverride` as needed\n *\n * @param {object} settings\n */\n function correctDecimalPlacesOverrideOption(settings) {\n if (isNull(settings.decimalPlacesOverride)) {\n settings.decimalPlacesOverride = maximumVMinAndVMaxDecimalLength(settings.minimumValue, settings.maximumValue);\n }\n settings.oDec = String(settings.decimalPlacesOverride);\n\n // Most calculus assume `decimalPlacesOverride` is an integer, the following statement makes it clear (otherwise having it as a string leads to problems in rounding for instance)\n settings.decimalPlacesOverride = Number(settings.decimalPlacesOverride);\n }\n\n /**\n * Sets the alternative decimal separator key.\n *\n * @param {object} settings\n */\n function setsAlternativeDecimalSeparatorCharacter(settings) {\n if (isNull(settings.decimalCharacterAlternative) && Number(settings.decimalPlacesOverride) > 0) {\n if (settings.decimalCharacter === '.' && settings.digitGroupSeparator !== ',') {\n settings.decimalCharacterAlternative = ',';\n } else if (settings.decimalCharacter === ',' && settings.digitGroupSeparator !== '.') {\n settings.decimalCharacterAlternative = '.';\n }\n }\n }\n\n /**\n * Caches regular expressions for stripAllNonNumberCharacters\n *\n * @param {object} settings\n */\n function cachesUsualRegularExpressions(settings) {\n var allNumbersReg = '[0-9]';\n var noAllNumbersReg = '[^0-9]';\n\n // Test if there is a negative character in the string\n var aNegReg = settings.negativeSignCharacter ? '([-\\\\' + settings.negativeSignCharacter + ']?)' : '(-?)';\n settings.aNegRegAutoStrip = aNegReg;\n\n var negativeSignRegPart = void 0;\n if (settings.negativeSignCharacter) {\n negativeSignRegPart = '\\\\' + settings.negativeSignCharacter;\n } else {\n negativeSignRegPart = '';\n }\n settings.skipFirstAutoStrip = new RegExp(aNegReg + '[^-' + negativeSignRegPart + '\\\\' + settings.decimalCharacter + allNumbersReg + '].*?(' + allNumbersReg + '|\\\\' + settings.decimalCharacter + allNumbersReg + ')');\n settings.skipLastAutoStrip = new RegExp('(' + allNumbersReg + '\\\\' + settings.decimalCharacter + '?)[^\\\\' + settings.decimalCharacter + allNumbersReg + ']' + noAllNumbersReg + '*$');\n\n var allowed = '-0123456789\\\\' + settings.decimalCharacter;\n settings.allowedAutoStrip = new RegExp('[^' + allowed + ']', 'g');\n settings.numRegAutoStrip = new RegExp(aNegReg + '(?:\\\\' + settings.decimalCharacter + '?(' + allNumbersReg + '+\\\\' + settings.decimalCharacter + allNumbersReg + '+)|(' + allNumbersReg + '*(?:\\\\' + settings.decimalCharacter + allNumbersReg + '*)?))');\n\n // Using this regex version `^${settings.aNegRegAutoStrip}0*(\\\\d|$)` entirely clear the input on blur\n settings.stripReg = new RegExp('^' + settings.aNegRegAutoStrip + '0*(' + allNumbersReg + ')');\n }\n\n /**\n * Modify the user settings to make them 'exploitable' later.\n *\n * @param {object} settings\n */\n function transformOptionsValuesToDefaultTypes(settings) {\n $.each(settings, function (key, value) {\n // Convert the string 'true' and 'false' to real Boolean\n if (value === 'true' || value === 'false') {\n settings[key] = value === 'true';\n }\n\n // Convert numbers in options to strings\n //TODO if a value is already of type 'Number', shouldn't we keep it as a number for further manipulation, instead of using a string?\n if (typeof value === 'number' && key !== 'aScale') {\n settings[key] = value.toString();\n }\n });\n }\n\n /**\n * Convert the old settings options name to new ones.\n *\n * @param {object} options\n */\n function convertOldOptionsToNewOnes(options) {\n //TODO Delete this function once the old options are not used anymore\n var oldOptionsConverter = {\n // Old option name, with their corresponding new option\n aSep: 'digitGroupSeparator',\n nSep: 'noSeparatorOnFocus',\n dGroup: 'digitalGroupSpacing',\n aDec: 'decimalCharacter',\n altDec: 'decimalCharacterAlternative',\n aSign: 'currencySymbol',\n pSign: 'currencySymbolPlacement',\n pNeg: 'negativePositiveSignPlacement',\n aSuffix: 'suffixText',\n oLimits: 'overrideMinMaxLimits',\n vMax: 'maximumValue',\n vMin: 'minimumValue',\n mDec: 'decimalPlacesOverride',\n eDec: 'decimalPlacesShownOnFocus',\n scaleDecimal: 'scaleDecimalPlaces',\n aStor: 'saveValueToSessionStorage',\n mRound: 'roundingMethod',\n aPad: 'allowDecimalPadding',\n nBracket: 'negativeBracketsTypeOnBlur',\n wEmpty: 'emptyInputBehavior',\n lZero: 'leadingZero',\n aForm: 'formatOnPageLoad',\n sNumber: 'selectNumberOnly',\n anDefault: 'defaultValueOverride',\n unSetOnSubmit: 'unformatOnSubmit',\n outputType: 'outputFormat',\n debug: 'showWarnings',\n // Current options :\n digitGroupSeparator: true,\n noSeparatorOnFocus: true,\n digitalGroupSpacing: true,\n decimalCharacter: true,\n decimalCharacterAlternative: true,\n currencySymbol: true,\n currencySymbolPlacement: true,\n negativePositiveSignPlacement: true,\n showPositiveSign: true,\n suffixText: true,\n overrideMinMaxLimits: true,\n maximumValue: true,\n minimumValue: true,\n decimalPlacesOverride: true,\n decimalPlacesShownOnFocus: true,\n scaleDivisor: true,\n scaleDecimalPlaces: true,\n scaleSymbol: true,\n saveValueToSessionStorage: true,\n onInvalidPaste: true,\n roundingMethod: true,\n allowDecimalPadding: true,\n negativeBracketsTypeOnBlur: true,\n emptyInputBehavior: true,\n leadingZero: true,\n formatOnPageLoad: true,\n selectNumberOnly: true,\n defaultValueOverride: true,\n unformatOnSubmit: true,\n outputFormat: true,\n showWarnings: true,\n failOnUnknownOption: true,\n //FIXME Find a way to exclude those internal data from the settings object (ideally by using another object, or better yet, class attributes) -->\n hasFocus: true,\n runOnce: true,\n rawValue: true,\n trailingNegative: true,\n caretFix: true,\n throwInput: true,\n strip: true,\n tagList: true,\n negativeSignCharacter: true,\n positiveSignCharacter: true,\n mIntPos: true,\n mIntNeg: true,\n oDec: true,\n oPad: true,\n oBracket: true,\n oSep: true,\n oSign: true,\n oSuffix: true,\n aNegRegAutoStrip: true,\n skipFirstAutoStrip: true,\n skipLastAutoStrip: true,\n allowedAutoStrip: true,\n numRegAutoStrip: true,\n stripReg: true,\n holder: true\n };\n\n for (var option in options) {\n if (options.hasOwnProperty(option)) {\n if (oldOptionsConverter[option] === true) {\n // If the option is a 'new' option, we continue looping\n continue;\n }\n\n if (oldOptionsConverter.hasOwnProperty(option)) {\n // Else we have an 'old' option name\n warning('You are using the deprecated option name \\'' + option + '\\'. Please use \\'' + oldOptionsConverter[option] + '\\' instead from now on. The old option name will be dropped soon.', true);\n\n // Then we modify the initial option object to use the new options instead of the old ones\n options[oldOptionsConverter[option]] = options[option];\n delete options[option];\n } else if (options.failOnUnknownOption) {\n // ...or the option name is unknown. This means there is a problem with the options object, therefore we throw an error.\n throwError('Option name \\'' + option + '\\' is unknown. Please fix the options passed to autoNumeric');\n }\n }\n }\n }\n\n /**\n * Analyse the settings/options passed by the user, validate and clean them, then return them.\n * Note: This returns `null` if somehow the settings returned by jQuery is not an object.\n *\n * @param {object} options\n * @param {object} $this jQuery-selected DOM element\n * @param {boolean} update - If TRUE, then the settings already exists and this function only updates them instead of recreating them from scratch\n * @returns {object|null}\n */\n function getInitialSettings(options, $this) {\n var update = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;\n\n // Attempt to grab \"autoNumeric\" settings. If they do not exist, it returns \"undefined\".\n var settings = $this.data('autoNumeric');\n\n // If the user used old options, we convert them to new ones\n if (update || !isNull(options)) {\n convertOldOptionsToNewOnes(options);\n }\n\n if (update || isUndefined(settings)) {\n if (update) {\n // The settings are updated\n settings = $.extend(settings, options);\n } else {\n // If we couldn't grab any settings, create them from the default ones and combine them with the options passed\n // The settings are generated for the first time\n // This also attempt to grab the HTML5 data. If it doesn't exist, we'll get \"undefined\"\n var tagData = $this.data();\n settings = $.extend({}, defaultSettings, tagData, options, {\n hasFocus: false,\n runOnce: false,\n rawValue: '',\n trailingNegative: false,\n caretFix: false,\n throwInput: true, // Throw input event\n strip: true,\n tagList: allowedTagList\n });\n }\n\n // Modify the user settings to make them 'exploitable'\n transformOptionsValuesToDefaultTypes(settings);\n\n // Improve the `negativePositiveSignPlacement` option if needed\n correctNegativePositiveSignPlacementOption(settings);\n\n // Set the negative and positive signs, as needed\n settings.negativeSignCharacter = settings.minimumValue < 0 ? '-' : '';\n settings.positiveSignCharacter = settings.maximumValue >= 0 ? '+' : '';\n\n // Additional changes to the settings object (from the original autoCode() function)\n runCallbacksFoundInTheSettingsObject($this, settings);\n calculateVMinAndVMaxIntegerSizes(settings);\n correctDecimalPlacesOverrideOption(settings);\n setsAlternativeDecimalSeparatorCharacter(settings);\n cachesUsualRegularExpressions(settings);\n\n // Validate the settings\n validate(settings, false); // Throws if necessary\n\n // Original settings saved for use when decimalPlacesShownOnFocus, scaleDivisor & noSeparatorOnFocus options are being used\n keepAnOriginalSettingsCopy(settings);\n\n // Save our new settings\n $this.data('autoNumeric', settings);\n\n return settings;\n } else {\n return null;\n }\n }\n\n /**\n * Convert the `value` parameter that can either be :\n * - a real number,\n * - a string representing a real number, or\n * - a string representing a localized number (with specific group separators and decimal character),\n * ...to a string representing a real 'javascript' number (ie. '1234' or '1234.567').\n *\n * This function returns `NaN` if such conversion fails.\n *\n * @param {int|float|string} value\n * @param {object} settings\n * @returns {string|NaN}\n */\n function toNumericValue(value, settings) {\n var result = void 0;\n if (isNumber(Number(value))) {\n // The value has either already been stripped, or a 'real' javascript number is passed as a parameter\n result = value;\n } else {\n // Else if it's a string that `Number()` cannot typecast, then we try to convert the localized numeric string to a numeric one\n // Convert the value to a numeric string, stripping unnecessary characters in the process\n result = convertToNumericString(value.toString(), settings);\n\n // If the result is still not a numeric string, then we throw a warning\n if (!isNumber(Number(result))) {\n warning('The value \"' + value + '\" being \"set\" is not numeric and therefore cannot be used appropriately.', settings.showWarnings);\n result = NaN;\n }\n }\n\n return result;\n }\n\n /**\n * Methods supported by autoNumeric\n */\n var methods = {\n /**\n * Method to initialize autoNumeric and attach the settings (options can be passed as a parameter)\n * The options passed as a parameter is an object that contains the settings (ie. {digitGroupSeparator: \".\", decimalCharacter: \",\", currencySymbol: '€ '})\n *\n * @example\n * $(someSelector).autoNumeric('init'); // Initiate autoNumeric with defaults\n * $(someSelector).autoNumeric(); // Initiate autoNumeric with defaults\n * $(someSelector).autoNumeric('init', {options}); // Initiate autoNumeric with options\n * $(someSelector).autoNumeric({options}); // Initiate autoNumeric with options\n *\n * @param {object} options\n * @returns {*|{statements, branches, lines, functions, excludes, overrides}|{statements, branches, lines, functions, excludes}|{statements, lines, branches, functions, excludes}}\n */\n init: function init(options) {\n return this.each(function () {\n var $this = $(this);\n var $input = getInputIfSupportedTagAndType($this);\n\n var settings = getInitialSettings(options, $this, false);\n if (isNull(settings)) {\n return this;\n }\n\n // Create the AutoNumericHolder object that store the field properties\n var holder = getAutoNumericHolder($this, settings, false);\n\n if (!settings.runOnce && settings.formatOnPageLoad) {\n formatDefaultValueOnPageLoad(settings, $input, $this);\n }\n\n settings.runOnce = true;\n\n // Add the events listeners to supported input types (\"text\", \"hidden\", \"tel\" and no type)\n if ($input) {\n this.addEventListener('focusin', function (e) {\n onFocusInAndMouseEnter($this, holder, e);\n }, false);\n this.addEventListener('mouseenter', function (e) {\n onFocusInAndMouseEnter($this, holder, e);\n }, false);\n this.addEventListener('blur', function (e) {\n onFocusOutAndMouseLeave($this, holder, e);\n }, false);\n this.addEventListener('mouseleave', function (e) {\n onFocusOutAndMouseLeave($this, holder, e);\n }, false);\n this.addEventListener('keydown', function (e) {\n onKeydown(holder, e);\n }, false);\n this.addEventListener('keypress', function (e) {\n onKeypress(holder, e);\n }, false);\n this.addEventListener('keyup', function (e) {\n onKeyup(holder, settings, e);\n }, false);\n this.addEventListener('blur', function (e) {\n onBlur(holder, e);\n }, false);\n this.addEventListener('paste', function (e) {\n onPaste($this, holder, e);\n }, false);\n onSubmit($this, holder); //TODO Switch to `addEventListener'\n }\n });\n },\n\n\n /**\n * Method to stop and remove autoNumeric for the current element.\n * Note: this does not remove the formatting.\n *\n * @example $(someSelector).autoNumeric(\"destroy\"); // Destroys autoNumeric on this selected element\n *\n * @returns {*|jQuery}\n */\n destroy: function destroy() {\n return $(this).each(function () {\n var $this = getCurrentElement(this);\n var settings = $this.data('autoNumeric');\n if ((typeof settings === 'undefined' ? 'undefined' : _typeof(settings)) === 'object') {\n $this.val('');\n saveValueToPersistentStorage($this[0], settings, 'wipe');\n $this.removeData('autoNumeric');\n $this.off('.autoNumeric');\n }\n });\n },\n\n\n /**\n * Method to clear the value from sessionStorage (or cookie, depending on browser supports).\n *\n * @example $(someSelector).autoNumeric(\"wipe\"); // Removes session storage and cookies from memory\n *\n * @returns {*|jQuery}\n */\n wipe: function wipe() {\n return $(this).each(function () {\n var $this = getCurrentElement(this);\n var settings = $this.data('autoNumeric');\n if ((typeof settings === 'undefined' ? 'undefined' : _typeof(settings)) === 'object') {\n $this.val('');\n settings.rawValue = '';\n saveValueToPersistentStorage($this[0], settings, 'wipe');\n }\n });\n },\n\n\n /**\n * Method that updates the autoNumeric settings.\n * It can be called multiple times if needed.\n * The options passed as a parameter is an object that contains the settings (ie. {digitGroupSeparator: \".\", decimalCharacter: \",\", currencySymbol: '€ '}).\n *\n * @example $(someSelector).autoNumeric(\"update\", {options}); // Updates the settings\n *\n * @param {object} options\n * @returns {*|jQuery}\n */\n update: function update(options) {\n return $(this).each(function () {\n // Retrieve the current unformatted input value\n var $this = getCurrentElement(this);\n var strip = $this.autoNumeric('get');\n\n // Update the settings\n var settings = getInitialSettings(options, $this, true);\n\n // Update the AutoNumericHolder object that store the field properties\n getAutoNumericHolder($this, settings, true);\n\n // Reformat the input value with the new settings\n if ($this.val() !== '' || $this.text() !== '') {\n return $this.autoNumeric('set', strip);\n }\n });\n },\n\n\n /**\n * Method to format the value passed as a parameter.\n * If the value is passed as a string, it can be an integer '1234' or a double '1234.56789'\n * and must contain only numbers and one decimal (period) character\n *\n * @example $(someSelector).autoNumeric('set', '12345.67'); // Formats the value being passed as the second parameter\n *\n * @param {*} newValue\n * @returns {*|jQuery}\n */\n set: function set(newValue) {\n return $(this).each(function () {\n if (newValue === null || isUndefined(newValue)) {\n return;\n }\n\n //TODO This looks a lot like `getInputIfSupportedTagAndType()`. Is that necessary? Can the input element be changed since autoNumeric has been initialized?\n var $this = getCurrentElement(this);\n var settings = $this.data('autoNumeric');\n if ((typeof settings === 'undefined' ? 'undefined' : _typeof(settings)) !== 'object') {\n throwError('Initializing autoNumeric is required prior to calling the \"set\" method.');\n }\n // Reset the trailing negative settings, since it's possible the previous value was negative, but not the newly set one\n settings.trailingNegative = false;\n\n var $input = $this.is('input[type=text], input[type=hidden], input[type=tel], input:not([type])');\n\n var value = toNumericValue(newValue, settings);\n if (isNaN(value)) {\n return $this.val('');\n }\n\n if (value !== '') {\n var _checkIfInRangeWithOv5 = checkIfInRangeWithOverrideOption(value, settings),\n _checkIfInRangeWithOv6 = _slicedToArray(_checkIfInRangeWithOv5, 2),\n minTest = _checkIfInRangeWithOv6[0],\n maxTest = _checkIfInRangeWithOv6[1];\n // This test is needed by the showPositiveSign option\n\n\n var isZero = isZeroOrHasNoValue(value);\n if (isZero) {\n value = '0';\n }\n\n if (minTest && maxTest) {\n if ($input || isInArray($this.prop('tagName').toLowerCase(), settings.tagList)) {\n // to ensure rounding does not happen twice\n var hasBeenRounded = false;\n\n // rounds the the extended decimal places\n var tempDecimal = void 0;\n if (settings.decimalPlacesShownOnFocus) {\n tempDecimal = settings.decimalPlacesOverride;\n settings.decimalPlacesOverride = Number(settings.decimalPlacesShownOnFocus);\n value = roundValue(value, settings);\n hasBeenRounded = true;\n settings.decimalPlacesOverride = tempDecimal;\n }\n\n if (settings.scaleDivisor && !settings.onOff) {\n value = roundValue(value, settings);\n settings.rawValue = cleanLeadingTrailingZeros(value.replace(settings.decimalCharacter, '.'), settings);\n value = toNumericValue(value, settings);\n value = value / settings.scaleDivisor;\n value = value.toString();\n if (settings.scaleDecimalPlaces) {\n tempDecimal = settings.decimalPlacesOverride;\n settings.decimalPlacesOverride = Number(settings.scaleDecimalPlaces);\n value = roundValue(value, settings);\n hasBeenRounded = true;\n }\n }\n\n // Rounds if this has not been done already\n if (!hasBeenRounded) {\n value = roundValue(value, settings);\n }\n\n // Stores rawValue including the decimalPlacesShownOnFocus\n if (!settings.scaleDivisor) {\n settings.rawValue = cleanLeadingTrailingZeros(value.replace(settings.decimalCharacter, '.'), settings);\n }\n\n value = modifyNegativeSignAndDecimalCharacterForFormattedValue(value, settings);\n value = addGroupSeparators(value, settings);\n\n if (settings.scaleDivisor && settings.scaleDecimalPlaces && !settings.onOff) {\n settings.decimalPlacesOverride = tempDecimal;\n }\n }\n\n if (settings.saveValueToSessionStorage && (settings.decimalPlacesShownOnFocus || settings.scaleDivisor)) {\n saveValueToPersistentStorage($this[0], settings, 'set');\n }\n } else {\n settings.rawValue = '';\n saveValueToPersistentStorage($this[0], settings, 'wipe');\n var attemptedValue = value;\n value = '';\n if (!minTest) {\n $this.trigger('autoNumeric:minExceeded');\n }\n\n if (!maxTest) {\n $this.trigger('autoNumeric:maxExceeded');\n }\n\n throwError('The value [' + attemptedValue + '] being set falls outside of the minimumValue [' + settings.minimumValue + '] and maximumValue [' + settings.maximumValue + '] range set for this element');\n\n return $this.val('');\n }\n } else {\n return $this.val('');\n }\n\n if (!settings.hasFocus && settings.scaleSymbol) {\n value = value + settings.scaleSymbol;\n }\n\n if ($input) {\n return $this.val(value);\n }\n\n if (isInArray($this.prop('tagName').toLowerCase(), settings.tagList)) {\n return $this.text(value);\n }\n\n return false;\n });\n },\n\n\n /**\n * Method to un-format inputs.\n * This is handy to use right before form submission.\n *\n * By default, values are returned as ISO numeric strings (ie. \"1234.56\" or \"-1234.56\"), where the decimal character is a period.\n * Locale formats are supported \"1234.56-\" or \"1234,56\" or \"-1234,56 or \"1234,56-\", or even plain numbers.\n * Please see option \"outputFormat\" for more details\n *\n * @example $(someSelector).autoNumeric('unSet');\n *\n * @returns {*|jQuery}\n */\n unSet: function unSet() {\n return $(this).each(function () {\n var $this = getCurrentElement(this);\n var settings = $this.data('autoNumeric');\n if ((typeof settings === 'undefined' ? 'undefined' : _typeof(settings)) === 'object') {\n settings.hasFocus = true;\n $this.val($this.autoNumeric('getLocalized'));\n }\n });\n },\n\n\n /**\n * Method to re-format inputs.\n * This is handy to use right after form submission.\n *\n * This is called after the 'unSet' method to reformat the input\n *\n * @example $(someSelector).autoNumeric('reSet');\n *\n * @returns {*|jQuery}\n */\n reSet: function reSet() {\n return $(this).each(function () {\n var $this = getCurrentElement(this);\n var settings = $this.data('autoNumeric');\n if ((typeof settings === 'undefined' ? 'undefined' : _typeof(settings)) === 'object') {\n $this.autoNumeric('set', $this.val());\n }\n });\n },\n\n\n /**\n * Return the unformatted value as a string.\n *\n * @usage $(someSelector).autoNumeric('get');\n *\n * @returns {string}\n */\n get: function get() {\n //TODO Why would we need to get a new reference to $this since it has been done in `init()`?\n var $this = getCurrentElement(this);\n //TODO This looks a lot like `getInputIfSupportedTagAndType()`. Is that necessary? Can the input element be changed since autoNumeric has been initialized?\n var $input = $this.is('input[type=text], input[type=hidden], input[type=tel], input:not([type])');\n var settings = $this.data('autoNumeric');\n if ((typeof settings === 'undefined' ? 'undefined' : _typeof(settings)) !== 'object') {\n throwError('Initializing autoNumeric is required prior to calling the \"get\" method.');\n }\n\n // determine the element type then use .eq(0) selector to grab the value of the first element in selector\n var value = '';\n if ($input) {\n value = $this.eq(0).val();\n } else if (isInArray($this.prop('tagName').toLowerCase(), settings.tagList)) {\n value = $this.eq(0).text();\n } else {\n throwError('The \"<' + $this.prop('tagName').toLowerCase() + '>\" tag is not supported by autoNumeric');\n }\n\n if (settings.decimalPlacesShownOnFocus || settings.scaleDivisor) {\n value = settings.rawValue;\n } else {\n // Test if the value is negative\n var isValueNegative = isNegative(value);\n\n if (!/\\d/.test(value) && settings.emptyInputBehavior === 'focus') {\n return '';\n }\n\n if (value !== '' && settings.negativeBracketsTypeOnBlur !== null) {\n settings.hasFocus = true;\n value = toggleNegativeBracket(value, settings);\n }\n\n if (settings.runOnce || settings.formatOnPageLoad === false) {\n // Strips trailing negative symbol\n value = stripAllNonNumberCharacters(value, settings, true);\n // Trims leading and trailing zeros when leadingZero does NOT equal \"keep\".\n value = cleanLeadingTrailingZeros(value.replace(settings.decimalCharacter, '.'), settings);\n\n // Places the negative symbol in front of the trailing negative\n if (settings.trailingNegative && isValueNegative && !isNegative(value) && Number(value) !== 0) {\n value = '-' + value;\n }\n }\n\n if (value !== '' || value === '' && settings.emptyInputBehavior === 'zero') {\n value = modifyNegativeSignAndDecimalCharacterForRawValue(value, settings);\n }\n }\n\n // Always return a numeric string\n // This gets rid of the trailing zeros in the decimal places since `get` does not pad decimals\n return trimPaddedZerosFromDecimalPlaces(value);\n },\n\n\n /**\n * Returns the unformatted value, but following the `outputFormat` setting, which means the output can either be :\n * - a string (that could or could not represent a number (ie. \"12345,67-\")), or\n * - a plain number (if the setting 'number' is used).\n *\n * By default the returned values are an ISO numeric string \"1234.56\" or \"-1234.56\" where the decimal character is a period.\n * Check the \"outputFormat\" option definition for more details.\n *\n * @usage $(someSelector).autoNumeric('getLocalized');\n *\n * @returns {*}\n */\n getLocalized: function getLocalized() {\n var $this = getCurrentElement(this);\n var value = $this.autoNumeric('get');\n var settings = $this.data('autoNumeric');\n\n if (Number(value) === 0 && settings.leadingZero !== 'keep') {\n value = '0';\n }\n\n return toLocale(value, settings.outputFormat);\n },\n\n\n /**\n * Return the input unformatted value as a real Javascript number.\n *\n * @usage $(someSelector).autoNumeric('getNumber');\n *\n * @returns {number}\n */\n getNumber: function getNumber() {\n var $this = getCurrentElement(this);\n var value = $this.autoNumeric('get');\n\n return toLocale(value, 'number');\n },\n\n\n /**\n * Return the current formatted value of the autoNumeric element.\n * @usage aNInput.autoNumeric('getFormatted'))\n *\n * @returns {string}\n */\n getFormatted: function getFormatted() {\n // Make sure `this[0]` exists as well as `.value` before trying to access that property\n if (!this.hasOwnProperty('0') || !('value' in this[0])) {\n throwError('Unable to get the formatted string from the element.');\n }\n\n return this[0].value;\n },\n\n\n /**\n * The \"getString\" method uses jQuery's .serialize() method that creates a text string in standard URL-encoded notation.\n *\n * It then loops through the string and un-formats the inputs with autoNumeric.\n * By defaults values returned as ISO numeric string \"1234.56\" or \"-1234.56\" where the decimal character is a period\n * Locale formats are supported \"1234.56-\" or \"1234,56\" or \"-1234,56 or \"1234,56-\" or plain numbers => please see option \"outputFormat\" for details\n *\n * @returns {string}\n */\n getString: function getString() {\n return _getStringOrArray(false, this);\n },\n\n\n /**\n * The \"getArray\" method on the other hand uses jQuery's .serializeArray() method that creates array or objects that can be encoded as a JSON string.\n *\n * It then loops through the string and un-formats the inputs with autoNumeric.\n * By defaults values returned as ISO numeric string \"1234.56\" or \"-1234.56\" where the decimal character is a period\n * Locale formats are supported \"1234.56-\" or \"1234,56\" or \"-1234,56 or \"1234,56-\" or plain numbers => please see option \"outputFormat\" for details\n *\n * @returns {{}|[]}\n */\n getArray: function getArray() {\n return _getStringOrArray(true, this);\n },\n\n\n /**\n * The 'getSettings' function returns an object containing all the current autoNumeric settings.\n *\n * @example\n * $(someSelector).autoNumeric('getSettings');\n * $(someSelector).autoNumeric('getSettings').decimalCharacter; // Return the decimalCharacter setting as a string - any valid option name can be used\n *\n * @returns {object}\n */\n getSettings: function getSettings() {\n //TODO Add an option argument `optionName` to this function so that it return only the value of that option, not the entire settings object\n return this.data('autoNumeric');\n }\n };\n\n /**\n * The autoNumeric function accepts methods names (in string format) and those method parameters if needed.\n * It initialize autoNumeric on the given element.\n *\n * @param {string} method The method name (ie. 'set', 'get', etc.)\n * @param {*} args\n * @returns {*}\n */\n $.fn.autoNumeric = function (method) {\n if (methods[method]) {\n for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return methods[method].apply(this, args);\n }\n\n if ((typeof method === 'undefined' ? 'undefined' : _typeof(method)) === 'object' || !method) {\n // The options have been passed directly, without using a named method\n return methods.init.apply(this, [method]);\n }\n\n throwError('Method \"' + method + '\" is not supported by autoNumeric');\n };\n\n /**\n * Return the default autoNumeric settings.\n *\n * @returns {object}\n */\n getDefaultConfig = function getDefaultConfig() {\n return defaultSettings;\n };\n\n $.fn.autoNumeric.defaults = defaultSettings; // Make those settings public via jQuery too.\n\n /**\n * Return all the predefined language options in one object.\n * You can also access a specific language object directly by using `an.getLanguages().French` for instance.\n *\n * @returns {object}\n */\n getLanguages = function getLanguages() {\n return languageOption;\n };\n\n $.fn.autoNumeric.lang = languageOption; // Make those predefined language options public via jQuery too.\n\n /**\n * Public function that allows formatting without an element trigger.\n *\n * @param {number|string} value A number, or a string that represent a javascript number\n * @param {object|null} options\n * @returns {*}\n */\n autoFormat = function autoFormat(value) {\n var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;\n\n if (isUndefined(value) || value === null) {\n return null;\n }\n\n if (!isString(value) && !isNumber(value)) {\n throwError('The value \"' + value + '\" being \"set\" is not numeric and therefore cannot be used appropriately.');\n }\n\n // Initiate a very basic settings object\n var settings = $.extend({}, defaultSettings, { strip: false }, options);\n if (value < 0) {\n settings.negativeSignCharacter = '-';\n }\n\n if (isNull(settings.decimalPlacesOverride)) {\n settings.decimalPlacesOverride = maximumVMinAndVMaxDecimalLength(settings.minimumValue, settings.maximumValue);\n }\n\n // Check the validity of the `value` parameter\n // Convert the value to a numeric string, stripping unnecessary characters in the process\n var valueString = toNumericValue(value, settings);\n if (isNaN(valueString)) {\n throwError('The value [' + valueString + '] that you are trying to format is not a recognized number.');\n }\n\n // Basic tests to check if the given valueString is valid\n\n var _checkIfInRangeWithOv7 = checkIfInRangeWithOverrideOption(valueString, settings),\n _checkIfInRangeWithOv8 = _slicedToArray(_checkIfInRangeWithOv7, 2),\n minTest = _checkIfInRangeWithOv8[0],\n maxTest = _checkIfInRangeWithOv8[1];\n\n if (!minTest || !maxTest) {\n // Throw a custom event\n triggerEvent('autoFormat.autoNumeric', document, 'Range test failed');\n throwError('The value [' + valueString + '] being set falls outside of the minimumValue [' + settings.minimumValue + '] and maximumValue [' + settings.maximumValue + '] range set for this element');\n }\n\n // Everything is ok, proceed to rounding, formatting and grouping\n valueString = roundValue(valueString, settings);\n valueString = modifyNegativeSignAndDecimalCharacterForFormattedValue(valueString, settings);\n valueString = addGroupSeparators(valueString, settings);\n\n return valueString;\n };\n\n $.fn.autoFormat = autoFormat; // The jQuery export\n\n /**\n * Public function that allows unformatting without an element.\n *\n * @param {string|number} value\n * @param {object} options\n * @returns {*}\n */\n autoUnFormat = function autoUnFormat(value, options) {\n if (isUndefined(value) || value === null) {\n return null;\n }\n\n // Giving an unformatted value should return the same unformatted value, whatever the options passed as a parameter\n if (isNumber(value)) {\n return Number(value);\n }\n\n if (isArray(value) || isObject(value)) {\n //TODO Complete the test to throw when given a wrongly formatted number (ie. 'foobar')\n // Check the validity of the `value` parameter\n throwError('A number or a string representing a number is needed to be able to unformat it, [' + value + '] given.');\n }\n\n var settings = $.extend({}, defaultSettings, { strip: false }, options);\n var allowed = '-0123456789\\\\' + settings.decimalCharacter;\n var autoStrip = new RegExp('[^' + allowed + ']', 'gi');\n value = value.toString();\n\n // This checks is a negative sign is anywhere in the `value`, not just on the very first character (ie. '12345.67-')\n if (isNegative(value)) {\n settings.negativeSignCharacter = '-';\n } else if (settings.negativeBracketsTypeOnBlur && settings.negativeBracketsTypeOnBlur.split(',')[0] === value.charAt(0)) {\n settings.negativeSignCharacter = '-';\n settings.hasFocus = true;\n value = toggleNegativeBracket(value, settings);\n }\n\n value = value.replace(autoStrip, '');\n value = value.replace(settings.decimalCharacter, '.');\n value = toLocale(value, settings.outputFormat);\n\n return value;\n };\n\n $.fn.autoUnformat = autoUnFormat; // The jQuery export\n\n /**\n * Validate the given option object.\n * If the options are valid, this function returns nothing, otherwise if the options are invalid, this function throws an error.\n *\n * This tests if the options are not conflicting and are well formatted.\n * This function is lenient since it only tests the settings properties ; it ignores any other properties the options object could have.\n *\n * @param {*} userOptions\n * @param {Boolean} shouldExtendDefaultOptions If TRUE, then this function will extends the `userOptions` passed by the user, with the default options.\n * @throws Error\n */\n validate = function validate(userOptions) {\n var shouldExtendDefaultOptions = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;\n\n if (isUndefinedOrNullOrEmpty(userOptions) || !isObject(userOptions) || isEmptyObj(userOptions)) {\n throwError('The userOptions are invalid ; it should be a valid object, [' + userOptions + '] given.');\n }\n\n // If the user used old options, we convert them to new ones\n if (!isNull(userOptions)) {\n convertOldOptionsToNewOnes(userOptions);\n }\n\n // The user can choose if the `userOptions` has already been extended with the default options, or not\n var options = void 0;\n if (shouldExtendDefaultOptions) {\n options = $.extend({}, defaultSettings, userOptions);\n } else {\n options = userOptions;\n }\n\n // First things first, we test that the `showWarnings` option is valid\n if (!isTrueOrFalseString(options.showWarnings) && !isBoolean(options.showWarnings)) {\n throwError('The debug option \\'showWarnings\\' is invalid ; it should be either \\'false\\' or \\'true\\', [' + options.showWarnings + '] given.');\n }\n\n // Define the regular expressions needed for the following tests\n var testPositiveInteger = /^[0-9]+$/;\n var testNumericalCharacters = /[0-9]+/;\n // const testFloatAndPossibleNegativeSign = /^-?[0-9]+(\\.?[0-9]+)$/;\n var testFloatOrIntegerAndPossibleNegativeSign = /^-?[0-9]+(\\.?[0-9]+)?$/;\n var testPositiveFloatOrInteger = /^[0-9]+(\\.?[0-9]+)?$/;\n\n // Then tests the options individually\n if (!isInArray(options.digitGroupSeparator, [',', // Comma\n '.', // Dot\n ' ', // Normal space\n '\\u2009', // Thin-space\n '\\u202F', // Narrow no-break space\n '\\xA0', // No-break space\n '', // No separator\n \"'\", // Apostrophe\n '٬', // Arabic thousands separator\n '˙'])) {\n throwError('The thousand separator character option \\'digitGroupSeparator\\' is invalid ; it should be \\',\\', \\'.\\', \\'\\u066C\\', \\'\\u02D9\\', \"\\'\", \\' \\', \\'\\u2009\\', \\'\\u202F\\', \\'\\xA0\\' or empty (\\'\\'), [' + options.digitGroupSeparator + '] given.');\n }\n\n if (!isTrueOrFalseString(options.noSeparatorOnFocus) && !isBoolean(options.noSeparatorOnFocus)) {\n throwError('The \\'noSeparatorOnFocus\\' option is invalid ; it should be either \\'false\\' or \\'true\\', [' + options.noSeparatorOnFocus + '] given.');\n }\n\n if (!testPositiveInteger.test(options.digitalGroupSpacing)) {\n throwError('The digital grouping for thousand separator option \\'digitalGroupSpacing\\' is invalid ; it should be a positive integer, [' + options.digitalGroupSpacing + '] given.');\n }\n\n if (!isInArray(options.decimalCharacter, [',', // Comma\n '.', // Dot\n '·', // Middle-dot\n '٫', // Arabic decimal separator\n '⎖'])) {\n throwError('The decimal separator character option \\'decimalCharacter\\' is invalid ; it should be \\'.\\', \\',\\', \\'\\xB7\\', \\'\\u2396\\' or \\'\\u066B\\', [' + options.decimalCharacter + '] given.');\n }\n\n // Checks if the decimal and thousand characters are the same\n if (options.decimalCharacter === options.digitGroupSeparator) {\n throwError('autoNumeric will not function properly when the decimal character \\'decimalCharacter\\' [' + options.decimalCharacter + '] and the thousand separator \\'digitGroupSeparator\\' [' + options.digitGroupSeparator + '] are the same character.');\n }\n\n if (!isNull(options.decimalCharacterAlternative) && !isString(options.decimalCharacterAlternative)) {\n throwError('The alternate decimal separator character option \\'decimalCharacterAlternative\\' is invalid ; it should be a string, [' + options.decimalCharacterAlternative + '] given.');\n }\n\n if (options.currencySymbol !== '' && !isString(options.currencySymbol)) {\n throwError('The currency symbol option \\'currencySymbol\\' is invalid ; it should be a string, [' + options.currencySymbol + '] given.');\n }\n\n if (!isInArray(options.currencySymbolPlacement, ['p', 's'])) {\n throwError('The placement of the currency sign option \\'currencySymbolPlacement\\' is invalid ; it should either be \\'p\\' (prefix) or \\'s\\' (suffix), [' + options.currencySymbolPlacement + '] given.');\n }\n\n if (!isInArray(options.negativePositiveSignPlacement, ['p', 's', 'l', 'r', null])) {\n throwError('The placement of the negative sign option \\'negativePositiveSignPlacement\\' is invalid ; it should either be \\'p\\' (prefix), \\'s\\' (suffix), \\'l\\' (left), \\'r\\' (right) or \\'null\\', [' + options.negativePositiveSignPlacement + '] given.');\n }\n\n if (!isTrueOrFalseString(options.showPositiveSign) && !isBoolean(options.showPositiveSign)) {\n throwError('The show positive sign option \\'showPositiveSign\\' is invalid ; it should be either \\'false\\' or \\'true\\', [' + options.showPositiveSign + '] given.');\n }\n\n if (!isString(options.suffixText) || options.suffixText !== '' && (isNegative(options.suffixText) || testNumericalCharacters.test(options.suffixText))) {\n throwError('The additional suffix option \\'suffixText\\' is invalid ; it should not contains the negative sign \\'-\\' nor any numerical characters, [' + options.suffixText + '] given.');\n }\n\n if (!isNull(options.overrideMinMaxLimits) && !isInArray(options.overrideMinMaxLimits, ['ceiling', 'floor', 'ignore'])) {\n throwError('The override min & max limits option \\'overrideMinMaxLimits\\' is invalid ; it should either be \\'ceiling\\', \\'floor\\' or \\'ignore\\', [' + options.overrideMinMaxLimits + '] given.');\n }\n\n if (!isString(options.maximumValue) || !testFloatOrIntegerAndPossibleNegativeSign.test(options.maximumValue)) {\n throwError('The maximum possible value option \\'maximumValue\\' is invalid ; it should be a string that represents a positive or negative number, [' + options.maximumValue + '] given.');\n }\n\n if (!isString(options.minimumValue) || !testFloatOrIntegerAndPossibleNegativeSign.test(options.minimumValue)) {\n throwError('The minimum possible value option \\'minimumValue\\' is invalid ; it should be a string that represents a positive or negative number, [' + options.minimumValue + '] given.');\n }\n\n if (parseFloat(options.minimumValue) > parseFloat(options.maximumValue)) {\n throwError('The minimum possible value option is greater than the maximum possible value option ; \\'minimumValue\\' [' + options.minimumValue + '] should be smaller than \\'maximumValue\\' [' + options.maximumValue + '].');\n }\n\n if (!(isNull(options.decimalPlacesOverride) || isInt(options.decimalPlacesOverride) && options.decimalPlacesOverride >= 0 || // If integer option\n isString(options.decimalPlacesOverride) && testPositiveInteger.test(options.decimalPlacesOverride)) // If string option\n ) {\n throwError('The maximum number of decimal places option \\'decimalPlacesOverride\\' is invalid ; it should be a positive integer, [' + options.decimalPlacesOverride + '] given.');\n }\n\n // Write a warning message in the console if the number of decimal in minimumValue/maximumValue is overridden by decimalPlacesOverride (and not if decimalPlacesOverride is equal to the number of decimal used in minimumValue/maximumValue)\n var vMinAndVMaxMaximumDecimalPlaces = maximumVMinAndVMaxDecimalLength(options.minimumValue, options.maximumValue);\n if (!isNull(options.decimalPlacesOverride) && vMinAndVMaxMaximumDecimalPlaces !== Number(options.decimalPlacesOverride)) {\n warning('Setting \\'decimalPlacesOverride\\' to [' + options.decimalPlacesOverride + '] will override the decimals declared in \\'minimumValue\\' [' + options.minimumValue + '] and \\'maximumValue\\' [' + options.maximumValue + '].', options.showWarnings);\n }\n\n if (!options.allowDecimalPadding && !isNull(options.decimalPlacesOverride)) {\n warning('Setting \\'allowDecimalPadding\\' to [false] will override the current \\'decimalPlacesOverride\\' setting [' + options.decimalPlacesOverride + '].', options.showWarnings);\n }\n\n if (!isNull(options.decimalPlacesShownOnFocus) && (!isString(options.decimalPlacesShownOnFocus) || !testPositiveInteger.test(options.decimalPlacesShownOnFocus))) {\n throwError('The number of expanded decimal places option \\'decimalPlacesShownOnFocus\\' is invalid ; it should be a positive integer, [' + options.decimalPlacesShownOnFocus + '] given.');\n }\n\n // Checks if the extended decimal places \"decimalPlacesShownOnFocus\" is greater than the normal decimal places \"decimalPlacesOverride\"\n if (!isNull(options.decimalPlacesShownOnFocus) && !isNull(options.decimalPlacesOverride) && Number(options.decimalPlacesOverride) > Number(options.decimalPlacesShownOnFocus)) {\n warning('The extended decimal places \\'decimalPlacesShownOnFocus\\' [' + options.decimalPlacesShownOnFocus + '] should be greater than the \\'decimalPlacesOverride\\' [' + options.decimalPlacesOverride + '] value. Currently, this will limit the ability of your client to manually change some of the decimal places. Do you really want to do that?', options.showWarnings);\n }\n\n if (!isNull(options.scaleDivisor) && !testPositiveFloatOrInteger.test(options.scaleDivisor)) {\n throwError('The scale divisor option \\'scaleDivisor\\' is invalid ; it should be a positive number, preferably an integer, [' + options.scaleDivisor + '] given.');\n }\n\n if (!isNull(options.scaleDecimalPlaces) && !testPositiveInteger.test(options.scaleDecimalPlaces)) {\n throwError('The scale number of decimals option \\'scaleDecimalPlaces\\' is invalid ; it should be a positive integer, [' + options.scaleDecimalPlaces + '] given.');\n }\n\n if (!isNull(options.scaleSymbol) && !isString(options.scaleSymbol)) {\n throwError('The scale symbol option \\'scaleSymbol\\' is invalid ; it should be a string, [' + options.scaleSymbol + '] given.');\n }\n\n if (!isTrueOrFalseString(options.saveValueToSessionStorage) && !isBoolean(options.saveValueToSessionStorage)) {\n throwError('The save to session storage option \\'saveValueToSessionStorage\\' is invalid ; it should be either \\'false\\' or \\'true\\', [' + options.saveValueToSessionStorage + '] given.');\n }\n\n if (!isInArray(options.onInvalidPaste, ['error', 'ignore', 'clamp', 'truncate', 'replace'])) {\n throwError('The paste behavior option \\'onInvalidPaste\\' is invalid ; it should either be \\'error\\', \\'ignore\\', \\'clamp\\', \\'truncate\\' or \\'replace\\' (cf. documentation), [' + options.onInvalidPaste + '] given.');\n }\n\n if (!isInArray(options.roundingMethod, ['S', 'A', 's', 'a', 'B', 'U', 'D', 'C', 'F', 'N05', 'CHF', 'U05', 'D05'])) {\n throwError('The rounding method option \\'roundingMethod\\' is invalid ; it should either be \\'S\\', \\'A\\', \\'s\\', \\'a\\', \\'B\\', \\'U\\', \\'D\\', \\'C\\', \\'F\\', \\'N05\\', \\'CHF\\', \\'U05\\' or \\'D05\\' (cf. documentation), [' + options.roundingMethod + '] given.');\n }\n\n if (!isTrueOrFalseString(options.allowDecimalPadding) && !isBoolean(options.allowDecimalPadding)) {\n throwError('The control decimal padding option \\'allowDecimalPadding\\' is invalid ; it should be either \\'false\\' or \\'true\\', [' + options.allowDecimalPadding + '] given.');\n }\n\n if (!isNull(options.negativeBracketsTypeOnBlur) && !isInArray(options.negativeBracketsTypeOnBlur, ['(,)', '[,]', '<,>', '{,}'])) {\n throwError('The brackets for negative values option \\'negativeBracketsTypeOnBlur\\' is invalid ; it should either be \\'(,)\\', \\'[,]\\', \\'<,>\\' or \\'{,}\\', [' + options.negativeBracketsTypeOnBlur + '] given.');\n }\n\n if (!isInArray(options.emptyInputBehavior, ['focus', 'press', 'always', 'zero'])) {\n throwError('The display on empty string option \\'emptyInputBehavior\\' is invalid ; it should either be \\'focus\\', \\'press\\', \\'always\\' or \\'zero\\', [' + options.emptyInputBehavior + '] given.');\n }\n\n if (!isInArray(options.leadingZero, ['allow', 'deny', 'keep'])) {\n throwError('The leading zero behavior option \\'leadingZero\\' is invalid ; it should either be \\'allow\\', \\'deny\\' or \\'keep\\', [' + options.leadingZero + '] given.');\n }\n\n if (!isTrueOrFalseString(options.formatOnPageLoad) && !isBoolean(options.formatOnPageLoad)) {\n throwError('The format on initialization option \\'formatOnPageLoad\\' is invalid ; it should be either \\'false\\' or \\'true\\', [' + options.formatOnPageLoad + '] given.');\n }\n\n if (!isTrueOrFalseString(options.selectNumberOnly) && !isBoolean(options.selectNumberOnly)) {\n throwError('The select number only option \\'selectNumberOnly\\' is invalid ; it should be either \\'false\\' or \\'true\\', [' + options.selectNumberOnly + '] given.');\n }\n\n if (!isNull(options.defaultValueOverride) && options.defaultValueOverride !== '' && !testFloatOrIntegerAndPossibleNegativeSign.test(options.defaultValueOverride)) {\n throwError('The unformatted default value option \\'defaultValueOverride\\' is invalid ; it should be a string that represents a positive or negative number, [' + options.defaultValueOverride + '] given.');\n }\n\n if (!isTrueOrFalseString(options.unformatOnSubmit) && !isBoolean(options.unformatOnSubmit)) {\n throwError('The remove formatting on submit option \\'unformatOnSubmit\\' is invalid ; it should be either \\'false\\' or \\'true\\', [' + options.unformatOnSubmit + '] given.');\n }\n\n if (!isNull(options.outputFormat) && !isInArray(options.outputFormat, ['string', 'number', '.', '-.', ',', '-,', '.-', ',-'])) {\n throwError('The custom locale format option \\'outputFormat\\' is invalid ; it should either be null, \\'string\\', \\'number\\', \\'.\\', \\'-.\\', \\',\\', \\'-,\\', \\'.-\\' or \\',-\\', [' + options.outputFormat + '] given.');\n }\n\n if (!isTrueOrFalseString(options.failOnUnknownOption) && !isBoolean(options.failOnUnknownOption)) {\n throwError('The debug option \\'failOnUnknownOption\\' is invalid ; it should be either \\'false\\' or \\'true\\', [' + options.failOnUnknownOption + '] given.');\n }\n };\n\n $.fn.autoValidate = validate;\n\n /**\n * Return TRUE is the settings/options are valid, FALSE otherwise.\n *\n * @param {object} options\n * @returns {boolean}\n */\n areSettingsValid = function areSettingsValid(options) {\n var isValid = true;\n try {\n validate(options);\n } catch (error) {\n isValid = false;\n }\n\n return isValid;\n };\n\n /**\n * Take an arabic number as a string and return a javascript number.\n * By default, this function does not try to convert the arabic decimal and thousand separator characters.\n * This returns `NaN` is the conversion is not possible.\n * Based on http://stackoverflow.com/a/17025392/2834898\n *\n * @param {string} arabicNumbers\n * @param {boolean} returnANumber If `true`, return a Number, otherwise return a String\n * @param {boolean} parseDecimalCharacter\n * @param {boolean} parseThousandSeparator\n * @returns {string|number|NaN}\n */\n function arabicToLatinNumbers(arabicNumbers) {\n var returnANumber = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;\n var parseDecimalCharacter = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;\n var parseThousandSeparator = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : false;\n\n var result = arabicNumbers.toString();\n if (result === '') {\n return arabicNumbers;\n }\n\n if (parseDecimalCharacter) {\n result = result.replace(/٫/, '.'); // Decimal character\n }\n\n if (parseThousandSeparator) {\n result = result.replace(/٬/g, ''); // Thousand separator\n }\n\n // Replace the numbers only\n result = result.replace(/[٠١٢٣٤٥٦٧٨٩]/g, function (d) {\n return d.charCodeAt(0) - 1632;\n }) // Arabic numbers\n .replace(/[۰۱۲۳۴۵۶۷۸۹]/g, function (d) {\n return d.charCodeAt(0) - 1776;\n }); // Persian numbers\n\n // `NaN` has precedence over the string `'NaN'`\n var resultAsNumber = Number(result);\n if (isNaN(resultAsNumber)) {\n return resultAsNumber;\n }\n\n if (returnANumber) {\n result = resultAsNumber;\n }\n\n return result;\n }\n\n /**\n * Create a custom event and immediately sent it from the given element.\n * By default, if no element is given, the event is thrown from `document`.\n *\n * @param {string} eventName\n * @param {Element} element\n * @param {object} detail\n */\n function triggerEvent(eventName) {\n var element = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : document;\n var detail = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;\n\n var event = void 0;\n if (window.CustomEvent) {\n event = new CustomEvent(eventName, { detail: detail, bubbles: false, cancelable: false }); // This is not supported by default by IE ; We use the polyfill for IE9 and later.\n } else {\n event = document.createEvent('CustomEvent');\n event.initCustomEvent(eventName, true, true, { detail: detail });\n }\n\n element.dispatchEvent(event);\n }\n\n /**\n * Polyfill from https://developer.mozilla.org/en-US/docs/Web/API/CustomEvent/CustomEvent for obsolete browsers (IE)\n */\n (function () {\n if (typeof window.CustomEvent === 'function') {\n return false;\n }\n\n function CustomEvent(event, params) {\n params = params || { bubbles: false, cancelable: false, detail: void 0 };\n var evt = document.createEvent('CustomEvent');\n evt.initCustomEvent(event, params.bubbles, params.cancelable, params.detail);\n return evt;\n }\n\n CustomEvent.prototype = window.Event.prototype;\n window.CustomEvent = CustomEvent;\n })();\n});\n\n/**\n * This exports the interface for the autoNumeric object\n */\nexports.default = {\n format: autoFormat,\n unFormat: autoUnFormat,\n getDefaultConfig: getDefaultConfig,\n getLanguages: getLanguages,\n validate: validate, // an.validate(options) : throws if necessary\n areSettingsValid: areSettingsValid };\n}.call(window));//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vLi9zcmMvYXV0b051bWVyaWMuanM/YTRlZSJdLCJuYW1lcyI6WyJhdXRvRm9ybWF0IiwiYXV0b1VuRm9ybWF0IiwiZ2V0RGVmYXVsdENvbmZpZyIsImdldExhbmd1YWdlcyIsInZhbGlkYXRlIiwiYXJlU2V0dGluZ3NWYWxpZCIsImFsbG93ZWRUYWdMaXN0IiwiZGVmYXVsdFNldHRpbmdzIiwiZGlnaXRHcm91cFNlcGFyYXRvciIsIm5vU2VwYXJhdG9yT25Gb2N1cyIsImRpZ2l0YWxHcm91cFNwYWNpbmciLCJkZWNpbWFsQ2hhcmFjdGVyIiwiZGVjaW1hbENoYXJhY3RlckFsdGVybmF0aXZlIiwiY3VycmVuY3lTeW1ib2wiLCJjdXJyZW5jeVN5bWJvbFBsYWNl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0MCxcbiAgICBJbnNlcnQ6ICAgICAgICAgNDUsXG4gICAgRGVsZXRlOiAgICAgICAgIDQ2LFxuICAgIG51bTA6ICAgICAgICAgICA0OCxcbiAgICBudW0xOiAgICAgICAgICAgNDksXG4gICAgbnVtMjogICAgICAgICAgIDUwLFxuICAgIG51bTM6ICAgICAgICAgICA1MSxcbiAgICBudW00OiAgICAgICAgICAgNTIsXG4gICAgbnVtNTogICAgICAgICAgIDUzLFxuICAgIG51bTY6ICAgICAgICAgICA1NCxcbiAgICBudW03OiAgICAgICAgICAgNTUsXG4gICAgbnVtODogICAgICAgICAgIDU2LFxuICAgIG51bTk6ICAgICAgICAgICA1NyxcbiAgICBhOiAgICAgICAgICAgICAgNjUsXG4gICAgYjogICAgICAgICAgICAgIDY2LFxuICAgIGM6ICAgICAgICAgICAgICA2NyxcbiAgICBkOiAgICAgICAgICAgICAgNjgsXG4gICAgZTogICAgICAgICAgICAgIDY5LFxuICAgIGY6ICAgICAgICAgICAgICA3MCxcbiAgICBnOiAgICAgICAgICAgICAgNzEsXG4gICAgaDogICAgICAgICAgICAgIDcyLFxuICAgIGk6ICAgICAgICAgICAgICA3MyxcbiAgICBqOiAgICAgICAgICAgICAgNzQsXG4gICAgazogICAgICAgICAgICAgIDc1LFxuICAgIGw6ICAgICAgICAgICAgICA3NixcbiAgICBtOiAgICAgICAgICAgICAgNzcsXG4gICAgbjogICAgICAgICAgICAgIDc4LFxuICAgIG86ICAgICAgICAgICAgICA3OSxcbiAgICBwOiAgICAgICAgICAgICAgODAsXG4gICAgcTogICAgICAgICAgICAgIDgxLFxuICAgIHI6ICAgICAgICAgICAgICA4MixcbiAgICBzOiAgICAgICAgICAgICAgODMsXG4gICAgdDogICAgICAgICAgICAgIDg0LFxuICAgIHU6ICAgICAgICAgICAgICA4NSxcbiAgICB2OiAgICAgICAgICAgICAgODYsXG4gICAgdzogICAgICAgICAgICAgIDg3LFxuICAgIHg6ICAgICAgICAgICAgICA4OCxcbiAgICB5OiAgICAgICAgICAgICAgODksXG4gICAgejogICAgICAgICAgICAgIDkwLFxuICAgIFdpbmRvd3M6ICAgICAgICA5MSxcbiAgICBSaWdodENsaWNrOiAgICAgOTMsXG4gICAgbnVtcGFkMDogICAgICAgIDk2LFxuICAgIG51bXBhZDE6ICAgICAgICA5NyxcbiAgICBudW1wYWQyOiAgICAgICAgOTgsXG4gICAgbnVtcGFkMzogICAgICAgIDk5LFxuICAgIG51bXBhZDQ6ICAgICAgICAxMDAsXG4gICAgbnVtcGFkNTogICAgICAgIDEwMSxcbiAgICBudW1wYWQ2OiAgICAgICAgMTAyLFxuICAgIG51bXBhZDc6ICAgICAgICAxMDMsXG4gICAgbnVtcGFkODogICAgICAgIDEwNCxcbiAgICBudW1wYWQ5OiAgICAgICAgMTA1LFxuICAgIE11bHRpcGx5TnVtcGFkOiAxMDYsXG4gICAgUGx1c051bXBhZDogICAgIDEwNyxcbiAgICBNaW51c051bXBhZDogICAgMTA5LFxuICAgIERvdE51bXBhZDogICAgICAxMTAsXG4gICAgU2xhc2hOdW1wYWQ6ICAgIDExMSxcbiAgICBGMTogICAgICAgICAgICAgMTEyLFxuICAgIEYyOiAgICAgICAgICAgICAxMTMsXG4gICAgRjM6ICAgICAgICAgICAgIDExNCxcbiAgICBGNDogICAgICAgICAgICAgMTE1LFxuICAgIEY1OiAgICAgICAgICAgICAxMTYsXG4gICAgRjY6ICAgICAgICAgICAgIDExNyxcbiAgICBGNzogICAgICAgICAgICAgMTE4LFxuICAgIEY4OiAgICAgICAgICAgICAxMTksXG4gICAgRjk6ICAgICAgICAgICAgIDEyMCxcbiAgICBGMTA6ICAgICAgICAgICAgMTIxLFxuICAgIEYxMTogICAgICAgICAgICAxMjIsXG4gICAgRjEyOiAgICAgICAgICAgIDEyMyxcbiAgICBOdW1Mb2NrOiAgICAgICAgMTQ0LFxuICAgIFNjcm9sbExvY2s6ICAgICAxNDUsXG4gICAgTXlDb21wdXRlcjogICAgIDE4MixcbiAgICBNeUNhbGN1bGF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iAgICAgICAgICAnRWplY3QnLFxuICAgIExvZ09mZjogICAgICAgICAnTG9nT2ZmJyxcbiAgICBQb3dlcjogICAgICAgICAgJ1Bvd2VyJyxcbiAgICBQb3dlck9mZjogICAgICAgJ1Bvd2VyT2ZmJyxcbiAgICBQcmludFNjcmVlbjogICAgJ1ByaW50U2NyZWVuJyxcbiAgICBIaWJlcm5hdGU6ICAgICAgJ0hpYmVybmF0ZScsIC8vICdVbmlkZW50aWZpZWQnIGZvciBGaXJlZm94IDw9MzdcbiAgICBTdGFuZGJ5OiAgICAgICAgJ1N0YW5kYnknLCAvLyAnVW5pZGVudGlmaWVkJyBmb3IgRmlyZWZveCA8PTM2LCBhbmQgSUU5XG4gICAgV2FrZVVwOiAgICAgICAgICdXYWtlVXAnLFxuXG4gICAgLy8gSU1FIGFuZCBjb21wb3NpdGlvbiBrZXlzXG4gICAgQ29tcG9zZTogICAgICAgICdDb21wb3NlJyxcbiAgICBEZWFkOiAgICAgICAgICAgJ0RlYWQnLFxuXG4gICAgLy8gRnVuY3Rpb24ga2V5c1xuICAgIEYxOiAgICAgICAgICAgICAnRjEnLFxuICAgIEYyOiAgICAgICAgICAgICAnRjInLFxuICAgIEYzOiAgICAgICAgICAgICAnRjMnLFxuICAgIEY0OiAgICAgICAgICAgICAnRjQnLFxuICAgIEY1OiAgICAgICAgICAgICAnRjUnLFxuICAgIEY2OiAgICAgICAgICAgICAnRjYnLFxuICAgIEY3OiAgICAgICAgICAgICAnRjcnLFxuICAgIEY4OiAgICAgICAgICAgICAnRjgnLFxuICAgIEY5OiAgICAgICAgICAgICAnRjknLFxuICAgIEYxMDogICAgICAgICAgICAnRjEwJyxcbiAgICBGMTE6ICAgICAgICAgICAgJ0YxMScsXG4gICAgRjEyOiAgICAgICAgICAgICdGMTInLFxuXG4gICAgLy8gRG9jdW1lbnQga2V5c1xuICAgIFByaW50OiAgICAgICAgICAnUHJpbnQnLFxuXG4gICAgLy8gJ05vcm1hbCcga2V5c1xuICAgIG51bTA6ICAgICAgICAgICAnMCcsXG4gICAgbnVtMTogICAgICAgICAgICcxJyxcbiAgICBudW0yOiAgICAgICAgICAgJzInLFxuICAgIG51bTM6ICAgICAgICAgICAnMycsXG4gICAgbnVtNDogICAgICAgICAgICc0JyxcbiAgICBudW01OiAgICAgICAgICAgJzUnLFxuICAgIG51bTY6ICAgICAgICAgICAnNicsXG4gICAgbnVtNzogICAgICAgICAgICc3JyxcbiAgICBudW04OiAgICAgICAgICAgJzgnLFxuICAgIG51bTk6ICAgICAgICAgICAnOScsXG4gICAgbnVtcGFkMDogICAgICAgICcwJyxcbiAgICBudW1wYWQxOiAgICAgICAgJzEnLFxuICAgIG51bXBhZDI6ICAgICAgICAnMicsXG4gICAgbnVtcGFkMzogICAgICAgICczJyxcbiAgICBudW1wYWQ0OiAgICAgICAgJzQnLFxuICAgIG51bXBhZDU6ICAgICAgICAnNScsXG4gICAgbnVtcGFkNjogICAgICAgICc2JyxcbiAgICBudW1wYWQ3OiAgICAgICAgJzcnLFxuICAgIG51bXBhZDg6ICAgICAgICAnOCcsXG4gICAgbnVtcGFkOTogICAgICAgICc5JyxcbiAgICBhOiAgICAgICAgICAgICAgJ2EnLFxuICAgIGI6ICAgICAgICAgICAgICAnYicsXG4gICAgYzogICAgICAgICAgICAgICdjJyxcbiAgICBkOiAgICAgICAgICAgICAgJ2QnLFxuICAgIGU6ICAgICAgICAgICAgICAnZScsXG4gICAgZjogICAgICAgICAgICAgICdmJyxcbiAgICBnOiAgICAgICAgICAgICAgJ2cnLFxuICAgIGg6ICAgICAgICAgICAgICAnaCcsXG4gICAgaTogICAgICAgICAgICAgICdpJyxcbiAgICBqOiAgICAgICAgICAgICAgJ2onLFxuICAgIGs6ICAgICAgICAgICAgICAnaycsXG4gICAgbDogICAgICAgICAgICAgICdsJyxcbiAgICBtOiAgICAgICAgICAgICAgJ20nLFxuICAgIG46ICAgICAgICAgICAgICAnbicsXG4gICAgbzogICAgICAgICAgICAgICdvJyxcbiAgICBwOiAgICAgICAgICAgICAgJ3AnLFxuICAgIHE6ICAgICAgICAgICAgICAncScsXG4gICAgcjogICAgICAgICAgICAgICdyJyxcbiAgICBzOiAgICAgICAgICAgICAgJ3MnLFxuICAgIHQ6ICAgICAgICAgICAgICAndCcsXG4gICAgdTogICAgICAgICAgICAgICd1JyxcbiAgICB2OiAgICAgICAgICAgICAgJ3YnLFxuICAgIHc6ICAgICAgICAgICAgICAndycsXG4gICAgeDogICAgICAgICAgICAgICd4JyxcbiAgICB5OiAgICAgICAgICAgICAgJ3knLFxuICAgIHo6ICAgICAgICAgICAgICAneicsXG4gICAgTXVsdGlwbHlOdW1wYWQ6ICcqJyxcbiAgICBQbHVzTnVtcGFkOiAgICAgJysnLFxuICAgIE1pbnVzTnVtcGFkOiAgICAnLScsXG4gICAgRG90TnVtcGFkOiAgICAgICcuJyxcbiAgICBTbGFzaE51bXBhZDogICAgJy8nLFxuICAgIFNlbWljb2xvbjogICAgICAnOycsXG4gICAgRXF1YWw6ICAgICAgICAgICc9JyxcbiAgICBDb21tYTogICAgICAgICAgJywnLFxuICAgIEh5cGhlbjogICAgICAgICAnLScsXG4gICAgTWludXM6ICAgICAgICAgICctJyxcbiAgICBQbHVzOiAgICAgICAgICAgJysnLFxuICAgIERvdDogICAgICAgICAgICAnLicsXG4gICAgU2xhc2g6ICAgICAgICAgICcvJyxcbiAgICBCYWNrcXVvdGU6ICAgICAgJ2AnLFxuICAgIExlZnRCcmFja2V0OiAgICAnWycsXG4gICAgUmlnaHRCcmFja2V0OiAgICddJyxcbiAgICBCYWNrc2xhc2g6ICAgICAgJ1xcXFwnLFxuICAgIFF1b3RlOiAgICAgICAgICBcIidcIixcbiAgICBOdW1wYWREb3Q6ICAgICAgJy4nLFxuICAgIE51bXBhZERvdEFsdDogICAnLCcsIC8vIE1vZGVybiBicm93c2VycyBhdXRvbWF0aWNhbGx5IGFkYXB0IHRoZSBjaGFyYWN0ZXIgc2VudCBieSB0aGlzIGtleSB0byB0aGUgZGVjaW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ICAgICAgIDogJywnLFxuICAgICAgICBkZWNpbWFsQ2hhcmFjdGVyQWx0ZXJuYXRpdmU6ICcuJyxcbiAgICAgICAgY3VycmVuY3lTeW1ib2wgICAgICAgICAgICAgOiAnXFx1MjAyZuKCrCcsXG4gICAgICAgIGN1cnJlbmN5U3ltYm9sUGxhY2VtZW50ICAgIDogJ3MnLFxuICAgICAgICBzZWxlY3ROdW1iZXJPbmx5ICAgICAgICAgICA6IGRlZmF1bHRTZWxlY3ROdW1iZXJPbmx5LFxuICAgICAgICByb3VuZGluZ01ldGhvZCAgICAgICAgICAgICA6IGRlZmF1bHRSb3VuZGluZ01ldGhvZCxcbiAgICAgICAgbGVhZGluZ1plcm8gICAgICAgICAgICAgICAgOiBkZWZhdWx0TGVhZGluZ1plcm8sXG4gICAgICAgIG1pbmltdW1WYWx1ZSAgICAgICAgICAgICAgIDogZGVmYXVsdE1pbmltdW1WYWx1ZSxcbiAgICAgICAgbWF4aW11bVZhbHVlICAgICAgICAgICAgICAgOiBkZWZhdWx0TWF4aW11bVZhbHVlLFxuICAgIH0sXG4gICAgTm9ydGhBbWVyaWNhbjoge1xuICAgICAgICBkaWdpdEdyb3VwU2VwYXJhdG9yICAgIDogJywnLFxuICAgICAgICBkZWNpbWFsQ2hhcmFjdGVyICAgICAgIDogJy4nLFxuICAgICAgICBjdXJyZW5jeVN5bWJvbCAgICAgICAgIDogJyQnLFxuICAgICAgICBjdXJyZW5jeVN5bWJvbFBsYWNlbWVudDogJ3AnLFxuICAgICAgICBzZWxlY3ROdW1iZXJPbmx5ICAgICAgIDogZGVmYXVsdFNlbGVjdE51bWJlck9ubHksXG4gICAgICAgIHJvdW5kaW5nTWV0aG9kICAgICAgICAgOiBkZWZhdWx0Um91bmRpbmdNZXRob2QsXG4gICAgICAgIGxlYWRpbmdaZXJvICAgICAgICAgICAgOiBkZWZhdWx0TGVhZGluZ1plcm8sXG4gICAgICAgIG1pbmltdW1WYWx1ZSAgICAgICAgICAgOiBkZWZhdWx0TWluaW11bVZhbHVlLFxuICAgICAgICBtYXhpbXVtVmFsdWUgICAgICAgICAgIDogZGVmYXVsdE1heGltdW1WYWx1ZSxcbiAgICB9LFxuICAgIEJyaXRpc2g6IHtcbiAgICAgICAgZGlnaXRHcm91cFNlcGFyYXRvciAgICA6ICcsJyxcbiAgICAgICAgZGVjaW1hbENoYXJhY3RlciAgICAgICA6ICcuJyxcbiAgICAgICAgY3VycmVuY3lTeW1ib2wgICAgICAgICA6ICfCoycsXG4gICAgICAgIGN1cnJlbmN5U3ltYm9sUGxhY2VtZW50OiAncCcsXG4gICAgICAgIHNlbGVjdE51bWJlck9ubHkgICAgICAgOiBkZWZhdWx0U2VsZWN0TnVtYmVyT25seSxcbiAgICAgICAgcm91bmRpbmdNZXRob2QgICAgICAgICA6IGRlZmF1bHRSb3VuZGluZ01ldGhvZCxcbiAgICAgICAgbGVhZGluZ1plcm8gICAgICAgICAgICA6IGRlZmF1bHRMZWFkaW5nWmVybyxcbiAgICAgICAgbWluaW11bVZhbHVlICAgICAgICAgICA6IGRlZmF1bHRNaW5pbXVtVmFsdWUsXG4gICAgICAgIG1heGltdW1WYWx1ZSAgICAgICAgICAgOiBkZWZhdWx0TWF4aW11bVZhbHVlLFxuICAgIH0sXG4gICAgU3dpc3M6IHsgLy8gU3Vpc3NlXG4gICAgICAgIGRpZ2l0R3JvdXBTZXBhcmF0b3IgICAgOiBgJ2AsXG4gICAgICAgIGRlY2ltYWxDaGFyYWN0ZXIgICAgICAgOiAnLicsXG4gICAgICAgIGN1cnJlbmN5U3ltYm9sICAgICAgICAgOiAnXFx1MjAyZkNIRicsXG4gICAgICAgIGN1cnJlbmN5U3ltYm9sUGxhY2VtZW50OiAncycsXG4gICAgICAgIHNlbGVjdE51bWJlck9ubHkgICAgICAgOiBkZWZhdWx0U2VsZWN0TnVtYmVyT25seSxcbiAgICAgICAgcm91bmRpbmdNZXRob2QgICAgICAgICA6IGRlZmF1bHRSb3VuZGluZ01ldGhvZCxcbiAgIC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VudC5rZXlDb2RlOmV2ZW50LndoaWNoO1xuICAgIH1cblxuICAgIC8qKlxuICAgICAqIFJldHVybiB0aGUgY2hhcmFjdGVyIGZyb20gdGhlIGV2ZW50IGtleSBjb2RlLlxuICAgICAqIEBleGFtcGxlIGNoYXJhY3Rlcig1MCkgPT4gJzInXG4gICAgICpcbiAgICAgKiBAcGFyYW0ge0V2ZW50fSBldmVudFxuICAgICAqIEByZXR1cm5zIHtzdHJpbmd9XG4gICAgICovXG4gICAgZnVuY3Rpb24gY2hhcmFjdGVyKGV2ZW50KSB7XG4gICAgICAgIGlmICh0eXBlb2YgZXZlbnQua2V5ID09PSAndW5kZWZpbmVkJyB8fCBldmVudC5rZXkgPT09ICdVbmlkZW50aWZpZWQnKSB7XG4gICAgICAgICAgICByZXR1cm4gU3RyaW5nLmZyb21DaGFyQ29kZSh0aGlzLmtleUNvZGVOdW1iZXIoZXZlbnQpKTtcbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIC8vIFNwZWNpYWwgY2FzZSBmb3Igb2Jzb2xldGUgYnJvd3NlcnMgbGlrZSBJRSB0aGF0IHJldHVybiB0aGUgb2xkIG5hbWVzXG4gICAgICAgICAgICBsZXQgcmVzdWx0O1xuICAgICAgICAgICAgc3dpdGNoIChldmVudC5rZXkpIHtcbiAgICAgICAgICAgICAgICBjYXNlICdEZWNpbWFsJzpcbiAgICAgICAgICAgICAgICAgICAgcmVzdWx0ID0ga2V5TmFtZS5OdW1wYWREb3Q7XG4gICAgICAgICAgICAgICAgICAgIGJyZWFrO1xuICAgICAgICAgICAgICAgIGNhc2UgJ011bHRpcGx5JzpcbiAgICAgICAgICAgICAgICAgICAgcmVzdWx0ID0ga2V5TmFtZS5OdW1wYWRNdWx0aXBseTtcbiAgICAgICAgICAgICAgICAgICAgYnJlYWs7XG4gICAgICAgICAgICAgICAgY2FzZSAnQWRkJzpcbiAgICAgICAgICAgICAgICAgICAgcmVzdWx0ID0ga2V5TmFtZS5OdW1wYWRQbHVzO1xuICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICBjYXNlICdTdWJ0cmFjdCc6XG4gICAgICAgICAgICAgICAgICAgIHJlc3VsdCA9IGtleU5hbWUuTnVtcGFkTWludXM7XG4gICAgICAgICAgICAgICAgICAgIGJyZWFrO1xuICAgICAgICAgICAgICAgIGNhc2UgJ0RpdmlkZSc6XG4gICAgICAgICAgICAgICAgICAgIHJlc3VsdCA9IGtleU5hbWUuTnVtcGFkU2xhc2g7XG4gICAgICAgICAgICAgICAgICAgIGJyZWFrO1xuICAgICAgICAgICAgICAgIGNhc2UgJ0RlbCc6XG4gICAgICAgICAgICAgICAgICAgIC8vIFNwZWNpYWwgd29ya2Fyb3VuZCBmb3IgdGhlIG9ic29sZXRlIGJyb3dzZXIgSUUxMSB3aGljaCBvdXRwdXQgYSAnRGVsZXRlJyBrZXkgd2hlbiB1c2luZyB0aGUgbnVtcGFkICdkb3QnIG9uZSEgVGhpcyBmaXhlcyBpc3N1ZSAjNDAxIC8vRklYTUUgw6AgdGVybWluZXJcbiAgICAgICAgICAgICAgICAgICAgcmVzdWx0ID0ga2V5TmFtZS5Eb3Q7IC8vIGFzIG9mIHZlcnNpb24gMi4wLjggdGhlIGNoYXJhY3RlcigpIGZ1bmN0aW9uIGlzIG9ubHkgY2FsbGVkIG9uIGtleXByZXNzIGV2ZW50LiBUaGUgJ0RlbCcgZG9lcyBub3QgdGhyb3cgdGhlIGtleXByZXNzIGV2ZW50LlxuICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICBkZWZhdWx0OlxuICAgICAgICAgICAgICAgICAgICByZXN1bHQgPSBldmVudC5rZXk7XG4gICAgICAgICAgICB9XG5cbiAgICAgICAgICAgIHJldHVybiByZXN1bHQ7XG4gICAgICAgIH1cbiAgICB9XG5cbiAgICAvKipcbiAgICAgKiBSZXR1cm4gVFJVRSBpZiB0aGUgZ2l2ZW4gdmFsdWUgKGEgbnVtYmVyI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XR1cm4gcztcbiAgICB9XG5cbiAgICAvKipcbiAgICAgKiBDb252ZXJ0cyB0aGUgSVNPIG51bWVyaWMgc3RyaW5nIHRvIHRoZSBsb2NhbGUgZGVjaW1hbCBhbmQgbWludXMgc2lnbiBwbGFjZW1lbnQuXG4gICAgICogU2VlIHRoZSBcIm91dHB1dEZvcm1hdFwiIG9wdGlvbiBkZWZpbml0aW9uIGZvciBtb3JlIGRldGFpbHMuXG4gICAgICpcbiAgICAgKiBAcGFyYW0ge3N0cmluZ3xudWxsfSB2YWx1ZVxuICAgICAqIEBwYXJhbSB7c3RyaW5nfSBsb2NhbGVcbiAgICAgKiBAcmV0dXJucyB7Kn1cbiAgICAgKi9cbiAgICBmdW5jdGlvbiB0b0xvY2FsZSh2YWx1ZSwgbG9jYWxlKSB7XG4gICAgICAgIGlmIChpc051bGwobG9jYWxlKSB8fCBsb2NhbGUgPT09ICdzdHJpbmcnKSB7XG4gICAgICAgICAgICByZXR1cm4gdmFsdWU7XG4gICAgICAgIH1cblxuICAgICAgICBsZXQgcmVzdWx0O1xuICAgICAgICBzd2l0Y2ggKGxvY2FsZSkge1xuICAgICAgICAgICAgY2FzZSAnbnVtYmVyJzpcbiAgICAgICAgICAgICAgICByZXN1bHQgPSBOdW1iZXIodmFsdWUpO1xuICAgICAgICAgICAgICAgIGJyZWFrO1xuICAgICAgICAgICAgY2FzZSAnLi0nOlxuICAgICAgICAgICAgICAgIHJlc3VsdCA9IGlzTmVnYXRpdmUodmFsdWUpID8gdmFsdWUucmVwbGFjZSgnLScsICcnKSArICctJyA6IHZhbHVlO1xuICAgICAgICAgICAgICAgIGJyZWFrO1xuICAgICAgICAgICAgY2FzZSAnLCc6XG4gICAgICAgICAgICBjYXNlICctLCc6XG4gICAgICAgICAgICAgICAgcmVzdWx0ID0gdmFsdWUucmVwbGFjZSgnLicsICcsJyk7XG4gICAgICAgICAgICAgICAgYnJlYWs7XG4gICAgICAgICAgICBjYXNlICcsLSc6XG4gICAgICAgICAgIC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AgICAgICAgICAgICAgICAgICAgY2FzZSAnbCc6XG4gICAgICAgICAgICAgICAgICAgICAgICBpbnB1dFZhbHVlID0gYCR7c2V0dGluZ3MubmVnYXRpdmVTaWduQ2hhcmFjdGVyfSR7c2V0dGluZ3MuY3VycmVuY3lTeW1ib2x9JHtpbnB1dFZhbHVlfWA7XG4gICAgICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICAgICAgY2FzZSAncic6XG4gICAgICAgICAgICAgICAgICAgICAgICBpbnB1dFZhbHVlID0gYCR7c2V0dGluZ3MuY3VycmVuY3lTeW1ib2x9JHtzZXR0aW5ncy5uZWdhdGl2ZVNpZ25DaGFyYWN0ZXJ9JHtpbnB1dFZhbHVlfWA7XG4gICAgICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICAgICAgY2FzZSAncyc6XG4gICAgICAgICAgICAgICAgICAgICAgICBpbnB1dFZhbHVlID0gYCR7c2V0dGluZ3MuY3VycmVuY3lTeW1ib2x9JHtpbnB1dFZhbHVlfSR7c2V0dGluZ3MubmVnYXRpdmVTaWduQ2hhcmFjdGVyfWA7XG4gICAgICAgICAgICAgICAgICAgICAgICBzZXR0aW5ncy50cmFpbGluZ05lZ2F0aXZlID0gdHJ1ZTtcbiAgICAgICAgICAgICAgICAgICAgICAgIGJyZWFrO1xuICAgICAgICAgICAgICAgICAgICBkZWZhdWx0IDpcbiAgICAgICAgICAgICAgICAgICAgLy9cbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9IGVsc2UgaWYgKHNldHRpbmdzLnNob3dQb3NpdGl2ZVNpZ24gJiYgIWlzWmVybykge1xuICAgICAgICAgICAgICAgIHN3aXRjaCAoc2V0dGluZ3MubmVnYXRpdmVQb3NpdGl2ZVNpZ25QbGFjZW1lbnQpIHtcbiAgICAgICAgICAgICAgICAgICAgY2FzZSAnbCc6XG4gICAgICAgICAgICAgICAgICAgICAgICBpbnB1dFZhbHVlID0gYCR7c2V0dGluZ3MucG9zaXRpdmVTaWduQ2hhcmFjdGVyfSR7c2V0dGluZ3MuY3VycmVuY3lTeW1ib2x9JHtpbnB1dFZhbHVlfWA7XG4gICAgICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICAgICAgY2FzZSAncic6XG4gICAgICAgICAgICAgICAgICAgICAgICBpbnB1dFZhbHVlID0gYCR7c2V0dGluZ3MuY3VycmVuY3lTeW1ib2x9JHtzZXR0aW5ncy5wb3NpdGl2ZVNpZ25DaGFyYWN0ZXJ9JHtpbnB1dFZhbHVlfWA7XG4gICAgICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICAgICAgY2FzZSAncyc6XG4gICAgICAgICAgICAgICAgICAgICAgICBpbnB1dFZhbHVlID0gYCR7c2V0dGluZ3MuY3VycmVuY3lTeW1ib2x9JHtpbnB1dFZhbHVlfSR7c2V0dGluZ3MucG9zaXRpdmVTaWduQ2hhcmFjdGVyfWA7XG4gICAgICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICAgICAgZGVmYXVsdCA6XG4gICAgICAgICAgICAgICAgICAgIC8vXG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgICAgICBpbnB1dFZhbHVlID0gc2V0dGluZ3MuY3VycmVuY3lTeW1ib2wgKyBpbnB1dFZhbHVlO1xuICAgICAgICAgICAgfVxuICAgICAgICB9XG5cbiAgICAgICAgaWYgKHNldHRpbmdzLmN1cnJlbmN5U3ltYm9sUGxhY2VtZW50ID09PSAncycpIHtcbiAgICAgICAgICAgIGlmIChpc1ZhbHVlTmVnYXRpdmUpIHtcbiAgICAgICAgICAgICAgICBzd2l0Y2ggKHNldHRpbmdzLm5lZ2F0aXZlUG9zaXRpdmVTaWduUGxhY2VtZW50KSB7XG4gICAgICAgICAgICAgICAgICAgIGNhc2UgJ3InOlxuICAgICAgICAgICAgICAgICAgICAgICAgaW5wdXRWYWx1ZSA9IGAke2lucHV0VmFsdWV9JHtzZXR0aW5ncy5jdXJyZW5jeVN5bWJvbH0ke3NldHRpbmdzLm5lZ2F0aXZlU2lnbkNoYXJhY3Rlcn1gO1xuICAgICAgICAgICAgICAgICAgICAgICAgc2V0dGluZ3MudHJhaWxpbmdOZWdhdGl2ZSA9IHRydWU7XG4gICAgICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICAgICAgY2FzZSAnbCc6XG4gICAgICAgICAgICAgICAgICAgICAgICBpbnB1dFZhbHVlID0gYCR7aW5wdXRWYWx1ZX0ke3NldHRpbmdzLm5lZ2F0aXZlU2lnbkNoYXJhY3Rlcn0ke3NldHRpbmdzLmN1cnJlbmN5U3ltYm9sfWA7XG4gICAgICAgICAgICAgICAgICAgICAgICBzZXR0aW5ncy50cmFpbGluZ05lZ2F0aXZlID0gdHJ1ZTtcbiAgICAgICAgICAgICAgICAgICAgICAgIGJyZWFrO1xuICAgICAgICAgICAgICAgICAgICBjYXNlICdwJzpcbiAgICAgICAgICAgICAgICAgICAgICAgIGlucHV0VmFsdWUgPSBgJHtzZXR0aW5ncy5uZWdhdGl2ZVNpZ25DaGFyYWN0ZXJ9JHtpbnB1dFZhbHVlfSR7c2V0dGluZ3MuY3VycmVuY3lTeW1ib2x9YDtcbiAgICAgICAgICAgICAgICAgICAgICAgIGJyZWFrO1xuICAgICAgICAgICAgICAgICAgICBkZWZhdWx0IDpcbiAgICAgICAgICAgICAgICAgICAgLy9cbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9IGVsc2UgaWYgKHNldHRpbmdzLnNob3dQb3NpdGl2ZVNpZ24gJiYgIWlzWmVybykge1xuICAgICAgICAgICAgICAgIHN3aXRjaCAoc2V0dGluZ3MubmVnYXRpdmVQb3NpdGl2ZVNpZ25QbGFjZW1lbnQpIHtcbiAgICAgICAgICAgICAgICAgICAgY2FzZSAncic6XG4gICAgICAgICAgICAgICAgICAgICAgICB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IDIwKS50b1N0cmluZygpO1xuICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICBkZWZhdWx0IDpcbiAgICAgICAgICAgICAgICAgICAgaW5wdXRWYWx1ZSA9IChNYXRoLmZsb29yKGlucHV0VmFsdWUgKiAyMCkgLyAyMCkudG9TdHJpbmcoKTtcbiAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgbGV0IHJlc3VsdDtcbiAgICAgICAgICAgIGlmICghY29udGFpbnMoaW5wdXRWYWx1ZSwgJy4nKSkge1xuICAgICAgICAgICAgICAgIHJlc3VsdCA9IGlucHV0VmFsdWUgKyAnLjAwJztcbiAgICAgICAgICAgIH0gZWxzZSBpZiAoaW5wdXRWYWx1ZS5sZW5ndGggLSBpbnB1dFZhbHVlLmluZGV4T2YoJy4nKSA8IDMpIHtcbiAgICAgICAgICAgICAgICByZXN1bHQgPSBpbnB1dFZhbHVlICsgJzAnO1xuICAgICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgICAgICByZXN1bHQgPSBpbnB1dFZhbHVlO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgcmV0dXJuIHJlc3VsdDtcbiAgICAgICAgfVxuXG4gICAgICAgIGxldCBpdlJvdW5kZWQgPSAnJztcbiAgICAgICAgbGV0IGkgPSAwO1xuICAgICAgICBsZXQgblNpZ24gPSAnJztcbiAgICAgICAgbGV0IHRlbXBvcmFyeURlY2ltYWxQbGFjZXNPdmVycmlkZTtcblxuICAgICAgICAvLyBzZXRzIHRoZSB0cnVuY2F0ZSB6ZXJvIG1ldGhvZFxuICAgICAgICBpZiAoc2V0dGluZ3MuYWxsb3dEZWNpbWFsUGFkZGluZykge1xuICAgICAgICAgICAgdGVtcG9yYXJ5RGVjaW1hbFBsYWNlc092ZXJyaWRlID0gc2V0dGluZ3MuZGVjaW1hbFBsYWNlc092ZXJyaWRlO1xuICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgdGVtcG9yYXJ5RGVjaW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mIHNldHRpbmdzLnJvdW5kaW5nTWV0aG9kID09PSAnVScpKSB7ICAgICAgICAgICAgICAgICAgLy8gUm91bmQgdXAgYXdheSBmcm9tIHplcm9cbiAgICAgICAgICAgIC8vIFJvdW5kIHVwIHRoZSBsYXN0IGRpZ2l0IGlmIHJlcXVpcmVkLCBhbmQgY29udGludWUgdW50aWwgbm8gbW9yZSA5J3MgYXJlIGZvdW5kXG4gICAgICAgICAgICBmb3IgKGkgPSAoaXZBcnJheS5sZW5ndGggLSAxKTsgaSA+PSAwOyBpIC09IDEpIHtcbiAgICAgICAgICAgICAgICBpZiAoaXZBcnJheVtpXSAhPT0gJy4nKSB7XG4gICAgICAgICAgICAgICAgICAgIGl2QXJyYXlbaV0gPSAraXZBcnJheVtpXSArIDE7XG4gICAgICAgICAgICAgICAgICAgIGlmIChpdkFycmF5W2ldIDwgMTApIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIGJyZWFrO1xuICAgICAgICAgICAgICAgICAgICB9XG5cbiAgICAgICAgICAgICAgICAgICAgaWYgKGkgPiAwKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBpdkFycmF5W2ldID0gJzAnO1xuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgfVxuICAgICAgICB9XG5cbiAgICAgICAgLy8gUmVjb25zdHJ1Y3QgdGhlIHN0cmluZywgY29udmVydGluZyBhbnkgMTAncyB0byAwJ3NcbiAgICAgICAgaXZBcnJheSA9IGl2QXJyYXkuc2xpY2UoMCwgckxlbmd0aCArIDEpO1xuXG4gICAgICAgIC8vIFJldHVybiB0aGUgcm91bmRlZCB2YWx1ZVxuICAgICAgICBpdlJvdW5kZWQgPSB0cnVuY2F0ZVplcm9zKGl2QXJyYXkuam9pbignJyksIHRlbXBvcmFyeURlY2ltYWxQbGFjZXNPdmVycmlkZSk7XG5cbiAgICAgICAgcmV0dXJuIChOdW1iZXIoaXZSb3VuZGVkKSA9PT0gMCkgPyB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gICAgIGxldCBlO1xuICAgICAgICBsZXQgaTtcbiAgICAgICAgbGV0IG5MO1xuICAgICAgICBsZXQgajtcblxuICAgICAgICAvLyBNaW51cyB6ZXJvP1xuICAgICAgICBpZiAobiA9PT0gMCAmJiAxIC8gbiA8IDApIHtcbiAgICAgICAgICAgIG4gPSAnLTAnO1xuICAgICAgICB9XG5cbiAgICAgICAgLy8gRGV0ZXJtaW5lIHNpZ24uIDEgcG9zaXRpdmUsIC0xIG5lZ2F0aXZlXG4gICAgICAgIG4gPSBuLnRvU3RyaW5nKCk7XG4gICAgICAgIGlmIChpc05lZ2F0aXZlU3RyaWN0KG4pKSB7XG4gICAgICAgICAgICBuID0gbi5zbGljZSgxKTtcbiAgICAgICAgICAgIHgucyA9IC0xO1xuICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgeC5zID0gMTtcbiAgICAgICAgfVxuXG4gICAgICAgIC8vIERlY2ltYWwgcG9pbnQ/XG4gICAgICAgIGUgPSBuLmluZGV4T2YoJy4nKTtcbiAgICAgICAgaWYgKGUgPiAtMSkge1xuICAgICAgICAgICAgbiA9IG4ucmVwbGFjZSgnLicsICcnKTtcbiAgICAgICAgfVxuXG4gICAgICAgIC8vIGxlbmd0aCBvZiBzdHJpbmcgaWYgbm8gZGVjaW1hbCBjaGFyYWN0ZXJcbiAgICAgICAgaWYgKGUgPCAwKSB7XG4gICAgICAgICAgICAvLyBJbnRlZ2VyXG4gICAgICAgICAgICBlID0gbi5sZW5ndGg7XG4gICAgICAgIH1cblxuICAgICAgICAvLyBEZXRlcm1pbmUgbGVhZGluZyB6ZXJvc1xuICAgICAgICBpID0gKG4uc2VhcmNoKC9bMS05XS9pKSA9PT0gLTEpID8gbi5sZW5ndGggOiBuLnNlYXJjaCgvWzEtOV0vaSk7XG4gICAgICAgIG5MID0gbi5sZW5ndGg7XG4gICAgICAgIGlmIChpID09PSBuTCkge1xuICAgICAgICAgICAgLy8gWmVyb1xuICAgICAgICAgICAgeC5lID0gMDtcbiAgICAgICAgICAgIHguYyA9IFswXTtcbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgIC8vIERldGVybWluZSB0cmFpbGluZyB6ZXJvc1xuICAgICAgICAgICAgZm9yIChqID0gbkwgLSAxOyBuLmNoYXJBdChqKSA9PT0gJzAnOyBqIC09IDEpIHtcbiAgICAgICAgICAgICAgICBuTCAtPSAxO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgbkwgLT0gMTtcblxuICAgICAgICAgICAgLy8gRGVjaW1hbCBsb2NhdGlvblxuICAgICAgICAgICAgeC5lID0gZSAtIGkgLSAxO1xuICAgICAgICAgICAgeC5jID0gW107XG5cbiAgICAgICAgICAgIC8vIENvbnZlcnQgc3RyaW5nIHRvIGFycmF5IG9mIGRpZ2l0cyB3aXRob3V0IGxlYWRpbmcvdHJhaWxpbmcgemVyb3NcbiAgICAgICAgICAgIGZvciAoZSA9IDA7IGkgPD0gbkw7IGkgKz0gMSkge1xuICAgICAgICAgICAgICAgIHguY1tlXSA9ICtuLmNoYXJBdChpKTtcbiAgICAgICAgICAgICAgICBlICs9IDE7XG4gICAgICAgICAgICB9XG4gICAgICAgIH1cblxuICAgICAgICByZXR1cm4geDtcbiAgICB9XG5cbiAgICAvKipcbiAgICAgKiBGdW5jdGlvbiB0byB0ZXN0IGlmIHRoZSBpbnB1dCB2YWx1ZSBmYWxscyB3aXRoIHRoZSBNaW4gLyBNYXggc2V0dGluZ3MuXG4gICAgICogVGhpcyB1c2VzIHRoZSBwYXJzZWQgc3RyaW5ncyBmb3IgdGhlIGFib3ZlIHBhcnNlU3RyIGZ1bmN0aW9uLlxuICAgICAqXG4gICAgICogVGhpcyBmdW5jdGlvbiBpcyBhZGFwdGVkIGZyb20gQmlnLmpzIGh0dHBzOi8vZ2l0aHViLmNvbS9NaWtlTWNsL2JpZy5qcy8uIE1hbnkgdGhhbmtzIHRvIE1pa2UuXG4gICAgICpcbiAgICAgKiBAcGFyYW0ge29iamVjdH0geSBCaWcgbnVtYmVyIGluc3RhbmNlXG4gICAgICogQHBhcmFtIHtvYmplY3R9IHggQmlnIG51bWJlciBpbnN0YW5jZVxuICAgICAqIEByZXR1cm5zIHsqfVxuICAgICAqL1xuICAgIGZ1bmN0aW9uIHRlc3RNaW5NYXgoeSwgeCkge1xuICAgICAgICBjb25zdCB4YyA9IHguYztcbiAgICAgICAgY29uc3QgeWMgPSB5LmM7XG4gICAgICAgIGxldCBpID0geC5zO1xuICAgICAgICBsZXQgaiA9IHkucztcbiAgICAgICAgbGV0IGsgPSB4LmU7XG4gICAgICAgIGxldCBsID0geS5lO1xuXG4gICAgICAgIC8vIEVpdGhlciB6ZXJvP1xuICAgICAgICBpZiAoIXhjWzBdIHx8ICF5Y1swXSkge1xuICAgICAgICAgICAgbGV0IHJlc3VsdDtcbiAgICAgICAgICAgIGlmICgheGNbMF0pIHtcbiAgICAgICAgICAgICAgICByZXN1bHQgPSAheWNbMF0/MDotajtcbiAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgcmVzdWx0ID0gaTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIHJldHVybiByZXN1bHQ7XG4gICAgICAgIH1cblxuICAgICAgICAvLyBTaWducyBkaWZmZXI/XG4gICAgICAgIGlmIChpICE9PSBqKSB7XG4gICAgICAgICAgICByZXR1cm4gaTtcbiAgICAgICAgfVxuICAgICAgICBjb25zdCB4TmVnID0gaSA8IDA7XG5cbiAgICAgICAgLy8gQ29tcGFyZSBleHBvbmVudHNcbiAgICAgICAgaWYgKGsgIT09IGwpIHtcbiAgICAgICAgICAgIHJldHVybiAoayA+IGwgXiB4TmVnKT8xOi0xO1xuICAgICAgICB9XG4gICAgICAgIGkgPSAtMTtcbiAgICAgICAgayA9IHhjLmxlbmd0aDtcbiAgICAgICAgbCA9IHljLmxlbmd0aDtcbiAgICAgICAgaiA9IChrIDwgbCkgPyBrIDogbDtcblxuICAgICAgICAvLyBDb21wYXJlIGRpZ2l0IGJ5IGR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ZSkge1xuICAgICAgICBjb25zdCBuYW1lRVEgPSBuYW1lICsgJz0nO1xuICAgICAgICBjb25zdCBjYSA9IGRvY3VtZW50LmNvb2tpZS5zcGxpdCgnOycpO1xuICAgICAgICBsZXQgYyA9ICcnO1xuICAgICAgICBmb3IgKGxldCBpID0gMDsgaSA8IGNhLmxlbmd0aDsgaSArPSAxKSB7XG4gICAgICAgICAgICBjID0gY2FbaV07XG4gICAgICAgICAgICB3aGlsZSAoYy5jaGFyQXQoMCkgPT09ICcgJykge1xuICAgICAgICAgICAgICAgIGMgPSBjLnN1YnN0cmluZygxLCBjLmxlbmd0aCk7XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICBpZiAoYy5pbmRleE9mKG5hbWVFUSkgPT09IDApIHtcbiAgICAgICAgICAgICAgICByZXR1cm4gYy5zdWJzdHJpbmcobmFtZUVRLmxlbmd0aCwgYy5sZW5ndGgpO1xuICAgICAgICAgICAgfVxuICAgICAgICB9XG5cbiAgICAgICAgcmV0dXJuIG51bGw7XG4gICAgfVxuXG4gICAgLyoqXG4gICAgICogVGVzdCBpZiBzZXNzaW9uU3RvcmFnZSBpcyBzdXBwb3J0ZWQuXG4gICAgICogVGhpcyBpcyB0YWtlbiBmcm9tIE1vZGVybml6ci5cbiAgICAgKlxuICAgICAqIEByZXR1cm5zIHtib29sZWFufVxuICAgICAqL1xuICAgIGZ1bmN0aW9uIHN0b3JhZ2VUZXN0KCkge1xuICAgICAgICBjb25zdCBtb2QgPSAnbW9kZXJuaXpyJztcbiAgICAgICAgdHJ5IHtcbiAgICAgICAgICAgIHNlc3Npb25TdG9yYWdlLnNldEl0ZW0obW9kLCBtb2QpO1xuICAgICAgICAgICAgc2Vzc2lvblN0b3JhZ2UucmVtb3ZlSXRlbShtb2QpO1xuICAgICAgICAgICAgcmV0dXJuIHRydWU7XG4gICAgICAgIH0gY2F0Y2ggKGUpIHtcbiAgICAgICAgICAgIHJldHVybiBmYWxzZTtcbiAgICAgICAgfVxuICAgIH1c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AgICBsZXQgZXhwaXJlcztcblxuICAgICAgICAgICAgLy8gU2V0cyBjb29raWUgZm9yIGJyb3dzZXIgdGhhdCBkbyBub3Qgc3VwcG9ydCBzZXNzaW9uU3RvcmFnZSBJRSA2ICYgSUUgN1xuICAgICAgICAgICAgaWYgKHN0b3JhZ2VUZXN0KCkgPT09IGZhbHNlKSB7XG4gICAgICAgICAgICAgICAgc3dpdGNoIChhY3Rpb24pIHtcbiAgICAgICAgICAgICAgICAgICAgY2FzZSAnc2V0JzpcbiAgICAgICAgICAgICAgICAgICAgICAgIGRvY3VtZW50LmNvb2tpZSA9IGAke3N0b3JlZE5hbWV9PSR7c2V0dGluZ3MucmF3VmFsdWV9OyBleHBpcmVzPSA7IHBhdGg9L2A7XG4gICAgICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICAgICAgY2FzZSAnd2lwZSc6XG4gICAgICAgICAgICAgICAgICAgICAgICBkYXRlID0gbmV3IERhdGUoKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIGRhdGUuc2V0VGltZShkYXRlLmdldFRpbWUoKSArICgtMSAqIDI0ICogNjAgKiA2MCAqIDEwMDApKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIGV4cGlyZXMgPSAnOyBleHBpcmVzPScgKyBkYXRlLnRvVVRDU3RyaW5nKCk7IC8vIE5vdGUgOiBgdG9HTVRTdHJpbmcoKWAgaGFzIGJlZW4gZGVwcmVjYXRlZCAoY2YuIGh0dHBzOi8vZGV2ZWxvcGVyLm1vemlsbGEub3JnL2VuLVVTL2RvY3MvV2ViL0phdmFTY3JpcHQvUmVmZXJlbmNlL0dsb2JhbF9PYmplY3RzL0RhdGUvdG9HTVRTdHJpbmcpXG4gICAgICAgICAgICAgICAgICAgICAgICBkb2N1bWVudC5jb29raWUgPSBgJHtzdG9yZWROYW1lfT0nJyA7JHtleHBpcmVzfTsgcGF0aD0vYDtcbiAgICAgICAgICAgICAgICAgICAgICAgIGJyZWFrO1xuICAgICAgICAgICAgICAgICAgICBjYXNlICdnZXQnOlxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHJlYWRDb29raWUoc3RvcmVkTmFtZSk7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgICAgICBzd2l0Y2ggKGFjdGlvbikge1xuICAgICAgICAgICAgICAgICAgICBjYXNlICdzZXQnOlxuICAgICAgICAgICAgICAgICAgICAgICAgc2Vzc2lvblN0b3JhZ2Uuc2V0SXRlbShzdG9yZWROYW1lLCBzZXR0aW5ncy5yYXdWYWx1ZSk7XG4gICAgICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICAgICAgY2FzZSAnd2lwZSc6XG4gICAgICAgICAgICAgICAgICAgICAgICBzZXNzaW9uU3RvcmFnZS5yZW1vdmVJdGVtKHN0b3JlZE5hbWUpO1xuICAgICAgICAgICAgICAgICAgICAgICAgYnJlYWs7XG4gICAgICAgICAgICAgICAgICAgIGNhc2UgJ2dldCc6XG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gc2Vzc2lvblN0b3JhZ2UuZ2V0SXRlbShzdG9yZWROYW1lKTtcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9XG4gICAgICAgIH1cbiAgICB9XG5cbiAgICAvKipcbiAgICAgKiBIb2xkZXIgb2JqZWN0IGZvciBmaWVsZCBwcm9wZXJ0aWVzXG4gICAgICovXG4gICAgY2xhc3MgQXV0b051bWVyaWNIb2xkZXIge1xuICAgICAgICAvKipcbiAgICAgICAgICogQ2xhc3MgY29uc3RydWN0b3JcbiAgICAgICAgICpcbiAgICAgICAgICogQHBhcmFtIHtIVE1MRWxlbWVudH0gdGhhdCAtIEEgcmVmZXJlbmNlIHRvIHRoZSBjdXJyZW50IERPTSBlbGVtZW50XG4gICAgICAgICAqIEBwYXJhbSB7b2JqZWN0fSBzZXR0aW5nc1xuICAgICAgICAgKi9cbiAgICAgICA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WNpdCAoYW5kIGEgYm9vbGVhbilcbiAgICAgICAgICAgIHN0YXJ0ID0gTWF0aC5tYXgoc3RhcnQsIDApO1xuICAgICAgICAgICAgZW5kID0gTWF0aC5taW4oZW5kLCB0aGlzLnRoYXQudmFsdWUubGVuZ3RoKTsgLy9UT0RPIFJlcGxhY2UgYHRoaXMudGhhdC52YWx1ZS5sZW5ndGhgIHdpdGggYHRoaXMudmFsdWUubGVuZ3RoYFxuICAgICAgICAgICAgdGhpcy5zZWxlY3Rpb24gPSB7XG4gICAgICAgICAgICAgICAgc3RhcnQsXG4gICAgICAgICAgICAgICAgZW5kLFxuICAgICAgICAgICAgICAgIGxlbmd0aDogZW5kIC0gc3RhcnQsXG4gICAgICAgICAgICB9O1xuXG4gICAgICAgICAgICBpZiAoaXNVbmRlZmluZWQoc2V0UmVhbCkgfHwgc2V0UmVhbCkge1xuICAgICAgICAgICAgICAgIHNldEVsZW1lbnRTZWxlY3Rpb24odGhpcy50aGF0LCBzdGFydCwgZW5kKTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgfVxuXG4gICAgICAgIC8qKlxuICAgICAgICAgKiBTZXQgdGhlIGNhcmV0IHBvc2l0aW9uIGluc2lkZSB0aGUgaW5wdXQgYXQgdGhlIGdpdmVuIHBvc2l0aW9uLlxuICAgICAgICAgKlxuICAgICAgICAgKiBAcGFyYW0ge2ludH0gcG9zXG4gICAgICAgICAqIEBwYXJhbSB7dW5kZWZpbmVkfGJvb2xlYW59IHNldFJlYWxcbiAgICAgICAgICogQHByaXZhdGVcbiAgICAgICAgICovXG4gICAgICAgIF9zZXRDYXJldFBvc2l0aW9uKHBvcywgc2V0UmVhbCkge1xuICAgICAgICAgICAgLy9UT0RPIE1vZGlmeSBzZXRSZWFsIHRvIGJlIG1vcmUgZXhwbGljaXQgKGFuZCBhIGJvb2xlYW4pXG4gICAgICAgICAgICB0aGlzLl9zZXRTZWxlY3Rpb24ocG9zLCBwb3MsIHNldFJlYWwpO1xuICAgICAgICB9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PSAnZGVueScpIHtcbiAgICAgICAgICAgICAgICAgICAgLy8gSWYgdGhlIHVzZXIgZW50ZXIgYDBgLCB0aGVuIHRoZSBjYXJldCBpcyBwdXQgb24gdGhlIHJpZ2h0IHNpZGUgb2YgaXQgKEZpeCBpc3N1ZSAjMjk5KVxuICAgICAgICAgICAgICAgICAgICBpZiAocGFydHNbMV0gPT09ICcnIHx8IHBhcnRzWzBdID09PSAnMCcgJiYgcGFydHNbMV0gIT09ICcnKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBwb3NpdGlvbiA9IDE7XG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBwb3NpdGlvbiA9IDA7XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICB9XG5cbiAgICAgICAgICAgICAgICB0aGlzLnZhbHVlID0gdGhpcy5uZXdWYWx1ZTtcbiAgICAgICAgICAgICAgICB0aGlzLl9zZXRDYXJldFBvc2l0aW9uKHBvc2l0aW9uLCBmYWxzZSk7XG5cbiAgICAgICAgICAgICAgICByZXR1cm4gdHJ1ZTtcbiAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgaWYgKCFtaW5UZXN0KSB7XG4gICAgICAgICAgICAgICAgdGhpcy4kdGhhdC50cmlnZ2VyKCdhdXRvTnVtZXJpYzptaW5FeGNlZWRlZCcpO1xuICAgICAgICAgICAgfSBlbHNlIGlmICghbWF4VGVzdCkge1xuICAgICAgICAgICAgICAgIHRoaXMuJHRoYXQudHJpZ2dlcignYXV0b051bWVyaWM6bWF4RXhjZWVkZWQnKTtcbiAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgcmV0dXJuIGZhbHNlO1xuICAgICAgICB9XG5cbiAgICAgICAgLyoqXG4gICAgICAgICAqIEhlbHBlciBmdW5jdGlvbiBmb3IgYF9leHBhbmRTZWxlY3Rpb25PblNpZ24oKWAuXG4gICAgICAgICAqXG4gICAgICAgICAqIEByZXR1cm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3dzICYmIHRoaXMuZXZlbnRLZXlDb2RlIDw9IGtleUNvZGUuUmlnaHRDbGljaykgfHxcbiAgICAgICAgICAgICAgICAodGhpcy5ldmVudEtleUNvZGUgPj0ga2V5Q29kZS5UYWIgJiYgdGhpcy5ldmVudEtleUNvZGUgPCBrZXlDb2RlLlNwYWNlKSB8fFxuICAgICAgICAgICAgICAgIC8vIGBlLndoaWNoYCBpcyBzb21ldGltZXMgZGlmZmVyZW50IHRoYW4gYHRoaXMuZXZlbnRLZXlDb2RlYCBkdXJpbmcgdGhlIGtleXByZXNzIGV2ZW50IHdoZW4gZW50ZXJpbmcgYSBwcmludGFibGUgY2hhcmFjdGVyIGtleSAoaWUuICd0JykuIEFsc28sIGBlLndoaWNoYCBlcXVhbHMgMCBmb3Igbm9uLXByaW50YWJsZSBjaGFyYWN0ZXJzLlxuICAgICAgICAgICAgICAgICh0aGlzLmV2ZW50S2V5Q29kZSA8IGtleUNvZGUuQmFja3NwYWNlICYmXG4gICAgICAgICAgICAgICAgKGUud2hpY2ggPT09IDAgfHwgZS53aGljaCA9PT0gdGhpcy5ldmVudEtleUNvZGUpKSB8fFxuICAgICAgICAgICAgICAgIHRoaXMuZXZlbnRLZXlDb2RlID09PSBrZXlDb2RlLk51bUxvY2sgfHxcbiAgICAgICAgICAgICAgICB0aGlzLmV2ZW50S2V5Q29kZSA9PT0ga2V5Q29kZS5TY3JvbGxMb2NrIHx8XG4gICAgICAgICAgICAgICAgdGhpcy5ldmVudEtleUNvZGUgPT09IGtleUNvZGUuSW5zZXJ0IHx8XG4gICAgICAgICAgICAgICAgdGhpcy5ldmVudEtleUNvZGUgPT09IGtleUNvZGUuQ29tbWFuZCkge1xuICAgICAgICAgICAgICAgIHJldHVybiB0cnVlO1xuICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAvLyBJZiBhIFwiU2VsZWN0IGFsbFwiIGtleWJvYXJkIHNob3J0Y3V0IGlzIGRldGVjdGVkIChjdHJsICsgYSlcbiAgICAgICA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7XG4gICAgICAgICAgICAgICAgICAgIGNvbnN0IG5lZ2F0aXZlUG9zaXRpdmVTaWduUGxhY2VtZW50ID0gdGhpcy5zZXR0aW5ncy5uZWdhdGl2ZVBvc2l0aXZlU2lnblBsYWNlbWVudDtcblxuICAgICAgICAgICAgICAgICAgICBsZXQgc3RhcnQ7XG4gICAgICAgICAgICAgICAgICAgIGlmIChjdXJyZW5jeVN5bWJvbFBsYWNlbWVudCA9PT0gJ3MnKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBzdGFydCA9IDA7XG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBzdGFydCA9IChuZWdhdGl2ZVBvc2l0aXZlU2lnblBsYWNlbWVudCA9PT0gJ2wnICYmIG5lZ0xlbiA9PT0gMSAmJiBjdXJyZW5jeVN5bWJvbExlbiA+IDApP2N1cnJlbmN5U3ltYm9sTGVuICsgMTpjdXJyZW5jeVN5bWJvbExlbjtcbiAgICAgICAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgICAgICAgIGxldCBlbmQ7XG4gICAgICAgICAgICAgICAgICAgIGlmIChjdXJyZW5jeVN5bWJvbFBsYWNlbWVudCA9PT0gJ3AnKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBlbmQgPSB2YWx1ZUxlbiAtIHN1ZmZpeFRleHRMZW47XG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBzd2l0Y2ggKG5lZ2F0aXZlUG9zaXRpdmVTaWduUGxhY2VtZW50KSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgY2FzZSAnbCc6XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGVuZCA9IHZhbHVlTGVuIC0gKHN1ZmZpeFRleHRMZW4gKyBjdXJyZW5jeVN5bWJvbExlbik7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGJyZWFrO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNhc2UgJ3InOlxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBlbmQgPSAoY3VycmVuY3lTeW1ib2xMZW4gPiAwKT92YWx1ZUxlbiAtIChjdXJyZW5jeVN5bWJvbExlbiArIG5lZ0xlbiArIHN1ZmZpeFRleHRMZW4pOnZhbHVlTGVuIC0gKGN1cnJlbmN5U3ltYm9sTGVuICsgc3VmZml4VGV4dExlbik7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGJyZWFrO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGRlZmF1bHQgOlxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBlbmQgPSB2YWx1ZUxlbiAtIChjdXJyZW5jeVN5bWJvbExlbiArIHN1ZmZpeFRleHRMZW4pO1xuICAgICAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICB9XG5cbiAgICAgICAgICAgICAgICAgICAgc2V0RWxlbWVudFNlbGVjdGlvbih0aGlzLnRoYXQsIHN0YXJ0LCBlbmQpO1xuICAgICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAgIHJldHVybiB0cnVlO1xuICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAvLyBJZiBhIFwiQ29weVwiLCBcIlBhc3RlXCIgb3IgXCJDdXRcIiBrZXlib2FyZCBzaG9ydGN1dCBpcyBkZXRlY3RlZCAocmVzcGVjdGl2ZWx5ICdjdHJsICsgYycsICdjdHJsICsgdicgb3IgJ2N0cmwgKyB4JylcbiAgICAgICAgICAgIGlmICgoZS5jdHJsS2V5IHx8IGUubWV0YUtleSkgJiYgKHRoaXMuZXZlbnRLZXlDb2RlID09PSBrZXlDb2RlLmMgfHwgdGhpcy5ldmVudEtleUNvZGUgPT09IGtleUNvZGUudiB8fCB0aGlzLmV2ZW50S2V5Q29kZSA9PT0ga2V5Q29kZS54KSkge1xuICAgICAgICAgICAgICAgIGlmIChlLnR5cGUgPT09ICdrZXlkb3duJykge1xuICAgICAgICAgICAgICAgICAgICB0aGlzLl9leHBhbmRTZWxlY3Rpb25PblNpZ24oKTtcbiAgICAgICAgICAgICAgICB9XG5cbiAgICAgICAgICAgICAgICAvLyBUcnkgdG8gcHJldmVudCB3cm9uZyBwYXN0ZVxuICAgICAgICAgICAgICAgIGlmICh0aGlzLmV2ZW50S2V5Q29kZSA9PT0ga2V5Q29kZS52IHx8IHRoaXMuZXZlbnRLZXlDb2RlID09PSBrZXlDb2RlLkluc2VydCkge1xuICAgICAgICAgICAgICAgICAgICBpZiAoZS50eXBlID09PSAna2V5ZG93bicgfHwgZS50eXBlID09PSAna2V5cHJlc3MnKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoaXNVbmRlZmluZWQodGhpcy52YWx1ZVBhcnRzQmVmb3JlUGFzdGUpKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy52YWx1ZVBhcnRzQmVmb3JlUGFzdGUgPSB0aGlzLl9nZXRMZWZ0QW5kUmlnaHRQYXJ0QXJvdW5kVGhlU2VsZWN0aW9uKCk7XG4gICAgICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgICAgICAgICB0aGlzLl9jaGVja1Bhc3RlKCk7XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICB9XG5cbiAgICAgICAgICAgICAgICByZXR1cm4gZS50eXBlID09PSAna2V5ZG93bicgfHwgZS50eXBlID09PSAna2V5cHJlc3MnIHx8IHRoaXMuZXZlbnRLZXlDb2RlID09PSBrZXlDb2RlLmM7XG4gICAgICAgICAgICB9XG5cbiAgICAgICAgICAgIGlmIChlLmN0cmxLZXkgfHwgZS5tZXRhS2V5KSB7XG4gICAgICAgICAgICAgICAgcmV0dXJuIHRydWU7XG4gICAgICAgICAgICB9XG5cbiAgICAgICAgICAgIC8vIEp1bXAgb3ZlciB0aG91c2FuZCBzZXBhcmF0b3JcbiAgICAgICAgICAgIC8vVE9ETyBNb3ZlIHRoaXMgdGVzdCBpbnNpZGUgdGhlIGBvbktleWRvd25gIGhhbmRsZXJcbiAgICAgICAgICAgIGlmICh0aGlzLmV2ZW50S2V5Q29kZSA9PT0ga2V5Q29kZS5MZWZ0QXJyb3cgfHwgdGhpcy5ldmVudEtleUNvZGUgPT09IGtleUNvZGUuUmlnaHRBcnJvdykge1xuICAgICAgICAgICAgICAgIGlmIChlLnR5cGUgPT09ICdrZXlkb3duJyAmJiAhZS5zaGlmdEtleSkge1xuICAgICAgICAgICAgICAgICAgICBpZiAodGhpcy5ldmVudEtleUNvZGUgPT09IGtleUNvZGUuTGVmdEFycm93ICYmXG4gICAgICAgICAgICAgICAgICAgICAgICAodGhpcy50aGF0LnZhbHVlLmNoYXJBdCh0aGlzLnNlbGVjdGlvbi5zdGFydCAtIDIpID09PSB0aGlzLnNldHRpbmdzQ2xvbmUuZGlnaXRHcm91cFNlcGFyYXRvciB8fFxuICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy50aGF0LnZhbHVlLmNoYXJBdCh0aGlzLnNlbGVjdGlvbi5zdGFydCAtIDIpID09PSB0aGlzLnNldHRpbmdzQ2xvbmUuZGVjaW1hbENoYXJhY3RlcikpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMuX3NldENhcmV0UG9zaXRpb24odGhpcy5zZWxlY3Rpb24uc3RhcnQgLSAxKTtcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIGlmICh0aGlzLmV2ZW50S2V5Q29kZSA9PT0ga2V5Q29kZS5SaWdodEFycm93ICYmXG4gICAgICAgICAgICAgICAgICAgICAgICAodGhpcy50aGF0LnZhbHVlLmNoYXJBdCh0aGlzLnNlbGVjdGlvbi5zdGFydCArIDEpID09PSB0aGlzLnNldHRpbmdzQ2xvbmUuZGlnaXRHcm91cFNlcGFyYXRvciB8fFxuICAgICAgICAgICAgICAgICAgICAgICAgdGhpc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pKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBsZWZ0ID0gbGVmdC5zdWJzdHJpbmcoMSk7XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgcmlnaHQgPSByaWdodC5zdWJzdHJpbmcoMSk7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICByZXR1cm4gW2xlZnQsIHJpZ2h0XTtcbiAgICAgICAgfVxuXG4gICAgICAgIC8qKlxuICAgICAgICAgKiBQcm9jZXNzIHRoZSBkZWxldGlvbiBvZiBjaGFyYWN0ZXJzLlxuICAgICAgICAgKi9cbiAgICAgICAgX3Byb2Nlc3NDaGFyYWN0ZXJEZWxldGlvbigpIHtcbiAgICAgICAgICAgIGNvbnN0IHNldHRpbmdzQ2xvbmUgPSB0aGlzLnNldHRpbmdzQ2xvbmU7XG5cbiAgICAgICAgICAgIGxldCBsZWZ0O1xuICAgICAgICAgICAgbGV0IHJpZ2h0O1xuXG4gICAgICAgICAgICBpZiAoIXRoaXMuc2VsZWN0aW9uLmxlbmd0aCkge1xuICAgICAgICAgICAgICAgIFtsZWZ0LCByaWdodF0gPSB0aGlzLl9nZXRVbmZvcm1hdHRlZExlZnRBbmRSaWdodFBhcnRBcm91bmRUaGVTZWxlY3Rpb24oKTtcbiAgICAgICAgICAgICAgICBpZiAobGVmdCA9PT0gJycgJiYgcmlnaHQgPT09ICcnKSB7XG4gICAgICAgICAgICAgICAgICAgIHNldHRpbmdzQ2xvbmUudGhyb3dJbnB1dCA9IGZhbHNlO1xuICAgICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAgIGlmICgoKHNldHRpbmdzQ2xvbmUuY3VycmVuY3lTeW1ib2xQbGFjZW1lbnQgPT09ICdwJyAmJiBzZXR0aW5nc0Nsb25lLm5lZ2F0aXZlUG9zaXRpdmVTaWduUGxhY2VtZW50ID09PSAncycpIHx8XG4gICAgICAgICAgICAgICAgICAgIChzZXR0aW5n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lclxuICAgICAgICAgICAgICAgIGlmIChzZXR0aW5nc0Nsb25lLm5lZ2F0aXZlU2lnbkNoYXJhY3RlciAmJiBjb250YWlucyhyaWdodCwgc2V0dGluZ3NDbG9uZS5uZWdhdGl2ZVNpZ25DaGFyYWN0ZXIpKSB7XG4gICAgICAgICAgICAgICAgICAgIHJldHVybiB0cnVlO1xuICAgICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAgIC8vIERvIG5vdCBhbGxvdyBkZWNpbWFsIGNoYXJhY3RlciBpZiBvdGhlciBkZWNpbWFsIGNoYXJhY3RlciBwcmVzZW50XG4gICAgICAgICAgICAgICAgaWYgKGNvbnRhaW5zKGxlZnQsIHNldHRpbmdzQ2xvbmUuZGVjaW1hbENoYXJhY3RlcikpIHtcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHRydWU7XG4gICAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgICAgaWYgKHJpZ2h0LmluZGV4T2Yoc2V0dGluZ3NDbG9uZS5kZWNpbWFsQ2hhcmFjdGVyKSA+IDApIHtcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHRydWU7XG4gICAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgICAgaWYgKHJpZ2h0LmluZGV4T2Yoc2V0dGluZ3NDbG9uZS5kZWNpbWFsQ2hhcmFjdGVyKSA9PT0gMCkge1xuICAgICAgICAgICAgICAgICAgICByaWdodCA9IHJpZ2h0LnN1YnN0cigxKTtcbiAgICAgICAgICAgICAgICB9XG5cbiAgICAgICAgICAgICAgICB0aGlzLl9zZXRWYWx1ZVBhcnRzKGxlZnQgKyBzZXR0aW5nc0Nsb25lLmRlY2ltYWxDaGFyYWN0ZXIsIHJpZ2h0KTtcblxuICAgICAgICAgICAgICAgIHJldHVybiB0cnVlO1xuICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAvLyBQcmV2ZW50IG1pbnVzIGlmIG5vdCBhbGxvd2VkXG4gICAgICAgICAgICB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NlbWVudCA9PT0gJ3MnICYmIHNldHRpbmdzQ2xvbmUubmVnYXRpdmVQb3NpdGl2ZVNpZ25QbGFjZW1lbnQgIT09ICdwJykpICYmXG4gICAgICAgICAgICAgICAgICAgIGxlZnRBclswXSA9PT0gJy0nICYmIHNldHRpbmdzQ2xvbmUubmVnYXRpdmVTaWduQ2hhcmFjdGVyICE9PSAnJykge1xuICAgICAgICAgICAgICAgICAgICBsZWZ0QXIuc2hpZnQoKTtcblxuICAgICAgICAgICAgICAgICAgICBpZiAoKHRoaXMuZXZlbnRLZXlDb2RlID09PSBrZXlDb2RlLkJhY2tzcGFjZSB8fCB0aGlzLmV2ZW50S2V5Q29kZSA9PT0ga2V5Q29kZS5EZWxldGUpICYmXG4gICAgICAgICAgICAgICAgICAgICAgICBzZXR0aW5nc0Nsb25lLmNhcmV0Rml4KSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoc2V0dGluZ3NDbG9uZS5jdXJyZW5jeVN5bWJvbFBsYWNlbWVudCA9PT0gJ3MnICYmIHNldHRpbmdzQ2xvbmUubmVnYXRpdmVQb3NpdGl2ZVNpZ25QbGFjZW1lbnQgPT09ICdsJykge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGxlZnRBci5wdXNoKCctJyk7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgc2V0dGluZ3NDbG9uZS5jYXJldEZpeCA9IGUudHlwZSA9PT0gJ2tleWRvd24nO1xuICAgICAgICAgICAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoc2V0dGluZ3NDbG9uZS5jdXJyZW5jeVN5bWJvbFBsYWNlbWVudCA9PT0gJ3AnICYmIHNldHRpbmdzQ2xvbmUubmVnYXRpdmVQb3NpdGl2ZVNpZ25QbGFjZW1lbnQgPT09ICdzJykge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGxlZnRBci5wdXNoKCctJyk7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgc2V0dGluZ3NDbG9uZS5jYXJldEZpeCA9IGUudHlwZSA9PT0gJ2tleWRvd24nO1xuICAgICAgICAgICAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoc2V0dGluZ3NDbG9uZS5jdXJyZW5jeVN5bWJvbFBsYWNlbWVudCA9PT0gJ3MnICYmIHNldHRpbmdzQ2xvbmUubmVnYXRpdmVQb3NpdGl2ZVNpZ25QbGFjZW1lbnQgPT09ICdyJykge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNvbnN0IHNpZ25QYXJ0cyA9IHNldHRpbmdzQ2xvbmUuY3VycmVuY3lTeW1ib2wuc3BsaXQoJycpO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNvbnN0IGVzY2FwZUNociA9IFsnXFxcXCcsICdeJywgJyQnLCAnLicsICd8JywgJz8nLCAnKicsICcrJywgJygnLCAnKScsICdbJ107XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc3QgZXNjYXBlZFBhcnRzID0gW107XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgJC5lYWNoKHNpZ25QYXJ0cywgKGksIG1pbmlQYXJ0cykgPT4ge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBtaW5pUGFydHMgPSBzaWduUGFydHNbaV07XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChpc0luQXJyYXkobWluaVBhcnRzLCBlc2NhcGVDaHIpKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBlc2NhcGVkUGFydHMucHVzaCgnXFxcXCcgKyBtaW5pUGFydHMpO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZXNjYXBlZFBhcnRzLnB1c2gobWluaVBhcnRzKTtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xuXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYgKHRoaXMuZXZlbnRLZXlDb2RlID09PSBrZXlDb2RlLkJhY2tzcGFjZSkge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBlc2NhcGVkUGFydHMucHVzaCgnLScpO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vIFB1c2hpbmcgdGhlIGVzY2FwZWQgc2lnblxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGxlZnRBci5wdXNoKGVzY2FwZWRQYXJ0cy5qb2luKCcnKSk7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgc2V0dGluZ3NDbG9uZS5jYXJldEZpeCA9IGUudHlwZSA9PT0gJ2tleWRvd24nO1xuICAgICAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgICAgZm9yIChsZXQgaSA9IDA7IGkgPCBsZWZ0QXIubGVuZ3RoOyBpKyspIHtcbiAgICAgICAgICAgICAgICAgICAgaWYgKCFsZWZ0QXJbaV0ubWF0Y2goJ1xcXFxkJykpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIGxlZnRBcltpXSA9ICdcXFxcJyArIGxlZnRBcltpXTtcbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAgIGNvbnN0IGxlZnRSZWcgPSBuZXcgUmVnRXhwKCdeLio/JyArIGxlZnRBci5qb2luKCcuKj8nKSk7XG5cbiAgICAgICAgICAgICAgICAvLyBTZWFyY2ggY3Vyc29yIHBvc2l0aW9uIGluIGZvcm1hdHRlZCB2YWx1ZVxuICAgICAgICAgICAgICAgIGNvbnN0IG5ld0xlZnQgPSB2YWx1ZS5tYXRjaChsZWZ0UmVnKTtcbiAgICAgICAgICAgICAgICB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dGVyVHlwZXMudGVzdChmaWVsZC50eXBlKSAmJiAhZmllbGQuZGlzYWJsZWQgJiYgKGZpZWxkLmNoZWNrZWQgfHwgIXJDaGVja2FibGVUeXBlLnRlc3QoZmllbGQudHlwZSkpKSB7XG4gICAgICAgICAgICAgICAgc2NJbmRleC5wdXNoKGNvdW50KTtcbiAgICAgICAgICAgICAgICBjb3VudCsrO1xuICAgICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgICAgICBzY0luZGV4LnB1c2goLTEpO1xuICAgICAgICAgICAgfVxuICAgICAgICB9KTtcblxuICAgICAgICAvLyBpbmRleCBvZiBhbGwgaW5wdXRzIHRhZ3MgZXhjZXB0IGNoZWNrYm94XG4gICAgICAgIGNvdW50ID0gMDtcbiAgICAgICAgJC5lYWNoKGFsbEZvcm1FbGVtZW50cywgKGksIGZpZWxkKSA9PiB7XG4gICAgICAgICAgICBpZiAoZmllbGQubG9jYWxOYW1lID09PSAnaW5wdXQnICYmIChmaWVsZC50eXBlID09PSAnJyB8fCBmaWVsZC50eXBlID09PSAndGV4dCcgfHwgZmllbGQudHlwZSA9PT0gJ2hpZGRlbicgfHwgZmllbGQudHlwZSA9PT0gJ3RlbCcpKSB7XG4gICAgICAgICAgICAgICAgYWlJbmRleC5wdXNoKGNvdW50KTtcbiAgICAgICAgICAgICAgICBjb3VudCsrO1xuICAgICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgICAgICBhaUluZGV4LnB1c2goLTEpO1xuICAgICAgICAgICAgICAgIGlmIChmaWVsZC5sb2NhbE5hbWUgPT09ICdpbnB1dCcgJiYgck5vbkF1dG9OdW1lcmljVHlwZXMudGVzdChmaWVsZC50eXBlKSkge1xuICAgICAgICAgICAgICAgICAgICBjb3VudCsrO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgIH1cbiAgICAgICAgfSk7XG5cbiAgICAgICAgaWYgKGdldEFycmF5QmVoYXZpb3IpIHtcbiAgICAgICAgICAgIGNvbnN0IGZvcm1GaWVsZHMgPSAkdGhpcy5zZXJpYWxpemVBcnJheSgpO1xuXG4gICAgICAgICAgICAkLmVhY2goZm9ybUZpZWxkcywgKGksIGZpZWxkKSA9PiB7XG4gICAgICAgICAgICAgICAgY29uc3Qgc2NFbGVtZW50ID0gc2NJbmRleC5pbmRleE9mKGkpO1xuXG4gICAgICAgICAgICAgICAgaWYgKHNjRWxlbWVudCA+IC0xICYmIGFpSW5kZXhbc2NFbGVtZW50XSA+IC0xKSB7XG4gICAgICAgICAgICAgICAgICAgIGNvbnN0IHRlc3RJbnB1dCA9ICQoYGZvcm06ZXEoJHtmb3JtSW5kZXh9KSBpbnB1dDplcSgke2FpSW5kZXhbc2NFbGVtZW50XX0pYCk7XG4gICAgICAgICAgICAgICAgICAgIGNvbnN0IHNldHRpbmdzID0gdGVzdElucHV0LmRhdGEoJ2F1dG9OdW1lcmljJyk7XG5cbiAgICAgICAgICAgICAgICAgICAgaWYgKHR5cGVvZiBzZXR0aW5ncyA9PT0gJ29iamVjdCcpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIGZpZWxkLnZhbHVlID0gdGVzdElucHV0LmF1dG9OdW1lcmljKCdnZXRMb2NhbGl6ZWQnKS50b1N0cmluZygpO1xuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgfSk7XG5cbiAgICAgICAgICAgIHJldHVybiBmb3JtRmllbGRzO1xuICAgICAgICB9XG4gICAgICAgIGVsc2Uge1xuICAgICAgICAgICAgLy8gZ2V0U3RyaW5nKCkgYmVoYXZpb3JcbiAgICAgICAgICAgIGNvbnN0IGZvcm1GaWVsZHMgPSAkdGhpcy5zZXJpYWxpemUoKTtcbiAgICAgICAgICAgIGNvbnN0IGZvcm1QYXJ0cyA9IGZvcm1GaWVsZHMuc3BsaXQoJyYnKTtcblxuICAgICAgICAgICAgJC5lYWNoKGZvcm1QYXJ0cywgaSA9PiB7XG4gICAgICAgICAgICAgICAgY29uc3QgW2lucHV0TmFtZSwgaW5wdXRWYWx1ZV0gPSBmb3JtUGFydHNbaV0uc3BsaXQoJz0nKTtcbiAgICAgICAgICAgICAgICBjb25zdCBzY0VsZW1lbnQgPSBzY0luZGV4LmluZGV4T2YoaSk7XG5cbiAgICAgICAgICAgICAgICAvLyBJZiB0aGUgY3VycmVudCBlbGVtZW50IGlzIGEgdmFsaWQgZWxlbWVudFxuICAgICAgICAgICAgICAgIGlmIChzY0VsZW1lbnQgPiAtMSAmJiBhaUluZGV4W3NjRWxlbWVudF0gPiAtMSkge1xuICAgICAgICAgICAgICAgICAgICBjb25zdCB0ZXN0SW5wdXQgPSAkKGBmb3JtOmVxKCR7Zm9ybUluZGV4fSkgaW5wdXQ6ZXEoJHthaUluZGV4W3NjRWxlbWVudF19KWApO1xuICAgICAgICAgICAgICAgICAgICBjb25zdCBzZXR0aW5ncyA9IHRlc3RJbnB1dC5kYXRhKCdhdXRvTnVtZXJpYycpO1xuXG4gICAgICAgICAgICAgICAgICAgIGlmICh0eXBlb2Ygc2V0dGluZ3MgPT09ICdvYmplY3QnKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoaW5wdXRWYWx1ZSAhPT0gbnVsbCkge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNvbnN0IG1vZGlmaWVkSW5wdXRWYWx1ZSA9IHRlc3RJbnB1dC5hdXRvTnVtZXJpYygnZ2V0TG9jYWxpemVkJykudG9TdHJpbmcoKTtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBmb3JtUGFydHNbaV0gPSBgJHtpbnB1dE5hbWV9PSR7bW9kaWZpZWRJbnB1dFZhbHVlfWA7XG4gICAgICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9KTtcblxuICAgICAgICAgICAgcmV0dXJuIGZvcm1QYXJ0cy5qb2luKCcmJyk7XG4gICAgICAgIH1cbiAgICB9XG5cbiA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51bGwgJiYgb25FbXB0eSAhPT0gJycpICYmIHNldHRpbmdzLmVtcHR5SW5wdXRCZWhhdmlvciA9PT0gJ2ZvY3VzJykge1xuICAgICAgICAgICAgICAgICR0aGlzLnZhbChvbkVtcHR5KTtcbiAgICAgICAgICAgICAgICBpZiAob25FbXB0eSA9PT0gc2V0dGluZ3MuY3VycmVuY3lTeW1ib2wgJiYgc2V0dGluZ3MuY3VycmVuY3lTeW1ib2xQbGFjZW1lbnQgPT09ICdzJykge1xuICAgICAgICAgICAgICAgICAgICBzZXRFbGVtZW50U2VsZWN0aW9uKGUudGFyZ2V0LCAwLCAwKTtcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9XG4gICAgICAgIH1cbiAgICB9XG5cbiAgICAvKipcbiAgICAgKiBIYW5kbGVyIGZvciAna2V5ZG93bicgZXZlbnRzLlxuICAgICAqIFRoZSB1c2VyIGp1c3Qgc3RhcnRlZCBwdXNoaW5nIGFueSBrZXksIGhlbmNlIG9uZSBldmVudCBpcyBzZW50LlxuICAgICAqXG4gICAgICogTm90ZSA6XG4gICAgICogQnkgZGVmYXVsdCBhICdub3JtYWwnIGlucHV0IG91dHB1dCB0aG9zZSBldmVudHMgaW4gdGhlIHJpZ2h0IG9yZGVyIHdoZW4gaW5wdXR0aW5nIGEgY2hhcmFjdGVyIGtleSAoaWUuICdhJykgOlxuICAgICAqIC0ga2V5ZG93blxuICAgICAqIC0ga2V5cHJlc3NcbiAgICAgKiAtIGlucHV0XG4gICAgICogLSBrZXl1cFxuICAgICAqXG4gICAgICogLi4ud2hlbiBpbnB1dHRpbmcgYSBtb2RpZmllciBrZXkgKGllLiAnY3RybCcpIDpcbiAgICAgKiAtIGtleWRvd25cbiAgICAgKiAtIGtleXVwXG4gICAgICpcbiAgICAgKiBJZiAnZGVsZXRlJyBvciAnYmFja3NwYWNlJyBpcyBlbnRlcmVkLCB0aGUgZm9sbG93aW5nIGV2ZW50cyBhcmUgc2VudCA6XG4gICAgICogLSBrZ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ICAgICAgICAgICAgICAgICB2YWx1ZSA9IHZhbHVlIC8gc2V0dGluZ3Muc2NhbGVEaXZpc29yO1xuICAgICAgICAgICAgICAgICAgICAgICAgdmFsdWUgPSB2YWx1ZS50b1N0cmluZygpO1xuICAgICAgICAgICAgICAgICAgICB9XG5cbiAgICAgICAgICAgICAgICAgICAgc2V0dGluZ3MuZGVjaW1hbFBsYWNlc092ZXJyaWRlID0gKHNldHRpbmdzLnNjYWxlRGl2aXNvciAmJiBzZXR0aW5ncy5zY2FsZURlY2ltYWxQbGFjZXMpID8gTnVtYmVyKHNldHRpbmdzLnNjYWxlRGVjaW1hbFBsYWNlcykgOiBzZXR0aW5ncy5kZWNpbWFsUGxhY2VzT3ZlcnJpZGU7XG4gICAgICAgICAgICAgICAgICAgIHZhbHVlID0gcm91bmRWYWx1ZSh2YWx1ZSwgc2V0dGluZ3MpO1xuICAgICAgICAgICAgICAgICAgICB2YWx1ZSA9IG1vZGlmeU5lZ2F0aXZlU2lnbkFuZERlY2ltYWxDaGFyYWN0ZXJGb3JGb3JtYXR0ZWRWYWx1ZSh2YWx1ZSwgc2V0dGluZ3MpO1xuICAgICAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgICAgIGlmICghbWluVGVzdCkge1xuICAgICAgICAgICAgICAgICAgICAgICAgJHRoaXMudHJpZ2dlcignYXV0b051bWVyaWM6bWluRXhjZWVkZWQnKTtcbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICBpZiAoIW1heFRlc3QpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgICR0aGlzLnRyaWdnZXIoJ2F1dG9OdW1lcmljOm1heEV4Y2VlZGVkJyk7XG4gICAgICAgICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAgICAgICB2YWx1ZSA9IHNldHRpbmdzLnJhd1ZhbHVlO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgaWYgKHNldHRpbmdzLmVtcHR5SW5wdXRCZWhhdmlvciA9PT0gJ3plcm8nKSB7XG4gICAgICAgICAgICAgICAgICAgIHNldHRpbmdzLnJhd1ZhbHVlID0gJzAnO1xuICAgICAgICAgICAgICAgICAgICB2YWx1ZSA9IHJvdW5kVmFsdWUoJzAnLCBzZXR0aW5ncyk7XG4gICAgICAgICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgICAgICAgICAgc2V0dGluZ3MucmF3VmFsdWUgPSAnJztcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9XG5cbiAgICAgICAgICAgIGxldCBncm91cGVkVmFsdWUgPSBjaGVja0VtcHR5KHZhbHVlLCBzZXR0aW5ncywgZmFsc2UpO1xuICAgICAgICAgICAgaWYgKGdyb3VwZWRWYWx1ZSA9PT0gbnVsbCkge1xuICAgICAgICAgICAgICAgIGdyb3VwZWRWYWx1ZSA9IGFkZEdyb3VwU2VwYXJhdG9ycyh2YWx1ZSwgc2V0dGluZ3MpO1xuICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICBpZiAoZ3JvdXBlZFZhbHVlICE9PSBvcmlnVmFsdWUpIHtcbiAgICAgICAgICAgICAgICBncm91cGVkVmFsdWUgPSAoc2V0dGluZ3Muc2NhbGVTeW1ib2wpID8gZ3JvdXBlZFZhbHVlICsgc2V0dGluZ3Muc2NhbGVTeW1ib2wgOiBncm91cGVkVmFsdWU7XG4gICAgICAgICAgICAgICAgJHRoaXMudmFsKGdyb3VwZWRWYWx1ZSk7XG4gICAgICAgICAgICB9XG5cbiAgICAgICAgICAgIGlmIChncm91cGVkVmFsdWUgIT09IGhvbGRlci52YWx1ZU9uRm9jdXMpIHtcbiAgICAgICAgICAgICAgICAkdGhpcy5jaGFuZ2UoKTtcbiAgICAgICAgICAgICAgICBkZWxldGUgaG9sZGVyLnZhbHVlT25Gb2N1cztcbiAgICAgICAgICAgIH1cbiAgICAgICAgfVxuICAgIH1cblxuICAgIC8qKl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2RpZnkgdGhlIHJlc3VsdCB3aXRoIGFub3RoZXIgcGFzdGVkIGNoYXJhY3RlclxuICAgICAgICAgICAgICAgICAgICBtb2RpZmllZExlZnRQYXJ0ICs9IHBhc3RlZFRleHRbcGFzdGVkVGV4dEluZGV4XTtcbiAgICAgICAgICAgICAgICAgICAgcmVzdWx0ID0gbW9kaWZpZWRMZWZ0UGFydCArIHJpZ2h0UGFydDtcblxuICAgICAgICAgICAgICAgICAgICAvLyBDaGVjayB0aGUgcmFuZ2UgbGltaXRzXG4gICAgICAgICAgICAgICAgICAgIGlmICghY2hlY2tJZkluUmFuZ2UocmVzdWx0LCBtaW5QYXJzZSwgbWF4UGFyc2UpKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAvLyBUaGUgcmVzdWx0IGlzIG91dCBvZiB0aGUgcmFuZ2UgbGltaXRzLCBzdG9wIHRoZSBsb29wIGhlcmVcbiAgICAgICAgICAgICAgICAgICAgICAgIGJyZWFrO1xuICAgICAgICAgICAgICAgICAgICB9XG5cbiAgICAgICAgICAgICAgICAgICAgLy8gU2F2ZSB0aGUgbGFzdCBnb29kIGtub3duIHJlc3VsdFxuICAgICAgICAgICAgICAgICAgICBsYXN0R29vZEtub3duUmVzdWx0ID0gcmVzdWx0O1xuXG4gICAgICAgICAgICAgICAgICAgIC8vIFVwZGF0ZSB0aGUgbG9jYWwgdmFyaWFibGVzIGZvciB0aGUgbmV4dCBsb29wXG4gICAgICAgICAgICAgICAgICAgIHBhc3RlZFRleHRJbmRleCsrO1xuICAgICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAgIC8vIFVwZGF0ZSB0aGUgbGFzdCBjYXJldCBwb3NpdGlvbiB3aGVyZSB0byBpbnNlcnQgYSBuZXcgbnVtYmVyXG4gICAgICAgICAgICAgICAgY2FyZXRQb3NpdGlvbk9uSW5pdGlhbFRleHRBZnRlclBhc3RpbmcgKz0gcGFzdGVkVGV4dEluZGV4O1xuXG4gICAgICAgICAgICAgICAgLy9YW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kluaXRpYWxUZXh0QWZ0ZXJQYXN0aW5nO1xuICAgICAgICAgICAgICAgIGNvbnN0IGxhc3RHb29kS25vd25SZXN1bHRTaXplID0gbGFzdEdvb2RLbm93blJlc3VsdC5sZW5ndGg7XG5cbiAgICAgICAgICAgICAgICB3aGlsZSAocGFzdGVkVGV4dEluZGV4IDwgcGFzdGVkVGV4dC5sZW5ndGggJiYgbGFzdEdvb2RLbm93blJlc3VsdEluZGV4IDwgbGFzdEdvb2RLbm93blJlc3VsdFNpemUpIHtcbiAgICAgICAgICAgICAgICAgICAgaWYgKGxhc3RHb29kS25vd25SZXN1bHRbbGFzdEdvb2RLbm93blJlc3VsdEluZGV4XSA9PT0gJy4nKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAvLyBXZSBza2lwIHRoZSBkZWNpbWFsIGNoYXJhY3RlciAncmVwbGFjZW1lbnQnLiBUaGF0IHdheSwgd2UgZG8gbm90IGNoYW5nZSB0aGUgZGVjaW1hbCBjaGFyYWN0ZXIgcG9zaXRpb24gcmVnYXJkaW5nIHRoZSByZW1haW5pbmcgbnVtYmVycy5cbiAgICAgICAgICAgICAgICAgICAgICAgIGxhc3RHb29kS25vd25SZXN1bHRJbmRleCsrO1xuICAgICAgICAgICAgICAgICAgICAgICAgY29udGludWU7XG4gICAgICAgICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAgICAgICAvLyBUaGlzIHJlcGxhY2Ugb25lIGNoYXJhY3RlciBhdCBhIHRpbWVcbiAgICAgICAgICAgICAgICAgICAgcmVzdWx0ID0gcmVwbGFjZUNoYXJBdChsYXN0R29vZEtub3duUmVzdWx0LCBsYXN0R29vZEtub3duUmVzdWx0SW5kZXgsIHBhc3RlZFRleHRbcGFzdGVkVGV4dEluZGV4XSk7XG5cbiAgICAgICAgICAgICAgICAgICAgLy8gQ2hlY2sgdGhlIHJhbmdlIGxpbWl0c1xuICAgICAgICAgICAgICAgICAgICBpZiAoIWNoZWNrSWZJblJhbmdlKHJlc3VsdCwgbWluUGFyc2UsIG1heFBhcnNlKSkge1xuICAgICAgICAgICAgICAgICAgICAgICAgLy8gVGhlIHJlc3VsdCBpcyBvdXQgb2YgdGhlIHJhbmdlIGxpbWl0cywgc3RvcCB0aGUgbG9vcCBoZXJlXG4gICAgICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgICAgICAgIC8vIFNhdmUgdGhlIGxhc3QgZ29vZCBrbm93biByZXN1bHRcbiAgICAgICAgICAgICAgICAgICAgbGFzdEdvb2RLbm93blJlc3VsdCA9IHJlc3VsdDtcblxuICAgICAgICAgICAgICAgICAgICAvLyBVcGRhdGUgdGhlIGxvY2FsIHZhcmlhYmxlcyBmb3IgdGhlIG5leHQgbG9vcFxuICAgICAgICAgICAgICAgICAgICBwYXN0ZWRUZXh0SW5kZXgrKztcbiAgICAgICAgICAgICAgICAgICAgbGFzdEdvb2RLbm93blJlc3VsdEluZGV4Kys7XG4gICAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgICAgLy8gVXBkYXRlIHRoZSBsYXN0IGNhcmV0IHBvc2l0aW9uIHdoZXJlIHRvIGluc2VydCBhIG5ldyBudW1iZXJcbiAgICAgICAgICAgICAgICBjYXJldFBvc2l0aW9uT25Jbml0aWFsVGV4dEFmdGVyUGFzdGluZyA9IGxhc3RHb29kS25vd25SZXN1bHRJbmRleDtcblxuICAgICAgICAgICAgICAgIGlmIChsZWZ0UGFydENvbnRhaW5lZEFEb3QpIHtcbiAgICAgICAgICAgICAgICAgICAgLy8gSWYgYSBkb3QgaGFzIGJlZW4gcmVtb3ZlZCBmb3IgdGhlIHBhcnQgb24gdGhlIGxlZnQgb2YgdGhlIGNhcmV0LCB3ZSBkZWNyZW1lbnQgdGhlIGNhcmV0IGluZGV4IHBvc2l0aW9uXG4gICAgICAgICAgICAgICAgICAgIGNhcmV0UG9zaXRpb25PbkluaXRpYWxUZXh0QWZ0ZXJQYXN0aW5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ICAgICAgICAgfVxuXG4gICAgICAgICAgICAgICAgICAgIGlmIChsZWZ0UGFydENvbnRhaW5lZEFEb3QpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIC8vIElmIGEgZG90IGhhcyBiZWVuIHJlbW92ZWQgZm9yIHRoZSBwYXJ0IG9uIHRoZSBsZWZ0IG9mIHRoZSBjYXJldCwgd2UgZGVjcmVtZW50IHRoZSBjYXJldCBpbmRleCBwb3NpdGlvblxuICAgICAgICAgICAgICAgICAgICAgICAgY2FyZXRQb3NpdGlvbk9uSW5pdGlhbFRleHRBZnRlclBhc3RpbmctLTtcbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgfVxuXG4gICAgICAgIC8vIDUuIENoZWNrIGlmIHRoZSByZXN1bHQgaXMgYSB2YWxpZCBudW1iZXIsIGlmIG5vdCwgZHJvcCB0aGUgcGFzdGUgYW5kIGRvIG5vdGhpbmcuXG4gICAgICAgIGlmICghaXNOdW1iZXIocmVzdWx0KSB8fCByZXN1bHQgPT09ICcnKSB7XG4gICAgICAgICAgICBpZiAoaG9sZGVyLnNldHRpbmdzLm9uSW52YWxpZFBhc3RlID09PSAnZXJyb3InKSB7XG4gICAgICAgICAgICAgICAgdGhyb3dFcnJvcihgVGhlIHBhc3RlZCB2YWx1ZSAnJHtyYXdQYXN0ZWRUZXh0fScgd291bGQgcmVzdWx0IGludG8gYW4gaW52YWxpZCBjb250ZW50ICcke3Jlc3VsdH0nLmApOyAvL1RPRE8gU2hvdWxkIHdlIHNlbmQgYSB3YXJuaW5nIGluc3RlYWQgb2YgdGhyb3dpbmcgYW4gZXJyb3I/XG4gICAgICAgICAgICAgICAgLy9UT0RPIFRoaXMgaXMgbm90IERSWSA7IHJlZmFjdG9yIHdpdGggYWJvdmVcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIHJldHVybjtcbiAgICAgICAgfVxuXG4gICAgICAgIC8vIDYuIElmIGl0J3MgYSB2YWxpZCB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HMsIGtlZXAgdGhlIGxhc3Qga25vd24gbm9uLWZhaWxpbmcgcmVzdWx0LlxuICAgICAgICAgKiAgICAgIC0gQ2hhbmdlIHRoZSBjYXJldCBwb3NpdGlvbiB0byBiZSBwb3NpdGlvbmVkIGFmdGVyIHRoZSBsYXN0IHBhc3RlZCBjaGFyYWN0ZXIuXG4gICAgICAgICAqL1xuICAgICAgICBsZXQgdmFsdWVIYXNCZWVuU2V0ID0gZmFsc2U7XG4gICAgICAgIGxldCB2YWx1ZUhhc0JlZW5DbGFtcGVkID0gZmFsc2U7XG4gICAgICAgIHRyeSB7XG4gICAgICAgICAgICAkdGhpcy5hdXRvTnVtZXJpYygnc2V0JywgcmVzdWx0KTtcbiAgICAgICAgICAgIHZhbHVlSGFzQmVlblNldCA9IHRydWU7XG4gICAgICAgIH1cbiAgICAgICAgY2F0Y2ggKGVycm9yKSB7XG4gICAgICAgICAgICBsZXQgY2xhbXBlZFZhbHVlO1xuICAgICAgICAgICAgc3dpdGNoIChob2xkZXIuc2V0dGluZ3Mub25JbnZhbGlkUGFzdGUpIHtcbiAgICAgICAgICAgICAgICBjYXNlICdjbGFtcCc6XG4gICAgICAgICAgICAgICAgICAgIGNsYW1wZWRWYWx1ZSA9IGNsYW1wVG9SYW5nZUxpbWl0cyhyZXN1bHQsIGhvbGRlci5zZXR0aW5ncyk7XG4gICAgICAgICAgICAgICAgICAgIHRyeSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAkdGhpcy5hdXRvTnVtZXJpYygnc2V0JywgY2xhbXBlZFZhbHVlKTtcbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICBjYXRjaCAoZXJyb3IpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIHRocm93RXJyb3IoYEZhdGFsIGVycm9yOiBVbmFibGUgdG8gc2V0IHRoZSBjbGFtcGVkIHZhbHVlICcke2NsYW1wZWRWYWx1ZX0nLmApO1xuICAgICAgICAgICAgICAgICAgICB9XG5cbiAgICAgICAgICAgICAgICAgICAgdmFsdWVIYXNCZWVuQ2xhbXBlZCA9IHRydWU7XG4gICAgICAgICAgICAgICAgICAgIHZhbHVlSGFzQmVlblNldCA9IHRydWU7XG4gICAgICAgICAgICAgICAgICAgIHJlc3VsdCA9IGNsYW1wZWRWYWx1ZTsgLy8gVGhpcyBpcyB1c2VkIG9ubHkgZm9yIHNldHRpbmcgdGhlIGNhcmV0IHBvc2l0aW9uIGxhdGVyXG4gICAgICAgICAgICAgICAgICAgIGJyZWFrO1xuICAgICAgICAgICAgICAgIGNhc2UgJ2Vycm9yJzpcbiAgICAgICAgICAgICAgICBjYXNlICd0cnVuY2F0ZSc6XG4gICAgICAgICAgICAgICAgY2FzZSAncmVwbGFjZSc6XG4gICAgICAgICAgICAgICAgICAgIC8vIFRocm93IGFuIGVycm9yIG1lc3NhZ2VcbiAgICAgICAgICAgICAgICAgICAgdGhyb3dFcnJvcihgVGhlIHBhc3RlZCB2YWx1ZSAnJHtyYXdQYXN0ZWRUZXh0fScgcmVzdWx0cyBpbiBhIHZhbHVlICcke3Jlc3VsdH0nIHRoYXQgaXMgb3V0c2lkZSBvZiB0aGUgbWluaW11bSBbJHtob2xkZXIuc2V0dGluZ3MubWluaW11bVZhbHVlfV0gYW5kIG1heGltdW0gWyR7aG9sZGVyLnNldHRpbmdzLm1heGltdW1WYWx1ZX1dIHZhbHVlIHJhbmdlLmApO1xuICAgICAgICAgICAgICAgIC8vIGZhbGxzIHRocm91Z2hcbiAgICAgICAgICAgICAgICBjYXNlICdpZ25vcmUnOlxuICAgICAgICAgICAgICAgIC8vIERvIG5vdGhpbmdcbiAgICAgICAgICAgICAgICAvLyBmYWxscyB0aHJvdWdoXG4gICAgICAgICAgICAgICAgZGVmYXVsdCA6XG4gICAgICAgICAgICAgICAgICAgIHJldHVybjsgLy8gLi4uYW5kIG5vdGhpbmcgZWxzZSBzaG91bGQgYmUgY2hhbmdlZFxuICAgICAgICAgICAgfVxuICAgICAgICB9XG5cbiA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gICAgICAgICAgICAgICAgIChzZXR0aW5ncy5zY2FsZURpdmlzb3IgJiYgc2V0dGluZ3Muc2F2ZVZhbHVlVG9TZXNzaW9uU3RvcmFnZSkpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIHNldHRpbmdzLnJhd1ZhbHVlID0gc2F2ZVZhbHVlVG9QZXJzaXN0ZW50U3RvcmFnZSgkdGhpc1swXSwgc2V0dGluZ3MsICdnZXQnKTtcbiAgICAgICAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgICAgICAgIC8vIElmIHRoZSBkZWNpbWFsUGxhY2VzU2hvd25PbkZvY3VzIHZhbHVlIHNob3VsZCBOT1QgYmUgc2F2ZWQgaW4gc2Vzc2lvblN0b3JhZ2VcbiAgICAgICAgICAgICAgICAgICAgaWYgKCFzZXR0aW5ncy5zYXZlVmFsdWVUb1Nlc3Npb25TdG9yYWdlKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBsZXQgdG9TdHJpcDtcblxuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKHNldHRpbmdzLm5lZ2F0aXZlQnJhY2tldHNUeXBlT25CbHVyICE9PSBudWxsICYmIHNldHRpbmdzLm5lZ2F0aXZlU2lnbkNoYXJhY3RlciAhPT0gJycpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZXR0aW5ncy5oYXNGb2N1cyA9IHRydWU7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdG9TdHJpcCA9IHRvZ2dsZU5lZ2F0aXZlQnJhY2tldChjdXJyZW50VmFsdWUsIHNldHRpbmdzKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdG9TdHJpcCA9IGN1cnJlbnRWYWx1ZTtcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKChzZXR0aW5ncy5uZWdhdGl2ZVBvc2l0aXZlU2lnblBsYWNlbWVudCA9PT0gJ3MnIHx8XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgKHNldHRpbmdzLm5lZ2F0aXZlUG9zaXRpdmVTaWduUGxhY2VtZW50ICE9PSAncCcgJiYgc2V0dGluZ3MuY3VycmVuY3lTeW1ib2xQbGFjZW1lbnQgPT09ICdzJykpICYmXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgc2V0dGluZ3MubmVnYXRpdmVTaWduQ2hhcmFjdGVyICE9PSAnJyAmJlxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlzTmVnYXRpdmUoY3VycmVudFZhbHVlKSkge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNldHRpbmdzLnJhd1ZhbHVlID0gc2V0dGluZ3MubmVnYXRpdmVTaWduQ2hhcmFjdGVyICsgc3RyaXBBbGxOb25OdW1iZXJDaGFyYWN0ZXJzKHRvU3RyaXAsIHNldHRpbmdzLCB0cnVlKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgc2V0dGluZ3MucmF3VmFsdWUgPSBzdHJpcEFsbE5vbk51bWJlckNoYXJhY3RlcnModG9TdHJpcCwgc2V0dGluZ3MsIHRydWUpO1xuICAgICAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICB9XG5cbiAgICAgICAgICAgICAgICAgICAgc2V0VmFsdWUgPSBmYWxzZTtcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9XG5cbiAgICAgICAgICAgIGlmIChjdXJyZW50VmFsdWUgPT09ICcnKSB7XG4gICAgICAgICAgICAgICAgc3dpdGNoIChzZXR0aW5ncy5lbXB0eUlucHV0QmVoYXZpb3IpIHtcbiAgICAgICAgICAgICAgICAgICAgY2FzZSAnZm9jdXMnOlxuICAgICAgICAgICAgICAgICAgICAgICAgc2V0VmFsdWUgPSBmYWxzZTtcbiAgICAgICAgICAgICAgICAgICAgICAgIGJyZWFrO1xuICAgICAgICAgICAgICAgICAgICBjYXNlICdhbHdheXMnOlxuICAgICAgICAgICAgICAgICAgICAgICAgJHRoaXMudmFsKHNldHRpbmdzLmN1cnJlbmN5U3ltYm9sKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIHNldFZhbHVlID0gZmFsc2U7XG4gICAgICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICAgICAgY2FzZSAnemVybyc6XG4gICAgICAgICAgICAgICAgICAgICAgICAkdGhpcy5hdXRvTnVtZXJpYygnc2V0JywgJzAnKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIHNldFZhbHVlID0gZmFsc2U7XG4gICAgICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICAgICAgZGVmYXVsdCA6XG4gICAgICAgICAgICAgICAgICAgIC8vXG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgfSBlbHNlIGlmIChzZXRWYWx1ZSAmJiBjdXJyZW50VmFsdWUgPT09ICR0aGlzLmF0dHIoJ3ZhbHVlJykpIHtcbiAgICAgICAgICAgICAgICAkdGhpcy5hdXRvTnVtZXJpYygnc2V0JywgY3VycmVudFZhbHVlKTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgfVxuXG4gICAgICAgIGlmIChpc0luQXJyYXkoJHRoaXMucHJvcCgndGFnTmFtZScpLnRvTG93ZXJDYXNlKCksIHNldHRpbmdzLnRhZ0xpc3QpICYmICR0aGlzLnRleHQoKSAhPT0gJycpIHtcbiAgICAgICAgICAgIGlmIChzZXR0aW5ncy5kZWZhdWx0VmFsdWVPdmVycmlkZSAhPT0gbnVsbCkge1xuICAgICAgICAgICAgICAgIGlmIChzZXR0aW5ncy5kZWZhdWx0VmFsdWVPdmVycmlkZSA9PT0gJHRoaXMudGV4dCgpKSB7XG4gICAgICAgICAgICAgICAgICAgICR0aGlzLmF1dG9OdW1lcmljKCdzZXQnLCAkdGhpcy50ZXh0KCkpO1xuICAgICA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RpbmdzIG9wdGlvbnMgbmFtZSB0byBuZXcgb25lcy5cbiAgICAgKlxuICAgICAqIEBwYXJhbSB7b2JqZWN0fSBvcHRpb25zXG4gICAgICovXG4gICAgZnVuY3Rpb24gY29udmVydE9sZE9wdGlvbnNUb05ld09uZXMob3B0aW9ucykge1xuICAgICAgICAvL1RPRE8gRGVsZXRlIHRoaXMgZnVuY3Rpb24gb25jZSB0aGUgb2xkIG9wdGlvbnMgYXJlIG5vdCB1c2VkIGFueW1vcmVcbiAgICAgICAgY29uc3Qgb2xkT3B0aW9uc0NvbnZlcnRlciA9IHtcbiAgICAgICAgICAgIC8vIE9sZCBvcHRpb24gbmFtZSwgd2l0aCB0aGVpciBjb3JyZXNwb25kaW5nIG5ldyBvcHRpb25cbiAgICAgICAgICAgIGFTZXAgICAgICAgICAgICAgICAgICAgICAgICAgOiAnZGlnaXRHcm91cFNlcGFyYXRvcicsXG4gICAgICAgICAgICBuU2VwICAgICAgICAgICAgICAgICAgICAgICAgIDogJ25vU2VwYXJhdG9yT25Gb2N1cycsXG4gICAgICAgICAgICBkR3JvdXAgICAgICAgICAgICAgICAgICAgICAgIDogJ2RpZ2l0YWxHcm91cFNwYWNpbmcnLFxuICAgICAgICAgICAgYURlYyAgICAgICAgICAgICAgICAgICAgICAgICA6ICdkZWNpbWFsQ2hhcmFjdGVyJyxcbiAgICAgICAgICAgIGFsdERlYyAgICAgICAgICAgICAgICAgICAgICAgOiAnZGVjaW1hbENoYXJhY3RlckFsdGVybmF0aXZlJyxcbiAgICAgICAgICAgIGFTaWduICAgICAgICAgICAgICAgICAgICAgICAgOiAnY3VycmVuY3lTeW1ib2wnLFxuICAgICAgICAgICAgcFNpZ24gICAgICAgICAgICAgICAgICAgICAgICA6ICdjdXJyZW5jeVN5bWJvbFBsYWNlbWVudCcsXG4gICAgICAgICAgICBwTmVnICAgICAgICAgICAgICAgICAgICAgICAgIDogJ25lZ2F0aXZlUG9zaXRpdmVTaWduUGxhY2VtZW50JyxcbiAgICAgICAgICAgIGFTdWZmaXggICAgICAgICAgICAgICAgICAgICAgOiAnc3VmZml4VGV4dCcsXG4gICAgICAgICAgICBvTGltaXRzICAgICAgICAgICAgICAgICAgICAgIDogJ292ZXJyaWRlTWluTWF4TGltaXRzJyxcbiAgICAgICAgICAgIHZNYXggICAgICAgICAgICAgICAgICAgICAgICAgOiAnbWF4aW11bVZhbHVlJyxcbiAgICAgICAgICAgIHZNaW4gICAgICAgICAgICAgICAgICAgICAgICAgOiAnbWluaW11bVZhbHVlJyxcbiAgICAgICAgICAgIG1EZWMgICAgICAgICAgICAgICAgICAgICAgICAgOiAnZGVjaW1hbFBsYWNlc092ZXJyaWRlJyxcbiAgICAgICAgICAgIGVEZWMgICAgICAgICAgICAgICAgICAgICAgICAgOiAnZGVjaW1hbFBsYWNlc1Nob3duT25Gb2N1cycsXG4gICAgICAgICAgICBzY2FsZURlY2ltYWwgICAgICAgICAgICAgICAgIDogJ3NjYWxlRGVjaW1hbFBsYWNlcycsXG4gICAgICAgICAgICBhU3RvciAgICAgICAgICAgICAgICAgICAgICAgIDogJ3NhdmVWYWx1ZVRvU2Vzc2lvblN0b3JhZ2UnLFxuICAgICAgICAgICAgbVJvdW5kICAgICAgICAgICAgICAgICAgICAgICA6ICdyb3VuZGluZ01ldGhvZCcsXG4gICAgICAgICAgICBhUGFkICAgICAgICAgICAgICAgICAgICAgICAgIDogJ2FsbG93RGVjaW1hbFBhZGRpbmcnLFxuICAgICAgICAgICAgbkJyYWNrZXQgICAgICAgICAgICAgICAgICAgICA6ICduZWdhdGl2ZUJyYWNrZXRzVHlwZU9uQmx1cicsXG4gICAgICAgICAgICB3RW1wdHkgICAgICAgICAgICAgICAgICAgICAgIDogJ2VtcHR5SW5wdXRCZWhhdmlvcicsXG4gICAgICAgICAgICBsWmVybyAgICAgICAgICAgICAgICAgICAgICAgIDogJ2xlYWRpbmdaZXJvJyxcbiAgICAgICAgICAgIGFGb3JtICAgICAgICAgICAgICAgICAgICAgICAgOiAnZm9ybWF0T25QYWdlTG9hZCcsXG4gICAgICAgICAgICBzTnVtYmVyICAgICAgICAgICAgICAgICAgICAgIDogJ3NlbGVjdE51bWJlck9ubHknLFxuICAgICAgICAgICAgYW5EZWZhdWx0ICAgICAgICAgICAgICAgICAgICA6ICdkZWZhdWx0VmFsdWVPdmVycmlkZScsXG4gICAgICAgICAgICB1blNldE9uU3VibWl0ICAgICAgICAgICAgICAgIDogJ3VuZm9ybWF0T25TdWJtaXQnLFxuICAgICAgICAgICAgb3V0cHV0VHlwZSAgICAgICAgICAgICAgICAgICA6ICdvdXRwdXRGb3JtYXQnLFxuICAgICAgICAgICAgZGVidWcgICAgICAgICAgICAgICAgICAgICAgICA6ICdzaG93V2FybmluZ3MnLFxuICAgICAgICAgICAgLy8gQ3VycmVudCBvcHRpb25zIDpcbiAgICAgICAgICAgIGRpZ2l0R3JvdXBTZXBhcmF0b3IgICAgICAgICAgOiB0cnVlLFxuICAgICAgICAgICAgbm9TZXBhcmF0b3JPbkZvY3VzICAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICBkaWdpdGFsR3JvdXBTcGFjaW5nICAgICAgICAgIDogdHJ1ZSxcbiAgICAgICAgICAgIGRlY2ltYWxDaGFyYWN0ZXIgICAgICAgICAgICAgOiB0cnVlLFxuICAgICAgICAgICAgZGVjaW1hbENoYXJhY3RlckFsdGVybmF0aXZlICA6IHRydWUsXG4gICAgICAgICAgICBjdXJyZW5jeVN5bWJvbCAgICAgICAgICAgICAgIDogdHJ1ZSxcbiAgICAgICAgICAgIGN1cnJlbmN5U3ltYm9sUGxhY2VtZW50ICAgICAgOiB0cnVlLFxuICAgICAgICAgICAgbmVnYXRpdmVQb3NpdGl2ZVNpZ25QbGFjZW1lbnQ6IHRydWUsXG4gICAgICAgICAgICBzaG93UG9zaXRpdmVTaWduICAgICAgICAgICAgIDogdHJ1ZSxcbiAgICAgICAgICAgIHN1ZmZpeFRleHQgICAgICAgICAgICAgICAgICAgOiB0cnVlLFxuICAgICAgICAgICAgb3ZlcnJpZGVNaW5NYXhMaW1pdHMgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICBtYXhpbXVtVmFsdWUgICAgICAgICAgICAgICAgIDogdHJ1ZSxcbiAgICAgICAgICAgIG1pbmltdW1WYWx1ZSAgICAgICAgICAgICAgICAgOiB0cnVlLFxuICAgICAgICAgICAgZGVjaW1hbFBsYWNlc092ZXJyaWRlICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICBkZWNpbWFsUGxhY2VzU2hvd25PbkZvY3VzICAgIDogdHJ1ZSxcbiAgICAgICAgICAgIHNjYWxlRGl2aXNvciAgICAgICAgICAgICAgICAgOiB0cnVlLFxuICAgICAgICAgICAgc2NhbGVEZWNpbWFsUGxhY2VzICAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICBzY2FsZVN5bWJvbCAgICAgICAgICAgICAgICAgIDogdHJ1ZSxcbiAgICAgICAgICAgIHNhdmVWYWx1ZVRvU2Vzc2lvblN0b3JhZ2UgICAgOiB0cnVlLFxuICAgICAgICAgICAgb25JbnZhbGlkUGFzdGUgICAgICAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICByb3VuZGluZ01ldGhvZCAgICAgICAgICAgICAgIDogdHJ1ZSxcbiAgICAgICAgICAgIGFsbG93RGVjaW1hbFBhZGRpbmcgICAgICAgICAgOiB0cnVlLFxuICAgICAgICAgICAgbmVnYXRpdmVCcmFja2V0c1R5cGVPbkJsdXIgICA6IHRydWUsXG4gICAgICAgICAgICBlbXB0eUlucHV0QmVoYXZpb3IgICAgICAgICAgIDogdHJ1ZSxcbiAgICAgICAgICAgIGxlYWRpbmdaZXJvICAgICAgICAgICAgICAgICAgOiB0cnVlLFxuICAgICAgICAgICAgZm9ybWF0T25QYWdlTG9hZCAgICAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICBzZWxlY3ROdW1iZXJPbmx5ICAgICAgICAgICAgIDogdHJ1ZSxcbiAgICAgICAgICAgIGRlZmF1bHRWYWx1ZU92ZXJyaWRlICAgICAgICAgOiB0cnVlLFxuICAgICAgICAgICAgdW5mb3JtYXRPblN1Ym1pdCAgICAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICBvdXRwdXRGb3JtYXQgICAgICAgICAgICAgICAgIDogdHJ1ZSxcbiAgICAgICAgICAgIHNob3dXYXJuaW5ncyAgICAgICAgICAgICAgICAgOiB0cnVlLFxuICAgICAgICAgICAgZmFpbE9uVW5rbm93bk9wdGlvbiAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICAvL0ZJWE1FIEZpbmQgYSB3YXkgdG8gZXhjbHVkZSB0aG9zZSBpbnRlcm5hbCBkYXRhIGZyb20gdGhlIHNldHRpbmdzIG9iamVjdCAoaWRlYWxseSBieSB1c2luZyBhbm90aGVyIG9iamVjdCwgb3IgYmV0dGVyIHlldCwgY2xhc3MgYXR0cmlidXRlcykgLS0+XG4gICAgICAgICAgICBoYXNGb2N1cyAgICAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICBydW5PbmNlICAgICAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICByYXdWYWx1ZSAgICAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICB0cmFpbGluZ05lZ2F0aXZlICAgICA6IHRydWUsXG4gICAgICAgICAgICBjYXJldEZpeCAgICAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICB0aHJvd0lucHV0ICAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICBzdHJpcCAgICAgICAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICB0YWdMaXN0ICAgICAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICBuZWdhdGl2ZVNpZ25DaGFyYWN0ZXI6IHRydWUsXG4gICAgICAgICAgICBwb3NpdGl2ZVNpZ25DaGFyYWN0ZXI6IHRydWUsXG4gICAgICAgICAgICBtSW50UG9zICAgICAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICBtSW50TmVnICAgICAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICBvRGVjICAgICAgICAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICBvUGFkICAgICAgICAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICBvQnJhY2tldCAgICAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICBvU2VwICAgICAgICAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICBvU2lnbiAgICAgICAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICBvU3VmZml4ICAgICAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICBhTmVnUmVnQXV0b1N0cmlwICAgICA6IHRydWUsXG4gICAgICAgICAgICBza2lwRmlyc3RBdXRvU3RyaXAgICA6IHRydWUsXG4gICAgICAgICAgICBza2lwTGFzdEF1dG9TdHJpcCAgICA6IHRydWUsXG4gICAgICAgICAgICBhbGxvd2VkQXV0b1N0cmlwICAgICA6IHRydWUsXG4gICAgICAgICAgICBudW1SZWdBdXRvU3RyaXAgICAgICA6IHRydWUsXG4gICAgICAgICAgICBzdHJpcFJlZyAgICAgICAgICAgICA6IHRydWUsXG4gICAgICAgICAgICBob2xkZXIgICAgICAgICAgICAgICA6IHRydWUsXG4gICAgICAgIH07XG5cbiAgICAgICAgZm9yIChjb25zdCBvcHRpb24gaW4gb3B0aW9ucykge1xuICAgICAgICAgICAgaWYgKG9wdGlvbnMuaGFzT3duUHJvcGVydHkob3B0aW9uKSkge1xuICAgICAgICAgICAgICAgIGlmIChvbGRPcHRpb25zQ29udmVydGVyW29wdGlvbl0gPT09IHRydWUpIHtcbiAgICAgICAgICAgICAgICAgICAgLy8gSWYgdGhlIG9wdGlvbiBpcyBhICduZXcnIG9wdGlvbiwgd2UgY29udGludWUgbG9vcGluZ1xuICAgICAgICAgICAgICAgICAgICBjb250aW51ZTtcbiAgICAgICAgICAgICAgICB9XG5cbiAgICAgICAgICAgICAgICBpZiAob2xkT3B0aW9uc0NvbnZlcnRlci5oYXNPd25Qcm9wZX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ICAgICBjb25zdCBzZXR0aW5ncyA9ICR0aGlzLmRhdGEoJ2F1dG9OdW1lcmljJyk7XG4gICAgICAgICAgICAgICAgaWYgKHR5cGVvZiBzZXR0aW5ncyA9PT0gJ29iamVjdCcpIHtcbiAgICAgICAgICAgICAgICAgICAgJHRoaXMudmFsKCcnKTtcbiAgICAgICAgICAgICAgICAgICAgc2F2ZVZhbHVlVG9QZXJzaXN0ZW50U3RvcmFnZSgkdGhpc1swXSwgc2V0dGluZ3MsICd3aXBlJyk7XG4gICAgICAgICAgICAgICAgICAgICR0aGlzLnJlbW92ZURhdGEoJ2F1dG9OdW1lcmljJyk7XG4gICAgICAgICAgICAgICAgICAgICR0aGlzLm9mZignLmF1dG9OdW1lcmljJyk7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgfSk7XG4gICAgICAgIH0sXG5cbiAgICAgICAgLyoqXG4gICAgICAgICAqIE1ldGhvZCB0byBjbGVhciB0aGUgdmFsdWUgZnJvbSBzZXNzaW9uU3RvcmFnZSAob3IgY29va2llLCBkZXBlbmRpbmcgb24gYnJvd3NlciBzdXBwb3J0cykuXG4gICAgICAgICAqXG4gICAgICAgICAqIEBleGFtcGxlICQoc29tZVNlbGVjdG9yKS5hdXRvTnVtZXJpYyhcIndpcGVcIik7IC8vIFJlbW92ZXMgc2Vzc2lvbiBzdG9yYWdlIGFuZCBjb29raWVzIGZyb20gbWVtb3J5XG4gICAgICAgICAqXG4gICAgICAgICAqIEByZXR1cm5zIHsqfGpRdWVyeX1cbiAgICAgICAgICovXG4gICAgICAgIHdpcGUoKSB7XG4gICAgICAgICAgICByZXR1cm4gJCh0aGlzKS5lYWNoKGZ1bmN0aW9uKCkge1xuICAgICAgICAgICAgICAgIGNvbnN0ICR0aGlzID0gZ2V0Q3VycmVudEVsZW1lbnQodGhpcyk7XG4gICAgICAgICAgICAgICAgY29uc3Qgc2V0dGluZ3MgPSAkdGhpcy5kYXRhKCdhdXRvTnVtZXJpYycpO1xuICAgICAg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zICE9PSAnb2JqZWN0Jykge1xuICAgICAgICAgICAgICAgICAgICB0aHJvd0Vycm9yKGBJbml0aWFsaXppbmcgYXV0b051bWVyaWMgaXMgcmVxdWlyZWQgcHJpb3IgdG8gY2FsbGluZyB0aGUgXCJzZXRcIiBtZXRob2QuYCk7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIC8vIFJlc2V0IHRoZSB0cmFpbGluZyBuZWdhdGl2ZSBzZXR0aW5ncywgc2luY2UgaXQncyBwb3NzaWJsZSB0aGUgcHJldmlvdXMgdmFsdWUgd2FzIG5lZ2F0aXZlLCBidXQgbm90IHRoZSBuZXdseSBzZXQgb25lXG4gICAgICAgICAgICAgICAgc2V0dGluZ3MudHJhaWxpbmdOZWdhdGl2ZSA9IGZhbHNlO1xuXG4gICAgICAgICAgICAgICAgY29uc3QgJGlucHV0ID0gJHRoaXMuaXMoJ2lucHV0W3R5cGU9dGV4dF0sIGlucHV0W3R5cGU9aGlkZGVuXSwgaW5wdXRbdHlwZT10ZWxdLCBpbnB1dDpub3QoW3R5cGVdKScpO1xuXG4gICAgICAgICAgICAgICAgbGV0IHZhbHVlID0gdG9OdW1lcmljVmFsdWUobmV3VmFsdWUsIHNldHRpbmdzKTtcbiAgICAgICAgICAgICAgICBpZiAoaXNOYU4odmFsdWUpKSB7XG4gICAgICAgICAgICAgICAgICAgIHJldHVybiAkdGhpcy52YWwoJycpO1xuICAgICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAgIGlmICh2YWx1ZSAhPT0gJycpIHtcbiAgICAgICAgICAgICAgICAgICAgY29uc3QgW21pblRlc3QsIG1heFRlc3RdID0gY2hlY2tJZkluUmFuZ2VXaXRoT3ZlcnJpZGVPcHRpb24odmFsdWUsIHNldHRpbmdzKTtcbiAgICAgICAgICAgICAgICAgICAgLy8gVGhpcyB0ZXN0IGlzIG5lZWRlZCBieSB0aGUgc2hvd1Bvc2l0aXZlU2lnbiBvcHRpb25cbiAgICAgICAgICAgICAgICAgICAgY29uc3QgaXNaZXJvID0gaXNaZXJvT3JIYXNOb1ZhbHVlKHZhbHVlKTtcbiAgICAgICAgICAgICAgICAgICAgaWYgKGlzWmVybykge1xuICAgICAgICAgICAgICAgICAgICAgICAgdmFsdWUgPSAnMCc7XG4gICAgICAgICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAgICAgICBpZiAobWluVGVzdCAmJiBtYXhUZXN0KSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoJGlucHV0IHx8IGlzSW5BcnJheSgkdGhpcy5wcm9wKCd0YWdOYW1lJykudG9Mb3dlckNhc2UoKSwgc2V0dGluZ3MudGFnTGlzdCkpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAvLyB0byBlbnN1cmUgcm91bmRpbmcgZG9lcyBub3QgaGFwcGVuIHR3aWNlXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgbGV0IGhhc0JlZW5Sb3VuZGVkID0gZmFsc2U7XG5cbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAvLyByb3VuZHMgdGhlIHRoZSBleHRlbmRlZCBkZWNpbWFsIHBsYWNlc1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGxldCB0ZW1wRGVjaW1hbDtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAoc2V0dGluZ3MuZGVjaW1hbFBsYWNlc1Nob3duT25Gb2N1cykge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB0ZW1wRGVjaW1hbCA9IHNldHRpbmdzLmRlY2ltYWxQbGFjZXNPdmVycmlkZTtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc2V0dGluZ3MuZGVjaW1hbFBsYWNlc092ZXJyaWRlID0gTnVtYmVyKHNldHRpbmdzLmRlY2ltYWxQbGFjZXNTaG93bk9uRm9jdXMpO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YWx1ZSA9IHJvdW5kVmFsdWUodmFsdWUsIHNldHRpbmdzKTtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaGFzQmVlblJvdW5kZWQgPSB0cnVlO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZXR0aW5ncy5kZWNpbWFsUGxhY2VzT3ZlcnJpZGUgPSB0ZW1wRGVjaW1hbDtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XG5cbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAoc2V0dGluZ3Muc2NhbGVEaXZpc29yICYmICFzZXR0aW5ncy5vbk9mZikge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YWx1ZSA9IHJvdW5kVmFsdWUodmFsdWUsIHNldHRpbmdzKTtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc2V0dGluZ3MucmF3VmFsdWUgPSBjbGVhbkxlYWRpbmdUcmFpbGluZ1plcm9zKHZhbHVlLnJlcGxhY2Uoc2V0dGluZ3MuZGVjaW1hbENoYXJhY3RlciwgJy4nKSwgc2V0dGluZ3MpO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YWx1ZSA9IHRvTnVtZXJpY1ZhbHVlKHZhbHVlLCBzZXR0aW5ncyk7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhbHVlID0gdmFsdWUgLyBzZXR0aW5ncy5zY2FsZURpdmlzb3I7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhbHVlID0gdmFsdWUudG9TdHJpbmcoKTtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYgKHNldHRpbmdzLnNjYWxlRGVjaW1hbFBsYWNlcykge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdGVtcERlY2ltYWwgPSBzZXR0aW5ncy5kZWNpbWFsUGxhY2VzT3ZlcnJpZGU7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZXR0aW5ncy5kZWNpbWFsUGxhY2VzT3ZlcnJpZGUgPSBOdW1iZXIoc2V0dGluZ3Muc2NhbGVEZWNpbWFsUGxhY2VzKTtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhbHVlID0gcm91bmRWYWx1ZSh2YWx1ZSwgc2V0dGluZ3MpO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaGFzQmVlblJvdW5kZWQgPSB0cnVlO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgLy8gUm91bmRzIGlmIHRoaXMgaGFzIG5vdCBiZWVuIGRvbmUgYWxyZWFkeVxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmICghaGFzQmVlblJvdW5kZWQpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdmFsdWUgPSByb3VuZFZhbHVlKHZhbHVlLCBzZXR0aW5ncyk7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgLy8gU3RvcmVzIHJhd1ZhbHVlIGluY2x1ZGluZyB0aGUgZGVjaW1hbFBsYWNlc1Nob3duT25Gb2N1c1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmICghc2V0dGluZ3Muc2NhbGVEaXZpc29yKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNldHRpbmdzLnJhd1ZhbHVlID0gY2xlYW5MZWFkaW5nVHJhaWxpbmdaZXJvcyh2YWx1ZS5yZXBsYWNlKHNldHRpbmdzLmRlY2ltYWxDaGFyYWN0ZXIsICcuJyksIHNldHRpbmdzKTtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XG5cbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB2YWx1ZSA9IG1vZGlmeU5lZ2F0aXZlU2lnbkFuZERlY2ltYWxDaGFyYWN0ZXJGb3JGb3JtYXR0ZWRWYWx1ZSh2YWx1ZSwgc2V0dGluZ3MpO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHZhbHVlID0gYWRkR3JvdXBTZXBhcmF0b3JzKHZhbHVlLCBzZXR0aW5ncyk7XG5cbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAoc2V0dGluZ3Muc2NhbGVEaXZpc29yICYmIHNldHRpbmdzLnNjYWxlRGVjaW1hbFBsYWNlcyAmJiAhc2V0dGluZ3Mub25PZmYpIHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc2V0dGluZ3MuZGVjaW1hbFBsYWNlc092ZXJyaWRlID0gdGVtcERlY2ltYWw7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoc2V0dGluZ3Muc2F2ZVZhbHVlVG9TZXNzaW9uU3RvcmFnZSAmJiAoc2V0dGluZ3MuZGVjaW1hbFBsYWNlc1Nob3duT25Gb2N1cyB8fCBzZXR0aW5ncy5zY2FsZURpdmlzb3IpKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgc2F2ZVZhbHVlVG9QZXJzaXN0ZW50U3RvcmFnZSgkdGhpc1swXSwgc2V0dGluZ3MsICdzZXQnKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIHNldHRpbmdzLnJhd1ZhbHVlID0gJyc7XG4gICAgICAgICAgICAgICAgICAgICAgICBzYXZlVmFsdWVUb1BlcnNpc3RlbnRTdG9yYWdlKCR0aGlzWzBdLCBzZXR0aW5ncywgJ3dpcGUnKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIGNvbnN0IGF0dGVtcHRlZFZhbHVlID0gdmFsdWU7XG4gICAgICAgICAgICAgICAgICAgICAgICB2YWx1ZSA9ICcnO1xuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKCFtaW5UZXN0KSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgJHRoaXMudHJpZ2dlcignYXV0b051bWVyaWM6bWluRXhjZWVkZWQnKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKCFtYXhUZXN0KSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgJHRoaXMudHJpZ2dlcignYXV0b051bWVyaWM6bWF4RXhjZWVkZWQnKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAgICAgICAgICAgdGhyb3dFcnJvcihgVGhlIHZhbHVlIFske2F0dGVtcHRlZFZhbHVlfV0gYmVpbmcgc2V0IGZhbGxzIG91dHNpZGUgb2YgdGhlIG1pbmltdW1WYWx1ZSBbJHtzZXR0aW5ncy5taW5pbXVtVmFsdWV9XSBhbmQgbWF4aW11bVZhbHVlIFske3NldHRpbmdzLm1heGltdW1WYWx1ZX1dIHJhbmdlIHNldCBmb3IgdGhpcyBlbGVtZW50YCk7XG5cbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiAkdGhpcy52YWwoJycpO1xuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuICR0aGlzLnZhbCgnJyk7XG4gICAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgICAgaWYgKCFzZXR0aW5ncy5oYXNGb2N1cyAmJiBzZXR0aW5ncy5zY2FsZVN5bWJvbCkge1xuICAgICAgICAgICAgICAgICAgICB2YWx1ZSA9IHZhbHVlICsgc2V0dGluZ3Muc2NhbGVTeW1ib2w7XG4gICAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgICAgaWYgKCRpbnB1dCkge1xuICAgICAgICAgICAgICAgICAgICByZXR1cm4gJHRoaXMudmFs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ovXG4gICAgICAgIHVuU2V0KCkge1xuICAgICAgICAgICAgcmV0dXJuICQodGhpcykuZWFjaChmdW5jdGlvbigpIHtcbiAgICAgICAgICAgICAgICBjb25zdCAkdGhpcyA9IGdldEN1cnJlbnRFbGVtZW50KHRoaXMpO1xuICAgICAgICAgICAgICAgIGNvbnN0IHNldHRpbmdzID0gJHRoaXMuZGF0YSgnYXV0b051bWVyaWMnKTtcbiAgICAgICAgICAgICAgICBpZiAodHlwZW9mIHNldHRpbmdzID09PSAnb2JqZWN0Jykge1xuICAgICAgICAgICAgICAgICAgICBzZXR0aW5ncy5oYXNGb2N1cyA9IHRydWU7XG4gICAgICAgICAgICAgICAgICAgICR0aGlzLnZhbCgkdGhpcy5hdXRvTnVtZXJpYygnZ2V0TG9jYWxpemVkJykpO1xuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgIH0pO1xuICAgICAgICB9LFxuXG4gICAgICAgIC8qKlxuICAgICAgICAgKiBNZXRob2QgdG8gcmUtZm9ybWF0IGlucHV0cy5cbiAgICAgICAgICogVGhpcyBpcyBoYW5keSB0byB1c2UgcmlnaHQgYWZ0ZXIgZm9ybSBzdWJtaXNzaW9uLlxuICAgICAgICAgKlxuICAgICAgICAgKiBUaGlzIGlzIGNhbGxlZCBhZnRlciB0aGUgJ3VuU2V0JyBtZXRob2QgdG8gcmVmb3JtYXQgdGhlIGlucHV0XG4gICAgICAgICAqXG4gICAgICAgICAqIEBleGFtcGxlICQoc29tZVNlbGVjdG9yKS5hdXRvTnVtZXJpYygncmVTZXQnKTtcbiAgICAgICAgICpcbiAgICAgICAgICogQHJldHVybnMgeyp8alF1ZXJ5fVxuICAgICAgICAgKi9cbiAgICAgICAgcmVTZXQoKSB7XG4gICAgICAgICAgICByZXR1cm4gJCh0aGlzKS5lYWNoKGZ1bmN0aW9uKCkge1xuICAgICAgICAgICAgICAgIGNvbnN0ICR0aGlzID0gZ2V0Q3VycmVudEVsZW1lbnQodGhpcyk7XG4gICAgICAgICAg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gICAgICAgICAgIGNvbnN0IHNldHRpbmdzID0gJHRoaXMuZGF0YSgnYXV0b051bWVyaWMnKTtcblxuICAgICAgICAgICAgaWYgKE51bWJlcih2YWx1ZSkgPT09IDAgJiYgc2V0dGluZ3MubGVhZGluZ1plcm8gIT09ICdrZWVwJykge1xuICAgICAgICAgICAgICAgIHZhbHVlID0gJzAnO1xuICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICByZXR1cm4gdG9Mb2NhbGUodmFsdWUsIHNldHRpbmdzLm91dHB1dEZvcm1hdCk7XG4gICAgICAgIH0sXG5cbiAgICAgICAgLyoqXG4gICAgICAgICAqIFJldHVybiB0aGUgaW5wdXQgdW5mb3JtYXR0ZWQgdmFsdWUgYXMgYSByZWFsIEphdmFzY3JpcHQgbnVtYmVyLlxuICAgICAgICAgKlxuICAgICAgICAgKiBAdXNhZ2UgJChzb21lU2VsZWN0b3IpLmF1dG9OdW1lcmljKCdnZXROdW1iZXInKTtcbiAgICAgICAgICpcbiAgICAgICAgICogQHJldHVybnMge251bWJlcn1cbiAgICAgICAgICovXG4gICAgICAgIGdldE51bWJlcigpIHtcbiAgICAgICAgICAgIGNvbnN0ICR0aGlzID0gZ2V0Q3VycmVudEVsZW1lbnQodGhpcyk7XG4gICAgICAgICAgICBjb25zdCB2YWx1ZSA9ICR0aGlzLmF1dG9OdW1lcmljKCdnZXQnKTtcblxuICAgICAgICAgICAgcmV0dXJuIHRvTG9jYWxlKHZhbHVlLCAnbnVtYmVyJyk7XG4gICAgICAgIH0sXG5cbiAgICAgICAgLyoqXG4gICAgICAgICAqIFJldHVybiB0aGUgY3VycmVudCBmb3JtYXR0ZWQgdmFsdWUgb2YgdGhlIGF1dG9OdW1lcmljIGVsZW1lbnQuXG4gICAgICAgICAqIEB1c2FnZSBhTklucHV0LmF1dG9OdW1lcmljKCdnZXRGb3JtYXR0ZWQnKSlcbiAgICAgICAgICpcbiAgICAgICAgICogQHJldHVybnMge3N0cmluZ31cbiAgICAgICAgICovXG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vbiksIFske29wdGlvbnMub25JbnZhbGlkUGFzdGV9XSBnaXZlbi5gKTtcbiAgICAgICAgfVxuXG4gICAgICAgIGlmICghaXNJbkFycmF5KG9wdGlvbnMucm91bmRpbmdNZXRob2QsIFtcbiAgICAgICAgICAgICdTJyxcbiAgICAgICAgICAgICdBJyxcbiAgICAgICAgICAgICdzJyxcbiAgICAgICAgICAgICdhJyxcbiAgICAgICAgICAgICdCJyxcbiAgICAgICAgICAgICdVJyxcbiAgICAgICAgICAgICdEJyxcbiAgICAgICAgICAgICdDJyxcbiAgICAgICAgICAgICdGJyxcbiAgICAgICAgICAgICdOMDUnLFxuICAgICAgICAgICAgJ0NIRicsXG4gICAgICAgICAgICAnVTA1JyxcbiAgICAgICAgICAgICdEMDUnLFxuICAgICAgICBdKSkge1xuICAgICAgICAgICAgdGhyb3dFcnJvcihgVGhlIHJvdW5kaW5nIG1ldGhvZCBvcHRpb24gJ3JvdW5kaW5nTWV0aG9kJyBpcyBpbnZhbGlkIDsgaXQgc2hvdWxkIGVpdGhlciBiZSAnUycsICdBJywgJ3MnLCAnYScsICdCJywgJ1UnLCAnRCcsICdDJywgJ0YnLCAnTjA1JywgJ0NIRicsICdVMDUnIG9yICdEMDUnIChjZi4gZG9jdW1lbnRhdGlvbiksIFske29wdGlvbnMucm91bmRpbmdNZXRob2R9XSBnaXZlbi5gKTtcbiAgICAgICAgfVxuXG4gICAgICAgIGlmICghaXNUcnVlT3JGYWxzZVN0cmluZyhvcHRpb25zLmFsbG93RGVjaW1hbFBhZGRpbmcpICYmICFpc0Jvb2xlYW4ob3B0aW9ucy5hbGxvd0RlY2ltYWxQYWRkaW5nKSkge1xuICAgICAgICAgICAgdGhyb3dFcnJvcihgVGhlIGNvbnRyb2wgZGVjaW1hbCBwYWRkaW5nIG9wdGlvbiAnYWxsb3dEZWNpbWFsUGFkZGluZycgaXMgaW52YWxpZCA7IGl0IHNob3VsZCBiZSBlaXRoZXIgJ2ZhbHNlJyBvciAndHJ1ZScs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_EXTERNAL_MODULE_1__;//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIndlYnBhY2s6Ly8vZXh0ZXJuYWwge1wicm9vdFwiOlwialF1ZXJ5XCIsXCJjb21tb25qc1wiOlwianF1ZXJ5XCIsXCJjb21tb25qczJcIjpcImpxdWVyeVwiLFwiYW1kXCI6XCJqcXVlcnlcIn0/NWNiYyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSIsImZpbGUiOiIxLmpzIiwic291cmNlc0NvbnRlbnQiOlsibW9kdWxlLmV4cG9ydHMgPSBfX1dFQlBBQ0tfRVhURVJOQUxfTU9EVUxFXzFfXztcblxuXG4vLy8vLy8vLy8vLy8vLy8vLy9cbi8vIFdFQlBBQ0sgRk9PVEVSXG4vLyBleHRlcm5hbCB7XCJyb290XCI6XCJqUXVlcnlcIixcImNvbW1vbmpzXCI6XCJqcXVlcnlcIixcImNvbW1vbmpzMlwiOlwianF1ZXJ5XCIsXCJhbWRcIjpcImpxdWVyeVwifVxuLy8gbW9kdWxlIGlkID0gMVxuLy8gbW9kdWxlIGNodW5rcyA9IDAiXSwic291cmNlUm9vdCI6IiJ9"); /***/ } /******/ ]) }); ;
app/react-icons/fa/check.js
scampersand/sonos-front
import React from 'react'; import IconBase from 'react-icon-base'; export default class FaCheck extends React.Component { render() { return ( <IconBase viewBox="0 0 40 40" {...this.props}> <g><path d="m37.3 12.6q0 0.9-0.6 1.6l-19.2 19.1q-0.6 0.7-1.5 0.7t-1.6-0.7l-11.1-11.1q-0.6-0.6-0.6-1.5t0.6-1.5l3.1-3q0.6-0.7 1.5-0.7t1.5 0.7l6.6 6.5 14.6-14.6q0.6-0.6 1.5-0.6t1.5 0.6l3.1 3q0.6 0.6 0.6 1.5z"/></g> </IconBase> ); } }
src/routes/login/index.js
mlem8/dev-challenge
/** * React Starter Kit (https://www.reactstarterkit.com/) * * Copyright © 2014-2016 Kriasoft, LLC. All rights reserved. * * This source code is licensed under the MIT license found in the * LICENSE.txt file in the root directory of this source tree. */ import React from 'react'; import Login from './Login'; export default { path: '/login', action() { return <Login />; }, };
ajax/libs/react/15.5.2/react-with-addons.min.js
holtkamp/cdnjs
/** * React (with addons) v15.5.2 * * Copyright 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * */ !function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var t;t="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this,t.React=e()}}(function(){return function e(t,n,r){function o(a,s){if(!n[a]){if(!t[a]){var u="function"==typeof require&&require;if(!s&&u)return u(a,!0);if(i)return i(a,!0);var c=new Error("Cannot find module '"+a+"'");throw c.code="MODULE_NOT_FOUND",c}var p=n[a]={exports:{}};t[a][0].call(p.exports,function(e){var n=t[a][1][e];return o(n||e)},p,p.exports,e,t,n,r)}return n[a].exports}for(var i="function"==typeof require&&require,a=0;a<r.length;a++)o(r[a]);return o}({1:[function(e,t,n){"use strict";function r(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n["ms"+e]="MS"+t,n["O"+e]="o"+t.toLowerCase(),n}function o(e){if(s[e])return s[e];if(!a[e])return e;var t=a[e];for(var n in t)if(t.hasOwnProperty(n)&&n in u)return s[e]=t[n];return""}var i=e(39),a={animationend:r("Animation","AnimationEnd"),animationiteration:r("Animation","AnimationIteration"),animationstart:r("Animation","AnimationStart"),transitionend:r("Transition","TransitionEnd")},s={},u={};i.canUseDOM&&(u=document.createElement("div").style,"AnimationEvent"in window||(delete a.animationend.animation,delete a.animationiteration.animation,delete a.animationstart.animation),"TransitionEvent"in window||delete a.transitionend.transition),t.exports=o},{39:39}],2:[function(e,t,n){"use strict";function r(e){var t={"=":"=0",":":"=2"};return"$"+(""+e).replace(/[=:]/g,function(e){return t[e]})}function o(e){var t={"=0":"=","=2":":"};return(""+("."===e[0]&&"$"===e[1]?e.substring(2):e.substring(1))).replace(/(=0|=2)/g,function(e){return t[e]})}var i={escape:r,unescape:o};t.exports=i},{}],3:[function(e,t,n){"use strict";var r=e(18),o=e(23),i={linkState:function(e){return new r(this.state[e],o.createStateKeySetter(this,e))}};t.exports=i},{18:18,23:23}],4:[function(e,t,n){"use strict";var r=e(34),o=(e(42),function(e){var t=this;if(t.instancePool.length){var n=t.instancePool.pop();return t.call(n,e),n}return new t(e)}),i=function(e,t){var n=this;if(n.instancePool.length){var r=n.instancePool.pop();return n.call(r,e,t),r}return new n(e,t)},a=function(e,t,n){var r=this;if(r.instancePool.length){var o=r.instancePool.pop();return r.call(o,e,t,n),o}return new r(e,t,n)},s=function(e,t,n,r){var o=this;if(o.instancePool.length){var i=o.instancePool.pop();return o.call(i,e,t,n,r),i}return new o(e,t,n,r)},u=function(e){var t=this;e instanceof t||r("25"),e.destructor(),t.instancePool.length<t.poolSize&&t.instancePool.push(e)},c=o,p=function(e,t){var n=e;return n.instancePool=[],n.getPooled=t||c,n.poolSize||(n.poolSize=10),n.release=u,n},l={addPoolingTo:p,oneArgumentPooler:o,twoArgumentPooler:i,threeArgumentPooler:a,fourArgumentPooler:s};t.exports=l},{34:34,42:42}],5:[function(e,t,n){"use strict";var r=e(45),o=e(9),i=e(11),a=e(22),s=e(10),u=e(14),c=e(15),p=e(21),l=e(27),f=e(33),d=(e(44),c.createElement),h=c.createFactory,y=c.cloneElement,m=r,v={Children:{map:o.map,forEach:o.forEach,count:o.count,toArray:o.toArray,only:f},Component:i,PureComponent:a,createElement:d,cloneElement:y,isValidElement:c.isValidElement,PropTypes:p,createClass:s.createClass,createFactory:h,createMixin:function(e){return e},DOM:u,version:l,__spread:m};t.exports=v},{10:10,11:11,14:14,15:15,21:21,22:22,27:27,33:33,44:44,45:45,9:9}],6:[function(e,t,n){"use strict";function r(){if(!o){var t=e(29);o=t.__SECRET_INJECTED_REACT_DOM_DO_NOT_USE_OR_YOU_WILL_BE_FIRED}return o}var o;n.getReactDOM=r},{29:29}],7:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function a(e){var t="transition"+e+"Timeout",n="transition"+e;return function(e){if(e[n]){if(null==e[t])return new Error(t+" wasn't supplied to ReactCSSTransitionGroup: this can cause unreliable animations and won't be supported in a future version of React. See https://fb.me/react-animation-transition-group-timeout for more information.");if("number"!=typeof e[t])return new Error(t+" must be a number (in milliseconds)")}}}var s=e(45),u=e(5),c=e(47),p=c(u.isValidElement),l=e(26),f=e(8),d=function(e){function t(){var n,i,a;r(this,t);for(var s=arguments.length,c=Array(s),p=0;p<s;p++)c[p]=arguments[p];return n=i=o(this,e.call.apply(e,[this].concat(c))),i._wrapChild=function(e){return u.createElement(f,{name:i.props.transitionName,appear:i.props.transitionAppear,enter:i.props.transitionEnter,leave:i.props.transitionLeave,appearTimeout:i.props.transitionAppearTimeout,enterTimeout:i.props.transitionEnterTimeout,leaveTimeout:i.props.transitionLeaveTimeout},e)},a=n,o(i,a)}return i(t,e),t.prototype.render=function(){return u.createElement(l,s({},this.props,{childFactory:this._wrapChild}))},t}(u.Component);d.displayName="ReactCSSTransitionGroup",d.propTypes={transitionName:f.propTypes.name,transitionAppear:p.bool,transitionEnter:p.bool,transitionLeave:p.bool,transitionAppearTimeout:a("Appear"),transitionEnterTimeout:a("Enter"),transitionLeaveTimeout:a("Leave")},d.defaultProps={transitionAppear:!1,transitionEnter:!0,transitionLeave:!0},t.exports=d},{26:26,45:45,47:47,5:5,8:8}],8:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var a=e(5),s=e(6),u=e(47),c=u(a.isValidElement),p=e(38),l=e(25),f=e(33),d=17,h=function(e){function t(){var n,i,a;r(this,t);for(var u=arguments.length,c=Array(u),f=0;f<u;f++)c[f]=arguments[f];return n=i=o(this,e.call.apply(e,[this].concat(c))),i._isMounted=!1,i.transition=function(e,t,n){var r=s.getReactDOM().findDOMNode(i);if(!r)return void(t&&t());var o=i.props.name[e]||i.props.name+"-"+e,a=i.props.name[e+"Active"]||o+"-active",u=null,c=function(e){e&&e.target!==r||(clearTimeout(u),p.removeClass(r,o),p.removeClass(r,a),l.removeEndEventListener(r,c),t&&t())};p.addClass(r,o),i.queueClassAndNode(a,r),n?(u=setTimeout(c,n),i.transitionTimeouts.push(u)):l.addEndEventListener(r,c)},i.queueClassAndNode=function(e,t){i.classNameAndNodeQueue.push({className:e,node:t}),i.timeout||(i.timeout=setTimeout(i.flushClassNameAndNodeQueue,d))},i.flushClassNameAndNodeQueue=function(){i._isMounted&&i.classNameAndNodeQueue.forEach(function(e){p.addClass(e.node,e.className)}),i.classNameAndNodeQueue.length=0,i.timeout=null},i.componentWillAppear=function(e){i.props.appear?i.transition("appear",e,i.props.appearTimeout):e()},i.componentWillEnter=function(e){i.props.enter?i.transition("enter",e,i.props.enterTimeout):e()},i.componentWillLeave=function(e){i.props.leave?i.transition("leave",e,i.props.leaveTimeout):e()},a=n,o(i,a)}return i(t,e),t.prototype.componentWillMount=function(){this.classNameAndNodeQueue=[],this.transitionTimeouts=[]},t.prototype.componentDidMount=function(){this._isMounted=!0},t.prototype.componentWillUnmount=function(){this._isMounted=!1,this.timeout&&clearTimeout(this.timeout),this.transitionTimeouts.forEach(function(e){clearTimeout(e)}),this.classNameAndNodeQueue.length=0},t.prototype.render=function(){return f(this.props.children)},t}(a.Component);h.propTypes={name:c.oneOfType([c.string,c.shape({enter:c.string,leave:c.string,active:c.string}),c.shape({enter:c.string,enterActive:c.string,leave:c.string,leaveActive:c.string,appear:c.string,appearActive:c.string})]).isRequired,appear:c.bool,enter:c.bool,leave:c.bool,appearTimeout:c.number,enterTimeout:c.number,leaveTimeout:c.number},t.exports=h},{25:25,33:33,38:38,47:47,5:5,6:6}],9:[function(e,t,n){"use strict";function r(e){return(""+e).replace(b,"$&/")}function o(e,t){this.func=e,this.context=t,this.count=0}function i(e,t,n){var r=e.func,o=e.context;r.call(o,t,e.count++)}function a(e,t,n){if(null==e)return e;var r=o.getPooled(t,n);v(e,i,r),o.release(r)}function s(e,t,n,r){this.result=e,this.keyPrefix=t,this.func=n,this.context=r,this.count=0}function u(e,t,n){var o=e.result,i=e.keyPrefix,a=e.func,s=e.context,u=a.call(s,t,e.count++);Array.isArray(u)?c(u,o,n,m.thatReturnsArgument):null!=u&&(y.isValidElement(u)&&(u=y.cloneAndReplaceKey(u,i+(!u.key||t&&t.key===u.key?"":r(u.key)+"/")+n)),o.push(u))}function c(e,t,n,o,i){var a="";null!=n&&(a=r(n)+"/");var c=s.getPooled(t,a,o,i);v(e,u,c),s.release(c)}function p(e,t,n){if(null==e)return e;var r=[];return c(e,r,null,t,n),r}function l(e,t,n){return null}function f(e,t){return v(e,l,null)}function d(e){var t=[];return c(e,t,null,m.thatReturnsArgument),t}var h=e(4),y=e(15),m=e(40),v=e(36),E=h.twoArgumentPooler,g=h.fourArgumentPooler,b=/\/+/g;o.prototype.destructor=function(){this.func=null,this.context=null,this.count=0},h.addPoolingTo(o,E),s.prototype.destructor=function(){this.result=null,this.keyPrefix=null,this.func=null,this.context=null,this.count=0},h.addPoolingTo(s,g);var _={forEach:a,map:p,mapIntoWithKeyPrefixInternal:c,count:f,toArray:d};t.exports=_},{15:15,36:36,4:4,40:40}],10:[function(e,t,n){"use strict";function r(e){return e}function o(e,t){var n=b.hasOwnProperty(t)?b[t]:null;w.hasOwnProperty(t)&&"OVERRIDE_BASE"!==n&&f("73",t),e&&"DEFINE_MANY"!==n&&"DEFINE_MANY_MERGED"!==n&&f("74",t)}function i(e,t){if(t){"function"==typeof t&&f("75"),y.isValidElement(t)&&f("76");var n=e.prototype,r=n.__reactAutoBindPairs;t.hasOwnProperty(E)&&_.mixins(e,t.mixins);for(var i in t)if(t.hasOwnProperty(i)&&i!==E){var a=t[i],s=n.hasOwnProperty(i);if(o(s,i),_.hasOwnProperty(i))_[i](e,a);else{var p=b.hasOwnProperty(i),l="function"==typeof a,d=l&&!p&&!s&&!1!==t.autobind;if(d)r.push(i,a),n[i]=a;else if(s){var h=b[i];(!p||"DEFINE_MANY_MERGED"!==h&&"DEFINE_MANY"!==h)&&f("77",h,i),"DEFINE_MANY_MERGED"===h?n[i]=u(n[i],a):"DEFINE_MANY"===h&&(n[i]=c(n[i],a))}else n[i]=a}}}}function a(e,t){if(t)for(var n in t){var r=t[n];if(t.hasOwnProperty(n)){var o=n in _;o&&f("78",n);var i=n in e;i&&f("79",n),e[n]=r}}}function s(e,t){e&&t&&"object"==typeof e&&"object"==typeof t||f("80");for(var n in t)t.hasOwnProperty(n)&&(void 0!==e[n]&&f("81",n),e[n]=t[n]);return e}function u(e,t){return function(){var n=e.apply(this,arguments),r=t.apply(this,arguments);if(null==n)return r;if(null==r)return n;var o={};return s(o,n),s(o,r),o}}function c(e,t){return function(){e.apply(this,arguments),t.apply(this,arguments)}}function p(e,t){return t.bind(e)}function l(e){for(var t=e.__reactAutoBindPairs,n=0;n<t.length;n+=2){var r=t[n],o=t[n+1];e[r]=p(e,o)}}var f=e(34),d=e(45),h=e(11),y=e(15),m=(e(20),e(19)),v=e(41),E=(e(42),e(44),"mixins"),g=[],b={mixins:"DEFINE_MANY",statics:"DEFINE_MANY",propTypes:"DEFINE_MANY",contextTypes:"DEFINE_MANY",childContextTypes:"DEFINE_MANY",getDefaultProps:"DEFINE_MANY_MERGED",getInitialState:"DEFINE_MANY_MERGED",getChildContext:"DEFINE_MANY_MERGED",render:"DEFINE_ONCE",componentWillMount:"DEFINE_MANY",componentDidMount:"DEFINE_MANY",componentWillReceiveProps:"DEFINE_MANY",shouldComponentUpdate:"DEFINE_ONCE",componentWillUpdate:"DEFINE_MANY",componentDidUpdate:"DEFINE_MANY",componentWillUnmount:"DEFINE_MANY",updateComponent:"OVERRIDE_BASE"},_={displayName:function(e,t){e.displayName=t},mixins:function(e,t){if(t)for(var n=0;n<t.length;n++)i(e,t[n])},childContextTypes:function(e,t){e.childContextTypes=d({},e.childContextTypes,t)},contextTypes:function(e,t){e.contextTypes=d({},e.contextTypes,t)},getDefaultProps:function(e,t){e.getDefaultProps?e.getDefaultProps=u(e.getDefaultProps,t):e.getDefaultProps=t},propTypes:function(e,t){e.propTypes=d({},e.propTypes,t)},statics:function(e,t){a(e,t)},autobind:function(){}},w={replaceState:function(e,t){this.updater.enqueueReplaceState(this,e),t&&this.updater.enqueueCallback(this,t,"replaceState")},isMounted:function(){return this.updater.isMounted(this)}},A=function(){};d(A.prototype,h.prototype,w);var T={createClass:function(e){var t=r(function(e,n,r){this.__reactAutoBindPairs.length&&l(this),this.props=e,this.context=n,this.refs=v,this.updater=r||m,this.state=null;var o=this.getInitialState?this.getInitialState():null;("object"!=typeof o||Array.isArray(o))&&f("82",t.displayName||"ReactCompositeComponent"),this.state=o});t.prototype=new A,t.prototype.constructor=t,t.prototype.__reactAutoBindPairs=[],g.forEach(i.bind(null,t)),i(t,e),t.getDefaultProps&&(t.defaultProps=t.getDefaultProps()),t.prototype.render||f("83");for(var n in b)t.prototype[n]||(t.prototype[n]=null);return t},injection:{injectMixin:function(e){g.push(e)}}};t.exports=T},{11:11,15:15,19:19,20:20,34:34,41:41,42:42,44:44,45:45}],11:[function(e,t,n){"use strict";function r(e,t,n){this.props=e,this.context=t,this.refs=a,this.updater=n||i}var o=e(34),i=e(19),a=(e(30),e(41));e(42),e(44);r.prototype.isReactComponent={},r.prototype.setState=function(e,t){"object"!=typeof e&&"function"!=typeof e&&null!=e&&o("85"),this.updater.enqueueSetState(this,e),t&&this.updater.enqueueCallback(this,t,"setState")},r.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this),e&&this.updater.enqueueCallback(this,e,"forceUpdate")};t.exports=r},{19:19,30:30,34:34,41:41,42:42,44:44}],12:[function(e,t,n){"use strict";var r=e(35),o={shouldComponentUpdate:function(e,t){return r(this,e,t)}};t.exports=o},{35:35}],13:[function(e,t,n){"use strict";var r={current:null};t.exports=r},{}],14:[function(e,t,n){"use strict";var r=e(15),o=r.createFactory,i={a:o("a"),abbr:o("abbr"),address:o("address"),area:o("area"),article:o("article"),aside:o("aside"),audio:o("audio"),b:o("b"),base:o("base"),bdi:o("bdi"),bdo:o("bdo"),big:o("big"),blockquote:o("blockquote"),body:o("body"),br:o("br"),button:o("button"),canvas:o("canvas"),caption:o("caption"),cite:o("cite"),code:o("code"),col:o("col"),colgroup:o("colgroup"),data:o("data"),datalist:o("datalist"),dd:o("dd"),del:o("del"),details:o("details"),dfn:o("dfn"),dialog:o("dialog"),div:o("div"),dl:o("dl"),dt:o("dt"),em:o("em"),embed:o("embed"),fieldset:o("fieldset"),figcaption:o("figcaption"),figure:o("figure"),footer:o("footer"),form:o("form"),h1:o("h1"),h2:o("h2"),h3:o("h3"),h4:o("h4"),h5:o("h5"),h6:o("h6"),head:o("head"),header:o("header"),hgroup:o("hgroup"),hr:o("hr"),html:o("html"),i:o("i"),iframe:o("iframe"),img:o("img"),input:o("input"),ins:o("ins"),kbd:o("kbd"),keygen:o("keygen"),label:o("label"),legend:o("legend"),li:o("li"),link:o("link"),main:o("main"),map:o("map"),mark:o("mark"),menu:o("menu"),menuitem:o("menuitem"),meta:o("meta"),meter:o("meter"),nav:o("nav"),noscript:o("noscript"),object:o("object"),ol:o("ol"),optgroup:o("optgroup"),option:o("option"),output:o("output"),p:o("p"),param:o("param"),picture:o("picture"),pre:o("pre"),progress:o("progress"),q:o("q"),rp:o("rp"),rt:o("rt"),ruby:o("ruby"),s:o("s"),samp:o("samp"),script:o("script"),section:o("section"),select:o("select"),small:o("small"),source:o("source"),span:o("span"),strong:o("strong"),style:o("style"),sub:o("sub"),summary:o("summary"),sup:o("sup"),table:o("table"),tbody:o("tbody"),td:o("td"),textarea:o("textarea"),tfoot:o("tfoot"),th:o("th"),thead:o("thead"),time:o("time"),title:o("title"),tr:o("tr"),track:o("track"),u:o("u"),ul:o("ul"),var:o("var"),video:o("video"),wbr:o("wbr"),circle:o("circle"),clipPath:o("clipPath"),defs:o("defs"),ellipse:o("ellipse"),g:o("g"),image:o("image"),line:o("line"),linearGradient:o("linearGradient"),mask:o("mask"),path:o("path"),pattern:o("pattern"),polygon:o("polygon"),polyline:o("polyline"),radialGradient:o("radialGradient"),rect:o("rect"),stop:o("stop"),svg:o("svg"),text:o("text"),tspan:o("tspan")};t.exports=i},{15:15}],15:[function(e,t,n){"use strict";function r(e){return void 0!==e.ref}function o(e){return void 0!==e.key}var i=e(45),a=e(13),s=(e(44),e(30),Object.prototype.hasOwnProperty),u=e(16),c={key:!0,ref:!0,__self:!0,__source:!0},p=function(e,t,n,r,o,i,a){return{$$typeof:u,type:e,key:t,ref:n,props:a,_owner:i}};p.createElement=function(e,t,n){var i,u={},l=null,f=null;if(null!=t){r(t)&&(f=t.ref),o(t)&&(l=""+t.key),void 0===t.__self?null:t.__self,void 0===t.__source?null:t.__source;for(i in t)s.call(t,i)&&!c.hasOwnProperty(i)&&(u[i]=t[i])}var d=arguments.length-2;if(1===d)u.children=n;else if(d>1){for(var h=Array(d),y=0;y<d;y++)h[y]=arguments[y+2];u.children=h}if(e&&e.defaultProps){var m=e.defaultProps;for(i in m)void 0===u[i]&&(u[i]=m[i])}return p(e,l,f,0,0,a.current,u)},p.createFactory=function(e){var t=p.createElement.bind(null,e);return t.type=e,t},p.cloneAndReplaceKey=function(e,t){return p(e.type,t,e.ref,e._self,e._source,e._owner,e.props)},p.cloneElement=function(e,t,n){var u,l=i({},e.props),f=e.key,d=e.ref,h=(e._self,e._source,e._owner);if(null!=t){r(t)&&(d=t.ref,h=a.current),o(t)&&(f=""+t.key);var y;e.type&&e.type.defaultProps&&(y=e.type.defaultProps);for(u in t)s.call(t,u)&&!c.hasOwnProperty(u)&&(void 0===t[u]&&void 0!==y?l[u]=y[u]:l[u]=t[u])}var m=arguments.length-2;if(1===m)l.children=n;else if(m>1){for(var v=Array(m),E=0;E<m;E++)v[E]=arguments[E+2];l.children=v}return p(e.type,f,d,0,0,h,l)},p.isValidElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===u},t.exports=p},{13:13,16:16,30:30,44:44,45:45}],16:[function(e,t,n){"use strict";var r="function"==typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103;t.exports=r},{}],17:[function(e,t,n){"use strict";var r=e(34),o=e(9),i=e(15),a=e(40),s=(e(42),e(44),{create:function(e){if("object"!=typeof e||!e||Array.isArray(e))return e;if(i.isValidElement(e))return e;1===e.nodeType&&r("0");var t=[];for(var n in e)o.mapIntoWithKeyPrefixInternal(e[n],t,n,a.thatReturnsArgument);return t}});t.exports=s},{15:15,34:34,40:40,42:42,44:44,9:9}],18:[function(e,t,n){"use strict";function r(e,t){this.value=e,this.requestChange=t}function o(e){var t={value:void 0===e?i.PropTypes.any.isRequired:e.isRequired,requestChange:i.PropTypes.func.isRequired};return i.PropTypes.shape(t)}var i=e(5);r.PropTypes={link:o},t.exports=r},{5:5}],19:[function(e,t,n){"use strict";var r=(e(44),{isMounted:function(e){return!1},enqueueCallback:function(e,t){},enqueueForceUpdate:function(e){},enqueueReplaceState:function(e,t){},enqueueSetState:function(e,t){}});t.exports=r},{44:44}],20:[function(e,t,n){"use strict";var r={};t.exports=r},{}],21:[function(e,t,n){"use strict";var r=e(15),o=r.isValidElement,i=e(47);t.exports=i(o)},{15:15,47:47}],22:[function(e,t,n){"use strict";function r(e,t,n){this.props=e,this.context=t,this.refs=u,this.updater=n||s}function o(){}var i=e(45),a=e(11),s=e(19),u=e(41);o.prototype=a.prototype,r.prototype=new o,r.prototype.constructor=r,i(r.prototype,a.prototype),r.prototype.isPureReactComponent=!0,t.exports=r},{11:11,19:19,41:41,45:45}],23:[function(e,t,n){"use strict";function r(e,t){var n={};return function(r){n[t]=r,e.setState(n)}}var o={createStateSetter:function(e,t){return function(n,r,o,i,a,s){var u=t.call(e,n,r,o,i,a,s);u&&e.setState(u)}},createStateKeySetter:function(e,t){var n=e.__keySetters||(e.__keySetters={});return n[t]||(n[t]=r(e,t))}};o.Mixin={createStateSetter:function(e){return o.createStateSetter(this,e)},createStateKeySetter:function(e){return o.createStateKeySetter(this,e)}},t.exports=o},{}],24:[function(e,t,n){"use strict";var r=e(31),o={getChildMapping:function(e,t){return e?r(e):e},mergeChildMappings:function(e,t){function n(n){return t.hasOwnProperty(n)?t[n]:e[n]}e=e||{},t=t||{};var r={},o=[];for(var i in e)t.hasOwnProperty(i)?o.length&&(r[i]=o,o=[]):o.push(i);var a,s={};for(var u in t){if(r.hasOwnProperty(u))for(a=0;a<r[u].length;a++){var c=r[u][a];s[r[u][a]]=n(c)}s[u]=n(u)}for(a=0;a<o.length;a++)s[o[a]]=n(o[a]);return s}};t.exports=o},{31:31}],25:[function(e,t,n){"use strict";function r(e,t,n){e.addEventListener(t,n,!1)}function o(e,t,n){e.removeEventListener(t,n,!1)}var i=e(39),a=e(1),s=[];i.canUseDOM&&function(){var e=a("animationend"),t=a("transitionend");e&&s.push(e),t&&s.push(t)}();var u={addEndEventListener:function(e,t){if(0===s.length)return void window.setTimeout(t,0);s.forEach(function(n){r(e,n,t)})},removeEndEventListener:function(e,t){0!==s.length&&s.forEach(function(n){o(e,n,t)})}};t.exports=u},{1:1,39:39}],26:[function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var a=e(45),s=e(5),u=e(24),c=e(47),p=c(s.isValidElement),l=e(40),f=function(e){function t(){var n,i,s;r(this,t);for(var c=arguments.length,p=Array(c),l=0;l<c;l++)p[l]=arguments[l];return n=i=o(this,e.call.apply(e,[this].concat(p))),i.state={children:u.getChildMapping(i.props.children)},i.performAppear=function(e){i.currentlyTransitioningKeys[e]=!0;var t=i.refs[e];t.componentWillAppear?t.componentWillAppear(i._handleDoneAppearing.bind(i,e)):i._handleDoneAppearing(e)},i._handleDoneAppearing=function(e){var t=i.refs[e];t.componentDidAppear&&t.componentDidAppear(),delete i.currentlyTransitioningKeys[e];var n=u.getChildMapping(i.props.children);n&&n.hasOwnProperty(e)||i.performLeave(e)},i.performEnter=function(e){i.currentlyTransitioningKeys[e]=!0;var t=i.refs[e];t.componentWillEnter?t.componentWillEnter(i._handleDoneEntering.bind(i,e)):i._handleDoneEntering(e)},i._handleDoneEntering=function(e){var t=i.refs[e];t.componentDidEnter&&t.componentDidEnter(),delete i.currentlyTransitioningKeys[e];var n=u.getChildMapping(i.props.children);n&&n.hasOwnProperty(e)||i.performLeave(e)},i.performLeave=function(e){i.currentlyTransitioningKeys[e]=!0;var t=i.refs[e];t.componentWillLeave?t.componentWillLeave(i._handleDoneLeaving.bind(i,e)):i._handleDoneLeaving(e)},i._handleDoneLeaving=function(e){var t=i.refs[e];t.componentDidLeave&&t.componentDidLeave(),delete i.currentlyTransitioningKeys[e];var n=u.getChildMapping(i.props.children);n&&n.hasOwnProperty(e)?i.performEnter(e):i.setState(function(t){var n=a({},t.children);return delete n[e],{children:n}})},s=n,o(i,s)}return i(t,e),t.prototype.componentWillMount=function(){this.currentlyTransitioningKeys={},this.keysToEnter=[],this.keysToLeave=[]},t.prototype.componentDidMount=function(){var e=this.state.children;for(var t in e)e[t]&&this.performAppear(t)},t.prototype.componentWillReceiveProps=function(e){var t=u.getChildMapping(e.children),n=this.state.children;this.setState({children:u.mergeChildMappings(n,t)});var r;for(r in t){var o=n&&n.hasOwnProperty(r);!t[r]||o||this.currentlyTransitioningKeys[r]||this.keysToEnter.push(r)}for(r in n){var i=t&&t.hasOwnProperty(r);!n[r]||i||this.currentlyTransitioningKeys[r]||this.keysToLeave.push(r)}},t.prototype.componentDidUpdate=function(){var e=this.keysToEnter;this.keysToEnter=[],e.forEach(this.performEnter);var t=this.keysToLeave;this.keysToLeave=[],t.forEach(this.performLeave)},t.prototype.render=function(){var e=[];for(var t in this.state.children){var n=this.state.children[t];n&&e.push(s.cloneElement(this.props.childFactory(n),{ref:t,key:t}))}var r=a({},this.props);return delete r.transitionLeave,delete r.transitionName,delete r.transitionAppear,delete r.transitionEnter,delete r.childFactory,delete r.transitionLeaveTimeout,delete r.transitionEnterTimeout,delete r.transitionAppearTimeout,delete r.component,s.createElement(this.props.component,r,e)},t}(s.Component);f.displayName="ReactTransitionGroup",f.propTypes={component:p.any,childFactory:p.func},f.defaultProps={component:"span",childFactory:l.thatReturnsArgument},t.exports=f},{24:24,40:40,45:45,47:47,5:5}],27:[function(e,t,n){"use strict";t.exports="15.5.2"},{}],28:[function(e,t,n){"use strict";var r=e(3),o=e(5),i=(e(6),e(12)),a=e(7),s=e(17),u=e(26),c=e(35),p=e(37);o.addons={CSSTransitionGroup:a,LinkedStateMixin:r,PureRenderMixin:i,TransitionGroup:u,createFragment:s.create,shallowCompare:c,update:p},t.exports=o},{12:12,17:17,26:26,3:3,35:35,37:37,5:5,6:6,7:7}],29:[function(e,t,n){"use strict";var r=e(45),o=e(28),i=r(o,{__SECRET_INJECTED_REACT_DOM_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:null,__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:{ReactCurrentOwner:e(13)}});t.exports=i},{13:13,28:28,45:45}],30:[function(e,t,n){"use strict";t.exports=!1},{}],31:[function(e,t,n){(function(n){"use strict";function r(e,t,n,r){if(e&&"object"==typeof e){var o=e;void 0===o[n]&&null!=t&&(o[n]=t)}}function o(e,t){if(null==e)return e;var n={};return i(e,r,n),n}var i=(e(2),e(36));e(44);void 0!==n&&n.env,t.exports=o}).call(this,void 0)},{2:2,36:36,44:44}],32:[function(e,t,n){"use strict";function r(e){var t=e&&(o&&e[o]||e[i]);if("function"==typeof t)return t}var o="function"==typeof Symbol&&Symbol.iterator,i="@@iterator";t.exports=r},{}],33:[function(e,t,n){"use strict";function r(e){return i.isValidElement(e)||o("143"),e}var o=e(34),i=e(15);e(42);t.exports=r},{15:15,34:34,42:42}],34:[function(e,t,n){"use strict";function r(e){for(var t=arguments.length-1,n="Minified React error #"+e+"; visit http://facebook.github.io/react/docs/error-decoder.html?invariant="+e,r=0;r<t;r++)n+="&args[]="+encodeURIComponent(arguments[r+1]);n+=" for the full message or use the non-minified dev environment for full errors and additional helpful warnings.";var o=new Error(n);throw o.name="Invariant Violation",o.framesToPop=1,o}t.exports=r},{}],35:[function(e,t,n){"use strict";function r(e,t,n){return!o(e.props,t)||!o(e.state,n)}var o=e(43);t.exports=r},{43:43}],36:[function(e,t,n){"use strict";function r(e,t){return e&&"object"==typeof e&&null!=e.key?c.escape(e.key):t.toString(36)}function o(e,t,n,i){var f=typeof e;if("undefined"!==f&&"boolean"!==f||(e=null),null===e||"string"===f||"number"===f||"object"===f&&e.$$typeof===s)return n(i,e,""===t?p+r(e,0):t),1;var d,h,y=0,m=""===t?p:t+l;if(Array.isArray(e))for(var v=0;v<e.length;v++)d=e[v],h=m+r(d,v),y+=o(d,h,n,i);else{var E=u(e);if(E){var g,b=E.call(e);if(E!==e.entries)for(var _=0;!(g=b.next()).done;)d=g.value,h=m+r(d,_++),y+=o(d,h,n,i);else for(;!(g=b.next()).done;){var w=g.value;w&&(d=w[1],h=m+c.escape(w[0])+l+r(d,0),y+=o(d,h,n,i))}}else if("object"===f){var A=String(e);a("31","[object Object]"===A?"object with keys {"+Object.keys(e).join(", ")+"}":A,"")}}return y}function i(e,t,n){return null==e?0:o(e,"",t,n)}var a=e(34),s=(e(13),e(16)),u=e(32),c=(e(42),e(2)),p=(e(44),"."),l=":";t.exports=i},{13:13,16:16,2:2,32:32,34:34,42:42,44:44}],37:[function(e,t,n){"use strict";function r(e){return Array.isArray(e)?e.concat():e&&"object"==typeof e?s(new e.constructor,e):e}function o(e,t,n){Array.isArray(e)||a("1",n,e);var r=t[n];Array.isArray(r)||a("2",n,r)}function i(e,t){if("object"!=typeof t&&a("3",y.join(", "),f),u.call(t,f))return 1!==Object.keys(t).length&&a("4",f),t[f];var n=r(e);if(u.call(t,d)){var v=t[d];v&&"object"==typeof v||a("5",d,v),n&&"object"==typeof n||a("6",d,n),s(n,t[d])}u.call(t,c)&&(o(e,t,c),t[c].forEach(function(e){n.push(e)})),u.call(t,p)&&(o(e,t,p),t[p].forEach(function(e){n.unshift(e)})),u.call(t,l)&&(Array.isArray(e)||a("7",l,e),Array.isArray(t[l])||a("8",l,t[l]),t[l].forEach(function(e){Array.isArray(e)||a("8",l,t[l]),n.splice.apply(n,e)})),u.call(t,h)&&("function"!=typeof t[h]&&a("9",h,t[h]),n=t[h](n));for(var E in t)m.hasOwnProperty(E)&&m[E]||(n[E]=i(e[E],t[E]));return n}var a=e(34),s=e(45),u=(e(42),{}.hasOwnProperty),c="$push",p="$unshift",l="$splice",f="$set",d="$merge",h="$apply",y=[c,p,l,f,d,h],m={};y.forEach(function(e){m[e]=!0}),t.exports=i},{34:34,42:42,45:45}],38:[function(e,t,n){"use strict";function r(e,t){for(var n=e;n.parentNode;)n=n.parentNode;var r=n.querySelectorAll(t);return-1!==Array.prototype.indexOf.call(r,e)}var o=e(42),i={addClass:function(e,t){return/\s/.test(t)&&o(!1),t&&(e.classList?e.classList.add(t):i.hasClass(e,t)||(e.className=e.className+" "+t)),e},removeClass:function(e,t){return/\s/.test(t)&&o(!1),t&&(e.classList?e.classList.remove(t):i.hasClass(e,t)&&(e.className=e.className.replace(new RegExp("(^|\\s)"+t+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,""))),e},conditionClass:function(e,t,n){return(n?i.addClass:i.removeClass)(e,t)},hasClass:function(e,t){return/\s/.test(t)&&o(!1),e.classList?!!t&&e.classList.contains(t):(" "+e.className+" ").indexOf(" "+t+" ")>-1},matchesSelector:function(e,t){return(e.matches||e.webkitMatchesSelector||e.mozMatchesSelector||e.msMatchesSelector||function(t){return r(e,t)}).call(e,t)}};t.exports=i},{42:42}],39:[function(e,t,n){"use strict";var r=!("undefined"==typeof window||!window.document||!window.document.createElement),o={canUseDOM:r,canUseWorkers:"undefined"!=typeof Worker,canUseEventListeners:r&&!(!window.addEventListener&&!window.attachEvent),canUseViewport:r&&!!window.screen,isInWorker:!r};t.exports=o},{}],40:[function(e,t,n){"use strict";function r(e){return function(){return e}}var o=function(){};o.thatReturns=r,o.thatReturnsFalse=r(!1),o.thatReturnsTrue=r(!0),o.thatReturnsNull=r(null),o.thatReturnsThis=function(){return this},o.thatReturnsArgument=function(e){return e},t.exports=o},{}],41:[function(e,t,n){"use strict";var r={};t.exports=r},{}],42:[function(e,t,n){"use strict";function r(e,t,n,r,i,a,s,u){if(o(t),!e){var c;if(void 0===t)c=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var p=[n,r,i,a,s,u],l=0;c=new Error(t.replace(/%s/g,function(){return p[l++]})),c.name="Invariant Violation"}throw c.framesToPop=1,c}}var o=function(e){};t.exports=r},{}],43:[function(e,t,n){"use strict";function r(e,t){return e===t?0!==e||0!==t||1/e==1/t:e!==e&&t!==t}function o(e,t){if(r(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var n=Object.keys(e),o=Object.keys(t);if(n.length!==o.length)return!1;for(var a=0;a<n.length;a++)if(!i.call(t,n[a])||!r(e[n[a]],t[n[a]]))return!1;return!0}var i=Object.prototype.hasOwnProperty;t.exports=o},{}],44:[function(e,t,n){"use strict";var r=e(40),o=r;t.exports=o},{40:40}],45:[function(e,t,n){"use strict";function r(e){if(null===e||void 0===e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}var o=Object.getOwnPropertySymbols,i=Object.prototype.hasOwnProperty,a=Object.prototype.propertyIsEnumerable;t.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map(function(e){return t[e]}).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach(function(e){r[e]=e}),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(e){return!1}}()?Object.assign:function(e,t){for(var n,s,u=r(e),c=1;c<arguments.length;c++){n=Object(arguments[c]);for(var p in n)i.call(n,p)&&(u[p]=n[p]);if(o){s=o(n);for(var l=0;l<s.length;l++)a.call(n,s[l])&&(u[s[l]]=n[s[l]])}}return u}},{}],46:[function(e,t,n){"use strict";function r(e,t,n,r,o){}e(42),e(44),e(48);t.exports=r},{42:42,44:44,48:48}],47:[function(e,t,n){"use strict" ;var r=(e(40),e(42)),o=(e(44),e(48),e(46));t.exports=function(e){function t(e){this.message=e,this.stack=""}var n,i=("function"==typeof Symbol&&Symbol.iterator,function(){r(!1,"React.PropTypes type checking code is stripped in production.")});i.isRequired=i;var a=function(){return i};return n={array:i,bool:i,func:i,number:i,object:i,string:i,symbol:i,any:i,arrayOf:a,element:i,instanceOf:a,node:i,objectOf:a,oneOf:a,oneOfType:a,shape:a},t.prototype=Error.prototype,n.checkPropTypes=o,n.PropTypes=n,n}},{40:40,42:42,44:44,46:46,48:48}],48:[function(e,t,n){"use strict";t.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},{}]},{},[29])(29)});
components/menu/index.js
react-material-design/react-material-design
import '@material/menu/dist/mdc.menu.css'; import classNames from 'classnames'; import PropTypes from 'prop-types'; import React, { Component } from 'react'; import { MDCSimpleMenu } from '@material/menu'; // TODO: Dynamically set selectMenu /** Menu */ class Menu extends Component { static propTypes = { children: PropTypes.oneOfType([ PropTypes.arrayOf(PropTypes.element), PropTypes.element, ]).isRequired, darkTheme: PropTypes.bool, /** When menu is used as a child within <Select /> */ selectMenu: PropTypes.bool, } constructor(props) { super(props); this.mainRoot = React.createRef(); } componentDidMount() { this.menu = new MDCSimpleMenu(this.mainRoot.current); this.menu.listen('MDCSimpleMenu:selected', ({ detail }) => { this.setState({ selectedIndex: detail.index, }); }); } handleOpen = (focusIndex) => { this.menu.show({ focusIndex }); } render() { const { children, darkTheme, selectMenu } = this.props; return ( <div ref={this.mainRoot} className={classNames('mdc-simple-menu', { 'mdc-simple-menu--theme-dark': darkTheme }, { 'mdc-select__menu': selectMenu })} tabIndex="-1" > <ul className="mdc-simple-menu__items mdc-list" role="menu" aria-hidden="true"> {children} </ul> </div> ); } } export default Menu;
src/routes/home/components/Home.hero.js
jackinf/skynda.me
/** * Created by jevgenir on 18/09/2016. */ import React from 'react'; import withStyle from 'isomorphic-style-loader/lib/withStyles'; import s from './Home.hero.css'; import RaisedButton from 'material-ui/RaisedButton'; import heroImageUrl from './../../../public/images/standard/hero-01-2.jpg'; /** * Main jumbotron for a primary marketing message or call to action */ class Hero extends React.Component { render() { return (<div className={s.sk_hero}> <img className={s.sk_hero__image} src={heroImageUrl} alt="image"/> <div className={s.sk_hero__text}> <div className="container"> <div className={s.grid}> <div className="col-md-10"> <h2>Buying a pre-used car has never been so fun, easy and secure</h2> </div> <div className="col-md-2"> <RaisedButton label="Read more" href="details" backgroundColor="#019BFF" labelColor="whitesmoke" /> </div> </div> </div> </div> </div>) } } export default withStyle(s)(Hero);
src/propTypes/ViewStylePropTypes.js
omeid/react-native-mock
/** * https://github.com/facebook/react-native/blob/master/Libraries/Components/View/ViewStylePropTypes.js */ import React from 'react'; import ColorPropType from './ColorPropType'; import LayoutPropTypes from './LayoutPropTypes'; import ShadowPropTypesIOS from './ShadowPropTypesIOS'; import TransformPropTypes from './TransformPropTypes'; const { PropTypes } = React; /** * Warning: Some of these properties may not be supported in all releases. */ var ViewStylePropTypes = { ...LayoutPropTypes, ...ShadowPropTypesIOS, ...TransformPropTypes, backfaceVisibility: PropTypes.oneOf(['visible', 'hidden']), backgroundColor: ColorPropType, borderColor: ColorPropType, borderTopColor: ColorPropType, borderRightColor: ColorPropType, borderBottomColor: ColorPropType, borderLeftColor: ColorPropType, borderRadius: PropTypes.number, borderTopLeftRadius: PropTypes.number, borderTopRightRadius: PropTypes.number, borderBottomLeftRadius: PropTypes.number, borderBottomRightRadius: PropTypes.number, borderStyle: PropTypes.oneOf(['solid', 'dotted', 'dashed']), borderWidth: PropTypes.number, borderTopWidth: PropTypes.number, borderRightWidth: PropTypes.number, borderBottomWidth: PropTypes.number, borderLeftWidth: PropTypes.number, opacity: PropTypes.number, overflow: PropTypes.oneOf(['visible', 'hidden']), /** * (Android-only) Sets the elevation of a view, using Android's underlying * [elevation API](https://developer.android.com/training/material/shadows-clipping.html#Elevation). * This adds a drop shadow to the item and affects z-order for overlapping views. * Only supported on Android 5.0+, has no effect on earlier versions. * @platform android */ elevation: PropTypes.number, }; module.exports = ViewStylePropTypes;
sites/default/files/js/js_sGMYHUidD5LYrJp_HvVwUpXWa8fIH-NwJJ_26fQg1UI.js
balad7/d8training
/*! jQuery v2.2.3 | (c) jQuery Foundation | jquery.org/license */ !function(a,b){"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof window?window:this,function(a,b){var c=[],d=a.document,e=c.slice,f=c.concat,g=c.push,h=c.indexOf,i={},j=i.toString,k=i.hasOwnProperty,l={},m="2.2.3",n=function(a,b){return new n.fn.init(a,b)},o=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,p=/^-ms-/,q=/-([\da-z])/gi,r=function(a,b){return b.toUpperCase()};n.fn=n.prototype={jquery:m,constructor:n,selector:"",length:0,toArray:function(){return e.call(this)},get:function(a){return null!=a?0>a?this[a+this.length]:this[a]:e.call(this)},pushStack:function(a){var b=n.merge(this.constructor(),a);return b.prevObject=this,b.context=this.context,b},each:function(a){return n.each(this,a)},map:function(a){return this.pushStack(n.map(this,function(b,c){return a.call(b,c,b)}))},slice:function(){return this.pushStack(e.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(a){var b=this.length,c=+a+(0>a?b:0);return this.pushStack(c>=0&&b>c?[this[c]]:[])},end:function(){return this.prevObject||this.constructor()},push:g,sort:c.sort,splice:c.splice},n.extend=n.fn.extend=function(){var a,b,c,d,e,f,g=arguments[0]||{},h=1,i=arguments.length,j=!1;for("boolean"==typeof g&&(j=g,g=arguments[h]||{},h++),"object"==typeof g||n.isFunction(g)||(g={}),h===i&&(g=this,h--);i>h;h++)if(null!=(a=arguments[h]))for(b in a)c=g[b],d=a[b],g!==d&&(j&&d&&(n.isPlainObject(d)||(e=n.isArray(d)))?(e?(e=!1,f=c&&n.isArray(c)?c:[]):f=c&&n.isPlainObject(c)?c:{},g[b]=n.extend(j,f,d)):void 0!==d&&(g[b]=d));return g},n.extend({expando:"jQuery"+(m+Math.random()).replace(/\D/g,""),isReady:!0,error:function(a){throw new Error(a)},noop:function(){},isFunction:function(a){return"function"===n.type(a)},isArray:Array.isArray,isWindow:function(a){return null!=a&&a===a.window},isNumeric:function(a){var b=a&&a.toString();return!n.isArray(a)&&b-parseFloat(b)+1>=0},isPlainObject:function(a){var b;if("object"!==n.type(a)||a.nodeType||n.isWindow(a))return!1;if(a.constructor&&!k.call(a,"constructor")&&!k.call(a.constructor.prototype||{},"isPrototypeOf"))return!1;for(b in a);return void 0===b||k.call(a,b)},isEmptyObject:function(a){var b;for(b in a)return!1;return!0},type:function(a){return null==a?a+"":"object"==typeof a||"function"==typeof a?i[j.call(a)]||"object":typeof a},globalEval:function(a){var b,c=eval;a=n.trim(a),a&&(1===a.indexOf("use strict")?(b=d.createElement("script"),b.text=a,d.head.appendChild(b).parentNode.removeChild(b)):c(a))},camelCase:function(a){return a.replace(p,"ms-").replace(q,r)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toLowerCase()===b.toLowerCase()},each:function(a,b){var c,d=0;if(s(a)){for(c=a.length;c>d;d++)if(b.call(a[d],d,a[d])===!1)break}else for(d in a)if(b.call(a[d],d,a[d])===!1)break;return a},trim:function(a){return null==a?"":(a+"").replace(o,"")},makeArray:function(a,b){var c=b||[];return null!=a&&(s(Object(a))?n.merge(c,"string"==typeof a?[a]:a):g.call(c,a)),c},inArray:function(a,b,c){return null==b?-1:h.call(b,a,c)},merge:function(a,b){for(var c=+b.length,d=0,e=a.length;c>d;d++)a[e++]=b[d];return a.length=e,a},grep:function(a,b,c){for(var d,e=[],f=0,g=a.length,h=!c;g>f;f++)d=!b(a[f],f),d!==h&&e.push(a[f]);return e},map:function(a,b,c){var d,e,g=0,h=[];if(s(a))for(d=a.length;d>g;g++)e=b(a[g],g,c),null!=e&&h.push(e);else for(g in a)e=b(a[g],g,c),null!=e&&h.push(e);return f.apply([],h)},guid:1,proxy:function(a,b){var c,d,f;return"string"==typeof b&&(c=a[b],b=a,a=c),n.isFunction(a)?(d=e.call(arguments,2),f=function(){return a.apply(b||this,d.concat(e.call(arguments)))},f.guid=a.guid=a.guid||n.guid++,f):void 0},now:Date.now,support:l}),"function"==typeof Symbol&&(n.fn[Symbol.iterator]=c[Symbol.iterator]),n.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(a,b){i["[object "+b+"]"]=b.toLowerCase()});function s(a){var b=!!a&&"length"in a&&a.length,c=n.type(a);return"function"===c||n.isWindow(a)?!1:"array"===c||0===b||"number"==typeof b&&b>0&&b-1 in a}var t=function(a){var b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u="sizzle"+1*new Date,v=a.document,w=0,x=0,y=ga(),z=ga(),A=ga(),B=function(a,b){return a===b&&(l=!0),0},C=1<<31,D={}.hasOwnProperty,E=[],F=E.pop,G=E.push,H=E.push,I=E.slice,J=function(a,b){for(var c=0,d=a.length;d>c;c++)if(a[c]===b)return c;return-1},K="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",L="[\\x20\\t\\r\\n\\f]",M="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",N="\\["+L+"*("+M+")(?:"+L+"*([*^$|!~]?=)"+L+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+M+"))|)"+L+"*\\]",O=":("+M+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+N+")*)|.*)\\)|)",P=new RegExp(L+"+","g"),Q=new RegExp("^"+L+"+|((?:^|[^\\\\])(?:\\\\.)*)"+L+"+$","g"),R=new RegExp("^"+L+"*,"+L+"*"),S=new RegExp("^"+L+"*([>+~]|"+L+")"+L+"*"),T=new RegExp("="+L+"*([^\\]'\"]*?)"+L+"*\\]","g"),U=new RegExp(O),V=new RegExp("^"+M+"$"),W={ID:new RegExp("^#("+M+")"),CLASS:new RegExp("^\\.("+M+")"),TAG:new RegExp("^("+M+"|[*])"),ATTR:new RegExp("^"+N),PSEUDO:new RegExp("^"+O),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+L+"*(even|odd|(([+-]|)(\\d*)n|)"+L+"*(?:([+-]|)"+L+"*(\\d+)|))"+L+"*\\)|)","i"),bool:new RegExp("^(?:"+K+")$","i"),needsContext:new RegExp("^"+L+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+L+"*((?:-\\d)?\\d*)"+L+"*\\)|)(?=[^-]|$)","i")},X=/^(?:input|select|textarea|button)$/i,Y=/^h\d$/i,Z=/^[^{]+\{\s*\[native \w/,$=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,_=/[+~]/,aa=/'|\\/g,ba=new RegExp("\\\\([\\da-f]{1,6}"+L+"?|("+L+")|.)","ig"),ca=function(a,b,c){var d="0x"+b-65536;return d!==d||c?b:0>d?String.fromCharCode(d+65536):String.fromCharCode(d>>10|55296,1023&d|56320)},da=function(){m()};try{H.apply(E=I.call(v.childNodes),v.childNodes),E[v.childNodes.length].nodeType}catch(ea){H={apply:E.length?function(a,b){G.apply(a,I.call(b))}:function(a,b){var c=a.length,d=0;while(a[c++]=b[d++]);a.length=c-1}}}function fa(a,b,d,e){var f,h,j,k,l,o,r,s,w=b&&b.ownerDocument,x=b?b.nodeType:9;if(d=d||[],"string"!=typeof a||!a||1!==x&&9!==x&&11!==x)return d;if(!e&&((b?b.ownerDocument||b:v)!==n&&m(b),b=b||n,p)){if(11!==x&&(o=$.exec(a)))if(f=o[1]){if(9===x){if(!(j=b.getElementById(f)))return d;if(j.id===f)return d.push(j),d}else if(w&&(j=w.getElementById(f))&&t(b,j)&&j.id===f)return d.push(j),d}else{if(o[2])return H.apply(d,b.getElementsByTagName(a)),d;if((f=o[3])&&c.getElementsByClassName&&b.getElementsByClassName)return H.apply(d,b.getElementsByClassName(f)),d}if(c.qsa&&!A[a+" "]&&(!q||!q.test(a))){if(1!==x)w=b,s=a;else if("object"!==b.nodeName.toLowerCase()){(k=b.getAttribute("id"))?k=k.replace(aa,"\\$&"):b.setAttribute("id",k=u),r=g(a),h=r.length,l=V.test(k)?"#"+k:"[id='"+k+"']";while(h--)r[h]=l+" "+qa(r[h]);s=r.join(","),w=_.test(a)&&oa(b.parentNode)||b}if(s)try{return H.apply(d,w.querySelectorAll(s)),d}catch(y){}finally{k===u&&b.removeAttribute("id")}}}return i(a.replace(Q,"$1"),b,d,e)}function ga(){var a=[];function b(c,e){return a.push(c+" ")>d.cacheLength&&delete b[a.shift()],b[c+" "]=e}return b}function ha(a){return a[u]=!0,a}function ia(a){var b=n.createElement("div");try{return!!a(b)}catch(c){return!1}finally{b.parentNode&&b.parentNode.removeChild(b),b=null}}function ja(a,b){var c=a.split("|"),e=c.length;while(e--)d.attrHandle[c[e]]=b}function ka(a,b){var c=b&&a,d=c&&1===a.nodeType&&1===b.nodeType&&(~b.sourceIndex||C)-(~a.sourceIndex||C);if(d)return d;if(c)while(c=c.nextSibling)if(c===b)return-1;return a?1:-1}function la(a){return function(b){var c=b.nodeName.toLowerCase();return"input"===c&&b.type===a}}function ma(a){return function(b){var c=b.nodeName.toLowerCase();return("input"===c||"button"===c)&&b.type===a}}function na(a){return ha(function(b){return b=+b,ha(function(c,d){var e,f=a([],c.length,b),g=f.length;while(g--)c[e=f[g]]&&(c[e]=!(d[e]=c[e]))})})}function oa(a){return a&&"undefined"!=typeof a.getElementsByTagName&&a}c=fa.support={},f=fa.isXML=function(a){var b=a&&(a.ownerDocument||a).documentElement;return b?"HTML"!==b.nodeName:!1},m=fa.setDocument=function(a){var b,e,g=a?a.ownerDocument||a:v;return g!==n&&9===g.nodeType&&g.documentElement?(n=g,o=n.documentElement,p=!f(n),(e=n.defaultView)&&e.top!==e&&(e.addEventListener?e.addEventListener("unload",da,!1):e.attachEvent&&e.attachEvent("onunload",da)),c.attributes=ia(function(a){return a.className="i",!a.getAttribute("className")}),c.getElementsByTagName=ia(function(a){return a.appendChild(n.createComment("")),!a.getElementsByTagName("*").length}),c.getElementsByClassName=Z.test(n.getElementsByClassName),c.getById=ia(function(a){return o.appendChild(a).id=u,!n.getElementsByName||!n.getElementsByName(u).length}),c.getById?(d.find.ID=function(a,b){if("undefined"!=typeof b.getElementById&&p){var c=b.getElementById(a);return c?[c]:[]}},d.filter.ID=function(a){var b=a.replace(ba,ca);return function(a){return a.getAttribute("id")===b}}):(delete d.find.ID,d.filter.ID=function(a){var b=a.replace(ba,ca);return function(a){var c="undefined"!=typeof a.getAttributeNode&&a.getAttributeNode("id");return c&&c.value===b}}),d.find.TAG=c.getElementsByTagName?function(a,b){return"undefined"!=typeof b.getElementsByTagName?b.getElementsByTagName(a):c.qsa?b.querySelectorAll(a):void 0}:function(a,b){var c,d=[],e=0,f=b.getElementsByTagName(a);if("*"===a){while(c=f[e++])1===c.nodeType&&d.push(c);return d}return f},d.find.CLASS=c.getElementsByClassName&&function(a,b){return"undefined"!=typeof b.getElementsByClassName&&p?b.getElementsByClassName(a):void 0},r=[],q=[],(c.qsa=Z.test(n.querySelectorAll))&&(ia(function(a){o.appendChild(a).innerHTML="<a id='"+u+"'></a><select id='"+u+"-\r\\' msallowcapture=''><option selected=''></option></select>",a.querySelectorAll("[msallowcapture^='']").length&&q.push("[*^$]="+L+"*(?:''|\"\")"),a.querySelectorAll("[selected]").length||q.push("\\["+L+"*(?:value|"+K+")"),a.querySelectorAll("[id~="+u+"-]").length||q.push("~="),a.querySelectorAll(":checked").length||q.push(":checked"),a.querySelectorAll("a#"+u+"+*").length||q.push(".#.+[+~]")}),ia(function(a){var b=n.createElement("input");b.setAttribute("type","hidden"),a.appendChild(b).setAttribute("name","D"),a.querySelectorAll("[name=d]").length&&q.push("name"+L+"*[*^$|!~]?="),a.querySelectorAll(":enabled").length||q.push(":enabled",":disabled"),a.querySelectorAll("*,:x"),q.push(",.*:")})),(c.matchesSelector=Z.test(s=o.matches||o.webkitMatchesSelector||o.mozMatchesSelector||o.oMatchesSelector||o.msMatchesSelector))&&ia(function(a){c.disconnectedMatch=s.call(a,"div"),s.call(a,"[s!='']:x"),r.push("!=",O)}),q=q.length&&new RegExp(q.join("|")),r=r.length&&new RegExp(r.join("|")),b=Z.test(o.compareDocumentPosition),t=b||Z.test(o.contains)?function(a,b){var c=9===a.nodeType?a.documentElement:a,d=b&&b.parentNode;return a===d||!(!d||1!==d.nodeType||!(c.contains?c.contains(d):a.compareDocumentPosition&&16&a.compareDocumentPosition(d)))}:function(a,b){if(b)while(b=b.parentNode)if(b===a)return!0;return!1},B=b?function(a,b){if(a===b)return l=!0,0;var d=!a.compareDocumentPosition-!b.compareDocumentPosition;return d?d:(d=(a.ownerDocument||a)===(b.ownerDocument||b)?a.compareDocumentPosition(b):1,1&d||!c.sortDetached&&b.compareDocumentPosition(a)===d?a===n||a.ownerDocument===v&&t(v,a)?-1:b===n||b.ownerDocument===v&&t(v,b)?1:k?J(k,a)-J(k,b):0:4&d?-1:1)}:function(a,b){if(a===b)return l=!0,0;var c,d=0,e=a.parentNode,f=b.parentNode,g=[a],h=[b];if(!e||!f)return a===n?-1:b===n?1:e?-1:f?1:k?J(k,a)-J(k,b):0;if(e===f)return ka(a,b);c=a;while(c=c.parentNode)g.unshift(c);c=b;while(c=c.parentNode)h.unshift(c);while(g[d]===h[d])d++;return d?ka(g[d],h[d]):g[d]===v?-1:h[d]===v?1:0},n):n},fa.matches=function(a,b){return fa(a,null,null,b)},fa.matchesSelector=function(a,b){if((a.ownerDocument||a)!==n&&m(a),b=b.replace(T,"='$1']"),c.matchesSelector&&p&&!A[b+" "]&&(!r||!r.test(b))&&(!q||!q.test(b)))try{var d=s.call(a,b);if(d||c.disconnectedMatch||a.document&&11!==a.document.nodeType)return d}catch(e){}return fa(b,n,null,[a]).length>0},fa.contains=function(a,b){return(a.ownerDocument||a)!==n&&m(a),t(a,b)},fa.attr=function(a,b){(a.ownerDocument||a)!==n&&m(a);var e=d.attrHandle[b.toLowerCase()],f=e&&D.call(d.attrHandle,b.toLowerCase())?e(a,b,!p):void 0;return void 0!==f?f:c.attributes||!p?a.getAttribute(b):(f=a.getAttributeNode(b))&&f.specified?f.value:null},fa.error=function(a){throw new Error("Syntax error, unrecognized expression: "+a)},fa.uniqueSort=function(a){var b,d=[],e=0,f=0;if(l=!c.detectDuplicates,k=!c.sortStable&&a.slice(0),a.sort(B),l){while(b=a[f++])b===a[f]&&(e=d.push(f));while(e--)a.splice(d[e],1)}return k=null,a},e=fa.getText=function(a){var b,c="",d=0,f=a.nodeType;if(f){if(1===f||9===f||11===f){if("string"==typeof a.textContent)return a.textContent;for(a=a.firstChild;a;a=a.nextSibling)c+=e(a)}else if(3===f||4===f)return a.nodeValue}else while(b=a[d++])c+=e(b);return c},d=fa.selectors={cacheLength:50,createPseudo:ha,match:W,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(a){return a[1]=a[1].replace(ba,ca),a[3]=(a[3]||a[4]||a[5]||"").replace(ba,ca),"~="===a[2]&&(a[3]=" "+a[3]+" "),a.slice(0,4)},CHILD:function(a){return a[1]=a[1].toLowerCase(),"nth"===a[1].slice(0,3)?(a[3]||fa.error(a[0]),a[4]=+(a[4]?a[5]+(a[6]||1):2*("even"===a[3]||"odd"===a[3])),a[5]=+(a[7]+a[8]||"odd"===a[3])):a[3]&&fa.error(a[0]),a},PSEUDO:function(a){var b,c=!a[6]&&a[2];return W.CHILD.test(a[0])?null:(a[3]?a[2]=a[4]||a[5]||"":c&&U.test(c)&&(b=g(c,!0))&&(b=c.indexOf(")",c.length-b)-c.length)&&(a[0]=a[0].slice(0,b),a[2]=c.slice(0,b)),a.slice(0,3))}},filter:{TAG:function(a){var b=a.replace(ba,ca).toLowerCase();return"*"===a?function(){return!0}:function(a){return a.nodeName&&a.nodeName.toLowerCase()===b}},CLASS:function(a){var b=y[a+" "];return b||(b=new RegExp("(^|"+L+")"+a+"("+L+"|$)"))&&y(a,function(a){return b.test("string"==typeof a.className&&a.className||"undefined"!=typeof a.getAttribute&&a.getAttribute("class")||"")})},ATTR:function(a,b,c){return function(d){var e=fa.attr(d,a);return null==e?"!="===b:b?(e+="","="===b?e===c:"!="===b?e!==c:"^="===b?c&&0===e.indexOf(c):"*="===b?c&&e.indexOf(c)>-1:"$="===b?c&&e.slice(-c.length)===c:"~="===b?(" "+e.replace(P," ")+" ").indexOf(c)>-1:"|="===b?e===c||e.slice(0,c.length+1)===c+"-":!1):!0}},CHILD:function(a,b,c,d,e){var f="nth"!==a.slice(0,3),g="last"!==a.slice(-4),h="of-type"===b;return 1===d&&0===e?function(a){return!!a.parentNode}:function(b,c,i){var j,k,l,m,n,o,p=f!==g?"nextSibling":"previousSibling",q=b.parentNode,r=h&&b.nodeName.toLowerCase(),s=!i&&!h,t=!1;if(q){if(f){while(p){m=b;while(m=m[p])if(h?m.nodeName.toLowerCase()===r:1===m.nodeType)return!1;o=p="only"===a&&!o&&"nextSibling"}return!0}if(o=[g?q.firstChild:q.lastChild],g&&s){m=q,l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),j=k[a]||[],n=j[0]===w&&j[1],t=n&&j[2],m=n&&q.childNodes[n];while(m=++n&&m&&m[p]||(t=n=0)||o.pop())if(1===m.nodeType&&++t&&m===b){k[a]=[w,n,t];break}}else if(s&&(m=b,l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),j=k[a]||[],n=j[0]===w&&j[1],t=n),t===!1)while(m=++n&&m&&m[p]||(t=n=0)||o.pop())if((h?m.nodeName.toLowerCase()===r:1===m.nodeType)&&++t&&(s&&(l=m[u]||(m[u]={}),k=l[m.uniqueID]||(l[m.uniqueID]={}),k[a]=[w,t]),m===b))break;return t-=e,t===d||t%d===0&&t/d>=0}}},PSEUDO:function(a,b){var c,e=d.pseudos[a]||d.setFilters[a.toLowerCase()]||fa.error("unsupported pseudo: "+a);return e[u]?e(b):e.length>1?(c=[a,a,"",b],d.setFilters.hasOwnProperty(a.toLowerCase())?ha(function(a,c){var d,f=e(a,b),g=f.length;while(g--)d=J(a,f[g]),a[d]=!(c[d]=f[g])}):function(a){return e(a,0,c)}):e}},pseudos:{not:ha(function(a){var b=[],c=[],d=h(a.replace(Q,"$1"));return d[u]?ha(function(a,b,c,e){var f,g=d(a,null,e,[]),h=a.length;while(h--)(f=g[h])&&(a[h]=!(b[h]=f))}):function(a,e,f){return b[0]=a,d(b,null,f,c),b[0]=null,!c.pop()}}),has:ha(function(a){return function(b){return fa(a,b).length>0}}),contains:ha(function(a){return a=a.replace(ba,ca),function(b){return(b.textContent||b.innerText||e(b)).indexOf(a)>-1}}),lang:ha(function(a){return V.test(a||"")||fa.error("unsupported lang: "+a),a=a.replace(ba,ca).toLowerCase(),function(b){var c;do if(c=p?b.lang:b.getAttribute("xml:lang")||b.getAttribute("lang"))return c=c.toLowerCase(),c===a||0===c.indexOf(a+"-");while((b=b.parentNode)&&1===b.nodeType);return!1}}),target:function(b){var c=a.location&&a.location.hash;return c&&c.slice(1)===b.id},root:function(a){return a===o},focus:function(a){return a===n.activeElement&&(!n.hasFocus||n.hasFocus())&&!!(a.type||a.href||~a.tabIndex)},enabled:function(a){return a.disabled===!1},disabled:function(a){return a.disabled===!0},checked:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&!!a.checked||"option"===b&&!!a.selected},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,a.selected===!0},empty:function(a){for(a=a.firstChild;a;a=a.nextSibling)if(a.nodeType<6)return!1;return!0},parent:function(a){return!d.pseudos.empty(a)},header:function(a){return Y.test(a.nodeName)},input:function(a){return X.test(a.nodeName)},button:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&"button"===a.type||"button"===b},text:function(a){var b;return"input"===a.nodeName.toLowerCase()&&"text"===a.type&&(null==(b=a.getAttribute("type"))||"text"===b.toLowerCase())},first:na(function(){return[0]}),last:na(function(a,b){return[b-1]}),eq:na(function(a,b,c){return[0>c?c+b:c]}),even:na(function(a,b){for(var c=0;b>c;c+=2)a.push(c);return a}),odd:na(function(a,b){for(var c=1;b>c;c+=2)a.push(c);return a}),lt:na(function(a,b,c){for(var d=0>c?c+b:c;--d>=0;)a.push(d);return a}),gt:na(function(a,b,c){for(var d=0>c?c+b:c;++d<b;)a.push(d);return a})}},d.pseudos.nth=d.pseudos.eq;for(b in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})d.pseudos[b]=la(b);for(b in{submit:!0,reset:!0})d.pseudos[b]=ma(b);function pa(){}pa.prototype=d.filters=d.pseudos,d.setFilters=new pa,g=fa.tokenize=function(a,b){var c,e,f,g,h,i,j,k=z[a+" "];if(k)return b?0:k.slice(0);h=a,i=[],j=d.preFilter;while(h){c&&!(e=R.exec(h))||(e&&(h=h.slice(e[0].length)||h),i.push(f=[])),c=!1,(e=S.exec(h))&&(c=e.shift(),f.push({value:c,type:e[0].replace(Q," ")}),h=h.slice(c.length));for(g in d.filter)!(e=W[g].exec(h))||j[g]&&!(e=j[g](e))||(c=e.shift(),f.push({value:c,type:g,matches:e}),h=h.slice(c.length));if(!c)break}return b?h.length:h?fa.error(a):z(a,i).slice(0)};function qa(a){for(var b=0,c=a.length,d="";c>b;b++)d+=a[b].value;return d}function ra(a,b,c){var d=b.dir,e=c&&"parentNode"===d,f=x++;return b.first?function(b,c,f){while(b=b[d])if(1===b.nodeType||e)return a(b,c,f)}:function(b,c,g){var h,i,j,k=[w,f];if(g){while(b=b[d])if((1===b.nodeType||e)&&a(b,c,g))return!0}else while(b=b[d])if(1===b.nodeType||e){if(j=b[u]||(b[u]={}),i=j[b.uniqueID]||(j[b.uniqueID]={}),(h=i[d])&&h[0]===w&&h[1]===f)return k[2]=h[2];if(i[d]=k,k[2]=a(b,c,g))return!0}}}function sa(a){return a.length>1?function(b,c,d){var e=a.length;while(e--)if(!a[e](b,c,d))return!1;return!0}:a[0]}function ta(a,b,c){for(var d=0,e=b.length;e>d;d++)fa(a,b[d],c);return c}function ua(a,b,c,d,e){for(var f,g=[],h=0,i=a.length,j=null!=b;i>h;h++)(f=a[h])&&(c&&!c(f,d,e)||(g.push(f),j&&b.push(h)));return g}function va(a,b,c,d,e,f){return d&&!d[u]&&(d=va(d)),e&&!e[u]&&(e=va(e,f)),ha(function(f,g,h,i){var j,k,l,m=[],n=[],o=g.length,p=f||ta(b||"*",h.nodeType?[h]:h,[]),q=!a||!f&&b?p:ua(p,m,a,h,i),r=c?e||(f?a:o||d)?[]:g:q;if(c&&c(q,r,h,i),d){j=ua(r,n),d(j,[],h,i),k=j.length;while(k--)(l=j[k])&&(r[n[k]]=!(q[n[k]]=l))}if(f){if(e||a){if(e){j=[],k=r.length;while(k--)(l=r[k])&&j.push(q[k]=l);e(null,r=[],j,i)}k=r.length;while(k--)(l=r[k])&&(j=e?J(f,l):m[k])>-1&&(f[j]=!(g[j]=l))}}else r=ua(r===g?r.splice(o,r.length):r),e?e(null,g,r,i):H.apply(g,r)})}function wa(a){for(var b,c,e,f=a.length,g=d.relative[a[0].type],h=g||d.relative[" "],i=g?1:0,k=ra(function(a){return a===b},h,!0),l=ra(function(a){return J(b,a)>-1},h,!0),m=[function(a,c,d){var e=!g&&(d||c!==j)||((b=c).nodeType?k(a,c,d):l(a,c,d));return b=null,e}];f>i;i++)if(c=d.relative[a[i].type])m=[ra(sa(m),c)];else{if(c=d.filter[a[i].type].apply(null,a[i].matches),c[u]){for(e=++i;f>e;e++)if(d.relative[a[e].type])break;return va(i>1&&sa(m),i>1&&qa(a.slice(0,i-1).concat({value:" "===a[i-2].type?"*":""})).replace(Q,"$1"),c,e>i&&wa(a.slice(i,e)),f>e&&wa(a=a.slice(e)),f>e&&qa(a))}m.push(c)}return sa(m)}function xa(a,b){var c=b.length>0,e=a.length>0,f=function(f,g,h,i,k){var l,o,q,r=0,s="0",t=f&&[],u=[],v=j,x=f||e&&d.find.TAG("*",k),y=w+=null==v?1:Math.random()||.1,z=x.length;for(k&&(j=g===n||g||k);s!==z&&null!=(l=x[s]);s++){if(e&&l){o=0,g||l.ownerDocument===n||(m(l),h=!p);while(q=a[o++])if(q(l,g||n,h)){i.push(l);break}k&&(w=y)}c&&((l=!q&&l)&&r--,f&&t.push(l))}if(r+=s,c&&s!==r){o=0;while(q=b[o++])q(t,u,g,h);if(f){if(r>0)while(s--)t[s]||u[s]||(u[s]=F.call(i));u=ua(u)}H.apply(i,u),k&&!f&&u.length>0&&r+b.length>1&&fa.uniqueSort(i)}return k&&(w=y,j=v),t};return c?ha(f):f}return h=fa.compile=function(a,b){var c,d=[],e=[],f=A[a+" "];if(!f){b||(b=g(a)),c=b.length;while(c--)f=wa(b[c]),f[u]?d.push(f):e.push(f);f=A(a,xa(e,d)),f.selector=a}return f},i=fa.select=function(a,b,e,f){var i,j,k,l,m,n="function"==typeof a&&a,o=!f&&g(a=n.selector||a);if(e=e||[],1===o.length){if(j=o[0]=o[0].slice(0),j.length>2&&"ID"===(k=j[0]).type&&c.getById&&9===b.nodeType&&p&&d.relative[j[1].type]){if(b=(d.find.ID(k.matches[0].replace(ba,ca),b)||[])[0],!b)return e;n&&(b=b.parentNode),a=a.slice(j.shift().value.length)}i=W.needsContext.test(a)?0:j.length;while(i--){if(k=j[i],d.relative[l=k.type])break;if((m=d.find[l])&&(f=m(k.matches[0].replace(ba,ca),_.test(j[0].type)&&oa(b.parentNode)||b))){if(j.splice(i,1),a=f.length&&qa(j),!a)return H.apply(e,f),e;break}}}return(n||h(a,o))(f,b,!p,e,!b||_.test(a)&&oa(b.parentNode)||b),e},c.sortStable=u.split("").sort(B).join("")===u,c.detectDuplicates=!!l,m(),c.sortDetached=ia(function(a){return 1&a.compareDocumentPosition(n.createElement("div"))}),ia(function(a){return a.innerHTML="<a href='#'></a>","#"===a.firstChild.getAttribute("href")})||ja("type|href|height|width",function(a,b,c){return c?void 0:a.getAttribute(b,"type"===b.toLowerCase()?1:2)}),c.attributes&&ia(function(a){return a.innerHTML="<input/>",a.firstChild.setAttribute("value",""),""===a.firstChild.getAttribute("value")})||ja("value",function(a,b,c){return c||"input"!==a.nodeName.toLowerCase()?void 0:a.defaultValue}),ia(function(a){return null==a.getAttribute("disabled")})||ja(K,function(a,b,c){var d;return c?void 0:a[b]===!0?b.toLowerCase():(d=a.getAttributeNode(b))&&d.specified?d.value:null}),fa}(a);n.find=t,n.expr=t.selectors,n.expr[":"]=n.expr.pseudos,n.uniqueSort=n.unique=t.uniqueSort,n.text=t.getText,n.isXMLDoc=t.isXML,n.contains=t.contains;var u=function(a,b,c){var d=[],e=void 0!==c;while((a=a[b])&&9!==a.nodeType)if(1===a.nodeType){if(e&&n(a).is(c))break;d.push(a)}return d},v=function(a,b){for(var c=[];a;a=a.nextSibling)1===a.nodeType&&a!==b&&c.push(a);return c},w=n.expr.match.needsContext,x=/^<([\w-]+)\s*\/?>(?:<\/\1>|)$/,y=/^.[^:#\[\.,]*$/;function z(a,b,c){if(n.isFunction(b))return n.grep(a,function(a,d){return!!b.call(a,d,a)!==c});if(b.nodeType)return n.grep(a,function(a){return a===b!==c});if("string"==typeof b){if(y.test(b))return n.filter(b,a,c);b=n.filter(b,a)}return n.grep(a,function(a){return h.call(b,a)>-1!==c})}n.filter=function(a,b,c){var d=b[0];return c&&(a=":not("+a+")"),1===b.length&&1===d.nodeType?n.find.matchesSelector(d,a)?[d]:[]:n.find.matches(a,n.grep(b,function(a){return 1===a.nodeType}))},n.fn.extend({find:function(a){var b,c=this.length,d=[],e=this;if("string"!=typeof a)return this.pushStack(n(a).filter(function(){for(b=0;c>b;b++)if(n.contains(e[b],this))return!0}));for(b=0;c>b;b++)n.find(a,e[b],d);return d=this.pushStack(c>1?n.unique(d):d),d.selector=this.selector?this.selector+" "+a:a,d},filter:function(a){return this.pushStack(z(this,a||[],!1))},not:function(a){return this.pushStack(z(this,a||[],!0))},is:function(a){return!!z(this,"string"==typeof a&&w.test(a)?n(a):a||[],!1).length}});var A,B=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,C=n.fn.init=function(a,b,c){var e,f;if(!a)return this;if(c=c||A,"string"==typeof a){if(e="<"===a[0]&&">"===a[a.length-1]&&a.length>=3?[null,a,null]:B.exec(a),!e||!e[1]&&b)return!b||b.jquery?(b||c).find(a):this.constructor(b).find(a);if(e[1]){if(b=b instanceof n?b[0]:b,n.merge(this,n.parseHTML(e[1],b&&b.nodeType?b.ownerDocument||b:d,!0)),x.test(e[1])&&n.isPlainObject(b))for(e in b)n.isFunction(this[e])?this[e](b[e]):this.attr(e,b[e]);return this}return f=d.getElementById(e[2]),f&&f.parentNode&&(this.length=1,this[0]=f),this.context=d,this.selector=a,this}return a.nodeType?(this.context=this[0]=a,this.length=1,this):n.isFunction(a)?void 0!==c.ready?c.ready(a):a(n):(void 0!==a.selector&&(this.selector=a.selector,this.context=a.context),n.makeArray(a,this))};C.prototype=n.fn,A=n(d);var D=/^(?:parents|prev(?:Until|All))/,E={children:!0,contents:!0,next:!0,prev:!0};n.fn.extend({has:function(a){var b=n(a,this),c=b.length;return this.filter(function(){for(var a=0;c>a;a++)if(n.contains(this,b[a]))return!0})},closest:function(a,b){for(var c,d=0,e=this.length,f=[],g=w.test(a)||"string"!=typeof a?n(a,b||this.context):0;e>d;d++)for(c=this[d];c&&c!==b;c=c.parentNode)if(c.nodeType<11&&(g?g.index(c)>-1:1===c.nodeType&&n.find.matchesSelector(c,a))){f.push(c);break}return this.pushStack(f.length>1?n.uniqueSort(f):f)},index:function(a){return a?"string"==typeof a?h.call(n(a),this[0]):h.call(this,a.jquery?a[0]:a):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(a,b){return this.pushStack(n.uniqueSort(n.merge(this.get(),n(a,b))))},addBack:function(a){return this.add(null==a?this.prevObject:this.prevObject.filter(a))}});function F(a,b){while((a=a[b])&&1!==a.nodeType);return a}n.each({parent:function(a){var b=a.parentNode;return b&&11!==b.nodeType?b:null},parents:function(a){return u(a,"parentNode")},parentsUntil:function(a,b,c){return u(a,"parentNode",c)},next:function(a){return F(a,"nextSibling")},prev:function(a){return F(a,"previousSibling")},nextAll:function(a){return u(a,"nextSibling")},prevAll:function(a){return u(a,"previousSibling")},nextUntil:function(a,b,c){return u(a,"nextSibling",c)},prevUntil:function(a,b,c){return u(a,"previousSibling",c)},siblings:function(a){return v((a.parentNode||{}).firstChild,a)},children:function(a){return v(a.firstChild)},contents:function(a){return a.contentDocument||n.merge([],a.childNodes)}},function(a,b){n.fn[a]=function(c,d){var e=n.map(this,b,c);return"Until"!==a.slice(-5)&&(d=c),d&&"string"==typeof d&&(e=n.filter(d,e)),this.length>1&&(E[a]||n.uniqueSort(e),D.test(a)&&e.reverse()),this.pushStack(e)}});var G=/\S+/g;function H(a){var b={};return n.each(a.match(G)||[],function(a,c){b[c]=!0}),b}n.Callbacks=function(a){a="string"==typeof a?H(a):n.extend({},a);var b,c,d,e,f=[],g=[],h=-1,i=function(){for(e=a.once,d=b=!0;g.length;h=-1){c=g.shift();while(++h<f.length)f[h].apply(c[0],c[1])===!1&&a.stopOnFalse&&(h=f.length,c=!1)}a.memory||(c=!1),b=!1,e&&(f=c?[]:"")},j={add:function(){return f&&(c&&!b&&(h=f.length-1,g.push(c)),function d(b){n.each(b,function(b,c){n.isFunction(c)?a.unique&&j.has(c)||f.push(c):c&&c.length&&"string"!==n.type(c)&&d(c)})}(arguments),c&&!b&&i()),this},remove:function(){return n.each(arguments,function(a,b){var c;while((c=n.inArray(b,f,c))>-1)f.splice(c,1),h>=c&&h--}),this},has:function(a){return a?n.inArray(a,f)>-1:f.length>0},empty:function(){return f&&(f=[]),this},disable:function(){return e=g=[],f=c="",this},disabled:function(){return!f},lock:function(){return e=g=[],c||(f=c=""),this},locked:function(){return!!e},fireWith:function(a,c){return e||(c=c||[],c=[a,c.slice?c.slice():c],g.push(c),b||i()),this},fire:function(){return j.fireWith(this,arguments),this},fired:function(){return!!d}};return j},n.extend({Deferred:function(a){var b=[["resolve","done",n.Callbacks("once memory"),"resolved"],["reject","fail",n.Callbacks("once memory"),"rejected"],["notify","progress",n.Callbacks("memory")]],c="pending",d={state:function(){return c},always:function(){return e.done(arguments).fail(arguments),this},then:function(){var a=arguments;return n.Deferred(function(c){n.each(b,function(b,f){var g=n.isFunction(a[b])&&a[b];e[f[1]](function(){var a=g&&g.apply(this,arguments);a&&n.isFunction(a.promise)?a.promise().progress(c.notify).done(c.resolve).fail(c.reject):c[f[0]+"With"](this===d?c.promise():this,g?[a]:arguments)})}),a=null}).promise()},promise:function(a){return null!=a?n.extend(a,d):d}},e={};return d.pipe=d.then,n.each(b,function(a,f){var g=f[2],h=f[3];d[f[1]]=g.add,h&&g.add(function(){c=h},b[1^a][2].disable,b[2][2].lock),e[f[0]]=function(){return e[f[0]+"With"](this===e?d:this,arguments),this},e[f[0]+"With"]=g.fireWith}),d.promise(e),a&&a.call(e,e),e},when:function(a){var b=0,c=e.call(arguments),d=c.length,f=1!==d||a&&n.isFunction(a.promise)?d:0,g=1===f?a:n.Deferred(),h=function(a,b,c){return function(d){b[a]=this,c[a]=arguments.length>1?e.call(arguments):d,c===i?g.notifyWith(b,c):--f||g.resolveWith(b,c)}},i,j,k;if(d>1)for(i=new Array(d),j=new Array(d),k=new Array(d);d>b;b++)c[b]&&n.isFunction(c[b].promise)?c[b].promise().progress(h(b,j,i)).done(h(b,k,c)).fail(g.reject):--f;return f||g.resolveWith(k,c),g.promise()}});var I;n.fn.ready=function(a){return n.ready.promise().done(a),this},n.extend({isReady:!1,readyWait:1,holdReady:function(a){a?n.readyWait++:n.ready(!0)},ready:function(a){(a===!0?--n.readyWait:n.isReady)||(n.isReady=!0,a!==!0&&--n.readyWait>0||(I.resolveWith(d,[n]),n.fn.triggerHandler&&(n(d).triggerHandler("ready"),n(d).off("ready"))))}});function J(){d.removeEventListener("DOMContentLoaded",J),a.removeEventListener("load",J),n.ready()}n.ready.promise=function(b){return I||(I=n.Deferred(),"complete"===d.readyState||"loading"!==d.readyState&&!d.documentElement.doScroll?a.setTimeout(n.ready):(d.addEventListener("DOMContentLoaded",J),a.addEventListener("load",J))),I.promise(b)},n.ready.promise();var K=function(a,b,c,d,e,f,g){var h=0,i=a.length,j=null==c;if("object"===n.type(c)){e=!0;for(h in c)K(a,b,h,c[h],!0,f,g)}else if(void 0!==d&&(e=!0,n.isFunction(d)||(g=!0),j&&(g?(b.call(a,d),b=null):(j=b,b=function(a,b,c){return j.call(n(a),c)})),b))for(;i>h;h++)b(a[h],c,g?d:d.call(a[h],h,b(a[h],c)));return e?a:j?b.call(a):i?b(a[0],c):f},L=function(a){return 1===a.nodeType||9===a.nodeType||!+a.nodeType};function M(){this.expando=n.expando+M.uid++}M.uid=1,M.prototype={register:function(a,b){var c=b||{};return a.nodeType?a[this.expando]=c:Object.defineProperty(a,this.expando,{value:c,writable:!0,configurable:!0}),a[this.expando]},cache:function(a){if(!L(a))return{};var b=a[this.expando];return b||(b={},L(a)&&(a.nodeType?a[this.expando]=b:Object.defineProperty(a,this.expando,{value:b,configurable:!0}))),b},set:function(a,b,c){var d,e=this.cache(a);if("string"==typeof b)e[b]=c;else for(d in b)e[d]=b[d];return e},get:function(a,b){return void 0===b?this.cache(a):a[this.expando]&&a[this.expando][b]},access:function(a,b,c){var d;return void 0===b||b&&"string"==typeof b&&void 0===c?(d=this.get(a,b),void 0!==d?d:this.get(a,n.camelCase(b))):(this.set(a,b,c),void 0!==c?c:b)},remove:function(a,b){var c,d,e,f=a[this.expando];if(void 0!==f){if(void 0===b)this.register(a);else{n.isArray(b)?d=b.concat(b.map(n.camelCase)):(e=n.camelCase(b),b in f?d=[b,e]:(d=e,d=d in f?[d]:d.match(G)||[])),c=d.length;while(c--)delete f[d[c]]}(void 0===b||n.isEmptyObject(f))&&(a.nodeType?a[this.expando]=void 0:delete a[this.expando])}},hasData:function(a){var b=a[this.expando];return void 0!==b&&!n.isEmptyObject(b)}};var N=new M,O=new M,P=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,Q=/[A-Z]/g;function R(a,b,c){var d;if(void 0===c&&1===a.nodeType)if(d="data-"+b.replace(Q,"-$&").toLowerCase(),c=a.getAttribute(d),"string"==typeof c){try{c="true"===c?!0:"false"===c?!1:"null"===c?null:+c+""===c?+c:P.test(c)?n.parseJSON(c):c; }catch(e){}O.set(a,b,c)}else c=void 0;return c}n.extend({hasData:function(a){return O.hasData(a)||N.hasData(a)},data:function(a,b,c){return O.access(a,b,c)},removeData:function(a,b){O.remove(a,b)},_data:function(a,b,c){return N.access(a,b,c)},_removeData:function(a,b){N.remove(a,b)}}),n.fn.extend({data:function(a,b){var c,d,e,f=this[0],g=f&&f.attributes;if(void 0===a){if(this.length&&(e=O.get(f),1===f.nodeType&&!N.get(f,"hasDataAttrs"))){c=g.length;while(c--)g[c]&&(d=g[c].name,0===d.indexOf("data-")&&(d=n.camelCase(d.slice(5)),R(f,d,e[d])));N.set(f,"hasDataAttrs",!0)}return e}return"object"==typeof a?this.each(function(){O.set(this,a)}):K(this,function(b){var c,d;if(f&&void 0===b){if(c=O.get(f,a)||O.get(f,a.replace(Q,"-$&").toLowerCase()),void 0!==c)return c;if(d=n.camelCase(a),c=O.get(f,d),void 0!==c)return c;if(c=R(f,d,void 0),void 0!==c)return c}else d=n.camelCase(a),this.each(function(){var c=O.get(this,d);O.set(this,d,b),a.indexOf("-")>-1&&void 0!==c&&O.set(this,a,b)})},null,b,arguments.length>1,null,!0)},removeData:function(a){return this.each(function(){O.remove(this,a)})}}),n.extend({queue:function(a,b,c){var d;return a?(b=(b||"fx")+"queue",d=N.get(a,b),c&&(!d||n.isArray(c)?d=N.access(a,b,n.makeArray(c)):d.push(c)),d||[]):void 0},dequeue:function(a,b){b=b||"fx";var c=n.queue(a,b),d=c.length,e=c.shift(),f=n._queueHooks(a,b),g=function(){n.dequeue(a,b)};"inprogress"===e&&(e=c.shift(),d--),e&&("fx"===b&&c.unshift("inprogress"),delete f.stop,e.call(a,g,f)),!d&&f&&f.empty.fire()},_queueHooks:function(a,b){var c=b+"queueHooks";return N.get(a,c)||N.access(a,c,{empty:n.Callbacks("once memory").add(function(){N.remove(a,[b+"queue",c])})})}}),n.fn.extend({queue:function(a,b){var c=2;return"string"!=typeof a&&(b=a,a="fx",c--),arguments.length<c?n.queue(this[0],a):void 0===b?this:this.each(function(){var c=n.queue(this,a,b);n._queueHooks(this,a),"fx"===a&&"inprogress"!==c[0]&&n.dequeue(this,a)})},dequeue:function(a){return this.each(function(){n.dequeue(this,a)})},clearQueue:function(a){return this.queue(a||"fx",[])},promise:function(a,b){var c,d=1,e=n.Deferred(),f=this,g=this.length,h=function(){--d||e.resolveWith(f,[f])};"string"!=typeof a&&(b=a,a=void 0),a=a||"fx";while(g--)c=N.get(f[g],a+"queueHooks"),c&&c.empty&&(d++,c.empty.add(h));return h(),e.promise(b)}});var S=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,T=new RegExp("^(?:([+-])=|)("+S+")([a-z%]*)$","i"),U=["Top","Right","Bottom","Left"],V=function(a,b){return a=b||a,"none"===n.css(a,"display")||!n.contains(a.ownerDocument,a)};function W(a,b,c,d){var e,f=1,g=20,h=d?function(){return d.cur()}:function(){return n.css(a,b,"")},i=h(),j=c&&c[3]||(n.cssNumber[b]?"":"px"),k=(n.cssNumber[b]||"px"!==j&&+i)&&T.exec(n.css(a,b));if(k&&k[3]!==j){j=j||k[3],c=c||[],k=+i||1;do f=f||".5",k/=f,n.style(a,b,k+j);while(f!==(f=h()/i)&&1!==f&&--g)}return c&&(k=+k||+i||0,e=c[1]?k+(c[1]+1)*c[2]:+c[2],d&&(d.unit=j,d.start=k,d.end=e)),e}var X=/^(?:checkbox|radio)$/i,Y=/<([\w:-]+)/,Z=/^$|\/(?:java|ecma)script/i,$={option:[1,"<select multiple='multiple'>","</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};$.optgroup=$.option,$.tbody=$.tfoot=$.colgroup=$.caption=$.thead,$.th=$.td;function _(a,b){var c="undefined"!=typeof a.getElementsByTagName?a.getElementsByTagName(b||"*"):"undefined"!=typeof a.querySelectorAll?a.querySelectorAll(b||"*"):[];return void 0===b||b&&n.nodeName(a,b)?n.merge([a],c):c}function aa(a,b){for(var c=0,d=a.length;d>c;c++)N.set(a[c],"globalEval",!b||N.get(b[c],"globalEval"))}var ba=/<|&#?\w+;/;function ca(a,b,c,d,e){for(var f,g,h,i,j,k,l=b.createDocumentFragment(),m=[],o=0,p=a.length;p>o;o++)if(f=a[o],f||0===f)if("object"===n.type(f))n.merge(m,f.nodeType?[f]:f);else if(ba.test(f)){g=g||l.appendChild(b.createElement("div")),h=(Y.exec(f)||["",""])[1].toLowerCase(),i=$[h]||$._default,g.innerHTML=i[1]+n.htmlPrefilter(f)+i[2],k=i[0];while(k--)g=g.lastChild;n.merge(m,g.childNodes),g=l.firstChild,g.textContent=""}else m.push(b.createTextNode(f));l.textContent="",o=0;while(f=m[o++])if(d&&n.inArray(f,d)>-1)e&&e.push(f);else if(j=n.contains(f.ownerDocument,f),g=_(l.appendChild(f),"script"),j&&aa(g),c){k=0;while(f=g[k++])Z.test(f.type||"")&&c.push(f)}return l}!function(){var a=d.createDocumentFragment(),b=a.appendChild(d.createElement("div")),c=d.createElement("input");c.setAttribute("type","radio"),c.setAttribute("checked","checked"),c.setAttribute("name","t"),b.appendChild(c),l.checkClone=b.cloneNode(!0).cloneNode(!0).lastChild.checked,b.innerHTML="<textarea>x</textarea>",l.noCloneChecked=!!b.cloneNode(!0).lastChild.defaultValue}();var da=/^key/,ea=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,fa=/^([^.]*)(?:\.(.+)|)/;function ga(){return!0}function ha(){return!1}function ia(){try{return d.activeElement}catch(a){}}function ja(a,b,c,d,e,f){var g,h;if("object"==typeof b){"string"!=typeof c&&(d=d||c,c=void 0);for(h in b)ja(a,h,c,d,b[h],f);return a}if(null==d&&null==e?(e=c,d=c=void 0):null==e&&("string"==typeof c?(e=d,d=void 0):(e=d,d=c,c=void 0)),e===!1)e=ha;else if(!e)return a;return 1===f&&(g=e,e=function(a){return n().off(a),g.apply(this,arguments)},e.guid=g.guid||(g.guid=n.guid++)),a.each(function(){n.event.add(this,b,e,d,c)})}n.event={global:{},add:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=N.get(a);if(r){c.handler&&(f=c,c=f.handler,e=f.selector),c.guid||(c.guid=n.guid++),(i=r.events)||(i=r.events={}),(g=r.handle)||(g=r.handle=function(b){return"undefined"!=typeof n&&n.event.triggered!==b.type?n.event.dispatch.apply(a,arguments):void 0}),b=(b||"").match(G)||[""],j=b.length;while(j--)h=fa.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o&&(l=n.event.special[o]||{},o=(e?l.delegateType:l.bindType)||o,l=n.event.special[o]||{},k=n.extend({type:o,origType:q,data:d,handler:c,guid:c.guid,selector:e,needsContext:e&&n.expr.match.needsContext.test(e),namespace:p.join(".")},f),(m=i[o])||(m=i[o]=[],m.delegateCount=0,l.setup&&l.setup.call(a,d,p,g)!==!1||a.addEventListener&&a.addEventListener(o,g)),l.add&&(l.add.call(a,k),k.handler.guid||(k.handler.guid=c.guid)),e?m.splice(m.delegateCount++,0,k):m.push(k),n.event.global[o]=!0)}},remove:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,o,p,q,r=N.hasData(a)&&N.get(a);if(r&&(i=r.events)){b=(b||"").match(G)||[""],j=b.length;while(j--)if(h=fa.exec(b[j])||[],o=q=h[1],p=(h[2]||"").split(".").sort(),o){l=n.event.special[o]||{},o=(d?l.delegateType:l.bindType)||o,m=i[o]||[],h=h[2]&&new RegExp("(^|\\.)"+p.join("\\.(?:.*\\.|)")+"(\\.|$)"),g=f=m.length;while(f--)k=m[f],!e&&q!==k.origType||c&&c.guid!==k.guid||h&&!h.test(k.namespace)||d&&d!==k.selector&&("**"!==d||!k.selector)||(m.splice(f,1),k.selector&&m.delegateCount--,l.remove&&l.remove.call(a,k));g&&!m.length&&(l.teardown&&l.teardown.call(a,p,r.handle)!==!1||n.removeEvent(a,o,r.handle),delete i[o])}else for(o in i)n.event.remove(a,o+b[j],c,d,!0);n.isEmptyObject(i)&&N.remove(a,"handle events")}},dispatch:function(a){a=n.event.fix(a);var b,c,d,f,g,h=[],i=e.call(arguments),j=(N.get(this,"events")||{})[a.type]||[],k=n.event.special[a.type]||{};if(i[0]=a,a.delegateTarget=this,!k.preDispatch||k.preDispatch.call(this,a)!==!1){h=n.event.handlers.call(this,a,j),b=0;while((f=h[b++])&&!a.isPropagationStopped()){a.currentTarget=f.elem,c=0;while((g=f.handlers[c++])&&!a.isImmediatePropagationStopped())a.rnamespace&&!a.rnamespace.test(g.namespace)||(a.handleObj=g,a.data=g.data,d=((n.event.special[g.origType]||{}).handle||g.handler).apply(f.elem,i),void 0!==d&&(a.result=d)===!1&&(a.preventDefault(),a.stopPropagation()))}return k.postDispatch&&k.postDispatch.call(this,a),a.result}},handlers:function(a,b){var c,d,e,f,g=[],h=b.delegateCount,i=a.target;if(h&&i.nodeType&&("click"!==a.type||isNaN(a.button)||a.button<1))for(;i!==this;i=i.parentNode||this)if(1===i.nodeType&&(i.disabled!==!0||"click"!==a.type)){for(d=[],c=0;h>c;c++)f=b[c],e=f.selector+" ",void 0===d[e]&&(d[e]=f.needsContext?n(e,this).index(i)>-1:n.find(e,this,null,[i]).length),d[e]&&d.push(f);d.length&&g.push({elem:i,handlers:d})}return h<b.length&&g.push({elem:this,handlers:b.slice(h)}),g},props:"altKey bubbles cancelable ctrlKey currentTarget detail eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(a,b){return null==a.which&&(a.which=null!=b.charCode?b.charCode:b.keyCode),a}},mouseHooks:{props:"button buttons clientX clientY offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(a,b){var c,e,f,g=b.button;return null==a.pageX&&null!=b.clientX&&(c=a.target.ownerDocument||d,e=c.documentElement,f=c.body,a.pageX=b.clientX+(e&&e.scrollLeft||f&&f.scrollLeft||0)-(e&&e.clientLeft||f&&f.clientLeft||0),a.pageY=b.clientY+(e&&e.scrollTop||f&&f.scrollTop||0)-(e&&e.clientTop||f&&f.clientTop||0)),a.which||void 0===g||(a.which=1&g?1:2&g?3:4&g?2:0),a}},fix:function(a){if(a[n.expando])return a;var b,c,e,f=a.type,g=a,h=this.fixHooks[f];h||(this.fixHooks[f]=h=ea.test(f)?this.mouseHooks:da.test(f)?this.keyHooks:{}),e=h.props?this.props.concat(h.props):this.props,a=new n.Event(g),b=e.length;while(b--)c=e[b],a[c]=g[c];return a.target||(a.target=d),3===a.target.nodeType&&(a.target=a.target.parentNode),h.filter?h.filter(a,g):a},special:{load:{noBubble:!0},focus:{trigger:function(){return this!==ia()&&this.focus?(this.focus(),!1):void 0},delegateType:"focusin"},blur:{trigger:function(){return this===ia()&&this.blur?(this.blur(),!1):void 0},delegateType:"focusout"},click:{trigger:function(){return"checkbox"===this.type&&this.click&&n.nodeName(this,"input")?(this.click(),!1):void 0},_default:function(a){return n.nodeName(a.target,"a")}},beforeunload:{postDispatch:function(a){void 0!==a.result&&a.originalEvent&&(a.originalEvent.returnValue=a.result)}}}},n.removeEvent=function(a,b,c){a.removeEventListener&&a.removeEventListener(b,c)},n.Event=function(a,b){return this instanceof n.Event?(a&&a.type?(this.originalEvent=a,this.type=a.type,this.isDefaultPrevented=a.defaultPrevented||void 0===a.defaultPrevented&&a.returnValue===!1?ga:ha):this.type=a,b&&n.extend(this,b),this.timeStamp=a&&a.timeStamp||n.now(),void(this[n.expando]=!0)):new n.Event(a,b)},n.Event.prototype={constructor:n.Event,isDefaultPrevented:ha,isPropagationStopped:ha,isImmediatePropagationStopped:ha,preventDefault:function(){var a=this.originalEvent;this.isDefaultPrevented=ga,a&&a.preventDefault()},stopPropagation:function(){var a=this.originalEvent;this.isPropagationStopped=ga,a&&a.stopPropagation()},stopImmediatePropagation:function(){var a=this.originalEvent;this.isImmediatePropagationStopped=ga,a&&a.stopImmediatePropagation(),this.stopPropagation()}},n.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(a,b){n.event.special[a]={delegateType:b,bindType:b,handle:function(a){var c,d=this,e=a.relatedTarget,f=a.handleObj;return e&&(e===d||n.contains(d,e))||(a.type=f.origType,c=f.handler.apply(this,arguments),a.type=b),c}}}),n.fn.extend({on:function(a,b,c,d){return ja(this,a,b,c,d)},one:function(a,b,c,d){return ja(this,a,b,c,d,1)},off:function(a,b,c){var d,e;if(a&&a.preventDefault&&a.handleObj)return d=a.handleObj,n(a.delegateTarget).off(d.namespace?d.origType+"."+d.namespace:d.origType,d.selector,d.handler),this;if("object"==typeof a){for(e in a)this.off(e,b,a[e]);return this}return b!==!1&&"function"!=typeof b||(c=b,b=void 0),c===!1&&(c=ha),this.each(function(){n.event.remove(this,a,c,b)})}});var ka=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:-]+)[^>]*)\/>/gi,la=/<script|<style|<link/i,ma=/checked\s*(?:[^=]|=\s*.checked.)/i,na=/^true\/(.*)/,oa=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g;function pa(a,b){return n.nodeName(a,"table")&&n.nodeName(11!==b.nodeType?b:b.firstChild,"tr")?a.getElementsByTagName("tbody")[0]||a.appendChild(a.ownerDocument.createElement("tbody")):a}function qa(a){return a.type=(null!==a.getAttribute("type"))+"/"+a.type,a}function ra(a){var b=na.exec(a.type);return b?a.type=b[1]:a.removeAttribute("type"),a}function sa(a,b){var c,d,e,f,g,h,i,j;if(1===b.nodeType){if(N.hasData(a)&&(f=N.access(a),g=N.set(b,f),j=f.events)){delete g.handle,g.events={};for(e in j)for(c=0,d=j[e].length;d>c;c++)n.event.add(b,e,j[e][c])}O.hasData(a)&&(h=O.access(a),i=n.extend({},h),O.set(b,i))}}function ta(a,b){var c=b.nodeName.toLowerCase();"input"===c&&X.test(a.type)?b.checked=a.checked:"input"!==c&&"textarea"!==c||(b.defaultValue=a.defaultValue)}function ua(a,b,c,d){b=f.apply([],b);var e,g,h,i,j,k,m=0,o=a.length,p=o-1,q=b[0],r=n.isFunction(q);if(r||o>1&&"string"==typeof q&&!l.checkClone&&ma.test(q))return a.each(function(e){var f=a.eq(e);r&&(b[0]=q.call(this,e,f.html())),ua(f,b,c,d)});if(o&&(e=ca(b,a[0].ownerDocument,!1,a,d),g=e.firstChild,1===e.childNodes.length&&(e=g),g||d)){for(h=n.map(_(e,"script"),qa),i=h.length;o>m;m++)j=e,m!==p&&(j=n.clone(j,!0,!0),i&&n.merge(h,_(j,"script"))),c.call(a[m],j,m);if(i)for(k=h[h.length-1].ownerDocument,n.map(h,ra),m=0;i>m;m++)j=h[m],Z.test(j.type||"")&&!N.access(j,"globalEval")&&n.contains(k,j)&&(j.src?n._evalUrl&&n._evalUrl(j.src):n.globalEval(j.textContent.replace(oa,"")))}return a}function va(a,b,c){for(var d,e=b?n.filter(b,a):a,f=0;null!=(d=e[f]);f++)c||1!==d.nodeType||n.cleanData(_(d)),d.parentNode&&(c&&n.contains(d.ownerDocument,d)&&aa(_(d,"script")),d.parentNode.removeChild(d));return a}n.extend({htmlPrefilter:function(a){return a.replace(ka,"<$1></$2>")},clone:function(a,b,c){var d,e,f,g,h=a.cloneNode(!0),i=n.contains(a.ownerDocument,a);if(!(l.noCloneChecked||1!==a.nodeType&&11!==a.nodeType||n.isXMLDoc(a)))for(g=_(h),f=_(a),d=0,e=f.length;e>d;d++)ta(f[d],g[d]);if(b)if(c)for(f=f||_(a),g=g||_(h),d=0,e=f.length;e>d;d++)sa(f[d],g[d]);else sa(a,h);return g=_(h,"script"),g.length>0&&aa(g,!i&&_(a,"script")),h},cleanData:function(a){for(var b,c,d,e=n.event.special,f=0;void 0!==(c=a[f]);f++)if(L(c)){if(b=c[N.expando]){if(b.events)for(d in b.events)e[d]?n.event.remove(c,d):n.removeEvent(c,d,b.handle);c[N.expando]=void 0}c[O.expando]&&(c[O.expando]=void 0)}}}),n.fn.extend({domManip:ua,detach:function(a){return va(this,a,!0)},remove:function(a){return va(this,a)},text:function(a){return K(this,function(a){return void 0===a?n.text(this):this.empty().each(function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=a)})},null,a,arguments.length)},append:function(){return ua(this,arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=pa(this,a);b.appendChild(a)}})},prepend:function(){return ua(this,arguments,function(a){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var b=pa(this,a);b.insertBefore(a,b.firstChild)}})},before:function(){return ua(this,arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this)})},after:function(){return ua(this,arguments,function(a){this.parentNode&&this.parentNode.insertBefore(a,this.nextSibling)})},empty:function(){for(var a,b=0;null!=(a=this[b]);b++)1===a.nodeType&&(n.cleanData(_(a,!1)),a.textContent="");return this},clone:function(a,b){return a=null==a?!1:a,b=null==b?a:b,this.map(function(){return n.clone(this,a,b)})},html:function(a){return K(this,function(a){var b=this[0]||{},c=0,d=this.length;if(void 0===a&&1===b.nodeType)return b.innerHTML;if("string"==typeof a&&!la.test(a)&&!$[(Y.exec(a)||["",""])[1].toLowerCase()]){a=n.htmlPrefilter(a);try{for(;d>c;c++)b=this[c]||{},1===b.nodeType&&(n.cleanData(_(b,!1)),b.innerHTML=a);b=0}catch(e){}}b&&this.empty().append(a)},null,a,arguments.length)},replaceWith:function(){var a=[];return ua(this,arguments,function(b){var c=this.parentNode;n.inArray(this,a)<0&&(n.cleanData(_(this)),c&&c.replaceChild(b,this))},a)}}),n.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){n.fn[a]=function(a){for(var c,d=[],e=n(a),f=e.length-1,h=0;f>=h;h++)c=h===f?this:this.clone(!0),n(e[h])[b](c),g.apply(d,c.get());return this.pushStack(d)}});var wa,xa={HTML:"block",BODY:"block"};function ya(a,b){var c=n(b.createElement(a)).appendTo(b.body),d=n.css(c[0],"display");return c.detach(),d}function za(a){var b=d,c=xa[a];return c||(c=ya(a,b),"none"!==c&&c||(wa=(wa||n("<iframe frameborder='0' width='0' height='0'/>")).appendTo(b.documentElement),b=wa[0].contentDocument,b.write(),b.close(),c=ya(a,b),wa.detach()),xa[a]=c),c}var Aa=/^margin/,Ba=new RegExp("^("+S+")(?!px)[a-z%]+$","i"),Ca=function(b){var c=b.ownerDocument.defaultView;return c&&c.opener||(c=a),c.getComputedStyle(b)},Da=function(a,b,c,d){var e,f,g={};for(f in b)g[f]=a.style[f],a.style[f]=b[f];e=c.apply(a,d||[]);for(f in b)a.style[f]=g[f];return e},Ea=d.documentElement;!function(){var b,c,e,f,g=d.createElement("div"),h=d.createElement("div");if(h.style){h.style.backgroundClip="content-box",h.cloneNode(!0).style.backgroundClip="",l.clearCloneStyle="content-box"===h.style.backgroundClip,g.style.cssText="border:0;width:8px;height:0;top:0;left:-9999px;padding:0;margin-top:1px;position:absolute",g.appendChild(h);function i(){h.style.cssText="-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;position:relative;display:block;margin:auto;border:1px;padding:1px;top:1%;width:50%",h.innerHTML="",Ea.appendChild(g);var d=a.getComputedStyle(h);b="1%"!==d.top,f="2px"===d.marginLeft,c="4px"===d.width,h.style.marginRight="50%",e="4px"===d.marginRight,Ea.removeChild(g)}n.extend(l,{pixelPosition:function(){return i(),b},boxSizingReliable:function(){return null==c&&i(),c},pixelMarginRight:function(){return null==c&&i(),e},reliableMarginLeft:function(){return null==c&&i(),f},reliableMarginRight:function(){var b,c=h.appendChild(d.createElement("div"));return c.style.cssText=h.style.cssText="-webkit-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:0",c.style.marginRight=c.style.width="0",h.style.width="1px",Ea.appendChild(g),b=!parseFloat(a.getComputedStyle(c).marginRight),Ea.removeChild(g),h.removeChild(c),b}})}}();function Fa(a,b,c){var d,e,f,g,h=a.style;return c=c||Ca(a),g=c?c.getPropertyValue(b)||c[b]:void 0,""!==g&&void 0!==g||n.contains(a.ownerDocument,a)||(g=n.style(a,b)),c&&!l.pixelMarginRight()&&Ba.test(g)&&Aa.test(b)&&(d=h.width,e=h.minWidth,f=h.maxWidth,h.minWidth=h.maxWidth=h.width=g,g=c.width,h.width=d,h.minWidth=e,h.maxWidth=f),void 0!==g?g+"":g}function Ga(a,b){return{get:function(){return a()?void delete this.get:(this.get=b).apply(this,arguments)}}}var Ha=/^(none|table(?!-c[ea]).+)/,Ia={position:"absolute",visibility:"hidden",display:"block"},Ja={letterSpacing:"0",fontWeight:"400"},Ka=["Webkit","O","Moz","ms"],La=d.createElement("div").style;function Ma(a){if(a in La)return a;var b=a[0].toUpperCase()+a.slice(1),c=Ka.length;while(c--)if(a=Ka[c]+b,a in La)return a}function Na(a,b,c){var d=T.exec(b);return d?Math.max(0,d[2]-(c||0))+(d[3]||"px"):b}function Oa(a,b,c,d,e){for(var f=c===(d?"border":"content")?4:"width"===b?1:0,g=0;4>f;f+=2)"margin"===c&&(g+=n.css(a,c+U[f],!0,e)),d?("content"===c&&(g-=n.css(a,"padding"+U[f],!0,e)),"margin"!==c&&(g-=n.css(a,"border"+U[f]+"Width",!0,e))):(g+=n.css(a,"padding"+U[f],!0,e),"padding"!==c&&(g+=n.css(a,"border"+U[f]+"Width",!0,e)));return g}function Pa(b,c,e){var f=!0,g="width"===c?b.offsetWidth:b.offsetHeight,h=Ca(b),i="border-box"===n.css(b,"boxSizing",!1,h);if(d.msFullscreenElement&&a.top!==a&&b.getClientRects().length&&(g=Math.round(100*b.getBoundingClientRect()[c])),0>=g||null==g){if(g=Fa(b,c,h),(0>g||null==g)&&(g=b.style[c]),Ba.test(g))return g;f=i&&(l.boxSizingReliable()||g===b.style[c]),g=parseFloat(g)||0}return g+Oa(b,c,e||(i?"border":"content"),f,h)+"px"}function Qa(a,b){for(var c,d,e,f=[],g=0,h=a.length;h>g;g++)d=a[g],d.style&&(f[g]=N.get(d,"olddisplay"),c=d.style.display,b?(f[g]||"none"!==c||(d.style.display=""),""===d.style.display&&V(d)&&(f[g]=N.access(d,"olddisplay",za(d.nodeName)))):(e=V(d),"none"===c&&e||N.set(d,"olddisplay",e?c:n.css(d,"display"))));for(g=0;h>g;g++)d=a[g],d.style&&(b&&"none"!==d.style.display&&""!==d.style.display||(d.style.display=b?f[g]||"":"none"));return a}n.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=Fa(a,"opacity");return""===c?"1":c}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":"cssFloat"},style:function(a,b,c,d){if(a&&3!==a.nodeType&&8!==a.nodeType&&a.style){var e,f,g,h=n.camelCase(b),i=a.style;return b=n.cssProps[h]||(n.cssProps[h]=Ma(h)||h),g=n.cssHooks[b]||n.cssHooks[h],void 0===c?g&&"get"in g&&void 0!==(e=g.get(a,!1,d))?e:i[b]:(f=typeof c,"string"===f&&(e=T.exec(c))&&e[1]&&(c=W(a,b,e),f="number"),null!=c&&c===c&&("number"===f&&(c+=e&&e[3]||(n.cssNumber[h]?"":"px")),l.clearCloneStyle||""!==c||0!==b.indexOf("background")||(i[b]="inherit"),g&&"set"in g&&void 0===(c=g.set(a,c,d))||(i[b]=c)),void 0)}},css:function(a,b,c,d){var e,f,g,h=n.camelCase(b);return b=n.cssProps[h]||(n.cssProps[h]=Ma(h)||h),g=n.cssHooks[b]||n.cssHooks[h],g&&"get"in g&&(e=g.get(a,!0,c)),void 0===e&&(e=Fa(a,b,d)),"normal"===e&&b in Ja&&(e=Ja[b]),""===c||c?(f=parseFloat(e),c===!0||isFinite(f)?f||0:e):e}}),n.each(["height","width"],function(a,b){n.cssHooks[b]={get:function(a,c,d){return c?Ha.test(n.css(a,"display"))&&0===a.offsetWidth?Da(a,Ia,function(){return Pa(a,b,d)}):Pa(a,b,d):void 0},set:function(a,c,d){var e,f=d&&Ca(a),g=d&&Oa(a,b,d,"border-box"===n.css(a,"boxSizing",!1,f),f);return g&&(e=T.exec(c))&&"px"!==(e[3]||"px")&&(a.style[b]=c,c=n.css(a,b)),Na(a,c,g)}}}),n.cssHooks.marginLeft=Ga(l.reliableMarginLeft,function(a,b){return b?(parseFloat(Fa(a,"marginLeft"))||a.getBoundingClientRect().left-Da(a,{marginLeft:0},function(){return a.getBoundingClientRect().left}))+"px":void 0}),n.cssHooks.marginRight=Ga(l.reliableMarginRight,function(a,b){return b?Da(a,{display:"inline-block"},Fa,[a,"marginRight"]):void 0}),n.each({margin:"",padding:"",border:"Width"},function(a,b){n.cssHooks[a+b]={expand:function(c){for(var d=0,e={},f="string"==typeof c?c.split(" "):[c];4>d;d++)e[a+U[d]+b]=f[d]||f[d-2]||f[0];return e}},Aa.test(a)||(n.cssHooks[a+b].set=Na)}),n.fn.extend({css:function(a,b){return K(this,function(a,b,c){var d,e,f={},g=0;if(n.isArray(b)){for(d=Ca(a),e=b.length;e>g;g++)f[b[g]]=n.css(a,b[g],!1,d);return f}return void 0!==c?n.style(a,b,c):n.css(a,b)},a,b,arguments.length>1)},show:function(){return Qa(this,!0)},hide:function(){return Qa(this)},toggle:function(a){return"boolean"==typeof a?a?this.show():this.hide():this.each(function(){V(this)?n(this).show():n(this).hide()})}});function Ra(a,b,c,d,e){return new Ra.prototype.init(a,b,c,d,e)}n.Tween=Ra,Ra.prototype={constructor:Ra,init:function(a,b,c,d,e,f){this.elem=a,this.prop=c,this.easing=e||n.easing._default,this.options=b,this.start=this.now=this.cur(),this.end=d,this.unit=f||(n.cssNumber[c]?"":"px")},cur:function(){var a=Ra.propHooks[this.prop];return a&&a.get?a.get(this):Ra.propHooks._default.get(this)},run:function(a){var b,c=Ra.propHooks[this.prop];return this.options.duration?this.pos=b=n.easing[this.easing](a,this.options.duration*a,0,1,this.options.duration):this.pos=b=a,this.now=(this.end-this.start)*b+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),c&&c.set?c.set(this):Ra.propHooks._default.set(this),this}},Ra.prototype.init.prototype=Ra.prototype,Ra.propHooks={_default:{get:function(a){var b;return 1!==a.elem.nodeType||null!=a.elem[a.prop]&&null==a.elem.style[a.prop]?a.elem[a.prop]:(b=n.css(a.elem,a.prop,""),b&&"auto"!==b?b:0)},set:function(a){n.fx.step[a.prop]?n.fx.step[a.prop](a):1!==a.elem.nodeType||null==a.elem.style[n.cssProps[a.prop]]&&!n.cssHooks[a.prop]?a.elem[a.prop]=a.now:n.style(a.elem,a.prop,a.now+a.unit)}}},Ra.propHooks.scrollTop=Ra.propHooks.scrollLeft={set:function(a){a.elem.nodeType&&a.elem.parentNode&&(a.elem[a.prop]=a.now)}},n.easing={linear:function(a){return a},swing:function(a){return.5-Math.cos(a*Math.PI)/2},_default:"swing"},n.fx=Ra.prototype.init,n.fx.step={};var Sa,Ta,Ua=/^(?:toggle|show|hide)$/,Va=/queueHooks$/;function Wa(){return a.setTimeout(function(){Sa=void 0}),Sa=n.now()}function Xa(a,b){var c,d=0,e={height:a};for(b=b?1:0;4>d;d+=2-b)c=U[d],e["margin"+c]=e["padding"+c]=a;return b&&(e.opacity=e.width=a),e}function Ya(a,b,c){for(var d,e=(_a.tweeners[b]||[]).concat(_a.tweeners["*"]),f=0,g=e.length;g>f;f++)if(d=e[f].call(c,b,a))return d}function Za(a,b,c){var d,e,f,g,h,i,j,k,l=this,m={},o=a.style,p=a.nodeType&&V(a),q=N.get(a,"fxshow");c.queue||(h=n._queueHooks(a,"fx"),null==h.unqueued&&(h.unqueued=0,i=h.empty.fire,h.empty.fire=function(){h.unqueued||i()}),h.unqueued++,l.always(function(){l.always(function(){h.unqueued--,n.queue(a,"fx").length||h.empty.fire()})})),1===a.nodeType&&("height"in b||"width"in b)&&(c.overflow=[o.overflow,o.overflowX,o.overflowY],j=n.css(a,"display"),k="none"===j?N.get(a,"olddisplay")||za(a.nodeName):j,"inline"===k&&"none"===n.css(a,"float")&&(o.display="inline-block")),c.overflow&&(o.overflow="hidden",l.always(function(){o.overflow=c.overflow[0],o.overflowX=c.overflow[1],o.overflowY=c.overflow[2]}));for(d in b)if(e=b[d],Ua.exec(e)){if(delete b[d],f=f||"toggle"===e,e===(p?"hide":"show")){if("show"!==e||!q||void 0===q[d])continue;p=!0}m[d]=q&&q[d]||n.style(a,d)}else j=void 0;if(n.isEmptyObject(m))"inline"===("none"===j?za(a.nodeName):j)&&(o.display=j);else{q?"hidden"in q&&(p=q.hidden):q=N.access(a,"fxshow",{}),f&&(q.hidden=!p),p?n(a).show():l.done(function(){n(a).hide()}),l.done(function(){var b;N.remove(a,"fxshow");for(b in m)n.style(a,b,m[b])});for(d in m)g=Ya(p?q[d]:0,d,l),d in q||(q[d]=g.start,p&&(g.end=g.start,g.start="width"===d||"height"===d?1:0))}}function $a(a,b){var c,d,e,f,g;for(c in a)if(d=n.camelCase(c),e=b[d],f=a[c],n.isArray(f)&&(e=f[1],f=a[c]=f[0]),c!==d&&(a[d]=f,delete a[c]),g=n.cssHooks[d],g&&"expand"in g){f=g.expand(f),delete a[d];for(c in f)c in a||(a[c]=f[c],b[c]=e)}else b[d]=e}function _a(a,b,c){var d,e,f=0,g=_a.prefilters.length,h=n.Deferred().always(function(){delete i.elem}),i=function(){if(e)return!1;for(var b=Sa||Wa(),c=Math.max(0,j.startTime+j.duration-b),d=c/j.duration||0,f=1-d,g=0,i=j.tweens.length;i>g;g++)j.tweens[g].run(f);return h.notifyWith(a,[j,f,c]),1>f&&i?c:(h.resolveWith(a,[j]),!1)},j=h.promise({elem:a,props:n.extend({},b),opts:n.extend(!0,{specialEasing:{},easing:n.easing._default},c),originalProperties:b,originalOptions:c,startTime:Sa||Wa(),duration:c.duration,tweens:[],createTween:function(b,c){var d=n.Tween(a,j.opts,b,c,j.opts.specialEasing[b]||j.opts.easing);return j.tweens.push(d),d},stop:function(b){var c=0,d=b?j.tweens.length:0;if(e)return this;for(e=!0;d>c;c++)j.tweens[c].run(1);return b?(h.notifyWith(a,[j,1,0]),h.resolveWith(a,[j,b])):h.rejectWith(a,[j,b]),this}}),k=j.props;for($a(k,j.opts.specialEasing);g>f;f++)if(d=_a.prefilters[f].call(j,a,k,j.opts))return n.isFunction(d.stop)&&(n._queueHooks(j.elem,j.opts.queue).stop=n.proxy(d.stop,d)),d;return n.map(k,Ya,j),n.isFunction(j.opts.start)&&j.opts.start.call(a,j),n.fx.timer(n.extend(i,{elem:a,anim:j,queue:j.opts.queue})),j.progress(j.opts.progress).done(j.opts.done,j.opts.complete).fail(j.opts.fail).always(j.opts.always)}n.Animation=n.extend(_a,{tweeners:{"*":[function(a,b){var c=this.createTween(a,b);return W(c.elem,a,T.exec(b),c),c}]},tweener:function(a,b){n.isFunction(a)?(b=a,a=["*"]):a=a.match(G);for(var c,d=0,e=a.length;e>d;d++)c=a[d],_a.tweeners[c]=_a.tweeners[c]||[],_a.tweeners[c].unshift(b)},prefilters:[Za],prefilter:function(a,b){b?_a.prefilters.unshift(a):_a.prefilters.push(a)}}),n.speed=function(a,b,c){var d=a&&"object"==typeof a?n.extend({},a):{complete:c||!c&&b||n.isFunction(a)&&a,duration:a,easing:c&&b||b&&!n.isFunction(b)&&b};return d.duration=n.fx.off?0:"number"==typeof d.duration?d.duration:d.duration in n.fx.speeds?n.fx.speeds[d.duration]:n.fx.speeds._default,null!=d.queue&&d.queue!==!0||(d.queue="fx"),d.old=d.complete,d.complete=function(){n.isFunction(d.old)&&d.old.call(this),d.queue&&n.dequeue(this,d.queue)},d},n.fn.extend({fadeTo:function(a,b,c,d){return this.filter(V).css("opacity",0).show().end().animate({opacity:b},a,c,d)},animate:function(a,b,c,d){var e=n.isEmptyObject(a),f=n.speed(b,c,d),g=function(){var b=_a(this,n.extend({},a),f);(e||N.get(this,"finish"))&&b.stop(!0)};return g.finish=g,e||f.queue===!1?this.each(g):this.queue(f.queue,g)},stop:function(a,b,c){var d=function(a){var b=a.stop;delete a.stop,b(c)};return"string"!=typeof a&&(c=b,b=a,a=void 0),b&&a!==!1&&this.queue(a||"fx",[]),this.each(function(){var b=!0,e=null!=a&&a+"queueHooks",f=n.timers,g=N.get(this);if(e)g[e]&&g[e].stop&&d(g[e]);else for(e in g)g[e]&&g[e].stop&&Va.test(e)&&d(g[e]);for(e=f.length;e--;)f[e].elem!==this||null!=a&&f[e].queue!==a||(f[e].anim.stop(c),b=!1,f.splice(e,1));!b&&c||n.dequeue(this,a)})},finish:function(a){return a!==!1&&(a=a||"fx"),this.each(function(){var b,c=N.get(this),d=c[a+"queue"],e=c[a+"queueHooks"],f=n.timers,g=d?d.length:0;for(c.finish=!0,n.queue(this,a,[]),e&&e.stop&&e.stop.call(this,!0),b=f.length;b--;)f[b].elem===this&&f[b].queue===a&&(f[b].anim.stop(!0),f.splice(b,1));for(b=0;g>b;b++)d[b]&&d[b].finish&&d[b].finish.call(this);delete c.finish})}}),n.each(["toggle","show","hide"],function(a,b){var c=n.fn[b];n.fn[b]=function(a,d,e){return null==a||"boolean"==typeof a?c.apply(this,arguments):this.animate(Xa(b,!0),a,d,e)}}),n.each({slideDown:Xa("show"),slideUp:Xa("hide"),slideToggle:Xa("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){n.fn[a]=function(a,c,d){return this.animate(b,a,c,d)}}),n.timers=[],n.fx.tick=function(){var a,b=0,c=n.timers;for(Sa=n.now();b<c.length;b++)a=c[b],a()||c[b]!==a||c.splice(b--,1);c.length||n.fx.stop(),Sa=void 0},n.fx.timer=function(a){n.timers.push(a),a()?n.fx.start():n.timers.pop()},n.fx.interval=13,n.fx.start=function(){Ta||(Ta=a.setInterval(n.fx.tick,n.fx.interval))},n.fx.stop=function(){a.clearInterval(Ta),Ta=null},n.fx.speeds={slow:600,fast:200,_default:400},n.fn.delay=function(b,c){return b=n.fx?n.fx.speeds[b]||b:b,c=c||"fx",this.queue(c,function(c,d){var e=a.setTimeout(c,b);d.stop=function(){a.clearTimeout(e)}})},function(){var a=d.createElement("input"),b=d.createElement("select"),c=b.appendChild(d.createElement("option"));a.type="checkbox",l.checkOn=""!==a.value,l.optSelected=c.selected,b.disabled=!0,l.optDisabled=!c.disabled,a=d.createElement("input"),a.value="t",a.type="radio",l.radioValue="t"===a.value}();var ab,bb=n.expr.attrHandle;n.fn.extend({attr:function(a,b){return K(this,n.attr,a,b,arguments.length>1)},removeAttr:function(a){return this.each(function(){n.removeAttr(this,a)})}}),n.extend({attr:function(a,b,c){var d,e,f=a.nodeType;if(3!==f&&8!==f&&2!==f)return"undefined"==typeof a.getAttribute?n.prop(a,b,c):(1===f&&n.isXMLDoc(a)||(b=b.toLowerCase(),e=n.attrHooks[b]||(n.expr.match.bool.test(b)?ab:void 0)),void 0!==c?null===c?void n.removeAttr(a,b):e&&"set"in e&&void 0!==(d=e.set(a,c,b))?d:(a.setAttribute(b,c+""),c):e&&"get"in e&&null!==(d=e.get(a,b))?d:(d=n.find.attr(a,b),null==d?void 0:d))},attrHooks:{type:{set:function(a,b){if(!l.radioValue&&"radio"===b&&n.nodeName(a,"input")){var c=a.value;return a.setAttribute("type",b),c&&(a.value=c),b}}}},removeAttr:function(a,b){var c,d,e=0,f=b&&b.match(G);if(f&&1===a.nodeType)while(c=f[e++])d=n.propFix[c]||c,n.expr.match.bool.test(c)&&(a[d]=!1),a.removeAttribute(c)}}),ab={set:function(a,b,c){return b===!1?n.removeAttr(a,c):a.setAttribute(c,c),c}},n.each(n.expr.match.bool.source.match(/\w+/g),function(a,b){var c=bb[b]||n.find.attr;bb[b]=function(a,b,d){var e,f;return d||(f=bb[b],bb[b]=e,e=null!=c(a,b,d)?b.toLowerCase():null,bb[b]=f),e}});var cb=/^(?:input|select|textarea|button)$/i,db=/^(?:a|area)$/i;n.fn.extend({prop:function(a,b){return K(this,n.prop,a,b,arguments.length>1)},removeProp:function(a){return this.each(function(){delete this[n.propFix[a]||a]})}}),n.extend({prop:function(a,b,c){var d,e,f=a.nodeType;if(3!==f&&8!==f&&2!==f)return 1===f&&n.isXMLDoc(a)||(b=n.propFix[b]||b, e=n.propHooks[b]),void 0!==c?e&&"set"in e&&void 0!==(d=e.set(a,c,b))?d:a[b]=c:e&&"get"in e&&null!==(d=e.get(a,b))?d:a[b]},propHooks:{tabIndex:{get:function(a){var b=n.find.attr(a,"tabindex");return b?parseInt(b,10):cb.test(a.nodeName)||db.test(a.nodeName)&&a.href?0:-1}}},propFix:{"for":"htmlFor","class":"className"}}),l.optSelected||(n.propHooks.selected={get:function(a){var b=a.parentNode;return b&&b.parentNode&&b.parentNode.selectedIndex,null},set:function(a){var b=a.parentNode;b&&(b.selectedIndex,b.parentNode&&b.parentNode.selectedIndex)}}),n.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){n.propFix[this.toLowerCase()]=this});var eb=/[\t\r\n\f]/g;function fb(a){return a.getAttribute&&a.getAttribute("class")||""}n.fn.extend({addClass:function(a){var b,c,d,e,f,g,h,i=0;if(n.isFunction(a))return this.each(function(b){n(this).addClass(a.call(this,b,fb(this)))});if("string"==typeof a&&a){b=a.match(G)||[];while(c=this[i++])if(e=fb(c),d=1===c.nodeType&&(" "+e+" ").replace(eb," ")){g=0;while(f=b[g++])d.indexOf(" "+f+" ")<0&&(d+=f+" ");h=n.trim(d),e!==h&&c.setAttribute("class",h)}}return this},removeClass:function(a){var b,c,d,e,f,g,h,i=0;if(n.isFunction(a))return this.each(function(b){n(this).removeClass(a.call(this,b,fb(this)))});if(!arguments.length)return this.attr("class","");if("string"==typeof a&&a){b=a.match(G)||[];while(c=this[i++])if(e=fb(c),d=1===c.nodeType&&(" "+e+" ").replace(eb," ")){g=0;while(f=b[g++])while(d.indexOf(" "+f+" ")>-1)d=d.replace(" "+f+" "," ");h=n.trim(d),e!==h&&c.setAttribute("class",h)}}return this},toggleClass:function(a,b){var c=typeof a;return"boolean"==typeof b&&"string"===c?b?this.addClass(a):this.removeClass(a):n.isFunction(a)?this.each(function(c){n(this).toggleClass(a.call(this,c,fb(this),b),b)}):this.each(function(){var b,d,e,f;if("string"===c){d=0,e=n(this),f=a.match(G)||[];while(b=f[d++])e.hasClass(b)?e.removeClass(b):e.addClass(b)}else void 0!==a&&"boolean"!==c||(b=fb(this),b&&N.set(this,"__className__",b),this.setAttribute&&this.setAttribute("class",b||a===!1?"":N.get(this,"__className__")||""))})},hasClass:function(a){var b,c,d=0;b=" "+a+" ";while(c=this[d++])if(1===c.nodeType&&(" "+fb(c)+" ").replace(eb," ").indexOf(b)>-1)return!0;return!1}});var gb=/\r/g,hb=/[\x20\t\r\n\f]+/g;n.fn.extend({val:function(a){var b,c,d,e=this[0];{if(arguments.length)return d=n.isFunction(a),this.each(function(c){var e;1===this.nodeType&&(e=d?a.call(this,c,n(this).val()):a,null==e?e="":"number"==typeof e?e+="":n.isArray(e)&&(e=n.map(e,function(a){return null==a?"":a+""})),b=n.valHooks[this.type]||n.valHooks[this.nodeName.toLowerCase()],b&&"set"in b&&void 0!==b.set(this,e,"value")||(this.value=e))});if(e)return b=n.valHooks[e.type]||n.valHooks[e.nodeName.toLowerCase()],b&&"get"in b&&void 0!==(c=b.get(e,"value"))?c:(c=e.value,"string"==typeof c?c.replace(gb,""):null==c?"":c)}}}),n.extend({valHooks:{option:{get:function(a){var b=n.find.attr(a,"value");return null!=b?b:n.trim(n.text(a)).replace(hb," ")}},select:{get:function(a){for(var b,c,d=a.options,e=a.selectedIndex,f="select-one"===a.type||0>e,g=f?null:[],h=f?e+1:d.length,i=0>e?h:f?e:0;h>i;i++)if(c=d[i],(c.selected||i===e)&&(l.optDisabled?!c.disabled:null===c.getAttribute("disabled"))&&(!c.parentNode.disabled||!n.nodeName(c.parentNode,"optgroup"))){if(b=n(c).val(),f)return b;g.push(b)}return g},set:function(a,b){var c,d,e=a.options,f=n.makeArray(b),g=e.length;while(g--)d=e[g],(d.selected=n.inArray(n.valHooks.option.get(d),f)>-1)&&(c=!0);return c||(a.selectedIndex=-1),f}}}}),n.each(["radio","checkbox"],function(){n.valHooks[this]={set:function(a,b){return n.isArray(b)?a.checked=n.inArray(n(a).val(),b)>-1:void 0}},l.checkOn||(n.valHooks[this].get=function(a){return null===a.getAttribute("value")?"on":a.value})});var ib=/^(?:focusinfocus|focusoutblur)$/;n.extend(n.event,{trigger:function(b,c,e,f){var g,h,i,j,l,m,o,p=[e||d],q=k.call(b,"type")?b.type:b,r=k.call(b,"namespace")?b.namespace.split("."):[];if(h=i=e=e||d,3!==e.nodeType&&8!==e.nodeType&&!ib.test(q+n.event.triggered)&&(q.indexOf(".")>-1&&(r=q.split("."),q=r.shift(),r.sort()),l=q.indexOf(":")<0&&"on"+q,b=b[n.expando]?b:new n.Event(q,"object"==typeof b&&b),b.isTrigger=f?2:3,b.namespace=r.join("."),b.rnamespace=b.namespace?new RegExp("(^|\\.)"+r.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,b.result=void 0,b.target||(b.target=e),c=null==c?[b]:n.makeArray(c,[b]),o=n.event.special[q]||{},f||!o.trigger||o.trigger.apply(e,c)!==!1)){if(!f&&!o.noBubble&&!n.isWindow(e)){for(j=o.delegateType||q,ib.test(j+q)||(h=h.parentNode);h;h=h.parentNode)p.push(h),i=h;i===(e.ownerDocument||d)&&p.push(i.defaultView||i.parentWindow||a)}g=0;while((h=p[g++])&&!b.isPropagationStopped())b.type=g>1?j:o.bindType||q,m=(N.get(h,"events")||{})[b.type]&&N.get(h,"handle"),m&&m.apply(h,c),m=l&&h[l],m&&m.apply&&L(h)&&(b.result=m.apply(h,c),b.result===!1&&b.preventDefault());return b.type=q,f||b.isDefaultPrevented()||o._default&&o._default.apply(p.pop(),c)!==!1||!L(e)||l&&n.isFunction(e[q])&&!n.isWindow(e)&&(i=e[l],i&&(e[l]=null),n.event.triggered=q,e[q](),n.event.triggered=void 0,i&&(e[l]=i)),b.result}},simulate:function(a,b,c){var d=n.extend(new n.Event,c,{type:a,isSimulated:!0});n.event.trigger(d,null,b),d.isDefaultPrevented()&&c.preventDefault()}}),n.fn.extend({trigger:function(a,b){return this.each(function(){n.event.trigger(a,b,this)})},triggerHandler:function(a,b){var c=this[0];return c?n.event.trigger(a,b,c,!0):void 0}}),n.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(a,b){n.fn[b]=function(a,c){return arguments.length>0?this.on(b,null,a,c):this.trigger(b)}}),n.fn.extend({hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)}}),l.focusin="onfocusin"in a,l.focusin||n.each({focus:"focusin",blur:"focusout"},function(a,b){var c=function(a){n.event.simulate(b,a.target,n.event.fix(a))};n.event.special[b]={setup:function(){var d=this.ownerDocument||this,e=N.access(d,b);e||d.addEventListener(a,c,!0),N.access(d,b,(e||0)+1)},teardown:function(){var d=this.ownerDocument||this,e=N.access(d,b)-1;e?N.access(d,b,e):(d.removeEventListener(a,c,!0),N.remove(d,b))}}});var jb=a.location,kb=n.now(),lb=/\?/;n.parseJSON=function(a){return JSON.parse(a+"")},n.parseXML=function(b){var c;if(!b||"string"!=typeof b)return null;try{c=(new a.DOMParser).parseFromString(b,"text/xml")}catch(d){c=void 0}return c&&!c.getElementsByTagName("parsererror").length||n.error("Invalid XML: "+b),c};var mb=/#.*$/,nb=/([?&])_=[^&]*/,ob=/^(.*?):[ \t]*([^\r\n]*)$/gm,pb=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,qb=/^(?:GET|HEAD)$/,rb=/^\/\//,sb={},tb={},ub="*/".concat("*"),vb=d.createElement("a");vb.href=jb.href;function wb(a){return function(b,c){"string"!=typeof b&&(c=b,b="*");var d,e=0,f=b.toLowerCase().match(G)||[];if(n.isFunction(c))while(d=f[e++])"+"===d[0]?(d=d.slice(1)||"*",(a[d]=a[d]||[]).unshift(c)):(a[d]=a[d]||[]).push(c)}}function xb(a,b,c,d){var e={},f=a===tb;function g(h){var i;return e[h]=!0,n.each(a[h]||[],function(a,h){var j=h(b,c,d);return"string"!=typeof j||f||e[j]?f?!(i=j):void 0:(b.dataTypes.unshift(j),g(j),!1)}),i}return g(b.dataTypes[0])||!e["*"]&&g("*")}function yb(a,b){var c,d,e=n.ajaxSettings.flatOptions||{};for(c in b)void 0!==b[c]&&((e[c]?a:d||(d={}))[c]=b[c]);return d&&n.extend(!0,a,d),a}function zb(a,b,c){var d,e,f,g,h=a.contents,i=a.dataTypes;while("*"===i[0])i.shift(),void 0===d&&(d=a.mimeType||b.getResponseHeader("Content-Type"));if(d)for(e in h)if(h[e]&&h[e].test(d)){i.unshift(e);break}if(i[0]in c)f=i[0];else{for(e in c){if(!i[0]||a.converters[e+" "+i[0]]){f=e;break}g||(g=e)}f=f||g}return f?(f!==i[0]&&i.unshift(f),c[f]):void 0}function Ab(a,b,c,d){var e,f,g,h,i,j={},k=a.dataTypes.slice();if(k[1])for(g in a.converters)j[g.toLowerCase()]=a.converters[g];f=k.shift();while(f)if(a.responseFields[f]&&(c[a.responseFields[f]]=b),!i&&d&&a.dataFilter&&(b=a.dataFilter(b,a.dataType)),i=f,f=k.shift())if("*"===f)f=i;else if("*"!==i&&i!==f){if(g=j[i+" "+f]||j["* "+f],!g)for(e in j)if(h=e.split(" "),h[1]===f&&(g=j[i+" "+h[0]]||j["* "+h[0]])){g===!0?g=j[e]:j[e]!==!0&&(f=h[0],k.unshift(h[1]));break}if(g!==!0)if(g&&a["throws"])b=g(b);else try{b=g(b)}catch(l){return{state:"parsererror",error:g?l:"No conversion from "+i+" to "+f}}}return{state:"success",data:b}}n.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:jb.href,type:"GET",isLocal:pb.test(jb.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":ub,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":n.parseJSON,"text xml":n.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(a,b){return b?yb(yb(a,n.ajaxSettings),b):yb(n.ajaxSettings,a)},ajaxPrefilter:wb(sb),ajaxTransport:wb(tb),ajax:function(b,c){"object"==typeof b&&(c=b,b=void 0),c=c||{};var e,f,g,h,i,j,k,l,m=n.ajaxSetup({},c),o=m.context||m,p=m.context&&(o.nodeType||o.jquery)?n(o):n.event,q=n.Deferred(),r=n.Callbacks("once memory"),s=m.statusCode||{},t={},u={},v=0,w="canceled",x={readyState:0,getResponseHeader:function(a){var b;if(2===v){if(!h){h={};while(b=ob.exec(g))h[b[1].toLowerCase()]=b[2]}b=h[a.toLowerCase()]}return null==b?null:b},getAllResponseHeaders:function(){return 2===v?g:null},setRequestHeader:function(a,b){var c=a.toLowerCase();return v||(a=u[c]=u[c]||a,t[a]=b),this},overrideMimeType:function(a){return v||(m.mimeType=a),this},statusCode:function(a){var b;if(a)if(2>v)for(b in a)s[b]=[s[b],a[b]];else x.always(a[x.status]);return this},abort:function(a){var b=a||w;return e&&e.abort(b),z(0,b),this}};if(q.promise(x).complete=r.add,x.success=x.done,x.error=x.fail,m.url=((b||m.url||jb.href)+"").replace(mb,"").replace(rb,jb.protocol+"//"),m.type=c.method||c.type||m.method||m.type,m.dataTypes=n.trim(m.dataType||"*").toLowerCase().match(G)||[""],null==m.crossDomain){j=d.createElement("a");try{j.href=m.url,j.href=j.href,m.crossDomain=vb.protocol+"//"+vb.host!=j.protocol+"//"+j.host}catch(y){m.crossDomain=!0}}if(m.data&&m.processData&&"string"!=typeof m.data&&(m.data=n.param(m.data,m.traditional)),xb(sb,m,c,x),2===v)return x;k=n.event&&m.global,k&&0===n.active++&&n.event.trigger("ajaxStart"),m.type=m.type.toUpperCase(),m.hasContent=!qb.test(m.type),f=m.url,m.hasContent||(m.data&&(f=m.url+=(lb.test(f)?"&":"?")+m.data,delete m.data),m.cache===!1&&(m.url=nb.test(f)?f.replace(nb,"$1_="+kb++):f+(lb.test(f)?"&":"?")+"_="+kb++)),m.ifModified&&(n.lastModified[f]&&x.setRequestHeader("If-Modified-Since",n.lastModified[f]),n.etag[f]&&x.setRequestHeader("If-None-Match",n.etag[f])),(m.data&&m.hasContent&&m.contentType!==!1||c.contentType)&&x.setRequestHeader("Content-Type",m.contentType),x.setRequestHeader("Accept",m.dataTypes[0]&&m.accepts[m.dataTypes[0]]?m.accepts[m.dataTypes[0]]+("*"!==m.dataTypes[0]?", "+ub+"; q=0.01":""):m.accepts["*"]);for(l in m.headers)x.setRequestHeader(l,m.headers[l]);if(m.beforeSend&&(m.beforeSend.call(o,x,m)===!1||2===v))return x.abort();w="abort";for(l in{success:1,error:1,complete:1})x[l](m[l]);if(e=xb(tb,m,c,x)){if(x.readyState=1,k&&p.trigger("ajaxSend",[x,m]),2===v)return x;m.async&&m.timeout>0&&(i=a.setTimeout(function(){x.abort("timeout")},m.timeout));try{v=1,e.send(t,z)}catch(y){if(!(2>v))throw y;z(-1,y)}}else z(-1,"No Transport");function z(b,c,d,h){var j,l,t,u,w,y=c;2!==v&&(v=2,i&&a.clearTimeout(i),e=void 0,g=h||"",x.readyState=b>0?4:0,j=b>=200&&300>b||304===b,d&&(u=zb(m,x,d)),u=Ab(m,u,x,j),j?(m.ifModified&&(w=x.getResponseHeader("Last-Modified"),w&&(n.lastModified[f]=w),w=x.getResponseHeader("etag"),w&&(n.etag[f]=w)),204===b||"HEAD"===m.type?y="nocontent":304===b?y="notmodified":(y=u.state,l=u.data,t=u.error,j=!t)):(t=y,!b&&y||(y="error",0>b&&(b=0))),x.status=b,x.statusText=(c||y)+"",j?q.resolveWith(o,[l,y,x]):q.rejectWith(o,[x,y,t]),x.statusCode(s),s=void 0,k&&p.trigger(j?"ajaxSuccess":"ajaxError",[x,m,j?l:t]),r.fireWith(o,[x,y]),k&&(p.trigger("ajaxComplete",[x,m]),--n.active||n.event.trigger("ajaxStop")))}return x},getJSON:function(a,b,c){return n.get(a,b,c,"json")},getScript:function(a,b){return n.get(a,void 0,b,"script")}}),n.each(["get","post"],function(a,b){n[b]=function(a,c,d,e){return n.isFunction(c)&&(e=e||d,d=c,c=void 0),n.ajax(n.extend({url:a,type:b,dataType:e,data:c,success:d},n.isPlainObject(a)&&a))}}),n._evalUrl=function(a){return n.ajax({url:a,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0})},n.fn.extend({wrapAll:function(a){var b;return n.isFunction(a)?this.each(function(b){n(this).wrapAll(a.call(this,b))}):(this[0]&&(b=n(a,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){var a=this;while(a.firstElementChild)a=a.firstElementChild;return a}).append(this)),this)},wrapInner:function(a){return n.isFunction(a)?this.each(function(b){n(this).wrapInner(a.call(this,b))}):this.each(function(){var b=n(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){var b=n.isFunction(a);return this.each(function(c){n(this).wrapAll(b?a.call(this,c):a)})},unwrap:function(){return this.parent().each(function(){n.nodeName(this,"body")||n(this).replaceWith(this.childNodes)}).end()}}),n.expr.filters.hidden=function(a){return!n.expr.filters.visible(a)},n.expr.filters.visible=function(a){return a.offsetWidth>0||a.offsetHeight>0||a.getClientRects().length>0};var Bb=/%20/g,Cb=/\[\]$/,Db=/\r?\n/g,Eb=/^(?:submit|button|image|reset|file)$/i,Fb=/^(?:input|select|textarea|keygen)/i;function Gb(a,b,c,d){var e;if(n.isArray(b))n.each(b,function(b,e){c||Cb.test(a)?d(a,e):Gb(a+"["+("object"==typeof e&&null!=e?b:"")+"]",e,c,d)});else if(c||"object"!==n.type(b))d(a,b);else for(e in b)Gb(a+"["+e+"]",b[e],c,d)}n.param=function(a,b){var c,d=[],e=function(a,b){b=n.isFunction(b)?b():null==b?"":b,d[d.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};if(void 0===b&&(b=n.ajaxSettings&&n.ajaxSettings.traditional),n.isArray(a)||a.jquery&&!n.isPlainObject(a))n.each(a,function(){e(this.name,this.value)});else for(c in a)Gb(c,a[c],b,e);return d.join("&").replace(Bb,"+")},n.fn.extend({serialize:function(){return n.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var a=n.prop(this,"elements");return a?n.makeArray(a):this}).filter(function(){var a=this.type;return this.name&&!n(this).is(":disabled")&&Fb.test(this.nodeName)&&!Eb.test(a)&&(this.checked||!X.test(a))}).map(function(a,b){var c=n(this).val();return null==c?null:n.isArray(c)?n.map(c,function(a){return{name:b.name,value:a.replace(Db,"\r\n")}}):{name:b.name,value:c.replace(Db,"\r\n")}}).get()}}),n.ajaxSettings.xhr=function(){try{return new a.XMLHttpRequest}catch(b){}};var Hb={0:200,1223:204},Ib=n.ajaxSettings.xhr();l.cors=!!Ib&&"withCredentials"in Ib,l.ajax=Ib=!!Ib,n.ajaxTransport(function(b){var c,d;return l.cors||Ib&&!b.crossDomain?{send:function(e,f){var g,h=b.xhr();if(h.open(b.type,b.url,b.async,b.username,b.password),b.xhrFields)for(g in b.xhrFields)h[g]=b.xhrFields[g];b.mimeType&&h.overrideMimeType&&h.overrideMimeType(b.mimeType),b.crossDomain||e["X-Requested-With"]||(e["X-Requested-With"]="XMLHttpRequest");for(g in e)h.setRequestHeader(g,e[g]);c=function(a){return function(){c&&(c=d=h.onload=h.onerror=h.onabort=h.onreadystatechange=null,"abort"===a?h.abort():"error"===a?"number"!=typeof h.status?f(0,"error"):f(h.status,h.statusText):f(Hb[h.status]||h.status,h.statusText,"text"!==(h.responseType||"text")||"string"!=typeof h.responseText?{binary:h.response}:{text:h.responseText},h.getAllResponseHeaders()))}},h.onload=c(),d=h.onerror=c("error"),void 0!==h.onabort?h.onabort=d:h.onreadystatechange=function(){4===h.readyState&&a.setTimeout(function(){c&&d()})},c=c("abort");try{h.send(b.hasContent&&b.data||null)}catch(i){if(c)throw i}},abort:function(){c&&c()}}:void 0}),n.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(a){return n.globalEval(a),a}}}),n.ajaxPrefilter("script",function(a){void 0===a.cache&&(a.cache=!1),a.crossDomain&&(a.type="GET")}),n.ajaxTransport("script",function(a){if(a.crossDomain){var b,c;return{send:function(e,f){b=n("<script>").prop({charset:a.scriptCharset,src:a.url}).on("load error",c=function(a){b.remove(),c=null,a&&f("error"===a.type?404:200,a.type)}),d.head.appendChild(b[0])},abort:function(){c&&c()}}}});var Jb=[],Kb=/(=)\?(?=&|$)|\?\?/;n.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var a=Jb.pop()||n.expando+"_"+kb++;return this[a]=!0,a}}),n.ajaxPrefilter("json jsonp",function(b,c,d){var e,f,g,h=b.jsonp!==!1&&(Kb.test(b.url)?"url":"string"==typeof b.data&&0===(b.contentType||"").indexOf("application/x-www-form-urlencoded")&&Kb.test(b.data)&&"data");return h||"jsonp"===b.dataTypes[0]?(e=b.jsonpCallback=n.isFunction(b.jsonpCallback)?b.jsonpCallback():b.jsonpCallback,h?b[h]=b[h].replace(Kb,"$1"+e):b.jsonp!==!1&&(b.url+=(lb.test(b.url)?"&":"?")+b.jsonp+"="+e),b.converters["script json"]=function(){return g||n.error(e+" was not called"),g[0]},b.dataTypes[0]="json",f=a[e],a[e]=function(){g=arguments},d.always(function(){void 0===f?n(a).removeProp(e):a[e]=f,b[e]&&(b.jsonpCallback=c.jsonpCallback,Jb.push(e)),g&&n.isFunction(f)&&f(g[0]),g=f=void 0}),"script"):void 0}),n.parseHTML=function(a,b,c){if(!a||"string"!=typeof a)return null;"boolean"==typeof b&&(c=b,b=!1),b=b||d;var e=x.exec(a),f=!c&&[];return e?[b.createElement(e[1])]:(e=ca([a],b,f),f&&f.length&&n(f).remove(),n.merge([],e.childNodes))};var Lb=n.fn.load;n.fn.load=function(a,b,c){if("string"!=typeof a&&Lb)return Lb.apply(this,arguments);var d,e,f,g=this,h=a.indexOf(" ");return h>-1&&(d=n.trim(a.slice(h)),a=a.slice(0,h)),n.isFunction(b)?(c=b,b=void 0):b&&"object"==typeof b&&(e="POST"),g.length>0&&n.ajax({url:a,type:e||"GET",dataType:"html",data:b}).done(function(a){f=arguments,g.html(d?n("<div>").append(n.parseHTML(a)).find(d):a)}).always(c&&function(a,b){g.each(function(){c.apply(this,f||[a.responseText,b,a])})}),this},n.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(a,b){n.fn[b]=function(a){return this.on(b,a)}}),n.expr.filters.animated=function(a){return n.grep(n.timers,function(b){return a===b.elem}).length};function Mb(a){return n.isWindow(a)?a:9===a.nodeType&&a.defaultView}n.offset={setOffset:function(a,b,c){var d,e,f,g,h,i,j,k=n.css(a,"position"),l=n(a),m={};"static"===k&&(a.style.position="relative"),h=l.offset(),f=n.css(a,"top"),i=n.css(a,"left"),j=("absolute"===k||"fixed"===k)&&(f+i).indexOf("auto")>-1,j?(d=l.position(),g=d.top,e=d.left):(g=parseFloat(f)||0,e=parseFloat(i)||0),n.isFunction(b)&&(b=b.call(a,c,n.extend({},h))),null!=b.top&&(m.top=b.top-h.top+g),null!=b.left&&(m.left=b.left-h.left+e),"using"in b?b.using.call(a,m):l.css(m)}},n.fn.extend({offset:function(a){if(arguments.length)return void 0===a?this:this.each(function(b){n.offset.setOffset(this,a,b)});var b,c,d=this[0],e={top:0,left:0},f=d&&d.ownerDocument;if(f)return b=f.documentElement,n.contains(b,d)?(e=d.getBoundingClientRect(),c=Mb(f),{top:e.top+c.pageYOffset-b.clientTop,left:e.left+c.pageXOffset-b.clientLeft}):e},position:function(){if(this[0]){var a,b,c=this[0],d={top:0,left:0};return"fixed"===n.css(c,"position")?b=c.getBoundingClientRect():(a=this.offsetParent(),b=this.offset(),n.nodeName(a[0],"html")||(d=a.offset()),d.top+=n.css(a[0],"borderTopWidth",!0),d.left+=n.css(a[0],"borderLeftWidth",!0)),{top:b.top-d.top-n.css(c,"marginTop",!0),left:b.left-d.left-n.css(c,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var a=this.offsetParent;while(a&&"static"===n.css(a,"position"))a=a.offsetParent;return a||Ea})}}),n.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(a,b){var c="pageYOffset"===b;n.fn[a]=function(d){return K(this,function(a,d,e){var f=Mb(a);return void 0===e?f?f[b]:a[d]:void(f?f.scrollTo(c?f.pageXOffset:e,c?e:f.pageYOffset):a[d]=e)},a,d,arguments.length)}}),n.each(["top","left"],function(a,b){n.cssHooks[b]=Ga(l.pixelPosition,function(a,c){return c?(c=Fa(a,b),Ba.test(c)?n(a).position()[b]+"px":c):void 0})}),n.each({Height:"height",Width:"width"},function(a,b){n.each({padding:"inner"+a,content:b,"":"outer"+a},function(c,d){n.fn[d]=function(d,e){var f=arguments.length&&(c||"boolean"!=typeof d),g=c||(d===!0||e===!0?"margin":"border");return K(this,function(b,c,d){var e;return n.isWindow(b)?b.document.documentElement["client"+a]:9===b.nodeType?(e=b.documentElement,Math.max(b.body["scroll"+a],e["scroll"+a],b.body["offset"+a],e["offset"+a],e["client"+a])):void 0===d?n.css(b,c,g):n.style(b,c,d,g)},b,f?d:void 0,f,null)}})}),n.fn.extend({bind:function(a,b,c){return this.on(a,null,b,c)},unbind:function(a,b){return this.off(a,null,b)},delegate:function(a,b,c,d){return this.on(b,a,c,d)},undelegate:function(a,b,c){return 1===arguments.length?this.off(a,"**"):this.off(b,a||"**",c)},size:function(){return this.length}}),n.fn.andSelf=n.fn.addBack,"function"==typeof define&&define.amd&&define("jquery",[],function(){return n});var Nb=a.jQuery,Ob=a.$;return n.noConflict=function(b){return a.$===n&&(a.$=Ob),b&&a.jQuery===n&&(a.jQuery=Nb),n},b||(a.jQuery=a.$=n),n}); ; // Underscore.js 1.8.3 // http://underscorejs.org // (c) 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors // Underscore may be freely distributed under the MIT license. (function(){function n(n){function t(t,r,e,u,i,o){for(;i>=0&&o>i;i+=n){var a=u?u[i]:i;e=r(e,t[a],a,t)}return e}return function(r,e,u,i){e=b(e,i,4);var o=!k(r)&&m.keys(r),a=(o||r).length,c=n>0?0:a-1;return arguments.length<3&&(u=r[o?o[c]:c],c+=n),t(r,e,u,o,c,a)}}function t(n){return function(t,r,e){r=x(r,e);for(var u=O(t),i=n>0?0:u-1;i>=0&&u>i;i+=n)if(r(t[i],i,t))return i;return-1}}function r(n,t,r){return function(e,u,i){var o=0,a=O(e);if("number"==typeof i)n>0?o=i>=0?i:Math.max(i+a,o):a=i>=0?Math.min(i+1,a):i+a+1;else if(r&&i&&a)return i=r(e,u),e[i]===u?i:-1;if(u!==u)return i=t(l.call(e,o,a),m.isNaN),i>=0?i+o:-1;for(i=n>0?o:a-1;i>=0&&a>i;i+=n)if(e[i]===u)return i;return-1}}function e(n,t){var r=I.length,e=n.constructor,u=m.isFunction(e)&&e.prototype||a,i="constructor";for(m.has(n,i)&&!m.contains(t,i)&&t.push(i);r--;)i=I[r],i in n&&n[i]!==u[i]&&!m.contains(t,i)&&t.push(i)}var u=this,i=u._,o=Array.prototype,a=Object.prototype,c=Function.prototype,f=o.push,l=o.slice,s=a.toString,p=a.hasOwnProperty,h=Array.isArray,v=Object.keys,g=c.bind,y=Object.create,d=function(){},m=function(n){return n instanceof m?n:this instanceof m?void(this._wrapped=n):new m(n)};"undefined"!=typeof exports?("undefined"!=typeof module&&module.exports&&(exports=module.exports=m),exports._=m):u._=m,m.VERSION="1.8.3";var b=function(n,t,r){if(t===void 0)return n;switch(null==r?3:r){case 1:return function(r){return n.call(t,r)};case 2:return function(r,e){return n.call(t,r,e)};case 3:return function(r,e,u){return n.call(t,r,e,u)};case 4:return function(r,e,u,i){return n.call(t,r,e,u,i)}}return function(){return n.apply(t,arguments)}},x=function(n,t,r){return null==n?m.identity:m.isFunction(n)?b(n,t,r):m.isObject(n)?m.matcher(n):m.property(n)};m.iteratee=function(n,t){return x(n,t,1/0)};var _=function(n,t){return function(r){var e=arguments.length;if(2>e||null==r)return r;for(var u=1;e>u;u++)for(var i=arguments[u],o=n(i),a=o.length,c=0;a>c;c++){var f=o[c];t&&r[f]!==void 0||(r[f]=i[f])}return r}},j=function(n){if(!m.isObject(n))return{};if(y)return y(n);d.prototype=n;var t=new d;return d.prototype=null,t},w=function(n){return function(t){return null==t?void 0:t[n]}},A=Math.pow(2,53)-1,O=w("length"),k=function(n){var t=O(n);return"number"==typeof t&&t>=0&&A>=t};m.each=m.forEach=function(n,t,r){t=b(t,r);var e,u;if(k(n))for(e=0,u=n.length;u>e;e++)t(n[e],e,n);else{var i=m.keys(n);for(e=0,u=i.length;u>e;e++)t(n[i[e]],i[e],n)}return n},m.map=m.collect=function(n,t,r){t=x(t,r);for(var e=!k(n)&&m.keys(n),u=(e||n).length,i=Array(u),o=0;u>o;o++){var a=e?e[o]:o;i[o]=t(n[a],a,n)}return i},m.reduce=m.foldl=m.inject=n(1),m.reduceRight=m.foldr=n(-1),m.find=m.detect=function(n,t,r){var e;return e=k(n)?m.findIndex(n,t,r):m.findKey(n,t,r),e!==void 0&&e!==-1?n[e]:void 0},m.filter=m.select=function(n,t,r){var e=[];return t=x(t,r),m.each(n,function(n,r,u){t(n,r,u)&&e.push(n)}),e},m.reject=function(n,t,r){return m.filter(n,m.negate(x(t)),r)},m.every=m.all=function(n,t,r){t=x(t,r);for(var e=!k(n)&&m.keys(n),u=(e||n).length,i=0;u>i;i++){var o=e?e[i]:i;if(!t(n[o],o,n))return!1}return!0},m.some=m.any=function(n,t,r){t=x(t,r);for(var e=!k(n)&&m.keys(n),u=(e||n).length,i=0;u>i;i++){var o=e?e[i]:i;if(t(n[o],o,n))return!0}return!1},m.contains=m.includes=m.include=function(n,t,r,e){return k(n)||(n=m.values(n)),("number"!=typeof r||e)&&(r=0),m.indexOf(n,t,r)>=0},m.invoke=function(n,t){var r=l.call(arguments,2),e=m.isFunction(t);return m.map(n,function(n){var u=e?t:n[t];return null==u?u:u.apply(n,r)})},m.pluck=function(n,t){return m.map(n,m.property(t))},m.where=function(n,t){return m.filter(n,m.matcher(t))},m.findWhere=function(n,t){return m.find(n,m.matcher(t))},m.max=function(n,t,r){var e,u,i=-1/0,o=-1/0;if(null==t&&null!=n){n=k(n)?n:m.values(n);for(var a=0,c=n.length;c>a;a++)e=n[a],e>i&&(i=e)}else t=x(t,r),m.each(n,function(n,r,e){u=t(n,r,e),(u>o||u===-1/0&&i===-1/0)&&(i=n,o=u)});return i},m.min=function(n,t,r){var e,u,i=1/0,o=1/0;if(null==t&&null!=n){n=k(n)?n:m.values(n);for(var a=0,c=n.length;c>a;a++)e=n[a],i>e&&(i=e)}else t=x(t,r),m.each(n,function(n,r,e){u=t(n,r,e),(o>u||1/0===u&&1/0===i)&&(i=n,o=u)});return i},m.shuffle=function(n){for(var t,r=k(n)?n:m.values(n),e=r.length,u=Array(e),i=0;e>i;i++)t=m.random(0,i),t!==i&&(u[i]=u[t]),u[t]=r[i];return u},m.sample=function(n,t,r){return null==t||r?(k(n)||(n=m.values(n)),n[m.random(n.length-1)]):m.shuffle(n).slice(0,Math.max(0,t))},m.sortBy=function(n,t,r){return t=x(t,r),m.pluck(m.map(n,function(n,r,e){return{value:n,index:r,criteria:t(n,r,e)}}).sort(function(n,t){var r=n.criteria,e=t.criteria;if(r!==e){if(r>e||r===void 0)return 1;if(e>r||e===void 0)return-1}return n.index-t.index}),"value")};var F=function(n){return function(t,r,e){var u={};return r=x(r,e),m.each(t,function(e,i){var o=r(e,i,t);n(u,e,o)}),u}};m.groupBy=F(function(n,t,r){m.has(n,r)?n[r].push(t):n[r]=[t]}),m.indexBy=F(function(n,t,r){n[r]=t}),m.countBy=F(function(n,t,r){m.has(n,r)?n[r]++:n[r]=1}),m.toArray=function(n){return n?m.isArray(n)?l.call(n):k(n)?m.map(n,m.identity):m.values(n):[]},m.size=function(n){return null==n?0:k(n)?n.length:m.keys(n).length},m.partition=function(n,t,r){t=x(t,r);var e=[],u=[];return m.each(n,function(n,r,i){(t(n,r,i)?e:u).push(n)}),[e,u]},m.first=m.head=m.take=function(n,t,r){return null==n?void 0:null==t||r?n[0]:m.initial(n,n.length-t)},m.initial=function(n,t,r){return l.call(n,0,Math.max(0,n.length-(null==t||r?1:t)))},m.last=function(n,t,r){return null==n?void 0:null==t||r?n[n.length-1]:m.rest(n,Math.max(0,n.length-t))},m.rest=m.tail=m.drop=function(n,t,r){return l.call(n,null==t||r?1:t)},m.compact=function(n){return m.filter(n,m.identity)};var S=function(n,t,r,e){for(var u=[],i=0,o=e||0,a=O(n);a>o;o++){var c=n[o];if(k(c)&&(m.isArray(c)||m.isArguments(c))){t||(c=S(c,t,r));var f=0,l=c.length;for(u.length+=l;l>f;)u[i++]=c[f++]}else r||(u[i++]=c)}return u};m.flatten=function(n,t){return S(n,t,!1)},m.without=function(n){return m.difference(n,l.call(arguments,1))},m.uniq=m.unique=function(n,t,r,e){m.isBoolean(t)||(e=r,r=t,t=!1),null!=r&&(r=x(r,e));for(var u=[],i=[],o=0,a=O(n);a>o;o++){var c=n[o],f=r?r(c,o,n):c;t?(o&&i===f||u.push(c),i=f):r?m.contains(i,f)||(i.push(f),u.push(c)):m.contains(u,c)||u.push(c)}return u},m.union=function(){return m.uniq(S(arguments,!0,!0))},m.intersection=function(n){for(var t=[],r=arguments.length,e=0,u=O(n);u>e;e++){var i=n[e];if(!m.contains(t,i)){for(var o=1;r>o&&m.contains(arguments[o],i);o++);o===r&&t.push(i)}}return t},m.difference=function(n){var t=S(arguments,!0,!0,1);return m.filter(n,function(n){return!m.contains(t,n)})},m.zip=function(){return m.unzip(arguments)},m.unzip=function(n){for(var t=n&&m.max(n,O).length||0,r=Array(t),e=0;t>e;e++)r[e]=m.pluck(n,e);return r},m.object=function(n,t){for(var r={},e=0,u=O(n);u>e;e++)t?r[n[e]]=t[e]:r[n[e][0]]=n[e][1];return r},m.findIndex=t(1),m.findLastIndex=t(-1),m.sortedIndex=function(n,t,r,e){r=x(r,e,1);for(var u=r(t),i=0,o=O(n);o>i;){var a=Math.floor((i+o)/2);r(n[a])<u?i=a+1:o=a}return i},m.indexOf=r(1,m.findIndex,m.sortedIndex),m.lastIndexOf=r(-1,m.findLastIndex),m.range=function(n,t,r){null==t&&(t=n||0,n=0),r=r||1;for(var e=Math.max(Math.ceil((t-n)/r),0),u=Array(e),i=0;e>i;i++,n+=r)u[i]=n;return u};var E=function(n,t,r,e,u){if(!(e instanceof t))return n.apply(r,u);var i=j(n.prototype),o=n.apply(i,u);return m.isObject(o)?o:i};m.bind=function(n,t){if(g&&n.bind===g)return g.apply(n,l.call(arguments,1));if(!m.isFunction(n))throw new TypeError("Bind must be called on a function");var r=l.call(arguments,2),e=function(){return E(n,e,t,this,r.concat(l.call(arguments)))};return e},m.partial=function(n){var t=l.call(arguments,1),r=function(){for(var e=0,u=t.length,i=Array(u),o=0;u>o;o++)i[o]=t[o]===m?arguments[e++]:t[o];for(;e<arguments.length;)i.push(arguments[e++]);return E(n,r,this,this,i)};return r},m.bindAll=function(n){var t,r,e=arguments.length;if(1>=e)throw new Error("bindAll must be passed function names");for(t=1;e>t;t++)r=arguments[t],n[r]=m.bind(n[r],n);return n},m.memoize=function(n,t){var r=function(e){var u=r.cache,i=""+(t?t.apply(this,arguments):e);return m.has(u,i)||(u[i]=n.apply(this,arguments)),u[i]};return r.cache={},r},m.delay=function(n,t){var r=l.call(arguments,2);return setTimeout(function(){return n.apply(null,r)},t)},m.defer=m.partial(m.delay,m,1),m.throttle=function(n,t,r){var e,u,i,o=null,a=0;r||(r={});var c=function(){a=r.leading===!1?0:m.now(),o=null,i=n.apply(e,u),o||(e=u=null)};return function(){var f=m.now();a||r.leading!==!1||(a=f);var l=t-(f-a);return e=this,u=arguments,0>=l||l>t?(o&&(clearTimeout(o),o=null),a=f,i=n.apply(e,u),o||(e=u=null)):o||r.trailing===!1||(o=setTimeout(c,l)),i}},m.debounce=function(n,t,r){var e,u,i,o,a,c=function(){var f=m.now()-o;t>f&&f>=0?e=setTimeout(c,t-f):(e=null,r||(a=n.apply(i,u),e||(i=u=null)))};return function(){i=this,u=arguments,o=m.now();var f=r&&!e;return e||(e=setTimeout(c,t)),f&&(a=n.apply(i,u),i=u=null),a}},m.wrap=function(n,t){return m.partial(t,n)},m.negate=function(n){return function(){return!n.apply(this,arguments)}},m.compose=function(){var n=arguments,t=n.length-1;return function(){for(var r=t,e=n[t].apply(this,arguments);r--;)e=n[r].call(this,e);return e}},m.after=function(n,t){return function(){return--n<1?t.apply(this,arguments):void 0}},m.before=function(n,t){var r;return function(){return--n>0&&(r=t.apply(this,arguments)),1>=n&&(t=null),r}},m.once=m.partial(m.before,2);var M=!{toString:null}.propertyIsEnumerable("toString"),I=["valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"];m.keys=function(n){if(!m.isObject(n))return[];if(v)return v(n);var t=[];for(var r in n)m.has(n,r)&&t.push(r);return M&&e(n,t),t},m.allKeys=function(n){if(!m.isObject(n))return[];var t=[];for(var r in n)t.push(r);return M&&e(n,t),t},m.values=function(n){for(var t=m.keys(n),r=t.length,e=Array(r),u=0;r>u;u++)e[u]=n[t[u]];return e},m.mapObject=function(n,t,r){t=x(t,r);for(var e,u=m.keys(n),i=u.length,o={},a=0;i>a;a++)e=u[a],o[e]=t(n[e],e,n);return o},m.pairs=function(n){for(var t=m.keys(n),r=t.length,e=Array(r),u=0;r>u;u++)e[u]=[t[u],n[t[u]]];return e},m.invert=function(n){for(var t={},r=m.keys(n),e=0,u=r.length;u>e;e++)t[n[r[e]]]=r[e];return t},m.functions=m.methods=function(n){var t=[];for(var r in n)m.isFunction(n[r])&&t.push(r);return t.sort()},m.extend=_(m.allKeys),m.extendOwn=m.assign=_(m.keys),m.findKey=function(n,t,r){t=x(t,r);for(var e,u=m.keys(n),i=0,o=u.length;o>i;i++)if(e=u[i],t(n[e],e,n))return e},m.pick=function(n,t,r){var e,u,i={},o=n;if(null==o)return i;m.isFunction(t)?(u=m.allKeys(o),e=b(t,r)):(u=S(arguments,!1,!1,1),e=function(n,t,r){return t in r},o=Object(o));for(var a=0,c=u.length;c>a;a++){var f=u[a],l=o[f];e(l,f,o)&&(i[f]=l)}return i},m.omit=function(n,t,r){if(m.isFunction(t))t=m.negate(t);else{var e=m.map(S(arguments,!1,!1,1),String);t=function(n,t){return!m.contains(e,t)}}return m.pick(n,t,r)},m.defaults=_(m.allKeys,!0),m.create=function(n,t){var r=j(n);return t&&m.extendOwn(r,t),r},m.clone=function(n){return m.isObject(n)?m.isArray(n)?n.slice():m.extend({},n):n},m.tap=function(n,t){return t(n),n},m.isMatch=function(n,t){var r=m.keys(t),e=r.length;if(null==n)return!e;for(var u=Object(n),i=0;e>i;i++){var o=r[i];if(t[o]!==u[o]||!(o in u))return!1}return!0};var N=function(n,t,r,e){if(n===t)return 0!==n||1/n===1/t;if(null==n||null==t)return n===t;n instanceof m&&(n=n._wrapped),t instanceof m&&(t=t._wrapped);var u=s.call(n);if(u!==s.call(t))return!1;switch(u){case"[object RegExp]":case"[object String]":return""+n==""+t;case"[object Number]":return+n!==+n?+t!==+t:0===+n?1/+n===1/t:+n===+t;case"[object Date]":case"[object Boolean]":return+n===+t}var i="[object Array]"===u;if(!i){if("object"!=typeof n||"object"!=typeof t)return!1;var o=n.constructor,a=t.constructor;if(o!==a&&!(m.isFunction(o)&&o instanceof o&&m.isFunction(a)&&a instanceof a)&&"constructor"in n&&"constructor"in t)return!1}r=r||[],e=e||[];for(var c=r.length;c--;)if(r[c]===n)return e[c]===t;if(r.push(n),e.push(t),i){if(c=n.length,c!==t.length)return!1;for(;c--;)if(!N(n[c],t[c],r,e))return!1}else{var f,l=m.keys(n);if(c=l.length,m.keys(t).length!==c)return!1;for(;c--;)if(f=l[c],!m.has(t,f)||!N(n[f],t[f],r,e))return!1}return r.pop(),e.pop(),!0};m.isEqual=function(n,t){return N(n,t)},m.isEmpty=function(n){return null==n?!0:k(n)&&(m.isArray(n)||m.isString(n)||m.isArguments(n))?0===n.length:0===m.keys(n).length},m.isElement=function(n){return!(!n||1!==n.nodeType)},m.isArray=h||function(n){return"[object Array]"===s.call(n)},m.isObject=function(n){var t=typeof n;return"function"===t||"object"===t&&!!n},m.each(["Arguments","Function","String","Number","Date","RegExp","Error"],function(n){m["is"+n]=function(t){return s.call(t)==="[object "+n+"]"}}),m.isArguments(arguments)||(m.isArguments=function(n){return m.has(n,"callee")}),"function"!=typeof/./&&"object"!=typeof Int8Array&&(m.isFunction=function(n){return"function"==typeof n||!1}),m.isFinite=function(n){return isFinite(n)&&!isNaN(parseFloat(n))},m.isNaN=function(n){return m.isNumber(n)&&n!==+n},m.isBoolean=function(n){return n===!0||n===!1||"[object Boolean]"===s.call(n)},m.isNull=function(n){return null===n},m.isUndefined=function(n){return n===void 0},m.has=function(n,t){return null!=n&&p.call(n,t)},m.noConflict=function(){return u._=i,this},m.identity=function(n){return n},m.constant=function(n){return function(){return n}},m.noop=function(){},m.property=w,m.propertyOf=function(n){return null==n?function(){}:function(t){return n[t]}},m.matcher=m.matches=function(n){return n=m.extendOwn({},n),function(t){return m.isMatch(t,n)}},m.times=function(n,t,r){var e=Array(Math.max(0,n));t=b(t,r,1);for(var u=0;n>u;u++)e[u]=t(u);return e},m.random=function(n,t){return null==t&&(t=n,n=0),n+Math.floor(Math.random()*(t-n+1))},m.now=Date.now||function(){return(new Date).getTime()};var B={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#x27;","`":"&#x60;"},T=m.invert(B),R=function(n){var t=function(t){return n[t]},r="(?:"+m.keys(n).join("|")+")",e=RegExp(r),u=RegExp(r,"g");return function(n){return n=null==n?"":""+n,e.test(n)?n.replace(u,t):n}};m.escape=R(B),m.unescape=R(T),m.result=function(n,t,r){var e=null==n?void 0:n[t];return e===void 0&&(e=r),m.isFunction(e)?e.call(n):e};var q=0;m.uniqueId=function(n){var t=++q+"";return n?n+t:t},m.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var K=/(.)^/,z={"'":"'","\\":"\\","\r":"r","\n":"n","\u2028":"u2028","\u2029":"u2029"},D=/\\|'|\r|\n|\u2028|\u2029/g,L=function(n){return"\\"+z[n]};m.template=function(n,t,r){!t&&r&&(t=r),t=m.defaults({},t,m.templateSettings);var e=RegExp([(t.escape||K).source,(t.interpolate||K).source,(t.evaluate||K).source].join("|")+"|$","g"),u=0,i="__p+='";n.replace(e,function(t,r,e,o,a){return i+=n.slice(u,a).replace(D,L),u=a+t.length,r?i+="'+\n((__t=("+r+"))==null?'':_.escape(__t))+\n'":e?i+="'+\n((__t=("+e+"))==null?'':__t)+\n'":o&&(i+="';\n"+o+"\n__p+='"),t}),i+="';\n",t.variable||(i="with(obj||{}){\n"+i+"}\n"),i="var __t,__p='',__j=Array.prototype.join,"+"print=function(){__p+=__j.call(arguments,'');};\n"+i+"return __p;\n";try{var o=new Function(t.variable||"obj","_",i)}catch(a){throw a.source=i,a}var c=function(n){return o.call(this,n,m)},f=t.variable||"obj";return c.source="function("+f+"){\n"+i+"}",c},m.chain=function(n){var t=m(n);return t._chain=!0,t};var P=function(n,t){return n._chain?m(t).chain():t};m.mixin=function(n){m.each(m.functions(n),function(t){var r=m[t]=n[t];m.prototype[t]=function(){var n=[this._wrapped];return f.apply(n,arguments),P(this,r.apply(m,n))}})},m.mixin(m),m.each(["pop","push","reverse","shift","sort","splice","unshift"],function(n){var t=o[n];m.prototype[n]=function(){var r=this._wrapped;return t.apply(r,arguments),"shift"!==n&&"splice"!==n||0!==r.length||delete r[0],P(this,r)}}),m.each(["concat","join","slice"],function(n){var t=o[n];m.prototype[n]=function(){return P(this,t.apply(this._wrapped,arguments))}}),m.prototype.value=function(){return this._wrapped},m.prototype.valueOf=m.prototype.toJSON=m.prototype.value,m.prototype.toString=function(){return""+this._wrapped},"function"==typeof define&&define.amd&&define("underscore",[],function(){return m})}).call(this); (function(t){var e=typeof self=="object"&&self.self==self&&self||typeof global=="object"&&global.global==global&&global;if(typeof define==="function"&&define.amd){define(["underscore","jquery","exports"],function(i,r,n){e.Backbone=t(e,n,i,r)})}else if(typeof exports!=="undefined"){var i=require("underscore"),r;try{r=require("jquery")}catch(n){}t(e,exports,i,r)}else{e.Backbone=t(e,{},e._,e.jQuery||e.Zepto||e.ender||e.$)}})(function(t,e,i,r){var n=t.Backbone;var s=Array.prototype.slice;e.VERSION="1.2.3";e.$=r;e.noConflict=function(){t.Backbone=n;return this};e.emulateHTTP=false;e.emulateJSON=false;var a=function(t,e,r){switch(t){case 1:return function(){return i[e](this[r])};case 2:return function(t){return i[e](this[r],t)};case 3:return function(t,n){return i[e](this[r],h(t,this),n)};case 4:return function(t,n,s){return i[e](this[r],h(t,this),n,s)};default:return function(){var t=s.call(arguments);t.unshift(this[r]);return i[e].apply(i,t)}}};var o=function(t,e,r){i.each(e,function(e,n){if(i[n])t.prototype[n]=a(e,n,r)})};var h=function(t,e){if(i.isFunction(t))return t;if(i.isObject(t)&&!e._isModel(t))return u(t);if(i.isString(t))return function(e){return e.get(t)};return t};var u=function(t){var e=i.matches(t);return function(t){return e(t.attributes)}};var l=e.Events={};var c=/\s+/;var f=function(t,e,r,n,s){var a=0,o;if(r&&typeof r==="object"){if(n!==void 0&&"context"in s&&s.context===void 0)s.context=n;for(o=i.keys(r);a<o.length;a++){e=f(t,e,o[a],r[o[a]],s)}}else if(r&&c.test(r)){for(o=r.split(c);a<o.length;a++){e=t(e,o[a],n,s)}}else{e=t(e,r,n,s)}return e};l.on=function(t,e,i){return d(this,t,e,i)};var d=function(t,e,i,r,n){t._events=f(v,t._events||{},e,i,{context:r,ctx:t,listening:n});if(n){var s=t._listeners||(t._listeners={});s[n.id]=n}return t};l.listenTo=function(t,e,r){if(!t)return this;var n=t._listenId||(t._listenId=i.uniqueId("l"));var s=this._listeningTo||(this._listeningTo={});var a=s[n];if(!a){var o=this._listenId||(this._listenId=i.uniqueId("l"));a=s[n]={obj:t,objId:n,id:o,listeningTo:s,count:0}}d(t,e,r,this,a);return this};var v=function(t,e,i,r){if(i){var n=t[e]||(t[e]=[]);var s=r.context,a=r.ctx,o=r.listening;if(o)o.count++;n.push({callback:i,context:s,ctx:s||a,listening:o})}return t};l.off=function(t,e,i){if(!this._events)return this;this._events=f(g,this._events,t,e,{context:i,listeners:this._listeners});return this};l.stopListening=function(t,e,r){var n=this._listeningTo;if(!n)return this;var s=t?[t._listenId]:i.keys(n);for(var a=0;a<s.length;a++){var o=n[s[a]];if(!o)break;o.obj.off(e,r,this)}if(i.isEmpty(n))this._listeningTo=void 0;return this};var g=function(t,e,r,n){if(!t)return;var s=0,a;var o=n.context,h=n.listeners;if(!e&&!r&&!o){var u=i.keys(h);for(;s<u.length;s++){a=h[u[s]];delete h[a.id];delete a.listeningTo[a.objId]}return}var l=e?[e]:i.keys(t);for(;s<l.length;s++){e=l[s];var c=t[e];if(!c)break;var f=[];for(var d=0;d<c.length;d++){var v=c[d];if(r&&r!==v.callback&&r!==v.callback._callback||o&&o!==v.context){f.push(v)}else{a=v.listening;if(a&&--a.count===0){delete h[a.id];delete a.listeningTo[a.objId]}}}if(f.length){t[e]=f}else{delete t[e]}}if(i.size(t))return t};l.once=function(t,e,r){var n=f(p,{},t,e,i.bind(this.off,this));return this.on(n,void 0,r)};l.listenToOnce=function(t,e,r){var n=f(p,{},e,r,i.bind(this.stopListening,this,t));return this.listenTo(t,n)};var p=function(t,e,r,n){if(r){var s=t[e]=i.once(function(){n(e,s);r.apply(this,arguments)});s._callback=r}return t};l.trigger=function(t){if(!this._events)return this;var e=Math.max(0,arguments.length-1);var i=Array(e);for(var r=0;r<e;r++)i[r]=arguments[r+1];f(m,this._events,t,void 0,i);return this};var m=function(t,e,i,r){if(t){var n=t[e];var s=t.all;if(n&&s)s=s.slice();if(n)_(n,r);if(s)_(s,[e].concat(r))}return t};var _=function(t,e){var i,r=-1,n=t.length,s=e[0],a=e[1],o=e[2];switch(e.length){case 0:while(++r<n)(i=t[r]).callback.call(i.ctx);return;case 1:while(++r<n)(i=t[r]).callback.call(i.ctx,s);return;case 2:while(++r<n)(i=t[r]).callback.call(i.ctx,s,a);return;case 3:while(++r<n)(i=t[r]).callback.call(i.ctx,s,a,o);return;default:while(++r<n)(i=t[r]).callback.apply(i.ctx,e);return}};l.bind=l.on;l.unbind=l.off;i.extend(e,l);var y=e.Model=function(t,e){var r=t||{};e||(e={});this.cid=i.uniqueId(this.cidPrefix);this.attributes={};if(e.collection)this.collection=e.collection;if(e.parse)r=this.parse(r,e)||{};r=i.defaults({},r,i.result(this,"defaults"));this.set(r,e);this.changed={};this.initialize.apply(this,arguments)};i.extend(y.prototype,l,{changed:null,validationError:null,idAttribute:"id",cidPrefix:"c",initialize:function(){},toJSON:function(t){return i.clone(this.attributes)},sync:function(){return e.sync.apply(this,arguments)},get:function(t){return this.attributes[t]},escape:function(t){return i.escape(this.get(t))},has:function(t){return this.get(t)!=null},matches:function(t){return!!i.iteratee(t,this)(this.attributes)},set:function(t,e,r){if(t==null)return this;var n;if(typeof t==="object"){n=t;r=e}else{(n={})[t]=e}r||(r={});if(!this._validate(n,r))return false;var s=r.unset;var a=r.silent;var o=[];var h=this._changing;this._changing=true;if(!h){this._previousAttributes=i.clone(this.attributes);this.changed={}}var u=this.attributes;var l=this.changed;var c=this._previousAttributes;for(var f in n){e=n[f];if(!i.isEqual(u[f],e))o.push(f);if(!i.isEqual(c[f],e)){l[f]=e}else{delete l[f]}s?delete u[f]:u[f]=e}this.id=this.get(this.idAttribute);if(!a){if(o.length)this._pending=r;for(var d=0;d<o.length;d++){this.trigger("change:"+o[d],this,u[o[d]],r)}}if(h)return this;if(!a){while(this._pending){r=this._pending;this._pending=false;this.trigger("change",this,r)}}this._pending=false;this._changing=false;return this},unset:function(t,e){return this.set(t,void 0,i.extend({},e,{unset:true}))},clear:function(t){var e={};for(var r in this.attributes)e[r]=void 0;return this.set(e,i.extend({},t,{unset:true}))},hasChanged:function(t){if(t==null)return!i.isEmpty(this.changed);return i.has(this.changed,t)},changedAttributes:function(t){if(!t)return this.hasChanged()?i.clone(this.changed):false;var e=this._changing?this._previousAttributes:this.attributes;var r={};for(var n in t){var s=t[n];if(i.isEqual(e[n],s))continue;r[n]=s}return i.size(r)?r:false},previous:function(t){if(t==null||!this._previousAttributes)return null;return this._previousAttributes[t]},previousAttributes:function(){return i.clone(this._previousAttributes)},fetch:function(t){t=i.extend({parse:true},t);var e=this;var r=t.success;t.success=function(i){var n=t.parse?e.parse(i,t):i;if(!e.set(n,t))return false;if(r)r.call(t.context,e,i,t);e.trigger("sync",e,i,t)};z(this,t);return this.sync("read",this,t)},save:function(t,e,r){var n;if(t==null||typeof t==="object"){n=t;r=e}else{(n={})[t]=e}r=i.extend({validate:true,parse:true},r);var s=r.wait;if(n&&!s){if(!this.set(n,r))return false}else{if(!this._validate(n,r))return false}var a=this;var o=r.success;var h=this.attributes;r.success=function(t){a.attributes=h;var e=r.parse?a.parse(t,r):t;if(s)e=i.extend({},n,e);if(e&&!a.set(e,r))return false;if(o)o.call(r.context,a,t,r);a.trigger("sync",a,t,r)};z(this,r);if(n&&s)this.attributes=i.extend({},h,n);var u=this.isNew()?"create":r.patch?"patch":"update";if(u==="patch"&&!r.attrs)r.attrs=n;var l=this.sync(u,this,r);this.attributes=h;return l},destroy:function(t){t=t?i.clone(t):{};var e=this;var r=t.success;var n=t.wait;var s=function(){e.stopListening();e.trigger("destroy",e,e.collection,t)};t.success=function(i){if(n)s();if(r)r.call(t.context,e,i,t);if(!e.isNew())e.trigger("sync",e,i,t)};var a=false;if(this.isNew()){i.defer(t.success)}else{z(this,t);a=this.sync("delete",this,t)}if(!n)s();return a},url:function(){var t=i.result(this,"urlRoot")||i.result(this.collection,"url")||F();if(this.isNew())return t;var e=this.get(this.idAttribute);return t.replace(/[^\/]$/,"$&/")+encodeURIComponent(e)},parse:function(t,e){return t},clone:function(){return new this.constructor(this.attributes)},isNew:function(){return!this.has(this.idAttribute)},isValid:function(t){return this._validate({},i.defaults({validate:true},t))},_validate:function(t,e){if(!e.validate||!this.validate)return true;t=i.extend({},this.attributes,t);var r=this.validationError=this.validate(t,e)||null;if(!r)return true;this.trigger("invalid",this,r,i.extend(e,{validationError:r}));return false}});var b={keys:1,values:1,pairs:1,invert:1,pick:0,omit:0,chain:1,isEmpty:1};o(y,b,"attributes");var x=e.Collection=function(t,e){e||(e={});if(e.model)this.model=e.model;if(e.comparator!==void 0)this.comparator=e.comparator;this._reset();this.initialize.apply(this,arguments);if(t)this.reset(t,i.extend({silent:true},e))};var w={add:true,remove:true,merge:true};var E={add:true,remove:false};var k=function(t,e,i){i=Math.min(Math.max(i,0),t.length);var r=Array(t.length-i);var n=e.length;for(var s=0;s<r.length;s++)r[s]=t[s+i];for(s=0;s<n;s++)t[s+i]=e[s];for(s=0;s<r.length;s++)t[s+n+i]=r[s]};i.extend(x.prototype,l,{model:y,initialize:function(){},toJSON:function(t){return this.map(function(e){return e.toJSON(t)})},sync:function(){return e.sync.apply(this,arguments)},add:function(t,e){return this.set(t,i.extend({merge:false},e,E))},remove:function(t,e){e=i.extend({},e);var r=!i.isArray(t);t=r?[t]:i.clone(t);var n=this._removeModels(t,e);if(!e.silent&&n)this.trigger("update",this,e);return r?n[0]:n},set:function(t,e){if(t==null)return;e=i.defaults({},e,w);if(e.parse&&!this._isModel(t))t=this.parse(t,e);var r=!i.isArray(t);t=r?[t]:t.slice();var n=e.at;if(n!=null)n=+n;if(n<0)n+=this.length+1;var s=[];var a=[];var o=[];var h={};var u=e.add;var l=e.merge;var c=e.remove;var f=false;var d=this.comparator&&n==null&&e.sort!==false;var v=i.isString(this.comparator)?this.comparator:null;var g;for(var p=0;p<t.length;p++){g=t[p];var m=this.get(g);if(m){if(l&&g!==m){var _=this._isModel(g)?g.attributes:g;if(e.parse)_=m.parse(_,e);m.set(_,e);if(d&&!f)f=m.hasChanged(v)}if(!h[m.cid]){h[m.cid]=true;s.push(m)}t[p]=m}else if(u){g=t[p]=this._prepareModel(g,e);if(g){a.push(g);this._addReference(g,e);h[g.cid]=true;s.push(g)}}}if(c){for(p=0;p<this.length;p++){g=this.models[p];if(!h[g.cid])o.push(g)}if(o.length)this._removeModels(o,e)}var y=false;var b=!d&&u&&c;if(s.length&&b){y=this.length!=s.length||i.some(this.models,function(t,e){return t!==s[e]});this.models.length=0;k(this.models,s,0);this.length=this.models.length}else if(a.length){if(d)f=true;k(this.models,a,n==null?this.length:n);this.length=this.models.length}if(f)this.sort({silent:true});if(!e.silent){for(p=0;p<a.length;p++){if(n!=null)e.index=n+p;g=a[p];g.trigger("add",g,this,e)}if(f||y)this.trigger("sort",this,e);if(a.length||o.length)this.trigger("update",this,e)}return r?t[0]:t},reset:function(t,e){e=e?i.clone(e):{};for(var r=0;r<this.models.length;r++){this._removeReference(this.models[r],e)}e.previousModels=this.models;this._reset();t=this.add(t,i.extend({silent:true},e));if(!e.silent)this.trigger("reset",this,e);return t},push:function(t,e){return this.add(t,i.extend({at:this.length},e))},pop:function(t){var e=this.at(this.length-1);return this.remove(e,t)},unshift:function(t,e){return this.add(t,i.extend({at:0},e))},shift:function(t){var e=this.at(0);return this.remove(e,t)},slice:function(){return s.apply(this.models,arguments)},get:function(t){if(t==null)return void 0;var e=this.modelId(this._isModel(t)?t.attributes:t);return this._byId[t]||this._byId[e]||this._byId[t.cid]},at:function(t){if(t<0)t+=this.length;return this.models[t]},where:function(t,e){return this[e?"find":"filter"](t)},findWhere:function(t){return this.where(t,true)},sort:function(t){var e=this.comparator;if(!e)throw new Error("Cannot sort a set without a comparator");t||(t={});var r=e.length;if(i.isFunction(e))e=i.bind(e,this);if(r===1||i.isString(e)){this.models=this.sortBy(e)}else{this.models.sort(e)}if(!t.silent)this.trigger("sort",this,t);return this},pluck:function(t){return i.invoke(this.models,"get",t)},fetch:function(t){t=i.extend({parse:true},t);var e=t.success;var r=this;t.success=function(i){var n=t.reset?"reset":"set";r[n](i,t);if(e)e.call(t.context,r,i,t);r.trigger("sync",r,i,t)};z(this,t);return this.sync("read",this,t)},create:function(t,e){e=e?i.clone(e):{};var r=e.wait;t=this._prepareModel(t,e);if(!t)return false;if(!r)this.add(t,e);var n=this;var s=e.success;e.success=function(t,e,i){if(r)n.add(t,i);if(s)s.call(i.context,t,e,i)};t.save(null,e);return t},parse:function(t,e){return t},clone:function(){return new this.constructor(this.models,{model:this.model,comparator:this.comparator})},modelId:function(t){return t[this.model.prototype.idAttribute||"id"]},_reset:function(){this.length=0;this.models=[];this._byId={}},_prepareModel:function(t,e){if(this._isModel(t)){if(!t.collection)t.collection=this;return t}e=e?i.clone(e):{};e.collection=this;var r=new this.model(t,e);if(!r.validationError)return r;this.trigger("invalid",this,r.validationError,e);return false},_removeModels:function(t,e){var i=[];for(var r=0;r<t.length;r++){var n=this.get(t[r]);if(!n)continue;var s=this.indexOf(n);this.models.splice(s,1);this.length--;if(!e.silent){e.index=s;n.trigger("remove",n,this,e)}i.push(n);this._removeReference(n,e)}return i.length?i:false},_isModel:function(t){return t instanceof y},_addReference:function(t,e){this._byId[t.cid]=t;var i=this.modelId(t.attributes);if(i!=null)this._byId[i]=t;t.on("all",this._onModelEvent,this)},_removeReference:function(t,e){delete this._byId[t.cid];var i=this.modelId(t.attributes);if(i!=null)delete this._byId[i];if(this===t.collection)delete t.collection;t.off("all",this._onModelEvent,this)},_onModelEvent:function(t,e,i,r){if((t==="add"||t==="remove")&&i!==this)return;if(t==="destroy")this.remove(e,r);if(t==="change"){var n=this.modelId(e.previousAttributes());var s=this.modelId(e.attributes);if(n!==s){if(n!=null)delete this._byId[n];if(s!=null)this._byId[s]=e}}this.trigger.apply(this,arguments)}});var S={forEach:3,each:3,map:3,collect:3,reduce:4,foldl:4,inject:4,reduceRight:4,foldr:4,find:3,detect:3,filter:3,select:3,reject:3,every:3,all:3,some:3,any:3,include:3,includes:3,contains:3,invoke:0,max:3,min:3,toArray:1,size:1,first:3,head:3,take:3,initial:3,rest:3,tail:3,drop:3,last:3,without:0,difference:0,indexOf:3,shuffle:1,lastIndexOf:3,isEmpty:1,chain:1,sample:3,partition:3,groupBy:3,countBy:3,sortBy:3,indexBy:3};o(x,S,"models");var I=e.View=function(t){this.cid=i.uniqueId("view");i.extend(this,i.pick(t,P));this._ensureElement();this.initialize.apply(this,arguments)};var T=/^(\S+)\s*(.*)$/;var P=["model","collection","el","id","attributes","className","tagName","events"];i.extend(I.prototype,l,{tagName:"div",$:function(t){return this.$el.find(t)},initialize:function(){},render:function(){return this},remove:function(){this._removeElement();this.stopListening();return this},_removeElement:function(){this.$el.remove()},setElement:function(t){this.undelegateEvents();this._setElement(t);this.delegateEvents();return this},_setElement:function(t){this.$el=t instanceof e.$?t:e.$(t);this.el=this.$el[0]},delegateEvents:function(t){t||(t=i.result(this,"events"));if(!t)return this;this.undelegateEvents();for(var e in t){var r=t[e];if(!i.isFunction(r))r=this[r];if(!r)continue;var n=e.match(T);this.delegate(n[1],n[2],i.bind(r,this))}return this},delegate:function(t,e,i){this.$el.on(t+".delegateEvents"+this.cid,e,i);return this},undelegateEvents:function(){if(this.$el)this.$el.off(".delegateEvents"+this.cid);return this},undelegate:function(t,e,i){this.$el.off(t+".delegateEvents"+this.cid,e,i);return this},_createElement:function(t){return document.createElement(t)},_ensureElement:function(){if(!this.el){var t=i.extend({},i.result(this,"attributes"));if(this.id)t.id=i.result(this,"id");if(this.className)t["class"]=i.result(this,"className");this.setElement(this._createElement(i.result(this,"tagName")));this._setAttributes(t)}else{this.setElement(i.result(this,"el"))}},_setAttributes:function(t){this.$el.attr(t)}});e.sync=function(t,r,n){var s=H[t];i.defaults(n||(n={}),{emulateHTTP:e.emulateHTTP,emulateJSON:e.emulateJSON});var a={type:s,dataType:"json"};if(!n.url){a.url=i.result(r,"url")||F()}if(n.data==null&&r&&(t==="create"||t==="update"||t==="patch")){a.contentType="application/json";a.data=JSON.stringify(n.attrs||r.toJSON(n))}if(n.emulateJSON){a.contentType="application/x-www-form-urlencoded";a.data=a.data?{model:a.data}:{}}if(n.emulateHTTP&&(s==="PUT"||s==="DELETE"||s==="PATCH")){a.type="POST";if(n.emulateJSON)a.data._method=s;var o=n.beforeSend;n.beforeSend=function(t){t.setRequestHeader("X-HTTP-Method-Override",s);if(o)return o.apply(this,arguments)}}if(a.type!=="GET"&&!n.emulateJSON){a.processData=false}var h=n.error;n.error=function(t,e,i){n.textStatus=e;n.errorThrown=i;if(h)h.call(n.context,t,e,i)};var u=n.xhr=e.ajax(i.extend(a,n));r.trigger("request",r,u,n);return u};var H={create:"POST",update:"PUT",patch:"PATCH","delete":"DELETE",read:"GET"};e.ajax=function(){return e.$.ajax.apply(e.$,arguments)};var $=e.Router=function(t){t||(t={});if(t.routes)this.routes=t.routes;this._bindRoutes();this.initialize.apply(this,arguments)};var A=/\((.*?)\)/g;var C=/(\(\?)?:\w+/g;var R=/\*\w+/g;var j=/[\-{}\[\]+?.,\\\^$|#\s]/g;i.extend($.prototype,l,{initialize:function(){},route:function(t,r,n){if(!i.isRegExp(t))t=this._routeToRegExp(t);if(i.isFunction(r)){n=r;r=""}if(!n)n=this[r];var s=this;e.history.route(t,function(i){var a=s._extractParameters(t,i);if(s.execute(n,a,r)!==false){s.trigger.apply(s,["route:"+r].concat(a));s.trigger("route",r,a);e.history.trigger("route",s,r,a)}});return this},execute:function(t,e,i){if(t)t.apply(this,e)},navigate:function(t,i){e.history.navigate(t,i);return this},_bindRoutes:function(){if(!this.routes)return;this.routes=i.result(this,"routes");var t,e=i.keys(this.routes);while((t=e.pop())!=null){this.route(t,this.routes[t])}},_routeToRegExp:function(t){t=t.replace(j,"\\$&").replace(A,"(?:$1)?").replace(C,function(t,e){return e?t:"([^/?]+)"}).replace(R,"([^?]*?)");return new RegExp("^"+t+"(?:\\?([\\s\\S]*))?$")},_extractParameters:function(t,e){var r=t.exec(e).slice(1);return i.map(r,function(t,e){if(e===r.length-1)return t||null;return t?decodeURIComponent(t):null})}});var M=e.History=function(){this.handlers=[];this.checkUrl=i.bind(this.checkUrl,this);if(typeof window!=="undefined"){this.location=window.location;this.history=window.history}};var N=/^[#\/]|\s+$/g;var O=/^\/+|\/+$/g;var U=/#.*$/;M.started=false;i.extend(M.prototype,l,{interval:50,atRoot:function(){var t=this.location.pathname.replace(/[^\/]$/,"$&/");return t===this.root&&!this.getSearch()},matchRoot:function(){var t=this.decodeFragment(this.location.pathname);var e=t.slice(0,this.root.length-1)+"/";return e===this.root},decodeFragment:function(t){return decodeURI(t.replace(/%25/g,"%2525"))},getSearch:function(){var t=this.location.href.replace(/#.*/,"").match(/\?.+/);return t?t[0]:""},getHash:function(t){var e=(t||this).location.href.match(/#(.*)$/);return e?e[1]:""},getPath:function(){var t=this.decodeFragment(this.location.pathname+this.getSearch()).slice(this.root.length-1);return t.charAt(0)==="/"?t.slice(1):t},getFragment:function(t){if(t==null){if(this._usePushState||!this._wantsHashChange){t=this.getPath()}else{t=this.getHash()}}return t.replace(N,"")},start:function(t){if(M.started)throw new Error("Backbone.history has already been started");M.started=true;this.options=i.extend({root:"/"},this.options,t);this.root=this.options.root;this._wantsHashChange=this.options.hashChange!==false;this._hasHashChange="onhashchange"in window&&(document.documentMode===void 0||document.documentMode>7);this._useHashChange=this._wantsHashChange&&this._hasHashChange;this._wantsPushState=!!this.options.pushState;this._hasPushState=!!(this.history&&this.history.pushState);this._usePushState=this._wantsPushState&&this._hasPushState;this.fragment=this.getFragment();this.root=("/"+this.root+"/").replace(O,"/");if(this._wantsHashChange&&this._wantsPushState){if(!this._hasPushState&&!this.atRoot()){var e=this.root.slice(0,-1)||"/";this.location.replace(e+"#"+this.getPath());return true}else if(this._hasPushState&&this.atRoot()){this.navigate(this.getHash(),{replace:true})}}if(!this._hasHashChange&&this._wantsHashChange&&!this._usePushState){this.iframe=document.createElement("iframe");this.iframe.src="javascript:0";this.iframe.style.display="none";this.iframe.tabIndex=-1;var r=document.body;var n=r.insertBefore(this.iframe,r.firstChild).contentWindow;n.document.open();n.document.close();n.location.hash="#"+this.fragment}var s=window.addEventListener||function(t,e){return attachEvent("on"+t,e)};if(this._usePushState){s("popstate",this.checkUrl,false)}else if(this._useHashChange&&!this.iframe){s("hashchange",this.checkUrl,false)}else if(this._wantsHashChange){this._checkUrlInterval=setInterval(this.checkUrl,this.interval)}if(!this.options.silent)return this.loadUrl()},stop:function(){var t=window.removeEventListener||function(t,e){return detachEvent("on"+t,e)};if(this._usePushState){t("popstate",this.checkUrl,false)}else if(this._useHashChange&&!this.iframe){t("hashchange",this.checkUrl,false)}if(this.iframe){document.body.removeChild(this.iframe);this.iframe=null}if(this._checkUrlInterval)clearInterval(this._checkUrlInterval);M.started=false},route:function(t,e){this.handlers.unshift({route:t,callback:e})},checkUrl:function(t){var e=this.getFragment();if(e===this.fragment&&this.iframe){e=this.getHash(this.iframe.contentWindow)}if(e===this.fragment)return false;if(this.iframe)this.navigate(e);this.loadUrl()},loadUrl:function(t){if(!this.matchRoot())return false;t=this.fragment=this.getFragment(t);return i.some(this.handlers,function(e){if(e.route.test(t)){e.callback(t);return true}})},navigate:function(t,e){if(!M.started)return false;if(!e||e===true)e={trigger:!!e};t=this.getFragment(t||"");var i=this.root;if(t===""||t.charAt(0)==="?"){i=i.slice(0,-1)||"/"}var r=i+t;t=this.decodeFragment(t.replace(U,""));if(this.fragment===t)return;this.fragment=t;if(this._usePushState){this.history[e.replace?"replaceState":"pushState"]({},document.title,r)}else if(this._wantsHashChange){this._updateHash(this.location,t,e.replace);if(this.iframe&&t!==this.getHash(this.iframe.contentWindow)){var n=this.iframe.contentWindow;if(!e.replace){n.document.open();n.document.close()}this._updateHash(n.location,t,e.replace)}}else{return this.location.assign(r)}if(e.trigger)return this.loadUrl(t)},_updateHash:function(t,e,i){if(i){var r=t.href.replace(/(javascript:|#).*$/,"");t.replace(r+"#"+e)}else{t.hash="#"+e}}});e.history=new M;var q=function(t,e){var r=this;var n;if(t&&i.has(t,"constructor")){n=t.constructor}else{n=function(){return r.apply(this,arguments)}}i.extend(n,r,e);var s=function(){this.constructor=n};s.prototype=r.prototype;n.prototype=new s;if(t)i.extend(n.prototype,t);n.__super__=r.prototype;return n};y.extend=x.extend=$.extend=I.extend=M.extend=q;var F=function(){throw new Error('A "url" property or function must be specified')};var z=function(t,e){var i=e.error;e.error=function(r){if(i)i.call(e.context,t,r,e);t.trigger("error",t,r,e)}};return e}); /*! * jQuery Once v2.1.1 - http://github.com/robloach/jquery-once * @license MIT, GPL-2.0 * http://opensource.org/licenses/MIT * http://opensource.org/licenses/GPL-2.0 */ (function(e){"use strict";if(typeof exports==="object"){e(require("jquery"))}else if(typeof define==="function"&&define.amd){define(["jquery"],e)}else{e(jQuery)}})(function(e){"use strict";var n=function(e){e=e||"once";if(typeof e!=="string"){throw new Error("The jQuery Once id parameter must be a string")}return e};e.fn.once=function(t){var r="jquery-once-"+n(t);return this.filter(function(){return e(this).data(r)!==true}).data(r,true)};e.fn.removeOnce=function(e){return this.findOnce(e).removeData("jquery-once-"+n(e))};e.fn.findOnce=function(t){var r="jquery-once-"+n(t);return this.filter(function(){return e(this).data(r)===true})}}); /** * @file * Parse inline JSON and initialize the drupalSettings global object. */ (function () { 'use strict'; // Use direct child elements to harden against XSS exploits when CSP is on. var settingsElement = document.querySelector('head > script[type="application/json"][data-drupal-selector="drupal-settings-json"], body > script[type="application/json"][data-drupal-selector="drupal-settings-json"]'); /** * Variable generated by Drupal with all the configuration created from PHP. * * @global * * @type {object} */ window.drupalSettings = {}; if (settingsElement !== null) { window.drupalSettings = JSON.parse(settingsElement.textContent); } })(); ; /** * @file * Defines the Drupal JavaScript API. */ /** * A jQuery object, typically the return value from a `$(selector)` call. * * Holds an HTMLElement or a collection of HTMLElements. * * @typedef {object} jQuery * * @prop {number} length=0 * Number of elements contained in the jQuery object. */ /** * Variable generated by Drupal that holds all translated strings from PHP. * * Content of this variable is automatically created by Drupal when using the * Interface Translation module. It holds the translation of strings used on * the page. * * This variable is used to pass data from the backend to the frontend. Data * contained in `drupalSettings` is used during behavior initialization. * * @global * * @var {object} drupalTranslations */ /** * Global Drupal object. * * All Drupal JavaScript APIs are contained in this namespace. * * @global * * @namespace */ window.Drupal = {behaviors: {}, locale: {}}; // Class indicating that JavaScript is enabled; used for styling purpose. document.documentElement.className += ' js'; // Allow other JavaScript libraries to use $. if (window.jQuery) { jQuery.noConflict(); } // JavaScript should be made compatible with libraries other than jQuery by // wrapping it in an anonymous closure. (function (domready, Drupal, drupalSettings, drupalTranslations) { 'use strict'; /** * Helper to rethrow errors asynchronously. * * This way Errors bubbles up outside of the original callstack, making it * easier to debug errors in the browser. * * @param {Error|string} error * The error to be thrown. */ Drupal.throwError = function (error) { setTimeout(function () { throw error; }, 0); }; /** * Custom error thrown after attach/detach if one or more behaviors failed. * Initializes the JavaScript behaviors for page loads and Ajax requests. * * @callback Drupal~behaviorAttach * * @param {HTMLDocument|HTMLElement} context * An element to detach behaviors from. * @param {?object} settings * An object containing settings for the current context. It is rarely used. * * @see Drupal.attachBehaviors */ /** * Reverts and cleans up JavaScript behavior initialization. * * @callback Drupal~behaviorDetach * * @param {HTMLDocument|HTMLElement} context * An element to attach behaviors to. * @param {object} settings * An object containing settings for the current context. * @param {string} trigger * One of `'unload'`, `'move'`, or `'serialize'`. * * @see Drupal.detachBehaviors */ /** * @typedef {object} Drupal~behavior * * @prop {Drupal~behaviorAttach} attach * Function run on page load and after an Ajax call. * @prop {Drupal~behaviorDetach} detach * Function run when content is serialized or removed from the page. */ /** * Holds all initialization methods. * * @namespace Drupal.behaviors * * @type {Object.<string, Drupal~behavior>} */ /** * Defines a behavior to be run during attach and detach phases. * * Attaches all registered behaviors to a page element. * * Behaviors are event-triggered actions that attach to page elements, * enhancing default non-JavaScript UIs. Behaviors are registered in the * {@link Drupal.behaviors} object using the method 'attach' and optionally * also 'detach'. * * {@link Drupal.attachBehaviors} is added below to the `jQuery.ready` event * and therefore runs on initial page load. Developers implementing Ajax in * their solutions should also call this function after new page content has * been loaded, feeding in an element to be processed, in order to attach all * behaviors to the new content. * * Behaviors should use `var elements = * $(context).find(selector).once('behavior-name');` to ensure the behavior is * attached only once to a given element. (Doing so enables the reprocessing * of given elements, which may be needed on occasion despite the ability to * limit behavior attachment to a particular element.) * * @example * Drupal.behaviors.behaviorName = { * attach: function (context, settings) { * // ... * }, * detach: function (context, settings, trigger) { * // ... * } * }; * * @param {HTMLDocument|HTMLElement} [context=document] * An element to attach behaviors to. * @param {object} [settings=drupalSettings] * An object containing settings for the current context. If none is given, * the global {@link drupalSettings} object is used. * * @see Drupal~behaviorAttach * @see Drupal.detachBehaviors * * @throws {Drupal~DrupalBehaviorError} */ Drupal.attachBehaviors = function (context, settings) { context = context || document; settings = settings || drupalSettings; var behaviors = Drupal.behaviors; // Execute all of them. for (var i in behaviors) { if (behaviors.hasOwnProperty(i) && typeof behaviors[i].attach === 'function') { // Don't stop the execution of behaviors in case of an error. try { behaviors[i].attach(context, settings); } catch (e) { Drupal.throwError(e); } } } }; // Attach all behaviors. domready(function () { Drupal.attachBehaviors(document, drupalSettings); }); /** * Detaches registered behaviors from a page element. * * Developers implementing Ajax in their solutions should call this function * before page content is about to be removed, feeding in an element to be * processed, in order to allow special behaviors to detach from the content. * * Such implementations should use `.findOnce()` and `.removeOnce()` to find * elements with their corresponding `Drupal.behaviors.behaviorName.attach` * implementation, i.e. `.removeOnce('behaviorName')`, to ensure the behavior * is detached only from previously processed elements. * * @param {HTMLDocument|HTMLElement} [context=document] * An element to detach behaviors from. * @param {object} [settings=drupalSettings] * An object containing settings for the current context. If none given, * the global {@link drupalSettings} object is used. * @param {string} [trigger='unload'] * A string containing what's causing the behaviors to be detached. The * possible triggers are: * - `'unload'`: The context element is being removed from the DOM. * - `'move'`: The element is about to be moved within the DOM (for example, * during a tabledrag row swap). After the move is completed, * {@link Drupal.attachBehaviors} is called, so that the behavior can undo * whatever it did in response to the move. Many behaviors won't need to * do anything simply in response to the element being moved, but because * IFRAME elements reload their "src" when being moved within the DOM, * behaviors bound to IFRAME elements (like WYSIWYG editors) may need to * take some action. * - `'serialize'`: When an Ajax form is submitted, this is called with the * form as the context. This provides every behavior within the form an * opportunity to ensure that the field elements have correct content * in them before the form is serialized. The canonical use-case is so * that WYSIWYG editors can update the hidden textarea to which they are * bound. * * @throws {Drupal~DrupalBehaviorError} * * @see Drupal~behaviorDetach * @see Drupal.attachBehaviors */ Drupal.detachBehaviors = function (context, settings, trigger) { context = context || document; settings = settings || drupalSettings; trigger = trigger || 'unload'; var behaviors = Drupal.behaviors; // Execute all of them. for (var i in behaviors) { if (behaviors.hasOwnProperty(i) && typeof behaviors[i].detach === 'function') { // Don't stop the execution of behaviors in case of an error. try { behaviors[i].detach(context, settings, trigger); } catch (e) { Drupal.throwError(e); } } } }; /** * Encodes special characters in a plain-text string for display as HTML. * * @param {string} str * The string to be encoded. * * @return {string} * The encoded string. * * @ingroup sanitization */ Drupal.checkPlain = function (str) { str = str.toString() .replace(/&/g, '&amp;') .replace(/"/g, '&quot;') .replace(/</g, '&lt;') .replace(/>/g, '&gt;'); return str; }; /** * Replaces placeholders with sanitized values in a string. * * @param {string} str * A string with placeholders. * @param {object} args * An object of replacements pairs to make. Incidences of any key in this * array are replaced with the corresponding value. Based on the first * character of the key, the value is escaped and/or themed: * - `'!variable'`: inserted as is. * - `'@variable'`: escape plain text to HTML ({@link Drupal.checkPlain}). * - `'%variable'`: escape text and theme as a placeholder for user- * submitted content ({@link Drupal.checkPlain} + * `{@link Drupal.theme}('placeholder')`). * * @return {string} * The formatted string. * * @see Drupal.t */ Drupal.formatString = function (str, args) { // Keep args intact. var processedArgs = {}; // Transform arguments before inserting them. for (var key in args) { if (args.hasOwnProperty(key)) { switch (key.charAt(0)) { // Escaped only. case '@': processedArgs[key] = Drupal.checkPlain(args[key]); break; // Pass-through. case '!': processedArgs[key] = args[key]; break; // Escaped and placeholder. default: processedArgs[key] = Drupal.theme('placeholder', args[key]); break; } } } return Drupal.stringReplace(str, processedArgs, null); }; /** * Replaces substring. * * The longest keys will be tried first. Once a substring has been replaced, * its new value will not be searched again. * * @param {string} str * A string with placeholders. * @param {object} args * Key-value pairs. * @param {Array|null} keys * Array of keys from `args`. Internal use only. * * @return {string} * The replaced string. */ Drupal.stringReplace = function (str, args, keys) { if (str.length === 0) { return str; } // If the array of keys is not passed then collect the keys from the args. if (!Array.isArray(keys)) { keys = []; for (var k in args) { if (args.hasOwnProperty(k)) { keys.push(k); } } // Order the keys by the character length. The shortest one is the first. keys.sort(function (a, b) { return a.length - b.length; }); } if (keys.length === 0) { return str; } // Take next longest one from the end. var key = keys.pop(); var fragments = str.split(key); if (keys.length) { for (var i = 0; i < fragments.length; i++) { // Process each fragment with a copy of remaining keys. fragments[i] = Drupal.stringReplace(fragments[i], args, keys.slice(0)); } } return fragments.join(args[key]); }; /** * Translates strings to the page language, or a given language. * * See the documentation of the server-side t() function for further details. * * @param {string} str * A string containing the English text to translate. * @param {Object.<string, string>} [args] * An object of replacements pairs to make after translation. Incidences * of any key in this array are replaced with the corresponding value. * See {@link Drupal.formatString}. * @param {object} [options] * Additional options for translation. * @param {string} [options.context=''] * The context the source string belongs to. * * @return {string} * The formatted string. * The translated string. */ Drupal.t = function (str, args, options) { options = options || {}; options.context = options.context || ''; // Fetch the localized version of the string. if (typeof drupalTranslations !== 'undefined' && drupalTranslations.strings && drupalTranslations.strings[options.context] && drupalTranslations.strings[options.context][str]) { str = drupalTranslations.strings[options.context][str]; } if (args) { str = Drupal.formatString(str, args); } return str; }; /** * Returns the URL to a Drupal page. * * @param {string} path * Drupal path to transform to URL. * * @return {string} * The full URL. */ Drupal.url = function (path) { return drupalSettings.path.baseUrl + drupalSettings.path.pathPrefix + path; }; /** * Returns the passed in URL as an absolute URL. * * @param {string} url * The URL string to be normalized to an absolute URL. * * @return {string} * The normalized, absolute URL. * * @see https://github.com/angular/angular.js/blob/v1.4.4/src/ng/urlUtils.js * @see https://grack.com/blog/2009/11/17/absolutizing-url-in-javascript * @see https://github.com/jquery/jquery-ui/blob/1.11.4/ui/tabs.js#L53 */ Drupal.url.toAbsolute = function (url) { var urlParsingNode = document.createElement('a'); // Decode the URL first; this is required by IE <= 6. Decoding non-UTF-8 // strings may throw an exception. try { url = decodeURIComponent(url); } catch (e) { // Empty. } urlParsingNode.setAttribute('href', url); // IE <= 7 normalizes the URL when assigned to the anchor node similar to // the other browsers. return urlParsingNode.cloneNode(false).href; }; /** * Returns true if the URL is within Drupal's base path. * * @param {string} url * The URL string to be tested. * * @return {bool} * `true` if local. * * @see https://github.com/jquery/jquery-ui/blob/1.11.4/ui/tabs.js#L58 */ Drupal.url.isLocal = function (url) { // Always use browser-derived absolute URLs in the comparison, to avoid // attempts to break out of the base path using directory traversal. var absoluteUrl = Drupal.url.toAbsolute(url); var protocol = location.protocol; // Consider URLs that match this site's base URL but use HTTPS instead of HTTP // as local as well. if (protocol === 'http:' && absoluteUrl.indexOf('https:') === 0) { protocol = 'https:'; } var baseUrl = protocol + '//' + location.host + drupalSettings.path.baseUrl.slice(0, -1); // Decoding non-UTF-8 strings may throw an exception. try { absoluteUrl = decodeURIComponent(absoluteUrl); } catch (e) { // Empty. } try { baseUrl = decodeURIComponent(baseUrl); } catch (e) { // Empty. } // The given URL matches the site's base URL, or has a path under the site's // base URL. return absoluteUrl === baseUrl || absoluteUrl.indexOf(baseUrl + '/') === 0; }; /** * Formats a string containing a count of items. * * This function ensures that the string is pluralized correctly. Since * {@link Drupal.t} is called by this function, make sure not to pass * already-localized strings to it. * * See the documentation of the server-side * \Drupal\Core\StringTranslation\TranslationInterface::formatPlural() * function for more details. * * @param {number} count * The item count to display. * @param {string} singular * The string for the singular case. Please make sure it is clear this is * singular, to ease translation (e.g. use "1 new comment" instead of "1 * new"). Do not use @count in the singular string. * @param {string} plural * The string for the plural case. Please make sure it is clear this is * plural, to ease translation. Use @count in place of the item count, as in * "@count new comments". * @param {object} [args] * An object of replacements pairs to make after translation. Incidences * of any key in this array are replaced with the corresponding value. * See {@link Drupal.formatString}. * Note that you do not need to include @count in this array. * This replacement is done automatically for the plural case. * @param {object} [options] * The options to pass to the {@link Drupal.t} function. * * @return {string} * A translated string. */ Drupal.formatPlural = function (count, singular, plural, args, options) { args = args || {}; args['@count'] = count; var pluralDelimiter = drupalSettings.pluralDelimiter; var translations = Drupal.t(singular + pluralDelimiter + plural, args, options).split(pluralDelimiter); var index = 0; // Determine the index of the plural form. if (typeof drupalTranslations !== 'undefined' && drupalTranslations.pluralFormula) { index = count in drupalTranslations.pluralFormula ? drupalTranslations.pluralFormula[count] : drupalTranslations.pluralFormula['default']; } else if (args['@count'] !== 1) { index = 1; } return translations[index]; }; /** * Encodes a Drupal path for use in a URL. * * For aesthetic reasons slashes are not escaped. * * @param {string} item * Unencoded path. * * @return {string} * The encoded path. */ Drupal.encodePath = function (item) { return window.encodeURIComponent(item).replace(/%2F/g, '/'); }; /** * Generates the themed representation of a Drupal object. * * All requests for themed output must go through this function. It examines * the request and routes it to the appropriate theme function. If the current * theme does not provide an override function, the generic theme function is * called. * * @example * <caption>To retrieve the HTML for text that should be emphasized and * displayed as a placeholder inside a sentence.</caption> * Drupal.theme('placeholder', text); * * @namespace * * @param {function} func * The name of the theme function to call. * @param {...args} * Additional arguments to pass along to the theme function. * * @return {string|object|HTMLElement|jQuery} * Any data the theme function returns. This could be a plain HTML string, * but also a complex object. */ Drupal.theme = function (func) { var args = Array.prototype.slice.apply(arguments, [1]); if (func in Drupal.theme) { return Drupal.theme[func].apply(this, args); } }; /** * Formats text for emphasized display in a placeholder inside a sentence. * * @param {string} str * The text to format (plain-text). * * @return {string} * The formatted text (html). */ Drupal.theme.placeholder = function (str) { return '<em class="placeholder">' + Drupal.checkPlain(str) + '</em>'; }; })(domready, Drupal, window.drupalSettings, window.drupalTranslations); ; /*! * jQuery UI Core 1.11.4 * http://jqueryui.com * * Copyright jQuery Foundation and other contributors * Released under the MIT license. * http://jquery.org/license * * http://api.jqueryui.com/category/ui-core/ */(function(e){typeof define=="function"&&define.amd?define(["jquery"],e):e(jQuery)})(function(e){function t(t,r){var i,s,o,u=t.nodeName.toLowerCase();return"area"===u?(i=t.parentNode,s=i.name,!t.href||!s||i.nodeName.toLowerCase()!=="map"?!1:(o=e("img[usemap='#"+s+"']")[0],!!o&&n(o))):(/^(input|select|textarea|button|object)$/.test(u)?!t.disabled:"a"===u?t.href||r:r)&&n(t)}function n(t){return e.expr.filters.visible(t)&&!e(t).parents().addBack().filter(function(){return e.css(this,"visibility")==="hidden"}).length}e.ui=e.ui||{},e.extend(e.ui,{version:"1.11.4",keyCode:{BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38}}),e.fn.extend({scrollParent:function(t){var n=this.css("position"),r=n==="absolute",i=t?/(auto|scroll|hidden)/:/(auto|scroll)/,s=this.parents().filter(function(){var t=e(this);return r&&t.css("position")==="static"?!1:i.test(t.css("overflow")+t.css("overflow-y")+t.css("overflow-x"))}).eq(0);return n==="fixed"||!s.length?e(this[0].ownerDocument||document):s},uniqueId:function(){var e=0;return function(){return this.each(function(){this.id||(this.id="ui-id-"+ ++e)})}}(),removeUniqueId:function(){return this.each(function(){/^ui-id-\d+$/.test(this.id)&&e(this).removeAttr("id")})}}),e.extend(e.expr[":"],{data:e.expr.createPseudo?e.expr.createPseudo(function(t){return function(n){return!!e.data(n,t)}}):function(t,n,r){return!!e.data(t,r[3])},focusable:function(n){return t(n,!isNaN(e.attr(n,"tabindex")))},tabbable:function(n){var r=e.attr(n,"tabindex"),i=isNaN(r);return(i||r>=0)&&t(n,!i)}}),e("<a>").outerWidth(1).jquery||e.each(["Width","Height"],function(t,n){function o(t,n,i,s){return e.each(r,function(){n-=parseFloat(e.css(t,"padding"+this))||0,i&&(n-=parseFloat(e.css(t,"border"+this+"Width"))||0),s&&(n-=parseFloat(e.css(t,"margin"+this))||0)}),n}var r=n==="Width"?["Left","Right"]:["Top","Bottom"],i=n.toLowerCase(),s={innerWidth:e.fn.innerWidth,innerHeight:e.fn.innerHeight,outerWidth:e.fn.outerWidth,outerHeight:e.fn.outerHeight};e.fn["inner"+n]=function(t){return t===undefined?s["inner"+n].call(this):this.each(function(){e(this).css(i,o(this,t)+"px")})},e.fn["outer"+n]=function(t,r){return typeof t!="number"?s["outer"+n].call(this,t):this.each(function(){e(this).css(i,o(this,t,!0,r)+"px")})}}),e.fn.addBack||(e.fn.addBack=function(e){return this.add(e==null?this.prevObject:this.prevObject.filter(e))}),e("<a>").data("a-b","a").removeData("a-b").data("a-b")&&(e.fn.removeData=function(t){return function(n){return arguments.length?t.call(this,e.camelCase(n)):t.call(this)}}(e.fn.removeData)),e.ui.ie=!!/msie [\w.]+/.exec(navigator.userAgent.toLowerCase()),e.fn.extend({focus:function(t){return function(n,r){return typeof n=="number"?this.each(function(){var t=this;setTimeout(function(){e(t).focus(),r&&r.call(t)},n)}):t.apply(this,arguments)}}(e.fn.focus),disableSelection:function(){var e="onselectstart"in document.createElement("div")?"selectstart":"mousedown";return function(){return this.bind(e+".ui-disableSelection",function(e){e.preventDefault()})}}(),enableSelection:function(){return this.unbind(".ui-disableSelection")},zIndex:function(t){if(t!==undefined)return this.css("zIndex",t);if(this.length){var n=e(this[0]),r,i;while(n.length&&n[0]!==document){r=n.css("position");if(r==="absolute"||r==="relative"||r==="fixed"){i=parseInt(n.css("zIndex"),10);if(!isNaN(i)&&i!==0)return i}n=n.parent()}}return 0}}),e.ui.plugin={add:function(t,n,r){var i,s=e.ui[t].prototype;for(i in r)s.plugins[i]=s.plugins[i]||[],s.plugins[i].push([n,r[i]])},call:function(e,t,n,r){var i,s=e.plugins[t];if(!s)return;if(!r&&(!e.element[0].parentNode||e.element[0].parentNode.nodeType===11))return;for(i=0;i<s.length;i++)e.options[s[i][0]]&&s[i][1].apply(e.element,n)}}});; /** * @file * Attaches behaviors for the Contextual module. */ (function ($, Drupal, drupalSettings, _, Backbone, JSON, storage) { 'use strict'; var options = $.extend(drupalSettings.contextual, // Merge strings on top of drupalSettings so that they are not mutable. { strings: { open: Drupal.t('Open'), close: Drupal.t('Close') } } ); // Clear the cached contextual links whenever the current user's set of // permissions changes. var cachedPermissionsHash = storage.getItem('Drupal.contextual.permissionsHash'); var permissionsHash = drupalSettings.user.permissionsHash; if (cachedPermissionsHash !== permissionsHash) { if (typeof permissionsHash === 'string') { _.chain(storage).keys().each(function (key) { if (key.substring(0, 18) === 'Drupal.contextual.') { storage.removeItem(key); } }); } storage.setItem('Drupal.contextual.permissionsHash', permissionsHash); } /** * Initializes a contextual link: updates its DOM, sets up model and views. * * @param {jQuery} $contextual * A contextual links placeholder DOM element, containing the actual * contextual links as rendered by the server. * @param {string} html * The server-side rendered HTML for this contextual link. */ function initContextual($contextual, html) { var $region = $contextual.closest('.contextual-region'); var contextual = Drupal.contextual; $contextual // Update the placeholder to contain its rendered contextual links. .html(html) // Use the placeholder as a wrapper with a specific class to provide // positioning and behavior attachment context. .addClass('contextual') // Ensure a trigger element exists before the actual contextual links. .prepend(Drupal.theme('contextualTrigger')); // Set the destination parameter on each of the contextual links. var destination = 'destination=' + Drupal.encodePath(drupalSettings.path.currentPath); $contextual.find('.contextual-links a').each(function () { var url = this.getAttribute('href'); var glue = (url.indexOf('?') === -1) ? '?' : '&'; this.setAttribute('href', url + glue + destination); }); // Create a model and the appropriate views. var model = new contextual.StateModel({ title: $region.find('h2').eq(0).text().trim() }); var viewOptions = $.extend({el: $contextual, model: model}, options); contextual.views.push({ visual: new contextual.VisualView(viewOptions), aural: new contextual.AuralView(viewOptions), keyboard: new contextual.KeyboardView(viewOptions) }); contextual.regionViews.push(new contextual.RegionView( $.extend({el: $region, model: model}, options)) ); // Add the model to the collection. This must happen after the views have // been associated with it, otherwise collection change event handlers can't // trigger the model change event handler in its views. contextual.collection.add(model); // Let other JavaScript react to the adding of a new contextual link. $(document).trigger('drupalContextualLinkAdded', { $el: $contextual, $region: $region, model: model }); // Fix visual collisions between contextual link triggers. adjustIfNestedAndOverlapping($contextual); } /** * Determines if a contextual link is nested & overlapping, if so: adjusts it. * * This only deals with two levels of nesting; deeper levels are not touched. * * @param {jQuery} $contextual * A contextual links placeholder DOM element, containing the actual * contextual links as rendered by the server. */ function adjustIfNestedAndOverlapping($contextual) { var $contextuals = $contextual // @todo confirm that .closest() is not sufficient .parents('.contextual-region').eq(-1) .find('.contextual'); // Early-return when there's no nesting. if ($contextuals.length === 1) { return; } // If the two contextual links overlap, then we move the second one. var firstTop = $contextuals.eq(0).offset().top; var secondTop = $contextuals.eq(1).offset().top; if (firstTop === secondTop) { var $nestedContextual = $contextuals.eq(1); // Retrieve height of nested contextual link. var height = 0; var $trigger = $nestedContextual.find('.trigger'); // Elements with the .visually-hidden class have no dimensions, so this // class must be temporarily removed to the calculate the height. $trigger.removeClass('visually-hidden'); height = $nestedContextual.height(); $trigger.addClass('visually-hidden'); // Adjust nested contextual link's position. $nestedContextual.css({top: $nestedContextual.position().top + height}); } } /** * Attaches outline behavior for regions associated with contextual links. * * Events * Contextual triggers an event that can be used by other scripts. * - drupalContextualLinkAdded: Triggered when a contextual link is added. * * @type {Drupal~behavior} * * @prop {Drupal~behaviorAttach} attach * Attaches the outline behavior to the right context. */ Drupal.behaviors.contextual = { attach: function (context) { var $context = $(context); // Find all contextual links placeholders, if any. var $placeholders = $context.find('[data-contextual-id]').once('contextual-render'); if ($placeholders.length === 0) { return; } // Collect the IDs for all contextual links placeholders. var ids = []; $placeholders.each(function () { ids.push($(this).attr('data-contextual-id')); }); // Update all contextual links placeholders whose HTML is cached. var uncachedIDs = _.filter(ids, function initIfCached(contextualID) { var html = storage.getItem('Drupal.contextual.' + contextualID); if (html !== null) { // Initialize after the current execution cycle, to make the AJAX // request for retrieving the uncached contextual links as soon as // possible, but also to ensure that other Drupal behaviors have had // the chance to set up an event listener on the Backbone collection // Drupal.contextual.collection. window.setTimeout(function () { initContextual($context.find('[data-contextual-id="' + contextualID + '"]'), html); }); return false; } return true; }); // Perform an AJAX request to let the server render the contextual links // for each of the placeholders. if (uncachedIDs.length > 0) { $.ajax({ url: Drupal.url('contextual/render'), type: 'POST', data: {'ids[]': uncachedIDs}, dataType: 'json', success: function (results) { _.each(results, function (html, contextualID) { // Store the metadata. storage.setItem('Drupal.contextual.' + contextualID, html); // If the rendered contextual links are empty, then the current // user does not have permission to access the associated links: // don't render anything. if (html.length > 0) { // Update the placeholders to contain its rendered contextual // links. Usually there will only be one placeholder, but it's // possible for multiple identical placeholders exist on the // page (probably because the same content appears more than // once). $placeholders = $context.find('[data-contextual-id="' + contextualID + '"]'); // Initialize the contextual links. for (var i = 0; i < $placeholders.length; i++) { initContextual($placeholders.eq(i), html); } } }); } }); } } }; /** * Namespace for contextual related functionality. * * @namespace */ Drupal.contextual = { /** * The {@link Drupal.contextual.View} instances associated with each list * element of contextual links. * * @type {Array} */ views: [], /** * The {@link Drupal.contextual.RegionView} instances associated with each * contextual region element. * * @type {Array} */ regionViews: [] }; /** * A Backbone.Collection of {@link Drupal.contextual.StateModel} instances. * * @type {Backbone.Collection} */ Drupal.contextual.collection = new Backbone.Collection([], {model: Drupal.contextual.StateModel}); /** * A trigger is an interactive element often bound to a click handler. * * @return {string} * A string representing a DOM fragment. */ Drupal.theme.contextualTrigger = function () { return '<button class="trigger visually-hidden focusable" type="button"></button>'; }; })(jQuery, Drupal, drupalSettings, _, Backbone, window.JSON, window.sessionStorage); ; /** * @file * A Backbone Model for the state of a contextual link's trigger, list & region. */ (function (Drupal, Backbone) { 'use strict'; /** * Models the state of a contextual link's trigger, list & region. * * @constructor * * @augments Backbone.Model */ Drupal.contextual.StateModel = Backbone.Model.extend(/** @lends Drupal.contextual.StateModel# */{ /** * @type {object} * * @prop {string} title * @prop {bool} regionIsHovered * @prop {bool} hasFocus * @prop {bool} isOpen * @prop {bool} isLocked */ defaults: /** @lends Drupal.contextual.StateModel# */{ /** * The title of the entity to which these contextual links apply. * * @type {string} */ title: '', /** * Represents if the contextual region is being hovered. * * @type {bool} */ regionIsHovered: false, /** * Represents if the contextual trigger or options have focus. * * @type {bool} */ hasFocus: false, /** * Represents if the contextual options for an entity are available to * be selected (i.e. whether the list of options is visible). * * @type {bool} */ isOpen: false, /** * When the model is locked, the trigger remains active. * * @type {bool} */ isLocked: false }, /** * Opens or closes the contextual link. * * If it is opened, then also give focus. * * @return {Drupal.contextual.StateModel} * The current contextual state model. */ toggleOpen: function () { var newIsOpen = !this.get('isOpen'); this.set('isOpen', newIsOpen); if (newIsOpen) { this.focus(); } return this; }, /** * Closes this contextual link. * * Does not call blur() because we want to allow a contextual link to have * focus, yet be closed for example when hovering. * * @return {Drupal.contextual.StateModel} * The current contextual state model. */ close: function () { this.set('isOpen', false); return this; }, /** * Gives focus to this contextual link. * * Also closes + removes focus from every other contextual link. * * @return {Drupal.contextual.StateModel} * The current contextual state model. */ focus: function () { this.set('hasFocus', true); var cid = this.cid; this.collection.each(function (model) { if (model.cid !== cid) { model.close().blur(); } }); return this; }, /** * Removes focus from this contextual link, unless it is open. * * @return {Drupal.contextual.StateModel} * The current contextual state model. */ blur: function () { if (!this.get('isOpen')) { this.set('hasFocus', false); } return this; } }); })(Drupal, Backbone); ; /** * @file * A Backbone View that provides the aural view of a contextual link. */ (function (Drupal, Backbone) { 'use strict'; Drupal.contextual.AuralView = Backbone.View.extend(/** @lends Drupal.contextual.AuralView# */{ /** * Renders the aural view of a contextual link (i.e. screen reader support). * * @constructs * * @augments Backbone.View * * @param {object} options * Options for the view. */ initialize: function (options) { this.options = options; this.listenTo(this.model, 'change', this.render); // Use aria-role form so that the number of items in the list is spoken. this.$el.attr('role', 'form'); // Initial render. this.render(); }, /** * @inheritdoc */ render: function () { var isOpen = this.model.get('isOpen'); // Set the hidden property of the links. this.$el.find('.contextual-links') .prop('hidden', !isOpen); // Update the view of the trigger. this.$el.find('.trigger') .text(Drupal.t('@action @title configuration options', { '@action': (!isOpen) ? this.options.strings.open : this.options.strings.close, '@title': this.model.get('title') })) .attr('aria-pressed', isOpen); } }); })(Drupal, Backbone); ; /** * @file * A Backbone View that provides keyboard interaction for a contextual link. */ (function (Drupal, Backbone) { 'use strict'; Drupal.contextual.KeyboardView = Backbone.View.extend(/** @lends Drupal.contextual.KeyboardView# */{ /** * @type {object} */ events: { 'focus .trigger': 'focus', 'focus .contextual-links a': 'focus', 'blur .trigger': function () { this.model.blur(); }, 'blur .contextual-links a': function () { // Set up a timeout to allow a user to tab between the trigger and the // contextual links without the menu dismissing. var that = this; this.timer = window.setTimeout(function () { that.model.close().blur(); }, 150); } }, /** * Provides keyboard interaction for a contextual link. * * @constructs * * @augments Backbone.View */ initialize: function () { /** * The timer is used to create a delay before dismissing the contextual * links on blur. This is only necessary when keyboard users tab into * contextual links without edit mode (i.e. without TabbingManager). * That means that if we decide to disable tabbing of contextual links * without edit mode, all this timer logic can go away. * * @type {NaN|number} */ this.timer = NaN; }, /** * Sets focus on the model; Clears the timer that dismisses the links. */ focus: function () { // Clear the timeout that might have been set by blurring a link. window.clearTimeout(this.timer); this.model.focus(); } }); })(Drupal, Backbone); ; /** * @file * A Backbone View that renders the visual view of a contextual region element. */ (function (Drupal, Backbone, Modernizr) { 'use strict'; Drupal.contextual.RegionView = Backbone.View.extend(/** @lends Drupal.contextual.RegionView# */{ /** * Events for the Backbone view. * * @return {object} * A mapping of events to be used in the view. */ events: function () { var mapping = { mouseenter: function () { this.model.set('regionIsHovered', true); }, mouseleave: function () { this.model.close().blur().set('regionIsHovered', false); } }; // We don't want mouse hover events on touch. if (Modernizr.touchevents) { mapping = {}; } return mapping; }, /** * Renders the visual view of a contextual region element. * * @constructs * * @augments Backbone.View */ initialize: function () { this.listenTo(this.model, 'change:hasFocus', this.render); }, /** * @inheritdoc * * @return {Drupal.contextual.RegionView} * The current contextual region view. */ render: function () { this.$el.toggleClass('focus', this.model.get('hasFocus')); return this; } }); })(Drupal, Backbone, Modernizr); ; /** * @file * A Backbone View that provides the visual view of a contextual link. */ (function (Drupal, Backbone, Modernizr) { 'use strict'; Drupal.contextual.VisualView = Backbone.View.extend(/** @lends Drupal.contextual.VisualView# */{ /** * Events for the Backbone view. * * @return {object} * A mapping of events to be used in the view. */ events: function () { // Prevents delay and simulated mouse events. var touchEndToClick = function (event) { event.preventDefault(); event.target.click(); }; var mapping = { 'click .trigger': function () { this.model.toggleOpen(); }, 'touchend .trigger': touchEndToClick, 'click .contextual-links a': function () { this.model.close().blur(); }, 'touchend .contextual-links a': touchEndToClick }; // We only want mouse hover events on non-touch. if (!Modernizr.touchevents) { mapping.mouseenter = function () { this.model.focus(); }; } return mapping; }, /** * Renders the visual view of a contextual link. Listens to mouse & touch. * * @constructs * * @augments Backbone.View */ initialize: function () { this.listenTo(this.model, 'change', this.render); }, /** * @inheritdoc * * @return {Drupal.contextual.VisualView} * The current contextual visual view. */ render: function () { var isOpen = this.model.get('isOpen'); // The trigger should be visible when: // - the mouse hovered over the region, // - the trigger is locked, // - and for as long as the contextual menu is open. var isVisible = this.model.get('isLocked') || this.model.get('regionIsHovered') || isOpen; this.$el // The open state determines if the links are visible. .toggleClass('open', isOpen) // Update the visibility of the trigger. .find('.trigger').toggleClass('visually-hidden', !isVisible); // Nested contextual region handling: hide any nested contextual triggers. if ('isOpen' in this.model.changed) { this.$el.closest('.contextual-region') .find('.contextual .trigger:not(:first)') .toggle(!isOpen); } return this; } }); })(Drupal, Backbone, Modernizr); ; /** * @file * Define vertical tabs functionality. */ /** * Triggers when form values inside a vertical tab changes. * * This is used to update the summary in vertical tabs in order to know what * are the important fields' values. * * @event summaryUpdated */ (function ($, Drupal, drupalSettings) { 'use strict'; /** * This script transforms a set of details into a stack of vertical tabs. * * Each tab may have a summary which can be updated by another * script. For that to work, each details element has an associated * 'verticalTabCallback' (with jQuery.data() attached to the details), * which is called every time the user performs an update to a form * element inside the tab pane. * * @type {Drupal~behavior} * * @prop {Drupal~behaviorAttach} attach * Attaches behaviors for vertical tabs. */ Drupal.behaviors.verticalTabs = { attach: function (context) { var width = drupalSettings.widthBreakpoint || 640; var mq = '(max-width: ' + width + 'px)'; if (window.matchMedia(mq).matches) { return; } $(context).find('[data-vertical-tabs-panes]').once('vertical-tabs').each(function () { var $this = $(this).addClass('vertical-tabs__panes'); var focusID = $this.find(':hidden.vertical-tabs__active-tab').val(); var tab_focus; // Check if there are some details that can be converted to // vertical-tabs. var $details = $this.find('> details'); if ($details.length === 0) { return; } // Create the tab column. var tab_list = $('<ul class="vertical-tabs__menu"></ul>'); $this.wrap('<div class="vertical-tabs clearfix"></div>').before(tab_list); // Transform each details into a tab. $details.each(function () { var $that = $(this); var vertical_tab = new Drupal.verticalTab({ title: $that.find('> summary').text(), details: $that }); tab_list.append(vertical_tab.item); $that .removeClass('collapsed') // prop() can't be used on browsers not supporting details element, // the style won't apply to them if prop() is used. .attr('open', true) .addClass('vertical-tabs__pane') .data('verticalTab', vertical_tab); if (this.id === focusID) { tab_focus = $that; } }); $(tab_list).find('> li').eq(0).addClass('first'); $(tab_list).find('> li').eq(-1).addClass('last'); if (!tab_focus) { // If the current URL has a fragment and one of the tabs contains an // element that matches the URL fragment, activate that tab. var $locationHash = $this.find(window.location.hash); if (window.location.hash && $locationHash.length) { tab_focus = $locationHash.closest('.vertical-tabs__pane'); } else { tab_focus = $this.find('> .vertical-tabs__pane').eq(0); } } if (tab_focus.length) { tab_focus.data('verticalTab').focus(); } }); } }; /** * The vertical tab object represents a single tab within a tab group. * * @constructor * * @param {object} settings * Settings object. * @param {string} settings.title * The name of the tab. * @param {jQuery} settings.details * The jQuery object of the details element that is the tab pane. * * @fires event:summaryUpdated * * @listens event:summaryUpdated */ Drupal.verticalTab = function (settings) { var self = this; $.extend(this, settings, Drupal.theme('verticalTab', settings)); this.link.attr('href', '#' + settings.details.attr('id')); this.link.on('click', function (e) { e.preventDefault(); self.focus(); }); // Keyboard events added: // Pressing the Enter key will open the tab pane. this.link.on('keydown', function (event) { if (event.keyCode === 13) { event.preventDefault(); self.focus(); // Set focus on the first input field of the visible details/tab pane. $('.vertical-tabs__pane :input:visible:enabled').eq(0).trigger('focus'); } }); this.details .on('summaryUpdated', function () { self.updateSummary(); }) .trigger('summaryUpdated'); }; Drupal.verticalTab.prototype = { /** * Displays the tab's content pane. */ focus: function () { this.details .siblings('.vertical-tabs__pane') .each(function () { var tab = $(this).data('verticalTab'); tab.details.hide(); tab.item.removeClass('is-selected'); }) .end() .show() .siblings(':hidden.vertical-tabs__active-tab') .val(this.details.attr('id')); this.item.addClass('is-selected'); // Mark the active tab for screen readers. $('#active-vertical-tab').remove(); this.link.append('<span id="active-vertical-tab" class="visually-hidden">' + Drupal.t('(active tab)') + '</span>'); }, /** * Updates the tab's summary. */ updateSummary: function () { this.summary.html(this.details.drupalGetSummary()); }, /** * Shows a vertical tab pane. * * @return {Drupal.verticalTab} * The verticalTab instance. */ tabShow: function () { // Display the tab. this.item.show(); // Show the vertical tabs. this.item.closest('.js-form-type-vertical-tabs').show(); // Update .first marker for items. We need recurse from parent to retain // the actual DOM element order as jQuery implements sortOrder, but not // as public method. this.item.parent().children('.vertical-tabs__menu-item').removeClass('first') .filter(':visible').eq(0).addClass('first'); // Display the details element. this.details.removeClass('vertical-tab--hidden').show(); // Focus this tab. this.focus(); return this; }, /** * Hides a vertical tab pane. * * @return {Drupal.verticalTab} * The verticalTab instance. */ tabHide: function () { // Hide this tab. this.item.hide(); // Update .first marker for items. We need recurse from parent to retain // the actual DOM element order as jQuery implements sortOrder, but not // as public method. this.item.parent().children('.vertical-tabs__menu-item').removeClass('first') .filter(':visible').eq(0).addClass('first'); // Hide the details element. this.details.addClass('vertical-tab--hidden').hide(); // Focus the first visible tab (if there is one). var $firstTab = this.details.siblings('.vertical-tabs__pane:not(.vertical-tab--hidden)').eq(0); if ($firstTab.length) { $firstTab.data('verticalTab').focus(); } // Hide the vertical tabs (if no tabs remain). else { this.item.closest('.js-form-type-vertical-tabs').hide(); } return this; } }; /** * Theme function for a vertical tab. * * @param {object} settings * An object with the following keys: * @param {string} settings.title * The name of the tab. * * @return {object} * This function has to return an object with at least these keys: * - item: The root tab jQuery element * - link: The anchor tag that acts as the clickable area of the tab * (jQuery version) * - summary: The jQuery element that contains the tab summary */ Drupal.theme.verticalTab = function (settings) { var tab = {}; tab.item = $('<li class="vertical-tabs__menu-item" tabindex="-1"></li>') .append(tab.link = $('<a href="#"></a>') .append(tab.title = $('<strong class="vertical-tabs__menu-item-title"></strong>').text(settings.title)) .append(tab.summary = $('<span class="vertical-tabs__menu-item-summary"></span>') ) ); return tab; }; })(jQuery, Drupal, drupalSettings); ; /** * @file * Attaches behaviors for Drupal's active link marking. */ (function (Drupal, drupalSettings) { 'use strict'; /** * Append is-active class. * * The link is only active if its path corresponds to the current path, the * language of the linked path is equal to the current language, and if the * query parameters of the link equal those of the current request, since the * same request with different query parameters may yield a different page * (e.g. pagers, exposed View filters). * * Does not discriminate based on element type, so allows you to set the * is-active class on any element: a, li… * * @type {Drupal~behavior} */ Drupal.behaviors.activeLinks = { attach: function (context) { // Start by finding all potentially active links. var path = drupalSettings.path; var queryString = JSON.stringify(path.currentQuery); var querySelector = path.currentQuery ? "[data-drupal-link-query='" + queryString + "']" : ':not([data-drupal-link-query])'; var originalSelectors = ['[data-drupal-link-system-path="' + path.currentPath + '"]']; var selectors; // If this is the front page, we have to check for the <front> path as // well. if (path.isFront) { originalSelectors.push('[data-drupal-link-system-path="<front>"]'); } // Add language filtering. selectors = [].concat( // Links without any hreflang attributes (most of them). originalSelectors.map(function (selector) { return selector + ':not([hreflang])'; }), // Links with hreflang equals to the current language. originalSelectors.map(function (selector) { return selector + '[hreflang="' + path.currentLanguage + '"]'; }) ); // Add query string selector for pagers, exposed filters. selectors = selectors.map(function (current) { return current + querySelector; }); // Query the DOM. var activeLinks = context.querySelectorAll(selectors.join(',')); var il = activeLinks.length; for (var i = 0; i < il; i++) { activeLinks[i].classList.add('is-active'); } }, detach: function (context, settings, trigger) { if (trigger === 'unload') { var activeLinks = context.querySelectorAll('[data-drupal-link-system-path].is-active'); var il = activeLinks.length; for (var i = 0; i < il; i++) { activeLinks[i].classList.remove('is-active'); } } } }; })(Drupal, drupalSettings); ; /** * @file * Menu UI admin behaviors. */ (function ($, Drupal) { 'use strict'; /** * * @type {Drupal~behavior} */ Drupal.behaviors.menuUiChangeParentItems = { attach: function (context, settings) { var $menu = $('#edit-menu').once('menu-parent'); if ($menu.length) { // Update the list of available parent menu items to match the initial // available menus. Drupal.menuUiUpdateParentList(); // Update list of available parent menu items. $menu.on('change', 'input', Drupal.menuUiUpdateParentList); } } }; /** * Function to set the options of the menu parent item dropdown. */ Drupal.menuUiUpdateParentList = function () { var $menu = $('#edit-menu'); var values = []; $menu.find('input:checked').each(function () { // Get the names of all checked menus. values.push(Drupal.checkPlain($.trim($(this).val()))); }); $.ajax({ url: location.protocol + '//' + location.host + Drupal.url('admin/structure/menu/parents'), type: 'POST', data: {'menus[]': values}, dataType: 'json', success: function (options) { var $select = $('#edit-menu-parent'); // Save key of last selected element. var selected = $select.val(); // Remove all existing options from dropdown. $select.children().remove(); // Add new options to dropdown. Keep a count of options for testing later. var totalOptions = 0; for (var machineName in options) { if (options.hasOwnProperty(machineName)) { $select.append( $('<option ' + (machineName === selected ? ' selected="selected"' : '') + '></option>').val(machineName).text(options[machineName]) ); totalOptions++; } } // Hide the parent options if there are no options for it. $select.closest('div').toggle(totalOptions > 0).attr('hidden', totalOptions === 0); } }); }; })(jQuery, Drupal); ; /** * @file * Adapted from underscore.js with the addition Drupal namespace. */ /** * Limits the invocations of a function in a given time frame. * * The debounce function wrapper should be used sparingly. One clear use case * is limiting the invocation of a callback attached to the window resize event. * * Before using the debounce function wrapper, consider first whether the * callback could be attached to an event that fires less frequently or if the * function can be written in such a way that it is only invoked under specific * conditions. * * @param {function} func * The function to be invoked. * @param {number} wait * The time period within which the callback function should only be * invoked once. For example if the wait period is 250ms, then the callback * will only be called at most 4 times per second. * @param {bool} immediate * Whether we wait at the beginning or end to execute the function. * * @return {function} * The debounced function. */ Drupal.debounce = function (func, wait, immediate) { 'use strict'; var timeout; var result; return function () { var context = this; var args = arguments; var later = function () { timeout = null; if (!immediate) { result = func.apply(context, args); } }; var callNow = immediate && !timeout; clearTimeout(timeout); timeout = setTimeout(later, wait); if (callNow) { result = func.apply(context, args); } return result; }; }; ; /*! jquery.cookie v1.4.1 | MIT */ !function(a){"function"==typeof define&&define.amd?define(["jquery"],a):"object"==typeof exports?a(require("jquery")):a(jQuery)}(function(a){function b(a){return h.raw?a:encodeURIComponent(a)}function c(a){return h.raw?a:decodeURIComponent(a)}function d(a){return b(h.json?JSON.stringify(a):String(a))}function e(a){0===a.indexOf('"')&&(a=a.slice(1,-1).replace(/\\"/g,'"').replace(/\\\\/g,"\\"));try{return a=decodeURIComponent(a.replace(g," ")),h.json?JSON.parse(a):a}catch(b){}}function f(b,c){var d=h.raw?b:e(b);return a.isFunction(c)?c(d):d}var g=/\+/g,h=a.cookie=function(e,g,i){if(void 0!==g&&!a.isFunction(g)){if(i=a.extend({},h.defaults,i),"number"==typeof i.expires){var j=i.expires,k=i.expires=new Date;k.setTime(+k+864e5*j)}return document.cookie=[b(e),"=",d(g),i.expires?"; expires="+i.expires.toUTCString():"",i.path?"; path="+i.path:"",i.domain?"; domain="+i.domain:"",i.secure?"; secure":""].join("")}for(var l=e?void 0:{},m=document.cookie?document.cookie.split("; "):[],n=0,o=m.length;o>n;n++){var p=m[n].split("="),q=c(p.shift()),r=p.join("=");if(e&&e===q){l=f(r,g);break}e||void 0===(r=f(r))||(l[q]=r)}return l};h.defaults={},a.removeCookie=function(b,c){return void 0===a.cookie(b)?!1:(a.cookie(b,"",a.extend({},c,{expires:-1})),!a.cookie(b))}});; /** * @file * Form features. */ /** * Triggers when a value in the form changed. * * The event triggers when content is typed or pasted in a text field, before * the change event triggers. * * @event formUpdated */ (function ($, Drupal, debounce) { 'use strict'; /** * Retrieves the summary for the first element. * * @return {string} * The text of the summary. */ $.fn.drupalGetSummary = function () { var callback = this.data('summaryCallback'); return (this[0] && callback) ? $.trim(callback(this[0])) : ''; }; /** * Sets the summary for all matched elements. * * @param {function} callback * Either a function that will be called each time the summary is * retrieved or a string (which is returned each time). * * @return {jQuery} * jQuery collection of the current element. * * @fires event:summaryUpdated * * @listens event:formUpdated */ $.fn.drupalSetSummary = function (callback) { var self = this; // To facilitate things, the callback should always be a function. If it's // not, we wrap it into an anonymous function which just returns the value. if (typeof callback !== 'function') { var val = callback; callback = function () { return val; }; } return this .data('summaryCallback', callback) // To prevent duplicate events, the handlers are first removed and then // (re-)added. .off('formUpdated.summary') .on('formUpdated.summary', function () { self.trigger('summaryUpdated'); }) // The actual summaryUpdated handler doesn't fire when the callback is // changed, so we have to do this manually. .trigger('summaryUpdated'); }; /** * Prevents consecutive form submissions of identical form values. * * Repetitive form submissions that would submit the identical form values * are prevented, unless the form values are different to the previously * submitted values. * * This is a simplified re-implementation of a user-agent behavior that * should be natively supported by major web browsers, but at this time, only * Firefox has a built-in protection. * * A form value-based approach ensures that the constraint is triggered for * consecutive, identical form submissions only. Compared to that, a form * button-based approach would (1) rely on [visible] buttons to exist where * technically not required and (2) require more complex state management if * there are multiple buttons in a form. * * This implementation is based on form-level submit events only and relies * on jQuery's serialize() method to determine submitted form values. As such, * the following limitations exist: * * - Event handlers on form buttons that preventDefault() do not receive a * double-submit protection. That is deemed to be fine, since such button * events typically trigger reversible client-side or server-side * operations that are local to the context of a form only. * - Changed values in advanced form controls, such as file inputs, are not * part of the form values being compared between consecutive form submits * (due to limitations of jQuery.serialize()). That is deemed to be * acceptable, because if the user forgot to attach a file, then the size of * HTTP payload will most likely be small enough to be fully passed to the * server endpoint within (milli)seconds. If a user mistakenly attached a * wrong file and is technically versed enough to cancel the form submission * (and HTTP payload) in order to attach a different file, then that * edge-case is not supported here. * * Lastly, all forms submitted via HTTP GET are idempotent by definition of * HTTP standards, so excluded in this implementation. * * @type {Drupal~behavior} */ Drupal.behaviors.formSingleSubmit = { attach: function () { function onFormSubmit(e) { var $form = $(e.currentTarget); var formValues = $form.serialize(); var previousValues = $form.attr('data-drupal-form-submit-last'); if (previousValues === formValues) { e.preventDefault(); } else { $form.attr('data-drupal-form-submit-last', formValues); } } $('body').once('form-single-submit') .on('submit.singleSubmit', 'form:not([method~="GET"])', onFormSubmit); } }; /** * Sends a 'formUpdated' event each time a form element is modified. * * @param {HTMLElement} element * The element to trigger a form updated event on. * * @fires event:formUpdated */ function triggerFormUpdated(element) { $(element).trigger('formUpdated'); } /** * Collects the IDs of all form fields in the given form. * * @param {HTMLFormElement} form * The form element to search. * * @return {Array} * Array of IDs for form fields. */ function fieldsList(form) { var $fieldList = $(form).find('[name]').map(function (index, element) { // We use id to avoid name duplicates on radio fields and filter out // elements with a name but no id. return element.getAttribute('id'); }); // Return a true array. return $.makeArray($fieldList); } /** * Triggers the 'formUpdated' event on form elements when they are modified. * * @type {Drupal~behavior} * * @prop {Drupal~behaviorAttach} attach * Attaches formUpdated behaviors. * @prop {Drupal~behaviorDetach} detach * Detaches formUpdated behaviors. * * @fires event:formUpdated */ Drupal.behaviors.formUpdated = { attach: function (context) { var $context = $(context); var contextIsForm = $context.is('form'); var $forms = (contextIsForm ? $context : $context.find('form')).once('form-updated'); var formFields; if ($forms.length) { // Initialize form behaviors, use $.makeArray to be able to use native // forEach array method and have the callback parameters in the right // order. $.makeArray($forms).forEach(function (form) { var events = 'change.formUpdated input.formUpdated '; var eventHandler = debounce(function (event) { triggerFormUpdated(event.target); }, 300); formFields = fieldsList(form).join(','); form.setAttribute('data-drupal-form-fields', formFields); $(form).on(events, eventHandler); }); } // On ajax requests context is the form element. if (contextIsForm) { formFields = fieldsList(context).join(','); // @todo replace with form.getAttribute() when #1979468 is in. var currentFields = $(context).attr('data-drupal-form-fields'); // If there has been a change in the fields or their order, trigger // formUpdated. if (formFields !== currentFields) { triggerFormUpdated(context); } } }, detach: function (context, settings, trigger) { var $context = $(context); var contextIsForm = $context.is('form'); if (trigger === 'unload') { var $forms = (contextIsForm ? $context : $context.find('form')).removeOnce('form-updated'); if ($forms.length) { $.makeArray($forms).forEach(function (form) { form.removeAttribute('data-drupal-form-fields'); $(form).off('.formUpdated'); }); } } } }; /** * Prepopulate form fields with information from the visitor browser. * * @type {Drupal~behavior} * * @prop {Drupal~behaviorAttach} attach * Attaches the behavior for filling user info from browser. */ Drupal.behaviors.fillUserInfoFromBrowser = { attach: function (context, settings) { var userInfo = ['name', 'mail', 'homepage']; var $forms = $('[data-user-info-from-browser]').once('user-info-from-browser'); if ($forms.length) { userInfo.map(function (info) { var $element = $forms.find('[name=' + info + ']'); var browserData = localStorage.getItem('Drupal.visitor.' + info); var emptyOrDefault = ($element.val() === '' || ($element.attr('data-drupal-default-value') === $element.val())); if ($element.length && emptyOrDefault && browserData) { $element.val(browserData); } }); } $forms.on('submit', function () { userInfo.map(function (info) { var $element = $forms.find('[name=' + info + ']'); if ($element.length) { localStorage.setItem('Drupal.visitor.' + info, $element.val()); } }); }); } }; })(jQuery, Drupal, Drupal.debounce); ; /** * @file * Add aria attribute handling for details and summary elements. */ (function ($, Drupal) { 'use strict'; /** * Handles `aria-expanded` and `aria-pressed` attributes on details elements. * * @type {Drupal~behavior} */ Drupal.behaviors.detailsAria = { attach: function () { $('body').once('detailsAria').on('click.detailsAria', 'summary', function (event) { var $summary = $(event.currentTarget); var open = $(event.currentTarget.parentNode).attr('open') === 'open' ? 'false' : 'true'; $summary.attr({ 'aria-expanded': open, 'aria-pressed': open }); }); } }; })(jQuery, Drupal); ; /** * @file * Polyfill for HTML5 details elements. */ (function ($, Modernizr, Drupal) { 'use strict'; /** * The collapsible details object represents a single details element. * * @constructor Drupal.CollapsibleDetails * * @param {HTMLElement} node * The details element. */ function CollapsibleDetails(node) { this.$node = $(node); this.$node.data('details', this); // Expand details if there are errors inside, or if it contains an // element that is targeted by the URI fragment identifier. var anchor = location.hash && location.hash !== '#' ? ', ' + location.hash : ''; if (this.$node.find('.error' + anchor).length) { this.$node.attr('open', true); } // Initialize and setup the summary, this.setupSummary(); // Initialize and setup the legend. this.setupLegend(); } $.extend(CollapsibleDetails, /** @lends Drupal.CollapsibleDetails */{ /** * Holds references to instantiated CollapsibleDetails objects. * * @type {Array.<Drupal.CollapsibleDetails>} */ instances: [] }); $.extend(CollapsibleDetails.prototype, /** @lends Drupal.CollapsibleDetails# */{ /** * Initialize and setup summary events and markup. * * @fires event:summaryUpdated * * @listens event:summaryUpdated */ setupSummary: function () { this.$summary = $('<span class="summary"></span>'); this.$node .on('summaryUpdated', $.proxy(this.onSummaryUpdated, this)) .trigger('summaryUpdated'); }, /** * Initialize and setup legend markup. */ setupLegend: function () { // Turn the summary into a clickable link. var $legend = this.$node.find('> summary'); $('<span class="details-summary-prefix visually-hidden"></span>') .append(this.$node.attr('open') ? Drupal.t('Hide') : Drupal.t('Show')) .prependTo($legend) .after(document.createTextNode(' ')); // .wrapInner() does not retain bound events. $('<a class="details-title"></a>') .attr('href', '#' + this.$node.attr('id')) .prepend($legend.contents()) .appendTo($legend); $legend .append(this.$summary) .on('click', $.proxy(this.onLegendClick, this)); }, /** * Handle legend clicks. * * @param {jQuery.Event} e * The event triggered. */ onLegendClick: function (e) { this.toggle(); e.preventDefault(); }, /** * Update summary. */ onSummaryUpdated: function () { var text = $.trim(this.$node.drupalGetSummary()); this.$summary.html(text ? ' (' + text + ')' : ''); }, /** * Toggle the visibility of a details element using smooth animations. */ toggle: function () { var isOpen = !!this.$node.attr('open'); var $summaryPrefix = this.$node.find('> summary span.details-summary-prefix'); if (isOpen) { $summaryPrefix.html(Drupal.t('Show')); } else { $summaryPrefix.html(Drupal.t('Hide')); } // Delay setting the attribute to emulate chrome behavior and make // details-aria.js work as expected with this polyfill. setTimeout(function () { this.$node.attr('open', !isOpen); }.bind(this), 0); } }); /** * Polyfill HTML5 details element. * * @type {Drupal~behavior} * * @prop {Drupal~behaviorAttach} attach * Attaches behavior for the details element. */ Drupal.behaviors.collapse = { attach: function (context) { if (Modernizr.details) { return; } var $collapsibleDetails = $(context).find('details').once('collapse').addClass('collapse-processed'); if ($collapsibleDetails.length) { for (var i = 0; i < $collapsibleDetails.length; i++) { CollapsibleDetails.instances.push(new CollapsibleDetails($collapsibleDetails[i])); } } } }; // Expose constructor in the public space. Drupal.CollapsibleDetails = CollapsibleDetails; })(jQuery, Modernizr, Drupal); ; /** * @file * Javascript for the node content editing form. */ (function ($, Drupal) { 'use strict'; /** * Behaviors for setting summaries on content type form. * * @type {Drupal~behavior} * * @prop {Drupal~behaviorAttach} attach * Attaches summary behaviors on content type edit forms. */ Drupal.behaviors.contentTypes = { attach: function (context) { var $context = $(context); // Provide the vertical tab summaries. $context.find('#edit-submission').drupalSetSummary(function (context) { var vals = []; vals.push(Drupal.checkPlain($(context).find('#edit-title-label').val()) || Drupal.t('Requires a title')); return vals.join(', '); }); $context.find('#edit-workflow').drupalSetSummary(function (context) { var vals = []; $(context).find('input[name^="options"]:checked').parent().each(function () { vals.push(Drupal.checkPlain($(this).text())); }); if (!$(context).find('#edit-options-status').is(':checked')) { vals.unshift(Drupal.t('Not published')); } return vals.join(', '); }); $('#edit-language', context).drupalSetSummary(function (context) { var vals = []; vals.push($('.js-form-item-language-configuration-langcode select option:selected', context).text()); $('input:checked', context).next('label').each(function () { vals.push(Drupal.checkPlain($(this).text())); }); return vals.join(', '); }); $context.find('#edit-display').drupalSetSummary(function (context) { var vals = []; var $editContext = $(context); $editContext.find('input:checked').next('label').each(function () { vals.push(Drupal.checkPlain($(this).text())); }); if (!$editContext.find('#edit-display-submitted').is(':checked')) { vals.unshift(Drupal.t("Don't display post information")); } return vals.join(', '); }); } }; })(jQuery, Drupal); ; window.matchMedia||(window.matchMedia=function(){"use strict";var e=window.styleMedia||window.media;if(!e){var t=document.createElement("style"),i=document.getElementsByTagName("script")[0],n=null;t.type="text/css";t.id="matchmediajs-test";i.parentNode.insertBefore(t,i);n="getComputedStyle"in window&&window.getComputedStyle(t,null)||t.currentStyle;e={matchMedium:function(e){var i="@media "+e+"{ #matchmediajs-test { width: 1px; } }";if(t.styleSheet){t.styleSheet.cssText=i}else{t.textContent=i}return n.width==="1px"}}}return function(t){return{matches:e.matchMedium(t||"all"),media:t||"all"}}}()); ; /** * @file * Machine name functionality. */ (function ($, Drupal, drupalSettings) { 'use strict'; /** * Attach the machine-readable name form element behavior. * * @type {Drupal~behavior} * * @prop {Drupal~behaviorAttach} attach * Attaches machine-name behaviors. */ Drupal.behaviors.machineName = { /** * Attaches the behavior. * * @param {Element} context * The context for attaching the behavior. * @param {object} settings * Settings object. * @param {object} settings.machineName * A list of elements to process, keyed by the HTML ID of the form * element containing the human-readable value. Each element is an object * defining the following properties: * - target: The HTML ID of the machine name form element. * - suffix: The HTML ID of a container to show the machine name preview * in (usually a field suffix after the human-readable name * form element). * - label: The label to show for the machine name preview. * - replace_pattern: A regular expression (without modifiers) matching * disallowed characters in the machine name; e.g., '[^a-z0-9]+'. * - replace: A character to replace disallowed characters with; e.g., * '_' or '-'. * - standalone: Whether the preview should stay in its own element * rather than the suffix of the source element. * - field_prefix: The #field_prefix of the form element. * - field_suffix: The #field_suffix of the form element. */ attach: function (context, settings) { var self = this; var $context = $(context); var timeout = null; var xhr = null; function clickEditHandler(e) { var data = e.data; data.$wrapper.removeClass('visually-hidden'); data.$target.trigger('focus'); data.$suffix.hide(); data.$source.off('.machineName'); } function machineNameHandler(e) { var data = e.data; var options = data.options; var baseValue = $(e.target).val(); var rx = new RegExp(options.replace_pattern, 'g'); var expected = baseValue.toLowerCase().replace(rx, options.replace).substr(0, options.maxlength); // Abort the last pending request because the label has changed and it // is no longer valid. if (xhr && xhr.readystate !== 4) { xhr.abort(); xhr = null; } // Wait 300 milliseconds since the last event to update the machine name // i.e., after the user has stopped typing. if (timeout) { clearTimeout(timeout); timeout = null; } timeout = setTimeout(function () { if (baseValue.toLowerCase() !== expected) { xhr = self.transliterate(baseValue, options).done(function (machine) { self.showMachineName(machine.substr(0, options.maxlength), data); }); } else { self.showMachineName(expected, data); } }, 300); } Object.keys(settings.machineName).forEach(function (source_id) { var machine = ''; var eventData; var options = settings.machineName[source_id]; var $source = $context.find(source_id).addClass('machine-name-source').once('machine-name'); var $target = $context.find(options.target).addClass('machine-name-target'); var $suffix = $context.find(options.suffix); var $wrapper = $target.closest('.js-form-item'); // All elements have to exist. if (!$source.length || !$target.length || !$suffix.length || !$wrapper.length) { return; } // Skip processing upon a form validation error on the machine name. if ($target.hasClass('error')) { return; } // Figure out the maximum length for the machine name. options.maxlength = $target.attr('maxlength'); // Hide the form item container of the machine name form element. $wrapper.addClass('visually-hidden'); // Determine the initial machine name value. Unless the machine name // form element is disabled or not empty, the initial default value is // based on the human-readable form element value. if ($target.is(':disabled') || $target.val() !== '') { machine = $target.val(); } else if ($source.val() !== '') { machine = self.transliterate($source.val(), options); } // Append the machine name preview to the source field. var $preview = $('<span class="machine-name-value">' + options.field_prefix + Drupal.checkPlain(machine) + options.field_suffix + '</span>'); $suffix.empty(); if (options.label) { $suffix.append('<span class="machine-name-label">' + options.label + ': </span>'); } $suffix.append($preview); // If the machine name cannot be edited, stop further processing. if ($target.is(':disabled')) { return; } eventData = { $source: $source, $target: $target, $suffix: $suffix, $wrapper: $wrapper, $preview: $preview, options: options }; // If it is editable, append an edit link. var $link = $('<span class="admin-link"><button type="button" class="link">' + Drupal.t('Edit') + '</button></span>').on('click', eventData, clickEditHandler); $suffix.append($link); // Preview the machine name in realtime when the human-readable name // changes, but only if there is no machine name yet; i.e., only upon // initial creation, not when editing. if ($target.val() === '') { $source.on('formUpdated.machineName', eventData, machineNameHandler) // Initialize machine name preview. .trigger('formUpdated.machineName'); } // Add a listener for an invalid event on the machine name input // to show its container and focus it. $target.on('invalid', eventData, clickEditHandler); }); }, showMachineName: function (machine, data) { var settings = data.options; // Set the machine name to the transliterated value. if (machine !== '') { if (machine !== settings.replace) { data.$target.val(machine); data.$preview.html(settings.field_prefix + Drupal.checkPlain(machine) + settings.field_suffix); } data.$suffix.show(); } else { data.$suffix.hide(); data.$target.val(machine); data.$preview.empty(); } }, /** * Transliterate a human-readable name to a machine name. * * @param {string} source * A string to transliterate. * @param {object} settings * The machine name settings for the corresponding field. * @param {string} settings.replace_pattern * A regular expression (without modifiers) matching disallowed characters * in the machine name; e.g., '[^a-z0-9]+'. * @param {string} settings.replace * A character to replace disallowed characters with; e.g., '_' or '-'. * @param {number} settings.maxlength * The maximum length of the machine name. * * @return {jQuery} * The transliterated source string. */ transliterate: function (source, settings) { return $.get(Drupal.url('machine_name/transliterate'), { text: source, langcode: drupalSettings.langcode, replace_pattern: settings.replace_pattern, replace: settings.replace, lowercase: true }); } }; })(jQuery, Drupal, drupalSettings); ; /** * @file * Responsive navigation tabs. * * This also supports collapsible navigable is the 'is-collapsible' class is * added to the main element, and a target element is included. */ (function ($, Drupal) { 'use strict'; function init(i, tab) { var $tab = $(tab); var $target = $tab.find('[data-drupal-nav-tabs-target]'); var isCollapsible = $tab.hasClass('is-collapsible'); function openMenu(e) { $target.toggleClass('is-open'); } function handleResize(e) { $tab.addClass('is-horizontal'); var $tabs = $tab.find('.tabs'); var isHorizontal = $tabs.outerHeight() <= $tabs.find('.tabs__tab').outerHeight(); $tab.toggleClass('is-horizontal', isHorizontal); if (isCollapsible) { $tab.toggleClass('is-collapse-enabled', !isHorizontal); } if (isHorizontal) { $target.removeClass('is-open'); } } $tab.addClass('position-container is-horizontal-enabled'); $tab.on('click.tabs', '[data-drupal-nav-tabs-trigger]', openMenu); $(window).on('resize.tabs', Drupal.debounce(handleResize, 150)).trigger('resize.tabs'); } /** * Initialise the tabs JS. */ Drupal.behaviors.navTabs = { attach: function (context, settings) { var $tabs = $(context).find('[data-drupal-nav-tabs]'); if ($tabs.length) { var notSmartPhone = window.matchMedia('(min-width: 300px)'); if (notSmartPhone.matches) { $tabs.once('nav-tabs').each(init); } } } }; })(jQuery, Drupal); ; /** * @file * Progress bar. */ (function ($, Drupal) { 'use strict'; /** * Theme function for the progress bar. * * @param {string} id * The id for the progress bar. * * @return {string} * The HTML for the progress bar. */ Drupal.theme.progressBar = function (id) { return '<div id="' + id + '" class="progress" aria-live="polite">' + '<div class="progress__label">&nbsp;</div>' + '<div class="progress__track"><div class="progress__bar"></div></div>' + '<div class="progress__percentage"></div>' + '<div class="progress__description">&nbsp;</div>' + '</div>'; }; /** * A progressbar object. Initialized with the given id. Must be inserted into * the DOM afterwards through progressBar.element. * * Method is the function which will perform the HTTP request to get the * progress bar state. Either "GET" or "POST". * * @example * pb = new Drupal.ProgressBar('myProgressBar'); * some_element.appendChild(pb.element); * * @constructor * * @param {string} id * The id for the progressbar. * @param {function} updateCallback * Callback to run on update. * @param {string} method * HTTP method to use. * @param {function} errorCallback * Callback to call on error. */ Drupal.ProgressBar = function (id, updateCallback, method, errorCallback) { this.id = id; this.method = method || 'GET'; this.updateCallback = updateCallback; this.errorCallback = errorCallback; // The WAI-ARIA setting aria-live="polite" will announce changes after // users // have completed their current activity and not interrupt the screen // reader. this.element = $(Drupal.theme('progressBar', id)); }; $.extend(Drupal.ProgressBar.prototype, /** @lends Drupal.ProgressBar# */{ /** * Set the percentage and status message for the progressbar. * * @param {number} percentage * The progress percentage. * @param {string} message * The message to show the user. * @param {string} label * The text for the progressbar label. */ setProgress: function (percentage, message, label) { if (percentage >= 0 && percentage <= 100) { $(this.element).find('div.progress__bar').css('width', percentage + '%'); $(this.element).find('div.progress__percentage').html(percentage + '%'); } $('div.progress__description', this.element).html(message); $('div.progress__label', this.element).html(label); if (this.updateCallback) { this.updateCallback(percentage, message, this); } }, /** * Start monitoring progress via Ajax. * * @param {string} uri * The URI to use for monitoring. * @param {number} delay * The delay for calling the monitoring URI. */ startMonitoring: function (uri, delay) { this.delay = delay; this.uri = uri; this.sendPing(); }, /** * Stop monitoring progress via Ajax. */ stopMonitoring: function () { clearTimeout(this.timer); // This allows monitoring to be stopped from within the callback. this.uri = null; }, /** * Request progress data from server. */ sendPing: function () { if (this.timer) { clearTimeout(this.timer); } if (this.uri) { var pb = this; // When doing a post request, you need non-null data. Otherwise a // HTTP 411 or HTTP 406 (with Apache mod_security) error may result. var uri = this.uri; if (uri.indexOf('?') === -1) { uri += '?'; } else { uri += '&'; } uri += '_format=json'; $.ajax({ type: this.method, url: uri, data: '', dataType: 'json', success: function (progress) { // Display errors. if (progress.status === 0) { pb.displayError(progress.data); return; } // Update display. pb.setProgress(progress.percentage, progress.message, progress.label); // Schedule next timer. pb.timer = setTimeout(function () { pb.sendPing(); }, pb.delay); }, error: function (xmlhttp) { var e = new Drupal.AjaxError(xmlhttp, pb.uri); pb.displayError('<pre>' + e.message + '</pre>'); } }); } }, /** * Display errors on the page. * * @param {string} string * The error message to show the user. */ displayError: function (string) { var error = $('<div class="messages messages--error"></div>').html(string); $(this.element).before(error).hide(); if (this.errorCallback) { this.errorCallback(this); } } }); })(jQuery, Drupal); ; /** * @file * Provides Ajax page updating via jQuery $.ajax. * * Ajax is a method of making a request via JavaScript while viewing an HTML * page. The request returns an array of commands encoded in JSON, which is * then executed to make any changes that are necessary to the page. * * Drupal uses this file to enhance form elements with `#ajax['url']` and * `#ajax['wrapper']` properties. If set, this file will automatically be * included to provide Ajax capabilities. */ (function ($, window, Drupal, drupalSettings) { 'use strict'; /** * Attaches the Ajax behavior to each Ajax form element. * * @type {Drupal~behavior} * * @prop {Drupal~behaviorAttach} attach * Initialize all {@link Drupal.Ajax} objects declared in * `drupalSettings.ajax` or initialize {@link Drupal.Ajax} objects from * DOM elements having the `use-ajax-submit` or `use-ajax` css class. * @prop {Drupal~behaviorDetach} detach * During `unload` remove all {@link Drupal.Ajax} objects related to * the removed content. */ Drupal.behaviors.AJAX = { attach: function (context, settings) { function loadAjaxBehavior(base) { var element_settings = settings.ajax[base]; if (typeof element_settings.selector === 'undefined') { element_settings.selector = '#' + base; } $(element_settings.selector).once('drupal-ajax').each(function () { element_settings.element = this; element_settings.base = base; Drupal.ajax(element_settings); }); } // Load all Ajax behaviors specified in the settings. for (var base in settings.ajax) { if (settings.ajax.hasOwnProperty(base)) { loadAjaxBehavior(base); } } // Bind Ajax behaviors to all items showing the class. $('.use-ajax').once('ajax').each(function () { var element_settings = {}; // Clicked links look better with the throbber than the progress bar. element_settings.progress = {type: 'throbber'}; // For anchor tags, these will go to the target of the anchor rather // than the usual location. var href = $(this).attr('href'); if (href) { element_settings.url = href; element_settings.event = 'click'; } element_settings.dialogType = $(this).data('dialog-type'); element_settings.dialog = $(this).data('dialog-options'); element_settings.base = $(this).attr('id'); element_settings.element = this; Drupal.ajax(element_settings); }); // This class means to submit the form to the action using Ajax. $('.use-ajax-submit').once('ajax').each(function () { var element_settings = {}; // Ajax submits specified in this manner automatically submit to the // normal form action. element_settings.url = $(this.form).attr('action'); // Form submit button clicks need to tell the form what was clicked so // it gets passed in the POST request. element_settings.setClick = true; // Form buttons use the 'click' event rather than mousedown. element_settings.event = 'click'; // Clicked form buttons look better with the throbber than the progress // bar. element_settings.progress = {type: 'throbber'}; element_settings.base = $(this).attr('id'); element_settings.element = this; Drupal.ajax(element_settings); }); }, detach: function (context, settings, trigger) { if (trigger === 'unload') { Drupal.ajax.expired().forEach(function (instance) { // Set this to null and allow garbage collection to reclaim // the memory. Drupal.ajax.instances[instance.instanceIndex] = null; }); } } }; /** * Extends Error to provide handling for Errors in Ajax. * * @constructor * * @augments Error * * @param {XMLHttpRequest} xmlhttp * XMLHttpRequest object used for the failed request. * @param {string} uri * The URI where the error occurred. * @param {string} customMessage * The custom message. */ Drupal.AjaxError = function (xmlhttp, uri, customMessage) { var statusCode; var statusText; var pathText; var responseText; var readyStateText; if (xmlhttp.status) { statusCode = '\n' + Drupal.t('An AJAX HTTP error occurred.') + '\n' + Drupal.t('HTTP Result Code: !status', {'!status': xmlhttp.status}); } else { statusCode = '\n' + Drupal.t('An AJAX HTTP request terminated abnormally.'); } statusCode += '\n' + Drupal.t('Debugging information follows.'); pathText = '\n' + Drupal.t('Path: !uri', {'!uri': uri}); statusText = ''; // In some cases, when statusCode === 0, xmlhttp.statusText may not be // defined. Unfortunately, testing for it with typeof, etc, doesn't seem to // catch that and the test causes an exception. So we need to catch the // exception here. try { statusText = '\n' + Drupal.t('StatusText: !statusText', {'!statusText': $.trim(xmlhttp.statusText)}); } catch (e) { // Empty. } responseText = ''; // Again, we don't have a way to know for sure whether accessing // xmlhttp.responseText is going to throw an exception. So we'll catch it. try { responseText = '\n' + Drupal.t('ResponseText: !responseText', {'!responseText': $.trim(xmlhttp.responseText)}); } catch (e) { // Empty. } // Make the responseText more readable by stripping HTML tags and newlines. responseText = responseText.replace(/<("[^"]*"|'[^']*'|[^'">])*>/gi, ''); responseText = responseText.replace(/[\n]+\s+/g, '\n'); // We don't need readyState except for status == 0. readyStateText = xmlhttp.status === 0 ? ('\n' + Drupal.t('ReadyState: !readyState', {'!readyState': xmlhttp.readyState})) : ''; customMessage = customMessage ? ('\n' + Drupal.t('CustomMessage: !customMessage', {'!customMessage': customMessage})) : ''; /** * Formatted and translated error message. * * @type {string} */ this.message = statusCode + pathText + statusText + customMessage + responseText + readyStateText; /** * Used by some browsers to display a more accurate stack trace. * * @type {string} */ this.name = 'AjaxError'; }; Drupal.AjaxError.prototype = new Error(); Drupal.AjaxError.prototype.constructor = Drupal.AjaxError; /** * Provides Ajax page updating via jQuery $.ajax. * * This function is designed to improve developer experience by wrapping the * initialization of {@link Drupal.Ajax} objects and storing all created * objects in the {@link Drupal.ajax.instances} array. * * @example * Drupal.behaviors.myCustomAJAXStuff = { * attach: function (context, settings) { * * var ajaxSettings = { * url: 'my/url/path', * // If the old version of Drupal.ajax() needs to be used those * // properties can be added * base: 'myBase', * element: $(context).find('.someElement') * }; * * var myAjaxObject = Drupal.ajax(ajaxSettings); * * // Declare a new Ajax command specifically for this Ajax object. * myAjaxObject.commands.insert = function (ajax, response, status) { * $('#my-wrapper').append(response.data); * alert('New content was appended to #my-wrapper'); * }; * * // This command will remove this Ajax object from the page. * myAjaxObject.commands.destroyObject = function (ajax, response, status) { * Drupal.ajax.instances[this.instanceIndex] = null; * }; * * // Programmatically trigger the Ajax request. * myAjaxObject.execute(); * } * }; * * @param {object} settings * The settings object passed to {@link Drupal.Ajax} constructor. * @param {string} [settings.base] * Base is passed to {@link Drupal.Ajax} constructor as the 'base' * parameter. * @param {HTMLElement} [settings.element] * Element parameter of {@link Drupal.Ajax} constructor, element on which * event listeners will be bound. * * @return {Drupal.Ajax} * The created Ajax object. * * @see Drupal.AjaxCommands */ Drupal.ajax = function (settings) { if (arguments.length !== 1) { throw new Error('Drupal.ajax() function must be called with one configuration object only'); } // Map those config keys to variables for the old Drupal.ajax function. var base = settings.base || false; var element = settings.element || false; delete settings.base; delete settings.element; // By default do not display progress for ajax calls without an element. if (!settings.progress && !element) { settings.progress = false; } var ajax = new Drupal.Ajax(base, element, settings); ajax.instanceIndex = Drupal.ajax.instances.length; Drupal.ajax.instances.push(ajax); return ajax; }; /** * Contains all created Ajax objects. * * @type {Array.<Drupal.Ajax|null>} */ Drupal.ajax.instances = []; /** * List all objects where the associated element is not in the DOM * * This method ignores {@link Drupal.Ajax} objects not bound to DOM elements * when created with {@link Drupal.ajax}. * * @return {Array.<Drupal.Ajax>} * The list of expired {@link Drupal.Ajax} objects. */ Drupal.ajax.expired = function () { return Drupal.ajax.instances.filter(function (instance) { return instance && instance.element !== false && !document.body.contains(instance.element); }); }; /** * Settings for an Ajax object. * * @typedef {object} Drupal.Ajax~element_settings * * @prop {string} url * Target of the Ajax request. * @prop {?string} [event] * Event bound to settings.element which will trigger the Ajax request. * @prop {bool} [keypress=true] * Triggers a request on keypress events. * @prop {?string} selector * jQuery selector targeting the element to bind events to or used with * {@link Drupal.AjaxCommands}. * @prop {string} [effect='none'] * Name of the jQuery method to use for displaying new Ajax content. * @prop {string|number} [speed='none'] * Speed with which to apply the effect. * @prop {string} [method] * Name of the jQuery method used to insert new content in the targeted * element. * @prop {object} [progress] * Settings for the display of a user-friendly loader. * @prop {string} [progress.type='throbber'] * Type of progress element, core provides `'bar'`, `'throbber'` and * `'fullscreen'`. * @prop {string} [progress.message=Drupal.t('Please wait...')] * Custom message to be used with the bar indicator. * @prop {object} [submit] * Extra data to be sent with the Ajax request. * @prop {bool} [submit.js=true] * Allows the PHP side to know this comes from an Ajax request. * @prop {object} [dialog] * Options for {@link Drupal.dialog}. * @prop {string} [dialogType] * One of `'modal'` or `'dialog'`. * @prop {string} [prevent] * List of events on which to stop default action and stop propagation. */ /** * Ajax constructor. * * The Ajax request returns an array of commands encoded in JSON, which is * then executed to make any changes that are necessary to the page. * * Drupal uses this file to enhance form elements with `#ajax['url']` and * `#ajax['wrapper']` properties. If set, this file will automatically be * included to provide Ajax capabilities. * * @constructor * * @param {string} [base] * Base parameter of {@link Drupal.Ajax} constructor * @param {HTMLElement} [element] * Element parameter of {@link Drupal.Ajax} constructor, element on which * event listeners will be bound. * @param {Drupal.Ajax~element_settings} element_settings * Settings for this Ajax object. */ Drupal.Ajax = function (base, element, element_settings) { var defaults = { event: element ? 'mousedown' : null, keypress: true, selector: base ? '#' + base : null, effect: 'none', speed: 'none', method: 'replaceWith', progress: { type: 'throbber', message: Drupal.t('Please wait...') }, submit: { js: true } }; $.extend(this, defaults, element_settings); /** * @type {Drupal.AjaxCommands} */ this.commands = new Drupal.AjaxCommands(); /** * @type {bool|number} */ this.instanceIndex = false; // @todo Remove this after refactoring the PHP code to: // - Call this 'selector'. // - Include the '#' for ID-based selectors. // - Support non-ID-based selectors. if (this.wrapper) { /** * @type {string} */ this.wrapper = '#' + this.wrapper; } /** * @type {HTMLElement} */ this.element = element; /** * @type {Drupal.Ajax~element_settings} */ this.element_settings = element_settings; // If there isn't a form, jQuery.ajax() will be used instead, allowing us to // bind Ajax to links as well. if (this.element && this.element.form) { /** * @type {jQuery} */ this.$form = $(this.element.form); } // If no Ajax callback URL was given, use the link href or form action. if (!this.url) { var $element = $(this.element); if ($element.is('a')) { this.url = $element.attr('href'); } else if (this.element && element.form) { this.url = this.$form.attr('action'); } } // Replacing 'nojs' with 'ajax' in the URL allows for an easy method to let // the server detect when it needs to degrade gracefully. // There are four scenarios to check for: // 1. /nojs/ // 2. /nojs$ - The end of a URL string. // 3. /nojs? - Followed by a query (e.g. path/nojs?destination=foobar). // 4. /nojs# - Followed by a fragment (e.g.: path/nojs#myfragment). var originalUrl = this.url; /** * Processed Ajax URL. * * @type {string} */ this.url = this.url.replace(/\/nojs(\/|$|\?|#)/g, '/ajax$1'); // If the 'nojs' version of the URL is trusted, also trust the 'ajax' // version. if (drupalSettings.ajaxTrustedUrl[originalUrl]) { drupalSettings.ajaxTrustedUrl[this.url] = true; } // Set the options for the ajaxSubmit function. // The 'this' variable will not persist inside of the options object. var ajax = this; /** * Options for the jQuery.ajax function. * * @name Drupal.Ajax#options * * @type {object} * * @prop {string} url * Ajax URL to be called. * @prop {object} data * Ajax payload. * @prop {function} beforeSerialize * Implement jQuery beforeSerialize function to call * {@link Drupal.Ajax#beforeSerialize}. * @prop {function} beforeSubmit * Implement jQuery beforeSubmit function to call * {@link Drupal.Ajax#beforeSubmit}. * @prop {function} beforeSend * Implement jQuery beforeSend function to call * {@link Drupal.Ajax#beforeSend}. * @prop {function} success * Implement jQuery success function to call * {@link Drupal.Ajax#success}. * @prop {function} complete * Implement jQuery success function to clean up ajax state and trigger an * error if needed. * @prop {string} dataType='json' * Type of the response expected. * @prop {string} type='POST' * HTTP method to use for the Ajax request. */ ajax.options = { url: ajax.url, data: ajax.submit, beforeSerialize: function (element_settings, options) { return ajax.beforeSerialize(element_settings, options); }, beforeSubmit: function (form_values, element_settings, options) { ajax.ajaxing = true; return ajax.beforeSubmit(form_values, element_settings, options); }, beforeSend: function (xmlhttprequest, options) { ajax.ajaxing = true; return ajax.beforeSend(xmlhttprequest, options); }, success: function (response, status, xmlhttprequest) { // Sanity check for browser support (object expected). // When using iFrame uploads, responses must be returned as a string. if (typeof response === 'string') { response = $.parseJSON(response); } // Prior to invoking the response's commands, verify that they can be // trusted by checking for a response header. See // \Drupal\Core\EventSubscriber\AjaxResponseSubscriber for details. // - Empty responses are harmless so can bypass verification. This // avoids an alert message for server-generated no-op responses that // skip Ajax rendering. // - Ajax objects with trusted URLs (e.g., ones defined server-side via // #ajax) can bypass header verification. This is especially useful // for Ajax with multipart forms. Because IFRAME transport is used, // the response headers cannot be accessed for verification. if (response !== null && !drupalSettings.ajaxTrustedUrl[ajax.url]) { if (xmlhttprequest.getResponseHeader('X-Drupal-Ajax-Token') !== '1') { var customMessage = Drupal.t('The response failed verification so will not be processed.'); return ajax.error(xmlhttprequest, ajax.url, customMessage); } } return ajax.success(response, status); }, complete: function (xmlhttprequest, status) { ajax.ajaxing = false; if (status === 'error' || status === 'parsererror') { return ajax.error(xmlhttprequest, ajax.url); } }, dataType: 'json', type: 'POST' }; if (element_settings.dialog) { ajax.options.data.dialogOptions = element_settings.dialog; } // Ensure that we have a valid URL by adding ? when no query parameter is // yet available, otherwise append using &. if (ajax.options.url.indexOf('?') === -1) { ajax.options.url += '?'; } else { ajax.options.url += '&'; } ajax.options.url += Drupal.ajax.WRAPPER_FORMAT + '=drupal_' + (element_settings.dialogType || 'ajax'); // Bind the ajaxSubmit function to the element event. $(ajax.element).on(element_settings.event, function (event) { if (!drupalSettings.ajaxTrustedUrl[ajax.url] && !Drupal.url.isLocal(ajax.url)) { throw new Error(Drupal.t('The callback URL is not local and not trusted: !url', {'!url': ajax.url})); } return ajax.eventResponse(this, event); }); // If necessary, enable keyboard submission so that Ajax behaviors // can be triggered through keyboard input as well as e.g. a mousedown // action. if (element_settings.keypress) { $(ajax.element).on('keypress', function (event) { return ajax.keypressResponse(this, event); }); } // If necessary, prevent the browser default action of an additional event. // For example, prevent the browser default action of a click, even if the // Ajax behavior binds to mousedown. if (element_settings.prevent) { $(ajax.element).on(element_settings.prevent, false); } }; /** * URL query attribute to indicate the wrapper used to render a request. * * The wrapper format determines how the HTML is wrapped, for example in a * modal dialog. * * @const {string} * * @default */ Drupal.ajax.WRAPPER_FORMAT = '_wrapper_format'; /** * Request parameter to indicate that a request is a Drupal Ajax request. * * @const {string} * * @default */ Drupal.Ajax.AJAX_REQUEST_PARAMETER = '_drupal_ajax'; /** * Execute the ajax request. * * Allows developers to execute an Ajax request manually without specifying * an event to respond to. * * @return {object} * Returns the jQuery.Deferred object underlying the Ajax request. If * pre-serialization fails, the Deferred will be returned in the rejected * state. */ Drupal.Ajax.prototype.execute = function () { // Do not perform another ajax command if one is already in progress. if (this.ajaxing) { return; } try { this.beforeSerialize(this.element, this.options); // Return the jqXHR so that external code can hook into the Deferred API. return $.ajax(this.options); } catch (e) { // Unset the ajax.ajaxing flag here because it won't be unset during // the complete response. this.ajaxing = false; window.alert('An error occurred while attempting to process ' + this.options.url + ': ' + e.message); // For consistency, return a rejected Deferred (i.e., jqXHR's superclass) // so that calling code can take appropriate action. return $.Deferred().reject(); } }; /** * Handle a key press. * * The Ajax object will, if instructed, bind to a key press response. This * will test to see if the key press is valid to trigger this event and * if it is, trigger it for us and prevent other keypresses from triggering. * In this case we're handling RETURN and SPACEBAR keypresses (event codes 13 * and 32. RETURN is often used to submit a form when in a textfield, and * SPACE is often used to activate an element without submitting. * * @param {HTMLElement} element * Element the event was triggered on. * @param {jQuery.Event} event * Triggered event. */ Drupal.Ajax.prototype.keypressResponse = function (element, event) { // Create a synonym for this to reduce code confusion. var ajax = this; // Detect enter key and space bar and allow the standard response for them, // except for form elements of type 'text', 'tel', 'number' and 'textarea', // where the spacebar activation causes inappropriate activation if // #ajax['keypress'] is TRUE. On a text-type widget a space should always // be a space. if (event.which === 13 || (event.which === 32 && element.type !== 'text' && element.type !== 'textarea' && element.type !== 'tel' && element.type !== 'number')) { event.preventDefault(); event.stopPropagation(); $(ajax.element_settings.element).trigger(ajax.element_settings.event); } }; /** * Handle an event that triggers an Ajax response. * * When an event that triggers an Ajax response happens, this method will * perform the actual Ajax call. It is bound to the event using * bind() in the constructor, and it uses the options specified on the * Ajax object. * * @param {HTMLElement} element * Element the event was triggered on. * @param {jQuery.Event} event * Triggered event. */ Drupal.Ajax.prototype.eventResponse = function (element, event) { event.preventDefault(); event.stopPropagation(); // Create a synonym for this to reduce code confusion. var ajax = this; // Do not perform another Ajax command if one is already in progress. if (ajax.ajaxing) { return; } try { if (ajax.$form) { // If setClick is set, we must set this to ensure that the button's // value is passed. if (ajax.setClick) { // Mark the clicked button. 'form.clk' is a special variable for // ajaxSubmit that tells the system which element got clicked to // trigger the submit. Without it there would be no 'op' or // equivalent. element.form.clk = element; } ajax.$form.ajaxSubmit(ajax.options); } else { ajax.beforeSerialize(ajax.element, ajax.options); $.ajax(ajax.options); } } catch (e) { // Unset the ajax.ajaxing flag here because it won't be unset during // the complete response. ajax.ajaxing = false; window.alert('An error occurred while attempting to process ' + ajax.options.url + ': ' + e.message); } }; /** * Handler for the form serialization. * * Runs before the beforeSend() handler (see below), and unlike that one, runs * before field data is collected. * * @param {object} [element] * Ajax object's `element_settings`. * @param {object} options * jQuery.ajax options. */ Drupal.Ajax.prototype.beforeSerialize = function (element, options) { // Allow detaching behaviors to update field values before collecting them. // This is only needed when field values are added to the POST data, so only // when there is a form such that this.$form.ajaxSubmit() is used instead of // $.ajax(). When there is no form and $.ajax() is used, beforeSerialize() // isn't called, but don't rely on that: explicitly check this.$form. if (this.$form) { var settings = this.settings || drupalSettings; Drupal.detachBehaviors(this.$form.get(0), settings, 'serialize'); } // Inform Drupal that this is an AJAX request. options.data[Drupal.Ajax.AJAX_REQUEST_PARAMETER] = 1; // Allow Drupal to return new JavaScript and CSS files to load without // returning the ones already loaded. // @see \Drupal\Core\Theme\AjaxBasePageNegotiator // @see \Drupal\Core\Asset\LibraryDependencyResolverInterface::getMinimalRepresentativeSubset() // @see system_js_settings_alter() var pageState = drupalSettings.ajaxPageState; options.data['ajax_page_state[theme]'] = pageState.theme; options.data['ajax_page_state[theme_token]'] = pageState.theme_token; options.data['ajax_page_state[libraries]'] = pageState.libraries; }; /** * Modify form values prior to form submission. * * @param {Array.<object>} form_values * Processed form values. * @param {jQuery} element * The form node as a jQuery object. * @param {object} options * jQuery.ajax options. */ Drupal.Ajax.prototype.beforeSubmit = function (form_values, element, options) { // This function is left empty to make it simple to override for modules // that wish to add functionality here. }; /** * Prepare the Ajax request before it is sent. * * @param {XMLHttpRequest} xmlhttprequest * Native Ajax object. * @param {object} options * jQuery.ajax options. */ Drupal.Ajax.prototype.beforeSend = function (xmlhttprequest, options) { // For forms without file inputs, the jQuery Form plugin serializes the // form values, and then calls jQuery's $.ajax() function, which invokes // this handler. In this circumstance, options.extraData is never used. For // forms with file inputs, the jQuery Form plugin uses the browser's normal // form submission mechanism, but captures the response in a hidden IFRAME. // In this circumstance, it calls this handler first, and then appends // hidden fields to the form to submit the values in options.extraData. // There is no simple way to know which submission mechanism will be used, // so we add to extraData regardless, and allow it to be ignored in the // former case. if (this.$form) { options.extraData = options.extraData || {}; // Let the server know when the IFRAME submission mechanism is used. The // server can use this information to wrap the JSON response in a // TEXTAREA, as per http://jquery.malsup.com/form/#file-upload. options.extraData.ajax_iframe_upload = '1'; // The triggering element is about to be disabled (see below), but if it // contains a value (e.g., a checkbox, textfield, select, etc.), ensure // that value is included in the submission. As per above, submissions // that use $.ajax() are already serialized prior to the element being // disabled, so this is only needed for IFRAME submissions. var v = $.fieldValue(this.element); if (v !== null) { options.extraData[this.element.name] = v; } } // Disable the element that received the change to prevent user interface // interaction while the Ajax request is in progress. ajax.ajaxing prevents // the element from triggering a new request, but does not prevent the user // from changing its value. $(this.element).prop('disabled', true); if (!this.progress || !this.progress.type) { return; } // Insert progress indicator. var progressIndicatorMethod = 'setProgressIndicator' + this.progress.type.slice(0, 1).toUpperCase() + this.progress.type.slice(1).toLowerCase(); if (progressIndicatorMethod in this && typeof this[progressIndicatorMethod] === 'function') { this[progressIndicatorMethod].call(this); } }; /** * Sets the progress bar progress indicator. */ Drupal.Ajax.prototype.setProgressIndicatorBar = function () { var progressBar = new Drupal.ProgressBar('ajax-progress-' + this.element.id, $.noop, this.progress.method, $.noop); if (this.progress.message) { progressBar.setProgress(-1, this.progress.message); } if (this.progress.url) { progressBar.startMonitoring(this.progress.url, this.progress.interval || 1500); } this.progress.element = $(progressBar.element).addClass('ajax-progress ajax-progress-bar'); this.progress.object = progressBar; $(this.element).after(this.progress.element); }; /** * Sets the throbber progress indicator. */ Drupal.Ajax.prototype.setProgressIndicatorThrobber = function () { this.progress.element = $('<div class="ajax-progress ajax-progress-throbber"><div class="throbber">&nbsp;</div></div>'); if (this.progress.message) { this.progress.element.find('.throbber').after('<div class="message">' + this.progress.message + '</div>'); } $(this.element).after(this.progress.element); }; /** * Sets the fullscreen progress indicator. */ Drupal.Ajax.prototype.setProgressIndicatorFullscreen = function () { this.progress.element = $('<div class="ajax-progress ajax-progress-fullscreen">&nbsp;</div>'); $('body').after(this.progress.element); }; /** * Handler for the form redirection completion. * * @param {Array.<Drupal.AjaxCommands~commandDefinition>} response * Drupal Ajax response. * @param {number} status * XMLHttpRequest status. */ Drupal.Ajax.prototype.success = function (response, status) { // Remove the progress element. if (this.progress.element) { $(this.progress.element).remove(); } if (this.progress.object) { this.progress.object.stopMonitoring(); } $(this.element).prop('disabled', false); // Save element's ancestors tree so if the element is removed from the dom // we can try to refocus one of its parents. Using addBack reverse the // result array, meaning that index 0 is the highest parent in the hierarchy // in this situation it is usually a <form> element. var elementParents = $(this.element).parents('[data-drupal-selector]').addBack().toArray(); // Track if any command is altering the focus so we can avoid changing the // focus set by the Ajax command. var focusChanged = false; for (var i in response) { if (response.hasOwnProperty(i) && response[i].command && this.commands[response[i].command]) { this.commands[response[i].command](this, response[i], status); if (response[i].command === 'invoke' && response[i].method === 'focus') { focusChanged = true; } } } // If the focus hasn't be changed by the ajax commands, try to refocus the // triggering element or one of its parents if that element does not exist // anymore. if (!focusChanged && this.element && !$(this.element).data('disable-refocus')) { var target = false; for (var n = elementParents.length - 1; !target && n > 0; n--) { target = document.querySelector('[data-drupal-selector="' + elementParents[n].getAttribute('data-drupal-selector') + '"]'); } if (target) { $(target).trigger('focus'); } } // Reattach behaviors, if they were detached in beforeSerialize(). The // attachBehaviors() called on the new content from processing the response // commands is not sufficient, because behaviors from the entire form need // to be reattached. if (this.$form) { var settings = this.settings || drupalSettings; Drupal.attachBehaviors(this.$form.get(0), settings); } // Remove any response-specific settings so they don't get used on the next // call by mistake. this.settings = null; }; /** * Build an effect object to apply an effect when adding new HTML. * * @param {object} response * Drupal Ajax response. * @param {string} [response.effect] * Override the default value of {@link Drupal.Ajax#element_settings}. * @param {string|number} [response.speed] * Override the default value of {@link Drupal.Ajax#element_settings}. * * @return {object} * Returns an object with `showEffect`, `hideEffect` and `showSpeed` * properties. */ Drupal.Ajax.prototype.getEffect = function (response) { var type = response.effect || this.effect; var speed = response.speed || this.speed; var effect = {}; if (type === 'none') { effect.showEffect = 'show'; effect.hideEffect = 'hide'; effect.showSpeed = ''; } else if (type === 'fade') { effect.showEffect = 'fadeIn'; effect.hideEffect = 'fadeOut'; effect.showSpeed = speed; } else { effect.showEffect = type + 'Toggle'; effect.hideEffect = type + 'Toggle'; effect.showSpeed = speed; } return effect; }; /** * Handler for the form redirection error. * * @param {object} xmlhttprequest * Native XMLHttpRequest object. * @param {string} uri * Ajax Request URI. * @param {string} [customMessage] * Extra message to print with the Ajax error. */ Drupal.Ajax.prototype.error = function (xmlhttprequest, uri, customMessage) { // Remove the progress element. if (this.progress.element) { $(this.progress.element).remove(); } if (this.progress.object) { this.progress.object.stopMonitoring(); } // Undo hide. $(this.wrapper).show(); // Re-enable the element. $(this.element).prop('disabled', false); // Reattach behaviors, if they were detached in beforeSerialize(). if (this.$form) { var settings = this.settings || drupalSettings; Drupal.attachBehaviors(this.$form.get(0), settings); } throw new Drupal.AjaxError(xmlhttprequest, uri, customMessage); }; /** * @typedef {object} Drupal.AjaxCommands~commandDefinition * * @prop {string} command * @prop {string} [method] * @prop {string} [selector] * @prop {string} [data] * @prop {object} [settings] * @prop {bool} [asterisk] * @prop {string} [text] * @prop {string} [title] * @prop {string} [url] * @prop {object} [argument] * @prop {string} [name] * @prop {string} [value] * @prop {string} [old] * @prop {string} [new] * @prop {bool} [merge] * @prop {Array} [args] * * @see Drupal.AjaxCommands */ /** * Provide a series of commands that the client will perform. * * @constructor */ Drupal.AjaxCommands = function () {}; Drupal.AjaxCommands.prototype = { /** * Command to insert new content into the DOM. * * @param {Drupal.Ajax} ajax * {@link Drupal.Ajax} object created by {@link Drupal.ajax}. * @param {object} response * The response from the Ajax request. * @param {string} response.data * The data to use with the jQuery method. * @param {string} [response.method] * The jQuery DOM manipulation method to be used. * @param {string} [response.selector] * A optional jQuery selector string. * @param {object} [response.settings] * An optional array of settings that will be used. * @param {number} [status] * The XMLHttpRequest status. */ insert: function (ajax, response, status) { // Get information from the response. If it is not there, default to // our presets. var $wrapper = response.selector ? $(response.selector) : $(ajax.wrapper); var method = response.method || ajax.method; var effect = ajax.getEffect(response); var settings; // We don't know what response.data contains: it might be a string of text // without HTML, so don't rely on jQuery correctly interpreting // $(response.data) as new HTML rather than a CSS selector. Also, if // response.data contains top-level text nodes, they get lost with either // $(response.data) or $('<div></div>').replaceWith(response.data). var $new_content_wrapped = $('<div></div>').html(response.data); var $new_content = $new_content_wrapped.contents(); // For legacy reasons, the effects processing code assumes that // $new_content consists of a single top-level element. Also, it has not // been sufficiently tested whether attachBehaviors() can be successfully // called with a context object that includes top-level text nodes. // However, to give developers full control of the HTML appearing in the // page, and to enable Ajax content to be inserted in places where <div> // elements are not allowed (e.g., within <table>, <tr>, and <span> // parents), we check if the new content satisfies the requirement // of a single top-level element, and only use the container <div> created // above when it doesn't. For more information, please see // https://www.drupal.org/node/736066. if ($new_content.length !== 1 || $new_content.get(0).nodeType !== 1) { $new_content = $new_content_wrapped; } // If removing content from the wrapper, detach behaviors first. switch (method) { case 'html': case 'replaceWith': case 'replaceAll': case 'empty': case 'remove': settings = response.settings || ajax.settings || drupalSettings; Drupal.detachBehaviors($wrapper.get(0), settings); } // Add the new content to the page. $wrapper[method]($new_content); // Immediately hide the new content if we're using any effects. if (effect.showEffect !== 'show') { $new_content.hide(); } // Determine which effect to use and what content will receive the // effect, then show the new content. if ($new_content.find('.ajax-new-content').length > 0) { $new_content.find('.ajax-new-content').hide(); $new_content.show(); $new_content.find('.ajax-new-content')[effect.showEffect](effect.showSpeed); } else if (effect.showEffect !== 'show') { $new_content[effect.showEffect](effect.showSpeed); } // Attach all JavaScript behaviors to the new content, if it was // successfully added to the page, this if statement allows // `#ajax['wrapper']` to be optional. if ($new_content.parents('html').length > 0) { // Apply any settings from the returned JSON if available. settings = response.settings || ajax.settings || drupalSettings; Drupal.attachBehaviors($new_content.get(0), settings); } }, /** * Command to remove a chunk from the page. * * @param {Drupal.Ajax} [ajax] * {@link Drupal.Ajax} object created by {@link Drupal.ajax}. * @param {object} response * The response from the Ajax request. * @param {string} response.selector * A jQuery selector string. * @param {object} [response.settings] * An optional array of settings that will be used. * @param {number} [status] * The XMLHttpRequest status. */ remove: function (ajax, response, status) { var settings = response.settings || ajax.settings || drupalSettings; $(response.selector).each(function () { Drupal.detachBehaviors(this, settings); }) .remove(); }, /** * Command to mark a chunk changed. * * @param {Drupal.Ajax} [ajax] * {@link Drupal.Ajax} object created by {@link Drupal.ajax}. * @param {object} response * The JSON response object from the Ajax request. * @param {string} response.selector * A jQuery selector string. * @param {bool} [response.asterisk] * An optional CSS selector. If specified, an asterisk will be * appended to the HTML inside the provided selector. * @param {number} [status] * The request status. */ changed: function (ajax, response, status) { var $element = $(response.selector); if (!$element.hasClass('ajax-changed')) { $element.addClass('ajax-changed'); if (response.asterisk) { $element.find(response.asterisk).append(' <abbr class="ajax-changed" title="' + Drupal.t('Changed') + '">*</abbr> '); } } }, /** * Command to provide an alert. * * @param {Drupal.Ajax} [ajax] * {@link Drupal.Ajax} object created by {@link Drupal.ajax}. * @param {object} response * The JSON response from the Ajax request. * @param {string} response.text * The text that will be displayed in an alert dialog. * @param {number} [status] * The XMLHttpRequest status. */ alert: function (ajax, response, status) { window.alert(response.text, response.title); }, /** * Command to set the window.location, redirecting the browser. * * @param {Drupal.Ajax} [ajax] * {@link Drupal.Ajax} object created by {@link Drupal.ajax}. * @param {object} response * The response from the Ajax request. * @param {string} response.url * The URL to redirect to. * @param {number} [status] * The XMLHttpRequest status. */ redirect: function (ajax, response, status) { window.location = response.url; }, /** * Command to provide the jQuery css() function. * * @param {Drupal.Ajax} [ajax] * {@link Drupal.Ajax} object created by {@link Drupal.ajax}. * @param {object} response * The response from the Ajax request. * @param {string} response.selector * A jQuery selector string. * @param {object} response.argument * An array of key/value pairs to set in the CSS for the selector. * @param {number} [status] * The XMLHttpRequest status. */ css: function (ajax, response, status) { $(response.selector).css(response.argument); }, /** * Command to set the settings used for other commands in this response. * * This method will also remove expired `drupalSettings.ajax` settings. * * @param {Drupal.Ajax} [ajax] * {@link Drupal.Ajax} object created by {@link Drupal.ajax}. * @param {object} response * The response from the Ajax request. * @param {bool} response.merge * Determines whether the additional settings should be merged to the * global settings. * @param {object} response.settings * Contains additional settings to add to the global settings. * @param {number} [status] * The XMLHttpRequest status. */ settings: function (ajax, response, status) { var ajaxSettings = drupalSettings.ajax; // Clean up drupalSettings.ajax. if (ajaxSettings) { Drupal.ajax.expired().forEach(function (instance) { // If the Ajax object has been created through drupalSettings.ajax // it will have a selector. When there is no selector the object // has been initialized with a special class name picked up by the // Ajax behavior. if (instance.selector) { var selector = instance.selector.replace('#', ''); if (selector in ajaxSettings) { delete ajaxSettings[selector]; } } }); } if (response.merge) { $.extend(true, drupalSettings, response.settings); } else { ajax.settings = response.settings; } }, /** * Command to attach data using jQuery's data API. * * @param {Drupal.Ajax} [ajax] * {@link Drupal.Ajax} object created by {@link Drupal.ajax}. * @param {object} response * The response from the Ajax request. * @param {string} response.name * The name or key (in the key value pair) of the data attached to this * selector. * @param {string} response.selector * A jQuery selector string. * @param {string|object} response.value * The value of to be attached. * @param {number} [status] * The XMLHttpRequest status. */ data: function (ajax, response, status) { $(response.selector).data(response.name, response.value); }, /** * Command to apply a jQuery method. * * @param {Drupal.Ajax} [ajax] * {@link Drupal.Ajax} object created by {@link Drupal.ajax}. * @param {object} response * The response from the Ajax request. * @param {Array} response.args * An array of arguments to the jQuery method, if any. * @param {string} response.method * The jQuery method to invoke. * @param {string} response.selector * A jQuery selector string. * @param {number} [status] * The XMLHttpRequest status. */ invoke: function (ajax, response, status) { var $element = $(response.selector); $element[response.method].apply($element, response.args); }, /** * Command to restripe a table. * * @param {Drupal.Ajax} [ajax] * {@link Drupal.Ajax} object created by {@link Drupal.ajax}. * @param {object} response * The response from the Ajax request. * @param {string} response.selector * A jQuery selector string. * @param {number} [status] * The XMLHttpRequest status. */ restripe: function (ajax, response, status) { // :even and :odd are reversed because jQuery counts from 0 and // we count from 1, so we're out of sync. // Match immediate children of the parent element to allow nesting. $(response.selector).find('> tbody > tr:visible, > tr:visible') .removeClass('odd even') .filter(':even').addClass('odd').end() .filter(':odd').addClass('even'); }, /** * Command to update a form's build ID. * * @param {Drupal.Ajax} [ajax] * {@link Drupal.Ajax} object created by {@link Drupal.ajax}. * @param {object} response * The response from the Ajax request. * @param {string} response.old * The old form build ID. * @param {string} response.new * The new form build ID. * @param {number} [status] * The XMLHttpRequest status. */ update_build_id: function (ajax, response, status) { $('input[name="form_build_id"][value="' + response.old + '"]').val(response.new); }, /** * Command to add css. * * Uses the proprietary addImport method if available as browsers which * support that method ignore @import statements in dynamically added * stylesheets. * * @param {Drupal.Ajax} [ajax] * {@link Drupal.Ajax} object created by {@link Drupal.ajax}. * @param {object} response * The response from the Ajax request. * @param {string} response.data * A string that contains the styles to be added. * @param {number} [status] * The XMLHttpRequest status. */ add_css: function (ajax, response, status) { // Add the styles in the normal way. $('head').prepend(response.data); // Add imports in the styles using the addImport method if available. var match; var importMatch = /^@import url\("(.*)"\);$/igm; if (document.styleSheets[0].addImport && importMatch.test(response.data)) { importMatch.lastIndex = 0; do { match = importMatch.exec(response.data); document.styleSheets[0].addImport(match[1]); } while (match); } } }; })(jQuery, window, Drupal, drupalSettings); ; /** * @file * Adds an HTML element and method to trigger audio UAs to read system messages. * * Use {@link Drupal.announce} to indicate to screen reader users that an * element on the page has changed state. For instance, if clicking a link * loads 10 more items into a list, one might announce the change like this. * * @example * $('#search-list') * .on('itemInsert', function (event, data) { * // Insert the new items. * $(data.container.el).append(data.items.el); * // Announce the change to the page contents. * Drupal.announce(Drupal.t('@count items added to @container', * {'@count': data.items.length, '@container': data.container.title} * )); * }); */ (function (Drupal, debounce) { 'use strict'; var liveElement; var announcements = []; /** * Builds a div element with the aria-live attribute and add it to the DOM. * * @type {Drupal~behavior} * * @prop {Drupal~behaviorAttach} attach * Attaches the behavior for drupalAnnouce. */ Drupal.behaviors.drupalAnnounce = { attach: function (context) { // Create only one aria-live element. if (!liveElement) { liveElement = document.createElement('div'); liveElement.id = 'drupal-live-announce'; liveElement.className = 'visually-hidden'; liveElement.setAttribute('aria-live', 'polite'); liveElement.setAttribute('aria-busy', 'false'); document.body.appendChild(liveElement); } } }; /** * Concatenates announcements to a single string; appends to the live region. */ function announce() { var text = []; var priority = 'polite'; var announcement; // Create an array of announcement strings to be joined and appended to the // aria live region. var il = announcements.length; for (var i = 0; i < il; i++) { announcement = announcements.pop(); text.unshift(announcement.text); // If any of the announcements has a priority of assertive then the group // of joined announcements will have this priority. if (announcement.priority === 'assertive') { priority = 'assertive'; } } if (text.length) { // Clear the liveElement so that repeated strings will be read. liveElement.innerHTML = ''; // Set the busy state to true until the node changes are complete. liveElement.setAttribute('aria-busy', 'true'); // Set the priority to assertive, or default to polite. liveElement.setAttribute('aria-live', priority); // Print the text to the live region. Text should be run through // Drupal.t() before being passed to Drupal.announce(). liveElement.innerHTML = text.join('\n'); // The live text area is updated. Allow the AT to announce the text. liveElement.setAttribute('aria-busy', 'false'); } } /** * Triggers audio UAs to read the supplied text. * * The aria-live region will only read the text that currently populates its * text node. Replacing text quickly in rapid calls to announce results in * only the text from the most recent call to {@link Drupal.announce} being * read. By wrapping the call to announce in a debounce function, we allow for * time for multiple calls to {@link Drupal.announce} to queue up their * messages. These messages are then joined and append to the aria-live region * as one text node. * * @param {string} text * A string to be read by the UA. * @param {string} [priority='polite'] * A string to indicate the priority of the message. Can be either * 'polite' or 'assertive'. * * @return {function} * The return of the call to debounce. * * @see http://www.w3.org/WAI/PF/aria-practices/#liveprops */ Drupal.announce = function (text, priority) { // Save the text and priority into a closure variable. Multiple simultaneous // announcements will be concatenated and read in sequence. announcements.push({ text: text, priority: priority }); // Immediately invoke the function that debounce returns. 200 ms is right at // the cusp where humans notice a pause, so we will wait // at most this much time before the set of queued announcements is read. return (debounce(announce, 200)()); }; }(Drupal, Drupal.debounce)); ; (function(){if(window.matchMedia&&window.matchMedia("all").addListener){return false}var e=window.matchMedia,i=e("only all").matches,n=false,t=0,a=[],r=function(i){clearTimeout(t);t=setTimeout(function(){for(var i=0,n=a.length;i<n;i++){var t=a[i].mql,r=a[i].listeners||[],o=e(t.media).matches;if(o!==t.matches){t.matches=o;for(var s=0,l=r.length;s<l;s++){r[s].call(window,t)}}}},30)};window.matchMedia=function(t){var o=e(t),s=[],l=0;o.addListener=function(e){if(!i){return}if(!n){n=true;window.addEventListener("resize",r,true)}if(l===0){l=a.push({mql:o,listeners:s})}s.push(e)};o.removeListener=function(e){for(var i=0,n=s.length;i<n;i++){if(s[i]===e){s.splice(i,1)}}};return o}})(); ; /** * @file * Manages elements that can offset the size of the viewport. * * Measures and reports viewport offset dimensions from elements like the * toolbar that can potentially displace the positioning of other elements. */ /** * @typedef {object} Drupal~displaceOffset * * @prop {number} top * @prop {number} left * @prop {number} right * @prop {number} bottom */ /** * Triggers when layout of the page changes. * * This is used to position fixed element on the page during page resize and * Toolbar toggling. * * @event drupalViewportOffsetChange */ (function ($, Drupal, debounce) { 'use strict'; /** * @name Drupal.displace.offsets * * @type {Drupal~displaceOffset} */ var offsets = { top: 0, right: 0, bottom: 0, left: 0 }; /** * Registers a resize handler on the window. * * @type {Drupal~behavior} */ Drupal.behaviors.drupalDisplace = { attach: function () { // Mark this behavior as processed on the first pass. if (this.displaceProcessed) { return; } this.displaceProcessed = true; $(window).on('resize.drupalDisplace', debounce(displace, 200)); } }; /** * Informs listeners of the current offset dimensions. * * @function Drupal.displace * * @prop {Drupal~displaceOffset} offsets * * @param {bool} [broadcast] * When true or undefined, causes the recalculated offsets values to be * broadcast to listeners. * * @return {Drupal~displaceOffset} * An object whose keys are the for sides an element -- top, right, bottom * and left. The value of each key is the viewport displacement distance for * that edge. * * @fires event:drupalViewportOffsetChange */ function displace(broadcast) { offsets = Drupal.displace.offsets = calculateOffsets(); if (typeof broadcast === 'undefined' || broadcast) { $(document).trigger('drupalViewportOffsetChange', offsets); } return offsets; } /** * Determines the viewport offsets. * * @return {Drupal~displaceOffset} * An object whose keys are the for sides an element -- top, right, bottom * and left. The value of each key is the viewport displacement distance for * that edge. */ function calculateOffsets() { return { top: calculateOffset('top'), right: calculateOffset('right'), bottom: calculateOffset('bottom'), left: calculateOffset('left') }; } /** * Gets a specific edge's offset. * * Any element with the attribute data-offset-{edge} e.g. data-offset-top will * be considered in the viewport offset calculations. If the attribute has a * numeric value, that value will be used. If no value is provided, one will * be calculated using the element's dimensions and placement. * * @function Drupal.displace.calculateOffset * * @param {string} edge * The name of the edge to calculate. Can be 'top', 'right', * 'bottom' or 'left'. * * @return {number} * The viewport displacement distance for the requested edge. */ function calculateOffset(edge) { var edgeOffset = 0; var displacingElements = document.querySelectorAll('[data-offset-' + edge + ']'); var n = displacingElements.length; for (var i = 0; i < n; i++) { var el = displacingElements[i]; // If the element is not visible, do consider its dimensions. if (el.style.display === 'none') { continue; } // If the offset data attribute contains a displacing value, use it. var displacement = parseInt(el.getAttribute('data-offset-' + edge), 10); // If the element's offset data attribute exits // but is not a valid number then get the displacement // dimensions directly from the element. if (isNaN(displacement)) { displacement = getRawOffset(el, edge); } // If the displacement value is larger than the current value for this // edge, use the displacement value. edgeOffset = Math.max(edgeOffset, displacement); } return edgeOffset; } /** * Calculates displacement for element based on its dimensions and placement. * * @param {HTMLElement} el * The jQuery element whose dimensions and placement will be measured. * * @param {string} edge * The name of the edge of the viewport that the element is associated * with. * * @return {number} * The viewport displacement distance for the requested edge. */ function getRawOffset(el, edge) { var $el = $(el); var documentElement = document.documentElement; var displacement = 0; var horizontal = (edge === 'left' || edge === 'right'); // Get the offset of the element itself. var placement = $el.offset()[horizontal ? 'left' : 'top']; // Subtract scroll distance from placement to get the distance // to the edge of the viewport. placement -= window['scroll' + (horizontal ? 'X' : 'Y')] || document.documentElement['scroll' + (horizontal) ? 'Left' : 'Top'] || 0; // Find the displacement value according to the edge. switch (edge) { // Left and top elements displace as a sum of their own offset value // plus their size. case 'top': // Total displacement is the sum of the elements placement and size. displacement = placement + $el.outerHeight(); break; case 'left': // Total displacement is the sum of the elements placement and size. displacement = placement + $el.outerWidth(); break; // Right and bottom elements displace according to their left and // top offset. Their size isn't important. case 'bottom': displacement = documentElement.clientHeight - placement; break; case 'right': displacement = documentElement.clientWidth - placement; break; default: displacement = 0; } return displacement; } /** * Assign the displace function to a property of the Drupal global object. * * @ignore */ Drupal.displace = displace; $.extend(Drupal.displace, { /** * Expose offsets to other scripts to avoid having to recalculate offsets. * * @ignore */ offsets: offsets, /** * Expose method to compute a single edge offsets. * * @ignore */ calculateOffset: calculateOffset }); })(jQuery, Drupal, Drupal.debounce); ; /** * @file * Builds a nested accordion widget. * * Invoke on an HTML list element with the jQuery plugin pattern. * * @example * $('.toolbar-menu').drupalToolbarMenu(); */ (function ($, Drupal, drupalSettings) { 'use strict'; /** * Store the open menu tray. */ var activeItem = Drupal.url(drupalSettings.path.currentPath); $.fn.drupalToolbarMenu = function () { var ui = { handleOpen: Drupal.t('Extend'), handleClose: Drupal.t('Collapse') }; /** * Handle clicks from the disclosure button on an item with sub-items. * * @param {Object} event * A jQuery Event object. */ function toggleClickHandler(event) { var $toggle = $(event.target); var $item = $toggle.closest('li'); // Toggle the list item. toggleList($item); // Close open sibling menus. var $openItems = $item.siblings().filter('.open'); toggleList($openItems, false); } /** * Handle clicks from a menu item link. * * @param {Object} event * A jQuery Event object. */ function linkClickHandler(event) { // If the toolbar is positioned fixed (and therefore hiding content // underneath), then users expect clicks in the administration menu tray // to take them to that destination but for the menu tray to be closed // after clicking: otherwise the toolbar itself is obstructing the view // of the destination they chose. if (!Drupal.toolbar.models.toolbarModel.get('isFixed')) { Drupal.toolbar.models.toolbarModel.set('activeTab', null); } // Stopping propagation to make sure that once a toolbar-box is clicked // (the whitespace part), the page is not redirected anymore. event.stopPropagation(); } /** * Toggle the open/close state of a list is a menu. * * @param {jQuery} $item * The li item to be toggled. * * @param {Boolean} switcher * A flag that forces toggleClass to add or a remove a class, rather than * simply toggling its presence. */ function toggleList($item, switcher) { var $toggle = $item.children('.toolbar-box').children('.toolbar-handle'); switcher = (typeof switcher !== 'undefined') ? switcher : !$item.hasClass('open'); // Toggle the item open state. $item.toggleClass('open', switcher); // Twist the toggle. $toggle.toggleClass('open', switcher); // Adjust the toggle text. $toggle .find('.action') // Expand Structure, Collapse Structure. .text((switcher) ? ui.handleClose : ui.handleOpen); } /** * Add markup to the menu elements. * * Items with sub-elements have a list toggle attached to them. Menu item * links and the corresponding list toggle are wrapped with in a div * classed with .toolbar-box. The .toolbar-box div provides a positioning * context for the item list toggle. * * @param {jQuery} $menu * The root of the menu to be initialized. */ function initItems($menu) { var options = { class: 'toolbar-icon toolbar-handle', action: ui.handleOpen, text: '' }; // Initialize items and their links. $menu.find('li > a').wrap('<div class="toolbar-box">'); // Add a handle to each list item if it has a menu. $menu.find('li').each(function (index, element) { var $item = $(element); if ($item.children('ul.toolbar-menu').length) { var $box = $item.children('.toolbar-box'); options.text = Drupal.t('@label', {'@label': $box.find('a').text()}); $item.children('.toolbar-box') .append(Drupal.theme('toolbarMenuItemToggle', options)); } }); } /** * Adds a level class to each list based on its depth in the menu. * * This function is called recursively on each sub level of lists elements * until the depth of the menu is exhausted. * * @param {jQuery} $lists * A jQuery object of ul elements. * * @param {number} level * The current level number to be assigned to the list elements. */ function markListLevels($lists, level) { level = (!level) ? 1 : level; var $lis = $lists.children('li').addClass('level-' + level); $lists = $lis.children('ul'); if ($lists.length) { markListLevels($lists, level + 1); } } /** * On page load, open the active menu item. * * Marks the trail of the active link in the menu back to the root of the * menu with .menu-item--active-trail. * * @param {jQuery} $menu * The root of the menu. */ function openActiveItem($menu) { var pathItem = $menu.find('a[href="' + location.pathname + '"]'); if (pathItem.length && !activeItem) { activeItem = location.pathname; } if (activeItem) { var $activeItem = $menu.find('a[href="' + activeItem + '"]').addClass('menu-item--active'); var $activeTrail = $activeItem.parentsUntil('.root', 'li').addClass('menu-item--active-trail'); toggleList($activeTrail, true); } } // Return the jQuery object. return this.each(function (selector) { var $menu = $(this).once('toolbar-menu'); if ($menu.length) { // Bind event handlers. $menu .on('click.toolbar', '.toolbar-box', toggleClickHandler) .on('click.toolbar', '.toolbar-box a', linkClickHandler); $menu.addClass('root'); initItems($menu); markListLevels($menu); // Restore previous and active states. openActiveItem($menu); } }); }; /** * A toggle is an interactive element often bound to a click handler. * * @param {object} options * Options for the button. * @param {string} options.class * Class to set on the button. * @param {string} options.action * Action for the button. * @param {string} options.text * Used as label for the button. * * @return {string} * A string representing a DOM fragment. */ Drupal.theme.toolbarMenuItemToggle = function (options) { return '<button class="' + options['class'] + '"><span class="action">' + options.action + '</span><span class="label">' + options.text + '</span></button>'; }; }(jQuery, Drupal, drupalSettings)); ; /** * @file * Defines the behavior of the Drupal administration toolbar. */ (function ($, Drupal, drupalSettings) { 'use strict'; // Merge run-time settings with the defaults. var options = $.extend( { breakpoints: { 'toolbar.narrow': '', 'toolbar.standard': '', 'toolbar.wide': '' } }, drupalSettings.toolbar, // Merge strings on top of drupalSettings so that they are not mutable. { strings: { horizontal: Drupal.t('Horizontal orientation'), vertical: Drupal.t('Vertical orientation') } } ); /** * Registers tabs with the toolbar. * * The Drupal toolbar allows modules to register top-level tabs. These may * point directly to a resource or toggle the visibility of a tray. * * Modules register tabs with hook_toolbar(). * * @type {Drupal~behavior} * * @prop {Drupal~behaviorAttach} attach * Attaches the toolbar rendering functionality to the toolbar element. */ Drupal.behaviors.toolbar = { attach: function (context) { // Verify that the user agent understands media queries. Complex admin // toolbar layouts require media query support. if (!window.matchMedia('only screen').matches) { return; } // Process the administrative toolbar. $(context).find('#toolbar-administration').once('toolbar').each(function () { // Establish the toolbar models and views. var model = Drupal.toolbar.models.toolbarModel = new Drupal.toolbar.ToolbarModel({ locked: JSON.parse(localStorage.getItem('Drupal.toolbar.trayVerticalLocked')) || false, activeTab: document.getElementById(JSON.parse(localStorage.getItem('Drupal.toolbar.activeTabID'))) }); Drupal.toolbar.views.toolbarVisualView = new Drupal.toolbar.ToolbarVisualView({ el: this, model: model, strings: options.strings }); Drupal.toolbar.views.toolbarAuralView = new Drupal.toolbar.ToolbarAuralView({ el: this, model: model, strings: options.strings }); Drupal.toolbar.views.bodyVisualView = new Drupal.toolbar.BodyVisualView({ el: this, model: model }); // Render collapsible menus. var menuModel = Drupal.toolbar.models.menuModel = new Drupal.toolbar.MenuModel(); Drupal.toolbar.views.menuVisualView = new Drupal.toolbar.MenuVisualView({ el: $(this).find('.toolbar-menu-administration').get(0), model: menuModel, strings: options.strings }); // Handle the resolution of Drupal.toolbar.setSubtrees. // This is handled with a deferred so that the function may be invoked // asynchronously. Drupal.toolbar.setSubtrees.done(function (subtrees) { menuModel.set('subtrees', subtrees); var theme = drupalSettings.ajaxPageState.theme; localStorage.setItem('Drupal.toolbar.subtrees.' + theme, JSON.stringify(subtrees)); // Indicate on the toolbarModel that subtrees are now loaded. model.set('areSubtreesLoaded', true); }); // Attach a listener to the configured media query breakpoints. for (var label in options.breakpoints) { if (options.breakpoints.hasOwnProperty(label)) { var mq = options.breakpoints[label]; var mql = Drupal.toolbar.mql[label] = window.matchMedia(mq); // Curry the model and the label of the media query breakpoint to // the mediaQueryChangeHandler function. mql.addListener(Drupal.toolbar.mediaQueryChangeHandler.bind(null, model, label)); // Fire the mediaQueryChangeHandler for each configured breakpoint // so that they process once. Drupal.toolbar.mediaQueryChangeHandler.call(null, model, label, mql); } } // Trigger an initial attempt to load menu subitems. This first attempt // is made after the media query handlers have had an opportunity to // process. The toolbar starts in the vertical orientation by default, // unless the viewport is wide enough to accommodate a horizontal // orientation. Thus we give the Toolbar a chance to determine if it // should be set to horizontal orientation before attempting to load // menu subtrees. Drupal.toolbar.views.toolbarVisualView.loadSubtrees(); $(document) // Update the model when the viewport offset changes. .on('drupalViewportOffsetChange.toolbar', function (event, offsets) { model.set('offsets', offsets); }); // Broadcast model changes to other modules. model .on('change:orientation', function (model, orientation) { $(document).trigger('drupalToolbarOrientationChange', orientation); }) .on('change:activeTab', function (model, tab) { $(document).trigger('drupalToolbarTabChange', tab); }) .on('change:activeTray', function (model, tray) { $(document).trigger('drupalToolbarTrayChange', tray); }); // If the toolbar's orientation is horizontal and no active tab is // defined then show the tray of the first toolbar tab by default (but // not the first 'Home' toolbar tab). if (Drupal.toolbar.models.toolbarModel.get('orientation') === 'horizontal' && Drupal.toolbar.models.toolbarModel.get('activeTab') === null) { Drupal.toolbar.models.toolbarModel.set({ activeTab: $('.toolbar-bar .toolbar-tab:not(.home-toolbar-tab) a').get(0) }); } }); } }; /** * Toolbar methods of Backbone objects. * * @namespace */ Drupal.toolbar = { /** * A hash of View instances. * * @type {object.<string, Backbone.View>} */ views: {}, /** * A hash of Model instances. * * @type {object.<string, Backbone.Model>} */ models: {}, /** * A hash of MediaQueryList objects tracked by the toolbar. * * @type {object.<string, object>} */ mql: {}, /** * Accepts a list of subtree menu elements. * * A deferred object that is resolved by an inlined JavaScript callback. * * @type {jQuery.Deferred} * * @see toolbar_subtrees_jsonp(). */ setSubtrees: new $.Deferred(), /** * Respond to configured narrow media query changes. * * @param {Drupal.toolbar.ToolbarModel} model * A toolbar model * @param {string} label * Media query label. * @param {object} mql * A MediaQueryList object. */ mediaQueryChangeHandler: function (model, label, mql) { switch (label) { case 'toolbar.narrow': model.set({ isOriented: mql.matches, isTrayToggleVisible: false }); // If the toolbar doesn't have an explicit orientation yet, or if the // narrow media query doesn't match then set the orientation to // vertical. if (!mql.matches || !model.get('orientation')) { model.set({orientation: 'vertical'}, {validate: true}); } break; case 'toolbar.standard': model.set({ isFixed: mql.matches }); break; case 'toolbar.wide': model.set({ orientation: ((mql.matches) ? 'horizontal' : 'vertical') }, {validate: true}); // The tray orientation toggle visibility does not need to be // validated. model.set({ isTrayToggleVisible: mql.matches }); break; default: break; } } }; /** * A toggle is an interactive element often bound to a click handler. * * @return {string} * A string representing a DOM fragment. */ Drupal.theme.toolbarOrientationToggle = function () { return '<div class="toolbar-toggle-orientation"><div class="toolbar-lining">' + '<button class="toolbar-icon" type="button"></button>' + '</div></div>'; }; /** * Ajax command to set the toolbar subtrees. * * @param {Drupal.Ajax} ajax * {@link Drupal.Ajax} object created by {@link Drupal.ajax}. * @param {object} response * JSON response from the Ajax request. * @param {number} [status] * XMLHttpRequest status. */ Drupal.AjaxCommands.prototype.setToolbarSubtrees = function (ajax, response, status) { Drupal.toolbar.setSubtrees.resolve(response.subtrees); }; }(jQuery, Drupal, drupalSettings)); ; /** * @file * A Backbone Model for collapsible menus. */ (function (Backbone, Drupal) { 'use strict'; /** * Backbone Model for collapsible menus. * * @constructor * * @augments Backbone.Model */ Drupal.toolbar.MenuModel = Backbone.Model.extend(/** @lends Drupal.toolbar.MenuModel# */{ /** * @type {object} * * @prop {object} subtrees */ defaults: /** @lends Drupal.toolbar.MenuModel# */{ /** * @type {object} */ subtrees: {} } }); }(Backbone, Drupal)); ; /** * @file * A Backbone Model for the toolbar. */ (function (Backbone, Drupal) { 'use strict'; /** * Backbone model for the toolbar. * * @constructor * * @augments Backbone.Model */ Drupal.toolbar.ToolbarModel = Backbone.Model.extend(/** @lends Drupal.toolbar.ToolbarModel# */{ /** * @type {object} * * @prop activeTab * @prop activeTray * @prop isOriented * @prop isFixed * @prop areSubtreesLoaded * @prop isViewportOverflowConstrained * @prop orientation * @prop locked * @prop isTrayToggleVisible * @prop height * @prop offsets */ defaults: /** @lends Drupal.toolbar.ToolbarModel# */{ /** * The active toolbar tab. All other tabs should be inactive under * normal circumstances. It will remain active across page loads. The * active item is stored as an ID selector e.g. '#toolbar-item--1'. * * @type {string} */ activeTab: null, /** * Represents whether a tray is open or not. Stored as an ID selector e.g. * '#toolbar-item--1-tray'. * * @type {string} */ activeTray: null, /** * Indicates whether the toolbar is displayed in an oriented fashion, * either horizontal or vertical. * * @type {bool} */ isOriented: false, /** * Indicates whether the toolbar is positioned absolute (false) or fixed * (true). * * @type {bool} */ isFixed: false, /** * Menu subtrees are loaded through an AJAX request only when the Toolbar * is set to a vertical orientation. * * @type {bool} */ areSubtreesLoaded: false, /** * If the viewport overflow becomes constrained, isFixed must be true so * that elements in the trays aren't lost off-screen and impossible to * get to. * * @type {bool} */ isViewportOverflowConstrained: false, /** * The orientation of the active tray. * * @type {string} */ orientation: 'vertical', /** * A tray is locked if a user toggled it to vertical. Otherwise a tray * will switch between vertical and horizontal orientation based on the * configured breakpoints. The locked state will be maintained across page * loads. * * @type {bool} */ locked: false, /** * Indicates whether the tray orientation toggle is visible. * * @type {bool} */ isTrayToggleVisible: false, /** * The height of the toolbar. * * @type {number} */ height: null, /** * The current viewport offsets determined by {@link Drupal.displace}. The * offsets suggest how a module might position is components relative to * the viewport. * * @type {object} * * @prop {number} top * @prop {number} right * @prop {number} bottom * @prop {number} left */ offsets: { top: 0, right: 0, bottom: 0, left: 0 } }, /** * @inheritdoc * * @param {object} attributes * Attributes for the toolbar. * @param {object} options * Options for the toolbar. * * @return {string|undefined} * Returns an error message if validation failed. */ validate: function (attributes, options) { // Prevent the orientation being set to horizontal if it is locked, unless // override has not been passed as an option. if (attributes.orientation === 'horizontal' && this.get('locked') && !options.override) { return Drupal.t('The toolbar cannot be set to a horizontal orientation when it is locked.'); } } }); }(Backbone, Drupal)); ; /** * @file * A Backbone view for the body element. */ (function ($, Drupal, Backbone) { 'use strict'; Drupal.toolbar.BodyVisualView = Backbone.View.extend(/** @lends Drupal.toolbar.BodyVisualView# */{ /** * Adjusts the body element with the toolbar position and dimension changes. * * @constructs * * @augments Backbone.View */ initialize: function () { this.listenTo(this.model, 'change:orientation change:offsets change:activeTray change:isOriented change:isFixed change:isViewportOverflowConstrained', this.render); }, /** * @inheritdoc */ render: function () { var $body = $('body'); var orientation = this.model.get('orientation'); var isOriented = this.model.get('isOriented'); var isViewportOverflowConstrained = this.model.get('isViewportOverflowConstrained'); $body // We are using JavaScript to control media-query handling for two // reasons: (1) Using JavaScript let's us leverage the breakpoint // configurations and (2) the CSS is really complex if we try to hide // some styling from browsers that don't understand CSS media queries. // If we drive the CSS from classes added through JavaScript, // then the CSS becomes simpler and more robust. .toggleClass('toolbar-vertical', (orientation === 'vertical')) .toggleClass('toolbar-horizontal', (isOriented && orientation === 'horizontal')) // When the toolbar is fixed, it will not scroll with page scrolling. .toggleClass('toolbar-fixed', (isViewportOverflowConstrained || this.model.get('isFixed'))) // Toggle the toolbar-tray-open class on the body element. The class is // applied when a toolbar tray is active. Padding might be applied to // the body element to prevent the tray from overlapping content. .toggleClass('toolbar-tray-open', !!this.model.get('activeTray')) // Apply padding to the top of the body to offset the placement of the // toolbar bar element. .css('padding-top', this.model.get('offsets').top); } }); }(jQuery, Drupal, Backbone)); ; /** * @file * A Backbone view for the collapsible menus. */ (function ($, Backbone, Drupal) { 'use strict'; Drupal.toolbar.MenuVisualView = Backbone.View.extend(/** @lends Drupal.toolbar.MenuVisualView# */{ /** * Backbone View for collapsible menus. * * @constructs * * @augments Backbone.View */ initialize: function () { this.listenTo(this.model, 'change:subtrees', this.render); }, /** * @inheritdoc */ render: function () { var subtrees = this.model.get('subtrees'); // Add subtrees. for (var id in subtrees) { if (subtrees.hasOwnProperty(id)) { this.$el .find('#toolbar-link-' + id) .once('toolbar-subtrees') .after(subtrees[id]); } } // Render the main menu as a nested, collapsible accordion. if ('drupalToolbarMenu' in $.fn) { this.$el .children('.toolbar-menu') .drupalToolbarMenu(); } } }); }(jQuery, Backbone, Drupal)); ; /** * @file * A Backbone view for the aural feedback of the toolbar. */ (function (Backbone, Drupal) { 'use strict'; Drupal.toolbar.ToolbarAuralView = Backbone.View.extend(/** @lends Drupal.toolbar.ToolbarAuralView# */{ /** * Backbone view for the aural feedback of the toolbar. * * @constructs * * @augments Backbone.View * * @param {object} options * Options for the view. * @param {object} options.strings * Various strings to use in the view. */ initialize: function (options) { this.strings = options.strings; this.listenTo(this.model, 'change:orientation', this.onOrientationChange); this.listenTo(this.model, 'change:activeTray', this.onActiveTrayChange); }, /** * Announces an orientation change. * * @param {Drupal.toolbar.ToolbarModel} model * The toolbar model in question. * @param {string} orientation * The new value of the orientation attribute in the model. */ onOrientationChange: function (model, orientation) { Drupal.announce(Drupal.t('Tray orientation changed to @orientation.', { '@orientation': orientation })); }, /** * Announces a changed active tray. * * @param {Drupal.toolbar.ToolbarModel} model * The toolbar model in question. * @param {HTMLElement} tray * The new value of the tray attribute in the model. */ onActiveTrayChange: function (model, tray) { var relevantTray = (tray === null) ? model.previous('activeTray') : tray; var action = (tray === null) ? Drupal.t('closed') : Drupal.t('opened'); var trayNameElement = relevantTray.querySelector('.toolbar-tray-name'); var text; if (trayNameElement !== null) { text = Drupal.t('Tray "@tray" @action.', { '@tray': trayNameElement.textContent, '@action': action }); } else { text = Drupal.t('Tray @action.', {'@action': action}); } Drupal.announce(text); } }); }(Backbone, Drupal)); ; /** * @file * A Backbone view for the toolbar element. Listens to mouse & touch. */ (function ($, Drupal, drupalSettings, Backbone) { 'use strict'; Drupal.toolbar.ToolbarVisualView = Backbone.View.extend(/** @lends Drupal.toolbar.ToolbarVisualView# */{ /** * Event map for the `ToolbarVisualView`. * * @return {object} * A map of events. */ events: function () { // Prevents delay and simulated mouse events. var touchEndToClick = function (event) { event.preventDefault(); event.target.click(); }; return { 'click .toolbar-bar .toolbar-tab .trigger': 'onTabClick', 'click .toolbar-toggle-orientation button': 'onOrientationToggleClick', 'touchend .toolbar-bar .toolbar-tab .trigger': touchEndToClick, 'touchend .toolbar-toggle-orientation button': touchEndToClick }; }, /** * Backbone view for the toolbar element. Listens to mouse & touch. * * @constructs * * @augments Backbone.View * * @param {object} options * Options for the view object. * @param {object} options.strings * Various strings to use in the view. */ initialize: function (options) { this.strings = options.strings; this.listenTo(this.model, 'change:activeTab change:orientation change:isOriented change:isTrayToggleVisible', this.render); this.listenTo(this.model, 'change:mqMatches', this.onMediaQueryChange); this.listenTo(this.model, 'change:offsets', this.adjustPlacement); // Add the tray orientation toggles. this.$el .find('.toolbar-tray .toolbar-lining') .append(Drupal.theme('toolbarOrientationToggle')); // Trigger an activeTab change so that listening scripts can respond on // page load. This will call render. this.model.trigger('change:activeTab'); }, /** * @inheritdoc * * @return {Drupal.toolbar.ToolbarVisualView} * The `ToolbarVisualView` instance. */ render: function () { this.updateTabs(); this.updateTrayOrientation(); this.updateBarAttributes(); // Load the subtrees if the orientation of the toolbar is changed to // vertical. This condition responds to the case that the toolbar switches // from horizontal to vertical orientation. The toolbar starts in a // vertical orientation by default and then switches to horizontal during // initialization if the media query conditions are met. Simply checking // that the orientation is vertical here would result in the subtrees // always being loaded, even when the toolbar initialization ultimately // results in a horizontal orientation. // // @see Drupal.behaviors.toolbar.attach() where admin menu subtrees // loading is invoked during initialization after media query conditions // have been processed. if (this.model.changed.orientation === 'vertical' || this.model.changed.activeTab) { this.loadSubtrees(); } // Trigger a recalculation of viewport displacing elements. Use setTimeout // to ensure this recalculation happens after changes to visual elements // have processed. window.setTimeout(function () { Drupal.displace(true); }, 0); return this; }, /** * Responds to a toolbar tab click. * * @param {jQuery.Event} event * The event triggered. */ onTabClick: function (event) { // If this tab has a tray associated with it, it is considered an // activatable tab. if (event.target.hasAttribute('data-toolbar-tray')) { var activeTab = this.model.get('activeTab'); var clickedTab = event.target; // Set the event target as the active item if it is not already. this.model.set('activeTab', (!activeTab || clickedTab !== activeTab) ? clickedTab : null); event.preventDefault(); event.stopPropagation(); } }, /** * Toggles the orientation of a toolbar tray. * * @param {jQuery.Event} event * The event triggered. */ onOrientationToggleClick: function (event) { var orientation = this.model.get('orientation'); // Determine the toggle-to orientation. var antiOrientation = (orientation === 'vertical') ? 'horizontal' : 'vertical'; var locked = antiOrientation === 'vertical'; // Remember the locked state. if (locked) { localStorage.setItem('Drupal.toolbar.trayVerticalLocked', 'true'); } else { localStorage.removeItem('Drupal.toolbar.trayVerticalLocked'); } // Update the model. this.model.set({ locked: locked, orientation: antiOrientation }, { validate: true, override: true }); event.preventDefault(); event.stopPropagation(); }, /** * Updates the display of the tabs: toggles a tab and the associated tray. */ updateTabs: function () { var $tab = $(this.model.get('activeTab')); // Deactivate the previous tab. $(this.model.previous('activeTab')) .removeClass('is-active') .prop('aria-pressed', false); // Deactivate the previous tray. $(this.model.previous('activeTray')) .removeClass('is-active'); // Activate the selected tab. if ($tab.length > 0) { $tab .addClass('is-active') // Mark the tab as pressed. .prop('aria-pressed', true); var name = $tab.attr('data-toolbar-tray'); // Store the active tab name or remove the setting. var id = $tab.get(0).id; if (id) { localStorage.setItem('Drupal.toolbar.activeTabID', JSON.stringify(id)); } // Activate the associated tray. var $tray = this.$el.find('[data-toolbar-tray="' + name + '"].toolbar-tray'); if ($tray.length) { $tray.addClass('is-active'); this.model.set('activeTray', $tray.get(0)); } else { // There is no active tray. this.model.set('activeTray', null); } } else { // There is no active tray. this.model.set('activeTray', null); localStorage.removeItem('Drupal.toolbar.activeTabID'); } }, /** * Update the attributes of the toolbar bar element. */ updateBarAttributes: function () { var isOriented = this.model.get('isOriented'); if (isOriented) { this.$el.find('.toolbar-bar').attr('data-offset-top', ''); } else { this.$el.find('.toolbar-bar').removeAttr('data-offset-top'); } // Toggle between a basic vertical view and a more sophisticated // horizontal and vertical display of the toolbar bar and trays. this.$el.toggleClass('toolbar-oriented', isOriented); }, /** * Updates the orientation of the active tray if necessary. */ updateTrayOrientation: function () { var orientation = this.model.get('orientation'); // The antiOrientation is used to render the view of action buttons like // the tray orientation toggle. var antiOrientation = (orientation === 'vertical') ? 'horizontal' : 'vertical'; // Update the orientation of the trays. var $trays = this.$el.find('.toolbar-tray') .removeClass('toolbar-tray-horizontal toolbar-tray-vertical') .addClass('toolbar-tray-' + orientation); // Update the tray orientation toggle button. var iconClass = 'toolbar-icon-toggle-' + orientation; var iconAntiClass = 'toolbar-icon-toggle-' + antiOrientation; var $orientationToggle = this.$el.find('.toolbar-toggle-orientation') .toggle(this.model.get('isTrayToggleVisible')); $orientationToggle.find('button') .val(antiOrientation) .attr('title', this.strings[antiOrientation]) .text(this.strings[antiOrientation]) .removeClass(iconClass) .addClass(iconAntiClass); // Update data offset attributes for the trays. var dir = document.documentElement.dir; var edge = (dir === 'rtl') ? 'right' : 'left'; // Remove data-offset attributes from the trays so they can be refreshed. $trays.removeAttr('data-offset-left data-offset-right data-offset-top'); // If an active vertical tray exists, mark it as an offset element. $trays.filter('.toolbar-tray-vertical.is-active').attr('data-offset-' + edge, ''); // If an active horizontal tray exists, mark it as an offset element. $trays.filter('.toolbar-tray-horizontal.is-active').attr('data-offset-top', ''); }, /** * Sets the tops of the trays so that they align with the bottom of the bar. */ adjustPlacement: function () { var $trays = this.$el.find('.toolbar-tray'); if (!this.model.get('isOriented')) { $trays.css('margin-top', 0); $trays.removeClass('toolbar-tray-horizontal').addClass('toolbar-tray-vertical'); } else { // The toolbar container is invisible. Its placement is used to // determine the container for the trays. $trays.css('margin-top', this.$el.find('.toolbar-bar').outerHeight()); } }, /** * Calls the endpoint URI that builds an AJAX command with the rendered * subtrees. * * The rendered admin menu subtrees HTML is cached on the client in * localStorage until the cache of the admin menu subtrees on the server- * side is invalidated. The subtreesHash is stored in localStorage as well * and compared to the subtreesHash in drupalSettings to determine when the * admin menu subtrees cache has been invalidated. */ loadSubtrees: function () { var $activeTab = $(this.model.get('activeTab')); var orientation = this.model.get('orientation'); // Only load and render the admin menu subtrees if: // (1) They have not been loaded yet. // (2) The active tab is the administration menu tab, indicated by the // presence of the data-drupal-subtrees attribute. // (3) The orientation of the tray is vertical. if (!this.model.get('areSubtreesLoaded') && typeof $activeTab.data('drupal-subtrees') !== 'undefined' && orientation === 'vertical') { var subtreesHash = drupalSettings.toolbar.subtreesHash; var theme = drupalSettings.ajaxPageState.theme; var endpoint = Drupal.url('toolbar/subtrees/' + subtreesHash); var cachedSubtreesHash = localStorage.getItem('Drupal.toolbar.subtreesHash.' + theme); var cachedSubtrees = JSON.parse(localStorage.getItem('Drupal.toolbar.subtrees.' + theme)); var isVertical = this.model.get('orientation') === 'vertical'; // If we have the subtrees in localStorage and the subtree hash has not // changed, then use the cached data. if (isVertical && subtreesHash === cachedSubtreesHash && cachedSubtrees) { Drupal.toolbar.setSubtrees.resolve(cachedSubtrees); } // Only make the call to get the subtrees if the orientation of the // toolbar is vertical. else if (isVertical) { // Remove the cached menu information. localStorage.removeItem('Drupal.toolbar.subtreesHash.' + theme); localStorage.removeItem('Drupal.toolbar.subtrees.' + theme); // The AJAX response's command will trigger the resolve method of the // Drupal.toolbar.setSubtrees Promise. Drupal.ajax({url: endpoint}).execute(); // Cache the hash for the subtrees locally. localStorage.setItem('Drupal.toolbar.subtreesHash.' + theme, subtreesHash); } } } }); }(jQuery, Drupal, drupalSettings, Backbone)); ; /* jQuery Foundation Joyride Plugin 2.1 | Copyright 2012, ZURB | www.opensource.org/licenses/mit-license.php */ (function(e,t,n){"use strict";var r={version:"2.0.3",tipLocation:"bottom",nubPosition:"auto",scroll:!0,scrollSpeed:300,timer:0,autoStart:!1,startTimerOnClick:!0,startOffset:0,nextButton:!0,tipAnimation:"fade",pauseAfter:[],tipAnimationFadeSpeed:300,cookieMonster:!1,cookieName:"joyride",cookieDomain:!1,cookiePath:!1,localStorage:!1,localStorageKey:"joyride",tipContainer:"body",modal:!1,expose:!1,postExposeCallback:e.noop,preRideCallback:e.noop,postRideCallback:e.noop,preStepCallback:e.noop,postStepCallback:e.noop,template:{link:'<a href="#close" class="joyride-close-tip">X</a>',timer:'<div class="joyride-timer-indicator-wrap"><span class="joyride-timer-indicator"></span></div>',tip:'<div class="joyride-tip-guide"><span class="joyride-nub"></span></div>',wrapper:'<div class="joyride-content-wrapper" role="dialog"></div>',button:'<a href="#" class="joyride-next-tip"></a>',modal:'<div class="joyride-modal-bg"></div>',expose:'<div class="joyride-expose-wrapper"></div>',exposeCover:'<div class="joyride-expose-cover"></div>'}},i=i||!1,s={},o={init:function(n){return this.each(function(){e.isEmptyObject(s)?(s=e.extend(!0,r,n),s.document=t.document,s.$document=e(s.document),s.$window=e(t),s.$content_el=e(this),s.$body=e(s.tipContainer),s.body_offset=e(s.tipContainer).position(),s.$tip_content=e("> li",s.$content_el),s.paused=!1,s.attempts=0,s.tipLocationPatterns={top:["bottom"],bottom:[],left:["right","top","bottom"],right:["left","top","bottom"]},o.jquery_check(),e.isFunction(e.cookie)||(s.cookieMonster=!1),(!s.cookieMonster||!e.cookie(s.cookieName))&&(!s.localStorage||!o.support_localstorage()||!localStorage.getItem(s.localStorageKey))&&(s.$tip_content.each(function(t){o.create({$li:e(this),index:t})}),s.autoStart&&(!s.startTimerOnClick&&s.timer>0?(o.show("init"),o.startTimer()):o.show("init"))),s.$document.on("click.joyride",".joyride-next-tip, .joyride-modal-bg",function(e){e.preventDefault(),s.$li.next().length<1?o.end():s.timer>0?(clearTimeout(s.automate),o.hide(),o.show(),o.startTimer()):(o.hide(),o.show())}),s.$document.on("click.joyride",".joyride-close-tip",function(e){e.preventDefault(),o.end()}),s.$window.bind("resize.joyride",function(t){if(s.$li){if(s.exposed&&s.exposed.length>0){var n=e(s.exposed);n.each(function(){var t=e(this);o.un_expose(t),o.expose(t)})}o.is_phone()?o.pos_phone():o.pos_default()}})):o.restart()})},resume:function(){o.set_li(),o.show()},nextTip:function(){s.$li.next().length<1?o.end():s.timer>0?(clearTimeout(s.automate),o.hide(),o.show(),o.startTimer()):(o.hide(),o.show())},tip_template:function(t){var n,r,i;return t.tip_class=t.tip_class||"",n=e(s.template.tip).addClass(t.tip_class),r=e.trim(e(t.li).html())+o.button_text(t.button_text)+s.template.link+o.timer_instance(t.index),i=e(s.template.wrapper),t.li.attr("data-aria-labelledby")&&i.attr("aria-labelledby",t.li.attr("data-aria-labelledby")),t.li.attr("data-aria-describedby")&&i.attr("aria-describedby",t.li.attr("data-aria-describedby")),n.append(i),n.first().attr("data-index",t.index),e(".joyride-content-wrapper",n).append(r),n[0]},timer_instance:function(t){var n;return t===0&&s.startTimerOnClick&&s.timer>0||s.timer===0?n="":n=o.outerHTML(e(s.template.timer)[0]),n},button_text:function(t){return s.nextButton?(t=e.trim(t)||"Next",t=o.outerHTML(e(s.template.button).append(t)[0])):t="",t},create:function(t){var n=t.$li.attr("data-button")||t.$li.attr("data-text"),r=t.$li.attr("class"),i=e(o.tip_template({tip_class:r,index:t.index,button_text:n,li:t.$li}));e(s.tipContainer).append(i)},show:function(t){var r={},i,u=[],a=0,f,l=null;if(s.$li===n||e.inArray(s.$li.index(),s.pauseAfter)===-1){s.paused?s.paused=!1:o.set_li(t),s.attempts=0;if(s.$li.length&&s.$target.length>0){t&&(s.preRideCallback(s.$li.index(),s.$next_tip),s.modal&&o.show_modal()),s.preStepCallback(s.$li.index(),s.$next_tip),u=(s.$li.data("options")||":").split(";"),a=u.length;for(i=a-1;i>=0;i--)f=u[i].split(":"),f.length===2&&(r[e.trim(f[0])]=e.trim(f[1]));s.tipSettings=e.extend({},s,r),s.tipSettings.tipLocationPattern=s.tipLocationPatterns[s.tipSettings.tipLocation],s.modal&&s.expose&&o.expose(),!/body/i.test(s.$target.selector)&&s.scroll&&o.scroll_to(),o.is_phone()?o.pos_phone(!0):o.pos_default(!0),l=e(".joyride-timer-indicator",s.$next_tip),/pop/i.test(s.tipAnimation)?(l.outerWidth(0),s.timer>0?(s.$next_tip.show(),l.animate({width:e(".joyride-timer-indicator-wrap",s.$next_tip).outerWidth()},s.timer)):s.$next_tip.show()):/fade/i.test(s.tipAnimation)&&(l.outerWidth(0),s.timer>0?(s.$next_tip.fadeIn(s.tipAnimationFadeSpeed),s.$next_tip.show(),l.animate({width:e(".joyride-timer-indicator-wrap",s.$next_tip).outerWidth()},s.timer)):s.$next_tip.fadeIn(s.tipAnimationFadeSpeed)),s.$current_tip=s.$next_tip,e(".joyride-next-tip",s.$current_tip).focus(),o.tabbable(s.$current_tip)}else s.$li&&s.$target.length<1?o.show():o.end()}else s.paused=!0},is_phone:function(){return i?i.mq("only screen and (max-width: 767px)"):s.$window.width()<767?!0:!1},support_localstorage:function(){return i?i.localstorage:!!t.localStorage},hide:function(){s.modal&&s.expose&&o.un_expose(),s.modal||e(".joyride-modal-bg").hide(),s.$current_tip.hide(),s.postStepCallback(s.$li.index(),s.$current_tip)},set_li:function(e){e?(s.$li=s.$tip_content.eq(s.startOffset),o.set_next_tip(),s.$current_tip=s.$next_tip):(s.$li=s.$li.next(),o.set_next_tip()),o.set_target()},set_next_tip:function(){s.$next_tip=e(".joyride-tip-guide[data-index="+s.$li.index()+"]")},set_target:function(){var t=s.$li.attr("data-class"),n=s.$li.attr("data-id"),r=function(){return n?e(s.document.getElementById(n)):t?e("."+t).filter(":visible").first():e("body")};s.$target=r()},scroll_to:function(){var t,n;t=s.$window.height()/2,n=Math.ceil(s.$target.offset().top-t+s.$next_tip.outerHeight()),e("html, body").stop().animate({scrollTop:n},s.scrollSpeed)},paused:function(){return e.inArray(s.$li.index()+1,s.pauseAfter)===-1?!0:!1},destroy:function(){e.isEmptyObject(s)||s.$document.off(".joyride"),e(t).off(".joyride"),e(".joyride-close-tip, .joyride-next-tip, .joyride-modal-bg").off(".joyride"),e(".joyride-tip-guide, .joyride-modal-bg").remove(),clearTimeout(s.automate),s={}},restart:function(){s.autoStart?(o.hide(),s.$li=n,o.show("init")):(!s.startTimerOnClick&&s.timer>0?(o.show("init"),o.startTimer()):o.show("init"),s.autoStart=!0)},pos_default:function(t){var n=Math.ceil(s.$window.height()/2),r=s.$next_tip.offset(),i=e(".joyride-nub",s.$next_tip),u=Math.ceil(i.outerWidth()/2),a=Math.ceil(i.outerHeight()/2),f=t||!1;f&&(s.$next_tip.css("visibility","hidden"),s.$next_tip.show());if(!/body/i.test(s.$target.selector)){var l=s.tipSettings.tipAdjustmentY?parseInt(s.tipSettings.tipAdjustmentY):0,c=s.tipSettings.tipAdjustmentX?parseInt(s.tipSettings.tipAdjustmentX):0;o.bottom()?(s.$next_tip.css({top:s.$target.offset().top+a+s.$target.outerHeight()+l,left:s.$target.offset().left+c}),/right/i.test(s.tipSettings.nubPosition)&&s.$next_tip.css("left",s.$target.offset().left-s.$next_tip.outerWidth()+s.$target.outerWidth()),o.nub_position(i,s.tipSettings.nubPosition,"top")):o.top()?(s.$next_tip.css({top:s.$target.offset().top-s.$next_tip.outerHeight()-a+l,left:s.$target.offset().left+c}),o.nub_position(i,s.tipSettings.nubPosition,"bottom")):o.right()?(s.$next_tip.css({top:s.$target.offset().top+l,left:s.$target.outerWidth()+s.$target.offset().left+u+c}),o.nub_position(i,s.tipSettings.nubPosition,"left")):o.left()&&(s.$next_tip.css({top:s.$target.offset().top+l,left:s.$target.offset().left-s.$next_tip.outerWidth()-u+c}),o.nub_position(i,s.tipSettings.nubPosition,"right")),!o.visible(o.corners(s.$next_tip))&&s.attempts<s.tipSettings.tipLocationPattern.length&&(i.removeClass("bottom").removeClass("top").removeClass("right").removeClass("left"),s.tipSettings.tipLocation=s.tipSettings.tipLocationPattern[s.attempts],s.attempts++,o.pos_default(!0))}else s.$li.length&&o.pos_modal(i);f&&(s.$next_tip.hide(),s.$next_tip.css("visibility","visible"))},pos_phone:function(t){var n=s.$next_tip.outerHeight(),r=s.$next_tip.offset(),i=s.$target.outerHeight(),u=e(".joyride-nub",s.$next_tip),a=Math.ceil(u.outerHeight()/2),f=t||!1;u.removeClass("bottom").removeClass("top").removeClass("right").removeClass("left"),f&&(s.$next_tip.css("visibility","hidden"),s.$next_tip.show()),/body/i.test(s.$target.selector)?s.$li.length&&o.pos_modal(u):o.top()?(s.$next_tip.offset({top:s.$target.offset().top-n-a}),u.addClass("bottom")):(s.$next_tip.offset({top:s.$target.offset().top+i+a}),u.addClass("top")),f&&(s.$next_tip.hide(),s.$next_tip.css("visibility","visible"))},pos_modal:function(e){o.center(),e.hide(),o.show_modal()},show_modal:function(){e(".joyride-modal-bg").length<1&&e("body").append(s.template.modal).show(),/pop/i.test(s.tipAnimation)?e(".joyride-modal-bg").show():e(".joyride-modal-bg").fadeIn(s.tipAnimationFadeSpeed)},expose:function(){var n,r,i,u,a="expose-"+Math.floor(Math.random()*1e4);if(arguments.length>0&&arguments[0]instanceof e)i=arguments[0];else{if(!s.$target||!!/body/i.test(s.$target.selector))return!1;i=s.$target}if(i.length<1)return t.console&&console.error("element not valid",i),!1;n=e(s.template.expose),s.$body.append(n),n.css({top:i.offset().top,left:i.offset().left,width:i.outerWidth(!0),height:i.outerHeight(!0)}),r=e(s.template.exposeCover),u={zIndex:i.css("z-index"),position:i.css("position")},i.css("z-index",n.css("z-index")*1+1),u.position=="static"&&i.css("position","relative"),i.data("expose-css",u),r.css({top:i.offset().top,left:i.offset().left,width:i.outerWidth(!0),height:i.outerHeight(!0)}),s.$body.append(r),n.addClass(a),r.addClass(a),s.tipSettings.exposeClass&&(n.addClass(s.tipSettings.exposeClass),r.addClass(s.tipSettings.exposeClass)),i.data("expose",a),s.postExposeCallback(s.$li.index(),s.$next_tip,i),o.add_exposed(i)},un_expose:function(){var n,r,i,u,a=!1;if(arguments.length>0&&arguments[0]instanceof e)r=arguments[0];else{if(!s.$target||!!/body/i.test(s.$target.selector))return!1;r=s.$target}if(r.length<1)return t.console&&console.error("element not valid",r),!1;n=r.data("expose"),i=e("."+n),arguments.length>1&&(a=arguments[1]),a===!0?e(".joyride-expose-wrapper,.joyride-expose-cover").remove():i.remove(),u=r.data("expose-css"),u.zIndex=="auto"?r.css("z-index",""):r.css("z-index",u.zIndex),u.position!=r.css("position")&&(u.position=="static"?r.css("position",""):r.css("position",u.position)),r.removeData("expose"),r.removeData("expose-z-index"),o.remove_exposed(r)},add_exposed:function(t){s.exposed=s.exposed||[],t instanceof e?s.exposed.push(t[0]):typeof t=="string"&&s.exposed.push(t)},remove_exposed:function(t){var n;t instanceof e?n=t[0]:typeof t=="string"&&(n=t),s.exposed=s.exposed||[];for(var r=0;r<s.exposed.length;r++)if(s.exposed[r]==n){s.exposed.splice(r,1);return}},center:function(){var e=s.$window;return s.$next_tip.css({top:(e.height()-s.$next_tip.outerHeight())/2+e.scrollTop(),left:(e.width()-s.$next_tip.outerWidth())/2+e.scrollLeft()}),!0},bottom:function(){return/bottom/i.test(s.tipSettings.tipLocation)},top:function(){return/top/i.test(s.tipSettings.tipLocation)},right:function(){return/right/i.test(s.tipSettings.tipLocation)},left:function(){return/left/i.test(s.tipSettings.tipLocation)},corners:function(e){var t=s.$window,n=t.height()/2,r=Math.ceil(s.$target.offset().top-n+s.$next_tip.outerHeight()),i=t.width()+t.scrollLeft(),o=t.height()+r,u=t.height()+t.scrollTop(),a=t.scrollTop();return r<a&&(r<0?a=0:a=r),o>u&&(u=o),[e.offset().top<a,i<e.offset().left+e.outerWidth(),u<e.offset().top+e.outerHeight(),t.scrollLeft()>e.offset().left]},visible:function(e){var t=e.length;while(t--)if(e[t])return!1;return!0},nub_position:function(e,t,n){t==="auto"?e.addClass(n):e.addClass(t)},startTimer:function(){s.$li.length?s.automate=setTimeout(function(){o.hide(),o.show(),o.startTimer()},s.timer):clearTimeout(s.automate)},end:function(){s.cookieMonster&&e.cookie(s.cookieName,"ridden",{expires:365,domain:s.cookieDomain,path:s.cookiePath}),s.localStorage&&localStorage.setItem(s.localStorageKey,!0),s.timer>0&&clearTimeout(s.automate),s.modal&&s.expose&&o.un_expose(),s.$current_tip&&s.$current_tip.hide(),s.$li&&(s.postStepCallback(s.$li.index(),s.$current_tip),s.postRideCallback(s.$li.index(),s.$current_tip)),e(".joyride-modal-bg").hide()},jquery_check:function(){return e.isFunction(e.fn.on)?!0:(e.fn.on=function(e,t,n){return this.delegate(t,e,n)},e.fn.off=function(e,t,n){return this.undelegate(t,e,n)},!1)},outerHTML:function(e){return e.outerHTML||(new XMLSerializer).serializeToString(e)},version:function(){return s.version},tabbable:function(t){e(t).on("keydown",function(n){if(!n.isDefaultPrevented()&&n.keyCode&&n.keyCode===27){n.preventDefault(),o.end();return}if(n.keyCode!==9)return;var r=e(t).find(":tabbable"),i=r.filter(":first"),s=r.filter(":last");n.target===s[0]&&!n.shiftKey?(i.focus(1),n.preventDefault()):n.target===i[0]&&n.shiftKey&&(s.focus(1),n.preventDefault())})}};e.fn.joyride=function(t){if(o[t])return o[t].apply(this,Array.prototype.slice.call(arguments,1));if(typeof t=="object"||!t)return o.init.apply(this,arguments);e.error("Method "+t+" does not exist on jQuery.joyride")}})(jQuery,this); ; /** * @file * Attaches behaviors for the Tour module's toolbar tab. */ (function ($, Backbone, Drupal, document) { 'use strict'; var queryString = decodeURI(window.location.search); /** * Attaches the tour's toolbar tab behavior. * * It uses the query string for: * - tour: When ?tour=1 is present, the tour will start automatically after * the page has loaded. * - tips: Pass ?tips=class in the url to filter the available tips to the * subset which match the given class. * * @example * http://example.com/foo?tour=1&tips=bar * * @type {Drupal~behavior} * * @prop {Drupal~behaviorAttach} attach * Attach tour functionality on `tour` events. */ Drupal.behaviors.tour = { attach: function (context) { $('body').once('tour').each(function () { var model = new Drupal.tour.models.StateModel(); new Drupal.tour.views.ToggleTourView({ el: $(context).find('#toolbar-tab-tour'), model: model }); model // Allow other scripts to respond to tour events. .on('change:isActive', function (model, isActive) { $(document).trigger((isActive) ? 'drupalTourStarted' : 'drupalTourStopped'); }) // Initialization: check whether a tour is available on the current // page. .set('tour', $(context).find('ol#tour')); // Start the tour immediately if toggled via query string. if (/tour=?/i.test(queryString)) { model.set('isActive', true); } }); } }; /** * @namespace */ Drupal.tour = Drupal.tour || { /** * @namespace Drupal.tour.models */ models: {}, /** * @namespace Drupal.tour.views */ views: {} }; /** * Backbone Model for tours. * * @constructor * * @augments Backbone.Model */ Drupal.tour.models.StateModel = Backbone.Model.extend(/** @lends Drupal.tour.models.StateModel# */{ /** * @type {object} */ defaults: /** @lends Drupal.tour.models.StateModel# */{ /** * Indicates whether the Drupal root window has a tour. * * @type {Array} */ tour: [], /** * Indicates whether the tour is currently running. * * @type {bool} */ isActive: false, /** * Indicates which tour is the active one (necessary to cleanly stop). * * @type {Array} */ activeTour: [] } }); Drupal.tour.views.ToggleTourView = Backbone.View.extend(/** @lends Drupal.tour.views.ToggleTourView# */{ /** * @type {object} */ events: {click: 'onClick'}, /** * Handles edit mode toggle interactions. * * @constructs * * @augments Backbone.View */ initialize: function () { this.listenTo(this.model, 'change:tour change:isActive', this.render); this.listenTo(this.model, 'change:isActive', this.toggleTour); }, /** * @inheritdoc * * @return {Drupal.tour.views.ToggleTourView} * The `ToggleTourView` view. */ render: function () { // Render the visibility. this.$el.toggleClass('hidden', this._getTour().length === 0); // Render the state. var isActive = this.model.get('isActive'); this.$el.find('button') .toggleClass('is-active', isActive) .prop('aria-pressed', isActive); return this; }, /** * Model change handler; starts or stops the tour. */ toggleTour: function () { if (this.model.get('isActive')) { var $tour = this._getTour(); this._removeIrrelevantTourItems($tour, this._getDocument()); var that = this; if ($tour.find('li').length) { $tour.joyride({ autoStart: true, postRideCallback: function () { that.model.set('isActive', false); }, // HTML segments for tip layout. template: { link: '<a href=\"#close\" class=\"joyride-close-tip\">&times;</a>', button: '<a href=\"#\" class=\"button button--primary joyride-next-tip\"></a>' } }); this.model.set({isActive: true, activeTour: $tour}); } } else { this.model.get('activeTour').joyride('destroy'); this.model.set({isActive: false, activeTour: []}); } }, /** * Toolbar tab click event handler; toggles isActive. * * @param {jQuery.Event} event * The click event. */ onClick: function (event) { this.model.set('isActive', !this.model.get('isActive')); event.preventDefault(); event.stopPropagation(); }, /** * Gets the tour. * * @return {jQuery} * A jQuery element pointing to a `<ol>` containing tour items. */ _getTour: function () { return this.model.get('tour'); }, /** * Gets the relevant document as a jQuery element. * * @return {jQuery} * A jQuery element pointing to the document within which a tour would be * started given the current state. */ _getDocument: function () { return $(document); }, /** * Removes tour items for elements that don't have matching page elements. * * Or that are explicitly filtered out via the 'tips' query string. * * @example * <caption>This will filter out tips that do not have a matching * page element or don't have the "bar" class.</caption> * http://example.com/foo?tips=bar * * @param {jQuery} $tour * A jQuery element pointing to a `<ol>` containing tour items. * @param {jQuery} $document * A jQuery element pointing to the document within which the elements * should be sought. * * @see Drupal.tour.views.ToggleTourView#_getDocument */ _removeIrrelevantTourItems: function ($tour, $document) { var removals = false; var tips = /tips=([^&]+)/.exec(queryString); $tour .find('li') .each(function () { var $this = $(this); var itemId = $this.attr('data-id'); var itemClass = $this.attr('data-class'); // If the query parameter 'tips' is set, remove all tips that don't // have the matching class. if (tips && !$(this).hasClass(tips[1])) { removals = true; $this.remove(); return; } // Remove tip from the DOM if there is no corresponding page element. if ((!itemId && !itemClass) || (itemId && $document.find('#' + itemId).length) || (itemClass && $document.find('.' + itemClass).length)) { return; } removals = true; $this.remove(); }); // If there were removals, we'll have to do some clean-up. if (removals) { var total = $tour.find('li').length; if (!total) { this.model.set({tour: []}); } $tour .find('li') // Rebuild the progress data. .each(function (index) { var progress = Drupal.t('!tour_item of !total', {'!tour_item': index + 1, '!total': total}); $(this).find('.tour-progress').text(progress); }) // Update the last item to have "End tour" as the button. .eq(-1) .attr('data-text', Drupal.t('End tour')); } } }); })(jQuery, Backbone, Drupal, document); ; /** * @file * Manages page tabbing modifications made by modules. */ /** * Allow modules to respond to the constrain event. * * @event drupalTabbingConstrained */ /** * Allow modules to respond to the tabbingContext release event. * * @event drupalTabbingContextReleased */ /** * Allow modules to respond to the constrain event. * * @event drupalTabbingContextActivated */ /** * Allow modules to respond to the constrain event. * * @event drupalTabbingContextDeactivated */ (function ($, Drupal) { 'use strict'; /** * Provides an API for managing page tabbing order modifications. * * @constructor Drupal~TabbingManager */ function TabbingManager() { /** * Tabbing sets are stored as a stack. The active set is at the top of the * stack. We use a JavaScript array as if it were a stack; we consider the * first element to be the bottom and the last element to be the top. This * allows us to use JavaScript's built-in Array.push() and Array.pop() * methods. * * @type {Array.<Drupal~TabbingContext>} */ this.stack = []; } /** * Add public methods to the TabbingManager class. */ $.extend(TabbingManager.prototype, /** @lends Drupal~TabbingManager# */{ /** * Constrain tabbing to the specified set of elements only. * * Makes elements outside of the specified set of elements unreachable via * the tab key. * * @param {jQuery} elements * The set of elements to which tabbing should be constrained. Can also * be a jQuery-compatible selector string. * * @return {Drupal~TabbingContext} * The TabbingContext instance. * * @fires event:drupalTabbingConstrained */ constrain: function (elements) { // Deactivate all tabbingContexts to prepare for the new constraint. A // tabbingContext instance will only be reactivated if the stack is // unwound to it in the _unwindStack() method. var il = this.stack.length; for (var i = 0; i < il; i++) { this.stack[i].deactivate(); } // The "active tabbing set" are the elements tabbing should be constrained // to. var $elements = $(elements).find(':tabbable').addBack(':tabbable'); var tabbingContext = new TabbingContext({ // The level is the current height of the stack before this new // tabbingContext is pushed on top of the stack. level: this.stack.length, $tabbableElements: $elements }); this.stack.push(tabbingContext); // Activates the tabbingContext; this will manipulate the DOM to constrain // tabbing. tabbingContext.activate(); // Allow modules to respond to the constrain event. $(document).trigger('drupalTabbingConstrained', tabbingContext); return tabbingContext; }, /** * Restores a former tabbingContext when an active one is released. * * The TabbingManager stack of tabbingContext instances will be unwound * from the top-most released tabbingContext down to the first non-released * tabbingContext instance. This non-released instance is then activated. */ release: function () { // Unwind as far as possible: find the topmost non-released // tabbingContext. var toActivate = this.stack.length - 1; while (toActivate >= 0 && this.stack[toActivate].released) { toActivate--; } // Delete all tabbingContexts after the to be activated one. They have // already been deactivated, so their effect on the DOM has been reversed. this.stack.splice(toActivate + 1); // Get topmost tabbingContext, if one exists, and activate it. if (toActivate >= 0) { this.stack[toActivate].activate(); } }, /** * Makes all elements outside of the tabbingContext's set untabbable. * * Elements made untabbable have their original tabindex and autofocus * values stored so that they might be restored later when this * tabbingContext is deactivated. * * @param {Drupal~TabbingContext} tabbingContext * The TabbingContext instance that has been activated. */ activate: function (tabbingContext) { var $set = tabbingContext.$tabbableElements; var level = tabbingContext.level; // Determine which elements are reachable via tabbing by default. var $disabledSet = $(':tabbable') // Exclude elements of the active tabbing set. .not($set); // Set the disabled set on the tabbingContext. tabbingContext.$disabledElements = $disabledSet; // Record the tabindex for each element, so we can restore it later. var il = $disabledSet.length; for (var i = 0; i < il; i++) { this.recordTabindex($disabledSet.eq(i), level); } // Make all tabbable elements outside of the active tabbing set // unreachable. $disabledSet .prop('tabindex', -1) .prop('autofocus', false); // Set focus on an element in the tabbingContext's set of tabbable // elements. First, check if there is an element with an autofocus // attribute. Select the last one from the DOM order. var $hasFocus = $set.filter('[autofocus]').eq(-1); // If no element in the tabbable set has an autofocus attribute, select // the first element in the set. if ($hasFocus.length === 0) { $hasFocus = $set.eq(0); } $hasFocus.trigger('focus'); }, /** * Restores that tabbable state of a tabbingContext's disabled elements. * * Elements that were made untabbable have their original tabindex and * autofocus values restored. * * @param {Drupal~TabbingContext} tabbingContext * The TabbingContext instance that has been deactivated. */ deactivate: function (tabbingContext) { var $set = tabbingContext.$disabledElements; var level = tabbingContext.level; var il = $set.length; for (var i = 0; i < il; i++) { this.restoreTabindex($set.eq(i), level); } }, /** * Records the tabindex and autofocus values of an untabbable element. * * @param {jQuery} $el * The set of elements that have been disabled. * @param {number} level * The stack level for which the tabindex attribute should be recorded. */ recordTabindex: function ($el, level) { var tabInfo = $el.data('drupalOriginalTabIndices') || {}; tabInfo[level] = { tabindex: $el[0].getAttribute('tabindex'), autofocus: $el[0].hasAttribute('autofocus') }; $el.data('drupalOriginalTabIndices', tabInfo); }, /** * Restores the tabindex and autofocus values of a reactivated element. * * @param {jQuery} $el * The element that is being reactivated. * @param {number} level * The stack level for which the tabindex attribute should be restored. */ restoreTabindex: function ($el, level) { var tabInfo = $el.data('drupalOriginalTabIndices'); if (tabInfo && tabInfo[level]) { var data = tabInfo[level]; if (data.tabindex) { $el[0].setAttribute('tabindex', data.tabindex); } // If the element did not have a tabindex at this stack level then // remove it. else { $el[0].removeAttribute('tabindex'); } if (data.autofocus) { $el[0].setAttribute('autofocus', 'autofocus'); } // Clean up $.data. if (level === 0) { // Remove all data. $el.removeData('drupalOriginalTabIndices'); } else { // Remove the data for this stack level and higher. var levelToDelete = level; while (tabInfo.hasOwnProperty(levelToDelete)) { delete tabInfo[levelToDelete]; levelToDelete++; } $el.data('drupalOriginalTabIndices', tabInfo); } } } }); /** * Stores a set of tabbable elements. * * This constraint can be removed with the release() method. * * @constructor Drupal~TabbingContext * * @param {object} options * A set of initiating values * @param {number} options.level * The level in the TabbingManager's stack of this tabbingContext. * @param {jQuery} options.$tabbableElements * The DOM elements that should be reachable via the tab key when this * tabbingContext is active. * @param {jQuery} options.$disabledElements * The DOM elements that should not be reachable via the tab key when this * tabbingContext is active. * @param {bool} options.released * A released tabbingContext can never be activated again. It will be * cleaned up when the TabbingManager unwinds its stack. * @param {bool} options.active * When true, the tabbable elements of this tabbingContext will be reachable * via the tab key and the disabled elements will not. Only one * tabbingContext can be active at a time. */ function TabbingContext(options) { $.extend(this, /** @lends Drupal~TabbingContext# */{ /** * @type {?number} */ level: null, /** * @type {jQuery} */ $tabbableElements: $(), /** * @type {jQuery} */ $disabledElements: $(), /** * @type {bool} */ released: false, /** * @type {bool} */ active: false }, options); } /** * Add public methods to the TabbingContext class. */ $.extend(TabbingContext.prototype, /** @lends Drupal~TabbingContext# */{ /** * Releases this TabbingContext. * * Once a TabbingContext object is released, it can never be activated * again. * * @fires event:drupalTabbingContextReleased */ release: function () { if (!this.released) { this.deactivate(); this.released = true; Drupal.tabbingManager.release(this); // Allow modules to respond to the tabbingContext release event. $(document).trigger('drupalTabbingContextReleased', this); } }, /** * Activates this TabbingContext. * * @fires event:drupalTabbingContextActivated */ activate: function () { // A released TabbingContext object can never be activated again. if (!this.active && !this.released) { this.active = true; Drupal.tabbingManager.activate(this); // Allow modules to respond to the constrain event. $(document).trigger('drupalTabbingContextActivated', this); } }, /** * Deactivates this TabbingContext. * * @fires event:drupalTabbingContextDeactivated */ deactivate: function () { if (this.active) { this.active = false; Drupal.tabbingManager.deactivate(this); // Allow modules to respond to the constrain event. $(document).trigger('drupalTabbingContextDeactivated', this); } } }); // Mark this behavior as processed on the first pass and return if it is // already processed. if (Drupal.tabbingManager) { return; } /** * @type {Drupal~TabbingManager} */ Drupal.tabbingManager = new TabbingManager(); }(jQuery, Drupal)); ; /** * @file * Attaches behaviors for the Contextual module's edit toolbar tab. */ (function ($, Drupal, Backbone) { 'use strict'; var strings = { tabbingReleased: Drupal.t('Tabbing is no longer constrained by the Contextual module.'), tabbingConstrained: Drupal.t('Tabbing is constrained to a set of @contextualsCount and the edit mode toggle.'), pressEsc: Drupal.t('Press the esc key to exit.') }; /** * Initializes a contextual link: updates its DOM, sets up model and views. * * @param {HTMLElement} context * A contextual links DOM element as rendered by the server. */ function initContextualToolbar(context) { if (!Drupal.contextual || !Drupal.contextual.collection) { return; } var contextualToolbar = Drupal.contextualToolbar; var model = contextualToolbar.model = new contextualToolbar.StateModel({ // Checks whether localStorage indicates we should start in edit mode // rather than view mode. // @see Drupal.contextualToolbar.VisualView.persist isViewing: localStorage.getItem('Drupal.contextualToolbar.isViewing') !== 'false' }, { contextualCollection: Drupal.contextual.collection }); var viewOptions = { el: $('.toolbar .toolbar-bar .contextual-toolbar-tab'), model: model, strings: strings }; new contextualToolbar.VisualView(viewOptions); new contextualToolbar.AuralView(viewOptions); } /** * Attaches contextual's edit toolbar tab behavior. * * @type {Drupal~behavior} * * @prop {Drupal~behaviorAttach} attach * Attaches contextual toolbar behavior on a contextualToolbar-init event. */ Drupal.behaviors.contextualToolbar = { attach: function (context) { if ($('body').once('contextualToolbar-init').length) { initContextualToolbar(context); } } }; /** * Namespace for the contextual toolbar. * * @namespace */ Drupal.contextualToolbar = { /** * The {@link Drupal.contextualToolbar.StateModel} instance. * * @type {?Drupal.contextualToolbar.StateModel} */ model: null }; })(jQuery, Drupal, Backbone); ; /** * @file * A Backbone Model for the state of Contextual module's edit toolbar tab. */ (function (Drupal, Backbone) { 'use strict'; Drupal.contextualToolbar.StateModel = Backbone.Model.extend(/** @lends Drupal.contextualToolbar.StateModel# */{ /** * @type {object} * * @prop {bool} isViewing * @prop {bool} isVisible * @prop {number} contextualCount * @prop {Drupal~TabbingContext} tabbingContext */ defaults: /** @lends Drupal.contextualToolbar.StateModel# */{ /** * Indicates whether the toggle is currently in "view" or "edit" mode. * * @type {bool} */ isViewing: true, /** * Indicates whether the toggle should be visible or hidden. Automatically * calculated, depends on contextualCount. * * @type {bool} */ isVisible: false, /** * Tracks how many contextual links exist on the page. * * @type {number} */ contextualCount: 0, /** * A TabbingContext object as returned by {@link Drupal~TabbingManager}: * the set of tabbable elements when edit mode is enabled. * * @type {?Drupal~TabbingContext} */ tabbingContext: null }, /** * Models the state of the edit mode toggle. * * @constructs * * @augments Backbone.Model * * @param {object} attrs * Attributes for the backbone model. * @param {object} options * An object with the following option: * @param {Backbone.collection} options.contextualCollection * The collection of {@link Drupal.contextual.StateModel} models that * represent the contextual links on the page. */ initialize: function (attrs, options) { // Respond to new/removed contextual links. this.listenTo(options.contextualCollection, 'reset remove add', this.countContextualLinks); this.listenTo(options.contextualCollection, 'add', this.lockNewContextualLinks); // Automatically determine visibility. this.listenTo(this, 'change:contextualCount', this.updateVisibility); // Whenever edit mode is toggled, lock all contextual links. this.listenTo(this, 'change:isViewing', function (model, isViewing) { options.contextualCollection.each(function (contextualModel) { contextualModel.set('isLocked', !isViewing); }); }); }, /** * Tracks the number of contextual link models in the collection. * * @param {Drupal.contextual.StateModel} contextualModel * The contextual links model that was added or removed. * @param {Backbone.Collection} contextualCollection * The collection of contextual link models. */ countContextualLinks: function (contextualModel, contextualCollection) { this.set('contextualCount', contextualCollection.length); }, /** * Lock newly added contextual links if edit mode is enabled. * * @param {Drupal.contextual.StateModel} contextualModel * The contextual links model that was added. * @param {Backbone.Collection} [contextualCollection] * The collection of contextual link models. */ lockNewContextualLinks: function (contextualModel, contextualCollection) { if (!this.get('isViewing')) { contextualModel.set('isLocked', true); } }, /** * Automatically updates visibility of the view/edit mode toggle. */ updateVisibility: function () { this.set('isVisible', this.get('contextualCount') > 0); } }); })(Drupal, Backbone); ; /** * @file * A Backbone View that provides the aural view of the edit mode toggle. */ (function ($, Drupal, Backbone, _) { 'use strict'; Drupal.contextualToolbar.AuralView = Backbone.View.extend(/** @lends Drupal.contextualToolbar.AuralView# */{ /** * Tracks whether the tabbing constraint announcement has been read once. * * @type {bool} */ announcedOnce: false, /** * Renders the aural view of the edit mode toggle (screen reader support). * * @constructs * * @augments Backbone.View * * @param {object} options * Options for the view. */ initialize: function (options) { this.options = options; this.listenTo(this.model, 'change', this.render); this.listenTo(this.model, 'change:isViewing', this.manageTabbing); $(document).on('keyup', _.bind(this.onKeypress, this)); }, /** * @inheritdoc * * @return {Drupal.contextualToolbar.AuralView} * The current contextual toolbar aural view. */ render: function () { // Render the state. this.$el.find('button').attr('aria-pressed', !this.model.get('isViewing')); return this; }, /** * Limits tabbing to the contextual links and edit mode toolbar tab. */ manageTabbing: function () { var tabbingContext = this.model.get('tabbingContext'); // Always release an existing tabbing context. if (tabbingContext) { tabbingContext.release(); Drupal.announce(this.options.strings.tabbingReleased); } // Create a new tabbing context when edit mode is enabled. if (!this.model.get('isViewing')) { tabbingContext = Drupal.tabbingManager.constrain($('.contextual-toolbar-tab, .contextual')); this.model.set('tabbingContext', tabbingContext); this.announceTabbingConstraint(); this.announcedOnce = true; } }, /** * Announces the current tabbing constraint. */ announceTabbingConstraint: function () { var strings = this.options.strings; Drupal.announce(Drupal.formatString(strings.tabbingConstrained, { '@contextualsCount': Drupal.formatPlural(Drupal.contextual.collection.length, '@count contextual link', '@count contextual links') })); Drupal.announce(strings.pressEsc); }, /** * Responds to esc and tab key press events. * * @param {jQuery.Event} event * The keypress event. */ onKeypress: function (event) { // The first tab key press is tracked so that an annoucement about tabbing // constraints can be raised if edit mode is enabled when the page is // loaded. if (!this.announcedOnce && event.keyCode === 9 && !this.model.get('isViewing')) { this.announceTabbingConstraint(); // Set announce to true so that this conditional block won't run again. this.announcedOnce = true; } // Respond to the ESC key. Exit out of edit mode. if (event.keyCode === 27) { this.model.set('isViewing', true); } } }); })(jQuery, Drupal, Backbone, _); ; /** * @file * A Backbone View that provides the visual view of the edit mode toggle. */ (function (Drupal, Backbone) { 'use strict'; Drupal.contextualToolbar.VisualView = Backbone.View.extend(/** @lends Drupal.contextualToolbar.VisualView# */{ /** * Events for the Backbone view. * * @return {object} * A mapping of events to be used in the view. */ events: function () { // Prevents delay and simulated mouse events. var touchEndToClick = function (event) { event.preventDefault(); event.target.click(); }; return { click: function () { this.model.set('isViewing', !this.model.get('isViewing')); }, touchend: touchEndToClick }; }, /** * Renders the visual view of the edit mode toggle. * * Listens to mouse & touch and handles edit mode toggle interactions. * * @constructs * * @augments Backbone.View */ initialize: function () { this.listenTo(this.model, 'change', this.render); this.listenTo(this.model, 'change:isViewing', this.persist); }, /** * @inheritdoc * * @return {Drupal.contextualToolbar.VisualView} * The current contextual toolbar visual view. */ render: function () { // Render the visibility. this.$el.toggleClass('hidden', !this.model.get('isVisible')); // Render the state. this.$el.find('button').toggleClass('is-active', !this.model.get('isViewing')); return this; }, /** * Model change handler; persists the isViewing value to localStorage. * * `isViewing === true` is the default, so only stores in localStorage when * it's not the default value (i.e. false). * * @param {Drupal.contextualToolbar.StateModel} model * A {@link Drupal.contextualToolbar.StateModel} model. * @param {bool} isViewing * The value of the isViewing attribute in the model. */ persist: function (model, isViewing) { if (!isViewing) { localStorage.setItem('Drupal.contextualToolbar.isViewing', 'false'); } else { localStorage.removeItem('Drupal.contextualToolbar.isViewing'); } } }); })(Drupal, Backbone); ; /** * @file * Replaces the home link in toolbar with a back to site link. */ (function ($, Drupal, drupalSettings) { 'use strict'; var pathInfo = drupalSettings.path; var escapeAdminPath = sessionStorage.getItem('escapeAdminPath'); var windowLocation = window.location; // Saves the last non-administrative page in the browser to be able to link // back to it when browsing administrative pages. If there is a destination // parameter there is not need to save the current path because the page is // loaded within an existing "workflow". if (!pathInfo.currentPathIsAdmin && !/destination=/.test(windowLocation.search)) { sessionStorage.setItem('escapeAdminPath', windowLocation); } /** * Replaces the "Home" link with "Back to site" link. * * Back to site link points to the last non-administrative page the user * visited within the same browser tab. * * @type {Drupal~behavior} * * @prop {Drupal~behaviorAttach} attach * Attaches the replacement functionality to the toolbar-escape-admin element. */ Drupal.behaviors.escapeAdmin = { attach: function () { var $toolbarEscape = $('[data-toolbar-escape-admin]').once('escapeAdmin'); if ($toolbarEscape.length && pathInfo.currentPathIsAdmin) { if (escapeAdminPath !== null) { $toolbarEscape.attr('href', escapeAdminPath); } else { $toolbarEscape.text(Drupal.t('Home')); } $toolbarEscape.closest('.toolbar-tab').removeClass('hidden'); } } }; })(jQuery, Drupal, drupalSettings); ;
src/svg-icons/image/brightness-2.js
nathanmarks/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ImageBrightness2 = (props) => ( <SvgIcon {...props}> <path d="M10 2c-1.82 0-3.53.5-5 1.35C7.99 5.08 10 8.3 10 12s-2.01 6.92-5 8.65C6.47 21.5 8.18 22 10 22c5.52 0 10-4.48 10-10S15.52 2 10 2z"/> </SvgIcon> ); ImageBrightness2 = pure(ImageBrightness2); ImageBrightness2.displayName = 'ImageBrightness2'; ImageBrightness2.muiName = 'SvgIcon'; export default ImageBrightness2;
6.4.3/examples/wizard/dist/bundle.js
erikras/redux-form-docs
!function(e){function t(r){if(n[r])return n[r].exports;var o=n[r]={exports:{},id:r,loaded:!1};return e[r].call(o.exports,o,o.exports,t),o.loaded=!0,o.exports}var n={};return t.m=e,t.c=n,t.p="/dist/",t(0)}([function(e,t,n){n(280),e.exports=n(279)},function(e,t,n){var r=n(4),o=n(37),i=n(20),a=n(21),u=n(38),s="prototype",c=function(e,t,n){var l,f,p,d,h=e&c.F,v=e&c.G,m=e&c.S,y=e&c.P,g=e&c.B,b=v?r:m?r[t]||(r[t]={}):(r[t]||{})[s],_=v?o:o[t]||(o[t]={}),x=_[s]||(_[s]={});v&&(n=t);for(l in n)f=!h&&b&&void 0!==b[l],p=(f?b:n)[l],d=g&&f?u(p,r):y&&"function"==typeof p?u(Function.call,p):p,b&&a(b,l,p,e&c.U),_[l]!=p&&i(_,l,d),y&&x[l]!=p&&(x[l]=p)};r.core=o,c.F=1,c.G=2,c.S=4,c.P=8,c.B=16,c.W=32,c.U=64,c.R=128,e.exports=c},function(e,t,n){"use strict";function r(e,t,n,r,i,a,u,s){if(o(t),!e){var c;if(void 0===t)c=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var l=[n,r,i,a,u,s],f=0;c=new Error(t.replace(/%s/g,function(){return l[f++]})),c.name="Invariant Violation"}throw c.framesToPop=1,c}}var o=function(e){};e.exports=r},function(e,t,n){var r=n(8);e.exports=function(e){if(!r(e))throw TypeError(e+" is not an object!");return e}},function(e,t){var n=e.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},function(e,t,n){"use strict";var r=n(29),o=r;e.exports=o},function(e,t){e.exports=function(e){try{return!!e()}catch(e){return!0}}},function(e,t){"use strict";function n(e){for(var t=arguments.length-1,n="Minified React error #"+e+"; visit http://facebook.github.io/react/docs/error-decoder.html?invariant="+e,r=0;r<t;r++)n+="&args[]="+encodeURIComponent(arguments[r+1]);n+=" for the full message or use the non-minified dev environment for full errors and additional helpful warnings.";var o=new Error(n);throw o.name="Invariant Violation",o.framesToPop=1,o}e.exports=n},function(e,t){e.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},function(e,t,n){var r=n(94)("wks"),o=n(56),i=n(4).Symbol,a="function"==typeof i,u=e.exports=function(e){return r[e]||(r[e]=a&&i[e]||(a?i:o)("Symbol."+e))};u.store=r},function(e,t){"use strict";function n(e){if(null===e||void 0===e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}function r(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;var r=Object.getOwnPropertyNames(t).map(function(e){return t[e]});if("0123456789"!==r.join(""))return!1;var o={};return"abcdefghijklmnopqrst".split("").forEach(function(e){o[e]=e}),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},o)).join("")}catch(e){return!1}}var o=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable;e.exports=r()?Object.assign:function(e,t){for(var r,a,u=n(e),s=1;s<arguments.length;s++){r=Object(arguments[s]);for(var c in r)o.call(r,c)&&(u[c]=r[c]);if(Object.getOwnPropertySymbols){a=Object.getOwnPropertySymbols(r);for(var l=0;l<a.length;l++)i.call(r,a[l])&&(u[a[l]]=r[a[l]])}}return u}},function(e,t,n){e.exports=!n(6)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},function(e,t,n){var r=n(3),o=n(188),i=n(34),a=Object.defineProperty;t.f=n(11)?Object.defineProperty:function(e,t,n){if(r(e),t=i(t,!0),r(n),o)try{return a(e,t,n)}catch(e){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(e[t]=n.value),e}},function(e,t,n){"use strict";function r(e){for(var t;t=e._renderedComponent;)e=t;return e}function o(e,t){var n=r(e);n._hostNode=t,t[v]=n}function i(e){var t=e._hostNode;t&&(delete t[v],e._hostNode=null)}function a(e,t){if(!(e._flags&h.hasCachedChildNodes)){var n=e._renderedChildren,i=t.firstChild;e:for(var a in n)if(n.hasOwnProperty(a)){var u=n[a],s=r(u)._domID;if(0!==s){for(;null!==i;i=i.nextSibling)if(1===i.nodeType&&i.getAttribute(d)===String(s)||8===i.nodeType&&i.nodeValue===" react-text: "+s+" "||8===i.nodeType&&i.nodeValue===" react-empty: "+s+" "){o(u,i);continue e}l("32",s)}}e._flags|=h.hasCachedChildNodes}}function u(e){if(e[v])return e[v];for(var t=[];!e[v];){if(t.push(e),!e.parentNode)return null;e=e.parentNode}for(var n,r;e&&(r=e[v]);e=t.pop())n=r,t.length&&a(r,e);return n}function s(e){var t=u(e);return null!=t&&t._hostNode===e?t:null}function c(e){if(void 0===e._hostNode?l("33"):void 0,e._hostNode)return e._hostNode;for(var t=[];!e._hostNode;)t.push(e),e._hostParent?void 0:l("34"),e=e._hostParent;for(;t.length;e=t.pop())a(e,e._hostNode);return e._hostNode}var l=n(7),f=n(67),p=n(239),d=(n(2),f.ID_ATTRIBUTE_NAME),h=p,v="__reactInternalInstance$"+Math.random().toString(36).slice(2),m={getClosestInstanceFromNode:u,getInstanceFromNode:s,getNodeFromInstance:c,precacheChildNodes:a,precacheNode:o,uncacheNode:i};e.exports=m},function(e,t,n){"use strict";e.exports=n(70)},function(e,t,n){var r=n(45),o=Math.min;e.exports=function(e){return e>0?o(r(e),9007199254740991):0}},function(e,t,n){var r=n(27);e.exports=function(e){return Object(r(e))}},function(e,t){var n={}.hasOwnProperty;e.exports=function(e,t){return n.call(e,t)}},function(e,t){"use strict";var n=!("undefined"==typeof window||!window.document||!window.document.createElement),r={canUseDOM:n,canUseWorkers:"undefined"!=typeof Worker,canUseEventListeners:n&&!(!window.addEventListener&&!window.attachEvent),canUseViewport:n&&!!window.screen,isInWorker:!n};e.exports=r},function(e,t){e.exports=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e}},function(e,t,n){var r=n(12),o=n(44);e.exports=n(11)?function(e,t,n){return r.f(e,t,o(1,n))}:function(e,t,n){return e[t]=n,e}},function(e,t,n){var r=n(4),o=n(20),i=n(17),a=n(56)("src"),u="toString",s=Function[u],c=(""+s).split(u);n(37).inspectSource=function(e){return s.call(e)},(e.exports=function(e,t,n,u){var s="function"==typeof n;s&&(i(n,"name")||o(n,"name",t)),e[t]!==n&&(s&&(i(n,a)||o(n,a,e[t]?""+e[t]:c.join(String(t)))),e===r?e[t]=n:u?e[t]?e[t]=n:o(e,t,n):(delete e[t],o(e,t,n)))})(Function.prototype,u,function(){return"function"==typeof this&&this[a]||s.call(this)})},function(e,t,n){var r=n(1),o=n(6),i=n(27),a=/"/g,u=function(e,t,n,r){var o=String(i(e)),u="<"+t;return""!==n&&(u+=" "+n+'="'+String(r).replace(a,"&quot;")+'"'),u+">"+o+"</"+t+">"};e.exports=function(e,t){var n={};n[e]=t(u),r(r.P+r.F*o(function(){var t=""[e]('"');return t!==t.toLowerCase()||t.split('"').length>3}),"String",n)}},function(e,t,n){var r=n(74),o=n(27);e.exports=function(e){return r(o(e))}},function(e,t,n){var r=n(75),o=n(44),i=n(23),a=n(34),u=n(17),s=n(188),c=Object.getOwnPropertyDescriptor;t.f=n(11)?c:function(e,t){if(e=i(e),t=a(t,!0),s)try{return c(e,t)}catch(e){}if(u(e,t))return o(!r.f.call(e,t),e[t])}},function(e,t,n){var r=n(17),o=n(16),i=n(130)("IE_PROTO"),a=Object.prototype;e.exports=Object.getPrototypeOf||function(e){return e=o(e),r(e,i)?e[i]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?a:null}},function(e,t){var n={}.toString;e.exports=function(e){return n.call(e).slice(8,-1)}},function(e,t){e.exports=function(e){if(void 0==e)throw TypeError("Can't call method on "+e);return e}},function(e,t,n){var r=n(6);e.exports=function(e,t){return!!e&&r(function(){t?e.call(null,function(){},1):e.call(null)})}},function(e,t){"use strict";function n(e){return function(){return e}}var r=function(){};r.thatReturns=n,r.thatReturnsFalse=n(!1),r.thatReturnsTrue=n(!0),r.thatReturnsNull=n(null),r.thatReturnsThis=function(){return this},r.thatReturnsArgument=function(e){return e},e.exports=r},function(e,t){var n=Array.isArray;e.exports=n},function(e,t,n){"use strict";var r=null;e.exports={debugTool:r}},function(e,t,n){var r=n(38),o=n(74),i=n(16),a=n(15),u=n(283);e.exports=function(e,t){var n=1==e,s=2==e,c=3==e,l=4==e,f=6==e,p=5==e||f,d=t||u;return function(t,u,h){for(var v,m,y=i(t),g=o(y),b=r(u,h,3),_=a(g.length),x=0,E=n?d(t,_):s?d(t,0):void 0;_>x;x++)if((p||x in g)&&(v=g[x],m=b(v,x,y),e))if(n)E[x]=m;else if(m)switch(e){case 3:return!0;case 5:return v;case 6:return x;case 2:E.push(v)}else if(l)return!1;return f?-1:c||l?l:E}}},function(e,t,n){var r=n(1),o=n(37),i=n(6);e.exports=function(e,t){var n=(o.Object||{})[e]||Object[e],a={};a[e]=t(n),r(r.S+r.F*i(function(){n(1)}),"Object",a)}},function(e,t,n){var r=n(8);e.exports=function(e,t){if(!r(e))return e;var n,o;if(t&&"function"==typeof(n=e.toString)&&!r(o=n.call(e)))return o;if("function"==typeof(n=e.valueOf)&&!r(o=n.call(e)))return o;if(!t&&"function"==typeof(n=e.toString)&&!r(o=n.call(e)))return o;throw TypeError("Can't convert object to primitive value")}},function(e,t,n){var r=n(225),o="object"==typeof self&&self&&self.Object===Object&&self,i=r||o||Function("return this")();e.exports=i},function(e,t,n){"use strict";function r(){O.ReactReconcileTransaction&&x?void 0:l("123")}function o(){this.reinitializeTransaction(),this.dirtyComponentsLength=null,this.callbackQueue=p.getPooled(),this.reconcileTransaction=O.ReactReconcileTransaction.getPooled(!0)}function i(e,t,n,o,i,a){return r(),x.batchedUpdates(e,t,n,o,i,a)}function a(e,t){return e._mountOrder-t._mountOrder}function u(e){var t=e.dirtyComponentsLength;t!==y.length?l("124",t,y.length):void 0,y.sort(a),g++;for(var n=0;n<t;n++){var r=y[n],o=r._pendingCallbacks;r._pendingCallbacks=null;var i;if(h.logTopLevelRenders){var u=r;r._currentElement.type.isReactTopLevelWrapper&&(u=r._renderedComponent),i="React update: "+u.getName(),console.time(i)}if(v.performUpdateIfNecessary(r,e.reconcileTransaction,g),i&&console.timeEnd(i),o)for(var s=0;s<o.length;s++)e.callbackQueue.enqueue(o[s],r.getPublicInstance())}}function s(e){return r(),x.isBatchingUpdates?(y.push(e),void(null==e._updateBatchNumber&&(e._updateBatchNumber=g+1))):void x.batchedUpdates(s,e)}function c(e,t){x.isBatchingUpdates?void 0:l("125"),b.enqueue(e,t),_=!0}var l=n(7),f=n(10),p=n(237),d=n(59),h=n(242),v=n(68),m=n(107),y=(n(2),[]),g=0,b=p.getPooled(),_=!1,x=null,E={initialize:function(){this.dirtyComponentsLength=y.length},close:function(){this.dirtyComponentsLength!==y.length?(y.splice(0,this.dirtyComponentsLength),C()):y.length=0}},w={initialize:function(){this.callbackQueue.reset()},close:function(){this.callbackQueue.notifyAll()}},S=[E,w];f(o.prototype,m,{getTransactionWrappers:function(){return S},destructor:function(){this.dirtyComponentsLength=null,p.release(this.callbackQueue),this.callbackQueue=null,O.ReactReconcileTransaction.release(this.reconcileTransaction),this.reconcileTransaction=null},perform:function(e,t,n){return m.perform.call(this,this.reconcileTransaction.perform,this.reconcileTransaction,e,t,n)}}),d.addPoolingTo(o);var C=function(){for(;y.length||_;){if(y.length){var e=o.getPooled();e.perform(u,null,e),o.release(e)}if(_){_=!1;var t=b;b=p.getPooled(),t.notifyAll(),p.release(t)}}},P={injectReconcileTransaction:function(e){e?void 0:l("126"),O.ReactReconcileTransaction=e},injectBatchingStrategy:function(e){e?void 0:l("127"),"function"!=typeof e.batchedUpdates?l("128"):void 0,"boolean"!=typeof e.isBatchingUpdates?l("129"):void 0,x=e}},O={ReactReconcileTransaction:null,batchedUpdates:i,enqueueUpdate:s,flushBatchedUpdates:C,injection:P,asap:c};e.exports=O},function(e,t){var n=e.exports={version:"2.4.0"};"number"==typeof __e&&(__e=n)},function(e,t,n){var r=n(19);e.exports=function(e,t,n){if(r(e),void 0===t)return e;switch(n){case 1:return function(n){return e.call(t,n)};case 2:return function(n,r){return e.call(t,n,r)};case 3:return function(n,r,o){return e.call(t,n,r,o)}}return function(){return e.apply(t,arguments)}}},function(e,t,n){var r=n(204),o=n(1),i=n(94)("metadata"),a=i.store||(i.store=new(n(207))),u=function(e,t,n){var o=a.get(e);if(!o){if(!n)return;a.set(e,o=new r)}var i=o.get(t);if(!i){if(!n)return;o.set(t,i=new r)}return i},s=function(e,t,n){var r=u(t,n,!1);return void 0!==r&&r.has(e)},c=function(e,t,n){var r=u(t,n,!1);return void 0===r?void 0:r.get(e)},l=function(e,t,n,r){u(n,r,!0).set(e,t)},f=function(e,t){var n=u(e,t,!1),r=[];return n&&n.forEach(function(e,t){r.push(t)}),r},p=function(e){return void 0===e||"symbol"==typeof e?e:String(e)},d=function(e){o(o.S,"Reflect",e)};e.exports={store:a,map:u,has:s,get:c,set:l,keys:f,key:p,exp:d}},function(e,t,n){"use strict";if(n(11)){var r=n(49),o=n(4),i=n(6),a=n(1),u=n(95),s=n(137),c=n(38),l=n(48),f=n(44),p=n(20),d=n(53),h=n(45),v=n(15),m=n(55),y=n(34),g=n(17),b=n(201),_=n(73),x=n(8),E=n(16),w=n(122),S=n(50),C=n(25),P=n(51).f,O=n(139),T=n(56),k=n(9),A=n(32),R=n(85),M=n(131),I=n(140),N=n(62),j=n(91),F=n(54),D=n(115),U=n(181),L=n(12),V=n(24),W=L.f,B=V.f,q=o.RangeError,z=o.TypeError,H=o.Uint8Array,Y="ArrayBuffer",K="Shared"+Y,G="BYTES_PER_ELEMENT",$="prototype",X=Array[$],Q=s.ArrayBuffer,J=s.DataView,Z=A(0),ee=A(2),te=A(3),ne=A(4),re=A(5),oe=A(6),ie=R(!0),ae=R(!1),ue=I.values,se=I.keys,ce=I.entries,le=X.lastIndexOf,fe=X.reduce,pe=X.reduceRight,de=X.join,he=X.sort,ve=X.slice,me=X.toString,ye=X.toLocaleString,ge=k("iterator"),be=k("toStringTag"),_e=T("typed_constructor"),xe=T("def_constructor"),Ee=u.CONSTR,we=u.TYPED,Se=u.VIEW,Ce="Wrong length!",Pe=A(1,function(e,t){return Me(M(e,e[xe]),t)}),Oe=i(function(){return 1===new H(new Uint16Array([1]).buffer)[0]}),Te=!!H&&!!H[$].set&&i(function(){new H(1).set({})}),ke=function(e,t){if(void 0===e)throw z(Ce);var n=+e,r=v(e);if(t&&!b(n,r))throw q(Ce);return r},Ae=function(e,t){var n=h(e);if(n<0||n%t)throw q("Wrong offset!");return n},Re=function(e){if(x(e)&&we in e)return e;throw z(e+" is not a typed array!")},Me=function(e,t){if(!(x(e)&&_e in e))throw z("It is not a typed array constructor!");return new e(t)},Ie=function(e,t){return Ne(M(e,e[xe]),t)},Ne=function(e,t){for(var n=0,r=t.length,o=Me(e,r);r>n;)o[n]=t[n++];return o},je=function(e,t,n){W(e,t,{get:function(){return this._d[n]}})},Fe=function(e){var t,n,r,o,i,a,u=E(e),s=arguments.length,l=s>1?arguments[1]:void 0,f=void 0!==l,p=O(u);if(void 0!=p&&!w(p)){for(a=p.call(u),r=[],t=0;!(i=a.next()).done;t++)r.push(i.value);u=r}for(f&&s>2&&(l=c(l,arguments[2],2)),t=0,n=v(u.length),o=Me(this,n);n>t;t++)o[t]=f?l(u[t],t):u[t];return o},De=function(){for(var e=0,t=arguments.length,n=Me(this,t);t>e;)n[e]=arguments[e++];return n},Ue=!!H&&i(function(){ye.call(new H(1))}),Le=function(){return ye.apply(Ue?ve.call(Re(this)):Re(this),arguments)},Ve={copyWithin:function(e,t){return U.call(Re(this),e,t,arguments.length>2?arguments[2]:void 0)},every:function(e){return ne(Re(this),e,arguments.length>1?arguments[1]:void 0)},fill:function(e){return D.apply(Re(this),arguments)},filter:function(e){return Ie(this,ee(Re(this),e,arguments.length>1?arguments[1]:void 0))},find:function(e){return re(Re(this),e,arguments.length>1?arguments[1]:void 0)},findIndex:function(e){return oe(Re(this),e,arguments.length>1?arguments[1]:void 0)},forEach:function(e){Z(Re(this),e,arguments.length>1?arguments[1]:void 0)},indexOf:function(e){return ae(Re(this),e,arguments.length>1?arguments[1]:void 0)},includes:function(e){return ie(Re(this),e,arguments.length>1?arguments[1]:void 0)},join:function(e){return de.apply(Re(this),arguments)},lastIndexOf:function(e){return le.apply(Re(this),arguments)},map:function(e){return Pe(Re(this),e,arguments.length>1?arguments[1]:void 0)},reduce:function(e){return fe.apply(Re(this),arguments)},reduceRight:function(e){return pe.apply(Re(this),arguments)},reverse:function(){for(var e,t=this,n=Re(t).length,r=Math.floor(n/2),o=0;o<r;)e=t[o],t[o++]=t[--n],t[n]=e;return t},some:function(e){return te(Re(this),e,arguments.length>1?arguments[1]:void 0)},sort:function(e){return he.call(Re(this),e)},subarray:function(e,t){var n=Re(this),r=n.length,o=m(e,r);return new(M(n,n[xe]))(n.buffer,n.byteOffset+o*n.BYTES_PER_ELEMENT,v((void 0===t?r:m(t,r))-o))}},We=function(e,t){return Ie(this,ve.call(Re(this),e,t))},Be=function(e){Re(this);var t=Ae(arguments[1],1),n=this.length,r=E(e),o=v(r.length),i=0;if(o+t>n)throw q(Ce);for(;i<o;)this[t+i]=r[i++]},qe={entries:function(){return ce.call(Re(this))},keys:function(){return se.call(Re(this))},values:function(){return ue.call(Re(this))}},ze=function(e,t){return x(e)&&e[we]&&"symbol"!=typeof t&&t in e&&String(+t)==String(t)},He=function(e,t){return ze(e,t=y(t,!0))?f(2,e[t]):B(e,t)},Ye=function(e,t,n){return!(ze(e,t=y(t,!0))&&x(n)&&g(n,"value"))||g(n,"get")||g(n,"set")||n.configurable||g(n,"writable")&&!n.writable||g(n,"enumerable")&&!n.enumerable?W(e,t,n):(e[t]=n.value,e)};Ee||(V.f=He,L.f=Ye),a(a.S+a.F*!Ee,"Object",{getOwnPropertyDescriptor:He,defineProperty:Ye}),i(function(){me.call({})})&&(me=ye=function(){return de.call(this)});var Ke=d({},Ve);d(Ke,qe),p(Ke,ge,qe.values),d(Ke,{slice:We,set:Be,constructor:function(){},toString:me,toLocaleString:Le}),je(Ke,"buffer","b"),je(Ke,"byteOffset","o"),je(Ke,"byteLength","l"),je(Ke,"length","e"),W(Ke,be,{get:function(){return this[we]}}),e.exports=function(e,t,n,s){s=!!s;var c=e+(s?"Clamped":"")+"Array",f="Uint8Array"!=c,d="get"+e,h="set"+e,m=o[c],y=m||{},g=m&&C(m),b=!m||!u.ABV,E={},w=m&&m[$],O=function(e,n){var r=e._d;return r.v[d](n*t+r.o,Oe)},T=function(e,n,r){var o=e._d;s&&(r=(r=Math.round(r))<0?0:r>255?255:255&r),o.v[h](n*t+o.o,r,Oe)},k=function(e,t){W(e,t,{get:function(){return O(this,t)},set:function(e){return T(this,t,e)},enumerable:!0})};b?(m=n(function(e,n,r,o){l(e,m,c,"_d");var i,a,u,s,f=0,d=0;if(x(n)){if(!(n instanceof Q||(s=_(n))==Y||s==K))return we in n?Ne(m,n):Fe.call(m,n);i=n,d=Ae(r,t);var h=n.byteLength;if(void 0===o){if(h%t)throw q(Ce);if(a=h-d,a<0)throw q(Ce)}else if(a=v(o)*t,a+d>h)throw q(Ce);u=a/t}else u=ke(n,!0),a=u*t,i=new Q(a);for(p(e,"_d",{b:i,o:d,l:a,e:u,v:new J(i)});f<u;)k(e,f++)}),w=m[$]=S(Ke),p(w,"constructor",m)):j(function(e){new m(null),new m(e)},!0)||(m=n(function(e,n,r,o){l(e,m,c);var i;return x(n)?n instanceof Q||(i=_(n))==Y||i==K?void 0!==o?new y(n,Ae(r,t),o):void 0!==r?new y(n,Ae(r,t)):new y(n):we in n?Ne(m,n):Fe.call(m,n):new y(ke(n,f))}),Z(g!==Function.prototype?P(y).concat(P(g)):P(y),function(e){e in m||p(m,e,y[e])}),m[$]=w,r||(w.constructor=m));var A=w[ge],R=!!A&&("values"==A.name||void 0==A.name),M=qe.values;p(m,_e,!0),p(w,we,c),p(w,Se,!0),p(w,xe,m),(s?new m(1)[be]==c:be in w)||W(w,be,{get:function(){return c}}),E[c]=m,a(a.G+a.W+a.F*(m!=y),E),a(a.S,c,{BYTES_PER_ELEMENT:t,from:Fe,of:De}),G in w||p(w,G,t),a(a.P,c,Ve),F(c),a(a.P+a.F*Te,c,{set:Be}),a(a.P+a.F*!R,c,qe),a(a.P+a.F*(w.toString!=me),c,{toString:me}),a(a.P+a.F*i(function(){new m(1).slice()}),c,{slice:We}),a(a.P+a.F*(i(function(){return[1,2].toLocaleString()!=new m([1,2]).toLocaleString()})||!i(function(){w.toLocaleString.call([1,2])})),c,{toLocaleString:Le}),N[c]=R?A:M,r||R||p(w,ge,M)}}else e.exports=function(){}},function(e,t,n){"use strict";function r(e,t,n,r){this.dispatchConfig=e,this._targetInst=t,this.nativeEvent=n;var o=this.constructor.Interface;for(var i in o)if(o.hasOwnProperty(i)){var u=o[i];u?this[i]=u(n):"target"===i?this.target=r:this[i]=n[i]}var s=null!=n.defaultPrevented?n.defaultPrevented:n.returnValue===!1;return s?this.isDefaultPrevented=a.thatReturnsTrue:this.isDefaultPrevented=a.thatReturnsFalse,this.isPropagationStopped=a.thatReturnsFalse,this}var o=n(10),i=n(59),a=n(29),u=(n(5),"function"==typeof Proxy,["dispatchConfig","_targetInst","nativeEvent","isDefaultPrevented","isPropagationStopped","_dispatchListeners","_dispatchInstances"]),s={type:null,target:null,currentTarget:a.thatReturnsNull,eventPhase:null,bubbles:null,cancelable:null,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:null,isTrusted:null};o(r.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():"unknown"!=typeof e.returnValue&&(e.returnValue=!1),this.isDefaultPrevented=a.thatReturnsTrue)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():"unknown"!=typeof e.cancelBubble&&(e.cancelBubble=!0),this.isPropagationStopped=a.thatReturnsTrue)},persist:function(){this.isPersistent=a.thatReturnsTrue},isPersistent:a.thatReturnsFalse,destructor:function(){var e=this.constructor.Interface;for(var t in e)this[t]=null;for(var n=0;n<u.length;n++)this[u[n]]=null}}),r.Interface=s,r.augmentClass=function(e,t){var n=this,r=function(){};r.prototype=n.prototype;var a=new r;o(a,e.prototype),e.prototype=a,e.prototype.constructor=e,e.Interface=o({},n.Interface,t),e.augmentClass=n.augmentClass,i.addPoolingTo(e,i.fourArgumentPooler)},i.addPoolingTo(r,i.fourArgumentPooler),e.exports=r},function(e,t){"use strict";var n={current:null};e.exports=n},function(e,t,n){var r=n(56)("meta"),o=n(8),i=n(17),a=n(12).f,u=0,s=Object.isExtensible||function(){return!0},c=!n(6)(function(){return s(Object.preventExtensions({}))}),l=function(e){a(e,r,{value:{i:"O"+ ++u,w:{}}})},f=function(e,t){if(!o(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;if(!i(e,r)){if(!s(e))return"F";if(!t)return"E";l(e)}return e[r].i},p=function(e,t){if(!i(e,r)){if(!s(e))return!0;if(!t)return!1;l(e)}return e[r].w},d=function(e){return c&&h.NEED&&s(e)&&!i(e,r)&&l(e),e},h=e.exports={KEY:r,NEED:!1,fastKey:f,getWeak:p,onFreeze:d}},function(e,t){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},function(e,t){var n=Math.ceil,r=Math.floor;e.exports=function(e){return isNaN(e=+e)?0:(e>0?r:n)(e)}},function(e,t){function n(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}e.exports=n},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(574),i=r(o),a=n(701),u=r(a),s=n(270),c=r(s),l=n(700),f=r(l),p=n(698),d=r(p),h=n(699),v=r(h),m={empty:{},emptyList:[],getIn:c.default,setIn:f.default,deepEqual:d.default,deleteIn:v.default,fromJS:function(e){return e},size:function(e){return e?e.length:0},some:i.default,splice:u.default,toJS:function(e){return e}};t.default=m},function(e,t){e.exports=function(e,t,n,r){if(!(e instanceof t)||void 0!==r&&r in e)throw TypeError(n+": incorrect invocation!");return e}},function(e,t){e.exports=!1},function(e,t,n){var r=n(3),o=n(194),i=n(118),a=n(130)("IE_PROTO"),u=function(){},s="prototype",c=function(){var e,t=n(117)("iframe"),r=i.length,o="<",a=">";for(t.style.display="none",n(120).appendChild(t),t.src="javascript:",e=t.contentWindow.document,e.open(),e.write(o+"script"+a+"document.F=Object"+o+"/script"+a),e.close(),c=e.F;r--;)delete c[s][i[r]];return c()};e.exports=Object.create||function(e,t){var n;return null!==e?(u[s]=r(e),n=new u,u[s]=null,n[a]=e):n=c(),void 0===t?n:o(n,t)}},function(e,t,n){var r=n(196),o=n(118).concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return r(e,o)}},function(e,t,n){var r=n(196),o=n(118);e.exports=Object.keys||function(e){return r(e,o)}},function(e,t,n){var r=n(21);e.exports=function(e,t,n){for(var o in t)r(e,o,t[o],n);return e}},function(e,t,n){"use strict";var r=n(4),o=n(12),i=n(11),a=n(9)("species");e.exports=function(e){var t=r[e];i&&t&&!t[a]&&o.f(t,a,{configurable:!0,get:function(){return this}})}},function(e,t,n){var r=n(45),o=Math.max,i=Math.min;e.exports=function(e,t){return e=r(e),e<0?o(e+t,0):i(e,t)}},function(e,t){var n=0,r=Math.random();e.exports=function(e){return"Symbol(".concat(void 0===e?"":e,")_",(++n+r).toString(36))}},function(e,t,n){function r(e,t){var n=i(e,t);return o(n)?n:void 0}var o=n(497),i=n(529);e.exports=r},function(e,t){function n(e){return null!=e&&"object"==typeof e}e.exports=n},function(e,t,n){"use strict";var r=n(7),o=(n(2),function(e){var t=this;if(t.instancePool.length){var n=t.instancePool.pop();return t.call(n,e),n}return new t(e)}),i=function(e,t){var n=this;if(n.instancePool.length){var r=n.instancePool.pop();return n.call(r,e,t),r}return new n(e,t)},a=function(e,t,n){var r=this;if(r.instancePool.length){var o=r.instancePool.pop();return r.call(o,e,t,n),o}return new r(e,t,n)},u=function(e,t,n,r){var o=this;if(o.instancePool.length){var i=o.instancePool.pop();return o.call(i,e,t,n,r),i}return new o(e,t,n,r)},s=function(e,t,n,r,o){var i=this;if(i.instancePool.length){var a=i.instancePool.pop();return i.call(a,e,t,n,r,o),a}return new i(e,t,n,r,o)},c=function(e){var t=this;e instanceof t?void 0:r("25"),e.destructor(),t.instancePool.length<t.poolSize&&t.instancePool.push(e)},l=10,f=o,p=function(e,t){var n=e;return n.instancePool=[],n.getPooled=t||f,n.poolSize||(n.poolSize=l),n.release=c,n},d={addPoolingTo:p,oneArgumentPooler:o,twoArgumentPooler:i,threeArgumentPooler:a,fourArgumentPooler:u,fiveArgumentPooler:s};e.exports=d},function(e,t,n){var r=n(9)("unscopables"),o=Array.prototype;void 0==o[r]&&n(20)(o,r,{}),e.exports=function(e){o[r][e]=!0}},function(e,t,n){var r=n(38),o=n(190),i=n(122),a=n(3),u=n(15),s=n(139),c={},l={},t=e.exports=function(e,t,n,f,p){var d,h,v,m,y=p?function(){return e}:s(e),g=r(n,f,t?2:1),b=0;if("function"!=typeof y)throw TypeError(e+" is not iterable!");if(i(y)){for(d=u(e.length);d>b;b++)if(m=t?g(a(h=e[b])[0],h[1]):g(e[b]),m===c||m===l)return m}else for(v=y.call(e);!(h=v.next()).done;)if(m=o(v,g,h.value,t),m===c||m===l)return m};t.BREAK=c,t.RETURN=l},function(e,t){e.exports={}},function(e,t,n){var r=n(12).f,o=n(17),i=n(9)("toStringTag");e.exports=function(e,t,n){e&&!o(e=n?e:e.prototype,i)&&r(e,i,{configurable:!0,value:t})}},function(e,t,n){var r=n(1),o=n(27),i=n(6),a=n(135),u="["+a+"]",s="​…",c=RegExp("^"+u+u+"*"),l=RegExp(u+u+"*$"),f=function(e,t,n){var o={},u=i(function(){return!!a[e]()||s[e]()!=s}),c=o[e]=u?t(p):a[e];n&&(o[n]=c),r(r.P+r.F*u,"String",o)},p=f.trim=function(e,t){return e=String(o(e)),1&t&&(e=e.replace(c,"")),2&t&&(e=e.replace(l,"")),e};e.exports=f},function(e,t,n){function r(e){return null==e?void 0===e?s:u:c&&c in Object(e)?i(e):a(e)}var o=n(97),i=n(526),a=n(554),u="[object Null]",s="[object Undefined]",c=o?o.toStringTag:void 0;e.exports=r},function(e,t,n){"use strict";function r(e){if(m){var t=e.node,n=e.children;if(n.length)for(var r=0;r<n.length;r++)y(t,n[r],null);else null!=e.html?f(t,e.html):null!=e.text&&d(t,e.text)}}function o(e,t){e.parentNode.replaceChild(t.node,e),r(t)}function i(e,t){m?e.children.push(t):e.node.appendChild(t.node)}function a(e,t){m?e.html=t:f(e.node,t)}function u(e,t){m?e.text=t:d(e.node,t)}function s(){return this.node.nodeName}function c(e){return{node:e,children:[],html:null,text:null,toString:s}}var l=n(159),f=n(109),p=n(167),d=n(254),h=1,v=11,m="undefined"!=typeof document&&"number"==typeof document.documentMode||"undefined"!=typeof navigator&&"string"==typeof navigator.userAgent&&/\bEdge\/\d/.test(navigator.userAgent),y=p(function(e,t,n){t.node.nodeType===v||t.node.nodeType===h&&"object"===t.node.nodeName.toLowerCase()&&(null==t.node.namespaceURI||t.node.namespaceURI===l.html)?(r(t),e.insertBefore(t.node,n)):(e.insertBefore(t.node,n),r(t))});c.insertTreeBefore=y,c.replaceChildWithTree=o,c.queueChild=i,c.queueHTML=a,c.queueText=u,e.exports=c},function(e,t,n){"use strict";function r(e,t){return(e&t)===t}var o=n(7),i=(n(2),{MUST_USE_PROPERTY:1,HAS_BOOLEAN_VALUE:4,HAS_NUMERIC_VALUE:8,HAS_POSITIVE_NUMERIC_VALUE:24,HAS_OVERLOADED_BOOLEAN_VALUE:32,injectDOMPropertyConfig:function(e){var t=i,n=e.Properties||{},a=e.DOMAttributeNamespaces||{},s=e.DOMAttributeNames||{},c=e.DOMPropertyNames||{},l=e.DOMMutationMethods||{};e.isCustomAttribute&&u._isCustomAttributeFunctions.push(e.isCustomAttribute);for(var f in n){u.properties.hasOwnProperty(f)?o("48",f):void 0;var p=f.toLowerCase(),d=n[f],h={attributeName:p,attributeNamespace:null,propertyName:f,mutationMethod:null,mustUseProperty:r(d,t.MUST_USE_PROPERTY),hasBooleanValue:r(d,t.HAS_BOOLEAN_VALUE),hasNumericValue:r(d,t.HAS_NUMERIC_VALUE),hasPositiveNumericValue:r(d,t.HAS_POSITIVE_NUMERIC_VALUE),hasOverloadedBooleanValue:r(d,t.HAS_OVERLOADED_BOOLEAN_VALUE)};if(h.hasBooleanValue+h.hasNumericValue+h.hasOverloadedBooleanValue<=1?void 0:o("50",f),s.hasOwnProperty(f)){var v=s[f];h.attributeName=v}a.hasOwnProperty(f)&&(h.attributeNamespace=a[f]),c.hasOwnProperty(f)&&(h.propertyName=c[f]),l.hasOwnProperty(f)&&(h.mutationMethod=l[f]),u.properties[f]=h}}}),a=":A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",u={ID_ATTRIBUTE_NAME:"data-reactid",ROOT_ATTRIBUTE_NAME:"data-reactroot",ATTRIBUTE_NAME_START_CHAR:a,ATTRIBUTE_NAME_CHAR:a+"\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040",properties:{},getPossibleStandardName:null,_isCustomAttributeFunctions:[],isCustomAttribute:function(e){for(var t=0;t<u._isCustomAttributeFunctions.length;t++){var n=u._isCustomAttributeFunctions[t];if(n(e))return!0}return!1},injection:i};e.exports=u},function(e,t,n){"use strict";function r(){o.attachRefs(this,this._currentElement)}var o=n(621),i=(n(31),n(5),{mountComponent:function(e,t,n,o,i,a){var u=e.mountComponent(t,n,o,i,a);return e._currentElement&&null!=e._currentElement.ref&&t.getReactMountReady().enqueue(r,e),u},getHostNode:function(e){return e.getHostNode()},unmountComponent:function(e,t){o.detachRefs(e,e._currentElement),e.unmountComponent(t)},receiveComponent:function(e,t,n,i){var a=e._currentElement;if(t!==a||i!==e._context){var u=o.shouldUpdateRefs(a,t);u&&o.detachRefs(e,a),e.receiveComponent(t,n,i),u&&e._currentElement&&null!=e._currentElement.ref&&n.getReactMountReady().enqueue(r,e)}},performUpdateIfNecessary:function(e,t,n){e._updateBatchNumber===n&&e.performUpdateIfNecessary(t)}});e.exports=i},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}t.__esModule=!0,t.connect=t.Provider=void 0;var o=n(649),i=r(o),a=n(650),u=r(a);t.Provider=i.default,t.connect=u.default},function(e,t,n){"use strict";var r=n(10),o=n(655),i=n(174),a=n(660),u=n(656),s=n(657),c=n(71),l=n(658),f=n(661),p=n(662),d=(n(5),c.createElement),h=c.createFactory,v=c.cloneElement,m=r,y={Children:{map:o.map,forEach:o.forEach,count:o.count,toArray:o.toArray,only:p},Component:i,PureComponent:a,createElement:d,cloneElement:v,isValidElement:c.isValidElement,PropTypes:l,createClass:u.createClass,createFactory:h,createMixin:function(e){return e},DOM:s,version:f,__spread:m};e.exports=y},function(e,t,n){"use strict";function r(e){return void 0!==e.ref}function o(e){return void 0!==e.key}var i=n(10),a=n(42),u=(n(5),n(261),Object.prototype.hasOwnProperty),s=n(259),c={key:!0,ref:!0,__self:!0,__source:!0},l=function(e,t,n,r,o,i,a){var u={$$typeof:s,type:e,key:t,ref:n,props:a,_owner:i};return u};l.createElement=function(e,t,n){var i,s={},f=null,p=null,d=null,h=null;if(null!=t){r(t)&&(p=t.ref),o(t)&&(f=""+t.key),d=void 0===t.__self?null:t.__self,h=void 0===t.__source?null:t.__source;for(i in t)u.call(t,i)&&!c.hasOwnProperty(i)&&(s[i]=t[i])}var v=arguments.length-2;if(1===v)s.children=n;else if(v>1){for(var m=Array(v),y=0;y<v;y++)m[y]=arguments[y+2];s.children=m}if(e&&e.defaultProps){var g=e.defaultProps;for(i in g)void 0===s[i]&&(s[i]=g[i])}return l(e,f,p,d,h,a.current,s)},l.createFactory=function(e){var t=l.createElement.bind(null,e);return t.type=e,t},l.cloneAndReplaceKey=function(e,t){var n=l(e.type,t,e.ref,e._self,e._source,e._owner,e.props);return n},l.cloneElement=function(e,t,n){var s,f=i({},e.props),p=e.key,d=e.ref,h=e._self,v=e._source,m=e._owner;if(null!=t){r(t)&&(d=t.ref,m=a.current),o(t)&&(p=""+t.key);var y;e.type&&e.type.defaultProps&&(y=e.type.defaultProps);for(s in t)u.call(t,s)&&!c.hasOwnProperty(s)&&(void 0===t[s]&&void 0!==y?f[s]=y[s]:f[s]=t[s])}var g=arguments.length-2;if(1===g)f.children=n;else if(g>1){for(var b=Array(g),_=0;_<g;_++)b[_]=arguments[_+2];f.children=b}return l(e.type,p,d,h,v,m,f)},l.isValidElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===s},e.exports=l},function(e,t){"use strict";function n(e){for(var t=arguments.length-1,n="Minified React error #"+e+"; visit http://facebook.github.io/react/docs/error-decoder.html?invariant="+e,r=0;r<t;r++)n+="&args[]="+encodeURIComponent(arguments[r+1]);n+=" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."; var o=new Error(n);throw o.name="Invariant Violation",o.framesToPop=1,o}e.exports=n},function(e,t,n){var r=n(26),o=n(9)("toStringTag"),i="Arguments"==r(function(){return arguments}()),a=function(e,t){try{return e[t]}catch(e){}};e.exports=function(e){var t,n,u;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(n=a(t=Object(e),o))?n:i?r(t):"Object"==(u=r(t))&&"function"==typeof t.callee?"Arguments":u}},function(e,t,n){var r=n(26);e.exports=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==r(e)?e.split(""):Object(e)}},function(e,t){t.f={}.propertyIsEnumerable},function(e,t,n){"use strict";var r={};e.exports=r},function(e,t,n){"use strict";var r=function(e,t,n,r,o,i,a,u){if(!e){var s;if(void 0===t)s=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var c=[n,r,o,i,a,u],l=0;s=new Error(t.replace(/%s/g,function(){return c[l++]})),s.name="Invariant Violation"}throw s.framesToPop=1,s}};e.exports=r},function(e,t,n){function r(e){if("string"==typeof e||o(e))return e;var t=e+"";return"0"==t&&1/e==-i?"-0":t}var o=n(103),i=1/0;e.exports=r},function(e,t){function n(e,t){return e===t||e!==e&&t!==t}e.exports=n},function(e,t,n){function r(e){return null!=e&&i(e.length)&&!o(e)}var o=n(153),i=n(154);e.exports=r},function(e,t,n){"use strict";function r(e){return"button"===e||"input"===e||"select"===e||"textarea"===e}function o(e,t,n){switch(e){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":return!(!n.disabled||!r(t));default:return!1}}var i=n(7),a=n(160),u=n(161),s=n(165),c=n(248),l=n(249),f=(n(2),{}),p=null,d=function(e,t){e&&(u.executeDispatchesInOrder(e,t),e.isPersistent()||e.constructor.release(e))},h=function(e){return d(e,!0)},v=function(e){return d(e,!1)},m=function(e){return"."+e._rootNodeID},y={injection:{injectEventPluginOrder:a.injectEventPluginOrder,injectEventPluginsByName:a.injectEventPluginsByName},putListener:function(e,t,n){"function"!=typeof n?i("94",t,typeof n):void 0;var r=m(e),o=f[t]||(f[t]={});o[r]=n;var u=a.registrationNameModules[t];u&&u.didPutListener&&u.didPutListener(e,t,n)},getListener:function(e,t){var n=f[t];if(o(t,e._currentElement.type,e._currentElement.props))return null;var r=m(e);return n&&n[r]},deleteListener:function(e,t){var n=a.registrationNameModules[t];n&&n.willDeleteListener&&n.willDeleteListener(e,t);var r=f[t];if(r){var o=m(e);delete r[o]}},deleteAllListeners:function(e){var t=m(e);for(var n in f)if(f.hasOwnProperty(n)&&f[n][t]){var r=a.registrationNameModules[n];r&&r.willDeleteListener&&r.willDeleteListener(e,n),delete f[n][t]}},extractEvents:function(e,t,n,r){for(var o,i=a.plugins,u=0;u<i.length;u++){var s=i[u];if(s){var l=s.extractEvents(e,t,n,r);l&&(o=c(o,l))}}return o},enqueueEvents:function(e){e&&(p=c(p,e))},processEventQueue:function(e){var t=p;p=null,e?l(t,h):l(t,v),p?i("95"):void 0,s.rethrowCaughtError()},__purge:function(){f={}},__getListenerBank:function(){return f}};e.exports=y},function(e,t,n){"use strict";function r(e,t,n){var r=t.dispatchConfig.phasedRegistrationNames[n];return y(e,r)}function o(e,t,n){var o=r(e,n,t);o&&(n._dispatchListeners=v(n._dispatchListeners,o),n._dispatchInstances=v(n._dispatchInstances,e))}function i(e){e&&e.dispatchConfig.phasedRegistrationNames&&h.traverseTwoPhase(e._targetInst,o,e)}function a(e){if(e&&e.dispatchConfig.phasedRegistrationNames){var t=e._targetInst,n=t?h.getParentInstance(t):null;h.traverseTwoPhase(n,o,e)}}function u(e,t,n){if(n&&n.dispatchConfig.registrationName){var r=n.dispatchConfig.registrationName,o=y(e,r);o&&(n._dispatchListeners=v(n._dispatchListeners,o),n._dispatchInstances=v(n._dispatchInstances,e))}}function s(e){e&&e.dispatchConfig.registrationName&&u(e._targetInst,null,e)}function c(e){m(e,i)}function l(e){m(e,a)}function f(e,t,n,r){h.traverseEnterLeave(n,r,u,e,t)}function p(e){m(e,s)}var d=n(81),h=n(161),v=n(248),m=n(249),y=(n(5),d.getListener),g={accumulateTwoPhaseDispatches:c,accumulateTwoPhaseDispatchesSkipTarget:l,accumulateDirectDispatches:p,accumulateEnterLeaveDispatches:f};e.exports=g},function(e,t){"use strict";var n={remove:function(e){e._reactInternalInstance=void 0},get:function(e){return e._reactInternalInstance},has:function(e){return void 0!==e._reactInternalInstance},set:function(e,t){e._reactInternalInstance=t}};e.exports=n},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(41),i=n(170),a={view:function(e){if(e.view)return e.view;var t=i(e);if(t.window===t)return t;var n=t.ownerDocument;return n?n.defaultView||n.parentWindow:window},detail:function(e){return e.detail||0}};o.augmentClass(r,a),e.exports=r},function(e,t,n){var r=n(23),o=n(15),i=n(55);e.exports=function(e){return function(t,n,a){var u,s=r(t),c=o(s.length),l=i(a,c);if(e&&n!=n){for(;c>l;)if(u=s[l++],u!=u)return!0}else for(;c>l;l++)if((e||l in s)&&s[l]===n)return e||l||0;return!e&&-1}}},function(e,t,n){"use strict";var r=n(4),o=n(1),i=n(21),a=n(53),u=n(43),s=n(61),c=n(48),l=n(8),f=n(6),p=n(91),d=n(63),h=n(121);e.exports=function(e,t,n,v,m,y){var g=r[e],b=g,_=m?"set":"add",x=b&&b.prototype,E={},w=function(e){var t=x[e];i(x,e,"delete"==e?function(e){return!(y&&!l(e))&&t.call(this,0===e?0:e)}:"has"==e?function(e){return!(y&&!l(e))&&t.call(this,0===e?0:e)}:"get"==e?function(e){return y&&!l(e)?void 0:t.call(this,0===e?0:e)}:"add"==e?function(e){return t.call(this,0===e?0:e),this}:function(e,n){return t.call(this,0===e?0:e,n),this})};if("function"==typeof b&&(y||x.forEach&&!f(function(){(new b).entries().next()}))){var S=new b,C=S[_](y?{}:-0,1)!=S,P=f(function(){S.has(1)}),O=p(function(e){new b(e)}),T=!y&&f(function(){for(var e=new b,t=5;t--;)e[_](t,t);return!e.has(-0)});O||(b=t(function(t,n){c(t,b,e);var r=h(new g,t,b);return void 0!=n&&s(n,m,r[_],r),r}),b.prototype=x,x.constructor=b),(P||T)&&(w("delete"),w("has"),m&&w("get")),(T||C)&&w(_),y&&x.clear&&delete x.clear}else b=v.getConstructor(t,e,m,_),a(b.prototype,n),u.NEED=!0;return d(b,e),E[e]=b,o(o.G+o.W+o.F*(b!=g),E),y||v.setStrong(b,e,m),b}},function(e,t,n){"use strict";var r=n(20),o=n(21),i=n(6),a=n(27),u=n(9);e.exports=function(e,t,n){var s=u(e),c=n(a,s,""[e]),l=c[0],f=c[1];i(function(){var t={};return t[s]=function(){return 7},7!=""[e](t)})&&(o(String.prototype,e,l),r(RegExp.prototype,s,2==t?function(e,t){return f.call(e,this,t)}:function(e){return f.call(e,this)}))}},function(e,t,n){"use strict";var r=n(3);e.exports=function(){var e=r(this),t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t}},function(e,t){e.exports=function(e,t,n){var r=void 0===n;switch(t.length){case 0:return r?e():e.call(n);case 1:return r?e(t[0]):e.call(n,t[0]);case 2:return r?e(t[0],t[1]):e.call(n,t[0],t[1]);case 3:return r?e(t[0],t[1],t[2]):e.call(n,t[0],t[1],t[2]);case 4:return r?e(t[0],t[1],t[2],t[3]):e.call(n,t[0],t[1],t[2],t[3])}return e.apply(n,t)}},function(e,t,n){var r=n(8),o=n(26),i=n(9)("match");e.exports=function(e){var t;return r(e)&&(void 0!==(t=e[i])?!!t:"RegExp"==o(e))}},function(e,t,n){var r=n(9)("iterator"),o=!1;try{var i=[7][r]();i.return=function(){o=!0},Array.from(i,function(){throw 2})}catch(e){}e.exports=function(e,t){if(!t&&!o)return!1;var n=!1;try{var i=[7],a=i[r]();a.next=function(){return{done:n=!0}},i[r]=function(){return a},e(i)}catch(e){}return n}},function(e,t,n){e.exports=n(49)||!n(6)(function(){var e=Math.random();__defineSetter__.call(null,e,function(){}),delete n(4)[e]})},function(e,t){t.f=Object.getOwnPropertySymbols},function(e,t,n){var r=n(4),o="__core-js_shared__",i=r[o]||(r[o]={});e.exports=function(e){return i[e]||(i[e]={})}},function(e,t,n){for(var r,o=n(4),i=n(20),a=n(56),u=a("typed_array"),s=a("view"),c=!(!o.ArrayBuffer||!o.DataView),l=c,f=0,p=9,d="Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array".split(",");f<p;)(r=o[d[f++]])?(i(r.prototype,u,!0),i(r.prototype,s,!0)):l=!1;e.exports={ABV:c,CONSTR:l,TYPED:u,VIEW:s}},function(e,t,n){function r(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}var o=n(539),i=n(540),a=n(541),u=n(542),s=n(543);r.prototype.clear=o,r.prototype.delete=i,r.prototype.get=a,r.prototype.has=u,r.prototype.set=s,e.exports=r},function(e,t,n){var r=n(35),o=r.Symbol;e.exports=o},function(e,t,n){function r(e,t){for(var n=e.length;n--;)if(o(e[n][0],t))return n;return-1}var o=n(79);e.exports=r},function(e,t,n){function r(e,t,n){"__proto__"==t&&o?o(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}var o=n(223);e.exports=r},function(e,t,n){function r(e,t){var n=e.__data__;return o(t)?n["string"==typeof t?"string":"hash"]:n.map}var o=n(537);e.exports=r},function(e,t,n){var r=n(57),o=r(Object,"create");e.exports=o},function(e,t,n){function r(e){if(!a(e)||o(e)!=u)return!1;var t=i(e);if(null===t)return!0;var n=f.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&l.call(n)==p}var o=n(65),i=n(226),a=n(58),u="[object Object]",s=Function.prototype,c=Object.prototype,l=s.toString,f=c.hasOwnProperty,p=l.call(Object);e.exports=r},function(e,t,n){function r(e){return"symbol"==typeof e||i(e)&&o(e)==a}var o=n(65),i=n(58),a="[object Symbol]";e.exports=r},function(e,t,n){function r(e){return a(e)?o(e,c):u(e)?[e]:i(s(l(e)))}var o=n(214),i=n(222),a=n(30),u=n(103),s=n(231),c=n(78),l=n(235);e.exports=r},function(e,t,n){"use strict";function r(e){return Object.prototype.hasOwnProperty.call(e,v)||(e[v]=d++,f[e[v]]={}),f[e[v]]}var o,i=n(10),a=n(160),u=n(613),s=n(247),c=n(646),l=n(171),f={},p=!1,d=0,h={topAbort:"abort",topAnimationEnd:c("animationend")||"animationend",topAnimationIteration:c("animationiteration")||"animationiteration",topAnimationStart:c("animationstart")||"animationstart",topBlur:"blur",topCanPlay:"canplay",topCanPlayThrough:"canplaythrough",topChange:"change",topClick:"click",topCompositionEnd:"compositionend",topCompositionStart:"compositionstart",topCompositionUpdate:"compositionupdate",topContextMenu:"contextmenu",topCopy:"copy",topCut:"cut",topDoubleClick:"dblclick",topDrag:"drag",topDragEnd:"dragend",topDragEnter:"dragenter",topDragExit:"dragexit",topDragLeave:"dragleave",topDragOver:"dragover",topDragStart:"dragstart",topDrop:"drop",topDurationChange:"durationchange",topEmptied:"emptied",topEncrypted:"encrypted",topEnded:"ended",topError:"error",topFocus:"focus",topInput:"input",topKeyDown:"keydown",topKeyPress:"keypress",topKeyUp:"keyup",topLoadedData:"loadeddata",topLoadedMetadata:"loadedmetadata",topLoadStart:"loadstart",topMouseDown:"mousedown",topMouseMove:"mousemove",topMouseOut:"mouseout",topMouseOver:"mouseover",topMouseUp:"mouseup",topPaste:"paste",topPause:"pause",topPlay:"play",topPlaying:"playing",topProgress:"progress",topRateChange:"ratechange",topScroll:"scroll",topSeeked:"seeked",topSeeking:"seeking",topSelectionChange:"selectionchange",topStalled:"stalled",topSuspend:"suspend",topTextInput:"textInput",topTimeUpdate:"timeupdate",topTouchCancel:"touchcancel",topTouchEnd:"touchend",topTouchMove:"touchmove",topTouchStart:"touchstart",topTransitionEnd:c("transitionend")||"transitionend",topVolumeChange:"volumechange",topWaiting:"waiting",topWheel:"wheel"},v="_reactListenersID"+String(Math.random()).slice(2),m=i({},u,{ReactEventListener:null,injection:{injectReactEventListener:function(e){e.setHandleTopLevel(m.handleTopLevel),m.ReactEventListener=e}},setEnabled:function(e){m.ReactEventListener&&m.ReactEventListener.setEnabled(e)},isEnabled:function(){return!(!m.ReactEventListener||!m.ReactEventListener.isEnabled())},listenTo:function(e,t){for(var n=t,o=r(n),i=a.registrationNameDependencies[e],u=0;u<i.length;u++){var s=i[u];o.hasOwnProperty(s)&&o[s]||("topWheel"===s?l("wheel")?m.ReactEventListener.trapBubbledEvent("topWheel","wheel",n):l("mousewheel")?m.ReactEventListener.trapBubbledEvent("topWheel","mousewheel",n):m.ReactEventListener.trapBubbledEvent("topWheel","DOMMouseScroll",n):"topScroll"===s?l("scroll",!0)?m.ReactEventListener.trapCapturedEvent("topScroll","scroll",n):m.ReactEventListener.trapBubbledEvent("topScroll","scroll",m.ReactEventListener.WINDOW_HANDLE):"topFocus"===s||"topBlur"===s?(l("focus",!0)?(m.ReactEventListener.trapCapturedEvent("topFocus","focus",n),m.ReactEventListener.trapCapturedEvent("topBlur","blur",n)):l("focusin")&&(m.ReactEventListener.trapBubbledEvent("topFocus","focusin",n),m.ReactEventListener.trapBubbledEvent("topBlur","focusout",n)),o.topBlur=!0,o.topFocus=!0):h.hasOwnProperty(s)&&m.ReactEventListener.trapBubbledEvent(s,h[s],n),o[s]=!0)}},trapBubbledEvent:function(e,t,n){return m.ReactEventListener.trapBubbledEvent(e,t,n)},trapCapturedEvent:function(e,t,n){return m.ReactEventListener.trapCapturedEvent(e,t,n)},supportsEventPageXY:function(){if(!document.createEvent)return!1;var e=document.createEvent("MouseEvent");return null!=e&&"pageX"in e},ensureScrollValueMonitoring:function(){if(void 0===o&&(o=m.supportsEventPageXY()),!o&&!p){var e=s.refreshScrollValues;m.ReactEventListener.monitorScrollValue(e),p=!0}}});e.exports=m},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(84),i=n(247),a=n(169),u={screenX:null,screenY:null,clientX:null,clientY:null,ctrlKey:null,shiftKey:null,altKey:null,metaKey:null,getModifierState:a,button:function(e){var t=e.button;return"which"in e?t:2===t?2:4===t?1:0},buttons:null,relatedTarget:function(e){return e.relatedTarget||(e.fromElement===e.srcElement?e.toElement:e.fromElement)},pageX:function(e){return"pageX"in e?e.pageX:e.clientX+i.currentScrollLeft},pageY:function(e){return"pageY"in e?e.pageY:e.clientY+i.currentScrollTop}};o.augmentClass(r,u),e.exports=r},function(e,t,n){"use strict";var r=n(7),o=(n(2),{}),i={reinitializeTransaction:function(){this.transactionWrappers=this.getTransactionWrappers(),this.wrapperInitData?this.wrapperInitData.length=0:this.wrapperInitData=[],this._isInTransaction=!1},_isInTransaction:!1,getTransactionWrappers:null,isInTransaction:function(){return!!this._isInTransaction},perform:function(e,t,n,o,i,a,u,s){this.isInTransaction()?r("27"):void 0;var c,l;try{this._isInTransaction=!0,c=!0,this.initializeAll(0),l=e.call(t,n,o,i,a,u,s),c=!1}finally{try{if(c)try{this.closeAll(0)}catch(e){}else this.closeAll(0)}finally{this._isInTransaction=!1}}return l},initializeAll:function(e){for(var t=this.transactionWrappers,n=e;n<t.length;n++){var r=t[n];try{this.wrapperInitData[n]=o,this.wrapperInitData[n]=r.initialize?r.initialize.call(this):null}finally{if(this.wrapperInitData[n]===o)try{this.initializeAll(n+1)}catch(e){}}}},closeAll:function(e){this.isInTransaction()?void 0:r("28");for(var t=this.transactionWrappers,n=e;n<t.length;n++){var i,a=t[n],u=this.wrapperInitData[n];try{i=!0,u!==o&&a.close&&a.close.call(this,u),i=!1}finally{if(i)try{this.closeAll(n+1)}catch(e){}}}this.wrapperInitData.length=0}};e.exports=i},function(e,t){"use strict";function n(e){var t=""+e,n=o.exec(t);if(!n)return t;var r,i="",a=0,u=0;for(a=n.index;a<t.length;a++){switch(t.charCodeAt(a)){case 34:r="&quot;";break;case 38:r="&amp;";break;case 39:r="&#x27;";break;case 60:r="&lt;";break;case 62:r="&gt;";break;default:continue}u!==a&&(i+=t.substring(u,a)),u=a+1,i+=r}return u!==a?i+t.substring(u,a):i}function r(e){return"boolean"==typeof e||"number"==typeof e?""+e:n(e)}var o=/["'&<>]/;e.exports=r},function(e,t,n){"use strict";var r,o=n(18),i=n(159),a=/^[ \r\n\t\f]/,u=/<(!--|link|noscript|meta|script|style)[ \r\n\t\f\/>]/,s=n(167),c=s(function(e,t){if(e.namespaceURI!==i.svg||"innerHTML"in e)e.innerHTML=t;else{r=r||document.createElement("div"),r.innerHTML="<svg>"+t+"</svg>";for(var n=r.firstChild;n.firstChild;)e.appendChild(n.firstChild)}});if(o.canUseDOM){var l=document.createElement("div");l.innerHTML=" ",""===l.innerHTML&&(c=function(e,t){if(e.parentNode&&e.parentNode.replaceChild(e,e),a.test(t)||"<"===t[0]&&u.test(t)){e.innerHTML=String.fromCharCode(65279)+t;var n=e.firstChild;1===n.data.length?e.removeChild(n):n.deleteData(0,1)}else e.innerHTML=t}),l=null}e.exports=c},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0}),t.values=t.untouch=t.unregisterField=t.touch=t.SubmissionError=t.submit=t.stopSubmit=t.stopAsyncValidation=t.startSubmit=t.startAsyncValidation=t.setSubmitSucceeded=t.setSubmitFailed=t.reset=t.registerField=t.reduxForm=t.reducer=t.propTypes=t.hasSubmitFailed=t.hasSubmitSucceeded=t.isSubmitting=t.isValid=t.isPristine=t.isInvalid=t.isDirty=t.initialize=t.getFormSubmitErrors=t.getFormAsyncErrors=t.getFormSyncErrors=t.getFormValues=t.formValueSelector=t.focus=t.FormSection=t.Form=t.FieldArray=t.Fields=t.Field=t.destroy=t.change=t.autofill=t.blur=t.arrayUnshift=t.arraySwap=t.arraySplice=t.arrayShift=t.arrayRemoveAll=t.arrayRemove=t.arrayPush=t.arrayPop=t.arrayMove=t.arrayInsert=t.actionTypes=void 0;var o=n(674),i=r(o),a=n(47),u=r(a),s=(0,i.default)(u.default),c=s.actionTypes,l=s.arrayInsert,f=s.arrayMove,p=s.arrayPop,d=s.arrayPush,h=s.arrayRemove,v=s.arrayRemoveAll,m=s.arrayShift,y=s.arraySplice,g=s.arraySwap,b=s.arrayUnshift,_=s.blur,x=s.autofill,E=s.change,w=s.destroy,S=s.Field,C=s.Fields,P=s.FieldArray,O=s.Form,T=s.FormSection,k=s.focus,A=s.formValueSelector,R=s.getFormValues,M=s.getFormSyncErrors,I=s.getFormAsyncErrors,N=s.getFormSubmitErrors,j=s.initialize,F=s.isDirty,D=s.isInvalid,U=s.isPristine,L=s.isValid,V=s.isSubmitting,W=s.hasSubmitSucceeded,B=s.hasSubmitFailed,q=s.propTypes,z=s.reducer,H=s.reduxForm,Y=s.registerField,K=s.reset,G=s.setSubmitFailed,$=s.setSubmitSucceeded,X=s.startAsyncValidation,Q=s.startSubmit,J=s.stopAsyncValidation,Z=s.stopSubmit,ee=s.submit,te=s.SubmissionError,ne=s.touch,re=s.unregisterField,oe=s.untouch,ie=s.values;t.actionTypes=c,t.arrayInsert=l,t.arrayMove=f,t.arrayPop=p,t.arrayPush=d,t.arrayRemove=h,t.arrayRemoveAll=v,t.arrayShift=m,t.arraySplice=y,t.arraySwap=g,t.arrayUnshift=b,t.blur=_,t.autofill=x,t.change=E,t.destroy=w,t.Field=S,t.Fields=C,t.FieldArray=P,t.Form=O,t.FormSection=T,t.focus=k,t.formValueSelector=A,t.getFormValues=R,t.getFormSyncErrors=M,t.getFormAsyncErrors=I,t.getFormSubmitErrors=N,t.initialize=j,t.isDirty=F,t.isInvalid=D,t.isPristine=U,t.isValid=L,t.isSubmitting=V,t.hasSubmitSucceeded=W,t.hasSubmitFailed=B,t.propTypes=q,t.reducer=z,t.reduxForm=H,t.registerField=Y,t.reset=K,t.setSubmitFailed=G,t.setSubmitSucceeded=$,t.startAsyncValidation=X,t.startSubmit=Q,t.stopAsyncValidation=J,t.stopSubmit=Z,t.submit=ee,t.SubmissionError=te,t.touch=ne,t.unregisterField=re,t.untouch=oe,t.values=ie},function(e,t){"use strict";function n(e,t){var n=e._reduxForm.sectionPrefix;return!n||r.test(t)?t:n+"."+t}Object.defineProperty(t,"__esModule",{value:!0}),t.default=n;var r=/\[\d+\]$/},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}t.__esModule=!0,t.compose=t.applyMiddleware=t.bindActionCreators=t.combineReducers=t.createStore=void 0;var o=n(272),i=r(o),a=n(707),u=r(a),s=n(706),c=r(s),l=n(705),f=r(l),p=n(271),d=r(p),h=n(273);r(h);t.createStore=i.default,t.combineReducers=u.default,t.bindActionCreators=c.default,t.applyMiddleware=f.default,t.compose=d.default},function(e,t){e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children=[],e.webpackPolyfill=1),e}},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(e){var t={};return e.firstName||(t.firstName="Required"),e.lastName||(t.lastName="Required"),e.email?/^[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,4}$/i.test(e.email)||(t.email="Invalid email address"):t.email="Required",e.sex||(t.sex="Required"),e.favoriteColor||(t.favoriteColor="Required"),t};t.default=n},function(e,t,n){"use strict";var r=n(16),o=n(55),i=n(15);e.exports=function(e){for(var t=r(this),n=i(t.length),a=arguments.length,u=o(a>1?arguments[1]:void 0,n),s=a>2?arguments[2]:void 0,c=void 0===s?n:o(s,n);c>u;)t[u++]=e;return t}},function(e,t,n){"use strict";var r=n(12),o=n(44);e.exports=function(e,t,n){t in e?r.f(e,t,o(0,n)):e[t]=n}},function(e,t,n){var r=n(8),o=n(4).document,i=r(o)&&r(o.createElement);e.exports=function(e){return i?o.createElement(e):{}}},function(e,t){e.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(e,t,n){var r=n(9)("match");e.exports=function(e){var t=/./;try{"/./"[e](t)}catch(n){try{return t[r]=!1,!"/./"[e](t)}catch(e){}}return!0}},function(e,t,n){e.exports=n(4).document&&document.documentElement},function(e,t,n){var r=n(8),o=n(129).set;e.exports=function(e,t,n){var i,a=t.constructor;return a!==n&&"function"==typeof a&&(i=a.prototype)!==n.prototype&&r(i)&&o&&o(e,i),e}},function(e,t,n){var r=n(62),o=n(9)("iterator"),i=Array.prototype;e.exports=function(e){return void 0!==e&&(r.Array===e||i[o]===e)}},function(e,t,n){var r=n(26);e.exports=Array.isArray||function(e){return"Array"==r(e)}},function(e,t,n){"use strict";var r=n(50),o=n(44),i=n(63),a={};n(20)(a,n(9)("iterator"),function(){return this}),e.exports=function(e,t,n){e.prototype=r(a,{next:o(1,n)}),i(e,t+" Iterator")}},function(e,t,n){"use strict";var r=n(49),o=n(1),i=n(21),a=n(20),u=n(17),s=n(62),c=n(124),l=n(63),f=n(25),p=n(9)("iterator"),d=!([].keys&&"next"in[].keys()),h="@@iterator",v="keys",m="values",y=function(){return this};e.exports=function(e,t,n,g,b,_,x){c(n,t,g);var E,w,S,C=function(e){if(!d&&e in k)return k[e];switch(e){case v:return function(){return new n(this,e)};case m:return function(){return new n(this,e)}}return function(){return new n(this,e)}},P=t+" Iterator",O=b==m,T=!1,k=e.prototype,A=k[p]||k[h]||b&&k[b],R=A||C(b),M=b?O?C("entries"):R:void 0,I="Array"==t?k.entries||A:A;if(I&&(S=f(I.call(new e)),S!==Object.prototype&&(l(S,P,!0),r||u(S,p)||a(S,p,y))),O&&A&&A.name!==m&&(T=!0,R=function(){return A.call(this)}),r&&!x||!d&&!T&&k[p]||a(k,p,R),s[t]=R,s[P]=y,b)if(E={values:O?R:C(m),keys:_?R:C(v),entries:M},x)for(w in E)w in k||i(k,w,E[w]);else o(o.P+o.F*(d||T),t,E);return E}},function(e,t){var n=Math.expm1;e.exports=!n||n(10)>22025.465794806718||n(10)<22025.465794806718||n(-2e-17)!=-2e-17?function(e){return 0==(e=+e)?e:e>-1e-6&&e<1e-6?e+e*e/2:Math.exp(e)-1}:n},function(e,t){e.exports=Math.sign||function(e){return 0==(e=+e)||e!=e?e:e<0?-1:1}},function(e,t,n){var r=n(4),o=n(136).set,i=r.MutationObserver||r.WebKitMutationObserver,a=r.process,u=r.Promise,s="process"==n(26)(a);e.exports=function(){var e,t,n,c=function(){var r,o;for(s&&(r=a.domain)&&r.exit();e;){o=e.fn,e=e.next;try{o()}catch(r){throw e?n():t=void 0,r}}t=void 0,r&&r.enter()};if(s)n=function(){a.nextTick(c)};else if(i){var l=!0,f=document.createTextNode("");new i(c).observe(f,{characterData:!0}),n=function(){f.data=l=!l}}else if(u&&u.resolve){var p=u.resolve();n=function(){p.then(c)}}else n=function(){o.call(r,c)};return function(r){var o={fn:r,next:void 0};t&&(t.next=o),e||(e=o,n()),t=o}}},function(e,t,n){var r=n(8),o=n(3),i=function(e,t){if(o(e),!r(t)&&null!==t)throw TypeError(t+": can't set as prototype!")};e.exports={set:Object.setPrototypeOf||("__proto__"in{}?function(e,t,r){try{r=n(38)(Function.call,n(24).f(Object.prototype,"__proto__").set,2),r(e,[]),t=!(e instanceof Array)}catch(e){t=!0}return function(e,n){return i(e,n),t?e.__proto__=n:r(e,n),e}}({},!1):void 0),check:i}},function(e,t,n){var r=n(94)("keys"),o=n(56);e.exports=function(e){return r[e]||(r[e]=o(e))}},function(e,t,n){var r=n(3),o=n(19),i=n(9)("species");e.exports=function(e,t){var n,a=r(e).constructor;return void 0===a||void 0==(n=r(a)[i])?t:o(n)}},function(e,t,n){var r=n(45),o=n(27);e.exports=function(e){return function(t,n){var i,a,u=String(o(t)),s=r(n),c=u.length;return s<0||s>=c?e?"":void 0:(i=u.charCodeAt(s),i<55296||i>56319||s+1===c||(a=u.charCodeAt(s+1))<56320||a>57343?e?u.charAt(s):i:e?u.slice(s,s+2):(i-55296<<10)+(a-56320)+65536)}}},function(e,t,n){var r=n(90),o=n(27);e.exports=function(e,t,n){if(r(t))throw TypeError("String#"+n+" doesn't accept regex!");return String(o(e))}},function(e,t,n){"use strict";var r=n(45),o=n(27);e.exports=function(e){var t=String(o(this)),n="",i=r(e);if(i<0||i==1/0)throw RangeError("Count can't be negative");for(;i>0;(i>>>=1)&&(t+=t))1&i&&(n+=t);return n}},function(e,t){e.exports="\t\n\v\f\r   ᠎              \u2028\u2029\ufeff"},function(e,t,n){var r,o,i,a=n(38),u=n(89),s=n(120),c=n(117),l=n(4),f=l.process,p=l.setImmediate,d=l.clearImmediate,h=l.MessageChannel,v=0,m={},y="onreadystatechange",g=function(){var e=+this;if(m.hasOwnProperty(e)){var t=m[e];delete m[e],t()}},b=function(e){g.call(e.data)};p&&d||(p=function(e){for(var t=[],n=1;arguments.length>n;)t.push(arguments[n++]);return m[++v]=function(){u("function"==typeof e?e:Function(e),t)},r(v),v},d=function(e){delete m[e]},"process"==n(26)(f)?r=function(e){f.nextTick(a(g,e,1))}:h?(o=new h,i=o.port2,o.port1.onmessage=b,r=a(i.postMessage,i,1)):l.addEventListener&&"function"==typeof postMessage&&!l.importScripts?(r=function(e){l.postMessage(e+"","*")},l.addEventListener("message",b,!1)):r=y in c("script")?function(e){s.appendChild(c("script"))[y]=function(){s.removeChild(this),g.call(e)}}:function(e){setTimeout(a(g,e,1),0)}),e.exports={set:p,clear:d}},function(e,t,n){"use strict";var r=n(4),o=n(11),i=n(49),a=n(95),u=n(20),s=n(53),c=n(6),l=n(48),f=n(45),p=n(15),d=n(51).f,h=n(12).f,v=n(115),m=n(63),y="ArrayBuffer",g="DataView",b="prototype",_="Wrong length!",x="Wrong index!",E=r[y],w=r[g],S=r.Math,C=r.RangeError,P=r.Infinity,O=E,T=S.abs,k=S.pow,A=S.floor,R=S.log,M=S.LN2,I="buffer",N="byteLength",j="byteOffset",F=o?"_b":I,D=o?"_l":N,U=o?"_o":j,L=function(e,t,n){var r,o,i,a=Array(n),u=8*n-t-1,s=(1<<u)-1,c=s>>1,l=23===t?k(2,-24)-k(2,-77):0,f=0,p=e<0||0===e&&1/e<0?1:0;for(e=T(e),e!=e||e===P?(o=e!=e?1:0,r=s):(r=A(R(e)/M),e*(i=k(2,-r))<1&&(r--,i*=2),e+=r+c>=1?l/i:l*k(2,1-c),e*i>=2&&(r++,i/=2),r+c>=s?(o=0,r=s):r+c>=1?(o=(e*i-1)*k(2,t),r+=c):(o=e*k(2,c-1)*k(2,t),r=0));t>=8;a[f++]=255&o,o/=256,t-=8);for(r=r<<t|o,u+=t;u>0;a[f++]=255&r,r/=256,u-=8);return a[--f]|=128*p,a},V=function(e,t,n){var r,o=8*n-t-1,i=(1<<o)-1,a=i>>1,u=o-7,s=n-1,c=e[s--],l=127&c;for(c>>=7;u>0;l=256*l+e[s],s--,u-=8);for(r=l&(1<<-u)-1,l>>=-u,u+=t;u>0;r=256*r+e[s],s--,u-=8);if(0===l)l=1-a;else{if(l===i)return r?NaN:c?-P:P;r+=k(2,t),l-=a}return(c?-1:1)*r*k(2,l-t)},W=function(e){return e[3]<<24|e[2]<<16|e[1]<<8|e[0]},B=function(e){return[255&e]},q=function(e){return[255&e,e>>8&255]},z=function(e){return[255&e,e>>8&255,e>>16&255,e>>24&255]},H=function(e){return L(e,52,8)},Y=function(e){return L(e,23,4)},K=function(e,t,n){h(e[b],t,{get:function(){return this[n]}})},G=function(e,t,n,r){var o=+n,i=f(o);if(o!=i||i<0||i+t>e[D])throw C(x);var a=e[F]._b,u=i+e[U],s=a.slice(u,u+t);return r?s:s.reverse()},$=function(e,t,n,r,o,i){var a=+n,u=f(a);if(a!=u||u<0||u+t>e[D])throw C(x);for(var s=e[F]._b,c=u+e[U],l=r(+o),p=0;p<t;p++)s[c+p]=l[i?p:t-p-1]},X=function(e,t){l(e,E,y);var n=+t,r=p(n);if(n!=r)throw C(_);return r};if(a.ABV){if(!c(function(){new E})||!c(function(){new E(.5)})){E=function(e){return new O(X(this,e))};for(var Q,J=E[b]=O[b],Z=d(O),ee=0;Z.length>ee;)(Q=Z[ee++])in E||u(E,Q,O[Q]);i||(J.constructor=E)}var te=new w(new E(2)),ne=w[b].setInt8;te.setInt8(0,2147483648),te.setInt8(1,2147483649),!te.getInt8(0)&&te.getInt8(1)||s(w[b],{setInt8:function(e,t){ne.call(this,e,t<<24>>24)},setUint8:function(e,t){ne.call(this,e,t<<24>>24)}},!0)}else E=function(e){var t=X(this,e);this._b=v.call(Array(t),0),this[D]=t},w=function(e,t,n){l(this,w,g),l(e,E,g);var r=e[D],o=f(t);if(o<0||o>r)throw C("Wrong offset!");if(n=void 0===n?r-o:p(n),o+n>r)throw C(_);this[F]=e,this[U]=o,this[D]=n},o&&(K(E,N,"_l"),K(w,I,"_b"),K(w,N,"_l"),K(w,j,"_o")),s(w[b],{getInt8:function(e){return G(this,1,e)[0]<<24>>24},getUint8:function(e){return G(this,1,e)[0]},getInt16:function(e){var t=G(this,2,e,arguments[1]);return(t[1]<<8|t[0])<<16>>16},getUint16:function(e){var t=G(this,2,e,arguments[1]);return t[1]<<8|t[0]},getInt32:function(e){return W(G(this,4,e,arguments[1]))},getUint32:function(e){return W(G(this,4,e,arguments[1]))>>>0},getFloat32:function(e){return V(G(this,4,e,arguments[1]),23,4)},getFloat64:function(e){return V(G(this,8,e,arguments[1]),52,8)},setInt8:function(e,t){$(this,1,e,B,t)},setUint8:function(e,t){$(this,1,e,B,t)},setInt16:function(e,t){$(this,2,e,q,t,arguments[2])},setUint16:function(e,t){$(this,2,e,q,t,arguments[2])},setInt32:function(e,t){$(this,4,e,z,t,arguments[2])},setUint32:function(e,t){$(this,4,e,z,t,arguments[2])},setFloat32:function(e,t){$(this,4,e,Y,t,arguments[2])},setFloat64:function(e,t){$(this,8,e,H,t,arguments[2])}});m(E,y),m(w,g),u(w[b],a.VIEW,!0),t[y]=E,t[g]=w},function(e,t,n){var r=n(4),o=n(37),i=n(49),a=n(203),u=n(12).f;e.exports=function(e){var t=o.Symbol||(o.Symbol=i?{}:r.Symbol||{});"_"==e.charAt(0)||e in t||u(t,e,{value:a.f(e)})}},function(e,t,n){var r=n(73),o=n(9)("iterator"),i=n(62);e.exports=n(37).getIteratorMethod=function(e){if(void 0!=e)return e[o]||e["@@iterator"]||i[r(e)]}},function(e,t,n){"use strict";var r=n(60),o=n(191),i=n(62),a=n(23);e.exports=n(125)(Array,"Array",function(e,t){this._t=a(e),this._i=0,this._k=t},function(){var e=this._t,t=this._k,n=this._i++;return!e||n>=e.length?(this._t=void 0,o(1)):"keys"==t?o(0,n):"values"==t?o(0,e[n]):o(0,[n,e[n]])},"values"),i.Arguments=i.Array,r("keys"),r("values"),r("entries")},function(e,t){"use strict";function n(e,t){return e===t?0!==e||0!==t||1/e===1/t:e!==e&&t!==t}function r(e,t){if(n(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var r=Object.keys(e),i=Object.keys(t);if(r.length!==i.length)return!1;for(var a=0;a<r.length;a++)if(!o.call(t,r[a])||!n(e[r[a]],t[r[a]]))return!1;return!0}var o=Object.prototype.hasOwnProperty;e.exports=r},function(e,t){function n(e){return!!e&&("object"==typeof e||"function"==typeof e)&&"function"==typeof e.then}e.exports=n},function(e,t,n){var r=n(57),o=n(35),i=r(o,"Map");e.exports=i},function(e,t,n){function r(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}var o=n(544),i=n(545),a=n(546),u=n(547),s=n(548);r.prototype.clear=o,r.prototype.delete=i,r.prototype.get=a,r.prototype.has=u,r.prototype.set=s,e.exports=r},function(e,t,n){function r(e){var t=this.__data__=new o(e);this.size=t.size}var o=n(96),i=n(561),a=n(562),u=n(563),s=n(564),c=n(565);r.prototype.clear=i,r.prototype.delete=a,r.prototype.get=u,r.prototype.has=s,r.prototype.set=c,e.exports=r},function(e,t,n){function r(e,t,n,a,u){return e===t||(null==e||null==t||!i(e)&&!i(t)?e!==e&&t!==t:o(e,t,n,a,r,u))}var o=n(495),i=n(58);e.exports=r},function(e,t){function n(e,t){return t=null==t?r:t,!!t&&("number"==typeof e||o.test(e))&&e>-1&&e%1==0&&e<t}var r=9007199254740991,o=/^(?:0|[1-9]\d*)$/;e.exports=n},function(e,t,n){function r(e,t){if(o(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!i(e))||(u.test(e)||!a.test(e)||null!=t&&e in Object(t))}var o=n(30),i=n(103),a=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,u=/^\w*$/;e.exports=r},function(e,t){function n(e){var t=e&&e.constructor,n="function"==typeof t&&t.prototype||r;return e===n}var r=Object.prototype;e.exports=n},function(e,t){function n(e){return e}e.exports=n},function(e,t,n){var r=n(494),o=n(58),i=Object.prototype,a=i.hasOwnProperty,u=i.propertyIsEnumerable,s=r(function(){return arguments}())?r:function(e){return o(e)&&a.call(e,"callee")&&!u.call(e,"callee")};e.exports=s},function(e,t,n){(function(e){var r=n(35),o=n(576),i="object"==typeof t&&t&&!t.nodeType&&t,a=i&&"object"==typeof e&&e&&!e.nodeType&&e,u=a&&a.exports===i,s=u?r.Buffer:void 0,c=s?s.isBuffer:void 0,l=c||o;e.exports=l}).call(t,n(113)(e))},function(e,t,n){function r(e){if(!i(e))return!1;var t=o(e);return t==u||t==s||t==a||t==c}var o=n(65),i=n(46),a="[object AsyncFunction]",u="[object Function]",s="[object GeneratorFunction]",c="[object Proxy]";e.exports=r},function(e,t){function n(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=r}var r=9007199254740991;e.exports=n},function(e,t,n){ var r=n(498),o=n(512),i=n(553),a=i&&i.isTypedArray,u=a?o(a):r;e.exports=u},function(e,t,n){function r(e){return a(e)?o(e):i(e)}var o=n(213),i=n(499),a=n(80);e.exports=r},function(e,t){function n(){throw new Error("setTimeout has not been defined")}function r(){throw new Error("clearTimeout has not been defined")}function o(e){if(l===setTimeout)return setTimeout(e,0);if((l===n||!l)&&setTimeout)return l=setTimeout,setTimeout(e,0);try{return l(e,0)}catch(t){try{return l.call(null,e,0)}catch(t){return l.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===r||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){v&&d&&(v=!1,d.length?h=d.concat(h):m=-1,h.length&&u())}function u(){if(!v){var e=o(a);v=!0;for(var t=h.length;t;){for(d=h,h=[];++m<t;)d&&d[m].run();m=-1,t=h.length}d=null,v=!1,i(e)}}function s(e,t){this.fun=e,this.array=t}function c(){}var l,f,p=e.exports={};!function(){try{l="function"==typeof setTimeout?setTimeout:n}catch(e){l=n}try{f="function"==typeof clearTimeout?clearTimeout:r}catch(e){f=r}}();var d,h=[],v=!1,m=-1;p.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];h.push(new s(e,t)),1!==h.length||v||o(u)},s.prototype.run=function(){this.fun.apply(null,this.array)},p.title="browser",p.browser=!0,p.env={},p.argv=[],p.version="",p.versions={},p.on=c,p.addListener=c,p.once=c,p.off=c,p.removeListener=c,p.removeAllListeners=c,p.emit=c,p.binding=function(e){throw new Error("process.binding is not supported")},p.cwd=function(){return"/"},p.chdir=function(e){throw new Error("process.chdir is not supported")},p.umask=function(){return 0}},function(e,t,n){"use strict";function r(e,t){return Array.isArray(t)&&(t=t[1]),t?t.nextSibling:e.firstChild}function o(e,t,n){l.insertTreeBefore(e,t,n)}function i(e,t,n){Array.isArray(t)?u(e,t[0],t[1],n):v(e,t,n)}function a(e,t){if(Array.isArray(t)){var n=t[1];t=t[0],s(e,t,n),e.removeChild(n)}e.removeChild(t)}function u(e,t,n,r){for(var o=t;;){var i=o.nextSibling;if(v(e,o,r),o===n)break;o=i}}function s(e,t,n){for(;;){var r=t.nextSibling;if(r===n)break;e.removeChild(r)}}function c(e,t,n){var r=e.parentNode,o=e.nextSibling;o===t?n&&v(r,document.createTextNode(n),o):n?(h(o,n),s(r,o,t)):s(r,e,t)}var l=n(66),f=n(590),p=(n(13),n(31),n(167)),d=n(109),h=n(254),v=p(function(e,t,n){e.insertBefore(t,n)}),m=f.dangerouslyReplaceNodeWithMarkup,y={dangerouslyReplaceNodeWithMarkup:m,replaceDelimitedText:c,processUpdates:function(e,t){for(var n=0;n<t.length;n++){var u=t[n];switch(u.type){case"INSERT_MARKUP":o(e,u.content,r(e,u.afterNode));break;case"MOVE_EXISTING":i(e,u.fromNode,r(e,u.afterNode));break;case"SET_MARKUP":d(e,u.content);break;case"TEXT_CONTENT":h(e,u.content);break;case"REMOVE_NODE":a(e,u.fromNode)}}}};e.exports=y},function(e,t){"use strict";var n={html:"http://www.w3.org/1999/xhtml",mathml:"http://www.w3.org/1998/Math/MathML",svg:"http://www.w3.org/2000/svg"};e.exports=n},function(e,t,n){"use strict";function r(){if(u)for(var e in s){var t=s[e],n=u.indexOf(e);if(n>-1?void 0:a("96",e),!c.plugins[n]){t.extractEvents?void 0:a("97",e),c.plugins[n]=t;var r=t.eventTypes;for(var i in r)o(r[i],t,i)?void 0:a("98",i,e)}}}function o(e,t,n){c.eventNameDispatchConfigs.hasOwnProperty(n)?a("99",n):void 0,c.eventNameDispatchConfigs[n]=e;var r=e.phasedRegistrationNames;if(r){for(var o in r)if(r.hasOwnProperty(o)){var u=r[o];i(u,t,n)}return!0}return!!e.registrationName&&(i(e.registrationName,t,n),!0)}function i(e,t,n){c.registrationNameModules[e]?a("100",e):void 0,c.registrationNameModules[e]=t,c.registrationNameDependencies[e]=t.eventTypes[n].dependencies}var a=n(7),u=(n(2),null),s={},c={plugins:[],eventNameDispatchConfigs:{},registrationNameModules:{},registrationNameDependencies:{},possibleRegistrationNames:null,injectEventPluginOrder:function(e){u?a("101"):void 0,u=Array.prototype.slice.call(e),r()},injectEventPluginsByName:function(e){var t=!1;for(var n in e)if(e.hasOwnProperty(n)){var o=e[n];s.hasOwnProperty(n)&&s[n]===o||(s[n]?a("102",n):void 0,s[n]=o,t=!0)}t&&r()},getPluginModuleForEvent:function(e){var t=e.dispatchConfig;if(t.registrationName)return c.registrationNameModules[t.registrationName]||null;if(void 0!==t.phasedRegistrationNames){var n=t.phasedRegistrationNames;for(var r in n)if(n.hasOwnProperty(r)){var o=c.registrationNameModules[n[r]];if(o)return o}}return null},_resetEventPlugins:function(){u=null;for(var e in s)s.hasOwnProperty(e)&&delete s[e];c.plugins.length=0;var t=c.eventNameDispatchConfigs;for(var n in t)t.hasOwnProperty(n)&&delete t[n];var r=c.registrationNameModules;for(var o in r)r.hasOwnProperty(o)&&delete r[o]}};e.exports=c},function(e,t,n){"use strict";function r(e){return"topMouseUp"===e||"topTouchEnd"===e||"topTouchCancel"===e}function o(e){return"topMouseMove"===e||"topTouchMove"===e}function i(e){return"topMouseDown"===e||"topTouchStart"===e}function a(e,t,n,r){var o=e.type||"unknown-event";e.currentTarget=y.getNodeFromInstance(r),t?v.invokeGuardedCallbackWithCatch(o,n,e):v.invokeGuardedCallback(o,n,e),e.currentTarget=null}function u(e,t){var n=e._dispatchListeners,r=e._dispatchInstances;if(Array.isArray(n))for(var o=0;o<n.length&&!e.isPropagationStopped();o++)a(e,t,n[o],r[o]);else n&&a(e,t,n,r);e._dispatchListeners=null,e._dispatchInstances=null}function s(e){var t=e._dispatchListeners,n=e._dispatchInstances;if(Array.isArray(t)){for(var r=0;r<t.length&&!e.isPropagationStopped();r++)if(t[r](e,n[r]))return n[r]}else if(t&&t(e,n))return n;return null}function c(e){var t=s(e);return e._dispatchInstances=null,e._dispatchListeners=null,t}function l(e){var t=e._dispatchListeners,n=e._dispatchInstances;Array.isArray(t)?h("103"):void 0,e.currentTarget=t?y.getNodeFromInstance(n):null;var r=t?t(e):null;return e.currentTarget=null,e._dispatchListeners=null,e._dispatchInstances=null,r}function f(e){return!!e._dispatchListeners}var p,d,h=n(7),v=n(165),m=(n(2),n(5),{injectComponentTree:function(e){p=e},injectTreeTraversal:function(e){d=e}}),y={isEndish:r,isMoveish:o,isStartish:i,executeDirectDispatch:l,executeDispatchesInOrder:u,executeDispatchesInOrderStopAtTrue:c,hasDispatches:f,getInstanceFromNode:function(e){return p.getInstanceFromNode(e)},getNodeFromInstance:function(e){return p.getNodeFromInstance(e)},isAncestor:function(e,t){return d.isAncestor(e,t)},getLowestCommonAncestor:function(e,t){return d.getLowestCommonAncestor(e,t)},getParentInstance:function(e){return d.getParentInstance(e)},traverseTwoPhase:function(e,t,n){return d.traverseTwoPhase(e,t,n)},traverseEnterLeave:function(e,t,n,r,o){return d.traverseEnterLeave(e,t,n,r,o)},injection:m};e.exports=y},function(e,t){"use strict";function n(e){var t=/[=:]/g,n={"=":"=0",":":"=2"},r=(""+e).replace(t,function(e){return n[e]});return"$"+r}function r(e){var t=/(=0|=2)/g,n={"=0":"=","=2":":"},r="."===e[0]&&"$"===e[1]?e.substring(2):e.substring(1);return(""+r).replace(t,function(e){return n[e]})}var o={escape:n,unescape:r};e.exports=o},function(e,t,n){"use strict";function r(e){null!=e.checkedLink&&null!=e.valueLink?u("87"):void 0}function o(e){r(e),null!=e.value||null!=e.onChange?u("88"):void 0}function i(e){r(e),null!=e.checked||null!=e.onChange?u("89"):void 0}function a(e){if(e){var t=e.getName();if(t)return" Check the render method of `"+t+"`."}return""}var u=n(7),s=n(70),c=n(619),l=(n(2),n(5),{button:!0,checkbox:!0,image:!0,hidden:!0,radio:!0,reset:!0,submit:!0}),f={value:function(e,t,n){return!e[t]||l[e.type]||e.onChange||e.readOnly||e.disabled?null:new Error("You provided a `value` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultValue`. Otherwise, set either `onChange` or `readOnly`.")},checked:function(e,t,n){return!e[t]||e.onChange||e.readOnly||e.disabled?null:new Error("You provided a `checked` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultChecked`. Otherwise, set either `onChange` or `readOnly`.")},onChange:s.PropTypes.func},p={},d={checkPropTypes:function(e,t,n){for(var r in f){if(f.hasOwnProperty(r))var o=f[r](t,r,e,"prop",null,c);if(o instanceof Error&&!(o.message in p)){p[o.message]=!0;a(n)}}},getValue:function(e){return e.valueLink?(o(e),e.valueLink.value):e.value},getChecked:function(e){return e.checkedLink?(i(e),e.checkedLink.value):e.checked},executeOnChange:function(e,t){return e.valueLink?(o(e),e.valueLink.requestChange(t.target.value)):e.checkedLink?(i(e),e.checkedLink.requestChange(t.target.checked)):e.onChange?e.onChange.call(void 0,t):void 0}};e.exports=d},function(e,t,n){"use strict";var r=n(7),o=(n(2),!1),i={replaceNodeWithMarkup:null,processChildrenUpdates:null,injection:{injectEnvironment:function(e){o?r("104"):void 0,i.replaceNodeWithMarkup=e.replaceNodeWithMarkup,i.processChildrenUpdates=e.processChildrenUpdates,o=!0}}};e.exports=i},function(e,t,n){"use strict";function r(e,t,n){try{t(n)}catch(e){null===o&&(o=e)}}var o=null,i={invokeGuardedCallback:r,invokeGuardedCallbackWithCatch:r,rethrowCaughtError:function(){if(o){var e=o;throw o=null,e}}};e.exports=i},function(e,t,n){"use strict";function r(e){s.enqueueUpdate(e)}function o(e){var t=typeof e;if("object"!==t)return t;var n=e.constructor&&e.constructor.name||t,r=Object.keys(e);return r.length>0&&r.length<20?n+" (keys: "+r.join(", ")+")":n}function i(e,t){var n=u.get(e);if(!n){return null}return n}var a=n(7),u=(n(42),n(83)),s=(n(31),n(36)),c=(n(2),n(5),{isMounted:function(e){var t=u.get(e);return!!t&&!!t._renderedComponent},enqueueCallback:function(e,t,n){c.validateCallback(t,n);var o=i(e);return o?(o._pendingCallbacks?o._pendingCallbacks.push(t):o._pendingCallbacks=[t],void r(o)):null},enqueueCallbackInternal:function(e,t){e._pendingCallbacks?e._pendingCallbacks.push(t):e._pendingCallbacks=[t],r(e)},enqueueForceUpdate:function(e){var t=i(e,"forceUpdate");t&&(t._pendingForceUpdate=!0,r(t))},enqueueReplaceState:function(e,t){var n=i(e,"replaceState");n&&(n._pendingStateQueue=[t],n._pendingReplaceState=!0,r(n))},enqueueSetState:function(e,t){var n=i(e,"setState");if(n){var o=n._pendingStateQueue||(n._pendingStateQueue=[]);o.push(t),r(n)}},enqueueElementInternal:function(e,t,n){e._pendingElement=t,e._context=n,r(e)},validateCallback:function(e,t){e&&"function"!=typeof e?a("122",t,o(e)):void 0}});e.exports=c},function(e,t){"use strict";var n=function(e){return"undefined"!=typeof MSApp&&MSApp.execUnsafeLocalFunction?function(t,n,r,o){MSApp.execUnsafeLocalFunction(function(){return e(t,n,r,o)})}:e};e.exports=n},function(e,t){"use strict";function n(e){var t,n=e.keyCode;return"charCode"in e?(t=e.charCode,0===t&&13===n&&(t=13)):t=n,t>=32||13===t?t:0}e.exports=n},function(e,t){"use strict";function n(e){var t=this,n=t.nativeEvent;if(n.getModifierState)return n.getModifierState(e);var r=o[e];return!!r&&!!n[r]}function r(e){return n}var o={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};e.exports=r},function(e,t){"use strict";function n(e){var t=e.target||e.srcElement||window;return t.correspondingUseElement&&(t=t.correspondingUseElement),3===t.nodeType?t.parentNode:t}e.exports=n},function(e,t,n){"use strict";/** * Checks if an event is supported in the current execution environment. * * NOTE: This will not work correctly for non-generic events such as `change`, * `reset`, `load`, `error`, and `select`. * * Borrows from Modernizr. * * @param {string} eventNameSuffix Event name, e.g. "click". * @param {?boolean} capture Check if the capture phase is supported. * @return {boolean} True if the event is supported. * @internal * @license Modernizr 3.0.0pre (Custom Build) | MIT */ function r(e,t){if(!i.canUseDOM||t&&!("addEventListener"in document))return!1;var n="on"+e,r=n in document;if(!r){var a=document.createElement("div");a.setAttribute(n,"return;"),r="function"==typeof a[n]}return!r&&o&&"wheel"===e&&(r=document.implementation.hasFeature("Events.wheel","3.0")),r}var o,i=n(18);i.canUseDOM&&(o=document.implementation&&document.implementation.hasFeature&&document.implementation.hasFeature("","")!==!0),e.exports=r},function(e,t){"use strict";function n(e,t){var n=null===e||e===!1,r=null===t||t===!1;if(n||r)return n===r;var o=typeof e,i=typeof t;return"string"===o||"number"===o?"string"===i||"number"===i:"object"===i&&e.type===t.type&&e.key===t.key}e.exports=n},function(e,t,n){"use strict";var r=(n(10),n(29)),o=(n(5),r);e.exports=o},function(e,t,n){"use strict";function r(e,t,n){this.props=e,this.context=t,this.refs=a,this.updater=n||i}var o=n(72),i=n(175),a=(n(261),n(76));n(2),n(5);r.prototype.isReactComponent={},r.prototype.setState=function(e,t){"object"!=typeof e&&"function"!=typeof e&&null!=e?o("85"):void 0,this.updater.enqueueSetState(this,e),t&&this.updater.enqueueCallback(this,t,"setState")},r.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this),e&&this.updater.enqueueCallback(this,e,"forceUpdate")};e.exports=r},function(e,t,n){"use strict";function r(e,t){}var o=(n(5),{isMounted:function(e){return!1},enqueueCallback:function(e,t){},enqueueForceUpdate:function(e){r(e,"forceUpdate")},enqueueReplaceState:function(e,t){r(e,"replaceState")},enqueueSetState:function(e,t){r(e,"setState")}});e.exports=o},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.ARRAY_INSERT="@@redux-form/ARRAY_INSERT",t.ARRAY_MOVE="@@redux-form/ARRAY_MOVE",t.ARRAY_POP="@@redux-form/ARRAY_POP",t.ARRAY_PUSH="@@redux-form/ARRAY_PUSH",t.ARRAY_REMOVE="@@redux-form/ARRAY_REMOVE",t.ARRAY_REMOVE_ALL="@@redux-form/ARRAY_REMOVE_ALL",t.ARRAY_SHIFT="@@redux-form/ARRAY_SHIFT",t.ARRAY_SPLICE="@@redux-form/ARRAY_SPLICE",t.ARRAY_UNSHIFT="@@redux-form/ARRAY_UNSHIFT",t.ARRAY_SWAP="@@redux-form/ARRAY_SWAP",t.AUTOFILL="@@redux-form/AUTOFILL",t.BLUR="@@redux-form/BLUR",t.CHANGE="@@redux-form/CHANGE",t.CLEAR_SUBMIT="@@redux-form/CLEAR_SUBMIT",t.CLEAR_ASYNC_ERROR="@redux-form/CLEAR_ASYNC_ERROR",t.DESTROY="@@redux-form/DESTROY",t.FOCUS="@@redux-form/FOCUS",t.INITIALIZE="@@redux-form/INITIALIZE",t.REGISTER_FIELD="@@redux-form/REGISTER_FIELD",t.RESET="@@redux-form/RESET",t.SET_SUBMIT_FAILED="@@redux-form/SET_SUBMIT_FAILED",t.SET_SUBMIT_SUCCEEDED="@@redux-form/SET_SUBMIT_SUCCEEDED",t.START_ASYNC_VALIDATION="@@redux-form/START_ASYNC_VALIDATION",t.START_SUBMIT="@@redux-form/START_SUBMIT",t.STOP_ASYNC_VALIDATION="@@redux-form/STOP_ASYNC_VALIDATION",t.STOP_SUBMIT="@@redux-form/STOP_SUBMIT",t.SUBMIT="@@redux-form/SUBMIT",t.TOUCH="@@redux-form/TOUCH",t.UNREGISTER_FIELD="@@redux-form/UNREGISTER_FIELD",t.UNTOUCH="@@redux-form/UNTOUCH",t.UPDATE_SYNC_ERRORS="@@redux-form/UPDATE_SYNC_ERRORS",t.UPDATE_SYNC_WARNINGS="@@redux-form/UPDATE_SYNC_WARNINGS"},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(684),i=r(o),a=function(e){var t=e.getIn,n=(0,i.default)(e);return function(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(e){return t(e,"form")},o=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return function(i){var a=r(i),u=t(a,e+".syncError");if(u)return!1;if(!o){var s=t(a,e+".error");if(s)return!1}var c=t(a,e+".syncErrors"),l=t(a,e+".asyncErrors"),f=o?void 0:t(a,e+".submitErrors");if(!c&&!l&&!f)return!0;var p=t(a,e+".registeredFields")||[];return!p.some(function(e){return n(e,c,l,f)})}}};t.default=a},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(709),i=r(o),a=function(e,t,n){return!(0,i.default)(e.props,t)||!(0,i.default)(e.state,n)};t.default=a},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},i=n(14),a=r(i),u=function(e){var t=e.input,n=e.label,r=e.type,i=e.meta,u=i.touched,s=i.error;return a.default.createElement("div",null,a.default.createElement("label",null,n),a.default.createElement("div",null,a.default.createElement("input",o({},t,{placeholder:n,type:r})),u&&s&&a.default.createElement("span",null,s)))};t.default=u},function(e,t,n){var r=n(26);e.exports=function(e,t){if("number"!=typeof e&&"Number"!=r(e))throw TypeError(t);return+e}},function(e,t,n){"use strict";var r=n(16),o=n(55),i=n(15);e.exports=[].copyWithin||function(e,t){var n=r(this),a=i(n.length),u=o(e,a),s=o(t,a),c=arguments.length>2?arguments[2]:void 0,l=Math.min((void 0===c?a:o(c,a))-s,a-u),f=1;for(s<u&&u<s+l&&(f=-1,s+=l-1,u+=l-1);l-- >0;)s in n?n[u]=n[s]:delete n[u],u+=f,s+=f;return n}},function(e,t,n){var r=n(61);e.exports=function(e,t){var n=[];return r(e,!1,n.push,n,t),n}},function(e,t,n){var r=n(19),o=n(16),i=n(74),a=n(15);e.exports=function(e,t,n,u,s){r(t);var c=o(e),l=i(c),f=a(c.length),p=s?f-1:0,d=s?-1:1;if(n<2)for(;;){if(p in l){u=l[p],p+=d;break}if(p+=d,s?p<0:f<=p)throw TypeError("Reduce of empty array with no initial value")}for(;s?p>=0:f>p;p+=d)p in l&&(u=t(u,l[p],p,c));return u}},function(e,t,n){"use strict";var r=n(19),o=n(8),i=n(89),a=[].slice,u={},s=function(e,t,n){if(!(t in u)){for(var r=[],o=0;o<t;o++)r[o]="a["+o+"]";u[t]=Function("F,a","return new F("+r.join(",")+")")}return u[t](e,n)};e.exports=Function.bind||function(e){var t=r(this),n=a.call(arguments,1),u=function(){var r=n.concat(a.call(arguments));return this instanceof u?s(t,r.length,r):i(t,r,e)};return o(t.prototype)&&(u.prototype=t.prototype),u}},function(e,t,n){"use strict";var r=n(12).f,o=n(50),i=n(53),a=n(38),u=n(48),s=n(27),c=n(61),l=n(125),f=n(191),p=n(54),d=n(11),h=n(43).fastKey,v=d?"_s":"size",m=function(e,t){var n,r=h(t);if("F"!==r)return e._i[r];for(n=e._f;n;n=n.n)if(n.k==t)return n};e.exports={getConstructor:function(e,t,n,l){var f=e(function(e,r){u(e,f,t,"_i"),e._i=o(null),e._f=void 0,e._l=void 0,e[v]=0,void 0!=r&&c(r,n,e[l],e)});return i(f.prototype,{clear:function(){for(var e=this,t=e._i,n=e._f;n;n=n.n)n.r=!0,n.p&&(n.p=n.p.n=void 0),delete t[n.i];e._f=e._l=void 0,e[v]=0},delete:function(e){var t=this,n=m(t,e);if(n){var r=n.n,o=n.p;delete t._i[n.i],n.r=!0,o&&(o.n=r),r&&(r.p=o),t._f==n&&(t._f=r),t._l==n&&(t._l=o),t[v]--}return!!n},forEach:function(e){u(this,f,"forEach");for(var t,n=a(e,arguments.length>1?arguments[1]:void 0,3);t=t?t.n:this._f;)for(n(t.v,t.k,this);t&&t.r;)t=t.p},has:function(e){return!!m(this,e)}}),d&&r(f.prototype,"size",{get:function(){return s(this[v])}}),f},def:function(e,t,n){var r,o,i=m(e,t);return i?i.v=n:(e._l=i={i:o=h(t,!0),k:t,v:n,p:r=e._l,n:void 0,r:!1},e._f||(e._f=i),r&&(r.n=i),e[v]++,"F"!==o&&(e._i[o]=i)),e},getEntry:m,setStrong:function(e,t,n){l(e,t,function(e,t){this._t=e,this._k=t,this._l=void 0},function(){for(var e=this,t=e._k,n=e._l;n&&n.r;)n=n.p;return e._t&&(e._l=n=n?n.n:e._t._f)?"keys"==t?f(0,n.k):"values"==t?f(0,n.v):f(0,[n.k,n.v]):(e._t=void 0,f(1))},n?"entries":"values",!n,!0),p(t)}}},function(e,t,n){var r=n(73),o=n(182);e.exports=function(e){return function(){if(r(this)!=e)throw TypeError(e+"#toJSON isn't generic");return o(this)}}},function(e,t,n){"use strict";var r=n(53),o=n(43).getWeak,i=n(3),a=n(8),u=n(48),s=n(61),c=n(32),l=n(17),f=c(5),p=c(6),d=0,h=function(e){return e._l||(e._l=new v)},v=function(){this.a=[]},m=function(e,t){return f(e.a,function(e){return e[0]===t})};v.prototype={get:function(e){var t=m(this,e);if(t)return t[1]},has:function(e){return!!m(this,e)},set:function(e,t){var n=m(this,e);n?n[1]=t:this.a.push([e,t])},delete:function(e){var t=p(this.a,function(t){return t[0]===e});return~t&&this.a.splice(t,1),!!~t}},e.exports={getConstructor:function(e,t,n,i){var c=e(function(e,r){u(e,c,t,"_i"),e._i=d++,e._l=void 0,void 0!=r&&s(r,n,e[i],e)});return r(c.prototype,{delete:function(e){if(!a(e))return!1;var t=o(e);return t===!0?h(this).delete(e):t&&l(t,this._i)&&delete t[this._i]},has:function(e){if(!a(e))return!1;var t=o(e);return t===!0?h(this).has(e):t&&l(t,this._i)}}),c},def:function(e,t,n){var r=o(i(t),!0);return r===!0?h(e).set(t,n):r[e._i]=n,e},ufstore:h}},function(e,t,n){e.exports=!n(11)&&!n(6)(function(){return 7!=Object.defineProperty(n(117)("div"),"a",{get:function(){return 7}}).a})},function(e,t,n){var r=n(8),o=Math.floor;e.exports=function(e){return!r(e)&&isFinite(e)&&o(e)===e}},function(e,t,n){var r=n(3);e.exports=function(e,t,n,o){try{return o?t(r(n)[0],n[1]):t(n)}catch(t){var i=e.return;throw void 0!==i&&r(i.call(e)),t}}},function(e,t){e.exports=function(e,t){return{value:t,done:!!e}}},function(e,t){e.exports=Math.log1p||function(e){return(e=+e)>-1e-8&&e<1e-8?e-e*e/2:Math.log(1+e)}},function(e,t,n){"use strict";var r=n(52),o=n(93),i=n(75),a=n(16),u=n(74),s=Object.assign;e.exports=!s||n(6)(function(){var e={},t={},n=Symbol(),r="abcdefghijklmnopqrst";return e[n]=7,r.split("").forEach(function(e){t[e]=e}),7!=s({},e)[n]||Object.keys(s({},t)).join("")!=r})?function(e,t){for(var n=a(e),s=arguments.length,c=1,l=o.f,f=i.f;s>c;)for(var p,d=u(arguments[c++]),h=l?r(d).concat(l(d)):r(d),v=h.length,m=0;v>m;)f.call(d,p=h[m++])&&(n[p]=d[p]);return n}:s},function(e,t,n){var r=n(12),o=n(3),i=n(52);e.exports=n(11)?Object.defineProperties:function(e,t){o(e);for(var n,a=i(t),u=a.length,s=0;u>s;)r.f(e,n=a[s++],t[n]);return e}},function(e,t,n){var r=n(23),o=n(51).f,i={}.toString,a="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],u=function(e){try{return o(e)}catch(e){return a.slice()}};e.exports.f=function(e){return a&&"[object Window]"==i.call(e)?u(e):o(r(e))}},function(e,t,n){var r=n(17),o=n(23),i=n(85)(!1),a=n(130)("IE_PROTO");e.exports=function(e,t){var n,u=o(e),s=0,c=[];for(n in u)n!=a&&r(u,n)&&c.push(n);for(;t.length>s;)r(u,n=t[s++])&&(~i(c,n)||c.push(n));return c}},function(e,t,n){var r=n(52),o=n(23),i=n(75).f;e.exports=function(e){return function(t){for(var n,a=o(t),u=r(a),s=u.length,c=0,l=[];s>c;)i.call(a,n=u[c++])&&l.push(e?[n,a[n]]:a[n]);return l}}},function(e,t,n){var r=n(51),o=n(93),i=n(3),a=n(4).Reflect;e.exports=a&&a.ownKeys||function(e){var t=r.f(i(e)),n=o.f;return n?t.concat(n(e)):t}},function(e,t,n){var r=n(4).parseFloat,o=n(64).trim;e.exports=1/r(n(135)+"-0")!==-(1/0)?function(e){var t=o(String(e),3),n=r(t);return 0===n&&"-"==t.charAt(0)?-0:n}:r},function(e,t,n){var r=n(4).parseInt,o=n(64).trim,i=n(135),a=/^[\-+]?0[xX]/;e.exports=8!==r(i+"08")||22!==r(i+"0x16")?function(e,t){var n=o(String(e),3);return r(n,t>>>0||(a.test(n)?16:10))}:r},function(e,t){e.exports=Object.is||function(e,t){return e===t?0!==e||1/e===1/t:e!=e&&t!=t}},function(e,t,n){var r=n(15),o=n(134),i=n(27);e.exports=function(e,t,n,a){var u=String(i(e)),s=u.length,c=void 0===n?" ":String(n),l=r(t);if(l<=s||""==c)return u;var f=l-s,p=o.call(c,Math.ceil(f/c.length));return p.length>f&&(p=p.slice(0,f)),a?p+u:u+p}},function(e,t,n){t.f=n(9)},function(e,t,n){"use strict";var r=n(185);e.exports=n(86)("Map",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{get:function(e){var t=r.getEntry(this,e);return t&&t.v},set:function(e,t){return r.def(this,0===e?0:e,t)}},r,!0)},function(e,t,n){n(11)&&"g"!=/./g.flags&&n(12).f(RegExp.prototype,"flags",{configurable:!0,get:n(88)})},function(e,t,n){"use strict";var r=n(185);e.exports=n(86)("Set",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{add:function(e){return r.def(this,e=0===e?0:e,e)}},r)},function(e,t,n){"use strict";var r,o=n(32)(0),i=n(21),a=n(43),u=n(193),s=n(187),c=n(8),l=a.getWeak,f=Object.isExtensible,p=s.ufstore,d={},h=function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},v={get:function(e){if(c(e)){var t=l(e);return t===!0?p(this).get(e):t?t[this._i]:void 0}},set:function(e,t){return s.def(this,e,t)}},m=e.exports=n(86)("WeakMap",h,v,s,!0,!0);7!=(new m).set((Object.freeze||Object)(d),7).get(d)&&(r=s.getConstructor(h),u(r.prototype,v),a.NEED=!0,o(["delete","has","get","set"],function(e){var t=m.prototype,n=t[e];i(t,e,function(t,o){if(c(t)&&!f(t)){this._f||(this._f=new r);var i=this._f[e](t,o);return"set"==e?this:i}return n.call(this,t,o)})}))},function(e,t,n){"use strict";var r=n(29),o={listen:function(e,t,n){return e.addEventListener?(e.addEventListener(t,n,!1),{remove:function(){e.removeEventListener(t,n,!1)}}):e.attachEvent?(e.attachEvent("on"+t,n),{remove:function(){e.detachEvent("on"+t,n)}}):void 0},capture:function(e,t,n){return e.addEventListener?(e.addEventListener(t,n,!0),{remove:function(){e.removeEventListener(t,n,!0)}}):{remove:r}},registerDefault:function(){}};e.exports=o},function(e,t){"use strict";function n(e){try{e.focus()}catch(e){}}e.exports=n},function(e,t){"use strict";function n(){if("undefined"==typeof document)return null;try{return document.activeElement||document.body}catch(e){return document.body}}e.exports=n},function(e,t){"use strict";var n={childContextTypes:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,mixins:!0,propTypes:!0,type:!0},r={name:!0,length:!0,prototype:!0,caller:!0,arguments:!0,arity:!0},o="function"==typeof Object.getOwnPropertySymbols;e.exports=function(e,t,i){if("string"!=typeof t){var a=Object.getOwnPropertyNames(t);o&&(a=a.concat(Object.getOwnPropertySymbols(t)));for(var u=0;u<a.length;++u)if(!(n[a[u]]||r[a[u]]||i&&i[a[u]]))try{e[a[u]]=t[a[u]]}catch(e){}}return e}},function(e,t,n){var r=n(35),o=r.Uint8Array;e.exports=o},function(e,t,n){function r(e,t){var n=a(e),r=!n&&i(e),l=!n&&!r&&u(e),p=!n&&!r&&!l&&c(e),d=n||r||l||p,h=d?o(e.length,String):[],v=h.length;for(var m in e)!t&&!f.call(e,m)||d&&("length"==m||l&&("offset"==m||"parent"==m)||p&&("buffer"==m||"byteLength"==m||"byteOffset"==m)||s(m,v))||h.push(m);return h}var o=n(510),i=n(151),a=n(30),u=n(152),s=n(147),c=n(155),l=Object.prototype,f=l.hasOwnProperty;e.exports=r},function(e,t){function n(e,t){for(var n=-1,r=null==e?0:e.length,o=Array(r);++n<r;)o[n]=t(e[n],n,e);return o}e.exports=n},function(e,t){function n(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}e.exports=n},function(e,t,n){function r(e,t,n){(void 0===n||i(e[t],n))&&(void 0!==n||t in e)||o(e,t,n)}var o=n(99),i=n(79);e.exports=r},function(e,t,n){var r=n(521),o=r();e.exports=o},function(e,t,n){function r(e,t){return e&&o(e,t,i)}var o=n(217),i=n(156);e.exports=r},function(e,t,n){function r(e,t){t=o(t,e);for(var n=0,r=t.length;null!=e&&n<r;)e=e[i(t[n++])];return n&&n==r?e:void 0}var o=n(221),i=n(78);e.exports=r},function(e,t,n){function r(e){return"function"==typeof e?e:null==e?a:"object"==typeof e?u(e)?i(e[0],e[1]):o(e):s(e)}var o=n(501),i=n(502),a=n(150),u=n(30),s=n(573);e.exports=r},function(e,t,n){function r(e,t){return o(e)?e:i(e,t)?[e]:a(u(e))}var o=n(30),i=n(148),a=n(231),u=n(235);e.exports=r},function(e,t){function n(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}e.exports=n},function(e,t,n){var r=n(57),o=function(){try{var e=r(Object,"defineProperty");return e({},"",{}),e}catch(e){}}();e.exports=o},function(e,t,n){function r(e,t,n,r,c,l){var f=n&u,p=e.length,d=t.length;if(p!=d&&!(f&&d>p))return!1;var h=l.get(e);if(h&&l.get(t))return h==t;var v=-1,m=!0,y=n&s?new o:void 0;for(l.set(e,t),l.set(t,e);++v<p;){var g=e[v],b=t[v];if(r)var _=f?r(b,g,v,t,e,l):r(g,b,v,e,t,l);if(void 0!==_){if(_)continue;m=!1;break}if(y){if(!i(t,function(e,t){if(!a(y,t)&&(g===e||c(g,e,n,r,l)))return y.push(t)})){m=!1;break}}else if(g!==b&&!c(g,b,n,r,l)){m=!1;break}}return l.delete(e),l.delete(t),m}var o=n(484),i=n(215),a=n(513),u=1,s=2;e.exports=r},function(e,t){(function(t){var n="object"==typeof t&&t&&t.Object===Object&&t;e.exports=n}).call(t,function(){return this}())},function(e,t,n){var r=n(230),o=r(Object.getPrototypeOf,Object);e.exports=o},function(e,t,n){function r(e,t,n){if(!u(n))return!1;var r=typeof t;return!!("number"==r?i(n)&&a(t,n.length):"string"==r&&t in n)&&o(n[t],e)}var o=n(79),i=n(80),a=n(147),u=n(46);e.exports=r},function(e,t,n){function r(e){return e===e&&!o(e)}var o=n(46);e.exports=r},function(e,t){function n(e,t){return function(n){return null!=n&&(n[e]===t&&(void 0!==t||e in Object(n)))}}e.exports=n},function(e,t){function n(e,t){return function(n){return e(t(n))}}e.exports=n},function(e,t,n){var r=n(550),o=/^\./,i=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,a=/\\(\\)?/g,u=r(function(e){var t=[];return o.test(e)&&t.push(""),e.replace(i,function(e,n,r,o){t.push(r?o.replace(a,"$1"):n||e)}),t});e.exports=u},function(e,t){function n(e){if(null!=e){try{return o.call(e)}catch(e){}try{return e+""}catch(e){}}return""}var r=Function.prototype,o=r.toString;e.exports=n},function(e,t,n){function r(e){return a(e)?o(e,!0):i(e)}var o=n(213),i=n(500),a=n(80);e.exports=r},function(e,t,n){function r(e,t){var n={};return t=a(t,3),i(e,function(e,r,i){o(n,r,t(e,r,i))}),n}var o=n(99),i=n(218),a=n(220);e.exports=r},function(e,t,n){function r(e){return null==e?"":o(e)}var o=n(511);e.exports=r},function(e,t){"use strict";function n(e,t){return e+t.charAt(0).toUpperCase()+t.substring(1)}var r={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridRow:!0,gridColumn:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},o=["Webkit","ms","Moz","O"];Object.keys(r).forEach(function(e){o.forEach(function(t){r[n(t,e)]=r[e]})});var i={background:{backgroundAttachment:!0,backgroundColor:!0,backgroundImage:!0,backgroundPositionX:!0,backgroundPositionY:!0,backgroundRepeat:!0},backgroundPosition:{backgroundPositionX:!0,backgroundPositionY:!0},border:{borderWidth:!0,borderStyle:!0,borderColor:!0},borderBottom:{borderBottomWidth:!0,borderBottomStyle:!0,borderBottomColor:!0},borderLeft:{borderLeftWidth:!0,borderLeftStyle:!0,borderLeftColor:!0},borderRight:{borderRightWidth:!0,borderRightStyle:!0,borderRightColor:!0},borderTop:{borderTopWidth:!0,borderTopStyle:!0,borderTopColor:!0},font:{fontStyle:!0,fontVariant:!0,fontWeight:!0,fontSize:!0,lineHeight:!0,fontFamily:!0},outline:{outlineWidth:!0,outlineStyle:!0,outlineColor:!0}},a={isUnitlessNumber:r,shorthandPropertyExpansions:i};e.exports=a},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var o=n(7),i=n(59),a=(n(2),function(){function e(t){r(this,e),this._callbacks=null,this._contexts=null,this._arg=t}return e.prototype.enqueue=function(e,t){this._callbacks=this._callbacks||[],this._callbacks.push(e),this._contexts=this._contexts||[],this._contexts.push(t)},e.prototype.notifyAll=function(){var e=this._callbacks,t=this._contexts,n=this._arg;if(e&&t){e.length!==t.length?o("24"):void 0,this._callbacks=null,this._contexts=null;for(var r=0;r<e.length;r++)e[r].call(t[r],n);e.length=0,t.length=0}},e.prototype.checkpoint=function(){return this._callbacks?this._callbacks.length:0},e.prototype.rollback=function(e){this._callbacks&&this._contexts&&(this._callbacks.length=e,this._contexts.length=e)},e.prototype.reset=function(){this._callbacks=null,this._contexts=null},e.prototype.destructor=function(){this.reset()},e}());e.exports=i.addPoolingTo(a)},function(e,t,n){"use strict";function r(e){return!!c.hasOwnProperty(e)||!s.hasOwnProperty(e)&&(u.test(e)?(c[e]=!0,!0):(s[e]=!0,!1))}function o(e,t){return null==t||e.hasBooleanValue&&!t||e.hasNumericValue&&isNaN(t)||e.hasPositiveNumericValue&&t<1||e.hasOverloadedBooleanValue&&t===!1}var i=n(67),a=(n(13),n(31),n(647)),u=(n(5),new RegExp("^["+i.ATTRIBUTE_NAME_START_CHAR+"]["+i.ATTRIBUTE_NAME_CHAR+"]*$")),s={},c={},l={createMarkupForID:function(e){return i.ID_ATTRIBUTE_NAME+"="+a(e)},setAttributeForID:function(e,t){e.setAttribute(i.ID_ATTRIBUTE_NAME,t)},createMarkupForRoot:function(){return i.ROOT_ATTRIBUTE_NAME+'=""'},setAttributeForRoot:function(e){e.setAttribute(i.ROOT_ATTRIBUTE_NAME,"")},createMarkupForProperty:function(e,t){var n=i.properties.hasOwnProperty(e)?i.properties[e]:null;if(n){if(o(n,t))return"";var r=n.attributeName;return n.hasBooleanValue||n.hasOverloadedBooleanValue&&t===!0?r+'=""':r+"="+a(t)}return i.isCustomAttribute(e)?null==t?"":e+"="+a(t):null},createMarkupForCustomAttribute:function(e,t){return r(e)&&null!=t?e+"="+a(t):""},setValueForProperty:function(e,t,n){var r=i.properties.hasOwnProperty(t)?i.properties[t]:null;if(r){var a=r.mutationMethod;if(a)a(e,n);else{if(o(r,n))return void this.deleteValueForProperty(e,t);if(r.mustUseProperty)e[r.propertyName]=n;else{var u=r.attributeName,s=r.attributeNamespace;s?e.setAttributeNS(s,u,""+n):r.hasBooleanValue||r.hasOverloadedBooleanValue&&n===!0?e.setAttribute(u,""):e.setAttribute(u,""+n)}}}else if(i.isCustomAttribute(t))return void l.setValueForAttribute(e,t,n)},setValueForAttribute:function(e,t,n){if(r(t)){null==n?e.removeAttribute(t):e.setAttribute(t,""+n)}},deleteValueForAttribute:function(e,t){e.removeAttribute(t)},deleteValueForProperty:function(e,t){var n=i.properties.hasOwnProperty(t)?i.properties[t]:null;if(n){var r=n.mutationMethod;if(r)r(e,void 0);else if(n.mustUseProperty){var o=n.propertyName;n.hasBooleanValue?e[o]=!1:e[o]=""}else e.removeAttribute(n.attributeName)}else i.isCustomAttribute(t)&&e.removeAttribute(t)}};e.exports=l},function(e,t){"use strict";var n={hasCachedChildNodes:1};e.exports=n},function(e,t,n){"use strict";function r(){if(this._rootNodeID&&this._wrapperState.pendingUpdate){this._wrapperState.pendingUpdate=!1;var e=this._currentElement.props,t=u.getValue(e);null!=t&&o(this,Boolean(e.multiple),t)}}function o(e,t,n){var r,o,i=s.getNodeFromInstance(e).options;if(t){for(r={},o=0;o<n.length;o++)r[""+n[o]]=!0;for(o=0;o<i.length;o++){var a=r.hasOwnProperty(i[o].value);i[o].selected!==a&&(i[o].selected=a)}}else{for(r=""+n,o=0;o<i.length;o++)if(i[o].value===r)return void(i[o].selected=!0);i.length&&(i[0].selected=!0)}}function i(e){var t=this._currentElement.props,n=u.executeOnChange(t,e);return this._rootNodeID&&(this._wrapperState.pendingUpdate=!0),c.asap(r,this),n}var a=n(10),u=n(163),s=n(13),c=n(36),l=(n(5),!1),f={getHostProps:function(e,t){return a({},t,{onChange:e._wrapperState.onChange,value:void 0})},mountWrapper:function(e,t){var n=u.getValue(t);e._wrapperState={pendingUpdate:!1,initialValue:null!=n?n:t.defaultValue,listeners:null,onChange:i.bind(e),wasMultiple:Boolean(t.multiple)},void 0===t.value||void 0===t.defaultValue||l||(l=!0)},getSelectValueContext:function(e){return e._wrapperState.initialValue},postUpdateWrapper:function(e){var t=e._currentElement.props;e._wrapperState.initialValue=void 0;var n=e._wrapperState.wasMultiple;e._wrapperState.wasMultiple=Boolean(t.multiple);var r=u.getValue(t);null!=r?(e._wrapperState.pendingUpdate=!1,o(e,Boolean(t.multiple),r)):n!==Boolean(t.multiple)&&(null!=t.defaultValue?o(e,Boolean(t.multiple),t.defaultValue):o(e,Boolean(t.multiple),t.multiple?[]:""))}};e.exports=f},function(e,t){"use strict";var n,r={injectEmptyComponentFactory:function(e){n=e}},o={create:function(e){return n(e)}};o.injection=r,e.exports=o},function(e,t){"use strict";var n={logTopLevelRenders:!1};e.exports=n},function(e,t,n){"use strict";function r(e){return s?void 0:a("111",e.type),new s(e)}function o(e){return new l(e)}function i(e){return e instanceof l}var a=n(7),u=n(10),s=(n(2),null),c={},l=null,f={injectGenericComponentClass:function(e){s=e},injectTextComponentClass:function(e){l=e},injectComponentClasses:function(e){u(c,e)}},p={createInternalComponent:r,createInstanceForText:o,isTextComponent:i,injection:f};e.exports=p},function(e,t,n){"use strict";function r(e){return i(document.documentElement,e)}var o=n(606),i=n(465),a=n(209),u=n(210),s={hasSelectionCapabilities:function(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&("input"===t&&"text"===e.type||"textarea"===t||"true"===e.contentEditable)},getSelectionInformation:function(){var e=u();return{focusedElem:e,selectionRange:s.hasSelectionCapabilities(e)?s.getSelection(e):null}},restoreSelection:function(e){var t=u(),n=e.focusedElem,o=e.selectionRange;t!==n&&r(n)&&(s.hasSelectionCapabilities(n)&&s.setSelection(n,o),a(n))},getSelection:function(e){var t;if("selectionStart"in e)t={start:e.selectionStart,end:e.selectionEnd};else if(document.selection&&e.nodeName&&"input"===e.nodeName.toLowerCase()){var n=document.selection.createRange();n.parentElement()===e&&(t={start:-n.moveStart("character",-e.value.length),end:-n.moveEnd("character",-e.value.length)})}else t=o.getOffsets(e);return t||{start:0,end:0}},setSelection:function(e,t){var n=t.start,r=t.end;if(void 0===r&&(r=n),"selectionStart"in e)e.selectionStart=n,e.selectionEnd=Math.min(r,e.value.length);else if(document.selection&&e.nodeName&&"input"===e.nodeName.toLowerCase()){var i=e.createTextRange();i.collapse(!0),i.moveStart("character",n),i.moveEnd("character",r-n),i.select()}else o.setOffsets(e,t)}};e.exports=s},function(e,t,n){"use strict";function r(e,t){for(var n=Math.min(e.length,t.length),r=0;r<n;r++)if(e.charAt(r)!==t.charAt(r))return r;return e.length===t.length?-1:n}function o(e){return e?e.nodeType===N?e.documentElement:e.firstChild:null}function i(e){return e.getAttribute&&e.getAttribute(R)||""}function a(e,t,n,r,o){var i;if(x.logTopLevelRenders){var a=e._currentElement.props.child,u=a.type;i="React mount: "+("string"==typeof u?u:u.displayName||u.name),console.time(i)}var s=S.mountComponent(e,n,null,b(e,t),o,0);i&&console.timeEnd(i),e._renderedComponent._topLevelWrapper=e,L._mountImageIntoNode(s,t,e,r,n)}function u(e,t,n,r){var o=P.ReactReconcileTransaction.getPooled(!n&&_.useCreateElement);o.perform(a,null,e,t,o,n,r),P.ReactReconcileTransaction.release(o)}function s(e,t,n){for(S.unmountComponent(e,n),t.nodeType===N&&(t=t.documentElement);t.lastChild;)t.removeChild(t.lastChild)}function c(e){var t=o(e);if(t){var n=g.getInstanceFromNode(t);return!(!n||!n._hostParent)}}function l(e){return!(!e||e.nodeType!==I&&e.nodeType!==N&&e.nodeType!==j)}function f(e){var t=o(e),n=t&&g.getInstanceFromNode(t);return n&&!n._hostParent?n:null}function p(e){var t=f(e);return t?t._hostContainerInfo._topLevelWrapper:null}var d=n(7),h=n(66),v=n(67),m=n(70),y=n(105),g=(n(42),n(13)),b=n(600),_=n(602),x=n(242),E=n(83),w=(n(31),n(616)),S=n(68),C=n(166),P=n(36),O=n(76),T=n(252),k=(n(2),n(109)),A=n(172),R=(n(5),v.ID_ATTRIBUTE_NAME),M=v.ROOT_ATTRIBUTE_NAME,I=1,N=9,j=11,F={},D=1,U=function(){this.rootID=D++};U.prototype.isReactComponent={},U.prototype.render=function(){return this.props.child},U.isReactTopLevelWrapper=!0;var L={TopLevelWrapper:U,_instancesByReactRootID:F,scrollMonitor:function(e,t){t()},_updateRootComponent:function(e,t,n,r,o){return L.scrollMonitor(r,function(){C.enqueueElementInternal(e,t,n),o&&C.enqueueCallbackInternal(e,o)}),e},_renderNewRootComponent:function(e,t,n,r){l(t)?void 0:d("37"),y.ensureScrollValueMonitoring();var o=T(e,!1);P.batchedUpdates(u,o,t,n,r);var i=o._instance.rootID;return F[i]=o,o},renderSubtreeIntoContainer:function(e,t,n,r){return null!=e&&E.has(e)?void 0:d("38"),L._renderSubtreeIntoContainer(e,t,n,r)},_renderSubtreeIntoContainer:function(e,t,n,r){C.validateCallback(r,"ReactDOM.render"),m.isValidElement(t)?void 0:d("39","string"==typeof t?" Instead of passing a string like 'div', pass React.createElement('div') or <div />.":"function"==typeof t?" Instead of passing a class like Foo, pass React.createElement(Foo) or <Foo />.":null!=t&&void 0!==t.props?" This may be caused by unintentionally loading two independent copies of React.":"");var a,u=m.createElement(U,{child:t});if(e){var s=E.get(e);a=s._processChildContext(s._context)}else a=O;var l=p(n);if(l){var f=l._currentElement,h=f.props.child;if(A(h,t)){var v=l._renderedComponent.getPublicInstance(),y=r&&function(){r.call(v)};return L._updateRootComponent(l,u,a,n,y),v}L.unmountComponentAtNode(n)}var g=o(n),b=g&&!!i(g),_=c(n),x=b&&!l&&!_,w=L._renderNewRootComponent(u,n,x,a)._renderedComponent.getPublicInstance();return r&&r.call(w),w},render:function(e,t,n){return L._renderSubtreeIntoContainer(null,e,t,n)},unmountComponentAtNode:function(e){l(e)?void 0:d("40");var t=p(e);if(!t){c(e),1===e.nodeType&&e.hasAttribute(M);return!1}return delete F[t._instance.rootID],P.batchedUpdates(s,t,e,!1),!0},_mountImageIntoNode:function(e,t,n,i,a){if(l(t)?void 0:d("41"),i){var u=o(t);if(w.canReuseMarkup(e,u))return void g.precacheNode(n,u);var s=u.getAttribute(w.CHECKSUM_ATTR_NAME);u.removeAttribute(w.CHECKSUM_ATTR_NAME);var c=u.outerHTML;u.setAttribute(w.CHECKSUM_ATTR_NAME,s);var f=e,p=r(f,c),v=" (client) "+f.substring(p-20,p+20)+"\n (server) "+c.substring(p-20,p+20);t.nodeType===N?d("42",v):void 0}if(t.nodeType===N?d("43"):void 0,a.useCreateElement){for(;t.lastChild;)t.removeChild(t.lastChild);h.insertTreeBefore(t,e,null)}else k(t,e),g.precacheNode(n,t.firstChild)}};e.exports=L},function(e,t,n){"use strict";var r=n(7),o=n(70),i=(n(2),{HOST:0,COMPOSITE:1,EMPTY:2,getType:function(e){return null===e||e===!1?i.EMPTY:o.isValidElement(e)?"function"==typeof e.type?i.COMPOSITE:i.HOST:void r("26",e)}});e.exports=i},function(e,t){"use strict";var n={currentScrollLeft:0,currentScrollTop:0,refreshScrollValues:function(e){n.currentScrollLeft=e.x,n.currentScrollTop=e.y}};e.exports=n},function(e,t,n){"use strict";function r(e,t){return null==t?o("30"):void 0,null==e?t:Array.isArray(e)?Array.isArray(t)?(e.push.apply(e,t),e):(e.push(t),e):Array.isArray(t)?[e].concat(t):[e,t]}var o=n(7);n(2);e.exports=r},function(e,t){"use strict";function n(e,t,n){Array.isArray(e)?e.forEach(t,n):e&&t.call(n,e)}e.exports=n},function(e,t,n){"use strict";function r(e){for(var t;(t=e._renderedNodeType)===o.COMPOSITE;)e=e._renderedComponent;return t===o.HOST?e._renderedComponent:t===o.EMPTY?null:void 0}var o=n(246);e.exports=r},function(e,t,n){"use strict";function r(){return!i&&o.canUseDOM&&(i="textContent"in document.documentElement?"textContent":"innerText"),i}var o=n(18),i=null;e.exports=r},function(e,t,n){"use strict";function r(e){if(e){var t=e.getName();if(t)return" Check the render method of `"+t+"`."}return""}function o(e){return"function"==typeof e&&"undefined"!=typeof e.prototype&&"function"==typeof e.prototype.mountComponent&&"function"==typeof e.prototype.receiveComponent}function i(e,t){var n;if(null===e||e===!1)n=c.create(i);else if("object"==typeof e){var u=e;!u||"function"!=typeof u.type&&"string"!=typeof u.type?a("130",null==u.type?u.type:typeof u.type,r(u._owner)):void 0,"string"==typeof u.type?n=l.createInternalComponent(u):o(u.type)?(n=new u.type(u),n.getHostNode||(n.getHostNode=n.getNativeNode)):n=new f(u)}else"string"==typeof e||"number"==typeof e?n=l.createInstanceForText(e):a("131",typeof e);return n._mountIndex=0,n._mountImage=null,n}var a=n(7),u=n(10),s=n(597),c=n(241),l=n(243),f=(n(644),n(2),n(5),function(e){this.construct(e)});u(f.prototype,s,{_instantiateReactComponent:i}),e.exports=i},function(e,t){"use strict";function n(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return"input"===t?!!r[e.type]:"textarea"===t}var r={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};e.exports=n},function(e,t,n){"use strict";var r=n(18),o=n(108),i=n(109),a=function(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&3===n.nodeType)return void(n.nodeValue=t)}e.textContent=t};r.canUseDOM&&("textContent"in document.documentElement||(a=function(e,t){return 3===e.nodeType?void(e.nodeValue=t):void i(e,o(t))})),e.exports=a},function(e,t,n){"use strict";function r(e,t){return e&&"object"==typeof e&&null!=e.key?c.escape(e.key):t.toString(36); }function o(e,t,n,i){var p=typeof e;if("undefined"!==p&&"boolean"!==p||(e=null),null===e||"string"===p||"number"===p||"object"===p&&e.$$typeof===u)return n(i,e,""===t?l+r(e,0):t),1;var d,h,v=0,m=""===t?l:t+f;if(Array.isArray(e))for(var y=0;y<e.length;y++)d=e[y],h=m+r(d,y),v+=o(d,h,n,i);else{var g=s(e);if(g){var b,_=g.call(e);if(g!==e.entries)for(var x=0;!(b=_.next()).done;)d=b.value,h=m+r(d,x++),v+=o(d,h,n,i);else for(;!(b=_.next()).done;){var E=b.value;E&&(d=E[1],h=m+c.escape(E[0])+f+r(d,0),v+=o(d,h,n,i))}}else if("object"===p){var w="",S=String(e);a("31","[object Object]"===S?"object with keys {"+Object.keys(e).join(", ")+"}":S,w)}}return v}function i(e,t,n){return null==e?0:o(e,"",t,n)}var a=n(7),u=(n(42),n(612)),s=n(643),c=(n(2),n(162)),l=(n(5),"."),f=":";e.exports=i},function(e,t,n){"use strict";t.__esModule=!0;var r=n(14);t.default=r.PropTypes.shape({subscribe:r.PropTypes.func.isRequired,dispatch:r.PropTypes.func.isRequired,getState:r.PropTypes.func.isRequired})},function(e,t){"use strict";function n(e){"undefined"!=typeof console&&"function"==typeof console.error&&console.error(e);try{throw new Error(e)}catch(e){}}t.__esModule=!0,t.default=n},function(e,t,n){"use strict";function r(e){var t=Function.prototype.toString,n=Object.prototype.hasOwnProperty,r=RegExp("^"+t.call(n).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");try{var o=t.call(e);return r.test(o)}catch(e){return!1}}function o(e){var t=c(e);if(t){var n=t.childIDs;l(e),n.forEach(o)}}function i(e,t,n){return"\n in "+(e||"Unknown")+(t?" (at "+t.fileName.replace(/^.*[\\\/]/,"")+":"+t.lineNumber+")":n?" (created by "+n+")":"")}function a(e){return null==e?"#empty":"string"==typeof e||"number"==typeof e?"#text":"string"==typeof e.type?e.type:e.type.displayName||e.type.name||"Unknown"}function u(e){var t,n=C.getDisplayName(e),r=C.getElement(e),o=C.getOwnerID(e);return o&&(t=C.getDisplayName(o)),i(n,r&&r._source,t)}var s,c,l,f,p,d,h,v=n(72),m=n(42),y=(n(2),n(5),"function"==typeof Array.from&&"function"==typeof Map&&r(Map)&&null!=Map.prototype&&"function"==typeof Map.prototype.keys&&r(Map.prototype.keys)&&"function"==typeof Set&&r(Set)&&null!=Set.prototype&&"function"==typeof Set.prototype.keys&&r(Set.prototype.keys));if(y){var g=new Map,b=new Set;s=function(e,t){g.set(e,t)},c=function(e){return g.get(e)},l=function(e){g.delete(e)},f=function(){return Array.from(g.keys())},p=function(e){b.add(e)},d=function(e){b.delete(e)},h=function(){return Array.from(b.keys())}}else{var _={},x={},E=function(e){return"."+e},w=function(e){return parseInt(e.substr(1),10)};s=function(e,t){var n=E(e);_[n]=t},c=function(e){var t=E(e);return _[t]},l=function(e){var t=E(e);delete _[t]},f=function(){return Object.keys(_).map(w)},p=function(e){var t=E(e);x[t]=!0},d=function(e){var t=E(e);delete x[t]},h=function(){return Object.keys(x).map(w)}}var S=[],C={onSetChildren:function(e,t){var n=c(e);n?void 0:v("144"),n.childIDs=t;for(var r=0;r<t.length;r++){var o=t[r],i=c(o);i?void 0:v("140"),null==i.childIDs&&"object"==typeof i.element&&null!=i.element?v("141"):void 0,i.isMounted?void 0:v("71"),null==i.parentID&&(i.parentID=e),i.parentID!==e?v("142",o,i.parentID,e):void 0}},onBeforeMountComponent:function(e,t,n){var r={element:t,parentID:n,text:null,childIDs:[],isMounted:!1,updateCount:0};s(e,r)},onBeforeUpdateComponent:function(e,t){var n=c(e);n&&n.isMounted&&(n.element=t)},onMountComponent:function(e){var t=c(e);t?void 0:v("144"),t.isMounted=!0;var n=0===t.parentID;n&&p(e)},onUpdateComponent:function(e){var t=c(e);t&&t.isMounted&&t.updateCount++},onUnmountComponent:function(e){var t=c(e);if(t){t.isMounted=!1;var n=0===t.parentID;n&&d(e)}S.push(e)},purgeUnmountedComponents:function(){if(!C._preventPurging){for(var e=0;e<S.length;e++){var t=S[e];o(t)}S.length=0}},isMounted:function(e){var t=c(e);return!!t&&t.isMounted},getCurrentStackAddendum:function(e){var t="";if(e){var n=a(e),r=e._owner;t+=i(n,e._source,r&&r.getName())}var o=m.current,u=o&&o._debugID;return t+=C.getStackAddendumByID(u)},getStackAddendumByID:function(e){for(var t="";e;)t+=u(e),e=C.getParentID(e);return t},getChildIDs:function(e){var t=c(e);return t?t.childIDs:[]},getDisplayName:function(e){var t=C.getElement(e);return t?a(t):null},getElement:function(e){var t=c(e);return t?t.element:null},getOwnerID:function(e){var t=C.getElement(e);return t&&t._owner?t._owner._debugID:null},getParentID:function(e){var t=c(e);return t?t.parentID:null},getSource:function(e){var t=c(e),n=t?t.element:null,r=null!=n?n._source:null;return r},getText:function(e){var t=C.getElement(e);return"string"==typeof t?t:"number"==typeof t?""+t:null},getUpdateCount:function(e){var t=c(e);return t?t.updateCount:0},getRootIDs:h,getRegisteredIDs:f};e.exports=C},function(e,t){"use strict";var n="function"==typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103;e.exports=n},function(e,t,n){"use strict";var r={};e.exports=r},function(e,t,n){"use strict";var r=!1;e.exports=r},function(e,t){"use strict";function n(e){var t=e&&(r&&e[r]||e[o]);if("function"==typeof t)return t}var r="function"==typeof Symbol&&Symbol.iterator,o="@@iterator";e.exports=n},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var u=n(462),s=r(u),c=function(e){function t(e){o(this,t);var n=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,"Submit Validation Failed"));return n.errors=e,n}return a(t,e),t}(s.default);t.default=c},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.updateSyncWarnings=t.updateSyncErrors=t.untouch=t.unregisterField=t.touch=t.setSubmitSucceeded=t.setSubmitFailed=t.submit=t.stopSubmit=t.stopAsyncValidation=t.startSubmit=t.startAsyncValidation=t.reset=t.registerField=t.initialize=t.focus=t.destroy=t.clearAsyncError=t.clearSubmit=t.change=t.blur=t.autofill=t.arrayUnshift=t.arraySwap=t.arraySplice=t.arrayShift=t.arrayRemoveAll=t.arrayRemove=t.arrayPush=t.arrayPop=t.arrayMove=t.arrayInsert=void 0;var r=n(176);t.arrayInsert=function(e,t,n,o){return{type:r.ARRAY_INSERT,meta:{form:e,field:t,index:n},payload:o}},t.arrayMove=function(e,t,n,o){return{type:r.ARRAY_MOVE,meta:{form:e,field:t,from:n,to:o}}},t.arrayPop=function(e,t){return{type:r.ARRAY_POP,meta:{form:e,field:t}}},t.arrayPush=function(e,t,n){return{type:r.ARRAY_PUSH,meta:{form:e,field:t},payload:n}},t.arrayRemove=function(e,t,n){return{type:r.ARRAY_REMOVE,meta:{form:e,field:t,index:n}}},t.arrayRemoveAll=function(e,t){return{type:r.ARRAY_REMOVE_ALL,meta:{form:e,field:t}}},t.arrayShift=function(e,t){return{type:r.ARRAY_SHIFT,meta:{form:e,field:t}}},t.arraySplice=function(e,t,n,o,i){var a={type:r.ARRAY_SPLICE,meta:{form:e,field:t,index:n,removeNum:o}};return void 0!==i&&(a.payload=i),a},t.arraySwap=function(e,t,n,o){if(n===o)throw new Error("Swap indices cannot be equal");if(n<0||o<0)throw new Error("Swap indices cannot be negative");return{type:r.ARRAY_SWAP,meta:{form:e,field:t,indexA:n,indexB:o}}},t.arrayUnshift=function(e,t,n){return{type:r.ARRAY_UNSHIFT,meta:{form:e,field:t},payload:n}},t.autofill=function(e,t,n){return{type:r.AUTOFILL,meta:{form:e,field:t},payload:n}},t.blur=function(e,t,n,o){return{type:r.BLUR,meta:{form:e,field:t,touch:o},payload:n}},t.change=function(e,t,n,o,i){return{type:r.CHANGE,meta:{form:e,field:t,touch:o,persistentSubmitErrors:i},payload:n}},t.clearSubmit=function(e){return{type:r.CLEAR_SUBMIT,meta:{form:e}}},t.clearAsyncError=function(e,t){return{type:r.CLEAR_ASYNC_ERROR,meta:{form:e,field:t}}},t.destroy=function(e){return{type:r.DESTROY,meta:{form:e}}},t.focus=function(e,t){return{type:r.FOCUS,meta:{form:e,field:t}}},t.initialize=function(e,t,n){return{type:r.INITIALIZE,meta:{form:e,keepDirty:n},payload:t}},t.registerField=function(e,t,n){return{type:r.REGISTER_FIELD,meta:{form:e},payload:{name:t,type:n}}},t.reset=function(e){return{type:r.RESET,meta:{form:e}}},t.startAsyncValidation=function(e,t){return{type:r.START_ASYNC_VALIDATION,meta:{form:e,field:t}}},t.startSubmit=function(e){return{type:r.START_SUBMIT,meta:{form:e}}},t.stopAsyncValidation=function(e,t){var n={type:r.STOP_ASYNC_VALIDATION,meta:{form:e},payload:t};return t&&Object.keys(t).length&&(n.error=!0),n},t.stopSubmit=function(e,t){var n={type:r.STOP_SUBMIT,meta:{form:e},payload:t};return t&&Object.keys(t).length&&(n.error=!0),n},t.submit=function(e){return{type:r.SUBMIT,meta:{form:e}}},t.setSubmitFailed=function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),o=1;o<t;o++)n[o-1]=arguments[o];return{type:r.SET_SUBMIT_FAILED,meta:{form:e,fields:n},error:!0}},t.setSubmitSucceeded=function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),o=1;o<t;o++)n[o-1]=arguments[o];return{type:r.SET_SUBMIT_SUCCEEDED,meta:{form:e,fields:n},error:!1}},t.touch=function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),o=1;o<t;o++)n[o-1]=arguments[o];return{type:r.TOUCH,meta:{form:e,fields:n}}},t.unregisterField=function(e,t){return{type:r.UNREGISTER_FIELD,meta:{form:e},payload:{name:t}}},t.untouch=function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),o=1;o<t;o++)n[o-1]=arguments[o];return{type:r.UNTOUCH,meta:{form:e,fields:n}}},t.updateSyncErrors=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments[2];return{type:r.UPDATE_SYNC_ERRORS,meta:{form:e},payload:{syncErrors:t,error:n}}},t.updateSyncWarnings=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments[2];return{type:r.UPDATE_SYNC_WARNINGS,meta:{form:e},payload:{syncWarnings:t,warning:n}}}},function(e,t){"use strict";function n(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}Object.defineProperty(t,"__esModule",{value:!0});var r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},o=function(e,t,n){var o=t.value;return"checkbox"===e?r({},t,{checked:!!o}):"radio"===e?r({},t,{checked:o===n,value:n}):"select-multiple"===e?r({},t,{value:o||[]}):"file"===e?r({},t,{value:void 0}):t},i=function(e,t,i){var a=e.getIn,u=e.toJS,s=i.asyncError,c=i.asyncValidating,l=i.onBlur,f=i.onChange,p=i.onDrop,d=i.onDragStart,h=i.dirty,v=i.dispatch,m=i.onFocus,y=i.format,g=(i.parse,i.pristine),b=i.props,_=i.state,x=i.submitError,E=i.submitFailed,w=i.submitting,S=i.syncError,C=i.syncWarning,P=(i.validate,i.value),O=i._value,T=(i.warn,n(i,["asyncError","asyncValidating","onBlur","onChange","onDrop","onDragStart","dirty","dispatch","onFocus","format","parse","pristine","props","state","submitError","submitFailed","submitting","syncError","syncWarning","validate","value","_value","warn"])),k=S||s||x,A=C,R=function(e,n){if(null===n)return e;var r=null==e?"":e;return n?n(e,t):r},M=R(P,y);return{input:o(T.type,{name:t,onBlur:l,onChange:f,onDragStart:d,onDrop:p,onFocus:m,value:M},O),meta:r({},u(_),{active:!(!_||!a(_,"active")),asyncValidating:c,autofilled:!(!_||!a(_,"autofilled")),dirty:h,dispatch:v,error:k,warning:A,invalid:!!k,pristine:g,submitting:!!w,submitFailed:!!E,touched:!(!_||!a(_,"touched")),valid:!k,visited:!(!_||!a(_,"visited"))}),custom:r({},T,b)}};t.default=i},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(e){return!!(e&&e.stopPropagation&&e.preventDefault)};t.default=n},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(679),i=r(o),a=n(685),u=r(a),s=function(e,t){var n=t.name,r=t.parse,o=t.normalize,a=(0,i.default)(e,u.default);return r&&(a=r(a,n)),o&&(a=o(n,a)),a};t.default=s},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(266),i=r(o),a=function(e){var t=(0,i.default)(e);return t&&e.preventDefault(),t};t.default=a},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(e){var t=e.deepEqual,n=e.empty,r=e.getIn;return function(e){var o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(e){return r(e,"form")};return function(i){var a=o(i),u=r(a,e+".initial")||n,s=r(a,e+".values")||u;return t(u,s)}}};t.default=n},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(104),i=r(o),a=function(e,t){if(!e)return e;var n=(0,i.default)(t),r=n.length;if(r){for(var o=e,a=0;a<r&&o;++a)o=o[n[a]];return o}};t.default=a},function(e,t){"use strict";function n(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];if(0===t.length)return function(e){return e};if(1===t.length)return t[0];var r=t[t.length-1],o=t.slice(0,-1);return function(){return o.reduceRight(function(e,t){return t(e)},r.apply(void 0,arguments))}}t.__esModule=!0,t.default=n},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t,n){function r(){y===m&&(y=m.slice())}function i(){return v}function u(e){if("function"!=typeof e)throw new Error("Expected listener to be a function.");var t=!0;return r(),y.push(e),function(){if(t){t=!1,r();var n=y.indexOf(e);y.splice(n,1)}}}function l(e){if(!(0,a.default)(e))throw new Error("Actions must be plain objects. Use custom middleware for async actions.");if("undefined"==typeof e.type)throw new Error('Actions may not have an undefined "type" property. Have you misspelled a constant?');if(g)throw new Error("Reducers may not dispatch actions.");try{g=!0,v=h(v,e)}finally{g=!1}for(var t=m=y,n=0;n<t.length;n++)t[n]();return e}function f(e){if("function"!=typeof e)throw new Error("Expected the nextReducer to be a function.");h=e,l({type:c.INIT})}function p(){var e,t=u;return e={subscribe:function(e){function n(){e.next&&e.next(i())}if("object"!=typeof e)throw new TypeError("Expected the observer to be an object.");n();var r=t(n);return{unsubscribe:r}}},e[s.default]=function(){return this},e}var d;if("function"==typeof t&&"undefined"==typeof n&&(n=t,t=void 0),"undefined"!=typeof n){if("function"!=typeof n)throw new Error("Expected the enhancer to be a function.");return n(o)(e,t)}if("function"!=typeof e)throw new Error("Expected the reducer to be a function.");var h=e,v=t,m=[],y=m,g=!1;return l({type:c.INIT}),d={dispatch:l,subscribe:u,getState:i,replaceReducer:f},d[s.default]=p,d}t.__esModule=!0,t.ActionTypes=void 0,t.default=o;var i=n(102),a=r(i),u=n(710),s=r(u),c=t.ActionTypes={INIT:"@@redux/INIT"}},function(e,t){"use strict";function n(e){"undefined"!=typeof console&&"function"==typeof console.error&&console.error(e);try{throw new Error(e)}catch(e){}}t.__esModule=!0,t.default=n},function(e,t){e.exports=function(){Array.prototype.findIndex||(Array.prototype.findIndex=function(e){if(null===this)throw new TypeError("Array.prototype.findIndex called on null or undefined");if("function"!=typeof e)throw new TypeError("predicate must be a function");for(var t,n=Object(this),r=n.length>>>0,o=arguments[1],i=0;i<r;i++)if(t=n[i],e.call(o,t,i,n))return i;return-1})}()},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var u=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),s=n(14),c=r(s),l=n(276),f=r(l),p=n(277),d=r(p),h=n(278),v=r(h),m=function(e){function t(e){o(this,t);var n=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.nextPage=n.nextPage.bind(n),n.previousPage=n.previousPage.bind(n),n.state={page:1},n}return a(t,e),u(t,[{key:"nextPage",value:function(){this.setState({page:this.state.page+1})}},{key:"previousPage",value:function(){this.setState({page:this.state.page-1})}},{key:"render",value:function(){var e=this.props.onSubmit,t=this.state.page;return c.default.createElement("div",null,1===t&&c.default.createElement(f.default,{onSubmit:this.nextPage}),2===t&&c.default.createElement(d.default,{previousPage:this.previousPage,onSubmit:this.nextPage}),3===t&&c.default.createElement(v.default,{previousPage:this.previousPage,onSubmit:e}))}}]),t}(s.Component);m.propTypes={onSubmit:s.PropTypes.func.isRequired},t.default=m},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(14),i=r(o),a=n(110),u=n(114),s=r(u),c=n(179),l=r(c),f=function(e){var t=e.handleSubmit;return i.default.createElement("form",{onSubmit:t},i.default.createElement(a.Field,{name:"firstName",type:"text",component:l.default,label:"First Name"}),i.default.createElement(a.Field,{name:"lastName",type:"text",component:l.default,label:"Last Name"}),i.default.createElement("div",null,i.default.createElement("button",{type:"submit",className:"next"},"Next")))};t.default=(0,a.reduxForm)({form:"wizard",destroyOnUnmount:!1,forceUnregisterOnUnmount:!0,validate:s.default})(f)},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(14),i=r(o),a=n(110),u=n(114),s=r(u),c=n(179),l=r(c),f=function(e){var t=e.meta,n=t.touched,r=t.error;return!(!n||!r)&&i.default.createElement("span",null,r)},p=function(e){var t=e.handleSubmit,n=e.previousPage;return i.default.createElement("form",{onSubmit:t},i.default.createElement(a.Field,{name:"email",type:"email",component:l.default,label:"Email"}),i.default.createElement("div",null,i.default.createElement("label",null,"Sex"),i.default.createElement("div",null,i.default.createElement("label",null,i.default.createElement(a.Field,{name:"sex",component:"input",type:"radio",value:"male"})," Male"),i.default.createElement("label",null,i.default.createElement(a.Field,{name:"sex",component:"input",type:"radio",value:"female"})," Female"),i.default.createElement(a.Field,{name:"sex",component:f}))),i.default.createElement("div",null,i.default.createElement("button",{type:"button",className:"previous",onClick:n},"Previous"),i.default.createElement("button",{type:"submit",className:"next"},"Next")))};t.default=(0,a.reduxForm)({form:"wizard",destroyOnUnmount:!1,forceUnregisterOnUnmount:!0,validate:s.default})(p)},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(14),i=r(o),a=n(110),u=n(114),s=r(u),c=["Red","Orange","Yellow","Green","Blue","Indigo","Violet"],l=function(e){var t=e.input,n=e.meta,r=n.touched,o=n.error;return i.default.createElement("div",null,i.default.createElement("select",t,i.default.createElement("option",{value:""},"Select a color..."),c.map(function(e){return i.default.createElement("option",{value:e,key:e},e)})),r&&o&&i.default.createElement("span",null,o))},f=function(e){var t=e.handleSubmit,n=e.pristine,r=e.previousPage,o=e.submitting;return i.default.createElement("form",{onSubmit:t},i.default.createElement("div",null,i.default.createElement("label",null,"Favorite Color"),i.default.createElement(a.Field,{name:"favoriteColor",component:l})),i.default.createElement("div",null,i.default.createElement("label",{htmlFor:"employed"},"Employed"),i.default.createElement("div",null,i.default.createElement(a.Field,{name:"employed",id:"employed",component:"input",type:"checkbox"}))),i.default.createElement("div",null,i.default.createElement("label",null,"Notes"),i.default.createElement("div",null,i.default.createElement(a.Field,{name:"notes",component:"textarea",placeholder:"Notes"}))),i.default.createElement("div",null,i.default.createElement("button",{type:"button",className:"previous",onClick:r},"Previous"),i.default.createElement("button",{type:"submit",disabled:n||o},"Submit")))};t.default=(0,a.reduxForm)({form:"wizard",destroyOnUnmount:!1,forceUnregisterOnUnmount:!0,validate:s.default})(f)},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}var o=n(14),i=r(o),a=n(584),u=r(a),s=n(69),c=n(112),l=n(110),f=n(664),p=document.getElementById("content"),d=(0,c.combineReducers)({form:l.reducer}),h=(window.devToolsExtension?window.devToolsExtension()(c.createStore):c.createStore)(d),v=function(e){return new Promise(function(t){setTimeout(function(){window.alert("You submitted:\n\n"+JSON.stringify(e,null,2)),t()},500)})},m=function(){var e=n(275).default,t=n(475),r=n(578),o=n(583),a=n(582),c=n(579),l=n(580),d=n(581);u.default.render(i.default.createElement(s.Provider,{store:h},i.default.createElement(f.App,{version:"6.4.3",path:"/examples/wizard",breadcrumbs:(0,f.generateExampleBreadcrumbs)("wizard","Wizard Form Example","6.4.3")},i.default.createElement(f.Markdown,{content:t}),i.default.createElement("h2",null,"Form"),i.default.createElement(e,{onSubmit:v}),i.default.createElement(f.Values,{form:"wizard"}),i.default.createElement("h2",null,"Code"),i.default.createElement("h4",null,"renderField.js"),i.default.createElement(f.Code,{source:a}),i.default.createElement("h4",null,"WizardForm.js"),i.default.createElement(f.Code,{source:r}),i.default.createElement("h4",null,"validate.js"),i.default.createElement(f.Code,{source:o}),i.default.createElement("h4",null,"WizardFormFirstPage.js"),i.default.createElement(f.Code,{source:c}),i.default.createElement("h4",null,"WizardFormSecondPage.js"),i.default.createElement(f.Code,{source:l}),i.default.createElement("h4",null,"WizardFormThirdPage.js"),i.default.createElement(f.Code,{source:d}))),p)};m()},function(e,t,n){(function(e){"use strict";function t(e,t,n){e[t]||Object[r](e,t,{writable:!0,configurable:!0,value:n})}if(n(461),n(708),n(281),e._babelPolyfill)throw new Error("only one instance of babel-polyfill is allowed");e._babelPolyfill=!0;var r="defineProperty";t(String.prototype,"padLeft","".padStart),t(String.prototype,"padRight","".padEnd),"pop,reverse,shift,keys,values,entries,indexOf,every,some,forEach,map,filter,find,findIndex,includes,join,slice,concat,push,splice,unshift,sort,lastIndexOf,reduce,reduceRight,copyWithin,fill".split(",").forEach(function(e){[][e]&&t(Array,e,Function.call.bind([][e]))})}).call(t,function(){return this}())},function(e,t,n){n(290),e.exports=n(37).RegExp.escape},function(e,t,n){var r=n(8),o=n(123),i=n(9)("species");e.exports=function(e){var t;return o(e)&&(t=e.constructor,"function"!=typeof t||t!==Array&&!o(t.prototype)||(t=void 0),r(t)&&(t=t[i],null===t&&(t=void 0))),void 0===t?Array:t}},function(e,t,n){var r=n(282);e.exports=function(e,t){return new(r(e))(t)}},function(e,t,n){"use strict";var r=n(3),o=n(34),i="number";e.exports=function(e){if("string"!==e&&e!==i&&"default"!==e)throw TypeError("Incorrect hint");return o(r(this),e!=i)}},function(e,t,n){var r=n(52),o=n(93),i=n(75);e.exports=function(e){var t=r(e),n=o.f;if(n)for(var a,u=n(e),s=i.f,c=0;u.length>c;)s.call(e,a=u[c++])&&t.push(a);return t}},function(e,t,n){var r=n(52),o=n(23);e.exports=function(e,t){for(var n,i=o(e),a=r(i),u=a.length,s=0;u>s;)if(i[n=a[s++]]===t)return n}},function(e,t,n){"use strict";var r=n(288),o=n(89),i=n(19);e.exports=function(){for(var e=i(this),t=arguments.length,n=Array(t),a=0,u=r._,s=!1;t>a;)(n[a]=arguments[a++])===u&&(s=!0);return function(){var r,i=this,a=arguments.length,c=0,l=0;if(!s&&!a)return o(e,n,i);if(r=n.slice(),s)for(;t>c;c++)r[c]===u&&(r[c]=arguments[l++]);for(;a>l;)r.push(arguments[l++]);return o(e,r,i)}}},function(e,t,n){e.exports=n(4)},function(e,t){e.exports=function(e,t){var n=t===Object(t)?function(e){return t[e]}:t;return function(t){return String(t).replace(e,n)}}},function(e,t,n){var r=n(1),o=n(289)(/[\\^$*+?.()|[\]{}]/g,"\\$&");r(r.S,"RegExp",{escape:function(e){return o(e)}})},function(e,t,n){var r=n(1);r(r.P,"Array",{copyWithin:n(181)}),n(60)("copyWithin")},function(e,t,n){"use strict";var r=n(1),o=n(32)(4);r(r.P+r.F*!n(28)([].every,!0),"Array",{every:function(e){return o(this,e,arguments[1])}})},function(e,t,n){var r=n(1);r(r.P,"Array",{fill:n(115)}),n(60)("fill")},function(e,t,n){"use strict";var r=n(1),o=n(32)(2);r(r.P+r.F*!n(28)([].filter,!0),"Array",{filter:function(e){return o(this,e,arguments[1])}})},function(e,t,n){"use strict";var r=n(1),o=n(32)(6),i="findIndex",a=!0;i in[]&&Array(1)[i](function(){a=!1}),r(r.P+r.F*a,"Array",{findIndex:function(e){return o(this,e,arguments.length>1?arguments[1]:void 0)}}),n(60)(i)},function(e,t,n){"use strict";var r=n(1),o=n(32)(5),i="find",a=!0;i in[]&&Array(1)[i](function(){a=!1}),r(r.P+r.F*a,"Array",{find:function(e){return o(this,e,arguments.length>1?arguments[1]:void 0)}}),n(60)(i)},function(e,t,n){"use strict";var r=n(1),o=n(32)(0),i=n(28)([].forEach,!0);r(r.P+r.F*!i,"Array",{forEach:function(e){return o(this,e,arguments[1])}})},function(e,t,n){"use strict";var r=n(38),o=n(1),i=n(16),a=n(190),u=n(122),s=n(15),c=n(116),l=n(139);o(o.S+o.F*!n(91)(function(e){Array.from(e)}),"Array",{from:function(e){var t,n,o,f,p=i(e),d="function"==typeof this?this:Array,h=arguments.length,v=h>1?arguments[1]:void 0,m=void 0!==v,y=0,g=l(p);if(m&&(v=r(v,h>2?arguments[2]:void 0,2)),void 0==g||d==Array&&u(g))for(t=s(p.length),n=new d(t);t>y;y++)c(n,y,m?v(p[y],y):p[y]);else for(f=g.call(p),n=new d;!(o=f.next()).done;y++)c(n,y,m?a(f,v,[o.value,y],!0):o.value);return n.length=y,n}})},function(e,t,n){"use strict";var r=n(1),o=n(85)(!1),i=[].indexOf,a=!!i&&1/[1].indexOf(1,-0)<0;r(r.P+r.F*(a||!n(28)(i)),"Array",{indexOf:function(e){return a?i.apply(this,arguments)||0:o(this,e,arguments[1])}})},function(e,t,n){var r=n(1);r(r.S,"Array",{isArray:n(123)})},function(e,t,n){"use strict";var r=n(1),o=n(23),i=[].join;r(r.P+r.F*(n(74)!=Object||!n(28)(i)),"Array",{join:function(e){return i.call(o(this),void 0===e?",":e)}})},function(e,t,n){"use strict";var r=n(1),o=n(23),i=n(45),a=n(15),u=[].lastIndexOf,s=!!u&&1/[1].lastIndexOf(1,-0)<0;r(r.P+r.F*(s||!n(28)(u)),"Array",{lastIndexOf:function(e){if(s)return u.apply(this,arguments)||0;var t=o(this),n=a(t.length),r=n-1;for(arguments.length>1&&(r=Math.min(r,i(arguments[1]))),r<0&&(r=n+r);r>=0;r--)if(r in t&&t[r]===e)return r||0;return-1}})},function(e,t,n){"use strict";var r=n(1),o=n(32)(1);r(r.P+r.F*!n(28)([].map,!0),"Array",{map:function(e){return o(this,e,arguments[1])}})},function(e,t,n){"use strict";var r=n(1),o=n(116);r(r.S+r.F*n(6)(function(){function e(){}return!(Array.of.call(e)instanceof e)}),"Array",{of:function(){for(var e=0,t=arguments.length,n=new("function"==typeof this?this:Array)(t);t>e;)o(n,e,arguments[e++]);return n.length=t,n}})},function(e,t,n){"use strict";var r=n(1),o=n(183);r(r.P+r.F*!n(28)([].reduceRight,!0),"Array",{reduceRight:function(e){return o(this,e,arguments.length,arguments[1],!0)}})},function(e,t,n){"use strict";var r=n(1),o=n(183);r(r.P+r.F*!n(28)([].reduce,!0),"Array",{reduce:function(e){return o(this,e,arguments.length,arguments[1],!1)}})},function(e,t,n){"use strict";var r=n(1),o=n(120),i=n(26),a=n(55),u=n(15),s=[].slice;r(r.P+r.F*n(6)(function(){o&&s.call(o)}),"Array",{slice:function(e,t){var n=u(this.length),r=i(this);if(t=void 0===t?n:t,"Array"==r)return s.call(this,e,t);for(var o=a(e,n),c=a(t,n),l=u(c-o),f=Array(l),p=0;p<l;p++)f[p]="String"==r?this.charAt(o+p):this[o+p];return f}})},function(e,t,n){"use strict";var r=n(1),o=n(32)(3);r(r.P+r.F*!n(28)([].some,!0),"Array",{some:function(e){return o(this,e,arguments[1])}})},function(e,t,n){"use strict";var r=n(1),o=n(19),i=n(16),a=n(6),u=[].sort,s=[1,2,3];r(r.P+r.F*(a(function(){s.sort(void 0)})||!a(function(){s.sort(null)})||!n(28)(u)),"Array",{sort:function(e){return void 0===e?u.call(i(this)):u.call(i(this),o(e))}})},function(e,t,n){n(54)("Array")},function(e,t,n){var r=n(1);r(r.S,"Date",{now:function(){return(new Date).getTime()}})},function(e,t,n){"use strict";var r=n(1),o=n(6),i=Date.prototype.getTime,a=function(e){return e>9?e:"0"+e};r(r.P+r.F*(o(function(){return"0385-07-25T07:06:39.999Z"!=new Date(-5e13-1).toISOString()})||!o(function(){new Date(NaN).toISOString()})),"Date",{toISOString:function(){if(!isFinite(i.call(this)))throw RangeError("Invalid time value");var e=this,t=e.getUTCFullYear(),n=e.getUTCMilliseconds(),r=t<0?"-":t>9999?"+":"";return r+("00000"+Math.abs(t)).slice(r?-6:-4)+"-"+a(e.getUTCMonth()+1)+"-"+a(e.getUTCDate())+"T"+a(e.getUTCHours())+":"+a(e.getUTCMinutes())+":"+a(e.getUTCSeconds())+"."+(n>99?n:"0"+a(n))+"Z"}})},function(e,t,n){"use strict";var r=n(1),o=n(16),i=n(34);r(r.P+r.F*n(6)(function(){return null!==new Date(NaN).toJSON()||1!==Date.prototype.toJSON.call({toISOString:function(){return 1}})}),"Date",{toJSON:function(e){var t=o(this),n=i(t);return"number"!=typeof n||isFinite(n)?t.toISOString():null}})},function(e,t,n){var r=n(9)("toPrimitive"),o=Date.prototype;r in o||n(20)(o,r,n(284))},function(e,t,n){var r=Date.prototype,o="Invalid Date",i="toString",a=r[i],u=r.getTime;new Date(NaN)+""!=o&&n(21)(r,i,function(){var e=u.call(this);return e===e?a.call(this):o})},function(e,t,n){var r=n(1);r(r.P,"Function",{bind:n(184)})},function(e,t,n){"use strict";var r=n(8),o=n(25),i=n(9)("hasInstance"),a=Function.prototype;i in a||n(12).f(a,i,{value:function(e){if("function"!=typeof this||!r(e))return!1;if(!r(this.prototype))return e instanceof this;for(;e=o(e);)if(this.prototype===e)return!0;return!1}})},function(e,t,n){var r=n(12).f,o=n(44),i=n(17),a=Function.prototype,u=/^\s*function ([^ (]*)/,s="name",c=Object.isExtensible||function(){return!0};s in a||n(11)&&r(a,s,{configurable:!0,get:function(){try{var e=this,t=(""+e).match(u)[1];return i(e,s)||!c(e)||r(e,s,o(5,t)),t}catch(e){return""}}})},function(e,t,n){var r=n(1),o=n(192),i=Math.sqrt,a=Math.acosh;r(r.S+r.F*!(a&&710==Math.floor(a(Number.MAX_VALUE))&&a(1/0)==1/0),"Math",{acosh:function(e){return(e=+e)<1?NaN:e>94906265.62425156?Math.log(e)+Math.LN2:o(e-1+i(e-1)*i(e+1))}})},function(e,t,n){function r(e){return isFinite(e=+e)&&0!=e?e<0?-r(-e):Math.log(e+Math.sqrt(e*e+1)):e}var o=n(1),i=Math.asinh;o(o.S+o.F*!(i&&1/i(0)>0),"Math",{asinh:r})},function(e,t,n){var r=n(1),o=Math.atanh;r(r.S+r.F*!(o&&1/o(-0)<0),"Math",{atanh:function(e){return 0==(e=+e)?e:Math.log((1+e)/(1-e))/2}})},function(e,t,n){var r=n(1),o=n(127);r(r.S,"Math",{cbrt:function(e){return o(e=+e)*Math.pow(Math.abs(e),1/3)}})},function(e,t,n){var r=n(1);r(r.S,"Math",{clz32:function(e){return(e>>>=0)?31-Math.floor(Math.log(e+.5)*Math.LOG2E):32}})},function(e,t,n){var r=n(1),o=Math.exp;r(r.S,"Math",{cosh:function(e){return(o(e=+e)+o(-e))/2}})},function(e,t,n){var r=n(1),o=n(126);r(r.S+r.F*(o!=Math.expm1),"Math",{expm1:o})},function(e,t,n){var r=n(1),o=n(127),i=Math.pow,a=i(2,-52),u=i(2,-23),s=i(2,127)*(2-u),c=i(2,-126),l=function(e){return e+1/a-1/a};r(r.S,"Math",{fround:function(e){var t,n,r=Math.abs(e),i=o(e);return r<c?i*l(r/c/u)*c*u:(t=(1+u/a)*r,n=t-(t-r),n>s||n!=n?i*(1/0):i*n)}})},function(e,t,n){var r=n(1),o=Math.abs;r(r.S,"Math",{hypot:function(e,t){for(var n,r,i=0,a=0,u=arguments.length,s=0;a<u;)n=o(arguments[a++]),s<n?(r=s/n,i=i*r*r+1,s=n):n>0?(r=n/s, i+=r*r):i+=n;return s===1/0?1/0:s*Math.sqrt(i)}})},function(e,t,n){var r=n(1),o=Math.imul;r(r.S+r.F*n(6)(function(){return o(4294967295,5)!=-5||2!=o.length}),"Math",{imul:function(e,t){var n=65535,r=+e,o=+t,i=n&r,a=n&o;return 0|i*a+((n&r>>>16)*a+i*(n&o>>>16)<<16>>>0)}})},function(e,t,n){var r=n(1);r(r.S,"Math",{log10:function(e){return Math.log(e)/Math.LN10}})},function(e,t,n){var r=n(1);r(r.S,"Math",{log1p:n(192)})},function(e,t,n){var r=n(1);r(r.S,"Math",{log2:function(e){return Math.log(e)/Math.LN2}})},function(e,t,n){var r=n(1);r(r.S,"Math",{sign:n(127)})},function(e,t,n){var r=n(1),o=n(126),i=Math.exp;r(r.S+r.F*n(6)(function(){return!Math.sinh(-2e-17)!=-2e-17}),"Math",{sinh:function(e){return Math.abs(e=+e)<1?(o(e)-o(-e))/2:(i(e-1)-i(-e-1))*(Math.E/2)}})},function(e,t,n){var r=n(1),o=n(126),i=Math.exp;r(r.S,"Math",{tanh:function(e){var t=o(e=+e),n=o(-e);return t==1/0?1:n==1/0?-1:(t-n)/(i(e)+i(-e))}})},function(e,t,n){var r=n(1);r(r.S,"Math",{trunc:function(e){return(e>0?Math.floor:Math.ceil)(e)}})},function(e,t,n){"use strict";var r=n(4),o=n(17),i=n(26),a=n(121),u=n(34),s=n(6),c=n(51).f,l=n(24).f,f=n(12).f,p=n(64).trim,d="Number",h=r[d],v=h,m=h.prototype,y=i(n(50)(m))==d,g="trim"in String.prototype,b=function(e){var t=u(e,!1);if("string"==typeof t&&t.length>2){t=g?t.trim():p(t,3);var n,r,o,i=t.charCodeAt(0);if(43===i||45===i){if(n=t.charCodeAt(2),88===n||120===n)return NaN}else if(48===i){switch(t.charCodeAt(1)){case 66:case 98:r=2,o=49;break;case 79:case 111:r=8,o=55;break;default:return+t}for(var a,s=t.slice(2),c=0,l=s.length;c<l;c++)if(a=s.charCodeAt(c),a<48||a>o)return NaN;return parseInt(s,r)}}return+t};if(!h(" 0o1")||!h("0b1")||h("+0x1")){h=function(e){var t=arguments.length<1?0:e,n=this;return n instanceof h&&(y?s(function(){m.valueOf.call(n)}):i(n)!=d)?a(new v(b(t)),n,h):b(t)};for(var _,x=n(11)?c(v):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,isFinite,isInteger,isNaN,isSafeInteger,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,parseFloat,parseInt,isInteger".split(","),E=0;x.length>E;E++)o(v,_=x[E])&&!o(h,_)&&f(h,_,l(v,_));h.prototype=m,m.constructor=h,n(21)(r,d,h)}},function(e,t,n){var r=n(1);r(r.S,"Number",{EPSILON:Math.pow(2,-52)})},function(e,t,n){var r=n(1),o=n(4).isFinite;r(r.S,"Number",{isFinite:function(e){return"number"==typeof e&&o(e)}})},function(e,t,n){var r=n(1);r(r.S,"Number",{isInteger:n(189)})},function(e,t,n){var r=n(1);r(r.S,"Number",{isNaN:function(e){return e!=e}})},function(e,t,n){var r=n(1),o=n(189),i=Math.abs;r(r.S,"Number",{isSafeInteger:function(e){return o(e)&&i(e)<=9007199254740991}})},function(e,t,n){var r=n(1);r(r.S,"Number",{MAX_SAFE_INTEGER:9007199254740991})},function(e,t,n){var r=n(1);r(r.S,"Number",{MIN_SAFE_INTEGER:-9007199254740991})},function(e,t,n){var r=n(1),o=n(199);r(r.S+r.F*(Number.parseFloat!=o),"Number",{parseFloat:o})},function(e,t,n){var r=n(1),o=n(200);r(r.S+r.F*(Number.parseInt!=o),"Number",{parseInt:o})},function(e,t,n){"use strict";var r=n(1),o=n(45),i=n(180),a=n(134),u=1..toFixed,s=Math.floor,c=[0,0,0,0,0,0],l="Number.toFixed: incorrect invocation!",f="0",p=function(e,t){for(var n=-1,r=t;++n<6;)r+=e*c[n],c[n]=r%1e7,r=s(r/1e7)},d=function(e){for(var t=6,n=0;--t>=0;)n+=c[t],c[t]=s(n/e),n=n%e*1e7},h=function(){for(var e=6,t="";--e>=0;)if(""!==t||0===e||0!==c[e]){var n=String(c[e]);t=""===t?n:t+a.call(f,7-n.length)+n}return t},v=function(e,t,n){return 0===t?n:t%2===1?v(e,t-1,n*e):v(e*e,t/2,n)},m=function(e){for(var t=0,n=e;n>=4096;)t+=12,n/=4096;for(;n>=2;)t+=1,n/=2;return t};r(r.P+r.F*(!!u&&("0.000"!==8e-5.toFixed(3)||"1"!==.9.toFixed(0)||"1.25"!==1.255.toFixed(2)||"1000000000000000128"!==(0xde0b6b3a7640080).toFixed(0))||!n(6)(function(){u.call({})})),"Number",{toFixed:function(e){var t,n,r,u,s=i(this,l),c=o(e),y="",g=f;if(c<0||c>20)throw RangeError(l);if(s!=s)return"NaN";if(s<=-1e21||s>=1e21)return String(s);if(s<0&&(y="-",s=-s),s>1e-21)if(t=m(s*v(2,69,1))-69,n=t<0?s*v(2,-t,1):s/v(2,t,1),n*=4503599627370496,t=52-t,t>0){for(p(0,n),r=c;r>=7;)p(1e7,0),r-=7;for(p(v(10,r,1),0),r=t-1;r>=23;)d(1<<23),r-=23;d(1<<r),p(1,1),d(2),g=h()}else p(0,n),p(1<<-t,0),g=h()+a.call(f,c);return c>0?(u=g.length,g=y+(u<=c?"0."+a.call(f,c-u)+g:g.slice(0,u-c)+"."+g.slice(u-c))):g=y+g,g}})},function(e,t,n){"use strict";var r=n(1),o=n(6),i=n(180),a=1..toPrecision;r(r.P+r.F*(o(function(){return"1"!==a.call(1,void 0)})||!o(function(){a.call({})})),"Number",{toPrecision:function(e){var t=i(this,"Number#toPrecision: incorrect invocation!");return void 0===e?a.call(t):a.call(t,e)}})},function(e,t,n){var r=n(1);r(r.S+r.F,"Object",{assign:n(193)})},function(e,t,n){var r=n(1);r(r.S,"Object",{create:n(50)})},function(e,t,n){var r=n(1);r(r.S+r.F*!n(11),"Object",{defineProperties:n(194)})},function(e,t,n){var r=n(1);r(r.S+r.F*!n(11),"Object",{defineProperty:n(12).f})},function(e,t,n){var r=n(8),o=n(43).onFreeze;n(33)("freeze",function(e){return function(t){return e&&r(t)?e(o(t)):t}})},function(e,t,n){var r=n(23),o=n(24).f;n(33)("getOwnPropertyDescriptor",function(){return function(e,t){return o(r(e),t)}})},function(e,t,n){n(33)("getOwnPropertyNames",function(){return n(195).f})},function(e,t,n){var r=n(16),o=n(25);n(33)("getPrototypeOf",function(){return function(e){return o(r(e))}})},function(e,t,n){var r=n(8);n(33)("isExtensible",function(e){return function(t){return!!r(t)&&(!e||e(t))}})},function(e,t,n){var r=n(8);n(33)("isFrozen",function(e){return function(t){return!r(t)||!!e&&e(t)}})},function(e,t,n){var r=n(8);n(33)("isSealed",function(e){return function(t){return!r(t)||!!e&&e(t)}})},function(e,t,n){var r=n(1);r(r.S,"Object",{is:n(201)})},function(e,t,n){var r=n(16),o=n(52);n(33)("keys",function(){return function(e){return o(r(e))}})},function(e,t,n){var r=n(8),o=n(43).onFreeze;n(33)("preventExtensions",function(e){return function(t){return e&&r(t)?e(o(t)):t}})},function(e,t,n){var r=n(8),o=n(43).onFreeze;n(33)("seal",function(e){return function(t){return e&&r(t)?e(o(t)):t}})},function(e,t,n){var r=n(1);r(r.S,"Object",{setPrototypeOf:n(129).set})},function(e,t,n){"use strict";var r=n(73),o={};o[n(9)("toStringTag")]="z",o+""!="[object z]"&&n(21)(Object.prototype,"toString",function(){return"[object "+r(this)+"]"},!0)},function(e,t,n){var r=n(1),o=n(199);r(r.G+r.F*(parseFloat!=o),{parseFloat:o})},function(e,t,n){var r=n(1),o=n(200);r(r.G+r.F*(parseInt!=o),{parseInt:o})},function(e,t,n){"use strict";var r,o,i,a=n(49),u=n(4),s=n(38),c=n(73),l=n(1),f=n(8),p=n(19),d=n(48),h=n(61),v=n(131),m=n(136).set,y=n(128)(),g="Promise",b=u.TypeError,_=u.process,x=u[g],_=u.process,E="process"==c(_),w=function(){},S=!!function(){try{var e=x.resolve(1),t=(e.constructor={})[n(9)("species")]=function(e){e(w,w)};return(E||"function"==typeof PromiseRejectionEvent)&&e.then(w)instanceof t}catch(e){}}(),C=function(e,t){return e===t||e===x&&t===i},P=function(e){var t;return!(!f(e)||"function"!=typeof(t=e.then))&&t},O=function(e){return C(x,e)?new T(e):new o(e)},T=o=function(e){var t,n;this.promise=new e(function(e,r){if(void 0!==t||void 0!==n)throw b("Bad Promise constructor");t=e,n=r}),this.resolve=p(t),this.reject=p(n)},k=function(e){try{e()}catch(e){return{error:e}}},A=function(e,t){if(!e._n){e._n=!0;var n=e._c;y(function(){for(var r=e._v,o=1==e._s,i=0,a=function(t){var n,i,a=o?t.ok:t.fail,u=t.resolve,s=t.reject,c=t.domain;try{a?(o||(2==e._h&&I(e),e._h=1),a===!0?n=r:(c&&c.enter(),n=a(r),c&&c.exit()),n===t.promise?s(b("Promise-chain cycle")):(i=P(n))?i.call(n,u,s):u(n)):s(r)}catch(e){s(e)}};n.length>i;)a(n[i++]);e._c=[],e._n=!1,t&&!e._h&&R(e)})}},R=function(e){m.call(u,function(){var t,n,r,o=e._v;if(M(e)&&(t=k(function(){E?_.emit("unhandledRejection",o,e):(n=u.onunhandledrejection)?n({promise:e,reason:o}):(r=u.console)&&r.error&&r.error("Unhandled promise rejection",o)}),e._h=E||M(e)?2:1),e._a=void 0,t)throw t.error})},M=function(e){if(1==e._h)return!1;for(var t,n=e._a||e._c,r=0;n.length>r;)if(t=n[r++],t.fail||!M(t.promise))return!1;return!0},I=function(e){m.call(u,function(){var t;E?_.emit("rejectionHandled",e):(t=u.onrejectionhandled)&&t({promise:e,reason:e._v})})},N=function(e){var t=this;t._d||(t._d=!0,t=t._w||t,t._v=e,t._s=2,t._a||(t._a=t._c.slice()),A(t,!0))},j=function(e){var t,n=this;if(!n._d){n._d=!0,n=n._w||n;try{if(n===e)throw b("Promise can't be resolved itself");(t=P(e))?y(function(){var r={_w:n,_d:!1};try{t.call(e,s(j,r,1),s(N,r,1))}catch(e){N.call(r,e)}}):(n._v=e,n._s=1,A(n,!1))}catch(e){N.call({_w:n,_d:!1},e)}}};S||(x=function(e){d(this,x,g,"_h"),p(e),r.call(this);try{e(s(j,this,1),s(N,this,1))}catch(e){N.call(this,e)}},r=function(e){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1},r.prototype=n(53)(x.prototype,{then:function(e,t){var n=O(v(this,x));return n.ok="function"!=typeof e||e,n.fail="function"==typeof t&&t,n.domain=E?_.domain:void 0,this._c.push(n),this._a&&this._a.push(n),this._s&&A(this,!1),n.promise},catch:function(e){return this.then(void 0,e)}}),T=function(){var e=new r;this.promise=e,this.resolve=s(j,e,1),this.reject=s(N,e,1)}),l(l.G+l.W+l.F*!S,{Promise:x}),n(63)(x,g),n(54)(g),i=n(37)[g],l(l.S+l.F*!S,g,{reject:function(e){var t=O(this),n=t.reject;return n(e),t.promise}}),l(l.S+l.F*(a||!S),g,{resolve:function(e){if(e instanceof x&&C(e.constructor,this))return e;var t=O(this),n=t.resolve;return n(e),t.promise}}),l(l.S+l.F*!(S&&n(91)(function(e){x.all(e).catch(w)})),g,{all:function(e){var t=this,n=O(t),r=n.resolve,o=n.reject,i=k(function(){var n=[],i=0,a=1;h(e,!1,function(e){var u=i++,s=!1;n.push(void 0),a++,t.resolve(e).then(function(e){s||(s=!0,n[u]=e,--a||r(n))},o)}),--a||r(n)});return i&&o(i.error),n.promise},race:function(e){var t=this,n=O(t),r=n.reject,o=k(function(){h(e,!1,function(e){t.resolve(e).then(n.resolve,r)})});return o&&r(o.error),n.promise}})},function(e,t,n){var r=n(1),o=n(19),i=n(3),a=(n(4).Reflect||{}).apply,u=Function.apply;r(r.S+r.F*!n(6)(function(){a(function(){})}),"Reflect",{apply:function(e,t,n){var r=o(e),s=i(n);return a?a(r,t,s):u.call(r,t,s)}})},function(e,t,n){var r=n(1),o=n(50),i=n(19),a=n(3),u=n(8),s=n(6),c=n(184),l=(n(4).Reflect||{}).construct,f=s(function(){function e(){}return!(l(function(){},[],e)instanceof e)}),p=!s(function(){l(function(){})});r(r.S+r.F*(f||p),"Reflect",{construct:function(e,t){i(e),a(t);var n=arguments.length<3?e:i(arguments[2]);if(p&&!f)return l(e,t,n);if(e==n){switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3])}var r=[null];return r.push.apply(r,t),new(c.apply(e,r))}var s=n.prototype,d=o(u(s)?s:Object.prototype),h=Function.apply.call(e,d,t);return u(h)?h:d}})},function(e,t,n){var r=n(12),o=n(1),i=n(3),a=n(34);o(o.S+o.F*n(6)(function(){Reflect.defineProperty(r.f({},1,{value:1}),1,{value:2})}),"Reflect",{defineProperty:function(e,t,n){i(e),t=a(t,!0),i(n);try{return r.f(e,t,n),!0}catch(e){return!1}}})},function(e,t,n){var r=n(1),o=n(24).f,i=n(3);r(r.S,"Reflect",{deleteProperty:function(e,t){var n=o(i(e),t);return!(n&&!n.configurable)&&delete e[t]}})},function(e,t,n){"use strict";var r=n(1),o=n(3),i=function(e){this._t=o(e),this._i=0;var t,n=this._k=[];for(t in e)n.push(t)};n(124)(i,"Object",function(){var e,t=this,n=t._k;do if(t._i>=n.length)return{value:void 0,done:!0};while(!((e=n[t._i++])in t._t));return{value:e,done:!1}}),r(r.S,"Reflect",{enumerate:function(e){return new i(e)}})},function(e,t,n){var r=n(24),o=n(1),i=n(3);o(o.S,"Reflect",{getOwnPropertyDescriptor:function(e,t){return r.f(i(e),t)}})},function(e,t,n){var r=n(1),o=n(25),i=n(3);r(r.S,"Reflect",{getPrototypeOf:function(e){return o(i(e))}})},function(e,t,n){function r(e,t){var n,u,l=arguments.length<3?e:arguments[2];return c(e)===l?e[t]:(n=o.f(e,t))?a(n,"value")?n.value:void 0!==n.get?n.get.call(l):void 0:s(u=i(e))?r(u,t,l):void 0}var o=n(24),i=n(25),a=n(17),u=n(1),s=n(8),c=n(3);u(u.S,"Reflect",{get:r})},function(e,t,n){var r=n(1);r(r.S,"Reflect",{has:function(e,t){return t in e}})},function(e,t,n){var r=n(1),o=n(3),i=Object.isExtensible;r(r.S,"Reflect",{isExtensible:function(e){return o(e),!i||i(e)}})},function(e,t,n){var r=n(1);r(r.S,"Reflect",{ownKeys:n(198)})},function(e,t,n){var r=n(1),o=n(3),i=Object.preventExtensions;r(r.S,"Reflect",{preventExtensions:function(e){o(e);try{return i&&i(e),!0}catch(e){return!1}}})},function(e,t,n){var r=n(1),o=n(129);o&&r(r.S,"Reflect",{setPrototypeOf:function(e,t){o.check(e,t);try{return o.set(e,t),!0}catch(e){return!1}}})},function(e,t,n){function r(e,t,n){var s,p,d=arguments.length<4?e:arguments[3],h=i.f(l(e),t);if(!h){if(f(p=a(e)))return r(p,t,n,d);h=c(0)}return u(h,"value")?!(h.writable===!1||!f(d))&&(s=i.f(d,t)||c(0),s.value=n,o.f(d,t,s),!0):void 0!==h.set&&(h.set.call(d,n),!0)}var o=n(12),i=n(24),a=n(25),u=n(17),s=n(1),c=n(44),l=n(3),f=n(8);s(s.S,"Reflect",{set:r})},function(e,t,n){var r=n(4),o=n(121),i=n(12).f,a=n(51).f,u=n(90),s=n(88),c=r.RegExp,l=c,f=c.prototype,p=/a/g,d=/a/g,h=new c(p)!==p;if(n(11)&&(!h||n(6)(function(){return d[n(9)("match")]=!1,c(p)!=p||c(d)==d||"/a/i"!=c(p,"i")}))){c=function(e,t){var n=this instanceof c,r=u(e),i=void 0===t;return!n&&r&&e.constructor===c&&i?e:o(h?new l(r&&!i?e.source:e,t):l((r=e instanceof c)?e.source:e,r&&i?s.call(e):t),n?this:f,c)};for(var v=(function(e){e in c||i(c,e,{configurable:!0,get:function(){return l[e]},set:function(t){l[e]=t}})}),m=a(l),y=0;m.length>y;)v(m[y++]);f.constructor=c,c.prototype=f,n(21)(r,"RegExp",c)}n(54)("RegExp")},function(e,t,n){n(87)("match",1,function(e,t,n){return[function(n){"use strict";var r=e(this),o=void 0==n?void 0:n[t];return void 0!==o?o.call(n,r):new RegExp(n)[t](String(r))},n]})},function(e,t,n){n(87)("replace",2,function(e,t,n){return[function(r,o){"use strict";var i=e(this),a=void 0==r?void 0:r[t];return void 0!==a?a.call(r,i,o):n.call(String(i),r,o)},n]})},function(e,t,n){n(87)("search",1,function(e,t,n){return[function(n){"use strict";var r=e(this),o=void 0==n?void 0:n[t];return void 0!==o?o.call(n,r):new RegExp(n)[t](String(r))},n]})},function(e,t,n){n(87)("split",2,function(e,t,r){"use strict";var o=n(90),i=r,a=[].push,u="split",s="length",c="lastIndex";if("c"=="abbc"[u](/(b)*/)[1]||4!="test"[u](/(?:)/,-1)[s]||2!="ab"[u](/(?:ab)*/)[s]||4!="."[u](/(.?)(.?)/)[s]||"."[u](/()()/)[s]>1||""[u](/.?/)[s]){var l=void 0===/()??/.exec("")[1];r=function(e,t){var n=String(this);if(void 0===e&&0===t)return[];if(!o(e))return i.call(n,e,t);var r,u,f,p,d,h=[],v=(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.unicode?"u":"")+(e.sticky?"y":""),m=0,y=void 0===t?4294967295:t>>>0,g=new RegExp(e.source,v+"g");for(l||(r=new RegExp("^"+g.source+"$(?!\\s)",v));(u=g.exec(n))&&(f=u.index+u[0][s],!(f>m&&(h.push(n.slice(m,u.index)),!l&&u[s]>1&&u[0].replace(r,function(){for(d=1;d<arguments[s]-2;d++)void 0===arguments[d]&&(u[d]=void 0)}),u[s]>1&&u.index<n[s]&&a.apply(h,u.slice(1)),p=u[0][s],m=f,h[s]>=y)));)g[c]===u.index&&g[c]++;return m===n[s]?!p&&g.test("")||h.push(""):h.push(n.slice(m)),h[s]>y?h.slice(0,y):h}}else"0"[u](void 0,0)[s]&&(r=function(e,t){return void 0===e&&0===t?[]:i.call(this,e,t)});return[function(n,o){var i=e(this),a=void 0==n?void 0:n[t];return void 0!==a?a.call(n,i,o):r.call(String(i),n,o)},r]})},function(e,t,n){"use strict";n(205);var r=n(3),o=n(88),i=n(11),a="toString",u=/./[a],s=function(e){n(21)(RegExp.prototype,a,e,!0)};n(6)(function(){return"/a/b"!=u.call({source:"a",flags:"b"})})?s(function(){var e=r(this);return"/".concat(e.source,"/","flags"in e?e.flags:!i&&e instanceof RegExp?o.call(e):void 0)}):u.name!=a&&s(function(){return u.call(this)})},function(e,t,n){"use strict";n(22)("anchor",function(e){return function(t){return e(this,"a","name",t)}})},function(e,t,n){"use strict";n(22)("big",function(e){return function(){return e(this,"big","","")}})},function(e,t,n){"use strict";n(22)("blink",function(e){return function(){return e(this,"blink","","")}})},function(e,t,n){"use strict";n(22)("bold",function(e){return function(){return e(this,"b","","")}})},function(e,t,n){"use strict";var r=n(1),o=n(132)(!1);r(r.P,"String",{codePointAt:function(e){return o(this,e)}})},function(e,t,n){"use strict";var r=n(1),o=n(15),i=n(133),a="endsWith",u=""[a];r(r.P+r.F*n(119)(a),"String",{endsWith:function(e){var t=i(this,e,a),n=arguments.length>1?arguments[1]:void 0,r=o(t.length),s=void 0===n?r:Math.min(o(n),r),c=String(e);return u?u.call(t,c,s):t.slice(s-c.length,s)===c}})},function(e,t,n){"use strict";n(22)("fixed",function(e){return function(){return e(this,"tt","","")}})},function(e,t,n){"use strict";n(22)("fontcolor",function(e){return function(t){return e(this,"font","color",t)}})},function(e,t,n){"use strict";n(22)("fontsize",function(e){return function(t){return e(this,"font","size",t)}})},function(e,t,n){var r=n(1),o=n(55),i=String.fromCharCode,a=String.fromCodePoint;r(r.S+r.F*(!!a&&1!=a.length),"String",{fromCodePoint:function(e){for(var t,n=[],r=arguments.length,a=0;r>a;){if(t=+arguments[a++],o(t,1114111)!==t)throw RangeError(t+" is not a valid code point");n.push(t<65536?i(t):i(((t-=65536)>>10)+55296,t%1024+56320))}return n.join("")}})},function(e,t,n){"use strict";var r=n(1),o=n(133),i="includes";r(r.P+r.F*n(119)(i),"String",{includes:function(e){return!!~o(this,e,i).indexOf(e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){"use strict";n(22)("italics",function(e){return function(){return e(this,"i","","")}})},function(e,t,n){"use strict";var r=n(132)(!0);n(125)(String,"String",function(e){this._t=String(e),this._i=0},function(){var e,t=this._t,n=this._i;return n>=t.length?{value:void 0,done:!0}:(e=r(t,n),this._i+=e.length,{value:e,done:!1})})},function(e,t,n){"use strict";n(22)("link",function(e){return function(t){return e(this,"a","href",t)}})},function(e,t,n){var r=n(1),o=n(23),i=n(15);r(r.S,"String",{raw:function(e){for(var t=o(e.raw),n=i(t.length),r=arguments.length,a=[],u=0;n>u;)a.push(String(t[u++])),u<r&&a.push(String(arguments[u]));return a.join("")}})},function(e,t,n){var r=n(1);r(r.P,"String",{repeat:n(134)})},function(e,t,n){"use strict";n(22)("small",function(e){return function(){return e(this,"small","","")}})},function(e,t,n){"use strict";var r=n(1),o=n(15),i=n(133),a="startsWith",u=""[a];r(r.P+r.F*n(119)(a),"String",{startsWith:function(e){var t=i(this,e,a),n=o(Math.min(arguments.length>1?arguments[1]:void 0,t.length)),r=String(e);return u?u.call(t,r,n):t.slice(n,n+r.length)===r}})},function(e,t,n){"use strict";n(22)("strike",function(e){return function(){return e(this,"strike","","")}})},function(e,t,n){"use strict";n(22)("sub",function(e){return function(){return e(this,"sub","","")}})},function(e,t,n){"use strict";n(22)("sup",function(e){return function(){return e(this,"sup","","")}})},function(e,t,n){"use strict";n(64)("trim",function(e){return function(){return e(this,3)}})},function(e,t,n){"use strict";var r=n(4),o=n(17),i=n(11),a=n(1),u=n(21),s=n(43).KEY,c=n(6),l=n(94),f=n(63),p=n(56),d=n(9),h=n(203),v=n(138),m=n(286),y=n(285),g=n(123),b=n(3),_=n(23),x=n(34),E=n(44),w=n(50),S=n(195),C=n(24),P=n(12),O=n(52),T=C.f,k=P.f,A=S.f,R=r.Symbol,M=r.JSON,I=M&&M.stringify,N="prototype",j=d("_hidden"),F=d("toPrimitive"),D={}.propertyIsEnumerable,U=l("symbol-registry"),L=l("symbols"),V=l("op-symbols"),W=Object[N],B="function"==typeof R,q=r.QObject,z=!q||!q[N]||!q[N].findChild,H=i&&c(function(){return 7!=w(k({},"a",{get:function(){return k(this,"a",{value:7}).a}})).a})?function(e,t,n){var r=T(W,t);r&&delete W[t],k(e,t,n),r&&e!==W&&k(W,t,r)}:k,Y=function(e){var t=L[e]=w(R[N]);return t._k=e,t},K=B&&"symbol"==typeof R.iterator?function(e){return"symbol"==typeof e}:function(e){return e instanceof R},G=function(e,t,n){return e===W&&G(V,t,n),b(e),t=x(t,!0),b(n),o(L,t)?(n.enumerable?(o(e,j)&&e[j][t]&&(e[j][t]=!1),n=w(n,{enumerable:E(0,!1)})):(o(e,j)||k(e,j,E(1,{})),e[j][t]=!0),H(e,t,n)):k(e,t,n)},$=function(e,t){b(e);for(var n,r=y(t=_(t)),o=0,i=r.length;i>o;)G(e,n=r[o++],t[n]);return e},X=function(e,t){return void 0===t?w(e):$(w(e),t)},Q=function(e){var t=D.call(this,e=x(e,!0));return!(this===W&&o(L,e)&&!o(V,e))&&(!(t||!o(this,e)||!o(L,e)||o(this,j)&&this[j][e])||t)},J=function(e,t){if(e=_(e),t=x(t,!0),e!==W||!o(L,t)||o(V,t)){var n=T(e,t);return!n||!o(L,t)||o(e,j)&&e[j][t]||(n.enumerable=!0),n}},Z=function(e){for(var t,n=A(_(e)),r=[],i=0;n.length>i;)o(L,t=n[i++])||t==j||t==s||r.push(t);return r},ee=function(e){for(var t,n=e===W,r=A(n?V:_(e)),i=[],a=0;r.length>a;)!o(L,t=r[a++])||n&&!o(W,t)||i.push(L[t]);return i};B||(R=function(){if(this instanceof R)throw TypeError("Symbol is not a constructor!");var e=p(arguments.length>0?arguments[0]:void 0),t=function(n){this===W&&t.call(V,n),o(this,j)&&o(this[j],e)&&(this[j][e]=!1),H(this,e,E(1,n))};return i&&z&&H(W,e,{configurable:!0,set:t}),Y(e)},u(R[N],"toString",function(){return this._k}),C.f=J,P.f=G,n(51).f=S.f=Z,n(75).f=Q,n(93).f=ee,i&&!n(49)&&u(W,"propertyIsEnumerable",Q,!0),h.f=function(e){return Y(d(e))}),a(a.G+a.W+a.F*!B,{Symbol:R});for(var te="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),ne=0;te.length>ne;)d(te[ne++]);for(var te=O(d.store),ne=0;te.length>ne;)v(te[ne++]);a(a.S+a.F*!B,"Symbol",{for:function(e){return o(U,e+="")?U[e]:U[e]=R(e)},keyFor:function(e){if(K(e))return m(U,e);throw TypeError(e+" is not a symbol!")},useSetter:function(){z=!0},useSimple:function(){z=!1}}),a(a.S+a.F*!B,"Object",{create:X,defineProperty:G,defineProperties:$,getOwnPropertyDescriptor:J,getOwnPropertyNames:Z,getOwnPropertySymbols:ee}),M&&a(a.S+a.F*(!B||c(function(){var e=R();return"[null]"!=I([e])||"{}"!=I({a:e})||"{}"!=I(Object(e))})),"JSON",{stringify:function(e){if(void 0!==e&&!K(e)){for(var t,n,r=[e],o=1;arguments.length>o;)r.push(arguments[o++]);return t=r[1],"function"==typeof t&&(n=t),!n&&g(t)||(t=function(e,t){if(n&&(t=n.call(this,e,t)),!K(t))return t}),r[1]=t,I.apply(M,r)}}}),R[N][F]||n(20)(R[N],F,R[N].valueOf),f(R,"Symbol"),f(Math,"Math",!0),f(r.JSON,"JSON",!0)},function(e,t,n){"use strict";var r=n(1),o=n(95),i=n(137),a=n(3),u=n(55),s=n(15),c=n(8),l=n(4).ArrayBuffer,f=n(131),p=i.ArrayBuffer,d=i.DataView,h=o.ABV&&l.isView,v=p.prototype.slice,m=o.VIEW,y="ArrayBuffer";r(r.G+r.W+r.F*(l!==p),{ArrayBuffer:p}),r(r.S+r.F*!o.CONSTR,y,{isView:function(e){return h&&h(e)||c(e)&&m in e}}),r(r.P+r.U+r.F*n(6)(function(){return!new p(2).slice(1,void 0).byteLength}),y,{slice:function(e,t){if(void 0!==v&&void 0===t)return v.call(a(this),e);for(var n=a(this).byteLength,r=u(e,n),o=u(void 0===t?n:t,n),i=new(f(this,p))(s(o-r)),c=new d(this),l=new d(i),h=0;r<o;)l.setUint8(h++,c.getUint8(r++));return i}}),n(54)(y)},function(e,t,n){var r=n(1);r(r.G+r.W+r.F*!n(95).ABV,{DataView:n(137).DataView})},function(e,t,n){n(40)("Float32",4,function(e){return function(t,n,r){return e(this,t,n,r)}})},function(e,t,n){n(40)("Float64",8,function(e){return function(t,n,r){return e(this,t,n,r)}})},function(e,t,n){n(40)("Int16",2,function(e){return function(t,n,r){return e(this,t,n,r)}})},function(e,t,n){n(40)("Int32",4,function(e){return function(t,n,r){return e(this,t,n,r)}})},function(e,t,n){n(40)("Int8",1,function(e){return function(t,n,r){return e(this,t,n,r)}})},function(e,t,n){n(40)("Uint16",2,function(e){return function(t,n,r){return e(this,t,n,r)}})},function(e,t,n){n(40)("Uint32",4,function(e){return function(t,n,r){return e(this,t,n,r)}})},function(e,t,n){n(40)("Uint8",1,function(e){return function(t,n,r){return e(this,t,n,r)}})},function(e,t,n){n(40)("Uint8",1,function(e){return function(t,n,r){return e(this,t,n,r)}},!0)},function(e,t,n){"use strict";var r=n(187);n(86)("WeakSet",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{add:function(e){return r.def(this,e,!0)}},r,!1,!0)},function(e,t,n){"use strict";var r=n(1),o=n(85)(!0);r(r.P,"Array",{includes:function(e){return o(this,e,arguments.length>1?arguments[1]:void 0)}}),n(60)("includes")},function(e,t,n){var r=n(1),o=n(128)(),i=n(4).process,a="process"==n(26)(i);r(r.G,{asap:function(e){var t=a&&i.domain;o(t?t.bind(e):e)}})},function(e,t,n){var r=n(1),o=n(26);r(r.S,"Error",{isError:function(e){return"Error"===o(e)}})},function(e,t,n){var r=n(1);r(r.P+r.R,"Map",{toJSON:n(186)("Map")})},function(e,t,n){var r=n(1);r(r.S,"Math",{iaddh:function(e,t,n,r){var o=e>>>0,i=t>>>0,a=n>>>0;return i+(r>>>0)+((o&a|(o|a)&~(o+a>>>0))>>>31)|0}})},function(e,t,n){var r=n(1);r(r.S,"Math",{imulh:function(e,t){var n=65535,r=+e,o=+t,i=r&n,a=o&n,u=r>>16,s=o>>16,c=(u*a>>>0)+(i*a>>>16);return u*s+(c>>16)+((i*s>>>0)+(c&n)>>16)}})},function(e,t,n){var r=n(1);r(r.S,"Math",{isubh:function(e,t,n,r){var o=e>>>0,i=t>>>0,a=n>>>0;return i-(r>>>0)-((~o&a|~(o^a)&o-a>>>0)>>>31)|0}})},function(e,t,n){var r=n(1);r(r.S,"Math",{umulh:function(e,t){var n=65535,r=+e,o=+t,i=r&n,a=o&n,u=r>>>16,s=o>>>16,c=(u*a>>>0)+(i*a>>>16);return u*s+(c>>>16)+((i*s>>>0)+(c&n)>>>16)}})},function(e,t,n){"use strict";var r=n(1),o=n(16),i=n(19),a=n(12);n(11)&&r(r.P+n(92),"Object",{__defineGetter__:function(e,t){a.f(o(this),e,{get:i(t),enumerable:!0,configurable:!0})}})},function(e,t,n){"use strict";var r=n(1),o=n(16),i=n(19),a=n(12);n(11)&&r(r.P+n(92),"Object",{__defineSetter__:function(e,t){a.f(o(this),e,{set:i(t),enumerable:!0,configurable:!0})}})},function(e,t,n){var r=n(1),o=n(197)(!0);r(r.S,"Object",{entries:function(e){return o(e)}})},function(e,t,n){var r=n(1),o=n(198),i=n(23),a=n(24),u=n(116);r(r.S,"Object",{getOwnPropertyDescriptors:function(e){for(var t,n=i(e),r=a.f,s=o(n),c={},l=0;s.length>l;)u(c,t=s[l++],r(n,t));return c}})},function(e,t,n){"use strict";var r=n(1),o=n(16),i=n(34),a=n(25),u=n(24).f;n(11)&&r(r.P+n(92),"Object",{__lookupGetter__:function(e){var t,n=o(this),r=i(e,!0);do if(t=u(n,r))return t.get;while(n=a(n))}})},function(e,t,n){"use strict";var r=n(1),o=n(16),i=n(34),a=n(25),u=n(24).f;n(11)&&r(r.P+n(92),"Object",{__lookupSetter__:function(e){var t,n=o(this),r=i(e,!0);do if(t=u(n,r))return t.set;while(n=a(n))}})},function(e,t,n){var r=n(1),o=n(197)(!1);r(r.S,"Object",{values:function(e){return o(e)}})},function(e,t,n){"use strict";var r=n(1),o=n(4),i=n(37),a=n(128)(),u=n(9)("observable"),s=n(19),c=n(3),l=n(48),f=n(53),p=n(20),d=n(61),h=d.RETURN,v=function(e){return null==e?void 0:s(e)},m=function(e){var t=e._c;t&&(e._c=void 0,t())},y=function(e){return void 0===e._o},g=function(e){y(e)||(e._o=void 0,m(e))},b=function(e,t){c(e),this._c=void 0,this._o=e,e=new _(this);try{var n=t(e),r=n;null!=n&&("function"==typeof n.unsubscribe?n=function(){r.unsubscribe()}:s(n),this._c=n)}catch(t){return void e.error(t)}y(this)&&m(this)};b.prototype=f({},{unsubscribe:function(){g(this)}});var _=function(e){this._s=e};_.prototype=f({},{next:function(e){var t=this._s;if(!y(t)){var n=t._o;try{var r=v(n.next);if(r)return r.call(n,e)}catch(e){try{g(t)}finally{throw e}}}},error:function(e){var t=this._s;if(y(t))throw e;var n=t._o;t._o=void 0;try{var r=v(n.error);if(!r)throw e;e=r.call(n,e)}catch(e){try{m(t)}finally{throw e}}return m(t),e},complete:function(e){var t=this._s;if(!y(t)){var n=t._o;t._o=void 0;try{var r=v(n.complete);e=r?r.call(n,e):void 0}catch(e){try{m(t)}finally{throw e}}return m(t),e}}});var x=function(e){l(this,x,"Observable","_f")._f=s(e)};f(x.prototype,{subscribe:function(e){return new b(e,this._f)},forEach:function(e){var t=this;return new(i.Promise||o.Promise)(function(n,r){s(e);var o=t.subscribe({next:function(t){try{return e(t)}catch(e){r(e),o.unsubscribe()}},error:r,complete:n})})}}),f(x,{from:function(e){var t="function"==typeof this?this:x,n=v(c(e)[u]);if(n){var r=c(n.call(e));return r.constructor===t?r:new t(function(e){return r.subscribe(e)})}return new t(function(t){var n=!1;return a(function(){if(!n){try{if(d(e,!1,function(e){if(t.next(e),n)return h})===h)return}catch(e){if(n)throw e;return void t.error(e)}t.complete()}}),function(){n=!0}})},of:function(){for(var e=0,t=arguments.length,n=Array(t);e<t;)n[e]=arguments[e++];return new("function"==typeof this?this:x)(function(e){var t=!1;return a(function(){if(!t){for(var r=0;r<n.length;++r)if(e.next(n[r]),t)return;e.complete()}}),function(){t=!0}})}}),p(x.prototype,u,function(){return this}),r(r.G,{Observable:x}),n(54)("Observable")},function(e,t,n){var r=n(39),o=n(3),i=r.key,a=r.set;r.exp({defineMetadata:function(e,t,n,r){a(e,t,o(n),i(r))}})},function(e,t,n){var r=n(39),o=n(3),i=r.key,a=r.map,u=r.store;r.exp({deleteMetadata:function(e,t){var n=arguments.length<3?void 0:i(arguments[2]),r=a(o(t),n,!1);if(void 0===r||!r.delete(e))return!1;if(r.size)return!0;var s=u.get(t);return s.delete(n),!!s.size||u.delete(t)}})},function(e,t,n){var r=n(206),o=n(182),i=n(39),a=n(3),u=n(25),s=i.keys,c=i.key,l=function(e,t){var n=s(e,t),i=u(e);if(null===i)return n;var a=l(i,t);return a.length?n.length?o(new r(n.concat(a))):a:n};i.exp({getMetadataKeys:function(e){return l(a(e),arguments.length<2?void 0:c(arguments[1]))}})},function(e,t,n){var r=n(39),o=n(3),i=n(25),a=r.has,u=r.get,s=r.key,c=function(e,t,n){var r=a(e,t,n);if(r)return u(e,t,n);var o=i(t);return null!==o?c(e,o,n):void 0};r.exp({getMetadata:function(e,t){return c(e,o(t),arguments.length<3?void 0:s(arguments[2]))}})},function(e,t,n){var r=n(39),o=n(3),i=r.keys,a=r.key;r.exp({getOwnMetadataKeys:function(e){return i(o(e),arguments.length<2?void 0:a(arguments[1]))}})},function(e,t,n){var r=n(39),o=n(3),i=r.get,a=r.key;r.exp({getOwnMetadata:function(e,t){return i(e,o(t),arguments.length<3?void 0:a(arguments[2]))}})},function(e,t,n){var r=n(39),o=n(3),i=n(25),a=r.has,u=r.key,s=function(e,t,n){var r=a(e,t,n);if(r)return!0;var o=i(t);return null!==o&&s(e,o,n)};r.exp({hasMetadata:function(e,t){return s(e,o(t),arguments.length<3?void 0:u(arguments[2]))}})},function(e,t,n){var r=n(39),o=n(3),i=r.has,a=r.key;r.exp({hasOwnMetadata:function(e,t){return i(e,o(t),arguments.length<3?void 0:a(arguments[2]))}})},function(e,t,n){var r=n(39),o=n(3),i=n(19),a=r.key,u=r.set;r.exp({metadata:function(e,t){return function(n,r){u(e,t,(void 0!==r?o:i)(n),a(r))}}})},function(e,t,n){var r=n(1);r(r.P+r.R,"Set",{toJSON:n(186)("Set")})},function(e,t,n){"use strict";var r=n(1),o=n(132)(!0);r(r.P,"String",{at:function(e){return o(this,e)}})},function(e,t,n){"use strict";var r=n(1),o=n(27),i=n(15),a=n(90),u=n(88),s=RegExp.prototype,c=function(e,t){this._r=e,this._s=t};n(124)(c,"RegExp String",function(){var e=this._r.exec(this._s);return{value:e,done:null===e}}),r(r.P,"String",{matchAll:function(e){if(o(this),!a(e))throw TypeError(e+" is not a regexp!");var t=String(this),n="flags"in s?String(e.flags):u.call(e),r=new RegExp(e.source,~n.indexOf("g")?n:"g"+n);return r.lastIndex=i(e.lastIndex),new c(r,t)}})},function(e,t,n){"use strict";var r=n(1),o=n(202);r(r.P,"String",{padEnd:function(e){return o(this,e,arguments.length>1?arguments[1]:void 0,!1)}})},function(e,t,n){"use strict";var r=n(1),o=n(202);r(r.P,"String",{padStart:function(e){return o(this,e,arguments.length>1?arguments[1]:void 0,!0)}})},function(e,t,n){"use strict";n(64)("trimLeft",function(e){return function(){return e(this,1)}},"trimStart")},function(e,t,n){"use strict";n(64)("trimRight",function(e){return function(){return e(this,2)}},"trimEnd")},function(e,t,n){n(138)("asyncIterator")},function(e,t,n){n(138)("observable")},function(e,t,n){var r=n(1);r(r.S,"System",{global:n(4)})},function(e,t,n){for(var r=n(140),o=n(21),i=n(4),a=n(20),u=n(62),s=n(9),c=s("iterator"),l=s("toStringTag"),f=u.Array,p=["NodeList","DOMTokenList","MediaList","StyleSheetList","CSSRuleList"],d=0;d<5;d++){var h,v=p[d],m=i[v],y=m&&m.prototype;if(y){y[c]||a(y,c,f),y[l]||a(y,l,v),u[v]=f;for(h in r)y[h]||o(y,h,r[h],!0)}}},function(e,t,n){var r=n(1),o=n(136);r(r.G+r.B,{setImmediate:o.set,clearImmediate:o.clear})},function(e,t,n){var r=n(4),o=n(1),i=n(89),a=n(287),u=r.navigator,s=!!u&&/MSIE .\./.test(u.userAgent),c=function(e){return s?function(t,n){return e(i(a,[].slice.call(arguments,2),"function"==typeof t?t:Function(t)),n)}:e};o(o.G+o.B+o.F*s,{setTimeout:c(r.setTimeout),setInterval:c(r.setInterval)})},function(e,t,n){n(410),n(349),n(351),n(350),n(353),n(355),n(360),n(354),n(352),n(362),n(361),n(357),n(358),n(356),n(348),n(359),n(363),n(364),n(316),n(318),n(317),n(366),n(365),n(336),n(346),n(347),n(337),n(338), n(339),n(340),n(341),n(342),n(343),n(344),n(345),n(319),n(320),n(321),n(322),n(323),n(324),n(325),n(326),n(327),n(328),n(329),n(330),n(331),n(332),n(333),n(334),n(335),n(397),n(402),n(409),n(400),n(392),n(393),n(398),n(403),n(405),n(388),n(389),n(390),n(391),n(394),n(395),n(396),n(399),n(401),n(404),n(406),n(407),n(408),n(311),n(313),n(312),n(315),n(314),n(300),n(298),n(304),n(301),n(307),n(309),n(297),n(303),n(294),n(308),n(292),n(306),n(305),n(299),n(302),n(291),n(293),n(296),n(295),n(310),n(140),n(382),n(387),n(205),n(383),n(384),n(385),n(386),n(367),n(204),n(206),n(207),n(422),n(411),n(412),n(417),n(420),n(421),n(415),n(418),n(416),n(419),n(413),n(414),n(368),n(369),n(370),n(371),n(372),n(375),n(373),n(374),n(376),n(377),n(378),n(379),n(381),n(380),n(423),n(449),n(452),n(451),n(453),n(454),n(450),n(455),n(456),n(434),n(437),n(433),n(431),n(432),n(435),n(436),n(426),n(448),n(457),n(425),n(427),n(429),n(428),n(430),n(439),n(440),n(442),n(441),n(444),n(443),n(445),n(446),n(447),n(424),n(438),n(460),n(459),n(458),e.exports=n(37)},function(e,t){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function o(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function i(e){function t(){e.apply(this,arguments)}return t.prototype=Object.create(e.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e,t}Object.defineProperty(t,"__esModule",{value:!0});var a=function(e){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";n(this,t);var o=r(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return Object.defineProperty(o,"message",{configurable:!0,enumerable:!1,value:e,writable:!0}),Object.defineProperty(o,"name",{configurable:!0,enumerable:!1,value:o.constructor.name,writable:!0}),Error.hasOwnProperty("captureStackTrace")?(Error.captureStackTrace(o,o.constructor),r(o)):(Object.defineProperty(o,"stack",{configurable:!0,enumerable:!1,value:new Error(e).stack,writable:!0}),o)}return o(t,e),t}(i(Error));t.default=a,e.exports=t.default},function(e,t){"use strict";function n(e){return e.replace(r,function(e,t){return t.toUpperCase()})}var r=/-(.)/g;e.exports=n},function(e,t,n){"use strict";function r(e){return o(e.replace(i,"ms-"))}var o=n(463),i=/^-ms-/;e.exports=r},function(e,t,n){"use strict";function r(e,t){return!(!e||!t)&&(e===t||!o(e)&&(o(t)?r(e,t.parentNode):"contains"in e?e.contains(t):!!e.compareDocumentPosition&&!!(16&e.compareDocumentPosition(t))))}var o=n(473);e.exports=r},function(e,t,n){"use strict";function r(e){var t=e.length;if(Array.isArray(e)||"object"!=typeof e&&"function"!=typeof e?a(!1):void 0,"number"!=typeof t?a(!1):void 0,0===t||t-1 in e?void 0:a(!1),"function"==typeof e.callee?a(!1):void 0,e.hasOwnProperty)try{return Array.prototype.slice.call(e)}catch(e){}for(var n=Array(t),r=0;r<t;r++)n[r]=e[r];return n}function o(e){return!!e&&("object"==typeof e||"function"==typeof e)&&"length"in e&&!("setInterval"in e)&&"number"!=typeof e.nodeType&&(Array.isArray(e)||"callee"in e||"item"in e)}function i(e){return o(e)?Array.isArray(e)?e.slice():r(e):[e]}var a=n(2);e.exports=i},function(e,t,n){"use strict";function r(e){var t=e.match(l);return t&&t[1].toLowerCase()}function o(e,t){var n=c;c?void 0:s(!1);var o=r(e),i=o&&u(o);if(i){n.innerHTML=i[1]+e+i[2];for(var l=i[0];l--;)n=n.lastChild}else n.innerHTML=e;var f=n.getElementsByTagName("script");f.length&&(t?void 0:s(!1),a(f).forEach(t));for(var p=Array.from(n.childNodes);n.lastChild;)n.removeChild(n.lastChild);return p}var i=n(18),a=n(466),u=n(468),s=n(2),c=i.canUseDOM?document.createElement("div"):null,l=/^\s*<(\w+)/;e.exports=o},function(e,t,n){"use strict";function r(e){return a?void 0:i(!1),p.hasOwnProperty(e)||(e="*"),u.hasOwnProperty(e)||("*"===e?a.innerHTML="<link />":a.innerHTML="<"+e+"></"+e+">",u[e]=!a.firstChild),u[e]?p[e]:null}var o=n(18),i=n(2),a=o.canUseDOM?document.createElement("div"):null,u={},s=[1,'<select multiple="true">',"</select>"],c=[1,"<table>","</table>"],l=[3,"<table><tbody><tr>","</tr></tbody></table>"],f=[1,'<svg xmlns="http://www.w3.org/2000/svg">',"</svg>"],p={"*":[1,"?<div>","</div>"],area:[1,"<map>","</map>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],legend:[1,"<fieldset>","</fieldset>"],param:[1,"<object>","</object>"],tr:[2,"<table><tbody>","</tbody></table>"],optgroup:s,option:s,caption:c,colgroup:c,tbody:c,tfoot:c,thead:c,td:l,th:l},d=["circle","clipPath","defs","ellipse","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","text","tspan"];d.forEach(function(e){p[e]=f,u[e]=!0}),e.exports=r},function(e,t){"use strict";function n(e){return e===window?{x:window.pageXOffset||document.documentElement.scrollLeft,y:window.pageYOffset||document.documentElement.scrollTop}:{x:e.scrollLeft,y:e.scrollTop}}e.exports=n},function(e,t){"use strict";function n(e){return e.replace(r,"-$1").toLowerCase()}var r=/([A-Z])/g;e.exports=n},function(e,t,n){"use strict";function r(e){return o(e).replace(i,"-ms-")}var o=n(470),i=/^ms-/;e.exports=r},function(e,t){"use strict";function n(e){return!(!e||!("function"==typeof Node?e instanceof Node:"object"==typeof e&&"number"==typeof e.nodeType&&"string"==typeof e.nodeName))}e.exports=n},function(e,t,n){"use strict";function r(e){return o(e)&&3==e.nodeType}var o=n(472);e.exports=r},function(e,t){"use strict";function n(e){var t={};return function(n){return t.hasOwnProperty(n)||(t[n]=e.call(this,n)),t[n]}}e.exports=n},function(e,t){e.exports="<h1 id=wizard-form>Wizard Form</h1> <p>One common UI design pattern is to separate a single form out into sepearate pages of inputs, commonly known as a Wizard. There are several ways that this could be accomplished using <code>redux-form</code>, but the simplest and recommended way is to follow these instructions:</p> <ul> <li>Connect each page with <code>reduxForm()</code> to the same form name.</li> <li>Specify the <code>destroyOnUnmount: false</code> flag to preserve form data across form component unmounts.</li> <li>You may specify sync validation for the entire form</li> <li>Use <code>onSubmit</code> to transition forward to the next page; this forces validation to run.</li> </ul> <p>Things that are up to you to implement:</p> <ul> <li>Call <code>props.destroy()</code> manually after a successful submit.</li> </ul> <h2 id=running-this-example-locally>Running this example locally</h2> <p>To run this example locally on your machine clone the <code>redux-form</code> repository, then <code>cd redux-form</code> to change to the repo directory, and run <code>npm install</code>.</p> <p>Then run <code>npm run example:wizard</code> or manually run the following commands:</p> <pre><code>cd ./examples/wizard\nnpm install\nnpm start\n</code></pre>"},function(e,t){function n(e){return!!e&&"object"==typeof e}function r(e,t){var n=null==e?void 0:e[t];return a(n)?n:void 0}function o(e){return i(e)&&p.call(e)==u}function i(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function a(e){return null!=e&&(o(e)?d.test(l.call(e)):n(e)&&s.test(e))}var u="[object Function]",s=/^\[object .+?Constructor\]$/,c=Object.prototype,l=Function.prototype.toString,f=c.hasOwnProperty,p=c.toString,d=RegExp("^"+l.call(f).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");e.exports=r},function(e,t){function n(e){return o(e)&&h.call(e,"callee")&&(!m.call(e,"callee")||v.call(e)==l)}function r(e){return null!=e&&a(e.length)&&!i(e)}function o(e){return s(e)&&r(e)}function i(e){var t=u(e)?v.call(e):"";return t==f||t==p}function a(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=c}function u(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function s(e){return!!e&&"object"==typeof e}var c=9007199254740991,l="[object Arguments]",f="[object Function]",p="[object GeneratorFunction]",d=Object.prototype,h=d.hasOwnProperty,v=d.toString,m=d.propertyIsEnumerable;e.exports=n},function(e,t){function n(e){return!!e&&"object"==typeof e}function r(e,t){var n=null==e?void 0:e[t];return u(n)?n:void 0}function o(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=y}function i(e){return a(e)&&h.call(e)==c}function a(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function u(e){return null!=e&&(i(e)?v.test(p.call(e)):n(e)&&l.test(e))}var s="[object Array]",c="[object Function]",l=/^\[object .+?Constructor\]$/,f=Object.prototype,p=Function.prototype.toString,d=f.hasOwnProperty,h=f.toString,v=RegExp("^"+p.call(d).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),m=r(Array,"isArray"),y=9007199254740991,g=m||function(e){return n(e)&&o(e.length)&&h.call(e)==s};e.exports=g},function(e,t,n){function r(e){return function(t){return null==t?void 0:t[e]}}function o(e){return null!=e&&a(g(e))}function i(e,t){return e="number"==typeof e||d.test(e)?+e:-1,t=null==t?y:t,e>-1&&e%1==0&&e<t}function a(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=y}function u(e){for(var t=c(e),n=t.length,r=n&&e.length,o=!!r&&a(r)&&(p(e)||f(e)),u=-1,s=[];++u<n;){var l=t[u];(o&&i(l,r)||v.call(e,l))&&s.push(l)}return s}function s(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function c(e){if(null==e)return[];s(e)||(e=Object(e));var t=e.length;t=t&&a(t)&&(p(e)||f(e))&&t||0;for(var n=e.constructor,r=-1,o="function"==typeof n&&n.prototype===e,u=Array(t),c=t>0;++r<t;)u[r]=r+"";for(var l in e)c&&i(l,t)||"constructor"==l&&(o||!v.call(e,l))||u.push(l);return u}var l=n(476),f=n(477),p=n(478),d=/^\d+$/,h=Object.prototype,v=h.hasOwnProperty,m=l(Object,"keys"),y=9007199254740991,g=r("length"),b=m?function(e){var t=null==e?void 0:e.constructor;return"function"==typeof t&&t.prototype===e||"function"!=typeof e&&o(e)?u(e):s(e)?m(e):[]}:u;e.exports=b},function(e,t,n){var r=n(57),o=n(35),i=r(o,"DataView");e.exports=i},function(e,t,n){function r(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}var o=n(531),i=n(532),a=n(533),u=n(534),s=n(535);r.prototype.clear=o,r.prototype.delete=i,r.prototype.get=a,r.prototype.has=u,r.prototype.set=s,e.exports=r},function(e,t,n){var r=n(57),o=n(35),i=r(o,"Promise");e.exports=i},function(e,t,n){var r=n(57),o=n(35),i=r(o,"Set");e.exports=i},function(e,t,n){function r(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new o;++t<n;)this.add(e[t])}var o=n(144),i=n(556),a=n(557);r.prototype.add=r.prototype.push=i,r.prototype.has=a,e.exports=r},function(e,t,n){var r=n(57),o=n(35),i=r(o,"WeakMap");e.exports=i},function(e,t){function n(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}e.exports=n},function(e,t){function n(e,t){for(var n=-1,r=null==e?0:e.length,o=0,i=[];++n<r;){var a=e[n];t(a,n,e)&&(i[o++]=a)}return i}e.exports=n},function(e,t){function n(e,t){for(var n=-1,r=t.length,o=e.length;++n<r;)e[o+n]=t[n];return e}e.exports=n},function(e,t,n){function r(e,t,n){var r=e[t];u.call(e,t)&&i(r,n)&&(void 0!==n||t in e)||o(e,t,n)}var o=n(99),i=n(79),a=Object.prototype,u=a.hasOwnProperty;e.exports=r},function(e,t,n){var r=n(46),o=Object.create,i=function(){function e(){}return function(t){if(!r(t))return{};if(o)return o(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();e.exports=i},function(e,t,n){var r=n(218),o=n(520),i=o(r);e.exports=i},function(e,t,n){function r(e,t,n){var r=t(e);return i(e)?r:o(r,n(e))}var o=n(488),i=n(30);e.exports=r},function(e,t){function n(e,t){return null!=e&&t in Object(e)}e.exports=n},function(e,t,n){function r(e){return i(e)&&o(e)==a}var o=n(65),i=n(58),a="[object Arguments]";e.exports=r},function(e,t,n){function r(e,t,n,r,m,g){var b=c(e),_=c(t),x=b?h:s(e),E=_?h:s(t);x=x==d?v:x,E=E==d?v:E;var w=x==v,S=E==v,C=x==E;if(C&&l(e)){if(!l(t))return!1;b=!0,w=!1}if(C&&!w)return g||(g=new o),b||f(e)?i(e,t,n,r,m,g):a(e,t,x,n,r,m,g);if(!(n&p)){var P=w&&y.call(e,"__wrapped__"),O=S&&y.call(t,"__wrapped__");if(P||O){var T=P?e.value():e,k=O?t.value():t;return g||(g=new o),m(T,k,n,r,g)}}return!!C&&(g||(g=new o),u(e,t,n,r,m,g))}var o=n(145),i=n(224),a=n(522),u=n(523),s=n(528),c=n(30),l=n(152),f=n(155),p=1,d="[object Arguments]",h="[object Array]",v="[object Object]",m=Object.prototype,y=m.hasOwnProperty;e.exports=r},function(e,t,n){function r(e,t,n,r){var s=n.length,c=s,l=!r;if(null==e)return!c;for(e=Object(e);s--;){var f=n[s];if(l&&f[2]?f[1]!==e[f[0]]:!(f[0]in e))return!1}for(;++s<c;){f=n[s];var p=f[0],d=e[p],h=f[1];if(l&&f[2]){if(void 0===d&&!(p in e))return!1}else{var v=new o;if(r)var m=r(d,h,p,e,t,v);if(!(void 0===m?i(h,d,a|u,r,v):m))return!1}}return!0}var o=n(145),i=n(146),a=1,u=2;e.exports=r},function(e,t,n){function r(e){if(!a(e)||i(e))return!1;var t=o(e)?h:c;return t.test(u(e))}var o=n(153),i=n(538),a=n(46),u=n(232),s=/[\\^$.*+?()[\]{}|]/g,c=/^\[object .+?Constructor\]$/,l=Function.prototype,f=Object.prototype,p=l.toString,d=f.hasOwnProperty,h=RegExp("^"+p.call(d).replace(s,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");e.exports=r},function(e,t,n){function r(e){return a(e)&&i(e.length)&&!!R[o(e)]}var o=n(65),i=n(154),a=n(58),u="[object Arguments]",s="[object Array]",c="[object Boolean]",l="[object Date]",f="[object Error]",p="[object Function]",d="[object Map]",h="[object Number]",v="[object Object]",m="[object RegExp]",y="[object Set]",g="[object String]",b="[object WeakMap]",_="[object ArrayBuffer]",x="[object DataView]",E="[object Float32Array]",w="[object Float64Array]",S="[object Int8Array]",C="[object Int16Array]",P="[object Int32Array]",O="[object Uint8Array]",T="[object Uint8ClampedArray]",k="[object Uint16Array]",A="[object Uint32Array]",R={};R[E]=R[w]=R[S]=R[C]=R[P]=R[O]=R[T]=R[k]=R[A]=!0,R[u]=R[s]=R[_]=R[c]=R[x]=R[l]=R[f]=R[p]=R[d]=R[h]=R[v]=R[m]=R[y]=R[g]=R[b]=!1,e.exports=r},function(e,t,n){function r(e){if(!o(e))return i(e);var t=[];for(var n in Object(e))u.call(e,n)&&"constructor"!=n&&t.push(n);return t}var o=n(149),i=n(551),a=Object.prototype,u=a.hasOwnProperty;e.exports=r},function(e,t,n){function r(e){if(!o(e))return a(e);var t=i(e),n=[];for(var r in e)("constructor"!=r||!t&&s.call(e,r))&&n.push(r);return n}var o=n(46),i=n(149),a=n(552),u=Object.prototype,s=u.hasOwnProperty;e.exports=r},function(e,t,n){function r(e){var t=i(e);return 1==t.length&&t[0][2]?a(t[0][0],t[0][1]):function(n){return n===e||o(n,e,t)}}var o=n(496),i=n(525),a=n(229);e.exports=r},function(e,t,n){function r(e,t){return u(e)&&s(t)?c(l(e),t):function(n){var r=i(n,e);return void 0===r&&r===t?a(n,e):o(t,r,f|p)}}var o=n(146),i=n(567),a=n(568),u=n(148),s=n(228),c=n(229),l=n(78),f=1,p=2;e.exports=r},function(e,t,n){function r(e,t,n,l,f){e!==t&&a(t,function(a,c){if(s(a))f||(f=new o),u(e,t,c,n,r,l,f);else{var p=l?l(e[c],a,c+"",e,t,f):void 0;void 0===p&&(p=a),i(e,c,p)}},c)}var o=n(145),i=n(216),a=n(217),u=n(504),s=n(46),c=n(233);e.exports=r},function(e,t,n){function r(e,t,n,r,g,b,_){var x=e[n],E=t[n],w=_.get(E);if(w)return void o(e,n,w);var S=b?b(x,E,n+"",e,t,_):void 0,C=void 0===S;if(C){var P=l(E),O=!P&&p(E),T=!P&&!O&&m(E);S=E,P||O||T?l(x)?S=x:f(x)?S=u(x):O?(C=!1,S=i(E,!0)):T?(C=!1,S=a(E,!0)):S=[]:v(E)||c(E)?(S=x,c(x)?S=y(x):(!h(x)||r&&d(x))&&(S=s(E))):C=!1}C&&(_.set(E,S),g(S,E,r,b,_),_.delete(E)),o(e,n,S)}var o=n(216),i=n(515),a=n(516),u=n(222),s=n(536),c=n(151),l=n(30),f=n(569),p=n(152),d=n(153),h=n(46),v=n(102),m=n(155),y=n(577);e.exports=r},function(e,t){function n(e){return function(t){return null==t?void 0:t[e]}}e.exports=n},function(e,t,n){function r(e){return function(t){return o(t,e)}}var o=n(219);e.exports=r},function(e,t,n){function r(e,t){return a(i(e,t,o),e+"")}var o=n(150),i=n(555),a=n(559);e.exports=r},function(e,t,n){var r=n(566),o=n(223),i=n(150),a=o?function(e,t){return o(e,"toString",{configurable:!0,enumerable:!1,value:r(t),writable:!0})}:i;e.exports=a},function(e,t,n){function r(e,t){var n;return o(e,function(e,r,o){return n=t(e,r,o),!n}),!!n}var o=n(491);e.exports=r},function(e,t){function n(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}e.exports=n},function(e,t,n){function r(e){if("string"==typeof e)return e;if(a(e))return i(e,r)+"";if(u(e))return l?l.call(e):"";var t=e+"";return"0"==t&&1/e==-s?"-0":t}var o=n(97),i=n(214),a=n(30),u=n(103),s=1/0,c=o?o.prototype:void 0,l=c?c.toString:void 0;e.exports=r},function(e,t){function n(e){return function(t){return e(t)}}e.exports=n},function(e,t){function n(e,t){return e.has(t)}e.exports=n},function(e,t,n){function r(e){var t=new e.constructor(e.byteLength);return new o(t).set(new o(e)),t}var o=n(212);e.exports=r},function(e,t,n){(function(e){function r(e,t){if(t)return e.slice();var n=e.length,r=c?c(n):new e.constructor(n);return e.copy(r),r}var o=n(35),i="object"==typeof t&&t&&!t.nodeType&&t,a=i&&"object"==typeof e&&e&&!e.nodeType&&e,u=a&&a.exports===i,s=u?o.Buffer:void 0,c=s?s.allocUnsafe:void 0;e.exports=r}).call(t,n(113)(e))},function(e,t,n){function r(e,t){var n=t?o(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}var o=n(514);e.exports=r},function(e,t,n){function r(e,t,n,r){var a=!n;n||(n={});for(var u=-1,s=t.length;++u<s;){var c=t[u],l=r?r(n[c],e[c],c,n,e):void 0;void 0===l&&(l=e[c]),a?i(n,c,l):o(n,c,l)}return n}var o=n(489),i=n(99);e.exports=r},function(e,t,n){var r=n(35),o=r["__core-js_shared__"];e.exports=o},function(e,t,n){function r(e){return o(function(t,n){var r=-1,o=n.length,a=o>1?n[o-1]:void 0,u=o>2?n[2]:void 0;for(a=e.length>3&&"function"==typeof a?(o--,a):void 0,u&&i(n[0],n[1],u)&&(a=o<3?void 0:a,o=1),t=Object(t);++r<o;){var s=n[r];s&&e(t,s,r,a)}return t})}var o=n(507),i=n(227);e.exports=r},function(e,t,n){function r(e,t){return function(n,r){if(null==n)return n;if(!o(n))return e(n,r);for(var i=n.length,a=t?i:-1,u=Object(n);(t?a--:++a<i)&&r(u[a],a,u)!==!1;);return n}}var o=n(80);e.exports=r},function(e,t){function n(e){return function(t,n,r){for(var o=-1,i=Object(t),a=r(t),u=a.length;u--;){var s=a[e?u:++o];if(n(i[s],s,i)===!1)break}return t}}e.exports=n},function(e,t,n){function r(e,t,n,r,o,w,C){switch(n){case E:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case x:return!(e.byteLength!=t.byteLength||!w(new i(e),new i(t)));case p:case d:case m:return a(+e,+t);case h:return e.name==t.name&&e.message==t.message;case y:case b:return e==t+"";case v:var P=s;case g:var O=r&l;if(P||(P=c),e.size!=t.size&&!O)return!1;var T=C.get(e);if(T)return T==t;r|=f,C.set(e,t);var k=u(P(e),P(t),r,o,w,C);return C.delete(e),k;case _:if(S)return S.call(e)==S.call(t)}return!1}var o=n(97),i=n(212),a=n(79),u=n(224),s=n(549),c=n(558),l=1,f=2,p="[object Boolean]",d="[object Date]",h="[object Error]",v="[object Map]",m="[object Number]",y="[object RegExp]",g="[object Set]",b="[object String]",_="[object Symbol]",x="[object ArrayBuffer]",E="[object DataView]",w=o?o.prototype:void 0,S=w?w.valueOf:void 0;e.exports=r},function(e,t,n){function r(e,t,n,r,a,s){var c=n&i,l=o(e),f=l.length,p=o(t),d=p.length;if(f!=d&&!c)return!1;for(var h=f;h--;){var v=l[h];if(!(c?v in t:u.call(t,v)))return!1}var m=s.get(e);if(m&&s.get(t))return m==t;var y=!0;s.set(e,t),s.set(t,e);for(var g=c;++h<f;){v=l[h];var b=e[v],_=t[v];if(r)var x=c?r(_,b,v,t,e,s):r(b,_,v,e,t,s);if(!(void 0===x?b===_||a(b,_,n,r,s):x)){y=!1;break}g||(g="constructor"==v)}if(y&&!g){var E=e.constructor,w=t.constructor;E!=w&&"constructor"in e&&"constructor"in t&&!("function"==typeof E&&E instanceof E&&"function"==typeof w&&w instanceof w)&&(y=!1)}return s.delete(e),s.delete(t),y}var o=n(524),i=1,a=Object.prototype,u=a.hasOwnProperty;e.exports=r},function(e,t,n){function r(e){return o(e,a,i)}var o=n(492),i=n(527),a=n(156);e.exports=r},function(e,t,n){function r(e){for(var t=i(e),n=t.length;n--;){var r=t[n],a=e[r];t[n]=[r,a,o(a)]}return t}var o=n(228),i=n(156);e.exports=r},function(e,t,n){function r(e){var t=a.call(e,s),n=e[s];try{e[s]=void 0;var r=!0}catch(e){}var o=u.call(e);return r&&(t?e[s]=n:delete e[s]),o}var o=n(97),i=Object.prototype,a=i.hasOwnProperty,u=i.toString,s=o?o.toStringTag:void 0;e.exports=r},function(e,t,n){var r=n(487),o=n(575),i=Object.prototype,a=i.propertyIsEnumerable,u=Object.getOwnPropertySymbols,s=u?function(e){return null==e?[]:(e=Object(e),r(u(e),function(t){return a.call(e,t)}))}:o;e.exports=s},function(e,t,n){var r=n(480),o=n(143),i=n(482),a=n(483),u=n(485),s=n(65),c=n(232),l="[object Map]",f="[object Object]",p="[object Promise]",d="[object Set]",h="[object WeakMap]",v="[object DataView]",m=c(r),y=c(o),g=c(i),b=c(a),_=c(u),x=s;(r&&x(new r(new ArrayBuffer(1)))!=v||o&&x(new o)!=l||i&&x(i.resolve())!=p||a&&x(new a)!=d||u&&x(new u)!=h)&&(x=function(e){var t=s(e),n=t==f?e.constructor:void 0,r=n?c(n):"";if(r)switch(r){case m:return v;case y:return l;case g:return p;case b:return d;case _:return h}return t}),e.exports=x},function(e,t){function n(e,t){return null==e?void 0:e[t]}e.exports=n},function(e,t,n){function r(e,t,n){t=o(t,e);for(var r=-1,l=t.length,f=!1;++r<l;){var p=c(t[r]);if(!(f=null!=e&&n(e,p)))break;e=e[p]}return f||++r!=l?f:(l=null==e?0:e.length,!!l&&s(l)&&u(p,l)&&(a(e)||i(e)))}var o=n(221),i=n(151),a=n(30),u=n(147),s=n(154),c=n(78);e.exports=r},function(e,t,n){function r(){this.__data__=o?o(null):{},this.size=0}var o=n(101);e.exports=r},function(e,t){function n(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}e.exports=n},function(e,t,n){function r(e){var t=this.__data__;if(o){var n=t[e];return n===i?void 0:n}return u.call(t,e)?t[e]:void 0}var o=n(101),i="__lodash_hash_undefined__",a=Object.prototype,u=a.hasOwnProperty;e.exports=r},function(e,t,n){function r(e){var t=this.__data__;return o?void 0!==t[e]:a.call(t,e)}var o=n(101),i=Object.prototype,a=i.hasOwnProperty;e.exports=r},function(e,t,n){function r(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=o&&void 0===t?i:t,this}var o=n(101),i="__lodash_hash_undefined__";e.exports=r},function(e,t,n){function r(e){return"function"!=typeof e.constructor||a(e)?{}:o(i(e))}var o=n(490),i=n(226),a=n(149);e.exports=r},function(e,t){function n(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}e.exports=n},function(e,t,n){function r(e){return!!i&&i in e}var o=n(518),i=function(){var e=/[^.]+$/.exec(o&&o.keys&&o.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();e.exports=r},function(e,t){function n(){this.__data__=[],this.size=0}e.exports=n},function(e,t,n){function r(e){var t=this.__data__,n=o(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():a.call(t,n,1),--this.size,!0}var o=n(98),i=Array.prototype,a=i.splice;e.exports=r},function(e,t,n){function r(e){var t=this.__data__,n=o(t,e);return n<0?void 0:t[n][1]}var o=n(98);e.exports=r},function(e,t,n){function r(e){return o(this.__data__,e)>-1}var o=n(98);e.exports=r},function(e,t,n){function r(e,t){var n=this.__data__,r=o(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}var o=n(98);e.exports=r},function(e,t,n){function r(){this.size=0,this.__data__={hash:new o,map:new(a||i),string:new o}}var o=n(481),i=n(96),a=n(143);e.exports=r},function(e,t,n){function r(e){var t=o(this,e).delete(e);return this.size-=t?1:0,t}var o=n(100);e.exports=r},function(e,t,n){function r(e){return o(this,e).get(e)}var o=n(100);e.exports=r},function(e,t,n){function r(e){return o(this,e).has(e)}var o=n(100);e.exports=r},function(e,t,n){function r(e,t){var n=o(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}var o=n(100);e.exports=r},function(e,t){function n(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}e.exports=n},function(e,t,n){function r(e){var t=o(e,function(e){return n.size===i&&n.clear(),e}),n=t.cache;return t}var o=n(571),i=500;e.exports=r},function(e,t,n){var r=n(230),o=r(Object.keys,Object);e.exports=o},function(e,t){function n(e){var t=[];if(null!=e)for(var n in Object(e))t.push(n);return t}e.exports=n},function(e,t,n){(function(e){var r=n(225),o="object"==typeof t&&t&&!t.nodeType&&t,i=o&&"object"==typeof e&&e&&!e.nodeType&&e,a=i&&i.exports===o,u=a&&r.process,s=function(){try{return u&&u.binding&&u.binding("util")}catch(e){}}();e.exports=s}).call(t,n(113)(e))},function(e,t){function n(e){return o.call(e)}var r=Object.prototype,o=r.toString;e.exports=n},function(e,t,n){function r(e,t,n){return t=i(void 0===t?e.length-1:t,0),function(){for(var r=arguments,a=-1,u=i(r.length-t,0),s=Array(u);++a<u;)s[a]=r[t+a];a=-1;for(var c=Array(t+1);++a<t;)c[a]=r[a];return c[t]=n(s),o(e,this,c)}}var o=n(486),i=Math.max;e.exports=r},function(e,t){function n(e){return this.__data__.set(e,r),this}var r="__lodash_hash_undefined__";e.exports=n},function(e,t){function n(e){return this.__data__.has(e)}e.exports=n},function(e,t){function n(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}e.exports=n},function(e,t,n){var r=n(508),o=n(560),i=o(r);e.exports=i},function(e,t){function n(e){var t=0,n=0;return function(){var a=i(),u=o-(a-n);if(n=a,u>0){if(++t>=r)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var r=800,o=16,i=Date.now;e.exports=n},function(e,t,n){function r(){this.__data__=new o,this.size=0}var o=n(96);e.exports=r},function(e,t){function n(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}e.exports=n},function(e,t){function n(e){return this.__data__.get(e)}e.exports=n},function(e,t){function n(e){return this.__data__.has(e)}e.exports=n},function(e,t,n){function r(e,t){var n=this.__data__;if(n instanceof o){var r=n.__data__;if(!i||r.length<u-1)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new a(r)}return n.set(e,t),this.size=n.size,this}var o=n(96),i=n(143),a=n(144),u=200;e.exports=r},function(e,t){function n(e){return function(){return e}}e.exports=n},function(e,t,n){function r(e,t,n){var r=null==e?void 0:o(e,t);return void 0===r?n:r}var o=n(219);e.exports=r},function(e,t,n){function r(e,t){return null!=e&&i(e,t,o)}var o=n(493),i=n(530);e.exports=r},function(e,t,n){function r(e){return i(e)&&o(e)}var o=n(80),i=n(58);e.exports=r},function(e,t,n){function r(e,t,n){n="function"==typeof n?n:void 0;var r=n?n(e,t):void 0;return void 0===r?o(e,t,void 0,n):!!r}var o=n(146);e.exports=r},function(e,t,n){function r(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new TypeError(i);var n=function(){var r=arguments,o=t?t.apply(this,r):r[0],i=n.cache;if(i.has(o))return i.get(o);var a=e.apply(this,r);return n.cache=i.set(o,a)||i,a};return n.cache=new(r.Cache||o),n}var o=n(144),i="Expected a function";r.Cache=o,e.exports=r},function(e,t,n){var r=n(503),o=n(519),i=o(function(e,t,n){r(e,t,n)});e.exports=i},function(e,t,n){function r(e){return a(e)?o(u(e)):i(e)}var o=n(505),i=n(506),a=n(148),u=n(78);e.exports=r},function(e,t,n){function r(e,t,n){var r=u(e)?o:a;return n&&s(e,t,n)&&(t=void 0),r(e,i(t,3))}var o=n(215),i=n(220),a=n(509),u=n(30),s=n(227);e.exports=r},function(e,t){function n(){return[]}e.exports=n},function(e,t){function n(){return!1}e.exports=n},function(e,t,n){function r(e){return o(e,i(e))}var o=n(517),i=n(233);e.exports=r},function(e,t){e.exports="import React, { Component, PropTypes } from 'react'\nimport WizardFormFirstPage from './WizardFormFirstPage'\nimport WizardFormSecondPage from './WizardFormSecondPage'\nimport WizardFormThirdPage from './WizardFormThirdPage'\n\nclass WizardForm extends Component {\n constructor(props) {\n super(props)\n this.nextPage = this.nextPage.bind(this)\n this.previousPage = this.previousPage.bind(this)\n this.state = {\n page: 1\n }\n }\n nextPage() {\n this.setState({ page: this.state.page + 1 })\n }\n\n previousPage() {\n this.setState({ page: this.state.page - 1 })\n }\n\n render() {\n const { onSubmit } = this.props\n const { page } = this.state\n return (<div>\n {page === 1 && <WizardFormFirstPage onSubmit={this.nextPage}/>}\n {page === 2 && <WizardFormSecondPage previousPage={this.previousPage} onSubmit={this.nextPage}/>}\n {page === 3 && <WizardFormThirdPage previousPage={this.previousPage} onSubmit={onSubmit}/>}\n </div>\n )\n }\n}\n\nWizardForm.propTypes = {\n onSubmit: PropTypes.func.isRequired\n}\n\nexport default WizardForm\n"},function(e,t){e.exports='import React from \'react\'\nimport { Field, reduxForm } from \'redux-form\'\nimport validate from \'./validate\'\nimport renderField from \'./renderField\'\n\nconst WizardFormFirstPage = (props) => {\n const { handleSubmit } = props\n return (\n <form onSubmit={handleSubmit}>\n <Field name="firstName" type="text" component={renderField} label="First Name"/>\n <Field name="lastName" type="text" component={renderField} label="Last Name"/>\n <div>\n <button type="submit" className="next">Next</button>\n </div>\n </form>\n ) \n}\n\nexport default reduxForm({\n form: \'wizard\', // <------ same form name\n destroyOnUnmount: false, // <------ preserve form data\n forceUnregisterOnUnmount: true, // <------ unregister fields on unmount\n validate\n})(WizardFormFirstPage)\n'},function(e,t){e.exports='import React from \'react\'\nimport { Field, reduxForm } from \'redux-form\'\nimport validate from \'./validate\'\nimport renderField from \'./renderField\'\n\nconst renderError = ({ meta: { touched, error } }) => touched && error ?\n <span>{error}</span> : false\n\nconst WizardFormSecondPage = (props) => {\n const { handleSubmit, previousPage } = props\n return (\n <form onSubmit={handleSubmit}>\n <Field name="email" type="email" component={renderField} label="Email"/>\n <div>\n <label>Sex</label>\n <div>\n <label><Field name="sex" component="input" type="radio" value="male"/> Male</label>\n <label><Field name="sex" component="input" type="radio" value="female"/> Female</label>\n <Field name="sex" component={renderError}/>\n </div>\n </div>\n <div>\n <button type="button" className="previous" onClick={previousPage}>Previous</button>\n <button type="submit" className="next">Next</button>\n </div>\n </form>\n )\n}\n\nexport default reduxForm({\n form: \'wizard\', //Form name is same\n destroyOnUnmount: false,\n forceUnregisterOnUnmount: true, // <------ unregister fields on unmount\n validate\n})(WizardFormSecondPage)\n'},function(e,t){e.exports='import React from \'react\'\nimport { Field, reduxForm } from \'redux-form\'\nimport validate from \'./validate\'\nconst colors = [ \'Red\', \'Orange\', \'Yellow\', \'Green\', \'Blue\', \'Indigo\', \'Violet\' ]\n\nconst renderColorSelector = ({ input, meta: { touched, error } }) => (\n <div>\n <select {...input}>\n <option value="">Select a color...</option>\n {colors.map(val => <option value={val} key={val}>{val}</option>)}\n </select>\n {touched && error && <span>{error}</span>}\n </div>\n)\n\nconst WizardFormThirdPage = (props) => {\n const { handleSubmit, pristine, previousPage, submitting } = props\n return (\n <form onSubmit={handleSubmit}>\n <div>\n <label>Favorite Color</label>\n <Field name="favoriteColor" component={renderColorSelector}/>\n </div>\n <div>\n <label htmlFor="employed">Employed</label>\n <div>\n <Field name="employed" id="employed" component="input" type="checkbox"/>\n </div>\n </div>\n <div>\n <label>Notes</label>\n <div>\n <Field name="notes" component="textarea" placeholder="Notes"/>\n </div>\n </div>\n <div>\n <button type="button" className="previous" onClick={previousPage}>Previous</button>\n <button type="submit" disabled={pristine || submitting}>Submit</button>\n </div>\n </form>\n )\n}\nexport default reduxForm({\n form: \'wizard\', //Form name is same\n destroyOnUnmount: false,\n forceUnregisterOnUnmount: true, // <------ unregister fields on unmount\n validate\n})(WizardFormThirdPage)\n'; },function(e,t){e.exports="import React from 'react'\n\nconst renderField = ({ input, label, type, meta: { touched, error } }) => (\n <div>\n <label>{label}</label>\n <div>\n <input {...input} placeholder={label} type={type}/>\n {touched && error && <span>{error}</span>}\n </div>\n </div>\n)\n\nexport default renderField\n"},function(e,t){e.exports="const validate = values => {\n const errors = {}\n if (!values.firstName) {\n errors.firstName = 'Required'\n }\n if (!values.lastName) {\n errors.lastName = 'Required'\n }\n if (!values.email) {\n errors.email = 'Required'\n } else if (!/^[A-Z0-9._%+-]+@[A-Z0-9.-]+\\.[A-Z]{2,4}$/i.test(values.email)) {\n errors.email = 'Invalid email address'\n }\n if (!values.sex) {\n errors.sex = 'Required'\n }\n if (!values.favoriteColor) {\n errors.favoriteColor = 'Required'\n }\n return errors\n}\n\nexport default validate\n"},function(e,t,n){"use strict";e.exports=n(598)},function(e,t){"use strict";var n={Properties:{"aria-current":0,"aria-details":0,"aria-disabled":0,"aria-hidden":0,"aria-invalid":0,"aria-keyshortcuts":0,"aria-label":0,"aria-roledescription":0,"aria-autocomplete":0,"aria-checked":0,"aria-expanded":0,"aria-haspopup":0,"aria-level":0,"aria-modal":0,"aria-multiline":0,"aria-multiselectable":0,"aria-orientation":0,"aria-placeholder":0,"aria-pressed":0,"aria-readonly":0,"aria-required":0,"aria-selected":0,"aria-sort":0,"aria-valuemax":0,"aria-valuemin":0,"aria-valuenow":0,"aria-valuetext":0,"aria-atomic":0,"aria-busy":0,"aria-live":0,"aria-relevant":0,"aria-dropeffect":0,"aria-grabbed":0,"aria-activedescendant":0,"aria-colcount":0,"aria-colindex":0,"aria-colspan":0,"aria-controls":0,"aria-describedby":0,"aria-errormessage":0,"aria-flowto":0,"aria-labelledby":0,"aria-owns":0,"aria-posinset":0,"aria-rowcount":0,"aria-rowindex":0,"aria-rowspan":0,"aria-setsize":0},DOMAttributeNames:{},DOMPropertyNames:{}};e.exports=n},function(e,t,n){"use strict";var r=n(13),o=n(209),i={focusDOMComponent:function(){o(r.getNodeFromInstance(this))}};e.exports=i},function(e,t,n){"use strict";function r(){var e=window.opera;return"object"==typeof e&&"function"==typeof e.version&&parseInt(e.version(),10)<=12}function o(e){return(e.ctrlKey||e.altKey||e.metaKey)&&!(e.ctrlKey&&e.altKey)}function i(e){switch(e){case"topCompositionStart":return P.compositionStart;case"topCompositionEnd":return P.compositionEnd;case"topCompositionUpdate":return P.compositionUpdate}}function a(e,t){return"topKeyDown"===e&&t.keyCode===b}function u(e,t){switch(e){case"topKeyUp":return g.indexOf(t.keyCode)!==-1;case"topKeyDown":return t.keyCode!==b;case"topKeyPress":case"topMouseDown":case"topBlur":return!0;default:return!1}}function s(e){var t=e.detail;return"object"==typeof t&&"data"in t?t.data:null}function c(e,t,n,r){var o,c;if(_?o=i(e):T?u(e,n)&&(o=P.compositionEnd):a(e,n)&&(o=P.compositionStart),!o)return null;w&&(T||o!==P.compositionStart?o===P.compositionEnd&&T&&(c=T.getData()):T=v.getPooled(r));var l=m.getPooled(o,t,n,r);if(c)l.data=c;else{var f=s(n);null!==f&&(l.data=f)}return d.accumulateTwoPhaseDispatches(l),l}function l(e,t){switch(e){case"topCompositionEnd":return s(t);case"topKeyPress":var n=t.which;return n!==S?null:(O=!0,C);case"topTextInput":var r=t.data;return r===C&&O?null:r;default:return null}}function f(e,t){if(T){if("topCompositionEnd"===e||!_&&u(e,t)){var n=T.getData();return v.release(T),T=null,n}return null}switch(e){case"topPaste":return null;case"topKeyPress":return t.which&&!o(t)?String.fromCharCode(t.which):null;case"topCompositionEnd":return w?null:t.data;default:return null}}function p(e,t,n,r){var o;if(o=E?l(e,n):f(e,n),!o)return null;var i=y.getPooled(P.beforeInput,t,n,r);return i.data=o,d.accumulateTwoPhaseDispatches(i),i}var d=n(82),h=n(18),v=n(593),m=n(630),y=n(633),g=[9,13,27,32],b=229,_=h.canUseDOM&&"CompositionEvent"in window,x=null;h.canUseDOM&&"documentMode"in document&&(x=document.documentMode);var E=h.canUseDOM&&"TextEvent"in window&&!x&&!r(),w=h.canUseDOM&&(!_||x&&x>8&&x<=11),S=32,C=String.fromCharCode(S),P={beforeInput:{phasedRegistrationNames:{bubbled:"onBeforeInput",captured:"onBeforeInputCapture"},dependencies:["topCompositionEnd","topKeyPress","topTextInput","topPaste"]},compositionEnd:{phasedRegistrationNames:{bubbled:"onCompositionEnd",captured:"onCompositionEndCapture"},dependencies:["topBlur","topCompositionEnd","topKeyDown","topKeyPress","topKeyUp","topMouseDown"]},compositionStart:{phasedRegistrationNames:{bubbled:"onCompositionStart",captured:"onCompositionStartCapture"},dependencies:["topBlur","topCompositionStart","topKeyDown","topKeyPress","topKeyUp","topMouseDown"]},compositionUpdate:{phasedRegistrationNames:{bubbled:"onCompositionUpdate",captured:"onCompositionUpdateCapture"},dependencies:["topBlur","topCompositionUpdate","topKeyDown","topKeyPress","topKeyUp","topMouseDown"]}},O=!1,T=null,k={eventTypes:P,extractEvents:function(e,t,n,r){return[c(e,t,n,r),p(e,t,n,r)]}};e.exports=k},function(e,t,n){"use strict";var r=n(236),o=n(18),i=(n(31),n(464),n(639)),a=n(471),u=n(474),s=(n(5),u(function(e){return a(e)})),c=!1,l="cssFloat";if(o.canUseDOM){var f=document.createElement("div").style;try{f.font=""}catch(e){c=!0}void 0===document.documentElement.style.cssFloat&&(l="styleFloat")}var p={createMarkupForStyles:function(e,t){var n="";for(var r in e)if(e.hasOwnProperty(r)){var o=e[r];null!=o&&(n+=s(r)+":",n+=i(r,o,t)+";")}return n||null},setValueForStyles:function(e,t,n){var o=e.style;for(var a in t)if(t.hasOwnProperty(a)){var u=i(a,t[a],n);if("float"!==a&&"cssFloat"!==a||(a=l),u)o[a]=u;else{var s=c&&r.shorthandPropertyExpansions[a];if(s)for(var f in s)o[f]="";else o[a]=""}}}};e.exports=p},function(e,t,n){"use strict";function r(e){var t=e.nodeName&&e.nodeName.toLowerCase();return"select"===t||"input"===t&&"file"===e.type}function o(e){var t=w.getPooled(O.change,k,e,S(e));b.accumulateTwoPhaseDispatches(t),E.batchedUpdates(i,t)}function i(e){g.enqueueEvents(e),g.processEventQueue(!1)}function a(e,t){T=e,k=t,T.attachEvent("onchange",o)}function u(){T&&(T.detachEvent("onchange",o),T=null,k=null)}function s(e,t){if("topChange"===e)return t}function c(e,t,n){"topFocus"===e?(u(),a(t,n)):"topBlur"===e&&u()}function l(e,t){T=e,k=t,A=e.value,R=Object.getOwnPropertyDescriptor(e.constructor.prototype,"value"),Object.defineProperty(T,"value",N),T.attachEvent?T.attachEvent("onpropertychange",p):T.addEventListener("propertychange",p,!1)}function f(){T&&(delete T.value,T.detachEvent?T.detachEvent("onpropertychange",p):T.removeEventListener("propertychange",p,!1),T=null,k=null,A=null,R=null)}function p(e){if("value"===e.propertyName){var t=e.srcElement.value;t!==A&&(A=t,o(e))}}function d(e,t){if("topInput"===e)return t}function h(e,t,n){"topFocus"===e?(f(),l(t,n)):"topBlur"===e&&f()}function v(e,t){if(("topSelectionChange"===e||"topKeyUp"===e||"topKeyDown"===e)&&T&&T.value!==A)return A=T.value,k}function m(e){return e.nodeName&&"input"===e.nodeName.toLowerCase()&&("checkbox"===e.type||"radio"===e.type)}function y(e,t){if("topClick"===e)return t}var g=n(81),b=n(82),_=n(18),x=n(13),E=n(36),w=n(41),S=n(170),C=n(171),P=n(253),O={change:{phasedRegistrationNames:{bubbled:"onChange",captured:"onChangeCapture"},dependencies:["topBlur","topChange","topClick","topFocus","topInput","topKeyDown","topKeyUp","topSelectionChange"]}},T=null,k=null,A=null,R=null,M=!1;_.canUseDOM&&(M=C("change")&&(!document.documentMode||document.documentMode>8));var I=!1;_.canUseDOM&&(I=C("input")&&(!document.documentMode||document.documentMode>11));var N={get:function(){return R.get.call(this)},set:function(e){A=""+e,R.set.call(this,e)}},j={eventTypes:O,extractEvents:function(e,t,n,o){var i,a,u=t?x.getNodeFromInstance(t):window;if(r(u)?M?i=s:a=c:P(u)?I?i=d:(i=v,a=h):m(u)&&(i=y),i){var l=i(e,t);if(l){var f=w.getPooled(O.change,l,n,o);return f.type="change",b.accumulateTwoPhaseDispatches(f),f}}a&&a(e,u,t)}};e.exports=j},function(e,t,n){"use strict";var r=n(7),o=n(66),i=n(18),a=n(467),u=n(29),s=(n(2),{dangerouslyReplaceNodeWithMarkup:function(e,t){if(i.canUseDOM?void 0:r("56"),t?void 0:r("57"),"HTML"===e.nodeName?r("58"):void 0,"string"==typeof t){var n=a(t,u)[0];e.parentNode.replaceChild(n,e)}else o.replaceChildWithTree(e,t)}});e.exports=s},function(e,t){"use strict";var n=["ResponderEventPlugin","SimpleEventPlugin","TapEventPlugin","EnterLeaveEventPlugin","ChangeEventPlugin","SelectEventPlugin","BeforeInputEventPlugin"];e.exports=n},function(e,t,n){"use strict";var r=n(82),o=n(13),i=n(106),a={mouseEnter:{registrationName:"onMouseEnter",dependencies:["topMouseOut","topMouseOver"]},mouseLeave:{registrationName:"onMouseLeave",dependencies:["topMouseOut","topMouseOver"]}},u={eventTypes:a,extractEvents:function(e,t,n,u){if("topMouseOver"===e&&(n.relatedTarget||n.fromElement))return null;if("topMouseOut"!==e&&"topMouseOver"!==e)return null;var s;if(u.window===u)s=u;else{var c=u.ownerDocument;s=c?c.defaultView||c.parentWindow:window}var l,f;if("topMouseOut"===e){l=t;var p=n.relatedTarget||n.toElement;f=p?o.getClosestInstanceFromNode(p):null}else l=null,f=t;if(l===f)return null;var d=null==l?s:o.getNodeFromInstance(l),h=null==f?s:o.getNodeFromInstance(f),v=i.getPooled(a.mouseLeave,l,n,u);v.type="mouseleave",v.target=d,v.relatedTarget=h;var m=i.getPooled(a.mouseEnter,f,n,u);return m.type="mouseenter",m.target=h,m.relatedTarget=d,r.accumulateEnterLeaveDispatches(v,m,l,f),[v,m]}};e.exports=u},function(e,t,n){"use strict";function r(e){this._root=e,this._startText=this.getText(),this._fallbackText=null}var o=n(10),i=n(59),a=n(251);o(r.prototype,{destructor:function(){this._root=null,this._startText=null,this._fallbackText=null},getText:function(){return"value"in this._root?this._root.value:this._root[a()]},getData:function(){if(this._fallbackText)return this._fallbackText;var e,t,n=this._startText,r=n.length,o=this.getText(),i=o.length;for(e=0;e<r&&n[e]===o[e];e++);var a=r-e;for(t=1;t<=a&&n[r-t]===o[i-t];t++);var u=t>1?1-t:void 0;return this._fallbackText=o.slice(e,u),this._fallbackText}}),i.addPoolingTo(r),e.exports=r},function(e,t,n){"use strict";var r=n(67),o=r.injection.MUST_USE_PROPERTY,i=r.injection.HAS_BOOLEAN_VALUE,a=r.injection.HAS_NUMERIC_VALUE,u=r.injection.HAS_POSITIVE_NUMERIC_VALUE,s=r.injection.HAS_OVERLOADED_BOOLEAN_VALUE,c={isCustomAttribute:RegExp.prototype.test.bind(new RegExp("^(data|aria)-["+r.ATTRIBUTE_NAME_CHAR+"]*$")),Properties:{accept:0,acceptCharset:0,accessKey:0,action:0,allowFullScreen:i,allowTransparency:0,alt:0,as:0,async:i,autoComplete:0,autoPlay:i,capture:i,cellPadding:0,cellSpacing:0,charSet:0,challenge:0,checked:o|i,cite:0,classID:0,className:0,cols:u,colSpan:0,content:0,contentEditable:0,contextMenu:0,controls:i,coords:0,crossOrigin:0,data:0,dateTime:0,default:i,defer:i,dir:0,disabled:i,download:s,draggable:0,encType:0,form:0,formAction:0,formEncType:0,formMethod:0,formNoValidate:i,formTarget:0,frameBorder:0,headers:0,height:0,hidden:i,high:0,href:0,hrefLang:0,htmlFor:0,httpEquiv:0,icon:0,id:0,inputMode:0,integrity:0,is:0,keyParams:0,keyType:0,kind:0,label:0,lang:0,list:0,loop:i,low:0,manifest:0,marginHeight:0,marginWidth:0,max:0,maxLength:0,media:0,mediaGroup:0,method:0,min:0,minLength:0,multiple:o|i,muted:o|i,name:0,nonce:0,noValidate:i,open:i,optimum:0,pattern:0,placeholder:0,playsInline:i,poster:0,preload:0,profile:0,radioGroup:0,readOnly:i,referrerPolicy:0,rel:0,required:i,reversed:i,role:0,rows:u,rowSpan:a,sandbox:0,scope:0,scoped:i,scrolling:0,seamless:i,selected:o|i,shape:0,size:u,sizes:0,span:u,spellCheck:0,src:0,srcDoc:0,srcLang:0,srcSet:0,start:a,step:0,style:0,summary:0,tabIndex:0,target:0,title:0,type:0,useMap:0,value:0,width:0,wmode:0,wrap:0,about:0,datatype:0,inlist:0,prefix:0,property:0,resource:0,typeof:0,vocab:0,autoCapitalize:0,autoCorrect:0,autoSave:0,color:0,itemProp:0,itemScope:i,itemType:0,itemID:0,itemRef:0,results:0,security:0,unselectable:0},DOMAttributeNames:{acceptCharset:"accept-charset",className:"class",htmlFor:"for",httpEquiv:"http-equiv"},DOMPropertyNames:{}};e.exports=c},function(e,t,n){(function(t){"use strict";function r(e,t,n,r){var o=void 0===e[n];null!=t&&o&&(e[n]=i(t,!0))}var o=n(68),i=n(252),a=(n(162),n(172)),u=n(255),s=(n(5),{instantiateChildren:function(e,t,n,o){if(null==e)return null;var i={};return u(e,r,i),i},updateChildren:function(e,t,n,r,u,s,c,l,f){if(t||e){var p,d;for(p in t)if(t.hasOwnProperty(p)){d=e&&e[p];var h=d&&d._currentElement,v=t[p];if(null!=d&&a(h,v))o.receiveComponent(d,v,u,l),t[p]=d;else{d&&(r[p]=o.getHostNode(d),o.unmountComponent(d,!1));var m=i(v,!0);t[p]=m;var y=o.mountComponent(m,u,s,c,l,f);n.push(y)}}for(p in e)!e.hasOwnProperty(p)||t&&t.hasOwnProperty(p)||(d=e[p],r[p]=o.getHostNode(d),o.unmountComponent(d,!1))}},unmountChildren:function(e,t){for(var n in e)if(e.hasOwnProperty(n)){var r=e[n];o.unmountComponent(r,t)}}});e.exports=s}).call(t,n(157))},function(e,t,n){"use strict";var r=n(158),o=n(603),i={processChildrenUpdates:o.dangerouslyProcessChildrenUpdates,replaceNodeWithMarkup:r.dangerouslyReplaceNodeWithMarkup};e.exports=i},function(e,t,n){"use strict";function r(e){}function o(e,t){}function i(e){return!(!e.prototype||!e.prototype.isReactComponent)}function a(e){return!(!e.prototype||!e.prototype.isPureReactComponent)}var u=n(7),s=n(10),c=n(70),l=n(164),f=n(42),p=n(165),d=n(83),h=(n(31),n(246)),v=n(68),m=n(76),y=(n(2),n(141)),g=n(172),b=(n(5),{ImpureClass:0,PureClass:1,StatelessFunctional:2});r.prototype.render=function(){var e=d.get(this)._currentElement.type,t=e(this.props,this.context,this.updater);return o(e,t),t};var _=1,x={construct:function(e){this._currentElement=e,this._rootNodeID=0,this._compositeType=null,this._instance=null,this._hostParent=null,this._hostContainerInfo=null,this._updateBatchNumber=null,this._pendingElement=null,this._pendingStateQueue=null,this._pendingReplaceState=!1,this._pendingForceUpdate=!1,this._renderedNodeType=null,this._renderedComponent=null,this._context=null,this._mountOrder=0,this._topLevelWrapper=null,this._pendingCallbacks=null,this._calledComponentWillUnmount=!1},mountComponent:function(e,t,n,s){this._context=s,this._mountOrder=_++,this._hostParent=t,this._hostContainerInfo=n;var l,f=this._currentElement.props,p=this._processContext(s),h=this._currentElement.type,v=e.getUpdateQueue(),y=i(h),g=this._constructComponent(y,f,p,v);y||null!=g&&null!=g.render?a(h)?this._compositeType=b.PureClass:this._compositeType=b.ImpureClass:(l=g,o(h,l),null===g||g===!1||c.isValidElement(g)?void 0:u("105",h.displayName||h.name||"Component"),g=new r(h),this._compositeType=b.StatelessFunctional);g.props=f,g.context=p,g.refs=m,g.updater=v,this._instance=g,d.set(g,this);var x=g.state;void 0===x&&(g.state=x=null),"object"!=typeof x||Array.isArray(x)?u("106",this.getName()||"ReactCompositeComponent"):void 0,this._pendingStateQueue=null,this._pendingReplaceState=!1,this._pendingForceUpdate=!1;var E;return E=g.unstable_handleError?this.performInitialMountWithErrorHandling(l,t,n,e,s):this.performInitialMount(l,t,n,e,s),g.componentDidMount&&e.getReactMountReady().enqueue(g.componentDidMount,g),E},_constructComponent:function(e,t,n,r){return this._constructComponentWithoutOwner(e,t,n,r)},_constructComponentWithoutOwner:function(e,t,n,r){var o=this._currentElement.type;return e?new o(t,n,r):o(t,n,r)},performInitialMountWithErrorHandling:function(e,t,n,r,o){var i,a=r.checkpoint();try{i=this.performInitialMount(e,t,n,r,o)}catch(u){r.rollback(a),this._instance.unstable_handleError(u),this._pendingStateQueue&&(this._instance.state=this._processPendingState(this._instance.props,this._instance.context)),a=r.checkpoint(),this._renderedComponent.unmountComponent(!0),r.rollback(a),i=this.performInitialMount(e,t,n,r,o)}return i},performInitialMount:function(e,t,n,r,o){var i=this._instance,a=0;i.componentWillMount&&(i.componentWillMount(),this._pendingStateQueue&&(i.state=this._processPendingState(i.props,i.context))),void 0===e&&(e=this._renderValidatedComponent());var u=h.getType(e);this._renderedNodeType=u;var s=this._instantiateReactComponent(e,u!==h.EMPTY);this._renderedComponent=s;var c=v.mountComponent(s,r,t,n,this._processChildContext(o),a);return c},getHostNode:function(){return v.getHostNode(this._renderedComponent)},unmountComponent:function(e){if(this._renderedComponent){var t=this._instance;if(t.componentWillUnmount&&!t._calledComponentWillUnmount)if(t._calledComponentWillUnmount=!0,e){var n=this.getName()+".componentWillUnmount()";p.invokeGuardedCallback(n,t.componentWillUnmount.bind(t))}else t.componentWillUnmount();this._renderedComponent&&(v.unmountComponent(this._renderedComponent,e),this._renderedNodeType=null,this._renderedComponent=null,this._instance=null),this._pendingStateQueue=null,this._pendingReplaceState=!1,this._pendingForceUpdate=!1,this._pendingCallbacks=null,this._pendingElement=null,this._context=null,this._rootNodeID=0,this._topLevelWrapper=null,d.remove(t)}},_maskContext:function(e){var t=this._currentElement.type,n=t.contextTypes;if(!n)return m;var r={};for(var o in n)r[o]=e[o];return r},_processContext:function(e){var t=this._maskContext(e);return t},_processChildContext:function(e){var t,n=this._currentElement.type,r=this._instance;if(r.getChildContext&&(t=r.getChildContext()),t){"object"!=typeof n.childContextTypes?u("107",this.getName()||"ReactCompositeComponent"):void 0;for(var o in t)o in n.childContextTypes?void 0:u("108",this.getName()||"ReactCompositeComponent",o);return s({},e,t)}return e},_checkContextTypes:function(e,t,n){},receiveComponent:function(e,t,n){var r=this._currentElement,o=this._context;this._pendingElement=null,this.updateComponent(t,r,e,o,n)},performUpdateIfNecessary:function(e){null!=this._pendingElement?v.receiveComponent(this,this._pendingElement,e,this._context):null!==this._pendingStateQueue||this._pendingForceUpdate?this.updateComponent(e,this._currentElement,this._currentElement,this._context,this._context):this._updateBatchNumber=null},updateComponent:function(e,t,n,r,o){var i=this._instance;null==i?u("136",this.getName()||"ReactCompositeComponent"):void 0;var a,s=!1;this._context===o?a=i.context:(a=this._processContext(o),s=!0);var c=t.props,l=n.props;t!==n&&(s=!0),s&&i.componentWillReceiveProps&&i.componentWillReceiveProps(l,a);var f=this._processPendingState(l,a),p=!0;this._pendingForceUpdate||(i.shouldComponentUpdate?p=i.shouldComponentUpdate(l,f,a):this._compositeType===b.PureClass&&(p=!y(c,l)||!y(i.state,f))),this._updateBatchNumber=null,p?(this._pendingForceUpdate=!1,this._performComponentUpdate(n,l,f,a,e,o)):(this._currentElement=n,this._context=o,i.props=l,i.state=f,i.context=a)},_processPendingState:function(e,t){var n=this._instance,r=this._pendingStateQueue,o=this._pendingReplaceState;if(this._pendingReplaceState=!1,this._pendingStateQueue=null,!r)return n.state;if(o&&1===r.length)return r[0];for(var i=s({},o?r[0]:n.state),a=o?1:0;a<r.length;a++){var u=r[a];s(i,"function"==typeof u?u.call(n,i,e,t):u)}return i},_performComponentUpdate:function(e,t,n,r,o,i){var a,u,s,c=this._instance,l=Boolean(c.componentDidUpdate);l&&(a=c.props,u=c.state,s=c.context),c.componentWillUpdate&&c.componentWillUpdate(t,n,r),this._currentElement=e,this._context=i,c.props=t,c.state=n,c.context=r,this._updateRenderedComponent(o,i),l&&o.getReactMountReady().enqueue(c.componentDidUpdate.bind(c,a,u,s),c)},_updateRenderedComponent:function(e,t){var n=this._renderedComponent,r=n._currentElement,o=this._renderValidatedComponent(),i=0;if(g(r,o))v.receiveComponent(n,o,e,this._processChildContext(t));else{var a=v.getHostNode(n);v.unmountComponent(n,!1);var u=h.getType(o);this._renderedNodeType=u;var s=this._instantiateReactComponent(o,u!==h.EMPTY);this._renderedComponent=s;var c=v.mountComponent(s,e,this._hostParent,this._hostContainerInfo,this._processChildContext(t),i);this._replaceNodeWithMarkup(a,c,n)}},_replaceNodeWithMarkup:function(e,t,n){l.replaceNodeWithMarkup(e,t,n)},_renderValidatedComponentWithoutOwnerOrContext:function(){var e,t=this._instance;return e=t.render()},_renderValidatedComponent:function(){var e;if(this._compositeType!==b.StatelessFunctional){f.current=this;try{e=this._renderValidatedComponentWithoutOwnerOrContext()}finally{f.current=null}}else e=this._renderValidatedComponentWithoutOwnerOrContext();return null===e||e===!1||c.isValidElement(e)?void 0:u("109",this.getName()||"ReactCompositeComponent"),e},attachRef:function(e,t){var n=this.getPublicInstance();null==n?u("110"):void 0;var r=t.getPublicInstance(),o=n.refs===m?n.refs={}:n.refs;o[e]=r},detachRef:function(e){var t=this.getPublicInstance().refs;delete t[e]},getName:function(){var e=this._currentElement.type,t=this._instance&&this._instance.constructor;return e.displayName||t&&t.displayName||e.name||t&&t.name||null},getPublicInstance:function(){var e=this._instance;return this._compositeType===b.StatelessFunctional?null:e},_instantiateReactComponent:null};e.exports=x},function(e,t,n){"use strict";var r=n(13),o=n(611),i=n(245),a=n(68),u=n(36),s=n(624),c=n(640),l=n(250),f=n(648);n(5);o.inject();var p={findDOMNode:c,render:i.render,unmountComponentAtNode:i.unmountComponentAtNode,version:s,unstable_batchedUpdates:u.batchedUpdates,unstable_renderSubtreeIntoContainer:f};"undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.inject&&__REACT_DEVTOOLS_GLOBAL_HOOK__.inject({ComponentTree:{getClosestInstanceFromNode:r.getClosestInstanceFromNode,getNodeFromInstance:function(e){return e._renderedComponent&&(e=l(e)),e?r.getNodeFromInstance(e):null}},Mount:i,Reconciler:a});e.exports=p},function(e,t,n){"use strict";function r(e){if(e){var t=e._currentElement._owner||null;if(t){var n=t.getName();if(n)return" This DOM node was rendered by `"+n+"`."}}return""}function o(e,t){t&&(G[e._tag]&&(null!=t.children||null!=t.dangerouslySetInnerHTML?v("137",e._tag,e._currentElement._owner?" Check the render method of "+e._currentElement._owner.getName()+".":""):void 0),null!=t.dangerouslySetInnerHTML&&(null!=t.children?v("60"):void 0,"object"==typeof t.dangerouslySetInnerHTML&&B in t.dangerouslySetInnerHTML?void 0:v("61")),null!=t.style&&"object"!=typeof t.style?v("62",r(e)):void 0)}function i(e,t,n,r){if(!(r instanceof I)){var o=e._hostContainerInfo,i=o._node&&o._node.nodeType===z,u=i?o._node:o._ownerDocument;U(t,u),r.getReactMountReady().enqueue(a,{inst:e,registrationName:t,listener:n})}}function a(){var e=this;w.putListener(e.inst,e.registrationName,e.listener)}function u(){var e=this;T.postMountWrapper(e)}function s(){var e=this;R.postMountWrapper(e)}function c(){var e=this;k.postMountWrapper(e)}function l(){var e=this;e._rootNodeID?void 0:v("63");var t=D(e);switch(t?void 0:v("64"),e._tag){case"iframe":case"object":e._wrapperState.listeners=[C.trapBubbledEvent("topLoad","load",t)];break;case"video":case"audio":e._wrapperState.listeners=[];for(var n in H)H.hasOwnProperty(n)&&e._wrapperState.listeners.push(C.trapBubbledEvent(n,H[n],t));break;case"source":e._wrapperState.listeners=[C.trapBubbledEvent("topError","error",t)];break;case"img":e._wrapperState.listeners=[C.trapBubbledEvent("topError","error",t),C.trapBubbledEvent("topLoad","load",t)];break;case"form":e._wrapperState.listeners=[C.trapBubbledEvent("topReset","reset",t),C.trapBubbledEvent("topSubmit","submit",t)];break;case"input":case"select":case"textarea":e._wrapperState.listeners=[C.trapBubbledEvent("topInvalid","invalid",t)]}}function f(){A.postUpdateWrapper(this)}function p(e){Q.call(X,e)||($.test(e)?void 0:v("65",e),X[e]=!0)}function d(e,t){return e.indexOf("-")>=0||null!=t.is}function h(e){var t=e.type;p(t),this._currentElement=e,this._tag=t.toLowerCase(),this._namespaceURI=null,this._renderedChildren=null,this._previousStyle=null,this._previousStyleCopy=null,this._hostNode=null,this._hostParent=null,this._rootNodeID=0,this._domID=0,this._hostContainerInfo=null,this._wrapperState=null,this._topLevelWrapper=null,this._flags=0}var v=n(7),m=n(10),y=n(586),g=n(588),b=n(66),_=n(159),x=n(67),E=n(238),w=n(81),S=n(160),C=n(105),P=n(239),O=n(13),T=n(604),k=n(605),A=n(240),R=n(608),M=(n(31),n(617)),I=n(622),N=(n(29),n(108)),j=(n(2),n(171),n(141),n(173),n(5),P),F=w.deleteListener,D=O.getNodeFromInstance,U=C.listenTo,L=S.registrationNameModules,V={string:!0,number:!0},W="style",B="__html",q={children:null,dangerouslySetInnerHTML:null,suppressContentEditableWarning:null},z=11,H={topAbort:"abort",topCanPlay:"canplay",topCanPlayThrough:"canplaythrough",topDurationChange:"durationchange",topEmptied:"emptied",topEncrypted:"encrypted",topEnded:"ended",topError:"error",topLoadedData:"loadeddata",topLoadedMetadata:"loadedmetadata",topLoadStart:"loadstart",topPause:"pause",topPlay:"play",topPlaying:"playing",topProgress:"progress",topRateChange:"ratechange",topSeeked:"seeked",topSeeking:"seeking",topStalled:"stalled",topSuspend:"suspend",topTimeUpdate:"timeupdate",topVolumeChange:"volumechange",topWaiting:"waiting"},Y={area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0},K={listing:!0,pre:!0,textarea:!0},G=m({menuitem:!0},Y),$=/^[a-zA-Z][a-zA-Z:_\.\-\d]*$/,X={},Q={}.hasOwnProperty,J=1;h.displayName="ReactDOMComponent",h.Mixin={mountComponent:function(e,t,n,r){this._rootNodeID=J++,this._domID=n._idCounter++,this._hostParent=t,this._hostContainerInfo=n;var i=this._currentElement.props;switch(this._tag){case"audio":case"form":case"iframe":case"img":case"link":case"object":case"source":case"video":this._wrapperState={listeners:null},e.getReactMountReady().enqueue(l,this);break;case"input":T.mountWrapper(this,i,t),i=T.getHostProps(this,i),e.getReactMountReady().enqueue(l,this);break;case"option":k.mountWrapper(this,i,t),i=k.getHostProps(this,i);break;case"select":A.mountWrapper(this,i,t),i=A.getHostProps(this,i),e.getReactMountReady().enqueue(l,this);break;case"textarea":R.mountWrapper(this,i,t),i=R.getHostProps(this,i),e.getReactMountReady().enqueue(l,this)}o(this,i);var a,f;null!=t?(a=t._namespaceURI,f=t._tag):n._tag&&(a=n._namespaceURI,f=n._tag),(null==a||a===_.svg&&"foreignobject"===f)&&(a=_.html),a===_.html&&("svg"===this._tag?a=_.svg:"math"===this._tag&&(a=_.mathml)),this._namespaceURI=a;var p;if(e.useCreateElement){var d,h=n._ownerDocument;if(a===_.html)if("script"===this._tag){var v=h.createElement("div"),m=this._currentElement.type;v.innerHTML="<"+m+"></"+m+">",d=v.removeChild(v.firstChild)}else d=i.is?h.createElement(this._currentElement.type,i.is):h.createElement(this._currentElement.type);else d=h.createElementNS(a,this._currentElement.type);O.precacheNode(this,d),this._flags|=j.hasCachedChildNodes,this._hostParent||E.setAttributeForRoot(d),this._updateDOMProperties(null,i,e);var g=b(d);this._createInitialChildren(e,i,r,g),p=g}else{var x=this._createOpenTagMarkupAndPutListeners(e,i),w=this._createContentMarkup(e,i,r);p=!w&&Y[this._tag]?x+"/>":x+">"+w+"</"+this._currentElement.type+">"}switch(this._tag){case"input":e.getReactMountReady().enqueue(u,this),i.autoFocus&&e.getReactMountReady().enqueue(y.focusDOMComponent,this);break;case"textarea":e.getReactMountReady().enqueue(s,this),i.autoFocus&&e.getReactMountReady().enqueue(y.focusDOMComponent,this);break;case"select":i.autoFocus&&e.getReactMountReady().enqueue(y.focusDOMComponent,this);break;case"button":i.autoFocus&&e.getReactMountReady().enqueue(y.focusDOMComponent,this);break;case"option":e.getReactMountReady().enqueue(c,this)}return p},_createOpenTagMarkupAndPutListeners:function(e,t){var n="<"+this._currentElement.type;for(var r in t)if(t.hasOwnProperty(r)){var o=t[r];if(null!=o)if(L.hasOwnProperty(r))o&&i(this,r,o,e);else{r===W&&(o&&(o=this._previousStyleCopy=m({},t.style)),o=g.createMarkupForStyles(o,this));var a=null;null!=this._tag&&d(this._tag,t)?q.hasOwnProperty(r)||(a=E.createMarkupForCustomAttribute(r,o)):a=E.createMarkupForProperty(r,o),a&&(n+=" "+a)}}return e.renderToStaticMarkup?n:(this._hostParent||(n+=" "+E.createMarkupForRoot()),n+=" "+E.createMarkupForID(this._domID))},_createContentMarkup:function(e,t,n){var r="",o=t.dangerouslySetInnerHTML;if(null!=o)null!=o.__html&&(r=o.__html);else{var i=V[typeof t.children]?t.children:null,a=null!=i?null:t.children;if(null!=i)r=N(i);else if(null!=a){var u=this.mountChildren(a,e,n);r=u.join("")}}return K[this._tag]&&"\n"===r.charAt(0)?"\n"+r:r},_createInitialChildren:function(e,t,n,r){var o=t.dangerouslySetInnerHTML;if(null!=o)null!=o.__html&&b.queueHTML(r,o.__html);else{var i=V[typeof t.children]?t.children:null,a=null!=i?null:t.children;if(null!=i)b.queueText(r,i);else if(null!=a)for(var u=this.mountChildren(a,e,n),s=0;s<u.length;s++)b.queueChild(r,u[s])}},receiveComponent:function(e,t,n){var r=this._currentElement;this._currentElement=e,this.updateComponent(t,r,e,n)},updateComponent:function(e,t,n,r){var i=t.props,a=this._currentElement.props;switch(this._tag){case"input":i=T.getHostProps(this,i),a=T.getHostProps(this,a);break;case"option":i=k.getHostProps(this,i),a=k.getHostProps(this,a);break;case"select":i=A.getHostProps(this,i),a=A.getHostProps(this,a);break;case"textarea":i=R.getHostProps(this,i),a=R.getHostProps(this,a)}switch(o(this,a),this._updateDOMProperties(i,a,e),this._updateDOMChildren(i,a,e,r),this._tag){case"input":T.updateWrapper(this);break;case"textarea":R.updateWrapper(this);break;case"select":e.getReactMountReady().enqueue(f,this)}},_updateDOMProperties:function(e,t,n){var r,o,a;for(r in e)if(!t.hasOwnProperty(r)&&e.hasOwnProperty(r)&&null!=e[r])if(r===W){var u=this._previousStyleCopy;for(o in u)u.hasOwnProperty(o)&&(a=a||{},a[o]="");this._previousStyleCopy=null}else L.hasOwnProperty(r)?e[r]&&F(this,r):d(this._tag,e)?q.hasOwnProperty(r)||E.deleteValueForAttribute(D(this),r):(x.properties[r]||x.isCustomAttribute(r))&&E.deleteValueForProperty(D(this),r);for(r in t){var s=t[r],c=r===W?this._previousStyleCopy:null!=e?e[r]:void 0;if(t.hasOwnProperty(r)&&s!==c&&(null!=s||null!=c))if(r===W)if(s?s=this._previousStyleCopy=m({},s):this._previousStyleCopy=null,c){for(o in c)!c.hasOwnProperty(o)||s&&s.hasOwnProperty(o)||(a=a||{},a[o]="");for(o in s)s.hasOwnProperty(o)&&c[o]!==s[o]&&(a=a||{},a[o]=s[o])}else a=s;else if(L.hasOwnProperty(r))s?i(this,r,s,n):c&&F(this,r);else if(d(this._tag,t))q.hasOwnProperty(r)||E.setValueForAttribute(D(this),r,s);else if(x.properties[r]||x.isCustomAttribute(r)){var l=D(this);null!=s?E.setValueForProperty(l,r,s):E.deleteValueForProperty(l,r)}}a&&g.setValueForStyles(D(this),a,this)},_updateDOMChildren:function(e,t,n,r){var o=V[typeof e.children]?e.children:null,i=V[typeof t.children]?t.children:null,a=e.dangerouslySetInnerHTML&&e.dangerouslySetInnerHTML.__html,u=t.dangerouslySetInnerHTML&&t.dangerouslySetInnerHTML.__html,s=null!=o?null:e.children,c=null!=i?null:t.children,l=null!=o||null!=a,f=null!=i||null!=u;null!=s&&null==c?this.updateChildren(null,n,r):l&&!f&&this.updateTextContent(""),null!=i?o!==i&&this.updateTextContent(""+i):null!=u?a!==u&&this.updateMarkup(""+u):null!=c&&this.updateChildren(c,n,r)},getHostNode:function(){return D(this)},unmountComponent:function(e){switch(this._tag){case"audio":case"form":case"iframe":case"img":case"link":case"object":case"source":case"video":var t=this._wrapperState.listeners;if(t)for(var n=0;n<t.length;n++)t[n].remove();break;case"html":case"head":case"body":v("66",this._tag)}this.unmountChildren(e),O.uncacheNode(this),w.deleteAllListeners(this),this._rootNodeID=0,this._domID=0,this._wrapperState=null},getPublicInstance:function(){return D(this)}},m(h.prototype,h.Mixin,M.Mixin),e.exports=h},function(e,t,n){"use strict";function r(e,t){var n={_topLevelWrapper:e,_idCounter:1,_ownerDocument:t?t.nodeType===o?t:t.ownerDocument:null,_node:t,_tag:t?t.nodeName.toLowerCase():null,_namespaceURI:t?t.namespaceURI:null};return n}var o=(n(173),9);e.exports=r},function(e,t,n){"use strict";var r=n(10),o=n(66),i=n(13),a=function(e){this._currentElement=null,this._hostNode=null,this._hostParent=null,this._hostContainerInfo=null,this._domID=0};r(a.prototype,{mountComponent:function(e,t,n,r){var a=n._idCounter++;this._domID=a,this._hostParent=t,this._hostContainerInfo=n;var u=" react-empty: "+this._domID+" "; if(e.useCreateElement){var s=n._ownerDocument,c=s.createComment(u);return i.precacheNode(this,c),o(c)}return e.renderToStaticMarkup?"":"<!--"+u+"-->"},receiveComponent:function(){},getHostNode:function(){return i.getNodeFromInstance(this)},unmountComponent:function(){i.uncacheNode(this)}}),e.exports=a},function(e,t){"use strict";var n={useCreateElement:!0,useFiber:!1};e.exports=n},function(e,t,n){"use strict";var r=n(158),o=n(13),i={dangerouslyProcessChildrenUpdates:function(e,t){var n=o.getNodeFromInstance(e);r.processUpdates(n,t)}};e.exports=i},function(e,t,n){"use strict";function r(){this._rootNodeID&&f.updateWrapper(this)}function o(e){var t=this._currentElement.props,n=s.executeOnChange(t,e);l.asap(r,this);var o=t.name;if("radio"===t.type&&null!=o){for(var a=c.getNodeFromInstance(this),u=a;u.parentNode;)u=u.parentNode;for(var f=u.querySelectorAll("input[name="+JSON.stringify(""+o)+'][type="radio"]'),p=0;p<f.length;p++){var d=f[p];if(d!==a&&d.form===a.form){var h=c.getInstanceFromNode(d);h?void 0:i("90"),l.asap(r,h)}}}return n}var i=n(7),a=n(10),u=n(238),s=n(163),c=n(13),l=n(36),f=(n(2),n(5),{getHostProps:function(e,t){var n=s.getValue(t),r=s.getChecked(t),o=a({type:void 0,step:void 0,min:void 0,max:void 0},t,{defaultChecked:void 0,defaultValue:void 0,value:null!=n?n:e._wrapperState.initialValue,checked:null!=r?r:e._wrapperState.initialChecked,onChange:e._wrapperState.onChange});return o},mountWrapper:function(e,t){var n=t.defaultValue;e._wrapperState={initialChecked:null!=t.checked?t.checked:t.defaultChecked,initialValue:null!=t.value?t.value:n,listeners:null,onChange:o.bind(e)}},updateWrapper:function(e){var t=e._currentElement.props,n=t.checked;null!=n&&u.setValueForProperty(c.getNodeFromInstance(e),"checked",n||!1);var r=c.getNodeFromInstance(e),o=s.getValue(t);if(null!=o){var i=""+o;i!==r.value&&(r.value=i)}else null==t.value&&null!=t.defaultValue&&(r.defaultValue=""+t.defaultValue),null==t.checked&&null!=t.defaultChecked&&(r.defaultChecked=!!t.defaultChecked)},postMountWrapper:function(e){var t=e._currentElement.props,n=c.getNodeFromInstance(e);switch(t.type){case"submit":case"reset":break;case"color":case"date":case"datetime":case"datetime-local":case"month":case"time":case"week":n.value="",n.value=n.defaultValue;break;default:n.value=n.value}var r=n.name;""!==r&&(n.name=""),n.defaultChecked=!n.defaultChecked,n.defaultChecked=!n.defaultChecked,""!==r&&(n.name=r)}});e.exports=f},function(e,t,n){"use strict";function r(e){var t="";return i.Children.forEach(e,function(e){null!=e&&("string"==typeof e||"number"==typeof e?t+=e:s||(s=!0))}),t}var o=n(10),i=n(70),a=n(13),u=n(240),s=(n(5),!1),c={mountWrapper:function(e,t,n){var o=null;if(null!=n){var i=n;"optgroup"===i._tag&&(i=i._hostParent),null!=i&&"select"===i._tag&&(o=u.getSelectValueContext(i))}var a=null;if(null!=o){var s;if(s=null!=t.value?t.value+"":r(t.children),a=!1,Array.isArray(o)){for(var c=0;c<o.length;c++)if(""+o[c]===s){a=!0;break}}else a=""+o===s}e._wrapperState={selected:a}},postMountWrapper:function(e){var t=e._currentElement.props;if(null!=t.value){var n=a.getNodeFromInstance(e);n.setAttribute("value",t.value)}},getHostProps:function(e,t){var n=o({selected:void 0,children:void 0},t);null!=e._wrapperState.selected&&(n.selected=e._wrapperState.selected);var i=r(t.children);return i&&(n.children=i),n}};e.exports=c},function(e,t,n){"use strict";function r(e,t,n,r){return e===n&&t===r}function o(e){var t=document.selection,n=t.createRange(),r=n.text.length,o=n.duplicate();o.moveToElementText(e),o.setEndPoint("EndToStart",n);var i=o.text.length,a=i+r;return{start:i,end:a}}function i(e){var t=window.getSelection&&window.getSelection();if(!t||0===t.rangeCount)return null;var n=t.anchorNode,o=t.anchorOffset,i=t.focusNode,a=t.focusOffset,u=t.getRangeAt(0);try{u.startContainer.nodeType,u.endContainer.nodeType}catch(e){return null}var s=r(t.anchorNode,t.anchorOffset,t.focusNode,t.focusOffset),c=s?0:u.toString().length,l=u.cloneRange();l.selectNodeContents(e),l.setEnd(u.startContainer,u.startOffset);var f=r(l.startContainer,l.startOffset,l.endContainer,l.endOffset),p=f?0:l.toString().length,d=p+c,h=document.createRange();h.setStart(n,o),h.setEnd(i,a);var v=h.collapsed;return{start:v?d:p,end:v?p:d}}function a(e,t){var n,r,o=document.selection.createRange().duplicate();void 0===t.end?(n=t.start,r=n):t.start>t.end?(n=t.end,r=t.start):(n=t.start,r=t.end),o.moveToElementText(e),o.moveStart("character",n),o.setEndPoint("EndToStart",o),o.moveEnd("character",r-n),o.select()}function u(e,t){if(window.getSelection){var n=window.getSelection(),r=e[l()].length,o=Math.min(t.start,r),i=void 0===t.end?o:Math.min(t.end,r);if(!n.extend&&o>i){var a=i;i=o,o=a}var u=c(e,o),s=c(e,i);if(u&&s){var f=document.createRange();f.setStart(u.node,u.offset),n.removeAllRanges(),o>i?(n.addRange(f),n.extend(s.node,s.offset)):(f.setEnd(s.node,s.offset),n.addRange(f))}}}var s=n(18),c=n(645),l=n(251),f=s.canUseDOM&&"selection"in document&&!("getSelection"in window),p={getOffsets:f?o:i,setOffsets:f?a:u};e.exports=p},function(e,t,n){"use strict";var r=n(7),o=n(10),i=n(158),a=n(66),u=n(13),s=n(108),c=(n(2),n(173),function(e){this._currentElement=e,this._stringText=""+e,this._hostNode=null,this._hostParent=null,this._domID=0,this._mountIndex=0,this._closingComment=null,this._commentNodes=null});o(c.prototype,{mountComponent:function(e,t,n,r){var o=n._idCounter++,i=" react-text: "+o+" ",c=" /react-text ";if(this._domID=o,this._hostParent=t,e.useCreateElement){var l=n._ownerDocument,f=l.createComment(i),p=l.createComment(c),d=a(l.createDocumentFragment());return a.queueChild(d,a(f)),this._stringText&&a.queueChild(d,a(l.createTextNode(this._stringText))),a.queueChild(d,a(p)),u.precacheNode(this,f),this._closingComment=p,d}var h=s(this._stringText);return e.renderToStaticMarkup?h:"<!--"+i+"-->"+h+"<!--"+c+"-->"},receiveComponent:function(e,t){if(e!==this._currentElement){this._currentElement=e;var n=""+e;if(n!==this._stringText){this._stringText=n;var r=this.getHostNode();i.replaceDelimitedText(r[0],r[1],n)}}},getHostNode:function(){var e=this._commentNodes;if(e)return e;if(!this._closingComment)for(var t=u.getNodeFromInstance(this),n=t.nextSibling;;){if(null==n?r("67",this._domID):void 0,8===n.nodeType&&" /react-text "===n.nodeValue){this._closingComment=n;break}n=n.nextSibling}return e=[this._hostNode,this._closingComment],this._commentNodes=e,e},unmountComponent:function(){this._closingComment=null,this._commentNodes=null,u.uncacheNode(this)}}),e.exports=c},function(e,t,n){"use strict";function r(){this._rootNodeID&&l.updateWrapper(this)}function o(e){var t=this._currentElement.props,n=u.executeOnChange(t,e);return c.asap(r,this),n}var i=n(7),a=n(10),u=n(163),s=n(13),c=n(36),l=(n(2),n(5),{getHostProps:function(e,t){null!=t.dangerouslySetInnerHTML?i("91"):void 0;var n=a({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue,onChange:e._wrapperState.onChange});return n},mountWrapper:function(e,t){var n=u.getValue(t),r=n;if(null==n){var a=t.defaultValue,s=t.children;null!=s&&(null!=a?i("92"):void 0,Array.isArray(s)&&(s.length<=1?void 0:i("93"),s=s[0]),a=""+s),null==a&&(a=""),r=a}e._wrapperState={initialValue:""+r,listeners:null,onChange:o.bind(e)}},updateWrapper:function(e){var t=e._currentElement.props,n=s.getNodeFromInstance(e),r=u.getValue(t);if(null!=r){var o=""+r;o!==n.value&&(n.value=o),null==t.defaultValue&&(n.defaultValue=o)}null!=t.defaultValue&&(n.defaultValue=t.defaultValue)},postMountWrapper:function(e){var t=s.getNodeFromInstance(e);t.value=t.textContent}});e.exports=l},function(e,t,n){"use strict";function r(e,t){"_hostNode"in e?void 0:s("33"),"_hostNode"in t?void 0:s("33");for(var n=0,r=e;r;r=r._hostParent)n++;for(var o=0,i=t;i;i=i._hostParent)o++;for(;n-o>0;)e=e._hostParent,n--;for(;o-n>0;)t=t._hostParent,o--;for(var a=n;a--;){if(e===t)return e;e=e._hostParent,t=t._hostParent}return null}function o(e,t){"_hostNode"in e?void 0:s("35"),"_hostNode"in t?void 0:s("35");for(;t;){if(t===e)return!0;t=t._hostParent}return!1}function i(e){return"_hostNode"in e?void 0:s("36"),e._hostParent}function a(e,t,n){for(var r=[];e;)r.push(e),e=e._hostParent;var o;for(o=r.length;o-- >0;)t(r[o],"captured",n);for(o=0;o<r.length;o++)t(r[o],"bubbled",n)}function u(e,t,n,o,i){for(var a=e&&t?r(e,t):null,u=[];e&&e!==a;)u.push(e),e=e._hostParent;for(var s=[];t&&t!==a;)s.push(t),t=t._hostParent;var c;for(c=0;c<u.length;c++)n(u[c],"bubbled",o);for(c=s.length;c-- >0;)n(s[c],"captured",i)}var s=n(7);n(2);e.exports={isAncestor:o,getLowestCommonAncestor:r,getParentInstance:i,traverseTwoPhase:a,traverseEnterLeave:u}},function(e,t,n){"use strict";function r(){this.reinitializeTransaction()}var o=n(10),i=n(36),a=n(107),u=n(29),s={initialize:u,close:function(){p.isBatchingUpdates=!1}},c={initialize:u,close:i.flushBatchedUpdates.bind(i)},l=[c,s];o(r.prototype,a,{getTransactionWrappers:function(){return l}});var f=new r,p={isBatchingUpdates:!1,batchedUpdates:function(e,t,n,r,o,i){var a=p.isBatchingUpdates;return p.isBatchingUpdates=!0,a?e(t,n,r,o,i):f.perform(e,null,t,n,r,o,i)}};e.exports=p},function(e,t,n){"use strict";function r(){w||(w=!0,g.EventEmitter.injectReactEventListener(y),g.EventPluginHub.injectEventPluginOrder(u),g.EventPluginUtils.injectComponentTree(p),g.EventPluginUtils.injectTreeTraversal(h),g.EventPluginHub.injectEventPluginsByName({SimpleEventPlugin:E,EnterLeaveEventPlugin:s,ChangeEventPlugin:a,SelectEventPlugin:x,BeforeInputEventPlugin:i}),g.HostComponent.injectGenericComponentClass(f),g.HostComponent.injectTextComponentClass(v),g.DOMProperty.injectDOMPropertyConfig(o),g.DOMProperty.injectDOMPropertyConfig(c),g.DOMProperty.injectDOMPropertyConfig(_),g.EmptyComponent.injectEmptyComponentFactory(function(e){return new d(e)}),g.Updates.injectReconcileTransaction(b),g.Updates.injectBatchingStrategy(m),g.Component.injectEnvironment(l))}var o=n(585),i=n(587),a=n(589),u=n(591),s=n(592),c=n(594),l=n(596),f=n(599),p=n(13),d=n(601),h=n(609),v=n(607),m=n(610),y=n(614),g=n(615),b=n(620),_=n(625),x=n(626),E=n(627),w=!1;e.exports={inject:r}},function(e,t){"use strict";var n="function"==typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103;e.exports=n},function(e,t,n){"use strict";function r(e){o.enqueueEvents(e),o.processEventQueue(!1)}var o=n(81),i={handleTopLevel:function(e,t,n,i){var a=o.extractEvents(e,t,n,i);r(a)}};e.exports=i},function(e,t,n){"use strict";function r(e){for(;e._hostParent;)e=e._hostParent;var t=f.getNodeFromInstance(e),n=t.parentNode;return f.getClosestInstanceFromNode(n)}function o(e,t){this.topLevelType=e,this.nativeEvent=t,this.ancestors=[]}function i(e){var t=d(e.nativeEvent),n=f.getClosestInstanceFromNode(t),o=n;do e.ancestors.push(o),o=o&&r(o);while(o);for(var i=0;i<e.ancestors.length;i++)n=e.ancestors[i],v._handleTopLevel(e.topLevelType,n,e.nativeEvent,d(e.nativeEvent))}function a(e){var t=h(window);e(t)}var u=n(10),s=n(208),c=n(18),l=n(59),f=n(13),p=n(36),d=n(170),h=n(469);u(o.prototype,{destructor:function(){this.topLevelType=null,this.nativeEvent=null,this.ancestors.length=0}}),l.addPoolingTo(o,l.twoArgumentPooler);var v={_enabled:!0,_handleTopLevel:null,WINDOW_HANDLE:c.canUseDOM?window:null,setHandleTopLevel:function(e){v._handleTopLevel=e},setEnabled:function(e){v._enabled=!!e},isEnabled:function(){return v._enabled},trapBubbledEvent:function(e,t,n){return n?s.listen(n,t,v.dispatchEvent.bind(null,e)):null},trapCapturedEvent:function(e,t,n){return n?s.capture(n,t,v.dispatchEvent.bind(null,e)):null},monitorScrollValue:function(e){var t=a.bind(null,e);s.listen(window,"scroll",t)},dispatchEvent:function(e,t){if(v._enabled){var n=o.getPooled(e,t);try{p.batchedUpdates(i,n)}finally{o.release(n)}}}};e.exports=v},function(e,t,n){"use strict";var r=n(67),o=n(81),i=n(161),a=n(164),u=n(241),s=n(105),c=n(243),l=n(36),f={Component:a.injection,DOMProperty:r.injection,EmptyComponent:u.injection,EventPluginHub:o.injection,EventPluginUtils:i.injection,EventEmitter:s.injection,HostComponent:c.injection,Updates:l.injection};e.exports=f},function(e,t,n){"use strict";var r=n(638),o=/\/?>/,i=/^<\!\-\-/,a={CHECKSUM_ATTR_NAME:"data-react-checksum",addChecksumToMarkup:function(e){var t=r(e);return i.test(e)?e:e.replace(o," "+a.CHECKSUM_ATTR_NAME+'="'+t+'"$&')},canReuseMarkup:function(e,t){var n=t.getAttribute(a.CHECKSUM_ATTR_NAME);n=n&&parseInt(n,10);var o=r(e);return o===n}};e.exports=a},function(e,t,n){"use strict";function r(e,t,n){return{type:"INSERT_MARKUP",content:e,fromIndex:null,fromNode:null,toIndex:n,afterNode:t}}function o(e,t,n){return{type:"MOVE_EXISTING",content:null,fromIndex:e._mountIndex,fromNode:p.getHostNode(e),toIndex:n,afterNode:t}}function i(e,t){return{type:"REMOVE_NODE",content:null,fromIndex:e._mountIndex,fromNode:t,toIndex:null,afterNode:null}}function a(e){return{type:"SET_MARKUP",content:e,fromIndex:null,fromNode:null,toIndex:null,afterNode:null}}function u(e){return{type:"TEXT_CONTENT",content:e,fromIndex:null,fromNode:null,toIndex:null,afterNode:null}}function s(e,t){return t&&(e=e||[],e.push(t)),e}function c(e,t){f.processChildrenUpdates(e,t)}var l=n(7),f=n(164),p=(n(83),n(31),n(42),n(68)),d=n(595),h=(n(29),n(641)),v=(n(2),{Mixin:{_reconcilerInstantiateChildren:function(e,t,n){return d.instantiateChildren(e,t,n)},_reconcilerUpdateChildren:function(e,t,n,r,o,i){var a,u=0;return a=h(t,u),d.updateChildren(e,a,n,r,o,this,this._hostContainerInfo,i,u),a},mountChildren:function(e,t,n){var r=this._reconcilerInstantiateChildren(e,t,n);this._renderedChildren=r;var o=[],i=0;for(var a in r)if(r.hasOwnProperty(a)){var u=r[a],s=0,c=p.mountComponent(u,t,this,this._hostContainerInfo,n,s);u._mountIndex=i++,o.push(c)}return o},updateTextContent:function(e){var t=this._renderedChildren;d.unmountChildren(t,!1);for(var n in t)t.hasOwnProperty(n)&&l("118");var r=[u(e)];c(this,r)},updateMarkup:function(e){var t=this._renderedChildren;d.unmountChildren(t,!1);for(var n in t)t.hasOwnProperty(n)&&l("118");var r=[a(e)];c(this,r)},updateChildren:function(e,t,n){this._updateChildren(e,t,n)},_updateChildren:function(e,t,n){var r=this._renderedChildren,o={},i=[],a=this._reconcilerUpdateChildren(r,e,i,o,t,n);if(a||r){var u,l=null,f=0,d=0,h=0,v=null;for(u in a)if(a.hasOwnProperty(u)){var m=r&&r[u],y=a[u];m===y?(l=s(l,this.moveChild(m,v,f,d)),d=Math.max(m._mountIndex,d),m._mountIndex=f):(m&&(d=Math.max(m._mountIndex,d)),l=s(l,this._mountChildAtIndex(y,i[h],v,f,t,n)),h++),f++,v=p.getHostNode(y)}for(u in o)o.hasOwnProperty(u)&&(l=s(l,this._unmountChild(r[u],o[u])));l&&c(this,l),this._renderedChildren=a}},unmountChildren:function(e){var t=this._renderedChildren;d.unmountChildren(t,e),this._renderedChildren=null},moveChild:function(e,t,n,r){if(e._mountIndex<r)return o(e,t,n)},createChild:function(e,t,n){return r(n,t,e._mountIndex)},removeChild:function(e,t){return i(e,t)},_mountChildAtIndex:function(e,t,n,r,o,i){return e._mountIndex=r,this.createChild(e,n,t)},_unmountChild:function(e,t){var n=this.removeChild(e,t);return e._mountIndex=null,n}}});e.exports=v},function(e,t,n){"use strict";function r(e){return!(!e||"function"!=typeof e.attachRef||"function"!=typeof e.detachRef)}var o=n(7),i=(n(2),{addComponentAsRefTo:function(e,t,n){r(n)?void 0:o("119"),n.attachRef(t,e)},removeComponentAsRefFrom:function(e,t,n){r(n)?void 0:o("120");var i=n.getPublicInstance();i&&i.refs[t]===e.getPublicInstance()&&n.detachRef(t)}});e.exports=i},function(e,t){"use strict";var n="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";e.exports=n},function(e,t,n){"use strict";function r(e){this.reinitializeTransaction(),this.renderToStaticMarkup=!1,this.reactMountReady=i.getPooled(null),this.useCreateElement=e}var o=n(10),i=n(237),a=n(59),u=n(105),s=n(244),c=(n(31),n(107)),l=n(166),f={initialize:s.getSelectionInformation,close:s.restoreSelection},p={initialize:function(){var e=u.isEnabled();return u.setEnabled(!1),e},close:function(e){u.setEnabled(e)}},d={initialize:function(){this.reactMountReady.reset()},close:function(){this.reactMountReady.notifyAll()}},h=[f,p,d],v={getTransactionWrappers:function(){return h},getReactMountReady:function(){return this.reactMountReady},getUpdateQueue:function(){return l},checkpoint:function(){return this.reactMountReady.checkpoint()},rollback:function(e){this.reactMountReady.rollback(e)},destructor:function(){i.release(this.reactMountReady),this.reactMountReady=null}};o(r.prototype,c,v),a.addPoolingTo(r),e.exports=r},function(e,t,n){"use strict";function r(e,t,n){"function"==typeof e?e(t.getPublicInstance()):i.addComponentAsRefTo(t,e,n)}function o(e,t,n){"function"==typeof e?e(null):i.removeComponentAsRefFrom(t,e,n)}var i=n(618),a={};a.attachRefs=function(e,t){if(null!==t&&"object"==typeof t){var n=t.ref;null!=n&&r(n,e,t._owner)}},a.shouldUpdateRefs=function(e,t){var n=null,r=null;null!==e&&"object"==typeof e&&(n=e.ref,r=e._owner);var o=null,i=null;return null!==t&&"object"==typeof t&&(o=t.ref,i=t._owner),n!==o||"string"==typeof o&&i!==r},a.detachRefs=function(e,t){if(null!==t&&"object"==typeof t){var n=t.ref;null!=n&&o(n,e,t._owner)}},e.exports=a},function(e,t,n){"use strict";function r(e){this.reinitializeTransaction(),this.renderToStaticMarkup=e,this.useCreateElement=!1,this.updateQueue=new u(this)}var o=n(10),i=n(59),a=n(107),u=(n(31),n(623)),s=[],c={enqueue:function(){}},l={getTransactionWrappers:function(){return s},getReactMountReady:function(){return c},getUpdateQueue:function(){return this.updateQueue},destructor:function(){},checkpoint:function(){},rollback:function(){}};o(r.prototype,a,l),i.addPoolingTo(r),e.exports=r},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t){}var i=n(166),a=(n(5),function(){function e(t){r(this,e),this.transaction=t}return e.prototype.isMounted=function(e){return!1},e.prototype.enqueueCallback=function(e,t,n){this.transaction.isInTransaction()&&i.enqueueCallback(e,t,n)},e.prototype.enqueueForceUpdate=function(e){this.transaction.isInTransaction()?i.enqueueForceUpdate(e):o(e,"forceUpdate")},e.prototype.enqueueReplaceState=function(e,t){this.transaction.isInTransaction()?i.enqueueReplaceState(e,t):o(e,"replaceState")},e.prototype.enqueueSetState=function(e,t){this.transaction.isInTransaction()?i.enqueueSetState(e,t):o(e,"setState")},e}());e.exports=a},function(e,t){"use strict";e.exports="15.4.1"},function(e,t){"use strict";var n={xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace"},r={accentHeight:"accent-height",accumulate:0,additive:0,alignmentBaseline:"alignment-baseline",allowReorder:"allowReorder",alphabetic:0,amplitude:0,arabicForm:"arabic-form",ascent:0,attributeName:"attributeName",attributeType:"attributeType",autoReverse:"autoReverse",azimuth:0,baseFrequency:"baseFrequency",baseProfile:"baseProfile",baselineShift:"baseline-shift",bbox:0,begin:0,bias:0,by:0,calcMode:"calcMode",capHeight:"cap-height",clip:0,clipPath:"clip-path",clipRule:"clip-rule",clipPathUnits:"clipPathUnits",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",contentScriptType:"contentScriptType",contentStyleType:"contentStyleType",cursor:0,cx:0,cy:0,d:0,decelerate:0,descent:0,diffuseConstant:"diffuseConstant",direction:0,display:0,divisor:0,dominantBaseline:"dominant-baseline",dur:0,dx:0,dy:0,edgeMode:"edgeMode",elevation:0,enableBackground:"enable-background",end:0,exponent:0,externalResourcesRequired:"externalResourcesRequired",fill:0,fillOpacity:"fill-opacity",fillRule:"fill-rule",filter:0,filterRes:"filterRes",filterUnits:"filterUnits",floodColor:"flood-color",floodOpacity:"flood-opacity",focusable:0,fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",format:0,from:0,fx:0,fy:0,g1:0,g2:0,glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",glyphRef:"glyphRef",gradientTransform:"gradientTransform",gradientUnits:"gradientUnits",hanging:0,horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",ideographic:0,imageRendering:"image-rendering",in:0,in2:0,intercept:0,k:0,k1:0,k2:0,k3:0,k4:0,kernelMatrix:"kernelMatrix",kernelUnitLength:"kernelUnitLength",kerning:0,keyPoints:"keyPoints",keySplines:"keySplines",keyTimes:"keyTimes",lengthAdjust:"lengthAdjust",letterSpacing:"letter-spacing",lightingColor:"lighting-color",limitingConeAngle:"limitingConeAngle",local:0,markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",markerHeight:"markerHeight",markerUnits:"markerUnits",markerWidth:"markerWidth",mask:0,maskContentUnits:"maskContentUnits",maskUnits:"maskUnits",mathematical:0,mode:0,numOctaves:"numOctaves",offset:0,opacity:0,operator:0,order:0,orient:0,orientation:0,origin:0,overflow:0,overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pathLength:"pathLength",patternContentUnits:"patternContentUnits",patternTransform:"patternTransform",patternUnits:"patternUnits",pointerEvents:"pointer-events",points:0,pointsAtX:"pointsAtX",pointsAtY:"pointsAtY",pointsAtZ:"pointsAtZ",preserveAlpha:"preserveAlpha",preserveAspectRatio:"preserveAspectRatio",primitiveUnits:"primitiveUnits",r:0,radius:0,refX:"refX",refY:"refY",renderingIntent:"rendering-intent",repeatCount:"repeatCount",repeatDur:"repeatDur",requiredExtensions:"requiredExtensions",requiredFeatures:"requiredFeatures",restart:0,result:0,rotate:0,rx:0,ry:0,scale:0,seed:0,shapeRendering:"shape-rendering",slope:0,spacing:0,specularConstant:"specularConstant",specularExponent:"specularExponent",speed:0,spreadMethod:"spreadMethod",startOffset:"startOffset",stdDeviation:"stdDeviation",stemh:0,stemv:0,stitchTiles:"stitchTiles",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",string:0,stroke:0,strokeDasharray:"stroke-dasharray",strokeDashoffset:"stroke-dashoffset",strokeLinecap:"stroke-linecap",strokeLinejoin:"stroke-linejoin",strokeMiterlimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",surfaceScale:"surfaceScale",systemLanguage:"systemLanguage",tableValues:"tableValues",targetX:"targetX",targetY:"targetY",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",textLength:"textLength",to:0,transform:0,u1:0,u2:0,underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicode:0,unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",values:0,vectorEffect:"vector-effect",version:0,vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",viewBox:"viewBox",viewTarget:"viewTarget",visibility:0,widths:0,wordSpacing:"word-spacing",writingMode:"writing-mode",x:0,xHeight:"x-height",x1:0,x2:0,xChannelSelector:"xChannelSelector",xlinkActuate:"xlink:actuate",xlinkArcrole:"xlink:arcrole",xlinkHref:"xlink:href",xlinkRole:"xlink:role",xlinkShow:"xlink:show",xlinkTitle:"xlink:title",xlinkType:"xlink:type",xmlBase:"xml:base",xmlns:0,xmlnsXlink:"xmlns:xlink",xmlLang:"xml:lang",xmlSpace:"xml:space",y:0,y1:0,y2:0,yChannelSelector:"yChannelSelector",z:0,zoomAndPan:"zoomAndPan"},o={Properties:{},DOMAttributeNamespaces:{xlinkActuate:n.xlink,xlinkArcrole:n.xlink,xlinkHref:n.xlink,xlinkRole:n.xlink,xlinkShow:n.xlink,xlinkTitle:n.xlink,xlinkType:n.xlink,xmlBase:n.xml,xmlLang:n.xml,xmlSpace:n.xml},DOMAttributeNames:{}};Object.keys(r).forEach(function(e){o.Properties[e]=0,r[e]&&(o.DOMAttributeNames[e]=r[e])}),e.exports=o},function(e,t,n){"use strict";function r(e){if("selectionStart"in e&&s.hasSelectionCapabilities(e))return{start:e.selectionStart,end:e.selectionEnd};if(window.getSelection){var t=window.getSelection();return{anchorNode:t.anchorNode,anchorOffset:t.anchorOffset,focusNode:t.focusNode,focusOffset:t.focusOffset}}if(document.selection){var n=document.selection.createRange();return{parentElement:n.parentElement(),text:n.text,top:n.boundingTop,left:n.boundingLeft}}}function o(e,t){if(g||null==v||v!==l())return null;var n=r(v);if(!y||!p(y,n)){y=n;var o=c.getPooled(h.select,m,e,t);return o.type="select",o.target=v,i.accumulateTwoPhaseDispatches(o),o}return null}var i=n(82),a=n(18),u=n(13),s=n(244),c=n(41),l=n(210),f=n(253),p=n(141),d=a.canUseDOM&&"documentMode"in document&&document.documentMode<=11,h={select:{phasedRegistrationNames:{bubbled:"onSelect",captured:"onSelectCapture"},dependencies:["topBlur","topContextMenu","topFocus","topKeyDown","topKeyUp","topMouseDown","topMouseUp","topSelectionChange"]}},v=null,m=null,y=null,g=!1,b=!1,_={eventTypes:h,extractEvents:function(e,t,n,r){if(!b)return null;var i=t?u.getNodeFromInstance(t):window;switch(e){case"topFocus":(f(i)||"true"===i.contentEditable)&&(v=i,m=t,y=null);break;case"topBlur":v=null,m=null,y=null;break;case"topMouseDown":g=!0;break;case"topContextMenu":case"topMouseUp":return g=!1,o(n,r);case"topSelectionChange":if(d)break;case"topKeyDown":case"topKeyUp":return o(n,r)}return null},didPutListener:function(e,t,n){"onSelect"===t&&(b=!0)}};e.exports=_},function(e,t,n){"use strict";function r(e){return"."+e._rootNodeID}function o(e){return"button"===e||"input"===e||"select"===e||"textarea"===e}var i=n(7),a=n(208),u=n(82),s=n(13),c=n(628),l=n(629),f=n(41),p=n(632),d=n(634),h=n(106),v=n(631),m=n(635),y=n(636),g=n(84),b=n(637),_=n(29),x=n(168),E=(n(2),{}),w={};["abort","animationEnd","animationIteration","animationStart","blur","canPlay","canPlayThrough","click","contextMenu","copy","cut","doubleClick","drag","dragEnd","dragEnter","dragExit","dragLeave","dragOver","dragStart","drop","durationChange","emptied","encrypted","ended","error","focus","input","invalid","keyDown","keyPress","keyUp","load","loadedData","loadedMetadata","loadStart","mouseDown","mouseMove","mouseOut","mouseOver","mouseUp","paste","pause","play","playing","progress","rateChange","reset","scroll","seeked","seeking","stalled","submit","suspend","timeUpdate","touchCancel","touchEnd","touchMove","touchStart","transitionEnd","volumeChange","waiting","wheel"].forEach(function(e){var t=e[0].toUpperCase()+e.slice(1),n="on"+t,r="top"+t,o={phasedRegistrationNames:{bubbled:n,captured:n+"Capture"},dependencies:[r]};E[e]=o,w[r]=o});var S={},C={eventTypes:E,extractEvents:function(e,t,n,r){var o=w[e];if(!o)return null;var a;switch(e){case"topAbort":case"topCanPlay":case"topCanPlayThrough":case"topDurationChange":case"topEmptied":case"topEncrypted":case"topEnded":case"topError":case"topInput":case"topInvalid":case"topLoad":case"topLoadedData":case"topLoadedMetadata":case"topLoadStart":case"topPause":case"topPlay":case"topPlaying":case"topProgress":case"topRateChange":case"topReset":case"topSeeked":case"topSeeking":case"topStalled":case"topSubmit":case"topSuspend":case"topTimeUpdate":case"topVolumeChange":case"topWaiting":a=f;break;case"topKeyPress":if(0===x(n))return null;case"topKeyDown":case"topKeyUp":a=d;break;case"topBlur":case"topFocus":a=p;break;case"topClick":if(2===n.button)return null;case"topDoubleClick":case"topMouseDown":case"topMouseMove":case"topMouseUp":case"topMouseOut":case"topMouseOver":case"topContextMenu":a=h;break;case"topDrag":case"topDragEnd":case"topDragEnter":case"topDragExit":case"topDragLeave":case"topDragOver":case"topDragStart":case"topDrop":a=v;break;case"topTouchCancel":case"topTouchEnd":case"topTouchMove":case"topTouchStart":a=m;break;case"topAnimationEnd":case"topAnimationIteration":case"topAnimationStart":a=c;break;case"topTransitionEnd":a=y;break;case"topScroll":a=g;break;case"topWheel":a=b;break;case"topCopy":case"topCut":case"topPaste":a=l}a?void 0:i("86",e);var s=a.getPooled(o,t,n,r);return u.accumulateTwoPhaseDispatches(s),s},didPutListener:function(e,t,n){if("onClick"===t&&!o(e._tag)){var i=r(e),u=s.getNodeFromInstance(e);S[i]||(S[i]=a.listen(u,"click",_))}},willDeleteListener:function(e,t){if("onClick"===t&&!o(e._tag)){var n=r(e);S[n].remove(),delete S[n]}}};e.exports=C},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(41),i={animationName:null,elapsedTime:null,pseudoElement:null};o.augmentClass(r,i),e.exports=r},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(41),i={clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}};o.augmentClass(r,i),e.exports=r},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(41),i={data:null};o.augmentClass(r,i),e.exports=r},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(106),i={dataTransfer:null};o.augmentClass(r,i),e.exports=r},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(84),i={relatedTarget:null};o.augmentClass(r,i),e.exports=r},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(41),i={data:null};o.augmentClass(r,i),e.exports=r},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(84),i=n(168),a=n(642),u=n(169),s={key:a,location:null,ctrlKey:null,shiftKey:null,altKey:null,metaKey:null,repeat:null,locale:null,getModifierState:u,charCode:function(e){return"keypress"===e.type?i(e):0},keyCode:function(e){return"keydown"===e.type||"keyup"===e.type?e.keyCode:0},which:function(e){return"keypress"===e.type?i(e):"keydown"===e.type||"keyup"===e.type?e.keyCode:0}};o.augmentClass(r,s),e.exports=r},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(84),i=n(169),a={touches:null,targetTouches:null,changedTouches:null,altKey:null,metaKey:null,ctrlKey:null,shiftKey:null,getModifierState:i};o.augmentClass(r,a),e.exports=r},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(41),i={propertyName:null,elapsedTime:null,pseudoElement:null};o.augmentClass(r,i),e.exports=r},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(106),i={deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:null,deltaMode:null};o.augmentClass(r,i),e.exports=r},function(e,t){"use strict";function n(e){for(var t=1,n=0,o=0,i=e.length,a=i&-4;o<a;){for(var u=Math.min(o+4096,a);o<u;o+=4)n+=(t+=e.charCodeAt(o))+(t+=e.charCodeAt(o+1))+(t+=e.charCodeAt(o+2))+(t+=e.charCodeAt(o+3));t%=r,n%=r}for(;o<i;o++)n+=t+=e.charCodeAt(o);return t%=r,n%=r,t|n<<16}var r=65521;e.exports=n},function(e,t,n){"use strict";function r(e,t,n){var r=null==t||"boolean"==typeof t||""===t;if(r)return"";var o=isNaN(t);if(o||0===t||i.hasOwnProperty(e)&&i[e])return""+t;if("string"==typeof t){t=t.trim()}return t+"px"}var o=n(236),i=(n(5),o.isUnitlessNumber);e.exports=r},function(e,t,n){"use strict";function r(e){if(null==e)return null;if(1===e.nodeType)return e;var t=a.get(e);return t?(t=u(t),t?i.getNodeFromInstance(t):null):void("function"==typeof e.render?o("44"):o("45",Object.keys(e)))}var o=n(7),i=(n(42),n(13)),a=n(83),u=n(250);n(2),n(5);e.exports=r},function(e,t,n){(function(t){"use strict";function r(e,t,n,r){if(e&&"object"==typeof e){var o=e,i=void 0===o[n];i&&null!=t&&(o[n]=t)}}function o(e,t){if(null==e)return e;var n={};return i(e,r,n),n}var i=(n(162),n(255));n(5);e.exports=o}).call(t,n(157))},function(e,t,n){"use strict";function r(e){if(e.key){var t=i[e.key]||e.key;if("Unidentified"!==t)return t}if("keypress"===e.type){var n=o(e);return 13===n?"Enter":String.fromCharCode(n)}return"keydown"===e.type||"keyup"===e.type?a[e.keyCode]||"Unidentified":""}var o=n(168),i={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified" },a={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",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",224:"Meta"};e.exports=r},function(e,t){"use strict";function n(e){var t=e&&(r&&e[r]||e[o]);if("function"==typeof t)return t}var r="function"==typeof Symbol&&Symbol.iterator,o="@@iterator";e.exports=n},function(e,t){"use strict";function n(){return r++}var r=1;e.exports=n},function(e,t){"use strict";function n(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function r(e){for(;e;){if(e.nextSibling)return e.nextSibling;e=e.parentNode}}function o(e,t){for(var o=n(e),i=0,a=0;o;){if(3===o.nodeType){if(a=i+o.textContent.length,i<=t&&a>=t)return{node:o,offset:t-i};i=a}o=n(r(o))}}e.exports=o},function(e,t,n){"use strict";function r(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n["ms"+e]="MS"+t,n["O"+e]="o"+t.toLowerCase(),n}function o(e){if(u[e])return u[e];if(!a[e])return e;var t=a[e];for(var n in t)if(t.hasOwnProperty(n)&&n in s)return u[e]=t[n];return""}var i=n(18),a={animationend:r("Animation","AnimationEnd"),animationiteration:r("Animation","AnimationIteration"),animationstart:r("Animation","AnimationStart"),transitionend:r("Transition","TransitionEnd")},u={},s={};i.canUseDOM&&(s=document.createElement("div").style,"AnimationEvent"in window||(delete a.animationend.animation,delete a.animationiteration.animation,delete a.animationstart.animation),"TransitionEvent"in window||delete a.transitionend.transition),e.exports=o},function(e,t,n){"use strict";function r(e){return'"'+o(e)+'"'}var o=n(108);e.exports=r},function(e,t,n){"use strict";var r=n(245);e.exports=r.renderSubtreeIntoContainer},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0,t.default=void 0;var u=n(14),s=n(256),c=r(s),l=n(257),f=(r(l),function(e){function t(n,r){o(this,t);var a=i(this,e.call(this,n,r));return a.store=n.store,a}return a(t,e),t.prototype.getChildContext=function(){return{store:this.store}},t.prototype.render=function(){return u.Children.only(this.props.children)},t}(u.Component));t.default=f,f.propTypes={store:c.default.isRequired,children:u.PropTypes.element.isRequired},f.childContextTypes={store:c.default.isRequired}},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function u(e){return e.displayName||e.name||"Component"}function s(e,t){try{return e.apply(t)}catch(e){return O.value=e,O}}function c(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},c=Boolean(e),p=e||S,h=void 0;h="function"==typeof t?t:t?(0,y.default)(t):C;var m=n||P,g=r.pure,b=void 0===g||g,_=r.withRef,E=void 0!==_&&_,k=b&&m!==P,A=T++;return function(e){function t(e,t,n){var r=m(e,t,n);return r}var n="Connect("+u(e)+")",r=function(r){function u(e,t){o(this,u);var a=i(this,r.call(this,e,t));a.version=A,a.store=e.store||t.store,(0,w.default)(a.store,'Could not find "store" in either the context or '+('props of "'+n+'". ')+"Either wrap the root component in a <Provider>, "+('or explicitly pass "store" as a prop to "'+n+'".'));var s=a.store.getState();return a.state={storeState:s},a.clearCache(),a}return a(u,r),u.prototype.shouldComponentUpdate=function(){return!b||this.haveOwnPropsChanged||this.hasStoreStateChanged},u.prototype.computeStateProps=function(e,t){if(!this.finalMapStateToProps)return this.configureFinalMapState(e,t);var n=e.getState(),r=this.doStatePropsDependOnOwnProps?this.finalMapStateToProps(n,t):this.finalMapStateToProps(n);return r},u.prototype.configureFinalMapState=function(e,t){var n=p(e.getState(),t),r="function"==typeof n;return this.finalMapStateToProps=r?n:p,this.doStatePropsDependOnOwnProps=1!==this.finalMapStateToProps.length,r?this.computeStateProps(e,t):n},u.prototype.computeDispatchProps=function(e,t){if(!this.finalMapDispatchToProps)return this.configureFinalMapDispatch(e,t);var n=e.dispatch,r=this.doDispatchPropsDependOnOwnProps?this.finalMapDispatchToProps(n,t):this.finalMapDispatchToProps(n);return r},u.prototype.configureFinalMapDispatch=function(e,t){var n=h(e.dispatch,t),r="function"==typeof n;return this.finalMapDispatchToProps=r?n:h,this.doDispatchPropsDependOnOwnProps=1!==this.finalMapDispatchToProps.length,r?this.computeDispatchProps(e,t):n},u.prototype.updateStatePropsIfNeeded=function(){var e=this.computeStateProps(this.store,this.props);return(!this.stateProps||!(0,v.default)(e,this.stateProps))&&(this.stateProps=e,!0)},u.prototype.updateDispatchPropsIfNeeded=function(){var e=this.computeDispatchProps(this.store,this.props);return(!this.dispatchProps||!(0,v.default)(e,this.dispatchProps))&&(this.dispatchProps=e,!0)},u.prototype.updateMergedPropsIfNeeded=function(){var e=t(this.stateProps,this.dispatchProps,this.props);return!(this.mergedProps&&k&&(0,v.default)(e,this.mergedProps))&&(this.mergedProps=e,!0)},u.prototype.isSubscribed=function(){return"function"==typeof this.unsubscribe},u.prototype.trySubscribe=function(){c&&!this.unsubscribe&&(this.unsubscribe=this.store.subscribe(this.handleChange.bind(this)),this.handleChange())},u.prototype.tryUnsubscribe=function(){this.unsubscribe&&(this.unsubscribe(),this.unsubscribe=null)},u.prototype.componentDidMount=function(){this.trySubscribe()},u.prototype.componentWillReceiveProps=function(e){b&&(0,v.default)(e,this.props)||(this.haveOwnPropsChanged=!0)},u.prototype.componentWillUnmount=function(){this.tryUnsubscribe(),this.clearCache()},u.prototype.clearCache=function(){this.dispatchProps=null,this.stateProps=null,this.mergedProps=null,this.haveOwnPropsChanged=!0,this.hasStoreStateChanged=!0,this.haveStatePropsBeenPrecalculated=!1,this.statePropsPrecalculationError=null,this.renderedElement=null,this.finalMapDispatchToProps=null,this.finalMapStateToProps=null},u.prototype.handleChange=function(){if(this.unsubscribe){var e=this.store.getState(),t=this.state.storeState;if(!b||t!==e){if(b&&!this.doStatePropsDependOnOwnProps){var n=s(this.updateStatePropsIfNeeded,this);if(!n)return;n===O&&(this.statePropsPrecalculationError=O.value),this.haveStatePropsBeenPrecalculated=!0}this.hasStoreStateChanged=!0,this.setState({storeState:e})}}},u.prototype.getWrappedInstance=function(){return(0,w.default)(E,"To access the wrapped instance, you need to specify { withRef: true } as the fourth argument of the connect() call."),this.refs.wrappedInstance},u.prototype.render=function(){var t=this.haveOwnPropsChanged,n=this.hasStoreStateChanged,r=this.haveStatePropsBeenPrecalculated,o=this.statePropsPrecalculationError,i=this.renderedElement;if(this.haveOwnPropsChanged=!1,this.hasStoreStateChanged=!1,this.haveStatePropsBeenPrecalculated=!1,this.statePropsPrecalculationError=null,o)throw o;var a=!0,u=!0;b&&i&&(a=n||t&&this.doStatePropsDependOnOwnProps,u=t&&this.doDispatchPropsDependOnOwnProps);var s=!1,c=!1;r?s=!0:a&&(s=this.updateStatePropsIfNeeded()),u&&(c=this.updateDispatchPropsIfNeeded());var p=!0;return p=!!(s||c||t)&&this.updateMergedPropsIfNeeded(),!p&&i?i:(E?this.renderedElement=(0,f.createElement)(e,l({},this.mergedProps,{ref:"wrappedInstance"})):this.renderedElement=(0,f.createElement)(e,this.mergedProps),this.renderedElement)},u}(f.Component);return r.displayName=n,r.WrappedComponent=e,r.contextTypes={store:d.default},r.propTypes={store:d.default},(0,x.default)(r,e)}}t.__esModule=!0;var l=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e};t.default=c;var f=n(14),p=n(256),d=r(p),h=n(651),v=r(h),m=n(652),y=r(m),g=n(257),b=(r(g),n(102)),_=(r(b),n(211)),x=r(_),E=n(77),w=r(E),S=function(e){return{}},C=function(e){return{dispatch:e}},P=function(e,t,n){return l({},n,e,t)},O={value:null},T=0},function(e,t){"use strict";function n(e,t){if(e===t)return!0;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(var o=Object.prototype.hasOwnProperty,i=0;i<n.length;i++)if(!o.call(t,n[i])||e[n[i]]!==t[n[i]])return!1;return!0}t.__esModule=!0,t.default=n},function(e,t,n){"use strict";function r(e){return function(t){return(0,o.bindActionCreators)(e,t)}}t.__esModule=!0,t.default=r;var o=n(112)},function(e,t){"use strict";function n(e){var t=/[=:]/g,n={"=":"=0",":":"=2"},r=(""+e).replace(t,function(e){return n[e]});return"$"+r}function r(e){var t=/(=0|=2)/g,n={"=0":"=","=2":":"},r="."===e[0]&&"$"===e[1]?e.substring(2):e.substring(1);return(""+r).replace(t,function(e){return n[e]})}var o={escape:n,unescape:r};e.exports=o},function(e,t,n){"use strict";var r=n(72),o=(n(2),function(e){var t=this;if(t.instancePool.length){var n=t.instancePool.pop();return t.call(n,e),n}return new t(e)}),i=function(e,t){var n=this;if(n.instancePool.length){var r=n.instancePool.pop();return n.call(r,e,t),r}return new n(e,t)},a=function(e,t,n){var r=this;if(r.instancePool.length){var o=r.instancePool.pop();return r.call(o,e,t,n),o}return new r(e,t,n)},u=function(e,t,n,r){var o=this;if(o.instancePool.length){var i=o.instancePool.pop();return o.call(i,e,t,n,r),i}return new o(e,t,n,r)},s=function(e,t,n,r,o){var i=this;if(i.instancePool.length){var a=i.instancePool.pop();return i.call(a,e,t,n,r,o),a}return new i(e,t,n,r,o)},c=function(e){var t=this;e instanceof t?void 0:r("25"),e.destructor(),t.instancePool.length<t.poolSize&&t.instancePool.push(e)},l=10,f=o,p=function(e,t){var n=e;return n.instancePool=[],n.getPooled=t||f,n.poolSize||(n.poolSize=l),n.release=c,n},d={addPoolingTo:p,oneArgumentPooler:o,twoArgumentPooler:i,threeArgumentPooler:a,fourArgumentPooler:u,fiveArgumentPooler:s};e.exports=d},function(e,t,n){"use strict";function r(e){return(""+e).replace(_,"$&/")}function o(e,t){this.func=e,this.context=t,this.count=0}function i(e,t,n){var r=e.func,o=e.context;r.call(o,t,e.count++)}function a(e,t,n){if(null==e)return e;var r=o.getPooled(t,n);y(e,i,r),o.release(r)}function u(e,t,n,r){this.result=e,this.keyPrefix=t,this.func=n,this.context=r,this.count=0}function s(e,t,n){var o=e.result,i=e.keyPrefix,a=e.func,u=e.context,s=a.call(u,t,e.count++);Array.isArray(s)?c(s,o,n,m.thatReturnsArgument):null!=s&&(v.isValidElement(s)&&(s=v.cloneAndReplaceKey(s,i+(!s.key||t&&t.key===s.key?"":r(s.key)+"/")+n)),o.push(s))}function c(e,t,n,o,i){var a="";null!=n&&(a=r(n)+"/");var c=u.getPooled(t,a,o,i);y(e,s,c),u.release(c)}function l(e,t,n){if(null==e)return e;var r=[];return c(e,r,null,t,n),r}function f(e,t,n){return null}function p(e,t){return y(e,f,null)}function d(e){var t=[];return c(e,t,null,m.thatReturnsArgument),t}var h=n(654),v=n(71),m=n(29),y=n(663),g=h.twoArgumentPooler,b=h.fourArgumentPooler,_=/\/+/g;o.prototype.destructor=function(){this.func=null,this.context=null,this.count=0},h.addPoolingTo(o,g),u.prototype.destructor=function(){this.result=null,this.keyPrefix=null,this.func=null,this.context=null,this.count=0},h.addPoolingTo(u,b);var x={forEach:a,map:l,mapIntoWithKeyPrefixInternal:c,count:p,toArray:d};e.exports=x},function(e,t,n){"use strict";function r(e){return e}function o(e,t){var n=_.hasOwnProperty(t)?_[t]:null;E.hasOwnProperty(t)&&("OVERRIDE_BASE"!==n?p("73",t):void 0),e&&("DEFINE_MANY"!==n&&"DEFINE_MANY_MERGED"!==n?p("74",t):void 0)}function i(e,t){if(t){"function"==typeof t?p("75"):void 0,v.isValidElement(t)?p("76"):void 0;var n=e.prototype,r=n.__reactAutoBindPairs;t.hasOwnProperty(g)&&x.mixins(e,t.mixins);for(var i in t)if(t.hasOwnProperty(i)&&i!==g){var a=t[i],u=n.hasOwnProperty(i);if(o(u,i),x.hasOwnProperty(i))x[i](e,a);else{var l=_.hasOwnProperty(i),f="function"==typeof a,d=f&&!l&&!u&&t.autobind!==!1;if(d)r.push(i,a),n[i]=a;else if(u){var h=_[i];!l||"DEFINE_MANY_MERGED"!==h&&"DEFINE_MANY"!==h?p("77",h,i):void 0,"DEFINE_MANY_MERGED"===h?n[i]=s(n[i],a):"DEFINE_MANY"===h&&(n[i]=c(n[i],a))}else n[i]=a}}}else;}function a(e,t){if(t)for(var n in t){var r=t[n];if(t.hasOwnProperty(n)){var o=n in x;o?p("78",n):void 0;var i=n in e;i?p("79",n):void 0,e[n]=r}}}function u(e,t){e&&t&&"object"==typeof e&&"object"==typeof t?void 0:p("80");for(var n in t)t.hasOwnProperty(n)&&(void 0!==e[n]?p("81",n):void 0,e[n]=t[n]);return e}function s(e,t){return function(){var n=e.apply(this,arguments),r=t.apply(this,arguments);if(null==n)return r;if(null==r)return n;var o={};return u(o,n),u(o,r),o}}function c(e,t){return function(){e.apply(this,arguments),t.apply(this,arguments)}}function l(e,t){var n=t.bind(e);return n}function f(e){for(var t=e.__reactAutoBindPairs,n=0;n<t.length;n+=2){var r=t[n],o=t[n+1];e[r]=l(e,o)}}var p=n(72),d=n(10),h=n(174),v=n(71),m=(n(260),n(175)),y=n(76),g=(n(2),n(5),"mixins"),b=[],_={mixins:"DEFINE_MANY",statics:"DEFINE_MANY",propTypes:"DEFINE_MANY",contextTypes:"DEFINE_MANY",childContextTypes:"DEFINE_MANY",getDefaultProps:"DEFINE_MANY_MERGED",getInitialState:"DEFINE_MANY_MERGED",getChildContext:"DEFINE_MANY_MERGED",render:"DEFINE_ONCE",componentWillMount:"DEFINE_MANY",componentDidMount:"DEFINE_MANY",componentWillReceiveProps:"DEFINE_MANY",shouldComponentUpdate:"DEFINE_ONCE",componentWillUpdate:"DEFINE_MANY",componentDidUpdate:"DEFINE_MANY",componentWillUnmount:"DEFINE_MANY",updateComponent:"OVERRIDE_BASE"},x={displayName:function(e,t){e.displayName=t},mixins:function(e,t){if(t)for(var n=0;n<t.length;n++)i(e,t[n])},childContextTypes:function(e,t){e.childContextTypes=d({},e.childContextTypes,t)},contextTypes:function(e,t){e.contextTypes=d({},e.contextTypes,t)},getDefaultProps:function(e,t){e.getDefaultProps?e.getDefaultProps=s(e.getDefaultProps,t):e.getDefaultProps=t},propTypes:function(e,t){e.propTypes=d({},e.propTypes,t)},statics:function(e,t){a(e,t)},autobind:function(){}},E={replaceState:function(e,t){this.updater.enqueueReplaceState(this,e),t&&this.updater.enqueueCallback(this,t,"replaceState")},isMounted:function(){return this.updater.isMounted(this)}},w=function(){};d(w.prototype,h.prototype,E);var S={createClass:function(e){var t=r(function(e,n,r){this.__reactAutoBindPairs.length&&f(this),this.props=e,this.context=n,this.refs=y,this.updater=r||m,this.state=null;var o=this.getInitialState?this.getInitialState():null;"object"!=typeof o||Array.isArray(o)?p("82",t.displayName||"ReactCompositeComponent"):void 0,this.state=o});t.prototype=new w,t.prototype.constructor=t,t.prototype.__reactAutoBindPairs=[],b.forEach(i.bind(null,t)),i(t,e),t.getDefaultProps&&(t.defaultProps=t.getDefaultProps()),t.prototype.render?void 0:p("83");for(var n in _)t.prototype[n]||(t.prototype[n]=null);return t},injection:{injectMixin:function(e){b.push(e)}}};e.exports=S},function(e,t,n){"use strict";var r=n(71),o=r.createFactory,i={a:o("a"),abbr:o("abbr"),address:o("address"),area:o("area"),article:o("article"),aside:o("aside"),audio:o("audio"),b:o("b"),base:o("base"),bdi:o("bdi"),bdo:o("bdo"),big:o("big"),blockquote:o("blockquote"),body:o("body"),br:o("br"),button:o("button"),canvas:o("canvas"),caption:o("caption"),cite:o("cite"),code:o("code"),col:o("col"),colgroup:o("colgroup"),data:o("data"),datalist:o("datalist"),dd:o("dd"),del:o("del"),details:o("details"),dfn:o("dfn"),dialog:o("dialog"),div:o("div"),dl:o("dl"),dt:o("dt"),em:o("em"),embed:o("embed"),fieldset:o("fieldset"),figcaption:o("figcaption"),figure:o("figure"),footer:o("footer"),form:o("form"),h1:o("h1"),h2:o("h2"),h3:o("h3"),h4:o("h4"),h5:o("h5"),h6:o("h6"),head:o("head"),header:o("header"),hgroup:o("hgroup"),hr:o("hr"),html:o("html"),i:o("i"),iframe:o("iframe"),img:o("img"),input:o("input"),ins:o("ins"),kbd:o("kbd"),keygen:o("keygen"),label:o("label"),legend:o("legend"),li:o("li"),link:o("link"),main:o("main"),map:o("map"),mark:o("mark"),menu:o("menu"),menuitem:o("menuitem"),meta:o("meta"),meter:o("meter"),nav:o("nav"),noscript:o("noscript"),object:o("object"),ol:o("ol"),optgroup:o("optgroup"),option:o("option"),output:o("output"),p:o("p"),param:o("param"),picture:o("picture"),pre:o("pre"),progress:o("progress"),q:o("q"),rp:o("rp"),rt:o("rt"),ruby:o("ruby"),s:o("s"),samp:o("samp"),script:o("script"),section:o("section"),select:o("select"),small:o("small"),source:o("source"),span:o("span"),strong:o("strong"),style:o("style"),sub:o("sub"),summary:o("summary"),sup:o("sup"),table:o("table"),tbody:o("tbody"),td:o("td"),textarea:o("textarea"),tfoot:o("tfoot"),th:o("th"),thead:o("thead"),time:o("time"),title:o("title"),tr:o("tr"),track:o("track"),u:o("u"),ul:o("ul"),var:o("var"),video:o("video"),wbr:o("wbr"),circle:o("circle"),clipPath:o("clipPath"),defs:o("defs"),ellipse:o("ellipse"),g:o("g"),image:o("image"),line:o("line"),linearGradient:o("linearGradient"),mask:o("mask"),path:o("path"),pattern:o("pattern"),polygon:o("polygon"),polyline:o("polyline"),radialGradient:o("radialGradient"),rect:o("rect"),stop:o("stop"),svg:o("svg"),text:o("text"),tspan:o("tspan")};e.exports=i},function(e,t,n){"use strict";function r(e,t){return e===t?0!==e||1/e===1/t:e!==e&&t!==t}function o(e){this.message=e,this.stack=""}function i(e){function t(t,n,r,i,a,u,s){i=i||P,u=u||r;if(null==n[r]){var c=E[a];return t?new o(null===n[r]?"The "+c+" `"+u+"` is marked as required "+("in `"+i+"`, but its value is `null`."):"The "+c+" `"+u+"` is marked as required in "+("`"+i+"`, but its value is `undefined`.")):null}return e(n,r,i,a,u)}var n=t.bind(null,!1);return n.isRequired=t.bind(null,!0),n}function a(e){function t(t,n,r,i,a,u){var s=t[n],c=g(s);if(c!==e){var l=E[i],f=b(s);return new o("Invalid "+l+" `"+a+"` of type "+("`"+f+"` supplied to `"+r+"`, expected ")+("`"+e+"`."))}return null}return i(t)}function u(){return i(S.thatReturns(null))}function s(e){function t(t,n,r,i,a){if("function"!=typeof e)return new o("Property `"+a+"` of component `"+r+"` has invalid PropType notation inside arrayOf.");var u=t[n];if(!Array.isArray(u)){var s=E[i],c=g(u);return new o("Invalid "+s+" `"+a+"` of type "+("`"+c+"` supplied to `"+r+"`, expected an array."))}for(var l=0;l<u.length;l++){var f=e(u,l,r,i,a+"["+l+"]",w);if(f instanceof Error)return f}return null}return i(t)}function c(){function e(e,t,n,r,i){var a=e[t];if(!x.isValidElement(a)){var u=E[r],s=g(a);return new o("Invalid "+u+" `"+i+"` of type "+("`"+s+"` supplied to `"+n+"`, expected a single ReactElement."))}return null}return i(e)}function l(e){function t(t,n,r,i,a){if(!(t[n]instanceof e)){var u=E[i],s=e.name||P,c=_(t[n]);return new o("Invalid "+u+" `"+a+"` of type "+("`"+c+"` supplied to `"+r+"`, expected ")+("instance of `"+s+"`."))}return null}return i(t)}function f(e){function t(t,n,i,a,u){for(var s=t[n],c=0;c<e.length;c++)if(r(s,e[c]))return null;var l=E[a],f=JSON.stringify(e);return new o("Invalid "+l+" `"+u+"` of value `"+s+"` "+("supplied to `"+i+"`, expected one of "+f+"."))}return Array.isArray(e)?i(t):S.thatReturnsNull}function p(e){function t(t,n,r,i,a){if("function"!=typeof e)return new o("Property `"+a+"` of component `"+r+"` has invalid PropType notation inside objectOf.");var u=t[n],s=g(u);if("object"!==s){var c=E[i];return new o("Invalid "+c+" `"+a+"` of type "+("`"+s+"` supplied to `"+r+"`, expected an object."))}for(var l in u)if(u.hasOwnProperty(l)){var f=e(u,l,r,i,a+"."+l,w);if(f instanceof Error)return f}return null}return i(t)}function d(e){function t(t,n,r,i,a){for(var u=0;u<e.length;u++){var s=e[u];if(null==s(t,n,r,i,a,w))return null}var c=E[i];return new o("Invalid "+c+" `"+a+"` supplied to "+("`"+r+"`."))}return Array.isArray(e)?i(t):S.thatReturnsNull}function h(){function e(e,t,n,r,i){if(!m(e[t])){var a=E[r];return new o("Invalid "+a+" `"+i+"` supplied to "+("`"+n+"`, expected a ReactNode."))}return null}return i(e)}function v(e){function t(t,n,r,i,a){var u=t[n],s=g(u);if("object"!==s){var c=E[i];return new o("Invalid "+c+" `"+a+"` of type `"+s+"` "+("supplied to `"+r+"`, expected `object`."))}for(var l in e){var f=e[l];if(f){var p=f(u,l,r,i,a+"."+l,w);if(p)return p}}return null}return i(t)}function m(e){switch(typeof e){case"number":case"string":case"undefined":return!0;case"boolean":return!e;case"object":if(Array.isArray(e))return e.every(m);if(null===e||x.isValidElement(e))return!0;var t=C(e);if(!t)return!1;var n,r=t.call(e);if(t!==e.entries){for(;!(n=r.next()).done;)if(!m(n.value))return!1}else for(;!(n=r.next()).done;){var o=n.value;if(o&&!m(o[1]))return!1}return!0;default:return!1}}function y(e,t){return"symbol"===e||("Symbol"===t["@@toStringTag"]||"function"==typeof Symbol&&t instanceof Symbol)}function g(e){var t=typeof e;return Array.isArray(e)?"array":e instanceof RegExp?"object":y(t,e)?"symbol":t}function b(e){var t=g(e);if("object"===t){if(e instanceof Date)return"date";if(e instanceof RegExp)return"regexp"}return t}function _(e){return e.constructor&&e.constructor.name?e.constructor.name:P}var x=n(71),E=n(260),w=n(659),S=n(29),C=n(262),P=(n(5),"<<anonymous>>"),O={array:a("array"),bool:a("boolean"),func:a("function"),number:a("number"),object:a("object"),string:a("string"),symbol:a("symbol"),any:u(),arrayOf:s,element:c(),instanceOf:l,node:h(),objectOf:p,oneOf:f,oneOfType:d,shape:v};o.prototype=Error.prototype,e.exports=O},function(e,t){"use strict";var n="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";e.exports=n},function(e,t,n){"use strict";function r(e,t,n){this.props=e,this.context=t,this.refs=s,this.updater=n||u}function o(){}var i=n(10),a=n(174),u=n(175),s=n(76);o.prototype=a.prototype,r.prototype=new o,r.prototype.constructor=r,i(r.prototype,a.prototype),r.prototype.isPureReactComponent=!0,e.exports=r},function(e,t){"use strict";e.exports="15.4.1"},function(e,t,n){"use strict";function r(e){return i.isValidElement(e)?void 0:o("143"),e}var o=n(72),i=n(71);n(2);e.exports=r},function(e,t,n){"use strict";function r(e,t){return e&&"object"==typeof e&&null!=e.key?c.escape(e.key):t.toString(36)}function o(e,t,n,i){var p=typeof e;if("undefined"!==p&&"boolean"!==p||(e=null),null===e||"string"===p||"number"===p||"object"===p&&e.$$typeof===u)return n(i,e,""===t?l+r(e,0):t),1;var d,h,v=0,m=""===t?l:t+f;if(Array.isArray(e))for(var y=0;y<e.length;y++)d=e[y],h=m+r(d,y),v+=o(d,h,n,i);else{var g=s(e);if(g){var b,_=g.call(e);if(g!==e.entries)for(var x=0;!(b=_.next()).done;)d=b.value,h=m+r(d,x++),v+=o(d,h,n,i);else for(;!(b=_.next()).done;){var E=b.value;E&&(d=E[1],h=m+c.escape(E[0])+f+r(d,0),v+=o(d,h,n,i))}}else if("object"===p){var w="",S=String(e);a("31","[object Object]"===S?"object with keys {"+Object.keys(e).join(", ")+"}":S,w)}}return v}function i(e,t,n){return null==e?0:o(e,"",t,n)}var a=n(72),u=(n(42),n(259)),s=n(262),c=(n(2),n(653)),l=(n(5),"."),f=":";e.exports=i},function(e,t,n){!function(t,r){e.exports=r(n(14))}(this,function(e){return function(e){function t(r){if(n[r])return n[r].exports;var o=n[r]={exports:{},id:r,loaded:!1};return e[r].call(o.exports,o,o.exports,t),o.loaded=!0,o.exports}var n={};return t.m=e,t.c=n,t.p="",t(0)}([function(e,t,n){n(177),e.exports=n(185)},function(e,t,n){"use strict";function r(e,t,n,r,o,i,a,u){if(!e){var s;if(void 0===t)s=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var c=[n,r,o,i,a,u],l=0;s=new Error(t.replace(/%s/g,function(){return c[l++]})),s.name="Invariant Violation"}throw s.framesToPop=1,s}}e.exports=r},function(e,t,n){"use strict";var r=n(9),o=r;e.exports=o},function(e,t){"use strict";function n(e){if(null===e||void 0===e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}function r(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;var r=Object.getOwnPropertyNames(t).map(function(e){return t[e]});if("0123456789"!==r.join(""))return!1;var o={};return"abcdefghijklmnopqrst".split("").forEach(function(e){o[e]=e}),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},o)).join("")}catch(e){return!1}}var o=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable;e.exports=r()?Object.assign:function(e,t){for(var r,a,u=n(e),s=1;s<arguments.length;s++){r=Object(arguments[s]);for(var c in r)o.call(r,c)&&(u[c]=r[c]);if(Object.getOwnPropertySymbols){a=Object.getOwnPropertySymbols(r);for(var l=0;l<a.length;l++)i.call(r,a[l])&&(u[a[l]]=r[a[l]])}}return u}},function(e,t,n){"use strict";function r(e){for(var t;t=e._renderedComponent;)e=t;return e}function o(e,t){var n=r(e);n._nativeNode=t,t[v]=n}function i(e){var t=e._nativeNode;t&&(delete t[v],e._nativeNode=null)}function a(e,t){if(!(e._flags&h.hasCachedChildNodes)){var n=e._renderedChildren,i=t.firstChild;e:for(var a in n)if(n.hasOwnProperty(a)){var u=n[a],s=r(u)._domID;if(null!=s){for(;null!==i;i=i.nextSibling)if(1===i.nodeType&&i.getAttribute(d)===String(s)||8===i.nodeType&&i.nodeValue===" react-text: "+s+" "||8===i.nodeType&&i.nodeValue===" react-empty: "+s+" "){o(u,i);continue e}p(!1)}}e._flags|=h.hasCachedChildNodes}}function u(e){if(e[v])return e[v];for(var t=[];!e[v];){if(t.push(e),!e.parentNode)return null;e=e.parentNode}for(var n,r;e&&(r=e[v]);e=t.pop())n=r,t.length&&a(r,e);return n}function s(e){var t=u(e);return null!=t&&t._nativeNode===e?t:null}function c(e){if(void 0===e._nativeNode?p(!1):void 0,e._nativeNode)return e._nativeNode;for(var t=[];!e._nativeNode;)t.push(e),e._nativeParent?void 0:p(!1),e=e._nativeParent;for(;t.length;e=t.pop())a(e,e._nativeNode);return e._nativeNode}var l=n(19),f=n(139),p=n(1),d=l.ID_ATTRIBUTE_NAME,h=f,v="__reactInternalInstance$"+Math.random().toString(36).slice(2),m={getClosestInstanceFromNode:u,getInstanceFromNode:s,getNodeFromInstance:c,precacheChildNodes:a,precacheNode:o,uncacheNode:i};e.exports=m},function(t,n){t.exports=e},function(e,t){"use strict";var n=!("undefined"==typeof window||!window.document||!window.document.createElement),r={canUseDOM:n,canUseWorkers:"undefined"!=typeof Worker,canUseEventListeners:n&&!(!window.addEventListener&&!window.attachEvent),canUseViewport:n&&!!window.screen,isInWorker:!n};e.exports=r},function(e,t,n){"use strict";var r=n(326);e.exports={debugTool:r}},function(e,t,n){(function(t){var r=n(226),o=r("object"==typeof t&&t),i=r("object"==typeof self&&self),a=r("object"==typeof this&&this),u=o||i||a||Function("return this")();e.exports=u}).call(t,function(){return this}())},function(e,t){"use strict";function n(e){return function(){return e}}var r=function(){};r.thatReturns=n,r.thatReturnsFalse=n(!1),r.thatReturnsTrue=n(!0),r.thatReturnsNull=n(null),r.thatReturnsThis=function(){return this},r.thatReturnsArgument=function(e){return e},e.exports=r},function(e,t,n){"use strict";function r(){O.ReactReconcileTransaction&&x?void 0:m(!1)}function o(){this.reinitializeTransaction(),this.dirtyComponentsLength=null,this.callbackQueue=f.getPooled(),this.reconcileTransaction=O.ReactReconcileTransaction.getPooled(!0)}function i(e,t,n,o,i,a){r(),x.batchedUpdates(e,t,n,o,i,a)}function a(e,t){return e._mountOrder-t._mountOrder}function u(e){var t=e.dirtyComponentsLength;t!==y.length?m(!1):void 0,y.sort(a),g++;for(var n=0;n<t;n++){var r=y[n],o=r._pendingCallbacks;r._pendingCallbacks=null;var i;if(d.logTopLevelRenders){var u=r;r._currentElement.props===r._renderedComponent._currentElement&&(u=r._renderedComponent),i="React update: "+u.getName(),console.time(i)}if(h.performUpdateIfNecessary(r,e.reconcileTransaction,g),i&&console.timeEnd(i),o)for(var s=0;s<o.length;s++)e.callbackQueue.enqueue(o[s],r.getPublicInstance())}}function s(e){return r(),x.isBatchingUpdates?(y.push(e),void(null==e._updateBatchNumber&&(e._updateBatchNumber=g+1))):void x.batchedUpdates(s,e)}function c(e,t){x.isBatchingUpdates?void 0:m(!1),b.enqueue(e,t),_=!0}var l=n(3),f=n(136),p=n(16),d=n(145),h=(n(7),n(21)),v=n(51),m=n(1),y=[],g=0,b=f.getPooled(),_=!1,x=null,E={initialize:function(){this.dirtyComponentsLength=y.length},close:function(){this.dirtyComponentsLength!==y.length?(y.splice(0,this.dirtyComponentsLength),C()):y.length=0}},w={initialize:function(){this.callbackQueue.reset()},close:function(){this.callbackQueue.notifyAll()}},S=[E,w];l(o.prototype,v.Mixin,{getTransactionWrappers:function(){return S},destructor:function(){this.dirtyComponentsLength=null,f.release(this.callbackQueue),this.callbackQueue=null,O.ReactReconcileTransaction.release(this.reconcileTransaction),this.reconcileTransaction=null},perform:function(e,t,n){return v.Mixin.perform.call(this,this.reconcileTransaction.perform,this.reconcileTransaction,e,t,n)}}),p.addPoolingTo(o);var C=function(){for(;y.length||_;){if(y.length){var e=o.getPooled();e.perform(u,null,e),o.release(e)}if(_){_=!1;var t=b;b=f.getPooled(),t.notifyAll(),f.release(t)}}},P={injectReconcileTransaction:function(e){e?void 0:m(!1),O.ReactReconcileTransaction=e},injectBatchingStrategy:function(e){e?void 0:m(!1),"function"!=typeof e.batchedUpdates?m(!1):void 0,"boolean"!=typeof e.isBatchingUpdates?m(!1):void 0,x=e}},O={ReactReconcileTransaction:null,batchedUpdates:i,enqueueUpdate:s,flushBatchedUpdates:C,injection:P,asap:c};e.exports=O},function(e,t){var n=Array.isArray;e.exports=n},function(e,t,n){"use strict";var r=n(32),o=r({bubbled:null,captured:null}),i=r({topAbort:null,topAnimationEnd:null,topAnimationIteration:null,topAnimationStart:null,topBlur:null,topCanPlay:null,topCanPlayThrough:null,topChange:null,topClick:null,topCompositionEnd:null,topCompositionStart:null,topCompositionUpdate:null,topContextMenu:null,topCopy:null,topCut:null,topDoubleClick:null,topDrag:null,topDragEnd:null,topDragEnter:null,topDragExit:null,topDragLeave:null,topDragOver:null,topDragStart:null,topDrop:null,topDurationChange:null,topEmptied:null,topEncrypted:null,topEnded:null,topError:null,topFocus:null,topInput:null,topInvalid:null,topKeyDown:null,topKeyPress:null,topKeyUp:null,topLoad:null,topLoadedData:null,topLoadedMetadata:null,topLoadStart:null,topMouseDown:null,topMouseMove:null,topMouseOut:null,topMouseOver:null,topMouseUp:null,topPaste:null,topPause:null,topPlay:null,topPlaying:null,topProgress:null,topRateChange:null,topReset:null,topScroll:null,topSeeked:null,topSeeking:null,topSelectionChange:null,topStalled:null,topSubmit:null,topSuspend:null,topTextInput:null,topTimeUpdate:null,topTouchCancel:null,topTouchEnd:null,topTouchMove:null,topTouchStart:null,topTransitionEnd:null,topVolumeChange:null,topWaiting:null,topWheel:null}),a={topLevelTypes:i,PropagationPhases:o};e.exports=a},function(e,t,n){"use strict";function r(e,t,n,r){this.dispatchConfig=e,this._targetInst=t,this.nativeEvent=n;var o=this.constructor.Interface;for(var i in o)if(o.hasOwnProperty(i)){var u=o[i];u?this[i]=u(n):"target"===i?this.target=r:this[i]=n[i]}var s=null!=n.defaultPrevented?n.defaultPrevented:n.returnValue===!1;return s?this.isDefaultPrevented=a.thatReturnsTrue:this.isDefaultPrevented=a.thatReturnsFalse,this.isPropagationStopped=a.thatReturnsFalse,this}var o=n(3),i=n(16),a=n(9),u=(n(2),"function"==typeof Proxy,["dispatchConfig","_targetInst","nativeEvent","isDefaultPrevented","isPropagationStopped","_dispatchListeners","_dispatchInstances"]),s={ type:null,target:null,currentTarget:a.thatReturnsNull,eventPhase:null,bubbles:null,cancelable:null,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:null,isTrusted:null};o(r.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():e.returnValue=!1,this.isDefaultPrevented=a.thatReturnsTrue)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():e.cancelBubble=!0,this.isPropagationStopped=a.thatReturnsTrue)},persist:function(){this.isPersistent=a.thatReturnsTrue},isPersistent:a.thatReturnsFalse,destructor:function(){var e=this.constructor.Interface;for(var t in e)this[t]=null;for(var n=0;n<u.length;n++)this[u[n]]=null}}),r.Interface=s,r.augmentClass=function(e,t){var n=this,r=function(){};r.prototype=n.prototype;var a=new r;o(a,e.prototype),e.prototype=a,e.prototype.constructor=e,e.Interface=o({},n.Interface,t),e.augmentClass=n.augmentClass,i.addPoolingTo(e,i.fourArgumentPooler)},i.addPoolingTo(r,i.fourArgumentPooler),e.exports=r},function(e,t){"use strict";var n=function(e){var t;for(t in e)if(e.hasOwnProperty(t))return t;return null};e.exports=n},function(e,t){function n(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}e.exports=n},function(e,t,n){"use strict";var r=n(1),o=function(e){var t=this;if(t.instancePool.length){var n=t.instancePool.pop();return t.call(n,e),n}return new t(e)},i=function(e,t){var n=this;if(n.instancePool.length){var r=n.instancePool.pop();return n.call(r,e,t),r}return new n(e,t)},a=function(e,t,n){var r=this;if(r.instancePool.length){var o=r.instancePool.pop();return r.call(o,e,t,n),o}return new r(e,t,n)},u=function(e,t,n,r){var o=this;if(o.instancePool.length){var i=o.instancePool.pop();return o.call(i,e,t,n,r),i}return new o(e,t,n,r)},s=function(e,t,n,r,o){var i=this;if(i.instancePool.length){var a=i.instancePool.pop();return i.call(a,e,t,n,r,o),a}return new i(e,t,n,r,o)},c=function(e){var t=this;e instanceof t?void 0:r(!1),e.destructor(),t.instancePool.length<t.poolSize&&t.instancePool.push(e)},l=10,f=o,p=function(e,t){var n=e;return n.instancePool=[],n.getPooled=t||f,n.poolSize||(n.poolSize=l),n.release=c,n},d={addPoolingTo:p,oneArgumentPooler:o,twoArgumentPooler:i,threeArgumentPooler:a,fourArgumentPooler:u,fiveArgumentPooler:s};e.exports=d},function(e,t,n){"use strict";var r=n(3),o=n(20),i=(n(2),n(158),"function"==typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103),a={key:!0,ref:!0,__self:!0,__source:!0},u=function(e,t,n,r,o,a,u){var s={$$typeof:i,type:e,key:t,ref:n,props:u,_owner:a};return s};u.createElement=function(e,t,n){var r,i={},s=null,c=null,l=null,f=null;if(null!=t){c=void 0===t.ref?null:t.ref,s=void 0===t.key?null:""+t.key,l=void 0===t.__self?null:t.__self,f=void 0===t.__source?null:t.__source;for(r in t)t.hasOwnProperty(r)&&!a.hasOwnProperty(r)&&(i[r]=t[r])}var p=arguments.length-2;if(1===p)i.children=n;else if(p>1){for(var d=Array(p),h=0;h<p;h++)d[h]=arguments[h+2];i.children=d}if(e&&e.defaultProps){var v=e.defaultProps;for(r in v)void 0===i[r]&&(i[r]=v[r])}return u(e,s,c,l,f,o.current,i)},u.createFactory=function(e){var t=u.createElement.bind(null,e);return t.type=e,t},u.cloneAndReplaceKey=function(e,t){var n=u(e.type,t,e.ref,e._self,e._source,e._owner,e.props);return n},u.cloneElement=function(e,t,n){var i,s=r({},e.props),c=e.key,l=e.ref,f=e._self,p=e._source,d=e._owner;if(null!=t){void 0!==t.ref&&(l=t.ref,d=o.current),void 0!==t.key&&(c=""+t.key);var h;e.type&&e.type.defaultProps&&(h=e.type.defaultProps);for(i in t)t.hasOwnProperty(i)&&!a.hasOwnProperty(i)&&(void 0===t[i]&&void 0!==h?s[i]=h[i]:s[i]=t[i])}var v=arguments.length-2;if(1===v)s.children=n;else if(v>1){for(var m=Array(v),y=0;y<v;y++)m[y]=arguments[y+2];s.children=m}return u(e.type,c,l,f,p,d,s)},u.isValidElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===i},e.exports=u},function(e,t){function n(e){return!!e&&"object"==typeof e}e.exports=n},function(e,t,n){"use strict";function r(e,t){return(e&t)===t}var o=n(1),i={MUST_USE_PROPERTY:1,HAS_SIDE_EFFECTS:2,HAS_BOOLEAN_VALUE:4,HAS_NUMERIC_VALUE:8,HAS_POSITIVE_NUMERIC_VALUE:24,HAS_OVERLOADED_BOOLEAN_VALUE:32,injectDOMPropertyConfig:function(e){var t=i,n=e.Properties||{},a=e.DOMAttributeNamespaces||{},s=e.DOMAttributeNames||{},c=e.DOMPropertyNames||{},l=e.DOMMutationMethods||{};e.isCustomAttribute&&u._isCustomAttributeFunctions.push(e.isCustomAttribute);for(var f in n){u.properties.hasOwnProperty(f)?o(!1):void 0;var p=f.toLowerCase(),d=n[f],h={attributeName:p,attributeNamespace:null,propertyName:f,mutationMethod:null,mustUseProperty:r(d,t.MUST_USE_PROPERTY),hasSideEffects:r(d,t.HAS_SIDE_EFFECTS),hasBooleanValue:r(d,t.HAS_BOOLEAN_VALUE),hasNumericValue:r(d,t.HAS_NUMERIC_VALUE),hasPositiveNumericValue:r(d,t.HAS_POSITIVE_NUMERIC_VALUE),hasOverloadedBooleanValue:r(d,t.HAS_OVERLOADED_BOOLEAN_VALUE)};if(!h.mustUseProperty&&h.hasSideEffects?o(!1):void 0,h.hasBooleanValue+h.hasNumericValue+h.hasOverloadedBooleanValue<=1?void 0:o(!1),s.hasOwnProperty(f)){var v=s[f];h.attributeName=v}a.hasOwnProperty(f)&&(h.attributeNamespace=a[f]),c.hasOwnProperty(f)&&(h.propertyName=c[f]),l.hasOwnProperty(f)&&(h.mutationMethod=l[f]),u.properties[f]=h}}},a=":A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",u={ID_ATTRIBUTE_NAME:"data-reactid",ROOT_ATTRIBUTE_NAME:"data-reactroot",ATTRIBUTE_NAME_START_CHAR:a,ATTRIBUTE_NAME_CHAR:a+"\\-.0-9\\uB7\\u0300-\\u036F\\u203F-\\u2040",properties:{},getPossibleStandardName:null,_isCustomAttributeFunctions:[],isCustomAttribute:function(e){for(var t=0;t<u._isCustomAttributeFunctions.length;t++){var n=u._isCustomAttributeFunctions[t];if(n(e))return!0}return!1},injection:i};e.exports=u},function(e,t){"use strict";var n={current:null};e.exports=n},function(e,t,n){"use strict";function r(){o.attachRefs(this,this._currentElement)}var o=n(334),i=(n(7),n(1)),a={mountComponent:function(e,t,n,o,i){var a=e.mountComponent(t,n,o,i);return e._currentElement&&null!=e._currentElement.ref&&t.getReactMountReady().enqueue(r,e),a},getNativeNode:function(e){return e.getNativeNode()},unmountComponent:function(e,t){o.detachRefs(e,e._currentElement),e.unmountComponent(t)},receiveComponent:function(e,t,n,i){var a=e._currentElement;if(t!==a||i!==e._context){var u=o.shouldUpdateRefs(a,t);u&&o.detachRefs(e,a),e.receiveComponent(t,n,i),u&&e._currentElement&&null!=e._currentElement.ref&&n.getReactMountReady().enqueue(r,e)}},performUpdateIfNecessary:function(e,t,n){return e._updateBatchNumber!==n?void(null!=e._updateBatchNumber&&e._updateBatchNumber!==n+1?i(!1):void 0):void e.performUpdateIfNecessary(t)}};e.exports=a},function(e,t,n){function r(e,t){var n=i(e,t);return o(n)?n:void 0}var o=n(218),i=n(240);e.exports=r},function(e,t,n){"use strict";function r(e){if(v){var t=e.node,n=e.children;if(n.length)for(var r=0;r<n.length;r++)m(t,n[r],null);else null!=e.html?t.innerHTML=e.html:null!=e.text&&p(t,e.text)}}function o(e,t){e.parentNode.replaceChild(t.node,e),r(t)}function i(e,t){v?e.children.push(t):e.node.appendChild(t.node)}function a(e,t){v?e.html=t:e.node.innerHTML=t}function u(e,t){v?e.text=t:p(e.node,t)}function s(){return this.node.nodeName}function c(e){return{node:e,children:[],html:null,text:null,toString:s}}var l=n(137),f=n(80),p=n(164),d=1,h=11,v="undefined"!=typeof document&&"number"==typeof document.documentMode||"undefined"!=typeof navigator&&"string"==typeof navigator.userAgent&&/\bEdge\/\d/.test(navigator.userAgent),m=f(function(e,t,n){t.node.nodeType===h||t.node.nodeType===d&&"object"===t.node.nodeName.toLowerCase()&&(null==t.node.namespaceURI||t.node.namespaceURI===l.html)?(r(t),e.insertBefore(t.node,n)):(e.insertBefore(t.node,n),r(t))});c.insertTreeBefore=m,c.replaceChildWithTree=o,c.queueChild=i,c.queueHTML=a,c.queueText=u,e.exports=c},function(e,t,n){"use strict";var r={};e.exports=r},function(e,t){function n(e,t){for(var n=-1,o=e.length,i=0,a=[];++n<o;){var u=e[n];u!==t&&u!==r||(e[n]=r,a[i++]=n)}return a}var r="__lodash_placeholder__";e.exports=n},function(e,t,n){function r(e){if("string"==typeof e||o(e))return e;var t=e+"";return"0"==t&&1/e==-i?"-0":t}var o=n(27),i=1/0;e.exports=r},function(e,t,n){function r(e){return"symbol"==typeof e||o(e)&&u.call(e)==i}var o=n(18),i="[object Symbol]",a=Object.prototype,u=a.toString;e.exports=r},function(e,t,n){"use strict";var r=n(48),o=n(72),i=n(76),a=n(157),u=n(159),s=n(1),c={},l=null,f=function(e,t){e&&(o.executeDispatchesInOrder(e,t),e.isPersistent()||e.constructor.release(e))},p=function(e){return f(e,!0)},d=function(e){return f(e,!1)},h={injection:{injectEventPluginOrder:r.injectEventPluginOrder,injectEventPluginsByName:r.injectEventPluginsByName},putListener:function(e,t,n){"function"!=typeof n?s(!1):void 0;var o=c[t]||(c[t]={});o[e._rootNodeID]=n;var i=r.registrationNameModules[t];i&&i.didPutListener&&i.didPutListener(e,t,n)},getListener:function(e,t){var n=c[t];return n&&n[e._rootNodeID]},deleteListener:function(e,t){var n=r.registrationNameModules[t];n&&n.willDeleteListener&&n.willDeleteListener(e,t);var o=c[t];o&&delete o[e._rootNodeID]},deleteAllListeners:function(e){for(var t in c)if(c[t][e._rootNodeID]){var n=r.registrationNameModules[t];n&&n.willDeleteListener&&n.willDeleteListener(e,t),delete c[t][e._rootNodeID]}},extractEvents:function(e,t,n,o){for(var i,u=r.plugins,s=0;s<u.length;s++){var c=u[s];if(c){var l=c.extractEvents(e,t,n,o);l&&(i=a(i,l))}}return i},enqueueEvents:function(e){e&&(l=a(l,e))},processEventQueue:function(e){var t=l;l=null,e?u(t,p):u(t,d),l?s(!1):void 0,i.rethrowCaughtError()},__purge:function(){c={}},__getListenerBank:function(){return c}};e.exports=h},function(e,t,n){"use strict";function r(e,t,n){var r=t.dispatchConfig.phasedRegistrationNames[n];return b(e,r)}function o(e,t,n){var o=t?g.bubbled:g.captured,i=r(e,n,o);i&&(n._dispatchListeners=m(n._dispatchListeners,i),n._dispatchInstances=m(n._dispatchInstances,e))}function i(e){e&&e.dispatchConfig.phasedRegistrationNames&&v.traverseTwoPhase(e._targetInst,o,e)}function a(e){if(e&&e.dispatchConfig.phasedRegistrationNames){var t=e._targetInst,n=t?v.getParentInstance(t):null;v.traverseTwoPhase(n,o,e)}}function u(e,t,n){if(n&&n.dispatchConfig.registrationName){var r=n.dispatchConfig.registrationName,o=b(e,r);o&&(n._dispatchListeners=m(n._dispatchListeners,o),n._dispatchInstances=m(n._dispatchInstances,e))}}function s(e){e&&e.dispatchConfig.registrationName&&u(e._targetInst,null,e)}function c(e){y(e,i)}function l(e){y(e,a)}function f(e,t,n,r){v.traverseEnterLeave(n,r,u,e,t)}function p(e){y(e,s)}var d=n(12),h=n(28),v=n(72),m=n(157),y=n(159),g=(n(2),d.PropagationPhases),b=h.getListener,_={accumulateTwoPhaseDispatches:c,accumulateTwoPhaseDispatchesSkipTarget:l,accumulateDirectDispatches:p,accumulateEnterLeaveDispatches:f};e.exports=_},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(13),i=n(83),a={view:function(e){if(e.view)return e.view;var t=i(e);if(null!=t&&t.window===t)return t;var n=t.ownerDocument;return n?n.defaultView||n.parentWindow:window},detail:function(e){return e.detail||0}};o.augmentClass(r,a),e.exports=r},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(285),i=r(o),a=n(386),u=r(a),s=n(172),c=r(s),l=n(385),f=r(l),p=n(383),d=r(p),h=n(384),v=r(h),m={empty:{},getIn:c.default,setIn:f.default,deepEqual:d.default,deleteIn:v.default,fromJS:function(e){return e},size:function(e){return e?e.length:0},some:i.default,splice:u.default};t.default=m},function(e,t,n){"use strict";var r=n(1),o=function(e){var t,n={};e instanceof Object&&!Array.isArray(e)?void 0:r(!1);for(t in e)e.hasOwnProperty(t)&&(n[t]=t);return n};e.exports=o},function(e,t,n){"use strict";var r=function(e,t,n,r,o,i,a,u){if(!e){var s;if(void 0===t)s=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var c=[n,r,o,i,a,u],l=0;s=new Error(t.replace(/%s/g,function(){return c[l++]})),s.name="Invariant Violation"}throw s.framesToPop=1,s}};e.exports=r},function(e,t,n){function r(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}var o=n(253),i=n(254),a=n(255),u=n(256),s=n(257);r.prototype.clear=o,r.prototype.delete=i,r.prototype.get=a,r.prototype.has=u,r.prototype.set=s,e.exports=r},function(e,t,n){function r(e,t){for(var n=e.length;n--;)if(o(e[n][0],t))return n;return-1}var o=n(126);e.exports=r},function(e,t,n){function r(e){return function(){var t=arguments;switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3]);case 5:return new e(t[0],t[1],t[2],t[3],t[4]);case 6:return new e(t[0],t[1],t[2],t[3],t[4],t[5]);case 7:return new e(t[0],t[1],t[2],t[3],t[4],t[5],t[6])}var n=o(e.prototype),r=e.apply(n,t);return i(r)?r:n}}var o=n(59),i=n(15);e.exports=r},function(e,t){function n(e){var t=e;return t.placeholder}e.exports=n},function(e,t,n){function r(e,t){var n=e.__data__;return o(t)?n["string"==typeof t?"string":"hash"]:n.map}var o=n(249);e.exports=r},function(e,t){function n(e,t){return t=null==t?r:t,!!t&&("number"==typeof e||o.test(e))&&e>-1&&e%1==0&&e<t}var r=9007199254740991,o=/^(?:0|[1-9]\d*)$/;e.exports=n},function(e,t,n){function r(e,t){if(o(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!i(e))||u.test(e)||!a.test(e)||null!=t&&e in Object(t)}var o=n(11),i=n(27),a=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,u=/^\w*$/;e.exports=r},function(e,t,n){var r=n(22),o=r(Object,"create");e.exports=o},function(e,t,n){function r(e){return null!=e&&a(o(e))&&!i(e)}var o=n(237),i=n(64),a=n(43);e.exports=r},function(e,t){function n(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=r}var r=9007199254740991;e.exports=n},function(e,t,n){var r=n(116),o=n(37),i=n(25),a=n(131),u=32,s=a(function(e,t){var n=i(t,o(s));return r(e,u,void 0,t,n)});s.placeholder={},e.exports=s},function(e,t,n){function r(e){return a(e)?o(e,c):u(e)?[e]:i(s(e))}var o=n(212),i=n(62),a=n(11),u=n(27),s=n(124),c=n(26);e.exports=r},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}t.__esModule=!0,t.connect=t.Provider=void 0;var o=n(292),i=r(o),a=n(293),u=r(a);t.Provider=i.default,t.connect=u.default},function(e,t){"use strict";var n={onClick:!0,onDoubleClick:!0,onMouseDown:!0,onMouseMove:!0,onMouseUp:!0,onClickCapture:!0,onDoubleClickCapture:!0,onMouseDownCapture:!0,onMouseMoveCapture:!0,onMouseUpCapture:!0},r={getNativeProps:function(e,t){if(!t.disabled)return t;var r={};for(var o in t)!n[o]&&t.hasOwnProperty(o)&&(r[o]=t[o]);return r}};e.exports=r},function(e,t,n){"use strict";function r(){if(u)for(var e in s){var t=s[e],n=u.indexOf(e);if(n>-1?void 0:a(!1),!c.plugins[n]){t.extractEvents?void 0:a(!1),c.plugins[n]=t;var r=t.eventTypes;for(var i in r)o(r[i],t,i)?void 0:a(!1)}}}function o(e,t,n){c.eventNameDispatchConfigs.hasOwnProperty(n)?a(!1):void 0,c.eventNameDispatchConfigs[n]=e;var r=e.phasedRegistrationNames;if(r){for(var o in r)if(r.hasOwnProperty(o)){var u=r[o];i(u,t,n)}return!0}return!!e.registrationName&&(i(e.registrationName,t,n),!0)}function i(e,t,n){c.registrationNameModules[e]?a(!1):void 0,c.registrationNameModules[e]=t,c.registrationNameDependencies[e]=t.eventTypes[n].dependencies}var a=n(1),u=null,s={},c={plugins:[],eventNameDispatchConfigs:{},registrationNameModules:{},registrationNameDependencies:{},possibleRegistrationNames:null,injectEventPluginOrder:function(e){u?a(!1):void 0,u=Array.prototype.slice.call(e),r()},injectEventPluginsByName:function(e){var t=!1;for(var n in e)if(e.hasOwnProperty(n)){var o=e[n];s.hasOwnProperty(n)&&s[n]===o||(s[n]?a(!1):void 0,s[n]=o,t=!0)}t&&r()},getPluginModuleForEvent:function(e){var t=e.dispatchConfig;if(t.registrationName)return c.registrationNameModules[t.registrationName]||null;for(var n in t.phasedRegistrationNames)if(t.phasedRegistrationNames.hasOwnProperty(n)){var r=c.registrationNameModules[t.phasedRegistrationNames[n]];if(r)return r}return null},_resetEventPlugins:function(){u=null;for(var e in s)s.hasOwnProperty(e)&&delete s[e];c.plugins.length=0;var t=c.eventNameDispatchConfigs;for(var n in t)t.hasOwnProperty(n)&&delete t[n];var r=c.registrationNameModules;for(var o in r)r.hasOwnProperty(o)&&delete r[o]}};e.exports=c},function(e,t,n){"use strict";function r(e){return Object.prototype.hasOwnProperty.call(e,m)||(e[m]=h++,p[e[m]]={}),p[e[m]]}var o,i=n(3),a=n(12),u=n(48),s=n(327),c=n(156),l=n(356),f=n(85),p={},d=!1,h=0,v={topAbort:"abort",topAnimationEnd:l("animationend")||"animationend",topAnimationIteration:l("animationiteration")||"animationiteration",topAnimationStart:l("animationstart")||"animationstart",topBlur:"blur",topCanPlay:"canplay",topCanPlayThrough:"canplaythrough",topChange:"change",topClick:"click",topCompositionEnd:"compositionend",topCompositionStart:"compositionstart",topCompositionUpdate:"compositionupdate",topContextMenu:"contextmenu",topCopy:"copy",topCut:"cut",topDoubleClick:"dblclick",topDrag:"drag",topDragEnd:"dragend",topDragEnter:"dragenter",topDragExit:"dragexit",topDragLeave:"dragleave",topDragOver:"dragover",topDragStart:"dragstart",topDrop:"drop",topDurationChange:"durationchange",topEmptied:"emptied",topEncrypted:"encrypted",topEnded:"ended",topError:"error",topFocus:"focus",topInput:"input",topKeyDown:"keydown",topKeyPress:"keypress",topKeyUp:"keyup",topLoadedData:"loadeddata",topLoadedMetadata:"loadedmetadata",topLoadStart:"loadstart",topMouseDown:"mousedown",topMouseMove:"mousemove",topMouseOut:"mouseout",topMouseOver:"mouseover",topMouseUp:"mouseup",topPaste:"paste",topPause:"pause",topPlay:"play",topPlaying:"playing",topProgress:"progress",topRateChange:"ratechange",topScroll:"scroll",topSeeked:"seeked",topSeeking:"seeking",topSelectionChange:"selectionchange",topStalled:"stalled",topSuspend:"suspend",topTextInput:"textInput",topTimeUpdate:"timeupdate",topTouchCancel:"touchcancel",topTouchEnd:"touchend",topTouchMove:"touchmove",topTouchStart:"touchstart",topTransitionEnd:l("transitionend")||"transitionend",topVolumeChange:"volumechange",topWaiting:"waiting",topWheel:"wheel"},m="_reactListenersID"+String(Math.random()).slice(2),y=i({},s,{ReactEventListener:null,injection:{injectReactEventListener:function(e){e.setHandleTopLevel(y.handleTopLevel),y.ReactEventListener=e}},setEnabled:function(e){y.ReactEventListener&&y.ReactEventListener.setEnabled(e)},isEnabled:function(){return!(!y.ReactEventListener||!y.ReactEventListener.isEnabled())},listenTo:function(e,t){for(var n=t,o=r(n),i=u.registrationNameDependencies[e],s=a.topLevelTypes,c=0;c<i.length;c++){var l=i[c];o.hasOwnProperty(l)&&o[l]||(l===s.topWheel?f("wheel")?y.ReactEventListener.trapBubbledEvent(s.topWheel,"wheel",n):f("mousewheel")?y.ReactEventListener.trapBubbledEvent(s.topWheel,"mousewheel",n):y.ReactEventListener.trapBubbledEvent(s.topWheel,"DOMMouseScroll",n):l===s.topScroll?f("scroll",!0)?y.ReactEventListener.trapCapturedEvent(s.topScroll,"scroll",n):y.ReactEventListener.trapBubbledEvent(s.topScroll,"scroll",y.ReactEventListener.WINDOW_HANDLE):l===s.topFocus||l===s.topBlur?(f("focus",!0)?(y.ReactEventListener.trapCapturedEvent(s.topFocus,"focus",n),y.ReactEventListener.trapCapturedEvent(s.topBlur,"blur",n)):f("focusin")&&(y.ReactEventListener.trapBubbledEvent(s.topFocus,"focusin",n),y.ReactEventListener.trapBubbledEvent(s.topBlur,"focusout",n)),o[s.topBlur]=!0,o[s.topFocus]=!0):v.hasOwnProperty(l)&&y.ReactEventListener.trapBubbledEvent(l,v[l],n),o[l]=!0)}},trapBubbledEvent:function(e,t,n){return y.ReactEventListener.trapBubbledEvent(e,t,n)},trapCapturedEvent:function(e,t,n){return y.ReactEventListener.trapCapturedEvent(e,t,n)},ensureScrollValueMonitoring:function(){if(void 0===o&&(o=document.createEvent&&"pageX"in document.createEvent("MouseEvent")),!o&&!d){var e=c.refreshScrollValues;y.ReactEventListener.monitorScrollValue(e),d=!0}}});e.exports=y},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(30),i=n(156),a=n(82),u={screenX:null,screenY:null,clientX:null,clientY:null,ctrlKey:null,shiftKey:null,altKey:null,metaKey:null,getModifierState:a,button:function(e){var t=e.button;return"which"in e?t:2===t?2:4===t?1:0},buttons:null,relatedTarget:function(e){return e.relatedTarget||(e.fromElement===e.srcElement?e.toElement:e.fromElement)},pageX:function(e){return"pageX"in e?e.pageX:e.clientX+i.currentScrollLeft},pageY:function(e){return"pageY"in e?e.pageY:e.clientY+i.currentScrollTop}};o.augmentClass(r,u),e.exports=r},function(e,t,n){"use strict";var r=n(1),o={reinitializeTransaction:function(){this.transactionWrappers=this.getTransactionWrappers(),this.wrapperInitData?this.wrapperInitData.length=0:this.wrapperInitData=[],this._isInTransaction=!1},_isInTransaction:!1,getTransactionWrappers:null,isInTransaction:function(){return!!this._isInTransaction},perform:function(e,t,n,o,i,a,u,s){this.isInTransaction()?r(!1):void 0;var c,l;try{this._isInTransaction=!0,c=!0,this.initializeAll(0),l=e.call(t,n,o,i,a,u,s),c=!1}finally{try{if(c)try{this.closeAll(0)}catch(e){}else this.closeAll(0)}finally{this._isInTransaction=!1}}return l},initializeAll:function(e){for(var t=this.transactionWrappers,n=e;n<t.length;n++){var r=t[n];try{this.wrapperInitData[n]=i.OBSERVED_ERROR,this.wrapperInitData[n]=r.initialize?r.initialize.call(this):null}finally{if(this.wrapperInitData[n]===i.OBSERVED_ERROR)try{this.initializeAll(n+1)}catch(e){}}}},closeAll:function(e){this.isInTransaction()?void 0:r(!1);for(var t=this.transactionWrappers,n=e;n<t.length;n++){var o,a=t[n],u=this.wrapperInitData[n];try{o=!0,u!==i.OBSERVED_ERROR&&a.close&&a.close.call(this,u),o=!1}finally{if(o)try{this.closeAll(n+1)}catch(e){}}}this.wrapperInitData.length=0}},i={Mixin:o,OBSERVED_ERROR:{}};e.exports=i},function(e,t){"use strict";function n(e){return o[e]}function r(e){return(""+e).replace(i,n)}var o={"&":"&amp;",">":"&gt;","<":"&lt;",'"':"&quot;","'":"&#x27;"},i=/[&><"']/g;e.exports=r},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}Object.defineProperty(t,"__esModule",{value:!0});var i=n(5),a=r(i),u=n(189),s=r(u),c=n(180),l=r(c),f=n(181),p=r(f),d=n(178),h=r(d),v=n(182),m=r(v),y=n(93),g=r(y),b=function(e){var t=e.children,n=e.path,r=e.version,i=e.breadcrumbs,u="/"===n,c="https://redux-form.com/"+r;return a.default.createElement("div",{className:(0,g.default)(s.default.app,o({},s.default.hasNav,!u))},!u&&a.default.createElement(p.default,{path:n,url:c}),a.default.createElement("div",{className:s.default.contentAndFooter},a.default.createElement("div",{className:s.default.topNav},a.default.createElement("a",{href:"https://redux-form.com",className:s.default.brand}),a.default.createElement("a",{className:s.default.github,href:"https://github.com/erikras/redux-form",title:"Github",target:"_blank"},a.default.createElement("i",{className:"fa fa-fw fa-github"}))),a.default.createElement("div",{className:(0,g.default)(s.default.content,o({},s.default.home,u))},u?a.default.createElement(l.default,{version:r}):a.default.createElement("div",null,a.default.createElement(h.default,{items:i}),t)),a.default.createElement("div",{className:s.default.footer},a.default.createElement("div",null,"Created by Erik Rasmussen"),a.default.createElement("div",null,"Got questions? Ask for help:",a.default.createElement("a",{className:s.default.help,href:"https://stackoverflow.com/questions/ask?tags=redux-form",title:"Stack Overflow",target:"_blank"},a.default.createElement("i",{className:"fa fa-fw fa-stack-overflow"})),a.default.createElement("a",{className:s.default.help,href:"https://github.com/erikras/redux-form/issues/new",title:"Github",target:"_blank"},a.default.createElement("i",{className:"fa fa-fw fa-github"}))),a.default.createElement("div",null,a.default.createElement(m.default,{username:"erikras",showUsername:!0,large:!0}),a.default.createElement(m.default,{username:"ReduxForm",showUsername:!0,large:!0})))))};t.default=b},function(e,t){"use strict";function n(e,t){return e===t?0!==e||1/e===1/t:e!==e&&t!==t}function r(e,t){if(n(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var r=Object.keys(e),i=Object.keys(t);if(r.length!==i.length)return!1;for(var a=0;a<r.length;a++)if(!o.call(t,r[a])||!n(e[r[a]],t[r[a]]))return!1;return!0}var o=Object.prototype.hasOwnProperty;e.exports=r},function(e,t){function n(e){return!!e&&("object"==typeof e||"function"==typeof e)&&"function"==typeof e.then}e.exports=n},function(e,t,n){function r(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=a,this.__views__=[]}var o=n(59),i=n(61),a=4294967295;r.prototype=o(i.prototype),r.prototype.constructor=r,e.exports=r},function(e,t,n){function r(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}var o=n(258),i=n(259),a=n(260),u=n(261),s=n(262);r.prototype.clear=o,r.prototype.delete=i,r.prototype.get=a,r.prototype.has=u,r.prototype.set=s,e.exports=r},function(e,t){function n(e,t,n){var r=n.length;switch(r){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}e.exports=n},function(e,t,n){function r(e){return o(e)?i(e):{}}var o=n(15),i=Object.create;e.exports=r},function(e,t,n){function r(e,t,n,u,s){return e===t||(null==e||null==t||!i(e)&&!a(t)?e!==e&&t!==t:o(e,t,r,n,u,s))}var o=n(216),i=n(15),a=n(18);e.exports=r},function(e,t){function n(){}e.exports=n},function(e,t){function n(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}e.exports=n},function(e,t){function n(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}e.exports=n},function(e,t,n){function r(e){var t=o(e)?s.call(e):"";return t==i||t==a}var o=n(15),i="[object Function]",a="[object GeneratorFunction]",u=Object.prototype,s=u.toString;e.exports=r},function(e,t,n){function r(e){if(!a(e)||p.call(e)!=u||i(e))return!1;var t=o(e);if(null===t)return!0;var n=l.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&c.call(n)==f}var o=n(119),i=n(63),a=n(18),u="[object Object]",s=Object.prototype,c=Function.prototype.toString,l=s.hasOwnProperty,f=c.call(Object),p=s.toString;e.exports=r},function(e,t,n){function r(e){var t=c(e);if(!t&&!u(e))return i(e);var n=a(e),r=!!n,l=n||[],f=l.length;for(var p in e)!o(e,p)||r&&("length"==p||s(p,f))||t&&"constructor"==p||l.push(p);return l}var o=n(107),i=n(219),a=n(247),u=n(42),s=n(39),c=n(252);e.exports=r},function(e,t,n){function r(e,t){var n={};return t=i(t,3),o(e,function(e,r,o){n[r]=t(e,r,o)}),n}var o=n(105),i=n(108);e.exports=r},function(e,t,n){(function(t){(function(){function t(e){this.tokens=[],this.tokens.links={},this.options=e||l.defaults,this.rules=f.normal,this.options.gfm&&(this.options.tables?this.rules=f.tables:this.rules=f.gfm)}function n(e,t){if(this.options=t||l.defaults,this.links=e,this.rules=p.normal,this.renderer=this.options.renderer||new r,this.renderer.options=this.options,!this.links)throw new Error("Tokens array requires a `links` property.");this.options.gfm?this.options.breaks?this.rules=p.breaks:this.rules=p.gfm:this.options.pedantic&&(this.rules=p.pedantic)}function r(e){this.options=e||{}}function o(e){this.tokens=[],this.token=null,this.options=e||l.defaults,this.options.renderer=this.options.renderer||new r,this.renderer=this.options.renderer,this.renderer.options=this.options}function i(e,t){return e.replace(t?/&/g:/&(?!#?\w+;)/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#39;")}function a(e){return e.replace(/&([#\w]+);/g,function(e,t){return t=t.toLowerCase(),"colon"===t?":":"#"===t.charAt(0)?"x"===t.charAt(1)?String.fromCharCode(parseInt(t.substring(2),16)):String.fromCharCode(+t.substring(1)):""})}function u(e,t){return e=e.source,t=t||"",function n(r,o){return r?(o=o.source||o,o=o.replace(/(^|[^\[])\^/g,"$1"),e=e.replace(r,o),n):new RegExp(e,t)}}function s(){}function c(e){for(var t,n,r=1;r<arguments.length;r++){t=arguments[r];for(n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])}return e}function l(e,n,r){if(r||"function"==typeof n){r||(r=n,n=null),n=c({},l.defaults,n||{});var a,u,s=n.highlight,f=0;try{a=t.lex(e,n)}catch(e){return r(e)}u=a.length;var p=function(e){if(e)return n.highlight=s,r(e);var t;try{t=o.parse(a,n)}catch(t){e=t}return n.highlight=s,e?r(e):r(null,t)};if(!s||s.length<3)return p();if(delete n.highlight,!u)return p();for(;f<a.length;f++)!function(e){return"code"!==e.type?--u||p():s(e.text,e.lang,function(t,n){return t?p(t):null==n||n===e.text?--u||p():(e.text=n,e.escaped=!0,void(--u||p()))})}(a[f])}else try{return n&&(n=c({},l.defaults,n)),o.parse(t.lex(e,n),n)}catch(e){if(e.message+="\nPlease report this to https://github.com/chjj/marked.",(n||l.defaults).silent)return"<p>An error occured:</p><pre>"+i(e.message+"",!0)+"</pre>";throw e}}var f={newline:/^\n+/,code:/^( {4}[^\n]+\n*)+/,fences:s,hr:/^( *[-*_]){3,} *(?:\n+|$)/,heading:/^ *(#{1,6}) *([^\n]+?) *#* *(?:\n+|$)/,nptable:s,lheading:/^([^\n]+)\n *(=|-){2,} *(?:\n+|$)/,blockquote:/^( *>[^\n]+(\n(?!def)[^\n]+)*\n*)+/,list:/^( *)(bull) [\s\S]+?(?:hr|def|\n{2,}(?! )(?!\1bull )\n*|\s*$)/,html:/^ *(?:comment *(?:\n|\s*$)|closed *(?:\n{2,}|\s*$)|closing *(?:\n{2,}|\s*$))/,def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +["(]([^\n]+)[")])? *(?:\n+|$)/,table:s,paragraph:/^((?:[^\n]+\n?(?!hr|heading|lheading|blockquote|tag|def))+)\n*/,text:/^[^\n]+/};f.bullet=/(?:[*+-]|\d+\.)/,f.item=/^( *)(bull) [^\n]*(?:\n(?!\1bull )[^\n]*)*/,f.item=u(f.item,"gm")(/bull/g,f.bullet)(),f.list=u(f.list)(/bull/g,f.bullet)("hr","\\n+(?=\\1?(?:[-*_] *){3,}(?:\\n+|$))")("def","\\n+(?="+f.def.source+")")(),f.blockquote=u(f.blockquote)("def",f.def)(),f._tag="(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:/|[^\\w\\s@]*@)\\b",f.html=u(f.html)("comment",/<!--[\s\S]*?-->/)("closed",/<(tag)[\s\S]+?<\/\1>/)("closing",/<tag(?:"[^"]*"|'[^']*'|[^'">])*?>/)(/tag/g,f._tag)(),f.paragraph=u(f.paragraph)("hr",f.hr)("heading",f.heading)("lheading",f.lheading)("blockquote",f.blockquote)("tag","<"+f._tag)("def",f.def)(),f.normal=c({},f),f.gfm=c({},f.normal,{fences:/^ *(`{3,}|~{3,})[ \.]*(\S+)? *\n([\s\S]*?)\s*\1 *(?:\n+|$)/,paragraph:/^/,heading:/^ *(#{1,6}) +([^\n]+?) *#* *(?:\n+|$)/}),f.gfm.paragraph=u(f.paragraph)("(?!","(?!"+f.gfm.fences.source.replace("\\1","\\2")+"|"+f.list.source.replace("\\1","\\3")+"|")(),f.tables=c({},f.gfm,{nptable:/^ *(\S.*\|.*)\n *([-:]+ *\|[-| :]*)\n((?:.*\|.*(?:\n|$))*)\n*/,table:/^ *\|(.+)\n *\|( *[-:]+[-| :]*)\n((?: *\|.*(?:\n|$))*)\n*/}),t.rules=f,t.lex=function(e,n){var r=new t(n);return r.lex(e)},t.prototype.lex=function(e){return e=e.replace(/\r\n|\r/g,"\n").replace(/\t/g," ").replace(/\u00a0/g," ").replace(/\u2424/g,"\n"),this.token(e,!0)},t.prototype.token=function(e,t,n){for(var r,o,i,a,u,s,c,l,p,e=e.replace(/^ +$/gm,"");e;)if((i=this.rules.newline.exec(e))&&(e=e.substring(i[0].length),i[0].length>1&&this.tokens.push({type:"space"})),i=this.rules.code.exec(e))e=e.substring(i[0].length),i=i[0].replace(/^ {4}/gm,""),this.tokens.push({type:"code",text:this.options.pedantic?i:i.replace(/\n+$/,"")});else if(i=this.rules.fences.exec(e))e=e.substring(i[0].length),this.tokens.push({type:"code",lang:i[2],text:i[3]||""});else if(i=this.rules.heading.exec(e))e=e.substring(i[0].length),this.tokens.push({type:"heading",depth:i[1].length,text:i[2]});else if(t&&(i=this.rules.nptable.exec(e))){for(e=e.substring(i[0].length),s={type:"table",header:i[1].replace(/^ *| *\| *$/g,"").split(/ *\| */),align:i[2].replace(/^ *|\| *$/g,"").split(/ *\| */), cells:i[3].replace(/\n$/,"").split("\n")},l=0;l<s.align.length;l++)/^ *-+: *$/.test(s.align[l])?s.align[l]="right":/^ *:-+: *$/.test(s.align[l])?s.align[l]="center":/^ *:-+ *$/.test(s.align[l])?s.align[l]="left":s.align[l]=null;for(l=0;l<s.cells.length;l++)s.cells[l]=s.cells[l].split(/ *\| */);this.tokens.push(s)}else if(i=this.rules.lheading.exec(e))e=e.substring(i[0].length),this.tokens.push({type:"heading",depth:"="===i[2]?1:2,text:i[1]});else if(i=this.rules.hr.exec(e))e=e.substring(i[0].length),this.tokens.push({type:"hr"});else if(i=this.rules.blockquote.exec(e))e=e.substring(i[0].length),this.tokens.push({type:"blockquote_start"}),i=i[0].replace(/^ *> ?/gm,""),this.token(i,t,!0),this.tokens.push({type:"blockquote_end"});else if(i=this.rules.list.exec(e)){for(e=e.substring(i[0].length),a=i[2],this.tokens.push({type:"list_start",ordered:a.length>1}),i=i[0].match(this.rules.item),r=!1,p=i.length,l=0;l<p;l++)s=i[l],c=s.length,s=s.replace(/^ *([*+-]|\d+\.) +/,""),~s.indexOf("\n ")&&(c-=s.length,s=this.options.pedantic?s.replace(/^ {1,4}/gm,""):s.replace(new RegExp("^ {1,"+c+"}","gm"),"")),this.options.smartLists&&l!==p-1&&(u=f.bullet.exec(i[l+1])[0],a===u||a.length>1&&u.length>1||(e=i.slice(l+1).join("\n")+e,l=p-1)),o=r||/\n\n(?!\s*$)/.test(s),l!==p-1&&(r="\n"===s.charAt(s.length-1),o||(o=r)),this.tokens.push({type:o?"loose_item_start":"list_item_start"}),this.token(s,!1,n),this.tokens.push({type:"list_item_end"});this.tokens.push({type:"list_end"})}else if(i=this.rules.html.exec(e))e=e.substring(i[0].length),this.tokens.push({type:this.options.sanitize?"paragraph":"html",pre:!this.options.sanitizer&&("pre"===i[1]||"script"===i[1]||"style"===i[1]),text:i[0]});else if(!n&&t&&(i=this.rules.def.exec(e)))e=e.substring(i[0].length),this.tokens.links[i[1].toLowerCase()]={href:i[2],title:i[3]};else if(t&&(i=this.rules.table.exec(e))){for(e=e.substring(i[0].length),s={type:"table",header:i[1].replace(/^ *| *\| *$/g,"").split(/ *\| */),align:i[2].replace(/^ *|\| *$/g,"").split(/ *\| */),cells:i[3].replace(/(?: *\| *)?\n$/,"").split("\n")},l=0;l<s.align.length;l++)/^ *-+: *$/.test(s.align[l])?s.align[l]="right":/^ *:-+: *$/.test(s.align[l])?s.align[l]="center":/^ *:-+ *$/.test(s.align[l])?s.align[l]="left":s.align[l]=null;for(l=0;l<s.cells.length;l++)s.cells[l]=s.cells[l].replace(/^ *\| *| *\| *$/g,"").split(/ *\| */);this.tokens.push(s)}else if(t&&(i=this.rules.paragraph.exec(e)))e=e.substring(i[0].length),this.tokens.push({type:"paragraph",text:"\n"===i[1].charAt(i[1].length-1)?i[1].slice(0,-1):i[1]});else if(i=this.rules.text.exec(e))e=e.substring(i[0].length),this.tokens.push({type:"text",text:i[0]});else if(e)throw new Error("Infinite loop on byte: "+e.charCodeAt(0));return this.tokens};var p={escape:/^\\([\\`*{}\[\]()#+\-.!_>])/,autolink:/^<([^ >]+(@|:\/)[^ >]+)>/,url:s,tag:/^<!--[\s\S]*?-->|^<\/?\w+(?:"[^"]*"|'[^']*'|[^'">])*?>/,link:/^!?\[(inside)\]\(href\)/,reflink:/^!?\[(inside)\]\s*\[([^\]]*)\]/,nolink:/^!?\[((?:\[[^\]]*\]|[^\[\]])*)\]/,strong:/^__([\s\S]+?)__(?!_)|^\*\*([\s\S]+?)\*\*(?!\*)/,em:/^\b_((?:[^_]|__)+?)_\b|^\*((?:\*\*|[\s\S])+?)\*(?!\*)/,code:/^(`+)\s*([\s\S]*?[^`])\s*\1(?!`)/,br:/^ {2,}\n(?!\s*$)/,del:s,text:/^[\s\S]+?(?=[\\<!\[_*`]| {2,}\n|$)/};p._inside=/(?:\[[^\]]*\]|[^\[\]]|\](?=[^\[]*\]))*/,p._href=/\s*<?([\s\S]*?)>?(?:\s+['"]([\s\S]*?)['"])?\s*/,p.link=u(p.link)("inside",p._inside)("href",p._href)(),p.reflink=u(p.reflink)("inside",p._inside)(),p.normal=c({},p),p.pedantic=c({},p.normal,{strong:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,em:/^_(?=\S)([\s\S]*?\S)_(?!_)|^\*(?=\S)([\s\S]*?\S)\*(?!\*)/}),p.gfm=c({},p.normal,{escape:u(p.escape)("])","~|])")(),url:/^(https?:\/\/[^\s<]+[^<.,:;"')\]\s])/,del:/^~~(?=\S)([\s\S]*?\S)~~/,text:u(p.text)("]|","~]|")("|","|https?://|")()}),p.breaks=c({},p.gfm,{br:u(p.br)("{2,}","*")(),text:u(p.gfm.text)("{2,}","*")()}),n.rules=p,n.output=function(e,t,r){var o=new n(t,r);return o.output(e)},n.prototype.output=function(e){for(var t,n,r,o,a="";e;)if(o=this.rules.escape.exec(e))e=e.substring(o[0].length),a+=o[1];else if(o=this.rules.autolink.exec(e))e=e.substring(o[0].length),"@"===o[2]?(n=":"===o[1].charAt(6)?this.mangle(o[1].substring(7)):this.mangle(o[1]),r=this.mangle("mailto:")+n):(n=i(o[1]),r=n),a+=this.renderer.link(r,null,n);else if(this.inLink||!(o=this.rules.url.exec(e))){if(o=this.rules.tag.exec(e))!this.inLink&&/^<a /i.test(o[0])?this.inLink=!0:this.inLink&&/^<\/a>/i.test(o[0])&&(this.inLink=!1),e=e.substring(o[0].length),a+=this.options.sanitize?this.options.sanitizer?this.options.sanitizer(o[0]):i(o[0]):o[0];else if(o=this.rules.link.exec(e))e=e.substring(o[0].length),this.inLink=!0,a+=this.outputLink(o,{href:o[2],title:o[3]}),this.inLink=!1;else if((o=this.rules.reflink.exec(e))||(o=this.rules.nolink.exec(e))){if(e=e.substring(o[0].length),t=(o[2]||o[1]).replace(/\s+/g," "),t=this.links[t.toLowerCase()],!t||!t.href){a+=o[0].charAt(0),e=o[0].substring(1)+e;continue}this.inLink=!0,a+=this.outputLink(o,t),this.inLink=!1}else if(o=this.rules.strong.exec(e))e=e.substring(o[0].length),a+=this.renderer.strong(this.output(o[2]||o[1]));else if(o=this.rules.em.exec(e))e=e.substring(o[0].length),a+=this.renderer.em(this.output(o[2]||o[1]));else if(o=this.rules.code.exec(e))e=e.substring(o[0].length),a+=this.renderer.codespan(i(o[2],!0));else if(o=this.rules.br.exec(e))e=e.substring(o[0].length),a+=this.renderer.br();else if(o=this.rules.del.exec(e))e=e.substring(o[0].length),a+=this.renderer.del(this.output(o[1]));else if(o=this.rules.text.exec(e))e=e.substring(o[0].length),a+=this.renderer.text(i(this.smartypants(o[0])));else if(e)throw new Error("Infinite loop on byte: "+e.charCodeAt(0))}else e=e.substring(o[0].length),n=i(o[1]),r=n,a+=this.renderer.link(r,null,n);return a},n.prototype.outputLink=function(e,t){var n=i(t.href),r=t.title?i(t.title):null;return"!"!==e[0].charAt(0)?this.renderer.link(n,r,this.output(e[1])):this.renderer.image(n,r,i(e[1]))},n.prototype.smartypants=function(e){return this.options.smartypants?e.replace(/---/g,"—").replace(/--/g,"–").replace(/(^|[-\u2014\/(\[{"\s])'/g,"$1‘").replace(/'/g,"’").replace(/(^|[-\u2014\/(\[{\u2018\s])"/g,"$1“").replace(/"/g,"”").replace(/\.{3}/g,"…"):e},n.prototype.mangle=function(e){if(!this.options.mangle)return e;for(var t,n="",r=e.length,o=0;o<r;o++)t=e.charCodeAt(o),Math.random()>.5&&(t="x"+t.toString(16)),n+="&#"+t+";";return n},r.prototype.code=function(e,t,n){if(this.options.highlight){var r=this.options.highlight(e,t);null!=r&&r!==e&&(n=!0,e=r)}return t?'<pre><code class="'+this.options.langPrefix+i(t,!0)+'">'+(n?e:i(e,!0))+"\n</code></pre>\n":"<pre><code>"+(n?e:i(e,!0))+"\n</code></pre>"},r.prototype.blockquote=function(e){return"<blockquote>\n"+e+"</blockquote>\n"},r.prototype.html=function(e){return e},r.prototype.heading=function(e,t,n){return"<h"+t+' id="'+this.options.headerPrefix+n.toLowerCase().replace(/[^\w]+/g,"-")+'">'+e+"</h"+t+">\n"},r.prototype.hr=function(){return this.options.xhtml?"<hr/>\n":"<hr>\n"},r.prototype.list=function(e,t){var n=t?"ol":"ul";return"<"+n+">\n"+e+"</"+n+">\n"},r.prototype.listitem=function(e){return"<li>"+e+"</li>\n"},r.prototype.paragraph=function(e){return"<p>"+e+"</p>\n"},r.prototype.table=function(e,t){return"<table>\n<thead>\n"+e+"</thead>\n<tbody>\n"+t+"</tbody>\n</table>\n"},r.prototype.tablerow=function(e){return"<tr>\n"+e+"</tr>\n"},r.prototype.tablecell=function(e,t){var n=t.header?"th":"td",r=t.align?"<"+n+' style="text-align:'+t.align+'">':"<"+n+">";return r+e+"</"+n+">\n"},r.prototype.strong=function(e){return"<strong>"+e+"</strong>"},r.prototype.em=function(e){return"<em>"+e+"</em>"},r.prototype.codespan=function(e){return"<code>"+e+"</code>"},r.prototype.br=function(){return this.options.xhtml?"<br/>":"<br>"},r.prototype.del=function(e){return"<del>"+e+"</del>"},r.prototype.link=function(e,t,n){if(this.options.sanitize){try{var r=decodeURIComponent(a(e)).replace(/[^\w:]/g,"").toLowerCase()}catch(e){return""}if(0===r.indexOf("javascript:")||0===r.indexOf("vbscript:"))return""}var o='<a href="'+e+'"';return t&&(o+=' title="'+t+'"'),o+=">"+n+"</a>"},r.prototype.image=function(e,t,n){var r='<img src="'+e+'" alt="'+n+'"';return t&&(r+=' title="'+t+'"'),r+=this.options.xhtml?"/>":">"},r.prototype.text=function(e){return e},o.parse=function(e,t,n){var r=new o(t,n);return r.parse(e)},o.prototype.parse=function(e){this.inline=new n(e.links,this.options,this.renderer),this.tokens=e.reverse();for(var t="";this.next();)t+=this.tok();return t},o.prototype.next=function(){return this.token=this.tokens.pop()},o.prototype.peek=function(){return this.tokens[this.tokens.length-1]||0},o.prototype.parseText=function(){for(var e=this.token.text;"text"===this.peek().type;)e+="\n"+this.next().text;return this.inline.output(e)},o.prototype.tok=function(){switch(this.token.type){case"space":return"";case"hr":return this.renderer.hr();case"heading":return this.renderer.heading(this.inline.output(this.token.text),this.token.depth,this.token.text);case"code":return this.renderer.code(this.token.text,this.token.lang,this.token.escaped);case"table":var e,t,n,r,o,i="",a="";for(n="",e=0;e<this.token.header.length;e++)r={header:!0,align:this.token.align[e]},n+=this.renderer.tablecell(this.inline.output(this.token.header[e]),{header:!0,align:this.token.align[e]});for(i+=this.renderer.tablerow(n),e=0;e<this.token.cells.length;e++){for(t=this.token.cells[e],n="",o=0;o<t.length;o++)n+=this.renderer.tablecell(this.inline.output(t[o]),{header:!1,align:this.token.align[o]});a+=this.renderer.tablerow(n)}return this.renderer.table(i,a);case"blockquote_start":for(var a="";"blockquote_end"!==this.next().type;)a+=this.tok();return this.renderer.blockquote(a);case"list_start":for(var a="",u=this.token.ordered;"list_end"!==this.next().type;)a+=this.tok();return this.renderer.list(a,u);case"list_item_start":for(var a="";"list_item_end"!==this.next().type;)a+="text"===this.token.type?this.parseText():this.tok();return this.renderer.listitem(a);case"loose_item_start":for(var a="";"list_item_end"!==this.next().type;)a+=this.tok();return this.renderer.listitem(a);case"html":var s=this.token.pre||this.options.pedantic?this.token.text:this.inline.output(this.token.text);return this.renderer.html(s);case"paragraph":return this.renderer.paragraph(this.inline.output(this.token.text));case"text":return this.renderer.paragraph(this.parseText())}},s.exec=s,l.options=l.setOptions=function(e){return c(l.defaults,e),l},l.defaults={gfm:!0,tables:!0,breaks:!1,pedantic:!1,sanitize:!1,sanitizer:null,mangle:!0,smartLists:!1,silent:!1,highlight:null,langPrefix:"lang-",smartypants:!1,headerPrefix:"",renderer:new r,xhtml:!1},l.Parser=o,l.parser=o.parse,l.Renderer=r,l.Lexer=t,l.lexer=t.lex,l.InlineLexer=n,l.inlineLexer=n.output,l.parse=l,e.exports=l}).call(function(){return this||("undefined"!=typeof window?window:t)}())}).call(t,function(){return this}())},function(e,t,n){e.exports=n(359)},function(e,t,n){"use strict";function r(e,t){return Array.isArray(t)&&(t=t[1]),t?t.nextSibling:e.firstChild}function o(e,t,n){l.insertTreeBefore(e,t,n)}function i(e,t,n){Array.isArray(t)?u(e,t[0],t[1],n):m(e,t,n)}function a(e,t){if(Array.isArray(t)){var n=t[1];t=t[0],s(e,t,n),e.removeChild(n)}e.removeChild(t)}function u(e,t,n,r){for(var o=t;;){var i=o.nextSibling;if(m(e,o,r),o===n)break;o=i}}function s(e,t,n){for(;;){var r=t.nextSibling;if(r===n)break;e.removeChild(r)}}function c(e,t,n){var r=e.parentNode,o=e.nextSibling;o===t?n&&m(r,document.createTextNode(n),o):n?(v(o,n),s(r,o,t)):s(r,e,t)}var l=n(23),f=n(300),p=n(149),d=(n(4),n(7),n(80)),h=n(86),v=n(164),m=d(function(e,t,n){e.insertBefore(t,n)}),y=f.dangerouslyReplaceNodeWithMarkup,g={dangerouslyReplaceNodeWithMarkup:y,replaceDelimitedText:c,processUpdates:function(e,t){for(var n=0;n<t.length;n++){var u=t[n];switch(u.type){case p.INSERT_MARKUP:o(e,u.content,r(e,u.afterNode));break;case p.MOVE_EXISTING:i(e,u.fromNode,r(e,u.afterNode));break;case p.SET_MARKUP:h(e,u.content);break;case p.TEXT_CONTENT:v(e,u.content);break;case p.REMOVE_NODE:a(e,u.fromNode)}}}};e.exports=g},function(e,t,n){"use strict";function r(e){return!!c.hasOwnProperty(e)||!s.hasOwnProperty(e)&&(u.test(e)?(c[e]=!0,!0):(s[e]=!0,!1))}function o(e,t){return null==t||e.hasBooleanValue&&!t||e.hasNumericValue&&isNaN(t)||e.hasPositiveNumericValue&&t<1||e.hasOverloadedBooleanValue&&t===!1}var i=n(19),a=(n(4),n(318),n(7),n(357)),u=(n(2),new RegExp("^["+i.ATTRIBUTE_NAME_START_CHAR+"]["+i.ATTRIBUTE_NAME_CHAR+"]*$")),s={},c={},l={createMarkupForID:function(e){return i.ID_ATTRIBUTE_NAME+"="+a(e)},setAttributeForID:function(e,t){e.setAttribute(i.ID_ATTRIBUTE_NAME,t)},createMarkupForRoot:function(){return i.ROOT_ATTRIBUTE_NAME+'=""'},setAttributeForRoot:function(e){e.setAttribute(i.ROOT_ATTRIBUTE_NAME,"")},createMarkupForProperty:function(e,t){var n=i.properties.hasOwnProperty(e)?i.properties[e]:null;if(n){if(o(n,t))return"";var r=n.attributeName;return n.hasBooleanValue||n.hasOverloadedBooleanValue&&t===!0?r+'=""':r+"="+a(t)}return i.isCustomAttribute(e)?null==t?"":e+"="+a(t):null},createMarkupForCustomAttribute:function(e,t){return r(e)&&null!=t?e+"="+a(t):""},setValueForProperty:function(e,t,n){var r=i.properties.hasOwnProperty(t)?i.properties[t]:null;if(r){var a=r.mutationMethod;if(a)a(e,n);else{if(o(r,n))return void this.deleteValueForProperty(e,t);if(r.mustUseProperty){var u=r.propertyName;r.hasSideEffects&&""+e[u]==""+n||(e[u]=n)}else{var s=r.attributeName,c=r.attributeNamespace;c?e.setAttributeNS(c,s,""+n):r.hasBooleanValue||r.hasOverloadedBooleanValue&&n===!0?e.setAttribute(s,""):e.setAttribute(s,""+n)}}}else if(i.isCustomAttribute(t))return void l.setValueForAttribute(e,t,n)},setValueForAttribute:function(e,t,n){r(t)&&(null==n?e.removeAttribute(t):e.setAttribute(t,""+n))},deleteValueForProperty:function(e,t){var n=i.properties.hasOwnProperty(t)?i.properties[t]:null;if(n){var r=n.mutationMethod;if(r)r(e,void 0);else if(n.mustUseProperty){var o=n.propertyName;n.hasBooleanValue?e[o]=!1:n.hasSideEffects&&""+e[o]==""||(e[o]="")}else e.removeAttribute(n.attributeName)}else i.isCustomAttribute(t)&&e.removeAttribute(t)}};e.exports=l},function(e,t,n){"use strict";function r(e){return e===g.topMouseUp||e===g.topTouchEnd||e===g.topTouchCancel}function o(e){return e===g.topMouseMove||e===g.topTouchMove}function i(e){return e===g.topMouseDown||e===g.topTouchStart}function a(e,t,n,r){var o=e.type||"unknown-event";e.currentTarget=b.getNodeFromInstance(r),t?v.invokeGuardedCallbackWithCatch(o,n,e):v.invokeGuardedCallback(o,n,e),e.currentTarget=null}function u(e,t){var n=e._dispatchListeners,r=e._dispatchInstances;if(Array.isArray(n))for(var o=0;o<n.length&&!e.isPropagationStopped();o++)a(e,t,n[o],r[o]);else n&&a(e,t,n,r);e._dispatchListeners=null,e._dispatchInstances=null}function s(e){var t=e._dispatchListeners,n=e._dispatchInstances;if(Array.isArray(t)){for(var r=0;r<t.length&&!e.isPropagationStopped();r++)if(t[r](e,n[r]))return n[r]}else if(t&&t(e,n))return n;return null}function c(e){var t=s(e);return e._dispatchInstances=null,e._dispatchListeners=null,t}function l(e){var t=e._dispatchListeners,n=e._dispatchInstances;Array.isArray(t)?m(!1):void 0,e.currentTarget=t?b.getNodeFromInstance(n):null;var r=t?t(e):null;return e.currentTarget=null,e._dispatchListeners=null,e._dispatchInstances=null,r}function f(e){return!!e._dispatchListeners}var p,d,h=n(12),v=n(76),m=n(1),y=(n(2),{injectComponentTree:function(e){p=e},injectTreeTraversal:function(e){d=e}}),g=h.topLevelTypes,b={isEndish:r,isMoveish:o,isStartish:i,executeDirectDispatch:l,executeDispatchesInOrder:u,executeDispatchesInOrderStopAtTrue:c,hasDispatches:f,getInstanceFromNode:function(e){return p.getInstanceFromNode(e)},getNodeFromInstance:function(e){return p.getNodeFromInstance(e)},isAncestor:function(e,t){return d.isAncestor(e,t)},getLowestCommonAncestor:function(e,t){return d.getLowestCommonAncestor(e,t)},getParentInstance:function(e){return d.getParentInstance(e)},traverseTwoPhase:function(e,t,n){return d.traverseTwoPhase(e,t,n)},traverseEnterLeave:function(e,t,n,r,o){return d.traverseEnterLeave(e,t,n,r,o)},injection:y};e.exports=b},function(e,t){"use strict";function n(e){var t=/[=:]/g,n={"=":"=0",":":"=2"},r=(""+e).replace(t,function(e){return n[e]});return"$"+r}function r(e){var t=/(=0|=2)/g,n={"=0":"=","=2":":"},r="."===e[0]&&"$"===e[1]?e.substring(2):e.substring(1);return(""+r).replace(t,function(e){return n[e]})}var o={escape:n,unescape:r};e.exports=o},function(e,t,n){"use strict";function r(e){null!=e.checkedLink&&null!=e.valueLink?c(!1):void 0}function o(e){r(e),null!=e.value||null!=e.onChange?c(!1):void 0}function i(e){r(e),null!=e.checked||null!=e.onChange?c(!1):void 0}function a(e){if(e){var t=e.getName();if(t)return" Check the render method of `"+t+"`."}return""}var u=n(332),s=n(79),c=n(1),l=(n(2),{button:!0,checkbox:!0,image:!0,hidden:!0,radio:!0,reset:!0,submit:!0}),f={value:function(e,t,n){return!e[t]||l[e.type]||e.onChange||e.readOnly||e.disabled?null:new Error("You provided a `value` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultValue`. Otherwise, set either `onChange` or `readOnly`.")},checked:function(e,t,n){return!e[t]||e.onChange||e.readOnly||e.disabled?null:new Error("You provided a `checked` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultChecked`. Otherwise, set either `onChange` or `readOnly`.")},onChange:u.func},p={},d={checkPropTypes:function(e,t,n){for(var r in f){if(f.hasOwnProperty(r))var o=f[r](t,r,e,s.prop);o instanceof Error&&!(o.message in p)&&(p[o.message]=!0,a(n))}},getValue:function(e){return e.valueLink?(o(e),e.valueLink.value):e.value},getChecked:function(e){return e.checkedLink?(i(e),e.checkedLink.value):e.checked},executeOnChange:function(e,t){return e.valueLink?(o(e),e.valueLink.requestChange(t.target.value)):e.checkedLink?(i(e),e.checkedLink.requestChange(t.target.checked)):e.onChange?e.onChange.call(void 0,t):void 0}};e.exports=d},function(e,t,n){"use strict";var r=n(1),o=!1,i={unmountIDFromEnvironment:null,replaceNodeWithMarkup:null,processChildrenUpdates:null,injection:{injectEnvironment:function(e){o?r(!1):void 0,i.unmountIDFromEnvironment=e.unmountIDFromEnvironment,i.replaceNodeWithMarkup=e.replaceNodeWithMarkup,i.processChildrenUpdates=e.processChildrenUpdates,o=!0}}};e.exports=i},function(e,t,n){"use strict";function r(e,t,n,r){try{return t(n,r)}catch(e){return void(null===o&&(o=e))}}var o=null,i={invokeGuardedCallback:r,invokeGuardedCallbackWithCatch:r,rethrowCaughtError:function(){if(o){var e=o;throw o=null,e}}};e.exports=i},function(e,t){"use strict";var n={remove:function(e){e._reactInternalInstance=void 0},get:function(e){return e._reactInternalInstance},has:function(e){return void 0!==e._reactInternalInstance},set:function(e,t){e._reactInternalInstance=t}};e.exports=n},function(e,t,n){"use strict";var r={};e.exports=r},function(e,t,n){"use strict";var r=n(32),o=r({prop:null,context:null,childContext:null});e.exports=o},function(e,t){"use strict";var n=function(e){return"undefined"!=typeof MSApp&&MSApp.execUnsafeLocalFunction?function(t,n,r,o){MSApp.execUnsafeLocalFunction(function(){return e(t,n,r,o)})}:e};e.exports=n},function(e,t){"use strict";function n(e){var t,n=e.keyCode;return"charCode"in e?(t=e.charCode,0===t&&13===n&&(t=13)):t=n,t>=32||13===t?t:0}e.exports=n},function(e,t){"use strict";function n(e){var t=this,n=t.nativeEvent;if(n.getModifierState)return n.getModifierState(e);var r=o[e];return!!r&&!!n[r]}function r(e){return n}var o={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};e.exports=r},function(e,t){"use strict";function n(e){var t=e.target||e.srcElement||window;return t.correspondingUseElement&&(t=t.correspondingUseElement),3===t.nodeType?t.parentNode:t}e.exports=n},function(e,t,n){"use strict";function r(e){return"function"==typeof e&&"undefined"!=typeof e.prototype&&"function"==typeof e.prototype.mountComponent&&"function"==typeof e.prototype.receiveComponent}function o(e){var t,n=null===e||e===!1;if(n)t=u.create(o);else if("object"==typeof e){var i=e;!i||"function"!=typeof i.type&&"string"!=typeof i.type?c(!1):void 0,t="string"==typeof i.type?s.createInternalComponent(i):r(i.type)?new i.type(i):new l(i)}else"string"==typeof e||"number"==typeof e?t=s.createInstanceForText(e):c(!1);return t._mountIndex=0,t._mountImage=null,t}var i=n(3),a=n(309),u=n(144),s=n(150),c=(n(7),n(1)),l=(n(2),function(e){this.construct(e)});i(l.prototype,a.Mixin,{_instantiateReactComponent:o}),e.exports=o},function(e,t,n){"use strict";/** * Checks if an event is supported in the current execution environment. * * NOTE: This will not work correctly for non-generic events such as `change`, * `reset`, `load`, `error`, and `select`. * * Borrows from Modernizr. * * @param {string} eventNameSuffix Event name, e.g. "click". * @param {?boolean} capture Check if the capture phase is supported. * @return {boolean} True if the event is supported. * @internal * @license Modernizr 3.0.0pre (Custom Build) | MIT */ function r(e,t){if(!i.canUseDOM||t&&!("addEventListener"in document))return!1;var n="on"+e,r=n in document;if(!r){var a=document.createElement("div");a.setAttribute(n,"return;"),r="function"==typeof a[n]}return!r&&o&&"wheel"===e&&(r=document.implementation.hasFeature("Events.wheel","3.0")),r}var o,i=n(6);i.canUseDOM&&(o=document.implementation&&document.implementation.hasFeature&&document.implementation.hasFeature("","")!==!0),e.exports=r},function(e,t,n){"use strict";var r=n(6),o=/^[ \r\n\t\f]/,i=/<(!--|link|noscript|meta|script|style)[ \r\n\t\f\/>]/,a=n(80),u=a(function(e,t){e.innerHTML=t});if(r.canUseDOM){var s=document.createElement("div");s.innerHTML=" ",""===s.innerHTML&&(u=function(e,t){if(e.parentNode&&e.parentNode.replaceChild(e,e),o.test(t)||"<"===t[0]&&i.test(t)){e.innerHTML=String.fromCharCode(65279)+t;var n=e.firstChild;1===n.data.length?e.removeChild(n):n.deleteData(0,1)}else e.innerHTML=t}),s=null}e.exports=u},function(e,t){"use strict";function n(e,t){var n=null===e||e===!1,r=null===t||t===!1;if(n||r)return n===r;var o=typeof e,i=typeof t;return"string"===o||"number"===o?"string"===i||"number"===i:"object"===i&&e.type===t.type&&e.key===t.key}e.exports=n},function(e,t,n){"use strict";function r(e,t){return e&&"object"==typeof e&&null!=e.key?c.escape(e.key):t.toString(36)}function o(e,t,n,i){var p=typeof e;if("undefined"!==p&&"boolean"!==p||(e=null),null===e||"string"===p||"number"===p||a.isValidElement(e))return n(i,e,""===t?l+r(e,0):t),1;var d,h,v=0,m=""===t?l:t+f;if(Array.isArray(e))for(var y=0;y<e.length;y++)d=e[y],h=m+r(d,y),v+=o(d,h,n,i);else{var g=u(e);if(g){var b,_=g.call(e);if(g!==e.entries)for(var x=0;!(b=_.next()).done;)d=b.value,h=m+r(d,x++),v+=o(d,h,n,i);else for(;!(b=_.next()).done;){var E=b.value;E&&(d=E[1],h=m+c.escape(E[0])+f+r(d,0),v+=o(d,h,n,i))}}else"object"===p&&(String(e),s(!1))}return v}function i(e,t,n){return null==e?0:o(e,"",t,n)}var a=(n(20),n(17)),u=n(160),s=n(1),c=n(73),l=(n(2),"."),f=":";e.exports=i},function(e,t,n){"use strict";var r=(n(3),n(9)),o=(n(2),r);e.exports=o},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ARRAY_INSERT="redux-form/ARRAY_INSERT",t.ARRAY_POP="redux-form/ARRAY_POP",t.ARRAY_PUSH="redux-form/ARRAY_PUSH",t.ARRAY_REMOVE="redux-form/ARRAY_REMOVE",t.ARRAY_SHIFT="redux-form/ARRAY_SHIFT",t.ARRAY_SPLICE="redux-form/ARRAY_SPLICE",t.ARRAY_UNSHIFT="redux-form/ARRAY_UNSHIFT",t.ARRAY_SWAP="redux-form/ARRAY_SWAP",t.BLUR="redux-form/BLUR",t.CHANGE="redux-form/CHANGE",t.DESTROY="redux-form/DESTROY",t.FOCUS="redux-form/FOCUS",t.INITIALIZE="redux-form/INITIALIZE",t.REGISTER_FIELD="redux-form/REGISTER_FIELD",t.RESET="redux-form/RESET",t.SET_SUBMIT_FAILED="redux-form/SET_SUBMIT_FAILED",t.START_ASYNC_VALIDATION="redux-form/START_ASYNC_VALIDATION",t.START_SUBMIT="redux-form/START_SUBMIT",t.STOP_ASYNC_VALIDATION="redux-form/STOP_ASYNC_VALIDATION",t.STOP_SUBMIT="redux-form/STOP_SUBMIT",t.TOUCH="redux-form/TOUCH",t.UNREGISTER_FIELD="redux-form/UNREGISTER_FIELD",t.UNTOUCH="redux-form/UNTOUCH"},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(5),i=r(o),a=n(92),u=r(a),s=function(e){var t=e.source,n=e.language;return i.default.createElement(u.default,{content:"```"+n+t+"```"})};s.defaultProps={language:"js"},t.default=s},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(5),i=r(o),a=n(68),u=r(a),s=n(187),c=r(s),l=function(e){return e.replace(/```(?:javascript|js)([\s\S]+?)```/g,function(e,t){return'<pre class="language-jsx"><code class="language-jsx">'+c.default.highlight(t,c.default.languages.jsx)+"</code></pre>"})},f=function(e){var t=e.content;return i.default.createElement("div",{dangerouslySetInnerHTML:{__html:(0,u.default)(l(t))}})};t.default=f},function(e,t,n){var r,o;/*! Copyright (c) 2016 Jed Watson. Licensed under the MIT License (MIT), see http://jedwatson.github.io/classnames */ !function(){"use strict";function n(){for(var e=[],t=0;t<arguments.length;t++){var r=arguments[t];if(r){var o=typeof r;if("string"===o||"number"===o)e.push(r);else if(Array.isArray(r))e.push(n.apply(null,r));else if("object"===o)for(var a in r)i.call(r,a)&&r[a]&&e.push(a)}}return e.join(" ")}var i={}.hasOwnProperty;"undefined"!=typeof e&&e.exports?e.exports=n:(r=[],o=function(){return n}.apply(t,r),!(void 0!==o&&(e.exports=o)))}()},function(e,t,n){"use strict";var r=n(9),o={listen:function(e,t,n){return e.addEventListener?(e.addEventListener(t,n,!1),{remove:function(){e.removeEventListener(t,n,!1)}}):e.attachEvent?(e.attachEvent("on"+t,n),{remove:function(){e.detachEvent("on"+t,n)}}):void 0},capture:function(e,t,n){return e.addEventListener?(e.addEventListener(t,n,!0),{remove:function(){e.removeEventListener(t,n,!0)}}):{remove:r}},registerDefault:function(){}};e.exports=o},function(e,t){"use strict";function n(e){try{e.focus()}catch(e){}}e.exports=n},function(e,t){"use strict";function n(){if("undefined"==typeof document)return null;try{return document.activeElement||document.body}catch(e){return document.body}}e.exports=n},function(e,t,n){"use strict";function r(e){return a?void 0:i(!1),p.hasOwnProperty(e)||(e="*"),u.hasOwnProperty(e)||("*"===e?a.innerHTML="<link />":a.innerHTML="<"+e+"></"+e+">",u[e]=!a.firstChild),u[e]?p[e]:null}var o=n(6),i=n(1),a=o.canUseDOM?document.createElement("div"):null,u={},s=[1,'<select multiple="true">',"</select>"],c=[1,"<table>","</table>"],l=[3,"<table><tbody><tr>","</tr></tbody></table>"],f=[1,'<svg xmlns="http://www.w3.org/2000/svg">',"</svg>"],p={"*":[1,"?<div>","</div>"],area:[1,"<map>","</map>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],legend:[1,"<fieldset>","</fieldset>"],param:[1,"<object>","</object>"],tr:[2,"<table><tbody>","</tbody></table>"],optgroup:s,option:s,caption:c,colgroup:c,tbody:c,tfoot:c,thead:c,td:l,th:l},d=["circle","clipPath","defs","ellipse","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","text","tspan"];d.forEach(function(e){p[e]=f,u[e]=!0}),e.exports=r},function(e,t){"use strict";var n={childContextTypes:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,mixins:!0,propTypes:!0,type:!0},r={name:!0,length:!0,prototype:!0,caller:!0,arguments:!0,arity:!0},o="function"==typeof Object.getOwnPropertySymbols;e.exports=function(e,t,i){if("string"!=typeof t){var a=Object.getOwnPropertyNames(t);o&&(a=a.concat(Object.getOwnPropertySymbols(t)));for(var u=0;u<a.length;++u)if(!(n[a[u]]||r[a[u]]||i&&i[a[u]]))try{e[a[u]]=t[a[u]]}catch(e){}}return e}},function(e,t,n){function r(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=void 0}var o=n(59),i=n(61);r.prototype=o(i.prototype),r.prototype.constructor=r,e.exports=r},function(e,t,n){var r=n(22),o=n(8),i=r(o,"Map");e.exports=i},function(e,t,n){function r(e){this.__data__=new o(e)}var o=n(34),i=n(270),a=n(271),u=n(272),s=n(273),c=n(274);r.prototype.clear=i,r.prototype.delete=a,r.prototype.get=u,r.prototype.has=s,r.prototype.set=c,e.exports=r},function(e,t,n){var r=n(8),o=r.Symbol;e.exports=o},function(e,t,n){var r=n(22),o=n(8),i=r(o,"WeakMap");e.exports=i},function(e,t){function n(e,t){for(var n=-1,r=e?e.length:0;++n<r;)if(t(e[n],n,e))return!0;return!1}e.exports=n},function(e,t,n){function r(e,t){return e&&o(e,t,i)}var o=n(214),i=n(66);e.exports=r},function(e,t,n){function r(e,t){t=i(t,e)?[t]:o(t);for(var n=0,r=t.length;null!=e&&n<r;)e=e[a(t[n++])];return n&&n==r?e:void 0}var o=n(111),i=n(40),a=n(26);e.exports=r},function(e,t,n){function r(e,t){return null!=e&&(a.call(e,t)||"object"==typeof e&&t in e&&null===o(e))}var o=n(119),i=Object.prototype,a=i.hasOwnProperty;e.exports=r},function(e,t,n){function r(e){return"function"==typeof e?e:null==e?a:"object"==typeof e?u(e)?i(e[0],e[1]):o(e):s(e)}var o=n(220),i=n(221),a=n(127),u=n(11),s=n(284);e.exports=r},function(e,t){function n(e){return function(t){return null==t?void 0:t[e]}}e.exports=n},function(e,t,n){var r=n(127),o=n(122),i=o?function(e,t){return o.set(e,t),e}:r;e.exports=i},function(e,t,n){function r(e){return o(e)?e:i(e)}var o=n(11),i=n(124);e.exports=r},function(e,t){function n(e,t,n,o){for(var i=-1,a=e.length,u=n.length,s=-1,c=t.length,l=r(a-u,0),f=Array(c+l),p=!o;++s<c;)f[s]=t[s];for(;++i<u;)(p||i<a)&&(f[n[i]]=e[i]);for(;l--;)f[s++]=e[i++];return f}var r=Math.max;e.exports=n},function(e,t){function n(e,t,n,o){for(var i=-1,a=e.length,u=-1,s=n.length,c=-1,l=t.length,f=r(a-s,0),p=Array(f+l),d=!o;++i<f;)p[i]=e[i];for(var h=i;++c<l;)p[h+c]=t[c];for(;++u<s;)(d||i<a)&&(p[h+n[u]]=e[i++]);return p}var r=Math.max;e.exports=n},function(e,t,n){function r(e,t,n,b,_,x,E,w,S,C){function P(){for(var d=arguments.length,h=Array(d),v=d;v--;)h[v]=arguments[v];if(A)var m=c(P),y=a(h,m);if(b&&(h=o(h,b,_,A)),x&&(h=i(h,x,E,A)),d-=y,A&&d<C){var g=f(h,m);return s(e,t,r,P.placeholder,n,h,g,w,S,C-d)}var I=T?n:this,N=k?I[e]:e;return d=h.length,w?h=l(h,w):R&&d>1&&h.reverse(),O&&S<d&&(h.length=S),this&&this!==p&&this instanceof P&&(N=M||u(N)),N.apply(I,h)}var O=t&y,T=t&d,k=t&h,A=t&(v|m),R=t&g,M=k?void 0:u(e);return P}var o=n(112),i=n(113),a=n(228),u=n(36),s=n(115),c=n(37),l=n(266),f=n(25),p=n(8),d=1,h=2,v=8,m=16,y=128,g=512;e.exports=r},function(e,t,n){function r(e,t,n,r,p,d,h,v,m,y){var g=t&c,b=g?h:void 0,_=g?void 0:h,x=g?d:void 0,E=g?void 0:d;t|=g?l:f,t&=~(g?f:l),t&s||(t&=~(a|u));var w=[e,t,p,x,b,E,_,v,m,y],S=n.apply(void 0,w);return o(e)&&i(S,w),S.placeholder=r,S}var o=n(250),i=n(123),a=1,u=2,s=4,c=8,l=32,f=64;e.exports=r},function(e,t,n){function r(e,t,n,r,x,E,w,S){var C=t&v;if(!C&&"function"!=typeof e)throw new TypeError(d);var P=r?r.length:0;if(P||(t&=~(g|b),r=x=void 0),w=void 0===w?w:_(p(w),0),S=void 0===S?S:p(S),P-=x?x.length:0,t&b){var O=r,T=x;r=x=void 0}var k=C?void 0:c(e),A=[e,t,n,r,x,O,T,E,w,S];if(k&&l(A,k),e=A[0],t=A[1],n=A[2],r=A[3],x=A[4],S=A[9]=null==A[9]?C?0:e.length:_(A[9]-P,0),!S&&t&(m|y)&&(t&=~(m|y)),t&&t!=h)R=t==m||t==y?a(e,t,S):t!=g&&t!=(h|g)||x.length?u.apply(void 0,A):s(e,t,n,r);else var R=i(e,t,n);var M=k?o:f;return M(R,A)}var o=n(110),i=n(231),a=n(232),u=n(114),s=n(233),c=n(118),l=n(264),f=n(123),p=n(132),d="Expected a function",h=1,v=2,m=8,y=16,g=32,b=64,_=Math.max;e.exports=r},function(e,t,n){function r(e,t,n,r,s,c){var l=s&u,f=e.length,p=t.length;if(f!=p&&!(l&&p>f))return!1;var d=c.get(e);if(d)return d==t;var h=-1,v=!0,m=s&a?new o:void 0;for(c.set(e,t);++h<f;){var y=e[h],g=t[h];if(r)var b=l?r(g,y,h,t,e,c):r(y,g,h,e,t,c);if(void 0!==b){if(b)continue;v=!1;break}if(m){if(!i(t,function(e,t){if(!m.has(t)&&(y===e||n(y,e,r,s,c)))return m.add(t)})){v=!1;break}}else if(y!==g&&!n(y,g,r,s,c)){v=!1;break}}return c.delete(e),v}var o=n(210),i=n(104),a=1,u=2;e.exports=r},function(e,t,n){var r=n(122),o=n(130),i=r?function(e){return r.get(e)}:o;e.exports=i},function(e,t){function n(e){return r(Object(e))}var r=Object.getPrototypeOf;e.exports=n},function(e,t,n){function r(e){return e===e&&!o(e)}var o=n(15);e.exports=r},function(e,t){function n(e,t){return function(n){return null!=n&&n[e]===t&&(void 0!==t||e in Object(n))}}e.exports=n},function(e,t,n){var r=n(103),o=r&&new r;e.exports=o},function(e,t,n){var r=n(110),o=n(282),i=150,a=16,u=function(){var e=0,t=0;return function(n,u){var s=o(),c=a-(s-t);if(t=s,c>0){if(++e>=i)return n}else e=0;return r(n,u)}}();e.exports=u},function(e,t,n){var r=n(281),o=n(288),i=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(\.|\[\])(?:\4|$))/g,a=/\\(\\)?/g,u=r(function(e){var t=[];return o(e).replace(i,function(e,n,r,o){t.push(r?o.replace(a,"$1"):n||e)}),t});e.exports=u},function(e,t){function n(e){if(null!=e){try{return r.call(e)}catch(e){}try{return e+""}catch(e){}}return""}var r=Function.prototype.toString;e.exports=n},function(e,t){function n(e,t){return e===t||e!==e&&t!==t}e.exports=n},function(e,t){function n(e){return e}e.exports=n},function(e,t,n){function r(e){return o(e)&&u.call(e,"callee")&&(!c.call(e,"callee")||s.call(e)==i)}var o=n(278),i="[object Arguments]",a=Object.prototype,u=a.hasOwnProperty,s=a.toString,c=a.propertyIsEnumerable;e.exports=r},function(e,t,n){function r(e){return"string"==typeof e||!o(e)&&i(e)&&s.call(e)==a}var o=n(11),i=n(18),a="[object String]",u=Object.prototype,s=u.toString;e.exports=r},function(e,t){function n(){}e.exports=n},function(e,t,n){function r(e,t){if("function"!=typeof e)throw new TypeError(a);return t=u(void 0===t?e.length-1:i(t),0),function(){for(var n=arguments,r=-1,i=u(n.length-t,0),a=Array(i);++r<i;)a[r]=n[t+r];switch(t){case 0:return e.call(this,a);case 1:return e.call(this,n[0],a);case 2:return e.call(this,n[0],n[1],a)}var s=Array(t+1);for(r=-1;++r<t;)s[r]=n[r];return s[t]=a,o(e,this,s)}}var o=n(58),i=n(132),a="Expected a function",u=Math.max;e.exports=r},function(e,t,n){function r(e){var t=o(e),n=t%1;return t===t?n?t-n:t:0}var o=n(286);e.exports=r},function(e,t,n){"use strict";t.__esModule=!0;var r=n(5);t.default=r.PropTypes.shape({subscribe:r.PropTypes.func.isRequired,dispatch:r.PropTypes.func.isRequired,getState:r.PropTypes.func.isRequired})},function(e,t){"use strict";function n(e){"undefined"!=typeof console&&"function"==typeof console.error&&console.error(e);try{throw new Error(e)}catch(e){}}t.__esModule=!0,t.default=n},function(e,t){"use strict";function n(e,t){return e+t.charAt(0).toUpperCase()+t.substring(1)}var r={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridRow:!0,gridColumn:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},o=["Webkit","ms","Moz","O"];Object.keys(r).forEach(function(e){o.forEach(function(t){r[n(t,e)]=r[e]})});var i={background:{backgroundAttachment:!0,backgroundColor:!0,backgroundImage:!0,backgroundPositionX:!0,backgroundPositionY:!0,backgroundRepeat:!0},backgroundPosition:{backgroundPositionX:!0,backgroundPositionY:!0},border:{borderWidth:!0,borderStyle:!0,borderColor:!0},borderBottom:{borderBottomWidth:!0,borderBottomStyle:!0,borderBottomColor:!0},borderLeft:{borderLeftWidth:!0,borderLeftStyle:!0,borderLeftColor:!0},borderRight:{borderRightWidth:!0,borderRightStyle:!0,borderRightColor:!0},borderTop:{borderTopWidth:!0,borderTopStyle:!0,borderTopColor:!0},font:{fontStyle:!0,fontVariant:!0,fontWeight:!0,fontSize:!0,lineHeight:!0,fontFamily:!0},outline:{outlineWidth:!0,outlineStyle:!0,outlineColor:!0}},a={isUnitlessNumber:r,shorthandPropertyExpansions:i};e.exports=a},function(e,t,n){"use strict";function r(){this._callbacks=null,this._contexts=null}var o=n(3),i=n(16),a=n(1);o(r.prototype,{enqueue:function(e,t){this._callbacks=this._callbacks||[],this._contexts=this._contexts||[],this._callbacks.push(e),this._contexts.push(t)},notifyAll:function(){var e=this._callbacks,t=this._contexts;if(e){e.length!==t.length?a(!1):void 0,this._callbacks=null,this._contexts=null;for(var n=0;n<e.length;n++)e[n].call(t[n]);e.length=0,t.length=0}},checkpoint:function(){return this._callbacks?this._callbacks.length:0},rollback:function(e){this._callbacks&&(this._callbacks.length=e,this._contexts.length=e)},reset:function(){this._callbacks=null,this._contexts=null},destructor:function(){this.reset()}}),i.addPoolingTo(r),e.exports=r},function(e,t){"use strict";var n={html:"http://www.w3.org/1999/xhtml",mathml:"http://www.w3.org/1998/Math/MathML",svg:"http://www.w3.org/2000/svg"};e.exports=n},function(e,t,n){"use strict";var r=n(70),o=n(316),i={processChildrenUpdates:o.dangerouslyProcessChildrenUpdates,replaceNodeWithMarkup:r.dangerouslyReplaceNodeWithMarkup,unmountIDFromEnvironment:function(e){}};e.exports=i},function(e,t){"use strict";var n={hasCachedChildNodes:1};e.exports=n},function(e,t,n){"use strict";function r(e,t){var n={_topLevelWrapper:e,_idCounter:1,_ownerDocument:t?t.nodeType===o?t:t.ownerDocument:null,_node:t,_tag:t?t.nodeName.toLowerCase():null,_namespaceURI:t?t.namespaceURI:null};return n}var o=(n(89),9);e.exports=r},function(e,t,n){"use strict";function r(){if(this._rootNodeID&&this._wrapperState.pendingUpdate){this._wrapperState.pendingUpdate=!1;var e=this._currentElement.props,t=s.getValue(e);null!=t&&o(this,Boolean(e.multiple),t)}}function o(e,t,n){var r,o,i=c.getNodeFromInstance(e).options;if(t){for(r={},o=0;o<n.length;o++)r[""+n[o]]=!0;for(o=0;o<i.length;o++){var a=r.hasOwnProperty(i[o].value);i[o].selected!==a&&(i[o].selected=a)}}else{for(r=""+n,o=0;o<i.length;o++)if(i[o].value===r)return void(i[o].selected=!0);i.length&&(i[0].selected=!0)}}function i(e){var t=this._currentElement.props,n=s.executeOnChange(t,e);return this._rootNodeID&&(this._wrapperState.pendingUpdate=!0),l.asap(r,this),n}var a=n(3),u=n(47),s=n(74),c=n(4),l=n(10),f=(n(2),!1),p={getNativeProps:function(e,t){return a({},u.getNativeProps(e,t),{onChange:e._wrapperState.onChange,value:void 0})},mountWrapper:function(e,t){var n=s.getValue(t);e._wrapperState={pendingUpdate:!1,initialValue:null!=n?n:t.defaultValue,listeners:null,onChange:i.bind(e),wasMultiple:Boolean(t.multiple)},void 0===t.value||void 0===t.defaultValue||f||(f=!0)},getSelectValueContext:function(e){return e._wrapperState.initialValue},postUpdateWrapper:function(e){var t=e._currentElement.props;e._wrapperState.initialValue=void 0;var n=e._wrapperState.wasMultiple;e._wrapperState.wasMultiple=Boolean(t.multiple);var r=s.getValue(t);null!=r?(e._wrapperState.pendingUpdate=!1,o(e,Boolean(t.multiple),r)):n!==Boolean(t.multiple)&&(null!=t.defaultValue?o(e,Boolean(t.multiple),t.defaultValue):o(e,Boolean(t.multiple),t.multiple?[]:""))}};e.exports=p},function(e,t,n){"use strict";function r(){this.reinitializeTransaction()}var o=n(3),i=n(10),a=n(51),u=n(9),s={initialize:u,close:function(){p.isBatchingUpdates=!1}},c={initialize:u,close:i.flushBatchedUpdates.bind(i)},l=[c,s];o(r.prototype,a.Mixin,{getTransactionWrappers:function(){return l}});var f=new r,p={isBatchingUpdates:!1,batchedUpdates:function(e,t,n,r,o,i){var a=p.isBatchingUpdates;p.isBatchingUpdates=!0,a?e(t,n,r,o,i):f.perform(e,null,t,n,r,o,i)}};e.exports=p},function(e,t,n){"use strict";function r(){E||(E=!0,y.EventEmitter.injectReactEventListener(m),y.EventPluginHub.injectEventPluginOrder(a),y.EventPluginUtils.injectComponentTree(f),y.EventPluginUtils.injectTreeTraversal(d),y.EventPluginHub.injectEventPluginsByName({SimpleEventPlugin:x,EnterLeaveEventPlugin:u,ChangeEventPlugin:i,SelectEventPlugin:_,BeforeInputEventPlugin:o}),y.NativeComponent.injectGenericComponentClass(l),y.NativeComponent.injectTextComponentClass(h),y.DOMProperty.injectDOMPropertyConfig(s),y.DOMProperty.injectDOMPropertyConfig(b),y.EmptyComponent.injectEmptyComponentFactory(function(e){return new p(e)}),y.Updates.injectReconcileTransaction(g),y.Updates.injectBatchingStrategy(v),y.Component.injectEnvironment(c))}var o=n(297),i=n(299),a=n(301),u=n(302),s=n(304),c=n(138),l=n(312),f=n(4),p=n(314),d=n(324),h=n(322),v=n(142),m=n(328),y=n(329),g=n(333),b=n(337),_=n(338),x=n(339),E=!1;e.exports={inject:r}},function(e,t){"use strict";var n,r={injectEmptyComponentFactory:function(e){n=e}},o={create:function(e){return n(e)}};o.injection=r,e.exports=o},function(e,t){"use strict";var n={logTopLevelRenders:!1};e.exports=n},function(e,t,n){"use strict";function r(e){return i(document.documentElement,e)}var o=n(320),i=n(195),a=n(95),u=n(96),s={hasSelectionCapabilities:function(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&("input"===t&&"text"===e.type||"textarea"===t||"true"===e.contentEditable)},getSelectionInformation:function(){var e=u();return{focusedElem:e,selectionRange:s.hasSelectionCapabilities(e)?s.getSelection(e):null}},restoreSelection:function(e){var t=u(),n=e.focusedElem,o=e.selectionRange;t!==n&&r(n)&&(s.hasSelectionCapabilities(n)&&s.setSelection(n,o),a(n))},getSelection:function(e){var t;if("selectionStart"in e)t={start:e.selectionStart,end:e.selectionEnd};else if(document.selection&&e.nodeName&&"input"===e.nodeName.toLowerCase()){var n=document.selection.createRange();n.parentElement()===e&&(t={start:-n.moveStart("character",-e.value.length),end:-n.moveEnd("character",-e.value.length)})}else t=o.getOffsets(e);return t||{start:0,end:0}},setSelection:function(e,t){var n=t.start,r=t.end;if(void 0===r&&(r=n),"selectionStart"in e)e.selectionStart=n,e.selectionEnd=Math.min(r,e.value.length);else if(document.selection&&e.nodeName&&"input"===e.nodeName.toLowerCase()){var i=e.createTextRange();i.collapse(!0),i.moveStart("character",n),i.moveEnd("character",r-n),i.select()}else o.setOffsets(e,t)}};e.exports=s},function(e,t,n){"use strict";var r=n(350),o=/\/?>/,i=/^<\!\-\-/,a={CHECKSUM_ATTR_NAME:"data-react-checksum",addChecksumToMarkup:function(e){var t=r(e);return i.test(e)?e:e.replace(o," "+a.CHECKSUM_ATTR_NAME+'="'+t+'"$&')},canReuseMarkup:function(e,t){var n=t.getAttribute(a.CHECKSUM_ATTR_NAME);n=n&&parseInt(n,10);var o=r(e);return o===n}};e.exports=a},function(e,t,n){"use strict";function r(e,t){for(var n=Math.min(e.length,t.length),r=0;r<n;r++)if(e.charAt(r)!==t.charAt(r))return r;return e.length===t.length?-1:n}function o(e){return e?e.nodeType===M?e.documentElement:e.firstChild:null}function i(e){return e.getAttribute&&e.getAttribute(k)||""}function a(e,t,n,r,o){var i;if(b.logTopLevelRenders){var a=e._currentElement.props,u=a.type;i="React mount: "+("string"==typeof u?u:u.displayName||u.name),console.time(i)}var s=x.mountComponent(e,n,null,m(e,t),o);i&&console.timeEnd(i),e._renderedComponent._topLevelWrapper=e,D._mountImageIntoNode(s,t,e,r,n)}function u(e,t,n,r){var o=w.ReactReconcileTransaction.getPooled(!n&&y.useCreateElement);o.perform(a,null,e,t,o,n,r),w.ReactReconcileTransaction.release(o)}function s(e,t,n){for(x.unmountComponent(e,n),t.nodeType===M&&(t=t.documentElement);t.lastChild;)t.removeChild(t.lastChild)}function c(e){var t=o(e);if(t){var n=v.getInstanceFromNode(t);return!(!n||!n._nativeParent)}}function l(e){var t=o(e),n=t&&v.getInstanceFromNode(t);return n&&!n._nativeParent?n:null}function f(e){var t=l(e);return t?t._nativeContainerInfo._topLevelWrapper:null}var p=n(23),d=n(19),h=n(49),v=(n(20),n(4)),m=n(140),y=n(315),g=n(17),b=n(145),_=(n(7),n(147)),x=n(21),E=n(154),w=n(10),S=n(24),C=n(84),P=n(1),O=n(86),T=n(87),k=(n(2),d.ID_ATTRIBUTE_NAME),A=d.ROOT_ATTRIBUTE_NAME,R=1,M=9,I=11,N={},j=1,F=function(){this.rootID=j++};F.prototype.isReactComponent={},F.prototype.render=function(){return this.props};var D={TopLevelWrapper:F,_instancesByReactRootID:N,scrollMonitor:function(e,t){t()},_updateRootComponent:function(e,t,n,r){return D.scrollMonitor(n,function(){E.enqueueElementInternal(e,t),r&&E.enqueueCallbackInternal(e,r)}),e},_renderNewRootComponent:function(e,t,n,r){!t||t.nodeType!==R&&t.nodeType!==M&&t.nodeType!==I?P(!1):void 0,h.ensureScrollValueMonitoring();var o=C(e);w.batchedUpdates(u,o,t,n,r);var i=o._instance.rootID;return N[i]=o,o},renderSubtreeIntoContainer:function(e,t,n,r){return null==e||null==e._reactInternalInstance?P(!1):void 0,D._renderSubtreeIntoContainer(e,t,n,r)},_renderSubtreeIntoContainer:function(e,t,n,r){E.validateCallback(r,"ReactDOM.render"),g.isValidElement(t)?void 0:P(!1);var a=g(F,null,null,null,null,null,t),u=f(n);if(u){var s=u._currentElement,l=s.props;if(T(l,t)){var p=u._renderedComponent.getPublicInstance(),d=r&&function(){r.call(p)};return D._updateRootComponent(u,a,n,d),p}D.unmountComponentAtNode(n)}var h=o(n),v=h&&!!i(h),m=c(n),y=v&&!u&&!m,b=D._renderNewRootComponent(a,n,y,null!=e?e._reactInternalInstance._processChildContext(e._reactInternalInstance._context):S)._renderedComponent.getPublicInstance();return r&&r.call(b),b},render:function(e,t,n){return D._renderSubtreeIntoContainer(null,e,t,n)},unmountComponentAtNode:function(e){!e||e.nodeType!==R&&e.nodeType!==M&&e.nodeType!==I?P(!1):void 0;var t=f(e);return t?(delete N[t._instance.rootID],w.batchedUpdates(s,t,e,!1),!0):(c(e),1===e.nodeType&&e.hasAttribute(A),!1)},_mountImageIntoNode:function(e,t,n,i,a){if(!t||t.nodeType!==R&&t.nodeType!==M&&t.nodeType!==I?P(!1):void 0,i){var u=o(t);if(_.canReuseMarkup(e,u))return void v.precacheNode(n,u);var s=u.getAttribute(_.CHECKSUM_ATTR_NAME);u.removeAttribute(_.CHECKSUM_ATTR_NAME);var c=u.outerHTML;u.setAttribute(_.CHECKSUM_ATTR_NAME,s);var l=e,f=r(l,c);" (client) "+l.substring(f-20,f+20)+"\n (server) "+c.substring(f-20,f+20),t.nodeType===M?P(!1):void 0}if(t.nodeType===M?P(!1):void 0,a.useCreateElement){for(;t.lastChild;)t.removeChild(t.lastChild);p.insertTreeBefore(t,e,null)}else O(t,e),v.precacheNode(n,t.firstChild)}};e.exports=D},function(e,t,n){"use strict";var r=n(32),o=r({INSERT_MARKUP:null,MOVE_EXISTING:null,REMOVE_NODE:null,SET_MARKUP:null,TEXT_CONTENT:null});e.exports=o},function(e,t,n){"use strict";function r(e){if("function"==typeof e.type)return e.type;var t=e.type,n=f[t];return null==n&&(f[t]=n=c(t)),n}function o(e){return l?void 0:s(!1),new l(e)}function i(e){return new p(e)}function a(e){return e instanceof p}var u=n(3),s=n(1),c=null,l=null,f={},p=null,d={injectGenericComponentClass:function(e){l=e},injectTextComponentClass:function(e){p=e},injectComponentClasses:function(e){u(f,e)}},h={getComponentClassForElement:r,createInternalComponent:o,createInstanceForText:i,isTextComponent:a,injection:d};e.exports=h},function(e,t,n){"use strict";var r=n(17),o=n(1),i={NATIVE:0,COMPOSITE:1,EMPTY:2,getType:function(e){return null===e||e===!1?i.EMPTY:r.isValidElement(e)?"function"==typeof e.type?i.COMPOSITE:i.NATIVE:void o(!1)}};e.exports=i},function(e,t,n){"use strict";function r(e,t){}var o=(n(2),{isMounted:function(e){return!1},enqueueCallback:function(e,t){},enqueueForceUpdate:function(e){r(e,"forceUpdate")},enqueueReplaceState:function(e,t){r(e,"replaceState")},enqueueSetState:function(e,t){r(e,"setState")}});e.exports=o},function(e,t,n){"use strict";function r(e){this.reinitializeTransaction(),this.renderToStaticMarkup=e,this.useCreateElement=!1}var o=n(3),i=n(16),a=n(51),u=[],s={enqueue:function(){}},c={getTransactionWrappers:function(){return u},getReactMountReady:function(){return s},destructor:function(){},checkpoint:function(){},rollback:function(){}};o(r.prototype,a.Mixin,c),i.addPoolingTo(r),e.exports=r},function(e,t,n){"use strict";function r(e){a.enqueueUpdate(e)}function o(e,t){var n=i.get(e);return n?n:null}var i=(n(20),n(77)),a=n(10),u=n(1),s=(n(2),{isMounted:function(e){var t=i.get(e);return!!t&&!!t._renderedComponent},enqueueCallback:function(e,t,n){s.validateCallback(t,n);var i=o(e);return i?(i._pendingCallbacks?i._pendingCallbacks.push(t):i._pendingCallbacks=[t],void r(i)):null},enqueueCallbackInternal:function(e,t){e._pendingCallbacks?e._pendingCallbacks.push(t):e._pendingCallbacks=[t],r(e)},enqueueForceUpdate:function(e){var t=o(e,"forceUpdate");t&&(t._pendingForceUpdate=!0,r(t))},enqueueReplaceState:function(e,t){var n=o(e,"replaceState");n&&(n._pendingStateQueue=[t],n._pendingReplaceState=!0,r(n))},enqueueSetState:function(e,t){var n=o(e,"setState");if(n){var i=n._pendingStateQueue||(n._pendingStateQueue=[]);i.push(t),r(n)}},enqueueElementInternal:function(e,t){e._pendingElement=t,r(e)},validateCallback:function(e,t){e&&"function"!=typeof e?u(!1):void 0}});e.exports=s},function(e,t){"use strict";e.exports="15.1.0"},function(e,t){"use strict";var n={currentScrollLeft:0,currentScrollTop:0,refreshScrollValues:function(e){n.currentScrollLeft=e.x,n.currentScrollTop=e.y}};e.exports=n},function(e,t,n){"use strict";function r(e,t){if(null==t?o(!1):void 0,null==e)return t;var n=Array.isArray(e),r=Array.isArray(t);return n&&r?(e.push.apply(e,t),e):n?(e.push(t),e):r?[e].concat(t):[e,t]}var o=n(1);e.exports=r},function(e,t,n){"use strict";var r=!1;e.exports=r},function(e,t){"use strict";var n=function(e,t,n){Array.isArray(e)?e.forEach(t,n):e&&t.call(n,e)};e.exports=n},function(e,t){"use strict";function n(e){var t=e&&(r&&e[r]||e[o]);if("function"==typeof t)return t}var r="function"==typeof Symbol&&Symbol.iterator,o="@@iterator";e.exports=n},function(e,t,n){"use strict";function r(e){for(var t;(t=e._renderedNodeType)===o.COMPOSITE;)e=e._renderedComponent;return t===o.NATIVE?e._renderedComponent:t===o.EMPTY?null:void 0}var o=n(151);e.exports=r},function(e,t,n){"use strict";function r(){return!i&&o.canUseDOM&&(i="textContent"in document.documentElement?"textContent":"innerText"),i}var o=n(6),i=null;e.exports=r},function(e,t){"use strict";function n(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&("input"===t&&r[e.type]||"textarea"===t)}var r={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};e.exports=n},function(e,t,n){"use strict";var r=n(6),o=n(52),i=n(86),a=function(e,t){e.textContent=t};r.canUseDOM&&("textContent"in document.documentElement||(a=function(e,t){i(e,o(t))})),e.exports=a},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var u=n(188),s=r(u),c=function(e){function t(e){o(this,t);var n=i(this,Object.getPrototypeOf(t).call(this,"Submit Validation Failed"));return n.errors=e,n}return a(t,e),t}(s.default);t.default=c},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.untouch=t.unregisterField=t.touch=t.setSubmitFailed=t.stopSubmit=t.stopAsyncValidation=t.startSubmit=t.startAsyncValidation=t.reset=t.registerField=t.initialize=t.focus=t.destroy=t.change=t.blur=t.arrayUnshift=t.arraySwap=t.arraySplice=t.arrayShift=t.arrayRemove=t.arrayPush=t.arrayPop=t.arrayInsert=void 0;var r=n(90);t.arrayInsert=function(e,t,n,o){return{type:r.ARRAY_INSERT,meta:{form:e,field:t,index:n},payload:o}},t.arrayPop=function(e,t){return{type:r.ARRAY_POP,meta:{form:e,field:t}}},t.arrayPush=function(e,t,n){return{type:r.ARRAY_PUSH,meta:{form:e,field:t},payload:n}},t.arrayRemove=function(e,t,n){return{type:r.ARRAY_REMOVE,meta:{form:e,field:t,index:n}}},t.arrayShift=function(e,t){return{type:r.ARRAY_SHIFT,meta:{form:e,field:t}}},t.arraySplice=function(e,t,n,o,i){var a={type:r.ARRAY_SPLICE,meta:{form:e,field:t,index:n,removeNum:o}};return void 0!==i&&(a.payload=i),a},t.arraySwap=function(e,t,n,o){if(n===o)throw new Error("Swap indices cannot be equal");if(n<0||o<0)throw new Error("Swap indices cannot be negative");return{type:r.ARRAY_SWAP,meta:{form:e,field:t,indexA:n,indexB:o}}},t.arrayUnshift=function(e,t,n){return{type:r.ARRAY_UNSHIFT,meta:{form:e,field:t},payload:n}},t.blur=function(e,t,n,o){return{type:r.BLUR,meta:{form:e,field:t,touch:o},payload:n}},t.change=function(e,t,n,o){return{type:r.CHANGE,meta:{form:e,field:t,touch:o},payload:n}},t.destroy=function(e){return{type:r.DESTROY,meta:{form:e}}},t.focus=function(e,t){return{type:r.FOCUS,meta:{form:e,field:t}}},t.initialize=function(e,t){return{type:r.INITIALIZE,meta:{form:e},payload:t}},t.registerField=function(e,t,n){return{type:r.REGISTER_FIELD,meta:{form:e},payload:{name:t,type:n}}},t.reset=function(e){return{type:r.RESET,meta:{form:e}}},t.startAsyncValidation=function(e,t){return{type:r.START_ASYNC_VALIDATION,meta:{form:e,field:t}}},t.startSubmit=function(e){return{type:r.START_SUBMIT,meta:{form:e}}},t.stopAsyncValidation=function(e,t){var n={type:r.STOP_ASYNC_VALIDATION,meta:{form:e},payload:t};return t&&Object.keys(t).length&&(n.error=!0),n},t.stopSubmit=function(e,t){var n={type:r.STOP_SUBMIT,meta:{form:e},payload:t};return t&&Object.keys(t).length&&(n.error=!0),n},t.setSubmitFailed=function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),o=1;o<t;o++)n[o-1]=arguments[o];return{type:r.SET_SUBMIT_FAILED,meta:{form:e,fields:n},error:!0}},t.touch=function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),o=1;o<t;o++)n[o-1]=arguments[o];return{type:r.TOUCH,meta:{form:e,fields:n}}},t.unregisterField=function(e,t){return{type:r.UNREGISTER_FIELD,meta:{form:e},payload:{name:t}}},t.untouch=function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),o=1;o<t;o++)n[o-1]=arguments[o];return{type:r.UNTOUCH,meta:{form:e,fields:n}}}},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=t.dataKey="value",r=function(e,t){return function(e){e.dataTransfer.setData(n,t)}};t.default=r},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(169),i=r(o),a=function(e){var t=[];if(e)for(var n=0;n<e.length;n++){var r=e[n];r.selected&&t.push(r.value)}return t},u=function(e,t){if((0,i.default)(e)){if(!t&&e.nativeEvent&&void 0!==e.nativeEvent.text)return e.nativeEvent.text;if(t&&void 0!==e.nativeEvent)return e.nativeEvent.text;var n=e.target,r=n.type,o=n.value,u=n.checked,s=n.files,c=e.dataTransfer;return"checkbox"===r?u:"file"===r?s||c&&c.files:"select-multiple"===r?a(e.target.options):o}return e&&void 0!==e.value?e.value:e};t.default=u},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(e){return!!(e&&e.stopPropagation&&e.preventDefault)};t.default=n},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(169),i=r(o),a=function(e){var t=(0,i.default)(e);return t&&e.preventDefault(),t};t.default=a},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n="undefined"!=typeof window&&window.navigator&&window.navigator.product&&"ReactNative"===window.navigator.product;t.default=n},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}Object.defineProperty(t,"__esModule",{value:!0});var i=n(45),a=r(i),u=function e(t,n){for(var r=arguments.length,o=Array(r>2?r-2:0),i=2;i<r;i++)o[i-2]=arguments[i];if(!t)return t;var a=t[n];return o.length?e.apply(void 0,[a].concat(o)):a},s=function(e,t){return u.apply(void 0,[e].concat(o((0,a.default)(t))))};t.default=s},function(e,t){"use strict";function n(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];if(0===t.length)return function(e){return e};var r=function(){var e=t[t.length-1],n=t.slice(0,-1);return{v:function(){return n.reduceRight(function(e,t){return t(e)},e.apply(void 0,arguments))}}}();return"object"==typeof r?r.v:void 0}t.__esModule=!0,t.default=n},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t,n){function r(){y===m&&(y=m.slice())}function i(){return v}function u(e){if("function"!=typeof e)throw new Error("Expected listener to be a function.");var t=!0;return r(),y.push(e),function(){if(t){t=!1,r();var n=y.indexOf(e);y.splice(n,1)}}}function l(e){if(!(0,a.default)(e))throw new Error("Actions must be plain objects. Use custom middleware for async actions.");if("undefined"==typeof e.type)throw new Error('Actions may not have an undefined "type" property. Have you misspelled a constant?');if(g)throw new Error("Reducers may not dispatch actions.");try{g=!0,v=h(v,e)}finally{g=!1}for(var t=m=y,n=0;n<t.length;n++)t[n]();return e}function f(e){if("function"!=typeof e)throw new Error("Expected the nextReducer to be a function.");h=e,l({type:c.INIT})}function p(){var e,t=u;return e={subscribe:function(e){function n(){e.next&&e.next(i())}if("object"!=typeof e)throw new TypeError("Expected the observer to be an object."); n();var r=t(n);return{unsubscribe:r}}},e[s.default]=function(){return this},e}var d;if("function"==typeof t&&"undefined"==typeof n&&(n=t,t=void 0),"undefined"!=typeof n){if("function"!=typeof n)throw new Error("Expected the enhancer to be a function.");return n(o)(e,t)}if("function"!=typeof e)throw new Error("Expected the reducer to be a function.");var h=e,v=t,m=[],y=m,g=!1;return l({type:c.INIT}),d={dispatch:l,subscribe:u,getState:i,replaceReducer:f},d[s.default]=p,d}t.__esModule=!0,t.ActionTypes=void 0,t.default=o;var i=n(65),a=r(i),u=n(392),s=r(u),c=t.ActionTypes={INIT:"@@redux/INIT"}},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}t.__esModule=!0,t.compose=t.applyMiddleware=t.bindActionCreators=t.combineReducers=t.createStore=void 0;var o=n(174),i=r(o),a=n(391),u=r(a),s=n(390),c=r(s),l=n(389),f=r(l),p=n(173),d=r(p),h=n(176);r(h),t.createStore=i.default,t.combineReducers=u.default,t.bindActionCreators=c.default,t.applyMiddleware=f.default,t.compose=d.default},function(e,t){"use strict";function n(e){"undefined"!=typeof console&&"function"==typeof console.error&&console.error(e);try{throw new Error(e)}catch(e){}}t.__esModule=!0,t.default=n},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}var o=n(5),i=r(o),a=n(290),u=r(a),s=n(53),c=r(s);"undefined"!=typeof window&&(window.initReact=function(e){return u.default.render(i.default.createElement(c.default,e),document.getElementById("content"))})},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(5),i=r(o),a=n(68),u=r(a),s=n(190),c=r(s),l=function(e){return/<p>(.+)<\/p>/.exec((0,u.default)(e))[1]},f=function(e){var t=e.items;return!(!t||!t.length)&&i.default.createElement("ol",{className:c.default.breadcrumbs},t.map(function(e,n){var r=e.path,o=e.title;return n===t.length-1?i.default.createElement("li",{key:n,dangerouslySetInnerHTML:{__html:l(o)}}):i.default.createElement("li",{key:n},i.default.createElement("a",{href:r,dangerouslySetInnerHTML:{__html:l(o)}}))}))};t.default=f},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(5),i=r(o),a=function(e){var t=e.user,n=e.repo,r=e.type,o=e.width,a=e.height,u=e.count,s=e.large,c="https://ghbtns.com/github-btn.html?user="+t+"&repo="+n+"&type="+r;return u&&(c+="&count=true"),s&&(c+="&size=large"),i.default.createElement("iframe",{src:c,frameBorder:"0",allowTransparency:"true",scrolling:"0",width:o,height:a,style:{border:"none",width:o,height:a}})};a.propTypes={user:o.PropTypes.string.isRequired,repo:o.PropTypes.string.isRequired,type:o.PropTypes.oneOf(["star","watch","fork","follow"]).isRequired,width:o.PropTypes.number.isRequired,height:o.PropTypes.number.isRequired,count:o.PropTypes.bool,large:o.PropTypes.bool},t.default=a},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(5),i=r(o),a=n(179),u=r(a),s=function(e){var t=e.version,r=n(191);return i.default.createElement("div",{className:r.home},i.default.createElement("div",{className:r.masthead},i.default.createElement("div",{className:r.logo}),i.default.createElement("h1",null,"Redux Form"),i.default.createElement("div",{className:r.version},"v",t),i.default.createElement("h2",null,"The best way to manage your form state in Redux."),i.default.createElement(u.default,{user:"erikras",repo:"redux-form",type:"star",width:160,height:30,count:!0,large:!0}),i.default.createElement(u.default,{user:"erikras",repo:"redux-form",type:"fork",width:160,height:30,count:!0,large:!0})),i.default.createElement("div",{className:r.options},i.default.createElement("a",{href:"docs/GettingStarted.md"},i.default.createElement("i",{className:r.start}),"Start Here"),i.default.createElement("a",{href:"docs/api"},i.default.createElement("i",{className:r.api}),"API"),i.default.createElement("a",{href:"examples"},i.default.createElement("i",{className:r.examples}),"Examples"),i.default.createElement("a",{href:"docs/faq"},i.default.createElement("i",{className:r.faq}),"FAQ")))};t.default=s},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function u(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),c=n(5),l=r(c),f=n(93),p=r(f),d=n(68),h=r(d),v=n(192),m=r(v),y=function(e){return/<p>(.+)<\/p>/.exec((0,h.default)(e))[1]},g=function(e){function t(e){i(this,t);var n=a(this,Object.getPrototypeOf(t).call(this,e));return n.open=n.open.bind(n),n.close=n.close.bind(n),n.state={open:!1},n}return u(t,e),s(t,[{key:"renderItem",value:function(e,t){var n=arguments.length<=2||void 0===arguments[2]?0:arguments[2],r=this.props,i=r.path,a=r.url;return l.default.createElement("a",{href:""+(a||"")+e,className:(0,p.default)(m.default["indent"+n],o({},m.default.active,e===i)),dangerouslySetInnerHTML:{__html:y(t)}})}},{key:"open",value:function(){this.setState({open:!0})}},{key:"close",value:function(){this.setState({open:!1})}},{key:"render",value:function(){var e=this.state.open,t=this.props.url;return l.default.createElement("div",{className:(0,p.default)(m.default.nav,o({},m.default.open,e))},l.default.createElement("button",{type:"button",onClick:this.open}),l.default.createElement("div",{className:m.default.overlay,onClick:this.close},l.default.createElement("i",{className:"fa fa-times"})," Close"),l.default.createElement("div",{className:m.default.placeholder}),l.default.createElement("nav",{className:m.default.menu},l.default.createElement("a",{href:t,className:m.default.brand},"Redux Form"),this.renderItem("/docs/GettingStarted.md","Getting Started"),this.renderItem("/docs/MigrationGuide.md","`v6` Migration Guide"),this.renderItem("/docs/ValueLifecycle.md","Value Lifecycle"),this.renderItem("/docs/api","API"),this.renderItem("/docs/api/ReduxForm.md","`reduxForm()`",1),this.renderItem("/docs/api/Props.md","`props`",1),this.renderItem("/docs/api/Field.md","`Field`",1),this.renderItem("/docs/api/Fields.md","`Fields`",1),this.renderItem("/docs/api/FieldArray.md","`FieldArray`",1),this.renderItem("/docs/api/Form.md","`Form`",1),this.renderItem("/docs/api/FormSection.md","`FormSection`",1),this.renderItem("/docs/api/FormValueSelector.md","`formValueSelector()`",1),this.renderItem("/docs/api/Reducer.md","`reducer`",1),this.renderItem("/docs/api/ReducerPlugin.md","`reducer.plugin()`",2),this.renderItem("/docs/api/SubmissionError.md","`SubmissionError`",1),this.renderItem("/docs/api/ActionCreators.md","Action Creators",1),this.renderItem("/docs/api/Selectors.md","Selectors",1),this.renderItem("/docs/faq","FAQ"),this.renderItem("/examples","Examples"),this.renderItem("/examples/simple","Simple Form",1),this.renderItem("/examples/syncValidation","Sync Validation",1),this.renderItem("/examples/fieldLevelValidation","Field-Level Validation",1),this.renderItem("/examples/submitValidation","Submit Validation",1),this.renderItem("/examples/asyncValidation","Async Validation",1),this.renderItem("/examples/initializeFromState","Initializing from State",1),this.renderItem("/examples/selectingFormValues","Selecting Form Values",1),this.renderItem("/examples/fieldArrays","Field Arrays",1),this.renderItem("/examples/remoteSubmit","Remote Submit",1),this.renderItem("/examples/normalizing","Normalizing",1),this.renderItem("/examples/immutable","Immutable JS",1),this.renderItem("/examples/wizard","Wizard Form",1),this.renderItem("/examples/material-ui","Material UI",1),this.renderItem("/examples/react-widgets","React Widgets",1),this.renderItem("/docs/DocumentationVersions.md","Older Versions")))}}]),t}(c.Component);g.propTypes={path:c.PropTypes.string.isRequired,url:c.PropTypes.string.isRequired},t.default=g},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},i=n(5),a=r(i),u=function(e){var t=e.username,n=e.showUsername,r=e.showCount,i=e.large,u={};return n||(u["data-show-screen-name"]="false"),r||(u["data-show-count"]="false"),i&&(u["data-size"]="large"),a.default.createElement("a",o({href:"https://twitter.com/"+t,className:"twitter-follow-button"},u),"Follow @",t)};u.propTypes={username:i.PropTypes.string.isRequired,showUserName:i.PropTypes.bool,showCount:i.PropTypes.bool,large:i.PropTypes.bool},t.default=u},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(5),i=r(o),a=n(379),u=n(91),s=r(u),c=function(e){var t=e.form,n=e.format,r=void 0===n?function(e){return JSON.stringify(e,null,2)}:n,o=(0,a.values)({form:t}),u=function(e){var t=e.values;return i.default.createElement("div",null,i.default.createElement("h2",null,"Values"),i.default.createElement(s.default,{source:r(t)}))},c=o(u);return i.default.createElement(c,null)};t.default=c},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(e,t,n){return[{path:"https://redux-form.com/"+n+"/",title:"Redux Form"},{path:"https://redux-form.com/"+n+"/examples",title:"Examples"},{path:"https://redux-form.com/"+n+"/examples/"+e,title:t}]};t.default=n},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0}),t.Values=t.Markdown=t.Code=t.App=t.generateExampleBreadcrumbs=t.render=void 0;var o=n(186),i=r(o),a=n(184),u=r(a),s=n(53),c=r(s),l=n(91),f=r(l),p=n(92),d=r(p),h=n(183),v=r(h);t.render=i.default,t.generateExampleBreadcrumbs=u.default,t.App=c.default,t.Code=f.default,t.Markdown=d.default,t.Values=v.default},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(5),i=r(o),a=n(291),u=n(53),s=r(u),c=function(e){var t=e.component,n=e.title,r=e.path,o=e.version,u=e.breadcrumbs;return'<!DOCTYPE html>\n <html lang="en">\n <head>\n <meta charSet="utf-8"/>\n <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"/>\n <title>Redux Form'+(n&&" - "+n)+'</title>\n <link href="https://redux-form.com/'+o+'/bundle.css"\n media="screen, projection" rel="stylesheet" type="text/css"/>\n <link href="//cdnjs.cloudflare.com/ajax/libs/font-awesome/4.3.0/css/font-awesome.min.css"\n media="screen, projection" rel="stylesheet" type="text/css"/>\n <meta itemprop="name" content="Redux Form"/>\n <meta property="og:type" content="website"/>\n <meta property="og:title" content="Redux Form"/>\n <meta property="og:site_name" content="Redux Form"/>\n <meta property="og:description" content="The best way to manage your form state in Redux."/>\n <meta property="og:image" content="logo.png"/>\n <meta property="twitter:site" content="@erikras"/>\n <meta property="twitter:creator" content="@erikras"/>\n <style type="text/css">\n body {\n margin: 0;\n }\n </style>\n </head>\n <body>\n <div id="content">\n '+(0,a.renderToString)(i.default.createElement(s.default,{version:o,path:r,breadcrumbs:u},t))+'\n </div>\n <script src="https://redux-form.com/'+o+'/bundle.js"></script>\n <script>initReact('+JSON.stringify({version:o,path:r,breadcrumbs:u})+")</script>\n <script>\n (function(i,s,o,g,r,a,m){i[ 'GoogleAnalyticsObject' ] = r;i[r]=i[r]||function(){\n (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),\n m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)\n })(window,document,'script','//www.google-analytics.com/analytics.js','ga');\n ga('create', 'UA-69298417-1', 'auto');\n ga('send', 'pageview');\n </script>\n <script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+'://platform.twitter.com/widgets.js';fjs.parentNode.insertBefore(js,fjs);}}(document, 'script', 'twitter-wjs');</script>\n </body>\n </html>"};t.default=c},function(e,t){(function(t){"use strict";var n="undefined"!=typeof window?window:"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope?self:{},r=function(){var e=/\blang(?:uage)?-(\w+)\b/i,t=0,r=n.Prism={util:{encode:function(e){return e instanceof o?new o(e.type,r.util.encode(e.content),e.alias):"Array"===r.util.type(e)?e.map(r.util.encode):e.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/\u00a0/g," ")},type:function(e){return Object.prototype.toString.call(e).match(/\[object (\w+)\]/)[1]},objId:function(e){return e.__id||Object.defineProperty(e,"__id",{value:++t}),e.__id},clone:function(e){var t=r.util.type(e);switch(t){case"Object":var n={};for(var o in e)e.hasOwnProperty(o)&&(n[o]=r.util.clone(e[o]));return n;case"Array":return e.map&&e.map(function(e){return r.util.clone(e)})}return e}},languages:{extend:function(e,t){var n=r.util.clone(r.languages[e]);for(var o in t)n[o]=t[o];return n},insertBefore:function(e,t,n,o){o=o||r.languages;var i=o[e];if(2==arguments.length){n=arguments[1];for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a]);return i}var u={};for(var s in i)if(i.hasOwnProperty(s)){if(s==t)for(var a in n)n.hasOwnProperty(a)&&(u[a]=n[a]);u[s]=i[s]}return r.languages.DFS(r.languages,function(t,n){n===o[e]&&t!=e&&(this[t]=u)}),o[e]=u},DFS:function(e,t,n,o){o=o||{};for(var i in e)e.hasOwnProperty(i)&&(t.call(e,i,e[i],n||i),"Object"!==r.util.type(e[i])||o[r.util.objId(e[i])]?"Array"!==r.util.type(e[i])||o[r.util.objId(e[i])]||(o[r.util.objId(e[i])]=!0,r.languages.DFS(e[i],t,i,o)):(o[r.util.objId(e[i])]=!0,r.languages.DFS(e[i],t,null,o)))}},plugins:{},highlightAll:function(e,t){var n={callback:t,selector:'code[class*="language-"], [class*="language-"] code, code[class*="lang-"], [class*="lang-"] code'};r.hooks.run("before-highlightall",n);for(var o,i=n.elements||document.querySelectorAll(n.selector),a=0;o=i[a++];)r.highlightElement(o,e===!0,n.callback)},highlightElement:function(t,o,i){for(var a,u,s=t;s&&!e.test(s.className);)s=s.parentNode;s&&(a=(s.className.match(e)||[,""])[1],u=r.languages[a]),t.className=t.className.replace(e,"").replace(/\s+/g," ")+" language-"+a,s=t.parentNode,/pre/i.test(s.nodeName)&&(s.className=s.className.replace(e,"").replace(/\s+/g," ")+" language-"+a);var c=t.textContent,l={element:t,language:a,grammar:u,code:c};if(!c||!u)return void r.hooks.run("complete",l);if(r.hooks.run("before-highlight",l),o&&n.Worker){var f=new Worker(r.filename);f.onmessage=function(e){l.highlightedCode=e.data,r.hooks.run("before-insert",l),l.element.innerHTML=l.highlightedCode,i&&i.call(l.element),r.hooks.run("after-highlight",l),r.hooks.run("complete",l)},f.postMessage(JSON.stringify({language:l.language,code:l.code,immediateClose:!0}))}else l.highlightedCode=r.highlight(l.code,l.grammar,l.language),r.hooks.run("before-insert",l),l.element.innerHTML=l.highlightedCode,i&&i.call(t),r.hooks.run("after-highlight",l),r.hooks.run("complete",l)},highlight:function(e,t,n){var i=r.tokenize(e,t);return o.stringify(r.util.encode(i),n)},tokenize:function(e,t){var n=r.Token,o=[e],i=t.rest;if(i){for(var a in i)t[a]=i[a];delete t.rest}e:for(var a in t)if(t.hasOwnProperty(a)&&t[a]){var u=t[a];u="Array"===r.util.type(u)?u:[u];for(var s=0;s<u.length;++s){var c=u[s],l=c.inside,f=!!c.lookbehind,p=!!c.greedy,d=0,h=c.alias;c=c.pattern||c;for(var v=0;v<o.length;v++){var m=o[v];if(o.length>e.length)break e;if(!(m instanceof n)){c.lastIndex=0;var y=c.exec(m),g=1;if(!y&&p&&v!=o.length-1){var b=o[v+1].matchedStr||o[v+1],_=m+b;if(v<o.length-2&&(_+=o[v+2].matchedStr||o[v+2]),c.lastIndex=0,y=c.exec(_),!y)continue;var x=y.index+(f?y[1].length:0);if(x>=m.length)continue;var E=y.index+y[0].length,w=m.length+b.length;g=3,w>=E&&(g=2,_=_.slice(0,w)),m=_}if(y){f&&(d=y[1].length);var x=y.index+d,y=y[0].slice(d),E=x+y.length,S=m.slice(0,x),C=m.slice(E),P=[v,g];S&&P.push(S);var O=new n(a,l?r.tokenize(y,l):y,h,y);P.push(O),C&&P.push(C),Array.prototype.splice.apply(o,P)}}}}}return o},hooks:{all:{},add:function(e,t){var n=r.hooks.all;n[e]=n[e]||[],n[e].push(t)},run:function(e,t){var n=r.hooks.all[e];if(n&&n.length)for(var o,i=0;o=n[i++];)o(t)}}},o=r.Token=function(e,t,n,r){this.type=e,this.content=t,this.alias=n,this.matchedStr=r||null};if(o.stringify=function(e,t,n){if("string"==typeof e)return e;if("Array"===r.util.type(e))return e.map(function(n){return o.stringify(n,t,e)}).join("");var i={type:e.type,content:o.stringify(e.content,t,n),tag:"span",classes:["token",e.type],attributes:{},language:t,parent:n};if("comment"==i.type&&(i.attributes.spellcheck="true"),e.alias){var a="Array"===r.util.type(e.alias)?e.alias:[e.alias];Array.prototype.push.apply(i.classes,a)}r.hooks.run("wrap",i);var u="";for(var s in i.attributes)u+=(u?" ":"")+s+'="'+(i.attributes[s]||"")+'"';return"<"+i.tag+' class="'+i.classes.join(" ")+'" '+u+">"+i.content+"</"+i.tag+">"},!n.document)return n.addEventListener?(n.addEventListener("message",function(e){var t=JSON.parse(e.data),o=t.language,i=t.code,a=t.immediateClose;n.postMessage(r.highlight(i,r.languages[o],o)),a&&n.close()},!1),n.Prism):n.Prism;var i=document.currentScript||[].slice.call(document.getElementsByTagName("script")).pop();return i&&(r.filename=i.src,document.addEventListener&&!i.hasAttribute("data-manual")&&document.addEventListener("DOMContentLoaded",r.highlightAll)),n.Prism}();"undefined"!=typeof e&&e.exports&&(e.exports=r),"undefined"!=typeof t&&(t.Prism=r),r.languages.markup={comment:/<!--[\w\W]*?-->/,prolog:/<\?[\w\W]+?\?>/,doctype:/<!DOCTYPE[\w\W]+?>/,cdata:/<!\[CDATA\[[\w\W]*?]]>/i,tag:{pattern:/<\/?(?!\d)[^\s>\/=.$<]+(?:\s+[^\s>\/=]+(?:=(?:("|')(?:\\\1|\\?(?!\1)[\w\W])*\1|[^\s'">=]+))?)*\s*\/?>/i,inside:{tag:{pattern:/^<\/?[^\s>\/]+/i,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"attr-value":{pattern:/=(?:('|")[\w\W]*?(\1)|[^\s>]+)/i,inside:{punctuation:/[=>"']/}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:/&#?[\da-z]{1,8};/i},r.hooks.add("wrap",function(e){"entity"===e.type&&(e.attributes.title=e.content.replace(/&amp;/,"&"))}),r.languages.xml=r.languages.markup,r.languages.html=r.languages.markup,r.languages.mathml=r.languages.markup,r.languages.svg=r.languages.markup,r.languages.css={comment:/\/\*[\w\W]*?\*\//,atrule:{pattern:/@[\w-]+?.*?(;|(?=\s*\{))/i,inside:{rule:/@[\w-]+/}},url:/url\((?:(["'])(\\(?:\r\n|[\w\W])|(?!\1)[^\\\r\n])*\1|.*?)\)/i,selector:/[^\{\}\s][^\{\};]*?(?=\s*\{)/,string:/("|')(\\(?:\r\n|[\w\W])|(?!\1)[^\\\r\n])*\1/,property:/(\b|\B)[\w-]+(?=\s*:)/i,important:/\B!important\b/i,function:/[-a-z0-9]+(?=\()/i,punctuation:/[(){};:]/},r.languages.css.atrule.inside.rest=r.util.clone(r.languages.css),r.languages.markup&&(r.languages.insertBefore("markup","tag",{style:{pattern:/(<style[\w\W]*?>)[\w\W]*?(?=<\/style>)/i,lookbehind:!0,inside:r.languages.css,alias:"language-css"}}),r.languages.insertBefore("inside","attr-value",{"style-attr":{pattern:/\s*style=("|').*?\1/i,inside:{"attr-name":{pattern:/^\s*style/i,inside:r.languages.markup.tag.inside},punctuation:/^\s*=\s*['"]|['"]\s*$/,"attr-value":{pattern:/.+/i,inside:r.languages.css}},alias:"language-css"}},r.languages.markup.tag)),r.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\w\W]*?\*\//,lookbehind:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0}],string:{pattern:/(["'])(\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/((?:\b(?:class|interface|extends|implements|trait|instanceof|new)\s+)|(?:catch\s+\())[a-z0-9_\.\\]+/i,lookbehind:!0,inside:{punctuation:/(\.|\\)/}},keyword:/\b(if|else|while|do|for|return|in|instanceof|function|new|try|throw|catch|finally|null|break|continue)\b/,boolean:/\b(true|false)\b/,function:/[a-z0-9_]+(?=\()/i,number:/\b-?(?:0x[\da-f]+|\d*\.?\d+(?:e[+-]?\d+)?)\b/i,operator:/--?|\+\+?|!=?=?|<=?|>=?|==?=?|&&?|\|\|?|\?|\*|\/|~|\^|%/,punctuation:/[{}[\];(),.:]/},r.languages.javascript=r.languages.extend("clike",{keyword:/\b(as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|var|void|while|with|yield)\b/,number:/\b-?(0x[\dA-Fa-f]+|0b[01]+|0o[0-7]+|\d*\.?\d+([Ee][+-]?\d+)?|NaN|Infinity)\b/,function:/[_$a-zA-Z\xA0-\uFFFF][_$a-zA-Z0-9\xA0-\uFFFF]*(?=\()/i}),r.languages.insertBefore("javascript","keyword",{regex:{pattern:/(^|[^\/])\/(?!\/)(\[.+?]|\\.|[^\/\\\r\n])+\/[gimyu]{0,5}(?=\s*($|[\r\n,.;})]))/,lookbehind:!0,greedy:!0}}),r.languages.insertBefore("javascript","class-name",{"template-string":{pattern:/`(?:\\\\|\\?[^\\])*?`/,inside:{interpolation:{pattern:/\$\{[^}]+\}/,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:r.languages.javascript}},string:/[\s\S]+/}}}),r.languages.markup&&r.languages.insertBefore("markup","tag",{script:{pattern:/(<script[\w\W]*?>)[\w\W]*?(?=<\/script>)/i,lookbehind:!0,inside:r.languages.javascript,alias:"language-javascript"}}),r.languages.js=r.languages.javascript,r.languages.json={property:/".*?"(?=\s*:)/gi,string:/"(?!:)(\\?[^"])*?"(?!:)/g,number:/\b-?(0x[\dA-Fa-f]+|\d*\.?\d+([Ee]-?\d+)?)\b/g,punctuation:/[{}[\]);,]/g,operator:/:/g,boolean:/\b(true|false)\b/gi,null:/\bnull\b/gi},r.languages.jsonp=r.languages.json,!function(e){var t=e.util.clone(e.languages.javascript);e.languages.jsx=e.languages.extend("markup",t),e.languages.jsx.tag.pattern=/<\/?[\w\.:-]+\s*(?:\s+[\w\.:-]+(?:=(?:("|')(\\?[\w\W])*?\1|[^\s'">=]+|(\{[\w\W]*?\})))?\s*)*\/?>/i,e.languages.jsx.tag.inside["attr-value"].pattern=/=[^\{](?:('|")[\w\W]*?(\1)|[^\s>]+)/i;var n=e.util.clone(e.languages.jsx);delete n.punctuation,n=e.languages.insertBefore("jsx","operator",{punctuation:/=(?={)|[{}[\];(),.:]/},{jsx:n}),e.languages.insertBefore("inside","attr-value",{script:{pattern:/=(\{(?:\{[^}]*\}|[^}])+\})/i,inside:n,alias:"language-javascript"}},e.languages.jsx.tag)}(r)}).call(t,function(){return this}())},function(e,t){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function r(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var o=function(e,t,n){for(var r=!0;r;){var o=e,i=t,a=n;r=!1,null===o&&(o=Function.prototype);var u=Object.getOwnPropertyDescriptor(o,i);if(void 0!==u){if("value"in u)return u.value;var s=u.get;if(void 0===s)return;return s.call(a)}var c=Object.getPrototypeOf(o);if(null===c)return;e=c,t=i,n=a,r=!0,u=c=void 0}},i=function(e){function t(){var e=arguments.length<=0||void 0===arguments[0]?"":arguments[0];return n(this,t),o(Object.getPrototypeOf(t.prototype),"constructor",this).call(this,e),Object.defineProperty(this,"message",{enumerable:!1,value:e,writable:!0}),Object.defineProperty(this,"name",{enumerable:!1,value:this.constructor.name,writable:!0}),Error.hasOwnProperty("captureStackTrace")?void Error.captureStackTrace(this,this.constructor):void Object.defineProperty(this,"stack",{enumerable:!1,value:new Error(e).stack,writable:!0})}return r(t,e),t}(Error);t.default=i,e.exports=t.default},function(e,t){e.exports={app:"app___3P8ep",topNav:"topNav___sBW8S",brand:"brand___YAZl-",github:"github___3-vRv",contentAndFooter:"contentAndFooter___kE2nt",content:"content___3TVHp",home:"home___2XyPG",hasNav:"hasNav___1KF_W",footer:"footer___1oh0h",help:"help___3OayI"}},function(e,t){e.exports={breadcrumbs:"breadcrumbs___1BHo6"}},function(e,t){e.exports={home:"home___381a9",masthead:"masthead___MGNF0",logo:"logo___hP7wi",content:"content___2vYdp",version:"version___2mbZo",github:"github___mrRv3",options:"options___2Tyc4",start:"start___1WlUb",api:"api___1hCrr",examples:"examples___2H_mp",faq:"faq___2mIT0"}},function(e,t){e.exports={nav:"nav___11xa5",placeholder:"placeholder___TzF1K",overlay:"overlay___1GMox",menu:"menu___12xDU",active:"active___2eU59",brand:"brand___1qRUu",indent1:"indent1___4iVnL",indent2:"indent2___2PiOO",open:"open___3Bk_k"}},function(e,t){"use strict";function n(e){return e.replace(r,function(e,t){return t.toUpperCase()})}var r=/-(.)/g;e.exports=n},function(e,t,n){"use strict";function r(e){return o(e.replace(i,"ms-"))}var o=n(193),i=/^-ms-/;e.exports=r},function(e,t,n){"use strict";function r(e,t){return!(!e||!t)&&(e===t||!o(e)&&(o(t)?r(e,t.parentNode):"contains"in e?e.contains(t):!!e.compareDocumentPosition&&!!(16&e.compareDocumentPosition(t))))}var o=n(202);e.exports=r},function(e,t,n){"use strict";function r(e){var t=e.length;if(Array.isArray(e)||"object"!=typeof e&&"function"!=typeof e?a(!1):void 0,"number"!=typeof t?a(!1):void 0,0===t||t-1 in e?void 0:a(!1),"function"==typeof e.callee?a(!1):void 0,e.hasOwnProperty)try{return Array.prototype.slice.call(e)}catch(e){}for(var n=Array(t),r=0;r<t;r++)n[r]=e[r];return n}function o(e){return!!e&&("object"==typeof e||"function"==typeof e)&&"length"in e&&!("setInterval"in e)&&"number"!=typeof e.nodeType&&(Array.isArray(e)||"callee"in e||"item"in e)}function i(e){return o(e)?Array.isArray(e)?e.slice():r(e):[e]}var a=n(1);e.exports=i},function(e,t,n){"use strict";function r(e){var t=e.match(l);return t&&t[1].toLowerCase()}function o(e,t){var n=c;c?void 0:s(!1);var o=r(e),i=o&&u(o);if(i){n.innerHTML=i[1]+e+i[2];for(var l=i[0];l--;)n=n.lastChild}else n.innerHTML=e;var f=n.getElementsByTagName("script");f.length&&(t?void 0:s(!1),a(f).forEach(t));for(var p=Array.from(n.childNodes);n.lastChild;)n.removeChild(n.lastChild);return p}var i=n(6),a=n(196),u=n(97),s=n(1),c=i.canUseDOM?document.createElement("div"):null,l=/^\s*<(\w+)/;e.exports=o},function(e,t){"use strict";function n(e){return e===window?{x:window.pageXOffset||document.documentElement.scrollLeft,y:window.pageYOffset||document.documentElement.scrollTop}:{x:e.scrollLeft,y:e.scrollTop}}e.exports=n},function(e,t){"use strict";function n(e){return e.replace(r,"-$1").toLowerCase()}var r=/([A-Z])/g;e.exports=n},function(e,t,n){"use strict";function r(e){return o(e).replace(i,"-ms-")}var o=n(199),i=/^ms-/;e.exports=r},function(e,t){"use strict";function n(e){return!(!e||!("function"==typeof Node?e instanceof Node:"object"==typeof e&&"number"==typeof e.nodeType&&"string"==typeof e.nodeName))}e.exports=n},function(e,t,n){"use strict";function r(e){return o(e)&&3==e.nodeType}var o=n(201);e.exports=r},function(e,t){"use strict";function n(e){var t={};return function(n){return t.hasOwnProperty(n)||(t[n]=e.call(this,n)),t[n]}}e.exports=n},function(e,t,n){"use strict";var r,o=n(6);o.canUseDOM&&(r=window.performance||window.msPerformance||window.webkitPerformance),e.exports=r||{}},function(e,t,n){"use strict";var r,o=n(204);r=o.now?function(){return o.now()}:function(){return Date.now()},e.exports=r},function(e,t,n){var r=n(22),o=n(8),i=r(o,"DataView");e.exports=i},function(e,t,n){function r(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}var o=n(242),i=n(243),a=n(244),u=n(245),s=n(246);r.prototype.clear=o,r.prototype.delete=i,r.prototype.get=a,r.prototype.has=u,r.prototype.set=s,e.exports=r},function(e,t,n){var r=n(22),o=n(8),i=r(o,"Promise");e.exports=i},function(e,t,n){var r=n(22),o=n(8),i=r(o,"Set");e.exports=i},function(e,t,n){function r(e){var t=-1,n=e?e.length:0;for(this.__data__=new o;++t<n;)this.add(e[t])}var o=n(57),i=n(267),a=n(268);r.prototype.add=r.prototype.push=i,r.prototype.has=a,e.exports=r},function(e,t,n){var r=n(8),o=r.Uint8Array;e.exports=o},function(e,t){function n(e,t){for(var n=-1,r=e?e.length:0,o=Array(r);++n<r;)o[n]=t(e[n],n,e);return o}e.exports=n},function(e,t,n){var r=n(105),o=n(229),i=o(r);e.exports=i},function(e,t,n){var r=n(230),o=r();e.exports=o},function(e,t){function n(e,t){return null!=e&&t in Object(e)}e.exports=n},function(e,t,n){function r(e,t,n,r,m,g){var b=c(e),_=c(t),x=h,E=h;b||(x=s(e),x=x==d?v:x),_||(E=s(t),E=E==d?v:E);var w=x==v&&!l(e),S=E==v&&!l(t),C=x==E;if(C&&!w)return g||(g=new o),b||f(e)?i(e,t,n,r,m,g):a(e,t,x,n,r,m,g);if(!(m&p)){var P=w&&y.call(e,"__wrapped__"),O=S&&y.call(t,"__wrapped__");if(P||O){var T=P?e.value():e,k=O?t.value():t;return g||(g=new o),n(T,k,r,m,g)}}return!!C&&(g||(g=new o),u(e,t,n,r,m,g))}var o=n(101),i=n(117),a=n(234),u=n(235),s=n(239),c=n(11),l=n(63),f=n(280),p=2,d="[object Arguments]",h="[object Array]",v="[object Object]",m=Object.prototype,y=m.hasOwnProperty;e.exports=r},function(e,t,n){function r(e,t,n,r){var s=n.length,c=s,l=!r;if(null==e)return!c;for(e=Object(e);s--;){var f=n[s];if(l&&f[2]?f[1]!==e[f[0]]:!(f[0]in e))return!1}for(;++s<c;){f=n[s];var p=f[0],d=e[p],h=f[1];if(l&&f[2]){if(void 0===d&&!(p in e))return!1}else{var v=new o;if(r)var m=r(d,h,p,e,t,v);if(!(void 0===m?i(h,d,r,a|u,v):m))return!1}}return!0}var o=n(101),i=n(60),a=1,u=2;e.exports=r},function(e,t,n){function r(e){if(!u(e)||a(e))return!1;var t=o(e)||i(e)?h:l;return t.test(s(e))}var o=n(64),i=n(63),a=n(251),u=n(15),s=n(125),c=/[\\^$.*+?()[\]{}|]/g,l=/^\[object .+?Constructor\]$/,f=Object.prototype,p=Function.prototype.toString,d=f.hasOwnProperty,h=RegExp("^"+p.call(d).replace(c,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");e.exports=r},function(e,t){function n(e){return r(Object(e))}var r=Object.keys;e.exports=n},function(e,t,n){function r(e){var t=i(e);return 1==t.length&&t[0][2]?a(t[0][0],t[0][1]):function(n){return n===e||o(n,e,t)}}var o=n(217),i=n(238),a=n(121);e.exports=r},function(e,t,n){function r(e,t){return u(e)&&s(t)?c(l(e),t):function(n){var r=i(n,e);return void 0===r&&r===t?a(n,e):o(t,r,void 0,f|p)}}var o=n(60),i=n(276),a=n(277),u=n(40),s=n(120),c=n(121),l=n(26),f=1,p=2;e.exports=r},function(e,t,n){function r(e){return function(t){return o(t,e)}}var o=n(106);e.exports=r},function(e,t,n){function r(e,t){var n;return o(e,function(e,r,o){return n=t(e,r,o),!n}),!!n}var o=n(213);e.exports=r},function(e,t){function n(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}e.exports=n},function(e,t,n){function r(e){if("string"==typeof e)return e;if(i(e))return s?s.call(e):"";var t=e+"";return"0"==t&&1/e==-a?"-0":t}var o=n(102),i=n(27),a=1/0,u=o?o.prototype:void 0,s=u?u.toString:void 0;e.exports=r},function(e,t){function n(e){return e&&e.Object===Object?e:null}e.exports=n},function(e,t,n){var r=n(8),o=r["__core-js_shared__"];e.exports=o},function(e,t){function n(e,t){for(var n=e.length,r=0;n--;)e[n]===t&&r++;return r}e.exports=n},function(e,t,n){function r(e,t){return function(n,r){if(null==n)return n;if(!o(n))return e(n,r);for(var i=n.length,a=t?i:-1,u=Object(n);(t?a--:++a<i)&&r(u[a],a,u)!==!1;);return n}}var o=n(42);e.exports=r},function(e,t){function n(e){return function(t,n,r){for(var o=-1,i=Object(t),a=r(t),u=a.length;u--;){var s=a[e?u:++o];if(n(i[s],s,i)===!1)break; }return t}}e.exports=n},function(e,t,n){function r(e,t,n){function r(){var t=this&&this!==i&&this instanceof r?s:e;return t.apply(u?n:this,arguments)}var u=t&a,s=o(e);return r}var o=n(36),i=n(8),a=1;e.exports=r},function(e,t,n){function r(e,t,n){function r(){for(var i=arguments.length,p=Array(i),d=i,h=s(r);d--;)p[d]=arguments[d];var v=i<3&&p[0]!==h&&p[i-1]!==h?[]:c(p,h);if(i-=v.length,i<n)return u(e,t,a,r.placeholder,void 0,p,v,void 0,void 0,n-i);var m=this&&this!==l&&this instanceof r?f:e;return o(m,this,p)}var f=i(e);return r}var o=n(58),i=n(36),a=n(114),u=n(115),s=n(37),c=n(25),l=n(8);e.exports=r},function(e,t,n){function r(e,t,n,r){function s(){for(var t=-1,i=arguments.length,u=-1,f=r.length,p=Array(f+i),d=this&&this!==a&&this instanceof s?l:e;++u<f;)p[u]=r[u];for(;i--;)p[u++]=arguments[++t];return o(d,c?n:this,p)}var c=t&u,l=i(e);return s}var o=n(58),i=n(36),a=n(8),u=1;e.exports=r},function(e,t,n){function r(e,t,n,r,o,E,S){switch(n){case x:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case _:return!(e.byteLength!=t.byteLength||!r(new i(e),new i(t)));case f:case p:return+e==+t;case d:return e.name==t.name&&e.message==t.message;case v:return e!=+e?t!=+t:e==+t;case m:case g:return e==t+"";case h:var C=u;case y:var P=E&l;if(C||(C=s),e.size!=t.size&&!P)return!1;var O=S.get(e);return O?O==t:(E|=c,S.set(e,t),a(C(e),C(t),r,o,E,S));case b:if(w)return w.call(e)==w.call(t)}return!1}var o=n(102),i=n(211),a=n(117),u=n(263),s=n(269),c=1,l=2,f="[object Boolean]",p="[object Date]",d="[object Error]",h="[object Map]",v="[object Number]",m="[object RegExp]",y="[object Set]",g="[object String]",b="[object Symbol]",_="[object ArrayBuffer]",x="[object DataView]",E=o?o.prototype:void 0,w=E?E.valueOf:void 0;e.exports=r},function(e,t,n){function r(e,t,n,r,u,s){var c=u&a,l=i(e),f=l.length,p=i(t),d=p.length;if(f!=d&&!c)return!1;for(var h=f;h--;){var v=l[h];if(!(c?v in t:o(t,v)))return!1}var m=s.get(e);if(m)return m==t;var y=!0;s.set(e,t);for(var g=c;++h<f;){v=l[h];var b=e[v],_=t[v];if(r)var x=c?r(_,b,v,t,e,s):r(b,_,v,e,t,s);if(!(void 0===x?b===_||n(b,_,r,u,s):x)){y=!1;break}g||(g="constructor"==v)}if(y&&!g){var E=e.constructor,w=t.constructor;E!=w&&"constructor"in e&&"constructor"in t&&!("function"==typeof E&&E instanceof E&&"function"==typeof w&&w instanceof w)&&(y=!1)}return s.delete(e),y}var o=n(107),i=n(66),a=2;e.exports=r},function(e,t,n){function r(e){for(var t=e.name+"",n=o[t],r=a.call(o,t)?n.length:0;r--;){var i=n[r],u=i.func;if(null==u||u==e)return i.name}return t}var o=n(265),i=Object.prototype,a=i.hasOwnProperty;e.exports=r},function(e,t,n){var r=n(109),o=r("length");e.exports=o},function(e,t,n){function r(e){for(var t=i(e),n=t.length;n--;){var r=t[n],a=e[r];t[n]=[r,a,o(a)]}return t}var o=n(120),i=n(66);e.exports=r},function(e,t,n){function r(e){return y.call(e)}var o=n(206),i=n(100),a=n(208),u=n(209),s=n(103),c=n(125),l="[object Map]",f="[object Object]",p="[object Promise]",d="[object Set]",h="[object WeakMap]",v="[object DataView]",m=Object.prototype,y=m.toString,g=c(o),b=c(i),_=c(a),x=c(u),E=c(s);(o&&r(new o(new ArrayBuffer(1)))!=v||i&&r(new i)!=l||a&&r(a.resolve())!=p||u&&r(new u)!=d||s&&r(new s)!=h)&&(r=function(e){var t=y.call(e),n=t==f?e.constructor:void 0,r=n?c(n):void 0;if(r)switch(r){case g:return v;case b:return l;case _:return p;case x:return d;case E:return h}return t}),e.exports=r},function(e,t){function n(e,t){return null==e?void 0:e[t]}e.exports=n},function(e,t,n){function r(e,t,n){t=s(t,e)?[t]:o(t);for(var r,p=-1,d=t.length;++p<d;){var h=f(t[p]);if(!(r=null!=e&&n(e,h)))break;e=e[h]}if(r)return r;var d=e?e.length:0;return!!d&&c(d)&&u(h,d)&&(a(e)||l(e)||i(e))}var o=n(111),i=n(128),a=n(11),u=n(39),s=n(40),c=n(43),l=n(129),f=n(26);e.exports=r},function(e,t,n){function r(){this.__data__=o?o(null):{}}var o=n(41);e.exports=r},function(e,t){function n(e){return this.has(e)&&delete this.__data__[e]}e.exports=n},function(e,t,n){function r(e){var t=this.__data__;if(o){var n=t[e];return n===i?void 0:n}return u.call(t,e)?t[e]:void 0}var o=n(41),i="__lodash_hash_undefined__",a=Object.prototype,u=a.hasOwnProperty;e.exports=r},function(e,t,n){function r(e){var t=this.__data__;return o?void 0!==t[e]:a.call(t,e)}var o=n(41),i=Object.prototype,a=i.hasOwnProperty;e.exports=r},function(e,t,n){function r(e,t){var n=this.__data__;return n[e]=o&&void 0===t?i:t,this}var o=n(41),i="__lodash_hash_undefined__";e.exports=r},function(e,t,n){function r(e){var t=e?e.length:void 0;return u(t)&&(a(e)||s(e)||i(e))?o(t,String):null}var o=n(224),i=n(128),a=n(11),u=n(43),s=n(129);e.exports=r},function(e,t,n){function r(e,t,n){if(!u(n))return!1;var r=typeof t;return!!("number"==r?i(n)&&a(t,n.length):"string"==r&&t in n)&&o(n[t],e)}var o=n(126),i=n(42),a=n(39),u=n(15);e.exports=r},function(e,t){function n(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}e.exports=n},function(e,t,n){function r(e){var t=a(e),n=u[t];if("function"!=typeof n||!(t in o.prototype))return!1;if(e===n)return!0;var r=i(n);return!!r&&e===r[0]}var o=n(56),i=n(118),a=n(236),u=n(289);e.exports=r},function(e,t,n){function r(e){return!!i&&i in e}var o=n(227),i=function(){var e=/[^.]+$/.exec(o&&o.keys&&o.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();e.exports=r},function(e,t){function n(e){var t=e&&e.constructor,n="function"==typeof t&&t.prototype||r;return e===n}var r=Object.prototype;e.exports=n},function(e,t){function n(){this.__data__=[]}e.exports=n},function(e,t,n){function r(e){var t=this.__data__,n=o(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():a.call(t,n,1),!0}var o=n(35),i=Array.prototype,a=i.splice;e.exports=r},function(e,t,n){function r(e){var t=this.__data__,n=o(t,e);return n<0?void 0:t[n][1]}var o=n(35);e.exports=r},function(e,t,n){function r(e){return o(this.__data__,e)>-1}var o=n(35);e.exports=r},function(e,t,n){function r(e,t){var n=this.__data__,r=o(n,e);return r<0?n.push([e,t]):n[r][1]=t,this}var o=n(35);e.exports=r},function(e,t,n){function r(){this.__data__={hash:new o,map:new(a||i),string:new o}}var o=n(207),i=n(34),a=n(100);e.exports=r},function(e,t,n){function r(e){return o(this,e).delete(e)}var o=n(38);e.exports=r},function(e,t,n){function r(e){return o(this,e).get(e)}var o=n(38);e.exports=r},function(e,t,n){function r(e){return o(this,e).has(e)}var o=n(38);e.exports=r},function(e,t,n){function r(e,t){return o(this,e).set(e,t),this}var o=n(38);e.exports=r},function(e,t){function n(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}e.exports=n},function(e,t,n){function r(e,t){var n=e[1],r=t[1],v=n|r,m=v<(s|c|p),y=r==p&&n==f||r==p&&n==d&&e[7].length<=t[8]||r==(p|d)&&t[7].length<=t[8]&&n==f;if(!m&&!y)return e;r&s&&(e[2]=t[2],v|=n&s?0:l);var g=t[3];if(g){var b=e[3];e[3]=b?o(b,g,t[4]):g,e[4]=b?a(e[3],u):t[4]}return g=t[5],g&&(b=e[5],e[5]=b?i(b,g,t[6]):g,e[6]=b?a(e[5],u):t[6]),g=t[7],g&&(e[7]=g),r&p&&(e[8]=null==e[8]?t[8]:h(e[8],t[8])),null==e[9]&&(e[9]=t[9]),e[0]=t[0],e[1]=v,e}var o=n(112),i=n(113),a=n(25),u="__lodash_placeholder__",s=1,c=2,l=4,f=8,p=128,d=256,h=Math.min;e.exports=r},function(e,t){var n={};e.exports=n},function(e,t,n){function r(e,t){for(var n=e.length,r=a(t.length,n),u=o(e);r--;){var s=t[r];e[r]=i(s,n)?u[s]:void 0}return e}var o=n(62),i=n(39),a=Math.min;e.exports=r},function(e,t){function n(e){return this.__data__.set(e,r),this}var r="__lodash_hash_undefined__";e.exports=n},function(e,t){function n(e){return this.__data__.has(e)}e.exports=n},function(e,t){function n(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}e.exports=n},function(e,t,n){function r(){this.__data__=new o}var o=n(34);e.exports=r},function(e,t){function n(e){return this.__data__.delete(e)}e.exports=n},function(e,t){function n(e){return this.__data__.get(e)}e.exports=n},function(e,t){function n(e){return this.__data__.has(e)}e.exports=n},function(e,t,n){function r(e,t){var n=this.__data__;return n instanceof o&&n.__data__.length==a&&(n=this.__data__=new i(n.__data__)),n.set(e,t),this}var o=n(34),i=n(57),a=200;e.exports=r},function(e,t,n){function r(e){if(e instanceof o)return e.clone();var t=new i(e.__wrapped__,e.__chain__);return t.__actions__=a(e.__actions__),t.__index__=e.__index__,t.__values__=e.__values__,t}var o=n(56),i=n(99),a=n(62);e.exports=r},function(e,t,n){function r(e,t,n){var r=null==e?void 0:o(e,t);return void 0===r?n:r}var o=n(106);e.exports=r},function(e,t,n){function r(e,t){return null!=e&&i(e,t,o)}var o=n(215),i=n(241);e.exports=r},function(e,t,n){function r(e){return i(e)&&o(e)}var o=n(42),i=n(18);e.exports=r},function(e,t,n){function r(e,t,n){n="function"==typeof n?n:void 0;var r=n?n(e,t):void 0;return void 0===r?o(e,t,n):!!r}var o=n(60);e.exports=r},function(e,t,n){function r(e){return i(e)&&o(e.length)&&!!A[M.call(e)]}var o=n(43),i=n(18),a="[object Arguments]",u="[object Array]",s="[object Boolean]",c="[object Date]",l="[object Error]",f="[object Function]",p="[object Map]",d="[object Number]",h="[object Object]",v="[object RegExp]",m="[object Set]",y="[object String]",g="[object WeakMap]",b="[object ArrayBuffer]",_="[object DataView]",x="[object Float32Array]",E="[object Float64Array]",w="[object Int8Array]",S="[object Int16Array]",C="[object Int32Array]",P="[object Uint8Array]",O="[object Uint8ClampedArray]",T="[object Uint16Array]",k="[object Uint32Array]",A={};A[x]=A[E]=A[w]=A[S]=A[C]=A[P]=A[O]=A[T]=A[k]=!0,A[a]=A[u]=A[b]=A[s]=A[_]=A[c]=A[l]=A[f]=A[p]=A[d]=A[h]=A[v]=A[m]=A[y]=A[g]=!1;var R=Object.prototype,M=R.toString;e.exports=r},function(e,t,n){function r(e,t){if("function"!=typeof e||t&&"function"!=typeof t)throw new TypeError(i);var n=function(){var r=arguments,o=t?t.apply(this,r):r[0],i=n.cache;if(i.has(o))return i.get(o);var a=e.apply(this,r);return n.cache=i.set(o,a),a};return n.cache=new(r.Cache||o),n}var o=n(57),i="Expected a function";r.Cache=o,e.exports=r},function(e,t){function n(){return Date.now()}e.exports=n},function(e,t,n){var r=n(116),o=n(37),i=n(25),a=n(131),u=64,s=a(function(e,t){var n=i(t,o(s));return r(e,u,void 0,t,n)});s.placeholder={},e.exports=s},function(e,t,n){function r(e){return a(e)?o(u(e)):i(e)}var o=n(109),i=n(222),a=n(40),u=n(26);e.exports=r},function(e,t,n){function r(e,t,n){var r=u(e)?o:a;return n&&s(e,t,n)&&(t=void 0),r(e,i(t,3))}var o=n(104),i=n(108),a=n(223),u=n(11),s=n(248);e.exports=r},function(e,t,n){function r(e){if(!e)return 0===e?e:0;if(e=o(e),e===i||e===-i){var t=e<0?-1:1;return t*a}return e===e?e:0}var o=n(287),i=1/0,a=1.7976931348623157e308;e.exports=r},function(e,t,n){function r(e){if("number"==typeof e)return e;if(a(e))return u;if(i(e)){var t=o(e.valueOf)?e.valueOf():e;e=i(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(s,"");var n=l.test(e);return n||f.test(e)?p(e.slice(2),n?2:8):c.test(e)?u:+e}var o=n(64),i=n(15),a=n(27),u=NaN,s=/^\s+|\s+$/g,c=/^[-+]0x[0-9a-f]+$/i,l=/^0b[01]+$/i,f=/^0o[0-7]+$/i,p=parseInt;e.exports=r},function(e,t,n){function r(e){return null==e?"":o(e)}var o=n(225);e.exports=r},function(e,t,n){function r(e){if(s(e)&&!u(e)&&!(e instanceof o)){if(e instanceof i)return e;if(f.call(e,"__wrapped__"))return c(e)}return new i(e)}var o=n(56),i=n(99),a=n(61),u=n(11),s=n(18),c=n(275),l=Object.prototype,f=l.hasOwnProperty;r.prototype=a.prototype,r.prototype.constructor=r,e.exports=r},function(e,t,n){"use strict";e.exports=n(310)},function(e,t,n){"use strict";e.exports=n(321)},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}t.__esModule=!0,t.default=void 0;var u=n(5),s=n(133),c=r(s),l=n(134),f=(r(l),function(e){function t(n,r){o(this,t);var a=i(this,e.call(this,n,r));return a.store=n.store,a}return a(t,e),t.prototype.getChildContext=function(){return{store:this.store}},t.prototype.render=function(){var e=this.props.children;return u.Children.only(e)},t}(u.Component));t.default=f,f.propTypes={store:c.default.isRequired,children:u.PropTypes.element.isRequired},f.childContextTypes={store:c.default.isRequired}},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function u(e){return e.displayName||e.name||"Component"}function s(e,t){try{return e.apply(t)}catch(e){return O.value=e,O}}function c(e,t,n){var r=arguments.length<=3||void 0===arguments[3]?{}:arguments[3],c=Boolean(e),p=e||S,h=void 0;h="function"==typeof t?t:t?(0,y.default)(t):C;var m=n||P,g=r.pure,b=void 0===g||g,_=r.withRef,E=void 0!==_&&_,k=b&&m!==P,A=T++;return function(e){function t(e,t,n){var r=m(e,t,n);return r}var n="Connect("+u(e)+")",r=function(r){function u(e,t){o(this,u);var a=i(this,r.call(this,e,t));a.version=A,a.store=e.store||t.store,(0,w.default)(a.store,'Could not find "store" in either the context or '+('props of "'+n+'". ')+"Either wrap the root component in a <Provider>, "+('or explicitly pass "store" as a prop to "'+n+'".'));var s=a.store.getState();return a.state={storeState:s},a.clearCache(),a}return a(u,r),u.prototype.shouldComponentUpdate=function(){return!b||this.haveOwnPropsChanged||this.hasStoreStateChanged},u.prototype.computeStateProps=function(e,t){if(!this.finalMapStateToProps)return this.configureFinalMapState(e,t);var n=e.getState(),r=this.doStatePropsDependOnOwnProps?this.finalMapStateToProps(n,t):this.finalMapStateToProps(n);return r},u.prototype.configureFinalMapState=function(e,t){var n=p(e.getState(),t),r="function"==typeof n;return this.finalMapStateToProps=r?n:p,this.doStatePropsDependOnOwnProps=1!==this.finalMapStateToProps.length,r?this.computeStateProps(e,t):n},u.prototype.computeDispatchProps=function(e,t){if(!this.finalMapDispatchToProps)return this.configureFinalMapDispatch(e,t);var n=e.dispatch,r=this.doDispatchPropsDependOnOwnProps?this.finalMapDispatchToProps(n,t):this.finalMapDispatchToProps(n);return r},u.prototype.configureFinalMapDispatch=function(e,t){var n=h(e.dispatch,t),r="function"==typeof n;return this.finalMapDispatchToProps=r?n:h,this.doDispatchPropsDependOnOwnProps=1!==this.finalMapDispatchToProps.length,r?this.computeDispatchProps(e,t):n},u.prototype.updateStatePropsIfNeeded=function(){var e=this.computeStateProps(this.store,this.props);return!(this.stateProps&&(0,v.default)(e,this.stateProps)||(this.stateProps=e,0))},u.prototype.updateDispatchPropsIfNeeded=function(){var e=this.computeDispatchProps(this.store,this.props);return!(this.dispatchProps&&(0,v.default)(e,this.dispatchProps)||(this.dispatchProps=e,0))},u.prototype.updateMergedPropsIfNeeded=function(){var e=t(this.stateProps,this.dispatchProps,this.props);return!(this.mergedProps&&k&&(0,v.default)(e,this.mergedProps)||(this.mergedProps=e,0))},u.prototype.isSubscribed=function(){return"function"==typeof this.unsubscribe},u.prototype.trySubscribe=function(){c&&!this.unsubscribe&&(this.unsubscribe=this.store.subscribe(this.handleChange.bind(this)),this.handleChange())},u.prototype.tryUnsubscribe=function(){this.unsubscribe&&(this.unsubscribe(),this.unsubscribe=null)},u.prototype.componentDidMount=function(){this.trySubscribe()},u.prototype.componentWillReceiveProps=function(e){b&&(0,v.default)(e,this.props)||(this.haveOwnPropsChanged=!0)},u.prototype.componentWillUnmount=function(){this.tryUnsubscribe(),this.clearCache()},u.prototype.clearCache=function(){this.dispatchProps=null,this.stateProps=null,this.mergedProps=null,this.haveOwnPropsChanged=!0,this.hasStoreStateChanged=!0,this.haveStatePropsBeenPrecalculated=!1,this.statePropsPrecalculationError=null,this.renderedElement=null,this.finalMapDispatchToProps=null,this.finalMapStateToProps=null},u.prototype.handleChange=function(){if(this.unsubscribe){var e=this.store.getState(),t=this.state.storeState;if(!b||t!==e){if(b&&!this.doStatePropsDependOnOwnProps){var n=s(this.updateStatePropsIfNeeded,this);if(!n)return;n===O&&(this.statePropsPrecalculationError=O.value),this.haveStatePropsBeenPrecalculated=!0}this.hasStoreStateChanged=!0,this.setState({storeState:e})}}},u.prototype.getWrappedInstance=function(){return(0,w.default)(E,"To access the wrapped instance, you need to specify { withRef: true } as the fourth argument of the connect() call."),this.refs.wrappedInstance},u.prototype.render=function(){var t=this.haveOwnPropsChanged,n=this.hasStoreStateChanged,r=this.haveStatePropsBeenPrecalculated,o=this.statePropsPrecalculationError,i=this.renderedElement;if(this.haveOwnPropsChanged=!1,this.hasStoreStateChanged=!1,this.haveStatePropsBeenPrecalculated=!1,this.statePropsPrecalculationError=null,o)throw o;var a=!0,u=!0;b&&i&&(a=n||t&&this.doStatePropsDependOnOwnProps,u=t&&this.doDispatchPropsDependOnOwnProps);var s=!1,c=!1;r?s=!0:a&&(s=this.updateStatePropsIfNeeded()),u&&(c=this.updateDispatchPropsIfNeeded());var p=!0;return p=!!(s||c||t)&&this.updateMergedPropsIfNeeded(),!p&&i?i:(E?this.renderedElement=(0,f.createElement)(e,l({},this.mergedProps,{ref:"wrappedInstance"})):this.renderedElement=(0,f.createElement)(e,this.mergedProps),this.renderedElement)},u}(f.Component);return r.displayName=n,r.WrappedComponent=e,r.contextTypes={store:d.default},r.propTypes={store:d.default},(0,x.default)(r,e)}}var l=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e};t.__esModule=!0,t.default=c;var f=n(5),p=n(133),d=r(p),h=n(294),v=r(h),m=n(295),y=r(m),g=n(134),b=(r(g),n(65)),_=(r(b),n(98)),x=r(_),E=n(33),w=r(E),S=function(e){return{}},C=function(e){return{dispatch:e}},P=function(e,t,n){return l({},n,e,t)},O={value:null},T=0},function(e,t){"use strict";function n(e,t){if(e===t)return!0;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(var o=Object.prototype.hasOwnProperty,i=0;i<n.length;i++)if(!o.call(t,n[i])||e[n[i]]!==t[n[i]])return!1;return!0}t.__esModule=!0,t.default=n},function(e,t,n){"use strict";function r(e){return function(t){return(0,o.bindActionCreators)(e,t)}}t.__esModule=!0,t.default=r;var o=n(175)},function(e,t,n){"use strict";var r=n(4),o=n(95),i={focusDOMComponent:function(){o(r.getNodeFromInstance(this))}};e.exports=i},function(e,t,n){"use strict";function r(){var e=window.opera;return"object"==typeof e&&"function"==typeof e.version&&parseInt(e.version(),10)<=12}function o(e){return(e.ctrlKey||e.altKey||e.metaKey)&&!(e.ctrlKey&&e.altKey)}function i(e){switch(e){case T.topCompositionStart:return k.compositionStart;case T.topCompositionEnd:return k.compositionEnd;case T.topCompositionUpdate:return k.compositionUpdate}}function a(e,t){return e===T.topKeyDown&&t.keyCode===x}function u(e,t){switch(e){case T.topKeyUp:return _.indexOf(t.keyCode)!==-1;case T.topKeyDown:return t.keyCode!==x;case T.topKeyPress:case T.topMouseDown:case T.topBlur:return!0;default:return!1}}function s(e){var t=e.detail;return"object"==typeof t&&"data"in t?t.data:null}function c(e,t,n,r){var o,c;if(E?o=i(e):R?u(e,n)&&(o=k.compositionEnd):a(e,n)&&(o=k.compositionStart),!o)return null;C&&(R||o!==k.compositionStart?o===k.compositionEnd&&R&&(c=R.getData()):R=m.getPooled(r));var l=y.getPooled(o,t,n,r);if(c)l.data=c;else{var f=s(n);null!==f&&(l.data=f)}return h.accumulateTwoPhaseDispatches(l),l}function l(e,t){switch(e){case T.topCompositionEnd:return s(t);case T.topKeyPress:var n=t.which;return n!==P?null:(A=!0,O);case T.topTextInput:var r=t.data;return r===O&&A?null:r;default:return null}}function f(e,t){if(R){if(e===T.topCompositionEnd||u(e,t)){var n=R.getData();return m.release(R),R=null,n}return null}switch(e){case T.topPaste:return null;case T.topKeyPress:return t.which&&!o(t)?String.fromCharCode(t.which):null;case T.topCompositionEnd:return C?null:t.data;default:return null}}function p(e,t,n,r){var o;if(o=S?l(e,n):f(e,n),!o)return null;var i=g.getPooled(k.beforeInput,t,n,r);return i.data=o,h.accumulateTwoPhaseDispatches(i),i}var d=n(12),h=n(29),v=n(6),m=n(303),y=n(342),g=n(345),b=n(14),_=[9,13,27,32],x=229,E=v.canUseDOM&&"CompositionEvent"in window,w=null;v.canUseDOM&&"documentMode"in document&&(w=document.documentMode);var S=v.canUseDOM&&"TextEvent"in window&&!w&&!r(),C=v.canUseDOM&&(!E||w&&w>8&&w<=11),P=32,O=String.fromCharCode(P),T=d.topLevelTypes,k={beforeInput:{phasedRegistrationNames:{bubbled:b({onBeforeInput:null}),captured:b({onBeforeInputCapture:null})},dependencies:[T.topCompositionEnd,T.topKeyPress,T.topTextInput,T.topPaste]},compositionEnd:{phasedRegistrationNames:{bubbled:b({onCompositionEnd:null}),captured:b({onCompositionEndCapture:null})},dependencies:[T.topBlur,T.topCompositionEnd,T.topKeyDown,T.topKeyPress,T.topKeyUp,T.topMouseDown]},compositionStart:{phasedRegistrationNames:{bubbled:b({onCompositionStart:null}),captured:b({onCompositionStartCapture:null})},dependencies:[T.topBlur,T.topCompositionStart,T.topKeyDown,T.topKeyPress,T.topKeyUp,T.topMouseDown]},compositionUpdate:{phasedRegistrationNames:{bubbled:b({onCompositionUpdate:null}),captured:b({onCompositionUpdateCapture:null})},dependencies:[T.topBlur,T.topCompositionUpdate,T.topKeyDown,T.topKeyPress,T.topKeyUp,T.topMouseDown]}},A=!1,R=null,M={eventTypes:k,extractEvents:function(e,t,n,r){return[c(e,t,n,r),p(e,t,n,r)]}};e.exports=M},function(e,t,n){"use strict";var r=n(135),o=n(6),i=(n(7),n(194),n(351)),a=n(200),u=n(203),s=(n(2),u(function(e){return a(e)})),c=!1,l="cssFloat";if(o.canUseDOM){var f=document.createElement("div").style;try{f.font=""}catch(e){c=!0}void 0===document.documentElement.style.cssFloat&&(l="styleFloat")}var p={createMarkupForStyles:function(e,t){var n="";for(var r in e)if(e.hasOwnProperty(r)){var o=e[r];null!=o&&(n+=s(r)+":",n+=i(r,o,t)+";")}return n||null},setValueForStyles:function(e,t,n){var o=e.style;for(var a in t)if(t.hasOwnProperty(a)){var u=i(a,t[a],n);if("float"!==a&&"cssFloat"!==a||(a=l),u)o[a]=u;else{var s=c&&r.shorthandPropertyExpansions[a];if(s)for(var f in s)o[f]="";else o[a]=""}}}};e.exports=p},function(e,t,n){"use strict";function r(e){var t=e.nodeName&&e.nodeName.toLowerCase();return"select"===t||"input"===t&&"file"===e.type}function o(e){var t=S.getPooled(A.change,M,e,C(e));_.accumulateTwoPhaseDispatches(t),w.batchedUpdates(i,t)}function i(e){b.enqueueEvents(e),b.processEventQueue(!1)}function a(e,t){R=e,M=t,R.attachEvent("onchange",o)}function u(){R&&(R.detachEvent("onchange",o),R=null,M=null)}function s(e,t){if(e===k.topChange)return t}function c(e,t,n){e===k.topFocus?(u(),a(t,n)):e===k.topBlur&&u()}function l(e,t){R=e,M=t,I=e.value,N=Object.getOwnPropertyDescriptor(e.constructor.prototype,"value"),Object.defineProperty(R,"value",D),R.attachEvent?R.attachEvent("onpropertychange",p):R.addEventListener("propertychange",p,!1)}function f(){R&&(delete R.value,R.detachEvent?R.detachEvent("onpropertychange",p):R.removeEventListener("propertychange",p,!1),R=null,M=null,I=null,N=null)}function p(e){if("value"===e.propertyName){var t=e.srcElement.value;t!==I&&(I=t,o(e))}}function d(e,t){if(e===k.topInput)return t}function h(e,t,n){e===k.topFocus?(f(),l(t,n)):e===k.topBlur&&f()}function v(e,t){if((e===k.topSelectionChange||e===k.topKeyUp||e===k.topKeyDown)&&R&&R.value!==I)return I=R.value,M}function m(e){return e.nodeName&&"input"===e.nodeName.toLowerCase()&&("checkbox"===e.type||"radio"===e.type)}function y(e,t){if(e===k.topClick)return t}var g=n(12),b=n(28),_=n(29),x=n(6),E=n(4),w=n(10),S=n(13),C=n(83),P=n(85),O=n(163),T=n(14),k=g.topLevelTypes,A={change:{phasedRegistrationNames:{bubbled:T({onChange:null}),captured:T({onChangeCapture:null})},dependencies:[k.topBlur,k.topChange,k.topClick,k.topFocus,k.topInput,k.topKeyDown,k.topKeyUp,k.topSelectionChange]}},R=null,M=null,I=null,N=null,j=!1;x.canUseDOM&&(j=P("change")&&(!("documentMode"in document)||document.documentMode>8));var F=!1;x.canUseDOM&&(F=P("input")&&(!("documentMode"in document)||document.documentMode>11));var D={get:function(){return N.get.call(this)},set:function(e){I=""+e,N.set.call(this,e)}},U={eventTypes:A,extractEvents:function(e,t,n,o){var i,a,u=t?E.getNodeFromInstance(t):window;if(r(u)?j?i=s:a=c:O(u)?F?i=d:(i=v,a=h):m(u)&&(i=y),i){var l=i(e,t);if(l){var f=S.getPooled(A.change,l,n,o);return f.type="change",_.accumulateTwoPhaseDispatches(f),f}}a&&a(e,u,t)}};e.exports=U},function(e,t,n){"use strict";function r(e){return e.substring(1,e.indexOf(" "))}var o=n(23),i=n(6),a=n(197),u=n(9),s=n(97),c=n(1),l=/^(<[^ \/>]+)/,f="data-danger-index",p={dangerouslyRenderMarkup:function(e){i.canUseDOM?void 0:c(!1);for(var t,n={},o=0;o<e.length;o++)e[o]?void 0:c(!1),t=r(e[o]),t=s(t)?t:"*",n[t]=n[t]||[],n[t][o]=e[o];var p=[],d=0;for(t in n)if(n.hasOwnProperty(t)){var h,v=n[t];for(h in v)if(v.hasOwnProperty(h)){var m=v[h];v[h]=m.replace(l,"$1 "+f+'="'+h+'" ')}for(var y=a(v.join(""),u),g=0;g<y.length;++g){var b=y[g];b.hasAttribute&&b.hasAttribute(f)&&(h=+b.getAttribute(f),b.removeAttribute(f),p.hasOwnProperty(h)?c(!1):void 0,p[h]=b,d+=1)}}return d!==p.length?c(!1):void 0,p.length!==e.length?c(!1):void 0,p},dangerouslyReplaceNodeWithMarkup:function(e,t){if(i.canUseDOM?void 0:c(!1),t?void 0:c(!1),"HTML"===e.nodeName?c(!1):void 0,"string"==typeof t){var n=a(t,u)[0];e.parentNode.replaceChild(n,e)}else o.replaceChildWithTree(e,t)}};e.exports=p},function(e,t,n){"use strict";var r=n(14),o=[r({ResponderEventPlugin:null}),r({SimpleEventPlugin:null}),r({TapEventPlugin:null}),r({EnterLeaveEventPlugin:null}),r({ChangeEventPlugin:null}),r({SelectEventPlugin:null}),r({BeforeInputEventPlugin:null})];e.exports=o},function(e,t,n){"use strict";var r=n(12),o=n(29),i=n(4),a=n(50),u=n(14),s=r.topLevelTypes,c={mouseEnter:{registrationName:u({onMouseEnter:null}),dependencies:[s.topMouseOut,s.topMouseOver]},mouseLeave:{registrationName:u({onMouseLeave:null}),dependencies:[s.topMouseOut,s.topMouseOver]}},l={eventTypes:c,extractEvents:function(e,t,n,r){if(e===s.topMouseOver&&(n.relatedTarget||n.fromElement))return null;if(e!==s.topMouseOut&&e!==s.topMouseOver)return null;var u;if(r.window===r)u=r;else{var l=r.ownerDocument;u=l?l.defaultView||l.parentWindow:window}var f,p;if(e===s.topMouseOut){f=t;var d=n.relatedTarget||n.toElement;p=d?i.getClosestInstanceFromNode(d):null}else f=null,p=t;if(f===p)return null;var h=null==f?u:i.getNodeFromInstance(f),v=null==p?u:i.getNodeFromInstance(p),m=a.getPooled(c.mouseLeave,f,n,r);m.type="mouseleave",m.target=h,m.relatedTarget=v;var y=a.getPooled(c.mouseEnter,p,n,r);return y.type="mouseenter",y.target=v,y.relatedTarget=h,o.accumulateEnterLeaveDispatches(m,y,f,p),[m,y]}};e.exports=l},function(e,t,n){"use strict";function r(e){this._root=e,this._startText=this.getText(),this._fallbackText=null}var o=n(3),i=n(16),a=n(162);o(r.prototype,{destructor:function(){this._root=null,this._startText=null,this._fallbackText=null},getText:function(){return"value"in this._root?this._root.value:this._root[a()]},getData:function(){if(this._fallbackText)return this._fallbackText;var e,t,n=this._startText,r=n.length,o=this.getText(),i=o.length;for(e=0;e<r&&n[e]===o[e];e++);var a=r-e;for(t=1;t<=a&&n[r-t]===o[i-t];t++);var u=t>1?1-t:void 0;return this._fallbackText=o.slice(e,u),this._fallbackText}}),i.addPoolingTo(r),e.exports=r},function(e,t,n){"use strict";var r=n(19),o=r.injection.MUST_USE_PROPERTY,i=r.injection.HAS_BOOLEAN_VALUE,a=r.injection.HAS_SIDE_EFFECTS,u=r.injection.HAS_NUMERIC_VALUE,s=r.injection.HAS_POSITIVE_NUMERIC_VALUE,c=r.injection.HAS_OVERLOADED_BOOLEAN_VALUE,l={isCustomAttribute:RegExp.prototype.test.bind(new RegExp("^(data|aria)-["+r.ATTRIBUTE_NAME_CHAR+"]*$")),Properties:{accept:0,acceptCharset:0,accessKey:0,action:0,allowFullScreen:i,allowTransparency:0,alt:0,async:i,autoComplete:0,autoPlay:i,capture:i,cellPadding:0,cellSpacing:0,charSet:0,challenge:0,checked:o|i,cite:0,classID:0,className:0,cols:s,colSpan:0,content:0,contentEditable:0,contextMenu:0,controls:i,coords:0,crossOrigin:0,data:0,dateTime:0,default:i,defer:i,dir:0,disabled:i,download:c,draggable:0,encType:0,form:0,formAction:0,formEncType:0,formMethod:0,formNoValidate:i,formTarget:0,frameBorder:0,headers:0,height:0,hidden:i,high:0,href:0,hrefLang:0,htmlFor:0,httpEquiv:0,icon:0,id:0,inputMode:0,integrity:0,is:0,keyParams:0,keyType:0,kind:0,label:0,lang:0,list:0,loop:i,low:0,manifest:0,marginHeight:0,marginWidth:0,max:0,maxLength:0,media:0,mediaGroup:0,method:0,min:0,minLength:0,multiple:o|i,muted:o|i,name:0,nonce:0,noValidate:i,open:i,optimum:0,pattern:0,placeholder:0,poster:0,preload:0,profile:0,radioGroup:0,readOnly:i,rel:0,required:i,reversed:i,role:0,rows:s,rowSpan:u,sandbox:0,scope:0,scoped:i,scrolling:0,seamless:i,selected:o|i,shape:0,size:s,sizes:0,span:s,spellCheck:0,src:0,srcDoc:0,srcLang:0,srcSet:0,start:u,step:0,style:0,summary:0,tabIndex:0,target:0,title:0,type:0,useMap:0,value:o|a,width:0,wmode:0,wrap:0,about:0,datatype:0,inlist:0,prefix:0,property:0,resource:0,typeof:0,vocab:0,autoCapitalize:0,autoCorrect:0,autoSave:0,color:0,itemProp:0,itemScope:i,itemType:0,itemID:0,itemRef:0,results:0,security:0,unselectable:0},DOMAttributeNames:{acceptCharset:"accept-charset",className:"class",htmlFor:"for",httpEquiv:"http-equiv"},DOMPropertyNames:{}};e.exports=l},function(e,t,n){"use strict";function r(e,t,n){var r=void 0===e[n];null!=t&&r&&(e[n]=i(t))}var o=n(21),i=n(84),a=(n(73),n(87)),u=n(88),s=(n(2),{instantiateChildren:function(e,t,n){if(null==e)return null;var o={};return u(e,r,o),o},updateChildren:function(e,t,n,r,u){if(t||e){var s,c;for(s in t)if(t.hasOwnProperty(s)){c=e&&e[s];var l=c&&c._currentElement,f=t[s];if(null!=c&&a(l,f))o.receiveComponent(c,f,r,u),t[s]=c;else{c&&(n[s]=o.getNativeNode(c),o.unmountComponent(c,!1));var p=i(f);t[s]=p}}for(s in e)!e.hasOwnProperty(s)||t&&t.hasOwnProperty(s)||(c=e[s],n[s]=o.getNativeNode(c),o.unmountComponent(c,!1))}},unmountChildren:function(e,t){for(var n in e)if(e.hasOwnProperty(n)){var r=e[n];o.unmountComponent(r,t)}}});e.exports=s},function(e,t,n){"use strict";function r(e){return(""+e).replace(_,"$&/")}function o(e,t){this.func=e,this.context=t,this.count=0}function i(e,t,n){var r=e.func,o=e.context;r.call(o,t,e.count++)}function a(e,t,n){if(null==e)return e;var r=o.getPooled(t,n);y(e,i,r),o.release(r)}function u(e,t,n,r){this.result=e,this.keyPrefix=t,this.func=n,this.context=r,this.count=0}function s(e,t,n){var o=e.result,i=e.keyPrefix,a=e.func,u=e.context,s=a.call(u,t,e.count++);Array.isArray(s)?c(s,o,n,m.thatReturnsArgument):null!=s&&(v.isValidElement(s)&&(s=v.cloneAndReplaceKey(s,i+(!s.key||t&&t.key===s.key?"":r(s.key)+"/")+n)),o.push(s))}function c(e,t,n,o,i){var a="";null!=n&&(a=r(n)+"/");var c=u.getPooled(t,a,o,i);y(e,s,c),u.release(c)}function l(e,t,n){if(null==e)return e;var r=[];return c(e,r,null,t,n),r}function f(e,t,n){return null}function p(e,t){return y(e,f,null)}function d(e){var t=[];return c(e,t,null,m.thatReturnsArgument),t}var h=n(16),v=n(17),m=n(9),y=n(88),g=h.twoArgumentPooler,b=h.fourArgumentPooler,_=/\/+/g;o.prototype.destructor=function(){this.func=null,this.context=null,this.count=0},h.addPoolingTo(o,g),u.prototype.destructor=function(){this.result=null,this.keyPrefix=null,this.func=null,this.context=null,this.count=0},h.addPoolingTo(u,b);var x={forEach:a,map:l,mapIntoWithKeyPrefixInternal:c, count:p,toArray:d};e.exports=x},function(e,t,n){"use strict";function r(e,t){var n=E.hasOwnProperty(t)?E[t]:null;S.hasOwnProperty(t)&&(n!==_.OVERRIDE_BASE?m(!1):void 0),e&&(n!==_.DEFINE_MANY&&n!==_.DEFINE_MANY_MERGED?m(!1):void 0)}function o(e,t){if(t){"function"==typeof t?m(!1):void 0,d.isValidElement(t)?m(!1):void 0;var n=e.prototype,o=n.__reactAutoBindPairs;t.hasOwnProperty(b)&&w.mixins(e,t.mixins);for(var i in t)if(t.hasOwnProperty(i)&&i!==b){var a=t[i],c=n.hasOwnProperty(i);if(r(c,i),w.hasOwnProperty(i))w[i](e,a);else{var l=E.hasOwnProperty(i),f="function"==typeof a,p=f&&!l&&!c&&t.autobind!==!1;if(p)o.push(i,a),n[i]=a;else if(c){var h=E[i];!l||h!==_.DEFINE_MANY_MERGED&&h!==_.DEFINE_MANY?m(!1):void 0,h===_.DEFINE_MANY_MERGED?n[i]=u(n[i],a):h===_.DEFINE_MANY&&(n[i]=s(n[i],a))}else n[i]=a}}}}function i(e,t){if(t)for(var n in t){var r=t[n];if(t.hasOwnProperty(n)){var o=n in w;o?m(!1):void 0;var i=n in e;i?m(!1):void 0,e[n]=r}}}function a(e,t){e&&t&&"object"==typeof e&&"object"==typeof t?void 0:m(!1);for(var n in t)t.hasOwnProperty(n)&&(void 0!==e[n]?m(!1):void 0,e[n]=t[n]);return e}function u(e,t){return function(){var n=e.apply(this,arguments),r=t.apply(this,arguments);if(null==n)return r;if(null==r)return n;var o={};return a(o,n),a(o,r),o}}function s(e,t){return function(){e.apply(this,arguments),t.apply(this,arguments)}}function c(e,t){var n=t.bind(e);return n}function l(e){for(var t=e.__reactAutoBindPairs,n=0;n<t.length;n+=2){var r=t[n],o=t[n+1];e[r]=c(e,o)}}var f=n(3),p=n(308),d=n(17),h=(n(79),n(78),n(152)),v=n(24),m=n(1),y=n(32),g=n(14),b=(n(2),g({mixins:null})),_=y({DEFINE_ONCE:null,DEFINE_MANY:null,OVERRIDE_BASE:null,DEFINE_MANY_MERGED:null}),x=[],E={mixins:_.DEFINE_MANY,statics:_.DEFINE_MANY,propTypes:_.DEFINE_MANY,contextTypes:_.DEFINE_MANY,childContextTypes:_.DEFINE_MANY,getDefaultProps:_.DEFINE_MANY_MERGED,getInitialState:_.DEFINE_MANY_MERGED,getChildContext:_.DEFINE_MANY_MERGED,render:_.DEFINE_ONCE,componentWillMount:_.DEFINE_MANY,componentDidMount:_.DEFINE_MANY,componentWillReceiveProps:_.DEFINE_MANY,shouldComponentUpdate:_.DEFINE_ONCE,componentWillUpdate:_.DEFINE_MANY,componentDidUpdate:_.DEFINE_MANY,componentWillUnmount:_.DEFINE_MANY,updateComponent:_.OVERRIDE_BASE},w={displayName:function(e,t){e.displayName=t},mixins:function(e,t){if(t)for(var n=0;n<t.length;n++)o(e,t[n])},childContextTypes:function(e,t){e.childContextTypes=f({},e.childContextTypes,t)},contextTypes:function(e,t){e.contextTypes=f({},e.contextTypes,t)},getDefaultProps:function(e,t){e.getDefaultProps?e.getDefaultProps=u(e.getDefaultProps,t):e.getDefaultProps=t},propTypes:function(e,t){e.propTypes=f({},e.propTypes,t)},statics:function(e,t){i(e,t)},autobind:function(){}},S={replaceState:function(e,t){this.updater.enqueueReplaceState(this,e),t&&this.updater.enqueueCallback(this,t,"replaceState")},isMounted:function(){return this.updater.isMounted(this)}},C=function(){};f(C.prototype,p.prototype,S);var P={createClass:function(e){var t=function(e,t,n){this.__reactAutoBindPairs.length&&l(this),this.props=e,this.context=t,this.refs=v,this.updater=n||h,this.state=null;var r=this.getInitialState?this.getInitialState():null;"object"!=typeof r||Array.isArray(r)?m(!1):void 0,this.state=r};t.prototype=new C,t.prototype.constructor=t,t.prototype.__reactAutoBindPairs=[],x.forEach(o.bind(null,t)),o(t,e),t.getDefaultProps&&(t.defaultProps=t.getDefaultProps()),t.prototype.render?void 0:m(!1);for(var n in E)t.prototype[n]||(t.prototype[n]=null);return t},injection:{injectMixin:function(e){x.push(e)}}};e.exports=P},function(e,t,n){"use strict";function r(e,t,n){this.props=e,this.context=t,this.refs=i,this.updater=n||o}var o=n(152),i=(n(7),n(158),n(24)),a=n(1);n(2),r.prototype.isReactComponent={},r.prototype.setState=function(e,t){"object"!=typeof e&&"function"!=typeof e&&null!=e?a(!1):void 0,this.updater.enqueueSetState(this,e),t&&this.updater.enqueueCallback(this,t,"setState")},r.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this),e&&this.updater.enqueueCallback(this,e,"forceUpdate")},e.exports=r},function(e,t,n){"use strict";function r(e){var t=e._currentElement._owner||null;if(t){var n=t.getName();if(n)return" Check the render method of `"+n+"`."}return""}function o(e){}function i(e,t){}function a(e){return e.prototype&&e.prototype.isReactComponent}var u=n(3),s=n(75),c=n(20),l=n(17),f=n(76),p=n(77),d=(n(7),n(151)),h=n(79),v=(n(78),n(21)),m=n(154),y=n(24),g=n(1),b=n(87);n(2),o.prototype.render=function(){var e=p.get(this)._currentElement.type,t=e(this.props,this.context,this.updater);return i(e,t),t};var _=1,x={construct:function(e){this._currentElement=e,this._rootNodeID=null,this._instance=null,this._nativeParent=null,this._nativeContainerInfo=null,this._updateBatchNumber=null,this._pendingElement=null,this._pendingStateQueue=null,this._pendingReplaceState=!1,this._pendingForceUpdate=!1,this._renderedNodeType=null,this._renderedComponent=null,this._context=null,this._mountOrder=0,this._topLevelWrapper=null,this._pendingCallbacks=null,this._calledComponentWillUnmount=!1},mountComponent:function(e,t,n,r){this._context=r,this._mountOrder=_++,this._nativeParent=t,this._nativeContainerInfo=n;var u,s=this._processProps(this._currentElement.props),c=this._processContext(r),f=this._currentElement.type,d=this._constructComponent(s,c);a(f)||null!=d&&null!=d.render||(u=d,i(f,u),null===d||d===!1||l.isValidElement(d)?void 0:g(!1),d=new o(f)),d.props=s,d.context=c,d.refs=y,d.updater=m,this._instance=d,p.set(d,this);var h=d.state;void 0===h&&(d.state=h=null),"object"!=typeof h||Array.isArray(h)?g(!1):void 0,this._pendingStateQueue=null,this._pendingReplaceState=!1,this._pendingForceUpdate=!1;var v;return v=d.unstable_handleError?this.performInitialMountWithErrorHandling(u,t,n,e,r):this.performInitialMount(u,t,n,e,r),d.componentDidMount&&e.getReactMountReady().enqueue(d.componentDidMount,d),v},_constructComponent:function(e,t){return this._constructComponentWithoutOwner(e,t)},_constructComponentWithoutOwner:function(e,t){var n,r=this._currentElement.type;return n=a(r)?new r(e,t,m):r(e,t,m)},performInitialMountWithErrorHandling:function(e,t,n,r,o){var i,a=r.checkpoint();try{i=this.performInitialMount(e,t,n,r,o)}catch(u){r.rollback(a),this._instance.unstable_handleError(u),this._pendingStateQueue&&(this._instance.state=this._processPendingState(this._instance.props,this._instance.context)),a=r.checkpoint(),this._renderedComponent.unmountComponent(!0),r.rollback(a),i=this.performInitialMount(e,t,n,r,o)}return i},performInitialMount:function(e,t,n,r,o){var i=this._instance;i.componentWillMount&&(i.componentWillMount(),this._pendingStateQueue&&(i.state=this._processPendingState(i.props,i.context))),void 0===e&&(e=this._renderValidatedComponent()),this._renderedNodeType=d.getType(e),this._renderedComponent=this._instantiateReactComponent(e);var a=v.mountComponent(this._renderedComponent,r,t,n,this._processChildContext(o));return a},getNativeNode:function(){return v.getNativeNode(this._renderedComponent)},unmountComponent:function(e){if(this._renderedComponent){var t=this._instance;if(t.componentWillUnmount&&!t._calledComponentWillUnmount)if(t._calledComponentWillUnmount=!0,e){var n=this.getName()+".componentWillUnmount()";f.invokeGuardedCallback(n,t.componentWillUnmount.bind(t))}else t.componentWillUnmount();this._renderedComponent&&(v.unmountComponent(this._renderedComponent,e),this._renderedNodeType=null,this._renderedComponent=null,this._instance=null),this._pendingStateQueue=null,this._pendingReplaceState=!1,this._pendingForceUpdate=!1,this._pendingCallbacks=null,this._pendingElement=null,this._context=null,this._rootNodeID=null,this._topLevelWrapper=null,p.remove(t)}},_maskContext:function(e){var t=this._currentElement.type,n=t.contextTypes;if(!n)return y;var r={};for(var o in n)r[o]=e[o];return r},_processContext:function(e){var t=this._maskContext(e);return t},_processChildContext:function(e){var t=this._currentElement.type,n=this._instance,r=n.getChildContext&&n.getChildContext();if(r){"object"!=typeof t.childContextTypes?g(!1):void 0;for(var o in r)o in t.childContextTypes?void 0:g(!1);return u({},e,r)}return e},_processProps:function(e){return e},_checkPropTypes:function(e,t,n){var o=this.getName();for(var i in e)if(e.hasOwnProperty(i)){var a;try{"function"!=typeof e[i]?g(!1):void 0,a=e[i](t,i,o,n)}catch(e){a=e}a instanceof Error&&(r(this),n===h.prop)}},receiveComponent:function(e,t,n){var r=this._currentElement,o=this._context;this._pendingElement=null,this.updateComponent(t,r,e,o,n)},performUpdateIfNecessary:function(e){null!=this._pendingElement?v.receiveComponent(this,this._pendingElement,e,this._context):null!==this._pendingStateQueue||this._pendingForceUpdate?this.updateComponent(e,this._currentElement,this._currentElement,this._context,this._context):this._updateBatchNumber=null},updateComponent:function(e,t,n,r,o){var i,a,u=this._instance,s=!1;this._context===o?i=u.context:(i=this._processContext(o),s=!0),t===n?a=n.props:(a=this._processProps(n.props),s=!0),s&&u.componentWillReceiveProps&&u.componentWillReceiveProps(a,i);var c=this._processPendingState(a,i),l=!0;!this._pendingForceUpdate&&u.shouldComponentUpdate&&(l=u.shouldComponentUpdate(a,c,i)),this._updateBatchNumber=null,l?(this._pendingForceUpdate=!1,this._performComponentUpdate(n,a,c,i,e,o)):(this._currentElement=n,this._context=o,u.props=a,u.state=c,u.context=i)},_processPendingState:function(e,t){var n=this._instance,r=this._pendingStateQueue,o=this._pendingReplaceState;if(this._pendingReplaceState=!1,this._pendingStateQueue=null,!r)return n.state;if(o&&1===r.length)return r[0];for(var i=u({},o?r[0]:n.state),a=o?1:0;a<r.length;a++){var s=r[a];u(i,"function"==typeof s?s.call(n,i,e,t):s)}return i},_performComponentUpdate:function(e,t,n,r,o,i){var a,u,s,c=this._instance,l=Boolean(c.componentDidUpdate);l&&(a=c.props,u=c.state,s=c.context),c.componentWillUpdate&&c.componentWillUpdate(t,n,r),this._currentElement=e,this._context=i,c.props=t,c.state=n,c.context=r,this._updateRenderedComponent(o,i),l&&o.getReactMountReady().enqueue(c.componentDidUpdate.bind(c,a,u,s),c)},_updateRenderedComponent:function(e,t){var n=this._renderedComponent,r=n._currentElement,o=this._renderValidatedComponent();if(b(r,o))v.receiveComponent(n,o,e,this._processChildContext(t));else{var i=v.getNativeNode(n);v.unmountComponent(n,!1),this._renderedNodeType=d.getType(o),this._renderedComponent=this._instantiateReactComponent(o);var a=v.mountComponent(this._renderedComponent,e,this._nativeParent,this._nativeContainerInfo,this._processChildContext(t));this._replaceNodeWithMarkup(i,a,n)}},_replaceNodeWithMarkup:function(e,t,n){s.replaceNodeWithMarkup(e,t,n)},_renderValidatedComponentWithoutOwnerOrContext:function(){var e=this._instance,t=e.render();return t},_renderValidatedComponent:function(){var e;c.current=this;try{e=this._renderValidatedComponentWithoutOwnerOrContext()}finally{c.current=null}return null===e||e===!1||l.isValidElement(e)?void 0:g(!1),e},attachRef:function(e,t){var n=this.getPublicInstance();null==n?g(!1):void 0;var r=t.getPublicInstance(),o=n.refs===y?n.refs={}:n.refs;o[e]=r},detachRef:function(e){var t=this.getPublicInstance().refs;delete t[e]},getName:function(){var e=this._currentElement.type,t=this._instance&&this._instance.constructor;return e.displayName||t&&t.displayName||e.name||t&&t.name||null},getPublicInstance:function(){var e=this._instance;return e instanceof o?null:e},_instantiateReactComponent:null},E={Mixin:x};e.exports=E},function(e,t,n){"use strict";var r=n(4),o=n(143),i=n(148),a=n(21),u=n(10),s=n(155),c=n(352),l=n(161),f=n(358);n(2),o.inject();var p={findDOMNode:c,render:i.render,unmountComponentAtNode:i.unmountComponentAtNode,version:s,unstable_batchedUpdates:u.batchedUpdates,unstable_renderSubtreeIntoContainer:f};"undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.inject&&__REACT_DEVTOOLS_GLOBAL_HOOK__.inject({ComponentTree:{getClosestInstanceFromNode:r.getClosestInstanceFromNode,getNodeFromInstance:function(e){return e._renderedComponent&&(e=l(e)),e?r.getNodeFromInstance(e):null}},Mount:i,Reconciler:a}),e.exports=p},function(e,t,n){"use strict";var r=n(47),o={getNativeProps:r.getNativeProps};e.exports=o},function(e,t,n){"use strict";function r(e,t){t&&($[e._tag]&&(null!=t.children||null!=t.dangerouslySetInnerHTML?N(!1):void 0),null!=t.dangerouslySetInnerHTML&&(null!=t.children?N(!1):void 0,"object"==typeof t.dangerouslySetInnerHTML&&q in t.dangerouslySetInnerHTML?void 0:N(!1)),null!=t.style&&"object"!=typeof t.style?N(!1):void 0)}function o(e,t,n,r){if(!(r instanceof M)){var o=e._nativeContainerInfo,a=o._node&&o._node.nodeType===H,u=a?o._node:o._ownerDocument;L(t,u),r.getReactMountReady().enqueue(i,{inst:e,registrationName:t,listener:n})}}function i(){var e=this;_.putListener(e.inst,e.registrationName,e.listener)}function a(){var e=this;T.postMountWrapper(e)}function u(){var e=this;e._rootNodeID?void 0:N(!1);var t=U(e);switch(t?void 0:N(!1),e._tag){case"iframe":case"object":e._wrapperState.listeners=[E.trapBubbledEvent(b.topLevelTypes.topLoad,"load",t)];break;case"video":case"audio":e._wrapperState.listeners=[];for(var n in Y)Y.hasOwnProperty(n)&&e._wrapperState.listeners.push(E.trapBubbledEvent(b.topLevelTypes[n],Y[n],t));break;case"img":e._wrapperState.listeners=[E.trapBubbledEvent(b.topLevelTypes.topError,"error",t),E.trapBubbledEvent(b.topLevelTypes.topLoad,"load",t)];break;case"form":e._wrapperState.listeners=[E.trapBubbledEvent(b.topLevelTypes.topReset,"reset",t),E.trapBubbledEvent(b.topLevelTypes.topSubmit,"submit",t)];break;case"input":case"select":case"textarea":e._wrapperState.listeners=[E.trapBubbledEvent(b.topLevelTypes.topInvalid,"invalid",t)]}}function s(){k.postUpdateWrapper(this)}function c(e){J.call(Q,e)||(X.test(e)?void 0:N(!1),Q[e]=!0)}function l(e,t){return e.indexOf("-")>=0||null!=t.is}function f(e){var t=e.type;c(t),this._currentElement=e,this._tag=t.toLowerCase(),this._namespaceURI=null,this._renderedChildren=null,this._previousStyle=null,this._previousStyleCopy=null,this._nativeNode=null,this._nativeParent=null,this._rootNodeID=null,this._domID=null,this._nativeContainerInfo=null,this._wrapperState=null,this._topLevelWrapper=null,this._flags=0}var p=n(3),d=n(296),h=n(298),v=n(23),m=n(137),y=n(19),g=n(71),b=n(12),_=n(28),x=n(48),E=n(49),w=n(138),S=n(311),C=n(139),P=n(4),O=n(317),T=n(319),k=n(141),A=n(323),R=(n(7),n(330)),M=n(153),I=(n(9),n(52)),N=n(1),j=(n(85),n(14)),F=(n(54),n(89),n(2),C),D=_.deleteListener,U=P.getNodeFromInstance,L=E.listenTo,V=x.registrationNameModules,W={string:!0,number:!0},B=j({style:null}),q=j({__html:null}),z={children:null,dangerouslySetInnerHTML:null,suppressContentEditableWarning:null},H=11,Y={topAbort:"abort",topCanPlay:"canplay",topCanPlayThrough:"canplaythrough",topDurationChange:"durationchange",topEmptied:"emptied",topEncrypted:"encrypted",topEnded:"ended",topError:"error",topLoadedData:"loadeddata",topLoadedMetadata:"loadedmetadata",topLoadStart:"loadstart",topPause:"pause",topPlay:"play",topPlaying:"playing",topProgress:"progress",topRateChange:"ratechange",topSeeked:"seeked",topSeeking:"seeking",topStalled:"stalled",topSuspend:"suspend",topTimeUpdate:"timeupdate",topVolumeChange:"volumechange",topWaiting:"waiting"},K={area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0},G={listing:!0,pre:!0,textarea:!0},$=p({menuitem:!0},K),X=/^[a-zA-Z][a-zA-Z:_\.\-\d]*$/,Q={},J={}.hasOwnProperty,Z=1;f.displayName="ReactDOMComponent",f.Mixin={mountComponent:function(e,t,n,o){this._rootNodeID=Z++,this._domID=n._idCounter++,this._nativeParent=t,this._nativeContainerInfo=n;var i=this._currentElement.props;switch(this._tag){case"iframe":case"object":case"img":case"form":case"video":case"audio":this._wrapperState={listeners:null},e.getReactMountReady().enqueue(u,this);break;case"button":i=S.getNativeProps(this,i,t);break;case"input":O.mountWrapper(this,i,t),i=O.getNativeProps(this,i),e.getReactMountReady().enqueue(u,this);break;case"option":T.mountWrapper(this,i,t),i=T.getNativeProps(this,i);break;case"select":k.mountWrapper(this,i,t),i=k.getNativeProps(this,i),e.getReactMountReady().enqueue(u,this);break;case"textarea":A.mountWrapper(this,i,t),i=A.getNativeProps(this,i),e.getReactMountReady().enqueue(u,this)}r(this,i);var s,c;null!=t?(s=t._namespaceURI,c=t._tag):n._tag&&(s=n._namespaceURI,c=n._tag),(null==s||s===m.svg&&"foreignobject"===c)&&(s=m.html),s===m.html&&("svg"===this._tag?s=m.svg:"math"===this._tag&&(s=m.mathml)),this._namespaceURI=s;var l;if(e.useCreateElement){var f,p=n._ownerDocument;if(s===m.html)if("script"===this._tag){var h=p.createElement("div"),y=this._currentElement.type;h.innerHTML="<"+y+"></"+y+">",f=h.removeChild(h.firstChild)}else f=p.createElement(this._currentElement.type,i.is||null);else f=p.createElementNS(s,this._currentElement.type);P.precacheNode(this,f),this._flags|=F.hasCachedChildNodes,this._nativeParent||g.setAttributeForRoot(f),this._updateDOMProperties(null,i,e);var b=v(f);this._createInitialChildren(e,i,o,b),l=b}else{var _=this._createOpenTagMarkupAndPutListeners(e,i),x=this._createContentMarkup(e,i,o);l=!x&&K[this._tag]?_+"/>":_+">"+x+"</"+this._currentElement.type+">"}switch(this._tag){case"button":case"input":case"select":case"textarea":i.autoFocus&&e.getReactMountReady().enqueue(d.focusDOMComponent,this);break;case"option":e.getReactMountReady().enqueue(a,this)}return l},_createOpenTagMarkupAndPutListeners:function(e,t){var n="<"+this._currentElement.type;for(var r in t)if(t.hasOwnProperty(r)){var i=t[r];if(null!=i)if(V.hasOwnProperty(r))i&&o(this,r,i,e);else{r===B&&(i&&(i=this._previousStyleCopy=p({},t.style)),i=h.createMarkupForStyles(i,this));var a=null;null!=this._tag&&l(this._tag,t)?z.hasOwnProperty(r)||(a=g.createMarkupForCustomAttribute(r,i)):a=g.createMarkupForProperty(r,i),a&&(n+=" "+a)}}return e.renderToStaticMarkup?n:(this._nativeParent||(n+=" "+g.createMarkupForRoot()),n+=" "+g.createMarkupForID(this._domID))},_createContentMarkup:function(e,t,n){var r="",o=t.dangerouslySetInnerHTML;if(null!=o)null!=o.__html&&(r=o.__html);else{var i=W[typeof t.children]?t.children:null,a=null!=i?null:t.children;if(null!=i)r=I(i);else if(null!=a){var u=this.mountChildren(a,e,n);r=u.join("")}}return G[this._tag]&&"\n"===r.charAt(0)?"\n"+r:r},_createInitialChildren:function(e,t,n,r){var o=t.dangerouslySetInnerHTML;if(null!=o)null!=o.__html&&v.queueHTML(r,o.__html);else{var i=W[typeof t.children]?t.children:null,a=null!=i?null:t.children;if(null!=i)v.queueText(r,i);else if(null!=a)for(var u=this.mountChildren(a,e,n),s=0;s<u.length;s++)v.queueChild(r,u[s])}},receiveComponent:function(e,t,n){var r=this._currentElement;this._currentElement=e,this.updateComponent(t,r,e,n)},updateComponent:function(e,t,n,o){var i=t.props,a=this._currentElement.props;switch(this._tag){case"button":i=S.getNativeProps(this,i),a=S.getNativeProps(this,a);break;case"input":O.updateWrapper(this),i=O.getNativeProps(this,i),a=O.getNativeProps(this,a);break;case"option":i=T.getNativeProps(this,i),a=T.getNativeProps(this,a);break;case"select":i=k.getNativeProps(this,i),a=k.getNativeProps(this,a);break;case"textarea":A.updateWrapper(this),i=A.getNativeProps(this,i),a=A.getNativeProps(this,a)}r(this,a),this._updateDOMProperties(i,a,e),this._updateDOMChildren(i,a,e,o),"select"===this._tag&&e.getReactMountReady().enqueue(s,this)},_updateDOMProperties:function(e,t,n){var r,i,a;for(r in e)if(!t.hasOwnProperty(r)&&e.hasOwnProperty(r)&&null!=e[r])if(r===B){var u=this._previousStyleCopy;for(i in u)u.hasOwnProperty(i)&&(a=a||{},a[i]="");this._previousStyleCopy=null}else V.hasOwnProperty(r)?e[r]&&D(this,r):(y.properties[r]||y.isCustomAttribute(r))&&g.deleteValueForProperty(U(this),r);for(r in t){var s=t[r],c=r===B?this._previousStyleCopy:null!=e?e[r]:void 0;if(t.hasOwnProperty(r)&&s!==c&&(null!=s||null!=c))if(r===B)if(s?s=this._previousStyleCopy=p({},s):this._previousStyleCopy=null,c){for(i in c)!c.hasOwnProperty(i)||s&&s.hasOwnProperty(i)||(a=a||{},a[i]="");for(i in s)s.hasOwnProperty(i)&&c[i]!==s[i]&&(a=a||{},a[i]=s[i])}else a=s;else if(V.hasOwnProperty(r))s?o(this,r,s,n):c&&D(this,r);else if(l(this._tag,t))z.hasOwnProperty(r)||g.setValueForAttribute(U(this),r,s);else if(y.properties[r]||y.isCustomAttribute(r)){var f=U(this);null!=s?g.setValueForProperty(f,r,s):g.deleteValueForProperty(f,r)}}a&&h.setValueForStyles(U(this),a,this)},_updateDOMChildren:function(e,t,n,r){var o=W[typeof e.children]?e.children:null,i=W[typeof t.children]?t.children:null,a=e.dangerouslySetInnerHTML&&e.dangerouslySetInnerHTML.__html,u=t.dangerouslySetInnerHTML&&t.dangerouslySetInnerHTML.__html,s=null!=o?null:e.children,c=null!=i?null:t.children,l=null!=o||null!=a,f=null!=i||null!=u;null!=s&&null==c?this.updateChildren(null,n,r):l&&!f&&this.updateTextContent(""),null!=i?o!==i&&this.updateTextContent(""+i):null!=u?a!==u&&this.updateMarkup(""+u):null!=c&&this.updateChildren(c,n,r)},getNativeNode:function(){return U(this)},unmountComponent:function(e){switch(this._tag){case"iframe":case"object":case"img":case"form":case"video":case"audio":var t=this._wrapperState.listeners;if(t)for(var n=0;n<t.length;n++)t[n].remove();break;case"html":case"head":case"body":N(!1)}this.unmountChildren(e),P.uncacheNode(this),_.deleteAllListeners(this),w.unmountIDFromEnvironment(this._rootNodeID),this._rootNodeID=null,this._domID=null,this._wrapperState=null},getPublicInstance:function(){return U(this)}},p(f.prototype,f.Mixin,R.Mixin),e.exports=f},function(e,t,n){"use strict";function r(e,t,n,r,o,i){}var o=n(325),i=(n(2),[]),a={addDevtool:function(e){i.push(e)},removeDevtool:function(e){for(var t=0;t<i.length;t++)i[t]===e&&(i.splice(t,1),t--)},onCreateMarkupForProperty:function(e,t){r("onCreateMarkupForProperty",e,t)},onSetValueForProperty:function(e,t,n){r("onSetValueForProperty",e,t,n)},onDeleteValueForProperty:function(e,t){r("onDeleteValueForProperty",e,t)}};a.addDevtool(o),e.exports=a},function(e,t,n){"use strict";var r=n(3),o=n(23),i=n(4),a=function(e){this._currentElement=null,this._nativeNode=null,this._nativeParent=null,this._nativeContainerInfo=null,this._domID=null};r(a.prototype,{mountComponent:function(e,t,n,r){var a=n._idCounter++;this._domID=a,this._nativeParent=t,this._nativeContainerInfo=n;var u=" react-empty: "+this._domID+" ";if(e.useCreateElement){var s=n._ownerDocument,c=s.createComment(u);return i.precacheNode(this,c),o(c)}return e.renderToStaticMarkup?"":"<!--"+u+"-->"},receiveComponent:function(){},getNativeNode:function(){return i.getNodeFromInstance(this)},unmountComponent:function(){i.uncacheNode(this)}}),e.exports=a},function(e,t){"use strict";var n={useCreateElement:!0};e.exports=n},function(e,t,n){"use strict";var r=n(70),o=n(4),i={dangerouslyProcessChildrenUpdates:function(e,t){var n=o.getNodeFromInstance(e);r.processUpdates(n,t)}};e.exports=i},function(e,t,n){"use strict";function r(){this._rootNodeID&&p.updateWrapper(this)}function o(e){var t=this._currentElement.props,n=s.executeOnChange(t,e);l.asap(r,this);var o=t.name;if("radio"===t.type&&null!=o){for(var i=c.getNodeFromInstance(this),a=i;a.parentNode;)a=a.parentNode;for(var u=a.querySelectorAll("input[name="+JSON.stringify(""+o)+'][type="radio"]'),p=0;p<u.length;p++){var d=u[p];if(d!==i&&d.form===i.form){var h=c.getInstanceFromNode(d);h?void 0:f(!1),l.asap(r,h)}}}return n}var i=n(3),a=n(47),u=n(71),s=n(74),c=n(4),l=n(10),f=n(1),p=(n(2),{getNativeProps:function(e,t){var n=s.getValue(t),r=s.getChecked(t),o=i({type:void 0},a.getNativeProps(e,t),{defaultChecked:void 0,defaultValue:void 0,value:null!=n?n:e._wrapperState.initialValue,checked:null!=r?r:e._wrapperState.initialChecked,onChange:e._wrapperState.onChange});return o},mountWrapper:function(e,t){var n=t.defaultValue;e._wrapperState={initialChecked:t.defaultChecked||!1,initialValue:null!=n?n:null,listeners:null,onChange:o.bind(e)}},updateWrapper:function(e){var t=e._currentElement.props,n=t.checked;null!=n&&u.setValueForProperty(c.getNodeFromInstance(e),"checked",n||!1);var r=s.getValue(t);null!=r&&u.setValueForProperty(c.getNodeFromInstance(e),"value",""+r)}});e.exports=p},function(e,t,n){"use strict";var r=n(313);e.exports={debugTool:r}},function(e,t,n){"use strict";var r=n(3),o=n(306),i=n(4),a=n(141),u=(n(2),{mountWrapper:function(e,t,n){var r=null;if(null!=n){var o=n;"optgroup"===o._tag&&(o=o._nativeParent),null!=o&&"select"===o._tag&&(r=a.getSelectValueContext(o))}var i=null;if(null!=r)if(i=!1,Array.isArray(r)){for(var u=0;u<r.length;u++)if(""+r[u]==""+t.value){i=!0;break}}else i=""+r==""+t.value;e._wrapperState={selected:i}},postMountWrapper:function(e){var t=e._currentElement.props;if(null!=t.value){var n=i.getNodeFromInstance(e);n.setAttribute("value",t.value)}},getNativeProps:function(e,t){var n=r({selected:void 0,children:void 0},t);null!=e._wrapperState.selected&&(n.selected=e._wrapperState.selected);var i="";return o.forEach(t.children,function(e){null!=e&&("string"!=typeof e&&"number"!=typeof e||(i+=e))}),i&&(n.children=i),n}});e.exports=u},function(e,t,n){"use strict";function r(e,t,n,r){return e===n&&t===r}function o(e){var t=document.selection,n=t.createRange(),r=n.text.length,o=n.duplicate();o.moveToElementText(e),o.setEndPoint("EndToStart",n);var i=o.text.length,a=i+r;return{start:i,end:a}}function i(e){var t=window.getSelection&&window.getSelection();if(!t||0===t.rangeCount)return null;var n=t.anchorNode,o=t.anchorOffset,i=t.focusNode,a=t.focusOffset,u=t.getRangeAt(0);try{u.startContainer.nodeType,u.endContainer.nodeType}catch(e){return null}var s=r(t.anchorNode,t.anchorOffset,t.focusNode,t.focusOffset),c=s?0:u.toString().length,l=u.cloneRange();l.selectNodeContents(e),l.setEnd(u.startContainer,u.startOffset);var f=r(l.startContainer,l.startOffset,l.endContainer,l.endOffset),p=f?0:l.toString().length,d=p+c,h=document.createRange();h.setStart(n,o),h.setEnd(i,a);var v=h.collapsed;return{start:v?d:p,end:v?p:d}}function a(e,t){var n,r,o=document.selection.createRange().duplicate();void 0===t.end?(n=t.start,r=n):t.start>t.end?(n=t.end,r=t.start):(n=t.start,r=t.end),o.moveToElementText(e),o.moveStart("character",n),o.setEndPoint("EndToStart",o),o.moveEnd("character",r-n),o.select()}function u(e,t){if(window.getSelection){var n=window.getSelection(),r=e[l()].length,o=Math.min(t.start,r),i=void 0===t.end?o:Math.min(t.end,r);if(!n.extend&&o>i){var a=i;i=o,o=a}var u=c(e,o),s=c(e,i);if(u&&s){var f=document.createRange();f.setStart(u.node,u.offset),n.removeAllRanges(),o>i?(n.addRange(f),n.extend(s.node,s.offset)):(f.setEnd(s.node,s.offset),n.addRange(f))}}}var s=n(6),c=n(355),l=n(162),f=s.canUseDOM&&"selection"in document&&!("getSelection"in window),p={getOffsets:f?o:i,setOffsets:f?a:u};e.exports=p},function(e,t,n){"use strict";var r=n(143),o=n(336),i=n(155);r.inject();var a={renderToString:o.renderToString,renderToStaticMarkup:o.renderToStaticMarkup,version:i};e.exports=a},function(e,t,n){"use strict";var r=n(3),o=n(70),i=n(23),a=n(4),u=(n(7),n(52)),s=n(1),c=(n(89),function(e){this._currentElement=e,this._stringText=""+e,this._nativeNode=null,this._nativeParent=null,this._domID=null,this._mountIndex=0,this._closingComment=null,this._commentNodes=null});r(c.prototype,{mountComponent:function(e,t,n,r){var o=n._idCounter++,s=" react-text: "+o+" ",c=" /react-text ";if(this._domID=o,this._nativeParent=t,e.useCreateElement){var l=n._ownerDocument,f=l.createComment(s),p=l.createComment(c),d=i(l.createDocumentFragment());return i.queueChild(d,i(f)),this._stringText&&i.queueChild(d,i(l.createTextNode(this._stringText))),i.queueChild(d,i(p)),a.precacheNode(this,f),this._closingComment=p,d}var h=u(this._stringText);return e.renderToStaticMarkup?h:"<!--"+s+"-->"+h+"<!--"+c+"-->"},receiveComponent:function(e,t){if(e!==this._currentElement){this._currentElement=e;var n=""+e;if(n!==this._stringText){this._stringText=n;var r=this.getNativeNode();o.replaceDelimitedText(r[0],r[1],n)}}},getNativeNode:function(){var e=this._commentNodes;if(e)return e;if(!this._closingComment)for(var t=a.getNodeFromInstance(this),n=t.nextSibling;;){if(null==n?s(!1):void 0,8===n.nodeType&&" /react-text "===n.nodeValue){this._closingComment=n;break}n=n.nextSibling}return e=[this._nativeNode,this._closingComment],this._commentNodes=e,e},unmountComponent:function(){this._closingComment=null,this._commentNodes=null,a.uncacheNode(this)}}),e.exports=c},function(e,t,n){"use strict";function r(){this._rootNodeID&&p.updateWrapper(this)}function o(e){var t=this._currentElement.props,n=s.executeOnChange(t,e);return l.asap(r,this),n}var i=n(3),a=n(47),u=n(71),s=n(74),c=n(4),l=n(10),f=n(1),p=(n(2),{getNativeProps:function(e,t){null!=t.dangerouslySetInnerHTML?f(!1):void 0;var n=i({},a.getNativeProps(e,t),{defaultValue:void 0,value:void 0,children:e._wrapperState.initialValue,onChange:e._wrapperState.onChange});return n},mountWrapper:function(e,t){var n=t.defaultValue,r=t.children;null!=r&&(null!=n?f(!1):void 0,Array.isArray(r)&&(r.length<=1?void 0:f(!1),r=r[0]),n=""+r),null==n&&(n="");var i=s.getValue(t);e._wrapperState={initialValue:""+(null!=i?i:n),listeners:null,onChange:o.bind(e)}},updateWrapper:function(e){var t=e._currentElement.props,n=s.getValue(t);null!=n&&u.setValueForProperty(c.getNodeFromInstance(e),"value",""+n)}});e.exports=p},function(e,t,n){"use strict";function r(e,t){"_nativeNode"in e?void 0:s(!1),"_nativeNode"in t?void 0:s(!1);for(var n=0,r=e;r;r=r._nativeParent)n++;for(var o=0,i=t;i;i=i._nativeParent)o++;for(;n-o>0;)e=e._nativeParent,n--;for(;o-n>0;)t=t._nativeParent,o--;for(var a=n;a--;){if(e===t)return e;e=e._nativeParent,t=t._nativeParent}return null}function o(e,t){"_nativeNode"in e?void 0:s(!1),"_nativeNode"in t?void 0:s(!1);for(;t;){if(t===e)return!0;t=t._nativeParent}return!1}function i(e){return"_nativeNode"in e?void 0:s(!1),e._nativeParent}function a(e,t,n){for(var r=[];e;)r.push(e),e=e._nativeParent;var o;for(o=r.length;o-- >0;)t(r[o],!1,n);for(o=0;o<r.length;o++)t(r[o],!0,n)}function u(e,t,n,o,i){for(var a=e&&t?r(e,t):null,u=[];e&&e!==a;)u.push(e),e=e._nativeParent;for(var s=[];t&&t!==a;)s.push(t),t=t._nativeParent;var c;for(c=0;c<u.length;c++)n(u[c],!0,o);for(c=s.length;c-- >0;)n(s[c],!1,i)}var s=n(1);e.exports={isAncestor:o,getLowestCommonAncestor:r,getParentInstance:i,traverseTwoPhase:a,traverseEnterLeave:u}},function(e,t,n){"use strict";var r,o=(n(19),n(48),n(2),{onCreateMarkupForProperty:function(e,t){r(e)},onSetValueForProperty:function(e,t,n){r(t)},onDeleteValueForProperty:function(e,t){r(t)}});e.exports=o},function(e,t,n){"use strict";function r(e,t,n,r,o,i){}function o(e){}var i=(n(6),n(205),n(2),[]),a={addDevtool:function(e){i.push(e)},removeDevtool:function(e){for(var t=0;t<i.length;t++)i[t]===e&&(i.splice(t,1),t--)},beginProfiling:function(){},endProfiling:function(){},getFlushHistory:function(){},onBeginFlush:function(){r("onBeginFlush")},onEndFlush:function(){r("onEndFlush")},onBeginLifeCycleTimer:function(e,t){o(e),r("onBeginLifeCycleTimer",e,t)},onEndLifeCycleTimer:function(e,t){o(e),r("onEndLifeCycleTimer",e,t)},onBeginReconcilerTimer:function(e,t){o(e),r("onBeginReconcilerTimer",e,t)},onEndReconcilerTimer:function(e,t){o(e),r("onEndReconcilerTimer",e,t)},onBeginProcessingChildContext:function(){r("onBeginProcessingChildContext")},onEndProcessingChildContext:function(){r("onEndProcessingChildContext")},onNativeOperation:function(e,t,n){o(e),r("onNativeOperation",e,t,n)},onSetState:function(){r("onSetState")},onSetDisplayName:function(e,t){o(e),r("onSetDisplayName",e,t)},onSetChildren:function(e,t){o(e),r("onSetChildren",e,t)},onSetOwner:function(e,t){o(e),r("onSetOwner",e,t)},onSetText:function(e,t){o(e),r("onSetText",e,t)},onMountRootComponent:function(e){o(e),r("onMountRootComponent",e)},onMountComponent:function(e){o(e),r("onMountComponent",e)},onUpdateComponent:function(e){o(e),r("onUpdateComponent",e)},onUnmountComponent:function(e){o(e),r("onUnmountComponent",e)}};e.exports=a},function(e,t,n){"use strict";function r(e){o.enqueueEvents(e),o.processEventQueue(!1)}var o=n(28),i={handleTopLevel:function(e,t,n,i){ var a=o.extractEvents(e,t,n,i);r(a)}};e.exports=i},function(e,t,n){"use strict";function r(e){for(;e._nativeParent;)e=e._nativeParent;var t=f.getNodeFromInstance(e),n=t.parentNode;return f.getClosestInstanceFromNode(n)}function o(e,t){this.topLevelType=e,this.nativeEvent=t,this.ancestors=[]}function i(e){var t=d(e.nativeEvent),n=f.getClosestInstanceFromNode(t),o=n;do e.ancestors.push(o),o=o&&r(o);while(o);for(var i=0;i<e.ancestors.length;i++)n=e.ancestors[i],v._handleTopLevel(e.topLevelType,n,e.nativeEvent,d(e.nativeEvent))}function a(e){var t=h(window);e(t)}var u=n(3),s=n(94),c=n(6),l=n(16),f=n(4),p=n(10),d=n(83),h=n(198);u(o.prototype,{destructor:function(){this.topLevelType=null,this.nativeEvent=null,this.ancestors.length=0}}),l.addPoolingTo(o,l.twoArgumentPooler);var v={_enabled:!0,_handleTopLevel:null,WINDOW_HANDLE:c.canUseDOM?window:null,setHandleTopLevel:function(e){v._handleTopLevel=e},setEnabled:function(e){v._enabled=!!e},isEnabled:function(){return v._enabled},trapBubbledEvent:function(e,t,n){var r=n;return r?s.listen(r,t,v.dispatchEvent.bind(null,e)):null},trapCapturedEvent:function(e,t,n){var r=n;return r?s.capture(r,t,v.dispatchEvent.bind(null,e)):null},monitorScrollValue:function(e){var t=a.bind(null,e);s.listen(window,"scroll",t)},dispatchEvent:function(e,t){if(v._enabled){var n=o.getPooled(e,t);try{p.batchedUpdates(i,n)}finally{o.release(n)}}}};e.exports=v},function(e,t,n){"use strict";var r=n(19),o=n(28),i=n(72),a=n(75),u=n(307),s=n(144),c=n(49),l=n(150),f=n(10),p={Component:a.injection,Class:u.injection,DOMProperty:r.injection,EmptyComponent:s.injection,EventPluginHub:o.injection,EventPluginUtils:i.injection,EventEmitter:c.injection,NativeComponent:l.injection,Updates:f.injection};e.exports=p},function(e,t,n){"use strict";function r(e,t,n){return{type:f.INSERT_MARKUP,content:e,fromIndex:null,fromNode:null,toIndex:n,afterNode:t}}function o(e,t,n){return{type:f.MOVE_EXISTING,content:null,fromIndex:e._mountIndex,fromNode:p.getNativeNode(e),toIndex:n,afterNode:t}}function i(e,t){return{type:f.REMOVE_NODE,content:null,fromIndex:e._mountIndex,fromNode:t,toIndex:null,afterNode:null}}function a(e){return{type:f.SET_MARKUP,content:e,fromIndex:null,fromNode:null,toIndex:null,afterNode:null}}function u(e){return{type:f.TEXT_CONTENT,content:e,fromIndex:null,fromNode:null,toIndex:null,afterNode:null}}function s(e,t){return t&&(e=e||[],e.push(t)),e}function c(e,t){l.processChildrenUpdates(e,t)}var l=n(75),f=(n(7),n(149)),p=(n(20),n(21)),d=n(305),h=(n(9),n(353)),v=n(1),m={Mixin:{_reconcilerInstantiateChildren:function(e,t,n){return d.instantiateChildren(e,t,n)},_reconcilerUpdateChildren:function(e,t,n,r,o){var i;return i=h(t),d.updateChildren(e,i,n,r,o),i},mountChildren:function(e,t,n){var r=this._reconcilerInstantiateChildren(e,t,n);this._renderedChildren=r;var o=[],i=0;for(var a in r)if(r.hasOwnProperty(a)){var u=r[a],s=p.mountComponent(u,t,this,this._nativeContainerInfo,n);u._mountIndex=i++,o.push(s)}return o},updateTextContent:function(e){var t=this._renderedChildren;d.unmountChildren(t,!1);for(var n in t)t.hasOwnProperty(n)&&v(!1);var r=[u(e)];c(this,r)},updateMarkup:function(e){var t=this._renderedChildren;d.unmountChildren(t,!1);for(var n in t)t.hasOwnProperty(n)&&v(!1);var r=[a(e)];c(this,r)},updateChildren:function(e,t,n){this._updateChildren(e,t,n)},_updateChildren:function(e,t,n){var r=this._renderedChildren,o={},i=this._reconcilerUpdateChildren(r,e,o,t,n);if(i||r){var a,u=null,l=0,f=0,d=null;for(a in i)if(i.hasOwnProperty(a)){var h=r&&r[a],v=i[a];h===v?(u=s(u,this.moveChild(h,d,f,l)),l=Math.max(h._mountIndex,l),h._mountIndex=f):(h&&(l=Math.max(h._mountIndex,l)),u=s(u,this._mountChildAtIndex(v,d,f,t,n))),f++,d=p.getNativeNode(v)}for(a in o)o.hasOwnProperty(a)&&(u=s(u,this._unmountChild(r[a],o[a])));u&&c(this,u),this._renderedChildren=i}},unmountChildren:function(e){var t=this._renderedChildren;d.unmountChildren(t,e),this._renderedChildren=null},moveChild:function(e,t,n,r){if(e._mountIndex<r)return o(e,t,n)},createChild:function(e,t,n){return r(n,t,e._mountIndex)},removeChild:function(e,t){return i(e,t)},_mountChildAtIndex:function(e,t,n,r,o){var i=p.mountComponent(e,r,this,this._nativeContainerInfo,o);return e._mountIndex=n,this.createChild(e,t,i)},_unmountChild:function(e,t){var n=this.removeChild(e,t);return e._mountIndex=null,n}}};e.exports=m},function(e,t,n){"use strict";var r=n(1),o={isValidOwner:function(e){return!(!e||"function"!=typeof e.attachRef||"function"!=typeof e.detachRef)},addComponentAsRefTo:function(e,t,n){o.isValidOwner(n)?void 0:r(!1),n.attachRef(t,e)},removeComponentAsRefFrom:function(e,t,n){o.isValidOwner(n)?void 0:r(!1);var i=n.getPublicInstance();i&&i.refs[t]===e.getPublicInstance()&&n.detachRef(t)}};e.exports=o},function(e,t,n){"use strict";function r(e,t){return e===t?0!==e||1/e===1/t:e!==e&&t!==t}function o(e){function t(t,n,r,o,i,a){if(o=o||w,a=a||r,null==n[r]){var u=_[i];return t?new Error("Required "+u+" `"+a+"` was not specified in "+("`"+o+"`.")):null}return e(n,r,o,i,a)}var n=t.bind(null,!1);return n.isRequired=t.bind(null,!0),n}function i(e){function t(t,n,r,o,i){var a=t[n],u=m(a);if(u!==e){var s=_[o],c=y(a);return new Error("Invalid "+s+" `"+i+"` of type "+("`"+c+"` supplied to `"+r+"`, expected ")+("`"+e+"`."))}return null}return o(t)}function a(){return o(x.thatReturns(null))}function u(e){function t(t,n,r,o,i){if("function"!=typeof e)return new Error("Property `"+i+"` of component `"+r+"` has invalid PropType notation inside arrayOf.");var a=t[n];if(!Array.isArray(a)){var u=_[o],s=m(a);return new Error("Invalid "+u+" `"+i+"` of type "+("`"+s+"` supplied to `"+r+"`, expected an array."))}for(var c=0;c<a.length;c++){var l=e(a,c,r,o,i+"["+c+"]");if(l instanceof Error)return l}return null}return o(t)}function s(){function e(e,t,n,r,o){if(!b.isValidElement(e[t])){var i=_[r];return new Error("Invalid "+i+" `"+o+"` supplied to "+("`"+n+"`, expected a single ReactElement."))}return null}return o(e)}function c(e){function t(t,n,r,o,i){if(!(t[n]instanceof e)){var a=_[o],u=e.name||w,s=g(t[n]);return new Error("Invalid "+a+" `"+i+"` of type "+("`"+s+"` supplied to `"+r+"`, expected ")+("instance of `"+u+"`."))}return null}return o(t)}function l(e){function t(t,n,o,i,a){for(var u=t[n],s=0;s<e.length;s++)if(r(u,e[s]))return null;var c=_[i],l=JSON.stringify(e);return new Error("Invalid "+c+" `"+a+"` of value `"+u+"` "+("supplied to `"+o+"`, expected one of "+l+"."))}return o(Array.isArray(e)?t:function(){return new Error("Invalid argument supplied to oneOf, expected an instance of array.")})}function f(e){function t(t,n,r,o,i){if("function"!=typeof e)return new Error("Property `"+i+"` of component `"+r+"` has invalid PropType notation inside objectOf.");var a=t[n],u=m(a);if("object"!==u){var s=_[o];return new Error("Invalid "+s+" `"+i+"` of type "+("`"+u+"` supplied to `"+r+"`, expected an object."))}for(var c in a)if(a.hasOwnProperty(c)){var l=e(a,c,r,o,i+"."+c);if(l instanceof Error)return l}return null}return o(t)}function p(e){function t(t,n,r,o,i){for(var a=0;a<e.length;a++){var u=e[a];if(null==u(t,n,r,o,i))return null}var s=_[o];return new Error("Invalid "+s+" `"+i+"` supplied to "+("`"+r+"`."))}return o(Array.isArray(e)?t:function(){return new Error("Invalid argument supplied to oneOfType, expected an instance of array.")})}function d(){function e(e,t,n,r,o){if(!v(e[t])){var i=_[r];return new Error("Invalid "+i+" `"+o+"` supplied to "+("`"+n+"`, expected a ReactNode."))}return null}return o(e)}function h(e){function t(t,n,r,o,i){var a=t[n],u=m(a);if("object"!==u){var s=_[o];return new Error("Invalid "+s+" `"+i+"` of type `"+u+"` "+("supplied to `"+r+"`, expected `object`."))}for(var c in e){var l=e[c];if(l){var f=l(a,c,r,o,i+"."+c);if(f)return f}}return null}return o(t)}function v(e){switch(typeof e){case"number":case"string":case"undefined":return!0;case"boolean":return!e;case"object":if(Array.isArray(e))return e.every(v);if(null===e||b.isValidElement(e))return!0;var t=E(e);if(!t)return!1;var n,r=t.call(e);if(t!==e.entries){for(;!(n=r.next()).done;)if(!v(n.value))return!1}else for(;!(n=r.next()).done;){var o=n.value;if(o&&!v(o[1]))return!1}return!0;default:return!1}}function m(e){var t=typeof e;return Array.isArray(e)?"array":e instanceof RegExp?"object":t}function y(e){var t=m(e);if("object"===t){if(e instanceof Date)return"date";if(e instanceof RegExp)return"regexp"}return t}function g(e){return e.constructor&&e.constructor.name?e.constructor.name:w}var b=n(17),_=n(78),x=n(9),E=n(160),w="<<anonymous>>",S={array:i("array"),bool:i("boolean"),func:i("function"),number:i("number"),object:i("object"),string:i("string"),any:a(),arrayOf:u,element:s(),instanceOf:c,node:d(),objectOf:f,oneOf:l,oneOfType:p,shape:h};e.exports=S},function(e,t,n){"use strict";function r(e){this.reinitializeTransaction(),this.renderToStaticMarkup=!1,this.reactMountReady=i.getPooled(null),this.useCreateElement=e}var o=n(3),i=n(136),a=n(16),u=n(49),s=n(146),c=n(51),l={initialize:s.getSelectionInformation,close:s.restoreSelection},f={initialize:function(){var e=u.isEnabled();return u.setEnabled(!1),e},close:function(e){u.setEnabled(e)}},p={initialize:function(){this.reactMountReady.reset()},close:function(){this.reactMountReady.notifyAll()}},d=[l,f,p],h={getTransactionWrappers:function(){return d},getReactMountReady:function(){return this.reactMountReady},checkpoint:function(){return this.reactMountReady.checkpoint()},rollback:function(e){this.reactMountReady.rollback(e)},destructor:function(){i.release(this.reactMountReady),this.reactMountReady=null}};o(r.prototype,c.Mixin,h),a.addPoolingTo(r),e.exports=r},function(e,t,n){"use strict";function r(e,t,n){"function"==typeof e?e(t.getPublicInstance()):i.addComponentAsRefTo(t,e,n)}function o(e,t,n){"function"==typeof e?e(null):i.removeComponentAsRefFrom(t,e,n)}var i=n(331),a={};a.attachRefs=function(e,t){if(null!==t&&t!==!1){var n=t.ref;null!=n&&r(n,e,t._owner)}},a.shouldUpdateRefs=function(e,t){var n=null===e||e===!1,r=null===t||t===!1;return n||r||t._owner!==e._owner||t.ref!==e.ref},a.detachRefs=function(e,t){if(null!==t&&t!==!1){var n=t.ref;null!=n&&o(n,e,t._owner)}},e.exports=a},function(e,t){"use strict";var n={isBatchingUpdates:!1,batchedUpdates:function(e){}};e.exports=n},function(e,t,n){"use strict";function r(e,t){var n;try{return d.injection.injectBatchingStrategy(f),n=p.getPooled(t),n.perform(function(){var r=v(e),o=l.mountComponent(r,n,null,a(),h);return t||(o=c.addChecksumToMarkup(o)),o},null)}finally{p.release(n),d.injection.injectBatchingStrategy(u)}}function o(e){return s.isValidElement(e)?void 0:m(!1),r(e,!1)}function i(e){return s.isValidElement(e)?void 0:m(!1),r(e,!0)}var a=n(140),u=n(142),s=n(17),c=(n(7),n(147)),l=n(21),f=n(335),p=n(153),d=n(10),h=n(24),v=n(84),m=n(1);e.exports={renderToString:o,renderToStaticMarkup:i}},function(e,t){"use strict";var n={xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace"},r={accentHeight:"accent-height",accumulate:0,additive:0,alignmentBaseline:"alignment-baseline",allowReorder:"allowReorder",alphabetic:0,amplitude:0,arabicForm:"arabic-form",ascent:0,attributeName:"attributeName",attributeType:"attributeType",autoReverse:"autoReverse",azimuth:0,baseFrequency:"baseFrequency",baseProfile:"baseProfile",baselineShift:"baseline-shift",bbox:0,begin:0,bias:0,by:0,calcMode:"calcMode",capHeight:"cap-height",clip:0,clipPath:"clip-path",clipRule:"clip-rule",clipPathUnits:"clipPathUnits",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",contentScriptType:"contentScriptType",contentStyleType:"contentStyleType",cursor:0,cx:0,cy:0,d:0,decelerate:0,descent:0,diffuseConstant:"diffuseConstant",direction:0,display:0,divisor:0,dominantBaseline:"dominant-baseline",dur:0,dx:0,dy:0,edgeMode:"edgeMode",elevation:0,enableBackground:"enable-background",end:0,exponent:0,externalResourcesRequired:"externalResourcesRequired",fill:0,fillOpacity:"fill-opacity",fillRule:"fill-rule",filter:0,filterRes:"filterRes",filterUnits:"filterUnits",floodColor:"flood-color",floodOpacity:"flood-opacity",focusable:0,fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",format:0,from:0,fx:0,fy:0,g1:0,g2:0,glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",glyphRef:"glyphRef",gradientTransform:"gradientTransform",gradientUnits:"gradientUnits",hanging:0,horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",ideographic:0,imageRendering:"image-rendering",in:0,in2:0,intercept:0,k:0,k1:0,k2:0,k3:0,k4:0,kernelMatrix:"kernelMatrix",kernelUnitLength:"kernelUnitLength",kerning:0,keyPoints:"keyPoints",keySplines:"keySplines",keyTimes:"keyTimes",lengthAdjust:"lengthAdjust",letterSpacing:"letter-spacing",lightingColor:"lighting-color",limitingConeAngle:"limitingConeAngle",local:0,markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",markerHeight:"markerHeight",markerUnits:"markerUnits",markerWidth:"markerWidth",mask:0,maskContentUnits:"maskContentUnits",maskUnits:"maskUnits",mathematical:0,mode:0,numOctaves:"numOctaves",offset:0,opacity:0,operator:0,order:0,orient:0,orientation:0,origin:0,overflow:0,overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pathLength:"pathLength",patternContentUnits:"patternContentUnits",patternTransform:"patternTransform",patternUnits:"patternUnits",pointerEvents:"pointer-events",points:0,pointsAtX:"pointsAtX",pointsAtY:"pointsAtY",pointsAtZ:"pointsAtZ",preserveAlpha:"preserveAlpha",preserveAspectRatio:"preserveAspectRatio",primitiveUnits:"primitiveUnits",r:0,radius:0,refX:"refX",refY:"refY",renderingIntent:"rendering-intent",repeatCount:"repeatCount",repeatDur:"repeatDur",requiredExtensions:"requiredExtensions",requiredFeatures:"requiredFeatures",restart:0,result:0,rotate:0,rx:0,ry:0,scale:0,seed:0,shapeRendering:"shape-rendering",slope:0,spacing:0,specularConstant:"specularConstant",specularExponent:"specularExponent",speed:0,spreadMethod:"spreadMethod",startOffset:"startOffset",stdDeviation:"stdDeviation",stemh:0,stemv:0,stitchTiles:"stitchTiles",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",string:0,stroke:0,strokeDasharray:"stroke-dasharray",strokeDashoffset:"stroke-dashoffset",strokeLinecap:"stroke-linecap",strokeLinejoin:"stroke-linejoin",strokeMiterlimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",surfaceScale:"surfaceScale",systemLanguage:"systemLanguage",tableValues:"tableValues",targetX:"targetX",targetY:"targetY",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",textLength:"textLength",to:0,transform:0,u1:0,u2:0,underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicode:0,unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",values:0,vectorEffect:"vector-effect",version:0,vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",viewBox:"viewBox",viewTarget:"viewTarget",visibility:0,widths:0,wordSpacing:"word-spacing",writingMode:"writing-mode",x:0,xHeight:"x-height",x1:0,x2:0,xChannelSelector:"xChannelSelector",xlinkActuate:"xlink:actuate",xlinkArcrole:"xlink:arcrole",xlinkHref:"xlink:href",xlinkRole:"xlink:role",xlinkShow:"xlink:show",xlinkTitle:"xlink:title",xlinkType:"xlink:type",xmlBase:"xml:base",xmlLang:"xml:lang",xmlSpace:"xml:space",y:0,y1:0,y2:0,yChannelSelector:"yChannelSelector",z:0,zoomAndPan:"zoomAndPan"},o={Properties:{},DOMAttributeNamespaces:{xlinkActuate:n.xlink,xlinkArcrole:n.xlink,xlinkHref:n.xlink,xlinkRole:n.xlink,xlinkShow:n.xlink,xlinkTitle:n.xlink,xlinkType:n.xlink,xmlBase:n.xml,xmlLang:n.xml,xmlSpace:n.xml},DOMAttributeNames:{}};Object.keys(r).forEach(function(e){o.Properties[e]=0,r[e]&&(o.DOMAttributeNames[e]=r[e])}),e.exports=o},function(e,t,n){"use strict";function r(e){if("selectionStart"in e&&c.hasSelectionCapabilities(e))return{start:e.selectionStart,end:e.selectionEnd};if(window.getSelection){var t=window.getSelection();return{anchorNode:t.anchorNode,anchorOffset:t.anchorOffset,focusNode:t.focusNode,focusOffset:t.focusOffset}}if(document.selection){var n=document.selection.createRange();return{parentElement:n.parentElement(),text:n.text,top:n.boundingTop,left:n.boundingLeft}}}function o(e,t){if(x||null==g||g!==f())return null;var n=r(g);if(!_||!h(_,n)){_=n;var o=l.getPooled(y.select,b,e,t);return o.type="select",o.target=g,a.accumulateTwoPhaseDispatches(o),o}return null}var i=n(12),a=n(29),u=n(6),s=n(4),c=n(146),l=n(13),f=n(96),p=n(163),d=n(14),h=n(54),v=i.topLevelTypes,m=u.canUseDOM&&"documentMode"in document&&document.documentMode<=11,y={select:{phasedRegistrationNames:{bubbled:d({onSelect:null}),captured:d({onSelectCapture:null})},dependencies:[v.topBlur,v.topContextMenu,v.topFocus,v.topKeyDown,v.topMouseDown,v.topMouseUp,v.topSelectionChange]}},g=null,b=null,_=null,x=!1,E=!1,w=d({onSelect:null}),S={eventTypes:y,extractEvents:function(e,t,n,r){if(!E)return null;var i=t?s.getNodeFromInstance(t):window;switch(e){case v.topFocus:(p(i)||"true"===i.contentEditable)&&(g=i,b=t,_=null);break;case v.topBlur:g=null,b=null,_=null;break;case v.topMouseDown:x=!0;break;case v.topContextMenu:case v.topMouseUp:return x=!1,o(n,r);case v.topSelectionChange:if(m)break;case v.topKeyDown:case v.topKeyUp:return o(n,r)}return null},didPutListener:function(e,t,n){t===w&&(E=!0)}};e.exports=S},function(e,t,n){"use strict";var r=n(12),o=n(94),i=n(29),a=n(4),u=n(340),s=n(341),c=n(13),l=n(344),f=n(346),p=n(50),d=n(343),h=n(347),v=n(348),m=n(30),y=n(349),g=n(9),b=n(81),_=n(1),x=n(14),E=r.topLevelTypes,w={abort:{phasedRegistrationNames:{bubbled:x({onAbort:!0}),captured:x({onAbortCapture:!0})}},animationEnd:{phasedRegistrationNames:{bubbled:x({onAnimationEnd:!0}),captured:x({onAnimationEndCapture:!0})}},animationIteration:{phasedRegistrationNames:{bubbled:x({onAnimationIteration:!0}),captured:x({onAnimationIterationCapture:!0})}},animationStart:{phasedRegistrationNames:{bubbled:x({onAnimationStart:!0}),captured:x({onAnimationStartCapture:!0})}},blur:{phasedRegistrationNames:{bubbled:x({onBlur:!0}),captured:x({onBlurCapture:!0})}},canPlay:{phasedRegistrationNames:{bubbled:x({onCanPlay:!0}),captured:x({onCanPlayCapture:!0})}},canPlayThrough:{phasedRegistrationNames:{bubbled:x({onCanPlayThrough:!0}),captured:x({onCanPlayThroughCapture:!0})}},click:{phasedRegistrationNames:{bubbled:x({onClick:!0}),captured:x({onClickCapture:!0})}},contextMenu:{phasedRegistrationNames:{bubbled:x({onContextMenu:!0}),captured:x({onContextMenuCapture:!0})}},copy:{phasedRegistrationNames:{bubbled:x({onCopy:!0}),captured:x({onCopyCapture:!0})}},cut:{phasedRegistrationNames:{bubbled:x({onCut:!0}),captured:x({onCutCapture:!0})}},doubleClick:{phasedRegistrationNames:{bubbled:x({onDoubleClick:!0}),captured:x({onDoubleClickCapture:!0})}},drag:{phasedRegistrationNames:{bubbled:x({onDrag:!0}),captured:x({onDragCapture:!0})}},dragEnd:{phasedRegistrationNames:{bubbled:x({onDragEnd:!0}),captured:x({onDragEndCapture:!0})}},dragEnter:{phasedRegistrationNames:{bubbled:x({onDragEnter:!0}),captured:x({onDragEnterCapture:!0})}},dragExit:{phasedRegistrationNames:{bubbled:x({onDragExit:!0}),captured:x({onDragExitCapture:!0})}},dragLeave:{phasedRegistrationNames:{bubbled:x({onDragLeave:!0}),captured:x({onDragLeaveCapture:!0})}},dragOver:{phasedRegistrationNames:{bubbled:x({onDragOver:!0}),captured:x({onDragOverCapture:!0})}},dragStart:{phasedRegistrationNames:{bubbled:x({onDragStart:!0}),captured:x({onDragStartCapture:!0})}},drop:{phasedRegistrationNames:{bubbled:x({onDrop:!0}),captured:x({onDropCapture:!0})}},durationChange:{phasedRegistrationNames:{bubbled:x({onDurationChange:!0}),captured:x({onDurationChangeCapture:!0})}},emptied:{phasedRegistrationNames:{bubbled:x({onEmptied:!0}),captured:x({onEmptiedCapture:!0})}},encrypted:{phasedRegistrationNames:{bubbled:x({onEncrypted:!0}),captured:x({onEncryptedCapture:!0})}},ended:{phasedRegistrationNames:{bubbled:x({onEnded:!0}),captured:x({onEndedCapture:!0})}},error:{phasedRegistrationNames:{bubbled:x({onError:!0}),captured:x({onErrorCapture:!0})}},focus:{phasedRegistrationNames:{bubbled:x({onFocus:!0}),captured:x({onFocusCapture:!0})}},input:{phasedRegistrationNames:{bubbled:x({onInput:!0}),captured:x({onInputCapture:!0})}},invalid:{phasedRegistrationNames:{bubbled:x({onInvalid:!0}),captured:x({onInvalidCapture:!0})}},keyDown:{phasedRegistrationNames:{bubbled:x({onKeyDown:!0}),captured:x({onKeyDownCapture:!0})}},keyPress:{phasedRegistrationNames:{bubbled:x({onKeyPress:!0}),captured:x({onKeyPressCapture:!0})}},keyUp:{phasedRegistrationNames:{bubbled:x({onKeyUp:!0}),captured:x({onKeyUpCapture:!0})}},load:{phasedRegistrationNames:{bubbled:x({onLoad:!0}),captured:x({onLoadCapture:!0})}},loadedData:{phasedRegistrationNames:{bubbled:x({onLoadedData:!0}),captured:x({onLoadedDataCapture:!0})}},loadedMetadata:{phasedRegistrationNames:{bubbled:x({onLoadedMetadata:!0}),captured:x({onLoadedMetadataCapture:!0})}},loadStart:{phasedRegistrationNames:{bubbled:x({onLoadStart:!0}),captured:x({onLoadStartCapture:!0})}},mouseDown:{phasedRegistrationNames:{bubbled:x({onMouseDown:!0}),captured:x({onMouseDownCapture:!0})}},mouseMove:{phasedRegistrationNames:{bubbled:x({onMouseMove:!0}),captured:x({onMouseMoveCapture:!0})}},mouseOut:{phasedRegistrationNames:{bubbled:x({onMouseOut:!0}),captured:x({onMouseOutCapture:!0})}},mouseOver:{phasedRegistrationNames:{bubbled:x({onMouseOver:!0}),captured:x({onMouseOverCapture:!0})}},mouseUp:{phasedRegistrationNames:{bubbled:x({onMouseUp:!0}),captured:x({onMouseUpCapture:!0})}},paste:{phasedRegistrationNames:{bubbled:x({onPaste:!0}),captured:x({onPasteCapture:!0})}},pause:{phasedRegistrationNames:{bubbled:x({onPause:!0}),captured:x({onPauseCapture:!0})}},play:{phasedRegistrationNames:{bubbled:x({onPlay:!0}),captured:x({onPlayCapture:!0})}},playing:{phasedRegistrationNames:{bubbled:x({onPlaying:!0}),captured:x({onPlayingCapture:!0})}},progress:{phasedRegistrationNames:{bubbled:x({onProgress:!0}),captured:x({onProgressCapture:!0})}},rateChange:{phasedRegistrationNames:{bubbled:x({onRateChange:!0}),captured:x({onRateChangeCapture:!0})}},reset:{phasedRegistrationNames:{bubbled:x({onReset:!0}),captured:x({onResetCapture:!0})}},scroll:{phasedRegistrationNames:{bubbled:x({onScroll:!0}),captured:x({onScrollCapture:!0})}},seeked:{phasedRegistrationNames:{bubbled:x({onSeeked:!0}),captured:x({onSeekedCapture:!0})}},seeking:{phasedRegistrationNames:{bubbled:x({onSeeking:!0}),captured:x({onSeekingCapture:!0})}},stalled:{phasedRegistrationNames:{bubbled:x({onStalled:!0}),captured:x({onStalledCapture:!0})}},submit:{phasedRegistrationNames:{bubbled:x({onSubmit:!0}),captured:x({onSubmitCapture:!0})}},suspend:{phasedRegistrationNames:{bubbled:x({onSuspend:!0}),captured:x({onSuspendCapture:!0})}},timeUpdate:{phasedRegistrationNames:{bubbled:x({onTimeUpdate:!0}),captured:x({onTimeUpdateCapture:!0})}},touchCancel:{phasedRegistrationNames:{bubbled:x({onTouchCancel:!0}),captured:x({onTouchCancelCapture:!0})}},touchEnd:{phasedRegistrationNames:{bubbled:x({onTouchEnd:!0}),captured:x({onTouchEndCapture:!0})}},touchMove:{phasedRegistrationNames:{bubbled:x({onTouchMove:!0}),captured:x({onTouchMoveCapture:!0})}},touchStart:{phasedRegistrationNames:{bubbled:x({onTouchStart:!0}),captured:x({onTouchStartCapture:!0})}},transitionEnd:{phasedRegistrationNames:{bubbled:x({onTransitionEnd:!0}),captured:x({onTransitionEndCapture:!0})}},volumeChange:{phasedRegistrationNames:{bubbled:x({onVolumeChange:!0}),captured:x({onVolumeChangeCapture:!0})}},waiting:{phasedRegistrationNames:{bubbled:x({onWaiting:!0}),captured:x({onWaitingCapture:!0})}},wheel:{phasedRegistrationNames:{bubbled:x({onWheel:!0}),captured:x({onWheelCapture:!0})}}},S={topAbort:w.abort,topAnimationEnd:w.animationEnd,topAnimationIteration:w.animationIteration,topAnimationStart:w.animationStart,topBlur:w.blur,topCanPlay:w.canPlay,topCanPlayThrough:w.canPlayThrough,topClick:w.click,topContextMenu:w.contextMenu,topCopy:w.copy,topCut:w.cut,topDoubleClick:w.doubleClick,topDrag:w.drag,topDragEnd:w.dragEnd,topDragEnter:w.dragEnter,topDragExit:w.dragExit,topDragLeave:w.dragLeave,topDragOver:w.dragOver,topDragStart:w.dragStart,topDrop:w.drop,topDurationChange:w.durationChange,topEmptied:w.emptied,topEncrypted:w.encrypted,topEnded:w.ended,topError:w.error,topFocus:w.focus,topInput:w.input,topInvalid:w.invalid,topKeyDown:w.keyDown,topKeyPress:w.keyPress,topKeyUp:w.keyUp,topLoad:w.load,topLoadedData:w.loadedData,topLoadedMetadata:w.loadedMetadata,topLoadStart:w.loadStart,topMouseDown:w.mouseDown,topMouseMove:w.mouseMove,topMouseOut:w.mouseOut,topMouseOver:w.mouseOver,topMouseUp:w.mouseUp,topPaste:w.paste,topPause:w.pause,topPlay:w.play,topPlaying:w.playing,topProgress:w.progress,topRateChange:w.rateChange,topReset:w.reset,topScroll:w.scroll,topSeeked:w.seeked,topSeeking:w.seeking,topStalled:w.stalled,topSubmit:w.submit,topSuspend:w.suspend,topTimeUpdate:w.timeUpdate,topTouchCancel:w.touchCancel,topTouchEnd:w.touchEnd,topTouchMove:w.touchMove,topTouchStart:w.touchStart,topTransitionEnd:w.transitionEnd,topVolumeChange:w.volumeChange,topWaiting:w.waiting,topWheel:w.wheel};for(var C in S)S[C].dependencies=[C];var P=x({onClick:null}),O={},T={eventTypes:w,extractEvents:function(e,t,n,r){var o=S[e];if(!o)return null;var a;switch(e){case E.topAbort:case E.topCanPlay:case E.topCanPlayThrough:case E.topDurationChange:case E.topEmptied:case E.topEncrypted:case E.topEnded:case E.topError:case E.topInput:case E.topInvalid:case E.topLoad:case E.topLoadedData:case E.topLoadedMetadata:case E.topLoadStart:case E.topPause:case E.topPlay:case E.topPlaying:case E.topProgress:case E.topRateChange:case E.topReset:case E.topSeeked:case E.topSeeking:case E.topStalled:case E.topSubmit:case E.topSuspend:case E.topTimeUpdate:case E.topVolumeChange:case E.topWaiting:a=c;break;case E.topKeyPress:if(0===b(n))return null;case E.topKeyDown:case E.topKeyUp:a=f;break;case E.topBlur:case E.topFocus:a=l;break;case E.topClick:if(2===n.button)return null;case E.topContextMenu:case E.topDoubleClick:case E.topMouseDown:case E.topMouseMove:case E.topMouseOut:case E.topMouseOver:case E.topMouseUp:a=p;break;case E.topDrag:case E.topDragEnd:case E.topDragEnter:case E.topDragExit:case E.topDragLeave:case E.topDragOver:case E.topDragStart:case E.topDrop:a=d;break;case E.topTouchCancel:case E.topTouchEnd:case E.topTouchMove:case E.topTouchStart:a=h;break;case E.topAnimationEnd:case E.topAnimationIteration:case E.topAnimationStart:a=u;break;case E.topTransitionEnd:a=v;break;case E.topScroll:a=m;break;case E.topWheel:a=y;break;case E.topCopy:case E.topCut:case E.topPaste:a=s}a?void 0:_(!1);var g=a.getPooled(o,t,n,r);return i.accumulateTwoPhaseDispatches(g),g},didPutListener:function(e,t,n){if(t===P){var r=e._rootNodeID,i=a.getNodeFromInstance(e);O[r]||(O[r]=o.listen(i,"click",g))}},willDeleteListener:function(e,t){if(t===P){var n=e._rootNodeID;O[n].remove(),delete O[n]}}};e.exports=T},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(13),i={animationName:null,elapsedTime:null,pseudoElement:null};o.augmentClass(r,i),e.exports=r},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(13),i={clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}};o.augmentClass(r,i),e.exports=r},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(13),i={data:null};o.augmentClass(r,i),e.exports=r},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(50),i={dataTransfer:null};o.augmentClass(r,i),e.exports=r},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(30),i={relatedTarget:null};o.augmentClass(r,i),e.exports=r},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(13),i={data:null};o.augmentClass(r,i),e.exports=r},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(30),i=n(81),a=n(354),u=n(82),s={key:a,location:null,ctrlKey:null,shiftKey:null,altKey:null,metaKey:null,repeat:null,locale:null,getModifierState:u,charCode:function(e){return"keypress"===e.type?i(e):0},keyCode:function(e){return"keydown"===e.type||"keyup"===e.type?e.keyCode:0},which:function(e){return"keypress"===e.type?i(e):"keydown"===e.type||"keyup"===e.type?e.keyCode:0}};o.augmentClass(r,s),e.exports=r},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(30),i=n(82),a={touches:null,targetTouches:null,changedTouches:null,altKey:null,metaKey:null,ctrlKey:null,shiftKey:null,getModifierState:i};o.augmentClass(r,a),e.exports=r},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(13),i={propertyName:null,elapsedTime:null,pseudoElement:null};o.augmentClass(r,i),e.exports=r},function(e,t,n){"use strict";function r(e,t,n,r){return o.call(this,e,t,n,r)}var o=n(50),i={deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:null,deltaMode:null};o.augmentClass(r,i),e.exports=r},function(e,t){"use strict";function n(e){for(var t=1,n=0,o=0,i=e.length,a=i&-4;o<a;){for(var u=Math.min(o+4096,a);o<u;o+=4)n+=(t+=e.charCodeAt(o))+(t+=e.charCodeAt(o+1))+(t+=e.charCodeAt(o+2))+(t+=e.charCodeAt(o+3));t%=r,n%=r}for(;o<i;o++)n+=t+=e.charCodeAt(o);return t%=r,n%=r,t|n<<16}var r=65521;e.exports=n},function(e,t,n){"use strict";function r(e,t,n){var r=null==t||"boolean"==typeof t||""===t;if(r)return"";var o=isNaN(t);return o||0===t||i.hasOwnProperty(e)&&i[e]?""+t:("string"==typeof t&&(t=t.trim()),t+"px")}var o=n(135),i=(n(2),o.isUnitlessNumber);e.exports=r},function(e,t,n){"use strict";function r(e){if(null==e)return null;if(1===e.nodeType)return e;var t=i.get(e);return t?(t=a(t),t?o.getNodeFromInstance(t):null):void u(("function"==typeof e.render,!1))}var o=(n(20),n(4)),i=n(77),a=n(161),u=n(1);n(2),e.exports=r},function(e,t,n){"use strict";function r(e,t,n){var r=e,o=void 0===r[n];o&&null!=t&&(r[n]=t)}function o(e){if(null==e)return e;var t={};return i(e,r,t),t}var i=(n(73),n(88));n(2),e.exports=o},function(e,t,n){"use strict";function r(e){if(e.key){var t=i[e.key]||e.key;if("Unidentified"!==t)return t}if("keypress"===e.type){var n=o(e);return 13===n?"Enter":String.fromCharCode(n)}return"keydown"===e.type||"keyup"===e.type?a[e.keyCode]||"Unidentified":""}var o=n(81),i={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},a={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",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",224:"Meta"};e.exports=r},function(e,t){"use strict";function n(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function r(e){for(;e;){if(e.nextSibling)return e.nextSibling;e=e.parentNode}}function o(e,t){for(var o=n(e),i=0,a=0;o;){if(3===o.nodeType){if(a=i+o.textContent.length,i<=t&&a>=t)return{node:o,offset:t-i};i=a}o=n(r(o))}}e.exports=o},function(e,t,n){"use strict";function r(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n["ms"+e]="MS"+t, n["O"+e]="o"+t.toLowerCase(),n}function o(e){if(u[e])return u[e];if(!a[e])return e;var t=a[e];for(var n in t)if(t.hasOwnProperty(n)&&n in s)return u[e]=t[n];return""}var i=n(6),a={animationend:r("Animation","AnimationEnd"),animationiteration:r("Animation","AnimationIteration"),animationstart:r("Animation","AnimationStart"),transitionend:r("Transition","TransitionEnd")},u={},s={};i.canUseDOM&&(s=document.createElement("div").style,"AnimationEvent"in window||(delete a.animationend.animation,delete a.animationiteration.animation,delete a.animationstart.animation),"TransitionEvent"in window||delete a.transitionend.transition),e.exports=o},function(e,t,n){"use strict";function r(e){return'"'+o(e)+'"'}var o=n(52);e.exports=r},function(e,t,n){"use strict";var r=n(148);e.exports=r.renderSubtreeIntoContainer},function(e,t,n){"use strict";function r(e,t,n){return!o(e.props,t)||!o(e.state,n)}var o=n(54);e.exports=r},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function u(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var s=n(67),c=r(s),l=n(44),f=r(l),p=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),d=n(5),h=n(46),v=n(367),m=r(v),y=n(31),g=r(y),b=function(e,t,n){var r=e.asyncValidate,s=e.blur,l=e.change,v=e.focus,y=e.getFormState,b=e.initialValues,_=t.deepEqual,x=t.getIn,E=b&&x(b,n),w=function(e){function t(){return i(this,t),a(this,Object.getPrototypeOf(t).apply(this,arguments))}return u(t,e),p(t,[{key:"shouldComponentUpdate",value:function(e){return!_(this.props,e)}},{key:"getRenderedComponent",value:function(){return this.refs.renderedComponent}},{key:"render",value:function(){var e=this.props,t=e.component,i=e.defaultValue,a=e.withRef,u=o(e,["component","defaultValue","withRef"]),s=this.context._reduxForm.adapter,c=(0,m.default)(x,n,u,this.syncError,i,r);a&&(c.ref="renderedComponent");var l=void 0;return s&&(l=s(t,c)),l||(l=(0,d.createElement)(t,c)),l}},{key:"syncError",get:function(){var e=this.context._reduxForm.getSyncErrors,t=g.default.getIn(e(),n);return t&&t._error?t._error:t}},{key:"dirty",get:function(){return this.props.dirty}},{key:"pristine",get:function(){return this.props.pristine}},{key:"value",get:function(){return this.props.value}}]),t}(d.Component);w.propTypes={component:d.PropTypes.oneOfType([d.PropTypes.func,d.PropTypes.string]).isRequired,defaultValue:d.PropTypes.any},w.contextTypes={_reduxForm:d.PropTypes.object};var S=(0,c.default)({blur:s,change:l,focus:v},function(e){return(0,f.default)(e,n)}),C=(0,h.connect)(function(e,t){var r=x(y(e),"initial."+n)||E,o=x(y(e),"values."+n),i=o===r;return{asyncError:x(y(e),"asyncErrors."+n),asyncValidating:x(y(e),"asyncValidating")===n,dirty:!i,pristine:i,state:x(y(e),"fields."+n),submitError:x(y(e),"submitErrors."+n),value:o,_value:t.value}},S,void 0,{withRef:!0});return C(w)};t.default=b},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function u(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var s=n(67),c=r(s),l=n(44),f=r(l),p=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),d=n(5),h=n(46),v=n(366),m=r(v),y=n(31),g=r(y),b=n(69),_=r(b),x=function(e,t,n){var r=e.arrayInsert,s=e.arrayPop,l=e.arrayPush,v=e.arrayRemove,y=e.arrayShift,b=e.arraySplice,x=e.arraySwap,E=e.arrayUnshift,w=(e.asyncValidate,e.blur,e.change,e.focus,e.getFormState),S=e.initialValues,C=t.deepEqual,P=t.getIn,O=t.size,T=S&&P(S,n),k=function(e){function t(){return i(this,t),a(this,Object.getPrototypeOf(t).apply(this,arguments))}return u(t,e),p(t,[{key:"shouldComponentUpdate",value:function(e){return(0,_.default)(this,e)}},{key:"getRenderedComponent",value:function(){return this.refs.renderedComponent}},{key:"render",value:function(){var e=this.props,t=e.component,r=e.withRef,i=o(e,["component","withRef"]),a=(0,m.default)(P,O,n,i,this.syncError);return r&&(a.ref="renderedComponent"),(0,d.createElement)(t,a)}},{key:"syncError",get:function(){var e=this.context._reduxForm.getSyncErrors;return g.default.getIn(e(),n+"._error")}},{key:"dirty",get:function(){return this.props.dirty}},{key:"pristine",get:function(){return this.props.pristine}},{key:"value",get:function(){return this.props.value}}]),t}(d.Component);k.propTypes={component:d.PropTypes.oneOfType([d.PropTypes.func,d.PropTypes.string]).isRequired,defaultValue:d.PropTypes.any},k.contextTypes={_reduxForm:d.PropTypes.object};var A=(0,c.default)({arrayInsert:r,arrayPop:s,arrayPush:l,arrayRemove:v,arrayShift:y,arraySplice:b,arraySwap:x,arrayUnshift:E},function(e){return(0,f.default)(e,n)}),R=(0,h.connect)(function(e){var t=P(w(e),"initial."+n)||T,r=P(w(e),"values."+n),o=C(r,t);return{asyncError:P(w(e),"asyncErrors."+n+"._error"),dirty:!o,pristine:o,submitError:P(w(e),"submitErrors."+n+"._error"),value:r}},A,void 0,{withRef:!0});return R(k)};t.default=x},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var u=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),c=n(5),l=n(33),f=r(l),p=n(360),d=r(p),h=n(69),v=r(h),m=function(e){var t=e.deepEqual,n=e.getIn,r=function(e){function r(e,a){o(this,r);var u=i(this,Object.getPrototypeOf(r).call(this,e,a));if(!a._reduxForm)throw new Error("Field must be inside a component decorated with reduxForm()");return u.ConnectedField=(0,d.default)(a._reduxForm,{deepEqual:t,getIn:n},e.name),u}return a(r,e),s(r,[{key:"shouldComponentUpdate",value:function(e){return(0,v.default)(this,e)}},{key:"componentWillMount",value:function(){this.context._reduxForm.register(this.name,"Field")}},{key:"componentWillReceiveProps",value:function(e){this.props.name!==e.name&&(this.ConnectedField=(0,d.default)(this.context._reduxForm,{deepEqual:t,getIn:n},e.name))}},{key:"componentWillUnmount",value:function(){this.context._reduxForm.unregister(this.name)}},{key:"getRenderedComponent",value:function(){return(0,f.default)(this.props.withRef,"If you want to access getRenderedComponent(), you must specify a withRef prop to Field"),this.refs.connected.getWrappedInstance().getRenderedComponent()}},{key:"render",value:function(){return(0,c.createElement)(this.ConnectedField,u({},this.props,{ref:"connected"}))}},{key:"name",get:function(){return this.props.name}},{key:"dirty",get:function(){return this.refs.connected.getWrappedInstance().dirty}},{key:"pristine",get:function(){return this.refs.connected.getWrappedInstance().pristine}},{key:"value",get:function(){return this.refs.connected.getWrappedInstance().value}}]),r}(c.Component);return r.propTypes={name:c.PropTypes.string.isRequired,component:c.PropTypes.oneOfType([c.PropTypes.func,c.PropTypes.string]).isRequired,defaultValue:c.PropTypes.any},r.contextTypes={_reduxForm:c.PropTypes.object},r};t.default=m},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var u=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),c=n(5),l=n(33),f=r(l),p=n(361),d=r(p),h=n(69),v=r(h),m=function(e){var t=e.deepEqual,n=e.getIn,r=e.size,l=function(e){function l(e,a){o(this,l);var u=i(this,Object.getPrototypeOf(l).call(this,e,a));if(!a._reduxForm)throw new Error("FieldArray must be inside a component decorated with reduxForm()");return u.ConnectedFieldArray=(0,d.default)(a._reduxForm,{deepEqual:t,getIn:n,size:r},e.name),u}return a(l,e),s(l,[{key:"shouldComponentUpdate",value:function(e){return(0,v.default)(this,e)}},{key:"componentWillMount",value:function(){this.context._reduxForm.register(this.name,"FieldArray")}},{key:"componentWillReceiveProps",value:function(e){this.props.name!==e.name&&(this.ConnectedFieldArray=(0,d.default)(this.context._reduxForm,{deepEqual:t,getIn:n,size:r},e.name))}},{key:"componentWillUnmount",value:function(){this.context._reduxForm.unregister(this.name)}},{key:"getRenderedComponent",value:function(){return(0,f.default)(this.props.withRef,"If you want to access getRenderedComponent(), you must specify a withRef prop to FieldArray"),this.refs.connected.getWrappedInstance().getRenderedComponent()}},{key:"render",value:function(){return(0,c.createElement)(this.ConnectedFieldArray,u({},this.props,{ref:"connected"}))}},{key:"name",get:function(){return this.props.name}},{key:"dirty",get:function(){return this.refs.connected.getWrappedInstance().dirty}},{key:"pristine",get:function(){return this.refs.connected.getWrappedInstance().pristine}},{key:"value",get:function(){return this.refs.connected.getWrappedInstance().value}}]),l}(c.Component);return l.propTypes={name:c.PropTypes.string.isRequired,component:c.PropTypes.func.isRequired},l.contextTypes={_reduxForm:c.PropTypes.object},l};t.default=m},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(55),i=r(o),a=function(e,t,n,r){t(r);var o=e();if(!(0,i.default)(o))throw new Error("asyncValidate function passed to reduxForm must return a promise");var a=function(e){return function(t){if(t&&Object.keys(t).length)return n(t),Promise.reject();if(e)throw n(),new Error("Asynchronous validation promise was rejected without errors.");return n(),Promise.resolve()}};return o.then(a(!1),a(!0))};t.default=a},function(e,t,n){"use strict";function r(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}function o(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var i=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},a=n(381),u=o(a),s=n(382),c=o(s),l=n(362),f=o(l),p=n(363),d=o(p),h=n(375),v=o(h),m=n(388),y=o(m),g=n(165),b=o(g),_=n(380),x=o(_),E=n(166),w=r(E),S=n(90),C=r(S),P=function(e){return i({actionTypes:C},w,{Field:(0,f.default)(e),FieldArray:(0,d.default)(e),formValueSelector:(0,v.default)(e),propTypes:x.default,reduxForm:(0,c.default)(e),reducer:(0,u.default)(e),SubmissionError:b.default,values:(0,y.default)(e)})};t.default=P},function(e,t){"use strict";function n(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}Object.defineProperty(t,"__esModule",{value:!0});var r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},o=function(e,t,o,i,a){var u=i.arrayInsert,s=i.arrayPop,c=i.arrayPush,l=i.arrayRemove,f=i.arrayShift,p=(i.arraySplice,i.arraySwap),d=i.arrayUnshift,h=i.asyncError,v=i.dirty,m=i.pristine,y=(i.state,i.submitError),g=(i.submitFailed,i.value),b=n(i,["arrayInsert","arrayPop","arrayPush","arrayRemove","arrayShift","arraySplice","arraySwap","arrayUnshift","asyncError","dirty","pristine","state","submitError","submitFailed","value"]),_=a||h||y,x=t(g);return r({dirty:v,error:_,forEach:function(e){return(g||[]).forEach(function(t,n){return e(o+"["+n+"]",n)})},insert:u,invalid:!!_,length:x,map:function(e){return(g||[]).map(function(t,n){return e(o+"["+n+"]",n)})},pop:function(){return s(),e(g,x-1)},pristine:m,push:c,remove:l,shift:function(){return f(),e(g,0)},swap:p,unshift:d,valid:!_},b)};t.default=o},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}Object.defineProperty(t,"__esModule",{value:!0});var i=n(130),a=r(i),u=n(44),s=r(u),c=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},l=n(370),f=r(l),p=n(371),d=r(p),h=n(167),v=r(h),m=n(372),y=r(m),g=n(373),b=r(g),_=function(e,t){var n=e.type,r=e.value,i=o(e,["type","value"]);return"checkbox"===n?c({},i,{checked:!!r,type:n}):"radio"===n?c({},i,{checked:r===t,type:n,value:t}):"select-multiple"===n?c({},i,{type:n,value:r||[]}):e},x=function(e,t,n,r){var i=n.asyncError,u=n.blur,l=n.change,p=n.dirty,h=n.focus,m=n.pristine,g=n.state,x=n.submitError,E=n.value,w=n._value,S=o(n,["asyncError","blur","change","dirty","focus","pristine","state","submitError","value","_value"]),C=arguments.length<=4||void 0===arguments[4]?"":arguments[4],P=arguments.length<=5||void 0===arguments[5]?a.default:arguments[5],O=r||i||x,T=(0,d.default)(l);return _(c({active:g&&!!e(g,"active"),dirty:p,error:O,invalid:!!O,name:t,onBlur:(0,f.default)(u,(0,s.default)(P,t)),onChange:T,onDragStart:(0,v.default)(t,E),onDrop:(0,y.default)(t,l),onFocus:(0,b.default)(t,h),onUpdate:T,pristine:m,touched:!(!g||!e(g,"touched")),valid:!O,value:null==E?C:E,visited:g&&!!e(g,"visited")},S),w)};t.default=x},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(e){var t=e.initialized,n=e.trigger,r=e.pristine,o=e.syncValidationPasses;if(!o)return!1;switch(n){case"blur":return!0;case"submit":return!r||!t;default:return!1}};t.default=n},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(45),i=r(o),a=function(e){var t=e.deepEqual,n=e.empty,r=e.getIn,o=e.deleteIn,a=e.setIn,u=function e(u,s){if("]"===s[s.length-1]){var c=(0,i.default)(s);c.pop();var l=r(u,c.join("."));return l?a(u,s,void 0):u}var f=o(u,s),p=s.lastIndexOf(".");if(p>0){var d=s.substring(0,p);if("]"!==d[d.length-1]){var h=r(f,d);if(t(h,n))return e(f,d)}}return f};return u};t.default=a},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(168),i=r(o),a=n(171),u=r(a),s=function(e,t){return function(n){var r=(0,i.default)(n,u.default);e(r),t&&t(r)}};t.default=s},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(168),i=r(o),a=n(171),u=r(a),s=function(e){return function(t){return e((0,i.default)(t,u.default))}};t.default=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(167),o=function(e,t){return function(n){t(e,n.dataTransfer.getData(r.dataKey))}};t.default=o},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(e,t){return function(){return t(e)}};t.default=n},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(170),i=r(o),a=function(e){return function(t){for(var n=arguments.length,r=Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return(0,i.default)(t)?e.apply(void 0,r):e.apply(void 0,[t].concat(r))}};t.default=a},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(33),i=r(o),a=n(31),u=r(a),s=function(e){var t=e.getIn;return function(e){var n=arguments.length<=1||void 0===arguments[1]?function(e){return t(e,"form")}:arguments[1];return(0,i.default)(e,"Form value must be specified"),function(r){for(var o=arguments.length,a=Array(o>1?o-1:0),s=1;s<o;s++)a[s-1]=arguments[s];return(0,i.default)(a.length,"No fields specified"),1===a.length?t(n(r),e+".values."+a[0]):a.reduce(function(o,i){var a=t(n(r),e+".values."+i);return void 0===a?o:u.default.setIn(o,i,a)},{})}}};t.default=s},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}Object.defineProperty(t,"__esModule",{value:!0});var i=n(55),a=r(i),u=n(165),s=r(u),c=function(e,t,n,r,i){var u=t.dispatch,c=t.startSubmit,l=t.stopSubmit,f=t.setSubmitFailed,p=t.syncErrors,d=t.returnRejectedSubmitPromise,h=t.values;if(n){var v=function(){var t=e(h,u);return(0,a.default)(t)?(c(),t.then(function(e){return l(),e}).catch(function(e){if(l(e instanceof s.default?e.errors:void 0),d)return Promise.reject(e)})):t},m=r&&r();return m?m.then(v,function(e){if(f.apply(void 0,o(i)),d)return Promise.reject(e)}):v()}if(f.apply(void 0,o(i)),d)return Promise.reject(p)};t.default=c},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(172),i=r(o),a=function(e,t){switch(t){case"Field":return e;case"FieldArray":return e+"._error"}},u=function(e){var t=e.getIn,n=function(e,n,r,o){var u=t(e,"name"),s=t(e,"type");if(!n&&!r&&!o)return!1;var c=a(u,s),l=(0,i.default)(n,c);if(l&&"string"==typeof l)return!0;var f=t(r,c);if(f&&"string"==typeof f)return!0;var p=t(o,c);return!(!p||"string"!=typeof p)};return n};t.default=u},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(e){var t=e.getIn,n=function(e){if(!e)return!1;var n=t(e,"_error");return!!n||"string"==typeof e&&!!e};return n};t.default=n},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0}),t.values=t.untouch=t.touch=t.SubmissionError=t.stopSubmit=t.stopAsyncValidation=t.startSubmit=t.startAsyncValidation=t.setSubmitFailed=t.reset=t.propTypes=t.initialize=t.reduxForm=t.reducer=t.formValueSelector=t.focus=t.FieldArray=t.Field=t.destroy=t.change=t.blur=t.arrayUnshift=t.arraySwap=t.arraySplice=t.arrayShift=t.arrayRemove=t.arrayPush=t.arrayPop=t.arrayInsert=t.actionTypes=void 0;var o=n(365),i=r(o),a=n(31),u=r(a),s=(0,i.default)(u.default),c=s.actionTypes,l=s.arrayInsert,f=s.arrayPop,p=s.arrayPush,d=s.arrayRemove,h=s.arrayShift,v=s.arraySplice,m=s.arraySwap,y=s.arrayUnshift,g=s.blur,b=s.change,_=s.destroy,x=s.Field,E=s.FieldArray,w=s.focus,S=s.formValueSelector,C=s.reducer,P=s.reduxForm,O=s.initialize,T=s.propTypes,k=s.reset,A=s.setSubmitFailed,R=s.startAsyncValidation,M=s.startSubmit,I=s.stopAsyncValidation,N=s.stopSubmit,j=s.SubmissionError,F=s.touch,D=s.untouch,U=s.values;t.actionTypes=c,t.arrayInsert=l,t.arrayPop=f,t.arrayPush=p,t.arrayRemove=d,t.arrayShift=h,t.arraySplice=v,t.arraySwap=m,t.arrayUnshift=y,t.blur=g,t.change=b,t.destroy=_,t.Field=x,t.FieldArray=E,t.focus=w,t.formValueSelector=S,t.reducer=C,t.reduxForm=P,t.initialize=O,t.propTypes=T,t.reset=k,t.setSubmitFailed=A,t.startAsyncValidation=R,t.startSubmit=M,t.stopAsyncValidation=I,t.stopSubmit=N,t.SubmissionError=j,t.touch=F,t.untouch=D,t.values=U},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.propTypes=void 0;var r=n(5),o=r.PropTypes.any,i=r.PropTypes.bool,a=r.PropTypes.func;t.propTypes={asyncValidating:i.isRequired,autofilled:i,dirty:i.isRequired,error:o,invalid:i.isRequired,pristine:i.isRequired,submitting:i.isRequired,submitFailed:i.isRequired,valid:i.isRequired,asyncValidate:a.isRequired,destroy:a.isRequired,handleSubmit:a.isRequired,initialize:a.isRequired,reset:a.isRequired,touch:a.isRequired,untouch:a.isRequired}},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}Object.defineProperty(t,"__esModule",{value:!0});var a=n(90),u=n(369),s=r(u),c=function(e){function t(e){return e}var n,r=e.splice,u=e.empty,c=e.getIn,l=e.setIn,f=e.deleteIn,p=e.fromJS,d=e.size,h=e.some,v=(0,s.default)(e),m=function(e,t,n,o,i,a,u){var s=c(e,t+"."+n);return s||u?l(e,t+"."+n,r(s,o,i,a)):e},y=["values","fields","submitErrors","asyncErrors"],g=function(e,t,n,r,o){var i=e;return i=m(i,"values",t,n,r,o,!0),i=m(i,"fields",t,n,r,u),i=m(i,"submitErrors",t,n,r,u),i=m(i,"asyncErrors",t,n,r,u)},b=(n={},o(n,a.ARRAY_INSERT,function(e,t){var n=t.meta,r=n.field,o=n.index,i=t.payload;return g(e,r,o,0,i)}),o(n,a.ARRAY_POP,function(e,t){var n=t.meta.field,r=c(e,"values."+n),o=r?d(r):0;return o?g(e,n,o-1,1):e}),o(n,a.ARRAY_PUSH,function(e,t){var n=t.meta.field,r=t.payload,o=c(e,"values."+n),i=o?d(o):0;return g(e,n,i,0,r)}),o(n,a.ARRAY_REMOVE,function(e,t){var n=t.meta,r=n.field,o=n.index;return g(e,r,o,1)}),o(n,a.ARRAY_SHIFT,function(e,t){var n=t.meta.field;return g(e,n,0,1)}),o(n,a.ARRAY_SPLICE,function(e,t){var n=t.meta,r=n.field,o=n.index,i=n.removeNum,a=t.payload;return g(e,r,o,i,a)}),o(n,a.ARRAY_SWAP,function(e,t){var n=t.meta,r=n.field,o=n.indexA,i=n.indexB,a=e;return y.forEach(function(e){var t=c(a,e+"."+r+"["+o+"]"),n=c(a,e+"."+r+"["+i+"]");void 0===t&&void 0===n||(a=l(a,e+"."+r+"["+o+"]",n),a=l(a,e+"."+r+"["+i+"]",t))}),a}),o(n,a.ARRAY_UNSHIFT,function(e,t){var n=t.meta.field,r=t.payload;return g(e,n,0,0,r)}),o(n,a.BLUR,function(e,t){var n=t.meta,r=n.field,o=n.touch,i=t.payload,a=e,u=c(a,"initial."+r);return void 0===u&&""===i?a=v(a,"values."+r):void 0!==i&&(a=l(a,"values."+r,i)),r===c(a,"active")&&(a=f(a,"active")),a=f(a,"fields."+r+".active"),o&&(a=l(a,"fields."+r+".touched",!0),a=l(a,"anyTouched",!0)),a}),o(n,a.CHANGE,function(e,t){var n=t.meta,r=n.field,o=n.touch,i=t.payload,a=e,u=c(a,"initial."+r);return void 0===u&&""===i?a=v(a,"values."+r):void 0!==i&&(a=l(a,"values."+r,i)),a=v(a,"asyncErrors."+r),a=v(a,"submitErrors."+r),o&&(a=l(a,"fields."+r+".touched",!0),a=l(a,"anyTouched",!0)),a}),o(n,a.FOCUS,function(e,t){var n=t.meta.field,r=e,o=c(e,"active");return r=f(r,"fields."+o+".active"),r=l(r,"fields."+n+".visited",!0),r=l(r,"fields."+n+".active",!0),r=l(r,"active",n)}),o(n,a.INITIALIZE,function(e,t){var n=t.payload,r=p(n),o=u;return o=l(o,"values",r),o=l(o,"initial",r)}),o(n,a.REGISTER_FIELD,function(e,t){var n=t.payload,o=n.name,i=n.type,a=e,u=c(a,"registeredFields");if(h(u,function(e){return c(e,"name")===o}))return e;var s=p({name:o,type:i});return a=l(e,"registeredFields",r(u,d(u),0,s))}),o(n,a.RESET,function(e){var t=c(e,"initial"),n=u;return t?(n=l(n,"values",t),n=l(n,"initial",t)):n=v(n,"values"),n}),o(n,a.START_ASYNC_VALIDATION,function(e,t){var n=t.meta.field;return l(e,"asyncValidating",n||!0)}),o(n,a.START_SUBMIT,function(e){return l(e,"submitting",!0)}),o(n,a.STOP_ASYNC_VALIDATION,function(e,t){var n=t.payload,r=e;if(r=f(r,"asyncValidating"),n&&Object.keys(n).length){var o=n._error,a=i(n,["_error"]);o&&(r=l(r,"error",o)),r=Object.keys(a).length?l(r,"asyncErrors",p(a)):f(r,"asyncErrors")}else r=f(r,"error"),r=f(r,"asyncErrors");return r}),o(n,a.STOP_SUBMIT,function(e,t){var n=t.payload,r=e;if(r=f(r,"submitting"),r=f(r,"submitFailed"),n&&Object.keys(n).length){var o=n._error,a=i(n,["_error"]);o&&(r=l(r,"error",o)),r=Object.keys(a).length?l(r,"submitErrors",p(a)):f(r,"submitErrors"),r=l(r,"submitFailed",!0)}else r=f(r,"error"),r=f(r,"submitErrors");return r}),o(n,a.SET_SUBMIT_FAILED,function(e,t){var n=t.meta.fields,r=e;return r=l(r,"submitFailed",!0),r=f(r,"submitting"),n.forEach(function(e){return r=l(r,"fields."+e+".touched",!0)}),n.length&&(r=l(r,"anyTouched",!0)),r}),o(n,a.TOUCH,function(e,t){var n=t.meta.fields,r=e;return n.forEach(function(e){return r=l(r,"fields."+e+".touched",!0)}),r=l(r,"anyTouched",!0)}),o(n,a.UNREGISTER_FIELD,function(e,t){var n=t.payload.name,o=c(e,"registeredFields");if(!o)return e;var i=o.findIndex(function(e){return c(e,"name")===n});return d(o)<=1&&i>=0?v(e,"registeredFields"):l(e,"registeredFields",r(o,i,1))}),o(n,a.UNTOUCH,function(e,t){var n=t.meta.fields,r=e;return n.forEach(function(e){return r=f(r,"fields."+e+".touched")}),r}),n),_=function(){var e=arguments.length<=0||void 0===arguments[0]?u:arguments[0],t=arguments[1],n=b[t.type];return n?n(e,t):e},x=function(e){return function(){var t=arguments.length<=0||void 0===arguments[0]?u:arguments[0],n=arguments.length<=1||void 0===arguments[1]?{}:arguments[1],r=n&&n.meta&&n.meta.form;if(!r)return t;if(n.type===a.DESTROY)return v(t,n.meta.form);var o=c(t,r),i=e(o,n);return i===o?t:l(t,r,i)}};return t(x(_))};t.default=c},function(e,t,n){"use strict";function r(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}function o(e){return e&&e.__esModule?e:{default:e}}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function u(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function s(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}function c(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}Object.defineProperty(t,"__esModule",{value:!0});var l=n(283),f=o(l),p=n(44),d=o(p),h=n(67),v=o(h),m="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol?"symbol":typeof e},y=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),g=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},b=n(5),_=n(98),x=o(_),E=n(46),w=n(175),S=n(55),C=o(S),P=n(387),O=o(P),T=n(166),k=r(T),A=n(376),R=o(A),M=n(170),I=o(M),N=n(374),j=o(N),F=n(364),D=o(F),U=n(378),L=o(U),V=n(377),W=o(V),B=n(368),q=o(B),z=n(31),H=o(z),Y=k.arrayInsert,K=k.arrayPop,G=k.arrayPush,$=k.arrayRemove,X=k.arrayShift,Q=k.arraySplice,J=k.arraySwap,Z=k.arrayUnshift,ee=k.blur,te=k.change,ne=k.focus,re=c(k,["arrayInsert","arrayPop","arrayPush","arrayRemove","arrayShift","arraySplice","arraySwap","arrayUnshift","blur","change","focus"]),oe={arrayInsert:Y,arrayPop:K,arrayPush:G,arrayRemove:$,arrayShift:X,arraySplice:Q,arraySwap:J,arrayUnshift:Z},ie=[].concat(s(Object.keys(k)),["array","asyncErrors","initialized","initialValues","syncErrors","values","registeredFields"]),ae=function(e){if(!e||"function"!=typeof e)throw new Error("You must either pass handleSubmit() an onSubmit function or pass onSubmit as a prop");return e},ue=function(e){var t=e.deepEqual,n=e.empty,r=e.getIn,o=e.setIn,s=e.fromJS,l=e.some,p=(0,L.default)(e),h=(0,W.default)(e),_=(0,L.default)(H.default);return function(e){var S=g({touchOnBlur:!0,touchOnChange:!1,destroyOnUnmount:!0,shouldAsyncValidate:q.default,getFormState:function(e){return r(e,"form")}},e);return function(e){var P=function(n){function s(e){i(this,s);var t=a(this,Object.getPrototypeOf(s).call(this,e));return t.submit=t.submit.bind(t),t.reset=t.reset.bind(t),t.asyncValidate=t.asyncValidate.bind(t),t.getSyncErrors=t.getSyncErrors.bind(t),t.register=t.register.bind(t),t.unregister=t.unregister.bind(t),t.submitCompleted=t.submitCompleted.bind(t),t}return u(s,n),y(s,[{key:"getChildContext",value:function(){var e=this;return{_reduxForm:g({},this.props,{getFormState:function(t){return r(e.props.getFormState(t),e.props.form)},asyncValidate:this.asyncValidate,getSyncErrors:this.getSyncErrors,register:this.register,unregister:this.unregister})}}},{key:"initIfNeeded",value:function(e){var t=e.initialize,n=e.initialized,r=e.initialValues;r&&!n&&t(r)}},{key:"componentWillMount",value:function(){this.initIfNeeded(this.props)}},{key:"componentWillReceiveProps",value:function(e){this.initIfNeeded(e)}},{key:"shouldComponentUpdate",value:function(e){var n=this;return Object.keys(e).some(function(r){return!~ie.indexOf(r)&&!t(n.props[r],e[r])})}},{key:"componentWillUnmount",value:function(){var e=this.props,t=e.destroyOnUnmount,n=e.destroy;t&&(this.destroyed=!0,n())}},{key:"getSyncErrors",value:function(){return this.props.syncErrors}},{key:"register",value:function(e,t){this.props.registerField(e,t)}},{key:"unregister",value:function(e){this.destroyed||this.props.unregisterField(e)}},{key:"asyncValidate",value:function e(t,n){var i=this,a=this.props,u=a.asyncBlurFields,s=a.asyncErrors,e=a.asyncValidate,c=a.dispatch,l=a.initialized,f=a.pristine,p=a.shouldAsyncValidate,d=a.startAsyncValidation,h=a.stopAsyncValidation,v=a.syncErrors,y=a.values,g=!t;if(e){var b=function(){var a=g?y:o(y,t,n),m=g||!r(v,t),b=!g&&(!u||~u.indexOf(t.replace(/\[[0-9]+\]/g,"[]"))); if((b||g)&&p({asyncErrors:s,initialized:l,trigger:g?"submit":"blur",blurredField:t,pristine:f,syncValidationPasses:m}))return{v:(0,D.default)(function(){return e(a,c,i.props)},d,h,t)}}();if("object"===("undefined"==typeof b?"undefined":m(b)))return b.v}}},{key:"submitCompleted",value:function(e){return delete this.submitPromise,e}},{key:"listenToSubmit",value:function(e){return(0,C.default)(e)?(this.submitPromise=e,e.then(this.submitCompleted,this.submitCompleted)):e}},{key:"submit",value:function(e){var t=this,n=this.props.onSubmit;return e&&!(0,I.default)(e)?(0,j.default)(function(){return!t.submitPromise&&t.listenToSubmit((0,R.default)(ae(e),t.props,t.valid,t.asyncValidate,t.fieldList))}):this.submitPromise?void 0:this.listenToSubmit((0,R.default)(ae(n),this.props,this.valid,this.asyncValidate,this.fieldList))}},{key:"reset",value:function(){this.props.reset()}},{key:"render",value:function(){var t=this.props,n=(t.arrayInsert,t.arrayPop,t.arrayPush,t.arrayRemove,t.arrayShift,t.arraySplice,t.arraySwap,t.arrayUnshift,t.asyncErrors,t.reduxMountPoint,t.destroyOnUnmount,t.getFormState,t.touchOnBlur,t.touchOnChange,t.syncErrors,t.values,t.registerField,t.unregisterField,c(t,["arrayInsert","arrayPop","arrayPush","arrayRemove","arrayShift","arraySplice","arraySwap","arrayUnshift","asyncErrors","reduxMountPoint","destroyOnUnmount","getFormState","touchOnBlur","touchOnChange","syncErrors","values","registerField","unregisterField"]));return(0,b.createElement)(e,g({},n,{handleSubmit:this.submit}))}},{key:"values",get:function(){return this.props.values}},{key:"valid",get:function(){return this.props.valid}},{key:"invalid",get:function(){return!this.valid}},{key:"fieldList",get:function(){return this.props.registeredFields.map(function(e){return r(e,"name")})}}]),s}(b.Component);P.displayName="Form("+(0,O.default)(e)+")",P.WrappedComponent=e,P.childContextTypes={_reduxForm:b.PropTypes.object.isRequired},P.propTypes={adapter:b.PropTypes.func,destroyOnUnmount:b.PropTypes.bool,form:b.PropTypes.string.isRequired,initialValues:b.PropTypes.object,getFormState:b.PropTypes.func,validate:b.PropTypes.func,touchOnBlur:b.PropTypes.bool,touchOnChange:b.PropTypes.bool,registeredFields:b.PropTypes.any};var T=(0,E.connect)(function(e,o){var i=o.form,a=o.getFormState,u=o.initialValues,s=o.validate,c=r(a(e)||n,i)||n,f=r(c,"initial"),d=u||f||n,v=r(c,"values")||d,m=t(d,v),y=r(c,"asyncErrors"),g=r(c,"submitErrors"),b=s&&s(v,o)||{},x=_(b),E=p(y),w=p(g),S=!(x||E||w||l(r(c,"registeredFields"),function(e){return h(e,b,y,g)})),C=!!r(c,"anyTouched"),P=!!r(c,"submitting"),O=!!r(c,"submitFailed"),T=r(c,"error");return{anyTouched:C,asyncErrors:y,asyncValidating:r(c,"asyncValidating"),dirty:!m,error:T,initialized:!!f,invalid:!S,pristine:m,submitting:P,submitFailed:O,syncErrors:b,values:v,valid:S,registeredFields:r(c,"registeredFields")}},function(e,t){var n=function(e){return(0,d.default)(e,t.form)},r=(0,v.default)(re,n),o=(0,v.default)(oe,n),i=(0,f.default)(n(ee),!!t.touchOnBlur),a=(0,f.default)(n(te),!!t.touchOnChange),u=n(ne),s=(0,w.bindActionCreators)(r,e),c={insert:(0,w.bindActionCreators)(o.arrayInsert,e),pop:(0,w.bindActionCreators)(o.arrayPop,e),push:(0,w.bindActionCreators)(o.arrayPush,e),remove:(0,w.bindActionCreators)(o.arrayRemove,e),shift:(0,w.bindActionCreators)(o.arrayShift,e),splice:(0,w.bindActionCreators)(o.arraySplice,e),swap:(0,w.bindActionCreators)(o.arraySwap,e),unshift:(0,w.bindActionCreators)(o.arrayUnshift,e)},l=g({},s,o,{blur:i,change:a,array:c,focus:u,dispatch:e});return function(){return l}},void 0,{withRef:!0}),k=(0,x.default)(T(P),e);return k.defaultProps=S,function(e){function t(){return i(this,t),a(this,Object.getPrototypeOf(t).apply(this,arguments))}return u(t,e),y(t,[{key:"submit",value:function(){return this.refs.wrapped.getWrappedInstance().submit()}},{key:"reset",value:function(){return this.refs.wrapped.getWrappedInstance().reset()}},{key:"render",value:function(){var e=this.props,t=e.initialValues,n=c(e,["initialValues"]);return(0,b.createElement)(k,g({},n,{ref:"wrapped",initialValues:s(t)}))}},{key:"valid",get:function(){return this.refs.wrapped.getWrappedInstance().valid}},{key:"invalid",get:function(){return this.refs.wrapped.getWrappedInstance().invalid}},{key:"values",get:function(){return this.refs.wrapped.getWrappedInstance().values}},{key:"fieldList",get:function(){return this.refs.wrapped.getWrappedInstance().fieldList}}]),t}(b.Component)}}};t.default=ue},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(279),i=r(o),a=function(e,t){return e==t||null==e&&""===t||""===e&&null==t||void 0},u=function(e,t){return(0,i.default)(e,t,a)};t.default=u},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}Object.defineProperty(t,"__esModule",{value:!0});var a=n(45),u=r(a),s=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},c=function e(t,n){for(var r=arguments.length,a=Array(r>2?r-2:0),u=2;u<r;u++)a[u-2]=arguments[u];if(void 0===t||void 0===n)return t;if(a.length){if(Array.isArray(t)){if(n<t.length){var c=e.apply(void 0,[t&&t[n]].concat(a));if(c!==t[n]){var l=[].concat(i(t));return l[n]=c,l}}return t}if(n in t){var f=e.apply(void 0,[t&&t[n]].concat(a));return t[n]===f?t:s({},t,o({},n,f))}return t}if(Array.isArray(t)){if(isNaN(n))throw new Error("Cannot delete non-numerical index from an array");if(n<t.length){var p=[].concat(i(t));return p.splice(n,1),p}return t}if(n in t){var d=s({},t);return delete d[n],d}return t},l=function(e,t){return c.apply(void 0,[e].concat(i((0,u.default)(t))))};t.default=l},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}Object.defineProperty(t,"__esModule",{value:!0});var a=n(45),u=r(a),s=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},c=function e(t,n,r){for(var a=arguments.length,u=Array(a>3?a-3:0),c=3;c<a;c++)u[c-3]=arguments[c];if(void 0===r)return n;var l=e.apply(void 0,[t&&t[r],n].concat(u));if(!t){var f=isNaN(r)?{}:[];return f[r]=l,f}if(Array.isArray(t)){var p=[].concat(i(t));return p[r]=l,p}return s({},t,o({},r,l))},l=function(e,t,n){return c.apply(void 0,[e,n].concat(i((0,u.default)(t))))};t.default=l},function(e,t){"use strict";function n(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}Object.defineProperty(t,"__esModule",{value:!0});var r=function(){var e=arguments.length<=0||void 0===arguments[0]?[]:arguments[0],t=arguments[1],r=arguments[2],o=arguments[3],i=[].concat(n(e));return r?i.splice(t,r):i.splice(t,0,o),i};t.default=r},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(e){return e.displayName||e.name||"Component"};t.default=n},function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}Object.defineProperty(t,"__esModule",{value:!0});var o=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},i=n(46),a=function(e){var t=e.getIn;return function(e){var n=o({prop:"values",getFormState:function(e){return t(e,"form")}},e),a=n.form,u=n.prop,s=n.getFormState;return(0,i.connect)(function(e){return r({},u,t(s(e),a+".values"))},function(){return{}})}};t.default=a},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){return function(n,r,o){var a=e(n,r,o),s=a.dispatch,c=[],l={getState:a.getState,dispatch:function(e){return s(e)}};return c=t.map(function(e){return e(l)}),s=u.default.apply(void 0,c)(a.dispatch),i({},a,{dispatch:s})}}}t.__esModule=!0;var i=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e};t.default=o;var a=n(173),u=r(a)},function(e,t){"use strict";function n(e,t){return function(){return t(e.apply(void 0,arguments))}}function r(e,t){if("function"==typeof e)return n(e,t);if("object"!=typeof e||null===e)throw new Error("bindActionCreators expected an object or a function, instead received "+(null===e?"null":typeof e)+'. Did you write "import ActionCreators from" instead of "import * as ActionCreators from"?');for(var r=Object.keys(e),o={},i=0;i<r.length;i++){var a=r[i],u=e[a];"function"==typeof u&&(o[a]=n(u,t))}return o}t.__esModule=!0,t.default=r},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){var n=t&&t.type,r=n&&'"'+n.toString()+'"'||"an action";return"Given action "+r+', reducer "'+e+'" returned undefined. To ignore an action, you must explicitly return the previous state.'}function i(e){Object.keys(e).forEach(function(t){var n=e[t],r=n(void 0,{type:u.ActionTypes.INIT});if("undefined"==typeof r)throw new Error('Reducer "'+t+'" returned undefined during initialization. If the state passed to the reducer is undefined, you must explicitly return the initial state. The initial state may not be undefined.');var o="@@redux/PROBE_UNKNOWN_ACTION_"+Math.random().toString(36).substring(7).split("").join(".");if("undefined"==typeof n(void 0,{type:o}))throw new Error('Reducer "'+t+'" returned undefined when probed with a random type. '+("Don't try to handle "+u.ActionTypes.INIT+' or other actions in "redux/*" ')+"namespace. They are considered private. Instead, you must return the current state for any unknown actions, unless it is undefined, in which case you must return the initial state, regardless of the action type. The initial state may not be undefined.")})}function a(e){for(var t=Object.keys(e),n={},r=0;r<t.length;r++){var a=t[r];"function"==typeof e[a]&&(n[a]=e[a])}var u,s=Object.keys(n);try{i(n)}catch(e){u=e}return function(){var e=arguments.length<=0||void 0===arguments[0]?{}:arguments[0],t=arguments[1];if(u)throw u;for(var r=!1,i={},a=0;a<s.length;a++){var c=s[a],l=n[c],f=e[c],p=l(f,t);if("undefined"==typeof p){var d=o(c,t);throw new Error(d)}i[c]=p,r=r||p!==f}return r?i:e}}t.__esModule=!0,t.default=a;var u=n(174),s=n(65),c=(r(s),n(176));r(c)},function(e,t,n){(function(t){"use strict";e.exports=n(393)(t||window||this)}).call(t,function(){return this}())},function(e,t){"use strict";e.exports=function(e){var t,n=e.Symbol;return"function"==typeof n?n.observable?t=n.observable:(t=n("observable"),n.observable=t):t="@@observable",t}}])})},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function u(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var s=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},c=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),l=n(14),f=n(69),p=n(265),d=r(p),h=n(47),v=r(h),m=n(267),y=r(m),g=n(702),b=["_reduxForm"],_=function(e){var t=e.deepEqual,n=e.getIn,r=e.toJS,p=function(e,t){var n=v.default.getIn(e,t);return n&&n._error?n._error:n},h=function(e,t){var n=v.default.getIn(e,t);return n&&n._warning?n._warning:n},m=function(e){function f(e){i(this,f);var t=a(this,(f.__proto__||Object.getPrototypeOf(f)).call(this,e));return t.handleChange=t.handleChange.bind(t),t.handleFocus=t.handleFocus.bind(t),t.handleBlur=t.handleBlur.bind(t),t.handleDragStart=t.handleDragStart.bind(t),t.handleDrop=t.handleDrop.bind(t),t}return u(f,e),c(f,[{key:"shouldComponentUpdate",value:function(e){var n=this,r=Object.keys(e),o=Object.keys(this.props);return r.length!==o.length||r.some(function(r){return!~b.indexOf(r)&&!t(n.props[r],e[r])})}},{key:"isPristine",value:function(){return this.props.pristine}},{key:"getValue",value:function(){return this.props.value}},{key:"getRenderedComponent",value:function(){return this.refs.renderedComponent}},{key:"handleChange",value:function(e){var t=this.props,n=t.name,r=t.dispatch,o=t.parse,i=t.normalize,a=t._reduxForm,u=(0,y.default)(e,{name:n,parse:o,normalize:i});r(a.change(n,u))}},{key:"handleFocus",value:function(){var e=this.props,t=e.name,n=e.dispatch,r=e._reduxForm;n(r.focus(t))}},{key:"handleBlur",value:function(e){var t=this.props,n=t.name,r=t.dispatch,o=t.parse,i=t.normalize,a=t._reduxForm,u=(0,y.default)(e,{name:n,parse:o,normalize:i});r(a.blur(n,u)),a.asyncValidate&&a.asyncValidate(n,u)}},{key:"handleDragStart",value:function(e){var t=this.props.value;e.dataTransfer.setData(g.dataKey,null==t?"":t)}},{key:"handleDrop",value:function(e){var t=this.props,n=t.name,r=t.dispatch,o=t._reduxForm;r(o.change(n,e.dataTransfer.getData(g.dataKey))),e.preventDefault()}},{key:"render",value:function(){var e=this.props,t=e.component,i=e.withRef,a=e.name,u=(e._reduxForm,e.normalize,o(e,["component","withRef","name","_reduxForm","normalize"])),c=(0,d.default)({getIn:n,toJS:r},a,s({},u,{onBlur:this.handleBlur,onChange:this.handleChange,onDrop:this.handleDrop,onDragStart:this.handleDragStart,onFocus:this.handleFocus})),f=c.custom,p=o(c,["custom"]);if(i&&(f.ref="renderedComponent"),"string"==typeof t){var h=p.input;p.meta;return(0,l.createElement)(t,s({},h,f))}return(0,l.createElement)(t,s({},p,f))}}]),f}(l.Component);m.propTypes={component:l.PropTypes.oneOfType([l.PropTypes.func,l.PropTypes.string]).isRequired,props:l.PropTypes.object};var _=(0,f.connect)(function(e,t){var r=t.name,o=t._reduxForm,i=o.initialValues,a=o.getFormState,u=a(e),s=n(u,"initial."+r),c=void 0!==s?s:i&&n(i,r),l=n(u,"values."+r),f=n(u,"submitting"),d=p(n(u,"syncErrors"),r),v=h(n(u,"syncWarnings"),r),m=l===c;return{asyncError:n(u,"asyncErrors."+r),asyncValidating:n(u,"asyncValidating")===r,dirty:!m,pristine:m,state:n(u,"fields."+r),submitError:n(u,"submitErrors."+r),submitFailed:n(u,"submitFailed"),submitting:f,syncError:d,syncWarning:v,value:l,_value:t.value}},void 0,void 0,{withRef:!0});return _(m)};t.default=_},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function u(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var s=n(234),c=r(s),l=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},f=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),p=n(14),d=n(69),h=n(112),v=n(675),m=r(v),y=n(47),g=r(y),b=["_reduxForm","value"],_=function(e){var t=e.deepEqual,n=e.getIn,r=e.size,s=function(e,t){return g.default.getIn(e,t+"._error")},v=function(e,t){return g.default.getIn(e,t+"._warning")},y=function(e){function r(){i(this,r);var e=a(this,(r.__proto__||Object.getPrototypeOf(r)).call(this));return e.getValue=e.getValue.bind(e),e}return u(r,e),f(r,[{key:"shouldComponentUpdate",value:function(e){var n=this,r=Object.keys(e),o=Object.keys(this.props);return r.length!==o.length||r.some(function(r){return!~b.indexOf(r)&&!t(n.props[r],e[r])})}},{key:"getRenderedComponent",value:function(){return this.refs.renderedComponent}},{key:"getValue",value:function(e){return this.props.value&&n(this.props.value,e)}},{key:"render",value:function(){var e=this.props,t=e.component,r=e.withRef,i=e.name,a=(e._reduxForm,o(e,["component","withRef","name","_reduxForm"])),u=(0,m.default)(n,i,this.getValue,l({},a,{name:i}));return r&&(u.ref="renderedComponent"),(0,p.createElement)(t,u)}},{key:"dirty",get:function(){return this.props.dirty}},{key:"pristine",get:function(){return this.props.pristine}},{key:"value",get:function(){return this.props.value}}]),r}(p.Component);y.propTypes={component:p.PropTypes.oneOfType([p.PropTypes.func,p.PropTypes.string]).isRequired,props:p.PropTypes.object},y.contextTypes={_reduxForm:p.PropTypes.object};var _=(0,d.connect)(function(e,o){var i=o.name,a=o._reduxForm,u=a.initialValues,c=a.getFormState,l=c(e),f=n(l,"initial."+i)||u&&n(u,i),p=n(l,"values."+i),d=n(l,"submitting"),h=s(n(l,"syncErrors"),i),m=v(n(l,"syncWarnings"),i),y=t(p,f);return{asyncError:n(l,"asyncErrors."+i+"._error"),dirty:!y,pristine:y,state:n(l,"fields."+i),submitError:n(l,"submitErrors."+i+"._error"),submitting:d,syncError:h,syncWarning:m,value:p,length:r(p)}},function(e,t){var n=t.name,r=t._reduxForm,o=r.arrayInsert,i=r.arrayMove,a=r.arrayPop,u=r.arrayPush,s=r.arrayRemove,l=r.arrayRemoveAll,f=r.arrayShift,p=r.arraySplice,d=r.arraySwap,v=r.arrayUnshift;return(0,c.default)({arrayInsert:o,arrayMove:i,arrayPop:a,arrayPush:u,arrayRemove:s,arrayRemoveAll:l,arrayShift:f,arraySplice:p,arraySwap:d,arrayUnshift:v},function(t){return(0,h.bindActionCreators)(t.bind(null,n),e)})},void 0,{withRef:!0});return _(y)};t.default=_},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}function i(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var c=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},l=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),f=n(14),p=n(69),d=n(265),h=r(d),v=n(47),m=r(v),y=n(267),g=r(y),b=["_reduxForm"],_=function(e){var t=e.deepEqual,n=e.getIn,r=e.toJS,d=function(e,t){var n=m.default.getIn(e,t);return n&&n._error?n._error:n},v=function(e,t){var n=m.default.getIn(e,t);return n&&n._warning?n._warning:n},y=function(e){function p(e){a(this,p);var t=u(this,(p.__proto__||Object.getPrototypeOf(p)).call(this,e));return t.handleChange=t.handleChange.bind(t),t.handleFocus=t.handleFocus.bind(t),t.handleBlur=t.handleBlur.bind(t),t.onChangeFns=Object.keys(e._fields).reduce(function(e,n){return c({},e,i({},n,function(e){return t.handleChange(n,e)}))},{}),t.onFocusFns=Object.keys(e._fields).reduce(function(e,n){return c({},e,i({},n,function(){return t.handleFocus(n)}))},{}),t.onBlurFns=Object.keys(e._fields).reduce(function(e,n){return c({},e,i({},n,function(e){return t.handleBlur(n,e)}))},{}),t}return s(p,e),l(p,[{key:"shouldComponentUpdate",value:function(e){var n=this,r=Object.keys(e),o=Object.keys(this.props);return r.length!==o.length||r.some(function(r){return!~b.indexOf(r)&&!t(n.props[r],e[r])})}},{key:"isDirty",value:function(){var e=this.props._fields;return Object.keys(e).some(function(t){return e[t].dirty})}},{key:"getValues",value:function(){var e=this.props._fields;return Object.keys(e).reduce(function(t,n){return m.default.setIn(t,n,e[n].value)},{})}},{key:"getRenderedComponent",value:function(){return this.refs.renderedComponent}},{key:"handleChange",value:function(e,t){var n=this.props,r=n.dispatch,o=n.parse,i=n.normalize,a=n._reduxForm,u=(0,g.default)(t,{name:e,parse:o,normalize:i});r(a.change(e,u))}},{key:"handleFocus",value:function(e){var t=this.props,n=t.dispatch,r=t._reduxForm;n(r.focus(e))}},{key:"handleBlur",value:function(e,t){var n=this.props,r=n.dispatch,o=n.parse,i=n.normalize,a=n._reduxForm,u=(0,g.default)(t,{name:e,parse:o,normalize:i});r(a.blur(e,u)),a.asyncValidate&&a.asyncValidate(e,u)}},{key:"render",value:function(){var e=this,t=this.props,i=t.component,a=t.withRef,u=t._fields,s=t._reduxForm,l=o(t,["component","withRef","_fields","_reduxForm"]),p=s.sectionPrefix,d=Object.keys(u).reduce(function(t,i){var a=u[i],s=(0,h.default)({getIn:n,toJS:r},i,c({},a,l,{onBlur:e.onBlurFns[i],onChange:e.onChangeFns[i],onFocus:e.onFocusFns[i]})),f=s.custom,d=o(s,["custom"]);t.custom=f;var v=p?i.replace(p+".",""):i;return m.default.setIn(t,v,d)},{}),v=d.custom,y=o(d,["custom"]);return a&&(y.ref="renderedComponent"),(0,f.createElement)(i,c({},y,v))}}]),p}(f.Component);y.propTypes={component:f.PropTypes.oneOfType([f.PropTypes.func,f.PropTypes.string]).isRequired,_fields:f.PropTypes.object.isRequired,props:f.PropTypes.object};var _=(0,p.connect)(function(e,t){var r=t.names,o=t._reduxForm,i=o.initialValues,a=o.getFormState,u=a(e);return{_fields:r.reduce(function(e,r){var o=n(u,"initial."+r),a=void 0!==o?o:i&&n(i,r),s=n(u,"values."+r),c=d(n(u,"syncErrors"),r),l=v(n(u,"syncWarnings"),r),f=n(u,"submitting"),p=s===a;return e[r]={asyncError:n(u,"asyncErrors."+r),asyncValidating:n(u,"asyncValidating")===r,dirty:!p,pristine:p,state:n(u,"fields."+r),submitError:n(u,"submitErrors."+r),submitFailed:n(u,"submitFailed"),submitting:f,syncError:c,syncWarning:l,value:s,_value:t.value},e},{})}},void 0,void 0,{withRef:!0});return _(y)};t.default=_},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var u=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),c=n(14),l=n(77),f=r(l),p=n(665),d=r(p),h=n(178),v=r(h),m=n(111),y=r(m),g=function(e){var t=e.deepEqual,n=e.getIn,r=e.setIn,l=e.toJS,p=(0,d.default)({deepEqual:t,getIn:n,toJS:l}),h=function(e){function t(e,n){o(this,t);var r=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,n));if(!n._reduxForm)throw new Error("Field must be inside a component decorated with reduxForm()");return r.normalize=r.normalize.bind(r),r}return a(t,e),s(t,[{key:"shouldComponentUpdate",value:function(e,t){return(0,v.default)(this,e,t)}},{key:"componentWillMount",value:function(){var e=this;this.context._reduxForm.register(this.name,"Field",function(){return e.props.validate},function(){return e.props.warn})}},{key:"componentWillReceiveProps",value:function(e){this.props.name!==e.name&&(this.context._reduxForm.unregister(this.name),this.context._reduxForm.register((0,y.default)(this.context,e.name),"Field"))}},{key:"componentWillUnmount",value:function(){this.context._reduxForm.unregister(this.name)}},{key:"getRenderedComponent",value:function(){return(0,f.default)(this.props.withRef,"If you want to access getRenderedComponent(), you must specify a withRef prop to Field"),this.refs.connected.getWrappedInstance().getRenderedComponent()}},{key:"normalize",value:function e(t,n){var e=this.props.normalize;if(!e)return n;var o=this.context._reduxForm.getValues(),i=this.value,a=r(o,t,n);return e(n,i,a,o)}},{key:"render",value:function(){return(0,c.createElement)(p,u({},this.props,{name:this.name,normalize:this.normalize,_reduxForm:this.context._reduxForm,ref:"connected"}))}},{key:"name",get:function(){return(0,y.default)(this.context,this.props.name)}},{key:"dirty",get:function(){return!this.pristine}},{key:"pristine",get:function(){return this.refs.connected.getWrappedInstance().isPristine()}},{key:"value",get:function(){return this.refs.connected&&this.refs.connected.getWrappedInstance().getValue()}}]),t}(c.Component);return h.propTypes={name:c.PropTypes.string.isRequired,component:c.PropTypes.oneOfType([c.PropTypes.func,c.PropTypes.string]).isRequired,format:c.PropTypes.func,normalize:c.PropTypes.func,parse:c.PropTypes.func,props:c.PropTypes.object},h.contextTypes={_reduxForm:c.PropTypes.object},h};t.default=g},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function u(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}Object.defineProperty(t,"__esModule",{value:!0});var s=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},c=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),l=n(14),f=n(77),p=r(f),d=n(666),h=r(d),v=n(178),m=r(v),y=n(111),g=r(y),b=function(e){return Array.isArray(e)?e:[e]},_=function(e,t){return e&&function(){var n=b(e),r=!0,o=!1,i=void 0;try{for(var a,s=n[Symbol.iterator]();!(r=(a=s.next()).done);r=!0){var c=a.value,l=c.apply(void 0,arguments);if(l)return u({},t,l)}}catch(e){o=!0,i=e}finally{try{!r&&s.return&&s.return()}finally{if(o)throw i}}}},x=function(e){var t=e.deepEqual,n=e.getIn,r=e.size,u=(0,h.default)({deepEqual:t,getIn:n,size:r}),f=function(e){function t(e,n){o(this,t);var r=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,n));if(!n._reduxForm)throw new Error("FieldArray must be inside a component decorated with reduxForm()");return r}return a(t,e),c(t,[{key:"shouldComponentUpdate",value:function(e,t){return(0,m.default)(this,e,t)}},{key:"componentWillMount",value:function(){var e=this;this.context._reduxForm.register(this.name,"FieldArray",function(){return _(e.props.validate,"_error")},function(){return _(e.props.warn,"_warning")})}},{key:"componentWillReceiveProps",value:function(e){this.props.name!==e.name&&(this.context._reduxForm.unregister(this.name),this.context._reduxForm.register((0,g.default)(this.context,e.name),"FieldArray"))}},{key:"componentWillUnmount",value:function(){this.context._reduxForm.unregister(this.name)}},{key:"getRenderedComponent",value:function(){return(0,p.default)(this.props.withRef,"If you want to access getRenderedComponent(), you must specify a withRef prop to FieldArray"),this.refs.connected.getWrappedInstance().getRenderedComponent()}},{key:"render",value:function(){return(0,l.createElement)(u,s({},this.props,{name:this.name,syncError:this.syncError,syncWarning:this.syncWarning,_reduxForm:this.context._reduxForm,ref:"connected"}))}},{key:"name",get:function(){return(0,g.default)(this.context,this.props.name)}},{key:"dirty",get:function(){return this.refs.connected.getWrappedInstance().dirty}},{key:"pristine",get:function(){return this.refs.connected.getWrappedInstance().pristine}},{key:"value",get:function(){return this.refs.connected.getWrappedInstance().value}}]),t}(l.Component);return f.propTypes={name:l.PropTypes.string.isRequired,component:l.PropTypes.func.isRequired,props:l.PropTypes.object},f.contextTypes={_reduxForm:l.PropTypes.object},f};t.default=x},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var u=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),c=n(14),l=n(77),f=r(l),p=n(667),d=r(p),h=n(178),v=r(h),m=n(47),y=r(m),g=n(111),b=r(g),_=function(e){return e?Array.isArray(e)||e._isFieldArray?void 0:new Error('Invalid prop "names" supplied to <Fields/>. Must be either an array of strings or the fields array generated by FieldArray.'):new Error('No "names" prop was specified <Fields/>')},x=function(e){var t=e.deepEqual,n=e.getIn,r=e.toJS,l=(0, d.default)({deepEqual:t,getIn:n,toJS:r}),p=function(e){function t(e,n){o(this,t);var r=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,n));if(!n._reduxForm)throw new Error("Fields must be inside a component decorated with reduxForm()");return r}return a(t,e),s(t,[{key:"shouldComponentUpdate",value:function(e,t){return(0,v.default)(this,e,t)}},{key:"componentWillMount",value:function(){var e=_(this.props.names);if(e)throw e;var t=this.context,n=t._reduxForm.register;this.names.forEach(function(e){return n((0,b.default)(t,e),"Field")})}},{key:"componentWillReceiveProps",value:function(e){var t=this;y.default.deepEqual(this.props.names,e.names)||!function(){var n=t.context,r=n._reduxForm,o=r.register,i=r.unregister;t.props.names.forEach(function(e){return i((0,b.default)(n,e))}),e.names.forEach(function(e){return o((0,b.default)(n,e),"Field")})}()}},{key:"componentWillUnmount",value:function(){var e=this.context,t=e._reduxForm.unregister;this.props.names.forEach(function(n){return t((0,b.default)(e,n))})}},{key:"getRenderedComponent",value:function(){return(0,f.default)(this.props.withRef,"If you want to access getRenderedComponent(), you must specify a withRef prop to Fields"),this.refs.connected.getWrappedInstance().getRenderedComponent()}},{key:"render",value:function(){var e=this.context;return(0,c.createElement)(l,u({},this.props,{names:this.props.names.map(function(t){return(0,b.default)(e,t)}),_reduxForm:this.context._reduxForm,ref:"connected"}))}},{key:"names",get:function(){return this.props.names}},{key:"dirty",get:function(){return this.refs.connected.getWrappedInstance().isDirty()}},{key:"pristine",get:function(){return!this.dirty}},{key:"values",get:function(){return this.refs.connected&&this.refs.connected.getWrappedInstance().getValues()}}]),t}(c.Component);return p.propTypes={names:function(e,t){return _(e[t])},component:c.PropTypes.oneOfType([c.PropTypes.func,c.PropTypes.string]).isRequired,format:c.PropTypes.func,parse:c.PropTypes.func,props:c.PropTypes.object},p.contextTypes={_reduxForm:c.PropTypes.object},p};t.default=x},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function a(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var u=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),s=n(14),c=r(s),l=function(e){function t(e,n){o(this,t);var r=i(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,n));if(!n._reduxForm)throw new Error("Form must be inside a component decorated with reduxForm()");return r}return a(t,e),u(t,[{key:"componentWillMount",value:function(){this.context._reduxForm.registerInnerOnSubmit(this.props.onSubmit)}},{key:"render",value:function(){return c.default.createElement("form",this.props)}}]),t}(s.Component);l.propTypes={onSubmit:s.PropTypes.func.isRequired},l.contextTypes={_reduxForm:s.PropTypes.object},t.default=l},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}function i(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function u(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var s=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},c=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),l=n(14),f=r(l),p=n(111),d=r(p),h=function(e){function t(e,n){i(this,t);var r=a(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,n));if(!n._reduxForm)throw new Error("FormSection must be inside a component decorated with reduxForm()");return r}return u(t,e),c(t,[{key:"getChildContext",value:function(){var e=this.context,t=this.props.name;return{_reduxForm:s({},e._reduxForm,{sectionPrefix:(0,d.default)(e,t)})}}},{key:"render",value:function(){var e=this.props,t=e.children,n=(e.name,e.component),r=o(e,["children","name","component"]);return f.default.isValidElement(t)?t:(0,l.createElement)(n,s({},r,{children:t}))}}]),t}(l.Component);h.propTypes={name:l.PropTypes.string.isRequired,component:l.PropTypes.oneOfType([l.PropTypes.func,l.PropTypes.string])},h.defaultProps={component:"div"},h.childContextTypes={_reduxForm:l.PropTypes.object.isRequired},h.contextTypes={_reduxForm:l.PropTypes.object},t.default=h},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(142),i=r(o),a=function(e,t,n,r){t(r);var o=e();if(!(0,i.default)(o))throw new Error("asyncValidate function passed to reduxForm must return a promise");var a=function(e){return function(t){if(t&&Object.keys(t).length)return n(t),t;if(e)throw n(),new Error("Asynchronous validation promise was rejected without errors.");return n(),Promise.resolve()}};return o.then(a(!1),a(!0))};t.default=a},function(e,t,n){"use strict";function r(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}function o(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var i=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},a=n(687),u=o(a),s=n(688),c=o(s),l=n(668),f=o(l),p=n(670),d=o(p),h=n(669),v=o(h),m=n(681),y=o(m),g=n(704),b=o(g),_=n(692),x=o(_),E=n(691),w=o(E),S=n(689),C=o(S),P=n(690),O=o(P),T=n(695),k=o(T),A=n(696),R=o(A),M=n(269),I=o(M),N=n(177),j=o(N),F=n(697),D=o(F),U=n(694),L=o(U),V=n(693),W=o(V),B=n(671),q=o(B),z=n(672),H=o(z),Y=n(263),K=o(Y),G=n(686),$=o(G),X=n(264),Q=r(X),J=n(176),Z=r(J),ee=function(e){return i({actionTypes:Z},Q,{Field:(0,f.default)(e),Fields:(0,d.default)(e),FieldArray:(0,v.default)(e),Form:q.default,FormSection:H.default,formValueSelector:(0,y.default)(e),getFormValues:(0,x.default)(e),getFormSyncErrors:(0,w.default)(e),getFormAsyncErrors:(0,C.default)(e),getFormSubmitErrors:(0,O.default)(e),isDirty:(0,k.default)(e),isInvalid:(0,R.default)(e),isPristine:(0,I.default)(e),isValid:(0,j.default)(e),isSubmitting:(0,D.default)(e),hasSubmitSucceeded:(0,L.default)(e),hasSubmitFailed:(0,W.default)(e),propTypes:$.default,reduxForm:(0,c.default)(e),reducer:(0,u.default)(e),SubmissionError:K.default,values:(0,b.default)(e)})};t.default=ee},function(e,t){"use strict";function n(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}Object.defineProperty(t,"__esModule",{value:!0});var r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},o=function(e,t,o,i){var a=i.arrayInsert,u=i.arrayMove,s=i.arrayPop,c=i.arrayPush,l=i.arrayRemove,f=i.arrayRemoveAll,p=i.arrayShift,d=(i.arraySplice,i.arraySwap),h=i.arrayUnshift,v=i.asyncError,m=i.dirty,y=i.length,g=i.pristine,b=i.submitError,_=i.state,x=(i.submitFailed,i.submitting),E=i.syncError,w=i.syncWarning,S=i.value,C=i.props,P=n(i,["arrayInsert","arrayMove","arrayPop","arrayPush","arrayRemove","arrayRemoveAll","arrayShift","arraySplice","arraySwap","arrayUnshift","asyncError","dirty","length","pristine","submitError","state","submitFailed","submitting","syncError","syncWarning","value","props"]),O=E||v||b,T=w,k=r({fields:{_isFieldArray:!0,forEach:function(e){return(S||[]).forEach(function(n,r){return e(t+"["+r+"]",r,k.fields)})},get:o,getAll:function(){return S},insert:a,length:y,map:function(e){return(S||[]).map(function(n,r){return e(t+"["+r+"]",r,k.fields)})},move:u,name:t,pop:function(){return s(),e(S,y-1)},push:c,reduce:function(e,n){return(S||[]).reduce(function(n,r,o){return e(n,t+"["+o+"]",o,k.fields)},n)},remove:l,removeAll:f,shift:function(){return p(),e(S,0)},swap:d,unshift:h},meta:{dirty:m,error:O,warning:T,invalid:!!O,pristine:g,submitting:x,touched:!(!_||!e(_,"touched")),valid:!O}},C,P);return k};t.default=o},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(e){var t=e.initialized,n=e.trigger,r=e.pristine,o=e.syncValidationPasses;if(!o)return!1;switch(n){case"blur":return!0;case"submit":return!r||!t;default:return!1}};t.default=n},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(e){var t=e.values,n=e.nextProps,r=e.initialRender,o=e.lastFieldValidatorKeys,i=e.fieldValidatorKeys,a=e.structure;return!!r||(!a.deepEqual(t,n.values)||!a.deepEqual(o,i))};t.default=n},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(104),i=r(o),a=function(e){var t=e.deepEqual,n=e.empty,r=e.getIn,o=e.deleteIn,a=e.setIn,u=function e(u,s){if("]"===s[s.length-1]){var c=(0,i.default)(s);c.pop();var l=r(u,c.join("."));return l?a(u,s,void 0):u}var f=o(u,s),p=s.lastIndexOf(".");if(p>0){var d=s.substring(0,p);if("]"!==d[d.length-1]){var h=r(f,d);if(t(h,n))return e(f,d)}}return f};return u};t.default=a},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(266),i=r(o),a=function(e){var t=[];if(e)for(var n=0;n<e.length;n++){var r=e[n];r.selected&&t.push(r.value)}return t},u=function(e,t){if((0,i.default)(e)){if(!t&&e.nativeEvent&&void 0!==e.nativeEvent.text)return e.nativeEvent.text;if(t&&void 0!==e.nativeEvent)return e.nativeEvent.text;var n=e.target,r=n.type,o=n.value,u=n.checked,s=n.files,c=e.dataTransfer;return"checkbox"===r?u:"file"===r?s||c&&c.files:"select-multiple"===r?a(e.target.options):o}return e};t.default=u},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(268),i=r(o),a=function(e){return function(t){for(var n=arguments.length,r=Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return(0,i.default)(t)?e.apply(void 0,r):e.apply(void 0,[t].concat(r))}};t.default=a},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(77),i=r(o),a=n(47),u=r(a),s=function(e){var t=e.getIn;return function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(e){return t(e,"form")};return(0,i.default)(e,"Form value must be specified"),function(r){for(var o=arguments.length,a=Array(o>1?o-1:0),s=1;s<o;s++)a[s-1]=arguments[s];return(0,i.default)(a.length,"No fields specified"),1===a.length?t(n(r),e+".values."+a[0]):a.reduce(function(o,i){var a=t(n(r),e+".values."+i);return void 0===a?o:u.default.setIn(o,i,a)},{})}}};t.default=s},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(47),i=r(o),a=function(e){return Array.isArray(e)?e:[e]},u=function(e,t,n){var r=!0,o=!1,i=void 0;try{for(var u,s=a(n)[Symbol.iterator]();!(r=(u=s.next()).done);r=!0){var c=u.value,l=c(e,t);if(l)return l}}catch(e){o=!0,i=e}finally{try{!r&&s.return&&s.return()}finally{if(o)throw i}}},s=function(e,t){var n=t.getIn;return function(t){var r={};return Object.keys(e).forEach(function(o){var a=n(t,o),s=u(a,t,e[o]);s&&(r=i.default.setIn(r,o,s))}),r}};t.default=s},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}Object.defineProperty(t,"__esModule",{value:!0});var i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},a=n(142),u=r(a),s=n(263),c=r(s),l=function(e,t,n,r,a){var s=t.dispatch,l=t.onSubmitFail,f=t.onSubmitSuccess,p=t.startSubmit,d=t.stopSubmit,h=t.setSubmitFailed,v=t.setSubmitSucceeded,m=t.syncErrors,y=t.touch,g=t.values,b=t.persistentSubmitErrors;if(y.apply(void 0,o(a)),!n&&!b)return h.apply(void 0,o(a)),l&&l(m,s,null),m;var _=function(){var n=function(){var n=void 0;try{n=e(g,s,t)}catch(e){var r=e instanceof c.default?e.errors:void 0;if(d(r),h.apply(void 0,o(a)),l&&l(r,s,e),r||l)return r;throw e}return(0,u.default)(n)?(p(),n.then(function(e){return d(),v(),f&&f(e,s),e},function(e){var t=e instanceof c.default?e.errors:void 0;if(d(t),h.apply(void 0,o(a)),l&&l(t,s,e),t||l)return t;throw e})):(v(),f&&f(n,s),n)},i=r&&r();return i?{v:i.then(function(e){if(e)throw e;return n()}).catch(function(e){return h.apply(void 0,o(a)),l&&l(e,s,null),Promise.reject(e)})}:{v:n()}}();return"object"===("undefined"==typeof _?"undefined":i(_))?_.v:void 0};t.default=l},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(270),i=r(o),a=function(e,t){switch(t){case"Field":return[e,e+"._error"];case"FieldArray":return[e+"._error"]}},u=function(e){var t=e.getIn,n=function(e,n,r,o){if(!n&&!r&&!o)return!1;var u=t(e,"name"),s=t(e,"type");return a(u,s).some(function(e){return(0,i.default)(n,e)||t(r,e)||t(o,e)})};return n};t.default=u},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n="undefined"!=typeof window&&window.navigator&&window.navigator.product&&"ReactNative"===window.navigator.product;t.default=n},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(14),o=r.PropTypes.any,i=r.PropTypes.bool,a=r.PropTypes.func,u=r.PropTypes.shape,s={asyncValidating:i.isRequired,dirty:i.isRequired,error:o,warning:o,invalid:i.isRequired,initialized:i.isRequired,pristine:i.isRequired,submitting:i.isRequired,submitFailed:i.isRequired,submitSucceeded:i.isRequired,valid:i.isRequired,array:u({insert:a.isRequired,move:a.isRequired,pop:a.isRequired,push:a.isRequired,remove:a.isRequired,removeAll:a.isRequired,shift:a.isRequired,splice:a.isRequired,swap:a.isRequired,unshift:a.isRequired}),asyncValidate:a.isRequired,blur:a.isRequired,change:a.isRequired,destroy:a.isRequired,dispatch:a.isRequired,handleSubmit:a.isRequired,initialize:a.isRequired,reset:a.isRequired,touch:a.isRequired,untouch:a.isRequired};t.default=s},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}Object.defineProperty(t,"__esModule",{value:!0});var a=n(176);n(274);var u=n(678),s=r(u),c=function(e){function t(e){return e.plugin=function(e){var n=this;return t(function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:u,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return Object.keys(e).reduce(function(n,o){var i=c(n,o),a=e[o](i,r,c(t,o));return a===i?n:l(n,o,a)},n(t,r))})},e}var n,r=e.deepEqual,u=e.empty,c=e.getIn,l=e.setIn,f=e.deleteIn,p=e.fromJS,d=e.size,h=e.some,v=e.splice,m=(0,s.default)(e),y=function(e,t,n,r,o,i,a){var u=c(e,t+"."+n);return u||a?l(e,t+"."+n,v(u,r,o,i)):e},g=["values","fields","submitErrors","asyncErrors"],b=function(e,t,n,r,o){var i=e,a=null!=o?u:void 0;return i=y(i,"values",t,n,r,o,!0),i=y(i,"fields",t,n,r,a),i=y(i,"submitErrors",t,n,r,a),i=y(i,"asyncErrors",t,n,r,a)},_=(n={},o(n,a.ARRAY_INSERT,function(e,t){var n=t.meta,r=n.field,o=n.index,i=t.payload;return b(e,r,o,0,i)}),o(n,a.ARRAY_MOVE,function(e,t){var n=t.meta,r=n.field,o=n.from,i=n.to,a=c(e,"values."+r),u=a?d(a):0,s=e;return u&&g.forEach(function(e){var t=e+"."+r;if(c(s,t)){var n=c(s,t+"["+o+"]");s=l(s,t,v(c(s,t),o,1)),s=l(s,t,v(c(s,t),i,0,n))}}),s}),o(n,a.ARRAY_POP,function(e,t){var n=t.meta.field,r=c(e,"values."+n),o=r?d(r):0;return o?b(e,n,o-1,1):e}),o(n,a.ARRAY_PUSH,function(e,t){var n=t.meta.field,r=t.payload,o=c(e,"values."+n),i=o?d(o):0;return b(e,n,i,0,r)}),o(n,a.ARRAY_REMOVE,function(e,t){var n=t.meta,r=n.field,o=n.index;return b(e,r,o,1)}),o(n,a.ARRAY_REMOVE_ALL,function(e,t){var n=t.meta.field,r=c(e,"values."+n),o=r?d(r):0;return o?b(e,n,0,o):e}),o(n,a.ARRAY_SHIFT,function(e,t){var n=t.meta.field;return b(e,n,0,1)}),o(n,a.ARRAY_SPLICE,function(e,t){var n=t.meta,r=n.field,o=n.index,i=n.removeNum,a=t.payload;return b(e,r,o,i,a)}),o(n,a.ARRAY_SWAP,function(e,t){var n=t.meta,r=n.field,o=n.indexA,i=n.indexB,a=e;return g.forEach(function(e){var t=c(a,e+"."+r+"["+o+"]"),n=c(a,e+"."+r+"["+i+"]");void 0===t&&void 0===n||(a=l(a,e+"."+r+"["+o+"]",n),a=l(a,e+"."+r+"["+i+"]",t))}),a}),o(n,a.ARRAY_UNSHIFT,function(e,t){var n=t.meta.field,r=t.payload;return b(e,n,0,0,r)}),o(n,a.AUTOFILL,function(e,t){var n=t.meta.field,r=t.payload,o=e;return o=m(o,"asyncErrors."+n),o=m(o,"submitErrors."+n),o=l(o,"fields."+n+".autofilled",!0),o=l(o,"values."+n,r)}),o(n,a.BLUR,function(e,t){var n=t.meta,r=n.field,o=n.touch,i=t.payload,a=e,u=c(a,"initial."+r);return void 0===u&&""===i?a=m(a,"values."+r):void 0!==i&&(a=l(a,"values."+r,i)),r===c(a,"active")&&(a=f(a,"active")),a=f(a,"fields."+r+".active"),o&&(a=l(a,"fields."+r+".touched",!0),a=l(a,"anyTouched",!0)),a}),o(n,a.CHANGE,function(e,t){var n=t.meta,r=n.field,o=n.touch,i=n.persistentSubmitErrors,a=t.payload,u=e,s=c(u,"initial."+r);return void 0===s&&""===a?u=m(u,"values."+r):void 0!==a&&(u=l(u,"values."+r,a)),u=m(u,"asyncErrors."+r),i||(u=m(u,"submitErrors."+r)),u=m(u,"fields."+r+".autofilled"),o&&(u=l(u,"fields."+r+".touched",!0),u=l(u,"anyTouched",!0)),u}),o(n,a.CLEAR_SUBMIT,function(e){return f(e,"triggerSubmit")}),o(n,a.CLEAR_ASYNC_ERROR,function(e,t){var n=t.meta.field;return f(e,"asyncErrors."+n)}),o(n,a.FOCUS,function(e,t){var n=t.meta.field,r=e,o=c(e,"active");return r=f(r,"fields."+o+".active"),r=l(r,"fields."+n+".visited",!0),r=l(r,"fields."+n+".active",!0),r=l(r,"active",n)}),o(n,a.INITIALIZE,function(e,t){var n=t.payload,o=t.meta.keepDirty,i=p(n),a=u,s=c(e,"warning");s&&(a=l(a,"warning",s));var f=c(e,"syncWarnings");f&&(a=l(a,"syncWarnings",f));var d=c(e,"error");d&&(a=l(a,"error",d));var h=c(e,"syncErrors");h&&(a=l(a,"syncErrors",h));var v=c(e,"registeredFields");v&&(a=l(a,"registeredFields",v));var m=i;return o&&v&&!function(){var t=c(e,"values"),n=c(e,"initial");v.forEach(function(e){var o=c(e,"name"),i=c(n,o),a=c(t,o);r(a,i)||(m=l(m,o,a))})}(),a=l(a,"values",m),a=l(a,"initial",i)}),o(n,a.REGISTER_FIELD,function(e,t){var n=t.payload,r=n.name,o=n.type,i=e,a=c(i,"registeredFields");if(h(a,function(e){return c(e,"name")===r}))return e;var u=p({name:r,type:o});return i=l(e,"registeredFields",v(a,d(a),0,u))}),o(n,a.RESET,function(e){var t=u,n=c(e,"registeredFields");n&&(t=l(t,"registeredFields",n));var r=c(e,"initial");return r&&(t=l(t,"values",r),t=l(t,"initial",r)),t}),o(n,a.SUBMIT,function(e){return l(e,"triggerSubmit",!0)}),o(n,a.START_ASYNC_VALIDATION,function(e,t){var n=t.meta.field;return l(e,"asyncValidating",n||!0)}),o(n,a.START_SUBMIT,function(e){return l(e,"submitting",!0)}),o(n,a.STOP_ASYNC_VALIDATION,function(e,t){var n=t.payload,r=e;if(r=f(r,"asyncValidating"),n&&Object.keys(n).length){var o=n._error,a=i(n,["_error"]);o&&(r=l(r,"error",o)),r=Object.keys(a).length?l(r,"asyncErrors",p(a)):f(r,"asyncErrors")}else r=f(r,"error"),r=f(r,"asyncErrors");return r}),o(n,a.STOP_SUBMIT,function(e,t){var n=t.payload,r=e;if(r=f(r,"submitting"),r=f(r,"submitFailed"),r=f(r,"submitSucceeded"),n&&Object.keys(n).length){var o=n._error,a=i(n,["_error"]);r=o?l(r,"error",o):f(r,"error"),r=Object.keys(a).length?l(r,"submitErrors",p(a)):f(r,"submitErrors"),r=l(r,"submitFailed",!0)}else r=l(r,"submitSucceeded",!0),r=f(r,"error"),r=f(r,"submitErrors");return r}),o(n,a.SET_SUBMIT_FAILED,function(e,t){var n=t.meta.fields,r=e;return r=l(r,"submitFailed",!0),r=f(r,"submitSucceeded"),r=f(r,"submitting"),n.forEach(function(e){return r=l(r,"fields."+e+".touched",!0)}),n.length&&(r=l(r,"anyTouched",!0)),r}),o(n,a.SET_SUBMIT_SUCCEEDED,function(e){var t=e;return t=f(t,"submitFailed"),t=l(t,"submitSucceeded",!0)}),o(n,a.TOUCH,function(e,t){var n=t.meta.fields,r=e;return n.forEach(function(e){return r=l(r,"fields."+e+".touched",!0)}),r=l(r,"anyTouched",!0)}),o(n,a.UNREGISTER_FIELD,function(e,t){var n=t.payload.name,r=c(e,"registeredFields");if(!r)return e;var o=r.findIndex(function(e){return c(e,"name")===n});return d(r)<=1&&o>=0?m(e,"registeredFields"):o<0?e:l(e,"registeredFields",v(r,o,1))}),o(n,a.UNTOUCH,function(e,t){var n=t.meta.fields,r=e;return n.forEach(function(e){return r=f(r,"fields."+e+".touched")}),r}),o(n,a.UPDATE_SYNC_ERRORS,function(e,t){var n=t.payload,r=n.syncErrors,o=n.error,i=e;return o?(i=l(i,"error",o),i=l(i,"syncError",!0)):(i=f(i,"error"),i=f(i,"syncError")),i=Object.keys(r).length?l(i,"syncErrors",r):f(i,"syncErrors")}),o(n,a.UPDATE_SYNC_WARNINGS,function(e,t){var n=t.payload,r=n.syncWarnings,o=n.warning,i=e;return i=o?l(i,"warning",o):f(i,"warning"),i=Object.keys(r).length?l(i,"syncWarnings",r):f(i,"syncWarnings")}),n),x=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:u,t=arguments[1],n=_[t.type];return n?n(e,t):e},E=function(e){return function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:u,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=n&&n.meta&&n.meta.form;if(!r)return t;if(n.type===a.DESTROY)return m(t,n.meta.form);var o=c(t,r),i=e(o,n);return i===o?t:l(t,r,i)}};return t(E(x))};t.default=c},function(e,t,n){"use strict";function r(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}function o(e){return e&&e.__esModule?e:{default:e}}function i(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function s(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function c(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}function l(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}Object.defineProperty(t,"__esModule",{value:!0});var f=n(572),p=o(f),d=n(234),h=o(d),v=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),m=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},y="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},g=n(14),b=n(211),_=o(b),x=n(69),E=n(112),w=n(142),S=o(w),C=n(703),P=o(C),O=n(264),T=r(O),k=n(683),A=o(k),R=n(268),M=o(R),I=n(680),N=o(I),j=n(673),F=o(j),D=n(676),U=o(D),L=n(677),V=o(L),W=n(47),B=o(W),q=n(682),z=o(q),H=n(177),Y=o(H),K=function(e){return Boolean(e&&e.prototype&&"object"===y(e.prototype.isReactComponent))},G=T.arrayInsert,$=T.arrayMove,X=T.arrayPop,Q=T.arrayPush,J=T.arrayRemove,Z=T.arrayRemoveAll,ee=T.arrayShift,te=T.arraySplice,ne=T.arraySwap,re=T.arrayUnshift,oe=T.blur,ie=T.change,ae=T.focus,ue=l(T,["arrayInsert","arrayMove","arrayPop","arrayPush","arrayRemove","arrayRemoveAll","arrayShift","arraySplice","arraySwap","arrayUnshift","blur","change","focus"]),se={arrayInsert:G,arrayMove:$,arrayPop:X,arrayPush:Q,arrayRemove:J,arrayRemoveAll:Z,arrayShift:ee,arraySplice:te,arraySwap:ne,arrayUnshift:re},ce=[].concat(c(Object.keys(T)),["array","asyncErrors","initialized","initialValues","syncErrors","syncWarnings","values","registeredFields"]),le=function(e){if(!e||"function"!=typeof e)throw new Error("You must either pass handleSubmit() an onSubmit function or pass onSubmit as a prop");return e},fe=function(e){var t=e.deepEqual,n=e.empty,r=e.getIn,o=e.setIn,c=e.fromJS,f=(0,Y.default)(e);return function(d){var b=m({touchOnBlur:!0,touchOnChange:!1,persistentSubmitErrors:!1,destroyOnUnmount:!0,shouldAsyncValidate:U.default,shouldValidate:V.default,enableReinitialize:!1,keepDirtyOnReinitialize:!1,getFormState:function(e){return r(e,"form")},pure:!0,forceUnregisterOnUnmount:!1},d);return function(d){var w=0,C=function(n){function c(e){a(this,c);var t=u(this,(c.__proto__||Object.getPrototypeOf(c)).call(this,e));return t.submit=t.submit.bind(t),t.reset=t.reset.bind(t),t.asyncValidate=t.asyncValidate.bind(t),t.getValues=t.getValues.bind(t),t.register=t.register.bind(t),t.unregister=t.unregister.bind(t),t.submitCompleted=t.submitCompleted.bind(t),t.submitFailed=t.submitFailed.bind(t),t.fieldValidators={},t.lastFieldValidatorKeys=[],t.fieldWarners={},t.lastFieldWarnerKeys=[],w++,t}return s(c,n),v(c,[{key:"getChildContext",value:function(){var e=this;return{_reduxForm:m({},this.props,{getFormState:function(t){return r(e.props.getFormState(t),e.props.form)},asyncValidate:this.asyncValidate,getValues:this.getValues,sectionPrefix:void 0,register:this.register,unregister:this.unregister,registerInnerOnSubmit:function(t){return e.innerOnSubmit=t}})}}},{key:"initIfNeeded",value:function(e){var n=this.props.enableReinitialize;if(e){if((n||!e.initialized)&&!t(this.props.initialValues,e.initialValues)){var r=e.initialized&&this.props.keepDirtyOnReinitialize;this.props.initialize(e.initialValues,r)}}else!this.props.initialValues||this.props.initialized&&!n||this.props.initialize(this.props.initialValues,this.props.keepDirtyOnReinitialize)}},{key:"updateSyncErrorsIfNeeded",value:function(e,t){var n=this.props,r=n.error,o=n.syncErrors,i=n.updateSyncErrors,a=!(o&&Object.keys(o).length||r),u=!(e&&Object.keys(e).length||t);a&&u||B.default.deepEqual(o,e)&&B.default.deepEqual(r,t)||i(e,t)}},{key:"submitIfNeeded",value:function(e){var t=this.props,n=t.clearSubmit,r=t.triggerSubmit;!r&&e.triggerSubmit&&(n(),this.submit())}},{key:"validateIfNeeded",value:function(t){var n=this.props,r=n.shouldValidate,o=n.validate,i=n.values,a=this.generateValidator();if(o||a){var u=void 0===t,s=Object.keys(this.fieldValidators),c=r({values:i,nextProps:t,props:this.props,initialRender:u,lastFieldValidatorKeys:this.lastFieldValidatorKeys,fieldValidatorKeys:s,structure:e});if(c){var f=u?this.props:t,d=(0,p.default)(o?o(f.values,f)||{}:{},a?a(f.values,f)||{}:{}),h=d._error,v=l(d,["_error"]);this.lastFieldValidatorKeys=s,this.updateSyncErrorsIfNeeded(v,h)}}}},{key:"updateSyncWarningsIfNeeded",value:function(e,t){var n=this.props,r=n.warning,o=n.syncWarnings,i=n.updateSyncWarnings,a=!(o&&Object.keys(o).length||r),u=!(e&&Object.keys(e).length||t);a&&u||B.default.deepEqual(o,e)&&B.default.deepEqual(r,t)||i(e,t)}},{key:"warnIfNeeded",value:function(t){var n=this.props,r=n.shouldValidate,o=n.warn,i=n.values,a=this.generateWarner();if(o||a){var u=void 0===t,s=Object.keys(this.fieldWarners),c=r({values:i,nextProps:t,props:this.props,initialRender:u,lastFieldValidatorKeys:this.lastFieldWarnerKeys,fieldValidatorKeys:s,structure:e});if(c){var f=u?this.props:t,d=(0,p.default)(o?o(f.values,f):{},a?a(f.values,f):{}),h=d._warning,v=l(d,["_warning"]);this.lastFieldWarnerKeys=s,this.updateSyncWarningsIfNeeded(v,h)}}}},{key:"componentWillMount",value:function(){this.initIfNeeded(),this.validateIfNeeded(),this.warnIfNeeded()}},{key:"componentWillReceiveProps",value:function(e){this.initIfNeeded(e),this.validateIfNeeded(e),this.warnIfNeeded(e),this.submitIfNeeded(e)}},{key:"shouldComponentUpdate",value:function(e){var n=this;return!b.pure||Object.keys(e).some(function(r){return!~ce.indexOf(r)&&!t(n.props[r],e[r])})}},{key:"componentWillUnmount",value:function(){var e=this.props,t=e.destroyOnUnmount,n=e.destroy;t&&(this.destroyed=!0,n()),this.unmounted=!0,w--}},{key:"getValues",value:function(){return this.props.values}},{key:"isValid",value:function(){return this.props.valid}},{key:"isPristine",value:function(){return this.props.pristine}},{key:"register",value:function(e,t,n,r){this.props.registerField(e,t),n&&(this.fieldValidators[e]=n),r&&(this.fieldWarners[e]=r)}},{key:"unregister",value:function(e){!this.props.destroyOnUnmount&&!this.props.forceUnregisterOnUnmount||this.destroyed||this.unmounted&&w||(this.props.unregisterField(e),delete this.fieldValidators[e],delete this.fieldWarners[e])}},{key:"getFieldList",value:function(){return this.props.registeredFields.map(function(e){return r(e,"name")})}},{key:"generateValidator",value:function(){var t=this,n={};return Object.keys(this.fieldValidators).forEach(function(e){var r=t.fieldValidators[e]();r&&(n[e]=r)}),Object.keys(n).length?(0,z.default)(n,e):void 0}},{key:"generateWarner",value:function(){var t=this,n={};return Object.keys(this.fieldWarners).forEach(function(e){var r=t.fieldWarners[e]();r&&(n[e]=r)}),Object.keys(n).length?(0,z.default)(n,e):void 0}},{key:"asyncValidate",value:function e(t,n){var i=this,a=this.props,u=a.asyncBlurFields,s=a.asyncErrors,e=a.asyncValidate,c=a.dispatch,l=a.initialized,f=a.pristine,p=a.shouldAsyncValidate,d=a.startAsyncValidation,h=a.stopAsyncValidation,v=a.syncErrors,m=a.values,g=!t;if(e){var b=function(){var a=g?m:o(m,t,n),y=g||!r(v,t),b=!g&&(!u||~u.indexOf(t.replace(/\[[0-9]+\]/g,"[]")));if((b||g)&&p({asyncErrors:s,initialized:l,trigger:g?"submit":"blur",blurredField:t,pristine:f,syncValidationPasses:y}))return{v:(0,F.default)(function(){return e(a,c,i.props,t)},d,h,t)}}();if("object"===("undefined"==typeof b?"undefined":y(b)))return b.v}}},{key:"submitCompleted",value:function(e){return delete this.submitPromise,e}},{key:"submitFailed",value:function(e){throw delete this.submitPromise,e}},{key:"listenToSubmit",value:function(e){return(0,S.default)(e)?(this.submitPromise=e,e.then(this.submitCompleted,this.submitFailed)):e}},{key:"submit",value:function(e){var t=this,n=this.props.onSubmit;return e&&!(0,M.default)(e)?(0,N.default)(function(){return!t.submitPromise&&t.listenToSubmit((0,A.default)(le(e),t.props,t.props.validExceptSubmit,t.asyncValidate,t.getFieldList()))}):this.submitPromise?void 0:this.innerOnSubmit?this.innerOnSubmit():this.listenToSubmit((0,A.default)(le(n),this.props,this.props.validExceptSubmit,this.asyncValidate,this.getFieldList())); }},{key:"reset",value:function(){this.props.reset()}},{key:"render",value:function(){var e=this.props,t=e.anyTouched,n=(e.arrayInsert,e.arrayMove,e.arrayPop,e.arrayPush,e.arrayRemove,e.arrayRemoveAll,e.arrayShift,e.arraySplice,e.arraySwap,e.arrayUnshift,e.asyncErrors,e.asyncValidate,e.asyncValidating),r=e.blur,o=e.change,a=e.destroy,u=(e.destroyOnUnmount,e.forceUnregisterOnUnmount,e.dirty),s=e.dispatch,c=(e.enableReinitialize,e.error),f=(e.focus,e.form),p=(e.getFormState,e.initialize),h=e.initialized,v=e.initialValues,y=e.invalid,b=(e.keepDirtyOnReinitialize,e.pristine),_=e.propNamespace,x=(e.registeredFields,e.registerField,e.reset),w=(e.setSubmitFailed,e.setSubmitSucceeded,e.shouldAsyncValidate,e.shouldValidate,e.startAsyncValidation,e.startSubmit,e.stopAsyncValidation,e.stopSubmit,e.submitting),S=e.submitFailed,C=e.submitSucceeded,P=e.touch,O=(e.touchOnBlur,e.touchOnChange,e.persistentSubmitErrors,e.syncErrors,e.syncWarnings,e.unregisterField,e.untouch),T=(e.updateSyncErrors,e.updateSyncWarnings,e.valid),k=(e.validExceptSubmit,e.values,e.warning),A=l(e,["anyTouched","arrayInsert","arrayMove","arrayPop","arrayPush","arrayRemove","arrayRemoveAll","arrayShift","arraySplice","arraySwap","arrayUnshift","asyncErrors","asyncValidate","asyncValidating","blur","change","destroy","destroyOnUnmount","forceUnregisterOnUnmount","dirty","dispatch","enableReinitialize","error","focus","form","getFormState","initialize","initialized","initialValues","invalid","keepDirtyOnReinitialize","pristine","propNamespace","registeredFields","registerField","reset","setSubmitFailed","setSubmitSucceeded","shouldAsyncValidate","shouldValidate","startAsyncValidation","startSubmit","stopAsyncValidation","stopSubmit","submitting","submitFailed","submitSucceeded","touch","touchOnBlur","touchOnChange","persistentSubmitErrors","syncErrors","syncWarnings","unregisterField","untouch","updateSyncErrors","updateSyncWarnings","valid","validExceptSubmit","values","warning"]),R=m({anyTouched:t,asyncValidate:this.asyncValidate,asyncValidating:n},(0,E.bindActionCreators)({blur:r,change:o},s),{destroy:a,dirty:u,dispatch:s,error:c,form:f,handleSubmit:this.submit,initialize:p,initialized:h,initialValues:v,invalid:y,pristine:b,reset:x,submitting:w,submitFailed:S,submitSucceeded:C,touch:P,untouch:O,valid:T,warning:k}),M=m({},_?i({},_,R):R,A);return K(d)&&(M.ref="wrapped"),(0,g.createElement)(d,M)}}]),c}(g.Component);C.displayName="Form("+(0,P.default)(d)+")",C.WrappedComponent=d,C.childContextTypes={_reduxForm:g.PropTypes.object.isRequired},C.propTypes={destroyOnUnmount:g.PropTypes.bool,forceUnregisterOnUnmount:g.PropTypes.bool,form:g.PropTypes.string.isRequired,initialValues:g.PropTypes.object,getFormState:g.PropTypes.func,onSubmitFail:g.PropTypes.func,onSubmitSuccess:g.PropTypes.func,propNameSpace:g.PropTypes.string,validate:g.PropTypes.func,warn:g.PropTypes.func,touchOnBlur:g.PropTypes.bool,touchOnChange:g.PropTypes.bool,triggerSubmit:g.PropTypes.bool,persistentSubmitErrors:g.PropTypes.bool,registeredFields:g.PropTypes.any};var O=(0,x.connect)(function(e,o){var i=o.form,a=o.getFormState,u=o.initialValues,s=o.enableReinitialize,c=o.keepDirtyOnReinitialize,l=r(a(e)||n,i)||n,p=r(l,"initial"),d=!!p,h=s&&d&&!t(u,p),v=h&&!c,m=u||p||n;h&&(m=p||n);var y=r(l,"values")||m;v&&(y=m);var g=t(m,y),b=r(l,"asyncErrors"),_=r(l,"syncErrors")||{},x=r(l,"syncWarnings")||{},E=r(l,"registeredFields")||[],w=f(i,a,!1)(e),S=f(i,a,!0)(e),C=!!r(l,"anyTouched"),P=!!r(l,"submitting"),O=!!r(l,"submitFailed"),T=!!r(l,"submitSucceeded"),k=r(l,"error"),A=r(l,"warning"),R=r(l,"triggerSubmit");return{anyTouched:C,asyncErrors:b,asyncValidating:r(l,"asyncValidating")||!1,dirty:!g,error:k,initialized:d,invalid:!w,pristine:g,registeredFields:E,submitting:P,submitFailed:O,submitSucceeded:T,syncErrors:_,syncWarnings:x,triggerSubmit:R,values:y,valid:w,validExceptSubmit:S,warning:A}},function(e,t){var n=function(e){return e.bind(null,t.form)},r=(0,h.default)(ue,n),o=(0,h.default)(se,n),i=function(e,n){return oe(t.form,e,n,!!t.touchOnBlur)},a=function(e,n){return ie(t.form,e,n,!!t.touchOnChange,!!t.persistentSubmitErrors)},u=n(ae),s=(0,E.bindActionCreators)(r,e),c={insert:(0,E.bindActionCreators)(o.arrayInsert,e),move:(0,E.bindActionCreators)(o.arrayMove,e),pop:(0,E.bindActionCreators)(o.arrayPop,e),push:(0,E.bindActionCreators)(o.arrayPush,e),remove:(0,E.bindActionCreators)(o.arrayRemove,e),removeAll:(0,E.bindActionCreators)(o.arrayRemoveAll,e),shift:(0,E.bindActionCreators)(o.arrayShift,e),splice:(0,E.bindActionCreators)(o.arraySplice,e),swap:(0,E.bindActionCreators)(o.arraySwap,e),unshift:(0,E.bindActionCreators)(o.arrayUnshift,e)},l=m({},s,o,{blur:i,change:a,array:c,focus:u,dispatch:e});return function(){return l}},void 0,{withRef:!0}),T=(0,_.default)(O(C),d);return T.defaultProps=b,function(e){function t(){return a(this,t),u(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return s(t,e),v(t,[{key:"submit",value:function(){return this.refs.wrapped.getWrappedInstance().submit()}},{key:"reset",value:function(){return this.refs.wrapped.getWrappedInstance().reset()}},{key:"render",value:function(){var e=this.props,t=e.initialValues,n=l(e,["initialValues"]);return(0,g.createElement)(T,m({},n,{ref:"wrapped",initialValues:c(t)}))}},{key:"valid",get:function(){return this.refs.wrapped.getWrappedInstance().isValid()}},{key:"invalid",get:function(){return!this.valid}},{key:"pristine",get:function(){return this.refs.wrapped.getWrappedInstance().isPristine()}},{key:"dirty",get:function(){return!this.pristine}},{key:"values",get:function(){return this.refs.wrapped.getWrappedInstance().getValues()}},{key:"fieldList",get:function(){return this.refs.wrapped.getWrappedInstance().getFieldList()}},{key:"wrappedInstance",get:function(){return this.refs.wrapped.getWrappedInstance().refs.wrapped}}]),t}(g.Component)}}};t.default=fe},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(e){var t=e.getIn;return function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(e){return t(e,"form")};return function(r){return t(n(r),e+".asyncErrors")}}};t.default=n},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(e){var t=e.getIn;return function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(e){return t(e,"form")};return function(r){return t(n(r),e+".submitErrors")}}};t.default=n},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(e){var t=e.getIn;return function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(e){return t(e,"form")};return function(r){return t(n(r),e+".syncErrors")}}};t.default=n},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(e){var t=e.getIn;return function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(e){return t(e,"form")};return function(r){return t(n(r),e+".values")}}};t.default=n},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(e){var t=e.getIn;return function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(e){return t(e,"form")};return function(r){var o=n(r);return t(o,e+".submitFailed")||!1}}};t.default=n},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(e){var t=e.getIn;return function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(e){return t(e,"form")};return function(r){var o=n(r);return t(o,e+".submitSucceeded")||!1}}};t.default=n},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(269),i=r(o),a=function(e){return function(t,n){var r=(0,i.default)(e)(t,n);return function(e){return!r(e)}}};t.default=a},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(177),i=r(o),a=function(e){return function(t,n){var r=(0,i.default)(e)(t,n);return function(e){return!r(e)}}};t.default=a},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(e){var t=e.getIn;return function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(e){return t(e,"form")};return function(r){var o=n(r);return t(o,e+".submitting")||!1}}};t.default=n},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(570),i=r(o),a=function(e,t){return e===t||(!(null!=e&&""!==e&&e!==!1||null!=t&&""!==t&&t!==!1)||(!e||!t||e._error===t._error)&&((!e||!t||e._warning===t._warning)&&void 0))},u=function(e,t){return(0,i.default)(e,t,a)};t.default=u},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}Object.defineProperty(t,"__esModule",{value:!0});var a=n(104),u=r(a),s=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},c=function e(t,n){for(var r=arguments.length,a=Array(r>2?r-2:0),u=2;u<r;u++)a[u-2]=arguments[u];if(void 0===t||void 0===n)return t;if(a.length){if(Array.isArray(t)){if(n<t.length){var c=e.apply(void 0,[t&&t[n]].concat(a));if(c!==t[n]){var l=[].concat(i(t));return l[n]=c,l}}return t}if(n in t){var f=e.apply(void 0,[t&&t[n]].concat(a));return t[n]===f?t:s({},t,o({},n,f))}return t}if(Array.isArray(t)){if(isNaN(n))throw new Error("Cannot delete non-numerical index from an array");if(n<t.length){var p=[].concat(i(t));return p.splice(n,1),p}return t}if(n in t){var d=s({},t);return delete d[n],d}return t},l=function(e,t){return c.apply(void 0,[e].concat(i((0,u.default)(t))))};t.default=l},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}Object.defineProperty(t,"__esModule",{value:!0});var i=n(104),a=r(i),u=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},s=function e(t,n,r,i){if(i>=r.length)return n;var a=r[i],s=e(t&&t[a],n,r,i+1);if(!t){var c=isNaN(a)?{}:[];return c[a]=s,c}if(Array.isArray(t)){var l=[].concat(t);return l[a]=s,l}return u({},t,o({},a,s))},c=function(e,t,n){return s(e,n,(0,a.default)(t),0)};t.default=c},function(e,t){"use strict";function n(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}Object.defineProperty(t,"__esModule",{value:!0});var r=function(e,t,r,o){if(e=e||[],t<e.length){if(void 0===o&&!r){var i=[].concat(n(e));return i.splice(t,0,null),i[t]=void 0,i}if(null!=o){var a=[].concat(n(e));return a.splice(t,r,o),a}var u=[].concat(n(e));return u.splice(t,r),u}if(r)return e;var s=[].concat(n(e));return s[t]=o,s};t.default=r},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.dataKey="text"},function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=function(e){return e.displayName||e.name||"Component"};t.default=n},function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}Object.defineProperty(t,"__esModule",{value:!0});var o=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},i=n(69),a=function(e){var t=e.getIn;return function(e){var n=o({prop:"values",getFormState:function(e){return t(e,"form")}},e),a=n.form,u=n.prop,s=n.getFormState;return(0,i.connect)(function(e){return r({},u,t(s(e),a+".values"))},function(){return{}})}};t.default=a},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){return function(n,r,o){var a=e(n,r,o),s=a.dispatch,c=[],l={getState:a.getState,dispatch:function(e){return s(e)}};return c=t.map(function(e){return e(l)}),s=u.default.apply(void 0,c)(a.dispatch),i({},a,{dispatch:s})}}}t.__esModule=!0;var i=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e};t.default=o;var a=n(271),u=r(a)},function(e,t){"use strict";function n(e,t){return function(){return t(e.apply(void 0,arguments))}}function r(e,t){if("function"==typeof e)return n(e,t);if("object"!=typeof e||null===e)throw new Error("bindActionCreators expected an object or a function, instead received "+(null===e?"null":typeof e)+'. Did you write "import ActionCreators from" instead of "import * as ActionCreators from"?');for(var r=Object.keys(e),o={},i=0;i<r.length;i++){var a=r[i],u=e[a];"function"==typeof u&&(o[a]=n(u,t))}return o}t.__esModule=!0,t.default=r},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){var n=t&&t.type,r=n&&'"'+n.toString()+'"'||"an action";return"Given action "+r+', reducer "'+e+'" returned undefined. To ignore an action, you must explicitly return the previous state.'}function i(e){Object.keys(e).forEach(function(t){var n=e[t],r=n(void 0,{type:u.ActionTypes.INIT});if("undefined"==typeof r)throw new Error('Reducer "'+t+'" returned undefined during initialization. If the state passed to the reducer is undefined, you must explicitly return the initial state. The initial state may not be undefined.');var o="@@redux/PROBE_UNKNOWN_ACTION_"+Math.random().toString(36).substring(7).split("").join(".");if("undefined"==typeof n(void 0,{type:o}))throw new Error('Reducer "'+t+'" returned undefined when probed with a random type. '+("Don't try to handle "+u.ActionTypes.INIT+' or other actions in "redux/*" ')+"namespace. They are considered private. Instead, you must return the current state for any unknown actions, unless it is undefined, in which case you must return the initial state, regardless of the action type. The initial state may not be undefined.")})}function a(e){for(var t=Object.keys(e),n={},r=0;r<t.length;r++){var a=t[r];"function"==typeof e[a]&&(n[a]=e[a])}var u,s=Object.keys(n);try{i(n)}catch(e){u=e}return function(){var e=arguments.length<=0||void 0===arguments[0]?{}:arguments[0],t=arguments[1];if(u)throw u;for(var r=!1,i={},a=0;a<s.length;a++){var c=s[a],l=n[c],f=e[c],p=l(f,t);if("undefined"==typeof p){var d=o(c,t);throw new Error(d)}i[c]=p,r=r||p!==f}return r?i:e}}t.__esModule=!0,t.default=a;var u=n(272),s=n(102),c=(r(s),n(273));r(c)},function(e,t,n){(function(t,n){!function(t){"use strict";function r(e,t,n,r){var o=t&&t.prototype instanceof i?t:i,a=Object.create(o.prototype),u=new d(r||[]);return a._invoke=l(e,n,u),a}function o(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}function i(){}function a(){}function u(){}function s(e){["next","throw","return"].forEach(function(t){e[t]=function(e){return this._invoke(t,e)}})}function c(e){function t(n,r,i,a){var u=o(e[n],e,r);if("throw"!==u.type){var s=u.arg,c=s.value;return c&&"object"==typeof c&&g.call(c,"__await")?Promise.resolve(c.__await).then(function(e){t("next",e,i,a)},function(e){t("throw",e,i,a)}):Promise.resolve(c).then(function(e){s.value=e,i(s)},a)}a(u.arg)}function r(e,n){function r(){return new Promise(function(r,o){t(e,n,r,o)})}return i=i?i.then(r,r):r()}"object"==typeof n&&n.domain&&(t=n.domain.bind(t));var i;this._invoke=r}function l(e,t,n){var r=S;return function(i,a){if(r===P)throw new Error("Generator is already running");if(r===O){if("throw"===i)throw a;return v()}for(;;){var u=n.delegate;if(u){if("return"===i||"throw"===i&&u.iterator[i]===m){n.delegate=null;var s=u.iterator.return;if(s){var c=o(s,u.iterator,a);if("throw"===c.type){i="throw",a=c.arg;continue}}if("return"===i)continue}var c=o(u.iterator[i],u.iterator,a);if("throw"===c.type){n.delegate=null,i="throw",a=c.arg;continue}i="next",a=m;var l=c.arg;if(!l.done)return r=C,l;n[u.resultName]=l.value,n.next=u.nextLoc,n.delegate=null}if("next"===i)n.sent=n._sent=a;else if("throw"===i){if(r===S)throw r=O,a;n.dispatchException(a)&&(i="next",a=m)}else"return"===i&&n.abrupt("return",a);r=P;var c=o(e,t,n);if("normal"===c.type){r=n.done?O:C;var l={value:c.arg,done:n.done};if(c.arg!==T)return l;n.delegate&&"next"===i&&(a=m)}else"throw"===c.type&&(r=O,i="throw",a=c.arg)}}}function f(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function p(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function d(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(f,this),this.reset(!0)}function h(e){if(e){var t=e[_];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var n=-1,r=function t(){for(;++n<e.length;)if(g.call(e,n))return t.value=e[n],t.done=!1,t;return t.value=m,t.done=!0,t};return r.next=r}}return{next:v}}function v(){return{value:m,done:!0}}var m,y=Object.prototype,g=y.hasOwnProperty,b="function"==typeof Symbol?Symbol:{},_=b.iterator||"@@iterator",x=b.toStringTag||"@@toStringTag",E="object"==typeof e,w=t.regeneratorRuntime;if(w)return void(E&&(e.exports=w));w=t.regeneratorRuntime=E?e.exports:{},w.wrap=r;var S="suspendedStart",C="suspendedYield",P="executing",O="completed",T={},k={};k[_]=function(){return this};var A=Object.getPrototypeOf,R=A&&A(A(h([])));R&&R!==y&&g.call(R,_)&&(k=R);var M=u.prototype=i.prototype=Object.create(k);a.prototype=M.constructor=u,u.constructor=a,u[x]=a.displayName="GeneratorFunction",w.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===a||"GeneratorFunction"===(t.displayName||t.name))},w.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,u):(e.__proto__=u,x in e||(e[x]="GeneratorFunction")),e.prototype=Object.create(M),e},w.awrap=function(e){return{__await:e}},s(c.prototype),w.AsyncIterator=c,w.async=function(e,t,n,o){var i=new c(r(e,t,n,o));return w.isGeneratorFunction(t)?i:i.next().then(function(e){return e.done?e.value:i.next()})},s(M),M[x]="Generator",M.toString=function(){return"[object Generator]"},w.keys=function(e){var t=[];for(var n in e)t.push(n);return t.reverse(),function n(){for(;t.length;){var r=t.pop();if(r in e)return n.value=r,n.done=!1,n}return n.done=!0,n}},w.values=h,d.prototype={constructor:d,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=m,this.done=!1,this.delegate=null,this.tryEntries.forEach(p),!e)for(var t in this)"t"===t.charAt(0)&&g.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=m)},stop:function(){this.done=!0;var e=this.tryEntries[0],t=e.completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){function t(t,r){return i.type="throw",i.arg=e,n.next=t,!!r}if(this.done)throw e;for(var n=this,r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r],i=o.completion;if("root"===o.tryLoc)return t("end");if(o.tryLoc<=this.prev){var a=g.call(o,"catchLoc"),u=g.call(o,"finallyLoc");if(a&&u){if(this.prev<o.catchLoc)return t(o.catchLoc,!0);if(this.prev<o.finallyLoc)return t(o.finallyLoc)}else if(a){if(this.prev<o.catchLoc)return t(o.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return t(o.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&g.call(r,"finallyLoc")&&this.prev<r.finallyLoc){var o=r;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var i=o?o.completion:{};return i.type=e,i.arg=t,o?this.next=o.finallyLoc:this.complete(i),T},complete:function(e,t){if("throw"===e.type)throw e.arg;"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=e.arg,this.next="end"):"normal"===e.type&&t&&(this.next=t)},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),p(n),T}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var o=r.arg;p(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:h(e),resultName:t,nextLoc:n},T}}}("object"==typeof t?t:"object"==typeof window?window:"object"==typeof self?self:this)}).call(t,function(){return this}(),n(157))},function(e,t,n){"use strict";var r=n(479);e.exports=function(e,t,n,o){var i=n?n.call(o,e,t):void 0;if(void 0!==i)return!!i;if(e===t)return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var a=r(e),u=r(t),s=a.length;if(s!==u.length)return!1;o=o||null;for(var c=Object.prototype.hasOwnProperty.bind(t),l=0;l<s;l++){var f=a[l];if(!c(f))return!1;var p=e[f],d=t[f],h=n?n.call(o,p,d,f):void 0;if(h===!1||void 0===h&&p!==d)return!1}return!0}},function(e,t,n){e.exports=n(711)},function(e,t,n){(function(e,r){"use strict";function o(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var i,a=n(712),u=o(a);i="undefined"!=typeof self?self:"undefined"!=typeof window?window:"undefined"!=typeof e?e:r;var s=(0,u.default)(i);t.default=s}).call(t,function(){return this}(),n(113)(e))},function(e,t){"use strict";function n(e){var t,n=e.Symbol;return"function"==typeof n?n.observable?t=n.observable:(t=n("observable"),n.observable=t):t="@@observable",t}Object.defineProperty(t,"__esModule",{value:!0}),t.default=n}]); //# sourceMappingURL=bundle.js.map
packages/generator-fluxible/app/templates/components/Html.js
localnerve/fluxible
import React from 'react'; import ApplicationStore from '../stores/ApplicationStore'; class Html extends React.Component { render() { return ( <html> <head> <meta charSet="utf-8" /> <title>{this.props.context.getStore(ApplicationStore).getPageTitle()}</title> <meta name="viewport" content="width=device-width, user-scalable=no" /> <link rel="stylesheet" href="http://yui.yahooapis.com/pure/0.5.0/pure-min.css" /> </head> <body> <div id="app" dangerouslySetInnerHTML={{__html: this.props.markup}}></div> <script dangerouslySetInnerHTML={{__html: this.props.state}}></script> <script src={'/public/js/' + this.props.clientFile}></script> </body> </html> ); } } export default Html;
ajax/libs/flocks.js/1.5.1/flocks.js
tresni/cdnjs
/** @jsx React.DOM */ /* jshint node: true, browser: true, newcap: false */ /* eslint max-statements: 0, no-else-return: 0, brace-style: 0 */ /* eslint-env node,browser */ /** * The Flocks library module. Load this module and use either the * flocks <tt>flocks.createClass</tt> wrapper or the <tt>flocks plumbing</tt> * mixin to create <tt>flocks controls</tt>. Place them into your document * using <tt>flocks.mount</tt>, and use the returned function or the data and * method that the mixin provides, <tt>this.fctx</tt> and <tt>this.fset()</tt> * respectively, to read and write to the <tt>flocks state</tt>. * * And suddenly you're done. * * Please see the <a href="http://flocks.rocks/what_is_flocks.html" target="_blank">tutorials</a> * for more information. * * @module flocks * @main createClass * @class flocks */ // if it's in a <script> it's defined already // otherwise assume commonjs /* eslint-disable no-use-before-define, vars-on-top */ if (typeof React === "undefined") { var React = require("react"); } /* eslint-enable no-use-before-define, vars-on-top */ // wrap the remainder (function() { "use strict"; var Mixin, exports, initialized = false, updateBlocks = 0, tagtype, /* eslint-disable no-unused-vars */ dirty = false, handler = function(Ignored) { return true; }, /* eslint-ensable no-unused-vars */ finalizer = function() { return true; }, prevFCtx = {}, nextFCtx = {}, flocks2Ctxs = { "flocks2context" : React.PropTypes.object }; // ... lol function arrayMember(Item, Array) { return (!!(~( Array.indexOf(Item, 0) ))); } function isArray(maybeArray) { return (Object.prototype.toString.call(maybeArray) === "[object Array]"); } function isUndefined(maybeUndefined) { return (typeof maybeUndefined === "undefined"); } function isNonArrayObject(maybeArray) { if (typeof maybeArray !== "object") { return false; } if (Object.prototype.toString.call(maybeArray) === "[object Array]") { return false; } return true; } function flocksLog(Level, Message) { if (typeof Level === "string") { if (arrayMember(Level, ["warn","debug","error","log","info","exception","assert"])) { console[Level]("Flocks2 [" + Level + "] " + Message.toString()); } else { console.log("Flocks2 [Unknown level] " + Message.toString()); } } else if (isUndefined(nextFCtx.flocks2Config)) { console.log("Flocks2 pre-config [" + Level.toString() + "] " + Message.toString()); } else if (nextFCtx.flocks2Config.log_level >= Level) { console.log("Flocks2 [" + Level.toString() + "] " + Message.toString()); } } function attemptUpdate() { flocksLog(3, " - Flocks2 attempting update"); dirty = true; if (!(initialized)) { flocksLog(1, " x Flocks2 skipped update: root is not initialized"); return null; } if (updateBlocks) { flocksLog(1, " x Flocks2 skipped update: lock count updateBlocks is non-zero"); return null; } /* todo see issue #9 https://github.com/StoneCypher/flocks.js/issues/9 if (deepCompare(nextFCtx, prevFCtx)) { flocksLog(2, " x Flocks2 skipped update: no update to state"); return true; } */ if (!(handler(nextFCtx))) { flocksLog(0, " ! Flocks2 rolling back update: handler rejected propset"); nextFCtx = prevFCtx; dirty = false; return null; } prevFCtx = nextFCtx; flocksLog(3, " - Flocks2 update passed"); if (prevFCtx.flocks2Config.target === 'detatched') { flocksLog(3, " - Flocks2 skipping render because explicitly detatched"); } else { flocksLog(3, " - Flocks2 rendering"); React.render( React.createFactory(tagtype)( { "flocks2context" : nextFCtx } ), prevFCtx.flocks2Config.target ); } dirty = false; flocksLog(3, " - Flocks2 update complete; finalizing"); finalizer(); return true; } function enforceString(On, Label) { if (typeof On !== "string") { throw Label || "Argument must be a string"; } } function enforceArray(On, Label) { if (!isArray(On)) { throw Label || "Argument must be an array"; } } function enforceNonArrayObject(On, Label) { if (!isNonArrayObject(On)) { throw Label || "Argument must be a non-array object"; } } function setByKey(Key, MaybeValue) { enforceString(Key, "Flocks2 set/2 must take a string for its key"); nextFCtx[Key] = MaybeValue; flocksLog(1, " - Flocks2 setByKey \"" + Key + "\""); attemptUpdate(); } function setTargetByPath(Path, Target, NewVal) { var NextPath, OldVal; // it gets hoisted anyway, so it triggers eslint warnings when inlined // might as well be explicit about it if (!(isArray(Path))) { throw "Path must be an array!"; } if (Path.length === 0) { OldVal = Target; Target = NewVal; return OldVal; } if (Path.length === 1) { OldVal = Target[Path[0]]; Target[Path[0]] = NewVal; return OldVal; } if (["string","number"].indexOf(typeof Path[0]) !== -1) { NextPath = Path.splice(1, Number.MAX_VALUE); return setTargetByPath(NextPath, Target[Path[0]], NewVal); } } function setByPath(Path, NewVal) { enforceArray(Path, "Flocks2 setByPathh/2 must take an array for its key"); flocksLog(1, " - Flocks2 setByPath \"" + Path.join("|") + "\""); setTargetByPath(Path, nextFCtx, NewVal); attemptUpdate(); } // todo // function setByObject(Key, MaybeValue) { // flocksLog(0, " - Flocks2 setByObject stub"); // attemptUpdate(); // } function set(Key, MaybeValue) { flocksLog(3, " - Flocks2 multi-set"); if (typeof Key === "string") { return setByKey(Key, MaybeValue); } else if (isArray(Key)) { return setByPath(Key, MaybeValue); } // else if (isNonArrayObject(Key)) { return setByObject(Key); } // todo else { throw "Flocks2 set/1,2 key must be a string or an array"; } } function getByKey(Key) { return prevFCtx[Key]; } function getByPathImpl(Path, Target) { var NextPath; if (!(isArray(Path))) { throw "path must be an array!"; } if (Path.length === 0) { return Target; } if (Path.length === 1) { return Target[Path[0]]; } if (["string","number"].indexOf(typeof Path[0]) !== -1) { NextPath = Path.splice(1, Number.MAX_VALUE); return getByPathImpl(NextPath, Target[Path[0]]); } } function getByPath(Path) { return getByPathImpl(Path, prevFCtx); } function get(Key) { flocksLog(3, " - Flocks2 multi-get"); if (typeof Key === "string") { return getByKey(Key); } else if (isArray(Key)) { return getByPath(Key); } else { throw "Flocks2 get/1 key must be a string or an array"; } } function update(SparseObject) { // todo console.log("ERROR: stub called!"); enforceNonArrayObject(SparseObject, "Flocks2 update/1 must take a plain object"); } function lock() { ++updateBlocks; } function unlock() { if (updateBlocks <= 0) { throw "unlock()ed with no lock!"; } --updateBlocks; attemptUpdate(); } function clone(obj) { var copy = obj.constructor(), attr; if ((obj === null) || (typeof obj !== "object")) { return obj; } for (attr in obj) { if (obj.hasOwnProperty(attr)) { copy[attr] = obj[attr]; } } return copy; } function create(iFlocksConfig, iFlocksData) { var FlocksConfig = iFlocksConfig || {}, FlocksData = iFlocksData || {}, target = FlocksConfig.target || document.body, stub = function() { console.log("ERROR: stub called!"); attemptUpdate(); }, // todo updater = { "override" : stub, // todo "clear" : stub, // todo "get" : get, "get_key" : getByKey, "get_path" : getByPath, "set" : set, "set_path" : setByPath, "update" : update, "lock" : lock, "unlock" : unlock }; FlocksConfig.log_level = FlocksConfig.log_level || -1; tagtype = FlocksConfig.control; FlocksData.flocks2Config = FlocksConfig; nextFCtx = FlocksData; flocksLog(1, "Flocks2 root creation begins"); if (!(tagtype)) { throw "Flocks2 fatal error: must provide a control in create/2 FlocksConfig"; } if (FlocksConfig.handler) { handler = FlocksConfig.handler; flocksLog(3, " - Flocks2 handler assigned"); } if (FlocksConfig.finalizer) { finalizer = FlocksConfig.finalizer; flocksLog(3, " - Flocks2 finalizer assigned"); } if (FlocksConfig.preventAutoContext) { flocksLog(2, " - Flocks2 skipping auto-context"); } else { flocksLog(2, " - Flocks2 engaging auto-context"); this.fctx = clone(nextFCtx); } flocksLog(3, "Flocks2 creation finished; initializing"); initialized = true; attemptUpdate(); flocksLog(3, "Flocks2 expose updater"); this.fupd = updater; this.fset = updater.set; this.fgetkey = updater.get_key; this.fgetpath = updater.get_path; this.flock = updater.lock; this.funlock = updater.unlock; this.fupdate = updater.update; flocksLog(3, "Flocks2 initialization finished"); return updater; } // because of YUIdoc limitations, the extracted docs for the mixin are far // below. search for the word "yuibama" to jump between these places. Mixin = { "contextTypes" : flocks2Ctxs, "childContextTypes" : flocks2Ctxs, "componentWillMount" : function() { flocksLog(1, " - Flocks2 component will mount: " + this.constructor.displayName); flocksLog(3, isUndefined(this.props.flocks2context)? " - No F2 Context Prop" : " - F2 Context Prop found"); flocksLog(3, isUndefined(this.context.flocks2context)? " - No F2 Context" : " - F2 Context found"); if (this.props.flocks2context) { this.context.flocks2context = this.props.flocks2context; } this.fupdate = function(Obj) { return update(Obj); }; this.fget = function(K) { return get(K); }; this.fgetkey = function(K) { return getByKey(K); }; this.fgetpath = function(P) { return getByPath(P); }; this.fset = function(K,V) { return set(K,V); }; this.fsetpath = function(P,V) { return set(P,V); }; this.flock = function() { return lock(); }; this.funlock = function() { return unlock(); }; this.fctx = this.context.flocks2context; }, "getChildContext" : function() { return this.context; } }; function atLeastFlocks(OriginalList) { var NewList; if (isUndefined(OriginalList)) { return [ Mixin ]; } if (isArray(OriginalList)) { if (arrayMember(Mixin, OriginalList)) { return OriginalList; } else { NewList = clone(OriginalList); NewList.push(Mixin); return NewList; } } throw "Original mixin list must be an array or undefined!"; } function createClass(spec) { spec.mixins = atLeastFlocks(spec.mixins); return React.createClass(spec); } exports = { /** * <tt>version</tt> is an exposed string on the <tt>module export</tt> * which mentions the current library version. This number should * always be in sync with the <tt>package.json</tt> and <tt>bower.json</tt> * version, the <tt>github tag</tt>, the <tt>npm version</tt>, and will * define the paths available on <tt>cdnjs</tt> * * @property version * @type {String} */ "version" : "1.5.0", /** * <tt>createClass</tt> is a wrapper for <tt>react.createClass</tt> which * automatically adds the <tt>plumbing</tt> mixin to your control's spec, * to keep visual noise down. If you prefer, you can add the <tt>plumbing</tt> * mixin manually, in the standard fashion, instead; that may be more * convenient in situations where many mixins are in use, or where other * wrappers of <tt>createClass</tt> are in use. * * @method createClass */ "createClass" : createClass, /** * <tt>mount</tt> accepts a <tt>flocks config</tt> and an initial state, * and then manages a root control for you. <tt>mount</tt> returns to * you a function which you can use from outside the control tree to * update the <tt>flocks state</tt>. From inside the control tree, a * control decorated with the <tt>flocks plumbing</tt> has a member * <tt>this.fctx</tt> which contains an up to date copy of the <tt>flocks * state</tt>, and another member <tt>this.fset()</tt> which you can * use to update the <tt>flocks state</tt>. * * To <tt>mount</tt> a control is to start the process by placing your * top level control into the document through <tt>flocks</tt>. * * @method mount */ "mount" : create, /** * <tt>clone</tt> recursively deep-copies its argument. * * @method clone */ "clone" : clone, /** * <tt>isArray</tt> produces a boolean regarding whether its argument * is a javascript <tt>Array</tt>. * * @method isArray */ "isArray" : isArray, /** * <tt>isUndefined</tt> produces a boolean regarding whether its argument * is the javascript value <tt>undefined</tt>. * * @method isUndefined */ "isUndefined" : isUndefined, /** * <tt>isNonArrayObject</tt> produces a boolean regarding whether its * argument is a javascript <tt>Object</tt>, but also goes to the effort * to exclude javascript <tt>Array</tt>s. * * @method isNonArrayObject */ "isNonArrayObject" : isNonArrayObject, /** * <tt>enforceString</tt> accepts a value argument and an optional * explanation argument, and will throw if the value argument is not of * type <tt>string</tt>. The throw will be the explanation argument, or * a default if the explanation is not present. * * @method enforceString */ "enforceString" : enforceString, /** * <tt>enforceArray</tt> accepts a value argument and an optional * explanation argument, and will throw if the value argument is not of * type <tt>Array</tt>. The throw will be the explanation argument, or * a default if the explanation is not present. * * @method enforceArray */ "enforceArray" : enforceArray, /** * <tt>enforceNonArrayObject</tt> accepts a value argument and an optional * explanation argument, and will throw if the value argument is of * type <tt>Array</tt>, or not of type <tt>Object</tt>. The throw will be * the explanation argument, or a default if the explanation is not present. * * @method enforceNonArrayObject */ "enforceNonArrayObject" : enforceNonArrayObject, /** * <tt>atLeastFlocks</tt> accepts a mixin set from a control spec, or * the value <tt>undefined</tt>, and produces a mixin set in response, * which contains the old mixin set if any, pre-pended with * the <tt>flocks plumbing</tt> mixin, or a mixin set with just that * mixin if the previous mixin set was empty or <tt>undefined</tt>. * If the mixin set provided already contains flocks, it will be * returned unaltered, in case the prior mixin set is order sensitive. * * This is not a method that the end user should expect to use. * * @method atLeastFlocks */ "atLeastFlocks" : atLeastFlocks, /** * <tt>plumbing</tt> is the <tt>flocks</tt> mixin which handles all of * the behind-the-scenes work to make <tt>flocks</tt> function. The * mixin is automatically added by calling <tt>flocks.createClass</tt>, * or you can add it yourself in the standard mixin fashion if you prefer. * * @class plumbing */ // grossest doc structure ever. thanks yuibama. /** * Describes the context types accepted or required by any given React * component; mixin hook notes the need for <tt>flocks2context : object</tt> * as an incoming context to pay attention to. * * @property contextTypes */ /** * Describes the context types provided by the React component; mixin * hook notes that this provides <tt>flocks2context : object</tt> to * subordinate controls. * * @property childContextTypes */ /** * Called when the control is about to mount; mixin hooks this event to * add the flocks context <tt>this.fctx</tt>, the flocks updater * <tt>this.fset</tt>, and other flocks methods to the control object. * * @event componentWillMount */ /** * Called when the control is about to pass context to children; the * plumbing mixin hooks this event to do the simple job of passing the * flocks context data downwards. * * @event getChildContext */ "plumbing" : Mixin }; if (typeof module !== "undefined") { module.exports = exports; } else { window.flocks = exports; } }());
frontend/src/Settings/General/LoggingSettings.js
geogolem/Radarr
import PropTypes from 'prop-types'; import React from 'react'; import FieldSet from 'Components/FieldSet'; import FormGroup from 'Components/Form/FormGroup'; import FormInputGroup from 'Components/Form/FormInputGroup'; import FormLabel from 'Components/Form/FormLabel'; import { inputTypes } from 'Helpers/Props'; import translate from 'Utilities/String/translate'; const logLevelOptions = [ { key: 'info', value: translate('Info') }, { key: 'debug', value: translate('Debug') }, { key: 'trace', value: translate('Trace') } ]; function LoggingSettings(props) { const { settings, onInputChange } = props; const { logLevel } = settings; return ( <FieldSet legend={translate('Logging')}> <FormGroup> <FormLabel>{translate('LogLevel')}</FormLabel> <FormInputGroup type={inputTypes.SELECT} name="logLevel" values={logLevelOptions} helpTextWarning={logLevel.value === 'trace' ? translate('LogLevelTraceHelpTextWarning') : undefined} onChange={onInputChange} {...logLevel} /> </FormGroup> </FieldSet> ); } LoggingSettings.propTypes = { settings: PropTypes.object.isRequired, onInputChange: PropTypes.func.isRequired }; export default LoggingSettings;
ajax/libs/material-ui/4.12.0/internal/svg-icons/ArrowDownward.js
cdnjs/cdnjs
"use strict"; var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault"); var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard"); Object.defineProperty(exports, "__esModule", { value: true }); exports.default = void 0; var React = _interopRequireWildcard(require("react")); var _createSvgIcon = _interopRequireDefault(require("../../utils/createSvgIcon")); /** * @ignore - internal component. */ var _default = (0, _createSvgIcon.default)( /*#__PURE__*/React.createElement("path", { d: "M20 12l-1.41-1.41L13 16.17V4h-2v12.17l-5.58-5.59L4 12l8 8 8-8z" }), 'ArrowDownward'); exports.default = _default;
src/icons/MoveToInboxIcon.js
kiloe/ui
import React from 'react'; import Icon from '../Icon'; export default class MoveToInboxIcon extends Icon { getSVG(){return <svg xmlns="http://www.w3.org/2000/svg" width="48" height="48" viewBox="0 0 48 48"><path d="M38 6H9.98c-2.21 0-3.96 1.79-3.96 4L6 38c0 2.21 1.77 4 3.98 4H38c2.21 0 4-1.79 4-4V10c0-2.21-1.79-4-4-4zm0 24h-8c0 3.31-2.69 6-6 6s-6-2.69-6-6H9.98V10H38v20zm-6-10h-4v-6h-8v6h-4l8 8 8-8z"/></svg>;} };
imports/ui/components/AuthenticatedNavigation.js
themeteorchef/base
import React from 'react'; import { browserHistory } from 'react-router'; import { LinkContainer } from 'react-router-bootstrap'; import { Nav, NavItem, NavDropdown, MenuItem } from 'react-bootstrap'; import { Meteor } from 'meteor/meteor'; const handleLogout = () => Meteor.logout(() => browserHistory.push('/login')); const userName = () => { const user = Meteor.user(); const name = user && user.profile ? user.profile.name : ''; return user ? `${name.first} ${name.last}` : ''; }; const AuthenticatedNavigation = () => ( <div> <Nav> <LinkContainer to="/documents"> <NavItem eventKey={ 2 } href="/documents">Documents</NavItem> </LinkContainer> </Nav> <Nav pullRight> <NavDropdown eventKey={ 3 } title={ userName() } id="basic-nav-dropdown"> <MenuItem eventKey={ 3.1 } onClick={ handleLogout }>Logout</MenuItem> </NavDropdown> </Nav> </div> ); export default AuthenticatedNavigation;
ajax/libs/bla/1.4.0/bla.js
holtkamp/cdnjs
/** * @module vow * @author Filatov Dmitry <[email protected]> * @version 0.4.9 * @license * Dual licensed under the MIT and GPL licenses: * * http://www.opensource.org/licenses/mit-license.php * * http://www.gnu.org/licenses/gpl.html */ (function(global) { var undef, nextTick = (function() { var fns = [], enqueueFn = function(fn) { return fns.push(fn) === 1; }, callFns = function() { var fnsToCall = fns, i = 0, len = fns.length; fns = []; while(i < len) { fnsToCall[i++](); } }; if(typeof setImmediate === 'function') { // ie10, nodejs >= 0.10 return function(fn) { enqueueFn(fn) && setImmediate(callFns); }; } if(typeof process === 'object' && process.nextTick) { // nodejs < 0.10 return function(fn) { enqueueFn(fn) && process.nextTick(callFns); }; } if(global.postMessage) { // modern browsers var isPostMessageAsync = true; if(global.attachEvent) { var checkAsync = function() { isPostMessageAsync = false; }; global.attachEvent('onmessage', checkAsync); global.postMessage('__checkAsync', '*'); global.detachEvent('onmessage', checkAsync); } if(isPostMessageAsync) { var msg = '__promise' + +new Date, onMessage = function(e) { if(e.data === msg) { e.stopPropagation && e.stopPropagation(); callFns(); } }; global.addEventListener? global.addEventListener('message', onMessage, true) : global.attachEvent('onmessage', onMessage); return function(fn) { enqueueFn(fn) && global.postMessage(msg, '*'); }; } } var doc = global.document; if('onreadystatechange' in doc.createElement('script')) { // ie6-ie8 var createScript = function() { var script = doc.createElement('script'); script.onreadystatechange = function() { script.parentNode.removeChild(script); script = script.onreadystatechange = null; callFns(); }; (doc.documentElement || doc.body).appendChild(script); }; return function(fn) { enqueueFn(fn) && createScript(); }; } return function(fn) { // old browsers enqueueFn(fn) && setTimeout(callFns, 0); }; })(), throwException = function(e) { nextTick(function() { throw e; }); }, isFunction = function(obj) { return typeof obj === 'function'; }, isObject = function(obj) { return obj !== null && typeof obj === 'object'; }, toStr = Object.prototype.toString, isArray = Array.isArray || function(obj) { return toStr.call(obj) === '[object Array]'; }, getArrayKeys = function(arr) { var res = [], i = 0, len = arr.length; while(i < len) { res.push(i++); } return res; }, getObjectKeys = Object.keys || function(obj) { var res = []; for(var i in obj) { obj.hasOwnProperty(i) && res.push(i); } return res; }, defineCustomErrorType = function(name) { var res = function(message) { this.name = name; this.message = message; }; res.prototype = new Error(); return res; }, wrapOnFulfilled = function(onFulfilled, idx) { return function(val) { onFulfilled.call(this, val, idx); }; }; /** * @class Deferred * @exports vow:Deferred * @description * The `Deferred` class is used to encapsulate newly-created promise object along with functions that resolve, reject or notify it. */ /** * @constructor * @description * You can use `vow.defer()` instead of using this constructor. * * `new vow.Deferred()` gives the same result as `vow.defer()`. */ var Deferred = function() { this._promise = new Promise(); }; Deferred.prototype = /** @lends Deferred.prototype */{ /** * Returns corresponding promise. * * @returns {vow:Promise} */ promise : function() { return this._promise; }, /** * Resolves corresponding promise with given `value`. * * @param {*} value * * @example * ```js * var defer = vow.defer(), * promise = defer.promise(); * * promise.then(function(value) { * // value is "'success'" here * }); * * defer.resolve('success'); * ``` */ resolve : function(value) { this._promise.isResolved() || this._promise._resolve(value); }, /** * Rejects corresponding promise with given `reason`. * * @param {*} reason * * @example * ```js * var defer = vow.defer(), * promise = defer.promise(); * * promise.fail(function(reason) { * // reason is "'something is wrong'" here * }); * * defer.reject('something is wrong'); * ``` */ reject : function(reason) { if(this._promise.isResolved()) { return; } if(vow.isPromise(reason)) { reason = reason.then(function(val) { var defer = vow.defer(); defer.reject(val); return defer.promise(); }); this._promise._resolve(reason); } else { this._promise._reject(reason); } }, /** * Notifies corresponding promise with given `value`. * * @param {*} value * * @example * ```js * var defer = vow.defer(), * promise = defer.promise(); * * promise.progress(function(value) { * // value is "'20%'", "'40%'" here * }); * * defer.notify('20%'); * defer.notify('40%'); * ``` */ notify : function(value) { this._promise.isResolved() || this._promise._notify(value); } }; var PROMISE_STATUS = { PENDING : 0, RESOLVED : 1, FULFILLED : 2, REJECTED : 3 }; /** * @class Promise * @exports vow:Promise * @description * The `Promise` class is used when you want to give to the caller something to subscribe to, * but not the ability to resolve or reject the deferred. */ /** * @constructor * @param {Function} resolver See https://github.com/domenic/promises-unwrapping/blob/master/README.md#the-promise-constructor for details. * @description * You should use this constructor directly only if you are going to use `vow` as DOM Promises implementation. * In other case you should use `vow.defer()` and `defer.promise()` methods. * @example * ```js * function fetchJSON(url) { * return new vow.Promise(function(resolve, reject, notify) { * var xhr = new XMLHttpRequest(); * xhr.open('GET', url); * xhr.responseType = 'json'; * xhr.send(); * xhr.onload = function() { * if(xhr.response) { * resolve(xhr.response); * } * else { * reject(new TypeError()); * } * }; * }); * } * ``` */ var Promise = function(resolver) { this._value = undef; this._status = PROMISE_STATUS.PENDING; this._fulfilledCallbacks = []; this._rejectedCallbacks = []; this._progressCallbacks = []; if(resolver) { // NOTE: see https://github.com/domenic/promises-unwrapping/blob/master/README.md var _this = this, resolverFnLen = resolver.length; resolver( function(val) { _this.isResolved() || _this._resolve(val); }, resolverFnLen > 1? function(reason) { _this.isResolved() || _this._reject(reason); } : undef, resolverFnLen > 2? function(val) { _this.isResolved() || _this._notify(val); } : undef); } }; Promise.prototype = /** @lends Promise.prototype */ { /** * Returns value of fulfilled promise or reason in case of rejection. * * @returns {*} */ valueOf : function() { return this._value; }, /** * Returns `true` if promise is resolved. * * @returns {Boolean} */ isResolved : function() { return this._status !== PROMISE_STATUS.PENDING; }, /** * Returns `true` if promise is fulfilled. * * @returns {Boolean} */ isFulfilled : function() { return this._status === PROMISE_STATUS.FULFILLED; }, /** * Returns `true` if promise is rejected. * * @returns {Boolean} */ isRejected : function() { return this._status === PROMISE_STATUS.REJECTED; }, /** * Adds reactions to promise. * * @param {Function} [onFulfilled] Callback that will to be invoked with the value after promise has been fulfilled * @param {Function} [onRejected] Callback that will to be invoked with the reason after promise has been rejected * @param {Function} [onProgress] Callback that will to be invoked with the value after promise has been notified * @param {Object} [ctx] Context of callbacks execution * @returns {vow:Promise} A new promise, see https://github.com/promises-aplus/promises-spec for details */ then : function(onFulfilled, onRejected, onProgress, ctx) { var defer = new Deferred(); this._addCallbacks(defer, onFulfilled, onRejected, onProgress, ctx); return defer.promise(); }, /** * Adds rejection reaction only. It is shortcut for `promise.then(undefined, onRejected)`. * * @param {Function} onRejected Callback to be called with the value after promise has been rejected * @param {Object} [ctx] Context of callback execution * @returns {vow:Promise} */ 'catch' : function(onRejected, ctx) { return this.then(undef, onRejected, ctx); }, /** * Adds rejection reaction only. It is shortcut for `promise.then(null, onRejected)`. It's alias for `catch`. * * @param {Function} onRejected Callback to be called with the value after promise has been rejected * @param {Object} [ctx] Context of callback execution * @returns {vow:Promise} */ fail : function(onRejected, ctx) { return this.then(undef, onRejected, ctx); }, /** * Adds resolving reaction (to fulfillment and rejection both). * * @param {Function} onResolved Callback that to be called with the value after promise has been resolved * @param {Object} [ctx] Context of callback execution * @returns {vow:Promise} */ always : function(onResolved, ctx) { var _this = this, cb = function() { return onResolved.call(this, _this); }; return this.then(cb, cb, ctx); }, /** * Adds progress reaction. * * @param {Function} onProgress Callback to be called with the value when promise has been notified * @param {Object} [ctx] Context of callback execution * @returns {vow:Promise} */ progress : function(onProgress, ctx) { return this.then(undef, undef, onProgress, ctx); }, /** * Like `promise.then`, but "spreads" the array into a variadic value handler. * It is useful with `vow.all` and `vow.allResolved` methods. * * @param {Function} [onFulfilled] Callback that will to be invoked with the value after promise has been fulfilled * @param {Function} [onRejected] Callback that will to be invoked with the reason after promise has been rejected * @param {Object} [ctx] Context of callbacks execution * @returns {vow:Promise} * * @example * ```js * var defer1 = vow.defer(), * defer2 = vow.defer(); * * vow.all([defer1.promise(), defer2.promise()]).spread(function(arg1, arg2) { * // arg1 is "1", arg2 is "'two'" here * }); * * defer1.resolve(1); * defer2.resolve('two'); * ``` */ spread : function(onFulfilled, onRejected, ctx) { return this.then( function(val) { return onFulfilled.apply(this, val); }, onRejected, ctx); }, /** * Like `then`, but terminates a chain of promises. * If the promise has been rejected, throws it as an exception in a future turn of the event loop. * * @param {Function} [onFulfilled] Callback that will to be invoked with the value after promise has been fulfilled * @param {Function} [onRejected] Callback that will to be invoked with the reason after promise has been rejected * @param {Function} [onProgress] Callback that will to be invoked with the value after promise has been notified * @param {Object} [ctx] Context of callbacks execution * * @example * ```js * var defer = vow.defer(); * defer.reject(Error('Internal error')); * defer.promise().done(); // exception to be thrown * ``` */ done : function(onFulfilled, onRejected, onProgress, ctx) { this .then(onFulfilled, onRejected, onProgress, ctx) .fail(throwException); }, /** * Returns a new promise that will be fulfilled in `delay` milliseconds if the promise is fulfilled, * or immediately rejected if promise is rejected. * * @param {Number} delay * @returns {vow:Promise} */ delay : function(delay) { var timer, promise = this.then(function(val) { var defer = new Deferred(); timer = setTimeout( function() { defer.resolve(val); }, delay); return defer.promise(); }); promise.always(function() { clearTimeout(timer); }); return promise; }, /** * Returns a new promise that will be rejected in `timeout` milliseconds * if the promise is not resolved beforehand. * * @param {Number} timeout * @returns {vow:Promise} * * @example * ```js * var defer = vow.defer(), * promiseWithTimeout1 = defer.promise().timeout(50), * promiseWithTimeout2 = defer.promise().timeout(200); * * setTimeout( * function() { * defer.resolve('ok'); * }, * 100); * * promiseWithTimeout1.fail(function(reason) { * // promiseWithTimeout to be rejected in 50ms * }); * * promiseWithTimeout2.then(function(value) { * // promiseWithTimeout to be fulfilled with "'ok'" value * }); * ``` */ timeout : function(timeout) { var defer = new Deferred(), timer = setTimeout( function() { defer.reject(new vow.TimedOutError('timed out')); }, timeout); this.then( function(val) { defer.resolve(val); }, function(reason) { defer.reject(reason); }); defer.promise().always(function() { clearTimeout(timer); }); return defer.promise(); }, _vow : true, _resolve : function(val) { if(this._status > PROMISE_STATUS.RESOLVED) { return; } if(val === this) { this._reject(TypeError('Can\'t resolve promise with itself')); return; } this._status = PROMISE_STATUS.RESOLVED; if(val && !!val._vow) { // shortpath for vow.Promise val.isFulfilled()? this._fulfill(val.valueOf()) : val.isRejected()? this._reject(val.valueOf()) : val.then( this._fulfill, this._reject, this._notify, this); return; } if(isObject(val) || isFunction(val)) { var then; try { then = val.then; } catch(e) { this._reject(e); return; } if(isFunction(then)) { var _this = this, isResolved = false; try { then.call( val, function(val) { if(isResolved) { return; } isResolved = true; _this._resolve(val); }, function(err) { if(isResolved) { return; } isResolved = true; _this._reject(err); }, function(val) { _this._notify(val); }); } catch(e) { isResolved || this._reject(e); } return; } } this._fulfill(val); }, _fulfill : function(val) { if(this._status > PROMISE_STATUS.RESOLVED) { return; } this._status = PROMISE_STATUS.FULFILLED; this._value = val; this._callCallbacks(this._fulfilledCallbacks, val); this._fulfilledCallbacks = this._rejectedCallbacks = this._progressCallbacks = undef; }, _reject : function(reason) { if(this._status > PROMISE_STATUS.RESOLVED) { return; } this._status = PROMISE_STATUS.REJECTED; this._value = reason; this._callCallbacks(this._rejectedCallbacks, reason); this._fulfilledCallbacks = this._rejectedCallbacks = this._progressCallbacks = undef; }, _notify : function(val) { this._callCallbacks(this._progressCallbacks, val); }, _addCallbacks : function(defer, onFulfilled, onRejected, onProgress, ctx) { if(onRejected && !isFunction(onRejected)) { ctx = onRejected; onRejected = undef; } else if(onProgress && !isFunction(onProgress)) { ctx = onProgress; onProgress = undef; } var cb; if(!this.isRejected()) { cb = { defer : defer, fn : isFunction(onFulfilled)? onFulfilled : undef, ctx : ctx }; this.isFulfilled()? this._callCallbacks([cb], this._value) : this._fulfilledCallbacks.push(cb); } if(!this.isFulfilled()) { cb = { defer : defer, fn : onRejected, ctx : ctx }; this.isRejected()? this._callCallbacks([cb], this._value) : this._rejectedCallbacks.push(cb); } if(this._status <= PROMISE_STATUS.RESOLVED) { this._progressCallbacks.push({ defer : defer, fn : onProgress, ctx : ctx }); } }, _callCallbacks : function(callbacks, arg) { var len = callbacks.length; if(!len) { return; } var isResolved = this.isResolved(), isFulfilled = this.isFulfilled(); nextTick(function() { var i = 0, cb, defer, fn; while(i < len) { cb = callbacks[i++]; defer = cb.defer; fn = cb.fn; if(fn) { var ctx = cb.ctx, res; try { res = ctx? fn.call(ctx, arg) : fn(arg); } catch(e) { defer.reject(e); continue; } isResolved? defer.resolve(res) : defer.notify(res); } else { isResolved? isFulfilled? defer.resolve(arg) : defer.reject(arg) : defer.notify(arg); } } }); } }; /** @lends Promise */ var staticMethods = { /** * Coerces given `value` to a promise, or returns the `value` if it's already a promise. * * @param {*} value * @returns {vow:Promise} */ cast : function(value) { return vow.cast(value); }, /** * Returns a promise to be fulfilled only after all the items in `iterable` are fulfilled, * or to be rejected when any of the `iterable` is rejected. * * @param {Array|Object} iterable * @returns {vow:Promise} */ all : function(iterable) { return vow.all(iterable); }, /** * Returns a promise to be fulfilled only when any of the items in `iterable` are fulfilled, * or to be rejected when the first item is rejected. * * @param {Array} iterable * @returns {vow:Promise} */ race : function(iterable) { return vow.anyResolved(iterable); }, /** * Returns a promise that has already been resolved with the given `value`. * If `value` is a promise, returned promise will be adopted with the state of given promise. * * @param {*} value * @returns {vow:Promise} */ resolve : function(value) { return vow.resolve(value); }, /** * Returns a promise that has already been rejected with the given `reason`. * * @param {*} reason * @returns {vow:Promise} */ reject : function(reason) { return vow.reject(reason); } }; for(var prop in staticMethods) { staticMethods.hasOwnProperty(prop) && (Promise[prop] = staticMethods[prop]); } var vow = /** @exports vow */ { Deferred : Deferred, Promise : Promise, /** * Creates a new deferred. This method is a factory method for `vow:Deferred` class. * It's equivalent to `new vow.Deferred()`. * * @returns {vow:Deferred} */ defer : function() { return new Deferred(); }, /** * Static equivalent to `promise.then`. * If given `value` is not a promise, then `value` is equivalent to fulfilled promise. * * @param {*} value * @param {Function} [onFulfilled] Callback that will to be invoked with the value after promise has been fulfilled * @param {Function} [onRejected] Callback that will to be invoked with the reason after promise has been rejected * @param {Function} [onProgress] Callback that will to be invoked with the value after promise has been notified * @param {Object} [ctx] Context of callbacks execution * @returns {vow:Promise} */ when : function(value, onFulfilled, onRejected, onProgress, ctx) { return vow.cast(value).then(onFulfilled, onRejected, onProgress, ctx); }, /** * Static equivalent to `promise.fail`. * If given `value` is not a promise, then `value` is equivalent to fulfilled promise. * * @param {*} value * @param {Function} onRejected Callback that will to be invoked with the reason after promise has been rejected * @param {Object} [ctx] Context of callback execution * @returns {vow:Promise} */ fail : function(value, onRejected, ctx) { return vow.when(value, undef, onRejected, ctx); }, /** * Static equivalent to `promise.always`. * If given `value` is not a promise, then `value` is equivalent to fulfilled promise. * * @param {*} value * @param {Function} onResolved Callback that will to be invoked with the reason after promise has been resolved * @param {Object} [ctx] Context of callback execution * @returns {vow:Promise} */ always : function(value, onResolved, ctx) { return vow.when(value).always(onResolved, ctx); }, /** * Static equivalent to `promise.progress`. * If given `value` is not a promise, then `value` is equivalent to fulfilled promise. * * @param {*} value * @param {Function} onProgress Callback that will to be invoked with the reason after promise has been notified * @param {Object} [ctx] Context of callback execution * @returns {vow:Promise} */ progress : function(value, onProgress, ctx) { return vow.when(value).progress(onProgress, ctx); }, /** * Static equivalent to `promise.spread`. * If given `value` is not a promise, then `value` is equivalent to fulfilled promise. * * @param {*} value * @param {Function} [onFulfilled] Callback that will to be invoked with the value after promise has been fulfilled * @param {Function} [onRejected] Callback that will to be invoked with the reason after promise has been rejected * @param {Object} [ctx] Context of callbacks execution * @returns {vow:Promise} */ spread : function(value, onFulfilled, onRejected, ctx) { return vow.when(value).spread(onFulfilled, onRejected, ctx); }, /** * Static equivalent to `promise.done`. * If given `value` is not a promise, then `value` is equivalent to fulfilled promise. * * @param {*} value * @param {Function} [onFulfilled] Callback that will to be invoked with the value after promise has been fulfilled * @param {Function} [onRejected] Callback that will to be invoked with the reason after promise has been rejected * @param {Function} [onProgress] Callback that will to be invoked with the value after promise has been notified * @param {Object} [ctx] Context of callbacks execution */ done : function(value, onFulfilled, onRejected, onProgress, ctx) { vow.when(value).done(onFulfilled, onRejected, onProgress, ctx); }, /** * Checks whether the given `value` is a promise-like object * * @param {*} value * @returns {Boolean} * * @example * ```js * vow.isPromise('something'); // returns false * vow.isPromise(vow.defer().promise()); // returns true * vow.isPromise({ then : function() { }); // returns true * ``` */ isPromise : function(value) { return isObject(value) && isFunction(value.then); }, /** * Coerces given `value` to a promise, or returns the `value` if it's already a promise. * * @param {*} value * @returns {vow:Promise} */ cast : function(value) { return value && !!value._vow? value : vow.resolve(value); }, /** * Static equivalent to `promise.valueOf`. * If given `value` is not an instance of `vow.Promise`, then `value` is equivalent to fulfilled promise. * * @param {*} value * @returns {*} */ valueOf : function(value) { return value && isFunction(value.valueOf)? value.valueOf() : value; }, /** * Static equivalent to `promise.isFulfilled`. * If given `value` is not an instance of `vow.Promise`, then `value` is equivalent to fulfilled promise. * * @param {*} value * @returns {Boolean} */ isFulfilled : function(value) { return value && isFunction(value.isFulfilled)? value.isFulfilled() : true; }, /** * Static equivalent to `promise.isRejected`. * If given `value` is not an instance of `vow.Promise`, then `value` is equivalent to fulfilled promise. * * @param {*} value * @returns {Boolean} */ isRejected : function(value) { return value && isFunction(value.isRejected)? value.isRejected() : false; }, /** * Static equivalent to `promise.isResolved`. * If given `value` is not a promise, then `value` is equivalent to fulfilled promise. * * @param {*} value * @returns {Boolean} */ isResolved : function(value) { return value && isFunction(value.isResolved)? value.isResolved() : true; }, /** * Returns a promise that has already been resolved with the given `value`. * If `value` is a promise, returned promise will be adopted with the state of given promise. * * @param {*} value * @returns {vow:Promise} */ resolve : function(value) { var res = vow.defer(); res.resolve(value); return res.promise(); }, /** * Returns a promise that has already been fulfilled with the given `value`. * If `value` is a promise, returned promise will be fulfilled with fulfill/rejection value of given promise. * * @param {*} value * @returns {vow:Promise} */ fulfill : function(value) { var defer = vow.defer(), promise = defer.promise(); defer.resolve(value); return promise.isFulfilled()? promise : promise.then(null, function(reason) { return reason; }); }, /** * Returns a promise that has already been rejected with the given `reason`. * If `reason` is a promise, returned promise will be rejected with fulfill/rejection value of given promise. * * @param {*} reason * @returns {vow:Promise} */ reject : function(reason) { var defer = vow.defer(); defer.reject(reason); return defer.promise(); }, /** * Invokes a given function `fn` with arguments `args` * * @param {Function} fn * @param {...*} [args] * @returns {vow:Promise} * * @example * ```js * var promise1 = vow.invoke(function(value) { * return value; * }, 'ok'), * promise2 = vow.invoke(function() { * throw Error(); * }); * * promise1.isFulfilled(); // true * promise1.valueOf(); // 'ok' * promise2.isRejected(); // true * promise2.valueOf(); // instance of Error * ``` */ invoke : function(fn, args) { var len = Math.max(arguments.length - 1, 0), callArgs; if(len) { // optimization for V8 callArgs = Array(len); var i = 0; while(i < len) { callArgs[i++] = arguments[i]; } } try { return vow.resolve(callArgs? fn.apply(global, callArgs) : fn.call(global)); } catch(e) { return vow.reject(e); } }, /** * Returns a promise to be fulfilled only after all the items in `iterable` are fulfilled, * or to be rejected when any of the `iterable` is rejected. * * @param {Array|Object} iterable * @returns {vow:Promise} * * @example * with array: * ```js * var defer1 = vow.defer(), * defer2 = vow.defer(); * * vow.all([defer1.promise(), defer2.promise(), 3]) * .then(function(value) { * // value is "[1, 2, 3]" here * }); * * defer1.resolve(1); * defer2.resolve(2); * ``` * * @example * with object: * ```js * var defer1 = vow.defer(), * defer2 = vow.defer(); * * vow.all({ p1 : defer1.promise(), p2 : defer2.promise(), p3 : 3 }) * .then(function(value) { * // value is "{ p1 : 1, p2 : 2, p3 : 3 }" here * }); * * defer1.resolve(1); * defer2.resolve(2); * ``` */ all : function(iterable) { var defer = new Deferred(), isPromisesArray = isArray(iterable), keys = isPromisesArray? getArrayKeys(iterable) : getObjectKeys(iterable), len = keys.length, res = isPromisesArray? [] : {}; if(!len) { defer.resolve(res); return defer.promise(); } var i = len; vow._forEach( iterable, function(value, idx) { res[keys[idx]] = value; if(!--i) { defer.resolve(res); } }, defer.reject, defer.notify, defer, keys); return defer.promise(); }, /** * Returns a promise to be fulfilled only after all the items in `iterable` are resolved. * * @param {Array|Object} iterable * @returns {vow:Promise} * * @example * ```js * var defer1 = vow.defer(), * defer2 = vow.defer(); * * vow.allResolved([defer1.promise(), defer2.promise()]).spread(function(promise1, promise2) { * promise1.isRejected(); // returns true * promise1.valueOf(); // returns "'error'" * promise2.isFulfilled(); // returns true * promise2.valueOf(); // returns "'ok'" * }); * * defer1.reject('error'); * defer2.resolve('ok'); * ``` */ allResolved : function(iterable) { var defer = new Deferred(), isPromisesArray = isArray(iterable), keys = isPromisesArray? getArrayKeys(iterable) : getObjectKeys(iterable), i = keys.length, res = isPromisesArray? [] : {}; if(!i) { defer.resolve(res); return defer.promise(); } var onResolved = function() { --i || defer.resolve(iterable); }; vow._forEach( iterable, onResolved, onResolved, defer.notify, defer, keys); return defer.promise(); }, allPatiently : function(iterable) { return vow.allResolved(iterable).then(function() { var isPromisesArray = isArray(iterable), keys = isPromisesArray? getArrayKeys(iterable) : getObjectKeys(iterable), rejectedPromises, fulfilledPromises, len = keys.length, i = 0, key, promise; if(!len) { return isPromisesArray? [] : {}; } while(i < len) { key = keys[i++]; promise = iterable[key]; if(vow.isRejected(promise)) { rejectedPromises || (rejectedPromises = isPromisesArray? [] : {}); isPromisesArray? rejectedPromises.push(promise.valueOf()) : rejectedPromises[key] = promise.valueOf(); } else if(!rejectedPromises) { (fulfilledPromises || (fulfilledPromises = isPromisesArray? [] : {}))[key] = vow.valueOf(promise); } } if(rejectedPromises) { throw rejectedPromises; } return fulfilledPromises; }); }, /** * Returns a promise to be fulfilled only when any of the items in `iterable` is fulfilled, * or to be rejected when all the items are rejected (with the reason of the first rejected item). * * @param {Array} iterable * @returns {vow:Promise} */ any : function(iterable) { var defer = new Deferred(), len = iterable.length; if(!len) { defer.reject(Error()); return defer.promise(); } var i = 0, reason; vow._forEach( iterable, defer.resolve, function(e) { i || (reason = e); ++i === len && defer.reject(reason); }, defer.notify, defer); return defer.promise(); }, /** * Returns a promise to be fulfilled only when any of the items in `iterable` is fulfilled, * or to be rejected when the first item is rejected. * * @param {Array} iterable * @returns {vow:Promise} */ anyResolved : function(iterable) { var defer = new Deferred(), len = iterable.length; if(!len) { defer.reject(Error()); return defer.promise(); } vow._forEach( iterable, defer.resolve, defer.reject, defer.notify, defer); return defer.promise(); }, /** * Static equivalent to `promise.delay`. * If given `value` is not a promise, then `value` is equivalent to fulfilled promise. * * @param {*} value * @param {Number} delay * @returns {vow:Promise} */ delay : function(value, delay) { return vow.resolve(value).delay(delay); }, /** * Static equivalent to `promise.timeout`. * If given `value` is not a promise, then `value` is equivalent to fulfilled promise. * * @param {*} value * @param {Number} timeout * @returns {vow:Promise} */ timeout : function(value, timeout) { return vow.resolve(value).timeout(timeout); }, _forEach : function(promises, onFulfilled, onRejected, onProgress, ctx, keys) { var len = keys? keys.length : promises.length, i = 0; while(i < len) { vow.when( promises[keys? keys[i] : i], wrapOnFulfilled(onFulfilled, i), onRejected, onProgress, ctx); ++i; } }, TimedOutError : defineCustomErrorType('TimedOut') }; var defineAsGlobal = true; if(typeof module === 'object' && typeof module.exports === 'object') { module.exports = vow; defineAsGlobal = false; } if(typeof modules === 'object' && isFunction(modules.define)) { modules.define('vow', function(provide) { provide(vow); }); defineAsGlobal = false; } if(typeof define === 'function') { define(function(require, exports, module) { module.exports = vow; }); defineAsGlobal = false; } defineAsGlobal && (global.vow = vow); })(this); (function (global) { /** * API error. * * @param {String} type Error type. * @param {String} message Human-readable description of the error. */ function ApiError(type, message) { this.name = 'ApiError'; this.type = type; this.message = message; if (Error.captureStackTrace) { Error.captureStackTrace(this, this.constructor); } } ApiError.prototype = Object.create(Error.prototype, { constructor: { value: ApiError } }); /** * Invalid or missed parameter. */ ApiError.BAD_REQUEST = 'BAD_REQUEST'; /** * Unspecified error or server logic error. */ ApiError.INTERNAL_ERROR = 'INTERNAL_ERROR'; /** * API middleware wasn't found. */ ApiError.NOT_FOUND = 'NOT_FOUND'; var defineAsGlobal = true; /** * @see https://github.com/ymaps/modules */ if (typeof global.modules === 'object') { global.modules.define('bla-error', function (provide) { provide(ApiError); }); defineAsGlobal = false; } /** * @see requirejs.org */ if (typeof global.define === 'function') { global.define('bla-error', function () { return ApiError; }); defineAsGlobal = false; } /** * Common JS. * @see http://wiki.commonjs.org/wiki/Modules/1.1.1 */ if (typeof require === 'function' && typeof module === 'object' && typeof module.exports === 'object') { module.exports = ApiError; defineAsGlobal = false; } if (defineAsGlobal) { global.bla = global.bla || {}; global.bla.ApiError = ApiError; } }(window)); (function (global) { /** * Returns API class based on dependencies. * * @param {Object} vow * @param {Object} ApiError * @returns {Function} */ function createApiClass(vow, ApiError) { /** * Makes an ajax request. * * @param {String} url A string containing the URL to which the request is sent. * @param {String} data Data to be sent to the server. * @returns {vow.Promise} */ function sendAjaxRequest(url, data) { var xhr = new XMLHttpRequest(); var d = vow.defer(); xhr.onreadystatechange = function () { if (xhr.readyState === XMLHttpRequest.DONE) { if (xhr.status === 200) { d.resolve(JSON.parse(xhr.responseText)); } else { d.reject(xhr); } } }; xhr.open('POST', url, true); xhr.setRequestHeader('Accept', 'application/json, text/javascript, */*; q=0.01'); xhr.setRequestHeader('Content-type', 'application/json'); xhr.setRequestHeader('X-Requested-With', 'XMLHttpRequest'); xhr.send(data); return d.promise(); } /* * Set of predefined API errors. */ var XHR_ERRORS = { 404: new ApiError(ApiError.NOT_FOUND, 'API middleware wasn\'t found') }; /** * Api provider. * * @param {String} basePath Url path to the middleware root. * @param {Object} [options] Extra options. * @param {Boolean} [options.enableBatching=true] Enables batching. */ function Api(basePath, options) { this._basePath = basePath; options = options || {}; this._options = { enableBatching: options.hasOwnProperty('enableBatching') ? options.enableBatching : true }; this._batch = []; this._deferreds = {}; } Api.prototype = { constructor: Api, /** * Executes api by path with specified parameters. * * @param {String} methodName Method name. * @param {Object} params Data should be sent to the method. * @param {Object} [execOptions] Exec-specific options. * @param {Boolean} [execOptions.enableBatching=true] Should the current call of the method be batched. * method be batched. * @returns {vow.Promise} */ exec: function (methodName, params, execOptions) { execOptions = execOptions || {}; var enableBatching = execOptions.hasOwnProperty('enableBatching') ? execOptions.enableBatching : this._options.enableBatching; return enableBatching ? this._execWithBatching(methodName, params) : this._execWithoutBatching(methodName, params); }, /** * Executes method immediately. * * @param {String} methodName Method name. * @param {Object} params Data should be sent to the method. * @returns {vow.Promise} */ _execWithoutBatching: function (methodName, params) { var defer = vow.defer(); var url = this._basePath + methodName; var data = JSON.stringify(params); sendAjaxRequest(url, data).then( this._resolvePromise.bind(this, defer), this._rejectPromise.bind(this, defer) ); return defer.promise(); }, /** * Executes method with a little delay, adding it to batch. * * @param {String} methodName Method name. * @param {Object} params Data should be sent to the method. * @returns {vow.Promise} */ _execWithBatching: function (methodName, params) { var requestId = this._getRequestId(methodName, params); var promise = this._getRequestPromise(requestId); if (!promise) { this._addToBatch(methodName, params); promise = this._createPromise(requestId); this._run(); } return promise; }, /** * Generates an ID for a method request. * * @param {String} methodName * @param {Object} params * @returns {String} */ _getRequestId: function (methodName, params) { var stringifiedParams = JSON.stringify(params) || ''; return methodName + stringifiedParams; }, /** * Gets the promise object for given request ID. * * @param {String} requestId Request ID for which promise is retrieved. * @returns {vow.Promise|undefined} */ _getRequestPromise: function (requestId) { var defer = this._deferreds[requestId]; return defer && defer.promise(); }, /** * Appends data to the batch array. * * @param {String} methodName * @param {Object} params */ _addToBatch: function (methodName, params) { this._batch.push({ method: methodName, params: params }); }, /** * Creates new deferred promise. * * @param {String} requestId Request ID for which promise is generated. * @returns {vow.Promise} */ _createPromise: function (requestId) { var defer = vow.defer(); this._deferreds[requestId] = defer; return defer.promise(); }, /** * Initializes async batch request. */ _run: function () { // The collecting requests for the batch will start when a first request is received. // That's why the batch length is checked there. if (this._batch.length === 1) { vow.resolve().then(this._sendBatchRequest, this); } }, /** * Performs batch request. */ _sendBatchRequest: function () { var url = this._basePath + 'batch'; var data = JSON.stringify({methods: this._batch}); sendAjaxRequest(url, data).then( this._resolvePromises.bind(this, this._batch), this._rejectPromises.bind(this, this._batch) ); this._batch = []; }, /** * Resolve deferred promise. * * @param {vow.Deferred} defer * @param {Object} response Server response. */ _resolvePromise: function (defer, response) { var error = response.error; if (error) { defer.reject(new ApiError(error.type, error.message)); } else { defer.resolve(response.data); } }, /** * Resolves deferred promises. * * @param {Object[]} batch Batch request data. * @param {Object} response Server response. */ _resolvePromises: function (batch, response) { var data = response.data; for (var i = 0, requestId; i < batch.length; i++) { requestId = this._getRequestId(batch[i].method, batch[i].params); this._resolvePromise(this._deferreds[requestId], data[i]); delete this._deferreds[requestId]; } }, /** * Rejects deferred promise. * * @param {vow.Deferred} defer * @param {XMLHttpRequest} xhr */ _rejectPromise: function (defer, xhr) { var errorMessage = xhr.message || xhr.statusText || xhr.responseText; var error = XHR_ERRORS[xhr.status] || new ApiError(ApiError.INTERNAL_ERROR, errorMessage); defer.reject(error); }, /** * Rejects deferred promises. * * @param {Object[]} batch Batch request data. * @param {XMLHttpRequest} xhr */ _rejectPromises: function (batch, xhr) { for (var i = 0, requestId; i < batch.length; i++) { requestId = this._getRequestId(batch[i].method, batch[i].params); this._rejectPromise(this._deferreds[requestId], xhr); delete this._deferreds[requestId]; } } }; return Api; } var defineAsGlobal = true; /** * @see https://github.com/ymaps/modules */ if (typeof global.modules === 'object') { global.modules.define('bla', ['vow', 'bla-error'], function (provide, vow, ApiError) { var Api = createApiClass(vow, ApiError); provide(Api); }); defineAsGlobal = false; } /** * @see requirejs.org */ if (typeof global.define === 'function') { global.define('bla', ['bla-error', 'vow'], function (ApiError, vow) { return createApiClass(vow, ApiError); }); defineAsGlobal = false; } /** * Common JS. * @see http://wiki.commonjs.org/wiki/Modules/1.1.1 */ if (typeof require === 'function' && typeof module === 'object' && typeof module.exports === 'object') { var vow = require('vow'); var ApiError = require('../bla-error/bla-error.js'); module.exports = createApiClass(vow, ApiError); defineAsGlobal = false; } if (defineAsGlobal) { global.bla = global.bla || {}; global.bla.Api = createApiClass(global.vow, global.bla.ApiError); } }(window));
src/svg-icons/action/done.js
mtsandeep/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ActionDone = (props) => ( <SvgIcon {...props}> <path d="M9 16.2L4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4L9 16.2z"/> </SvgIcon> ); ActionDone = pure(ActionDone); ActionDone.displayName = 'ActionDone'; ActionDone.muiName = 'SvgIcon'; export default ActionDone;
ajax/libs/zingchart-react/1.0.6/zingchart-react.js
holtkamp/cdnjs
import zingchart from 'zingchart'; import React, { Component } from 'react'; class Core extends Component{ render() { return ( React.createElement("div", {id: this.props.id}) ); } //Called after the render function. componentDidMount(){ zingchart.render({ id : this.props.id, width: (this.props.width || 600), height: (this.props.height || 400), data : this.props.data, theme : (this.props.theme) ? this.props.theme : "light" }); } //Used to check the values being passed in to avoid unnecessary changes. shouldComponentUpdate(nextProps, nextState){ //Lazy object comparison return !(JSON.stringify(nextProps.data) === JSON.stringify(this.props.data)) ; } componentWillUpdate(nextProps){ zingchart.exec(this.props.id, 'setdata', { data : nextProps.data }); } componentWillUnmount(){ zingchart.exec(this.props.id, 'destroy'); } }; class Line extends Component{ render(){ var myConfig = { type: "line", series : this.props.series }; applyAttrs(this.props, myConfig); return (React.createElement(Core, {id: this.props.id, height: this.props.height, width: this.props.width, data: myConfig, theme: this.props.theme})); } }; class Area extends Component{ render(){ var myConfig = { type: "area", series : this.props.series }; applyAttrs(this.props, myConfig); return (React.createElement(Core, {id: this.props.id, height: this.props.height, width: this.props.width, data: myConfig, theme: this.props.theme})); } }; class Bar extends Component{ render(){ var myConfig = { type: "bar", series : this.props.series }; applyAttrs(this.props, myConfig); return (React.createElement(Core, {id: this.props.id, height: this.props.height, width: this.props.width, data: myConfig, theme: this.props.theme})); } }; class Scatter extends Component{ render(){ var myConfig = { type: "scatter", series : this.props.series }; applyAttrs(this.props, myConfig); return (React.createElement(Core, {id: this.props.id, height: this.props.height, width: this.props.width, data: myConfig, theme: this.props.theme})); } }; class Pie extends Component{ render(){ var myConfig = { type: "pie", series : this.props.series }; applyAttrs(this.props, myConfig); return (React.createElement(Core, {id: this.props.id, height: this.props.height, width: this.props.width, data: myConfig, theme: this.props.theme})); } }; function applyAttrs(oProps, oConfig){ if(oProps.legend && oProps.legend.toLowerCase() == "true"){ oConfig.plotarea = oConfig.plotarea || {}; oConfig.plotarea.marginRight = "150px"; oConfig.legend = { maxItems : "4", overflow : "page" }; } if(oProps.title){ oConfig.title = { text : oProps.title } } } export { Core as core, Line as line, Area as area, Bar as bar, Pie as pie, Scatter as scatter };
ajax/libs/yui/3.4.1/loader/loader-debug.js
nesk/cdnjs
YUI.add('loader-base', function(Y) { /** * The YUI loader core * @module loader * @submodule loader-base */ if (!YUI.Env[Y.version]) { (function() { var VERSION = Y.version, BUILD = '/build/', ROOT = VERSION + BUILD, CDN_BASE = Y.Env.base, GALLERY_VERSION = 'gallery-2011.09.14-20-40', TNT = '2in3', TNT_VERSION = '4', YUI2_VERSION = '2.9.0', COMBO_BASE = CDN_BASE + 'combo?', META = { version: VERSION, root: ROOT, base: Y.Env.base, comboBase: COMBO_BASE, skin: { defaultSkin: 'sam', base: 'assets/skins/', path: 'skin.css', after: ['cssreset', 'cssfonts', 'cssgrids', 'cssbase', 'cssreset-context', 'cssfonts-context']}, groups: {}, patterns: {} }, groups = META.groups, yui2Update = function(tnt, yui2) { var root = TNT + '.' + (tnt || TNT_VERSION) + '/' + (yui2 || YUI2_VERSION) + BUILD; groups.yui2.base = CDN_BASE + root; groups.yui2.root = root; }, galleryUpdate = function(tag) { var root = (tag || GALLERY_VERSION) + BUILD; groups.gallery.base = CDN_BASE + root; groups.gallery.root = root; }; groups[VERSION] = {}; groups.gallery = { ext: false, combine: true, comboBase: COMBO_BASE, update: galleryUpdate, patterns: { 'gallery-': { }, 'lang/gallery-': {}, 'gallerycss-': { type: 'css' } } }; groups.yui2 = { combine: true, ext: false, comboBase: COMBO_BASE, update: yui2Update, patterns: { 'yui2-': { configFn: function(me) { if (/-skin|reset|fonts|grids|base/.test(me.name)) { me.type = 'css'; me.path = me.path.replace(/\.js/, '.css'); // this makes skins in builds earlier than // 2.6.0 work as long as combine is false me.path = me.path.replace(/\/yui2-skin/, '/assets/skins/sam/yui2-skin'); } } } } }; galleryUpdate(); yui2Update(); YUI.Env[VERSION] = META; }()); } /** * Loader dynamically loads script and css files. It includes the dependency * info for the version of the library in use, and will automatically pull in * dependencies for the modules requested. It supports rollup files and will * automatically use these when appropriate in order to minimize the number of * http connections required to load all of the dependencies. It can load the * files from the Yahoo! CDN, and it can utilize the combo service provided on * this network to reduce the number of http connections required to download * YUI files. * * @module loader * @main loader * @submodule loader-base */ var NOT_FOUND = {}, NO_REQUIREMENTS = [], MAX_URL_LENGTH = 2048, GLOBAL_ENV = YUI.Env, GLOBAL_LOADED = GLOBAL_ENV._loaded, CSS = 'css', JS = 'js', INTL = 'intl', VERSION = Y.version, ROOT_LANG = '', YObject = Y.Object, oeach = YObject.each, YArray = Y.Array, _queue = GLOBAL_ENV._loaderQueue, META = GLOBAL_ENV[VERSION], SKIN_PREFIX = 'skin-', L = Y.Lang, ON_PAGE = GLOBAL_ENV.mods, modulekey, cache, _path = function(dir, file, type, nomin) { var path = dir + '/' + file; if (!nomin) { path += '-min'; } path += '.' + (type || CSS); return path; }; if (YUI.Env.aliases) { YUI.Env.aliases = {}; //Don't need aliases if Loader is present } /** * The component metadata is stored in Y.Env.meta. * Part of the loader module. * @property meta * @for YUI */ Y.Env.meta = META; /** * Loader dynamically loads script and css files. It includes the dependency * info for the version of the library in use, and will automatically pull in * dependencies for the modules requested. It supports rollup files and will * automatically use these when appropriate in order to minimize the number of * http connections required to load all of the dependencies. It can load the * files from the Yahoo! CDN, and it can utilize the combo service provided on * this network to reduce the number of http connections required to download * YUI files. * * While the loader can be instantiated by the end user, it normally is not. * @see YUI.use for the normal use case. The use function automatically will * pull in missing dependencies. * * @constructor * @class Loader * @param {object} o an optional set of configuration options. Valid options: * <ul> * <li>base: * The base dir</li> * <li>comboBase: * The YUI combo service base dir. Ex: http://yui.yahooapis.com/combo?</li> * <li>root: * The root path to prepend to module names for the combo service. * Ex: 2.5.2/build/</li> * <li>filter:. * * A filter to apply to result urls. This filter will modify the default * path for all modules. The default path for the YUI library is the * minified version of the files (e.g., event-min.js). The filter property * can be a predefined filter or a custom filter. The valid predefined * filters are: * <dl> * <dt>DEBUG</dt> * <dd>Selects the debug versions of the library (e.g., event-debug.js). * This option will automatically include the Logger widget</dd> * <dt>RAW</dt> * <dd>Selects the non-minified version of the library (e.g., event.js). * </dd> * </dl> * You can also define a custom filter, which must be an object literal * containing a search expression and a replace string: * <pre> * myFilter: &#123; * 'searchExp': "-min\\.js", * 'replaceStr': "-debug.js" * &#125; * </pre> * * </li> * <li>filters: per-component filter specification. If specified * for a given component, this overrides the filter config. _Note:_ This does not work on combo urls, use the filter property instead.</li> * <li>combine: * Use the YUI combo service to reduce the number of http connections * required to load your dependencies</li> * <li>ignore: * A list of modules that should never be dynamically loaded</li> * <li>force: * A list of modules that should always be loaded when required, even if * already present on the page</li> * <li>insertBefore: * Node or id for a node that should be used as the insertion point for * new nodes</li> * <li>charset: * charset for dynamic nodes (deprecated, use jsAttributes or cssAttributes) * </li> * <li>jsAttributes: object literal containing attributes to add to script * nodes</li> * <li>cssAttributes: object literal containing attributes to add to link * nodes</li> * <li>timeout: * The number of milliseconds before a timeout occurs when dynamically * loading nodes. If not set, there is no timeout</li> * <li>context: * execution context for all callbacks</li> * <li>onSuccess: * callback for the 'success' event</li> * <li>onFailure: callback for the 'failure' event</li> * <li>onCSS: callback for the 'CSSComplete' event. When loading YUI * components with CSS the CSS is loaded first, then the script. This * provides a moment you can tie into to improve * the presentation of the page while the script is loading.</li> * <li>onTimeout: * callback for the 'timeout' event</li> * <li>onProgress: * callback executed each time a script or css file is loaded</li> * <li>modules: * A list of module definitions. See Loader.addModule for the supported * module metadata</li> * <li>groups: * A list of group definitions. Each group can contain specific definitions * for base, comboBase, combine, and accepts a list of modules. See above * for the description of these properties.</li> * <li>2in3: the version of the YUI 2 in 3 wrapper to use. The intrinsic * support for YUI 2 modules in YUI 3 relies on versions of the YUI 2 * components inside YUI 3 module wrappers. These wrappers * change over time to accomodate the issues that arise from running YUI 2 * in a YUI 3 sandbox.</li> * <li>yui2: when using the 2in3 project, you can select the version of * YUI 2 to use. Valid values * are 2.2.2, 2.3.1, 2.4.1, 2.5.2, 2.6.0, * 2.7.0, 2.8.0, and 2.8.1 [default] -- plus all versions of YUI 2 * going forward.</li> * </ul> */ Y.Loader = function(o) { var defaults = META.modules, self = this; modulekey = META.md5; /** * Internal callback to handle multiple internal insert() calls * so that css is inserted prior to js * @property _internalCallback * @private */ // self._internalCallback = null; /** * Callback that will be executed when the loader is finished * with an insert * @method onSuccess * @type function */ // self.onSuccess = null; /** * Callback that will be executed if there is a failure * @method onFailure * @type function */ // self.onFailure = null; /** * Callback for the 'CSSComplete' event. When loading YUI components * with CSS the CSS is loaded first, then the script. This provides * a moment you can tie into to improve the presentation of the page * while the script is loading. * @method onCSS * @type function */ // self.onCSS = null; /** * Callback executed each time a script or css file is loaded * @method onProgress * @type function */ // self.onProgress = null; /** * Callback that will be executed if a timeout occurs * @method onTimeout * @type function */ // self.onTimeout = null; /** * The execution context for all callbacks * @property context * @default {YUI} the YUI instance */ self.context = Y; /** * Data that is passed to all callbacks * @property data */ // self.data = null; /** * Node reference or id where new nodes should be inserted before * @property insertBefore * @type string|HTMLElement */ // self.insertBefore = null; /** * The charset attribute for inserted nodes * @property charset * @type string * @deprecated , use cssAttributes or jsAttributes. */ // self.charset = null; /** * An object literal containing attributes to add to link nodes * @property cssAttributes * @type object */ // self.cssAttributes = null; /** * An object literal containing attributes to add to script nodes * @property jsAttributes * @type object */ // self.jsAttributes = null; /** * The base directory. * @property base * @type string * @default http://yui.yahooapis.com/[YUI VERSION]/build/ */ self.base = Y.Env.meta.base + Y.Env.meta.root; /** * Base path for the combo service * @property comboBase * @type string * @default http://yui.yahooapis.com/combo? */ self.comboBase = Y.Env.meta.comboBase; /* * Base path for language packs. */ // self.langBase = Y.Env.meta.langBase; // self.lang = ""; /** * If configured, the loader will attempt to use the combo * service for YUI resources and configured external resources. * @property combine * @type boolean * @default true if a base dir isn't in the config */ self.combine = o.base && (o.base.indexOf(self.comboBase.substr(0, 20)) > -1); /** * The default seperator to use between files in a combo URL * @property comboSep * @type {String} * @default Ampersand */ self.comboSep = '&'; /** * Max url length for combo urls. The default is 2048. This is the URL * limit for the Yahoo! hosted combo servers. If consuming * a different combo service that has a different URL limit * it is possible to override this default by supplying * the maxURLLength config option. The config option will * only take effect if lower than the default. * * @property maxURLLength * @type int */ self.maxURLLength = MAX_URL_LENGTH; /** * Ignore modules registered on the YUI global * @property ignoreRegistered * @default false */ // self.ignoreRegistered = false; /** * Root path to prepend to module path for the combo * service * @property root * @type string * @default [YUI VERSION]/build/ */ self.root = Y.Env.meta.root; /** * Timeout value in milliseconds. If set, self value will be used by * the get utility. the timeout event will fire if * a timeout occurs. * @property timeout * @type int */ self.timeout = 0; /** * A list of modules that should not be loaded, even if * they turn up in the dependency tree * @property ignore * @type string[] */ // self.ignore = null; /** * A list of modules that should always be loaded, even * if they have already been inserted into the page. * @property force * @type string[] */ // self.force = null; self.forceMap = {}; /** * Should we allow rollups * @property allowRollup * @type boolean * @default false */ self.allowRollup = false; /** * A filter to apply to result urls. This filter will modify the default * path for all modules. The default path for the YUI library is the * minified version of the files (e.g., event-min.js). The filter property * can be a predefined filter or a custom filter. The valid predefined * filters are: * <dl> * <dt>DEBUG</dt> * <dd>Selects the debug versions of the library (e.g., event-debug.js). * This option will automatically include the Logger widget</dd> * <dt>RAW</dt> * <dd>Selects the non-minified version of the library (e.g., event.js). * </dd> * </dl> * You can also define a custom filter, which must be an object literal * containing a search expression and a replace string: * <pre> * myFilter: &#123; * 'searchExp': "-min\\.js", * 'replaceStr': "-debug.js" * &#125; * </pre> * @property filter * @type string| {searchExp: string, replaceStr: string} */ // self.filter = null; /** * per-component filter specification. If specified for a given * component, this overrides the filter config. * @property filters * @type object */ self.filters = {}; /** * The list of requested modules * @property required * @type {string: boolean} */ self.required = {}; /** * If a module name is predefined when requested, it is checked againsts * the patterns provided in this property. If there is a match, the * module is added with the default configuration. * * At the moment only supporting module prefixes, but anticipate * supporting at least regular expressions. * @property patterns * @type Object */ // self.patterns = Y.merge(Y.Env.meta.patterns); self.patterns = {}; /** * The library metadata * @property moduleInfo */ // self.moduleInfo = Y.merge(Y.Env.meta.moduleInfo); self.moduleInfo = {}; self.groups = Y.merge(Y.Env.meta.groups); /** * Provides the information used to skin the skinnable components. * The following skin definition would result in 'skin1' and 'skin2' * being loaded for calendar (if calendar was requested), and * 'sam' for all other skinnable components: * * <code> * skin: { * * // The default skin, which is automatically applied if not * // overriden by a component-specific skin definition. * // Change this in to apply a different skin globally * defaultSkin: 'sam', * * // This is combined with the loader base property to get * // the default root directory for a skin. ex: * // http://yui.yahooapis.com/2.3.0/build/assets/skins/sam/ * base: 'assets/skins/', * * // Any component-specific overrides can be specified here, * // making it possible to load different skins for different * // components. It is possible to load more than one skin * // for a given component as well. * overrides: { * calendar: ['skin1', 'skin2'] * } * } * </code> * @property skin */ self.skin = Y.merge(Y.Env.meta.skin); /* * Map of conditional modules * @since 3.2.0 */ self.conditions = {}; // map of modules with a hash of modules that meet the requirement // self.provides = {}; self.config = o; self._internal = true; cache = GLOBAL_ENV._renderedMods; if (cache) { oeach(cache, function modCache(v, k) { //self.moduleInfo[k] = Y.merge(v); self.moduleInfo[k] = v; }); cache = GLOBAL_ENV._conditions; oeach(cache, function condCache(v, k) { //self.conditions[k] = Y.merge(v); self.conditions[k] = v; }); } else { oeach(defaults, self.addModule, self); } if (!GLOBAL_ENV._renderedMods) { //GLOBAL_ENV._renderedMods = Y.merge(self.moduleInfo); //GLOBAL_ENV._conditions = Y.merge(self.conditions); GLOBAL_ENV._renderedMods = self.moduleInfo; GLOBAL_ENV._conditions = self.conditions; } self._inspectPage(); self._internal = false; self._config(o); self.testresults = null; if (Y.config.tests) { self.testresults = Y.config.tests; } /** * List of rollup files found in the library metadata * @property rollups */ // self.rollups = null; /** * Whether or not to load optional dependencies for * the requested modules * @property loadOptional * @type boolean * @default false */ // self.loadOptional = false; /** * All of the derived dependencies in sorted order, which * will be populated when either calculate() or insert() * is called * @property sorted * @type string[] */ self.sorted = []; /** * Set when beginning to compute the dependency tree. * Composed of what YUI reports to be loaded combined * with what has been loaded by any instance on the page * with the version number specified in the metadata. * @property loaded * @type {string: boolean} */ self.loaded = GLOBAL_LOADED[VERSION]; /* * A list of modules to attach to the YUI instance when complete. * If not supplied, the sorted list of dependencies are applied. * @property attaching */ // self.attaching = null; /** * Flag to indicate the dependency tree needs to be recomputed * if insert is called again. * @property dirty * @type boolean * @default true */ self.dirty = true; /** * List of modules inserted by the utility * @property inserted * @type {string: boolean} */ self.inserted = {}; /** * List of skipped modules during insert() because the module * was not defined * @property skipped */ self.skipped = {}; // Y.on('yui:load', self.loadNext, self); self.tested = {}; /* * Cached sorted calculate results * @property results * @since 3.2.0 */ //self.results = {}; }; Y.Loader.prototype = { FILTER_DEFS: { RAW: { 'searchExp': '-min\\.js', 'replaceStr': '.js' }, DEBUG: { 'searchExp': '-min\\.js', 'replaceStr': '-debug.js' } }, /* * Check the pages meta-data and cache the result. * @method _inspectPage * @private */ _inspectPage: function() { oeach(ON_PAGE, function(v, k) { if (v.details) { var m = this.moduleInfo[k], req = v.details.requires, mr = m && m.requires; if (m) { if (!m._inspected && req && mr.length != req.length) { // console.log('deleting ' + m.name); // m.requres = YObject.keys(Y.merge(YArray.hash(req), YArray.hash(mr))); delete m.expanded; // delete m.expanded_map; } } else { m = this.addModule(v.details, k); } m._inspected = true; } }, this); }, /* * returns true if b is not loaded, and is required directly or by means of modules it supersedes. * @private * @method _requires * @param {String} mod1 The first module to compare * @param {String} mod2 The second module to compare */ _requires: function(mod1, mod2) { var i, rm, after_map, s, info = this.moduleInfo, m = info[mod1], other = info[mod2]; if (!m || !other) { return false; } rm = m.expanded_map; after_map = m.after_map; // check if this module should be sorted after the other // do this first to short circut circular deps if (after_map && (mod2 in after_map)) { return true; } after_map = other.after_map; // and vis-versa if (after_map && (mod1 in after_map)) { return false; } // check if this module requires one the other supersedes s = info[mod2] && info[mod2].supersedes; if (s) { for (i = 0; i < s.length; i++) { if (this._requires(mod1, s[i])) { return true; } } } s = info[mod1] && info[mod1].supersedes; if (s) { for (i = 0; i < s.length; i++) { if (this._requires(mod2, s[i])) { return false; } } } // check if this module requires the other directly // if (r && YArray.indexOf(r, mod2) > -1) { if (rm && (mod2 in rm)) { return true; } // external css files should be sorted below yui css if (m.ext && m.type == CSS && !other.ext && other.type == CSS) { return true; } return false; }, /** * Apply a new config to the Loader instance * @method _config * @param {Object} o The new configuration */ _config: function(o) { var i, j, val, f, group, groupName, self = this; // apply config values if (o) { for (i in o) { if (o.hasOwnProperty(i)) { val = o[i]; if (i == 'require') { self.require(val); } else if (i == 'skin') { Y.mix(self.skin, o[i], true); } else if (i == 'groups') { for (j in val) { if (val.hasOwnProperty(j)) { // Y.log('group: ' + j); groupName = j; group = val[j]; self.addGroup(group, groupName); } } } else if (i == 'modules') { // add a hash of module definitions oeach(val, self.addModule, self); } else if (i == 'gallery') { this.groups.gallery.update(val); } else if (i == 'yui2' || i == '2in3') { this.groups.yui2.update(o['2in3'], o.yui2); } else if (i == 'maxURLLength') { self[i] = Math.min(MAX_URL_LENGTH, val); } else { self[i] = val; } } } } // fix filter f = self.filter; if (L.isString(f)) { f = f.toUpperCase(); self.filterName = f; self.filter = self.FILTER_DEFS[f]; if (f == 'DEBUG') { self.require('yui-log', 'dump'); } } if (self.lang) { self.require('intl-base', 'intl'); } }, /** * Returns the skin module name for the specified skin name. If a * module name is supplied, the returned skin module name is * specific to the module passed in. * @method formatSkin * @param {string} skin the name of the skin. * @param {string} mod optional: the name of a module to skin. * @return {string} the full skin module name. */ formatSkin: function(skin, mod) { var s = SKIN_PREFIX + skin; if (mod) { s = s + '-' + mod; } return s; }, /** * Adds the skin def to the module info * @method _addSkin * @param {string} skin the name of the skin. * @param {string} mod the name of the module. * @param {string} parent parent module if this is a skin of a * submodule or plugin. * @return {string} the module name for the skin. * @private */ _addSkin: function(skin, mod, parent) { var mdef, pkg, name, nmod, info = this.moduleInfo, sinf = this.skin, ext = info[mod] && info[mod].ext; // Add a module definition for the module-specific skin css if (mod) { name = this.formatSkin(skin, mod); if (!info[name]) { mdef = info[mod]; pkg = mdef.pkg || mod; nmod = { name: name, group: mdef.group, type: 'css', after: sinf.after, path: (parent || pkg) + '/' + sinf.base + skin + '/' + mod + '.css', ext: ext }; if (mdef.base) { nmod.base = mdef.base; } if (mdef.configFn) { nmod.configFn = mdef.configFn; } this.addModule(nmod, name); Y.log('adding skin ' + name + ', ' + parent + ', ' + pkg + ', ' + info[name].path); } } return name; }, /** * Add a new module group * <dl> * <dt>name:</dt> <dd>required, the group name</dd> * <dt>base:</dt> <dd>The base dir for this module group</dd> * <dt>root:</dt> <dd>The root path to add to each combo * resource path</dd> * <dt>combine:</dt> <dd>combo handle</dd> * <dt>comboBase:</dt> <dd>combo service base path</dd> * <dt>modules:</dt> <dd>the group of modules</dd> * </dl> * @method addGroup * @param {object} o An object containing the module data. * @param {string} name the group name. */ addGroup: function(o, name) { var mods = o.modules, self = this; name = name || o.name; o.name = name; self.groups[name] = o; if (o.patterns) { oeach(o.patterns, function(v, k) { v.group = name; self.patterns[k] = v; }); } if (mods) { oeach(mods, function(v, k) { v.group = name; self.addModule(v, k); }, self); } }, /** * Add a new module to the component metadata. * <dl> * <dt>name:</dt> <dd>required, the component name</dd> * <dt>type:</dt> <dd>required, the component type (js or css) * </dd> * <dt>path:</dt> <dd>required, the path to the script from * "base"</dd> * <dt>requires:</dt> <dd>array of modules required by this * component</dd> * <dt>optional:</dt> <dd>array of optional modules for this * component</dd> * <dt>supersedes:</dt> <dd>array of the modules this component * replaces</dd> * <dt>after:</dt> <dd>array of modules the components which, if * present, should be sorted above this one</dd> * <dt>after_map:</dt> <dd>faster alternative to 'after' -- supply * a hash instead of an array</dd> * <dt>rollup:</dt> <dd>the number of superseded modules required * for automatic rollup</dd> * <dt>fullpath:</dt> <dd>If fullpath is specified, this is used * instead of the configured base + path</dd> * <dt>skinnable:</dt> <dd>flag to determine if skin assets should * automatically be pulled in</dd> * <dt>submodules:</dt> <dd>a hash of submodules</dd> * <dt>group:</dt> <dd>The group the module belongs to -- this * is set automatically when it is added as part of a group * configuration.</dd> * <dt>lang:</dt> * <dd>array of BCP 47 language tags of languages for which this * module has localized resource bundles, * e.g., ["en-GB","zh-Hans-CN"]</dd> * <dt>condition:</dt> * <dd>Specifies that the module should be loaded automatically if * a condition is met. This is an object with up to three fields: * [trigger] - the name of a module that can trigger the auto-load * [test] - a function that returns true when the module is to be * loaded. * [when] - specifies the load order of the conditional module * with regard to the position of the trigger module. * This should be one of three values: 'before', 'after', or * 'instead'. The default is 'after'. * </dd> * <dt>testresults:</dt><dd>a hash of test results from Y.Features.all()</dd> * </dl> * @method addModule * @param {object} o An object containing the module data. * @param {string} name the module name (optional), required if not * in the module data. * @return {object} the module definition or null if * the object passed in did not provide all required attributes. */ addModule: function(o, name) { name = name || o.name; //Only merge this data if the temp flag is set //from an earlier pass from a pattern or else //an override module (YUI_config) can not be used to //replace a default module. if (this.moduleInfo[name] && this.moduleInfo[name].temp) { //This catches temp modules loaded via a pattern // The module will be added twice, once from the pattern and // Once from the actual add call, this ensures that properties // that were added to the module the first time around (group: gallery) // are also added the second time around too. o = Y.merge(this.moduleInfo[name], o); } o.name = name; if (!o || !o.name) { return null; } if (!o.type) { o.type = JS; } if (!o.path && !o.fullpath) { o.path = _path(name, name, o.type); } o.supersedes = o.supersedes || o.use; o.ext = ('ext' in o) ? o.ext : (this._internal) ? false : true; o.requires = this.filterRequires(o.requires) || []; // Handle submodule logic var subs = o.submodules, i, l, t, sup, s, smod, plugins, plug, j, langs, packName, supName, flatSup, flatLang, lang, ret, overrides, skinname, when, conditions = this.conditions, trigger; // , existing = this.moduleInfo[name], newr; this.moduleInfo[name] = o; if (!o.langPack && o.lang) { langs = YArray(o.lang); for (j = 0; j < langs.length; j++) { lang = langs[j]; packName = this.getLangPackName(lang, name); smod = this.moduleInfo[packName]; if (!smod) { smod = this._addLangPack(lang, o, packName); } } } if (subs) { sup = o.supersedes || []; l = 0; for (i in subs) { if (subs.hasOwnProperty(i)) { s = subs[i]; s.path = s.path || _path(name, i, o.type); s.pkg = name; s.group = o.group; if (s.supersedes) { sup = sup.concat(s.supersedes); } smod = this.addModule(s, i); sup.push(i); if (smod.skinnable) { o.skinnable = true; overrides = this.skin.overrides; if (overrides && overrides[i]) { for (j = 0; j < overrides[i].length; j++) { skinname = this._addSkin(overrides[i][j], i, name); sup.push(skinname); } } skinname = this._addSkin(this.skin.defaultSkin, i, name); sup.push(skinname); } // looks like we are expected to work out the metadata // for the parent module language packs from what is // specified in the child modules. if (s.lang && s.lang.length) { langs = YArray(s.lang); for (j = 0; j < langs.length; j++) { lang = langs[j]; packName = this.getLangPackName(lang, name); supName = this.getLangPackName(lang, i); smod = this.moduleInfo[packName]; if (!smod) { smod = this._addLangPack(lang, o, packName); } flatSup = flatSup || YArray.hash(smod.supersedes); if (!(supName in flatSup)) { smod.supersedes.push(supName); } o.lang = o.lang || []; flatLang = flatLang || YArray.hash(o.lang); if (!(lang in flatLang)) { o.lang.push(lang); } // Y.log('pack ' + packName + ' should supersede ' + supName); // Add rollup file, need to add to supersedes list too // default packages packName = this.getLangPackName(ROOT_LANG, name); supName = this.getLangPackName(ROOT_LANG, i); smod = this.moduleInfo[packName]; if (!smod) { smod = this._addLangPack(lang, o, packName); } if (!(supName in flatSup)) { smod.supersedes.push(supName); } // Y.log('pack ' + packName + ' should supersede ' + supName); // Add rollup file, need to add to supersedes list too } } l++; } } //o.supersedes = YObject.keys(YArray.hash(sup)); o.supersedes = YArray.dedupe(sup); if (this.allowRollup) { o.rollup = (l < 4) ? l : Math.min(l - 1, 4); } } plugins = o.plugins; if (plugins) { for (i in plugins) { if (plugins.hasOwnProperty(i)) { plug = plugins[i]; plug.pkg = name; plug.path = plug.path || _path(name, i, o.type); plug.requires = plug.requires || []; plug.group = o.group; this.addModule(plug, i); if (o.skinnable) { this._addSkin(this.skin.defaultSkin, i, name); } } } } if (o.condition) { t = o.condition.trigger; if (YUI.Env.aliases[t]) { t = YUI.Env.aliases[t]; } if (!Y.Lang.isArray(t)) { t = [t]; } for (i = 0; i < t.length; i++) { trigger = t[i]; when = o.condition.when; conditions[trigger] = conditions[trigger] || {}; conditions[trigger][name] = o.condition; // the 'when' attribute can be 'before', 'after', or 'instead' // the default is after. if (when && when != 'after') { if (when == 'instead') { // replace the trigger o.supersedes = o.supersedes || []; o.supersedes.push(trigger); } else { // before the trigger // the trigger requires the conditional mod, // so it should appear before the conditional // mod if we do not intersede. } } else { // after the trigger o.after = o.after || []; o.after.push(trigger); } } } if (o.after) { o.after_map = YArray.hash(o.after); } // this.dirty = true; if (o.configFn) { ret = o.configFn(o); if (ret === false) { delete this.moduleInfo[name]; o = null; } } return o; }, /** * Add a requirement for one or more module * @method require * @param {string[] | string*} what the modules to load. */ require: function(what) { var a = (typeof what === 'string') ? YArray(arguments) : what; this.dirty = true; this.required = Y.merge(this.required, YArray.hash(this.filterRequires(a))); this._explodeRollups(); }, /** * Grab all the items that were asked for, check to see if the Loader * meta-data contains a "use" array. If it doesm remove the asked item and replace it with * the content of the "use". * This will make asking for: "dd" * Actually ask for: "dd-ddm-base,dd-ddm,dd-ddm-drop,dd-drag,dd-proxy,dd-constrain,dd-drop,dd-scroll,dd-drop-plugin" * @private * @method _explodeRollups */ _explodeRollups: function() { var self = this, m, r = self.required; if (!self.allowRollup) { oeach(r, function(v, name) { m = self.getModule(name); if (m && m.use) { //delete r[name]; YArray.each(m.use, function(v) { m = self.getModule(v); if (m && m.use) { //delete r[v]; YArray.each(m.use, function(v) { r[v] = true; }); } else { r[v] = true; } }); } }); self.required = r; } }, /** * Explodes the required array to remove aliases and replace them with real modules * @method filterRequires * @param {Array} r The original requires array * @return {Array} The new array of exploded requirements */ filterRequires: function(r) { if (r) { if (!Y.Lang.isArray(r)) { r = [r]; } r = Y.Array(r); var c = [], i, mod, o, m; for (i = 0; i < r.length; i++) { mod = this.getModule(r[i]); if (mod && mod.use) { for (o = 0; o < mod.use.length; o++) { //Must walk the other modules in case a module is a rollup of rollups (datatype) m = this.getModule(mod.use[o]); if (m && m.use) { c = Y.Array.dedupe([].concat(c, this.filterRequires(m.use))); } else { c.push(mod.use[o]); } } } else { c.push(r[i]); } } r = c; } return r; }, /** * Returns an object containing properties for all modules required * in order to load the requested module * @method getRequires * @param {object} mod The module definition from moduleInfo. * @return {array} the expanded requirement list. */ getRequires: function(mod) { if (!mod || mod._parsed) { // Y.log('returning no reqs for ' + mod.name); return NO_REQUIREMENTS; } var i, m, j, add, packName, lang, testresults = this.testresults, name = mod.name, cond, go, adddef = ON_PAGE[name] && ON_PAGE[name].details, d, k, m1, r, old_mod, o, skinmod, skindef, skinpar, skinname, intl = mod.lang || mod.intl, info = this.moduleInfo, ftests = Y.Features && Y.Features.tests.load, hash; // console.log(name); // pattern match leaves module stub that needs to be filled out if (mod.temp && adddef) { old_mod = mod; mod = this.addModule(adddef, name); mod.group = old_mod.group; mod.pkg = old_mod.pkg; delete mod.expanded; } // console.log('cache: ' + mod.langCache + ' == ' + this.lang); // if (mod.expanded && (!mod.langCache || mod.langCache == this.lang)) { if (mod.expanded && (!this.lang || mod.langCache === this.lang)) { //Y.log('Already expanded ' + name + ', ' + mod.expanded); return mod.expanded; } d = []; hash = {}; r = this.filterRequires(mod.requires); if (mod.lang) { //If a module has a lang attribute, auto add the intl requirement. d.unshift('intl'); r.unshift('intl'); intl = true; } o = this.filterRequires(mod.optional); // Y.log("getRequires: " + name + " (dirty:" + this.dirty + // ", expanded:" + mod.expanded + ")"); mod._parsed = true; mod.langCache = this.lang; for (i = 0; i < r.length; i++) { //Y.log(name + ' requiring ' + r[i], 'info', 'loader'); if (!hash[r[i]]) { d.push(r[i]); hash[r[i]] = true; m = this.getModule(r[i]); if (m) { add = this.getRequires(m); intl = intl || (m.expanded_map && (INTL in m.expanded_map)); for (j = 0; j < add.length; j++) { d.push(add[j]); } } } } // get the requirements from superseded modules, if any r = this.filterRequires(mod.supersedes); if (r) { for (i = 0; i < r.length; i++) { if (!hash[r[i]]) { // if this module has submodules, the requirements list is // expanded to include the submodules. This is so we can // prevent dups when a submodule is already loaded and the // parent is requested. if (mod.submodules) { d.push(r[i]); } hash[r[i]] = true; m = this.getModule(r[i]); if (m) { add = this.getRequires(m); intl = intl || (m.expanded_map && (INTL in m.expanded_map)); for (j = 0; j < add.length; j++) { d.push(add[j]); } } } } } if (o && this.loadOptional) { for (i = 0; i < o.length; i++) { if (!hash[o[i]]) { d.push(o[i]); hash[o[i]] = true; m = info[o[i]]; if (m) { add = this.getRequires(m); intl = intl || (m.expanded_map && (INTL in m.expanded_map)); for (j = 0; j < add.length; j++) { d.push(add[j]); } } } } } cond = this.conditions[name]; if (cond) { if (testresults && ftests) { oeach(testresults, function(result, id) { var condmod = ftests[id].name; if (!hash[condmod] && ftests[id].trigger == name) { if (result && ftests[id]) { hash[condmod] = true; d.push(condmod); } } }); } else { oeach(cond, function(def, condmod) { if (!hash[condmod]) { go = def && ((def.ua && Y.UA[def.ua]) || (def.test && def.test(Y, r))); if (go) { hash[condmod] = true; d.push(condmod); m = this.getModule(condmod); // Y.log('conditional', m); if (m) { add = this.getRequires(m); for (j = 0; j < add.length; j++) { d.push(add[j]); } } } } }, this); } } // Create skin modules if (mod.skinnable) { skindef = this.skin.overrides; oeach(YUI.Env.aliases, function(o, n) { if (Y.Array.indexOf(o, name) > -1) { skinpar = n; } }); if (skindef && (skindef[name] || (skinpar && skindef[skinpar]))) { skinname = name; if (skindef[skinpar]) { skinname = skinpar; } for (i = 0; i < skindef[skinname].length; i++) { skinmod = this._addSkin(skindef[skinname][i], name); d.push(skinmod); } } else { skinmod = this._addSkin(this.skin.defaultSkin, name); d.push(skinmod); } } mod._parsed = false; if (intl) { if (mod.lang && !mod.langPack && Y.Intl) { lang = Y.Intl.lookupBestLang(this.lang || ROOT_LANG, mod.lang); //Y.log('Best lang: ' + lang + ', this.lang: ' + this.lang + ', mod.lang: ' + mod.lang); packName = this.getLangPackName(lang, name); if (packName) { d.unshift(packName); } } d.unshift(INTL); } mod.expanded_map = YArray.hash(d); mod.expanded = YObject.keys(mod.expanded_map); return mod.expanded; }, /** * Returns a hash of module names the supplied module satisfies. * @method getProvides * @param {string} name The name of the module. * @return {object} what this module provides. */ getProvides: function(name) { var m = this.getModule(name), o, s; // supmap = this.provides; if (!m) { return NOT_FOUND; } if (m && !m.provides) { o = {}; s = m.supersedes; if (s) { YArray.each(s, function(v) { Y.mix(o, this.getProvides(v)); }, this); } o[name] = true; m.provides = o; } return m.provides; }, /** * Calculates the dependency tree, the result is stored in the sorted * property. * @method calculate * @param {object} o optional options object. * @param {string} type optional argument to prune modules. */ calculate: function(o, type) { if (o || type || this.dirty) { if (o) { this._config(o); } if (!this._init) { this._setup(); } this._explode(); if (this.allowRollup) { this._rollup(); } else { this._explodeRollups(); } this._reduce(); this._sort(); } }, /** * Creates a "psuedo" package for languages provided in the lang array * @method _addLangPack * @param {String} lang The language to create * @param {Object} m The module definition to create the language pack around * @param {String} packName The name of the package (e.g: lang/datatype-date-en-US) * @return {Object} The module definition */ _addLangPack: function(lang, m, packName) { var name = m.name, packPath, existing = this.moduleInfo[packName]; if (!existing) { packPath = _path((m.pkg || name), packName, JS, true); this.addModule({ path: packPath, intl: true, langPack: true, ext: m.ext, group: m.group, supersedes: [] }, packName); if (lang) { Y.Env.lang = Y.Env.lang || {}; Y.Env.lang[lang] = Y.Env.lang[lang] || {}; Y.Env.lang[lang][name] = true; } } return this.moduleInfo[packName]; }, /** * Investigates the current YUI configuration on the page. By default, * modules already detected will not be loaded again unless a force * option is encountered. Called by calculate() * @method _setup * @private */ _setup: function() { var info = this.moduleInfo, name, i, j, m, l, packName; for (name in info) { if (info.hasOwnProperty(name)) { m = info[name]; if (m) { // remove dups //m.requires = YObject.keys(YArray.hash(m.requires)); m.requires = YArray.dedupe(m.requires); // Create lang pack modules if (m.lang && m.lang.length) { // Setup root package if the module has lang defined, // it needs to provide a root language pack packName = this.getLangPackName(ROOT_LANG, name); this._addLangPack(null, m, packName); } } } } //l = Y.merge(this.inserted); l = {}; // available modules if (!this.ignoreRegistered) { Y.mix(l, GLOBAL_ENV.mods); } // add the ignore list to the list of loaded packages if (this.ignore) { Y.mix(l, YArray.hash(this.ignore)); } // expand the list to include superseded modules for (j in l) { if (l.hasOwnProperty(j)) { Y.mix(l, this.getProvides(j)); } } // remove modules on the force list from the loaded list if (this.force) { for (i = 0; i < this.force.length; i++) { if (this.force[i] in l) { delete l[this.force[i]]; } } } Y.mix(this.loaded, l); this._init = true; }, /** * Builds a module name for a language pack * @method getLangPackName * @param {string} lang the language code. * @param {string} mname the module to build it for. * @return {string} the language pack module name. */ getLangPackName: function(lang, mname) { return ('lang/' + mname + ((lang) ? '_' + lang : '')); }, /** * Inspects the required modules list looking for additional * dependencies. Expands the required list to include all * required modules. Called by calculate() * @method _explode * @private */ _explode: function() { var r = this.required, m, reqs, done = {}, self = this; // the setup phase is over, all modules have been created self.dirty = false; self._explodeRollups(); r = self.required; oeach(r, function(v, name) { if (!done[name]) { done[name] = true; m = self.getModule(name); if (m) { var expound = m.expound; if (expound) { r[expound] = self.getModule(expound); reqs = self.getRequires(r[expound]); Y.mix(r, YArray.hash(reqs)); } reqs = self.getRequires(m); Y.mix(r, YArray.hash(reqs)); } } }); // Y.log('After explode: ' + YObject.keys(r)); }, /** * Get's the loader meta data for the requested module * @method getModule * @param {String} mname The module name to get * @return {Object} The module metadata */ getModule: function(mname) { //TODO: Remove name check - it's a quick hack to fix pattern WIP if (!mname) { return null; } var p, found, pname, m = this.moduleInfo[mname], patterns = this.patterns; // check the patterns library to see if we should automatically add // the module with defaults if (!m) { // Y.log('testing patterns ' + YObject.keys(patterns)); for (pname in patterns) { if (patterns.hasOwnProperty(pname)) { // Y.log('testing pattern ' + i); p = patterns[pname]; // use the metadata supplied for the pattern // as the module definition. if (mname.indexOf(pname) > -1) { found = p; break; } } } if (found) { if (p.action) { // Y.log('executing pattern action: ' + pname); p.action.call(this, mname, pname); } else { Y.log('Undefined module: ' + mname + ', matched a pattern: ' + pname, 'info', 'loader'); // ext true or false? m = this.addModule(Y.merge(found), mname); m.temp = true; } } } return m; }, // impl in rollup submodule _rollup: function() { }, /** * Remove superceded modules and loaded modules. Called by * calculate() after we have the mega list of all dependencies * @method _reduce * @return {object} the reduced dependency hash. * @private */ _reduce: function(r) { r = r || this.required; var i, j, s, m, type = this.loadType, ignore = this.ignore ? YArray.hash(this.ignore) : false; for (i in r) { if (r.hasOwnProperty(i)) { m = this.getModule(i); // remove if already loaded if (((this.loaded[i] || ON_PAGE[i]) && !this.forceMap[i] && !this.ignoreRegistered) || (type && m && m.type != type)) { delete r[i]; } if (ignore && ignore[i]) { delete r[i]; } // remove anything this module supersedes s = m && m.supersedes; if (s) { for (j = 0; j < s.length; j++) { if (s[j] in r) { delete r[s[j]]; } } } } } return r; }, /** * Handles the queue when a module has been loaded for all cases * @method _finish * @private * @param {String} msg The message from Loader * @param {Boolean} success A boolean denoting success or failure */ _finish: function(msg, success) { Y.log('loader finishing: ' + msg + ', ' + Y.id + ', ' + this.data, 'info', 'loader'); _queue.running = false; var onEnd = this.onEnd; if (onEnd) { onEnd.call(this.context, { msg: msg, data: this.data, success: success }); } this._continue(); }, /** * The default Loader onSuccess handler, calls this.onSuccess with a payload * @method _onSuccess * @private */ _onSuccess: function() { var self = this, skipped = Y.merge(self.skipped), fn, failed = [], rreg = self.requireRegistration, success, msg; oeach(skipped, function(k) { delete self.inserted[k]; }); self.skipped = {}; oeach(self.inserted, function(v, k) { var mod = self.getModule(k); if (mod && rreg && mod.type == JS && !(k in YUI.Env.mods)) { failed.push(k); } else { Y.mix(self.loaded, self.getProvides(k)); } }); fn = self.onSuccess; msg = (failed.length) ? 'notregistered' : 'success'; success = !(failed.length); if (fn) { fn.call(self.context, { msg: msg, data: self.data, success: success, failed: failed, skipped: skipped }); } self._finish(msg, success); }, /** * The default Loader onFailure handler, calls this.onFailure with a payload * @method _onFailure * @private */ _onFailure: function(o) { Y.log('load error: ' + o.msg + ', ' + Y.id, 'error', 'loader'); var f = this.onFailure, msg = 'failure: ' + o.msg; if (f) { f.call(this.context, { msg: msg, data: this.data, success: false }); } this._finish(msg, false); }, /** * The default Loader onTimeout handler, calls this.onTimeout with a payload * @method _onTimeout * @private */ _onTimeout: function() { Y.log('loader timeout: ' + Y.id, 'error', 'loader'); var f = this.onTimeout; if (f) { f.call(this.context, { msg: 'timeout', data: this.data, success: false }); } this._finish('timeout', false); }, /** * Sorts the dependency tree. The last step of calculate() * @method _sort * @private */ _sort: function() { // create an indexed list var s = YObject.keys(this.required), // loaded = this.loaded, done = {}, p = 0, l, a, b, j, k, moved, doneKey; // keep going until we make a pass without moving anything for (;;) { l = s.length; moved = false; // start the loop after items that are already sorted for (j = p; j < l; j++) { // check the next module on the list to see if its // dependencies have been met a = s[j]; // check everything below current item and move if we // find a requirement for the current item for (k = j + 1; k < l; k++) { doneKey = a + s[k]; if (!done[doneKey] && this._requires(a, s[k])) { // extract the dependency so we can move it up b = s.splice(k, 1); // insert the dependency above the item that // requires it s.splice(j, 0, b[0]); // only swap two dependencies once to short circut // circular dependencies done[doneKey] = true; // keep working moved = true; break; } } // jump out of loop if we moved something if (moved) { break; // this item is sorted, move our pointer and keep going } else { p++; } } // when we make it here and moved is false, we are // finished sorting if (!moved) { break; } } this.sorted = s; }, /** * (Unimplemented) * @method partial * @unimplemented */ partial: function(partial, o, type) { this.sorted = partial; this.insert(o, type, true); }, /** * Handles the actual insertion of script/link tags * @method _insert * @param {Object} source The YUI instance the request came from * @param {Object} o The metadata to include * @param {String} type JS or CSS * @param {Boolean} [skipcalc=false] Do a Loader.calculate on the meta */ _insert: function(source, o, type, skipcalc) { // Y.log('private _insert() ' + (type || '') + ', ' + Y.id, "info", "loader"); // restore the state at the time of the request if (source) { this._config(source); } // build the dependency list // don't include type so we can process CSS and script in // one pass when the type is not specified. if (!skipcalc) { this.calculate(o); } this.loadType = type; if (!type) { var self = this; // Y.log("trying to load css first"); this._internalCallback = function() { var f = self.onCSS, n, p, sib; // IE hack for style overrides that are not being applied if (this.insertBefore && Y.UA.ie) { n = Y.config.doc.getElementById(this.insertBefore); p = n.parentNode; sib = n.nextSibling; p.removeChild(n); if (sib) { p.insertBefore(n, sib); } else { p.appendChild(n); } } if (f) { f.call(self.context, Y); } self._internalCallback = null; self._insert(null, null, JS); }; this._insert(null, null, CSS); return; } // set a flag to indicate the load has started this._loading = true; // flag to indicate we are done with the combo service // and any additional files will need to be loaded // individually this._combineComplete = {}; // start the load this.loadNext(); }, /** * Once a loader operation is completely finished, process any additional queued items. * @method _continue * @private */ _continue: function() { if (!(_queue.running) && _queue.size() > 0) { _queue.running = true; _queue.next()(); } }, /** * inserts the requested modules and their dependencies. * <code>type</code> can be "js" or "css". Both script and * css are inserted if type is not provided. * @method insert * @param {object} o optional options object. * @param {string} type the type of dependency to insert. */ insert: function(o, type, skipsort) { // Y.log('public insert() ' + (type || '') + ', ' + // Y.Object.keys(this.required), "info", "loader"); var self = this, copy = Y.merge(this); delete copy.require; delete copy.dirty; _queue.add(function() { self._insert(copy, o, type, skipsort); }); this._continue(); }, /** * Executed every time a module is loaded, and if we are in a load * cycle, we attempt to load the next script. Public so that it * is possible to call this if using a method other than * Y.register to determine when scripts are fully loaded * @method loadNext * @param {string} mname optional the name of the module that has * been loaded (which is usually why it is time to load the next * one). */ loadNext: function(mname) { // It is possible that this function is executed due to something // else on the page loading a YUI module. Only react when we // are actively loading something if (!this._loading) { return; } var s, len, i, m, url, fn, msg, attr, group, groupName, j, frag, comboSource, comboSources, mods, combining, urls, comboBase, self = this, type = self.loadType, handleSuccess = function(o) { self.loadNext(o.data); }, handleCombo = function(o) { self._combineComplete[type] = true; var i, len = combining.length; for (i = 0; i < len; i++) { self.inserted[combining[i]] = true; } handleSuccess(o); }; if (self.combine && (!self._combineComplete[type])) { combining = []; self._combining = combining; s = self.sorted; len = s.length; // the default combo base comboBase = self.comboBase; url = comboBase; urls = []; comboSources = {}; for (i = 0; i < len; i++) { comboSource = comboBase; m = self.getModule(s[i]); groupName = m && m.group; if (groupName) { group = self.groups[groupName]; if (!group.combine) { m.combine = false; continue; } m.combine = true; if (group.comboBase) { comboSource = group.comboBase; } if ("root" in group && L.isValue(group.root)) { m.root = group.root; } } comboSources[comboSource] = comboSources[comboSource] || []; comboSources[comboSource].push(m); } for (j in comboSources) { if (comboSources.hasOwnProperty(j)) { url = j; mods = comboSources[j]; len = mods.length; for (i = 0; i < len; i++) { // m = self.getModule(s[i]); m = mods[i]; // Do not try to combine non-yui JS unless combo def // is found if (m && (m.type === type) && (m.combine || !m.ext)) { frag = ((L.isValue(m.root)) ? m.root : self.root) + m.path; frag = self._filter(frag, m.name); if ((url !== j) && (i <= (len - 1)) && ((frag.length + url.length) > self.maxURLLength)) { //Hack until this is rewritten to use an array and not string concat: if (url.substr(url.length - 1, 1) === self.comboSep) { url = url.substr(0, (url.length - 1)); } urls.push(self._filter(url)); url = j; } url += frag; if (i < (len - 1)) { url += self.comboSep; } combining.push(m.name); } } if (combining.length && (url != j)) { //Hack until this is rewritten to use an array and not string concat: if (url.substr(url.length - 1, 1) === self.comboSep) { url = url.substr(0, (url.length - 1)); } urls.push(self._filter(url)); } } } if (combining.length) { Y.log('Attempting to use combo: ' + combining, 'info', 'loader'); // if (m.type === CSS) { if (type === CSS) { fn = Y.Get.css; attr = self.cssAttributes; } else { fn = Y.Get.script; attr = self.jsAttributes; } fn(urls, { data: self._loading, onSuccess: handleCombo, onFailure: self._onFailure, onTimeout: self._onTimeout, insertBefore: self.insertBefore, charset: self.charset, attributes: attr, timeout: self.timeout, autopurge: false, context: self }); return; } else { self._combineComplete[type] = true; } } if (mname) { // if the module that was just loaded isn't what we were expecting, // continue to wait if (mname !== self._loading) { return; } // Y.log("loadNext executing, just loaded " + mname + ", " + // Y.id, "info", "loader"); // The global handler that is called when each module is loaded // will pass that module name to this function. Storing this // data to avoid loading the same module multiple times // centralize this in the callback self.inserted[mname] = true; // self.loaded[mname] = true; // provided = self.getProvides(mname); // Y.mix(self.loaded, provided); // Y.mix(self.inserted, provided); if (self.onProgress) { self.onProgress.call(self.context, { name: mname, data: self.data }); } } s = self.sorted; len = s.length; for (i = 0; i < len; i = i + 1) { // this.inserted keeps track of what the loader has loaded. // move on if this item is done. if (s[i] in self.inserted) { continue; } // Because rollups will cause multiple load notifications // from Y, loadNext may be called multiple times for // the same module when loading a rollup. We can safely // skip the subsequent requests if (s[i] === self._loading) { Y.log('still loading ' + s[i] + ', waiting', 'info', 'loader'); return; } // log("inserting " + s[i]); m = self.getModule(s[i]); if (!m) { if (!self.skipped[s[i]]) { msg = 'Undefined module ' + s[i] + ' skipped'; Y.log(msg, 'warn', 'loader'); // self.inserted[s[i]] = true; self.skipped[s[i]] = true; } continue; } group = (m.group && self.groups[m.group]) || NOT_FOUND; // The load type is stored to offer the possibility to load // the css separately from the script. if (!type || type === m.type) { self._loading = s[i]; Y.log('attempting to load ' + s[i] + ', ' + self.base, 'info', 'loader'); if (m.type === CSS) { fn = Y.Get.css; attr = self.cssAttributes; } else { fn = Y.Get.script; attr = self.jsAttributes; } url = (m.fullpath) ? self._filter(m.fullpath, s[i]) : self._url(m.path, s[i], group.base || m.base); fn(url, { data: s[i], onSuccess: handleSuccess, insertBefore: self.insertBefore, charset: self.charset, attributes: attr, onFailure: self._onFailure, onTimeout: self._onTimeout, timeout: self.timeout, autopurge: false, context: self }); return; } } // we are finished self._loading = null; fn = self._internalCallback; // internal callback for loading css first if (fn) { // Y.log('loader internal'); self._internalCallback = null; fn.call(self); } else { // Y.log('loader complete'); self._onSuccess(); } }, /** * Apply filter defined for this instance to a url/path * @method _filter * @param {string} u the string to filter. * @param {string} name the name of the module, if we are processing * a single module as opposed to a combined url. * @return {string} the filtered string. * @private */ _filter: function(u, name) { var f = this.filter, hasFilter = name && (name in this.filters), modFilter = hasFilter && this.filters[name], groupName = this.moduleInfo[name] ? this.moduleInfo[name].group:null; if (groupName && this.groups[groupName].filter) { modFilter = this.groups[groupName].filter; hasFilter = true; }; if (u) { if (hasFilter) { f = (L.isString(modFilter)) ? this.FILTER_DEFS[modFilter.toUpperCase()] || null : modFilter; } if (f) { u = u.replace(new RegExp(f.searchExp, 'g'), f.replaceStr); } } return u; }, /** * Generates the full url for a module * @method _url * @param {string} path the path fragment. * @param {String} name The name of the module * @pamra {String} [base=self.base] The base url to use * @return {string} the full url. * @private */ _url: function(path, name, base) { return this._filter((base || this.base || '') + path, name); }, /** * Returns an Object hash of file arrays built from `loader.sorted` or from an arbitrary list of sorted modules. * @method resolve * @param {Boolean} [calc=false] Perform a loader.calculate() before anything else * @param {Array} [s=loader.sorted] An override for the loader.sorted array * @return {Object} Object hash (js and css) of two arrays of file lists * @example This method can be used as an off-line dep calculator * * var Y = YUI(); * var loader = new Y.Loader({ * filter: 'debug', * base: '../../', * root: 'build/', * combine: true, * require: ['node', 'dd', 'console'] * }); * var out = loader.resolve(true); * */ resolve: function(calc, s) { var self = this, i, m, url, out = { js: [], css: [] }; if (calc) { self.calculate(); } s = s || self.sorted; for (i = 0; i < s.length; i++) { m = self.getModule(s[i]); if (m) { if (self.combine) { url = self._filter((self.root + m.path), m.name, self.root); } else { url = self._filter(m.fullpath, m.name, '') || self._url(m.path, m.name); } out[m.type].push(url); } } if (self.combine) { out.js = [self.comboBase + out.js.join(self.comboSep)]; out.css = [self.comboBase + out.css.join(self.comboSep)]; } return out; }, /** * Returns an Object hash of hashes built from `loader.sorted` or from an arbitrary list of sorted modules. * @method hash * @private * @param {Boolean} [calc=false] Perform a loader.calculate() before anything else * @param {Array} [s=loader.sorted] An override for the loader.sorted array * @return {Object} Object hash (js and css) of two object hashes of file lists, with the module name as the key * @example This method can be used as an off-line dep calculator * * var Y = YUI(); * var loader = new Y.Loader({ * filter: 'debug', * base: '../../', * root: 'build/', * combine: true, * require: ['node', 'dd', 'console'] * }); * var out = loader.hash(true); * */ hash: function(calc, s) { var self = this, i, m, url, out = { js: {}, css: {} }; if (calc) { self.calculate(); } s = s || self.sorted; for (i = 0; i < s.length; i++) { m = self.getModule(s[i]); if (m) { url = self._filter(m.fullpath, m.name, '') || self._url(m.path, m.name); out[m.type][m.name] = url; } } return out; } }; }, '@VERSION@' ,{requires:['get']}); YUI.add('loader-rollup', function(Y) { /** * Optional automatic rollup logic for reducing http connections * when not using a combo service. * @module loader * @submodule rollup */ /** * Look for rollup packages to determine if all of the modules a * rollup supersedes are required. If so, include the rollup to * help reduce the total number of connections required. Called * by calculate(). This is an optional feature, and requires the * appropriate submodule to function. * @method _rollup * @for Loader * @private */ Y.Loader.prototype._rollup = function() { var i, j, m, s, r = this.required, roll, info = this.moduleInfo, rolled, c, smod; // find and cache rollup modules if (this.dirty || !this.rollups) { this.rollups = {}; for (i in info) { if (info.hasOwnProperty(i)) { m = this.getModule(i); // if (m && m.rollup && m.supersedes) { if (m && m.rollup) { this.rollups[i] = m; } } } this.forceMap = (this.force) ? Y.Array.hash(this.force) : {}; } // make as many passes as needed to pick up rollup rollups for (;;) { rolled = false; // go through the rollup candidates for (i in this.rollups) { if (this.rollups.hasOwnProperty(i)) { // there can be only one, unless forced if (!r[i] && ((!this.loaded[i]) || this.forceMap[i])) { m = this.getModule(i); s = m.supersedes || []; roll = false; // @TODO remove continue if (!m.rollup) { continue; } c = 0; // check the threshold for (j = 0; j < s.length; j++) { smod = info[s[j]]; // if the superseded module is loaded, we can't // load the rollup unless it has been forced. if (this.loaded[s[j]] && !this.forceMap[s[j]]) { roll = false; break; // increment the counter if this module is required. // if we are beyond the rollup threshold, we will // use the rollup module } else if (r[s[j]] && m.type == smod.type) { c++; // Y.log("adding to thresh: " + c + ", " + s[j]); roll = (c >= m.rollup); if (roll) { // Y.log("over thresh " + c + ", " + s[j]); break; } } } if (roll) { // Y.log("adding rollup: " + i); // add the rollup r[i] = true; rolled = true; // expand the rollup's dependencies this.getRequires(m); } } } } // if we made it here w/o rolling up something, we are done if (!rolled) { break; } } }; }, '@VERSION@' ,{requires:['loader-base']}); YUI.add('loader-yui3', function(Y) { /* This file is auto-generated by src/loader/scripts/meta_join.py */ /** * YUI 3 module metadata * @module loader * @submodule yui3 */ YUI.Env[Y.version].modules = YUI.Env[Y.version].modules || { "align-plugin": { "requires": [ "node-screen", "node-pluginhost" ] }, "anim": { "use": [ "anim-base", "anim-color", "anim-curve", "anim-easing", "anim-node-plugin", "anim-scroll", "anim-xy" ] }, "anim-base": { "requires": [ "base-base", "node-style" ] }, "anim-color": { "requires": [ "anim-base" ] }, "anim-curve": { "requires": [ "anim-xy" ] }, "anim-easing": { "requires": [ "anim-base" ] }, "anim-node-plugin": { "requires": [ "node-pluginhost", "anim-base" ] }, "anim-scroll": { "requires": [ "anim-base" ] }, "anim-xy": { "requires": [ "anim-base", "node-screen" ] }, "app": { "use": [ "controller", "model", "model-list", "view" ] }, "array-extras": { "requires": [ "yui-base" ] }, "array-invoke": { "requires": [ "yui-base" ] }, "arraylist": { "requires": [ "yui-base" ] }, "arraylist-add": { "requires": [ "arraylist" ] }, "arraylist-filter": { "requires": [ "arraylist" ] }, "arraysort": { "requires": [ "yui-base" ] }, "async-queue": { "requires": [ "event-custom" ] }, "attribute": { "use": [ "attribute-base", "attribute-complex" ] }, "attribute-base": { "requires": [ "event-custom" ] }, "attribute-complex": { "requires": [ "attribute-base" ] }, "autocomplete": { "use": [ "autocomplete-base", "autocomplete-sources", "autocomplete-list", "autocomplete-plugin" ] }, "autocomplete-base": { "optional": [ "autocomplete-sources" ], "requires": [ "array-extras", "base-build", "escape", "event-valuechange", "node-base" ] }, "autocomplete-filters": { "requires": [ "array-extras", "text-wordbreak" ] }, "autocomplete-filters-accentfold": { "requires": [ "array-extras", "text-accentfold", "text-wordbreak" ] }, "autocomplete-highlighters": { "requires": [ "array-extras", "highlight-base" ] }, "autocomplete-highlighters-accentfold": { "requires": [ "array-extras", "highlight-accentfold" ] }, "autocomplete-list": { "after": [ "autocomplete-sources" ], "lang": [ "en" ], "requires": [ "autocomplete-base", "event-resize", "node-screen", "selector-css3", "shim-plugin", "widget", "widget-position", "widget-position-align" ], "skinnable": true }, "autocomplete-list-keys": { "condition": { "name": "autocomplete-list-keys", "test": function (Y) { // Only add keyboard support to autocomplete-list if this doesn't appear to // be an iOS or Android-based mobile device. // // There's currently no feasible way to actually detect whether a device has // a hardware keyboard, so this sniff will have to do. It can easily be // overridden by manually loading the autocomplete-list-keys module. // // Worth noting: even though iOS supports bluetooth keyboards, Mobile Safari // doesn't fire the keyboard events used by AutoCompleteList, so there's // no point loading the -keys module even when a bluetooth keyboard may be // available. return !(Y.UA.ios || Y.UA.android); }, "trigger": "autocomplete-list" }, "requires": [ "autocomplete-list", "base-build" ] }, "autocomplete-plugin": { "requires": [ "autocomplete-list", "node-pluginhost" ] }, "autocomplete-sources": { "optional": [ "io-base", "json-parse", "jsonp", "yql" ], "requires": [ "autocomplete-base" ] }, "base": { "use": [ "base-base", "base-pluginhost", "base-build" ] }, "base-base": { "after": [ "attribute-complex" ], "requires": [ "attribute-base" ] }, "base-build": { "requires": [ "base-base" ] }, "base-pluginhost": { "requires": [ "base-base", "pluginhost" ] }, "cache": { "use": [ "cache-base", "cache-offline", "cache-plugin" ] }, "cache-base": { "requires": [ "base" ] }, "cache-offline": { "requires": [ "cache-base", "json" ] }, "cache-plugin": { "requires": [ "plugin", "cache-base" ] }, "calendar": { "lang": [ "en", "ja", "ru" ], "requires": [ "calendar-base", "calendarnavigator" ], "skinnable": true }, "calendar-base": { "lang": [ "en", "ja", "ru" ], "requires": [ "widget", "substitute", "datatype-date", "datatype-date-math", "cssgrids" ], "skinnable": true }, "calendarnavigator": { "requires": [ "plugin", "classnamemanager", "datatype-date", "node", "substitute" ], "skinnable": true }, "charts": { "requires": [ "dom", "datatype-number", "datatype-date", "event-custom", "event-mouseenter", "widget", "widget-position", "widget-stack", "graphics" ] }, "classnamemanager": { "requires": [ "yui-base" ] }, "clickable-rail": { "requires": [ "slider-base" ] }, "collection": { "use": [ "array-extras", "arraylist", "arraylist-add", "arraylist-filter", "array-invoke" ] }, "console": { "lang": [ "en", "es", "ja" ], "requires": [ "yui-log", "widget", "substitute" ], "skinnable": true }, "console-filters": { "requires": [ "plugin", "console" ], "skinnable": true }, "controller": { "optional": [ "querystring-parse" ], "requires": [ "array-extras", "base-build", "history" ] }, "cookie": { "requires": [ "yui-base" ] }, "createlink-base": { "requires": [ "editor-base" ] }, "cssbase": { "after": [ "cssreset", "cssfonts", "cssgrids", "cssreset-context", "cssfonts-context", "cssgrids-context" ], "type": "css" }, "cssbase-context": { "after": [ "cssreset", "cssfonts", "cssgrids", "cssreset-context", "cssfonts-context", "cssgrids-context" ], "type": "css" }, "cssfonts": { "type": "css" }, "cssfonts-context": { "type": "css" }, "cssgrids": { "optional": [ "cssreset", "cssfonts" ], "type": "css" }, "cssreset": { "type": "css" }, "cssreset-context": { "type": "css" }, "dataschema": { "use": [ "dataschema-base", "dataschema-json", "dataschema-xml", "dataschema-array", "dataschema-text" ] }, "dataschema-array": { "requires": [ "dataschema-base" ] }, "dataschema-base": { "requires": [ "base" ] }, "dataschema-json": { "requires": [ "dataschema-base", "json" ] }, "dataschema-text": { "requires": [ "dataschema-base" ] }, "dataschema-xml": { "requires": [ "dataschema-base" ] }, "datasource": { "use": [ "datasource-local", "datasource-io", "datasource-get", "datasource-function", "datasource-cache", "datasource-jsonschema", "datasource-xmlschema", "datasource-arrayschema", "datasource-textschema", "datasource-polling" ] }, "datasource-arrayschema": { "requires": [ "datasource-local", "plugin", "dataschema-array" ] }, "datasource-cache": { "requires": [ "datasource-local", "plugin", "cache-base" ] }, "datasource-function": { "requires": [ "datasource-local" ] }, "datasource-get": { "requires": [ "datasource-local", "get" ] }, "datasource-io": { "requires": [ "datasource-local", "io-base" ] }, "datasource-jsonschema": { "requires": [ "datasource-local", "plugin", "dataschema-json" ] }, "datasource-local": { "requires": [ "base" ] }, "datasource-polling": { "requires": [ "datasource-local" ] }, "datasource-textschema": { "requires": [ "datasource-local", "plugin", "dataschema-text" ] }, "datasource-xmlschema": { "requires": [ "datasource-local", "plugin", "dataschema-xml" ] }, "datatable": { "use": [ "datatable-base", "datatable-datasource", "datatable-sort", "datatable-scroll" ] }, "datatable-base": { "requires": [ "recordset-base", "widget", "substitute", "event-mouseenter" ], "skinnable": true }, "datatable-datasource": { "requires": [ "datatable-base", "plugin", "datasource-local" ] }, "datatable-scroll": { "requires": [ "datatable-base", "plugin" ] }, "datatable-sort": { "lang": [ "en" ], "requires": [ "datatable-base", "plugin", "recordset-sort" ] }, "datatype": { "use": [ "datatype-number", "datatype-date", "datatype-xml" ] }, "datatype-date": { "supersedes": [ "datatype-date-format" ], "use": [ "datatype-date-parse", "datatype-date-format" ] }, "datatype-date-format": { "lang": [ "ar", "ar-JO", "ca", "ca-ES", "da", "da-DK", "de", "de-AT", "de-DE", "el", "el-GR", "en", "en-AU", "en-CA", "en-GB", "en-IE", "en-IN", "en-JO", "en-MY", "en-NZ", "en-PH", "en-SG", "en-US", "es", "es-AR", "es-BO", "es-CL", "es-CO", "es-EC", "es-ES", "es-MX", "es-PE", "es-PY", "es-US", "es-UY", "es-VE", "fi", "fi-FI", "fr", "fr-BE", "fr-CA", "fr-FR", "hi", "hi-IN", "id", "id-ID", "it", "it-IT", "ja", "ja-JP", "ko", "ko-KR", "ms", "ms-MY", "nb", "nb-NO", "nl", "nl-BE", "nl-NL", "pl", "pl-PL", "pt", "pt-BR", "ro", "ro-RO", "ru", "ru-RU", "sv", "sv-SE", "th", "th-TH", "tr", "tr-TR", "vi", "vi-VN", "zh-Hans", "zh-Hans-CN", "zh-Hant", "zh-Hant-HK", "zh-Hant-TW" ] }, "datatype-date-math": { "requires": [ "yui-base" ] }, "datatype-date-parse": {}, "datatype-number": { "use": [ "datatype-number-parse", "datatype-number-format" ] }, "datatype-number-format": {}, "datatype-number-parse": {}, "datatype-xml": { "use": [ "datatype-xml-parse", "datatype-xml-format" ] }, "datatype-xml-format": {}, "datatype-xml-parse": {}, "dd": { "use": [ "dd-ddm-base", "dd-ddm", "dd-ddm-drop", "dd-drag", "dd-proxy", "dd-constrain", "dd-drop", "dd-scroll", "dd-delegate" ] }, "dd-constrain": { "requires": [ "dd-drag" ] }, "dd-ddm": { "requires": [ "dd-ddm-base", "event-resize" ] }, "dd-ddm-base": { "requires": [ "node", "base", "yui-throttle", "classnamemanager" ] }, "dd-ddm-drop": { "requires": [ "dd-ddm" ] }, "dd-delegate": { "requires": [ "dd-drag", "dd-drop-plugin", "event-mouseenter" ] }, "dd-drag": { "requires": [ "dd-ddm-base" ] }, "dd-drop": { "requires": [ "dd-drag", "dd-ddm-drop" ] }, "dd-drop-plugin": { "requires": [ "dd-drop" ] }, "dd-gestures": { "condition": { "name": "dd-gestures", "test": function(Y) { return (Y.config.win && ('ontouchstart' in Y.config.win && !Y.UA.chrome)); }, "trigger": "dd-drag" }, "requires": [ "dd-drag", "event-synthetic", "event-gestures" ] }, "dd-plugin": { "optional": [ "dd-constrain", "dd-proxy" ], "requires": [ "dd-drag" ] }, "dd-proxy": { "requires": [ "dd-drag" ] }, "dd-scroll": { "requires": [ "dd-drag" ] }, "dial": { "lang": [ "en", "es" ], "requires": [ "widget", "dd-drag", "substitute", "event-mouseenter", "event-move", "event-key", "transition", "intl" ], "skinnable": true }, "dom": { "use": [ "dom-base", "dom-screen", "dom-style", "selector-native", "selector" ] }, "dom-base": { "requires": [ "dom-core" ] }, "dom-core": { "requires": [ "oop", "features" ] }, "dom-deprecated": { "requires": [ "dom-base" ] }, "dom-screen": { "requires": [ "dom-base", "dom-style" ] }, "dom-style": { "requires": [ "dom-base" ] }, "dom-style-ie": { "condition": { "name": "dom-style-ie", "test": function (Y) { var testFeature = Y.Features.test, addFeature = Y.Features.add, WINDOW = Y.config.win, DOCUMENT = Y.config.doc, DOCUMENT_ELEMENT = 'documentElement', ret = false; addFeature('style', 'computedStyle', { test: function() { return WINDOW && 'getComputedStyle' in WINDOW; } }); addFeature('style', 'opacity', { test: function() { return DOCUMENT && 'opacity' in DOCUMENT[DOCUMENT_ELEMENT].style; } }); ret = (!testFeature('style', 'opacity') && !testFeature('style', 'computedStyle')); return ret; }, "trigger": "dom-style" }, "requires": [ "dom-style" ] }, "dump": { "requires": [ "yui-base" ] }, "editor": { "use": [ "frame", "selection", "exec-command", "editor-base", "editor-para", "editor-br", "editor-bidi", "editor-tab", "createlink-base" ] }, "editor-base": { "requires": [ "base", "frame", "node", "exec-command", "selection" ] }, "editor-bidi": { "requires": [ "editor-base" ] }, "editor-br": { "requires": [ "editor-base" ] }, "editor-lists": { "requires": [ "editor-base" ] }, "editor-para": { "requires": [ "editor-base" ] }, "editor-tab": { "requires": [ "editor-base" ] }, "escape": { "requires": [ "yui-base" ] }, "event": { "after": [ "node-base" ], "use": [ "event-base", "event-delegate", "event-synthetic", "event-mousewheel", "event-mouseenter", "event-key", "event-focus", "event-resize", "event-hover", "event-outside" ] }, "event-base": { "after": [ "node-base" ], "requires": [ "event-custom-base" ] }, "event-base-ie": { "after": [ "event-base" ], "condition": { "name": "event-base-ie", "test": function(Y) { var imp = Y.config.doc && Y.config.doc.implementation; return (imp && (!imp.hasFeature('Events', '2.0'))); }, "trigger": "node-base" }, "requires": [ "node-base" ] }, "event-custom": { "use": [ "event-custom-base", "event-custom-complex" ] }, "event-custom-base": { "requires": [ "oop" ] }, "event-custom-complex": { "requires": [ "event-custom-base" ] }, "event-delegate": { "requires": [ "node-base" ] }, "event-flick": { "requires": [ "node-base", "event-touch", "event-synthetic" ] }, "event-focus": { "requires": [ "event-synthetic" ] }, "event-gestures": { "use": [ "event-flick", "event-move" ] }, "event-hover": { "requires": [ "event-mouseenter" ] }, "event-key": { "requires": [ "event-synthetic" ] }, "event-mouseenter": { "requires": [ "event-synthetic" ] }, "event-mousewheel": { "requires": [ "node-base" ] }, "event-move": { "requires": [ "node-base", "event-touch", "event-synthetic" ] }, "event-outside": { "requires": [ "event-synthetic" ] }, "event-resize": { "requires": [ "node-base", "event-synthetic" ] }, "event-simulate": { "requires": [ "event-base" ] }, "event-synthetic": { "requires": [ "node-base", "event-custom-complex" ] }, "event-touch": { "requires": [ "node-base" ] }, "event-valuechange": { "requires": [ "event-focus", "event-synthetic" ] }, "exec-command": { "requires": [ "frame" ] }, "features": { "requires": [ "yui-base" ] }, "frame": { "requires": [ "base", "node", "selector-css3", "substitute", "yui-throttle" ] }, "get": { "requires": [ "yui-base" ] }, "graphics": { "requires": [ "node", "event-custom", "pluginhost" ] }, "graphics-canvas": { "condition": { "name": "graphics-canvas", "test": function(Y) { var DOCUMENT = Y.config.doc, canvas = DOCUMENT && DOCUMENT.createElement("canvas"); return (DOCUMENT && !DOCUMENT.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#BasicStructure", "1.1") && (canvas && canvas.getContext && canvas.getContext("2d"))); }, "trigger": "graphics" }, "requires": [ "graphics" ] }, "graphics-canvas-default": { "condition": { "name": "graphics-canvas-default", "test": function(Y) { var DOCUMENT = Y.config.doc, canvas = DOCUMENT && DOCUMENT.createElement("canvas"); return (DOCUMENT && !DOCUMENT.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#BasicStructure", "1.1") && (canvas && canvas.getContext && canvas.getContext("2d"))); }, "trigger": "graphics" } }, "graphics-svg": { "condition": { "name": "graphics-svg", "test": function(Y) { var DOCUMENT = Y.config.doc; return (DOCUMENT && DOCUMENT.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#BasicStructure", "1.1")); }, "trigger": "graphics" }, "requires": [ "graphics" ] }, "graphics-svg-default": { "condition": { "name": "graphics-svg-default", "test": function(Y) { var DOCUMENT = Y.config.doc; return (DOCUMENT && DOCUMENT.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#BasicStructure", "1.1")); }, "trigger": "graphics" } }, "graphics-vml": { "condition": { "name": "graphics-vml", "test": function(Y) { var DOCUMENT = Y.config.doc, canvas = DOCUMENT && DOCUMENT.createElement("canvas"); return (DOCUMENT && !DOCUMENT.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#BasicStructure", "1.1") && (!canvas || !canvas.getContext || !canvas.getContext("2d"))); }, "trigger": "graphics" }, "requires": [ "graphics" ] }, "graphics-vml-default": { "condition": { "name": "graphics-vml-default", "test": function(Y) { var DOCUMENT = Y.config.doc, canvas = DOCUMENT && DOCUMENT.createElement("canvas"); return (DOCUMENT && !DOCUMENT.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#BasicStructure", "1.1") && (!canvas || !canvas.getContext || !canvas.getContext("2d"))); }, "trigger": "graphics" } }, "highlight": { "use": [ "highlight-base", "highlight-accentfold" ] }, "highlight-accentfold": { "requires": [ "highlight-base", "text-accentfold" ] }, "highlight-base": { "requires": [ "array-extras", "classnamemanager", "escape", "text-wordbreak" ] }, "history": { "use": [ "history-base", "history-hash", "history-hash-ie", "history-html5" ] }, "history-base": { "requires": [ "event-custom-complex" ] }, "history-hash": { "after": [ "history-html5" ], "requires": [ "event-synthetic", "history-base", "yui-later" ] }, "history-hash-ie": { "condition": { "name": "history-hash-ie", "test": function (Y) { var docMode = Y.config.doc && Y.config.doc.documentMode; return Y.UA.ie && (!('onhashchange' in Y.config.win) || !docMode || docMode < 8); }, "trigger": "history-hash" }, "requires": [ "history-hash", "node-base" ] }, "history-html5": { "optional": [ "json" ], "requires": [ "event-base", "history-base", "node-base" ] }, "imageloader": { "requires": [ "base-base", "node-style", "node-screen" ] }, "intl": { "requires": [ "intl-base", "event-custom" ] }, "intl-base": { "requires": [ "yui-base" ] }, "io": { "use": [ "io-base", "io-xdr", "io-form", "io-upload-iframe", "io-queue" ] }, "io-base": { "requires": [ "event-custom-base", "querystring-stringify-simple" ] }, "io-form": { "requires": [ "io-base", "node-base" ] }, "io-queue": { "requires": [ "io-base", "queue-promote" ] }, "io-upload-iframe": { "requires": [ "io-base", "node-base" ] }, "io-xdr": { "requires": [ "io-base", "datatype-xml-parse" ] }, "json": { "use": [ "json-parse", "json-stringify" ] }, "json-parse": { "requires": [ "yui-base" ] }, "json-stringify": { "requires": [ "yui-base" ] }, "jsonp": { "requires": [ "get", "oop" ] }, "jsonp-url": { "requires": [ "jsonp" ] }, "loader": { "use": [ "loader-base", "loader-rollup", "loader-yui3" ] }, "loader-base": { "requires": [ "get" ] }, "loader-rollup": { "requires": [ "loader-base" ] }, "loader-yui3": { "requires": [ "loader-base" ] }, "model": { "requires": [ "base-build", "escape", "json-parse" ] }, "model-list": { "requires": [ "array-extras", "array-invoke", "arraylist", "base-build", "escape", "json-parse", "model" ] }, "node": { "use": [ "node-base", "node-event-delegate", "node-pluginhost", "node-screen", "node-style" ] }, "node-base": { "requires": [ "event-base", "node-core", "dom-base" ] }, "node-core": { "requires": [ "dom-core", "selector" ] }, "node-deprecated": { "requires": [ "node-base" ] }, "node-event-delegate": { "requires": [ "node-base", "event-delegate" ] }, "node-event-html5": { "requires": [ "node-base" ] }, "node-event-simulate": { "requires": [ "node-base", "event-simulate" ] }, "node-flick": { "requires": [ "classnamemanager", "transition", "event-flick", "plugin" ], "skinnable": true }, "node-focusmanager": { "requires": [ "attribute", "node", "plugin", "node-event-simulate", "event-key", "event-focus" ] }, "node-load": { "requires": [ "node-base", "io-base" ] }, "node-menunav": { "requires": [ "node", "classnamemanager", "plugin", "node-focusmanager" ], "skinnable": true }, "node-pluginhost": { "requires": [ "node-base", "pluginhost" ] }, "node-screen": { "requires": [ "dom-screen", "node-base" ] }, "node-style": { "requires": [ "dom-style", "node-base" ] }, "oop": { "requires": [ "yui-base" ] }, "overlay": { "requires": [ "widget", "widget-stdmod", "widget-position", "widget-position-align", "widget-stack", "widget-position-constrain" ], "skinnable": true }, "panel": { "requires": [ "widget", "widget-stdmod", "widget-position", "widget-position-align", "widget-stack", "widget-position-constrain", "widget-modality", "widget-autohide", "widget-buttons" ], "skinnable": true }, "plugin": { "requires": [ "base-base" ] }, "pluginhost": { "use": [ "pluginhost-base", "pluginhost-config" ] }, "pluginhost-base": { "requires": [ "yui-base" ] }, "pluginhost-config": { "requires": [ "pluginhost-base" ] }, "profiler": { "requires": [ "yui-base" ] }, "querystring": { "use": [ "querystring-parse", "querystring-stringify" ] }, "querystring-parse": { "requires": [ "yui-base", "array-extras" ] }, "querystring-parse-simple": { "requires": [ "yui-base" ] }, "querystring-stringify": { "requires": [ "yui-base" ] }, "querystring-stringify-simple": { "requires": [ "yui-base" ] }, "queue-promote": { "requires": [ "yui-base" ] }, "range-slider": { "requires": [ "slider-base", "slider-value-range", "clickable-rail" ] }, "recordset": { "use": [ "recordset-base", "recordset-sort", "recordset-filter", "recordset-indexer" ] }, "recordset-base": { "requires": [ "base", "arraylist" ] }, "recordset-filter": { "requires": [ "recordset-base", "array-extras", "plugin" ] }, "recordset-indexer": { "requires": [ "recordset-base", "plugin" ] }, "recordset-sort": { "requires": [ "arraysort", "recordset-base", "plugin" ] }, "resize": { "use": [ "resize-base", "resize-proxy", "resize-constrain" ] }, "resize-base": { "requires": [ "base", "widget", "substitute", "event", "oop", "dd-drag", "dd-delegate", "dd-drop" ], "skinnable": true }, "resize-constrain": { "requires": [ "plugin", "resize-base" ] }, "resize-plugin": { "optional": [ "resize-constrain" ], "requires": [ "resize-base", "plugin" ] }, "resize-proxy": { "requires": [ "plugin", "resize-base" ] }, "rls": { "requires": [ "get", "features" ] }, "scrollview": { "requires": [ "scrollview-base", "scrollview-scrollbars" ] }, "scrollview-base": { "requires": [ "widget", "event-gestures", "transition" ], "skinnable": true }, "scrollview-base-ie": { "condition": { "name": "scrollview-base-ie", "trigger": "scrollview-base", "ua": "ie" }, "requires": [ "scrollview-base" ] }, "scrollview-list": { "requires": [ "plugin", "classnamemanager" ], "skinnable": true }, "scrollview-paginator": { "requires": [ "plugin" ] }, "scrollview-scrollbars": { "requires": [ "classnamemanager", "transition", "plugin" ], "skinnable": true }, "selection": { "requires": [ "node" ] }, "selector": { "requires": [ "selector-native" ] }, "selector-css2": { "condition": { "name": "selector-css2", "test": function (Y) { var DOCUMENT = Y.config.doc, ret = DOCUMENT && !('querySelectorAll' in DOCUMENT); return ret; }, "trigger": "selector" }, "requires": [ "selector-native" ] }, "selector-css3": { "requires": [ "selector-native", "selector-css2" ] }, "selector-native": { "requires": [ "dom-base" ] }, "shim-plugin": { "requires": [ "node-style", "node-pluginhost" ] }, "slider": { "use": [ "slider-base", "slider-value-range", "clickable-rail", "range-slider" ] }, "slider-base": { "requires": [ "widget", "dd-constrain", "substitute" ], "skinnable": true }, "slider-value-range": { "requires": [ "slider-base" ] }, "sortable": { "requires": [ "dd-delegate", "dd-drop-plugin", "dd-proxy" ] }, "sortable-scroll": { "requires": [ "dd-scroll", "sortable" ] }, "stylesheet": { "requires": [ "yui-base" ] }, "substitute": { "optional": [ "dump" ], "requires": [ "yui-base" ] }, "swf": { "requires": [ "event-custom", "node", "swfdetect", "escape" ] }, "swfdetect": { "requires": [ "yui-base" ] }, "tabview": { "requires": [ "widget", "widget-parent", "widget-child", "tabview-base", "node-pluginhost", "node-focusmanager" ], "skinnable": true }, "tabview-base": { "requires": [ "node-event-delegate", "classnamemanager", "skin-sam-tabview" ] }, "tabview-plugin": { "requires": [ "tabview-base" ] }, "test": { "requires": [ "event-simulate", "event-custom", "substitute", "json-stringify" ], "skinnable": true }, "text": { "use": [ "text-accentfold", "text-wordbreak" ] }, "text-accentfold": { "requires": [ "array-extras", "text-data-accentfold" ] }, "text-data-accentfold": { "requires": [ "yui-base" ] }, "text-data-wordbreak": { "requires": [ "yui-base" ] }, "text-wordbreak": { "requires": [ "array-extras", "text-data-wordbreak" ] }, "transition": { "requires": [ "node-style" ] }, "transition-timer": { "condition": { "name": "transition-timer", "test": function (Y) { var DOCUMENT = Y.config.doc, node = (DOCUMENT) ? DOCUMENT.documentElement: null, ret = true; if (node && node.style) { ret = !('MozTransition' in node.style || 'WebkitTransition' in node.style); } return ret; }, "trigger": "transition" }, "requires": [ "transition" ] }, "uploader": { "requires": [ "event-custom", "node", "base", "swf" ] }, "view": { "requires": [ "base-build", "node-event-delegate" ] }, "widget": { "use": [ "widget-base", "widget-htmlparser", "widget-uievents", "widget-skin" ] }, "widget-anim": { "requires": [ "plugin", "anim-base", "widget" ] }, "widget-autohide": { "requires": [ "widget", "event-outside", "base-build", "event-key" ], "skinnable": false }, "widget-base": { "requires": [ "attribute", "event-focus", "base-base", "base-pluginhost", "node-base", "node-style", "classnamemanager" ], "skinnable": true }, "widget-base-ie": { "condition": { "name": "widget-base-ie", "trigger": "widget-base", "ua": "ie" }, "requires": [ "widget-base" ] }, "widget-buttons": { "requires": [ "widget", "base-build", "widget-stdmod" ], "skinnable": true }, "widget-child": { "requires": [ "base-build", "widget" ] }, "widget-htmlparser": { "requires": [ "widget-base" ] }, "widget-locale": { "requires": [ "widget-base" ] }, "widget-modality": { "requires": [ "widget", "event-outside", "base-build" ], "skinnable": false }, "widget-parent": { "requires": [ "base-build", "arraylist", "widget" ] }, "widget-position": { "requires": [ "base-build", "node-screen", "widget" ] }, "widget-position-align": { "requires": [ "widget-position" ] }, "widget-position-constrain": { "requires": [ "widget-position" ] }, "widget-skin": { "requires": [ "widget-base" ] }, "widget-stack": { "requires": [ "base-build", "widget" ], "skinnable": true }, "widget-stdmod": { "requires": [ "base-build", "widget" ] }, "widget-uievents": { "requires": [ "widget-base", "node-event-delegate" ] }, "yql": { "requires": [ "jsonp", "jsonp-url" ] }, "yui": {}, "yui-base": {}, "yui-later": { "requires": [ "yui-base" ] }, "yui-log": { "requires": [ "yui-base" ] }, "yui-rls": {}, "yui-throttle": { "requires": [ "yui-base" ] } }; YUI.Env[Y.version].md5 = '105ebffae27a0e3d7331f8cf5c0bb282'; }, '@VERSION@' ,{requires:['loader-base']}); YUI.add('loader', function(Y){}, '@VERSION@' ,{use:['loader-base', 'loader-rollup', 'loader-yui3' ]});
ajax/libs/react/16.1.0-beta.1/umd/react.development.js
sufuf3/cdnjs
/** @license React v16.1.0-beta.1 * react.development.js * * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ (function (global, factory) { typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() : typeof define === 'function' && define.amd ? define(factory) : (global.React = factory()); }(this, (function () { 'use strict'; /* object-assign (c) Sindre Sorhus @license MIT */ /* eslint-disable no-unused-vars */ var getOwnPropertySymbols = Object.getOwnPropertySymbols; var hasOwnProperty = Object.prototype.hasOwnProperty; var propIsEnumerable = Object.prototype.propertyIsEnumerable; function toObject(val) { if (val === null || val === undefined) { throw new TypeError('Object.assign cannot be called with null or undefined'); } return Object(val); } function shouldUseNative() { try { if (!Object.assign) { return false; } // Detect buggy property enumeration order in older V8 versions. // https://bugs.chromium.org/p/v8/issues/detail?id=4118 var test1 = new String('abc'); // eslint-disable-line no-new-wrappers test1[5] = 'de'; if (Object.getOwnPropertyNames(test1)[0] === '5') { return false; } // https://bugs.chromium.org/p/v8/issues/detail?id=3056 var test2 = {}; for (var i = 0; i < 10; i++) { test2['_' + String.fromCharCode(i)] = i; } var order2 = Object.getOwnPropertyNames(test2).map(function (n) { return test2[n]; }); if (order2.join('') !== '0123456789') { return false; } // https://bugs.chromium.org/p/v8/issues/detail?id=3056 var test3 = {}; 'abcdefghijklmnopqrst'.split('').forEach(function (letter) { test3[letter] = letter; }); if (Object.keys(Object.assign({}, test3)).join('') !== 'abcdefghijklmnopqrst') { return false; } return true; } catch (err) { // We don't expect any of the above to throw, but better to be safe. return false; } } var objectAssign$1 = shouldUseNative() ? Object.assign : function (target, source) { var from; var to = toObject(target); var symbols; for (var s = 1; s < arguments.length; s++) { from = Object(arguments[s]); for (var key in from) { if (hasOwnProperty.call(from, key)) { to[key] = from[key]; } } if (getOwnPropertySymbols) { symbols = getOwnPropertySymbols(from); for (var i = 0; i < symbols.length; i++) { if (propIsEnumerable.call(from, symbols[i])) { to[symbols[i]] = from[symbols[i]]; } } } } return to; }; /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ // TODO: this is special because it gets imported during build. var ReactVersion = '16.1.0-beta.1'; /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. * * */ /** * WARNING: DO NOT manually require this module. * This is a replacement for `invariant(...)` used by the error code system * and will _only_ be required by the corresponding babel pass. * It always throws. */ /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. * */ /** * Use invariant() to assert state which your program assumes to be true. * * Provide sprintf-style format (only %s is supported) and arguments * to provide information about what broke and what you were * expecting. * * The invariant message will be stripped in production, but the invariant * will remain to ensure logic does not differ in production. */ var validateFormat = function validateFormat(format) {}; { validateFormat = function validateFormat(format) { if (format === undefined) { throw new Error('invariant requires an error message argument'); } }; } function invariant(condition, format, a, b, c, d, e, f) { validateFormat(format); if (!condition) { var error; if (format === undefined) { error = new Error('Minified exception occurred; use the non-minified dev environment ' + 'for the full error message and additional helpful warnings.'); } else { var args = [a, b, c, d, e, f]; var argIndex = 0; error = new Error(format.replace(/%s/g, function () { return args[argIndex++]; })); error.name = 'Invariant Violation'; } error.framesToPop = 1; // we don't care about invariant's own frame throw error; } } var invariant_1$1 = invariant; /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. * * */ // Exports React.Fragment var enableReactFragment = false; // Exports ReactDOM.createRoot // Mutating mode (React DOM, React ART, React Native): // Experimental noop mode (currently unused): // Experimental persistent mode (CS): // Only used in www builds. /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. * */ var emptyObject = {}; { Object.freeze(emptyObject); } var emptyObject_1 = emptyObject; /** * Copyright (c) 2014-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ /** * Forked from fbjs/warning: * https://github.com/facebook/fbjs/blob/e66ba20ad5be433eb54423f2b097d829324d9de6/packages/fbjs/src/__forks__/warning.js * * Only change is we use console.warn instead of console.error, * and do nothing when 'console' is not supported. * This really simplifies the code. * --- * Similar to invariant but only logs a warning if the condition is not met. * This can be used to log issues in development environments in critical * paths. Removing the logging code for production environments will keep the * same logic and follow the same code paths. */ var lowPriorityWarning = function () {}; { var printWarning = function (format) { for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { args[_key - 1] = arguments[_key]; } var argIndex = 0; var message = 'Warning: ' + format.replace(/%s/g, function () { return args[argIndex++]; }); if (typeof console !== 'undefined') { console.warn(message); } try { // --- Welcome to debugging React --- // This error was thrown as a convenience so that you can use this stack // to find the callsite that caused this warning to fire. throw new Error(message); } catch (x) {} }; lowPriorityWarning = function (condition, format) { if (format === undefined) { throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument'); } if (!condition) { for (var _len2 = arguments.length, args = Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) { args[_key2 - 2] = arguments[_key2]; } printWarning.apply(undefined, [format].concat(args)); } }; } var lowPriorityWarning$1 = lowPriorityWarning; /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. * * */ function makeEmptyFunction(arg) { return function () { return arg; }; } /** * This function accepts and discards inputs; it has no side effects. This is * primarily useful idiomatically for overridable function endpoints which * always need to be callable, since JS lacks a null-call idiom ala Cocoa. */ var emptyFunction = function emptyFunction() {}; emptyFunction.thatReturns = makeEmptyFunction; emptyFunction.thatReturnsFalse = makeEmptyFunction(false); emptyFunction.thatReturnsTrue = makeEmptyFunction(true); emptyFunction.thatReturnsNull = makeEmptyFunction(null); emptyFunction.thatReturnsThis = function () { return this; }; emptyFunction.thatReturnsArgument = function (arg) { return arg; }; var emptyFunction_1 = emptyFunction; /** * Copyright (c) 2014-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. * */ /** * Similar to invariant but only logs a warning if the condition is not met. * This can be used to log issues in development environments in critical * paths. Removing the logging code for production environments will keep the * same logic and follow the same code paths. */ var warning = emptyFunction_1; { var printWarning$1 = function printWarning(format) { for (var _len = arguments.length, args = Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { args[_key - 1] = arguments[_key]; } var argIndex = 0; var message = 'Warning: ' + format.replace(/%s/g, function () { return args[argIndex++]; }); if (typeof console !== 'undefined') { console.error(message); } try { // --- Welcome to debugging React --- // This error was thrown as a convenience so that you can use this stack // to find the callsite that caused this warning to fire. throw new Error(message); } catch (x) {} }; warning = function warning(condition, format) { if (format === undefined) { throw new Error('`warning(condition, format, ...args)` requires a warning ' + 'message argument'); } if (format.indexOf('Failed Composite propType: ') === 0) { return; // Ignore CompositeComponent proptype check. } if (!condition) { for (var _len2 = arguments.length, args = Array(_len2 > 2 ? _len2 - 2 : 0), _key2 = 2; _key2 < _len2; _key2++) { args[_key2 - 2] = arguments[_key2]; } printWarning$1.apply(undefined, [format].concat(args)); } }; } var warning_1$1 = warning; /** * Copyright (c) 2015-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ var didWarnStateUpdateForUnmountedComponent = {}; function warnNoop(publicInstance, callerName) { { var constructor = publicInstance.constructor; var componentName = constructor && (constructor.displayName || constructor.name) || 'ReactClass'; var warningKey = componentName + '.' + callerName; if (didWarnStateUpdateForUnmountedComponent[warningKey]) { return; } warning_1$1(false, '%s(...): Can only update a mounted or mounting component. ' + 'This usually means you called %s() on an unmounted component. ' + 'This is a no-op.\n\nPlease check the code for the %s component.', callerName, callerName, componentName); didWarnStateUpdateForUnmountedComponent[warningKey] = true; } } /** * This is the abstract API for an update queue. */ var ReactNoopUpdateQueue = { /** * Checks whether or not this composite component is mounted. * @param {ReactClass} publicInstance The instance we want to test. * @return {boolean} True if mounted, false otherwise. * @protected * @final */ isMounted: function (publicInstance) { return false; }, /** * Forces an update. This should only be invoked when it is known with * certainty that we are **not** in a DOM transaction. * * You may want to call this when you know that some deeper aspect of the * component's state has changed but `setState` was not called. * * This will not invoke `shouldComponentUpdate`, but it will invoke * `componentWillUpdate` and `componentDidUpdate`. * * @param {ReactClass} publicInstance The instance that should rerender. * @param {?function} callback Called after component is updated. * @param {?string} callerName name of the calling function in the public API. * @internal */ enqueueForceUpdate: function (publicInstance, callback, callerName) { warnNoop(publicInstance, 'forceUpdate'); }, /** * Replaces all of the state. Always use this or `setState` to mutate state. * You should treat `this.state` as immutable. * * There is no guarantee that `this.state` will be immediately updated, so * accessing `this.state` after calling this method may return the old value. * * @param {ReactClass} publicInstance The instance that should rerender. * @param {object} completeState Next state. * @param {?function} callback Called after component is updated. * @param {?string} callerName name of the calling function in the public API. * @internal */ enqueueReplaceState: function (publicInstance, completeState, callback, callerName) { warnNoop(publicInstance, 'replaceState'); }, /** * Sets a subset of the state. This only exists because _pendingState is * internal. This provides a merging strategy that is not available to deep * properties which is confusing. TODO: Expose pendingState or don't use it * during the merge. * * @param {ReactClass} publicInstance The instance that should rerender. * @param {object} partialState Next partial state to be merged with state. * @param {?function} callback Called after component is updated. * @param {?string} Name of the calling function in the public API. * @internal */ enqueueSetState: function (publicInstance, partialState, callback, callerName) { warnNoop(publicInstance, 'setState'); } }; /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ /** * Base class helpers for the updating state of a component. */ function Component(props, context, updater) { this.props = props; this.context = context; this.refs = emptyObject_1; // We initialize the default updater but the real one gets injected by the // renderer. this.updater = updater || ReactNoopUpdateQueue; } Component.prototype.isReactComponent = {}; /** * Sets a subset of the state. Always use this to mutate * state. You should treat `this.state` as immutable. * * There is no guarantee that `this.state` will be immediately updated, so * accessing `this.state` after calling this method may return the old value. * * There is no guarantee that calls to `setState` will run synchronously, * as they may eventually be batched together. You can provide an optional * callback that will be executed when the call to setState is actually * completed. * * When a function is provided to setState, it will be called at some point in * the future (not synchronously). It will be called with the up to date * component arguments (state, props, context). These values can be different * from this.* because your function may be called after receiveProps but before * shouldComponentUpdate, and this new state, props, and context will not yet be * assigned to this. * * @param {object|function} partialState Next partial state or function to * produce next partial state to be merged with current state. * @param {?function} callback Called after state is updated. * @final * @protected */ Component.prototype.setState = function (partialState, callback) { !(typeof partialState === 'object' || typeof partialState === 'function' || partialState == null) ? invariant_1$1(false, 'setState(...): takes an object of state variables to update or a function which returns an object of state variables.') : void 0; this.updater.enqueueSetState(this, partialState, callback, 'setState'); }; /** * Forces an update. This should only be invoked when it is known with * certainty that we are **not** in a DOM transaction. * * You may want to call this when you know that some deeper aspect of the * component's state has changed but `setState` was not called. * * This will not invoke `shouldComponentUpdate`, but it will invoke * `componentWillUpdate` and `componentDidUpdate`. * * @param {?function} callback Called after update is complete. * @final * @protected */ Component.prototype.forceUpdate = function (callback) { this.updater.enqueueForceUpdate(this, callback, 'forceUpdate'); }; /** * Deprecated APIs. These APIs used to exist on classic React classes but since * we would like to deprecate them, we're not going to move them over to this * modern base class. Instead, we define a getter that warns if it's accessed. */ { var deprecatedAPIs = { isMounted: ['isMounted', 'Instead, make sure to clean up subscriptions and pending requests in ' + 'componentWillUnmount to prevent memory leaks.'], replaceState: ['replaceState', 'Refactor your code to use setState instead (see ' + 'https://github.com/facebook/react/issues/3236).'] }; var defineDeprecationWarning = function (methodName, info) { Object.defineProperty(Component.prototype, methodName, { get: function () { lowPriorityWarning$1(false, '%s(...) is deprecated in plain JavaScript React classes. %s', info[0], info[1]); return undefined; } }); }; for (var fnName in deprecatedAPIs) { if (deprecatedAPIs.hasOwnProperty(fnName)) { defineDeprecationWarning(fnName, deprecatedAPIs[fnName]); } } } /** * Base class helpers for the updating state of a component. */ function PureComponent(props, context, updater) { // Duplicated from Component. this.props = props; this.context = context; this.refs = emptyObject_1; // We initialize the default updater but the real one gets injected by the // renderer. this.updater = updater || ReactNoopUpdateQueue; } function ComponentDummy() {} ComponentDummy.prototype = Component.prototype; var pureComponentPrototype = PureComponent.prototype = new ComponentDummy(); pureComponentPrototype.constructor = PureComponent; // Avoid an extra prototype jump for these methods. objectAssign$1(pureComponentPrototype, Component.prototype); pureComponentPrototype.isPureReactComponent = true; function AsyncComponent(props, context, updater) { // Duplicated from Component. this.props = props; this.context = context; this.refs = emptyObject_1; // We initialize the default updater but the real one gets injected by the // renderer. this.updater = updater || ReactNoopUpdateQueue; } var asyncComponentPrototype = AsyncComponent.prototype = new ComponentDummy(); asyncComponentPrototype.constructor = AsyncComponent; // Avoid an extra prototype jump for these methods. objectAssign$1(asyncComponentPrototype, Component.prototype); asyncComponentPrototype.unstable_isAsyncReactComponent = true; asyncComponentPrototype.render = function () { return this.props.children; }; /** * Keeps track of the current owner. * * The current owner is the component who should own any components that are * currently being constructed. */ var ReactCurrentOwner = { /** * @internal * @type {ReactComponent} */ current: null }; /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. * * */ /** * Copyright (c) 2014-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ var hasOwnProperty$1 = Object.prototype.hasOwnProperty; // The Symbol used to tag the ReactElement type. If there is no native Symbol // nor polyfill, then a plain number is used for performance. var REACT_ELEMENT_TYPE$1 = typeof Symbol === 'function' && Symbol['for'] && Symbol['for']('react.element') || 0xeac7; var RESERVED_PROPS = { key: true, ref: true, __self: true, __source: true }; var specialPropKeyWarningShown; var specialPropRefWarningShown; function hasValidRef(config) { { if (hasOwnProperty$1.call(config, 'ref')) { var getter = Object.getOwnPropertyDescriptor(config, 'ref').get; if (getter && getter.isReactWarning) { return false; } } } return config.ref !== undefined; } function hasValidKey(config) { { if (hasOwnProperty$1.call(config, 'key')) { var getter = Object.getOwnPropertyDescriptor(config, 'key').get; if (getter && getter.isReactWarning) { return false; } } } return config.key !== undefined; } function defineKeyPropWarningGetter(props, displayName) { var warnAboutAccessingKey = function () { if (!specialPropKeyWarningShown) { specialPropKeyWarningShown = true; warning_1$1(false, '%s: `key` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + 'prop. (https://fb.me/react-special-props)', displayName); } }; warnAboutAccessingKey.isReactWarning = true; Object.defineProperty(props, 'key', { get: warnAboutAccessingKey, configurable: true }); } function defineRefPropWarningGetter(props, displayName) { var warnAboutAccessingRef = function () { if (!specialPropRefWarningShown) { specialPropRefWarningShown = true; warning_1$1(false, '%s: `ref` is not a prop. Trying to access it will result ' + 'in `undefined` being returned. If you need to access the same ' + 'value within the child component, you should pass it as a different ' + 'prop. (https://fb.me/react-special-props)', displayName); } }; warnAboutAccessingRef.isReactWarning = true; Object.defineProperty(props, 'ref', { get: warnAboutAccessingRef, configurable: true }); } /** * Factory method to create a new React element. This no longer adheres to * the class pattern, so do not use new to call it. Also, no instanceof check * will work. Instead test $$typeof field against Symbol.for('react.element') to check * if something is a React Element. * * @param {*} type * @param {*} key * @param {string|object} ref * @param {*} self A *temporary* helper to detect places where `this` is * different from the `owner` when React.createElement is called, so that we * can warn. We want to get rid of owner and replace string `ref`s with arrow * functions, and as long as `this` and owner are the same, there will be no * change in behavior. * @param {*} source An annotation object (added by a transpiler or otherwise) * indicating filename, line number, and/or other information. * @param {*} owner * @param {*} props * @internal */ var ReactElement = function (type, key, ref, self, source, owner, props) { var element = { // This tag allow us to uniquely identify this as a React Element $$typeof: REACT_ELEMENT_TYPE$1, // Built-in properties that belong on the element type: type, key: key, ref: ref, props: props, // Record the component responsible for creating this element. _owner: owner }; { // The validation flag is currently mutative. We put it on // an external backing store so that we can freeze the whole object. // This can be replaced with a WeakMap once they are implemented in // commonly used development environments. element._store = {}; // To make comparing ReactElements easier for testing purposes, we make // the validation flag non-enumerable (where possible, which should // include every environment we run tests in), so the test framework // ignores it. Object.defineProperty(element._store, 'validated', { configurable: false, enumerable: false, writable: true, value: false }); // self and source are DEV only properties. Object.defineProperty(element, '_self', { configurable: false, enumerable: false, writable: false, value: self }); // Two elements created in two different places should be considered // equal for testing purposes and therefore we hide it from enumeration. Object.defineProperty(element, '_source', { configurable: false, enumerable: false, writable: false, value: source }); if (Object.freeze) { Object.freeze(element.props); Object.freeze(element); } } return element; }; /** * Create and return a new ReactElement of the given type. * See https://reactjs.org/docs/react-api.html#createelement */ function createElement(type, config, children) { var propName; // Reserved names are extracted var props = {}; var key = null; var ref = null; var self = null; var source = null; if (config != null) { if (hasValidRef(config)) { ref = config.ref; } if (hasValidKey(config)) { key = '' + config.key; } self = config.__self === undefined ? null : config.__self; source = config.__source === undefined ? null : config.__source; // Remaining properties are added to a new props object for (propName in config) { if (hasOwnProperty$1.call(config, propName) && !RESERVED_PROPS.hasOwnProperty(propName)) { props[propName] = config[propName]; } } } // Children can be more than one argument, and those are transferred onto // the newly allocated props object. var childrenLength = arguments.length - 2; if (childrenLength === 1) { props.children = children; } else if (childrenLength > 1) { var childArray = Array(childrenLength); for (var i = 0; i < childrenLength; i++) { childArray[i] = arguments[i + 2]; } { if (Object.freeze) { Object.freeze(childArray); } } props.children = childArray; } // Resolve default props if (type && type.defaultProps) { var defaultProps = type.defaultProps; for (propName in defaultProps) { if (props[propName] === undefined) { props[propName] = defaultProps[propName]; } } } { if (key || ref) { if (typeof props.$$typeof === 'undefined' || props.$$typeof !== REACT_ELEMENT_TYPE$1) { var displayName = typeof type === 'function' ? type.displayName || type.name || 'Unknown' : type; if (key) { defineKeyPropWarningGetter(props, displayName); } if (ref) { defineRefPropWarningGetter(props, displayName); } } } } return ReactElement(type, key, ref, self, source, ReactCurrentOwner.current, props); } /** * Return a function that produces ReactElements of a given type. * See https://reactjs.org/docs/react-api.html#createfactory */ function cloneAndReplaceKey(oldElement, newKey) { var newElement = ReactElement(oldElement.type, newKey, oldElement.ref, oldElement._self, oldElement._source, oldElement._owner, oldElement.props); return newElement; } /** * Clone and return a new ReactElement using element as the starting point. * See https://reactjs.org/docs/react-api.html#cloneelement */ function cloneElement(element, config, children) { var propName; // Original props are copied var props = objectAssign$1({}, element.props); // Reserved names are extracted var key = element.key; var ref = element.ref; // Self is preserved since the owner is preserved. var self = element._self; // Source is preserved since cloneElement is unlikely to be targeted by a // transpiler, and the original source is probably a better indicator of the // true owner. var source = element._source; // Owner will be preserved, unless ref is overridden var owner = element._owner; if (config != null) { if (hasValidRef(config)) { // Silently steal the ref from the parent. ref = config.ref; owner = ReactCurrentOwner.current; } if (hasValidKey(config)) { key = '' + config.key; } // Remaining properties override existing props var defaultProps; if (element.type && element.type.defaultProps) { defaultProps = element.type.defaultProps; } for (propName in config) { if (hasOwnProperty$1.call(config, propName) && !RESERVED_PROPS.hasOwnProperty(propName)) { if (config[propName] === undefined && defaultProps !== undefined) { // Resolve default props props[propName] = defaultProps[propName]; } else { props[propName] = config[propName]; } } } } // Children can be more than one argument, and those are transferred onto // the newly allocated props object. var childrenLength = arguments.length - 2; if (childrenLength === 1) { props.children = children; } else if (childrenLength > 1) { var childArray = Array(childrenLength); for (var i = 0; i < childrenLength; i++) { childArray[i] = arguments[i + 2]; } props.children = childArray; } return ReactElement(element.type, key, ref, self, source, owner, props); } /** * Verifies the object is a ReactElement. * See https://reactjs.org/docs/react-api.html#isvalidelement * @param {?object} object * @return {boolean} True if `object` is a valid component. * @final */ function isValidElement(object) { return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE$1; } /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. * * */ var ReactDebugCurrentFrame = {}; { // Component that is being worked on ReactDebugCurrentFrame.getCurrentStack = null; ReactDebugCurrentFrame.getStackAddendum = function () { var impl = ReactDebugCurrentFrame.getCurrentStack; if (impl) { return impl(); } return null; }; } /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator; var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec. // The Symbol used to tag the ReactElement type. If there is no native Symbol // nor polyfill, then a plain number is used for performance. var REACT_ELEMENT_TYPE = typeof Symbol === 'function' && Symbol['for'] && Symbol['for']('react.element') || 0xeac7; var REACT_PORTAL_TYPE = typeof Symbol === 'function' && Symbol['for'] && Symbol['for']('react.portal') || 0xeaca; var SEPARATOR = '.'; var SUBSEPARATOR = ':'; /** * Escape and wrap key so it is safe to use as a reactid * * @param {string} key to be escaped. * @return {string} the escaped key. */ function escape(key) { var escapeRegex = /[=:]/g; var escaperLookup = { '=': '=0', ':': '=2' }; var escapedString = ('' + key).replace(escapeRegex, function (match) { return escaperLookup[match]; }); return '$' + escapedString; } /** * TODO: Test that a single child and an array with one item have the same key * pattern. */ var didWarnAboutMaps = false; var userProvidedKeyEscapeRegex = /\/+/g; function escapeUserProvidedKey(text) { return ('' + text).replace(userProvidedKeyEscapeRegex, '$&/'); } var POOL_SIZE = 10; var traverseContextPool = []; function getPooledTraverseContext(mapResult, keyPrefix, mapFunction, mapContext) { if (traverseContextPool.length) { var traverseContext = traverseContextPool.pop(); traverseContext.result = mapResult; traverseContext.keyPrefix = keyPrefix; traverseContext.func = mapFunction; traverseContext.context = mapContext; traverseContext.count = 0; return traverseContext; } else { return { result: mapResult, keyPrefix: keyPrefix, func: mapFunction, context: mapContext, count: 0 }; } } function releaseTraverseContext(traverseContext) { traverseContext.result = null; traverseContext.keyPrefix = null; traverseContext.func = null; traverseContext.context = null; traverseContext.count = 0; if (traverseContextPool.length < POOL_SIZE) { traverseContextPool.push(traverseContext); } } /** * @param {?*} children Children tree container. * @param {!string} nameSoFar Name of the key path so far. * @param {!function} callback Callback to invoke with each child found. * @param {?*} traverseContext Used to pass information throughout the traversal * process. * @return {!number} The number of children in this subtree. */ function traverseAllChildrenImpl(children, nameSoFar, callback, traverseContext) { var type = typeof children; if (type === 'undefined' || type === 'boolean') { // All of the above are perceived as null. children = null; } if (children === null || type === 'string' || type === 'number' || // The following is inlined from ReactElement. This means we can optimize // some checks. React Fiber also inlines this logic for similar purposes. type === 'object' && children.$$typeof === REACT_ELEMENT_TYPE || type === 'object' && children.$$typeof === REACT_PORTAL_TYPE) { callback(traverseContext, children, // If it's the only child, treat the name as if it was wrapped in an array // so that it's consistent if the number of children grows. nameSoFar === '' ? SEPARATOR + getComponentKey(children, 0) : nameSoFar); return 1; } var child; var nextName; var subtreeCount = 0; // Count of children found in the current subtree. var nextNamePrefix = nameSoFar === '' ? SEPARATOR : nameSoFar + SUBSEPARATOR; if (Array.isArray(children)) { for (var i = 0; i < children.length; i++) { child = children[i]; nextName = nextNamePrefix + getComponentKey(child, i); subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); } } else { var iteratorFn = ITERATOR_SYMBOL && children[ITERATOR_SYMBOL] || children[FAUX_ITERATOR_SYMBOL]; if (typeof iteratorFn === 'function') { { // Warn about using Maps as children if (iteratorFn === children.entries) { warning_1$1(didWarnAboutMaps, 'Using Maps as children is unsupported and will likely yield ' + 'unexpected results. Convert it to a sequence/iterable of keyed ' + 'ReactElements instead.%s', ReactDebugCurrentFrame.getStackAddendum()); didWarnAboutMaps = true; } } var iterator = iteratorFn.call(children); var step; var ii = 0; while (!(step = iterator.next()).done) { child = step.value; nextName = nextNamePrefix + getComponentKey(child, ii++); subtreeCount += traverseAllChildrenImpl(child, nextName, callback, traverseContext); } } else if (type === 'object') { var addendum = ''; { addendum = ' If you meant to render a collection of children, use an array ' + 'instead.' + ReactDebugCurrentFrame.getStackAddendum(); } var childrenString = '' + children; invariant_1$1(false, 'Objects are not valid as a React child (found: %s).%s', childrenString === '[object Object]' ? 'object with keys {' + Object.keys(children).join(', ') + '}' : childrenString, addendum); } } return subtreeCount; } /** * Traverses children that are typically specified as `props.children`, but * might also be specified through attributes: * * - `traverseAllChildren(this.props.children, ...)` * - `traverseAllChildren(this.props.leftPanelChildren, ...)` * * The `traverseContext` is an optional argument that is passed through the * entire traversal. It can be used to store accumulations or anything else that * the callback might find relevant. * * @param {?*} children Children tree object. * @param {!function} callback To invoke upon traversing each child. * @param {?*} traverseContext Context for traversal. * @return {!number} The number of children in this subtree. */ function traverseAllChildren(children, callback, traverseContext) { if (children == null) { return 0; } return traverseAllChildrenImpl(children, '', callback, traverseContext); } /** * Generate a key string that identifies a component within a set. * * @param {*} component A component that could contain a manual key. * @param {number} index Index that is used if a manual key is not provided. * @return {string} */ function getComponentKey(component, index) { // Do some typechecking here since we call this blindly. We want to ensure // that we don't block potential future ES APIs. if (typeof component === 'object' && component !== null && component.key != null) { // Explicit key return escape(component.key); } // Implicit key determined by the index in the set return index.toString(36); } function forEachSingleChild(bookKeeping, child, name) { var func = bookKeeping.func, context = bookKeeping.context; func.call(context, child, bookKeeping.count++); } /** * Iterates through children that are typically specified as `props.children`. * * See https://reactjs.org/docs/react-api.html#react.children.foreach * * The provided forEachFunc(child, index) will be called for each * leaf child. * * @param {?*} children Children tree container. * @param {function(*, int)} forEachFunc * @param {*} forEachContext Context for forEachContext. */ function forEachChildren(children, forEachFunc, forEachContext) { if (children == null) { return children; } var traverseContext = getPooledTraverseContext(null, null, forEachFunc, forEachContext); traverseAllChildren(children, forEachSingleChild, traverseContext); releaseTraverseContext(traverseContext); } function mapSingleChildIntoContext(bookKeeping, child, childKey) { var result = bookKeeping.result, keyPrefix = bookKeeping.keyPrefix, func = bookKeeping.func, context = bookKeeping.context; var mappedChild = func.call(context, child, bookKeeping.count++); if (Array.isArray(mappedChild)) { mapIntoWithKeyPrefixInternal(mappedChild, result, childKey, emptyFunction_1.thatReturnsArgument); } else if (mappedChild != null) { if (isValidElement(mappedChild)) { mappedChild = cloneAndReplaceKey(mappedChild, // Keep both the (mapped) and old keys if they differ, just as // traverseAllChildren used to do for objects as children keyPrefix + (mappedChild.key && (!child || child.key !== mappedChild.key) ? escapeUserProvidedKey(mappedChild.key) + '/' : '') + childKey); } result.push(mappedChild); } } function mapIntoWithKeyPrefixInternal(children, array, prefix, func, context) { var escapedPrefix = ''; if (prefix != null) { escapedPrefix = escapeUserProvidedKey(prefix) + '/'; } var traverseContext = getPooledTraverseContext(array, escapedPrefix, func, context); traverseAllChildren(children, mapSingleChildIntoContext, traverseContext); releaseTraverseContext(traverseContext); } /** * Maps children that are typically specified as `props.children`. * * See https://reactjs.org/docs/react-api.html#react.children.map * * The provided mapFunction(child, key, index) will be called for each * leaf child. * * @param {?*} children Children tree container. * @param {function(*, int)} func The map function. * @param {*} context Context for mapFunction. * @return {object} Object containing the ordered map of results. */ function mapChildren(children, func, context) { if (children == null) { return children; } var result = []; mapIntoWithKeyPrefixInternal(children, result, null, func, context); return result; } /** * Count the number of children that are typically specified as * `props.children`. * * See https://reactjs.org/docs/react-api.html#react.children.count * * @param {?*} children Children tree container. * @return {number} The number of children. */ function countChildren(children, context) { return traverseAllChildren(children, emptyFunction_1.thatReturnsNull, null); } /** * Flatten a children object (typically specified as `props.children`) and * return an array with appropriately re-keyed children. * * See https://reactjs.org/docs/react-api.html#react.children.toarray */ function toArray(children) { var result = []; mapIntoWithKeyPrefixInternal(children, result, null, emptyFunction_1.thatReturnsArgument); return result; } /** * Returns the first child in a collection of children and verifies that there * is only one child in the collection. * * See https://reactjs.org/docs/react-api.html#react.children.only * * The current implementation of this function assumes that a single child gets * passed without a wrapper, but the purpose of this helper function is to * abstract away the particular structure of children. * * @param {?object} children Child collection structure. * @return {ReactElement} The first and only `ReactElement` contained in the * structure. */ function onlyChild(children) { !isValidElement(children) ? invariant_1$1(false, 'React.Children.only expected to receive a single React element child.') : void 0; return children; } /** * Copyright (c) 2016-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. * * */ var describeComponentFrame = function (name, source, ownerName) { return '\n in ' + (name || 'Unknown') + (source ? ' (at ' + source.fileName.replace(/^.*[\\\/]/, '') + ':' + source.lineNumber + ')' : ownerName ? ' (created by ' + ownerName + ')' : ''); }; function getComponentName(fiber) { var type = fiber.type; if (typeof type === 'string') { return type; } if (typeof type === 'function') { return type.displayName || type.name; } return null; } /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. * * */ /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ var ReactPropTypesSecret$1 = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED'; var ReactPropTypesSecret_1 = ReactPropTypesSecret$1; /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ { var invariant$2 = invariant_1$1; var warning$2 = warning_1$1; var ReactPropTypesSecret = ReactPropTypesSecret_1; var loggedTypeFailures = {}; } /** * Assert that the values match with the type specs. * Error messages are memorized and will only be shown once. * * @param {object} typeSpecs Map of name to a ReactPropType * @param {object} values Runtime values that need to be type-checked * @param {string} location e.g. "prop", "context", "child context" * @param {string} componentName Name of the component for error messages. * @param {?Function} getStack Returns the component stack. * @private */ function checkPropTypes(typeSpecs, values, location, componentName, getStack) { { for (var typeSpecName in typeSpecs) { if (typeSpecs.hasOwnProperty(typeSpecName)) { var error; // Prop type validation may throw. In case they do, we don't want to // fail the render phase where it didn't fail before. So we log it. // After these have been cleaned up, we'll let them throw. try { // This is intentionally an invariant that gets caught. It's the same // behavior as without this statement except with a better message. invariant$2(typeof typeSpecs[typeSpecName] === 'function', '%s: %s type `%s` is invalid; it must be a function, usually from ' + 'the `prop-types` package, but received `%s`.', componentName || 'React class', location, typeSpecName, typeof typeSpecs[typeSpecName]); error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret); } catch (ex) { error = ex; } warning$2(!error || error instanceof Error, '%s: type specification of %s `%s` is invalid; the type checker ' + 'function must return `null` or an `Error` but returned a %s. ' + 'You may have forgotten to pass an argument to the type checker ' + 'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' + 'shape all require an argument).', componentName || 'React class', location, typeSpecName, typeof error); if (error instanceof Error && !(error.message in loggedTypeFailures)) { // Only monitor this failure once because there tends to be a lot of the // same error. loggedTypeFailures[error.message] = true; var stack = getStack ? getStack() : ''; warning$2(false, 'Failed %s type: %s%s', location, error.message, stack != null ? stack : ''); } } } } } var checkPropTypes_1$1 = checkPropTypes; /** * Copyright (c) 2014-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ /** * ReactElementValidator provides a wrapper around a element factory * which validates the props passed to the element. This is intended to be * used only in DEV and could be replaced by a static type checker for languages * that support it. */ { var currentlyValidatingElement = null; var getDisplayName = function (element) { if (element == null) { return '#empty'; } else if (typeof element === 'string' || typeof element === 'number') { return '#text'; } else if (typeof element.type === 'string') { return element.type; } else if (element.type === REACT_FRAGMENT_TYPE$1) { return 'React.Fragment'; } else { return element.type.displayName || element.type.name || 'Unknown'; } }; var getStackAddendum = function () { var stack = ''; if (currentlyValidatingElement) { var name = getDisplayName(currentlyValidatingElement); var owner = currentlyValidatingElement._owner; stack += describeComponentFrame(name, currentlyValidatingElement._source, owner && getComponentName(owner)); } stack += ReactDebugCurrentFrame.getStackAddendum() || ''; return stack; }; var REACT_FRAGMENT_TYPE$1 = typeof Symbol === 'function' && Symbol['for'] && Symbol['for']('react.fragment') || 0xeacb; var VALID_FRAGMENT_PROPS = new Map([['children', true], ['key', true]]); } var ITERATOR_SYMBOL$1 = typeof Symbol === 'function' && Symbol.iterator; var FAUX_ITERATOR_SYMBOL$1 = '@@iterator'; // Before Symbol spec. function getDeclarationErrorAddendum() { if (ReactCurrentOwner.current) { var name = getComponentName(ReactCurrentOwner.current); if (name) { return '\n\nCheck the render method of `' + name + '`.'; } } return ''; } function getSourceInfoErrorAddendum(elementProps) { if (elementProps !== null && elementProps !== undefined && elementProps.__source !== undefined) { var source = elementProps.__source; var fileName = source.fileName.replace(/^.*[\\\/]/, ''); var lineNumber = source.lineNumber; return '\n\nCheck your code at ' + fileName + ':' + lineNumber + '.'; } return ''; } /** * Warn if there's no key explicitly set on dynamic arrays of children or * object keys are not valid. This allows us to keep track of children between * updates. */ var ownerHasKeyUseWarning = {}; function getCurrentComponentErrorInfo(parentType) { var info = getDeclarationErrorAddendum(); if (!info) { var parentName = typeof parentType === 'string' ? parentType : parentType.displayName || parentType.name; if (parentName) { info = '\n\nCheck the top-level render call using <' + parentName + '>.'; } } return info; } /** * Warn if the element doesn't have an explicit key assigned to it. * This element is in an array. The array could grow and shrink or be * reordered. All children that haven't already been validated are required to * have a "key" property assigned to it. Error statuses are cached so a warning * will only be shown once. * * @internal * @param {ReactElement} element Element that requires a key. * @param {*} parentType element's parent's type. */ function validateExplicitKey(element, parentType) { if (!element._store || element._store.validated || element.key != null) { return; } element._store.validated = true; var currentComponentErrorInfo = getCurrentComponentErrorInfo(parentType); if (ownerHasKeyUseWarning[currentComponentErrorInfo]) { return; } ownerHasKeyUseWarning[currentComponentErrorInfo] = true; // Usually the current owner is the offender, but if it accepts children as a // property, it may be the creator of the child that's responsible for // assigning it a key. var childOwner = ''; if (element && element._owner && element._owner !== ReactCurrentOwner.current) { // Give the component that originally created this child. childOwner = ' It was passed a child from ' + getComponentName(element._owner) + '.'; } currentlyValidatingElement = element; { warning_1$1(false, 'Each child in an array or iterator should have a unique "key" prop.' + '%s%s See https://fb.me/react-warning-keys for more information.%s', currentComponentErrorInfo, childOwner, getStackAddendum()); } currentlyValidatingElement = null; } /** * Ensure that every element either is passed in a static location, in an * array with an explicit keys property defined, or in an object literal * with valid key property. * * @internal * @param {ReactNode} node Statically passed child of any type. * @param {*} parentType node's parent's type. */ function validateChildKeys(node, parentType) { if (typeof node !== 'object') { return; } if (Array.isArray(node)) { for (var i = 0; i < node.length; i++) { var child = node[i]; if (isValidElement(child)) { validateExplicitKey(child, parentType); } } } else if (isValidElement(node)) { // This element was passed in a valid location. if (node._store) { node._store.validated = true; } } else if (node) { var iteratorFn = ITERATOR_SYMBOL$1 && node[ITERATOR_SYMBOL$1] || node[FAUX_ITERATOR_SYMBOL$1]; if (typeof iteratorFn === 'function') { // Entry iterators used to provide implicit keys, // but now we print a separate warning for them later. if (iteratorFn !== node.entries) { var iterator = iteratorFn.call(node); var step; while (!(step = iterator.next()).done) { if (isValidElement(step.value)) { validateExplicitKey(step.value, parentType); } } } } } } /** * Given an element, validate that its props follow the propTypes definition, * provided by the type. * * @param {ReactElement} element */ function validatePropTypes(element) { var componentClass = element.type; if (typeof componentClass !== 'function') { return; } var name = componentClass.displayName || componentClass.name; var propTypes = componentClass.propTypes; if (propTypes) { currentlyValidatingElement = element; checkPropTypes_1$1(propTypes, element.props, 'prop', name, getStackAddendum); currentlyValidatingElement = null; } if (typeof componentClass.getDefaultProps === 'function') { warning_1$1(componentClass.getDefaultProps.isReactClassApproved, 'getDefaultProps is only used on classic React.createClass ' + 'definitions. Use a static property named `defaultProps` instead.'); } } /** * Given a fragment, validate that it can only be provided with fragment props * @param {ReactElement} fragment */ function validateFragmentProps(fragment) { currentlyValidatingElement = fragment; var _iteratorNormalCompletion = true; var _didIteratorError = false; var _iteratorError = undefined; try { for (var _iterator = Object.keys(fragment.props)[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) { var key = _step.value; if (!VALID_FRAGMENT_PROPS.has(key)) { warning_1$1(false, 'Invalid prop `%s` supplied to `React.Fragment`. ' + 'React.Fragment can only have `key` and `children` props.%s', key, getStackAddendum()); break; } } } catch (err) { _didIteratorError = true; _iteratorError = err; } finally { try { if (!_iteratorNormalCompletion && _iterator['return']) { _iterator['return'](); } } finally { if (_didIteratorError) { throw _iteratorError; } } } if (fragment.ref !== null) { warning_1$1(false, 'Invalid attribute `ref` supplied to `React.Fragment`.%s', getStackAddendum()); } currentlyValidatingElement = null; } function createElementWithValidation(type, props, children) { var validType = typeof type === 'string' || typeof type === 'function' || typeof type === 'symbol' || typeof type === 'number'; // We warn in this case but don't throw. We expect the element creation to // succeed and there will likely be errors in render. if (!validType) { var info = ''; if (type === undefined || typeof type === 'object' && type !== null && Object.keys(type).length === 0) { info += ' You likely forgot to export your component from the file ' + "it's defined in."; } var sourceInfo = getSourceInfoErrorAddendum(props); if (sourceInfo) { info += sourceInfo; } else { info += getDeclarationErrorAddendum(); } info += getStackAddendum() || ''; warning_1$1(false, 'React.createElement: type is invalid -- expected a string (for ' + 'built-in components) or a class/function (for composite ' + 'components) but got: %s.%s', type == null ? type : typeof type, info); } var element = createElement.apply(this, arguments); // The result can be nullish if a mock or a custom function is used. // TODO: Drop this when these are no longer allowed as the type argument. if (element == null) { return element; } // Skip key warning if the type isn't valid since our key validation logic // doesn't expect a non-string/function type and can throw confusing errors. // We don't want exception behavior to differ between dev and prod. // (Rendering will throw with a helpful message and as soon as the type is // fixed, the key warnings will appear.) if (validType) { for (var i = 2; i < arguments.length; i++) { validateChildKeys(arguments[i], type); } } if (typeof type === 'symbol' && type === REACT_FRAGMENT_TYPE$1) { validateFragmentProps(element); } else { validatePropTypes(element); } return element; } function createFactoryWithValidation(type) { var validatedFactory = createElementWithValidation.bind(null, type); // Legacy hook TODO: Warn if this is accessed validatedFactory.type = type; { Object.defineProperty(validatedFactory, 'type', { enumerable: false, get: function () { lowPriorityWarning$1(false, 'Factory.type is deprecated. Access the class directly ' + 'before passing it to createFactory.'); Object.defineProperty(this, 'type', { value: type }); return type; } }); } return validatedFactory; } function cloneElementWithValidation(element, props, children) { var newElement = cloneElement.apply(this, arguments); for (var i = 2; i < arguments.length; i++) { validateChildKeys(arguments[i], newElement.type); } validatePropTypes(newElement); return newElement; } /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ var REACT_FRAGMENT_TYPE = typeof Symbol === 'function' && Symbol['for'] && Symbol['for']('react.fragment') || 0xeacb; var React = { Children: { map: mapChildren, forEach: forEachChildren, count: countChildren, toArray: toArray, only: onlyChild }, Component: Component, PureComponent: PureComponent, unstable_AsyncComponent: AsyncComponent, createElement: createElementWithValidation, cloneElement: cloneElementWithValidation, createFactory: createFactoryWithValidation, isValidElement: isValidElement, version: ReactVersion, __SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED: { ReactCurrentOwner: ReactCurrentOwner, // Used by renderers to avoid bundling object-assign twice in UMD bundles: assign: objectAssign$1 } }; if (enableReactFragment) { React.Fragment = REACT_FRAGMENT_TYPE; } { objectAssign$1(React.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED, { // These should not be included in production. ReactDebugCurrentFrame: ReactDebugCurrentFrame, // Shim for React DOM 16.0.0 which still destructured (but not used) this. // TODO: remove in React 17.0. ReactComponentTreeHook: {} }); } var React$2 = Object.freeze({ default: React }); var React$3 = ( React$2 && React ) || React$2; /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. * * */ // TODO: decide on the top-level export form. // This is hacky but makes it work with both Rollup and Jest. var react = React$3['default'] ? React$3['default'] : React$3; return react; })));
web/src/containers/Home/index.js
shiyangzhaoa/call-club
import React from 'react'; import { Route, Switch, } from 'react-router-dom'; import NavBar from './../../components/NavBar'; import CategoryList from './../CategoryList'; const Home = (pros) => { return ( <NavBar> <Switch> <Route path="/" exact component={CategoryList} /> <Route path="/page/:pageNum?" exact component={CategoryList} /> <Route path="/category/:categorySlug/:pageNum?" exact component={CategoryList} /> </Switch> </NavBar> ); } export default Home;
node_modules/react-router/modules/Route.js
Zach417/churchetto-web
import React from 'react' import invariant from 'invariant' import { createRouteFromReactElement } from './RouteUtils' import { component, components } from './PropTypes' const { string, func } = React.PropTypes /** * A <Route> is used to declare which components are rendered to the * page when the URL matches a given pattern. * * Routes are arranged in a nested tree structure. When a new URL is * requested, the tree is searched depth-first to find a route whose * path matches the URL. When one is found, all routes in the tree * that lead to it are considered "active" and their components are * rendered into the DOM, nested in the same order as in the tree. */ const Route = React.createClass({ statics: { createRouteFromReactElement }, propTypes: { path: string, component, components, getComponent: func, getComponents: func }, /* istanbul ignore next: sanity check */ render() { invariant( false, '<Route> elements are for router configuration only and should not be rendered' ) } }) export default Route
ajax/libs/falcor/0.0.13/falcor.browser.js
redmunds/cdnjs
/*! * Copyright 2014 Netflix, Inc * * 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. */ (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);throw new Error("Cannot find module '"+o+"'")}var f=n[o]={exports:{}};t[o][0].call(f.exports,function(e){var n=t[o][1][e];return s(n?n:e)},f,f.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){ var falcor = require('./index'); var HttpDataSource = require('falcor-browser'); falcor.HttpDataSource = HttpDataSource; module.exports = falcor; },{"./index":2,"falcor-browser":149}],2:[function(require,module,exports){ var falcor = require('./lib/falcor'); var get = require('./lib/get'); var set = require('./lib/set'); var inv = require('./lib/invalidate'); var prototype = falcor.Model.prototype; prototype._getBoundValue = get.getBoundValue; prototype._getValueSync = get.getValueSync; prototype._getPathSetsAsValues = get.getAsValues; prototype._getPathSetsAsJSON = get.getAsJSON; prototype._getPathSetsAsPathMap = get.getAsPathMap; prototype._getPathSetsAsJSONG = get.getAsJSONG; prototype._getPathMapsAsValues = get.getAsValues; prototype._getPathMapsAsJSON = get.getAsJSON; prototype._getPathMapsAsPathMap = get.getAsPathMap; prototype._getPathMapsAsJSONG = get.getAsJSONG; prototype._setPathSetsAsJSON = set.setPathSetsAsJSON; prototype._setPathSetsAsJSONG = set.setPathSetsAsJSONG; prototype._setPathSetsAsPathMap = set.setPathSetsAsPathMap; prototype._setPathSetsAsValues = set.setPathSetsAsValues; prototype._setPathMapsAsJSON = set.setPathMapsAsJSON; prototype._setPathMapsAsJSONG = set.setPathMapsAsJSONG; prototype._setPathMapsAsPathMap = set.setPathMapsAsPathMap; prototype._setPathMapsAsValues = set.setPathMapsAsValues; prototype._setJSONGsAsJSON = set.setJSONGsAsJSON; prototype._setJSONGsAsJSONG = set.setJSONGsAsJSONG; prototype._setJSONGsAsPathMap = set.setJSONGsAsPathMap; prototype._setJSONGsAsValues = set.setJSONGsAsValues; prototype._invPathSetsAsJSON = inv.invPathSetsAsJSON; prototype._invPathSetsAsJSONG = inv.invPathSetsAsJSONG; prototype._invPathSetsAsPathMap = inv.invPathSetsAsPathMap; prototype._invPathSetsAsValues = inv.invPathSetsAsValues; // prototype._setCache = get.setCache; prototype._setCache = set.setCache; module.exports = falcor; },{"./lib/falcor":6,"./lib/get":48,"./lib/invalidate":77,"./lib/set":85}],3:[function(require,module,exports){ if (typeof falcor === 'undefined') { var falcor = {}; } var Rx = require('rx'); falcor.__Internals = {}; falcor.Observable = Rx.Observable; falcor.EXPIRES_NOW = 0; falcor.EXPIRES_NEVER = 1; /** * The current semVer'd data version of falcor. */ falcor.dataVersion = '0.1.0'; falcor.now = function now() { return Date.now(); }; falcor.NOOP = function() {}; module.exports = falcor; },{"rx":168}],4:[function(require,module,exports){ var falcor = require('./Falcor'); var RequestQueue = require('./request/RequestQueue'); var ImmediateScheduler = require('./scheduler/ImmediateScheduler'); var TimeoutScheduler = require('./scheduler/TimeoutScheduler'); var ERROR = require("../types/error"); var ModelResponse = require('./ModelResponse'); var call = require('./operations/call'); var operations = require('./operations'); var pathSyntax = require('falcor-path-syntax'); var getBoundValue = require('./../get/getBoundValue'); var slice = Array.prototype.slice; var $ref = require('./../types/path'); var $error = require('./../types/error'); var $sentinel = require('./../types/sentinel'); var Model = module.exports = falcor.Model = function Model(options) { if (!options) { options = {}; } this._materialized = options.materialized || false; this._boxed = options.boxed || false; this._treatErrorsAsValues = options.treatErrorsAsValues || false; this._dataSource = options.source; this._maxSize = options.maxSize || Math.pow(2, 53) - 1; this._collectRatio = options.collectRatio || 0.75; this._scheduler = new ImmediateScheduler(); this._request = new RequestQueue(this, this._scheduler); this._errorSelector = options.errorSelector || Model.prototype._errorSelector; this._router = options.router; this._root = options.root || { expired: [], allowSync: 0, unsafeMode: false }; if (options.cache && typeof options.cache === "object") { this.setCache(options.cache); } else { this._cache = {}; } this._path = []; }; Model.EXPIRES_NOW = falcor.EXPIRES_NOW; Model.EXPIRES_NEVER = falcor.EXPIRES_NEVER; Model.ref = function(path) { if (typeof path === 'string') { path = pathSyntax(path); } return {$type: $ref, value: path}; }; Model.error = function(error) { return {$type: $error, value: error}; }; Model.atom = function(value) { return {$type: $sentinel, value: value}; }; Model.prototype = { _boxed: false, _progressive: false, _errorSelector: function(x, y) { return y; }, get: operations("get"), set: operations("set"), invalidate: operations("invalidate"), call: call, getValue: function(path) { return this.get(path, function(x) { return x; }); }, setValue: function(path, value) { path = pathSyntax.fromPath(path); return this.set(Array.isArray(path) ? {path: path, value: value} : path, function(x) { return x; }); }, bind: function(boundPath) { var model = this, root = model._root, paths = new Array(arguments.length - 1), i = -1, n = arguments.length - 1; boundPath = pathSyntax.fromPath(boundPath); while(++i < n) { paths[i] = pathSyntax.fromPath(arguments[i + 1]); } if(n === 0) { throw new Error("Model#bind requires at least one value path."); } return falcor.Observable.create(function(observer) { var boundModel; root.allowSync++; try { boundModel = model.bindSync(model._path.concat(boundPath)); if (!boundModel) { throw false; } observer.onNext(boundModel); observer.onCompleted(); } catch (e) { return model.get.apply(model, paths.map(function(path) { return boundPath.concat(path); }).concat(function(){})).subscribe( function onNext() {}, function onError(err) { observer.onError(err); }, function onCompleted() { root.allowSync++; try { boundModel = model.bindSync(boundPath); if(boundModel) { observer.onNext(boundModel); } observer.onCompleted(); } catch(e) { observer.onError(e); } // remove the inc finally { root.allowSync--; } }); } // remove the inc finally { root.allowSync--; } }); }, setCache: function(cache) { return (this._cache = {}) && this._setCache(this, cache); }, getCache: function() { var pathmaps = [{}]; var tmpCache = this.boxValues().treatErrorsAsValues().materialize(); tmpCache._getPathMapsAsPathMap(tmpCache, [tmpCache._cache], pathmaps); return pathmaps[0].json; }, getValueSync: function(path) { path = pathSyntax.fromPath(path); if (Array.isArray(path) === false) { throw new Error("Model#getValueSync must be called with an Array path."); } if (this._path.length) { path = this._path.concat(path); } return this.syncCheck("getValueSync") && this._getValueSync(this, path).value; }, setValueSync: function(path, value, errorSelector) { path = pathSyntax.fromPath(path); if(Array.isArray(path) === false) { if(typeof errorSelector !== "function") { errorSelector = value || this._errorSelector; } value = path.value; path = path.path; } if(Array.isArray(path) === false) { throw new Error("Model#setValueSync must be called with an Array path."); } if(this.syncCheck("setValueSync")) { var json = {}; var tEeAV = this._treatErrorsAsValues; var boxed = this._boxed; this._treatErrorsAsValues = true; this._boxed = true; this._setPathSetsAsJSON(this, [{path: path, value: value}], [json], errorSelector); this._treatErrorsAsValues = tEeAV; this._boxed = boxed; json = json.json; if(json && json.$type === ERROR && !this._treatErrorsAsValues) { if(this._boxed) { throw json; } else { throw json.value; } } else if(this._boxed) { return json; } return json && json.value; } }, bindSync: function(path) { path = pathSyntax.fromPath(path); if(Array.isArray(path) === false) { throw new Error("Model#bindSync must be called with an Array path."); } var boundValue = this.syncCheck("bindSync") && getBoundValue(this, this._path.concat(path)); var node = boundValue.value; path = boundValue.path; if(boundValue.shorted) { if(!!node) { if(node.$type === ERROR) { if(this._boxed) { throw node; } throw node.value; // throw new Error("Model#bindSync can\'t bind to or beyond an error: " + boundValue.toString()); } } return undefined; } else if(!!node && node.$type === ERROR) { if(this._boxed) { throw node; } throw node.value; } return this.clone(["_path", boundValue.path]); }, clone: function() { var self = this; var clone = new Model(); var key, keyValue; var keys = Object.keys(self); var keysIdx = -1; var keysLen = keys.length; while(++keysIdx < keysLen) { key = keys[keysIdx]; clone[key] = self[key]; } var argsIdx = -1; var argsLen = arguments.length; while(++argsIdx < argsLen) { keyValue = arguments[argsIdx]; clone[keyValue[0]] = keyValue[1]; } return clone; }, batch: function(schedulerOrDelay) { if(typeof schedulerOrDelay === "number") { schedulerOrDelay = new TimeoutScheduler(Math.round(Math.abs(schedulerOrDelay))); } else if(!schedulerOrDelay || !schedulerOrDelay.schedule) { schedulerOrDelay = new ImmediateScheduler(); } return this.clone(["_request", new RequestQueue(this, schedulerOrDelay)]); }, unbatch: function() { return this.clone(["_request", new RequestQueue(this, new ImmediateScheduler())]); }, treatErrorsAsValues: function() { return this.clone(["_treatErrorsAsValues", true]); }, materialize: function() { return this.clone(["_materialized", true]); }, boxValues: function() { return this.clone(["_boxed", true]); }, unboxValues: function() { return this.clone(["_boxed", false]); }, withoutDataSource: function() { return this.clone(["_dataSource", null]); }, syncCheck: function(name) { if (!!this._dataSource && this._root.allowSync <= 0 && this._root.unsafeMode === false) { throw new Error("Model#" + name + " may only be called within the context of a request selector."); } return true; } }; },{"../types/error":135,"./../get/getBoundValue":45,"./../types/error":135,"./../types/path":136,"./../types/sentinel":137,"./Falcor":3,"./ModelResponse":5,"./operations":12,"./operations/call":7,"./request/RequestQueue":37,"./scheduler/ImmediateScheduler":38,"./scheduler/TimeoutScheduler":39,"falcor-path-syntax":152}],5:[function(require,module,exports){ var falcor = require('./Falcor'); var pathSyntax = require('falcor-path-syntax'); if(typeof Promise !== "undefined" && Promise) { falcor.Promise = Promise; } else { falcor.Promise = require("promise"); } var Observable = falcor.Observable, valuesMixin = { format: { value: "AsValues" } }, jsonMixin = { format: { value: "AsPathMap" } }, jsongMixin = { format: { value: "AsJSONG" } }, progressiveMixin = { operationIsProgressive: { value: true } }; function ModelResponse(forEach) { this._subscribe = forEach; } ModelResponse.create = function(forEach) { return new ModelResponse(forEach); }; ModelResponse.fromOperation = function(model, args, selector, forEach) { return new ModelResponse(function(observer) { return forEach(Object.create(observer, { operationModel: {value: model}, operationArgs: {value: pathSyntax.fromPathsOrPathValues(args)}, operationSelector: {value: selector} })); }); }; function noop() {} function mixin(self) { var mixins = Array.prototype.slice.call(arguments, 1); return new ModelResponse(function(other) { return self.subscribe(mixins.reduce(function(proto, mixin) { return Object.create(proto, mixin); }, other)); }); } ModelResponse.prototype = Observable.create(noop); ModelResponse.prototype.format = "AsPathMap"; ModelResponse.prototype.toPathValues = function() { return mixin(this, valuesMixin); }; ModelResponse.prototype.toJSON = function() { return mixin(this, jsonMixin); }; ModelResponse.prototype.progressively = function() { return mixin(this, progressiveMixin); }; ModelResponse.prototype.toJSONG = function() { return mixin(this, jsongMixin); }; ModelResponse.prototype.then = function(onNext, onError) { var self = this; return new falcor.Promise(function(resolve, reject) { setTimeout(function() { var value = undefined; var error = undefined; self.toArray().subscribe( function(values) { if(values.length <= 1) { value = values[0]; } else { value = values; } }, function(errors) { if(errors.length <= 1) { error = errors[0]; } else { error = errors; } resolve = undefined; }, function() { if(!!resolve) { resolve(value); } else { reject(error); } } ); }, 0); }).then(onNext, onError); }; module.exports = ModelResponse; },{"./Falcor":3,"falcor-path-syntax":152,"promise":158}],6:[function(require,module,exports){ var falcor = require('./Falcor'); var Model = require('./Model'); falcor.Model = Model; module.exports = falcor; },{"./Falcor":3,"./Model":4}],7:[function(require,module,exports){ module.exports = call; var falcor = require("../../Falcor"); var ModelResponse = require('./../../ModelResponse'); function call(path, args, suffixes, paths, selector) { var model = this; args && Array.isArray(args) || (args = []); suffixes && Array.isArray(suffixes) || (suffixes = []); paths = Array.prototype.slice.call(arguments, 3); if (typeof (selector = paths[paths.length - 1]) !== "function") { selector = undefined; } else { paths = paths.slice(0, -1); } return ModelResponse.create(function (options) { var rootModel = model.clone(["_path", []]), localRoot = rootModel.withoutDataSource(), dataSource = model._dataSource, boundPath = model._path, callPath = boundPath.concat(path), thisPath = callPath.slice(0, -1); var disposable = model. getValue(path). flatMap(function (localFn) { if (typeof localFn === "function") { return falcor.Observable.return(localFn. apply(rootModel.bindSync(thisPath), args). map(function (pathValue) { return { path: thisPath.concat(pathValue.path), value: pathValue.value }; }). toArray(). flatMap(function (pathValues) { return localRoot.set. apply(localRoot, pathValues). toJSONG(); }). flatMap(function (envelope) { return rootModel.get.apply(rootModel, envelope.paths.reduce(function (paths, path) { return paths.concat(suffixes.map(function (suffix) { return path.concat(suffix); })); }, []). concat(paths.reduce(function (paths, path) { return paths.concat(thisPath.concat(path)); }, []))). toJSONG(); })); } return falcor.Observable.empty(); }). defaultIfEmpty(dataSource.call(path, args, suffixes, paths)). mergeAll(). subscribe(function (envelope) { var invalidated = envelope.invalidated; if (invalidated && invalidated.length) { invalidatePaths(rootModel, invalidated, undefined, model._errorSelector); } disposable = localRoot. set(envelope, function () { return model; }). subscribe(function (model) { var getPaths = envelope.paths.map(function (path) { return path.slice(boundPath.length); }); if (selector) { getPaths[getPaths.length] = function () { return selector.call(model, getPaths); }; } disposable = model.get.apply(model, getPaths).subscribe(options); }); }); return { dispose: function () { disposable && disposable.dispose(); disposable = undefined; } }; }); } },{"../../Falcor":3,"./../../ModelResponse":5}],8:[function(require,module,exports){ var combineOperations = require('./../support/combineOperations'); var setSeedsOrOnNext = require('./../support/setSeedsOrOnNext'); /** * The initial args that are passed into the async request pipeline. * @see lib/falcor/operations/request.js for how initialArgs are used */ module.exports = function getInitialArgs(options, seeds, onNext) { var seedRequired = options.format !== 'AsValues'; var isProgressive = options.operationIsProgressive; var spreadOperations = false; var operations = combineOperations( options.operationArgs, options.format, 'get', spreadOperations, isProgressive); setSeedsOrOnNext( operations, seedRequired, seeds, onNext, options.operationSelector); var requestOptions; return [operations]; }; },{"./../support/combineOperations":23,"./../support/setSeedsOrOnNext":36}],9:[function(require,module,exports){ var getSourceObserver = require('./../support/getSourceObserever'); var partitionOperations = require('./../support/partitionOperations'); var mergeBoundPath = require('./../support/mergeBoundPath'); module.exports = getSourceRequest; function getSourceRequest( options, onNext, seeds, combinedResults, requestOptions, cb) { var model = options.operationModel; var boundPath = model._path; var missingPaths = combinedResults.requestedMissingPaths; if (boundPath.length) { for (var i = 0; i < missingPaths.length; ++i) { var pathSetIndex = missingPaths[i].pathSetIndex; var path = missingPaths[i] = boundPath.concat(missingPaths[i]); path.pathSetIndex = pathSetIndex; } } return model._request.get( missingPaths, combinedResults.optimizedMissingPaths, getSourceObserver( model, missingPaths, function getSourceCallback(err, results) { if (err) { cb(err); return; } // partitions the operations by their pathSetIndex var partitionOperationsAndSeeds = partitionOperations( results, seeds, options.format, onNext); // We allow for the rerequesting to happen. cb(null, partitionOperationsAndSeeds); })); } },{"./../support/getSourceObserever":24,"./../support/mergeBoundPath":28,"./../support/partitionOperations":31}],10:[function(require,module,exports){ var getInitialArgs = require('./getInitialArgs'); var getSourceRequest = require('./getSourceRequest'); var shouldRequest = require('./shouldRequest'); var request = require('./../request'); var processOperations = require('./../support/processOperations'); var get = request( getInitialArgs, getSourceRequest, processOperations, shouldRequest); module.exports = get; },{"./../request":15,"./../support/processOperations":33,"./getInitialArgs":8,"./getSourceRequest":9,"./shouldRequest":11}],11:[function(require,module,exports){ module.exports = function(model, combinedResults) { return model._dataSource && combinedResults.requestedMissingPaths.length > 0; }; },{}],12:[function(require,module,exports){ var ModelResponse = require('../ModelResponse'); var get = require('./get'); var set = require('./set'); var invalidate = require('./invalidate'); module.exports = function modelOperation(name) { return function() { var model = this, root = model._root, args = Array.prototype.slice.call(arguments), selector = args[args.length - 1]; if (typeof selector === 'function') { args.pop(); } else { selector = false; } var modelResponder; switch (name) { case 'get': modelResponder = get; break; case 'set': modelResponder = set; break; case 'invalidate': modelResponder = invalidate; break; } return ModelResponse.fromOperation( model, args, selector, modelResponder); }; }; },{"../ModelResponse":5,"./get":10,"./invalidate":13,"./set":16}],13:[function(require,module,exports){ var invalidateInitialArgs = require('./invalidateInitialArgs'); var request = require('./../request'); var processOperations = require('./../support/processOperations'); var invalidate = request( invalidateInitialArgs, null, processOperations); module.exports = invalidate; },{"./../request":15,"./../support/processOperations":33,"./invalidateInitialArgs":14}],14:[function(require,module,exports){ var combineOperations = require('./../support/combineOperations'); var setSeedsOrOnNext = require('./../support/setSeedsOrOnNext'); module.exports = function getInitialArgs(options, seeds, onNext) { var seedRequired = options.format !== 'AsValues'; var operations = combineOperations( options.operationArgs, options.format, 'inv'); setSeedsOrOnNext( operations, seedRequired, seeds, onNext, options.operationSelector); return [operations, seeds]; }; },{"./../support/combineOperations":23,"./../support/setSeedsOrOnNext":36}],15:[function(require,module,exports){ var setSeedsOrOnNext = require('./support/setSeedsOrOnNext'); var onNextValues = require('./support/onNextValue'); var onCompletedOrError = require('./support/onCompletedOrError'); var primeSeeds = require('./support/primeSeeds'); var autoFalse = function() { return false; }; module.exports = request; function request(initialArgs, sourceRequest, processOperations, shouldRequestFn) { if (!shouldRequestFn) { shouldRequestFn = autoFalse; } return function innerRequest(options) { var selector = options.operationSelector; var model = options.operationModel; var args = options.operationArgs; var onNext = options.onNext.bind(options); var onError = options.onError.bind(options); var onCompleted = options.onCompleted.bind(options); var isProgressive = options.operationIsProgressive; var errorSelector = model._errorSelector; var selectorLength = selector && selector.length || 0; // State variables var errors = []; var format = options.format = selector && 'AsJSON' || options.format || 'AsPathMap'; var toJSONG = format === 'AsJSONG'; var toJSON = format === 'AsPathMap'; var toPathValues = format === 'AsValues'; var seedRequired = toJSON || toJSONG || selector; var boundPath = model._path; var i, len; var foundValue = false; var seeds = primeSeeds(selector, selectorLength); var loopCount = 0; function recurse(operations, opts) { if (loopCount > 50) { throw 'Loop Kill switch thrown.'; } var combinedResults = processOperations( model, operations, errorSelector, opts); foundValue = foundValue || combinedResults.valuesReceived; if (combinedResults.errors.length) { errors = errors.concat(combinedResults.errors); } // if in progressiveMode, values are emitted // each time through the recurse loop. This may have // to change when the router is considered. if (isProgressive && !toPathValues) { onNextValues(model, onNext, seeds, selector); } // Performs the recursing via dataSource if (shouldRequestFn(model, combinedResults, loopCount)) { sourceRequest( options, onNext, seeds, combinedResults, opts, function onCompleteFromSourceSet(err, results) { if (err) { errors = errors.concat(err); recurse([], seeds); return; } ++loopCount; // We continue to string the opts through recurse(results, opts); }); } // Else we need to onNext values and complete/error. else { if (!toPathValues && !isProgressive && foundValue) { onNextValues(model, onNext, seeds, selector); } onCompletedOrError(onCompleted, onError, errors); } } try { recurse.apply(null, initialArgs(options, seeds, onNext)); } catch(e) { errors = [e]; onCompletedOrError(onCompleted, onError, errors); } }; } },{"./support/onCompletedOrError":29,"./support/onNextValue":30,"./support/primeSeeds":32,"./support/setSeedsOrOnNext":36}],16:[function(require,module,exports){ var setInitialArgs = require('./setInitialArgs'); var setSourceRequest = require('./setSourceRequest'); var request = require('./../request'); var setProcessOperations = require('./setProcessOperations'); var shouldRequest = require('./shouldRequest'); var set = request( setInitialArgs, setSourceRequest, setProcessOperations, shouldRequest); module.exports = set; },{"./../request":15,"./setInitialArgs":17,"./setProcessOperations":18,"./setSourceRequest":19,"./shouldRequest":20}],17:[function(require,module,exports){ var combineOperations = require('./../support/combineOperations'); var setSeedsOrOnNext = require('./../support/setSeedsOrOnNext'); var Formats = require('./../support/Formats'); var toPathValues = Formats.toPathValues; var toJSONG = Formats.toJSONG; module.exports = function setInitialArgs(options, seeds, onNext) { var isPathValues = options.format === toPathValues; var seedRequired = !isPathValues; var shouldRequest = !!options.operationModel._dataSource; var format = options.format; var args = options.operationArgs; var selector = options.operationSelector; var isProgressive = options.operationIsProgressive; var firstSeeds, operations; var requestOptions = { removeBoundPath: shouldRequest }; // If Model is a slave, in shouldRequest mode, // a single seed is required to accumulate the jsong results. if (shouldRequest) { operations = combineOperations(args, toJSONG, 'set', selector, false); firstSeeds = [{}]; setSeedsOrOnNext( operations, true, firstSeeds, false, options.selector); // we must keep track of the set seeds. requestOptions.requestSeed = firstSeeds[0]; } // This model is the master, therefore a regular set can be performed. else { firstSeeds = seeds; operations = combineOperations(args, format, 'set'); setSeedsOrOnNext( operations, seedRequired, seeds, onNext, options.operationSelector); } // We either have to construct the master operations if // the ModelResponse is isProgressive // the ModelResponse is toPathValues // but luckily we can just perform a get for the progressive or // toPathValues mode. if (isProgressive || isPathValues) { var getOps = combineOperations( args, format, 'get', selector, true); setSeedsOrOnNext( getOps, seedRequired, seeds, onNext, options.operationSelector); operations = operations.concat(getOps); requestOptions.isProgressive = true; } return [operations, requestOptions]; }; },{"./../support/Formats":21,"./../support/combineOperations":23,"./../support/setSeedsOrOnNext":36}],18:[function(require,module,exports){ var processOperations = require('./../support/processOperations'); var combineOperations = require('./../support/combineOperations'); var mergeBoundPath = require('./../support/mergeBoundPath'); var Formats = require('./../support/Formats'); var toPathValues = Formats.toPathValues; module.exports = setProcessOperations; function setProcessOperations(model, operations, errorSelector, requestOptions) { var boundPath = model._path; var hasBoundPath = boundPath.length > 0; var removeBoundPath = requestOptions && requestOptions.removeBoundPath; var isProgressive = requestOptions && requestOptions.isProgressive; var progressiveOperations; // if in progressive mode, then the progressive operations // need to be executed but the bound path must stay intact. if (isProgressive && removeBoundPath && hasBoundPath) { progressiveOperations = operations.filter(function(op) { return op.isProgressive; }); operations = operations.filter(function(op) { return !op.isProgressive; }); } if (removeBoundPath && hasBoundPath) { model._path = []; // For every operations arguments, the bound path must be adjusted. for (var i = 0, opLen = operations.length; i < opLen; i++) { var args = operations[i].args; for (var j = 0, argsLen = args.length; j < argsLen; j++) { args[j] = mergeBoundPath(args[j], boundPath); } } } var results = processOperations(model, operations, errorSelector); // Undo what we have done to the model's bound path. if (removeBoundPath && hasBoundPath) { model._path = boundPath; } // executes the progressive ops if (progressiveOperations) { processOperations(model, progressiveOperations, errorSelector); } return results; } },{"./../support/Formats":21,"./../support/combineOperations":23,"./../support/mergeBoundPath":28,"./../support/processOperations":33}],19:[function(require,module,exports){ var getSourceObserver = require('./../support/getSourceObserever'); var combineOperations = require('./../support/combineOperations'); var setSeedsOrOnNext = require('./../support/setSeedsOrOnNext'); var toPathValues = require('./../support/Formats').toPathValues; module.exports = setSourceRequest; function setSourceRequest( options, onNext, seeds, combinedResults, requestOptions, cb) { var model = options.operationModel; var seedRequired = options.format !== toPathValues; var requestSeed = requestOptions.requestSeed; return model._request.set( requestSeed, getSourceObserver( model, requestSeed.paths, function setSourceRequestCB(err, results) { if (err) { cb(err); } // Sets the results into the model. model._setJSONGsAsJSON(model, [results], []); // Gets the original paths / maps back out. var operations = combineOperations( options.operationArgs, options.format, 'get'); setSeedsOrOnNext( operations, seedRequired, seeds, onNext, options.operationSelector); // unset the removeBoundPath. requestOptions.removeBoundPath = false; cb(null, operations); })); } },{"./../support/Formats":21,"./../support/combineOperations":23,"./../support/getSourceObserever":24,"./../support/setSeedsOrOnNext":36}],20:[function(require,module,exports){ // Set differs from get in the sense that the first time through // the recurse loop a server operation must be performed if it can be. module.exports = function(model, combinedResults, loopCount) { return model._dataSource && ( combinedResults.requestedMissingPaths.length > 0 || loopCount === 0); }; },{}],21:[function(require,module,exports){ module.exports = { toPathValues: 'AsValues', toJSON: 'AsPathMap', toJSONG: 'AsJSONG', selector: 'AsJSON', }; },{}],22:[function(require,module,exports){ module.exports = function buildJSONGOperation(format, seeds, jsongOp, seedOffset, onNext) { return { methodName: '_setJSONGs' + format, format: format, isValues: format === 'AsValues', onNext: onNext, seeds: seeds, seedsOffset: seedOffset, args: [jsongOp] }; }; },{}],23:[function(require,module,exports){ var isSeedRequired = require('./seedRequired'); var isJSONG = require('./isJSONG'); var isPathOrPathValue = require('./isPathOrPathValue'); var Formats = require('./Formats'); var toSelector = Formats.selector; module.exports = function combineOperations(args, format, name, spread, isProgressive) { var seedRequired = isSeedRequired(format); var isValues = !seedRequired; var hasSelector = seedRequired && format === toSelector; var seedsOffset = 0; return args. reduce(function(groups, argument) { var group = groups[groups.length - 1]; var type = isPathOrPathValue(argument) ? "PathSets" : isJSONG(argument) ? "JSONGs" : "PathMaps"; var groupType = group && group.type; var methodName = '_' + name + type + format; if (!groupType || type !== groupType || spread) { group = { methodName: methodName, format: format, operation: name, isValues: isValues, seeds: [], onNext: null, seedsOffset: seedsOffset, isProgressive: isProgressive, type: type, args: [] }; groups.push(group); } if (hasSelector) { ++seedsOffset; } group.args.push(argument); return groups; }, []); }; },{"./Formats":21,"./isJSONG":26,"./isPathOrPathValue":27,"./seedRequired":34}],24:[function(require,module,exports){ var insertErrors = require('./insertErrors.js'); /** * creates the model source observer * @param {Model} model * @param {Array.<Array>} requestedMissingPaths * @param {Function} cb */ function getSourceObserver(model, requestedMissingPaths, cb) { var incomingValues; return { onNext: function(jsongEnvelop) { incomingValues = { jsong: jsongEnvelop.jsong, paths: requestedMissingPaths }; }, onError: function(err) { cb(insertErrors(model, requestedMissingPaths, err)); }, onCompleted: function() { cb(false, incomingValues); } }; } module.exports = getSourceObserver; },{"./insertErrors.js":25}],25:[function(require,module,exports){ /** * will insert the error provided for every requestedPath. * @param {Model} model * @param {Array.<Array>} requestedPaths * @param {Object} err */ module.exports = function insertErrors(model, requestedPaths, err) { var out = model._setPathSetsAsJSON.apply(null, [model].concat( requestedPaths. reduce(function(acc, r) { acc[0].push({ path: r, value: err }); return acc; }, [[]]), [], model._errorSelector )); return out.errors; }; },{}],26:[function(require,module,exports){ module.exports = function isJSONG(x) { return x.hasOwnProperty("jsong"); }; },{}],27:[function(require,module,exports){ module.exports = function isPathOrPathValue(x) { return !!(Array.isArray(x)) || ( x.hasOwnProperty("path") && x.hasOwnProperty("value")); }; },{}],28:[function(require,module,exports){ var isJSONG = require('./isJSONG'); var isPathValue = require('./isPathOrPathValue'); module.exports = mergeBoundPath; function mergeBoundPath(arg, boundPath) { return isJSONG(arg) && mergeBoundPathIntoJSONG(arg, boundPath) || isPathValue(arg) && mergeBoundPathIntoPathValue(arg, boundPath) || mergeBoundPathIntoJSON(arg, boundPath); } function mergeBoundPathIntoJSONG(jsongEnv, boundPath) { var newJSONGEnv = {jsong: jsongEnv.jsong, paths: jsongEnv.paths}; if (boundPath.length) { var paths = []; for (i = 0, len = jsongEnv.paths.length; i < len; i++) { paths[i] = boundPath.concat(jsongEnv.paths[i]); } newJSONGEnv.paths = paths; } return newJSONGEnv; } function mergeBoundPathIntoJSON(arg, boundPath) { var newArg = arg; if (boundPath.length) { newArg = {}; for (var i = 0, len = boundPath.length - 1; i < len; i++) { newArg[boundPath[i]] = {}; } newArg[boundPath[i]] = arg; } return newArg; } function mergeBoundPathIntoPathValue(arg, boundPath) { return { path: boundPath.concat(arg.path), value: arg.value }; } },{"./isJSONG":26,"./isPathOrPathValue":27}],29:[function(require,module,exports){ module.exports = function onCompletedOrError(onCompleted, onError, errors) { if (errors.length) { onError(errors); } else { onCompleted(); } }; },{}],30:[function(require,module,exports){ /** * will onNext the observer with the seeds provided. * @param {Model} model * @param {Function} onNext * @param {Array.<Object>} seeds * @param {Function} [selector] */ module.exports = function onNextValues(model, onNext, seeds, selector) { var root = model._root; root.allowSync++; try { if (selector) { if (seeds.length) { // they should be wrapped in json items onNext(selector.apply(model, seeds.map(function(x, i) { return x.json; }))); } else { onNext(selector.call(model)); } } else { // this means there is an onNext function that is not AsValues or progressive, // therefore there must only be one onNext call, which should only be the 0 // index of the values of the array onNext(seeds[0]); } } catch(e) { } finally { root.allowSync--; } }; },{}],31:[function(require,module,exports){ var buildJSONGOperation = require('./buildJSONGOperation'); /** * It performs the opposite of combine operations. It will take a JSONG * response and partition them into the required amount of operations. * @param {{jsong: {}, paths:[]}} jsongResponse */ module.exports = partitionOperations; function partitionOperations( jsongResponse, seeds, format, onNext) { var partitionedOps = []; var requestedMissingPaths = jsongResponse.paths; if (format === 'AsJSON') { // fast collapse ass the requestedMissingPaths into their // respective groups var opsFromRequestedMissingPaths = []; var op = null; for (var i = 0, len = requestedMissingPaths.length; i < len; i++) { var missingPath = requestedMissingPaths[i]; if (!op || op.idx !== missingPath.pathSetIndex) { op = { idx: missingPath.pathSetIndex, paths: [] }; opsFromRequestedMissingPaths.push(op); } op.paths.push(missingPath); } opsFromRequestedMissingPaths.forEach(function(op, i) { var seed = [seeds[op.idx]]; var jsong = { jsong: jsongResponse.jsong, paths: op.paths }; partitionedOps.push(buildJSONGOperation( format, seed, jsong, op.idx, onNext)); }); } else { partitionedOps[0] = buildJSONGOperation(format, seeds, jsongResponse, 0, onNext); } return partitionedOps; } },{"./buildJSONGOperation":22}],32:[function(require,module,exports){ module.exports = function primeSeeds(selector, selectorLength) { var seeds = []; if (selector) { for (i = 0; i < selectorLength; i++) { seeds.push({}); } } else { seeds[0] = {}; } return seeds; }; },{}],33:[function(require,module,exports){ module.exports = function processOperations(model, operations, errorSelector, boundPath) { return operations.reduce(function(memo, operation) { var jsonGraphOperation = model[operation.methodName]; var seedsOrFunction = operation.isValues ? operation.onNext : operation.seeds; var results = jsonGraphOperation( model, operation.args, seedsOrFunction, operation.onNext, errorSelector, boundPath); var missing = results.requestedMissingPaths; var offset = operation.seedsOffset; for (var i = 0, len = missing.length; i < len; i++) { missing[i].boundPath = boundPath; missing[i].pathSetIndex += offset; } memo.requestedMissingPaths = memo.requestedMissingPaths.concat(missing); memo.optimizedMissingPaths = memo.optimizedMissingPaths.concat(results.optimizedMissingPaths); memo.errors = memo.errors.concat(results.errors); memo.valuesReceived = memo.valuesReceived || results.requestedPaths.length > 0; return memo; }, { errors: [], requestedMissingPaths: [], optimizedMissingPaths: [], valuesReceived: false }); } },{}],34:[function(require,module,exports){ module.exports = function isSeedRequired(format) { return format === 'AsJSON' || format === 'AsJSONG' || format === 'AsPathMap'; }; },{}],35:[function(require,module,exports){ module.exports = function setSeedsOnGroups(groups, seeds, hasSelector) { var valueIndex = 0; var seedsLength = seeds.length; var j, i, len = groups.length, gLen, group; if (hasSelector) { for (i = 0; i < len && valueIndex < seedsLength; i++) { group = groups[i]; gLen = gLen = group.args.length; for (j = 0; j < gLen && valueIndex < seedsLength; j++, valueIndex++) { group.seeds.push(seeds[valueIndex]); } } } else { for (i = 0; i < len && valueIndex < seedsLength; i++) { groups[i].seeds = seeds; } } } },{}],36:[function(require,module,exports){ var setSeedsOnGroups = require('./setSeedsOnGroups'); module.exports = function setSeedsOrOnNext(operations, seedRequired, seeds, onNext, selector) { if (seedRequired) { setSeedsOnGroups(operations, seeds, selector); } else { for (i = 0; i < operations.length; i++) { operations[i].onNext = onNext; } } }; },{"./setSeedsOnGroups":35}],37:[function(require,module,exports){ var falcor = require('./../Falcor'); var NOOP = falcor.NOOP; var RequestQueue = function(jsongModel, scheduler) { this._scheduler = scheduler; this._jsongModel = jsongModel; this._scheduled = false; this._requests = []; }; RequestQueue.prototype = { _get: function() { var i = -1; var requests = this._requests; while (++i < requests.length) { if (!requests[i].pending && requests[i].isGet) { return requests[i]; } } return requests[requests.length] = new GetRequest(this._jsongModel, this); }, _set: function() { var i = -1; var requests = this._requests; // TODO: Set always sends off a request immediately, so there is no batching. while (++i < requests.length) { if (!requests[i].pending && requests[i].isSet) { return requests[i]; } } return requests[requests.length] = new SetRequest(this._jsongModel, this); }, remove: function(request) { for (var i = this._requests.length - 1; i > -1; i--) { if (this._requests[i].id === request.id && this._requests.splice(i, 1)) { break; } } }, set: function(jsongEnv, observer) { var self = this; var disposable = self._set().batch(jsongEnv, observer).flush(); return { dispose: function() { disposable.dispose(); } }; }, get: function(requestedPaths, optimizedPaths, observer) { var self = this; var disposable = null; // TODO: get does not batch across requests. self._get().batch(requestedPaths, optimizedPaths, observer); if (!self._scheduled) { self._scheduled = true; disposable = self._scheduler.schedule(self._flush.bind(self)); } return { dispose: function() { disposable.dispose(); } }; }, _flush: function() { this._scheduled = false; var requests = this._requests, i = -1; var disposables = []; while (++i < requests.length) { if (!requests[i].pending) { disposables[disposables.length] = requests[i].flush(); } } return { dispose: function() { disposables.forEach(function(d) { d.dispose(); }); } }; } }; var REQUEST_ID = 0; var SetRequest = function(model, queue) { var self = this; self._jsongModel = model; self._queue = queue; self.observers = []; self.jsongEnvs = []; self.pending = false; self.id = ++REQUEST_ID; self.isSet = true; }; SetRequest.prototype = { batch: function(jsongEnv, observer) { var self = this; observer.onNext = observer.onNext || NOOP; observer.onError = observer.onError || NOOP; observer.onCompleted = observer.onCompleted || NOOP; if (!observer.__observerId) { observer.__observerId = ++REQUEST_ID; } observer._requestId = self.id; self.observers[self.observers.length] = observer; self.jsongEnvs[self.jsongEnvs.length] = jsongEnv; return self; }, flush: function() { var incomingValues, query, op, len; var self = this; var jsongs = self.jsongEnvs; var observers = self.observers; var model = self._jsongModel; self.pending = true; // TODO: Set does not batch. return model._dataSource. set(jsongs[0]). subscribe(function(response) { incomingValues = response; }, function(err) { var i = -1; var n = observers.length; while (++i < n) { obs = observers[i]; obs.onError && obs.onError(err); } }, function() { var i, n, obs; self._queue.remove(self); i = -1; n = observers.length; while (++i < n) { obs = observers[i]; obs.onNext && obs.onNext({ jsong: incomingValues.jsong || incomingValues.value, paths: incomingValues.paths }); obs.onCompleted && obs.onCompleted(); } }); } }; var GetRequest = function(jsongModel, queue) { var self = this; self._jsongModel = jsongModel; self._queue = queue; self.observers = []; self.optimizedPaths = []; self.requestedPaths = []; self.pending = false; self.id = ++REQUEST_ID; self.isGet = true; }; GetRequest.prototype = { batch: function(requestedPaths, optimizedPaths, observer) { // TODO: Do we need to gap fill? var self = this; observer.onNext = observer.onNext || NOOP; observer.onError = observer.onError || NOOP; observer.onCompleted = observer.onCompleted || NOOP; if (!observer.__observerId) { observer.__observerId = ++REQUEST_ID; } observer._requestId = self.id; self.observers[self.observers.length] = observer; self.optimizedPaths[self.optimizedPaths.length] = optimizedPaths; self.requestedPaths[self.requestedPaths.length] = requestedPaths; return self; }, flush: function() { var incomingValues, query, op, len; var self = this; var requested = self.requestedPaths; var optimized = self.optimizedPaths; var observers = self.observers; var disposables = []; var results = []; var model = self._jsongModel; self._scheduled = false; self.pending = true; var optimizedMaps = {}; var requestedMaps = {}; var r, o, i, j, obs, resultIndex; for (i = 0, len = requested.length; i < len; i++) { r = requested[i]; o = optimized[i]; obs = observers[i]; for (j = 0; j < r.length; j++) { pathsToMapWithObservers(r[j], 0, readyNode(requestedMaps, null, obs), obs); pathsToMapWithObservers(o[j], 0, readyNode(optimizedMaps, null, obs), obs); } } return model._dataSource. get(collapse(optimizedMaps)). subscribe(function(response) { incomingValues = response; }, function(err) { var i = -1; var n = observers.length; while (++i < n) { obs = observers[i]; obs.onError && obs.onError(err); } }, function() { var i, n, obs; self._queue.remove(self); i = -1; n = observers.length; while (++i < n) { obs = observers[i]; obs.onNext && obs.onNext({ jsong: incomingValues.jsong || incomingValues.value, paths: incomingValues.paths }); obs.onCompleted && obs.onCompleted(); } }); }, // Returns the paths that are contained within this request. contains: function(requestedPaths, optimizedPaths) { // TODO: } }; function pathsToMapWithObservers(path, idx, branch, observer) { var curr = path[idx]; // Object / Array if (typeof curr === 'object') { if (Array.isArray(curr)) { curr.forEach(function(v) { readyNode(branch, v, observer); if (path.length > idx + 1) { pathsToMapWithObservers(path, idx + 1, branch[v], observer); } }); } else { var from = curr.from || 0; var to = curr.to >= 0 ? curr.to : curr.length; for (var i = from; i <= to; i++) { readyNode(branch, i, observer); if (path.length > idx + 1) { pathsToMapWithObservers(path, idx + 1, branch[i], observer); } } } } else { readyNode(branch, curr, observer); if (path.length > idx + 1) { pathsToMapWithObservers(path, idx + 1, branch[curr], observer); } } } /** * Builds the set of collapsed * queries by traversing the tree * once */ var charPattern = /\D/i; function readyNode(branch, key, observer) { if (key === null) { branch.__observers = branch.__observers || []; !containsObserver(branch.__observers, observer) && branch.__observers.push(observer); return branch; } if (!branch[key]) { branch[key] = {__observers: []}; } !containsObserver(branch[key].__observers, observer) && branch[key].__observers.push(observer); return branch; } function containsObserver(observers, observer) { if (!observer) { return; } return observers.reduce(function(acc, x) { return acc || x.__observerId === observer.__observerId; }, false); } function collapse(pathMap) { return rangeCollapse(buildQueries(pathMap)); } /** * Collapse ranges, e.g. when there is a continuous range * in an array, turn it into an object instead * * [1,2,3,4,5,6] => {"from":1, "to":6} * */ function rangeCollapse(paths) { paths.forEach(function (path) { path.forEach(function (elt, index) { var range; if (Array.isArray(elt) && elt.every(isNumber) && allUnique(elt)) { elt.sort(function(a, b) { return a - b; }); if (elt[elt.length-1] - elt[0] === elt.length-1) { // create range range = {}; range.from = elt[0]; range.to = elt[elt.length-1]; path[index] = range; } } }); }); return paths; } /* jshint forin: false */ function buildQueries(root) { if (root == null || typeof root !== 'object') { return [ [] ]; } var children = Object.keys(root).filter(notPathMapInternalKeys), child, memo, paths, key, childIsNum, list, head, tail, clone, results, i = -1, n = children.length, j, k, x; if (n === 0 || Array.isArray(root) === true) { return [ [] ]; } memo = {}; while(++i < n) { child = children[i]; paths = buildQueries(root[child]); key = createKey(paths); childIsNum = typeof child === 'string' && !charPattern.test(child); if ((list = memo[key]) && (head = list.head)) { head[head.length] = childIsNum ? parseInt(child, 10) : child; } else { memo[key] = { head: [childIsNum ? parseInt(child, 10) : child], tail: paths }; } } results = []; for(x in memo) { head = (list = memo[x]).head; tail = list.tail; i = -1; n = tail.length; while(++i < n) { list = tail[i]; j = -1; k = list.length; if(head[0] === '') { clone = []; } else { clone = [head.length === 1 ? head[0] : head]; while(++j < k) { clone[j + 1] = list[j]; } } results[results.length] = clone; } } return results; } function notPathMapInternalKeys(key) { return ( key !== "__observers" && key !== "__pending" && key !== "__batchID" ); } /** * Return true if argument is a number */ function isNumber(val) { return typeof val === "number"; } /** * allUnique * return true if every number in an array is unique */ function allUnique(arr) { var hash = {}, index, len; for (index = 0, len = arr.length; index < len; index++) { if (hash[arr[index]]) { return false; } hash[arr[index]] = true; } return true; } /** * Sort a list-of-lists * Used for generating a unique hash * key for each subtree; used by the * memoization */ function sortLol(lol) { return lol.reduce(function (result, curr) { if (curr instanceof Array) { result.push(sortLol(curr).slice(0).sort()); return result; } return result.concat(curr); }, []).slice(0).sort(); } /** * Create a unique hash key for a set * of paths */ function createKey(list) { return JSON.stringify(sortLol(list)); } // Note: For testing falcor.__Internals.buildQueries = buildQueries; module.exports = RequestQueue; },{"./../Falcor":3}],38:[function(require,module,exports){ function ImmediateScheduler() { } ImmediateScheduler.prototype = { schedule: function(action) { action(); } }; module.exports = ImmediateScheduler; },{}],39:[function(require,module,exports){ function TimeoutScheduler(delay) { this.delay = delay; } TimeoutScheduler.prototype = { schedule: function(action) { setTimeout(action, this.delay); } }; module.exports = TimeoutScheduler; },{}],40:[function(require,module,exports){ var hardLink = require('./util/hardlink'); var createHardlink = hardLink.create; var onValue = require('./onValue'); var isExpired = require('./util/isExpired'); var $path = require('./../types/path.js'); var __context = require("../internal/context"); function followReference(model, root, node, referenceContainer, reference, seed, outputFormat) { var depth = 0; var k, next; while (true) { if (depth === 0 && referenceContainer[__context]) { depth = reference.length; next = referenceContainer[__context]; } else { k = reference[depth++]; next = node[k]; } if (next) { var type = next.$type; var value = type && next.value || next; if (depth < reference.length) { if (type) { node = next; break; } node = next; continue; } // We need to report a value or follow another reference. else { node = next; if (type && isExpired(next)) { break; } if (!referenceContainer[__context]) { createHardlink(referenceContainer, next); } // Restart the reference follower. if (type === $path) { if (outputFormat === 'JSONG') { onValue(model, next, seed, null, null, reference, null, outputFormat); } depth = 0; reference = value; referenceContainer = next; node = root; continue; } break; } } else { node = undefined; } break; } if (depth < reference.length && node !== undefined) { var ref = []; for (var i = 0; i < depth; i++) { ref[i] = reference[i]; } reference = ref; } return [node, reference]; } module.exports = followReference; },{"../internal/context":62,"./../types/path.js":136,"./onValue":52,"./util/hardlink":54,"./util/isExpired":55}],41:[function(require,module,exports){ var getBoundValue = require('./getBoundValue'); var isPathValue = require('./util/isPathValue'); module.exports = function(walk) { return function getAsJSON(model, paths, values) { var results = { values: [], errors: [], requestedPaths: [], optimizedPaths: [], requestedMissingPaths: [], optimizedMissingPaths: [] }; var requestedMissingPaths = results.requestedMissingPaths; var inputFormat = Array.isArray(paths[0]) || isPathValue(paths[0]) ? 'Paths' : 'JSON'; var cache = model._cache; var boundPath = model._path; var currentCachePosition; var missingIdx = 0; var boundOptimizedPath, optimizedPath; var i, j, len, bLen; results.values = values; if (!values) { values = []; } if (boundPath.length) { var boundValue = getBoundValue(model, boundPath); currentCachePosition = boundValue.value; optimizedPath = boundOptimizedPath = boundValue.path; } else { currentCachePosition = cache; optimizedPath = boundOptimizedPath = []; } for (i = 0, len = paths.length; i < len; i++) { var valueNode = undefined; var pathSet = paths[i]; if (values[i]) { valueNode = values[i]; } if (len > 1) { optimizedPath = []; for (j = 0, bLen = boundOptimizedPath.length; j < bLen; j++) { optimizedPath[j] = boundOptimizedPath[j]; } } if (pathSet.path) { pathSet = pathSet.path; } walk(model, cache, currentCachePosition, pathSet, 0, valueNode, [], results, optimizedPath, [], inputFormat, 'JSON'); if (missingIdx < requestedMissingPaths.length) { for (j = missingIdx, length = requestedMissingPaths.length; j < length; j++) { requestedMissingPaths[j].pathSetIndex = i; } missingIdx = length; } } return results; }; }; },{"./getBoundValue":45,"./util/isPathValue":57}],42:[function(require,module,exports){ var getBoundValue = require('./getBoundValue'); var isPathValue = require('./util/isPathValue'); module.exports = function(walk) { return function getAsJSONG(model, paths, values) { var results = { values: [], errors: [], requestedPaths: [], optimizedPaths: [], requestedMissingPaths: [], optimizedMissingPaths: [] }; var inputFormat = Array.isArray(paths[0]) || isPathValue(paths[0]) ? 'Paths' : 'JSON'; results.values = values; var cache = model._cache; var boundPath = model._path; var currentCachePosition; if (boundPath.length) { throw 'It is not legal to use the JSON Graph format from a bound Model. JSON Graph format can only be used from a root model.'; } else { currentCachePosition = cache; } for (var i = 0, len = paths.length; i < len; i++) { var pathSet = paths[i]; if (pathSet.path) { pathSet = pathSet.path; } walk(model, cache, currentCachePosition, pathSet, 0, values[0], [], results, [], [], inputFormat, 'JSONG'); } return results; }; }; },{"./getBoundValue":45,"./util/isPathValue":57}],43:[function(require,module,exports){ var getBoundValue = require('./getBoundValue'); var isPathValue = require('./util/isPathValue'); module.exports = function(walk) { return function getAsPathMap(model, paths, values) { var valueNode; var results = { values: [], errors: [], requestedPaths: [], optimizedPaths: [], requestedMissingPaths: [], optimizedMissingPaths: [] }; var inputFormat = Array.isArray(paths[0]) || isPathValue(paths[0]) ? 'Paths' : 'JSON'; valueNode = values[0]; results.values = values; var cache = model._cache; var boundPath = model._path; var currentCachePosition; var optimizedPath, boundOptimizedPath; if (boundPath.length) { var boundValue = getBoundValue(model, boundPath); currentCachePosition = boundValue.value; optimizedPath = boundOptimizedPath = boundValue.path; } else { currentCachePosition = cache; optimizedPath = boundOptimizedPath = []; } for (var i = 0, len = paths.length; i < len; i++) { if (len > 1) { optimizedPath = []; for (j = 0, bLen = boundOptimizedPath.length; j < bLen; j++) { optimizedPath[j] = boundOptimizedPath[j]; } } var pathSet = paths[i]; if (pathSet.path) { pathSet = pathSet.path; } walk(model, cache, currentCachePosition, pathSet, 0, valueNode, [], results, optimizedPath, [], inputFormat, 'PathMap'); } return results; }; }; },{"./getBoundValue":45,"./util/isPathValue":57}],44:[function(require,module,exports){ var getBoundValue = require('./getBoundValue'); var isPathValue = require('./util/isPathValue'); module.exports = function(walk) { return function getAsValues(model, paths, onNext) { var results = { values: [], errors: [], requestedPaths: [], optimizedPaths: [], requestedMissingPaths: [], optimizedMissingPaths: [] }; var inputFormat = Array.isArray(paths[0]) || isPathValue(paths[0]) ? 'Paths' : 'JSON'; var cache = model._cache; var boundPath = model._path; var currentCachePosition; var optimizedPath, boundOptimizedPath; if (boundPath.length) { var boundValue = getBoundValue(model, boundPath); currentCachePosition = boundValue.value; optimizedPath = boundOptimizedPath = boundValue.path; } else { currentCachePosition = cache; optimizedPath = boundOptimizedPath = []; } for (var i = 0, len = paths.length; i < len; i++) { if (len > 1) { optimizedPath = []; for (j = 0, bLen = boundOptimizedPath.length; j < bLen; j++) { optimizedPath[j] = boundOptimizedPath[j]; } } var pathSet = paths[i]; if (pathSet.path) { pathSet = pathSet.path; } walk(model, cache, currentCachePosition, pathSet, 0, onNext, null, results, optimizedPath, [], inputFormat, 'Values'); } return results; }; }; },{"./getBoundValue":45,"./util/isPathValue":57}],45:[function(require,module,exports){ var getValueSync = require('./getValueSync'); module.exports = function getBoundValue(model, path) { var boxed, value, shorted; boxed = model._boxed; model._boxed = true; value = getValueSync(model, path.concat(null)); model._boxed = boxed; path = value.optimizedPath; shorted = value.shorted; value = value.value; while (path.length && path[path.length - 1] === null) { path.pop(); } return { path: path, value: value, shorted: shorted }; }; },{"./getValueSync":46}],46:[function(require,module,exports){ var followReference = require('./followReference'); var clone = require('./util/clone'); var isExpired = require('./util/isExpired'); var promote = require('./util/lru').promote; var $path = require('./../types/path.js'); var $sentinel = require('./../types/sentinel.js'); var $error = require('./../types/error.js'); module.exports = function getValueSync(model, simplePath) { var root = model._cache; var len = simplePath.length; var optimizedPath = []; var shorted = false, shouldShort = false; var depth = 0; var key, i, next = root, type, curr = root, out, ref, refNode; do { key = simplePath[depth++]; if (key !== null) { next = curr[key]; optimizedPath.push(key); } if (!next) { out = undefined; shorted = true; break; } type = next.$type; // Up to the last key we follow references if (depth < len) { if (type === $path) { ref = followReference(model, root, root, next, next.value); refNode = ref[0]; if (!refNode) { out = undefined; break; } type = refNode.$type; next = refNode; optimizedPath = ref[1]; } if (type) { break; } } // If there is a value, then we have great success, else, report an undefined. else { out = next; } curr = next; } while (next && depth < len); if (depth < len) { // Unfortunately, if all that follows are nulls, then we have not shorted. for (i = depth; i < len; ++i) { if (simplePath[depth] !== null) { shouldShort = true; break; } } // if we should short or report value. Values are reported on nulls. if (shouldShort) { shorted = true; out = undefined; } else { out = next; } for (i = depth; i < len; ++i) { optimizedPath[optimizedPath.length] = simplePath[i]; } } // promotes if not expired if (out) { if (isExpired(out)) { out = undefined; } else { promote(model, out); } } if (out && out.$type === $error && !model._treatErrorsAsValues) { throw {path: simplePath, value: out.value}; } else if (out && model._boxed) { out = !!type ? clone(out) : out; } else if (!out && model._materialized) { out = {$type: $sentinel}; } else if (out) { out = out.value; } return { value: out, shorted: shorted, optimizedPath: optimizedPath }; }; },{"./../types/error.js":135,"./../types/path.js":136,"./../types/sentinel.js":137,"./followReference":40,"./util/clone":53,"./util/isExpired":55,"./util/lru":58}],47:[function(require,module,exports){ var followReference = require('./followReference'); var onError = require('./onError'); var onMissing = require('./onMissing'); var onValue = require('./onValue'); var lru = require('./util/lru'); var hardLink = require('./util/hardlink'); var isMaterialized = require('./util/isMaterialzed'); var removeHardlink = hardLink.remove; var splice = lru.splice; var isExpired = require('./util/isExpired'); var permuteKey = require('./util/permuteKey'); var $path = require('./../types/path'); var $error = require('./../types/error'); var __invalidated = require("../internal/invalidated"); function walk(model, root, curr, pathOrJSON, depth, seedOrFunction, positionalInfo, outerResults, optimizedPath, requestedPath, inputFormat, outputFormat, fromReference) { if ((!curr || curr && curr.$type) && evaluateNode(model, curr, pathOrJSON, depth, seedOrFunction, requestedPath, optimizedPath, positionalInfo, outerResults, outputFormat, fromReference)) { return; } // We continue the search to the end of the path/json structure. else { // Base case of the searching: Have we hit the end of the road? // Paths // 1) depth === path.length // PathMaps (json input) // 2) if its an object with no keys // 3) its a non-object var jsonQuery = inputFormat === 'JSON'; var atEndOfJSONQuery = false; var k, i, len; if (jsonQuery) { // it has a $type property means we have hit a end. if (pathOrJSON && pathOrJSON.$type) { atEndOfJSONQuery = true; } // is it an object? else if (pathOrJSON && typeof pathOrJSON === 'object') { // A terminating condition k = Object.keys(pathOrJSON); if (k.length === 1) { k = k[0]; } } // found a primitive, we hit the end. else { atEndOfJSONQuery = true; } } else { k = pathOrJSON[depth]; } // BaseCase: we have hit the end of our query without finding a 'leaf' node, therefore emit missing. if (atEndOfJSONQuery || !jsonQuery && depth === pathOrJSON.length) { if (isMaterialized(model)) { onValue(model, curr, seedOrFunction, outerResults, requestedPath, optimizedPath, positionalInfo, outputFormat, fromReference); return; } onMissing(model, curr, pathOrJSON, depth, seedOrFunction, outerResults, requestedPath, optimizedPath, positionalInfo, outputFormat); return; } var memo = {done: false}; var permutePosition = positionalInfo; var permuteRequested = requestedPath; var permuteOptimized = optimizedPath; var asJSONG = outputFormat === 'JSONG'; var asJSON = outputFormat === 'JSON'; var isKeySet = false; var hasChildren = false; depth++; var key; if (k && typeof k === 'object') { memo.isArray = Array.isArray(k); memo.arrOffset = 0; key = permuteKey(k, memo); isKeySet = true; // The complex key provided is actual empty if (memo.done) { return; } } else { key = k; memo.done = true; } if (asJSON && isKeySet) { permutePosition = []; for (i = 0, len = positionalInfo.length; i < len; i++) { permutePosition[i] = positionalInfo[i]; } permutePosition.push(depth - 1); } do { fromReference = false; if (!memo.done) { permuteOptimized = []; permuteRequested = []; for (i = 0, len = requestedPath.length; i < len; i++) { permuteRequested[i] = requestedPath[i]; } for (i = 0, len = optimizedPath.length; i < len; i++) { permuteOptimized[i] = optimizedPath[i]; } } var nextPathOrPathMap = jsonQuery ? pathOrJSON[key] : pathOrJSON; if (jsonQuery && nextPathOrPathMap) { if (typeof nextPathOrPathMap === 'object') { if (nextPathOrPathMap.$type) { hasChildren = false; } else { hasChildren = Object.keys(nextPathOrPathMap).length > 0; } } } var next; if (key === null || jsonQuery && key === '__null') { next = curr; } else { next = curr[key]; permuteOptimized.push(key); permuteRequested.push(key); } if (next) { var nType = next.$type; var value = nType && next.value || next; if (jsonQuery && hasChildren || !jsonQuery && depth < pathOrJSON.length) { if (nType && nType === $path && !isExpired(next)) { if (asJSONG) { onValue(model, next, seedOrFunction, outerResults, false, permuteOptimized, permutePosition, outputFormat); } var ref = followReference(model, root, root, next, value, seedOrFunction, outputFormat); fromReference = true; next = ref[0]; var refPath = ref[1]; permuteOptimized = []; for (i = 0, len = refPath.length; i < len; i++) { permuteOptimized[i] = refPath[i]; } } } } walk(model, root, next, nextPathOrPathMap, depth, seedOrFunction, permutePosition, outerResults, permuteOptimized, permuteRequested, inputFormat, outputFormat, fromReference); if (!memo.done) { key = permuteKey(k, memo); } } while (!memo.done); } } function evaluateNode(model, curr, pathOrJSON, depth, seedOrFunction, requestedPath, optimizedPath, positionalInfo, outerResults, outputFormat, fromReference) { // BaseCase: This position does not exist, emit missing. if (!curr) { if (isMaterialized(model)) { onValue(model, curr, seedOrFunction, outerResults, requestedPath, optimizedPath, positionalInfo, outputFormat, fromReference); } else { onMissing(model, curr, pathOrJSON, depth, seedOrFunction, outerResults, requestedPath, optimizedPath, positionalInfo, outputFormat); } return true; } var currType = curr.$type; positionalInfo = positionalInfo || []; // The Base Cases. There is a type, therefore we have hit a 'leaf' node. if (currType === $error) { if (fromReference) { requestedPath.push(null); } if (outputFormat === 'JSONG' || model._treatErrorsAsValues) { onValue(model, curr, seedOrFunction, outerResults, requestedPath, optimizedPath, positionalInfo, outputFormat, fromReference); } else { onError(model, curr, requestedPath, optimizedPath, outerResults); } } // Else we have found a value, emit the current position information. else { if (isExpired(curr)) { if (!curr[__invalidated]) { splice(model, curr); removeHardlink(curr); } onMissing(model, curr, pathOrJSON, depth, seedOrFunction, outerResults, requestedPath, optimizedPath, positionalInfo, outputFormat); } else { onValue(model, curr, seedOrFunction, outerResults, requestedPath, optimizedPath, positionalInfo, outputFormat, fromReference); } } return true; } module.exports = walk; },{"../internal/invalidated":65,"./../types/error":135,"./../types/path":136,"./followReference":40,"./onError":50,"./onMissing":51,"./onValue":52,"./util/hardlink":54,"./util/isExpired":55,"./util/isMaterialzed":56,"./util/lru":58,"./util/permuteKey":59}],48:[function(require,module,exports){ var walk = require('./getWalk'); module.exports = { getAsJSON: require('./getAsJSON')(walk), getAsJSONG: require('./getAsJSONG')(walk), getAsValues: require('./getAsValues')(walk), getAsPathMap: require('./getAsPathMap')(walk), getValueSync: require('./getValueSync'), getBoundValue: require('./getBoundValue'), setCache: require('./legacy_setCache') }; },{"./getAsJSON":41,"./getAsJSONG":42,"./getAsPathMap":43,"./getAsValues":44,"./getBoundValue":45,"./getValueSync":46,"./getWalk":47,"./legacy_setCache":49}],49:[function(require,module,exports){ /* istanbul ignore next */ var NOOP = function NOOP() {}, __GENERATION_GUID = 0, __GENERATION_VERSION = 0, __CONTAINER = "__reference_container", __CONTEXT = "__context", __GENERATION = "__generation", __GENERATION_UPDATED = "__generation_updated", __INVALIDATED = "__invalidated", __KEY = "__key", __KEYS = "__keys", __IS_KEY_SET = "__is_key_set", __NULL = "__null", __SELF = "./", __PARENT = "../", __REF = "__ref", __REF_INDEX = "__ref_index", __REFS_LENGTH = "__refs_length", __ROOT = "/", __OFFSET = "__offset", __FALKOR_EMPTY_OBJECT = '__FALKOR_EMPTY_OBJECT', __INTERNAL_KEYS = [ __CONTAINER, __CONTEXT, __GENERATION, __GENERATION_UPDATED, __INVALIDATED, __KEY, __KEYS, __IS_KEY_SET, __NULL, __SELF, __PARENT, __REF, __REF_INDEX, __REFS_LENGTH, __OFFSET, __ROOT ], $TYPE = "$type", $SIZE = "$size", $EXPIRES = "$expires", $TIMESTAMP = "$timestamp", SENTINEL = "sentinel", PATH = "ref", ERROR = "error", VALUE = "value", EXPIRED = "expired", LEAF = "leaf"; /* istanbul ignore next */ module.exports = function setCache(model, map) { var root = model._root, expired = root.expired, depth = 0, height = 0, mapStack = [], nodes = [], nodeRoot = model._cache, nodeParent = nodeRoot, node = nodeParent, nodeType, nodeValue, nodeSize, nodeTimestamp, nodeExpires; mapStack[0] = map; nodes[-1] = nodeParent; while (depth > -1) { /* Walk Path Map */ var isTerminus = false, offset = 0, keys = void 0, index = void 0, key = void 0, isKeySet = false; node = nodeParent = nodes[depth - 1]; depth = depth; follow_path_map_9177: do { height = depth; nodeType = node && node[$TYPE] || void 0; nodeValue = nodeType === SENTINEL ? node[VALUE] : node; if ((isTerminus = !((map = mapStack[offset = depth * 4]) != null && typeof map === 'object') || map[$TYPE] !== void 0 || Array.isArray(map) || !((keys = mapStack[offset + 1] || (mapStack[offset + 1] = Object.keys(map))) && ((index = mapStack[offset + 2] || (mapStack[offset + 2] = 0)) || true) && ((isKeySet = keys.length > 1) || keys.length > 0))) || (node == null || nodeType !== void 0 || typeof node !== 'object' || Array.isArray(nodeValue))) { if ((nodeExpires = (node && node[$EXPIRES]) != null) && (nodeExpires !== 1 && (nodeExpires === 0 || nodeExpires < now())) || node != null && node[__INVALIDATED] === true) { nodeType = void 0; nodeValue = void 0; node = (expired[expired.length] = node) && (node[__INVALIDATED] = true) && void 0; } if (!isTerminus && ((!nodeType || nodeType === SENTINEL) && Array.isArray(nodeValue))) { if (node == null || nodeType !== void 0 || typeof node !== 'object' || Array.isArray(nodeValue)) { key = null; node = node; depth = depth; continue follow_path_map_9177; } } else { if (key != null) { var newNode, sizeOffset, edgeSize = node && node[$SIZE] || 0; nodeType = map && map[$TYPE] || void 0; nV2 = nodeType ? map[VALUE] : void 0; nodeValue = nodeType === SENTINEL ? map[VALUE] : map; newNode = map; if ((!nodeType || nodeType === SENTINEL || nodeType === PATH) && Array.isArray(nodeValue)) { delete nodeValue[$SIZE]; // console.log(1); if (nodeType) { nodeSize = 50 + (nodeValue.length || 1); } else { nodeSize = nodeValue.length || 1; } newNode[$SIZE] = nodeSize; nodeValue[__CONTAINER] = newNode; } else if (nodeType === SENTINEL || nodeType === PATH) { newNode[$SIZE] = nodeSize = 50 + (nV2 && typeof nV2.length === 'number' ? nV2.length : 1); } else if (nodeType === ERROR) { newNode[$SIZE] = nodeSize = map && map[$SIZE] || 0 || 50 + 1; } else if (!(map != null && typeof map === 'object')) { nodeSize = 50 + (typeof nodeValue === 'string' && nodeValue.length || 1); nodeType = 'sentinel'; newNode = {}; newNode[VALUE] = nodeValue; newNode[$TYPE] = nodeType; newNode[$SIZE] = nodeSize; } else { nodeType = newNode[$TYPE] = nodeType || GROUP; newNode[$SIZE] = nodeSize = map && map[$SIZE] || 0 || 50 + 1; } ; if (node !== newNode && (node != null && typeof node === 'object')) { var nodeRefsLength = node[__REFS_LENGTH] || 0, destRefsLength = newNode[__REFS_LENGTH] || 0, i = -1, ref; while (++i < nodeRefsLength) { if ((ref = node[__REF + i]) !== void 0) { ref[__CONTEXT] = newNode; newNode[__REF + (destRefsLength + i)] = ref; node[__REF + i] = void 0; } } newNode[__REFS_LENGTH] = nodeRefsLength + destRefsLength; node[__REFS_LENGTH] = ref = void 0; var invParent = nodeParent, invChild = node, invKey = key, keys$2, index$2, offset$2, childType, childValue, isBranch, stack = [ nodeParent, invKey, node ], depth$2 = 0; while (depth$2 > -1) { nodeParent = stack[offset$2 = depth$2 * 8]; invKey = stack[offset$2 + 1]; node = stack[offset$2 + 2]; if ((childType = stack[offset$2 + 3]) === void 0 || (childType = void 0)) { childType = stack[offset$2 + 3] = node && node[$TYPE] || void 0 || null; } childValue = stack[offset$2 + 4] || (stack[offset$2 + 4] = childType === SENTINEL ? node[VALUE] : node); if ((isBranch = stack[offset$2 + 5]) === void 0) { isBranch = stack[offset$2 + 5] = !childType && (node != null && typeof node === 'object') && !Array.isArray(childValue); } if (isBranch === true) { if ((keys$2 = stack[offset$2 + 6]) === void 0) { keys$2 = stack[offset$2 + 6] = []; index$2 = -1; for (var childKey in node) { !(!(childKey[0] !== '_' || childKey[1] !== '_') || (childKey === __SELF || childKey === __PARENT || childKey === __ROOT) || childKey[0] === '$') && (keys$2[++index$2] = childKey); } } index$2 = stack[offset$2 + 7] || (stack[offset$2 + 7] = 0); if (index$2 < keys$2.length) { stack[offset$2 + 7] = index$2 + 1; stack[offset$2 = ++depth$2 * 8] = node; stack[offset$2 + 1] = invKey = keys$2[index$2]; stack[offset$2 + 2] = node[invKey]; continue; } } var ref$2 = node[$TYPE] === SENTINEL ? node[VALUE] : node, destination; if (ref$2 && Array.isArray(ref$2)) { destination = ref$2[__CONTEXT]; if (destination) { var i$2 = (ref$2[__REF_INDEX] || 0) - 1, n = (destination[__REFS_LENGTH] || 0) - 1; while (++i$2 <= n) { destination[__REF + i$2] = destination[__REF + (i$2 + 1)]; } destination[__REFS_LENGTH] = n; ref$2[__REF_INDEX] = ref$2[__CONTEXT] = destination = void 0; } } if (node != null && typeof node === 'object') { var ref$3, i$3 = -1, n$2 = node[__REFS_LENGTH] || 0; while (++i$3 < n$2) { if ((ref$3 = node[__REF + i$3]) !== void 0) { ref$3[__CONTEXT] = node[__REF + i$3] = void 0; } } node[__REFS_LENGTH] = void 0; var root$2 = root, head = root$2.__head, tail = root$2.__tail, next = node.__next, prev = node.__prev; next != null && typeof next === 'object' && (next.__prev = prev); prev != null && typeof prev === 'object' && (prev.__next = next); node === head && (root$2.__head = root$2.__next = next); node === tail && (root$2.__tail = root$2.__prev = prev); node.__next = node.__prev = void 0; head = tail = next = prev = void 0; ; nodeParent[invKey] = node[__SELF] = node[__PARENT] = node[__ROOT] = void 0; } ; delete stack[offset$2 + 0]; delete stack[offset$2 + 1]; delete stack[offset$2 + 2]; delete stack[offset$2 + 3]; delete stack[offset$2 + 4]; delete stack[offset$2 + 5]; delete stack[offset$2 + 6]; delete stack[offset$2 + 7]; --depth$2; } nodeParent = invParent; node = invChild; } nodeParent[key] = node = newNode; nodeType = node && node[$TYPE] || void 0; node = !node[__SELF] && ((node[__SELF] = node) || true) && ((node[__KEY] = key) || true) && ((node[__PARENT] = nodeParent) || true) && ((node[__ROOT] = nodeRoot) || true) && (node[__GENERATION] || (node[__GENERATION] = ++__GENERATION_GUID) && node) && ((!nodeType || nodeType === SENTINEL) && Array.isArray(nodeValue) && (nodeValue[__CONTAINER] = node)) || node; sizeOffset = edgeSize - nodeSize; var self = nodeParent, child = node; while (node = nodeParent) { nodeParent = node[__PARENT]; if ((node[$SIZE] = (node[$SIZE] || 0) - sizeOffset) <= 0 && nodeParent) { var ref$4 = node[$TYPE] === SENTINEL ? node[VALUE] : node, destination$2; if (ref$4 && Array.isArray(ref$4)) { destination$2 = ref$4[__CONTEXT]; if (destination$2) { var i$4 = (ref$4[__REF_INDEX] || 0) - 1, n$3 = (destination$2[__REFS_LENGTH] || 0) - 1; while (++i$4 <= n$3) { destination$2[__REF + i$4] = destination$2[__REF + (i$4 + 1)]; } destination$2[__REFS_LENGTH] = n$3; ref$4[__REF_INDEX] = ref$4[__CONTEXT] = destination$2 = void 0; } } if (node != null && typeof node === 'object') { var ref$5, i$5 = -1, n$4 = node[__REFS_LENGTH] || 0; while (++i$5 < n$4) { if ((ref$5 = node[__REF + i$5]) !== void 0) { ref$5[__CONTEXT] = node[__REF + i$5] = void 0; } } node[__REFS_LENGTH] = void 0; var root$3 = root, head$2 = root$3.__head, tail$2 = root$3.__tail, next$2 = node.__next, prev$2 = node.__prev; next$2 != null && typeof next$2 === 'object' && (next$2.__prev = prev$2); prev$2 != null && typeof prev$2 === 'object' && (prev$2.__next = next$2); node === head$2 && (root$3.__head = root$3.__next = next$2); node === tail$2 && (root$3.__tail = root$3.__prev = prev$2); node.__next = node.__prev = void 0; head$2 = tail$2 = next$2 = prev$2 = void 0; ; nodeParent[node[__KEY]] = node[__SELF] = node[__PARENT] = node[__ROOT] = void 0; } } else if (node[__GENERATION_UPDATED] !== __GENERATION_VERSION) { var self$2 = node, stack$2 = [], depth$3 = 0, linkPaths, ref$6, i$6, k, n$5; while (depth$3 > -1) { if ((linkPaths = stack$2[depth$3]) === void 0) { i$6 = k = -1; n$5 = node[__REFS_LENGTH] || 0; node[__GENERATION_UPDATED] = __GENERATION_VERSION; node[__GENERATION] = ++__GENERATION_GUID; if ((ref$6 = node[__PARENT]) !== void 0 && ref$6[__GENERATION_UPDATED] !== __GENERATION_VERSION) { stack$2[depth$3] = linkPaths = new Array(n$5 + 1); linkPaths[++k] = ref$6; } else if (n$5 > 0) { stack$2[depth$3] = linkPaths = new Array(n$5); } while (++i$6 < n$5) { if ((ref$6 = node[__REF + i$6]) !== void 0 && ref$6[__GENERATION_UPDATED] !== __GENERATION_VERSION) { linkPaths[++k] = ref$6; } } } if ((node = linkPaths && linkPaths.pop()) !== void 0) { ++depth$3; } else { stack$2[depth$3--] = void 0; } } node = self$2; } } nodeParent = self; node = child; } ; node = node; break follow_path_map_9177; } } if ((key = keys[index]) == null) { node = node; break follow_path_map_9177; } else if (key === __NULL && ((key = null) || true) || !(!(key[0] !== '_' || key[1] !== '_') || (key === __SELF || key === __PARENT || key === __ROOT) || key[0] === '$') && ((mapStack[(depth + 1) * 4] = map[key]) || true)) { mapStack[(depth + 1) * 4 + 3] = key; } else { mapStack[offset + 2] = index + 1; node = node; depth = depth; continue follow_path_map_9177; } nodes[depth - 1] = nodeParent = node; if (key != null) { node = nodeParent && nodeParent[key]; if (typeof map === 'object') { for (var key$2 in map) { key$2[0] === '$' && key$2 !== $SIZE && (nodeParent && (nodeParent[key$2] = map[key$2]) || true); } map = map[key]; } var mapType = map && map[$TYPE] || void 0; var mapValue = mapType === SENTINEL ? map[VALUE] : map; if ((node == null || typeof node !== 'object' || !!nodeType && nodeType !== SENTINEL && !Array.isArray(nodeValue)) && (!mapType && (map != null && typeof map === 'object') && !Array.isArray(mapValue))) { nodeType = void 0; nodeValue = {}; nodeSize = node && node[$SIZE] || 0; if (node !== nodeValue && (node != null && typeof node === 'object')) { var nodeRefsLength$2 = node[__REFS_LENGTH] || 0, destRefsLength$2 = nodeValue[__REFS_LENGTH] || 0, i$7 = -1, ref$7; while (++i$7 < nodeRefsLength$2) { if ((ref$7 = node[__REF + i$7]) !== void 0) { ref$7[__CONTEXT] = nodeValue; nodeValue[__REF + (destRefsLength$2 + i$7)] = ref$7; node[__REF + i$7] = void 0; } } nodeValue[__REFS_LENGTH] = nodeRefsLength$2 + destRefsLength$2; node[__REFS_LENGTH] = ref$7 = void 0; var invParent$2 = nodeParent, invChild$2 = node, invKey$2 = key, keys$3, index$3, offset$3, childType$2, childValue$2, isBranch$2, stack$3 = [ nodeParent, invKey$2, node ], depth$4 = 0; while (depth$4 > -1) { nodeParent = stack$3[offset$3 = depth$4 * 8]; invKey$2 = stack$3[offset$3 + 1]; node = stack$3[offset$3 + 2]; if ((childType$2 = stack$3[offset$3 + 3]) === void 0 || (childType$2 = void 0)) { childType$2 = stack$3[offset$3 + 3] = node && node[$TYPE] || void 0 || null; } childValue$2 = stack$3[offset$3 + 4] || (stack$3[offset$3 + 4] = childType$2 === SENTINEL ? node[VALUE] : node); if ((isBranch$2 = stack$3[offset$3 + 5]) === void 0) { isBranch$2 = stack$3[offset$3 + 5] = !childType$2 && (node != null && typeof node === 'object') && !Array.isArray(childValue$2); } if (isBranch$2 === true) { if ((keys$3 = stack$3[offset$3 + 6]) === void 0) { keys$3 = stack$3[offset$3 + 6] = []; index$3 = -1; for (var childKey$2 in node) { !(!(childKey$2[0] !== '_' || childKey$2[1] !== '_') || (childKey$2 === __SELF || childKey$2 === __PARENT || childKey$2 === __ROOT) || childKey$2[0] === '$') && (keys$3[++index$3] = childKey$2); } } index$3 = stack$3[offset$3 + 7] || (stack$3[offset$3 + 7] = 0); if (index$3 < keys$3.length) { stack$3[offset$3 + 7] = index$3 + 1; stack$3[offset$3 = ++depth$4 * 8] = node; stack$3[offset$3 + 1] = invKey$2 = keys$3[index$3]; stack$3[offset$3 + 2] = node[invKey$2]; continue; } } var ref$8 = node[$TYPE] === SENTINEL ? node[VALUE] : node, destination$3; if (ref$8 && Array.isArray(ref$8)) { destination$3 = ref$8[__CONTEXT]; if (destination$3) { var i$8 = (ref$8[__REF_INDEX] || 0) - 1, n$6 = (destination$3[__REFS_LENGTH] || 0) - 1; while (++i$8 <= n$6) { destination$3[__REF + i$8] = destination$3[__REF + (i$8 + 1)]; } destination$3[__REFS_LENGTH] = n$6; ref$8[__REF_INDEX] = ref$8[__CONTEXT] = destination$3 = void 0; } } if (node != null && typeof node === 'object') { var ref$9, i$9 = -1, n$7 = node[__REFS_LENGTH] || 0; while (++i$9 < n$7) { if ((ref$9 = node[__REF + i$9]) !== void 0) { ref$9[__CONTEXT] = node[__REF + i$9] = void 0; } } node[__REFS_LENGTH] = void 0; var root$4 = root, head$3 = root$4.__head, tail$3 = root$4.__tail, next$3 = node.__next, prev$3 = node.__prev; next$3 != null && typeof next$3 === 'object' && (next$3.__prev = prev$3); prev$3 != null && typeof prev$3 === 'object' && (prev$3.__next = next$3); node === head$3 && (root$4.__head = root$4.__next = next$3); node === tail$3 && (root$4.__tail = root$4.__prev = prev$3); node.__next = node.__prev = void 0; head$3 = tail$3 = next$3 = prev$3 = void 0; ; nodeParent[invKey$2] = node[__SELF] = node[__PARENT] = node[__ROOT] = void 0; } ; delete stack$3[offset$3 + 0]; delete stack$3[offset$3 + 1]; delete stack$3[offset$3 + 2]; delete stack$3[offset$3 + 3]; delete stack$3[offset$3 + 4]; delete stack$3[offset$3 + 5]; delete stack$3[offset$3 + 6]; delete stack$3[offset$3 + 7]; --depth$4; } nodeParent = invParent$2; node = invChild$2; } nodeParent[key] = node = nodeValue; node = !node[__SELF] && ((node[__SELF] = node) || true) && ((node[__KEY] = key) || true) && ((node[__PARENT] = nodeParent) || true) && ((node[__ROOT] = nodeRoot) || true) && (node[__GENERATION] || (node[__GENERATION] = ++__GENERATION_GUID) && node) && ((!nodeType || nodeType === SENTINEL) && Array.isArray(nodeValue) && (nodeValue[__CONTAINER] = node)) || node; var self$3 = node, node$2; while (node$2 = node) { if (node[__GENERATION_UPDATED] !== __GENERATION_VERSION) { var self$4 = node, stack$4 = [], depth$5 = 0, linkPaths$2, ref$10, i$10, k$2, n$8; while (depth$5 > -1) { if ((linkPaths$2 = stack$4[depth$5]) === void 0) { i$10 = k$2 = -1; n$8 = node[__REFS_LENGTH] || 0; node[__GENERATION_UPDATED] = __GENERATION_VERSION; node[__GENERATION] = ++__GENERATION_GUID; if ((ref$10 = node[__PARENT]) !== void 0 && ref$10[__GENERATION_UPDATED] !== __GENERATION_VERSION) { stack$4[depth$5] = linkPaths$2 = new Array(n$8 + 1); linkPaths$2[++k$2] = ref$10; } else if (n$8 > 0) { stack$4[depth$5] = linkPaths$2 = new Array(n$8); } while (++i$10 < n$8) { if ((ref$10 = node[__REF + i$10]) !== void 0 && ref$10[__GENERATION_UPDATED] !== __GENERATION_VERSION) { linkPaths$2[++k$2] = ref$10; } } } if ((node = linkPaths$2 && linkPaths$2.pop()) !== void 0) { ++depth$5; } else { stack$4[depth$5--] = void 0; } } node = self$4; } node = node$2[__PARENT]; } node = self$3; } } node = node; depth = depth + 1; continue follow_path_map_9177; } while (true); node = node; var offset$4 = depth * 4, keys$4, index$4; do { delete mapStack[offset$4 + 0]; delete mapStack[offset$4 + 1]; delete mapStack[offset$4 + 2]; delete mapStack[offset$4 + 3]; } while ((keys$4 = mapStack[(offset$4 = 4 * --depth) + 1]) && ((index$4 = mapStack[offset$4 + 2]) || true) && (mapStack[offset$4 + 2] = ++index$4) >= keys$4.length); } return nodeRoot; } },{}],50:[function(require,module,exports){ var lru = require('./util/lru'); var clone = require('./util/clone'); var promote = lru.promote; module.exports = function onError(model, node, permuteRequested, permuteOptimized, outerResults) { outerResults.errors.push({path: permuteRequested, value: node.value}); promote(model, node); if (permuteOptimized) { outerResults.requestedPaths.push(permuteRequested); outerResults.optimizedPaths.push(permuteOptimized); } }; },{"./util/clone":53,"./util/lru":58}],51:[function(require,module,exports){ var support = require('./util/support'); var fastCat = support.fastCat, fastCatSkipNulls = support.fastCatSkipNulls, fastCopy = support.fastCopy; var isExpired = require('./util/isExpired'); var spreadJSON = require('./util/spreadJSON'); var clone = require('./util/clone'); module.exports = function onMissing(model, node, path, depth, seedOrFunction, outerResults, permuteRequested, permuteOptimized, permutePosition, outputFormat) { var pathSlice; if (Array.isArray(path)) { if (depth < path.length) { pathSlice = fastCopy(path, depth); } else { pathSlice = []; } concatAndInsertMissing(pathSlice, outerResults, permuteRequested, permuteOptimized, permutePosition, outputFormat); } else { pathSlice = []; spreadJSON(path, pathSlice); for (var i = 0, len = pathSlice.length; i < len; i++) { concatAndInsertMissing(pathSlice[i], outerResults, permuteRequested, permuteOptimized, permutePosition, outputFormat, true); } } }; function concatAndInsertMissing(remainingPath, results, permuteRequested, permuteOptimized, permutePosition, outputFormat, __null) { var i = 0, len; if (__null) { for (i = 0, len = remainingPath.length; i < len; i++) { if (remainingPath[i] === '__null') { remainingPath[i] = null; } } } if (outputFormat === 'JSON') { permuteRequested = fastCat(permuteRequested, remainingPath); for (i = 0, len = permutePosition.length; i < len; i++) { var idx = permutePosition[i]; var r = permuteRequested[idx]; permuteRequested[idx] = [r]; } results.requestedMissingPaths.push(permuteRequested); results.optimizedMissingPaths.push(fastCatSkipNulls(permuteOptimized, remainingPath)); } else { results.requestedMissingPaths.push(fastCat(permuteRequested, remainingPath)); results.optimizedMissingPaths.push(fastCatSkipNulls(permuteOptimized, remainingPath)); } } },{"./util/clone":53,"./util/isExpired":55,"./util/spreadJSON":60,"./util/support":61}],52:[function(require,module,exports){ var lru = require('./util/lru'); var clone = require('./util/clone'); var promote = lru.promote; var $path = require('./../types/path'); var $sentinel = require('./../types/sentinel'); var $error = require('./../types/error'); module.exports = function onValue(model, node, seedOrFunction, outerResults, permuteRequested, permuteOptimized, permutePosition, outputFormat, fromReference) { var i, len, k, key, curr, prev, prevK; var materialized = false, valueNode; if (node) { promote(model, node); } if (!node || node.value === undefined) { materialized = model._materialized; } // materialized if (materialized) { valueNode = {$type: $sentinel}; } // Boxed Mode & Reference Node & Error node (only happens when model is in treat errors as values). else if (model._boxed) { valueNode = clone(node); } else if (node.$type === $path || node.$type === $error) { if (outputFormat === 'JSONG') { valueNode = clone(node); } else { valueNode = node.value; } } else { if (outputFormat === 'JSONG') { if (typeof node.value === 'object') { valueNode = clone(node); } else { valueNode = node.value; } } else { valueNode = node.value; } } if (permuteRequested) { if (fromReference && permuteRequested[permuteRequested.length - 1] !== null) { permuteRequested.push(null); } outerResults.requestedPaths.push(permuteRequested); outerResults.optimizedPaths.push(permuteOptimized); } switch (outputFormat) { case 'Values': // in any subscription situation, onNexts are always provided, even as a noOp. seedOrFunction({path: permuteRequested, value: valueNode}); break; case 'PathMap': len = permuteRequested.length - 1; if (len === -1) { seedOrFunction.json = valueNode; } else { curr = seedOrFunction.json; if (!curr) { curr = seedOrFunction.json = {}; } for (i = 0; i < len; i++) { k = permuteRequested[i]; if (!curr[k]) { curr[k] = {}; } prev = curr; prevK = k; curr = curr[k]; } k = permuteRequested[i]; if (k !== null) { curr[k] = valueNode; } else { prev[prevK] = valueNode; } } break; case 'JSON': if (seedOrFunction) { if (permutePosition.length) { if (!seedOrFunction.json) { seedOrFunction.json = {}; } curr = seedOrFunction.json; for (i = 0, len = permutePosition.length - 1; i < len; i++) { k = permutePosition[i]; key = permuteRequested[k]; if (!curr[key]) { curr[key] = {}; } curr = curr[key]; } // assign the last k = permutePosition[i]; key = permuteRequested[k]; curr[key] = valueNode; } else { seedOrFunction.json = valueNode; } } break; case 'JSONG': curr = seedOrFunction.jsong; if (!curr) { curr = seedOrFunction.jsong = {}; seedOrFunction.paths = []; } for (i = 0, len = permuteOptimized.length - 1; i < len; i++) { key = permuteOptimized[i]; if (!curr[key]) { curr[key] = {}; } curr = curr[key]; } // assign the last key = permuteOptimized[i]; // TODO: Special case? do string comparisons make big difference? curr[key] = materialized ? {$type: $sentinel} : valueNode; if (permuteRequested) { seedOrFunction.paths.push(permuteRequested); } break; } }; },{"./../types/error":135,"./../types/path":136,"./../types/sentinel":137,"./util/clone":53,"./util/lru":58}],53:[function(require,module,exports){ // Copies the node var prefix = require("../../internal/prefix"); module.exports = function clone(node) { var outValue, i, len; var keys = Object.keys(node); outValue = {}; for (i = 0, len = keys.length; i < len; i++) { var k = keys[i]; if (k[0] === prefix) { continue; } outValue[k] = node[k]; } return outValue; }; },{"../../internal/prefix":70}],54:[function(require,module,exports){ var __ref = require("../../internal/ref"); var __context = require("../../internal/context"); var __ref_index = require("../../internal/ref-index"); var __refs_length = require("../../internal/refs-length"); function createHardlink(from, to) { // create a back reference var backRefs = to[__refs_length] || 0; to[__ref + backRefs] = from; to[__refs_length] = backRefs + 1; // create a hard reference from[__ref_index] = backRefs; from[__context] = to; } function removeHardlink(cacheObject) { var context = cacheObject[__context]; if (context) { var idx = cacheObject[__ref_index]; var len = context[__refs_length]; while (idx < len) { context[__ref + idx] = context[__REF + idx + 1]; ++idx; } context[__refs_length] = len - 1; cacheObject[__context] = undefined; cacheObject[__ref_index] = undefined; } } module.exports = { create: createHardlink, remove: removeHardlink }; },{"../../internal/context":62,"../../internal/ref":73,"../../internal/ref-index":72,"../../internal/refs-length":74}],55:[function(require,module,exports){ var now = require('../../support/now'); module.exports = function isExpired(node) { var $expires = node.$expires === undefined && -1 || node.$expires; return $expires !== -1 && $expires !== 1 && ($expires === 0 || $expires < now()); }; },{"../../support/now":122}],56:[function(require,module,exports){ module.exports = function isMaterialized(model) { return model._materialized && !(model._router || model._dataSource); }; },{}],57:[function(require,module,exports){ module.exports = function(x) { return x.path && x.value; }; },{}],58:[function(require,module,exports){ var __head = require("../../internal/head"); var __tail = require("../../internal/tail"); var __next = require("../../internal/next"); var __prev = require("../../internal/prev"); var __invalidated = require("../../internal/invalidated"); // [H] -> Next -> ... -> [T] // [T] -> Prev -> ... -> [H] function lruPromote(model, object) { var root = model._root; var head = root[__head]; if (head === object) { return; } // First insert if (!head) { root[__head] = object; return; } // The head and the tail need to separate if (!root[__tail]) { root[__head] = object; root[__tail] = head; object[__next] = head; // Now tail head[__prev] = object; return; } // Its in the cache. Splice out. var prev = object[__prev]; var next = object[__next]; if (next) { next[__prev] = prev; } if (prev) { prev[__next] = next; } object[__prev] = undefined; // Insert into head position root[__head] = object; object[__next] = head; head[__prev] = object; } function lruSplice(model, object) { var root = model._root; // Its in the cache. Splice out. var prev = object[__prev]; var next = object[__next]; if (next) { next[__prev] = prev; } if (prev) { prev[__next] = next; } object[__prev] = undefined; if (object === root[__head]) { root[__head] = undefined; } if (object === root[__tail]) { root[__tail] = undefined; } object[__invalidated] = true; root.expired.push(object); } module.exports = { promote: lruPromote, splice: lruSplice }; },{"../../internal/head":64,"../../internal/invalidated":65,"../../internal/next":67,"../../internal/prev":71,"../../internal/tail":75}],59:[function(require,module,exports){ var prefix = require("../../internal/prefix"); module.exports = function permuteKey(key, memo) { if (memo.isArray) { if (memo.loaded && memo.rangeOffset > memo.to) { memo.arrOffset++; memo.loaded = false; } var idx = memo.arrOffset, length = key.length; if (idx === length) { memo.done = true; return ''; } var el = key[memo.arrOffset]; var type = typeof el; if (type === 'object') { if (!memo.loaded) { memo.from = el.from || 0; memo.to = el.to || typeof el.length === 'number' && memo.from + el.length - 1 || 0; memo.rangeOffset = memo.from; memo.loaded = true; } return memo.rangeOffset++; } else { do { // if (type !== 'string') { // break; // } if (el[0] !== prefix && el[0] !== '$') { break; } el = key[++idx]; } while (el !== undefined || idx < length); if (el === undefined || idx === length) { memo.done = true; return ''; } memo.arrOffset = idx + 1; return el; } } else { if (!memo.loaded) { memo.from = key.from || 0; memo.to = key.to || typeof key.length === 'number' && memo.from + key.length - 1 || 0; memo.rangeOffset = memo.from; memo.loaded = true; } if (memo.rangeOffset > memo.to) { memo.done = true; return ''; } return memo.rangeOffset++; } }; },{"../../internal/prefix":70}],60:[function(require,module,exports){ var fastCopy = require('./support').fastCopy; module.exports = function spreadJSON(root, bins, bin) { bin = bin || []; if (!bins.length) { bins.push(bin); } if (!root || typeof root !== 'object' || root.$type) { return []; } var keys = Object.keys(root); if (keys.length === 1) { bin.push(keys[0]); spreadJSON(root[keys[0]], bins, bin); } else { for (var i = 0, len = keys.length; i < len; i++) { var k = keys[i]; var nextBin = fastCopy(bin); nextBin.push(k); bins.push(nextBin); spreadJSON(root[k], bins, nextBin); } } }; },{"./support":61}],61:[function(require,module,exports){ function fastCopy(arr, i) { var a = [], len, j; for (j = 0, i = i || 0, len = arr.length; i < len; j++, i++) { a[j] = arr[i]; } return a; } function fastCatSkipNulls(arr1, arr2) { var a = [], i, len, j; for (i = 0, len = arr1.length; i < len; i++) { a[i] = arr1[i]; } for (j = 0, len = arr2.length; j < len; j++) { if (arr2[j] !== null) { a[i++] = arr2[j]; } } return a; } function fastCat(arr1, arr2) { var a = [], i, len, j; for (i = 0, len = arr1.length; i < len; i++) { a[i] = arr1[i]; } for (j = 0, len = arr2.length; j < len; j++) { a[i++] = arr2[j]; } return a; } module.exports = { fastCat: fastCat, fastCatSkipNulls: fastCatSkipNulls, fastCopy: fastCopy }; },{}],62:[function(require,module,exports){ module.exports = require("./prefix") + "context"; },{"./prefix":70}],63:[function(require,module,exports){ module.exports = require("./prefix") + "generation"; },{"./prefix":70}],64:[function(require,module,exports){ module.exports = require("./prefix") + "head"; },{"./prefix":70}],65:[function(require,module,exports){ module.exports = require("./prefix") + "invalidated"; },{"./prefix":70}],66:[function(require,module,exports){ module.exports = require("./prefix") + "key"; },{"./prefix":70}],67:[function(require,module,exports){ module.exports = require("./prefix") + "next"; },{"./prefix":70}],68:[function(require,module,exports){ module.exports = require("./prefix") + "offset"; },{"./prefix":70}],69:[function(require,module,exports){ module.exports = require("./prefix") + "parent"; },{"./prefix":70}],70:[function(require,module,exports){ // This may look like an empty string, but it's actually a single zero-width-space character. module.exports = "​"; },{}],71:[function(require,module,exports){ module.exports = require("./prefix") + "prev"; },{"./prefix":70}],72:[function(require,module,exports){ module.exports = require("./prefix") + "ref-index"; },{"./prefix":70}],73:[function(require,module,exports){ module.exports = require("./prefix") + "ref"; },{"./prefix":70}],74:[function(require,module,exports){ module.exports = require("./prefix") + "refs-length"; },{"./prefix":70}],75:[function(require,module,exports){ module.exports = require("./prefix") + "tail"; },{"./prefix":70}],76:[function(require,module,exports){ module.exports = require("./prefix") + "version"; },{"./prefix":70}],77:[function(require,module,exports){ module.exports = { invPathSetsAsJSON: require("./invalidate-path-sets-as-json-dense"), invPathSetsAsJSONG: require("./invalidate-path-sets-as-json-graph"), invPathSetsAsPathMap: require("./invalidate-path-sets-as-json-sparse"), invPathSetsAsValues: require("./invalidate-path-sets-as-json-values") }; },{"./invalidate-path-sets-as-json-dense":78,"./invalidate-path-sets-as-json-graph":79,"./invalidate-path-sets-as-json-sparse":80,"./invalidate-path-sets-as-json-values":81}],78:[function(require,module,exports){ module.exports = invalidate_path_sets_as_json_dense; var clone = require("../support/clone-dense-json"); var array_clone = require("../support/array-clone"); var array_slice = require("../support/array-slice"); var options = require("../support/options"); var walk_path_set = require("../walk/walk-path-set"); var is_object = require("../support/is-object"); var get_valid_key = require("../support/get-valid-key"); var update_graph = require("../support/update-graph"); var invalidate_node = require("../support/invalidate-node"); var collect = require("../lru/collect"); function invalidate_path_sets_as_json_dense(model, pathsets, values) { var roots = options([], model); var index = -1; var count = pathsets.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var json, hasValue; roots[0] = roots.root; while (++index < count) { json = values && values[index]; if (is_object(json)) { roots[3] = parents[3] = nodes[3] = json.json || (json.json = {}) } else { roots[3] = parents[3] = nodes[3] = undefined; } var pathset = pathsets[index]; roots.index = index; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); if (is_object(json)) { json.json = roots.json; } delete roots.json; } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, hasValue: true, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, json; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } json = parents[3]; parent = parents[0]; } else { json = is_keyset && nodes[3] || parents[3]; parent = nodes[0]; } var node = parent[key]; if (!is_top_level) { parents[0] = parent; nodes[0] = node; return; } if (is_branch) { parents[0] = nodes[0] = node; if (is_keyset && !!(parents[3] = json)) { nodes[3] = json[keyset] || (json[keyset] = {}); } return; } nodes[0] = node; if (!!json) { var type = is_object(node) && node.$type || undefined; var jsonkey = keyset; if (jsonkey == null) { json = roots; jsonkey = 3; } json[jsonkey] = clone(roots, node, type, node && node.value); } var lru = roots.lru; var size = node.$size || 0; var version = roots.version; invalidate_node(parent, node, key, roots.lru); update_graph(parent, size, version, lru); } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { roots.json = roots[3]; roots.hasValue = true; roots.requestedPaths.push(array_slice(requested, roots.offset)); } },{"../lru/collect":82,"../support/array-clone":100,"../support/array-slice":101,"../support/clone-dense-json":102,"../support/get-valid-key":112,"../support/invalidate-node":116,"../support/is-object":118,"../support/options":123,"../support/update-graph":133,"../walk/walk-path-set":143}],79:[function(require,module,exports){ module.exports = invalidate_path_sets_as_json_graph; var $path = require("../types/path"); var clone = require("../support/clone-dense-json"); var array_clone = require("../support/array-clone"); var options = require("../support/options"); var walk_path_set = require("../walk/walk-path-set-soft-link"); var is_object = require("../support/is-object"); var get_valid_key = require("../support/get-valid-key"); var update_graph = require("../support/update-graph"); var invalidate_node = require("../support/invalidate-node"); var clone_success = require("../support/clone-success-paths"); var collect = require("../lru/collect"); function invalidate_path_sets_as_json_graph(model, pathsets, values) { var roots = options([], model); var index = -1; var count = pathsets.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var json = values[0]; roots[0] = roots.root; roots[1] = parents[1] = nodes[1] = json.jsong || (json.jsong = {}); roots.requestedPaths = json.paths || (json.paths = roots.requestedPaths); while (++index < count) { var pathset = pathsets[index]; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, hasValue: true, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, json; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } json = parents[1]; parent = parents[0]; } else { json = nodes[1]; parent = nodes[0]; } var jsonkey = key; var node = parent[key]; if (!is_top_level) { parents[0] = parent; nodes[0] = node; parents[1] = json; nodes[1] = json[jsonkey] || (json[jsonkey] = {}); return; } var type = is_object(node) && node.$type || undefined; if (is_branch) { parents[0] = nodes[0] = node; parents[1] = json; if (type == $path) { json[jsonkey] = clone(roots, node, type, node.value); } else { nodes[1] = json[jsonkey] || (json[jsonkey] = {}); } return; } nodes[0] = node; json[jsonkey] = clone(roots, node, type, node && node.value); var lru = roots.lru; var size = node.$size || 0; var version = roots.version; invalidate_node(parent, node, key, roots.lru); update_graph(parent, size, version, lru); } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { clone_success(roots, requested, optimized); roots.json = roots[1]; roots.hasValue = true; } },{"../lru/collect":82,"../support/array-clone":100,"../support/clone-dense-json":102,"../support/clone-success-paths":108,"../support/get-valid-key":112,"../support/invalidate-node":116,"../support/is-object":118,"../support/options":123,"../support/update-graph":133,"../types/path":136,"../walk/walk-path-set-soft-link":142}],80:[function(require,module,exports){ module.exports = invalidate_path_sets_as_json_sparse; var clone = require("../support/clone-dense-json"); var array_clone = require("../support/array-clone"); var array_slice = require("../support/array-slice"); var options = require("../support/options"); var walk_path_set = require("../walk/walk-path-set"); var is_object = require("../support/is-object"); var get_valid_key = require("../support/get-valid-key"); var update_graph = require("../support/update-graph"); var invalidate_node = require("../support/invalidate-node"); var collect = require("../lru/collect"); function invalidate_path_sets_as_json_sparse(model, pathsets, values) { var roots = options([], model); var index = -1; var count = pathsets.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var json = values[0]; roots[0] = roots.root; roots[3] = parents[3] = nodes[3] = json.json || (json.json = {}); while (++index < count) { var pathset = pathsets[index]; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, hasValue: true, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, json, jsonkey; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } jsonkey = get_valid_key(requested); json = parents[3]; parent = parents[0]; } else { jsonkey = key; json = nodes[3]; parent = nodes[0]; } var node = parent[key]; if (!is_top_level) { parents[0] = parent; nodes[0] = node; return; } if (is_branch) { parents[0] = nodes[0] = node; parents[3] = json; nodes[3] = json[jsonkey] || (json[jsonkey] = {}); return; } nodes[0] = node; var type = is_object(node) && node.$type || undefined; json[jsonkey] = clone(roots, node, type, node && node.value); var lru = roots.lru; var size = node.$size || 0; var version = roots.version; invalidate_node(parent, node, key, roots.lru); update_graph(parent, size, version, lru); } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { roots.json = roots[3]; roots.hasValue = true; roots.requestedPaths.push(array_slice(requested, roots.offset)); } },{"../lru/collect":82,"../support/array-clone":100,"../support/array-slice":101,"../support/clone-dense-json":102,"../support/get-valid-key":112,"../support/invalidate-node":116,"../support/is-object":118,"../support/options":123,"../support/update-graph":133,"../walk/walk-path-set":143}],81:[function(require,module,exports){ module.exports = invalidate_path_sets_as_json_values; var clone = require("../support/clone-dense-json"); var array_clone = require("../support/array-clone"); var array_slice = require("../support/array-slice"); var options = require("../support/options"); var walk_path_set = require("../walk/walk-path-set"); var is_object = require("../support/is-object"); var get_valid_key = require("../support/get-valid-key"); var update_graph = require("../support/update-graph"); var invalidate_node = require("../support/invalidate-node"); var collect = require("../lru/collect"); function invalidate_path_sets_as_json_values(model, pathsets, onNext) { var roots = options([], model); var index = -1; var count = pathsets.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; roots[0] = roots.root; roots.onNext = onNext; while (++index < count) { var pathset = pathsets[index]; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: null, errors: roots.errors, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } parent = parents[0]; } else { parent = nodes[0]; } var node = parent[key]; if (!is_top_level) { parents[0] = parent; nodes[0] = node; return; } if (is_branch) { parents[0] = nodes[0] = node; return; } nodes[0] = node; var lru = roots.lru; var size = node.$size || 0; var version = roots.version; invalidate_node(parent, node, key, roots.lru); update_graph(parent, size, version, lru); } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { var node = nodes[0]; var type = is_object(node) && node.$type || undefined; var onNext = roots.onNext; if (!!type && onNext) { onNext({ path: array_clone(requested), value: clone(roots, node, type, node && node.value) }); } roots.requestedPaths.push(array_slice(requested, roots.offset)); } },{"../lru/collect":82,"../support/array-clone":100,"../support/array-slice":101,"../support/clone-dense-json":102,"../support/get-valid-key":112,"../support/invalidate-node":116,"../support/is-object":118,"../support/options":123,"../support/update-graph":133,"../walk/walk-path-set":143}],82:[function(require,module,exports){ var __head = require("../internal/head"); var __tail = require("../internal/tail"); var __next = require("../internal/next"); var __prev = require("../internal/prev"); var update_graph = require("../support/update-graph"); module.exports = function(lru, expired, version, total, max, ratio) { var targetSize = max * ratio; var node, size; while(!!(node = expired.pop())) { size = node.$size || 0; total -= size; update_graph(node, size, version, lru); } if(total >= max) { var prev = lru[__tail]; while((total >= targetSize) && !!(node = prev)) { prev = prev[__prev]; size = node.$size || 0; total -= size; update_graph(node, size, version, lru); } if((lru[__tail] = lru[__prev] = prev) == null) { lru[__head] = lru[__next] = undefined; } else { prev[__next] = undefined; } } }; },{"../internal/head":64,"../internal/next":67,"../internal/prev":71,"../internal/tail":75,"../support/update-graph":133}],83:[function(require,module,exports){ var $expires_never = require("../values/expires-never"); var __head = require("../internal/head"); var __tail = require("../internal/tail"); var __next = require("../internal/next"); var __prev = require("../internal/prev"); var is_object = require("../support/is-object"); module.exports = function(root, node) { if(is_object(node) && (node.$expires !== $expires_never)) { var head = root[__head], tail = root[__tail], next = node[__next], prev = node[__prev]; if (node !== head) { (next != null && typeof next === "object") && (next[__prev] = prev); (prev != null && typeof prev === "object") && (prev[__next] = next); (next = head) && (head != null && typeof head === "object") && (head[__prev] = node); (root[__head] = root[__next] = head = node); (head[__next] = next); (head[__prev] = undefined); } if (tail == null || node === tail) { root[__tail] = root[__prev] = tail = prev || node; } } return node; }; },{"../internal/head":64,"../internal/next":67,"../internal/prev":71,"../internal/tail":75,"../support/is-object":118,"../values/expires-never":138}],84:[function(require,module,exports){ var __head = require("../internal/head"); var __tail = require("../internal/tail"); var __next = require("../internal/next"); var __prev = require("../internal/prev"); module.exports = function(root, node) { var head = root[__head], tail = root[__tail], next = node[__next], prev = node[__prev]; (next != null && typeof next === "object") && (next[__prev] = prev); (prev != null && typeof prev === "object") && (prev[__next] = next); (node === head) && (root[__head] = root[__next] = next); (node === tail) && (root[__tail] = root[__prev] = prev); node[__next] = node[__prev] = undefined; head = tail = next = prev = undefined; }; },{"../internal/head":64,"../internal/next":67,"../internal/prev":71,"../internal/tail":75}],85:[function(require,module,exports){ module.exports = { setPathSetsAsJSON: require('./set-json-values-as-json-dense'), setPathSetsAsJSONG: require('./set-json-values-as-json-graph'), setPathSetsAsPathMap: require('./set-json-values-as-json-sparse'), setPathSetsAsValues: require('./set-json-values-as-json-values'), setPathMapsAsJSON: require('./set-json-sparse-as-json-dense'), setPathMapsAsJSONG: require('./set-json-sparse-as-json-graph'), setPathMapsAsPathMap: require('./set-json-sparse-as-json-sparse'), setPathMapsAsValues: require('./set-json-sparse-as-json-values'), setJSONGsAsJSON: require('./set-json-graph-as-json-dense'), setJSONGsAsJSONG: require('./set-json-graph-as-json-graph'), setJSONGsAsPathMap: require('./set-json-graph-as-json-sparse'), setJSONGsAsValues: require('./set-json-graph-as-json-values'), setCache: require('./set-cache') }; },{"./set-cache":86,"./set-json-graph-as-json-dense":87,"./set-json-graph-as-json-graph":88,"./set-json-graph-as-json-sparse":89,"./set-json-graph-as-json-values":90,"./set-json-sparse-as-json-dense":91,"./set-json-sparse-as-json-graph":92,"./set-json-sparse-as-json-sparse":93,"./set-json-sparse-as-json-values":94,"./set-json-values-as-json-dense":95,"./set-json-values-as-json-graph":96,"./set-json-values-as-json-sparse":97,"./set-json-values-as-json-values":98}],86:[function(require,module,exports){ module.exports = set_cache; var $error = require("../types/error"); var $sentinel = require("../types/sentinel"); var clone = require("../support/clone-dense-json"); var array_clone = require("../support/array-clone"); var options = require("../support/options"); var walk_path_map = require("../walk/walk-path-map"); var is_object = require("../support/is-object"); var get_valid_key = require("../support/get-valid-key"); var create_branch = require("../support/create-branch"); var wrap_node = require("../support/wrap-node"); var replace_node = require("../support/replace-node"); var graph_node = require("../support/graph-node"); var update_back_refs = require("../support/update-back-refs"); var update_graph = require("../support/update-graph"); var inc_generation = require("../support/inc-generation"); var collect = require("../lru/collect"); function set_cache(model, pathmap, error_selector) { var roots = options([], model, error_selector); var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var keys_stack = []; roots[0] = roots.root; walk_path_map(onNode, onEdge, pathmap, keys_stack, 0, roots, parents, nodes, requested, optimized); collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return model; } function onNode(pathmap, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } parent = parents[0]; } else { parent = nodes[0]; } var node = parent[key], type; if (is_branch) { type = is_object(node) && node.$type || undefined; node = create_branch(roots, parent, node, type, key); parents[0] = nodes[0] = node; return; } var selector = roots.error_selector; var root = roots[0]; var size = is_object(node) && node.$size || 0; var mess = pathmap; type = is_object(mess) && mess.$type || undefined; mess = wrap_node(mess, type, !!type ? mess.value : mess); type || (type = $sentinel); if (type == $error && !!selector) { mess = selector(requested, mess); } node = replace_node(parent, node, mess, key, roots.lru); node = graph_node(root, parent, node, key, inc_generation()); update_graph(parent, size - node.$size, roots.version, roots.lru); nodes[0] = node; } function onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset) { } },{"../lru/collect":82,"../support/array-clone":100,"../support/clone-dense-json":102,"../support/create-branch":110,"../support/get-valid-key":112,"../support/graph-node":113,"../support/inc-generation":114,"../support/is-object":118,"../support/options":123,"../support/replace-node":126,"../support/update-back-refs":132,"../support/update-graph":133,"../support/wrap-node":134,"../types/error":135,"../types/sentinel":137,"../walk/walk-path-map":141}],87:[function(require,module,exports){ module.exports = set_json_graph_as_json_dense; var $path = require("../types/path"); var clone = require("../support/clone-dense-json"); var array_clone = require("../support/array-clone"); var options = require("../support/options"); var walk_path_set = require("../walk/walk-path-set-soft-link"); var is_object = require("../support/is-object"); var get_valid_key = require("../support/get-valid-key"); var merge_node = require("../support/merge-node"); var node_as_miss = require("../support/treat-node-as-missing-path-set"); var node_as_error = require("../support/treat-node-as-error"); var clone_success = require("../support/clone-success-paths"); var collect = require("../lru/collect"); function set_json_graph_as_json_dense(model, envelopes, values, error_selector) { var roots = []; roots.offset = model._path.length; roots.bound = []; roots = options(roots, model, error_selector); var index = -1; var index2 = -1; var count = envelopes.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var json, hasValue, hasValues; roots[0] = roots.root; while (++index < count) { var envelope = envelopes[index]; var pathsets = envelope.paths; var jsong = envelope.jsong || envelope.values || envelope.value; var index3 = -1; var count2 = pathsets.length; roots[2] = jsong; nodes[2] = jsong; while (++index3 < count2) { json = values && values[++index2]; if (is_object(json)) { roots.json = roots[3] = parents[3] = nodes[3] = json.json || (json.json = {}); } else { roots.json = roots[3] = parents[3] = nodes[3] = undefined; } var pathset = pathsets[index3]; roots.index = index3; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); hasValue = roots.hasValue; if (!!hasValue) { hasValues = true; if (is_object(json)) { json.json = roots.json; } delete roots.json; delete roots.hasValue; } else if (is_object(json)) { delete json.json; } } } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, messageParent, json; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } json = parents[3]; parent = parents[0]; messageParent = parents[2]; } else { json = is_keyset && nodes[3] || parents[3]; parent = nodes[0]; messageParent = nodes[2]; } var node = parent[key]; var message = messageParent && messageParent[key]; nodes[2] = message; nodes[0] = node = merge_node(roots, parent, node, messageParent, message, key); if (!is_top_level) { parents[0] = parent; parents[2] = messageParent; return; } var length = requested.length; var offset = roots.offset; parents[3] = json; if (is_branch) { parents[0] = node; parents[2] = message; if ((length > offset) && is_keyset && !!json) { nodes[3] = json[keyset] || (json[keyset] = {}); } } } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { var json; var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathset, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); if (node_as_error(roots, node, type, requested) === false) { if(keyset == null) { roots.json = clone(roots, node, type, node && node.value); } else if(!!(json = parents[3])) { json[keyset] = clone(roots, node, type, node && node.value); } roots.hasValue = true; } } } },{"../lru/collect":82,"../support/array-clone":100,"../support/clone-dense-json":102,"../support/clone-success-paths":108,"../support/get-valid-key":112,"../support/is-object":118,"../support/merge-node":121,"../support/options":123,"../support/treat-node-as-error":128,"../support/treat-node-as-missing-path-set":130,"../types/path":136,"../walk/walk-path-set-soft-link":142}],88:[function(require,module,exports){ module.exports = set_json_graph_as_json_graph; var $path = require("../types/path"); var clone = require("../support/clone-graph-json"); var array_clone = require("../support/array-clone"); var options = require("../support/options"); var walk_path_set = require("../walk/walk-path-set-soft-link"); var is_object = require("../support/is-object"); var get_valid_key = require("../support/get-valid-key"); var merge_node = require("../support/merge-node"); var node_as_miss = require("../support/treat-node-as-missing-path-set"); var node_as_error = require("../support/treat-node-as-error"); var clone_success = require("../support/clone-success-paths"); var promote = require("../lru/promote"); var collect = require("../lru/collect"); function set_json_graph_as_json_graph(model, envelopes, values, error_selector) { var roots = []; roots.offset = 0; roots.bound = []; roots = options(roots, model, error_selector); var index = -1; var count = envelopes.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var json = values[0]; var hasValue; roots[0] = roots.root; roots[1] = parents[1] = nodes[1] = json.jsong || (json.jsong = {}); roots.requestedPaths = json.paths || (json.paths = roots.requestedPaths); while (++index < count) { var envelope = envelopes[index]; var pathsets = envelope.paths; var jsong = envelope.jsong || envelope.values || envelope.value; var index2 = -1; var count2 = pathsets.length; roots[2] = jsong; nodes[2] = jsong; while (++index2 < count2) { var pathset = pathsets[index2]; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); } } hasValue = roots.hasValue; if(hasValue) { json.jsong = roots[1]; } else { delete json.jsong; delete json.paths; } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, messageParent, json, jsonkey; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } json = parents[1]; parent = parents[0]; messageParent = parents[2]; } else { json = nodes[1]; parent = nodes[0]; messageParent = nodes[2]; } var jsonkey = key; var node = parent[key]; var message = messageParent && messageParent[key]; nodes[2] = message; nodes[0] = node = merge_node(roots, parent, node, messageParent, message, key); if (!is_top_level) { parents[0] = parent; parents[2] = messageParent; parents[1] = json; nodes[1] = json[jsonkey] || (json[jsonkey] = {}); return; } var type = is_object(node) && node.$type || undefined; if (is_branch) { parents[0] = node; parents[2] = message; parents[1] = json; if (type == $path) { json[jsonkey] = clone(roots, node, type, node.value); roots.hasValue = true; } else { nodes[1] = json[jsonkey] || (json[jsonkey] = {}); } return; } json[jsonkey] = clone(roots, node, type, node && node.value); roots.hasValue = true; } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { var json; var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathset, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); promote(roots.lru, node); if (keyset == null && !roots.hasValue && (keyset = get_valid_key(optimized)) == null) { node = clone(roots, node, type, node && node.value); json = roots[1]; json.$type = node.$type; json.value = node.value; } roots.hasValue = true; } } },{"../lru/collect":82,"../lru/promote":83,"../support/array-clone":100,"../support/clone-graph-json":103,"../support/clone-success-paths":108,"../support/get-valid-key":112,"../support/is-object":118,"../support/merge-node":121,"../support/options":123,"../support/treat-node-as-error":128,"../support/treat-node-as-missing-path-set":130,"../types/path":136,"../walk/walk-path-set-soft-link":142}],89:[function(require,module,exports){ module.exports = set_json_graph_as_json_sparse; var $path = require("../types/path"); var clone = require("../support/clone-dense-json"); var array_clone = require("../support/array-clone"); var options = require("../support/options"); var walk_path_set = require("../walk/walk-path-set-soft-link"); var is_object = require("../support/is-object"); var get_valid_key = require("../support/get-valid-key"); var merge_node = require("../support/merge-node"); var node_as_miss = require("../support/treat-node-as-missing-path-set"); var node_as_error = require("../support/treat-node-as-error"); var clone_success = require("../support/clone-success-paths"); var collect = require("../lru/collect"); function set_json_graph_as_json_sparse(model, envelopes, values, error_selector) { var roots = []; roots.offset = model._path.length; roots.bound = []; roots = options(roots, model, error_selector); var index = -1; var count = envelopes.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var json = values[0]; var hasValue; roots[0] = roots.root; roots[3] = parents[3] = nodes[3] = json.json || (json.json = {}); while (++index < count) { var envelope = envelopes[index]; var pathsets = envelope.paths; var jsong = envelope.jsong || envelope.values || envelope.value; var index2 = -1; var count2 = pathsets.length; roots[2] = jsong; nodes[2] = jsong; while (++index2 < count2) { var pathset = pathsets[index2]; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); } } hasValue = roots.hasValue; if(hasValue) { json.json = roots[3]; } else { delete json.json; } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, messageParent, json, jsonkey; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } jsonkey = get_valid_key(requested); json = parents[3]; parent = parents[0]; messageParent = parents[2]; } else { jsonkey = key; json = nodes[3]; parent = nodes[0]; messageParent = nodes[2]; } var node = parent[key]; var message = messageParent && messageParent[key]; nodes[2] = message; nodes[0] = node = merge_node(roots, parent, node, messageParent, message, key); if (!is_top_level) { parents[0] = parent; parents[2] = messageParent; return; } parents[3] = json; if (is_branch) { var length = requested.length; var offset = roots.offset; var type = is_object(node) && node.$type || undefined; parents[0] = node; parents[2] = message; if ((length > offset) && (!type || type == $path)) { nodes[3] = json[jsonkey] || (json[jsonkey] = {}); } } } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { var json; var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathset, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); if (node_as_error(roots, node, type, requested) === false) { if (keyset == null && !roots.hasValue && (keyset = get_valid_key(optimized)) == null) { node = clone(roots, node, type, node && node.value); json = roots[3]; json.$type = node.$type; json.value = node.value; } else { json = parents[3]; json[key] = clone(roots, node, type, node && node.value); } roots.hasValue = true; } } } },{"../lru/collect":82,"../support/array-clone":100,"../support/clone-dense-json":102,"../support/clone-success-paths":108,"../support/get-valid-key":112,"../support/is-object":118,"../support/merge-node":121,"../support/options":123,"../support/treat-node-as-error":128,"../support/treat-node-as-missing-path-set":130,"../types/path":136,"../walk/walk-path-set-soft-link":142}],90:[function(require,module,exports){ module.exports = set_json_graph_as_json_values; var $path = require("../types/path"); var clone = require("../support/clone-dense-json"); var array_clone = require("../support/array-clone"); var array_slice = require("../support/array-slice"); var options = require("../support/options"); var walk_path_set = require("../walk/walk-path-set-soft-link"); var is_object = require("../support/is-object"); var get_valid_key = require("../support/get-valid-key"); var merge_node = require("../support/merge-node"); var node_as_miss = require("../support/treat-node-as-missing-path-set"); var node_as_error = require("../support/treat-node-as-error"); var clone_success = require("../support/clone-success-paths"); var collect = require("../lru/collect"); function set_json_graph_as_json_values(model, envelopes, onNext, error_selector) { var roots = []; roots.offset = model._path.length; roots.bound = []; roots = options(roots, model, error_selector); var index = -1; var count = envelopes.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; roots[0] = roots.root; roots.onNext = onNext; while (++index < count) { var envelope = envelopes[index]; var pathsets = envelope.paths; var jsong = envelope.jsong || envelope.values || envelope.value; var index2 = -1; var count2 = pathsets.length; roots[2] = jsong; nodes[2] = jsong; while (++index2 < count2) { var pathset = pathsets[index2]; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); } } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: null, errors: roots.errors, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset) { var parent, messageParent; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } parent = parents[0]; messageParent = parents[2]; } else { parent = nodes[0]; messageParent = nodes[2]; } var node = parent[key]; var message = messageParent && messageParent[key]; nodes[2] = message; nodes[0] = node = merge_node(roots, parent, node, messageParent, message, key); if (!is_top_level) { parents[0] = parent; parents[2] = messageParent; return; } if (is_branch) { parents[0] = node; parents[2] = message; } } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset, is_keyset) { var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathset, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); if (node_as_error(roots, node, type, requested) === false) { roots.onNext({ path: array_slice(requested, roots.offset), value: clone(roots, node, type, node && node.value) }); } } } },{"../lru/collect":82,"../support/array-clone":100,"../support/array-slice":101,"../support/clone-dense-json":102,"../support/clone-success-paths":108,"../support/get-valid-key":112,"../support/is-object":118,"../support/merge-node":121,"../support/options":123,"../support/treat-node-as-error":128,"../support/treat-node-as-missing-path-set":130,"../types/path":136,"../walk/walk-path-set-soft-link":142}],91:[function(require,module,exports){ module.exports = set_json_sparse_as_json_dense; var $path = require("../types/path"); var $error = require("../types/error"); var $sentinel = require("../types/sentinel"); var clone = require("../support/clone-dense-json"); var array_clone = require("../support/array-clone"); var options = require("../support/options"); var walk_path_map = require("../walk/walk-path-map"); var is_object = require("../support/is-object"); var get_valid_key = require("../support/get-valid-key"); var create_branch = require("../support/create-branch"); var wrap_node = require("../support/wrap-node"); var replace_node = require("../support/replace-node"); var graph_node = require("../support/graph-node"); var update_back_refs = require("../support/update-back-refs"); var update_graph = require("../support/update-graph"); var inc_generation = require("../support/inc-generation"); var node_as_miss = require("../support/treat-node-as-missing-path-map"); var node_as_error = require("../support/treat-node-as-error"); var clone_success = require("../support/clone-success-paths"); var collect = require("../lru/collect"); function set_json_sparse_as_json_dense(model, pathmaps, values, error_selector) { var roots = options([], model, error_selector); var index = -1; var count = pathmaps.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var keys_stack = []; var json, hasValue, hasValues; roots[0] = roots.root; while (++index < count) { json = values && values[index]; if (is_object(json)) { roots.json = roots[3] = parents[3] = nodes[3] = json.json || (json.json = {}) } else { roots.json = roots[3] = parents[3] = nodes[3] = undefined; } var pathmap = pathmaps[index]; roots.index = index; walk_path_map(onNode, onEdge, pathmap, keys_stack, 0, roots, parents, nodes, requested, optimized); hasValue = roots.hasValue; if (!!hasValue) { hasValues = true; if (is_object(json)) { json.json = roots.json; } delete roots.json; delete roots.hasValue; } else if (is_object(json)) { delete json.json; } } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, hasValue: hasValues, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathmap, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, json; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } json = parents[3]; parent = parents[0]; } else { json = is_keyset && nodes[3] || parents[3]; parent = nodes[0]; } var node = parent[key], type; if (!is_top_level) { type = is_object(node) && node.$type || undefined; type = type && is_branch && "." || type; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; return; } parents[3] = json; if (is_branch) { type = is_object(node) && node.$type || undefined; node = create_branch(roots, parent, node, type, key); parents[0] = nodes[0] = node; if (is_keyset && !!json) { nodes[3] = json[keyset] || (json[keyset] = {}); } return; } var selector = roots.error_selector; var root = roots[0]; var size = is_object(node) && node.$size || 0; var mess = pathmap; type = is_object(mess) && mess.$type || undefined; mess = wrap_node(mess, type, !!type ? mess.value : mess); type || (type = $sentinel); if (type == $error && !!selector) { mess = selector(requested, mess); } node = replace_node(parent, node, mess, key, roots.lru); node = graph_node(root, parent, node, key, inc_generation()); update_graph(parent, size - node.$size, roots.version, roots.lru); nodes[0] = node; } function onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset) { var json; var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathmap, keys_stack, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); if (node_as_error(roots, node, type, requested) === false) { if(keyset == null) { roots.json = clone(roots, node, type, node && node.value); } else if(!!(json = parents[3])) { json[keyset] = clone(roots, node, type, node && node.value); } roots.hasValue = true; } } } },{"../lru/collect":82,"../support/array-clone":100,"../support/clone-dense-json":102,"../support/clone-success-paths":108,"../support/create-branch":110,"../support/get-valid-key":112,"../support/graph-node":113,"../support/inc-generation":114,"../support/is-object":118,"../support/options":123,"../support/replace-node":126,"../support/treat-node-as-error":128,"../support/treat-node-as-missing-path-map":129,"../support/update-back-refs":132,"../support/update-graph":133,"../support/wrap-node":134,"../types/error":135,"../types/path":136,"../types/sentinel":137,"../walk/walk-path-map":141}],92:[function(require,module,exports){ module.exports = set_json_sparse_as_json_graph; var $path = require("../types/path"); var $error = require("../types/error"); var $sentinel = require("../types/sentinel"); var clone = require("../support/clone-graph-json"); var array_clone = require("../support/array-clone"); var options = require("../support/options"); var walk_path_map = require("../walk/walk-path-map-soft-link"); var is_object = require("../support/is-object"); var get_valid_key = require("../support/get-valid-key"); var create_branch = require("../support/create-branch"); var wrap_node = require("../support/wrap-node"); var replace_node = require("../support/replace-node"); var graph_node = require("../support/graph-node"); var update_back_refs = require("../support/update-back-refs"); var update_graph = require("../support/update-graph"); var inc_generation = require("../support/inc-generation"); var node_as_miss = require("../support/treat-node-as-missing-path-map"); var node_as_error = require("../support/treat-node-as-error"); var clone_success = require("../support/clone-success-paths"); var promote = require("../lru/promote"); var collect = require("../lru/collect"); function set_json_sparse_as_json_graph(model, pathmaps, values, error_selector) { var roots = options([], model, error_selector); var index = -1; var count = pathmaps.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var keys_stack = []; var json = values[0]; var hasValue; roots[0] = roots.root; roots[1] = parents[1] = nodes[1] = json.jsong || (json.jsong = {}); roots.requestedPaths = json.paths || (json.paths = roots.requestedPaths); while (++index < count) { var pathmap = pathmaps[index]; walk_path_map(onNode, onEdge, pathmap, keys_stack, 0, roots, parents, nodes, requested, optimized); } hasValue = roots.hasValue; if(hasValue) { json.jsong = roots[1]; } else { delete json.jsong; delete json.paths; } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, hasValue: hasValue, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathmap, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, json; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } json = parents[1]; parent = parents[0]; } else { json = nodes[1]; parent = nodes[0]; } var jsonkey = key; var node = parent[key], type; if (!is_top_level) { type = is_object(node) && node.$type || undefined; type = type && is_branch && "." || type; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; parents[1] = json; if (type == $path) { json[jsonkey] = clone(roots, node, type, node.value); roots.hasValue = true; } else { nodes[1] = json[jsonkey] || (json[jsonkey] = {}); } return; } if (is_branch) { type = is_object(node) && node.$type || undefined; node = create_branch(roots, parent, node, type, key); type = node.$type; parents[0] = nodes[0] = node; parents[1] = json; if (type == $path) { json[jsonkey] = clone(roots, node, type, node.value); roots.hasValue = true; } else { nodes[1] = json[jsonkey] || (json[jsonkey] = {}); } return; } var selector = roots.error_selector; var root = roots[0]; var size = is_object(node) && node.$size || 0; var mess = pathmap; type = is_object(mess) && mess.$type || undefined; mess = wrap_node(mess, type, !!type ? mess.value : mess); type || (type = $sentinel); if (type == $error && !!selector) { mess = selector(requested, mess); } node = replace_node(parent, node, mess, key, roots.lru); node = graph_node(root, parent, node, key, inc_generation()); update_graph(parent, size - node.$size, roots.version, roots.lru); nodes[0] = node; json[jsonkey] = clone(roots, node, type, node && node.value); roots.hasValue = true; } function onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset) { var json; var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathmap, keys_stack, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); promote(roots.lru, node); if (keyset == null && !roots.hasValue && (keyset = get_valid_key(optimized)) == null) { node = clone(roots, node, type, node && node.value); json = roots[1]; json.$type = node.$type; json.value = node.value; } roots.hasValue = true; } } },{"../lru/collect":82,"../lru/promote":83,"../support/array-clone":100,"../support/clone-graph-json":103,"../support/clone-success-paths":108,"../support/create-branch":110,"../support/get-valid-key":112,"../support/graph-node":113,"../support/inc-generation":114,"../support/is-object":118,"../support/options":123,"../support/replace-node":126,"../support/treat-node-as-error":128,"../support/treat-node-as-missing-path-map":129,"../support/update-back-refs":132,"../support/update-graph":133,"../support/wrap-node":134,"../types/error":135,"../types/path":136,"../types/sentinel":137,"../walk/walk-path-map-soft-link":140}],93:[function(require,module,exports){ module.exports = set_json_sparse_as_json_sparse; var $path = require("../types/path"); var $error = require("../types/error"); var $sentinel = require("../types/sentinel"); var clone = require("../support/clone-dense-json"); var array_clone = require("../support/array-clone"); var options = require("../support/options"); var walk_path_map = require("../walk/walk-path-map"); var is_object = require("../support/is-object"); var get_valid_key = require("../support/get-valid-key"); var create_branch = require("../support/create-branch"); var wrap_node = require("../support/wrap-node"); var replace_node = require("../support/replace-node"); var graph_node = require("../support/graph-node"); var update_back_refs = require("../support/update-back-refs"); var update_graph = require("../support/update-graph"); var inc_generation = require("../support/inc-generation"); var node_as_miss = require("../support/treat-node-as-missing-path-map"); var node_as_error = require("../support/treat-node-as-error"); var clone_success = require("../support/clone-success-paths"); var collect = require("../lru/collect"); function set_json_sparse_as_json_sparse(model, pathmaps, values, error_selector) { var roots = options([], model, error_selector); var index = -1; var count = pathmaps.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var keys_stack = []; var json = values[0]; var hasValue; roots[0] = roots.root; roots[3] = parents[3] = nodes[3] = json.json || (json.json = {}); while (++index < count) { var pathmap = pathmaps[index]; walk_path_map(onNode, onEdge, pathmap, keys_stack, 0, roots, parents, nodes, requested, optimized); } hasValue = roots.hasValue; if(hasValue) { json.json = roots[3]; } else { delete json.json; } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, hasValue: hasValue, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathmap, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, json, jsonkey; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } jsonkey = get_valid_key(requested); json = parents[3]; parent = parents[0]; } else { jsonkey = key; json = nodes[3]; parent = nodes[0]; } var node = parent[key], type; if (!is_top_level) { type = is_object(node) && node.$type || undefined; type = type && is_branch && "." || type; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; return; } parents[3] = json; if (is_branch) { type = is_object(node) && node.$type || undefined; node = create_branch(roots, parent, node, type, key); parents[0] = nodes[0] = node; nodes[3] = json[jsonkey] || (json[jsonkey] = {}); return; } var selector = roots.error_selector; var root = roots[0]; var size = is_object(node) && node.$size || 0; var mess = pathmap; type = is_object(mess) && mess.$type || undefined; mess = wrap_node(mess, type, !!type ? mess.value : mess); type || (type = $sentinel); if (type == $error && !!selector) { mess = selector(requested, mess); } node = replace_node(parent, node, mess, key, roots.lru); node = graph_node(root, parent, node, key, inc_generation()); update_graph(parent, size - node.$size, roots.version, roots.lru); nodes[0] = node; } function onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset) { var json; var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathmap, keys_stack, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); if (node_as_error(roots, node, type, requested) === false) { if (keyset == null && !roots.hasValue && (keyset = get_valid_key(optimized)) == null) { node = clone(roots, node, type, node && node.value); json = roots[3]; json.$type = node.$type; json.value = node.value; } else { json = parents[3]; json[key] = clone(roots, node, type, node && node.value); } roots.hasValue = true; } } } },{"../lru/collect":82,"../support/array-clone":100,"../support/clone-dense-json":102,"../support/clone-success-paths":108,"../support/create-branch":110,"../support/get-valid-key":112,"../support/graph-node":113,"../support/inc-generation":114,"../support/is-object":118,"../support/options":123,"../support/replace-node":126,"../support/treat-node-as-error":128,"../support/treat-node-as-missing-path-map":129,"../support/update-back-refs":132,"../support/update-graph":133,"../support/wrap-node":134,"../types/error":135,"../types/path":136,"../types/sentinel":137,"../walk/walk-path-map":141}],94:[function(require,module,exports){ module.exports = set_path_map_as_json_values; var $error = require("../types/error"); var $sentinel = require("../types/sentinel"); var clone = require("../support/clone-dense-json"); var array_clone = require("../support/array-clone"); var options = require("../support/options"); var walk_path_map = require("../walk/walk-path-map"); var is_object = require("../support/is-object"); var get_valid_key = require("../support/get-valid-key"); var create_branch = require("../support/create-branch"); var wrap_node = require("../support/wrap-node"); var replace_node = require("../support/replace-node"); var graph_node = require("../support/graph-node"); var update_back_refs = require("../support/update-back-refs"); var update_graph = require("../support/update-graph"); var inc_generation = require("../support/inc-generation"); var node_as_miss = require("../support/treat-node-as-missing-path-map"); var node_as_error = require("../support/treat-node-as-error"); var clone_success = require("../support/clone-success-paths"); var collect = require("../lru/collect"); function set_path_map_as_json_values(model, pathmaps, onNext, error_selector) { var roots = options([], model, error_selector); var index = -1; var count = pathmaps.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var keys_stack = []; roots[0] = roots.root; roots.onNext = onNext; while (++index < count) { var pathmap = pathmaps[index]; walk_path_map(onNode, onEdge, pathmap, keys_stack, 0, roots, parents, nodes, requested, optimized); } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: null, errors: roots.errors, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathmap, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } parent = parents[0]; } else { parent = nodes[0]; } var node = parent[key], type; if (!is_top_level) { type = is_object(node) && node.$type || undefined; type = type && is_branch && "." || type; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; return; } if (is_branch) { type = is_object(node) && node.$type || undefined; node = create_branch(roots, parent, node, type, key); parents[0] = nodes[0] = node; return; } var selector = roots.error_selector; var root = roots[0]; var size = is_object(node) && node.$size || 0; var mess = pathmap; type = is_object(mess) && mess.$type || undefined; mess = wrap_node(mess, type, !!type ? mess.value : mess); type || (type = $sentinel); if (type == $error && !!selector) { mess = selector(requested, mess); } node = replace_node(parent, node, mess, key, roots.lru); node = graph_node(root, parent, node, key, inc_generation()); update_graph(parent, size - node.$size, roots.version, roots.lru); nodes[0] = node; } function onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset) { var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathmap, keys_stack, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); if (node_as_error(roots, node, type, requested) === false) { roots.onNext({ path: array_clone(requested), value: clone(roots, node, type, node && node.value) }); } } } },{"../lru/collect":82,"../support/array-clone":100,"../support/clone-dense-json":102,"../support/clone-success-paths":108,"../support/create-branch":110,"../support/get-valid-key":112,"../support/graph-node":113,"../support/inc-generation":114,"../support/is-object":118,"../support/options":123,"../support/replace-node":126,"../support/treat-node-as-error":128,"../support/treat-node-as-missing-path-map":129,"../support/update-back-refs":132,"../support/update-graph":133,"../support/wrap-node":134,"../types/error":135,"../types/sentinel":137,"../walk/walk-path-map":141}],95:[function(require,module,exports){ module.exports = set_json_values_as_json_dense; var $path = require("../types/path"); var $error = require("../types/error"); var $sentinel = require("../types/sentinel"); var clone = require("../support/clone-dense-json"); var array_clone = require("../support/array-clone"); var options = require("../support/options"); var walk_path_set = require("../walk/walk-path-set"); var is_object = require("../support/is-object"); var get_valid_key = require("../support/get-valid-key"); var create_branch = require("../support/create-branch"); var wrap_node = require("../support/wrap-node"); var invalidate_node = require("../support/invalidate-node"); var replace_node = require("../support/replace-node"); var graph_node = require("../support/graph-node"); var update_back_refs = require("../support/update-back-refs"); var update_graph = require("../support/update-graph"); var inc_generation = require("../support/inc-generation"); var node_as_miss = require("../support/treat-node-as-missing-path-set"); var node_as_error = require("../support/treat-node-as-error"); var clone_success = require("../support/clone-success-paths"); var collect = require("../lru/collect"); function set_json_values_as_json_dense(model, pathvalues, values, error_selector) { var roots = options([], model, error_selector); var index = -1; var count = pathvalues.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var json, hasValue, hasValues; roots[0] = roots.root; while (++index < count) { json = values && values[index]; if (is_object(json)) { roots.json = roots[3] = parents[3] = nodes[3] = json.json || (json.json = {}) } else { roots.json = roots[3] = parents[3] = nodes[3] = undefined; } var pv = pathvalues[index]; var pathset = pv.path; roots.value = pv.value; roots.index = index; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); hasValue = roots.hasValue; if (!!hasValue) { hasValues = true; if (is_object(json)) { json.json = roots.json; } delete roots.json; delete roots.hasValue; } else if (is_object(json)) { delete json.json; } } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, hasValue: hasValues, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, json; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } json = parents[3]; parent = parents[0]; } else { json = is_keyset && nodes[3] || parents[3]; parent = nodes[0]; } var node = parent[key], type; if (!is_top_level) { type = is_object(node) && node.$type || undefined; type = type && is_branch && "." || type; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; return; } parents[3] = json; if (is_branch) { type = is_object(node) && node.$type || undefined; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; if (is_keyset && !!json) { nodes[3] = json[keyset] || (json[keyset] = {}); } return; } var selector = roots.error_selector; var root = roots[0]; var size = is_object(node) && node.$size || 0; var mess = roots.value; if(mess === undefined && roots.headless) { invalidate_node(parent, node, key, roots.lru); update_graph(parent, size, roots.version, roots.lru); node = undefined; } else { type = is_object(mess) && mess.$type || undefined; mess = wrap_node(mess, type, !!type ? mess.value : mess); type || (type = $sentinel); if (type == $error && !!selector) { mess = selector(requested, mess); } node = replace_node(parent, node, mess, key, roots.lru); node = graph_node(root, parent, node, key, inc_generation()); update_graph(parent, size - node.$size, roots.version, roots.lru); } nodes[0] = node; } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { var json; var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathset, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); if (node_as_error(roots, node, type, requested) === false) { if(keyset == null) { roots.json = clone(roots, node, type, node && node.value); } else if(!!(json = parents[3])) { json[keyset] = clone(roots, node, type, node && node.value); } roots.hasValue = true; } } } },{"../lru/collect":82,"../support/array-clone":100,"../support/clone-dense-json":102,"../support/clone-success-paths":108,"../support/create-branch":110,"../support/get-valid-key":112,"../support/graph-node":113,"../support/inc-generation":114,"../support/invalidate-node":116,"../support/is-object":118,"../support/options":123,"../support/replace-node":126,"../support/treat-node-as-error":128,"../support/treat-node-as-missing-path-set":130,"../support/update-back-refs":132,"../support/update-graph":133,"../support/wrap-node":134,"../types/error":135,"../types/path":136,"../types/sentinel":137,"../walk/walk-path-set":143}],96:[function(require,module,exports){ module.exports = set_json_values_as_json_graph; var $path = require("../types/path"); var $error = require("../types/error"); var $sentinel = require("../types/sentinel"); var clone = require("../support/clone-graph-json"); var array_clone = require("../support/array-clone"); var options = require("../support/options"); var walk_path_set = require("../walk/walk-path-set-soft-link"); var is_object = require("../support/is-object"); var get_valid_key = require("../support/get-valid-key"); var create_branch = require("../support/create-branch"); var wrap_node = require("../support/wrap-node"); var invalidate_node = require("../support/invalidate-node"); var replace_node = require("../support/replace-node"); var graph_node = require("../support/graph-node"); var update_back_refs = require("../support/update-back-refs"); var update_graph = require("../support/update-graph"); var inc_generation = require("../support/inc-generation"); var node_as_miss = require("../support/treat-node-as-missing-path-set"); var node_as_error = require("../support/treat-node-as-error"); var clone_success = require("../support/clone-success-paths"); var promote = require("../lru/promote"); var collect = require("../lru/collect"); function set_json_values_as_json_graph(model, pathvalues, values, error_selector) { var roots = options([], model, error_selector); var index = -1; var count = pathvalues.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var json = values[0]; var hasValue; roots[0] = roots.root; roots[1] = parents[1] = nodes[1] = json.jsong || (json.jsong = {}); roots.requestedPaths = json.paths || (json.paths = roots.requestedPaths); while (++index < count) { var pv = pathvalues[index]; var pathset = pv.path; roots.value = pv.value; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); } hasValue = roots.hasValue; if(hasValue) { json.jsong = roots[1]; } else { delete json.jsong; delete json.paths; } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, hasValue: hasValue, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, json; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } json = parents[1]; parent = parents[0]; } else { json = nodes[1]; parent = nodes[0]; } var jsonkey = key; var node = parent[key], type; if (!is_top_level) { type = is_object(node) && node.$type || undefined; type = type && is_branch && "." || type; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; parents[1] = json; if (type == $path) { json[jsonkey] = clone(roots, node, type, node.value); roots.hasValue = true; } else { nodes[1] = json[jsonkey] || (json[jsonkey] = {}); } return; } if (is_branch) { type = is_object(node) && node.$type || undefined; node = create_branch(roots, parent, node, type, key); type = node.$type; parents[0] = parent; nodes[0] = node; parents[1] = json; if (type == $path) { json[jsonkey] = clone(roots, node, type, node.value); roots.hasValue = true; } else { nodes[1] = json[jsonkey] || (json[jsonkey] = {}); } return; } var selector = roots.error_selector; var root = roots[0]; var size = is_object(node) && node.$size || 0; var mess = roots.value; if(mess === undefined && roots.headless) { invalidate_node(parent, node, key, roots.lru); update_graph(parent, size, roots.version, roots.lru); node = undefined; } else { type = is_object(mess) && mess.$type || undefined; mess = wrap_node(mess, type, !!type ? mess.value : mess); type || (type = $sentinel); if (type == $error && !!selector) { mess = selector(requested, mess); } node = replace_node(parent, node, mess, key, roots.lru); node = graph_node(root, parent, node, key, inc_generation()); update_graph(parent, size - node.$size, roots.version, roots.lru); } nodes[0] = node; json[jsonkey] = clone(roots, node, type, node && node.value); roots.hasValue = true; } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { var json; var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathset, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); promote(roots.lru, node); if (keyset == null && !roots.hasValue && (keyset = get_valid_key(optimized)) == null) { node = clone(roots, node, type, node && node.value); json = roots[1]; json.$type = node.$type; json.value = node.value; } roots.hasValue = true; } } },{"../lru/collect":82,"../lru/promote":83,"../support/array-clone":100,"../support/clone-graph-json":103,"../support/clone-success-paths":108,"../support/create-branch":110,"../support/get-valid-key":112,"../support/graph-node":113,"../support/inc-generation":114,"../support/invalidate-node":116,"../support/is-object":118,"../support/options":123,"../support/replace-node":126,"../support/treat-node-as-error":128,"../support/treat-node-as-missing-path-set":130,"../support/update-back-refs":132,"../support/update-graph":133,"../support/wrap-node":134,"../types/error":135,"../types/path":136,"../types/sentinel":137,"../walk/walk-path-set-soft-link":142}],97:[function(require,module,exports){ module.exports = set_json_values_as_json_sparse; var $path = require("../types/path"); var $error = require("../types/error"); var $sentinel = require("../types/sentinel"); var clone = require("../support/clone-dense-json"); var array_clone = require("../support/array-clone"); var options = require("../support/options"); var walk_path_set = require("../walk/walk-path-set"); var is_object = require("../support/is-object"); var get_valid_key = require("../support/get-valid-key"); var create_branch = require("../support/create-branch"); var wrap_node = require("../support/wrap-node"); var invalidate_node = require("../support/invalidate-node"); var replace_node = require("../support/replace-node"); var graph_node = require("../support/graph-node"); var update_back_refs = require("../support/update-back-refs"); var update_graph = require("../support/update-graph"); var inc_generation = require("../support/inc-generation"); var node_as_miss = require("../support/treat-node-as-missing-path-set"); var node_as_error = require("../support/treat-node-as-error"); var clone_success = require("../support/clone-success-paths"); var collect = require("../lru/collect"); function set_json_values_as_json_sparse(model, pathvalues, values, error_selector) { var roots = options([], model, error_selector); var index = -1; var count = pathvalues.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var json = values[0]; var hasValue; roots[0] = roots.root; roots[3] = parents[3] = nodes[3] = json.json || (json.json = {}); while (++index < count) { var pv = pathvalues[index]; var pathset = pv.path; roots.value = pv.value; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); } hasValue = roots.hasValue; if(hasValue) { json.json = roots[3]; } else { delete json.json; } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, hasValue: hasValue, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, json, jsonkey; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } jsonkey = get_valid_key(requested); json = parents[3]; parent = parents[0]; } else { jsonkey = key; json = nodes[3]; parent = nodes[0]; } var node = parent[key], type; if (!is_top_level) { type = is_object(node) && node.$type || undefined; type = type && is_branch && "." || type; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; return; } parents[3] = json; if (is_branch) { type = is_object(node) && node.$type || undefined; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; nodes[3] = json[jsonkey] || (json[jsonkey] = {}); return; } var selector = roots.error_selector; var root = roots[0]; var size = is_object(node) && node.$size || 0; var mess = roots.value; if(mess === undefined && roots.headless) { invalidate_node(parent, node, key, roots.lru); update_graph(parent, size, roots.version, roots.lru); node = undefined; } else { type = is_object(mess) && mess.$type || undefined; mess = wrap_node(mess, type, !!type ? mess.value : mess); type || (type = $sentinel); if (type == $error && !!selector) { mess = selector(requested, mess); } node = replace_node(parent, node, mess, key, roots.lru); node = graph_node(root, parent, node, key, inc_generation()); update_graph(parent, size - node.$size, roots.version, roots.lru); } nodes[0] = node; } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { var json; var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathset, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); if (node_as_error(roots, node, type, requested) === false) { if (keyset == null && !roots.hasValue && (keyset = get_valid_key(optimized)) == null) { node = clone(roots, node, type, node && node.value); json = roots[3]; json.$type = node.$type; json.value = node.value; } else { json = parents[3]; json[key] = clone(roots, node, type, node && node.value); } roots.hasValue = true; } } } },{"../lru/collect":82,"../support/array-clone":100,"../support/clone-dense-json":102,"../support/clone-success-paths":108,"../support/create-branch":110,"../support/get-valid-key":112,"../support/graph-node":113,"../support/inc-generation":114,"../support/invalidate-node":116,"../support/is-object":118,"../support/options":123,"../support/replace-node":126,"../support/treat-node-as-error":128,"../support/treat-node-as-missing-path-set":130,"../support/update-back-refs":132,"../support/update-graph":133,"../support/wrap-node":134,"../types/error":135,"../types/path":136,"../types/sentinel":137,"../walk/walk-path-set":143}],98:[function(require,module,exports){ module.exports = set_json_values_as_json_values; var $error = require("../types/error"); var $sentinel = require("../types/sentinel"); var clone = require("../support/clone-dense-json"); var array_clone = require("../support/array-clone"); var options = require("../support/options"); var walk_path_set = require("../walk/walk-path-set"); var is_object = require("../support/is-object"); var get_valid_key = require("../support/get-valid-key"); var create_branch = require("../support/create-branch"); var wrap_node = require("../support/wrap-node"); var invalidate_node = require("../support/invalidate-node"); var replace_node = require("../support/replace-node"); var graph_node = require("../support/graph-node"); var update_back_refs = require("../support/update-back-refs"); var update_graph = require("../support/update-graph"); var inc_generation = require("../support/inc-generation"); var node_as_miss = require("../support/treat-node-as-missing-path-set"); var node_as_error = require("../support/treat-node-as-error"); var clone_success = require("../support/clone-success-paths"); var collect = require("../lru/collect"); function set_json_values_as_json_values(model, pathvalues, onNext, error_selector) { var roots = options([], model, error_selector); var index = -1; var count = pathvalues.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; roots[0] = roots.root; roots.onNext = onNext; while (++index < count) { var pv = pathvalues[index]; var pathset = pv.path; roots.value = pv.value; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: null, errors: roots.errors, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent; if (key == null) { if ((key = get_valid_key(optimized, nodes)) == null) { return; } parent = parents[0]; } else { parent = nodes[0]; } var node = parent[key], type; if (!is_top_level) { type = is_object(node) && node.$type || undefined; type = type && is_branch && "." || type; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; return; } if (is_branch) { type = is_object(node) && node.$type || undefined; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; return; } var selector = roots.error_selector; var root = roots[0]; var size = is_object(node) && node.$size || 0; var mess = roots.value; if(mess === undefined && roots.headless) { invalidate_node(parent, node, key, roots.lru); update_graph(parent, size, roots.version, roots.lru); node = undefined; } else { type = is_object(mess) && mess.$type || undefined; mess = wrap_node(mess, type, !!type ? mess.value : mess); type || (type = $sentinel); if (type == $error && !!selector) { mess = selector(requested, mess); } node = replace_node(parent, node, mess, key, roots.lru); node = graph_node(root, parent, node, key, inc_generation()); update_graph(parent, size - node.$size, roots.version, roots.lru); } nodes[0] = node; } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathset, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); if (node_as_error(roots, node, type, requested) === false) { roots.onNext({ path: array_clone(requested), value: clone(roots, node, type, node && node.value) }); } } } },{"../lru/collect":82,"../support/array-clone":100,"../support/clone-dense-json":102,"../support/clone-success-paths":108,"../support/create-branch":110,"../support/get-valid-key":112,"../support/graph-node":113,"../support/inc-generation":114,"../support/invalidate-node":116,"../support/is-object":118,"../support/options":123,"../support/replace-node":126,"../support/treat-node-as-error":128,"../support/treat-node-as-missing-path-set":130,"../support/update-back-refs":132,"../support/update-graph":133,"../support/wrap-node":134,"../types/error":135,"../types/sentinel":137,"../walk/walk-path-set":143}],99:[function(require,module,exports){ module.exports = function(array, value) { var i = -1; var n = array.length; var array2 = new Array(n + 1); while(++i < n) { array2[i] = array[i]; } array2[i] = value; return array2; }; },{}],100:[function(require,module,exports){ module.exports = function(array) { var i = -1; var n = array.length; var array2 = new Array(n); while(++i < n) { array2[i] = array[i]; } return array2; }; },{}],101:[function(require,module,exports){ module.exports = function(array, index) { var i = -1; var n = array.length - index; var array2 = new Array(n); while(++i < n) { array2[i] = array[i + index]; } return array2; }; },{}],102:[function(require,module,exports){ var $sentinel = require("../types/sentinel"); var clone = require("./clone"); module.exports = function(roots, node, type, value) { if(node == null || value === undefined) { return { $type: $sentinel }; } if(roots.boxed == true) { return !!type && clone(node) || node; } return value; } },{"../types/sentinel":137,"./clone":109}],103:[function(require,module,exports){ var $sentinel = require("../types/sentinel"); var clone = require("./clone"); var is_primitive = require("./is-primitive"); module.exports = function(roots, node, type, value) { if(node == null || value === undefined) { return { $type: $sentinel }; } if(roots.boxed == true) { return !!type && clone(node) || node; } if(!type || (type === $sentinel && is_primitive(value))) { return value; } return clone(node); } },{"../types/sentinel":137,"./clone":109,"./is-primitive":119}],104:[function(require,module,exports){ var clone_requested = require("./clone-requested-path"); var clone_optimized = require("./clone-optimized-path"); var walk_path_map = require("../walk/walk-path-map-soft-link"); var is_object = require("./is-object"); var empty = []; module.exports = function(roots, pathmap, keys_stack, depth, requested, optimized) { var patset_keys = explode_keys(pathmap, keys_stack.concat(), depth); var pathset = patset_keys.map(function(keys) { keys = keys.filter(function(key) { return key != "null"; }); switch(keys.length) { case 0: return null; case 1: return keys[0]; default: return keys; } }); roots.requestedMissingPaths.push(clone_requested(roots.bound, requested, pathset, depth, roots.index)); roots.optimizedMissingPaths.push(clone_optimized(optimized, pathset, depth)); } function explode_keys(pathmap, keys_stack, depth) { if(is_object(pathmap)) { var keys = Object.keys(pathmap); var keys2 = keys_stack[depth] || (keys_stack[depth] = []); keys2.push.apply(keys2, keys); keys.forEach(function(key) { explode_keys(pathmap[key], keys_stack, depth + 1); }); } return keys_stack; } },{"../walk/walk-path-map-soft-link":140,"./clone-optimized-path":106,"./clone-requested-path":107,"./is-object":118}],105:[function(require,module,exports){ var clone_requested_path = require("./clone-requested-path"); var clone_optimized_path = require("./clone-optimized-path"); module.exports = function(roots, pathset, depth, requested, optimized) { roots.requestedMissingPaths.push(clone_requested_path(roots.bound, requested, pathset, depth, roots.index)); roots.optimizedMissingPaths.push(clone_optimized_path(optimized, pathset, depth)); } },{"./clone-optimized-path":106,"./clone-requested-path":107}],106:[function(require,module,exports){ module.exports = function(optimized, pathset, depth) { var x; var i = -1; var j = depth - 1; var n = optimized.length; var m = pathset.length; var array2 = []; while(++i < n) { array2[i] = optimized[i]; } while(++j < m) { if((x = pathset[j]) != null) { array2[i++] = x; } } return array2; } },{}],107:[function(require,module,exports){ var is_object = require("./is-object"); module.exports = function(bound, requested, pathset, depth, index) { var x; var i = -1; var j = -1; var l = 0; var m = requested.length; var n = bound.length; var array2 = []; while(++i < n) { array2[i] = bound[i]; } while(++j < m) { if((x = requested[j]) != null) { if(is_object(pathset[l++])) { array2[i++] = [x]; } else { array2[i++] = x; } } } m = n + l + pathset.length - depth; while(i < m) { array2[i++] = pathset[l++]; } if(index != null) { array2.pathSetIndex = index; } return array2; } },{"./is-object":118}],108:[function(require,module,exports){ var array_slice = require("./array-slice"); var array_clone = require("./array-clone"); module.exports = function(roots, requested, optimized) { roots.requestedPaths.push(array_slice(requested, roots.offset)); roots.optimizedPaths.push(array_clone(optimized)); } },{"./array-clone":100,"./array-slice":101}],109:[function(require,module,exports){ var is_object = require("./is-object"); var prefix = require("../internal/prefix"); module.exports = function(value) { var dest = value, src = dest, i = -1, n, keys, key; if(is_object(dest)) { dest = {}; keys = Object.keys(src); n = keys.length; while(++i < n) { key = keys[i]; if(key[0] !== prefix) { dest[key] = src[key]; } } } return dest; } },{"../internal/prefix":70,"./is-object":118}],110:[function(require,module,exports){ var $path = require("../types/path"); var $expired = "expired"; var replace_node = require("./replace-node"); var graph_node = require("./graph-node"); var update_back_refs = require("./update-back-refs"); var is_primitive = require("./is-primitive"); var is_expired = require("./is-expired"); module.exports = function(roots, parent, node, type, key) { if(!!type && is_expired(roots, node)) { type = $expired; } if((!!type && type != $path) || is_primitive(node)) { node = replace_node(parent, node, {}, key, roots.lru); node = graph_node(roots[0], parent, node, key, 0); node = update_back_refs(node, roots.version); } return node; } },{"../types/path":136,"./graph-node":113,"./is-expired":117,"./is-primitive":119,"./replace-node":126,"./update-back-refs":132}],111:[function(require,module,exports){ var __ref = require("../internal/ref"); var __context = require("../internal/context"); var __ref_index = require("../internal/ref-index"); var __refs_length = require("../internal/refs-length"); module.exports = function(node) { var ref, i = -1, n = node[__refs_length] || 0; while(++i < n) { if((ref = node[__ref + i]) !== undefined) { ref[__context] = ref[__ref_index] = node[__ref + i] = undefined; } } node[__refs_length] = undefined } },{"../internal/context":62,"../internal/ref":73,"../internal/ref-index":72,"../internal/refs-length":74}],112:[function(require,module,exports){ module.exports = function(path) { var key, index = path.length - 1; do { if((key = path[index]) != null) { return key; } } while(--index > -1); return null; } },{}],113:[function(require,module,exports){ var __parent = require("../internal/parent"); var __key = require("../internal/key"); var __generation = require("../internal/generation"); module.exports = function(root, parent, node, key, generation) { node[__parent] = parent; node[__key] = key; node[__generation] = generation; return node; } },{"../internal/generation":63,"../internal/key":66,"../internal/parent":69}],114:[function(require,module,exports){ var generation = 0; module.exports = function() { return generation++; } },{}],115:[function(require,module,exports){ var version = 0; module.exports = function() { return version++; } },{}],116:[function(require,module,exports){ module.exports = invalidate; var is_object = require("./is-object"); var remove_node = require("./remove-node"); var prefix = require("../internal/prefix"); function invalidate(parent, node, key, lru) { if(remove_node(parent, node, key, lru)) { var type = is_object(node) && node.$type || undefined; if(type == null) { var keys = Object.keys(node); for(var i = -1, n = keys.length; ++i < n;) { var key = keys[i]; if(key[0] !== prefix && key[0] !== "$") { invalidate(node, node[key], key, lru); } } } return true; } return false; } },{"../internal/prefix":70,"./is-object":118,"./remove-node":125}],117:[function(require,module,exports){ var $expires_now = require("../values/expires-now"); var $expires_never = require("../values/expires-never"); var __invalidated = require("../internal/invalidated"); var now = require("./now"); var splice = require("../lru/splice"); module.exports = function(roots, node) { var expires = node.$expires; if((expires != null ) && ( expires != $expires_never ) && ( expires == $expires_now || expires < now())) { if(!node[__invalidated]) { node[__invalidated] = true; roots.expired.push(node); splice(roots.lru, node); } return true; } return false; } },{"../internal/invalidated":65,"../lru/splice":84,"../values/expires-never":138,"../values/expires-now":139,"./now":122}],118:[function(require,module,exports){ var obj_typeof = "object"; module.exports = function(value) { return value != null && typeof value == obj_typeof; } },{}],119:[function(require,module,exports){ var obj_typeof = "object"; module.exports = function(value) { return value == null || typeof value != obj_typeof; } },{}],120:[function(require,module,exports){ module.exports = key_to_keyset; var __offset = require("../internal/offset"); var is_array = Array.isArray; var is_object = require("./is-object"); function key_to_keyset(key, iskeyset) { if(iskeyset) { if(is_array(key)) { key = key[key[__offset]]; return key_to_keyset(key, is_object(key)); } else { return key[__offset]; } } return key; } },{"../internal/offset":68,"./is-object":118}],121:[function(require,module,exports){ var $self = "./"; var $path = require("../types/path"); var $sentinel = require("../types/sentinel"); var $expires_now = require("../values/expires-now"); var is_object = require("./is-object"); var is_primitive = require("./is-primitive"); var is_expired = require("./is-expired"); var promote = require("../lru/promote"); var wrap_node = require("./wrap-node"); var graph_node = require("./graph-node"); var replace_node = require("../support/replace-node"); var update_graph = require("../support/update-graph"); var inc_generation = require("./inc-generation"); var invalidate_node = require("./invalidate-node"); module.exports = function(roots, parent, node, messageParent, message, key) { var type, messageType, node_is_object, message_is_object; // If the cache and message are the same, we can probably return early: // - If they're both null, return null. // - If they're both branches, return the branch. // - If they're both edges, continue below. if(node == message) { if(node == null) { return null; } else if(node_is_object = is_object(node)) { type = node.$type; if(type == null) { if(node[$self] == null) { return graph_node(roots[0], parent, node, key, 0); } return node; } } } else if(node_is_object = is_object(node)) { type = node.$type; } var value, messageValue; if(type == $path) { if(message == null) { // If the cache is an expired reference, but the message // is empty, remove the cache value and return undefined // so we build a missing path. if(is_expired(roots, node)) { invalidate_node(parent, node, key, roots.lru); return undefined; } // If the cache has a reference and the message is empty, // leave the cache alone and follow the reference. return node; } else if(message_is_object = is_object(message)) { messageType = message.$type; // If the cache and the message are both references, // check if we need to replace the cache reference. if(messageType == $path) { if(node === message) { // If the cache and message are the same reference, // we performed a whole-branch merge of one of the // grandparents. If we've previously graphed this // reference, break early. if(node[$self] != null) { return node; } } // If the message doesn't expire immediately and is newer than the // cache (or either cache or message don't have timestamps), attempt // to use the message value. // Note: Number and `undefined` compared LT/GT to `undefined` is `false`. else if(( is_expired(roots, message) === false) && (( message.$timestamp < node.$timestamp) === false)) { // Compare the cache and message references. // - If they're the same, break early so we don't insert. // - If they're different, replace the cache reference. value = node.value; messageValue = message.value; var count = value.length; // If the reference lengths are equal, check their keys for equality. if(count === messageValue.length) { while(--count > -1) { // If any of their keys are different, replace the reference // in the cache with the reference in the message. if(value[count] !== messageValue[count]) { break; } } // If all their keys are equal, leave the cache value alone. if(count === -1) { return node; } } } } } } else { if(message_is_object = is_object(message)) { messageType = message.$type; } if(node_is_object && !type) { // Otherwise if the cache is a branch and the message is either // null or also a branch, continue with the cache branch. if(message == null || (message_is_object && !messageType)) { return node; } } } // If the message is an expired edge, report it back out so we don't build a missing path, but // don't insert it into the cache. If a value exists in the cache that didn't come from a // whole-branch grandparent merge, remove the cache value. if(!!messageType && !!message[$self] && is_expired(roots, message)) { if(node_is_object && node != message) { invalidate_node(parent, node, key, roots.lru); } return message; } // If the cache is a value, but the message is a branch, merge the branch over the value. else if(!!type && message_is_object && !messageType) { node = replace_node(parent, node, message, key, roots.lru); return graph_node(roots[0], parent, node, key, 0); } // If the message is a value, insert it into the cache. else if(!message_is_object || !!messageType) { var offset = 0; // If we've arrived at this message value, but didn't perform a whole-branch merge // on one of its ancestors, replace the cache node with the message value. if(node != message) { messageValue || (messageValue = !!messageType ? message.value : message); message = wrap_node(message, messageType, messageValue); var size = node_is_object && node.$size || 0; var messageSize = message.$size; offset = size - messageSize; node = replace_node(parent, node, message, key, roots.lru); update_graph(parent, offset, roots.version, roots.lru); node = graph_node(roots[0], parent, node, key, inc_generation()); } // If the cache and the message are the same value, we branch-merged one of its // ancestors. Give the message a $size and $type, attach its graph pointers, and // update the cache sizes and generations. else if(node_is_object && node[$self] == null) { node = parent[key] = wrap_node(node, type, node.value); offset = -node.$size; update_graph(parent, offset, roots.version, roots.lru); node = graph_node(roots[0], parent, node, key, inc_generation()); } // Otherwise, cache and message are the same primitive value. Wrap in a sentinel and insert. else { node = parent[key] = wrap_node(node, type, node); offset = -node.$size; update_graph(parent, offset, roots.version, roots.lru); node = graph_node(roots[0], parent, node, key, inc_generation()); } // If the node is already expired, return undefined to build a missing path. // if(is_expired(roots, node)) { // return undefined; // } // Promote the message edge in the LRU. promote(roots.lru, node); } // If we get here, the cache is empty and the message is a branch. // Merge the whole branch over. else if(node == null) { node = parent[key] = graph_node(roots[0], parent, message, key, 0); } return node; } },{"../lru/promote":83,"../support/replace-node":126,"../support/update-graph":133,"../types/path":136,"../types/sentinel":137,"../values/expires-now":139,"./graph-node":113,"./inc-generation":114,"./invalidate-node":116,"./is-expired":117,"./is-object":118,"./is-primitive":119,"./wrap-node":134}],122:[function(require,module,exports){ module.exports = Date.now; },{}],123:[function(require,module,exports){ var inc_version = require("../support/inc-version"); var getBoundValue = require('../get/getBoundValue'); module.exports = function(options, model, error_selector) { var bound = options.bound || (options.bound = model._path || []); var root = options.root || (options.root = model._cache); var nodes = options.nodes || (options.nodes = []); var lru = options.lru || (options.lru = model._root); options.expired || (options.expired = lru.expired); options.errors || (options.errors = []); options.requestedPaths || (options.requestedPaths = []); options.optimizedPaths || (options.optimizedPaths = []); options.requestedMissingPaths || (options.requestedMissingPaths = []); options.optimizedMissingPaths || (options.optimizedMissingPaths = []); options.boxed = model._boxed || false; options.materialized = model._materialized; options.errorsAsValues = model._treatErrorsAsValues || false; options.headless = model._dataSource == null; options.version = inc_version(); options.offset || (options.offset = 0); options.error_selector = error_selector || model._errorSelector; if(bound.length) { nodes[0] = getBoundValue(model, bound).value; } else { nodes[0] = root; } return options; }; },{"../get/getBoundValue":45,"../support/inc-version":115}],124:[function(require,module,exports){ module.exports = permute_keyset; var __offset = require("../internal/offset"); var is_array = Array.isArray; var is_object = require("./is-object"); function permute_keyset(key) { if(is_array(key)) { if(key[__offset] === undefined) { key[__offset] = -1; if(key.length == 0) { return false; } } if(++key[__offset] >= key.length) { return permute_keyset(key[key[__offset] = -1]); } else { return true; } } else if(is_object(key)) { if(key[__offset] === undefined) { key[__offset] = (key.from || (key.from = 0)) - 1; if(key.to === undefined) { if(key.length === undefined) { throw new Error("Range keysets must specify at least one index to retrieve."); } else if(key.length === 0) { return false; } key.to = key.from + (key.length || 1) - 1; } } if(++key[__offset] > key.to) { key[__offset] = key.from - 1; return false; } return true; } return false; } },{"../internal/offset":68,"./is-object":118}],125:[function(require,module,exports){ var $path = require("../types/path"); var __parent = require("../internal/parent"); var unlink = require("./unlink"); var delete_back_refs = require("./delete-back-refs"); var splice = require("../lru/splice"); var is_object = require("./is-object"); module.exports = function(parent, node, key, lru) { if(is_object(node)) { var type = node.$type; if(!!type) { if(type == $path) { unlink(node); } splice(lru, node); } delete_back_refs(node); parent[key] = node[__parent] = undefined; return true; } return false; } },{"../internal/parent":69,"../lru/splice":84,"../types/path":136,"./delete-back-refs":111,"./is-object":118,"./unlink":131}],126:[function(require,module,exports){ var transfer_back_refs = require("./transfer-back-refs"); var invalidate_node = require("./invalidate-node"); module.exports = function(parent, node, replacement, key, lru) { if(node != null && node !== replacement && typeof node == "object") { transfer_back_refs(node, replacement); invalidate_node(parent, node, key, lru); } return parent[key] = replacement; } },{"./invalidate-node":116,"./transfer-back-refs":127}],127:[function(require,module,exports){ var __ref = require("../internal/ref"); var __context = require("../internal/context"); var __refs_length = require("../internal/refs-length"); module.exports = function(node, dest) { var nodeRefsLength = node[__refs_length] || 0, destRefsLength = dest[__refs_length] || 0, i = -1, ref; while(++i < nodeRefsLength) { ref = node[__ref + i]; if(ref !== undefined) { ref[__context] = dest; dest[__ref + (destRefsLength + i)] = ref; node[__ref + i] = undefined; } } dest[__refs_length] = nodeRefsLength + destRefsLength; node[__refs_length] = ref = undefined; } },{"../internal/context":62,"../internal/ref":73,"../internal/refs-length":74}],128:[function(require,module,exports){ var $error = require("../types/error"); var promote = require("../lru/promote"); var array_clone = require("./array-clone"); module.exports = function(roots, node, type, path) { if(node == null) { return false; } promote(roots.lru, node); if(type != $error || roots.errorsAsValues) { return false; } roots.errors.push({ path: array_clone(path), value: node.value }); return true; }; },{"../lru/promote":83,"../types/error":135,"./array-clone":100}],129:[function(require,module,exports){ var $sentinel = require("../types/sentinel"); var clone_misses = require("./clone-missing-path-maps"); var is_expired = require("./is-expired"); module.exports = function(roots, node, type, pathmap, keys_stack, depth, requested, optimized) { var dematerialized = !roots.materialized; if(node == null && dematerialized) { clone_misses(roots, pathmap, keys_stack, depth, requested, optimized); return true; } else if(!!type) { if(type == $sentinel && node.value === undefined && dematerialized && !roots.boxed) { return true; } else if(is_expired(roots, node)) { clone_misses(roots, pathmap, keys_stack, depth, requested, optimized); return true; } } return false; }; },{"../types/sentinel":137,"./clone-missing-path-maps":104,"./is-expired":117}],130:[function(require,module,exports){ var $sentinel = require("../types/sentinel"); var clone_misses = require("./clone-missing-path-sets"); var is_expired = require("./is-expired"); module.exports = function(roots, node, type, pathset, depth, requested, optimized) { var dematerialized = !roots.materialized; if(node == null && dematerialized) { clone_misses(roots, pathset, depth, requested, optimized); return true; } else if(!!type) { if(type == $sentinel && node.value === undefined && dematerialized && !roots.boxed) { return true; } else if(is_expired(roots, node)) { clone_misses(roots, pathset, depth, requested, optimized); return true; } } return false; }; },{"../types/sentinel":137,"./clone-missing-path-sets":105,"./is-expired":117}],131:[function(require,module,exports){ var __ref = require("../internal/ref"); var __context = require("../internal/context"); var __ref_index = require("../internal/ref-index"); var __refs_length = require("../internal/refs-length"); module.exports = function(ref) { var destination = ref[__context]; if(destination) { var i = (ref[__ref_index] || 0) - 1, n = (destination[__refs_length] || 0) - 1; while(++i <= n) { destination[__ref + i] = destination[__ref + (i + 1)]; } destination[__refs_length] = n; ref[__ref_index] = ref[__context] = destination = undefined; } } },{"../internal/context":62,"../internal/ref":73,"../internal/ref-index":72,"../internal/refs-length":74}],132:[function(require,module,exports){ module.exports = update_back_refs; var __ref = require("../internal/ref"); var __parent = require("../internal/parent"); var __version = require("../internal/version"); var __generation = require("../internal/generation"); var __refs_length = require("../internal/refs-length"); var generation = require("./inc-generation"); function update_back_refs(node, version) { if(node && node[__version] !== version) { node[__version] = version; node[__generation] = generation(); update_back_refs(node[__parent], version); var i = -1, n = node[__refs_length] || 0; while(++i < n) { update_back_refs(node[__ref + i], version); } } return node; } },{"../internal/generation":63,"../internal/parent":69,"../internal/ref":73,"../internal/refs-length":74,"../internal/version":76,"./inc-generation":114}],133:[function(require,module,exports){ var __key = require("../internal/key"); var __version = require("../internal/version"); var __parent = require("../internal/parent"); var remove_node = require("./remove-node"); var update_back_refs = require("./update-back-refs"); module.exports = function(node, offset, version, lru) { var child; while(child = node) { node = child[__parent]; if((child.$size = (child.$size || 0) - offset) <= 0 && node != null) { remove_node(node, child, child[__key], lru); } else if(child[__version] !== version) { update_back_refs(child, version); } } } },{"../internal/key":66,"../internal/parent":69,"../internal/version":76,"./remove-node":125,"./update-back-refs":132}],134:[function(require,module,exports){ var $path = require("../types/path"); var $error = require("../types/error"); var $sentinel = require("../types/sentinel"); var now = require("./now"); var clone = require("./clone"); var is_array = Array.isArray; var is_object = require("./is-object"); module.exports = function(node, type, value) { var dest = node, size = 0; if(!!type) { dest = clone(node); size = dest.$size; // } // if(type == $path) { // dest = clone(node); // size = 50 + (value.length || 1); // } else if(is_object(node) && (type || (type = node.$type))) { // dest = clone(node); // size = dest.$size; } else { dest = { value: value }; type = $sentinel; } if(size <= 0 || size == null) { switch(typeof value) { case "number": case "boolean": case "function": case "undefined": size = 51; break; case "object": size = is_array(value) && (50 + value.length) || 51; break; case "string": size = 50 + value.length; break; } } var expires = is_object(node) && node.$expires || undefined; if(typeof expires === "number" && expires < 0) { dest.$expires = now() + (expires * -1); } dest.$type = type; dest.$size = size; return dest; } },{"../types/error":135,"../types/path":136,"../types/sentinel":137,"./clone":109,"./is-object":118,"./now":122}],135:[function(require,module,exports){ module.exports = "error"; },{}],136:[function(require,module,exports){ module.exports = "ref"; },{}],137:[function(require,module,exports){ module.exports = "sentinel"; },{}],138:[function(require,module,exports){ module.exports = 1; },{}],139:[function(require,module,exports){ module.exports = 0; },{}],140:[function(require,module,exports){ module.exports = walk_path_map; var prefix = require("../internal/prefix"); var $path = require("../types/path"); var walk_reference = require("./walk-reference"); var array_slice = require("../support/array-slice"); var array_clone = require("../support/array-clone"); var array_append = require("../support/array-append"); var is_expired = require("../support/is-expired"); var is_primitive = require("../support/is-primitive"); var is_object = require("../support/is-object"); var is_array = Array.isArray; var promote = require("../lru/promote"); function walk_path_map(onNode, onEdge, pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset, is_keyset) { var node = nodes[0]; if(is_primitive(pathmap) || is_primitive(node)) { return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset); } var type = node.$type; while(type === $path) { if(is_expired(roots, node)) { nodes[0] = undefined; return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset); } promote(roots.lru, node); var container = node; var reference = node.value; nodes[0] = parents[0] = roots[0]; nodes[1] = parents[1] = roots[1]; nodes[2] = parents[2] = roots[2]; walk_reference(onNode, container, reference, roots, parents, nodes, requested, optimized); node = nodes[0]; if(node == null) { optimized = array_clone(reference); return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset); } else if(is_primitive(node) || ((type = node.$type) && type != $path)) { onNode(pathmap, roots, parents, nodes, requested, optimized, true, null, keyset, false); return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, array_append(requested, null), optimized, key, keyset); } } if(type != null) { return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset); } var keys = keys_stack[depth] = Object.keys(pathmap); if(keys.length == 0) { return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset); } var is_outer_keyset = keys.length > 1; for(var i = -1, n = keys.length; ++i < n;) { var inner_key = keys[i]; if((inner_key[0] === prefix) || (inner_key[0] === "$")) { continue; } var inner_keyset = is_outer_keyset ? inner_key : keyset; var nodes2 = array_clone(nodes); var parents2 = array_clone(parents); var pathmap2 = pathmap[inner_key]; var requested2, optimized2, is_branch; var has_child_key = false; var is_branch = is_object(pathmap2) && !pathmap2.$type;// && !is_array(pathmap2); if(is_branch) { for(child_key in pathmap2) { if((child_key[0] === prefix) || (child_key[0] === "$")) { continue; } child_key = pathmap2.hasOwnProperty(child_key); break; } is_branch = child_key === true; } if(inner_key == "null") { requested2 = array_append(requested, null); optimized2 = array_clone(optimized); inner_key = key; inner_keyset = keyset; pathmap2 = pathmap; onNode(pathmap2, roots, parents2, nodes2, requested2, optimized2, true, is_branch, null, inner_keyset, false); } else { requested2 = array_append(requested, inner_key); optimized2 = array_append(optimized, inner_key); onNode(pathmap2, roots, parents2, nodes2, requested2, optimized2, true, is_branch, inner_key, inner_keyset, is_outer_keyset); } if(is_branch) { walk_path_map(onNode, onEdge, pathmap2, keys_stack, depth + 1, roots, parents2, nodes2, requested2, optimized2, inner_key, inner_keyset, is_outer_keyset ); } else { onEdge(pathmap2, keys_stack, depth, roots, parents2, nodes2, requested2, optimized2, inner_key, inner_keyset); } } } },{"../internal/prefix":70,"../lru/promote":83,"../support/array-append":99,"../support/array-clone":100,"../support/array-slice":101,"../support/is-expired":117,"../support/is-object":118,"../support/is-primitive":119,"../types/path":136,"./walk-reference":144}],141:[function(require,module,exports){ module.exports = walk_path_map; var prefix = require("../internal/prefix"); var __context = require("../internal/context"); var $path = require("../types/path"); var walk_reference = require("./walk-reference"); var array_slice = require("../support/array-slice"); var array_clone = require("../support/array-clone"); var array_append = require("../support/array-append"); var is_expired = require("../support/is-expired"); var is_primitive = require("../support/is-primitive"); var is_object = require("../support/is-object"); var is_array = Array.isArray; var promote = require("../lru/promote"); function walk_path_map(onNode, onEdge, pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset, is_keyset) { var node = nodes[0]; if(is_primitive(pathmap) || is_primitive(node)) { return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset); } var type = node.$type; while(type === $path) { if(is_expired(roots, node)) { nodes[0] = undefined; return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset); } promote(roots.lru, node); var container = node; var reference = node.value; node = node[__context]; if(node != null) { type = node.$type; optimized = array_clone(reference); nodes[0] = node; } else { nodes[0] = parents[0] = roots[0]; walk_reference(onNode, container, reference, roots, parents, nodes, requested, optimized); node = nodes[0]; if(node == null) { optimized = array_clone(reference); return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset); } else if(is_primitive(node) || ((type = node.$type) && type != $path)) { onNode(pathmap, roots, parents, nodes, requested, optimized, true, null, keyset, false); return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, array_append(requested, null), optimized, key, keyset); } } } if(type != null) { return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset); } var keys = keys_stack[depth] = Object.keys(pathmap); if(keys.length == 0) { return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset); } var is_outer_keyset = keys.length > 1; for(var i = -1, n = keys.length; ++i < n;) { var inner_key = keys[i]; if((inner_key[0] === prefix) || (inner_key[0] === "$")) { continue; } var inner_keyset = is_outer_keyset ? inner_key : keyset; var nodes2 = array_clone(nodes); var parents2 = array_clone(parents); var pathmap2 = pathmap[inner_key]; var requested2, optimized2, is_branch; var child_key = false; var is_branch = is_object(pathmap2) && !pathmap2.$type;// && !is_array(pathmap2); if(is_branch) { for(child_key in pathmap2) { if((child_key[0] === prefix) || (child_key[0] === "$")) { continue; } child_key = pathmap2.hasOwnProperty(child_key); break; } is_branch = child_key === true; } if(inner_key == "null") { requested2 = array_append(requested, null); optimized2 = array_clone(optimized); inner_key = key; inner_keyset = keyset; pathmap2 = pathmap; onNode(pathmap2, roots, parents2, nodes2, requested2, optimized2, true, is_branch, null, inner_keyset, false); } else { requested2 = array_append(requested, inner_key); optimized2 = array_append(optimized, inner_key); onNode(pathmap2, roots, parents2, nodes2, requested2, optimized2, true, is_branch, inner_key, inner_keyset, is_outer_keyset); } if(is_branch) { walk_path_map(onNode, onEdge, pathmap2, keys_stack, depth + 1, roots, parents2, nodes2, requested2, optimized2, inner_key, inner_keyset, is_outer_keyset ); } else { onEdge(pathmap2, keys_stack, depth, roots, parents2, nodes2, requested2, optimized2, inner_key, inner_keyset); } } } },{"../internal/context":62,"../internal/prefix":70,"../lru/promote":83,"../support/array-append":99,"../support/array-clone":100,"../support/array-slice":101,"../support/is-expired":117,"../support/is-object":118,"../support/is-primitive":119,"../types/path":136,"./walk-reference":144}],142:[function(require,module,exports){ module.exports = walk_path_set; var $path = require("../types/path"); var empty_array = new Array(0); var walk_reference = require("./walk-reference"); var array_slice = require("../support/array-slice"); var array_clone = require("../support/array-clone"); var array_append = require("../support/array-append"); var is_expired = require("../support/is-expired"); var is_primitive = require("../support/is-primitive"); var is_object = require("../support/is-object"); var keyset_to_key = require("../support/keyset-to-key"); var permute_keyset = require("../support/permute-keyset"); var promote = require("../lru/promote"); function walk_path_set(onNode, onEdge, pathset, depth, roots, parents, nodes, requested, optimized, key, keyset, is_keyset) { var node = nodes[0]; if(depth >= pathset.length || is_primitive(node)) { return onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset); } var type = node.$type; while(type === $path) { if(is_expired(roots, node)) { nodes[0] = undefined; return onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset); } promote(roots.lru, node); var container = node; var reference = node.value; nodes[0] = parents[0] = roots[0]; nodes[1] = parents[1] = roots[1]; nodes[2] = parents[2] = roots[2]; walk_reference(onNode, container, reference, roots, parents, nodes, requested, optimized); node = nodes[0]; if(node == null) { optimized = array_clone(reference); return onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset); } else if(is_primitive(node) || ((type = node.$type) && type != $path)) { onNode(pathset, roots, parents, nodes, requested, optimized, true, false, null, keyset, false); return onEdge(pathset, depth, roots, parents, nodes, array_append(requested, null), optimized, key, keyset); } } if(type != null) { return onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset); } var outer_key = pathset[depth]; var is_outer_keyset = is_object(outer_key); var is_branch = depth < pathset.length - 1; var run_once = false; while(is_outer_keyset && permute_keyset(outer_key) && (run_once = true) || (run_once = !run_once)) { var inner_key, inner_keyset; if(is_outer_keyset === true) { inner_key = keyset_to_key(outer_key, true); inner_keyset = inner_key; } else { inner_key = outer_key; inner_keyset = keyset; } var nodes2 = array_clone(nodes); var parents2 = array_clone(parents); var requested2, optimized2; if(inner_key == null) { requested2 = array_append(requested, null); optimized2 = array_clone(optimized); // optimized2 = optimized; inner_key = key; inner_keyset = keyset; onNode(pathset, roots, parents2, nodes2, requested2, optimized2, true, is_branch, null, inner_keyset, false); } else { requested2 = array_append(requested, inner_key); optimized2 = array_append(optimized, inner_key); onNode(pathset, roots, parents2, nodes2, requested2, optimized2, true, is_branch, inner_key, inner_keyset, is_outer_keyset); } walk_path_set(onNode, onEdge, pathset, depth + 1, roots, parents2, nodes2, requested2, optimized2, inner_key, inner_keyset, is_outer_keyset ); } } },{"../lru/promote":83,"../support/array-append":99,"../support/array-clone":100,"../support/array-slice":101,"../support/is-expired":117,"../support/is-object":118,"../support/is-primitive":119,"../support/keyset-to-key":120,"../support/permute-keyset":124,"../types/path":136,"./walk-reference":144}],143:[function(require,module,exports){ module.exports = walk_path_set; var prefix = require("../internal/prefix"); var __context = require("../internal/context"); var $path = require("../types/path"); var empty_array = new Array(0); var walk_reference = require("./walk-reference"); var array_slice = require("../support/array-slice"); var array_clone = require("../support/array-clone"); var array_append = require("../support/array-append"); var is_expired = require("../support/is-expired"); var is_primitive = require("../support/is-primitive"); var is_object = require("../support/is-object"); var keyset_to_key = require("../support/keyset-to-key"); var permute_keyset = require("../support/permute-keyset"); var promote = require("../lru/promote"); function walk_path_set(onNode, onEdge, pathset, depth, roots, parents, nodes, requested, optimized, key, keyset, is_keyset) { var node = nodes[0]; if(depth >= pathset.length || is_primitive(node)) { return onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset); } var type = node.$type; while(type === $path) { if(is_expired(roots, node)) { nodes[0] = undefined; return onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset); } promote(roots.lru, node); var container = node; var reference = node.value; node = node[__context]; if(node != null) { type = node.$type; optimized = array_clone(reference); nodes[0] = node; } else { nodes[0] = parents[0] = roots[0]; // nodes[1] = parents[1] = roots[1]; // nodes[2] = parents[2] = roots[2]; walk_reference(onNode, container, reference, roots, parents, nodes, requested, optimized); node = nodes[0]; if(node == null) { optimized = array_clone(reference); return onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset); } else if(is_primitive(node) || ((type = node.$type) && type != $path)) { onNode(pathset, roots, parents, nodes, requested, optimized, true, false, null, keyset, false); return onEdge(pathset, depth, roots, parents, nodes, array_append(requested, null), optimized, key, keyset); } } } if(type != null) { return onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset); } var outer_key = pathset[depth]; var is_outer_keyset = is_object(outer_key); var is_branch = depth < pathset.length - 1; var run_once = false; while(is_outer_keyset && permute_keyset(outer_key) && (run_once = true) || (run_once = !run_once)) { var inner_key, inner_keyset; if(is_outer_keyset === true) { inner_key = keyset_to_key(outer_key, true); inner_keyset = inner_key; } else { inner_key = outer_key; inner_keyset = keyset; } var nodes2 = array_clone(nodes); var parents2 = array_clone(parents); var requested2, optimized2; if(inner_key == null) { requested2 = array_append(requested, null); optimized2 = array_clone(optimized); // optimized2 = optimized; inner_key = key; inner_keyset = keyset; onNode(pathset, roots, parents2, nodes2, requested2, optimized2, true, is_branch, null, inner_keyset, false); } else { requested2 = array_append(requested, inner_key); optimized2 = array_append(optimized, inner_key); onNode(pathset, roots, parents2, nodes2, requested2, optimized2, true, is_branch, inner_key, inner_keyset, is_outer_keyset); } walk_path_set(onNode, onEdge, pathset, depth + 1, roots, parents2, nodes2, requested2, optimized2, inner_key, inner_keyset, is_outer_keyset ); } } },{"../internal/context":62,"../internal/prefix":70,"../lru/promote":83,"../support/array-append":99,"../support/array-clone":100,"../support/array-slice":101,"../support/is-expired":117,"../support/is-object":118,"../support/is-primitive":119,"../support/keyset-to-key":120,"../support/permute-keyset":124,"../types/path":136,"./walk-reference":144}],144:[function(require,module,exports){ module.exports = walk_reference; var prefix = require("../internal/prefix"); var __ref = require("../internal/ref"); var __context = require("../internal/context"); var __ref_index = require("../internal/ref-index"); var __refs_length = require("../internal/refs-length"); var is_object = require("../support/is-object"); var is_primitive = require("../support/is-primitive"); var array_slice = require("../support/array-slice"); var array_append = require("../support/array-append"); function walk_reference(onNode, container, reference, roots, parents, nodes, requested, optimized) { optimized.length = 0; var index = -1; var count = reference.length; var node, key, keyset; while(++index < count) { node = nodes[0]; if(node == null) { return nodes; } else if(is_primitive(node) || node.$type) { onNode(reference, roots, parents, nodes, requested, optimized, false, false, keyset, null, false); return nodes; } do { key = reference[index]; if(key != null) { keyset = key; optimized.push(key); onNode(reference, roots, parents, nodes, requested, optimized, false, index < count - 1, key, null, false); break; } } while(++index < count); } node = nodes[0]; if(is_object(node) && container[__context] !== node) { var backrefs = node[__refs_length] || 0; node[__refs_length] = backrefs + 1; node[__ref + backrefs] = container; container[__context] = node; container[__ref_index] = backrefs; } return nodes; } },{"../internal/context":62,"../internal/prefix":70,"../internal/ref":73,"../internal/ref-index":72,"../internal/refs-length":74,"../support/array-append":99,"../support/array-slice":101,"../support/is-object":118,"../support/is-primitive":119}],145:[function(require,module,exports){ /*global define:false require:false */ module.exports = (function(){ // Import Events var events = require('events') // Export Domain var domain = {} domain.createDomain = domain.create = function(){ var d = new events.EventEmitter() function emitError(e) { d.emit('error', e) } d.add = function(emitter){ emitter.on('error', emitError) } d.remove = function(emitter){ emitter.removeListener('error', emitError) } d.bind = function(fn){ return function(){ var args = Array.prototype.slice.call(arguments) try { fn.apply(null, args) } catch (err){ emitError(err) } } } d.intercept = function(fn){ return function(err){ if ( err ) { emitError(err) } else { var args = Array.prototype.slice.call(arguments, 1) try { fn.apply(null, args) } catch (err){ emitError(err) } } } } d.run = function(fn){ try { fn() } catch (err) { emitError(err) } return this }; d.dispose = function(){ this.removeAllListeners() return this }; d.enter = d.exit = function(){ return this } return d }; return domain }).call(this) },{"events":146}],146:[function(require,module,exports){ // Copyright Joyent, Inc. and other Node contributors. // // 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. function EventEmitter() { this._events = this._events || {}; this._maxListeners = this._maxListeners || undefined; } module.exports = EventEmitter; // Backwards-compat with node 0.10.x EventEmitter.EventEmitter = EventEmitter; EventEmitter.prototype._events = undefined; EventEmitter.prototype._maxListeners = undefined; // By default EventEmitters will print a warning if more than 10 listeners are // added to it. This is a useful default which helps finding memory leaks. EventEmitter.defaultMaxListeners = 10; // Obviously not all Emitters should be limited to 10. This function allows // that to be increased. Set to zero for unlimited. EventEmitter.prototype.setMaxListeners = function(n) { if (!isNumber(n) || n < 0 || isNaN(n)) throw TypeError('n must be a positive number'); this._maxListeners = n; return this; }; EventEmitter.prototype.emit = function(type) { var er, handler, len, args, i, listeners; if (!this._events) this._events = {}; // If there is no 'error' event listener then throw. if (type === 'error') { if (!this._events.error || (isObject(this._events.error) && !this._events.error.length)) { er = arguments[1]; if (er instanceof Error) { throw er; // Unhandled 'error' event } throw TypeError('Uncaught, unspecified "error" event.'); } } handler = this._events[type]; if (isUndefined(handler)) return false; if (isFunction(handler)) { switch (arguments.length) { // fast cases case 1: handler.call(this); break; case 2: handler.call(this, arguments[1]); break; case 3: handler.call(this, arguments[1], arguments[2]); break; // slower default: len = arguments.length; args = new Array(len - 1); for (i = 1; i < len; i++) args[i - 1] = arguments[i]; handler.apply(this, args); } } else if (isObject(handler)) { len = arguments.length; args = new Array(len - 1); for (i = 1; i < len; i++) args[i - 1] = arguments[i]; listeners = handler.slice(); len = listeners.length; for (i = 0; i < len; i++) listeners[i].apply(this, args); } return true; }; EventEmitter.prototype.addListener = function(type, listener) { var m; if (!isFunction(listener)) throw TypeError('listener must be a function'); if (!this._events) this._events = {}; // To avoid recursion in the case that type === "newListener"! Before // adding it to the listeners, first emit "newListener". if (this._events.newListener) this.emit('newListener', type, isFunction(listener.listener) ? listener.listener : listener); if (!this._events[type]) // Optimize the case of one listener. Don't need the extra array object. this._events[type] = listener; else if (isObject(this._events[type])) // If we've already got an array, just append. this._events[type].push(listener); else // Adding the second element, need to change to array. this._events[type] = [this._events[type], listener]; // Check for listener leak if (isObject(this._events[type]) && !this._events[type].warned) { var m; if (!isUndefined(this._maxListeners)) { m = this._maxListeners; } else { m = EventEmitter.defaultMaxListeners; } if (m && m > 0 && this._events[type].length > m) { this._events[type].warned = true; console.error('(node) warning: possible EventEmitter memory ' + 'leak detected. %d listeners added. ' + 'Use emitter.setMaxListeners() to increase limit.', this._events[type].length); if (typeof console.trace === 'function') { // not supported in IE 10 console.trace(); } } } return this; }; EventEmitter.prototype.on = EventEmitter.prototype.addListener; EventEmitter.prototype.once = function(type, listener) { if (!isFunction(listener)) throw TypeError('listener must be a function'); var fired = false; function g() { this.removeListener(type, g); if (!fired) { fired = true; listener.apply(this, arguments); } } g.listener = listener; this.on(type, g); return this; }; // emits a 'removeListener' event iff the listener was removed EventEmitter.prototype.removeListener = function(type, listener) { var list, position, length, i; if (!isFunction(listener)) throw TypeError('listener must be a function'); if (!this._events || !this._events[type]) return this; list = this._events[type]; length = list.length; position = -1; if (list === listener || (isFunction(list.listener) && list.listener === listener)) { delete this._events[type]; if (this._events.removeListener) this.emit('removeListener', type, listener); } else if (isObject(list)) { for (i = length; i-- > 0;) { if (list[i] === listener || (list[i].listener && list[i].listener === listener)) { position = i; break; } } if (position < 0) return this; if (list.length === 1) { list.length = 0; delete this._events[type]; } else { list.splice(position, 1); } if (this._events.removeListener) this.emit('removeListener', type, listener); } return this; }; EventEmitter.prototype.removeAllListeners = function(type) { var key, listeners; if (!this._events) return this; // not listening for removeListener, no need to emit if (!this._events.removeListener) { if (arguments.length === 0) this._events = {}; else if (this._events[type]) delete this._events[type]; return this; } // emit removeListener for all listeners on all events if (arguments.length === 0) { for (key in this._events) { if (key === 'removeListener') continue; this.removeAllListeners(key); } this.removeAllListeners('removeListener'); this._events = {}; return this; } listeners = this._events[type]; if (isFunction(listeners)) { this.removeListener(type, listeners); } else { // LIFO order while (listeners.length) this.removeListener(type, listeners[listeners.length - 1]); } delete this._events[type]; return this; }; EventEmitter.prototype.listeners = function(type) { var ret; if (!this._events || !this._events[type]) ret = []; else if (isFunction(this._events[type])) ret = [this._events[type]]; else ret = this._events[type].slice(); return ret; }; EventEmitter.listenerCount = function(emitter, type) { var ret; if (!emitter._events || !emitter._events[type]) ret = 0; else if (isFunction(emitter._events[type])) ret = 1; else ret = emitter._events[type].length; return ret; }; function isFunction(arg) { return typeof arg === 'function'; } function isNumber(arg) { return typeof arg === 'number'; } function isObject(arg) { return typeof arg === 'object' && arg !== null; } function isUndefined(arg) { return arg === void 0; } },{}],147:[function(require,module,exports){ // shim for using process in browser var process = module.exports = {}; process.nextTick = (function () { var canSetImmediate = typeof window !== 'undefined' && window.setImmediate; var canPost = typeof window !== 'undefined' && window.postMessage && window.addEventListener ; if (canSetImmediate) { return function (f) { return window.setImmediate(f) }; } if (canPost) { var queue = []; window.addEventListener('message', function (ev) { var source = ev.source; if ((source === window || source === null) && ev.data === 'process-tick') { ev.stopPropagation(); if (queue.length > 0) { var fn = queue.shift(); fn(); } } }, true); return function nextTick(fn) { queue.push(fn); window.postMessage('process-tick', '*'); }; } return function nextTick(fn) { setTimeout(fn, 0); }; })(); process.title = 'browser'; process.browser = true; process.env = {}; process.argv = []; function noop() {} process.on = noop; process.addListener = noop; process.once = noop; process.off = noop; process.removeListener = noop; process.removeAllListeners = noop; process.emit = noop; process.binding = function (name) { throw new Error('process.binding is not supported'); } // TODO(shtylman) process.cwd = function () { return '/' }; process.chdir = function (dir) { throw new Error('process.chdir is not supported'); }; },{}],148:[function(require,module,exports){ (function (global){ /*! * Copyright 2014 Netflix, Inc * * 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. */ !function(e){if("object"==typeof exports)module.exports=e();else if("function"==typeof define&&define.amd)define(e);else{var f;"undefined"!=typeof window?f=window:"undefined"!=typeof global?f=global:"undefined"!=typeof self&&(f=self),f.falcor=e()}}(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);throw new Error("Cannot find module '"+o+"'")}var f=n[o]={exports:{}};t[o][0].call(f.exports,function(e){var n=t[o][1][e];return s(n?n:e)},f,f.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(_dereq_,module,exports){ module.exports = _dereq_('./operations'); },{"./operations":149}],2:[function(_dereq_,module,exports){ if (typeof falcor === 'undefined') { var falcor = {}; } var Rx = _dereq_('./rx.ultralite'); falcor.__Internals = {}; falcor.Observable = Rx.Observable; falcor.EXPIRES_NOW = 0; falcor.EXPIRES_NEVER = 1; /** * The current semVer'd data version of falcor. */ falcor.dataVersion = '0.1.0'; falcor.now = function now() { return Date.now(); }; falcor.NOOP = function() {}; module.exports = falcor; },{"./rx.ultralite":41}],3:[function(_dereq_,module,exports){ var falcor = _dereq_('./Falcor'); var RequestQueue = _dereq_('./request/RequestQueue'); var ImmediateScheduler = _dereq_('./scheduler/ImmediateScheduler'); var TimeoutScheduler = _dereq_('./scheduler/TimeoutScheduler'); var ERROR = _dereq_("../types/error"); var ModelResponse = _dereq_('./ModelResponse'); var call = _dereq_('./operations/call'); var operations = _dereq_('./operations'); var dotSyntaxParser = _dereq_('./operations/parser/parser'); var getBoundValue = _dereq_('./../get/getBoundValue'); var slice = Array.prototype.slice; var $ref = _dereq_('./../types/path'); var $error = _dereq_('./../types/error'); var $sentinel = _dereq_('./../types/sentinel'); var Model = module.exports = falcor.Model = function Model(options) { if (!options) { options = {}; } this._materialized = options.materialized || false; this._boxed = options.boxed || false; this._treatErrorsAsValues = options.treatErrorsAsValues || false; this._dataSource = options.source; this._maxSize = options.maxSize || Math.pow(2, 53) - 1; this._collectRatio = options.collectRatio || 0.75; this._scheduler = new ImmediateScheduler(); this._request = new RequestQueue(this, this._scheduler); this._errorSelector = options.errorSelector || Model.prototype._errorSelector; this._router = options.router; this._root = options.root || { expired: [], allowSync: false, unsafeMode: true }; if (options.cache && typeof options.cache === "object") { this.setCache(options.cache); } else { this._cache = {}; } this._path = []; }; Model.EXPIRES_NOW = falcor.EXPIRES_NOW; Model.EXPIRES_NEVER = falcor.EXPIRES_NEVER; Model.ref = function(path) { if (typeof path === 'string') { path = dotSyntaxParser(path); } return {$type: $ref, value: path}; }; Model.error = function(error) { return {$type: $error, value: error}; }; Model.atom = function(value) { return {$type: $sentinel, value: value}; }; Model.prototype = { _boxed: false, _progressive: false, _errorSelector: function(x, y) { return y; }, get: operations('get'), set: operations("set"), invalidate: operations("invalidate"), call: call, getValue: function(path) { return this.get(path, function(x) { return x }); }, setValue: function(path, value) { return this.set(Array.isArray(path) ? {path: path, value: value} : path, function(x) { return x; }); }, bind: function(boundPath) { var model = this, root = model._root, paths = new Array(arguments.length - 1), i = -1, n = arguments.length - 1; while(++i < n) { paths[i] = arguments[i + 1]; } if(n === 0) { throw new Error("Model#bind requires at least one value path."); } return falcor.Observable.create(function(observer) { var boundModel; try { root.allowSync = true; if(!(boundModel = model.bindSync(model._path.concat(boundPath)))) { throw false; } root.allowSync = false; observer.onNext(boundModel); observer.onCompleted(); } catch (e) { root.allowSync = false; return model.get.apply(model, paths.map(function(path) { return boundPath.concat(path); }).concat(function(){})).subscribe( function onNext() {}, function onError(err) { observer.onError(err); }, function onCompleted() { try { if(boundModel = model.bindSync(boundPath)) { observer.onNext(boundModel); } observer.onCompleted(); } catch(e) { observer.onError(e); } }); } }); }, setCache: function(cache) { return (this._cache = {}) && this._setCache(this, cache); }, getValueSync: function(path) { if (Array.isArray(path) === false) { throw new Error("Model#getValueSync must be called with an Array path."); } if (this._path.length) { path = this._path.concat(path); } return this.syncCheck("getValueSync") && this._getValueSync(this, path).value; }, setValueSync: function(path, value, errorSelector) { if(Array.isArray(path) === false) { if(typeof errorSelector !== "function") { errorSelector = value || this._errorSelector; } value = path.value; path = path.path; } if(Array.isArray(path) === false) { throw new Error("Model#setValueSync must be called with an Array path."); } if(this.syncCheck("setValueSync")) { var json = {}; var tEeAV = this._treatErrorsAsValues; var boxed = this._boxed; this._treatErrorsAsValues = true; this._boxed = true; this._setPathSetsAsJSON(this, [{path: path, value: value}], [json], errorSelector); this._treatErrorsAsValues = tEeAV; this._boxed = boxed; json = json.json; if(json && json.$type === ERROR && !this._treatErrorsAsValues) { if(this._boxed) { throw json; } else { throw json.value; } } else if(this._boxed) { return json; } return json && json.value; } }, bindSync: function(path) { if(Array.isArray(path) === false) { throw new Error("Model#bindSync must be called with an Array path."); } var boundValue = this.syncCheck("bindSync") && getBoundValue(this, this._path.concat(path)); var node = boundValue.value; path = boundValue.path; if(boundValue.shorted) { if(!!node) { if(node.$type === ERROR) { if(this._boxed) { throw node; } throw node.value; // throw new Error("Model#bindSync can\'t bind to or beyond an error: " + boundValue.toString()); } } return undefined; } else if(!!node && node.$type === ERROR) { if(this._boxed) { throw node; } throw node.value; } return this.clone(["_path", boundValue.path]); }, // TODO: This seems like a great place for optimizations clone: function() { var self = this; var clone = new Model(); Object.keys(self).forEach(function(key) { clone[key] = self[key]; }); slice.call(arguments).forEach(function(tuple) { clone[tuple[0]] = tuple[1]; }); return clone; }, batch: function(schedulerOrDelay) { if(typeof schedulerOrDelay === "number") { schedulerOrDelay = new TimeoutScheduler(Math.round(Math.abs(schedulerOrDelay))); } else if(!schedulerOrDelay || !schedulerOrDelay.schedule) { schedulerOrDelay = new ImmediateScheduler(); } return this.clone(["_request", new RequestQueue(this, schedulerOrDelay)]); }, unbatch: function() { return this.clone(["_request", new RequestQueue(this, new ImmediateScheduler())]); }, treatErrorsAsValues: function() { return this.clone(["_treatErrorsAsValues", true]); }, materialize: function() { return this.clone(["_materialized", true]); }, boxValues: function() { return this.clone(["_boxed", true]); }, unboxValues: function() { return this.clone(["_boxed", false]); }, withoutDataSource: function() { return this.clone(["_dataSource", null]); }, syncCheck: function(name) { if (!!this._dataSource && this._root.allowSync === false && this._root.unsafeMode === false) { throw new Error("Model#" + name + " may only be called within the context of a request selector."); } return true; } }; },{"../types/error":139,"./../get/getBoundValue":49,"./../types/error":139,"./../types/path":140,"./../types/sentinel":141,"./Falcor":2,"./ModelResponse":4,"./operations":11,"./operations/call":6,"./operations/parser/parser":16,"./request/RequestQueue":40,"./scheduler/ImmediateScheduler":42,"./scheduler/TimeoutScheduler":43}],4:[function(_dereq_,module,exports){ var falcor = _dereq_('./Falcor'); var Observable = falcor.Observable, valuesMixin = { format: { value: "AsValues" } }, jsonMixin = { format: { value: "AsPathMap" } }, jsongMixin = { format: { value: "AsJSONG" } }, progressiveMixin = { operationIsProgressive: { value: true } }; function ModelResponse(forEach) { this._subscribe = forEach; } ModelResponse.create = function(forEach) { return new ModelResponse(forEach); }; ModelResponse.fromOperation = function(model, args, selector, forEach) { return new ModelResponse(function(observer) { return forEach(Object.create(observer, { operationModel: {value: model}, operationArgs: {value: args}, operationSelector: {value: selector} })); }); }; function noop() {} function mixin(self) { var mixins = Array.prototype.slice.call(arguments, 1); return new ModelResponse(function(other) { return self.subscribe(mixins.reduce(function(proto, mixin) { return Object.create(proto, mixin); }, other)); }); } ModelResponse.prototype = Observable.create(noop); ModelResponse.prototype.format = "AsPathMap"; ModelResponse.prototype.toPathValues = function() { return mixin(this, valuesMixin); }; ModelResponse.prototype.toJSON = function() { return mixin(this, jsonMixin); }; ModelResponse.prototype.progressively = function() { return mixin(this, progressiveMixin); }; ModelResponse.prototype.toJSONG = function() { return mixin(this, jsongMixin); }; module.exports = ModelResponse; },{"./Falcor":2}],5:[function(_dereq_,module,exports){ var falcor = _dereq_('./Falcor'); var Model = _dereq_('./Model'); falcor.Model = Model; module.exports = falcor; },{"./Falcor":2,"./Model":3}],6:[function(_dereq_,module,exports){ module.exports = call; var falcor = _dereq_("../../Falcor"); var ModelResponse = _dereq_('./../../ModelResponse'); function call(path, args, suffixes, paths, selector) { var model = this; args && Array.isArray(args) || (args = []); suffixes && Array.isArray(suffixes) || (suffixes = []); paths = Array.prototype.slice.call(arguments, 3); if (typeof (selector = paths[paths.length - 1]) !== "function") { selector = undefined; } else { paths = paths.slice(0, -1); } return ModelResponse.create(function (options) { var rootModel = model.clone(["_path", []]), localRoot = rootModel.withoutDataSource(), dataSource = model._dataSource, boundPath = model._path, callPath = boundPath.concat(path), thisPath = callPath.slice(0, -1); var disposable = model. getValue(path). flatMap(function (localFn) { if (typeof localFn === "function") { return falcor.Observable.return(localFn. apply(rootModel.bindSync(thisPath), args). map(function (pathValue) { return { path: thisPath.concat(pathValue.path), value: pathValue.value }; }). toArray(). flatMap(function (pathValues) { return localRoot.set. apply(localRoot, pathValues). toJSONG(); }). flatMap(function (envelope) { return rootModel.get.apply(rootModel, envelope.paths.reduce(function (paths, path) { return paths.concat(suffixes.map(function (suffix) { return path.concat(suffix); })); }, []). concat(paths.reduce(function (paths, path) { return paths.concat(thisPath.concat(path)); }, []))). toJSONG(); })); } return falcor.Observable.empty(); }). defaultIfEmpty(dataSource.call(path, args, suffixes, paths)). mergeAll(). subscribe(function (envelope) { var invalidated = envelope.invalidated; if (invalidated && invalidated.length) { invalidatePaths(rootModel, invalidated, undefined, model._errorSelector); } disposable = localRoot. set(envelope, function () { return model; }). subscribe(function (model) { var getPaths = envelope.paths.map(function (path) { return path.slice(boundPath.length); }); if (selector) { getPaths[getPaths.length] = function () { return selector.call(model, getPaths); }; } disposable = model.get.apply(model, getPaths).subscribe(options); }); }); return { dispose: function () { disposable && disposable.dispose(); disposable = undefined; } }; }); } },{"../../Falcor":2,"./../../ModelResponse":4}],7:[function(_dereq_,module,exports){ var combineOperations = _dereq_('./../support/combineOperations'); var setSeedsOrOnNext = _dereq_('./../support/setSeedsOrOnNext'); /** * The initial args that are passed into the async request pipeline. * @see lib/falcor/operations/request.js for how initialArgs are used */ module.exports = function getInitialArgs(options, seeds, onNext) { var seedRequired = options.format !== 'AsValues'; var isProgressive = options.operationIsProgressive; var spreadOperations = false; var operations = combineOperations( options.operationArgs, options.format, 'get', spreadOperations, isProgressive); setSeedsOrOnNext( operations, seedRequired, seeds, onNext, options.operationSelector); var requestOptions; return [operations]; }; },{"./../support/combineOperations":26,"./../support/setSeedsOrOnNext":39}],8:[function(_dereq_,module,exports){ var getSourceObserver = _dereq_('./../support/getSourceObserever'); var partitionOperations = _dereq_('./../support/partitionOperations'); var mergeBoundPath = _dereq_('./../support/mergeBoundPath'); module.exports = getSourceRequest; function getSourceRequest( options, onNext, seeds, combinedResults, requestOptions, cb) { var model = options.operationModel; var boundPath = model._path; var missingPaths = combinedResults.requestedMissingPaths; if (boundPath.length) { for (var i = 0; i < missingPaths.length; ++i) { var pathSetIndex = missingPaths[i].pathSetIndex; var path = missingPaths[i] = boundPath.concat(missingPaths[i]); path.pathSetIndex = pathSetIndex; } } return model._request.get( missingPaths, combinedResults.optimizedMissingPaths, getSourceObserver( model, missingPaths, function getSourceCallback(err, results) { if (err) { cb(err); return; } // partitions the operations by their pathSetIndex var partitionOperationsAndSeeds = partitionOperations( results, seeds, options.format, onNext); // We allow for the rerequesting to happen. cb(null, partitionOperationsAndSeeds); })); } },{"./../support/getSourceObserever":27,"./../support/mergeBoundPath":31,"./../support/partitionOperations":34}],9:[function(_dereq_,module,exports){ var getInitialArgs = _dereq_('./getInitialArgs'); var getSourceRequest = _dereq_('./getSourceRequest'); var shouldRequest = _dereq_('./shouldRequest'); var request = _dereq_('./../request'); var processOperations = _dereq_('./../support/processOperations'); var get = request( getInitialArgs, getSourceRequest, processOperations, shouldRequest); module.exports = get; },{"./../request":18,"./../support/processOperations":36,"./getInitialArgs":7,"./getSourceRequest":8,"./shouldRequest":10}],10:[function(_dereq_,module,exports){ module.exports = function(model, combinedResults) { return model._dataSource && combinedResults.requestedMissingPaths.length > 0; }; },{}],11:[function(_dereq_,module,exports){ var ModelResponse = _dereq_('../ModelResponse'); var get = _dereq_('./get'); var set = _dereq_('./set'); var invalidate = _dereq_('./invalidate'); module.exports = function modelOperation(name) { return function() { var model = this, root = model._root, args = Array.prototype.slice.call(arguments), selector = args[args.length - 1]; if (typeof selector === 'function') { args.pop(); } else { selector = false; } var modelResponder; switch (name) { case 'get': modelResponder = get; break; case 'set': modelResponder = set; break; case 'invalidate': modelResponder = invalidate; break; } return ModelResponse.fromOperation( model, args, selector, modelResponder); }; }; },{"../ModelResponse":4,"./get":9,"./invalidate":12,"./set":19}],12:[function(_dereq_,module,exports){ var invalidateInitialArgs = _dereq_('./invalidateInitialArgs'); var request = _dereq_('./../request'); var processOperations = _dereq_('./../support/processOperations'); var invalidate = request( invalidateInitialArgs, null, processOperations); module.exports = invalidate; },{"./../request":18,"./../support/processOperations":36,"./invalidateInitialArgs":13}],13:[function(_dereq_,module,exports){ var combineOperations = _dereq_('./../support/combineOperations'); var setSeedsOrOnNext = _dereq_('./../support/setSeedsOrOnNext'); module.exports = function getInitialArgs(options, seeds, onNext) { var seedRequired = options.format !== 'AsValues'; var operations = combineOperations( options.operationArgs, options.format, 'inv'); setSeedsOrOnNext( operations, seedRequired, seeds, onNext, options.operationSelector); return [operations, seeds]; }; },{"./../support/combineOperations":26,"./../support/setSeedsOrOnNext":39}],14:[function(_dereq_,module,exports){ module.exports = { token: 'token', dotSeparator: '.', commaSeparator: ',', openingBracket: '[', closingBracket: ']', space: 'space', quote: 'quote', unknown: 'unknown' }; },{}],15:[function(_dereq_,module,exports){ module.exports = { nestedIndexers: 'Indexers cannot be nested', closingWithoutOpeningIndexer: 'A closing indexer, "]", was provided without an opening indexer.', leadingDotInIndexer: 'The dot operator in an indexer cannot be used this way.', twoDot: 'Cannot have two dot separators outside of an indexer range.', dotComma: 'Cannot have a comma preceded by a dot separator.', commasOutsideOfIndexers: 'Commas cannot be used outside of indexers.', trailingComma: 'Cannot have trailing commas in indexers.', leadingComma: 'Leading commas in ranges are not allowed.', emptyQuotes: 'Cannot have empty quotes', emptyIndexer: 'Cannot have empty indexer.', quotesOutsideIndexer: 'Cannot have quotes outside indexer.', nonTerminatingQuotes: 'The quotes within the indexer were not closed.', tokensMustBeNumeric: 'Tokens without quotes must be numeric.', indexerTokensMustBeCommaDelimited: 'Indexer tokens must be comma delimited.', numericRange: 'Only numeric keys can be used in ranges.' }; },{}],16:[function(_dereq_,module,exports){ var tokenizer = _dereq_('./tokenizer'); var TokenTypes = _dereq_('./TokenTypes'); var Expections = _dereq_('./expections'); /** * not only is this the parser, it is also the * semantic analyzer for brevity sake / we never need * this to change overall types of output. */ module.exports = function parser(string) { var out = []; var tokenized = tokenizer(string); var state = {}; var token = tokenized(); while (!token.done) { switch (token.type) { case TokenTypes.token: insertToken(token.token, state, out); break; case TokenTypes.dotSeparator: dotSeparator(token.token, state, out); break; case TokenTypes.space: space(token.token, state, out); break; case TokenTypes.commaSeparator: commaSeparator(token.token, state, out); break; case TokenTypes.openingBracket: openIndexer(token.token, state, out); break; case TokenTypes.closingBracket: closeIndexer(token.token, state, out); break; case TokenTypes.quote: quote(token.token, state, out); break; } token = tokenized(); } return out; }; function space(token, state, out) { // The space character only matters when inIndexer // and in quote mode. if (state.inIndexer && state.quote) { state.indexerToken += token; } } function insertToken(token, state, out) { state.hasDot = false; // if within indexer then there are several edge cases. if (state.inIndexer) { tokenInIndexer(token, state, out); return; } // if not in indexer just insert into end position. out[out.length] = token; } function dotSeparator(token, state, out) { // If in indexer then dotOperators have different meanings. if (state.inIndexer) { indexerDotOperator(token, state, out); } // throws an expection if a range operator is outside of a range. else if (state.hasDot) { throw Expections.twoDot; } state.hasDot = true; } function commaSeparator(token, state, out) { if (state.hasDot) { throw Expections.dotComma; } // If in indexer then dotOperators have different meanings. if (state.inIndexer) { indexerCommaOperator(token, state, out); } } // Accumulates dotSeparators inside indexers function indexerDotOperator(token, state, out) { // must be preceded by token. if (state.indexerToken === undefined) { throw Expections.leadingDotInIndexer; } // if in quote mode, add the dot indexer to quote. if (state.quote) { state.indexerToken += token; return; } if (!state.rangeCount) { state.range = true; state.rangeCount = 0; } ++state.rangeCount; if (state.rangeCount === 2) { state.inclusiveRange = true; } else if (state.rangeCount === 3) { state.exclusiveRange = true; state.inclusiveRange = false; } } function indexerCommaOperator(token, state, out) { // are we a range indexer? if (state.range) { closeRangedIndexer(token, state, out); } // push previous token and clear state. else if (state.inIndexer) { pushTokenIntoIndexer(token, state, out); } // If a comma is used outside of an indexer throw else { throw Expections.commasOutsideOfIndexers; } } function pushTokenIntoIndexer(token, state, out) { // no token to push, throw error. if (state.indexerToken === undefined) { throw Expections.leadingComma; } // push the current token onto the stack then clear state. state.indexer[state.indexer.length] = state.indexerToken; cleanIndexerTokenState(state); } function openIndexer(token, state, out) { if (state.inIndexer) { throw Expections.nestedIndexers; } state.inIndexer = true; state.indexer = []; } function closeIndexer(token, state, out) { // must be within an indexer to close. if (!state.inIndexer) { throw Expections.closingWithoutOpeningIndexer; } // The quotes could be non terminating if (state.quote) { throw Expections.nonTerminatingQuotes; } // are we a range indexer? if (state.range) { closeRangedIndexer(token, state, out); } // are we have a token? else if (state.indexerToken !== undefined) { pushTokenIntoIndexer(token, state, out); } // empty indexer. Must be after the potential addition // statements. if (state.indexer && state.indexer.length === 0) { throw Expections.emptyIndexer; } // flatten to avoid odd JSON output. if (state.indexer && state.indexer.length === 1) { state.indexer = state.indexer[0]; } out[out.length] = state.indexer; // removes all indexer state cleanIndexerRangeState(state); cleanIndexerTokenState(state); state.indexer = state.inIndexer = undefined; } function closeRangedIndexer(token, state, out) { state.indexer[state.indexer.length] = { from: state.indexerToken, to: state.rangeCloseToken - (state.exclusiveRange && 1 || 0) }; cleanIndexerRangeState(state); } function cleanIndexerRangeState(state) { state.inclusiveRange = state.exclusiveRange = state.range = state.rangeCloseToken = state.rangeCount = undefined; } // removes state associated with indexerTokenState. function cleanIndexerTokenState(state) { state.indexerToken = state.indexerTokenQuoted = undefined; } function tokenInRange(token, state, out) { token = +token; if (isNaN(token)) { throw Expections.numericRange; } state.rangeCloseToken = token; } function tokenInIndexer(token, state, out) { // finish the range token. if (state.range) { tokenInRange(token, state, out); } // quote mode, accumulate tokens. else if (state.quote) { if (state.indexerToken === undefined) { state.indexerToken = ''; } state.indexerToken += token; } // We are in range mode. else { token = +token; if (isNaN(token)) { throw Expections.tokensMustBeNumeric; } state.indexerToken = token; } } // this function just ensures that quotes only happen in indexers, // outside of ranges, and with 1 or more length tokens. function quote(token, state, out) { if (state.indexerTokenQuoted) { throw Expections.indexerTokensMustBeCommaDelimited; } if (!state.inIndexer) { throw Expections.quotesOutsideIndexer; } var was = state.quote; var toBe = !was; state.quote = toBe; // so deep if (was && !toBe) { if (state.indexerToken === undefined) { throw Expections.emptyQuotes; } state.indexerTokenQuoted = true; } } },{"./TokenTypes":14,"./expections":15,"./tokenizer":17}],17:[function(_dereq_,module,exports){ var TokenTypes = _dereq_('./TokenTypes'); var DOT_SEPARATOR = '.'; var COMMA_SEPARATOR = ','; var OPENING_BRACKET = '['; var CLOSING_BRACKET = ']'; var DOUBLE_OUOTES = '"'; var SINGE_OUOTES = "'"; var SPACE = " "; var SPECIAL_CHARACTERS = '\'"[]., '; var TokenTypes = _dereq_('./TokenTypes'); module.exports = function tokenizer(string) { var idx = -1; return function() { var token = ''; var done; do { done = idx === string.length; if (done) { return {done: true}; } // we have to peek at the next token var character = string[idx + 1]; // if its not a special character we need to accumulate it. var isQuote = character === SINGE_OUOTES || character === DOUBLE_OUOTES; if (character !== undefined && SPECIAL_CHARACTERS.indexOf(character) === -1) { token += character; ++idx; continue; } if (token.length) { return toOutput(token, TokenTypes.token, done); } ++idx; var type; switch (character) { case DOT_SEPARATOR: type = TokenTypes.dotSeparator; break; case COMMA_SEPARATOR: type = TokenTypes.commaSeparator; break; case OPENING_BRACKET: type = TokenTypes.openingBracket; break; case CLOSING_BRACKET: type = TokenTypes.closingBracket; break; case SPACE: type = TokenTypes.space; break; case DOUBLE_OUOTES: case SINGE_OUOTES: type = TokenTypes.quote; break; } if (type) { return toOutput(token, type, done); } } while (!done); if (token.length) { return toOutput(token, TokenTypes.token, false); } return {done: true}; }; }; function toOutput(token, type, done) { return { token: token, done: done, type: type }; } },{"./TokenTypes":14}],18:[function(_dereq_,module,exports){ var setSeedsOrOnNext = _dereq_('./support/setSeedsOrOnNext'); var onNextValues = _dereq_('./support/onNextValue'); var onCompletedOrError = _dereq_('./support/onCompletedOrError'); var dotSyntaxParser = _dereq_('./parser/parser'); var primeSeeds = _dereq_('./support/primeSeeds'); var autoFalse = function() { return false; }; module.exports = request; function request(initialArgs, sourceRequest, processOperations, shouldRequestFn) { if (!shouldRequestFn) { shouldRequestFn = autoFalse; } return function innerRequest(options) { var selector = options.operationSelector; var model = options.operationModel; var args = options.operationArgs; var onNext = options.onNext.bind(options); var onError = options.onError.bind(options); var onCompleted = options.onCompleted.bind(options); var isProgressive = options.operationIsProgressive; var errorSelector = model._errorSelector; var selectorLength = selector && selector.length || 0; // State variables var errors = []; var format = options.format = selector && 'AsJSON' || options.format || 'AsPathMap'; var toJSONG = format === 'AsJSONG'; var toJSON = format === 'AsPathMap'; var toPathValues = format === 'AsValues'; var seedRequired = toJSON || toJSONG || selector; var boundPath = model._path; var i, len; var foundValue = false; var seeds = primeSeeds(selector, selectorLength); var loopCount = 0; // parse any dotSyntax for (i = 0, len = args.length; i < len; i++) { // it is a dotSyntax string. if (typeof args[i] === 'string') { args[i] = dotSyntaxParser(args[i]); } // it is a pathValue with dotSyntax. else if (typeof args[i].path === 'string') { args[i].path = dotSyntaxParser(args[i].path); } } function recurse(operations, opts) { if (loopCount > 50) { throw 'Loop Kill switch thrown.'; } var combinedResults = processOperations( model, operations, errorSelector, opts); foundValue = foundValue || combinedResults.valuesReceived; if (combinedResults.errors.length) { errors = errors.concat(combinedResults.errors); } // if in progressiveMode, values are emitted // each time through the recurse loop. This may have // to change when the router is considered. if (isProgressive && !toPathValues) { onNextValues(model, onNext, seeds, selector); } // Performs the recursing via dataSource if (shouldRequestFn(model, combinedResults, loopCount)) { sourceRequest( options, onNext, seeds, combinedResults, opts, function onCompleteFromSourceSet(err, results) { if (err) { errors = errors.concat(err); recurse([], seeds); return; } ++loopCount; // We continue to string the opts through recurse(results, opts); }); } // Else we need to onNext values and complete/error. else { if (!toPathValues && !isProgressive && foundValue) { onNextValues(model, onNext, seeds, selector); } onCompletedOrError(onCompleted, onError, errors); } } try { recurse.apply(null, initialArgs(options, seeds, onNext)); } catch(e) { errors = [e]; onCompletedOrError(onCompleted, onError, errors); } }; } },{"./parser/parser":16,"./support/onCompletedOrError":32,"./support/onNextValue":33,"./support/primeSeeds":35,"./support/setSeedsOrOnNext":39}],19:[function(_dereq_,module,exports){ var setInitialArgs = _dereq_('./setInitialArgs'); var setSourceRequest = _dereq_('./setSourceRequest'); var request = _dereq_('./../request'); var setProcessOperations = _dereq_('./setProcessOperations'); var shouldRequest = _dereq_('./shouldRequest'); var set = request( setInitialArgs, setSourceRequest, setProcessOperations, shouldRequest); module.exports = set; },{"./../request":18,"./setInitialArgs":20,"./setProcessOperations":21,"./setSourceRequest":22,"./shouldRequest":23}],20:[function(_dereq_,module,exports){ var combineOperations = _dereq_('./../support/combineOperations'); var setSeedsOrOnNext = _dereq_('./../support/setSeedsOrOnNext'); var Formats = _dereq_('./../support/Formats'); var toPathValues = Formats.toPathValues; var toJSONG = Formats.toJSONG; module.exports = function setInitialArgs(options, seeds, onNext) { var isPathValues = options.format === toPathValues; var seedRequired = !isPathValues; var shouldRequest = !!options.operationModel._dataSource; var format = options.format; var args = options.operationArgs; var selector = options.operationSelector; var isProgressive = options.operationIsProgressive; var firstSeeds, operations; var requestOptions = { removeBoundPath: shouldRequest }; // If Model is a slave, in shouldRequest mode, // a single seed is required to accumulate the jsong results. if (shouldRequest) { operations = combineOperations(args, toJSONG, 'set', selector, false); firstSeeds = [{}]; setSeedsOrOnNext( operations, true, firstSeeds, false, options.selector); // we must keep track of the set seeds. requestOptions.requestSeed = firstSeeds[0]; } // This model is the master, therefore a regular set can be performed. else { firstSeeds = seeds; operations = combineOperations(args, format, 'set'); setSeedsOrOnNext( operations, seedRequired, seeds, onNext, options.operationSelector); } // We either have to construct the master operations if // the ModelResponse is isProgressive // the ModelResponse is toPathValues // but luckily we can just perform a get for the progressive or // toPathValues mode. if (isProgressive || isPathValues) { var getOps = combineOperations( args, format, 'get', selector, true); setSeedsOrOnNext( getOps, seedRequired, seeds, onNext, options.operationSelector); operations = operations.concat(getOps); requestOptions.isProgressive = true; } return [operations, requestOptions]; }; },{"./../support/Formats":24,"./../support/combineOperations":26,"./../support/setSeedsOrOnNext":39}],21:[function(_dereq_,module,exports){ var processOperations = _dereq_('./../support/processOperations'); var combineOperations = _dereq_('./../support/combineOperations'); var mergeBoundPath = _dereq_('./../support/mergeBoundPath'); var Formats = _dereq_('./../support/Formats'); var toPathValues = Formats.toPathValues; module.exports = setProcessOperations; function setProcessOperations(model, operations, errorSelector, requestOptions) { var boundPath = model._path; var hasBoundPath = boundPath.length > 0; var removeBoundPath = requestOptions && requestOptions.removeBoundPath; var isProgressive = requestOptions && requestOptions.isProgressive; var progressiveOperations; // if in progressive mode, then the progressive operations // need to be executed but the bound path must stay intact. if (isProgressive && removeBoundPath && hasBoundPath) { progressiveOperations = operations.filter(function(op) { return op.isProgressive; }); operations = operations.filter(function(op) { return !op.isProgressive; }); } if (removeBoundPath && hasBoundPath) { model._path = []; // For every operations arguments, the bound path must be adjusted. for (var i = 0, opLen = operations.length; i < opLen; i++) { var args = operations[i].args; for (var j = 0, argsLen = args.length; j < argsLen; j++) { args[j] = mergeBoundPath(args[j], boundPath); } } } var results = processOperations(model, operations, errorSelector); // Undo what we have done to the model's bound path. if (removeBoundPath && hasBoundPath) { model._path = boundPath; } // executes the progressive ops if (progressiveOperations) { processOperations(model, progressiveOperations, errorSelector); } return results; } },{"./../support/Formats":24,"./../support/combineOperations":26,"./../support/mergeBoundPath":31,"./../support/processOperations":36}],22:[function(_dereq_,module,exports){ var getSourceObserver = _dereq_('./../support/getSourceObserever'); var combineOperations = _dereq_('./../support/combineOperations'); var setSeedsOrOnNext = _dereq_('./../support/setSeedsOrOnNext'); var toPathValues = _dereq_('./../support/Formats').toPathValues; module.exports = setSourceRequest; function setSourceRequest( options, onNext, seeds, combinedResults, requestOptions, cb) { var model = options.operationModel; var seedRequired = options.format !== toPathValues; var requestSeed = requestOptions.requestSeed; return model._request.set( requestSeed, getSourceObserver( model, requestSeed.paths, function setSourceRequestCB(err, results) { if (err) { cb(err); } // Sets the results into the model. model._setJSONGsAsJSON(model, [results], []); // Gets the original paths / maps back out. var operations = combineOperations( options.operationArgs, options.format, 'get'); setSeedsOrOnNext( operations, seedRequired, seeds, onNext, options.operationSelector); // unset the removeBoundPath. requestOptions.removeBoundPath = false; cb(null, operations); })); } },{"./../support/Formats":24,"./../support/combineOperations":26,"./../support/getSourceObserever":27,"./../support/setSeedsOrOnNext":39}],23:[function(_dereq_,module,exports){ // Set differs from get in the sense that the first time through // the recurse loop a server operation must be performed if it can be. module.exports = function(model, combinedResults, loopCount) { return model._dataSource && ( combinedResults.requestedMissingPaths.length > 0 || loopCount === 0); }; },{}],24:[function(_dereq_,module,exports){ module.exports = { toPathValues: 'AsValues', toJSON: 'AsPathMap', toJSONG: 'AsJSONG', selector: 'AsJSON', }; },{}],25:[function(_dereq_,module,exports){ module.exports = function buildJSONGOperation(format, seeds, jsongOp, seedOffset, onNext) { return { methodName: '_setJSONGs' + format, format: format, isValues: format === 'AsValues', onNext: onNext, seeds: seeds, seedsOffset: seedOffset, args: [jsongOp] }; }; },{}],26:[function(_dereq_,module,exports){ var isSeedRequired = _dereq_('./seedRequired'); var isJSONG = _dereq_('./isJSONG'); var isPathOrPathValue = _dereq_('./isPathOrPathValue'); var Formats = _dereq_('./Formats'); var toSelector = Formats.selector; module.exports = function combineOperations(args, format, name, spread, isProgressive) { var seedRequired = isSeedRequired(format); var isValues = !seedRequired; var hasSelector = seedRequired && format === toSelector; var seedsOffset = 0; return args. reduce(function(groups, argument) { var group = groups[groups.length - 1]; var type = isPathOrPathValue(argument) ? "PathSets" : isJSONG(argument) ? "JSONGs" : "PathMaps"; var groupType = group && group.type; var methodName = '_' + name + type + format; if (!groupType || type !== groupType || spread) { group = { methodName: methodName, format: format, operation: name, isValues: isValues, seeds: [], onNext: null, seedsOffset: seedsOffset, isProgressive: isProgressive, type: type, args: [] }; groups.push(group); } if (hasSelector) { ++seedsOffset; } group.args.push(argument); return groups; }, []); }; },{"./Formats":24,"./isJSONG":29,"./isPathOrPathValue":30,"./seedRequired":37}],27:[function(_dereq_,module,exports){ var insertErrors = _dereq_('./insertErrors.js'); /** * creates the model source observer * @param {Model} model * @param {Array.<Array>} requestedMissingPaths * @param {Function} cb */ function getSourceObserver(model, requestedMissingPaths, cb) { var incomingValues; return { onNext: function(jsongEnvelop) { incomingValues = { jsong: jsongEnvelop.jsong, paths: requestedMissingPaths }; }, onError: function(err) { cb(insertErrors(model, requestedMissingPaths, err)); }, onCompleted: function() { cb(false, incomingValues); } }; } module.exports = getSourceObserver; },{"./insertErrors.js":28}],28:[function(_dereq_,module,exports){ /** * will insert the error provided for every requestedPath. * @param {Model} model * @param {Array.<Array>} requestedPaths * @param {Object} err */ module.exports = function insertErrors(model, requestedPaths, err) { var out = model._setPathSetsAsJSON.apply(null, [model].concat( requestedPaths. reduce(function(acc, r) { acc[0].push({ path: r, value: err }); return acc; }, [[]]), [], model._errorSelector )); return out.errors; }; },{}],29:[function(_dereq_,module,exports){ module.exports = function isJSONG(x) { return x.hasOwnProperty("jsong"); }; },{}],30:[function(_dereq_,module,exports){ module.exports = function isPathOrPathValue(x) { return !!(Array.isArray(x)) || ( x.hasOwnProperty("path") && x.hasOwnProperty("value")); }; },{}],31:[function(_dereq_,module,exports){ var isJSONG = _dereq_('./isJSONG'); var isPathValue = _dereq_('./isPathOrPathValue'); module.exports = mergeBoundPath; function mergeBoundPath(arg, boundPath) { return isJSONG(arg) && mergeBoundPathIntoJSONG(arg, boundPath) || isPathValue(arg) && mergeBoundPathIntoPathValue(arg, boundPath) || mergeBoundPathIntoJSON(arg, boundPath); } function mergeBoundPathIntoJSONG(jsongEnv, boundPath) { var newJSONGEnv = {jsong: jsongEnv.jsong, paths: jsongEnv.paths}; if (boundPath.length) { var paths = []; for (i = 0, len = jsongEnv.paths.length; i < len; i++) { paths[i] = boundPath.concat(jsongEnv.paths[i]); } newJSONGEnv.paths = paths; } return newJSONGEnv; } function mergeBoundPathIntoJSON(arg, boundPath) { var newArg = arg; if (boundPath.length) { newArg = {}; for (var i = 0, len = boundPath.length - 1; i < len; i++) { newArg[boundPath[i]] = {}; } newArg[boundPath[i]] = arg; } return newArg; } function mergeBoundPathIntoPathValue(arg, boundPath) { return { path: boundPath.concat(arg.path), value: arg.value }; } },{"./isJSONG":29,"./isPathOrPathValue":30}],32:[function(_dereq_,module,exports){ module.exports = function onCompletedOrError(onCompleted, onError, errors) { if (errors.length) { onError(errors); } else { onCompleted(); } }; },{}],33:[function(_dereq_,module,exports){ /** * will onNext the observer with the seeds provided. * @param {Model} model * @param {Function} onNext * @param {Array.<Object>} seeds * @param {Function} [selector] */ module.exports = function onNextValues(model, onNext, seeds, selector) { var root = model._root; root.allowSync = true; if (selector) { if (seeds.length) { // they should be wrapped in json items onNext(selector.apply(model, seeds.map(function(x, i) { return x.json; }))); } else { onNext(selector.call(model)); } } else { // this means there is an onNext function that is not AsValues or progressive, // therefore there must only be one onNext call, which should only be the 0 // index of the values of the array onNext(seeds[0]); } root.allowSync = false; }; },{}],34:[function(_dereq_,module,exports){ var buildJSONGOperation = _dereq_('./buildJSONGOperation'); /** * It performs the opposite of combine operations. It will take a JSONG * response and partition them into the required amount of operations. * @param {{jsong: {}, paths:[]}} jsongResponse */ module.exports = partitionOperations; function partitionOperations( jsongResponse, seeds, format, onNext) { var partitionedOps = []; var requestedMissingPaths = jsongResponse.paths; if (format === 'AsJSON') { // fast collapse ass the requestedMissingPaths into their // respective groups var opsFromRequestedMissingPaths = []; var op = null; for (var i = 0, len = requestedMissingPaths.length; i < len; i++) { var missingPath = requestedMissingPaths[i]; if (!op || op.idx !== missingPath.pathSetIndex) { op = { idx: missingPath.pathSetIndex, paths: [] }; opsFromRequestedMissingPaths.push(op); } op.paths.push(missingPath); } opsFromRequestedMissingPaths.forEach(function(op, i) { var seed = [seeds[op.idx]]; var jsong = { jsong: jsongResponse.jsong, paths: op.paths }; partitionedOps.push(buildJSONGOperation( format, seed, jsong, op.idx, onNext)); }); } else { partitionedOps[0] = buildJSONGOperation(format, seeds, jsongResponse, 0, onNext); } return partitionedOps; } },{"./buildJSONGOperation":25}],35:[function(_dereq_,module,exports){ module.exports = function primeSeeds(selector, selectorLength) { var seeds = []; if (selector) { for (i = 0; i < selectorLength; i++) { seeds.push({}); } } else { seeds[0] = {}; } return seeds; }; },{}],36:[function(_dereq_,module,exports){ module.exports = function processOperations(model, operations, errorSelector, boundPath) { return operations.reduce(function(memo, operation) { var jsonGraphOperation = model[operation.methodName]; var seedsOrFunction = operation.isValues ? operation.onNext : operation.seeds; var results = jsonGraphOperation( model, operation.args, seedsOrFunction, operation.onNext, errorSelector, boundPath); var missing = results.requestedMissingPaths; var offset = operation.seedsOffset; for (var i = 0, len = missing.length; i < len; i++) { missing[i].boundPath = boundPath; missing[i].pathSetIndex += offset; } memo.requestedMissingPaths = memo.requestedMissingPaths.concat(missing); memo.optimizedMissingPaths = memo.optimizedMissingPaths.concat(results.optimizedMissingPaths); memo.errors = memo.errors.concat(results.errors); memo.valuesReceived = memo.valuesReceived || results.requestedPaths.length > 0; return memo; }, { errors: [], requestedMissingPaths: [], optimizedMissingPaths: [], valuesReceived: false }); } },{}],37:[function(_dereq_,module,exports){ module.exports = function isSeedRequired(format) { return format === 'AsJSON' || format === 'AsJSONG' || format === 'AsPathMap'; }; },{}],38:[function(_dereq_,module,exports){ module.exports = function setSeedsOnGroups(groups, seeds, hasSelector) { var valueIndex = 0; var seedsLength = seeds.length; var j, i, len = groups.length, gLen, group; if (hasSelector) { for (i = 0; i < len && valueIndex < seedsLength; i++) { group = groups[i]; gLen = gLen = group.args.length; for (j = 0; j < gLen && valueIndex < seedsLength; j++, valueIndex++) { group.seeds.push(seeds[valueIndex]); } } } else { for (i = 0; i < len && valueIndex < seedsLength; i++) { groups[i].seeds = seeds; } } } },{}],39:[function(_dereq_,module,exports){ var setSeedsOnGroups = _dereq_('./setSeedsOnGroups'); module.exports = function setSeedsOrOnNext(operations, seedRequired, seeds, onNext, selector) { if (seedRequired) { setSeedsOnGroups(operations, seeds, selector); } else { for (i = 0; i < operations.length; i++) { operations[i].onNext = onNext; } } }; },{"./setSeedsOnGroups":38}],40:[function(_dereq_,module,exports){ var falcor = _dereq_('./../Falcor'); var NOOP = falcor.NOOP; var RequestQueue = function(jsongModel, scheduler) { this._scheduler = scheduler; this._jsongModel = jsongModel; this._scheduled = false; this._requests = []; }; RequestQueue.prototype = { _get: function() { var i = -1; var requests = this._requests; while (++i < requests.length) { if (!requests[i].pending && requests[i].isGet) { return requests[i]; } } return requests[requests.length] = new GetRequest(this._jsongModel, this); }, _set: function() { var i = -1; var requests = this._requests; // TODO: Set always sends off a request immediately, so there is no batching. while (++i < requests.length) { if (!requests[i].pending && requests[i].isSet) { return requests[i]; } } return requests[requests.length] = new SetRequest(this._jsongModel, this); }, remove: function(request) { for (var i = this._requests.length - 1; i > -1; i--) { if (this._requests[i].id === request.id && this._requests.splice(i, 1)) { break; } } }, set: function(jsongEnv, observer) { var self = this; var disposable = self._set().batch(jsongEnv, observer).flush(); return { dispose: function() { disposable.dispose(); } }; }, get: function(requestedPaths, optimizedPaths, observer) { var self = this; var disposable = null; // TODO: get does not batch across requests. self._get().batch(requestedPaths, optimizedPaths, observer); if (!self._scheduled) { self._scheduled = true; disposable = self._scheduler.schedule(self._flush.bind(self)); } return { dispose: function() { disposable.dispose(); } }; }, _flush: function() { this._scheduled = false; var requests = this._requests, i = -1; var disposables = []; while (++i < requests.length) { if (!requests[i].pending) { disposables[disposables.length] = requests[i].flush(); } } return { dispose: function() { disposables.forEach(function(d) { d.dispose(); }); } }; } }; var REQUEST_ID = 0; var SetRequest = function(model, queue) { var self = this; self._jsongModel = model; self._queue = queue; self.observers = []; self.jsongEnvs = []; self.pending = false; self.id = ++REQUEST_ID; self.isSet = true; }; SetRequest.prototype = { batch: function(jsongEnv, observer) { var self = this; observer.onNext = observer.onNext || NOOP; observer.onError = observer.onError || NOOP; observer.onCompleted = observer.onCompleted || NOOP; if (!observer.__observerId) { observer.__observerId = ++REQUEST_ID; } observer._requestId = self.id; self.observers[self.observers.length] = observer; self.jsongEnvs[self.jsongEnvs.length] = jsongEnv; return self; }, flush: function() { var incomingValues, query, op, len; var self = this; var jsongs = self.jsongEnvs; var observers = self.observers; var model = self._jsongModel; self.pending = true; // TODO: Set does not batch. return model._dataSource. set(jsongs[0]). subscribe(function(response) { incomingValues = response; }, function(err) { var i = -1; var n = observers.length; while (++i < n) { obs = observers[i]; obs.onError && obs.onError(err); } }, function() { var i, n, obs; self._queue.remove(self); i = -1; n = observers.length; while (++i < n) { obs = observers[i]; obs.onNext && obs.onNext({ jsong: incomingValues.jsong || incomingValues.value, paths: incomingValues.paths }); obs.onCompleted && obs.onCompleted(); } }); } }; var GetRequest = function(jsongModel, queue) { var self = this; self._jsongModel = jsongModel; self._queue = queue; self.observers = []; self.optimizedPaths = []; self.requestedPaths = []; self.pending = false; self.id = ++REQUEST_ID; self.isGet = true; }; GetRequest.prototype = { batch: function(requestedPaths, optimizedPaths, observer) { // TODO: Do we need to gap fill? var self = this; observer.onNext = observer.onNext || NOOP; observer.onError = observer.onError || NOOP; observer.onCompleted = observer.onCompleted || NOOP; if (!observer.__observerId) { observer.__observerId = ++REQUEST_ID; } observer._requestId = self.id; self.observers[self.observers.length] = observer; self.optimizedPaths[self.optimizedPaths.length] = optimizedPaths; self.requestedPaths[self.requestedPaths.length] = requestedPaths; return self; }, flush: function() { var incomingValues, query, op, len; var self = this; var requested = self.requestedPaths; var optimized = self.optimizedPaths; var observers = self.observers; var disposables = []; var results = []; var model = self._jsongModel; self._scheduled = false; self.pending = true; var optimizedMaps = {}; var requestedMaps = {}; var r, o, i, j, obs, resultIndex; for (i = 0, len = requested.length; i < len; i++) { r = requested[i]; o = optimized[i]; obs = observers[i]; for (j = 0; j < r.length; j++) { pathsToMapWithObservers(r[j], 0, readyNode(requestedMaps, null, obs), obs); pathsToMapWithObservers(o[j], 0, readyNode(optimizedMaps, null, obs), obs); } } return model._dataSource. get(collapse(optimizedMaps)). subscribe(function(response) { incomingValues = response; }, function(err) { var i = -1; var n = observers.length; while (++i < n) { obs = observers[i]; obs.onError && obs.onError(err); } }, function() { var i, n, obs; self._queue.remove(self); i = -1; n = observers.length; while (++i < n) { obs = observers[i]; obs.onNext && obs.onNext({ jsong: incomingValues.jsong || incomingValues.value, paths: incomingValues.paths }); obs.onCompleted && obs.onCompleted(); } }); }, // Returns the paths that are contained within this request. contains: function(requestedPaths, optimizedPaths) { // TODO: } }; function pathsToMapWithObservers(path, idx, branch, observer) { var curr = path[idx]; // Object / Array if (typeof curr === 'object') { if (Array.isArray(curr)) { curr.forEach(function(v) { readyNode(branch, v, observer); if (path.length > idx + 1) { pathsToMapWithObservers(path, idx + 1, branch[v], observer); } }); } else { var from = curr.from || 0; var to = curr.to >= 0 ? curr.to : curr.length; for (var i = from; i <= to; i++) { readyNode(branch, i, observer); if (path.length > idx + 1) { pathsToMapWithObservers(path, idx + 1, branch[i], observer); } } } } else { readyNode(branch, curr, observer); if (path.length > idx + 1) { pathsToMapWithObservers(path, idx + 1, branch[curr], observer); } } } /** * Builds the set of collapsed * queries by traversing the tree * once */ var charPattern = /\D/i; function readyNode(branch, key, observer) { if (key === null) { branch.__observers = branch.__observers || []; !containsObserver(branch.__observers, observer) && branch.__observers.push(observer); return branch; } if (!branch[key]) { branch[key] = {__observers: []}; } !containsObserver(branch[key].__observers, observer) && branch[key].__observers.push(observer); return branch; } function containsObserver(observers, observer) { if (!observer) { return; } return observers.reduce(function(acc, x) { return acc || x.__observerId === observer.__observerId; }, false); } function collapse(pathMap) { return rangeCollapse(buildQueries(pathMap)); } /** * Collapse ranges, e.g. when there is a continuous range * in an array, turn it into an object instead * * [1,2,3,4,5,6] => {"from":1, "to":6} * */ function rangeCollapse(paths) { paths.forEach(function (path) { path.forEach(function (elt, index) { var range; if (Array.isArray(elt) && elt.every(isNumber) && allUnique(elt)) { elt.sort(function(a, b) { return a - b; }); if (elt[elt.length-1] - elt[0] === elt.length-1) { // create range range = {}; range.from = elt[0]; range.to = elt[elt.length-1]; path[index] = range; } } }); }); return paths; } /* jshint forin: false */ function buildQueries(root) { if (root == null || typeof root !== 'object') { return [ [] ]; } var children = Object.keys(root).filter(notPathMapInternalKeys), child, memo, paths, key, childIsNum, list, head, tail, clone, results, i = -1, n = children.length, j, k, x; if (n === 0 || Array.isArray(root) === true) { return [ [] ]; } memo = {}; while(++i < n) { child = children[i]; paths = buildQueries(root[child]); key = createKey(paths); childIsNum = typeof child === 'string' && !charPattern.test(child); if ((list = memo[key]) && (head = list.head)) { head[head.length] = childIsNum ? parseInt(child, 10) : child; } else { memo[key] = { head: [childIsNum ? parseInt(child, 10) : child], tail: paths }; } } results = []; for(x in memo) { head = (list = memo[x]).head; tail = list.tail; i = -1; n = tail.length; while(++i < n) { list = tail[i]; j = -1; k = list.length; if(head[0] === '') { clone = []; } else { clone = [head.length === 1 ? head[0] : head]; while(++j < k) { clone[j + 1] = list[j]; } } results[results.length] = clone; } } return results; } function notPathMapInternalKeys(key) { return ( key !== "__observers" && key !== "__pending" && key !== "__batchID" ); } /** * Return true if argument is a number */ function isNumber(val) { return typeof val === "number"; } /** * allUnique * return true if every number in an array is unique */ function allUnique(arr) { var hash = {}, index, len; for (index = 0, len = arr.length; index < len; index++) { if (hash[arr[index]]) { return false; } hash[arr[index]] = true; } return true; } /** * Sort a list-of-lists * Used for generating a unique hash * key for each subtree; used by the * memoization */ function sortLol(lol) { return lol.reduce(function (result, curr) { if (curr instanceof Array) { result.push(sortLol(curr).slice(0).sort()); return result; } return result.concat(curr); }, []).slice(0).sort(); } /** * Create a unique hash key for a set * of paths */ function createKey(list) { return JSON.stringify(sortLol(list)); } // Note: For testing falcor.__Internals.buildQueries = buildQueries; module.exports = RequestQueue; },{"./../Falcor":2}],41:[function(_dereq_,module,exports){ (function (global){ /** Rx Ultralite! Rx on the Roku Tyler throws this (possibly related to browserify-ing Rx): Error: 'TypeError: 'undefined' is not a function (evaluating 'root.document.createElement('script')')' */ var Rx; if (typeof window !== "undefined" && typeof window["Rx"] !== "undefined") { // Browser environment Rx = window["Rx"]; } else if (typeof global !== "undefined" && typeof global["Rx"] !== "undefined") { // Node.js environment Rx = global["Rx"]; } else if (typeof _dereq_ !== 'undefined' || typeof window !== 'undefined' && window.require) { var r = typeof _dereq_ !== 'undefined' && _dereq_ || window.require; try { // CommonJS environment with rx module Rx = r("rx"); } catch(e) { Rx = undefined; } } if(Rx === undefined) { Rx = { I: function() { return arguments[0]; }, Disposable: (function() { function Disposable(a) { this.action = a; } Disposable.create = function(a) { return new Disposable(a); }; Disposable.empty = new Disposable(function(){}); Disposable.prototype.dispose = function() { if(typeof this.action === 'function') { this.action(); } }; return Disposable; })(), Observable: (function() { function Observable(s) { this._subscribe = s; } Observable.create = Observable.createWithDisposable = function(s) { return new Observable(s); }; Observable.fastCreateWithDisposable = Observable.create; Observable.fastReturnValue = function(value) { return Observable.create(function(observer) { observer.onNext(value); observer.onCompleted(); }); }; // NOTE: Required for Router Observable.prototype.from; Observable.prototype.materialize; Observable.prototype.reduce; Observable.of = function() { var len = arguments.length, args = new Array(len); for(var i = 0; i < len; i++) { args[i] = arguments[i]; } return Observable.create(function(observer) { var errorOcurred = false; try { for(var i = 0; i < len; ++i) { observer.onNext(args[i]); } } catch(e) { errorOcurred = true; observer.onError(e); } if(errorOcurred !== true) { observer.onCompleted(); } }); } Observable.prototype.subscribe = function(n, e, c) { return this._subscribe( (n != null && typeof n === 'object') ? n : Rx.Observer.create(n, e, c) ); }; Observable.prototype.forEach = Observable.prototype.subscribe; Observable.prototype.catchException = function(next) { var self = this; return Observable.create(function(o) { return self.subscribe( function(x) { o.onNext(x); }, function(e) { return ( (typeof next === 'function') ? next(e) : next ).subscribe(o); }, function() { o.onCompleted(); }); }); }; return Observable; })(), Observer: (function() { function Observer(n, e, c) { this.onNext = n || Rx.I; this.onError = e || Rx.I; this.onCompleted = c || Rx.I; } Observer.create = function(n, e, c) { return new Observer(n, e, c); }; return Observer; })(), Subject: (function(){ function Subject() { this.observers = []; } Subject.prototype.subscribe = function(subscriber) { var a = this.observers, n = a.length; a[n] = subscriber; return { dispose: function() { a.splice(n, 1); } } }; Subject.prototype.onNext = function(x) { var listeners = this.observers.concat(), i = -1, n = listeners.length; while(++i < n) { listeners[i].onNext(x); } }; Subject.prototype.onError = function(e) { var listeners = this.observers.concat(), i = -1, n = listeners.length; this.observers.length = 0; while(++i < n) { listeners[i].onError(e); } }; Subject.prototype.onCompleted = function() { var listeners = this.observers.concat(), i = -1, n = listeners.length; this.observers.length = 0; while(++i < n) { listeners[i].onCompleted(); } }; })() }; } module.exports = Rx; }).call(this,typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {}) },{}],42:[function(_dereq_,module,exports){ function ImmediateScheduler() { } ImmediateScheduler.prototype = { schedule: function(action) { action(); } }; module.exports = ImmediateScheduler; },{}],43:[function(_dereq_,module,exports){ function TimeoutScheduler(delay) { this.delay = delay; } TimeoutScheduler.prototype = { schedule: function(action) { setTimeout(action, this.delay); } }; module.exports = TimeoutScheduler; },{}],44:[function(_dereq_,module,exports){ var hardLink = _dereq_('./util/hardlink'); var createHardlink = hardLink.create; var onValue = _dereq_('./onValue'); var isExpired = _dereq_('./util/isExpired'); var $path = _dereq_('./../types/path.js'); var __context = _dereq_("../internal/context"); function followReference(model, root, node, referenceContainer, reference, seed, outputFormat) { var depth = 0; var k, next; while (true) { if (depth === 0 && referenceContainer[__context]) { depth = reference.length; next = referenceContainer[__context]; } else { k = reference[depth++]; next = node[k]; } if (next) { var type = next.$type; var value = type && next.value || next; if (depth < reference.length) { if (type) { node = next; break; } node = next; continue; } // We need to report a value or follow another reference. else { node = next; if (type && isExpired(next)) { break; } if (!referenceContainer[__context]) { createHardlink(referenceContainer, next); } // Restart the reference follower. if (type === $path) { if (outputFormat === 'JSONG') { onValue(model, next, seed, null, null, reference, null, outputFormat); } depth = 0; reference = value; referenceContainer = next; node = root; continue; } break; } } else { node = undefined; } break; } if (depth < reference.length) { var ref = []; for (var i = 0; i < depth; i++) { ref[i] = reference[i]; } reference = ref; } return [node, reference]; } module.exports = followReference; },{"../internal/context":66,"./../types/path.js":140,"./onValue":56,"./util/hardlink":58,"./util/isExpired":59}],45:[function(_dereq_,module,exports){ var getBoundValue = _dereq_('./getBoundValue'); var isPathValue = _dereq_('./util/isPathValue'); module.exports = function(walk) { return function getAsJSON(model, paths, values) { var results = { values: [], errors: [], requestedPaths: [], optimizedPaths: [], requestedMissingPaths: [], optimizedMissingPaths: [] }; var requestedMissingPaths = results.requestedMissingPaths; var inputFormat = Array.isArray(paths[0]) || isPathValue(paths[0]) ? 'Paths' : 'JSON'; var cache = model._cache; var boundPath = model._path; var currentCachePosition; var missingIdx = 0; var boundOptimizedPath, optimizedPath; var i, j, len, bLen; results.values = values; if (!values) { values = []; } if (boundPath.length) { var boundValue = getBoundValue(model, boundPath); currentCachePosition = boundValue.value; optimizedPath = boundOptimizedPath = boundValue.path; } else { currentCachePosition = cache; optimizedPath = boundOptimizedPath = []; } for (i = 0, len = paths.length; i < len; i++) { var valueNode = undefined; var pathSet = paths[i]; if (values[i]) { valueNode = values[i]; } if (len > 1) { optimizedPath = []; for (j = 0, bLen = boundOptimizedPath.length; j < bLen; j++) { optimizedPath[i] = boundOptimizedPath[i]; } } if (pathSet.path) { pathSet = pathSet.path; } walk(model, cache, currentCachePosition, pathSet, 0, valueNode, [], results, optimizedPath, [], inputFormat, 'JSON'); if (missingIdx < requestedMissingPaths.length) { for (j = missingIdx, length = requestedMissingPaths.length; j < length; j++) { requestedMissingPaths[j].pathSetIndex = i; } missingIdx = length; } } return results; }; }; },{"./getBoundValue":49,"./util/isPathValue":61}],46:[function(_dereq_,module,exports){ var getBoundValue = _dereq_('./getBoundValue'); var isPathValue = _dereq_('./util/isPathValue'); module.exports = function(walk) { return function getAsJSONG(model, paths, values) { var results = { values: [], errors: [], requestedPaths: [], optimizedPaths: [], requestedMissingPaths: [], optimizedMissingPaths: [] }; var inputFormat = Array.isArray(paths[0]) || isPathValue(paths[0]) ? 'Paths' : 'JSON'; results.values = values; var cache = model._cache; var boundPath = model._path; var currentCachePosition; if (boundPath.length) { throw 'It is not legal to use the JSON Graph format from a bound Model. JSON Graph format can only be used from a root model.'; } else { currentCachePosition = cache; } for (var i = 0, len = paths.length; i < len; i++) { var pathSet = paths[i]; if (pathSet.path) { pathSet = pathSet.path; } walk(model, cache, currentCachePosition, pathSet, 0, values[0], [], results, [], [], inputFormat, 'JSONG'); } return results; }; }; },{"./getBoundValue":49,"./util/isPathValue":61}],47:[function(_dereq_,module,exports){ var getBoundValue = _dereq_('./getBoundValue'); var isPathValue = _dereq_('./util/isPathValue'); module.exports = function(walk) { return function getAsPathMap(model, paths, values) { var valueNode; var results = { values: [], errors: [], requestedPaths: [], optimizedPaths: [], requestedMissingPaths: [], optimizedMissingPaths: [] }; var inputFormat = Array.isArray(paths[0]) || isPathValue(paths[0]) ? 'Paths' : 'JSON'; valueNode = values[0]; results.values = values; var cache = model._cache; var boundPath = model._path; var currentCachePosition; var optimizedPath, boundOptimizedPath; if (boundPath.length) { var boundValue = getBoundValue(model, boundPath); currentCachePosition = boundValue.value; optimizedPath = boundOptimizedPath = boundValue.path; } else { currentCachePosition = cache; optimizedPath = boundOptimizedPath = []; } for (var i = 0, len = paths.length; i < len; i++) { if (len > 1) { optimizedPath = []; for (j = 0, bLen = boundOptimizedPath.length; j < bLen; j++) { optimizedPath[i] = boundOptimizedPath[i]; } } var pathSet = paths[i]; if (pathSet.path) { pathSet = pathSet.path; } walk(model, cache, currentCachePosition, pathSet, 0, valueNode, [], results, optimizedPath, [], inputFormat, 'PathMap'); } return results; }; }; },{"./getBoundValue":49,"./util/isPathValue":61}],48:[function(_dereq_,module,exports){ var getBoundValue = _dereq_('./getBoundValue'); var isPathValue = _dereq_('./util/isPathValue'); module.exports = function(walk) { return function getAsValues(model, paths, onNext) { var results = { values: [], errors: [], requestedPaths: [], optimizedPaths: [], requestedMissingPaths: [], optimizedMissingPaths: [] }; var inputFormat = Array.isArray(paths[0]) || isPathValue(paths[0]) ? 'Paths' : 'JSON'; var cache = model._cache; var boundPath = model._path; var currentCachePosition; var optimizedPath, boundOptimizedPath; if (boundPath.length) { var boundValue = getBoundValue(model, boundPath); currentCachePosition = boundValue.value; optimizedPath = boundOptimizedPath = boundValue.path; } else { currentCachePosition = cache; optimizedPath = boundOptimizedPath = []; } for (var i = 0, len = paths.length; i < len; i++) { if (len > 1) { optimizedPath = []; for (j = 0, bLen = boundOptimizedPath.length; j < bLen; j++) { optimizedPath[i] = boundOptimizedPath[i]; } } var pathSet = paths[i]; if (pathSet.path) { pathSet = pathSet.path; } walk(model, cache, currentCachePosition, pathSet, 0, onNext, null, results, optimizedPath, [], inputFormat, 'Values'); } return results; }; }; },{"./getBoundValue":49,"./util/isPathValue":61}],49:[function(_dereq_,module,exports){ var getValueSync = _dereq_('./getValueSync'); module.exports = function getBoundValue(model, path) { var boxed, value, shorted; boxed = model._boxed; model._boxed = true; value = getValueSync(model, path.concat(null)); model._boxed = boxed; path = value.optimizedPath; shorted = value.shorted; value = value.value; while (path.length && path[path.length - 1] === null) { path.pop(); } return { path: path, value: value, shorted: shorted }; }; },{"./getValueSync":50}],50:[function(_dereq_,module,exports){ var followReference = _dereq_('./followReference'); var clone = _dereq_('./util/clone'); var isExpired = _dereq_('./util/isExpired'); var promote = _dereq_('./util/lru').promote; var $path = _dereq_('./../types/path.js'); var $sentinel = _dereq_('./../types/sentinel.js'); var $error = _dereq_('./../types/error.js'); module.exports = function getValueSync(model, simplePath) { var root = model._cache; var len = simplePath.length; var optimizedPath = []; var shorted = false, shouldShort = false; var depth = 0; var key, next = root, type, curr = root, out, ref, refNode; do { key = simplePath[depth++]; if (key !== null) { next = curr[key]; } if (!next) { out = undefined; shorted = true; break; } type = next.$type; optimizedPath.push(key); // Up to the last key we follow references if (depth < len) { if (type === $path) { ref = followReference(model, root, root, next, next.value); refNode = ref[0]; if (!refNode) { out = undefined; break; } type = refNode.$type; next = refNode; optimizedPath = ref[1]; } if (type) { break; } } // If there is a value, then we have great success, else, report an undefined. else { out = next; } curr = next; } while (next && depth < len); if (depth < len) { // Unfortunately, if all that follows are nulls, then we have not shorted. for (;depth < len; ++depth) { if (simplePath[depth] !== null) { shouldShort = true; break; } } // if we should short or report value. Values are reported on nulls. if (shouldShort) { shorted = true; out = undefined; } else { out = next; } } // promotes if not expired if (out) { if (isExpired(out)) { out = undefined; } else { promote(model, out); } } if (out && out.$type === $error && !model._treatErrorsAsValues) { throw {path: simplePath, value: out.value}; } else if (out && model._boxed) { out = !!type ? clone(out) : out; } else if (!out && model._materialized) { out = {$type: $sentinel}; } else if (out) { out = out.value; } return { value: out, shorted: shorted, optimizedPath: optimizedPath }; }; },{"./../types/error.js":139,"./../types/path.js":140,"./../types/sentinel.js":141,"./followReference":44,"./util/clone":57,"./util/isExpired":59,"./util/lru":62}],51:[function(_dereq_,module,exports){ var followReference = _dereq_('./followReference'); var onError = _dereq_('./onError'); var onMissing = _dereq_('./onMissing'); var onValue = _dereq_('./onValue'); var lru = _dereq_('./util/lru'); var hardLink = _dereq_('./util/hardlink'); var isMaterialized = _dereq_('./util/isMaterialzed'); var removeHardlink = hardLink.remove; var splice = lru.splice; var isExpired = _dereq_('./util/isExpired'); var permuteKey = _dereq_('./util/permuteKey'); var $path = _dereq_('./../types/path'); var $error = _dereq_('./../types/error'); var __invalidated = _dereq_("../internal/invalidated"); // TODO: Objectify? function walk(model, root, curr, pathOrJSON, depth, seedOrFunction, positionalInfo, outerResults, optimizedPath, requestedPath, inputFormat, outputFormat, fromReference) { if ((!curr || curr && curr.$type) && evaluateNode(model, curr, pathOrJSON, depth, seedOrFunction, requestedPath, optimizedPath, positionalInfo, outerResults, outputFormat, fromReference)) { return; } // We continue the search to the end of the path/json structure. else { // Base case of the searching: Have we hit the end of the road? // Paths // 1) depth === path.length // PathMaps (json input) // 2) if its an object with no keys // 3) its a non-object var jsonQuery = inputFormat === 'JSON'; var atEndOfJSONQuery = false; var k, i, len; if (jsonQuery) { // it has a $type property means we have hit a end. if (pathOrJSON && pathOrJSON.$type) { atEndOfJSONQuery = true; } // is it an object? else if (pathOrJSON && typeof pathOrJSON === 'object') { // A terminating condition k = Object.keys(pathOrJSON); if (k.length === 1) { k = k[0]; } } // found a primitive, we hit the end. else { atEndOfJSONQuery = true; } } else { k = pathOrJSON[depth]; } // BaseCase: we have hit the end of our query without finding a 'leaf' node, therefore emit missing. if (atEndOfJSONQuery || !jsonQuery && depth === pathOrJSON.length) { if (isMaterialized(model)) { onValue(model, curr, seedOrFunction, outerResults, requestedPath, optimizedPath, positionalInfo, outputFormat, fromReference); return; } onMissing(model, curr, pathOrJSON, depth, seedOrFunction, outerResults, requestedPath, optimizedPath, positionalInfo, outputFormat); return; } var memo = {done: false}; var permutePosition = positionalInfo; var permuteRequested = requestedPath; var permuteOptimized = optimizedPath; var asJSONG = outputFormat === 'JSONG'; var asJSON = outputFormat === 'JSON'; var isKeySet = false; var hasChildren = false; depth++; var key; if (k && typeof k === 'object') { memo.isArray = Array.isArray(k); memo.arrOffset = 0; key = permuteKey(k, memo); isKeySet = true; } else { key = k; memo.done = true; } if (asJSON && isKeySet) { permutePosition = []; for (i = 0, len = positionalInfo.length; i < len; i++) { permutePosition[i] = positionalInfo[i]; } permutePosition.push(depth - 1); } do { fromReference = false; if (!memo.done) { permuteOptimized = []; permuteRequested = []; for (i = 0, len = requestedPath.length; i < len; i++) { permuteRequested[i] = requestedPath[i]; } for (i = 0, len = optimizedPath.length; i < len; i++) { permuteOptimized[i] = optimizedPath[i]; } } var nextPathOrPathMap = jsonQuery ? pathOrJSON[key] : pathOrJSON; if (jsonQuery && nextPathOrPathMap) { if (typeof nextPathOrPathMap === 'object') { if (nextPathOrPathMap.$type) { hasChildren = false; } else { hasChildren = Object.keys(nextPathOrPathMap).length > 0; } } } var next; if (key === null || jsonQuery && key === '__null') { next = curr; } else { next = curr[key]; permuteOptimized.push(key); permuteRequested.push(key); } if (next) { var nType = next.$type; var value = nType && next.value || next; if (jsonQuery && hasChildren || !jsonQuery && depth < pathOrJSON.length) { if (nType && nType === $path && !isExpired(next)) { if (asJSONG) { onValue(model, next, seedOrFunction, outerResults, false, permuteOptimized, permutePosition, outputFormat); } var ref = followReference(model, root, root, next, value, seedOrFunction, outputFormat); fromReference = true; next = ref[0]; var refPath = ref[1]; permuteOptimized = []; for (i = 0, len = refPath.length; i < len; i++) { permuteOptimized[i] = refPath[i]; } } } } walk(model, root, next, nextPathOrPathMap, depth, seedOrFunction, permutePosition, outerResults, permuteOptimized, permuteRequested, inputFormat, outputFormat, fromReference); if (!memo.done) { key = permuteKey(k, memo); } } while (!memo.done); } } function evaluateNode(model, curr, pathOrJSON, depth, seedOrFunction, requestedPath, optimizedPath, positionalInfo, outerResults, outputFormat, fromReference) { // BaseCase: This position does not exist, emit missing. if (!curr) { if (isMaterialized(model)) { onValue(model, curr, seedOrFunction, outerResults, requestedPath, optimizedPath, positionalInfo, outputFormat, fromReference); } else { onMissing(model, curr, pathOrJSON, depth, seedOrFunction, outerResults, requestedPath, optimizedPath, positionalInfo, outputFormat); } return true; } var currType = curr.$type; positionalInfo = positionalInfo || []; // The Base Cases. There is a type, therefore we have hit a 'leaf' node. if (currType === $error) { if (fromReference) { requestedPath.push(null); } if (outputFormat === 'JSONG' || model._treatErrorsAsValues) { onValue(model, curr, seedOrFunction, outerResults, requestedPath, optimizedPath, positionalInfo, outputFormat, fromReference); } else { onError(model, curr, requestedPath, optimizedPath, outerResults); } } // Else we have found a value, emit the current position information. else { if (isExpired(curr)) { if (!curr[__invalidated]) { splice(model, curr); removeHardlink(curr); } onMissing(model, curr, pathOrJSON, depth, seedOrFunction, outerResults, requestedPath, optimizedPath, positionalInfo, outputFormat); } else { onValue(model, curr, seedOrFunction, outerResults, requestedPath, optimizedPath, positionalInfo, outputFormat, fromReference); } } return true; } module.exports = walk; },{"../internal/invalidated":69,"./../types/error":139,"./../types/path":140,"./followReference":44,"./onError":54,"./onMissing":55,"./onValue":56,"./util/hardlink":58,"./util/isExpired":59,"./util/isMaterialzed":60,"./util/lru":62,"./util/permuteKey":63}],52:[function(_dereq_,module,exports){ var walk = _dereq_('./getWalk'); module.exports = { getAsJSON: _dereq_('./getAsJSON')(walk), getAsJSONG: _dereq_('./getAsJSONG')(walk), getAsValues: _dereq_('./getAsValues')(walk), getAsPathMap: _dereq_('./getAsPathMap')(walk), getValueSync: _dereq_('./getValueSync'), getBoundValue: _dereq_('./getBoundValue'), setCache: _dereq_('./legacy_setCache') }; },{"./getAsJSON":45,"./getAsJSONG":46,"./getAsPathMap":47,"./getAsValues":48,"./getBoundValue":49,"./getValueSync":50,"./getWalk":51,"./legacy_setCache":53}],53:[function(_dereq_,module,exports){ /* istanbul ignore next */ var NOOP = function NOOP() {}, __GENERATION_GUID = 0, __GENERATION_VERSION = 0, __CONTAINER = "__reference_container", __CONTEXT = "__context", __GENERATION = "__generation", __GENERATION_UPDATED = "__generation_updated", __INVALIDATED = "__invalidated", __KEY = "__key", __KEYS = "__keys", __IS_KEY_SET = "__is_key_set", __NULL = "__null", __SELF = "./", __PARENT = "../", __REF = "__ref", __REF_INDEX = "__ref_index", __REFS_LENGTH = "__refs_length", __ROOT = "/", __OFFSET = "__offset", __FALKOR_EMPTY_OBJECT = '__FALKOR_EMPTY_OBJECT', __INTERNAL_KEYS = [ __CONTAINER, __CONTEXT, __GENERATION, __GENERATION_UPDATED, __INVALIDATED, __KEY, __KEYS, __IS_KEY_SET, __NULL, __SELF, __PARENT, __REF, __REF_INDEX, __REFS_LENGTH, __OFFSET, __ROOT ], $TYPE = "$type", $SIZE = "$size", $EXPIRES = "$expires", $TIMESTAMP = "$timestamp", SENTINEL = "sentinel", PATH = "ref", ERROR = "error", VALUE = "value", EXPIRED = "expired", LEAF = "leaf"; /* istanbul ignore next */ module.exports = function setCache(model, map) { var root = model._root, expired = root.expired, depth = 0, height = 0, mapStack = [], nodes = [], nodeRoot = model._cache, nodeParent = nodeRoot, node = nodeParent, nodeType, nodeValue, nodeSize, nodeTimestamp, nodeExpires; mapStack[0] = map; nodes[-1] = nodeParent; while (depth > -1) { /* Walk Path Map */ var isTerminus = false, offset = 0, keys = void 0, index = void 0, key = void 0, isKeySet = false; node = nodeParent = nodes[depth - 1]; depth = depth; follow_path_map_9177: do { height = depth; nodeType = node && node[$TYPE] || void 0; nodeValue = nodeType === SENTINEL ? node[VALUE] : node; if ((isTerminus = !((map = mapStack[offset = depth * 4]) != null && typeof map === 'object') || map[$TYPE] !== void 0 || Array.isArray(map) || !((keys = mapStack[offset + 1] || (mapStack[offset + 1] = Object.keys(map))) && ((index = mapStack[offset + 2] || (mapStack[offset + 2] = 0)) || true) && ((isKeySet = keys.length > 1) || keys.length > 0))) || (node == null || nodeType !== void 0 || typeof node !== 'object' || Array.isArray(nodeValue))) { if ((nodeExpires = (node && node[$EXPIRES]) != null) && (nodeExpires !== 1 && (nodeExpires === 0 || nodeExpires < now())) || node != null && node[__INVALIDATED] === true) { nodeType = void 0; nodeValue = void 0; node = (expired[expired.length] = node) && (node[__INVALIDATED] = true) && void 0; } if (!isTerminus && ((!nodeType || nodeType === SENTINEL) && Array.isArray(nodeValue))) { if (node == null || nodeType !== void 0 || typeof node !== 'object' || Array.isArray(nodeValue)) { key = null; node = node; depth = depth; continue follow_path_map_9177; } } else { if (key != null) { var newNode, sizeOffset, edgeSize = node && node[$SIZE] || 0; nodeType = map && map[$TYPE] || void 0; nV2 = nodeType ? map[VALUE] : void 0; nodeValue = nodeType === SENTINEL ? map[VALUE] : map; newNode = map; if ((!nodeType || nodeType === SENTINEL || nodeType === PATH) && Array.isArray(nodeValue)) { delete nodeValue[$SIZE]; // console.log(1); if (nodeType) { nodeSize = 50 + (nodeValue.length || 1); } else { nodeSize = nodeValue.length || 1; } newNode[$SIZE] = nodeSize; nodeValue[__CONTAINER] = newNode; } else if (nodeType === SENTINEL || nodeType === PATH) { newNode[$SIZE] = nodeSize = 50 + (nV2 && typeof nV2.length === 'number' ? nV2.length : 1); } else if (nodeType === ERROR) { newNode[$SIZE] = nodeSize = map && map[$SIZE] || 0 || 50 + 1; } else if (!(map != null && typeof map === 'object')) { nodeSize = 50 + (typeof nodeValue === 'string' && nodeValue.length || 1); nodeType = 'sentinel'; newNode = {}; newNode[VALUE] = nodeValue; newNode[$TYPE] = nodeType; newNode[$SIZE] = nodeSize; } else { nodeType = newNode[$TYPE] = nodeType || GROUP; newNode[$SIZE] = nodeSize = map && map[$SIZE] || 0 || 50 + 1; } ; if (node !== newNode && (node != null && typeof node === 'object')) { var nodeRefsLength = node[__REFS_LENGTH] || 0, destRefsLength = newNode[__REFS_LENGTH] || 0, i = -1, ref; while (++i < nodeRefsLength) { if ((ref = node[__REF + i]) !== void 0) { ref[__CONTEXT] = newNode; newNode[__REF + (destRefsLength + i)] = ref; node[__REF + i] = void 0; } } newNode[__REFS_LENGTH] = nodeRefsLength + destRefsLength; node[__REFS_LENGTH] = ref = void 0; var invParent = nodeParent, invChild = node, invKey = key, keys$2, index$2, offset$2, childType, childValue, isBranch, stack = [ nodeParent, invKey, node ], depth$2 = 0; while (depth$2 > -1) { nodeParent = stack[offset$2 = depth$2 * 8]; invKey = stack[offset$2 + 1]; node = stack[offset$2 + 2]; if ((childType = stack[offset$2 + 3]) === void 0 || (childType = void 0)) { childType = stack[offset$2 + 3] = node && node[$TYPE] || void 0 || null; } childValue = stack[offset$2 + 4] || (stack[offset$2 + 4] = childType === SENTINEL ? node[VALUE] : node); if ((isBranch = stack[offset$2 + 5]) === void 0) { isBranch = stack[offset$2 + 5] = !childType && (node != null && typeof node === 'object') && !Array.isArray(childValue); } if (isBranch === true) { if ((keys$2 = stack[offset$2 + 6]) === void 0) { keys$2 = stack[offset$2 + 6] = []; index$2 = -1; for (var childKey in node) { !(!(childKey[0] !== '_' || childKey[1] !== '_') || (childKey === __SELF || childKey === __PARENT || childKey === __ROOT) || childKey[0] === '$') && (keys$2[++index$2] = childKey); } } index$2 = stack[offset$2 + 7] || (stack[offset$2 + 7] = 0); if (index$2 < keys$2.length) { stack[offset$2 + 7] = index$2 + 1; stack[offset$2 = ++depth$2 * 8] = node; stack[offset$2 + 1] = invKey = keys$2[index$2]; stack[offset$2 + 2] = node[invKey]; continue; } } var ref$2 = node[$TYPE] === SENTINEL ? node[VALUE] : node, destination; if (ref$2 && Array.isArray(ref$2)) { destination = ref$2[__CONTEXT]; if (destination) { var i$2 = (ref$2[__REF_INDEX] || 0) - 1, n = (destination[__REFS_LENGTH] || 0) - 1; while (++i$2 <= n) { destination[__REF + i$2] = destination[__REF + (i$2 + 1)]; } destination[__REFS_LENGTH] = n; ref$2[__REF_INDEX] = ref$2[__CONTEXT] = destination = void 0; } } if (node != null && typeof node === 'object') { var ref$3, i$3 = -1, n$2 = node[__REFS_LENGTH] || 0; while (++i$3 < n$2) { if ((ref$3 = node[__REF + i$3]) !== void 0) { ref$3[__CONTEXT] = node[__REF + i$3] = void 0; } } node[__REFS_LENGTH] = void 0; var root$2 = root, head = root$2.__head, tail = root$2.__tail, next = node.__next, prev = node.__prev; next != null && typeof next === 'object' && (next.__prev = prev); prev != null && typeof prev === 'object' && (prev.__next = next); node === head && (root$2.__head = root$2.__next = next); node === tail && (root$2.__tail = root$2.__prev = prev); node.__next = node.__prev = void 0; head = tail = next = prev = void 0; ; nodeParent[invKey] = node[__SELF] = node[__PARENT] = node[__ROOT] = void 0; } ; delete stack[offset$2 + 0]; delete stack[offset$2 + 1]; delete stack[offset$2 + 2]; delete stack[offset$2 + 3]; delete stack[offset$2 + 4]; delete stack[offset$2 + 5]; delete stack[offset$2 + 6]; delete stack[offset$2 + 7]; --depth$2; } nodeParent = invParent; node = invChild; } nodeParent[key] = node = newNode; nodeType = node && node[$TYPE] || void 0; node = !node[__SELF] && ((node[__SELF] = node) || true) && ((node[__KEY] = key) || true) && ((node[__PARENT] = nodeParent) || true) && ((node[__ROOT] = nodeRoot) || true) && (node[__GENERATION] || (node[__GENERATION] = ++__GENERATION_GUID) && node) && ((!nodeType || nodeType === SENTINEL) && Array.isArray(nodeValue) && (nodeValue[__CONTAINER] = node)) || node; sizeOffset = edgeSize - nodeSize; var self = nodeParent, child = node; while (node = nodeParent) { nodeParent = node[__PARENT]; if ((node[$SIZE] = (node[$SIZE] || 0) - sizeOffset) <= 0 && nodeParent) { var ref$4 = node[$TYPE] === SENTINEL ? node[VALUE] : node, destination$2; if (ref$4 && Array.isArray(ref$4)) { destination$2 = ref$4[__CONTEXT]; if (destination$2) { var i$4 = (ref$4[__REF_INDEX] || 0) - 1, n$3 = (destination$2[__REFS_LENGTH] || 0) - 1; while (++i$4 <= n$3) { destination$2[__REF + i$4] = destination$2[__REF + (i$4 + 1)]; } destination$2[__REFS_LENGTH] = n$3; ref$4[__REF_INDEX] = ref$4[__CONTEXT] = destination$2 = void 0; } } if (node != null && typeof node === 'object') { var ref$5, i$5 = -1, n$4 = node[__REFS_LENGTH] || 0; while (++i$5 < n$4) { if ((ref$5 = node[__REF + i$5]) !== void 0) { ref$5[__CONTEXT] = node[__REF + i$5] = void 0; } } node[__REFS_LENGTH] = void 0; var root$3 = root, head$2 = root$3.__head, tail$2 = root$3.__tail, next$2 = node.__next, prev$2 = node.__prev; next$2 != null && typeof next$2 === 'object' && (next$2.__prev = prev$2); prev$2 != null && typeof prev$2 === 'object' && (prev$2.__next = next$2); node === head$2 && (root$3.__head = root$3.__next = next$2); node === tail$2 && (root$3.__tail = root$3.__prev = prev$2); node.__next = node.__prev = void 0; head$2 = tail$2 = next$2 = prev$2 = void 0; ; nodeParent[node[__KEY]] = node[__SELF] = node[__PARENT] = node[__ROOT] = void 0; } } else if (node[__GENERATION_UPDATED] !== __GENERATION_VERSION) { var self$2 = node, stack$2 = [], depth$3 = 0, linkPaths, ref$6, i$6, k, n$5; while (depth$3 > -1) { if ((linkPaths = stack$2[depth$3]) === void 0) { i$6 = k = -1; n$5 = node[__REFS_LENGTH] || 0; node[__GENERATION_UPDATED] = __GENERATION_VERSION; node[__GENERATION] = ++__GENERATION_GUID; if ((ref$6 = node[__PARENT]) !== void 0 && ref$6[__GENERATION_UPDATED] !== __GENERATION_VERSION) { stack$2[depth$3] = linkPaths = new Array(n$5 + 1); linkPaths[++k] = ref$6; } else if (n$5 > 0) { stack$2[depth$3] = linkPaths = new Array(n$5); } while (++i$6 < n$5) { if ((ref$6 = node[__REF + i$6]) !== void 0 && ref$6[__GENERATION_UPDATED] !== __GENERATION_VERSION) { linkPaths[++k] = ref$6; } } } if ((node = linkPaths && linkPaths.pop()) !== void 0) { ++depth$3; } else { stack$2[depth$3--] = void 0; } } node = self$2; } } nodeParent = self; node = child; } ; node = node; break follow_path_map_9177; } } if ((key = keys[index]) == null) { node = node; break follow_path_map_9177; } else if (key === __NULL && ((key = null) || true) || !(!(key[0] !== '_' || key[1] !== '_') || (key === __SELF || key === __PARENT || key === __ROOT) || key[0] === '$') && ((mapStack[(depth + 1) * 4] = map[key]) || true)) { mapStack[(depth + 1) * 4 + 3] = key; } else { mapStack[offset + 2] = index + 1; node = node; depth = depth; continue follow_path_map_9177; } nodes[depth - 1] = nodeParent = node; if (key != null) { node = nodeParent && nodeParent[key]; if (typeof map === 'object') { for (var key$2 in map) { key$2[0] === '$' && key$2 !== $SIZE && (nodeParent && (nodeParent[key$2] = map[key$2]) || true); } map = map[key]; } var mapType = map && map[$TYPE] || void 0; var mapValue = mapType === SENTINEL ? map[VALUE] : map; if ((node == null || typeof node !== 'object' || !!nodeType && nodeType !== SENTINEL && !Array.isArray(nodeValue)) && (!mapType && (map != null && typeof map === 'object') && !Array.isArray(mapValue))) { nodeType = void 0; nodeValue = {}; nodeSize = node && node[$SIZE] || 0; if (node !== nodeValue && (node != null && typeof node === 'object')) { var nodeRefsLength$2 = node[__REFS_LENGTH] || 0, destRefsLength$2 = nodeValue[__REFS_LENGTH] || 0, i$7 = -1, ref$7; while (++i$7 < nodeRefsLength$2) { if ((ref$7 = node[__REF + i$7]) !== void 0) { ref$7[__CONTEXT] = nodeValue; nodeValue[__REF + (destRefsLength$2 + i$7)] = ref$7; node[__REF + i$7] = void 0; } } nodeValue[__REFS_LENGTH] = nodeRefsLength$2 + destRefsLength$2; node[__REFS_LENGTH] = ref$7 = void 0; var invParent$2 = nodeParent, invChild$2 = node, invKey$2 = key, keys$3, index$3, offset$3, childType$2, childValue$2, isBranch$2, stack$3 = [ nodeParent, invKey$2, node ], depth$4 = 0; while (depth$4 > -1) { nodeParent = stack$3[offset$3 = depth$4 * 8]; invKey$2 = stack$3[offset$3 + 1]; node = stack$3[offset$3 + 2]; if ((childType$2 = stack$3[offset$3 + 3]) === void 0 || (childType$2 = void 0)) { childType$2 = stack$3[offset$3 + 3] = node && node[$TYPE] || void 0 || null; } childValue$2 = stack$3[offset$3 + 4] || (stack$3[offset$3 + 4] = childType$2 === SENTINEL ? node[VALUE] : node); if ((isBranch$2 = stack$3[offset$3 + 5]) === void 0) { isBranch$2 = stack$3[offset$3 + 5] = !childType$2 && (node != null && typeof node === 'object') && !Array.isArray(childValue$2); } if (isBranch$2 === true) { if ((keys$3 = stack$3[offset$3 + 6]) === void 0) { keys$3 = stack$3[offset$3 + 6] = []; index$3 = -1; for (var childKey$2 in node) { !(!(childKey$2[0] !== '_' || childKey$2[1] !== '_') || (childKey$2 === __SELF || childKey$2 === __PARENT || childKey$2 === __ROOT) || childKey$2[0] === '$') && (keys$3[++index$3] = childKey$2); } } index$3 = stack$3[offset$3 + 7] || (stack$3[offset$3 + 7] = 0); if (index$3 < keys$3.length) { stack$3[offset$3 + 7] = index$3 + 1; stack$3[offset$3 = ++depth$4 * 8] = node; stack$3[offset$3 + 1] = invKey$2 = keys$3[index$3]; stack$3[offset$3 + 2] = node[invKey$2]; continue; } } var ref$8 = node[$TYPE] === SENTINEL ? node[VALUE] : node, destination$3; if (ref$8 && Array.isArray(ref$8)) { destination$3 = ref$8[__CONTEXT]; if (destination$3) { var i$8 = (ref$8[__REF_INDEX] || 0) - 1, n$6 = (destination$3[__REFS_LENGTH] || 0) - 1; while (++i$8 <= n$6) { destination$3[__REF + i$8] = destination$3[__REF + (i$8 + 1)]; } destination$3[__REFS_LENGTH] = n$6; ref$8[__REF_INDEX] = ref$8[__CONTEXT] = destination$3 = void 0; } } if (node != null && typeof node === 'object') { var ref$9, i$9 = -1, n$7 = node[__REFS_LENGTH] || 0; while (++i$9 < n$7) { if ((ref$9 = node[__REF + i$9]) !== void 0) { ref$9[__CONTEXT] = node[__REF + i$9] = void 0; } } node[__REFS_LENGTH] = void 0; var root$4 = root, head$3 = root$4.__head, tail$3 = root$4.__tail, next$3 = node.__next, prev$3 = node.__prev; next$3 != null && typeof next$3 === 'object' && (next$3.__prev = prev$3); prev$3 != null && typeof prev$3 === 'object' && (prev$3.__next = next$3); node === head$3 && (root$4.__head = root$4.__next = next$3); node === tail$3 && (root$4.__tail = root$4.__prev = prev$3); node.__next = node.__prev = void 0; head$3 = tail$3 = next$3 = prev$3 = void 0; ; nodeParent[invKey$2] = node[__SELF] = node[__PARENT] = node[__ROOT] = void 0; } ; delete stack$3[offset$3 + 0]; delete stack$3[offset$3 + 1]; delete stack$3[offset$3 + 2]; delete stack$3[offset$3 + 3]; delete stack$3[offset$3 + 4]; delete stack$3[offset$3 + 5]; delete stack$3[offset$3 + 6]; delete stack$3[offset$3 + 7]; --depth$4; } nodeParent = invParent$2; node = invChild$2; } nodeParent[key] = node = nodeValue; node = !node[__SELF] && ((node[__SELF] = node) || true) && ((node[__KEY] = key) || true) && ((node[__PARENT] = nodeParent) || true) && ((node[__ROOT] = nodeRoot) || true) && (node[__GENERATION] || (node[__GENERATION] = ++__GENERATION_GUID) && node) && ((!nodeType || nodeType === SENTINEL) && Array.isArray(nodeValue) && (nodeValue[__CONTAINER] = node)) || node; var self$3 = node, node$2; while (node$2 = node) { if (node[__GENERATION_UPDATED] !== __GENERATION_VERSION) { var self$4 = node, stack$4 = [], depth$5 = 0, linkPaths$2, ref$10, i$10, k$2, n$8; while (depth$5 > -1) { if ((linkPaths$2 = stack$4[depth$5]) === void 0) { i$10 = k$2 = -1; n$8 = node[__REFS_LENGTH] || 0; node[__GENERATION_UPDATED] = __GENERATION_VERSION; node[__GENERATION] = ++__GENERATION_GUID; if ((ref$10 = node[__PARENT]) !== void 0 && ref$10[__GENERATION_UPDATED] !== __GENERATION_VERSION) { stack$4[depth$5] = linkPaths$2 = new Array(n$8 + 1); linkPaths$2[++k$2] = ref$10; } else if (n$8 > 0) { stack$4[depth$5] = linkPaths$2 = new Array(n$8); } while (++i$10 < n$8) { if ((ref$10 = node[__REF + i$10]) !== void 0 && ref$10[__GENERATION_UPDATED] !== __GENERATION_VERSION) { linkPaths$2[++k$2] = ref$10; } } } if ((node = linkPaths$2 && linkPaths$2.pop()) !== void 0) { ++depth$5; } else { stack$4[depth$5--] = void 0; } } node = self$4; } node = node$2[__PARENT]; } node = self$3; } } node = node; depth = depth + 1; continue follow_path_map_9177; } while (true); node = node; var offset$4 = depth * 4, keys$4, index$4; do { delete mapStack[offset$4 + 0]; delete mapStack[offset$4 + 1]; delete mapStack[offset$4 + 2]; delete mapStack[offset$4 + 3]; } while ((keys$4 = mapStack[(offset$4 = 4 * --depth) + 1]) && ((index$4 = mapStack[offset$4 + 2]) || true) && (mapStack[offset$4 + 2] = ++index$4) >= keys$4.length); } return nodeRoot; } },{}],54:[function(_dereq_,module,exports){ var lru = _dereq_('./util/lru'); var clone = _dereq_('./util/clone'); var promote = lru.promote; module.exports = function onError(model, node, permuteRequested, permuteOptimized, outerResults) { outerResults.errors.push({path: permuteRequested, value: node.value}); promote(model, node); if (permuteOptimized) { outerResults.requestedPaths.push(permuteRequested); outerResults.optimizedPaths.push(permuteOptimized); } }; },{"./util/clone":57,"./util/lru":62}],55:[function(_dereq_,module,exports){ var support = _dereq_('./util/support'); var fastCat = support.fastCat, fastCatSkipNulls = support.fastCatSkipNulls, fastCopy = support.fastCopy; var isExpired = _dereq_('./util/isExpired'); var spreadJSON = _dereq_('./util/spreadJSON'); var clone = _dereq_('./util/clone'); module.exports = function onMissing(model, node, path, depth, seedOrFunction, outerResults, permuteRequested, permuteOptimized, permutePosition, outputFormat) { var pathSlice; if (Array.isArray(path)) { if (depth < path.length) { pathSlice = fastCopy(path, depth); } else { pathSlice = []; } concatAndInsertMissing(pathSlice, outerResults, permuteRequested, permuteOptimized, permutePosition, outputFormat); } else { pathSlice = []; spreadJSON(path, pathSlice); for (var i = 0, len = pathSlice.length; i < len; i++) { concatAndInsertMissing(pathSlice[i], outerResults, permuteRequested, permuteOptimized, permutePosition, outputFormat, true); } } }; function concatAndInsertMissing(remainingPath, results, permuteRequested, permuteOptimized, permutePosition, outputFormat, __null) { var i = 0, len; if (__null) { for (i = 0, len = remainingPath.length; i < len; i++) { if (remainingPath[i] === '__null') { remainingPath[i] = null; } } } if (outputFormat === 'JSON') { permuteRequested = fastCat(permuteRequested, remainingPath); for (i = 0, len = permutePosition.length; i < len; i++) { var idx = permutePosition[i]; var r = permuteRequested[idx]; permuteRequested[idx] = [r]; } results.requestedMissingPaths.push(permuteRequested); results.optimizedMissingPaths.push(fastCatSkipNulls(permuteOptimized, remainingPath)); } else { results.requestedMissingPaths.push(fastCat(permuteRequested, remainingPath)); results.optimizedMissingPaths.push(fastCatSkipNulls(permuteOptimized, remainingPath)); } } },{"./util/clone":57,"./util/isExpired":59,"./util/spreadJSON":64,"./util/support":65}],56:[function(_dereq_,module,exports){ var lru = _dereq_('./util/lru'); var clone = _dereq_('./util/clone'); var promote = lru.promote; var $path = _dereq_('./../types/path'); var $sentinel = _dereq_('./../types/sentinel'); var $error = _dereq_('./../types/error'); module.exports = function onValue(model, node, seedOrFunction, outerResults, permuteRequested, permuteOptimized, permutePosition, outputFormat, fromReference) { var i, len, k, key, curr, prev, prevK; var materialized = false, valueNode; if (node) { promote(model, node); } if (!node || node.value === undefined) { materialized = model._materialized; } // materialized if (materialized) { valueNode = {$type: $sentinel}; } // Boxed Mode & Reference Node & Error node (only happens when model is in treat errors as values). else if (model._boxed) { valueNode = clone(node); } else if (node.$type === $path || node.$type === $error) { if (outputFormat === 'JSONG') { valueNode = clone(node); } else { valueNode = node.value; } } else { if (outputFormat === 'JSONG') { if (typeof node.value === 'object') { valueNode = clone(node); } else { valueNode = node.value; } } else { valueNode = node.value; } } if (permuteRequested) { if (fromReference && permuteRequested[permuteRequested.length - 1] !== null) { permuteRequested.push(null); } outerResults.requestedPaths.push(permuteRequested); outerResults.optimizedPaths.push(permuteOptimized); } switch (outputFormat) { case 'Values': // in any subscription situation, onNexts are always provided, even as a noOp. seedOrFunction({path: permuteRequested, value: valueNode}); break; case 'PathMap': len = permuteRequested.length - 1; if (len === -1) { seedOrFunction.json = valueNode; } else { curr = seedOrFunction.json; if (!curr) { curr = seedOrFunction.json = {}; } for (i = 0; i < len; i++) { k = permuteRequested[i]; if (!curr[k]) { curr[k] = {}; } prev = curr; prevK = k; curr = curr[k]; } k = permuteRequested[i]; if (k !== null) { curr[k] = valueNode; } else { prev[prevK] = valueNode; } } break; case 'JSON': if (seedOrFunction) { if (permutePosition.length) { if (!seedOrFunction.json) { seedOrFunction.json = {}; } curr = seedOrFunction.json; for (i = 0, len = permutePosition.length - 1; i < len; i++) { k = permutePosition[i]; key = permuteRequested[k]; if (!curr[key]) { curr[key] = {}; } curr = curr[key]; } // assign the last k = permutePosition[i]; key = permuteRequested[k]; curr[key] = valueNode; } else { seedOrFunction.json = valueNode; } } break; case 'JSONG': curr = seedOrFunction.jsong; if (!curr) { curr = seedOrFunction.jsong = {}; seedOrFunction.paths = []; } for (i = 0, len = permuteOptimized.length - 1; i < len; i++) { key = permuteOptimized[i]; if (!curr[key]) { curr[key] = {}; } curr = curr[key]; } // assign the last key = permuteOptimized[i]; // TODO: Special case? do string comparisons make big difference? curr[key] = materialized ? {$type: $sentinel} : valueNode; if (permuteRequested) { seedOrFunction.paths.push(permuteRequested); } break; } }; },{"./../types/error":139,"./../types/path":140,"./../types/sentinel":141,"./util/clone":57,"./util/lru":62}],57:[function(_dereq_,module,exports){ // Copies the node var prefix = _dereq_("../../internal/prefix"); module.exports = function clone(node) { var outValue, i, len; var keys = Object.keys(node); outValue = {}; for (i = 0, len = keys.length; i < len; i++) { var k = keys[i]; if (k[0] === prefix) { continue; } outValue[k] = node[k]; } return outValue; }; },{"../../internal/prefix":74}],58:[function(_dereq_,module,exports){ var __ref = _dereq_("../../internal/ref"); var __context = _dereq_("../../internal/context"); var __ref_index = _dereq_("../../internal/ref-index"); var __refs_length = _dereq_("../../internal/refs-length"); function createHardlink(from, to) { // create a back reference var backRefs = to[__refs_length] || 0; to[__ref + backRefs] = from; to[__refs_length] = backRefs + 1; // create a hard reference from[__ref_index] = backRefs; from[__context] = to; } function removeHardlink(cacheObject) { var context = cacheObject[__context]; if (context) { var idx = cacheObject[__ref_index]; var len = context[__refs_length]; while (idx < len) { context[__ref + idx] = context[__REF + idx + 1]; ++idx; } context[__refs_length] = len - 1; cacheObject[__context] = undefined; cacheObject[__ref_index] = undefined; } } module.exports = { create: createHardlink, remove: removeHardlink }; },{"../../internal/context":66,"../../internal/ref":77,"../../internal/ref-index":76,"../../internal/refs-length":78}],59:[function(_dereq_,module,exports){ var now = _dereq_('../../support/now'); module.exports = function isExpired(node) { var $expires = node.$expires === undefined && -1 || node.$expires; return $expires !== -1 && $expires !== 1 && ($expires === 0 || $expires < now()); }; },{"../../support/now":126}],60:[function(_dereq_,module,exports){ module.exports = function isMaterialized(model) { return model._materialized && !(model._router || model._dataSource); }; },{}],61:[function(_dereq_,module,exports){ module.exports = function(x) { return x.path && x.value; }; },{}],62:[function(_dereq_,module,exports){ var __head = _dereq_("../../internal/head"); var __tail = _dereq_("../../internal/tail"); var __next = _dereq_("../../internal/next"); var __prev = _dereq_("../../internal/prev"); var __invalidated = _dereq_("../../internal/invalidated"); // [H] -> Next -> ... -> [T] // [T] -> Prev -> ... -> [H] function lruPromote(model, object) { var root = model._root; var head = root[__head]; if (head === object) { return; } // First insert if (!head) { root[__head] = object; return; } // The head and the tail need to separate if (!root[__tail]) { root[__head] = object; root[__tail] = head; object[__next] = head; // Now tail head[__prev] = object; return; } // Its in the cache. Splice out. var prev = object[__prev]; var next = object[__next]; if (next) { next[__prev] = prev; } if (prev) { prev[__next] = next; } object[__prev] = undefined; // Insert into head position root[__head] = object; object[__next] = head; head[__prev] = object; } function lruSplice(model, object) { var root = model._root; // Its in the cache. Splice out. var prev = object[__prev]; var next = object[__next]; if (next) { next[__prev] = prev; } if (prev) { prev[__next] = next; } object[__prev] = undefined; if (object === root[__head]) { root[__head] = undefined; } if (object === root[__tail]) { root[__tail] = undefined; } object[__invalidated] = true; root.expired.push(object); } module.exports = { promote: lruPromote, splice: lruSplice }; },{"../../internal/head":68,"../../internal/invalidated":69,"../../internal/next":71,"../../internal/prev":75,"../../internal/tail":79}],63:[function(_dereq_,module,exports){ var prefix = _dereq_("../../internal/prefix"); module.exports = function permuteKey(key, memo) { if (memo.isArray) { if (memo.loaded && memo.rangeOffset > memo.to) { memo.arrOffset++; memo.loaded = false; } var idx = memo.arrOffset, length = key.length; if (idx === length) { memo.done = true; return ''; } var el = key[memo.arrOffset]; var type = typeof el; if (type === 'object') { if (!memo.loaded) { memo.from = el.from || 0; memo.to = el.to || el.length && memo.from + el.length - 1 || 0; memo.rangeOffset = memo.from; memo.loaded = true; } return memo.rangeOffset++; } else { do { if (type !== 'string') { break; } if (el[0] !== prefix && el[0] !== '$') { break; } el = key[++idx]; } while (el === undefined || idx < length); if (el === undefined || idx === length) { memo.done = true; return ''; } memo.arrOffset = idx + 1; return el; } } else { if (!memo.loaded) { memo.from = key.from || 0; memo.to = key.to || key.length && memo.from + key.length - 1 || 0; memo.rangeOffset = memo.from; memo.loaded = true; } if (memo.rangeOffset > memo.to) { memo.done = true; return ''; } return memo.rangeOffset++; } }; },{"../../internal/prefix":74}],64:[function(_dereq_,module,exports){ var fastCopy = _dereq_('./support').fastCopy; module.exports = function spreadJSON(root, bins, bin) { bin = bin || []; if (!bins.length) { bins.push(bin); } if (!root || typeof root !== 'object' || root.$type) { return []; } var keys = Object.keys(root); if (keys.length === 1) { bin.push(keys[0]); spreadJSON(root[keys[0]], bins, bin); } else { for (var i = 0, len = keys.length; i < len; i++) { var k = keys[i]; var nextBin = fastCopy(bin); nextBin.push(k); bins.push(nextBin); spreadJSON(root[k], bins, nextBin); } } }; },{"./support":65}],65:[function(_dereq_,module,exports){ function fastCopy(arr, i) { var a = [], len, j; for (j = 0, i = i || 0, len = arr.length; i < len; j++, i++) { a[j] = arr[i]; } return a; } function fastCatSkipNulls(arr1, arr2) { var a = [], i, len, j; for (i = 0, len = arr1.length; i < len; i++) { a[i] = arr1[i]; } for (j = 0, len = arr2.length; j < len; j++) { if (arr2[j] !== null) { a[i++] = arr2[j]; } } return a; } function fastCat(arr1, arr2) { var a = [], i, len, j; for (i = 0, len = arr1.length; i < len; i++) { a[i] = arr1[i]; } for (j = 0, len = arr2.length; j < len; j++) { a[i++] = arr2[j]; } return a; } module.exports = { fastCat: fastCat, fastCatSkipNulls: fastCatSkipNulls, fastCopy: fastCopy }; },{}],66:[function(_dereq_,module,exports){ module.exports = _dereq_("./prefix") + "context"; },{"./prefix":74}],67:[function(_dereq_,module,exports){ module.exports = _dereq_("./prefix") + "generation"; },{"./prefix":74}],68:[function(_dereq_,module,exports){ module.exports = _dereq_("./prefix") + "head"; },{"./prefix":74}],69:[function(_dereq_,module,exports){ module.exports = _dereq_("./prefix") + "invalidated"; },{"./prefix":74}],70:[function(_dereq_,module,exports){ module.exports = _dereq_("./prefix") + "key"; },{"./prefix":74}],71:[function(_dereq_,module,exports){ module.exports = _dereq_("./prefix") + "next"; },{"./prefix":74}],72:[function(_dereq_,module,exports){ module.exports = _dereq_("./prefix") + "offset"; },{"./prefix":74}],73:[function(_dereq_,module,exports){ module.exports = _dereq_("./prefix") + "parent"; },{"./prefix":74}],74:[function(_dereq_,module,exports){ // This may look like an empty string, but it's actually a single zero-width-space character. module.exports = "​"; },{}],75:[function(_dereq_,module,exports){ module.exports = _dereq_("./prefix") + "prev"; },{"./prefix":74}],76:[function(_dereq_,module,exports){ module.exports = _dereq_("./prefix") + "ref-index"; },{"./prefix":74}],77:[function(_dereq_,module,exports){ module.exports = _dereq_("./prefix") + "ref"; },{"./prefix":74}],78:[function(_dereq_,module,exports){ module.exports = _dereq_("./prefix") + "refs-length"; },{"./prefix":74}],79:[function(_dereq_,module,exports){ module.exports = _dereq_("./prefix") + "tail"; },{"./prefix":74}],80:[function(_dereq_,module,exports){ module.exports = _dereq_("./prefix") + "version"; },{"./prefix":74}],81:[function(_dereq_,module,exports){ module.exports = { invPathSetsAsJSON: _dereq_("./invalidate-path-sets-as-json-dense"), invPathSetsAsJSONG: _dereq_("./invalidate-path-sets-as-json-graph"), invPathSetsAsPathMap: _dereq_("./invalidate-path-sets-as-json-sparse"), invPathSetsAsValues: _dereq_("./invalidate-path-sets-as-json-values") }; },{"./invalidate-path-sets-as-json-dense":82,"./invalidate-path-sets-as-json-graph":83,"./invalidate-path-sets-as-json-sparse":84,"./invalidate-path-sets-as-json-values":85}],82:[function(_dereq_,module,exports){ module.exports = invalidate_path_sets_as_json_dense; var clone = _dereq_("../support/clone-dense-json"); var array_clone = _dereq_("../support/array-clone"); var array_slice = _dereq_("../support/array-slice"); var options = _dereq_("../support/options"); var walk_path_set = _dereq_("../walk/walk-path-set"); var is_object = _dereq_("../support/is-object"); var get_valid_key = _dereq_("../support/get-valid-key"); var update_graph = _dereq_("../support/update-graph"); var invalidate_node = _dereq_("../support/invalidate-node"); var collect = _dereq_("../lru/collect"); function invalidate_path_sets_as_json_dense(model, pathsets, values) { var roots = options([], model); var index = -1; var count = pathsets.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var json, hasValue; roots[0] = roots.root; while (++index < count) { json = values && values[index]; if (is_object(json)) { roots[3] = parents[3] = nodes[3] = json.json || (json.json = {}) } else { roots[3] = parents[3] = nodes[3] = undefined; } var pathset = pathsets[index]; roots.index = index; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); if (is_object(json)) { json.json = roots.json; } delete roots.json; } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, hasValue: true, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, json; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } json = parents[3]; parent = parents[0]; } else { json = is_keyset && nodes[3] || parents[3]; parent = nodes[0]; } var node = parent[key]; if (!is_top_level) { parents[0] = parent; nodes[0] = node; return; } if (is_branch) { parents[0] = nodes[0] = node; if (is_keyset && !!(parents[3] = json)) { nodes[3] = json[keyset] || (json[keyset] = {}); } return; } nodes[0] = node; if (!!json) { var type = is_object(node) && node.$type || undefined; var jsonkey = keyset; if (jsonkey == null) { json = roots; jsonkey = 3; } json[jsonkey] = clone(roots, node, type, node && node.value); } var lru = roots.lru; var size = node.$size || 0; var version = roots.version; invalidate_node(parent, node, key, roots.lru); update_graph(parent, size, version, lru); } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { roots.json = roots[3]; roots.hasValue = true; roots.requestedPaths.push(array_slice(requested, roots.offset)); } },{"../lru/collect":86,"../support/array-clone":104,"../support/array-slice":105,"../support/clone-dense-json":106,"../support/get-valid-key":116,"../support/invalidate-node":120,"../support/is-object":122,"../support/options":127,"../support/update-graph":137,"../walk/walk-path-set":147}],83:[function(_dereq_,module,exports){ module.exports = invalidate_path_sets_as_json_graph; var $path = _dereq_("../types/path"); var clone = _dereq_("../support/clone-dense-json"); var array_clone = _dereq_("../support/array-clone"); var options = _dereq_("../support/options"); var walk_path_set = _dereq_("../walk/walk-path-set-soft-link"); var is_object = _dereq_("../support/is-object"); var get_valid_key = _dereq_("../support/get-valid-key"); var update_graph = _dereq_("../support/update-graph"); var invalidate_node = _dereq_("../support/invalidate-node"); var clone_success = _dereq_("../support/clone-success-paths"); var collect = _dereq_("../lru/collect"); function invalidate_path_sets_as_json_graph(model, pathsets, values) { var roots = options([], model); var index = -1; var count = pathsets.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var json = values[0]; roots[0] = roots.root; roots[1] = parents[1] = nodes[1] = json.jsong || (json.jsong = {}); roots.requestedPaths = json.paths || (json.paths = roots.requestedPaths); while (++index < count) { var pathset = pathsets[index]; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, hasValue: true, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, json; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } json = parents[1]; parent = parents[0]; } else { json = nodes[1]; parent = nodes[0]; } var jsonkey = key; var node = parent[key]; if (!is_top_level) { parents[0] = parent; nodes[0] = node; parents[1] = json; nodes[1] = json[jsonkey] || (json[jsonkey] = {}); return; } var type = is_object(node) && node.$type || undefined; if (is_branch) { parents[0] = nodes[0] = node; parents[1] = json; if (type == $path) { json[jsonkey] = clone(roots, node, type, node.value); } else { nodes[1] = json[jsonkey] || (json[jsonkey] = {}); } return; } nodes[0] = node; json[jsonkey] = clone(roots, node, type, node && node.value); var lru = roots.lru; var size = node.$size || 0; var version = roots.version; invalidate_node(parent, node, key, roots.lru); update_graph(parent, size, version, lru); } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { clone_success(roots, requested, optimized); roots.json = roots[1]; roots.hasValue = true; } },{"../lru/collect":86,"../support/array-clone":104,"../support/clone-dense-json":106,"../support/clone-success-paths":112,"../support/get-valid-key":116,"../support/invalidate-node":120,"../support/is-object":122,"../support/options":127,"../support/update-graph":137,"../types/path":140,"../walk/walk-path-set-soft-link":146}],84:[function(_dereq_,module,exports){ module.exports = invalidate_path_sets_as_json_sparse; var clone = _dereq_("../support/clone-dense-json"); var array_clone = _dereq_("../support/array-clone"); var array_slice = _dereq_("../support/array-slice"); var options = _dereq_("../support/options"); var walk_path_set = _dereq_("../walk/walk-path-set"); var is_object = _dereq_("../support/is-object"); var get_valid_key = _dereq_("../support/get-valid-key"); var update_graph = _dereq_("../support/update-graph"); var invalidate_node = _dereq_("../support/invalidate-node"); var collect = _dereq_("../lru/collect"); function invalidate_path_sets_as_json_sparse(model, pathsets, values) { var roots = options([], model); var index = -1; var count = pathsets.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var json = values[0]; roots[0] = roots.root; roots[3] = parents[3] = nodes[3] = json.json || (json.json = {}); while (++index < count) { var pathset = pathsets[index]; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, hasValue: true, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, json, jsonkey; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } jsonkey = get_valid_key(requested); json = parents[3]; parent = parents[0]; } else { jsonkey = key; json = nodes[3]; parent = nodes[0]; } var node = parent[key]; if (!is_top_level) { parents[0] = parent; nodes[0] = node; return; } if (is_branch) { parents[0] = nodes[0] = node; parents[3] = json; nodes[3] = json[jsonkey] || (json[jsonkey] = {}); return; } nodes[0] = node; var type = is_object(node) && node.$type || undefined; json[jsonkey] = clone(roots, node, type, node && node.value); var lru = roots.lru; var size = node.$size || 0; var version = roots.version; invalidate_node(parent, node, key, roots.lru); update_graph(parent, size, version, lru); } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { roots.json = roots[3]; roots.hasValue = true; roots.requestedPaths.push(array_slice(requested, roots.offset)); } },{"../lru/collect":86,"../support/array-clone":104,"../support/array-slice":105,"../support/clone-dense-json":106,"../support/get-valid-key":116,"../support/invalidate-node":120,"../support/is-object":122,"../support/options":127,"../support/update-graph":137,"../walk/walk-path-set":147}],85:[function(_dereq_,module,exports){ module.exports = invalidate_path_sets_as_json_values; var clone = _dereq_("../support/clone-dense-json"); var array_clone = _dereq_("../support/array-clone"); var array_slice = _dereq_("../support/array-slice"); var options = _dereq_("../support/options"); var walk_path_set = _dereq_("../walk/walk-path-set"); var is_object = _dereq_("../support/is-object"); var get_valid_key = _dereq_("../support/get-valid-key"); var update_graph = _dereq_("../support/update-graph"); var invalidate_node = _dereq_("../support/invalidate-node"); var collect = _dereq_("../lru/collect"); function invalidate_path_sets_as_json_values(model, pathsets, onNext) { var roots = options([], model); var index = -1; var count = pathsets.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; roots[0] = roots.root; roots.onNext = onNext; while (++index < count) { var pathset = pathsets[index]; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: null, errors: roots.errors, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } parent = parents[0]; } else { parent = nodes[0]; } var node = parent[key]; if (!is_top_level) { parents[0] = parent; nodes[0] = node; return; } if (is_branch) { parents[0] = nodes[0] = node; return; } nodes[0] = node; var lru = roots.lru; var size = node.$size || 0; var version = roots.version; invalidate_node(parent, node, key, roots.lru); update_graph(parent, size, version, lru); } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { var node = nodes[0]; var type = is_object(node) && node.$type || undefined; var onNext = roots.onNext; if (!!type && onNext) { onNext({ path: array_clone(requested), value: clone(roots, node, type, node && node.value) }); } roots.requestedPaths.push(array_slice(requested, roots.offset)); } },{"../lru/collect":86,"../support/array-clone":104,"../support/array-slice":105,"../support/clone-dense-json":106,"../support/get-valid-key":116,"../support/invalidate-node":120,"../support/is-object":122,"../support/options":127,"../support/update-graph":137,"../walk/walk-path-set":147}],86:[function(_dereq_,module,exports){ var __head = _dereq_("../internal/head"); var __tail = _dereq_("../internal/tail"); var __next = _dereq_("../internal/next"); var __prev = _dereq_("../internal/prev"); var update_graph = _dereq_("../support/update-graph"); module.exports = function(lru, expired, version, total, max, ratio) { var targetSize = max * ratio; var node, size; while(!!(node = expired.pop())) { size = node.$size || 0; total -= size; update_graph(node, size, version, lru); } if(total >= max) { var prev = lru[__tail]; while((total >= targetSize) && !!(node = prev)) { prev = prev[__prev]; size = node.$size || 0; total -= size; update_graph(node, size, version, lru); } if((lru[__tail] = lru[__prev] = prev) == null) { lru[__head] = lru[__next] = undefined; } else { prev[__next] = undefined; } } }; },{"../internal/head":68,"../internal/next":71,"../internal/prev":75,"../internal/tail":79,"../support/update-graph":137}],87:[function(_dereq_,module,exports){ var $expires_never = _dereq_("../values/expires-never"); var __head = _dereq_("../internal/head"); var __tail = _dereq_("../internal/tail"); var __next = _dereq_("../internal/next"); var __prev = _dereq_("../internal/prev"); var is_object = _dereq_("../support/is-object"); module.exports = function(root, node) { if(is_object(node) && (node.$expires !== $expires_never)) { var head = root[__head], tail = root[__tail], next = node[__next], prev = node[__prev]; if (node !== head) { (next != null && typeof next === "object") && (next[__prev] = prev); (prev != null && typeof prev === "object") && (prev[__next] = next); (next = head) && (head != null && typeof head === "object") && (head[__prev] = node); (root[__head] = root[__next] = head = node); (head[__next] = next); (head[__prev] = undefined); } if (tail == null || node === tail) { root[__tail] = root[__prev] = tail = prev || node; } } return node; }; },{"../internal/head":68,"../internal/next":71,"../internal/prev":75,"../internal/tail":79,"../support/is-object":122,"../values/expires-never":142}],88:[function(_dereq_,module,exports){ var __head = _dereq_("../internal/head"); var __tail = _dereq_("../internal/tail"); var __next = _dereq_("../internal/next"); var __prev = _dereq_("../internal/prev"); module.exports = function(root, node) { var head = root[__head], tail = root[__tail], next = node[__next], prev = node[__prev]; (next != null && typeof next === "object") && (next[__prev] = prev); (prev != null && typeof prev === "object") && (prev[__next] = next); (node === head) && (root[__head] = root[__next] = next); (node === tail) && (root[__tail] = root[__prev] = prev); node[__next] = node[__prev] = undefined; head = tail = next = prev = undefined; }; },{"../internal/head":68,"../internal/next":71,"../internal/prev":75,"../internal/tail":79}],89:[function(_dereq_,module,exports){ module.exports = { setPathSetsAsJSON: _dereq_('./set-json-values-as-json-dense'), setPathSetsAsJSONG: _dereq_('./set-json-values-as-json-graph'), setPathSetsAsPathMap: _dereq_('./set-json-values-as-json-sparse'), setPathSetsAsValues: _dereq_('./set-json-values-as-json-values'), setPathMapsAsJSON: _dereq_('./set-json-sparse-as-json-dense'), setPathMapsAsJSONG: _dereq_('./set-json-sparse-as-json-graph'), setPathMapsAsPathMap: _dereq_('./set-json-sparse-as-json-sparse'), setPathMapsAsValues: _dereq_('./set-json-sparse-as-json-values'), setJSONGsAsJSON: _dereq_('./set-json-graph-as-json-dense'), setJSONGsAsJSONG: _dereq_('./set-json-graph-as-json-graph'), setJSONGsAsPathMap: _dereq_('./set-json-graph-as-json-sparse'), setJSONGsAsValues: _dereq_('./set-json-graph-as-json-values'), setCache: _dereq_('./set-cache') }; },{"./set-cache":90,"./set-json-graph-as-json-dense":91,"./set-json-graph-as-json-graph":92,"./set-json-graph-as-json-sparse":93,"./set-json-graph-as-json-values":94,"./set-json-sparse-as-json-dense":95,"./set-json-sparse-as-json-graph":96,"./set-json-sparse-as-json-sparse":97,"./set-json-sparse-as-json-values":98,"./set-json-values-as-json-dense":99,"./set-json-values-as-json-graph":100,"./set-json-values-as-json-sparse":101,"./set-json-values-as-json-values":102}],90:[function(_dereq_,module,exports){ module.exports = set_cache; var $error = _dereq_("../types/error"); var $sentinel = _dereq_("../types/sentinel"); var clone = _dereq_("../support/clone-dense-json"); var array_clone = _dereq_("../support/array-clone"); var options = _dereq_("../support/options"); var walk_path_map = _dereq_("../walk/walk-path-map"); var is_object = _dereq_("../support/is-object"); var get_valid_key = _dereq_("../support/get-valid-key"); var create_branch = _dereq_("../support/create-branch"); var wrap_node = _dereq_("../support/wrap-node"); var replace_node = _dereq_("../support/replace-node"); var graph_node = _dereq_("../support/graph-node"); var update_back_refs = _dereq_("../support/update-back-refs"); var update_graph = _dereq_("../support/update-graph"); var inc_generation = _dereq_("../support/inc-generation"); var collect = _dereq_("../lru/collect"); function set_cache(model, pathmap, error_selector) { var roots = options([], model, error_selector); var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var keys_stack = []; roots[0] = roots.root; walk_path_map(onNode, onEdge, pathmap, keys_stack, 0, roots, parents, nodes, requested, optimized); collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return model; } function onNode(pathmap, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } parent = parents[0]; } else { parent = nodes[0]; } var node = parent[key], type; if (is_branch) { type = is_object(node) && node.$type || undefined; node = create_branch(roots, parent, node, type, key); parents[0] = nodes[0] = node; return; } var selector = roots.error_selector; var root = roots[0]; var size = is_object(node) && node.$size || 0; var mess = pathmap; type = is_object(mess) && mess.$type || undefined; mess = wrap_node(mess, type, !!type ? mess.value : mess); type || (type = $sentinel); if (type == $error && !!selector) { mess = selector(requested, mess); } node = replace_node(parent, node, mess, key, roots.lru); node = graph_node(root, parent, node, key, inc_generation()); update_graph(parent, size - node.$size, roots.version, roots.lru); nodes[0] = node; } function onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset) { } },{"../lru/collect":86,"../support/array-clone":104,"../support/clone-dense-json":106,"../support/create-branch":114,"../support/get-valid-key":116,"../support/graph-node":117,"../support/inc-generation":118,"../support/is-object":122,"../support/options":127,"../support/replace-node":130,"../support/update-back-refs":136,"../support/update-graph":137,"../support/wrap-node":138,"../types/error":139,"../types/sentinel":141,"../walk/walk-path-map":145}],91:[function(_dereq_,module,exports){ module.exports = set_json_graph_as_json_dense; var $path = _dereq_("../types/path"); var clone = _dereq_("../support/clone-dense-json"); var array_clone = _dereq_("../support/array-clone"); var options = _dereq_("../support/options"); var walk_path_set = _dereq_("../walk/walk-path-set-soft-link"); var is_object = _dereq_("../support/is-object"); var get_valid_key = _dereq_("../support/get-valid-key"); var merge_node = _dereq_("../support/merge-node"); var node_as_miss = _dereq_("../support/treat-node-as-missing-path-set"); var node_as_error = _dereq_("../support/treat-node-as-error"); var clone_success = _dereq_("../support/clone-success-paths"); var collect = _dereq_("../lru/collect"); function set_json_graph_as_json_dense(model, envelopes, values, error_selector) { var roots = []; roots.offset = model._path.length; roots.bound = []; roots = options(roots, model, error_selector); var index = -1; var index2 = -1; var count = envelopes.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var json, hasValue, hasValues; roots[0] = roots.root; while (++index < count) { var envelope = envelopes[index]; var pathsets = envelope.paths; var jsong = envelope.jsong || envelope.values || envelope.value; var index3 = -1; var count2 = pathsets.length; roots[2] = jsong; nodes[2] = jsong; while (++index3 < count2) { json = values && values[++index2]; if (is_object(json)) { roots.json = roots[3] = parents[3] = nodes[3] = json.json || (json.json = {}); } else { roots.json = roots[3] = parents[3] = nodes[3] = undefined; } var pathset = pathsets[index3]; roots.index = index3; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); hasValue = roots.hasValue; if (!!hasValue) { hasValues = true; if (is_object(json)) { json.json = roots.json; } delete roots.json; delete roots.hasValue; } else if (is_object(json)) { delete json.json; } } } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, messageParent, json; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } json = parents[3]; parent = parents[0]; messageParent = parents[2]; } else { json = is_keyset && nodes[3] || parents[3]; parent = nodes[0]; messageParent = nodes[2]; } var node = parent[key]; var message = messageParent && messageParent[key]; nodes[2] = message; nodes[0] = node = merge_node(roots, parent, node, messageParent, message, key); if (!is_top_level) { parents[0] = parent; parents[2] = messageParent; return; } var length = requested.length; var offset = roots.offset; parents[3] = json; if (is_branch) { parents[0] = node; parents[2] = message; if ((length > offset) && is_keyset && !!json) { nodes[3] = json[keyset] || (json[keyset] = {}); } } } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { var json; var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathset, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); if (node_as_error(roots, node, type, requested) === false) { if(keyset == null) { roots.json = clone(roots, node, type, node && node.value); } else if(!!(json = parents[3])) { json[keyset] = clone(roots, node, type, node && node.value); } roots.hasValue = true; } } } },{"../lru/collect":86,"../support/array-clone":104,"../support/clone-dense-json":106,"../support/clone-success-paths":112,"../support/get-valid-key":116,"../support/is-object":122,"../support/merge-node":125,"../support/options":127,"../support/treat-node-as-error":132,"../support/treat-node-as-missing-path-set":134,"../types/path":140,"../walk/walk-path-set-soft-link":146}],92:[function(_dereq_,module,exports){ module.exports = set_json_graph_as_json_graph; var $path = _dereq_("../types/path"); var clone = _dereq_("../support/clone-graph-json"); var array_clone = _dereq_("../support/array-clone"); var options = _dereq_("../support/options"); var walk_path_set = _dereq_("../walk/walk-path-set-soft-link"); var is_object = _dereq_("../support/is-object"); var get_valid_key = _dereq_("../support/get-valid-key"); var merge_node = _dereq_("../support/merge-node"); var node_as_miss = _dereq_("../support/treat-node-as-missing-path-set"); var node_as_error = _dereq_("../support/treat-node-as-error"); var clone_success = _dereq_("../support/clone-success-paths"); var promote = _dereq_("../lru/promote"); var collect = _dereq_("../lru/collect"); function set_json_graph_as_json_graph(model, envelopes, values, error_selector) { var roots = []; roots.offset = 0; roots.bound = []; roots = options(roots, model, error_selector); var index = -1; var count = envelopes.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var json = values[0]; var hasValue; roots[0] = roots.root; roots[1] = parents[1] = nodes[1] = json.jsong || (json.jsong = {}); roots.requestedPaths = json.paths || (json.paths = roots.requestedPaths); while (++index < count) { var envelope = envelopes[index]; var pathsets = envelope.paths; var jsong = envelope.jsong || envelope.values || envelope.value; var index2 = -1; var count2 = pathsets.length; roots[2] = jsong; nodes[2] = jsong; while (++index2 < count2) { var pathset = pathsets[index2]; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); } } hasValue = roots.hasValue; if(hasValue) { json.jsong = roots[1]; } else { delete json.jsong; delete json.paths; } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, messageParent, json, jsonkey; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } json = parents[1]; parent = parents[0]; messageParent = parents[2]; } else { json = nodes[1]; parent = nodes[0]; messageParent = nodes[2]; } var jsonkey = key; var node = parent[key]; var message = messageParent && messageParent[key]; nodes[2] = message; nodes[0] = node = merge_node(roots, parent, node, messageParent, message, key); if (!is_top_level) { parents[0] = parent; parents[2] = messageParent; parents[1] = json; nodes[1] = json[jsonkey] || (json[jsonkey] = {}); return; } var type = is_object(node) && node.$type || undefined; if (is_branch) { parents[0] = node; parents[2] = message; parents[1] = json; if (type == $path) { json[jsonkey] = clone(roots, node, type, node.value); roots.hasValue = true; } else { nodes[1] = json[jsonkey] || (json[jsonkey] = {}); } return; } json[jsonkey] = clone(roots, node, type, node && node.value); roots.hasValue = true; } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { var json; var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathset, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); promote(roots.lru, node); if (keyset == null && !roots.hasValue && (keyset = get_valid_key(optimized)) == null) { node = clone(roots, node, type, node && node.value); json = roots[1]; json.$type = node.$type; json.value = node.value; } roots.hasValue = true; } } },{"../lru/collect":86,"../lru/promote":87,"../support/array-clone":104,"../support/clone-graph-json":107,"../support/clone-success-paths":112,"../support/get-valid-key":116,"../support/is-object":122,"../support/merge-node":125,"../support/options":127,"../support/treat-node-as-error":132,"../support/treat-node-as-missing-path-set":134,"../types/path":140,"../walk/walk-path-set-soft-link":146}],93:[function(_dereq_,module,exports){ module.exports = set_json_graph_as_json_sparse; var $path = _dereq_("../types/path"); var clone = _dereq_("../support/clone-dense-json"); var array_clone = _dereq_("../support/array-clone"); var options = _dereq_("../support/options"); var walk_path_set = _dereq_("../walk/walk-path-set-soft-link"); var is_object = _dereq_("../support/is-object"); var get_valid_key = _dereq_("../support/get-valid-key"); var merge_node = _dereq_("../support/merge-node"); var node_as_miss = _dereq_("../support/treat-node-as-missing-path-set"); var node_as_error = _dereq_("../support/treat-node-as-error"); var clone_success = _dereq_("../support/clone-success-paths"); var collect = _dereq_("../lru/collect"); function set_json_graph_as_json_sparse(model, envelopes, values, error_selector) { var roots = []; roots.offset = model._path.length; roots.bound = []; roots = options(roots, model, error_selector); var index = -1; var count = envelopes.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var json = values[0]; var hasValue; roots[0] = roots.root; roots[3] = parents[3] = nodes[3] = json.json || (json.json = {}); while (++index < count) { var envelope = envelopes[index]; var pathsets = envelope.paths; var jsong = envelope.jsong || envelope.values || envelope.value; var index2 = -1; var count2 = pathsets.length; roots[2] = jsong; nodes[2] = jsong; while (++index2 < count2) { var pathset = pathsets[index2]; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); } } hasValue = roots.hasValue; if(hasValue) { json.json = roots[3]; } else { delete json.json; } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, messageParent, json, jsonkey; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } jsonkey = get_valid_key(requested); json = parents[3]; parent = parents[0]; messageParent = parents[2]; } else { jsonkey = key; json = nodes[3]; parent = nodes[0]; messageParent = nodes[2]; } var node = parent[key]; var message = messageParent && messageParent[key]; nodes[2] = message; nodes[0] = node = merge_node(roots, parent, node, messageParent, message, key); if (!is_top_level) { parents[0] = parent; parents[2] = messageParent; return; } parents[3] = json; if (is_branch) { var length = requested.length; var offset = roots.offset; var type = is_object(node) && node.$type || undefined; parents[0] = node; parents[2] = message; if ((length > offset) && (!type || type == $path)) { nodes[3] = json[jsonkey] || (json[jsonkey] = {}); } } } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { var json; var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathset, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); if (node_as_error(roots, node, type, requested) === false) { if (keyset == null && !roots.hasValue && (keyset = get_valid_key(optimized)) == null) { node = clone(roots, node, type, node && node.value); json = roots[3]; json.$type = node.$type; json.value = node.value; } else { json = parents[3]; json[key] = clone(roots, node, type, node && node.value); } roots.hasValue = true; } } } },{"../lru/collect":86,"../support/array-clone":104,"../support/clone-dense-json":106,"../support/clone-success-paths":112,"../support/get-valid-key":116,"../support/is-object":122,"../support/merge-node":125,"../support/options":127,"../support/treat-node-as-error":132,"../support/treat-node-as-missing-path-set":134,"../types/path":140,"../walk/walk-path-set-soft-link":146}],94:[function(_dereq_,module,exports){ module.exports = set_json_graph_as_json_values; var $path = _dereq_("../types/path"); var clone = _dereq_("../support/clone-dense-json"); var array_clone = _dereq_("../support/array-clone"); var array_slice = _dereq_("../support/array-slice"); var options = _dereq_("../support/options"); var walk_path_set = _dereq_("../walk/walk-path-set-soft-link"); var is_object = _dereq_("../support/is-object"); var get_valid_key = _dereq_("../support/get-valid-key"); var merge_node = _dereq_("../support/merge-node"); var node_as_miss = _dereq_("../support/treat-node-as-missing-path-set"); var node_as_error = _dereq_("../support/treat-node-as-error"); var clone_success = _dereq_("../support/clone-success-paths"); var collect = _dereq_("../lru/collect"); function set_json_graph_as_json_values(model, envelopes, onNext, error_selector) { var roots = []; roots.offset = model._path.length; roots.bound = []; roots = options(roots, model, error_selector); var index = -1; var count = envelopes.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; roots[0] = roots.root; roots.onNext = onNext; while (++index < count) { var envelope = envelopes[index]; var pathsets = envelope.paths; var jsong = envelope.jsong || envelope.values || envelope.value; var index2 = -1; var count2 = pathsets.length; roots[2] = jsong; nodes[2] = jsong; while (++index2 < count2) { var pathset = pathsets[index2]; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); } } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: null, errors: roots.errors, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset) { var parent, messageParent; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } parent = parents[0]; messageParent = parents[2]; } else { parent = nodes[0]; messageParent = nodes[2]; } var node = parent[key]; var message = messageParent && messageParent[key]; nodes[2] = message; nodes[0] = node = merge_node(roots, parent, node, messageParent, message, key); if (!is_top_level) { parents[0] = parent; parents[2] = messageParent; return; } if (is_branch) { parents[0] = node; parents[2] = message; } } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset, is_keyset) { var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathset, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); if (node_as_error(roots, node, type, requested) === false) { roots.onNext({ path: array_slice(requested, roots.offset), value: clone(roots, node, type, node && node.value) }); } } } },{"../lru/collect":86,"../support/array-clone":104,"../support/array-slice":105,"../support/clone-dense-json":106,"../support/clone-success-paths":112,"../support/get-valid-key":116,"../support/is-object":122,"../support/merge-node":125,"../support/options":127,"../support/treat-node-as-error":132,"../support/treat-node-as-missing-path-set":134,"../types/path":140,"../walk/walk-path-set-soft-link":146}],95:[function(_dereq_,module,exports){ module.exports = set_json_sparse_as_json_dense; var $path = _dereq_("../types/path"); var $error = _dereq_("../types/error"); var $sentinel = _dereq_("../types/sentinel"); var clone = _dereq_("../support/clone-dense-json"); var array_clone = _dereq_("../support/array-clone"); var options = _dereq_("../support/options"); var walk_path_map = _dereq_("../walk/walk-path-map"); var is_object = _dereq_("../support/is-object"); var get_valid_key = _dereq_("../support/get-valid-key"); var create_branch = _dereq_("../support/create-branch"); var wrap_node = _dereq_("../support/wrap-node"); var replace_node = _dereq_("../support/replace-node"); var graph_node = _dereq_("../support/graph-node"); var update_back_refs = _dereq_("../support/update-back-refs"); var update_graph = _dereq_("../support/update-graph"); var inc_generation = _dereq_("../support/inc-generation"); var node_as_miss = _dereq_("../support/treat-node-as-missing-path-map"); var node_as_error = _dereq_("../support/treat-node-as-error"); var clone_success = _dereq_("../support/clone-success-paths"); var collect = _dereq_("../lru/collect"); function set_json_sparse_as_json_dense(model, pathmaps, values, error_selector) { var roots = options([], model, error_selector); var index = -1; var count = pathmaps.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var keys_stack = []; var json, hasValue, hasValues; roots[0] = roots.root; while (++index < count) { json = values && values[index]; if (is_object(json)) { roots.json = roots[3] = parents[3] = nodes[3] = json.json || (json.json = {}) } else { roots.json = roots[3] = parents[3] = nodes[3] = undefined; } var pathmap = pathmaps[index]; roots.index = index; walk_path_map(onNode, onEdge, pathmap, keys_stack, 0, roots, parents, nodes, requested, optimized); hasValue = roots.hasValue; if (!!hasValue) { hasValues = true; if (is_object(json)) { json.json = roots.json; } delete roots.json; delete roots.hasValue; } else if (is_object(json)) { delete json.json; } } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, hasValue: hasValues, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathmap, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, json; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } json = parents[3]; parent = parents[0]; } else { json = is_keyset && nodes[3] || parents[3]; parent = nodes[0]; } var node = parent[key], type; if (!is_top_level) { type = is_object(node) && node.$type || undefined; type = type && is_branch && "." || type; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; return; } parents[3] = json; if (is_branch) { type = is_object(node) && node.$type || undefined; node = create_branch(roots, parent, node, type, key); parents[0] = nodes[0] = node; if (is_keyset && !!json) { nodes[3] = json[keyset] || (json[keyset] = {}); } return; } var selector = roots.error_selector; var root = roots[0]; var size = is_object(node) && node.$size || 0; var mess = pathmap; type = is_object(mess) && mess.$type || undefined; mess = wrap_node(mess, type, !!type ? mess.value : mess); type || (type = $sentinel); if (type == $error && !!selector) { mess = selector(requested, mess); } node = replace_node(parent, node, mess, key, roots.lru); node = graph_node(root, parent, node, key, inc_generation()); update_graph(parent, size - node.$size, roots.version, roots.lru); nodes[0] = node; } function onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset) { var json; var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathmap, keys_stack, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); if (node_as_error(roots, node, type, requested) === false) { if(keyset == null) { roots.json = clone(roots, node, type, node && node.value); } else if(!!(json = parents[3])) { json[keyset] = clone(roots, node, type, node && node.value); } roots.hasValue = true; } } } },{"../lru/collect":86,"../support/array-clone":104,"../support/clone-dense-json":106,"../support/clone-success-paths":112,"../support/create-branch":114,"../support/get-valid-key":116,"../support/graph-node":117,"../support/inc-generation":118,"../support/is-object":122,"../support/options":127,"../support/replace-node":130,"../support/treat-node-as-error":132,"../support/treat-node-as-missing-path-map":133,"../support/update-back-refs":136,"../support/update-graph":137,"../support/wrap-node":138,"../types/error":139,"../types/path":140,"../types/sentinel":141,"../walk/walk-path-map":145}],96:[function(_dereq_,module,exports){ module.exports = set_json_sparse_as_json_graph; var $path = _dereq_("../types/path"); var $error = _dereq_("../types/error"); var $sentinel = _dereq_("../types/sentinel"); var clone = _dereq_("../support/clone-graph-json"); var array_clone = _dereq_("../support/array-clone"); var options = _dereq_("../support/options"); var walk_path_map = _dereq_("../walk/walk-path-map-soft-link"); var is_object = _dereq_("../support/is-object"); var get_valid_key = _dereq_("../support/get-valid-key"); var create_branch = _dereq_("../support/create-branch"); var wrap_node = _dereq_("../support/wrap-node"); var replace_node = _dereq_("../support/replace-node"); var graph_node = _dereq_("../support/graph-node"); var update_back_refs = _dereq_("../support/update-back-refs"); var update_graph = _dereq_("../support/update-graph"); var inc_generation = _dereq_("../support/inc-generation"); var node_as_miss = _dereq_("../support/treat-node-as-missing-path-map"); var node_as_error = _dereq_("../support/treat-node-as-error"); var clone_success = _dereq_("../support/clone-success-paths"); var promote = _dereq_("../lru/promote"); var collect = _dereq_("../lru/collect"); function set_json_sparse_as_json_graph(model, pathmaps, values, error_selector) { var roots = options([], model, error_selector); var index = -1; var count = pathmaps.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var keys_stack = []; var json = values[0]; var hasValue; roots[0] = roots.root; roots[1] = parents[1] = nodes[1] = json.jsong || (json.jsong = {}); roots.requestedPaths = json.paths || (json.paths = roots.requestedPaths); while (++index < count) { var pathmap = pathmaps[index]; walk_path_map(onNode, onEdge, pathmap, keys_stack, 0, roots, parents, nodes, requested, optimized); } hasValue = roots.hasValue; if(hasValue) { json.jsong = roots[1]; } else { delete json.jsong; delete json.paths; } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, hasValue: hasValue, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathmap, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, json; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } json = parents[1]; parent = parents[0]; } else { json = nodes[1]; parent = nodes[0]; } var jsonkey = key; var node = parent[key], type; if (!is_top_level) { type = is_object(node) && node.$type || undefined; type = type && is_branch && "." || type; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; parents[1] = json; if (type == $path) { json[jsonkey] = clone(roots, node, type, node.value); roots.hasValue = true; } else { nodes[1] = json[jsonkey] || (json[jsonkey] = {}); } return; } if (is_branch) { type = is_object(node) && node.$type || undefined; node = create_branch(roots, parent, node, type, key); type = node.$type; parents[0] = nodes[0] = node; parents[1] = json; if (type == $path) { json[jsonkey] = clone(roots, node, type, node.value); roots.hasValue = true; } else { nodes[1] = json[jsonkey] || (json[jsonkey] = {}); } return; } var selector = roots.error_selector; var root = roots[0]; var size = is_object(node) && node.$size || 0; var mess = pathmap; type = is_object(mess) && mess.$type || undefined; mess = wrap_node(mess, type, !!type ? mess.value : mess); type || (type = $sentinel); if (type == $error && !!selector) { mess = selector(requested, mess); } node = replace_node(parent, node, mess, key, roots.lru); node = graph_node(root, parent, node, key, inc_generation()); update_graph(parent, size - node.$size, roots.version, roots.lru); nodes[0] = node; json[jsonkey] = clone(roots, node, type, node && node.value); roots.hasValue = true; } function onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset) { var json; var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathmap, keys_stack, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); promote(roots.lru, node); if (keyset == null && !roots.hasValue && (keyset = get_valid_key(optimized)) == null) { node = clone(roots, node, type, node && node.value); json = roots[1]; json.$type = node.$type; json.value = node.value; } roots.hasValue = true; } } },{"../lru/collect":86,"../lru/promote":87,"../support/array-clone":104,"../support/clone-graph-json":107,"../support/clone-success-paths":112,"../support/create-branch":114,"../support/get-valid-key":116,"../support/graph-node":117,"../support/inc-generation":118,"../support/is-object":122,"../support/options":127,"../support/replace-node":130,"../support/treat-node-as-error":132,"../support/treat-node-as-missing-path-map":133,"../support/update-back-refs":136,"../support/update-graph":137,"../support/wrap-node":138,"../types/error":139,"../types/path":140,"../types/sentinel":141,"../walk/walk-path-map-soft-link":144}],97:[function(_dereq_,module,exports){ module.exports = set_json_sparse_as_json_sparse; var $path = _dereq_("../types/path"); var $error = _dereq_("../types/error"); var $sentinel = _dereq_("../types/sentinel"); var clone = _dereq_("../support/clone-dense-json"); var array_clone = _dereq_("../support/array-clone"); var options = _dereq_("../support/options"); var walk_path_map = _dereq_("../walk/walk-path-map"); var is_object = _dereq_("../support/is-object"); var get_valid_key = _dereq_("../support/get-valid-key"); var create_branch = _dereq_("../support/create-branch"); var wrap_node = _dereq_("../support/wrap-node"); var replace_node = _dereq_("../support/replace-node"); var graph_node = _dereq_("../support/graph-node"); var update_back_refs = _dereq_("../support/update-back-refs"); var update_graph = _dereq_("../support/update-graph"); var inc_generation = _dereq_("../support/inc-generation"); var node_as_miss = _dereq_("../support/treat-node-as-missing-path-map"); var node_as_error = _dereq_("../support/treat-node-as-error"); var clone_success = _dereq_("../support/clone-success-paths"); var collect = _dereq_("../lru/collect"); function set_json_sparse_as_json_sparse(model, pathmaps, values, error_selector) { var roots = options([], model, error_selector); var index = -1; var count = pathmaps.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var keys_stack = []; var json = values[0]; var hasValue; roots[0] = roots.root; roots[3] = parents[3] = nodes[3] = json.json || (json.json = {}); while (++index < count) { var pathmap = pathmaps[index]; walk_path_map(onNode, onEdge, pathmap, keys_stack, 0, roots, parents, nodes, requested, optimized); } hasValue = roots.hasValue; if(hasValue) { json.json = roots[3]; } else { delete json.json; } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, hasValue: hasValue, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathmap, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, json, jsonkey; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } jsonkey = get_valid_key(requested); json = parents[3]; parent = parents[0]; } else { jsonkey = key; json = nodes[3]; parent = nodes[0]; } var node = parent[key], type; if (!is_top_level) { type = is_object(node) && node.$type || undefined; type = type && is_branch && "." || type; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; return; } parents[3] = json; if (is_branch) { type = is_object(node) && node.$type || undefined; node = create_branch(roots, parent, node, type, key); parents[0] = nodes[0] = node; nodes[3] = json[jsonkey] || (json[jsonkey] = {}); return; } var selector = roots.error_selector; var root = roots[0]; var size = is_object(node) && node.$size || 0; var mess = pathmap; type = is_object(mess) && mess.$type || undefined; mess = wrap_node(mess, type, !!type ? mess.value : mess); type || (type = $sentinel); if (type == $error && !!selector) { mess = selector(requested, mess); } node = replace_node(parent, node, mess, key, roots.lru); node = graph_node(root, parent, node, key, inc_generation()); update_graph(parent, size - node.$size, roots.version, roots.lru); nodes[0] = node; } function onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset) { var json; var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathmap, keys_stack, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); if (node_as_error(roots, node, type, requested) === false) { if (keyset == null && !roots.hasValue && (keyset = get_valid_key(optimized)) == null) { node = clone(roots, node, type, node && node.value); json = roots[3]; json.$type = node.$type; json.value = node.value; } else { json = parents[3]; json[key] = clone(roots, node, type, node && node.value); } roots.hasValue = true; } } } },{"../lru/collect":86,"../support/array-clone":104,"../support/clone-dense-json":106,"../support/clone-success-paths":112,"../support/create-branch":114,"../support/get-valid-key":116,"../support/graph-node":117,"../support/inc-generation":118,"../support/is-object":122,"../support/options":127,"../support/replace-node":130,"../support/treat-node-as-error":132,"../support/treat-node-as-missing-path-map":133,"../support/update-back-refs":136,"../support/update-graph":137,"../support/wrap-node":138,"../types/error":139,"../types/path":140,"../types/sentinel":141,"../walk/walk-path-map":145}],98:[function(_dereq_,module,exports){ module.exports = set_path_map_as_json_values; var $error = _dereq_("../types/error"); var $sentinel = _dereq_("../types/sentinel"); var clone = _dereq_("../support/clone-dense-json"); var array_clone = _dereq_("../support/array-clone"); var options = _dereq_("../support/options"); var walk_path_map = _dereq_("../walk/walk-path-map"); var is_object = _dereq_("../support/is-object"); var get_valid_key = _dereq_("../support/get-valid-key"); var create_branch = _dereq_("../support/create-branch"); var wrap_node = _dereq_("../support/wrap-node"); var replace_node = _dereq_("../support/replace-node"); var graph_node = _dereq_("../support/graph-node"); var update_back_refs = _dereq_("../support/update-back-refs"); var update_graph = _dereq_("../support/update-graph"); var inc_generation = _dereq_("../support/inc-generation"); var node_as_miss = _dereq_("../support/treat-node-as-missing-path-map"); var node_as_error = _dereq_("../support/treat-node-as-error"); var clone_success = _dereq_("../support/clone-success-paths"); var collect = _dereq_("../lru/collect"); function set_path_map_as_json_values(model, pathmaps, onNext, error_selector) { var roots = options([], model, error_selector); var index = -1; var count = pathmaps.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var keys_stack = []; roots[0] = roots.root; roots.onNext = onNext; while (++index < count) { var pathmap = pathmaps[index]; walk_path_map(onNode, onEdge, pathmap, keys_stack, 0, roots, parents, nodes, requested, optimized); } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: null, errors: roots.errors, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathmap, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } parent = parents[0]; } else { parent = nodes[0]; } var node = parent[key], type; if (!is_top_level) { type = is_object(node) && node.$type || undefined; type = type && is_branch && "." || type; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; return; } if (is_branch) { type = is_object(node) && node.$type || undefined; node = create_branch(roots, parent, node, type, key); parents[0] = nodes[0] = node; return; } var selector = roots.error_selector; var root = roots[0]; var size = is_object(node) && node.$size || 0; var mess = pathmap; type = is_object(mess) && mess.$type || undefined; mess = wrap_node(mess, type, !!type ? mess.value : mess); type || (type = $sentinel); if (type == $error && !!selector) { mess = selector(requested, mess); } node = replace_node(parent, node, mess, key, roots.lru); node = graph_node(root, parent, node, key, inc_generation()); update_graph(parent, size - node.$size, roots.version, roots.lru); nodes[0] = node; } function onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset) { var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathmap, keys_stack, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); if (node_as_error(roots, node, type, requested) === false) { roots.onNext({ path: array_clone(requested), value: clone(roots, node, type, node && node.value) }); } } } },{"../lru/collect":86,"../support/array-clone":104,"../support/clone-dense-json":106,"../support/clone-success-paths":112,"../support/create-branch":114,"../support/get-valid-key":116,"../support/graph-node":117,"../support/inc-generation":118,"../support/is-object":122,"../support/options":127,"../support/replace-node":130,"../support/treat-node-as-error":132,"../support/treat-node-as-missing-path-map":133,"../support/update-back-refs":136,"../support/update-graph":137,"../support/wrap-node":138,"../types/error":139,"../types/sentinel":141,"../walk/walk-path-map":145}],99:[function(_dereq_,module,exports){ module.exports = set_json_values_as_json_dense; var $path = _dereq_("../types/path"); var $error = _dereq_("../types/error"); var $sentinel = _dereq_("../types/sentinel"); var clone = _dereq_("../support/clone-dense-json"); var array_clone = _dereq_("../support/array-clone"); var options = _dereq_("../support/options"); var walk_path_set = _dereq_("../walk/walk-path-set"); var is_object = _dereq_("../support/is-object"); var get_valid_key = _dereq_("../support/get-valid-key"); var create_branch = _dereq_("../support/create-branch"); var wrap_node = _dereq_("../support/wrap-node"); var invalidate_node = _dereq_("../support/invalidate-node"); var replace_node = _dereq_("../support/replace-node"); var graph_node = _dereq_("../support/graph-node"); var update_back_refs = _dereq_("../support/update-back-refs"); var update_graph = _dereq_("../support/update-graph"); var inc_generation = _dereq_("../support/inc-generation"); var node_as_miss = _dereq_("../support/treat-node-as-missing-path-set"); var node_as_error = _dereq_("../support/treat-node-as-error"); var clone_success = _dereq_("../support/clone-success-paths"); var collect = _dereq_("../lru/collect"); function set_json_values_as_json_dense(model, pathvalues, values, error_selector) { var roots = options([], model, error_selector); var index = -1; var count = pathvalues.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var json, hasValue, hasValues; roots[0] = roots.root; while (++index < count) { json = values && values[index]; if (is_object(json)) { roots.json = roots[3] = parents[3] = nodes[3] = json.json || (json.json = {}) } else { roots.json = roots[3] = parents[3] = nodes[3] = undefined; } var pv = pathvalues[index]; var pathset = pv.path; roots.value = pv.value; roots.index = index; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); hasValue = roots.hasValue; if (!!hasValue) { hasValues = true; if (is_object(json)) { json.json = roots.json; } delete roots.json; delete roots.hasValue; } else if (is_object(json)) { delete json.json; } } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, hasValue: hasValues, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, json; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } json = parents[3]; parent = parents[0]; } else { json = is_keyset && nodes[3] || parents[3]; parent = nodes[0]; } var node = parent[key], type; if (!is_top_level) { type = is_object(node) && node.$type || undefined; type = type && is_branch && "." || type; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; return; } parents[3] = json; if (is_branch) { type = is_object(node) && node.$type || undefined; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; if (is_keyset && !!json) { nodes[3] = json[keyset] || (json[keyset] = {}); } return; } var selector = roots.error_selector; var root = roots[0]; var size = is_object(node) && node.$size || 0; var mess = roots.value; if(mess === undefined && roots.headless) { invalidate_node(parent, node, key, roots.lru); update_graph(parent, size, roots.version, roots.lru); node = undefined; } else { type = is_object(mess) && mess.$type || undefined; mess = wrap_node(mess, type, !!type ? mess.value : mess); type || (type = $sentinel); if (type == $error && !!selector) { mess = selector(requested, mess); } node = replace_node(parent, node, mess, key, roots.lru); node = graph_node(root, parent, node, key, inc_generation()); update_graph(parent, size - node.$size, roots.version, roots.lru); } nodes[0] = node; } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { var json; var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathset, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); if (node_as_error(roots, node, type, requested) === false) { if(keyset == null) { roots.json = clone(roots, node, type, node && node.value); } else if(!!(json = parents[3])) { json[keyset] = clone(roots, node, type, node && node.value); } roots.hasValue = true; } } } },{"../lru/collect":86,"../support/array-clone":104,"../support/clone-dense-json":106,"../support/clone-success-paths":112,"../support/create-branch":114,"../support/get-valid-key":116,"../support/graph-node":117,"../support/inc-generation":118,"../support/invalidate-node":120,"../support/is-object":122,"../support/options":127,"../support/replace-node":130,"../support/treat-node-as-error":132,"../support/treat-node-as-missing-path-set":134,"../support/update-back-refs":136,"../support/update-graph":137,"../support/wrap-node":138,"../types/error":139,"../types/path":140,"../types/sentinel":141,"../walk/walk-path-set":147}],100:[function(_dereq_,module,exports){ module.exports = set_json_values_as_json_graph; var $path = _dereq_("../types/path"); var $error = _dereq_("../types/error"); var $sentinel = _dereq_("../types/sentinel"); var clone = _dereq_("../support/clone-graph-json"); var array_clone = _dereq_("../support/array-clone"); var options = _dereq_("../support/options"); var walk_path_set = _dereq_("../walk/walk-path-set-soft-link"); var is_object = _dereq_("../support/is-object"); var get_valid_key = _dereq_("../support/get-valid-key"); var create_branch = _dereq_("../support/create-branch"); var wrap_node = _dereq_("../support/wrap-node"); var invalidate_node = _dereq_("../support/invalidate-node"); var replace_node = _dereq_("../support/replace-node"); var graph_node = _dereq_("../support/graph-node"); var update_back_refs = _dereq_("../support/update-back-refs"); var update_graph = _dereq_("../support/update-graph"); var inc_generation = _dereq_("../support/inc-generation"); var node_as_miss = _dereq_("../support/treat-node-as-missing-path-set"); var node_as_error = _dereq_("../support/treat-node-as-error"); var clone_success = _dereq_("../support/clone-success-paths"); var promote = _dereq_("../lru/promote"); var collect = _dereq_("../lru/collect"); function set_json_values_as_json_graph(model, pathvalues, values, error_selector) { var roots = options([], model, error_selector); var index = -1; var count = pathvalues.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var json = values[0]; var hasValue; roots[0] = roots.root; roots[1] = parents[1] = nodes[1] = json.jsong || (json.jsong = {}); roots.requestedPaths = json.paths || (json.paths = roots.requestedPaths); while (++index < count) { var pv = pathvalues[index]; var pathset = pv.path; roots.value = pv.value; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); } hasValue = roots.hasValue; if(hasValue) { json.jsong = roots[1]; } else { delete json.jsong; delete json.paths; } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, hasValue: hasValue, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, json; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } json = parents[1]; parent = parents[0]; } else { json = nodes[1]; parent = nodes[0]; } var jsonkey = key; var node = parent[key], type; if (!is_top_level) { type = is_object(node) && node.$type || undefined; type = type && is_branch && "." || type; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; parents[1] = json; if (type == $path) { json[jsonkey] = clone(roots, node, type, node.value); roots.hasValue = true; } else { nodes[1] = json[jsonkey] || (json[jsonkey] = {}); } return; } if (is_branch) { type = is_object(node) && node.$type || undefined; node = create_branch(roots, parent, node, type, key); type = node.$type; parents[0] = parent; nodes[0] = node; parents[1] = json; if (type == $path) { json[jsonkey] = clone(roots, node, type, node.value); roots.hasValue = true; } else { nodes[1] = json[jsonkey] || (json[jsonkey] = {}); } return; } var selector = roots.error_selector; var root = roots[0]; var size = is_object(node) && node.$size || 0; var mess = roots.value; if(mess === undefined && roots.headless) { invalidate_node(parent, node, key, roots.lru); update_graph(parent, size, roots.version, roots.lru); node = undefined; } else { type = is_object(mess) && mess.$type || undefined; mess = wrap_node(mess, type, !!type ? mess.value : mess); type || (type = $sentinel); if (type == $error && !!selector) { mess = selector(requested, mess); } node = replace_node(parent, node, mess, key, roots.lru); node = graph_node(root, parent, node, key, inc_generation()); update_graph(parent, size - node.$size, roots.version, roots.lru); } nodes[0] = node; json[jsonkey] = clone(roots, node, type, node && node.value); roots.hasValue = true; } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { var json; var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathset, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); promote(roots.lru, node); if (keyset == null && !roots.hasValue && (keyset = get_valid_key(optimized)) == null) { node = clone(roots, node, type, node && node.value); json = roots[1]; json.$type = node.$type; json.value = node.value; } roots.hasValue = true; } } },{"../lru/collect":86,"../lru/promote":87,"../support/array-clone":104,"../support/clone-graph-json":107,"../support/clone-success-paths":112,"../support/create-branch":114,"../support/get-valid-key":116,"../support/graph-node":117,"../support/inc-generation":118,"../support/invalidate-node":120,"../support/is-object":122,"../support/options":127,"../support/replace-node":130,"../support/treat-node-as-error":132,"../support/treat-node-as-missing-path-set":134,"../support/update-back-refs":136,"../support/update-graph":137,"../support/wrap-node":138,"../types/error":139,"../types/path":140,"../types/sentinel":141,"../walk/walk-path-set-soft-link":146}],101:[function(_dereq_,module,exports){ module.exports = set_json_values_as_json_sparse; var $path = _dereq_("../types/path"); var $error = _dereq_("../types/error"); var $sentinel = _dereq_("../types/sentinel"); var clone = _dereq_("../support/clone-dense-json"); var array_clone = _dereq_("../support/array-clone"); var options = _dereq_("../support/options"); var walk_path_set = _dereq_("../walk/walk-path-set"); var is_object = _dereq_("../support/is-object"); var get_valid_key = _dereq_("../support/get-valid-key"); var create_branch = _dereq_("../support/create-branch"); var wrap_node = _dereq_("../support/wrap-node"); var invalidate_node = _dereq_("../support/invalidate-node"); var replace_node = _dereq_("../support/replace-node"); var graph_node = _dereq_("../support/graph-node"); var update_back_refs = _dereq_("../support/update-back-refs"); var update_graph = _dereq_("../support/update-graph"); var inc_generation = _dereq_("../support/inc-generation"); var node_as_miss = _dereq_("../support/treat-node-as-missing-path-set"); var node_as_error = _dereq_("../support/treat-node-as-error"); var clone_success = _dereq_("../support/clone-success-paths"); var collect = _dereq_("../lru/collect"); function set_json_values_as_json_sparse(model, pathvalues, values, error_selector) { var roots = options([], model, error_selector); var index = -1; var count = pathvalues.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; var json = values[0]; var hasValue; roots[0] = roots.root; roots[3] = parents[3] = nodes[3] = json.json || (json.json = {}); while (++index < count) { var pv = pathvalues[index]; var pathset = pv.path; roots.value = pv.value; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); } hasValue = roots.hasValue; if(hasValue) { json.json = roots[3]; } else { delete json.json; } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: values, errors: roots.errors, hasValue: hasValue, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent, json, jsonkey; if (key == null) { if ((key = get_valid_key(optimized)) == null) { return; } jsonkey = get_valid_key(requested); json = parents[3]; parent = parents[0]; } else { jsonkey = key; json = nodes[3]; parent = nodes[0]; } var node = parent[key], type; if (!is_top_level) { type = is_object(node) && node.$type || undefined; type = type && is_branch && "." || type; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; return; } parents[3] = json; if (is_branch) { type = is_object(node) && node.$type || undefined; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; nodes[3] = json[jsonkey] || (json[jsonkey] = {}); return; } var selector = roots.error_selector; var root = roots[0]; var size = is_object(node) && node.$size || 0; var mess = roots.value; if(mess === undefined && roots.headless) { invalidate_node(parent, node, key, roots.lru); update_graph(parent, size, roots.version, roots.lru); node = undefined; } else { type = is_object(mess) && mess.$type || undefined; mess = wrap_node(mess, type, !!type ? mess.value : mess); type || (type = $sentinel); if (type == $error && !!selector) { mess = selector(requested, mess); } node = replace_node(parent, node, mess, key, roots.lru); node = graph_node(root, parent, node, key, inc_generation()); update_graph(parent, size - node.$size, roots.version, roots.lru); } nodes[0] = node; } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { var json; var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathset, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); if (node_as_error(roots, node, type, requested) === false) { if (keyset == null && !roots.hasValue && (keyset = get_valid_key(optimized)) == null) { node = clone(roots, node, type, node && node.value); json = roots[3]; json.$type = node.$type; json.value = node.value; } else { json = parents[3]; json[key] = clone(roots, node, type, node && node.value); } roots.hasValue = true; } } } },{"../lru/collect":86,"../support/array-clone":104,"../support/clone-dense-json":106,"../support/clone-success-paths":112,"../support/create-branch":114,"../support/get-valid-key":116,"../support/graph-node":117,"../support/inc-generation":118,"../support/invalidate-node":120,"../support/is-object":122,"../support/options":127,"../support/replace-node":130,"../support/treat-node-as-error":132,"../support/treat-node-as-missing-path-set":134,"../support/update-back-refs":136,"../support/update-graph":137,"../support/wrap-node":138,"../types/error":139,"../types/path":140,"../types/sentinel":141,"../walk/walk-path-set":147}],102:[function(_dereq_,module,exports){ module.exports = set_json_values_as_json_values; var $error = _dereq_("../types/error"); var $sentinel = _dereq_("../types/sentinel"); var clone = _dereq_("../support/clone-dense-json"); var array_clone = _dereq_("../support/array-clone"); var options = _dereq_("../support/options"); var walk_path_set = _dereq_("../walk/walk-path-set"); var is_object = _dereq_("../support/is-object"); var get_valid_key = _dereq_("../support/get-valid-key"); var create_branch = _dereq_("../support/create-branch"); var wrap_node = _dereq_("../support/wrap-node"); var invalidate_node = _dereq_("../support/invalidate-node"); var replace_node = _dereq_("../support/replace-node"); var graph_node = _dereq_("../support/graph-node"); var update_back_refs = _dereq_("../support/update-back-refs"); var update_graph = _dereq_("../support/update-graph"); var inc_generation = _dereq_("../support/inc-generation"); var node_as_miss = _dereq_("../support/treat-node-as-missing-path-set"); var node_as_error = _dereq_("../support/treat-node-as-error"); var clone_success = _dereq_("../support/clone-success-paths"); var collect = _dereq_("../lru/collect"); function set_json_values_as_json_values(model, pathvalues, onNext, error_selector) { var roots = options([], model, error_selector); var index = -1; var count = pathvalues.length; var nodes = roots.nodes; var parents = array_clone(nodes); var requested = []; var optimized = []; roots[0] = roots.root; roots.onNext = onNext; while (++index < count) { var pv = pathvalues[index]; var pathset = pv.path; roots.value = pv.value; walk_path_set(onNode, onEdge, pathset, 0, roots, parents, nodes, requested, optimized); } collect( roots.lru, roots.expired, roots.version, roots.root.$size || 0, model._maxSize, model._collectRatio ); return { values: null, errors: roots.errors, requestedPaths: roots.requestedPaths, optimizedPaths: roots.optimizedPaths, requestedMissingPaths: roots.requestedMissingPaths, optimizedMissingPaths: roots.optimizedMissingPaths }; } function onNode(pathset, roots, parents, nodes, requested, optimized, is_top_level, is_branch, key, keyset, is_keyset) { var parent; if (key == null) { if ((key = get_valid_key(optimized, nodes)) == null) { return; } parent = parents[0]; } else { parent = nodes[0]; } var node = parent[key], type; if (!is_top_level) { type = is_object(node) && node.$type || undefined; type = type && is_branch && "." || type; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; return; } if (is_branch) { type = is_object(node) && node.$type || undefined; node = create_branch(roots, parent, node, type, key); parents[0] = parent; nodes[0] = node; return; } var selector = roots.error_selector; var root = roots[0]; var size = is_object(node) && node.$size || 0; var mess = roots.value; if(mess === undefined && roots.headless) { invalidate_node(parent, node, key, roots.lru); update_graph(parent, size, roots.version, roots.lru); node = undefined; } else { type = is_object(mess) && mess.$type || undefined; mess = wrap_node(mess, type, !!type ? mess.value : mess); type || (type = $sentinel); if (type == $error && !!selector) { mess = selector(requested, mess); } node = replace_node(parent, node, mess, key, roots.lru); node = graph_node(root, parent, node, key, inc_generation()); update_graph(parent, size - node.$size, roots.version, roots.lru); } nodes[0] = node; } function onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset) { var node = nodes[0]; var type = is_object(node) && node.$type || (node = undefined); if (node_as_miss(roots, node, type, pathset, depth, requested, optimized) === false) { clone_success(roots, requested, optimized); if (node_as_error(roots, node, type, requested) === false) { roots.onNext({ path: array_clone(requested), value: clone(roots, node, type, node && node.value) }); } } } },{"../lru/collect":86,"../support/array-clone":104,"../support/clone-dense-json":106,"../support/clone-success-paths":112,"../support/create-branch":114,"../support/get-valid-key":116,"../support/graph-node":117,"../support/inc-generation":118,"../support/invalidate-node":120,"../support/is-object":122,"../support/options":127,"../support/replace-node":130,"../support/treat-node-as-error":132,"../support/treat-node-as-missing-path-set":134,"../support/update-back-refs":136,"../support/update-graph":137,"../support/wrap-node":138,"../types/error":139,"../types/sentinel":141,"../walk/walk-path-set":147}],103:[function(_dereq_,module,exports){ module.exports = function(array, value) { var i = -1; var n = array.length; var array2 = new Array(n + 1); while(++i < n) { array2[i] = array[i]; } array2[i] = value; return array2; }; },{}],104:[function(_dereq_,module,exports){ module.exports = function(array) { var i = -1; var n = array.length; var array2 = new Array(n); while(++i < n) { array2[i] = array[i]; } return array2; }; },{}],105:[function(_dereq_,module,exports){ module.exports = function(array, index) { var i = -1; var n = array.length - index; var array2 = new Array(n); while(++i < n) { array2[i] = array[i + index]; } return array2; }; },{}],106:[function(_dereq_,module,exports){ var $sentinel = _dereq_("../types/sentinel"); var clone = _dereq_("./clone"); module.exports = function(roots, node, type, value) { if(node == null || value === undefined) { return { $type: $sentinel }; } if(roots.boxed == true) { return !!type && clone(node) || node; } return value; } },{"../types/sentinel":141,"./clone":113}],107:[function(_dereq_,module,exports){ var $sentinel = _dereq_("../types/sentinel"); var clone = _dereq_("./clone"); var is_primitive = _dereq_("./is-primitive"); module.exports = function(roots, node, type, value) { if(node == null || value === undefined) { return { $type: $sentinel }; } if(roots.boxed == true) { return !!type && clone(node) || node; } if(!type || (type === $sentinel && is_primitive(value))) { return value; } return clone(node); } },{"../types/sentinel":141,"./clone":113,"./is-primitive":123}],108:[function(_dereq_,module,exports){ var clone_requested = _dereq_("./clone-requested-path"); var clone_optimized = _dereq_("./clone-optimized-path"); var walk_path_map = _dereq_("../walk/walk-path-map-soft-link"); var is_object = _dereq_("./is-object"); var empty = []; module.exports = function(roots, pathmap, keys_stack, depth, requested, optimized) { var patset_keys = explode_keys(pathmap, keys_stack.concat(), depth); var pathset = patset_keys.map(function(keys) { keys = keys.filter(function(key) { return key != "null"; }); switch(keys.length) { case 0: return null; case 1: return keys[0]; default: return keys; } }); roots.requestedMissingPaths.push(clone_requested(roots.bound, requested, pathset, depth, roots.index)); roots.optimizedMissingPaths.push(clone_optimized(optimized, pathset, depth)); } function explode_keys(pathmap, keys_stack, depth) { if(is_object(pathmap)) { var keys = Object.keys(pathmap); var keys2 = keys_stack[depth] || (keys_stack[depth] = []); keys2.push.apply(keys2, keys); keys.forEach(function(key) { explode_keys(pathmap[key], keys_stack, depth + 1); }); } return keys_stack; } },{"../walk/walk-path-map-soft-link":144,"./clone-optimized-path":110,"./clone-requested-path":111,"./is-object":122}],109:[function(_dereq_,module,exports){ var clone_requested_path = _dereq_("./clone-requested-path"); var clone_optimized_path = _dereq_("./clone-optimized-path"); module.exports = function(roots, pathset, depth, requested, optimized) { roots.requestedMissingPaths.push(clone_requested_path(roots.bound, requested, pathset, depth, roots.index)); roots.optimizedMissingPaths.push(clone_optimized_path(optimized, pathset, depth)); } },{"./clone-optimized-path":110,"./clone-requested-path":111}],110:[function(_dereq_,module,exports){ module.exports = function(optimized, pathset, depth) { var x; var i = -1; var j = depth - 1; var n = optimized.length; var m = pathset.length; var array2 = []; while(++i < n) { array2[i] = optimized[i]; } while(++j < m) { if((x = pathset[j]) != null) { array2[i++] = x; } } return array2; } },{}],111:[function(_dereq_,module,exports){ var is_object = _dereq_("./is-object"); module.exports = function(bound, requested, pathset, depth, index) { var x; var i = -1; var j = -1; var l = 0; var m = requested.length; var n = bound.length; var array2 = []; while(++i < n) { array2[i] = bound[i]; } while(++j < m) { if((x = requested[j]) != null) { if(is_object(pathset[l++])) { array2[i++] = [x]; } else { array2[i++] = x; } } } m = n + l + pathset.length - depth; while(i < m) { array2[i++] = pathset[l++]; } if(index != null) { array2.pathSetIndex = index; } return array2; } },{"./is-object":122}],112:[function(_dereq_,module,exports){ var array_slice = _dereq_("./array-slice"); var array_clone = _dereq_("./array-clone"); module.exports = function(roots, requested, optimized) { roots.requestedPaths.push(array_slice(requested, roots.offset)); roots.optimizedPaths.push(array_clone(optimized)); } },{"./array-clone":104,"./array-slice":105}],113:[function(_dereq_,module,exports){ var is_object = _dereq_("./is-object"); var prefix = _dereq_("../internal/prefix"); module.exports = function(value) { var dest = value, src = dest, i = -1, n, keys, key; if(is_object(dest)) { dest = {}; keys = Object.keys(src); n = keys.length; while(++i < n) { key = keys[i]; if(key[0] !== prefix) { dest[key] = src[key]; } } } return dest; } },{"../internal/prefix":74,"./is-object":122}],114:[function(_dereq_,module,exports){ var $path = _dereq_("../types/path"); var $expired = "expired"; var replace_node = _dereq_("./replace-node"); var graph_node = _dereq_("./graph-node"); var update_back_refs = _dereq_("./update-back-refs"); var is_primitive = _dereq_("./is-primitive"); var is_expired = _dereq_("./is-expired"); module.exports = function(roots, parent, node, type, key) { if(!!type && is_expired(roots, node)) { type = $expired; } if((!!type && type != $path) || is_primitive(node)) { node = replace_node(parent, node, {}, key, roots.lru); node = graph_node(roots[0], parent, node, key, 0); node = update_back_refs(node, roots.version); } return node; } },{"../types/path":140,"./graph-node":117,"./is-expired":121,"./is-primitive":123,"./replace-node":130,"./update-back-refs":136}],115:[function(_dereq_,module,exports){ var __ref = _dereq_("../internal/ref"); var __context = _dereq_("../internal/context"); var __ref_index = _dereq_("../internal/ref-index"); var __refs_length = _dereq_("../internal/refs-length"); module.exports = function(node) { var ref, i = -1, n = node[__refs_length] || 0; while(++i < n) { if((ref = node[__ref + i]) !== undefined) { ref[__context] = ref[__ref_index] = node[__ref + i] = undefined; } } node[__refs_length] = undefined } },{"../internal/context":66,"../internal/ref":77,"../internal/ref-index":76,"../internal/refs-length":78}],116:[function(_dereq_,module,exports){ module.exports = function(path) { var key, index = path.length - 1; do { if((key = path[index]) != null) { return key; } } while(--index > -1); return null; } },{}],117:[function(_dereq_,module,exports){ var __parent = _dereq_("../internal/parent"); var __key = _dereq_("../internal/key"); var __generation = _dereq_("../internal/generation"); module.exports = function(root, parent, node, key, generation) { node[__parent] = parent; node[__key] = key; node[__generation] = generation; return node; } },{"../internal/generation":67,"../internal/key":70,"../internal/parent":73}],118:[function(_dereq_,module,exports){ var generation = 0; module.exports = function() { return generation++; } },{}],119:[function(_dereq_,module,exports){ var version = 0; module.exports = function() { return version++; } },{}],120:[function(_dereq_,module,exports){ module.exports = invalidate; var is_object = _dereq_("./is-object"); var remove_node = _dereq_("./remove-node"); var prefix = _dereq_("../internal/prefix"); function invalidate(parent, node, key, lru) { if(remove_node(parent, node, key, lru)) { var type = is_object(node) && node.$type || undefined; if(type == null) { var keys = Object.keys(node); for(var i = -1, n = keys.length; ++i < n;) { var key = keys[i]; if(key[0] !== prefix && key[0] !== "$") { invalidate(node, node[key], key, lru); } } } return true; } return false; } },{"../internal/prefix":74,"./is-object":122,"./remove-node":129}],121:[function(_dereq_,module,exports){ var $expires_now = _dereq_("../values/expires-now"); var $expires_never = _dereq_("../values/expires-never"); var __invalidated = _dereq_("../internal/invalidated"); var now = _dereq_("./now"); var splice = _dereq_("../lru/splice"); module.exports = function(roots, node) { var expires = node.$expires; if((expires != null ) && ( expires != $expires_never ) && ( expires == $expires_now || expires < now())) { if(!node[__invalidated]) { node[__invalidated] = true; roots.expired.push(node); splice(roots.lru, node); } return true; } return false; } },{"../internal/invalidated":69,"../lru/splice":88,"../values/expires-never":142,"../values/expires-now":143,"./now":126}],122:[function(_dereq_,module,exports){ var obj_typeof = "object"; module.exports = function(value) { return value != null && typeof value == obj_typeof; } },{}],123:[function(_dereq_,module,exports){ var obj_typeof = "object"; module.exports = function(value) { return value == null || typeof value != obj_typeof; } },{}],124:[function(_dereq_,module,exports){ module.exports = key_to_keyset; var __offset = _dereq_("../internal/offset"); var is_array = Array.isArray; var is_object = _dereq_("./is-object"); function key_to_keyset(key, iskeyset) { if(iskeyset) { if(is_array(key)) { key = key[key[__offset]]; return key_to_keyset(key, is_object(key)); } else { return key[__offset]; } } return key; } },{"../internal/offset":72,"./is-object":122}],125:[function(_dereq_,module,exports){ var $self = "./"; var $path = _dereq_("../types/path"); var $sentinel = _dereq_("../types/sentinel"); var $expires_now = _dereq_("../values/expires-now"); var is_object = _dereq_("./is-object"); var is_primitive = _dereq_("./is-primitive"); var is_expired = _dereq_("./is-expired"); var promote = _dereq_("../lru/promote"); var wrap_node = _dereq_("./wrap-node"); var graph_node = _dereq_("./graph-node"); var replace_node = _dereq_("../support/replace-node"); var update_graph = _dereq_("../support/update-graph"); var inc_generation = _dereq_("./inc-generation"); var invalidate_node = _dereq_("./invalidate-node"); module.exports = function(roots, parent, node, messageParent, message, key) { var type, messageType, node_is_object, message_is_object; // If the cache and message are the same, we can probably return early: // - If they're both null, return null. // - If they're both branches, return the branch. // - If they're both edges, continue below. if(node == message) { if(node == null) { return null; } else if(node_is_object = is_object(node)) { type = node.$type; if(type == null) { if(node[$self] == null) { return graph_node(roots[0], parent, node, key, 0); } return node; } } } else if(node_is_object = is_object(node)) { type = node.$type; } var value, messageValue; if(type == $path) { if(message == null) { // If the cache is an expired reference, but the message // is empty, remove the cache value and return undefined // so we build a missing path. if(is_expired(roots, node)) { invalidate_node(parent, node, key, roots.lru); return undefined; } // If the cache has a reference and the message is empty, // leave the cache alone and follow the reference. return node; } else if(message_is_object = is_object(message)) { messageType = message.$type; // If the cache and the message are both references, // check if we need to replace the cache reference. if(messageType == $path) { if(node === message) { // If the cache and message are the same reference, // we performed a whole-branch merge of one of the // grandparents. If we've previously graphed this // reference, break early. if(node[$self] != null) { return node; } } // If the message doesn't expire immediately and is newer than the // cache (or either cache or message don't have timestamps), attempt // to use the message value. // Note: Number and `undefined` compared LT/GT to `undefined` is `false`. else if(( is_expired(roots, message) === false) && (( message.$timestamp < node.$timestamp) === false)) { // Compare the cache and message references. // - If they're the same, break early so we don't insert. // - If they're different, replace the cache reference. value = node.value; messageValue = message.value; var count = value.length; // If the reference lengths are equal, check their keys for equality. if(count === messageValue.length) { while(--count > -1) { // If any of their keys are different, replace the reference // in the cache with the reference in the message. if(value[count] !== messageValue[count]) { break; } } // If all their keys are equal, leave the cache value alone. if(count === -1) { return node; } } } } } } else { if(message_is_object = is_object(message)) { messageType = message.$type; } if(node_is_object && !type) { // Otherwise if the cache is a branch and the message is either // null or also a branch, continue with the cache branch. if(message == null || (message_is_object && !messageType)) { return node; } } } // If the message is an expired edge, report it back out so we don't build a missing path, but // don't insert it into the cache. If a value exists in the cache that didn't come from a // whole-branch grandparent merge, remove the cache value. if(!!messageType && !!message[$self] && is_expired(roots, message)) { if(node_is_object && node != message) { invalidate_node(parent, node, key, roots.lru); } return message; } // If the cache is a value, but the message is a branch, merge the branch over the value. else if(!!type && message_is_object && !messageType) { node = replace_node(parent, node, message, key, roots.lru); return graph_node(roots[0], parent, node, key, 0); } // If the message is a value, insert it into the cache. else if(!message_is_object || !!messageType) { var offset = 0; // If we've arrived at this message value, but didn't perform a whole-branch merge // on one of its ancestors, replace the cache node with the message value. if(node != message) { messageValue || (messageValue = !!messageType ? message.value : message); message = wrap_node(message, messageType, messageValue); var size = node_is_object && node.$size || 0; var messageSize = message.$size; offset = size - messageSize; node = replace_node(parent, node, message, key, roots.lru); update_graph(parent, offset, roots.version, roots.lru); node = graph_node(roots[0], parent, node, key, inc_generation()); } // If the cache and the message are the same value, we branch-merged one of its // ancestors. Give the message a $size and $type, attach its graph pointers, and // update the cache sizes and generations. else if(node_is_object && node[$self] == null) { node = parent[key] = wrap_node(node, type, node.value); offset = -node.$size; update_graph(parent, offset, roots.version, roots.lru); node = graph_node(roots[0], parent, node, key, inc_generation()); } // Otherwise, cache and message are the same primitive value. Wrap in a sentinel and insert. else { node = parent[key] = wrap_node(node, type, node); offset = -node.$size; update_graph(parent, offset, roots.version, roots.lru); node = graph_node(roots[0], parent, node, key, inc_generation()); } // If the node is already expired, return undefined to build a missing path. // if(is_expired(roots, node)) { // return undefined; // } // Promote the message edge in the LRU. promote(roots.lru, node); } // If we get here, the cache is empty and the message is a branch. // Merge the whole branch over. else if(node == null) { node = parent[key] = graph_node(roots[0], parent, message, key, 0); } return node; } },{"../lru/promote":87,"../support/replace-node":130,"../support/update-graph":137,"../types/path":140,"../types/sentinel":141,"../values/expires-now":143,"./graph-node":117,"./inc-generation":118,"./invalidate-node":120,"./is-expired":121,"./is-object":122,"./is-primitive":123,"./wrap-node":138}],126:[function(_dereq_,module,exports){ module.exports = Date.now; },{}],127:[function(_dereq_,module,exports){ var inc_version = _dereq_("../support/inc-version"); var getBoundValue = _dereq_('../get/getBoundValue'); module.exports = function(options, model, error_selector) { var bound = options.bound || (options.bound = model._path || []); var root = options.root || (options.root = model._cache); var nodes = options.nodes || (options.nodes = []); var lru = options.lru || (options.lru = model._root); options.expired || (options.expired = lru.expired); options.errors || (options.errors = []); options.requestedPaths || (options.requestedPaths = []); options.optimizedPaths || (options.optimizedPaths = []); options.requestedMissingPaths || (options.requestedMissingPaths = []); options.optimizedMissingPaths || (options.optimizedMissingPaths = []); options.boxed = model._boxed || false; options.materialized = model._materialized; options.errorsAsValues = model._treatErrorsAsValues || false; options.headless = model._dataSource == null; options.version = inc_version(); options.offset || (options.offset = 0); options.error_selector = error_selector || model._errorSelector; if(bound.length) { nodes[0] = getBoundValue(model, bound).value; } else { nodes[0] = root; } return options; }; },{"../get/getBoundValue":49,"../support/inc-version":119}],128:[function(_dereq_,module,exports){ module.exports = permute_keyset; var __offset = _dereq_("../internal/offset"); var is_array = Array.isArray; var is_object = _dereq_("./is-object"); function permute_keyset(key) { if(is_array(key)) { if(key[__offset] === undefined) { key[__offset] = -1; if(key.length == 0) { return false; } } if(++key[__offset] >= key.length) { return permute_keyset(key[key[__offset] = -1]); } else { return true; } } else if(is_object(key)) { if(key[__offset] === undefined) { key[__offset] = (key.from || (key.from = 0)) - 1; if(key.to === undefined) { if(key.length === undefined) { throw new Error("Range keysets must specify at least one index to retrieve."); } else if(key.length === 0) { return false; } key.to = key.from + (key.length || 1) - 1; } } if(++key[__offset] > key.to) { key[__offset] = key.from - 1; return false; } return true; } return false; } },{"../internal/offset":72,"./is-object":122}],129:[function(_dereq_,module,exports){ var $path = _dereq_("../types/path"); var __parent = _dereq_("../internal/parent"); var unlink = _dereq_("./unlink"); var delete_back_refs = _dereq_("./delete-back-refs"); var splice = _dereq_("../lru/splice"); var is_object = _dereq_("./is-object"); module.exports = function(parent, node, key, lru) { if(is_object(node)) { var type = node.$type; if(!!type) { if(type == $path) { unlink(node); } splice(lru, node); } delete_back_refs(node); parent[key] = node[__parent] = undefined; return true; } return false; } },{"../internal/parent":73,"../lru/splice":88,"../types/path":140,"./delete-back-refs":115,"./is-object":122,"./unlink":135}],130:[function(_dereq_,module,exports){ var transfer_back_refs = _dereq_("./transfer-back-refs"); var invalidate_node = _dereq_("./invalidate-node"); module.exports = function(parent, node, replacement, key, lru) { if(node != null && node !== replacement && typeof node == "object") { transfer_back_refs(node, replacement); invalidate_node(parent, node, key, lru); } return parent[key] = replacement; } },{"./invalidate-node":120,"./transfer-back-refs":131}],131:[function(_dereq_,module,exports){ var __ref = _dereq_("../internal/ref"); var __context = _dereq_("../internal/context"); var __refs_length = _dereq_("../internal/refs-length"); module.exports = function(node, dest) { var nodeRefsLength = node[__refs_length] || 0, destRefsLength = dest[__refs_length] || 0, i = -1, ref; while(++i < nodeRefsLength) { ref = node[__ref + i]; if(ref !== undefined) { ref[__context] = dest; dest[__ref + (destRefsLength + i)] = ref; node[__ref + i] = undefined; } } dest[__refs_length] = nodeRefsLength + destRefsLength; node[__refs_length] = ref = undefined; } },{"../internal/context":66,"../internal/ref":77,"../internal/refs-length":78}],132:[function(_dereq_,module,exports){ var $error = _dereq_("../types/error"); var promote = _dereq_("../lru/promote"); var array_clone = _dereq_("./array-clone"); module.exports = function(roots, node, type, path) { if(node == null) { return false; } promote(roots.lru, node); if(type != $error || roots.errorsAsValues) { return false; } roots.errors.push({ path: array_clone(path), value: node.value }); return true; }; },{"../lru/promote":87,"../types/error":139,"./array-clone":104}],133:[function(_dereq_,module,exports){ var $sentinel = _dereq_("../types/sentinel"); var clone_misses = _dereq_("./clone-missing-path-maps"); var is_expired = _dereq_("./is-expired"); module.exports = function(roots, node, type, pathmap, keys_stack, depth, requested, optimized) { var dematerialized = !roots.materialized; if(node == null && dematerialized) { clone_misses(roots, pathmap, keys_stack, depth, requested, optimized); return true; } else if(!!type) { if(type == $sentinel && node.value === undefined && dematerialized && !roots.boxed) { return true; } else if(is_expired(roots, node)) { clone_misses(roots, pathmap, keys_stack, depth, requested, optimized); return true; } } return false; }; },{"../types/sentinel":141,"./clone-missing-path-maps":108,"./is-expired":121}],134:[function(_dereq_,module,exports){ var $sentinel = _dereq_("../types/sentinel"); var clone_misses = _dereq_("./clone-missing-path-sets"); var is_expired = _dereq_("./is-expired"); module.exports = function(roots, node, type, pathset, depth, requested, optimized) { var dematerialized = !roots.materialized; if(node == null && dematerialized) { clone_misses(roots, pathset, depth, requested, optimized); return true; } else if(!!type) { if(type == $sentinel && node.value === undefined && dematerialized && !roots.boxed) { return true; } else if(is_expired(roots, node)) { clone_misses(roots, pathset, depth, requested, optimized); return true; } } return false; }; },{"../types/sentinel":141,"./clone-missing-path-sets":109,"./is-expired":121}],135:[function(_dereq_,module,exports){ var __ref = _dereq_("../internal/ref"); var __context = _dereq_("../internal/context"); var __ref_index = _dereq_("../internal/ref-index"); var __refs_length = _dereq_("../internal/refs-length"); module.exports = function(ref) { var destination = ref[__context]; if(destination) { var i = (ref[__ref_index] || 0) - 1, n = (destination[__refs_length] || 0) - 1; while(++i <= n) { destination[__ref + i] = destination[__ref + (i + 1)]; } destination[__refs_length] = n; ref[__ref_index] = ref[__context] = destination = undefined; } } },{"../internal/context":66,"../internal/ref":77,"../internal/ref-index":76,"../internal/refs-length":78}],136:[function(_dereq_,module,exports){ module.exports = update_back_refs; var __ref = _dereq_("../internal/ref"); var __parent = _dereq_("../internal/parent"); var __version = _dereq_("../internal/version"); var __generation = _dereq_("../internal/generation"); var __refs_length = _dereq_("../internal/refs-length"); var generation = _dereq_("./inc-generation"); function update_back_refs(node, version) { if(node && node[__version] !== version) { node[__version] = version; node[__generation] = generation(); update_back_refs(node[__parent], version); var i = -1, n = node[__refs_length] || 0; while(++i < n) { update_back_refs(node[__ref + i], version); } } return node; } },{"../internal/generation":67,"../internal/parent":73,"../internal/ref":77,"../internal/refs-length":78,"../internal/version":80,"./inc-generation":118}],137:[function(_dereq_,module,exports){ var __key = _dereq_("../internal/key"); var __version = _dereq_("../internal/version"); var __parent = _dereq_("../internal/parent"); var remove_node = _dereq_("./remove-node"); var update_back_refs = _dereq_("./update-back-refs"); module.exports = function(node, offset, version, lru) { var child; while(child = node) { node = child[__parent]; if((child.$size = (child.$size || 0) - offset) <= 0 && node != null) { remove_node(node, child, child[__key], lru); } else if(child[__version] !== version) { update_back_refs(child, version); } } } },{"../internal/key":70,"../internal/parent":73,"../internal/version":80,"./remove-node":129,"./update-back-refs":136}],138:[function(_dereq_,module,exports){ var $path = _dereq_("../types/path"); var $error = _dereq_("../types/error"); var $sentinel = _dereq_("../types/sentinel"); var now = _dereq_("./now"); var clone = _dereq_("./clone"); var is_array = Array.isArray; var is_object = _dereq_("./is-object"); module.exports = function(node, type, value) { var dest = node, size = 0; if(!!type) { dest = clone(node); size = dest.$size; // } // if(type == $path) { // dest = clone(node); // size = 50 + (value.length || 1); // } else if(is_object(node) && (type || (type = node.$type))) { // dest = clone(node); // size = dest.$size; } else { dest = { value: value }; type = $sentinel; } if(size <= 0 || size == null) { switch(typeof value) { case "number": case "boolean": case "function": case "undefined": size = 51; break; case "object": size = is_array(value) && (50 + value.length) || 51; break; case "string": size = 50 + value.length; break; } } var expires = is_object(node) && node.$expires || undefined; if(typeof expires === "number" && expires < 0) { dest.$expires = now() + (expires * -1); } dest.$type = type; dest.$size = size; return dest; } },{"../types/error":139,"../types/path":140,"../types/sentinel":141,"./clone":113,"./is-object":122,"./now":126}],139:[function(_dereq_,module,exports){ module.exports = "error"; },{}],140:[function(_dereq_,module,exports){ module.exports = "ref"; },{}],141:[function(_dereq_,module,exports){ module.exports = "sentinel"; },{}],142:[function(_dereq_,module,exports){ module.exports = 1; },{}],143:[function(_dereq_,module,exports){ module.exports = 0; },{}],144:[function(_dereq_,module,exports){ module.exports = walk_path_map; var prefix = _dereq_("../internal/prefix"); var $path = _dereq_("../types/path"); var walk_reference = _dereq_("./walk-reference"); var array_slice = _dereq_("../support/array-slice"); var array_clone = _dereq_("../support/array-clone"); var array_append = _dereq_("../support/array-append"); var is_expired = _dereq_("../support/is-expired"); var is_primitive = _dereq_("../support/is-primitive"); var is_object = _dereq_("../support/is-object"); var is_array = Array.isArray; var promote = _dereq_("../lru/promote"); function walk_path_map(onNode, onEdge, pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset, is_keyset) { var node = nodes[0]; if(is_primitive(pathmap) || is_primitive(node)) { return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset); } var type = node.$type; while(type === $path) { if(is_expired(roots, node)) { nodes[0] = undefined; return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset); } promote(roots.lru, node); var container = node; var reference = node.value; nodes[0] = parents[0] = roots[0]; nodes[1] = parents[1] = roots[1]; nodes[2] = parents[2] = roots[2]; walk_reference(onNode, container, reference, roots, parents, nodes, requested, optimized); node = nodes[0]; if(node == null) { return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset); } else if(is_primitive(node) || ((type = node.$type) && type != $path)) { onNode(pathmap, roots, parents, nodes, requested, optimized, true, null, keyset, false); return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, array_append(requested, null), optimized, key, keyset); } } if(type != null) { return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset); } var keys = keys_stack[depth] = Object.keys(pathmap); if(keys.length == 0) { return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset); } var is_outer_keyset = keys.length > 1; for(var i = -1, n = keys.length; ++i < n;) { var inner_key = keys[i]; if((inner_key[0] === prefix) || (inner_key[0] === "$")) { continue; } var inner_keyset = is_outer_keyset ? inner_key : keyset; var nodes2 = array_clone(nodes); var parents2 = array_clone(parents); var pathmap2 = pathmap[inner_key]; var requested2, optimized2, is_branch; var has_child_key = false; var is_branch = is_object(pathmap2) && !pathmap2.$type;// && !is_array(pathmap2); if(is_branch) { for(child_key in pathmap2) { if((child_key[0] === prefix) || (child_key[0] === "$")) { continue; } child_key = pathmap2.hasOwnProperty(child_key); break; } is_branch = child_key === true; } if(inner_key == "null") { requested2 = array_append(requested, null); optimized2 = array_clone(optimized); inner_key = key; inner_keyset = keyset; pathmap2 = pathmap; onNode(pathmap2, roots, parents2, nodes2, requested2, optimized2, true, is_branch, null, inner_keyset, false); } else { requested2 = array_append(requested, inner_key); optimized2 = array_append(optimized, inner_key); onNode(pathmap2, roots, parents2, nodes2, requested2, optimized2, true, is_branch, inner_key, inner_keyset, is_outer_keyset); } if(is_branch) { walk_path_map(onNode, onEdge, pathmap2, keys_stack, depth + 1, roots, parents2, nodes2, requested2, optimized2, inner_key, inner_keyset, is_outer_keyset ); } else { onEdge(pathmap2, keys_stack, depth, roots, parents2, nodes2, requested2, optimized2, inner_key, inner_keyset); } } } },{"../internal/prefix":74,"../lru/promote":87,"../support/array-append":103,"../support/array-clone":104,"../support/array-slice":105,"../support/is-expired":121,"../support/is-object":122,"../support/is-primitive":123,"../types/path":140,"./walk-reference":148}],145:[function(_dereq_,module,exports){ module.exports = walk_path_map; var prefix = _dereq_("../internal/prefix"); var __context = _dereq_("../internal/context"); var $path = _dereq_("../types/path"); var walk_reference = _dereq_("./walk-reference"); var array_slice = _dereq_("../support/array-slice"); var array_clone = _dereq_("../support/array-clone"); var array_append = _dereq_("../support/array-append"); var is_expired = _dereq_("../support/is-expired"); var is_primitive = _dereq_("../support/is-primitive"); var is_object = _dereq_("../support/is-object"); var is_array = Array.isArray; var promote = _dereq_("../lru/promote"); function walk_path_map(onNode, onEdge, pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset, is_keyset) { var node = nodes[0]; if(is_primitive(pathmap) || is_primitive(node)) { return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset); } var type = node.$type; while(type === $path) { if(is_expired(roots, node)) { nodes[0] = undefined; return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset); } promote(roots.lru, node); var container = node; var reference = node.value; node = node[__context]; if(node != null) { type = node.$type; optimized = array_clone(reference); nodes[0] = node; } else { nodes[0] = parents[0] = roots[0]; walk_reference(onNode, container, reference, roots, parents, nodes, requested, optimized); node = nodes[0]; if(node == null) { return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset); } else if(is_primitive(node) || ((type = node.$type) && type != $path)) { onNode(pathmap, roots, parents, nodes, requested, optimized, true, null, keyset, false); return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, array_append(requested, null), optimized, key, keyset); } } } if(type != null) { return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset); } var keys = keys_stack[depth] = Object.keys(pathmap); if(keys.length == 0) { return onEdge(pathmap, keys_stack, depth, roots, parents, nodes, requested, optimized, key, keyset); } var is_outer_keyset = keys.length > 1; for(var i = -1, n = keys.length; ++i < n;) { var inner_key = keys[i]; if((inner_key[0] === prefix) || (inner_key[0] === "$")) { continue; } var inner_keyset = is_outer_keyset ? inner_key : keyset; var nodes2 = array_clone(nodes); var parents2 = array_clone(parents); var pathmap2 = pathmap[inner_key]; var requested2, optimized2, is_branch; var child_key = false; var is_branch = is_object(pathmap2) && !pathmap2.$type;// && !is_array(pathmap2); if(is_branch) { for(child_key in pathmap2) { if((child_key[0] === prefix) || (child_key[0] === "$")) { continue; } child_key = pathmap2.hasOwnProperty(child_key); break; } is_branch = child_key === true; } if(inner_key == "null") { requested2 = array_append(requested, null); optimized2 = array_clone(optimized); inner_key = key; inner_keyset = keyset; pathmap2 = pathmap; onNode(pathmap2, roots, parents2, nodes2, requested2, optimized2, true, is_branch, null, inner_keyset, false); } else { requested2 = array_append(requested, inner_key); optimized2 = array_append(optimized, inner_key); onNode(pathmap2, roots, parents2, nodes2, requested2, optimized2, true, is_branch, inner_key, inner_keyset, is_outer_keyset); } if(is_branch) { walk_path_map(onNode, onEdge, pathmap2, keys_stack, depth + 1, roots, parents2, nodes2, requested2, optimized2, inner_key, inner_keyset, is_outer_keyset ); } else { onEdge(pathmap2, keys_stack, depth, roots, parents2, nodes2, requested2, optimized2, inner_key, inner_keyset); } } } },{"../internal/context":66,"../internal/prefix":74,"../lru/promote":87,"../support/array-append":103,"../support/array-clone":104,"../support/array-slice":105,"../support/is-expired":121,"../support/is-object":122,"../support/is-primitive":123,"../types/path":140,"./walk-reference":148}],146:[function(_dereq_,module,exports){ module.exports = walk_path_set; var $path = _dereq_("../types/path"); var empty_array = new Array(0); var walk_reference = _dereq_("./walk-reference"); var array_slice = _dereq_("../support/array-slice"); var array_clone = _dereq_("../support/array-clone"); var array_append = _dereq_("../support/array-append"); var is_expired = _dereq_("../support/is-expired"); var is_primitive = _dereq_("../support/is-primitive"); var is_object = _dereq_("../support/is-object"); var keyset_to_key = _dereq_("../support/keyset-to-key"); var permute_keyset = _dereq_("../support/permute-keyset"); var promote = _dereq_("../lru/promote"); function walk_path_set(onNode, onEdge, pathset, depth, roots, parents, nodes, requested, optimized, key, keyset, is_keyset) { var node = nodes[0]; if(depth >= pathset.length || is_primitive(node)) { return onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset); } var type = node.$type; while(type === $path) { if(is_expired(roots, node)) { nodes[0] = undefined; return onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset); } promote(roots.lru, node); var container = node; var reference = node.value; nodes[0] = parents[0] = roots[0]; nodes[1] = parents[1] = roots[1]; nodes[2] = parents[2] = roots[2]; walk_reference(onNode, container, reference, roots, parents, nodes, requested, optimized); node = nodes[0]; if(node == null) { return onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset); } else if(is_primitive(node) || ((type = node.$type) && type != $path)) { onNode(pathset, roots, parents, nodes, requested, optimized, true, false, null, keyset, false); return onEdge(pathset, depth, roots, parents, nodes, array_append(requested, null), optimized, key, keyset); } } if(type != null) { return onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset); } var outer_key = pathset[depth]; var is_outer_keyset = is_object(outer_key); var is_branch = depth < pathset.length - 1; var run_once = false; while(is_outer_keyset && permute_keyset(outer_key) && (run_once = true) || (run_once = !run_once)) { var inner_key, inner_keyset; if(is_outer_keyset === true) { inner_key = keyset_to_key(outer_key, true); inner_keyset = inner_key; } else { inner_key = outer_key; inner_keyset = keyset; } var nodes2 = array_clone(nodes); var parents2 = array_clone(parents); var requested2, optimized2; if(inner_key == null) { requested2 = array_append(requested, null); optimized2 = array_clone(optimized); // optimized2 = optimized; inner_key = key; inner_keyset = keyset; onNode(pathset, roots, parents2, nodes2, requested2, optimized2, true, is_branch, null, inner_keyset, false); } else { requested2 = array_append(requested, inner_key); optimized2 = array_append(optimized, inner_key); onNode(pathset, roots, parents2, nodes2, requested2, optimized2, true, is_branch, inner_key, inner_keyset, is_outer_keyset); } walk_path_set(onNode, onEdge, pathset, depth + 1, roots, parents2, nodes2, requested2, optimized2, inner_key, inner_keyset, is_outer_keyset ); } } },{"../lru/promote":87,"../support/array-append":103,"../support/array-clone":104,"../support/array-slice":105,"../support/is-expired":121,"../support/is-object":122,"../support/is-primitive":123,"../support/keyset-to-key":124,"../support/permute-keyset":128,"../types/path":140,"./walk-reference":148}],147:[function(_dereq_,module,exports){ module.exports = walk_path_set; var prefix = _dereq_("../internal/prefix"); var __context = _dereq_("../internal/context"); var $path = _dereq_("../types/path"); var empty_array = new Array(0); var walk_reference = _dereq_("./walk-reference"); var array_slice = _dereq_("../support/array-slice"); var array_clone = _dereq_("../support/array-clone"); var array_append = _dereq_("../support/array-append"); var is_expired = _dereq_("../support/is-expired"); var is_primitive = _dereq_("../support/is-primitive"); var is_object = _dereq_("../support/is-object"); var keyset_to_key = _dereq_("../support/keyset-to-key"); var permute_keyset = _dereq_("../support/permute-keyset"); var promote = _dereq_("../lru/promote"); function walk_path_set(onNode, onEdge, pathset, depth, roots, parents, nodes, requested, optimized, key, keyset, is_keyset) { var node = nodes[0]; if(depth >= pathset.length || is_primitive(node)) { return onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset); } var type = node.$type; while(type === $path) { if(is_expired(roots, node)) { nodes[0] = undefined; return onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset); } promote(roots.lru, node); var container = node; var reference = node.value; node = node[__context]; if(node != null) { type = node.$type; optimized = array_clone(reference); nodes[0] = node; } else { nodes[0] = parents[0] = roots[0]; // nodes[1] = parents[1] = roots[1]; // nodes[2] = parents[2] = roots[2]; walk_reference(onNode, container, reference, roots, parents, nodes, requested, optimized); node = nodes[0]; if(node == null) { return onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset); } else if(is_primitive(node) || ((type = node.$type) && type != $path)) { onNode(pathset, roots, parents, nodes, requested, optimized, true, false, null, keyset, false); return onEdge(pathset, depth, roots, parents, nodes, array_append(requested, null), optimized, key, keyset); } } } if(type != null) { return onEdge(pathset, depth, roots, parents, nodes, requested, optimized, key, keyset); } var outer_key = pathset[depth]; var is_outer_keyset = is_object(outer_key); var is_branch = depth < pathset.length - 1; var run_once = false; while(is_outer_keyset && permute_keyset(outer_key) && (run_once = true) || (run_once = !run_once)) { var inner_key, inner_keyset; if(is_outer_keyset === true) { inner_key = keyset_to_key(outer_key, true); inner_keyset = inner_key; } else { inner_key = outer_key; inner_keyset = keyset; } var nodes2 = array_clone(nodes); var parents2 = array_clone(parents); var requested2, optimized2; if(inner_key == null) { requested2 = array_append(requested, null); optimized2 = array_clone(optimized); // optimized2 = optimized; inner_key = key; inner_keyset = keyset; onNode(pathset, roots, parents2, nodes2, requested2, optimized2, true, is_branch, null, inner_keyset, false); } else { requested2 = array_append(requested, inner_key); optimized2 = array_append(optimized, inner_key); onNode(pathset, roots, parents2, nodes2, requested2, optimized2, true, is_branch, inner_key, inner_keyset, is_outer_keyset); } walk_path_set(onNode, onEdge, pathset, depth + 1, roots, parents2, nodes2, requested2, optimized2, inner_key, inner_keyset, is_outer_keyset ); } } },{"../internal/context":66,"../internal/prefix":74,"../lru/promote":87,"../support/array-append":103,"../support/array-clone":104,"../support/array-slice":105,"../support/is-expired":121,"../support/is-object":122,"../support/is-primitive":123,"../support/keyset-to-key":124,"../support/permute-keyset":128,"../types/path":140,"./walk-reference":148}],148:[function(_dereq_,module,exports){ module.exports = walk_reference; var prefix = _dereq_("../internal/prefix"); var __ref = _dereq_("../internal/ref"); var __context = _dereq_("../internal/context"); var __ref_index = _dereq_("../internal/ref-index"); var __refs_length = _dereq_("../internal/refs-length"); var is_object = _dereq_("../support/is-object"); var is_primitive = _dereq_("../support/is-primitive"); var array_slice = _dereq_("../support/array-slice"); var array_append = _dereq_("../support/array-append"); function walk_reference(onNode, container, reference, roots, parents, nodes, requested, optimized) { optimized.length = 0; var index = -1; var count = reference.length; var node, key, keyset; while(++index < count) { node = nodes[0]; if(node == null) { return nodes; } else if(is_primitive(node) || node.$type) { onNode(reference, roots, parents, nodes, requested, optimized, false, false, keyset, null, false); return nodes; } do { key = reference[index]; if(key != null) { keyset = key; optimized.push(key); onNode(reference, roots, parents, nodes, requested, optimized, false, index < count - 1, key, null, false); break; } } while(++index < count); } node = nodes[0]; if(is_object(node) && container[__context] !== node) { var backrefs = node[__refs_length] || 0; node[__refs_length] = backrefs + 1; node[__ref + backrefs] = container; container[__context] = node; container[__ref_index] = backrefs; } return nodes; } },{"../internal/context":66,"../internal/prefix":74,"../internal/ref":77,"../internal/ref-index":76,"../internal/refs-length":78,"../support/array-append":103,"../support/array-slice":105,"../support/is-object":122,"../support/is-primitive":123}],149:[function(_dereq_,module,exports){ var falcor = _dereq_('./lib/falcor'); var get = _dereq_('./lib/get'); var set = _dereq_('./lib/set'); var inv = _dereq_('./lib/invalidate'); var prototype = falcor.Model.prototype; prototype._getBoundValue = get.getBoundValue; prototype._getValueSync = get.getValueSync; prototype._getPathSetsAsValues = get.getAsValues; prototype._getPathSetsAsJSON = get.getAsJSON; prototype._getPathSetsAsPathMap = get.getAsPathMap; prototype._getPathSetsAsJSONG = get.getAsJSONG; prototype._getPathMapsAsValues = get.getAsValues; prototype._getPathMapsAsJSON = get.getAsJSON; prototype._getPathMapsAsPathMap = get.getAsPathMap; prototype._getPathMapsAsJSONG = get.getAsJSONG; prototype._setPathSetsAsJSON = set.setPathSetsAsJSON; prototype._setPathSetsAsJSONG = set.setPathSetsAsJSONG; prototype._setPathSetsAsPathMap = set.setPathSetsAsPathMap; prototype._setPathSetsAsValues = set.setPathSetsAsValues; prototype._setPathMapsAsJSON = set.setPathMapsAsJSON; prototype._setPathMapsAsJSONG = set.setPathMapsAsJSONG; prototype._setPathMapsAsPathMap = set.setPathMapsAsPathMap; prototype._setPathMapsAsValues = set.setPathMapsAsValues; prototype._setJSONGsAsJSON = set.setJSONGsAsJSON; prototype._setJSONGsAsJSONG = set.setJSONGsAsJSONG; prototype._setJSONGsAsPathMap = set.setJSONGsAsPathMap; prototype._setJSONGsAsValues = set.setJSONGsAsValues; prototype._invPathSetsAsJSON = inv.invPathSetsAsJSON; prototype._invPathSetsAsJSONG = inv.invPathSetsAsJSONG; prototype._invPathSetsAsPathMap = inv.invPathSetsAsPathMap; prototype._invPathSetsAsValues = inv.invPathSetsAsValues; // prototype._setCache = get.setCache; prototype._setCache = set.setCache; module.exports = falcor; },{"./lib/falcor":5,"./lib/get":52,"./lib/invalidate":81,"./lib/set":89}]},{},[1]) (1) }); }).call(this,typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {}) },{}],149:[function(require,module,exports){ var falcor = require('falcor'); var Observable = falcor.Observable; function XMLHttpSource(jsongUrl, timeout) { this._jsongUrl = jsongUrl; this._timeout = timeout || 15000; } XMLHttpSource.prototype = { /** * @inheritDoc DataSource#get */ get: function (pathSet) { var method = 'GET'; var config = buildQueryObject(this._jsongUrl, method, { path: pathSet, method: 'get' }); return request(method, config); }, /** * @inheritDoc DataSource#set */ set: function () { // TODO: What to send what to send }, /** * @inheritDoc DataSource#call */ call: function (callPath, args, pathSuffix, paths) { var method = 'GET'; var queryData = []; args = args || []; pathSuffix = pathSuffix || []; paths = paths || []; paths.forEach(function (path) { queryData.push('path=' + encodeURIComponent(JSON.stringify(path))); }); queryData.push('method=call'); queryData.push('callPath=' + encodeURIComponent(JSON.stringify(callPath))); if (Array.isArray(args)) { args.forEach(function (value) { queryData.push('param=' + encodeURIComponent(JSON.stringify(value))); }); } if (Array.isArray(pathSuffix)) { pathSuffix.forEach(function (value) { queryData.push('pathSuffix=' + encodeURIComponent(JSON.stringify(value))); }); } var config = buildQueryObject(this._jsongUrl, method, queryData.join('&')); return request(method, config); } }; function request(method, config) { return Observable.create(function (observer) { // i have to actual work now :( var xhr = new XMLHttpRequest(); // Link the response methods xhr.onload = onXhrLoad.bind(null, observer, xhr); xhr.onerror = onXhrError.bind(null, observer, xhr); xhr.ontimeout = onXhrTimeout.bind(null, observer, xhr); // Sets information xhr.timeout = config.timeout; // Anything but explicit false results in true. xhr.withCredentials = !(config.withCredentials === false); xhr.responseType = 'json'; // Takes the url and opens the connection xhr.open(method, config.url); // Fills the request headers var requestHeaders = config.requestHeaders || {}; var keys = Object.keys(requestHeaders); keys.forEach(function (k) { xhr.setRequestHeader(k, requestHeaders[k]); }); // Sends the request. xhr.send(config.data); return function () { // TODO: Dispose of request. }; }); } /* * General handling of a successfully completed request (that had a 200 response code) */ function _handleXhrComplete(observer, data) { observer.onNext(data); observer.onCompleted(); } /* * General handling of ultimate failure (after appropriate retries) */ function _handleXhrError(observer, textStatus, errorThrown) { if (!errorThrown) { errorThrown = new Error(textStatus); } observer.onError(errorThrown); } function onXhrLoad(observer, xhr) { var status, responseData, responseObject; // If there's no observer, the request has been (or is being) cancelled. if (xhr && observer) { status = xhr.status; responseData = xhr.responseText; if (status >= 200 && status <= 399) { try { responseData = JSON.parse(responseData || ''); } catch (e) { _handleXhrError(observer, 'invalid json', e); } _handleXhrComplete(observer, responseData); } else if (status === 401 || status === 403 || status === 407) { _handleXhrError(observer, responseData); } else if (status === 410) { // TODO: Retry ? _handleXhrError(observer, responseData); } else if (status === 408 || status === 504) { // TODO: Retry ? _handleXhrError(observer, responseData); } else { _handleXhrError(observer, responseData || ('Response code ' + status)); } } } function onXhrError(observer, xhr) { _handleXhrError(observer, xhr.statusText || 'request error'); } function onXhrTimeout(observer) { _handleXhrError(observer, 'request timeout'); } function buildQueryObject(url, method, queryData) { var qData = []; var keys; var data = {url: url}; if (typeof queryData === 'string') { qData.push(queryData); } else { keys = Object.keys(queryData); keys.forEach(function (k) { var value = typeof queryData[k] === 'object' ? JSON.stringify(queryData[k]) : queryData[k]; qData.push(k + '=' + value); }); } if (method === 'GET') { data.url += '?' + qData.join('&'); } else { data.data = qData.join('&'); } return data; } module.exports = XMLHttpSource; },{"falcor":148}],150:[function(require,module,exports){ var TokenTypes = { token: 'token', dotSeparator: '.', commaSeparator: ',', openingBracket: '[', closingBracket: ']', openingBrace: '{', closingBrace: '}', escape: '\\', space: ' ', quote: 'quote', unknown: 'unknown' }; module.exports = TokenTypes; },{}],151:[function(require,module,exports){ module.exports = { indexer: { nested: 'Indexers cannot be nested.', needQuotes: 'unquoted indexers must be numeric.', empty: 'cannot have empty indexers.', leadingDot: 'Indexers cannot have leading dots.', leadingComma: 'Indexers cannot have leading comma.', requiresComma: 'Indexers require commas between indexer args.' }, range: { precedingNaN: 'ranges must be preceded by numbers.', suceedingNaN: 'ranges must be suceeded by numbers.' }, quote: { empty: 'cannot have empty quoted keys.', illegalEscape: 'Invalid escape character. Only quotes are escapable.' }, unexpectedToken: 'Unexpected token.', throwError: function(err, state, token) { if (token) { throw err + ' -- ' + state.parseString + ' with next token: ' + token; } throw err + ' -- ' + state.parseString; } }; },{}],152:[function(require,module,exports){ var Tokenizer = require('./tokenizer'); var head = require('./parse-tree/head'); var parser = function parser(string, extendedRules) { return head(new Tokenizer(string, extendedRules)); }; module.exports = parser; // Constructs the paths from paths / pathValues that have strings. // If it does not have a string, just moves the value into the return // results. parser.fromPathsOrPathValues = function(paths, ext) { var out = []; for (i = 0, len = paths.length; i < len; i++) { // Is the path a string if (typeof paths[i] === 'string') { out[i] = parser(paths[i], ext); } // is the path a path value with a string value. else if (typeof paths[i].path === 'string') { out[i] = { path: parser(paths[i].path, ext), value: paths[i].value }; } // just copy it over. else { out[i] = paths[i]; } } return out; }; // If the argument is a string, this with convert, else just return // the path provided. parser.fromPath = function(path, ext) { if (typeof path === 'string') { return parser(path, ext); } return path; }; },{"./parse-tree/head":153,"./tokenizer":157}],153:[function(require,module,exports){ var TokenTypes = require('./../TokenTypes'); var Expections = require('./../exceptions'); var indexer = require('./indexer'); /** * The top level of the parse tree. This returns the generated path * from the tokenizer. */ module.exports = function head(tokenizer) { var token = tokenizer.next(); var first = true; var state = { parseString: '' }; var out = []; while (!token.done) { // continue to build the parse string. state.parseString += token.token; switch (token.type) { case TokenTypes.token: out[out.length] = token.token; break; // dotSeparators at the top level have no meaning case TokenTypes.dotSeparator: if (first) { // TODO: Fix me throw 'ohh no!'; } break; // Spaces do nothing. case TokenTypes.space: // NOTE: Spaces at the top level are allowed. // titlesById .summary is a valid path. break; // Its time to decend the parse tree. case TokenTypes.openingBracket: indexer(tokenizer, token, state, out); break; // TODO: Fix me default: throw 'ohh no!'; } first = false; // Keep cycling through the tokenizer. token = tokenizer.next(); } if (first) { // TODO: Ohh no! Fix me throw 'ohh no!'; } return out; }; },{"./../TokenTypes":150,"./../exceptions":151,"./indexer":154}],154:[function(require,module,exports){ var TokenTypes = require('./../TokenTypes'); var E = require('./../exceptions'); var idxE = E.indexer; var range = require('./range'); var quote = require('./quote'); /** * The indexer is all the logic that happens in between * the '[', opening bracket, and ']' closing bracket. */ module.exports = function indexer(tokenizer, openingToken, state, out) { var token = tokenizer.next(); var done = false; var allowedMaxLength = 1; // State variables state.indexer = []; while (!token.done) { // continue to build the parse string. state.parseString += token.token; switch (token.type) { case TokenTypes.token: case TokenTypes.quote: // ensures that token adders are properly delimited. if (state.indexer.length === allowedMaxLength) { E.throwError(idxE.requiresComma, state); } break; } switch (token.type) { case TokenTypes.token: var t = +token.token; if (isNaN(t)) { E.throwError(idxE.needQuotes, state); } state.indexer[state.indexer.length] = t; break; // dotSeparators at the top level have no meaning case TokenTypes.dotSeparator: if (!state.indexer.length) { E.throwError(idxE.leadingDot, state); } range(tokenizer, token, state, out); break; // Spaces do nothing. case TokenTypes.space: break; case TokenTypes.closingBracket: done = true; break; // The quotes require their own tree due to what can be in it. case TokenTypes.quote: quote(tokenizer, token, state, out); break; // Its time to decend the parse tree. case TokenTypes.openingBracket: E.throwError(idxE.nested, state); break; case TokenTypes.commaSeparator: ++allowedMaxLength; break; default: E.throwError(idxE.unexpectedToken, state); } // If done, leave loop if (done) { break; } // Keep cycling through the tokenizer. token = tokenizer.next(); } if (state.indexer.length === 0) { E.throwError(idxE.empty, state); } // Remember, if an array of 1, keySets will be generated. if (state.indexer.length === 1) { state.indexer = state.indexer[0]; } out[out.length] = state.indexer; // Clean state. state.indexer = undefined; }; },{"./../TokenTypes":150,"./../exceptions":151,"./quote":155,"./range":156}],155:[function(require,module,exports){ var TokenTypes = require('./../TokenTypes'); var E = require('./../exceptions'); var quoteE = E.quote; /** * The indexer is all the logic that happens in between * the '[', opening bracket, and ']' closing bracket. */ module.exports = function quote(tokenizer, openingToken, state, out) { var token = tokenizer.next(); var innerToken = ''; var openingQuote = openingToken.token; var escaping = false; var done = false; while (!token.done) { // continue to build the parse string. state.parseString += token.token; switch (token.type) { case TokenTypes.token: case TokenTypes.space: case TokenTypes.dotSeparator: case TokenTypes.commaSeparator: case TokenTypes.openingBracket: case TokenTypes.closingBracket: case TokenTypes.openingBrace: case TokenTypes.closingBrace: if (escaping) { E.throwError(quoteE.illegalEscape, state); } innerToken += token.token; break; case TokenTypes.quote: // the simple case. We are escaping if (escaping) { innerToken += token.token; escaping = false; } // its not a quote that is the opening quote else if (token.token !== openingQuote) { innerToken += token.token; } // last thing left. Its a quote that is the opening quote // therefore we must produce the inner token of the indexer. else { done = true; } break; case TokenTypes.escape: escaping = true; break; default: E.throwError(E.unexpectedToken, state); } // If done, leave loop if (done) { break; } // Keep cycling through the tokenizer. token = tokenizer.next(); } if (innerToken.length === 0) { E.throwError(quoteE.empty, state); } state.indexer[state.indexer.length] = innerToken; }; },{"./../TokenTypes":150,"./../exceptions":151}],156:[function(require,module,exports){ var Tokenizer = require('./../tokenizer'); var TokenTypes = require('./../TokenTypes'); var E = require('./../exceptions'); /** * The indexer is all the logic that happens in between * the '[', opening bracket, and ']' closing bracket. */ module.exports = function range(tokenizer, openingToken, state, out) { var token = tokenizer.peek(); var dotCount = 1; var done = false; var inclusive = true; // Grab the last token off the stack. Must be an integer. var idx = state.indexer.length - 1; var from = Tokenizer.toNumber(state.indexer[idx]); var to; if (isNaN(from)) { E.throwError(E.range.precedingNaN, state); } // Why is number checking so difficult in javascript. while (!done && !token.done) { switch (token.type) { // dotSeparators at the top level have no meaning case TokenTypes.dotSeparator: if (dotCount === 3) { E.throwError(E.unexpectedToken, state); } ++dotCount; if (dotCount === 3) { inclusive = false; } break; case TokenTypes.token: // move the tokenizer forward and save to. to = Tokenizer.toNumber(tokenizer.next().token); // continue to build the parse string. state.parseString += token.token; // throw potential error. if (isNaN(to)) { E.throwError(E.range.suceedingNaN, state); } done = true; break; default: done = true; break; } // Keep cycling through the tokenizer. But ranges have to peek // before they go to the next token since there is no 'terminating' // character. if (!done) { tokenizer.next(); // continue to build the parse string. state.parseString += token.token; // go to the next token without consuming. token = tokenizer.peek(); } // break and remove state information. else { break; } } state.indexer[idx] = {from: from, to: inclusive ? to : to - 1}; }; },{"./../TokenTypes":150,"./../exceptions":151,"./../tokenizer":157}],157:[function(require,module,exports){ var TokenTypes = require('./../TokenTypes'); var DOT_SEPARATOR = '.'; var COMMA_SEPARATOR = ','; var OPENING_BRACKET = '['; var CLOSING_BRACKET = ']'; var OPENING_BRACE = '{'; var CLOSING_BRACE = '}'; var ESCAPE = '\\'; var DOUBLE_OUOTES = '"'; var SINGE_OUOTES = "'"; var SPACE = " "; var SPECIAL_CHARACTERS = '\\\'"[]., '; var EXT_SPECIAL_CHARACTERS = '\\{}\'"[]., '; var Tokenizer = module.exports = function(string, ext) { this._string = string; this._idx = -1; this._extended = ext; }; Tokenizer.prototype = { /** * grabs the next token either from the peek operation or generates the * next token. */ next: function() { var nextToken = this._nextToken ? this._nextToken : getNext(this._string, this._idx, this._extended); this._idx = nextToken.idx; this._nextToken = false; return nextToken.token; }, /** * will peak but not increment the tokenizer */ peek: function() { var nextToken = this._nextToken ? this._nextToken : getNext(this._string, this._idx, this._extended); this._nextToken = nextToken; return nextToken.token; } }; Tokenizer.toNumber = function toNumber(x) { if (!isNaN(+x)) { return +x; } return NaN; }; function toOutput(token, type, done) { return { token: token, done: done, type: type }; } function getNext(string, idx, ext) { var output = false; var token = ''; var specialChars = ext ? EXT_SPECIAL_CHARACTERS : SPECIAL_CHARACTERS; do { done = idx + 1 >= string.length; if (done) { break; } // we have to peek at the next token var character = string[idx + 1]; if (character !== undefined && specialChars.indexOf(character) === -1) { token += character; ++idx; continue; } // The token to delimiting character transition. else if (token.length) { break; } ++idx; var type; switch (character) { case DOT_SEPARATOR: type = TokenTypes.dotSeparator; break; case COMMA_SEPARATOR: type = TokenTypes.commaSeparator; break; case OPENING_BRACKET: type = TokenTypes.openingBracket; break; case CLOSING_BRACKET: type = TokenTypes.closingBracket; break; case OPENING_BRACE: type = TokenTypes.openingBrace; break; case CLOSING_BRACE: type = TokenTypes.closingBrace; break; case SPACE: type = TokenTypes.space; break; case DOUBLE_OUOTES: case SINGE_OUOTES: type = TokenTypes.quote; break; case ESCAPE: type = TokenTypes.escape; break; default: type = TokenTypes.unknown; break; } output = toOutput(character, type, false); break; } while (!done); if (!output && token.length) { output = toOutput(token, TokenTypes.token, false); } if (!output) { output = {done: true}; } return { token: output, idx: idx }; } },{"./../TokenTypes":150}],158:[function(require,module,exports){ 'use strict'; module.exports = require('./lib') },{"./lib":163}],159:[function(require,module,exports){ 'use strict'; var asap = require('asap/raw') function noop() {}; // States: // // 0 - pending // 1 - fulfilled with _value // 2 - rejected with _value // 3 - adopted the state of another promise, _value // // once the state is no longer pending (0) it is immutable // All `_` prefixed properties will be reduced to `_{random number}` // at build time to obfuscate them and discourage their use. // We don't use symbols or Object.defineProperty to fully hide them // because the performance isn't good enough. // to avoid using try/catch inside critical functions, we // extract them to here. var LAST_ERROR = null; var IS_ERROR = {}; function getThen(obj) { try { return obj.then; } catch (ex) { LAST_ERROR = ex; return IS_ERROR; } } function tryCallOne(fn, a) { try { return fn(a); } catch (ex) { LAST_ERROR = ex; return IS_ERROR; } } function tryCallTwo(fn, a, b) { try { fn(a, b); } catch (ex) { LAST_ERROR = ex; return IS_ERROR; } } module.exports = Promise; function Promise(fn) { if (typeof this !== 'object') throw new TypeError('Promises must be constructed via new') if (typeof fn !== 'function') throw new TypeError('not a function') this._71 = 0; this._18 = null; this._61 = []; if (fn === noop) return; doResolve(fn, this); } Promise.prototype._10 = function (onFulfilled, onRejected) { var self = this; return new this.constructor(function (resolve, reject) { var res = new Promise(noop); res.then(resolve, reject); self._24(new Handler(onFulfilled, onRejected, res)); }); }; Promise.prototype.then = function(onFulfilled, onRejected) { if (this.constructor !== Promise) return this._10(onFulfilled, onRejected); var res = new Promise(noop); this._24(new Handler(onFulfilled, onRejected, res)); return res; }; Promise.prototype._24 = function(deferred) { if (this._71 === 3) { this._18._24(deferred); return; } if (this._71 === 0) { this._61.push(deferred); return; } var state = this._71; var value = this._18; asap(function() { var cb = state === 1 ? deferred.onFulfilled : deferred.onRejected if (cb === null) { (state === 1 ? deferred.promise._82(value) : deferred.promise._67(value)) return } var ret = tryCallOne(cb, value); if (ret === IS_ERROR) { deferred.promise._67(LAST_ERROR) } else { deferred.promise._82(ret) } }); }; Promise.prototype._82 = function(newValue) { //Promise Resolution Procedure: https://github.com/promises-aplus/promises-spec#the-promise-resolution-procedure if (newValue === this) { return this._67(new TypeError('A promise cannot be resolved with itself.')) } if (newValue && (typeof newValue === 'object' || typeof newValue === 'function')) { var then = getThen(newValue); if (then === IS_ERROR) { return this._67(LAST_ERROR); } if ( then === this.then && newValue instanceof Promise && newValue._24 === this._24 ) { this._71 = 3; this._18 = newValue; for (var i = 0; i < this._61.length; i++) { newValue._24(this._61[i]); } return; } else if (typeof then === 'function') { doResolve(then.bind(newValue), this) return } } this._71 = 1 this._18 = newValue this._94() } Promise.prototype._67 = function (newValue) { this._71 = 2 this._18 = newValue this._94() } Promise.prototype._94 = function () { for (var i = 0; i < this._61.length; i++) this._24(this._61[i]) this._61 = null } function Handler(onFulfilled, onRejected, promise){ this.onFulfilled = typeof onFulfilled === 'function' ? onFulfilled : null this.onRejected = typeof onRejected === 'function' ? onRejected : null this.promise = promise; } /** * Take a potentially misbehaving resolver function and make sure * onFulfilled and onRejected are only called once. * * Makes no guarantees about asynchrony. */ function doResolve(fn, promise) { var done = false; var res = tryCallTwo(fn, function (value) { if (done) return done = true promise._82(value) }, function (reason) { if (done) return done = true promise._67(reason) }) if (!done && res === IS_ERROR) { done = true promise._67(LAST_ERROR) } } },{"asap/raw":167}],160:[function(require,module,exports){ 'use strict'; var Promise = require('./core.js') module.exports = Promise Promise.prototype.done = function (onFulfilled, onRejected) { var self = arguments.length ? this.then.apply(this, arguments) : this self.then(null, function (err) { setTimeout(function () { throw err }, 0) }) } },{"./core.js":159}],161:[function(require,module,exports){ 'use strict'; //This file contains the ES6 extensions to the core Promises/A+ API var Promise = require('./core.js') var asap = require('asap/raw') module.exports = Promise /* Static Functions */ function ValuePromise(value) { this.then = function (onFulfilled) { if (typeof onFulfilled !== 'function') return this return new Promise(function (resolve, reject) { asap(function () { try { resolve(onFulfilled(value)) } catch (ex) { reject(ex); } }) }) } } ValuePromise.prototype = Promise.prototype var TRUE = new ValuePromise(true) var FALSE = new ValuePromise(false) var NULL = new ValuePromise(null) var UNDEFINED = new ValuePromise(undefined) var ZERO = new ValuePromise(0) var EMPTYSTRING = new ValuePromise('') Promise.resolve = function (value) { if (value instanceof Promise) return value if (value === null) return NULL if (value === undefined) return UNDEFINED if (value === true) return TRUE if (value === false) return FALSE if (value === 0) return ZERO if (value === '') return EMPTYSTRING if (typeof value === 'object' || typeof value === 'function') { try { var then = value.then if (typeof then === 'function') { return new Promise(then.bind(value)) } } catch (ex) { return new Promise(function (resolve, reject) { reject(ex) }) } } return new ValuePromise(value) } Promise.all = function (arr) { var args = Array.prototype.slice.call(arr) return new Promise(function (resolve, reject) { if (args.length === 0) return resolve([]) var remaining = args.length function res(i, val) { if (val && (typeof val === 'object' || typeof val === 'function')) { var then = val.then if (typeof then === 'function') { then.call(val, function (val) { res(i, val) }, reject) return } } args[i] = val if (--remaining === 0) { resolve(args); } } for (var i = 0; i < args.length; i++) { res(i, args[i]) } }) } Promise.reject = function (value) { return new Promise(function (resolve, reject) { reject(value); }); } Promise.race = function (values) { return new Promise(function (resolve, reject) { values.forEach(function(value){ Promise.resolve(value).then(resolve, reject); }) }); } /* Prototype Methods */ Promise.prototype['catch'] = function (onRejected) { return this.then(null, onRejected); } },{"./core.js":159,"asap/raw":167}],162:[function(require,module,exports){ 'use strict'; var Promise = require('./core.js') module.exports = Promise Promise.prototype['finally'] = function (f) { return this.then(function (value) { return Promise.resolve(f()).then(function () { return value }) }, function (err) { return Promise.resolve(f()).then(function () { throw err }) }) } },{"./core.js":159}],163:[function(require,module,exports){ 'use strict'; module.exports = require('./core.js') require('./done.js') require('./finally.js') require('./es6-extensions.js') require('./node-extensions.js') },{"./core.js":159,"./done.js":160,"./es6-extensions.js":161,"./finally.js":162,"./node-extensions.js":164}],164:[function(require,module,exports){ 'use strict'; //This file contains then/promise specific extensions that are only useful for node.js interop var Promise = require('./core.js') var asap = require('asap') module.exports = Promise /* Static Functions */ Promise.denodeify = function (fn, argumentCount) { argumentCount = argumentCount || Infinity return function () { var self = this var args = Array.prototype.slice.call(arguments) return new Promise(function (resolve, reject) { while (args.length && args.length > argumentCount) { args.pop() } args.push(function (err, res) { if (err) reject(err) else resolve(res) }) var res = fn.apply(self, args) if (res && (typeof res === 'object' || typeof res === 'function') && typeof res.then === 'function') { resolve(res) } }) } } Promise.nodeify = function (fn) { return function () { var args = Array.prototype.slice.call(arguments) var callback = typeof args[args.length - 1] === 'function' ? args.pop() : null var ctx = this try { return fn.apply(this, arguments).nodeify(callback, ctx) } catch (ex) { if (callback === null || typeof callback == 'undefined') { return new Promise(function (resolve, reject) { reject(ex) }) } else { asap(function () { callback.call(ctx, ex) }) } } } } Promise.prototype.nodeify = function (callback, ctx) { if (typeof callback != 'function') return this this.then(function (value) { asap(function () { callback.call(ctx, null, value) }) }, function (err) { asap(function () { callback.call(ctx, err) }) }) } },{"./core.js":159,"asap":165}],165:[function(require,module,exports){ "use strict"; // rawAsap provides everything we need except exception management. var rawAsap = require("./raw"); // RawTasks are recycled to reduce GC churn. var freeTasks = []; // We queue errors to ensure they are thrown in right order (FIFO). // Array-as-queue is good enough here, since we are just dealing with exceptions. var pendingErrors = []; var requestErrorThrow = rawAsap.makeRequestCallFromTimer(throwFirstError); function throwFirstError() { if (pendingErrors.length) { throw pendingErrors.shift(); } } /** * Calls a task as soon as possible after returning, in its own event, with priority * over other events like animation, reflow, and repaint. An error thrown from an * event will not interrupt, nor even substantially slow down the processing of * other events, but will be rather postponed to a lower priority event. * @param {{call}} task A callable object, typically a function that takes no * arguments. */ module.exports = asap; function asap(task) { var rawTask; if (freeTasks.length) { rawTask = freeTasks.pop(); } else { rawTask = new RawTask(); } rawTask.task = task; rawAsap(rawTask); } // We wrap tasks with recyclable task objects. A task object implements // `call`, just like a function. function RawTask() { this.task = null; } // The sole purpose of wrapping the task is to catch the exception and recycle // the task object after its single use. RawTask.prototype.call = function () { try { this.task.call(); } catch (error) { if (asap.onerror) { // This hook exists purely for testing purposes. // Its name will be periodically randomized to break any code that // depends on its existence. asap.onerror(error); } else { // In a web browser, exceptions are not fatal. However, to avoid // slowing down the queue of pending tasks, we rethrow the error in a // lower priority turn. pendingErrors.push(error); requestErrorThrow(); } } finally { this.task = null; freeTasks[freeTasks.length] = this; } }; },{"./raw":166}],166:[function(require,module,exports){ (function (global){ "use strict"; // Use the fastest means possible to execute a task in its own turn, with // priority over other events including IO, animation, reflow, and redraw // events in browsers. // // An exception thrown by a task will permanently interrupt the processing of // subsequent tasks. The higher level `asap` function ensures that if an // exception is thrown by a task, that the task queue will continue flushing as // soon as possible, but if you use `rawAsap` directly, you are responsible to // either ensure that no exceptions are thrown from your task, or to manually // call `rawAsap.requestFlush` if an exception is thrown. module.exports = rawAsap; function rawAsap(task) { if (!queue.length) { requestFlush(); flushing = true; } // Equivalent to push, but avoids a function call. queue[queue.length] = task; } var queue = []; // Once a flush has been requested, no further calls to `requestFlush` are // necessary until the next `flush` completes. var flushing = false; // `requestFlush` is an implementation-specific method that attempts to kick // off a `flush` event as quickly as possible. `flush` will attempt to exhaust // the event queue before yielding to the browser's own event loop. var requestFlush; // The position of the next task to execute in the task queue. This is // preserved between calls to `flush` so that it can be resumed if // a task throws an exception. var index = 0; // If a task schedules additional tasks recursively, the task queue can grow // unbounded. To prevent memory exhaustion, the task queue will periodically // truncate already-completed tasks. var capacity = 1024; // The flush function processes all tasks that have been scheduled with // `rawAsap` unless and until one of those tasks throws an exception. // If a task throws an exception, `flush` ensures that its state will remain // consistent and will resume where it left off when called again. // However, `flush` does not make any arrangements to be called again if an // exception is thrown. function flush() { while (index < queue.length) { var currentIndex = index; // Advance the index before calling the task. This ensures that we will // begin flushing on the next task the task throws an error. index = index + 1; queue[currentIndex].call(); // Prevent leaking memory for long chains of recursive calls to `asap`. // If we call `asap` within tasks scheduled by `asap`, the queue will // grow, but to avoid an O(n) walk for every task we execute, we don't // shift tasks off the queue after they have been executed. // Instead, we periodically shift 1024 tasks off the queue. if (index > capacity) { // Manually shift all values starting at the index back to the // beginning of the queue. for (var scan = 0; scan < index; scan++) { queue[scan] = queue[scan + index]; } queue.length -= index; index = 0; } } queue.length = 0; index = 0; flushing = false; } // `requestFlush` is implemented using a strategy based on data collected from // every available SauceLabs Selenium web driver worker at time of writing. // https://docs.google.com/spreadsheets/d/1mG-5UYGup5qxGdEMWkhP6BWCz053NUb2E1QoUTU16uA/edit#gid=783724593 // Safari 6 and 6.1 for desktop, iPad, and iPhone are the only browsers that // have WebKitMutationObserver but not un-prefixed MutationObserver. // Must use `global` instead of `window` to work in both frames and web // workers. `global` is a provision of Browserify, Mr, Mrs, or Mop. var BrowserMutationObserver = global.MutationObserver || global.WebKitMutationObserver; // MutationObservers are desirable because they have high priority and work // reliably everywhere they are implemented. // They are implemented in all modern browsers. // // - Android 4-4.3 // - Chrome 26-34 // - Firefox 14-29 // - Internet Explorer 11 // - iPad Safari 6-7.1 // - iPhone Safari 7-7.1 // - Safari 6-7 if (typeof BrowserMutationObserver === "function") { requestFlush = makeRequestCallFromMutationObserver(flush); // MessageChannels are desirable because they give direct access to the HTML // task queue, are implemented in Internet Explorer 10, Safari 5.0-1, and Opera // 11-12, and in web workers in many engines. // Although message channels yield to any queued rendering and IO tasks, they // would be better than imposing the 4ms delay of timers. // However, they do not work reliably in Internet Explorer or Safari. // Internet Explorer 10 is the only browser that has setImmediate but does // not have MutationObservers. // Although setImmediate yields to the browser's renderer, it would be // preferrable to falling back to setTimeout since it does not have // the minimum 4ms penalty. // Unfortunately there appears to be a bug in Internet Explorer 10 Mobile (and // Desktop to a lesser extent) that renders both setImmediate and // MessageChannel useless for the purposes of ASAP. // https://github.com/kriskowal/q/issues/396 // Timers are implemented universally. // We fall back to timers in workers in most engines, and in foreground // contexts in the following browsers. // However, note that even this simple case requires nuances to operate in a // broad spectrum of browsers. // // - Firefox 3-13 // - Internet Explorer 6-9 // - iPad Safari 4.3 // - Lynx 2.8.7 } else { requestFlush = makeRequestCallFromTimer(flush); } // `requestFlush` requests that the high priority event queue be flushed as // soon as possible. // This is useful to prevent an error thrown in a task from stalling the event // queue if the exception handled by Node.js’s // `process.on("uncaughtException")` or by a domain. rawAsap.requestFlush = requestFlush; // To request a high priority event, we induce a mutation observer by toggling // the text of a text node between "1" and "-1". function makeRequestCallFromMutationObserver(callback) { var toggle = 1; var observer = new BrowserMutationObserver(callback); var node = document.createTextNode(""); observer.observe(node, {characterData: true}); return function requestCall() { toggle = -toggle; node.data = toggle; }; } // The message channel technique was discovered by Malte Ubl and was the // original foundation for this library. // http://www.nonblocking.io/2011/06/windownexttick.html // Safari 6.0.5 (at least) intermittently fails to create message ports on a // page's first load. Thankfully, this version of Safari supports // MutationObservers, so we don't need to fall back in that case. // function makeRequestCallFromMessageChannel(callback) { // var channel = new MessageChannel(); // channel.port1.onmessage = callback; // return function requestCall() { // channel.port2.postMessage(0); // }; // } // For reasons explained above, we are also unable to use `setImmediate` // under any circumstances. // Even if we were, there is another bug in Internet Explorer 10. // It is not sufficient to assign `setImmediate` to `requestFlush` because // `setImmediate` must be called *by name* and therefore must be wrapped in a // closure. // Never forget. // function makeRequestCallFromSetImmediate(callback) { // return function requestCall() { // setImmediate(callback); // }; // } // Safari 6.0 has a problem where timers will get lost while the user is // scrolling. This problem does not impact ASAP because Safari 6.0 supports // mutation observers, so that implementation is used instead. // However, if we ever elect to use timers in Safari, the prevalent work-around // is to add a scroll event listener that calls for a flush. // `setTimeout` does not call the passed callback if the delay is less than // approximately 7 in web workers in Firefox 8 through 18, and sometimes not // even then. function makeRequestCallFromTimer(callback) { return function requestCall() { // We dispatch a timeout with a specified delay of 0 for engines that // can reliably accommodate that request. This will usually be snapped // to a 4 milisecond delay, but once we're flushing, there's no delay // between events. var timeoutHandle = setTimeout(handleTimer, 0); // However, since this timer gets frequently dropped in Firefox // workers, we enlist an interval handle that will try to fire // an event 20 times per second until it succeeds. var intervalHandle = setInterval(handleTimer, 50); function handleTimer() { // Whichever timer succeeds will cancel both timers and // execute the callback. clearTimeout(timeoutHandle); clearInterval(intervalHandle); callback(); } }; } // This is for `asap.js` only. // Its name will be periodically randomized to break any code that depends on // its existence. rawAsap.makeRequestCallFromTimer = makeRequestCallFromTimer; // ASAP was originally a nextTick shim included in Q. This was factored out // into this ASAP package. It was later adapted to RSVP which made further // amendments. These decisions, particularly to marginalize MessageChannel and // to capture the MutationObserver implementation in a closure, were integrated // back into ASAP proper. // https://github.com/tildeio/rsvp.js/blob/cddf7232546a9cf858524b75cde6f9edf72620a7/lib/rsvp/asap.js }).call(this,typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {}) },{}],167:[function(require,module,exports){ (function (process){ "use strict"; var domain; // The domain module is executed on demand var hasSetImmediate = typeof setImmediate === "function"; // Use the fastest means possible to execute a task in its own turn, with // priority over other events including network IO events in Node.js. // // An exception thrown by a task will permanently interrupt the processing of // subsequent tasks. The higher level `asap` function ensures that if an // exception is thrown by a task, that the task queue will continue flushing as // soon as possible, but if you use `rawAsap` directly, you are responsible to // either ensure that no exceptions are thrown from your task, or to manually // call `rawAsap.requestFlush` if an exception is thrown. module.exports = rawAsap; function rawAsap(task) { if (!queue.length) { requestFlush(); flushing = true; } // Avoids a function call queue[queue.length] = task; } var queue = []; // Once a flush has been requested, no further calls to `requestFlush` are // necessary until the next `flush` completes. var flushing = false; // The position of the next task to execute in the task queue. This is // preserved between calls to `flush` so that it can be resumed if // a task throws an exception. var index = 0; // If a task schedules additional tasks recursively, the task queue can grown // unbounded. To prevent memory excaustion, the task queue will periodically // truncate already-completed tasks. var capacity = 1024; // The flush function processes all tasks that have been scheduled with // `rawAsap` unless and until one of those tasks throws an exception. // If a task throws an exception, `flush` ensures that its state will remain // consistent and will resume where it left off when called again. // However, `flush` does not make any arrangements to be called again if an // exception is thrown. function flush() { while (index < queue.length) { var currentIndex = index; // Advance the index before calling the task. This ensures that we will // begin flushing on the next task the task throws an error. index = index + 1; queue[currentIndex].call(); // Prevent leaking memory for long chains of recursive calls to `asap`. // If we call `asap` within tasks scheduled by `asap`, the queue will // grow, but to avoid an O(n) walk for every task we execute, we don't // shift tasks off the queue after they have been executed. // Instead, we periodically shift 1024 tasks off the queue. if (index > capacity) { // Manually shift all values starting at the index back to the // beginning of the queue. for (var scan = 0; scan < index; scan++) { queue[scan] = queue[scan + index]; } queue.length -= index; index = 0; } } queue.length = 0; index = 0; flushing = false; } rawAsap.requestFlush = requestFlush; function requestFlush() { // Ensure flushing is not bound to any domain. // It is not sufficient to exit the domain, because domains exist on a stack. // To execute code outside of any domain, the following dance is necessary. var parentDomain = process.domain; if (parentDomain) { if (!domain) { // Lazy execute the domain module. // Only employed if the user elects to use domains. domain = require("domain"); } domain.active = process.domain = null; } // `setImmediate` is slower that `process.nextTick`, but `process.nextTick` // cannot handle recursion. // `requestFlush` will only be called recursively from `asap.js`, to resume // flushing after an error is thrown into a domain. // Conveniently, `setImmediate` was introduced in the same version // `process.nextTick` started throwing recursion errors. if (flushing && hasSetImmediate) { setImmediate(flush); } else { process.nextTick(flush); } if (parentDomain) { domain.active = process.domain = parentDomain; } } }).call(this,require("FWaASH")) },{"FWaASH":147,"domain":145}],168:[function(require,module,exports){ (function (process,global){ // Copyright (c) Microsoft Open Technologies, Inc. All rights reserved. See License.txt in the project root for license information. ;(function (undefined) { var objectTypes = { 'boolean': false, 'function': true, 'object': true, 'number': false, 'string': false, 'undefined': false }; var root = (objectTypes[typeof window] && window) || this, freeExports = objectTypes[typeof exports] && exports && !exports.nodeType && exports, freeModule = objectTypes[typeof module] && module && !module.nodeType && module, moduleExports = freeModule && freeModule.exports === freeExports && freeExports, freeGlobal = objectTypes[typeof global] && global; if (freeGlobal && (freeGlobal.global === freeGlobal || freeGlobal.window === freeGlobal)) { root = freeGlobal; } var Rx = { internals: {}, config: { Promise: root.Promise }, helpers: { } }; // Defaults var noop = Rx.helpers.noop = function () { }, notDefined = Rx.helpers.notDefined = function (x) { return typeof x === 'undefined'; }, isScheduler = Rx.helpers.isScheduler = function (x) { return x instanceof Rx.Scheduler; }, identity = Rx.helpers.identity = function (x) { return x; }, pluck = Rx.helpers.pluck = function (property) { return function (x) { return x[property]; }; }, just = Rx.helpers.just = function (value) { return function () { return value; }; }, defaultNow = Rx.helpers.defaultNow = Date.now, defaultComparer = Rx.helpers.defaultComparer = function (x, y) { return isEqual(x, y); }, defaultSubComparer = Rx.helpers.defaultSubComparer = function (x, y) { return x > y ? 1 : (x < y ? -1 : 0); }, defaultKeySerializer = Rx.helpers.defaultKeySerializer = function (x) { return x.toString(); }, defaultError = Rx.helpers.defaultError = function (err) { throw err; }, isPromise = Rx.helpers.isPromise = function (p) { return !!p && typeof p.then === 'function'; }, asArray = Rx.helpers.asArray = function () { return Array.prototype.slice.call(arguments); }, not = Rx.helpers.not = function (a) { return !a; }, isFunction = Rx.helpers.isFunction = (function () { var isFn = function (value) { return typeof value == 'function' || false; } // fallback for older versions of Chrome and Safari if (isFn(/x/)) { isFn = function(value) { return typeof value == 'function' && toString.call(value) == '[object Function]'; }; } return isFn; }()); function cloneArray(arr) { for(var a = [], i = 0, len = arr.length; i < len; i++) { a.push(arr[i]); } return a;} Rx.config.longStackSupport = false; var hasStacks = false; try { throw new Error(); } catch (e) { hasStacks = !!e.stack; } // All code after this point will be filtered from stack traces reported by RxJS var rStartingLine = captureLine(), rFileName; var STACK_JUMP_SEPARATOR = "From previous event:"; function makeStackTraceLong(error, observable) { // If possible, transform the error stack trace by removing Node and RxJS // cruft, then concatenating with the stack trace of `observable`. if (hasStacks && observable.stack && typeof error === "object" && error !== null && error.stack && error.stack.indexOf(STACK_JUMP_SEPARATOR) === -1 ) { var stacks = []; for (var o = observable; !!o; o = o.source) { if (o.stack) { stacks.unshift(o.stack); } } stacks.unshift(error.stack); var concatedStacks = stacks.join("\n" + STACK_JUMP_SEPARATOR + "\n"); error.stack = filterStackString(concatedStacks); } } function filterStackString(stackString) { var lines = stackString.split("\n"), desiredLines = []; for (var i = 0, len = lines.length; i < len; i++) { var line = lines[i]; if (!isInternalFrame(line) && !isNodeFrame(line) && line) { desiredLines.push(line); } } return desiredLines.join("\n"); } function isInternalFrame(stackLine) { var fileNameAndLineNumber = getFileNameAndLineNumber(stackLine); if (!fileNameAndLineNumber) { return false; } var fileName = fileNameAndLineNumber[0], lineNumber = fileNameAndLineNumber[1]; return fileName === rFileName && lineNumber >= rStartingLine && lineNumber <= rEndingLine; } function isNodeFrame(stackLine) { return stackLine.indexOf("(module.js:") !== -1 || stackLine.indexOf("(node.js:") !== -1; } function captureLine() { if (!hasStacks) { return; } try { throw new Error(); } catch (e) { var lines = e.stack.split("\n"); var firstLine = lines[0].indexOf("@") > 0 ? lines[1] : lines[2]; var fileNameAndLineNumber = getFileNameAndLineNumber(firstLine); if (!fileNameAndLineNumber) { return; } rFileName = fileNameAndLineNumber[0]; return fileNameAndLineNumber[1]; } } function getFileNameAndLineNumber(stackLine) { // Named functions: "at functionName (filename:lineNumber:columnNumber)" var attempt1 = /at .+ \((.+):(\d+):(?:\d+)\)$/.exec(stackLine); if (attempt1) { return [attempt1[1], Number(attempt1[2])]; } // Anonymous functions: "at filename:lineNumber:columnNumber" var attempt2 = /at ([^ ]+):(\d+):(?:\d+)$/.exec(stackLine); if (attempt2) { return [attempt2[1], Number(attempt2[2])]; } // Firefox style: "function@filename:lineNumber or @filename:lineNumber" var attempt3 = /.*@(.+):(\d+)$/.exec(stackLine); if (attempt3) { return [attempt3[1], Number(attempt3[2])]; } } var EmptyError = Rx.EmptyError = function() { this.message = 'Sequence contains no elements.'; Error.call(this); }; EmptyError.prototype = Error.prototype; var ObjectDisposedError = Rx.ObjectDisposedError = function() { this.message = 'Object has been disposed'; Error.call(this); }; ObjectDisposedError.prototype = Error.prototype; var ArgumentOutOfRangeError = Rx.ArgumentOutOfRangeError = function () { this.message = 'Argument out of range'; Error.call(this); }; ArgumentOutOfRangeError.prototype = Error.prototype; var NotSupportedError = Rx.NotSupportedError = function (message) { this.message = message || 'This operation is not supported'; Error.call(this); }; NotSupportedError.prototype = Error.prototype; var NotImplementedError = Rx.NotImplementedError = function (message) { this.message = message || 'This operation is not implemented'; Error.call(this); }; NotImplementedError.prototype = Error.prototype; var notImplemented = Rx.helpers.notImplemented = function () { throw new NotImplementedError(); }; var notSupported = Rx.helpers.notSupported = function () { throw new NotSupportedError(); }; // Shim in iterator support var $iterator$ = (typeof Symbol === 'function' && Symbol.iterator) || '_es6shim_iterator_'; // Bug for mozilla version if (root.Set && typeof new root.Set()['@@iterator'] === 'function') { $iterator$ = '@@iterator'; } var doneEnumerator = Rx.doneEnumerator = { done: true, value: undefined }; var isIterable = Rx.helpers.isIterable = function (o) { return o[$iterator$] !== undefined; } var isArrayLike = Rx.helpers.isArrayLike = function (o) { return o && o.length !== undefined; } Rx.helpers.iterator = $iterator$; var bindCallback = Rx.internals.bindCallback = function (func, thisArg, argCount) { if (typeof thisArg === 'undefined') { return func; } switch(argCount) { case 0: return function() { return func.call(thisArg) }; case 1: return function(arg) { return func.call(thisArg, arg); } case 2: return function(value, index) { return func.call(thisArg, value, index); }; case 3: return function(value, index, collection) { return func.call(thisArg, value, index, collection); }; } return function() { return func.apply(thisArg, arguments); }; }; /** Used to determine if values are of the language type Object */ var dontEnums = ['toString', 'toLocaleString', 'valueOf', 'hasOwnProperty', 'isPrototypeOf', 'propertyIsEnumerable', 'constructor'], dontEnumsLength = dontEnums.length; /** `Object#toString` result shortcuts */ var argsClass = '[object Arguments]', arrayClass = '[object Array]', boolClass = '[object Boolean]', dateClass = '[object Date]', errorClass = '[object Error]', funcClass = '[object Function]', numberClass = '[object Number]', objectClass = '[object Object]', regexpClass = '[object RegExp]', stringClass = '[object String]'; var toString = Object.prototype.toString, hasOwnProperty = Object.prototype.hasOwnProperty, supportsArgsClass = toString.call(arguments) == argsClass, // For less <IE9 && FF<4 supportNodeClass, errorProto = Error.prototype, objectProto = Object.prototype, stringProto = String.prototype, propertyIsEnumerable = objectProto.propertyIsEnumerable; try { supportNodeClass = !(toString.call(document) == objectClass && !({ 'toString': 0 } + '')); } catch (e) { supportNodeClass = true; } var nonEnumProps = {}; nonEnumProps[arrayClass] = nonEnumProps[dateClass] = nonEnumProps[numberClass] = { 'constructor': true, 'toLocaleString': true, 'toString': true, 'valueOf': true }; nonEnumProps[boolClass] = nonEnumProps[stringClass] = { 'constructor': true, 'toString': true, 'valueOf': true }; nonEnumProps[errorClass] = nonEnumProps[funcClass] = nonEnumProps[regexpClass] = { 'constructor': true, 'toString': true }; nonEnumProps[objectClass] = { 'constructor': true }; var support = {}; (function () { var ctor = function() { this.x = 1; }, props = []; ctor.prototype = { 'valueOf': 1, 'y': 1 }; for (var key in new ctor) { props.push(key); } for (key in arguments) { } // Detect if `name` or `message` properties of `Error.prototype` are enumerable by default. support.enumErrorProps = propertyIsEnumerable.call(errorProto, 'message') || propertyIsEnumerable.call(errorProto, 'name'); // Detect if `prototype` properties are enumerable by default. support.enumPrototypes = propertyIsEnumerable.call(ctor, 'prototype'); // Detect if `arguments` object indexes are non-enumerable support.nonEnumArgs = key != 0; // Detect if properties shadowing those on `Object.prototype` are non-enumerable. support.nonEnumShadows = !/valueOf/.test(props); }(1)); var isObject = Rx.internals.isObject = function(value) { var type = typeof value; return value && (type == 'function' || type == 'object') || false; }; function keysIn(object) { var result = []; if (!isObject(object)) { return result; } if (support.nonEnumArgs && object.length && isArguments(object)) { object = slice.call(object); } var skipProto = support.enumPrototypes && typeof object == 'function', skipErrorProps = support.enumErrorProps && (object === errorProto || object instanceof Error); for (var key in object) { if (!(skipProto && key == 'prototype') && !(skipErrorProps && (key == 'message' || key == 'name'))) { result.push(key); } } if (support.nonEnumShadows && object !== objectProto) { var ctor = object.constructor, index = -1, length = dontEnumsLength; if (object === (ctor && ctor.prototype)) { var className = object === stringProto ? stringClass : object === errorProto ? errorClass : toString.call(object), nonEnum = nonEnumProps[className]; } while (++index < length) { key = dontEnums[index]; if (!(nonEnum && nonEnum[key]) && hasOwnProperty.call(object, key)) { result.push(key); } } } return result; } function internalFor(object, callback, keysFunc) { var index = -1, props = keysFunc(object), length = props.length; while (++index < length) { var key = props[index]; if (callback(object[key], key, object) === false) { break; } } return object; } function internalForIn(object, callback) { return internalFor(object, callback, keysIn); } function isNode(value) { // IE < 9 presents DOM nodes as `Object` objects except they have `toString` // methods that are `typeof` "string" and still can coerce nodes to strings return typeof value.toString != 'function' && typeof (value + '') == 'string'; } var isArguments = function(value) { return (value && typeof value == 'object') ? toString.call(value) == argsClass : false; } // fallback for browsers that can't detect `arguments` objects by [[Class]] if (!supportsArgsClass) { isArguments = function(value) { return (value && typeof value == 'object') ? hasOwnProperty.call(value, 'callee') : false; }; } var isEqual = Rx.internals.isEqual = function (x, y) { return deepEquals(x, y, [], []); }; /** @private * Used for deep comparison **/ function deepEquals(a, b, stackA, stackB) { // exit early for identical values if (a === b) { // treat `+0` vs. `-0` as not equal return a !== 0 || (1 / a == 1 / b); } var type = typeof a, otherType = typeof b; // exit early for unlike primitive values if (a === a && (a == null || b == null || (type != 'function' && type != 'object' && otherType != 'function' && otherType != 'object'))) { return false; } // compare [[Class]] names var className = toString.call(a), otherClass = toString.call(b); if (className == argsClass) { className = objectClass; } if (otherClass == argsClass) { otherClass = objectClass; } if (className != otherClass) { return false; } switch (className) { case boolClass: case dateClass: // coerce dates and booleans to numbers, dates to milliseconds and booleans // to `1` or `0` treating invalid dates coerced to `NaN` as not equal return +a == +b; case numberClass: // treat `NaN` vs. `NaN` as equal return (a != +a) ? b != +b : // but treat `-0` vs. `+0` as not equal (a == 0 ? (1 / a == 1 / b) : a == +b); case regexpClass: case stringClass: // coerce regexes to strings (http://es5.github.io/#x15.10.6.4) // treat string primitives and their corresponding object instances as equal return a == String(b); } var isArr = className == arrayClass; if (!isArr) { // exit for functions and DOM nodes if (className != objectClass || (!support.nodeClass && (isNode(a) || isNode(b)))) { return false; } // in older versions of Opera, `arguments` objects have `Array` constructors var ctorA = !support.argsObject && isArguments(a) ? Object : a.constructor, ctorB = !support.argsObject && isArguments(b) ? Object : b.constructor; // non `Object` object instances with different constructors are not equal if (ctorA != ctorB && !(hasOwnProperty.call(a, 'constructor') && hasOwnProperty.call(b, 'constructor')) && !(isFunction(ctorA) && ctorA instanceof ctorA && isFunction(ctorB) && ctorB instanceof ctorB) && ('constructor' in a && 'constructor' in b) ) { return false; } } // assume cyclic structures are equal // the algorithm for detecting cyclic structures is adapted from ES 5.1 // section 15.12.3, abstract operation `JO` (http://es5.github.io/#x15.12.3) var initedStack = !stackA; stackA || (stackA = []); stackB || (stackB = []); var length = stackA.length; while (length--) { if (stackA[length] == a) { return stackB[length] == b; } } var size = 0; var result = true; // add `a` and `b` to the stack of traversed objects stackA.push(a); stackB.push(b); // recursively compare objects and arrays (susceptible to call stack limits) if (isArr) { // compare lengths to determine if a deep comparison is necessary length = a.length; size = b.length; result = size == length; if (result) { // deep compare the contents, ignoring non-numeric properties while (size--) { var index = length, value = b[size]; if (!(result = deepEquals(a[size], value, stackA, stackB))) { break; } } } } else { // deep compare objects using `forIn`, instead of `forOwn`, to avoid `Object.keys` // which, in this case, is more costly internalForIn(b, function(value, key, b) { if (hasOwnProperty.call(b, key)) { // count the number of properties. size++; // deep compare each property value. return (result = hasOwnProperty.call(a, key) && deepEquals(a[key], value, stackA, stackB)); } }); if (result) { // ensure both objects have the same number of properties internalForIn(a, function(value, key, a) { if (hasOwnProperty.call(a, key)) { // `size` will be `-1` if `a` has more properties than `b` return (result = --size > -1); } }); } } stackA.pop(); stackB.pop(); return result; } var hasProp = {}.hasOwnProperty, slice = Array.prototype.slice; var inherits = this.inherits = Rx.internals.inherits = function (child, parent) { function __() { this.constructor = child; } __.prototype = parent.prototype; child.prototype = new __(); }; var addProperties = Rx.internals.addProperties = function (obj) { for(var sources = [], i = 1, len = arguments.length; i < len; i++) { sources.push(arguments[i]); } for (var idx = 0, ln = sources.length; idx < ln; idx++) { var source = sources[idx]; for (var prop in source) { obj[prop] = source[prop]; } } }; // Rx Utils var addRef = Rx.internals.addRef = function (xs, r) { return new AnonymousObservable(function (observer) { return new CompositeDisposable(r.getDisposable(), xs.subscribe(observer)); }); }; function arrayInitialize(count, factory) { var a = new Array(count); for (var i = 0; i < count; i++) { a[i] = factory(); } return a; } var errorObj = {e: {}}; var tryCatchTarget; function tryCatcher() { try { return tryCatchTarget.apply(this, arguments); } catch (e) { errorObj.e = e; return errorObj; } } function tryCatch(fn) { if (!isFunction(fn)) { throw new TypeError('fn must be a function'); } tryCatchTarget = fn; return tryCatcher; } function thrower(e) { throw e; } // Collections function IndexedItem(id, value) { this.id = id; this.value = value; } IndexedItem.prototype.compareTo = function (other) { var c = this.value.compareTo(other.value); c === 0 && (c = this.id - other.id); return c; }; // Priority Queue for Scheduling var PriorityQueue = Rx.internals.PriorityQueue = function (capacity) { this.items = new Array(capacity); this.length = 0; }; var priorityProto = PriorityQueue.prototype; priorityProto.isHigherPriority = function (left, right) { return this.items[left].compareTo(this.items[right]) < 0; }; priorityProto.percolate = function (index) { if (index >= this.length || index < 0) { return; } var parent = index - 1 >> 1; if (parent < 0 || parent === index) { return; } if (this.isHigherPriority(index, parent)) { var temp = this.items[index]; this.items[index] = this.items[parent]; this.items[parent] = temp; this.percolate(parent); } }; priorityProto.heapify = function (index) { +index || (index = 0); if (index >= this.length || index < 0) { return; } var left = 2 * index + 1, right = 2 * index + 2, first = index; if (left < this.length && this.isHigherPriority(left, first)) { first = left; } if (right < this.length && this.isHigherPriority(right, first)) { first = right; } if (first !== index) { var temp = this.items[index]; this.items[index] = this.items[first]; this.items[first] = temp; this.heapify(first); } }; priorityProto.peek = function () { return this.items[0].value; }; priorityProto.removeAt = function (index) { this.items[index] = this.items[--this.length]; this.items[this.length] = undefined; this.heapify(); }; priorityProto.dequeue = function () { var result = this.peek(); this.removeAt(0); return result; }; priorityProto.enqueue = function (item) { var index = this.length++; this.items[index] = new IndexedItem(PriorityQueue.count++, item); this.percolate(index); }; priorityProto.remove = function (item) { for (var i = 0; i < this.length; i++) { if (this.items[i].value === item) { this.removeAt(i); return true; } } return false; }; PriorityQueue.count = 0; /** * Represents a group of disposable resources that are disposed together. * @constructor */ var CompositeDisposable = Rx.CompositeDisposable = function () { var args = [], i, len; if (Array.isArray(arguments[0])) { args = arguments[0]; len = args.length; } else { len = arguments.length; args = new Array(len); for(i = 0; i < len; i++) { args[i] = arguments[i]; } } for(i = 0; i < len; i++) { if (!isDisposable(args[i])) { throw new TypeError('Not a disposable'); } } this.disposables = args; this.isDisposed = false; this.length = args.length; }; var CompositeDisposablePrototype = CompositeDisposable.prototype; /** * Adds a disposable to the CompositeDisposable or disposes the disposable if the CompositeDisposable is disposed. * @param {Mixed} item Disposable to add. */ CompositeDisposablePrototype.add = function (item) { if (this.isDisposed) { item.dispose(); } else { this.disposables.push(item); this.length++; } }; /** * Removes and disposes the first occurrence of a disposable from the CompositeDisposable. * @param {Mixed} item Disposable to remove. * @returns {Boolean} true if found; false otherwise. */ CompositeDisposablePrototype.remove = function (item) { var shouldDispose = false; if (!this.isDisposed) { var idx = this.disposables.indexOf(item); if (idx !== -1) { shouldDispose = true; this.disposables.splice(idx, 1); this.length--; item.dispose(); } } return shouldDispose; }; /** * Disposes all disposables in the group and removes them from the group. */ CompositeDisposablePrototype.dispose = function () { if (!this.isDisposed) { this.isDisposed = true; var len = this.disposables.length, currentDisposables = new Array(len); for(var i = 0; i < len; i++) { currentDisposables[i] = this.disposables[i]; } this.disposables = []; this.length = 0; for (i = 0; i < len; i++) { currentDisposables[i].dispose(); } } }; /** * Provides a set of static methods for creating Disposables. * @param {Function} dispose Action to run during the first call to dispose. The action is guaranteed to be run at most once. */ var Disposable = Rx.Disposable = function (action) { this.isDisposed = false; this.action = action || noop; }; /** Performs the task of cleaning up resources. */ Disposable.prototype.dispose = function () { if (!this.isDisposed) { this.action(); this.isDisposed = true; } }; /** * Creates a disposable object that invokes the specified action when disposed. * @param {Function} dispose Action to run during the first call to dispose. The action is guaranteed to be run at most once. * @return {Disposable} The disposable object that runs the given action upon disposal. */ var disposableCreate = Disposable.create = function (action) { return new Disposable(action); }; /** * Gets the disposable that does nothing when disposed. */ var disposableEmpty = Disposable.empty = { dispose: noop }; /** * Validates whether the given object is a disposable * @param {Object} Object to test whether it has a dispose method * @returns {Boolean} true if a disposable object, else false. */ var isDisposable = Disposable.isDisposable = function (d) { return d && isFunction(d.dispose); }; var checkDisposed = Disposable.checkDisposed = function (disposable) { if (disposable.isDisposed) { throw new ObjectDisposedError(); } }; var SingleAssignmentDisposable = Rx.SingleAssignmentDisposable = (function () { function BooleanDisposable () { this.isDisposed = false; this.current = null; } var booleanDisposablePrototype = BooleanDisposable.prototype; /** * Gets the underlying disposable. * @return The underlying disposable. */ booleanDisposablePrototype.getDisposable = function () { return this.current; }; /** * Sets the underlying disposable. * @param {Disposable} value The new underlying disposable. */ booleanDisposablePrototype.setDisposable = function (value) { var shouldDispose = this.isDisposed; if (!shouldDispose) { var old = this.current; this.current = value; } old && old.dispose(); shouldDispose && value && value.dispose(); }; /** * Disposes the underlying disposable as well as all future replacements. */ booleanDisposablePrototype.dispose = function () { if (!this.isDisposed) { this.isDisposed = true; var old = this.current; this.current = null; } old && old.dispose(); }; return BooleanDisposable; }()); var SerialDisposable = Rx.SerialDisposable = SingleAssignmentDisposable; /** * Represents a disposable resource that only disposes its underlying disposable resource when all dependent disposable objects have been disposed. */ var RefCountDisposable = Rx.RefCountDisposable = (function () { function InnerDisposable(disposable) { this.disposable = disposable; this.disposable.count++; this.isInnerDisposed = false; } InnerDisposable.prototype.dispose = function () { if (!this.disposable.isDisposed && !this.isInnerDisposed) { this.isInnerDisposed = true; this.disposable.count--; if (this.disposable.count === 0 && this.disposable.isPrimaryDisposed) { this.disposable.isDisposed = true; this.disposable.underlyingDisposable.dispose(); } } }; /** * Initializes a new instance of the RefCountDisposable with the specified disposable. * @constructor * @param {Disposable} disposable Underlying disposable. */ function RefCountDisposable(disposable) { this.underlyingDisposable = disposable; this.isDisposed = false; this.isPrimaryDisposed = false; this.count = 0; } /** * Disposes the underlying disposable only when all dependent disposables have been disposed */ RefCountDisposable.prototype.dispose = function () { if (!this.isDisposed && !this.isPrimaryDisposed) { this.isPrimaryDisposed = true; if (this.count === 0) { this.isDisposed = true; this.underlyingDisposable.dispose(); } } }; /** * Returns a dependent disposable that when disposed decreases the refcount on the underlying disposable. * @returns {Disposable} A dependent disposable contributing to the reference count that manages the underlying disposable's lifetime. */ RefCountDisposable.prototype.getDisposable = function () { return this.isDisposed ? disposableEmpty : new InnerDisposable(this); }; return RefCountDisposable; })(); function ScheduledDisposable(scheduler, disposable) { this.scheduler = scheduler; this.disposable = disposable; this.isDisposed = false; } function scheduleItem(s, self) { if (!self.isDisposed) { self.isDisposed = true; self.disposable.dispose(); } } ScheduledDisposable.prototype.dispose = function () { this.scheduler.scheduleWithState(this, scheduleItem); }; var ScheduledItem = Rx.internals.ScheduledItem = function (scheduler, state, action, dueTime, comparer) { this.scheduler = scheduler; this.state = state; this.action = action; this.dueTime = dueTime; this.comparer = comparer || defaultSubComparer; this.disposable = new SingleAssignmentDisposable(); } ScheduledItem.prototype.invoke = function () { this.disposable.setDisposable(this.invokeCore()); }; ScheduledItem.prototype.compareTo = function (other) { return this.comparer(this.dueTime, other.dueTime); }; ScheduledItem.prototype.isCancelled = function () { return this.disposable.isDisposed; }; ScheduledItem.prototype.invokeCore = function () { return this.action(this.scheduler, this.state); }; /** Provides a set of static properties to access commonly used schedulers. */ var Scheduler = Rx.Scheduler = (function () { function Scheduler(now, schedule, scheduleRelative, scheduleAbsolute) { this.now = now; this._schedule = schedule; this._scheduleRelative = scheduleRelative; this._scheduleAbsolute = scheduleAbsolute; } function invokeAction(scheduler, action) { action(); return disposableEmpty; } var schedulerProto = Scheduler.prototype; /** * Schedules an action to be executed. * @param {Function} action Action to execute. * @returns {Disposable} The disposable object used to cancel the scheduled action (best effort). */ schedulerProto.schedule = function (action) { return this._schedule(action, invokeAction); }; /** * Schedules an action to be executed. * @param state State passed to the action to be executed. * @param {Function} action Action to be executed. * @returns {Disposable} The disposable object used to cancel the scheduled action (best effort). */ schedulerProto.scheduleWithState = function (state, action) { return this._schedule(state, action); }; /** * Schedules an action to be executed after the specified relative due time. * @param {Function} action Action to execute. * @param {Number} dueTime Relative time after which to execute the action. * @returns {Disposable} The disposable object used to cancel the scheduled action (best effort). */ schedulerProto.scheduleWithRelative = function (dueTime, action) { return this._scheduleRelative(action, dueTime, invokeAction); }; /** * Schedules an action to be executed after dueTime. * @param state State passed to the action to be executed. * @param {Function} action Action to be executed. * @param {Number} dueTime Relative time after which to execute the action. * @returns {Disposable} The disposable object used to cancel the scheduled action (best effort). */ schedulerProto.scheduleWithRelativeAndState = function (state, dueTime, action) { return this._scheduleRelative(state, dueTime, action); }; /** * Schedules an action to be executed at the specified absolute due time. * @param {Function} action Action to execute. * @param {Number} dueTime Absolute time at which to execute the action. * @returns {Disposable} The disposable object used to cancel the scheduled action (best effort). */ schedulerProto.scheduleWithAbsolute = function (dueTime, action) { return this._scheduleAbsolute(action, dueTime, invokeAction); }; /** * Schedules an action to be executed at dueTime. * @param {Mixed} state State passed to the action to be executed. * @param {Function} action Action to be executed. * @param {Number}dueTime Absolute time at which to execute the action. * @returns {Disposable} The disposable object used to cancel the scheduled action (best effort). */ schedulerProto.scheduleWithAbsoluteAndState = function (state, dueTime, action) { return this._scheduleAbsolute(state, dueTime, action); }; /** Gets the current time according to the local machine's system clock. */ Scheduler.now = defaultNow; /** * Normalizes the specified TimeSpan value to a positive value. * @param {Number} timeSpan The time span value to normalize. * @returns {Number} The specified TimeSpan value if it is zero or positive; otherwise, 0 */ Scheduler.normalize = function (timeSpan) { timeSpan < 0 && (timeSpan = 0); return timeSpan; }; return Scheduler; }()); var normalizeTime = Scheduler.normalize; (function (schedulerProto) { function invokeRecImmediate(scheduler, pair) { var state = pair[0], action = pair[1], group = new CompositeDisposable(); function recursiveAction(state1) { action(state1, function (state2) { var isAdded = false, isDone = false, d = scheduler.scheduleWithState(state2, function (scheduler1, state3) { if (isAdded) { group.remove(d); } else { isDone = true; } recursiveAction(state3); return disposableEmpty; }); if (!isDone) { group.add(d); isAdded = true; } }); } recursiveAction(state); return group; } function invokeRecDate(scheduler, pair, method) { var state = pair[0], action = pair[1], group = new CompositeDisposable(); function recursiveAction(state1) { action(state1, function (state2, dueTime1) { var isAdded = false, isDone = false, d = scheduler[method](state2, dueTime1, function (scheduler1, state3) { if (isAdded) { group.remove(d); } else { isDone = true; } recursiveAction(state3); return disposableEmpty; }); if (!isDone) { group.add(d); isAdded = true; } }); }; recursiveAction(state); return group; } function scheduleInnerRecursive(action, self) { action(function(dt) { self(action, dt); }); } /** * Schedules an action to be executed recursively. * @param {Function} action Action to execute recursively. The parameter passed to the action is used to trigger recursive scheduling of the action. * @returns {Disposable} The disposable object used to cancel the scheduled action (best effort). */ schedulerProto.scheduleRecursive = function (action) { return this.scheduleRecursiveWithState(action, function (_action, self) { _action(function () { self(_action); }); }); }; /** * Schedules an action to be executed recursively. * @param {Mixed} state State passed to the action to be executed. * @param {Function} action Action to execute recursively. The last parameter passed to the action is used to trigger recursive scheduling of the action, passing in recursive invocation state. * @returns {Disposable} The disposable object used to cancel the scheduled action (best effort). */ schedulerProto.scheduleRecursiveWithState = function (state, action) { return this.scheduleWithState([state, action], invokeRecImmediate); }; /** * Schedules an action to be executed recursively after a specified relative due time. * @param {Function} action Action to execute recursively. The parameter passed to the action is used to trigger recursive scheduling of the action at the specified relative time. * @param {Number}dueTime Relative time after which to execute the action for the first time. * @returns {Disposable} The disposable object used to cancel the scheduled action (best effort). */ schedulerProto.scheduleRecursiveWithRelative = function (dueTime, action) { return this.scheduleRecursiveWithRelativeAndState(action, dueTime, scheduleInnerRecursive); }; /** * Schedules an action to be executed recursively after a specified relative due time. * @param {Mixed} state State passed to the action to be executed. * @param {Function} action Action to execute recursively. The last parameter passed to the action is used to trigger recursive scheduling of the action, passing in the recursive due time and invocation state. * @param {Number}dueTime Relative time after which to execute the action for the first time. * @returns {Disposable} The disposable object used to cancel the scheduled action (best effort). */ schedulerProto.scheduleRecursiveWithRelativeAndState = function (state, dueTime, action) { return this._scheduleRelative([state, action], dueTime, function (s, p) { return invokeRecDate(s, p, 'scheduleWithRelativeAndState'); }); }; /** * Schedules an action to be executed recursively at a specified absolute due time. * @param {Function} action Action to execute recursively. The parameter passed to the action is used to trigger recursive scheduling of the action at the specified absolute time. * @param {Number}dueTime Absolute time at which to execute the action for the first time. * @returns {Disposable} The disposable object used to cancel the scheduled action (best effort). */ schedulerProto.scheduleRecursiveWithAbsolute = function (dueTime, action) { return this.scheduleRecursiveWithAbsoluteAndState(action, dueTime, scheduleInnerRecursive); }; /** * Schedules an action to be executed recursively at a specified absolute due time. * @param {Mixed} state State passed to the action to be executed. * @param {Function} action Action to execute recursively. The last parameter passed to the action is used to trigger recursive scheduling of the action, passing in the recursive due time and invocation state. * @param {Number}dueTime Absolute time at which to execute the action for the first time. * @returns {Disposable} The disposable object used to cancel the scheduled action (best effort). */ schedulerProto.scheduleRecursiveWithAbsoluteAndState = function (state, dueTime, action) { return this._scheduleAbsolute([state, action], dueTime, function (s, p) { return invokeRecDate(s, p, 'scheduleWithAbsoluteAndState'); }); }; }(Scheduler.prototype)); (function (schedulerProto) { /** * Schedules a periodic piece of work by dynamically discovering the scheduler's capabilities. The periodic task will be scheduled using window.setInterval for the base implementation. * @param {Number} period Period for running the work periodically. * @param {Function} action Action to be executed. * @returns {Disposable} The disposable object used to cancel the scheduled recurring action (best effort). */ Scheduler.prototype.schedulePeriodic = function (period, action) { return this.schedulePeriodicWithState(null, period, action); }; /** * Schedules a periodic piece of work by dynamically discovering the scheduler's capabilities. The periodic task will be scheduled using window.setInterval for the base implementation. * @param {Mixed} state Initial state passed to the action upon the first iteration. * @param {Number} period Period for running the work periodically. * @param {Function} action Action to be executed, potentially updating the state. * @returns {Disposable} The disposable object used to cancel the scheduled recurring action (best effort). */ Scheduler.prototype.schedulePeriodicWithState = function(state, period, action) { if (typeof root.setInterval === 'undefined') { throw new NotSupportedError(); } period = normalizeTime(period); var s = state, id = root.setInterval(function () { s = action(s); }, period); return disposableCreate(function () { root.clearInterval(id); }); }; }(Scheduler.prototype)); (function (schedulerProto) { /** * Returns a scheduler that wraps the original scheduler, adding exception handling for scheduled actions. * @param {Function} handler Handler that's run if an exception is caught. The exception will be rethrown if the handler returns false. * @returns {Scheduler} Wrapper around the original scheduler, enforcing exception handling. */ schedulerProto.catchError = schedulerProto['catch'] = function (handler) { return new CatchScheduler(this, handler); }; }(Scheduler.prototype)); var SchedulePeriodicRecursive = Rx.internals.SchedulePeriodicRecursive = (function () { function tick(command, recurse) { recurse(0, this._period); try { this._state = this._action(this._state); } catch (e) { this._cancel.dispose(); throw e; } } function SchedulePeriodicRecursive(scheduler, state, period, action) { this._scheduler = scheduler; this._state = state; this._period = period; this._action = action; } SchedulePeriodicRecursive.prototype.start = function () { var d = new SingleAssignmentDisposable(); this._cancel = d; d.setDisposable(this._scheduler.scheduleRecursiveWithRelativeAndState(0, this._period, tick.bind(this))); return d; }; return SchedulePeriodicRecursive; }()); /** Gets a scheduler that schedules work immediately on the current thread. */ var immediateScheduler = Scheduler.immediate = (function () { function scheduleNow(state, action) { return action(this, state); } return new Scheduler(defaultNow, scheduleNow, notSupported, notSupported); }()); /** * Gets a scheduler that schedules work as soon as possible on the current thread. */ var currentThreadScheduler = Scheduler.currentThread = (function () { var queue; function runTrampoline () { while (queue.length > 0) { var item = queue.dequeue(); !item.isCancelled() && item.invoke(); } } function scheduleNow(state, action) { var si = new ScheduledItem(this, state, action, this.now()); if (!queue) { queue = new PriorityQueue(4); queue.enqueue(si); var result = tryCatch(runTrampoline)(); queue = null; if (result === errorObj) { return thrower(result.e); } } else { queue.enqueue(si); } return si.disposable; } var currentScheduler = new Scheduler(defaultNow, scheduleNow, notSupported, notSupported); currentScheduler.scheduleRequired = function () { return !queue; }; return currentScheduler; }()); var scheduleMethod, clearMethod; var localTimer = (function () { var localSetTimeout, localClearTimeout = noop; if (!!root.WScript) { localSetTimeout = function (fn, time) { root.WScript.Sleep(time); fn(); }; } else if (!!root.setTimeout) { localSetTimeout = root.setTimeout; localClearTimeout = root.clearTimeout; } else { throw new NotSupportedError(); } return { setTimeout: localSetTimeout, clearTimeout: localClearTimeout }; }()); var localSetTimeout = localTimer.setTimeout, localClearTimeout = localTimer.clearTimeout; (function () { var nextHandle = 1, tasksByHandle = {}, currentlyRunning = false; clearMethod = function (handle) { delete tasksByHandle[handle]; }; function runTask(handle) { if (currentlyRunning) { localSetTimeout(function () { runTask(handle) }, 0); } else { var task = tasksByHandle[handle]; if (task) { currentlyRunning = true; var result = tryCatch(task)(); clearMethod(handle); currentlyRunning = false; if (result === errorObj) { return thrower(result.e); } } } } var reNative = RegExp('^' + String(toString) .replace(/[.*+?^${}()|[\]\\]/g, '\\$&') .replace(/toString| for [^\]]+/g, '.*?') + '$' ); var setImmediate = typeof (setImmediate = freeGlobal && moduleExports && freeGlobal.setImmediate) == 'function' && !reNative.test(setImmediate) && setImmediate; function postMessageSupported () { // Ensure not in a worker if (!root.postMessage || root.importScripts) { return false; } var isAsync = false, oldHandler = root.onmessage; // Test for async root.onmessage = function () { isAsync = true; }; root.postMessage('', '*'); root.onmessage = oldHandler; return isAsync; } // Use in order, setImmediate, nextTick, postMessage, MessageChannel, script readystatechanged, setTimeout if (isFunction(setImmediate)) { scheduleMethod = function (action) { var id = nextHandle++; tasksByHandle[id] = action; setImmediate(function () { runTask(id); }); return id; }; } else if (typeof process !== 'undefined' && {}.toString.call(process) === '[object process]') { scheduleMethod = function (action) { var id = nextHandle++; tasksByHandle[id] = action; process.nextTick(function () { runTask(id); }); return id; }; } else if (postMessageSupported()) { var MSG_PREFIX = 'ms.rx.schedule' + Math.random(); function onGlobalPostMessage(event) { // Only if we're a match to avoid any other global events if (typeof event.data === 'string' && event.data.substring(0, MSG_PREFIX.length) === MSG_PREFIX) { runTask(event.data.substring(MSG_PREFIX.length)); } } if (root.addEventListener) { root.addEventListener('message', onGlobalPostMessage, false); } else { root.attachEvent('onmessage', onGlobalPostMessage, false); } scheduleMethod = function (action) { var id = nextHandle++; tasksByHandle[id] = action; root.postMessage(MSG_PREFIX + currentId, '*'); return id; }; } else if (!!root.MessageChannel) { var channel = new root.MessageChannel(); channel.port1.onmessage = function (e) { runTask(e.data); }; scheduleMethod = function (action) { var id = nextHandle++; tasksByHandle[id] = action; channel.port2.postMessage(id); return id; }; } else if ('document' in root && 'onreadystatechange' in root.document.createElement('script')) { scheduleMethod = function (action) { var scriptElement = root.document.createElement('script'); var id = nextHandle++; tasksByHandle[id] = action; scriptElement.onreadystatechange = function () { runTask(id); scriptElement.onreadystatechange = null; scriptElement.parentNode.removeChild(scriptElement); scriptElement = null; }; root.document.documentElement.appendChild(scriptElement); return id; }; } else { scheduleMethod = function (action) { var id = nextHandle++; tasksByHandle[id] = action; localSetTimeout(function () { runTask(id); }, 0); return id; }; } }()); /** * Gets a scheduler that schedules work via a timed callback based upon platform. */ var timeoutScheduler = Scheduler.timeout = Scheduler.default = (function () { function scheduleNow(state, action) { var scheduler = this, disposable = new SingleAssignmentDisposable(); var id = scheduleMethod(function () { if (!disposable.isDisposed) { disposable.setDisposable(action(scheduler, state)); } }); return new CompositeDisposable(disposable, disposableCreate(function () { clearMethod(id); })); } function scheduleRelative(state, dueTime, action) { var scheduler = this, dt = Scheduler.normalize(dueTime); if (dt === 0) { return scheduler.scheduleWithState(state, action); } var disposable = new SingleAssignmentDisposable(); var id = localSetTimeout(function () { if (!disposable.isDisposed) { disposable.setDisposable(action(scheduler, state)); } }, dt); return new CompositeDisposable(disposable, disposableCreate(function () { localClearTimeout(id); })); } function scheduleAbsolute(state, dueTime, action) { return this.scheduleWithRelativeAndState(state, dueTime - this.now(), action); } return new Scheduler(defaultNow, scheduleNow, scheduleRelative, scheduleAbsolute); })(); var CatchScheduler = (function (__super__) { function scheduleNow(state, action) { return this._scheduler.scheduleWithState(state, this._wrap(action)); } function scheduleRelative(state, dueTime, action) { return this._scheduler.scheduleWithRelativeAndState(state, dueTime, this._wrap(action)); } function scheduleAbsolute(state, dueTime, action) { return this._scheduler.scheduleWithAbsoluteAndState(state, dueTime, this._wrap(action)); } inherits(CatchScheduler, __super__); function CatchScheduler(scheduler, handler) { this._scheduler = scheduler; this._handler = handler; this._recursiveOriginal = null; this._recursiveWrapper = null; __super__.call(this, this._scheduler.now.bind(this._scheduler), scheduleNow, scheduleRelative, scheduleAbsolute); } CatchScheduler.prototype._clone = function (scheduler) { return new CatchScheduler(scheduler, this._handler); }; CatchScheduler.prototype._wrap = function (action) { var parent = this; return function (self, state) { try { return action(parent._getRecursiveWrapper(self), state); } catch (e) { if (!parent._handler(e)) { throw e; } return disposableEmpty; } }; }; CatchScheduler.prototype._getRecursiveWrapper = function (scheduler) { if (this._recursiveOriginal !== scheduler) { this._recursiveOriginal = scheduler; var wrapper = this._clone(scheduler); wrapper._recursiveOriginal = scheduler; wrapper._recursiveWrapper = wrapper; this._recursiveWrapper = wrapper; } return this._recursiveWrapper; }; CatchScheduler.prototype.schedulePeriodicWithState = function (state, period, action) { var self = this, failed = false, d = new SingleAssignmentDisposable(); d.setDisposable(this._scheduler.schedulePeriodicWithState(state, period, function (state1) { if (failed) { return null; } try { return action(state1); } catch (e) { failed = true; if (!self._handler(e)) { throw e; } d.dispose(); return null; } })); return d; }; return CatchScheduler; }(Scheduler)); /** * Represents a notification to an observer. */ var Notification = Rx.Notification = (function () { function Notification(kind, value, exception, accept, acceptObservable, toString) { this.kind = kind; this.value = value; this.exception = exception; this._accept = accept; this._acceptObservable = acceptObservable; this.toString = toString; } /** * Invokes the delegate corresponding to the notification or the observer's method corresponding to the notification and returns the produced result. * * @memberOf Notification * @param {Any} observerOrOnNext Delegate to invoke for an OnNext notification or Observer to invoke the notification on.. * @param {Function} onError Delegate to invoke for an OnError notification. * @param {Function} onCompleted Delegate to invoke for an OnCompleted notification. * @returns {Any} Result produced by the observation. */ Notification.prototype.accept = function (observerOrOnNext, onError, onCompleted) { return observerOrOnNext && typeof observerOrOnNext === 'object' ? this._acceptObservable(observerOrOnNext) : this._accept(observerOrOnNext, onError, onCompleted); }; /** * Returns an observable sequence with a single notification. * * @memberOf Notifications * @param {Scheduler} [scheduler] Scheduler to send out the notification calls on. * @returns {Observable} The observable sequence that surfaces the behavior of the notification upon subscription. */ Notification.prototype.toObservable = function (scheduler) { var self = this; isScheduler(scheduler) || (scheduler = immediateScheduler); return new AnonymousObservable(function (observer) { return scheduler.scheduleWithState(self, function (_, notification) { notification._acceptObservable(observer); notification.kind === 'N' && observer.onCompleted(); }); }); }; return Notification; })(); /** * Creates an object that represents an OnNext notification to an observer. * @param {Any} value The value contained in the notification. * @returns {Notification} The OnNext notification containing the value. */ var notificationCreateOnNext = Notification.createOnNext = (function () { function _accept(onNext) { return onNext(this.value); } function _acceptObservable(observer) { return observer.onNext(this.value); } function toString() { return 'OnNext(' + this.value + ')'; } return function (value) { return new Notification('N', value, null, _accept, _acceptObservable, toString); }; }()); /** * Creates an object that represents an OnError notification to an observer. * @param {Any} error The exception contained in the notification. * @returns {Notification} The OnError notification containing the exception. */ var notificationCreateOnError = Notification.createOnError = (function () { function _accept (onNext, onError) { return onError(this.exception); } function _acceptObservable(observer) { return observer.onError(this.exception); } function toString () { return 'OnError(' + this.exception + ')'; } return function (e) { return new Notification('E', null, e, _accept, _acceptObservable, toString); }; }()); /** * Creates an object that represents an OnCompleted notification to an observer. * @returns {Notification} The OnCompleted notification. */ var notificationCreateOnCompleted = Notification.createOnCompleted = (function () { function _accept (onNext, onError, onCompleted) { return onCompleted(); } function _acceptObservable(observer) { return observer.onCompleted(); } function toString () { return 'OnCompleted()'; } return function () { return new Notification('C', null, null, _accept, _acceptObservable, toString); }; }()); var Enumerator = Rx.internals.Enumerator = function (next) { this._next = next; }; Enumerator.prototype.next = function () { return this._next(); }; Enumerator.prototype[$iterator$] = function () { return this; } var Enumerable = Rx.internals.Enumerable = function (iterator) { this._iterator = iterator; }; Enumerable.prototype[$iterator$] = function () { return this._iterator(); }; Enumerable.prototype.concat = function () { var sources = this; return new AnonymousObservable(function (o) { var e = sources[$iterator$](); var isDisposed, subscription = new SerialDisposable(); var cancelable = immediateScheduler.scheduleRecursive(function (self) { if (isDisposed) { return; } try { var currentItem = e.next(); } catch (ex) { return o.onError(ex); } if (currentItem.done) { return o.onCompleted(); } // Check if promise var currentValue = currentItem.value; isPromise(currentValue) && (currentValue = observableFromPromise(currentValue)); var d = new SingleAssignmentDisposable(); subscription.setDisposable(d); d.setDisposable(currentValue.subscribe( function(x) { o.onNext(x); }, function(err) { o.onError(err); }, self) ); }); return new CompositeDisposable(subscription, cancelable, disposableCreate(function () { isDisposed = true; })); }); }; Enumerable.prototype.catchError = function () { var sources = this; return new AnonymousObservable(function (o) { var e = sources[$iterator$](); var isDisposed, subscription = new SerialDisposable(); var cancelable = immediateScheduler.scheduleRecursiveWithState(null, function (lastException, self) { if (isDisposed) { return; } try { var currentItem = e.next(); } catch (ex) { return observer.onError(ex); } if (currentItem.done) { if (lastException !== null) { o.onError(lastException); } else { o.onCompleted(); } return; } // Check if promise var currentValue = currentItem.value; isPromise(currentValue) && (currentValue = observableFromPromise(currentValue)); var d = new SingleAssignmentDisposable(); subscription.setDisposable(d); d.setDisposable(currentValue.subscribe( function(x) { o.onNext(x); }, self, function() { o.onCompleted(); })); }); return new CompositeDisposable(subscription, cancelable, disposableCreate(function () { isDisposed = true; })); }); }; Enumerable.prototype.catchErrorWhen = function (notificationHandler) { var sources = this; return new AnonymousObservable(function (o) { var exceptions = new Subject(), notifier = new Subject(), handled = notificationHandler(exceptions), notificationDisposable = handled.subscribe(notifier); var e = sources[$iterator$](); var isDisposed, lastException, subscription = new SerialDisposable(); var cancelable = immediateScheduler.scheduleRecursive(function (self) { if (isDisposed) { return; } try { var currentItem = e.next(); } catch (ex) { return o.onError(ex); } if (currentItem.done) { if (lastException) { o.onError(lastException); } else { o.onCompleted(); } return; } // Check if promise var currentValue = currentItem.value; isPromise(currentValue) && (currentValue = observableFromPromise(currentValue)); var outer = new SingleAssignmentDisposable(); var inner = new SingleAssignmentDisposable(); subscription.setDisposable(new CompositeDisposable(inner, outer)); outer.setDisposable(currentValue.subscribe( function(x) { o.onNext(x); }, function (exn) { inner.setDisposable(notifier.subscribe(self, function(ex) { o.onError(ex); }, function() { o.onCompleted(); })); exceptions.onNext(exn); }, function() { o.onCompleted(); })); }); return new CompositeDisposable(notificationDisposable, subscription, cancelable, disposableCreate(function () { isDisposed = true; })); }); }; var enumerableRepeat = Enumerable.repeat = function (value, repeatCount) { if (repeatCount == null) { repeatCount = -1; } return new Enumerable(function () { var left = repeatCount; return new Enumerator(function () { if (left === 0) { return doneEnumerator; } if (left > 0) { left--; } return { done: false, value: value }; }); }); }; var enumerableOf = Enumerable.of = function (source, selector, thisArg) { if (selector) { var selectorFn = bindCallback(selector, thisArg, 3); } return new Enumerable(function () { var index = -1; return new Enumerator( function () { return ++index < source.length ? { done: false, value: !selector ? source[index] : selectorFn(source[index], index, source) } : doneEnumerator; }); }); }; /** * Supports push-style iteration over an observable sequence. */ var Observer = Rx.Observer = function () { }; /** * Creates a notification callback from an observer. * @returns The action that forwards its input notification to the underlying observer. */ Observer.prototype.toNotifier = function () { var observer = this; return function (n) { return n.accept(observer); }; }; /** * Hides the identity of an observer. * @returns An observer that hides the identity of the specified observer. */ Observer.prototype.asObserver = function () { return new AnonymousObserver(this.onNext.bind(this), this.onError.bind(this), this.onCompleted.bind(this)); }; /** * Checks access to the observer for grammar violations. This includes checking for multiple OnError or OnCompleted calls, as well as reentrancy in any of the observer methods. * If a violation is detected, an Error is thrown from the offending observer method call. * @returns An observer that checks callbacks invocations against the observer grammar and, if the checks pass, forwards those to the specified observer. */ Observer.prototype.checked = function () { return new CheckedObserver(this); }; /** * Creates an observer from the specified OnNext, along with optional OnError, and OnCompleted actions. * @param {Function} [onNext] Observer's OnNext action implementation. * @param {Function} [onError] Observer's OnError action implementation. * @param {Function} [onCompleted] Observer's OnCompleted action implementation. * @returns {Observer} The observer object implemented using the given actions. */ var observerCreate = Observer.create = function (onNext, onError, onCompleted) { onNext || (onNext = noop); onError || (onError = defaultError); onCompleted || (onCompleted = noop); return new AnonymousObserver(onNext, onError, onCompleted); }; /** * Creates an observer from a notification callback. * * @static * @memberOf Observer * @param {Function} handler Action that handles a notification. * @returns The observer object that invokes the specified handler using a notification corresponding to each message it receives. */ Observer.fromNotifier = function (handler, thisArg) { return new AnonymousObserver(function (x) { return handler.call(thisArg, notificationCreateOnNext(x)); }, function (e) { return handler.call(thisArg, notificationCreateOnError(e)); }, function () { return handler.call(thisArg, notificationCreateOnCompleted()); }); }; /** * Schedules the invocation of observer methods on the given scheduler. * @param {Scheduler} scheduler Scheduler to schedule observer messages on. * @returns {Observer} Observer whose messages are scheduled on the given scheduler. */ Observer.prototype.notifyOn = function (scheduler) { return new ObserveOnObserver(scheduler, this); }; Observer.prototype.makeSafe = function(disposable) { return new AnonymousSafeObserver(this._onNext, this._onError, this._onCompleted, disposable); }; /** * Abstract base class for implementations of the Observer class. * This base class enforces the grammar of observers where OnError and OnCompleted are terminal messages. */ var AbstractObserver = Rx.internals.AbstractObserver = (function (__super__) { inherits(AbstractObserver, __super__); /** * Creates a new observer in a non-stopped state. */ function AbstractObserver() { this.isStopped = false; __super__.call(this); } // Must be implemented by other observers AbstractObserver.prototype.next = notImplemented; AbstractObserver.prototype.error = notImplemented; AbstractObserver.prototype.completed = notImplemented; /** * Notifies the observer of a new element in the sequence. * @param {Any} value Next element in the sequence. */ AbstractObserver.prototype.onNext = function (value) { if (!this.isStopped) { this.next(value); } }; /** * Notifies the observer that an exception has occurred. * @param {Any} error The error that has occurred. */ AbstractObserver.prototype.onError = function (error) { if (!this.isStopped) { this.isStopped = true; this.error(error); } }; /** * Notifies the observer of the end of the sequence. */ AbstractObserver.prototype.onCompleted = function () { if (!this.isStopped) { this.isStopped = true; this.completed(); } }; /** * Disposes the observer, causing it to transition to the stopped state. */ AbstractObserver.prototype.dispose = function () { this.isStopped = true; }; AbstractObserver.prototype.fail = function (e) { if (!this.isStopped) { this.isStopped = true; this.error(e); return true; } return false; }; return AbstractObserver; }(Observer)); /** * Class to create an Observer instance from delegate-based implementations of the on* methods. */ var AnonymousObserver = Rx.AnonymousObserver = (function (__super__) { inherits(AnonymousObserver, __super__); /** * Creates an observer from the specified OnNext, OnError, and OnCompleted actions. * @param {Any} onNext Observer's OnNext action implementation. * @param {Any} onError Observer's OnError action implementation. * @param {Any} onCompleted Observer's OnCompleted action implementation. */ function AnonymousObserver(onNext, onError, onCompleted) { __super__.call(this); this._onNext = onNext; this._onError = onError; this._onCompleted = onCompleted; } /** * Calls the onNext action. * @param {Any} value Next element in the sequence. */ AnonymousObserver.prototype.next = function (value) { this._onNext(value); }; /** * Calls the onError action. * @param {Any} error The error that has occurred. */ AnonymousObserver.prototype.error = function (error) { this._onError(error); }; /** * Calls the onCompleted action. */ AnonymousObserver.prototype.completed = function () { this._onCompleted(); }; return AnonymousObserver; }(AbstractObserver)); var CheckedObserver = (function (__super__) { inherits(CheckedObserver, __super__); function CheckedObserver(observer) { __super__.call(this); this._observer = observer; this._state = 0; // 0 - idle, 1 - busy, 2 - done } var CheckedObserverPrototype = CheckedObserver.prototype; CheckedObserverPrototype.onNext = function (value) { this.checkAccess(); var res = tryCatch(this._observer.onNext).call(this._observer, value); this._state = 0; res === errorObj && thrower(res.e); }; CheckedObserverPrototype.onError = function (err) { this.checkAccess(); var res = tryCatch(this._observer.onError).call(this._observer, err); this._state = 2; res === errorObj && thrower(res.e); }; CheckedObserverPrototype.onCompleted = function () { this.checkAccess(); var res = tryCatch(this._observer.onCompleted).call(this._observer); this._state = 2; res === errorObj && thrower(res.e); }; CheckedObserverPrototype.checkAccess = function () { if (this._state === 1) { throw new Error('Re-entrancy detected'); } if (this._state === 2) { throw new Error('Observer completed'); } if (this._state === 0) { this._state = 1; } }; return CheckedObserver; }(Observer)); var ScheduledObserver = Rx.internals.ScheduledObserver = (function (__super__) { inherits(ScheduledObserver, __super__); function ScheduledObserver(scheduler, observer) { __super__.call(this); this.scheduler = scheduler; this.observer = observer; this.isAcquired = false; this.hasFaulted = false; this.queue = []; this.disposable = new SerialDisposable(); } ScheduledObserver.prototype.next = function (value) { var self = this; this.queue.push(function () { self.observer.onNext(value); }); }; ScheduledObserver.prototype.error = function (e) { var self = this; this.queue.push(function () { self.observer.onError(e); }); }; ScheduledObserver.prototype.completed = function () { var self = this; this.queue.push(function () { self.observer.onCompleted(); }); }; ScheduledObserver.prototype.ensureActive = function () { var isOwner = false, parent = this; if (!this.hasFaulted && this.queue.length > 0) { isOwner = !this.isAcquired; this.isAcquired = true; } if (isOwner) { this.disposable.setDisposable(this.scheduler.scheduleRecursive(function (self) { var work; if (parent.queue.length > 0) { work = parent.queue.shift(); } else { parent.isAcquired = false; return; } try { work(); } catch (ex) { parent.queue = []; parent.hasFaulted = true; throw ex; } self(); })); } }; ScheduledObserver.prototype.dispose = function () { __super__.prototype.dispose.call(this); this.disposable.dispose(); }; return ScheduledObserver; }(AbstractObserver)); var ObserveOnObserver = (function (__super__) { inherits(ObserveOnObserver, __super__); function ObserveOnObserver(scheduler, observer, cancel) { __super__.call(this, scheduler, observer); this._cancel = cancel; } ObserveOnObserver.prototype.next = function (value) { __super__.prototype.next.call(this, value); this.ensureActive(); }; ObserveOnObserver.prototype.error = function (e) { __super__.prototype.error.call(this, e); this.ensureActive(); }; ObserveOnObserver.prototype.completed = function () { __super__.prototype.completed.call(this); this.ensureActive(); }; ObserveOnObserver.prototype.dispose = function () { __super__.prototype.dispose.call(this); this._cancel && this._cancel.dispose(); this._cancel = null; }; return ObserveOnObserver; })(ScheduledObserver); var observableProto; /** * Represents a push-style collection. */ var Observable = Rx.Observable = (function () { function Observable(subscribe) { if (Rx.config.longStackSupport && hasStacks) { try { throw new Error(); } catch (e) { this.stack = e.stack.substring(e.stack.indexOf("\n") + 1); } var self = this; this._subscribe = function (observer) { var oldOnError = observer.onError.bind(observer); observer.onError = function (err) { makeStackTraceLong(err, self); oldOnError(err); }; return subscribe.call(self, observer); }; } else { this._subscribe = subscribe; } } observableProto = Observable.prototype; /** * Subscribes an observer to the observable sequence. * @param {Mixed} [observerOrOnNext] The object that is to receive notifications or an action to invoke for each element in the observable sequence. * @param {Function} [onError] Action to invoke upon exceptional termination of the observable sequence. * @param {Function} [onCompleted] Action to invoke upon graceful termination of the observable sequence. * @returns {Diposable} A disposable handling the subscriptions and unsubscriptions. */ observableProto.subscribe = observableProto.forEach = function (observerOrOnNext, onError, onCompleted) { return this._subscribe(typeof observerOrOnNext === 'object' ? observerOrOnNext : observerCreate(observerOrOnNext, onError, onCompleted)); }; /** * Subscribes to the next value in the sequence with an optional "this" argument. * @param {Function} onNext The function to invoke on each element in the observable sequence. * @param {Any} [thisArg] Object to use as this when executing callback. * @returns {Disposable} A disposable handling the subscriptions and unsubscriptions. */ observableProto.subscribeOnNext = function (onNext, thisArg) { return this._subscribe(observerCreate(typeof thisArg !== 'undefined' ? function(x) { onNext.call(thisArg, x); } : onNext)); }; /** * Subscribes to an exceptional condition in the sequence with an optional "this" argument. * @param {Function} onError The function to invoke upon exceptional termination of the observable sequence. * @param {Any} [thisArg] Object to use as this when executing callback. * @returns {Disposable} A disposable handling the subscriptions and unsubscriptions. */ observableProto.subscribeOnError = function (onError, thisArg) { return this._subscribe(observerCreate(null, typeof thisArg !== 'undefined' ? function(e) { onError.call(thisArg, e); } : onError)); }; /** * Subscribes to the next value in the sequence with an optional "this" argument. * @param {Function} onCompleted The function to invoke upon graceful termination of the observable sequence. * @param {Any} [thisArg] Object to use as this when executing callback. * @returns {Disposable} A disposable handling the subscriptions and unsubscriptions. */ observableProto.subscribeOnCompleted = function (onCompleted, thisArg) { return this._subscribe(observerCreate(null, null, typeof thisArg !== 'undefined' ? function() { onCompleted.call(thisArg); } : onCompleted)); }; return Observable; })(); var ObservableBase = Rx.ObservableBase = (function (__super__) { inherits(ObservableBase, __super__); function fixSubscriber(subscriber) { return subscriber && isFunction(subscriber.dispose) ? subscriber : isFunction(subscriber) ? disposableCreate(subscriber) : disposableEmpty; } function setDisposable(s, state) { var ado = state[0], self = state[1]; var sub = tryCatch(self.subscribeCore).call(self, ado); if (sub === errorObj) { if(!ado.fail(errorObj.e)) { return thrower(errorObj.e); } } ado.setDisposable(fixSubscriber(sub)); } function subscribe(observer) { var ado = new AutoDetachObserver(observer), state = [ado, this]; if (currentThreadScheduler.scheduleRequired()) { currentThreadScheduler.scheduleWithState(state, setDisposable); } else { setDisposable(null, state); } return ado; } function ObservableBase() { __super__.call(this, subscribe); } ObservableBase.prototype.subscribeCore = notImplemented; return ObservableBase; }(Observable)); /** * Wraps the source sequence in order to run its observer callbacks on the specified scheduler. * * This only invokes observer callbacks on a scheduler. In case the subscription and/or unsubscription actions have side-effects * that require to be run on a scheduler, use subscribeOn. * * @param {Scheduler} scheduler Scheduler to notify observers on. * @returns {Observable} The source sequence whose observations happen on the specified scheduler. */ observableProto.observeOn = function (scheduler) { var source = this; return new AnonymousObservable(function (observer) { return source.subscribe(new ObserveOnObserver(scheduler, observer)); }, source); }; /** * Wraps the source sequence in order to run its subscription and unsubscription logic on the specified scheduler. This operation is not commonly used; * see the remarks section for more information on the distinction between subscribeOn and observeOn. * This only performs the side-effects of subscription and unsubscription on the specified scheduler. In order to invoke observer * callbacks on a scheduler, use observeOn. * @param {Scheduler} scheduler Scheduler to perform subscription and unsubscription actions on. * @returns {Observable} The source sequence whose subscriptions and unsubscriptions happen on the specified scheduler. */ observableProto.subscribeOn = function (scheduler) { var source = this; return new AnonymousObservable(function (observer) { var m = new SingleAssignmentDisposable(), d = new SerialDisposable(); d.setDisposable(m); m.setDisposable(scheduler.schedule(function () { d.setDisposable(new ScheduledDisposable(scheduler, source.subscribe(observer))); })); return d; }, source); }; /** * Converts a Promise to an Observable sequence * @param {Promise} An ES6 Compliant promise. * @returns {Observable} An Observable sequence which wraps the existing promise success and failure. */ var observableFromPromise = Observable.fromPromise = function (promise) { return observableDefer(function () { var subject = new Rx.AsyncSubject(); promise.then( function (value) { subject.onNext(value); subject.onCompleted(); }, subject.onError.bind(subject)); return subject; }); }; /* * Converts an existing observable sequence to an ES6 Compatible Promise * @example * var promise = Rx.Observable.return(42).toPromise(RSVP.Promise); * * // With config * Rx.config.Promise = RSVP.Promise; * var promise = Rx.Observable.return(42).toPromise(); * @param {Function} [promiseCtor] The constructor of the promise. If not provided, it looks for it in Rx.config.Promise. * @returns {Promise} An ES6 compatible promise with the last value from the observable sequence. */ observableProto.toPromise = function (promiseCtor) { promiseCtor || (promiseCtor = Rx.config.Promise); if (!promiseCtor) { throw new NotSupportedError('Promise type not provided nor in Rx.config.Promise'); } var source = this; return new promiseCtor(function (resolve, reject) { // No cancellation can be done var value, hasValue = false; source.subscribe(function (v) { value = v; hasValue = true; }, reject, function () { hasValue && resolve(value); }); }); }; var ToArrayObservable = (function(__super__) { inherits(ToArrayObservable, __super__); function ToArrayObservable(source) { this.source = source; __super__.call(this); } ToArrayObservable.prototype.subscribeCore = function(observer) { return this.source.subscribe(new ToArrayObserver(observer)); }; return ToArrayObservable; }(ObservableBase)); function ToArrayObserver(observer) { this.observer = observer; this.a = []; this.isStopped = false; } ToArrayObserver.prototype.onNext = function (x) { if(!this.isStopped) { this.a.push(x); } }; ToArrayObserver.prototype.onError = function (e) { if (!this.isStopped) { this.isStopped = true; this.observer.onError(e); } }; ToArrayObserver.prototype.onCompleted = function () { if (!this.isStopped) { this.isStopped = true; this.observer.onNext(this.a); this.observer.onCompleted(); } }; ToArrayObserver.prototype.dispose = function () { this.isStopped = true; } ToArrayObserver.prototype.fail = function (e) { if (!this.isStopped) { this.isStopped = true; this.observer.onError(e); return true; } return false; }; /** * Creates an array from an observable sequence. * @returns {Observable} An observable sequence containing a single element with a list containing all the elements of the source sequence. */ observableProto.toArray = function () { return new ToArrayObservable(this); }; /** * Creates an observable sequence from a specified subscribe method implementation. * @example * var res = Rx.Observable.create(function (observer) { return function () { } ); * var res = Rx.Observable.create(function (observer) { return Rx.Disposable.empty; } ); * var res = Rx.Observable.create(function (observer) { } ); * @param {Function} subscribe Implementation of the resulting observable sequence's subscribe method, returning a function that will be wrapped in a Disposable. * @returns {Observable} The observable sequence with the specified implementation for the Subscribe method. */ Observable.create = Observable.createWithDisposable = function (subscribe, parent) { return new AnonymousObservable(subscribe, parent); }; /** * Returns an observable sequence that invokes the specified factory function whenever a new observer subscribes. * * @example * var res = Rx.Observable.defer(function () { return Rx.Observable.fromArray([1,2,3]); }); * @param {Function} observableFactory Observable factory function to invoke for each observer that subscribes to the resulting sequence or Promise. * @returns {Observable} An observable sequence whose observers trigger an invocation of the given observable factory function. */ var observableDefer = Observable.defer = function (observableFactory) { return new AnonymousObservable(function (observer) { var result; try { result = observableFactory(); } catch (e) { return observableThrow(e).subscribe(observer); } isPromise(result) && (result = observableFromPromise(result)); return result.subscribe(observer); }); }; /** * Returns an empty observable sequence, using the specified scheduler to send out the single OnCompleted message. * * @example * var res = Rx.Observable.empty(); * var res = Rx.Observable.empty(Rx.Scheduler.timeout); * @param {Scheduler} [scheduler] Scheduler to send the termination call on. * @returns {Observable} An observable sequence with no elements. */ var observableEmpty = Observable.empty = function (scheduler) { isScheduler(scheduler) || (scheduler = immediateScheduler); return new AnonymousObservable(function (observer) { return scheduler.scheduleWithState(null, function () { observer.onCompleted(); }); }); }; var FromObservable = (function(__super__) { inherits(FromObservable, __super__); function FromObservable(iterable, mapper, scheduler) { this.iterable = iterable; this.mapper = mapper; this.scheduler = scheduler; __super__.call(this); } FromObservable.prototype.subscribeCore = function (observer) { var sink = new FromSink(observer, this); return sink.run(); }; return FromObservable; }(ObservableBase)); var FromSink = (function () { function FromSink(observer, parent) { this.observer = observer; this.parent = parent; } FromSink.prototype.run = function () { var list = Object(this.parent.iterable), it = getIterable(list), observer = this.observer, mapper = this.parent.mapper; function loopRecursive(i, recurse) { try { var next = it.next(); } catch (e) { return observer.onError(e); } if (next.done) { return observer.onCompleted(); } var result = next.value; if (mapper) { try { result = mapper(result, i); } catch (e) { return observer.onError(e); } } observer.onNext(result); recurse(i + 1); } return this.parent.scheduler.scheduleRecursiveWithState(0, loopRecursive); }; return FromSink; }()); var maxSafeInteger = Math.pow(2, 53) - 1; function StringIterable(str) { this._s = s; } StringIterable.prototype[$iterator$] = function () { return new StringIterator(this._s); }; function StringIterator(str) { this._s = s; this._l = s.length; this._i = 0; } StringIterator.prototype[$iterator$] = function () { return this; }; StringIterator.prototype.next = function () { return this._i < this._l ? { done: false, value: this._s.charAt(this._i++) } : doneEnumerator; }; function ArrayIterable(a) { this._a = a; } ArrayIterable.prototype[$iterator$] = function () { return new ArrayIterator(this._a); }; function ArrayIterator(a) { this._a = a; this._l = toLength(a); this._i = 0; } ArrayIterator.prototype[$iterator$] = function () { return this; }; ArrayIterator.prototype.next = function () { return this._i < this._l ? { done: false, value: this._a[this._i++] } : doneEnumerator; }; function numberIsFinite(value) { return typeof value === 'number' && root.isFinite(value); } function isNan(n) { return n !== n; } function getIterable(o) { var i = o[$iterator$], it; if (!i && typeof o === 'string') { it = new StringIterable(o); return it[$iterator$](); } if (!i && o.length !== undefined) { it = new ArrayIterable(o); return it[$iterator$](); } if (!i) { throw new TypeError('Object is not iterable'); } return o[$iterator$](); } function sign(value) { var number = +value; if (number === 0) { return number; } if (isNaN(number)) { return number; } return number < 0 ? -1 : 1; } function toLength(o) { var len = +o.length; if (isNaN(len)) { return 0; } if (len === 0 || !numberIsFinite(len)) { return len; } len = sign(len) * Math.floor(Math.abs(len)); if (len <= 0) { return 0; } if (len > maxSafeInteger) { return maxSafeInteger; } return len; } /** * This method creates a new Observable sequence from an array-like or iterable object. * @param {Any} arrayLike An array-like or iterable object to convert to an Observable sequence. * @param {Function} [mapFn] Map function to call on every element of the array. * @param {Any} [thisArg] The context to use calling the mapFn if provided. * @param {Scheduler} [scheduler] Optional scheduler to use for scheduling. If not provided, defaults to Scheduler.currentThread. */ var observableFrom = Observable.from = function (iterable, mapFn, thisArg, scheduler) { if (iterable == null) { throw new Error('iterable cannot be null.') } if (mapFn && !isFunction(mapFn)) { throw new Error('mapFn when provided must be a function'); } if (mapFn) { var mapper = bindCallback(mapFn, thisArg, 2); } isScheduler(scheduler) || (scheduler = currentThreadScheduler); return new FromObservable(iterable, mapper, scheduler); } var FromArrayObservable = (function(__super__) { inherits(FromArrayObservable, __super__); function FromArrayObservable(args, scheduler) { this.args = args; this.scheduler = scheduler; __super__.call(this); } FromArrayObservable.prototype.subscribeCore = function (observer) { var sink = new FromArraySink(observer, this); return sink.run(); }; return FromArrayObservable; }(ObservableBase)); function FromArraySink(observer, parent) { this.observer = observer; this.parent = parent; } FromArraySink.prototype.run = function () { var observer = this.observer, args = this.parent.args, len = args.length; function loopRecursive(i, recurse) { if (i < len) { observer.onNext(args[i]); recurse(i + 1); } else { observer.onCompleted(); } } return this.parent.scheduler.scheduleRecursiveWithState(0, loopRecursive); }; /** * Converts an array to an observable sequence, using an optional scheduler to enumerate the array. * @deprecated use Observable.from or Observable.of * @param {Scheduler} [scheduler] Scheduler to run the enumeration of the input sequence on. * @returns {Observable} The observable sequence whose elements are pulled from the given enumerable sequence. */ var observableFromArray = Observable.fromArray = function (array, scheduler) { isScheduler(scheduler) || (scheduler = currentThreadScheduler); return new FromArrayObservable(array, scheduler) }; /** * Generates an observable sequence by running a state-driven loop producing the sequence's elements, using the specified scheduler to send out observer messages. * * @example * var res = Rx.Observable.generate(0, function (x) { return x < 10; }, function (x) { return x + 1; }, function (x) { return x; }); * var res = Rx.Observable.generate(0, function (x) { return x < 10; }, function (x) { return x + 1; }, function (x) { return x; }, Rx.Scheduler.timeout); * @param {Mixed} initialState Initial state. * @param {Function} condition Condition to terminate generation (upon returning false). * @param {Function} iterate Iteration step function. * @param {Function} resultSelector Selector function for results produced in the sequence. * @param {Scheduler} [scheduler] Scheduler on which to run the generator loop. If not provided, defaults to Scheduler.currentThread. * @returns {Observable} The generated sequence. */ Observable.generate = function (initialState, condition, iterate, resultSelector, scheduler) { isScheduler(scheduler) || (scheduler = currentThreadScheduler); return new AnonymousObservable(function (o) { var first = true; return scheduler.scheduleRecursiveWithState(initialState, function (state, self) { var hasResult, result; try { if (first) { first = false; } else { state = iterate(state); } hasResult = condition(state); hasResult && (result = resultSelector(state)); } catch (e) { return o.onError(e); } if (hasResult) { o.onNext(result); self(state); } else { o.onCompleted(); } }); }); }; function observableOf (scheduler, array) { isScheduler(scheduler) || (scheduler = currentThreadScheduler); return new FromArrayObservable(array, scheduler); } /** * This method creates a new Observable instance with a variable number of arguments, regardless of number or type of the arguments. * @returns {Observable} The observable sequence whose elements are pulled from the given arguments. */ Observable.of = function () { var len = arguments.length, args = new Array(len); for(var i = 0; i < len; i++) { args[i] = arguments[i]; } return new FromArrayObservable(args, currentThreadScheduler); }; /** * This method creates a new Observable instance with a variable number of arguments, regardless of number or type of the arguments. * @param {Scheduler} scheduler A scheduler to use for scheduling the arguments. * @returns {Observable} The observable sequence whose elements are pulled from the given arguments. */ Observable.ofWithScheduler = function (scheduler) { var len = arguments.length, args = new Array(len - 1); for(var i = 1; i < len; i++) { args[i - 1] = arguments[i]; } return new FromArrayObservable(args, scheduler); }; /** * Creates an Observable sequence from changes to an array using Array.observe. * @param {Array} array An array to observe changes. * @returns {Observable} An observable sequence containing changes to an array from Array.observe. */ Observable.ofArrayChanges = function(array) { if (!Array.isArray(array)) { throw new TypeError('Array.observe only accepts arrays.'); } if (typeof Array.observe !== 'function' && typeof Array.unobserve !== 'function') { throw new TypeError('Array.observe is not supported on your platform') } return new AnonymousObservable(function(observer) { function observerFn(changes) { for(var i = 0, len = changes.length; i < len; i++) { observer.onNext(changes[i]); } } Array.observe(array, observerFn); return function () { Array.unobserve(array, observerFn); }; }); }; /** * Creates an Observable sequence from changes to an object using Object.observe. * @param {Object} obj An object to observe changes. * @returns {Observable} An observable sequence containing changes to an object from Object.observe. */ Observable.ofObjectChanges = function(obj) { if (obj == null) { throw new TypeError('object must not be null or undefined.'); } if (typeof Object.observe !== 'function' && typeof Object.unobserve !== 'function') { throw new TypeError('Array.observe is not supported on your platform') } return new AnonymousObservable(function(observer) { function observerFn(changes) { for(var i = 0, len = changes.length; i < len; i++) { observer.onNext(changes[i]); } } Object.observe(obj, observerFn); return function () { Object.unobserve(obj, observerFn); }; }); }; /** * Returns a non-terminating observable sequence, which can be used to denote an infinite duration (e.g. when using reactive joins). * @returns {Observable} An observable sequence whose observers will never get called. */ var observableNever = Observable.never = function () { return new AnonymousObservable(function () { return disposableEmpty; }); }; /** * Convert an object into an observable sequence of [key, value] pairs. * @param {Object} obj The object to inspect. * @param {Scheduler} [scheduler] Scheduler to run the enumeration of the input sequence on. * @returns {Observable} An observable sequence of [key, value] pairs from the object. */ Observable.pairs = function (obj, scheduler) { scheduler || (scheduler = Rx.Scheduler.currentThread); return new AnonymousObservable(function (observer) { var keys = Object.keys(obj), len = keys.length; return scheduler.scheduleRecursiveWithState(0, function (idx, self) { if (idx < len) { var key = keys[idx]; observer.onNext([key, obj[key]]); self(idx + 1); } else { observer.onCompleted(); } }); }); }; var RangeObservable = (function(__super__) { inherits(RangeObservable, __super__); function RangeObservable(start, count, scheduler) { this.start = start; this.count = count; this.scheduler = scheduler; __super__.call(this); } RangeObservable.prototype.subscribeCore = function (observer) { var sink = new RangeSink(observer, this); return sink.run(); }; return RangeObservable; }(ObservableBase)); var RangeSink = (function () { function RangeSink(observer, parent) { this.observer = observer; this.parent = parent; } RangeSink.prototype.run = function () { var start = this.parent.start, count = this.parent.count, observer = this.observer; function loopRecursive(i, recurse) { if (i < count) { observer.onNext(start + i); recurse(i + 1); } else { observer.onCompleted(); } } return this.parent.scheduler.scheduleRecursiveWithState(0, loopRecursive); }; return RangeSink; }()); /** * Generates an observable sequence of integral numbers within a specified range, using the specified scheduler to send out observer messages. * @param {Number} start The value of the first integer in the sequence. * @param {Number} count The number of sequential integers to generate. * @param {Scheduler} [scheduler] Scheduler to run the generator loop on. If not specified, defaults to Scheduler.currentThread. * @returns {Observable} An observable sequence that contains a range of sequential integral numbers. */ Observable.range = function (start, count, scheduler) { isScheduler(scheduler) || (scheduler = currentThreadScheduler); return new RangeObservable(start, count, scheduler); }; /** * Generates an observable sequence that repeats the given element the specified number of times, using the specified scheduler to send out observer messages. * * @example * var res = Rx.Observable.repeat(42); * var res = Rx.Observable.repeat(42, 4); * 3 - res = Rx.Observable.repeat(42, 4, Rx.Scheduler.timeout); * 4 - res = Rx.Observable.repeat(42, null, Rx.Scheduler.timeout); * @param {Mixed} value Element to repeat. * @param {Number} repeatCount [Optiona] Number of times to repeat the element. If not specified, repeats indefinitely. * @param {Scheduler} scheduler Scheduler to run the producer loop on. If not specified, defaults to Scheduler.immediate. * @returns {Observable} An observable sequence that repeats the given element the specified number of times. */ Observable.repeat = function (value, repeatCount, scheduler) { isScheduler(scheduler) || (scheduler = currentThreadScheduler); return observableReturn(value, scheduler).repeat(repeatCount == null ? -1 : repeatCount); }; /** * Returns an observable sequence that contains a single element, using the specified scheduler to send out observer messages. * There is an alias called 'just' or browsers <IE9. * @param {Mixed} value Single element in the resulting observable sequence. * @param {Scheduler} scheduler Scheduler to send the single element on. If not specified, defaults to Scheduler.immediate. * @returns {Observable} An observable sequence containing the single specified element. */ var observableReturn = Observable['return'] = Observable.just = Observable.returnValue = function (value, scheduler) { isScheduler(scheduler) || (scheduler = immediateScheduler); return new AnonymousObservable(function (o) { return scheduler.scheduleWithState(value, function(_,v) { o.onNext(v); o.onCompleted(); }); }); }; /** * Returns an observable sequence that terminates with an exception, using the specified scheduler to send out the single onError message. * There is an alias to this method called 'throwError' for browsers <IE9. * @param {Mixed} error An object used for the sequence's termination. * @param {Scheduler} scheduler Scheduler to send the exceptional termination call on. If not specified, defaults to Scheduler.immediate. * @returns {Observable} The observable sequence that terminates exceptionally with the specified exception object. */ var observableThrow = Observable['throw'] = Observable.throwError = function (error, scheduler) { isScheduler(scheduler) || (scheduler = immediateScheduler); return new AnonymousObservable(function (observer) { return scheduler.schedule(function () { observer.onError(error); }); }); }; /** @deprecated use #some instead */ Observable.throwException = function () { //deprecate('throwException', 'throwError'); return Observable.throwError.apply(null, arguments); }; /** * Constructs an observable sequence that depends on a resource object, whose lifetime is tied to the resulting observable sequence's lifetime. * @param {Function} resourceFactory Factory function to obtain a resource object. * @param {Function} observableFactory Factory function to obtain an observable sequence that depends on the obtained resource. * @returns {Observable} An observable sequence whose lifetime controls the lifetime of the dependent resource object. */ Observable.using = function (resourceFactory, observableFactory) { return new AnonymousObservable(function (observer) { var disposable = disposableEmpty, resource, source; try { resource = resourceFactory(); resource && (disposable = resource); source = observableFactory(resource); } catch (exception) { return new CompositeDisposable(observableThrow(exception).subscribe(observer), disposable); } return new CompositeDisposable(source.subscribe(observer), disposable); }); }; /** * Propagates the observable sequence or Promise that reacts first. * @param {Observable} rightSource Second observable sequence or Promise. * @returns {Observable} {Observable} An observable sequence that surfaces either of the given sequences, whichever reacted first. */ observableProto.amb = function (rightSource) { var leftSource = this; return new AnonymousObservable(function (observer) { var choice, leftChoice = 'L', rightChoice = 'R', leftSubscription = new SingleAssignmentDisposable(), rightSubscription = new SingleAssignmentDisposable(); isPromise(rightSource) && (rightSource = observableFromPromise(rightSource)); function choiceL() { if (!choice) { choice = leftChoice; rightSubscription.dispose(); } } function choiceR() { if (!choice) { choice = rightChoice; leftSubscription.dispose(); } } leftSubscription.setDisposable(leftSource.subscribe(function (left) { choiceL(); if (choice === leftChoice) { observer.onNext(left); } }, function (err) { choiceL(); if (choice === leftChoice) { observer.onError(err); } }, function () { choiceL(); if (choice === leftChoice) { observer.onCompleted(); } })); rightSubscription.setDisposable(rightSource.subscribe(function (right) { choiceR(); if (choice === rightChoice) { observer.onNext(right); } }, function (err) { choiceR(); if (choice === rightChoice) { observer.onError(err); } }, function () { choiceR(); if (choice === rightChoice) { observer.onCompleted(); } })); return new CompositeDisposable(leftSubscription, rightSubscription); }); }; /** * Propagates the observable sequence or Promise that reacts first. * * @example * var = Rx.Observable.amb(xs, ys, zs); * @returns {Observable} An observable sequence that surfaces any of the given sequences, whichever reacted first. */ Observable.amb = function () { var acc = observableNever(), items = []; if (Array.isArray(arguments[0])) { items = arguments[0]; } else { for(var i = 0, len = arguments.length; i < len; i++) { items.push(arguments[i]); } } function func(previous, current) { return previous.amb(current); } for (var i = 0, len = items.length; i < len; i++) { acc = func(acc, items[i]); } return acc; }; function observableCatchHandler(source, handler) { return new AnonymousObservable(function (o) { var d1 = new SingleAssignmentDisposable(), subscription = new SerialDisposable(); subscription.setDisposable(d1); d1.setDisposable(source.subscribe(function (x) { o.onNext(x); }, function (e) { try { var result = handler(e); } catch (ex) { return o.onError(ex); } isPromise(result) && (result = observableFromPromise(result)); var d = new SingleAssignmentDisposable(); subscription.setDisposable(d); d.setDisposable(result.subscribe(o)); }, function (x) { o.onCompleted(x); })); return subscription; }, source); } /** * Continues an observable sequence that is terminated by an exception with the next observable sequence. * @example * 1 - xs.catchException(ys) * 2 - xs.catchException(function (ex) { return ys(ex); }) * @param {Mixed} handlerOrSecond Exception handler function that returns an observable sequence given the error that occurred in the first sequence, or a second observable sequence used to produce results when an error occurred in the first sequence. * @returns {Observable} An observable sequence containing the first sequence's elements, followed by the elements of the handler sequence in case an exception occurred. */ observableProto['catch'] = observableProto.catchError = observableProto.catchException = function (handlerOrSecond) { return typeof handlerOrSecond === 'function' ? observableCatchHandler(this, handlerOrSecond) : observableCatch([this, handlerOrSecond]); }; /** * Continues an observable sequence that is terminated by an exception with the next observable sequence. * @param {Array | Arguments} args Arguments or an array to use as the next sequence if an error occurs. * @returns {Observable} An observable sequence containing elements from consecutive source sequences until a source sequence terminates successfully. */ var observableCatch = Observable.catchError = Observable['catch'] = Observable.catchException = function () { var items = []; if (Array.isArray(arguments[0])) { items = arguments[0]; } else { for(var i = 0, len = arguments.length; i < len; i++) { items.push(arguments[i]); } } return enumerableOf(items).catchError(); }; /** * Merges the specified observable sequences into one observable sequence by using the selector function whenever any of the observable sequences or Promises produces an element. * This can be in the form of an argument list of observables or an array. * * @example * 1 - obs = observable.combineLatest(obs1, obs2, obs3, function (o1, o2, o3) { return o1 + o2 + o3; }); * 2 - obs = observable.combineLatest([obs1, obs2, obs3], function (o1, o2, o3) { return o1 + o2 + o3; }); * @returns {Observable} An observable sequence containing the result of combining elements of the sources using the specified result selector function. */ observableProto.combineLatest = function () { var len = arguments.length, args = new Array(len); for(var i = 0; i < len; i++) { args[i] = arguments[i]; } if (Array.isArray(args[0])) { args[0].unshift(this); } else { args.unshift(this); } return combineLatest.apply(this, args); }; /** * Merges the specified observable sequences into one observable sequence by using the selector function whenever any of the observable sequences or Promises produces an element. * * @example * 1 - obs = Rx.Observable.combineLatest(obs1, obs2, obs3, function (o1, o2, o3) { return o1 + o2 + o3; }); * 2 - obs = Rx.Observable.combineLatest([obs1, obs2, obs3], function (o1, o2, o3) { return o1 + o2 + o3; }); * @returns {Observable} An observable sequence containing the result of combining elements of the sources using the specified result selector function. */ var combineLatest = Observable.combineLatest = function () { var len = arguments.length, args = new Array(len); for(var i = 0; i < len; i++) { args[i] = arguments[i]; } var resultSelector = args.pop(); Array.isArray(args[0]) && (args = args[0]); return new AnonymousObservable(function (o) { var n = args.length, falseFactory = function () { return false; }, hasValue = arrayInitialize(n, falseFactory), hasValueAll = false, isDone = arrayInitialize(n, falseFactory), values = new Array(n); function next(i) { hasValue[i] = true; if (hasValueAll || (hasValueAll = hasValue.every(identity))) { try { var res = resultSelector.apply(null, values); } catch (e) { return o.onError(e); } o.onNext(res); } else if (isDone.filter(function (x, j) { return j !== i; }).every(identity)) { o.onCompleted(); } } function done (i) { isDone[i] = true; isDone.every(identity) && o.onCompleted(); } var subscriptions = new Array(n); for (var idx = 0; idx < n; idx++) { (function (i) { var source = args[i], sad = new SingleAssignmentDisposable(); isPromise(source) && (source = observableFromPromise(source)); sad.setDisposable(source.subscribe(function (x) { values[i] = x; next(i); }, function(e) { o.onError(e); }, function () { done(i); } )); subscriptions[i] = sad; }(idx)); } return new CompositeDisposable(subscriptions); }, this); }; /** * Concatenates all the observable sequences. This takes in either an array or variable arguments to concatenate. * @returns {Observable} An observable sequence that contains the elements of each given sequence, in sequential order. */ observableProto.concat = function () { for(var args = [], i = 0, len = arguments.length; i < len; i++) { args.push(arguments[i]); } args.unshift(this); return observableConcat.apply(null, args); }; /** * Concatenates all the observable sequences. * @param {Array | Arguments} args Arguments or an array to concat to the observable sequence. * @returns {Observable} An observable sequence that contains the elements of each given sequence, in sequential order. */ var observableConcat = Observable.concat = function () { var args; if (Array.isArray(arguments[0])) { args = arguments[0]; } else { args = new Array(arguments.length); for(var i = 0, len = arguments.length; i < len; i++) { args[i] = arguments[i]; } } return enumerableOf(args).concat(); }; /** * Concatenates an observable sequence of observable sequences. * @returns {Observable} An observable sequence that contains the elements of each observed inner sequence, in sequential order. */ observableProto.concatAll = observableProto.concatObservable = function () { return this.merge(1); }; var MergeObservable = (function (__super__) { inherits(MergeObservable, __super__); function MergeObservable(source, maxConcurrent) { this.source = source; this.maxConcurrent = maxConcurrent; __super__.call(this); } MergeObservable.prototype.subscribeCore = function(observer) { var g = new CompositeDisposable(); g.add(this.source.subscribe(new MergeObserver(observer, this.maxConcurrent, g))); return g; }; return MergeObservable; }(ObservableBase)); var MergeObserver = (function () { function MergeObserver(o, max, g) { this.o = o; this.max = max; this.g = g; this.done = false; this.q = []; this.activeCount = 0; this.isStopped = false; } MergeObserver.prototype.handleSubscribe = function (xs) { var sad = new SingleAssignmentDisposable(); this.g.add(sad); isPromise(xs) && (xs = observableFromPromise(xs)); sad.setDisposable(xs.subscribe(new InnerObserver(this, sad))); }; MergeObserver.prototype.onNext = function (innerSource) { if (this.isStopped) { return; } if(this.activeCount < this.max) { this.activeCount++; this.handleSubscribe(innerSource); } else { this.q.push(innerSource); } }; MergeObserver.prototype.onError = function (e) { if (!this.isStopped) { this.isStopped = true; this.o.onError(e); } }; MergeObserver.prototype.onCompleted = function () { if (!this.isStopped) { this.isStopped = true; this.done = true; this.activeCount === 0 && this.o.onCompleted(); } }; MergeObserver.prototype.dispose = function() { this.isStopped = true; }; MergeObserver.prototype.fail = function (e) { if (!this.isStopped) { this.isStopped = true; this.o.onError(e); return true; } return false; }; function InnerObserver(parent, sad) { this.parent = parent; this.sad = sad; this.isStopped = false; } InnerObserver.prototype.onNext = function (x) { if(!this.isStopped) { this.parent.o.onNext(x); } }; InnerObserver.prototype.onError = function (e) { if (!this.isStopped) { this.isStopped = true; this.parent.o.onError(e); } }; InnerObserver.prototype.onCompleted = function () { if(!this.isStopped) { this.isStopped = true; var parent = this.parent; parent.g.remove(this.sad); if (parent.q.length > 0) { parent.handleSubscribe(parent.q.shift()); } else { parent.activeCount--; parent.done && parent.activeCount === 0 && parent.o.onCompleted(); } } }; InnerObserver.prototype.dispose = function() { this.isStopped = true; }; InnerObserver.prototype.fail = function (e) { if (!this.isStopped) { this.isStopped = true; this.parent.o.onError(e); return true; } return false; }; return MergeObserver; }()); /** * Merges an observable sequence of observable sequences into an observable sequence, limiting the number of concurrent subscriptions to inner sequences. * Or merges two observable sequences into a single observable sequence. * * @example * 1 - merged = sources.merge(1); * 2 - merged = source.merge(otherSource); * @param {Mixed} [maxConcurrentOrOther] Maximum number of inner observable sequences being subscribed to concurrently or the second observable sequence. * @returns {Observable} The observable sequence that merges the elements of the inner sequences. */ observableProto.merge = function (maxConcurrentOrOther) { return typeof maxConcurrentOrOther !== 'number' ? observableMerge(this, maxConcurrentOrOther) : new MergeObservable(this, maxConcurrentOrOther); }; /** * Merges all the observable sequences into a single observable sequence. * The scheduler is optional and if not specified, the immediate scheduler is used. * @returns {Observable} The observable sequence that merges the elements of the observable sequences. */ var observableMerge = Observable.merge = function () { var scheduler, sources = [], i, len = arguments.length; if (!arguments[0]) { scheduler = immediateScheduler; for(i = 1; i < len; i++) { sources.push(arguments[i]); } } else if (isScheduler(arguments[0])) { scheduler = arguments[0]; for(i = 1; i < len; i++) { sources.push(arguments[i]); } } else { scheduler = immediateScheduler; for(i = 0; i < len; i++) { sources.push(arguments[i]); } } if (Array.isArray(sources[0])) { sources = sources[0]; } return observableOf(scheduler, sources).mergeAll(); }; var MergeAllObservable = (function (__super__) { inherits(MergeAllObservable, __super__); function MergeAllObservable(source) { this.source = source; __super__.call(this); } MergeAllObservable.prototype.subscribeCore = function (observer) { var g = new CompositeDisposable(), m = new SingleAssignmentDisposable(); g.add(m); m.setDisposable(this.source.subscribe(new MergeAllObserver(observer, g))); return g; }; return MergeAllObservable; }(ObservableBase)); var MergeAllObserver = (function() { function MergeAllObserver(o, g) { this.o = o; this.g = g; this.isStopped = false; this.done = false; } MergeAllObserver.prototype.onNext = function(innerSource) { if(this.isStopped) { return; } var sad = new SingleAssignmentDisposable(); this.g.add(sad); isPromise(innerSource) && (innerSource = observableFromPromise(innerSource)); sad.setDisposable(innerSource.subscribe(new InnerObserver(this, this.g, sad))); }; MergeAllObserver.prototype.onError = function (e) { if(!this.isStopped) { this.isStopped = true; this.o.onError(e); } }; MergeAllObserver.prototype.onCompleted = function () { if(!this.isStopped) { this.isStopped = true; this.done = true; this.g.length === 1 && this.o.onCompleted(); } }; MergeAllObserver.prototype.dispose = function() { this.isStopped = true; }; MergeAllObserver.prototype.fail = function (e) { if (!this.isStopped) { this.isStopped = true; this.o.onError(e); return true; } return false; }; function InnerObserver(parent, g, sad) { this.parent = parent; this.g = g; this.sad = sad; this.isStopped = false; } InnerObserver.prototype.onNext = function (x) { if (!this.isStopped) { this.parent.o.onNext(x); } }; InnerObserver.prototype.onError = function (e) { if(!this.isStopped) { this.isStopped = true; this.parent.o.onError(e); } }; InnerObserver.prototype.onCompleted = function () { if(!this.isStopped) { var parent = this.parent; this.isStopped = true; parent.g.remove(this.sad); parent.done && parent.g.length === 1 && parent.o.onCompleted(); } }; InnerObserver.prototype.dispose = function() { this.isStopped = true; }; InnerObserver.prototype.fail = function (e) { if (!this.isStopped) { this.isStopped = true; this.parent.o.onError(e); return true; } return false; }; return MergeAllObserver; }()); /** * Merges an observable sequence of observable sequences into an observable sequence. * @returns {Observable} The observable sequence that merges the elements of the inner sequences. */ observableProto.mergeAll = observableProto.mergeObservable = function () { return new MergeAllObservable(this); }; var CompositeError = Rx.CompositeError = function(errors) { this.name = "NotImplementedError"; this.innerErrors = errors; this.message = 'This contains multiple errors. Check the innerErrors'; Error.call(this); } CompositeError.prototype = Error.prototype; /** * Flattens an Observable that emits Observables into one Observable, in a way that allows an Observer to * receive all successfully emitted items from all of the source Observables without being interrupted by * an error notification from one of them. * * This behaves like Observable.prototype.mergeAll except that if any of the merged Observables notify of an * error via the Observer's onError, mergeDelayError will refrain from propagating that * error notification until all of the merged Observables have finished emitting items. * @param {Array | Arguments} args Arguments or an array to merge. * @returns {Observable} an Observable that emits all of the items emitted by the Observables emitted by the Observable */ Observable.mergeDelayError = function() { var args; if (Array.isArray(arguments[0])) { args = arguments[0]; } else { var len = arguments.length; args = new Array(len); for(var i = 0; i < len; i++) { args[i] = arguments[i]; } } var source = observableOf(null, args); return new AnonymousObservable(function (o) { var group = new CompositeDisposable(), m = new SingleAssignmentDisposable(), isStopped = false, errors = []; function setCompletion() { if (errors.length === 0) { o.onCompleted(); } else if (errors.length === 1) { o.onError(errors[0]); } else { o.onError(new CompositeError(errors)); } } group.add(m); m.setDisposable(source.subscribe( function (innerSource) { var innerSubscription = new SingleAssignmentDisposable(); group.add(innerSubscription); // Check for promises support isPromise(innerSource) && (innerSource = observableFromPromise(innerSource)); innerSubscription.setDisposable(innerSource.subscribe( function (x) { o.onNext(x); }, function (e) { errors.push(e); group.remove(innerSubscription); isStopped && group.length === 1 && setCompletion(); }, function () { group.remove(innerSubscription); isStopped && group.length === 1 && setCompletion(); })); }, function (e) { errors.push(e); isStopped = true; group.length === 1 && setCompletion(); }, function () { isStopped = true; group.length === 1 && setCompletion(); })); return group; }); }; /** * Continues an observable sequence that is terminated normally or by an exception with the next observable sequence. * @param {Observable} second Second observable sequence used to produce results after the first sequence terminates. * @returns {Observable} An observable sequence that concatenates the first and second sequence, even if the first sequence terminates exceptionally. */ observableProto.onErrorResumeNext = function (second) { if (!second) { throw new Error('Second observable is required'); } return onErrorResumeNext([this, second]); }; /** * Continues an observable sequence that is terminated normally or by an exception with the next observable sequence. * * @example * 1 - res = Rx.Observable.onErrorResumeNext(xs, ys, zs); * 1 - res = Rx.Observable.onErrorResumeNext([xs, ys, zs]); * @returns {Observable} An observable sequence that concatenates the source sequences, even if a sequence terminates exceptionally. */ var onErrorResumeNext = Observable.onErrorResumeNext = function () { var sources = []; if (Array.isArray(arguments[0])) { sources = arguments[0]; } else { for(var i = 0, len = arguments.length; i < len; i++) { sources.push(arguments[i]); } } return new AnonymousObservable(function (observer) { var pos = 0, subscription = new SerialDisposable(), cancelable = immediateScheduler.scheduleRecursive(function (self) { var current, d; if (pos < sources.length) { current = sources[pos++]; isPromise(current) && (current = observableFromPromise(current)); d = new SingleAssignmentDisposable(); subscription.setDisposable(d); d.setDisposable(current.subscribe(observer.onNext.bind(observer), self, self)); } else { observer.onCompleted(); } }); return new CompositeDisposable(subscription, cancelable); }); }; /** * Returns the values from the source observable sequence only after the other observable sequence produces a value. * @param {Observable | Promise} other The observable sequence or Promise that triggers propagation of elements of the source sequence. * @returns {Observable} An observable sequence containing the elements of the source sequence starting from the point the other sequence triggered propagation. */ observableProto.skipUntil = function (other) { var source = this; return new AnonymousObservable(function (o) { var isOpen = false; var disposables = new CompositeDisposable(source.subscribe(function (left) { isOpen && o.onNext(left); }, function (e) { o.onError(e); }, function () { isOpen && o.onCompleted(); })); isPromise(other) && (other = observableFromPromise(other)); var rightSubscription = new SingleAssignmentDisposable(); disposables.add(rightSubscription); rightSubscription.setDisposable(other.subscribe(function () { isOpen = true; rightSubscription.dispose(); }, function (e) { o.onError(e); }, function () { rightSubscription.dispose(); })); return disposables; }, source); }; /** * Transforms an observable sequence of observable sequences into an observable sequence producing values only from the most recent observable sequence. * @returns {Observable} The observable sequence that at any point in time produces the elements of the most recent inner observable sequence that has been received. */ observableProto['switch'] = observableProto.switchLatest = function () { var sources = this; return new AnonymousObservable(function (observer) { var hasLatest = false, innerSubscription = new SerialDisposable(), isStopped = false, latest = 0, subscription = sources.subscribe( function (innerSource) { var d = new SingleAssignmentDisposable(), id = ++latest; hasLatest = true; innerSubscription.setDisposable(d); // Check if Promise or Observable isPromise(innerSource) && (innerSource = observableFromPromise(innerSource)); d.setDisposable(innerSource.subscribe( function (x) { latest === id && observer.onNext(x); }, function (e) { latest === id && observer.onError(e); }, function () { if (latest === id) { hasLatest = false; isStopped && observer.onCompleted(); } })); }, function (e) { observer.onError(e); }, function () { isStopped = true; !hasLatest && observer.onCompleted(); }); return new CompositeDisposable(subscription, innerSubscription); }, sources); }; /** * Returns the values from the source observable sequence until the other observable sequence produces a value. * @param {Observable | Promise} other Observable sequence or Promise that terminates propagation of elements of the source sequence. * @returns {Observable} An observable sequence containing the elements of the source sequence up to the point the other sequence interrupted further propagation. */ observableProto.takeUntil = function (other) { var source = this; return new AnonymousObservable(function (o) { isPromise(other) && (other = observableFromPromise(other)); return new CompositeDisposable( source.subscribe(o), other.subscribe(function () { o.onCompleted(); }, function (e) { o.onError(e); }, noop) ); }, source); }; /** * Merges the specified observable sequences into one observable sequence by using the selector function only when the (first) source observable sequence produces an element. * * @example * 1 - obs = obs1.withLatestFrom(obs2, obs3, function (o1, o2, o3) { return o1 + o2 + o3; }); * 2 - obs = obs1.withLatestFrom([obs2, obs3], function (o1, o2, o3) { return o1 + o2 + o3; }); * @returns {Observable} An observable sequence containing the result of combining elements of the sources using the specified result selector function. */ observableProto.withLatestFrom = function () { var len = arguments.length, args = new Array(len) for(var i = 0; i < len; i++) { args[i] = arguments[i]; } var resultSelector = args.pop(), source = this; if (typeof source === 'undefined') { throw new Error('Source observable not found for withLatestFrom().'); } if (typeof resultSelector !== 'function') { throw new Error('withLatestFrom() expects a resultSelector function.'); } if (Array.isArray(args[0])) { args = args[0]; } return new AnonymousObservable(function (observer) { var falseFactory = function () { return false; }, n = args.length, hasValue = arrayInitialize(n, falseFactory), hasValueAll = false, values = new Array(n); var subscriptions = new Array(n + 1); for (var idx = 0; idx < n; idx++) { (function (i) { var other = args[i], sad = new SingleAssignmentDisposable(); isPromise(other) && (other = observableFromPromise(other)); sad.setDisposable(other.subscribe(function (x) { values[i] = x; hasValue[i] = true; hasValueAll = hasValue.every(identity); }, observer.onError.bind(observer), function () {})); subscriptions[i] = sad; }(idx)); } var sad = new SingleAssignmentDisposable(); sad.setDisposable(source.subscribe(function (x) { var res; var allValues = [x].concat(values); if (!hasValueAll) return; try { res = resultSelector.apply(null, allValues); } catch (ex) { observer.onError(ex); return; } observer.onNext(res); }, observer.onError.bind(observer), function () { observer.onCompleted(); })); subscriptions[n] = sad; return new CompositeDisposable(subscriptions); }, this); }; function zipArray(second, resultSelector) { var first = this; return new AnonymousObservable(function (observer) { var index = 0, len = second.length; return first.subscribe(function (left) { if (index < len) { var right = second[index++], result; try { result = resultSelector(left, right); } catch (e) { return observer.onError(e); } observer.onNext(result); } else { observer.onCompleted(); } }, function (e) { observer.onError(e); }, function () { observer.onCompleted(); }); }, first); } function falseFactory() { return false; } function emptyArrayFactory() { return []; } /** * Merges the specified observable sequences into one observable sequence by using the selector function whenever all of the observable sequences or an array have produced an element at a corresponding index. * The last element in the arguments must be a function to invoke for each series of elements at corresponding indexes in the args. * * @example * 1 - res = obs1.zip(obs2, fn); * 1 - res = x1.zip([1,2,3], fn); * @returns {Observable} An observable sequence containing the result of combining elements of the args using the specified result selector function. */ observableProto.zip = function () { if (Array.isArray(arguments[0])) { return zipArray.apply(this, arguments); } var len = arguments.length, args = new Array(len); for(var i = 0; i < len; i++) { args[i] = arguments[i]; } var parent = this, resultSelector = args.pop(); args.unshift(parent); return new AnonymousObservable(function (observer) { var n = args.length, queues = arrayInitialize(n, emptyArrayFactory), isDone = arrayInitialize(n, falseFactory); function next(i) { var res, queuedValues; if (queues.every(function (x) { return x.length > 0; })) { try { queuedValues = queues.map(function (x) { return x.shift(); }); res = resultSelector.apply(parent, queuedValues); } catch (ex) { observer.onError(ex); return; } observer.onNext(res); } else if (isDone.filter(function (x, j) { return j !== i; }).every(identity)) { observer.onCompleted(); } }; function done(i) { isDone[i] = true; if (isDone.every(function (x) { return x; })) { observer.onCompleted(); } } var subscriptions = new Array(n); for (var idx = 0; idx < n; idx++) { (function (i) { var source = args[i], sad = new SingleAssignmentDisposable(); isPromise(source) && (source = observableFromPromise(source)); sad.setDisposable(source.subscribe(function (x) { queues[i].push(x); next(i); }, function (e) { observer.onError(e); }, function () { done(i); })); subscriptions[i] = sad; })(idx); } return new CompositeDisposable(subscriptions); }, parent); }; /** * Merges the specified observable sequences into one observable sequence by using the selector function whenever all of the observable sequences have produced an element at a corresponding index. * @param arguments Observable sources. * @param {Function} resultSelector Function to invoke for each series of elements at corresponding indexes in the sources. * @returns {Observable} An observable sequence containing the result of combining elements of the sources using the specified result selector function. */ Observable.zip = function () { var len = arguments.length, args = new Array(len); for(var i = 0; i < len; i++) { args[i] = arguments[i]; } var first = args.shift(); return first.zip.apply(first, args); }; /** * Merges the specified observable sequences into one observable sequence by emitting a list with the elements of the observable sequences at corresponding indexes. * @param arguments Observable sources. * @returns {Observable} An observable sequence containing lists of elements at corresponding indexes. */ Observable.zipArray = function () { var sources; if (Array.isArray(arguments[0])) { sources = arguments[0]; } else { var len = arguments.length; sources = new Array(len); for(var i = 0; i < len; i++) { sources[i] = arguments[i]; } } return new AnonymousObservable(function (observer) { var n = sources.length, queues = arrayInitialize(n, function () { return []; }), isDone = arrayInitialize(n, function () { return false; }); function next(i) { if (queues.every(function (x) { return x.length > 0; })) { var res = queues.map(function (x) { return x.shift(); }); observer.onNext(res); } else if (isDone.filter(function (x, j) { return j !== i; }).every(identity)) { observer.onCompleted(); return; } }; function done(i) { isDone[i] = true; if (isDone.every(identity)) { observer.onCompleted(); return; } } var subscriptions = new Array(n); for (var idx = 0; idx < n; idx++) { (function (i) { subscriptions[i] = new SingleAssignmentDisposable(); subscriptions[i].setDisposable(sources[i].subscribe(function (x) { queues[i].push(x); next(i); }, function (e) { observer.onError(e); }, function () { done(i); })); })(idx); } return new CompositeDisposable(subscriptions); }); }; /** * Hides the identity of an observable sequence. * @returns {Observable} An observable sequence that hides the identity of the source sequence. */ observableProto.asObservable = function () { var source = this; return new AnonymousObservable(function (o) { return source.subscribe(o); }, this); }; /** * Projects each element of an observable sequence into zero or more buffers which are produced based on element count information. * * @example * var res = xs.bufferWithCount(10); * var res = xs.bufferWithCount(10, 1); * @param {Number} count Length of each buffer. * @param {Number} [skip] Number of elements to skip between creation of consecutive buffers. If not provided, defaults to the count. * @returns {Observable} An observable sequence of buffers. */ observableProto.bufferWithCount = function (count, skip) { if (typeof skip !== 'number') { skip = count; } return this.windowWithCount(count, skip).selectMany(function (x) { return x.toArray(); }).where(function (x) { return x.length > 0; }); }; /** * Dematerializes the explicit notification values of an observable sequence as implicit notifications. * @returns {Observable} An observable sequence exhibiting the behavior corresponding to the source sequence's notification values. */ observableProto.dematerialize = function () { var source = this; return new AnonymousObservable(function (o) { return source.subscribe(function (x) { return x.accept(o); }, function(e) { o.onError(e); }, function () { o.onCompleted(); }); }, this); }; /** * Returns an observable sequence that contains only distinct contiguous elements according to the keySelector and the comparer. * * var obs = observable.distinctUntilChanged(); * var obs = observable.distinctUntilChanged(function (x) { return x.id; }); * var obs = observable.distinctUntilChanged(function (x) { return x.id; }, function (x, y) { return x === y; }); * * @param {Function} [keySelector] A function to compute the comparison key for each element. If not provided, it projects the value. * @param {Function} [comparer] Equality comparer for computed key values. If not provided, defaults to an equality comparer function. * @returns {Observable} An observable sequence only containing the distinct contiguous elements, based on a computed key value, from the source sequence. */ observableProto.distinctUntilChanged = function (keySelector, comparer) { var source = this; comparer || (comparer = defaultComparer); return new AnonymousObservable(function (o) { var hasCurrentKey = false, currentKey; return source.subscribe(function (value) { var key = value; if (keySelector) { try { key = keySelector(value); } catch (e) { o.onError(e); return; } } if (hasCurrentKey) { try { var comparerEquals = comparer(currentKey, key); } catch (e) { o.onError(e); return; } } if (!hasCurrentKey || !comparerEquals) { hasCurrentKey = true; currentKey = key; o.onNext(value); } }, function (e) { o.onError(e); }, function () { o.onCompleted(); }); }, this); }; /** * Invokes an action for each element in the observable sequence and invokes an action upon graceful or exceptional termination of the observable sequence. * This method can be used for debugging, logging, etc. of query behavior by intercepting the message stream to run arbitrary actions for messages on the pipeline. * @param {Function | Observer} observerOrOnNext Action to invoke for each element in the observable sequence or an observer. * @param {Function} [onError] Action to invoke upon exceptional termination of the observable sequence. Used if only the observerOrOnNext parameter is also a function. * @param {Function} [onCompleted] Action to invoke upon graceful termination of the observable sequence. Used if only the observerOrOnNext parameter is also a function. * @returns {Observable} The source sequence with the side-effecting behavior applied. */ observableProto['do'] = observableProto.tap = observableProto.doAction = function (observerOrOnNext, onError, onCompleted) { var source = this; return new AnonymousObservable(function (observer) { var tapObserver = !observerOrOnNext || isFunction(observerOrOnNext) ? observerCreate(observerOrOnNext || noop, onError || noop, onCompleted || noop) : observerOrOnNext; return source.subscribe(function (x) { try { tapObserver.onNext(x); } catch (e) { observer.onError(e); } observer.onNext(x); }, function (err) { try { tapObserver.onError(err); } catch (e) { observer.onError(e); } observer.onError(err); }, function () { try { tapObserver.onCompleted(); } catch (e) { observer.onError(e); } observer.onCompleted(); }); }, this); }; /** * Invokes an action for each element in the observable sequence. * This method can be used for debugging, logging, etc. of query behavior by intercepting the message stream to run arbitrary actions for messages on the pipeline. * @param {Function} onNext Action to invoke for each element in the observable sequence. * @param {Any} [thisArg] Object to use as this when executing callback. * @returns {Observable} The source sequence with the side-effecting behavior applied. */ observableProto.doOnNext = observableProto.tapOnNext = function (onNext, thisArg) { return this.tap(typeof thisArg !== 'undefined' ? function (x) { onNext.call(thisArg, x); } : onNext); }; /** * Invokes an action upon exceptional termination of the observable sequence. * This method can be used for debugging, logging, etc. of query behavior by intercepting the message stream to run arbitrary actions for messages on the pipeline. * @param {Function} onError Action to invoke upon exceptional termination of the observable sequence. * @param {Any} [thisArg] Object to use as this when executing callback. * @returns {Observable} The source sequence with the side-effecting behavior applied. */ observableProto.doOnError = observableProto.tapOnError = function (onError, thisArg) { return this.tap(noop, typeof thisArg !== 'undefined' ? function (e) { onError.call(thisArg, e); } : onError); }; /** * Invokes an action upon graceful termination of the observable sequence. * This method can be used for debugging, logging, etc. of query behavior by intercepting the message stream to run arbitrary actions for messages on the pipeline. * @param {Function} onCompleted Action to invoke upon graceful termination of the observable sequence. * @param {Any} [thisArg] Object to use as this when executing callback. * @returns {Observable} The source sequence with the side-effecting behavior applied. */ observableProto.doOnCompleted = observableProto.tapOnCompleted = function (onCompleted, thisArg) { return this.tap(noop, null, typeof thisArg !== 'undefined' ? function () { onCompleted.call(thisArg); } : onCompleted); }; /** * Invokes a specified action after the source observable sequence terminates gracefully or exceptionally. * @param {Function} finallyAction Action to invoke after the source observable sequence terminates. * @returns {Observable} Source sequence with the action-invoking termination behavior applied. */ observableProto['finally'] = observableProto.ensure = function (action) { var source = this; return new AnonymousObservable(function (observer) { var subscription; try { subscription = source.subscribe(observer); } catch (e) { action(); throw e; } return disposableCreate(function () { try { subscription.dispose(); } catch (e) { throw e; } finally { action(); } }); }, this); }; /** * @deprecated use #finally or #ensure instead. */ observableProto.finallyAction = function (action) { //deprecate('finallyAction', 'finally or ensure'); return this.ensure(action); }; /** * Ignores all elements in an observable sequence leaving only the termination messages. * @returns {Observable} An empty observable sequence that signals termination, successful or exceptional, of the source sequence. */ observableProto.ignoreElements = function () { var source = this; return new AnonymousObservable(function (o) { return source.subscribe(noop, function (e) { o.onError(e); }, function () { o.onCompleted(); }); }, source); }; /** * Materializes the implicit notifications of an observable sequence as explicit notification values. * @returns {Observable} An observable sequence containing the materialized notification values from the source sequence. */ observableProto.materialize = function () { var source = this; return new AnonymousObservable(function (observer) { return source.subscribe(function (value) { observer.onNext(notificationCreateOnNext(value)); }, function (e) { observer.onNext(notificationCreateOnError(e)); observer.onCompleted(); }, function () { observer.onNext(notificationCreateOnCompleted()); observer.onCompleted(); }); }, source); }; /** * Repeats the observable sequence a specified number of times. If the repeat count is not specified, the sequence repeats indefinitely. * @param {Number} [repeatCount] Number of times to repeat the sequence. If not provided, repeats the sequence indefinitely. * @returns {Observable} The observable sequence producing the elements of the given sequence repeatedly. */ observableProto.repeat = function (repeatCount) { return enumerableRepeat(this, repeatCount).concat(); }; /** * Repeats the source observable sequence the specified number of times or until it successfully terminates. If the retry count is not specified, it retries indefinitely. * Note if you encounter an error and want it to retry once, then you must use .retry(2); * * @example * var res = retried = retry.repeat(); * var res = retried = retry.repeat(2); * @param {Number} [retryCount] Number of times to retry the sequence. If not provided, retry the sequence indefinitely. * @returns {Observable} An observable sequence producing the elements of the given sequence repeatedly until it terminates successfully. */ observableProto.retry = function (retryCount) { return enumerableRepeat(this, retryCount).catchError(); }; /** * Repeats the source observable sequence upon error each time the notifier emits or until it successfully terminates. * if the notifier completes, the observable sequence completes. * * @example * var timer = Observable.timer(500); * var source = observable.retryWhen(timer); * @param {Observable} [notifier] An observable that triggers the retries or completes the observable with onNext or onCompleted respectively. * @returns {Observable} An observable sequence producing the elements of the given sequence repeatedly until it terminates successfully. */ observableProto.retryWhen = function (notifier) { return enumerableRepeat(this).catchErrorWhen(notifier); }; /** * Applies an accumulator function over an observable sequence and returns each intermediate result. The optional seed value is used as the initial accumulator value. * For aggregation behavior with no intermediate results, see Observable.aggregate. * @example * var res = source.scan(function (acc, x) { return acc + x; }); * var res = source.scan(0, function (acc, x) { return acc + x; }); * @param {Mixed} [seed] The initial accumulator value. * @param {Function} accumulator An accumulator function to be invoked on each element. * @returns {Observable} An observable sequence containing the accumulated values. */ observableProto.scan = function () { var hasSeed = false, seed, accumulator, source = this; if (arguments.length === 2) { hasSeed = true; seed = arguments[0]; accumulator = arguments[1]; } else { accumulator = arguments[0]; } return new AnonymousObservable(function (o) { var hasAccumulation, accumulation, hasValue; return source.subscribe ( function (x) { !hasValue && (hasValue = true); try { if (hasAccumulation) { accumulation = accumulator(accumulation, x); } else { accumulation = hasSeed ? accumulator(seed, x) : x; hasAccumulation = true; } } catch (e) { o.onError(e); return; } o.onNext(accumulation); }, function (e) { o.onError(e); }, function () { !hasValue && hasSeed && o.onNext(seed); o.onCompleted(); } ); }, source); }; /** * Bypasses a specified number of elements at the end of an observable sequence. * @description * This operator accumulates a queue with a length enough to store the first `count` elements. As more elements are * received, elements are taken from the front of the queue and produced on the result sequence. This causes elements to be delayed. * @param count Number of elements to bypass at the end of the source sequence. * @returns {Observable} An observable sequence containing the source sequence elements except for the bypassed ones at the end. */ observableProto.skipLast = function (count) { if (count < 0) { throw new ArgumentOutOfRangeError(); } var source = this; return new AnonymousObservable(function (o) { var q = []; return source.subscribe(function (x) { q.push(x); q.length > count && o.onNext(q.shift()); }, function (e) { o.onError(e); }, function () { o.onCompleted(); }); }, source); }; /** * Prepends a sequence of values to an observable sequence with an optional scheduler and an argument list of values to prepend. * @example * var res = source.startWith(1, 2, 3); * var res = source.startWith(Rx.Scheduler.timeout, 1, 2, 3); * @param {Arguments} args The specified values to prepend to the observable sequence * @returns {Observable} The source sequence prepended with the specified values. */ observableProto.startWith = function () { var values, scheduler, start = 0; if (!!arguments.length && isScheduler(arguments[0])) { scheduler = arguments[0]; start = 1; } else { scheduler = immediateScheduler; } for(var args = [], i = start, len = arguments.length; i < len; i++) { args.push(arguments[i]); } return enumerableOf([observableFromArray(args, scheduler), this]).concat(); }; /** * Returns a specified number of contiguous elements from the end of an observable sequence. * @description * This operator accumulates a buffer with a length enough to store elements count elements. Upon completion of * the source sequence, this buffer is drained on the result sequence. This causes the elements to be delayed. * @param {Number} count Number of elements to take from the end of the source sequence. * @returns {Observable} An observable sequence containing the specified number of elements from the end of the source sequence. */ observableProto.takeLast = function (count) { if (count < 0) { throw new ArgumentOutOfRangeError(); } var source = this; return new AnonymousObservable(function (o) { var q = []; return source.subscribe(function (x) { q.push(x); q.length > count && q.shift(); }, function (e) { o.onError(e); }, function () { while (q.length > 0) { o.onNext(q.shift()); } o.onCompleted(); }); }, source); }; /** * Returns an array with the specified number of contiguous elements from the end of an observable sequence. * * @description * This operator accumulates a buffer with a length enough to store count elements. Upon completion of the * source sequence, this buffer is produced on the result sequence. * @param {Number} count Number of elements to take from the end of the source sequence. * @returns {Observable} An observable sequence containing a single array with the specified number of elements from the end of the source sequence. */ observableProto.takeLastBuffer = function (count) { var source = this; return new AnonymousObservable(function (o) { var q = []; return source.subscribe(function (x) { q.push(x); q.length > count && q.shift(); }, function (e) { o.onError(e); }, function () { o.onNext(q); o.onCompleted(); }); }, source); }; /** * Projects each element of an observable sequence into zero or more windows which are produced based on element count information. * * var res = xs.windowWithCount(10); * var res = xs.windowWithCount(10, 1); * @param {Number} count Length of each window. * @param {Number} [skip] Number of elements to skip between creation of consecutive windows. If not specified, defaults to the count. * @returns {Observable} An observable sequence of windows. */ observableProto.windowWithCount = function (count, skip) { var source = this; +count || (count = 0); Math.abs(count) === Infinity && (count = 0); if (count <= 0) { throw new ArgumentOutOfRangeError(); } skip == null && (skip = count); +skip || (skip = 0); Math.abs(skip) === Infinity && (skip = 0); if (skip <= 0) { throw new ArgumentOutOfRangeError(); } return new AnonymousObservable(function (observer) { var m = new SingleAssignmentDisposable(), refCountDisposable = new RefCountDisposable(m), n = 0, q = []; function createWindow () { var s = new Subject(); q.push(s); observer.onNext(addRef(s, refCountDisposable)); } createWindow(); m.setDisposable(source.subscribe( function (x) { for (var i = 0, len = q.length; i < len; i++) { q[i].onNext(x); } var c = n - count + 1; c >= 0 && c % skip === 0 && q.shift().onCompleted(); ++n % skip === 0 && createWindow(); }, function (e) { while (q.length > 0) { q.shift().onError(e); } observer.onError(e); }, function () { while (q.length > 0) { q.shift().onCompleted(); } observer.onCompleted(); } )); return refCountDisposable; }, source); }; function concatMap(source, selector, thisArg) { var selectorFunc = bindCallback(selector, thisArg, 3); return source.map(function (x, i) { var result = selectorFunc(x, i, source); isPromise(result) && (result = observableFromPromise(result)); (isArrayLike(result) || isIterable(result)) && (result = observableFrom(result)); return result; }).concatAll(); } /** * One of the Following: * Projects each element of an observable sequence to an observable sequence and merges the resulting observable sequences into one observable sequence. * * @example * var res = source.concatMap(function (x) { return Rx.Observable.range(0, x); }); * Or: * Projects each element of an observable sequence to an observable sequence, invokes the result selector for the source element and each of the corresponding inner sequence's elements, and merges the results into one observable sequence. * * var res = source.concatMap(function (x) { return Rx.Observable.range(0, x); }, function (x, y) { return x + y; }); * Or: * Projects each element of the source observable sequence to the other observable sequence and merges the resulting observable sequences into one observable sequence. * * var res = source.concatMap(Rx.Observable.fromArray([1,2,3])); * @param {Function} selector A transform function to apply to each element or an observable sequence to project each element from the * source sequence onto which could be either an observable or Promise. * @param {Function} [resultSelector] A transform function to apply to each element of the intermediate sequence. * @returns {Observable} An observable sequence whose elements are the result of invoking the one-to-many transform function collectionSelector on each element of the input sequence and then mapping each of those sequence elements and their corresponding source element to a result element. */ observableProto.selectConcat = observableProto.concatMap = function (selector, resultSelector, thisArg) { if (isFunction(selector) && isFunction(resultSelector)) { return this.concatMap(function (x, i) { var selectorResult = selector(x, i); isPromise(selectorResult) && (selectorResult = observableFromPromise(selectorResult)); (isArrayLike(selectorResult) || isIterable(selectorResult)) && (selectorResult = observableFrom(selectorResult)); return selectorResult.map(function (y, i2) { return resultSelector(x, y, i, i2); }); }); } return isFunction(selector) ? concatMap(this, selector, thisArg) : concatMap(this, function () { return selector; }); }; /** * Projects each notification of an observable sequence to an observable sequence and concats the resulting observable sequences into one observable sequence. * @param {Function} onNext A transform function to apply to each element; the second parameter of the function represents the index of the source element. * @param {Function} onError A transform function to apply when an error occurs in the source sequence. * @param {Function} onCompleted A transform function to apply when the end of the source sequence is reached. * @param {Any} [thisArg] An optional "this" to use to invoke each transform. * @returns {Observable} An observable sequence whose elements are the result of invoking the one-to-many transform function corresponding to each notification in the input sequence. */ observableProto.concatMapObserver = observableProto.selectConcatObserver = function(onNext, onError, onCompleted, thisArg) { var source = this, onNextFunc = bindCallback(onNext, thisArg, 2), onErrorFunc = bindCallback(onError, thisArg, 1), onCompletedFunc = bindCallback(onCompleted, thisArg, 0); return new AnonymousObservable(function (observer) { var index = 0; return source.subscribe( function (x) { var result; try { result = onNextFunc(x, index++); } catch (e) { observer.onError(e); return; } isPromise(result) && (result = observableFromPromise(result)); observer.onNext(result); }, function (err) { var result; try { result = onErrorFunc(err); } catch (e) { observer.onError(e); return; } isPromise(result) && (result = observableFromPromise(result)); observer.onNext(result); observer.onCompleted(); }, function () { var result; try { result = onCompletedFunc(); } catch (e) { observer.onError(e); return; } isPromise(result) && (result = observableFromPromise(result)); observer.onNext(result); observer.onCompleted(); }); }, this).concatAll(); }; /** * Returns the elements of the specified sequence or the specified value in a singleton sequence if the sequence is empty. * * var res = obs = xs.defaultIfEmpty(); * 2 - obs = xs.defaultIfEmpty(false); * * @memberOf Observable# * @param defaultValue The value to return if the sequence is empty. If not provided, this defaults to null. * @returns {Observable} An observable sequence that contains the specified default value if the source is empty; otherwise, the elements of the source itself. */ observableProto.defaultIfEmpty = function (defaultValue) { var source = this; defaultValue === undefined && (defaultValue = null); return new AnonymousObservable(function (observer) { var found = false; return source.subscribe(function (x) { found = true; observer.onNext(x); }, function (e) { observer.onError(e); }, function () { !found && observer.onNext(defaultValue); observer.onCompleted(); }); }, source); }; // Swap out for Array.findIndex function arrayIndexOfComparer(array, item, comparer) { for (var i = 0, len = array.length; i < len; i++) { if (comparer(array[i], item)) { return i; } } return -1; } function HashSet(comparer) { this.comparer = comparer; this.set = []; } HashSet.prototype.push = function(value) { var retValue = arrayIndexOfComparer(this.set, value, this.comparer) === -1; retValue && this.set.push(value); return retValue; }; /** * Returns an observable sequence that contains only distinct elements according to the keySelector and the comparer. * Usage of this operator should be considered carefully due to the maintenance of an internal lookup structure which can grow large. * * @example * var res = obs = xs.distinct(); * 2 - obs = xs.distinct(function (x) { return x.id; }); * 2 - obs = xs.distinct(function (x) { return x.id; }, function (a,b) { return a === b; }); * @param {Function} [keySelector] A function to compute the comparison key for each element. * @param {Function} [comparer] Used to compare items in the collection. * @returns {Observable} An observable sequence only containing the distinct elements, based on a computed key value, from the source sequence. */ observableProto.distinct = function (keySelector, comparer) { var source = this; comparer || (comparer = defaultComparer); return new AnonymousObservable(function (o) { var hashSet = new HashSet(comparer); return source.subscribe(function (x) { var key = x; if (keySelector) { try { key = keySelector(x); } catch (e) { o.onError(e); return; } } hashSet.push(key) && o.onNext(x); }, function (e) { o.onError(e); }, function () { o.onCompleted(); }); }, this); }; /** * Groups the elements of an observable sequence according to a specified key selector function and comparer and selects the resulting elements by using a specified function. * * @example * var res = observable.groupBy(function (x) { return x.id; }); * 2 - observable.groupBy(function (x) { return x.id; }), function (x) { return x.name; }); * 3 - observable.groupBy(function (x) { return x.id; }), function (x) { return x.name; }, function (x) { return x.toString(); }); * @param {Function} keySelector A function to extract the key for each element. * @param {Function} [elementSelector] A function to map each source element to an element in an observable group. * @param {Function} [comparer] Used to determine whether the objects are equal. * @returns {Observable} A sequence of observable groups, each of which corresponds to a unique key value, containing all elements that share that same key value. */ observableProto.groupBy = function (keySelector, elementSelector, comparer) { return this.groupByUntil(keySelector, elementSelector, observableNever, comparer); }; /** * Groups the elements of an observable sequence according to a specified key selector function. * A duration selector function is used to control the lifetime of groups. When a group expires, it receives an OnCompleted notification. When a new element with the same * key value as a reclaimed group occurs, the group will be reborn with a new lifetime request. * * @example * var res = observable.groupByUntil(function (x) { return x.id; }, null, function () { return Rx.Observable.never(); }); * 2 - observable.groupBy(function (x) { return x.id; }), function (x) { return x.name; }, function () { return Rx.Observable.never(); }); * 3 - observable.groupBy(function (x) { return x.id; }), function (x) { return x.name; }, function () { return Rx.Observable.never(); }, function (x) { return x.toString(); }); * @param {Function} keySelector A function to extract the key for each element. * @param {Function} durationSelector A function to signal the expiration of a group. * @param {Function} [comparer] Used to compare objects. When not specified, the default comparer is used. * @returns {Observable} * A sequence of observable groups, each of which corresponds to a unique key value, containing all elements that share that same key value. * If a group's lifetime expires, a new group with the same key value can be created once an element with such a key value is encoutered. * */ observableProto.groupByUntil = function (keySelector, elementSelector, durationSelector, comparer) { var source = this; elementSelector || (elementSelector = identity); comparer || (comparer = defaultComparer); return new AnonymousObservable(function (observer) { function handleError(e) { return function (item) { item.onError(e); }; } var map = new Dictionary(0, comparer), groupDisposable = new CompositeDisposable(), refCountDisposable = new RefCountDisposable(groupDisposable); groupDisposable.add(source.subscribe(function (x) { var key; try { key = keySelector(x); } catch (e) { map.getValues().forEach(handleError(e)); observer.onError(e); return; } var fireNewMapEntry = false, writer = map.tryGetValue(key); if (!writer) { writer = new Subject(); map.set(key, writer); fireNewMapEntry = true; } if (fireNewMapEntry) { var group = new GroupedObservable(key, writer, refCountDisposable), durationGroup = new GroupedObservable(key, writer); try { duration = durationSelector(durationGroup); } catch (e) { map.getValues().forEach(handleError(e)); observer.onError(e); return; } observer.onNext(group); var md = new SingleAssignmentDisposable(); groupDisposable.add(md); var expire = function () { map.remove(key) && writer.onCompleted(); groupDisposable.remove(md); }; md.setDisposable(duration.take(1).subscribe( noop, function (exn) { map.getValues().forEach(handleError(exn)); observer.onError(exn); }, expire) ); } var element; try { element = elementSelector(x); } catch (e) { map.getValues().forEach(handleError(e)); observer.onError(e); return; } writer.onNext(element); }, function (ex) { map.getValues().forEach(handleError(ex)); observer.onError(ex); }, function () { map.getValues().forEach(function (item) { item.onCompleted(); }); observer.onCompleted(); })); return refCountDisposable; }, source); }; var MapObservable = (function (__super__) { inherits(MapObservable, __super__); function MapObservable(source, selector, thisArg) { this.source = source; this.selector = bindCallback(selector, thisArg, 3); __super__.call(this); } MapObservable.prototype.internalMap = function (selector, thisArg) { var self = this; return new MapObservable(this.source, function (x, i, o) { return selector.call(this, self.selector(x, i, o), i, o); }, thisArg) }; MapObservable.prototype.subscribeCore = function (observer) { return this.source.subscribe(new MapObserver(observer, this.selector, this)); }; return MapObservable; }(ObservableBase)); function MapObserver(observer, selector, source) { this.observer = observer; this.selector = selector; this.source = source; this.i = 0; this.isStopped = false; } MapObserver.prototype.onNext = function(x) { if (this.isStopped) { return; } var result = tryCatch(this.selector).call(this, x, this.i++, this.source); if (result === errorObj) { return this.observer.onError(result.e); } this.observer.onNext(result); }; MapObserver.prototype.onError = function (e) { if(!this.isStopped) { this.isStopped = true; this.observer.onError(e); } }; MapObserver.prototype.onCompleted = function () { if(!this.isStopped) { this.isStopped = true; this.observer.onCompleted(); } }; MapObserver.prototype.dispose = function() { this.isStopped = true; }; MapObserver.prototype.fail = function (e) { if (!this.isStopped) { this.isStopped = true; this.observer.onError(e); return true; } return false; }; /** * Projects each element of an observable sequence into a new form by incorporating the element's index. * @param {Function} selector A transform function to apply to each source element; the second parameter of the function represents the index of the source element. * @param {Any} [thisArg] Object to use as this when executing callback. * @returns {Observable} An observable sequence whose elements are the result of invoking the transform function on each element of source. */ observableProto.map = observableProto.select = function (selector, thisArg) { var selectorFn = typeof selector === 'function' ? selector : function () { return selector; }; return this instanceof MapObservable ? this.internalMap(selectorFn, thisArg) : new MapObservable(this, selectorFn, thisArg); }; /** * Retrieves the value of a specified nested property from all elements in * the Observable sequence. * @param {Arguments} arguments The nested properties to pluck. * @returns {Observable} Returns a new Observable sequence of property values. */ observableProto.pluck = function () { var args = arguments, len = arguments.length; if (len === 0) { throw new Error('List of properties cannot be empty.'); } return this.map(function (x) { var currentProp = x; for (var i = 0; i < len; i++) { var p = currentProp[args[i]]; if (typeof p !== 'undefined') { currentProp = p; } else { return undefined; } } return currentProp; }); }; function flatMap(source, selector, thisArg) { var selectorFunc = bindCallback(selector, thisArg, 3); return source.map(function (x, i) { var result = selectorFunc(x, i, source); isPromise(result) && (result = observableFromPromise(result)); (isArrayLike(result) || isIterable(result)) && (result = observableFrom(result)); return result; }).mergeAll(); } /** * One of the Following: * Projects each element of an observable sequence to an observable sequence and merges the resulting observable sequences into one observable sequence. * * @example * var res = source.selectMany(function (x) { return Rx.Observable.range(0, x); }); * Or: * Projects each element of an observable sequence to an observable sequence, invokes the result selector for the source element and each of the corresponding inner sequence's elements, and merges the results into one observable sequence. * * var res = source.selectMany(function (x) { return Rx.Observable.range(0, x); }, function (x, y) { return x + y; }); * Or: * Projects each element of the source observable sequence to the other observable sequence and merges the resulting observable sequences into one observable sequence. * * var res = source.selectMany(Rx.Observable.fromArray([1,2,3])); * @param {Function} selector A transform function to apply to each element or an observable sequence to project each element from the source sequence onto which could be either an observable or Promise. * @param {Function} [resultSelector] A transform function to apply to each element of the intermediate sequence. * @param {Any} [thisArg] Object to use as this when executing callback. * @returns {Observable} An observable sequence whose elements are the result of invoking the one-to-many transform function collectionSelector on each element of the input sequence and then mapping each of those sequence elements and their corresponding source element to a result element. */ observableProto.selectMany = observableProto.flatMap = function (selector, resultSelector, thisArg) { if (isFunction(selector) && isFunction(resultSelector)) { return this.flatMap(function (x, i) { var selectorResult = selector(x, i); isPromise(selectorResult) && (selectorResult = observableFromPromise(selectorResult)); (isArrayLike(selectorResult) || isIterable(selectorResult)) && (selectorResult = observableFrom(selectorResult)); return selectorResult.map(function (y, i2) { return resultSelector(x, y, i, i2); }); }, thisArg); } return isFunction(selector) ? flatMap(this, selector, thisArg) : flatMap(this, function () { return selector; }); }; /** * Projects each notification of an observable sequence to an observable sequence and merges the resulting observable sequences into one observable sequence. * @param {Function} onNext A transform function to apply to each element; the second parameter of the function represents the index of the source element. * @param {Function} onError A transform function to apply when an error occurs in the source sequence. * @param {Function} onCompleted A transform function to apply when the end of the source sequence is reached. * @param {Any} [thisArg] An optional "this" to use to invoke each transform. * @returns {Observable} An observable sequence whose elements are the result of invoking the one-to-many transform function corresponding to each notification in the input sequence. */ observableProto.flatMapObserver = observableProto.selectManyObserver = function (onNext, onError, onCompleted, thisArg) { var source = this; return new AnonymousObservable(function (observer) { var index = 0; return source.subscribe( function (x) { var result; try { result = onNext.call(thisArg, x, index++); } catch (e) { observer.onError(e); return; } isPromise(result) && (result = observableFromPromise(result)); observer.onNext(result); }, function (err) { var result; try { result = onError.call(thisArg, err); } catch (e) { observer.onError(e); return; } isPromise(result) && (result = observableFromPromise(result)); observer.onNext(result); observer.onCompleted(); }, function () { var result; try { result = onCompleted.call(thisArg); } catch (e) { observer.onError(e); return; } isPromise(result) && (result = observableFromPromise(result)); observer.onNext(result); observer.onCompleted(); }); }, source).mergeAll(); }; /** * Projects each element of an observable sequence into a new sequence of observable sequences by incorporating the element's index and then * transforms an observable sequence of observable sequences into an observable sequence producing values only from the most recent observable sequence. * @param {Function} selector A transform function to apply to each source element; the second parameter of the function represents the index of the source element. * @param {Any} [thisArg] Object to use as this when executing callback. * @returns {Observable} An observable sequence whose elements are the result of invoking the transform function on each element of source producing an Observable of Observable sequences * and that at any point in time produces the elements of the most recent inner observable sequence that has been received. */ observableProto.selectSwitch = observableProto.flatMapLatest = observableProto.switchMap = function (selector, thisArg) { return this.select(selector, thisArg).switchLatest(); }; /** * Bypasses a specified number of elements in an observable sequence and then returns the remaining elements. * @param {Number} count The number of elements to skip before returning the remaining elements. * @returns {Observable} An observable sequence that contains the elements that occur after the specified index in the input sequence. */ observableProto.skip = function (count) { if (count < 0) { throw new ArgumentOutOfRangeError(); } var source = this; return new AnonymousObservable(function (o) { var remaining = count; return source.subscribe(function (x) { if (remaining <= 0) { o.onNext(x); } else { remaining--; } }, function (e) { o.onError(e); }, function () { o.onCompleted(); }); }, source); }; /** * Bypasses elements in an observable sequence as long as a specified condition is true and then returns the remaining elements. * The element's index is used in the logic of the predicate function. * * var res = source.skipWhile(function (value) { return value < 10; }); * var res = source.skipWhile(function (value, index) { return value < 10 || index < 10; }); * @param {Function} predicate A function to test each element for a condition; the second parameter of the function represents the index of the source element. * @param {Any} [thisArg] Object to use as this when executing callback. * @returns {Observable} An observable sequence that contains the elements from the input sequence starting at the first element in the linear series that does not pass the test specified by predicate. */ observableProto.skipWhile = function (predicate, thisArg) { var source = this, callback = bindCallback(predicate, thisArg, 3); return new AnonymousObservable(function (o) { var i = 0, running = false; return source.subscribe(function (x) { if (!running) { try { running = !callback(x, i++, source); } catch (e) { o.onError(e); return; } } running && o.onNext(x); }, function (e) { o.onError(e); }, function () { o.onCompleted(); }); }, source); }; /** * Returns a specified number of contiguous elements from the start of an observable sequence, using the specified scheduler for the edge case of take(0). * * var res = source.take(5); * var res = source.take(0, Rx.Scheduler.timeout); * @param {Number} count The number of elements to return. * @param {Scheduler} [scheduler] Scheduler used to produce an OnCompleted message in case <paramref name="count count</paramref> is set to 0. * @returns {Observable} An observable sequence that contains the specified number of elements from the start of the input sequence. */ observableProto.take = function (count, scheduler) { if (count < 0) { throw new ArgumentOutOfRangeError(); } if (count === 0) { return observableEmpty(scheduler); } var source = this; return new AnonymousObservable(function (o) { var remaining = count; return source.subscribe(function (x) { if (remaining-- > 0) { o.onNext(x); remaining === 0 && o.onCompleted(); } }, function (e) { o.onError(e); }, function () { o.onCompleted(); }); }, source); }; /** * Returns elements from an observable sequence as long as a specified condition is true. * The element's index is used in the logic of the predicate function. * @param {Function} predicate A function to test each element for a condition; the second parameter of the function represents the index of the source element. * @param {Any} [thisArg] Object to use as this when executing callback. * @returns {Observable} An observable sequence that contains the elements from the input sequence that occur before the element at which the test no longer passes. */ observableProto.takeWhile = function (predicate, thisArg) { var source = this, callback = bindCallback(predicate, thisArg, 3); return new AnonymousObservable(function (o) { var i = 0, running = true; return source.subscribe(function (x) { if (running) { try { running = callback(x, i++, source); } catch (e) { o.onError(e); return; } if (running) { o.onNext(x); } else { o.onCompleted(); } } }, function (e) { o.onError(e); }, function () { o.onCompleted(); }); }, source); }; var FilterObservable = (function (__super__) { inherits(FilterObservable, __super__); function FilterObservable(source, predicate, thisArg) { this.source = source; this.predicate = bindCallback(predicate, thisArg, 3); __super__.call(this); } FilterObservable.prototype.subscribeCore = function (observer) { return this.source.subscribe(new FilterObserver(observer, this.predicate, this)); }; FilterObservable.prototype.internalFilter = function(predicate, thisArg) { var self = this; return new FilterObservable(this.source, function(x, i, o) { return self.predicate(x, i, o) && predicate.call(this, x, i, o); }, thisArg); }; return FilterObservable; }(ObservableBase)); function FilterObserver(observer, predicate, source) { this.observer = observer; this.predicate = predicate; this.source = source; this.i = 0; this.isStopped = false; } FilterObserver.prototype.onNext = function(x) { if (this.isStopped) { return; } var shouldYield = tryCatch(this.predicate).call(this, x, this.i++, this.source); if (shouldYield === errorObj) { return this.observer.onError(shouldYield.e); } shouldYield && this.observer.onNext(x); }; FilterObserver.prototype.onError = function (e) { if(!this.isStopped) { this.isStopped = true; this.observer.onError(e); } }; FilterObserver.prototype.onCompleted = function () { if(!this.isStopped) { this.isStopped = true; this.observer.onCompleted(); } }; FilterObserver.prototype.dispose = function() { this.isStopped = true; }; FilterObserver.prototype.fail = function (e) { if (!this.isStopped) { this.isStopped = true; this.observer.onError(e); return true; } return false; }; /** * Filters the elements of an observable sequence based on a predicate by incorporating the element's index. * @param {Function} predicate A function to test each source element for a condition; the second parameter of the function represents the index of the source element. * @param {Any} [thisArg] Object to use as this when executing callback. * @returns {Observable} An observable sequence that contains elements from the input sequence that satisfy the condition. */ observableProto.filter = observableProto.where = function (predicate, thisArg) { return this instanceof FilterObservable ? this.internalFilter(predicate, thisArg) : new FilterObservable(this, predicate, thisArg); }; function extremaBy(source, keySelector, comparer) { return new AnonymousObservable(function (o) { var hasValue = false, lastKey = null, list = []; return source.subscribe(function (x) { var comparison, key; try { key = keySelector(x); } catch (ex) { o.onError(ex); return; } comparison = 0; if (!hasValue) { hasValue = true; lastKey = key; } else { try { comparison = comparer(key, lastKey); } catch (ex1) { o.onError(ex1); return; } } if (comparison > 0) { lastKey = key; list = []; } if (comparison >= 0) { list.push(x); } }, function (e) { o.onError(e); }, function () { o.onNext(list); o.onCompleted(); }); }, source); } function firstOnly(x) { if (x.length === 0) { throw new EmptyError(); } return x[0]; } /** * Applies an accumulator function over an observable sequence, returning the result of the aggregation as a single element in the result sequence. The specified seed value is used as the initial accumulator value. * For aggregation behavior with incremental intermediate results, see Observable.scan. * @deprecated Use #reduce instead * @param {Mixed} [seed] The initial accumulator value. * @param {Function} accumulator An accumulator function to be invoked on each element. * @returns {Observable} An observable sequence containing a single element with the final accumulator value. */ observableProto.aggregate = function () { var hasSeed = false, accumulator, seed, source = this; if (arguments.length === 2) { hasSeed = true; seed = arguments[0]; accumulator = arguments[1]; } else { accumulator = arguments[0]; } return new AnonymousObservable(function (o) { var hasAccumulation, accumulation, hasValue; return source.subscribe ( function (x) { !hasValue && (hasValue = true); try { if (hasAccumulation) { accumulation = accumulator(accumulation, x); } else { accumulation = hasSeed ? accumulator(seed, x) : x; hasAccumulation = true; } } catch (e) { return o.onError(e); } }, function (e) { o.onError(e); }, function () { hasValue && o.onNext(accumulation); !hasValue && hasSeed && o.onNext(seed); !hasValue && !hasSeed && o.onError(new EmptyError()); o.onCompleted(); } ); }, source); }; /** * Applies an accumulator function over an observable sequence, returning the result of the aggregation as a single element in the result sequence. The specified seed value is used as the initial accumulator value. * For aggregation behavior with incremental intermediate results, see Observable.scan. * @param {Function} accumulator An accumulator function to be invoked on each element. * @param {Any} [seed] The initial accumulator value. * @returns {Observable} An observable sequence containing a single element with the final accumulator value. */ observableProto.reduce = function (accumulator) { var hasSeed = false, seed, source = this; if (arguments.length === 2) { hasSeed = true; seed = arguments[1]; } return new AnonymousObservable(function (o) { var hasAccumulation, accumulation, hasValue; return source.subscribe ( function (x) { !hasValue && (hasValue = true); try { if (hasAccumulation) { accumulation = accumulator(accumulation, x); } else { accumulation = hasSeed ? accumulator(seed, x) : x; hasAccumulation = true; } } catch (e) { return o.onError(e); } }, function (e) { o.onError(e); }, function () { hasValue && o.onNext(accumulation); !hasValue && hasSeed && o.onNext(seed); !hasValue && !hasSeed && o.onError(new EmptyError()); o.onCompleted(); } ); }, source); }; /** * Determines whether any element of an observable sequence satisfies a condition if present, else if any items are in the sequence. * @param {Function} [predicate] A function to test each element for a condition. * @returns {Observable} An observable sequence containing a single element determining whether any elements in the source sequence pass the test in the specified predicate if given, else if any items are in the sequence. */ observableProto.some = function (predicate, thisArg) { var source = this; return predicate ? source.filter(predicate, thisArg).some() : new AnonymousObservable(function (observer) { return source.subscribe(function () { observer.onNext(true); observer.onCompleted(); }, function (e) { observer.onError(e); }, function () { observer.onNext(false); observer.onCompleted(); }); }, source); }; /** @deprecated use #some instead */ observableProto.any = function () { //deprecate('any', 'some'); return this.some.apply(this, arguments); }; /** * Determines whether an observable sequence is empty. * @returns {Observable} An observable sequence containing a single element determining whether the source sequence is empty. */ observableProto.isEmpty = function () { return this.any().map(not); }; /** * Determines whether all elements of an observable sequence satisfy a condition. * @param {Function} [predicate] A function to test each element for a condition. * @param {Any} [thisArg] Object to use as this when executing callback. * @returns {Observable} An observable sequence containing a single element determining whether all elements in the source sequence pass the test in the specified predicate. */ observableProto.every = function (predicate, thisArg) { return this.filter(function (v) { return !predicate(v); }, thisArg).some().map(not); }; /** @deprecated use #every instead */ observableProto.all = function () { //deprecate('all', 'every'); return this.every.apply(this, arguments); }; /** * Determines whether an observable sequence includes a specified element with an optional equality comparer. * @param searchElement The value to locate in the source sequence. * @param {Number} [fromIndex] An equality comparer to compare elements. * @returns {Observable} An observable sequence containing a single element determining whether the source sequence includes an element that has the specified value from the given index. */ observableProto.includes = function (searchElement, fromIndex) { var source = this; function comparer(a, b) { return (a === 0 && b === 0) || (a === b || (isNaN(a) && isNaN(b))); } return new AnonymousObservable(function (o) { var i = 0, n = +fromIndex || 0; Math.abs(n) === Infinity && (n = 0); if (n < 0) { o.onNext(false); o.onCompleted(); return disposableEmpty; } return source.subscribe( function (x) { if (i++ >= n && comparer(x, searchElement)) { o.onNext(true); o.onCompleted(); } }, function (e) { o.onError(e); }, function () { o.onNext(false); o.onCompleted(); }); }, this); }; /** * @deprecated use #includes instead. */ observableProto.contains = function (searchElement, fromIndex) { //deprecate('contains', 'includes'); observableProto.includes(searchElement, fromIndex); }; /** * Returns an observable sequence containing a value that represents how many elements in the specified observable sequence satisfy a condition if provided, else the count of items. * @example * res = source.count(); * res = source.count(function (x) { return x > 3; }); * @param {Function} [predicate]A function to test each element for a condition. * @param {Any} [thisArg] Object to use as this when executing callback. * @returns {Observable} An observable sequence containing a single element with a number that represents how many elements in the input sequence satisfy the condition in the predicate function if provided, else the count of items in the sequence. */ observableProto.count = function (predicate, thisArg) { return predicate ? this.filter(predicate, thisArg).count() : this.reduce(function (count) { return count + 1; }, 0); }; /** * Returns the first index at which a given element can be found in the observable sequence, or -1 if it is not present. * @param {Any} searchElement Element to locate in the array. * @param {Number} [fromIndex] The index to start the search. If not specified, defaults to 0. * @returns {Observable} And observable sequence containing the first index at which a given element can be found in the observable sequence, or -1 if it is not present. */ observableProto.indexOf = function(searchElement, fromIndex) { var source = this; return new AnonymousObservable(function (o) { var i = 0, n = +fromIndex || 0; Math.abs(n) === Infinity && (n = 0); if (n < 0) { o.onNext(-1); o.onCompleted(); return disposableEmpty; } return source.subscribe( function (x) { if (i >= n && x === searchElement) { o.onNext(i); o.onCompleted(); } i++; }, function (e) { o.onError(e); }, function () { o.onNext(-1); o.onCompleted(); }); }, source); }; /** * Computes the sum of a sequence of values that are obtained by invoking an optional transform function on each element of the input sequence, else if not specified computes the sum on each item in the sequence. * @param {Function} [selector] A transform function to apply to each element. * @param {Any} [thisArg] Object to use as this when executing callback. * @returns {Observable} An observable sequence containing a single element with the sum of the values in the source sequence. */ observableProto.sum = function (keySelector, thisArg) { return keySelector && isFunction(keySelector) ? this.map(keySelector, thisArg).sum() : this.reduce(function (prev, curr) { return prev + curr; }, 0); }; /** * Returns the elements in an observable sequence with the minimum key value according to the specified comparer. * @example * var res = source.minBy(function (x) { return x.value; }); * var res = source.minBy(function (x) { return x.value; }, function (x, y) { return x - y; }); * @param {Function} keySelector Key selector function. * @param {Function} [comparer] Comparer used to compare key values. * @returns {Observable} An observable sequence containing a list of zero or more elements that have a minimum key value. */ observableProto.minBy = function (keySelector, comparer) { comparer || (comparer = defaultSubComparer); return extremaBy(this, keySelector, function (x, y) { return comparer(x, y) * -1; }); }; /** * Returns the minimum element in an observable sequence according to the optional comparer else a default greater than less than check. * @example * var res = source.min(); * var res = source.min(function (x, y) { return x.value - y.value; }); * @param {Function} [comparer] Comparer used to compare elements. * @returns {Observable} An observable sequence containing a single element with the minimum element in the source sequence. */ observableProto.min = function (comparer) { return this.minBy(identity, comparer).map(function (x) { return firstOnly(x); }); }; /** * Returns the elements in an observable sequence with the maximum key value according to the specified comparer. * @example * var res = source.maxBy(function (x) { return x.value; }); * var res = source.maxBy(function (x) { return x.value; }, function (x, y) { return x - y;; }); * @param {Function} keySelector Key selector function. * @param {Function} [comparer] Comparer used to compare key values. * @returns {Observable} An observable sequence containing a list of zero or more elements that have a maximum key value. */ observableProto.maxBy = function (keySelector, comparer) { comparer || (comparer = defaultSubComparer); return extremaBy(this, keySelector, comparer); }; /** * Returns the maximum value in an observable sequence according to the specified comparer. * @example * var res = source.max(); * var res = source.max(function (x, y) { return x.value - y.value; }); * @param {Function} [comparer] Comparer used to compare elements. * @returns {Observable} An observable sequence containing a single element with the maximum element in the source sequence. */ observableProto.max = function (comparer) { return this.maxBy(identity, comparer).map(function (x) { return firstOnly(x); }); }; /** * Computes the average of an observable sequence of values that are in the sequence or obtained by invoking a transform function on each element of the input sequence if present. * @param {Function} [selector] A transform function to apply to each element. * @param {Any} [thisArg] Object to use as this when executing callback. * @returns {Observable} An observable sequence containing a single element with the average of the sequence of values. */ observableProto.average = function (keySelector, thisArg) { return keySelector && isFunction(keySelector) ? this.map(keySelector, thisArg).average() : this.reduce(function (prev, cur) { return { sum: prev.sum + cur, count: prev.count + 1 }; }, {sum: 0, count: 0 }).map(function (s) { if (s.count === 0) { throw new EmptyError(); } return s.sum / s.count; }); }; /** * Determines whether two sequences are equal by comparing the elements pairwise using a specified equality comparer. * * @example * var res = res = source.sequenceEqual([1,2,3]); * var res = res = source.sequenceEqual([{ value: 42 }], function (x, y) { return x.value === y.value; }); * 3 - res = source.sequenceEqual(Rx.Observable.returnValue(42)); * 4 - res = source.sequenceEqual(Rx.Observable.returnValue({ value: 42 }), function (x, y) { return x.value === y.value; }); * @param {Observable} second Second observable sequence or array to compare. * @param {Function} [comparer] Comparer used to compare elements of both sequences. * @returns {Observable} An observable sequence that contains a single element which indicates whether both sequences are of equal length and their corresponding elements are equal according to the specified equality comparer. */ observableProto.sequenceEqual = function (second, comparer) { var first = this; comparer || (comparer = defaultComparer); return new AnonymousObservable(function (o) { var donel = false, doner = false, ql = [], qr = []; var subscription1 = first.subscribe(function (x) { var equal, v; if (qr.length > 0) { v = qr.shift(); try { equal = comparer(v, x); } catch (e) { o.onError(e); return; } if (!equal) { o.onNext(false); o.onCompleted(); } } else if (doner) { o.onNext(false); o.onCompleted(); } else { ql.push(x); } }, function(e) { o.onError(e); }, function () { donel = true; if (ql.length === 0) { if (qr.length > 0) { o.onNext(false); o.onCompleted(); } else if (doner) { o.onNext(true); o.onCompleted(); } } }); (isArrayLike(second) || isIterable(second)) && (second = observableFrom(second)); isPromise(second) && (second = observableFromPromise(second)); var subscription2 = second.subscribe(function (x) { var equal; if (ql.length > 0) { var v = ql.shift(); try { equal = comparer(v, x); } catch (exception) { o.onError(exception); return; } if (!equal) { o.onNext(false); o.onCompleted(); } } else if (donel) { o.onNext(false); o.onCompleted(); } else { qr.push(x); } }, function(e) { o.onError(e); }, function () { doner = true; if (qr.length === 0) { if (ql.length > 0) { o.onNext(false); o.onCompleted(); } else if (donel) { o.onNext(true); o.onCompleted(); } } }); return new CompositeDisposable(subscription1, subscription2); }, first); }; function elementAtOrDefault(source, index, hasDefault, defaultValue) { if (index < 0) { throw new ArgumentOutOfRangeError(); } return new AnonymousObservable(function (o) { var i = index; return source.subscribe(function (x) { if (i-- === 0) { o.onNext(x); o.onCompleted(); } }, function (e) { o.onError(e); }, function () { if (!hasDefault) { o.onError(new ArgumentOutOfRangeError()); } else { o.onNext(defaultValue); o.onCompleted(); } }); }, source); } /** * Returns the element at a specified index in a sequence. * @example * var res = source.elementAt(5); * @param {Number} index The zero-based index of the element to retrieve. * @returns {Observable} An observable sequence that produces the element at the specified position in the source sequence. */ observableProto.elementAt = function (index) { return elementAtOrDefault(this, index, false); }; /** * Returns the element at a specified index in a sequence or a default value if the index is out of range. * @example * var res = source.elementAtOrDefault(5); * var res = source.elementAtOrDefault(5, 0); * @param {Number} index The zero-based index of the element to retrieve. * @param [defaultValue] The default value if the index is outside the bounds of the source sequence. * @returns {Observable} An observable sequence that produces the element at the specified position in the source sequence, or a default value if the index is outside the bounds of the source sequence. */ observableProto.elementAtOrDefault = function (index, defaultValue) { return elementAtOrDefault(this, index, true, defaultValue); }; function singleOrDefaultAsync(source, hasDefault, defaultValue) { return new AnonymousObservable(function (o) { var value = defaultValue, seenValue = false; return source.subscribe(function (x) { if (seenValue) { o.onError(new Error('Sequence contains more than one element')); } else { value = x; seenValue = true; } }, function (e) { o.onError(e); }, function () { if (!seenValue && !hasDefault) { o.onError(new EmptyError()); } else { o.onNext(value); o.onCompleted(); } }); }, source); } /** * Returns the only element of an observable sequence that satisfies the condition in the optional predicate, and reports an exception if there is not exactly one element in the observable sequence. * @param {Function} [predicate] A predicate function to evaluate for elements in the source sequence. * @param {Any} [thisArg] Object to use as `this` when executing the predicate. * @returns {Observable} Sequence containing the single element in the observable sequence that satisfies the condition in the predicate. */ observableProto.single = function (predicate, thisArg) { return predicate && isFunction(predicate) ? this.where(predicate, thisArg).single() : singleOrDefaultAsync(this, false); }; /** * Returns the only element of an observable sequence that matches the predicate, or a default value if no such element exists; this method reports an exception if there is more than one element in the observable sequence. * @example * var res = res = source.singleOrDefault(); * var res = res = source.singleOrDefault(function (x) { return x === 42; }); * res = source.singleOrDefault(function (x) { return x === 42; }, 0); * res = source.singleOrDefault(null, 0); * @memberOf Observable# * @param {Function} predicate A predicate function to evaluate for elements in the source sequence. * @param [defaultValue] The default value if the index is outside the bounds of the source sequence. * @param {Any} [thisArg] Object to use as `this` when executing the predicate. * @returns {Observable} Sequence containing the single element in the observable sequence that satisfies the condition in the predicate, or a default value if no such element exists. */ observableProto.singleOrDefault = function (predicate, defaultValue, thisArg) { return predicate && isFunction(predicate) ? this.filter(predicate, thisArg).singleOrDefault(null, defaultValue) : singleOrDefaultAsync(this, true, defaultValue); }; function firstOrDefaultAsync(source, hasDefault, defaultValue) { return new AnonymousObservable(function (o) { return source.subscribe(function (x) { o.onNext(x); o.onCompleted(); }, function (e) { o.onError(e); }, function () { if (!hasDefault) { o.onError(new EmptyError()); } else { o.onNext(defaultValue); o.onCompleted(); } }); }, source); } /** * Returns the first element of an observable sequence that satisfies the condition in the predicate if present else the first item in the sequence. * @example * var res = res = source.first(); * var res = res = source.first(function (x) { return x > 3; }); * @param {Function} [predicate] A predicate function to evaluate for elements in the source sequence. * @param {Any} [thisArg] Object to use as `this` when executing the predicate. * @returns {Observable} Sequence containing the first element in the observable sequence that satisfies the condition in the predicate if provided, else the first item in the sequence. */ observableProto.first = function (predicate, thisArg) { return predicate ? this.where(predicate, thisArg).first() : firstOrDefaultAsync(this, false); }; /** * Returns the first element of an observable sequence that satisfies the condition in the predicate, or a default value if no such element exists. * @param {Function} [predicate] A predicate function to evaluate for elements in the source sequence. * @param {Any} [defaultValue] The default value if no such element exists. If not specified, defaults to null. * @param {Any} [thisArg] Object to use as `this` when executing the predicate. * @returns {Observable} Sequence containing the first element in the observable sequence that satisfies the condition in the predicate, or a default value if no such element exists. */ observableProto.firstOrDefault = function (predicate, defaultValue, thisArg) { return predicate ? this.where(predicate).firstOrDefault(null, defaultValue) : firstOrDefaultAsync(this, true, defaultValue); }; function lastOrDefaultAsync(source, hasDefault, defaultValue) { return new AnonymousObservable(function (o) { var value = defaultValue, seenValue = false; return source.subscribe(function (x) { value = x; seenValue = true; }, function (e) { o.onError(e); }, function () { if (!seenValue && !hasDefault) { o.onError(new EmptyError()); } else { o.onNext(value); o.onCompleted(); } }); }, source); } /** * Returns the last element of an observable sequence that satisfies the condition in the predicate if specified, else the last element. * @param {Function} [predicate] A predicate function to evaluate for elements in the source sequence. * @param {Any} [thisArg] Object to use as `this` when executing the predicate. * @returns {Observable} Sequence containing the last element in the observable sequence that satisfies the condition in the predicate. */ observableProto.last = function (predicate, thisArg) { return predicate ? this.where(predicate, thisArg).last() : lastOrDefaultAsync(this, false); }; /** * Returns the last element of an observable sequence that satisfies the condition in the predicate, or a default value if no such element exists. * @param {Function} [predicate] A predicate function to evaluate for elements in the source sequence. * @param [defaultValue] The default value if no such element exists. If not specified, defaults to null. * @param {Any} [thisArg] Object to use as `this` when executing the predicate. * @returns {Observable} Sequence containing the last element in the observable sequence that satisfies the condition in the predicate, or a default value if no such element exists. */ observableProto.lastOrDefault = function (predicate, defaultValue, thisArg) { return predicate ? this.where(predicate, thisArg).lastOrDefault(null, defaultValue) : lastOrDefaultAsync(this, true, defaultValue); }; function findValue (source, predicate, thisArg, yieldIndex) { var callback = bindCallback(predicate, thisArg, 3); return new AnonymousObservable(function (o) { var i = 0; return source.subscribe(function (x) { var shouldRun; try { shouldRun = callback(x, i, source); } catch (e) { o.onError(e); return; } if (shouldRun) { o.onNext(yieldIndex ? i : x); o.onCompleted(); } else { i++; } }, function (e) { o.onError(e); }, function () { o.onNext(yieldIndex ? -1 : undefined); o.onCompleted(); }); }, source); } /** * Searches for an element that matches the conditions defined by the specified predicate, and returns the first occurrence within the entire Observable sequence. * @param {Function} predicate The predicate that defines the conditions of the element to search for. * @param {Any} [thisArg] Object to use as `this` when executing the predicate. * @returns {Observable} An Observable sequence with the first element that matches the conditions defined by the specified predicate, if found; otherwise, undefined. */ observableProto.find = function (predicate, thisArg) { return findValue(this, predicate, thisArg, false); }; /** * Searches for an element that matches the conditions defined by the specified predicate, and returns * an Observable sequence with the zero-based index of the first occurrence within the entire Observable sequence. * @param {Function} predicate The predicate that defines the conditions of the element to search for. * @param {Any} [thisArg] Object to use as `this` when executing the predicate. * @returns {Observable} An Observable sequence with the zero-based index of the first occurrence of an element that matches the conditions defined by match, if found; otherwise, –1. */ observableProto.findIndex = function (predicate, thisArg) { return findValue(this, predicate, thisArg, true); }; /** * Converts the observable sequence to a Set if it exists. * @returns {Observable} An observable sequence with a single value of a Set containing the values from the observable sequence. */ observableProto.toSet = function () { if (typeof root.Set === 'undefined') { throw new TypeError(); } var source = this; return new AnonymousObservable(function (o) { var s = new root.Set(); return source.subscribe( function (x) { s.add(x); }, function (e) { o.onError(e); }, function () { o.onNext(s); o.onCompleted(); }); }, source); }; /** * Converts the observable sequence to a Map if it exists. * @param {Function} keySelector A function which produces the key for the Map. * @param {Function} [elementSelector] An optional function which produces the element for the Map. If not present, defaults to the value from the observable sequence. * @returns {Observable} An observable sequence with a single value of a Map containing the values from the observable sequence. */ observableProto.toMap = function (keySelector, elementSelector) { if (typeof root.Map === 'undefined') { throw new TypeError(); } var source = this; return new AnonymousObservable(function (o) { var m = new root.Map(); return source.subscribe( function (x) { var key; try { key = keySelector(x); } catch (e) { o.onError(e); return; } var element = x; if (elementSelector) { try { element = elementSelector(x); } catch (e) { o.onError(e); return; } } m.set(key, element); }, function (e) { o.onError(e); }, function () { o.onNext(m); o.onCompleted(); }); }, source); }; var fnString = 'function', throwString = 'throw', isObject = Rx.internals.isObject; function toThunk(obj, ctx) { if (Array.isArray(obj)) { return objectToThunk.call(ctx, obj); } if (isGeneratorFunction(obj)) { return observableSpawn(obj.call(ctx)); } if (isGenerator(obj)) { return observableSpawn(obj); } if (isObservable(obj)) { return observableToThunk(obj); } if (isPromise(obj)) { return promiseToThunk(obj); } if (typeof obj === fnString) { return obj; } if (isObject(obj) || Array.isArray(obj)) { return objectToThunk.call(ctx, obj); } return obj; } function objectToThunk(obj) { var ctx = this; return function (done) { var keys = Object.keys(obj), pending = keys.length, results = new obj.constructor(), finished; if (!pending) { timeoutScheduler.schedule(function () { done(null, results); }); return; } for (var i = 0, len = keys.length; i < len; i++) { run(obj[keys[i]], keys[i]); } function run(fn, key) { if (finished) { return; } try { fn = toThunk(fn, ctx); if (typeof fn !== fnString) { results[key] = fn; return --pending || done(null, results); } fn.call(ctx, function(err, res) { if (finished) { return; } if (err) { finished = true; return done(err); } results[key] = res; --pending || done(null, results); }); } catch (e) { finished = true; done(e); } } } } function observableToThunk(observable) { return function (fn) { var value, hasValue = false; observable.subscribe( function (v) { value = v; hasValue = true; }, fn, function () { hasValue && fn(null, value); }); } } function promiseToThunk(promise) { return function(fn) { promise.then(function(res) { fn(null, res); }, fn); } } function isObservable(obj) { return obj && typeof obj.subscribe === fnString; } function isGeneratorFunction(obj) { return obj && obj.constructor && obj.constructor.name === 'GeneratorFunction'; } function isGenerator(obj) { return obj && typeof obj.next === fnString && typeof obj[throwString] === fnString; } /* * Spawns a generator function which allows for Promises, Observable sequences, Arrays, Objects, Generators and functions. * @param {Function} The spawning function. * @returns {Function} a function which has a done continuation. */ var observableSpawn = Rx.spawn = function (fn) { var isGenFun = isGeneratorFunction(fn); return function (done) { var ctx = this, gen = fn; if (isGenFun) { for(var args = [], i = 0, len = arguments.length; i < len; i++) { args.push(arguments[i]); } var len = args.length, hasCallback = len && typeof args[len - 1] === fnString; done = hasCallback ? args.pop() : handleError; gen = fn.apply(this, args); } else { done = done || handleError; } next(); function exit(err, res) { timeoutScheduler.schedule(done.bind(ctx, err, res)); } function next(err, res) { var ret; // multiple args if (arguments.length > 2) { for(var res = [], i = 1, len = arguments.length; i < len; i++) { res.push(arguments[i]); } } if (err) { try { ret = gen[throwString](err); } catch (e) { return exit(e); } } if (!err) { try { ret = gen.next(res); } catch (e) { return exit(e); } } if (ret.done) { return exit(null, ret.value); } ret.value = toThunk(ret.value, ctx); if (typeof ret.value === fnString) { var called = false; try { ret.value.call(ctx, function() { if (called) { return; } called = true; next.apply(ctx, arguments); }); } catch (e) { timeoutScheduler.schedule(function () { if (called) { return; } called = true; next.call(ctx, e); }); } return; } // Not supported next(new TypeError('Rx.spawn only supports a function, Promise, Observable, Object or Array.')); } } }; function handleError(err) { if (!err) { return; } timeoutScheduler.schedule(function() { throw err; }); } /** * Invokes the specified function asynchronously on the specified scheduler, surfacing the result through an observable sequence. * * @example * var res = Rx.Observable.start(function () { console.log('hello'); }); * var res = Rx.Observable.start(function () { console.log('hello'); }, Rx.Scheduler.timeout); * var res = Rx.Observable.start(function () { this.log('hello'); }, Rx.Scheduler.timeout, console); * * @param {Function} func Function to run asynchronously. * @param {Scheduler} [scheduler] Scheduler to run the function on. If not specified, defaults to Scheduler.timeout. * @param [context] The context for the func parameter to be executed. If not specified, defaults to undefined. * @returns {Observable} An observable sequence exposing the function's result value, or an exception. * * Remarks * * The function is called immediately, not during the subscription of the resulting sequence. * * Multiple subscriptions to the resulting sequence can observe the function's result. */ Observable.start = function (func, context, scheduler) { return observableToAsync(func, context, scheduler)(); }; /** * Converts the function into an asynchronous function. Each invocation of the resulting asynchronous function causes an invocation of the original synchronous function on the specified scheduler. * @param {Function} function Function to convert to an asynchronous function. * @param {Scheduler} [scheduler] Scheduler to run the function on. If not specified, defaults to Scheduler.timeout. * @param {Mixed} [context] The context for the func parameter to be executed. If not specified, defaults to undefined. * @returns {Function} Asynchronous function. */ var observableToAsync = Observable.toAsync = function (func, context, scheduler) { isScheduler(scheduler) || (scheduler = timeoutScheduler); return function () { var args = arguments, subject = new AsyncSubject(); scheduler.schedule(function () { var result; try { result = func.apply(context, args); } catch (e) { subject.onError(e); return; } subject.onNext(result); subject.onCompleted(); }); return subject.asObservable(); }; }; /** * Converts a callback function to an observable sequence. * * @param {Function} function Function with a callback as the last parameter to convert to an Observable sequence. * @param {Mixed} [context] The context for the func parameter to be executed. If not specified, defaults to undefined. * @param {Function} [selector] A selector which takes the arguments from the callback to produce a single item to yield on next. * @returns {Function} A function, when executed with the required parameters minus the callback, produces an Observable sequence with a single value of the arguments to the callback as an array. */ Observable.fromCallback = function (func, context, selector) { return function () { var len = arguments.length, args = new Array(len) for(var i = 0; i < len; i++) { args[i] = arguments[i]; } return new AnonymousObservable(function (observer) { function handler() { var len = arguments.length, results = new Array(len); for(var i = 0; i < len; i++) { results[i] = arguments[i]; } if (selector) { try { results = selector.apply(context, results); } catch (e) { return observer.onError(e); } observer.onNext(results); } else { if (results.length <= 1) { observer.onNext.apply(observer, results); } else { observer.onNext(results); } } observer.onCompleted(); } args.push(handler); func.apply(context, args); }).publishLast().refCount(); }; }; /** * Converts a Node.js callback style function to an observable sequence. This must be in function (err, ...) format. * @param {Function} func The function to call * @param {Mixed} [context] The context for the func parameter to be executed. If not specified, defaults to undefined. * @param {Function} [selector] A selector which takes the arguments from the callback minus the error to produce a single item to yield on next. * @returns {Function} An async function which when applied, returns an observable sequence with the callback arguments as an array. */ Observable.fromNodeCallback = function (func, context, selector) { return function () { var len = arguments.length, args = new Array(len); for(var i = 0; i < len; i++) { args[i] = arguments[i]; } return new AnonymousObservable(function (observer) { function handler(err) { if (err) { observer.onError(err); return; } var len = arguments.length, results = []; for(var i = 1; i < len; i++) { results[i - 1] = arguments[i]; } if (selector) { try { results = selector.apply(context, results); } catch (e) { return observer.onError(e); } observer.onNext(results); } else { if (results.length <= 1) { observer.onNext.apply(observer, results); } else { observer.onNext(results); } } observer.onCompleted(); } args.push(handler); func.apply(context, args); }).publishLast().refCount(); }; }; function createListener (element, name, handler) { if (element.addEventListener) { element.addEventListener(name, handler, false); return disposableCreate(function () { element.removeEventListener(name, handler, false); }); } throw new Error('No listener found'); } function createEventListener (el, eventName, handler) { var disposables = new CompositeDisposable(); // Asume NodeList if (Object.prototype.toString.call(el) === '[object NodeList]') { for (var i = 0, len = el.length; i < len; i++) { disposables.add(createEventListener(el.item(i), eventName, handler)); } } else if (el) { disposables.add(createListener(el, eventName, handler)); } return disposables; } /** * Configuration option to determine whether to use native events only */ Rx.config.useNativeEvents = false; /** * Creates an observable sequence by adding an event listener to the matching DOMElement or each item in the NodeList. * * @example * var source = Rx.Observable.fromEvent(element, 'mouseup'); * * @param {Object} element The DOMElement or NodeList to attach a listener. * @param {String} eventName The event name to attach the observable sequence. * @param {Function} [selector] A selector which takes the arguments from the event handler to produce a single item to yield on next. * @returns {Observable} An observable sequence of events from the specified element and the specified event. */ Observable.fromEvent = function (element, eventName, selector) { // Node.js specific if (element.addListener) { return fromEventPattern( function (h) { element.addListener(eventName, h); }, function (h) { element.removeListener(eventName, h); }, selector); } // Use only if non-native events are allowed if (!Rx.config.useNativeEvents) { // Handles jq, Angular.js, Zepto, Marionette, Ember.js if (typeof element.on === 'function' && typeof element.off === 'function') { return fromEventPattern( function (h) { element.on(eventName, h); }, function (h) { element.off(eventName, h); }, selector); } } return new AnonymousObservable(function (observer) { return createEventListener( element, eventName, function handler (e) { var results = e; if (selector) { try { results = selector(arguments); } catch (err) { return observer.onError(err); } } observer.onNext(results); }); }).publish().refCount(); }; /** * Creates an observable sequence from an event emitter via an addHandler/removeHandler pair. * @param {Function} addHandler The function to add a handler to the emitter. * @param {Function} [removeHandler] The optional function to remove a handler from an emitter. * @param {Function} [selector] A selector which takes the arguments from the event handler to produce a single item to yield on next. * @returns {Observable} An observable sequence which wraps an event from an event emitter */ var fromEventPattern = Observable.fromEventPattern = function (addHandler, removeHandler, selector) { return new AnonymousObservable(function (observer) { function innerHandler (e) { var result = e; if (selector) { try { result = selector(arguments); } catch (err) { return observer.onError(err); } } observer.onNext(result); } var returnValue = addHandler(innerHandler); return disposableCreate(function () { if (removeHandler) { removeHandler(innerHandler, returnValue); } }); }).publish().refCount(); }; /** * Invokes the asynchronous function, surfacing the result through an observable sequence. * @param {Function} functionAsync Asynchronous function which returns a Promise to run. * @returns {Observable} An observable sequence exposing the function's result value, or an exception. */ Observable.startAsync = function (functionAsync) { var promise; try { promise = functionAsync(); } catch (e) { return observableThrow(e); } return observableFromPromise(promise); } var PausableObservable = (function (__super__) { inherits(PausableObservable, __super__); function subscribe(observer) { var conn = this.source.publish(), subscription = conn.subscribe(observer), connection = disposableEmpty; var pausable = this.pauser.distinctUntilChanged().subscribe(function (b) { if (b) { connection = conn.connect(); } else { connection.dispose(); connection = disposableEmpty; } }); return new CompositeDisposable(subscription, connection, pausable); } function PausableObservable(source, pauser) { this.source = source; this.controller = new Subject(); if (pauser && pauser.subscribe) { this.pauser = this.controller.merge(pauser); } else { this.pauser = this.controller; } __super__.call(this, subscribe, source); } PausableObservable.prototype.pause = function () { this.controller.onNext(false); }; PausableObservable.prototype.resume = function () { this.controller.onNext(true); }; return PausableObservable; }(Observable)); /** * Pauses the underlying observable sequence based upon the observable sequence which yields true/false. * @example * var pauser = new Rx.Subject(); * var source = Rx.Observable.interval(100).pausable(pauser); * @param {Observable} pauser The observable sequence used to pause the underlying sequence. * @returns {Observable} The observable sequence which is paused based upon the pauser. */ observableProto.pausable = function (pauser) { return new PausableObservable(this, pauser); }; function combineLatestSource(source, subject, resultSelector) { return new AnonymousObservable(function (o) { var hasValue = [false, false], hasValueAll = false, isDone = false, values = new Array(2), err; function next(x, i) { values[i] = x var res; hasValue[i] = true; if (hasValueAll || (hasValueAll = hasValue.every(identity))) { if (err) { o.onError(err); return; } try { res = resultSelector.apply(null, values); } catch (ex) { o.onError(ex); return; } o.onNext(res); } if (isDone && values[1]) { o.onCompleted(); } } return new CompositeDisposable( source.subscribe( function (x) { next(x, 0); }, function (e) { if (values[1]) { o.onError(e); } else { err = e; } }, function () { isDone = true; values[1] && o.onCompleted(); }), subject.subscribe( function (x) { next(x, 1); }, function (e) { o.onError(e); }, function () { isDone = true; next(true, 1); }) ); }, source); } var PausableBufferedObservable = (function (__super__) { inherits(PausableBufferedObservable, __super__); function subscribe(o) { var q = [], previousShouldFire; var subscription = combineLatestSource( this.source, this.pauser.distinctUntilChanged().startWith(false), function (data, shouldFire) { return { data: data, shouldFire: shouldFire }; }) .subscribe( function (results) { if (previousShouldFire !== undefined && results.shouldFire != previousShouldFire) { previousShouldFire = results.shouldFire; // change in shouldFire if (results.shouldFire) { while (q.length > 0) { o.onNext(q.shift()); } } } else { previousShouldFire = results.shouldFire; // new data if (results.shouldFire) { o.onNext(results.data); } else { q.push(results.data); } } }, function (err) { // Empty buffer before sending error while (q.length > 0) { o.onNext(q.shift()); } o.onError(err); }, function () { // Empty buffer before sending completion while (q.length > 0) { o.onNext(q.shift()); } o.onCompleted(); } ); return subscription; } function PausableBufferedObservable(source, pauser) { this.source = source; this.controller = new Subject(); if (pauser && pauser.subscribe) { this.pauser = this.controller.merge(pauser); } else { this.pauser = this.controller; } __super__.call(this, subscribe, source); } PausableBufferedObservable.prototype.pause = function () { this.controller.onNext(false); }; PausableBufferedObservable.prototype.resume = function () { this.controller.onNext(true); }; return PausableBufferedObservable; }(Observable)); /** * Pauses the underlying observable sequence based upon the observable sequence which yields true/false, * and yields the values that were buffered while paused. * @example * var pauser = new Rx.Subject(); * var source = Rx.Observable.interval(100).pausableBuffered(pauser); * @param {Observable} pauser The observable sequence used to pause the underlying sequence. * @returns {Observable} The observable sequence which is paused based upon the pauser. */ observableProto.pausableBuffered = function (subject) { return new PausableBufferedObservable(this, subject); }; var ControlledObservable = (function (__super__) { inherits(ControlledObservable, __super__); function subscribe (observer) { return this.source.subscribe(observer); } function ControlledObservable (source, enableQueue) { __super__.call(this, subscribe, source); this.subject = new ControlledSubject(enableQueue); this.source = source.multicast(this.subject).refCount(); } ControlledObservable.prototype.request = function (numberOfItems) { if (numberOfItems == null) { numberOfItems = -1; } return this.subject.request(numberOfItems); }; return ControlledObservable; }(Observable)); var ControlledSubject = (function (__super__) { function subscribe (observer) { return this.subject.subscribe(observer); } inherits(ControlledSubject, __super__); function ControlledSubject(enableQueue) { enableQueue == null && (enableQueue = true); __super__.call(this, subscribe); this.subject = new Subject(); this.enableQueue = enableQueue; this.queue = enableQueue ? [] : null; this.requestedCount = 0; this.requestedDisposable = disposableEmpty; this.error = null; this.hasFailed = false; this.hasCompleted = false; } addProperties(ControlledSubject.prototype, Observer, { onCompleted: function () { this.hasCompleted = true; if (!this.enableQueue || this.queue.length === 0) this.subject.onCompleted(); else this.queue.push(Rx.Notification.createOnCompleted()); }, onError: function (error) { this.hasFailed = true; this.error = error; if (!this.enableQueue || this.queue.length === 0) this.subject.onError(error); else this.queue.push(Rx.Notification.createOnError(error)); }, onNext: function (value) { var hasRequested = false; if (this.requestedCount === 0) { this.enableQueue && this.queue.push(Rx.Notification.createOnNext(value)); } else { (this.requestedCount !== -1 && this.requestedCount-- === 0) && this.disposeCurrentRequest(); hasRequested = true; } hasRequested && this.subject.onNext(value); }, _processRequest: function (numberOfItems) { if (this.enableQueue) { while ((this.queue.length >= numberOfItems && numberOfItems > 0) || (this.queue.length > 0 && this.queue[0].kind !== 'N')) { var first = this.queue.shift(); first.accept(this.subject); if (first.kind === 'N') numberOfItems--; else { this.disposeCurrentRequest(); this.queue = []; } } return { numberOfItems : numberOfItems, returnValue: this.queue.length !== 0}; } //TODO I don't think this is ever necessary, since termination of a sequence without a queue occurs in the onCompletion or onError function //if (this.hasFailed) { // this.subject.onError(this.error); //} else if (this.hasCompleted) { // this.subject.onCompleted(); //} return { numberOfItems: numberOfItems, returnValue: false }; }, request: function (number) { this.disposeCurrentRequest(); var self = this, r = this._processRequest(number); var number = r.numberOfItems; if (!r.returnValue) { this.requestedCount = number; this.requestedDisposable = disposableCreate(function () { self.requestedCount = 0; }); return this.requestedDisposable; } else { return disposableEmpty; } }, disposeCurrentRequest: function () { this.requestedDisposable.dispose(); this.requestedDisposable = disposableEmpty; } }); return ControlledSubject; }(Observable)); /** * Attaches a controller to the observable sequence with the ability to queue. * @example * var source = Rx.Observable.interval(100).controlled(); * source.request(3); // Reads 3 values * @param {Observable} pauser The observable sequence used to pause the underlying sequence. * @returns {Observable} The observable sequence which is paused based upon the pauser. */ observableProto.controlled = function (enableQueue) { if (enableQueue == null) { enableQueue = true; } return new ControlledObservable(this, enableQueue); }; var StopAndWaitObservable = (function (__super__) { function subscribe (observer) { this.subscription = this.source.subscribe(new StopAndWaitObserver(observer, this, this.subscription)); var self = this; timeoutScheduler.schedule(function () { self.source.request(1); }); return this.subscription; } inherits(StopAndWaitObservable, __super__); function StopAndWaitObservable (source) { __super__.call(this, subscribe, source); this.source = source; } var StopAndWaitObserver = (function (__sub__) { inherits(StopAndWaitObserver, __sub__); function StopAndWaitObserver (observer, observable, cancel) { __sub__.call(this); this.observer = observer; this.observable = observable; this.cancel = cancel; } var stopAndWaitObserverProto = StopAndWaitObserver.prototype; stopAndWaitObserverProto.completed = function () { this.observer.onCompleted(); this.dispose(); }; stopAndWaitObserverProto.error = function (error) { this.observer.onError(error); this.dispose(); } stopAndWaitObserverProto.next = function (value) { this.observer.onNext(value); var self = this; timeoutScheduler.schedule(function () { self.observable.source.request(1); }); }; stopAndWaitObserverProto.dispose = function () { this.observer = null; if (this.cancel) { this.cancel.dispose(); this.cancel = null; } __sub__.prototype.dispose.call(this); }; return StopAndWaitObserver; }(AbstractObserver)); return StopAndWaitObservable; }(Observable)); /** * Attaches a stop and wait observable to the current observable. * @returns {Observable} A stop and wait observable. */ ControlledObservable.prototype.stopAndWait = function () { return new StopAndWaitObservable(this); }; var WindowedObservable = (function (__super__) { function subscribe (observer) { this.subscription = this.source.subscribe(new WindowedObserver(observer, this, this.subscription)); var self = this; timeoutScheduler.schedule(function () { self.source.request(self.windowSize); }); return this.subscription; } inherits(WindowedObservable, __super__); function WindowedObservable(source, windowSize) { __super__.call(this, subscribe, source); this.source = source; this.windowSize = windowSize; } var WindowedObserver = (function (__sub__) { inherits(WindowedObserver, __sub__); function WindowedObserver(observer, observable, cancel) { this.observer = observer; this.observable = observable; this.cancel = cancel; this.received = 0; } var windowedObserverPrototype = WindowedObserver.prototype; windowedObserverPrototype.completed = function () { this.observer.onCompleted(); this.dispose(); }; windowedObserverPrototype.error = function (error) { this.observer.onError(error); this.dispose(); }; windowedObserverPrototype.next = function (value) { this.observer.onNext(value); this.received = ++this.received % this.observable.windowSize; if (this.received === 0) { var self = this; timeoutScheduler.schedule(function () { self.observable.source.request(self.observable.windowSize); }); } }; windowedObserverPrototype.dispose = function () { this.observer = null; if (this.cancel) { this.cancel.dispose(); this.cancel = null; } __sub__.prototype.dispose.call(this); }; return WindowedObserver; }(AbstractObserver)); return WindowedObservable; }(Observable)); /** * Creates a sliding windowed observable based upon the window size. * @param {Number} windowSize The number of items in the window * @returns {Observable} A windowed observable based upon the window size. */ ControlledObservable.prototype.windowed = function (windowSize) { return new WindowedObservable(this, windowSize); }; /** * Pipes the existing Observable sequence into a Node.js Stream. * @param {Stream} dest The destination Node.js stream. * @returns {Stream} The destination stream. */ observableProto.pipe = function (dest) { var source = this.pausableBuffered(); function onDrain() { source.resume(); } dest.addListener('drain', onDrain); source.subscribe( function (x) { !dest.write(String(x)) && source.pause(); }, function (err) { dest.emit('error', err); }, function () { // Hack check because STDIO is not closable !dest._isStdio && dest.end(); dest.removeListener('drain', onDrain); }); source.resume(); return dest; }; /** * Multicasts the source sequence notifications through an instantiated subject into all uses of the sequence within a selector function. Each * subscription to the resulting sequence causes a separate multicast invocation, exposing the sequence resulting from the selector function's * invocation. For specializations with fixed subject types, see Publish, PublishLast, and Replay. * * @example * 1 - res = source.multicast(observable); * 2 - res = source.multicast(function () { return new Subject(); }, function (x) { return x; }); * * @param {Function|Subject} subjectOrSubjectSelector * Factory function to create an intermediate subject through which the source sequence's elements will be multicast to the selector function. * Or: * Subject to push source elements into. * * @param {Function} [selector] Optional selector function which can use the multicasted source sequence subject to the policies enforced by the created subject. Specified only if <paramref name="subjectOrSubjectSelector" is a factory function. * @returns {Observable} An observable sequence that contains the elements of a sequence produced by multicasting the source sequence within a selector function. */ observableProto.multicast = function (subjectOrSubjectSelector, selector) { var source = this; return typeof subjectOrSubjectSelector === 'function' ? new AnonymousObservable(function (observer) { var connectable = source.multicast(subjectOrSubjectSelector()); return new CompositeDisposable(selector(connectable).subscribe(observer), connectable.connect()); }, source) : new ConnectableObservable(source, subjectOrSubjectSelector); }; /** * Returns an observable sequence that is the result of invoking the selector on a connectable observable sequence that shares a single subscription to the underlying sequence. * This operator is a specialization of Multicast using a regular Subject. * * @example * var resres = source.publish(); * var res = source.publish(function (x) { return x; }); * * @param {Function} [selector] Selector function which can use the multicasted source sequence as many times as needed, without causing multiple subscriptions to the source sequence. Subscribers to the given source will receive all notifications of the source from the time of the subscription on. * @returns {Observable} An observable sequence that contains the elements of a sequence produced by multicasting the source sequence within a selector function. */ observableProto.publish = function (selector) { return selector && isFunction(selector) ? this.multicast(function () { return new Subject(); }, selector) : this.multicast(new Subject()); }; /** * Returns an observable sequence that shares a single subscription to the underlying sequence. * This operator is a specialization of publish which creates a subscription when the number of observers goes from zero to one, then shares that subscription with all subsequent observers until the number of observers returns to zero, at which point the subscription is disposed. * @returns {Observable} An observable sequence that contains the elements of a sequence produced by multicasting the source sequence. */ observableProto.share = function () { return this.publish().refCount(); }; /** * Returns an observable sequence that is the result of invoking the selector on a connectable observable sequence that shares a single subscription to the underlying sequence containing only the last notification. * This operator is a specialization of Multicast using a AsyncSubject. * * @example * var res = source.publishLast(); * var res = source.publishLast(function (x) { return x; }); * * @param selector [Optional] Selector function which can use the multicasted source sequence as many times as needed, without causing multiple subscriptions to the source sequence. Subscribers to the given source will only receive the last notification of the source. * @returns {Observable} An observable sequence that contains the elements of a sequence produced by multicasting the source sequence within a selector function. */ observableProto.publishLast = function (selector) { return selector && isFunction(selector) ? this.multicast(function () { return new AsyncSubject(); }, selector) : this.multicast(new AsyncSubject()); }; /** * Returns an observable sequence that is the result of invoking the selector on a connectable observable sequence that shares a single subscription to the underlying sequence and starts with initialValue. * This operator is a specialization of Multicast using a BehaviorSubject. * * @example * var res = source.publishValue(42); * var res = source.publishValue(function (x) { return x.select(function (y) { return y * y; }) }, 42); * * @param {Function} [selector] Optional selector function which can use the multicasted source sequence as many times as needed, without causing multiple subscriptions to the source sequence. Subscribers to the given source will receive immediately receive the initial value, followed by all notifications of the source from the time of the subscription on. * @param {Mixed} initialValue Initial value received by observers upon subscription. * @returns {Observable} An observable sequence that contains the elements of a sequence produced by multicasting the source sequence within a selector function. */ observableProto.publishValue = function (initialValueOrSelector, initialValue) { return arguments.length === 2 ? this.multicast(function () { return new BehaviorSubject(initialValue); }, initialValueOrSelector) : this.multicast(new BehaviorSubject(initialValueOrSelector)); }; /** * Returns an observable sequence that shares a single subscription to the underlying sequence and starts with an initialValue. * This operator is a specialization of publishValue which creates a subscription when the number of observers goes from zero to one, then shares that subscription with all subsequent observers until the number of observers returns to zero, at which point the subscription is disposed. * @param {Mixed} initialValue Initial value received by observers upon subscription. * @returns {Observable} An observable sequence that contains the elements of a sequence produced by multicasting the source sequence. */ observableProto.shareValue = function (initialValue) { return this.publishValue(initialValue).refCount(); }; /** * Returns an observable sequence that is the result of invoking the selector on a connectable observable sequence that shares a single subscription to the underlying sequence replaying notifications subject to a maximum time length for the replay buffer. * This operator is a specialization of Multicast using a ReplaySubject. * * @example * var res = source.replay(null, 3); * var res = source.replay(null, 3, 500); * var res = source.replay(null, 3, 500, scheduler); * var res = source.replay(function (x) { return x.take(6).repeat(); }, 3, 500, scheduler); * * @param selector [Optional] Selector function which can use the multicasted source sequence as many times as needed, without causing multiple subscriptions to the source sequence. Subscribers to the given source will receive all the notifications of the source subject to the specified replay buffer trimming policy. * @param bufferSize [Optional] Maximum element count of the replay buffer. * @param windowSize [Optional] Maximum time length of the replay buffer. * @param scheduler [Optional] Scheduler where connected observers within the selector function will be invoked on. * @returns {Observable} An observable sequence that contains the elements of a sequence produced by multicasting the source sequence within a selector function. */ observableProto.replay = function (selector, bufferSize, windowSize, scheduler) { return selector && isFunction(selector) ? this.multicast(function () { return new ReplaySubject(bufferSize, windowSize, scheduler); }, selector) : this.multicast(new ReplaySubject(bufferSize, windowSize, scheduler)); }; /** * Returns an observable sequence that shares a single subscription to the underlying sequence replaying notifications subject to a maximum time length for the replay buffer. * This operator is a specialization of replay which creates a subscription when the number of observers goes from zero to one, then shares that subscription with all subsequent observers until the number of observers returns to zero, at which point the subscription is disposed. * * @example * var res = source.shareReplay(3); * var res = source.shareReplay(3, 500); * var res = source.shareReplay(3, 500, scheduler); * * @param bufferSize [Optional] Maximum element count of the replay buffer. * @param window [Optional] Maximum time length of the replay buffer. * @param scheduler [Optional] Scheduler where connected observers within the selector function will be invoked on. * @returns {Observable} An observable sequence that contains the elements of a sequence produced by multicasting the source sequence. */ observableProto.shareReplay = function (bufferSize, windowSize, scheduler) { return this.replay(null, bufferSize, windowSize, scheduler).refCount(); }; var InnerSubscription = function (subject, observer) { this.subject = subject; this.observer = observer; }; InnerSubscription.prototype.dispose = function () { if (!this.subject.isDisposed && this.observer !== null) { var idx = this.subject.observers.indexOf(this.observer); this.subject.observers.splice(idx, 1); this.observer = null; } }; /** * Represents a value that changes over time. * Observers can subscribe to the subject to receive the last (or initial) value and all subsequent notifications. */ var BehaviorSubject = Rx.BehaviorSubject = (function (__super__) { function subscribe(observer) { checkDisposed(this); if (!this.isStopped) { this.observers.push(observer); observer.onNext(this.value); return new InnerSubscription(this, observer); } if (this.hasError) { observer.onError(this.error); } else { observer.onCompleted(); } return disposableEmpty; } inherits(BehaviorSubject, __super__); /** * Initializes a new instance of the BehaviorSubject class which creates a subject that caches its last value and starts with the specified value. * @param {Mixed} value Initial value sent to observers when no other value has been received by the subject yet. */ function BehaviorSubject(value) { __super__.call(this, subscribe); this.value = value, this.observers = [], this.isDisposed = false, this.isStopped = false, this.hasError = false; } addProperties(BehaviorSubject.prototype, Observer, { /** * Gets the current value or throws an exception. * Value is frozen after onCompleted is called. * After onError is called always throws the specified exception. * An exception is always thrown after dispose is called. * @returns {Mixed} The initial value passed to the constructor until onNext is called; after which, the last value passed to onNext. */ getValue: function () { checkDisposed(this); if (this.hasError) { throw this.error; } return this.value; }, /** * Indicates whether the subject has observers subscribed to it. * @returns {Boolean} Indicates whether the subject has observers subscribed to it. */ hasObservers: function () { return this.observers.length > 0; }, /** * Notifies all subscribed observers about the end of the sequence. */ onCompleted: function () { checkDisposed(this); if (this.isStopped) { return; } this.isStopped = true; for (var i = 0, os = cloneArray(this.observers), len = os.length; i < len; i++) { os[i].onCompleted(); } this.observers.length = 0; }, /** * Notifies all subscribed observers about the exception. * @param {Mixed} error The exception to send to all observers. */ onError: function (error) { checkDisposed(this); if (this.isStopped) { return; } this.isStopped = true; this.hasError = true; this.error = error; for (var i = 0, os = cloneArray(this.observers), len = os.length; i < len; i++) { os[i].onError(error); } this.observers.length = 0; }, /** * Notifies all subscribed observers about the arrival of the specified element in the sequence. * @param {Mixed} value The value to send to all observers. */ onNext: function (value) { checkDisposed(this); if (this.isStopped) { return; } this.value = value; for (var i = 0, os = cloneArray(this.observers), len = os.length; i < len; i++) { os[i].onNext(value); } }, /** * Unsubscribe all observers and release resources. */ dispose: function () { this.isDisposed = true; this.observers = null; this.value = null; this.exception = null; } }); return BehaviorSubject; }(Observable)); /** * Represents an object that is both an observable sequence as well as an observer. * Each notification is broadcasted to all subscribed and future observers, subject to buffer trimming policies. */ var ReplaySubject = Rx.ReplaySubject = (function (__super__) { var maxSafeInteger = Math.pow(2, 53) - 1; function createRemovableDisposable(subject, observer) { return disposableCreate(function () { observer.dispose(); !subject.isDisposed && subject.observers.splice(subject.observers.indexOf(observer), 1); }); } function subscribe(observer) { var so = new ScheduledObserver(this.scheduler, observer), subscription = createRemovableDisposable(this, so); checkDisposed(this); this._trim(this.scheduler.now()); this.observers.push(so); for (var i = 0, len = this.q.length; i < len; i++) { so.onNext(this.q[i].value); } if (this.hasError) { so.onError(this.error); } else if (this.isStopped) { so.onCompleted(); } so.ensureActive(); return subscription; } inherits(ReplaySubject, __super__); /** * Initializes a new instance of the ReplaySubject class with the specified buffer size, window size and scheduler. * @param {Number} [bufferSize] Maximum element count of the replay buffer. * @param {Number} [windowSize] Maximum time length of the replay buffer. * @param {Scheduler} [scheduler] Scheduler the observers are invoked on. */ function ReplaySubject(bufferSize, windowSize, scheduler) { this.bufferSize = bufferSize == null ? maxSafeInteger : bufferSize; this.windowSize = windowSize == null ? maxSafeInteger : windowSize; this.scheduler = scheduler || currentThreadScheduler; this.q = []; this.observers = []; this.isStopped = false; this.isDisposed = false; this.hasError = false; this.error = null; __super__.call(this, subscribe); } addProperties(ReplaySubject.prototype, Observer.prototype, { /** * Indicates whether the subject has observers subscribed to it. * @returns {Boolean} Indicates whether the subject has observers subscribed to it. */ hasObservers: function () { return this.observers.length > 0; }, _trim: function (now) { while (this.q.length > this.bufferSize) { this.q.shift(); } while (this.q.length > 0 && (now - this.q[0].interval) > this.windowSize) { this.q.shift(); } }, /** * Notifies all subscribed observers about the arrival of the specified element in the sequence. * @param {Mixed} value The value to send to all observers. */ onNext: function (value) { checkDisposed(this); if (this.isStopped) { return; } var now = this.scheduler.now(); this.q.push({ interval: now, value: value }); this._trim(now); for (var i = 0, os = cloneArray(this.observers), len = os.length; i < len; i++) { var observer = os[i]; observer.onNext(value); observer.ensureActive(); } }, /** * Notifies all subscribed observers about the exception. * @param {Mixed} error The exception to send to all observers. */ onError: function (error) { checkDisposed(this); if (this.isStopped) { return; } this.isStopped = true; this.error = error; this.hasError = true; var now = this.scheduler.now(); this._trim(now); for (var i = 0, os = cloneArray(this.observers), len = os.length; i < len; i++) { var observer = os[i]; observer.onError(error); observer.ensureActive(); } this.observers.length = 0; }, /** * Notifies all subscribed observers about the end of the sequence. */ onCompleted: function () { checkDisposed(this); if (this.isStopped) { return; } this.isStopped = true; var now = this.scheduler.now(); this._trim(now); for (var i = 0, os = cloneArray(this.observers), len = os.length; i < len; i++) { var observer = os[i]; observer.onCompleted(); observer.ensureActive(); } this.observers.length = 0; }, /** * Unsubscribe all observers and release resources. */ dispose: function () { this.isDisposed = true; this.observers = null; } }); return ReplaySubject; }(Observable)); var ConnectableObservable = Rx.ConnectableObservable = (function (__super__) { inherits(ConnectableObservable, __super__); function ConnectableObservable(source, subject) { var hasSubscription = false, subscription, sourceObservable = source.asObservable(); this.connect = function () { if (!hasSubscription) { hasSubscription = true; subscription = new CompositeDisposable(sourceObservable.subscribe(subject), disposableCreate(function () { hasSubscription = false; })); } return subscription; }; __super__.call(this, function (o) { return subject.subscribe(o); }); } ConnectableObservable.prototype.refCount = function () { var connectableSubscription, count = 0, source = this; return new AnonymousObservable(function (observer) { var shouldConnect = ++count === 1, subscription = source.subscribe(observer); shouldConnect && (connectableSubscription = source.connect()); return function () { subscription.dispose(); --count === 0 && connectableSubscription.dispose(); }; }); }; return ConnectableObservable; }(Observable)); var Dictionary = (function () { var primes = [1, 3, 7, 13, 31, 61, 127, 251, 509, 1021, 2039, 4093, 8191, 16381, 32749, 65521, 131071, 262139, 524287, 1048573, 2097143, 4194301, 8388593, 16777213, 33554393, 67108859, 134217689, 268435399, 536870909, 1073741789, 2147483647], noSuchkey = "no such key", duplicatekey = "duplicate key"; function isPrime(candidate) { if ((candidate & 1) === 0) { return candidate === 2; } var num1 = Math.sqrt(candidate), num2 = 3; while (num2 <= num1) { if (candidate % num2 === 0) { return false; } num2 += 2; } return true; } function getPrime(min) { var index, num, candidate; for (index = 0; index < primes.length; ++index) { num = primes[index]; if (num >= min) { return num; } } candidate = min | 1; while (candidate < primes[primes.length - 1]) { if (isPrime(candidate)) { return candidate; } candidate += 2; } return min; } function stringHashFn(str) { var hash = 757602046; if (!str.length) { return hash; } for (var i = 0, len = str.length; i < len; i++) { var character = str.charCodeAt(i); hash = ((hash << 5) - hash) + character; hash = hash & hash; } return hash; } function numberHashFn(key) { var c2 = 0x27d4eb2d; key = (key ^ 61) ^ (key >>> 16); key = key + (key << 3); key = key ^ (key >>> 4); key = key * c2; key = key ^ (key >>> 15); return key; } var getHashCode = (function () { var uniqueIdCounter = 0; return function (obj) { if (obj == null) { throw new Error(noSuchkey); } // Check for built-ins before tacking on our own for any object if (typeof obj === 'string') { return stringHashFn(obj); } if (typeof obj === 'number') { return numberHashFn(obj); } if (typeof obj === 'boolean') { return obj === true ? 1 : 0; } if (obj instanceof Date) { return numberHashFn(obj.valueOf()); } if (obj instanceof RegExp) { return stringHashFn(obj.toString()); } if (typeof obj.valueOf === 'function') { // Hack check for valueOf var valueOf = obj.valueOf(); if (typeof valueOf === 'number') { return numberHashFn(valueOf); } if (typeof valueOf === 'string') { return stringHashFn(valueOf); } } if (obj.hashCode) { return obj.hashCode(); } var id = 17 * uniqueIdCounter++; obj.hashCode = function () { return id; }; return id; }; }()); function newEntry() { return { key: null, value: null, next: 0, hashCode: 0 }; } function Dictionary(capacity, comparer) { if (capacity < 0) { throw new ArgumentOutOfRangeError(); } if (capacity > 0) { this._initialize(capacity); } this.comparer = comparer || defaultComparer; this.freeCount = 0; this.size = 0; this.freeList = -1; } var dictionaryProto = Dictionary.prototype; dictionaryProto._initialize = function (capacity) { var prime = getPrime(capacity), i; this.buckets = new Array(prime); this.entries = new Array(prime); for (i = 0; i < prime; i++) { this.buckets[i] = -1; this.entries[i] = newEntry(); } this.freeList = -1; }; dictionaryProto.add = function (key, value) { this._insert(key, value, true); }; dictionaryProto._insert = function (key, value, add) { if (!this.buckets) { this._initialize(0); } var index3, num = getHashCode(key) & 2147483647, index1 = num % this.buckets.length; for (var index2 = this.buckets[index1]; index2 >= 0; index2 = this.entries[index2].next) { if (this.entries[index2].hashCode === num && this.comparer(this.entries[index2].key, key)) { if (add) { throw new Error(duplicatekey); } this.entries[index2].value = value; return; } } if (this.freeCount > 0) { index3 = this.freeList; this.freeList = this.entries[index3].next; --this.freeCount; } else { if (this.size === this.entries.length) { this._resize(); index1 = num % this.buckets.length; } index3 = this.size; ++this.size; } this.entries[index3].hashCode = num; this.entries[index3].next = this.buckets[index1]; this.entries[index3].key = key; this.entries[index3].value = value; this.buckets[index1] = index3; }; dictionaryProto._resize = function () { var prime = getPrime(this.size * 2), numArray = new Array(prime); for (index = 0; index < numArray.length; ++index) { numArray[index] = -1; } var entryArray = new Array(prime); for (index = 0; index < this.size; ++index) { entryArray[index] = this.entries[index]; } for (var index = this.size; index < prime; ++index) { entryArray[index] = newEntry(); } for (var index1 = 0; index1 < this.size; ++index1) { var index2 = entryArray[index1].hashCode % prime; entryArray[index1].next = numArray[index2]; numArray[index2] = index1; } this.buckets = numArray; this.entries = entryArray; }; dictionaryProto.remove = function (key) { if (this.buckets) { var num = getHashCode(key) & 2147483647, index1 = num % this.buckets.length, index2 = -1; for (var index3 = this.buckets[index1]; index3 >= 0; index3 = this.entries[index3].next) { if (this.entries[index3].hashCode === num && this.comparer(this.entries[index3].key, key)) { if (index2 < 0) { this.buckets[index1] = this.entries[index3].next; } else { this.entries[index2].next = this.entries[index3].next; } this.entries[index3].hashCode = -1; this.entries[index3].next = this.freeList; this.entries[index3].key = null; this.entries[index3].value = null; this.freeList = index3; ++this.freeCount; return true; } else { index2 = index3; } } } return false; }; dictionaryProto.clear = function () { var index, len; if (this.size <= 0) { return; } for (index = 0, len = this.buckets.length; index < len; ++index) { this.buckets[index] = -1; } for (index = 0; index < this.size; ++index) { this.entries[index] = newEntry(); } this.freeList = -1; this.size = 0; }; dictionaryProto._findEntry = function (key) { if (this.buckets) { var num = getHashCode(key) & 2147483647; for (var index = this.buckets[num % this.buckets.length]; index >= 0; index = this.entries[index].next) { if (this.entries[index].hashCode === num && this.comparer(this.entries[index].key, key)) { return index; } } } return -1; }; dictionaryProto.count = function () { return this.size - this.freeCount; }; dictionaryProto.tryGetValue = function (key) { var entry = this._findEntry(key); return entry >= 0 ? this.entries[entry].value : undefined; }; dictionaryProto.getValues = function () { var index = 0, results = []; if (this.entries) { for (var index1 = 0; index1 < this.size; index1++) { if (this.entries[index1].hashCode >= 0) { results[index++] = this.entries[index1].value; } } } return results; }; dictionaryProto.get = function (key) { var entry = this._findEntry(key); if (entry >= 0) { return this.entries[entry].value; } throw new Error(noSuchkey); }; dictionaryProto.set = function (key, value) { this._insert(key, value, false); }; dictionaryProto.containskey = function (key) { return this._findEntry(key) >= 0; }; return Dictionary; }()); /** * Correlates the elements of two sequences based on overlapping durations. * * @param {Observable} right The right observable sequence to join elements for. * @param {Function} leftDurationSelector A function to select the duration (expressed as an observable sequence) of each element of the left observable sequence, used to determine overlap. * @param {Function} rightDurationSelector A function to select the duration (expressed as an observable sequence) of each element of the right observable sequence, used to determine overlap. * @param {Function} resultSelector A function invoked to compute a result element for any two overlapping elements of the left and right observable sequences. The parameters passed to the function correspond with the elements from the left and right source sequences for which overlap occurs. * @returns {Observable} An observable sequence that contains result elements computed from source elements that have an overlapping duration. */ observableProto.join = function (right, leftDurationSelector, rightDurationSelector, resultSelector) { var left = this; return new AnonymousObservable(function (observer) { var group = new CompositeDisposable(); var leftDone = false, rightDone = false; var leftId = 0, rightId = 0; var leftMap = new Dictionary(), rightMap = new Dictionary(); group.add(left.subscribe( function (value) { var id = leftId++; var md = new SingleAssignmentDisposable(); leftMap.add(id, value); group.add(md); var expire = function () { leftMap.remove(id) && leftMap.count() === 0 && leftDone && observer.onCompleted(); group.remove(md); }; var duration; try { duration = leftDurationSelector(value); } catch (e) { observer.onError(e); return; } md.setDisposable(duration.take(1).subscribe(noop, observer.onError.bind(observer), expire)); rightMap.getValues().forEach(function (v) { var result; try { result = resultSelector(value, v); } catch (exn) { observer.onError(exn); return; } observer.onNext(result); }); }, observer.onError.bind(observer), function () { leftDone = true; (rightDone || leftMap.count() === 0) && observer.onCompleted(); }) ); group.add(right.subscribe( function (value) { var id = rightId++; var md = new SingleAssignmentDisposable(); rightMap.add(id, value); group.add(md); var expire = function () { rightMap.remove(id) && rightMap.count() === 0 && rightDone && observer.onCompleted(); group.remove(md); }; var duration; try { duration = rightDurationSelector(value); } catch (e) { observer.onError(e); return; } md.setDisposable(duration.take(1).subscribe(noop, observer.onError.bind(observer), expire)); leftMap.getValues().forEach(function (v) { var result; try { result = resultSelector(v, value); } catch (exn) { observer.onError(exn); return; } observer.onNext(result); }); }, observer.onError.bind(observer), function () { rightDone = true; (leftDone || rightMap.count() === 0) && observer.onCompleted(); }) ); return group; }, left); }; /** * Correlates the elements of two sequences based on overlapping durations, and groups the results. * * @param {Observable} right The right observable sequence to join elements for. * @param {Function} leftDurationSelector A function to select the duration (expressed as an observable sequence) of each element of the left observable sequence, used to determine overlap. * @param {Function} rightDurationSelector A function to select the duration (expressed as an observable sequence) of each element of the right observable sequence, used to determine overlap. * @param {Function} resultSelector A function invoked to compute a result element for any element of the left sequence with overlapping elements from the right observable sequence. The first parameter passed to the function is an element of the left sequence. The second parameter passed to the function is an observable sequence with elements from the right sequence that overlap with the left sequence's element. * @returns {Observable} An observable sequence that contains result elements computed from source elements that have an overlapping duration. */ observableProto.groupJoin = function (right, leftDurationSelector, rightDurationSelector, resultSelector) { var left = this; return new AnonymousObservable(function (observer) { var group = new CompositeDisposable(); var r = new RefCountDisposable(group); var leftMap = new Dictionary(), rightMap = new Dictionary(); var leftId = 0, rightId = 0; function handleError(e) { return function (v) { v.onError(e); }; }; group.add(left.subscribe( function (value) { var s = new Subject(); var id = leftId++; leftMap.add(id, s); var result; try { result = resultSelector(value, addRef(s, r)); } catch (e) { leftMap.getValues().forEach(handleError(e)); observer.onError(e); return; } observer.onNext(result); rightMap.getValues().forEach(function (v) { s.onNext(v); }); var md = new SingleAssignmentDisposable(); group.add(md); var expire = function () { leftMap.remove(id) && s.onCompleted(); group.remove(md); }; var duration; try { duration = leftDurationSelector(value); } catch (e) { leftMap.getValues().forEach(handleError(e)); observer.onError(e); return; } md.setDisposable(duration.take(1).subscribe( noop, function (e) { leftMap.getValues().forEach(handleError(e)); observer.onError(e); }, expire) ); }, function (e) { leftMap.getValues().forEach(handleError(e)); observer.onError(e); }, observer.onCompleted.bind(observer)) ); group.add(right.subscribe( function (value) { var id = rightId++; rightMap.add(id, value); var md = new SingleAssignmentDisposable(); group.add(md); var expire = function () { rightMap.remove(id); group.remove(md); }; var duration; try { duration = rightDurationSelector(value); } catch (e) { leftMap.getValues().forEach(handleError(e)); observer.onError(e); return; } md.setDisposable(duration.take(1).subscribe( noop, function (e) { leftMap.getValues().forEach(handleError(e)); observer.onError(e); }, expire) ); leftMap.getValues().forEach(function (v) { v.onNext(value); }); }, function (e) { leftMap.getValues().forEach(handleError(e)); observer.onError(e); }) ); return r; }, left); }; /** * Projects each element of an observable sequence into zero or more buffers. * * @param {Mixed} bufferOpeningsOrClosingSelector Observable sequence whose elements denote the creation of new windows, or, a function invoked to define the boundaries of the produced windows (a new window is started when the previous one is closed, resulting in non-overlapping windows). * @param {Function} [bufferClosingSelector] A function invoked to define the closing of each produced window. If a closing selector function is specified for the first parameter, this parameter is ignored. * @returns {Observable} An observable sequence of windows. */ observableProto.buffer = function (bufferOpeningsOrClosingSelector, bufferClosingSelector) { return this.window.apply(this, arguments).selectMany(function (x) { return x.toArray(); }); }; /** * Projects each element of an observable sequence into zero or more windows. * * @param {Mixed} windowOpeningsOrClosingSelector Observable sequence whose elements denote the creation of new windows, or, a function invoked to define the boundaries of the produced windows (a new window is started when the previous one is closed, resulting in non-overlapping windows). * @param {Function} [windowClosingSelector] A function invoked to define the closing of each produced window. If a closing selector function is specified for the first parameter, this parameter is ignored. * @returns {Observable} An observable sequence of windows. */ observableProto.window = function (windowOpeningsOrClosingSelector, windowClosingSelector) { if (arguments.length === 1 && typeof arguments[0] !== 'function') { return observableWindowWithBoundaries.call(this, windowOpeningsOrClosingSelector); } return typeof windowOpeningsOrClosingSelector === 'function' ? observableWindowWithClosingSelector.call(this, windowOpeningsOrClosingSelector) : observableWindowWithOpenings.call(this, windowOpeningsOrClosingSelector, windowClosingSelector); }; function observableWindowWithOpenings(windowOpenings, windowClosingSelector) { return windowOpenings.groupJoin(this, windowClosingSelector, observableEmpty, function (_, win) { return win; }); } function observableWindowWithBoundaries(windowBoundaries) { var source = this; return new AnonymousObservable(function (observer) { var win = new Subject(), d = new CompositeDisposable(), r = new RefCountDisposable(d); observer.onNext(addRef(win, r)); d.add(source.subscribe(function (x) { win.onNext(x); }, function (err) { win.onError(err); observer.onError(err); }, function () { win.onCompleted(); observer.onCompleted(); })); isPromise(windowBoundaries) && (windowBoundaries = observableFromPromise(windowBoundaries)); d.add(windowBoundaries.subscribe(function (w) { win.onCompleted(); win = new Subject(); observer.onNext(addRef(win, r)); }, function (err) { win.onError(err); observer.onError(err); }, function () { win.onCompleted(); observer.onCompleted(); })); return r; }, source); } function observableWindowWithClosingSelector(windowClosingSelector) { var source = this; return new AnonymousObservable(function (observer) { var m = new SerialDisposable(), d = new CompositeDisposable(m), r = new RefCountDisposable(d), win = new Subject(); observer.onNext(addRef(win, r)); d.add(source.subscribe(function (x) { win.onNext(x); }, function (err) { win.onError(err); observer.onError(err); }, function () { win.onCompleted(); observer.onCompleted(); })); function createWindowClose () { var windowClose; try { windowClose = windowClosingSelector(); } catch (e) { observer.onError(e); return; } isPromise(windowClose) && (windowClose = observableFromPromise(windowClose)); var m1 = new SingleAssignmentDisposable(); m.setDisposable(m1); m1.setDisposable(windowClose.take(1).subscribe(noop, function (err) { win.onError(err); observer.onError(err); }, function () { win.onCompleted(); win = new Subject(); observer.onNext(addRef(win, r)); createWindowClose(); })); } createWindowClose(); return r; }, source); } /** * Returns a new observable that triggers on the second and subsequent triggerings of the input observable. * The Nth triggering of the input observable passes the arguments from the N-1th and Nth triggering as a pair. * The argument passed to the N-1th triggering is held in hidden internal state until the Nth triggering occurs. * @returns {Observable} An observable that triggers on successive pairs of observations from the input observable as an array. */ observableProto.pairwise = function () { var source = this; return new AnonymousObservable(function (observer) { var previous, hasPrevious = false; return source.subscribe( function (x) { if (hasPrevious) { observer.onNext([previous, x]); } else { hasPrevious = true; } previous = x; }, observer.onError.bind(observer), observer.onCompleted.bind(observer)); }, source); }; /** * Returns two observables which partition the observations of the source by the given function. * The first will trigger observations for those values for which the predicate returns true. * The second will trigger observations for those values where the predicate returns false. * The predicate is executed once for each subscribed observer. * Both also propagate all error observations arising from the source and each completes * when the source completes. * @param {Function} predicate * The function to determine which output Observable will trigger a particular observation. * @returns {Array} * An array of observables. The first triggers when the predicate returns true, * and the second triggers when the predicate returns false. */ observableProto.partition = function(predicate, thisArg) { return [ this.filter(predicate, thisArg), this.filter(function (x, i, o) { return !predicate.call(thisArg, x, i, o); }) ]; }; function enumerableWhile(condition, source) { return new Enumerable(function () { return new Enumerator(function () { return condition() ? { done: false, value: source } : { done: true, value: undefined }; }); }); } /** * Returns an observable sequence that is the result of invoking the selector on the source sequence, without sharing subscriptions. * This operator allows for a fluent style of writing queries that use the same sequence multiple times. * * @param {Function} selector Selector function which can use the source sequence as many times as needed, without sharing subscriptions to the source sequence. * @returns {Observable} An observable sequence that contains the elements of a sequence produced by multicasting the source sequence within a selector function. */ observableProto.letBind = observableProto['let'] = function (func) { return func(this); }; /** * Determines whether an observable collection contains values. There is an alias for this method called 'ifThen' for browsers <IE9 * * @example * 1 - res = Rx.Observable.if(condition, obs1); * 2 - res = Rx.Observable.if(condition, obs1, obs2); * 3 - res = Rx.Observable.if(condition, obs1, scheduler); * @param {Function} condition The condition which determines if the thenSource or elseSource will be run. * @param {Observable} thenSource The observable sequence or Promise that will be run if the condition function returns true. * @param {Observable} [elseSource] The observable sequence or Promise that will be run if the condition function returns false. If this is not provided, it defaults to Rx.Observabe.Empty with the specified scheduler. * @returns {Observable} An observable sequence which is either the thenSource or elseSource. */ Observable['if'] = Observable.ifThen = function (condition, thenSource, elseSourceOrScheduler) { return observableDefer(function () { elseSourceOrScheduler || (elseSourceOrScheduler = observableEmpty()); isPromise(thenSource) && (thenSource = observableFromPromise(thenSource)); isPromise(elseSourceOrScheduler) && (elseSourceOrScheduler = observableFromPromise(elseSourceOrScheduler)); // Assume a scheduler for empty only typeof elseSourceOrScheduler.now === 'function' && (elseSourceOrScheduler = observableEmpty(elseSourceOrScheduler)); return condition() ? thenSource : elseSourceOrScheduler; }); }; /** * Concatenates the observable sequences obtained by running the specified result selector for each element in source. * There is an alias for this method called 'forIn' for browsers <IE9 * @param {Array} sources An array of values to turn into an observable sequence. * @param {Function} resultSelector A function to apply to each item in the sources array to turn it into an observable sequence. * @returns {Observable} An observable sequence from the concatenated observable sequences. */ Observable['for'] = Observable.forIn = function (sources, resultSelector, thisArg) { return enumerableOf(sources, resultSelector, thisArg).concat(); }; /** * Repeats source as long as condition holds emulating a while loop. * There is an alias for this method called 'whileDo' for browsers <IE9 * * @param {Function} condition The condition which determines if the source will be repeated. * @param {Observable} source The observable sequence that will be run if the condition function returns true. * @returns {Observable} An observable sequence which is repeated as long as the condition holds. */ var observableWhileDo = Observable['while'] = Observable.whileDo = function (condition, source) { isPromise(source) && (source = observableFromPromise(source)); return enumerableWhile(condition, source).concat(); }; /** * Repeats source as long as condition holds emulating a do while loop. * * @param {Function} condition The condition which determines if the source will be repeated. * @param {Observable} source The observable sequence that will be run if the condition function returns true. * @returns {Observable} An observable sequence which is repeated as long as the condition holds. */ observableProto.doWhile = function (condition) { return observableConcat([this, observableWhileDo(condition, this)]); }; /** * Uses selector to determine which source in sources to use. * There is an alias 'switchCase' for browsers <IE9. * * @example * 1 - res = Rx.Observable.case(selector, { '1': obs1, '2': obs2 }); * 1 - res = Rx.Observable.case(selector, { '1': obs1, '2': obs2 }, obs0); * 1 - res = Rx.Observable.case(selector, { '1': obs1, '2': obs2 }, scheduler); * * @param {Function} selector The function which extracts the value for to test in a case statement. * @param {Array} sources A object which has keys which correspond to the case statement labels. * @param {Observable} [elseSource] The observable sequence or Promise that will be run if the sources are not matched. If this is not provided, it defaults to Rx.Observabe.empty with the specified scheduler. * * @returns {Observable} An observable sequence which is determined by a case statement. */ Observable['case'] = Observable.switchCase = function (selector, sources, defaultSourceOrScheduler) { return observableDefer(function () { isPromise(defaultSourceOrScheduler) && (defaultSourceOrScheduler = observableFromPromise(defaultSourceOrScheduler)); defaultSourceOrScheduler || (defaultSourceOrScheduler = observableEmpty()); typeof defaultSourceOrScheduler.now === 'function' && (defaultSourceOrScheduler = observableEmpty(defaultSourceOrScheduler)); var result = sources[selector()]; isPromise(result) && (result = observableFromPromise(result)); return result || defaultSourceOrScheduler; }); }; /** * Expands an observable sequence by recursively invoking selector. * * @param {Function} selector Selector function to invoke for each produced element, resulting in another sequence to which the selector will be invoked recursively again. * @param {Scheduler} [scheduler] Scheduler on which to perform the expansion. If not provided, this defaults to the current thread scheduler. * @returns {Observable} An observable sequence containing all the elements produced by the recursive expansion. */ observableProto.expand = function (selector, scheduler) { isScheduler(scheduler) || (scheduler = immediateScheduler); var source = this; return new AnonymousObservable(function (observer) { var q = [], m = new SerialDisposable(), d = new CompositeDisposable(m), activeCount = 0, isAcquired = false; var ensureActive = function () { var isOwner = false; if (q.length > 0) { isOwner = !isAcquired; isAcquired = true; } if (isOwner) { m.setDisposable(scheduler.scheduleRecursive(function (self) { var work; if (q.length > 0) { work = q.shift(); } else { isAcquired = false; return; } var m1 = new SingleAssignmentDisposable(); d.add(m1); m1.setDisposable(work.subscribe(function (x) { observer.onNext(x); var result = null; try { result = selector(x); } catch (e) { observer.onError(e); } q.push(result); activeCount++; ensureActive(); }, observer.onError.bind(observer), function () { d.remove(m1); activeCount--; if (activeCount === 0) { observer.onCompleted(); } })); self(); })); } }; q.push(source); activeCount++; ensureActive(); return d; }, this); }; /** * Runs all observable sequences in parallel and collect their last elements. * * @example * 1 - res = Rx.Observable.forkJoin([obs1, obs2]); * 1 - res = Rx.Observable.forkJoin(obs1, obs2, ...); * @returns {Observable} An observable sequence with an array collecting the last elements of all the input sequences. */ Observable.forkJoin = function () { var allSources = []; if (Array.isArray(arguments[0])) { allSources = arguments[0]; } else { for(var i = 0, len = arguments.length; i < len; i++) { allSources.push(arguments[i]); } } return new AnonymousObservable(function (subscriber) { var count = allSources.length; if (count === 0) { subscriber.onCompleted(); return disposableEmpty; } var group = new CompositeDisposable(), finished = false, hasResults = new Array(count), hasCompleted = new Array(count), results = new Array(count); for (var idx = 0; idx < count; idx++) { (function (i) { var source = allSources[i]; isPromise(source) && (source = observableFromPromise(source)); group.add( source.subscribe( function (value) { if (!finished) { hasResults[i] = true; results[i] = value; } }, function (e) { finished = true; subscriber.onError(e); group.dispose(); }, function () { if (!finished) { if (!hasResults[i]) { subscriber.onCompleted(); return; } hasCompleted[i] = true; for (var ix = 0; ix < count; ix++) { if (!hasCompleted[ix]) { return; } } finished = true; subscriber.onNext(results); subscriber.onCompleted(); } })); })(idx); } return group; }); }; /** * Runs two observable sequences in parallel and combines their last elemenets. * * @param {Observable} second Second observable sequence. * @param {Function} resultSelector Result selector function to invoke with the last elements of both sequences. * @returns {Observable} An observable sequence with the result of calling the selector function with the last elements of both input sequences. */ observableProto.forkJoin = function (second, resultSelector) { var first = this; return new AnonymousObservable(function (observer) { var leftStopped = false, rightStopped = false, hasLeft = false, hasRight = false, lastLeft, lastRight, leftSubscription = new SingleAssignmentDisposable(), rightSubscription = new SingleAssignmentDisposable(); isPromise(second) && (second = observableFromPromise(second)); leftSubscription.setDisposable( first.subscribe(function (left) { hasLeft = true; lastLeft = left; }, function (err) { rightSubscription.dispose(); observer.onError(err); }, function () { leftStopped = true; if (rightStopped) { if (!hasLeft) { observer.onCompleted(); } else if (!hasRight) { observer.onCompleted(); } else { var result; try { result = resultSelector(lastLeft, lastRight); } catch (e) { observer.onError(e); return; } observer.onNext(result); observer.onCompleted(); } } }) ); rightSubscription.setDisposable( second.subscribe(function (right) { hasRight = true; lastRight = right; }, function (err) { leftSubscription.dispose(); observer.onError(err); }, function () { rightStopped = true; if (leftStopped) { if (!hasLeft) { observer.onCompleted(); } else if (!hasRight) { observer.onCompleted(); } else { var result; try { result = resultSelector(lastLeft, lastRight); } catch (e) { observer.onError(e); return; } observer.onNext(result); observer.onCompleted(); } } }) ); return new CompositeDisposable(leftSubscription, rightSubscription); }, first); }; /** * Comonadic bind operator. * @param {Function} selector A transform function to apply to each element. * @param {Object} scheduler Scheduler used to execute the operation. If not specified, defaults to the ImmediateScheduler. * @returns {Observable} An observable sequence which results from the comonadic bind operation. */ observableProto.manySelect = function (selector, scheduler) { isScheduler(scheduler) || (scheduler = immediateScheduler); var source = this; return observableDefer(function () { var chain; return source .map(function (x) { var curr = new ChainObservable(x); chain && chain.onNext(x); chain = curr; return curr; }) .tap( noop, function (e) { chain && chain.onError(e); }, function () { chain && chain.onCompleted(); } ) .observeOn(scheduler) .map(selector); }, source); }; var ChainObservable = (function (__super__) { function subscribe (observer) { var self = this, g = new CompositeDisposable(); g.add(currentThreadScheduler.schedule(function () { observer.onNext(self.head); g.add(self.tail.mergeAll().subscribe(observer)); })); return g; } inherits(ChainObservable, __super__); function ChainObservable(head) { __super__.call(this, subscribe); this.head = head; this.tail = new AsyncSubject(); } addProperties(ChainObservable.prototype, Observer, { onCompleted: function () { this.onNext(Observable.empty()); }, onError: function (e) { this.onNext(Observable.throwError(e)); }, onNext: function (v) { this.tail.onNext(v); this.tail.onCompleted(); } }); return ChainObservable; }(Observable)); /** @private */ var Map = root.Map || (function () { function Map() { this._keys = []; this._values = []; } Map.prototype.get = function (key) { var i = this._keys.indexOf(key); return i !== -1 ? this._values[i] : undefined; }; Map.prototype.set = function (key, value) { var i = this._keys.indexOf(key); i !== -1 && (this._values[i] = value); this._values[this._keys.push(key) - 1] = value; }; Map.prototype.forEach = function (callback, thisArg) { for (var i = 0, len = this._keys.length; i < len; i++) { callback.call(thisArg, this._values[i], this._keys[i]); } }; return Map; }()); /** * @constructor * Represents a join pattern over observable sequences. */ function Pattern(patterns) { this.patterns = patterns; } /** * Creates a pattern that matches the current plan matches and when the specified observable sequences has an available value. * @param other Observable sequence to match in addition to the current pattern. * @return {Pattern} Pattern object that matches when all observable sequences in the pattern have an available value. */ Pattern.prototype.and = function (other) { return new Pattern(this.patterns.concat(other)); }; /** * Matches when all observable sequences in the pattern (specified using a chain of and operators) have an available value and projects the values. * @param {Function} selector Selector that will be invoked with available values from the source sequences, in the same order of the sequences in the pattern. * @return {Plan} Plan that produces the projected values, to be fed (with other plans) to the when operator. */ Pattern.prototype.thenDo = function (selector) { return new Plan(this, selector); }; function Plan(expression, selector) { this.expression = expression; this.selector = selector; } Plan.prototype.activate = function (externalSubscriptions, observer, deactivate) { var self = this; var joinObservers = []; for (var i = 0, len = this.expression.patterns.length; i < len; i++) { joinObservers.push(planCreateObserver(externalSubscriptions, this.expression.patterns[i], observer.onError.bind(observer))); } var activePlan = new ActivePlan(joinObservers, function () { var result; try { result = self.selector.apply(self, arguments); } catch (e) { observer.onError(e); return; } observer.onNext(result); }, function () { for (var j = 0, jlen = joinObservers.length; j < jlen; j++) { joinObservers[j].removeActivePlan(activePlan); } deactivate(activePlan); }); for (i = 0, len = joinObservers.length; i < len; i++) { joinObservers[i].addActivePlan(activePlan); } return activePlan; }; function planCreateObserver(externalSubscriptions, observable, onError) { var entry = externalSubscriptions.get(observable); if (!entry) { var observer = new JoinObserver(observable, onError); externalSubscriptions.set(observable, observer); return observer; } return entry; } function ActivePlan(joinObserverArray, onNext, onCompleted) { this.joinObserverArray = joinObserverArray; this.onNext = onNext; this.onCompleted = onCompleted; this.joinObservers = new Map(); for (var i = 0, len = this.joinObserverArray.length; i < len; i++) { var joinObserver = this.joinObserverArray[i]; this.joinObservers.set(joinObserver, joinObserver); } } ActivePlan.prototype.dequeue = function () { this.joinObservers.forEach(function (v) { v.queue.shift(); }); }; ActivePlan.prototype.match = function () { var i, len, hasValues = true; for (i = 0, len = this.joinObserverArray.length; i < len; i++) { if (this.joinObserverArray[i].queue.length === 0) { hasValues = false; break; } } if (hasValues) { var firstValues = [], isCompleted = false; for (i = 0, len = this.joinObserverArray.length; i < len; i++) { firstValues.push(this.joinObserverArray[i].queue[0]); this.joinObserverArray[i].queue[0].kind === 'C' && (isCompleted = true); } if (isCompleted) { this.onCompleted(); } else { this.dequeue(); var values = []; for (i = 0, len = firstValues.length; i < firstValues.length; i++) { values.push(firstValues[i].value); } this.onNext.apply(this, values); } } }; var JoinObserver = (function (__super__) { inherits(JoinObserver, __super__); function JoinObserver(source, onError) { __super__.call(this); this.source = source; this.onError = onError; this.queue = []; this.activePlans = []; this.subscription = new SingleAssignmentDisposable(); this.isDisposed = false; } var JoinObserverPrototype = JoinObserver.prototype; JoinObserverPrototype.next = function (notification) { if (!this.isDisposed) { if (notification.kind === 'E') { return this.onError(notification.exception); } this.queue.push(notification); var activePlans = this.activePlans.slice(0); for (var i = 0, len = activePlans.length; i < len; i++) { activePlans[i].match(); } } }; JoinObserverPrototype.error = noop; JoinObserverPrototype.completed = noop; JoinObserverPrototype.addActivePlan = function (activePlan) { this.activePlans.push(activePlan); }; JoinObserverPrototype.subscribe = function () { this.subscription.setDisposable(this.source.materialize().subscribe(this)); }; JoinObserverPrototype.removeActivePlan = function (activePlan) { this.activePlans.splice(this.activePlans.indexOf(activePlan), 1); this.activePlans.length === 0 && this.dispose(); }; JoinObserverPrototype.dispose = function () { __super__.prototype.dispose.call(this); if (!this.isDisposed) { this.isDisposed = true; this.subscription.dispose(); } }; return JoinObserver; } (AbstractObserver)); /** * Creates a pattern that matches when both observable sequences have an available value. * * @param right Observable sequence to match with the current sequence. * @return {Pattern} Pattern object that matches when both observable sequences have an available value. */ observableProto.and = function (right) { return new Pattern([this, right]); }; /** * Matches when the observable sequence has an available value and projects the value. * * @param {Function} selector Selector that will be invoked for values in the source sequence. * @returns {Plan} Plan that produces the projected values, to be fed (with other plans) to the when operator. */ observableProto.thenDo = function (selector) { return new Pattern([this]).thenDo(selector); }; /** * Joins together the results from several patterns. * * @param plans A series of plans (specified as an Array of as a series of arguments) created by use of the Then operator on patterns. * @returns {Observable} Observable sequence with the results form matching several patterns. */ Observable.when = function () { var len = arguments.length, plans; if (Array.isArray(arguments[0])) { plans = arguments[0]; } else { plans = new Array(len); for(var i = 0; i < len; i++) { plans[i] = arguments[i]; } } return new AnonymousObservable(function (o) { var activePlans = [], externalSubscriptions = new Map(); var outObserver = observerCreate( function (x) { o.onNext(x); }, function (err) { externalSubscriptions.forEach(function (v) { v.onError(err); }); o.onError(err); }, function (x) { o.onCompleted(); } ); try { for (var i = 0, len = plans.length; i < len; i++) { activePlans.push(plans[i].activate(externalSubscriptions, outObserver, function (activePlan) { var idx = activePlans.indexOf(activePlan); activePlans.splice(idx, 1); activePlans.length === 0 && o.onCompleted(); })); } } catch (e) { observableThrow(e).subscribe(o); } var group = new CompositeDisposable(); externalSubscriptions.forEach(function (joinObserver) { joinObserver.subscribe(); group.add(joinObserver); }); return group; }); }; function observableTimerDate(dueTime, scheduler) { return new AnonymousObservable(function (observer) { return scheduler.scheduleWithAbsolute(dueTime, function () { observer.onNext(0); observer.onCompleted(); }); }); } function observableTimerDateAndPeriod(dueTime, period, scheduler) { return new AnonymousObservable(function (observer) { var d = dueTime, p = normalizeTime(period); return scheduler.scheduleRecursiveWithAbsoluteAndState(0, d, function (count, self) { if (p > 0) { var now = scheduler.now(); d = d + p; d <= now && (d = now + p); } observer.onNext(count); self(count + 1, d); }); }); } function observableTimerTimeSpan(dueTime, scheduler) { return new AnonymousObservable(function (observer) { return scheduler.scheduleWithRelative(normalizeTime(dueTime), function () { observer.onNext(0); observer.onCompleted(); }); }); } function observableTimerTimeSpanAndPeriod(dueTime, period, scheduler) { return dueTime === period ? new AnonymousObservable(function (observer) { return scheduler.schedulePeriodicWithState(0, period, function (count) { observer.onNext(count); return count + 1; }); }) : observableDefer(function () { return observableTimerDateAndPeriod(scheduler.now() + dueTime, period, scheduler); }); } /** * Returns an observable sequence that produces a value after each period. * * @example * 1 - res = Rx.Observable.interval(1000); * 2 - res = Rx.Observable.interval(1000, Rx.Scheduler.timeout); * * @param {Number} period Period for producing the values in the resulting sequence (specified as an integer denoting milliseconds). * @param {Scheduler} [scheduler] Scheduler to run the timer on. If not specified, Rx.Scheduler.timeout is used. * @returns {Observable} An observable sequence that produces a value after each period. */ var observableinterval = Observable.interval = function (period, scheduler) { return observableTimerTimeSpanAndPeriod(period, period, isScheduler(scheduler) ? scheduler : timeoutScheduler); }; /** * Returns an observable sequence that produces a value after dueTime has elapsed and then after each period. * @param {Number} dueTime Absolute (specified as a Date object) or relative time (specified as an integer denoting milliseconds) at which to produce the first value. * @param {Mixed} [periodOrScheduler] Period to produce subsequent values (specified as an integer denoting milliseconds), or the scheduler to run the timer on. If not specified, the resulting timer is not recurring. * @param {Scheduler} [scheduler] Scheduler to run the timer on. If not specified, the timeout scheduler is used. * @returns {Observable} An observable sequence that produces a value after due time has elapsed and then each period. */ var observableTimer = Observable.timer = function (dueTime, periodOrScheduler, scheduler) { var period; isScheduler(scheduler) || (scheduler = timeoutScheduler); if (periodOrScheduler !== undefined && typeof periodOrScheduler === 'number') { period = periodOrScheduler; } else if (isScheduler(periodOrScheduler)) { scheduler = periodOrScheduler; } if (dueTime instanceof Date && period === undefined) { return observableTimerDate(dueTime.getTime(), scheduler); } if (dueTime instanceof Date && period !== undefined) { period = periodOrScheduler; return observableTimerDateAndPeriod(dueTime.getTime(), period, scheduler); } return period === undefined ? observableTimerTimeSpan(dueTime, scheduler) : observableTimerTimeSpanAndPeriod(dueTime, period, scheduler); }; function observableDelayTimeSpan(source, dueTime, scheduler) { return new AnonymousObservable(function (observer) { var active = false, cancelable = new SerialDisposable(), exception = null, q = [], running = false, subscription; subscription = source.materialize().timestamp(scheduler).subscribe(function (notification) { var d, shouldRun; if (notification.value.kind === 'E') { q = []; q.push(notification); exception = notification.value.exception; shouldRun = !running; } else { q.push({ value: notification.value, timestamp: notification.timestamp + dueTime }); shouldRun = !active; active = true; } if (shouldRun) { if (exception !== null) { observer.onError(exception); } else { d = new SingleAssignmentDisposable(); cancelable.setDisposable(d); d.setDisposable(scheduler.scheduleRecursiveWithRelative(dueTime, function (self) { var e, recurseDueTime, result, shouldRecurse; if (exception !== null) { return; } running = true; do { result = null; if (q.length > 0 && q[0].timestamp - scheduler.now() <= 0) { result = q.shift().value; } if (result !== null) { result.accept(observer); } } while (result !== null); shouldRecurse = false; recurseDueTime = 0; if (q.length > 0) { shouldRecurse = true; recurseDueTime = Math.max(0, q[0].timestamp - scheduler.now()); } else { active = false; } e = exception; running = false; if (e !== null) { observer.onError(e); } else if (shouldRecurse) { self(recurseDueTime); } })); } } }); return new CompositeDisposable(subscription, cancelable); }, source); } function observableDelayDate(source, dueTime, scheduler) { return observableDefer(function () { return observableDelayTimeSpan(source, dueTime - scheduler.now(), scheduler); }); } /** * Time shifts the observable sequence by dueTime. The relative time intervals between the values are preserved. * * @example * 1 - res = Rx.Observable.delay(new Date()); * 2 - res = Rx.Observable.delay(new Date(), Rx.Scheduler.timeout); * * 3 - res = Rx.Observable.delay(5000); * 4 - res = Rx.Observable.delay(5000, 1000, Rx.Scheduler.timeout); * @memberOf Observable# * @param {Number} dueTime Absolute (specified as a Date object) or relative time (specified as an integer denoting milliseconds) by which to shift the observable sequence. * @param {Scheduler} [scheduler] Scheduler to run the delay timers on. If not specified, the timeout scheduler is used. * @returns {Observable} Time-shifted sequence. */ observableProto.delay = function (dueTime, scheduler) { isScheduler(scheduler) || (scheduler = timeoutScheduler); return dueTime instanceof Date ? observableDelayDate(this, dueTime.getTime(), scheduler) : observableDelayTimeSpan(this, dueTime, scheduler); }; /** * Ignores values from an observable sequence which are followed by another value before dueTime. * @param {Number} dueTime Duration of the debounce period for each value (specified as an integer denoting milliseconds). * @param {Scheduler} [scheduler] Scheduler to run the debounce timers on. If not specified, the timeout scheduler is used. * @returns {Observable} The debounced sequence. */ observableProto.debounce = observableProto.throttleWithTimeout = function (dueTime, scheduler) { isScheduler(scheduler) || (scheduler = timeoutScheduler); var source = this; return new AnonymousObservable(function (observer) { var cancelable = new SerialDisposable(), hasvalue = false, value, id = 0; var subscription = source.subscribe( function (x) { hasvalue = true; value = x; id++; var currentId = id, d = new SingleAssignmentDisposable(); cancelable.setDisposable(d); d.setDisposable(scheduler.scheduleWithRelative(dueTime, function () { hasvalue && id === currentId && observer.onNext(value); hasvalue = false; })); }, function (e) { cancelable.dispose(); observer.onError(e); hasvalue = false; id++; }, function () { cancelable.dispose(); hasvalue && observer.onNext(value); observer.onCompleted(); hasvalue = false; id++; }); return new CompositeDisposable(subscription, cancelable); }, this); }; /** * @deprecated use #debounce or #throttleWithTimeout instead. */ observableProto.throttle = function(dueTime, scheduler) { //deprecate('throttle', 'debounce or throttleWithTimeout'); return this.debounce(dueTime, scheduler); }; /** * Projects each element of an observable sequence into zero or more windows which are produced based on timing information. * @param {Number} timeSpan Length of each window (specified as an integer denoting milliseconds). * @param {Mixed} [timeShiftOrScheduler] Interval between creation of consecutive windows (specified as an integer denoting milliseconds), or an optional scheduler parameter. If not specified, the time shift corresponds to the timeSpan parameter, resulting in non-overlapping adjacent windows. * @param {Scheduler} [scheduler] Scheduler to run windowing timers on. If not specified, the timeout scheduler is used. * @returns {Observable} An observable sequence of windows. */ observableProto.windowWithTime = function (timeSpan, timeShiftOrScheduler, scheduler) { var source = this, timeShift; timeShiftOrScheduler == null && (timeShift = timeSpan); isScheduler(scheduler) || (scheduler = timeoutScheduler); if (typeof timeShiftOrScheduler === 'number') { timeShift = timeShiftOrScheduler; } else if (isScheduler(timeShiftOrScheduler)) { timeShift = timeSpan; scheduler = timeShiftOrScheduler; } return new AnonymousObservable(function (observer) { var groupDisposable, nextShift = timeShift, nextSpan = timeSpan, q = [], refCountDisposable, timerD = new SerialDisposable(), totalTime = 0; groupDisposable = new CompositeDisposable(timerD), refCountDisposable = new RefCountDisposable(groupDisposable); function createTimer () { var m = new SingleAssignmentDisposable(), isSpan = false, isShift = false; timerD.setDisposable(m); if (nextSpan === nextShift) { isSpan = true; isShift = true; } else if (nextSpan < nextShift) { isSpan = true; } else { isShift = true; } var newTotalTime = isSpan ? nextSpan : nextShift, ts = newTotalTime - totalTime; totalTime = newTotalTime; if (isSpan) { nextSpan += timeShift; } if (isShift) { nextShift += timeShift; } m.setDisposable(scheduler.scheduleWithRelative(ts, function () { if (isShift) { var s = new Subject(); q.push(s); observer.onNext(addRef(s, refCountDisposable)); } isSpan && q.shift().onCompleted(); createTimer(); })); }; q.push(new Subject()); observer.onNext(addRef(q[0], refCountDisposable)); createTimer(); groupDisposable.add(source.subscribe( function (x) { for (var i = 0, len = q.length; i < len; i++) { q[i].onNext(x); } }, function (e) { for (var i = 0, len = q.length; i < len; i++) { q[i].onError(e); } observer.onError(e); }, function () { for (var i = 0, len = q.length; i < len; i++) { q[i].onCompleted(); } observer.onCompleted(); } )); return refCountDisposable; }, source); }; /** * Projects each element of an observable sequence into a window that is completed when either it's full or a given amount of time has elapsed. * @param {Number} timeSpan Maximum time length of a window. * @param {Number} count Maximum element count of a window. * @param {Scheduler} [scheduler] Scheduler to run windowing timers on. If not specified, the timeout scheduler is used. * @returns {Observable} An observable sequence of windows. */ observableProto.windowWithTimeOrCount = function (timeSpan, count, scheduler) { var source = this; isScheduler(scheduler) || (scheduler = timeoutScheduler); return new AnonymousObservable(function (observer) { var timerD = new SerialDisposable(), groupDisposable = new CompositeDisposable(timerD), refCountDisposable = new RefCountDisposable(groupDisposable), n = 0, windowId = 0, s = new Subject(); function createTimer(id) { var m = new SingleAssignmentDisposable(); timerD.setDisposable(m); m.setDisposable(scheduler.scheduleWithRelative(timeSpan, function () { if (id !== windowId) { return; } n = 0; var newId = ++windowId; s.onCompleted(); s = new Subject(); observer.onNext(addRef(s, refCountDisposable)); createTimer(newId); })); } observer.onNext(addRef(s, refCountDisposable)); createTimer(0); groupDisposable.add(source.subscribe( function (x) { var newId = 0, newWindow = false; s.onNext(x); if (++n === count) { newWindow = true; n = 0; newId = ++windowId; s.onCompleted(); s = new Subject(); observer.onNext(addRef(s, refCountDisposable)); } newWindow && createTimer(newId); }, function (e) { s.onError(e); observer.onError(e); }, function () { s.onCompleted(); observer.onCompleted(); } )); return refCountDisposable; }, source); }; /** * Projects each element of an observable sequence into zero or more buffers which are produced based on timing information. * * @example * 1 - res = xs.bufferWithTime(1000, scheduler); // non-overlapping segments of 1 second * 2 - res = xs.bufferWithTime(1000, 500, scheduler; // segments of 1 second with time shift 0.5 seconds * * @param {Number} timeSpan Length of each buffer (specified as an integer denoting milliseconds). * @param {Mixed} [timeShiftOrScheduler] Interval between creation of consecutive buffers (specified as an integer denoting milliseconds), or an optional scheduler parameter. If not specified, the time shift corresponds to the timeSpan parameter, resulting in non-overlapping adjacent buffers. * @param {Scheduler} [scheduler] Scheduler to run buffer timers on. If not specified, the timeout scheduler is used. * @returns {Observable} An observable sequence of buffers. */ observableProto.bufferWithTime = function (timeSpan, timeShiftOrScheduler, scheduler) { return this.windowWithTime.apply(this, arguments).selectMany(function (x) { return x.toArray(); }); }; /** * Projects each element of an observable sequence into a buffer that is completed when either it's full or a given amount of time has elapsed. * * @example * 1 - res = source.bufferWithTimeOrCount(5000, 50); // 5s or 50 items in an array * 2 - res = source.bufferWithTimeOrCount(5000, 50, scheduler); // 5s or 50 items in an array * * @param {Number} timeSpan Maximum time length of a buffer. * @param {Number} count Maximum element count of a buffer. * @param {Scheduler} [scheduler] Scheduler to run bufferin timers on. If not specified, the timeout scheduler is used. * @returns {Observable} An observable sequence of buffers. */ observableProto.bufferWithTimeOrCount = function (timeSpan, count, scheduler) { return this.windowWithTimeOrCount(timeSpan, count, scheduler).selectMany(function (x) { return x.toArray(); }); }; /** * Records the time interval between consecutive values in an observable sequence. * * @example * 1 - res = source.timeInterval(); * 2 - res = source.timeInterval(Rx.Scheduler.timeout); * * @param [scheduler] Scheduler used to compute time intervals. If not specified, the timeout scheduler is used. * @returns {Observable} An observable sequence with time interval information on values. */ observableProto.timeInterval = function (scheduler) { var source = this; isScheduler(scheduler) || (scheduler = timeoutScheduler); return observableDefer(function () { var last = scheduler.now(); return source.map(function (x) { var now = scheduler.now(), span = now - last; last = now; return { value: x, interval: span }; }); }); }; /** * Records the timestamp for each value in an observable sequence. * * @example * 1 - res = source.timestamp(); // produces { value: x, timestamp: ts } * 2 - res = source.timestamp(Rx.Scheduler.timeout); * * @param {Scheduler} [scheduler] Scheduler used to compute timestamps. If not specified, the timeout scheduler is used. * @returns {Observable} An observable sequence with timestamp information on values. */ observableProto.timestamp = function (scheduler) { isScheduler(scheduler) || (scheduler = timeoutScheduler); return this.map(function (x) { return { value: x, timestamp: scheduler.now() }; }); }; function sampleObservable(source, sampler) { return new AnonymousObservable(function (observer) { var atEnd, value, hasValue; function sampleSubscribe() { if (hasValue) { hasValue = false; observer.onNext(value); } atEnd && observer.onCompleted(); } return new CompositeDisposable( source.subscribe(function (newValue) { hasValue = true; value = newValue; }, observer.onError.bind(observer), function () { atEnd = true; }), sampler.subscribe(sampleSubscribe, observer.onError.bind(observer), sampleSubscribe) ); }, source); } /** * Samples the observable sequence at each interval. * * @example * 1 - res = source.sample(sampleObservable); // Sampler tick sequence * 2 - res = source.sample(5000); // 5 seconds * 2 - res = source.sample(5000, Rx.Scheduler.timeout); // 5 seconds * * @param {Mixed} intervalOrSampler Interval at which to sample (specified as an integer denoting milliseconds) or Sampler Observable. * @param {Scheduler} [scheduler] Scheduler to run the sampling timer on. If not specified, the timeout scheduler is used. * @returns {Observable} Sampled observable sequence. */ observableProto.sample = observableProto.throttleLatest = function (intervalOrSampler, scheduler) { isScheduler(scheduler) || (scheduler = timeoutScheduler); return typeof intervalOrSampler === 'number' ? sampleObservable(this, observableinterval(intervalOrSampler, scheduler)) : sampleObservable(this, intervalOrSampler); }; /** * Returns the source observable sequence or the other observable sequence if dueTime elapses. * @param {Number} dueTime Absolute (specified as a Date object) or relative time (specified as an integer denoting milliseconds) when a timeout occurs. * @param {Observable} [other] Sequence to return in case of a timeout. If not specified, a timeout error throwing sequence will be used. * @param {Scheduler} [scheduler] Scheduler to run the timeout timers on. If not specified, the timeout scheduler is used. * @returns {Observable} The source sequence switching to the other sequence in case of a timeout. */ observableProto.timeout = function (dueTime, other, scheduler) { (other == null || typeof other === 'string') && (other = observableThrow(new Error(other || 'Timeout'))); isScheduler(scheduler) || (scheduler = timeoutScheduler); var source = this, schedulerMethod = dueTime instanceof Date ? 'scheduleWithAbsolute' : 'scheduleWithRelative'; return new AnonymousObservable(function (observer) { var id = 0, original = new SingleAssignmentDisposable(), subscription = new SerialDisposable(), switched = false, timer = new SerialDisposable(); subscription.setDisposable(original); function createTimer() { var myId = id; timer.setDisposable(scheduler[schedulerMethod](dueTime, function () { if (id === myId) { isPromise(other) && (other = observableFromPromise(other)); subscription.setDisposable(other.subscribe(observer)); } })); } createTimer(); original.setDisposable(source.subscribe(function (x) { if (!switched) { id++; observer.onNext(x); createTimer(); } }, function (e) { if (!switched) { id++; observer.onError(e); } }, function () { if (!switched) { id++; observer.onCompleted(); } })); return new CompositeDisposable(subscription, timer); }, source); }; /** * Generates an observable sequence by iterating a state from an initial state until the condition fails. * * @example * res = source.generateWithAbsoluteTime(0, * function (x) { return return true; }, * function (x) { return x + 1; }, * function (x) { return x; }, * function (x) { return new Date(); } * }); * * @param {Mixed} initialState Initial state. * @param {Function} condition Condition to terminate generation (upon returning false). * @param {Function} iterate Iteration step function. * @param {Function} resultSelector Selector function for results produced in the sequence. * @param {Function} timeSelector Time selector function to control the speed of values being produced each iteration, returning Date values. * @param {Scheduler} [scheduler] Scheduler on which to run the generator loop. If not specified, the timeout scheduler is used. * @returns {Observable} The generated sequence. */ Observable.generateWithAbsoluteTime = function (initialState, condition, iterate, resultSelector, timeSelector, scheduler) { isScheduler(scheduler) || (scheduler = timeoutScheduler); return new AnonymousObservable(function (observer) { var first = true, hasResult = false, result, state = initialState, time; return scheduler.scheduleRecursiveWithAbsolute(scheduler.now(), function (self) { hasResult && observer.onNext(result); try { if (first) { first = false; } else { state = iterate(state); } hasResult = condition(state); if (hasResult) { result = resultSelector(state); time = timeSelector(state); } } catch (e) { observer.onError(e); return; } if (hasResult) { self(time); } else { observer.onCompleted(); } }); }); }; /** * Generates an observable sequence by iterating a state from an initial state until the condition fails. * * @example * res = source.generateWithRelativeTime(0, * function (x) { return return true; }, * function (x) { return x + 1; }, * function (x) { return x; }, * function (x) { return 500; } * ); * * @param {Mixed} initialState Initial state. * @param {Function} condition Condition to terminate generation (upon returning false). * @param {Function} iterate Iteration step function. * @param {Function} resultSelector Selector function for results produced in the sequence. * @param {Function} timeSelector Time selector function to control the speed of values being produced each iteration, returning integer values denoting milliseconds. * @param {Scheduler} [scheduler] Scheduler on which to run the generator loop. If not specified, the timeout scheduler is used. * @returns {Observable} The generated sequence. */ Observable.generateWithRelativeTime = function (initialState, condition, iterate, resultSelector, timeSelector, scheduler) { isScheduler(scheduler) || (scheduler = timeoutScheduler); return new AnonymousObservable(function (observer) { var first = true, hasResult = false, result, state = initialState, time; return scheduler.scheduleRecursiveWithRelative(0, function (self) { hasResult && observer.onNext(result); try { if (first) { first = false; } else { state = iterate(state); } hasResult = condition(state); if (hasResult) { result = resultSelector(state); time = timeSelector(state); } } catch (e) { observer.onError(e); return; } if (hasResult) { self(time); } else { observer.onCompleted(); } }); }); }; /** * Time shifts the observable sequence by delaying the subscription. * * @example * 1 - res = source.delaySubscription(5000); // 5s * 2 - res = source.delaySubscription(5000, Rx.Scheduler.timeout); // 5 seconds * * @param {Number} dueTime Absolute or relative time to perform the subscription at. * @param {Scheduler} [scheduler] Scheduler to run the subscription delay timer on. If not specified, the timeout scheduler is used. * @returns {Observable} Time-shifted sequence. */ observableProto.delaySubscription = function (dueTime, scheduler) { return this.delayWithSelector(observableTimer(dueTime, isScheduler(scheduler) ? scheduler : timeoutScheduler), observableEmpty); }; /** * Time shifts the observable sequence based on a subscription delay and a delay selector function for each element. * * @example * 1 - res = source.delayWithSelector(function (x) { return Rx.Scheduler.timer(5000); }); // with selector only * 1 - res = source.delayWithSelector(Rx.Observable.timer(2000), function (x) { return Rx.Observable.timer(x); }); // with delay and selector * * @param {Observable} [subscriptionDelay] Sequence indicating the delay for the subscription to the source. * @param {Function} delayDurationSelector Selector function to retrieve a sequence indicating the delay for each given element. * @returns {Observable} Time-shifted sequence. */ observableProto.delayWithSelector = function (subscriptionDelay, delayDurationSelector) { var source = this, subDelay, selector; if (typeof subscriptionDelay === 'function') { selector = subscriptionDelay; } else { subDelay = subscriptionDelay; selector = delayDurationSelector; } return new AnonymousObservable(function (observer) { var delays = new CompositeDisposable(), atEnd = false, done = function () { if (atEnd && delays.length === 0) { observer.onCompleted(); } }, subscription = new SerialDisposable(), start = function () { subscription.setDisposable(source.subscribe(function (x) { var delay; try { delay = selector(x); } catch (error) { observer.onError(error); return; } var d = new SingleAssignmentDisposable(); delays.add(d); d.setDisposable(delay.subscribe(function () { observer.onNext(x); delays.remove(d); done(); }, observer.onError.bind(observer), function () { observer.onNext(x); delays.remove(d); done(); })); }, observer.onError.bind(observer), function () { atEnd = true; subscription.dispose(); done(); })); }; if (!subDelay) { start(); } else { subscription.setDisposable(subDelay.subscribe(start, observer.onError.bind(observer), start)); } return new CompositeDisposable(subscription, delays); }, this); }; /** * Returns the source observable sequence, switching to the other observable sequence if a timeout is signaled. * @param {Observable} [firstTimeout] Observable sequence that represents the timeout for the first element. If not provided, this defaults to Observable.never(). * @param {Function} timeoutDurationSelector Selector to retrieve an observable sequence that represents the timeout between the current element and the next element. * @param {Observable} [other] Sequence to return in case of a timeout. If not provided, this is set to Observable.throwException(). * @returns {Observable} The source sequence switching to the other sequence in case of a timeout. */ observableProto.timeoutWithSelector = function (firstTimeout, timeoutdurationSelector, other) { if (arguments.length === 1) { timeoutdurationSelector = firstTimeout; firstTimeout = observableNever(); } other || (other = observableThrow(new Error('Timeout'))); var source = this; return new AnonymousObservable(function (observer) { var subscription = new SerialDisposable(), timer = new SerialDisposable(), original = new SingleAssignmentDisposable(); subscription.setDisposable(original); var id = 0, switched = false; function setTimer(timeout) { var myId = id; function timerWins () { return id === myId; } var d = new SingleAssignmentDisposable(); timer.setDisposable(d); d.setDisposable(timeout.subscribe(function () { timerWins() && subscription.setDisposable(other.subscribe(observer)); d.dispose(); }, function (e) { timerWins() && observer.onError(e); }, function () { timerWins() && subscription.setDisposable(other.subscribe(observer)); })); }; setTimer(firstTimeout); function observerWins() { var res = !switched; if (res) { id++; } return res; } original.setDisposable(source.subscribe(function (x) { if (observerWins()) { observer.onNext(x); var timeout; try { timeout = timeoutdurationSelector(x); } catch (e) { observer.onError(e); return; } setTimer(isPromise(timeout) ? observableFromPromise(timeout) : timeout); } }, function (e) { observerWins() && observer.onError(e); }, function () { observerWins() && observer.onCompleted(); })); return new CompositeDisposable(subscription, timer); }, source); }; /** * Ignores values from an observable sequence which are followed by another value within a computed throttle duration. * @param {Function} durationSelector Selector function to retrieve a sequence indicating the throttle duration for each given element. * @returns {Observable} The debounced sequence. */ observableProto.debounceWithSelector = function (durationSelector) { var source = this; return new AnonymousObservable(function (observer) { var value, hasValue = false, cancelable = new SerialDisposable(), id = 0; var subscription = source.subscribe(function (x) { var throttle; try { throttle = durationSelector(x); } catch (e) { observer.onError(e); return; } isPromise(throttle) && (throttle = observableFromPromise(throttle)); hasValue = true; value = x; id++; var currentid = id, d = new SingleAssignmentDisposable(); cancelable.setDisposable(d); d.setDisposable(throttle.subscribe(function () { hasValue && id === currentid && observer.onNext(value); hasValue = false; d.dispose(); }, observer.onError.bind(observer), function () { hasValue && id === currentid && observer.onNext(value); hasValue = false; d.dispose(); })); }, function (e) { cancelable.dispose(); observer.onError(e); hasValue = false; id++; }, function () { cancelable.dispose(); hasValue && observer.onNext(value); observer.onCompleted(); hasValue = false; id++; }); return new CompositeDisposable(subscription, cancelable); }, source); }; /** * @deprecated use #debounceWithSelector instead. */ observableProto.throttleWithSelector = function (durationSelector) { //deprecate('throttleWithSelector', 'debounceWithSelector'); return this.debounceWithSelector(durationSelector); }; /** * Skips elements for the specified duration from the end of the observable source sequence, using the specified scheduler to run timers. * * 1 - res = source.skipLastWithTime(5000); * 2 - res = source.skipLastWithTime(5000, scheduler); * * @description * This operator accumulates a queue with a length enough to store elements received during the initial duration window. * As more elements are received, elements older than the specified duration are taken from the queue and produced on the * result sequence. This causes elements to be delayed with duration. * @param {Number} duration Duration for skipping elements from the end of the sequence. * @param {Scheduler} [scheduler] Scheduler to run the timer on. If not specified, defaults to Rx.Scheduler.timeout * @returns {Observable} An observable sequence with the elements skipped during the specified duration from the end of the source sequence. */ observableProto.skipLastWithTime = function (duration, scheduler) { isScheduler(scheduler) || (scheduler = timeoutScheduler); var source = this; return new AnonymousObservable(function (o) { var q = []; return source.subscribe(function (x) { var now = scheduler.now(); q.push({ interval: now, value: x }); while (q.length > 0 && now - q[0].interval >= duration) { o.onNext(q.shift().value); } }, function (e) { o.onError(e); }, function () { var now = scheduler.now(); while (q.length > 0 && now - q[0].interval >= duration) { o.onNext(q.shift().value); } o.onCompleted(); }); }, source); }; /** * Returns elements within the specified duration from the end of the observable source sequence, using the specified schedulers to run timers and to drain the collected elements. * @description * This operator accumulates a queue with a length enough to store elements received during the initial duration window. * As more elements are received, elements older than the specified duration are taken from the queue and produced on the * result sequence. This causes elements to be delayed with duration. * @param {Number} duration Duration for taking elements from the end of the sequence. * @param {Scheduler} [scheduler] Scheduler to run the timer on. If not specified, defaults to Rx.Scheduler.timeout. * @returns {Observable} An observable sequence with the elements taken during the specified duration from the end of the source sequence. */ observableProto.takeLastWithTime = function (duration, scheduler) { var source = this; isScheduler(scheduler) || (scheduler = timeoutScheduler); return new AnonymousObservable(function (o) { var q = []; return source.subscribe(function (x) { var now = scheduler.now(); q.push({ interval: now, value: x }); while (q.length > 0 && now - q[0].interval >= duration) { q.shift(); } }, function (e) { o.onError(e); }, function () { var now = scheduler.now(); while (q.length > 0) { var next = q.shift(); if (now - next.interval <= duration) { o.onNext(next.value); } } o.onCompleted(); }); }, source); }; /** * Returns an array with the elements within the specified duration from the end of the observable source sequence, using the specified scheduler to run timers. * @description * This operator accumulates a queue with a length enough to store elements received during the initial duration window. * As more elements are received, elements older than the specified duration are taken from the queue and produced on the * result sequence. This causes elements to be delayed with duration. * @param {Number} duration Duration for taking elements from the end of the sequence. * @param {Scheduler} scheduler Scheduler to run the timer on. If not specified, defaults to Rx.Scheduler.timeout. * @returns {Observable} An observable sequence containing a single array with the elements taken during the specified duration from the end of the source sequence. */ observableProto.takeLastBufferWithTime = function (duration, scheduler) { var source = this; isScheduler(scheduler) || (scheduler = timeoutScheduler); return new AnonymousObservable(function (o) { var q = []; return source.subscribe(function (x) { var now = scheduler.now(); q.push({ interval: now, value: x }); while (q.length > 0 && now - q[0].interval >= duration) { q.shift(); } }, function (e) { o.onError(e); }, function () { var now = scheduler.now(), res = []; while (q.length > 0) { var next = q.shift(); now - next.interval <= duration && res.push(next.value); } o.onNext(res); o.onCompleted(); }); }, source); }; /** * Takes elements for the specified duration from the start of the observable source sequence, using the specified scheduler to run timers. * * @example * 1 - res = source.takeWithTime(5000, [optional scheduler]); * @description * This operator accumulates a queue with a length enough to store elements received during the initial duration window. * As more elements are received, elements older than the specified duration are taken from the queue and produced on the * result sequence. This causes elements to be delayed with duration. * @param {Number} duration Duration for taking elements from the start of the sequence. * @param {Scheduler} scheduler Scheduler to run the timer on. If not specified, defaults to Rx.Scheduler.timeout. * @returns {Observable} An observable sequence with the elements taken during the specified duration from the start of the source sequence. */ observableProto.takeWithTime = function (duration, scheduler) { var source = this; isScheduler(scheduler) || (scheduler = timeoutScheduler); return new AnonymousObservable(function (o) { return new CompositeDisposable(scheduler.scheduleWithRelative(duration, function () { o.onCompleted(); }), source.subscribe(o)); }, source); }; /** * Skips elements for the specified duration from the start of the observable source sequence, using the specified scheduler to run timers. * * @example * 1 - res = source.skipWithTime(5000, [optional scheduler]); * * @description * Specifying a zero value for duration doesn't guarantee no elements will be dropped from the start of the source sequence. * This is a side-effect of the asynchrony introduced by the scheduler, where the action that causes callbacks from the source sequence to be forwarded * may not execute immediately, despite the zero due time. * * Errors produced by the source sequence are always forwarded to the result sequence, even if the error occurs before the duration. * @param {Number} duration Duration for skipping elements from the start of the sequence. * @param {Scheduler} scheduler Scheduler to run the timer on. If not specified, defaults to Rx.Scheduler.timeout. * @returns {Observable} An observable sequence with the elements skipped during the specified duration from the start of the source sequence. */ observableProto.skipWithTime = function (duration, scheduler) { var source = this; isScheduler(scheduler) || (scheduler = timeoutScheduler); return new AnonymousObservable(function (observer) { var open = false; return new CompositeDisposable( scheduler.scheduleWithRelative(duration, function () { open = true; }), source.subscribe(function (x) { open && observer.onNext(x); }, observer.onError.bind(observer), observer.onCompleted.bind(observer))); }, source); }; /** * Skips elements from the observable source sequence until the specified start time, using the specified scheduler to run timers. * Errors produced by the source sequence are always forwarded to the result sequence, even if the error occurs before the start time. * * @examples * 1 - res = source.skipUntilWithTime(new Date(), [scheduler]); * 2 - res = source.skipUntilWithTime(5000, [scheduler]); * @param {Date|Number} startTime Time to start taking elements from the source sequence. If this value is less than or equal to Date(), no elements will be skipped. * @param {Scheduler} [scheduler] Scheduler to run the timer on. If not specified, defaults to Rx.Scheduler.timeout. * @returns {Observable} An observable sequence with the elements skipped until the specified start time. */ observableProto.skipUntilWithTime = function (startTime, scheduler) { isScheduler(scheduler) || (scheduler = timeoutScheduler); var source = this, schedulerMethod = startTime instanceof Date ? 'scheduleWithAbsolute' : 'scheduleWithRelative'; return new AnonymousObservable(function (o) { var open = false; return new CompositeDisposable( scheduler[schedulerMethod](startTime, function () { open = true; }), source.subscribe( function (x) { open && o.onNext(x); }, function (e) { o.onError(e); }, function () { o.onCompleted(); })); }, source); }; /** * Takes elements for the specified duration until the specified end time, using the specified scheduler to run timers. * @param {Number | Date} endTime Time to stop taking elements from the source sequence. If this value is less than or equal to new Date(), the result stream will complete immediately. * @param {Scheduler} [scheduler] Scheduler to run the timer on. * @returns {Observable} An observable sequence with the elements taken until the specified end time. */ observableProto.takeUntilWithTime = function (endTime, scheduler) { isScheduler(scheduler) || (scheduler = timeoutScheduler); var source = this, schedulerMethod = endTime instanceof Date ? 'scheduleWithAbsolute' : 'scheduleWithRelative'; return new AnonymousObservable(function (o) { return new CompositeDisposable( scheduler[schedulerMethod](endTime, function () { o.onCompleted(); }), source.subscribe(o)); }, source); }; /** * Returns an Observable that emits only the first item emitted by the source Observable during sequential time windows of a specified duration. * @param {Number} windowDuration time to wait before emitting another item after emitting the last item * @param {Scheduler} [scheduler] the Scheduler to use internally to manage the timers that handle timeout for each item. If not provided, defaults to Scheduler.timeout. * @returns {Observable} An Observable that performs the throttle operation. */ observableProto.throttleFirst = function (windowDuration, scheduler) { isScheduler(scheduler) || (scheduler = timeoutScheduler); var duration = +windowDuration || 0; if (duration <= 0) { throw new RangeError('windowDuration cannot be less or equal zero.'); } var source = this; return new AnonymousObservable(function (o) { var lastOnNext = 0; return source.subscribe( function (x) { var now = scheduler.now(); if (lastOnNext === 0 || now - lastOnNext >= duration) { lastOnNext = now; o.onNext(x); } },function (e) { o.onError(e); }, function () { o.onCompleted(); } ); }, source); }; /** * Executes a transducer to transform the observable sequence * @param {Transducer} transducer A transducer to execute * @returns {Observable} An Observable sequence containing the results from the transducer. */ observableProto.transduce = function(transducer) { var source = this; function transformForObserver(o) { return { '@@transducer/init': function() { return o; }, '@@transducer/step': function(obs, input) { return obs.onNext(input); }, '@@transducer/result': function(obs) { return obs.onCompleted(); } }; } return new AnonymousObservable(function(o) { var xform = transducer(transformForObserver(o)); return source.subscribe( function(v) { try { xform['@@transducer/step'](o, v); } catch (e) { o.onError(e); } }, function (e) { o.onError(e); }, function() { xform['@@transducer/result'](o); } ); }, source); }; /* * Performs a exclusive waiting for the first to finish before subscribing to another observable. * Observables that come in between subscriptions will be dropped on the floor. * @returns {Observable} A exclusive observable with only the results that happen when subscribed. */ observableProto.exclusive = function () { var sources = this; return new AnonymousObservable(function (observer) { var hasCurrent = false, isStopped = false, m = new SingleAssignmentDisposable(), g = new CompositeDisposable(); g.add(m); m.setDisposable(sources.subscribe( function (innerSource) { if (!hasCurrent) { hasCurrent = true; isPromise(innerSource) && (innerSource = observableFromPromise(innerSource)); var innerSubscription = new SingleAssignmentDisposable(); g.add(innerSubscription); innerSubscription.setDisposable(innerSource.subscribe( observer.onNext.bind(observer), observer.onError.bind(observer), function () { g.remove(innerSubscription); hasCurrent = false; if (isStopped && g.length === 1) { observer.onCompleted(); } })); } }, observer.onError.bind(observer), function () { isStopped = true; if (!hasCurrent && g.length === 1) { observer.onCompleted(); } })); return g; }, this); }; /* * Performs a exclusive map waiting for the first to finish before subscribing to another observable. * Observables that come in between subscriptions will be dropped on the floor. * @param {Function} selector Selector to invoke for every item in the current subscription. * @param {Any} [thisArg] An optional context to invoke with the selector parameter. * @returns {Observable} An exclusive observable with only the results that happen when subscribed. */ observableProto.exclusiveMap = function (selector, thisArg) { var sources = this, selectorFunc = bindCallback(selector, thisArg, 3); return new AnonymousObservable(function (observer) { var index = 0, hasCurrent = false, isStopped = true, m = new SingleAssignmentDisposable(), g = new CompositeDisposable(); g.add(m); m.setDisposable(sources.subscribe( function (innerSource) { if (!hasCurrent) { hasCurrent = true; innerSubscription = new SingleAssignmentDisposable(); g.add(innerSubscription); isPromise(innerSource) && (innerSource = observableFromPromise(innerSource)); innerSubscription.setDisposable(innerSource.subscribe( function (x) { var result; try { result = selectorFunc(x, index++, innerSource); } catch (e) { observer.onError(e); return; } observer.onNext(result); }, function (e) { observer.onError(e); }, function () { g.remove(innerSubscription); hasCurrent = false; if (isStopped && g.length === 1) { observer.onCompleted(); } })); } }, function (e) { observer.onError(e); }, function () { isStopped = true; if (g.length === 1 && !hasCurrent) { observer.onCompleted(); } })); return g; }, this); }; /** Provides a set of extension methods for virtual time scheduling. */ Rx.VirtualTimeScheduler = (function (__super__) { function localNow() { return this.toDateTimeOffset(this.clock); } function scheduleNow(state, action) { return this.scheduleAbsoluteWithState(state, this.clock, action); } function scheduleRelative(state, dueTime, action) { return this.scheduleRelativeWithState(state, this.toRelative(dueTime), action); } function scheduleAbsolute(state, dueTime, action) { return this.scheduleRelativeWithState(state, this.toRelative(dueTime - this.now()), action); } function invokeAction(scheduler, action) { action(); return disposableEmpty; } inherits(VirtualTimeScheduler, __super__); /** * Creates a new virtual time scheduler with the specified initial clock value and absolute time comparer. * * @constructor * @param {Number} initialClock Initial value for the clock. * @param {Function} comparer Comparer to determine causality of events based on absolute time. */ function VirtualTimeScheduler(initialClock, comparer) { this.clock = initialClock; this.comparer = comparer; this.isEnabled = false; this.queue = new PriorityQueue(1024); __super__.call(this, localNow, scheduleNow, scheduleRelative, scheduleAbsolute); } var VirtualTimeSchedulerPrototype = VirtualTimeScheduler.prototype; /** * Adds a relative time value to an absolute time value. * @param {Number} absolute Absolute virtual time value. * @param {Number} relative Relative virtual time value to add. * @return {Number} Resulting absolute virtual time sum value. */ VirtualTimeSchedulerPrototype.add = notImplemented; /** * Converts an absolute time to a number * @param {Any} The absolute time. * @returns {Number} The absolute time in ms */ VirtualTimeSchedulerPrototype.toDateTimeOffset = notImplemented; /** * Converts the TimeSpan value to a relative virtual time value. * @param {Number} timeSpan TimeSpan value to convert. * @return {Number} Corresponding relative virtual time value. */ VirtualTimeSchedulerPrototype.toRelative = notImplemented; /** * Schedules a periodic piece of work by dynamically discovering the scheduler's capabilities. The periodic task will be emulated using recursive scheduling. * @param {Mixed} state Initial state passed to the action upon the first iteration. * @param {Number} period Period for running the work periodically. * @param {Function} action Action to be executed, potentially updating the state. * @returns {Disposable} The disposable object used to cancel the scheduled recurring action (best effort). */ VirtualTimeSchedulerPrototype.schedulePeriodicWithState = function (state, period, action) { var s = new SchedulePeriodicRecursive(this, state, period, action); return s.start(); }; /** * Schedules an action to be executed after dueTime. * @param {Mixed} state State passed to the action to be executed. * @param {Number} dueTime Relative time after which to execute the action. * @param {Function} action Action to be executed. * @returns {Disposable} The disposable object used to cancel the scheduled action (best effort). */ VirtualTimeSchedulerPrototype.scheduleRelativeWithState = function (state, dueTime, action) { var runAt = this.add(this.clock, dueTime); return this.scheduleAbsoluteWithState(state, runAt, action); }; /** * Schedules an action to be executed at dueTime. * @param {Number} dueTime Relative time after which to execute the action. * @param {Function} action Action to be executed. * @returns {Disposable} The disposable object used to cancel the scheduled action (best effort). */ VirtualTimeSchedulerPrototype.scheduleRelative = function (dueTime, action) { return this.scheduleRelativeWithState(action, dueTime, invokeAction); }; /** * Starts the virtual time scheduler. */ VirtualTimeSchedulerPrototype.start = function () { if (!this.isEnabled) { this.isEnabled = true; do { var next = this.getNext(); if (next !== null) { this.comparer(next.dueTime, this.clock) > 0 && (this.clock = next.dueTime); next.invoke(); } else { this.isEnabled = false; } } while (this.isEnabled); } }; /** * Stops the virtual time scheduler. */ VirtualTimeSchedulerPrototype.stop = function () { this.isEnabled = false; }; /** * Advances the scheduler's clock to the specified time, running all work till that point. * @param {Number} time Absolute time to advance the scheduler's clock to. */ VirtualTimeSchedulerPrototype.advanceTo = function (time) { var dueToClock = this.comparer(this.clock, time); if (this.comparer(this.clock, time) > 0) { throw new ArgumentOutOfRangeError(); } if (dueToClock === 0) { return; } if (!this.isEnabled) { this.isEnabled = true; do { var next = this.getNext(); if (next !== null && this.comparer(next.dueTime, time) <= 0) { this.comparer(next.dueTime, this.clock) > 0 && (this.clock = next.dueTime); next.invoke(); } else { this.isEnabled = false; } } while (this.isEnabled); this.clock = time; } }; /** * Advances the scheduler's clock by the specified relative time, running all work scheduled for that timespan. * @param {Number} time Relative time to advance the scheduler's clock by. */ VirtualTimeSchedulerPrototype.advanceBy = function (time) { var dt = this.add(this.clock, time), dueToClock = this.comparer(this.clock, dt); if (dueToClock > 0) { throw new ArgumentOutOfRangeError(); } if (dueToClock === 0) { return; } this.advanceTo(dt); }; /** * Advances the scheduler's clock by the specified relative time. * @param {Number} time Relative time to advance the scheduler's clock by. */ VirtualTimeSchedulerPrototype.sleep = function (time) { var dt = this.add(this.clock, time); if (this.comparer(this.clock, dt) >= 0) { throw new ArgumentOutOfRangeError(); } this.clock = dt; }; /** * Gets the next scheduled item to be executed. * @returns {ScheduledItem} The next scheduled item. */ VirtualTimeSchedulerPrototype.getNext = function () { while (this.queue.length > 0) { var next = this.queue.peek(); if (next.isCancelled()) { this.queue.dequeue(); } else { return next; } } return null; }; /** * Schedules an action to be executed at dueTime. * @param {Scheduler} scheduler Scheduler to execute the action on. * @param {Number} dueTime Absolute time at which to execute the action. * @param {Function} action Action to be executed. * @returns {Disposable} The disposable object used to cancel the scheduled action (best effort). */ VirtualTimeSchedulerPrototype.scheduleAbsolute = function (dueTime, action) { return this.scheduleAbsoluteWithState(action, dueTime, invokeAction); }; /** * Schedules an action to be executed at dueTime. * @param {Mixed} state State passed to the action to be executed. * @param {Number} dueTime Absolute time at which to execute the action. * @param {Function} action Action to be executed. * @returns {Disposable} The disposable object used to cancel the scheduled action (best effort). */ VirtualTimeSchedulerPrototype.scheduleAbsoluteWithState = function (state, dueTime, action) { var self = this; function run(scheduler, state1) { self.queue.remove(si); return action(scheduler, state1); } var si = new ScheduledItem(this, state, run, dueTime, this.comparer); this.queue.enqueue(si); return si.disposable; }; return VirtualTimeScheduler; }(Scheduler)); /** Provides a virtual time scheduler that uses Date for absolute time and number for relative time. */ Rx.HistoricalScheduler = (function (__super__) { inherits(HistoricalScheduler, __super__); /** * Creates a new historical scheduler with the specified initial clock value. * @constructor * @param {Number} initialClock Initial value for the clock. * @param {Function} comparer Comparer to determine causality of events based on absolute time. */ function HistoricalScheduler(initialClock, comparer) { var clock = initialClock == null ? 0 : initialClock; var cmp = comparer || defaultSubComparer; __super__.call(this, clock, cmp); } var HistoricalSchedulerProto = HistoricalScheduler.prototype; /** * Adds a relative time value to an absolute time value. * @param {Number} absolute Absolute virtual time value. * @param {Number} relative Relative virtual time value to add. * @return {Number} Resulting absolute virtual time sum value. */ HistoricalSchedulerProto.add = function (absolute, relative) { return absolute + relative; }; HistoricalSchedulerProto.toDateTimeOffset = function (absolute) { return new Date(absolute).getTime(); }; /** * Converts the TimeSpan value to a relative virtual time value. * @memberOf HistoricalScheduler * @param {Number} timeSpan TimeSpan value to convert. * @return {Number} Corresponding relative virtual time value. */ HistoricalSchedulerProto.toRelative = function (timeSpan) { return timeSpan; }; return HistoricalScheduler; }(Rx.VirtualTimeScheduler)); var AnonymousObservable = Rx.AnonymousObservable = (function (__super__) { inherits(AnonymousObservable, __super__); // Fix subscriber to check for undefined or function returned to decorate as Disposable function fixSubscriber(subscriber) { return subscriber && isFunction(subscriber.dispose) ? subscriber : isFunction(subscriber) ? disposableCreate(subscriber) : disposableEmpty; } function setDisposable(s, state) { var ado = state[0], subscribe = state[1]; var sub = tryCatch(subscribe)(ado); if (sub === errorObj) { if(!ado.fail(errorObj.e)) { return thrower(errorObj.e); } } ado.setDisposable(fixSubscriber(sub)); } function AnonymousObservable(subscribe, parent) { this.source = parent; function s(observer) { var ado = new AutoDetachObserver(observer), state = [ado, subscribe]; if (currentThreadScheduler.scheduleRequired()) { currentThreadScheduler.scheduleWithState(state, setDisposable); } else { setDisposable(null, state); } return ado; } __super__.call(this, s); } return AnonymousObservable; }(Observable)); var AutoDetachObserver = (function (__super__) { inherits(AutoDetachObserver, __super__); function AutoDetachObserver(observer) { __super__.call(this); this.observer = observer; this.m = new SingleAssignmentDisposable(); } var AutoDetachObserverPrototype = AutoDetachObserver.prototype; AutoDetachObserverPrototype.next = function (value) { var result = tryCatch(this.observer.onNext).call(this.observer, value); if (result === errorObj) { this.dispose(); thrower(result.e); } }; AutoDetachObserverPrototype.error = function (err) { var result = tryCatch(this.observer.onError).call(this.observer, err); this.dispose(); result === errorObj && thrower(result.e); }; AutoDetachObserverPrototype.completed = function () { var result = tryCatch(this.observer.onCompleted).call(this.observer); this.dispose(); result === errorObj && thrower(result.e); }; AutoDetachObserverPrototype.setDisposable = function (value) { this.m.setDisposable(value); }; AutoDetachObserverPrototype.getDisposable = function () { return this.m.getDisposable(); }; AutoDetachObserverPrototype.dispose = function () { __super__.prototype.dispose.call(this); this.m.dispose(); }; return AutoDetachObserver; }(AbstractObserver)); var GroupedObservable = (function (__super__) { inherits(GroupedObservable, __super__); function subscribe(observer) { return this.underlyingObservable.subscribe(observer); } function GroupedObservable(key, underlyingObservable, mergedDisposable) { __super__.call(this, subscribe); this.key = key; this.underlyingObservable = !mergedDisposable ? underlyingObservable : new AnonymousObservable(function (observer) { return new CompositeDisposable(mergedDisposable.getDisposable(), underlyingObservable.subscribe(observer)); }); } return GroupedObservable; }(Observable)); /** * Represents an object that is both an observable sequence as well as an observer. * Each notification is broadcasted to all subscribed observers. */ var Subject = Rx.Subject = (function (__super__) { function subscribe(observer) { checkDisposed(this); if (!this.isStopped) { this.observers.push(observer); return new InnerSubscription(this, observer); } if (this.hasError) { observer.onError(this.error); return disposableEmpty; } observer.onCompleted(); return disposableEmpty; } inherits(Subject, __super__); /** * Creates a subject. */ function Subject() { __super__.call(this, subscribe); this.isDisposed = false, this.isStopped = false, this.observers = []; this.hasError = false; } addProperties(Subject.prototype, Observer.prototype, { /** * Indicates whether the subject has observers subscribed to it. * @returns {Boolean} Indicates whether the subject has observers subscribed to it. */ hasObservers: function () { return this.observers.length > 0; }, /** * Notifies all subscribed observers about the end of the sequence. */ onCompleted: function () { checkDisposed(this); if (!this.isStopped) { this.isStopped = true; for (var i = 0, os = cloneArray(this.observers), len = os.length; i < len; i++) { os[i].onCompleted(); } this.observers.length = 0; } }, /** * Notifies all subscribed observers about the exception. * @param {Mixed} error The exception to send to all observers. */ onError: function (error) { checkDisposed(this); if (!this.isStopped) { this.isStopped = true; this.error = error; this.hasError = true; for (var i = 0, os = cloneArray(this.observers), len = os.length; i < len; i++) { os[i].onError(error); } this.observers.length = 0; } }, /** * Notifies all subscribed observers about the arrival of the specified element in the sequence. * @param {Mixed} value The value to send to all observers. */ onNext: function (value) { checkDisposed(this); if (!this.isStopped) { for (var i = 0, os = cloneArray(this.observers), len = os.length; i < len; i++) { os[i].onNext(value); } } }, /** * Unsubscribe all observers and release resources. */ dispose: function () { this.isDisposed = true; this.observers = null; } }); /** * Creates a subject from the specified observer and observable. * @param {Observer} observer The observer used to send messages to the subject. * @param {Observable} observable The observable used to subscribe to messages sent from the subject. * @returns {Subject} Subject implemented using the given observer and observable. */ Subject.create = function (observer, observable) { return new AnonymousSubject(observer, observable); }; return Subject; }(Observable)); /** * Represents the result of an asynchronous operation. * The last value before the OnCompleted notification, or the error received through OnError, is sent to all subscribed observers. */ var AsyncSubject = Rx.AsyncSubject = (function (__super__) { function subscribe(observer) { checkDisposed(this); if (!this.isStopped) { this.observers.push(observer); return new InnerSubscription(this, observer); } if (this.hasError) { observer.onError(this.error); } else if (this.hasValue) { observer.onNext(this.value); observer.onCompleted(); } else { observer.onCompleted(); } return disposableEmpty; } inherits(AsyncSubject, __super__); /** * Creates a subject that can only receive one value and that value is cached for all future observations. * @constructor */ function AsyncSubject() { __super__.call(this, subscribe); this.isDisposed = false; this.isStopped = false; this.hasValue = false; this.observers = []; this.hasError = false; } addProperties(AsyncSubject.prototype, Observer, { /** * Indicates whether the subject has observers subscribed to it. * @returns {Boolean} Indicates whether the subject has observers subscribed to it. */ hasObservers: function () { checkDisposed(this); return this.observers.length > 0; }, /** * Notifies all subscribed observers about the end of the sequence, also causing the last received value to be sent out (if any). */ onCompleted: function () { var i, len; checkDisposed(this); if (!this.isStopped) { this.isStopped = true; var os = cloneArray(this.observers), len = os.length; if (this.hasValue) { for (i = 0; i < len; i++) { var o = os[i]; o.onNext(this.value); o.onCompleted(); } } else { for (i = 0; i < len; i++) { os[i].onCompleted(); } } this.observers.length = 0; } }, /** * Notifies all subscribed observers about the error. * @param {Mixed} error The Error to send to all observers. */ onError: function (error) { checkDisposed(this); if (!this.isStopped) { this.isStopped = true; this.hasError = true; this.error = error; for (var i = 0, os = cloneArray(this.observers), len = os.length; i < len; i++) { os[i].onError(error); } this.observers.length = 0; } }, /** * Sends a value to the subject. The last value received before successful termination will be sent to all subscribed and future observers. * @param {Mixed} value The value to store in the subject. */ onNext: function (value) { checkDisposed(this); if (this.isStopped) { return; } this.value = value; this.hasValue = true; }, /** * Unsubscribe all observers and release resources. */ dispose: function () { this.isDisposed = true; this.observers = null; this.exception = null; this.value = null; } }); return AsyncSubject; }(Observable)); var AnonymousSubject = Rx.AnonymousSubject = (function (__super__) { inherits(AnonymousSubject, __super__); function subscribe(observer) { return this.observable.subscribe(observer); } function AnonymousSubject(observer, observable) { this.observer = observer; this.observable = observable; __super__.call(this, subscribe); } addProperties(AnonymousSubject.prototype, Observer.prototype, { onCompleted: function () { this.observer.onCompleted(); }, onError: function (error) { this.observer.onError(error); }, onNext: function (value) { this.observer.onNext(value); } }); return AnonymousSubject; }(Observable)); /** * Used to pause and resume streams. */ Rx.Pauser = (function (__super__) { inherits(Pauser, __super__); function Pauser() { __super__.call(this); } /** * Pauses the underlying sequence. */ Pauser.prototype.pause = function () { this.onNext(false); }; /** * Resumes the underlying sequence. */ Pauser.prototype.resume = function () { this.onNext(true); }; return Pauser; }(Subject)); if (typeof define == 'function' && typeof define.amd == 'object' && define.amd) { root.Rx = Rx; define(function() { return Rx; }); } else if (freeExports && freeModule) { // in Node.js or RingoJS if (moduleExports) { (freeModule.exports = Rx).Rx = Rx; } else { freeExports.Rx = Rx; } } else { // in a browser or Rhino root.Rx = Rx; } // All code before this point will be filtered from stack traces. var rEndingLine = captureLine(); }.call(this)); }).call(this,require("FWaASH"),typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {}) },{"FWaASH":147}]},{},[1])
website/Application.js
bvaughn/react-highlight-words
import React from 'react' import HighlighterExample from '../src/Highlighter.example' import styles from './Application.css' export default function Application () { return ( <div> <div className={styles.headerRow}> <img className={styles.logo} width='482' height='278' src='https://cloud.githubusercontent.com/assets/29597/11903349/6da3d9c0-a56d-11e5-806d-1c7b96289523.png' /> </div> <div className={styles.body}> <div className={styles.card}> <HighlighterExample/> </div> </div> <div className={styles.footer}> react-highlight-words is available under the MIT license. </div> </div> ) }
examples/webpack/src/index.js
bluetidepro/react-styleguidist
import React from 'react'; import ReactDOM from 'react-dom'; import App from './App'; import './index.css'; ReactDOM.render(<App />, document.getElementById('root'));
example/index.js
thedgbrt/react-native-masonry
/** * Masonry demo app * @flow */ import React from 'react'; import { StyleSheet, Text, View } from 'react-native'; import Masonry from '../lib/Masonry'; const data = [ { text: "Hello" }, { text: "GoodBye" }, { text: "How are you doing today? I'm fine thank you" }, { text: "Who's a good boy?" } ]; let lotsOfData = []; for (let i = 0; i < 30; i++) { lotsOfData.push(...data); } const MasonryExample = () => ( <Masonry columns={3} data={lotsOfData} /> ); export default MasonryExample;
src/components/heroName.js
narcolepticsnowman/snow87site
import React, { Component } from 'react'; import './heroName.css'; import LinearAnimator from '../linearAnimator'; class HeroName extends Component { constructor(){ super(); new LinearAnimator( ()=> document.getElementsByClassName('hero-name')[0], ()=> {return { x: 0, y: window.innerHeight - window.innerHeight/4, width: '100%', height: '25%' }}, ()=> {return {y: 0, x: window.innerWidth*.36, width: "30%", height: "18%"}}, ()=> window.innerHeight*.75 ); } render() { return ( <div className="hero-name"> <div className="name-back"> Robert&nbsp;Kempton </div> </div> ); } } export default HeroName;
lodash/node_modules/core-js/modules/es6.promise.js
PerezYuan/learn
'use strict'; var LIBRARY = require('./_library') , global = require('./_global') , ctx = require('./_ctx') , classof = require('./_classof') , $export = require('./_export') , isObject = require('./_is-object') , aFunction = require('./_a-function') , anInstance = require('./_an-instance') , forOf = require('./_for-of') , speciesConstructor = require('./_species-constructor') , task = require('./_task').set , microtask = require('./_microtask')() , PROMISE = 'Promise' , TypeError = global.TypeError , process = global.process , $Promise = global[PROMISE] , process = global.process , isNode = classof(process) == 'process' , empty = function(){ /* empty */ } , Internal, GenericPromiseCapability, Wrapper; var USE_NATIVE = !!function(){ try { // correct subclassing with @@species support var promise = $Promise.resolve(1) , FakePromise = (promise.constructor = {})[require('./_wks')('species')] = function(exec){ exec(empty, empty); }; // unhandled rejections tracking support, NodeJS Promise without it fails @@species test return (isNode || typeof PromiseRejectionEvent == 'function') && promise.then(empty) instanceof FakePromise; } catch(e){ /* empty */ } }(); // helpers var sameConstructor = function(a, b){ // with library wrapper special case return a === b || a === $Promise && b === Wrapper; }; var isThenable = function(it){ var then; return isObject(it) && typeof (then = it.then) == 'function' ? then : false; }; var newPromiseCapability = function(C){ return sameConstructor($Promise, C) ? new PromiseCapability(C) : new GenericPromiseCapability(C); }; var PromiseCapability = GenericPromiseCapability = function(C){ var resolve, reject; this.promise = new C(function($$resolve, $$reject){ if(resolve !== undefined || reject !== undefined)throw TypeError('Bad Promise constructor'); resolve = $$resolve; reject = $$reject; }); this.resolve = aFunction(resolve); this.reject = aFunction(reject); }; var perform = function(exec){ try { exec(); } catch(e){ return {error: e}; } }; var notify = function(promise, isReject){ if(promise._n)return; promise._n = true; var chain = promise._c; microtask(function(){ var value = promise._v , ok = promise._s == 1 , i = 0; var run = function(reaction){ var handler = ok ? reaction.ok : reaction.fail , resolve = reaction.resolve , reject = reaction.reject , domain = reaction.domain , result, then; try { if(handler){ if(!ok){ if(promise._h == 2)onHandleUnhandled(promise); promise._h = 1; } if(handler === true)result = value; else { if(domain)domain.enter(); result = handler(value); if(domain)domain.exit(); } if(result === reaction.promise){ reject(TypeError('Promise-chain cycle')); } else if(then = isThenable(result)){ then.call(result, resolve, reject); } else resolve(result); } else reject(value); } catch(e){ reject(e); } }; while(chain.length > i)run(chain[i++]); // variable length - can't use forEach promise._c = []; promise._n = false; if(isReject && !promise._h)onUnhandled(promise); }); }; var onUnhandled = function(promise){ task.call(global, function(){ var value = promise._v , abrupt, handler, console; if(isUnhandled(promise)){ abrupt = perform(function(){ if(isNode){ process.emit('unhandledRejection', value, promise); } else if(handler = global.onunhandledrejection){ handler({promise: promise, reason: value}); } else if((console = global.console) && console.error){ console.error('Unhandled promise rejection', value); } }); // Browsers should not trigger `rejectionHandled` event if it was handled here, NodeJS - should promise._h = isNode || isUnhandled(promise) ? 2 : 1; } promise._a = undefined; if(abrupt)throw abrupt.error; }); }; var isUnhandled = function(promise){ if(promise._h == 1)return false; var chain = promise._a || promise._c , i = 0 , reaction; while(chain.length > i){ reaction = chain[i++]; if(reaction.fail || !isUnhandled(reaction.promise))return false; } return true; }; var onHandleUnhandled = function(promise){ task.call(global, function(){ var handler; if(isNode){ process.emit('rejectionHandled', promise); } else if(handler = global.onrejectionhandled){ handler({promise: promise, reason: promise._v}); } }); }; var $reject = function(value){ var promise = this; if(promise._d)return; promise._d = true; promise = promise._w || promise; // unwrap promise._v = value; promise._s = 2; if(!promise._a)promise._a = promise._c.slice(); notify(promise, true); }; var $resolve = function(value){ var promise = this , then; if(promise._d)return; promise._d = true; promise = promise._w || promise; // unwrap try { if(promise === value)throw TypeError("Promise can't be resolved itself"); if(then = isThenable(value)){ microtask(function(){ var wrapper = {_w: promise, _d: false}; // wrap try { then.call(value, ctx($resolve, wrapper, 1), ctx($reject, wrapper, 1)); } catch(e){ $reject.call(wrapper, e); } }); } else { promise._v = value; promise._s = 1; notify(promise, false); } } catch(e){ $reject.call({_w: promise, _d: false}, e); // wrap } }; // constructor polyfill if(!USE_NATIVE){ // 25.4.3.1 Promise(executor) $Promise = function Promise(executor){ anInstance(this, $Promise, PROMISE, '_h'); aFunction(executor); Internal.call(this); try { executor(ctx($resolve, this, 1), ctx($reject, this, 1)); } catch(err){ $reject.call(this, err); } }; Internal = function Promise(executor){ this._c = []; // <- awaiting reactions this._a = undefined; // <- checked in isUnhandled reactions this._s = 0; // <- state this._d = false; // <- done this._v = undefined; // <- value this._h = 0; // <- rejection state, 0 - default, 1 - handled, 2 - unhandled this._n = false; // <- notify }; Internal.prototype = require('./_redefine-all')($Promise.prototype, { // 25.4.5.3 Promise.prototype.then(onFulfilled, onRejected) then: function then(onFulfilled, onRejected){ var reaction = newPromiseCapability(speciesConstructor(this, $Promise)); reaction.ok = typeof onFulfilled == 'function' ? onFulfilled : true; reaction.fail = typeof onRejected == 'function' && onRejected; reaction.domain = isNode ? process.domain : undefined; this._c.push(reaction); if(this._a)this._a.push(reaction); if(this._s)notify(this, false); return reaction.promise; }, // 25.4.5.1 Promise.prototype.catch(onRejected) 'catch': function(onRejected){ return this.then(undefined, onRejected); } }); PromiseCapability = function(){ var promise = new Internal; this.promise = promise; this.resolve = ctx($resolve, promise, 1); this.reject = ctx($reject, promise, 1); }; } $export($export.G + $export.W + $export.F * !USE_NATIVE, {Promise: $Promise}); require('./_set-to-string-tag')($Promise, PROMISE); require('./_set-species')(PROMISE); Wrapper = require('./_core')[PROMISE]; // statics $export($export.S + $export.F * !USE_NATIVE, PROMISE, { // 25.4.4.5 Promise.reject(r) reject: function reject(r){ var capability = newPromiseCapability(this) , $$reject = capability.reject; $$reject(r); return capability.promise; } }); $export($export.S + $export.F * (LIBRARY || !USE_NATIVE), PROMISE, { // 25.4.4.6 Promise.resolve(x) resolve: function resolve(x){ // instanceof instead of internal slot check because we should fix it without replacement native Promise core if(x instanceof $Promise && sameConstructor(x.constructor, this))return x; var capability = newPromiseCapability(this) , $$resolve = capability.resolve; $$resolve(x); return capability.promise; } }); $export($export.S + $export.F * !(USE_NATIVE && require('./_iter-detect')(function(iter){ $Promise.all(iter)['catch'](empty); })), PROMISE, { // 25.4.4.1 Promise.all(iterable) all: function all(iterable){ var C = this , capability = newPromiseCapability(C) , resolve = capability.resolve , reject = capability.reject; var abrupt = perform(function(){ var values = [] , index = 0 , remaining = 1; forOf(iterable, false, function(promise){ var $index = index++ , alreadyCalled = false; values.push(undefined); remaining++; C.resolve(promise).then(function(value){ if(alreadyCalled)return; alreadyCalled = true; values[$index] = value; --remaining || resolve(values); }, reject); }); --remaining || resolve(values); }); if(abrupt)reject(abrupt.error); return capability.promise; }, // 25.4.4.4 Promise.race(iterable) race: function race(iterable){ var C = this , capability = newPromiseCapability(C) , reject = capability.reject; var abrupt = perform(function(){ forOf(iterable, false, function(promise){ C.resolve(promise).then(capability.resolve, reject); }); }); if(abrupt)reject(abrupt.error); return capability.promise; } });
fields/components/columns/ArrayColumn.js
rafmsou/keystone
import React from 'react'; import ItemsTableCell from '../../components/ItemsTableCell'; import ItemsTableValue from '../../components/ItemsTableValue'; var ArrayColumn = React.createClass({ displayName: 'ArrayColumn', propTypes: { col: React.PropTypes.object, data: React.PropTypes.object, }, renderValue () { const value = this.props.data.fields[this.props.col.path]; if (!value || !value.length) return null; return value.join(', '); }, render () { return ( <ItemsTableCell> <ItemsTableValue field={this.props.col.type}> {this.renderValue()} </ItemsTableValue> </ItemsTableCell> ); }, }); module.exports = ArrayColumn;
ajax/libs/gumby/2.6.0/js/libs/jquery-1.10.1.min.js
bergie/cdnjs
/*! jQuery v1.10.1 | (c) 2005, 2013 jQuery Foundation, Inc. | jquery.org/license //@ sourceMappingURL=jquery-1.10.1.min.map */ (function(e,t){var n,r,i=typeof t,o=e.location,a=e.document,s=a.documentElement,l=e.jQuery,u=e.$,c={},p=[],f="1.10.1",d=p.concat,h=p.push,g=p.slice,m=p.indexOf,y=c.toString,v=c.hasOwnProperty,b=f.trim,x=function(e,t){return new x.fn.init(e,t,r)},w=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,T=/\S+/g,C=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,N=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,k=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,E=/^[\],:{}\s]*$/,S=/(?:^|:|,)(?:\s*\[)+/g,A=/\\(?:["\\\/bfnrt]|u[\da-fA-F]{4})/g,j=/"[^"\\\r\n]*"|true|false|null|-?(?:\d+\.|)\d+(?:[eE][+-]?\d+|)/g,D=/^-ms-/,L=/-([\da-z])/gi,H=function(e,t){return t.toUpperCase()},q=function(e){(a.addEventListener||"load"===e.type||"complete"===a.readyState)&&(_(),x.ready())},_=function(){a.addEventListener?(a.removeEventListener("DOMContentLoaded",q,!1),e.removeEventListener("load",q,!1)):(a.detachEvent("onreadystatechange",q),e.detachEvent("onload",q))};x.fn=x.prototype={jquery:f,constructor:x,init:function(e,n,r){var i,o;if(!e)return this;if("string"==typeof e){if(i="<"===e.charAt(0)&&">"===e.charAt(e.length-1)&&e.length>=3?[null,e,null]:N.exec(e),!i||!i[1]&&n)return!n||n.jquery?(n||r).find(e):this.constructor(n).find(e);if(i[1]){if(n=n instanceof x?n[0]:n,x.merge(this,x.parseHTML(i[1],n&&n.nodeType?n.ownerDocument||n:a,!0)),k.test(i[1])&&x.isPlainObject(n))for(i in n)x.isFunction(this[i])?this[i](n[i]):this.attr(i,n[i]);return this}if(o=a.getElementById(i[2]),o&&o.parentNode){if(o.id!==i[2])return r.find(e);this.length=1,this[0]=o}return this.context=a,this.selector=e,this}return e.nodeType?(this.context=this[0]=e,this.length=1,this):x.isFunction(e)?r.ready(e):(e.selector!==t&&(this.selector=e.selector,this.context=e.context),x.makeArray(e,this))},selector:"",length:0,toArray:function(){return g.call(this)},get:function(e){return null==e?this.toArray():0>e?this[this.length+e]:this[e]},pushStack:function(e){var t=x.merge(this.constructor(),e);return t.prevObject=this,t.context=this.context,t},each:function(e,t){return x.each(this,e,t)},ready:function(e){return x.ready.promise().done(e),this},slice:function(){return this.pushStack(g.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(e){var t=this.length,n=+e+(0>e?t:0);return this.pushStack(n>=0&&t>n?[this[n]]:[])},map:function(e){return this.pushStack(x.map(this,function(t,n){return e.call(t,n,t)}))},end:function(){return this.prevObject||this.constructor(null)},push:h,sort:[].sort,splice:[].splice},x.fn.init.prototype=x.fn,x.extend=x.fn.extend=function(){var e,n,r,i,o,a,s=arguments[0]||{},l=1,u=arguments.length,c=!1;for("boolean"==typeof s&&(c=s,s=arguments[1]||{},l=2),"object"==typeof s||x.isFunction(s)||(s={}),u===l&&(s=this,--l);u>l;l++)if(null!=(o=arguments[l]))for(i in o)e=s[i],r=o[i],s!==r&&(c&&r&&(x.isPlainObject(r)||(n=x.isArray(r)))?(n?(n=!1,a=e&&x.isArray(e)?e:[]):a=e&&x.isPlainObject(e)?e:{},s[i]=x.extend(c,a,r)):r!==t&&(s[i]=r));return s},x.extend({expando:"jQuery"+(f+Math.random()).replace(/\D/g,""),noConflict:function(t){return e.$===x&&(e.$=u),t&&e.jQuery===x&&(e.jQuery=l),x},isReady:!1,readyWait:1,holdReady:function(e){e?x.readyWait++:x.ready(!0)},ready:function(e){if(e===!0?!--x.readyWait:!x.isReady){if(!a.body)return setTimeout(x.ready);x.isReady=!0,e!==!0&&--x.readyWait>0||(n.resolveWith(a,[x]),x.fn.trigger&&x(a).trigger("ready").off("ready"))}},isFunction:function(e){return"function"===x.type(e)},isArray:Array.isArray||function(e){return"array"===x.type(e)},isWindow:function(e){return null!=e&&e==e.window},isNumeric:function(e){return!isNaN(parseFloat(e))&&isFinite(e)},type:function(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?c[y.call(e)]||"object":typeof e},isPlainObject:function(e){var n;if(!e||"object"!==x.type(e)||e.nodeType||x.isWindow(e))return!1;try{if(e.constructor&&!v.call(e,"constructor")&&!v.call(e.constructor.prototype,"isPrototypeOf"))return!1}catch(r){return!1}if(x.support.ownLast)for(n in e)return v.call(e,n);for(n in e);return n===t||v.call(e,n)},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},error:function(e){throw Error(e)},parseHTML:function(e,t,n){if(!e||"string"!=typeof e)return null;"boolean"==typeof t&&(n=t,t=!1),t=t||a;var r=k.exec(e),i=!n&&[];return r?[t.createElement(r[1])]:(r=x.buildFragment([e],t,i),i&&x(i).remove(),x.merge([],r.childNodes))},parseJSON:function(n){return e.JSON&&e.JSON.parse?e.JSON.parse(n):null===n?n:"string"==typeof n&&(n=x.trim(n),n&&E.test(n.replace(A,"@").replace(j,"]").replace(S,"")))?Function("return "+n)():(x.error("Invalid JSON: "+n),t)},parseXML:function(n){var r,i;if(!n||"string"!=typeof n)return null;try{e.DOMParser?(i=new DOMParser,r=i.parseFromString(n,"text/xml")):(r=new ActiveXObject("Microsoft.XMLDOM"),r.async="false",r.loadXML(n))}catch(o){r=t}return r&&r.documentElement&&!r.getElementsByTagName("parsererror").length||x.error("Invalid XML: "+n),r},noop:function(){},globalEval:function(t){t&&x.trim(t)&&(e.execScript||function(t){e.eval.call(e,t)})(t)},camelCase:function(e){return e.replace(D,"ms-").replace(L,H)},nodeName:function(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()},each:function(e,t,n){var r,i=0,o=e.length,a=M(e);if(n){if(a){for(;o>i;i++)if(r=t.apply(e[i],n),r===!1)break}else for(i in e)if(r=t.apply(e[i],n),r===!1)break}else if(a){for(;o>i;i++)if(r=t.call(e[i],i,e[i]),r===!1)break}else for(i in e)if(r=t.call(e[i],i,e[i]),r===!1)break;return e},trim:b&&!b.call("\ufeff\u00a0")?function(e){return null==e?"":b.call(e)}:function(e){return null==e?"":(e+"").replace(C,"")},makeArray:function(e,t){var n=t||[];return null!=e&&(M(Object(e))?x.merge(n,"string"==typeof e?[e]:e):h.call(n,e)),n},inArray:function(e,t,n){var r;if(t){if(m)return m.call(t,e,n);for(r=t.length,n=n?0>n?Math.max(0,r+n):n:0;r>n;n++)if(n in t&&t[n]===e)return n}return-1},merge:function(e,n){var r=n.length,i=e.length,o=0;if("number"==typeof r)for(;r>o;o++)e[i++]=n[o];else while(n[o]!==t)e[i++]=n[o++];return e.length=i,e},grep:function(e,t,n){var r,i=[],o=0,a=e.length;for(n=!!n;a>o;o++)r=!!t(e[o],o),n!==r&&i.push(e[o]);return i},map:function(e,t,n){var r,i=0,o=e.length,a=M(e),s=[];if(a)for(;o>i;i++)r=t(e[i],i,n),null!=r&&(s[s.length]=r);else for(i in e)r=t(e[i],i,n),null!=r&&(s[s.length]=r);return d.apply([],s)},guid:1,proxy:function(e,n){var r,i,o;return"string"==typeof n&&(o=e[n],n=e,e=o),x.isFunction(e)?(r=g.call(arguments,2),i=function(){return e.apply(n||this,r.concat(g.call(arguments)))},i.guid=e.guid=e.guid||x.guid++,i):t},access:function(e,n,r,i,o,a,s){var l=0,u=e.length,c=null==r;if("object"===x.type(r)){o=!0;for(l in r)x.access(e,n,l,r[l],!0,a,s)}else if(i!==t&&(o=!0,x.isFunction(i)||(s=!0),c&&(s?(n.call(e,i),n=null):(c=n,n=function(e,t,n){return c.call(x(e),n)})),n))for(;u>l;l++)n(e[l],r,s?i:i.call(e[l],l,n(e[l],r)));return o?e:c?n.call(e):u?n(e[0],r):a},now:function(){return(new Date).getTime()},swap:function(e,t,n,r){var i,o,a={};for(o in t)a[o]=e.style[o],e.style[o]=t[o];i=n.apply(e,r||[]);for(o in t)e.style[o]=a[o];return i}}),x.ready.promise=function(t){if(!n)if(n=x.Deferred(),"complete"===a.readyState)setTimeout(x.ready);else if(a.addEventListener)a.addEventListener("DOMContentLoaded",q,!1),e.addEventListener("load",q,!1);else{a.attachEvent("onreadystatechange",q),e.attachEvent("onload",q);var r=!1;try{r=null==e.frameElement&&a.documentElement}catch(i){}r&&r.doScroll&&function o(){if(!x.isReady){try{r.doScroll("left")}catch(e){return setTimeout(o,50)}_(),x.ready()}}()}return n.promise(t)},x.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(e,t){c["[object "+t+"]"]=t.toLowerCase()});function M(e){var t=e.length,n=x.type(e);return x.isWindow(e)?!1:1===e.nodeType&&t?!0:"array"===n||"function"!==n&&(0===t||"number"==typeof t&&t>0&&t-1 in e)}r=x(a),function(e,t){var n,r,i,o,a,s,l,u,c,p,f,d,h,g,m,y,v,b="sizzle"+-new Date,w=e.document,T=0,C=0,N=lt(),k=lt(),E=lt(),S=!1,A=function(){return 0},j=typeof t,D=1<<31,L={}.hasOwnProperty,H=[],q=H.pop,_=H.push,M=H.push,O=H.slice,F=H.indexOf||function(e){var t=0,n=this.length;for(;n>t;t++)if(this[t]===e)return t;return-1},B="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",P="[\\x20\\t\\r\\n\\f]",R="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",W=R.replace("w","w#"),$="\\["+P+"*("+R+")"+P+"*(?:([*^$|!~]?=)"+P+"*(?:(['\"])((?:\\\\.|[^\\\\])*?)\\3|("+W+")|)|)"+P+"*\\]",I=":("+R+")(?:\\(((['\"])((?:\\\\.|[^\\\\])*?)\\3|((?:\\\\.|[^\\\\()[\\]]|"+$.replace(3,8)+")*)|.*)\\)|)",z=RegExp("^"+P+"+|((?:^|[^\\\\])(?:\\\\.)*)"+P+"+$","g"),X=RegExp("^"+P+"*,"+P+"*"),U=RegExp("^"+P+"*([>+~]|"+P+")"+P+"*"),V=RegExp(P+"*[+~]"),Y=RegExp("="+P+"*([^\\]'\"]*)"+P+"*\\]","g"),J=RegExp(I),G=RegExp("^"+W+"$"),Q={ID:RegExp("^#("+R+")"),CLASS:RegExp("^\\.("+R+")"),TAG:RegExp("^("+R.replace("w","w*")+")"),ATTR:RegExp("^"+$),PSEUDO:RegExp("^"+I),CHILD:RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+P+"*(even|odd|(([+-]|)(\\d*)n|)"+P+"*(?:([+-]|)"+P+"*(\\d+)|))"+P+"*\\)|)","i"),bool:RegExp("^(?:"+B+")$","i"),needsContext:RegExp("^"+P+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+P+"*((?:-\\d)?\\d*)"+P+"*\\)|)(?=[^-]|$)","i")},K=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,et=/^(?:input|select|textarea|button)$/i,tt=/^h\d$/i,nt=/'|\\/g,rt=RegExp("\\\\([\\da-f]{1,6}"+P+"?|("+P+")|.)","ig"),it=function(e,t,n){var r="0x"+t-65536;return r!==r||n?t:0>r?String.fromCharCode(r+65536):String.fromCharCode(55296|r>>10,56320|1023&r)};try{M.apply(H=O.call(w.childNodes),w.childNodes),H[w.childNodes.length].nodeType}catch(ot){M={apply:H.length?function(e,t){_.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function at(e,t,n,i){var o,a,s,l,u,c,d,m,y,x;if((t?t.ownerDocument||t:w)!==f&&p(t),t=t||f,n=n||[],!e||"string"!=typeof e)return n;if(1!==(l=t.nodeType)&&9!==l)return[];if(h&&!i){if(o=Z.exec(e))if(s=o[1]){if(9===l){if(a=t.getElementById(s),!a||!a.parentNode)return n;if(a.id===s)return n.push(a),n}else if(t.ownerDocument&&(a=t.ownerDocument.getElementById(s))&&v(t,a)&&a.id===s)return n.push(a),n}else{if(o[2])return M.apply(n,t.getElementsByTagName(e)),n;if((s=o[3])&&r.getElementsByClassName&&t.getElementsByClassName)return M.apply(n,t.getElementsByClassName(s)),n}if(r.qsa&&(!g||!g.test(e))){if(m=d=b,y=t,x=9===l&&e,1===l&&"object"!==t.nodeName.toLowerCase()){c=bt(e),(d=t.getAttribute("id"))?m=d.replace(nt,"\\$&"):t.setAttribute("id",m),m="[id='"+m+"'] ",u=c.length;while(u--)c[u]=m+xt(c[u]);y=V.test(e)&&t.parentNode||t,x=c.join(",")}if(x)try{return M.apply(n,y.querySelectorAll(x)),n}catch(T){}finally{d||t.removeAttribute("id")}}}return At(e.replace(z,"$1"),t,n,i)}function st(e){return K.test(e+"")}function lt(){var e=[];function t(n,r){return e.push(n+=" ")>o.cacheLength&&delete t[e.shift()],t[n]=r}return t}function ut(e){return e[b]=!0,e}function ct(e){var t=f.createElement("div");try{return!!e(t)}catch(n){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function pt(e,t,n){e=e.split("|");var r,i=e.length,a=n?null:t;while(i--)(r=o.attrHandle[e[i]])&&r!==t||(o.attrHandle[e[i]]=a)}function ft(e,t){var n=e.getAttributeNode(t);return n&&n.specified?n.value:e[t]===!0?t.toLowerCase():null}function dt(e,t){return e.getAttribute(t,"type"===t.toLowerCase()?1:2)}function ht(e){return"input"===e.nodeName.toLowerCase()?e.defaultValue:t}function gt(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&(~t.sourceIndex||D)-(~e.sourceIndex||D);if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function mt(e){return function(t){var n=t.nodeName.toLowerCase();return"input"===n&&t.type===e}}function yt(e){return function(t){var n=t.nodeName.toLowerCase();return("input"===n||"button"===n)&&t.type===e}}function vt(e){return ut(function(t){return t=+t,ut(function(n,r){var i,o=e([],n.length,t),a=o.length;while(a--)n[i=o[a]]&&(n[i]=!(r[i]=n[i]))})})}s=at.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return t?"HTML"!==t.nodeName:!1},r=at.support={},p=at.setDocument=function(e){var n=e?e.ownerDocument||e:w,i=n.parentWindow;return n!==f&&9===n.nodeType&&n.documentElement?(f=n,d=n.documentElement,h=!s(n),i&&i.frameElement&&i.attachEvent("onbeforeunload",function(){p()}),r.attributes=ct(function(e){return e.innerHTML="<a href='#'></a>",pt("type|href|height|width",dt,"#"===e.firstChild.getAttribute("href")),pt(B,ft,null==e.getAttribute("disabled")),e.className="i",!e.getAttribute("className")}),r.input=ct(function(e){return e.innerHTML="<input>",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")}),pt("value",ht,r.attributes&&r.input),r.getElementsByTagName=ct(function(e){return e.appendChild(n.createComment("")),!e.getElementsByTagName("*").length}),r.getElementsByClassName=ct(function(e){return e.innerHTML="<div class='a'></div><div class='a i'></div>",e.firstChild.className="i",2===e.getElementsByClassName("i").length}),r.getById=ct(function(e){return d.appendChild(e).id=b,!n.getElementsByName||!n.getElementsByName(b).length}),r.getById?(o.find.ID=function(e,t){if(typeof t.getElementById!==j&&h){var n=t.getElementById(e);return n&&n.parentNode?[n]:[]}},o.filter.ID=function(e){var t=e.replace(rt,it);return function(e){return e.getAttribute("id")===t}}):(delete o.find.ID,o.filter.ID=function(e){var t=e.replace(rt,it);return function(e){var n=typeof e.getAttributeNode!==j&&e.getAttributeNode("id");return n&&n.value===t}}),o.find.TAG=r.getElementsByTagName?function(e,n){return typeof n.getElementsByTagName!==j?n.getElementsByTagName(e):t}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},o.find.CLASS=r.getElementsByClassName&&function(e,n){return typeof n.getElementsByClassName!==j&&h?n.getElementsByClassName(e):t},m=[],g=[],(r.qsa=st(n.querySelectorAll))&&(ct(function(e){e.innerHTML="<select><option selected=''></option></select>",e.querySelectorAll("[selected]").length||g.push("\\["+P+"*(?:value|"+B+")"),e.querySelectorAll(":checked").length||g.push(":checked")}),ct(function(e){var t=n.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("t",""),e.querySelectorAll("[t^='']").length&&g.push("[*^$]="+P+"*(?:''|\"\")"),e.querySelectorAll(":enabled").length||g.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),g.push(",.*:")})),(r.matchesSelector=st(y=d.webkitMatchesSelector||d.mozMatchesSelector||d.oMatchesSelector||d.msMatchesSelector))&&ct(function(e){r.disconnectedMatch=y.call(e,"div"),y.call(e,"[s!='']:x"),m.push("!=",I)}),g=g.length&&RegExp(g.join("|")),m=m.length&&RegExp(m.join("|")),v=st(d.contains)||d.compareDocumentPosition?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},r.sortDetached=ct(function(e){return 1&e.compareDocumentPosition(n.createElement("div"))}),A=d.compareDocumentPosition?function(e,t){if(e===t)return S=!0,0;var i=t.compareDocumentPosition&&e.compareDocumentPosition&&e.compareDocumentPosition(t);return i?1&i||!r.sortDetached&&t.compareDocumentPosition(e)===i?e===n||v(w,e)?-1:t===n||v(w,t)?1:c?F.call(c,e)-F.call(c,t):0:4&i?-1:1:e.compareDocumentPosition?-1:1}:function(e,t){var r,i=0,o=e.parentNode,a=t.parentNode,s=[e],l=[t];if(e===t)return S=!0,0;if(!o||!a)return e===n?-1:t===n?1:o?-1:a?1:c?F.call(c,e)-F.call(c,t):0;if(o===a)return gt(e,t);r=e;while(r=r.parentNode)s.unshift(r);r=t;while(r=r.parentNode)l.unshift(r);while(s[i]===l[i])i++;return i?gt(s[i],l[i]):s[i]===w?-1:l[i]===w?1:0},n):f},at.matches=function(e,t){return at(e,null,null,t)},at.matchesSelector=function(e,t){if((e.ownerDocument||e)!==f&&p(e),t=t.replace(Y,"='$1']"),!(!r.matchesSelector||!h||m&&m.test(t)||g&&g.test(t)))try{var n=y.call(e,t);if(n||r.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(i){}return at(t,f,null,[e]).length>0},at.contains=function(e,t){return(e.ownerDocument||e)!==f&&p(e),v(e,t)},at.attr=function(e,n){(e.ownerDocument||e)!==f&&p(e);var i=o.attrHandle[n.toLowerCase()],a=i&&L.call(o.attrHandle,n.toLowerCase())?i(e,n,!h):t;return a===t?r.attributes||!h?e.getAttribute(n):(a=e.getAttributeNode(n))&&a.specified?a.value:null:a},at.error=function(e){throw Error("Syntax error, unrecognized expression: "+e)},at.uniqueSort=function(e){var t,n=[],i=0,o=0;if(S=!r.detectDuplicates,c=!r.sortStable&&e.slice(0),e.sort(A),S){while(t=e[o++])t===e[o]&&(i=n.push(o));while(i--)e.splice(n[i],1)}return e},a=at.getText=function(e){var t,n="",r=0,i=e.nodeType;if(i){if(1===i||9===i||11===i){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=a(e)}else if(3===i||4===i)return e.nodeValue}else for(;t=e[r];r++)n+=a(t);return n},o=at.selectors={cacheLength:50,createPseudo:ut,match:Q,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(rt,it),e[3]=(e[4]||e[5]||"").replace(rt,it),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||at.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&at.error(e[0]),e},PSEUDO:function(e){var n,r=!e[5]&&e[2];return Q.CHILD.test(e[0])?null:(e[3]&&e[4]!==t?e[2]=e[4]:r&&J.test(r)&&(n=bt(r,!0))&&(n=r.indexOf(")",r.length-n)-r.length)&&(e[0]=e[0].slice(0,n),e[2]=r.slice(0,n)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(rt,it).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=N[e+" "];return t||(t=RegExp("(^|"+P+")"+e+"("+P+"|$)"))&&N(e,function(e){return t.test("string"==typeof e.className&&e.className||typeof e.getAttribute!==j&&e.getAttribute("class")||"")})},ATTR:function(e,t,n){return function(r){var i=at.attr(r,e);return null==i?"!="===t:t?(i+="","="===t?i===n:"!="===t?i!==n:"^="===t?n&&0===i.indexOf(n):"*="===t?n&&i.indexOf(n)>-1:"$="===t?n&&i.slice(-n.length)===n:"~="===t?(" "+i+" ").indexOf(n)>-1:"|="===t?i===n||i.slice(0,n.length+1)===n+"-":!1):!0}},CHILD:function(e,t,n,r,i){var o="nth"!==e.slice(0,3),a="last"!==e.slice(-4),s="of-type"===t;return 1===r&&0===i?function(e){return!!e.parentNode}:function(t,n,l){var u,c,p,f,d,h,g=o!==a?"nextSibling":"previousSibling",m=t.parentNode,y=s&&t.nodeName.toLowerCase(),v=!l&&!s;if(m){if(o){while(g){p=t;while(p=p[g])if(s?p.nodeName.toLowerCase()===y:1===p.nodeType)return!1;h=g="only"===e&&!h&&"nextSibling"}return!0}if(h=[a?m.firstChild:m.lastChild],a&&v){c=m[b]||(m[b]={}),u=c[e]||[],d=u[0]===T&&u[1],f=u[0]===T&&u[2],p=d&&m.childNodes[d];while(p=++d&&p&&p[g]||(f=d=0)||h.pop())if(1===p.nodeType&&++f&&p===t){c[e]=[T,d,f];break}}else if(v&&(u=(t[b]||(t[b]={}))[e])&&u[0]===T)f=u[1];else while(p=++d&&p&&p[g]||(f=d=0)||h.pop())if((s?p.nodeName.toLowerCase()===y:1===p.nodeType)&&++f&&(v&&((p[b]||(p[b]={}))[e]=[T,f]),p===t))break;return f-=i,f===r||0===f%r&&f/r>=0}}},PSEUDO:function(e,t){var n,r=o.pseudos[e]||o.setFilters[e.toLowerCase()]||at.error("unsupported pseudo: "+e);return r[b]?r(t):r.length>1?(n=[e,e,"",t],o.setFilters.hasOwnProperty(e.toLowerCase())?ut(function(e,n){var i,o=r(e,t),a=o.length;while(a--)i=F.call(e,o[a]),e[i]=!(n[i]=o[a])}):function(e){return r(e,0,n)}):r}},pseudos:{not:ut(function(e){var t=[],n=[],r=l(e.replace(z,"$1"));return r[b]?ut(function(e,t,n,i){var o,a=r(e,null,i,[]),s=e.length;while(s--)(o=a[s])&&(e[s]=!(t[s]=o))}):function(e,i,o){return t[0]=e,r(t,null,o,n),!n.pop()}}),has:ut(function(e){return function(t){return at(e,t).length>0}}),contains:ut(function(e){return function(t){return(t.textContent||t.innerText||a(t)).indexOf(e)>-1}}),lang:ut(function(e){return G.test(e||"")||at.error("unsupported lang: "+e),e=e.replace(rt,it).toLowerCase(),function(t){var n;do if(n=h?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return n=n.toLowerCase(),n===e||0===n.indexOf(e+"-");while((t=t.parentNode)&&1===t.nodeType);return!1}}),target:function(t){var n=e.location&&e.location.hash;return n&&n.slice(1)===t.id},root:function(e){return e===d},focus:function(e){return e===f.activeElement&&(!f.hasFocus||f.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:function(e){return e.disabled===!1},disabled:function(e){return e.disabled===!0},checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,e.selected===!0},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeName>"@"||3===e.nodeType||4===e.nodeType)return!1;return!0},parent:function(e){return!o.pseudos.empty(e)},header:function(e){return tt.test(e.nodeName)},input:function(e){return et.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||t.toLowerCase()===e.type)},first:vt(function(){return[0]}),last:vt(function(e,t){return[t-1]}),eq:vt(function(e,t,n){return[0>n?n+t:n]}),even:vt(function(e,t){var n=0;for(;t>n;n+=2)e.push(n);return e}),odd:vt(function(e,t){var n=1;for(;t>n;n+=2)e.push(n);return e}),lt:vt(function(e,t,n){var r=0>n?n+t:n;for(;--r>=0;)e.push(r);return e}),gt:vt(function(e,t,n){var r=0>n?n+t:n;for(;t>++r;)e.push(r);return e})}};for(n in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})o.pseudos[n]=mt(n);for(n in{submit:!0,reset:!0})o.pseudos[n]=yt(n);function bt(e,t){var n,r,i,a,s,l,u,c=k[e+" "];if(c)return t?0:c.slice(0);s=e,l=[],u=o.preFilter;while(s){(!n||(r=X.exec(s)))&&(r&&(s=s.slice(r[0].length)||s),l.push(i=[])),n=!1,(r=U.exec(s))&&(n=r.shift(),i.push({value:n,type:r[0].replace(z," ")}),s=s.slice(n.length));for(a in o.filter)!(r=Q[a].exec(s))||u[a]&&!(r=u[a](r))||(n=r.shift(),i.push({value:n,type:a,matches:r}),s=s.slice(n.length));if(!n)break}return t?s.length:s?at.error(e):k(e,l).slice(0)}function xt(e){var t=0,n=e.length,r="";for(;n>t;t++)r+=e[t].value;return r}function wt(e,t,n){var r=t.dir,o=n&&"parentNode"===r,a=C++;return t.first?function(t,n,i){while(t=t[r])if(1===t.nodeType||o)return e(t,n,i)}:function(t,n,s){var l,u,c,p=T+" "+a;if(s){while(t=t[r])if((1===t.nodeType||o)&&e(t,n,s))return!0}else while(t=t[r])if(1===t.nodeType||o)if(c=t[b]||(t[b]={}),(u=c[r])&&u[0]===p){if((l=u[1])===!0||l===i)return l===!0}else if(u=c[r]=[p],u[1]=e(t,n,s)||i,u[1]===!0)return!0}}function Tt(e){return e.length>1?function(t,n,r){var i=e.length;while(i--)if(!e[i](t,n,r))return!1;return!0}:e[0]}function Ct(e,t,n,r,i){var o,a=[],s=0,l=e.length,u=null!=t;for(;l>s;s++)(o=e[s])&&(!n||n(o,r,i))&&(a.push(o),u&&t.push(s));return a}function Nt(e,t,n,r,i,o){return r&&!r[b]&&(r=Nt(r)),i&&!i[b]&&(i=Nt(i,o)),ut(function(o,a,s,l){var u,c,p,f=[],d=[],h=a.length,g=o||St(t||"*",s.nodeType?[s]:s,[]),m=!e||!o&&t?g:Ct(g,f,e,s,l),y=n?i||(o?e:h||r)?[]:a:m;if(n&&n(m,y,s,l),r){u=Ct(y,d),r(u,[],s,l),c=u.length;while(c--)(p=u[c])&&(y[d[c]]=!(m[d[c]]=p))}if(o){if(i||e){if(i){u=[],c=y.length;while(c--)(p=y[c])&&u.push(m[c]=p);i(null,y=[],u,l)}c=y.length;while(c--)(p=y[c])&&(u=i?F.call(o,p):f[c])>-1&&(o[u]=!(a[u]=p))}}else y=Ct(y===a?y.splice(h,y.length):y),i?i(null,a,y,l):M.apply(a,y)})}function kt(e){var t,n,r,i=e.length,a=o.relative[e[0].type],s=a||o.relative[" "],l=a?1:0,c=wt(function(e){return e===t},s,!0),p=wt(function(e){return F.call(t,e)>-1},s,!0),f=[function(e,n,r){return!a&&(r||n!==u)||((t=n).nodeType?c(e,n,r):p(e,n,r))}];for(;i>l;l++)if(n=o.relative[e[l].type])f=[wt(Tt(f),n)];else{if(n=o.filter[e[l].type].apply(null,e[l].matches),n[b]){for(r=++l;i>r;r++)if(o.relative[e[r].type])break;return Nt(l>1&&Tt(f),l>1&&xt(e.slice(0,l-1).concat({value:" "===e[l-2].type?"*":""})).replace(z,"$1"),n,r>l&&kt(e.slice(l,r)),i>r&&kt(e=e.slice(r)),i>r&&xt(e))}f.push(n)}return Tt(f)}function Et(e,t){var n=0,r=t.length>0,a=e.length>0,s=function(s,l,c,p,d){var h,g,m,y=[],v=0,b="0",x=s&&[],w=null!=d,C=u,N=s||a&&o.find.TAG("*",d&&l.parentNode||l),k=T+=null==C?1:Math.random()||.1;for(w&&(u=l!==f&&l,i=n);null!=(h=N[b]);b++){if(a&&h){g=0;while(m=e[g++])if(m(h,l,c)){p.push(h);break}w&&(T=k,i=++n)}r&&((h=!m&&h)&&v--,s&&x.push(h))}if(v+=b,r&&b!==v){g=0;while(m=t[g++])m(x,y,l,c);if(s){if(v>0)while(b--)x[b]||y[b]||(y[b]=q.call(p));y=Ct(y)}M.apply(p,y),w&&!s&&y.length>0&&v+t.length>1&&at.uniqueSort(p)}return w&&(T=k,u=C),x};return r?ut(s):s}l=at.compile=function(e,t){var n,r=[],i=[],o=E[e+" "];if(!o){t||(t=bt(e)),n=t.length;while(n--)o=kt(t[n]),o[b]?r.push(o):i.push(o);o=E(e,Et(i,r))}return o};function St(e,t,n){var r=0,i=t.length;for(;i>r;r++)at(e,t[r],n);return n}function At(e,t,n,i){var a,s,u,c,p,f=bt(e);if(!i&&1===f.length){if(s=f[0]=f[0].slice(0),s.length>2&&"ID"===(u=s[0]).type&&r.getById&&9===t.nodeType&&h&&o.relative[s[1].type]){if(t=(o.find.ID(u.matches[0].replace(rt,it),t)||[])[0],!t)return n;e=e.slice(s.shift().value.length)}a=Q.needsContext.test(e)?0:s.length;while(a--){if(u=s[a],o.relative[c=u.type])break;if((p=o.find[c])&&(i=p(u.matches[0].replace(rt,it),V.test(s[0].type)&&t.parentNode||t))){if(s.splice(a,1),e=i.length&&xt(s),!e)return M.apply(n,i),n;break}}}return l(e,f)(i,t,!h,n,V.test(e)),n}o.pseudos.nth=o.pseudos.eq;function jt(){}jt.prototype=o.filters=o.pseudos,o.setFilters=new jt,r.sortStable=b.split("").sort(A).join("")===b,p(),[0,0].sort(A),r.detectDuplicates=S,x.find=at,x.expr=at.selectors,x.expr[":"]=x.expr.pseudos,x.unique=at.uniqueSort,x.text=at.getText,x.isXMLDoc=at.isXML,x.contains=at.contains}(e);var O={};function F(e){var t=O[e]={};return x.each(e.match(T)||[],function(e,n){t[n]=!0}),t}x.Callbacks=function(e){e="string"==typeof e?O[e]||F(e):x.extend({},e);var n,r,i,o,a,s,l=[],u=!e.once&&[],c=function(t){for(r=e.memory&&t,i=!0,a=s||0,s=0,o=l.length,n=!0;l&&o>a;a++)if(l[a].apply(t[0],t[1])===!1&&e.stopOnFalse){r=!1;break}n=!1,l&&(u?u.length&&c(u.shift()):r?l=[]:p.disable())},p={add:function(){if(l){var t=l.length;(function i(t){x.each(t,function(t,n){var r=x.type(n);"function"===r?e.unique&&p.has(n)||l.push(n):n&&n.length&&"string"!==r&&i(n)})})(arguments),n?o=l.length:r&&(s=t,c(r))}return this},remove:function(){return l&&x.each(arguments,function(e,t){var r;while((r=x.inArray(t,l,r))>-1)l.splice(r,1),n&&(o>=r&&o--,a>=r&&a--)}),this},has:function(e){return e?x.inArray(e,l)>-1:!(!l||!l.length)},empty:function(){return l=[],o=0,this},disable:function(){return l=u=r=t,this},disabled:function(){return!l},lock:function(){return u=t,r||p.disable(),this},locked:function(){return!u},fireWith:function(e,t){return t=t||[],t=[e,t.slice?t.slice():t],!l||i&&!u||(n?u.push(t):c(t)),this},fire:function(){return p.fireWith(this,arguments),this},fired:function(){return!!i}};return p},x.extend({Deferred:function(e){var t=[["resolve","done",x.Callbacks("once memory"),"resolved"],["reject","fail",x.Callbacks("once memory"),"rejected"],["notify","progress",x.Callbacks("memory")]],n="pending",r={state:function(){return n},always:function(){return i.done(arguments).fail(arguments),this},then:function(){var e=arguments;return x.Deferred(function(n){x.each(t,function(t,o){var a=o[0],s=x.isFunction(e[t])&&e[t];i[o[1]](function(){var e=s&&s.apply(this,arguments);e&&x.isFunction(e.promise)?e.promise().done(n.resolve).fail(n.reject).progress(n.notify):n[a+"With"](this===r?n.promise():this,s?[e]:arguments)})}),e=null}).promise()},promise:function(e){return null!=e?x.extend(e,r):r}},i={};return r.pipe=r.then,x.each(t,function(e,o){var a=o[2],s=o[3];r[o[1]]=a.add,s&&a.add(function(){n=s},t[1^e][2].disable,t[2][2].lock),i[o[0]]=function(){return i[o[0]+"With"](this===i?r:this,arguments),this},i[o[0]+"With"]=a.fireWith}),r.promise(i),e&&e.call(i,i),i},when:function(e){var t=0,n=g.call(arguments),r=n.length,i=1!==r||e&&x.isFunction(e.promise)?r:0,o=1===i?e:x.Deferred(),a=function(e,t,n){return function(r){t[e]=this,n[e]=arguments.length>1?g.call(arguments):r,n===s?o.notifyWith(t,n):--i||o.resolveWith(t,n)}},s,l,u;if(r>1)for(s=Array(r),l=Array(r),u=Array(r);r>t;t++)n[t]&&x.isFunction(n[t].promise)?n[t].promise().done(a(t,u,n)).fail(o.reject).progress(a(t,l,s)):--i;return i||o.resolveWith(u,n),o.promise()}}),x.support=function(t){var n,r,o,s,l,u,c,p,f,d=a.createElement("div");if(d.setAttribute("className","t"),d.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",n=d.getElementsByTagName("*")||[],r=d.getElementsByTagName("a")[0],!r||!r.style||!n.length)return t;s=a.createElement("select"),u=s.appendChild(a.createElement("option")),o=d.getElementsByTagName("input")[0],r.style.cssText="top:1px;float:left;opacity:.5",t.getSetAttribute="t"!==d.className,t.leadingWhitespace=3===d.firstChild.nodeType,t.tbody=!d.getElementsByTagName("tbody").length,t.htmlSerialize=!!d.getElementsByTagName("link").length,t.style=/top/.test(r.getAttribute("style")),t.hrefNormalized="/a"===r.getAttribute("href"),t.opacity=/^0.5/.test(r.style.opacity),t.cssFloat=!!r.style.cssFloat,t.checkOn=!!o.value,t.optSelected=u.selected,t.enctype=!!a.createElement("form").enctype,t.html5Clone="<:nav></:nav>"!==a.createElement("nav").cloneNode(!0).outerHTML,t.inlineBlockNeedsLayout=!1,t.shrinkWrapBlocks=!1,t.pixelPosition=!1,t.deleteExpando=!0,t.noCloneEvent=!0,t.reliableMarginRight=!0,t.boxSizingReliable=!0,o.checked=!0,t.noCloneChecked=o.cloneNode(!0).checked,s.disabled=!0,t.optDisabled=!u.disabled;try{delete d.test}catch(h){t.deleteExpando=!1}o=a.createElement("input"),o.setAttribute("value",""),t.input=""===o.getAttribute("value"),o.value="t",o.setAttribute("type","radio"),t.radioValue="t"===o.value,o.setAttribute("checked","t"),o.setAttribute("name","t"),l=a.createDocumentFragment(),l.appendChild(o),t.appendChecked=o.checked,t.checkClone=l.cloneNode(!0).cloneNode(!0).lastChild.checked,d.attachEvent&&(d.attachEvent("onclick",function(){t.noCloneEvent=!1}),d.cloneNode(!0).click());for(f in{submit:!0,change:!0,focusin:!0})d.setAttribute(c="on"+f,"t"),t[f+"Bubbles"]=c in e||d.attributes[c].expando===!1;d.style.backgroundClip="content-box",d.cloneNode(!0).style.backgroundClip="",t.clearCloneStyle="content-box"===d.style.backgroundClip;for(f in x(t))break;return t.ownLast="0"!==f,x(function(){var n,r,o,s="padding:0;margin:0;border:0;display:block;box-sizing:content-box;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;",l=a.getElementsByTagName("body")[0];l&&(n=a.createElement("div"),n.style.cssText="border:0;width:0;height:0;position:absolute;top:0;left:-9999px;margin-top:1px",l.appendChild(n).appendChild(d),d.innerHTML="<table><tr><td></td><td>t</td></tr></table>",o=d.getElementsByTagName("td"),o[0].style.cssText="padding:0;margin:0;border:0;display:none",p=0===o[0].offsetHeight,o[0].style.display="",o[1].style.display="none",t.reliableHiddenOffsets=p&&0===o[0].offsetHeight,d.innerHTML="",d.style.cssText="box-sizing:border-box;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;padding:1px;border:1px;display:block;width:4px;margin-top:1%;position:absolute;top:1%;",x.swap(l,null!=l.style.zoom?{zoom:1}:{},function(){t.boxSizing=4===d.offsetWidth}),e.getComputedStyle&&(t.pixelPosition="1%"!==(e.getComputedStyle(d,null)||{}).top,t.boxSizingReliable="4px"===(e.getComputedStyle(d,null)||{width:"4px"}).width,r=d.appendChild(a.createElement("div")),r.style.cssText=d.style.cssText=s,r.style.marginRight=r.style.width="0",d.style.width="1px",t.reliableMarginRight=!parseFloat((e.getComputedStyle(r,null)||{}).marginRight)),typeof d.style.zoom!==i&&(d.innerHTML="",d.style.cssText=s+"width:1px;padding:1px;display:inline;zoom:1",t.inlineBlockNeedsLayout=3===d.offsetWidth,d.style.display="block",d.innerHTML="<div></div>",d.firstChild.style.width="5px",t.shrinkWrapBlocks=3!==d.offsetWidth,t.inlineBlockNeedsLayout&&(l.style.zoom=1)),l.removeChild(n),n=d=o=r=null) }),n=s=l=u=r=o=null,t}({});var B=/(?:\{[\s\S]*\}|\[[\s\S]*\])$/,P=/([A-Z])/g;function R(e,n,r,i){if(x.acceptData(e)){var o,a,s=x.expando,l=e.nodeType,u=l?x.cache:e,c=l?e[s]:e[s]&&s;if(c&&u[c]&&(i||u[c].data)||r!==t||"string"!=typeof n)return c||(c=l?e[s]=p.pop()||x.guid++:s),u[c]||(u[c]=l?{}:{toJSON:x.noop}),("object"==typeof n||"function"==typeof n)&&(i?u[c]=x.extend(u[c],n):u[c].data=x.extend(u[c].data,n)),a=u[c],i||(a.data||(a.data={}),a=a.data),r!==t&&(a[x.camelCase(n)]=r),"string"==typeof n?(o=a[n],null==o&&(o=a[x.camelCase(n)])):o=a,o}}function W(e,t,n){if(x.acceptData(e)){var r,i,o=e.nodeType,a=o?x.cache:e,s=o?e[x.expando]:x.expando;if(a[s]){if(t&&(r=n?a[s]:a[s].data)){x.isArray(t)?t=t.concat(x.map(t,x.camelCase)):t in r?t=[t]:(t=x.camelCase(t),t=t in r?[t]:t.split(" ")),i=t.length;while(i--)delete r[t[i]];if(n?!I(r):!x.isEmptyObject(r))return}(n||(delete a[s].data,I(a[s])))&&(o?x.cleanData([e],!0):x.support.deleteExpando||a!=a.window?delete a[s]:a[s]=null)}}}x.extend({cache:{},noData:{applet:!0,embed:!0,object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"},hasData:function(e){return e=e.nodeType?x.cache[e[x.expando]]:e[x.expando],!!e&&!I(e)},data:function(e,t,n){return R(e,t,n)},removeData:function(e,t){return W(e,t)},_data:function(e,t,n){return R(e,t,n,!0)},_removeData:function(e,t){return W(e,t,!0)},acceptData:function(e){if(e.nodeType&&1!==e.nodeType&&9!==e.nodeType)return!1;var t=e.nodeName&&x.noData[e.nodeName.toLowerCase()];return!t||t!==!0&&e.getAttribute("classid")===t}}),x.fn.extend({data:function(e,n){var r,i,o=null,a=0,s=this[0];if(e===t){if(this.length&&(o=x.data(s),1===s.nodeType&&!x._data(s,"parsedAttrs"))){for(r=s.attributes;r.length>a;a++)i=r[a].name,0===i.indexOf("data-")&&(i=x.camelCase(i.slice(5)),$(s,i,o[i]));x._data(s,"parsedAttrs",!0)}return o}return"object"==typeof e?this.each(function(){x.data(this,e)}):arguments.length>1?this.each(function(){x.data(this,e,n)}):s?$(s,e,x.data(s,e)):null},removeData:function(e){return this.each(function(){x.removeData(this,e)})}});function $(e,n,r){if(r===t&&1===e.nodeType){var i="data-"+n.replace(P,"-$1").toLowerCase();if(r=e.getAttribute(i),"string"==typeof r){try{r="true"===r?!0:"false"===r?!1:"null"===r?null:+r+""===r?+r:B.test(r)?x.parseJSON(r):r}catch(o){}x.data(e,n,r)}else r=t}return r}function I(e){var t;for(t in e)if(("data"!==t||!x.isEmptyObject(e[t]))&&"toJSON"!==t)return!1;return!0}x.extend({queue:function(e,n,r){var i;return e?(n=(n||"fx")+"queue",i=x._data(e,n),r&&(!i||x.isArray(r)?i=x._data(e,n,x.makeArray(r)):i.push(r)),i||[]):t},dequeue:function(e,t){t=t||"fx";var n=x.queue(e,t),r=n.length,i=n.shift(),o=x._queueHooks(e,t),a=function(){x.dequeue(e,t)};"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===t&&n.unshift("inprogress"),delete o.stop,i.call(e,a,o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return x._data(e,n)||x._data(e,n,{empty:x.Callbacks("once memory").add(function(){x._removeData(e,t+"queue"),x._removeData(e,n)})})}}),x.fn.extend({queue:function(e,n){var r=2;return"string"!=typeof e&&(n=e,e="fx",r--),r>arguments.length?x.queue(this[0],e):n===t?this:this.each(function(){var t=x.queue(this,e,n);x._queueHooks(this,e),"fx"===e&&"inprogress"!==t[0]&&x.dequeue(this,e)})},dequeue:function(e){return this.each(function(){x.dequeue(this,e)})},delay:function(e,t){return e=x.fx?x.fx.speeds[e]||e:e,t=t||"fx",this.queue(t,function(t,n){var r=setTimeout(t,e);n.stop=function(){clearTimeout(r)}})},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,n){var r,i=1,o=x.Deferred(),a=this,s=this.length,l=function(){--i||o.resolveWith(a,[a])};"string"!=typeof e&&(n=e,e=t),e=e||"fx";while(s--)r=x._data(a[s],e+"queueHooks"),r&&r.empty&&(i++,r.empty.add(l));return l(),o.promise(n)}});var z,X,U=/[\t\r\n\f]/g,V=/\r/g,Y=/^(?:input|select|textarea|button|object)$/i,J=/^(?:a|area)$/i,G=/^(?:checked|selected)$/i,Q=x.support.getSetAttribute,K=x.support.input;x.fn.extend({attr:function(e,t){return x.access(this,x.attr,e,t,arguments.length>1)},removeAttr:function(e){return this.each(function(){x.removeAttr(this,e)})},prop:function(e,t){return x.access(this,x.prop,e,t,arguments.length>1)},removeProp:function(e){return e=x.propFix[e]||e,this.each(function(){try{this[e]=t,delete this[e]}catch(n){}})},addClass:function(e){var t,n,r,i,o,a=0,s=this.length,l="string"==typeof e&&e;if(x.isFunction(e))return this.each(function(t){x(this).addClass(e.call(this,t,this.className))});if(l)for(t=(e||"").match(T)||[];s>a;a++)if(n=this[a],r=1===n.nodeType&&(n.className?(" "+n.className+" ").replace(U," "):" ")){o=0;while(i=t[o++])0>r.indexOf(" "+i+" ")&&(r+=i+" ");n.className=x.trim(r)}return this},removeClass:function(e){var t,n,r,i,o,a=0,s=this.length,l=0===arguments.length||"string"==typeof e&&e;if(x.isFunction(e))return this.each(function(t){x(this).removeClass(e.call(this,t,this.className))});if(l)for(t=(e||"").match(T)||[];s>a;a++)if(n=this[a],r=1===n.nodeType&&(n.className?(" "+n.className+" ").replace(U," "):"")){o=0;while(i=t[o++])while(r.indexOf(" "+i+" ")>=0)r=r.replace(" "+i+" "," ");n.className=e?x.trim(r):""}return this},toggleClass:function(e,t){var n=typeof e,r="boolean"==typeof t;return x.isFunction(e)?this.each(function(n){x(this).toggleClass(e.call(this,n,this.className,t),t)}):this.each(function(){if("string"===n){var o,a=0,s=x(this),l=t,u=e.match(T)||[];while(o=u[a++])l=r?l:!s.hasClass(o),s[l?"addClass":"removeClass"](o)}else(n===i||"boolean"===n)&&(this.className&&x._data(this,"__className__",this.className),this.className=this.className||e===!1?"":x._data(this,"__className__")||"")})},hasClass:function(e){var t=" "+e+" ",n=0,r=this.length;for(;r>n;n++)if(1===this[n].nodeType&&(" "+this[n].className+" ").replace(U," ").indexOf(t)>=0)return!0;return!1},val:function(e){var n,r,i,o=this[0];{if(arguments.length)return i=x.isFunction(e),this.each(function(n){var o;1===this.nodeType&&(o=i?e.call(this,n,x(this).val()):e,null==o?o="":"number"==typeof o?o+="":x.isArray(o)&&(o=x.map(o,function(e){return null==e?"":e+""})),r=x.valHooks[this.type]||x.valHooks[this.nodeName.toLowerCase()],r&&"set"in r&&r.set(this,o,"value")!==t||(this.value=o))});if(o)return r=x.valHooks[o.type]||x.valHooks[o.nodeName.toLowerCase()],r&&"get"in r&&(n=r.get(o,"value"))!==t?n:(n=o.value,"string"==typeof n?n.replace(V,""):null==n?"":n)}}}),x.extend({valHooks:{option:{get:function(e){var t=x.find.attr(e,"value");return null!=t?t:e.text}},select:{get:function(e){var t,n,r=e.options,i=e.selectedIndex,o="select-one"===e.type||0>i,a=o?null:[],s=o?i+1:r.length,l=0>i?s:o?i:0;for(;s>l;l++)if(n=r[l],!(!n.selected&&l!==i||(x.support.optDisabled?n.disabled:null!==n.getAttribute("disabled"))||n.parentNode.disabled&&x.nodeName(n.parentNode,"optgroup"))){if(t=x(n).val(),o)return t;a.push(t)}return a},set:function(e,t){var n,r,i=e.options,o=x.makeArray(t),a=i.length;while(a--)r=i[a],(r.selected=x.inArray(x(r).val(),o)>=0)&&(n=!0);return n||(e.selectedIndex=-1),o}}},attr:function(e,n,r){var o,a,s=e.nodeType;if(e&&3!==s&&8!==s&&2!==s)return typeof e.getAttribute===i?x.prop(e,n,r):(1===s&&x.isXMLDoc(e)||(n=n.toLowerCase(),o=x.attrHooks[n]||(x.expr.match.bool.test(n)?X:z)),r===t?o&&"get"in o&&null!==(a=o.get(e,n))?a:(a=x.find.attr(e,n),null==a?t:a):null!==r?o&&"set"in o&&(a=o.set(e,r,n))!==t?a:(e.setAttribute(n,r+""),r):(x.removeAttr(e,n),t))},removeAttr:function(e,t){var n,r,i=0,o=t&&t.match(T);if(o&&1===e.nodeType)while(n=o[i++])r=x.propFix[n]||n,x.expr.match.bool.test(n)?K&&Q||!G.test(n)?e[r]=!1:e[x.camelCase("default-"+n)]=e[r]=!1:x.attr(e,n,""),e.removeAttribute(Q?n:r)},attrHooks:{type:{set:function(e,t){if(!x.support.radioValue&&"radio"===t&&x.nodeName(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}},propFix:{"for":"htmlFor","class":"className"},prop:function(e,n,r){var i,o,a,s=e.nodeType;if(e&&3!==s&&8!==s&&2!==s)return a=1!==s||!x.isXMLDoc(e),a&&(n=x.propFix[n]||n,o=x.propHooks[n]),r!==t?o&&"set"in o&&(i=o.set(e,r,n))!==t?i:e[n]=r:o&&"get"in o&&null!==(i=o.get(e,n))?i:e[n]},propHooks:{tabIndex:{get:function(e){var t=x.find.attr(e,"tabindex");return t?parseInt(t,10):Y.test(e.nodeName)||J.test(e.nodeName)&&e.href?0:-1}}}}),X={set:function(e,t,n){return t===!1?x.removeAttr(e,n):K&&Q||!G.test(n)?e.setAttribute(!Q&&x.propFix[n]||n,n):e[x.camelCase("default-"+n)]=e[n]=!0,n}},x.each(x.expr.match.bool.source.match(/\w+/g),function(e,n){var r=x.expr.attrHandle[n]||x.find.attr;x.expr.attrHandle[n]=K&&Q||!G.test(n)?function(e,n,i){var o=x.expr.attrHandle[n],a=i?t:(x.expr.attrHandle[n]=t)!=r(e,n,i)?n.toLowerCase():null;return x.expr.attrHandle[n]=o,a}:function(e,n,r){return r?t:e[x.camelCase("default-"+n)]?n.toLowerCase():null}}),K&&Q||(x.attrHooks.value={set:function(e,n,r){return x.nodeName(e,"input")?(e.defaultValue=n,t):z&&z.set(e,n,r)}}),Q||(z={set:function(e,n,r){var i=e.getAttributeNode(r);return i||e.setAttributeNode(i=e.ownerDocument.createAttribute(r)),i.value=n+="","value"===r||n===e.getAttribute(r)?n:t}},x.expr.attrHandle.id=x.expr.attrHandle.name=x.expr.attrHandle.coords=function(e,n,r){var i;return r?t:(i=e.getAttributeNode(n))&&""!==i.value?i.value:null},x.valHooks.button={get:function(e,n){var r=e.getAttributeNode(n);return r&&r.specified?r.value:t},set:z.set},x.attrHooks.contenteditable={set:function(e,t,n){z.set(e,""===t?!1:t,n)}},x.each(["width","height"],function(e,n){x.attrHooks[n]={set:function(e,r){return""===r?(e.setAttribute(n,"auto"),r):t}}})),x.support.hrefNormalized||x.each(["href","src"],function(e,t){x.propHooks[t]={get:function(e){return e.getAttribute(t,4)}}}),x.support.style||(x.attrHooks.style={get:function(e){return e.style.cssText||t},set:function(e,t){return e.style.cssText=t+""}}),x.support.optSelected||(x.propHooks.selected={get:function(e){var t=e.parentNode;return t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex),null}}),x.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){x.propFix[this.toLowerCase()]=this}),x.support.enctype||(x.propFix.enctype="encoding"),x.each(["radio","checkbox"],function(){x.valHooks[this]={set:function(e,n){return x.isArray(n)?e.checked=x.inArray(x(e).val(),n)>=0:t}},x.support.checkOn||(x.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})});var Z=/^(?:input|select|textarea)$/i,et=/^key/,tt=/^(?:mouse|contextmenu)|click/,nt=/^(?:focusinfocus|focusoutblur)$/,rt=/^([^.]*)(?:\.(.+)|)$/;function it(){return!0}function ot(){return!1}function at(){try{return a.activeElement}catch(e){}}x.event={global:{},add:function(e,n,r,o,a){var s,l,u,c,p,f,d,h,g,m,y,v=x._data(e);if(v){r.handler&&(c=r,r=c.handler,a=c.selector),r.guid||(r.guid=x.guid++),(l=v.events)||(l=v.events={}),(f=v.handle)||(f=v.handle=function(e){return typeof x===i||e&&x.event.triggered===e.type?t:x.event.dispatch.apply(f.elem,arguments)},f.elem=e),n=(n||"").match(T)||[""],u=n.length;while(u--)s=rt.exec(n[u])||[],g=y=s[1],m=(s[2]||"").split(".").sort(),g&&(p=x.event.special[g]||{},g=(a?p.delegateType:p.bindType)||g,p=x.event.special[g]||{},d=x.extend({type:g,origType:y,data:o,handler:r,guid:r.guid,selector:a,needsContext:a&&x.expr.match.needsContext.test(a),namespace:m.join(".")},c),(h=l[g])||(h=l[g]=[],h.delegateCount=0,p.setup&&p.setup.call(e,o,m,f)!==!1||(e.addEventListener?e.addEventListener(g,f,!1):e.attachEvent&&e.attachEvent("on"+g,f))),p.add&&(p.add.call(e,d),d.handler.guid||(d.handler.guid=r.guid)),a?h.splice(h.delegateCount++,0,d):h.push(d),x.event.global[g]=!0);e=null}},remove:function(e,t,n,r,i){var o,a,s,l,u,c,p,f,d,h,g,m=x.hasData(e)&&x._data(e);if(m&&(c=m.events)){t=(t||"").match(T)||[""],u=t.length;while(u--)if(s=rt.exec(t[u])||[],d=g=s[1],h=(s[2]||"").split(".").sort(),d){p=x.event.special[d]||{},d=(r?p.delegateType:p.bindType)||d,f=c[d]||[],s=s[2]&&RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),l=o=f.length;while(o--)a=f[o],!i&&g!==a.origType||n&&n.guid!==a.guid||s&&!s.test(a.namespace)||r&&r!==a.selector&&("**"!==r||!a.selector)||(f.splice(o,1),a.selector&&f.delegateCount--,p.remove&&p.remove.call(e,a));l&&!f.length&&(p.teardown&&p.teardown.call(e,h,m.handle)!==!1||x.removeEvent(e,d,m.handle),delete c[d])}else for(d in c)x.event.remove(e,d+t[u],n,r,!0);x.isEmptyObject(c)&&(delete m.handle,x._removeData(e,"events"))}},trigger:function(n,r,i,o){var s,l,u,c,p,f,d,h=[i||a],g=v.call(n,"type")?n.type:n,m=v.call(n,"namespace")?n.namespace.split("."):[];if(u=f=i=i||a,3!==i.nodeType&&8!==i.nodeType&&!nt.test(g+x.event.triggered)&&(g.indexOf(".")>=0&&(m=g.split("."),g=m.shift(),m.sort()),l=0>g.indexOf(":")&&"on"+g,n=n[x.expando]?n:new x.Event(g,"object"==typeof n&&n),n.isTrigger=o?2:3,n.namespace=m.join("."),n.namespace_re=n.namespace?RegExp("(^|\\.)"+m.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,n.result=t,n.target||(n.target=i),r=null==r?[n]:x.makeArray(r,[n]),p=x.event.special[g]||{},o||!p.trigger||p.trigger.apply(i,r)!==!1)){if(!o&&!p.noBubble&&!x.isWindow(i)){for(c=p.delegateType||g,nt.test(c+g)||(u=u.parentNode);u;u=u.parentNode)h.push(u),f=u;f===(i.ownerDocument||a)&&h.push(f.defaultView||f.parentWindow||e)}d=0;while((u=h[d++])&&!n.isPropagationStopped())n.type=d>1?c:p.bindType||g,s=(x._data(u,"events")||{})[n.type]&&x._data(u,"handle"),s&&s.apply(u,r),s=l&&u[l],s&&x.acceptData(u)&&s.apply&&s.apply(u,r)===!1&&n.preventDefault();if(n.type=g,!o&&!n.isDefaultPrevented()&&(!p._default||p._default.apply(h.pop(),r)===!1)&&x.acceptData(i)&&l&&i[g]&&!x.isWindow(i)){f=i[l],f&&(i[l]=null),x.event.triggered=g;try{i[g]()}catch(y){}x.event.triggered=t,f&&(i[l]=f)}return n.result}},dispatch:function(e){e=x.event.fix(e);var n,r,i,o,a,s=[],l=g.call(arguments),u=(x._data(this,"events")||{})[e.type]||[],c=x.event.special[e.type]||{};if(l[0]=e,e.delegateTarget=this,!c.preDispatch||c.preDispatch.call(this,e)!==!1){s=x.event.handlers.call(this,e,u),n=0;while((o=s[n++])&&!e.isPropagationStopped()){e.currentTarget=o.elem,a=0;while((i=o.handlers[a++])&&!e.isImmediatePropagationStopped())(!e.namespace_re||e.namespace_re.test(i.namespace))&&(e.handleObj=i,e.data=i.data,r=((x.event.special[i.origType]||{}).handle||i.handler).apply(o.elem,l),r!==t&&(e.result=r)===!1&&(e.preventDefault(),e.stopPropagation()))}return c.postDispatch&&c.postDispatch.call(this,e),e.result}},handlers:function(e,n){var r,i,o,a,s=[],l=n.delegateCount,u=e.target;if(l&&u.nodeType&&(!e.button||"click"!==e.type))for(;u!=this;u=u.parentNode||this)if(1===u.nodeType&&(u.disabled!==!0||"click"!==e.type)){for(o=[],a=0;l>a;a++)i=n[a],r=i.selector+" ",o[r]===t&&(o[r]=i.needsContext?x(r,this).index(u)>=0:x.find(r,this,null,[u]).length),o[r]&&o.push(i);o.length&&s.push({elem:u,handlers:o})}return n.length>l&&s.push({elem:this,handlers:n.slice(l)}),s},fix:function(e){if(e[x.expando])return e;var t,n,r,i=e.type,o=e,s=this.fixHooks[i];s||(this.fixHooks[i]=s=tt.test(i)?this.mouseHooks:et.test(i)?this.keyHooks:{}),r=s.props?this.props.concat(s.props):this.props,e=new x.Event(o),t=r.length;while(t--)n=r[t],e[n]=o[n];return e.target||(e.target=o.srcElement||a),3===e.target.nodeType&&(e.target=e.target.parentNode),e.metaKey=!!e.metaKey,s.filter?s.filter(e,o):e},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(e,t){return null==e.which&&(e.which=null!=t.charCode?t.charCode:t.keyCode),e}},mouseHooks:{props:"button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(e,n){var r,i,o,s=n.button,l=n.fromElement;return null==e.pageX&&null!=n.clientX&&(i=e.target.ownerDocument||a,o=i.documentElement,r=i.body,e.pageX=n.clientX+(o&&o.scrollLeft||r&&r.scrollLeft||0)-(o&&o.clientLeft||r&&r.clientLeft||0),e.pageY=n.clientY+(o&&o.scrollTop||r&&r.scrollTop||0)-(o&&o.clientTop||r&&r.clientTop||0)),!e.relatedTarget&&l&&(e.relatedTarget=l===e.target?n.toElement:l),e.which||s===t||(e.which=1&s?1:2&s?3:4&s?2:0),e}},special:{load:{noBubble:!0},focus:{trigger:function(){if(this!==at()&&this.focus)try{return this.focus(),!1}catch(e){}},delegateType:"focusin"},blur:{trigger:function(){return this===at()&&this.blur?(this.blur(),!1):t},delegateType:"focusout"},click:{trigger:function(){return x.nodeName(this,"input")&&"checkbox"===this.type&&this.click?(this.click(),!1):t},_default:function(e){return x.nodeName(e.target,"a")}},beforeunload:{postDispatch:function(e){e.result!==t&&(e.originalEvent.returnValue=e.result)}}},simulate:function(e,t,n,r){var i=x.extend(new x.Event,n,{type:e,isSimulated:!0,originalEvent:{}});r?x.event.trigger(i,null,t):x.event.dispatch.call(t,i),i.isDefaultPrevented()&&n.preventDefault()}},x.removeEvent=a.removeEventListener?function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n,!1)}:function(e,t,n){var r="on"+t;e.detachEvent&&(typeof e[r]===i&&(e[r]=null),e.detachEvent(r,n))},x.Event=function(e,n){return this instanceof x.Event?(e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||e.returnValue===!1||e.getPreventDefault&&e.getPreventDefault()?it:ot):this.type=e,n&&x.extend(this,n),this.timeStamp=e&&e.timeStamp||x.now(),this[x.expando]=!0,t):new x.Event(e,n)},x.Event.prototype={isDefaultPrevented:ot,isPropagationStopped:ot,isImmediatePropagationStopped:ot,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=it,e&&(e.preventDefault?e.preventDefault():e.returnValue=!1)},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=it,e&&(e.stopPropagation&&e.stopPropagation(),e.cancelBubble=!0)},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=it,this.stopPropagation()}},x.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(e,t){x.event.special[e]={delegateType:t,bindType:t,handle:function(e){var n,r=this,i=e.relatedTarget,o=e.handleObj;return(!i||i!==r&&!x.contains(r,i))&&(e.type=o.origType,n=o.handler.apply(this,arguments),e.type=t),n}}}),x.support.submitBubbles||(x.event.special.submit={setup:function(){return x.nodeName(this,"form")?!1:(x.event.add(this,"click._submit keypress._submit",function(e){var n=e.target,r=x.nodeName(n,"input")||x.nodeName(n,"button")?n.form:t;r&&!x._data(r,"submitBubbles")&&(x.event.add(r,"submit._submit",function(e){e._submit_bubble=!0}),x._data(r,"submitBubbles",!0))}),t)},postDispatch:function(e){e._submit_bubble&&(delete e._submit_bubble,this.parentNode&&!e.isTrigger&&x.event.simulate("submit",this.parentNode,e,!0))},teardown:function(){return x.nodeName(this,"form")?!1:(x.event.remove(this,"._submit"),t)}}),x.support.changeBubbles||(x.event.special.change={setup:function(){return Z.test(this.nodeName)?(("checkbox"===this.type||"radio"===this.type)&&(x.event.add(this,"propertychange._change",function(e){"checked"===e.originalEvent.propertyName&&(this._just_changed=!0)}),x.event.add(this,"click._change",function(e){this._just_changed&&!e.isTrigger&&(this._just_changed=!1),x.event.simulate("change",this,e,!0)})),!1):(x.event.add(this,"beforeactivate._change",function(e){var t=e.target;Z.test(t.nodeName)&&!x._data(t,"changeBubbles")&&(x.event.add(t,"change._change",function(e){!this.parentNode||e.isSimulated||e.isTrigger||x.event.simulate("change",this.parentNode,e,!0)}),x._data(t,"changeBubbles",!0))}),t)},handle:function(e){var n=e.target;return this!==n||e.isSimulated||e.isTrigger||"radio"!==n.type&&"checkbox"!==n.type?e.handleObj.handler.apply(this,arguments):t},teardown:function(){return x.event.remove(this,"._change"),!Z.test(this.nodeName)}}),x.support.focusinBubbles||x.each({focus:"focusin",blur:"focusout"},function(e,t){var n=0,r=function(e){x.event.simulate(t,e.target,x.event.fix(e),!0)};x.event.special[t]={setup:function(){0===n++&&a.addEventListener(e,r,!0)},teardown:function(){0===--n&&a.removeEventListener(e,r,!0)}}}),x.fn.extend({on:function(e,n,r,i,o){var a,s;if("object"==typeof e){"string"!=typeof n&&(r=r||n,n=t);for(a in e)this.on(a,n,r,e[a],o);return this}if(null==r&&null==i?(i=n,r=n=t):null==i&&("string"==typeof n?(i=r,r=t):(i=r,r=n,n=t)),i===!1)i=ot;else if(!i)return this;return 1===o&&(s=i,i=function(e){return x().off(e),s.apply(this,arguments)},i.guid=s.guid||(s.guid=x.guid++)),this.each(function(){x.event.add(this,e,i,r,n)})},one:function(e,t,n,r){return this.on(e,t,n,r,1)},off:function(e,n,r){var i,o;if(e&&e.preventDefault&&e.handleObj)return i=e.handleObj,x(e.delegateTarget).off(i.namespace?i.origType+"."+i.namespace:i.origType,i.selector,i.handler),this;if("object"==typeof e){for(o in e)this.off(o,n,e[o]);return this}return(n===!1||"function"==typeof n)&&(r=n,n=t),r===!1&&(r=ot),this.each(function(){x.event.remove(this,e,r,n)})},trigger:function(e,t){return this.each(function(){x.event.trigger(e,t,this)})},triggerHandler:function(e,n){var r=this[0];return r?x.event.trigger(e,n,r,!0):t}});var st=/^.[^:#\[\.,]*$/,lt=/^(?:parents|prev(?:Until|All))/,ut=x.expr.match.needsContext,ct={children:!0,contents:!0,next:!0,prev:!0};x.fn.extend({find:function(e){var t,n=[],r=this,i=r.length;if("string"!=typeof e)return this.pushStack(x(e).filter(function(){for(t=0;i>t;t++)if(x.contains(r[t],this))return!0}));for(t=0;i>t;t++)x.find(e,r[t],n);return n=this.pushStack(i>1?x.unique(n):n),n.selector=this.selector?this.selector+" "+e:e,n},has:function(e){var t,n=x(e,this),r=n.length;return this.filter(function(){for(t=0;r>t;t++)if(x.contains(this,n[t]))return!0})},not:function(e){return this.pushStack(ft(this,e||[],!0))},filter:function(e){return this.pushStack(ft(this,e||[],!1))},is:function(e){return!!ft(this,"string"==typeof e&&ut.test(e)?x(e):e||[],!1).length},closest:function(e,t){var n,r=0,i=this.length,o=[],a=ut.test(e)||"string"!=typeof e?x(e,t||this.context):0;for(;i>r;r++)for(n=this[r];n&&n!==t;n=n.parentNode)if(11>n.nodeType&&(a?a.index(n)>-1:1===n.nodeType&&x.find.matchesSelector(n,e))){n=o.push(n);break}return this.pushStack(o.length>1?x.unique(o):o)},index:function(e){return e?"string"==typeof e?x.inArray(this[0],x(e)):x.inArray(e.jquery?e[0]:e,this):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){var n="string"==typeof e?x(e,t):x.makeArray(e&&e.nodeType?[e]:e),r=x.merge(this.get(),n);return this.pushStack(x.unique(r))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}});function pt(e,t){do e=e[t];while(e&&1!==e.nodeType);return e}x.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return x.dir(e,"parentNode")},parentsUntil:function(e,t,n){return x.dir(e,"parentNode",n)},next:function(e){return pt(e,"nextSibling")},prev:function(e){return pt(e,"previousSibling")},nextAll:function(e){return x.dir(e,"nextSibling")},prevAll:function(e){return x.dir(e,"previousSibling")},nextUntil:function(e,t,n){return x.dir(e,"nextSibling",n)},prevUntil:function(e,t,n){return x.dir(e,"previousSibling",n)},siblings:function(e){return x.sibling((e.parentNode||{}).firstChild,e)},children:function(e){return x.sibling(e.firstChild)},contents:function(e){return x.nodeName(e,"iframe")?e.contentDocument||e.contentWindow.document:x.merge([],e.childNodes)}},function(e,t){x.fn[e]=function(n,r){var i=x.map(this,t,n);return"Until"!==e.slice(-5)&&(r=n),r&&"string"==typeof r&&(i=x.filter(r,i)),this.length>1&&(ct[e]||(i=x.unique(i)),lt.test(e)&&(i=i.reverse())),this.pushStack(i)}}),x.extend({filter:function(e,t,n){var r=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===r.nodeType?x.find.matchesSelector(r,e)?[r]:[]:x.find.matches(e,x.grep(t,function(e){return 1===e.nodeType}))},dir:function(e,n,r){var i=[],o=e[n];while(o&&9!==o.nodeType&&(r===t||1!==o.nodeType||!x(o).is(r)))1===o.nodeType&&i.push(o),o=o[n];return i},sibling:function(e,t){var n=[];for(;e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n}});function ft(e,t,n){if(x.isFunction(t))return x.grep(e,function(e,r){return!!t.call(e,r,e)!==n});if(t.nodeType)return x.grep(e,function(e){return e===t!==n});if("string"==typeof t){if(st.test(t))return x.filter(t,e,n);t=x.filter(t,e)}return x.grep(e,function(e){return x.inArray(e,t)>=0!==n})}function dt(e){var t=ht.split("|"),n=e.createDocumentFragment();if(n.createElement)while(t.length)n.createElement(t.pop());return n}var ht="abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",gt=/ jQuery\d+="(?:null|\d+)"/g,mt=RegExp("<(?:"+ht+")[\\s/>]","i"),yt=/^\s+/,vt=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,bt=/<([\w:]+)/,xt=/<tbody/i,wt=/<|&#?\w+;/,Tt=/<(?:script|style|link)/i,Ct=/^(?:checkbox|radio)$/i,Nt=/checked\s*(?:[^=]|=\s*.checked.)/i,kt=/^$|\/(?:java|ecma)script/i,Et=/^true\/(.*)/,St=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,At={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>"],_default:x.support.htmlSerialize?[0,"",""]:[1,"X<div>","</div>"]},jt=dt(a),Dt=jt.appendChild(a.createElement("div"));At.optgroup=At.option,At.tbody=At.tfoot=At.colgroup=At.caption=At.thead,At.th=At.td,x.fn.extend({text:function(e){return x.access(this,function(e){return e===t?x.text(this):this.empty().append((this[0]&&this[0].ownerDocument||a).createTextNode(e))},null,e,arguments.length)},append:function(){return this.domManip(arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=Lt(this,e);t.appendChild(e)}})},prepend:function(){return this.domManip(arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=Lt(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return this.domManip(arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return this.domManip(arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)})},remove:function(e,t){var n,r=e?x.filter(e,this):this,i=0;for(;null!=(n=r[i]);i++)t||1!==n.nodeType||x.cleanData(Ft(n)),n.parentNode&&(t&&x.contains(n.ownerDocument,n)&&_t(Ft(n,"script")),n.parentNode.removeChild(n));return this},empty:function(){var e,t=0;for(;null!=(e=this[t]);t++){1===e.nodeType&&x.cleanData(Ft(e,!1));while(e.firstChild)e.removeChild(e.firstChild);e.options&&x.nodeName(e,"select")&&(e.options.length=0)}return this},clone:function(e,t){return e=null==e?!1:e,t=null==t?e:t,this.map(function(){return x.clone(this,e,t)})},html:function(e){return x.access(this,function(e){var n=this[0]||{},r=0,i=this.length;if(e===t)return 1===n.nodeType?n.innerHTML.replace(gt,""):t;if(!("string"!=typeof e||Tt.test(e)||!x.support.htmlSerialize&&mt.test(e)||!x.support.leadingWhitespace&&yt.test(e)||At[(bt.exec(e)||["",""])[1].toLowerCase()])){e=e.replace(vt,"<$1></$2>");try{for(;i>r;r++)n=this[r]||{},1===n.nodeType&&(x.cleanData(Ft(n,!1)),n.innerHTML=e);n=0}catch(o){}}n&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var e=x.map(this,function(e){return[e.nextSibling,e.parentNode]}),t=0;return this.domManip(arguments,function(n){var r=e[t++],i=e[t++];i&&(r&&r.parentNode!==i&&(r=this.nextSibling),x(this).remove(),i.insertBefore(n,r))},!0),t?this:this.remove()},detach:function(e){return this.remove(e,!0)},domManip:function(e,t,n){e=d.apply([],e);var r,i,o,a,s,l,u=0,c=this.length,p=this,f=c-1,h=e[0],g=x.isFunction(h);if(g||!(1>=c||"string"!=typeof h||x.support.checkClone)&&Nt.test(h))return this.each(function(r){var i=p.eq(r);g&&(e[0]=h.call(this,r,i.html())),i.domManip(e,t,n)});if(c&&(l=x.buildFragment(e,this[0].ownerDocument,!1,!n&&this),r=l.firstChild,1===l.childNodes.length&&(l=r),r)){for(a=x.map(Ft(l,"script"),Ht),o=a.length;c>u;u++)i=l,u!==f&&(i=x.clone(i,!0,!0),o&&x.merge(a,Ft(i,"script"))),t.call(this[u],i,u);if(o)for(s=a[a.length-1].ownerDocument,x.map(a,qt),u=0;o>u;u++)i=a[u],kt.test(i.type||"")&&!x._data(i,"globalEval")&&x.contains(s,i)&&(i.src?x._evalUrl(i.src):x.globalEval((i.text||i.textContent||i.innerHTML||"").replace(St,"")));l=r=null}return this}});function Lt(e,t){return x.nodeName(e,"table")&&x.nodeName(1===t.nodeType?t:t.firstChild,"tr")?e.getElementsByTagName("tbody")[0]||e.appendChild(e.ownerDocument.createElement("tbody")):e}function Ht(e){return e.type=(null!==x.find.attr(e,"type"))+"/"+e.type,e}function qt(e){var t=Et.exec(e.type);return t?e.type=t[1]:e.removeAttribute("type"),e}function _t(e,t){var n,r=0;for(;null!=(n=e[r]);r++)x._data(n,"globalEval",!t||x._data(t[r],"globalEval"))}function Mt(e,t){if(1===t.nodeType&&x.hasData(e)){var n,r,i,o=x._data(e),a=x._data(t,o),s=o.events;if(s){delete a.handle,a.events={};for(n in s)for(r=0,i=s[n].length;i>r;r++)x.event.add(t,n,s[n][r])}a.data&&(a.data=x.extend({},a.data))}}function Ot(e,t){var n,r,i;if(1===t.nodeType){if(n=t.nodeName.toLowerCase(),!x.support.noCloneEvent&&t[x.expando]){i=x._data(t);for(r in i.events)x.removeEvent(t,r,i.handle);t.removeAttribute(x.expando)}"script"===n&&t.text!==e.text?(Ht(t).text=e.text,qt(t)):"object"===n?(t.parentNode&&(t.outerHTML=e.outerHTML),x.support.html5Clone&&e.innerHTML&&!x.trim(t.innerHTML)&&(t.innerHTML=e.innerHTML)):"input"===n&&Ct.test(e.type)?(t.defaultChecked=t.checked=e.checked,t.value!==e.value&&(t.value=e.value)):"option"===n?t.defaultSelected=t.selected=e.defaultSelected:("input"===n||"textarea"===n)&&(t.defaultValue=e.defaultValue)}}x.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(e,t){x.fn[e]=function(e){var n,r=0,i=[],o=x(e),a=o.length-1;for(;a>=r;r++)n=r===a?this:this.clone(!0),x(o[r])[t](n),h.apply(i,n.get());return this.pushStack(i)}});function Ft(e,n){var r,o,a=0,s=typeof e.getElementsByTagName!==i?e.getElementsByTagName(n||"*"):typeof e.querySelectorAll!==i?e.querySelectorAll(n||"*"):t;if(!s)for(s=[],r=e.childNodes||e;null!=(o=r[a]);a++)!n||x.nodeName(o,n)?s.push(o):x.merge(s,Ft(o,n));return n===t||n&&x.nodeName(e,n)?x.merge([e],s):s}function Bt(e){Ct.test(e.type)&&(e.defaultChecked=e.checked)}x.extend({clone:function(e,t,n){var r,i,o,a,s,l=x.contains(e.ownerDocument,e);if(x.support.html5Clone||x.isXMLDoc(e)||!mt.test("<"+e.nodeName+">")?o=e.cloneNode(!0):(Dt.innerHTML=e.outerHTML,Dt.removeChild(o=Dt.firstChild)),!(x.support.noCloneEvent&&x.support.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||x.isXMLDoc(e)))for(r=Ft(o),s=Ft(e),a=0;null!=(i=s[a]);++a)r[a]&&Ot(i,r[a]);if(t)if(n)for(s=s||Ft(e),r=r||Ft(o),a=0;null!=(i=s[a]);a++)Mt(i,r[a]);else Mt(e,o);return r=Ft(o,"script"),r.length>0&&_t(r,!l&&Ft(e,"script")),r=s=i=null,o},buildFragment:function(e,t,n,r){var i,o,a,s,l,u,c,p=e.length,f=dt(t),d=[],h=0;for(;p>h;h++)if(o=e[h],o||0===o)if("object"===x.type(o))x.merge(d,o.nodeType?[o]:o);else if(wt.test(o)){s=s||f.appendChild(t.createElement("div")),l=(bt.exec(o)||["",""])[1].toLowerCase(),c=At[l]||At._default,s.innerHTML=c[1]+o.replace(vt,"<$1></$2>")+c[2],i=c[0];while(i--)s=s.lastChild;if(!x.support.leadingWhitespace&&yt.test(o)&&d.push(t.createTextNode(yt.exec(o)[0])),!x.support.tbody){o="table"!==l||xt.test(o)?"<table>"!==c[1]||xt.test(o)?0:s:s.firstChild,i=o&&o.childNodes.length;while(i--)x.nodeName(u=o.childNodes[i],"tbody")&&!u.childNodes.length&&o.removeChild(u)}x.merge(d,s.childNodes),s.textContent="";while(s.firstChild)s.removeChild(s.firstChild);s=f.lastChild}else d.push(t.createTextNode(o));s&&f.removeChild(s),x.support.appendChecked||x.grep(Ft(d,"input"),Bt),h=0;while(o=d[h++])if((!r||-1===x.inArray(o,r))&&(a=x.contains(o.ownerDocument,o),s=Ft(f.appendChild(o),"script"),a&&_t(s),n)){i=0;while(o=s[i++])kt.test(o.type||"")&&n.push(o)}return s=null,f},cleanData:function(e,t){var n,r,o,a,s=0,l=x.expando,u=x.cache,c=x.support.deleteExpando,f=x.event.special;for(;null!=(n=e[s]);s++)if((t||x.acceptData(n))&&(o=n[l],a=o&&u[o])){if(a.events)for(r in a.events)f[r]?x.event.remove(n,r):x.removeEvent(n,r,a.handle); u[o]&&(delete u[o],c?delete n[l]:typeof n.removeAttribute!==i?n.removeAttribute(l):n[l]=null,p.push(o))}},_evalUrl:function(e){return x.ajax({url:e,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0})}}),x.fn.extend({wrapAll:function(e){if(x.isFunction(e))return this.each(function(t){x(this).wrapAll(e.call(this,t))});if(this[0]){var t=x(e,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){var e=this;while(e.firstChild&&1===e.firstChild.nodeType)e=e.firstChild;return e}).append(this)}return this},wrapInner:function(e){return x.isFunction(e)?this.each(function(t){x(this).wrapInner(e.call(this,t))}):this.each(function(){var t=x(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)})},wrap:function(e){var t=x.isFunction(e);return this.each(function(n){x(this).wrapAll(t?e.call(this,n):e)})},unwrap:function(){return this.parent().each(function(){x.nodeName(this,"body")||x(this).replaceWith(this.childNodes)}).end()}});var Pt,Rt,Wt,$t=/alpha\([^)]*\)/i,It=/opacity\s*=\s*([^)]*)/,zt=/^(top|right|bottom|left)$/,Xt=/^(none|table(?!-c[ea]).+)/,Ut=/^margin/,Vt=RegExp("^("+w+")(.*)$","i"),Yt=RegExp("^("+w+")(?!px)[a-z%]+$","i"),Jt=RegExp("^([+-])=("+w+")","i"),Gt={BODY:"block"},Qt={position:"absolute",visibility:"hidden",display:"block"},Kt={letterSpacing:0,fontWeight:400},Zt=["Top","Right","Bottom","Left"],en=["Webkit","O","Moz","ms"];function tn(e,t){if(t in e)return t;var n=t.charAt(0).toUpperCase()+t.slice(1),r=t,i=en.length;while(i--)if(t=en[i]+n,t in e)return t;return r}function nn(e,t){return e=t||e,"none"===x.css(e,"display")||!x.contains(e.ownerDocument,e)}function rn(e,t){var n,r,i,o=[],a=0,s=e.length;for(;s>a;a++)r=e[a],r.style&&(o[a]=x._data(r,"olddisplay"),n=r.style.display,t?(o[a]||"none"!==n||(r.style.display=""),""===r.style.display&&nn(r)&&(o[a]=x._data(r,"olddisplay",ln(r.nodeName)))):o[a]||(i=nn(r),(n&&"none"!==n||!i)&&x._data(r,"olddisplay",i?n:x.css(r,"display"))));for(a=0;s>a;a++)r=e[a],r.style&&(t&&"none"!==r.style.display&&""!==r.style.display||(r.style.display=t?o[a]||"":"none"));return e}x.fn.extend({css:function(e,n){return x.access(this,function(e,n,r){var i,o,a={},s=0;if(x.isArray(n)){for(o=Rt(e),i=n.length;i>s;s++)a[n[s]]=x.css(e,n[s],!1,o);return a}return r!==t?x.style(e,n,r):x.css(e,n)},e,n,arguments.length>1)},show:function(){return rn(this,!0)},hide:function(){return rn(this)},toggle:function(e){var t="boolean"==typeof e;return this.each(function(){(t?e:nn(this))?x(this).show():x(this).hide()})}}),x.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=Wt(e,"opacity");return""===n?"1":n}}}},cssNumber:{columnCount:!0,fillOpacity:!0,fontWeight:!0,lineHeight:!0,opacity:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":x.support.cssFloat?"cssFloat":"styleFloat"},style:function(e,n,r,i){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var o,a,s,l=x.camelCase(n),u=e.style;if(n=x.cssProps[l]||(x.cssProps[l]=tn(u,l)),s=x.cssHooks[n]||x.cssHooks[l],r===t)return s&&"get"in s&&(o=s.get(e,!1,i))!==t?o:u[n];if(a=typeof r,"string"===a&&(o=Jt.exec(r))&&(r=(o[1]+1)*o[2]+parseFloat(x.css(e,n)),a="number"),!(null==r||"number"===a&&isNaN(r)||("number"!==a||x.cssNumber[l]||(r+="px"),x.support.clearCloneStyle||""!==r||0!==n.indexOf("background")||(u[n]="inherit"),s&&"set"in s&&(r=s.set(e,r,i))===t)))try{u[n]=r}catch(c){}}},css:function(e,n,r,i){var o,a,s,l=x.camelCase(n);return n=x.cssProps[l]||(x.cssProps[l]=tn(e.style,l)),s=x.cssHooks[n]||x.cssHooks[l],s&&"get"in s&&(a=s.get(e,!0,r)),a===t&&(a=Wt(e,n,i)),"normal"===a&&n in Kt&&(a=Kt[n]),""===r||r?(o=parseFloat(a),r===!0||x.isNumeric(o)?o||0:a):a}}),e.getComputedStyle?(Rt=function(t){return e.getComputedStyle(t,null)},Wt=function(e,n,r){var i,o,a,s=r||Rt(e),l=s?s.getPropertyValue(n)||s[n]:t,u=e.style;return s&&(""!==l||x.contains(e.ownerDocument,e)||(l=x.style(e,n)),Yt.test(l)&&Ut.test(n)&&(i=u.width,o=u.minWidth,a=u.maxWidth,u.minWidth=u.maxWidth=u.width=l,l=s.width,u.width=i,u.minWidth=o,u.maxWidth=a)),l}):a.documentElement.currentStyle&&(Rt=function(e){return e.currentStyle},Wt=function(e,n,r){var i,o,a,s=r||Rt(e),l=s?s[n]:t,u=e.style;return null==l&&u&&u[n]&&(l=u[n]),Yt.test(l)&&!zt.test(n)&&(i=u.left,o=e.runtimeStyle,a=o&&o.left,a&&(o.left=e.currentStyle.left),u.left="fontSize"===n?"1em":l,l=u.pixelLeft+"px",u.left=i,a&&(o.left=a)),""===l?"auto":l});function on(e,t,n){var r=Vt.exec(t);return r?Math.max(0,r[1]-(n||0))+(r[2]||"px"):t}function an(e,t,n,r,i){var o=n===(r?"border":"content")?4:"width"===t?1:0,a=0;for(;4>o;o+=2)"margin"===n&&(a+=x.css(e,n+Zt[o],!0,i)),r?("content"===n&&(a-=x.css(e,"padding"+Zt[o],!0,i)),"margin"!==n&&(a-=x.css(e,"border"+Zt[o]+"Width",!0,i))):(a+=x.css(e,"padding"+Zt[o],!0,i),"padding"!==n&&(a+=x.css(e,"border"+Zt[o]+"Width",!0,i)));return a}function sn(e,t,n){var r=!0,i="width"===t?e.offsetWidth:e.offsetHeight,o=Rt(e),a=x.support.boxSizing&&"border-box"===x.css(e,"boxSizing",!1,o);if(0>=i||null==i){if(i=Wt(e,t,o),(0>i||null==i)&&(i=e.style[t]),Yt.test(i))return i;r=a&&(x.support.boxSizingReliable||i===e.style[t]),i=parseFloat(i)||0}return i+an(e,t,n||(a?"border":"content"),r,o)+"px"}function ln(e){var t=a,n=Gt[e];return n||(n=un(e,t),"none"!==n&&n||(Pt=(Pt||x("<iframe frameborder='0' width='0' height='0'/>").css("cssText","display:block !important")).appendTo(t.documentElement),t=(Pt[0].contentWindow||Pt[0].contentDocument).document,t.write("<!doctype html><html><body>"),t.close(),n=un(e,t),Pt.detach()),Gt[e]=n),n}function un(e,t){var n=x(t.createElement(e)).appendTo(t.body),r=x.css(n[0],"display");return n.remove(),r}x.each(["height","width"],function(e,n){x.cssHooks[n]={get:function(e,r,i){return r?0===e.offsetWidth&&Xt.test(x.css(e,"display"))?x.swap(e,Qt,function(){return sn(e,n,i)}):sn(e,n,i):t},set:function(e,t,r){var i=r&&Rt(e);return on(e,t,r?an(e,n,r,x.support.boxSizing&&"border-box"===x.css(e,"boxSizing",!1,i),i):0)}}}),x.support.opacity||(x.cssHooks.opacity={get:function(e,t){return It.test((t&&e.currentStyle?e.currentStyle.filter:e.style.filter)||"")?.01*parseFloat(RegExp.$1)+"":t?"1":""},set:function(e,t){var n=e.style,r=e.currentStyle,i=x.isNumeric(t)?"alpha(opacity="+100*t+")":"",o=r&&r.filter||n.filter||"";n.zoom=1,(t>=1||""===t)&&""===x.trim(o.replace($t,""))&&n.removeAttribute&&(n.removeAttribute("filter"),""===t||r&&!r.filter)||(n.filter=$t.test(o)?o.replace($t,i):o+" "+i)}}),x(function(){x.support.reliableMarginRight||(x.cssHooks.marginRight={get:function(e,n){return n?x.swap(e,{display:"inline-block"},Wt,[e,"marginRight"]):t}}),!x.support.pixelPosition&&x.fn.position&&x.each(["top","left"],function(e,n){x.cssHooks[n]={get:function(e,r){return r?(r=Wt(e,n),Yt.test(r)?x(e).position()[n]+"px":r):t}}})}),x.expr&&x.expr.filters&&(x.expr.filters.hidden=function(e){return 0>=e.offsetWidth&&0>=e.offsetHeight||!x.support.reliableHiddenOffsets&&"none"===(e.style&&e.style.display||x.css(e,"display"))},x.expr.filters.visible=function(e){return!x.expr.filters.hidden(e)}),x.each({margin:"",padding:"",border:"Width"},function(e,t){x.cssHooks[e+t]={expand:function(n){var r=0,i={},o="string"==typeof n?n.split(" "):[n];for(;4>r;r++)i[e+Zt[r]+t]=o[r]||o[r-2]||o[0];return i}},Ut.test(e)||(x.cssHooks[e+t].set=on)});var cn=/%20/g,pn=/\[\]$/,fn=/\r?\n/g,dn=/^(?:submit|button|image|reset|file)$/i,hn=/^(?:input|select|textarea|keygen)/i;x.fn.extend({serialize:function(){return x.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=x.prop(this,"elements");return e?x.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!x(this).is(":disabled")&&hn.test(this.nodeName)&&!dn.test(e)&&(this.checked||!Ct.test(e))}).map(function(e,t){var n=x(this).val();return null==n?null:x.isArray(n)?x.map(n,function(e){return{name:t.name,value:e.replace(fn,"\r\n")}}):{name:t.name,value:n.replace(fn,"\r\n")}}).get()}}),x.param=function(e,n){var r,i=[],o=function(e,t){t=x.isFunction(t)?t():null==t?"":t,i[i.length]=encodeURIComponent(e)+"="+encodeURIComponent(t)};if(n===t&&(n=x.ajaxSettings&&x.ajaxSettings.traditional),x.isArray(e)||e.jquery&&!x.isPlainObject(e))x.each(e,function(){o(this.name,this.value)});else for(r in e)gn(r,e[r],n,o);return i.join("&").replace(cn,"+")};function gn(e,t,n,r){var i;if(x.isArray(t))x.each(t,function(t,i){n||pn.test(e)?r(e,i):gn(e+"["+("object"==typeof i?t:"")+"]",i,n,r)});else if(n||"object"!==x.type(t))r(e,t);else for(i in t)gn(e+"["+i+"]",t[i],n,r)}x.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(e,t){x.fn[t]=function(e,n){return arguments.length>0?this.on(t,null,e,n):this.trigger(t)}}),x.fn.extend({hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)},bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)}});var mn,yn,vn=x.now(),bn=/\?/,xn=/#.*$/,wn=/([?&])_=[^&]*/,Tn=/^(.*?):[ \t]*([^\r\n]*)\r?$/gm,Cn=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,Nn=/^(?:GET|HEAD)$/,kn=/^\/\//,En=/^([\w.+-]+:)(?:\/\/([^\/?#:]*)(?::(\d+)|)|)/,Sn=x.fn.load,An={},jn={},Dn="*/".concat("*");try{yn=o.href}catch(Ln){yn=a.createElement("a"),yn.href="",yn=yn.href}mn=En.exec(yn.toLowerCase())||[];function Hn(e){return function(t,n){"string"!=typeof t&&(n=t,t="*");var r,i=0,o=t.toLowerCase().match(T)||[];if(x.isFunction(n))while(r=o[i++])"+"===r[0]?(r=r.slice(1)||"*",(e[r]=e[r]||[]).unshift(n)):(e[r]=e[r]||[]).push(n)}}function qn(e,n,r,i){var o={},a=e===jn;function s(l){var u;return o[l]=!0,x.each(e[l]||[],function(e,l){var c=l(n,r,i);return"string"!=typeof c||a||o[c]?a?!(u=c):t:(n.dataTypes.unshift(c),s(c),!1)}),u}return s(n.dataTypes[0])||!o["*"]&&s("*")}function _n(e,n){var r,i,o=x.ajaxSettings.flatOptions||{};for(i in n)n[i]!==t&&((o[i]?e:r||(r={}))[i]=n[i]);return r&&x.extend(!0,e,r),e}x.fn.load=function(e,n,r){if("string"!=typeof e&&Sn)return Sn.apply(this,arguments);var i,o,a,s=this,l=e.indexOf(" ");return l>=0&&(i=e.slice(l,e.length),e=e.slice(0,l)),x.isFunction(n)?(r=n,n=t):n&&"object"==typeof n&&(a="POST"),s.length>0&&x.ajax({url:e,type:a,dataType:"html",data:n}).done(function(e){o=arguments,s.html(i?x("<div>").append(x.parseHTML(e)).find(i):e)}).complete(r&&function(e,t){s.each(r,o||[e.responseText,t,e])}),this},x.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){x.fn[t]=function(e){return this.on(t,e)}}),x.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:yn,type:"GET",isLocal:Cn.test(mn[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Dn,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"},converters:{"* text":String,"text html":!0,"text json":x.parseJSON,"text xml":x.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?_n(_n(e,x.ajaxSettings),t):_n(x.ajaxSettings,e)},ajaxPrefilter:Hn(An),ajaxTransport:Hn(jn),ajax:function(e,n){"object"==typeof e&&(n=e,e=t),n=n||{};var r,i,o,a,s,l,u,c,p=x.ajaxSetup({},n),f=p.context||p,d=p.context&&(f.nodeType||f.jquery)?x(f):x.event,h=x.Deferred(),g=x.Callbacks("once memory"),m=p.statusCode||{},y={},v={},b=0,w="canceled",C={readyState:0,getResponseHeader:function(e){var t;if(2===b){if(!c){c={};while(t=Tn.exec(a))c[t[1].toLowerCase()]=t[2]}t=c[e.toLowerCase()]}return null==t?null:t},getAllResponseHeaders:function(){return 2===b?a:null},setRequestHeader:function(e,t){var n=e.toLowerCase();return b||(e=v[n]=v[n]||e,y[e]=t),this},overrideMimeType:function(e){return b||(p.mimeType=e),this},statusCode:function(e){var t;if(e)if(2>b)for(t in e)m[t]=[m[t],e[t]];else C.always(e[C.status]);return this},abort:function(e){var t=e||w;return u&&u.abort(t),k(0,t),this}};if(h.promise(C).complete=g.add,C.success=C.done,C.error=C.fail,p.url=((e||p.url||yn)+"").replace(xn,"").replace(kn,mn[1]+"//"),p.type=n.method||n.type||p.method||p.type,p.dataTypes=x.trim(p.dataType||"*").toLowerCase().match(T)||[""],null==p.crossDomain&&(r=En.exec(p.url.toLowerCase()),p.crossDomain=!(!r||r[1]===mn[1]&&r[2]===mn[2]&&(r[3]||("http:"===r[1]?"80":"443"))===(mn[3]||("http:"===mn[1]?"80":"443")))),p.data&&p.processData&&"string"!=typeof p.data&&(p.data=x.param(p.data,p.traditional)),qn(An,p,n,C),2===b)return C;l=p.global,l&&0===x.active++&&x.event.trigger("ajaxStart"),p.type=p.type.toUpperCase(),p.hasContent=!Nn.test(p.type),o=p.url,p.hasContent||(p.data&&(o=p.url+=(bn.test(o)?"&":"?")+p.data,delete p.data),p.cache===!1&&(p.url=wn.test(o)?o.replace(wn,"$1_="+vn++):o+(bn.test(o)?"&":"?")+"_="+vn++)),p.ifModified&&(x.lastModified[o]&&C.setRequestHeader("If-Modified-Since",x.lastModified[o]),x.etag[o]&&C.setRequestHeader("If-None-Match",x.etag[o])),(p.data&&p.hasContent&&p.contentType!==!1||n.contentType)&&C.setRequestHeader("Content-Type",p.contentType),C.setRequestHeader("Accept",p.dataTypes[0]&&p.accepts[p.dataTypes[0]]?p.accepts[p.dataTypes[0]]+("*"!==p.dataTypes[0]?", "+Dn+"; q=0.01":""):p.accepts["*"]);for(i in p.headers)C.setRequestHeader(i,p.headers[i]);if(p.beforeSend&&(p.beforeSend.call(f,C,p)===!1||2===b))return C.abort();w="abort";for(i in{success:1,error:1,complete:1})C[i](p[i]);if(u=qn(jn,p,n,C)){C.readyState=1,l&&d.trigger("ajaxSend",[C,p]),p.async&&p.timeout>0&&(s=setTimeout(function(){C.abort("timeout")},p.timeout));try{b=1,u.send(y,k)}catch(N){if(!(2>b))throw N;k(-1,N)}}else k(-1,"No Transport");function k(e,n,r,i){var c,y,v,w,T,N=n;2!==b&&(b=2,s&&clearTimeout(s),u=t,a=i||"",C.readyState=e>0?4:0,c=e>=200&&300>e||304===e,r&&(w=Mn(p,C,r)),w=On(p,w,C,c),c?(p.ifModified&&(T=C.getResponseHeader("Last-Modified"),T&&(x.lastModified[o]=T),T=C.getResponseHeader("etag"),T&&(x.etag[o]=T)),204===e||"HEAD"===p.type?N="nocontent":304===e?N="notmodified":(N=w.state,y=w.data,v=w.error,c=!v)):(v=N,(e||!N)&&(N="error",0>e&&(e=0))),C.status=e,C.statusText=(n||N)+"",c?h.resolveWith(f,[y,N,C]):h.rejectWith(f,[C,N,v]),C.statusCode(m),m=t,l&&d.trigger(c?"ajaxSuccess":"ajaxError",[C,p,c?y:v]),g.fireWith(f,[C,N]),l&&(d.trigger("ajaxComplete",[C,p]),--x.active||x.event.trigger("ajaxStop")))}return C},getJSON:function(e,t,n){return x.get(e,t,n,"json")},getScript:function(e,n){return x.get(e,t,n,"script")}}),x.each(["get","post"],function(e,n){x[n]=function(e,r,i,o){return x.isFunction(r)&&(o=o||i,i=r,r=t),x.ajax({url:e,type:n,dataType:o,data:r,success:i})}});function Mn(e,n,r){var i,o,a,s,l=e.contents,u=e.dataTypes;while("*"===u[0])u.shift(),o===t&&(o=e.mimeType||n.getResponseHeader("Content-Type"));if(o)for(s in l)if(l[s]&&l[s].test(o)){u.unshift(s);break}if(u[0]in r)a=u[0];else{for(s in r){if(!u[0]||e.converters[s+" "+u[0]]){a=s;break}i||(i=s)}a=a||i}return a?(a!==u[0]&&u.unshift(a),r[a]):t}function On(e,t,n,r){var i,o,a,s,l,u={},c=e.dataTypes.slice();if(c[1])for(a in e.converters)u[a.toLowerCase()]=e.converters[a];o=c.shift();while(o)if(e.responseFields[o]&&(n[e.responseFields[o]]=t),!l&&r&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),l=o,o=c.shift())if("*"===o)o=l;else if("*"!==l&&l!==o){if(a=u[l+" "+o]||u["* "+o],!a)for(i in u)if(s=i.split(" "),s[1]===o&&(a=u[l+" "+s[0]]||u["* "+s[0]])){a===!0?a=u[i]:u[i]!==!0&&(o=s[0],c.unshift(s[1]));break}if(a!==!0)if(a&&e["throws"])t=a(t);else try{t=a(t)}catch(p){return{state:"parsererror",error:a?p:"No conversion from "+l+" to "+o}}}return{state:"success",data:t}}x.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/(?:java|ecma)script/},converters:{"text script":function(e){return x.globalEval(e),e}}}),x.ajaxPrefilter("script",function(e){e.cache===t&&(e.cache=!1),e.crossDomain&&(e.type="GET",e.global=!1)}),x.ajaxTransport("script",function(e){if(e.crossDomain){var n,r=a.head||x("head")[0]||a.documentElement;return{send:function(t,i){n=a.createElement("script"),n.async=!0,e.scriptCharset&&(n.charset=e.scriptCharset),n.src=e.url,n.onload=n.onreadystatechange=function(e,t){(t||!n.readyState||/loaded|complete/.test(n.readyState))&&(n.onload=n.onreadystatechange=null,n.parentNode&&n.parentNode.removeChild(n),n=null,t||i(200,"success"))},r.insertBefore(n,r.firstChild)},abort:function(){n&&n.onload(t,!0)}}}});var Fn=[],Bn=/(=)\?(?=&|$)|\?\?/;x.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=Fn.pop()||x.expando+"_"+vn++;return this[e]=!0,e}}),x.ajaxPrefilter("json jsonp",function(n,r,i){var o,a,s,l=n.jsonp!==!1&&(Bn.test(n.url)?"url":"string"==typeof n.data&&!(n.contentType||"").indexOf("application/x-www-form-urlencoded")&&Bn.test(n.data)&&"data");return l||"jsonp"===n.dataTypes[0]?(o=n.jsonpCallback=x.isFunction(n.jsonpCallback)?n.jsonpCallback():n.jsonpCallback,l?n[l]=n[l].replace(Bn,"$1"+o):n.jsonp!==!1&&(n.url+=(bn.test(n.url)?"&":"?")+n.jsonp+"="+o),n.converters["script json"]=function(){return s||x.error(o+" was not called"),s[0]},n.dataTypes[0]="json",a=e[o],e[o]=function(){s=arguments},i.always(function(){e[o]=a,n[o]&&(n.jsonpCallback=r.jsonpCallback,Fn.push(o)),s&&x.isFunction(a)&&a(s[0]),s=a=t}),"script"):t});var Pn,Rn,Wn=0,$n=e.ActiveXObject&&function(){var e;for(e in Pn)Pn[e](t,!0)};function In(){try{return new e.XMLHttpRequest}catch(t){}}function zn(){try{return new e.ActiveXObject("Microsoft.XMLHTTP")}catch(t){}}x.ajaxSettings.xhr=e.ActiveXObject?function(){return!this.isLocal&&In()||zn()}:In,Rn=x.ajaxSettings.xhr(),x.support.cors=!!Rn&&"withCredentials"in Rn,Rn=x.support.ajax=!!Rn,Rn&&x.ajaxTransport(function(n){if(!n.crossDomain||x.support.cors){var r;return{send:function(i,o){var a,s,l=n.xhr();if(n.username?l.open(n.type,n.url,n.async,n.username,n.password):l.open(n.type,n.url,n.async),n.xhrFields)for(s in n.xhrFields)l[s]=n.xhrFields[s];n.mimeType&&l.overrideMimeType&&l.overrideMimeType(n.mimeType),n.crossDomain||i["X-Requested-With"]||(i["X-Requested-With"]="XMLHttpRequest");try{for(s in i)l.setRequestHeader(s,i[s])}catch(u){}l.send(n.hasContent&&n.data||null),r=function(e,i){var s,u,c,p;try{if(r&&(i||4===l.readyState))if(r=t,a&&(l.onreadystatechange=x.noop,$n&&delete Pn[a]),i)4!==l.readyState&&l.abort();else{p={},s=l.status,u=l.getAllResponseHeaders(),"string"==typeof l.responseText&&(p.text=l.responseText);try{c=l.statusText}catch(f){c=""}s||!n.isLocal||n.crossDomain?1223===s&&(s=204):s=p.text?200:404}}catch(d){i||o(-1,d)}p&&o(s,c,p,u)},n.async?4===l.readyState?setTimeout(r):(a=++Wn,$n&&(Pn||(Pn={},x(e).unload($n)),Pn[a]=r),l.onreadystatechange=r):r()},abort:function(){r&&r(t,!0)}}}});var Xn,Un,Vn=/^(?:toggle|show|hide)$/,Yn=RegExp("^(?:([+-])=|)("+w+")([a-z%]*)$","i"),Jn=/queueHooks$/,Gn=[nr],Qn={"*":[function(e,t){var n=this.createTween(e,t),r=n.cur(),i=Yn.exec(t),o=i&&i[3]||(x.cssNumber[e]?"":"px"),a=(x.cssNumber[e]||"px"!==o&&+r)&&Yn.exec(x.css(n.elem,e)),s=1,l=20;if(a&&a[3]!==o){o=o||a[3],i=i||[],a=+r||1;do s=s||".5",a/=s,x.style(n.elem,e,a+o);while(s!==(s=n.cur()/r)&&1!==s&&--l)}return i&&(a=n.start=+a||+r||0,n.unit=o,n.end=i[1]?a+(i[1]+1)*i[2]:+i[2]),n}]};function Kn(){return setTimeout(function(){Xn=t}),Xn=x.now()}function Zn(e,t,n){var r,i=(Qn[t]||[]).concat(Qn["*"]),o=0,a=i.length;for(;a>o;o++)if(r=i[o].call(n,t,e))return r}function er(e,t,n){var r,i,o=0,a=Gn.length,s=x.Deferred().always(function(){delete l.elem}),l=function(){if(i)return!1;var t=Xn||Kn(),n=Math.max(0,u.startTime+u.duration-t),r=n/u.duration||0,o=1-r,a=0,l=u.tweens.length;for(;l>a;a++)u.tweens[a].run(o);return s.notifyWith(e,[u,o,n]),1>o&&l?n:(s.resolveWith(e,[u]),!1)},u=s.promise({elem:e,props:x.extend({},t),opts:x.extend(!0,{specialEasing:{}},n),originalProperties:t,originalOptions:n,startTime:Xn||Kn(),duration:n.duration,tweens:[],createTween:function(t,n){var r=x.Tween(e,u.opts,t,n,u.opts.specialEasing[t]||u.opts.easing);return u.tweens.push(r),r},stop:function(t){var n=0,r=t?u.tweens.length:0;if(i)return this;for(i=!0;r>n;n++)u.tweens[n].run(1);return t?s.resolveWith(e,[u,t]):s.rejectWith(e,[u,t]),this}}),c=u.props;for(tr(c,u.opts.specialEasing);a>o;o++)if(r=Gn[o].call(u,e,c,u.opts))return r;return x.map(c,Zn,u),x.isFunction(u.opts.start)&&u.opts.start.call(e,u),x.fx.timer(x.extend(l,{elem:e,anim:u,queue:u.opts.queue})),u.progress(u.opts.progress).done(u.opts.done,u.opts.complete).fail(u.opts.fail).always(u.opts.always)}function tr(e,t){var n,r,i,o,a;for(n in e)if(r=x.camelCase(n),i=t[r],o=e[n],x.isArray(o)&&(i=o[1],o=e[n]=o[0]),n!==r&&(e[r]=o,delete e[n]),a=x.cssHooks[r],a&&"expand"in a){o=a.expand(o),delete e[r];for(n in o)n in e||(e[n]=o[n],t[n]=i)}else t[r]=i}x.Animation=x.extend(er,{tweener:function(e,t){x.isFunction(e)?(t=e,e=["*"]):e=e.split(" ");var n,r=0,i=e.length;for(;i>r;r++)n=e[r],Qn[n]=Qn[n]||[],Qn[n].unshift(t)},prefilter:function(e,t){t?Gn.unshift(e):Gn.push(e)}});function nr(e,t,n){var r,i,o,a,s,l,u=this,c={},p=e.style,f=e.nodeType&&nn(e),d=x._data(e,"fxshow");n.queue||(s=x._queueHooks(e,"fx"),null==s.unqueued&&(s.unqueued=0,l=s.empty.fire,s.empty.fire=function(){s.unqueued||l()}),s.unqueued++,u.always(function(){u.always(function(){s.unqueued--,x.queue(e,"fx").length||s.empty.fire()})})),1===e.nodeType&&("height"in t||"width"in t)&&(n.overflow=[p.overflow,p.overflowX,p.overflowY],"inline"===x.css(e,"display")&&"none"===x.css(e,"float")&&(x.support.inlineBlockNeedsLayout&&"inline"!==ln(e.nodeName)?p.zoom=1:p.display="inline-block")),n.overflow&&(p.overflow="hidden",x.support.shrinkWrapBlocks||u.always(function(){p.overflow=n.overflow[0],p.overflowX=n.overflow[1],p.overflowY=n.overflow[2]}));for(r in t)if(i=t[r],Vn.exec(i)){if(delete t[r],o=o||"toggle"===i,i===(f?"hide":"show"))continue;c[r]=d&&d[r]||x.style(e,r)}if(!x.isEmptyObject(c)){d?"hidden"in d&&(f=d.hidden):d=x._data(e,"fxshow",{}),o&&(d.hidden=!f),f?x(e).show():u.done(function(){x(e).hide()}),u.done(function(){var t;x._removeData(e,"fxshow");for(t in c)x.style(e,t,c[t])});for(r in c)a=Zn(f?d[r]:0,r,u),r in d||(d[r]=a.start,f&&(a.end=a.start,a.start="width"===r||"height"===r?1:0))}}function rr(e,t,n,r,i){return new rr.prototype.init(e,t,n,r,i)}x.Tween=rr,rr.prototype={constructor:rr,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||"swing",this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(x.cssNumber[n]?"":"px")},cur:function(){var e=rr.propHooks[this.prop];return e&&e.get?e.get(this):rr.propHooks._default.get(this)},run:function(e){var t,n=rr.propHooks[this.prop];return this.pos=t=this.options.duration?x.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):rr.propHooks._default.set(this),this}},rr.prototype.init.prototype=rr.prototype,rr.propHooks={_default:{get:function(e){var t;return null==e.elem[e.prop]||e.elem.style&&null!=e.elem.style[e.prop]?(t=x.css(e.elem,e.prop,""),t&&"auto"!==t?t:0):e.elem[e.prop]},set:function(e){x.fx.step[e.prop]?x.fx.step[e.prop](e):e.elem.style&&(null!=e.elem.style[x.cssProps[e.prop]]||x.cssHooks[e.prop])?x.style(e.elem,e.prop,e.now+e.unit):e.elem[e.prop]=e.now}}},rr.propHooks.scrollTop=rr.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},x.each(["toggle","show","hide"],function(e,t){var n=x.fn[t];x.fn[t]=function(e,r,i){return null==e||"boolean"==typeof e?n.apply(this,arguments):this.animate(ir(t,!0),e,r,i)}}),x.fn.extend({fadeTo:function(e,t,n,r){return this.filter(nn).css("opacity",0).show().end().animate({opacity:t},e,n,r)},animate:function(e,t,n,r){var i=x.isEmptyObject(e),o=x.speed(t,n,r),a=function(){var t=er(this,x.extend({},e),o);(i||x._data(this,"finish"))&&t.stop(!0)};return a.finish=a,i||o.queue===!1?this.each(a):this.queue(o.queue,a)},stop:function(e,n,r){var i=function(e){var t=e.stop;delete e.stop,t(r)};return"string"!=typeof e&&(r=n,n=e,e=t),n&&e!==!1&&this.queue(e||"fx",[]),this.each(function(){var t=!0,n=null!=e&&e+"queueHooks",o=x.timers,a=x._data(this);if(n)a[n]&&a[n].stop&&i(a[n]);else for(n in a)a[n]&&a[n].stop&&Jn.test(n)&&i(a[n]);for(n=o.length;n--;)o[n].elem!==this||null!=e&&o[n].queue!==e||(o[n].anim.stop(r),t=!1,o.splice(n,1));(t||!r)&&x.dequeue(this,e)})},finish:function(e){return e!==!1&&(e=e||"fx"),this.each(function(){var t,n=x._data(this),r=n[e+"queue"],i=n[e+"queueHooks"],o=x.timers,a=r?r.length:0;for(n.finish=!0,x.queue(this,e,[]),i&&i.stop&&i.stop.call(this,!0),t=o.length;t--;)o[t].elem===this&&o[t].queue===e&&(o[t].anim.stop(!0),o.splice(t,1));for(t=0;a>t;t++)r[t]&&r[t].finish&&r[t].finish.call(this);delete n.finish})}});function ir(e,t){var n,r={height:e},i=0;for(t=t?1:0;4>i;i+=2-t)n=Zt[i],r["margin"+n]=r["padding"+n]=e;return t&&(r.opacity=r.width=e),r}x.each({slideDown:ir("show"),slideUp:ir("hide"),slideToggle:ir("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(e,t){x.fn[e]=function(e,n,r){return this.animate(t,e,n,r)}}),x.speed=function(e,t,n){var r=e&&"object"==typeof e?x.extend({},e):{complete:n||!n&&t||x.isFunction(e)&&e,duration:e,easing:n&&t||t&&!x.isFunction(t)&&t};return r.duration=x.fx.off?0:"number"==typeof r.duration?r.duration:r.duration in x.fx.speeds?x.fx.speeds[r.duration]:x.fx.speeds._default,(null==r.queue||r.queue===!0)&&(r.queue="fx"),r.old=r.complete,r.complete=function(){x.isFunction(r.old)&&r.old.call(this),r.queue&&x.dequeue(this,r.queue)},r},x.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2}},x.timers=[],x.fx=rr.prototype.init,x.fx.tick=function(){var e,n=x.timers,r=0;for(Xn=x.now();n.length>r;r++)e=n[r],e()||n[r]!==e||n.splice(r--,1);n.length||x.fx.stop(),Xn=t},x.fx.timer=function(e){e()&&x.timers.push(e)&&x.fx.start()},x.fx.interval=13,x.fx.start=function(){Un||(Un=setInterval(x.fx.tick,x.fx.interval))},x.fx.stop=function(){clearInterval(Un),Un=null},x.fx.speeds={slow:600,fast:200,_default:400},x.fx.step={},x.expr&&x.expr.filters&&(x.expr.filters.animated=function(e){return x.grep(x.timers,function(t){return e===t.elem}).length}),x.fn.offset=function(e){if(arguments.length)return e===t?this:this.each(function(t){x.offset.setOffset(this,e,t)});var n,r,o={top:0,left:0},a=this[0],s=a&&a.ownerDocument;if(s)return n=s.documentElement,x.contains(n,a)?(typeof a.getBoundingClientRect!==i&&(o=a.getBoundingClientRect()),r=or(s),{top:o.top+(r.pageYOffset||n.scrollTop)-(n.clientTop||0),left:o.left+(r.pageXOffset||n.scrollLeft)-(n.clientLeft||0)}):o},x.offset={setOffset:function(e,t,n){var r=x.css(e,"position");"static"===r&&(e.style.position="relative");var i=x(e),o=i.offset(),a=x.css(e,"top"),s=x.css(e,"left"),l=("absolute"===r||"fixed"===r)&&x.inArray("auto",[a,s])>-1,u={},c={},p,f;l?(c=i.position(),p=c.top,f=c.left):(p=parseFloat(a)||0,f=parseFloat(s)||0),x.isFunction(t)&&(t=t.call(e,n,o)),null!=t.top&&(u.top=t.top-o.top+p),null!=t.left&&(u.left=t.left-o.left+f),"using"in t?t.using.call(e,u):i.css(u)}},x.fn.extend({position:function(){if(this[0]){var e,t,n={top:0,left:0},r=this[0];return"fixed"===x.css(r,"position")?t=r.getBoundingClientRect():(e=this.offsetParent(),t=this.offset(),x.nodeName(e[0],"html")||(n=e.offset()),n.top+=x.css(e[0],"borderTopWidth",!0),n.left+=x.css(e[0],"borderLeftWidth",!0)),{top:t.top-n.top-x.css(r,"marginTop",!0),left:t.left-n.left-x.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent||s;while(e&&!x.nodeName(e,"html")&&"static"===x.css(e,"position"))e=e.offsetParent;return e||s})}}),x.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(e,n){var r=/Y/.test(n);x.fn[e]=function(i){return x.access(this,function(e,i,o){var a=or(e);return o===t?a?n in a?a[n]:a.document.documentElement[i]:e[i]:(a?a.scrollTo(r?x(a).scrollLeft():o,r?o:x(a).scrollTop()):e[i]=o,t)},e,i,arguments.length,null)}});function or(e){return x.isWindow(e)?e:9===e.nodeType?e.defaultView||e.parentWindow:!1}x.each({Height:"height",Width:"width"},function(e,n){x.each({padding:"inner"+e,content:n,"":"outer"+e},function(r,i){x.fn[i]=function(i,o){var a=arguments.length&&(r||"boolean"!=typeof i),s=r||(i===!0||o===!0?"margin":"border");return x.access(this,function(n,r,i){var o;return x.isWindow(n)?n.document.documentElement["client"+e]:9===n.nodeType?(o=n.documentElement,Math.max(n.body["scroll"+e],o["scroll"+e],n.body["offset"+e],o["offset"+e],o["client"+e])):i===t?x.css(n,r,s):x.style(n,r,i,s)},n,a?i:t,a,null)}})}),x.fn.size=function(){return this.length},x.fn.andSelf=x.fn.addBack,"object"==typeof module&&module&&"object"==typeof module.exports?module.exports=x:(e.jQuery=e.$=x,"function"==typeof define&&define.amd&&define("jquery",[],function(){return x}))})(window);
node_modules/react-icons/go/keyboard.js
bengimbel/Solstice-React-Contacts-Project
import React from 'react' import Icon from 'react-icon-base' const GoKeyboard = props => ( <Icon viewBox="0 0 40 40" {...props}> <g><path d="m25 22.5h2.5v-5h-2.5v5z m5-12.5h-2.5v5h2.5v-5z m-5 0h-2.5v5h2.5v-5z m-5 12.5h2.5v-5h-2.5v5z m-5 7.5h12.5v-5h-12.5v5z m15-7.5h5v-12.5h-2.5v7.5h-2.5v5z m-20 7.5h2.5v-5h-2.5v5z m20 0h5v-5h-5v5z m-10-20h-2.5v5h2.5v-5z m-12.5 7.5h-2.5v5h2.5v-5z m0 7.5h-2.5v5h2.5v-5z m-7.5-20v30h40v-30h-40z m37.5 27.5h-35v-25h35v25z m-22.5-10h2.5v-5h-2.5v5z m-5-12.5h-5v5h5v-5z m5 0h-2.5v5h2.5v-5z m-5 12.5h2.5v-5h-2.5v5z"/></g> </Icon> ) export default GoKeyboard
cm19/ReactJS/your-first-react-app-exercises-master/exercise-12/App.js
Brandon-J-Campbell/codemash
import React, { Component } from 'react'; import { BrowserRouter, Route } from 'react-router-dom'; import Friends from './friends/Friends.entry'; import styles from './App.css'; class App extends Component { render() { return ( <BrowserRouter> <div className={styles.app}> <header className={styles.appHeader}> <h1 className={styles.appTitle}>Exercise 12</h1> <h2 className={styles.subTitle}>React Router</h2> </header> <div className={styles.exercise}> <Route path="/" exact component={Friends} /> </div> </div> </BrowserRouter> ); } } export default App;
frontend/src/Components/Form/HintedSelectInputSelectedValue.js
Radarr/Radarr
import _ from 'lodash'; import PropTypes from 'prop-types'; import React from 'react'; import Label from 'Components/Label'; import EnhancedSelectInputSelectedValue from './EnhancedSelectInputSelectedValue'; import styles from './HintedSelectInputSelectedValue.css'; function HintedSelectInputSelectedValue(props) { const { value, values, hint, isMultiSelect, includeHint, ...otherProps } = props; const valuesMap = isMultiSelect && _.keyBy(values, 'key'); return ( <EnhancedSelectInputSelectedValue className={styles.selectedValue} {...otherProps} > <div className={styles.valueText}> { isMultiSelect && value.map((key, index) => { const v = valuesMap[key]; return ( <Label key={key}> {v ? v.value : key} </Label> ); }) } { !isMultiSelect && value } </div> { hint != null && includeHint && <div className={styles.hintText}> {hint} </div> } </EnhancedSelectInputSelectedValue> ); } HintedSelectInputSelectedValue.propTypes = { value: PropTypes.oneOfType([PropTypes.string, PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.string, PropTypes.number]))]).isRequired, values: PropTypes.arrayOf(PropTypes.object).isRequired, hint: PropTypes.string, isMultiSelect: PropTypes.bool.isRequired, includeHint: PropTypes.bool.isRequired }; HintedSelectInputSelectedValue.defaultProps = { isMultiSelect: false, includeHint: true }; export default HintedSelectInputSelectedValue;
ajax/libs/yui/3.7.3/datatable-body/datatable-body-coverage.js
jonobr1/cdnjs
if (typeof _yuitest_coverage == "undefined"){ _yuitest_coverage = {}; _yuitest_coverline = function(src, line){ var coverage = _yuitest_coverage[src]; if (!coverage.lines[line]){ coverage.calledLines++; } coverage.lines[line]++; }; _yuitest_coverfunc = function(src, name, line){ var coverage = _yuitest_coverage[src], funcId = name + ":" + line; if (!coverage.functions[funcId]){ coverage.calledFunctions++; } coverage.functions[funcId]++; }; } _yuitest_coverage["build/datatable-body/datatable-body.js"] = { lines: {}, functions: {}, coveredLines: 0, calledLines: 0, coveredFunctions: 0, calledFunctions: 0, path: "build/datatable-body/datatable-body.js", code: [] }; _yuitest_coverage["build/datatable-body/datatable-body.js"].code=["YUI.add('datatable-body', function (Y, NAME) {","","/**","View class responsible for rendering the `<tbody>` section of a table. Used as","the default `bodyView` for `Y.DataTable.Base` and `Y.DataTable` classes.","","@module datatable","@submodule datatable-body","@since 3.5.0","**/","var Lang = Y.Lang,"," isArray = Lang.isArray,"," isNumber = Lang.isNumber,"," isString = Lang.isString,"," fromTemplate = Lang.sub,"," htmlEscape = Y.Escape.html,"," toArray = Y.Array,"," bind = Y.bind,"," YObject = Y.Object;","","/**","View class responsible for rendering the `<tbody>` section of a table. Used as","the default `bodyView` for `Y.DataTable.Base` and `Y.DataTable` classes.","","Translates the provided `modelList` into a rendered `<tbody>` based on the data","in the constituent Models, altered or ammended by any special column","configurations.","","The `columns` configuration, passed to the constructor, determines which","columns will be rendered.","","The rendering process involves constructing an HTML template for a complete row","of data, built by concatenating a customized copy of the instance's","`CELL_TEMPLATE` into the `ROW_TEMPLATE` once for each column. This template is","then populated with values from each Model in the `modelList`, aggregating a","complete HTML string of all row and column data. A `<tbody>` Node is then created from the markup and any column `nodeFormatter`s are applied.","","Supported properties of the column objects include:",""," * `key` - Used to link a column to an attribute in a Model."," * `name` - Used for columns that don't relate to an attribute in the Model"," (`formatter` or `nodeFormatter` only) if the implementer wants a"," predictable name to refer to in their CSS."," * `cellTemplate` - Overrides the instance's `CELL_TEMPLATE` for cells in this"," column only."," * `formatter` - Used to customize or override the content value from the"," Model. These do not have access to the cell or row Nodes and should"," return string (HTML) content."," * `nodeFormatter` - Used to provide content for a cell as well as perform any"," custom modifications on the cell or row Node that could not be performed by"," `formatter`s. Should be used sparingly for better performance."," * `emptyCellValue` - String (HTML) value to use if the Model data for a"," column, or the content generated by a `formatter`, is the empty string,"," `null`, or `undefined`."," * `allowHTML` - Set to `true` if a column value, `formatter`, or"," `emptyCellValue` can contain HTML. This defaults to `false` to protect"," against XSS."," * `className` - Space delimited CSS classes to add to all `<td>`s in a column.","","Column `formatter`s are passed an object (`o`) with the following properties:",""," * `value` - The current value of the column's associated attribute, if any."," * `data` - An object map of Model keys to their current values."," * `record` - The Model instance."," * `column` - The column configuration object for the current column."," * `className` - Initially empty string to allow `formatter`s to add CSS "," classes to the cell's `<td>`."," * `rowIndex` - The zero-based row number."," * `rowClass` - Initially empty string to allow `formatter`s to add CSS"," classes to the cell's containing row `<tr>`.","","They may return a value or update `o.value` to assign specific HTML content. A","returned value has higher precedence.","","Column `nodeFormatter`s are passed an object (`o`) with the following","properties:",""," * `value` - The current value of the column's associated attribute, if any."," * `td` - The `<td>` Node instance."," * `cell` - The `<div>` liner Node instance if present, otherwise, the `<td>`."," When adding content to the cell, prefer appending into this property."," * `data` - An object map of Model keys to their current values."," * `record` - The Model instance."," * `column` - The column configuration object for the current column."," * `rowIndex` - The zero-based row number.","","They are expected to inject content into the cell's Node directly, including","any \"empty\" cell content. Each `nodeFormatter` will have access through the","Node API to all cells and rows in the `<tbody>`, but not to the `<table>`, as","it will not be attached yet.","","If a `nodeFormatter` returns `false`, the `o.td` and `o.cell` Nodes will be","`destroy()`ed to remove them from the Node cache and free up memory. The DOM","elements will remain as will any content added to them. _It is highly","advisable to always return `false` from your `nodeFormatter`s_.","","@class BodyView","@namespace DataTable","@extends View","@since 3.5.0","**/","Y.namespace('DataTable').BodyView = Y.Base.create('tableBody', Y.View, [], {"," // -- Instance properties -------------------------------------------------",""," /**"," HTML template used to create table cells.",""," @property CELL_TEMPLATE"," @type {HTML}"," @default '<td {headers} class=\"{className}\">{content}</td>'"," @since 3.5.0"," **/"," CELL_TEMPLATE: '<td {headers} class=\"{className}\">{content}</td>',",""," /**"," CSS class applied to even rows. This is assigned at instantiation."," "," For DataTable, this will be `yui3-datatable-even`.",""," @property CLASS_EVEN"," @type {String}"," @default 'yui3-table-even'"," @since 3.5.0"," **/"," //CLASS_EVEN: null",""," /**"," CSS class applied to odd rows. This is assigned at instantiation."," "," When used by DataTable instances, this will be `yui3-datatable-odd`.",""," @property CLASS_ODD"," @type {String}"," @default 'yui3-table-odd'"," @since 3.5.0"," **/"," //CLASS_ODD: null",""," /**"," HTML template used to create table rows.",""," @property ROW_TEMPLATE"," @type {HTML}"," @default '<tr id=\"{rowId}\" data-yui3-record=\"{clientId}\" class=\"{rowClass}\">{content}</tr>'"," @since 3.5.0"," **/"," ROW_TEMPLATE : '<tr id=\"{rowId}\" data-yui3-record=\"{clientId}\" class=\"{rowClass}\">{content}</tr>',",""," /**"," The object that serves as the source of truth for column and row data."," This property is assigned at instantiation from the `host` property of"," the configuration object passed to the constructor.",""," @property host"," @type {Object}"," @default (initially unset)"," @since 3.5.0"," **/"," //TODO: should this be protected?"," //host: null,",""," /**"," HTML templates used to create the `<tbody>` containing the table rows.",""," @property TBODY_TEMPLATE"," @type {HTML}"," @default '<tbody class=\"{className}\">{content}</tbody>'"," @since 3.6.0"," **/"," TBODY_TEMPLATE: '<tbody class=\"{className}\"></tbody>',",""," // -- Public methods ------------------------------------------------------",""," /**"," Returns the `<td>` Node from the given row and column index. Alternately,"," the `seed` can be a Node. If so, the nearest ancestor cell is returned."," If the `seed` is a cell, it is returned. If there is no cell at the given"," coordinates, `null` is returned.",""," Optionally, include an offset array or string to return a cell near the"," cell identified by the `seed`. The offset can be an array containing the"," number of rows to shift followed by the number of columns to shift, or one"," of \"above\", \"below\", \"next\", or \"previous\".",""," <pre><code>// Previous cell in the previous row"," var cell = table.getCell(e.target, [-1, -1]);",""," // Next cell"," var cell = table.getCell(e.target, 'next');"," var cell = table.getCell(e.taregt, [0, 1];</pre></code>",""," @method getCell"," @param {Number[]|Node} seed Array of row and column indexes, or a Node that"," is either the cell itself or a descendant of one."," @param {Number[]|String} [shift] Offset by which to identify the returned"," cell Node"," @return {Node}"," @since 3.5.0"," **/"," getCell: function (seed, shift) {"," var tbody = this.tbodyNode,"," row, cell, index, rowIndexOffset;",""," if (seed && tbody) {"," if (isArray(seed)) {"," row = tbody.get('children').item(seed[0]);"," cell = row && row.get('children').item(seed[1]);"," } else if (Y.instanceOf(seed, Y.Node)) {"," cell = seed.ancestor('.' + this.getClassName('cell'), true);"," }",""," if (cell && shift) {"," rowIndexOffset = tbody.get('firstChild.rowIndex');"," if (isString(shift)) {"," // TODO this should be a static object map"," switch (shift) {"," case 'above' : shift = [-1, 0]; break;"," case 'below' : shift = [1, 0]; break;"," case 'next' : shift = [0, 1]; break;"," case 'previous': shift = [0, -1]; break;"," }"," }",""," if (isArray(shift)) {"," index = cell.get('parentNode.rowIndex') +"," shift[0] - rowIndexOffset;"," row = tbody.get('children').item(index);",""," index = cell.get('cellIndex') + shift[1];"," cell = row && row.get('children').item(index);"," }"," }"," }"," "," return cell || null;"," },",""," /**"," Returns the generated CSS classname based on the input. If the `host`"," attribute is configured, it will attempt to relay to its `getClassName`"," or use its static `NAME` property as a string base."," "," If `host` is absent or has neither method nor `NAME`, a CSS classname"," will be generated using this class's `NAME`.",""," @method getClassName"," @param {String} token* Any number of token strings to assemble the"," classname from."," @return {String}"," @protected"," @since 3.5.0"," **/"," getClassName: function () {"," var host = this.host,"," args;",""," if (host && host.getClassName) {"," return host.getClassName.apply(host, arguments);"," } else {"," args = toArray(arguments);"," args.unshift(this.constructor.NAME);"," return Y.ClassNameManager.getClassName"," .apply(Y.ClassNameManager, args);"," }"," },",""," /**"," Returns the Model associated to the row Node or id provided. Passing the"," Node or id for a descendant of the row also works.",""," If no Model can be found, `null` is returned.",""," @method getRecord"," @param {String|Node} seed Row Node or `id`, or one for a descendant of a row"," @return {Model}"," @since 3.5.0"," **/"," getRecord: function (seed) {"," var modelList = this.get('modelList'),"," tbody = this.tbodyNode,"," row = null,"," record;",""," if (tbody) {"," if (isString(seed)) {"," seed = tbody.one('#' + seed);"," }",""," if (Y.instanceOf(seed, Y.Node)) {"," row = seed.ancestor(function (node) {"," return node.get('parentNode').compareTo(tbody);"," }, true);",""," record = row &&"," modelList.getByClientId(row.getData('yui3-record'));"," }"," }",""," return record || null;"," },",""," /**"," Returns the `<tr>` Node from the given row index, Model, or Model's"," `clientId`. If the rows haven't been rendered yet, or if the row can't be"," found by the input, `null` is returned.",""," @method getRow"," @param {Number|String|Model} id Row index, Model instance, or clientId"," @return {Node}"," @since 3.5.0"," **/"," getRow: function (id) {"," var tbody = this.tbodyNode,"," row = null;",""," if (tbody) {"," if (id) {"," id = this._idMap[id.get ? id.get('clientId') : id] || id;"," }",""," row = isNumber(id) ?"," tbody.get('children').item(id) :"," tbody.one('#' + id);"," }",""," return row;"," },",""," /**"," Creates the table's `<tbody>` content by assembling markup generated by"," populating the `ROW\\_TEMPLATE`, and `CELL\\_TEMPLATE` templates with content"," from the `columns` and `modelList` attributes.",""," The rendering process happens in three stages:",""," 1. A row template is assembled from the `columns` attribute (see"," `_createRowTemplate`)",""," 2. An HTML string is built up by concatening the application of the data in"," each Model in the `modelList` to the row template. For cells with"," `formatter`s, the function is called to generate cell content. Cells"," with `nodeFormatter`s are ignored. For all other cells, the data value"," from the Model attribute for the given column key is used. The"," accumulated row markup is then inserted into the container.",""," 3. If any column is configured with a `nodeFormatter`, the `modelList` is"," iterated again to apply the `nodeFormatter`s.",""," Supported properties of the column objects include:",""," * `key` - Used to link a column to an attribute in a Model."," * `name` - Used for columns that don't relate to an attribute in the Model"," (`formatter` or `nodeFormatter` only) if the implementer wants a"," predictable name to refer to in their CSS."," * `cellTemplate` - Overrides the instance's `CELL_TEMPLATE` for cells in"," this column only."," * `formatter` - Used to customize or override the content value from the"," Model. These do not have access to the cell or row Nodes and should"," return string (HTML) content."," * `nodeFormatter` - Used to provide content for a cell as well as perform"," any custom modifications on the cell or row Node that could not be"," performed by `formatter`s. Should be used sparingly for better"," performance."," * `emptyCellValue` - String (HTML) value to use if the Model data for a"," column, or the content generated by a `formatter`, is the empty string,"," `null`, or `undefined`."," * `allowHTML` - Set to `true` if a column value, `formatter`, or"," `emptyCellValue` can contain HTML. This defaults to `false` to protect"," against XSS."," * `className` - Space delimited CSS classes to add to all `<td>`s in a"," column.",""," Column `formatter`s are passed an object (`o`) with the following"," properties:",""," * `value` - The current value of the column's associated attribute, if"," any."," * `data` - An object map of Model keys to their current values."," * `record` - The Model instance."," * `column` - The column configuration object for the current column."," * `className` - Initially empty string to allow `formatter`s to add CSS "," classes to the cell's `<td>`."," * `rowIndex` - The zero-based row number."," * `rowClass` - Initially empty string to allow `formatter`s to add CSS"," classes to the cell's containing row `<tr>`.",""," They may return a value or update `o.value` to assign specific HTML"," content. A returned value has higher precedence.",""," Column `nodeFormatter`s are passed an object (`o`) with the following"," properties:",""," * `value` - The current value of the column's associated attribute, if"," any."," * `td` - The `<td>` Node instance."," * `cell` - The `<div>` liner Node instance if present, otherwise, the"," `<td>`. When adding content to the cell, prefer appending into this"," property."," * `data` - An object map of Model keys to their current values."," * `record` - The Model instance."," * `column` - The column configuration object for the current column."," * `rowIndex` - The zero-based row number.",""," They are expected to inject content into the cell's Node directly, including"," any \"empty\" cell content. Each `nodeFormatter` will have access through the"," Node API to all cells and rows in the `<tbody>`, but not to the `<table>`,"," as it will not be attached yet.",""," If a `nodeFormatter` returns `false`, the `o.td` and `o.cell` Nodes will be"," `destroy()`ed to remove them from the Node cache and free up memory. The"," DOM elements will remain as will any content added to them. _It is highly"," advisable to always return `false` from your `nodeFormatter`s_.",""," @method render"," @return {BodyView} The instance"," @chainable"," @since 3.5.0"," **/"," render: function () {"," var table = this.get('container'),"," data = this.get('modelList'),"," columns = this.get('columns'),"," tbody = this.tbodyNode ||"," (this.tbodyNode = this._createTBodyNode());"," "," // Needed for mutation"," this._createRowTemplate(columns);",""," if (data) {"," tbody.setHTML(this._createDataHTML(columns));",""," this._applyNodeFormatters(tbody, columns);"," }",""," if (tbody.get('parentNode') !== table) {"," table.appendChild(tbody);"," }",""," this.bindUI();",""," return this;"," },",""," // -- Protected and private methods ---------------------------------------"," /**"," Handles changes in the source's columns attribute. Redraws the table data.",""," @method _afterColumnsChange"," @param {EventFacade} e The `columnsChange` event object"," @protected"," @since 3.5.0"," **/"," // TODO: Preserve existing DOM"," // This will involve parsing and comparing the old and new column configs"," // and reacting to four types of changes:"," // 1. formatter, nodeFormatter, emptyCellValue changes"," // 2. column deletions"," // 3. column additions"," // 4. column moves (preserve cells)"," _afterColumnsChange: function (e) {"," this.render();"," },",""," /**"," Handles modelList changes, including additions, deletions, and updates.",""," Modifies the existing table DOM accordingly.",""," @method _afterDataChange"," @param {EventFacade} e The `change` event from the ModelList"," @protected"," @since 3.5.0"," **/"," _afterDataChange: function (e) {"," //var type = e.type.slice(e.type.lastIndexOf(':') + 1);",""," // TODO: Isolate changes"," this.render();"," },",""," /**"," Handles replacement of the modelList.",""," Rerenders the `<tbody>` contents.",""," @method _afterModelListChange"," @param {EventFacade} e The `modelListChange` event"," @protected"," @since 3.6.0"," **/"," _afterModelListChange: function (e) {"," var handles = this._eventHandles;",""," if (handles.dataChange) {"," handles.dataChange.detach();"," delete handles.dataChange;"," this.bindUI();"," }",""," if (this.tbodyNode) {"," this.render();"," }"," },",""," /**"," Iterates the `modelList`, and calls any `nodeFormatter`s found in the"," `columns` param on the appropriate cell Nodes in the `tbody`.",""," @method _applyNodeFormatters"," @param {Node} tbody The `<tbody>` Node whose columns to update"," @param {Object[]} columns The column configurations"," @protected"," @since 3.5.0"," **/"," _applyNodeFormatters: function (tbody, columns) {"," var host = this.host,"," data = this.get('modelList'),"," formatters = [],"," linerQuery = '.' + this.getClassName('liner'),"," rows, i, len;",""," // Only iterate the ModelList again if there are nodeFormatters"," for (i = 0, len = columns.length; i < len; ++i) {"," if (columns[i].nodeFormatter) {"," formatters.push(i);"," }"," }",""," if (data && formatters.length) {"," rows = tbody.get('childNodes');",""," data.each(function (record, index) {"," var formatterData = {"," data : record.toJSON(),"," record : record,"," rowIndex : index"," },"," row = rows.item(index),"," i, len, col, key, cells, cell, keep;","",""," if (row) {"," cells = row.get('childNodes');"," for (i = 0, len = formatters.length; i < len; ++i) {"," cell = cells.item(formatters[i]);",""," if (cell) {"," col = formatterData.column = columns[formatters[i]];"," key = col.key || col.id;",""," formatterData.value = record.get(key);"," formatterData.td = cell;"," formatterData.cell = cell.one(linerQuery) || cell;",""," keep = col.nodeFormatter.call(host,formatterData);",""," if (keep === false) {"," // Remove from the Node cache to reduce"," // memory footprint. This also purges events,"," // which you shouldn't be scoping to a cell"," // anyway. You've been warned. Incidentally,"," // you should always return false. Just sayin."," cell.destroy(true);"," }"," }"," }"," }"," });"," }"," },",""," /**"," Binds event subscriptions from the UI and the host (if assigned).",""," @method bindUI"," @protected"," @since 3.5.0"," **/"," bindUI: function () {"," var handles = this._eventHandles,"," modelList = this.get('modelList'),"," changeEvent = modelList.model.NAME + ':change';",""," if (!handles.columnsChange) {"," handles.columnsChange = this.after('columnsChange',"," bind('_afterColumnsChange', this));"," }",""," if (modelList && !handles.dataChange) {"," handles.dataChange = modelList.after("," ['add', 'remove', 'reset', changeEvent],"," bind('_afterDataChange', this));"," }"," },",""," /**"," Iterates the `modelList` and applies each Model to the `_rowTemplate`,"," allowing any column `formatter` or `emptyCellValue` to override cell"," content for the appropriate column. The aggregated HTML string is"," returned.",""," @method _createDataHTML"," @param {Object[]} columns The column configurations to customize the"," generated cell content or class names"," @return {HTML} The markup for all Models in the `modelList`, each applied"," to the `_rowTemplate`"," @protected"," @since 3.5.0"," **/"," _createDataHTML: function (columns) {"," var data = this.get('modelList'),"," html = '';",""," if (data) {"," data.each(function (model, index) {"," html += this._createRowHTML(model, index, columns);"," }, this);"," }",""," return html;"," },",""," /**"," Applies the data of a given Model, modified by any column formatters and"," supplemented by other template values to the instance's `_rowTemplate` (see"," `_createRowTemplate`). The generated string is then returned.",""," The data from Model's attributes is fetched by `toJSON` and this data"," object is appended with other properties to supply values to {placeholders}"," in the template. For a template generated from a Model with 'foo' and 'bar'"," attributes, the data object would end up with the following properties"," before being used to populate the `_rowTemplate`:",""," * `clientID` - From Model, used the assign the `<tr>`'s 'id' attribute."," * `foo` - The value to populate the 'foo' column cell content. This"," value will be the value stored in the Model's `foo` attribute, or the"," result of the column's `formatter` if assigned. If the value is '', "," `null`, or `undefined`, and the column's `emptyCellValue` is assigned,"," that value will be used."," * `bar` - Same for the 'bar' column cell content."," * `foo-className` - String of CSS classes to apply to the `<td>`."," * `bar-className` - Same."," * `rowClass` - String of CSS classes to apply to the `<tr>`. This"," will be the odd/even class per the specified index plus any additional"," classes assigned by column formatters (via `o.rowClass`).",""," Because this object is available to formatters, any additional properties"," can be added to fill in custom {placeholders} in the `_rowTemplate`.",""," @method _createRowHTML"," @param {Model} model The Model instance to apply to the row template"," @param {Number} index The index the row will be appearing"," @param {Object[]} columns The column configurations"," @return {HTML} The markup for the provided Model, less any `nodeFormatter`s"," @protected"," @since 3.5.0"," **/"," _createRowHTML: function (model, index, columns) {"," var data = model.toJSON(),"," clientId = model.get('clientId'),"," values = {"," rowId : this._getRowId(clientId),"," clientId: clientId,"," rowClass: (index % 2) ? this.CLASS_ODD : this.CLASS_EVEN"," },"," host = this.host || this,"," i, len, col, token, value, formatterData;",""," for (i = 0, len = columns.length; i < len; ++i) {"," col = columns[i];"," value = data[col.key];"," token = col._id || col.key;",""," values[token + '-className'] = '';",""," if (col.formatter) {"," formatterData = {"," value : value,"," data : data,"," column : col,"," record : model,"," className: '',"," rowClass : '',"," rowIndex : index"," };",""," if (typeof col.formatter === 'string') {"," if (value !== undefined) {"," // TODO: look for known formatters by string name"," value = fromTemplate(col.formatter, formatterData);"," }"," } else {"," // Formatters can either return a value"," value = col.formatter.call(host, formatterData);",""," // or update the value property of the data obj passed"," if (value === undefined) {"," value = formatterData.value;"," }",""," values[token + '-className'] = formatterData.className;"," values.rowClass += ' ' + formatterData.rowClass;"," }"," }",""," if (value === undefined || value === null || value === '') {"," value = col.emptyCellValue || '';"," }",""," values[token] = col.allowHTML ? value : htmlEscape(value);",""," values.rowClass = values.rowClass.replace(/\\s+/g, ' ');"," }",""," return fromTemplate(this._rowTemplate, values);"," },",""," /**"," Creates a custom HTML template string for use in generating the markup for"," individual table rows with {placeholder}s to capture data from the Models"," in the `modelList` attribute or from column `formatter`s.",""," Assigns the `_rowTemplate` property.",""," @method _createRowTemplate"," @param {Object[]} columns Array of column configuration objects"," @protected"," @since 3.5.0"," **/"," _createRowTemplate: function (columns) {"," var html = '',"," cellTemplate = this.CELL_TEMPLATE,"," i, len, col, key, token, headers, tokenValues;",""," for (i = 0, len = columns.length; i < len; ++i) {"," col = columns[i];"," key = col.key;"," token = col._id || key;"," // Only include headers if there are more than one"," headers = (col._headers || []).length > 1 ?"," 'headers=\"' + col._headers.join(' ') + '\"' : '';",""," tokenValues = {"," content : '{' + token + '}',"," headers : headers,"," className: this.getClassName('col', token) + ' ' +"," (col.className || '') + ' ' +"," this.getClassName('cell') +"," ' {' + token + '-className}'"," };",""," if (col.nodeFormatter) {"," // Defer all node decoration to the formatter"," tokenValues.content = '';"," }",""," html += fromTemplate(col.cellTemplate || cellTemplate, tokenValues);"," }",""," this._rowTemplate = fromTemplate(this.ROW_TEMPLATE, {"," content: html"," });"," },",""," /**"," Creates the `<tbody>` node that will store the data rows.",""," @method _createTBodyNode"," @return {Node}"," @protected"," @since 3.6.0"," **/"," _createTBodyNode: function () {"," return Y.Node.create(fromTemplate(this.TBODY_TEMPLATE, {"," className: this.getClassName('data')"," }));"," },",""," /**"," Destroys the instance.",""," @method destructor"," @protected"," @since 3.5.0"," **/"," destructor: function () {"," (new Y.EventHandle(YObject.values(this._eventHandles))).detach();"," },",""," /**"," Holds the event subscriptions needing to be detached when the instance is"," `destroy()`ed.",""," @property _eventHandles"," @type {Object}"," @default undefined (initially unset)"," @protected"," @since 3.5.0"," **/"," //_eventHandles: null,",""," /**"," Returns the row ID associated with a Model's clientId.",""," @method _getRowId"," @param {String} clientId The Model clientId"," @return {String}"," @protected"," **/"," _getRowId: function (clientId) {"," return this._idMap[clientId] || (this._idMap[clientId] = Y.guid());"," },",""," /**"," Map of Model clientIds to row ids.",""," @property _idMap"," @type {Object}"," @protected"," **/"," //_idMap,",""," /**"," Initializes the instance. Reads the following configuration properties in"," addition to the instance attributes:",""," * `columns` - (REQUIRED) The initial column information"," * `host` - The object to serve as source of truth for column info and"," for generating class names",""," @method initializer"," @param {Object} config Configuration data"," @protected"," @since 3.5.0"," **/"," initializer: function (config) {"," this.host = config.host;",""," this._eventHandles = {"," modelListChange: this.after('modelListChange',"," bind('_afterModelListChange', this))"," };"," this._idMap = {};",""," this.CLASS_ODD = this.getClassName('odd');"," this.CLASS_EVEN = this.getClassName('even');",""," }",""," /**"," The HTML template used to create a full row of markup for a single Model in"," the `modelList` plus any customizations defined in the column"," configurations.",""," @property _rowTemplate"," @type {HTML}"," @default (initially unset)"," @protected"," @since 3.5.0"," **/"," //_rowTemplate: null","});","","","}, '@VERSION@', {\"requires\": [\"datatable-core\", \"view\", \"classnamemanager\"]});"]; _yuitest_coverage["build/datatable-body/datatable-body.js"].lines = {"1":0,"11":0,"102":0,"201":0,"204":0,"205":0,"206":0,"207":0,"208":0,"209":0,"212":0,"213":0,"214":0,"216":0,"217":0,"218":0,"219":0,"220":0,"224":0,"225":0,"227":0,"229":0,"230":0,"235":0,"254":0,"257":0,"258":0,"260":0,"261":0,"262":0,"279":0,"284":0,"285":0,"286":0,"289":0,"290":0,"291":0,"294":0,"299":0,"313":0,"316":0,"317":0,"318":0,"321":0,"326":0,"420":0,"427":0,"429":0,"430":0,"432":0,"435":0,"436":0,"439":0,"441":0,"461":0,"478":0,"492":0,"494":0,"495":0,"496":0,"497":0,"500":0,"501":0,"516":0,"523":0,"524":0,"525":0,"529":0,"530":0,"532":0,"533":0,"542":0,"543":0,"544":0,"545":0,"547":0,"548":0,"549":0,"551":0,"552":0,"553":0,"555":0,"557":0,"563":0,"580":0,"584":0,"585":0,"589":0,"590":0,"611":0,"614":0,"615":0,"616":0,"620":0,"659":0,"669":0,"670":0,"671":0,"672":0,"674":0,"676":0,"677":0,"687":0,"688":0,"690":0,"694":0,"697":0,"698":0,"701":0,"702":0,"706":0,"707":0,"710":0,"712":0,"715":0,"731":0,"735":0,"736":0,"737":0,"738":0,"740":0,"743":0,"752":0,"754":0,"757":0,"760":0,"774":0,"787":0,"811":0,"837":0,"839":0,"843":0,"845":0,"846":0}; _yuitest_coverage["build/datatable-body/datatable-body.js"].functions = {"getCell:200":0,"getClassName:253":0,"(anonymous 2):290":0,"getRecord:278":0,"getRow:312":0,"render:419":0,"_afterColumnsChange:460":0,"_afterDataChange:474":0,"_afterModelListChange:491":0,"(anonymous 3):532":0,"_applyNodeFormatters:515":0,"bindUI:579":0,"(anonymous 4):615":0,"_createDataHTML:610":0,"_createRowHTML:658":0,"_createRowTemplate:730":0,"_createTBodyNode:773":0,"destructor:786":0,"_getRowId:810":0,"initializer:836":0,"(anonymous 1):1":0}; _yuitest_coverage["build/datatable-body/datatable-body.js"].coveredLines = 134; _yuitest_coverage["build/datatable-body/datatable-body.js"].coveredFunctions = 21; _yuitest_coverline("build/datatable-body/datatable-body.js", 1); YUI.add('datatable-body', function (Y, NAME) { /** View class responsible for rendering the `<tbody>` section of a table. Used as the default `bodyView` for `Y.DataTable.Base` and `Y.DataTable` classes. @module datatable @submodule datatable-body @since 3.5.0 **/ _yuitest_coverfunc("build/datatable-body/datatable-body.js", "(anonymous 1)", 1); _yuitest_coverline("build/datatable-body/datatable-body.js", 11); var Lang = Y.Lang, isArray = Lang.isArray, isNumber = Lang.isNumber, isString = Lang.isString, fromTemplate = Lang.sub, htmlEscape = Y.Escape.html, toArray = Y.Array, bind = Y.bind, YObject = Y.Object; /** View class responsible for rendering the `<tbody>` section of a table. Used as the default `bodyView` for `Y.DataTable.Base` and `Y.DataTable` classes. Translates the provided `modelList` into a rendered `<tbody>` based on the data in the constituent Models, altered or ammended by any special column configurations. The `columns` configuration, passed to the constructor, determines which columns will be rendered. The rendering process involves constructing an HTML template for a complete row of data, built by concatenating a customized copy of the instance's `CELL_TEMPLATE` into the `ROW_TEMPLATE` once for each column. This template is then populated with values from each Model in the `modelList`, aggregating a complete HTML string of all row and column data. A `<tbody>` Node is then created from the markup and any column `nodeFormatter`s are applied. Supported properties of the column objects include: * `key` - Used to link a column to an attribute in a Model. * `name` - Used for columns that don't relate to an attribute in the Model (`formatter` or `nodeFormatter` only) if the implementer wants a predictable name to refer to in their CSS. * `cellTemplate` - Overrides the instance's `CELL_TEMPLATE` for cells in this column only. * `formatter` - Used to customize or override the content value from the Model. These do not have access to the cell or row Nodes and should return string (HTML) content. * `nodeFormatter` - Used to provide content for a cell as well as perform any custom modifications on the cell or row Node that could not be performed by `formatter`s. Should be used sparingly for better performance. * `emptyCellValue` - String (HTML) value to use if the Model data for a column, or the content generated by a `formatter`, is the empty string, `null`, or `undefined`. * `allowHTML` - Set to `true` if a column value, `formatter`, or `emptyCellValue` can contain HTML. This defaults to `false` to protect against XSS. * `className` - Space delimited CSS classes to add to all `<td>`s in a column. Column `formatter`s are passed an object (`o`) with the following properties: * `value` - The current value of the column's associated attribute, if any. * `data` - An object map of Model keys to their current values. * `record` - The Model instance. * `column` - The column configuration object for the current column. * `className` - Initially empty string to allow `formatter`s to add CSS classes to the cell's `<td>`. * `rowIndex` - The zero-based row number. * `rowClass` - Initially empty string to allow `formatter`s to add CSS classes to the cell's containing row `<tr>`. They may return a value or update `o.value` to assign specific HTML content. A returned value has higher precedence. Column `nodeFormatter`s are passed an object (`o`) with the following properties: * `value` - The current value of the column's associated attribute, if any. * `td` - The `<td>` Node instance. * `cell` - The `<div>` liner Node instance if present, otherwise, the `<td>`. When adding content to the cell, prefer appending into this property. * `data` - An object map of Model keys to their current values. * `record` - The Model instance. * `column` - The column configuration object for the current column. * `rowIndex` - The zero-based row number. They are expected to inject content into the cell's Node directly, including any "empty" cell content. Each `nodeFormatter` will have access through the Node API to all cells and rows in the `<tbody>`, but not to the `<table>`, as it will not be attached yet. If a `nodeFormatter` returns `false`, the `o.td` and `o.cell` Nodes will be `destroy()`ed to remove them from the Node cache and free up memory. The DOM elements will remain as will any content added to them. _It is highly advisable to always return `false` from your `nodeFormatter`s_. @class BodyView @namespace DataTable @extends View @since 3.5.0 **/ _yuitest_coverline("build/datatable-body/datatable-body.js", 102); Y.namespace('DataTable').BodyView = Y.Base.create('tableBody', Y.View, [], { // -- Instance properties ------------------------------------------------- /** HTML template used to create table cells. @property CELL_TEMPLATE @type {HTML} @default '<td {headers} class="{className}">{content}</td>' @since 3.5.0 **/ CELL_TEMPLATE: '<td {headers} class="{className}">{content}</td>', /** CSS class applied to even rows. This is assigned at instantiation. For DataTable, this will be `yui3-datatable-even`. @property CLASS_EVEN @type {String} @default 'yui3-table-even' @since 3.5.0 **/ //CLASS_EVEN: null /** CSS class applied to odd rows. This is assigned at instantiation. When used by DataTable instances, this will be `yui3-datatable-odd`. @property CLASS_ODD @type {String} @default 'yui3-table-odd' @since 3.5.0 **/ //CLASS_ODD: null /** HTML template used to create table rows. @property ROW_TEMPLATE @type {HTML} @default '<tr id="{rowId}" data-yui3-record="{clientId}" class="{rowClass}">{content}</tr>' @since 3.5.0 **/ ROW_TEMPLATE : '<tr id="{rowId}" data-yui3-record="{clientId}" class="{rowClass}">{content}</tr>', /** The object that serves as the source of truth for column and row data. This property is assigned at instantiation from the `host` property of the configuration object passed to the constructor. @property host @type {Object} @default (initially unset) @since 3.5.0 **/ //TODO: should this be protected? //host: null, /** HTML templates used to create the `<tbody>` containing the table rows. @property TBODY_TEMPLATE @type {HTML} @default '<tbody class="{className}">{content}</tbody>' @since 3.6.0 **/ TBODY_TEMPLATE: '<tbody class="{className}"></tbody>', // -- Public methods ------------------------------------------------------ /** Returns the `<td>` Node from the given row and column index. Alternately, the `seed` can be a Node. If so, the nearest ancestor cell is returned. If the `seed` is a cell, it is returned. If there is no cell at the given coordinates, `null` is returned. Optionally, include an offset array or string to return a cell near the cell identified by the `seed`. The offset can be an array containing the number of rows to shift followed by the number of columns to shift, or one of "above", "below", "next", or "previous". <pre><code>// Previous cell in the previous row var cell = table.getCell(e.target, [-1, -1]); // Next cell var cell = table.getCell(e.target, 'next'); var cell = table.getCell(e.taregt, [0, 1];</pre></code> @method getCell @param {Number[]|Node} seed Array of row and column indexes, or a Node that is either the cell itself or a descendant of one. @param {Number[]|String} [shift] Offset by which to identify the returned cell Node @return {Node} @since 3.5.0 **/ getCell: function (seed, shift) { _yuitest_coverfunc("build/datatable-body/datatable-body.js", "getCell", 200); _yuitest_coverline("build/datatable-body/datatable-body.js", 201); var tbody = this.tbodyNode, row, cell, index, rowIndexOffset; _yuitest_coverline("build/datatable-body/datatable-body.js", 204); if (seed && tbody) { _yuitest_coverline("build/datatable-body/datatable-body.js", 205); if (isArray(seed)) { _yuitest_coverline("build/datatable-body/datatable-body.js", 206); row = tbody.get('children').item(seed[0]); _yuitest_coverline("build/datatable-body/datatable-body.js", 207); cell = row && row.get('children').item(seed[1]); } else {_yuitest_coverline("build/datatable-body/datatable-body.js", 208); if (Y.instanceOf(seed, Y.Node)) { _yuitest_coverline("build/datatable-body/datatable-body.js", 209); cell = seed.ancestor('.' + this.getClassName('cell'), true); }} _yuitest_coverline("build/datatable-body/datatable-body.js", 212); if (cell && shift) { _yuitest_coverline("build/datatable-body/datatable-body.js", 213); rowIndexOffset = tbody.get('firstChild.rowIndex'); _yuitest_coverline("build/datatable-body/datatable-body.js", 214); if (isString(shift)) { // TODO this should be a static object map _yuitest_coverline("build/datatable-body/datatable-body.js", 216); switch (shift) { case 'above' : _yuitest_coverline("build/datatable-body/datatable-body.js", 217); shift = [-1, 0]; break; case 'below' : _yuitest_coverline("build/datatable-body/datatable-body.js", 218); shift = [1, 0]; break; case 'next' : _yuitest_coverline("build/datatable-body/datatable-body.js", 219); shift = [0, 1]; break; case 'previous': _yuitest_coverline("build/datatable-body/datatable-body.js", 220); shift = [0, -1]; break; } } _yuitest_coverline("build/datatable-body/datatable-body.js", 224); if (isArray(shift)) { _yuitest_coverline("build/datatable-body/datatable-body.js", 225); index = cell.get('parentNode.rowIndex') + shift[0] - rowIndexOffset; _yuitest_coverline("build/datatable-body/datatable-body.js", 227); row = tbody.get('children').item(index); _yuitest_coverline("build/datatable-body/datatable-body.js", 229); index = cell.get('cellIndex') + shift[1]; _yuitest_coverline("build/datatable-body/datatable-body.js", 230); cell = row && row.get('children').item(index); } } } _yuitest_coverline("build/datatable-body/datatable-body.js", 235); return cell || null; }, /** Returns the generated CSS classname based on the input. If the `host` attribute is configured, it will attempt to relay to its `getClassName` or use its static `NAME` property as a string base. If `host` is absent or has neither method nor `NAME`, a CSS classname will be generated using this class's `NAME`. @method getClassName @param {String} token* Any number of token strings to assemble the classname from. @return {String} @protected @since 3.5.0 **/ getClassName: function () { _yuitest_coverfunc("build/datatable-body/datatable-body.js", "getClassName", 253); _yuitest_coverline("build/datatable-body/datatable-body.js", 254); var host = this.host, args; _yuitest_coverline("build/datatable-body/datatable-body.js", 257); if (host && host.getClassName) { _yuitest_coverline("build/datatable-body/datatable-body.js", 258); return host.getClassName.apply(host, arguments); } else { _yuitest_coverline("build/datatable-body/datatable-body.js", 260); args = toArray(arguments); _yuitest_coverline("build/datatable-body/datatable-body.js", 261); args.unshift(this.constructor.NAME); _yuitest_coverline("build/datatable-body/datatable-body.js", 262); return Y.ClassNameManager.getClassName .apply(Y.ClassNameManager, args); } }, /** Returns the Model associated to the row Node or id provided. Passing the Node or id for a descendant of the row also works. If no Model can be found, `null` is returned. @method getRecord @param {String|Node} seed Row Node or `id`, or one for a descendant of a row @return {Model} @since 3.5.0 **/ getRecord: function (seed) { _yuitest_coverfunc("build/datatable-body/datatable-body.js", "getRecord", 278); _yuitest_coverline("build/datatable-body/datatable-body.js", 279); var modelList = this.get('modelList'), tbody = this.tbodyNode, row = null, record; _yuitest_coverline("build/datatable-body/datatable-body.js", 284); if (tbody) { _yuitest_coverline("build/datatable-body/datatable-body.js", 285); if (isString(seed)) { _yuitest_coverline("build/datatable-body/datatable-body.js", 286); seed = tbody.one('#' + seed); } _yuitest_coverline("build/datatable-body/datatable-body.js", 289); if (Y.instanceOf(seed, Y.Node)) { _yuitest_coverline("build/datatable-body/datatable-body.js", 290); row = seed.ancestor(function (node) { _yuitest_coverfunc("build/datatable-body/datatable-body.js", "(anonymous 2)", 290); _yuitest_coverline("build/datatable-body/datatable-body.js", 291); return node.get('parentNode').compareTo(tbody); }, true); _yuitest_coverline("build/datatable-body/datatable-body.js", 294); record = row && modelList.getByClientId(row.getData('yui3-record')); } } _yuitest_coverline("build/datatable-body/datatable-body.js", 299); return record || null; }, /** Returns the `<tr>` Node from the given row index, Model, or Model's `clientId`. If the rows haven't been rendered yet, or if the row can't be found by the input, `null` is returned. @method getRow @param {Number|String|Model} id Row index, Model instance, or clientId @return {Node} @since 3.5.0 **/ getRow: function (id) { _yuitest_coverfunc("build/datatable-body/datatable-body.js", "getRow", 312); _yuitest_coverline("build/datatable-body/datatable-body.js", 313); var tbody = this.tbodyNode, row = null; _yuitest_coverline("build/datatable-body/datatable-body.js", 316); if (tbody) { _yuitest_coverline("build/datatable-body/datatable-body.js", 317); if (id) { _yuitest_coverline("build/datatable-body/datatable-body.js", 318); id = this._idMap[id.get ? id.get('clientId') : id] || id; } _yuitest_coverline("build/datatable-body/datatable-body.js", 321); row = isNumber(id) ? tbody.get('children').item(id) : tbody.one('#' + id); } _yuitest_coverline("build/datatable-body/datatable-body.js", 326); return row; }, /** Creates the table's `<tbody>` content by assembling markup generated by populating the `ROW\_TEMPLATE`, and `CELL\_TEMPLATE` templates with content from the `columns` and `modelList` attributes. The rendering process happens in three stages: 1. A row template is assembled from the `columns` attribute (see `_createRowTemplate`) 2. An HTML string is built up by concatening the application of the data in each Model in the `modelList` to the row template. For cells with `formatter`s, the function is called to generate cell content. Cells with `nodeFormatter`s are ignored. For all other cells, the data value from the Model attribute for the given column key is used. The accumulated row markup is then inserted into the container. 3. If any column is configured with a `nodeFormatter`, the `modelList` is iterated again to apply the `nodeFormatter`s. Supported properties of the column objects include: * `key` - Used to link a column to an attribute in a Model. * `name` - Used for columns that don't relate to an attribute in the Model (`formatter` or `nodeFormatter` only) if the implementer wants a predictable name to refer to in their CSS. * `cellTemplate` - Overrides the instance's `CELL_TEMPLATE` for cells in this column only. * `formatter` - Used to customize or override the content value from the Model. These do not have access to the cell or row Nodes and should return string (HTML) content. * `nodeFormatter` - Used to provide content for a cell as well as perform any custom modifications on the cell or row Node that could not be performed by `formatter`s. Should be used sparingly for better performance. * `emptyCellValue` - String (HTML) value to use if the Model data for a column, or the content generated by a `formatter`, is the empty string, `null`, or `undefined`. * `allowHTML` - Set to `true` if a column value, `formatter`, or `emptyCellValue` can contain HTML. This defaults to `false` to protect against XSS. * `className` - Space delimited CSS classes to add to all `<td>`s in a column. Column `formatter`s are passed an object (`o`) with the following properties: * `value` - The current value of the column's associated attribute, if any. * `data` - An object map of Model keys to their current values. * `record` - The Model instance. * `column` - The column configuration object for the current column. * `className` - Initially empty string to allow `formatter`s to add CSS classes to the cell's `<td>`. * `rowIndex` - The zero-based row number. * `rowClass` - Initially empty string to allow `formatter`s to add CSS classes to the cell's containing row `<tr>`. They may return a value or update `o.value` to assign specific HTML content. A returned value has higher precedence. Column `nodeFormatter`s are passed an object (`o`) with the following properties: * `value` - The current value of the column's associated attribute, if any. * `td` - The `<td>` Node instance. * `cell` - The `<div>` liner Node instance if present, otherwise, the `<td>`. When adding content to the cell, prefer appending into this property. * `data` - An object map of Model keys to their current values. * `record` - The Model instance. * `column` - The column configuration object for the current column. * `rowIndex` - The zero-based row number. They are expected to inject content into the cell's Node directly, including any "empty" cell content. Each `nodeFormatter` will have access through the Node API to all cells and rows in the `<tbody>`, but not to the `<table>`, as it will not be attached yet. If a `nodeFormatter` returns `false`, the `o.td` and `o.cell` Nodes will be `destroy()`ed to remove them from the Node cache and free up memory. The DOM elements will remain as will any content added to them. _It is highly advisable to always return `false` from your `nodeFormatter`s_. @method render @return {BodyView} The instance @chainable @since 3.5.0 **/ render: function () { _yuitest_coverfunc("build/datatable-body/datatable-body.js", "render", 419); _yuitest_coverline("build/datatable-body/datatable-body.js", 420); var table = this.get('container'), data = this.get('modelList'), columns = this.get('columns'), tbody = this.tbodyNode || (this.tbodyNode = this._createTBodyNode()); // Needed for mutation _yuitest_coverline("build/datatable-body/datatable-body.js", 427); this._createRowTemplate(columns); _yuitest_coverline("build/datatable-body/datatable-body.js", 429); if (data) { _yuitest_coverline("build/datatable-body/datatable-body.js", 430); tbody.setHTML(this._createDataHTML(columns)); _yuitest_coverline("build/datatable-body/datatable-body.js", 432); this._applyNodeFormatters(tbody, columns); } _yuitest_coverline("build/datatable-body/datatable-body.js", 435); if (tbody.get('parentNode') !== table) { _yuitest_coverline("build/datatable-body/datatable-body.js", 436); table.appendChild(tbody); } _yuitest_coverline("build/datatable-body/datatable-body.js", 439); this.bindUI(); _yuitest_coverline("build/datatable-body/datatable-body.js", 441); return this; }, // -- Protected and private methods --------------------------------------- /** Handles changes in the source's columns attribute. Redraws the table data. @method _afterColumnsChange @param {EventFacade} e The `columnsChange` event object @protected @since 3.5.0 **/ // TODO: Preserve existing DOM // This will involve parsing and comparing the old and new column configs // and reacting to four types of changes: // 1. formatter, nodeFormatter, emptyCellValue changes // 2. column deletions // 3. column additions // 4. column moves (preserve cells) _afterColumnsChange: function (e) { _yuitest_coverfunc("build/datatable-body/datatable-body.js", "_afterColumnsChange", 460); _yuitest_coverline("build/datatable-body/datatable-body.js", 461); this.render(); }, /** Handles modelList changes, including additions, deletions, and updates. Modifies the existing table DOM accordingly. @method _afterDataChange @param {EventFacade} e The `change` event from the ModelList @protected @since 3.5.0 **/ _afterDataChange: function (e) { //var type = e.type.slice(e.type.lastIndexOf(':') + 1); // TODO: Isolate changes _yuitest_coverfunc("build/datatable-body/datatable-body.js", "_afterDataChange", 474); _yuitest_coverline("build/datatable-body/datatable-body.js", 478); this.render(); }, /** Handles replacement of the modelList. Rerenders the `<tbody>` contents. @method _afterModelListChange @param {EventFacade} e The `modelListChange` event @protected @since 3.6.0 **/ _afterModelListChange: function (e) { _yuitest_coverfunc("build/datatable-body/datatable-body.js", "_afterModelListChange", 491); _yuitest_coverline("build/datatable-body/datatable-body.js", 492); var handles = this._eventHandles; _yuitest_coverline("build/datatable-body/datatable-body.js", 494); if (handles.dataChange) { _yuitest_coverline("build/datatable-body/datatable-body.js", 495); handles.dataChange.detach(); _yuitest_coverline("build/datatable-body/datatable-body.js", 496); delete handles.dataChange; _yuitest_coverline("build/datatable-body/datatable-body.js", 497); this.bindUI(); } _yuitest_coverline("build/datatable-body/datatable-body.js", 500); if (this.tbodyNode) { _yuitest_coverline("build/datatable-body/datatable-body.js", 501); this.render(); } }, /** Iterates the `modelList`, and calls any `nodeFormatter`s found in the `columns` param on the appropriate cell Nodes in the `tbody`. @method _applyNodeFormatters @param {Node} tbody The `<tbody>` Node whose columns to update @param {Object[]} columns The column configurations @protected @since 3.5.0 **/ _applyNodeFormatters: function (tbody, columns) { _yuitest_coverfunc("build/datatable-body/datatable-body.js", "_applyNodeFormatters", 515); _yuitest_coverline("build/datatable-body/datatable-body.js", 516); var host = this.host, data = this.get('modelList'), formatters = [], linerQuery = '.' + this.getClassName('liner'), rows, i, len; // Only iterate the ModelList again if there are nodeFormatters _yuitest_coverline("build/datatable-body/datatable-body.js", 523); for (i = 0, len = columns.length; i < len; ++i) { _yuitest_coverline("build/datatable-body/datatable-body.js", 524); if (columns[i].nodeFormatter) { _yuitest_coverline("build/datatable-body/datatable-body.js", 525); formatters.push(i); } } _yuitest_coverline("build/datatable-body/datatable-body.js", 529); if (data && formatters.length) { _yuitest_coverline("build/datatable-body/datatable-body.js", 530); rows = tbody.get('childNodes'); _yuitest_coverline("build/datatable-body/datatable-body.js", 532); data.each(function (record, index) { _yuitest_coverfunc("build/datatable-body/datatable-body.js", "(anonymous 3)", 532); _yuitest_coverline("build/datatable-body/datatable-body.js", 533); var formatterData = { data : record.toJSON(), record : record, rowIndex : index }, row = rows.item(index), i, len, col, key, cells, cell, keep; _yuitest_coverline("build/datatable-body/datatable-body.js", 542); if (row) { _yuitest_coverline("build/datatable-body/datatable-body.js", 543); cells = row.get('childNodes'); _yuitest_coverline("build/datatable-body/datatable-body.js", 544); for (i = 0, len = formatters.length; i < len; ++i) { _yuitest_coverline("build/datatable-body/datatable-body.js", 545); cell = cells.item(formatters[i]); _yuitest_coverline("build/datatable-body/datatable-body.js", 547); if (cell) { _yuitest_coverline("build/datatable-body/datatable-body.js", 548); col = formatterData.column = columns[formatters[i]]; _yuitest_coverline("build/datatable-body/datatable-body.js", 549); key = col.key || col.id; _yuitest_coverline("build/datatable-body/datatable-body.js", 551); formatterData.value = record.get(key); _yuitest_coverline("build/datatable-body/datatable-body.js", 552); formatterData.td = cell; _yuitest_coverline("build/datatable-body/datatable-body.js", 553); formatterData.cell = cell.one(linerQuery) || cell; _yuitest_coverline("build/datatable-body/datatable-body.js", 555); keep = col.nodeFormatter.call(host,formatterData); _yuitest_coverline("build/datatable-body/datatable-body.js", 557); if (keep === false) { // Remove from the Node cache to reduce // memory footprint. This also purges events, // which you shouldn't be scoping to a cell // anyway. You've been warned. Incidentally, // you should always return false. Just sayin. _yuitest_coverline("build/datatable-body/datatable-body.js", 563); cell.destroy(true); } } } } }); } }, /** Binds event subscriptions from the UI and the host (if assigned). @method bindUI @protected @since 3.5.0 **/ bindUI: function () { _yuitest_coverfunc("build/datatable-body/datatable-body.js", "bindUI", 579); _yuitest_coverline("build/datatable-body/datatable-body.js", 580); var handles = this._eventHandles, modelList = this.get('modelList'), changeEvent = modelList.model.NAME + ':change'; _yuitest_coverline("build/datatable-body/datatable-body.js", 584); if (!handles.columnsChange) { _yuitest_coverline("build/datatable-body/datatable-body.js", 585); handles.columnsChange = this.after('columnsChange', bind('_afterColumnsChange', this)); } _yuitest_coverline("build/datatable-body/datatable-body.js", 589); if (modelList && !handles.dataChange) { _yuitest_coverline("build/datatable-body/datatable-body.js", 590); handles.dataChange = modelList.after( ['add', 'remove', 'reset', changeEvent], bind('_afterDataChange', this)); } }, /** Iterates the `modelList` and applies each Model to the `_rowTemplate`, allowing any column `formatter` or `emptyCellValue` to override cell content for the appropriate column. The aggregated HTML string is returned. @method _createDataHTML @param {Object[]} columns The column configurations to customize the generated cell content or class names @return {HTML} The markup for all Models in the `modelList`, each applied to the `_rowTemplate` @protected @since 3.5.0 **/ _createDataHTML: function (columns) { _yuitest_coverfunc("build/datatable-body/datatable-body.js", "_createDataHTML", 610); _yuitest_coverline("build/datatable-body/datatable-body.js", 611); var data = this.get('modelList'), html = ''; _yuitest_coverline("build/datatable-body/datatable-body.js", 614); if (data) { _yuitest_coverline("build/datatable-body/datatable-body.js", 615); data.each(function (model, index) { _yuitest_coverfunc("build/datatable-body/datatable-body.js", "(anonymous 4)", 615); _yuitest_coverline("build/datatable-body/datatable-body.js", 616); html += this._createRowHTML(model, index, columns); }, this); } _yuitest_coverline("build/datatable-body/datatable-body.js", 620); return html; }, /** Applies the data of a given Model, modified by any column formatters and supplemented by other template values to the instance's `_rowTemplate` (see `_createRowTemplate`). The generated string is then returned. The data from Model's attributes is fetched by `toJSON` and this data object is appended with other properties to supply values to {placeholders} in the template. For a template generated from a Model with 'foo' and 'bar' attributes, the data object would end up with the following properties before being used to populate the `_rowTemplate`: * `clientID` - From Model, used the assign the `<tr>`'s 'id' attribute. * `foo` - The value to populate the 'foo' column cell content. This value will be the value stored in the Model's `foo` attribute, or the result of the column's `formatter` if assigned. If the value is '', `null`, or `undefined`, and the column's `emptyCellValue` is assigned, that value will be used. * `bar` - Same for the 'bar' column cell content. * `foo-className` - String of CSS classes to apply to the `<td>`. * `bar-className` - Same. * `rowClass` - String of CSS classes to apply to the `<tr>`. This will be the odd/even class per the specified index plus any additional classes assigned by column formatters (via `o.rowClass`). Because this object is available to formatters, any additional properties can be added to fill in custom {placeholders} in the `_rowTemplate`. @method _createRowHTML @param {Model} model The Model instance to apply to the row template @param {Number} index The index the row will be appearing @param {Object[]} columns The column configurations @return {HTML} The markup for the provided Model, less any `nodeFormatter`s @protected @since 3.5.0 **/ _createRowHTML: function (model, index, columns) { _yuitest_coverfunc("build/datatable-body/datatable-body.js", "_createRowHTML", 658); _yuitest_coverline("build/datatable-body/datatable-body.js", 659); var data = model.toJSON(), clientId = model.get('clientId'), values = { rowId : this._getRowId(clientId), clientId: clientId, rowClass: (index % 2) ? this.CLASS_ODD : this.CLASS_EVEN }, host = this.host || this, i, len, col, token, value, formatterData; _yuitest_coverline("build/datatable-body/datatable-body.js", 669); for (i = 0, len = columns.length; i < len; ++i) { _yuitest_coverline("build/datatable-body/datatable-body.js", 670); col = columns[i]; _yuitest_coverline("build/datatable-body/datatable-body.js", 671); value = data[col.key]; _yuitest_coverline("build/datatable-body/datatable-body.js", 672); token = col._id || col.key; _yuitest_coverline("build/datatable-body/datatable-body.js", 674); values[token + '-className'] = ''; _yuitest_coverline("build/datatable-body/datatable-body.js", 676); if (col.formatter) { _yuitest_coverline("build/datatable-body/datatable-body.js", 677); formatterData = { value : value, data : data, column : col, record : model, className: '', rowClass : '', rowIndex : index }; _yuitest_coverline("build/datatable-body/datatable-body.js", 687); if (typeof col.formatter === 'string') { _yuitest_coverline("build/datatable-body/datatable-body.js", 688); if (value !== undefined) { // TODO: look for known formatters by string name _yuitest_coverline("build/datatable-body/datatable-body.js", 690); value = fromTemplate(col.formatter, formatterData); } } else { // Formatters can either return a value _yuitest_coverline("build/datatable-body/datatable-body.js", 694); value = col.formatter.call(host, formatterData); // or update the value property of the data obj passed _yuitest_coverline("build/datatable-body/datatable-body.js", 697); if (value === undefined) { _yuitest_coverline("build/datatable-body/datatable-body.js", 698); value = formatterData.value; } _yuitest_coverline("build/datatable-body/datatable-body.js", 701); values[token + '-className'] = formatterData.className; _yuitest_coverline("build/datatable-body/datatable-body.js", 702); values.rowClass += ' ' + formatterData.rowClass; } } _yuitest_coverline("build/datatable-body/datatable-body.js", 706); if (value === undefined || value === null || value === '') { _yuitest_coverline("build/datatable-body/datatable-body.js", 707); value = col.emptyCellValue || ''; } _yuitest_coverline("build/datatable-body/datatable-body.js", 710); values[token] = col.allowHTML ? value : htmlEscape(value); _yuitest_coverline("build/datatable-body/datatable-body.js", 712); values.rowClass = values.rowClass.replace(/\s+/g, ' '); } _yuitest_coverline("build/datatable-body/datatable-body.js", 715); return fromTemplate(this._rowTemplate, values); }, /** Creates a custom HTML template string for use in generating the markup for individual table rows with {placeholder}s to capture data from the Models in the `modelList` attribute or from column `formatter`s. Assigns the `_rowTemplate` property. @method _createRowTemplate @param {Object[]} columns Array of column configuration objects @protected @since 3.5.0 **/ _createRowTemplate: function (columns) { _yuitest_coverfunc("build/datatable-body/datatable-body.js", "_createRowTemplate", 730); _yuitest_coverline("build/datatable-body/datatable-body.js", 731); var html = '', cellTemplate = this.CELL_TEMPLATE, i, len, col, key, token, headers, tokenValues; _yuitest_coverline("build/datatable-body/datatable-body.js", 735); for (i = 0, len = columns.length; i < len; ++i) { _yuitest_coverline("build/datatable-body/datatable-body.js", 736); col = columns[i]; _yuitest_coverline("build/datatable-body/datatable-body.js", 737); key = col.key; _yuitest_coverline("build/datatable-body/datatable-body.js", 738); token = col._id || key; // Only include headers if there are more than one _yuitest_coverline("build/datatable-body/datatable-body.js", 740); headers = (col._headers || []).length > 1 ? 'headers="' + col._headers.join(' ') + '"' : ''; _yuitest_coverline("build/datatable-body/datatable-body.js", 743); tokenValues = { content : '{' + token + '}', headers : headers, className: this.getClassName('col', token) + ' ' + (col.className || '') + ' ' + this.getClassName('cell') + ' {' + token + '-className}' }; _yuitest_coverline("build/datatable-body/datatable-body.js", 752); if (col.nodeFormatter) { // Defer all node decoration to the formatter _yuitest_coverline("build/datatable-body/datatable-body.js", 754); tokenValues.content = ''; } _yuitest_coverline("build/datatable-body/datatable-body.js", 757); html += fromTemplate(col.cellTemplate || cellTemplate, tokenValues); } _yuitest_coverline("build/datatable-body/datatable-body.js", 760); this._rowTemplate = fromTemplate(this.ROW_TEMPLATE, { content: html }); }, /** Creates the `<tbody>` node that will store the data rows. @method _createTBodyNode @return {Node} @protected @since 3.6.0 **/ _createTBodyNode: function () { _yuitest_coverfunc("build/datatable-body/datatable-body.js", "_createTBodyNode", 773); _yuitest_coverline("build/datatable-body/datatable-body.js", 774); return Y.Node.create(fromTemplate(this.TBODY_TEMPLATE, { className: this.getClassName('data') })); }, /** Destroys the instance. @method destructor @protected @since 3.5.0 **/ destructor: function () { _yuitest_coverfunc("build/datatable-body/datatable-body.js", "destructor", 786); _yuitest_coverline("build/datatable-body/datatable-body.js", 787); (new Y.EventHandle(YObject.values(this._eventHandles))).detach(); }, /** Holds the event subscriptions needing to be detached when the instance is `destroy()`ed. @property _eventHandles @type {Object} @default undefined (initially unset) @protected @since 3.5.0 **/ //_eventHandles: null, /** Returns the row ID associated with a Model's clientId. @method _getRowId @param {String} clientId The Model clientId @return {String} @protected **/ _getRowId: function (clientId) { _yuitest_coverfunc("build/datatable-body/datatable-body.js", "_getRowId", 810); _yuitest_coverline("build/datatable-body/datatable-body.js", 811); return this._idMap[clientId] || (this._idMap[clientId] = Y.guid()); }, /** Map of Model clientIds to row ids. @property _idMap @type {Object} @protected **/ //_idMap, /** Initializes the instance. Reads the following configuration properties in addition to the instance attributes: * `columns` - (REQUIRED) The initial column information * `host` - The object to serve as source of truth for column info and for generating class names @method initializer @param {Object} config Configuration data @protected @since 3.5.0 **/ initializer: function (config) { _yuitest_coverfunc("build/datatable-body/datatable-body.js", "initializer", 836); _yuitest_coverline("build/datatable-body/datatable-body.js", 837); this.host = config.host; _yuitest_coverline("build/datatable-body/datatable-body.js", 839); this._eventHandles = { modelListChange: this.after('modelListChange', bind('_afterModelListChange', this)) }; _yuitest_coverline("build/datatable-body/datatable-body.js", 843); this._idMap = {}; _yuitest_coverline("build/datatable-body/datatable-body.js", 845); this.CLASS_ODD = this.getClassName('odd'); _yuitest_coverline("build/datatable-body/datatable-body.js", 846); this.CLASS_EVEN = this.getClassName('even'); } /** The HTML template used to create a full row of markup for a single Model in the `modelList` plus any customizations defined in the column configurations. @property _rowTemplate @type {HTML} @default (initially unset) @protected @since 3.5.0 **/ //_rowTemplate: null }); }, '@VERSION@', {"requires": ["datatable-core", "view", "classnamemanager"]});
ajax/libs/oojs-ui/0.13.2/oojs-ui.js
maruilian11/cdnjs
/*! * OOjs UI v0.13.2 * https://www.mediawiki.org/wiki/OOjs_UI * * Copyright 2011–2015 OOjs UI Team and other contributors. * Released under the MIT license * http://oojs.mit-license.org * * Date: 2015-11-10T23:32:59Z */ ( function ( OO ) { 'use strict'; /** * Namespace for all classes, static methods and static properties. * * @class * @singleton */ OO.ui = {}; OO.ui.bind = $.proxy; /** * @property {Object} */ OO.ui.Keys = { UNDEFINED: 0, BACKSPACE: 8, DELETE: 46, LEFT: 37, RIGHT: 39, UP: 38, DOWN: 40, ENTER: 13, END: 35, HOME: 36, TAB: 9, PAGEUP: 33, PAGEDOWN: 34, ESCAPE: 27, SHIFT: 16, SPACE: 32 }; /** * @property {Number} */ OO.ui.elementId = 0; /** * Generate a unique ID for element * * @return {String} [id] */ OO.ui.generateElementId = function () { OO.ui.elementId += 1; return 'oojsui-' + OO.ui.elementId; }; /** * Check if an element is focusable. * Inspired from :focusable in jQueryUI v1.11.4 - 2015-04-14 * * @param {jQuery} element Element to test * @return {boolean} */ OO.ui.isFocusableElement = function ( $element ) { var nodeName, element = $element[ 0 ]; // Anything disabled is not focusable if ( element.disabled ) { return false; } // Check if the element is visible if ( !( // This is quicker than calling $element.is( ':visible' ) $.expr.filters.visible( element ) && // Check that all parents are visible !$element.parents().addBack().filter( function () { return $.css( this, 'visibility' ) === 'hidden'; } ).length ) ) { return false; } // Check if the element is ContentEditable, which is the string 'true' if ( element.contentEditable === 'true' ) { return true; } // Anything with a non-negative numeric tabIndex is focusable. // Use .prop to avoid browser bugs if ( $element.prop( 'tabIndex' ) >= 0 ) { return true; } // Some element types are naturally focusable // (indexOf is much faster than regex in Chrome and about the // same in FF: https://jsperf.com/regex-vs-indexof-array2) nodeName = element.nodeName.toLowerCase(); if ( [ 'input', 'select', 'textarea', 'button', 'object' ].indexOf( nodeName ) !== -1 ) { return true; } // Links and areas are focusable if they have an href if ( ( nodeName === 'a' || nodeName === 'area' ) && $element.attr( 'href' ) !== undefined ) { return true; } return false; }; /** * Find a focusable child * * @param {jQuery} $container Container to search in * @param {boolean} [backwards] Search backwards * @return {jQuery} Focusable child, an empty jQuery object if none found */ OO.ui.findFocusable = function ( $container, backwards ) { var $focusable = $( [] ), // $focusableCandidates is a superset of things that // could get matched by isFocusableElement $focusableCandidates = $container .find( 'input, select, textarea, button, object, a, area, [contenteditable], [tabindex]' ); if ( backwards ) { $focusableCandidates = Array.prototype.reverse.call( $focusableCandidates ); } $focusableCandidates.each( function () { var $this = $( this ); if ( OO.ui.isFocusableElement( $this ) ) { $focusable = $this; return false; } } ); return $focusable; }; /** * Get the user's language and any fallback languages. * * These language codes are used to localize user interface elements in the user's language. * * In environments that provide a localization system, this function should be overridden to * return the user's language(s). The default implementation returns English (en) only. * * @return {string[]} Language codes, in descending order of priority */ OO.ui.getUserLanguages = function () { return [ 'en' ]; }; /** * Get a value in an object keyed by language code. * * @param {Object.<string,Mixed>} obj Object keyed by language code * @param {string|null} [lang] Language code, if omitted or null defaults to any user language * @param {string} [fallback] Fallback code, used if no matching language can be found * @return {Mixed} Local value */ OO.ui.getLocalValue = function ( obj, lang, fallback ) { var i, len, langs; // Requested language if ( obj[ lang ] ) { return obj[ lang ]; } // Known user language langs = OO.ui.getUserLanguages(); for ( i = 0, len = langs.length; i < len; i++ ) { lang = langs[ i ]; if ( obj[ lang ] ) { return obj[ lang ]; } } // Fallback language if ( obj[ fallback ] ) { return obj[ fallback ]; } // First existing language for ( lang in obj ) { return obj[ lang ]; } return undefined; }; /** * Check if a node is contained within another node * * Similar to jQuery#contains except a list of containers can be supplied * and a boolean argument allows you to include the container in the match list * * @param {HTMLElement|HTMLElement[]} containers Container node(s) to search in * @param {HTMLElement} contained Node to find * @param {boolean} [matchContainers] Include the container(s) in the list of nodes to match, otherwise only match descendants * @return {boolean} The node is in the list of target nodes */ OO.ui.contains = function ( containers, contained, matchContainers ) { var i; if ( !Array.isArray( containers ) ) { containers = [ containers ]; } for ( i = containers.length - 1; i >= 0; i-- ) { if ( ( matchContainers && contained === containers[ i ] ) || $.contains( containers[ i ], contained ) ) { return true; } } return false; }; /** * Return a function, that, as long as it continues to be invoked, will not * be triggered. The function will be called after it stops being called for * N milliseconds. If `immediate` is passed, trigger the function on the * leading edge, instead of the trailing. * * Ported from: http://underscorejs.org/underscore.js * * @param {Function} func * @param {number} wait * @param {boolean} immediate * @return {Function} */ OO.ui.debounce = function ( func, wait, immediate ) { var timeout; return function () { var context = this, args = arguments, later = function () { timeout = null; if ( !immediate ) { func.apply( context, args ); } }; if ( immediate && !timeout ) { func.apply( context, args ); } clearTimeout( timeout ); timeout = setTimeout( later, wait ); }; }; /** * Proxy for `node.addEventListener( eventName, handler, true )`, if the browser supports it. * Otherwise falls back to non-capturing event listeners. * * @param {HTMLElement} node * @param {string} eventName * @param {Function} handler */ OO.ui.addCaptureEventListener = function ( node, eventName, handler ) { if ( node.addEventListener ) { node.addEventListener( eventName, handler, true ); } else { node.attachEvent( 'on' + eventName, handler ); } }; /** * Proxy for `node.removeEventListener( eventName, handler, true )`, if the browser supports it. * Otherwise falls back to non-capturing event listeners. * * @param {HTMLElement} node * @param {string} eventName * @param {Function} handler */ OO.ui.removeCaptureEventListener = function ( node, eventName, handler ) { if ( node.addEventListener ) { node.removeEventListener( eventName, handler, true ); } else { node.detachEvent( 'on' + eventName, handler ); } }; /** * Reconstitute a JavaScript object corresponding to a widget created by * the PHP implementation. * * This is an alias for `OO.ui.Element.static.infuse()`. * * @param {string|HTMLElement|jQuery} idOrNode * A DOM id (if a string) or node for the widget to infuse. * @return {OO.ui.Element} * The `OO.ui.Element` corresponding to this (infusable) document node. */ OO.ui.infuse = function ( idOrNode ) { return OO.ui.Element.static.infuse( idOrNode ); }; ( function () { /** * Message store for the default implementation of OO.ui.msg * * Environments that provide a localization system should not use this, but should override * OO.ui.msg altogether. * * @private */ var messages = { // Tool tip for a button that moves items in a list down one place 'ooui-outline-control-move-down': 'Move item down', // Tool tip for a button that moves items in a list up one place 'ooui-outline-control-move-up': 'Move item up', // Tool tip for a button that removes items from a list 'ooui-outline-control-remove': 'Remove item', // Label for the toolbar group that contains a list of all other available tools 'ooui-toolbar-more': 'More', // Label for the fake tool that expands the full list of tools in a toolbar group 'ooui-toolgroup-expand': 'More', // Label for the fake tool that collapses the full list of tools in a toolbar group 'ooui-toolgroup-collapse': 'Fewer', // Default label for the accept button of a confirmation dialog 'ooui-dialog-message-accept': 'OK', // Default label for the reject button of a confirmation dialog 'ooui-dialog-message-reject': 'Cancel', // Title for process dialog error description 'ooui-dialog-process-error': 'Something went wrong', // Label for process dialog dismiss error button, visible when describing errors 'ooui-dialog-process-dismiss': 'Dismiss', // Label for process dialog retry action button, visible when describing only recoverable errors 'ooui-dialog-process-retry': 'Try again', // Label for process dialog retry action button, visible when describing only warnings 'ooui-dialog-process-continue': 'Continue', // Label for the file selection widget's select file button 'ooui-selectfile-button-select': 'Select a file', // Label for the file selection widget if file selection is not supported 'ooui-selectfile-not-supported': 'File selection is not supported', // Label for the file selection widget when no file is currently selected 'ooui-selectfile-placeholder': 'No file is selected', // Label for the file selection widget's drop target 'ooui-selectfile-dragdrop-placeholder': 'Drop file here' }; /** * Get a localized message. * * In environments that provide a localization system, this function should be overridden to * return the message translated in the user's language. The default implementation always returns * English messages. * * After the message key, message parameters may optionally be passed. In the default implementation, * any occurrences of $1 are replaced with the first parameter, $2 with the second parameter, etc. * Alternative implementations of OO.ui.msg may use any substitution system they like, as long as * they support unnamed, ordered message parameters. * * @abstract * @param {string} key Message key * @param {Mixed...} [params] Message parameters * @return {string} Translated message with parameters substituted */ OO.ui.msg = function ( key ) { var message = messages[ key ], params = Array.prototype.slice.call( arguments, 1 ); if ( typeof message === 'string' ) { // Perform $1 substitution message = message.replace( /\$(\d+)/g, function ( unused, n ) { var i = parseInt( n, 10 ); return params[ i - 1 ] !== undefined ? params[ i - 1 ] : '$' + n; } ); } else { // Return placeholder if message not found message = '[' + key + ']'; } return message; }; /** * Package a message and arguments for deferred resolution. * * Use this when you are statically specifying a message and the message may not yet be present. * * @param {string} key Message key * @param {Mixed...} [params] Message parameters * @return {Function} Function that returns the resolved message when executed */ OO.ui.deferMsg = function () { var args = arguments; return function () { return OO.ui.msg.apply( OO.ui, args ); }; }; /** * Resolve a message. * * If the message is a function it will be executed, otherwise it will pass through directly. * * @param {Function|string} msg Deferred message, or message text * @return {string} Resolved message */ OO.ui.resolveMsg = function ( msg ) { if ( $.isFunction( msg ) ) { return msg(); } return msg; }; /** * @param {string} url * @return {boolean} */ OO.ui.isSafeUrl = function ( url ) { var protocol, // Keep in sync with php/Tag.php whitelist = [ 'bitcoin:', 'ftp:', 'ftps:', 'geo:', 'git:', 'gopher:', 'http:', 'https:', 'irc:', 'ircs:', 'magnet:', 'mailto:', 'mms:', 'news:', 'nntp:', 'redis:', 'sftp:', 'sip:', 'sips:', 'sms:', 'ssh:', 'svn:', 'tel:', 'telnet:', 'urn:', 'worldwind:', 'xmpp:' ]; if ( url.indexOf( ':' ) === -1 ) { // No protocol, safe return true; } protocol = url.split( ':', 1 )[ 0 ] + ':'; if ( !protocol.match( /^([A-za-z0-9\+\.\-])+:/ ) ) { // Not a valid protocol, safe return true; } // Safe if in the whitelist return whitelist.indexOf( protocol ) !== -1; }; } )(); /*! * Mixin namespace. */ /** * Namespace for OOjs UI mixins. * * Mixins are named according to the type of object they are intended to * be mixed in to. For example, OO.ui.mixin.GroupElement is intended to be * mixed in to an instance of OO.ui.Element, and OO.ui.mixin.GroupWidget * is intended to be mixed in to an instance of OO.ui.Widget. * * @class * @singleton */ OO.ui.mixin = {}; /** * PendingElement is a mixin that is used to create elements that notify users that something is happening * and that they should wait before proceeding. The pending state is visually represented with a pending * texture that appears in the head of a pending {@link OO.ui.ProcessDialog process dialog} or in the input * field of a {@link OO.ui.TextInputWidget text input widget}. * * Currently, {@link OO.ui.ActionWidget Action widgets}, which mix in this class, can also be marked as pending, but only when * used in {@link OO.ui.MessageDialog message dialogs}. The behavior is not currently supported for action widgets used * in process dialogs. * * @example * function MessageDialog( config ) { * MessageDialog.parent.call( this, config ); * } * OO.inheritClass( MessageDialog, OO.ui.MessageDialog ); * * MessageDialog.static.actions = [ * { action: 'save', label: 'Done', flags: 'primary' }, * { label: 'Cancel', flags: 'safe' } * ]; * * MessageDialog.prototype.initialize = function () { * MessageDialog.parent.prototype.initialize.apply( this, arguments ); * this.content = new OO.ui.PanelLayout( { $: this.$, padded: true } ); * this.content.$element.append( '<p>Click the \'Done\' action widget to see its pending state. Note that action widgets can be marked pending in message dialogs but not process dialogs.</p>' ); * this.$body.append( this.content.$element ); * }; * MessageDialog.prototype.getBodyHeight = function () { * return 100; * } * MessageDialog.prototype.getActionProcess = function ( action ) { * var dialog = this; * if ( action === 'save' ) { * dialog.getActions().get({actions: 'save'})[0].pushPending(); * return new OO.ui.Process() * .next( 1000 ) * .next( function () { * dialog.getActions().get({actions: 'save'})[0].popPending(); * } ); * } * return MessageDialog.parent.prototype.getActionProcess.call( this, action ); * }; * * var windowManager = new OO.ui.WindowManager(); * $( 'body' ).append( windowManager.$element ); * * var dialog = new MessageDialog(); * windowManager.addWindows( [ dialog ] ); * windowManager.openWindow( dialog ); * * @abstract * @class * * @constructor * @param {Object} [config] Configuration options * @cfg {jQuery} [$pending] Element to mark as pending, defaults to this.$element */ OO.ui.mixin.PendingElement = function OoUiMixinPendingElement( config ) { // Configuration initialization config = config || {}; // Properties this.pending = 0; this.$pending = null; // Initialisation this.setPendingElement( config.$pending || this.$element ); }; /* Setup */ OO.initClass( OO.ui.mixin.PendingElement ); /* Methods */ /** * Set the pending element (and clean up any existing one). * * @param {jQuery} $pending The element to set to pending. */ OO.ui.mixin.PendingElement.prototype.setPendingElement = function ( $pending ) { if ( this.$pending ) { this.$pending.removeClass( 'oo-ui-pendingElement-pending' ); } this.$pending = $pending; if ( this.pending > 0 ) { this.$pending.addClass( 'oo-ui-pendingElement-pending' ); } }; /** * Check if an element is pending. * * @return {boolean} Element is pending */ OO.ui.mixin.PendingElement.prototype.isPending = function () { return !!this.pending; }; /** * Increase the pending counter. The pending state will remain active until the counter is zero * (i.e., the number of calls to #pushPending and #popPending is the same). * * @chainable */ OO.ui.mixin.PendingElement.prototype.pushPending = function () { if ( this.pending === 0 ) { this.$pending.addClass( 'oo-ui-pendingElement-pending' ); this.updateThemeClasses(); } this.pending++; return this; }; /** * Decrease the pending counter. The pending state will remain active until the counter is zero * (i.e., the number of calls to #pushPending and #popPending is the same). * * @chainable */ OO.ui.mixin.PendingElement.prototype.popPending = function () { if ( this.pending === 1 ) { this.$pending.removeClass( 'oo-ui-pendingElement-pending' ); this.updateThemeClasses(); } this.pending = Math.max( 0, this.pending - 1 ); return this; }; /** * ActionSets manage the behavior of the {@link OO.ui.ActionWidget action widgets} that comprise them. * Actions can be made available for specific contexts (modes) and circumstances * (abilities). Action sets are primarily used with {@link OO.ui.Dialog Dialogs}. * * ActionSets contain two types of actions: * * - Special: Special actions are the first visible actions with special flags, such as 'safe' and 'primary', the default special flags. Additional special flags can be configured in subclasses with the static #specialFlags property. * - Other: Other actions include all non-special visible actions. * * Please see the [OOjs UI documentation on MediaWiki][1] for more information. * * @example * // Example: An action set used in a process dialog * function MyProcessDialog( config ) { * MyProcessDialog.parent.call( this, config ); * } * OO.inheritClass( MyProcessDialog, OO.ui.ProcessDialog ); * MyProcessDialog.static.title = 'An action set in a process dialog'; * // An action set that uses modes ('edit' and 'help' mode, in this example). * MyProcessDialog.static.actions = [ * { action: 'continue', modes: 'edit', label: 'Continue', flags: [ 'primary', 'constructive' ] }, * { action: 'help', modes: 'edit', label: 'Help' }, * { modes: 'edit', label: 'Cancel', flags: 'safe' }, * { action: 'back', modes: 'help', label: 'Back', flags: 'safe' } * ]; * * MyProcessDialog.prototype.initialize = function () { * MyProcessDialog.parent.prototype.initialize.apply( this, arguments ); * this.panel1 = new OO.ui.PanelLayout( { padded: true, expanded: false } ); * this.panel1.$element.append( '<p>This dialog uses an action set (continue, help, cancel, back) configured with modes. This is edit mode. Click \'help\' to see help mode.</p>' ); * this.panel2 = new OO.ui.PanelLayout( { padded: true, expanded: false } ); * this.panel2.$element.append( '<p>This is help mode. Only the \'back\' action widget is configured to be visible here. Click \'back\' to return to \'edit\' mode.</p>' ); * this.stackLayout = new OO.ui.StackLayout( { * items: [ this.panel1, this.panel2 ] * } ); * this.$body.append( this.stackLayout.$element ); * }; * MyProcessDialog.prototype.getSetupProcess = function ( data ) { * return MyProcessDialog.parent.prototype.getSetupProcess.call( this, data ) * .next( function () { * this.actions.setMode( 'edit' ); * }, this ); * }; * MyProcessDialog.prototype.getActionProcess = function ( action ) { * if ( action === 'help' ) { * this.actions.setMode( 'help' ); * this.stackLayout.setItem( this.panel2 ); * } else if ( action === 'back' ) { * this.actions.setMode( 'edit' ); * this.stackLayout.setItem( this.panel1 ); * } else if ( action === 'continue' ) { * var dialog = this; * return new OO.ui.Process( function () { * dialog.close(); * } ); * } * return MyProcessDialog.parent.prototype.getActionProcess.call( this, action ); * }; * MyProcessDialog.prototype.getBodyHeight = function () { * return this.panel1.$element.outerHeight( true ); * }; * var windowManager = new OO.ui.WindowManager(); * $( 'body' ).append( windowManager.$element ); * var dialog = new MyProcessDialog( { * size: 'medium' * } ); * windowManager.addWindows( [ dialog ] ); * windowManager.openWindow( dialog ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Windows/Process_Dialogs#Action_sets * * @abstract * @class * @mixins OO.EventEmitter * * @constructor * @param {Object} [config] Configuration options */ OO.ui.ActionSet = function OoUiActionSet( config ) { // Configuration initialization config = config || {}; // Mixin constructors OO.EventEmitter.call( this ); // Properties this.list = []; this.categories = { actions: 'getAction', flags: 'getFlags', modes: 'getModes' }; this.categorized = {}; this.special = {}; this.others = []; this.organized = false; this.changing = false; this.changed = false; }; /* Setup */ OO.mixinClass( OO.ui.ActionSet, OO.EventEmitter ); /* Static Properties */ /** * Symbolic name of the flags used to identify special actions. Special actions are displayed in the * header of a {@link OO.ui.ProcessDialog process dialog}. * See the [OOjs UI documentation on MediaWiki][2] for more information and examples. * * [2]:https://www.mediawiki.org/wiki/OOjs_UI/Windows/Process_Dialogs * * @abstract * @static * @inheritable * @property {string} */ OO.ui.ActionSet.static.specialFlags = [ 'safe', 'primary' ]; /* Events */ /** * @event click * * A 'click' event is emitted when an action is clicked. * * @param {OO.ui.ActionWidget} action Action that was clicked */ /** * @event resize * * A 'resize' event is emitted when an action widget is resized. * * @param {OO.ui.ActionWidget} action Action that was resized */ /** * @event add * * An 'add' event is emitted when actions are {@link #method-add added} to the action set. * * @param {OO.ui.ActionWidget[]} added Actions added */ /** * @event remove * * A 'remove' event is emitted when actions are {@link #method-remove removed} * or {@link #clear cleared}. * * @param {OO.ui.ActionWidget[]} added Actions removed */ /** * @event change * * A 'change' event is emitted when actions are {@link #method-add added}, {@link #clear cleared}, * or {@link #method-remove removed} from the action set or when the {@link #setMode mode} is changed. * */ /* Methods */ /** * Handle action change events. * * @private * @fires change */ OO.ui.ActionSet.prototype.onActionChange = function () { this.organized = false; if ( this.changing ) { this.changed = true; } else { this.emit( 'change' ); } }; /** * Check if an action is one of the special actions. * * @param {OO.ui.ActionWidget} action Action to check * @return {boolean} Action is special */ OO.ui.ActionSet.prototype.isSpecial = function ( action ) { var flag; for ( flag in this.special ) { if ( action === this.special[ flag ] ) { return true; } } return false; }; /** * Get action widgets based on the specified filter: ‘actions’, ‘flags’, ‘modes’, ‘visible’, * or ‘disabled’. * * @param {Object} [filters] Filters to use, omit to get all actions * @param {string|string[]} [filters.actions] Actions that action widgets must have * @param {string|string[]} [filters.flags] Flags that action widgets must have (e.g., 'safe') * @param {string|string[]} [filters.modes] Modes that action widgets must have * @param {boolean} [filters.visible] Action widgets must be visible * @param {boolean} [filters.disabled] Action widgets must be disabled * @return {OO.ui.ActionWidget[]} Action widgets matching all criteria */ OO.ui.ActionSet.prototype.get = function ( filters ) { var i, len, list, category, actions, index, match, matches; if ( filters ) { this.organize(); // Collect category candidates matches = []; for ( category in this.categorized ) { list = filters[ category ]; if ( list ) { if ( !Array.isArray( list ) ) { list = [ list ]; } for ( i = 0, len = list.length; i < len; i++ ) { actions = this.categorized[ category ][ list[ i ] ]; if ( Array.isArray( actions ) ) { matches.push.apply( matches, actions ); } } } } // Remove by boolean filters for ( i = 0, len = matches.length; i < len; i++ ) { match = matches[ i ]; if ( ( filters.visible !== undefined && match.isVisible() !== filters.visible ) || ( filters.disabled !== undefined && match.isDisabled() !== filters.disabled ) ) { matches.splice( i, 1 ); len--; i--; } } // Remove duplicates for ( i = 0, len = matches.length; i < len; i++ ) { match = matches[ i ]; index = matches.lastIndexOf( match ); while ( index !== i ) { matches.splice( index, 1 ); len--; index = matches.lastIndexOf( match ); } } return matches; } return this.list.slice(); }; /** * Get 'special' actions. * * Special actions are the first visible action widgets with special flags, such as 'safe' and 'primary'. * Special flags can be configured in subclasses by changing the static #specialFlags property. * * @return {OO.ui.ActionWidget[]|null} 'Special' action widgets. */ OO.ui.ActionSet.prototype.getSpecial = function () { this.organize(); return $.extend( {}, this.special ); }; /** * Get 'other' actions. * * Other actions include all non-special visible action widgets. * * @return {OO.ui.ActionWidget[]} 'Other' action widgets */ OO.ui.ActionSet.prototype.getOthers = function () { this.organize(); return this.others.slice(); }; /** * Set the mode (e.g., ‘edit’ or ‘view’). Only {@link OO.ui.ActionWidget#modes actions} configured * to be available in the specified mode will be made visible. All other actions will be hidden. * * @param {string} mode The mode. Only actions configured to be available in the specified * mode will be made visible. * @chainable * @fires toggle * @fires change */ OO.ui.ActionSet.prototype.setMode = function ( mode ) { var i, len, action; this.changing = true; for ( i = 0, len = this.list.length; i < len; i++ ) { action = this.list[ i ]; action.toggle( action.hasMode( mode ) ); } this.organized = false; this.changing = false; this.emit( 'change' ); return this; }; /** * Set the abilities of the specified actions. * * Action widgets that are configured with the specified actions will be enabled * or disabled based on the boolean values specified in the `actions` * parameter. * * @param {Object.<string,boolean>} actions A list keyed by action name with boolean * values that indicate whether or not the action should be enabled. * @chainable */ OO.ui.ActionSet.prototype.setAbilities = function ( actions ) { var i, len, action, item; for ( i = 0, len = this.list.length; i < len; i++ ) { item = this.list[ i ]; action = item.getAction(); if ( actions[ action ] !== undefined ) { item.setDisabled( !actions[ action ] ); } } return this; }; /** * Executes a function once per action. * * When making changes to multiple actions, use this method instead of iterating over the actions * manually to defer emitting a #change event until after all actions have been changed. * * @param {Object|null} actions Filters to use to determine which actions to iterate over; see #get * @param {Function} callback Callback to run for each action; callback is invoked with three * arguments: the action, the action's index, the list of actions being iterated over * @chainable */ OO.ui.ActionSet.prototype.forEach = function ( filter, callback ) { this.changed = false; this.changing = true; this.get( filter ).forEach( callback ); this.changing = false; if ( this.changed ) { this.emit( 'change' ); } return this; }; /** * Add action widgets to the action set. * * @param {OO.ui.ActionWidget[]} actions Action widgets to add * @chainable * @fires add * @fires change */ OO.ui.ActionSet.prototype.add = function ( actions ) { var i, len, action; this.changing = true; for ( i = 0, len = actions.length; i < len; i++ ) { action = actions[ i ]; action.connect( this, { click: [ 'emit', 'click', action ], resize: [ 'emit', 'resize', action ], toggle: [ 'onActionChange' ] } ); this.list.push( action ); } this.organized = false; this.emit( 'add', actions ); this.changing = false; this.emit( 'change' ); return this; }; /** * Remove action widgets from the set. * * To remove all actions, you may wish to use the #clear method instead. * * @param {OO.ui.ActionWidget[]} actions Action widgets to remove * @chainable * @fires remove * @fires change */ OO.ui.ActionSet.prototype.remove = function ( actions ) { var i, len, index, action; this.changing = true; for ( i = 0, len = actions.length; i < len; i++ ) { action = actions[ i ]; index = this.list.indexOf( action ); if ( index !== -1 ) { action.disconnect( this ); this.list.splice( index, 1 ); } } this.organized = false; this.emit( 'remove', actions ); this.changing = false; this.emit( 'change' ); return this; }; /** * Remove all action widets from the set. * * To remove only specified actions, use the {@link #method-remove remove} method instead. * * @chainable * @fires remove * @fires change */ OO.ui.ActionSet.prototype.clear = function () { var i, len, action, removed = this.list.slice(); this.changing = true; for ( i = 0, len = this.list.length; i < len; i++ ) { action = this.list[ i ]; action.disconnect( this ); } this.list = []; this.organized = false; this.emit( 'remove', removed ); this.changing = false; this.emit( 'change' ); return this; }; /** * Organize actions. * * This is called whenever organized information is requested. It will only reorganize the actions * if something has changed since the last time it ran. * * @private * @chainable */ OO.ui.ActionSet.prototype.organize = function () { var i, iLen, j, jLen, flag, action, category, list, item, special, specialFlags = this.constructor.static.specialFlags; if ( !this.organized ) { this.categorized = {}; this.special = {}; this.others = []; for ( i = 0, iLen = this.list.length; i < iLen; i++ ) { action = this.list[ i ]; if ( action.isVisible() ) { // Populate categories for ( category in this.categories ) { if ( !this.categorized[ category ] ) { this.categorized[ category ] = {}; } list = action[ this.categories[ category ] ](); if ( !Array.isArray( list ) ) { list = [ list ]; } for ( j = 0, jLen = list.length; j < jLen; j++ ) { item = list[ j ]; if ( !this.categorized[ category ][ item ] ) { this.categorized[ category ][ item ] = []; } this.categorized[ category ][ item ].push( action ); } } // Populate special/others special = false; for ( j = 0, jLen = specialFlags.length; j < jLen; j++ ) { flag = specialFlags[ j ]; if ( !this.special[ flag ] && action.hasFlag( flag ) ) { this.special[ flag ] = action; special = true; break; } } if ( !special ) { this.others.push( action ); } } } this.organized = true; } return this; }; /** * Each Element represents a rendering in the DOM—a button or an icon, for example, or anything * that is visible to a user. Unlike {@link OO.ui.Widget widgets}, plain elements usually do not have events * connected to them and can't be interacted with. * * @abstract * @class * * @constructor * @param {Object} [config] Configuration options * @cfg {string[]} [classes] The names of the CSS classes to apply to the element. CSS styles are added * to the top level (e.g., the outermost div) of the element. See the [OOjs UI documentation on MediaWiki][2] * for an example. * [2]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Buttons_and_Switches#cssExample * @cfg {string} [id] The HTML id attribute used in the rendered tag. * @cfg {string} [text] Text to insert * @cfg {Array} [content] An array of content elements to append (after #text). * Strings will be html-escaped; use an OO.ui.HtmlSnippet to append raw HTML. * Instances of OO.ui.Element will have their $element appended. * @cfg {jQuery} [$content] Content elements to append (after #text). * @cfg {jQuery} [$element] Wrapper element. Defaults to a new element with #getTagName. * @cfg {Mixed} [data] Custom data of any type or combination of types (e.g., string, number, array, object). * Data can also be specified with the #setData method. */ OO.ui.Element = function OoUiElement( config ) { // Configuration initialization config = config || {}; // Properties this.$ = $; this.visible = true; this.data = config.data; this.$element = config.$element || $( document.createElement( this.getTagName() ) ); this.elementGroup = null; this.debouncedUpdateThemeClassesHandler = OO.ui.debounce( this.debouncedUpdateThemeClasses ); // Initialization if ( Array.isArray( config.classes ) ) { this.$element.addClass( config.classes.join( ' ' ) ); } if ( config.id ) { this.$element.attr( 'id', config.id ); } if ( config.text ) { this.$element.text( config.text ); } if ( config.content ) { // The `content` property treats plain strings as text; use an // HtmlSnippet to append HTML content. `OO.ui.Element`s get their // appropriate $element appended. this.$element.append( config.content.map( function ( v ) { if ( typeof v === 'string' ) { // Escape string so it is properly represented in HTML. return document.createTextNode( v ); } else if ( v instanceof OO.ui.HtmlSnippet ) { // Bypass escaping. return v.toString(); } else if ( v instanceof OO.ui.Element ) { return v.$element; } return v; } ) ); } if ( config.$content ) { // The `$content` property treats plain strings as HTML. this.$element.append( config.$content ); } }; /* Setup */ OO.initClass( OO.ui.Element ); /* Static Properties */ /** * The name of the HTML tag used by the element. * * The static value may be ignored if the #getTagName method is overridden. * * @static * @inheritable * @property {string} */ OO.ui.Element.static.tagName = 'div'; /* Static Methods */ /** * Reconstitute a JavaScript object corresponding to a widget created * by the PHP implementation. * * @param {string|HTMLElement|jQuery} idOrNode * A DOM id (if a string) or node for the widget to infuse. * @return {OO.ui.Element} * The `OO.ui.Element` corresponding to this (infusable) document node. * For `Tag` objects emitted on the HTML side (used occasionally for content) * the value returned is a newly-created Element wrapping around the existing * DOM node. */ OO.ui.Element.static.infuse = function ( idOrNode ) { var obj = OO.ui.Element.static.unsafeInfuse( idOrNode, false ); // Verify that the type matches up. // FIXME: uncomment after T89721 is fixed (see T90929) /* if ( !( obj instanceof this['class'] ) ) { throw new Error( 'Infusion type mismatch!' ); } */ return obj; }; /** * Implementation helper for `infuse`; skips the type check and has an * extra property so that only the top-level invocation touches the DOM. * @private * @param {string|HTMLElement|jQuery} idOrNode * @param {jQuery.Promise|boolean} domPromise A promise that will be resolved * when the top-level widget of this infusion is inserted into DOM, * replacing the original node; or false for top-level invocation. * @return {OO.ui.Element} */ OO.ui.Element.static.unsafeInfuse = function ( idOrNode, domPromise ) { // look for a cached result of a previous infusion. var id, $elem, data, cls, parts, parent, obj, top, state; if ( typeof idOrNode === 'string' ) { id = idOrNode; $elem = $( document.getElementById( id ) ); } else { $elem = $( idOrNode ); id = $elem.attr( 'id' ); } if ( !$elem.length ) { throw new Error( 'Widget not found: ' + id ); } data = $elem.data( 'ooui-infused' ) || $elem[ 0 ].oouiInfused; if ( data ) { // cached! if ( data === true ) { throw new Error( 'Circular dependency! ' + id ); } return data; } data = $elem.attr( 'data-ooui' ); if ( !data ) { throw new Error( 'No infusion data found: ' + id ); } try { data = $.parseJSON( data ); } catch ( _ ) { data = null; } if ( !( data && data._ ) ) { throw new Error( 'No valid infusion data found: ' + id ); } if ( data._ === 'Tag' ) { // Special case: this is a raw Tag; wrap existing node, don't rebuild. return new OO.ui.Element( { $element: $elem } ); } parts = data._.split( '.' ); cls = OO.getProp.apply( OO, [ window ].concat( parts ) ); if ( cls === undefined ) { // The PHP output might be old and not including the "OO.ui" prefix // TODO: Remove this back-compat after next major release cls = OO.getProp.apply( OO, [ OO.ui ].concat( parts ) ); if ( cls === undefined ) { throw new Error( 'Unknown widget type: id: ' + id + ', class: ' + data._ ); } } // Verify that we're creating an OO.ui.Element instance parent = cls.parent; while ( parent !== undefined ) { if ( parent === OO.ui.Element ) { // Safe break; } parent = parent.parent; } if ( parent !== OO.ui.Element ) { throw new Error( 'Unknown widget type: id: ' + id + ', class: ' + data._ ); } if ( domPromise === false ) { top = $.Deferred(); domPromise = top.promise(); } $elem.data( 'ooui-infused', true ); // prevent loops data.id = id; // implicit data = OO.copy( data, null, function deserialize( value ) { if ( OO.isPlainObject( value ) ) { if ( value.tag ) { return OO.ui.Element.static.unsafeInfuse( value.tag, domPromise ); } if ( value.html ) { return new OO.ui.HtmlSnippet( value.html ); } } } ); // allow widgets to reuse parts of the DOM data = cls.static.reusePreInfuseDOM( $elem[ 0 ], data ); // pick up dynamic state, like focus, value of form inputs, scroll position, etc. state = cls.static.gatherPreInfuseState( $elem[ 0 ], data ); // rebuild widget // jscs:disable requireCapitalizedConstructors obj = new cls( data ); // jscs:enable requireCapitalizedConstructors // now replace old DOM with this new DOM. if ( top ) { // An efficient constructor might be able to reuse the entire DOM tree of the original element, // so only mutate the DOM if we need to. if ( $elem[ 0 ] !== obj.$element[ 0 ] ) { $elem.replaceWith( obj.$element ); // This element is now gone from the DOM, but if anyone is holding a reference to it, // let's allow them to OO.ui.infuse() it and do what they expect (T105828). // Do not use jQuery.data(), as using it on detached nodes leaks memory in 1.x line by design. $elem[ 0 ].oouiInfused = obj; } top.resolve(); } obj.$element.data( 'ooui-infused', obj ); // set the 'data-ooui' attribute so we can identify infused widgets obj.$element.attr( 'data-ooui', '' ); // restore dynamic state after the new element is inserted into DOM domPromise.done( obj.restorePreInfuseState.bind( obj, state ) ); return obj; }; /** * Pick out parts of `node`'s DOM to be reused when infusing a widget. * * This method **must not** make any changes to the DOM, only find interesting pieces and add them * to `config` (which should then be returned). Actual DOM juggling should then be done by the * constructor, which will be given the enhanced config. * * @protected * @param {HTMLElement} node * @param {Object} config * @return {Object} */ OO.ui.Element.static.reusePreInfuseDOM = function ( node, config ) { return config; }; /** * Gather the dynamic state (focus, value of form inputs, scroll position, etc.) of a HTML DOM node * (and its children) that represent an Element of the same class and the given configuration, * generated by the PHP implementation. * * This method is called just before `node` is detached from the DOM. The return value of this * function will be passed to #restorePreInfuseState after the newly created widget's #$element * is inserted into DOM to replace `node`. * * @protected * @param {HTMLElement} node * @param {Object} config * @return {Object} */ OO.ui.Element.static.gatherPreInfuseState = function () { return {}; }; /** * Get a jQuery function within a specific document. * * @static * @param {jQuery|HTMLElement|HTMLDocument|Window} context Context to bind the function to * @param {jQuery} [$iframe] HTML iframe element that contains the document, omit if document is * not in an iframe * @return {Function} Bound jQuery function */ OO.ui.Element.static.getJQuery = function ( context, $iframe ) { function wrapper( selector ) { return $( selector, wrapper.context ); } wrapper.context = this.getDocument( context ); if ( $iframe ) { wrapper.$iframe = $iframe; } return wrapper; }; /** * Get the document of an element. * * @static * @param {jQuery|HTMLElement|HTMLDocument|Window} obj Object to get the document for * @return {HTMLDocument|null} Document object */ OO.ui.Element.static.getDocument = function ( obj ) { // jQuery - selections created "offscreen" won't have a context, so .context isn't reliable return ( obj[ 0 ] && obj[ 0 ].ownerDocument ) || // Empty jQuery selections might have a context obj.context || // HTMLElement obj.ownerDocument || // Window obj.document || // HTMLDocument ( obj.nodeType === 9 && obj ) || null; }; /** * Get the window of an element or document. * * @static * @param {jQuery|HTMLElement|HTMLDocument|Window} obj Context to get the window for * @return {Window} Window object */ OO.ui.Element.static.getWindow = function ( obj ) { var doc = this.getDocument( obj ); // Support: IE 8 // Standard Document.defaultView is IE9+ return doc.parentWindow || doc.defaultView; }; /** * Get the direction of an element or document. * * @static * @param {jQuery|HTMLElement|HTMLDocument|Window} obj Context to get the direction for * @return {string} Text direction, either 'ltr' or 'rtl' */ OO.ui.Element.static.getDir = function ( obj ) { var isDoc, isWin; if ( obj instanceof jQuery ) { obj = obj[ 0 ]; } isDoc = obj.nodeType === 9; isWin = obj.document !== undefined; if ( isDoc || isWin ) { if ( isWin ) { obj = obj.document; } obj = obj.body; } return $( obj ).css( 'direction' ); }; /** * Get the offset between two frames. * * TODO: Make this function not use recursion. * * @static * @param {Window} from Window of the child frame * @param {Window} [to=window] Window of the parent frame * @param {Object} [offset] Offset to start with, used internally * @return {Object} Offset object, containing left and top properties */ OO.ui.Element.static.getFrameOffset = function ( from, to, offset ) { var i, len, frames, frame, rect; if ( !to ) { to = window; } if ( !offset ) { offset = { top: 0, left: 0 }; } if ( from.parent === from ) { return offset; } // Get iframe element frames = from.parent.document.getElementsByTagName( 'iframe' ); for ( i = 0, len = frames.length; i < len; i++ ) { if ( frames[ i ].contentWindow === from ) { frame = frames[ i ]; break; } } // Recursively accumulate offset values if ( frame ) { rect = frame.getBoundingClientRect(); offset.left += rect.left; offset.top += rect.top; if ( from !== to ) { this.getFrameOffset( from.parent, offset ); } } return offset; }; /** * Get the offset between two elements. * * The two elements may be in a different frame, but in that case the frame $element is in must * be contained in the frame $anchor is in. * * @static * @param {jQuery} $element Element whose position to get * @param {jQuery} $anchor Element to get $element's position relative to * @return {Object} Translated position coordinates, containing top and left properties */ OO.ui.Element.static.getRelativePosition = function ( $element, $anchor ) { var iframe, iframePos, pos = $element.offset(), anchorPos = $anchor.offset(), elementDocument = this.getDocument( $element ), anchorDocument = this.getDocument( $anchor ); // If $element isn't in the same document as $anchor, traverse up while ( elementDocument !== anchorDocument ) { iframe = elementDocument.defaultView.frameElement; if ( !iframe ) { throw new Error( '$element frame is not contained in $anchor frame' ); } iframePos = $( iframe ).offset(); pos.left += iframePos.left; pos.top += iframePos.top; elementDocument = iframe.ownerDocument; } pos.left -= anchorPos.left; pos.top -= anchorPos.top; return pos; }; /** * Get element border sizes. * * @static * @param {HTMLElement} el Element to measure * @return {Object} Dimensions object with `top`, `left`, `bottom` and `right` properties */ OO.ui.Element.static.getBorders = function ( el ) { var doc = el.ownerDocument, // Support: IE 8 // Standard Document.defaultView is IE9+ win = doc.parentWindow || doc.defaultView, style = win && win.getComputedStyle ? win.getComputedStyle( el, null ) : // Support: IE 8 // Standard getComputedStyle() is IE9+ el.currentStyle, $el = $( el ), top = parseFloat( style ? style.borderTopWidth : $el.css( 'borderTopWidth' ) ) || 0, left = parseFloat( style ? style.borderLeftWidth : $el.css( 'borderLeftWidth' ) ) || 0, bottom = parseFloat( style ? style.borderBottomWidth : $el.css( 'borderBottomWidth' ) ) || 0, right = parseFloat( style ? style.borderRightWidth : $el.css( 'borderRightWidth' ) ) || 0; return { top: top, left: left, bottom: bottom, right: right }; }; /** * Get dimensions of an element or window. * * @static * @param {HTMLElement|Window} el Element to measure * @return {Object} Dimensions object with `borders`, `scroll`, `scrollbar` and `rect` properties */ OO.ui.Element.static.getDimensions = function ( el ) { var $el, $win, doc = el.ownerDocument || el.document, // Support: IE 8 // Standard Document.defaultView is IE9+ win = doc.parentWindow || doc.defaultView; if ( win === el || el === doc.documentElement ) { $win = $( win ); return { borders: { top: 0, left: 0, bottom: 0, right: 0 }, scroll: { top: $win.scrollTop(), left: $win.scrollLeft() }, scrollbar: { right: 0, bottom: 0 }, rect: { top: 0, left: 0, bottom: $win.innerHeight(), right: $win.innerWidth() } }; } else { $el = $( el ); return { borders: this.getBorders( el ), scroll: { top: $el.scrollTop(), left: $el.scrollLeft() }, scrollbar: { right: $el.innerWidth() - el.clientWidth, bottom: $el.innerHeight() - el.clientHeight }, rect: el.getBoundingClientRect() }; } }; /** * Get scrollable object parent * * documentElement can't be used to get or set the scrollTop * property on Blink. Changing and testing its value lets us * use 'body' or 'documentElement' based on what is working. * * https://code.google.com/p/chromium/issues/detail?id=303131 * * @static * @param {HTMLElement} el Element to find scrollable parent for * @return {HTMLElement} Scrollable parent */ OO.ui.Element.static.getRootScrollableElement = function ( el ) { var scrollTop, body; if ( OO.ui.scrollableElement === undefined ) { body = el.ownerDocument.body; scrollTop = body.scrollTop; body.scrollTop = 1; if ( body.scrollTop === 1 ) { body.scrollTop = scrollTop; OO.ui.scrollableElement = 'body'; } else { OO.ui.scrollableElement = 'documentElement'; } } return el.ownerDocument[ OO.ui.scrollableElement ]; }; /** * Get closest scrollable container. * * Traverses up until either a scrollable element or the root is reached, in which case the window * will be returned. * * @static * @param {HTMLElement} el Element to find scrollable container for * @param {string} [dimension] Dimension of scrolling to look for; `x`, `y` or omit for either * @return {HTMLElement} Closest scrollable container */ OO.ui.Element.static.getClosestScrollableContainer = function ( el, dimension ) { var i, val, // props = [ 'overflow' ] doesn't work due to https://bugzilla.mozilla.org/show_bug.cgi?id=889091 props = [ 'overflow-x', 'overflow-y' ], $parent = $( el ).parent(); if ( dimension === 'x' || dimension === 'y' ) { props = [ 'overflow-' + dimension ]; } while ( $parent.length ) { if ( $parent[ 0 ] === this.getRootScrollableElement( el ) ) { return $parent[ 0 ]; } i = props.length; while ( i-- ) { val = $parent.css( props[ i ] ); if ( val === 'auto' || val === 'scroll' ) { return $parent[ 0 ]; } } $parent = $parent.parent(); } return this.getDocument( el ).body; }; /** * Scroll element into view. * * @static * @param {HTMLElement} el Element to scroll into view * @param {Object} [config] Configuration options * @param {string} [config.duration] jQuery animation duration value * @param {string} [config.direction] Scroll in only one direction, e.g. 'x' or 'y', omit * to scroll in both directions * @param {Function} [config.complete] Function to call when scrolling completes */ OO.ui.Element.static.scrollIntoView = function ( el, config ) { var rel, anim, callback, sc, $sc, eld, scd, $win; // Configuration initialization config = config || {}; anim = {}; callback = typeof config.complete === 'function' && config.complete; sc = this.getClosestScrollableContainer( el, config.direction ); $sc = $( sc ); eld = this.getDimensions( el ); scd = this.getDimensions( sc ); $win = $( this.getWindow( el ) ); // Compute the distances between the edges of el and the edges of the scroll viewport if ( $sc.is( 'html, body' ) ) { // If the scrollable container is the root, this is easy rel = { top: eld.rect.top, bottom: $win.innerHeight() - eld.rect.bottom, left: eld.rect.left, right: $win.innerWidth() - eld.rect.right }; } else { // Otherwise, we have to subtract el's coordinates from sc's coordinates rel = { top: eld.rect.top - ( scd.rect.top + scd.borders.top ), bottom: scd.rect.bottom - scd.borders.bottom - scd.scrollbar.bottom - eld.rect.bottom, left: eld.rect.left - ( scd.rect.left + scd.borders.left ), right: scd.rect.right - scd.borders.right - scd.scrollbar.right - eld.rect.right }; } if ( !config.direction || config.direction === 'y' ) { if ( rel.top < 0 ) { anim.scrollTop = scd.scroll.top + rel.top; } else if ( rel.top > 0 && rel.bottom < 0 ) { anim.scrollTop = scd.scroll.top + Math.min( rel.top, -rel.bottom ); } } if ( !config.direction || config.direction === 'x' ) { if ( rel.left < 0 ) { anim.scrollLeft = scd.scroll.left + rel.left; } else if ( rel.left > 0 && rel.right < 0 ) { anim.scrollLeft = scd.scroll.left + Math.min( rel.left, -rel.right ); } } if ( !$.isEmptyObject( anim ) ) { $sc.stop( true ).animate( anim, config.duration || 'fast' ); if ( callback ) { $sc.queue( function ( next ) { callback(); next(); } ); } } else { if ( callback ) { callback(); } } }; /** * Force the browser to reconsider whether it really needs to render scrollbars inside the element * and reserve space for them, because it probably doesn't. * * Workaround primarily for <https://code.google.com/p/chromium/issues/detail?id=387290>, but also * similar bugs in other browsers. "Just" forcing a reflow is not sufficient in all cases, we need * to first actually detach (or hide, but detaching is simpler) all children, *then* force a reflow, * and then reattach (or show) them back. * * @static * @param {HTMLElement} el Element to reconsider the scrollbars on */ OO.ui.Element.static.reconsiderScrollbars = function ( el ) { var i, len, scrollLeft, scrollTop, nodes = []; // Save scroll position scrollLeft = el.scrollLeft; scrollTop = el.scrollTop; // Detach all children while ( el.firstChild ) { nodes.push( el.firstChild ); el.removeChild( el.firstChild ); } // Force reflow void el.offsetHeight; // Reattach all children for ( i = 0, len = nodes.length; i < len; i++ ) { el.appendChild( nodes[ i ] ); } // Restore scroll position (no-op if scrollbars disappeared) el.scrollLeft = scrollLeft; el.scrollTop = scrollTop; }; /* Methods */ /** * Toggle visibility of an element. * * @param {boolean} [show] Make element visible, omit to toggle visibility * @fires visible * @chainable */ OO.ui.Element.prototype.toggle = function ( show ) { show = show === undefined ? !this.visible : !!show; if ( show !== this.isVisible() ) { this.visible = show; this.$element.toggleClass( 'oo-ui-element-hidden', !this.visible ); this.emit( 'toggle', show ); } return this; }; /** * Check if element is visible. * * @return {boolean} element is visible */ OO.ui.Element.prototype.isVisible = function () { return this.visible; }; /** * Get element data. * * @return {Mixed} Element data */ OO.ui.Element.prototype.getData = function () { return this.data; }; /** * Set element data. * * @param {Mixed} Element data * @chainable */ OO.ui.Element.prototype.setData = function ( data ) { this.data = data; return this; }; /** * Check if element supports one or more methods. * * @param {string|string[]} methods Method or list of methods to check * @return {boolean} All methods are supported */ OO.ui.Element.prototype.supports = function ( methods ) { var i, len, support = 0; methods = Array.isArray( methods ) ? methods : [ methods ]; for ( i = 0, len = methods.length; i < len; i++ ) { if ( $.isFunction( this[ methods[ i ] ] ) ) { support++; } } return methods.length === support; }; /** * Update the theme-provided classes. * * @localdoc This is called in element mixins and widget classes any time state changes. * Updating is debounced, minimizing overhead of changing multiple attributes and * guaranteeing that theme updates do not occur within an element's constructor */ OO.ui.Element.prototype.updateThemeClasses = function () { this.debouncedUpdateThemeClassesHandler(); }; /** * @private * @localdoc This method is called directly from the QUnit tests instead of #updateThemeClasses, to * make them synchronous. */ OO.ui.Element.prototype.debouncedUpdateThemeClasses = function () { OO.ui.theme.updateElementClasses( this ); }; /** * Get the HTML tag name. * * Override this method to base the result on instance information. * * @return {string} HTML tag name */ OO.ui.Element.prototype.getTagName = function () { return this.constructor.static.tagName; }; /** * Check if the element is attached to the DOM * @return {boolean} The element is attached to the DOM */ OO.ui.Element.prototype.isElementAttached = function () { return $.contains( this.getElementDocument(), this.$element[ 0 ] ); }; /** * Get the DOM document. * * @return {HTMLDocument} Document object */ OO.ui.Element.prototype.getElementDocument = function () { // Don't cache this in other ways either because subclasses could can change this.$element return OO.ui.Element.static.getDocument( this.$element ); }; /** * Get the DOM window. * * @return {Window} Window object */ OO.ui.Element.prototype.getElementWindow = function () { return OO.ui.Element.static.getWindow( this.$element ); }; /** * Get closest scrollable container. */ OO.ui.Element.prototype.getClosestScrollableElementContainer = function () { return OO.ui.Element.static.getClosestScrollableContainer( this.$element[ 0 ] ); }; /** * Get group element is in. * * @return {OO.ui.mixin.GroupElement|null} Group element, null if none */ OO.ui.Element.prototype.getElementGroup = function () { return this.elementGroup; }; /** * Set group element is in. * * @param {OO.ui.mixin.GroupElement|null} group Group element, null if none * @chainable */ OO.ui.Element.prototype.setElementGroup = function ( group ) { this.elementGroup = group; return this; }; /** * Scroll element into view. * * @param {Object} [config] Configuration options */ OO.ui.Element.prototype.scrollElementIntoView = function ( config ) { return OO.ui.Element.static.scrollIntoView( this.$element[ 0 ], config ); }; /** * Restore the pre-infusion dynamic state for this widget. * * This method is called after #$element has been inserted into DOM. The parameter is the return * value of #gatherPreInfuseState. * * @protected * @param {Object} state */ OO.ui.Element.prototype.restorePreInfuseState = function () { }; /** * Layouts are containers for elements and are used to arrange other widgets of arbitrary type in a way * that is centrally controlled and can be updated dynamically. Layouts can be, and usually are, combined. * See {@link OO.ui.FieldsetLayout FieldsetLayout}, {@link OO.ui.FieldLayout FieldLayout}, {@link OO.ui.FormLayout FormLayout}, * {@link OO.ui.PanelLayout PanelLayout}, {@link OO.ui.StackLayout StackLayout}, {@link OO.ui.PageLayout PageLayout}, * {@link OO.ui.HorizontalLayout HorizontalLayout}, and {@link OO.ui.BookletLayout BookletLayout} for more information and examples. * * @abstract * @class * @extends OO.ui.Element * @mixins OO.EventEmitter * * @constructor * @param {Object} [config] Configuration options */ OO.ui.Layout = function OoUiLayout( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.Layout.parent.call( this, config ); // Mixin constructors OO.EventEmitter.call( this ); // Initialization this.$element.addClass( 'oo-ui-layout' ); }; /* Setup */ OO.inheritClass( OO.ui.Layout, OO.ui.Element ); OO.mixinClass( OO.ui.Layout, OO.EventEmitter ); /** * Widgets are compositions of one or more OOjs UI elements that users can both view * and interact with. All widgets can be configured and modified via a standard API, * and their state can change dynamically according to a model. * * @abstract * @class * @extends OO.ui.Element * @mixins OO.EventEmitter * * @constructor * @param {Object} [config] Configuration options * @cfg {boolean} [disabled=false] Disable the widget. Disabled widgets cannot be used and their * appearance reflects this state. */ OO.ui.Widget = function OoUiWidget( config ) { // Initialize config config = $.extend( { disabled: false }, config ); // Parent constructor OO.ui.Widget.parent.call( this, config ); // Mixin constructors OO.EventEmitter.call( this ); // Properties this.disabled = null; this.wasDisabled = null; // Initialization this.$element.addClass( 'oo-ui-widget' ); this.setDisabled( !!config.disabled ); }; /* Setup */ OO.inheritClass( OO.ui.Widget, OO.ui.Element ); OO.mixinClass( OO.ui.Widget, OO.EventEmitter ); /* Static Properties */ /** * Whether this widget will behave reasonably when wrapped in a HTML `<label>`. If this is true, * wrappers such as OO.ui.FieldLayout may use a `<label>` instead of implementing own label click * handling. * * @static * @inheritable * @property {boolean} */ OO.ui.Widget.static.supportsSimpleLabel = false; /* Events */ /** * @event disable * * A 'disable' event is emitted when the disabled state of the widget changes * (i.e. on disable **and** enable). * * @param {boolean} disabled Widget is disabled */ /** * @event toggle * * A 'toggle' event is emitted when the visibility of the widget changes. * * @param {boolean} visible Widget is visible */ /* Methods */ /** * Check if the widget is disabled. * * @return {boolean} Widget is disabled */ OO.ui.Widget.prototype.isDisabled = function () { return this.disabled; }; /** * Set the 'disabled' state of the widget. * * When a widget is disabled, it cannot be used and its appearance is updated to reflect this state. * * @param {boolean} disabled Disable widget * @chainable */ OO.ui.Widget.prototype.setDisabled = function ( disabled ) { var isDisabled; this.disabled = !!disabled; isDisabled = this.isDisabled(); if ( isDisabled !== this.wasDisabled ) { this.$element.toggleClass( 'oo-ui-widget-disabled', isDisabled ); this.$element.toggleClass( 'oo-ui-widget-enabled', !isDisabled ); this.$element.attr( 'aria-disabled', isDisabled.toString() ); this.emit( 'disable', isDisabled ); this.updateThemeClasses(); } this.wasDisabled = isDisabled; return this; }; /** * Update the disabled state, in case of changes in parent widget. * * @chainable */ OO.ui.Widget.prototype.updateDisabled = function () { this.setDisabled( this.disabled ); return this; }; /** * A window is a container for elements that are in a child frame. They are used with * a window manager (OO.ui.WindowManager), which is used to open and close the window and control * its presentation. The size of a window is specified using a symbolic name (e.g., ‘small’, ‘medium’, * ‘large’), which is interpreted by the window manager. If the requested size is not recognized, * the window manager will choose a sensible fallback. * * The lifecycle of a window has three primary stages (opening, opened, and closing) in which * different processes are executed: * * **opening**: The opening stage begins when the window manager's {@link OO.ui.WindowManager#openWindow * openWindow} or the window's {@link #open open} methods are used, and the window manager begins to open * the window. * * - {@link #getSetupProcess} method is called and its result executed * - {@link #getReadyProcess} method is called and its result executed * * **opened**: The window is now open * * **closing**: The closing stage begins when the window manager's * {@link OO.ui.WindowManager#closeWindow closeWindow} * or the window's {@link #close} methods are used, and the window manager begins to close the window. * * - {@link #getHoldProcess} method is called and its result executed * - {@link #getTeardownProcess} method is called and its result executed. The window is now closed * * Each of the window's processes (setup, ready, hold, and teardown) can be extended in subclasses * by overriding the window's #getSetupProcess, #getReadyProcess, #getHoldProcess and #getTeardownProcess * methods. Note that each {@link OO.ui.Process process} is executed in series, so asynchronous * processing can complete. Always assume window processes are executed asynchronously. * * For more information, please see the [OOjs UI documentation on MediaWiki] [1]. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Windows * * @abstract * @class * @extends OO.ui.Element * @mixins OO.EventEmitter * * @constructor * @param {Object} [config] Configuration options * @cfg {string} [size] Symbolic name of the dialog size: `small`, `medium`, `large`, `larger` or * `full`. If omitted, the value of the {@link #static-size static size} property will be used. */ OO.ui.Window = function OoUiWindow( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.Window.parent.call( this, config ); // Mixin constructors OO.EventEmitter.call( this ); // Properties this.manager = null; this.size = config.size || this.constructor.static.size; this.$frame = $( '<div>' ); this.$overlay = $( '<div>' ); this.$content = $( '<div>' ); this.$focusTrapBefore = $( '<div>' ).prop( 'tabIndex', 0 ); this.$focusTrapAfter = $( '<div>' ).prop( 'tabIndex', 0 ); this.$focusTraps = this.$focusTrapBefore.add( this.$focusTrapAfter ); // Initialization this.$overlay.addClass( 'oo-ui-window-overlay' ); this.$content .addClass( 'oo-ui-window-content' ) .attr( 'tabindex', 0 ); this.$frame .addClass( 'oo-ui-window-frame' ) .append( this.$focusTrapBefore, this.$content, this.$focusTrapAfter ); this.$element .addClass( 'oo-ui-window' ) .append( this.$frame, this.$overlay ); // Initially hidden - using #toggle may cause errors if subclasses override toggle with methods // that reference properties not initialized at that time of parent class construction // TODO: Find a better way to handle post-constructor setup this.visible = false; this.$element.addClass( 'oo-ui-element-hidden' ); }; /* Setup */ OO.inheritClass( OO.ui.Window, OO.ui.Element ); OO.mixinClass( OO.ui.Window, OO.EventEmitter ); /* Static Properties */ /** * Symbolic name of the window size: `small`, `medium`, `large`, `larger` or `full`. * * The static size is used if no #size is configured during construction. * * @static * @inheritable * @property {string} */ OO.ui.Window.static.size = 'medium'; /* Methods */ /** * Handle mouse down events. * * @private * @param {jQuery.Event} e Mouse down event */ OO.ui.Window.prototype.onMouseDown = function ( e ) { // Prevent clicking on the click-block from stealing focus if ( e.target === this.$element[ 0 ] ) { return false; } }; /** * Check if the window has been initialized. * * Initialization occurs when a window is added to a manager. * * @return {boolean} Window has been initialized */ OO.ui.Window.prototype.isInitialized = function () { return !!this.manager; }; /** * Check if the window is visible. * * @return {boolean} Window is visible */ OO.ui.Window.prototype.isVisible = function () { return this.visible; }; /** * Check if the window is opening. * * This method is a wrapper around the window manager's {@link OO.ui.WindowManager#isOpening isOpening} * method. * * @return {boolean} Window is opening */ OO.ui.Window.prototype.isOpening = function () { return this.manager.isOpening( this ); }; /** * Check if the window is closing. * * This method is a wrapper around the window manager's {@link OO.ui.WindowManager#isClosing isClosing} method. * * @return {boolean} Window is closing */ OO.ui.Window.prototype.isClosing = function () { return this.manager.isClosing( this ); }; /** * Check if the window is opened. * * This method is a wrapper around the window manager's {@link OO.ui.WindowManager#isOpened isOpened} method. * * @return {boolean} Window is opened */ OO.ui.Window.prototype.isOpened = function () { return this.manager.isOpened( this ); }; /** * Get the window manager. * * All windows must be attached to a window manager, which is used to open * and close the window and control its presentation. * * @return {OO.ui.WindowManager} Manager of window */ OO.ui.Window.prototype.getManager = function () { return this.manager; }; /** * Get the symbolic name of the window size (e.g., `small` or `medium`). * * @return {string} Symbolic name of the size: `small`, `medium`, `large`, `larger`, `full` */ OO.ui.Window.prototype.getSize = function () { var viewport = OO.ui.Element.static.getDimensions( this.getElementWindow() ), sizes = this.manager.constructor.static.sizes, size = this.size; if ( !sizes[ size ] ) { size = this.manager.constructor.static.defaultSize; } if ( size !== 'full' && viewport.rect.right - viewport.rect.left < sizes[ size ].width ) { size = 'full'; } return size; }; /** * Get the size properties associated with the current window size * * @return {Object} Size properties */ OO.ui.Window.prototype.getSizeProperties = function () { return this.manager.constructor.static.sizes[ this.getSize() ]; }; /** * Disable transitions on window's frame for the duration of the callback function, then enable them * back. * * @private * @param {Function} callback Function to call while transitions are disabled */ OO.ui.Window.prototype.withoutSizeTransitions = function ( callback ) { // Temporarily resize the frame so getBodyHeight() can use scrollHeight measurements. // Disable transitions first, otherwise we'll get values from when the window was animating. var oldTransition, styleObj = this.$frame[ 0 ].style; oldTransition = styleObj.transition || styleObj.OTransition || styleObj.MsTransition || styleObj.MozTransition || styleObj.WebkitTransition; styleObj.transition = styleObj.OTransition = styleObj.MsTransition = styleObj.MozTransition = styleObj.WebkitTransition = 'none'; callback(); // Force reflow to make sure the style changes done inside callback really are not transitioned this.$frame.height(); styleObj.transition = styleObj.OTransition = styleObj.MsTransition = styleObj.MozTransition = styleObj.WebkitTransition = oldTransition; }; /** * Get the height of the full window contents (i.e., the window head, body and foot together). * * What consistitutes the head, body, and foot varies depending on the window type. * A {@link OO.ui.MessageDialog message dialog} displays a title and message in its body, * and any actions in the foot. A {@link OO.ui.ProcessDialog process dialog} displays a title * and special actions in the head, and dialog content in the body. * * To get just the height of the dialog body, use the #getBodyHeight method. * * @return {number} The height of the window contents (the dialog head, body and foot) in pixels */ OO.ui.Window.prototype.getContentHeight = function () { var bodyHeight, win = this, bodyStyleObj = this.$body[ 0 ].style, frameStyleObj = this.$frame[ 0 ].style; // Temporarily resize the frame so getBodyHeight() can use scrollHeight measurements. // Disable transitions first, otherwise we'll get values from when the window was animating. this.withoutSizeTransitions( function () { var oldHeight = frameStyleObj.height, oldPosition = bodyStyleObj.position; frameStyleObj.height = '1px'; // Force body to resize to new width bodyStyleObj.position = 'relative'; bodyHeight = win.getBodyHeight(); frameStyleObj.height = oldHeight; bodyStyleObj.position = oldPosition; } ); return ( // Add buffer for border ( this.$frame.outerHeight() - this.$frame.innerHeight() ) + // Use combined heights of children ( this.$head.outerHeight( true ) + bodyHeight + this.$foot.outerHeight( true ) ) ); }; /** * Get the height of the window body. * * To get the height of the full window contents (the window body, head, and foot together), * use #getContentHeight. * * When this function is called, the window will temporarily have been resized * to height=1px, so .scrollHeight measurements can be taken accurately. * * @return {number} Height of the window body in pixels */ OO.ui.Window.prototype.getBodyHeight = function () { return this.$body[ 0 ].scrollHeight; }; /** * Get the directionality of the frame (right-to-left or left-to-right). * * @return {string} Directionality: `'ltr'` or `'rtl'` */ OO.ui.Window.prototype.getDir = function () { return OO.ui.Element.static.getDir( this.$content ) || 'ltr'; }; /** * Get the 'setup' process. * * The setup process is used to set up a window for use in a particular context, * based on the `data` argument. This method is called during the opening phase of the window’s * lifecycle. * * Override this method to add additional steps to the ‘setup’ process the parent method provides * using the {@link OO.ui.Process#first first} and {@link OO.ui.Process#next next} methods * of OO.ui.Process. * * To add window content that persists between openings, you may wish to use the #initialize method * instead. * * @abstract * @param {Object} [data] Window opening data * @return {OO.ui.Process} Setup process */ OO.ui.Window.prototype.getSetupProcess = function () { return new OO.ui.Process(); }; /** * Get the ‘ready’ process. * * The ready process is used to ready a window for use in a particular * context, based on the `data` argument. This method is called during the opening phase of * the window’s lifecycle, after the window has been {@link #getSetupProcess setup}. * * Override this method to add additional steps to the ‘ready’ process the parent method * provides using the {@link OO.ui.Process#first first} and {@link OO.ui.Process#next next} * methods of OO.ui.Process. * * @abstract * @param {Object} [data] Window opening data * @return {OO.ui.Process} Ready process */ OO.ui.Window.prototype.getReadyProcess = function () { return new OO.ui.Process(); }; /** * Get the 'hold' process. * * The hold proccess is used to keep a window from being used in a particular context, * based on the `data` argument. This method is called during the closing phase of the window’s * lifecycle. * * Override this method to add additional steps to the 'hold' process the parent method provides * using the {@link OO.ui.Process#first first} and {@link OO.ui.Process#next next} methods * of OO.ui.Process. * * @abstract * @param {Object} [data] Window closing data * @return {OO.ui.Process} Hold process */ OO.ui.Window.prototype.getHoldProcess = function () { return new OO.ui.Process(); }; /** * Get the ‘teardown’ process. * * The teardown process is used to teardown a window after use. During teardown, * user interactions within the window are conveyed and the window is closed, based on the `data` * argument. This method is called during the closing phase of the window’s lifecycle. * * Override this method to add additional steps to the ‘teardown’ process the parent method provides * using the {@link OO.ui.Process#first first} and {@link OO.ui.Process#next next} methods * of OO.ui.Process. * * @abstract * @param {Object} [data] Window closing data * @return {OO.ui.Process} Teardown process */ OO.ui.Window.prototype.getTeardownProcess = function () { return new OO.ui.Process(); }; /** * Set the window manager. * * This will cause the window to initialize. Calling it more than once will cause an error. * * @param {OO.ui.WindowManager} manager Manager for this window * @throws {Error} An error is thrown if the method is called more than once * @chainable */ OO.ui.Window.prototype.setManager = function ( manager ) { if ( this.manager ) { throw new Error( 'Cannot set window manager, window already has a manager' ); } this.manager = manager; this.initialize(); return this; }; /** * Set the window size by symbolic name (e.g., 'small' or 'medium') * * @param {string} size Symbolic name of size: `small`, `medium`, `large`, `larger` or * `full` * @chainable */ OO.ui.Window.prototype.setSize = function ( size ) { this.size = size; this.updateSize(); return this; }; /** * Update the window size. * * @throws {Error} An error is thrown if the window is not attached to a window manager * @chainable */ OO.ui.Window.prototype.updateSize = function () { if ( !this.manager ) { throw new Error( 'Cannot update window size, must be attached to a manager' ); } this.manager.updateWindowSize( this ); return this; }; /** * Set window dimensions. This method is called by the {@link OO.ui.WindowManager window manager} * when the window is opening. In general, setDimensions should not be called directly. * * To set the size of the window, use the #setSize method. * * @param {Object} dim CSS dimension properties * @param {string|number} [dim.width] Width * @param {string|number} [dim.minWidth] Minimum width * @param {string|number} [dim.maxWidth] Maximum width * @param {string|number} [dim.width] Height, omit to set based on height of contents * @param {string|number} [dim.minWidth] Minimum height * @param {string|number} [dim.maxWidth] Maximum height * @chainable */ OO.ui.Window.prototype.setDimensions = function ( dim ) { var height, win = this, styleObj = this.$frame[ 0 ].style; // Calculate the height we need to set using the correct width if ( dim.height === undefined ) { this.withoutSizeTransitions( function () { var oldWidth = styleObj.width; win.$frame.css( 'width', dim.width || '' ); height = win.getContentHeight(); styleObj.width = oldWidth; } ); } else { height = dim.height; } this.$frame.css( { width: dim.width || '', minWidth: dim.minWidth || '', maxWidth: dim.maxWidth || '', height: height || '', minHeight: dim.minHeight || '', maxHeight: dim.maxHeight || '' } ); return this; }; /** * Initialize window contents. * * Before the window is opened for the first time, #initialize is called so that content that * persists between openings can be added to the window. * * To set up a window with new content each time the window opens, use #getSetupProcess. * * @throws {Error} An error is thrown if the window is not attached to a window manager * @chainable */ OO.ui.Window.prototype.initialize = function () { if ( !this.manager ) { throw new Error( 'Cannot initialize window, must be attached to a manager' ); } // Properties this.$head = $( '<div>' ); this.$body = $( '<div>' ); this.$foot = $( '<div>' ); this.$document = $( this.getElementDocument() ); // Events this.$element.on( 'mousedown', this.onMouseDown.bind( this ) ); // Initialization this.$head.addClass( 'oo-ui-window-head' ); this.$body.addClass( 'oo-ui-window-body' ); this.$foot.addClass( 'oo-ui-window-foot' ); this.$content.append( this.$head, this.$body, this.$foot ); return this; }; /** * Called when someone tries to focus the hidden element at the end of the dialog. * Sends focus back to the start of the dialog. * * @param {jQuery.Event} event Focus event */ OO.ui.Window.prototype.onFocusTrapFocused = function ( event ) { if ( this.$focusTrapBefore.is( event.target ) ) { OO.ui.findFocusable( this.$content, true ).focus(); } else { // this.$content is the part of the focus cycle, and is the first focusable element this.$content.focus(); } }; /** * Open the window. * * This method is a wrapper around a call to the window manager’s {@link OO.ui.WindowManager#openWindow openWindow} * method, which returns a promise resolved when the window is done opening. * * To customize the window each time it opens, use #getSetupProcess or #getReadyProcess. * * @param {Object} [data] Window opening data * @return {jQuery.Promise} Promise resolved with a value when the window is opened, or rejected * if the window fails to open. When the promise is resolved successfully, the first argument of the * value is a new promise, which is resolved when the window begins closing. * @throws {Error} An error is thrown if the window is not attached to a window manager */ OO.ui.Window.prototype.open = function ( data ) { if ( !this.manager ) { throw new Error( 'Cannot open window, must be attached to a manager' ); } return this.manager.openWindow( this, data ); }; /** * Close the window. * * This method is a wrapper around a call to the window * manager’s {@link OO.ui.WindowManager#closeWindow closeWindow} method, * which returns a closing promise resolved when the window is done closing. * * The window's #getHoldProcess and #getTeardownProcess methods are called during the closing * phase of the window’s lifecycle and can be used to specify closing behavior each time * the window closes. * * @param {Object} [data] Window closing data * @return {jQuery.Promise} Promise resolved when window is closed * @throws {Error} An error is thrown if the window is not attached to a window manager */ OO.ui.Window.prototype.close = function ( data ) { if ( !this.manager ) { throw new Error( 'Cannot close window, must be attached to a manager' ); } return this.manager.closeWindow( this, data ); }; /** * Setup window. * * This is called by OO.ui.WindowManager during window opening, and should not be called directly * by other systems. * * @param {Object} [data] Window opening data * @return {jQuery.Promise} Promise resolved when window is setup */ OO.ui.Window.prototype.setup = function ( data ) { var win = this, deferred = $.Deferred(); this.toggle( true ); this.focusTrapHandler = OO.ui.bind( this.onFocusTrapFocused, this ); this.$focusTraps.on( 'focus', this.focusTrapHandler ); this.getSetupProcess( data ).execute().done( function () { // Force redraw by asking the browser to measure the elements' widths win.$element.addClass( 'oo-ui-window-active oo-ui-window-setup' ).width(); win.$content.addClass( 'oo-ui-window-content-setup' ).width(); deferred.resolve(); } ); return deferred.promise(); }; /** * Ready window. * * This is called by OO.ui.WindowManager during window opening, and should not be called directly * by other systems. * * @param {Object} [data] Window opening data * @return {jQuery.Promise} Promise resolved when window is ready */ OO.ui.Window.prototype.ready = function ( data ) { var win = this, deferred = $.Deferred(); this.$content.focus(); this.getReadyProcess( data ).execute().done( function () { // Force redraw by asking the browser to measure the elements' widths win.$element.addClass( 'oo-ui-window-ready' ).width(); win.$content.addClass( 'oo-ui-window-content-ready' ).width(); deferred.resolve(); } ); return deferred.promise(); }; /** * Hold window. * * This is called by OO.ui.WindowManager during window closing, and should not be called directly * by other systems. * * @param {Object} [data] Window closing data * @return {jQuery.Promise} Promise resolved when window is held */ OO.ui.Window.prototype.hold = function ( data ) { var win = this, deferred = $.Deferred(); this.getHoldProcess( data ).execute().done( function () { // Get the focused element within the window's content var $focus = win.$content.find( OO.ui.Element.static.getDocument( win.$content ).activeElement ); // Blur the focused element if ( $focus.length ) { $focus[ 0 ].blur(); } // Force redraw by asking the browser to measure the elements' widths win.$element.removeClass( 'oo-ui-window-ready' ).width(); win.$content.removeClass( 'oo-ui-window-content-ready' ).width(); deferred.resolve(); } ); return deferred.promise(); }; /** * Teardown window. * * This is called by OO.ui.WindowManager during window closing, and should not be called directly * by other systems. * * @param {Object} [data] Window closing data * @return {jQuery.Promise} Promise resolved when window is torn down */ OO.ui.Window.prototype.teardown = function ( data ) { var win = this; return this.getTeardownProcess( data ).execute() .done( function () { // Force redraw by asking the browser to measure the elements' widths win.$element.removeClass( 'oo-ui-window-active oo-ui-window-setup' ).width(); win.$content.removeClass( 'oo-ui-window-content-setup' ).width(); win.$focusTraps.off( 'focus', win.focusTrapHandler ); win.toggle( false ); } ); }; /** * The Dialog class serves as the base class for the other types of dialogs. * Unless extended to include controls, the rendered dialog box is a simple window * that users can close by hitting the ‘Esc’ key. Dialog windows are used with OO.ui.WindowManager, * which opens, closes, and controls the presentation of the window. See the * [OOjs UI documentation on MediaWiki] [1] for more information. * * @example * // A simple dialog window. * function MyDialog( config ) { * MyDialog.parent.call( this, config ); * } * OO.inheritClass( MyDialog, OO.ui.Dialog ); * MyDialog.prototype.initialize = function () { * MyDialog.parent.prototype.initialize.call( this ); * this.content = new OO.ui.PanelLayout( { padded: true, expanded: false } ); * this.content.$element.append( '<p>A simple dialog window. Press \'Esc\' to close.</p>' ); * this.$body.append( this.content.$element ); * }; * MyDialog.prototype.getBodyHeight = function () { * return this.content.$element.outerHeight( true ); * }; * var myDialog = new MyDialog( { * size: 'medium' * } ); * // Create and append a window manager, which opens and closes the window. * var windowManager = new OO.ui.WindowManager(); * $( 'body' ).append( windowManager.$element ); * windowManager.addWindows( [ myDialog ] ); * // Open the window! * windowManager.openWindow( myDialog ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Windows/Dialogs * * @abstract * @class * @extends OO.ui.Window * @mixins OO.ui.mixin.PendingElement * * @constructor * @param {Object} [config] Configuration options */ OO.ui.Dialog = function OoUiDialog( config ) { // Parent constructor OO.ui.Dialog.parent.call( this, config ); // Mixin constructors OO.ui.mixin.PendingElement.call( this ); // Properties this.actions = new OO.ui.ActionSet(); this.attachedActions = []; this.currentAction = null; this.onDialogKeyDownHandler = this.onDialogKeyDown.bind( this ); // Events this.actions.connect( this, { click: 'onActionClick', resize: 'onActionResize', change: 'onActionsChange' } ); // Initialization this.$element .addClass( 'oo-ui-dialog' ) .attr( 'role', 'dialog' ); }; /* Setup */ OO.inheritClass( OO.ui.Dialog, OO.ui.Window ); OO.mixinClass( OO.ui.Dialog, OO.ui.mixin.PendingElement ); /* Static Properties */ /** * Symbolic name of dialog. * * The dialog class must have a symbolic name in order to be registered with OO.Factory. * Please see the [OOjs UI documentation on MediaWiki] [3] for more information. * * [3]: https://www.mediawiki.org/wiki/OOjs_UI/Windows/Window_managers * * @abstract * @static * @inheritable * @property {string} */ OO.ui.Dialog.static.name = ''; /** * The dialog title. * * The title can be specified as a plaintext string, a {@link OO.ui.mixin.LabelElement Label} node, or a function * that will produce a Label node or string. The title can also be specified with data passed to the * constructor (see #getSetupProcess). In this case, the static value will be overriden. * * @abstract * @static * @inheritable * @property {jQuery|string|Function} */ OO.ui.Dialog.static.title = ''; /** * An array of configured {@link OO.ui.ActionWidget action widgets}. * * Actions can also be specified with data passed to the constructor (see #getSetupProcess). In this case, the static * value will be overriden. * * [2]: https://www.mediawiki.org/wiki/OOjs_UI/Windows/Process_Dialogs#Action_sets * * @static * @inheritable * @property {Object[]} */ OO.ui.Dialog.static.actions = []; /** * Close the dialog when the 'Esc' key is pressed. * * @static * @abstract * @inheritable * @property {boolean} */ OO.ui.Dialog.static.escapable = true; /* Methods */ /** * Handle frame document key down events. * * @private * @param {jQuery.Event} e Key down event */ OO.ui.Dialog.prototype.onDialogKeyDown = function ( e ) { if ( e.which === OO.ui.Keys.ESCAPE ) { this.close(); e.preventDefault(); e.stopPropagation(); } }; /** * Handle action resized events. * * @private * @param {OO.ui.ActionWidget} action Action that was resized */ OO.ui.Dialog.prototype.onActionResize = function () { // Override in subclass }; /** * Handle action click events. * * @private * @param {OO.ui.ActionWidget} action Action that was clicked */ OO.ui.Dialog.prototype.onActionClick = function ( action ) { if ( !this.isPending() ) { this.executeAction( action.getAction() ); } }; /** * Handle actions change event. * * @private */ OO.ui.Dialog.prototype.onActionsChange = function () { this.detachActions(); if ( !this.isClosing() ) { this.attachActions(); } }; /** * Get the set of actions used by the dialog. * * @return {OO.ui.ActionSet} */ OO.ui.Dialog.prototype.getActions = function () { return this.actions; }; /** * Get a process for taking action. * * When you override this method, you can create a new OO.ui.Process and return it, or add additional * accept steps to the process the parent method provides using the {@link OO.ui.Process#first 'first'} * and {@link OO.ui.Process#next 'next'} methods of OO.ui.Process. * * @abstract * @param {string} [action] Symbolic name of action * @return {OO.ui.Process} Action process */ OO.ui.Dialog.prototype.getActionProcess = function ( action ) { return new OO.ui.Process() .next( function () { if ( !action ) { // An empty action always closes the dialog without data, which should always be // safe and make no changes this.close(); } }, this ); }; /** * @inheritdoc * * @param {Object} [data] Dialog opening data * @param {jQuery|string|Function|null} [data.title] Dialog title, omit to use * the {@link #static-title static title} * @param {Object[]} [data.actions] List of configuration options for each * {@link OO.ui.ActionWidget action widget}, omit to use {@link #static-actions static actions}. */ OO.ui.Dialog.prototype.getSetupProcess = function ( data ) { data = data || {}; // Parent method return OO.ui.Dialog.parent.prototype.getSetupProcess.call( this, data ) .next( function () { var config = this.constructor.static, actions = data.actions !== undefined ? data.actions : config.actions; this.title.setLabel( data.title !== undefined ? data.title : this.constructor.static.title ); this.actions.add( this.getActionWidgets( actions ) ); if ( this.constructor.static.escapable ) { this.$element.on( 'keydown', this.onDialogKeyDownHandler ); } }, this ); }; /** * @inheritdoc */ OO.ui.Dialog.prototype.getTeardownProcess = function ( data ) { // Parent method return OO.ui.Dialog.parent.prototype.getTeardownProcess.call( this, data ) .first( function () { if ( this.constructor.static.escapable ) { this.$element.off( 'keydown', this.onDialogKeyDownHandler ); } this.actions.clear(); this.currentAction = null; }, this ); }; /** * @inheritdoc */ OO.ui.Dialog.prototype.initialize = function () { var titleId; // Parent method OO.ui.Dialog.parent.prototype.initialize.call( this ); titleId = OO.ui.generateElementId(); // Properties this.title = new OO.ui.LabelWidget( { id: titleId } ); // Initialization this.$content.addClass( 'oo-ui-dialog-content' ); this.$element.attr( 'aria-labelledby', titleId ); this.setPendingElement( this.$head ); }; /** * Get action widgets from a list of configs * * @param {Object[]} actions Action widget configs * @return {OO.ui.ActionWidget[]} Action widgets */ OO.ui.Dialog.prototype.getActionWidgets = function ( actions ) { var i, len, widgets = []; for ( i = 0, len = actions.length; i < len; i++ ) { widgets.push( new OO.ui.ActionWidget( actions[ i ] ) ); } return widgets; }; /** * Attach action actions. * * @protected */ OO.ui.Dialog.prototype.attachActions = function () { // Remember the list of potentially attached actions this.attachedActions = this.actions.get(); }; /** * Detach action actions. * * @protected * @chainable */ OO.ui.Dialog.prototype.detachActions = function () { var i, len; // Detach all actions that may have been previously attached for ( i = 0, len = this.attachedActions.length; i < len; i++ ) { this.attachedActions[ i ].$element.detach(); } this.attachedActions = []; }; /** * Execute an action. * * @param {string} action Symbolic name of action to execute * @return {jQuery.Promise} Promise resolved when action completes, rejected if it fails */ OO.ui.Dialog.prototype.executeAction = function ( action ) { this.pushPending(); this.currentAction = action; return this.getActionProcess( action ).execute() .always( this.popPending.bind( this ) ); }; /** * Window managers are used to open and close {@link OO.ui.Window windows} and control their presentation. * Managed windows are mutually exclusive. If a new window is opened while a current window is opening * or is opened, the current window will be closed and any ongoing {@link OO.ui.Process process} will be cancelled. Windows * themselves are persistent and—rather than being torn down when closed—can be repopulated with the * pertinent data and reused. * * Over the lifecycle of a window, the window manager makes available three promises: `opening`, * `opened`, and `closing`, which represent the primary stages of the cycle: * * **Opening**: the opening stage begins when the window manager’s #openWindow or a window’s * {@link OO.ui.Window#open open} method is used, and the window manager begins to open the window. * * - an `opening` event is emitted with an `opening` promise * - the #getSetupDelay method is called and the returned value is used to time a pause in execution before * the window’s {@link OO.ui.Window#getSetupProcess getSetupProcess} method is called on the * window and its result executed * - a `setup` progress notification is emitted from the `opening` promise * - the #getReadyDelay method is called the returned value is used to time a pause in execution before * the window’s {@link OO.ui.Window#getReadyProcess getReadyProcess} method is called on the * window and its result executed * - a `ready` progress notification is emitted from the `opening` promise * - the `opening` promise is resolved with an `opened` promise * * **Opened**: the window is now open. * * **Closing**: the closing stage begins when the window manager's #closeWindow or the * window's {@link OO.ui.Window#close close} methods is used, and the window manager begins * to close the window. * * - the `opened` promise is resolved with `closing` promise and a `closing` event is emitted * - the #getHoldDelay method is called and the returned value is used to time a pause in execution before * the window's {@link OO.ui.Window#getHoldProcess getHoldProces} method is called on the * window and its result executed * - a `hold` progress notification is emitted from the `closing` promise * - the #getTeardownDelay() method is called and the returned value is used to time a pause in execution before * the window's {@link OO.ui.Window#getTeardownProcess getTeardownProcess} method is called on the * window and its result executed * - a `teardown` progress notification is emitted from the `closing` promise * - the `closing` promise is resolved. The window is now closed * * See the [OOjs UI documentation on MediaWiki][1] for more information. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Windows/Window_managers * * @class * @extends OO.ui.Element * @mixins OO.EventEmitter * * @constructor * @param {Object} [config] Configuration options * @cfg {OO.Factory} [factory] Window factory to use for automatic instantiation * Note that window classes that are instantiated with a factory must have * a {@link OO.ui.Dialog#static-name static name} property that specifies a symbolic name. * @cfg {boolean} [modal=true] Prevent interaction outside the dialog */ OO.ui.WindowManager = function OoUiWindowManager( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.WindowManager.parent.call( this, config ); // Mixin constructors OO.EventEmitter.call( this ); // Properties this.factory = config.factory; this.modal = config.modal === undefined || !!config.modal; this.windows = {}; this.opening = null; this.opened = null; this.closing = null; this.preparingToOpen = null; this.preparingToClose = null; this.currentWindow = null; this.globalEvents = false; this.$ariaHidden = null; this.onWindowResizeTimeout = null; this.onWindowResizeHandler = this.onWindowResize.bind( this ); this.afterWindowResizeHandler = this.afterWindowResize.bind( this ); // Initialization this.$element .addClass( 'oo-ui-windowManager' ) .toggleClass( 'oo-ui-windowManager-modal', this.modal ); }; /* Setup */ OO.inheritClass( OO.ui.WindowManager, OO.ui.Element ); OO.mixinClass( OO.ui.WindowManager, OO.EventEmitter ); /* Events */ /** * An 'opening' event is emitted when the window begins to be opened. * * @event opening * @param {OO.ui.Window} win Window that's being opened * @param {jQuery.Promise} opening An `opening` promise resolved with a value when the window is opened successfully. * When the `opening` promise is resolved, the first argument of the value is an 'opened' promise, the second argument * is the opening data. The `opening` promise emits `setup` and `ready` notifications when those processes are complete. * @param {Object} data Window opening data */ /** * A 'closing' event is emitted when the window begins to be closed. * * @event closing * @param {OO.ui.Window} win Window that's being closed * @param {jQuery.Promise} closing A `closing` promise is resolved with a value when the window * is closed successfully. The promise emits `hold` and `teardown` notifications when those * processes are complete. When the `closing` promise is resolved, the first argument of its value * is the closing data. * @param {Object} data Window closing data */ /** * A 'resize' event is emitted when a window is resized. * * @event resize * @param {OO.ui.Window} win Window that was resized */ /* Static Properties */ /** * Map of the symbolic name of each window size and its CSS properties. * * @static * @inheritable * @property {Object} */ OO.ui.WindowManager.static.sizes = { small: { width: 300 }, medium: { width: 500 }, large: { width: 700 }, larger: { width: 900 }, full: { // These can be non-numeric because they are never used in calculations width: '100%', height: '100%' } }; /** * Symbolic name of the default window size. * * The default size is used if the window's requested size is not recognized. * * @static * @inheritable * @property {string} */ OO.ui.WindowManager.static.defaultSize = 'medium'; /* Methods */ /** * Handle window resize events. * * @private * @param {jQuery.Event} e Window resize event */ OO.ui.WindowManager.prototype.onWindowResize = function () { clearTimeout( this.onWindowResizeTimeout ); this.onWindowResizeTimeout = setTimeout( this.afterWindowResizeHandler, 200 ); }; /** * Handle window resize events. * * @private * @param {jQuery.Event} e Window resize event */ OO.ui.WindowManager.prototype.afterWindowResize = function () { if ( this.currentWindow ) { this.updateWindowSize( this.currentWindow ); } }; /** * Check if window is opening. * * @return {boolean} Window is opening */ OO.ui.WindowManager.prototype.isOpening = function ( win ) { return win === this.currentWindow && !!this.opening && this.opening.state() === 'pending'; }; /** * Check if window is closing. * * @return {boolean} Window is closing */ OO.ui.WindowManager.prototype.isClosing = function ( win ) { return win === this.currentWindow && !!this.closing && this.closing.state() === 'pending'; }; /** * Check if window is opened. * * @return {boolean} Window is opened */ OO.ui.WindowManager.prototype.isOpened = function ( win ) { return win === this.currentWindow && !!this.opened && this.opened.state() === 'pending'; }; /** * Check if a window is being managed. * * @param {OO.ui.Window} win Window to check * @return {boolean} Window is being managed */ OO.ui.WindowManager.prototype.hasWindow = function ( win ) { var name; for ( name in this.windows ) { if ( this.windows[ name ] === win ) { return true; } } return false; }; /** * Get the number of milliseconds to wait after opening begins before executing the ‘setup’ process. * * @param {OO.ui.Window} win Window being opened * @param {Object} [data] Window opening data * @return {number} Milliseconds to wait */ OO.ui.WindowManager.prototype.getSetupDelay = function () { return 0; }; /** * Get the number of milliseconds to wait after setup has finished before executing the ‘ready’ process. * * @param {OO.ui.Window} win Window being opened * @param {Object} [data] Window opening data * @return {number} Milliseconds to wait */ OO.ui.WindowManager.prototype.getReadyDelay = function () { return 0; }; /** * Get the number of milliseconds to wait after closing has begun before executing the 'hold' process. * * @param {OO.ui.Window} win Window being closed * @param {Object} [data] Window closing data * @return {number} Milliseconds to wait */ OO.ui.WindowManager.prototype.getHoldDelay = function () { return 0; }; /** * Get the number of milliseconds to wait after the ‘hold’ process has finished before * executing the ‘teardown’ process. * * @param {OO.ui.Window} win Window being closed * @param {Object} [data] Window closing data * @return {number} Milliseconds to wait */ OO.ui.WindowManager.prototype.getTeardownDelay = function () { return this.modal ? 250 : 0; }; /** * Get a window by its symbolic name. * * If the window is not yet instantiated and its symbolic name is recognized by a factory, it will be * instantiated and added to the window manager automatically. Please see the [OOjs UI documentation on MediaWiki][3] * for more information about using factories. * [3]: https://www.mediawiki.org/wiki/OOjs_UI/Windows/Window_managers * * @param {string} name Symbolic name of the window * @return {jQuery.Promise} Promise resolved with matching window, or rejected with an OO.ui.Error * @throws {Error} An error is thrown if the symbolic name is not recognized by the factory. * @throws {Error} An error is thrown if the named window is not recognized as a managed window. */ OO.ui.WindowManager.prototype.getWindow = function ( name ) { var deferred = $.Deferred(), win = this.windows[ name ]; if ( !( win instanceof OO.ui.Window ) ) { if ( this.factory ) { if ( !this.factory.lookup( name ) ) { deferred.reject( new OO.ui.Error( 'Cannot auto-instantiate window: symbolic name is unrecognized by the factory' ) ); } else { win = this.factory.create( name ); this.addWindows( [ win ] ); deferred.resolve( win ); } } else { deferred.reject( new OO.ui.Error( 'Cannot get unmanaged window: symbolic name unrecognized as a managed window' ) ); } } else { deferred.resolve( win ); } return deferred.promise(); }; /** * Get current window. * * @return {OO.ui.Window|null} Currently opening/opened/closing window */ OO.ui.WindowManager.prototype.getCurrentWindow = function () { return this.currentWindow; }; /** * Open a window. * * @param {OO.ui.Window|string} win Window object or symbolic name of window to open * @param {Object} [data] Window opening data * @return {jQuery.Promise} An `opening` promise resolved when the window is done opening. * See {@link #event-opening 'opening' event} for more information about `opening` promises. * @fires opening */ OO.ui.WindowManager.prototype.openWindow = function ( win, data ) { var manager = this, opening = $.Deferred(); // Argument handling if ( typeof win === 'string' ) { return this.getWindow( win ).then( function ( win ) { return manager.openWindow( win, data ); } ); } // Error handling if ( !this.hasWindow( win ) ) { opening.reject( new OO.ui.Error( 'Cannot open window: window is not attached to manager' ) ); } else if ( this.preparingToOpen || this.opening || this.opened ) { opening.reject( new OO.ui.Error( 'Cannot open window: another window is opening or open' ) ); } // Window opening if ( opening.state() !== 'rejected' ) { // If a window is currently closing, wait for it to complete this.preparingToOpen = $.when( this.closing ); // Ensure handlers get called after preparingToOpen is set this.preparingToOpen.done( function () { if ( manager.modal ) { manager.toggleGlobalEvents( true ); manager.toggleAriaIsolation( true ); } manager.currentWindow = win; manager.opening = opening; manager.preparingToOpen = null; manager.emit( 'opening', win, opening, data ); setTimeout( function () { win.setup( data ).then( function () { manager.updateWindowSize( win ); manager.opening.notify( { state: 'setup' } ); setTimeout( function () { win.ready( data ).then( function () { manager.opening.notify( { state: 'ready' } ); manager.opening = null; manager.opened = $.Deferred(); opening.resolve( manager.opened.promise(), data ); } ); }, manager.getReadyDelay() ); } ); }, manager.getSetupDelay() ); } ); } return opening.promise(); }; /** * Close a window. * * @param {OO.ui.Window|string} win Window object or symbolic name of window to close * @param {Object} [data] Window closing data * @return {jQuery.Promise} A `closing` promise resolved when the window is done closing. * See {@link #event-closing 'closing' event} for more information about closing promises. * @throws {Error} An error is thrown if the window is not managed by the window manager. * @fires closing */ OO.ui.WindowManager.prototype.closeWindow = function ( win, data ) { var manager = this, closing = $.Deferred(), opened; // Argument handling if ( typeof win === 'string' ) { win = this.windows[ win ]; } else if ( !this.hasWindow( win ) ) { win = null; } // Error handling if ( !win ) { closing.reject( new OO.ui.Error( 'Cannot close window: window is not attached to manager' ) ); } else if ( win !== this.currentWindow ) { closing.reject( new OO.ui.Error( 'Cannot close window: window already closed with different data' ) ); } else if ( this.preparingToClose || this.closing ) { closing.reject( new OO.ui.Error( 'Cannot close window: window already closing with different data' ) ); } // Window closing if ( closing.state() !== 'rejected' ) { // If the window is currently opening, close it when it's done this.preparingToClose = $.when( this.opening ); // Ensure handlers get called after preparingToClose is set this.preparingToClose.done( function () { manager.closing = closing; manager.preparingToClose = null; manager.emit( 'closing', win, closing, data ); opened = manager.opened; manager.opened = null; opened.resolve( closing.promise(), data ); setTimeout( function () { win.hold( data ).then( function () { closing.notify( { state: 'hold' } ); setTimeout( function () { win.teardown( data ).then( function () { closing.notify( { state: 'teardown' } ); if ( manager.modal ) { manager.toggleGlobalEvents( false ); manager.toggleAriaIsolation( false ); } manager.closing = null; manager.currentWindow = null; closing.resolve( data ); } ); }, manager.getTeardownDelay() ); } ); }, manager.getHoldDelay() ); } ); } return closing.promise(); }; /** * Add windows to the window manager. * * Windows can be added by reference, symbolic name, or explicitly defined symbolic names. * See the [OOjs ui documentation on MediaWiki] [2] for examples. * [2]: https://www.mediawiki.org/wiki/OOjs_UI/Windows/Window_managers * * @param {Object.<string,OO.ui.Window>|OO.ui.Window[]} windows An array of window objects specified * by reference, symbolic name, or explicitly defined symbolic names. * @throws {Error} An error is thrown if a window is added by symbolic name, but has neither an * explicit nor a statically configured symbolic name. */ OO.ui.WindowManager.prototype.addWindows = function ( windows ) { var i, len, win, name, list; if ( Array.isArray( windows ) ) { // Convert to map of windows by looking up symbolic names from static configuration list = {}; for ( i = 0, len = windows.length; i < len; i++ ) { name = windows[ i ].constructor.static.name; if ( typeof name !== 'string' ) { throw new Error( 'Cannot add window' ); } list[ name ] = windows[ i ]; } } else if ( OO.isPlainObject( windows ) ) { list = windows; } // Add windows for ( name in list ) { win = list[ name ]; this.windows[ name ] = win.toggle( false ); this.$element.append( win.$element ); win.setManager( this ); } }; /** * Remove the specified windows from the windows manager. * * Windows will be closed before they are removed. If you wish to remove all windows, you may wish to use * the #clearWindows method instead. If you no longer need the window manager and want to ensure that it no * longer listens to events, use the #destroy method. * * @param {string[]} names Symbolic names of windows to remove * @return {jQuery.Promise} Promise resolved when window is closed and removed * @throws {Error} An error is thrown if the named windows are not managed by the window manager. */ OO.ui.WindowManager.prototype.removeWindows = function ( names ) { var i, len, win, name, cleanupWindow, manager = this, promises = [], cleanup = function ( name, win ) { delete manager.windows[ name ]; win.$element.detach(); }; for ( i = 0, len = names.length; i < len; i++ ) { name = names[ i ]; win = this.windows[ name ]; if ( !win ) { throw new Error( 'Cannot remove window' ); } cleanupWindow = cleanup.bind( null, name, win ); promises.push( this.closeWindow( name ).then( cleanupWindow, cleanupWindow ) ); } return $.when.apply( $, promises ); }; /** * Remove all windows from the window manager. * * Windows will be closed before they are removed. Note that the window manager, though not in use, will still * listen to events. If the window manager will not be used again, you may wish to use the #destroy method instead. * To remove just a subset of windows, use the #removeWindows method. * * @return {jQuery.Promise} Promise resolved when all windows are closed and removed */ OO.ui.WindowManager.prototype.clearWindows = function () { return this.removeWindows( Object.keys( this.windows ) ); }; /** * Set dialog size. In general, this method should not be called directly. * * Fullscreen mode will be used if the dialog is too wide to fit in the screen. * * @chainable */ OO.ui.WindowManager.prototype.updateWindowSize = function ( win ) { var isFullscreen; // Bypass for non-current, and thus invisible, windows if ( win !== this.currentWindow ) { return; } isFullscreen = win.getSize() === 'full'; this.$element.toggleClass( 'oo-ui-windowManager-fullscreen', isFullscreen ); this.$element.toggleClass( 'oo-ui-windowManager-floating', !isFullscreen ); win.setDimensions( win.getSizeProperties() ); this.emit( 'resize', win ); return this; }; /** * Bind or unbind global events for scrolling. * * @private * @param {boolean} [on] Bind global events * @chainable */ OO.ui.WindowManager.prototype.toggleGlobalEvents = function ( on ) { var scrollWidth, bodyMargin, $body = $( this.getElementDocument().body ), // We could have multiple window managers open so only modify // the body css at the bottom of the stack stackDepth = $body.data( 'windowManagerGlobalEvents' ) || 0 ; on = on === undefined ? !!this.globalEvents : !!on; if ( on ) { if ( !this.globalEvents ) { $( this.getElementWindow() ).on( { // Start listening for top-level window dimension changes 'orientationchange resize': this.onWindowResizeHandler } ); if ( stackDepth === 0 ) { scrollWidth = window.innerWidth - document.documentElement.clientWidth; bodyMargin = parseFloat( $body.css( 'margin-right' ) ) || 0; $body.css( { overflow: 'hidden', 'margin-right': bodyMargin + scrollWidth } ); } stackDepth++; this.globalEvents = true; } } else if ( this.globalEvents ) { $( this.getElementWindow() ).off( { // Stop listening for top-level window dimension changes 'orientationchange resize': this.onWindowResizeHandler } ); stackDepth--; if ( stackDepth === 0 ) { $body.css( { overflow: '', 'margin-right': '' } ); } this.globalEvents = false; } $body.data( 'windowManagerGlobalEvents', stackDepth ); return this; }; /** * Toggle screen reader visibility of content other than the window manager. * * @private * @param {boolean} [isolate] Make only the window manager visible to screen readers * @chainable */ OO.ui.WindowManager.prototype.toggleAriaIsolation = function ( isolate ) { isolate = isolate === undefined ? !this.$ariaHidden : !!isolate; if ( isolate ) { if ( !this.$ariaHidden ) { // Hide everything other than the window manager from screen readers this.$ariaHidden = $( 'body' ) .children() .not( this.$element.parentsUntil( 'body' ).last() ) .attr( 'aria-hidden', '' ); } } else if ( this.$ariaHidden ) { // Restore screen reader visibility this.$ariaHidden.removeAttr( 'aria-hidden' ); this.$ariaHidden = null; } return this; }; /** * Destroy the window manager. * * Destroying the window manager ensures that it will no longer listen to events. If you would like to * continue using the window manager, but wish to remove all windows from it, use the #clearWindows method * instead. */ OO.ui.WindowManager.prototype.destroy = function () { this.toggleGlobalEvents( false ); this.toggleAriaIsolation( false ); this.clearWindows(); this.$element.remove(); }; /** * Errors contain a required message (either a string or jQuery selection) that is used to describe what went wrong * in a {@link OO.ui.Process process}. The error's #recoverable and #warning configurations are used to customize the * appearance and functionality of the error interface. * * The basic error interface contains a formatted error message as well as two buttons: 'Dismiss' and 'Try again' (i.e., the error * is 'recoverable' by default). If the error is not recoverable, the 'Try again' button will not be rendered and the widget * that initiated the failed process will be disabled. * * If the error is a warning, the error interface will include a 'Dismiss' and a 'Continue' button, which will try the * process again. * * For an example of error interfaces, please see the [OOjs UI documentation on MediaWiki][1]. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Windows/Process_Dialogs#Processes_and_errors * * @class * * @constructor * @param {string|jQuery} message Description of error * @param {Object} [config] Configuration options * @cfg {boolean} [recoverable=true] Error is recoverable. * By default, errors are recoverable, and users can try the process again. * @cfg {boolean} [warning=false] Error is a warning. * If the error is a warning, the error interface will include a * 'Dismiss' and a 'Continue' button. It is the responsibility of the developer to ensure that the warning * is not triggered a second time if the user chooses to continue. */ OO.ui.Error = function OoUiError( message, config ) { // Allow passing positional parameters inside the config object if ( OO.isPlainObject( message ) && config === undefined ) { config = message; message = config.message; } // Configuration initialization config = config || {}; // Properties this.message = message instanceof jQuery ? message : String( message ); this.recoverable = config.recoverable === undefined || !!config.recoverable; this.warning = !!config.warning; }; /* Setup */ OO.initClass( OO.ui.Error ); /* Methods */ /** * Check if the error is recoverable. * * If the error is recoverable, users are able to try the process again. * * @return {boolean} Error is recoverable */ OO.ui.Error.prototype.isRecoverable = function () { return this.recoverable; }; /** * Check if the error is a warning. * * If the error is a warning, the error interface will include a 'Dismiss' and a 'Continue' button. * * @return {boolean} Error is warning */ OO.ui.Error.prototype.isWarning = function () { return this.warning; }; /** * Get error message as DOM nodes. * * @return {jQuery} Error message in DOM nodes */ OO.ui.Error.prototype.getMessage = function () { return this.message instanceof jQuery ? this.message.clone() : $( '<div>' ).text( this.message ).contents(); }; /** * Get the error message text. * * @return {string} Error message */ OO.ui.Error.prototype.getMessageText = function () { return this.message instanceof jQuery ? this.message.text() : this.message; }; /** * Wraps an HTML snippet for use with configuration values which default * to strings. This bypasses the default html-escaping done to string * values. * * @class * * @constructor * @param {string} [content] HTML content */ OO.ui.HtmlSnippet = function OoUiHtmlSnippet( content ) { // Properties this.content = content; }; /* Setup */ OO.initClass( OO.ui.HtmlSnippet ); /* Methods */ /** * Render into HTML. * * @return {string} Unchanged HTML snippet. */ OO.ui.HtmlSnippet.prototype.toString = function () { return this.content; }; /** * A Process is a list of steps that are called in sequence. The step can be a number, a jQuery promise, * or a function: * * - **number**: the process will wait for the specified number of milliseconds before proceeding. * - **promise**: the process will continue to the next step when the promise is successfully resolved * or stop if the promise is rejected. * - **function**: the process will execute the function. The process will stop if the function returns * either a boolean `false` or a promise that is rejected; if the function returns a number, the process * will wait for that number of milliseconds before proceeding. * * If the process fails, an {@link OO.ui.Error error} is generated. Depending on how the error is * configured, users can dismiss the error and try the process again, or not. If a process is stopped, * its remaining steps will not be performed. * * @class * * @constructor * @param {number|jQuery.Promise|Function} step Number of miliseconds to wait before proceeding, promise * that must be resolved before proceeding, or a function to execute. See #createStep for more information. see #createStep for more information * @param {Object} [context=null] Execution context of the function. The context is ignored if the step is * a number or promise. * @return {Object} Step object, with `callback` and `context` properties */ OO.ui.Process = function ( step, context ) { // Properties this.steps = []; // Initialization if ( step !== undefined ) { this.next( step, context ); } }; /* Setup */ OO.initClass( OO.ui.Process ); /* Methods */ /** * Start the process. * * @return {jQuery.Promise} Promise that is resolved when all steps have successfully completed. * If any of the steps return a promise that is rejected or a boolean false, this promise is rejected * and any remaining steps are not performed. */ OO.ui.Process.prototype.execute = function () { var i, len, promise; /** * Continue execution. * * @ignore * @param {Array} step A function and the context it should be called in * @return {Function} Function that continues the process */ function proceed( step ) { return function () { // Execute step in the correct context var deferred, result = step.callback.call( step.context ); if ( result === false ) { // Use rejected promise for boolean false results return $.Deferred().reject( [] ).promise(); } if ( typeof result === 'number' ) { if ( result < 0 ) { throw new Error( 'Cannot go back in time: flux capacitor is out of service' ); } // Use a delayed promise for numbers, expecting them to be in milliseconds deferred = $.Deferred(); setTimeout( deferred.resolve, result ); return deferred.promise(); } if ( result instanceof OO.ui.Error ) { // Use rejected promise for error return $.Deferred().reject( [ result ] ).promise(); } if ( Array.isArray( result ) && result.length && result[ 0 ] instanceof OO.ui.Error ) { // Use rejected promise for list of errors return $.Deferred().reject( result ).promise(); } // Duck-type the object to see if it can produce a promise if ( result && $.isFunction( result.promise ) ) { // Use a promise generated from the result return result.promise(); } // Use resolved promise for other results return $.Deferred().resolve().promise(); }; } if ( this.steps.length ) { // Generate a chain reaction of promises promise = proceed( this.steps[ 0 ] )(); for ( i = 1, len = this.steps.length; i < len; i++ ) { promise = promise.then( proceed( this.steps[ i ] ) ); } } else { promise = $.Deferred().resolve().promise(); } return promise; }; /** * Create a process step. * * @private * @param {number|jQuery.Promise|Function} step * * - Number of milliseconds to wait before proceeding * - Promise that must be resolved before proceeding * - Function to execute * - If the function returns a boolean false the process will stop * - If the function returns a promise, the process will continue to the next * step when the promise is resolved or stop if the promise is rejected * - If the function returns a number, the process will wait for that number of * milliseconds before proceeding * @param {Object} [context=null] Execution context of the function. The context is * ignored if the step is a number or promise. * @return {Object} Step object, with `callback` and `context` properties */ OO.ui.Process.prototype.createStep = function ( step, context ) { if ( typeof step === 'number' || $.isFunction( step.promise ) ) { return { callback: function () { return step; }, context: null }; } if ( $.isFunction( step ) ) { return { callback: step, context: context }; } throw new Error( 'Cannot create process step: number, promise or function expected' ); }; /** * Add step to the beginning of the process. * * @inheritdoc #createStep * @return {OO.ui.Process} this * @chainable */ OO.ui.Process.prototype.first = function ( step, context ) { this.steps.unshift( this.createStep( step, context ) ); return this; }; /** * Add step to the end of the process. * * @inheritdoc #createStep * @return {OO.ui.Process} this * @chainable */ OO.ui.Process.prototype.next = function ( step, context ) { this.steps.push( this.createStep( step, context ) ); return this; }; /** * A ToolFactory creates tools on demand. All tools ({@link OO.ui.Tool Tools}, {@link OO.ui.PopupTool PopupTools}, * and {@link OO.ui.ToolGroupTool ToolGroupTools}) must be registered with a tool factory. Tools are * registered by their symbolic name. See {@link OO.ui.Toolbar toolbars} for an example. * * For more information about toolbars in general, please see the [OOjs UI documentation on MediaWiki][1]. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Toolbars * * @class * @extends OO.Factory * @constructor */ OO.ui.ToolFactory = function OoUiToolFactory() { // Parent constructor OO.ui.ToolFactory.parent.call( this ); }; /* Setup */ OO.inheritClass( OO.ui.ToolFactory, OO.Factory ); /* Methods */ /** * Get tools from the factory * * @param {Array} include Included tools * @param {Array} exclude Excluded tools * @param {Array} promote Promoted tools * @param {Array} demote Demoted tools * @return {string[]} List of tools */ OO.ui.ToolFactory.prototype.getTools = function ( include, exclude, promote, demote ) { var i, len, included, promoted, demoted, auto = [], used = {}; // Collect included and not excluded tools included = OO.simpleArrayDifference( this.extract( include ), this.extract( exclude ) ); // Promotion promoted = this.extract( promote, used ); demoted = this.extract( demote, used ); // Auto for ( i = 0, len = included.length; i < len; i++ ) { if ( !used[ included[ i ] ] ) { auto.push( included[ i ] ); } } return promoted.concat( auto ).concat( demoted ); }; /** * Get a flat list of names from a list of names or groups. * * Tools can be specified in the following ways: * * - A specific tool: `{ name: 'tool-name' }` or `'tool-name'` * - All tools in a group: `{ group: 'group-name' }` * - All tools: `'*'` * * @private * @param {Array|string} collection List of tools * @param {Object} [used] Object with names that should be skipped as properties; extracted * names will be added as properties * @return {string[]} List of extracted names */ OO.ui.ToolFactory.prototype.extract = function ( collection, used ) { var i, len, item, name, tool, names = []; if ( collection === '*' ) { for ( name in this.registry ) { tool = this.registry[ name ]; if ( // Only add tools by group name when auto-add is enabled tool.static.autoAddToCatchall && // Exclude already used tools ( !used || !used[ name ] ) ) { names.push( name ); if ( used ) { used[ name ] = true; } } } } else if ( Array.isArray( collection ) ) { for ( i = 0, len = collection.length; i < len; i++ ) { item = collection[ i ]; // Allow plain strings as shorthand for named tools if ( typeof item === 'string' ) { item = { name: item }; } if ( OO.isPlainObject( item ) ) { if ( item.group ) { for ( name in this.registry ) { tool = this.registry[ name ]; if ( // Include tools with matching group tool.static.group === item.group && // Only add tools by group name when auto-add is enabled tool.static.autoAddToGroup && // Exclude already used tools ( !used || !used[ name ] ) ) { names.push( name ); if ( used ) { used[ name ] = true; } } } // Include tools with matching name and exclude already used tools } else if ( item.name && ( !used || !used[ item.name ] ) ) { names.push( item.name ); if ( used ) { used[ item.name ] = true; } } } } } return names; }; /** * ToolGroupFactories create {@link OO.ui.ToolGroup toolgroups} on demand. The toolgroup classes must * specify a symbolic name and be registered with the factory. The following classes are registered by * default: * * - {@link OO.ui.BarToolGroup BarToolGroups} (‘bar’) * - {@link OO.ui.MenuToolGroup MenuToolGroups} (‘menu’) * - {@link OO.ui.ListToolGroup ListToolGroups} (‘list’) * * See {@link OO.ui.Toolbar toolbars} for an example. * * For more information about toolbars in general, please see the [OOjs UI documentation on MediaWiki][1]. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Toolbars * @class * @extends OO.Factory * @constructor */ OO.ui.ToolGroupFactory = function OoUiToolGroupFactory() { var i, l, defaultClasses; // Parent constructor OO.Factory.call( this ); defaultClasses = this.constructor.static.getDefaultClasses(); // Register default toolgroups for ( i = 0, l = defaultClasses.length; i < l; i++ ) { this.register( defaultClasses[ i ] ); } }; /* Setup */ OO.inheritClass( OO.ui.ToolGroupFactory, OO.Factory ); /* Static Methods */ /** * Get a default set of classes to be registered on construction. * * @return {Function[]} Default classes */ OO.ui.ToolGroupFactory.static.getDefaultClasses = function () { return [ OO.ui.BarToolGroup, OO.ui.ListToolGroup, OO.ui.MenuToolGroup ]; }; /** * Theme logic. * * @abstract * @class * * @constructor * @param {Object} [config] Configuration options */ OO.ui.Theme = function OoUiTheme( config ) { // Configuration initialization config = config || {}; }; /* Setup */ OO.initClass( OO.ui.Theme ); /* Methods */ /** * Get a list of classes to be applied to a widget. * * The 'on' and 'off' lists combined MUST contain keys for all classes the theme adds or removes, * otherwise state transitions will not work properly. * * @param {OO.ui.Element} element Element for which to get classes * @return {Object.<string,string[]>} Categorized class names with `on` and `off` lists */ OO.ui.Theme.prototype.getElementClasses = function () { return { on: [], off: [] }; }; /** * Update CSS classes provided by the theme. * * For elements with theme logic hooks, this should be called any time there's a state change. * * @param {OO.ui.Element} element Element for which to update classes * @return {Object.<string,string[]>} Categorized class names with `on` and `off` lists */ OO.ui.Theme.prototype.updateElementClasses = function ( element ) { var $elements = $( [] ), classes = this.getElementClasses( element ); if ( element.$icon ) { $elements = $elements.add( element.$icon ); } if ( element.$indicator ) { $elements = $elements.add( element.$indicator ); } $elements .removeClass( classes.off.join( ' ' ) ) .addClass( classes.on.join( ' ' ) ); }; /** * The TabIndexedElement class is an attribute mixin used to add additional functionality to an * element created by another class. The mixin provides a ‘tabIndex’ property, which specifies the * order in which users will navigate through the focusable elements via the "tab" key. * * @example * // TabIndexedElement is mixed into the ButtonWidget class * // to provide a tabIndex property. * var button1 = new OO.ui.ButtonWidget( { * label: 'fourth', * tabIndex: 4 * } ); * var button2 = new OO.ui.ButtonWidget( { * label: 'second', * tabIndex: 2 * } ); * var button3 = new OO.ui.ButtonWidget( { * label: 'third', * tabIndex: 3 * } ); * var button4 = new OO.ui.ButtonWidget( { * label: 'first', * tabIndex: 1 * } ); * $( 'body' ).append( button1.$element, button2.$element, button3.$element, button4.$element ); * * @abstract * @class * * @constructor * @param {Object} [config] Configuration options * @cfg {jQuery} [$tabIndexed] The element that should use the tabindex functionality. By default, * the functionality is applied to the element created by the class ($element). If a different element is specified, the tabindex * functionality will be applied to it instead. * @cfg {number|null} [tabIndex=0] Number that specifies the element’s position in the tab-navigation * order (e.g., 1 for the first focusable element). Use 0 to use the default navigation order; use -1 * to remove the element from the tab-navigation flow. */ OO.ui.mixin.TabIndexedElement = function OoUiMixinTabIndexedElement( config ) { // Configuration initialization config = $.extend( { tabIndex: 0 }, config ); // Properties this.$tabIndexed = null; this.tabIndex = null; // Events this.connect( this, { disable: 'onTabIndexedElementDisable' } ); // Initialization this.setTabIndex( config.tabIndex ); this.setTabIndexedElement( config.$tabIndexed || this.$element ); }; /* Setup */ OO.initClass( OO.ui.mixin.TabIndexedElement ); /* Methods */ /** * Set the element that should use the tabindex functionality. * * This method is used to retarget a tabindex mixin so that its functionality applies * to the specified element. If an element is currently using the functionality, the mixin’s * effect on that element is removed before the new element is set up. * * @param {jQuery} $tabIndexed Element that should use the tabindex functionality * @chainable */ OO.ui.mixin.TabIndexedElement.prototype.setTabIndexedElement = function ( $tabIndexed ) { var tabIndex = this.tabIndex; // Remove attributes from old $tabIndexed this.setTabIndex( null ); // Force update of new $tabIndexed this.$tabIndexed = $tabIndexed; this.tabIndex = tabIndex; return this.updateTabIndex(); }; /** * Set the value of the tabindex. * * @param {number|null} tabIndex Tabindex value, or `null` for no tabindex * @chainable */ OO.ui.mixin.TabIndexedElement.prototype.setTabIndex = function ( tabIndex ) { tabIndex = typeof tabIndex === 'number' ? tabIndex : null; if ( this.tabIndex !== tabIndex ) { this.tabIndex = tabIndex; this.updateTabIndex(); } return this; }; /** * Update the `tabindex` attribute, in case of changes to tab index or * disabled state. * * @private * @chainable */ OO.ui.mixin.TabIndexedElement.prototype.updateTabIndex = function () { if ( this.$tabIndexed ) { if ( this.tabIndex !== null ) { // Do not index over disabled elements this.$tabIndexed.attr( { tabindex: this.isDisabled() ? -1 : this.tabIndex, // Support: ChromeVox and NVDA // These do not seem to inherit aria-disabled from parent elements 'aria-disabled': this.isDisabled().toString() } ); } else { this.$tabIndexed.removeAttr( 'tabindex aria-disabled' ); } } return this; }; /** * Handle disable events. * * @private * @param {boolean} disabled Element is disabled */ OO.ui.mixin.TabIndexedElement.prototype.onTabIndexedElementDisable = function () { this.updateTabIndex(); }; /** * Get the value of the tabindex. * * @return {number|null} Tabindex value */ OO.ui.mixin.TabIndexedElement.prototype.getTabIndex = function () { return this.tabIndex; }; /** * ButtonElement is often mixed into other classes to generate a button, which is a clickable * interface element that can be configured with access keys for accessibility. * See the [OOjs UI documentation on MediaWiki] [1] for examples. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Buttons_and_Switches#Buttons * @abstract * @class * * @constructor * @param {Object} [config] Configuration options * @cfg {jQuery} [$button] The button element created by the class. * If this configuration is omitted, the button element will use a generated `<a>`. * @cfg {boolean} [framed=true] Render the button with a frame */ OO.ui.mixin.ButtonElement = function OoUiMixinButtonElement( config ) { // Configuration initialization config = config || {}; // Properties this.$button = null; this.framed = null; this.active = false; this.onMouseUpHandler = this.onMouseUp.bind( this ); this.onMouseDownHandler = this.onMouseDown.bind( this ); this.onKeyDownHandler = this.onKeyDown.bind( this ); this.onKeyUpHandler = this.onKeyUp.bind( this ); this.onClickHandler = this.onClick.bind( this ); this.onKeyPressHandler = this.onKeyPress.bind( this ); // Initialization this.$element.addClass( 'oo-ui-buttonElement' ); this.toggleFramed( config.framed === undefined || config.framed ); this.setButtonElement( config.$button || $( '<a>' ) ); }; /* Setup */ OO.initClass( OO.ui.mixin.ButtonElement ); /* Static Properties */ /** * Cancel mouse down events. * * This property is usually set to `true` to prevent the focus from changing when the button is clicked. * Classes such as {@link OO.ui.mixin.DraggableElement DraggableElement} and {@link OO.ui.ButtonOptionWidget ButtonOptionWidget} * use a value of `false` so that dragging behavior is possible and mousedown events can be handled by a * parent widget. * * @static * @inheritable * @property {boolean} */ OO.ui.mixin.ButtonElement.static.cancelButtonMouseDownEvents = true; /* Events */ /** * A 'click' event is emitted when the button element is clicked. * * @event click */ /* Methods */ /** * Set the button element. * * This method is used to retarget a button mixin so that its functionality applies to * the specified button element instead of the one created by the class. If a button element * is already set, the method will remove the mixin’s effect on that element. * * @param {jQuery} $button Element to use as button */ OO.ui.mixin.ButtonElement.prototype.setButtonElement = function ( $button ) { if ( this.$button ) { this.$button .removeClass( 'oo-ui-buttonElement-button' ) .removeAttr( 'role accesskey' ) .off( { mousedown: this.onMouseDownHandler, keydown: this.onKeyDownHandler, click: this.onClickHandler, keypress: this.onKeyPressHandler } ); } this.$button = $button .addClass( 'oo-ui-buttonElement-button' ) .attr( { role: 'button' } ) .on( { mousedown: this.onMouseDownHandler, keydown: this.onKeyDownHandler, click: this.onClickHandler, keypress: this.onKeyPressHandler } ); }; /** * Handles mouse down events. * * @protected * @param {jQuery.Event} e Mouse down event */ OO.ui.mixin.ButtonElement.prototype.onMouseDown = function ( e ) { if ( this.isDisabled() || e.which !== 1 ) { return; } this.$element.addClass( 'oo-ui-buttonElement-pressed' ); // Run the mouseup handler no matter where the mouse is when the button is let go, so we can // reliably remove the pressed class OO.ui.addCaptureEventListener( this.getElementDocument(), 'mouseup', this.onMouseUpHandler ); // Prevent change of focus unless specifically configured otherwise if ( this.constructor.static.cancelButtonMouseDownEvents ) { return false; } }; /** * Handles mouse up events. * * @protected * @param {jQuery.Event} e Mouse up event */ OO.ui.mixin.ButtonElement.prototype.onMouseUp = function ( e ) { if ( this.isDisabled() || e.which !== 1 ) { return; } this.$element.removeClass( 'oo-ui-buttonElement-pressed' ); // Stop listening for mouseup, since we only needed this once OO.ui.removeCaptureEventListener( this.getElementDocument(), 'mouseup', this.onMouseUpHandler ); }; /** * Handles mouse click events. * * @protected * @param {jQuery.Event} e Mouse click event * @fires click */ OO.ui.mixin.ButtonElement.prototype.onClick = function ( e ) { if ( !this.isDisabled() && e.which === 1 ) { if ( this.emit( 'click' ) ) { return false; } } }; /** * Handles key down events. * * @protected * @param {jQuery.Event} e Key down event */ OO.ui.mixin.ButtonElement.prototype.onKeyDown = function ( e ) { if ( this.isDisabled() || ( e.which !== OO.ui.Keys.SPACE && e.which !== OO.ui.Keys.ENTER ) ) { return; } this.$element.addClass( 'oo-ui-buttonElement-pressed' ); // Run the keyup handler no matter where the key is when the button is let go, so we can // reliably remove the pressed class OO.ui.addCaptureEventListener( this.getElementDocument(), 'keyup', this.onKeyUpHandler ); }; /** * Handles key up events. * * @protected * @param {jQuery.Event} e Key up event */ OO.ui.mixin.ButtonElement.prototype.onKeyUp = function ( e ) { if ( this.isDisabled() || ( e.which !== OO.ui.Keys.SPACE && e.which !== OO.ui.Keys.ENTER ) ) { return; } this.$element.removeClass( 'oo-ui-buttonElement-pressed' ); // Stop listening for keyup, since we only needed this once OO.ui.removeCaptureEventListener( this.getElementDocument(), 'keyup', this.onKeyUpHandler ); }; /** * Handles key press events. * * @protected * @param {jQuery.Event} e Key press event * @fires click */ OO.ui.mixin.ButtonElement.prototype.onKeyPress = function ( e ) { if ( !this.isDisabled() && ( e.which === OO.ui.Keys.SPACE || e.which === OO.ui.Keys.ENTER ) ) { if ( this.emit( 'click' ) ) { return false; } } }; /** * Check if button has a frame. * * @return {boolean} Button is framed */ OO.ui.mixin.ButtonElement.prototype.isFramed = function () { return this.framed; }; /** * Render the button with or without a frame. Omit the `framed` parameter to toggle the button frame on and off. * * @param {boolean} [framed] Make button framed, omit to toggle * @chainable */ OO.ui.mixin.ButtonElement.prototype.toggleFramed = function ( framed ) { framed = framed === undefined ? !this.framed : !!framed; if ( framed !== this.framed ) { this.framed = framed; this.$element .toggleClass( 'oo-ui-buttonElement-frameless', !framed ) .toggleClass( 'oo-ui-buttonElement-framed', framed ); this.updateThemeClasses(); } return this; }; /** * Set the button's active state. * * The active state occurs when a {@link OO.ui.ButtonOptionWidget ButtonOptionWidget} or * a {@link OO.ui.ToggleButtonWidget ToggleButtonWidget} is pressed. This method does nothing * for other button types. * * @param {boolean} value Make button active * @chainable */ OO.ui.mixin.ButtonElement.prototype.setActive = function ( value ) { this.active = !!value; this.$element.toggleClass( 'oo-ui-buttonElement-active', this.active ); return this; }; /** * Check if the button is active * * @return {boolean} The button is active */ OO.ui.mixin.ButtonElement.prototype.isActive = function () { return this.active; }; /** * Any OOjs UI widget that contains other widgets (such as {@link OO.ui.ButtonWidget buttons} or * {@link OO.ui.OptionWidget options}) mixes in GroupElement. Adding, removing, and clearing * items from the group is done through the interface the class provides. * For more information, please see the [OOjs UI documentation on MediaWiki] [1]. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Elements/Groups * * @abstract * @class * * @constructor * @param {Object} [config] Configuration options * @cfg {jQuery} [$group] The container element created by the class. If this configuration * is omitted, the group element will use a generated `<div>`. */ OO.ui.mixin.GroupElement = function OoUiMixinGroupElement( config ) { // Configuration initialization config = config || {}; // Properties this.$group = null; this.items = []; this.aggregateItemEvents = {}; // Initialization this.setGroupElement( config.$group || $( '<div>' ) ); }; /* Methods */ /** * Set the group element. * * If an element is already set, items will be moved to the new element. * * @param {jQuery} $group Element to use as group */ OO.ui.mixin.GroupElement.prototype.setGroupElement = function ( $group ) { var i, len; this.$group = $group; for ( i = 0, len = this.items.length; i < len; i++ ) { this.$group.append( this.items[ i ].$element ); } }; /** * Check if a group contains no items. * * @return {boolean} Group is empty */ OO.ui.mixin.GroupElement.prototype.isEmpty = function () { return !this.items.length; }; /** * Get all items in the group. * * The method returns an array of item references (e.g., [button1, button2, button3]) and is useful * when synchronizing groups of items, or whenever the references are required (e.g., when removing items * from a group). * * @return {OO.ui.Element[]} An array of items. */ OO.ui.mixin.GroupElement.prototype.getItems = function () { return this.items.slice( 0 ); }; /** * Get an item by its data. * * Only the first item with matching data will be returned. To return all matching items, * use the #getItemsFromData method. * * @param {Object} data Item data to search for * @return {OO.ui.Element|null} Item with equivalent data, `null` if none exists */ OO.ui.mixin.GroupElement.prototype.getItemFromData = function ( data ) { var i, len, item, hash = OO.getHash( data ); for ( i = 0, len = this.items.length; i < len; i++ ) { item = this.items[ i ]; if ( hash === OO.getHash( item.getData() ) ) { return item; } } return null; }; /** * Get items by their data. * * All items with matching data will be returned. To return only the first match, use the #getItemFromData method instead. * * @param {Object} data Item data to search for * @return {OO.ui.Element[]} Items with equivalent data */ OO.ui.mixin.GroupElement.prototype.getItemsFromData = function ( data ) { var i, len, item, hash = OO.getHash( data ), items = []; for ( i = 0, len = this.items.length; i < len; i++ ) { item = this.items[ i ]; if ( hash === OO.getHash( item.getData() ) ) { items.push( item ); } } return items; }; /** * Aggregate the events emitted by the group. * * When events are aggregated, the group will listen to all contained items for the event, * and then emit the event under a new name. The new event will contain an additional leading * parameter containing the item that emitted the original event. Other arguments emitted from * the original event are passed through. * * @param {Object.<string,string|null>} events An object keyed by the name of the event that should be * aggregated (e.g., ‘click’) and the value of the new name to use (e.g., ‘groupClick’). * A `null` value will remove aggregated events. * @throws {Error} An error is thrown if aggregation already exists. */ OO.ui.mixin.GroupElement.prototype.aggregate = function ( events ) { var i, len, item, add, remove, itemEvent, groupEvent; for ( itemEvent in events ) { groupEvent = events[ itemEvent ]; // Remove existing aggregated event if ( Object.prototype.hasOwnProperty.call( this.aggregateItemEvents, itemEvent ) ) { // Don't allow duplicate aggregations if ( groupEvent ) { throw new Error( 'Duplicate item event aggregation for ' + itemEvent ); } // Remove event aggregation from existing items for ( i = 0, len = this.items.length; i < len; i++ ) { item = this.items[ i ]; if ( item.connect && item.disconnect ) { remove = {}; remove[ itemEvent ] = [ 'emit', this.aggregateItemEvents[ itemEvent ], item ]; item.disconnect( this, remove ); } } // Prevent future items from aggregating event delete this.aggregateItemEvents[ itemEvent ]; } // Add new aggregate event if ( groupEvent ) { // Make future items aggregate event this.aggregateItemEvents[ itemEvent ] = groupEvent; // Add event aggregation to existing items for ( i = 0, len = this.items.length; i < len; i++ ) { item = this.items[ i ]; if ( item.connect && item.disconnect ) { add = {}; add[ itemEvent ] = [ 'emit', groupEvent, item ]; item.connect( this, add ); } } } } }; /** * Add items to the group. * * Items will be added to the end of the group array unless the optional `index` parameter specifies * a different insertion point. Adding an existing item will move it to the end of the array or the point specified by the `index`. * * @param {OO.ui.Element[]} items An array of items to add to the group * @param {number} [index] Index of the insertion point * @chainable */ OO.ui.mixin.GroupElement.prototype.addItems = function ( items, index ) { var i, len, item, event, events, currentIndex, itemElements = []; for ( i = 0, len = items.length; i < len; i++ ) { item = items[ i ]; // Check if item exists then remove it first, effectively "moving" it currentIndex = this.items.indexOf( item ); if ( currentIndex >= 0 ) { this.removeItems( [ item ] ); // Adjust index to compensate for removal if ( currentIndex < index ) { index--; } } // Add the item if ( item.connect && item.disconnect && !$.isEmptyObject( this.aggregateItemEvents ) ) { events = {}; for ( event in this.aggregateItemEvents ) { events[ event ] = [ 'emit', this.aggregateItemEvents[ event ], item ]; } item.connect( this, events ); } item.setElementGroup( this ); itemElements.push( item.$element.get( 0 ) ); } if ( index === undefined || index < 0 || index >= this.items.length ) { this.$group.append( itemElements ); this.items.push.apply( this.items, items ); } else if ( index === 0 ) { this.$group.prepend( itemElements ); this.items.unshift.apply( this.items, items ); } else { this.items[ index ].$element.before( itemElements ); this.items.splice.apply( this.items, [ index, 0 ].concat( items ) ); } return this; }; /** * Remove the specified items from a group. * * Removed items are detached (not removed) from the DOM so that they may be reused. * To remove all items from a group, you may wish to use the #clearItems method instead. * * @param {OO.ui.Element[]} items An array of items to remove * @chainable */ OO.ui.mixin.GroupElement.prototype.removeItems = function ( items ) { var i, len, item, index, remove, itemEvent; // Remove specific items for ( i = 0, len = items.length; i < len; i++ ) { item = items[ i ]; index = this.items.indexOf( item ); if ( index !== -1 ) { if ( item.connect && item.disconnect && !$.isEmptyObject( this.aggregateItemEvents ) ) { remove = {}; if ( Object.prototype.hasOwnProperty.call( this.aggregateItemEvents, itemEvent ) ) { remove[ itemEvent ] = [ 'emit', this.aggregateItemEvents[ itemEvent ], item ]; } item.disconnect( this, remove ); } item.setElementGroup( null ); this.items.splice( index, 1 ); item.$element.detach(); } } return this; }; /** * Clear all items from the group. * * Cleared items are detached from the DOM, not removed, so that they may be reused. * To remove only a subset of items from a group, use the #removeItems method. * * @chainable */ OO.ui.mixin.GroupElement.prototype.clearItems = function () { var i, len, item, remove, itemEvent; // Remove all items for ( i = 0, len = this.items.length; i < len; i++ ) { item = this.items[ i ]; if ( item.connect && item.disconnect && !$.isEmptyObject( this.aggregateItemEvents ) ) { remove = {}; if ( Object.prototype.hasOwnProperty.call( this.aggregateItemEvents, itemEvent ) ) { remove[ itemEvent ] = [ 'emit', this.aggregateItemEvents[ itemEvent ], item ]; } item.disconnect( this, remove ); } item.setElementGroup( null ); item.$element.detach(); } this.items = []; return this; }; /** * DraggableElement is a mixin class used to create elements that can be clicked * and dragged by a mouse to a new position within a group. This class must be used * in conjunction with OO.ui.mixin.DraggableGroupElement, which provides a container for * the draggable elements. * * @abstract * @class * * @constructor */ OO.ui.mixin.DraggableElement = function OoUiMixinDraggableElement() { // Properties this.index = null; // Initialize and events this.$element .attr( 'draggable', true ) .addClass( 'oo-ui-draggableElement' ) .on( { dragstart: this.onDragStart.bind( this ), dragover: this.onDragOver.bind( this ), dragend: this.onDragEnd.bind( this ), drop: this.onDrop.bind( this ) } ); }; OO.initClass( OO.ui.mixin.DraggableElement ); /* Events */ /** * @event dragstart * * A dragstart event is emitted when the user clicks and begins dragging an item. * @param {OO.ui.mixin.DraggableElement} item The item the user has clicked and is dragging with the mouse. */ /** * @event dragend * A dragend event is emitted when the user drags an item and releases the mouse, * thus terminating the drag operation. */ /** * @event drop * A drop event is emitted when the user drags an item and then releases the mouse button * over a valid target. */ /* Static Properties */ /** * @inheritdoc OO.ui.mixin.ButtonElement */ OO.ui.mixin.DraggableElement.static.cancelButtonMouseDownEvents = false; /* Methods */ /** * Respond to dragstart event. * * @private * @param {jQuery.Event} event jQuery event * @fires dragstart */ OO.ui.mixin.DraggableElement.prototype.onDragStart = function ( e ) { var dataTransfer = e.originalEvent.dataTransfer; // Define drop effect dataTransfer.dropEffect = 'none'; dataTransfer.effectAllowed = 'move'; // Support: Firefox // We must set up a dataTransfer data property or Firefox seems to // ignore the fact the element is draggable. try { dataTransfer.setData( 'application-x/OOjs-UI-draggable', this.getIndex() ); } catch ( err ) { // The above is only for Firefox. Move on if it fails. } // Add dragging class this.$element.addClass( 'oo-ui-draggableElement-dragging' ); // Emit event this.emit( 'dragstart', this ); return true; }; /** * Respond to dragend event. * * @private * @fires dragend */ OO.ui.mixin.DraggableElement.prototype.onDragEnd = function () { this.$element.removeClass( 'oo-ui-draggableElement-dragging' ); this.emit( 'dragend' ); }; /** * Handle drop event. * * @private * @param {jQuery.Event} event jQuery event * @fires drop */ OO.ui.mixin.DraggableElement.prototype.onDrop = function ( e ) { e.preventDefault(); this.emit( 'drop', e ); }; /** * In order for drag/drop to work, the dragover event must * return false and stop propogation. * * @private */ OO.ui.mixin.DraggableElement.prototype.onDragOver = function ( e ) { e.preventDefault(); }; /** * Set item index. * Store it in the DOM so we can access from the widget drag event * * @private * @param {number} Item index */ OO.ui.mixin.DraggableElement.prototype.setIndex = function ( index ) { if ( this.index !== index ) { this.index = index; this.$element.data( 'index', index ); } }; /** * Get item index * * @private * @return {number} Item index */ OO.ui.mixin.DraggableElement.prototype.getIndex = function () { return this.index; }; /** * DraggableGroupElement is a mixin class used to create a group element to * contain draggable elements, which are items that can be clicked and dragged by a mouse. * The class is used with OO.ui.mixin.DraggableElement. * * @abstract * @class * @mixins OO.ui.mixin.GroupElement * * @constructor * @param {Object} [config] Configuration options * @cfg {string} [orientation] Item orientation: 'horizontal' or 'vertical'. The orientation * should match the layout of the items. Items displayed in a single row * or in several rows should use horizontal orientation. The vertical orientation should only be * used when the items are displayed in a single column. Defaults to 'vertical' */ OO.ui.mixin.DraggableGroupElement = function OoUiMixinDraggableGroupElement( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.mixin.GroupElement.call( this, config ); // Properties this.orientation = config.orientation || 'vertical'; this.dragItem = null; this.itemDragOver = null; this.itemKeys = {}; this.sideInsertion = ''; // Events this.aggregate( { dragstart: 'itemDragStart', dragend: 'itemDragEnd', drop: 'itemDrop' } ); this.connect( this, { itemDragStart: 'onItemDragStart', itemDrop: 'onItemDrop', itemDragEnd: 'onItemDragEnd' } ); this.$element.on( { dragover: this.onDragOver.bind( this ), dragleave: this.onDragLeave.bind( this ) } ); // Initialize if ( Array.isArray( config.items ) ) { this.addItems( config.items ); } this.$placeholder = $( '<div>' ) .addClass( 'oo-ui-draggableGroupElement-placeholder' ); this.$element .addClass( 'oo-ui-draggableGroupElement' ) .append( this.$status ) .toggleClass( 'oo-ui-draggableGroupElement-horizontal', this.orientation === 'horizontal' ) .prepend( this.$placeholder ); }; /* Setup */ OO.mixinClass( OO.ui.mixin.DraggableGroupElement, OO.ui.mixin.GroupElement ); /* Events */ /** * A 'reorder' event is emitted when the order of items in the group changes. * * @event reorder * @param {OO.ui.mixin.DraggableElement} item Reordered item * @param {number} [newIndex] New index for the item */ /* Methods */ /** * Respond to item drag start event * * @private * @param {OO.ui.mixin.DraggableElement} item Dragged item */ OO.ui.mixin.DraggableGroupElement.prototype.onItemDragStart = function ( item ) { var i, len; // Map the index of each object for ( i = 0, len = this.items.length; i < len; i++ ) { this.items[ i ].setIndex( i ); } if ( this.orientation === 'horizontal' ) { // Set the height of the indicator this.$placeholder.css( { height: item.$element.outerHeight(), width: 2 } ); } else { // Set the width of the indicator this.$placeholder.css( { height: 2, width: item.$element.outerWidth() } ); } this.setDragItem( item ); }; /** * Respond to item drag end event * * @private */ OO.ui.mixin.DraggableGroupElement.prototype.onItemDragEnd = function () { this.unsetDragItem(); return false; }; /** * Handle drop event and switch the order of the items accordingly * * @private * @param {OO.ui.mixin.DraggableElement} item Dropped item * @fires reorder */ OO.ui.mixin.DraggableGroupElement.prototype.onItemDrop = function ( item ) { var toIndex = item.getIndex(); // Check if the dropped item is from the current group // TODO: Figure out a way to configure a list of legally droppable // elements even if they are not yet in the list if ( this.getDragItem() ) { // If the insertion point is 'after', the insertion index // is shifted to the right (or to the left in RTL, hence 'after') if ( this.sideInsertion === 'after' ) { toIndex++; } // Emit change event this.emit( 'reorder', this.getDragItem(), toIndex ); } this.unsetDragItem(); // Return false to prevent propogation return false; }; /** * Handle dragleave event. * * @private */ OO.ui.mixin.DraggableGroupElement.prototype.onDragLeave = function () { // This means the item was dragged outside the widget this.$placeholder .css( 'left', 0 ) .addClass( 'oo-ui-element-hidden' ); }; /** * Respond to dragover event * * @private * @param {jQuery.Event} event Event details */ OO.ui.mixin.DraggableGroupElement.prototype.onDragOver = function ( e ) { var dragOverObj, $optionWidget, itemOffset, itemMidpoint, itemBoundingRect, itemSize, cssOutput, dragPosition, itemIndex, itemPosition, clientX = e.originalEvent.clientX, clientY = e.originalEvent.clientY; // Get the OptionWidget item we are dragging over dragOverObj = this.getElementDocument().elementFromPoint( clientX, clientY ); $optionWidget = $( dragOverObj ).closest( '.oo-ui-draggableElement' ); if ( $optionWidget[ 0 ] ) { itemOffset = $optionWidget.offset(); itemBoundingRect = $optionWidget[ 0 ].getBoundingClientRect(); itemPosition = $optionWidget.position(); itemIndex = $optionWidget.data( 'index' ); } if ( itemOffset && this.isDragging() && itemIndex !== this.getDragItem().getIndex() ) { if ( this.orientation === 'horizontal' ) { // Calculate where the mouse is relative to the item width itemSize = itemBoundingRect.width; itemMidpoint = itemBoundingRect.left + itemSize / 2; dragPosition = clientX; // Which side of the item we hover over will dictate // where the placeholder will appear, on the left or // on the right cssOutput = { left: dragPosition < itemMidpoint ? itemPosition.left : itemPosition.left + itemSize, top: itemPosition.top }; } else { // Calculate where the mouse is relative to the item height itemSize = itemBoundingRect.height; itemMidpoint = itemBoundingRect.top + itemSize / 2; dragPosition = clientY; // Which side of the item we hover over will dictate // where the placeholder will appear, on the top or // on the bottom cssOutput = { top: dragPosition < itemMidpoint ? itemPosition.top : itemPosition.top + itemSize, left: itemPosition.left }; } // Store whether we are before or after an item to rearrange // For horizontal layout, we need to account for RTL, as this is flipped if ( this.orientation === 'horizontal' && this.$element.css( 'direction' ) === 'rtl' ) { this.sideInsertion = dragPosition < itemMidpoint ? 'after' : 'before'; } else { this.sideInsertion = dragPosition < itemMidpoint ? 'before' : 'after'; } // Add drop indicator between objects this.$placeholder .css( cssOutput ) .removeClass( 'oo-ui-element-hidden' ); } else { // This means the item was dragged outside the widget this.$placeholder .css( 'left', 0 ) .addClass( 'oo-ui-element-hidden' ); } // Prevent default e.preventDefault(); }; /** * Set a dragged item * * @param {OO.ui.mixin.DraggableElement} item Dragged item */ OO.ui.mixin.DraggableGroupElement.prototype.setDragItem = function ( item ) { this.dragItem = item; }; /** * Unset the current dragged item */ OO.ui.mixin.DraggableGroupElement.prototype.unsetDragItem = function () { this.dragItem = null; this.itemDragOver = null; this.$placeholder.addClass( 'oo-ui-element-hidden' ); this.sideInsertion = ''; }; /** * Get the item that is currently being dragged. * * @return {OO.ui.mixin.DraggableElement|null} The currently dragged item, or `null` if no item is being dragged */ OO.ui.mixin.DraggableGroupElement.prototype.getDragItem = function () { return this.dragItem; }; /** * Check if an item in the group is currently being dragged. * * @return {Boolean} Item is being dragged */ OO.ui.mixin.DraggableGroupElement.prototype.isDragging = function () { return this.getDragItem() !== null; }; /** * IconElement is often mixed into other classes to generate an icon. * Icons are graphics, about the size of normal text. They are used to aid the user * in locating a control or to convey information in a space-efficient way. See the * [OOjs UI documentation on MediaWiki] [1] for a list of icons * included in the library. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Icons,_Indicators,_and_Labels#Icons * * @abstract * @class * * @constructor * @param {Object} [config] Configuration options * @cfg {jQuery} [$icon] The icon element created by the class. If this configuration is omitted, * the icon element will use a generated `<span>`. To use a different HTML tag, or to specify that * the icon element be set to an existing icon instead of the one generated by this class, set a * value using a jQuery selection. For example: * * // Use a <div> tag instead of a <span> * $icon: $("<div>") * // Use an existing icon element instead of the one generated by the class * $icon: this.$element * // Use an icon element from a child widget * $icon: this.childwidget.$element * @cfg {Object|string} [icon=''] The symbolic name of the icon (e.g., ‘remove’ or ‘menu’), or a map of * symbolic names. A map is used for i18n purposes and contains a `default` icon * name and additional names keyed by language code. The `default` name is used when no icon is keyed * by the user's language. * * Example of an i18n map: * * { default: 'bold-a', en: 'bold-b', de: 'bold-f' } * See the [OOjs UI documentation on MediaWiki] [2] for a list of icons included in the library. * [2]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Icons,_Indicators,_and_Labels#Icons * @cfg {string|Function} [iconTitle] A text string used as the icon title, or a function that returns title * text. The icon title is displayed when users move the mouse over the icon. */ OO.ui.mixin.IconElement = function OoUiMixinIconElement( config ) { // Configuration initialization config = config || {}; // Properties this.$icon = null; this.icon = null; this.iconTitle = null; // Initialization this.setIcon( config.icon || this.constructor.static.icon ); this.setIconTitle( config.iconTitle || this.constructor.static.iconTitle ); this.setIconElement( config.$icon || $( '<span>' ) ); }; /* Setup */ OO.initClass( OO.ui.mixin.IconElement ); /* Static Properties */ /** * The symbolic name of the icon (e.g., ‘remove’ or ‘menu’), or a map of symbolic names. A map is used * for i18n purposes and contains a `default` icon name and additional names keyed by * language code. The `default` name is used when no icon is keyed by the user's language. * * Example of an i18n map: * * { default: 'bold-a', en: 'bold-b', de: 'bold-f' } * * Note: the static property will be overridden if the #icon configuration is used. * * @static * @inheritable * @property {Object|string} */ OO.ui.mixin.IconElement.static.icon = null; /** * The icon title, displayed when users move the mouse over the icon. The value can be text, a * function that returns title text, or `null` for no title. * * The static property will be overridden if the #iconTitle configuration is used. * * @static * @inheritable * @property {string|Function|null} */ OO.ui.mixin.IconElement.static.iconTitle = null; /* Methods */ /** * Set the icon element. This method is used to retarget an icon mixin so that its functionality * applies to the specified icon element instead of the one created by the class. If an icon * element is already set, the mixin’s effect on that element is removed. Generated CSS classes * and mixin methods will no longer affect the element. * * @param {jQuery} $icon Element to use as icon */ OO.ui.mixin.IconElement.prototype.setIconElement = function ( $icon ) { if ( this.$icon ) { this.$icon .removeClass( 'oo-ui-iconElement-icon oo-ui-icon-' + this.icon ) .removeAttr( 'title' ); } this.$icon = $icon .addClass( 'oo-ui-iconElement-icon' ) .toggleClass( 'oo-ui-icon-' + this.icon, !!this.icon ); if ( this.iconTitle !== null ) { this.$icon.attr( 'title', this.iconTitle ); } this.updateThemeClasses(); }; /** * Set icon by symbolic name (e.g., ‘remove’ or ‘menu’). Use `null` to remove an icon. * The icon parameter can also be set to a map of icon names. See the #icon config setting * for an example. * * @param {Object|string|null} icon A symbolic icon name, a {@link #icon map of icon names} keyed * by language code, or `null` to remove the icon. * @chainable */ OO.ui.mixin.IconElement.prototype.setIcon = function ( icon ) { icon = OO.isPlainObject( icon ) ? OO.ui.getLocalValue( icon, null, 'default' ) : icon; icon = typeof icon === 'string' && icon.trim().length ? icon.trim() : null; if ( this.icon !== icon ) { if ( this.$icon ) { if ( this.icon !== null ) { this.$icon.removeClass( 'oo-ui-icon-' + this.icon ); } if ( icon !== null ) { this.$icon.addClass( 'oo-ui-icon-' + icon ); } } this.icon = icon; } this.$element.toggleClass( 'oo-ui-iconElement', !!this.icon ); this.updateThemeClasses(); return this; }; /** * Set the icon title. Use `null` to remove the title. * * @param {string|Function|null} iconTitle A text string used as the icon title, * a function that returns title text, or `null` for no title. * @chainable */ OO.ui.mixin.IconElement.prototype.setIconTitle = function ( iconTitle ) { iconTitle = typeof iconTitle === 'function' || ( typeof iconTitle === 'string' && iconTitle.length ) ? OO.ui.resolveMsg( iconTitle ) : null; if ( this.iconTitle !== iconTitle ) { this.iconTitle = iconTitle; if ( this.$icon ) { if ( this.iconTitle !== null ) { this.$icon.attr( 'title', iconTitle ); } else { this.$icon.removeAttr( 'title' ); } } } return this; }; /** * Get the symbolic name of the icon. * * @return {string} Icon name */ OO.ui.mixin.IconElement.prototype.getIcon = function () { return this.icon; }; /** * Get the icon title. The title text is displayed when a user moves the mouse over the icon. * * @return {string} Icon title text */ OO.ui.mixin.IconElement.prototype.getIconTitle = function () { return this.iconTitle; }; /** * IndicatorElement is often mixed into other classes to generate an indicator. * Indicators are small graphics that are generally used in two ways: * * - To draw attention to the status of an item. For example, an indicator might be * used to show that an item in a list has errors that need to be resolved. * - To clarify the function of a control that acts in an exceptional way (a button * that opens a menu instead of performing an action directly, for example). * * For a list of indicators included in the library, please see the * [OOjs UI documentation on MediaWiki] [1]. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Icons,_Indicators,_and_Labels#Indicators * * @abstract * @class * * @constructor * @param {Object} [config] Configuration options * @cfg {jQuery} [$indicator] The indicator element created by the class. If this * configuration is omitted, the indicator element will use a generated `<span>`. * @cfg {string} [indicator] Symbolic name of the indicator (e.g., ‘alert’ or ‘down’). * See the [OOjs UI documentation on MediaWiki][2] for a list of indicators included * in the library. * [2]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Icons,_Indicators,_and_Labels#Indicators * @cfg {string|Function} [indicatorTitle] A text string used as the indicator title, * or a function that returns title text. The indicator title is displayed when users move * the mouse over the indicator. */ OO.ui.mixin.IndicatorElement = function OoUiMixinIndicatorElement( config ) { // Configuration initialization config = config || {}; // Properties this.$indicator = null; this.indicator = null; this.indicatorTitle = null; // Initialization this.setIndicator( config.indicator || this.constructor.static.indicator ); this.setIndicatorTitle( config.indicatorTitle || this.constructor.static.indicatorTitle ); this.setIndicatorElement( config.$indicator || $( '<span>' ) ); }; /* Setup */ OO.initClass( OO.ui.mixin.IndicatorElement ); /* Static Properties */ /** * Symbolic name of the indicator (e.g., ‘alert’ or ‘down’). * The static property will be overridden if the #indicator configuration is used. * * @static * @inheritable * @property {string|null} */ OO.ui.mixin.IndicatorElement.static.indicator = null; /** * A text string used as the indicator title, a function that returns title text, or `null` * for no title. The static property will be overridden if the #indicatorTitle configuration is used. * * @static * @inheritable * @property {string|Function|null} */ OO.ui.mixin.IndicatorElement.static.indicatorTitle = null; /* Methods */ /** * Set the indicator element. * * If an element is already set, it will be cleaned up before setting up the new element. * * @param {jQuery} $indicator Element to use as indicator */ OO.ui.mixin.IndicatorElement.prototype.setIndicatorElement = function ( $indicator ) { if ( this.$indicator ) { this.$indicator .removeClass( 'oo-ui-indicatorElement-indicator oo-ui-indicator-' + this.indicator ) .removeAttr( 'title' ); } this.$indicator = $indicator .addClass( 'oo-ui-indicatorElement-indicator' ) .toggleClass( 'oo-ui-indicator-' + this.indicator, !!this.indicator ); if ( this.indicatorTitle !== null ) { this.$indicator.attr( 'title', this.indicatorTitle ); } this.updateThemeClasses(); }; /** * Set the indicator by its symbolic name: ‘alert’, ‘down’, ‘next’, ‘previous’, ‘required’, ‘up’. Use `null` to remove the indicator. * * @param {string|null} indicator Symbolic name of indicator, or `null` for no indicator * @chainable */ OO.ui.mixin.IndicatorElement.prototype.setIndicator = function ( indicator ) { indicator = typeof indicator === 'string' && indicator.length ? indicator.trim() : null; if ( this.indicator !== indicator ) { if ( this.$indicator ) { if ( this.indicator !== null ) { this.$indicator.removeClass( 'oo-ui-indicator-' + this.indicator ); } if ( indicator !== null ) { this.$indicator.addClass( 'oo-ui-indicator-' + indicator ); } } this.indicator = indicator; } this.$element.toggleClass( 'oo-ui-indicatorElement', !!this.indicator ); this.updateThemeClasses(); return this; }; /** * Set the indicator title. * * The title is displayed when a user moves the mouse over the indicator. * * @param {string|Function|null} indicator Indicator title text, a function that returns text, or * `null` for no indicator title * @chainable */ OO.ui.mixin.IndicatorElement.prototype.setIndicatorTitle = function ( indicatorTitle ) { indicatorTitle = typeof indicatorTitle === 'function' || ( typeof indicatorTitle === 'string' && indicatorTitle.length ) ? OO.ui.resolveMsg( indicatorTitle ) : null; if ( this.indicatorTitle !== indicatorTitle ) { this.indicatorTitle = indicatorTitle; if ( this.$indicator ) { if ( this.indicatorTitle !== null ) { this.$indicator.attr( 'title', indicatorTitle ); } else { this.$indicator.removeAttr( 'title' ); } } } return this; }; /** * Get the symbolic name of the indicator (e.g., ‘alert’ or ‘down’). * * @return {string} Symbolic name of indicator */ OO.ui.mixin.IndicatorElement.prototype.getIndicator = function () { return this.indicator; }; /** * Get the indicator title. * * The title is displayed when a user moves the mouse over the indicator. * * @return {string} Indicator title text */ OO.ui.mixin.IndicatorElement.prototype.getIndicatorTitle = function () { return this.indicatorTitle; }; /** * LabelElement is often mixed into other classes to generate a label, which * helps identify the function of an interface element. * See the [OOjs UI documentation on MediaWiki] [1] for more information. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Icons,_Indicators,_and_Labels#Labels * * @abstract * @class * * @constructor * @param {Object} [config] Configuration options * @cfg {jQuery} [$label] The label element created by the class. If this * configuration is omitted, the label element will use a generated `<span>`. * @cfg {jQuery|string|Function|OO.ui.HtmlSnippet} [label] The label text. The label can be specified * as a plaintext string, a jQuery selection of elements, or a function that will produce a string * in the future. See the [OOjs UI documentation on MediaWiki] [2] for examples. * [2]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Icons,_Indicators,_and_Labels#Labels * @cfg {boolean} [autoFitLabel=true] Fit the label to the width of the parent element. * The label will be truncated to fit if necessary. */ OO.ui.mixin.LabelElement = function OoUiMixinLabelElement( config ) { // Configuration initialization config = config || {}; // Properties this.$label = null; this.label = null; this.autoFitLabel = config.autoFitLabel === undefined || !!config.autoFitLabel; // Initialization this.setLabel( config.label || this.constructor.static.label ); this.setLabelElement( config.$label || $( '<span>' ) ); }; /* Setup */ OO.initClass( OO.ui.mixin.LabelElement ); /* Events */ /** * @event labelChange * @param {string} value */ /* Static Properties */ /** * The label text. The label can be specified as a plaintext string, a function that will * produce a string in the future, or `null` for no label. The static value will * be overridden if a label is specified with the #label config option. * * @static * @inheritable * @property {string|Function|null} */ OO.ui.mixin.LabelElement.static.label = null; /* Methods */ /** * Set the label element. * * If an element is already set, it will be cleaned up before setting up the new element. * * @param {jQuery} $label Element to use as label */ OO.ui.mixin.LabelElement.prototype.setLabelElement = function ( $label ) { if ( this.$label ) { this.$label.removeClass( 'oo-ui-labelElement-label' ).empty(); } this.$label = $label.addClass( 'oo-ui-labelElement-label' ); this.setLabelContent( this.label ); }; /** * Set the label. * * An empty string will result in the label being hidden. A string containing only whitespace will * be converted to a single `&nbsp;`. * * @param {jQuery|string|OO.ui.HtmlSnippet|Function|null} label Label nodes; text; a function that returns nodes or * text; or null for no label * @chainable */ OO.ui.mixin.LabelElement.prototype.setLabel = function ( label ) { label = typeof label === 'function' ? OO.ui.resolveMsg( label ) : label; label = ( ( typeof label === 'string' && label.length ) || label instanceof jQuery || label instanceof OO.ui.HtmlSnippet ) ? label : null; this.$element.toggleClass( 'oo-ui-labelElement', !!label ); if ( this.label !== label ) { if ( this.$label ) { this.setLabelContent( label ); } this.label = label; this.emit( 'labelChange' ); } return this; }; /** * Get the label. * * @return {jQuery|string|Function|null} Label nodes; text; a function that returns nodes or * text; or null for no label */ OO.ui.mixin.LabelElement.prototype.getLabel = function () { return this.label; }; /** * Fit the label. * * @chainable */ OO.ui.mixin.LabelElement.prototype.fitLabel = function () { if ( this.$label && this.$label.autoEllipsis && this.autoFitLabel ) { this.$label.autoEllipsis( { hasSpan: false, tooltip: true } ); } return this; }; /** * Set the content of the label. * * Do not call this method until after the label element has been set by #setLabelElement. * * @private * @param {jQuery|string|Function|null} label Label nodes; text; a function that returns nodes or * text; or null for no label */ OO.ui.mixin.LabelElement.prototype.setLabelContent = function ( label ) { if ( typeof label === 'string' ) { if ( label.match( /^\s*$/ ) ) { // Convert whitespace only string to a single non-breaking space this.$label.html( '&nbsp;' ); } else { this.$label.text( label ); } } else if ( label instanceof OO.ui.HtmlSnippet ) { this.$label.html( label.toString() ); } else if ( label instanceof jQuery ) { this.$label.empty().append( label ); } else { this.$label.empty(); } }; /** * LookupElement is a mixin that creates a {@link OO.ui.FloatingMenuSelectWidget menu} of suggested values for * a {@link OO.ui.TextInputWidget text input widget}. Suggested values are based on the characters the user types * into the text input field and, in general, the menu is only displayed when the user types. If a suggested value is chosen * from the lookup menu, that value becomes the value of the input field. * * Note that a new menu of suggested items is displayed when a value is chosen from the lookup menu. If this is * not the desired behavior, disable lookup menus with the #setLookupsDisabled method, then set the value, then * re-enable lookups. * * See the [OOjs UI demos][1] for an example. * * [1]: https://tools.wmflabs.org/oojs-ui/oojs-ui/demos/index.html#widgets-apex-vector-ltr * * @class * @abstract * * @constructor * @param {Object} [config] Configuration options * @cfg {jQuery} [$overlay] Overlay for the lookup menu; defaults to relative positioning * @cfg {jQuery} [$container=this.$element] The container element. The lookup menu is rendered beneath the specified element. * @cfg {boolean} [allowSuggestionsWhenEmpty=false] Request and display a lookup menu when the text input is empty. * By default, the lookup menu is not generated and displayed until the user begins to type. * @cfg {boolean} [highlightFirst=true] Whether the first lookup result should be highlighted (so, that the user can * take it over into the input with simply pressing return) automatically or not. */ OO.ui.mixin.LookupElement = function OoUiMixinLookupElement( config ) { // Configuration initialization config = $.extend( { highlightFirst: true }, config ); // Properties this.$overlay = config.$overlay || this.$element; this.lookupMenu = new OO.ui.FloatingMenuSelectWidget( { widget: this, input: this, $container: config.$container || this.$element } ); this.allowSuggestionsWhenEmpty = config.allowSuggestionsWhenEmpty || false; this.lookupCache = {}; this.lookupQuery = null; this.lookupRequest = null; this.lookupsDisabled = false; this.lookupInputFocused = false; this.lookupHighlightFirstItem = config.highlightFirst; // Events this.$input.on( { focus: this.onLookupInputFocus.bind( this ), blur: this.onLookupInputBlur.bind( this ), mousedown: this.onLookupInputMouseDown.bind( this ) } ); this.connect( this, { change: 'onLookupInputChange' } ); this.lookupMenu.connect( this, { toggle: 'onLookupMenuToggle', choose: 'onLookupMenuItemChoose' } ); // Initialization this.$element.addClass( 'oo-ui-lookupElement' ); this.lookupMenu.$element.addClass( 'oo-ui-lookupElement-menu' ); this.$overlay.append( this.lookupMenu.$element ); }; /* Methods */ /** * Handle input focus event. * * @protected * @param {jQuery.Event} e Input focus event */ OO.ui.mixin.LookupElement.prototype.onLookupInputFocus = function () { this.lookupInputFocused = true; this.populateLookupMenu(); }; /** * Handle input blur event. * * @protected * @param {jQuery.Event} e Input blur event */ OO.ui.mixin.LookupElement.prototype.onLookupInputBlur = function () { this.closeLookupMenu(); this.lookupInputFocused = false; }; /** * Handle input mouse down event. * * @protected * @param {jQuery.Event} e Input mouse down event */ OO.ui.mixin.LookupElement.prototype.onLookupInputMouseDown = function () { // Only open the menu if the input was already focused. // This way we allow the user to open the menu again after closing it with Esc // by clicking in the input. Opening (and populating) the menu when initially // clicking into the input is handled by the focus handler. if ( this.lookupInputFocused && !this.lookupMenu.isVisible() ) { this.populateLookupMenu(); } }; /** * Handle input change event. * * @protected * @param {string} value New input value */ OO.ui.mixin.LookupElement.prototype.onLookupInputChange = function () { if ( this.lookupInputFocused ) { this.populateLookupMenu(); } }; /** * Handle the lookup menu being shown/hidden. * * @protected * @param {boolean} visible Whether the lookup menu is now visible. */ OO.ui.mixin.LookupElement.prototype.onLookupMenuToggle = function ( visible ) { if ( !visible ) { // When the menu is hidden, abort any active request and clear the menu. // This has to be done here in addition to closeLookupMenu(), because // MenuSelectWidget will close itself when the user presses Esc. this.abortLookupRequest(); this.lookupMenu.clearItems(); } }; /** * Handle menu item 'choose' event, updating the text input value to the value of the clicked item. * * @protected * @param {OO.ui.MenuOptionWidget} item Selected item */ OO.ui.mixin.LookupElement.prototype.onLookupMenuItemChoose = function ( item ) { this.setValue( item.getData() ); }; /** * Get lookup menu. * * @private * @return {OO.ui.FloatingMenuSelectWidget} */ OO.ui.mixin.LookupElement.prototype.getLookupMenu = function () { return this.lookupMenu; }; /** * Disable or re-enable lookups. * * When lookups are disabled, calls to #populateLookupMenu will be ignored. * * @param {boolean} disabled Disable lookups */ OO.ui.mixin.LookupElement.prototype.setLookupsDisabled = function ( disabled ) { this.lookupsDisabled = !!disabled; }; /** * Open the menu. If there are no entries in the menu, this does nothing. * * @private * @chainable */ OO.ui.mixin.LookupElement.prototype.openLookupMenu = function () { if ( !this.lookupMenu.isEmpty() ) { this.lookupMenu.toggle( true ); } return this; }; /** * Close the menu, empty it, and abort any pending request. * * @private * @chainable */ OO.ui.mixin.LookupElement.prototype.closeLookupMenu = function () { this.lookupMenu.toggle( false ); this.abortLookupRequest(); this.lookupMenu.clearItems(); return this; }; /** * Request menu items based on the input's current value, and when they arrive, * populate the menu with these items and show the menu. * * If lookups have been disabled with #setLookupsDisabled, this function does nothing. * * @private * @chainable */ OO.ui.mixin.LookupElement.prototype.populateLookupMenu = function () { var widget = this, value = this.getValue(); if ( this.lookupsDisabled || this.isReadOnly() ) { return; } // If the input is empty, clear the menu, unless suggestions when empty are allowed. if ( !this.allowSuggestionsWhenEmpty && value === '' ) { this.closeLookupMenu(); // Skip population if there is already a request pending for the current value } else if ( value !== this.lookupQuery ) { this.getLookupMenuItems() .done( function ( items ) { widget.lookupMenu.clearItems(); if ( items.length ) { widget.lookupMenu .addItems( items ) .toggle( true ); widget.initializeLookupMenuSelection(); } else { widget.lookupMenu.toggle( false ); } } ) .fail( function () { widget.lookupMenu.clearItems(); } ); } return this; }; /** * Highlight the first selectable item in the menu, if configured. * * @private * @chainable */ OO.ui.mixin.LookupElement.prototype.initializeLookupMenuSelection = function () { if ( this.lookupHighlightFirstItem && !this.lookupMenu.getSelectedItem() ) { this.lookupMenu.highlightItem( this.lookupMenu.getFirstSelectableItem() ); } }; /** * Get lookup menu items for the current query. * * @private * @return {jQuery.Promise} Promise object which will be passed menu items as the first argument of * the done event. If the request was aborted to make way for a subsequent request, this promise * will not be rejected: it will remain pending forever. */ OO.ui.mixin.LookupElement.prototype.getLookupMenuItems = function () { var widget = this, value = this.getValue(), deferred = $.Deferred(), ourRequest; this.abortLookupRequest(); if ( Object.prototype.hasOwnProperty.call( this.lookupCache, value ) ) { deferred.resolve( this.getLookupMenuOptionsFromData( this.lookupCache[ value ] ) ); } else { this.pushPending(); this.lookupQuery = value; ourRequest = this.lookupRequest = this.getLookupRequest(); ourRequest .always( function () { // We need to pop pending even if this is an old request, otherwise // the widget will remain pending forever. // TODO: this assumes that an aborted request will fail or succeed soon after // being aborted, or at least eventually. It would be nice if we could popPending() // at abort time, but only if we knew that we hadn't already called popPending() // for that request. widget.popPending(); } ) .done( function ( response ) { // If this is an old request (and aborting it somehow caused it to still succeed), // ignore its success completely if ( ourRequest === widget.lookupRequest ) { widget.lookupQuery = null; widget.lookupRequest = null; widget.lookupCache[ value ] = widget.getLookupCacheDataFromResponse( response ); deferred.resolve( widget.getLookupMenuOptionsFromData( widget.lookupCache[ value ] ) ); } } ) .fail( function () { // If this is an old request (or a request failing because it's being aborted), // ignore its failure completely if ( ourRequest === widget.lookupRequest ) { widget.lookupQuery = null; widget.lookupRequest = null; deferred.reject(); } } ); } return deferred.promise(); }; /** * Abort the currently pending lookup request, if any. * * @private */ OO.ui.mixin.LookupElement.prototype.abortLookupRequest = function () { var oldRequest = this.lookupRequest; if ( oldRequest ) { // First unset this.lookupRequest to the fail handler will notice // that the request is no longer current this.lookupRequest = null; this.lookupQuery = null; oldRequest.abort(); } }; /** * Get a new request object of the current lookup query value. * * @protected * @abstract * @return {jQuery.Promise} jQuery AJAX object, or promise object with an .abort() method */ OO.ui.mixin.LookupElement.prototype.getLookupRequest = function () { // Stub, implemented in subclass return null; }; /** * Pre-process data returned by the request from #getLookupRequest. * * The return value of this function will be cached, and any further queries for the given value * will use the cache rather than doing API requests. * * @protected * @abstract * @param {Mixed} response Response from server * @return {Mixed} Cached result data */ OO.ui.mixin.LookupElement.prototype.getLookupCacheDataFromResponse = function () { // Stub, implemented in subclass return []; }; /** * Get a list of menu option widgets from the (possibly cached) data returned by * #getLookupCacheDataFromResponse. * * @protected * @abstract * @param {Mixed} data Cached result data, usually an array * @return {OO.ui.MenuOptionWidget[]} Menu items */ OO.ui.mixin.LookupElement.prototype.getLookupMenuOptionsFromData = function () { // Stub, implemented in subclass return []; }; /** * Set the read-only state of the widget. * * This will also disable/enable the lookups functionality. * * @param {boolean} readOnly Make input read-only * @chainable */ OO.ui.mixin.LookupElement.prototype.setReadOnly = function ( readOnly ) { // Parent method // Note: Calling #setReadOnly this way assumes this is mixed into an OO.ui.TextInputWidget OO.ui.TextInputWidget.prototype.setReadOnly.call( this, readOnly ); // During construction, #setReadOnly is called before the OO.ui.mixin.LookupElement constructor if ( this.isReadOnly() && this.lookupMenu ) { this.closeLookupMenu(); } return this; }; /** * PopupElement is mixed into other classes to generate a {@link OO.ui.PopupWidget popup widget}. * A popup is a container for content. It is overlaid and positioned absolutely. By default, each * popup has an anchor, which is an arrow-like protrusion that points toward the popup’s origin. * See {@link OO.ui.PopupWidget PopupWidget} for an example. * * @abstract * @class * * @constructor * @param {Object} [config] Configuration options * @cfg {Object} [popup] Configuration to pass to popup * @cfg {boolean} [popup.autoClose=true] Popup auto-closes when it loses focus */ OO.ui.mixin.PopupElement = function OoUiMixinPopupElement( config ) { // Configuration initialization config = config || {}; // Properties this.popup = new OO.ui.PopupWidget( $.extend( { autoClose: true }, config.popup, { $autoCloseIgnore: this.$element } ) ); }; /* Methods */ /** * Get popup. * * @return {OO.ui.PopupWidget} Popup widget */ OO.ui.mixin.PopupElement.prototype.getPopup = function () { return this.popup; }; /** * The FlaggedElement class is an attribute mixin, meaning that it is used to add * additional functionality to an element created by another class. The class provides * a ‘flags’ property assigned the name (or an array of names) of styling flags, * which are used to customize the look and feel of a widget to better describe its * importance and functionality. * * The library currently contains the following styling flags for general use: * * - **progressive**: Progressive styling is applied to convey that the widget will move the user forward in a process. * - **destructive**: Destructive styling is applied to convey that the widget will remove something. * - **constructive**: Constructive styling is applied to convey that the widget will create something. * * The flags affect the appearance of the buttons: * * @example * // FlaggedElement is mixed into ButtonWidget to provide styling flags * var button1 = new OO.ui.ButtonWidget( { * label: 'Constructive', * flags: 'constructive' * } ); * var button2 = new OO.ui.ButtonWidget( { * label: 'Destructive', * flags: 'destructive' * } ); * var button3 = new OO.ui.ButtonWidget( { * label: 'Progressive', * flags: 'progressive' * } ); * $( 'body' ).append( button1.$element, button2.$element, button3.$element ); * * {@link OO.ui.ActionWidget ActionWidgets}, which are a special kind of button that execute an action, use these flags: **primary** and **safe**. * Please see the [OOjs UI documentation on MediaWiki] [1] for more information. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Elements/Flagged * * @abstract * @class * * @constructor * @param {Object} [config] Configuration options * @cfg {string|string[]} [flags] The name or names of the flags (e.g., 'constructive' or 'primary') to apply. * Please see the [OOjs UI documentation on MediaWiki] [2] for more information about available flags. * [2]: https://www.mediawiki.org/wiki/OOjs_UI/Elements/Flagged * @cfg {jQuery} [$flagged] The flagged element. By default, * the flagged functionality is applied to the element created by the class ($element). * If a different element is specified, the flagged functionality will be applied to it instead. */ OO.ui.mixin.FlaggedElement = function OoUiMixinFlaggedElement( config ) { // Configuration initialization config = config || {}; // Properties this.flags = {}; this.$flagged = null; // Initialization this.setFlags( config.flags ); this.setFlaggedElement( config.$flagged || this.$element ); }; /* Events */ /** * @event flag * A flag event is emitted when the #clearFlags or #setFlags methods are used. The `changes` * parameter contains the name of each modified flag and indicates whether it was * added or removed. * * @param {Object.<string,boolean>} changes Object keyed by flag name. A Boolean `true` indicates * that the flag was added, `false` that the flag was removed. */ /* Methods */ /** * Set the flagged element. * * This method is used to retarget a flagged mixin so that its functionality applies to the specified element. * If an element is already set, the method will remove the mixin’s effect on that element. * * @param {jQuery} $flagged Element that should be flagged */ OO.ui.mixin.FlaggedElement.prototype.setFlaggedElement = function ( $flagged ) { var classNames = Object.keys( this.flags ).map( function ( flag ) { return 'oo-ui-flaggedElement-' + flag; } ).join( ' ' ); if ( this.$flagged ) { this.$flagged.removeClass( classNames ); } this.$flagged = $flagged.addClass( classNames ); }; /** * Check if the specified flag is set. * * @param {string} flag Name of flag * @return {boolean} The flag is set */ OO.ui.mixin.FlaggedElement.prototype.hasFlag = function ( flag ) { // This may be called before the constructor, thus before this.flags is set return this.flags && ( flag in this.flags ); }; /** * Get the names of all flags set. * * @return {string[]} Flag names */ OO.ui.mixin.FlaggedElement.prototype.getFlags = function () { // This may be called before the constructor, thus before this.flags is set return Object.keys( this.flags || {} ); }; /** * Clear all flags. * * @chainable * @fires flag */ OO.ui.mixin.FlaggedElement.prototype.clearFlags = function () { var flag, className, changes = {}, remove = [], classPrefix = 'oo-ui-flaggedElement-'; for ( flag in this.flags ) { className = classPrefix + flag; changes[ flag ] = false; delete this.flags[ flag ]; remove.push( className ); } if ( this.$flagged ) { this.$flagged.removeClass( remove.join( ' ' ) ); } this.updateThemeClasses(); this.emit( 'flag', changes ); return this; }; /** * Add one or more flags. * * @param {string|string[]|Object.<string, boolean>} flags A flag name, an array of flag names, * or an object keyed by flag name with a boolean value that indicates whether the flag should * be added (`true`) or removed (`false`). * @chainable * @fires flag */ OO.ui.mixin.FlaggedElement.prototype.setFlags = function ( flags ) { var i, len, flag, className, changes = {}, add = [], remove = [], classPrefix = 'oo-ui-flaggedElement-'; if ( typeof flags === 'string' ) { className = classPrefix + flags; // Set if ( !this.flags[ flags ] ) { this.flags[ flags ] = true; add.push( className ); } } else if ( Array.isArray( flags ) ) { for ( i = 0, len = flags.length; i < len; i++ ) { flag = flags[ i ]; className = classPrefix + flag; // Set if ( !this.flags[ flag ] ) { changes[ flag ] = true; this.flags[ flag ] = true; add.push( className ); } } } else if ( OO.isPlainObject( flags ) ) { for ( flag in flags ) { className = classPrefix + flag; if ( flags[ flag ] ) { // Set if ( !this.flags[ flag ] ) { changes[ flag ] = true; this.flags[ flag ] = true; add.push( className ); } } else { // Remove if ( this.flags[ flag ] ) { changes[ flag ] = false; delete this.flags[ flag ]; remove.push( className ); } } } } if ( this.$flagged ) { this.$flagged .addClass( add.join( ' ' ) ) .removeClass( remove.join( ' ' ) ); } this.updateThemeClasses(); this.emit( 'flag', changes ); return this; }; /** * TitledElement is mixed into other classes to provide a `title` attribute. * Titles are rendered by the browser and are made visible when the user moves * the mouse over the element. Titles are not visible on touch devices. * * @example * // TitledElement provides a 'title' attribute to the * // ButtonWidget class * var button = new OO.ui.ButtonWidget( { * label: 'Button with Title', * title: 'I am a button' * } ); * $( 'body' ).append( button.$element ); * * @abstract * @class * * @constructor * @param {Object} [config] Configuration options * @cfg {jQuery} [$titled] The element to which the `title` attribute is applied. * If this config is omitted, the title functionality is applied to $element, the * element created by the class. * @cfg {string|Function} [title] The title text or a function that returns text. If * this config is omitted, the value of the {@link #static-title static title} property is used. */ OO.ui.mixin.TitledElement = function OoUiMixinTitledElement( config ) { // Configuration initialization config = config || {}; // Properties this.$titled = null; this.title = null; // Initialization this.setTitle( config.title || this.constructor.static.title ); this.setTitledElement( config.$titled || this.$element ); }; /* Setup */ OO.initClass( OO.ui.mixin.TitledElement ); /* Static Properties */ /** * The title text, a function that returns text, or `null` for no title. The value of the static property * is overridden if the #title config option is used. * * @static * @inheritable * @property {string|Function|null} */ OO.ui.mixin.TitledElement.static.title = null; /* Methods */ /** * Set the titled element. * * This method is used to retarget a titledElement mixin so that its functionality applies to the specified element. * If an element is already set, the mixin’s effect on that element is removed before the new element is set up. * * @param {jQuery} $titled Element that should use the 'titled' functionality */ OO.ui.mixin.TitledElement.prototype.setTitledElement = function ( $titled ) { if ( this.$titled ) { this.$titled.removeAttr( 'title' ); } this.$titled = $titled; if ( this.title ) { this.$titled.attr( 'title', this.title ); } }; /** * Set title. * * @param {string|Function|null} title Title text, a function that returns text, or `null` for no title * @chainable */ OO.ui.mixin.TitledElement.prototype.setTitle = function ( title ) { title = typeof title === 'string' ? OO.ui.resolveMsg( title ) : null; if ( this.title !== title ) { if ( this.$titled ) { if ( title !== null ) { this.$titled.attr( 'title', title ); } else { this.$titled.removeAttr( 'title' ); } } this.title = title; } return this; }; /** * Get title. * * @return {string} Title string */ OO.ui.mixin.TitledElement.prototype.getTitle = function () { return this.title; }; /** * Element that can be automatically clipped to visible boundaries. * * Whenever the element's natural height changes, you have to call * {@link OO.ui.mixin.ClippableElement#clip} to make sure it's still * clipping correctly. * * The dimensions of #$clippableContainer will be compared to the boundaries of the * nearest scrollable container. If #$clippableContainer is too tall and/or too wide, * then #$clippable will be given a fixed reduced height and/or width and will be made * scrollable. By default, #$clippable and #$clippableContainer are the same element, * but you can build a static footer by setting #$clippableContainer to an element that contains * #$clippable and the footer. * * @abstract * @class * * @constructor * @param {Object} [config] Configuration options * @cfg {jQuery} [$clippable] Node to clip, assigned to #$clippable, omit to use #$element * @cfg {jQuery} [$clippableContainer] Node to keep visible, assigned to #$clippableContainer, * omit to use #$clippable */ OO.ui.mixin.ClippableElement = function OoUiMixinClippableElement( config ) { // Configuration initialization config = config || {}; // Properties this.$clippable = null; this.$clippableContainer = null; this.clipping = false; this.clippedHorizontally = false; this.clippedVertically = false; this.$clippableScrollableContainer = null; this.$clippableScroller = null; this.$clippableWindow = null; this.idealWidth = null; this.idealHeight = null; this.onClippableScrollHandler = this.clip.bind( this ); this.onClippableWindowResizeHandler = this.clip.bind( this ); // Initialization if ( config.$clippableContainer ) { this.setClippableContainer( config.$clippableContainer ); } this.setClippableElement( config.$clippable || this.$element ); }; /* Methods */ /** * Set clippable element. * * If an element is already set, it will be cleaned up before setting up the new element. * * @param {jQuery} $clippable Element to make clippable */ OO.ui.mixin.ClippableElement.prototype.setClippableElement = function ( $clippable ) { if ( this.$clippable ) { this.$clippable.removeClass( 'oo-ui-clippableElement-clippable' ); this.$clippable.css( { width: '', height: '', overflowX: '', overflowY: '' } ); OO.ui.Element.static.reconsiderScrollbars( this.$clippable[ 0 ] ); } this.$clippable = $clippable.addClass( 'oo-ui-clippableElement-clippable' ); this.clip(); }; /** * Set clippable container. * * This is the container that will be measured when deciding whether to clip. When clipping, * #$clippable will be resized in order to keep the clippable container fully visible. * * If the clippable container is unset, #$clippable will be used. * * @param {jQuery|null} $clippableContainer Container to keep visible, or null to unset */ OO.ui.mixin.ClippableElement.prototype.setClippableContainer = function ( $clippableContainer ) { this.$clippableContainer = $clippableContainer; if ( this.$clippable ) { this.clip(); } }; /** * Toggle clipping. * * Do not turn clipping on until after the element is attached to the DOM and visible. * * @param {boolean} [clipping] Enable clipping, omit to toggle * @chainable */ OO.ui.mixin.ClippableElement.prototype.toggleClipping = function ( clipping ) { clipping = clipping === undefined ? !this.clipping : !!clipping; if ( this.clipping !== clipping ) { this.clipping = clipping; if ( clipping ) { this.$clippableScrollableContainer = $( this.getClosestScrollableElementContainer() ); // If the clippable container is the root, we have to listen to scroll events and check // jQuery.scrollTop on the window because of browser inconsistencies this.$clippableScroller = this.$clippableScrollableContainer.is( 'html, body' ) ? $( OO.ui.Element.static.getWindow( this.$clippableScrollableContainer ) ) : this.$clippableScrollableContainer; this.$clippableScroller.on( 'scroll', this.onClippableScrollHandler ); this.$clippableWindow = $( this.getElementWindow() ) .on( 'resize', this.onClippableWindowResizeHandler ); // Initial clip after visible this.clip(); } else { this.$clippable.css( { width: '', height: '', overflowX: '', overflowY: '' } ); OO.ui.Element.static.reconsiderScrollbars( this.$clippable[ 0 ] ); this.$clippableScrollableContainer = null; this.$clippableScroller.off( 'scroll', this.onClippableScrollHandler ); this.$clippableScroller = null; this.$clippableWindow.off( 'resize', this.onClippableWindowResizeHandler ); this.$clippableWindow = null; } } return this; }; /** * Check if the element will be clipped to fit the visible area of the nearest scrollable container. * * @return {boolean} Element will be clipped to the visible area */ OO.ui.mixin.ClippableElement.prototype.isClipping = function () { return this.clipping; }; /** * Check if the bottom or right of the element is being clipped by the nearest scrollable container. * * @return {boolean} Part of the element is being clipped */ OO.ui.mixin.ClippableElement.prototype.isClipped = function () { return this.clippedHorizontally || this.clippedVertically; }; /** * Check if the right of the element is being clipped by the nearest scrollable container. * * @return {boolean} Part of the element is being clipped */ OO.ui.mixin.ClippableElement.prototype.isClippedHorizontally = function () { return this.clippedHorizontally; }; /** * Check if the bottom of the element is being clipped by the nearest scrollable container. * * @return {boolean} Part of the element is being clipped */ OO.ui.mixin.ClippableElement.prototype.isClippedVertically = function () { return this.clippedVertically; }; /** * Set the ideal size. These are the dimensions the element will have when it's not being clipped. * * @param {number|string} [width] Width as a number of pixels or CSS string with unit suffix * @param {number|string} [height] Height as a number of pixels or CSS string with unit suffix */ OO.ui.mixin.ClippableElement.prototype.setIdealSize = function ( width, height ) { this.idealWidth = width; this.idealHeight = height; if ( !this.clipping ) { // Update dimensions this.$clippable.css( { width: width, height: height } ); } // While clipping, idealWidth and idealHeight are not considered }; /** * Clip element to visible boundaries and allow scrolling when needed. Call this method when * the element's natural height changes. * * Element will be clipped the bottom or right of the element is within 10px of the edge of, or * overlapped by, the visible area of the nearest scrollable container. * * @chainable */ OO.ui.mixin.ClippableElement.prototype.clip = function () { var $container, extraHeight, extraWidth, ccOffset, $scrollableContainer, scOffset, scHeight, scWidth, ccWidth, scrollerIsWindow, scrollTop, scrollLeft, desiredWidth, desiredHeight, allotedWidth, allotedHeight, naturalWidth, naturalHeight, clipWidth, clipHeight, buffer = 7; // Chosen by fair dice roll if ( !this.clipping ) { // this.$clippableScrollableContainer and this.$clippableWindow are null, so the below will fail return this; } $container = this.$clippableContainer || this.$clippable; extraHeight = $container.outerHeight() - this.$clippable.outerHeight(); extraWidth = $container.outerWidth() - this.$clippable.outerWidth(); ccOffset = $container.offset(); $scrollableContainer = this.$clippableScrollableContainer.is( 'html, body' ) ? this.$clippableWindow : this.$clippableScrollableContainer; scOffset = $scrollableContainer.offset() || { top: 0, left: 0 }; scHeight = $scrollableContainer.innerHeight() - buffer; scWidth = $scrollableContainer.innerWidth() - buffer; ccWidth = $container.outerWidth() + buffer; scrollerIsWindow = this.$clippableScroller[ 0 ] === this.$clippableWindow[ 0 ]; scrollTop = scrollerIsWindow ? this.$clippableScroller.scrollTop() : 0; scrollLeft = scrollerIsWindow ? this.$clippableScroller.scrollLeft() : 0; desiredWidth = ccOffset.left < 0 ? ccWidth + ccOffset.left : ( scOffset.left + scrollLeft + scWidth ) - ccOffset.left; desiredHeight = ( scOffset.top + scrollTop + scHeight ) - ccOffset.top; allotedWidth = desiredWidth - extraWidth; allotedHeight = desiredHeight - extraHeight; naturalWidth = this.$clippable.prop( 'scrollWidth' ); naturalHeight = this.$clippable.prop( 'scrollHeight' ); clipWidth = allotedWidth < naturalWidth; clipHeight = allotedHeight < naturalHeight; if ( clipWidth ) { this.$clippable.css( { overflowX: 'scroll', width: Math.max( 0, allotedWidth ) } ); } else { this.$clippable.css( { width: this.idealWidth ? this.idealWidth - extraWidth : '', overflowX: '' } ); } if ( clipHeight ) { this.$clippable.css( { overflowY: 'scroll', height: Math.max( 0, allotedHeight ) } ); } else { this.$clippable.css( { height: this.idealHeight ? this.idealHeight - extraHeight : '', overflowY: '' } ); } // If we stopped clipping in at least one of the dimensions if ( ( this.clippedHorizontally && !clipWidth ) || ( this.clippedVertically && !clipHeight ) ) { OO.ui.Element.static.reconsiderScrollbars( this.$clippable[ 0 ] ); } this.clippedHorizontally = clipWidth; this.clippedVertically = clipHeight; return this; }; /** * Element that will stick under a specified container, even when it is inserted elsewhere in the * document (for example, in a OO.ui.Window's $overlay). * * The elements's position is automatically calculated and maintained when window is resized or the * page is scrolled. If you reposition the container manually, you have to call #position to make * sure the element is still placed correctly. * * As positioning is only possible when both the element and the container are attached to the DOM * and visible, it's only done after you call #togglePositioning. You might want to do this inside * the #toggle method to display a floating popup, for example. * * @abstract * @class * * @constructor * @param {Object} [config] Configuration options * @cfg {jQuery} [$floatable] Node to position, assigned to #$floatable, omit to use #$element * @cfg {jQuery} [$floatableContainer] Node to position below */ OO.ui.mixin.FloatableElement = function OoUiMixinFloatableElement( config ) { // Configuration initialization config = config || {}; // Properties this.$floatable = null; this.$floatableContainer = null; this.$floatableWindow = null; this.$floatableClosestScrollable = null; this.onFloatableScrollHandler = this.position.bind( this ); this.onFloatableWindowResizeHandler = this.position.bind( this ); // Initialization this.setFloatableContainer( config.$floatableContainer ); this.setFloatableElement( config.$floatable || this.$element ); }; /* Methods */ /** * Set floatable element. * * If an element is already set, it will be cleaned up before setting up the new element. * * @param {jQuery} $floatable Element to make floatable */ OO.ui.mixin.FloatableElement.prototype.setFloatableElement = function ( $floatable ) { if ( this.$floatable ) { this.$floatable.removeClass( 'oo-ui-floatableElement-floatable' ); this.$floatable.css( { left: '', top: '' } ); } this.$floatable = $floatable.addClass( 'oo-ui-floatableElement-floatable' ); this.position(); }; /** * Set floatable container. * * The element will be always positioned under the specified container. * * @param {jQuery|null} $floatableContainer Container to keep visible, or null to unset */ OO.ui.mixin.FloatableElement.prototype.setFloatableContainer = function ( $floatableContainer ) { this.$floatableContainer = $floatableContainer; if ( this.$floatable ) { this.position(); } }; /** * Toggle positioning. * * Do not turn positioning on until after the element is attached to the DOM and visible. * * @param {boolean} [positioning] Enable positioning, omit to toggle * @chainable */ OO.ui.mixin.FloatableElement.prototype.togglePositioning = function ( positioning ) { var closestScrollableOfContainer, closestScrollableOfFloatable; positioning = positioning === undefined ? !this.positioning : !!positioning; if ( this.positioning !== positioning ) { this.positioning = positioning; closestScrollableOfContainer = OO.ui.Element.static.getClosestScrollableContainer( this.$floatableContainer[ 0 ] ); closestScrollableOfFloatable = OO.ui.Element.static.getClosestScrollableContainer( this.$floatable[ 0 ] ); if ( closestScrollableOfContainer !== closestScrollableOfFloatable ) { // If the scrollable is the root, we have to listen to scroll events // on the window because of browser inconsistencies (or do we? someone should verify this) if ( $( closestScrollableOfContainer ).is( 'html, body' ) ) { closestScrollableOfContainer = OO.ui.Element.static.getWindow( closestScrollableOfContainer ); } } if ( positioning ) { this.$floatableWindow = $( this.getElementWindow() ); this.$floatableWindow.on( 'resize', this.onFloatableWindowResizeHandler ); if ( closestScrollableOfContainer !== closestScrollableOfFloatable ) { this.$floatableClosestScrollable = $( closestScrollableOfContainer ); this.$floatableClosestScrollable.on( 'scroll', this.onFloatableScrollHandler ); } // Initial position after visible this.position(); } else { if ( this.$floatableWindow ) { this.$floatableWindow.off( 'resize', this.onFloatableWindowResizeHandler ); this.$floatableWindow = null; } if ( this.$floatableClosestScrollable ) { this.$floatableClosestScrollable.off( 'scroll', this.onFloatableScrollHandler ); this.$floatableClosestScrollable = null; } this.$floatable.css( { left: '', top: '' } ); } } return this; }; /** * Position the floatable below its container. * * This should only be done when both of them are attached to the DOM and visible. * * @chainable */ OO.ui.mixin.FloatableElement.prototype.position = function () { var pos; if ( !this.positioning ) { return this; } pos = OO.ui.Element.static.getRelativePosition( this.$floatableContainer, this.$floatable.offsetParent() ); // Position under container pos.top += this.$floatableContainer.height(); this.$floatable.css( pos ); // We updated the position, so re-evaluate the clipping state. // (ClippableElement does not listen to 'scroll' events on $floatableContainer's parent, and so // will not notice the need to update itself.) // TODO: This is terrible, we shouldn't need to know about ClippableElement at all here. Why does // it not listen to the right events in the right places? if ( this.clip ) { this.clip(); } return this; }; /** * AccessKeyedElement is mixed into other classes to provide an `accesskey` attribute. * Accesskeys allow an user to go to a specific element by using * a shortcut combination of a browser specific keys + the key * set to the field. * * @example * // AccessKeyedElement provides an 'accesskey' attribute to the * // ButtonWidget class * var button = new OO.ui.ButtonWidget( { * label: 'Button with Accesskey', * accessKey: 'k' * } ); * $( 'body' ).append( button.$element ); * * @abstract * @class * * @constructor * @param {Object} [config] Configuration options * @cfg {jQuery} [$accessKeyed] The element to which the `accesskey` attribute is applied. * If this config is omitted, the accesskey functionality is applied to $element, the * element created by the class. * @cfg {string|Function} [accessKey] The key or a function that returns the key. If * this config is omitted, no accesskey will be added. */ OO.ui.mixin.AccessKeyedElement = function OoUiMixinAccessKeyedElement( config ) { // Configuration initialization config = config || {}; // Properties this.$accessKeyed = null; this.accessKey = null; // Initialization this.setAccessKey( config.accessKey || null ); this.setAccessKeyedElement( config.$accessKeyed || this.$element ); }; /* Setup */ OO.initClass( OO.ui.mixin.AccessKeyedElement ); /* Static Properties */ /** * The access key, a function that returns a key, or `null` for no accesskey. * * @static * @inheritable * @property {string|Function|null} */ OO.ui.mixin.AccessKeyedElement.static.accessKey = null; /* Methods */ /** * Set the accesskeyed element. * * This method is used to retarget a AccessKeyedElement mixin so that its functionality applies to the specified element. * If an element is already set, the mixin's effect on that element is removed before the new element is set up. * * @param {jQuery} $accessKeyed Element that should use the 'accesskeyes' functionality */ OO.ui.mixin.AccessKeyedElement.prototype.setAccessKeyedElement = function ( $accessKeyed ) { if ( this.$accessKeyed ) { this.$accessKeyed.removeAttr( 'accesskey' ); } this.$accessKeyed = $accessKeyed; if ( this.accessKey ) { this.$accessKeyed.attr( 'accesskey', this.accessKey ); } }; /** * Set accesskey. * * @param {string|Function|null} accesskey Key, a function that returns a key, or `null` for no accesskey * @chainable */ OO.ui.mixin.AccessKeyedElement.prototype.setAccessKey = function ( accessKey ) { accessKey = typeof accessKey === 'string' ? OO.ui.resolveMsg( accessKey ) : null; if ( this.accessKey !== accessKey ) { if ( this.$accessKeyed ) { if ( accessKey !== null ) { this.$accessKeyed.attr( 'accesskey', accessKey ); } else { this.$accessKeyed.removeAttr( 'accesskey' ); } } this.accessKey = accessKey; } return this; }; /** * Get accesskey. * * @return {string} accessKey string */ OO.ui.mixin.AccessKeyedElement.prototype.getAccessKey = function () { return this.accessKey; }; /** * Tools, together with {@link OO.ui.ToolGroup toolgroups}, constitute {@link OO.ui.Toolbar toolbars}. * Each tool is configured with a static name, title, and icon and is customized with the command to carry * out when the tool is selected. Tools must also be registered with a {@link OO.ui.ToolFactory tool factory}, * which creates the tools on demand. * * Tools are added to toolgroups ({@link OO.ui.ListToolGroup ListToolGroup}, * {@link OO.ui.BarToolGroup BarToolGroup}, or {@link OO.ui.MenuToolGroup MenuToolGroup}), which determine how * the tool is displayed in the toolbar. See {@link OO.ui.Toolbar toolbars} for an example. * * For more information, please see the [OOjs UI documentation on MediaWiki][1]. * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Toolbars * * @abstract * @class * @extends OO.ui.Widget * @mixins OO.ui.mixin.IconElement * @mixins OO.ui.mixin.FlaggedElement * @mixins OO.ui.mixin.TabIndexedElement * * @constructor * @param {OO.ui.ToolGroup} toolGroup * @param {Object} [config] Configuration options * @cfg {string|Function} [title] Title text or a function that returns text. If this config is omitted, the value of * the {@link #static-title static title} property is used. * * The title is used in different ways depending on the type of toolgroup that contains the tool. The * title is used as a tooltip if the tool is part of a {@link OO.ui.BarToolGroup bar} toolgroup, or as the label text if the tool is * part of a {@link OO.ui.ListToolGroup list} or {@link OO.ui.MenuToolGroup menu} toolgroup. * * For bar toolgroups, a description of the accelerator key is appended to the title if an accelerator key * is associated with an action by the same name as the tool and accelerator functionality has been added to the application. * To add accelerator key functionality, you must subclass OO.ui.Toolbar and override the {@link OO.ui.Toolbar#getToolAccelerator getToolAccelerator} method. */ OO.ui.Tool = function OoUiTool( toolGroup, config ) { // Allow passing positional parameters inside the config object if ( OO.isPlainObject( toolGroup ) && config === undefined ) { config = toolGroup; toolGroup = config.toolGroup; } // Configuration initialization config = config || {}; // Parent constructor OO.ui.Tool.parent.call( this, config ); // Properties this.toolGroup = toolGroup; this.toolbar = this.toolGroup.getToolbar(); this.active = false; this.$title = $( '<span>' ); this.$accel = $( '<span>' ); this.$link = $( '<a>' ); this.title = null; // Mixin constructors OO.ui.mixin.IconElement.call( this, config ); OO.ui.mixin.FlaggedElement.call( this, config ); OO.ui.mixin.TabIndexedElement.call( this, $.extend( {}, config, { $tabIndexed: this.$link } ) ); // Events this.toolbar.connect( this, { updateState: 'onUpdateState' } ); // Initialization this.$title.addClass( 'oo-ui-tool-title' ); this.$accel .addClass( 'oo-ui-tool-accel' ) .prop( { // This may need to be changed if the key names are ever localized, // but for now they are essentially written in English dir: 'ltr', lang: 'en' } ); this.$link .addClass( 'oo-ui-tool-link' ) .append( this.$icon, this.$title, this.$accel ) .attr( 'role', 'button' ); this.$element .data( 'oo-ui-tool', this ) .addClass( 'oo-ui-tool ' + 'oo-ui-tool-name-' + this.constructor.static.name.replace( /^([^\/]+)\/([^\/]+).*$/, '$1-$2' ) ) .toggleClass( 'oo-ui-tool-with-label', this.constructor.static.displayBothIconAndLabel ) .append( this.$link ); this.setTitle( config.title || this.constructor.static.title ); }; /* Setup */ OO.inheritClass( OO.ui.Tool, OO.ui.Widget ); OO.mixinClass( OO.ui.Tool, OO.ui.mixin.IconElement ); OO.mixinClass( OO.ui.Tool, OO.ui.mixin.FlaggedElement ); OO.mixinClass( OO.ui.Tool, OO.ui.mixin.TabIndexedElement ); /* Static Properties */ /** * @static * @inheritdoc */ OO.ui.Tool.static.tagName = 'span'; /** * Symbolic name of tool. * * The symbolic name is used internally to register the tool with a {@link OO.ui.ToolFactory ToolFactory}. It can * also be used when adding tools to toolgroups. * * @abstract * @static * @inheritable * @property {string} */ OO.ui.Tool.static.name = ''; /** * Symbolic name of the group. * * The group name is used to associate tools with each other so that they can be selected later by * a {@link OO.ui.ToolGroup toolgroup}. * * @abstract * @static * @inheritable * @property {string} */ OO.ui.Tool.static.group = ''; /** * Tool title text or a function that returns title text. The value of the static property is overridden if the #title config option is used. * * @abstract * @static * @inheritable * @property {string|Function} */ OO.ui.Tool.static.title = ''; /** * Display both icon and label when the tool is used in a {@link OO.ui.BarToolGroup bar} toolgroup. * Normally only the icon is displayed, or only the label if no icon is given. * * @static * @inheritable * @property {boolean} */ OO.ui.Tool.static.displayBothIconAndLabel = false; /** * Add tool to catch-all groups automatically. * * A catch-all group, which contains all tools that do not currently belong to a toolgroup, * can be included in a toolgroup using the wildcard selector, an asterisk (*). * * @static * @inheritable * @property {boolean} */ OO.ui.Tool.static.autoAddToCatchall = true; /** * Add tool to named groups automatically. * * By default, tools that are configured with a static ‘group’ property are added * to that group and will be selected when the symbolic name of the group is specified (e.g., when * toolgroups include tools by group name). * * @static * @property {boolean} * @inheritable */ OO.ui.Tool.static.autoAddToGroup = true; /** * Check if this tool is compatible with given data. * * This is a stub that can be overriden to provide support for filtering tools based on an * arbitrary piece of information (e.g., where the cursor is in a document). The implementation * must also call this method so that the compatibility check can be performed. * * @static * @inheritable * @param {Mixed} data Data to check * @return {boolean} Tool can be used with data */ OO.ui.Tool.static.isCompatibleWith = function () { return false; }; /* Methods */ /** * Handle the toolbar state being updated. * * This is an abstract method that must be overridden in a concrete subclass. * * @protected * @abstract */ OO.ui.Tool.prototype.onUpdateState = function () { throw new Error( 'OO.ui.Tool.onUpdateState not implemented in this subclass:' + this.constructor ); }; /** * Handle the tool being selected. * * This is an abstract method that must be overridden in a concrete subclass. * * @protected * @abstract */ OO.ui.Tool.prototype.onSelect = function () { throw new Error( 'OO.ui.Tool.onSelect not implemented in this subclass:' + this.constructor ); }; /** * Check if the tool is active. * * Tools become active when their #onSelect or #onUpdateState handlers change them to appear pressed * with the #setActive method. Additional CSS is applied to the tool to reflect the active state. * * @return {boolean} Tool is active */ OO.ui.Tool.prototype.isActive = function () { return this.active; }; /** * Make the tool appear active or inactive. * * This method should be called within #onSelect or #onUpdateState event handlers to make the tool * appear pressed or not. * * @param {boolean} state Make tool appear active */ OO.ui.Tool.prototype.setActive = function ( state ) { this.active = !!state; if ( this.active ) { this.$element.addClass( 'oo-ui-tool-active' ); } else { this.$element.removeClass( 'oo-ui-tool-active' ); } }; /** * Set the tool #title. * * @param {string|Function} title Title text or a function that returns text * @chainable */ OO.ui.Tool.prototype.setTitle = function ( title ) { this.title = OO.ui.resolveMsg( title ); this.updateTitle(); return this; }; /** * Get the tool #title. * * @return {string} Title text */ OO.ui.Tool.prototype.getTitle = function () { return this.title; }; /** * Get the tool's symbolic name. * * @return {string} Symbolic name of tool */ OO.ui.Tool.prototype.getName = function () { return this.constructor.static.name; }; /** * Update the title. */ OO.ui.Tool.prototype.updateTitle = function () { var titleTooltips = this.toolGroup.constructor.static.titleTooltips, accelTooltips = this.toolGroup.constructor.static.accelTooltips, accel = this.toolbar.getToolAccelerator( this.constructor.static.name ), tooltipParts = []; this.$title.text( this.title ); this.$accel.text( accel ); if ( titleTooltips && typeof this.title === 'string' && this.title.length ) { tooltipParts.push( this.title ); } if ( accelTooltips && typeof accel === 'string' && accel.length ) { tooltipParts.push( accel ); } if ( tooltipParts.length ) { this.$link.attr( 'title', tooltipParts.join( ' ' ) ); } else { this.$link.removeAttr( 'title' ); } }; /** * Destroy tool. * * Destroying the tool removes all event handlers and the tool’s DOM elements. * Call this method whenever you are done using a tool. */ OO.ui.Tool.prototype.destroy = function () { this.toolbar.disconnect( this ); this.$element.remove(); }; /** * Toolbars are complex interface components that permit users to easily access a variety * of {@link OO.ui.Tool tools} (e.g., formatting commands) and actions, which are additional commands that are * part of the toolbar, but not configured as tools. * * Individual tools are customized and then registered with a {@link OO.ui.ToolFactory tool factory}, which creates * the tools on demand. Each tool has a symbolic name (used when registering the tool), a title (e.g., ‘Insert * picture’), and an icon. * * Individual tools are organized in {@link OO.ui.ToolGroup toolgroups}, which can be {@link OO.ui.MenuToolGroup menus} * of tools, {@link OO.ui.ListToolGroup lists} of tools, or a single {@link OO.ui.BarToolGroup bar} of tools. * The arrangement and order of the toolgroups is customized when the toolbar is set up. Tools can be presented in * any order, but each can only appear once in the toolbar. * * The following is an example of a basic toolbar. * * @example * // Example of a toolbar * // Create the toolbar * var toolFactory = new OO.ui.ToolFactory(); * var toolGroupFactory = new OO.ui.ToolGroupFactory(); * var toolbar = new OO.ui.Toolbar( toolFactory, toolGroupFactory ); * * // We will be placing status text in this element when tools are used * var $area = $( '<p>' ).text( 'Toolbar example' ); * * // Define the tools that we're going to place in our toolbar * * // Create a class inheriting from OO.ui.Tool * function PictureTool() { * PictureTool.parent.apply( this, arguments ); * } * OO.inheritClass( PictureTool, OO.ui.Tool ); * // Each tool must have a 'name' (used as an internal identifier, see later) and at least one * // of 'icon' and 'title' (displayed icon and text). * PictureTool.static.name = 'picture'; * PictureTool.static.icon = 'picture'; * PictureTool.static.title = 'Insert picture'; * // Defines the action that will happen when this tool is selected (clicked). * PictureTool.prototype.onSelect = function () { * $area.text( 'Picture tool clicked!' ); * // Never display this tool as "active" (selected). * this.setActive( false ); * }; * // Make this tool available in our toolFactory and thus our toolbar * toolFactory.register( PictureTool ); * * // Register two more tools, nothing interesting here * function SettingsTool() { * SettingsTool.parent.apply( this, arguments ); * } * OO.inheritClass( SettingsTool, OO.ui.Tool ); * SettingsTool.static.name = 'settings'; * SettingsTool.static.icon = 'settings'; * SettingsTool.static.title = 'Change settings'; * SettingsTool.prototype.onSelect = function () { * $area.text( 'Settings tool clicked!' ); * this.setActive( false ); * }; * toolFactory.register( SettingsTool ); * * // Register two more tools, nothing interesting here * function StuffTool() { * StuffTool.parent.apply( this, arguments ); * } * OO.inheritClass( StuffTool, OO.ui.Tool ); * StuffTool.static.name = 'stuff'; * StuffTool.static.icon = 'ellipsis'; * StuffTool.static.title = 'More stuff'; * StuffTool.prototype.onSelect = function () { * $area.text( 'More stuff tool clicked!' ); * this.setActive( false ); * }; * toolFactory.register( StuffTool ); * * // This is a PopupTool. Rather than having a custom 'onSelect' action, it will display a * // little popup window (a PopupWidget). * function HelpTool( toolGroup, config ) { * OO.ui.PopupTool.call( this, toolGroup, $.extend( { popup: { * padded: true, * label: 'Help', * head: true * } }, config ) ); * this.popup.$body.append( '<p>I am helpful!</p>' ); * } * OO.inheritClass( HelpTool, OO.ui.PopupTool ); * HelpTool.static.name = 'help'; * HelpTool.static.icon = 'help'; * HelpTool.static.title = 'Help'; * toolFactory.register( HelpTool ); * * // Finally define which tools and in what order appear in the toolbar. Each tool may only be * // used once (but not all defined tools must be used). * toolbar.setup( [ * { * // 'bar' tool groups display tools' icons only, side-by-side. * type: 'bar', * include: [ 'picture', 'help' ] * }, * { * // 'list' tool groups display both the titles and icons, in a dropdown list. * type: 'list', * indicator: 'down', * label: 'More', * include: [ 'settings', 'stuff' ] * } * // Note how the tools themselves are toolgroup-agnostic - the same tool can be displayed * // either in a 'list' or a 'bar'. There is a 'menu' tool group too, not showcased here, * // since it's more complicated to use. (See the next example snippet on this page.) * ] ); * * // Create some UI around the toolbar and place it in the document * var frame = new OO.ui.PanelLayout( { * expanded: false, * framed: true * } ); * var contentFrame = new OO.ui.PanelLayout( { * expanded: false, * padded: true * } ); * frame.$element.append( * toolbar.$element, * contentFrame.$element.append( $area ) * ); * $( 'body' ).append( frame.$element ); * * // Here is where the toolbar is actually built. This must be done after inserting it into the * // document. * toolbar.initialize(); * * The following example extends the previous one to illustrate 'menu' toolgroups and the usage of * 'updateState' event. * * @example * // Create the toolbar * var toolFactory = new OO.ui.ToolFactory(); * var toolGroupFactory = new OO.ui.ToolGroupFactory(); * var toolbar = new OO.ui.Toolbar( toolFactory, toolGroupFactory ); * * // We will be placing status text in this element when tools are used * var $area = $( '<p>' ).text( 'Toolbar example' ); * * // Define the tools that we're going to place in our toolbar * * // Create a class inheriting from OO.ui.Tool * function PictureTool() { * PictureTool.parent.apply( this, arguments ); * } * OO.inheritClass( PictureTool, OO.ui.Tool ); * // Each tool must have a 'name' (used as an internal identifier, see later) and at least one * // of 'icon' and 'title' (displayed icon and text). * PictureTool.static.name = 'picture'; * PictureTool.static.icon = 'picture'; * PictureTool.static.title = 'Insert picture'; * // Defines the action that will happen when this tool is selected (clicked). * PictureTool.prototype.onSelect = function () { * $area.text( 'Picture tool clicked!' ); * // Never display this tool as "active" (selected). * this.setActive( false ); * }; * // The toolbar can be synchronized with the state of some external stuff, like a text * // editor's editing area, highlighting the tools (e.g. a 'bold' tool would be shown as active * // when the text cursor was inside bolded text). Here we simply disable this feature. * PictureTool.prototype.onUpdateState = function () { * }; * // Make this tool available in our toolFactory and thus our toolbar * toolFactory.register( PictureTool ); * * // Register two more tools, nothing interesting here * function SettingsTool() { * SettingsTool.parent.apply( this, arguments ); * this.reallyActive = false; * } * OO.inheritClass( SettingsTool, OO.ui.Tool ); * SettingsTool.static.name = 'settings'; * SettingsTool.static.icon = 'settings'; * SettingsTool.static.title = 'Change settings'; * SettingsTool.prototype.onSelect = function () { * $area.text( 'Settings tool clicked!' ); * // Toggle the active state on each click * this.reallyActive = !this.reallyActive; * this.setActive( this.reallyActive ); * // To update the menu label * this.toolbar.emit( 'updateState' ); * }; * SettingsTool.prototype.onUpdateState = function () { * }; * toolFactory.register( SettingsTool ); * * // Register two more tools, nothing interesting here * function StuffTool() { * StuffTool.parent.apply( this, arguments ); * this.reallyActive = false; * } * OO.inheritClass( StuffTool, OO.ui.Tool ); * StuffTool.static.name = 'stuff'; * StuffTool.static.icon = 'ellipsis'; * StuffTool.static.title = 'More stuff'; * StuffTool.prototype.onSelect = function () { * $area.text( 'More stuff tool clicked!' ); * // Toggle the active state on each click * this.reallyActive = !this.reallyActive; * this.setActive( this.reallyActive ); * // To update the menu label * this.toolbar.emit( 'updateState' ); * }; * StuffTool.prototype.onUpdateState = function () { * }; * toolFactory.register( StuffTool ); * * // This is a PopupTool. Rather than having a custom 'onSelect' action, it will display a * // little popup window (a PopupWidget). 'onUpdateState' is also already implemented. * function HelpTool( toolGroup, config ) { * OO.ui.PopupTool.call( this, toolGroup, $.extend( { popup: { * padded: true, * label: 'Help', * head: true * } }, config ) ); * this.popup.$body.append( '<p>I am helpful!</p>' ); * } * OO.inheritClass( HelpTool, OO.ui.PopupTool ); * HelpTool.static.name = 'help'; * HelpTool.static.icon = 'help'; * HelpTool.static.title = 'Help'; * toolFactory.register( HelpTool ); * * // Finally define which tools and in what order appear in the toolbar. Each tool may only be * // used once (but not all defined tools must be used). * toolbar.setup( [ * { * // 'bar' tool groups display tools' icons only, side-by-side. * type: 'bar', * include: [ 'picture', 'help' ] * }, * { * // 'menu' tool groups display both the titles and icons, in a dropdown menu. * // Menu label indicates which items are selected. * type: 'menu', * indicator: 'down', * include: [ 'settings', 'stuff' ] * } * ] ); * * // Create some UI around the toolbar and place it in the document * var frame = new OO.ui.PanelLayout( { * expanded: false, * framed: true * } ); * var contentFrame = new OO.ui.PanelLayout( { * expanded: false, * padded: true * } ); * frame.$element.append( * toolbar.$element, * contentFrame.$element.append( $area ) * ); * $( 'body' ).append( frame.$element ); * * // Here is where the toolbar is actually built. This must be done after inserting it into the * // document. * toolbar.initialize(); * toolbar.emit( 'updateState' ); * * @class * @extends OO.ui.Element * @mixins OO.EventEmitter * @mixins OO.ui.mixin.GroupElement * * @constructor * @param {OO.ui.ToolFactory} toolFactory Factory for creating tools * @param {OO.ui.ToolGroupFactory} toolGroupFactory Factory for creating toolgroups * @param {Object} [config] Configuration options * @cfg {boolean} [actions] Add an actions section to the toolbar. Actions are commands that are included * in the toolbar, but are not configured as tools. By default, actions are displayed on the right side of * the toolbar. * @cfg {boolean} [shadow] Add a shadow below the toolbar. */ OO.ui.Toolbar = function OoUiToolbar( toolFactory, toolGroupFactory, config ) { // Allow passing positional parameters inside the config object if ( OO.isPlainObject( toolFactory ) && config === undefined ) { config = toolFactory; toolFactory = config.toolFactory; toolGroupFactory = config.toolGroupFactory; } // Configuration initialization config = config || {}; // Parent constructor OO.ui.Toolbar.parent.call( this, config ); // Mixin constructors OO.EventEmitter.call( this ); OO.ui.mixin.GroupElement.call( this, config ); // Properties this.toolFactory = toolFactory; this.toolGroupFactory = toolGroupFactory; this.groups = []; this.tools = {}; this.$bar = $( '<div>' ); this.$actions = $( '<div>' ); this.initialized = false; this.onWindowResizeHandler = this.onWindowResize.bind( this ); // Events this.$element .add( this.$bar ).add( this.$group ).add( this.$actions ) .on( 'mousedown keydown', this.onPointerDown.bind( this ) ); // Initialization this.$group.addClass( 'oo-ui-toolbar-tools' ); if ( config.actions ) { this.$bar.append( this.$actions.addClass( 'oo-ui-toolbar-actions' ) ); } this.$bar .addClass( 'oo-ui-toolbar-bar' ) .append( this.$group, '<div style="clear:both"></div>' ); if ( config.shadow ) { this.$bar.append( '<div class="oo-ui-toolbar-shadow"></div>' ); } this.$element.addClass( 'oo-ui-toolbar' ).append( this.$bar ); }; /* Setup */ OO.inheritClass( OO.ui.Toolbar, OO.ui.Element ); OO.mixinClass( OO.ui.Toolbar, OO.EventEmitter ); OO.mixinClass( OO.ui.Toolbar, OO.ui.mixin.GroupElement ); /* Methods */ /** * Get the tool factory. * * @return {OO.ui.ToolFactory} Tool factory */ OO.ui.Toolbar.prototype.getToolFactory = function () { return this.toolFactory; }; /** * Get the toolgroup factory. * * @return {OO.Factory} Toolgroup factory */ OO.ui.Toolbar.prototype.getToolGroupFactory = function () { return this.toolGroupFactory; }; /** * Handles mouse down events. * * @private * @param {jQuery.Event} e Mouse down event */ OO.ui.Toolbar.prototype.onPointerDown = function ( e ) { var $closestWidgetToEvent = $( e.target ).closest( '.oo-ui-widget' ), $closestWidgetToToolbar = this.$element.closest( '.oo-ui-widget' ); if ( !$closestWidgetToEvent.length || $closestWidgetToEvent[ 0 ] === $closestWidgetToToolbar[ 0 ] ) { return false; } }; /** * Handle window resize event. * * @private * @param {jQuery.Event} e Window resize event */ OO.ui.Toolbar.prototype.onWindowResize = function () { this.$element.toggleClass( 'oo-ui-toolbar-narrow', this.$bar.width() <= this.narrowThreshold ); }; /** * Sets up handles and preloads required information for the toolbar to work. * This must be called after it is attached to a visible document and before doing anything else. */ OO.ui.Toolbar.prototype.initialize = function () { if ( !this.initialized ) { this.initialized = true; this.narrowThreshold = this.$group.width() + this.$actions.width(); $( this.getElementWindow() ).on( 'resize', this.onWindowResizeHandler ); this.onWindowResize(); } }; /** * Set up the toolbar. * * The toolbar is set up with a list of toolgroup configurations that specify the type of * toolgroup ({@link OO.ui.BarToolGroup bar}, {@link OO.ui.MenuToolGroup menu}, or {@link OO.ui.ListToolGroup list}) * to add and which tools to include, exclude, promote, or demote within that toolgroup. Please * see {@link OO.ui.ToolGroup toolgroups} for more information about including tools in toolgroups. * * @param {Object.<string,Array>} groups List of toolgroup configurations * @param {Array|string} [groups.include] Tools to include in the toolgroup * @param {Array|string} [groups.exclude] Tools to exclude from the toolgroup * @param {Array|string} [groups.promote] Tools to promote to the beginning of the toolgroup * @param {Array|string} [groups.demote] Tools to demote to the end of the toolgroup */ OO.ui.Toolbar.prototype.setup = function ( groups ) { var i, len, type, group, items = [], defaultType = 'bar'; // Cleanup previous groups this.reset(); // Build out new groups for ( i = 0, len = groups.length; i < len; i++ ) { group = groups[ i ]; if ( group.include === '*' ) { // Apply defaults to catch-all groups if ( group.type === undefined ) { group.type = 'list'; } if ( group.label === undefined ) { group.label = OO.ui.msg( 'ooui-toolbar-more' ); } } // Check type has been registered type = this.getToolGroupFactory().lookup( group.type ) ? group.type : defaultType; items.push( this.getToolGroupFactory().create( type, this, group ) ); } this.addItems( items ); }; /** * Remove all tools and toolgroups from the toolbar. */ OO.ui.Toolbar.prototype.reset = function () { var i, len; this.groups = []; this.tools = {}; for ( i = 0, len = this.items.length; i < len; i++ ) { this.items[ i ].destroy(); } this.clearItems(); }; /** * Destroy the toolbar. * * Destroying the toolbar removes all event handlers and DOM elements that constitute the toolbar. Call * this method whenever you are done using a toolbar. */ OO.ui.Toolbar.prototype.destroy = function () { $( this.getElementWindow() ).off( 'resize', this.onWindowResizeHandler ); this.reset(); this.$element.remove(); }; /** * Check if the tool is available. * * Available tools are ones that have not yet been added to the toolbar. * * @param {string} name Symbolic name of tool * @return {boolean} Tool is available */ OO.ui.Toolbar.prototype.isToolAvailable = function ( name ) { return !this.tools[ name ]; }; /** * Prevent tool from being used again. * * @param {OO.ui.Tool} tool Tool to reserve */ OO.ui.Toolbar.prototype.reserveTool = function ( tool ) { this.tools[ tool.getName() ] = tool; }; /** * Allow tool to be used again. * * @param {OO.ui.Tool} tool Tool to release */ OO.ui.Toolbar.prototype.releaseTool = function ( tool ) { delete this.tools[ tool.getName() ]; }; /** * Get accelerator label for tool. * * The OOjs UI library does not contain an accelerator system, but this is the hook for one. To * use an accelerator system, subclass the toolbar and override this method, which is meant to return a label * that describes the accelerator keys for the tool passed (by symbolic name) to the method. * * @param {string} name Symbolic name of tool * @return {string|undefined} Tool accelerator label if available */ OO.ui.Toolbar.prototype.getToolAccelerator = function () { return undefined; }; /** * ToolGroups are collections of {@link OO.ui.Tool tools} that are used in a {@link OO.ui.Toolbar toolbar}. * The type of toolgroup ({@link OO.ui.ListToolGroup list}, {@link OO.ui.BarToolGroup bar}, or {@link OO.ui.MenuToolGroup menu}) * to which a tool belongs determines how the tool is arranged and displayed in the toolbar. Toolgroups * themselves are created on demand with a {@link OO.ui.ToolGroupFactory toolgroup factory}. * * Toolgroups can contain individual tools, groups of tools, or all available tools: * * To include an individual tool (or array of individual tools), specify tools by symbolic name: * * include: [ 'tool-name' ] or [ { name: 'tool-name' }] * * To include a group of tools, specify the group name. (The tool's static ‘group’ config is used to assign the tool to a group.) * * include: [ { group: 'group-name' } ] * * To include all tools that are not yet assigned to a toolgroup, use the catch-all selector, an asterisk (*): * * include: '*' * * See {@link OO.ui.Toolbar toolbars} for a full example. For more information about toolbars in general, * please see the [OOjs UI documentation on MediaWiki][1]. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Toolbars * * @abstract * @class * @extends OO.ui.Widget * @mixins OO.ui.mixin.GroupElement * * @constructor * @param {OO.ui.Toolbar} toolbar * @param {Object} [config] Configuration options * @cfg {Array|string} [include=[]] List of tools to include in the toolgroup. * @cfg {Array|string} [exclude=[]] List of tools to exclude from the toolgroup. * @cfg {Array|string} [promote=[]] List of tools to promote to the beginning of the toolgroup. * @cfg {Array|string} [demote=[]] List of tools to demote to the end of the toolgroup. * This setting is particularly useful when tools have been added to the toolgroup * en masse (e.g., via the catch-all selector). */ OO.ui.ToolGroup = function OoUiToolGroup( toolbar, config ) { // Allow passing positional parameters inside the config object if ( OO.isPlainObject( toolbar ) && config === undefined ) { config = toolbar; toolbar = config.toolbar; } // Configuration initialization config = config || {}; // Parent constructor OO.ui.ToolGroup.parent.call( this, config ); // Mixin constructors OO.ui.mixin.GroupElement.call( this, config ); // Properties this.toolbar = toolbar; this.tools = {}; this.pressed = null; this.autoDisabled = false; this.include = config.include || []; this.exclude = config.exclude || []; this.promote = config.promote || []; this.demote = config.demote || []; this.onCapturedMouseKeyUpHandler = this.onCapturedMouseKeyUp.bind( this ); // Events this.$element.on( { mousedown: this.onMouseKeyDown.bind( this ), mouseup: this.onMouseKeyUp.bind( this ), keydown: this.onMouseKeyDown.bind( this ), keyup: this.onMouseKeyUp.bind( this ), focus: this.onMouseOverFocus.bind( this ), blur: this.onMouseOutBlur.bind( this ), mouseover: this.onMouseOverFocus.bind( this ), mouseout: this.onMouseOutBlur.bind( this ) } ); this.toolbar.getToolFactory().connect( this, { register: 'onToolFactoryRegister' } ); this.aggregate( { disable: 'itemDisable' } ); this.connect( this, { itemDisable: 'updateDisabled' } ); // Initialization this.$group.addClass( 'oo-ui-toolGroup-tools' ); this.$element .addClass( 'oo-ui-toolGroup' ) .append( this.$group ); this.populate(); }; /* Setup */ OO.inheritClass( OO.ui.ToolGroup, OO.ui.Widget ); OO.mixinClass( OO.ui.ToolGroup, OO.ui.mixin.GroupElement ); /* Events */ /** * @event update */ /* Static Properties */ /** * Show labels in tooltips. * * @static * @inheritable * @property {boolean} */ OO.ui.ToolGroup.static.titleTooltips = false; /** * Show acceleration labels in tooltips. * * Note: The OOjs UI library does not include an accelerator system, but does contain * a hook for one. To use an accelerator system, subclass the {@link OO.ui.Toolbar toolbar} and * override the {@link OO.ui.Toolbar#getToolAccelerator getToolAccelerator} method, which is * meant to return a label that describes the accelerator keys for a given tool (e.g., 'Ctrl + M'). * * @static * @inheritable * @property {boolean} */ OO.ui.ToolGroup.static.accelTooltips = false; /** * Automatically disable the toolgroup when all tools are disabled * * @static * @inheritable * @property {boolean} */ OO.ui.ToolGroup.static.autoDisable = true; /* Methods */ /** * @inheritdoc */ OO.ui.ToolGroup.prototype.isDisabled = function () { return this.autoDisabled || OO.ui.ToolGroup.parent.prototype.isDisabled.apply( this, arguments ); }; /** * @inheritdoc */ OO.ui.ToolGroup.prototype.updateDisabled = function () { var i, item, allDisabled = true; if ( this.constructor.static.autoDisable ) { for ( i = this.items.length - 1; i >= 0; i-- ) { item = this.items[ i ]; if ( !item.isDisabled() ) { allDisabled = false; break; } } this.autoDisabled = allDisabled; } OO.ui.ToolGroup.parent.prototype.updateDisabled.apply( this, arguments ); }; /** * Handle mouse down and key down events. * * @protected * @param {jQuery.Event} e Mouse down or key down event */ OO.ui.ToolGroup.prototype.onMouseKeyDown = function ( e ) { if ( !this.isDisabled() && ( e.which === 1 || e.which === OO.ui.Keys.SPACE || e.which === OO.ui.Keys.ENTER ) ) { this.pressed = this.getTargetTool( e ); if ( this.pressed ) { this.pressed.setActive( true ); OO.ui.addCaptureEventListener( this.getElementDocument(), 'mouseup', this.onCapturedMouseKeyUpHandler ); OO.ui.addCaptureEventListener( this.getElementDocument(), 'keyup', this.onCapturedMouseKeyUpHandler ); } return false; } }; /** * Handle captured mouse up and key up events. * * @protected * @param {Event} e Mouse up or key up event */ OO.ui.ToolGroup.prototype.onCapturedMouseKeyUp = function ( e ) { OO.ui.removeCaptureEventListener( this.getElementDocument(), 'mouseup', this.onCapturedMouseKeyUpHandler ); OO.ui.removeCaptureEventListener( this.getElementDocument(), 'keyup', this.onCapturedMouseKeyUpHandler ); // onMouseKeyUp may be called a second time, depending on where the mouse is when the button is // released, but since `this.pressed` will no longer be true, the second call will be ignored. this.onMouseKeyUp( e ); }; /** * Handle mouse up and key up events. * * @protected * @param {jQuery.Event} e Mouse up or key up event */ OO.ui.ToolGroup.prototype.onMouseKeyUp = function ( e ) { var tool = this.getTargetTool( e ); if ( !this.isDisabled() && this.pressed && this.pressed === tool && ( e.which === 1 || e.which === OO.ui.Keys.SPACE || e.which === OO.ui.Keys.ENTER ) ) { this.pressed.onSelect(); this.pressed = null; return false; } this.pressed = null; }; /** * Handle mouse over and focus events. * * @protected * @param {jQuery.Event} e Mouse over or focus event */ OO.ui.ToolGroup.prototype.onMouseOverFocus = function ( e ) { var tool = this.getTargetTool( e ); if ( this.pressed && this.pressed === tool ) { this.pressed.setActive( true ); } }; /** * Handle mouse out and blur events. * * @protected * @param {jQuery.Event} e Mouse out or blur event */ OO.ui.ToolGroup.prototype.onMouseOutBlur = function ( e ) { var tool = this.getTargetTool( e ); if ( this.pressed && this.pressed === tool ) { this.pressed.setActive( false ); } }; /** * Get the closest tool to a jQuery.Event. * * Only tool links are considered, which prevents other elements in the tool such as popups from * triggering tool group interactions. * * @private * @param {jQuery.Event} e * @return {OO.ui.Tool|null} Tool, `null` if none was found */ OO.ui.ToolGroup.prototype.getTargetTool = function ( e ) { var tool, $item = $( e.target ).closest( '.oo-ui-tool-link' ); if ( $item.length ) { tool = $item.parent().data( 'oo-ui-tool' ); } return tool && !tool.isDisabled() ? tool : null; }; /** * Handle tool registry register events. * * If a tool is registered after the group is created, we must repopulate the list to account for: * * - a tool being added that may be included * - a tool already included being overridden * * @protected * @param {string} name Symbolic name of tool */ OO.ui.ToolGroup.prototype.onToolFactoryRegister = function () { this.populate(); }; /** * Get the toolbar that contains the toolgroup. * * @return {OO.ui.Toolbar} Toolbar that contains the toolgroup */ OO.ui.ToolGroup.prototype.getToolbar = function () { return this.toolbar; }; /** * Add and remove tools based on configuration. */ OO.ui.ToolGroup.prototype.populate = function () { var i, len, name, tool, toolFactory = this.toolbar.getToolFactory(), names = {}, add = [], remove = [], list = this.toolbar.getToolFactory().getTools( this.include, this.exclude, this.promote, this.demote ); // Build a list of needed tools for ( i = 0, len = list.length; i < len; i++ ) { name = list[ i ]; if ( // Tool exists toolFactory.lookup( name ) && // Tool is available or is already in this group ( this.toolbar.isToolAvailable( name ) || this.tools[ name ] ) ) { // Hack to prevent infinite recursion via ToolGroupTool. We need to reserve the tool before // creating it, but we can't call reserveTool() yet because we haven't created the tool. this.toolbar.tools[ name ] = true; tool = this.tools[ name ]; if ( !tool ) { // Auto-initialize tools on first use this.tools[ name ] = tool = toolFactory.create( name, this ); tool.updateTitle(); } this.toolbar.reserveTool( tool ); add.push( tool ); names[ name ] = true; } } // Remove tools that are no longer needed for ( name in this.tools ) { if ( !names[ name ] ) { this.tools[ name ].destroy(); this.toolbar.releaseTool( this.tools[ name ] ); remove.push( this.tools[ name ] ); delete this.tools[ name ]; } } if ( remove.length ) { this.removeItems( remove ); } // Update emptiness state if ( add.length ) { this.$element.removeClass( 'oo-ui-toolGroup-empty' ); } else { this.$element.addClass( 'oo-ui-toolGroup-empty' ); } // Re-add tools (moving existing ones to new locations) this.addItems( add ); // Disabled state may depend on items this.updateDisabled(); }; /** * Destroy toolgroup. */ OO.ui.ToolGroup.prototype.destroy = function () { var name; this.clearItems(); this.toolbar.getToolFactory().disconnect( this ); for ( name in this.tools ) { this.toolbar.releaseTool( this.tools[ name ] ); this.tools[ name ].disconnect( this ).destroy(); delete this.tools[ name ]; } this.$element.remove(); }; /** * MessageDialogs display a confirmation or alert message. By default, the rendered dialog box * consists of a header that contains the dialog title, a body with the message, and a footer that * contains any {@link OO.ui.ActionWidget action widgets}. The MessageDialog class is the only type * of {@link OO.ui.Dialog dialog} that is usually instantiated directly. * * There are two basic types of message dialogs, confirmation and alert: * * - **confirmation**: the dialog title describes what a progressive action will do and the message provides * more details about the consequences. * - **alert**: the dialog title describes which event occurred and the message provides more information * about why the event occurred. * * The MessageDialog class specifies two actions: ‘accept’, the primary * action (e.g., ‘ok’) and ‘reject,’ the safe action (e.g., ‘cancel’). Both will close the window, * passing along the selected action. * * For more information and examples, please see the [OOjs UI documentation on MediaWiki][1]. * * @example * // Example: Creating and opening a message dialog window. * var messageDialog = new OO.ui.MessageDialog(); * * // Create and append a window manager. * var windowManager = new OO.ui.WindowManager(); * $( 'body' ).append( windowManager.$element ); * windowManager.addWindows( [ messageDialog ] ); * // Open the window. * windowManager.openWindow( messageDialog, { * title: 'Basic message dialog', * message: 'This is the message' * } ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Windows/Message_Dialogs * * @class * @extends OO.ui.Dialog * * @constructor * @param {Object} [config] Configuration options */ OO.ui.MessageDialog = function OoUiMessageDialog( config ) { // Parent constructor OO.ui.MessageDialog.parent.call( this, config ); // Properties this.verticalActionLayout = null; // Initialization this.$element.addClass( 'oo-ui-messageDialog' ); }; /* Setup */ OO.inheritClass( OO.ui.MessageDialog, OO.ui.Dialog ); /* Static Properties */ OO.ui.MessageDialog.static.name = 'message'; OO.ui.MessageDialog.static.size = 'small'; OO.ui.MessageDialog.static.verbose = false; /** * Dialog title. * * The title of a confirmation dialog describes what a progressive action will do. The * title of an alert dialog describes which event occurred. * * @static * @inheritable * @property {jQuery|string|Function|null} */ OO.ui.MessageDialog.static.title = null; /** * The message displayed in the dialog body. * * A confirmation message describes the consequences of a progressive action. An alert * message describes why an event occurred. * * @static * @inheritable * @property {jQuery|string|Function|null} */ OO.ui.MessageDialog.static.message = null; OO.ui.MessageDialog.static.actions = [ { action: 'accept', label: OO.ui.deferMsg( 'ooui-dialog-message-accept' ), flags: 'primary' }, { action: 'reject', label: OO.ui.deferMsg( 'ooui-dialog-message-reject' ), flags: 'safe' } ]; /* Methods */ /** * @inheritdoc */ OO.ui.MessageDialog.prototype.setManager = function ( manager ) { OO.ui.MessageDialog.parent.prototype.setManager.call( this, manager ); // Events this.manager.connect( this, { resize: 'onResize' } ); return this; }; /** * @inheritdoc */ OO.ui.MessageDialog.prototype.onActionResize = function ( action ) { this.fitActions(); return OO.ui.MessageDialog.parent.prototype.onActionResize.call( this, action ); }; /** * Handle window resized events. * * @private */ OO.ui.MessageDialog.prototype.onResize = function () { var dialog = this; dialog.fitActions(); // Wait for CSS transition to finish and do it again :( setTimeout( function () { dialog.fitActions(); }, 300 ); }; /** * Toggle action layout between vertical and horizontal. * * @private * @param {boolean} [value] Layout actions vertically, omit to toggle * @chainable */ OO.ui.MessageDialog.prototype.toggleVerticalActionLayout = function ( value ) { value = value === undefined ? !this.verticalActionLayout : !!value; if ( value !== this.verticalActionLayout ) { this.verticalActionLayout = value; this.$actions .toggleClass( 'oo-ui-messageDialog-actions-vertical', value ) .toggleClass( 'oo-ui-messageDialog-actions-horizontal', !value ); } return this; }; /** * @inheritdoc */ OO.ui.MessageDialog.prototype.getActionProcess = function ( action ) { if ( action ) { return new OO.ui.Process( function () { this.close( { action: action } ); }, this ); } return OO.ui.MessageDialog.parent.prototype.getActionProcess.call( this, action ); }; /** * @inheritdoc * * @param {Object} [data] Dialog opening data * @param {jQuery|string|Function|null} [data.title] Description of the action being confirmed * @param {jQuery|string|Function|null} [data.message] Description of the action's consequence * @param {boolean} [data.verbose] Message is verbose and should be styled as a long message * @param {Object[]} [data.actions] List of OO.ui.ActionOptionWidget configuration options for each * action item */ OO.ui.MessageDialog.prototype.getSetupProcess = function ( data ) { data = data || {}; // Parent method return OO.ui.MessageDialog.parent.prototype.getSetupProcess.call( this, data ) .next( function () { this.title.setLabel( data.title !== undefined ? data.title : this.constructor.static.title ); this.message.setLabel( data.message !== undefined ? data.message : this.constructor.static.message ); this.message.$element.toggleClass( 'oo-ui-messageDialog-message-verbose', data.verbose !== undefined ? data.verbose : this.constructor.static.verbose ); }, this ); }; /** * @inheritdoc */ OO.ui.MessageDialog.prototype.getReadyProcess = function ( data ) { data = data || {}; // Parent method return OO.ui.MessageDialog.parent.prototype.getReadyProcess.call( this, data ) .next( function () { // Focus the primary action button var actions = this.actions.get(); actions = actions.filter( function ( action ) { return action.getFlags().indexOf( 'primary' ) > -1; } ); if ( actions.length > 0 ) { actions[ 0 ].$button.focus(); } }, this ); }; /** * @inheritdoc */ OO.ui.MessageDialog.prototype.getBodyHeight = function () { var bodyHeight, oldOverflow, $scrollable = this.container.$element; oldOverflow = $scrollable[ 0 ].style.overflow; $scrollable[ 0 ].style.overflow = 'hidden'; OO.ui.Element.static.reconsiderScrollbars( $scrollable[ 0 ] ); bodyHeight = this.text.$element.outerHeight( true ); $scrollable[ 0 ].style.overflow = oldOverflow; return bodyHeight; }; /** * @inheritdoc */ OO.ui.MessageDialog.prototype.setDimensions = function ( dim ) { var $scrollable = this.container.$element; OO.ui.MessageDialog.parent.prototype.setDimensions.call( this, dim ); // Twiddle the overflow property, otherwise an unnecessary scrollbar will be produced. // Need to do it after transition completes (250ms), add 50ms just in case. setTimeout( function () { var oldOverflow = $scrollable[ 0 ].style.overflow; $scrollable[ 0 ].style.overflow = 'hidden'; OO.ui.Element.static.reconsiderScrollbars( $scrollable[ 0 ] ); $scrollable[ 0 ].style.overflow = oldOverflow; }, 300 ); return this; }; /** * @inheritdoc */ OO.ui.MessageDialog.prototype.initialize = function () { // Parent method OO.ui.MessageDialog.parent.prototype.initialize.call( this ); // Properties this.$actions = $( '<div>' ); this.container = new OO.ui.PanelLayout( { scrollable: true, classes: [ 'oo-ui-messageDialog-container' ] } ); this.text = new OO.ui.PanelLayout( { padded: true, expanded: false, classes: [ 'oo-ui-messageDialog-text' ] } ); this.message = new OO.ui.LabelWidget( { classes: [ 'oo-ui-messageDialog-message' ] } ); // Initialization this.title.$element.addClass( 'oo-ui-messageDialog-title' ); this.$content.addClass( 'oo-ui-messageDialog-content' ); this.container.$element.append( this.text.$element ); this.text.$element.append( this.title.$element, this.message.$element ); this.$body.append( this.container.$element ); this.$actions.addClass( 'oo-ui-messageDialog-actions' ); this.$foot.append( this.$actions ); }; /** * @inheritdoc */ OO.ui.MessageDialog.prototype.attachActions = function () { var i, len, other, special, others; // Parent method OO.ui.MessageDialog.parent.prototype.attachActions.call( this ); special = this.actions.getSpecial(); others = this.actions.getOthers(); if ( special.safe ) { this.$actions.append( special.safe.$element ); special.safe.toggleFramed( false ); } if ( others.length ) { for ( i = 0, len = others.length; i < len; i++ ) { other = others[ i ]; this.$actions.append( other.$element ); other.toggleFramed( false ); } } if ( special.primary ) { this.$actions.append( special.primary.$element ); special.primary.toggleFramed( false ); } if ( !this.isOpening() ) { // If the dialog is currently opening, this will be called automatically soon. // This also calls #fitActions. this.updateSize(); } }; /** * Fit action actions into columns or rows. * * Columns will be used if all labels can fit without overflow, otherwise rows will be used. * * @private */ OO.ui.MessageDialog.prototype.fitActions = function () { var i, len, action, previous = this.verticalActionLayout, actions = this.actions.get(); // Detect clipping this.toggleVerticalActionLayout( false ); for ( i = 0, len = actions.length; i < len; i++ ) { action = actions[ i ]; if ( action.$element.innerWidth() < action.$label.outerWidth( true ) ) { this.toggleVerticalActionLayout( true ); break; } } // Move the body out of the way of the foot this.$body.css( 'bottom', this.$foot.outerHeight( true ) ); if ( this.verticalActionLayout !== previous ) { // We changed the layout, window height might need to be updated. this.updateSize(); } }; /** * ProcessDialog windows encapsulate a {@link OO.ui.Process process} and all of the code necessary * to complete it. If the process terminates with an error, a customizable {@link OO.ui.Error error * interface} alerts users to the trouble, permitting the user to dismiss the error and try again when * relevant. The ProcessDialog class is always extended and customized with the actions and content * required for each process. * * The process dialog box consists of a header that visually represents the ‘working’ state of long * processes with an animation. The header contains the dialog title as well as * two {@link OO.ui.ActionWidget action widgets}: a ‘safe’ action on the left (e.g., ‘Cancel’) and * a ‘primary’ action on the right (e.g., ‘Done’). * * Like other windows, the process dialog is managed by a {@link OO.ui.WindowManager window manager}. * Please see the [OOjs UI documentation on MediaWiki][1] for more information and examples. * * @example * // Example: Creating and opening a process dialog window. * function MyProcessDialog( config ) { * MyProcessDialog.parent.call( this, config ); * } * OO.inheritClass( MyProcessDialog, OO.ui.ProcessDialog ); * * MyProcessDialog.static.title = 'Process dialog'; * MyProcessDialog.static.actions = [ * { action: 'save', label: 'Done', flags: 'primary' }, * { label: 'Cancel', flags: 'safe' } * ]; * * MyProcessDialog.prototype.initialize = function () { * MyProcessDialog.parent.prototype.initialize.apply( this, arguments ); * this.content = new OO.ui.PanelLayout( { padded: true, expanded: false } ); * this.content.$element.append( '<p>This is a process dialog window. The header contains the title and two buttons: \'Cancel\' (a safe action) on the left and \'Done\' (a primary action) on the right.</p>' ); * this.$body.append( this.content.$element ); * }; * MyProcessDialog.prototype.getActionProcess = function ( action ) { * var dialog = this; * if ( action ) { * return new OO.ui.Process( function () { * dialog.close( { action: action } ); * } ); * } * return MyProcessDialog.parent.prototype.getActionProcess.call( this, action ); * }; * * var windowManager = new OO.ui.WindowManager(); * $( 'body' ).append( windowManager.$element ); * * var dialog = new MyProcessDialog(); * windowManager.addWindows( [ dialog ] ); * windowManager.openWindow( dialog ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Windows/Process_Dialogs * * @abstract * @class * @extends OO.ui.Dialog * * @constructor * @param {Object} [config] Configuration options */ OO.ui.ProcessDialog = function OoUiProcessDialog( config ) { // Parent constructor OO.ui.ProcessDialog.parent.call( this, config ); // Properties this.fitOnOpen = false; // Initialization this.$element.addClass( 'oo-ui-processDialog' ); }; /* Setup */ OO.inheritClass( OO.ui.ProcessDialog, OO.ui.Dialog ); /* Methods */ /** * Handle dismiss button click events. * * Hides errors. * * @private */ OO.ui.ProcessDialog.prototype.onDismissErrorButtonClick = function () { this.hideErrors(); }; /** * Handle retry button click events. * * Hides errors and then tries again. * * @private */ OO.ui.ProcessDialog.prototype.onRetryButtonClick = function () { this.hideErrors(); this.executeAction( this.currentAction ); }; /** * @inheritdoc */ OO.ui.ProcessDialog.prototype.onActionResize = function ( action ) { if ( this.actions.isSpecial( action ) ) { this.fitLabel(); } return OO.ui.ProcessDialog.parent.prototype.onActionResize.call( this, action ); }; /** * @inheritdoc */ OO.ui.ProcessDialog.prototype.initialize = function () { // Parent method OO.ui.ProcessDialog.parent.prototype.initialize.call( this ); // Properties this.$navigation = $( '<div>' ); this.$location = $( '<div>' ); this.$safeActions = $( '<div>' ); this.$primaryActions = $( '<div>' ); this.$otherActions = $( '<div>' ); this.dismissButton = new OO.ui.ButtonWidget( { label: OO.ui.msg( 'ooui-dialog-process-dismiss' ) } ); this.retryButton = new OO.ui.ButtonWidget(); this.$errors = $( '<div>' ); this.$errorsTitle = $( '<div>' ); // Events this.dismissButton.connect( this, { click: 'onDismissErrorButtonClick' } ); this.retryButton.connect( this, { click: 'onRetryButtonClick' } ); // Initialization this.title.$element.addClass( 'oo-ui-processDialog-title' ); this.$location .append( this.title.$element ) .addClass( 'oo-ui-processDialog-location' ); this.$safeActions.addClass( 'oo-ui-processDialog-actions-safe' ); this.$primaryActions.addClass( 'oo-ui-processDialog-actions-primary' ); this.$otherActions.addClass( 'oo-ui-processDialog-actions-other' ); this.$errorsTitle .addClass( 'oo-ui-processDialog-errors-title' ) .text( OO.ui.msg( 'ooui-dialog-process-error' ) ); this.$errors .addClass( 'oo-ui-processDialog-errors oo-ui-element-hidden' ) .append( this.$errorsTitle, this.dismissButton.$element, this.retryButton.$element ); this.$content .addClass( 'oo-ui-processDialog-content' ) .append( this.$errors ); this.$navigation .addClass( 'oo-ui-processDialog-navigation' ) .append( this.$safeActions, this.$location, this.$primaryActions ); this.$head.append( this.$navigation ); this.$foot.append( this.$otherActions ); }; /** * @inheritdoc */ OO.ui.ProcessDialog.prototype.getActionWidgets = function ( actions ) { var i, len, widgets = []; for ( i = 0, len = actions.length; i < len; i++ ) { widgets.push( new OO.ui.ActionWidget( $.extend( { framed: true }, actions[ i ] ) ) ); } return widgets; }; /** * @inheritdoc */ OO.ui.ProcessDialog.prototype.attachActions = function () { var i, len, other, special, others; // Parent method OO.ui.ProcessDialog.parent.prototype.attachActions.call( this ); special = this.actions.getSpecial(); others = this.actions.getOthers(); if ( special.primary ) { this.$primaryActions.append( special.primary.$element ); } for ( i = 0, len = others.length; i < len; i++ ) { other = others[ i ]; this.$otherActions.append( other.$element ); } if ( special.safe ) { this.$safeActions.append( special.safe.$element ); } this.fitLabel(); this.$body.css( 'bottom', this.$foot.outerHeight( true ) ); }; /** * @inheritdoc */ OO.ui.ProcessDialog.prototype.executeAction = function ( action ) { var process = this; return OO.ui.ProcessDialog.parent.prototype.executeAction.call( this, action ) .fail( function ( errors ) { process.showErrors( errors || [] ); } ); }; /** * @inheritdoc */ OO.ui.ProcessDialog.prototype.setDimensions = function () { // Parent method OO.ui.ProcessDialog.parent.prototype.setDimensions.apply( this, arguments ); this.fitLabel(); }; /** * Fit label between actions. * * @private * @chainable */ OO.ui.ProcessDialog.prototype.fitLabel = function () { var safeWidth, primaryWidth, biggerWidth, labelWidth, navigationWidth, leftWidth, rightWidth, size = this.getSizeProperties(); if ( typeof size.width !== 'number' ) { if ( this.isOpened() ) { navigationWidth = this.$head.width() - 20; } else if ( this.isOpening() ) { if ( !this.fitOnOpen ) { // Size is relative and the dialog isn't open yet, so wait. this.manager.opening.done( this.fitLabel.bind( this ) ); this.fitOnOpen = true; } return; } else { return; } } else { navigationWidth = size.width - 20; } safeWidth = this.$safeActions.is( ':visible' ) ? this.$safeActions.width() : 0; primaryWidth = this.$primaryActions.is( ':visible' ) ? this.$primaryActions.width() : 0; biggerWidth = Math.max( safeWidth, primaryWidth ); labelWidth = this.title.$element.width(); if ( 2 * biggerWidth + labelWidth < navigationWidth ) { // We have enough space to center the label leftWidth = rightWidth = biggerWidth; } else { // Let's hope we at least have enough space not to overlap, because we can't wrap the label… if ( this.getDir() === 'ltr' ) { leftWidth = safeWidth; rightWidth = primaryWidth; } else { leftWidth = primaryWidth; rightWidth = safeWidth; } } this.$location.css( { paddingLeft: leftWidth, paddingRight: rightWidth } ); return this; }; /** * Handle errors that occurred during accept or reject processes. * * @private * @param {OO.ui.Error[]|OO.ui.Error} errors Errors to be handled */ OO.ui.ProcessDialog.prototype.showErrors = function ( errors ) { var i, len, $item, actions, items = [], abilities = {}, recoverable = true, warning = false; if ( errors instanceof OO.ui.Error ) { errors = [ errors ]; } for ( i = 0, len = errors.length; i < len; i++ ) { if ( !errors[ i ].isRecoverable() ) { recoverable = false; } if ( errors[ i ].isWarning() ) { warning = true; } $item = $( '<div>' ) .addClass( 'oo-ui-processDialog-error' ) .append( errors[ i ].getMessage() ); items.push( $item[ 0 ] ); } this.$errorItems = $( items ); if ( recoverable ) { abilities[ this.currentAction ] = true; // Copy the flags from the first matching action actions = this.actions.get( { actions: this.currentAction } ); if ( actions.length ) { this.retryButton.clearFlags().setFlags( actions[ 0 ].getFlags() ); } } else { abilities[ this.currentAction ] = false; this.actions.setAbilities( abilities ); } if ( warning ) { this.retryButton.setLabel( OO.ui.msg( 'ooui-dialog-process-continue' ) ); } else { this.retryButton.setLabel( OO.ui.msg( 'ooui-dialog-process-retry' ) ); } this.retryButton.toggle( recoverable ); this.$errorsTitle.after( this.$errorItems ); this.$errors.removeClass( 'oo-ui-element-hidden' ).scrollTop( 0 ); }; /** * Hide errors. * * @private */ OO.ui.ProcessDialog.prototype.hideErrors = function () { this.$errors.addClass( 'oo-ui-element-hidden' ); if ( this.$errorItems ) { this.$errorItems.remove(); this.$errorItems = null; } }; /** * @inheritdoc */ OO.ui.ProcessDialog.prototype.getTeardownProcess = function ( data ) { // Parent method return OO.ui.ProcessDialog.parent.prototype.getTeardownProcess.call( this, data ) .first( function () { // Make sure to hide errors this.hideErrors(); this.fitOnOpen = false; }, this ); }; /** * FieldLayouts are used with OO.ui.FieldsetLayout. Each FieldLayout requires a field-widget, * which is a widget that is specified by reference before any optional configuration settings. * * Field layouts can be configured with help text and/or labels. Labels are aligned in one of four ways: * * - **left**: The label is placed before the field-widget and aligned with the left margin. * A left-alignment is used for forms with many fields. * - **right**: The label is placed before the field-widget and aligned to the right margin. * A right-alignment is used for long but familiar forms which users tab through, * verifying the current field with a quick glance at the label. * - **top**: The label is placed above the field-widget. A top-alignment is used for brief forms * that users fill out from top to bottom. * - **inline**: The label is placed after the field-widget and aligned to the left. * An inline-alignment is best used with checkboxes or radio buttons. * * Help text is accessed via a help icon that appears in the upper right corner of the rendered field layout. * Please see the [OOjs UI documentation on MediaWiki] [1] for examples and more information. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Layouts/Fields_and_Fieldsets * @class * @extends OO.ui.Layout * @mixins OO.ui.mixin.LabelElement * @mixins OO.ui.mixin.TitledElement * * @constructor * @param {OO.ui.Widget} fieldWidget Field widget * @param {Object} [config] Configuration options * @cfg {string} [align='left'] Alignment of the label: 'left', 'right', 'top' or 'inline' * @cfg {Array} [errors] Error messages about the widget, which will be displayed below the widget. * The array may contain strings or OO.ui.HtmlSnippet instances. * @cfg {Array} [notices] Notices about the widget, which will be displayed below the widget. * The array may contain strings or OO.ui.HtmlSnippet instances. * @cfg {string|OO.ui.HtmlSnippet} [help] Help text. When help text is specified, a "help" icon will appear * in the upper-right corner of the rendered field; clicking it will display the text in a popup. * For important messages, you are advised to use `notices`, as they are always shown. * * @throws {Error} An error is thrown if no widget is specified */ OO.ui.FieldLayout = function OoUiFieldLayout( fieldWidget, config ) { var hasInputWidget, div; // Allow passing positional parameters inside the config object if ( OO.isPlainObject( fieldWidget ) && config === undefined ) { config = fieldWidget; fieldWidget = config.fieldWidget; } // Make sure we have required constructor arguments if ( fieldWidget === undefined ) { throw new Error( 'Widget not found' ); } hasInputWidget = fieldWidget.constructor.static.supportsSimpleLabel; // Configuration initialization config = $.extend( { align: 'left' }, config ); // Parent constructor OO.ui.FieldLayout.parent.call( this, config ); // Mixin constructors OO.ui.mixin.LabelElement.call( this, config ); OO.ui.mixin.TitledElement.call( this, $.extend( {}, config, { $titled: this.$label } ) ); // Properties this.fieldWidget = fieldWidget; this.errors = []; this.notices = []; this.$field = $( '<div>' ); this.$messages = $( '<ul>' ); this.$body = $( '<' + ( hasInputWidget ? 'label' : 'div' ) + '>' ); this.align = null; if ( config.help ) { this.popupButtonWidget = new OO.ui.PopupButtonWidget( { classes: [ 'oo-ui-fieldLayout-help' ], framed: false, icon: 'info' } ); div = $( '<div>' ); if ( config.help instanceof OO.ui.HtmlSnippet ) { div.html( config.help.toString() ); } else { div.text( config.help ); } this.popupButtonWidget.getPopup().$body.append( div.addClass( 'oo-ui-fieldLayout-help-content' ) ); this.$help = this.popupButtonWidget.$element; } else { this.$help = $( [] ); } // Events if ( hasInputWidget ) { this.$label.on( 'click', this.onLabelClick.bind( this ) ); } this.fieldWidget.connect( this, { disable: 'onFieldDisable' } ); // Initialization this.$element .addClass( 'oo-ui-fieldLayout' ) .append( this.$help, this.$body ); this.$body.addClass( 'oo-ui-fieldLayout-body' ); this.$messages.addClass( 'oo-ui-fieldLayout-messages' ); this.$field .addClass( 'oo-ui-fieldLayout-field' ) .toggleClass( 'oo-ui-fieldLayout-disable', this.fieldWidget.isDisabled() ) .append( this.fieldWidget.$element ); this.setErrors( config.errors || [] ); this.setNotices( config.notices || [] ); this.setAlignment( config.align ); }; /* Setup */ OO.inheritClass( OO.ui.FieldLayout, OO.ui.Layout ); OO.mixinClass( OO.ui.FieldLayout, OO.ui.mixin.LabelElement ); OO.mixinClass( OO.ui.FieldLayout, OO.ui.mixin.TitledElement ); /* Methods */ /** * Handle field disable events. * * @private * @param {boolean} value Field is disabled */ OO.ui.FieldLayout.prototype.onFieldDisable = function ( value ) { this.$element.toggleClass( 'oo-ui-fieldLayout-disabled', value ); }; /** * Handle label mouse click events. * * @private * @param {jQuery.Event} e Mouse click event */ OO.ui.FieldLayout.prototype.onLabelClick = function () { this.fieldWidget.simulateLabelClick(); return false; }; /** * Get the widget contained by the field. * * @return {OO.ui.Widget} Field widget */ OO.ui.FieldLayout.prototype.getField = function () { return this.fieldWidget; }; /** * @protected * @param {string} kind 'error' or 'notice' * @param {string|OO.ui.HtmlSnippet} text * @return {jQuery} */ OO.ui.FieldLayout.prototype.makeMessage = function ( kind, text ) { var $listItem, $icon, message; $listItem = $( '<li>' ); if ( kind === 'error' ) { $icon = new OO.ui.IconWidget( { icon: 'alert', flags: [ 'warning' ] } ).$element; } else if ( kind === 'notice' ) { $icon = new OO.ui.IconWidget( { icon: 'info' } ).$element; } else { $icon = ''; } message = new OO.ui.LabelWidget( { label: text } ); $listItem .append( $icon, message.$element ) .addClass( 'oo-ui-fieldLayout-messages-' + kind ); return $listItem; }; /** * Set the field alignment mode. * * @private * @param {string} value Alignment mode, either 'left', 'right', 'top' or 'inline' * @chainable */ OO.ui.FieldLayout.prototype.setAlignment = function ( value ) { if ( value !== this.align ) { // Default to 'left' if ( [ 'left', 'right', 'top', 'inline' ].indexOf( value ) === -1 ) { value = 'left'; } // Reorder elements if ( value === 'inline' ) { this.$body.append( this.$field, this.$label ); } else { this.$body.append( this.$label, this.$field ); } // Set classes. The following classes can be used here: // * oo-ui-fieldLayout-align-left // * oo-ui-fieldLayout-align-right // * oo-ui-fieldLayout-align-top // * oo-ui-fieldLayout-align-inline if ( this.align ) { this.$element.removeClass( 'oo-ui-fieldLayout-align-' + this.align ); } this.$element.addClass( 'oo-ui-fieldLayout-align-' + value ); this.align = value; } return this; }; /** * Set the list of error messages. * * @param {Array} errors Error messages about the widget, which will be displayed below the widget. * The array may contain strings or OO.ui.HtmlSnippet instances. * @chainable */ OO.ui.FieldLayout.prototype.setErrors = function ( errors ) { this.errors = errors.slice(); this.updateMessages(); return this; }; /** * Set the list of notice messages. * * @param {Array} notices Notices about the widget, which will be displayed below the widget. * The array may contain strings or OO.ui.HtmlSnippet instances. * @chainable */ OO.ui.FieldLayout.prototype.setNotices = function ( notices ) { this.notices = notices.slice(); this.updateMessages(); return this; }; /** * Update the rendering of error and notice messages. * * @private */ OO.ui.FieldLayout.prototype.updateMessages = function () { var i; this.$messages.empty(); if ( this.errors.length || this.notices.length ) { this.$body.after( this.$messages ); } else { this.$messages.remove(); return; } for ( i = 0; i < this.notices.length; i++ ) { this.$messages.append( this.makeMessage( 'notice', this.notices[ i ] ) ); } for ( i = 0; i < this.errors.length; i++ ) { this.$messages.append( this.makeMessage( 'error', this.errors[ i ] ) ); } }; /** * ActionFieldLayouts are used with OO.ui.FieldsetLayout. The layout consists of a field-widget, a button, * and an optional label and/or help text. The field-widget (e.g., a {@link OO.ui.TextInputWidget TextInputWidget}), * is required and is specified before any optional configuration settings. * * Labels can be aligned in one of four ways: * * - **left**: The label is placed before the field-widget and aligned with the left margin. * A left-alignment is used for forms with many fields. * - **right**: The label is placed before the field-widget and aligned to the right margin. * A right-alignment is used for long but familiar forms which users tab through, * verifying the current field with a quick glance at the label. * - **top**: The label is placed above the field-widget. A top-alignment is used for brief forms * that users fill out from top to bottom. * - **inline**: The label is placed after the field-widget and aligned to the left. * An inline-alignment is best used with checkboxes or radio buttons. * * Help text is accessed via a help icon that appears in the upper right corner of the rendered field layout when help * text is specified. * * @example * // Example of an ActionFieldLayout * var actionFieldLayout = new OO.ui.ActionFieldLayout( * new OO.ui.TextInputWidget( { * placeholder: 'Field widget' * } ), * new OO.ui.ButtonWidget( { * label: 'Button' * } ), * { * label: 'An ActionFieldLayout. This label is aligned top', * align: 'top', * help: 'This is help text' * } * ); * * $( 'body' ).append( actionFieldLayout.$element ); * * @class * @extends OO.ui.FieldLayout * * @constructor * @param {OO.ui.Widget} fieldWidget Field widget * @param {OO.ui.ButtonWidget} buttonWidget Button widget */ OO.ui.ActionFieldLayout = function OoUiActionFieldLayout( fieldWidget, buttonWidget, config ) { // Allow passing positional parameters inside the config object if ( OO.isPlainObject( fieldWidget ) && config === undefined ) { config = fieldWidget; fieldWidget = config.fieldWidget; buttonWidget = config.buttonWidget; } // Parent constructor OO.ui.ActionFieldLayout.parent.call( this, fieldWidget, config ); // Properties this.buttonWidget = buttonWidget; this.$button = $( '<div>' ); this.$input = $( '<div>' ); // Initialization this.$element .addClass( 'oo-ui-actionFieldLayout' ); this.$button .addClass( 'oo-ui-actionFieldLayout-button' ) .append( this.buttonWidget.$element ); this.$input .addClass( 'oo-ui-actionFieldLayout-input' ) .append( this.fieldWidget.$element ); this.$field .append( this.$input, this.$button ); }; /* Setup */ OO.inheritClass( OO.ui.ActionFieldLayout, OO.ui.FieldLayout ); /** * FieldsetLayouts are composed of one or more {@link OO.ui.FieldLayout FieldLayouts}, * which each contain an individual widget and, optionally, a label. Each Fieldset can be * configured with a label as well. For more information and examples, * please see the [OOjs UI documentation on MediaWiki][1]. * * @example * // Example of a fieldset layout * var input1 = new OO.ui.TextInputWidget( { * placeholder: 'A text input field' * } ); * * var input2 = new OO.ui.TextInputWidget( { * placeholder: 'A text input field' * } ); * * var fieldset = new OO.ui.FieldsetLayout( { * label: 'Example of a fieldset layout' * } ); * * fieldset.addItems( [ * new OO.ui.FieldLayout( input1, { * label: 'Field One' * } ), * new OO.ui.FieldLayout( input2, { * label: 'Field Two' * } ) * ] ); * $( 'body' ).append( fieldset.$element ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Layouts/Fields_and_Fieldsets * * @class * @extends OO.ui.Layout * @mixins OO.ui.mixin.IconElement * @mixins OO.ui.mixin.LabelElement * @mixins OO.ui.mixin.GroupElement * * @constructor * @param {Object} [config] Configuration options * @cfg {OO.ui.FieldLayout[]} [items] An array of fields to add to the fieldset. See OO.ui.FieldLayout for more information about fields. */ OO.ui.FieldsetLayout = function OoUiFieldsetLayout( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.FieldsetLayout.parent.call( this, config ); // Mixin constructors OO.ui.mixin.IconElement.call( this, config ); OO.ui.mixin.LabelElement.call( this, config ); OO.ui.mixin.GroupElement.call( this, config ); if ( config.help ) { this.popupButtonWidget = new OO.ui.PopupButtonWidget( { classes: [ 'oo-ui-fieldsetLayout-help' ], framed: false, icon: 'info' } ); this.popupButtonWidget.getPopup().$body.append( $( '<div>' ) .text( config.help ) .addClass( 'oo-ui-fieldsetLayout-help-content' ) ); this.$help = this.popupButtonWidget.$element; } else { this.$help = $( [] ); } // Initialization this.$element .addClass( 'oo-ui-fieldsetLayout' ) .prepend( this.$help, this.$icon, this.$label, this.$group ); if ( Array.isArray( config.items ) ) { this.addItems( config.items ); } }; /* Setup */ OO.inheritClass( OO.ui.FieldsetLayout, OO.ui.Layout ); OO.mixinClass( OO.ui.FieldsetLayout, OO.ui.mixin.IconElement ); OO.mixinClass( OO.ui.FieldsetLayout, OO.ui.mixin.LabelElement ); OO.mixinClass( OO.ui.FieldsetLayout, OO.ui.mixin.GroupElement ); /** * FormLayouts are used to wrap {@link OO.ui.FieldsetLayout FieldsetLayouts} when you intend to use browser-based * form submission for the fields instead of handling them in JavaScript. Form layouts can be configured with an * HTML form action, an encoding type, and a method using the #action, #enctype, and #method configs, respectively. * See the [OOjs UI documentation on MediaWiki] [1] for more information and examples. * * Only widgets from the {@link OO.ui.InputWidget InputWidget} family support form submission. It * includes standard form elements like {@link OO.ui.CheckboxInputWidget checkboxes}, {@link * OO.ui.RadioInputWidget radio buttons} and {@link OO.ui.TextInputWidget text fields}, as well as * some fancier controls. Some controls have both regular and InputWidget variants, for example * OO.ui.DropdownWidget and OO.ui.DropdownInputWidget – only the latter support form submission and * often have simplified APIs to match the capabilities of HTML forms. * See the [OOjs UI Inputs documentation on MediaWiki] [2] for more information about InputWidgets. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Layouts/Forms * [2]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Inputs * * @example * // Example of a form layout that wraps a fieldset layout * var input1 = new OO.ui.TextInputWidget( { * placeholder: 'Username' * } ); * var input2 = new OO.ui.TextInputWidget( { * placeholder: 'Password', * type: 'password' * } ); * var submit = new OO.ui.ButtonInputWidget( { * label: 'Submit' * } ); * * var fieldset = new OO.ui.FieldsetLayout( { * label: 'A form layout' * } ); * fieldset.addItems( [ * new OO.ui.FieldLayout( input1, { * label: 'Username', * align: 'top' * } ), * new OO.ui.FieldLayout( input2, { * label: 'Password', * align: 'top' * } ), * new OO.ui.FieldLayout( submit ) * ] ); * var form = new OO.ui.FormLayout( { * items: [ fieldset ], * action: '/api/formhandler', * method: 'get' * } ) * $( 'body' ).append( form.$element ); * * @class * @extends OO.ui.Layout * @mixins OO.ui.mixin.GroupElement * * @constructor * @param {Object} [config] Configuration options * @cfg {string} [method] HTML form `method` attribute * @cfg {string} [action] HTML form `action` attribute * @cfg {string} [enctype] HTML form `enctype` attribute * @cfg {OO.ui.FieldsetLayout[]} [items] Fieldset layouts to add to the form layout. */ OO.ui.FormLayout = function OoUiFormLayout( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.FormLayout.parent.call( this, config ); // Mixin constructors OO.ui.mixin.GroupElement.call( this, $.extend( {}, config, { $group: this.$element } ) ); // Events this.$element.on( 'submit', this.onFormSubmit.bind( this ) ); // Make sure the action is safe if ( config.action !== undefined && !OO.ui.isSafeUrl( config.action ) ) { throw new Error( 'Potentially unsafe action provided: ' + config.action ); } // Initialization this.$element .addClass( 'oo-ui-formLayout' ) .attr( { method: config.method, action: config.action, enctype: config.enctype } ); if ( Array.isArray( config.items ) ) { this.addItems( config.items ); } }; /* Setup */ OO.inheritClass( OO.ui.FormLayout, OO.ui.Layout ); OO.mixinClass( OO.ui.FormLayout, OO.ui.mixin.GroupElement ); /* Events */ /** * A 'submit' event is emitted when the form is submitted. * * @event submit */ /* Static Properties */ OO.ui.FormLayout.static.tagName = 'form'; /* Methods */ /** * Handle form submit events. * * @private * @param {jQuery.Event} e Submit event * @fires submit */ OO.ui.FormLayout.prototype.onFormSubmit = function () { if ( this.emit( 'submit' ) ) { return false; } }; /** * MenuLayouts combine a menu and a content {@link OO.ui.PanelLayout panel}. The menu is positioned relative to the content (after, before, top, or bottom) * and its size is customized with the #menuSize config. The content area will fill all remaining space. * * @example * var menuLayout = new OO.ui.MenuLayout( { * position: 'top' * } ), * menuPanel = new OO.ui.PanelLayout( { padded: true, expanded: true, scrollable: true } ), * contentPanel = new OO.ui.PanelLayout( { padded: true, expanded: true, scrollable: true } ), * select = new OO.ui.SelectWidget( { * items: [ * new OO.ui.OptionWidget( { * data: 'before', * label: 'Before', * } ), * new OO.ui.OptionWidget( { * data: 'after', * label: 'After', * } ), * new OO.ui.OptionWidget( { * data: 'top', * label: 'Top', * } ), * new OO.ui.OptionWidget( { * data: 'bottom', * label: 'Bottom', * } ) * ] * } ).on( 'select', function ( item ) { * menuLayout.setMenuPosition( item.getData() ); * } ); * * menuLayout.$menu.append( * menuPanel.$element.append( '<b>Menu panel</b>', select.$element ) * ); * menuLayout.$content.append( * contentPanel.$element.append( '<b>Content panel</b>', '<p>Note that the menu is positioned relative to the content panel: top, bottom, after, before.</p>') * ); * $( 'body' ).append( menuLayout.$element ); * * If menu size needs to be overridden, it can be accomplished using CSS similar to the snippet * below. MenuLayout's CSS will override the appropriate values with 'auto' or '0' to display the * menu correctly. If `menuPosition` is known beforehand, CSS rules corresponding to other positions * may be omitted. * * .oo-ui-menuLayout-menu { * height: 200px; * width: 200px; * } * .oo-ui-menuLayout-content { * top: 200px; * left: 200px; * right: 200px; * bottom: 200px; * } * * @class * @extends OO.ui.Layout * * @constructor * @param {Object} [config] Configuration options * @cfg {boolean} [showMenu=true] Show menu * @cfg {string} [menuPosition='before'] Position of menu: `top`, `after`, `bottom` or `before` */ OO.ui.MenuLayout = function OoUiMenuLayout( config ) { // Configuration initialization config = $.extend( { showMenu: true, menuPosition: 'before' }, config ); // Parent constructor OO.ui.MenuLayout.parent.call( this, config ); /** * Menu DOM node * * @property {jQuery} */ this.$menu = $( '<div>' ); /** * Content DOM node * * @property {jQuery} */ this.$content = $( '<div>' ); // Initialization this.$menu .addClass( 'oo-ui-menuLayout-menu' ); this.$content.addClass( 'oo-ui-menuLayout-content' ); this.$element .addClass( 'oo-ui-menuLayout' ) .append( this.$content, this.$menu ); this.setMenuPosition( config.menuPosition ); this.toggleMenu( config.showMenu ); }; /* Setup */ OO.inheritClass( OO.ui.MenuLayout, OO.ui.Layout ); /* Methods */ /** * Toggle menu. * * @param {boolean} showMenu Show menu, omit to toggle * @chainable */ OO.ui.MenuLayout.prototype.toggleMenu = function ( showMenu ) { showMenu = showMenu === undefined ? !this.showMenu : !!showMenu; if ( this.showMenu !== showMenu ) { this.showMenu = showMenu; this.$element .toggleClass( 'oo-ui-menuLayout-showMenu', this.showMenu ) .toggleClass( 'oo-ui-menuLayout-hideMenu', !this.showMenu ); } return this; }; /** * Check if menu is visible * * @return {boolean} Menu is visible */ OO.ui.MenuLayout.prototype.isMenuVisible = function () { return this.showMenu; }; /** * Set menu position. * * @param {string} position Position of menu, either `top`, `after`, `bottom` or `before` * @throws {Error} If position value is not supported * @chainable */ OO.ui.MenuLayout.prototype.setMenuPosition = function ( position ) { this.$element.removeClass( 'oo-ui-menuLayout-' + this.menuPosition ); this.menuPosition = position; this.$element.addClass( 'oo-ui-menuLayout-' + position ); return this; }; /** * Get menu position. * * @return {string} Menu position */ OO.ui.MenuLayout.prototype.getMenuPosition = function () { return this.menuPosition; }; /** * BookletLayouts contain {@link OO.ui.PageLayout page layouts} as well as * an {@link OO.ui.OutlineSelectWidget outline} that allows users to easily navigate * through the pages and select which one to display. By default, only one page is * displayed at a time and the outline is hidden. When a user navigates to a new page, * the booklet layout automatically focuses on the first focusable element, unless the * default setting is changed. Optionally, booklets can be configured to show * {@link OO.ui.OutlineControlsWidget controls} for adding, moving, and removing items. * * @example * // Example of a BookletLayout that contains two PageLayouts. * * function PageOneLayout( name, config ) { * PageOneLayout.parent.call( this, name, config ); * this.$element.append( '<p>First page</p><p>(This booklet has an outline, displayed on the left)</p>' ); * } * OO.inheritClass( PageOneLayout, OO.ui.PageLayout ); * PageOneLayout.prototype.setupOutlineItem = function () { * this.outlineItem.setLabel( 'Page One' ); * }; * * function PageTwoLayout( name, config ) { * PageTwoLayout.parent.call( this, name, config ); * this.$element.append( '<p>Second page</p>' ); * } * OO.inheritClass( PageTwoLayout, OO.ui.PageLayout ); * PageTwoLayout.prototype.setupOutlineItem = function () { * this.outlineItem.setLabel( 'Page Two' ); * }; * * var page1 = new PageOneLayout( 'one' ), * page2 = new PageTwoLayout( 'two' ); * * var booklet = new OO.ui.BookletLayout( { * outlined: true * } ); * * booklet.addPages ( [ page1, page2 ] ); * $( 'body' ).append( booklet.$element ); * * @class * @extends OO.ui.MenuLayout * * @constructor * @param {Object} [config] Configuration options * @cfg {boolean} [continuous=false] Show all pages, one after another * @cfg {boolean} [autoFocus=true] Focus on the first focusable element when a new page is displayed. * @cfg {boolean} [outlined=false] Show the outline. The outline is used to navigate through the pages of the booklet. * @cfg {boolean} [editable=false] Show controls for adding, removing and reordering pages */ OO.ui.BookletLayout = function OoUiBookletLayout( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.BookletLayout.parent.call( this, config ); // Properties this.currentPageName = null; this.pages = {}; this.ignoreFocus = false; this.stackLayout = new OO.ui.StackLayout( { continuous: !!config.continuous } ); this.$content.append( this.stackLayout.$element ); this.autoFocus = config.autoFocus === undefined || !!config.autoFocus; this.outlineVisible = false; this.outlined = !!config.outlined; if ( this.outlined ) { this.editable = !!config.editable; this.outlineControlsWidget = null; this.outlineSelectWidget = new OO.ui.OutlineSelectWidget(); this.outlinePanel = new OO.ui.PanelLayout( { scrollable: true } ); this.$menu.append( this.outlinePanel.$element ); this.outlineVisible = true; if ( this.editable ) { this.outlineControlsWidget = new OO.ui.OutlineControlsWidget( this.outlineSelectWidget ); } } this.toggleMenu( this.outlined ); // Events this.stackLayout.connect( this, { set: 'onStackLayoutSet' } ); if ( this.outlined ) { this.outlineSelectWidget.connect( this, { select: 'onOutlineSelectWidgetSelect' } ); this.scrolling = false; this.stackLayout.connect( this, { visibleItemChange: 'onStackLayoutVisibleItemChange' } ); } if ( this.autoFocus ) { // Event 'focus' does not bubble, but 'focusin' does this.stackLayout.$element.on( 'focusin', this.onStackLayoutFocus.bind( this ) ); } // Initialization this.$element.addClass( 'oo-ui-bookletLayout' ); this.stackLayout.$element.addClass( 'oo-ui-bookletLayout-stackLayout' ); if ( this.outlined ) { this.outlinePanel.$element .addClass( 'oo-ui-bookletLayout-outlinePanel' ) .append( this.outlineSelectWidget.$element ); if ( this.editable ) { this.outlinePanel.$element .addClass( 'oo-ui-bookletLayout-outlinePanel-editable' ) .append( this.outlineControlsWidget.$element ); } } }; /* Setup */ OO.inheritClass( OO.ui.BookletLayout, OO.ui.MenuLayout ); /* Events */ /** * A 'set' event is emitted when a page is {@link #setPage set} to be displayed by the booklet layout. * @event set * @param {OO.ui.PageLayout} page Current page */ /** * An 'add' event is emitted when pages are {@link #addPages added} to the booklet layout. * * @event add * @param {OO.ui.PageLayout[]} page Added pages * @param {number} index Index pages were added at */ /** * A 'remove' event is emitted when pages are {@link #clearPages cleared} or * {@link #removePages removed} from the booklet. * * @event remove * @param {OO.ui.PageLayout[]} pages Removed pages */ /* Methods */ /** * Handle stack layout focus. * * @private * @param {jQuery.Event} e Focusin event */ OO.ui.BookletLayout.prototype.onStackLayoutFocus = function ( e ) { var name, $target; // Find the page that an element was focused within $target = $( e.target ).closest( '.oo-ui-pageLayout' ); for ( name in this.pages ) { // Check for page match, exclude current page to find only page changes if ( this.pages[ name ].$element[ 0 ] === $target[ 0 ] && name !== this.currentPageName ) { this.setPage( name ); break; } } }; /** * Handle visibleItemChange events from the stackLayout * * The next visible page is set as the current page by selecting it * in the outline * * @param {OO.ui.PageLayout} page The next visible page in the layout */ OO.ui.BookletLayout.prototype.onStackLayoutVisibleItemChange = function ( page ) { // Set a flag to so that the resulting call to #onStackLayoutSet doesn't // try and scroll the item into view again. this.scrolling = true; this.outlineSelectWidget.selectItemByData( page.getName() ); this.scrolling = false; }; /** * Handle stack layout set events. * * @private * @param {OO.ui.PanelLayout|null} page The page panel that is now the current panel */ OO.ui.BookletLayout.prototype.onStackLayoutSet = function ( page ) { var layout = this; if ( !this.scrolling && page ) { page.scrollElementIntoView( { complete: function () { if ( layout.autoFocus ) { layout.focus(); } } } ); } }; /** * Focus the first input in the current page. * * If no page is selected, the first selectable page will be selected. * If the focus is already in an element on the current page, nothing will happen. * @param {number} [itemIndex] A specific item to focus on */ OO.ui.BookletLayout.prototype.focus = function ( itemIndex ) { var page, items = this.stackLayout.getItems(); if ( itemIndex !== undefined && items[ itemIndex ] ) { page = items[ itemIndex ]; } else { page = this.stackLayout.getCurrentItem(); } if ( !page && this.outlined ) { this.selectFirstSelectablePage(); page = this.stackLayout.getCurrentItem(); } if ( !page ) { return; } // Only change the focus if is not already in the current page if ( !OO.ui.contains( page.$element[ 0 ], this.getElementDocument().activeElement, true ) ) { page.focus(); } }; /** * Find the first focusable input in the booklet layout and focus * on it. */ OO.ui.BookletLayout.prototype.focusFirstFocusable = function () { OO.ui.findFocusable( this.stackLayout.$element ).focus(); }; /** * Handle outline widget select events. * * @private * @param {OO.ui.OptionWidget|null} item Selected item */ OO.ui.BookletLayout.prototype.onOutlineSelectWidgetSelect = function ( item ) { if ( item ) { this.setPage( item.getData() ); } }; /** * Check if booklet has an outline. * * @return {boolean} Booklet has an outline */ OO.ui.BookletLayout.prototype.isOutlined = function () { return this.outlined; }; /** * Check if booklet has editing controls. * * @return {boolean} Booklet is editable */ OO.ui.BookletLayout.prototype.isEditable = function () { return this.editable; }; /** * Check if booklet has a visible outline. * * @return {boolean} Outline is visible */ OO.ui.BookletLayout.prototype.isOutlineVisible = function () { return this.outlined && this.outlineVisible; }; /** * Hide or show the outline. * * @param {boolean} [show] Show outline, omit to invert current state * @chainable */ OO.ui.BookletLayout.prototype.toggleOutline = function ( show ) { if ( this.outlined ) { show = show === undefined ? !this.outlineVisible : !!show; this.outlineVisible = show; this.toggleMenu( show ); } return this; }; /** * Get the page closest to the specified page. * * @param {OO.ui.PageLayout} page Page to use as a reference point * @return {OO.ui.PageLayout|null} Page closest to the specified page */ OO.ui.BookletLayout.prototype.getClosestPage = function ( page ) { var next, prev, level, pages = this.stackLayout.getItems(), index = pages.indexOf( page ); if ( index !== -1 ) { next = pages[ index + 1 ]; prev = pages[ index - 1 ]; // Prefer adjacent pages at the same level if ( this.outlined ) { level = this.outlineSelectWidget.getItemFromData( page.getName() ).getLevel(); if ( prev && level === this.outlineSelectWidget.getItemFromData( prev.getName() ).getLevel() ) { return prev; } if ( next && level === this.outlineSelectWidget.getItemFromData( next.getName() ).getLevel() ) { return next; } } } return prev || next || null; }; /** * Get the outline widget. * * If the booklet is not outlined, the method will return `null`. * * @return {OO.ui.OutlineSelectWidget|null} Outline widget, or null if the booklet is not outlined */ OO.ui.BookletLayout.prototype.getOutline = function () { return this.outlineSelectWidget; }; /** * Get the outline controls widget. * * If the outline is not editable, the method will return `null`. * * @return {OO.ui.OutlineControlsWidget|null} The outline controls widget. */ OO.ui.BookletLayout.prototype.getOutlineControls = function () { return this.outlineControlsWidget; }; /** * Get a page by its symbolic name. * * @param {string} name Symbolic name of page * @return {OO.ui.PageLayout|undefined} Page, if found */ OO.ui.BookletLayout.prototype.getPage = function ( name ) { return this.pages[ name ]; }; /** * Get the current page. * * @return {OO.ui.PageLayout|undefined} Current page, if found */ OO.ui.BookletLayout.prototype.getCurrentPage = function () { var name = this.getCurrentPageName(); return name ? this.getPage( name ) : undefined; }; /** * Get the symbolic name of the current page. * * @return {string|null} Symbolic name of the current page */ OO.ui.BookletLayout.prototype.getCurrentPageName = function () { return this.currentPageName; }; /** * Add pages to the booklet layout * * When pages are added with the same names as existing pages, the existing pages will be * automatically removed before the new pages are added. * * @param {OO.ui.PageLayout[]} pages Pages to add * @param {number} index Index of the insertion point * @fires add * @chainable */ OO.ui.BookletLayout.prototype.addPages = function ( pages, index ) { var i, len, name, page, item, currentIndex, stackLayoutPages = this.stackLayout.getItems(), remove = [], items = []; // Remove pages with same names for ( i = 0, len = pages.length; i < len; i++ ) { page = pages[ i ]; name = page.getName(); if ( Object.prototype.hasOwnProperty.call( this.pages, name ) ) { // Correct the insertion index currentIndex = stackLayoutPages.indexOf( this.pages[ name ] ); if ( currentIndex !== -1 && currentIndex + 1 < index ) { index--; } remove.push( this.pages[ name ] ); } } if ( remove.length ) { this.removePages( remove ); } // Add new pages for ( i = 0, len = pages.length; i < len; i++ ) { page = pages[ i ]; name = page.getName(); this.pages[ page.getName() ] = page; if ( this.outlined ) { item = new OO.ui.OutlineOptionWidget( { data: name } ); page.setOutlineItem( item ); items.push( item ); } } if ( this.outlined && items.length ) { this.outlineSelectWidget.addItems( items, index ); this.selectFirstSelectablePage(); } this.stackLayout.addItems( pages, index ); this.emit( 'add', pages, index ); return this; }; /** * Remove the specified pages from the booklet layout. * * To remove all pages from the booklet, you may wish to use the #clearPages method instead. * * @param {OO.ui.PageLayout[]} pages An array of pages to remove * @fires remove * @chainable */ OO.ui.BookletLayout.prototype.removePages = function ( pages ) { var i, len, name, page, items = []; for ( i = 0, len = pages.length; i < len; i++ ) { page = pages[ i ]; name = page.getName(); delete this.pages[ name ]; if ( this.outlined ) { items.push( this.outlineSelectWidget.getItemFromData( name ) ); page.setOutlineItem( null ); } } if ( this.outlined && items.length ) { this.outlineSelectWidget.removeItems( items ); this.selectFirstSelectablePage(); } this.stackLayout.removeItems( pages ); this.emit( 'remove', pages ); return this; }; /** * Clear all pages from the booklet layout. * * To remove only a subset of pages from the booklet, use the #removePages method. * * @fires remove * @chainable */ OO.ui.BookletLayout.prototype.clearPages = function () { var i, len, pages = this.stackLayout.getItems(); this.pages = {}; this.currentPageName = null; if ( this.outlined ) { this.outlineSelectWidget.clearItems(); for ( i = 0, len = pages.length; i < len; i++ ) { pages[ i ].setOutlineItem( null ); } } this.stackLayout.clearItems(); this.emit( 'remove', pages ); return this; }; /** * Set the current page by symbolic name. * * @fires set * @param {string} name Symbolic name of page */ OO.ui.BookletLayout.prototype.setPage = function ( name ) { var selectedItem, $focused, page = this.pages[ name ], previousPage = this.currentPageName && this.pages[ this.currentPageName ]; if ( name !== this.currentPageName ) { if ( this.outlined ) { selectedItem = this.outlineSelectWidget.getSelectedItem(); if ( selectedItem && selectedItem.getData() !== name ) { this.outlineSelectWidget.selectItemByData( name ); } } if ( page ) { if ( previousPage ) { previousPage.setActive( false ); // Blur anything focused if the next page doesn't have anything focusable. // This is not needed if the next page has something focusable (because once it is focused // this blur happens automatically). If the layout is non-continuous, this check is // meaningless because the next page is not visible yet and thus can't hold focus. if ( this.autoFocus && this.stackLayout.continuous && OO.ui.findFocusable( page.$element ).length !== 0 ) { $focused = previousPage.$element.find( ':focus' ); if ( $focused.length ) { $focused[ 0 ].blur(); } } } this.currentPageName = name; page.setActive( true ); this.stackLayout.setItem( page ); if ( !this.stackLayout.continuous && previousPage ) { // This should not be necessary, since any inputs on the previous page should have been // blurred when it was hidden, but browsers are not very consistent about this. $focused = previousPage.$element.find( ':focus' ); if ( $focused.length ) { $focused[ 0 ].blur(); } } this.emit( 'set', page ); } } }; /** * Select the first selectable page. * * @chainable */ OO.ui.BookletLayout.prototype.selectFirstSelectablePage = function () { if ( !this.outlineSelectWidget.getSelectedItem() ) { this.outlineSelectWidget.selectItem( this.outlineSelectWidget.getFirstSelectableItem() ); } return this; }; /** * IndexLayouts contain {@link OO.ui.CardLayout card layouts} as well as * {@link OO.ui.TabSelectWidget tabs} that allow users to easily navigate through the cards and * select which one to display. By default, only one card is displayed at a time. When a user * navigates to a new card, the index layout automatically focuses on the first focusable element, * unless the default setting is changed. * * TODO: This class is similar to BookletLayout, we may want to refactor to reduce duplication * * @example * // Example of a IndexLayout that contains two CardLayouts. * * function CardOneLayout( name, config ) { * CardOneLayout.parent.call( this, name, config ); * this.$element.append( '<p>First card</p>' ); * } * OO.inheritClass( CardOneLayout, OO.ui.CardLayout ); * CardOneLayout.prototype.setupTabItem = function () { * this.tabItem.setLabel( 'Card one' ); * }; * * var card1 = new CardOneLayout( 'one' ), * card2 = new CardLayout( 'two', { label: 'Card two' } ); * * card2.$element.append( '<p>Second card</p>' ); * * var index = new OO.ui.IndexLayout(); * * index.addCards ( [ card1, card2 ] ); * $( 'body' ).append( index.$element ); * * @class * @extends OO.ui.MenuLayout * * @constructor * @param {Object} [config] Configuration options * @cfg {boolean} [continuous=false] Show all cards, one after another * @cfg {boolean} [expanded=true] Expand the content panel to fill the entire parent element. * @cfg {boolean} [autoFocus=true] Focus on the first focusable element when a new card is displayed. */ OO.ui.IndexLayout = function OoUiIndexLayout( config ) { // Configuration initialization config = $.extend( {}, config, { menuPosition: 'top' } ); // Parent constructor OO.ui.IndexLayout.parent.call( this, config ); // Properties this.currentCardName = null; this.cards = {}; this.ignoreFocus = false; this.stackLayout = new OO.ui.StackLayout( { continuous: !!config.continuous, expanded: config.expanded } ); this.$content.append( this.stackLayout.$element ); this.autoFocus = config.autoFocus === undefined || !!config.autoFocus; this.tabSelectWidget = new OO.ui.TabSelectWidget(); this.tabPanel = new OO.ui.PanelLayout(); this.$menu.append( this.tabPanel.$element ); this.toggleMenu( true ); // Events this.stackLayout.connect( this, { set: 'onStackLayoutSet' } ); this.tabSelectWidget.connect( this, { select: 'onTabSelectWidgetSelect' } ); if ( this.autoFocus ) { // Event 'focus' does not bubble, but 'focusin' does this.stackLayout.$element.on( 'focusin', this.onStackLayoutFocus.bind( this ) ); } // Initialization this.$element.addClass( 'oo-ui-indexLayout' ); this.stackLayout.$element.addClass( 'oo-ui-indexLayout-stackLayout' ); this.tabPanel.$element .addClass( 'oo-ui-indexLayout-tabPanel' ) .append( this.tabSelectWidget.$element ); }; /* Setup */ OO.inheritClass( OO.ui.IndexLayout, OO.ui.MenuLayout ); /* Events */ /** * A 'set' event is emitted when a card is {@link #setCard set} to be displayed by the index layout. * @event set * @param {OO.ui.CardLayout} card Current card */ /** * An 'add' event is emitted when cards are {@link #addCards added} to the index layout. * * @event add * @param {OO.ui.CardLayout[]} card Added cards * @param {number} index Index cards were added at */ /** * A 'remove' event is emitted when cards are {@link #clearCards cleared} or * {@link #removeCards removed} from the index. * * @event remove * @param {OO.ui.CardLayout[]} cards Removed cards */ /* Methods */ /** * Handle stack layout focus. * * @private * @param {jQuery.Event} e Focusin event */ OO.ui.IndexLayout.prototype.onStackLayoutFocus = function ( e ) { var name, $target; // Find the card that an element was focused within $target = $( e.target ).closest( '.oo-ui-cardLayout' ); for ( name in this.cards ) { // Check for card match, exclude current card to find only card changes if ( this.cards[ name ].$element[ 0 ] === $target[ 0 ] && name !== this.currentCardName ) { this.setCard( name ); break; } } }; /** * Handle stack layout set events. * * @private * @param {OO.ui.PanelLayout|null} card The card panel that is now the current panel */ OO.ui.IndexLayout.prototype.onStackLayoutSet = function ( card ) { var layout = this; if ( card ) { card.scrollElementIntoView( { complete: function () { if ( layout.autoFocus ) { layout.focus(); } } } ); } }; /** * Focus the first input in the current card. * * If no card is selected, the first selectable card will be selected. * If the focus is already in an element on the current card, nothing will happen. * @param {number} [itemIndex] A specific item to focus on */ OO.ui.IndexLayout.prototype.focus = function ( itemIndex ) { var card, items = this.stackLayout.getItems(); if ( itemIndex !== undefined && items[ itemIndex ] ) { card = items[ itemIndex ]; } else { card = this.stackLayout.getCurrentItem(); } if ( !card ) { this.selectFirstSelectableCard(); card = this.stackLayout.getCurrentItem(); } if ( !card ) { return; } // Only change the focus if is not already in the current page if ( !OO.ui.contains( card.$element[ 0 ], this.getElementDocument().activeElement, true ) ) { card.focus(); } }; /** * Find the first focusable input in the index layout and focus * on it. */ OO.ui.IndexLayout.prototype.focusFirstFocusable = function () { OO.ui.findFocusable( this.stackLayout.$element ).focus(); }; /** * Handle tab widget select events. * * @private * @param {OO.ui.OptionWidget|null} item Selected item */ OO.ui.IndexLayout.prototype.onTabSelectWidgetSelect = function ( item ) { if ( item ) { this.setCard( item.getData() ); } }; /** * Get the card closest to the specified card. * * @param {OO.ui.CardLayout} card Card to use as a reference point * @return {OO.ui.CardLayout|null} Card closest to the specified card */ OO.ui.IndexLayout.prototype.getClosestCard = function ( card ) { var next, prev, level, cards = this.stackLayout.getItems(), index = cards.indexOf( card ); if ( index !== -1 ) { next = cards[ index + 1 ]; prev = cards[ index - 1 ]; // Prefer adjacent cards at the same level level = this.tabSelectWidget.getItemFromData( card.getName() ).getLevel(); if ( prev && level === this.tabSelectWidget.getItemFromData( prev.getName() ).getLevel() ) { return prev; } if ( next && level === this.tabSelectWidget.getItemFromData( next.getName() ).getLevel() ) { return next; } } return prev || next || null; }; /** * Get the tabs widget. * * @return {OO.ui.TabSelectWidget} Tabs widget */ OO.ui.IndexLayout.prototype.getTabs = function () { return this.tabSelectWidget; }; /** * Get a card by its symbolic name. * * @param {string} name Symbolic name of card * @return {OO.ui.CardLayout|undefined} Card, if found */ OO.ui.IndexLayout.prototype.getCard = function ( name ) { return this.cards[ name ]; }; /** * Get the current card. * * @return {OO.ui.CardLayout|undefined} Current card, if found */ OO.ui.IndexLayout.prototype.getCurrentCard = function () { var name = this.getCurrentCardName(); return name ? this.getCard( name ) : undefined; }; /** * Get the symbolic name of the current card. * * @return {string|null} Symbolic name of the current card */ OO.ui.IndexLayout.prototype.getCurrentCardName = function () { return this.currentCardName; }; /** * Add cards to the index layout * * When cards are added with the same names as existing cards, the existing cards will be * automatically removed before the new cards are added. * * @param {OO.ui.CardLayout[]} cards Cards to add * @param {number} index Index of the insertion point * @fires add * @chainable */ OO.ui.IndexLayout.prototype.addCards = function ( cards, index ) { var i, len, name, card, item, currentIndex, stackLayoutCards = this.stackLayout.getItems(), remove = [], items = []; // Remove cards with same names for ( i = 0, len = cards.length; i < len; i++ ) { card = cards[ i ]; name = card.getName(); if ( Object.prototype.hasOwnProperty.call( this.cards, name ) ) { // Correct the insertion index currentIndex = stackLayoutCards.indexOf( this.cards[ name ] ); if ( currentIndex !== -1 && currentIndex + 1 < index ) { index--; } remove.push( this.cards[ name ] ); } } if ( remove.length ) { this.removeCards( remove ); } // Add new cards for ( i = 0, len = cards.length; i < len; i++ ) { card = cards[ i ]; name = card.getName(); this.cards[ card.getName() ] = card; item = new OO.ui.TabOptionWidget( { data: name } ); card.setTabItem( item ); items.push( item ); } if ( items.length ) { this.tabSelectWidget.addItems( items, index ); this.selectFirstSelectableCard(); } this.stackLayout.addItems( cards, index ); this.emit( 'add', cards, index ); return this; }; /** * Remove the specified cards from the index layout. * * To remove all cards from the index, you may wish to use the #clearCards method instead. * * @param {OO.ui.CardLayout[]} cards An array of cards to remove * @fires remove * @chainable */ OO.ui.IndexLayout.prototype.removeCards = function ( cards ) { var i, len, name, card, items = []; for ( i = 0, len = cards.length; i < len; i++ ) { card = cards[ i ]; name = card.getName(); delete this.cards[ name ]; items.push( this.tabSelectWidget.getItemFromData( name ) ); card.setTabItem( null ); } if ( items.length ) { this.tabSelectWidget.removeItems( items ); this.selectFirstSelectableCard(); } this.stackLayout.removeItems( cards ); this.emit( 'remove', cards ); return this; }; /** * Clear all cards from the index layout. * * To remove only a subset of cards from the index, use the #removeCards method. * * @fires remove * @chainable */ OO.ui.IndexLayout.prototype.clearCards = function () { var i, len, cards = this.stackLayout.getItems(); this.cards = {}; this.currentCardName = null; this.tabSelectWidget.clearItems(); for ( i = 0, len = cards.length; i < len; i++ ) { cards[ i ].setTabItem( null ); } this.stackLayout.clearItems(); this.emit( 'remove', cards ); return this; }; /** * Set the current card by symbolic name. * * @fires set * @param {string} name Symbolic name of card */ OO.ui.IndexLayout.prototype.setCard = function ( name ) { var selectedItem, $focused, card = this.cards[ name ], previousCard = this.currentCardName && this.cards[ this.currentCardName ]; if ( name !== this.currentCardName ) { selectedItem = this.tabSelectWidget.getSelectedItem(); if ( selectedItem && selectedItem.getData() !== name ) { this.tabSelectWidget.selectItemByData( name ); } if ( card ) { if ( previousCard ) { previousCard.setActive( false ); // Blur anything focused if the next card doesn't have anything focusable. // This is not needed if the next card has something focusable (because once it is focused // this blur happens automatically). If the layout is non-continuous, this check is // meaningless because the next card is not visible yet and thus can't hold focus. if ( this.autoFocus && this.stackLayout.continuous && OO.ui.findFocusable( card.$element ).length !== 0 ) { $focused = previousCard.$element.find( ':focus' ); if ( $focused.length ) { $focused[ 0 ].blur(); } } } this.currentCardName = name; card.setActive( true ); this.stackLayout.setItem( card ); if ( !this.stackLayout.continuous && previousCard ) { // This should not be necessary, since any inputs on the previous card should have been // blurred when it was hidden, but browsers are not very consistent about this. $focused = previousCard.$element.find( ':focus' ); if ( $focused.length ) { $focused[ 0 ].blur(); } } this.emit( 'set', card ); } } }; /** * Select the first selectable card. * * @chainable */ OO.ui.IndexLayout.prototype.selectFirstSelectableCard = function () { if ( !this.tabSelectWidget.getSelectedItem() ) { this.tabSelectWidget.selectItem( this.tabSelectWidget.getFirstSelectableItem() ); } return this; }; /** * PanelLayouts expand to cover the entire area of their parent. They can be configured with scrolling, padding, * and a frame, and are often used together with {@link OO.ui.StackLayout StackLayouts}. * * @example * // Example of a panel layout * var panel = new OO.ui.PanelLayout( { * expanded: false, * framed: true, * padded: true, * $content: $( '<p>A panel layout with padding and a frame.</p>' ) * } ); * $( 'body' ).append( panel.$element ); * * @class * @extends OO.ui.Layout * * @constructor * @param {Object} [config] Configuration options * @cfg {boolean} [scrollable=false] Allow vertical scrolling * @cfg {boolean} [padded=false] Add padding between the content and the edges of the panel. * @cfg {boolean} [expanded=true] Expand the panel to fill the entire parent element. * @cfg {boolean} [framed=false] Render the panel with a frame to visually separate it from outside content. */ OO.ui.PanelLayout = function OoUiPanelLayout( config ) { // Configuration initialization config = $.extend( { scrollable: false, padded: false, expanded: true, framed: false }, config ); // Parent constructor OO.ui.PanelLayout.parent.call( this, config ); // Initialization this.$element.addClass( 'oo-ui-panelLayout' ); if ( config.scrollable ) { this.$element.addClass( 'oo-ui-panelLayout-scrollable' ); } if ( config.padded ) { this.$element.addClass( 'oo-ui-panelLayout-padded' ); } if ( config.expanded ) { this.$element.addClass( 'oo-ui-panelLayout-expanded' ); } if ( config.framed ) { this.$element.addClass( 'oo-ui-panelLayout-framed' ); } }; /* Setup */ OO.inheritClass( OO.ui.PanelLayout, OO.ui.Layout ); /* Methods */ /** * Focus the panel layout * * The default implementation just focuses the first focusable element in the panel */ OO.ui.PanelLayout.prototype.focus = function () { OO.ui.findFocusable( this.$element ).focus(); }; /** * CardLayouts are used within {@link OO.ui.IndexLayout index layouts} to create cards that users can select and display * from the index's optional {@link OO.ui.TabSelectWidget tab} navigation. Cards are usually not instantiated directly, * rather extended to include the required content and functionality. * * Each card must have a unique symbolic name, which is passed to the constructor. In addition, the card's tab * item is customized (with a label) using the #setupTabItem method. See * {@link OO.ui.IndexLayout IndexLayout} for an example. * * @class * @extends OO.ui.PanelLayout * * @constructor * @param {string} name Unique symbolic name of card * @param {Object} [config] Configuration options * @cfg {jQuery|string|Function|OO.ui.HtmlSnippet} [label] Label for card's tab */ OO.ui.CardLayout = function OoUiCardLayout( name, config ) { // Allow passing positional parameters inside the config object if ( OO.isPlainObject( name ) && config === undefined ) { config = name; name = config.name; } // Configuration initialization config = $.extend( { scrollable: true }, config ); // Parent constructor OO.ui.CardLayout.parent.call( this, config ); // Properties this.name = name; this.label = config.label; this.tabItem = null; this.active = false; // Initialization this.$element.addClass( 'oo-ui-cardLayout' ); }; /* Setup */ OO.inheritClass( OO.ui.CardLayout, OO.ui.PanelLayout ); /* Events */ /** * An 'active' event is emitted when the card becomes active. Cards become active when they are * shown in a index layout that is configured to display only one card at a time. * * @event active * @param {boolean} active Card is active */ /* Methods */ /** * Get the symbolic name of the card. * * @return {string} Symbolic name of card */ OO.ui.CardLayout.prototype.getName = function () { return this.name; }; /** * Check if card is active. * * Cards become active when they are shown in a {@link OO.ui.IndexLayout index layout} that is configured to display * only one card at a time. Additional CSS is applied to the card's tab item to reflect the active state. * * @return {boolean} Card is active */ OO.ui.CardLayout.prototype.isActive = function () { return this.active; }; /** * Get tab item. * * The tab item allows users to access the card from the index's tab * navigation. The tab item itself can be customized (with a label, level, etc.) using the #setupTabItem method. * * @return {OO.ui.TabOptionWidget|null} Tab option widget */ OO.ui.CardLayout.prototype.getTabItem = function () { return this.tabItem; }; /** * Set or unset the tab item. * * Specify a {@link OO.ui.TabOptionWidget tab option} to set it, * or `null` to clear the tab item. To customize the tab item itself (e.g., to set a label or tab * level), use #setupTabItem instead of this method. * * @param {OO.ui.TabOptionWidget|null} tabItem Tab option widget, null to clear * @chainable */ OO.ui.CardLayout.prototype.setTabItem = function ( tabItem ) { this.tabItem = tabItem || null; if ( tabItem ) { this.setupTabItem(); } return this; }; /** * Set up the tab item. * * Use this method to customize the tab item (e.g., to add a label or tab level). To set or unset * the tab item itself (with a {@link OO.ui.TabOptionWidget tab option} or `null`), use * the #setTabItem method instead. * * @param {OO.ui.TabOptionWidget} tabItem Tab option widget to set up * @chainable */ OO.ui.CardLayout.prototype.setupTabItem = function () { if ( this.label ) { this.tabItem.setLabel( this.label ); } return this; }; /** * Set the card to its 'active' state. * * Cards become active when they are shown in a index layout that is configured to display only one card at a time. Additional * CSS is applied to the tab item to reflect the card's active state. Outside of the index * context, setting the active state on a card does nothing. * * @param {boolean} value Card is active * @fires active */ OO.ui.CardLayout.prototype.setActive = function ( active ) { active = !!active; if ( active !== this.active ) { this.active = active; this.$element.toggleClass( 'oo-ui-cardLayout-active', this.active ); this.emit( 'active', this.active ); } }; /** * PageLayouts are used within {@link OO.ui.BookletLayout booklet layouts} to create pages that users can select and display * from the booklet's optional {@link OO.ui.OutlineSelectWidget outline} navigation. Pages are usually not instantiated directly, * rather extended to include the required content and functionality. * * Each page must have a unique symbolic name, which is passed to the constructor. In addition, the page's outline * item is customized (with a label, outline level, etc.) using the #setupOutlineItem method. See * {@link OO.ui.BookletLayout BookletLayout} for an example. * * @class * @extends OO.ui.PanelLayout * * @constructor * @param {string} name Unique symbolic name of page * @param {Object} [config] Configuration options */ OO.ui.PageLayout = function OoUiPageLayout( name, config ) { // Allow passing positional parameters inside the config object if ( OO.isPlainObject( name ) && config === undefined ) { config = name; name = config.name; } // Configuration initialization config = $.extend( { scrollable: true }, config ); // Parent constructor OO.ui.PageLayout.parent.call( this, config ); // Properties this.name = name; this.outlineItem = null; this.active = false; // Initialization this.$element.addClass( 'oo-ui-pageLayout' ); }; /* Setup */ OO.inheritClass( OO.ui.PageLayout, OO.ui.PanelLayout ); /* Events */ /** * An 'active' event is emitted when the page becomes active. Pages become active when they are * shown in a booklet layout that is configured to display only one page at a time. * * @event active * @param {boolean} active Page is active */ /* Methods */ /** * Get the symbolic name of the page. * * @return {string} Symbolic name of page */ OO.ui.PageLayout.prototype.getName = function () { return this.name; }; /** * Check if page is active. * * Pages become active when they are shown in a {@link OO.ui.BookletLayout booklet layout} that is configured to display * only one page at a time. Additional CSS is applied to the page's outline item to reflect the active state. * * @return {boolean} Page is active */ OO.ui.PageLayout.prototype.isActive = function () { return this.active; }; /** * Get outline item. * * The outline item allows users to access the page from the booklet's outline * navigation. The outline item itself can be customized (with a label, level, etc.) using the #setupOutlineItem method. * * @return {OO.ui.OutlineOptionWidget|null} Outline option widget */ OO.ui.PageLayout.prototype.getOutlineItem = function () { return this.outlineItem; }; /** * Set or unset the outline item. * * Specify an {@link OO.ui.OutlineOptionWidget outline option} to set it, * or `null` to clear the outline item. To customize the outline item itself (e.g., to set a label or outline * level), use #setupOutlineItem instead of this method. * * @param {OO.ui.OutlineOptionWidget|null} outlineItem Outline option widget, null to clear * @chainable */ OO.ui.PageLayout.prototype.setOutlineItem = function ( outlineItem ) { this.outlineItem = outlineItem || null; if ( outlineItem ) { this.setupOutlineItem(); } return this; }; /** * Set up the outline item. * * Use this method to customize the outline item (e.g., to add a label or outline level). To set or unset * the outline item itself (with an {@link OO.ui.OutlineOptionWidget outline option} or `null`), use * the #setOutlineItem method instead. * * @param {OO.ui.OutlineOptionWidget} outlineItem Outline option widget to set up * @chainable */ OO.ui.PageLayout.prototype.setupOutlineItem = function () { return this; }; /** * Set the page to its 'active' state. * * Pages become active when they are shown in a booklet layout that is configured to display only one page at a time. Additional * CSS is applied to the outline item to reflect the page's active state. Outside of the booklet * context, setting the active state on a page does nothing. * * @param {boolean} value Page is active * @fires active */ OO.ui.PageLayout.prototype.setActive = function ( active ) { active = !!active; if ( active !== this.active ) { this.active = active; this.$element.toggleClass( 'oo-ui-pageLayout-active', active ); this.emit( 'active', this.active ); } }; /** * StackLayouts contain a series of {@link OO.ui.PanelLayout panel layouts}. By default, only one panel is displayed * at a time, though the stack layout can also be configured to show all contained panels, one after another, * by setting the #continuous option to 'true'. * * @example * // A stack layout with two panels, configured to be displayed continously * var myStack = new OO.ui.StackLayout( { * items: [ * new OO.ui.PanelLayout( { * $content: $( '<p>Panel One</p>' ), * padded: true, * framed: true * } ), * new OO.ui.PanelLayout( { * $content: $( '<p>Panel Two</p>' ), * padded: true, * framed: true * } ) * ], * continuous: true * } ); * $( 'body' ).append( myStack.$element ); * * @class * @extends OO.ui.PanelLayout * @mixins OO.ui.mixin.GroupElement * * @constructor * @param {Object} [config] Configuration options * @cfg {boolean} [continuous=false] Show all panels, one after another. By default, only one panel is displayed at a time. * @cfg {OO.ui.Layout[]} [items] Panel layouts to add to the stack layout. */ OO.ui.StackLayout = function OoUiStackLayout( config ) { // Configuration initialization config = $.extend( { scrollable: true }, config ); // Parent constructor OO.ui.StackLayout.parent.call( this, config ); // Mixin constructors OO.ui.mixin.GroupElement.call( this, $.extend( {}, config, { $group: this.$element } ) ); // Properties this.currentItem = null; this.continuous = !!config.continuous; // Initialization this.$element.addClass( 'oo-ui-stackLayout' ); if ( this.continuous ) { this.$element.addClass( 'oo-ui-stackLayout-continuous' ); this.$element.on( 'scroll', OO.ui.debounce( this.onScroll.bind( this ), 250 ) ); } if ( Array.isArray( config.items ) ) { this.addItems( config.items ); } }; /* Setup */ OO.inheritClass( OO.ui.StackLayout, OO.ui.PanelLayout ); OO.mixinClass( OO.ui.StackLayout, OO.ui.mixin.GroupElement ); /* Events */ /** * A 'set' event is emitted when panels are {@link #addItems added}, {@link #removeItems removed}, * {@link #clearItems cleared} or {@link #setItem displayed}. * * @event set * @param {OO.ui.Layout|null} item Current panel or `null` if no panel is shown */ /** * When used in continuous mode, this event is emitted when the user scrolls down * far enough such that currentItem is no longer visible. * * @event visibleItemChange * @param {OO.ui.PanelLayout} panel The next visible item in the layout */ /* Methods */ /** * Handle scroll events from the layout element * * @param {jQuery.Event} e * @fires visibleItemChange */ OO.ui.StackLayout.prototype.onScroll = function () { var currentRect, len = this.items.length, currentIndex = this.items.indexOf( this.currentItem ), newIndex = currentIndex, containerRect = this.$element[ 0 ].getBoundingClientRect(); if ( !containerRect || ( !containerRect.top && !containerRect.bottom ) ) { // Can't get bounding rect, possibly not attached. return; } function getRect( item ) { return item.$element[ 0 ].getBoundingClientRect(); } function isVisible( item ) { var rect = getRect( item ); return rect.bottom > containerRect.top && rect.top < containerRect.bottom; } currentRect = getRect( this.currentItem ); if ( currentRect.bottom < containerRect.top ) { // Scrolled down past current item while ( ++newIndex < len ) { if ( isVisible( this.items[ newIndex ] ) ) { break; } } } else if ( currentRect.top > containerRect.bottom ) { // Scrolled up past current item while ( --newIndex >= 0 ) { if ( isVisible( this.items[ newIndex ] ) ) { break; } } } if ( newIndex !== currentIndex ) { this.emit( 'visibleItemChange', this.items[ newIndex ] ); } }; /** * Get the current panel. * * @return {OO.ui.Layout|null} */ OO.ui.StackLayout.prototype.getCurrentItem = function () { return this.currentItem; }; /** * Unset the current item. * * @private * @param {OO.ui.StackLayout} layout * @fires set */ OO.ui.StackLayout.prototype.unsetCurrentItem = function () { var prevItem = this.currentItem; if ( prevItem === null ) { return; } this.currentItem = null; this.emit( 'set', null ); }; /** * Add panel layouts to the stack layout. * * Panels will be added to the end of the stack layout array unless the optional index parameter specifies a different * insertion point. Adding a panel that is already in the stack will move it to the end of the array or the point specified * by the index. * * @param {OO.ui.Layout[]} items Panels to add * @param {number} [index] Index of the insertion point * @chainable */ OO.ui.StackLayout.prototype.addItems = function ( items, index ) { // Update the visibility this.updateHiddenState( items, this.currentItem ); // Mixin method OO.ui.mixin.GroupElement.prototype.addItems.call( this, items, index ); if ( !this.currentItem && items.length ) { this.setItem( items[ 0 ] ); } return this; }; /** * Remove the specified panels from the stack layout. * * Removed panels are detached from the DOM, not removed, so that they may be reused. To remove all panels, * you may wish to use the #clearItems method instead. * * @param {OO.ui.Layout[]} items Panels to remove * @chainable * @fires set */ OO.ui.StackLayout.prototype.removeItems = function ( items ) { // Mixin method OO.ui.mixin.GroupElement.prototype.removeItems.call( this, items ); if ( items.indexOf( this.currentItem ) !== -1 ) { if ( this.items.length ) { this.setItem( this.items[ 0 ] ); } else { this.unsetCurrentItem(); } } return this; }; /** * Clear all panels from the stack layout. * * Cleared panels are detached from the DOM, not removed, so that they may be reused. To remove only * a subset of panels, use the #removeItems method. * * @chainable * @fires set */ OO.ui.StackLayout.prototype.clearItems = function () { this.unsetCurrentItem(); OO.ui.mixin.GroupElement.prototype.clearItems.call( this ); return this; }; /** * Show the specified panel. * * If another panel is currently displayed, it will be hidden. * * @param {OO.ui.Layout} item Panel to show * @chainable * @fires set */ OO.ui.StackLayout.prototype.setItem = function ( item ) { if ( item !== this.currentItem ) { this.updateHiddenState( this.items, item ); if ( this.items.indexOf( item ) !== -1 ) { this.currentItem = item; this.emit( 'set', item ); } else { this.unsetCurrentItem(); } } return this; }; /** * Update the visibility of all items in case of non-continuous view. * * Ensure all items are hidden except for the selected one. * This method does nothing when the stack is continuous. * * @private * @param {OO.ui.Layout[]} items Item list iterate over * @param {OO.ui.Layout} [selectedItem] Selected item to show */ OO.ui.StackLayout.prototype.updateHiddenState = function ( items, selectedItem ) { var i, len; if ( !this.continuous ) { for ( i = 0, len = items.length; i < len; i++ ) { if ( !selectedItem || selectedItem !== items[ i ] ) { items[ i ].$element.addClass( 'oo-ui-element-hidden' ); } } if ( selectedItem ) { selectedItem.$element.removeClass( 'oo-ui-element-hidden' ); } } }; /** * HorizontalLayout arranges its contents in a single line (using `display: inline-block` for its * items), with small margins between them. Convenient when you need to put a number of block-level * widgets on a single line next to each other. * * Note that inline elements, such as OO.ui.ButtonWidgets, do not need this wrapper. * * @example * // HorizontalLayout with a text input and a label * var layout = new OO.ui.HorizontalLayout( { * items: [ * new OO.ui.LabelWidget( { label: 'Label' } ), * new OO.ui.TextInputWidget( { value: 'Text' } ) * ] * } ); * $( 'body' ).append( layout.$element ); * * @class * @extends OO.ui.Layout * @mixins OO.ui.mixin.GroupElement * * @constructor * @param {Object} [config] Configuration options * @cfg {OO.ui.Widget[]|OO.ui.Layout[]} [items] Widgets or other layouts to add to the layout. */ OO.ui.HorizontalLayout = function OoUiHorizontalLayout( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.HorizontalLayout.parent.call( this, config ); // Mixin constructors OO.ui.mixin.GroupElement.call( this, $.extend( {}, config, { $group: this.$element } ) ); // Initialization this.$element.addClass( 'oo-ui-horizontalLayout' ); if ( Array.isArray( config.items ) ) { this.addItems( config.items ); } }; /* Setup */ OO.inheritClass( OO.ui.HorizontalLayout, OO.ui.Layout ); OO.mixinClass( OO.ui.HorizontalLayout, OO.ui.mixin.GroupElement ); /** * BarToolGroups are one of three types of {@link OO.ui.ToolGroup toolgroups} that are used to * create {@link OO.ui.Toolbar toolbars} (the other types of groups are {@link OO.ui.MenuToolGroup MenuToolGroup} * and {@link OO.ui.ListToolGroup ListToolGroup}). The {@link OO.ui.Tool tools} in a BarToolGroup are * displayed by icon in a single row. The title of the tool is displayed when users move the mouse over * the tool. * * BarToolGroups are created by a {@link OO.ui.ToolGroupFactory tool group factory} when the toolbar is * set up. * * @example * // Example of a BarToolGroup with two tools * var toolFactory = new OO.ui.ToolFactory(); * var toolGroupFactory = new OO.ui.ToolGroupFactory(); * var toolbar = new OO.ui.Toolbar( toolFactory, toolGroupFactory ); * * // We will be placing status text in this element when tools are used * var $area = $( '<p>' ).text( 'Example of a BarToolGroup with two tools.' ); * * // Define the tools that we're going to place in our toolbar * * // Create a class inheriting from OO.ui.Tool * function PictureTool() { * PictureTool.parent.apply( this, arguments ); * } * OO.inheritClass( PictureTool, OO.ui.Tool ); * // Each tool must have a 'name' (used as an internal identifier, see later) and at least one * // of 'icon' and 'title' (displayed icon and text). * PictureTool.static.name = 'picture'; * PictureTool.static.icon = 'picture'; * PictureTool.static.title = 'Insert picture'; * // Defines the action that will happen when this tool is selected (clicked). * PictureTool.prototype.onSelect = function () { * $area.text( 'Picture tool clicked!' ); * // Never display this tool as "active" (selected). * this.setActive( false ); * }; * // Make this tool available in our toolFactory and thus our toolbar * toolFactory.register( PictureTool ); * * // This is a PopupTool. Rather than having a custom 'onSelect' action, it will display a * // little popup window (a PopupWidget). * function HelpTool( toolGroup, config ) { * OO.ui.PopupTool.call( this, toolGroup, $.extend( { popup: { * padded: true, * label: 'Help', * head: true * } }, config ) ); * this.popup.$body.append( '<p>I am helpful!</p>' ); * } * OO.inheritClass( HelpTool, OO.ui.PopupTool ); * HelpTool.static.name = 'help'; * HelpTool.static.icon = 'help'; * HelpTool.static.title = 'Help'; * toolFactory.register( HelpTool ); * * // Finally define which tools and in what order appear in the toolbar. Each tool may only be * // used once (but not all defined tools must be used). * toolbar.setup( [ * { * // 'bar' tool groups display tools by icon only * type: 'bar', * include: [ 'picture', 'help' ] * } * ] ); * * // Create some UI around the toolbar and place it in the document * var frame = new OO.ui.PanelLayout( { * expanded: false, * framed: true * } ); * var contentFrame = new OO.ui.PanelLayout( { * expanded: false, * padded: true * } ); * frame.$element.append( * toolbar.$element, * contentFrame.$element.append( $area ) * ); * $( 'body' ).append( frame.$element ); * * // Here is where the toolbar is actually built. This must be done after inserting it into the * // document. * toolbar.initialize(); * * For more information about how to add tools to a bar tool group, please see {@link OO.ui.ToolGroup toolgroup}. * For more information about toolbars in general, please see the [OOjs UI documentation on MediaWiki][1]. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Toolbars * * @class * @extends OO.ui.ToolGroup * * @constructor * @param {OO.ui.Toolbar} toolbar * @param {Object} [config] Configuration options */ OO.ui.BarToolGroup = function OoUiBarToolGroup( toolbar, config ) { // Allow passing positional parameters inside the config object if ( OO.isPlainObject( toolbar ) && config === undefined ) { config = toolbar; toolbar = config.toolbar; } // Parent constructor OO.ui.BarToolGroup.parent.call( this, toolbar, config ); // Initialization this.$element.addClass( 'oo-ui-barToolGroup' ); }; /* Setup */ OO.inheritClass( OO.ui.BarToolGroup, OO.ui.ToolGroup ); /* Static Properties */ OO.ui.BarToolGroup.static.titleTooltips = true; OO.ui.BarToolGroup.static.accelTooltips = true; OO.ui.BarToolGroup.static.name = 'bar'; /** * PopupToolGroup is an abstract base class used by both {@link OO.ui.MenuToolGroup MenuToolGroup} * and {@link OO.ui.ListToolGroup ListToolGroup} to provide a popup--an overlaid menu or list of tools with an * optional icon and label. This class can be used for other base classes that also use this functionality. * * @abstract * @class * @extends OO.ui.ToolGroup * @mixins OO.ui.mixin.IconElement * @mixins OO.ui.mixin.IndicatorElement * @mixins OO.ui.mixin.LabelElement * @mixins OO.ui.mixin.TitledElement * @mixins OO.ui.mixin.ClippableElement * @mixins OO.ui.mixin.TabIndexedElement * * @constructor * @param {OO.ui.Toolbar} toolbar * @param {Object} [config] Configuration options * @cfg {string} [header] Text to display at the top of the popup */ OO.ui.PopupToolGroup = function OoUiPopupToolGroup( toolbar, config ) { // Allow passing positional parameters inside the config object if ( OO.isPlainObject( toolbar ) && config === undefined ) { config = toolbar; toolbar = config.toolbar; } // Configuration initialization config = config || {}; // Parent constructor OO.ui.PopupToolGroup.parent.call( this, toolbar, config ); // Properties this.active = false; this.dragging = false; this.onBlurHandler = this.onBlur.bind( this ); this.$handle = $( '<span>' ); // Mixin constructors OO.ui.mixin.IconElement.call( this, config ); OO.ui.mixin.IndicatorElement.call( this, config ); OO.ui.mixin.LabelElement.call( this, config ); OO.ui.mixin.TitledElement.call( this, config ); OO.ui.mixin.ClippableElement.call( this, $.extend( {}, config, { $clippable: this.$group } ) ); OO.ui.mixin.TabIndexedElement.call( this, $.extend( {}, config, { $tabIndexed: this.$handle } ) ); // Events this.$handle.on( { keydown: this.onHandleMouseKeyDown.bind( this ), keyup: this.onHandleMouseKeyUp.bind( this ), mousedown: this.onHandleMouseKeyDown.bind( this ), mouseup: this.onHandleMouseKeyUp.bind( this ) } ); // Initialization this.$handle .addClass( 'oo-ui-popupToolGroup-handle' ) .append( this.$icon, this.$label, this.$indicator ); // If the pop-up should have a header, add it to the top of the toolGroup. // Note: If this feature is useful for other widgets, we could abstract it into an // OO.ui.HeaderedElement mixin constructor. if ( config.header !== undefined ) { this.$group .prepend( $( '<span>' ) .addClass( 'oo-ui-popupToolGroup-header' ) .text( config.header ) ); } this.$element .addClass( 'oo-ui-popupToolGroup' ) .prepend( this.$handle ); }; /* Setup */ OO.inheritClass( OO.ui.PopupToolGroup, OO.ui.ToolGroup ); OO.mixinClass( OO.ui.PopupToolGroup, OO.ui.mixin.IconElement ); OO.mixinClass( OO.ui.PopupToolGroup, OO.ui.mixin.IndicatorElement ); OO.mixinClass( OO.ui.PopupToolGroup, OO.ui.mixin.LabelElement ); OO.mixinClass( OO.ui.PopupToolGroup, OO.ui.mixin.TitledElement ); OO.mixinClass( OO.ui.PopupToolGroup, OO.ui.mixin.ClippableElement ); OO.mixinClass( OO.ui.PopupToolGroup, OO.ui.mixin.TabIndexedElement ); /* Methods */ /** * @inheritdoc */ OO.ui.PopupToolGroup.prototype.setDisabled = function () { // Parent method OO.ui.PopupToolGroup.parent.prototype.setDisabled.apply( this, arguments ); if ( this.isDisabled() && this.isElementAttached() ) { this.setActive( false ); } }; /** * Handle focus being lost. * * The event is actually generated from a mouseup/keyup, so it is not a normal blur event object. * * @protected * @param {jQuery.Event} e Mouse up or key up event */ OO.ui.PopupToolGroup.prototype.onBlur = function ( e ) { // Only deactivate when clicking outside the dropdown element if ( $( e.target ).closest( '.oo-ui-popupToolGroup' )[ 0 ] !== this.$element[ 0 ] ) { this.setActive( false ); } }; /** * @inheritdoc */ OO.ui.PopupToolGroup.prototype.onMouseKeyUp = function ( e ) { // Only close toolgroup when a tool was actually selected if ( !this.isDisabled() && this.pressed && this.pressed === this.getTargetTool( e ) && ( e.which === 1 || e.which === OO.ui.Keys.SPACE || e.which === OO.ui.Keys.ENTER ) ) { this.setActive( false ); } return OO.ui.PopupToolGroup.parent.prototype.onMouseKeyUp.call( this, e ); }; /** * Handle mouse up and key up events. * * @protected * @param {jQuery.Event} e Mouse up or key up event */ OO.ui.PopupToolGroup.prototype.onHandleMouseKeyUp = function ( e ) { if ( !this.isDisabled() && ( e.which === 1 || e.which === OO.ui.Keys.SPACE || e.which === OO.ui.Keys.ENTER ) ) { return false; } }; /** * Handle mouse down and key down events. * * @protected * @param {jQuery.Event} e Mouse down or key down event */ OO.ui.PopupToolGroup.prototype.onHandleMouseKeyDown = function ( e ) { if ( !this.isDisabled() && ( e.which === 1 || e.which === OO.ui.Keys.SPACE || e.which === OO.ui.Keys.ENTER ) ) { this.setActive( !this.active ); return false; } }; /** * Switch into 'active' mode. * * When active, the popup is visible. A mouseup event anywhere in the document will trigger * deactivation. */ OO.ui.PopupToolGroup.prototype.setActive = function ( value ) { var containerWidth, containerLeft; value = !!value; if ( this.active !== value ) { this.active = value; if ( value ) { OO.ui.addCaptureEventListener( this.getElementDocument(), 'mouseup', this.onBlurHandler ); OO.ui.addCaptureEventListener( this.getElementDocument(), 'keyup', this.onBlurHandler ); this.$clippable.css( 'left', '' ); // Try anchoring the popup to the left first this.$element.addClass( 'oo-ui-popupToolGroup-active oo-ui-popupToolGroup-left' ); this.toggleClipping( true ); if ( this.isClippedHorizontally() ) { // Anchoring to the left caused the popup to clip, so anchor it to the right instead this.toggleClipping( false ); this.$element .removeClass( 'oo-ui-popupToolGroup-left' ) .addClass( 'oo-ui-popupToolGroup-right' ); this.toggleClipping( true ); } if ( this.isClippedHorizontally() ) { // Anchoring to the right also caused the popup to clip, so just make it fill the container containerWidth = this.$clippableScrollableContainer.width(); containerLeft = this.$clippableScrollableContainer.offset().left; this.toggleClipping( false ); this.$element.removeClass( 'oo-ui-popupToolGroup-right' ); this.$clippable.css( { left: -( this.$element.offset().left - containerLeft ), width: containerWidth } ); } } else { OO.ui.removeCaptureEventListener( this.getElementDocument(), 'mouseup', this.onBlurHandler ); OO.ui.removeCaptureEventListener( this.getElementDocument(), 'keyup', this.onBlurHandler ); this.$element.removeClass( 'oo-ui-popupToolGroup-active oo-ui-popupToolGroup-left oo-ui-popupToolGroup-right' ); this.toggleClipping( false ); } } }; /** * ListToolGroups are one of three types of {@link OO.ui.ToolGroup toolgroups} that are used to * create {@link OO.ui.Toolbar toolbars} (the other types of groups are {@link OO.ui.MenuToolGroup MenuToolGroup} * and {@link OO.ui.BarToolGroup BarToolGroup}). The {@link OO.ui.Tool tools} in a ListToolGroup are displayed * by label in a dropdown menu. The title of the tool is used as the label text. The menu itself can be configured * with a label, icon, indicator, header, and title. * * ListToolGroups can be configured to be expanded and collapsed. Collapsed lists will have a ‘More’ option that * users can select to see the full list of tools. If a collapsed toolgroup is expanded, a ‘Fewer’ option permits * users to collapse the list again. * * ListToolGroups are created by a {@link OO.ui.ToolGroupFactory toolgroup factory} when the toolbar is set up. The factory * requires the ListToolGroup's symbolic name, 'list', which is specified along with the other configurations. For more * information about how to add tools to a ListToolGroup, please see {@link OO.ui.ToolGroup toolgroup}. * * @example * // Example of a ListToolGroup * var toolFactory = new OO.ui.ToolFactory(); * var toolGroupFactory = new OO.ui.ToolGroupFactory(); * var toolbar = new OO.ui.Toolbar( toolFactory, toolGroupFactory ); * * // Configure and register two tools * function SettingsTool() { * SettingsTool.parent.apply( this, arguments ); * } * OO.inheritClass( SettingsTool, OO.ui.Tool ); * SettingsTool.static.name = 'settings'; * SettingsTool.static.icon = 'settings'; * SettingsTool.static.title = 'Change settings'; * SettingsTool.prototype.onSelect = function () { * this.setActive( false ); * }; * toolFactory.register( SettingsTool ); * // Register two more tools, nothing interesting here * function StuffTool() { * StuffTool.parent.apply( this, arguments ); * } * OO.inheritClass( StuffTool, OO.ui.Tool ); * StuffTool.static.name = 'stuff'; * StuffTool.static.icon = 'ellipsis'; * StuffTool.static.title = 'Change the world'; * StuffTool.prototype.onSelect = function () { * this.setActive( false ); * }; * toolFactory.register( StuffTool ); * toolbar.setup( [ * { * // Configurations for list toolgroup. * type: 'list', * label: 'ListToolGroup', * indicator: 'down', * icon: 'picture', * title: 'This is the title, displayed when user moves the mouse over the list toolgroup', * header: 'This is the header', * include: [ 'settings', 'stuff' ], * allowCollapse: ['stuff'] * } * ] ); * * // Create some UI around the toolbar and place it in the document * var frame = new OO.ui.PanelLayout( { * expanded: false, * framed: true * } ); * frame.$element.append( * toolbar.$element * ); * $( 'body' ).append( frame.$element ); * // Build the toolbar. This must be done after the toolbar has been appended to the document. * toolbar.initialize(); * * For more information about toolbars in general, please see the [OOjs UI documentation on MediaWiki][1]. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Toolbars * * @class * @extends OO.ui.PopupToolGroup * * @constructor * @param {OO.ui.Toolbar} toolbar * @param {Object} [config] Configuration options * @cfg {Array} [allowCollapse] Allow the specified tools to be collapsed. By default, collapsible tools * will only be displayed if users click the ‘More’ option displayed at the bottom of the list. If * the list is expanded, a ‘Fewer’ option permits users to collapse the list again. Any tools that * are included in the toolgroup, but are not designated as collapsible, will always be displayed. * To open a collapsible list in its expanded state, set #expanded to 'true'. * @cfg {Array} [forceExpand] Expand the specified tools. All other tools will be designated as collapsible. * Unless #expanded is set to true, the collapsible tools will be collapsed when the list is first opened. * @cfg {boolean} [expanded=false] Expand collapsible tools. This config is only relevant if tools have * been designated as collapsible. When expanded is set to true, all tools in the group will be displayed * when the list is first opened. Users can collapse the list with a ‘Fewer’ option at the bottom. */ OO.ui.ListToolGroup = function OoUiListToolGroup( toolbar, config ) { // Allow passing positional parameters inside the config object if ( OO.isPlainObject( toolbar ) && config === undefined ) { config = toolbar; toolbar = config.toolbar; } // Configuration initialization config = config || {}; // Properties (must be set before parent constructor, which calls #populate) this.allowCollapse = config.allowCollapse; this.forceExpand = config.forceExpand; this.expanded = config.expanded !== undefined ? config.expanded : false; this.collapsibleTools = []; // Parent constructor OO.ui.ListToolGroup.parent.call( this, toolbar, config ); // Initialization this.$element.addClass( 'oo-ui-listToolGroup' ); }; /* Setup */ OO.inheritClass( OO.ui.ListToolGroup, OO.ui.PopupToolGroup ); /* Static Properties */ OO.ui.ListToolGroup.static.name = 'list'; /* Methods */ /** * @inheritdoc */ OO.ui.ListToolGroup.prototype.populate = function () { var i, len, allowCollapse = []; OO.ui.ListToolGroup.parent.prototype.populate.call( this ); // Update the list of collapsible tools if ( this.allowCollapse !== undefined ) { allowCollapse = this.allowCollapse; } else if ( this.forceExpand !== undefined ) { allowCollapse = OO.simpleArrayDifference( Object.keys( this.tools ), this.forceExpand ); } this.collapsibleTools = []; for ( i = 0, len = allowCollapse.length; i < len; i++ ) { if ( this.tools[ allowCollapse[ i ] ] !== undefined ) { this.collapsibleTools.push( this.tools[ allowCollapse[ i ] ] ); } } // Keep at the end, even when tools are added this.$group.append( this.getExpandCollapseTool().$element ); this.getExpandCollapseTool().toggle( this.collapsibleTools.length !== 0 ); this.updateCollapsibleState(); }; OO.ui.ListToolGroup.prototype.getExpandCollapseTool = function () { var ExpandCollapseTool; if ( this.expandCollapseTool === undefined ) { ExpandCollapseTool = function () { ExpandCollapseTool.parent.apply( this, arguments ); }; OO.inheritClass( ExpandCollapseTool, OO.ui.Tool ); ExpandCollapseTool.prototype.onSelect = function () { this.toolGroup.expanded = !this.toolGroup.expanded; this.toolGroup.updateCollapsibleState(); this.setActive( false ); }; ExpandCollapseTool.prototype.onUpdateState = function () { // Do nothing. Tool interface requires an implementation of this function. }; ExpandCollapseTool.static.name = 'more-fewer'; this.expandCollapseTool = new ExpandCollapseTool( this ); } return this.expandCollapseTool; }; /** * @inheritdoc */ OO.ui.ListToolGroup.prototype.onMouseKeyUp = function ( e ) { // Do not close the popup when the user wants to show more/fewer tools if ( $( e.target ).closest( '.oo-ui-tool-name-more-fewer' ).length && ( e.which === 1 || e.which === OO.ui.Keys.SPACE || e.which === OO.ui.Keys.ENTER ) ) { // HACK: Prevent the popup list from being hidden. Skip the PopupToolGroup implementation (which // hides the popup list when a tool is selected) and call ToolGroup's implementation directly. return OO.ui.ListToolGroup.parent.parent.prototype.onMouseKeyUp.call( this, e ); } else { return OO.ui.ListToolGroup.parent.prototype.onMouseKeyUp.call( this, e ); } }; OO.ui.ListToolGroup.prototype.updateCollapsibleState = function () { var i, len; this.getExpandCollapseTool() .setIcon( this.expanded ? 'collapse' : 'expand' ) .setTitle( OO.ui.msg( this.expanded ? 'ooui-toolgroup-collapse' : 'ooui-toolgroup-expand' ) ); for ( i = 0, len = this.collapsibleTools.length; i < len; i++ ) { this.collapsibleTools[ i ].toggle( this.expanded ); } }; /** * MenuToolGroups are one of three types of {@link OO.ui.ToolGroup toolgroups} that are used to * create {@link OO.ui.Toolbar toolbars} (the other types of groups are {@link OO.ui.BarToolGroup BarToolGroup} * and {@link OO.ui.ListToolGroup ListToolGroup}). MenuToolGroups contain selectable {@link OO.ui.Tool tools}, * which are displayed by label in a dropdown menu. The tool's title is used as the label text, and the * menu label is updated to reflect which tool or tools are currently selected. If no tools are selected, * the menu label is empty. The menu can be configured with an indicator, icon, title, and/or header. * * MenuToolGroups are created by a {@link OO.ui.ToolGroupFactory tool group factory} when the toolbar * is set up. Note that all tools must define an {@link OO.ui.Tool#onUpdateState onUpdateState} method if * a MenuToolGroup is used. * * @example * // Example of a MenuToolGroup * var toolFactory = new OO.ui.ToolFactory(); * var toolGroupFactory = new OO.ui.ToolGroupFactory(); * var toolbar = new OO.ui.Toolbar( toolFactory, toolGroupFactory ); * * // We will be placing status text in this element when tools are used * var $area = $( '<p>' ).text( 'An example of a MenuToolGroup. Select a tool from the dropdown menu.' ); * * // Define the tools that we're going to place in our toolbar * * function SettingsTool() { * SettingsTool.parent.apply( this, arguments ); * this.reallyActive = false; * } * OO.inheritClass( SettingsTool, OO.ui.Tool ); * SettingsTool.static.name = 'settings'; * SettingsTool.static.icon = 'settings'; * SettingsTool.static.title = 'Change settings'; * SettingsTool.prototype.onSelect = function () { * $area.text( 'Settings tool clicked!' ); * // Toggle the active state on each click * this.reallyActive = !this.reallyActive; * this.setActive( this.reallyActive ); * // To update the menu label * this.toolbar.emit( 'updateState' ); * }; * SettingsTool.prototype.onUpdateState = function () { * }; * toolFactory.register( SettingsTool ); * * function StuffTool() { * StuffTool.parent.apply( this, arguments ); * this.reallyActive = false; * } * OO.inheritClass( StuffTool, OO.ui.Tool ); * StuffTool.static.name = 'stuff'; * StuffTool.static.icon = 'ellipsis'; * StuffTool.static.title = 'More stuff'; * StuffTool.prototype.onSelect = function () { * $area.text( 'More stuff tool clicked!' ); * // Toggle the active state on each click * this.reallyActive = !this.reallyActive; * this.setActive( this.reallyActive ); * // To update the menu label * this.toolbar.emit( 'updateState' ); * }; * StuffTool.prototype.onUpdateState = function () { * }; * toolFactory.register( StuffTool ); * * // Finally define which tools and in what order appear in the toolbar. Each tool may only be * // used once (but not all defined tools must be used). * toolbar.setup( [ * { * type: 'menu', * header: 'This is the (optional) header', * title: 'This is the (optional) title', * indicator: 'down', * include: [ 'settings', 'stuff' ] * } * ] ); * * // Create some UI around the toolbar and place it in the document * var frame = new OO.ui.PanelLayout( { * expanded: false, * framed: true * } ); * var contentFrame = new OO.ui.PanelLayout( { * expanded: false, * padded: true * } ); * frame.$element.append( * toolbar.$element, * contentFrame.$element.append( $area ) * ); * $( 'body' ).append( frame.$element ); * * // Here is where the toolbar is actually built. This must be done after inserting it into the * // document. * toolbar.initialize(); * toolbar.emit( 'updateState' ); * * For more information about how to add tools to a MenuToolGroup, please see {@link OO.ui.ToolGroup toolgroup}. * For more information about toolbars in general, please see the [OOjs UI documentation on MediaWiki] [1]. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Toolbars * * @class * @extends OO.ui.PopupToolGroup * * @constructor * @param {OO.ui.Toolbar} toolbar * @param {Object} [config] Configuration options */ OO.ui.MenuToolGroup = function OoUiMenuToolGroup( toolbar, config ) { // Allow passing positional parameters inside the config object if ( OO.isPlainObject( toolbar ) && config === undefined ) { config = toolbar; toolbar = config.toolbar; } // Configuration initialization config = config || {}; // Parent constructor OO.ui.MenuToolGroup.parent.call( this, toolbar, config ); // Events this.toolbar.connect( this, { updateState: 'onUpdateState' } ); // Initialization this.$element.addClass( 'oo-ui-menuToolGroup' ); }; /* Setup */ OO.inheritClass( OO.ui.MenuToolGroup, OO.ui.PopupToolGroup ); /* Static Properties */ OO.ui.MenuToolGroup.static.name = 'menu'; /* Methods */ /** * Handle the toolbar state being updated. * * When the state changes, the title of each active item in the menu will be joined together and * used as a label for the group. The label will be empty if none of the items are active. * * @private */ OO.ui.MenuToolGroup.prototype.onUpdateState = function () { var name, labelTexts = []; for ( name in this.tools ) { if ( this.tools[ name ].isActive() ) { labelTexts.push( this.tools[ name ].getTitle() ); } } this.setLabel( labelTexts.join( ', ' ) || ' ' ); }; /** * Popup tools open a popup window when they are selected from the {@link OO.ui.Toolbar toolbar}. Each popup tool is configured * with a static name, title, and icon, as well with as any popup configurations. Unlike other tools, popup tools do not require that developers specify * an #onSelect or #onUpdateState method, as these methods have been implemented already. * * // Example of a popup tool. When selected, a popup tool displays * // a popup window. * function HelpTool( toolGroup, config ) { * OO.ui.PopupTool.call( this, toolGroup, $.extend( { popup: { * padded: true, * label: 'Help', * head: true * } }, config ) ); * this.popup.$body.append( '<p>I am helpful!</p>' ); * }; * OO.inheritClass( HelpTool, OO.ui.PopupTool ); * HelpTool.static.name = 'help'; * HelpTool.static.icon = 'help'; * HelpTool.static.title = 'Help'; * toolFactory.register( HelpTool ); * * For an example of a toolbar that contains a popup tool, see {@link OO.ui.Toolbar toolbars}. For more information about * toolbars in genreral, please see the [OOjs UI documentation on MediaWiki][1]. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Toolbars * * @abstract * @class * @extends OO.ui.Tool * @mixins OO.ui.mixin.PopupElement * * @constructor * @param {OO.ui.ToolGroup} toolGroup * @param {Object} [config] Configuration options */ OO.ui.PopupTool = function OoUiPopupTool( toolGroup, config ) { // Allow passing positional parameters inside the config object if ( OO.isPlainObject( toolGroup ) && config === undefined ) { config = toolGroup; toolGroup = config.toolGroup; } // Parent constructor OO.ui.PopupTool.parent.call( this, toolGroup, config ); // Mixin constructors OO.ui.mixin.PopupElement.call( this, config ); // Initialization this.$element .addClass( 'oo-ui-popupTool' ) .append( this.popup.$element ); }; /* Setup */ OO.inheritClass( OO.ui.PopupTool, OO.ui.Tool ); OO.mixinClass( OO.ui.PopupTool, OO.ui.mixin.PopupElement ); /* Methods */ /** * Handle the tool being selected. * * @inheritdoc */ OO.ui.PopupTool.prototype.onSelect = function () { if ( !this.isDisabled() ) { this.popup.toggle(); } this.setActive( false ); return false; }; /** * Handle the toolbar state being updated. * * @inheritdoc */ OO.ui.PopupTool.prototype.onUpdateState = function () { this.setActive( false ); }; /** * A ToolGroupTool is a special sort of tool that can contain other {@link OO.ui.Tool tools} * and {@link OO.ui.ToolGroup toolgroups}. The ToolGroupTool was specifically designed to be used * inside a {@link OO.ui.BarToolGroup bar} toolgroup to provide access to additional tools from * the bar item. Included tools will be displayed in a dropdown {@link OO.ui.ListToolGroup list} * when the ToolGroupTool is selected. * * // Example: ToolGroupTool with two nested tools, 'setting1' and 'setting2', defined elsewhere. * * function SettingsTool() { * SettingsTool.parent.apply( this, arguments ); * }; * OO.inheritClass( SettingsTool, OO.ui.ToolGroupTool ); * SettingsTool.static.name = 'settings'; * SettingsTool.static.title = 'Change settings'; * SettingsTool.static.groupConfig = { * icon: 'settings', * label: 'ToolGroupTool', * include: [ 'setting1', 'setting2' ] * }; * toolFactory.register( SettingsTool ); * * For more information, please see the [OOjs UI documentation on MediaWiki][1]. * * Please note that this implementation is subject to change per [T74159] [2]. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Toolbars#ToolGroupTool * [2]: https://phabricator.wikimedia.org/T74159 * * @abstract * @class * @extends OO.ui.Tool * * @constructor * @param {OO.ui.ToolGroup} toolGroup * @param {Object} [config] Configuration options */ OO.ui.ToolGroupTool = function OoUiToolGroupTool( toolGroup, config ) { // Allow passing positional parameters inside the config object if ( OO.isPlainObject( toolGroup ) && config === undefined ) { config = toolGroup; toolGroup = config.toolGroup; } // Parent constructor OO.ui.ToolGroupTool.parent.call( this, toolGroup, config ); // Properties this.innerToolGroup = this.createGroup( this.constructor.static.groupConfig ); // Events this.innerToolGroup.connect( this, { disable: 'onToolGroupDisable' } ); // Initialization this.$link.remove(); this.$element .addClass( 'oo-ui-toolGroupTool' ) .append( this.innerToolGroup.$element ); }; /* Setup */ OO.inheritClass( OO.ui.ToolGroupTool, OO.ui.Tool ); /* Static Properties */ /** * Toolgroup configuration. * * The toolgroup configuration consists of the tools to include, as well as an icon and label * to use for the bar item. Tools can be included by symbolic name, group, or with the * wildcard selector. Please see {@link OO.ui.ToolGroup toolgroup} for more information. * * @property {Object.<string,Array>} */ OO.ui.ToolGroupTool.static.groupConfig = {}; /* Methods */ /** * Handle the tool being selected. * * @inheritdoc */ OO.ui.ToolGroupTool.prototype.onSelect = function () { this.innerToolGroup.setActive( !this.innerToolGroup.active ); return false; }; /** * Synchronize disabledness state of the tool with the inner toolgroup. * * @private * @param {boolean} disabled Element is disabled */ OO.ui.ToolGroupTool.prototype.onToolGroupDisable = function ( disabled ) { this.setDisabled( disabled ); }; /** * Handle the toolbar state being updated. * * @inheritdoc */ OO.ui.ToolGroupTool.prototype.onUpdateState = function () { this.setActive( false ); }; /** * Build a {@link OO.ui.ToolGroup toolgroup} from the specified configuration. * * @param {Object.<string,Array>} group Toolgroup configuration. Please see {@link OO.ui.ToolGroup toolgroup} for * more information. * @return {OO.ui.ListToolGroup} */ OO.ui.ToolGroupTool.prototype.createGroup = function ( group ) { if ( group.include === '*' ) { // Apply defaults to catch-all groups if ( group.label === undefined ) { group.label = OO.ui.msg( 'ooui-toolbar-more' ); } } return this.toolbar.getToolGroupFactory().create( 'list', this.toolbar, group ); }; /** * Mixin for OO.ui.Widget subclasses to provide OO.ui.mixin.GroupElement. * * Use together with OO.ui.mixin.ItemWidget to make disabled state inheritable. * * @private * @abstract * @class * @extends OO.ui.mixin.GroupElement * * @constructor * @param {Object} [config] Configuration options */ OO.ui.mixin.GroupWidget = function OoUiMixinGroupWidget( config ) { // Parent constructor OO.ui.mixin.GroupWidget.parent.call( this, config ); }; /* Setup */ OO.inheritClass( OO.ui.mixin.GroupWidget, OO.ui.mixin.GroupElement ); /* Methods */ /** * Set the disabled state of the widget. * * This will also update the disabled state of child widgets. * * @param {boolean} disabled Disable widget * @chainable */ OO.ui.mixin.GroupWidget.prototype.setDisabled = function ( disabled ) { var i, len; // Parent method // Note: Calling #setDisabled this way assumes this is mixed into an OO.ui.Widget OO.ui.Widget.prototype.setDisabled.call( this, disabled ); // During construction, #setDisabled is called before the OO.ui.mixin.GroupElement constructor if ( this.items ) { for ( i = 0, len = this.items.length; i < len; i++ ) { this.items[ i ].updateDisabled(); } } return this; }; /** * Mixin for widgets used as items in widgets that mix in OO.ui.mixin.GroupWidget. * * Item widgets have a reference to a OO.ui.mixin.GroupWidget while they are attached to the group. This * allows bidirectional communication. * * Use together with OO.ui.mixin.GroupWidget to make disabled state inheritable. * * @private * @abstract * @class * * @constructor */ OO.ui.mixin.ItemWidget = function OoUiMixinItemWidget() { // }; /* Methods */ /** * Check if widget is disabled. * * Checks parent if present, making disabled state inheritable. * * @return {boolean} Widget is disabled */ OO.ui.mixin.ItemWidget.prototype.isDisabled = function () { return this.disabled || ( this.elementGroup instanceof OO.ui.Widget && this.elementGroup.isDisabled() ); }; /** * Set group element is in. * * @param {OO.ui.mixin.GroupElement|null} group Group element, null if none * @chainable */ OO.ui.mixin.ItemWidget.prototype.setElementGroup = function ( group ) { // Parent method // Note: Calling #setElementGroup this way assumes this is mixed into an OO.ui.Element OO.ui.Element.prototype.setElementGroup.call( this, group ); // Initialize item disabled states this.updateDisabled(); return this; }; /** * OutlineControlsWidget is a set of controls for an {@link OO.ui.OutlineSelectWidget outline select widget}. * Controls include moving items up and down, removing items, and adding different kinds of items. * * **Currently, this class is only used by {@link OO.ui.BookletLayout booklet layouts}.** * * @class * @extends OO.ui.Widget * @mixins OO.ui.mixin.GroupElement * @mixins OO.ui.mixin.IconElement * * @constructor * @param {OO.ui.OutlineSelectWidget} outline Outline to control * @param {Object} [config] Configuration options * @cfg {Object} [abilities] List of abilties * @cfg {boolean} [abilities.move=true] Allow moving movable items * @cfg {boolean} [abilities.remove=true] Allow removing removable items */ OO.ui.OutlineControlsWidget = function OoUiOutlineControlsWidget( outline, config ) { // Allow passing positional parameters inside the config object if ( OO.isPlainObject( outline ) && config === undefined ) { config = outline; outline = config.outline; } // Configuration initialization config = $.extend( { icon: 'add' }, config ); // Parent constructor OO.ui.OutlineControlsWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.GroupElement.call( this, config ); OO.ui.mixin.IconElement.call( this, config ); // Properties this.outline = outline; this.$movers = $( '<div>' ); this.upButton = new OO.ui.ButtonWidget( { framed: false, icon: 'collapse', title: OO.ui.msg( 'ooui-outline-control-move-up' ) } ); this.downButton = new OO.ui.ButtonWidget( { framed: false, icon: 'expand', title: OO.ui.msg( 'ooui-outline-control-move-down' ) } ); this.removeButton = new OO.ui.ButtonWidget( { framed: false, icon: 'remove', title: OO.ui.msg( 'ooui-outline-control-remove' ) } ); this.abilities = { move: true, remove: true }; // Events outline.connect( this, { select: 'onOutlineChange', add: 'onOutlineChange', remove: 'onOutlineChange' } ); this.upButton.connect( this, { click: [ 'emit', 'move', -1 ] } ); this.downButton.connect( this, { click: [ 'emit', 'move', 1 ] } ); this.removeButton.connect( this, { click: [ 'emit', 'remove' ] } ); // Initialization this.$element.addClass( 'oo-ui-outlineControlsWidget' ); this.$group.addClass( 'oo-ui-outlineControlsWidget-items' ); this.$movers .addClass( 'oo-ui-outlineControlsWidget-movers' ) .append( this.removeButton.$element, this.upButton.$element, this.downButton.$element ); this.$element.append( this.$icon, this.$group, this.$movers ); this.setAbilities( config.abilities || {} ); }; /* Setup */ OO.inheritClass( OO.ui.OutlineControlsWidget, OO.ui.Widget ); OO.mixinClass( OO.ui.OutlineControlsWidget, OO.ui.mixin.GroupElement ); OO.mixinClass( OO.ui.OutlineControlsWidget, OO.ui.mixin.IconElement ); /* Events */ /** * @event move * @param {number} places Number of places to move */ /** * @event remove */ /* Methods */ /** * Set abilities. * * @param {Object} abilities List of abilties * @param {boolean} [abilities.move] Allow moving movable items * @param {boolean} [abilities.remove] Allow removing removable items */ OO.ui.OutlineControlsWidget.prototype.setAbilities = function ( abilities ) { var ability; for ( ability in this.abilities ) { if ( abilities[ ability ] !== undefined ) { this.abilities[ ability ] = !!abilities[ ability ]; } } this.onOutlineChange(); }; /** * @private * Handle outline change events. */ OO.ui.OutlineControlsWidget.prototype.onOutlineChange = function () { var i, len, firstMovable, lastMovable, items = this.outline.getItems(), selectedItem = this.outline.getSelectedItem(), movable = this.abilities.move && selectedItem && selectedItem.isMovable(), removable = this.abilities.remove && selectedItem && selectedItem.isRemovable(); if ( movable ) { i = -1; len = items.length; while ( ++i < len ) { if ( items[ i ].isMovable() ) { firstMovable = items[ i ]; break; } } i = len; while ( i-- ) { if ( items[ i ].isMovable() ) { lastMovable = items[ i ]; break; } } } this.upButton.setDisabled( !movable || selectedItem === firstMovable ); this.downButton.setDisabled( !movable || selectedItem === lastMovable ); this.removeButton.setDisabled( !removable ); }; /** * ToggleWidget implements basic behavior of widgets with an on/off state. * Please see OO.ui.ToggleButtonWidget and OO.ui.ToggleSwitchWidget for examples. * * @abstract * @class * @extends OO.ui.Widget * * @constructor * @param {Object} [config] Configuration options * @cfg {boolean} [value=false] The toggle’s initial on/off state. * By default, the toggle is in the 'off' state. */ OO.ui.ToggleWidget = function OoUiToggleWidget( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.ToggleWidget.parent.call( this, config ); // Properties this.value = null; // Initialization this.$element.addClass( 'oo-ui-toggleWidget' ); this.setValue( !!config.value ); }; /* Setup */ OO.inheritClass( OO.ui.ToggleWidget, OO.ui.Widget ); /* Events */ /** * @event change * * A change event is emitted when the on/off state of the toggle changes. * * @param {boolean} value Value representing the new state of the toggle */ /* Methods */ /** * Get the value representing the toggle’s state. * * @return {boolean} The on/off state of the toggle */ OO.ui.ToggleWidget.prototype.getValue = function () { return this.value; }; /** * Set the state of the toggle: `true` for 'on', `false' for 'off'. * * @param {boolean} value The state of the toggle * @fires change * @chainable */ OO.ui.ToggleWidget.prototype.setValue = function ( value ) { value = !!value; if ( this.value !== value ) { this.value = value; this.emit( 'change', value ); this.$element.toggleClass( 'oo-ui-toggleWidget-on', value ); this.$element.toggleClass( 'oo-ui-toggleWidget-off', !value ); this.$element.attr( 'aria-checked', value.toString() ); } return this; }; /** * A ButtonGroupWidget groups related buttons and is used together with OO.ui.ButtonWidget and * its subclasses. Each button in a group is addressed by a unique reference. Buttons can be added, * removed, and cleared from the group. * * @example * // Example: A ButtonGroupWidget with two buttons * var button1 = new OO.ui.PopupButtonWidget( { * label: 'Select a category', * icon: 'menu', * popup: { * $content: $( '<p>List of categories...</p>' ), * padded: true, * align: 'left' * } * } ); * var button2 = new OO.ui.ButtonWidget( { * label: 'Add item' * }); * var buttonGroup = new OO.ui.ButtonGroupWidget( { * items: [button1, button2] * } ); * $( 'body' ).append( buttonGroup.$element ); * * @class * @extends OO.ui.Widget * @mixins OO.ui.mixin.GroupElement * * @constructor * @param {Object} [config] Configuration options * @cfg {OO.ui.ButtonWidget[]} [items] Buttons to add */ OO.ui.ButtonGroupWidget = function OoUiButtonGroupWidget( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.ButtonGroupWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.GroupElement.call( this, $.extend( {}, config, { $group: this.$element } ) ); // Initialization this.$element.addClass( 'oo-ui-buttonGroupWidget' ); if ( Array.isArray( config.items ) ) { this.addItems( config.items ); } }; /* Setup */ OO.inheritClass( OO.ui.ButtonGroupWidget, OO.ui.Widget ); OO.mixinClass( OO.ui.ButtonGroupWidget, OO.ui.mixin.GroupElement ); /** * ButtonWidget is a generic widget for buttons. A wide variety of looks, * feels, and functionality can be customized via the class’s configuration options * and methods. Please see the [OOjs UI documentation on MediaWiki] [1] for more information * and examples. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Buttons_and_Switches * * @example * // A button widget * var button = new OO.ui.ButtonWidget( { * label: 'Button with Icon', * icon: 'remove', * iconTitle: 'Remove' * } ); * $( 'body' ).append( button.$element ); * * NOTE: HTML form buttons should use the OO.ui.ButtonInputWidget class. * * @class * @extends OO.ui.Widget * @mixins OO.ui.mixin.ButtonElement * @mixins OO.ui.mixin.IconElement * @mixins OO.ui.mixin.IndicatorElement * @mixins OO.ui.mixin.LabelElement * @mixins OO.ui.mixin.TitledElement * @mixins OO.ui.mixin.FlaggedElement * @mixins OO.ui.mixin.TabIndexedElement * @mixins OO.ui.mixin.AccessKeyedElement * * @constructor * @param {Object} [config] Configuration options * @cfg {string} [href] Hyperlink to visit when the button is clicked. * @cfg {string} [target] The frame or window in which to open the hyperlink. * @cfg {boolean} [noFollow] Search engine traversal hint (default: true) */ OO.ui.ButtonWidget = function OoUiButtonWidget( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.ButtonWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.ButtonElement.call( this, config ); OO.ui.mixin.IconElement.call( this, config ); OO.ui.mixin.IndicatorElement.call( this, config ); OO.ui.mixin.LabelElement.call( this, config ); OO.ui.mixin.TitledElement.call( this, $.extend( {}, config, { $titled: this.$button } ) ); OO.ui.mixin.FlaggedElement.call( this, config ); OO.ui.mixin.TabIndexedElement.call( this, $.extend( {}, config, { $tabIndexed: this.$button } ) ); OO.ui.mixin.AccessKeyedElement.call( this, $.extend( {}, config, { $accessKeyed: this.$button } ) ); // Properties this.href = null; this.target = null; this.noFollow = false; // Events this.connect( this, { disable: 'onDisable' } ); // Initialization this.$button.append( this.$icon, this.$label, this.$indicator ); this.$element .addClass( 'oo-ui-buttonWidget' ) .append( this.$button ); this.setHref( config.href ); this.setTarget( config.target ); this.setNoFollow( config.noFollow ); }; /* Setup */ OO.inheritClass( OO.ui.ButtonWidget, OO.ui.Widget ); OO.mixinClass( OO.ui.ButtonWidget, OO.ui.mixin.ButtonElement ); OO.mixinClass( OO.ui.ButtonWidget, OO.ui.mixin.IconElement ); OO.mixinClass( OO.ui.ButtonWidget, OO.ui.mixin.IndicatorElement ); OO.mixinClass( OO.ui.ButtonWidget, OO.ui.mixin.LabelElement ); OO.mixinClass( OO.ui.ButtonWidget, OO.ui.mixin.TitledElement ); OO.mixinClass( OO.ui.ButtonWidget, OO.ui.mixin.FlaggedElement ); OO.mixinClass( OO.ui.ButtonWidget, OO.ui.mixin.TabIndexedElement ); OO.mixinClass( OO.ui.ButtonWidget, OO.ui.mixin.AccessKeyedElement ); /* Methods */ /** * @inheritdoc */ OO.ui.ButtonWidget.prototype.onMouseDown = function ( e ) { if ( !this.isDisabled() ) { // Remove the tab-index while the button is down to prevent the button from stealing focus this.$button.removeAttr( 'tabindex' ); } return OO.ui.mixin.ButtonElement.prototype.onMouseDown.call( this, e ); }; /** * @inheritdoc */ OO.ui.ButtonWidget.prototype.onMouseUp = function ( e ) { if ( !this.isDisabled() ) { // Restore the tab-index after the button is up to restore the button's accessibility this.$button.attr( 'tabindex', this.tabIndex ); } return OO.ui.mixin.ButtonElement.prototype.onMouseUp.call( this, e ); }; /** * Get hyperlink location. * * @return {string} Hyperlink location */ OO.ui.ButtonWidget.prototype.getHref = function () { return this.href; }; /** * Get hyperlink target. * * @return {string} Hyperlink target */ OO.ui.ButtonWidget.prototype.getTarget = function () { return this.target; }; /** * Get search engine traversal hint. * * @return {boolean} Whether search engines should avoid traversing this hyperlink */ OO.ui.ButtonWidget.prototype.getNoFollow = function () { return this.noFollow; }; /** * Set hyperlink location. * * @param {string|null} href Hyperlink location, null to remove */ OO.ui.ButtonWidget.prototype.setHref = function ( href ) { href = typeof href === 'string' ? href : null; if ( href !== null ) { if ( !OO.ui.isSafeUrl( href ) ) { throw new Error( 'Potentially unsafe href provided: ' + href ); } } if ( href !== this.href ) { this.href = href; this.updateHref(); } return this; }; /** * Update the `href` attribute, in case of changes to href or * disabled state. * * @private * @chainable */ OO.ui.ButtonWidget.prototype.updateHref = function () { if ( this.href !== null && !this.isDisabled() ) { this.$button.attr( 'href', this.href ); } else { this.$button.removeAttr( 'href' ); } return this; }; /** * Handle disable events. * * @private * @param {boolean} disabled Element is disabled */ OO.ui.ButtonWidget.prototype.onDisable = function () { this.updateHref(); }; /** * Set hyperlink target. * * @param {string|null} target Hyperlink target, null to remove */ OO.ui.ButtonWidget.prototype.setTarget = function ( target ) { target = typeof target === 'string' ? target : null; if ( target !== this.target ) { this.target = target; if ( target !== null ) { this.$button.attr( 'target', target ); } else { this.$button.removeAttr( 'target' ); } } return this; }; /** * Set search engine traversal hint. * * @param {boolean} noFollow True if search engines should avoid traversing this hyperlink */ OO.ui.ButtonWidget.prototype.setNoFollow = function ( noFollow ) { noFollow = typeof noFollow === 'boolean' ? noFollow : true; if ( noFollow !== this.noFollow ) { this.noFollow = noFollow; if ( noFollow ) { this.$button.attr( 'rel', 'nofollow' ); } else { this.$button.removeAttr( 'rel' ); } } return this; }; /** * An ActionWidget is a {@link OO.ui.ButtonWidget button widget} that executes an action. * Action widgets are used with OO.ui.ActionSet, which manages the behavior and availability * of the actions. * * Both actions and action sets are primarily used with {@link OO.ui.Dialog Dialogs}. * Please see the [OOjs UI documentation on MediaWiki] [1] for more information * and examples. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Windows/Process_Dialogs#Action_sets * * @class * @extends OO.ui.ButtonWidget * @mixins OO.ui.mixin.PendingElement * * @constructor * @param {Object} [config] Configuration options * @cfg {string} [action] Symbolic name of the action (e.g., ‘continue’ or ‘cancel’). * @cfg {string[]} [modes] Symbolic names of the modes (e.g., ‘edit’ or ‘read’) in which the action * should be made available. See the action set's {@link OO.ui.ActionSet#setMode setMode} method * for more information about setting modes. * @cfg {boolean} [framed=false] Render the action button with a frame */ OO.ui.ActionWidget = function OoUiActionWidget( config ) { // Configuration initialization config = $.extend( { framed: false }, config ); // Parent constructor OO.ui.ActionWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.PendingElement.call( this, config ); // Properties this.action = config.action || ''; this.modes = config.modes || []; this.width = 0; this.height = 0; // Initialization this.$element.addClass( 'oo-ui-actionWidget' ); }; /* Setup */ OO.inheritClass( OO.ui.ActionWidget, OO.ui.ButtonWidget ); OO.mixinClass( OO.ui.ActionWidget, OO.ui.mixin.PendingElement ); /* Events */ /** * A resize event is emitted when the size of the widget changes. * * @event resize */ /* Methods */ /** * Check if the action is configured to be available in the specified `mode`. * * @param {string} mode Name of mode * @return {boolean} The action is configured with the mode */ OO.ui.ActionWidget.prototype.hasMode = function ( mode ) { return this.modes.indexOf( mode ) !== -1; }; /** * Get the symbolic name of the action (e.g., ‘continue’ or ‘cancel’). * * @return {string} */ OO.ui.ActionWidget.prototype.getAction = function () { return this.action; }; /** * Get the symbolic name of the mode or modes for which the action is configured to be available. * * The current mode is set with the action set's {@link OO.ui.ActionSet#setMode setMode} method. * Only actions that are configured to be avaiable in the current mode will be visible. All other actions * are hidden. * * @return {string[]} */ OO.ui.ActionWidget.prototype.getModes = function () { return this.modes.slice(); }; /** * Emit a resize event if the size has changed. * * @private * @chainable */ OO.ui.ActionWidget.prototype.propagateResize = function () { var width, height; if ( this.isElementAttached() ) { width = this.$element.width(); height = this.$element.height(); if ( width !== this.width || height !== this.height ) { this.width = width; this.height = height; this.emit( 'resize' ); } } return this; }; /** * @inheritdoc */ OO.ui.ActionWidget.prototype.setIcon = function () { // Mixin method OO.ui.mixin.IconElement.prototype.setIcon.apply( this, arguments ); this.propagateResize(); return this; }; /** * @inheritdoc */ OO.ui.ActionWidget.prototype.setLabel = function () { // Mixin method OO.ui.mixin.LabelElement.prototype.setLabel.apply( this, arguments ); this.propagateResize(); return this; }; /** * @inheritdoc */ OO.ui.ActionWidget.prototype.setFlags = function () { // Mixin method OO.ui.mixin.FlaggedElement.prototype.setFlags.apply( this, arguments ); this.propagateResize(); return this; }; /** * @inheritdoc */ OO.ui.ActionWidget.prototype.clearFlags = function () { // Mixin method OO.ui.mixin.FlaggedElement.prototype.clearFlags.apply( this, arguments ); this.propagateResize(); return this; }; /** * Toggle the visibility of the action button. * * @param {boolean} [show] Show button, omit to toggle visibility * @chainable */ OO.ui.ActionWidget.prototype.toggle = function () { // Parent method OO.ui.ActionWidget.parent.prototype.toggle.apply( this, arguments ); this.propagateResize(); return this; }; /** * PopupButtonWidgets toggle the visibility of a contained {@link OO.ui.PopupWidget PopupWidget}, * which is used to display additional information or options. * * @example * // Example of a popup button. * var popupButton = new OO.ui.PopupButtonWidget( { * label: 'Popup button with options', * icon: 'menu', * popup: { * $content: $( '<p>Additional options here.</p>' ), * padded: true, * align: 'force-left' * } * } ); * // Append the button to the DOM. * $( 'body' ).append( popupButton.$element ); * * @class * @extends OO.ui.ButtonWidget * @mixins OO.ui.mixin.PopupElement * * @constructor * @param {Object} [config] Configuration options */ OO.ui.PopupButtonWidget = function OoUiPopupButtonWidget( config ) { // Parent constructor OO.ui.PopupButtonWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.PopupElement.call( this, config ); // Events this.connect( this, { click: 'onAction' } ); // Initialization this.$element .addClass( 'oo-ui-popupButtonWidget' ) .attr( 'aria-haspopup', 'true' ) .append( this.popup.$element ); }; /* Setup */ OO.inheritClass( OO.ui.PopupButtonWidget, OO.ui.ButtonWidget ); OO.mixinClass( OO.ui.PopupButtonWidget, OO.ui.mixin.PopupElement ); /* Methods */ /** * Handle the button action being triggered. * * @private */ OO.ui.PopupButtonWidget.prototype.onAction = function () { this.popup.toggle(); }; /** * ToggleButtons are buttons that have a state (‘on’ or ‘off’) that is represented by a * Boolean value. Like other {@link OO.ui.ButtonWidget buttons}, toggle buttons can be * configured with {@link OO.ui.mixin.IconElement icons}, {@link OO.ui.mixin.IndicatorElement indicators}, * {@link OO.ui.mixin.TitledElement titles}, {@link OO.ui.mixin.FlaggedElement styling flags}, * and {@link OO.ui.mixin.LabelElement labels}. Please see * the [OOjs UI documentation][1] on MediaWiki for more information. * * @example * // Toggle buttons in the 'off' and 'on' state. * var toggleButton1 = new OO.ui.ToggleButtonWidget( { * label: 'Toggle Button off' * } ); * var toggleButton2 = new OO.ui.ToggleButtonWidget( { * label: 'Toggle Button on', * value: true * } ); * // Append the buttons to the DOM. * $( 'body' ).append( toggleButton1.$element, toggleButton2.$element ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Buttons_and_Switches#Toggle_buttons * * @class * @extends OO.ui.ToggleWidget * @mixins OO.ui.mixin.ButtonElement * @mixins OO.ui.mixin.IconElement * @mixins OO.ui.mixin.IndicatorElement * @mixins OO.ui.mixin.LabelElement * @mixins OO.ui.mixin.TitledElement * @mixins OO.ui.mixin.FlaggedElement * @mixins OO.ui.mixin.TabIndexedElement * * @constructor * @param {Object} [config] Configuration options * @cfg {boolean} [value=false] The toggle button’s initial on/off * state. By default, the button is in the 'off' state. */ OO.ui.ToggleButtonWidget = function OoUiToggleButtonWidget( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.ToggleButtonWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.ButtonElement.call( this, config ); OO.ui.mixin.IconElement.call( this, config ); OO.ui.mixin.IndicatorElement.call( this, config ); OO.ui.mixin.LabelElement.call( this, config ); OO.ui.mixin.TitledElement.call( this, $.extend( {}, config, { $titled: this.$button } ) ); OO.ui.mixin.FlaggedElement.call( this, config ); OO.ui.mixin.TabIndexedElement.call( this, $.extend( {}, config, { $tabIndexed: this.$button } ) ); // Events this.connect( this, { click: 'onAction' } ); // Initialization this.$button.append( this.$icon, this.$label, this.$indicator ); this.$element .addClass( 'oo-ui-toggleButtonWidget' ) .append( this.$button ); }; /* Setup */ OO.inheritClass( OO.ui.ToggleButtonWidget, OO.ui.ToggleWidget ); OO.mixinClass( OO.ui.ToggleButtonWidget, OO.ui.mixin.ButtonElement ); OO.mixinClass( OO.ui.ToggleButtonWidget, OO.ui.mixin.IconElement ); OO.mixinClass( OO.ui.ToggleButtonWidget, OO.ui.mixin.IndicatorElement ); OO.mixinClass( OO.ui.ToggleButtonWidget, OO.ui.mixin.LabelElement ); OO.mixinClass( OO.ui.ToggleButtonWidget, OO.ui.mixin.TitledElement ); OO.mixinClass( OO.ui.ToggleButtonWidget, OO.ui.mixin.FlaggedElement ); OO.mixinClass( OO.ui.ToggleButtonWidget, OO.ui.mixin.TabIndexedElement ); /* Methods */ /** * Handle the button action being triggered. * * @private */ OO.ui.ToggleButtonWidget.prototype.onAction = function () { this.setValue( !this.value ); }; /** * @inheritdoc */ OO.ui.ToggleButtonWidget.prototype.setValue = function ( value ) { value = !!value; if ( value !== this.value ) { // Might be called from parent constructor before ButtonElement constructor if ( this.$button ) { this.$button.attr( 'aria-pressed', value.toString() ); } this.setActive( value ); } // Parent method OO.ui.ToggleButtonWidget.parent.prototype.setValue.call( this, value ); return this; }; /** * @inheritdoc */ OO.ui.ToggleButtonWidget.prototype.setButtonElement = function ( $button ) { if ( this.$button ) { this.$button.removeAttr( 'aria-pressed' ); } OO.ui.mixin.ButtonElement.prototype.setButtonElement.call( this, $button ); this.$button.attr( 'aria-pressed', this.value.toString() ); }; /** * CapsuleMultiSelectWidgets are something like a {@link OO.ui.ComboBoxInputWidget combo box widget} * that allows for selecting multiple values. * * For more information about menus and options, please see the [OOjs UI documentation on MediaWiki][1]. * * @example * // Example: A CapsuleMultiSelectWidget. * var capsule = new OO.ui.CapsuleMultiSelectWidget( { * label: 'CapsuleMultiSelectWidget', * selected: [ 'Option 1', 'Option 3' ], * menu: { * items: [ * new OO.ui.MenuOptionWidget( { * data: 'Option 1', * label: 'Option One' * } ), * new OO.ui.MenuOptionWidget( { * data: 'Option 2', * label: 'Option Two' * } ), * new OO.ui.MenuOptionWidget( { * data: 'Option 3', * label: 'Option Three' * } ), * new OO.ui.MenuOptionWidget( { * data: 'Option 4', * label: 'Option Four' * } ), * new OO.ui.MenuOptionWidget( { * data: 'Option 5', * label: 'Option Five' * } ) * ] * } * } ); * $( 'body' ).append( capsule.$element ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Selects_and_Options#Menu_selects_and_options * * @class * @extends OO.ui.Widget * @mixins OO.ui.mixin.TabIndexedElement * @mixins OO.ui.mixin.GroupElement * * @constructor * @param {Object} [config] Configuration options * @cfg {boolean} [allowArbitrary=false] Allow data items to be added even if not present in the menu. * @cfg {Object} [menu] Configuration options to pass to the {@link OO.ui.MenuSelectWidget menu select widget}. * @cfg {Object} [popup] Configuration options to pass to the {@link OO.ui.PopupWidget popup widget}. * If specified, this popup will be shown instead of the menu (but the menu * will still be used for item labels and allowArbitrary=false). The widgets * in the popup should use this.addItemsFromData() or this.addItems() as necessary. * @cfg {jQuery} [$overlay] Render the menu or popup into a separate layer. * This configuration is useful in cases where the expanded menu is larger than * its containing `<div>`. The specified overlay layer is usually on top of * the containing `<div>` and has a larger area. By default, the menu uses * relative positioning. */ OO.ui.CapsuleMultiSelectWidget = function OoUiCapsuleMultiSelectWidget( config ) { var $tabFocus; // Configuration initialization config = config || {}; // Parent constructor OO.ui.CapsuleMultiSelectWidget.parent.call( this, config ); // Properties (must be set before mixin constructor calls) this.$input = config.popup ? null : $( '<input>' ); this.$handle = $( '<div>' ); // Mixin constructors OO.ui.mixin.GroupElement.call( this, config ); if ( config.popup ) { config.popup = $.extend( {}, config.popup, { align: 'forwards', anchor: false } ); OO.ui.mixin.PopupElement.call( this, config ); $tabFocus = $( '<span>' ); OO.ui.mixin.TabIndexedElement.call( this, $.extend( {}, config, { $tabIndexed: $tabFocus } ) ); } else { this.popup = null; $tabFocus = null; OO.ui.mixin.TabIndexedElement.call( this, $.extend( {}, config, { $tabIndexed: this.$input } ) ); } OO.ui.mixin.IndicatorElement.call( this, config ); OO.ui.mixin.IconElement.call( this, config ); // Properties this.allowArbitrary = !!config.allowArbitrary; this.$overlay = config.$overlay || this.$element; this.menu = new OO.ui.FloatingMenuSelectWidget( $.extend( { widget: this, $input: this.$input, $container: this.$element, filterFromInput: true, disabled: this.isDisabled() }, config.menu ) ); // Events if ( this.popup ) { $tabFocus.on( { focus: this.onFocusForPopup.bind( this ) } ); this.popup.$element.on( 'focusout', this.onPopupFocusOut.bind( this ) ); if ( this.popup.$autoCloseIgnore ) { this.popup.$autoCloseIgnore.on( 'focusout', this.onPopupFocusOut.bind( this ) ); } this.popup.connect( this, { toggle: function ( visible ) { $tabFocus.toggle( !visible ); } } ); } else { this.$input.on( { focus: this.onInputFocus.bind( this ), blur: this.onInputBlur.bind( this ), 'propertychange change click mouseup keydown keyup input cut paste select': this.onInputChange.bind( this ), keydown: this.onKeyDown.bind( this ), keypress: this.onKeyPress.bind( this ) } ); } this.menu.connect( this, { choose: 'onMenuChoose', add: 'onMenuItemsChange', remove: 'onMenuItemsChange' } ); this.$handle.on( { click: this.onClick.bind( this ) } ); // Initialization if ( this.$input ) { this.$input.prop( 'disabled', this.isDisabled() ); this.$input.attr( { role: 'combobox', 'aria-autocomplete': 'list' } ); this.$input.width( '1em' ); } if ( config.data ) { this.setItemsFromData( config.data ); } this.$group.addClass( 'oo-ui-capsuleMultiSelectWidget-group' ); this.$handle.addClass( 'oo-ui-capsuleMultiSelectWidget-handle' ) .append( this.$indicator, this.$icon, this.$group ); this.$element.addClass( 'oo-ui-capsuleMultiSelectWidget' ) .append( this.$handle ); if ( this.popup ) { this.$handle.append( $tabFocus ); this.$overlay.append( this.popup.$element ); } else { this.$handle.append( this.$input ); this.$overlay.append( this.menu.$element ); } this.onMenuItemsChange(); }; /* Setup */ OO.inheritClass( OO.ui.CapsuleMultiSelectWidget, OO.ui.Widget ); OO.mixinClass( OO.ui.CapsuleMultiSelectWidget, OO.ui.mixin.GroupElement ); OO.mixinClass( OO.ui.CapsuleMultiSelectWidget, OO.ui.mixin.PopupElement ); OO.mixinClass( OO.ui.CapsuleMultiSelectWidget, OO.ui.mixin.TabIndexedElement ); OO.mixinClass( OO.ui.CapsuleMultiSelectWidget, OO.ui.mixin.IndicatorElement ); OO.mixinClass( OO.ui.CapsuleMultiSelectWidget, OO.ui.mixin.IconElement ); /* Events */ /** * @event change * * A change event is emitted when the set of selected items changes. * * @param {Mixed[]} datas Data of the now-selected items */ /* Methods */ /** * Construct a OO.ui.CapsuleItemWidget (or a subclass thereof) from given label and data. * * @protected * @param {Mixed} data Custom data of any type. * @param {string} label The label text. * @return {OO.ui.CapsuleItemWidget} */ OO.ui.CapsuleMultiSelectWidget.prototype.createItemWidget = function ( data, label ) { return new OO.ui.CapsuleItemWidget( { data: data, label: label } ); }; /** * Get the data of the items in the capsule * @return {Mixed[]} */ OO.ui.CapsuleMultiSelectWidget.prototype.getItemsData = function () { return $.map( this.getItems(), function ( e ) { return e.data; } ); }; /** * Set the items in the capsule by providing data * @chainable * @param {Mixed[]} datas * @return {OO.ui.CapsuleMultiSelectWidget} */ OO.ui.CapsuleMultiSelectWidget.prototype.setItemsFromData = function ( datas ) { var widget = this, menu = this.menu, items = this.getItems(); $.each( datas, function ( i, data ) { var j, label, item = menu.getItemFromData( data ); if ( item ) { label = item.label; } else if ( widget.allowArbitrary ) { label = String( data ); } else { return; } item = null; for ( j = 0; j < items.length; j++ ) { if ( items[ j ].data === data && items[ j ].label === label ) { item = items[ j ]; items.splice( j, 1 ); break; } } if ( !item ) { item = widget.createItemWidget( data, label ); } widget.addItems( [ item ], i ); } ); if ( items.length ) { widget.removeItems( items ); } return this; }; /** * Add items to the capsule by providing their data * @chainable * @param {Mixed[]} datas * @return {OO.ui.CapsuleMultiSelectWidget} */ OO.ui.CapsuleMultiSelectWidget.prototype.addItemsFromData = function ( datas ) { var widget = this, menu = this.menu, items = []; $.each( datas, function ( i, data ) { var item; if ( !widget.getItemFromData( data ) ) { item = menu.getItemFromData( data ); if ( item ) { items.push( widget.createItemWidget( data, item.label ) ); } else if ( widget.allowArbitrary ) { items.push( widget.createItemWidget( data, String( data ) ) ); } } } ); if ( items.length ) { this.addItems( items ); } return this; }; /** * Remove items by data * @chainable * @param {Mixed[]} datas * @return {OO.ui.CapsuleMultiSelectWidget} */ OO.ui.CapsuleMultiSelectWidget.prototype.removeItemsFromData = function ( datas ) { var widget = this, items = []; $.each( datas, function ( i, data ) { var item = widget.getItemFromData( data ); if ( item ) { items.push( item ); } } ); if ( items.length ) { this.removeItems( items ); } return this; }; /** * @inheritdoc */ OO.ui.CapsuleMultiSelectWidget.prototype.addItems = function ( items ) { var same, i, l, oldItems = this.items.slice(); OO.ui.mixin.GroupElement.prototype.addItems.call( this, items ); if ( this.items.length !== oldItems.length ) { same = false; } else { same = true; for ( i = 0, l = oldItems.length; same && i < l; i++ ) { same = same && this.items[ i ] === oldItems[ i ]; } } if ( !same ) { this.emit( 'change', this.getItemsData() ); } return this; }; /** * @inheritdoc */ OO.ui.CapsuleMultiSelectWidget.prototype.removeItems = function ( items ) { var same, i, l, oldItems = this.items.slice(); OO.ui.mixin.GroupElement.prototype.removeItems.call( this, items ); if ( this.items.length !== oldItems.length ) { same = false; } else { same = true; for ( i = 0, l = oldItems.length; same && i < l; i++ ) { same = same && this.items[ i ] === oldItems[ i ]; } } if ( !same ) { this.emit( 'change', this.getItemsData() ); } return this; }; /** * @inheritdoc */ OO.ui.CapsuleMultiSelectWidget.prototype.clearItems = function () { if ( this.items.length ) { OO.ui.mixin.GroupElement.prototype.clearItems.call( this ); this.emit( 'change', this.getItemsData() ); } return this; }; /** * Get the capsule widget's menu. * @return {OO.ui.MenuSelectWidget} Menu widget */ OO.ui.CapsuleMultiSelectWidget.prototype.getMenu = function () { return this.menu; }; /** * Handle focus events * * @private * @param {jQuery.Event} event */ OO.ui.CapsuleMultiSelectWidget.prototype.onInputFocus = function () { if ( !this.isDisabled() ) { this.menu.toggle( true ); } }; /** * Handle blur events * * @private * @param {jQuery.Event} event */ OO.ui.CapsuleMultiSelectWidget.prototype.onInputBlur = function () { if ( this.allowArbitrary && this.$input.val().trim() !== '' ) { this.addItemsFromData( [ this.$input.val() ] ); } this.clearInput(); }; /** * Handle focus events * * @private * @param {jQuery.Event} event */ OO.ui.CapsuleMultiSelectWidget.prototype.onFocusForPopup = function () { if ( !this.isDisabled() ) { this.popup.setSize( this.$handle.width() ); this.popup.toggle( true ); this.popup.$element.find( '*' ) .filter( function () { return OO.ui.isFocusableElement( $( this ), true ); } ) .first() .focus(); } }; /** * Handles popup focus out events. * * @private * @param {Event} e Focus out event */ OO.ui.CapsuleMultiSelectWidget.prototype.onPopupFocusOut = function () { var widget = this.popup; setTimeout( function () { if ( widget.isVisible() && !OO.ui.contains( widget.$element[ 0 ], document.activeElement, true ) && ( !widget.$autoCloseIgnore || !widget.$autoCloseIgnore.has( document.activeElement ).length ) ) { widget.toggle( false ); } } ); }; /** * Handle mouse click events. * * @private * @param {jQuery.Event} e Mouse click event */ OO.ui.CapsuleMultiSelectWidget.prototype.onClick = function ( e ) { if ( e.which === 1 ) { this.focus(); return false; } }; /** * Handle key press events. * * @private * @param {jQuery.Event} e Key press event */ OO.ui.CapsuleMultiSelectWidget.prototype.onKeyPress = function ( e ) { var item; if ( !this.isDisabled() ) { if ( e.which === OO.ui.Keys.ESCAPE ) { this.clearInput(); return false; } if ( !this.popup ) { this.menu.toggle( true ); if ( e.which === OO.ui.Keys.ENTER ) { item = this.menu.getItemFromLabel( this.$input.val(), true ); if ( item ) { this.addItemsFromData( [ item.data ] ); this.clearInput(); } else if ( this.allowArbitrary && this.$input.val().trim() !== '' ) { this.addItemsFromData( [ this.$input.val() ] ); this.clearInput(); } return false; } // Make sure the input gets resized. setTimeout( this.onInputChange.bind( this ), 0 ); } } }; /** * Handle key down events. * * @private * @param {jQuery.Event} e Key down event */ OO.ui.CapsuleMultiSelectWidget.prototype.onKeyDown = function ( e ) { if ( !this.isDisabled() ) { // 'keypress' event is not triggered for Backspace if ( e.keyCode === OO.ui.Keys.BACKSPACE && this.$input.val() === '' ) { if ( this.items.length ) { this.removeItems( this.items.slice( -1 ) ); } return false; } } }; /** * Handle input change events. * * @private * @param {jQuery.Event} e Event of some sort */ OO.ui.CapsuleMultiSelectWidget.prototype.onInputChange = function () { if ( !this.isDisabled() ) { this.$input.width( this.$input.val().length + 'em' ); } }; /** * Handle menu choose events. * * @private * @param {OO.ui.OptionWidget} item Chosen item */ OO.ui.CapsuleMultiSelectWidget.prototype.onMenuChoose = function ( item ) { if ( item && item.isVisible() ) { this.addItemsFromData( [ item.getData() ] ); this.clearInput(); } }; /** * Handle menu item change events. * * @private */ OO.ui.CapsuleMultiSelectWidget.prototype.onMenuItemsChange = function () { this.setItemsFromData( this.getItemsData() ); this.$element.toggleClass( 'oo-ui-capsuleMultiSelectWidget-empty', this.menu.isEmpty() ); }; /** * Clear the input field * @private */ OO.ui.CapsuleMultiSelectWidget.prototype.clearInput = function () { if ( this.$input ) { this.$input.val( '' ); this.$input.width( '1em' ); } if ( this.popup ) { this.popup.toggle( false ); } this.menu.toggle( false ); this.menu.selectItem(); this.menu.highlightItem(); }; /** * @inheritdoc */ OO.ui.CapsuleMultiSelectWidget.prototype.setDisabled = function ( disabled ) { var i, len; // Parent method OO.ui.CapsuleMultiSelectWidget.parent.prototype.setDisabled.call( this, disabled ); if ( this.$input ) { this.$input.prop( 'disabled', this.isDisabled() ); } if ( this.menu ) { this.menu.setDisabled( this.isDisabled() ); } if ( this.popup ) { this.popup.setDisabled( this.isDisabled() ); } if ( this.items ) { for ( i = 0, len = this.items.length; i < len; i++ ) { this.items[ i ].updateDisabled(); } } return this; }; /** * Focus the widget * @chainable * @return {OO.ui.CapsuleMultiSelectWidget} */ OO.ui.CapsuleMultiSelectWidget.prototype.focus = function () { if ( !this.isDisabled() ) { if ( this.popup ) { this.popup.setSize( this.$handle.width() ); this.popup.toggle( true ); this.popup.$element.find( '*' ) .filter( function () { return OO.ui.isFocusableElement( $( this ), true ); } ) .first() .focus(); } else { this.menu.toggle( true ); this.$input.focus(); } } return this; }; /** * CapsuleItemWidgets are used within a {@link OO.ui.CapsuleMultiSelectWidget * CapsuleMultiSelectWidget} to display the selected items. * * @class * @extends OO.ui.Widget * @mixins OO.ui.mixin.ItemWidget * @mixins OO.ui.mixin.IndicatorElement * @mixins OO.ui.mixin.LabelElement * @mixins OO.ui.mixin.FlaggedElement * @mixins OO.ui.mixin.TabIndexedElement * * @constructor * @param {Object} [config] Configuration options */ OO.ui.CapsuleItemWidget = function OoUiCapsuleItemWidget( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.CapsuleItemWidget.parent.call( this, config ); // Properties (must be set before mixin constructor calls) this.$indicator = $( '<span>' ); // Mixin constructors OO.ui.mixin.ItemWidget.call( this ); OO.ui.mixin.IndicatorElement.call( this, $.extend( {}, config, { $indicator: this.$indicator, indicator: 'clear' } ) ); OO.ui.mixin.LabelElement.call( this, config ); OO.ui.mixin.FlaggedElement.call( this, config ); OO.ui.mixin.TabIndexedElement.call( this, $.extend( {}, config, { $tabIndexed: this.$indicator } ) ); // Events this.$indicator.on( { keydown: this.onCloseKeyDown.bind( this ), click: this.onCloseClick.bind( this ) } ); // Initialization this.$element .addClass( 'oo-ui-capsuleItemWidget' ) .append( this.$indicator, this.$label ); }; /* Setup */ OO.inheritClass( OO.ui.CapsuleItemWidget, OO.ui.Widget ); OO.mixinClass( OO.ui.CapsuleItemWidget, OO.ui.mixin.ItemWidget ); OO.mixinClass( OO.ui.CapsuleItemWidget, OO.ui.mixin.IndicatorElement ); OO.mixinClass( OO.ui.CapsuleItemWidget, OO.ui.mixin.LabelElement ); OO.mixinClass( OO.ui.CapsuleItemWidget, OO.ui.mixin.FlaggedElement ); OO.mixinClass( OO.ui.CapsuleItemWidget, OO.ui.mixin.TabIndexedElement ); /* Methods */ /** * Handle close icon clicks * @param {jQuery.Event} event */ OO.ui.CapsuleItemWidget.prototype.onCloseClick = function () { var element = this.getElementGroup(); if ( !this.isDisabled() && element && $.isFunction( element.removeItems ) ) { element.removeItems( [ this ] ); element.focus(); } }; /** * Handle close keyboard events * @param {jQuery.Event} event Key down event */ OO.ui.CapsuleItemWidget.prototype.onCloseKeyDown = function ( e ) { if ( !this.isDisabled() && $.isFunction( this.getElementGroup().removeItems ) ) { switch ( e.which ) { case OO.ui.Keys.ENTER: case OO.ui.Keys.BACKSPACE: case OO.ui.Keys.SPACE: this.getElementGroup().removeItems( [ this ] ); return false; } } }; /** * DropdownWidgets are not menus themselves, rather they contain a menu of options created with * OO.ui.MenuOptionWidget. The DropdownWidget takes care of opening and displaying the menu so that * users can interact with it. * * If you want to use this within a HTML form, such as a OO.ui.FormLayout, use * OO.ui.DropdownInputWidget instead. * * @example * // Example: A DropdownWidget with a menu that contains three options * var dropDown = new OO.ui.DropdownWidget( { * label: 'Dropdown menu: Select a menu option', * menu: { * items: [ * new OO.ui.MenuOptionWidget( { * data: 'a', * label: 'First' * } ), * new OO.ui.MenuOptionWidget( { * data: 'b', * label: 'Second' * } ), * new OO.ui.MenuOptionWidget( { * data: 'c', * label: 'Third' * } ) * ] * } * } ); * * $( 'body' ).append( dropDown.$element ); * * dropDown.getMenu().selectItemByData( 'b' ); * * dropDown.getMenu().getSelectedItem().getData(); // returns 'b' * * For more information, please see the [OOjs UI documentation on MediaWiki] [1]. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Selects_and_Options#Menu_selects_and_options * * @class * @extends OO.ui.Widget * @mixins OO.ui.mixin.IconElement * @mixins OO.ui.mixin.IndicatorElement * @mixins OO.ui.mixin.LabelElement * @mixins OO.ui.mixin.TitledElement * @mixins OO.ui.mixin.TabIndexedElement * * @constructor * @param {Object} [config] Configuration options * @cfg {Object} [menu] Configuration options to pass to {@link OO.ui.FloatingMenuSelectWidget menu select widget} * @cfg {jQuery} [$overlay] Render the menu into a separate layer. This configuration is useful in cases where * the expanded menu is larger than its containing `<div>`. The specified overlay layer is usually on top of the * containing `<div>` and has a larger area. By default, the menu uses relative positioning. */ OO.ui.DropdownWidget = function OoUiDropdownWidget( config ) { // Configuration initialization config = $.extend( { indicator: 'down' }, config ); // Parent constructor OO.ui.DropdownWidget.parent.call( this, config ); // Properties (must be set before TabIndexedElement constructor call) this.$handle = this.$( '<span>' ); this.$overlay = config.$overlay || this.$element; // Mixin constructors OO.ui.mixin.IconElement.call( this, config ); OO.ui.mixin.IndicatorElement.call( this, config ); OO.ui.mixin.LabelElement.call( this, config ); OO.ui.mixin.TitledElement.call( this, $.extend( {}, config, { $titled: this.$label } ) ); OO.ui.mixin.TabIndexedElement.call( this, $.extend( {}, config, { $tabIndexed: this.$handle } ) ); // Properties this.menu = new OO.ui.FloatingMenuSelectWidget( $.extend( { widget: this, $container: this.$element }, config.menu ) ); // Events this.$handle.on( { click: this.onClick.bind( this ), keypress: this.onKeyPress.bind( this ) } ); this.menu.connect( this, { select: 'onMenuSelect' } ); // Initialization this.$handle .addClass( 'oo-ui-dropdownWidget-handle' ) .append( this.$icon, this.$label, this.$indicator ); this.$element .addClass( 'oo-ui-dropdownWidget' ) .append( this.$handle ); this.$overlay.append( this.menu.$element ); }; /* Setup */ OO.inheritClass( OO.ui.DropdownWidget, OO.ui.Widget ); OO.mixinClass( OO.ui.DropdownWidget, OO.ui.mixin.IconElement ); OO.mixinClass( OO.ui.DropdownWidget, OO.ui.mixin.IndicatorElement ); OO.mixinClass( OO.ui.DropdownWidget, OO.ui.mixin.LabelElement ); OO.mixinClass( OO.ui.DropdownWidget, OO.ui.mixin.TitledElement ); OO.mixinClass( OO.ui.DropdownWidget, OO.ui.mixin.TabIndexedElement ); /* Methods */ /** * Get the menu. * * @return {OO.ui.MenuSelectWidget} Menu of widget */ OO.ui.DropdownWidget.prototype.getMenu = function () { return this.menu; }; /** * Handles menu select events. * * @private * @param {OO.ui.MenuOptionWidget} item Selected menu item */ OO.ui.DropdownWidget.prototype.onMenuSelect = function ( item ) { var selectedLabel; if ( !item ) { this.setLabel( null ); return; } selectedLabel = item.getLabel(); // If the label is a DOM element, clone it, because setLabel will append() it if ( selectedLabel instanceof jQuery ) { selectedLabel = selectedLabel.clone(); } this.setLabel( selectedLabel ); }; /** * Handle mouse click events. * * @private * @param {jQuery.Event} e Mouse click event */ OO.ui.DropdownWidget.prototype.onClick = function ( e ) { if ( !this.isDisabled() && e.which === 1 ) { this.menu.toggle(); } return false; }; /** * Handle key press events. * * @private * @param {jQuery.Event} e Key press event */ OO.ui.DropdownWidget.prototype.onKeyPress = function ( e ) { if ( !this.isDisabled() && ( ( e.which === OO.ui.Keys.SPACE && !this.menu.isVisible() ) || e.which === OO.ui.Keys.ENTER ) ) { this.menu.toggle(); return false; } }; /** * SelectFileWidgets allow for selecting files, using the HTML5 File API. These * widgets can be configured with {@link OO.ui.mixin.IconElement icons} and {@link * OO.ui.mixin.IndicatorElement indicators}. * Please see the [OOjs UI documentation on MediaWiki] [1] for more information and examples. * * @example * // Example of a file select widget * var selectFile = new OO.ui.SelectFileWidget(); * $( 'body' ).append( selectFile.$element ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets * * @class * @extends OO.ui.Widget * @mixins OO.ui.mixin.IconElement * @mixins OO.ui.mixin.IndicatorElement * @mixins OO.ui.mixin.PendingElement * @mixins OO.ui.mixin.LabelElement * * @constructor * @param {Object} [config] Configuration options * @cfg {string[]|null} [accept=null] MIME types to accept. null accepts all types. * @cfg {string} [placeholder] Text to display when no file is selected. * @cfg {string} [notsupported] Text to display when file support is missing in the browser. * @cfg {boolean} [droppable=true] Whether to accept files by drag and drop. * @cfg {boolean} [showDropTarget=false] Whether to show a drop target. Requires droppable to be true. * @cfg {boolean} [dragDropUI=false] Deprecated alias for showDropTarget */ OO.ui.SelectFileWidget = function OoUiSelectFileWidget( config ) { var dragHandler; // TODO: Remove in next release if ( config && config.dragDropUI ) { config.showDropTarget = true; } // Configuration initialization config = $.extend( { accept: null, placeholder: OO.ui.msg( 'ooui-selectfile-placeholder' ), notsupported: OO.ui.msg( 'ooui-selectfile-not-supported' ), droppable: true, showDropTarget: false }, config ); // Parent constructor OO.ui.SelectFileWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.IconElement.call( this, config ); OO.ui.mixin.IndicatorElement.call( this, config ); OO.ui.mixin.PendingElement.call( this, $.extend( {}, config, { $pending: this.$info } ) ); OO.ui.mixin.LabelElement.call( this, $.extend( {}, config, { autoFitLabel: true } ) ); // Properties this.$info = $( '<span>' ); // Properties this.showDropTarget = config.showDropTarget; this.isSupported = this.constructor.static.isSupported(); this.currentFile = null; if ( Array.isArray( config.accept ) ) { this.accept = config.accept; } else { this.accept = null; } this.placeholder = config.placeholder; this.notsupported = config.notsupported; this.onFileSelectedHandler = this.onFileSelected.bind( this ); this.selectButton = new OO.ui.ButtonWidget( { classes: [ 'oo-ui-selectFileWidget-selectButton' ], label: 'Select a file', disabled: this.disabled || !this.isSupported } ); this.clearButton = new OO.ui.ButtonWidget( { classes: [ 'oo-ui-selectFileWidget-clearButton' ], framed: false, icon: 'remove', disabled: this.disabled } ); // Events this.selectButton.$button.on( { keypress: this.onKeyPress.bind( this ) } ); this.clearButton.connect( this, { click: 'onClearClick' } ); if ( config.droppable ) { dragHandler = this.onDragEnterOrOver.bind( this ); this.$element.on( { dragenter: dragHandler, dragover: dragHandler, dragleave: this.onDragLeave.bind( this ), drop: this.onDrop.bind( this ) } ); } // Initialization this.addInput(); this.updateUI(); this.$label.addClass( 'oo-ui-selectFileWidget-label' ); this.$info .addClass( 'oo-ui-selectFileWidget-info' ) .append( this.$icon, this.$label, this.clearButton.$element, this.$indicator ); this.$element .addClass( 'oo-ui-selectFileWidget' ) .append( this.$info, this.selectButton.$element ); if ( config.droppable && config.showDropTarget ) { this.$dropTarget = $( '<div>' ) .addClass( 'oo-ui-selectFileWidget-dropTarget' ) .text( OO.ui.msg( 'ooui-selectfile-dragdrop-placeholder' ) ) .on( { click: this.onDropTargetClick.bind( this ) } ); this.$element.prepend( this.$dropTarget ); } }; /* Setup */ OO.inheritClass( OO.ui.SelectFileWidget, OO.ui.Widget ); OO.mixinClass( OO.ui.SelectFileWidget, OO.ui.mixin.IconElement ); OO.mixinClass( OO.ui.SelectFileWidget, OO.ui.mixin.IndicatorElement ); OO.mixinClass( OO.ui.SelectFileWidget, OO.ui.mixin.PendingElement ); OO.mixinClass( OO.ui.SelectFileWidget, OO.ui.mixin.LabelElement ); /* Static Properties */ /** * Check if this widget is supported * * @static * @return {boolean} */ OO.ui.SelectFileWidget.static.isSupported = function () { var $input; if ( OO.ui.SelectFileWidget.static.isSupportedCache === null ) { $input = $( '<input type="file">' ); OO.ui.SelectFileWidget.static.isSupportedCache = $input[ 0 ].files !== undefined; } return OO.ui.SelectFileWidget.static.isSupportedCache; }; OO.ui.SelectFileWidget.static.isSupportedCache = null; /* Events */ /** * @event change * * A change event is emitted when the on/off state of the toggle changes. * * @param {File|null} value New value */ /* Methods */ /** * Get the current value of the field * * @return {File|null} */ OO.ui.SelectFileWidget.prototype.getValue = function () { return this.currentFile; }; /** * Set the current value of the field * * @param {File|null} file File to select */ OO.ui.SelectFileWidget.prototype.setValue = function ( file ) { if ( this.currentFile !== file ) { this.currentFile = file; this.updateUI(); this.emit( 'change', this.currentFile ); } }; /** * Focus the widget. * * Focusses the select file button. * * @chainable */ OO.ui.SelectFileWidget.prototype.focus = function () { this.selectButton.$button[ 0 ].focus(); return this; }; /** * Update the user interface when a file is selected or unselected * * @protected */ OO.ui.SelectFileWidget.prototype.updateUI = function () { var $label; if ( !this.isSupported ) { this.$element.addClass( 'oo-ui-selectFileWidget-notsupported' ); this.$element.removeClass( 'oo-ui-selectFileWidget-empty' ); this.setLabel( this.notsupported ); } else { this.$element.addClass( 'oo-ui-selectFileWidget-supported' ); if ( this.currentFile ) { this.$element.removeClass( 'oo-ui-selectFileWidget-empty' ); $label = $( [] ); if ( this.currentFile.type !== '' ) { $label = $label.add( $( '<span>' ).addClass( 'oo-ui-selectFileWidget-fileType' ).text( this.currentFile.type ) ); } $label = $label.add( $( '<span>' ).text( this.currentFile.name ) ); this.setLabel( $label ); } else { this.$element.addClass( 'oo-ui-selectFileWidget-empty' ); this.setLabel( this.placeholder ); } } if ( this.$input ) { this.$input.attr( 'title', this.getLabel() ); } }; /** * Add the input to the widget * * @private */ OO.ui.SelectFileWidget.prototype.addInput = function () { if ( this.$input ) { this.$input.remove(); } if ( !this.isSupported ) { this.$input = null; return; } this.$input = $( '<input type="file">' ); this.$input.on( 'change', this.onFileSelectedHandler ); this.$input.attr( { tabindex: -1, title: this.getLabel() } ); if ( this.accept ) { this.$input.attr( 'accept', this.accept.join( ', ' ) ); } this.selectButton.$button.append( this.$input ); }; /** * Determine if we should accept this file * * @private * @param {string} File MIME type * @return {boolean} */ OO.ui.SelectFileWidget.prototype.isAllowedType = function ( mimeType ) { var i, mimeTest; if ( !this.accept || !mimeType ) { return true; } for ( i = 0; i < this.accept.length; i++ ) { mimeTest = this.accept[ i ]; if ( mimeTest === mimeType ) { return true; } else if ( mimeTest.substr( -2 ) === '/*' ) { mimeTest = mimeTest.substr( 0, mimeTest.length - 1 ); if ( mimeType.substr( 0, mimeTest.length ) === mimeTest ) { return true; } } } return false; }; /** * Handle file selection from the input * * @private * @param {jQuery.Event} e */ OO.ui.SelectFileWidget.prototype.onFileSelected = function ( e ) { var file = OO.getProp( e.target, 'files', 0 ) || null; if ( file && !this.isAllowedType( file.type ) ) { file = null; } this.setValue( file ); this.addInput(); }; /** * Handle clear button click events. * * @private */ OO.ui.SelectFileWidget.prototype.onClearClick = function () { this.setValue( null ); return false; }; /** * Handle key press events. * * @private * @param {jQuery.Event} e Key press event */ OO.ui.SelectFileWidget.prototype.onKeyPress = function ( e ) { if ( this.isSupported && !this.isDisabled() && this.$input && ( e.which === OO.ui.Keys.SPACE || e.which === OO.ui.Keys.ENTER ) ) { this.$input.click(); return false; } }; /** * Handle drop target click events. * * @private * @param {jQuery.Event} e Key press event */ OO.ui.SelectFileWidget.prototype.onDropTargetClick = function () { if ( this.isSupported && !this.isDisabled() && this.$input ) { this.$input.click(); return false; } }; /** * Handle drag enter and over events * * @private * @param {jQuery.Event} e Drag event */ OO.ui.SelectFileWidget.prototype.onDragEnterOrOver = function ( e ) { var itemOrFile, droppableFile = false, dt = e.originalEvent.dataTransfer; e.preventDefault(); e.stopPropagation(); if ( this.isDisabled() || !this.isSupported ) { this.$element.removeClass( 'oo-ui-selectFileWidget-canDrop' ); dt.dropEffect = 'none'; return false; } // DataTransferItem and File both have a type property, but in Chrome files // have no information at this point. itemOrFile = OO.getProp( dt, 'items', 0 ) || OO.getProp( dt, 'files', 0 ); if ( itemOrFile ) { if ( this.isAllowedType( itemOrFile.type ) ) { droppableFile = true; } // dt.types is Array-like, but not an Array } else if ( Array.prototype.indexOf.call( OO.getProp( dt, 'types' ) || [], 'Files' ) !== -1 ) { // File information is not available at this point for security so just assume // it is acceptable for now. // https://bugzilla.mozilla.org/show_bug.cgi?id=640534 droppableFile = true; } this.$element.toggleClass( 'oo-ui-selectFileWidget-canDrop', droppableFile ); if ( !droppableFile ) { dt.dropEffect = 'none'; } return false; }; /** * Handle drag leave events * * @private * @param {jQuery.Event} e Drag event */ OO.ui.SelectFileWidget.prototype.onDragLeave = function () { this.$element.removeClass( 'oo-ui-selectFileWidget-canDrop' ); }; /** * Handle drop events * * @private * @param {jQuery.Event} e Drop event */ OO.ui.SelectFileWidget.prototype.onDrop = function ( e ) { var file = null, dt = e.originalEvent.dataTransfer; e.preventDefault(); e.stopPropagation(); this.$element.removeClass( 'oo-ui-selectFileWidget-canDrop' ); if ( this.isDisabled() || !this.isSupported ) { return false; } file = OO.getProp( dt, 'files', 0 ); if ( file && !this.isAllowedType( file.type ) ) { file = null; } if ( file ) { this.setValue( file ); } return false; }; /** * @inheritdoc */ OO.ui.SelectFileWidget.prototype.setDisabled = function ( disabled ) { OO.ui.SelectFileWidget.parent.prototype.setDisabled.call( this, disabled ); if ( this.selectButton ) { this.selectButton.setDisabled( disabled ); } if ( this.clearButton ) { this.clearButton.setDisabled( disabled ); } return this; }; /** * IconWidget is a generic widget for {@link OO.ui.mixin.IconElement icons}. In general, IconWidgets should be used with OO.ui.LabelWidget, * which creates a label that identifies the icon’s function. See the [OOjs UI documentation on MediaWiki] [1] * for a list of icons included in the library. * * @example * // An icon widget with a label * var myIcon = new OO.ui.IconWidget( { * icon: 'help', * iconTitle: 'Help' * } ); * // Create a label. * var iconLabel = new OO.ui.LabelWidget( { * label: 'Help' * } ); * $( 'body' ).append( myIcon.$element, iconLabel.$element ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Icons,_Indicators,_and_Labels#Icons * * @class * @extends OO.ui.Widget * @mixins OO.ui.mixin.IconElement * @mixins OO.ui.mixin.TitledElement * @mixins OO.ui.mixin.FlaggedElement * * @constructor * @param {Object} [config] Configuration options */ OO.ui.IconWidget = function OoUiIconWidget( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.IconWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.IconElement.call( this, $.extend( {}, config, { $icon: this.$element } ) ); OO.ui.mixin.TitledElement.call( this, $.extend( {}, config, { $titled: this.$element } ) ); OO.ui.mixin.FlaggedElement.call( this, $.extend( {}, config, { $flagged: this.$element } ) ); // Initialization this.$element.addClass( 'oo-ui-iconWidget' ); }; /* Setup */ OO.inheritClass( OO.ui.IconWidget, OO.ui.Widget ); OO.mixinClass( OO.ui.IconWidget, OO.ui.mixin.IconElement ); OO.mixinClass( OO.ui.IconWidget, OO.ui.mixin.TitledElement ); OO.mixinClass( OO.ui.IconWidget, OO.ui.mixin.FlaggedElement ); /* Static Properties */ OO.ui.IconWidget.static.tagName = 'span'; /** * IndicatorWidgets create indicators, which are small graphics that are generally used to draw * attention to the status of an item or to clarify the function of a control. For a list of * indicators included in the library, please see the [OOjs UI documentation on MediaWiki][1]. * * @example * // Example of an indicator widget * var indicator1 = new OO.ui.IndicatorWidget( { * indicator: 'alert' * } ); * * // Create a fieldset layout to add a label * var fieldset = new OO.ui.FieldsetLayout(); * fieldset.addItems( [ * new OO.ui.FieldLayout( indicator1, { label: 'An alert indicator:' } ) * ] ); * $( 'body' ).append( fieldset.$element ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Icons,_Indicators,_and_Labels#Indicators * * @class * @extends OO.ui.Widget * @mixins OO.ui.mixin.IndicatorElement * @mixins OO.ui.mixin.TitledElement * * @constructor * @param {Object} [config] Configuration options */ OO.ui.IndicatorWidget = function OoUiIndicatorWidget( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.IndicatorWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.IndicatorElement.call( this, $.extend( {}, config, { $indicator: this.$element } ) ); OO.ui.mixin.TitledElement.call( this, $.extend( {}, config, { $titled: this.$element } ) ); // Initialization this.$element.addClass( 'oo-ui-indicatorWidget' ); }; /* Setup */ OO.inheritClass( OO.ui.IndicatorWidget, OO.ui.Widget ); OO.mixinClass( OO.ui.IndicatorWidget, OO.ui.mixin.IndicatorElement ); OO.mixinClass( OO.ui.IndicatorWidget, OO.ui.mixin.TitledElement ); /* Static Properties */ OO.ui.IndicatorWidget.static.tagName = 'span'; /** * InputWidget is the base class for all input widgets, which * include {@link OO.ui.TextInputWidget text inputs}, {@link OO.ui.CheckboxInputWidget checkbox inputs}, * {@link OO.ui.RadioInputWidget radio inputs}, and {@link OO.ui.ButtonInputWidget button inputs}. * See the [OOjs UI documentation on MediaWiki] [1] for more information and examples. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Inputs * * @abstract * @class * @extends OO.ui.Widget * @mixins OO.ui.mixin.FlaggedElement * @mixins OO.ui.mixin.TabIndexedElement * @mixins OO.ui.mixin.TitledElement * @mixins OO.ui.mixin.AccessKeyedElement * * @constructor * @param {Object} [config] Configuration options * @cfg {string} [name=''] The value of the input’s HTML `name` attribute. * @cfg {string} [value=''] The value of the input. * @cfg {string} [dir] The directionality of the input (ltr/rtl). * @cfg {Function} [inputFilter] The name of an input filter function. Input filters modify the value of an input * before it is accepted. */ OO.ui.InputWidget = function OoUiInputWidget( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.InputWidget.parent.call( this, config ); // Properties this.$input = this.getInputElement( config ); this.value = ''; this.inputFilter = config.inputFilter; // Mixin constructors OO.ui.mixin.FlaggedElement.call( this, config ); OO.ui.mixin.TabIndexedElement.call( this, $.extend( {}, config, { $tabIndexed: this.$input } ) ); OO.ui.mixin.TitledElement.call( this, $.extend( {}, config, { $titled: this.$input } ) ); OO.ui.mixin.AccessKeyedElement.call( this, $.extend( {}, config, { $accessKeyed: this.$input } ) ); // Events this.$input.on( 'keydown mouseup cut paste change input select', this.onEdit.bind( this ) ); // Initialization this.$input .addClass( 'oo-ui-inputWidget-input' ) .attr( 'name', config.name ) .prop( 'disabled', this.isDisabled() ); this.$element .addClass( 'oo-ui-inputWidget' ) .append( this.$input ); this.setValue( config.value ); this.setAccessKey( config.accessKey ); if ( config.dir ) { this.setDir( config.dir ); } }; /* Setup */ OO.inheritClass( OO.ui.InputWidget, OO.ui.Widget ); OO.mixinClass( OO.ui.InputWidget, OO.ui.mixin.FlaggedElement ); OO.mixinClass( OO.ui.InputWidget, OO.ui.mixin.TabIndexedElement ); OO.mixinClass( OO.ui.InputWidget, OO.ui.mixin.TitledElement ); OO.mixinClass( OO.ui.InputWidget, OO.ui.mixin.AccessKeyedElement ); /* Static Properties */ OO.ui.InputWidget.static.supportsSimpleLabel = true; /* Static Methods */ /** * @inheritdoc */ OO.ui.InputWidget.static.reusePreInfuseDOM = function ( node, config ) { config = OO.ui.InputWidget.parent.static.reusePreInfuseDOM( node, config ); // Reusing $input lets browsers preserve inputted values across page reloads (T114134) config.$input = $( node ).find( '.oo-ui-inputWidget-input' ); return config; }; /** * @inheritdoc */ OO.ui.InputWidget.static.gatherPreInfuseState = function ( node, config ) { var state = OO.ui.InputWidget.parent.static.gatherPreInfuseState( node, config ); state.value = config.$input.val(); // Might be better in TabIndexedElement, but it's awkward to do there because mixins are awkward state.focus = config.$input.is( ':focus' ); return state; }; /* Events */ /** * @event change * * A change event is emitted when the value of the input changes. * * @param {string} value */ /* Methods */ /** * Get input element. * * Subclasses of OO.ui.InputWidget use the `config` parameter to produce different elements in * different circumstances. The element must have a `value` property (like form elements). * * @protected * @param {Object} config Configuration options * @return {jQuery} Input element */ OO.ui.InputWidget.prototype.getInputElement = function ( config ) { // See #reusePreInfuseDOM about config.$input return config.$input || $( '<input>' ); }; /** * Handle potentially value-changing events. * * @private * @param {jQuery.Event} e Key down, mouse up, cut, paste, change, input, or select event */ OO.ui.InputWidget.prototype.onEdit = function () { var widget = this; if ( !this.isDisabled() ) { // Allow the stack to clear so the value will be updated setTimeout( function () { widget.setValue( widget.$input.val() ); } ); } }; /** * Get the value of the input. * * @return {string} Input value */ OO.ui.InputWidget.prototype.getValue = function () { // Resynchronize our internal data with DOM data. Other scripts executing on the page can modify // it, and we won't know unless they're kind enough to trigger a 'change' event. var value = this.$input.val(); if ( this.value !== value ) { this.setValue( value ); } return this.value; }; /** * Set the directionality of the input, either RTL (right-to-left) or LTR (left-to-right). * * @deprecated since v0.13.1, use #setDir directly * @param {boolean} isRTL Directionality is right-to-left * @chainable */ OO.ui.InputWidget.prototype.setRTL = function ( isRTL ) { this.setDir( isRTL ? 'rtl' : 'ltr' ); return this; }; /** * Set the directionality of the input. * * @param {string} dir Text directionality: 'ltr', 'rtl' or 'auto' * @chainable */ OO.ui.InputWidget.prototype.setDir = function ( dir ) { this.$input.prop( 'dir', dir ); return this; }; /** * Set the value of the input. * * @param {string} value New value * @fires change * @chainable */ OO.ui.InputWidget.prototype.setValue = function ( value ) { value = this.cleanUpValue( value ); // Update the DOM if it has changed. Note that with cleanUpValue, it // is possible for the DOM value to change without this.value changing. if ( this.$input.val() !== value ) { this.$input.val( value ); } if ( this.value !== value ) { this.value = value; this.emit( 'change', this.value ); } return this; }; /** * Set the input's access key. * FIXME: This is the same code as in OO.ui.mixin.ButtonElement, maybe find a better place for it? * * @param {string} accessKey Input's access key, use empty string to remove * @chainable */ OO.ui.InputWidget.prototype.setAccessKey = function ( accessKey ) { accessKey = typeof accessKey === 'string' && accessKey.length ? accessKey : null; if ( this.accessKey !== accessKey ) { if ( this.$input ) { if ( accessKey !== null ) { this.$input.attr( 'accesskey', accessKey ); } else { this.$input.removeAttr( 'accesskey' ); } } this.accessKey = accessKey; } return this; }; /** * Clean up incoming value. * * Ensures value is a string, and converts undefined and null to empty string. * * @private * @param {string} value Original value * @return {string} Cleaned up value */ OO.ui.InputWidget.prototype.cleanUpValue = function ( value ) { if ( value === undefined || value === null ) { return ''; } else if ( this.inputFilter ) { return this.inputFilter( String( value ) ); } else { return String( value ); } }; /** * Simulate the behavior of clicking on a label bound to this input. This method is only called by * {@link OO.ui.LabelWidget LabelWidget} and {@link OO.ui.FieldLayout FieldLayout}. It should not be * called directly. */ OO.ui.InputWidget.prototype.simulateLabelClick = function () { if ( !this.isDisabled() ) { if ( this.$input.is( ':checkbox, :radio' ) ) { this.$input.click(); } if ( this.$input.is( ':input' ) ) { this.$input[ 0 ].focus(); } } }; /** * @inheritdoc */ OO.ui.InputWidget.prototype.setDisabled = function ( state ) { OO.ui.InputWidget.parent.prototype.setDisabled.call( this, state ); if ( this.$input ) { this.$input.prop( 'disabled', this.isDisabled() ); } return this; }; /** * Focus the input. * * @chainable */ OO.ui.InputWidget.prototype.focus = function () { this.$input[ 0 ].focus(); return this; }; /** * Blur the input. * * @chainable */ OO.ui.InputWidget.prototype.blur = function () { this.$input[ 0 ].blur(); return this; }; /** * @inheritdoc */ OO.ui.InputWidget.prototype.restorePreInfuseState = function ( state ) { OO.ui.InputWidget.parent.prototype.restorePreInfuseState.call( this, state ); if ( state.value !== undefined && state.value !== this.getValue() ) { this.setValue( state.value ); } if ( state.focus ) { this.focus(); } }; /** * ButtonInputWidget is used to submit HTML forms and is intended to be used within * a OO.ui.FormLayout. If you do not need the button to work with HTML forms, you probably * want to use OO.ui.ButtonWidget instead. Button input widgets can be rendered as either an * HTML `<button/>` (the default) or an HTML `<input/>` tags. See the * [OOjs UI documentation on MediaWiki] [1] for more information. * * @example * // A ButtonInputWidget rendered as an HTML button, the default. * var button = new OO.ui.ButtonInputWidget( { * label: 'Input button', * icon: 'check', * value: 'check' * } ); * $( 'body' ).append( button.$element ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Inputs#Button_inputs * * @class * @extends OO.ui.InputWidget * @mixins OO.ui.mixin.ButtonElement * @mixins OO.ui.mixin.IconElement * @mixins OO.ui.mixin.IndicatorElement * @mixins OO.ui.mixin.LabelElement * @mixins OO.ui.mixin.TitledElement * * @constructor * @param {Object} [config] Configuration options * @cfg {string} [type='button'] The value of the HTML `'type'` attribute: 'button', 'submit' or 'reset'. * @cfg {boolean} [useInputTag=false] Use an `<input/>` tag instead of a `<button/>` tag, the default. * Widgets configured to be an `<input/>` do not support {@link #icon icons} and {@link #indicator indicators}, * non-plaintext {@link #label labels}, or {@link #value values}. In general, useInputTag should only * be set to `true` when there’s need to support IE6 in a form with multiple buttons. */ OO.ui.ButtonInputWidget = function OoUiButtonInputWidget( config ) { // Configuration initialization config = $.extend( { type: 'button', useInputTag: false }, config ); // Properties (must be set before parent constructor, which calls #setValue) this.useInputTag = config.useInputTag; // Parent constructor OO.ui.ButtonInputWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.ButtonElement.call( this, $.extend( {}, config, { $button: this.$input } ) ); OO.ui.mixin.IconElement.call( this, config ); OO.ui.mixin.IndicatorElement.call( this, config ); OO.ui.mixin.LabelElement.call( this, config ); OO.ui.mixin.TitledElement.call( this, $.extend( {}, config, { $titled: this.$input } ) ); // Initialization if ( !config.useInputTag ) { this.$input.append( this.$icon, this.$label, this.$indicator ); } this.$element.addClass( 'oo-ui-buttonInputWidget' ); }; /* Setup */ OO.inheritClass( OO.ui.ButtonInputWidget, OO.ui.InputWidget ); OO.mixinClass( OO.ui.ButtonInputWidget, OO.ui.mixin.ButtonElement ); OO.mixinClass( OO.ui.ButtonInputWidget, OO.ui.mixin.IconElement ); OO.mixinClass( OO.ui.ButtonInputWidget, OO.ui.mixin.IndicatorElement ); OO.mixinClass( OO.ui.ButtonInputWidget, OO.ui.mixin.LabelElement ); OO.mixinClass( OO.ui.ButtonInputWidget, OO.ui.mixin.TitledElement ); /* Static Properties */ /** * Disable generating `<label>` elements for buttons. One would very rarely need additional label * for a button, and it's already a big clickable target, and it causes unexpected rendering. */ OO.ui.ButtonInputWidget.static.supportsSimpleLabel = false; /* Methods */ /** * @inheritdoc * @protected */ OO.ui.ButtonInputWidget.prototype.getInputElement = function ( config ) { var type; // See InputWidget#reusePreInfuseDOM about config.$input if ( config.$input ) { return config.$input.empty(); } type = [ 'button', 'submit', 'reset' ].indexOf( config.type ) !== -1 ? config.type : 'button'; return $( '<' + ( config.useInputTag ? 'input' : 'button' ) + ' type="' + type + '">' ); }; /** * Set label value. * * If #useInputTag is `true`, the label is set as the `value` of the `<input/>` tag. * * @param {jQuery|string|Function|null} label Label nodes, text, a function that returns nodes or * text, or `null` for no label * @chainable */ OO.ui.ButtonInputWidget.prototype.setLabel = function ( label ) { OO.ui.mixin.LabelElement.prototype.setLabel.call( this, label ); if ( this.useInputTag ) { if ( typeof label === 'function' ) { label = OO.ui.resolveMsg( label ); } if ( label instanceof jQuery ) { label = label.text(); } if ( !label ) { label = ''; } this.$input.val( label ); } return this; }; /** * Set the value of the input. * * This method is disabled for button inputs configured as {@link #useInputTag <input/> tags}, as * they do not support {@link #value values}. * * @param {string} value New value * @chainable */ OO.ui.ButtonInputWidget.prototype.setValue = function ( value ) { if ( !this.useInputTag ) { OO.ui.ButtonInputWidget.parent.prototype.setValue.call( this, value ); } return this; }; /** * CheckboxInputWidgets, like HTML checkboxes, can be selected and/or configured with a value. * Note that these {@link OO.ui.InputWidget input widgets} are best laid out * in {@link OO.ui.FieldLayout field layouts} that use the {@link OO.ui.FieldLayout#align inline} * alignment. For more information, please see the [OOjs UI documentation on MediaWiki][1]. * * This widget can be used inside a HTML form, such as a OO.ui.FormLayout. * * @example * // An example of selected, unselected, and disabled checkbox inputs * var checkbox1=new OO.ui.CheckboxInputWidget( { * value: 'a', * selected: true * } ); * var checkbox2=new OO.ui.CheckboxInputWidget( { * value: 'b' * } ); * var checkbox3=new OO.ui.CheckboxInputWidget( { * value:'c', * disabled: true * } ); * // Create a fieldset layout with fields for each checkbox. * var fieldset = new OO.ui.FieldsetLayout( { * label: 'Checkboxes' * } ); * fieldset.addItems( [ * new OO.ui.FieldLayout( checkbox1, { label: 'Selected checkbox', align: 'inline' } ), * new OO.ui.FieldLayout( checkbox2, { label: 'Unselected checkbox', align: 'inline' } ), * new OO.ui.FieldLayout( checkbox3, { label: 'Disabled checkbox', align: 'inline' } ), * ] ); * $( 'body' ).append( fieldset.$element ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Inputs * * @class * @extends OO.ui.InputWidget * * @constructor * @param {Object} [config] Configuration options * @cfg {boolean} [selected=false] Select the checkbox initially. By default, the checkbox is not selected. */ OO.ui.CheckboxInputWidget = function OoUiCheckboxInputWidget( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.CheckboxInputWidget.parent.call( this, config ); // Initialization this.$element .addClass( 'oo-ui-checkboxInputWidget' ) // Required for pretty styling in MediaWiki theme .append( $( '<span>' ) ); this.setSelected( config.selected !== undefined ? config.selected : false ); }; /* Setup */ OO.inheritClass( OO.ui.CheckboxInputWidget, OO.ui.InputWidget ); /* Static Methods */ /** * @inheritdoc */ OO.ui.CheckboxInputWidget.static.gatherPreInfuseState = function ( node, config ) { var state = OO.ui.CheckboxInputWidget.parent.static.gatherPreInfuseState( node, config ); state.checked = config.$input.prop( 'checked' ); return state; }; /* Methods */ /** * @inheritdoc * @protected */ OO.ui.CheckboxInputWidget.prototype.getInputElement = function () { return $( '<input type="checkbox" />' ); }; /** * @inheritdoc */ OO.ui.CheckboxInputWidget.prototype.onEdit = function () { var widget = this; if ( !this.isDisabled() ) { // Allow the stack to clear so the value will be updated setTimeout( function () { widget.setSelected( widget.$input.prop( 'checked' ) ); } ); } }; /** * Set selection state of this checkbox. * * @param {boolean} state `true` for selected * @chainable */ OO.ui.CheckboxInputWidget.prototype.setSelected = function ( state ) { state = !!state; if ( this.selected !== state ) { this.selected = state; this.$input.prop( 'checked', this.selected ); this.emit( 'change', this.selected ); } return this; }; /** * Check if this checkbox is selected. * * @return {boolean} Checkbox is selected */ OO.ui.CheckboxInputWidget.prototype.isSelected = function () { // Resynchronize our internal data with DOM data. Other scripts executing on the page can modify // it, and we won't know unless they're kind enough to trigger a 'change' event. var selected = this.$input.prop( 'checked' ); if ( this.selected !== selected ) { this.setSelected( selected ); } return this.selected; }; /** * @inheritdoc */ OO.ui.CheckboxInputWidget.prototype.restorePreInfuseState = function ( state ) { OO.ui.CheckboxInputWidget.parent.prototype.restorePreInfuseState.call( this, state ); if ( state.checked !== undefined && state.checked !== this.isSelected() ) { this.setSelected( state.checked ); } }; /** * DropdownInputWidget is a {@link OO.ui.DropdownWidget DropdownWidget} intended to be used * within a HTML form, such as a OO.ui.FormLayout. The selected value is synchronized with the value * of a hidden HTML `input` tag. Please see the [OOjs UI documentation on MediaWiki][1] for * more information about input widgets. * * A DropdownInputWidget always has a value (one of the options is always selected), unless there * are no options. If no `value` configuration option is provided, the first option is selected. * If you need a state representing no value (no option being selected), use a DropdownWidget. * * This and OO.ui.RadioSelectInputWidget support the same configuration options. * * @example * // Example: A DropdownInputWidget with three options * var dropdownInput = new OO.ui.DropdownInputWidget( { * options: [ * { data: 'a', label: 'First' }, * { data: 'b', label: 'Second'}, * { data: 'c', label: 'Third' } * ] * } ); * $( 'body' ).append( dropdownInput.$element ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Inputs * * @class * @extends OO.ui.InputWidget * @mixins OO.ui.mixin.TitledElement * * @constructor * @param {Object} [config] Configuration options * @cfg {Object[]} [options=[]] Array of menu options in the format `{ data: …, label: … }` * @cfg {Object} [dropdown] Configuration options for {@link OO.ui.DropdownWidget DropdownWidget} */ OO.ui.DropdownInputWidget = function OoUiDropdownInputWidget( config ) { // Configuration initialization config = config || {}; // Properties (must be done before parent constructor which calls #setDisabled) this.dropdownWidget = new OO.ui.DropdownWidget( config.dropdown ); // Parent constructor OO.ui.DropdownInputWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.TitledElement.call( this, config ); // Events this.dropdownWidget.getMenu().connect( this, { select: 'onMenuSelect' } ); // Initialization this.setOptions( config.options || [] ); this.$element .addClass( 'oo-ui-dropdownInputWidget' ) .append( this.dropdownWidget.$element ); }; /* Setup */ OO.inheritClass( OO.ui.DropdownInputWidget, OO.ui.InputWidget ); OO.mixinClass( OO.ui.DropdownInputWidget, OO.ui.mixin.TitledElement ); /* Methods */ /** * @inheritdoc * @protected */ OO.ui.DropdownInputWidget.prototype.getInputElement = function ( config ) { // See InputWidget#reusePreInfuseDOM about config.$input if ( config.$input ) { return config.$input.addClass( 'oo-ui-element-hidden' ); } return $( '<input type="hidden">' ); }; /** * Handles menu select events. * * @private * @param {OO.ui.MenuOptionWidget} item Selected menu item */ OO.ui.DropdownInputWidget.prototype.onMenuSelect = function ( item ) { this.setValue( item.getData() ); }; /** * @inheritdoc */ OO.ui.DropdownInputWidget.prototype.setValue = function ( value ) { value = this.cleanUpValue( value ); this.dropdownWidget.getMenu().selectItemByData( value ); OO.ui.DropdownInputWidget.parent.prototype.setValue.call( this, value ); return this; }; /** * @inheritdoc */ OO.ui.DropdownInputWidget.prototype.setDisabled = function ( state ) { this.dropdownWidget.setDisabled( state ); OO.ui.DropdownInputWidget.parent.prototype.setDisabled.call( this, state ); return this; }; /** * Set the options available for this input. * * @param {Object[]} options Array of menu options in the format `{ data: …, label: … }` * @chainable */ OO.ui.DropdownInputWidget.prototype.setOptions = function ( options ) { var value = this.getValue(), widget = this; // Rebuild the dropdown menu this.dropdownWidget.getMenu() .clearItems() .addItems( options.map( function ( opt ) { var optValue = widget.cleanUpValue( opt.data ); return new OO.ui.MenuOptionWidget( { data: optValue, label: opt.label !== undefined ? opt.label : optValue } ); } ) ); // Restore the previous value, or reset to something sensible if ( this.dropdownWidget.getMenu().getItemFromData( value ) ) { // Previous value is still available, ensure consistency with the dropdown this.setValue( value ); } else { // No longer valid, reset if ( options.length ) { this.setValue( options[ 0 ].data ); } } return this; }; /** * @inheritdoc */ OO.ui.DropdownInputWidget.prototype.focus = function () { this.dropdownWidget.getMenu().toggle( true ); return this; }; /** * @inheritdoc */ OO.ui.DropdownInputWidget.prototype.blur = function () { this.dropdownWidget.getMenu().toggle( false ); return this; }; /** * RadioInputWidget creates a single radio button. Because radio buttons are usually used as a set, * in most cases you will want to use a {@link OO.ui.RadioSelectWidget radio select} * with {@link OO.ui.RadioOptionWidget radio options} instead of this class. For more information, * please see the [OOjs UI documentation on MediaWiki][1]. * * This widget can be used inside a HTML form, such as a OO.ui.FormLayout. * * @example * // An example of selected, unselected, and disabled radio inputs * var radio1 = new OO.ui.RadioInputWidget( { * value: 'a', * selected: true * } ); * var radio2 = new OO.ui.RadioInputWidget( { * value: 'b' * } ); * var radio3 = new OO.ui.RadioInputWidget( { * value: 'c', * disabled: true * } ); * // Create a fieldset layout with fields for each radio button. * var fieldset = new OO.ui.FieldsetLayout( { * label: 'Radio inputs' * } ); * fieldset.addItems( [ * new OO.ui.FieldLayout( radio1, { label: 'Selected', align: 'inline' } ), * new OO.ui.FieldLayout( radio2, { label: 'Unselected', align: 'inline' } ), * new OO.ui.FieldLayout( radio3, { label: 'Disabled', align: 'inline' } ), * ] ); * $( 'body' ).append( fieldset.$element ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Inputs * * @class * @extends OO.ui.InputWidget * * @constructor * @param {Object} [config] Configuration options * @cfg {boolean} [selected=false] Select the radio button initially. By default, the radio button is not selected. */ OO.ui.RadioInputWidget = function OoUiRadioInputWidget( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.RadioInputWidget.parent.call( this, config ); // Initialization this.$element .addClass( 'oo-ui-radioInputWidget' ) // Required for pretty styling in MediaWiki theme .append( $( '<span>' ) ); this.setSelected( config.selected !== undefined ? config.selected : false ); }; /* Setup */ OO.inheritClass( OO.ui.RadioInputWidget, OO.ui.InputWidget ); /* Static Methods */ /** * @inheritdoc */ OO.ui.RadioInputWidget.static.gatherPreInfuseState = function ( node, config ) { var state = OO.ui.RadioInputWidget.parent.static.gatherPreInfuseState( node, config ); state.checked = config.$input.prop( 'checked' ); return state; }; /* Methods */ /** * @inheritdoc * @protected */ OO.ui.RadioInputWidget.prototype.getInputElement = function () { return $( '<input type="radio" />' ); }; /** * @inheritdoc */ OO.ui.RadioInputWidget.prototype.onEdit = function () { // RadioInputWidget doesn't track its state. }; /** * Set selection state of this radio button. * * @param {boolean} state `true` for selected * @chainable */ OO.ui.RadioInputWidget.prototype.setSelected = function ( state ) { // RadioInputWidget doesn't track its state. this.$input.prop( 'checked', state ); return this; }; /** * Check if this radio button is selected. * * @return {boolean} Radio is selected */ OO.ui.RadioInputWidget.prototype.isSelected = function () { return this.$input.prop( 'checked' ); }; /** * @inheritdoc */ OO.ui.RadioInputWidget.prototype.restorePreInfuseState = function ( state ) { OO.ui.RadioInputWidget.parent.prototype.restorePreInfuseState.call( this, state ); if ( state.checked !== undefined && state.checked !== this.isSelected() ) { this.setSelected( state.checked ); } }; /** * RadioSelectInputWidget is a {@link OO.ui.RadioSelectWidget RadioSelectWidget} intended to be used * within a HTML form, such as a OO.ui.FormLayout. The selected value is synchronized with the value * of a hidden HTML `input` tag. Please see the [OOjs UI documentation on MediaWiki][1] for * more information about input widgets. * * This and OO.ui.DropdownInputWidget support the same configuration options. * * @example * // Example: A RadioSelectInputWidget with three options * var radioSelectInput = new OO.ui.RadioSelectInputWidget( { * options: [ * { data: 'a', label: 'First' }, * { data: 'b', label: 'Second'}, * { data: 'c', label: 'Third' } * ] * } ); * $( 'body' ).append( radioSelectInput.$element ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Inputs * * @class * @extends OO.ui.InputWidget * * @constructor * @param {Object} [config] Configuration options * @cfg {Object[]} [options=[]] Array of menu options in the format `{ data: …, label: … }` */ OO.ui.RadioSelectInputWidget = function OoUiRadioSelectInputWidget( config ) { // Configuration initialization config = config || {}; // Properties (must be done before parent constructor which calls #setDisabled) this.radioSelectWidget = new OO.ui.RadioSelectWidget(); // Parent constructor OO.ui.RadioSelectInputWidget.parent.call( this, config ); // Events this.radioSelectWidget.connect( this, { select: 'onMenuSelect' } ); // Initialization this.setOptions( config.options || [] ); this.$element .addClass( 'oo-ui-radioSelectInputWidget' ) .append( this.radioSelectWidget.$element ); }; /* Setup */ OO.inheritClass( OO.ui.RadioSelectInputWidget, OO.ui.InputWidget ); /* Static Properties */ OO.ui.RadioSelectInputWidget.static.supportsSimpleLabel = false; /* Static Methods */ /** * @inheritdoc */ OO.ui.RadioSelectInputWidget.static.gatherPreInfuseState = function ( node, config ) { var state = OO.ui.RadioSelectInputWidget.parent.static.gatherPreInfuseState( node, config ); state.value = $( node ).find( '.oo-ui-radioInputWidget .oo-ui-inputWidget-input:checked' ).val(); return state; }; /* Methods */ /** * @inheritdoc * @protected */ OO.ui.RadioSelectInputWidget.prototype.getInputElement = function () { return $( '<input type="hidden">' ); }; /** * Handles menu select events. * * @private * @param {OO.ui.RadioOptionWidget} item Selected menu item */ OO.ui.RadioSelectInputWidget.prototype.onMenuSelect = function ( item ) { this.setValue( item.getData() ); }; /** * @inheritdoc */ OO.ui.RadioSelectInputWidget.prototype.setValue = function ( value ) { value = this.cleanUpValue( value ); this.radioSelectWidget.selectItemByData( value ); OO.ui.RadioSelectInputWidget.parent.prototype.setValue.call( this, value ); return this; }; /** * @inheritdoc */ OO.ui.RadioSelectInputWidget.prototype.setDisabled = function ( state ) { this.radioSelectWidget.setDisabled( state ); OO.ui.RadioSelectInputWidget.parent.prototype.setDisabled.call( this, state ); return this; }; /** * Set the options available for this input. * * @param {Object[]} options Array of menu options in the format `{ data: …, label: … }` * @chainable */ OO.ui.RadioSelectInputWidget.prototype.setOptions = function ( options ) { var value = this.getValue(), widget = this; // Rebuild the radioSelect menu this.radioSelectWidget .clearItems() .addItems( options.map( function ( opt ) { var optValue = widget.cleanUpValue( opt.data ); return new OO.ui.RadioOptionWidget( { data: optValue, label: opt.label !== undefined ? opt.label : optValue } ); } ) ); // Restore the previous value, or reset to something sensible if ( this.radioSelectWidget.getItemFromData( value ) ) { // Previous value is still available, ensure consistency with the radioSelect this.setValue( value ); } else { // No longer valid, reset if ( options.length ) { this.setValue( options[ 0 ].data ); } } return this; }; /** * TextInputWidgets, like HTML text inputs, can be configured with options that customize the * size of the field as well as its presentation. In addition, these widgets can be configured * with {@link OO.ui.mixin.IconElement icons}, {@link OO.ui.mixin.IndicatorElement indicators}, an optional * validation-pattern (used to determine if an input value is valid or not) and an input filter, * which modifies incoming values rather than validating them. * Please see the [OOjs UI documentation on MediaWiki] [1] for more information and examples. * * This widget can be used inside a HTML form, such as a OO.ui.FormLayout. * * @example * // Example of a text input widget * var textInput = new OO.ui.TextInputWidget( { * value: 'Text input' * } ) * $( 'body' ).append( textInput.$element ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Inputs * * @class * @extends OO.ui.InputWidget * @mixins OO.ui.mixin.IconElement * @mixins OO.ui.mixin.IndicatorElement * @mixins OO.ui.mixin.PendingElement * @mixins OO.ui.mixin.LabelElement * * @constructor * @param {Object} [config] Configuration options * @cfg {string} [type='text'] The value of the HTML `type` attribute: 'text', 'password', 'search', * 'email' or 'url'. Ignored if `multiline` is true. * * Some values of `type` result in additional behaviors: * * - `search`: implies `icon: 'search'` and `indicator: 'clear'`; when clicked, the indicator * empties the text field * @cfg {string} [placeholder] Placeholder text * @cfg {boolean} [autofocus=false] Use an HTML `autofocus` attribute to * instruct the browser to focus this widget. * @cfg {boolean} [readOnly=false] Prevent changes to the value of the text input. * @cfg {number} [maxLength] Maximum number of characters allowed in the input. * @cfg {boolean} [multiline=false] Allow multiple lines of text * @cfg {number} [rows] If multiline, number of visible lines in textarea. If used with `autosize`, * specifies minimum number of rows to display. * @cfg {boolean} [autosize=false] Automatically resize the text input to fit its content. * Use the #maxRows config to specify a maximum number of displayed rows. * @cfg {boolean} [maxRows] Maximum number of rows to display when #autosize is set to true. * Defaults to the maximum of `10` and `2 * rows`, or `10` if `rows` isn't provided. * @cfg {string} [labelPosition='after'] The position of the inline label relative to that of * the value or placeholder text: `'before'` or `'after'` * @cfg {boolean} [required=false] Mark the field as required. Implies `indicator: 'required'`. * @cfg {boolean} [autocomplete=true] Should the browser support autocomplete for this field * @cfg {RegExp|Function|string} [validate] Validation pattern: when string, a symbolic name of a * pattern defined by the class: 'non-empty' (the value cannot be an empty string) or 'integer' * (the value must contain only numbers); when RegExp, a regular expression that must match the * value for it to be considered valid; when Function, a function receiving the value as parameter * that must return true, or promise resolving to true, for it to be considered valid. */ OO.ui.TextInputWidget = function OoUiTextInputWidget( config ) { // Configuration initialization config = $.extend( { type: 'text', labelPosition: 'after' }, config ); if ( config.type === 'search' ) { if ( config.icon === undefined ) { config.icon = 'search'; } // indicator: 'clear' is set dynamically later, depending on value } if ( config.required ) { if ( config.indicator === undefined ) { config.indicator = 'required'; } } // Parent constructor OO.ui.TextInputWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.IconElement.call( this, config ); OO.ui.mixin.IndicatorElement.call( this, config ); OO.ui.mixin.PendingElement.call( this, $.extend( {}, config, { $pending: this.$input } ) ); OO.ui.mixin.LabelElement.call( this, config ); // Properties this.type = this.getSaneType( config ); this.readOnly = false; this.multiline = !!config.multiline; this.autosize = !!config.autosize; this.minRows = config.rows !== undefined ? config.rows : ''; this.maxRows = config.maxRows || Math.max( 2 * ( this.minRows || 0 ), 10 ); this.validate = null; this.styleHeight = null; this.scrollWidth = null; // Clone for resizing if ( this.autosize ) { this.$clone = this.$input .clone() .insertAfter( this.$input ) .attr( 'aria-hidden', 'true' ) .addClass( 'oo-ui-element-hidden' ); } this.setValidation( config.validate ); this.setLabelPosition( config.labelPosition ); // Events this.$input.on( { keypress: this.onKeyPress.bind( this ), blur: this.onBlur.bind( this ) } ); this.$input.one( { focus: this.onElementAttach.bind( this ) } ); this.$icon.on( 'mousedown', this.onIconMouseDown.bind( this ) ); this.$indicator.on( 'mousedown', this.onIndicatorMouseDown.bind( this ) ); this.on( 'labelChange', this.updatePosition.bind( this ) ); this.connect( this, { change: 'onChange', disable: 'onDisable' } ); // Initialization this.$element .addClass( 'oo-ui-textInputWidget oo-ui-textInputWidget-type-' + this.type ) .append( this.$icon, this.$indicator ); this.setReadOnly( !!config.readOnly ); this.updateSearchIndicator(); if ( config.placeholder ) { this.$input.attr( 'placeholder', config.placeholder ); } if ( config.maxLength !== undefined ) { this.$input.attr( 'maxlength', config.maxLength ); } if ( config.autofocus ) { this.$input.attr( 'autofocus', 'autofocus' ); } if ( config.required ) { this.$input.attr( 'required', 'required' ); this.$input.attr( 'aria-required', 'true' ); } if ( config.autocomplete === false ) { this.$input.attr( 'autocomplete', 'off' ); // Turning off autocompletion also disables "form caching" when the user navigates to a // different page and then clicks "Back". Re-enable it when leaving. Borrowed from jQuery UI. $( window ).on( { beforeunload: function () { this.$input.removeAttr( 'autocomplete' ); }.bind( this ), pageshow: function () { // Browsers don't seem to actually fire this event on "Back", they instead just reload the // whole page... it shouldn't hurt, though. this.$input.attr( 'autocomplete', 'off' ); }.bind( this ) } ); } if ( this.multiline && config.rows ) { this.$input.attr( 'rows', config.rows ); } if ( this.label || config.autosize ) { this.installParentChangeDetector(); } }; /* Setup */ OO.inheritClass( OO.ui.TextInputWidget, OO.ui.InputWidget ); OO.mixinClass( OO.ui.TextInputWidget, OO.ui.mixin.IconElement ); OO.mixinClass( OO.ui.TextInputWidget, OO.ui.mixin.IndicatorElement ); OO.mixinClass( OO.ui.TextInputWidget, OO.ui.mixin.PendingElement ); OO.mixinClass( OO.ui.TextInputWidget, OO.ui.mixin.LabelElement ); /* Static Properties */ OO.ui.TextInputWidget.static.validationPatterns = { 'non-empty': /.+/, integer: /^\d+$/ }; /* Static Methods */ /** * @inheritdoc */ OO.ui.TextInputWidget.static.gatherPreInfuseState = function ( node, config ) { var state = OO.ui.TextInputWidget.parent.static.gatherPreInfuseState( node, config ); if ( config.multiline ) { state.scrollTop = config.$input.scrollTop(); } return state; }; /* Events */ /** * An `enter` event is emitted when the user presses 'enter' inside the text box. * * Not emitted if the input is multiline. * * @event enter */ /** * A `resize` event is emitted when autosize is set and the widget resizes * * @event resize */ /* Methods */ /** * Handle icon mouse down events. * * @private * @param {jQuery.Event} e Mouse down event * @fires icon */ OO.ui.TextInputWidget.prototype.onIconMouseDown = function ( e ) { if ( e.which === 1 ) { this.$input[ 0 ].focus(); return false; } }; /** * Handle indicator mouse down events. * * @private * @param {jQuery.Event} e Mouse down event * @fires indicator */ OO.ui.TextInputWidget.prototype.onIndicatorMouseDown = function ( e ) { if ( e.which === 1 ) { if ( this.type === 'search' ) { // Clear the text field this.setValue( '' ); } this.$input[ 0 ].focus(); return false; } }; /** * Handle key press events. * * @private * @param {jQuery.Event} e Key press event * @fires enter If enter key is pressed and input is not multiline */ OO.ui.TextInputWidget.prototype.onKeyPress = function ( e ) { if ( e.which === OO.ui.Keys.ENTER && !this.multiline ) { this.emit( 'enter', e ); } }; /** * Handle blur events. * * @private * @param {jQuery.Event} e Blur event */ OO.ui.TextInputWidget.prototype.onBlur = function () { this.setValidityFlag(); }; /** * Handle element attach events. * * @private * @param {jQuery.Event} e Element attach event */ OO.ui.TextInputWidget.prototype.onElementAttach = function () { // Any previously calculated size is now probably invalid if we reattached elsewhere this.valCache = null; this.adjustSize(); this.positionLabel(); }; /** * Handle change events. * * @param {string} value * @private */ OO.ui.TextInputWidget.prototype.onChange = function () { this.updateSearchIndicator(); this.setValidityFlag(); this.adjustSize(); }; /** * Handle disable events. * * @param {boolean} disabled Element is disabled * @private */ OO.ui.TextInputWidget.prototype.onDisable = function () { this.updateSearchIndicator(); }; /** * Check if the input is {@link #readOnly read-only}. * * @return {boolean} */ OO.ui.TextInputWidget.prototype.isReadOnly = function () { return this.readOnly; }; /** * Set the {@link #readOnly read-only} state of the input. * * @param {boolean} state Make input read-only * @chainable */ OO.ui.TextInputWidget.prototype.setReadOnly = function ( state ) { this.readOnly = !!state; this.$input.prop( 'readOnly', this.readOnly ); this.updateSearchIndicator(); return this; }; /** * Support function for making #onElementAttach work across browsers. * * This whole function could be replaced with one line of code using the DOMNodeInsertedIntoDocument * event, but it's not supported by Firefox and allegedly deprecated, so we only use it as fallback. * * Due to MutationObserver performance woes, #onElementAttach is only somewhat reliably called the * first time that the element gets attached to the documented. */ OO.ui.TextInputWidget.prototype.installParentChangeDetector = function () { var mutationObserver, onRemove, topmostNode, fakeParentNode, MutationObserver = window.MutationObserver || window.WebKitMutationObserver || window.MozMutationObserver, widget = this; if ( MutationObserver ) { // The new way. If only it wasn't so ugly. if ( this.$element.closest( 'html' ).length ) { // Widget is attached already, do nothing. This breaks the functionality of this function when // the widget is detached and reattached. Alas, doing this correctly with MutationObserver // would require observation of the whole document, which would hurt performance of other, // more important code. return; } // Find topmost node in the tree topmostNode = this.$element[ 0 ]; while ( topmostNode.parentNode ) { topmostNode = topmostNode.parentNode; } // We have no way to detect the $element being attached somewhere without observing the entire // DOM with subtree modifications, which would hurt performance. So we cheat: we hook to the // parent node of $element, and instead detect when $element is removed from it (and thus // probably attached somewhere else). If there is no parent, we create a "fake" one. If it // doesn't get attached, we end up back here and create the parent. mutationObserver = new MutationObserver( function ( mutations ) { var i, j, removedNodes; for ( i = 0; i < mutations.length; i++ ) { removedNodes = mutations[ i ].removedNodes; for ( j = 0; j < removedNodes.length; j++ ) { if ( removedNodes[ j ] === topmostNode ) { setTimeout( onRemove, 0 ); return; } } } } ); onRemove = function () { // If the node was attached somewhere else, report it if ( widget.$element.closest( 'html' ).length ) { widget.onElementAttach(); } mutationObserver.disconnect(); widget.installParentChangeDetector(); }; // Create a fake parent and observe it fakeParentNode = $( '<div>' ).append( topmostNode )[ 0 ]; mutationObserver.observe( fakeParentNode, { childList: true } ); } else { // Using the DOMNodeInsertedIntoDocument event is much nicer and less magical, and works for // detachment and reattachment, but it's not supported by Firefox and allegedly deprecated. this.$element.on( 'DOMNodeInsertedIntoDocument', this.onElementAttach.bind( this ) ); } }; /** * Automatically adjust the size of the text input. * * This only affects #multiline inputs that are {@link #autosize autosized}. * * @chainable * @fires resize */ OO.ui.TextInputWidget.prototype.adjustSize = function () { var scrollHeight, innerHeight, outerHeight, maxInnerHeight, measurementError, idealHeight, newHeight, scrollWidth, property; if ( this.multiline && this.$input.val() !== this.valCache ) { if ( this.autosize ) { this.$clone .val( this.$input.val() ) .attr( 'rows', this.minRows ) // Set inline height property to 0 to measure scroll height .css( 'height', 0 ); this.$clone.removeClass( 'oo-ui-element-hidden' ); this.valCache = this.$input.val(); scrollHeight = this.$clone[ 0 ].scrollHeight; // Remove inline height property to measure natural heights this.$clone.css( 'height', '' ); innerHeight = this.$clone.innerHeight(); outerHeight = this.$clone.outerHeight(); // Measure max rows height this.$clone .attr( 'rows', this.maxRows ) .css( 'height', 'auto' ) .val( '' ); maxInnerHeight = this.$clone.innerHeight(); // Difference between reported innerHeight and scrollHeight with no scrollbars present // Equals 1 on Blink-based browsers and 0 everywhere else measurementError = maxInnerHeight - this.$clone[ 0 ].scrollHeight; idealHeight = Math.min( maxInnerHeight, scrollHeight + measurementError ); this.$clone.addClass( 'oo-ui-element-hidden' ); // Only apply inline height when expansion beyond natural height is needed // Use the difference between the inner and outer height as a buffer newHeight = idealHeight > innerHeight ? idealHeight + ( outerHeight - innerHeight ) : ''; if ( newHeight !== this.styleHeight ) { this.$input.css( 'height', newHeight ); this.styleHeight = newHeight; this.emit( 'resize' ); } } scrollWidth = this.$input[ 0 ].offsetWidth - this.$input[ 0 ].clientWidth; if ( scrollWidth !== this.scrollWidth ) { property = this.$element.css( 'direction' ) === 'rtl' ? 'left' : 'right'; // Reset this.$label.css( { right: '', left: '' } ); this.$indicator.css( { right: '', left: '' } ); if ( scrollWidth ) { this.$indicator.css( property, scrollWidth ); if ( this.labelPosition === 'after' ) { this.$label.css( property, scrollWidth ); } } this.scrollWidth = scrollWidth; this.positionLabel(); } } return this; }; /** * @inheritdoc * @protected */ OO.ui.TextInputWidget.prototype.getInputElement = function ( config ) { return config.multiline ? $( '<textarea>' ) : $( '<input type="' + this.getSaneType( config ) + '" />' ); }; /** * Get sanitized value for 'type' for given config. * * @param {Object} config Configuration options * @return {string|null} * @private */ OO.ui.TextInputWidget.prototype.getSaneType = function ( config ) { var type = [ 'text', 'password', 'search', 'email', 'url' ].indexOf( config.type ) !== -1 ? config.type : 'text'; return config.multiline ? 'multiline' : type; }; /** * Check if the input supports multiple lines. * * @return {boolean} */ OO.ui.TextInputWidget.prototype.isMultiline = function () { return !!this.multiline; }; /** * Check if the input automatically adjusts its size. * * @return {boolean} */ OO.ui.TextInputWidget.prototype.isAutosizing = function () { return !!this.autosize; }; /** * Focus the input and select a specified range within the text. * * @param {number} from Select from offset * @param {number} [to] Select to offset, defaults to from * @chainable */ OO.ui.TextInputWidget.prototype.selectRange = function ( from, to ) { var textRange, isBackwards, start, end, element = this.$input[ 0 ]; to = to || from; isBackwards = to < from; start = isBackwards ? to : from; end = isBackwards ? from : to; this.focus(); if ( element.setSelectionRange ) { element.setSelectionRange( start, end, isBackwards ? 'backward' : 'forward' ); } else if ( element.createTextRange ) { // IE 8 and below textRange = element.createTextRange(); textRange.collapse( true ); textRange.moveStart( 'character', start ); textRange.moveEnd( 'character', end - start ); textRange.select(); } return this; }; /** * Get the length of the text input value. * * This could differ from the length of #getValue if the * value gets filtered * * @return {number} Input length */ OO.ui.TextInputWidget.prototype.getInputLength = function () { return this.$input[ 0 ].value.length; }; /** * Focus the input and select the entire text. * * @chainable */ OO.ui.TextInputWidget.prototype.select = function () { return this.selectRange( 0, this.getInputLength() ); }; /** * Focus the input and move the cursor to the start. * * @chainable */ OO.ui.TextInputWidget.prototype.moveCursorToStart = function () { return this.selectRange( 0 ); }; /** * Focus the input and move the cursor to the end. * * @chainable */ OO.ui.TextInputWidget.prototype.moveCursorToEnd = function () { return this.selectRange( this.getInputLength() ); }; /** * Set the validation pattern. * * The validation pattern is either a regular expression, a function, or the symbolic name of a * pattern defined by the class: 'non-empty' (the value cannot be an empty string) or 'integer' (the * value must contain only numbers). * * @param {RegExp|Function|string|null} validate Regular expression, function, or the symbolic name * of a pattern (either ‘integer’ or ‘non-empty’) defined by the class. */ OO.ui.TextInputWidget.prototype.setValidation = function ( validate ) { if ( validate instanceof RegExp || validate instanceof Function ) { this.validate = validate; } else { this.validate = this.constructor.static.validationPatterns[ validate ] || /.*/; } }; /** * Sets the 'invalid' flag appropriately. * * @param {boolean} [isValid] Optionally override validation result */ OO.ui.TextInputWidget.prototype.setValidityFlag = function ( isValid ) { var widget = this, setFlag = function ( valid ) { if ( !valid ) { widget.$input.attr( 'aria-invalid', 'true' ); } else { widget.$input.removeAttr( 'aria-invalid' ); } widget.setFlags( { invalid: !valid } ); }; if ( isValid !== undefined ) { setFlag( isValid ); } else { this.getValidity().then( function () { setFlag( true ); }, function () { setFlag( false ); } ); } }; /** * Check if a value is valid. * * This method returns a promise that resolves with a boolean `true` if the current value is * considered valid according to the supplied {@link #validate validation pattern}. * * @deprecated * @return {jQuery.Promise} A promise that resolves to a boolean `true` if the value is valid. */ OO.ui.TextInputWidget.prototype.isValid = function () { var result; if ( this.validate instanceof Function ) { result = this.validate( this.getValue() ); if ( $.isFunction( result.promise ) ) { return result.promise(); } else { return $.Deferred().resolve( !!result ).promise(); } } else { return $.Deferred().resolve( !!this.getValue().match( this.validate ) ).promise(); } }; /** * Get the validity of current value. * * This method returns a promise that resolves if the value is valid and rejects if * it isn't. Uses the {@link #validate validation pattern} to check for validity. * * @return {jQuery.Promise} A promise that resolves if the value is valid, rejects if not. */ OO.ui.TextInputWidget.prototype.getValidity = function () { var result, promise; function rejectOrResolve( valid ) { if ( valid ) { return $.Deferred().resolve().promise(); } else { return $.Deferred().reject().promise(); } } if ( this.validate instanceof Function ) { result = this.validate( this.getValue() ); if ( $.isFunction( result.promise ) ) { promise = $.Deferred(); result.then( function ( valid ) { if ( valid ) { promise.resolve(); } else { promise.reject(); } }, function () { promise.reject(); } ); return promise.promise(); } else { return rejectOrResolve( result ); } } else { return rejectOrResolve( this.getValue().match( this.validate ) ); } }; /** * Set the position of the inline label relative to that of the value: `‘before’` or `‘after’`. * * @param {string} labelPosition Label position, 'before' or 'after' * @chainable */ OO.ui.TextInputWidget.prototype.setLabelPosition = function ( labelPosition ) { this.labelPosition = labelPosition; this.updatePosition(); return this; }; /** * Deprecated alias of #setLabelPosition * * @deprecated Use setLabelPosition instead. */ OO.ui.TextInputWidget.prototype.setPosition = OO.ui.TextInputWidget.prototype.setLabelPosition; /** * Update the position of the inline label. * * This method is called by #setLabelPosition, and can also be called on its own if * something causes the label to be mispositioned. * * @chainable */ OO.ui.TextInputWidget.prototype.updatePosition = function () { var after = this.labelPosition === 'after'; this.$element .toggleClass( 'oo-ui-textInputWidget-labelPosition-after', !!this.label && after ) .toggleClass( 'oo-ui-textInputWidget-labelPosition-before', !!this.label && !after ); this.valCache = null; this.scrollWidth = null; this.adjustSize(); this.positionLabel(); return this; }; /** * Update the 'clear' indicator displayed on type: 'search' text fields, hiding it when the field is * already empty or when it's not editable. */ OO.ui.TextInputWidget.prototype.updateSearchIndicator = function () { if ( this.type === 'search' ) { if ( this.getValue() === '' || this.isDisabled() || this.isReadOnly() ) { this.setIndicator( null ); } else { this.setIndicator( 'clear' ); } } }; /** * Position the label by setting the correct padding on the input. * * @private * @chainable */ OO.ui.TextInputWidget.prototype.positionLabel = function () { var after, rtl, property; // Clear old values this.$input // Clear old values if present .css( { 'padding-right': '', 'padding-left': '' } ); if ( this.label ) { this.$element.append( this.$label ); } else { this.$label.detach(); return; } after = this.labelPosition === 'after'; rtl = this.$element.css( 'direction' ) === 'rtl'; property = after === rtl ? 'padding-left' : 'padding-right'; this.$input.css( property, this.$label.outerWidth( true ) + ( after ? this.scrollWidth : 0 ) ); return this; }; /** * @inheritdoc */ OO.ui.TextInputWidget.prototype.restorePreInfuseState = function ( state ) { OO.ui.TextInputWidget.parent.prototype.restorePreInfuseState.call( this, state ); if ( state.scrollTop !== undefined ) { this.$input.scrollTop( state.scrollTop ); } }; /** * ComboBoxInputWidgets combine a {@link OO.ui.TextInputWidget text input} (where a value * can be entered manually) and a {@link OO.ui.MenuSelectWidget menu of options} (from which * a value can be chosen instead). Users can choose options from the combo box in one of two ways: * * - by typing a value in the text input field. If the value exactly matches the value of a menu * option, that option will appear to be selected. * - by choosing a value from the menu. The value of the chosen option will then appear in the text * input field. * * This widget can be used inside a HTML form, such as a OO.ui.FormLayout. * * For more information about menus and options, please see the [OOjs UI documentation on MediaWiki][1]. * * @example * // Example: A ComboBoxInputWidget. * var comboBox = new OO.ui.ComboBoxInputWidget( { * label: 'ComboBoxInputWidget', * value: 'Option 1', * menu: { * items: [ * new OO.ui.MenuOptionWidget( { * data: 'Option 1', * label: 'Option One' * } ), * new OO.ui.MenuOptionWidget( { * data: 'Option 2', * label: 'Option Two' * } ), * new OO.ui.MenuOptionWidget( { * data: 'Option 3', * label: 'Option Three' * } ), * new OO.ui.MenuOptionWidget( { * data: 'Option 4', * label: 'Option Four' * } ), * new OO.ui.MenuOptionWidget( { * data: 'Option 5', * label: 'Option Five' * } ) * ] * } * } ); * $( 'body' ).append( comboBox.$element ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Selects_and_Options#Menu_selects_and_options * * @class * @extends OO.ui.TextInputWidget * * @constructor * @param {Object} [config] Configuration options * @cfg {Object[]} [options=[]] Array of menu options in the format `{ data: …, label: … }` * @cfg {Object} [menu] Configuration options to pass to the {@link OO.ui.FloatingMenuSelectWidget menu select widget}. * @cfg {jQuery} [$overlay] Render the menu into a separate layer. This configuration is useful in cases where * the expanded menu is larger than its containing `<div>`. The specified overlay layer is usually on top of the * containing `<div>` and has a larger area. By default, the menu uses relative positioning. */ OO.ui.ComboBoxInputWidget = function OoUiComboBoxInputWidget( config ) { // Configuration initialization config = $.extend( { indicator: 'down' }, config ); // For backwards-compatibility with ComboBoxWidget config $.extend( config, config.input ); // Parent constructor OO.ui.ComboBoxInputWidget.parent.call( this, config ); // Properties this.$overlay = config.$overlay || this.$element; this.menu = new OO.ui.FloatingMenuSelectWidget( $.extend( { widget: this, input: this, $container: this.$element, disabled: this.isDisabled() }, config.menu ) ); // For backwards-compatibility with ComboBoxWidget this.input = this; // Events this.$indicator.on( { click: this.onIndicatorClick.bind( this ), keypress: this.onIndicatorKeyPress.bind( this ) } ); this.connect( this, { change: 'onInputChange', enter: 'onInputEnter' } ); this.menu.connect( this, { choose: 'onMenuChoose', add: 'onMenuItemsChange', remove: 'onMenuItemsChange' } ); // Initialization this.$input.attr( { role: 'combobox', 'aria-autocomplete': 'list' } ); // Do not override options set via config.menu.items if ( config.options !== undefined ) { this.setOptions( config.options ); } // Extra class for backwards-compatibility with ComboBoxWidget this.$element.addClass( 'oo-ui-comboBoxInputWidget oo-ui-comboBoxWidget' ); this.$overlay.append( this.menu.$element ); this.onMenuItemsChange(); }; /* Setup */ OO.inheritClass( OO.ui.ComboBoxInputWidget, OO.ui.TextInputWidget ); /* Methods */ /** * Get the combobox's menu. * @return {OO.ui.FloatingMenuSelectWidget} Menu widget */ OO.ui.ComboBoxInputWidget.prototype.getMenu = function () { return this.menu; }; /** * Get the combobox's text input widget. * @return {OO.ui.TextInputWidget} Text input widget */ OO.ui.ComboBoxInputWidget.prototype.getInput = function () { return this; }; /** * Handle input change events. * * @private * @param {string} value New value */ OO.ui.ComboBoxInputWidget.prototype.onInputChange = function ( value ) { var match = this.menu.getItemFromData( value ); this.menu.selectItem( match ); if ( this.menu.getHighlightedItem() ) { this.menu.highlightItem( match ); } if ( !this.isDisabled() ) { this.menu.toggle( true ); } }; /** * Handle mouse click events. * * @private * @param {jQuery.Event} e Mouse click event */ OO.ui.ComboBoxInputWidget.prototype.onIndicatorClick = function ( e ) { if ( !this.isDisabled() && e.which === 1 ) { this.menu.toggle(); this.$input[ 0 ].focus(); } return false; }; /** * Handle key press events. * * @private * @param {jQuery.Event} e Key press event */ OO.ui.ComboBoxInputWidget.prototype.onIndicatorKeyPress = function ( e ) { if ( !this.isDisabled() && ( e.which === OO.ui.Keys.SPACE || e.which === OO.ui.Keys.ENTER ) ) { this.menu.toggle(); this.$input[ 0 ].focus(); return false; } }; /** * Handle input enter events. * * @private */ OO.ui.ComboBoxInputWidget.prototype.onInputEnter = function () { if ( !this.isDisabled() ) { this.menu.toggle( false ); } }; /** * Handle menu choose events. * * @private * @param {OO.ui.OptionWidget} item Chosen item */ OO.ui.ComboBoxInputWidget.prototype.onMenuChoose = function ( item ) { this.setValue( item.getData() ); }; /** * Handle menu item change events. * * @private */ OO.ui.ComboBoxInputWidget.prototype.onMenuItemsChange = function () { var match = this.menu.getItemFromData( this.getValue() ); this.menu.selectItem( match ); if ( this.menu.getHighlightedItem() ) { this.menu.highlightItem( match ); } this.$element.toggleClass( 'oo-ui-comboBoxInputWidget-empty', this.menu.isEmpty() ); }; /** * @inheritdoc */ OO.ui.ComboBoxInputWidget.prototype.setDisabled = function ( disabled ) { // Parent method OO.ui.ComboBoxInputWidget.parent.prototype.setDisabled.call( this, disabled ); if ( this.menu ) { this.menu.setDisabled( this.isDisabled() ); } return this; }; /** * Set the options available for this input. * * @param {Object[]} options Array of menu options in the format `{ data: …, label: … }` * @chainable */ OO.ui.ComboBoxInputWidget.prototype.setOptions = function ( options ) { this.getMenu() .clearItems() .addItems( options.map( function ( opt ) { return new OO.ui.MenuOptionWidget( { data: opt.data, label: opt.label !== undefined ? opt.label : opt.data } ); } ) ); return this; }; /** * @class * @deprecated Use OO.ui.ComboBoxInputWidget instead. */ OO.ui.ComboBoxWidget = OO.ui.ComboBoxInputWidget; /** * LabelWidgets help identify the function of interface elements. Each LabelWidget can * be configured with a `label` option that is set to a string, a label node, or a function: * * - String: a plaintext string * - jQuery selection: a jQuery selection, used for anything other than a plaintext label, e.g., a * label that includes a link or special styling, such as a gray color or additional graphical elements. * - Function: a function that will produce a string in the future. Functions are used * in cases where the value of the label is not currently defined. * * In addition, the LabelWidget can be associated with an {@link OO.ui.InputWidget input widget}, which * will come into focus when the label is clicked. * * @example * // Examples of LabelWidgets * var label1 = new OO.ui.LabelWidget( { * label: 'plaintext label' * } ); * var label2 = new OO.ui.LabelWidget( { * label: $( '<a href="default.html">jQuery label</a>' ) * } ); * // Create a fieldset layout with fields for each example * var fieldset = new OO.ui.FieldsetLayout(); * fieldset.addItems( [ * new OO.ui.FieldLayout( label1 ), * new OO.ui.FieldLayout( label2 ) * ] ); * $( 'body' ).append( fieldset.$element ); * * @class * @extends OO.ui.Widget * @mixins OO.ui.mixin.LabelElement * * @constructor * @param {Object} [config] Configuration options * @cfg {OO.ui.InputWidget} [input] {@link OO.ui.InputWidget Input widget} that uses the label. * Clicking the label will focus the specified input field. */ OO.ui.LabelWidget = function OoUiLabelWidget( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.LabelWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.LabelElement.call( this, $.extend( {}, config, { $label: this.$element } ) ); OO.ui.mixin.TitledElement.call( this, config ); // Properties this.input = config.input; // Events if ( this.input instanceof OO.ui.InputWidget ) { this.$element.on( 'click', this.onClick.bind( this ) ); } // Initialization this.$element.addClass( 'oo-ui-labelWidget' ); }; /* Setup */ OO.inheritClass( OO.ui.LabelWidget, OO.ui.Widget ); OO.mixinClass( OO.ui.LabelWidget, OO.ui.mixin.LabelElement ); OO.mixinClass( OO.ui.LabelWidget, OO.ui.mixin.TitledElement ); /* Static Properties */ OO.ui.LabelWidget.static.tagName = 'span'; /* Methods */ /** * Handles label mouse click events. * * @private * @param {jQuery.Event} e Mouse click event */ OO.ui.LabelWidget.prototype.onClick = function () { this.input.simulateLabelClick(); return false; }; /** * OptionWidgets are special elements that can be selected and configured with data. The * data is often unique for each option, but it does not have to be. OptionWidgets are used * with OO.ui.SelectWidget to create a selection of mutually exclusive options. For more information * and examples, please see the [OOjs UI documentation on MediaWiki][1]. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Selects_and_Options * * @class * @extends OO.ui.Widget * @mixins OO.ui.mixin.LabelElement * @mixins OO.ui.mixin.FlaggedElement * * @constructor * @param {Object} [config] Configuration options */ OO.ui.OptionWidget = function OoUiOptionWidget( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.OptionWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.ItemWidget.call( this ); OO.ui.mixin.LabelElement.call( this, config ); OO.ui.mixin.FlaggedElement.call( this, config ); // Properties this.selected = false; this.highlighted = false; this.pressed = false; // Initialization this.$element .data( 'oo-ui-optionWidget', this ) .attr( 'role', 'option' ) .attr( 'aria-selected', 'false' ) .addClass( 'oo-ui-optionWidget' ) .append( this.$label ); }; /* Setup */ OO.inheritClass( OO.ui.OptionWidget, OO.ui.Widget ); OO.mixinClass( OO.ui.OptionWidget, OO.ui.mixin.ItemWidget ); OO.mixinClass( OO.ui.OptionWidget, OO.ui.mixin.LabelElement ); OO.mixinClass( OO.ui.OptionWidget, OO.ui.mixin.FlaggedElement ); /* Static Properties */ OO.ui.OptionWidget.static.selectable = true; OO.ui.OptionWidget.static.highlightable = true; OO.ui.OptionWidget.static.pressable = true; OO.ui.OptionWidget.static.scrollIntoViewOnSelect = false; /* Methods */ /** * Check if the option can be selected. * * @return {boolean} Item is selectable */ OO.ui.OptionWidget.prototype.isSelectable = function () { return this.constructor.static.selectable && !this.isDisabled() && this.isVisible(); }; /** * Check if the option can be highlighted. A highlight indicates that the option * may be selected when a user presses enter or clicks. Disabled items cannot * be highlighted. * * @return {boolean} Item is highlightable */ OO.ui.OptionWidget.prototype.isHighlightable = function () { return this.constructor.static.highlightable && !this.isDisabled() && this.isVisible(); }; /** * Check if the option can be pressed. The pressed state occurs when a user mouses * down on an item, but has not yet let go of the mouse. * * @return {boolean} Item is pressable */ OO.ui.OptionWidget.prototype.isPressable = function () { return this.constructor.static.pressable && !this.isDisabled() && this.isVisible(); }; /** * Check if the option is selected. * * @return {boolean} Item is selected */ OO.ui.OptionWidget.prototype.isSelected = function () { return this.selected; }; /** * Check if the option is highlighted. A highlight indicates that the * item may be selected when a user presses enter or clicks. * * @return {boolean} Item is highlighted */ OO.ui.OptionWidget.prototype.isHighlighted = function () { return this.highlighted; }; /** * Check if the option is pressed. The pressed state occurs when a user mouses * down on an item, but has not yet let go of the mouse. The item may appear * selected, but it will not be selected until the user releases the mouse. * * @return {boolean} Item is pressed */ OO.ui.OptionWidget.prototype.isPressed = function () { return this.pressed; }; /** * Set the option’s selected state. In general, all modifications to the selection * should be handled by the SelectWidget’s {@link OO.ui.SelectWidget#selectItem selectItem( [item] )} * method instead of this method. * * @param {boolean} [state=false] Select option * @chainable */ OO.ui.OptionWidget.prototype.setSelected = function ( state ) { if ( this.constructor.static.selectable ) { this.selected = !!state; this.$element .toggleClass( 'oo-ui-optionWidget-selected', state ) .attr( 'aria-selected', state.toString() ); if ( state && this.constructor.static.scrollIntoViewOnSelect ) { this.scrollElementIntoView(); } this.updateThemeClasses(); } return this; }; /** * Set the option’s highlighted state. In general, all programmatic * modifications to the highlight should be handled by the * SelectWidget’s {@link OO.ui.SelectWidget#highlightItem highlightItem( [item] )} * method instead of this method. * * @param {boolean} [state=false] Highlight option * @chainable */ OO.ui.OptionWidget.prototype.setHighlighted = function ( state ) { if ( this.constructor.static.highlightable ) { this.highlighted = !!state; this.$element.toggleClass( 'oo-ui-optionWidget-highlighted', state ); this.updateThemeClasses(); } return this; }; /** * Set the option’s pressed state. In general, all * programmatic modifications to the pressed state should be handled by the * SelectWidget’s {@link OO.ui.SelectWidget#pressItem pressItem( [item] )} * method instead of this method. * * @param {boolean} [state=false] Press option * @chainable */ OO.ui.OptionWidget.prototype.setPressed = function ( state ) { if ( this.constructor.static.pressable ) { this.pressed = !!state; this.$element.toggleClass( 'oo-ui-optionWidget-pressed', state ); this.updateThemeClasses(); } return this; }; /** * DecoratedOptionWidgets are {@link OO.ui.OptionWidget options} that can be configured * with an {@link OO.ui.mixin.IconElement icon} and/or {@link OO.ui.mixin.IndicatorElement indicator}. * This class is used with OO.ui.SelectWidget to create a selection of mutually exclusive * options. For more information about options and selects, please see the * [OOjs UI documentation on MediaWiki][1]. * * @example * // Decorated options in a select widget * var select = new OO.ui.SelectWidget( { * items: [ * new OO.ui.DecoratedOptionWidget( { * data: 'a', * label: 'Option with icon', * icon: 'help' * } ), * new OO.ui.DecoratedOptionWidget( { * data: 'b', * label: 'Option with indicator', * indicator: 'next' * } ) * ] * } ); * $( 'body' ).append( select.$element ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Selects_and_Options * * @class * @extends OO.ui.OptionWidget * @mixins OO.ui.mixin.IconElement * @mixins OO.ui.mixin.IndicatorElement * * @constructor * @param {Object} [config] Configuration options */ OO.ui.DecoratedOptionWidget = function OoUiDecoratedOptionWidget( config ) { // Parent constructor OO.ui.DecoratedOptionWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.IconElement.call( this, config ); OO.ui.mixin.IndicatorElement.call( this, config ); // Initialization this.$element .addClass( 'oo-ui-decoratedOptionWidget' ) .prepend( this.$icon ) .append( this.$indicator ); }; /* Setup */ OO.inheritClass( OO.ui.DecoratedOptionWidget, OO.ui.OptionWidget ); OO.mixinClass( OO.ui.DecoratedOptionWidget, OO.ui.mixin.IconElement ); OO.mixinClass( OO.ui.DecoratedOptionWidget, OO.ui.mixin.IndicatorElement ); /** * ButtonOptionWidget is a special type of {@link OO.ui.mixin.ButtonElement button element} that * can be selected and configured with data. The class is * used with OO.ui.ButtonSelectWidget to create a selection of button options. Please see the * [OOjs UI documentation on MediaWiki] [1] for more information. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Selects_and_Options#Button_selects_and_options * * @class * @extends OO.ui.DecoratedOptionWidget * @mixins OO.ui.mixin.ButtonElement * @mixins OO.ui.mixin.TabIndexedElement * @mixins OO.ui.mixin.TitledElement * * @constructor * @param {Object} [config] Configuration options */ OO.ui.ButtonOptionWidget = function OoUiButtonOptionWidget( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.ButtonOptionWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.ButtonElement.call( this, config ); OO.ui.mixin.TitledElement.call( this, $.extend( {}, config, { $titled: this.$button } ) ); OO.ui.mixin.TabIndexedElement.call( this, $.extend( {}, config, { $tabIndexed: this.$button, tabIndex: -1 } ) ); // Initialization this.$element.addClass( 'oo-ui-buttonOptionWidget' ); this.$button.append( this.$element.contents() ); this.$element.append( this.$button ); }; /* Setup */ OO.inheritClass( OO.ui.ButtonOptionWidget, OO.ui.DecoratedOptionWidget ); OO.mixinClass( OO.ui.ButtonOptionWidget, OO.ui.mixin.ButtonElement ); OO.mixinClass( OO.ui.ButtonOptionWidget, OO.ui.mixin.TitledElement ); OO.mixinClass( OO.ui.ButtonOptionWidget, OO.ui.mixin.TabIndexedElement ); /* Static Properties */ // Allow button mouse down events to pass through so they can be handled by the parent select widget OO.ui.ButtonOptionWidget.static.cancelButtonMouseDownEvents = false; OO.ui.ButtonOptionWidget.static.highlightable = false; /* Methods */ /** * @inheritdoc */ OO.ui.ButtonOptionWidget.prototype.setSelected = function ( state ) { OO.ui.ButtonOptionWidget.parent.prototype.setSelected.call( this, state ); if ( this.constructor.static.selectable ) { this.setActive( state ); } return this; }; /** * RadioOptionWidget is an option widget that looks like a radio button. * The class is used with OO.ui.RadioSelectWidget to create a selection of radio options. * Please see the [OOjs UI documentation on MediaWiki] [1] for more information. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Selects_and_Options#Button_selects_and_option * * @class * @extends OO.ui.OptionWidget * * @constructor * @param {Object} [config] Configuration options */ OO.ui.RadioOptionWidget = function OoUiRadioOptionWidget( config ) { // Configuration initialization config = config || {}; // Properties (must be done before parent constructor which calls #setDisabled) this.radio = new OO.ui.RadioInputWidget( { value: config.data, tabIndex: -1 } ); // Parent constructor OO.ui.RadioOptionWidget.parent.call( this, config ); // Events this.radio.$input.on( 'focus', this.onInputFocus.bind( this ) ); // Initialization // Remove implicit role, we're handling it ourselves this.radio.$input.attr( 'role', 'presentation' ); this.$element .addClass( 'oo-ui-radioOptionWidget' ) .attr( 'role', 'radio' ) .attr( 'aria-checked', 'false' ) .removeAttr( 'aria-selected' ) .prepend( this.radio.$element ); }; /* Setup */ OO.inheritClass( OO.ui.RadioOptionWidget, OO.ui.OptionWidget ); /* Static Properties */ OO.ui.RadioOptionWidget.static.highlightable = false; OO.ui.RadioOptionWidget.static.scrollIntoViewOnSelect = true; OO.ui.RadioOptionWidget.static.pressable = false; OO.ui.RadioOptionWidget.static.tagName = 'label'; /* Methods */ /** * @param {jQuery.Event} e Focus event * @private */ OO.ui.RadioOptionWidget.prototype.onInputFocus = function () { this.radio.$input.blur(); this.$element.parent().focus(); }; /** * @inheritdoc */ OO.ui.RadioOptionWidget.prototype.setSelected = function ( state ) { OO.ui.RadioOptionWidget.parent.prototype.setSelected.call( this, state ); this.radio.setSelected( state ); this.$element .attr( 'aria-checked', state.toString() ) .removeAttr( 'aria-selected' ); return this; }; /** * @inheritdoc */ OO.ui.RadioOptionWidget.prototype.setDisabled = function ( disabled ) { OO.ui.RadioOptionWidget.parent.prototype.setDisabled.call( this, disabled ); this.radio.setDisabled( this.isDisabled() ); return this; }; /** * MenuOptionWidget is an option widget that looks like a menu item. The class is used with * OO.ui.MenuSelectWidget to create a menu of mutually exclusive options. Please see * the [OOjs UI documentation on MediaWiki] [1] for more information. * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Selects_and_Options#Menu_selects_and_options * * @class * @extends OO.ui.DecoratedOptionWidget * * @constructor * @param {Object} [config] Configuration options */ OO.ui.MenuOptionWidget = function OoUiMenuOptionWidget( config ) { // Configuration initialization config = $.extend( { icon: 'check' }, config ); // Parent constructor OO.ui.MenuOptionWidget.parent.call( this, config ); // Initialization this.$element .attr( 'role', 'menuitem' ) .addClass( 'oo-ui-menuOptionWidget' ); }; /* Setup */ OO.inheritClass( OO.ui.MenuOptionWidget, OO.ui.DecoratedOptionWidget ); /* Static Properties */ OO.ui.MenuOptionWidget.static.scrollIntoViewOnSelect = true; /** * MenuSectionOptionWidgets are used inside {@link OO.ui.MenuSelectWidget menu select widgets} to group one or more related * {@link OO.ui.MenuOptionWidget menu options}. MenuSectionOptionWidgets cannot be highlighted or selected. * * @example * var myDropdown = new OO.ui.DropdownWidget( { * menu: { * items: [ * new OO.ui.MenuSectionOptionWidget( { * label: 'Dogs' * } ), * new OO.ui.MenuOptionWidget( { * data: 'corgi', * label: 'Welsh Corgi' * } ), * new OO.ui.MenuOptionWidget( { * data: 'poodle', * label: 'Standard Poodle' * } ), * new OO.ui.MenuSectionOptionWidget( { * label: 'Cats' * } ), * new OO.ui.MenuOptionWidget( { * data: 'lion', * label: 'Lion' * } ) * ] * } * } ); * $( 'body' ).append( myDropdown.$element ); * * @class * @extends OO.ui.DecoratedOptionWidget * * @constructor * @param {Object} [config] Configuration options */ OO.ui.MenuSectionOptionWidget = function OoUiMenuSectionOptionWidget( config ) { // Parent constructor OO.ui.MenuSectionOptionWidget.parent.call( this, config ); // Initialization this.$element.addClass( 'oo-ui-menuSectionOptionWidget' ); }; /* Setup */ OO.inheritClass( OO.ui.MenuSectionOptionWidget, OO.ui.DecoratedOptionWidget ); /* Static Properties */ OO.ui.MenuSectionOptionWidget.static.selectable = false; OO.ui.MenuSectionOptionWidget.static.highlightable = false; /** * OutlineOptionWidget is an item in an {@link OO.ui.OutlineSelectWidget OutlineSelectWidget}. * * Currently, this class is only used by {@link OO.ui.BookletLayout booklet layouts}, which contain * {@link OO.ui.PageLayout page layouts}. See {@link OO.ui.BookletLayout BookletLayout} * for an example. * * @class * @extends OO.ui.DecoratedOptionWidget * * @constructor * @param {Object} [config] Configuration options * @cfg {number} [level] Indentation level * @cfg {boolean} [movable] Allow modification from {@link OO.ui.OutlineControlsWidget outline controls}. */ OO.ui.OutlineOptionWidget = function OoUiOutlineOptionWidget( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.OutlineOptionWidget.parent.call( this, config ); // Properties this.level = 0; this.movable = !!config.movable; this.removable = !!config.removable; // Initialization this.$element.addClass( 'oo-ui-outlineOptionWidget' ); this.setLevel( config.level ); }; /* Setup */ OO.inheritClass( OO.ui.OutlineOptionWidget, OO.ui.DecoratedOptionWidget ); /* Static Properties */ OO.ui.OutlineOptionWidget.static.highlightable = false; OO.ui.OutlineOptionWidget.static.scrollIntoViewOnSelect = true; OO.ui.OutlineOptionWidget.static.levelClass = 'oo-ui-outlineOptionWidget-level-'; OO.ui.OutlineOptionWidget.static.levels = 3; /* Methods */ /** * Check if item is movable. * * Movability is used by {@link OO.ui.OutlineControlsWidget outline controls}. * * @return {boolean} Item is movable */ OO.ui.OutlineOptionWidget.prototype.isMovable = function () { return this.movable; }; /** * Check if item is removable. * * Removability is used by {@link OO.ui.OutlineControlsWidget outline controls}. * * @return {boolean} Item is removable */ OO.ui.OutlineOptionWidget.prototype.isRemovable = function () { return this.removable; }; /** * Get indentation level. * * @return {number} Indentation level */ OO.ui.OutlineOptionWidget.prototype.getLevel = function () { return this.level; }; /** * Set movability. * * Movability is used by {@link OO.ui.OutlineControlsWidget outline controls}. * * @param {boolean} movable Item is movable * @chainable */ OO.ui.OutlineOptionWidget.prototype.setMovable = function ( movable ) { this.movable = !!movable; this.updateThemeClasses(); return this; }; /** * Set removability. * * Removability is used by {@link OO.ui.OutlineControlsWidget outline controls}. * * @param {boolean} movable Item is removable * @chainable */ OO.ui.OutlineOptionWidget.prototype.setRemovable = function ( removable ) { this.removable = !!removable; this.updateThemeClasses(); return this; }; /** * Set indentation level. * * @param {number} [level=0] Indentation level, in the range of [0,#maxLevel] * @chainable */ OO.ui.OutlineOptionWidget.prototype.setLevel = function ( level ) { var levels = this.constructor.static.levels, levelClass = this.constructor.static.levelClass, i = levels; this.level = level ? Math.max( 0, Math.min( levels - 1, level ) ) : 0; while ( i-- ) { if ( this.level === i ) { this.$element.addClass( levelClass + i ); } else { this.$element.removeClass( levelClass + i ); } } this.updateThemeClasses(); return this; }; /** * TabOptionWidget is an item in a {@link OO.ui.TabSelectWidget TabSelectWidget}. * * Currently, this class is only used by {@link OO.ui.IndexLayout index layouts}, which contain * {@link OO.ui.CardLayout card layouts}. See {@link OO.ui.IndexLayout IndexLayout} * for an example. * * @class * @extends OO.ui.OptionWidget * * @constructor * @param {Object} [config] Configuration options */ OO.ui.TabOptionWidget = function OoUiTabOptionWidget( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.TabOptionWidget.parent.call( this, config ); // Initialization this.$element.addClass( 'oo-ui-tabOptionWidget' ); }; /* Setup */ OO.inheritClass( OO.ui.TabOptionWidget, OO.ui.OptionWidget ); /* Static Properties */ OO.ui.TabOptionWidget.static.highlightable = false; /** * PopupWidget is a container for content. The popup is overlaid and positioned absolutely. * By default, each popup has an anchor that points toward its origin. * Please see the [OOjs UI documentation on Mediawiki] [1] for more information and examples. * * @example * // A popup widget. * var popup = new OO.ui.PopupWidget( { * $content: $( '<p>Hi there!</p>' ), * padded: true, * width: 300 * } ); * * $( 'body' ).append( popup.$element ); * // To display the popup, toggle the visibility to 'true'. * popup.toggle( true ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Popups * * @class * @extends OO.ui.Widget * @mixins OO.ui.mixin.LabelElement * @mixins OO.ui.mixin.ClippableElement * * @constructor * @param {Object} [config] Configuration options * @cfg {number} [width=320] Width of popup in pixels * @cfg {number} [height] Height of popup in pixels. Omit to use the automatic height. * @cfg {boolean} [anchor=true] Show anchor pointing to origin of popup * @cfg {string} [align='center'] Alignment of the popup: `center`, `force-left`, `force-right`, `backwards` or `forwards`. * If the popup is forced-left the popup body is leaning towards the left. For force-right alignment, the body of the * popup is leaning towards the right of the screen. * Using 'backwards' is a logical direction which will result in the popup leaning towards the beginning of the sentence * in the given language, which means it will flip to the correct positioning in right-to-left languages. * Using 'forward' will also result in a logical alignment where the body of the popup leans towards the end of the * sentence in the given language. * @cfg {jQuery} [$container] Constrain the popup to the boundaries of the specified container. * See the [OOjs UI docs on MediaWiki][3] for an example. * [3]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Popups#containerExample * @cfg {number} [containerPadding=10] Padding between the popup and its container, specified as a number of pixels. * @cfg {jQuery} [$content] Content to append to the popup's body * @cfg {jQuery} [$footer] Content to append to the popup's footer * @cfg {boolean} [autoClose=false] Automatically close the popup when it loses focus. * @cfg {jQuery} [$autoCloseIgnore] Elements that will not close the popup when clicked. * This config option is only relevant if #autoClose is set to `true`. See the [OOjs UI docs on MediaWiki][2] * for an example. * [2]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Popups#autocloseExample * @cfg {boolean} [head] Show a popup header that contains a #label (if specified) and close * button. * @cfg {boolean} [padded] Add padding to the popup's body */ OO.ui.PopupWidget = function OoUiPopupWidget( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.PopupWidget.parent.call( this, config ); // Properties (must be set before ClippableElement constructor call) this.$body = $( '<div>' ); this.$popup = $( '<div>' ); // Mixin constructors OO.ui.mixin.LabelElement.call( this, config ); OO.ui.mixin.ClippableElement.call( this, $.extend( {}, config, { $clippable: this.$body, $clippableContainer: this.$popup } ) ); // Properties this.$head = $( '<div>' ); this.$footer = $( '<div>' ); this.$anchor = $( '<div>' ); // If undefined, will be computed lazily in updateDimensions() this.$container = config.$container; this.containerPadding = config.containerPadding !== undefined ? config.containerPadding : 10; this.autoClose = !!config.autoClose; this.$autoCloseIgnore = config.$autoCloseIgnore; this.transitionTimeout = null; this.anchor = null; this.width = config.width !== undefined ? config.width : 320; this.height = config.height !== undefined ? config.height : null; this.setAlignment( config.align ); this.closeButton = new OO.ui.ButtonWidget( { framed: false, icon: 'close' } ); this.onMouseDownHandler = this.onMouseDown.bind( this ); this.onDocumentKeyDownHandler = this.onDocumentKeyDown.bind( this ); // Events this.closeButton.connect( this, { click: 'onCloseButtonClick' } ); // Initialization this.toggleAnchor( config.anchor === undefined || config.anchor ); this.$body.addClass( 'oo-ui-popupWidget-body' ); this.$anchor.addClass( 'oo-ui-popupWidget-anchor' ); this.$head .addClass( 'oo-ui-popupWidget-head' ) .append( this.$label, this.closeButton.$element ); this.$footer.addClass( 'oo-ui-popupWidget-footer' ); if ( !config.head ) { this.$head.addClass( 'oo-ui-element-hidden' ); } if ( !config.$footer ) { this.$footer.addClass( 'oo-ui-element-hidden' ); } this.$popup .addClass( 'oo-ui-popupWidget-popup' ) .append( this.$head, this.$body, this.$footer ); this.$element .addClass( 'oo-ui-popupWidget' ) .append( this.$popup, this.$anchor ); // Move content, which was added to #$element by OO.ui.Widget, to the body if ( config.$content instanceof jQuery ) { this.$body.append( config.$content ); } if ( config.$footer instanceof jQuery ) { this.$footer.append( config.$footer ); } if ( config.padded ) { this.$body.addClass( 'oo-ui-popupWidget-body-padded' ); } // Initially hidden - using #toggle may cause errors if subclasses override toggle with methods // that reference properties not initialized at that time of parent class construction // TODO: Find a better way to handle post-constructor setup this.visible = false; this.$element.addClass( 'oo-ui-element-hidden' ); }; /* Setup */ OO.inheritClass( OO.ui.PopupWidget, OO.ui.Widget ); OO.mixinClass( OO.ui.PopupWidget, OO.ui.mixin.LabelElement ); OO.mixinClass( OO.ui.PopupWidget, OO.ui.mixin.ClippableElement ); /* Methods */ /** * Handles mouse down events. * * @private * @param {MouseEvent} e Mouse down event */ OO.ui.PopupWidget.prototype.onMouseDown = function ( e ) { if ( this.isVisible() && !$.contains( this.$element[ 0 ], e.target ) && ( !this.$autoCloseIgnore || !this.$autoCloseIgnore.has( e.target ).length ) ) { this.toggle( false ); } }; /** * Bind mouse down listener. * * @private */ OO.ui.PopupWidget.prototype.bindMouseDownListener = function () { // Capture clicks outside popup OO.ui.addCaptureEventListener( this.getElementWindow(), 'mousedown', this.onMouseDownHandler ); }; /** * Handles close button click events. * * @private */ OO.ui.PopupWidget.prototype.onCloseButtonClick = function () { if ( this.isVisible() ) { this.toggle( false ); } }; /** * Unbind mouse down listener. * * @private */ OO.ui.PopupWidget.prototype.unbindMouseDownListener = function () { OO.ui.removeCaptureEventListener( this.getElementWindow(), 'mousedown', this.onMouseDownHandler ); }; /** * Handles key down events. * * @private * @param {KeyboardEvent} e Key down event */ OO.ui.PopupWidget.prototype.onDocumentKeyDown = function ( e ) { if ( e.which === OO.ui.Keys.ESCAPE && this.isVisible() ) { this.toggle( false ); e.preventDefault(); e.stopPropagation(); } }; /** * Bind key down listener. * * @private */ OO.ui.PopupWidget.prototype.bindKeyDownListener = function () { OO.ui.addCaptureEventListener( this.getElementWindow(), 'keydown', this.onDocumentKeyDownHandler ); }; /** * Unbind key down listener. * * @private */ OO.ui.PopupWidget.prototype.unbindKeyDownListener = function () { OO.ui.removeCaptureEventListener( this.getElementWindow(), 'keydown', this.onDocumentKeyDownHandler ); }; /** * Show, hide, or toggle the visibility of the anchor. * * @param {boolean} [show] Show anchor, omit to toggle */ OO.ui.PopupWidget.prototype.toggleAnchor = function ( show ) { show = show === undefined ? !this.anchored : !!show; if ( this.anchored !== show ) { if ( show ) { this.$element.addClass( 'oo-ui-popupWidget-anchored' ); } else { this.$element.removeClass( 'oo-ui-popupWidget-anchored' ); } this.anchored = show; } }; /** * Check if the anchor is visible. * * @return {boolean} Anchor is visible */ OO.ui.PopupWidget.prototype.hasAnchor = function () { return this.anchor; }; /** * @inheritdoc */ OO.ui.PopupWidget.prototype.toggle = function ( show ) { var change; show = show === undefined ? !this.isVisible() : !!show; change = show !== this.isVisible(); // Parent method OO.ui.PopupWidget.parent.prototype.toggle.call( this, show ); if ( change ) { if ( show ) { if ( this.autoClose ) { this.bindMouseDownListener(); this.bindKeyDownListener(); } this.updateDimensions(); this.toggleClipping( true ); } else { this.toggleClipping( false ); if ( this.autoClose ) { this.unbindMouseDownListener(); this.unbindKeyDownListener(); } } } return this; }; /** * Set the size of the popup. * * Changing the size may also change the popup's position depending on the alignment. * * @param {number} width Width in pixels * @param {number} height Height in pixels * @param {boolean} [transition=false] Use a smooth transition * @chainable */ OO.ui.PopupWidget.prototype.setSize = function ( width, height, transition ) { this.width = width; this.height = height !== undefined ? height : null; if ( this.isVisible() ) { this.updateDimensions( transition ); } }; /** * Update the size and position. * * Only use this to keep the popup properly anchored. Use #setSize to change the size, and this will * be called automatically. * * @param {boolean} [transition=false] Use a smooth transition * @chainable */ OO.ui.PopupWidget.prototype.updateDimensions = function ( transition ) { var popupOffset, originOffset, containerLeft, containerWidth, containerRight, popupLeft, popupRight, overlapLeft, overlapRight, anchorWidth, align = this.align, widget = this; if ( !this.$container ) { // Lazy-initialize $container if not specified in constructor this.$container = $( this.getClosestScrollableElementContainer() ); } // Set height and width before measuring things, since it might cause our measurements // to change (e.g. due to scrollbars appearing or disappearing) this.$popup.css( { width: this.width, height: this.height !== null ? this.height : 'auto' } ); // If we are in RTL, we need to flip the alignment, unless it is center if ( align === 'forwards' || align === 'backwards' ) { if ( this.$container.css( 'direction' ) === 'rtl' ) { align = ( { forwards: 'force-left', backwards: 'force-right' } )[ this.align ]; } else { align = ( { forwards: 'force-right', backwards: 'force-left' } )[ this.align ]; } } // Compute initial popupOffset based on alignment popupOffset = this.width * ( { 'force-left': -1, center: -0.5, 'force-right': 0 } )[ align ]; // Figure out if this will cause the popup to go beyond the edge of the container originOffset = this.$element.offset().left; containerLeft = this.$container.offset().left; containerWidth = this.$container.innerWidth(); containerRight = containerLeft + containerWidth; popupLeft = popupOffset - this.containerPadding; popupRight = popupOffset + this.containerPadding + this.width + this.containerPadding; overlapLeft = ( originOffset + popupLeft ) - containerLeft; overlapRight = containerRight - ( originOffset + popupRight ); // Adjust offset to make the popup not go beyond the edge, if needed if ( overlapRight < 0 ) { popupOffset += overlapRight; } else if ( overlapLeft < 0 ) { popupOffset -= overlapLeft; } // Adjust offset to avoid anchor being rendered too close to the edge // $anchor.width() doesn't work with the pure CSS anchor (returns 0) // TODO: Find a measurement that works for CSS anchors and image anchors anchorWidth = this.$anchor[ 0 ].scrollWidth * 2; if ( popupOffset + this.width < anchorWidth ) { popupOffset = anchorWidth - this.width; } else if ( -popupOffset < anchorWidth ) { popupOffset = -anchorWidth; } // Prevent transition from being interrupted clearTimeout( this.transitionTimeout ); if ( transition ) { // Enable transition this.$element.addClass( 'oo-ui-popupWidget-transitioning' ); } // Position body relative to anchor this.$popup.css( 'margin-left', popupOffset ); if ( transition ) { // Prevent transitioning after transition is complete this.transitionTimeout = setTimeout( function () { widget.$element.removeClass( 'oo-ui-popupWidget-transitioning' ); }, 200 ); } else { // Prevent transitioning immediately this.$element.removeClass( 'oo-ui-popupWidget-transitioning' ); } // Reevaluate clipping state since we've relocated and resized the popup this.clip(); return this; }; /** * Set popup alignment * @param {string} align Alignment of the popup, `center`, `force-left`, `force-right`, * `backwards` or `forwards`. */ OO.ui.PopupWidget.prototype.setAlignment = function ( align ) { // Validate alignment and transform deprecated values if ( [ 'left', 'right', 'force-left', 'force-right', 'backwards', 'forwards', 'center' ].indexOf( align ) > -1 ) { this.align = { left: 'force-right', right: 'force-left' }[ align ] || align; } else { this.align = 'center'; } }; /** * Get popup alignment * @return {string} align Alignment of the popup, `center`, `force-left`, `force-right`, * `backwards` or `forwards`. */ OO.ui.PopupWidget.prototype.getAlignment = function () { return this.align; }; /** * Progress bars visually display the status of an operation, such as a download, * and can be either determinate or indeterminate: * * - **determinate** process bars show the percent of an operation that is complete. * * - **indeterminate** process bars use a visual display of motion to indicate that an operation * is taking place. Because the extent of an indeterminate operation is unknown, the bar does * not use percentages. * * The value of the `progress` configuration determines whether the bar is determinate or indeterminate. * * @example * // Examples of determinate and indeterminate progress bars. * var progressBar1 = new OO.ui.ProgressBarWidget( { * progress: 33 * } ); * var progressBar2 = new OO.ui.ProgressBarWidget(); * * // Create a FieldsetLayout to layout progress bars * var fieldset = new OO.ui.FieldsetLayout; * fieldset.addItems( [ * new OO.ui.FieldLayout( progressBar1, {label: 'Determinate', align: 'top'}), * new OO.ui.FieldLayout( progressBar2, {label: 'Indeterminate', align: 'top'}) * ] ); * $( 'body' ).append( fieldset.$element ); * * @class * @extends OO.ui.Widget * * @constructor * @param {Object} [config] Configuration options * @cfg {number|boolean} [progress=false] The type of progress bar (determinate or indeterminate). * To create a determinate progress bar, specify a number that reflects the initial percent complete. * By default, the progress bar is indeterminate. */ OO.ui.ProgressBarWidget = function OoUiProgressBarWidget( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.ProgressBarWidget.parent.call( this, config ); // Properties this.$bar = $( '<div>' ); this.progress = null; // Initialization this.setProgress( config.progress !== undefined ? config.progress : false ); this.$bar.addClass( 'oo-ui-progressBarWidget-bar' ); this.$element .attr( { role: 'progressbar', 'aria-valuemin': 0, 'aria-valuemax': 100 } ) .addClass( 'oo-ui-progressBarWidget' ) .append( this.$bar ); }; /* Setup */ OO.inheritClass( OO.ui.ProgressBarWidget, OO.ui.Widget ); /* Static Properties */ OO.ui.ProgressBarWidget.static.tagName = 'div'; /* Methods */ /** * Get the percent of the progress that has been completed. Indeterminate progresses will return `false`. * * @return {number|boolean} Progress percent */ OO.ui.ProgressBarWidget.prototype.getProgress = function () { return this.progress; }; /** * Set the percent of the process completed or `false` for an indeterminate process. * * @param {number|boolean} progress Progress percent or `false` for indeterminate */ OO.ui.ProgressBarWidget.prototype.setProgress = function ( progress ) { this.progress = progress; if ( progress !== false ) { this.$bar.css( 'width', this.progress + '%' ); this.$element.attr( 'aria-valuenow', this.progress ); } else { this.$bar.css( 'width', '' ); this.$element.removeAttr( 'aria-valuenow' ); } this.$element.toggleClass( 'oo-ui-progressBarWidget-indeterminate', !progress ); }; /** * SearchWidgets combine a {@link OO.ui.TextInputWidget text input field}, where users can type a search query, * and a menu of search results, which is displayed beneath the query * field. Unlike {@link OO.ui.mixin.LookupElement lookup menus}, search result menus are always visible to the user. * Users can choose an item from the menu or type a query into the text field to search for a matching result item. * In general, search widgets are used inside a separate {@link OO.ui.Dialog dialog} window. * * Each time the query is changed, the search result menu is cleared and repopulated. Please see * the [OOjs UI demos][1] for an example. * * [1]: https://tools.wmflabs.org/oojs-ui/oojs-ui/demos/#dialogs-mediawiki-vector-ltr * * @class * @extends OO.ui.Widget * * @constructor * @param {Object} [config] Configuration options * @cfg {string|jQuery} [placeholder] Placeholder text for query input * @cfg {string} [value] Initial query value */ OO.ui.SearchWidget = function OoUiSearchWidget( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.SearchWidget.parent.call( this, config ); // Properties this.query = new OO.ui.TextInputWidget( { icon: 'search', placeholder: config.placeholder, value: config.value } ); this.results = new OO.ui.SelectWidget(); this.$query = $( '<div>' ); this.$results = $( '<div>' ); // Events this.query.connect( this, { change: 'onQueryChange', enter: 'onQueryEnter' } ); this.query.$input.on( 'keydown', this.onQueryKeydown.bind( this ) ); // Initialization this.$query .addClass( 'oo-ui-searchWidget-query' ) .append( this.query.$element ); this.$results .addClass( 'oo-ui-searchWidget-results' ) .append( this.results.$element ); this.$element .addClass( 'oo-ui-searchWidget' ) .append( this.$results, this.$query ); }; /* Setup */ OO.inheritClass( OO.ui.SearchWidget, OO.ui.Widget ); /* Methods */ /** * Handle query key down events. * * @private * @param {jQuery.Event} e Key down event */ OO.ui.SearchWidget.prototype.onQueryKeydown = function ( e ) { var highlightedItem, nextItem, dir = e.which === OO.ui.Keys.DOWN ? 1 : ( e.which === OO.ui.Keys.UP ? -1 : 0 ); if ( dir ) { highlightedItem = this.results.getHighlightedItem(); if ( !highlightedItem ) { highlightedItem = this.results.getSelectedItem(); } nextItem = this.results.getRelativeSelectableItem( highlightedItem, dir ); this.results.highlightItem( nextItem ); nextItem.scrollElementIntoView(); } }; /** * Handle select widget select events. * * Clears existing results. Subclasses should repopulate items according to new query. * * @private * @param {string} value New value */ OO.ui.SearchWidget.prototype.onQueryChange = function () { // Reset this.results.clearItems(); }; /** * Handle select widget enter key events. * * Chooses highlighted item. * * @private * @param {string} value New value */ OO.ui.SearchWidget.prototype.onQueryEnter = function () { var highlightedItem = this.results.getHighlightedItem(); if ( highlightedItem ) { this.results.chooseItem( highlightedItem ); } }; /** * Get the query input. * * @return {OO.ui.TextInputWidget} Query input */ OO.ui.SearchWidget.prototype.getQuery = function () { return this.query; }; /** * Get the search results menu. * * @return {OO.ui.SelectWidget} Menu of search results */ OO.ui.SearchWidget.prototype.getResults = function () { return this.results; }; /** * A SelectWidget is of a generic selection of options. The OOjs UI library contains several types of * select widgets, including {@link OO.ui.ButtonSelectWidget button selects}, * {@link OO.ui.RadioSelectWidget radio selects}, and {@link OO.ui.MenuSelectWidget * menu selects}. * * This class should be used together with OO.ui.OptionWidget or OO.ui.DecoratedOptionWidget. For more * information, please see the [OOjs UI documentation on MediaWiki][1]. * * @example * // Example of a select widget with three options * var select = new OO.ui.SelectWidget( { * items: [ * new OO.ui.OptionWidget( { * data: 'a', * label: 'Option One', * } ), * new OO.ui.OptionWidget( { * data: 'b', * label: 'Option Two', * } ), * new OO.ui.OptionWidget( { * data: 'c', * label: 'Option Three', * } ) * ] * } ); * $( 'body' ).append( select.$element ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Selects_and_Options * * @abstract * @class * @extends OO.ui.Widget * @mixins OO.ui.mixin.GroupWidget * * @constructor * @param {Object} [config] Configuration options * @cfg {OO.ui.OptionWidget[]} [items] An array of options to add to the select. * Options are created with {@link OO.ui.OptionWidget OptionWidget} classes. See * the [OOjs UI documentation on MediaWiki] [2] for examples. * [2]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Selects_and_Options */ OO.ui.SelectWidget = function OoUiSelectWidget( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.SelectWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.GroupWidget.call( this, $.extend( {}, config, { $group: this.$element } ) ); // Properties this.pressed = false; this.selecting = null; this.onMouseUpHandler = this.onMouseUp.bind( this ); this.onMouseMoveHandler = this.onMouseMove.bind( this ); this.onKeyDownHandler = this.onKeyDown.bind( this ); this.onKeyPressHandler = this.onKeyPress.bind( this ); this.keyPressBuffer = ''; this.keyPressBufferTimer = null; // Events this.connect( this, { toggle: 'onToggle' } ); this.$element.on( { mousedown: this.onMouseDown.bind( this ), mouseover: this.onMouseOver.bind( this ), mouseleave: this.onMouseLeave.bind( this ) } ); // Initialization this.$element .addClass( 'oo-ui-selectWidget oo-ui-selectWidget-depressed' ) .attr( 'role', 'listbox' ); if ( Array.isArray( config.items ) ) { this.addItems( config.items ); } }; /* Setup */ OO.inheritClass( OO.ui.SelectWidget, OO.ui.Widget ); // Need to mixin base class as well OO.mixinClass( OO.ui.SelectWidget, OO.ui.mixin.GroupElement ); OO.mixinClass( OO.ui.SelectWidget, OO.ui.mixin.GroupWidget ); /* Static */ OO.ui.SelectWidget.static.passAllFilter = function () { return true; }; /* Events */ /** * @event highlight * * A `highlight` event is emitted when the highlight is changed with the #highlightItem method. * * @param {OO.ui.OptionWidget|null} item Highlighted item */ /** * @event press * * A `press` event is emitted when the #pressItem method is used to programmatically modify the * pressed state of an option. * * @param {OO.ui.OptionWidget|null} item Pressed item */ /** * @event select * * A `select` event is emitted when the selection is modified programmatically with the #selectItem method. * * @param {OO.ui.OptionWidget|null} item Selected item */ /** * @event choose * A `choose` event is emitted when an item is chosen with the #chooseItem method. * @param {OO.ui.OptionWidget} item Chosen item */ /** * @event add * * An `add` event is emitted when options are added to the select with the #addItems method. * * @param {OO.ui.OptionWidget[]} items Added items * @param {number} index Index of insertion point */ /** * @event remove * * A `remove` event is emitted when options are removed from the select with the #clearItems * or #removeItems methods. * * @param {OO.ui.OptionWidget[]} items Removed items */ /* Methods */ /** * Handle mouse down events. * * @private * @param {jQuery.Event} e Mouse down event */ OO.ui.SelectWidget.prototype.onMouseDown = function ( e ) { var item; if ( !this.isDisabled() && e.which === 1 ) { this.togglePressed( true ); item = this.getTargetItem( e ); if ( item && item.isSelectable() ) { this.pressItem( item ); this.selecting = item; OO.ui.addCaptureEventListener( this.getElementDocument(), 'mouseup', this.onMouseUpHandler ); OO.ui.addCaptureEventListener( this.getElementDocument(), 'mousemove', this.onMouseMoveHandler ); } } return false; }; /** * Handle mouse up events. * * @private * @param {jQuery.Event} e Mouse up event */ OO.ui.SelectWidget.prototype.onMouseUp = function ( e ) { var item; this.togglePressed( false ); if ( !this.selecting ) { item = this.getTargetItem( e ); if ( item && item.isSelectable() ) { this.selecting = item; } } if ( !this.isDisabled() && e.which === 1 && this.selecting ) { this.pressItem( null ); this.chooseItem( this.selecting ); this.selecting = null; } OO.ui.removeCaptureEventListener( this.getElementDocument(), 'mouseup', this.onMouseUpHandler ); OO.ui.removeCaptureEventListener( this.getElementDocument(), 'mousemove', this.onMouseMoveHandler ); return false; }; /** * Handle mouse move events. * * @private * @param {jQuery.Event} e Mouse move event */ OO.ui.SelectWidget.prototype.onMouseMove = function ( e ) { var item; if ( !this.isDisabled() && this.pressed ) { item = this.getTargetItem( e ); if ( item && item !== this.selecting && item.isSelectable() ) { this.pressItem( item ); this.selecting = item; } } return false; }; /** * Handle mouse over events. * * @private * @param {jQuery.Event} e Mouse over event */ OO.ui.SelectWidget.prototype.onMouseOver = function ( e ) { var item; if ( !this.isDisabled() ) { item = this.getTargetItem( e ); this.highlightItem( item && item.isHighlightable() ? item : null ); } return false; }; /** * Handle mouse leave events. * * @private * @param {jQuery.Event} e Mouse over event */ OO.ui.SelectWidget.prototype.onMouseLeave = function () { if ( !this.isDisabled() ) { this.highlightItem( null ); } return false; }; /** * Handle key down events. * * @protected * @param {jQuery.Event} e Key down event */ OO.ui.SelectWidget.prototype.onKeyDown = function ( e ) { var nextItem, handled = false, currentItem = this.getHighlightedItem() || this.getSelectedItem(); if ( !this.isDisabled() && this.isVisible() ) { switch ( e.keyCode ) { case OO.ui.Keys.ENTER: if ( currentItem && currentItem.constructor.static.highlightable ) { // Was only highlighted, now let's select it. No-op if already selected. this.chooseItem( currentItem ); handled = true; } break; case OO.ui.Keys.UP: case OO.ui.Keys.LEFT: this.clearKeyPressBuffer(); nextItem = this.getRelativeSelectableItem( currentItem, -1 ); handled = true; break; case OO.ui.Keys.DOWN: case OO.ui.Keys.RIGHT: this.clearKeyPressBuffer(); nextItem = this.getRelativeSelectableItem( currentItem, 1 ); handled = true; break; case OO.ui.Keys.ESCAPE: case OO.ui.Keys.TAB: if ( currentItem && currentItem.constructor.static.highlightable ) { currentItem.setHighlighted( false ); } this.unbindKeyDownListener(); this.unbindKeyPressListener(); // Don't prevent tabbing away / defocusing handled = false; break; } if ( nextItem ) { if ( nextItem.constructor.static.highlightable ) { this.highlightItem( nextItem ); } else { this.chooseItem( nextItem ); } nextItem.scrollElementIntoView(); } if ( handled ) { // Can't just return false, because e is not always a jQuery event e.preventDefault(); e.stopPropagation(); } } }; /** * Bind key down listener. * * @protected */ OO.ui.SelectWidget.prototype.bindKeyDownListener = function () { OO.ui.addCaptureEventListener( this.getElementWindow(), 'keydown', this.onKeyDownHandler ); }; /** * Unbind key down listener. * * @protected */ OO.ui.SelectWidget.prototype.unbindKeyDownListener = function () { OO.ui.removeCaptureEventListener( this.getElementWindow(), 'keydown', this.onKeyDownHandler ); }; /** * Clear the key-press buffer * * @protected */ OO.ui.SelectWidget.prototype.clearKeyPressBuffer = function () { if ( this.keyPressBufferTimer ) { clearTimeout( this.keyPressBufferTimer ); this.keyPressBufferTimer = null; } this.keyPressBuffer = ''; }; /** * Handle key press events. * * @protected * @param {jQuery.Event} e Key press event */ OO.ui.SelectWidget.prototype.onKeyPress = function ( e ) { var c, filter, item; if ( !e.charCode ) { if ( e.keyCode === OO.ui.Keys.BACKSPACE && this.keyPressBuffer !== '' ) { this.keyPressBuffer = this.keyPressBuffer.substr( 0, this.keyPressBuffer.length - 1 ); return false; } return; } if ( String.fromCodePoint ) { c = String.fromCodePoint( e.charCode ); } else { c = String.fromCharCode( e.charCode ); } if ( this.keyPressBufferTimer ) { clearTimeout( this.keyPressBufferTimer ); } this.keyPressBufferTimer = setTimeout( this.clearKeyPressBuffer.bind( this ), 1500 ); item = this.getHighlightedItem() || this.getSelectedItem(); if ( this.keyPressBuffer === c ) { // Common (if weird) special case: typing "xxxx" will cycle through all // the items beginning with "x". if ( item ) { item = this.getRelativeSelectableItem( item, 1 ); } } else { this.keyPressBuffer += c; } filter = this.getItemMatcher( this.keyPressBuffer, false ); if ( !item || !filter( item ) ) { item = this.getRelativeSelectableItem( item, 1, filter ); } if ( item ) { if ( item.constructor.static.highlightable ) { this.highlightItem( item ); } else { this.chooseItem( item ); } item.scrollElementIntoView(); } return false; }; /** * Get a matcher for the specific string * * @protected * @param {string} s String to match against items * @param {boolean} [exact=false] Only accept exact matches * @return {Function} function ( OO.ui.OptionItem ) => boolean */ OO.ui.SelectWidget.prototype.getItemMatcher = function ( s, exact ) { var re; if ( s.normalize ) { s = s.normalize(); } s = exact ? s.trim() : s.replace( /^\s+/, '' ); re = '^\\s*' + s.replace( /([\\{}()|.?*+\-\^$\[\]])/g, '\\$1' ).replace( /\s+/g, '\\s+' ); if ( exact ) { re += '\\s*$'; } re = new RegExp( re, 'i' ); return function ( item ) { var l = item.getLabel(); if ( typeof l !== 'string' ) { l = item.$label.text(); } if ( l.normalize ) { l = l.normalize(); } return re.test( l ); }; }; /** * Bind key press listener. * * @protected */ OO.ui.SelectWidget.prototype.bindKeyPressListener = function () { OO.ui.addCaptureEventListener( this.getElementWindow(), 'keypress', this.onKeyPressHandler ); }; /** * Unbind key down listener. * * If you override this, be sure to call this.clearKeyPressBuffer() from your * implementation. * * @protected */ OO.ui.SelectWidget.prototype.unbindKeyPressListener = function () { OO.ui.removeCaptureEventListener( this.getElementWindow(), 'keypress', this.onKeyPressHandler ); this.clearKeyPressBuffer(); }; /** * Visibility change handler * * @protected * @param {boolean} visible */ OO.ui.SelectWidget.prototype.onToggle = function ( visible ) { if ( !visible ) { this.clearKeyPressBuffer(); } }; /** * Get the closest item to a jQuery.Event. * * @private * @param {jQuery.Event} e * @return {OO.ui.OptionWidget|null} Outline item widget, `null` if none was found */ OO.ui.SelectWidget.prototype.getTargetItem = function ( e ) { return $( e.target ).closest( '.oo-ui-optionWidget' ).data( 'oo-ui-optionWidget' ) || null; }; /** * Get selected item. * * @return {OO.ui.OptionWidget|null} Selected item, `null` if no item is selected */ OO.ui.SelectWidget.prototype.getSelectedItem = function () { var i, len; for ( i = 0, len = this.items.length; i < len; i++ ) { if ( this.items[ i ].isSelected() ) { return this.items[ i ]; } } return null; }; /** * Get highlighted item. * * @return {OO.ui.OptionWidget|null} Highlighted item, `null` if no item is highlighted */ OO.ui.SelectWidget.prototype.getHighlightedItem = function () { var i, len; for ( i = 0, len = this.items.length; i < len; i++ ) { if ( this.items[ i ].isHighlighted() ) { return this.items[ i ]; } } return null; }; /** * Toggle pressed state. * * Press is a state that occurs when a user mouses down on an item, but * has not yet let go of the mouse. The item may appear selected, but it will not be selected * until the user releases the mouse. * * @param {boolean} pressed An option is being pressed */ OO.ui.SelectWidget.prototype.togglePressed = function ( pressed ) { if ( pressed === undefined ) { pressed = !this.pressed; } if ( pressed !== this.pressed ) { this.$element .toggleClass( 'oo-ui-selectWidget-pressed', pressed ) .toggleClass( 'oo-ui-selectWidget-depressed', !pressed ); this.pressed = pressed; } }; /** * Highlight an option. If the `item` param is omitted, no options will be highlighted * and any existing highlight will be removed. The highlight is mutually exclusive. * * @param {OO.ui.OptionWidget} [item] Item to highlight, omit for no highlight * @fires highlight * @chainable */ OO.ui.SelectWidget.prototype.highlightItem = function ( item ) { var i, len, highlighted, changed = false; for ( i = 0, len = this.items.length; i < len; i++ ) { highlighted = this.items[ i ] === item; if ( this.items[ i ].isHighlighted() !== highlighted ) { this.items[ i ].setHighlighted( highlighted ); changed = true; } } if ( changed ) { this.emit( 'highlight', item ); } return this; }; /** * Fetch an item by its label. * * @param {string} label Label of the item to select. * @param {boolean} [prefix=false] Allow a prefix match, if only a single item matches * @return {OO.ui.Element|null} Item with equivalent label, `null` if none exists */ OO.ui.SelectWidget.prototype.getItemFromLabel = function ( label, prefix ) { var i, item, found, len = this.items.length, filter = this.getItemMatcher( label, true ); for ( i = 0; i < len; i++ ) { item = this.items[ i ]; if ( item instanceof OO.ui.OptionWidget && item.isSelectable() && filter( item ) ) { return item; } } if ( prefix ) { found = null; filter = this.getItemMatcher( label, false ); for ( i = 0; i < len; i++ ) { item = this.items[ i ]; if ( item instanceof OO.ui.OptionWidget && item.isSelectable() && filter( item ) ) { if ( found ) { return null; } found = item; } } if ( found ) { return found; } } return null; }; /** * Programmatically select an option by its label. If the item does not exist, * all options will be deselected. * * @param {string} [label] Label of the item to select. * @param {boolean} [prefix=false] Allow a prefix match, if only a single item matches * @fires select * @chainable */ OO.ui.SelectWidget.prototype.selectItemByLabel = function ( label, prefix ) { var itemFromLabel = this.getItemFromLabel( label, !!prefix ); if ( label === undefined || !itemFromLabel ) { return this.selectItem(); } return this.selectItem( itemFromLabel ); }; /** * Programmatically select an option by its data. If the `data` parameter is omitted, * or if the item does not exist, all options will be deselected. * * @param {Object|string} [data] Value of the item to select, omit to deselect all * @fires select * @chainable */ OO.ui.SelectWidget.prototype.selectItemByData = function ( data ) { var itemFromData = this.getItemFromData( data ); if ( data === undefined || !itemFromData ) { return this.selectItem(); } return this.selectItem( itemFromData ); }; /** * Programmatically select an option by its reference. If the `item` parameter is omitted, * all options will be deselected. * * @param {OO.ui.OptionWidget} [item] Item to select, omit to deselect all * @fires select * @chainable */ OO.ui.SelectWidget.prototype.selectItem = function ( item ) { var i, len, selected, changed = false; for ( i = 0, len = this.items.length; i < len; i++ ) { selected = this.items[ i ] === item; if ( this.items[ i ].isSelected() !== selected ) { this.items[ i ].setSelected( selected ); changed = true; } } if ( changed ) { this.emit( 'select', item ); } return this; }; /** * Press an item. * * Press is a state that occurs when a user mouses down on an item, but has not * yet let go of the mouse. The item may appear selected, but it will not be selected until the user * releases the mouse. * * @param {OO.ui.OptionWidget} [item] Item to press, omit to depress all * @fires press * @chainable */ OO.ui.SelectWidget.prototype.pressItem = function ( item ) { var i, len, pressed, changed = false; for ( i = 0, len = this.items.length; i < len; i++ ) { pressed = this.items[ i ] === item; if ( this.items[ i ].isPressed() !== pressed ) { this.items[ i ].setPressed( pressed ); changed = true; } } if ( changed ) { this.emit( 'press', item ); } return this; }; /** * Choose an item. * * Note that ‘choose’ should never be modified programmatically. A user can choose * an option with the keyboard or mouse and it becomes selected. To select an item programmatically, * use the #selectItem method. * * This method is identical to #selectItem, but may vary in subclasses that take additional action * when users choose an item with the keyboard or mouse. * * @param {OO.ui.OptionWidget} item Item to choose * @fires choose * @chainable */ OO.ui.SelectWidget.prototype.chooseItem = function ( item ) { if ( item ) { this.selectItem( item ); this.emit( 'choose', item ); } return this; }; /** * Get an option by its position relative to the specified item (or to the start of the option array, * if item is `null`). The direction in which to search through the option array is specified with a * number: -1 for reverse (the default) or 1 for forward. The method will return an option, or * `null` if there are no options in the array. * * @param {OO.ui.OptionWidget|null} item Item to describe the start position, or `null` to start at the beginning of the array. * @param {number} direction Direction to move in: -1 to move backward, 1 to move forward * @param {Function} filter Only consider items for which this function returns * true. Function takes an OO.ui.OptionWidget and returns a boolean. * @return {OO.ui.OptionWidget|null} Item at position, `null` if there are no items in the select */ OO.ui.SelectWidget.prototype.getRelativeSelectableItem = function ( item, direction, filter ) { var currentIndex, nextIndex, i, increase = direction > 0 ? 1 : -1, len = this.items.length; if ( !$.isFunction( filter ) ) { filter = OO.ui.SelectWidget.static.passAllFilter; } if ( item instanceof OO.ui.OptionWidget ) { currentIndex = this.items.indexOf( item ); nextIndex = ( currentIndex + increase + len ) % len; } else { // If no item is selected and moving forward, start at the beginning. // If moving backward, start at the end. nextIndex = direction > 0 ? 0 : len - 1; } for ( i = 0; i < len; i++ ) { item = this.items[ nextIndex ]; if ( item instanceof OO.ui.OptionWidget && item.isSelectable() && filter( item ) ) { return item; } nextIndex = ( nextIndex + increase + len ) % len; } return null; }; /** * Get the next selectable item or `null` if there are no selectable items. * Disabled options and menu-section markers and breaks are not selectable. * * @return {OO.ui.OptionWidget|null} Item, `null` if there aren't any selectable items */ OO.ui.SelectWidget.prototype.getFirstSelectableItem = function () { var i, len, item; for ( i = 0, len = this.items.length; i < len; i++ ) { item = this.items[ i ]; if ( item instanceof OO.ui.OptionWidget && item.isSelectable() ) { return item; } } return null; }; /** * Add an array of options to the select. Optionally, an index number can be used to * specify an insertion point. * * @param {OO.ui.OptionWidget[]} items Items to add * @param {number} [index] Index to insert items after * @fires add * @chainable */ OO.ui.SelectWidget.prototype.addItems = function ( items, index ) { // Mixin method OO.ui.mixin.GroupWidget.prototype.addItems.call( this, items, index ); // Always provide an index, even if it was omitted this.emit( 'add', items, index === undefined ? this.items.length - items.length - 1 : index ); return this; }; /** * Remove the specified array of options from the select. Options will be detached * from the DOM, not removed, so they can be reused later. To remove all options from * the select, you may wish to use the #clearItems method instead. * * @param {OO.ui.OptionWidget[]} items Items to remove * @fires remove * @chainable */ OO.ui.SelectWidget.prototype.removeItems = function ( items ) { var i, len, item; // Deselect items being removed for ( i = 0, len = items.length; i < len; i++ ) { item = items[ i ]; if ( item.isSelected() ) { this.selectItem( null ); } } // Mixin method OO.ui.mixin.GroupWidget.prototype.removeItems.call( this, items ); this.emit( 'remove', items ); return this; }; /** * Clear all options from the select. Options will be detached from the DOM, not removed, * so that they can be reused later. To remove a subset of options from the select, use * the #removeItems method. * * @fires remove * @chainable */ OO.ui.SelectWidget.prototype.clearItems = function () { var items = this.items.slice(); // Mixin method OO.ui.mixin.GroupWidget.prototype.clearItems.call( this ); // Clear selection this.selectItem( null ); this.emit( 'remove', items ); return this; }; /** * ButtonSelectWidget is a {@link OO.ui.SelectWidget select widget} that contains * button options and is used together with * OO.ui.ButtonOptionWidget. The ButtonSelectWidget provides an interface for * highlighting, choosing, and selecting mutually exclusive options. Please see * the [OOjs UI documentation on MediaWiki] [1] for more information. * * @example * // Example: A ButtonSelectWidget that contains three ButtonOptionWidgets * var option1 = new OO.ui.ButtonOptionWidget( { * data: 1, * label: 'Option 1', * title: 'Button option 1' * } ); * * var option2 = new OO.ui.ButtonOptionWidget( { * data: 2, * label: 'Option 2', * title: 'Button option 2' * } ); * * var option3 = new OO.ui.ButtonOptionWidget( { * data: 3, * label: 'Option 3', * title: 'Button option 3' * } ); * * var buttonSelect=new OO.ui.ButtonSelectWidget( { * items: [ option1, option2, option3 ] * } ); * $( 'body' ).append( buttonSelect.$element ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Selects_and_Options * * @class * @extends OO.ui.SelectWidget * @mixins OO.ui.mixin.TabIndexedElement * * @constructor * @param {Object} [config] Configuration options */ OO.ui.ButtonSelectWidget = function OoUiButtonSelectWidget( config ) { // Parent constructor OO.ui.ButtonSelectWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.TabIndexedElement.call( this, config ); // Events this.$element.on( { focus: this.bindKeyDownListener.bind( this ), blur: this.unbindKeyDownListener.bind( this ) } ); // Initialization this.$element.addClass( 'oo-ui-buttonSelectWidget' ); }; /* Setup */ OO.inheritClass( OO.ui.ButtonSelectWidget, OO.ui.SelectWidget ); OO.mixinClass( OO.ui.ButtonSelectWidget, OO.ui.mixin.TabIndexedElement ); /** * RadioSelectWidget is a {@link OO.ui.SelectWidget select widget} that contains radio * options and is used together with OO.ui.RadioOptionWidget. The RadioSelectWidget provides * an interface for adding, removing and selecting options. * Please see the [OOjs UI documentation on MediaWiki][1] for more information. * * If you want to use this within a HTML form, such as a OO.ui.FormLayout, use * OO.ui.RadioSelectInputWidget instead. * * @example * // A RadioSelectWidget with RadioOptions. * var option1 = new OO.ui.RadioOptionWidget( { * data: 'a', * label: 'Selected radio option' * } ); * * var option2 = new OO.ui.RadioOptionWidget( { * data: 'b', * label: 'Unselected radio option' * } ); * * var radioSelect=new OO.ui.RadioSelectWidget( { * items: [ option1, option2 ] * } ); * * // Select 'option 1' using the RadioSelectWidget's selectItem() method. * radioSelect.selectItem( option1 ); * * $( 'body' ).append( radioSelect.$element ); * * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Selects_and_Options * * @class * @extends OO.ui.SelectWidget * @mixins OO.ui.mixin.TabIndexedElement * * @constructor * @param {Object} [config] Configuration options */ OO.ui.RadioSelectWidget = function OoUiRadioSelectWidget( config ) { // Parent constructor OO.ui.RadioSelectWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.TabIndexedElement.call( this, config ); // Events this.$element.on( { focus: this.bindKeyDownListener.bind( this ), blur: this.unbindKeyDownListener.bind( this ) } ); // Initialization this.$element .addClass( 'oo-ui-radioSelectWidget' ) .attr( 'role', 'radiogroup' ); }; /* Setup */ OO.inheritClass( OO.ui.RadioSelectWidget, OO.ui.SelectWidget ); OO.mixinClass( OO.ui.RadioSelectWidget, OO.ui.mixin.TabIndexedElement ); /** * MenuSelectWidget is a {@link OO.ui.SelectWidget select widget} that contains options and * is used together with OO.ui.MenuOptionWidget. It is designed be used as part of another widget. * See {@link OO.ui.DropdownWidget DropdownWidget}, {@link OO.ui.ComboBoxInputWidget ComboBoxInputWidget}, * and {@link OO.ui.mixin.LookupElement LookupElement} for examples of widgets that contain menus. * MenuSelectWidgets themselves are not instantiated directly, rather subclassed * and customized to be opened, closed, and displayed as needed. * * By default, menus are clipped to the visible viewport and are not visible when a user presses the * mouse outside the menu. * * Menus also have support for keyboard interaction: * * - Enter/Return key: choose and select a menu option * - Up-arrow key: highlight the previous menu option * - Down-arrow key: highlight the next menu option * - Esc key: hide the menu * * Please see the [OOjs UI documentation on MediaWiki][1] for more information. * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Selects_and_Options * * @class * @extends OO.ui.SelectWidget * @mixins OO.ui.mixin.ClippableElement * * @constructor * @param {Object} [config] Configuration options * @cfg {OO.ui.TextInputWidget} [input] Text input used to implement option highlighting for menu items that match * the text the user types. This config is used by {@link OO.ui.ComboBoxInputWidget ComboBoxInputWidget} * and {@link OO.ui.mixin.LookupElement LookupElement} * @cfg {jQuery} [$input] Text input used to implement option highlighting for menu items that match * the text the user types. This config is used by {@link OO.ui.CapsuleMultiSelectWidget CapsuleMultiSelectWidget} * @cfg {OO.ui.Widget} [widget] Widget associated with the menu's active state. If the user clicks the mouse * anywhere on the page outside of this widget, the menu is hidden. For example, if there is a button * that toggles the menu's visibility on click, the menu will be hidden then re-shown when the user clicks * that button, unless the button (or its parent widget) is passed in here. * @cfg {boolean} [autoHide=true] Hide the menu when the mouse is pressed outside the menu. * @cfg {boolean} [filterFromInput=false] Filter the displayed options from the input */ OO.ui.MenuSelectWidget = function OoUiMenuSelectWidget( config ) { // Configuration initialization config = config || {}; // Parent constructor OO.ui.MenuSelectWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.ClippableElement.call( this, $.extend( {}, config, { $clippable: this.$group } ) ); // Properties this.newItems = null; this.autoHide = config.autoHide === undefined || !!config.autoHide; this.filterFromInput = !!config.filterFromInput; this.$input = config.$input ? config.$input : config.input ? config.input.$input : null; this.$widget = config.widget ? config.widget.$element : null; this.onDocumentMouseDownHandler = this.onDocumentMouseDown.bind( this ); this.onInputEditHandler = OO.ui.debounce( this.updateItemVisibility.bind( this ), 100 ); // Initialization this.$element .addClass( 'oo-ui-menuSelectWidget' ) .attr( 'role', 'menu' ); // Initially hidden - using #toggle may cause errors if subclasses override toggle with methods // that reference properties not initialized at that time of parent class construction // TODO: Find a better way to handle post-constructor setup this.visible = false; this.$element.addClass( 'oo-ui-element-hidden' ); }; /* Setup */ OO.inheritClass( OO.ui.MenuSelectWidget, OO.ui.SelectWidget ); OO.mixinClass( OO.ui.MenuSelectWidget, OO.ui.mixin.ClippableElement ); /* Methods */ /** * Handles document mouse down events. * * @protected * @param {jQuery.Event} e Key down event */ OO.ui.MenuSelectWidget.prototype.onDocumentMouseDown = function ( e ) { if ( !OO.ui.contains( this.$element[ 0 ], e.target, true ) && ( !this.$widget || !OO.ui.contains( this.$widget[ 0 ], e.target, true ) ) ) { this.toggle( false ); } }; /** * @inheritdoc */ OO.ui.MenuSelectWidget.prototype.onKeyDown = function ( e ) { var currentItem = this.getHighlightedItem() || this.getSelectedItem(); if ( !this.isDisabled() && this.isVisible() ) { switch ( e.keyCode ) { case OO.ui.Keys.LEFT: case OO.ui.Keys.RIGHT: // Do nothing if a text field is associated, arrow keys will be handled natively if ( !this.$input ) { OO.ui.MenuSelectWidget.parent.prototype.onKeyDown.call( this, e ); } break; case OO.ui.Keys.ESCAPE: case OO.ui.Keys.TAB: if ( currentItem ) { currentItem.setHighlighted( false ); } this.toggle( false ); // Don't prevent tabbing away, prevent defocusing if ( e.keyCode === OO.ui.Keys.ESCAPE ) { e.preventDefault(); e.stopPropagation(); } break; default: OO.ui.MenuSelectWidget.parent.prototype.onKeyDown.call( this, e ); return; } } }; /** * Update menu item visibility after input changes. * @protected */ OO.ui.MenuSelectWidget.prototype.updateItemVisibility = function () { var i, item, len = this.items.length, showAll = !this.isVisible(), filter = showAll ? null : this.getItemMatcher( this.$input.val() ); for ( i = 0; i < len; i++ ) { item = this.items[ i ]; if ( item instanceof OO.ui.OptionWidget ) { item.toggle( showAll || filter( item ) ); } } // Reevaluate clipping this.clip(); }; /** * @inheritdoc */ OO.ui.MenuSelectWidget.prototype.bindKeyDownListener = function () { if ( this.$input ) { this.$input.on( 'keydown', this.onKeyDownHandler ); } else { OO.ui.MenuSelectWidget.parent.prototype.bindKeyDownListener.call( this ); } }; /** * @inheritdoc */ OO.ui.MenuSelectWidget.prototype.unbindKeyDownListener = function () { if ( this.$input ) { this.$input.off( 'keydown', this.onKeyDownHandler ); } else { OO.ui.MenuSelectWidget.parent.prototype.unbindKeyDownListener.call( this ); } }; /** * @inheritdoc */ OO.ui.MenuSelectWidget.prototype.bindKeyPressListener = function () { if ( this.$input ) { if ( this.filterFromInput ) { this.$input.on( 'keydown mouseup cut paste change input select', this.onInputEditHandler ); } } else { OO.ui.MenuSelectWidget.parent.prototype.bindKeyPressListener.call( this ); } }; /** * @inheritdoc */ OO.ui.MenuSelectWidget.prototype.unbindKeyPressListener = function () { if ( this.$input ) { if ( this.filterFromInput ) { this.$input.off( 'keydown mouseup cut paste change input select', this.onInputEditHandler ); this.updateItemVisibility(); } } else { OO.ui.MenuSelectWidget.parent.prototype.unbindKeyPressListener.call( this ); } }; /** * Choose an item. * * When a user chooses an item, the menu is closed. * * Note that ‘choose’ should never be modified programmatically. A user can choose an option with the keyboard * or mouse and it becomes selected. To select an item programmatically, use the #selectItem method. * @param {OO.ui.OptionWidget} item Item to choose * @chainable */ OO.ui.MenuSelectWidget.prototype.chooseItem = function ( item ) { OO.ui.MenuSelectWidget.parent.prototype.chooseItem.call( this, item ); this.toggle( false ); return this; }; /** * @inheritdoc */ OO.ui.MenuSelectWidget.prototype.addItems = function ( items, index ) { var i, len, item; // Parent method OO.ui.MenuSelectWidget.parent.prototype.addItems.call( this, items, index ); // Auto-initialize if ( !this.newItems ) { this.newItems = []; } for ( i = 0, len = items.length; i < len; i++ ) { item = items[ i ]; if ( this.isVisible() ) { // Defer fitting label until item has been attached item.fitLabel(); } else { this.newItems.push( item ); } } // Reevaluate clipping this.clip(); return this; }; /** * @inheritdoc */ OO.ui.MenuSelectWidget.prototype.removeItems = function ( items ) { // Parent method OO.ui.MenuSelectWidget.parent.prototype.removeItems.call( this, items ); // Reevaluate clipping this.clip(); return this; }; /** * @inheritdoc */ OO.ui.MenuSelectWidget.prototype.clearItems = function () { // Parent method OO.ui.MenuSelectWidget.parent.prototype.clearItems.call( this ); // Reevaluate clipping this.clip(); return this; }; /** * @inheritdoc */ OO.ui.MenuSelectWidget.prototype.toggle = function ( visible ) { var i, len, change; visible = ( visible === undefined ? !this.visible : !!visible ) && !!this.items.length; change = visible !== this.isVisible(); // Parent method OO.ui.MenuSelectWidget.parent.prototype.toggle.call( this, visible ); if ( change ) { if ( visible ) { this.bindKeyDownListener(); this.bindKeyPressListener(); if ( this.newItems && this.newItems.length ) { for ( i = 0, len = this.newItems.length; i < len; i++ ) { this.newItems[ i ].fitLabel(); } this.newItems = null; } this.toggleClipping( true ); // Auto-hide if ( this.autoHide ) { OO.ui.addCaptureEventListener( this.getElementDocument(), 'mousedown', this.onDocumentMouseDownHandler ); } } else { this.unbindKeyDownListener(); this.unbindKeyPressListener(); OO.ui.removeCaptureEventListener( this.getElementDocument(), 'mousedown', this.onDocumentMouseDownHandler ); this.toggleClipping( false ); } } return this; }; /** * FloatingMenuSelectWidget is a menu that will stick under a specified * container, even when it is inserted elsewhere in the document (for example, * in a OO.ui.Window's $overlay). This is sometimes necessary to prevent the * menu from being clipped too aggresively. * * The menu's position is automatically calculated and maintained when the menu * is toggled or the window is resized. * * See OO.ui.ComboBoxInputWidget for an example of a widget that uses this class. * * @class * @extends OO.ui.MenuSelectWidget * @mixins OO.ui.mixin.FloatableElement * * @constructor * @param {OO.ui.Widget} [inputWidget] Widget to provide the menu for. * Deprecated, omit this parameter and specify `$container` instead. * @param {Object} [config] Configuration options * @cfg {jQuery} [$container=inputWidget.$element] Element to render menu under */ OO.ui.FloatingMenuSelectWidget = function OoUiFloatingMenuSelectWidget( inputWidget, config ) { // Allow 'inputWidget' parameter and config for backwards compatibility if ( OO.isPlainObject( inputWidget ) && config === undefined ) { config = inputWidget; inputWidget = config.inputWidget; } // Configuration initialization config = config || {}; // Parent constructor OO.ui.FloatingMenuSelectWidget.parent.call( this, config ); // Properties (must be set before mixin constructors) this.inputWidget = inputWidget; // For backwards compatibility this.$container = config.$container || this.inputWidget.$element; // Mixins constructors OO.ui.mixin.FloatableElement.call( this, $.extend( {}, config, { $floatableContainer: this.$container } ) ); // Initialization this.$element.addClass( 'oo-ui-floatingMenuSelectWidget' ); // For backwards compatibility this.$element.addClass( 'oo-ui-textInputMenuSelectWidget' ); }; /* Setup */ OO.inheritClass( OO.ui.FloatingMenuSelectWidget, OO.ui.MenuSelectWidget ); OO.mixinClass( OO.ui.FloatingMenuSelectWidget, OO.ui.mixin.FloatableElement ); // For backwards compatibility OO.ui.TextInputMenuSelectWidget = OO.ui.FloatingMenuSelectWidget; /* Methods */ /** * @inheritdoc */ OO.ui.FloatingMenuSelectWidget.prototype.toggle = function ( visible ) { var change; visible = visible === undefined ? !this.isVisible() : !!visible; change = visible !== this.isVisible(); if ( change && visible ) { // Make sure the width is set before the parent method runs. this.setIdealSize( this.$container.width() ); } // Parent method // This will call this.clip(), which is nonsensical since we're not positioned yet... OO.ui.FloatingMenuSelectWidget.parent.prototype.toggle.call( this, visible ); if ( change ) { this.togglePositioning( this.isVisible() ); } return this; }; /** * OutlineSelectWidget is a structured list that contains {@link OO.ui.OutlineOptionWidget outline options} * A set of controls can be provided with an {@link OO.ui.OutlineControlsWidget outline controls} widget. * * **Currently, this class is only used by {@link OO.ui.BookletLayout booklet layouts}.** * * @class * @extends OO.ui.SelectWidget * @mixins OO.ui.mixin.TabIndexedElement * * @constructor * @param {Object} [config] Configuration options */ OO.ui.OutlineSelectWidget = function OoUiOutlineSelectWidget( config ) { // Parent constructor OO.ui.OutlineSelectWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.TabIndexedElement.call( this, config ); // Events this.$element.on( { focus: this.bindKeyDownListener.bind( this ), blur: this.unbindKeyDownListener.bind( this ) } ); // Initialization this.$element.addClass( 'oo-ui-outlineSelectWidget' ); }; /* Setup */ OO.inheritClass( OO.ui.OutlineSelectWidget, OO.ui.SelectWidget ); OO.mixinClass( OO.ui.OutlineSelectWidget, OO.ui.mixin.TabIndexedElement ); /** * TabSelectWidget is a list that contains {@link OO.ui.TabOptionWidget tab options} * * **Currently, this class is only used by {@link OO.ui.IndexLayout index layouts}.** * * @class * @extends OO.ui.SelectWidget * @mixins OO.ui.mixin.TabIndexedElement * * @constructor * @param {Object} [config] Configuration options */ OO.ui.TabSelectWidget = function OoUiTabSelectWidget( config ) { // Parent constructor OO.ui.TabSelectWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.TabIndexedElement.call( this, config ); // Events this.$element.on( { focus: this.bindKeyDownListener.bind( this ), blur: this.unbindKeyDownListener.bind( this ) } ); // Initialization this.$element.addClass( 'oo-ui-tabSelectWidget' ); }; /* Setup */ OO.inheritClass( OO.ui.TabSelectWidget, OO.ui.SelectWidget ); OO.mixinClass( OO.ui.TabSelectWidget, OO.ui.mixin.TabIndexedElement ); /** * NumberInputWidgets combine a {@link OO.ui.TextInputWidget text input} (where a value * can be entered manually) and two {@link OO.ui.ButtonWidget button widgets} * (to adjust the value in increments) to allow the user to enter a number. * * @example * // Example: A NumberInputWidget. * var numberInput = new OO.ui.NumberInputWidget( { * label: 'NumberInputWidget', * input: { value: 5, min: 1, max: 10 } * } ); * $( 'body' ).append( numberInput.$element ); * * @class * @extends OO.ui.Widget * * @constructor * @param {Object} [config] Configuration options * @cfg {Object} [input] Configuration options to pass to the {@link OO.ui.TextInputWidget text input widget}. * @cfg {Object} [minusButton] Configuration options to pass to the {@link OO.ui.ButtonWidget decrementing button widget}. * @cfg {Object} [plusButton] Configuration options to pass to the {@link OO.ui.ButtonWidget incrementing button widget}. * @cfg {boolean} [isInteger=false] Whether the field accepts only integer values. * @cfg {number} [min=-Infinity] Minimum allowed value * @cfg {number} [max=Infinity] Maximum allowed value * @cfg {number} [step=1] Delta when using the buttons or up/down arrow keys * @cfg {number|null} [pageStep] Delta when using the page-up/page-down keys. Defaults to 10 times #step. */ OO.ui.NumberInputWidget = function OoUiNumberInputWidget( config ) { // Configuration initialization config = $.extend( { isInteger: false, min: -Infinity, max: Infinity, step: 1, pageStep: null }, config ); // Parent constructor OO.ui.NumberInputWidget.parent.call( this, config ); // Properties this.input = new OO.ui.TextInputWidget( $.extend( { disabled: this.isDisabled() }, config.input ) ); this.minusButton = new OO.ui.ButtonWidget( $.extend( { disabled: this.isDisabled(), tabIndex: -1 }, config.minusButton, { classes: [ 'oo-ui-numberInputWidget-minusButton' ], label: '−' } ) ); this.plusButton = new OO.ui.ButtonWidget( $.extend( { disabled: this.isDisabled(), tabIndex: -1 }, config.plusButton, { classes: [ 'oo-ui-numberInputWidget-plusButton' ], label: '+' } ) ); // Events this.input.connect( this, { change: this.emit.bind( this, 'change' ), enter: this.emit.bind( this, 'enter' ) } ); this.input.$input.on( { keydown: this.onKeyDown.bind( this ), 'wheel mousewheel DOMMouseScroll': this.onWheel.bind( this ) } ); this.plusButton.connect( this, { click: [ 'onButtonClick', +1 ] } ); this.minusButton.connect( this, { click: [ 'onButtonClick', -1 ] } ); // Initialization this.setIsInteger( !!config.isInteger ); this.setRange( config.min, config.max ); this.setStep( config.step, config.pageStep ); this.$field = $( '<div>' ).addClass( 'oo-ui-numberInputWidget-field' ) .append( this.minusButton.$element, this.input.$element, this.plusButton.$element ); this.$element.addClass( 'oo-ui-numberInputWidget' ).append( this.$field ); this.input.setValidation( this.validateNumber.bind( this ) ); }; /* Setup */ OO.inheritClass( OO.ui.NumberInputWidget, OO.ui.Widget ); /* Events */ /** * A `change` event is emitted when the value of the input changes. * * @event change */ /** * An `enter` event is emitted when the user presses 'enter' inside the text box. * * @event enter */ /* Methods */ /** * Set whether only integers are allowed * @param {boolean} flag */ OO.ui.NumberInputWidget.prototype.setIsInteger = function ( flag ) { this.isInteger = !!flag; this.input.setValidityFlag(); }; /** * Get whether only integers are allowed * @return {boolean} Flag value */ OO.ui.NumberInputWidget.prototype.getIsInteger = function () { return this.isInteger; }; /** * Set the range of allowed values * @param {number} min Minimum allowed value * @param {number} max Maximum allowed value */ OO.ui.NumberInputWidget.prototype.setRange = function ( min, max ) { if ( min > max ) { throw new Error( 'Minimum (' + min + ') must not be greater than maximum (' + max + ')' ); } this.min = min; this.max = max; this.input.setValidityFlag(); }; /** * Get the current range * @return {number[]} Minimum and maximum values */ OO.ui.NumberInputWidget.prototype.getRange = function () { return [ this.min, this.max ]; }; /** * Set the stepping deltas * @param {number} step Normal step * @param {number|null} pageStep Page step. If null, 10 * step will be used. */ OO.ui.NumberInputWidget.prototype.setStep = function ( step, pageStep ) { if ( step <= 0 ) { throw new Error( 'Step value must be positive' ); } if ( pageStep === null ) { pageStep = step * 10; } else if ( pageStep <= 0 ) { throw new Error( 'Page step value must be positive' ); } this.step = step; this.pageStep = pageStep; }; /** * Get the current stepping values * @return {number[]} Step and page step */ OO.ui.NumberInputWidget.prototype.getStep = function () { return [ this.step, this.pageStep ]; }; /** * Get the current value of the widget * @return {string} */ OO.ui.NumberInputWidget.prototype.getValue = function () { return this.input.getValue(); }; /** * Get the current value of the widget as a number * @return {number} May be NaN, or an invalid number */ OO.ui.NumberInputWidget.prototype.getNumericValue = function () { return +this.input.getValue(); }; /** * Set the value of the widget * @param {string} value Invalid values are allowed */ OO.ui.NumberInputWidget.prototype.setValue = function ( value ) { this.input.setValue( value ); }; /** * Adjust the value of the widget * @param {number} delta Adjustment amount */ OO.ui.NumberInputWidget.prototype.adjustValue = function ( delta ) { var n, v = this.getNumericValue(); delta = +delta; if ( isNaN( delta ) || !isFinite( delta ) ) { throw new Error( 'Delta must be a finite number' ); } if ( isNaN( v ) ) { n = 0; } else { n = v + delta; n = Math.max( Math.min( n, this.max ), this.min ); if ( this.isInteger ) { n = Math.round( n ); } } if ( n !== v ) { this.setValue( n ); } }; /** * Validate input * @private * @param {string} value Field value * @return {boolean} */ OO.ui.NumberInputWidget.prototype.validateNumber = function ( value ) { var n = +value; if ( isNaN( n ) || !isFinite( n ) ) { return false; } /*jshint bitwise: false */ if ( this.isInteger && ( n | 0 ) !== n ) { return false; } /*jshint bitwise: true */ if ( n < this.min || n > this.max ) { return false; } return true; }; /** * Handle mouse click events. * * @private * @param {number} dir +1 or -1 */ OO.ui.NumberInputWidget.prototype.onButtonClick = function ( dir ) { this.adjustValue( dir * this.step ); }; /** * Handle mouse wheel events. * * @private * @param {jQuery.Event} event */ OO.ui.NumberInputWidget.prototype.onWheel = function ( event ) { var delta = 0; // Standard 'wheel' event if ( event.originalEvent.deltaMode !== undefined ) { this.sawWheelEvent = true; } if ( event.originalEvent.deltaY ) { delta = -event.originalEvent.deltaY; } else if ( event.originalEvent.deltaX ) { delta = event.originalEvent.deltaX; } // Non-standard events if ( !this.sawWheelEvent ) { if ( event.originalEvent.wheelDeltaX ) { delta = -event.originalEvent.wheelDeltaX; } else if ( event.originalEvent.wheelDeltaY ) { delta = event.originalEvent.wheelDeltaY; } else if ( event.originalEvent.wheelDelta ) { delta = event.originalEvent.wheelDelta; } else if ( event.originalEvent.detail ) { delta = -event.originalEvent.detail; } } if ( delta ) { delta = delta < 0 ? -1 : 1; this.adjustValue( delta * this.step ); } return false; }; /** * Handle key down events. * * @private * @param {jQuery.Event} e Key down event */ OO.ui.NumberInputWidget.prototype.onKeyDown = function ( e ) { if ( !this.isDisabled() ) { switch ( e.which ) { case OO.ui.Keys.UP: this.adjustValue( this.step ); return false; case OO.ui.Keys.DOWN: this.adjustValue( -this.step ); return false; case OO.ui.Keys.PAGEUP: this.adjustValue( this.pageStep ); return false; case OO.ui.Keys.PAGEDOWN: this.adjustValue( -this.pageStep ); return false; } } }; /** * @inheritdoc */ OO.ui.NumberInputWidget.prototype.setDisabled = function ( disabled ) { // Parent method OO.ui.NumberInputWidget.parent.prototype.setDisabled.call( this, disabled ); if ( this.input ) { this.input.setDisabled( this.isDisabled() ); } if ( this.minusButton ) { this.minusButton.setDisabled( this.isDisabled() ); } if ( this.plusButton ) { this.plusButton.setDisabled( this.isDisabled() ); } return this; }; /** * ToggleSwitches are switches that slide on and off. Their state is represented by a Boolean * value (`true` for ‘on’, and `false` otherwise, the default). The ‘off’ state is represented * visually by a slider in the leftmost position. * * @example * // Toggle switches in the 'off' and 'on' position. * var toggleSwitch1 = new OO.ui.ToggleSwitchWidget(); * var toggleSwitch2 = new OO.ui.ToggleSwitchWidget( { * value: true * } ); * * // Create a FieldsetLayout to layout and label switches * var fieldset = new OO.ui.FieldsetLayout( { * label: 'Toggle switches' * } ); * fieldset.addItems( [ * new OO.ui.FieldLayout( toggleSwitch1, { label: 'Off', align: 'top' } ), * new OO.ui.FieldLayout( toggleSwitch2, { label: 'On', align: 'top' } ) * ] ); * $( 'body' ).append( fieldset.$element ); * * @class * @extends OO.ui.ToggleWidget * @mixins OO.ui.mixin.TabIndexedElement * * @constructor * @param {Object} [config] Configuration options * @cfg {boolean} [value=false] The toggle switch’s initial on/off state. * By default, the toggle switch is in the 'off' position. */ OO.ui.ToggleSwitchWidget = function OoUiToggleSwitchWidget( config ) { // Parent constructor OO.ui.ToggleSwitchWidget.parent.call( this, config ); // Mixin constructors OO.ui.mixin.TabIndexedElement.call( this, config ); // Properties this.dragging = false; this.dragStart = null; this.sliding = false; this.$glow = $( '<span>' ); this.$grip = $( '<span>' ); // Events this.$element.on( { click: this.onClick.bind( this ), keypress: this.onKeyPress.bind( this ) } ); // Initialization this.$glow.addClass( 'oo-ui-toggleSwitchWidget-glow' ); this.$grip.addClass( 'oo-ui-toggleSwitchWidget-grip' ); this.$element .addClass( 'oo-ui-toggleSwitchWidget' ) .attr( 'role', 'checkbox' ) .append( this.$glow, this.$grip ); }; /* Setup */ OO.inheritClass( OO.ui.ToggleSwitchWidget, OO.ui.ToggleWidget ); OO.mixinClass( OO.ui.ToggleSwitchWidget, OO.ui.mixin.TabIndexedElement ); /* Methods */ /** * Handle mouse click events. * * @private * @param {jQuery.Event} e Mouse click event */ OO.ui.ToggleSwitchWidget.prototype.onClick = function ( e ) { if ( !this.isDisabled() && e.which === 1 ) { this.setValue( !this.value ); } return false; }; /** * Handle key press events. * * @private * @param {jQuery.Event} e Key press event */ OO.ui.ToggleSwitchWidget.prototype.onKeyPress = function ( e ) { if ( !this.isDisabled() && ( e.which === OO.ui.Keys.SPACE || e.which === OO.ui.Keys.ENTER ) ) { this.setValue( !this.value ); return false; } }; }( OO ) );
src/svg-icons/maps/local-grocery-store.js
andrejunges/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let MapsLocalGroceryStore = (props) => ( <SvgIcon {...props}> <path d="M7 18c-1.1 0-1.99.9-1.99 2S5.9 22 7 22s2-.9 2-2-.9-2-2-2zM1 2v2h2l3.6 7.59-1.35 2.45c-.16.28-.25.61-.25.96 0 1.1.9 2 2 2h12v-2H7.42c-.14 0-.25-.11-.25-.25l.03-.12.9-1.63h7.45c.75 0 1.41-.41 1.75-1.03l3.58-6.49c.08-.14.12-.31.12-.48 0-.55-.45-1-1-1H5.21l-.94-2H1zm16 16c-1.1 0-1.99.9-1.99 2s.89 2 1.99 2 2-.9 2-2-.9-2-2-2z"/> </SvgIcon> ); MapsLocalGroceryStore = pure(MapsLocalGroceryStore); MapsLocalGroceryStore.displayName = 'MapsLocalGroceryStore'; MapsLocalGroceryStore.muiName = 'SvgIcon'; export default MapsLocalGroceryStore;
src/svg-icons/action/perm-identity.js
pancho111203/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ActionPermIdentity = (props) => ( <SvgIcon {...props}> <path d="M12 5.9c1.16 0 2.1.94 2.1 2.1s-.94 2.1-2.1 2.1S9.9 9.16 9.9 8s.94-2.1 2.1-2.1m0 9c2.97 0 6.1 1.46 6.1 2.1v1.1H5.9V17c0-.64 3.13-2.1 6.1-2.1M12 4C9.79 4 8 5.79 8 8s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm0 9c-2.67 0-8 1.34-8 4v3h16v-3c0-2.66-5.33-4-8-4z"/> </SvgIcon> ); ActionPermIdentity = pure(ActionPermIdentity); ActionPermIdentity.displayName = 'ActionPermIdentity'; ActionPermIdentity.muiName = 'SvgIcon'; export default ActionPermIdentity;
_protected/vendor/bower/jquery/src/sizzle/test/jquery.js
VegovaSuper3/test2agen
/*! * jQuery JavaScript Library v1.9.1 * http://jquery.com/ * * Includes Sizzle.js * http://sizzlejs.com/ * * Copyright 2005, 2012 jQuery Foundation, Inc. and other contributors * Released under the MIT license * http://jquery.org/license * * Date: 2013-2-4 */ (function( window, undefined ) { // 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+ //"use strict"; var // The deferred used on DOM ready readyList, // A central reference to the root jQuery(document) rootjQuery, // Support: IE<9 // For `typeof node.method` instead of `node.method !== undefined` core_strundefined = typeof undefined, // Use the correct document accordingly with window argument (sandbox) document = window.document, location = window.location, // Map over jQuery in case of overwrite _jQuery = window.jQuery, // Map over the $ in case of overwrite _$ = window.$, // [[Class]] -> type pairs class2type = {}, // List of deleted data cache ids, so we can reuse them core_deletedIds = [], core_version = "1.9.1", // Save a reference to some core methods core_concat = core_deletedIds.concat, core_push = core_deletedIds.push, core_slice = core_deletedIds.slice, core_indexOf = core_deletedIds.indexOf, core_toString = class2type.toString, core_hasOwn = class2type.hasOwnProperty, core_trim = core_version.trim, // Define a local copy of jQuery jQuery = function( selector, context ) { // The jQuery object is actually just the init constructor 'enhanced' return new jQuery.fn.init( selector, context, rootjQuery ); }, // Used for matching numbers core_pnum = /[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source, // Used for splitting on whitespace core_rnotwhite = /\S+/g, // Make sure we trim BOM and NBSP (here's looking at you, Safari 5.0 and IE) rtrim = /^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, // 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 = /^(?:(<[\w\W]+>)[^>]*|#([\w-]*))$/, // Match a standalone tag rsingleTag = /^<(\w+)\s*\/?>(?:<\/\1>|)$/, // JSON RegExp rvalidchars = /^[\],:{}\s]*$/, rvalidbraces = /(?:^|:|,)(?:\s*\[)+/g, rvalidescape = /\\(?:["\\\/bfnrt]|u[\da-fA-F]{4})/g, rvalidtokens = /"[^"\\\r\n]*"|true|false|null|-?(?:\d+\.|)\d+(?:[eE][+-]?\d+|)/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(); }, // The ready event handler completed = function( event ) { // 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(); } }, // Clean-up method for dom ready events detach = function() { if ( document.addEventListener ) { document.removeEventListener( "DOMContentLoaded", completed, false ); window.removeEventListener( "load", completed, false ); } else { document.detachEvent( "onreadystatechange", completed ); window.detachEvent( "onload", completed ); } }; jQuery.fn = jQuery.prototype = { // The current version of jQuery being used jquery: core_version, constructor: jQuery, init: function( selector, context, rootjQuery ) { 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 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 rootjQuery.ready( selector ); } if ( selector.selector !== undefined ) { this.selector = selector.selector; this.context = selector.context; } return jQuery.makeArray( selector, this ); }, // Start with an empty selector selector: "", // The default length of a jQuery object is 0 length: 0, // The number of elements contained in the matched element set size: function() { return this.length; }, toArray: function() { return core_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 a 'clean' array this.toArray() : // Return just the object ( num < 0 ? this[ this.length + num ] : this[ num ] ); }, // 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 ); }, ready: function( fn ) { // Add the callback jQuery.ready.promise().done( fn ); return this; }, slice: function() { return this.pushStack( core_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] ] : [] ); }, map: function( callback ) { return this.pushStack( jQuery.map(this, function( elem, i ) { return callback.call( elem, i, elem ); })); }, end: function() { return this.prevObject || this.constructor(null); }, // For internal use only. // Behaves like an Array's method, not like a jQuery method. push: core_push, sort: [].sort, splice: [].splice }; // Give the init function the jQuery prototype for later instantiation jQuery.fn.init.prototype = jQuery.fn; 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; target = arguments[1] || {}; // skip the boolean and the target i = 2; } // 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 ( length === i ) { 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({ noConflict: function( deep ) { if ( window.$ === jQuery ) { window.$ = _$; } if ( deep && window.jQuery === jQuery ) { window.jQuery = _jQuery; } return jQuery; }, // 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.trigger ) { jQuery( document ).trigger("ready").off("ready"); } }, // 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 ) { return obj != null && obj == obj.window; }, isNumeric: function( obj ) { return !isNaN( parseFloat(obj) ) && isFinite( obj ); }, type: function( obj ) { if ( obj == null ) { return String( obj ); } return typeof obj === "object" || typeof obj === "function" ? class2type[ core_toString.call(obj) ] || "object" : typeof obj; }, isPlainObject: function( obj ) { // 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 && !core_hasOwn.call(obj, "constructor") && !core_hasOwn.call(obj.constructor.prototype, "isPrototypeOf") ) { return false; } } catch ( e ) { // IE8,9 Will throw exceptions on certain host objects #9897 return false; } // Own properties are enumerated firstly, so to speed up, // if last one is own, then all properties are own. var key; for ( key in obj ) {} return key === undefined || core_hasOwn.call( obj, key ); }, isEmptyObject: function( obj ) { var name; for ( name in obj ) { return false; } return true; }, error: function( msg ) { throw new Error( msg ); }, // 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 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 ) { jQuery( scripts ).remove(); } return jQuery.merge( [], parsed.childNodes ); }, parseJSON: function( data ) { // Attempt to parse using the native JSON parser first if ( window.JSON && window.JSON.parse ) { return window.JSON.parse( data ); } if ( data === null ) { return data; } if ( typeof data === "string" ) { // Make sure leading/trailing whitespace is removed (IE can't handle it) data = jQuery.trim( data ); if ( data ) { // Make sure the incoming data is actual JSON // Logic borrowed from http://json.org/json2.js if ( rvalidchars.test( data.replace( rvalidescape, "@" ) .replace( rvalidtokens, "]" ) .replace( rvalidbraces, "")) ) { return ( new Function( "return " + data ) )(); } } } jQuery.error( "Invalid JSON: " + data ); }, // Cross-browser xml parsing 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; }, noop: function() {}, // 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; }, // Use native String.trim function wherever possible trim: core_trim && !core_trim.call("\uFEFF\xA0") ? function( text ) { return text == null ? "" : core_trim.call( text ); } : // Otherwise use our own trimming functionality 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 { core_push.call( ret, arr ); } } return ret; }, inArray: function( elem, arr, i ) { var len; if ( arr ) { if ( core_indexOf ) { return core_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 l = second.length, i = first.length, j = 0; if ( typeof l === "number" ) { for ( ; j < l; j++ ) { first[ i++ ] = second[ j ]; } } else { while ( second[j] !== undefined ) { first[ i++ ] = second[ j++ ]; } } first.length = i; return first; }, grep: function( elems, callback, inv ) { var retVal, ret = [], i = 0, length = elems.length; inv = !!inv; // Go through the array, only saving the items // that pass the validator function for ( ; i < length; i++ ) { retVal = !!callback( elems[ i ], i ); if ( inv !== retVal ) { ret.push( elems[ i ] ); } } return ret; }, // 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 if ( isArray ) { for ( ; i < length; i++ ) { value = callback( elems[ i ], i, arg ); if ( value != null ) { ret[ ret.length ] = value; } } // Go through every key on the object, } else { for ( i in elems ) { value = callback( elems[ i ], i, arg ); if ( value != null ) { ret[ ret.length ] = value; } } } // Flatten any nested arrays return core_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 = core_slice.call( arguments, 2 ); proxy = function() { return fn.apply( context || this, args.concat( core_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; }, // Multifunctional method to get and set values of a collection // The value/s can optionally be executed if it's a function 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; }, now: function() { return ( new Date() ).getTime(); } }); 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 ); }; // 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 ( jQuery.isWindow( obj ) ) { return false; } if ( obj.nodeType === 1 && length ) { return true; } return type === "array" || type !== "function" && ( length === 0 || typeof length === "number" && length > 0 && ( length - 1 ) in obj ); } // All jQuery objects should point back to these rootjQuery = jQuery(document); // 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( core_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 = []; 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 ) { args = args || []; args = [ context, args.slice ? args.slice() : args ]; if ( list && ( !fired || stack ) ) { 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 action = tuple[ 0 ], 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[ action + "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 = core_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 ? core_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(); } }); jQuery.support = (function() { var support, all, a, input, select, fragment, opt, eventName, isSupported, i, div = document.createElement("div"); // Setup div.setAttribute( "className", "t" ); div.innerHTML = " <link/><table></table><a href='/a'>a</a><input type='checkbox'/>"; // Support tests won't run in some limited or non-browser environments all = div.getElementsByTagName("*"); a = div.getElementsByTagName("a")[ 0 ]; if ( !all || !a || !all.length ) { return {}; } // First batch of tests select = document.createElement("select"); opt = select.appendChild( document.createElement("option") ); input = div.getElementsByTagName("input")[ 0 ]; a.style.cssText = "top:1px;float:left;opacity:.5"; support = { // Test setAttribute on camelCase class. If it works, we need attrFixes when doing get/setAttribute (ie6/7) getSetAttribute: div.className !== "t", // IE strips leading whitespace when .innerHTML is used leadingWhitespace: div.firstChild.nodeType === 3, // Make sure that tbody elements aren't automatically inserted // IE will insert them into empty tables tbody: !div.getElementsByTagName("tbody").length, // Make sure that link elements get serialized correctly by innerHTML // This requires a wrapper element in IE htmlSerialize: !!div.getElementsByTagName("link").length, // Get the style information from getAttribute // (IE uses .cssText instead) style: /top/.test( a.getAttribute("style") ), // Make sure that URLs aren't manipulated // (IE normalizes it by default) hrefNormalized: a.getAttribute("href") === "/a", // Make sure that element opacity exists // (IE uses filter instead) // Use a regex to work around a WebKit issue. See #5145 opacity: /^0.5/.test( a.style.opacity ), // Verify style float existence // (IE uses styleFloat instead of cssFloat) cssFloat: !!a.style.cssFloat, // Check the default checkbox/radio value ("" on WebKit; "on" elsewhere) 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) optSelected: opt.selected, // Tests for enctype support on a form (#6743) enctype: !!document.createElement("form").enctype, // Makes sure cloning an html5 element does not cause problems // Where outerHTML is undefined, this still works html5Clone: document.createElement("nav").cloneNode( true ).outerHTML !== "<:nav></:nav>", // jQuery.support.boxModel DEPRECATED in 1.8 since we don't support Quirks Mode boxModel: document.compatMode === "CSS1Compat", // Will be defined later deleteExpando: true, noCloneEvent: true, inlineBlockNeedsLayout: false, shrinkWrapBlocks: false, reliableMarginRight: true, boxSizingReliable: true, pixelPosition: false }; // Make sure checked status is properly cloned input.checked = true; support.noCloneChecked = input.cloneNode( true ).checked; // 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: IE<9 try { delete div.test; } catch( e ) { support.deleteExpando = false; } // 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"; // #11217 - WebKit loses check when the name is after the checked attribute input.setAttribute( "checked", "t" ); input.setAttribute( "name", "t" ); fragment = document.createDocumentFragment(); fragment.appendChild( input ); // Check if a disconnected checkbox will retain its checked // value of true after appended to the DOM (IE6/7) support.appendChecked = input.checked; // WebKit doesn't clone checked state correctly in fragments support.checkClone = fragment.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() if ( div.attachEvent ) { div.attachEvent( "onclick", function() { support.noCloneEvent = false; }); div.cloneNode( true ).click(); } // Support: IE<9 (lack submit/change bubble), Firefox 17+ (lack focusin event) // Beware of CSP restrictions (https://developer.mozilla.org/en/Security/CSP), test/csp.php for ( i in { submit: true, change: true, focusin: true }) { div.setAttribute( eventName = "on" + i, "t" ); support[ i + "Bubbles" ] = eventName in window || div.attributes[ eventName ].expando === false; } div.style.backgroundClip = "content-box"; div.cloneNode( true ).style.backgroundClip = ""; support.clearCloneStyle = div.style.backgroundClip === "content-box"; // Run tests that need a body at doc ready jQuery(function() { var container, marginDiv, tds, divReset = "padding:0;margin:0;border:0;display:block;box-sizing:content-box;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;", body = document.getElementsByTagName("body")[0]; if ( !body ) { // Return for frameset docs that don't have a body return; } container = document.createElement("div"); container.style.cssText = "border:0;width:0;height:0;position:absolute;top:0;left:-9999px;margin-top:1px"; body.appendChild( container ).appendChild( div ); // 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>"; tds = div.getElementsByTagName("td"); tds[ 0 ].style.cssText = "padding:0;margin:0;border:0;display:none"; isSupported = ( tds[ 0 ].offsetHeight === 0 ); tds[ 0 ].style.display = ""; tds[ 1 ].style.display = "none"; // Support: IE8 // Check if empty table cells still have offsetWidth/Height support.reliableHiddenOffsets = isSupported && ( tds[ 0 ].offsetHeight === 0 ); // Check box-sizing and margin behavior div.innerHTML = ""; div.style.cssText = "box-sizing:border-box;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;padding:1px;border:1px;display:block;width:4px;margin-top:1%;position:absolute;top:1%;"; support.boxSizing = ( div.offsetWidth === 4 ); support.doesNotIncludeMarginInBodyOffset = ( body.offsetTop !== 1 ); // Use window.getComputedStyle because jsdom on node.js will break without it. if ( window.getComputedStyle ) { support.pixelPosition = ( window.getComputedStyle( div, null ) || {} ).top !== "1%"; support.boxSizingReliable = ( window.getComputedStyle( div, null ) || { width: "4px" } ).width === "4px"; // Check if div with explicit width and no margin-right incorrectly // gets computed margin-right based on width of container. (#3333) // Fails in WebKit before Feb 2011 nightlies // WebKit Bug 13343 - getComputedStyle returns wrong value for margin-right marginDiv = div.appendChild( document.createElement("div") ); marginDiv.style.cssText = div.style.cssText = divReset; marginDiv.style.marginRight = marginDiv.style.width = "0"; div.style.width = "1px"; support.reliableMarginRight = !parseFloat( ( window.getComputedStyle( marginDiv, null ) || {} ).marginRight ); } if ( typeof div.style.zoom !== core_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.innerHTML = ""; div.style.cssText = divReset + "width:1px;padding:1px;display:inline;zoom:1"; support.inlineBlockNeedsLayout = ( div.offsetWidth === 3 ); // Support: IE6 // Check if elements with layout shrink-wrap their children div.style.display = "block"; div.innerHTML = "<div></div>"; div.firstChild.style.width = "5px"; support.shrinkWrapBlocks = ( div.offsetWidth !== 3 ); if ( support.inlineBlockNeedsLayout ) { // 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 ); // Null elements to avoid leaks in IE container = div = tds = marginDiv = null; }); // Null elements to avoid leaks in IE all = select = fragment = opt = a = input = null; return support; })(); var rbrace = /(?:\{[\s\S]*\}|\[[\s\S]*\])$/, rmultiDash = /([A-Z])/g; function internalData( elem, name, data, pvt /* Internal Use Only */ ){ if ( !jQuery.acceptData( elem ) ) { return; } var thisCache, ret, internalKey = jQuery.expando, getByName = typeof name === "string", // 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)) && getByName && data === undefined ) { 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 ) { elem[ internalKey ] = id = core_deletedIds.pop() || jQuery.guid++; } else { id = internalKey; } } if ( !cache[ id ] ) { cache[ id ] = {}; // Avoids exposing jQuery metadata on plain JS objects when the object // is serialized using JSON.stringify if ( !isNode ) { cache[ id ].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 ( getByName ) { // 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 i, l, thisCache, 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 ) ); } for ( i = 0, l = name.length; i < l; 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 : 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) } else if ( jQuery.support.deleteExpando || cache != cache.window ) { delete cache[ id ]; // When all else fails, null } else { cache[ id ] = null; } } jQuery.extend({ cache: {}, // Unique for each copy of jQuery on the page // Non-digits removed to match rinlinejQuery expando: "jQuery" + ( core_version + Math.random() ).replace( /\D/g, "" ), // The following elements throw uncatchable exceptions if you // attempt to add expando properties to them. noData: { "embed": true, // Ban all objects except for Flash (which handle expandos) "object": "clsid:D27CDB6E-AE6D-11cf-96B8-444553540000", "applet": true }, 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 ); }, // A method for determining if a DOM node can handle the data expando acceptData: function( elem ) { // Do not set data on non-element because it will not be cleared (#8335). if ( elem.nodeType && elem.nodeType !== 1 && elem.nodeType !== 9 ) { return false; } var noData = elem.nodeName && jQuery.noData[ elem.nodeName.toLowerCase() ]; // nodes accept data unless otherwise specified; rejection can be conditional return !noData || noData !== true && elem.getAttribute("classid") === noData; } }); jQuery.fn.extend({ data: function( key, value ) { var attrs, name, elem = this[0], i = 0, data = null; // Gets all values if ( key === undefined ) { if ( this.length ) { data = jQuery.data( elem ); if ( elem.nodeType === 1 && !jQuery._data( elem, "parsedAttrs" ) ) { attrs = elem.attributes; for ( ; i < attrs.length; i++ ) { name = attrs[i].name; if ( !name.indexOf( "data-" ) ) { 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 jQuery.access( this, function( value ) { if ( value === undefined ) { // Try to fetch any internally stored data first return elem ? dataAttr( elem, key, jQuery.data( elem, key ) ) : null; } this.each(function() { jQuery.data( this, key, value ); }); }, null, value, arguments.length > 1, null, true ); }, removeData: function( key ) { return this.each(function() { jQuery.removeData( this, key ); }); } }); 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; } 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--; } hooks.cur = fn; 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 ); }); }, // Based off of the plugin by Clint Helfers, with permission. // http://blindsignals.com/index.php/2009/07/jquery-delay/ 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 ); }; }); }, 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 nodeHook, boolHook, rclass = /[\t\r\n]/g, rreturn = /\r/g, rfocusable = /^(?:input|select|textarea|button|object)$/i, rclickable = /^(?:a|area)$/i, rboolean = /^(?:checked|selected|autofocus|autoplay|async|controls|defer|disabled|hidden|loop|multiple|open|readonly|required|scoped)$/i, ruseDefault = /^(?:checked|selected)$/i, getSetAttribute = jQuery.support.getSetAttribute, getSetInput = jQuery.support.input; jQuery.fn.extend({ attr: function( name, value ) { return jQuery.access( this, jQuery.attr, name, value, arguments.length > 1 ); }, removeAttr: function( name ) { return this.each(function() { jQuery.removeAttr( this, name ); }); }, prop: function( name, value ) { return jQuery.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 ) {} }); }, addClass: function( value ) { var classes, elem, cur, clazz, j, 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( core_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 + " "; } } elem.className = jQuery.trim( cur ); } } } return this; }, removeClass: function( value ) { var classes, elem, cur, clazz, j, 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( core_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 + " ", " " ); } } elem.className = value ? jQuery.trim( cur ) : ""; } } } return this; }, toggleClass: function( value, stateVal ) { var type = typeof value, isBool = typeof stateVal === "boolean"; 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 ), state = stateVal, classNames = value.match( core_rnotwhite ) || []; while ( (className = classNames[ i++ ]) ) { // check each className given, space separated list state = isBool ? state : !self.hasClass( className ); self[ state ? "addClass" : "removeClass" ]( className ); } // Toggle whole class name } else if ( type === core_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; }, val: function( value ) { var ret, hooks, 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, self = jQuery(this); if ( this.nodeType !== 1 ) { return; } if ( isFunction ) { val = value.call( this, i, self.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 ) { // attributes.value is undefined in Blackberry 4.7 but // uses .value. See #6932 var val = elem.attributes.value; return !val || val.specified ? elem.value : elem.text; } }, 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 ( jQuery.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 values = jQuery.makeArray( value ); jQuery(elem).find("option").each(function() { this.selected = jQuery.inArray( jQuery(this).val(), values ) >= 0; }); if ( !values.length ) { elem.selectedIndex = -1; } return values; } } }, attr: function( elem, name, value ) { var hooks, notxml, 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 === core_strundefined ) { return jQuery.prop( elem, name, value ); } notxml = nType !== 1 || !jQuery.isXMLDoc( elem ); // All attributes are lowercase // Grab necessary hook if one is defined if ( notxml ) { name = name.toLowerCase(); hooks = jQuery.attrHooks[ name ] || ( rboolean.test( name ) ? boolHook : nodeHook ); } if ( value !== undefined ) { if ( value === null ) { jQuery.removeAttr( elem, name ); } else if ( hooks && notxml && "set" in hooks && (ret = hooks.set( elem, value, name )) !== undefined ) { return ret; } else { elem.setAttribute( name, value + "" ); return value; } } else if ( hooks && notxml && "get" in hooks && (ret = hooks.get( elem, name )) !== null ) { return ret; } else { // In IE9+, Flash objects don't have .getAttribute (#12945) // Support: IE9+ if ( typeof elem.getAttribute !== core_strundefined ) { ret = elem.getAttribute( 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( core_rnotwhite ); if ( attrNames && elem.nodeType === 1 ) { while ( (name = attrNames[i++]) ) { propName = jQuery.propFix[ name ] || name; // Boolean attributes get special treatment (#10870) if ( rboolean.test( name ) ) { // Set corresponding property to false for boolean attributes // Also clear defaultChecked/defaultSelected (if appropriate) for IE<8 if ( !getSetAttribute && ruseDefault.test( name ) ) { elem[ jQuery.camelCase( "default-" + name ) ] = elem[ propName ] = false; } else { 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 ( !jQuery.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; } } } }, propFix: { tabindex: "tabIndex", readonly: "readOnly", "for": "htmlFor", "class": "className", maxlength: "maxLength", cellspacing: "cellSpacing", cellpadding: "cellPadding", rowspan: "rowSpan", colspan: "colSpan", usemap: "useMap", frameborder: "frameBorder", contenteditable: "contentEditable" }, 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 ) { if ( hooks && "set" in hooks && (ret = hooks.set( elem, value, name )) !== undefined ) { return ret; } else { return ( elem[ name ] = value ); } } else { if ( hooks && "get" in hooks && (ret = hooks.get( elem, name )) !== null ) { return ret; } else { return 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/ var attributeNode = elem.getAttributeNode("tabindex"); return attributeNode && attributeNode.specified ? parseInt( attributeNode.value, 10 ) : rfocusable.test( elem.nodeName ) || rclickable.test( elem.nodeName ) && elem.href ? 0 : undefined; } } } }); // Hook for boolean attributes boolHook = { get: function( elem, name ) { var // Use .prop to determine if this attribute is understood as boolean prop = jQuery.prop( elem, name ), // Fetch it accordingly attr = typeof prop === "boolean" && elem.getAttribute( name ), detail = typeof prop === "boolean" ? getSetInput && getSetAttribute ? attr != null : // oldIE fabricates an empty string for missing boolean attributes // and conflates checked/selected into attroperties ruseDefault.test( name ) ? elem[ jQuery.camelCase( "default-" + name ) ] : !!attr : // fetch an attribute node for properties not recognized as boolean elem.getAttributeNode( name ); return detail && detail.value !== false ? name.toLowerCase() : undefined; }, 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; } }; // fix oldIE value attroperty if ( !getSetInput || !getSetAttribute ) { jQuery.attrHooks.value = { get: function( elem, name ) { var ret = elem.getAttributeNode( name ); return jQuery.nodeName( elem, "input" ) ? // Ignore the value *property* by using defaultValue elem.defaultValue : ret && ret.specified ? ret.value : undefined; }, 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 = jQuery.valHooks.button = { get: function( elem, name ) { var ret = elem.getAttributeNode( name ); return ret && ( name === "id" || name === "name" || name === "coords" ? ret.value !== "" : ret.specified ) ? ret.value : undefined; }, 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) return name === "value" || value === elem.getAttribute( name ) ? value : undefined; } }; // Set contenteditable to false on removals(#10429) // Setting to empty string throws an error as an invalid value jQuery.attrHooks.contenteditable = { get: nodeHook.get, 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 ] = jQuery.extend( jQuery.attrHooks[ name ], { set: function( elem, value ) { if ( value === "" ) { elem.setAttribute( name, "auto" ); return value; } } }); }); } // Some attributes require a special call on IE // http://msdn.microsoft.com/en-us/library/ms536429%28VS.85%29.aspx if ( !jQuery.support.hrefNormalized ) { jQuery.each([ "href", "src", "width", "height" ], function( i, name ) { jQuery.attrHooks[ name ] = jQuery.extend( jQuery.attrHooks[ name ], { get: function( elem ) { var ret = elem.getAttribute( name, 2 ); return ret == null ? undefined : ret; } }); }); // 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 ); } }; }); } if ( !jQuery.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 + "" ); } }; } // Safari mis-reports the default selected property of an option // Accessing the parent's selectedIndex property fixes it if ( !jQuery.support.optSelected ) { jQuery.propHooks.selected = jQuery.extend( 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; } }); } // IE6/7 call enctype encoding if ( !jQuery.support.enctype ) { jQuery.propFix.enctype = "encoding"; } // Radios and checkboxes getter/setter if ( !jQuery.support.checkOn ) { jQuery.each([ "radio", "checkbox" ], function() { jQuery.valHooks[ this ] = { get: function( elem ) { // Handle the case where in Webkit "" is returned instead of "on" if a value isn't specified return elem.getAttribute("value") === null ? "on" : elem.value; } }; }); } jQuery.each([ "radio", "checkbox" ], function() { jQuery.valHooks[ this ] = jQuery.extend( jQuery.valHooks[ this ], { set: function( elem, value ) { if ( jQuery.isArray( value ) ) { return ( elem.checked = jQuery.inArray( jQuery(elem).val(), value ) >= 0 ); } } }); }); var rformElems = /^(?:input|select|textarea)$/i, rkeyEvent = /^key/, rmouseEvent = /^(?:mouse|contextmenu)|click/, rfocusMorph = /^(?:focusinfocus|focusoutblur)$/, rtypenamespace = /^([^.]*)(?:\.(.+)|)$/; function returnTrue() { return true; } function returnFalse() { return false; } /* * 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 !== core_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 // jQuery(...).bind("mouseover mouseout", fn); types = ( types || "" ).match( core_rnotwhite ) || [""]; t = types.length; while ( t-- ) { tmp = rtypenamespace.exec( types[t] ) || []; type = origType = tmp[1]; namespaces = ( tmp[2] || "" ).split( "." ).sort(); // 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( core_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 = core_hasOwn.call( event, "type" ) ? event.type : event, namespaces = core_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 ); event.isTrigger = true; 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 && jQuery.acceptData( cur ) && handle.apply && handle.apply( cur, data ) === 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( elem.ownerDocument, data ) === false) && !(type === "click" && jQuery.nodeName( elem, "a" )) && 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 = core_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") ) { for ( ; cur != this; cur = cur.parentNode || this ) { // 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 }, 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; } } }, focus: { // Fire native event if possible so blur/focus sequence is correct trigger: function() { if ( this !== document.activeElement && 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 === document.activeElement && this.blur ) { this.blur(); return false; } }, delegateType: "focusout" }, beforeunload: { postDispatch: function( event ) { // Even when returnValue equals to undefined Firefox will still show alert if ( event.result !== undefined ) { 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 ] === core_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.returnValue === false || src.getPreventDefault && src.getPreventDefault() ) ? 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() { this.isImmediatePropagationStopped = returnTrue; this.stopPropagation(); } }; // Create mouseenter/leave events using mouseover/out and event-time checks jQuery.each({ mouseenter: "mouseover", mouseleave: "mouseout" }, 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 ( !jQuery.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 ( !jQuery.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 ( !jQuery.support.focusinBubbles ) { jQuery.each({ focus: "focusin", blur: "focusout" }, function( orig, fix ) { // Attach a single capturing handler while someone wants focusin/focusout var attaches = 0, handler = function( event ) { jQuery.event.simulate( fix, event.target, jQuery.event.fix( event ), true ); }; jQuery.event.special[ fix ] = { setup: function() { if ( attaches++ === 0 ) { document.addEventListener( orig, handler, true ); } }, teardown: function() { if ( --attaches === 0 ) { document.removeEventListener( orig, handler, true ); } } }; }); } 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 ); }); }, 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 ); }, 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 ); } } }); /*! * Sizzle CSS Selector Engine * Copyright 2012 jQuery Foundation and other contributors * Released under the MIT license * http://sizzlejs.com/ */ (function( window, undefined ) { var i, cachedruns, Expr, getText, isXML, compile, hasDuplicate, outermostContext, // Local document vars setDocument, document, docElem, documentIsXML, rbuggyQSA, rbuggyMatches, matches, contains, sortOrder, // Instance-specific data expando = "sizzle" + -(new Date()), preferredDoc = window.document, support = {}, dirruns = 0, done = 0, classCache = createCache(), tokenCache = createCache(), compilerCache = createCache(), // General-purpose constants strundefined = typeof undefined, MAX_NEGATIVE = 1 << 31, // Array methods arr = [], pop = arr.pop, 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; }, // 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#" ), // Acceptable operators http://www.w3.org/TR/selectors/#attribute-selectors operators = "([*^$|!~]?=)", attributes = "\\[" + whitespace + "*(" + characterEncoding + ")" + whitespace + "*(?:" + operators + whitespace + "*(?:(['\"])((?:\\\\.|[^\\\\])*?)\\3|(" + identifier + ")|)|)" + whitespace + "*\\]", // Prefer arguments quoted, // then not containing pseudos/brackets, // then attribute selectors/non-parenthetical expressions, // then anything else // These preferences are here to reduce the number of selectors // needing tokenize in the PSEUDO preFilter pseudos = ":(" + characterEncoding + ")(?:\\(((['\"])((?:\\\\.|[^\\\\])*?)\\3|((?:\\\\.|[^\\\\()[\\]]|" + attributes.replace( 3, 8 ) + ")*)|.*)\\)|)", // 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 + "*([\\x20\\t\\r\\n\\f>+~])" + whitespace + "*" ), rpseudo = new RegExp( pseudos ), ridentifier = new RegExp( "^" + identifier + "$" ), matchExpr = { "ID": new RegExp( "^#(" + characterEncoding + ")" ), "CLASS": new RegExp( "^\\.(" + characterEncoding + ")" ), "NAME": new RegExp( "^\\[name=['\"]?(" + 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" ), // 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" ) }, rsibling = /[\x20\t\r\n\f]*[+~]/, rnative = /^[^{]+\{\s*\[native code/, // Easily-parseable/retrievable ID or TAG or CLASS selectors rquickExpr = /^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/, rinputs = /^(?:input|select|textarea|button)$/i, rheader = /^h\d$/i, rescape = /'|\\/g, rattributeQuotes = /\=[\x20\t\r\n\f]*([^'"\]]*)[\x20\t\r\n\f]*\]/g, // CSS escapes http://www.w3.org/TR/CSS21/syndata.html#escaped-characters runescape = /\\([\da-fA-F]{1,6}[\x20\t\r\n\f]?|.)/g, funescape = function( _, escaped ) { var high = "0x" + escaped - 0x10000; // NaN means non-codepoint return high !== high ? escaped : // BMP codepoint high < 0 ? String.fromCharCode( high + 0x10000 ) : // Supplemental Plane codepoint (surrogate pair) String.fromCharCode( high >> 10 | 0xD800, high & 0x3FF | 0xDC00 ); }; // Use a stripped-down slice if we can't use a native one try { slice.call( preferredDoc.documentElement.childNodes, 0 )[0].nodeType; } catch ( e ) { slice = function( i ) { var elem, results = []; while ( (elem = this[i++]) ) { results.push( elem ); } return results; }; } /** * For feature detection * @param {Function} fn The function to test for native support */ function isNative( fn ) { return rnative.test( fn + "" ); } /** * 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 cache, keys = []; return (cache = function( 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); }); } /** * 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 { // release memory in IE div = null; } } 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 ( !documentIsXML && !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 #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, slice.call(context.getElementsByTagName( selector ), 0) ); return results; // Speed-up: Sizzle(".CLASS") } else if ( (m = match[3]) && support.getByClassName && context.getElementsByClassName ) { push.apply( results, slice.call(context.getElementsByClassName( m ), 0) ); return results; } } // QSA path if ( support.qsa && !rbuggyQSA.test(selector) ) { old = true; nid = 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 ) && context.parentNode || context; newSelector = groups.join(","); } if ( newSelector ) { try { push.apply( results, slice.call( newContext.querySelectorAll( newSelector ), 0 ) ); return results; } catch(qsaError) { } finally { if ( !old ) { context.removeAttribute("id"); } } } } } // All others return select( selector.replace( rtrim, "$1" ), context, results, seed ); } /** * Detect xml * @param {Element|Object} elem An element or a document */ 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 doc = node ? node.ownerDocument || node : preferredDoc; // 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 documentIsXML = isXML( doc ); // Check if getElementsByTagName("*") returns only elements support.tagNameNoComments = assert(function( div ) { div.appendChild( doc.createComment("") ); return !div.getElementsByTagName("*").length; }); // Check if attributes should be retrieved by attribute nodes support.attributes = assert(function( div ) { div.innerHTML = "<select></select>"; var type = typeof div.lastChild.getAttribute("multiple"); // IE8 returns a string for some attributes even when not present return type !== "boolean" && type !== "string"; }); // Check if getElementsByClassName can be trusted support.getByClassName = assert(function( div ) { // Opera can't find a second classname (in 9.6) div.innerHTML = "<div class='hidden e'></div><div class='hidden'></div>"; if ( !div.getElementsByClassName || !div.getElementsByClassName("e").length ) { return false; } // Safari 3.2 caches class attributes and doesn't catch changes div.lastChild.className = "e"; return div.getElementsByClassName("e").length === 2; }); // Check if getElementById returns elements by name // Check if getElementsByName privileges form controls or returns elements by ID support.getByName = assert(function( div ) { // Inject content div.id = expando + 0; div.innerHTML = "<a name='" + expando + "'></a><div name='" + expando + "'></div>"; docElem.insertBefore( div, docElem.firstChild ); // Test var pass = doc.getElementsByName && // buggy browsers will return fewer than the correct 2 doc.getElementsByName( expando ).length === 2 + // buggy browsers will return more than the correct 0 doc.getElementsByName( expando + 0 ).length; support.getIdNotName = !doc.getElementById( expando ); // Cleanup docElem.removeChild( div ); return pass; }); // IE6/7 return modified attributes Expr.attrHandle = assert(function( div ) { div.innerHTML = "<a href='#'></a>"; return div.firstChild && typeof div.firstChild.getAttribute !== strundefined && div.firstChild.getAttribute("href") === "#"; }) ? {} : { "href": function( elem ) { return elem.getAttribute( "href", 2 ); }, "type": function( elem ) { return elem.getAttribute("type"); } }; // ID find and filter if ( support.getIdNotName ) { Expr.find["ID"] = function( id, context ) { if ( typeof context.getElementById !== strundefined && !documentIsXML ) { 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 { Expr.find["ID"] = function( id, context ) { if ( typeof context.getElementById !== strundefined && !documentIsXML ) { var m = context.getElementById( id ); return m ? m.id === id || typeof m.getAttributeNode !== strundefined && m.getAttributeNode("id").value === id ? [m] : undefined : []; } }; 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.tagNameNoComments ? 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; }; // Name Expr.find["NAME"] = support.getByName && function( tag, context ) { if ( typeof context.getElementsByName !== strundefined ) { return context.getElementsByName( name ); } }; // Class Expr.find["CLASS"] = support.getByClassName && function( className, context ) { if ( typeof context.getElementsByClassName !== strundefined && !documentIsXML ) { return context.getElementsByClassName( className ); } }; // QSA and matchesSelector support // matchesSelector(:active) reports false when true (IE9/Opera 11.5) rbuggyMatches = []; // qSa(:focus) reports false when true (Chrome 21), // no need to also add to buggyMatches since matches checks buggyQSA // A support test would require too much code (would include document ready) rbuggyQSA = [ ":focus" ]; if ( (support.qsa = isNative(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 explictly // setting a boolean content attribute, // since its presence should be enough // http://bugs.jquery.com/ticket/12359 div.innerHTML = "<select><option selected=''></option></select>"; // IE8 - Some boolean attributes are not treated correctly if ( !div.querySelectorAll("[selected]").length ) { rbuggyQSA.push( "\\[" + whitespace + "*(?:checked|disabled|ismap|multiple|readonly|selected|value)" ); } // 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 ) { // Opera 10-12/IE8 - ^= $= *= and empty values // Should not select anything div.innerHTML = "<input type='hidden' i=''/>"; if ( div.querySelectorAll("[i^='']").length ) { rbuggyQSA.push( "[*^$]=" + 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 = isNative( (matches = docElem.matchesSelector || docElem.mozMatchesSelector || docElem.webkitMatchesSelector || 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 = new RegExp( rbuggyQSA.join("|") ); rbuggyMatches = new RegExp( rbuggyMatches.join("|") ); // Element contains another // Purposefully does not implement inclusive descendent // As in, an element does not contain itself contains = isNative(docElem.contains) || docElem.compareDocumentPosition ? 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; }; // Document order sorting sortOrder = docElem.compareDocumentPosition ? function( a, b ) { var compare; if ( a === b ) { hasDuplicate = true; return 0; } if ( (compare = b.compareDocumentPosition && a.compareDocumentPosition && a.compareDocumentPosition( b )) ) { if ( compare & 1 || a.parentNode && a.parentNode.nodeType === 11 ) { if ( a === doc || contains( preferredDoc, a ) ) { return -1; } if ( b === doc || contains( preferredDoc, b ) ) { return 1; } return 0; } return compare & 4 ? -1 : 1; } return a.compareDocumentPosition ? -1 : 1; } : function( a, b ) { var cur, i = 0, aup = a.parentNode, bup = b.parentNode, ap = [ a ], bp = [ b ]; // Exit early if the nodes are identical if ( a === b ) { hasDuplicate = true; return 0; // Parentless nodes are either documents or disconnected } else if ( !aup || !bup ) { return a === doc ? -1 : b === doc ? 1 : aup ? -1 : bup ? 1 : 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; }; // Always assume the presence of duplicates if sort doesn't // pass them to our comparison function (as in Google Chrome). hasDuplicate = false; [0, 0].sort( sortOrder ); support.detectDuplicates = hasDuplicate; return document; }; 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']" ); // rbuggyQSA always contains :focus, so no need for an existence check if ( support.matchesSelector && !documentIsXML && (!rbuggyMatches || !rbuggyMatches.test(expr)) && !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 ) { var val; // Set document vars if needed if ( ( elem.ownerDocument || elem ) !== document ) { setDocument( elem ); } if ( !documentIsXML ) { name = name.toLowerCase(); } if ( (val = Expr.attrHandle[ name ]) ) { return val( elem ); } if ( documentIsXML || support.attributes ) { return elem.getAttribute( name ); } return ( (val = elem.getAttributeNode( name )) || elem.getAttribute( name ) ) && elem[ name ] === true ? name : val && val.specified ? val.value : null; }; Sizzle.error = function( msg ) { throw new Error( "Syntax error, unrecognized expression: " + msg ); }; // Document sorting and removing duplicates Sizzle.uniqueSort = function( results ) { var elem, duplicates = [], i = 1, j = 0; // Unless we *know* we can detect duplicates, assume their presence hasDuplicate = !support.detectDuplicates; results.sort( sortOrder ); if ( hasDuplicate ) { for ( ; (elem = results[i]); i++ ) { if ( elem === results[ i - 1 ] ) { j = duplicates.push( i ); } } while ( j-- ) { results.splice( duplicates[ j ], 1 ); } } return results; }; function siblingCheck( a, b ) { var cur = b && a, diff = cur && ( ~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 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 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 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]); } } }); }); } /** * 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 for ( ; (node = elem[i]); 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 (see #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, 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[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[5] && match[2]; if ( matchExpr["CHILD"].test( match[0] ) ) { return null; } // Accept quoted arguments as-is if ( match[4] ) { match[2] = match[4]; // 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( nodeName ) { if ( nodeName === "*" ) { return function() { return true; }; } nodeName = nodeName.replace( runescape, funescape ).toLowerCase(); return 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( 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 identifider if ( !ridentifier.test(lang || "") ) { Sizzle.error( "unsupported lang: " + lang ); } lang = lang.replace( runescape, funescape ).toLowerCase(); return function( elem ) { var elemLang; do { if ( (elemLang = documentIsXML ? elem.getAttribute("xml:lang") || elem.getAttribute("lang") : elem.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 only affected by element nodes and content nodes(including text(3), cdata(4)), // not comment, processing instructions, or others // Thanks to Diego Perini for the nodeName shortcut // Greater than "@" means alpha characters (specifically not starting with "#" or "?") for ( elem = elem.firstChild; elem; elem = elem.nextSibling ) { if ( elem.nodeName > "@" || elem.nodeType === 3 || elem.nodeType === 4 ) { 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; // IE6 and 7 will map elem.type to 'text' for new HTML5 types (search, etc) // use getAttribute instead to test this case return elem.nodeName.toLowerCase() === "input" && elem.type === "text" && ( (attr = elem.getAttribute("type")) == null || attr.toLowerCase() === elem.type ); }, // 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; }) } }; // 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 ); } function tokenize( 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 data, cache, outerCache, dirkey = 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 ( (cache = outerCache[ dir ]) && cache[0] === dirkey ) { if ( (data = cache[1]) === true || data === cachedruns ) { return data === true; } } else { cache = outerCache[ dir ] = [ dirkey ]; cache[1] = matcher( elem, context, xml ) || cachedruns; if ( cache[1] === true ) { 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 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( tokens.slice( 0, i - 1 ) ).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 ) { // A counter to specify which element is currently being matched var matcherCachedRuns = 0, bySet = setMatchers.length > 0, byElement = elementMatchers.length > 0, superMatcher = function( seed, context, xml, results, expandContext ) { var elem, j, matcher, setMatched = [], matchedCount = 0, i = "0", unmatched = seed && [], outermost = expandContext != null, contextBackup = outermostContext, // We must always have either seed elements or context elems = seed || byElement && Expr.find["TAG"]( "*", expandContext && context.parentNode || context ), // Use integer dirruns iff this is the outermost matcher dirrunsUnique = (dirruns += contextBackup == null ? 1 : Math.random() || 0.1); if ( outermost ) { outermostContext = context !== document && context; cachedruns = matcherCachedRuns; } // Add elements passing elementMatchers directly to results // Keep `i` a string if there are no elements so `matchedCount` will be "00" below for ( ; (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; cachedruns = ++matcherCachedRuns; } } // 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, group /* 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 ( !group ) { group = tokenize( selector ); } i = group.length; while ( i-- ) { cached = matcherFromTokens( group[i] ); if ( cached[ expando ] ) { setMatchers.push( cached ); } else { elementMatchers.push( cached ); } } // Cache the compiled function cached = compilerCache( selector, matcherFromGroupMatchers( elementMatchers, setMatchers ) ); } return cached; }; function multipleContexts( selector, contexts, results ) { var i = 0, len = contexts.length; for ( ; i < len; i++ ) { Sizzle( selector, contexts[i], results ); } return results; } function select( selector, context, results, seed ) { var i, tokens, token, type, find, match = tokenize( selector ); if ( !seed ) { // Try to minimize operations if there is 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" && context.nodeType === 9 && !documentIsXML && Expr.relative[ tokens[1].type ] ) { context = Expr.find["ID"]( token.matches[0].replace( runescape, funescape ), context )[0]; if ( !context ) { return results; } 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 ) && 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, slice.call( seed, 0 ) ); return results; } break; } } } } } // Compile and execute a filtering function // Provide `match` to avoid retokenization if we modified the selector above compile( selector, match )( seed, context, documentIsXML, results, rsibling.test( selector ) ); return results; } // Deprecated Expr.pseudos["nth"] = Expr.pseudos["eq"]; // Easy API for creating new setFilters function setFilters() {} Expr.filters = setFilters.prototype = Expr.pseudos; Expr.setFilters = new setFilters(); // Initialize with the default document setDocument(); // Override sizzle attribute retrieval Sizzle.attr = jQuery.attr; 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; })( window ); var runtil = /Until$/, rparentsprev = /^(?:parents|prev(?:Until|All))/, isSimple = /^.[^:#\[\.,]*$/, rneedsContext = jQuery.expr.match.needsContext, // methods guaranteed to produce a unique set when starting from a unique set guaranteedUnique = { children: true, contents: true, next: true, prev: true }; jQuery.fn.extend({ find: function( selector ) { var i, ret, self, len = this.length; if ( typeof selector !== "string" ) { self = this; return this.pushStack( jQuery( selector ).filter(function() { for ( i = 0; i < len; i++ ) { if ( jQuery.contains( self[ i ], this ) ) { return true; } } }) ); } ret = []; for ( i = 0; i < len; i++ ) { jQuery.find( selector, this[ 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; return ret; }, 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; } } }); }, not: function( selector ) { return this.pushStack( winnow(this, selector, false) ); }, filter: function( selector ) { return this.pushStack( winnow(this, selector, true) ); }, is: function( selector ) { return !!selector && ( typeof selector === "string" ? // 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". rneedsContext.test( selector ) ? jQuery( selector, this.context ).index( this[0] ) >= 0 : jQuery.filter( selector, this ).length > 0 : this.filter( selector ).length > 0 ); }, closest: function( selectors, context ) { var cur, i = 0, l = this.length, ret = [], pos = rneedsContext.test( selectors ) || typeof selectors !== "string" ? jQuery( selectors, context || this.context ) : 0; for ( ; i < l; i++ ) { cur = this[i]; while ( cur && cur.ownerDocument && cur !== context && cur.nodeType !== 11 ) { if ( pos ? pos.index(cur) > -1 : jQuery.find.matchesSelector(cur, selectors) ) { ret.push( cur ); break; } cur = cur.parentNode; } } return this.pushStack( ret.length > 1 ? jQuery.unique( ret ) : ret ); }, // 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 ) { var set = typeof selector === "string" ? jQuery( selector, context ) : jQuery.makeArray( selector && selector.nodeType ? [ selector ] : selector ), all = jQuery.merge( this.get(), set ); return this.pushStack( jQuery.unique(all) ); }, addBack: function( selector ) { return this.add( selector == null ? this.prevObject : this.prevObject.filter(selector) ); } }); jQuery.fn.andSelf = jQuery.fn.addBack; 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 ( !runtil.test( name ) ) { selector = until; } if ( selector && typeof selector === "string" ) { ret = jQuery.filter( selector, ret ); } ret = this.length > 1 && !guaranteedUnique[ name ] ? jQuery.unique( ret ) : ret; if ( this.length > 1 && rparentsprev.test( name ) ) { ret = ret.reverse(); } return this.pushStack( ret ); }; }); jQuery.extend({ filter: function( expr, elems, not ) { if ( not ) { expr = ":not(" + expr + ")"; } return elems.length === 1 ? jQuery.find.matchesSelector(elems[0], expr) ? [ elems[0] ] : [] : jQuery.find.matches(expr, elems); }, 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; } }); // Implement the identical functionality for filter and not function winnow( elements, qualifier, keep ) { // Can't pass null or undefined to indexOf in Firefox 4 // Set to 0 to skip string check qualifier = qualifier || 0; if ( jQuery.isFunction( qualifier ) ) { return jQuery.grep(elements, function( elem, i ) { var retVal = !!qualifier.call( elem, i, elem ); return retVal === keep; }); } else if ( qualifier.nodeType ) { return jQuery.grep(elements, function( elem ) { return ( elem === qualifier ) === keep; }); } else if ( typeof qualifier === "string" ) { var filtered = jQuery.grep(elements, function( elem ) { return elem.nodeType === 1; }); if ( isSimple.test( qualifier ) ) { return jQuery.filter(qualifier, filtered, !keep); } else { qualifier = jQuery.filter( qualifier, filtered ); } } return jQuery.grep(elements, function( elem ) { return ( jQuery.inArray( elem, qualifier ) >= 0 ) === keep; }); } 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, manipulation_rcheckableType = /^(?:checkbox|radio)$/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: jQuery.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; jQuery.fn.extend({ text: function( value ) { return jQuery.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 ); }, 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(); }, append: function() { return this.domManip(arguments, true, function( elem ) { if ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) { this.appendChild( elem ); } }); }, prepend: function() { return this.domManip(arguments, true, function( elem ) { if ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) { this.insertBefore( elem, this.firstChild ); } }); }, before: function() { return this.domManip( arguments, false, function( elem ) { if ( this.parentNode ) { this.parentNode.insertBefore( elem, this ); } }); }, after: function() { return this.domManip( arguments, false, function( elem ) { if ( this.parentNode ) { this.parentNode.insertBefore( elem, this.nextSibling ); } }); }, // keepData is for internal use only--do not document remove: function( selector, keepData ) { var elem, i = 0; for ( ; (elem = this[i]) != null; i++ ) { if ( !selector || jQuery.filter( selector, [ elem ] ).length > 0 ) { 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 jQuery.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 ) && ( jQuery.support.htmlSerialize || !rnoshimcache.test( value ) ) && ( jQuery.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( value ) { var isFunc = jQuery.isFunction( value ); // Make sure that the elements are removed from the DOM before they are inserted // this can help fix replacing a parent with child elements if ( !isFunc && typeof value !== "string" ) { value = jQuery( value ).not( this ).detach(); } return this.domManip( [ value ], true, function( elem ) { var next = this.nextSibling, parent = this.parentNode; if ( parent ) { jQuery( this ).remove(); parent.insertBefore( elem, next ); } }); }, detach: function( selector ) { return this.remove( selector, true ); }, domManip: function( args, table, callback ) { // Flatten any nested arrays args = core_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" || jQuery.support.checkClone || !rchecked.test( value ) ) ) { return this.each(function( index ) { var self = set.eq( index ); if ( isFunction ) { args[0] = value.call( this, index, table ? self.html() : undefined ); } self.domManip( args, table, callback ); }); } if ( l ) { fragment = jQuery.buildFragment( args, this[ 0 ].ownerDocument, false, this ); first = fragment.firstChild; if ( fragment.childNodes.length === 1 ) { fragment = first; } if ( first ) { table = table && jQuery.nodeName( first, "tr" ); 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( table && jQuery.nodeName( this[i], "table" ) ? findOrAppend( this[i], "tbody" ) : 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 ) { // Hope ajax is available... jQuery.ajax({ url: node.src, type: "GET", dataType: "script", async: false, global: false, "throws": true }); } else { jQuery.globalEval( ( node.text || node.textContent || node.innerHTML || "" ).replace( rcleanScript, "" ) ); } } } } // Fix #11809: Avoid leaking memory fragment = first = null; } } return this; } }); function findOrAppend( elem, tag ) { return elem.getElementsByTagName( tag )[0] || elem.appendChild( elem.ownerDocument.createElement( tag ) ); } // Replace/restore the type attribute of script elements for safe DOM manipulation function disableScript( elem ) { var attr = elem.getAttributeNode("type"); elem.type = ( attr && attr.specified ) + "/" + 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 ( !jQuery.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 ( jQuery.support.html5Clone && ( src.innerHTML && !jQuery.trim(dest.innerHTML) ) ) { dest.innerHTML = src.innerHTML; } } else if ( nodeName === "input" && manipulation_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.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() core_push.apply( ret, elems.get() ); } return this.pushStack( ret ); }; }); function getAll( context, tag ) { var elems, elem, i = 0, found = typeof context.getElementsByTagName !== core_strundefined ? context.getElementsByTagName( tag || "*" ) : typeof context.querySelectorAll !== core_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 ( manipulation_rcheckableType.test( elem.type ) ) { elem.defaultChecked = elem.checked; } } jQuery.extend({ clone: function( elem, dataAndEvents, deepDataAndEvents ) { var destElements, node, clone, i, srcElements, inPage = jQuery.contains( elem.ownerDocument, elem ); if ( jQuery.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 ( (!jQuery.support.noCloneEvent || !jQuery.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 ( !jQuery.support.leadingWhitespace && rleadingWhitespace.test( elem ) ) { nodes.push( context.createTextNode( rleadingWhitespace.exec( elem )[0] ) ); } // Remove IE's autoinserted <tbody> from table fragments if ( !jQuery.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 ( !jQuery.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 = jQuery.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 !== core_strundefined ) { elem.removeAttribute( internalKey ); } else { elem[ internalKey ] = null; } core_deletedIds.push( id ); } } } } } }); var iframe, getStyles, curCSS, ralpha = /alpha\([^)]*\)/i, ropacity = /opacity\s*=\s*([^)]*)/, rposition = /^(top|right|bottom|left)$/, // 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]).+)/, rmargin = /^margin/, rnumsplit = new RegExp( "^(" + core_pnum + ")(.*)$", "i" ), rnumnonpx = new RegExp( "^(" + core_pnum + ")(?!px)[a-z%]+$", "i" ), rrelNum = new RegExp( "^([+-])=(" + core_pnum + ")", "i" ), elemdisplay = { BODY: "block" }, cssShow = { position: "absolute", visibility: "hidden", display: "block" }, cssNormalTransform = { letterSpacing: 0, fontWeight: 400 }, cssExpand = [ "Top", "Right", "Bottom", "Left" ], 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 isHidden( 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 ); } 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", css_defaultDisplay(elem.nodeName) ); } } else { if ( !values[ index ] ) { 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; } jQuery.fn.extend({ css: function( name, value ) { return jQuery.access( this, function( elem, name, value ) { var len, styles, 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 ) { var bool = typeof state === "boolean"; return this.each(function() { if ( bool ? state : isHidden( this ) ) { jQuery( this ).show(); } else { jQuery( this ).hide(); } }); } }); 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; } } } }, // Exclude the following css properties to add px cssNumber: { "columnCount": true, "fillOpacity": true, "fontWeight": true, "lineHeight": true, "opacity": 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": jQuery.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 NaN and null values aren't set. See: #7116 if ( value == null || type === "number" && isNaN( 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 ( !jQuery.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 ) { // Wrapped to prevent IE from throwing errors when 'invalid' values are provided // Fixes bug #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; }, // A method for quickly swapping in/out CSS properties to get correct calculations 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; } }); // NOTE: we've included the "window" in window.getComputedStyle // because jsdom on node.js will break without it. if ( window.getComputedStyle ) { getStyles = function( elem ) { return window.getComputedStyle( elem, null ); }; curCSS = function( elem, name, _computed ) { var width, minWidth, maxWidth, computed = _computed || getStyles( elem ), // getPropertyValue is only needed for .css('filter') in IE9, see #12537 ret = computed ? computed.getPropertyValue( name ) || computed[ name ] : undefined, style = elem.style; 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; } } return ret; }; } else if ( document.documentElement.currentStyle ) { getStyles = function( elem ) { return elem.currentStyle; }; curCSS = function( elem, name, _computed ) { var left, rs, rsLeft, computed = _computed || getStyles( elem ), ret = computed ? computed[ name ] : undefined, style = elem.style; // 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; } } return ret === "" ? "auto" : ret; }; } 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 = jQuery.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 && ( jQuery.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"; } // Try to determine the default display value of an element function css_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'/>") .css( "cssText", "display:block !important" ) ).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; doc.write("<!doctype html><html><body>"); doc.close(); display = actualDisplay( nodeName, doc ); iframe.detach(); } // Store the correct default display elemdisplay[ nodeName ] = display; } return display; } // Called ONLY from within css_defaultDisplay function actualDisplay( name, doc ) { var elem = jQuery( doc.createElement( name ) ).appendTo( doc.body ), display = jQuery.css( elem[0], "display" ); elem.remove(); return display; } 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 elem.offsetWidth === 0 && rdisplayswap.test( jQuery.css( elem, "display" ) ) ? 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, jQuery.support.boxSizing && jQuery.css( elem, "boxSizing", false, styles ) === "border-box", styles ) : 0 ); } }; }); if ( !jQuery.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; } }; } // These hooks cannot be added until DOM ready because the support test // for it is not run until after DOM ready jQuery(function() { if ( !jQuery.support.reliableMarginRight ) { jQuery.cssHooks.marginRight = { get: 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" ] ); } } }; } // 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 if ( !jQuery.support.pixelPosition && jQuery.fn.position ) { jQuery.each( [ "top", "left" ], function( i, prop ) { jQuery.cssHooks[ prop ] = { get: 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; } } }; }); } }); if ( jQuery.expr && jQuery.expr.filters ) { 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 || (!jQuery.support.reliableHiddenOffsets && ((elem.style && elem.style.display) || jQuery.css( elem, "display" )) === "none"); }; jQuery.expr.filters.visible = function( elem ) { return !jQuery.expr.filters.hidden( elem ); }; } // 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; } }); var r20 = /%20/g, rbracket = /\[\]$/, rCRLF = /\r?\n/g, rsubmitterTypes = /^(?:submit|button|image|reset|file)$/i, rsubmittable = /^(?:input|select|textarea|keygen)/i; 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 || !manipulation_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(); } }); //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, "+" ); }; 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 ); } } 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.hover = function( fnOver, fnOut ) { return this.mouseenter( fnOver ).mouseleave( fnOut || fnOver ); }; var // Document location ajaxLocParts, ajaxLocation, ajax_nonce = jQuery.now(), ajax_rquery = /\?/, 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+)|)|)/, // Keep a copy of the old load method _load = jQuery.fn.load, /* 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( core_rnotwhite ) || []; if ( jQuery.isFunction( func ) ) { // For each dataType in the dataTypeExpression while ( (dataType = dataTypes[i++]) ) { // Prepend if requested if ( dataType[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; } 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 = 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; }; // 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.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 }); }; }); 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" }, // Data converters // Keys separate source (or catchall "*") and destination types with a single space converters: { // Convert anything to text "* text": window.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( core_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 += ( ajax_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_=" + ajax_nonce++ ) : // Otherwise add one to the end cacheURL + ( ajax_rquery.test( cacheURL ) ? "&" : "?" ) + "_=" + ajax_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; // Get response data if ( responses ) { response = ajaxHandleResponses( s, jqXHR, responses ); } // If successful, handle type chaining if ( status >= 200 && status < 300 || status === 304 ) { // 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 ) { isSuccess = true; statusText = "nocontent"; // if not modified } else if ( status === 304 ) { isSuccess = true; statusText = "notmodified"; // If we have data, let's convert it } else { isSuccess = ajaxConvert( s, response ); statusText = isSuccess.state; success = isSuccess.data; error = isSuccess.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; }, getScript: function( url, callback ) { return jQuery.get( url, undefined, callback, "script" ); }, getJSON: function( url, data, callback ) { return jQuery.get( url, data, callback, "json" ); } }); /* Handles responses to an ajax request: * - sets all responseXXX fields accordingly * - 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, responseFields = s.responseFields; // Fill responseXXX fields for ( type in responseFields ) { if ( type in responses ) { jqXHR[ responseFields[type] ] = responses[ type ]; } } // 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 function ajaxConvert( s, response ) { var conv2, current, conv, tmp, converters = {}, i = 0, // Work with a copy of dataTypes in case we need to modify it for conversion dataTypes = s.dataTypes.slice(), prev = dataTypes[ 0 ]; // Apply the dataFilter if provided if ( s.dataFilter ) { response = s.dataFilter( response, s.dataType ); } // Create converters map with lowercased keys if ( dataTypes[ 1 ] ) { for ( conv in s.converters ) { converters[ conv.toLowerCase() ] = s.converters[ conv ]; } } // Convert to each sequential dataType, tolerating list modification for ( ; (current = dataTypes[++i]); ) { // There's only work to do if current dataType is non-auto if ( current !== "*" ) { // Convert response if prev dataType is non-auto and differs from current 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.splice( i--, 0, current ); } 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 }; } } } } // Update prev for next iteration prev = current; } } return { state: "success", data: response }; } // 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 + "_" + ( ajax_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 += ( ajax_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"; } }); var xhrCallbacks, xhrSupported, xhrId = 0, // #5280: Internet Explorer will keep connections alive if we don't abort on unload xhrOnUnloadAbort = window.ActiveXObject && function() { // Abort all pending requests var key; for ( key in xhrCallbacks ) { xhrCallbacks[ key ]( 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 ) {} } // Create the request object // (This is still attached to ajaxSettings for backward compatibility) jQuery.ajaxSettings.xhr = window.ActiveXObject ? /* Microsoft failed to properly * implement the XMLHttpRequest in IE7 (can't request local files), * so we use the ActiveXObject when it is available * Additionally XMLHttpRequest can be disabled in IE7/IE8 so * we need a fallback. */ function() { return !this.isLocal && createStandardXHR() || createActiveXHR(); } : // For all other browsers, use the standard XMLHttpRequest object createStandardXHR; // Determine support properties xhrSupported = jQuery.ajaxSettings.xhr(); jQuery.support.cors = !!xhrSupported && ( "withCredentials" in xhrSupported ); xhrSupported = jQuery.support.ajax = !!xhrSupported; // Create transport if the browser can provide an xhr if ( xhrSupported ) { jQuery.ajaxTransport(function( s ) { // Cross domain only allowed if supported through XMLHttpRequest if ( !s.crossDomain || jQuery.support.cors ) { var callback; return { send: function( headers, complete ) { // Get a new xhr var handle, i, xhr = s.xhr(); // Open the socket // Passing null username, generates a login popup on Opera (#2865) if ( s.username ) { xhr.open( s.type, s.url, s.async, s.username, s.password ); } else { xhr.open( s.type, s.url, s.async ); } // Apply custom fields if provided if ( s.xhrFields ) { for ( i in s.xhrFields ) { xhr[ i ] = s.xhrFields[ i ]; } } // Override mime type if needed if ( s.mimeType && xhr.overrideMimeType ) { xhr.overrideMimeType( s.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 ( !s.crossDomain && !headers["X-Requested-With"] ) { headers["X-Requested-With"] = "XMLHttpRequest"; } // Need an extra try/catch for cross domain requests in Firefox 3 try { for ( i in headers ) { xhr.setRequestHeader( i, headers[ i ] ); } } catch( err ) {} // Do send the request // This may raise an exception which is actually // handled in jQuery.ajax (so no try/catch here) xhr.send( ( s.hasContent && s.data ) || null ); // Listener callback = function( _, isAbort ) { var status, responseHeaders, statusText, responses; // Firefox throws exceptions when accessing properties // of an xhr when a network error occurred // http://helpful.knobs-dials.com/index.php/Component_returned_failure_code:_0x80040111_(NS_ERROR_NOT_AVAILABLE) try { // Was never called and is aborted or complete if ( callback && ( isAbort || xhr.readyState === 4 ) ) { // Only called once callback = undefined; // Do not keep as active anymore if ( handle ) { xhr.onreadystatechange = jQuery.noop; if ( xhrOnUnloadAbort ) { delete xhrCallbacks[ handle ]; } } // If it's an abort if ( isAbort ) { // Abort it manually if needed if ( xhr.readyState !== 4 ) { xhr.abort(); } } else { responses = {}; status = xhr.status; responseHeaders = xhr.getAllResponseHeaders(); // When requesting binary data, IE6-9 will throw an exception // on any attempt to access responseText (#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 && s.isLocal && !s.crossDomain ) { status = responses.text ? 200 : 404; // IE - #1450: sometimes returns 1223 when it should be 204 } else if ( status === 1223 ) { status = 204; } } } } catch( firefoxAccessException ) { if ( !isAbort ) { complete( -1, firefoxAccessException ); } } // Call complete if needed if ( responses ) { complete( status, statusText, responses, responseHeaders ); } }; if ( !s.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 { handle = ++xhrId; if ( xhrOnUnloadAbort ) { // Create the active xhrs callbacks list if needed // and attach the unload handler if ( !xhrCallbacks ) { xhrCallbacks = {}; jQuery( window ).unload( xhrOnUnloadAbort ); } // Add to list of active xhrs callbacks xhrCallbacks[ handle ] = callback; } xhr.onreadystatechange = callback; } }, abort: function() { if ( callback ) { callback( undefined, true ); } } }; } }); } var fxNow, timerId, rfxtypes = /^(?:toggle|show|hide)$/, rfxnum = new RegExp( "^(?:([+-])=|)(" + core_pnum + ")([a-z%]*)$", "i" ), rrun = /queueHooks$/, animationPrefilters = [ defaultPrefilter ], tweeners = { "*": [function( prop, value ) { var end, unit, tween = this.createTween( prop, value ), parts = rfxnum.exec( value ), target = tween.cur(), start = +target || 0, scale = 1, maxIterations = 20; if ( parts ) { end = +parts[2]; unit = parts[3] || ( jQuery.cssNumber[ prop ] ? "" : "px" ); // We need to compute starting value if ( unit !== "px" && start ) { // Iteratively approximate from a nonzero starting point // Prefer the current property, because this process will be trivial if it uses the same units // Fallback to end or a simple constant start = jQuery.css( tween.elem, prop, true ) || end || 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 ); } tween.unit = unit; tween.start = start; // If a +=/-= token was provided, we're doing a relative animation tween.end = parts[1] ? start + ( parts[1] + 1 ) * end : end; } return tween; }] }; // Animations created synchronously will run synchronously function createFxNow() { setTimeout(function() { fxNow = undefined; }); return ( fxNow = jQuery.now() ); } function createTweens( animation, props ) { jQuery.each( props, function( prop, value ) { var collection = ( tweeners[ prop ] || [] ).concat( tweeners[ "*" ] ), index = 0, length = collection.length; for ( ; index < length; index++ ) { if ( collection[ index ].call( animation, prop, value ) ) { // we're done with this property return; } } }); } 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; } } createTweens( animation, props ); 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 ); } function propFilter( props, specialEasing ) { var value, name, index, easing, 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; } } } 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 ); } } }); function defaultPrefilter( elem, props, opts ) { /*jshint validthis:true */ var prop, index, length, value, dataShow, toggle, tween, hooks, oldfire, anim = this, style = elem.style, orig = {}, handled = [], hidden = elem.nodeType && isHidden( elem ); // 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 if ( jQuery.css( elem, "display" ) === "inline" && jQuery.css( elem, "float" ) === "none" ) { // inline-level elements accept inline-block; // block-level elements need to be inline with layout if ( !jQuery.support.inlineBlockNeedsLayout || css_defaultDisplay( elem.nodeName ) === "inline" ) { style.display = "inline-block"; } else { style.zoom = 1; } } } if ( opts.overflow ) { style.overflow = "hidden"; if ( !jQuery.support.shrinkWrapBlocks ) { anim.always(function() { style.overflow = opts.overflow[ 0 ]; style.overflowX = opts.overflow[ 1 ]; style.overflowY = opts.overflow[ 2 ]; }); } } // show/hide pass for ( index in props ) { value = props[ index ]; if ( rfxtypes.exec( value ) ) { delete props[ index ]; toggle = toggle || value === "toggle"; if ( value === ( hidden ? "hide" : "show" ) ) { continue; } handled.push( index ); } } length = handled.length; if ( length ) { dataShow = jQuery._data( elem, "fxshow" ) || jQuery._data( elem, "fxshow", {} ); if ( "hidden" in dataShow ) { hidden = dataShow.hidden; } // 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 ( index = 0 ; index < length ; index++ ) { prop = handled[ index ]; tween = anim.createTween( prop, hidden ? dataShow[ prop ] : 0 ); orig[ prop ] = dataShow[ prop ] || jQuery.style( elem, prop ); if ( !( prop in dataShow ) ) { dataShow[ prop ] = tween.start; if ( hidden ) { tween.end = tween.start; tween.start = prop === "width" || prop === "height" ? 1 : 0; } } } } } 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; } } } }; // Remove in 2.0 - this supports IE8's 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.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 ); }; }); 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 ); doAnimation.finish = function() { anim.stop( true ); }; // 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.cur && hooks.cur.finish ) { hooks.cur.finish.call( this ); } // 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; }); } }); // 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; } // 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.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.easing = { linear: function( p ) { return p; }, swing: function( p ) { return 0.5 - Math.cos( p*Math.PI ) / 2; } }; jQuery.timers = []; jQuery.fx = Tween.prototype.init; 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 ) { if ( timer() && jQuery.timers.push( timer ) ) { jQuery.fx.start(); } }; 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 }; // Back Compat <1.8 extension point jQuery.fx.step = {}; if ( jQuery.expr && jQuery.expr.filters ) { jQuery.expr.filters.animated = function( elem ) { return jQuery.grep(jQuery.timers, function( fn ) { return elem === fn.elem; }).length; }; } jQuery.fn.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 !== core_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 ) }; }; jQuery.offset = { setOffset: function( elem, options, i ) { var position = jQuery.css( elem, "position" ); // set position first, in-case top/left are set even on static elem if ( position === "static" ) { elem.style.position = "relative"; } var curElem = jQuery( elem ), curOffset = curElem.offset(), curCSSTop = jQuery.css( elem, "top" ), curCSSLeft = jQuery.css( elem, "left" ), calculatePosition = ( position === "absolute" || position === "fixed" ) && jQuery.inArray("auto", [curCSSTop, curCSSLeft]) > -1, props = {}, curPosition = {}, curTop, curLeft; // 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({ 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 it's 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 || document.documentElement; while ( offsetParent && ( !jQuery.nodeName( offsetParent, "html" ) && jQuery.css( offsetParent, "position") === "static" ) ) { offsetParent = offsetParent.offsetParent; } return offsetParent || document.documentElement; }); } }); // 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 jQuery.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 ); }; }); function getWindow( elem ) { return jQuery.isWindow( elem ) ? elem : elem.nodeType === 9 ? elem.defaultView || elem.parentWindow : false; } // 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 jQuery.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 ); }; }); }); // Limit scope pollution from any deprecated API // (function() { // })(); // Expose jQuery to the global object window.jQuery = window.$ = jQuery; // Expose jQuery as an AMD module, but only for AMD loaders that // understand the issues with loading multiple versions of jQuery // in a page that all might call define(). The loader will indicate // they have special allowances for multiple jQuery versions by // specifying define.amd.jQuery = true. Register as a named module, // since jQuery can be concatenated with other files that may use define, // but not use 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. if ( typeof define === "function" && define.amd && define.amd.jQuery ) { define( "jquery", [], function () { return jQuery; } ); } })( window );
src/svg-icons/maps/my-location.js
ruifortes/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let MapsMyLocation = (props) => ( <SvgIcon {...props}> <path d="M12 8c-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm8.94 3c-.46-4.17-3.77-7.48-7.94-7.94V1h-2v2.06C6.83 3.52 3.52 6.83 3.06 11H1v2h2.06c.46 4.17 3.77 7.48 7.94 7.94V23h2v-2.06c4.17-.46 7.48-3.77 7.94-7.94H23v-2h-2.06zM12 19c-3.87 0-7-3.13-7-7s3.13-7 7-7 7 3.13 7 7-3.13 7-7 7z"/> </SvgIcon> ); MapsMyLocation = pure(MapsMyLocation); MapsMyLocation.displayName = 'MapsMyLocation'; MapsMyLocation.muiName = 'SvgIcon'; export default MapsMyLocation;
demo/src/index.js
nafitzgerald/allennlp
import React from 'react'; import ReactDOM from 'react-dom'; import App from './App'; ReactDOM.render(<App />, document.getElementById('root'));
app/routes/index.js
ryanyogan/redux-blog-example
import React from 'react'; import { Route } from 'react-router'; import App from './App'; import SignupRoute from './SignupRoute'; import LoginRoute from './LoginRoute'; import ProfileRoute from './ProfileRoute'; import NotFound from '../components/NotFound'; import redirectBackAfter from '../utils/redirectBackAfter'; import fillStore from '../utils/fillStore'; import DashboardRoute from './DashboardRoute'; import * as Posts from './Posts'; const routes = ( <Route component={App}> <Route path="/signup" component={SignupRoute} /> <Route path="/login" component={LoginRoute} /> <Route path="/" component={Posts.List} /> <Route path="/posts/:id" component={Posts.View} /> <Route requireAuth> <Route path="/profile" component={ProfileRoute} /> <Route path="/dashboard" component={DashboardRoute} /> <Route path="/dashboard/add" component={Posts.Edit} /> <Route path="/dashboard/edit/:id" component={Posts.Edit} /> </Route> <Route path="*" component={NotFound} /> </Route> ); function walk(routes, cb) { cb(routes); if (routes.childRoutes) { routes.childRoutes.forEach(route => walk(route, cb)); } return routes; } export default (store, client) => { return walk(Route.createRouteFromReactElement(routes), route => { route.onEnter = (nextState, transition) => { const loggedIn = !!store.getState().auth.token; if (route.requireAuth && !loggedIn) { transition.to(...redirectBackAfter('/login', nextState)); } else if (client) { fillStore(store, nextState, [route.component]); } }; }); };
src/components/copy/addCopies/AddCopies.js
katima-g33k/blu-react-desktop
import React, { Component } from 'react'; import PropTypes from 'prop-types'; import { Col, Panel, Row, } from 'react-bootstrap'; import i18n from '../../../lib/i18n'; import { Item } from '../../../lib/models'; import ActionPanel from '../../../containers/AddCopiesActionPanelContainer'; import AddedCopiesTable from '../../../containers/AddedCopiesTableContainer'; import { Alert } from '../../general'; import ItemForm from '../../../containers/ItemFormContainer'; import Search from '../../../containers/SearchContainer'; const { Body, Heading, Title } = Panel; export default class AddCopies extends Component { static propTypes = { fetchItem: PropTypes.func.isRequired, handleOnAddCopy: PropTypes.func.isRequired, item: PropTypes.instanceOf(Item), memberName: PropTypes.string.isRequired, onLoad: PropTypes.func.isRequired, scannedItem: PropTypes.shape(), }; static defaultProps = { item: null, scannedItem: null, }; state = { ean13: null, isSearch: true, }; componentDidMount() { this.props.onLoad(); } componentWillReceiveProps(nextProps) { // TODO: Find a way to handle scanning same item twice in a row if (!this.state.isSearch) { return; } if ((this.props.scannedItem || {}).ean13 === (nextProps.scannedItem || {}).ean13) { if (nextProps.item.id) { this.props.handleOnAddCopy(nextProps.item); } return; } if (nextProps.scannedItem && nextProps.scannedItem.id) { this.props.fetchItem(nextProps.scannedItem.id); return; } if (!this.state.isSearch) { this.toggleView(); } else if (nextProps.scannedItem && nextProps.scannedItem.ean13) { this.toggleView(nextProps.scannedItem.ean13); } } toggleView = (ean13 = null) => this.setState(state => ({ ean13, isSearch: !state.isSearch })); renderSearch = () => ( <Search disableTypeSelection noHeader onAddButton={this.toggleView} onRowClick={this.props.handleOnAddCopy} type={Search.TYPES.ITEM} /> ); renderForm = () => ( <ItemForm ean13={this.state.ean13 || ''} onCancel={this.toggleView} onSaveCallback={this.props.handleOnAddCopy} /> ); render() { return ( <Row> <Col md={10}> <Panel> <Heading> <Title>{i18n('AddCopies.title')}</Title> </Heading> <Alert label={i18n('AddCopies.warning')} /> <Body> <h2> {this.props.memberName} </h2> <Row> <Col md={4}> <AddedCopiesTable /> </Col> </Row> <Row> <Col md={12}> {this.state.isSearch ? this.renderSearch() : this.renderForm()} </Col> </Row> </Body> </Panel> </Col> <Col md={2}> <ActionPanel /> </Col> </Row> ); } }
docs/src/examples/elements/Header/Content/HeaderExamplePlugIcon.js
Semantic-Org/Semantic-UI-React
import React from 'react' import { Header, Icon } from 'semantic-ui-react' const HeaderExamplePlugIcon = () => ( <Header as='h2'> <Icon name='plug' /> <Header.Content>Uptime Guarantee</Header.Content> </Header> ) export default HeaderExamplePlugIcon
src/js/components/icons/base/FormTrash.js
kylebyerly-hp/grommet
// (C) Copyright 2014-2015 Hewlett Packard Enterprise Development LP import React, { Component } from 'react'; import PropTypes from 'prop-types'; import classnames from 'classnames'; import CSSClassnames from '../../../utils/CSSClassnames'; import Intl from '../../../utils/Intl'; import Props from '../../../utils/Props'; const CLASS_ROOT = CSSClassnames.CONTROL_ICON; const COLOR_INDEX = CSSClassnames.COLOR_INDEX; export default class Icon extends Component { render () { const { className, colorIndex } = this.props; let { a11yTitle, size, responsive } = this.props; let { intl } = this.context; const classes = classnames( CLASS_ROOT, `${CLASS_ROOT}-form-trash`, className, { [`${CLASS_ROOT}--${size}`]: size, [`${CLASS_ROOT}--responsive`]: responsive, [`${COLOR_INDEX}-${colorIndex}`]: colorIndex } ); a11yTitle = a11yTitle || Intl.getMessage(intl, 'form-trash'); const restProps = Props.omit(this.props, Object.keys(Icon.propTypes)); return <svg {...restProps} version="1.1" viewBox="0 0 24 24" width="24px" height="24px" role="img" className={classes} aria-label={a11yTitle}><path fill="none" stroke="#000" strokeWidth="2" d="M7.5,9 L16.5,9 L16.5,19 L7.5,19 L7.5,9 Z M5,9 L19,9 M9.36363636,6 L14.3636364,6 L14.3636364,9 L9.36363636,9 L9.36363636,6 Z M10.5455,11 L10.5455,17 M13.5455,11 L13.5455,17"/></svg>; } }; Icon.contextTypes = { intl: PropTypes.object }; Icon.defaultProps = { responsive: true }; Icon.displayName = 'FormTrash'; Icon.icon = true; Icon.propTypes = { a11yTitle: PropTypes.string, colorIndex: PropTypes.string, size: PropTypes.oneOf(['xsmall', 'small', 'medium', 'large', 'xlarge', 'huge']), responsive: PropTypes.bool };
src/routes.js
sebacorrea33/todoinstitutos
import React from 'react'; import {IndexRoute, Route} from 'react-router'; import App from './containers/App'; import NotFoundPage from './containers/NotFoundPage'; import HomePage from './containers/HomePage'; import AboutPage from './containers/AboutPage'; import SearchPage from './containers/SearchPage'; import ProfilePage from './containers/ProfilePage'; import RegisterPage from './containers/RegisterPage'; import UserPage from './containers/UserPage'; export default () => { /** * Please keep routes in alphabetical order */ return ( <Route path="/" component={App}> { /* Home (main) route */ } <IndexRoute component={HomePage} /> { /* Routes */ } <Route path="registrarse" component={RegisterPage} /> <Route path="nosotros" component={AboutPage} /> <Route path="buscar" component={SearchPage} /> <Route path="perfil" component={ProfilePage} /> <Route path="user" component={UserPage} /> <Route path="user/:tab" component={UserPage} /> <Route path="/:profile" component={ProfilePage} /> { /* Catch all route */ } <Route path="*" component={NotFoundPage} status={404} /> </Route> ); };
Sources/ewsnodejs-server/node_modules/@material-ui/styles/es/styled/styled.js
nihospr01/OpenSpeechPlatform-UCSD
import _extends from "@babel/runtime/helpers/esm/extends"; import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose"; import React from 'react'; import clsx from 'clsx'; import PropTypes from 'prop-types'; import { chainPropTypes, getDisplayName } from '@material-ui/utils'; import hoistNonReactStatics from 'hoist-non-react-statics'; import makeStyles from '../makeStyles'; function omit(input, fields) { const output = {}; Object.keys(input).forEach(prop => { if (fields.indexOf(prop) === -1) { output[prop] = input[prop]; } }); return output; } // styled-components's API removes the mapping between components and styles. // Using components as a low-level styling construct can be simpler. export default function styled(Component) { const componentCreator = (style, options = {}) => { const { name } = options, stylesOptions = _objectWithoutPropertiesLoose(options, ["name"]); if (process.env.NODE_ENV !== 'production' && Component === undefined) { throw new Error(['You are calling styled(Component)(style) with an undefined component.', 'You may have forgotten to import it.'].join('\n')); } let classNamePrefix = name; if (process.env.NODE_ENV !== 'production') { if (!name) { // Provide a better DX outside production. const displayName = getDisplayName(Component); if (displayName !== undefined) { classNamePrefix = displayName; } } } const stylesOrCreator = typeof style === 'function' ? theme => ({ root: props => style(_extends({ theme }, props)) }) : { root: style }; const useStyles = makeStyles(stylesOrCreator, _extends({ Component, name: name || Component.displayName, classNamePrefix }, stylesOptions)); let filterProps; let propTypes = {}; if (style.filterProps) { filterProps = style.filterProps; delete style.filterProps; } /* eslint-disable react/forbid-foreign-prop-types */ if (style.propTypes) { propTypes = style.propTypes; delete style.propTypes; } /* eslint-enable react/forbid-foreign-prop-types */ const StyledComponent = /*#__PURE__*/React.forwardRef(function StyledComponent(props, ref) { const { children, className: classNameProp, clone, component: ComponentProp } = props, other = _objectWithoutPropertiesLoose(props, ["children", "className", "clone", "component"]); const classes = useStyles(props); const className = clsx(classes.root, classNameProp); let spread = other; if (filterProps) { spread = omit(spread, filterProps); } if (clone) { return /*#__PURE__*/React.cloneElement(children, _extends({ className: clsx(children.props.className, className) }, spread)); } if (typeof children === 'function') { return children(_extends({ className }, spread)); } const FinalComponent = ComponentProp || Component; return /*#__PURE__*/React.createElement(FinalComponent, _extends({ ref: ref, className: className }, spread), children); }); process.env.NODE_ENV !== "production" ? StyledComponent.propTypes = _extends({ /** * A render function or node. */ children: PropTypes.oneOfType([PropTypes.node, PropTypes.func]), /** * @ignore */ className: PropTypes.string, /** * If `true`, the component will recycle it's children HTML element. * It's using `React.cloneElement` internally. * * This prop will be deprecated and removed in v5 */ clone: chainPropTypes(PropTypes.bool, props => { if (props.clone && props.component) { return new Error('You can not use the clone and component prop at the same time.'); } return null; }), /** * The component used for the root node. * Either a string to use a HTML element or a component. */ component: PropTypes /* @typescript-to-proptypes-ignore */ .elementType }, propTypes) : void 0; if (process.env.NODE_ENV !== 'production') { StyledComponent.displayName = `Styled(${classNamePrefix})`; } hoistNonReactStatics(StyledComponent, Component); return StyledComponent; }; return componentCreator; }
packages/material-ui-icons/lib/FormatItalicTwoTone.js
mbrookes/material-ui
"use strict"; var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault"); Object.defineProperty(exports, "__esModule", { value: true }); exports.default = void 0; var _createSvgIcon = _interopRequireDefault(require("./utils/createSvgIcon")); var _jsxRuntime = require("react/jsx-runtime"); var _default = (0, _createSvgIcon.default)( /*#__PURE__*/(0, _jsxRuntime.jsx)("path", { d: "M6 15v3h8v-3h-2.21l3.42-8H18V4h-8v3h2.21l-3.42 8z" }), 'FormatItalicTwoTone'); exports.default = _default;
node_modules/react-icons/md/strikethrough-s.js
bengimbel/Solstice-React-Contacts-Project
import React from 'react' import Icon from 'react-icon-base' const MdStrikethroughS = props => ( <Icon viewBox="0 0 40 40" {...props}> <g><path d="m15.6 21.9c0 3 1.9 4.2 4.9 4.2 2 0 3.8-0.8 3.8-2.8 0-1.9-1-2.3-2.3-3-0.3-0.1-0.7-0.2-1-0.3h-16v-3.4h30v3.4h-6.5c0.1 0.2 0.3 0.4 0.3 0.5 0.3 0.8 0.6 1.8 0.6 2.8 0 3.6-2.4 5.4-5.3 6.2-1.1 0.3-2.2 0.5-3.6 0.5-0.7 0-1.6-0.1-2.4-0.2-1.7-0.4-3.1-0.9-4.3-1.8-1.8-1.3-3.1-3.1-3.1-6.1h4.9z m8.7-9.4c0-2.4-1.5-3.5-4-3.5-1.8 0-3.1 0.6-3.7 1.7-0.1 0.3-0.2 0.7-0.2 1.1 0 0.8 0.5 1.5 1.3 2 0.6 0.4 1.2 0.8 2.3 1.2h-7.7c0-0.2-0.2-0.2-0.3-0.4-0.4-0.8-0.6-1.7-0.6-2.8 0-2.2 1.2-3.9 2.5-4.9 1.6-1.1 3.7-1.9 6.5-1.9 2.7 0 5 0.8 6.5 2.1 1.3 1.2 2.4 3 2.4 5.4h-5z"/></g> </Icon> ) export default MdStrikethroughS
src/svg-icons/action/settings-voice.js
hai-cea/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ActionSettingsVoice = (props) => ( <SvgIcon {...props}> <path d="M7 24h2v-2H7v2zm5-11c1.66 0 2.99-1.34 2.99-3L15 4c0-1.66-1.34-3-3-3S9 2.34 9 4v6c0 1.66 1.34 3 3 3zm-1 11h2v-2h-2v2zm4 0h2v-2h-2v2zm4-14h-1.7c0 3-2.54 5.1-5.3 5.1S6.7 13 6.7 10H5c0 3.41 2.72 6.23 6 6.72V20h2v-3.28c3.28-.49 6-3.31 6-6.72z"/> </SvgIcon> ); ActionSettingsVoice = pure(ActionSettingsVoice); ActionSettingsVoice.displayName = 'ActionSettingsVoice'; ActionSettingsVoice.muiName = 'SvgIcon'; export default ActionSettingsVoice;
solutions/step8/client/index.js
colmarius/universal-react-workshop-app
import {render} from 'react-dom' import React from 'react' import Bootstrap from 'bootstrap/dist/css/bootstrap.css' import App from "./App.jsx" import {Provider} from 'react-redux' import {createStore, applyMiddleware} from 'redux' import reducers from './reducers' import thunk from 'redux-thunk' import {loadData} from './actions' let store if (typeof window.__PRELOADED_STATE__ !== 'undefined') { store = createStore(reducers, window.__PRELOADED_STATE__, applyMiddleware(thunk)) } else { // ...no preloaded state...dispatch the load action! store = createStore(reducers, applyMiddleware(thunk)) store.dispatch(loadData()) } render(<Provider store={store}> <App /> </Provider>, document.getElementById("container"))
node_modules/react-router-ie8/lib/PropTypes.js
Hive-Team/venus
'use strict'; var assign = require('react/lib/Object.assign'); var ReactPropTypes = require('react').PropTypes; var Route = require('./Route'); var PropTypes = assign({}, ReactPropTypes, { /** * Indicates that a prop should be falsy. */ falsy: function falsy(props, propName, componentName) { if (props[propName]) return new Error('<' + componentName + '> should not have a "' + propName + '" prop'); }, /** * Indicates that a prop should be a Route object. */ route: ReactPropTypes.instanceOf(Route), /** * Indicates that a prop should be a Router object. */ //router: ReactPropTypes.instanceOf(Router) // TODO router: ReactPropTypes.func }); module.exports = PropTypes;
ajax/libs/x-editable/1.5.0/bootstrap-editable/js/bootstrap-editable.js
gaearon/cdnjs
/*! X-editable - v1.5.0 * In-place editing with Twitter Bootstrap, jQuery UI or pure jQuery * http://github.com/vitalets/x-editable * Copyright (c) 2013 Vitaliy Potapov; Licensed MIT */ /** Form with single input element, two buttons and two states: normal/loading. Applied as jQuery method to DIV tag (not to form tag!). This is because form can be in loading state when spinner shown. Editableform is linked with one of input types, e.g. 'text', 'select' etc. @class editableform @uses text @uses textarea **/ (function ($) { "use strict"; var EditableForm = function (div, options) { this.options = $.extend({}, $.fn.editableform.defaults, options); this.$div = $(div); //div, containing form. Not form tag. Not editable-element. if(!this.options.scope) { this.options.scope = this; } //nothing shown after init }; EditableForm.prototype = { constructor: EditableForm, initInput: function() { //called once //take input from options (as it is created in editable-element) this.input = this.options.input; //set initial value //todo: may be add check: typeof str === 'string' ? this.value = this.input.str2value(this.options.value); //prerender: get input.$input this.input.prerender(); }, initTemplate: function() { this.$form = $($.fn.editableform.template); }, initButtons: function() { var $btn = this.$form.find('.editable-buttons'); $btn.append($.fn.editableform.buttons); if(this.options.showbuttons === 'bottom') { $btn.addClass('editable-buttons-bottom'); } }, /** Renders editableform @method render **/ render: function() { //init loader this.$loading = $($.fn.editableform.loading); this.$div.empty().append(this.$loading); //init form template and buttons this.initTemplate(); if(this.options.showbuttons) { this.initButtons(); } else { this.$form.find('.editable-buttons').remove(); } //show loading state this.showLoading(); //flag showing is form now saving value to server. //It is needed to wait when closing form. this.isSaving = false; /** Fired when rendering starts @event rendering @param {Object} event event object **/ this.$div.triggerHandler('rendering'); //init input this.initInput(); //append input to form this.$form.find('div.editable-input').append(this.input.$tpl); //append form to container this.$div.append(this.$form); //render input $.when(this.input.render()) .then($.proxy(function () { //setup input to submit automatically when no buttons shown if(!this.options.showbuttons) { this.input.autosubmit(); } //attach 'cancel' handler this.$form.find('.editable-cancel').click($.proxy(this.cancel, this)); if(this.input.error) { this.error(this.input.error); this.$form.find('.editable-submit').attr('disabled', true); this.input.$input.attr('disabled', true); //prevent form from submitting this.$form.submit(function(e){ e.preventDefault(); }); } else { this.error(false); this.input.$input.removeAttr('disabled'); this.$form.find('.editable-submit').removeAttr('disabled'); var value = (this.value === null || this.value === undefined || this.value === '') ? this.options.defaultValue : this.value; this.input.value2input(value); //attach submit handler this.$form.submit($.proxy(this.submit, this)); } /** Fired when form is rendered @event rendered @param {Object} event event object **/ this.$div.triggerHandler('rendered'); this.showForm(); //call postrender method to perform actions required visibility of form if(this.input.postrender) { this.input.postrender(); } }, this)); }, cancel: function() { /** Fired when form was cancelled by user @event cancel @param {Object} event event object **/ this.$div.triggerHandler('cancel'); }, showLoading: function() { var w, h; if(this.$form) { //set loading size equal to form w = this.$form.outerWidth(); h = this.$form.outerHeight(); if(w) { this.$loading.width(w); } if(h) { this.$loading.height(h); } this.$form.hide(); } else { //stretch loading to fill container width w = this.$loading.parent().width(); if(w) { this.$loading.width(w); } } this.$loading.show(); }, showForm: function(activate) { this.$loading.hide(); this.$form.show(); if(activate !== false) { this.input.activate(); } /** Fired when form is shown @event show @param {Object} event event object **/ this.$div.triggerHandler('show'); }, error: function(msg) { var $group = this.$form.find('.control-group'), $block = this.$form.find('.editable-error-block'), lines; if(msg === false) { $group.removeClass($.fn.editableform.errorGroupClass); $block.removeClass($.fn.editableform.errorBlockClass).empty().hide(); } else { //convert newline to <br> for more pretty error display if(msg) { lines = msg.split("\n"); for (var i = 0; i < lines.length; i++) { lines[i] = $('<div>').text(lines[i]).html(); } msg = lines.join('<br>'); } $group.addClass($.fn.editableform.errorGroupClass); $block.addClass($.fn.editableform.errorBlockClass).html(msg).show(); } }, submit: function(e) { e.stopPropagation(); e.preventDefault(); var error, newValue = this.input.input2value(); //get new value from input //validation if (error = this.validate(newValue)) { this.error(error); this.showForm(); return; } //if value not changed --> trigger 'nochange' event and return /*jslint eqeq: true*/ if (!this.options.savenochange && this.input.value2str(newValue) == this.input.value2str(this.value)) { /*jslint eqeq: false*/ /** Fired when value not changed but form is submitted. Requires savenochange = false. @event nochange @param {Object} event event object **/ this.$div.triggerHandler('nochange'); return; } //convert value for submitting to server var submitValue = this.input.value2submit(newValue); this.isSaving = true; //sending data to server $.when(this.save(submitValue)) .done($.proxy(function(response) { this.isSaving = false; //run success callback var res = typeof this.options.success === 'function' ? this.options.success.call(this.options.scope, response, newValue) : null; //if success callback returns false --> keep form open and do not activate input if(res === false) { this.error(false); this.showForm(false); return; } //if success callback returns string --> keep form open, show error and activate input if(typeof res === 'string') { this.error(res); this.showForm(); return; } //if success callback returns object like {newValue: <something>} --> use that value instead of submitted //it is usefull if you want to chnage value in url-function if(res && typeof res === 'object' && res.hasOwnProperty('newValue')) { newValue = res.newValue; } //clear error message this.error(false); this.value = newValue; /** Fired when form is submitted @event save @param {Object} event event object @param {Object} params additional params @param {mixed} params.newValue raw new value @param {mixed} params.submitValue submitted value as string @param {Object} params.response ajax response @example $('#form-div').on('save'), function(e, params){ if(params.newValue === 'username') {...} }); **/ this.$div.triggerHandler('save', {newValue: newValue, submitValue: submitValue, response: response}); }, this)) .fail($.proxy(function(xhr) { this.isSaving = false; var msg; if(typeof this.options.error === 'function') { msg = this.options.error.call(this.options.scope, xhr, newValue); } else { msg = typeof xhr === 'string' ? xhr : xhr.responseText || xhr.statusText || 'Unknown error!'; } this.error(msg); this.showForm(); }, this)); }, save: function(submitValue) { //try parse composite pk defined as json string in data-pk this.options.pk = $.fn.editableutils.tryParseJson(this.options.pk, true); var pk = (typeof this.options.pk === 'function') ? this.options.pk.call(this.options.scope) : this.options.pk, /* send on server in following cases: 1. url is function 2. url is string AND (pk defined OR send option = always) */ send = !!(typeof this.options.url === 'function' || (this.options.url && ((this.options.send === 'always') || (this.options.send === 'auto' && pk !== null && pk !== undefined)))), params; if (send) { //send to server this.showLoading(); //standard params params = { name: this.options.name || '', value: submitValue, pk: pk }; //additional params if(typeof this.options.params === 'function') { params = this.options.params.call(this.options.scope, params); } else { //try parse json in single quotes (from data-params attribute) this.options.params = $.fn.editableutils.tryParseJson(this.options.params, true); $.extend(params, this.options.params); } if(typeof this.options.url === 'function') { //user's function return this.options.url.call(this.options.scope, params); } else { //send ajax to server and return deferred object return $.ajax($.extend({ url : this.options.url, data : params, type : 'POST' }, this.options.ajaxOptions)); } } }, validate: function (value) { if (value === undefined) { value = this.value; } if (typeof this.options.validate === 'function') { return this.options.validate.call(this.options.scope, value); } }, option: function(key, value) { if(key in this.options) { this.options[key] = value; } if(key === 'value') { this.setValue(value); } //do not pass option to input as it is passed in editable-element }, setValue: function(value, convertStr) { if(convertStr) { this.value = this.input.str2value(value); } else { this.value = value; } //if form is visible, update input if(this.$form && this.$form.is(':visible')) { this.input.value2input(this.value); } } }; /* Initialize editableform. Applied to jQuery object. @method $().editableform(options) @params {Object} options @example var $form = $('&lt;div&gt;').editableform({ type: 'text', name: 'username', url: '/post', value: 'vitaliy' }); //to display form you should call 'render' method $form.editableform('render'); */ $.fn.editableform = function (option) { var args = arguments; return this.each(function () { var $this = $(this), data = $this.data('editableform'), options = typeof option === 'object' && option; if (!data) { $this.data('editableform', (data = new EditableForm(this, options))); } if (typeof option === 'string') { //call method data[option].apply(data, Array.prototype.slice.call(args, 1)); } }); }; //keep link to constructor to allow inheritance $.fn.editableform.Constructor = EditableForm; //defaults $.fn.editableform.defaults = { /* see also defaults for input */ /** Type of input. Can be <code>text|textarea|select|date|checklist</code> @property type @type string @default 'text' **/ type: 'text', /** Url for submit, e.g. <code>'/post'</code> If function - it will be called instead of ajax. Function should return deferred object to run fail/done callbacks. @property url @type string|function @default null @example url: function(params) { var d = new $.Deferred; if(params.value === 'abc') { return d.reject('error message'); //returning error via deferred object } else { //async saving data in js model someModel.asyncSaveMethod({ ..., success: function(){ d.resolve(); } }); return d.promise(); } } **/ url:null, /** Additional params for submit. If defined as <code>object</code> - it is **appended** to original ajax data (pk, name and value). If defined as <code>function</code> - returned object **overwrites** original ajax data. @example params: function(params) { //originally params contain pk, name and value params.a = 1; return params; } @property params @type object|function @default null **/ params:null, /** Name of field. Will be submitted on server. Can be taken from <code>id</code> attribute @property name @type string @default null **/ name: null, /** Primary key of editable object (e.g. record id in database). For composite keys use object, e.g. <code>{id: 1, lang: 'en'}</code>. Can be calculated dynamically via function. @property pk @type string|object|function @default null **/ pk: null, /** Initial value. If not defined - will be taken from element's content. For __select__ type should be defined (as it is ID of shown text). @property value @type string|object @default null **/ value: null, /** Value that will be displayed in input if original field value is empty (`null|undefined|''`). @property defaultValue @type string|object @default null @since 1.4.6 **/ defaultValue: null, /** Strategy for sending data on server. Can be `auto|always|never`. When 'auto' data will be sent on server **only if pk and url defined**, otherwise new value will be stored locally. @property send @type string @default 'auto' **/ send: 'auto', /** Function for client-side validation. If returns string - means validation not passed and string showed as error. @property validate @type function @default null @example validate: function(value) { if($.trim(value) == '') { return 'This field is required'; } } **/ validate: null, /** Success callback. Called when value successfully sent on server and **response status = 200**. Usefull to work with json response. For example, if your backend response can be <code>{success: true}</code> or <code>{success: false, msg: "server error"}</code> you can check it inside this callback. If it returns **string** - means error occured and string is shown as error message. If it returns **object like** <code>{newValue: &lt;something&gt;}</code> - it overwrites value, submitted by user. Otherwise newValue simply rendered into element. @property success @type function @default null @example success: function(response, newValue) { if(!response.success) return response.msg; } **/ success: null, /** Error callback. Called when request failed (response status != 200). Usefull when you want to parse error response and display a custom message. Must return **string** - the message to be displayed in the error block. @property error @type function @default null @since 1.4.4 @example error: function(response, newValue) { if(response.status === 500) { return 'Service unavailable. Please try later.'; } else { return response.responseText; } } **/ error: null, /** Additional options for submit ajax request. List of values: http://api.jquery.com/jQuery.ajax @property ajaxOptions @type object @default null @since 1.1.1 @example ajaxOptions: { type: 'put', dataType: 'json' } **/ ajaxOptions: null, /** Where to show buttons: left(true)|bottom|false Form without buttons is auto-submitted. @property showbuttons @type boolean|string @default true @since 1.1.1 **/ showbuttons: true, /** Scope for callback methods (success, validate). If <code>null</code> means editableform instance itself. @property scope @type DOMElement|object @default null @since 1.2.0 @private **/ scope: null, /** Whether to save or cancel value when it was not changed but form was submitted @property savenochange @type boolean @default false @since 1.2.0 **/ savenochange: false }; /* Note: following params could redefined in engine: bootstrap or jqueryui: Classes 'control-group' and 'editable-error-block' must always present! */ $.fn.editableform.template = '<form class="form-inline editableform">'+ '<div class="control-group">' + '<div><div class="editable-input"></div><div class="editable-buttons"></div></div>'+ '<div class="editable-error-block"></div>' + '</div>' + '</form>'; //loading div $.fn.editableform.loading = '<div class="editableform-loading"></div>'; //buttons $.fn.editableform.buttons = '<button type="submit" class="editable-submit">ok</button>'+ '<button type="button" class="editable-cancel">cancel</button>'; //error class attached to control-group $.fn.editableform.errorGroupClass = null; //error class attached to editable-error-block $.fn.editableform.errorBlockClass = 'editable-error'; //engine $.fn.editableform.engine = 'jquery'; }(window.jQuery)); /** * EditableForm utilites */ (function ($) { "use strict"; //utils $.fn.editableutils = { /** * classic JS inheritance function */ inherit: function (Child, Parent) { var F = function() { }; F.prototype = Parent.prototype; Child.prototype = new F(); Child.prototype.constructor = Child; Child.superclass = Parent.prototype; }, /** * set caret position in input * see http://stackoverflow.com/questions/499126/jquery-set-cursor-position-in-text-area */ setCursorPosition: function(elem, pos) { if (elem.setSelectionRange) { elem.setSelectionRange(pos, pos); } else if (elem.createTextRange) { var range = elem.createTextRange(); range.collapse(true); range.moveEnd('character', pos); range.moveStart('character', pos); range.select(); } }, /** * function to parse JSON in *single* quotes. (jquery automatically parse only double quotes) * That allows such code as: <a data-source="{'a': 'b', 'c': 'd'}"> * safe = true --> means no exception will be thrown * for details see http://stackoverflow.com/questions/7410348/how-to-set-json-format-to-html5-data-attributes-in-the-jquery */ tryParseJson: function(s, safe) { if (typeof s === 'string' && s.length && s.match(/^[\{\[].*[\}\]]$/)) { if (safe) { try { /*jslint evil: true*/ s = (new Function('return ' + s))(); /*jslint evil: false*/ } catch (e) {} finally { return s; } } else { /*jslint evil: true*/ s = (new Function('return ' + s))(); /*jslint evil: false*/ } } return s; }, /** * slice object by specified keys */ sliceObj: function(obj, keys, caseSensitive /* default: false */) { var key, keyLower, newObj = {}; if (!$.isArray(keys) || !keys.length) { return newObj; } for (var i = 0; i < keys.length; i++) { key = keys[i]; if (obj.hasOwnProperty(key)) { newObj[key] = obj[key]; } if(caseSensitive === true) { continue; } //when getting data-* attributes via $.data() it's converted to lowercase. //details: http://stackoverflow.com/questions/7602565/using-data-attributes-with-jquery //workaround is code below. keyLower = key.toLowerCase(); if (obj.hasOwnProperty(keyLower)) { newObj[key] = obj[keyLower]; } } return newObj; }, /* exclude complex objects from $.data() before pass to config */ getConfigData: function($element) { var data = {}; $.each($element.data(), function(k, v) { if(typeof v !== 'object' || (v && typeof v === 'object' && (v.constructor === Object || v.constructor === Array))) { data[k] = v; } }); return data; }, /* returns keys of object */ objectKeys: function(o) { if (Object.keys) { return Object.keys(o); } else { if (o !== Object(o)) { throw new TypeError('Object.keys called on a non-object'); } var k=[], p; for (p in o) { if (Object.prototype.hasOwnProperty.call(o,p)) { k.push(p); } } return k; } }, /** method to escape html. **/ escape: function(str) { return $('<div>').text(str).html(); }, /* returns array items from sourceData having value property equal or inArray of 'value' */ itemsByValue: function(value, sourceData, valueProp) { if(!sourceData || value === null) { return []; } if (typeof(valueProp) !== "function") { var idKey = valueProp || 'value'; valueProp = function (e) { return e[idKey]; }; } var isValArray = $.isArray(value), result = [], that = this; $.each(sourceData, function(i, o) { if(o.children) { result = result.concat(that.itemsByValue(value, o.children, valueProp)); } else { /*jslint eqeq: true*/ if(isValArray) { if($.grep(value, function(v){ return v == (o && typeof o === 'object' ? valueProp(o) : o); }).length) { result.push(o); } } else { var itemValue = (o && (typeof o === 'object')) ? valueProp(o) : o; if(value == itemValue) { result.push(o); } } /*jslint eqeq: false*/ } }); return result; }, /* Returns input by options: type, mode. */ createInput: function(options) { var TypeConstructor, typeOptions, input, type = options.type; //`date` is some kind of virtual type that is transformed to one of exact types //depending on mode and core lib if(type === 'date') { //inline if(options.mode === 'inline') { if($.fn.editabletypes.datefield) { type = 'datefield'; } else if($.fn.editabletypes.dateuifield) { type = 'dateuifield'; } //popup } else { if($.fn.editabletypes.date) { type = 'date'; } else if($.fn.editabletypes.dateui) { type = 'dateui'; } } //if type still `date` and not exist in types, replace with `combodate` that is base input if(type === 'date' && !$.fn.editabletypes.date) { type = 'combodate'; } } //`datetime` should be datetimefield in 'inline' mode if(type === 'datetime' && options.mode === 'inline') { type = 'datetimefield'; } //change wysihtml5 to textarea for jquery UI and plain versions if(type === 'wysihtml5' && !$.fn.editabletypes[type]) { type = 'textarea'; } //create input of specified type. Input will be used for converting value, not in form if(typeof $.fn.editabletypes[type] === 'function') { TypeConstructor = $.fn.editabletypes[type]; typeOptions = this.sliceObj(options, this.objectKeys(TypeConstructor.defaults)); input = new TypeConstructor(typeOptions); return input; } else { $.error('Unknown type: '+ type); return false; } }, //see http://stackoverflow.com/questions/7264899/detect-css-transitions-using-javascript-and-without-modernizr supportsTransitions: function () { var b = document.body || document.documentElement, s = b.style, p = 'transition', v = ['Moz', 'Webkit', 'Khtml', 'O', 'ms']; if(typeof s[p] === 'string') { return true; } // Tests for vendor specific prop p = p.charAt(0).toUpperCase() + p.substr(1); for(var i=0; i<v.length; i++) { if(typeof s[v[i] + p] === 'string') { return true; } } return false; } }; }(window.jQuery)); /** Attaches stand-alone container with editable-form to HTML element. Element is used only for positioning, value is not stored anywhere.<br> This method applied internally in <code>$().editable()</code>. You should subscribe on it's events (save / cancel) to get profit of it.<br> Final realization can be different: bootstrap-popover, jqueryui-tooltip, poshytip, inline-div. It depends on which js file you include.<br> Applied as jQuery method. @class editableContainer @uses editableform **/ (function ($) { "use strict"; var Popup = function (element, options) { this.init(element, options); }; var Inline = function (element, options) { this.init(element, options); }; //methods Popup.prototype = { containerName: null, //method to call container on element containerDataName: null, //object name in element's .data() innerCss: null, //tbd in child class containerClass: 'editable-container editable-popup', //css class applied to container element defaults: {}, //container itself defaults init: function(element, options) { this.$element = $(element); //since 1.4.1 container do not use data-* directly as they already merged into options. this.options = $.extend({}, $.fn.editableContainer.defaults, options); this.splitOptions(); //set scope of form callbacks to element this.formOptions.scope = this.$element[0]; this.initContainer(); //flag to hide container, when saving value will finish this.delayedHide = false; //bind 'destroyed' listener to destroy container when element is removed from dom this.$element.on('destroyed', $.proxy(function(){ this.destroy(); }, this)); //attach document handler to close containers on click / escape if(!$(document).data('editable-handlers-attached')) { //close all on escape $(document).on('keyup.editable', function (e) { if (e.which === 27) { $('.editable-open').editableContainer('hide'); //todo: return focus on element } }); //close containers when click outside //(mousedown could be better than click, it closes everything also on drag drop) $(document).on('click.editable', function(e) { var $target = $(e.target), i, exclude_classes = ['.editable-container', '.ui-datepicker-header', '.datepicker', //in inline mode datepicker is rendered into body '.modal-backdrop', '.bootstrap-wysihtml5-insert-image-modal', '.bootstrap-wysihtml5-insert-link-modal' ]; //check if element is detached. It occurs when clicking in bootstrap datepicker if (!$.contains(document.documentElement, e.target)) { return; } //for some reason FF 20 generates extra event (click) in select2 widget with e.target = document //we need to filter it via construction below. See https://github.com/vitalets/x-editable/issues/199 //Possibly related to http://stackoverflow.com/questions/10119793/why-does-firefox-react-differently-from-webkit-and-ie-to-click-event-on-selec if($target.is(document)) { return; } //if click inside one of exclude classes --> no nothing for(i=0; i<exclude_classes.length; i++) { if($target.is(exclude_classes[i]) || $target.parents(exclude_classes[i]).length) { return; } } //close all open containers (except one - target) Popup.prototype.closeOthers(e.target); }); $(document).data('editable-handlers-attached', true); } }, //split options on containerOptions and formOptions splitOptions: function() { this.containerOptions = {}; this.formOptions = {}; if(!$.fn[this.containerName]) { throw new Error(this.containerName + ' not found. Have you included corresponding js file?'); } //keys defined in container defaults go to container, others go to form for(var k in this.options) { if(k in this.defaults) { this.containerOptions[k] = this.options[k]; } else { this.formOptions[k] = this.options[k]; } } }, /* Returns jquery object of container @method tip() */ tip: function() { return this.container() ? this.container().$tip : null; }, /* returns container object */ container: function() { var container; //first, try get it by `containerDataName` if(this.containerDataName) { if(container = this.$element.data(this.containerDataName)) { return container; } } //second, try `containerName` container = this.$element.data(this.containerName); return container; }, /* call native method of underlying container, e.g. this.$element.popover('method') */ call: function() { this.$element[this.containerName].apply(this.$element, arguments); }, initContainer: function(){ this.call(this.containerOptions); }, renderForm: function() { this.$form .editableform(this.formOptions) .on({ save: $.proxy(this.save, this), //click on submit button (value changed) nochange: $.proxy(function(){ this.hide('nochange'); }, this), //click on submit button (value NOT changed) cancel: $.proxy(function(){ this.hide('cancel'); }, this), //click on calcel button show: $.proxy(function() { if(this.delayedHide) { this.hide(this.delayedHide.reason); this.delayedHide = false; } else { this.setPosition(); } }, this), //re-position container every time form is shown (occurs each time after loading state) rendering: $.proxy(this.setPosition, this), //this allows to place container correctly when loading shown resize: $.proxy(this.setPosition, this), //this allows to re-position container when form size is changed rendered: $.proxy(function(){ /** Fired when container is shown and form is rendered (for select will wait for loading dropdown options). **Note:** Bootstrap popover has own `shown` event that now cannot be separated from x-editable's one. The workaround is to check `arguments.length` that is always `2` for x-editable. @event shown @param {Object} event event object @example $('#username').on('shown', function(e, editable) { editable.input.$input.val('overwriting value of input..'); }); **/ /* TODO: added second param mainly to distinguish from bootstrap's shown event. It's a hotfix that will be solved in future versions via namespaced events. */ this.$element.triggerHandler('shown', $(this.options.scope).data('editable')); }, this) }) .editableform('render'); }, /** Shows container with form @method show() @param {boolean} closeAll Whether to close all other editable containers when showing this one. Default true. **/ /* Note: poshytip owerwrites this method totally! */ show: function (closeAll) { this.$element.addClass('editable-open'); if(closeAll !== false) { //close all open containers (except this) this.closeOthers(this.$element[0]); } //show container itself this.innerShow(); this.tip().addClass(this.containerClass); /* Currently, form is re-rendered on every show. The main reason is that we dont know, what will container do with content when closed: remove(), detach() or just hide() - it depends on container. Detaching form itself before hide and re-insert before show is good solution, but visually it looks ugly --> container changes size before hide. */ //if form already exist - delete previous data if(this.$form) { //todo: destroy prev data! //this.$form.destroy(); } this.$form = $('<div>'); //insert form into container body if(this.tip().is(this.innerCss)) { //for inline container this.tip().append(this.$form); } else { this.tip().find(this.innerCss).append(this.$form); } //render form this.renderForm(); }, /** Hides container with form @method hide() @param {string} reason Reason caused hiding. Can be <code>save|cancel|onblur|nochange|undefined (=manual)</code> **/ hide: function(reason) { if(!this.tip() || !this.tip().is(':visible') || !this.$element.hasClass('editable-open')) { return; } //if form is saving value, schedule hide if(this.$form.data('editableform').isSaving) { this.delayedHide = {reason: reason}; return; } else { this.delayedHide = false; } this.$element.removeClass('editable-open'); this.innerHide(); /** Fired when container was hidden. It occurs on both save or cancel. **Note:** Bootstrap popover has own `hidden` event that now cannot be separated from x-editable's one. The workaround is to check `arguments.length` that is always `2` for x-editable. @event hidden @param {object} event event object @param {string} reason Reason caused hiding. Can be <code>save|cancel|onblur|nochange|manual</code> @example $('#username').on('hidden', function(e, reason) { if(reason === 'save' || reason === 'cancel') { //auto-open next editable $(this).closest('tr').next().find('.editable').editable('show'); } }); **/ this.$element.triggerHandler('hidden', reason || 'manual'); }, /* internal show method. To be overwritten in child classes */ innerShow: function () { }, /* internal hide method. To be overwritten in child classes */ innerHide: function () { }, /** Toggles container visibility (show / hide) @method toggle() @param {boolean} closeAll Whether to close all other editable containers when showing this one. Default true. **/ toggle: function(closeAll) { if(this.container() && this.tip() && this.tip().is(':visible')) { this.hide(); } else { this.show(closeAll); } }, /* Updates the position of container when content changed. @method setPosition() */ setPosition: function() { //tbd in child class }, save: function(e, params) { /** Fired when new value was submitted. You can use <code>$(this).data('editableContainer')</code> inside handler to access to editableContainer instance @event save @param {Object} event event object @param {Object} params additional params @param {mixed} params.newValue submitted value @param {Object} params.response ajax response @example $('#username').on('save', function(e, params) { //assuming server response: '{success: true}' var pk = $(this).data('editableContainer').options.pk; if(params.response && params.response.success) { alert('value: ' + params.newValue + ' with pk: ' + pk + ' saved!'); } else { alert('error!'); } }); **/ this.$element.triggerHandler('save', params); //hide must be after trigger, as saving value may require methods of plugin, applied to input this.hide('save'); }, /** Sets new option @method option(key, value) @param {string} key @param {mixed} value **/ option: function(key, value) { this.options[key] = value; if(key in this.containerOptions) { this.containerOptions[key] = value; this.setContainerOption(key, value); } else { this.formOptions[key] = value; if(this.$form) { this.$form.editableform('option', key, value); } } }, setContainerOption: function(key, value) { this.call('option', key, value); }, /** Destroys the container instance @method destroy() **/ destroy: function() { this.hide(); this.innerDestroy(); this.$element.off('destroyed'); this.$element.removeData('editableContainer'); }, /* to be overwritten in child classes */ innerDestroy: function() { }, /* Closes other containers except one related to passed element. Other containers can be cancelled or submitted (depends on onblur option) */ closeOthers: function(element) { $('.editable-open').each(function(i, el){ //do nothing with passed element and it's children if(el === element || $(el).find(element).length) { return; } //otherwise cancel or submit all open containers var $el = $(el), ec = $el.data('editableContainer'); if(!ec) { return; } if(ec.options.onblur === 'cancel') { $el.data('editableContainer').hide('onblur'); } else if(ec.options.onblur === 'submit') { $el.data('editableContainer').tip().find('form').submit(); } }); }, /** Activates input of visible container (e.g. set focus) @method activate() **/ activate: function() { if(this.tip && this.tip().is(':visible') && this.$form) { this.$form.data('editableform').input.activate(); } } }; /** jQuery method to initialize editableContainer. @method $().editableContainer(options) @params {Object} options @example $('#edit').editableContainer({ type: 'text', url: '/post', pk: 1, value: 'hello' }); **/ $.fn.editableContainer = function (option) { var args = arguments; return this.each(function () { var $this = $(this), dataKey = 'editableContainer', data = $this.data(dataKey), options = typeof option === 'object' && option, Constructor = (options.mode === 'inline') ? Inline : Popup; if (!data) { $this.data(dataKey, (data = new Constructor(this, options))); } if (typeof option === 'string') { //call method data[option].apply(data, Array.prototype.slice.call(args, 1)); } }); }; //store constructors $.fn.editableContainer.Popup = Popup; $.fn.editableContainer.Inline = Inline; //defaults $.fn.editableContainer.defaults = { /** Initial value of form input @property value @type mixed @default null @private **/ value: null, /** Placement of container relative to element. Can be <code>top|right|bottom|left</code>. Not used for inline container. @property placement @type string @default 'top' **/ placement: 'top', /** Whether to hide container on save/cancel. @property autohide @type boolean @default true @private **/ autohide: true, /** Action when user clicks outside the container. Can be <code>cancel|submit|ignore</code>. Setting <code>ignore</code> allows to have several containers open. @property onblur @type string @default 'cancel' @since 1.1.1 **/ onblur: 'cancel', /** Animation speed (inline mode only) @property anim @type string @default false **/ anim: false, /** Mode of editable, can be `popup` or `inline` @property mode @type string @default 'popup' @since 1.4.0 **/ mode: 'popup' }; /* * workaround to have 'destroyed' event to destroy popover when element is destroyed * see http://stackoverflow.com/questions/2200494/jquery-trigger-event-when-an-element-is-removed-from-the-dom */ jQuery.event.special.destroyed = { remove: function(o) { if (o.handler) { o.handler(); } } }; }(window.jQuery)); /** * Editable Inline * --------------------- */ (function ($) { "use strict"; //copy prototype from EditableContainer //extend methods $.extend($.fn.editableContainer.Inline.prototype, $.fn.editableContainer.Popup.prototype, { containerName: 'editableform', innerCss: '.editable-inline', containerClass: 'editable-container editable-inline', //css class applied to container element initContainer: function(){ //container is <span> element this.$tip = $('<span></span>'); //convert anim to miliseconds (int) if(!this.options.anim) { this.options.anim = 0; } }, splitOptions: function() { //all options are passed to form this.containerOptions = {}; this.formOptions = this.options; }, tip: function() { return this.$tip; }, innerShow: function () { this.$element.hide(); this.tip().insertAfter(this.$element).show(); }, innerHide: function () { this.$tip.hide(this.options.anim, $.proxy(function() { this.$element.show(); this.innerDestroy(); }, this)); }, innerDestroy: function() { if(this.tip()) { this.tip().empty().remove(); } } }); }(window.jQuery)); /** Makes editable any HTML element on the page. Applied as jQuery method. @class editable @uses editableContainer **/ (function ($) { "use strict"; var Editable = function (element, options) { this.$element = $(element); //data-* has more priority over js options: because dynamically created elements may change data-* this.options = $.extend({}, $.fn.editable.defaults, options, $.fn.editableutils.getConfigData(this.$element)); if(this.options.selector) { this.initLive(); } else { this.init(); } //check for transition support if(this.options.highlight && !$.fn.editableutils.supportsTransitions()) { this.options.highlight = false; } }; Editable.prototype = { constructor: Editable, init: function () { var isValueByText = false, doAutotext, finalize; //name this.options.name = this.options.name || this.$element.attr('id'); //create input of specified type. Input needed already here to convert value for initial display (e.g. show text by id for select) //also we set scope option to have access to element inside input specific callbacks (e. g. source as function) this.options.scope = this.$element[0]; this.input = $.fn.editableutils.createInput(this.options); if(!this.input) { return; } //set value from settings or by element's text if (this.options.value === undefined || this.options.value === null) { this.value = this.input.html2value($.trim(this.$element.html())); isValueByText = true; } else { /* value can be string when received from 'data-value' attribute for complext objects value can be set as json string in data-value attribute, e.g. data-value="{city: 'Moscow', street: 'Lenina'}" */ this.options.value = $.fn.editableutils.tryParseJson(this.options.value, true); if(typeof this.options.value === 'string') { this.value = this.input.str2value(this.options.value); } else { this.value = this.options.value; } } //add 'editable' class to every editable element this.$element.addClass('editable'); //specifically for "textarea" add class .editable-pre-wrapped to keep linebreaks if(this.input.type === 'textarea') { this.$element.addClass('editable-pre-wrapped'); } //attach handler activating editable. In disabled mode it just prevent default action (useful for links) if(this.options.toggle !== 'manual') { this.$element.addClass('editable-click'); this.$element.on(this.options.toggle + '.editable', $.proxy(function(e){ //prevent following link if editable enabled if(!this.options.disabled) { e.preventDefault(); } //stop propagation not required because in document click handler it checks event target //e.stopPropagation(); if(this.options.toggle === 'mouseenter') { //for hover only show container this.show(); } else { //when toggle='click' we should not close all other containers as they will be closed automatically in document click listener var closeAll = (this.options.toggle !== 'click'); this.toggle(closeAll); } }, this)); } else { this.$element.attr('tabindex', -1); //do not stop focus on element when toggled manually } //if display is function it's far more convinient to have autotext = always to render correctly on init //see https://github.com/vitalets/x-editable-yii/issues/34 if(typeof this.options.display === 'function') { this.options.autotext = 'always'; } //check conditions for autotext: switch(this.options.autotext) { case 'always': doAutotext = true; break; case 'auto': //if element text is empty and value is defined and value not generated by text --> run autotext doAutotext = !$.trim(this.$element.text()).length && this.value !== null && this.value !== undefined && !isValueByText; break; default: doAutotext = false; } //depending on autotext run render() or just finilize init $.when(doAutotext ? this.render() : true).then($.proxy(function() { if(this.options.disabled) { this.disable(); } else { this.enable(); } /** Fired when element was initialized by `$().editable()` method. Please note that you should setup `init` handler **before** applying `editable`. @event init @param {Object} event event object @param {Object} editable editable instance (as here it cannot accessed via data('editable')) @since 1.2.0 @example $('#username').on('init', function(e, editable) { alert('initialized ' + editable.options.name); }); $('#username').editable(); **/ this.$element.triggerHandler('init', this); }, this)); }, /* Initializes parent element for live editables */ initLive: function() { //store selector var selector = this.options.selector; //modify options for child elements this.options.selector = false; this.options.autotext = 'never'; //listen toggle events this.$element.on(this.options.toggle + '.editable', selector, $.proxy(function(e){ var $target = $(e.target); if(!$target.data('editable')) { //if delegated element initially empty, we need to clear it's text (that was manually set to `empty` by user) //see https://github.com/vitalets/x-editable/issues/137 if($target.hasClass(this.options.emptyclass)) { $target.empty(); } $target.editable(this.options).trigger(e); } }, this)); }, /* Renders value into element's text. Can call custom display method from options. Can return deferred object. @method render() @param {mixed} response server response (if exist) to pass into display function */ render: function(response) { //do not display anything if(this.options.display === false) { return; } //if input has `value2htmlFinal` method, we pass callback in third param to be called when source is loaded if(this.input.value2htmlFinal) { return this.input.value2html(this.value, this.$element[0], this.options.display, response); //if display method defined --> use it } else if(typeof this.options.display === 'function') { return this.options.display.call(this.$element[0], this.value, response); //else use input's original value2html() method } else { return this.input.value2html(this.value, this.$element[0]); } }, /** Enables editable @method enable() **/ enable: function() { this.options.disabled = false; this.$element.removeClass('editable-disabled'); this.handleEmpty(this.isEmpty); if(this.options.toggle !== 'manual') { if(this.$element.attr('tabindex') === '-1') { this.$element.removeAttr('tabindex'); } } }, /** Disables editable @method disable() **/ disable: function() { this.options.disabled = true; this.hide(); this.$element.addClass('editable-disabled'); this.handleEmpty(this.isEmpty); //do not stop focus on this element this.$element.attr('tabindex', -1); }, /** Toggles enabled / disabled state of editable element @method toggleDisabled() **/ toggleDisabled: function() { if(this.options.disabled) { this.enable(); } else { this.disable(); } }, /** Sets new option @method option(key, value) @param {string|object} key option name or object with several options @param {mixed} value option new value @example $('.editable').editable('option', 'pk', 2); **/ option: function(key, value) { //set option(s) by object if(key && typeof key === 'object') { $.each(key, $.proxy(function(k, v){ this.option($.trim(k), v); }, this)); return; } //set option by string this.options[key] = value; //disabled if(key === 'disabled') { return value ? this.disable() : this.enable(); } //value if(key === 'value') { this.setValue(value); } //transfer new option to container! if(this.container) { this.container.option(key, value); } //pass option to input directly (as it points to the same in form) if(this.input.option) { this.input.option(key, value); } }, /* * set emptytext if element is empty */ handleEmpty: function (isEmpty) { //do not handle empty if we do not display anything if(this.options.display === false) { return; } /* isEmpty may be set directly as param of method. It is required when we enable/disable field and can't rely on content as node content is text: "Empty" that is not empty %) */ if(isEmpty !== undefined) { this.isEmpty = isEmpty; } else { //detect empty //for some inputs we need more smart check //e.g. wysihtml5 may have <br>, <p></p>, <img> if(typeof(this.input.isEmpty) === 'function') { this.isEmpty = this.input.isEmpty(this.$element); } else { this.isEmpty = $.trim(this.$element.html()) === ''; } } //emptytext shown only for enabled if(!this.options.disabled) { if (this.isEmpty) { this.$element.html(this.options.emptytext); if(this.options.emptyclass) { this.$element.addClass(this.options.emptyclass); } } else if(this.options.emptyclass) { this.$element.removeClass(this.options.emptyclass); } } else { //below required if element disable property was changed if(this.isEmpty) { this.$element.empty(); if(this.options.emptyclass) { this.$element.removeClass(this.options.emptyclass); } } } }, /** Shows container with form @method show() @param {boolean} closeAll Whether to close all other editable containers when showing this one. Default true. **/ show: function (closeAll) { if(this.options.disabled) { return; } //init editableContainer: popover, tooltip, inline, etc.. if(!this.container) { var containerOptions = $.extend({}, this.options, { value: this.value, input: this.input //pass input to form (as it is already created) }); this.$element.editableContainer(containerOptions); //listen `save` event this.$element.on("save.internal", $.proxy(this.save, this)); this.container = this.$element.data('editableContainer'); } else if(this.container.tip().is(':visible')) { return; } //show container this.container.show(closeAll); }, /** Hides container with form @method hide() **/ hide: function () { if(this.container) { this.container.hide(); } }, /** Toggles container visibility (show / hide) @method toggle() @param {boolean} closeAll Whether to close all other editable containers when showing this one. Default true. **/ toggle: function(closeAll) { if(this.container && this.container.tip().is(':visible')) { this.hide(); } else { this.show(closeAll); } }, /* * called when form was submitted */ save: function(e, params) { //mark element with unsaved class if needed if(this.options.unsavedclass) { /* Add unsaved css to element if: - url is not user's function - value was not sent to server - params.response === undefined, that means data was not sent - value changed */ var sent = false; sent = sent || typeof this.options.url === 'function'; sent = sent || this.options.display === false; sent = sent || params.response !== undefined; sent = sent || (this.options.savenochange && this.input.value2str(this.value) !== this.input.value2str(params.newValue)); if(sent) { this.$element.removeClass(this.options.unsavedclass); } else { this.$element.addClass(this.options.unsavedclass); } } //highlight when saving if(this.options.highlight) { var $e = this.$element, bgColor = $e.css('background-color'); $e.css('background-color', this.options.highlight); setTimeout(function(){ if(bgColor === 'transparent') { bgColor = ''; } $e.css('background-color', bgColor); $e.addClass('editable-bg-transition'); setTimeout(function(){ $e.removeClass('editable-bg-transition'); }, 1700); }, 10); } //set new value this.setValue(params.newValue, false, params.response); /** Fired when new value was submitted. You can use <code>$(this).data('editable')</code> to access to editable instance @event save @param {Object} event event object @param {Object} params additional params @param {mixed} params.newValue submitted value @param {Object} params.response ajax response @example $('#username').on('save', function(e, params) { alert('Saved value: ' + params.newValue); }); **/ //event itself is triggered by editableContainer. Description here is only for documentation }, validate: function () { if (typeof this.options.validate === 'function') { return this.options.validate.call(this, this.value); } }, /** Sets new value of editable @method setValue(value, convertStr) @param {mixed} value new value @param {boolean} convertStr whether to convert value from string to internal format **/ setValue: function(value, convertStr, response) { if(convertStr) { this.value = this.input.str2value(value); } else { this.value = value; } if(this.container) { this.container.option('value', this.value); } $.when(this.render(response)) .then($.proxy(function() { this.handleEmpty(); }, this)); }, /** Activates input of visible container (e.g. set focus) @method activate() **/ activate: function() { if(this.container) { this.container.activate(); } }, /** Removes editable feature from element @method destroy() **/ destroy: function() { this.disable(); if(this.container) { this.container.destroy(); } this.input.destroy(); if(this.options.toggle !== 'manual') { this.$element.removeClass('editable-click'); this.$element.off(this.options.toggle + '.editable'); } this.$element.off("save.internal"); this.$element.removeClass('editable editable-open editable-disabled'); this.$element.removeData('editable'); } }; /* EDITABLE PLUGIN DEFINITION * ======================= */ /** jQuery method to initialize editable element. @method $().editable(options) @params {Object} options @example $('#username').editable({ type: 'text', url: '/post', pk: 1 }); **/ $.fn.editable = function (option) { //special API methods returning non-jquery object var result = {}, args = arguments, datakey = 'editable'; switch (option) { /** Runs client-side validation for all matched editables @method validate() @returns {Object} validation errors map @example $('#username, #fullname').editable('validate'); // possible result: { username: "username is required", fullname: "fullname should be minimum 3 letters length" } **/ case 'validate': this.each(function () { var $this = $(this), data = $this.data(datakey), error; if (data && (error = data.validate())) { result[data.options.name] = error; } }); return result; /** Returns current values of editable elements. Note that it returns an **object** with name-value pairs, not a value itself. It allows to get data from several elements. If value of some editable is `null` or `undefined` it is excluded from result object. When param `isSingle` is set to **true** - it is supposed you have single element and will return value of editable instead of object. @method getValue() @param {bool} isSingle whether to return just value of single element @returns {Object} object of element names and values @example $('#username, #fullname').editable('getValue'); //result: { username: "superuser", fullname: "John" } //isSingle = true $('#username').editable('getValue', true); //result "superuser" **/ case 'getValue': if(arguments.length === 2 && arguments[1] === true) { //isSingle = true result = this.eq(0).data(datakey).value; } else { this.each(function () { var $this = $(this), data = $this.data(datakey); if (data && data.value !== undefined && data.value !== null) { result[data.options.name] = data.input.value2submit(data.value); } }); } return result; /** This method collects values from several editable elements and submit them all to server. Internally it runs client-side validation for all fields and submits only in case of success. See <a href="#newrecord">creating new records</a> for details. @method submit(options) @param {object} options @param {object} options.url url to submit data @param {object} options.data additional data to submit @param {object} options.ajaxOptions additional ajax options @param {function} options.error(obj) error handler @param {function} options.success(obj,config) success handler @returns {Object} jQuery object **/ case 'submit': //collects value, validate and submit to server for creating new record var config = arguments[1] || {}, $elems = this, errors = this.editable('validate'), values; if($.isEmptyObject(errors)) { values = this.editable('getValue'); if(config.data) { $.extend(values, config.data); } $.ajax($.extend({ url: config.url, data: values, type: 'POST' }, config.ajaxOptions)) .success(function(response) { //successful response 200 OK if(typeof config.success === 'function') { config.success.call($elems, response, config); } }) .error(function(){ //ajax error if(typeof config.error === 'function') { config.error.apply($elems, arguments); } }); } else { //client-side validation error if(typeof config.error === 'function') { config.error.call($elems, errors); } } return this; } //return jquery object return this.each(function () { var $this = $(this), data = $this.data(datakey), options = typeof option === 'object' && option; //for delegated targets do not store `editable` object for element //it's allows several different selectors. //see: https://github.com/vitalets/x-editable/issues/312 if(options && options.selector) { data = new Editable(this, options); return; } if (!data) { $this.data(datakey, (data = new Editable(this, options))); } if (typeof option === 'string') { //call method data[option].apply(data, Array.prototype.slice.call(args, 1)); } }); }; $.fn.editable.defaults = { /** Type of input. Can be <code>text|textarea|select|date|checklist</code> and more @property type @type string @default 'text' **/ type: 'text', /** Sets disabled state of editable @property disabled @type boolean @default false **/ disabled: false, /** How to toggle editable. Can be <code>click|dblclick|mouseenter|manual</code>. When set to <code>manual</code> you should manually call <code>show/hide</code> methods of editable. **Note**: if you call <code>show</code> or <code>toggle</code> inside **click** handler of some DOM element, you need to apply <code>e.stopPropagation()</code> because containers are being closed on any click on document. @example $('#edit-button').click(function(e) { e.stopPropagation(); $('#username').editable('toggle'); }); @property toggle @type string @default 'click' **/ toggle: 'click', /** Text shown when element is empty. @property emptytext @type string @default 'Empty' **/ emptytext: 'Empty', /** Allows to automatically set element's text based on it's value. Can be <code>auto|always|never</code>. Useful for select and date. For example, if dropdown list is <code>{1: 'a', 2: 'b'}</code> and element's value set to <code>1</code>, it's html will be automatically set to <code>'a'</code>. <code>auto</code> - text will be automatically set only if element is empty. <code>always|never</code> - always(never) try to set element's text. @property autotext @type string @default 'auto' **/ autotext: 'auto', /** Initial value of input. If not set, taken from element's text. Note, that if element's text is empty - text is automatically generated from value and can be customized (see `autotext` option). For example, to display currency sign: @example <a id="price" data-type="text" data-value="100"></a> <script> $('#price').editable({ ... display: function(value) { $(this).text(value + '$'); } }) </script> @property value @type mixed @default element's text **/ value: null, /** Callback to perform custom displaying of value in element's text. If `null`, default input's display used. If `false`, no displaying methods will be called, element's text will never change. Runs under element's scope. _**Parameters:**_ * `value` current value to be displayed * `response` server response (if display called after ajax submit), since 1.4.0 For _inputs with source_ (select, checklist) parameters are different: * `value` current value to be displayed * `sourceData` array of items for current input (e.g. dropdown items) * `response` server response (if display called after ajax submit), since 1.4.0 To get currently selected items use `$.fn.editableutils.itemsByValue(value, sourceData)`. @property display @type function|boolean @default null @since 1.2.0 @example display: function(value, sourceData) { //display checklist as comma-separated values var html = [], checked = $.fn.editableutils.itemsByValue(value, sourceData); if(checked.length) { $.each(checked, function(i, v) { html.push($.fn.editableutils.escape(v.text)); }); $(this).html(html.join(', ')); } else { $(this).empty(); } } **/ display: null, /** Css class applied when editable text is empty. @property emptyclass @type string @since 1.4.1 @default editable-empty **/ emptyclass: 'editable-empty', /** Css class applied when value was stored but not sent to server (`pk` is empty or `send = 'never'`). You may set it to `null` if you work with editables locally and submit them together. @property unsavedclass @type string @since 1.4.1 @default editable-unsaved **/ unsavedclass: 'editable-unsaved', /** If selector is provided, editable will be delegated to the specified targets. Usefull for dynamically generated DOM elements. **Please note**, that delegated targets can't be initialized with `emptytext` and `autotext` options, as they actually become editable only after first click. You should manually set class `editable-click` to these elements. Also, if element originally empty you should add class `editable-empty`, set `data-value=""` and write emptytext into element: @property selector @type string @since 1.4.1 @default null @example <div id="user"> <!-- empty --> <a href="#" data-name="username" data-type="text" class="editable-click editable-empty" data-value="" title="Username">Empty</a> <!-- non-empty --> <a href="#" data-name="group" data-type="select" data-source="/groups" data-value="1" class="editable-click" title="Group">Operator</a> </div> <script> $('#user').editable({ selector: 'a', url: '/post', pk: 1 }); </script> **/ selector: null, /** Color used to highlight element after update. Implemented via CSS3 transition, works in modern browsers. @property highlight @type string|boolean @since 1.4.5 @default #FFFF80 **/ highlight: '#FFFF80' }; }(window.jQuery)); /** AbstractInput - base class for all editable inputs. It defines interface to be implemented by any input type. To create your own input you can inherit from this class. @class abstractinput **/ (function ($) { "use strict"; //types $.fn.editabletypes = {}; var AbstractInput = function () { }; AbstractInput.prototype = { /** Initializes input @method init() **/ init: function(type, options, defaults) { this.type = type; this.options = $.extend({}, defaults, options); }, /* this method called before render to init $tpl that is inserted in DOM */ prerender: function() { this.$tpl = $(this.options.tpl); //whole tpl as jquery object this.$input = this.$tpl; //control itself, can be changed in render method this.$clear = null; //clear button this.error = null; //error message, if input cannot be rendered }, /** Renders input from tpl. Can return jQuery deferred object. Can be overwritten in child objects @method render() **/ render: function() { }, /** Sets element's html by value. @method value2html(value, element) @param {mixed} value @param {DOMElement} element **/ value2html: function(value, element) { $(element)[this.options.escape ? 'text' : 'html']($.trim(value)); }, /** Converts element's html to value @method html2value(html) @param {string} html @returns {mixed} **/ html2value: function(html) { return $('<div>').html(html).text(); }, /** Converts value to string (for internal compare). For submitting to server used value2submit(). @method value2str(value) @param {mixed} value @returns {string} **/ value2str: function(value) { return value; }, /** Converts string received from server into value. Usually from `data-value` attribute. @method str2value(str) @param {string} str @returns {mixed} **/ str2value: function(str) { return str; }, /** Converts value for submitting to server. Result can be string or object. @method value2submit(value) @param {mixed} value @returns {mixed} **/ value2submit: function(value) { return value; }, /** Sets value of input. @method value2input(value) @param {mixed} value **/ value2input: function(value) { this.$input.val(value); }, /** Returns value of input. Value can be object (e.g. datepicker) @method input2value() **/ input2value: function() { return this.$input.val(); }, /** Activates input. For text it sets focus. @method activate() **/ activate: function() { if(this.$input.is(':visible')) { this.$input.focus(); } }, /** Creates input. @method clear() **/ clear: function() { this.$input.val(null); }, /** method to escape html. **/ escape: function(str) { return $('<div>').text(str).html(); }, /** attach handler to automatically submit form when value changed (useful when buttons not shown) **/ autosubmit: function() { }, /** Additional actions when destroying element **/ destroy: function() { }, // -------- helper functions -------- setClass: function() { if(this.options.inputclass) { this.$input.addClass(this.options.inputclass); } }, setAttr: function(attr) { if (this.options[attr] !== undefined && this.options[attr] !== null) { this.$input.attr(attr, this.options[attr]); } }, option: function(key, value) { this.options[key] = value; } }; AbstractInput.defaults = { /** HTML template of input. Normally you should not change it. @property tpl @type string @default '' **/ tpl: '', /** CSS class automatically applied to input @property inputclass @type string @default null **/ inputclass: null, /** If `true` - html will be escaped in content of element via $.text() method. If `false` - html will not be escaped, $.html() used. When you use own `display` function, this option obviosly has no effect. @property escape @type boolean @since 1.5.0 @default true **/ escape: true, //scope for external methods (e.g. source defined as function) //for internal use only scope: null, //need to re-declare showbuttons here to get it's value from common config (passed only options existing in defaults) showbuttons: true }; $.extend($.fn.editabletypes, {abstractinput: AbstractInput}); }(window.jQuery)); /** List - abstract class for inputs that have source option loaded from js array or via ajax @class list @extends abstractinput **/ (function ($) { "use strict"; var List = function (options) { }; $.fn.editableutils.inherit(List, $.fn.editabletypes.abstractinput); $.extend(List.prototype, { render: function () { var deferred = $.Deferred(); this.error = null; this.onSourceReady(function () { this.renderList(); deferred.resolve(); }, function () { this.error = this.options.sourceError; deferred.resolve(); }); return deferred.promise(); }, html2value: function (html) { return null; //can't set value by text }, value2html: function (value, element, display, response) { var deferred = $.Deferred(), success = function () { if(typeof display === 'function') { //custom display method display.call(element, value, this.sourceData, response); } else { this.value2htmlFinal(value, element); } deferred.resolve(); }; //for null value just call success without loading source if(value === null) { success.call(this); } else { this.onSourceReady(success, function () { deferred.resolve(); }); } return deferred.promise(); }, // ------------- additional functions ------------ onSourceReady: function (success, error) { //run source if it function var source; if ($.isFunction(this.options.source)) { source = this.options.source.call(this.options.scope); this.sourceData = null; //note: if function returns the same source as URL - sourceData will be taken from cahce and no extra request performed } else { source = this.options.source; } //if allready loaded just call success if(this.options.sourceCache && $.isArray(this.sourceData)) { success.call(this); return; } //try parse json in single quotes (for double quotes jquery does automatically) try { source = $.fn.editableutils.tryParseJson(source, false); } catch (e) { error.call(this); return; } //loading from url if (typeof source === 'string') { //try to get sourceData from cache if(this.options.sourceCache) { var cacheID = source, cache; if (!$(document).data(cacheID)) { $(document).data(cacheID, {}); } cache = $(document).data(cacheID); //check for cached data if (cache.loading === false && cache.sourceData) { //take source from cache this.sourceData = cache.sourceData; this.doPrepend(); success.call(this); return; } else if (cache.loading === true) { //cache is loading, put callback in stack to be called later cache.callbacks.push($.proxy(function () { this.sourceData = cache.sourceData; this.doPrepend(); success.call(this); }, this)); //also collecting error callbacks cache.err_callbacks.push($.proxy(error, this)); return; } else { //no cache yet, activate it cache.loading = true; cache.callbacks = []; cache.err_callbacks = []; } } //ajaxOptions for source. Can be overwritten bt options.sourceOptions var ajaxOptions = $.extend({ url: source, type: 'get', cache: false, dataType: 'json', success: $.proxy(function (data) { if(cache) { cache.loading = false; } this.sourceData = this.makeArray(data); if($.isArray(this.sourceData)) { if(cache) { //store result in cache cache.sourceData = this.sourceData; //run success callbacks for other fields waiting for this source $.each(cache.callbacks, function () { this.call(); }); } this.doPrepend(); success.call(this); } else { error.call(this); if(cache) { //run error callbacks for other fields waiting for this source $.each(cache.err_callbacks, function () { this.call(); }); } } }, this), error: $.proxy(function () { error.call(this); if(cache) { cache.loading = false; //run error callbacks for other fields $.each(cache.err_callbacks, function () { this.call(); }); } }, this) }, this.options.sourceOptions); //loading sourceData from server $.ajax(ajaxOptions); } else { //options as json/array this.sourceData = this.makeArray(source); if($.isArray(this.sourceData)) { this.doPrepend(); success.call(this); } else { error.call(this); } } }, doPrepend: function () { if(this.options.prepend === null || this.options.prepend === undefined) { return; } if(!$.isArray(this.prependData)) { //run prepend if it is function (once) if ($.isFunction(this.options.prepend)) { this.options.prepend = this.options.prepend.call(this.options.scope); } //try parse json in single quotes this.options.prepend = $.fn.editableutils.tryParseJson(this.options.prepend, true); //convert prepend from string to object if (typeof this.options.prepend === 'string') { this.options.prepend = {'': this.options.prepend}; } this.prependData = this.makeArray(this.options.prepend); } if($.isArray(this.prependData) && $.isArray(this.sourceData)) { this.sourceData = this.prependData.concat(this.sourceData); } }, /* renders input list */ renderList: function() { // this method should be overwritten in child class }, /* set element's html by value */ value2htmlFinal: function(value, element) { // this method should be overwritten in child class }, /** * convert data to array suitable for sourceData, e.g. [{value: 1, text: 'abc'}, {...}] */ makeArray: function(data) { var count, obj, result = [], item, iterateItem; if(!data || typeof data === 'string') { return null; } if($.isArray(data)) { //array /* function to iterate inside item of array if item is object. Caclulates count of keys in item and store in obj. */ iterateItem = function (k, v) { obj = {value: k, text: v}; if(count++ >= 2) { return false;// exit from `each` if item has more than one key. } }; for(var i = 0; i < data.length; i++) { item = data[i]; if(typeof item === 'object') { count = 0; //count of keys inside item $.each(item, iterateItem); //case: [{val1: 'text1'}, {val2: 'text2} ...] if(count === 1) { result.push(obj); //case: [{value: 1, text: 'text1'}, {value: 2, text: 'text2'}, ...] } else if(count > 1) { //removed check of existance: item.hasOwnProperty('value') && item.hasOwnProperty('text') if(item.children) { item.children = this.makeArray(item.children); } result.push(item); } } else { //case: ['text1', 'text2' ...] result.push({value: item, text: item}); } } } else { //case: {val1: 'text1', val2: 'text2, ...} $.each(data, function (k, v) { result.push({value: k, text: v}); }); } return result; }, option: function(key, value) { this.options[key] = value; if(key === 'source') { this.sourceData = null; } if(key === 'prepend') { this.prependData = null; } } }); List.defaults = $.extend({}, $.fn.editabletypes.abstractinput.defaults, { /** Source data for list. If **array** - it should be in format: `[{value: 1, text: "text1"}, {value: 2, text: "text2"}, ...]` For compability, object format is also supported: `{"1": "text1", "2": "text2" ...}` but it does not guarantee elements order. If **string** - considered ajax url to load items. In that case results will be cached for fields with the same source and name. See also `sourceCache` option. If **function**, it should return data in format above (since 1.4.0). Since 1.4.1 key `children` supported to render OPTGROUP (for **select** input only). `[{text: "group1", children: [{value: 1, text: "text1"}, {value: 2, text: "text2"}]}, ...]` @property source @type string | array | object | function @default null **/ source: null, /** Data automatically prepended to the beginning of dropdown list. @property prepend @type string | array | object | function @default false **/ prepend: false, /** Error message when list cannot be loaded (e.g. ajax error) @property sourceError @type string @default Error when loading list **/ sourceError: 'Error when loading list', /** if <code>true</code> and source is **string url** - results will be cached for fields with the same source. Usefull for editable column in grid to prevent extra requests. @property sourceCache @type boolean @default true @since 1.2.0 **/ sourceCache: true, /** Additional ajax options to be used in $.ajax() when loading list from server. Useful to send extra parameters (`data` key) or change request method (`type` key). @property sourceOptions @type object|function @default null @since 1.5.0 **/ sourceOptions: null }); $.fn.editabletypes.list = List; }(window.jQuery)); /** Text input @class text @extends abstractinput @final @example <a href="#" id="username" data-type="text" data-pk="1">awesome</a> <script> $(function(){ $('#username').editable({ url: '/post', title: 'Enter username' }); }); </script> **/ (function ($) { "use strict"; var Text = function (options) { this.init('text', options, Text.defaults); }; $.fn.editableutils.inherit(Text, $.fn.editabletypes.abstractinput); $.extend(Text.prototype, { render: function() { this.renderClear(); this.setClass(); this.setAttr('placeholder'); }, activate: function() { if(this.$input.is(':visible')) { this.$input.focus(); $.fn.editableutils.setCursorPosition(this.$input.get(0), this.$input.val().length); if(this.toggleClear) { this.toggleClear(); } } }, //render clear button renderClear: function() { if (this.options.clear) { this.$clear = $('<span class="editable-clear-x"></span>'); this.$input.after(this.$clear) .css('padding-right', 24) .keyup($.proxy(function(e) { //arrows, enter, tab, etc if(~$.inArray(e.keyCode, [40,38,9,13,27])) { return; } clearTimeout(this.t); var that = this; this.t = setTimeout(function() { that.toggleClear(e); }, 100); }, this)) .parent().css('position', 'relative'); this.$clear.click($.proxy(this.clear, this)); } }, postrender: function() { /* //now `clear` is positioned via css if(this.$clear) { //can position clear button only here, when form is shown and height can be calculated // var h = this.$input.outerHeight(true) || 20, var h = this.$clear.parent().height(), delta = (h - this.$clear.height()) / 2; //this.$clear.css({bottom: delta, right: delta}); } */ }, //show / hide clear button toggleClear: function(e) { if(!this.$clear) { return; } var len = this.$input.val().length, visible = this.$clear.is(':visible'); if(len && !visible) { this.$clear.show(); } if(!len && visible) { this.$clear.hide(); } }, clear: function() { this.$clear.hide(); this.$input.val('').focus(); } }); Text.defaults = $.extend({}, $.fn.editabletypes.abstractinput.defaults, { /** @property tpl @default <input type="text"> **/ tpl: '<input type="text">', /** Placeholder attribute of input. Shown when input is empty. @property placeholder @type string @default null **/ placeholder: null, /** Whether to show `clear` button @property clear @type boolean @default true **/ clear: true }); $.fn.editabletypes.text = Text; }(window.jQuery)); /** Textarea input @class textarea @extends abstractinput @final @example <a href="#" id="comments" data-type="textarea" data-pk="1">awesome comment!</a> <script> $(function(){ $('#comments').editable({ url: '/post', title: 'Enter comments', rows: 10 }); }); </script> **/ (function ($) { "use strict"; var Textarea = function (options) { this.init('textarea', options, Textarea.defaults); }; $.fn.editableutils.inherit(Textarea, $.fn.editabletypes.abstractinput); $.extend(Textarea.prototype, { render: function () { this.setClass(); this.setAttr('placeholder'); this.setAttr('rows'); //ctrl + enter this.$input.keydown(function (e) { if (e.ctrlKey && e.which === 13) { $(this).closest('form').submit(); } }); }, //using `white-space: pre-wrap` solves \n <--> BR conversion very elegant! /* value2html: function(value, element) { var html = '', lines; if(value) { lines = value.split("\n"); for (var i = 0; i < lines.length; i++) { lines[i] = $('<div>').text(lines[i]).html(); } html = lines.join('<br>'); } $(element).html(html); }, html2value: function(html) { if(!html) { return ''; } var regex = new RegExp(String.fromCharCode(10), 'g'); var lines = html.split(/<br\s*\/?>/i); for (var i = 0; i < lines.length; i++) { var text = $('<div>').html(lines[i]).text(); // Remove newline characters (\n) to avoid them being converted by value2html() method // thus adding extra <br> tags text = text.replace(regex, ''); lines[i] = text; } return lines.join("\n"); }, */ activate: function() { $.fn.editabletypes.text.prototype.activate.call(this); } }); Textarea.defaults = $.extend({}, $.fn.editabletypes.abstractinput.defaults, { /** @property tpl @default <textarea></textarea> **/ tpl:'<textarea></textarea>', /** @property inputclass @default input-large **/ inputclass: 'input-large', /** Placeholder attribute of input. Shown when input is empty. @property placeholder @type string @default null **/ placeholder: null, /** Number of rows in textarea @property rows @type integer @default 7 **/ rows: 7 }); $.fn.editabletypes.textarea = Textarea; }(window.jQuery)); /** Select (dropdown) @class select @extends list @final @example <a href="#" id="status" data-type="select" data-pk="1" data-url="/post" data-title="Select status"></a> <script> $(function(){ $('#status').editable({ value: 2, source: [ {value: 1, text: 'Active'}, {value: 2, text: 'Blocked'}, {value: 3, text: 'Deleted'} ] }); }); </script> **/ (function ($) { "use strict"; var Select = function (options) { this.init('select', options, Select.defaults); }; $.fn.editableutils.inherit(Select, $.fn.editabletypes.list); $.extend(Select.prototype, { renderList: function() { this.$input.empty(); var fillItems = function($el, data) { var attr; if($.isArray(data)) { for(var i=0; i<data.length; i++) { attr = {}; if(data[i].children) { attr.label = data[i].text; $el.append(fillItems($('<optgroup>', attr), data[i].children)); } else { attr.value = data[i].value; if(data[i].disabled) { attr.disabled = true; } $el.append($('<option>', attr).text(data[i].text)); } } } return $el; }; fillItems(this.$input, this.sourceData); this.setClass(); //enter submit this.$input.on('keydown.editable', function (e) { if (e.which === 13) { $(this).closest('form').submit(); } }); }, value2htmlFinal: function(value, element) { var text = '', items = $.fn.editableutils.itemsByValue(value, this.sourceData); if(items.length) { text = items[0].text; } //$(element).text(text); $.fn.editabletypes.abstractinput.prototype.value2html.call(this, text, element); }, autosubmit: function() { this.$input.off('keydown.editable').on('change.editable', function(){ $(this).closest('form').submit(); }); } }); Select.defaults = $.extend({}, $.fn.editabletypes.list.defaults, { /** @property tpl @default <select></select> **/ tpl:'<select></select>' }); $.fn.editabletypes.select = Select; }(window.jQuery)); /** List of checkboxes. Internally value stored as javascript array of values. @class checklist @extends list @final @example <a href="#" id="options" data-type="checklist" data-pk="1" data-url="/post" data-title="Select options"></a> <script> $(function(){ $('#options').editable({ value: [2, 3], source: [ {value: 1, text: 'option1'}, {value: 2, text: 'option2'}, {value: 3, text: 'option3'} ] }); }); </script> **/ (function ($) { "use strict"; var Checklist = function (options) { this.init('checklist', options, Checklist.defaults); }; $.fn.editableutils.inherit(Checklist, $.fn.editabletypes.list); $.extend(Checklist.prototype, { renderList: function() { var $label, $div; this.$tpl.empty(); if(!$.isArray(this.sourceData)) { return; } for(var i=0; i<this.sourceData.length; i++) { $label = $('<label>').append($('<input>', { type: 'checkbox', value: this.sourceData[i].value })) .append($('<span>').text(' '+this.sourceData[i].text)); $('<div>').append($label).appendTo(this.$tpl); } this.$input = this.$tpl.find('input[type="checkbox"]'); this.setClass(); }, value2str: function(value) { return $.isArray(value) ? value.sort().join($.trim(this.options.separator)) : ''; }, //parse separated string str2value: function(str) { var reg, value = null; if(typeof str === 'string' && str.length) { reg = new RegExp('\\s*'+$.trim(this.options.separator)+'\\s*'); value = str.split(reg); } else if($.isArray(str)) { value = str; } else { value = [str]; } return value; }, //set checked on required checkboxes value2input: function(value) { this.$input.prop('checked', false); if($.isArray(value) && value.length) { this.$input.each(function(i, el) { var $el = $(el); // cannot use $.inArray as it performs strict comparison $.each(value, function(j, val){ /*jslint eqeq: true*/ if($el.val() == val) { /*jslint eqeq: false*/ $el.prop('checked', true); } }); }); } }, input2value: function() { var checked = []; this.$input.filter(':checked').each(function(i, el) { checked.push($(el).val()); }); return checked; }, //collect text of checked boxes value2htmlFinal: function(value, element) { var html = [], checked = $.fn.editableutils.itemsByValue(value, this.sourceData), escape = this.options.escape; if(checked.length) { $.each(checked, function(i, v) { var text = escape ? $.fn.editableutils.escape(v.text) : v.text; html.push(text); }); $(element).html(html.join('<br>')); } else { $(element).empty(); } }, activate: function() { this.$input.first().focus(); }, autosubmit: function() { this.$input.on('keydown', function(e){ if (e.which === 13) { $(this).closest('form').submit(); } }); } }); Checklist.defaults = $.extend({}, $.fn.editabletypes.list.defaults, { /** @property tpl @default <div></div> **/ tpl:'<div class="editable-checklist"></div>', /** @property inputclass @type string @default null **/ inputclass: null, /** Separator of values when reading from `data-value` attribute @property separator @type string @default ',' **/ separator: ',' }); $.fn.editabletypes.checklist = Checklist; }(window.jQuery)); /** HTML5 input types. Following types are supported: * password * email * url * tel * number * range * time Learn more about html5 inputs: http://www.w3.org/wiki/HTML5_form_additions To check browser compatibility please see: https://developer.mozilla.org/en-US/docs/HTML/Element/Input @class html5types @extends text @final @since 1.3.0 @example <a href="#" id="email" data-type="email" data-pk="1">[email protected]</a> <script> $(function(){ $('#email').editable({ url: '/post', title: 'Enter email' }); }); </script> **/ /** @property tpl @default depends on type **/ /* Password */ (function ($) { "use strict"; var Password = function (options) { this.init('password', options, Password.defaults); }; $.fn.editableutils.inherit(Password, $.fn.editabletypes.text); $.extend(Password.prototype, { //do not display password, show '[hidden]' instead value2html: function(value, element) { if(value) { $(element).text('[hidden]'); } else { $(element).empty(); } }, //as password not displayed, should not set value by html html2value: function(html) { return null; } }); Password.defaults = $.extend({}, $.fn.editabletypes.text.defaults, { tpl: '<input type="password">' }); $.fn.editabletypes.password = Password; }(window.jQuery)); /* Email */ (function ($) { "use strict"; var Email = function (options) { this.init('email', options, Email.defaults); }; $.fn.editableutils.inherit(Email, $.fn.editabletypes.text); Email.defaults = $.extend({}, $.fn.editabletypes.text.defaults, { tpl: '<input type="email">' }); $.fn.editabletypes.email = Email; }(window.jQuery)); /* Url */ (function ($) { "use strict"; var Url = function (options) { this.init('url', options, Url.defaults); }; $.fn.editableutils.inherit(Url, $.fn.editabletypes.text); Url.defaults = $.extend({}, $.fn.editabletypes.text.defaults, { tpl: '<input type="url">' }); $.fn.editabletypes.url = Url; }(window.jQuery)); /* Tel */ (function ($) { "use strict"; var Tel = function (options) { this.init('tel', options, Tel.defaults); }; $.fn.editableutils.inherit(Tel, $.fn.editabletypes.text); Tel.defaults = $.extend({}, $.fn.editabletypes.text.defaults, { tpl: '<input type="tel">' }); $.fn.editabletypes.tel = Tel; }(window.jQuery)); /* Number */ (function ($) { "use strict"; var NumberInput = function (options) { this.init('number', options, NumberInput.defaults); }; $.fn.editableutils.inherit(NumberInput, $.fn.editabletypes.text); $.extend(NumberInput.prototype, { render: function () { NumberInput.superclass.render.call(this); this.setAttr('min'); this.setAttr('max'); this.setAttr('step'); }, postrender: function() { if(this.$clear) { //increase right ffset for up/down arrows this.$clear.css({right: 24}); /* //can position clear button only here, when form is shown and height can be calculated var h = this.$input.outerHeight(true) || 20, delta = (h - this.$clear.height()) / 2; //add 12px to offset right for up/down arrows this.$clear.css({top: delta, right: delta + 16}); */ } } }); NumberInput.defaults = $.extend({}, $.fn.editabletypes.text.defaults, { tpl: '<input type="number">', inputclass: 'input-mini', min: null, max: null, step: null }); $.fn.editabletypes.number = NumberInput; }(window.jQuery)); /* Range (inherit from number) */ (function ($) { "use strict"; var Range = function (options) { this.init('range', options, Range.defaults); }; $.fn.editableutils.inherit(Range, $.fn.editabletypes.number); $.extend(Range.prototype, { render: function () { this.$input = this.$tpl.filter('input'); this.setClass(); this.setAttr('min'); this.setAttr('max'); this.setAttr('step'); this.$input.on('input', function(){ $(this).siblings('output').text($(this).val()); }); }, activate: function() { this.$input.focus(); } }); Range.defaults = $.extend({}, $.fn.editabletypes.number.defaults, { tpl: '<input type="range"><output style="width: 30px; display: inline-block"></output>', inputclass: 'input-medium' }); $.fn.editabletypes.range = Range; }(window.jQuery)); /* Time */ (function ($) { "use strict"; var Time = function (options) { this.init('time', options, Time.defaults); }; //inherit from abstract, as inheritance from text gives selection error. $.fn.editableutils.inherit(Time, $.fn.editabletypes.abstractinput); $.extend(Time.prototype, { render: function() { this.setClass(); } }); Time.defaults = $.extend({}, $.fn.editabletypes.abstractinput.defaults, { tpl: '<input type="time">' }); $.fn.editabletypes.time = Time; }(window.jQuery)); /** Select2 input. Based on amazing work of Igor Vaynberg https://github.com/ivaynberg/select2. Please see [original select2 docs](http://ivaynberg.github.com/select2) for detailed description and options. You should manually download and include select2 distributive: <link href="select2/select2.css" rel="stylesheet" type="text/css"></link> <script src="select2/select2.js"></script> To make it **bootstrap-styled** you can use css from [here](https://github.com/t0m/select2-bootstrap-css): <link href="select2-bootstrap.css" rel="stylesheet" type="text/css"></link> **Note:** currently `autotext` feature does not work for select2 with `ajax` remote source. You need initially put both `data-value` and element's text youself: <a href="#" data-type="select2" data-value="1">Text1</a> @class select2 @extends abstractinput @since 1.4.1 @final @example <a href="#" id="country" data-type="select2" data-pk="1" data-value="ru" data-url="/post" data-title="Select country"></a> <script> $(function(){ //local source $('#country').editable({ source: [ {id: 'gb', text: 'Great Britain'}, {id: 'us', text: 'United States'}, {id: 'ru', text: 'Russia'} ], select2: { multiple: true } }); //remote source (simple) $('#country').editable({ source: '/getCountries' }); //remote source (advanced) $('#country').editable({ select2: { placeholder: 'Select Country', allowClear: true, minimumInputLength: 3, id: function (item) { return item.CountryId; }, ajax: { url: '/getCountries', dataType: 'json', data: function (term, page) { return { query: term }; }, results: function (data, page) { return { results: data }; } }, formatResult: function (item) { return item.CountryName; }, formatSelection: function (item) { return item.CountryName; }, initSelection: function (element, callback) { return $.get('/getCountryById', { query: element.val() }, function (data) { callback(data); }); } } }); }); </script> **/ (function ($) { "use strict"; var Constructor = function (options) { this.init('select2', options, Constructor.defaults); options.select2 = options.select2 || {}; this.sourceData = null; //placeholder if(options.placeholder) { options.select2.placeholder = options.placeholder; } //if not `tags` mode, use source if(!options.select2.tags && options.source) { var source = options.source; //if source is function, call it (once!) if ($.isFunction(options.source)) { source = options.source.call(options.scope); } if (typeof source === 'string') { options.select2.ajax = options.select2.ajax || {}; //some default ajax params if(!options.select2.ajax.data) { options.select2.ajax.data = function(term) {return { query:term };}; } if(!options.select2.ajax.results) { options.select2.ajax.results = function(data) { return {results:data };}; } options.select2.ajax.url = source; } else { //check format and convert x-editable format to select2 format (if needed) this.sourceData = this.convertSource(source); options.select2.data = this.sourceData; } } //overriding objects in config (as by default jQuery extend() is not recursive) this.options.select2 = $.extend({}, Constructor.defaults.select2, options.select2); //detect whether it is multi-valued this.isMultiple = this.options.select2.tags || this.options.select2.multiple; this.isRemote = ('ajax' in this.options.select2); //store function returning ID of item //should be here as used inautotext for local source this.idFunc = this.options.select2.id; if (typeof(this.idFunc) !== "function") { var idKey = this.idFunc || 'id'; this.idFunc = function (e) { return e[idKey]; }; } //store function that renders text in select2 this.formatSelection = this.options.select2.formatSelection; if (typeof(this.formatSelection) !== "function") { this.formatSelection = function (e) { return e.text; }; } }; $.fn.editableutils.inherit(Constructor, $.fn.editabletypes.abstractinput); $.extend(Constructor.prototype, { render: function() { this.setClass(); //can not apply select2 here as it calls initSelection //over input that does not have correct value yet. //apply select2 only in value2input //this.$input.select2(this.options.select2); //when data is loaded via ajax, we need to know when it's done to populate listData if(this.isRemote) { //listen to loaded event to populate data this.$input.on('select2-loaded', $.proxy(function(e) { this.sourceData = e.items.results; }, this)); } //trigger resize of editableform to re-position container in multi-valued mode if(this.isMultiple) { this.$input.on('change', function() { $(this).closest('form').parent().triggerHandler('resize'); }); } }, value2html: function(value, element) { var text = '', data, that = this; if(this.options.select2.tags) { //in tags mode just assign value data = value; //data = $.fn.editableutils.itemsByValue(value, this.options.select2.tags, this.idFunc); } else if(this.sourceData) { data = $.fn.editableutils.itemsByValue(value, this.sourceData, this.idFunc); } else { //can not get list of possible values //(e.g. autotext for select2 with ajax source) } //data may be array (when multiple values allowed) if($.isArray(data)) { //collect selected data and show with separator text = []; $.each(data, function(k, v){ text.push(v && typeof v === 'object' ? that.formatSelection(v) : v); }); } else if(data) { text = that.formatSelection(data); } text = $.isArray(text) ? text.join(this.options.viewseparator) : text; //$(element).text(text); Constructor.superclass.value2html.call(this, text, element); }, html2value: function(html) { return this.options.select2.tags ? this.str2value(html, this.options.viewseparator) : null; }, value2input: function(value) { //for local source use data directly from source (to allow autotext) /* if(!this.isRemote && !this.isMultiple) { var items = $.fn.editableutils.itemsByValue(value, this.sourceData, this.idFunc); if(items.length) { this.$input.select2('data', items[0]); return; } } */ //for remote source just set value, text is updated by initSelection if(!this.$input.data('select2')) { this.$input.val(value); this.$input.select2(this.options.select2); } else { //second argument needed to separate initial change from user's click (for autosubmit) this.$input.val(value).trigger('change', true); } //if remote source AND no user's initSelection provided --> try to use element's text if(this.isRemote && !this.isMultiple && !this.options.select2.initSelection) { var customId = this.options.select2.id, customText = this.options.select2.formatSelection; if(!customId && !customText) { var data = {id: value, text: $(this.options.scope).text()}; this.$input.select2('data', data); } } }, input2value: function() { return this.$input.select2('val'); }, str2value: function(str, separator) { if(typeof str !== 'string' || !this.isMultiple) { return str; } separator = separator || this.options.select2.separator || $.fn.select2.defaults.separator; var val, i, l; if (str === null || str.length < 1) { return null; } val = str.split(separator); for (i = 0, l = val.length; i < l; i = i + 1) { val[i] = $.trim(val[i]); } return val; }, autosubmit: function() { this.$input.on('change', function(e, isInitial){ if(!isInitial) { $(this).closest('form').submit(); } }); }, /* Converts source from x-editable format: {value: 1, text: "1"} to select2 format: {id: 1, text: "1"} */ convertSource: function(source) { if($.isArray(source) && source.length && source[0].value !== undefined) { for(var i = 0; i<source.length; i++) { if(source[i].value !== undefined) { source[i].id = source[i].value; delete source[i].value; } } } return source; }, destroy: function() { if(this.$input.data('select2')) { this.$input.select2('destroy'); } } }); Constructor.defaults = $.extend({}, $.fn.editabletypes.abstractinput.defaults, { /** @property tpl @default <input type="hidden"> **/ tpl:'<input type="hidden">', /** Configuration of select2. [Full list of options](http://ivaynberg.github.com/select2). @property select2 @type object @default null **/ select2: null, /** Placeholder attribute of select @property placeholder @type string @default null **/ placeholder: null, /** Source data for select. It will be assigned to select2 `data` property and kept here just for convenience. Please note, that format is different from simple `select` input: use 'id' instead of 'value'. E.g. `[{id: 1, text: "text1"}, {id: 2, text: "text2"}, ...]`. @property source @type array|string|function @default null **/ source: null, /** Separator used to display tags. @property viewseparator @type string @default ', ' **/ viewseparator: ', ' }); $.fn.editabletypes.select2 = Constructor; }(window.jQuery)); /** * Combodate - 1.0.4 * Dropdown date and time picker. * Converts text input into dropdowns to pick day, month, year, hour, minute and second. * Uses momentjs as datetime library http://momentjs.com. * For internalization include corresponding file from https://github.com/timrwood/moment/tree/master/lang * * Confusion at noon and midnight - see http://en.wikipedia.org/wiki/12-hour_clock#Confusion_at_noon_and_midnight * In combodate: * 12:00 pm --> 12:00 (24-h format, midday) * 12:00 am --> 00:00 (24-h format, midnight, start of day) * * Differs from momentjs parse rules: * 00:00 pm, 12:00 pm --> 12:00 (24-h format, day not change) * 00:00 am, 12:00 am --> 00:00 (24-h format, day not change) * * * Author: Vitaliy Potapov * Project page: http://github.com/vitalets/combodate * Copyright (c) 2012 Vitaliy Potapov. Released under MIT License. **/ (function ($) { var Combodate = function (element, options) { this.$element = $(element); if(!this.$element.is('input')) { $.error('Combodate should be applied to INPUT element'); return; } this.options = $.extend({}, $.fn.combodate.defaults, options, this.$element.data()); this.init(); }; Combodate.prototype = { constructor: Combodate, init: function () { this.map = { //key regexp moment.method day: ['D', 'date'], month: ['M', 'month'], year: ['Y', 'year'], hour: ['[Hh]', 'hours'], minute: ['m', 'minutes'], second: ['s', 'seconds'], ampm: ['[Aa]', ''] }; this.$widget = $('<span class="combodate"></span>').html(this.getTemplate()); this.initCombos(); //update original input on change this.$widget.on('change', 'select', $.proxy(function(){ this.$element.val(this.getValue()); }, this)); this.$widget.find('select').css('width', 'auto'); //hide original input and insert widget this.$element.hide().after(this.$widget); //set initial value this.setValue(this.$element.val() || this.options.value); }, /* Replace tokens in template with <select> elements */ getTemplate: function() { var tpl = this.options.template; //first pass $.each(this.map, function(k, v) { v = v[0]; var r = new RegExp(v+'+'), token = v.length > 1 ? v.substring(1, 2) : v; tpl = tpl.replace(r, '{'+token+'}'); }); //replace spaces with &nbsp; tpl = tpl.replace(/ /g, '&nbsp;'); //second pass $.each(this.map, function(k, v) { v = v[0]; var token = v.length > 1 ? v.substring(1, 2) : v; tpl = tpl.replace('{'+token+'}', '<select class="'+k+'"></select>'); }); return tpl; }, /* Initialize combos that presents in template */ initCombos: function() { var that = this; $.each(this.map, function(k, v) { var $c = that.$widget.find('.'+k), f, items; if($c.length) { that['$'+k] = $c; //set properties like this.$day, this.$month etc. f = 'fill' + k.charAt(0).toUpperCase() + k.slice(1); //define method name to fill items, e.g `fillDays` items = that[f](); that['$'+k].html(that.renderItems(items)); } }); }, /* Initialize items of combos. Handles `firstItem` option */ initItems: function(key) { var values = [], relTime; if(this.options.firstItem === 'name') { //need both to support moment ver < 2 and >= 2 relTime = moment.relativeTime || moment.langData()._relativeTime; var header = typeof relTime[key] === 'function' ? relTime[key](1, true, key, false) : relTime[key]; //take last entry (see momentjs lang files structure) header = header.split(' ').reverse()[0]; values.push(['', header]); } else if(this.options.firstItem === 'empty') { values.push(['', '']); } return values; }, /* render items to string of <option> tags */ renderItems: function(items) { var str = []; for(var i=0; i<items.length; i++) { str.push('<option value="'+items[i][0]+'">'+items[i][1]+'</option>'); } return str.join("\n"); }, /* fill day */ fillDay: function() { var items = this.initItems('d'), name, i, twoDigit = this.options.template.indexOf('DD') !== -1; for(i=1; i<=31; i++) { name = twoDigit ? this.leadZero(i) : i; items.push([i, name]); } return items; }, /* fill month */ fillMonth: function() { var items = this.initItems('M'), name, i, longNames = this.options.template.indexOf('MMMM') !== -1, shortNames = this.options.template.indexOf('MMM') !== -1, twoDigit = this.options.template.indexOf('MM') !== -1; for(i=0; i<=11; i++) { if(longNames) { //see https://github.com/timrwood/momentjs.com/pull/36 name = moment().date(1).month(i).format('MMMM'); } else if(shortNames) { name = moment().date(1).month(i).format('MMM'); } else if(twoDigit) { name = this.leadZero(i+1); } else { name = i+1; } items.push([i, name]); } return items; }, /* fill year */ fillYear: function() { var items = [], name, i, longNames = this.options.template.indexOf('YYYY') !== -1; for(i=this.options.maxYear; i>=this.options.minYear; i--) { name = longNames ? i : (i+'').substring(2); items[this.options.yearDescending ? 'push' : 'unshift']([i, name]); } items = this.initItems('y').concat(items); return items; }, /* fill hour */ fillHour: function() { var items = this.initItems('h'), name, i, h12 = this.options.template.indexOf('h') !== -1, h24 = this.options.template.indexOf('H') !== -1, twoDigit = this.options.template.toLowerCase().indexOf('hh') !== -1, min = h12 ? 1 : 0, max = h12 ? 12 : 23; for(i=min; i<=max; i++) { name = twoDigit ? this.leadZero(i) : i; items.push([i, name]); } return items; }, /* fill minute */ fillMinute: function() { var items = this.initItems('m'), name, i, twoDigit = this.options.template.indexOf('mm') !== -1; for(i=0; i<=59; i+= this.options.minuteStep) { name = twoDigit ? this.leadZero(i) : i; items.push([i, name]); } return items; }, /* fill second */ fillSecond: function() { var items = this.initItems('s'), name, i, twoDigit = this.options.template.indexOf('ss') !== -1; for(i=0; i<=59; i+= this.options.secondStep) { name = twoDigit ? this.leadZero(i) : i; items.push([i, name]); } return items; }, /* fill ampm */ fillAmpm: function() { var ampmL = this.options.template.indexOf('a') !== -1, ampmU = this.options.template.indexOf('A') !== -1, items = [ ['am', ampmL ? 'am' : 'AM'], ['pm', ampmL ? 'pm' : 'PM'] ]; return items; }, /* Returns current date value from combos. If format not specified - `options.format` used. If format = `null` - Moment object returned. */ getValue: function(format) { var dt, values = {}, that = this, notSelected = false; //getting selected values $.each(this.map, function(k, v) { if(k === 'ampm') { return; } var def = k === 'day' ? 1 : 0; values[k] = that['$'+k] ? parseInt(that['$'+k].val(), 10) : def; if(isNaN(values[k])) { notSelected = true; return false; } }); //if at least one visible combo not selected - return empty string if(notSelected) { return ''; } //convert hours 12h --> 24h if(this.$ampm) { //12:00 pm --> 12:00 (24-h format, midday), 12:00 am --> 00:00 (24-h format, midnight, start of day) if(values.hour === 12) { values.hour = this.$ampm.val() === 'am' ? 0 : 12; } else { values.hour = this.$ampm.val() === 'am' ? values.hour : values.hour+12; } } dt = moment([values.year, values.month, values.day, values.hour, values.minute, values.second]); //highlight invalid date this.highlight(dt); format = format === undefined ? this.options.format : format; if(format === null) { return dt.isValid() ? dt : null; } else { return dt.isValid() ? dt.format(format) : ''; } }, setValue: function(value) { if(!value) { return; } var dt = typeof value === 'string' ? moment(value, this.options.format) : moment(value), that = this, values = {}; //function to find nearest value in select options function getNearest($select, value) { var delta = {}; $select.children('option').each(function(i, opt){ var optValue = $(opt).attr('value'), distance; if(optValue === '') return; distance = Math.abs(optValue - value); if(typeof delta.distance === 'undefined' || distance < delta.distance) { delta = {value: optValue, distance: distance}; } }); return delta.value; } if(dt.isValid()) { //read values from date object $.each(this.map, function(k, v) { if(k === 'ampm') { return; } values[k] = dt[v[1]](); }); if(this.$ampm) { //12:00 pm --> 12:00 (24-h format, midday), 12:00 am --> 00:00 (24-h format, midnight, start of day) if(values.hour >= 12) { values.ampm = 'pm'; if(values.hour > 12) { values.hour -= 12; } } else { values.ampm = 'am'; if(values.hour === 0) { values.hour = 12; } } } $.each(values, function(k, v) { //call val() for each existing combo, e.g. this.$hour.val() if(that['$'+k]) { if(k === 'minute' && that.options.minuteStep > 1 && that.options.roundTime) { v = getNearest(that['$'+k], v); } if(k === 'second' && that.options.secondStep > 1 && that.options.roundTime) { v = getNearest(that['$'+k], v); } that['$'+k].val(v); } }); this.$element.val(dt.format(this.options.format)); } }, /* highlight combos if date is invalid */ highlight: function(dt) { if(!dt.isValid()) { if(this.options.errorClass) { this.$widget.addClass(this.options.errorClass); } else { //store original border color if(!this.borderColor) { this.borderColor = this.$widget.find('select').css('border-color'); } this.$widget.find('select').css('border-color', 'red'); } } else { if(this.options.errorClass) { this.$widget.removeClass(this.options.errorClass); } else { this.$widget.find('select').css('border-color', this.borderColor); } } }, leadZero: function(v) { return v <= 9 ? '0' + v : v; }, destroy: function() { this.$widget.remove(); this.$element.removeData('combodate').show(); } //todo: clear method }; $.fn.combodate = function ( option ) { var d, args = Array.apply(null, arguments); args.shift(); //getValue returns date as string / object (not jQuery object) if(option === 'getValue' && this.length && (d = this.eq(0).data('combodate'))) { return d.getValue.apply(d, args); } return this.each(function () { var $this = $(this), data = $this.data('combodate'), options = typeof option == 'object' && option; if (!data) { $this.data('combodate', (data = new Combodate(this, options))); } if (typeof option == 'string' && typeof data[option] == 'function') { data[option].apply(data, args); } }); }; $.fn.combodate.defaults = { //in this format value stored in original input format: 'DD-MM-YYYY HH:mm', //in this format items in dropdowns are displayed template: 'D / MMM / YYYY H : mm', //initial value, can be `new Date()` value: null, minYear: 1970, maxYear: 2015, yearDescending: true, minuteStep: 5, secondStep: 1, firstItem: 'empty', //'name', 'empty', 'none' errorClass: null, roundTime: true //whether to round minutes and seconds if step > 1 }; }(window.jQuery)); /** Combodate input - dropdown date and time picker. Based on [combodate](http://vitalets.github.com/combodate) plugin (included). To use it you should manually include [momentjs](http://momentjs.com). <script src="js/moment.min.js"></script> Allows to input: * only date * only time * both date and time Please note, that format is taken from momentjs and **not compatible** with bootstrap-datepicker / jquery UI datepicker. Internally value stored as `momentjs` object. @class combodate @extends abstractinput @final @since 1.4.0 @example <a href="#" id="dob" data-type="combodate" data-pk="1" data-url="/post" data-value="1984-05-15" data-title="Select date"></a> <script> $(function(){ $('#dob').editable({ format: 'YYYY-MM-DD', viewformat: 'DD.MM.YYYY', template: 'D / MMMM / YYYY', combodate: { minYear: 2000, maxYear: 2015, minuteStep: 1 } } }); }); </script> **/ /*global moment*/ (function ($) { "use strict"; var Constructor = function (options) { this.init('combodate', options, Constructor.defaults); //by default viewformat equals to format if(!this.options.viewformat) { this.options.viewformat = this.options.format; } //try parse combodate config defined as json string in data-combodate options.combodate = $.fn.editableutils.tryParseJson(options.combodate, true); //overriding combodate config (as by default jQuery extend() is not recursive) this.options.combodate = $.extend({}, Constructor.defaults.combodate, options.combodate, { format: this.options.format, template: this.options.template }); }; $.fn.editableutils.inherit(Constructor, $.fn.editabletypes.abstractinput); $.extend(Constructor.prototype, { render: function () { this.$input.combodate(this.options.combodate); if($.fn.editableform.engine === 'bs3') { this.$input.siblings().find('select').addClass('form-control'); } if(this.options.inputclass) { this.$input.siblings().find('select').addClass(this.options.inputclass); } //"clear" link /* if(this.options.clear) { this.$clear = $('<a href="#"></a>').html(this.options.clear).click($.proxy(function(e){ e.preventDefault(); e.stopPropagation(); this.clear(); }, this)); this.$tpl.parent().append($('<div class="editable-clear">').append(this.$clear)); } */ }, value2html: function(value, element) { var text = value ? value.format(this.options.viewformat) : ''; //$(element).text(text); Constructor.superclass.value2html.call(this, text, element); }, html2value: function(html) { return html ? moment(html, this.options.viewformat) : null; }, value2str: function(value) { return value ? value.format(this.options.format) : ''; }, str2value: function(str) { return str ? moment(str, this.options.format) : null; }, value2submit: function(value) { return this.value2str(value); }, value2input: function(value) { this.$input.combodate('setValue', value); }, input2value: function() { return this.$input.combodate('getValue', null); }, activate: function() { this.$input.siblings('.combodate').find('select').eq(0).focus(); }, /* clear: function() { this.$input.data('datepicker').date = null; this.$input.find('.active').removeClass('active'); }, */ autosubmit: function() { } }); Constructor.defaults = $.extend({}, $.fn.editabletypes.abstractinput.defaults, { /** @property tpl @default <input type="text"> **/ tpl:'<input type="text">', /** @property inputclass @default null **/ inputclass: null, /** Format used for sending value to server. Also applied when converting date from <code>data-value</code> attribute.<br> See list of tokens in [momentjs docs](http://momentjs.com/docs/#/parsing/string-format) @property format @type string @default YYYY-MM-DD **/ format:'YYYY-MM-DD', /** Format used for displaying date. Also applied when converting date from element's text on init. If not specified equals to `format`. @property viewformat @type string @default null **/ viewformat: null, /** Template used for displaying dropdowns. @property template @type string @default D / MMM / YYYY **/ template: 'D / MMM / YYYY', /** Configuration of combodate. Full list of options: http://vitalets.github.com/combodate/#docs @property combodate @type object @default null **/ combodate: null /* (not implemented yet) Text shown as clear date button. If <code>false</code> clear button will not be rendered. @property clear @type boolean|string @default 'x clear' */ //clear: '&times; clear' }); $.fn.editabletypes.combodate = Constructor; }(window.jQuery)); /* Editableform based on Twitter Bootstrap 2 */ (function ($) { "use strict"; //store parent methods var pInitInput = $.fn.editableform.Constructor.prototype.initInput; $.extend($.fn.editableform.Constructor.prototype, { initTemplate: function() { this.$form = $($.fn.editableform.template); this.$form.find('.editable-error-block').addClass('help-block'); }, initInput: function() { pInitInput.apply(this); //for bs2 set default class `input-medium` to standard inputs var emptyInputClass = this.input.options.inputclass === null || this.input.options.inputclass === false; var defaultClass = 'input-medium'; //add bs2 default class to standard inputs //if(this.input.$input.is('input,select,textarea')) { var stdtypes = 'text,select,textarea,password,email,url,tel,number,range,time'.split(','); if(~$.inArray(this.input.type, stdtypes) && emptyInputClass) { this.input.options.inputclass = defaultClass; this.input.$input.addClass(defaultClass); } } }); //buttons $.fn.editableform.buttons = '<button type="submit" class="btn btn-primary editable-submit"><i class="icon-ok icon-white"></i></button>'+ '<button type="button" class="btn editable-cancel"><i class="icon-remove"></i></button>'; //error classes $.fn.editableform.errorGroupClass = 'error'; $.fn.editableform.errorBlockClass = null; //engine $.fn.editableform.engine = 'bs2'; }(window.jQuery)); /** * Editable Popover * --------------------- * requires bootstrap-popover.js */ (function ($) { "use strict"; //extend methods $.extend($.fn.editableContainer.Popup.prototype, { containerName: 'popover', //for compatibility with bootstrap <= 2.2.1 (content inserted into <p> instead of directly .popover-content) innerCss: $.fn.popover && $($.fn.popover.defaults.template).find('p').length ? '.popover-content p' : '.popover-content', defaults: $.fn.popover.defaults, initContainer: function(){ $.extend(this.containerOptions, { trigger: 'manual', selector: false, content: ' ', template: this.defaults.template }); //as template property is used in inputs, hide it from popover var t; if(this.$element.data('template')) { t = this.$element.data('template'); this.$element.removeData('template'); } this.call(this.containerOptions); if(t) { //restore data('template') this.$element.data('template', t); } }, /* show */ innerShow: function () { this.call('show'); }, /* hide */ innerHide: function () { this.call('hide'); }, /* destroy */ innerDestroy: function() { this.call('destroy'); }, setContainerOption: function(key, value) { this.container().options[key] = value; }, /** * move popover to new position. This function mainly copied from bootstrap-popover. */ /*jshint laxcomma: true*/ setPosition: function () { (function() { var $tip = this.tip() , inside , pos , actualWidth , actualHeight , placement , tp , tpt , tpb , tpl , tpr; placement = typeof this.options.placement === 'function' ? this.options.placement.call(this, $tip[0], this.$element[0]) : this.options.placement; inside = /in/.test(placement); $tip // .detach() //vitalets: remove any placement class because otherwise they dont influence on re-positioning of visible popover .removeClass('top right bottom left') .css({ top: 0, left: 0, display: 'block' }); // .insertAfter(this.$element); pos = this.getPosition(inside); actualWidth = $tip[0].offsetWidth; actualHeight = $tip[0].offsetHeight; placement = inside ? placement.split(' ')[1] : placement; tpb = {top: pos.top + pos.height, left: pos.left + pos.width / 2 - actualWidth / 2}; tpt = {top: pos.top - actualHeight, left: pos.left + pos.width / 2 - actualWidth / 2}; tpl = {top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left - actualWidth}; tpr = {top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left + pos.width}; switch (placement) { case 'bottom': if ((tpb.top + actualHeight) > ($(window).scrollTop() + $(window).height())) { if (tpt.top > $(window).scrollTop()) { placement = 'top'; } else if ((tpr.left + actualWidth) < ($(window).scrollLeft() + $(window).width())) { placement = 'right'; } else if (tpl.left > $(window).scrollLeft()) { placement = 'left'; } else { placement = 'right'; } } break; case 'top': if (tpt.top < $(window).scrollTop()) { if ((tpb.top + actualHeight) < ($(window).scrollTop() + $(window).height())) { placement = 'bottom'; } else if ((tpr.left + actualWidth) < ($(window).scrollLeft() + $(window).width())) { placement = 'right'; } else if (tpl.left > $(window).scrollLeft()) { placement = 'left'; } else { placement = 'right'; } } break; case 'left': if (tpl.left < $(window).scrollLeft()) { if ((tpr.left + actualWidth) < ($(window).scrollLeft() + $(window).width())) { placement = 'right'; } else if (tpt.top > $(window).scrollTop()) { placement = 'top'; } else if (tpt.top > $(window).scrollTop()) { placement = 'bottom'; } else { placement = 'right'; } } break; case 'right': if ((tpr.left + actualWidth) > ($(window).scrollLeft() + $(window).width())) { if (tpl.left > $(window).scrollLeft()) { placement = 'left'; } else if (tpt.top > $(window).scrollTop()) { placement = 'top'; } else if (tpt.top > $(window).scrollTop()) { placement = 'bottom'; } } break; } switch (placement) { case 'bottom': tp = tpb; break; case 'top': tp = tpt; break; case 'left': tp = tpl; break; case 'right': tp = tpr; break; } $tip .offset(tp) .addClass(placement) .addClass('in'); }).call(this.container()); /*jshint laxcomma: false*/ } }); }(window.jQuery)); /* ========================================================= * bootstrap-datepicker.js * http://www.eyecon.ro/bootstrap-datepicker * ========================================================= * Copyright 2012 Stefan Petre * Improvements by Andrew Rowls * * 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. * ========================================================= */ (function( $ ) { function UTCDate(){ return new Date(Date.UTC.apply(Date, arguments)); } function UTCToday(){ var today = new Date(); return UTCDate(today.getUTCFullYear(), today.getUTCMonth(), today.getUTCDate()); } // Picker object var Datepicker = function(element, options) { var that = this; this._process_options(options); this.element = $(element); this.isInline = false; this.isInput = this.element.is('input'); this.component = this.element.is('.date') ? this.element.find('.add-on, .btn') : false; this.hasInput = this.component && this.element.find('input').length; if(this.component && this.component.length === 0) this.component = false; this.picker = $(DPGlobal.template); this._buildEvents(); this._attachEvents(); if(this.isInline) { this.picker.addClass('datepicker-inline').appendTo(this.element); } else { this.picker.addClass('datepicker-dropdown dropdown-menu'); } if (this.o.rtl){ this.picker.addClass('datepicker-rtl'); this.picker.find('.prev i, .next i') .toggleClass('icon-arrow-left icon-arrow-right'); } this.viewMode = this.o.startView; if (this.o.calendarWeeks) this.picker.find('tfoot th.today') .attr('colspan', function(i, val){ return parseInt(val) + 1; }); this._allow_update = false; this.setStartDate(this.o.startDate); this.setEndDate(this.o.endDate); this.setDaysOfWeekDisabled(this.o.daysOfWeekDisabled); this.fillDow(); this.fillMonths(); this._allow_update = true; this.update(); this.showMode(); if(this.isInline) { this.show(); } }; Datepicker.prototype = { constructor: Datepicker, _process_options: function(opts){ // Store raw options for reference this._o = $.extend({}, this._o, opts); // Processed options var o = this.o = $.extend({}, this._o); // Check if "de-DE" style date is available, if not language should // fallback to 2 letter code eg "de" var lang = o.language; if (!dates[lang]) { lang = lang.split('-')[0]; if (!dates[lang]) lang = defaults.language; } o.language = lang; switch(o.startView){ case 2: case 'decade': o.startView = 2; break; case 1: case 'year': o.startView = 1; break; default: o.startView = 0; } switch (o.minViewMode) { case 1: case 'months': o.minViewMode = 1; break; case 2: case 'years': o.minViewMode = 2; break; default: o.minViewMode = 0; } o.startView = Math.max(o.startView, o.minViewMode); o.weekStart %= 7; o.weekEnd = ((o.weekStart + 6) % 7); var format = DPGlobal.parseFormat(o.format) if (o.startDate !== -Infinity) { o.startDate = DPGlobal.parseDate(o.startDate, format, o.language); } if (o.endDate !== Infinity) { o.endDate = DPGlobal.parseDate(o.endDate, format, o.language); } o.daysOfWeekDisabled = o.daysOfWeekDisabled||[]; if (!$.isArray(o.daysOfWeekDisabled)) o.daysOfWeekDisabled = o.daysOfWeekDisabled.split(/[,\s]*/); o.daysOfWeekDisabled = $.map(o.daysOfWeekDisabled, function (d) { return parseInt(d, 10); }); }, _events: [], _secondaryEvents: [], _applyEvents: function(evs){ for (var i=0, el, ev; i<evs.length; i++){ el = evs[i][0]; ev = evs[i][1]; el.on(ev); } }, _unapplyEvents: function(evs){ for (var i=0, el, ev; i<evs.length; i++){ el = evs[i][0]; ev = evs[i][1]; el.off(ev); } }, _buildEvents: function(){ if (this.isInput) { // single input this._events = [ [this.element, { focus: $.proxy(this.show, this), keyup: $.proxy(this.update, this), keydown: $.proxy(this.keydown, this) }] ]; } else if (this.component && this.hasInput){ // component: input + button this._events = [ // For components that are not readonly, allow keyboard nav [this.element.find('input'), { focus: $.proxy(this.show, this), keyup: $.proxy(this.update, this), keydown: $.proxy(this.keydown, this) }], [this.component, { click: $.proxy(this.show, this) }] ]; } else if (this.element.is('div')) { // inline datepicker this.isInline = true; } else { this._events = [ [this.element, { click: $.proxy(this.show, this) }] ]; } this._secondaryEvents = [ [this.picker, { click: $.proxy(this.click, this) }], [$(window), { resize: $.proxy(this.place, this) }], [$(document), { mousedown: $.proxy(function (e) { // Clicked outside the datepicker, hide it if (!( this.element.is(e.target) || this.element.find(e.target).size() || this.picker.is(e.target) || this.picker.find(e.target).size() )) { this.hide(); } }, this) }] ]; }, _attachEvents: function(){ this._detachEvents(); this._applyEvents(this._events); }, _detachEvents: function(){ this._unapplyEvents(this._events); }, _attachSecondaryEvents: function(){ this._detachSecondaryEvents(); this._applyEvents(this._secondaryEvents); }, _detachSecondaryEvents: function(){ this._unapplyEvents(this._secondaryEvents); }, _trigger: function(event, altdate){ var date = altdate || this.date, local_date = new Date(date.getTime() + (date.getTimezoneOffset()*60000)); this.element.trigger({ type: event, date: local_date, format: $.proxy(function(altformat){ var format = altformat || this.o.format; return DPGlobal.formatDate(date, format, this.o.language); }, this) }); }, show: function(e) { if (!this.isInline) this.picker.appendTo('body'); this.picker.show(); this.height = this.component ? this.component.outerHeight() : this.element.outerHeight(); this.place(); this._attachSecondaryEvents(); if (e) { e.preventDefault(); } this._trigger('show'); }, hide: function(e){ if(this.isInline) return; if (!this.picker.is(':visible')) return; this.picker.hide().detach(); this._detachSecondaryEvents(); this.viewMode = this.o.startView; this.showMode(); if ( this.o.forceParse && ( this.isInput && this.element.val() || this.hasInput && this.element.find('input').val() ) ) this.setValue(); this._trigger('hide'); }, remove: function() { this.hide(); this._detachEvents(); this._detachSecondaryEvents(); this.picker.remove(); delete this.element.data().datepicker; if (!this.isInput) { delete this.element.data().date; } }, getDate: function() { var d = this.getUTCDate(); return new Date(d.getTime() + (d.getTimezoneOffset()*60000)); }, getUTCDate: function() { return this.date; }, setDate: function(d) { this.setUTCDate(new Date(d.getTime() - (d.getTimezoneOffset()*60000))); }, setUTCDate: function(d) { this.date = d; this.setValue(); }, setValue: function() { var formatted = this.getFormattedDate(); if (!this.isInput) { if (this.component){ this.element.find('input').val(formatted); } } else { this.element.val(formatted); } }, getFormattedDate: function(format) { if (format === undefined) format = this.o.format; return DPGlobal.formatDate(this.date, format, this.o.language); }, setStartDate: function(startDate){ this._process_options({startDate: startDate}); this.update(); this.updateNavArrows(); }, setEndDate: function(endDate){ this._process_options({endDate: endDate}); this.update(); this.updateNavArrows(); }, setDaysOfWeekDisabled: function(daysOfWeekDisabled){ this._process_options({daysOfWeekDisabled: daysOfWeekDisabled}); this.update(); this.updateNavArrows(); }, place: function(){ if(this.isInline) return; var zIndex = parseInt(this.element.parents().filter(function() { return $(this).css('z-index') != 'auto'; }).first().css('z-index'))+10; var offset = this.component ? this.component.parent().offset() : this.element.offset(); var height = this.component ? this.component.outerHeight(true) : this.element.outerHeight(true); this.picker.css({ top: offset.top + height, left: offset.left, zIndex: zIndex }); }, _allow_update: true, update: function(){ if (!this._allow_update) return; var date, fromArgs = false; if(arguments && arguments.length && (typeof arguments[0] === 'string' || arguments[0] instanceof Date)) { date = arguments[0]; fromArgs = true; } else { date = this.isInput ? this.element.val() : this.element.data('date') || this.element.find('input').val(); delete this.element.data().date; } this.date = DPGlobal.parseDate(date, this.o.format, this.o.language); if(fromArgs) this.setValue(); if (this.date < this.o.startDate) { this.viewDate = new Date(this.o.startDate); } else if (this.date > this.o.endDate) { this.viewDate = new Date(this.o.endDate); } else { this.viewDate = new Date(this.date); } this.fill(); }, fillDow: function(){ var dowCnt = this.o.weekStart, html = '<tr>'; if(this.o.calendarWeeks){ var cell = '<th class="cw">&nbsp;</th>'; html += cell; this.picker.find('.datepicker-days thead tr:first-child').prepend(cell); } while (dowCnt < this.o.weekStart + 7) { html += '<th class="dow">'+dates[this.o.language].daysMin[(dowCnt++)%7]+'</th>'; } html += '</tr>'; this.picker.find('.datepicker-days thead').append(html); }, fillMonths: function(){ var html = '', i = 0; while (i < 12) { html += '<span class="month">'+dates[this.o.language].monthsShort[i++]+'</span>'; } this.picker.find('.datepicker-months td').html(html); }, setRange: function(range){ if (!range || !range.length) delete this.range; else this.range = $.map(range, function(d){ return d.valueOf(); }); this.fill(); }, getClassNames: function(date){ var cls = [], year = this.viewDate.getUTCFullYear(), month = this.viewDate.getUTCMonth(), currentDate = this.date.valueOf(), today = new Date(); if (date.getUTCFullYear() < year || (date.getUTCFullYear() == year && date.getUTCMonth() < month)) { cls.push('old'); } else if (date.getUTCFullYear() > year || (date.getUTCFullYear() == year && date.getUTCMonth() > month)) { cls.push('new'); } // Compare internal UTC date with local today, not UTC today if (this.o.todayHighlight && date.getUTCFullYear() == today.getFullYear() && date.getUTCMonth() == today.getMonth() && date.getUTCDate() == today.getDate()) { cls.push('today'); } if (currentDate && date.valueOf() == currentDate) { cls.push('active'); } if (date.valueOf() < this.o.startDate || date.valueOf() > this.o.endDate || $.inArray(date.getUTCDay(), this.o.daysOfWeekDisabled) !== -1) { cls.push('disabled'); } if (this.range){ if (date > this.range[0] && date < this.range[this.range.length-1]){ cls.push('range'); } if ($.inArray(date.valueOf(), this.range) != -1){ cls.push('selected'); } } return cls; }, fill: function() { var d = new Date(this.viewDate), year = d.getUTCFullYear(), month = d.getUTCMonth(), startYear = this.o.startDate !== -Infinity ? this.o.startDate.getUTCFullYear() : -Infinity, startMonth = this.o.startDate !== -Infinity ? this.o.startDate.getUTCMonth() : -Infinity, endYear = this.o.endDate !== Infinity ? this.o.endDate.getUTCFullYear() : Infinity, endMonth = this.o.endDate !== Infinity ? this.o.endDate.getUTCMonth() : Infinity, currentDate = this.date && this.date.valueOf(), tooltip; this.picker.find('.datepicker-days thead th.datepicker-switch') .text(dates[this.o.language].months[month]+' '+year); this.picker.find('tfoot th.today') .text(dates[this.o.language].today) .toggle(this.o.todayBtn !== false); this.picker.find('tfoot th.clear') .text(dates[this.o.language].clear) .toggle(this.o.clearBtn !== false); this.updateNavArrows(); this.fillMonths(); var prevMonth = UTCDate(year, month-1, 28,0,0,0,0), day = DPGlobal.getDaysInMonth(prevMonth.getUTCFullYear(), prevMonth.getUTCMonth()); prevMonth.setUTCDate(day); prevMonth.setUTCDate(day - (prevMonth.getUTCDay() - this.o.weekStart + 7)%7); var nextMonth = new Date(prevMonth); nextMonth.setUTCDate(nextMonth.getUTCDate() + 42); nextMonth = nextMonth.valueOf(); var html = []; var clsName; while(prevMonth.valueOf() < nextMonth) { if (prevMonth.getUTCDay() == this.o.weekStart) { html.push('<tr>'); if(this.o.calendarWeeks){ // ISO 8601: First week contains first thursday. // ISO also states week starts on Monday, but we can be more abstract here. var // Start of current week: based on weekstart/current date ws = new Date(+prevMonth + (this.o.weekStart - prevMonth.getUTCDay() - 7) % 7 * 864e5), // Thursday of this week th = new Date(+ws + (7 + 4 - ws.getUTCDay()) % 7 * 864e5), // First Thursday of year, year from thursday yth = new Date(+(yth = UTCDate(th.getUTCFullYear(), 0, 1)) + (7 + 4 - yth.getUTCDay())%7*864e5), // Calendar week: ms between thursdays, div ms per day, div 7 days calWeek = (th - yth) / 864e5 / 7 + 1; html.push('<td class="cw">'+ calWeek +'</td>'); } } clsName = this.getClassNames(prevMonth); clsName.push('day'); var before = this.o.beforeShowDay(prevMonth); if (before === undefined) before = {}; else if (typeof(before) === 'boolean') before = {enabled: before}; else if (typeof(before) === 'string') before = {classes: before}; if (before.enabled === false) clsName.push('disabled'); if (before.classes) clsName = clsName.concat(before.classes.split(/\s+/)); if (before.tooltip) tooltip = before.tooltip; clsName = $.unique(clsName); html.push('<td class="'+clsName.join(' ')+'"' + (tooltip ? ' title="'+tooltip+'"' : '') + '>'+prevMonth.getUTCDate() + '</td>'); if (prevMonth.getUTCDay() == this.o.weekEnd) { html.push('</tr>'); } prevMonth.setUTCDate(prevMonth.getUTCDate()+1); } this.picker.find('.datepicker-days tbody').empty().append(html.join('')); var currentYear = this.date && this.date.getUTCFullYear(); var months = this.picker.find('.datepicker-months') .find('th:eq(1)') .text(year) .end() .find('span').removeClass('active'); if (currentYear && currentYear == year) { months.eq(this.date.getUTCMonth()).addClass('active'); } if (year < startYear || year > endYear) { months.addClass('disabled'); } if (year == startYear) { months.slice(0, startMonth).addClass('disabled'); } if (year == endYear) { months.slice(endMonth+1).addClass('disabled'); } html = ''; year = parseInt(year/10, 10) * 10; var yearCont = this.picker.find('.datepicker-years') .find('th:eq(1)') .text(year + '-' + (year + 9)) .end() .find('td'); year -= 1; for (var i = -1; i < 11; i++) { html += '<span class="year'+(i == -1 ? ' old' : i == 10 ? ' new' : '')+(currentYear == year ? ' active' : '')+(year < startYear || year > endYear ? ' disabled' : '')+'">'+year+'</span>'; year += 1; } yearCont.html(html); }, updateNavArrows: function() { if (!this._allow_update) return; var d = new Date(this.viewDate), year = d.getUTCFullYear(), month = d.getUTCMonth(); switch (this.viewMode) { case 0: if (this.o.startDate !== -Infinity && year <= this.o.startDate.getUTCFullYear() && month <= this.o.startDate.getUTCMonth()) { this.picker.find('.prev').css({visibility: 'hidden'}); } else { this.picker.find('.prev').css({visibility: 'visible'}); } if (this.o.endDate !== Infinity && year >= this.o.endDate.getUTCFullYear() && month >= this.o.endDate.getUTCMonth()) { this.picker.find('.next').css({visibility: 'hidden'}); } else { this.picker.find('.next').css({visibility: 'visible'}); } break; case 1: case 2: if (this.o.startDate !== -Infinity && year <= this.o.startDate.getUTCFullYear()) { this.picker.find('.prev').css({visibility: 'hidden'}); } else { this.picker.find('.prev').css({visibility: 'visible'}); } if (this.o.endDate !== Infinity && year >= this.o.endDate.getUTCFullYear()) { this.picker.find('.next').css({visibility: 'hidden'}); } else { this.picker.find('.next').css({visibility: 'visible'}); } break; } }, click: function(e) { e.preventDefault(); var target = $(e.target).closest('span, td, th'); if (target.length == 1) { switch(target[0].nodeName.toLowerCase()) { case 'th': switch(target[0].className) { case 'datepicker-switch': this.showMode(1); break; case 'prev': case 'next': var dir = DPGlobal.modes[this.viewMode].navStep * (target[0].className == 'prev' ? -1 : 1); switch(this.viewMode){ case 0: this.viewDate = this.moveMonth(this.viewDate, dir); break; case 1: case 2: this.viewDate = this.moveYear(this.viewDate, dir); break; } this.fill(); break; case 'today': var date = new Date(); date = UTCDate(date.getFullYear(), date.getMonth(), date.getDate(), 0, 0, 0); this.showMode(-2); var which = this.o.todayBtn == 'linked' ? null : 'view'; this._setDate(date, which); break; case 'clear': var element; if (this.isInput) element = this.element; else if (this.component) element = this.element.find('input'); if (element) element.val("").change(); this._trigger('changeDate'); this.update(); if (this.o.autoclose) this.hide(); break; } break; case 'span': if (!target.is('.disabled')) { this.viewDate.setUTCDate(1); if (target.is('.month')) { var day = 1; var month = target.parent().find('span').index(target); var year = this.viewDate.getUTCFullYear(); this.viewDate.setUTCMonth(month); this._trigger('changeMonth', this.viewDate); if (this.o.minViewMode === 1) { this._setDate(UTCDate(year, month, day,0,0,0,0)); } } else { var year = parseInt(target.text(), 10)||0; var day = 1; var month = 0; this.viewDate.setUTCFullYear(year); this._trigger('changeYear', this.viewDate); if (this.o.minViewMode === 2) { this._setDate(UTCDate(year, month, day,0,0,0,0)); } } this.showMode(-1); this.fill(); } break; case 'td': if (target.is('.day') && !target.is('.disabled')){ var day = parseInt(target.text(), 10)||1; var year = this.viewDate.getUTCFullYear(), month = this.viewDate.getUTCMonth(); if (target.is('.old')) { if (month === 0) { month = 11; year -= 1; } else { month -= 1; } } else if (target.is('.new')) { if (month == 11) { month = 0; year += 1; } else { month += 1; } } this._setDate(UTCDate(year, month, day,0,0,0,0)); } break; } } }, _setDate: function(date, which){ if (!which || which == 'date') this.date = new Date(date); if (!which || which == 'view') this.viewDate = new Date(date); this.fill(); this.setValue(); this._trigger('changeDate'); var element; if (this.isInput) { element = this.element; } else if (this.component){ element = this.element.find('input'); } if (element) { element.change(); if (this.o.autoclose && (!which || which == 'date')) { this.hide(); } } }, moveMonth: function(date, dir){ if (!dir) return date; var new_date = new Date(date.valueOf()), day = new_date.getUTCDate(), month = new_date.getUTCMonth(), mag = Math.abs(dir), new_month, test; dir = dir > 0 ? 1 : -1; if (mag == 1){ test = dir == -1 // If going back one month, make sure month is not current month // (eg, Mar 31 -> Feb 31 == Feb 28, not Mar 02) ? function(){ return new_date.getUTCMonth() == month; } // If going forward one month, make sure month is as expected // (eg, Jan 31 -> Feb 31 == Feb 28, not Mar 02) : function(){ return new_date.getUTCMonth() != new_month; }; new_month = month + dir; new_date.setUTCMonth(new_month); // Dec -> Jan (12) or Jan -> Dec (-1) -- limit expected date to 0-11 if (new_month < 0 || new_month > 11) new_month = (new_month + 12) % 12; } else { // For magnitudes >1, move one month at a time... for (var i=0; i<mag; i++) // ...which might decrease the day (eg, Jan 31 to Feb 28, etc)... new_date = this.moveMonth(new_date, dir); // ...then reset the day, keeping it in the new month new_month = new_date.getUTCMonth(); new_date.setUTCDate(day); test = function(){ return new_month != new_date.getUTCMonth(); }; } // Common date-resetting loop -- if date is beyond end of month, make it // end of month while (test()){ new_date.setUTCDate(--day); new_date.setUTCMonth(new_month); } return new_date; }, moveYear: function(date, dir){ return this.moveMonth(date, dir*12); }, dateWithinRange: function(date){ return date >= this.o.startDate && date <= this.o.endDate; }, keydown: function(e){ if (this.picker.is(':not(:visible)')){ if (e.keyCode == 27) // allow escape to hide and re-show picker this.show(); return; } var dateChanged = false, dir, day, month, newDate, newViewDate; switch(e.keyCode){ case 27: // escape this.hide(); e.preventDefault(); break; case 37: // left case 39: // right if (!this.o.keyboardNavigation) break; dir = e.keyCode == 37 ? -1 : 1; if (e.ctrlKey){ newDate = this.moveYear(this.date, dir); newViewDate = this.moveYear(this.viewDate, dir); } else if (e.shiftKey){ newDate = this.moveMonth(this.date, dir); newViewDate = this.moveMonth(this.viewDate, dir); } else { newDate = new Date(this.date); newDate.setUTCDate(this.date.getUTCDate() + dir); newViewDate = new Date(this.viewDate); newViewDate.setUTCDate(this.viewDate.getUTCDate() + dir); } if (this.dateWithinRange(newDate)){ this.date = newDate; this.viewDate = newViewDate; this.setValue(); this.update(); e.preventDefault(); dateChanged = true; } break; case 38: // up case 40: // down if (!this.o.keyboardNavigation) break; dir = e.keyCode == 38 ? -1 : 1; if (e.ctrlKey){ newDate = this.moveYear(this.date, dir); newViewDate = this.moveYear(this.viewDate, dir); } else if (e.shiftKey){ newDate = this.moveMonth(this.date, dir); newViewDate = this.moveMonth(this.viewDate, dir); } else { newDate = new Date(this.date); newDate.setUTCDate(this.date.getUTCDate() + dir * 7); newViewDate = new Date(this.viewDate); newViewDate.setUTCDate(this.viewDate.getUTCDate() + dir * 7); } if (this.dateWithinRange(newDate)){ this.date = newDate; this.viewDate = newViewDate; this.setValue(); this.update(); e.preventDefault(); dateChanged = true; } break; case 13: // enter this.hide(); e.preventDefault(); break; case 9: // tab this.hide(); break; } if (dateChanged){ this._trigger('changeDate'); var element; if (this.isInput) { element = this.element; } else if (this.component){ element = this.element.find('input'); } if (element) { element.change(); } } }, showMode: function(dir) { if (dir) { this.viewMode = Math.max(this.o.minViewMode, Math.min(2, this.viewMode + dir)); } /* vitalets: fixing bug of very special conditions: jquery 1.7.1 + webkit + show inline datepicker in bootstrap popover. Method show() does not set display css correctly and datepicker is not shown. Changed to .css('display', 'block') solve the problem. See https://github.com/vitalets/x-editable/issues/37 In jquery 1.7.2+ everything works fine. */ //this.picker.find('>div').hide().filter('.datepicker-'+DPGlobal.modes[this.viewMode].clsName).show(); this.picker.find('>div').hide().filter('.datepicker-'+DPGlobal.modes[this.viewMode].clsName).css('display', 'block'); this.updateNavArrows(); } }; var DateRangePicker = function(element, options){ this.element = $(element); this.inputs = $.map(options.inputs, function(i){ return i.jquery ? i[0] : i; }); delete options.inputs; $(this.inputs) .datepicker(options) .bind('changeDate', $.proxy(this.dateUpdated, this)); this.pickers = $.map(this.inputs, function(i){ return $(i).data('datepicker'); }); this.updateDates(); }; DateRangePicker.prototype = { updateDates: function(){ this.dates = $.map(this.pickers, function(i){ return i.date; }); this.updateRanges(); }, updateRanges: function(){ var range = $.map(this.dates, function(d){ return d.valueOf(); }); $.each(this.pickers, function(i, p){ p.setRange(range); }); }, dateUpdated: function(e){ var dp = $(e.target).data('datepicker'), new_date = dp.getUTCDate(), i = $.inArray(e.target, this.inputs), l = this.inputs.length; if (i == -1) return; if (new_date < this.dates[i]){ // Date being moved earlier/left while (i>=0 && new_date < this.dates[i]){ this.pickers[i--].setUTCDate(new_date); } } else if (new_date > this.dates[i]){ // Date being moved later/right while (i<l && new_date > this.dates[i]){ this.pickers[i++].setUTCDate(new_date); } } this.updateDates(); }, remove: function(){ $.map(this.pickers, function(p){ p.remove(); }); delete this.element.data().datepicker; } }; function opts_from_el(el, prefix){ // Derive options from element data-attrs var data = $(el).data(), out = {}, inkey, replace = new RegExp('^' + prefix.toLowerCase() + '([A-Z])'), prefix = new RegExp('^' + prefix.toLowerCase()); for (var key in data) if (prefix.test(key)){ inkey = key.replace(replace, function(_,a){ return a.toLowerCase(); }); out[inkey] = data[key]; } return out; } function opts_from_locale(lang){ // Derive options from locale plugins var out = {}; // Check if "de-DE" style date is available, if not language should // fallback to 2 letter code eg "de" if (!dates[lang]) { lang = lang.split('-')[0] if (!dates[lang]) return; } var d = dates[lang]; $.each(locale_opts, function(i,k){ if (k in d) out[k] = d[k]; }); return out; } var old = $.fn.datepicker; var datepicker = $.fn.datepicker = function ( option ) { var args = Array.apply(null, arguments); args.shift(); var internal_return, this_return; this.each(function () { var $this = $(this), data = $this.data('datepicker'), options = typeof option == 'object' && option; if (!data) { var elopts = opts_from_el(this, 'date'), // Preliminary otions xopts = $.extend({}, defaults, elopts, options), locopts = opts_from_locale(xopts.language), // Options priority: js args, data-attrs, locales, defaults opts = $.extend({}, defaults, locopts, elopts, options); if ($this.is('.input-daterange') || opts.inputs){ var ropts = { inputs: opts.inputs || $this.find('input').toArray() }; $this.data('datepicker', (data = new DateRangePicker(this, $.extend(opts, ropts)))); } else{ $this.data('datepicker', (data = new Datepicker(this, opts))); } } if (typeof option == 'string' && typeof data[option] == 'function') { internal_return = data[option].apply(data, args); if (internal_return !== undefined) return false; } }); if (internal_return !== undefined) return internal_return; else return this; }; var defaults = $.fn.datepicker.defaults = { autoclose: false, beforeShowDay: $.noop, calendarWeeks: false, clearBtn: false, daysOfWeekDisabled: [], endDate: Infinity, forceParse: true, format: 'mm/dd/yyyy', keyboardNavigation: true, language: 'en', minViewMode: 0, rtl: false, startDate: -Infinity, startView: 0, todayBtn: false, todayHighlight: false, weekStart: 0 }; var locale_opts = $.fn.datepicker.locale_opts = [ 'format', 'rtl', 'weekStart' ]; $.fn.datepicker.Constructor = Datepicker; var dates = $.fn.datepicker.dates = { en: { days: ["Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday", "Sunday"], daysShort: ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun"], daysMin: ["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa", "Su"], months: ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"], monthsShort: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"], today: "Today", clear: "Clear" } }; var DPGlobal = { modes: [ { clsName: 'days', navFnc: 'Month', navStep: 1 }, { clsName: 'months', navFnc: 'FullYear', navStep: 1 }, { clsName: 'years', navFnc: 'FullYear', navStep: 10 }], isLeapYear: function (year) { return (((year % 4 === 0) && (year % 100 !== 0)) || (year % 400 === 0)); }, getDaysInMonth: function (year, month) { return [31, (DPGlobal.isLeapYear(year) ? 29 : 28), 31, 30, 31, 30, 31, 31, 30, 31, 30, 31][month]; }, validParts: /dd?|DD?|mm?|MM?|yy(?:yy)?/g, nonpunctuation: /[^ -\/:-@\[\u3400-\u9fff-`{-~\t\n\r]+/g, parseFormat: function(format){ // IE treats \0 as a string end in inputs (truncating the value), // so it's a bad format delimiter, anyway var separators = format.replace(this.validParts, '\0').split('\0'), parts = format.match(this.validParts); if (!separators || !separators.length || !parts || parts.length === 0){ throw new Error("Invalid date format."); } return {separators: separators, parts: parts}; }, parseDate: function(date, format, language) { if (date instanceof Date) return date; if (typeof format === 'string') format = DPGlobal.parseFormat(format); if (/^[\-+]\d+[dmwy]([\s,]+[\-+]\d+[dmwy])*$/.test(date)) { var part_re = /([\-+]\d+)([dmwy])/, parts = date.match(/([\-+]\d+)([dmwy])/g), part, dir; date = new Date(); for (var i=0; i<parts.length; i++) { part = part_re.exec(parts[i]); dir = parseInt(part[1]); switch(part[2]){ case 'd': date.setUTCDate(date.getUTCDate() + dir); break; case 'm': date = Datepicker.prototype.moveMonth.call(Datepicker.prototype, date, dir); break; case 'w': date.setUTCDate(date.getUTCDate() + dir * 7); break; case 'y': date = Datepicker.prototype.moveYear.call(Datepicker.prototype, date, dir); break; } } return UTCDate(date.getUTCFullYear(), date.getUTCMonth(), date.getUTCDate(), 0, 0, 0); } var parts = date && date.match(this.nonpunctuation) || [], date = new Date(), parsed = {}, setters_order = ['yyyy', 'yy', 'M', 'MM', 'm', 'mm', 'd', 'dd'], setters_map = { yyyy: function(d,v){ return d.setUTCFullYear(v); }, yy: function(d,v){ return d.setUTCFullYear(2000+v); }, m: function(d,v){ v -= 1; while (v<0) v += 12; v %= 12; d.setUTCMonth(v); while (d.getUTCMonth() != v) d.setUTCDate(d.getUTCDate()-1); return d; }, d: function(d,v){ return d.setUTCDate(v); } }, val, filtered, part; setters_map['M'] = setters_map['MM'] = setters_map['mm'] = setters_map['m']; setters_map['dd'] = setters_map['d']; date = UTCDate(date.getFullYear(), date.getMonth(), date.getDate(), 0, 0, 0); var fparts = format.parts.slice(); // Remove noop parts if (parts.length != fparts.length) { fparts = $(fparts).filter(function(i,p){ return $.inArray(p, setters_order) !== -1; }).toArray(); } // Process remainder if (parts.length == fparts.length) { for (var i=0, cnt = fparts.length; i < cnt; i++) { val = parseInt(parts[i], 10); part = fparts[i]; if (isNaN(val)) { switch(part) { case 'MM': filtered = $(dates[language].months).filter(function(){ var m = this.slice(0, parts[i].length), p = parts[i].slice(0, m.length); return m == p; }); val = $.inArray(filtered[0], dates[language].months) + 1; break; case 'M': filtered = $(dates[language].monthsShort).filter(function(){ var m = this.slice(0, parts[i].length), p = parts[i].slice(0, m.length); return m == p; }); val = $.inArray(filtered[0], dates[language].monthsShort) + 1; break; } } parsed[part] = val; } for (var i=0, s; i<setters_order.length; i++){ s = setters_order[i]; if (s in parsed && !isNaN(parsed[s])) setters_map[s](date, parsed[s]); } } return date; }, formatDate: function(date, format, language){ if (typeof format === 'string') format = DPGlobal.parseFormat(format); var val = { d: date.getUTCDate(), D: dates[language].daysShort[date.getUTCDay()], DD: dates[language].days[date.getUTCDay()], m: date.getUTCMonth() + 1, M: dates[language].monthsShort[date.getUTCMonth()], MM: dates[language].months[date.getUTCMonth()], yy: date.getUTCFullYear().toString().substring(2), yyyy: date.getUTCFullYear() }; val.dd = (val.d < 10 ? '0' : '') + val.d; val.mm = (val.m < 10 ? '0' : '') + val.m; var date = [], seps = $.extend([], format.separators); for (var i=0, cnt = format.parts.length; i <= cnt; i++) { if (seps.length) date.push(seps.shift()); date.push(val[format.parts[i]]); } return date.join(''); }, headTemplate: '<thead>'+ '<tr>'+ '<th class="prev"><i class="icon-arrow-left"/></th>'+ '<th colspan="5" class="datepicker-switch"></th>'+ '<th class="next"><i class="icon-arrow-right"/></th>'+ '</tr>'+ '</thead>', contTemplate: '<tbody><tr><td colspan="7"></td></tr></tbody>', footTemplate: '<tfoot><tr><th colspan="7" class="today"></th></tr><tr><th colspan="7" class="clear"></th></tr></tfoot>' }; DPGlobal.template = '<div class="datepicker">'+ '<div class="datepicker-days">'+ '<table class=" table-condensed">'+ DPGlobal.headTemplate+ '<tbody></tbody>'+ DPGlobal.footTemplate+ '</table>'+ '</div>'+ '<div class="datepicker-months">'+ '<table class="table-condensed">'+ DPGlobal.headTemplate+ DPGlobal.contTemplate+ DPGlobal.footTemplate+ '</table>'+ '</div>'+ '<div class="datepicker-years">'+ '<table class="table-condensed">'+ DPGlobal.headTemplate+ DPGlobal.contTemplate+ DPGlobal.footTemplate+ '</table>'+ '</div>'+ '</div>'; $.fn.datepicker.DPGlobal = DPGlobal; /* DATEPICKER NO CONFLICT * =================== */ $.fn.datepicker.noConflict = function(){ $.fn.datepicker = old; return this; }; /* DATEPICKER DATA-API * ================== */ $(document).on( 'focus.datepicker.data-api click.datepicker.data-api', '[data-provide="datepicker"]', function(e){ var $this = $(this); if ($this.data('datepicker')) return; e.preventDefault(); // component click requires us to explicitly show it datepicker.call($this, 'show'); } ); $(function(){ //$('[data-provide="datepicker-inline"]').datepicker(); //vit: changed to support noConflict() datepicker.call($('[data-provide="datepicker-inline"]')); }); }( window.jQuery )); /** Bootstrap-datepicker. Description and examples: https://github.com/eternicode/bootstrap-datepicker. For **i18n** you should include js file from here: https://github.com/eternicode/bootstrap-datepicker/tree/master/js/locales and set `language` option. Since 1.4.0 date has different appearance in **popup** and **inline** modes. @class date @extends abstractinput @final @example <a href="#" id="dob" data-type="date" data-pk="1" data-url="/post" data-title="Select date">15/05/1984</a> <script> $(function(){ $('#dob').editable({ format: 'yyyy-mm-dd', viewformat: 'dd/mm/yyyy', datepicker: { weekStart: 1 } } }); }); </script> **/ (function ($) { "use strict"; //store bootstrap-datepicker as bdateicker to exclude conflict with jQuery UI one $.fn.bdatepicker = $.fn.datepicker.noConflict(); if(!$.fn.datepicker) { //if there were no other datepickers, keep also original name $.fn.datepicker = $.fn.bdatepicker; } var Date = function (options) { this.init('date', options, Date.defaults); this.initPicker(options, Date.defaults); }; $.fn.editableutils.inherit(Date, $.fn.editabletypes.abstractinput); $.extend(Date.prototype, { initPicker: function(options, defaults) { //'format' is set directly from settings or data-* attributes //by default viewformat equals to format if(!this.options.viewformat) { this.options.viewformat = this.options.format; } //try parse datepicker config defined as json string in data-datepicker options.datepicker = $.fn.editableutils.tryParseJson(options.datepicker, true); //overriding datepicker config (as by default jQuery extend() is not recursive) //since 1.4 datepicker internally uses viewformat instead of format. Format is for submit only this.options.datepicker = $.extend({}, defaults.datepicker, options.datepicker, { format: this.options.viewformat }); //language this.options.datepicker.language = this.options.datepicker.language || 'en'; //store DPglobal this.dpg = $.fn.bdatepicker.DPGlobal; //store parsed formats this.parsedFormat = this.dpg.parseFormat(this.options.format); this.parsedViewFormat = this.dpg.parseFormat(this.options.viewformat); }, render: function () { this.$input.bdatepicker(this.options.datepicker); //"clear" link if(this.options.clear) { this.$clear = $('<a href="#"></a>').html(this.options.clear).click($.proxy(function(e){ e.preventDefault(); e.stopPropagation(); this.clear(); }, this)); this.$tpl.parent().append($('<div class="editable-clear">').append(this.$clear)); } }, value2html: function(value, element) { var text = value ? this.dpg.formatDate(value, this.parsedViewFormat, this.options.datepicker.language) : ''; Date.superclass.value2html.call(this, text, element); }, html2value: function(html) { return this.parseDate(html, this.parsedViewFormat); }, value2str: function(value) { return value ? this.dpg.formatDate(value, this.parsedFormat, this.options.datepicker.language) : ''; }, str2value: function(str) { return this.parseDate(str, this.parsedFormat); }, value2submit: function(value) { return this.value2str(value); }, value2input: function(value) { this.$input.bdatepicker('update', value); }, input2value: function() { return this.$input.data('datepicker').date; }, activate: function() { }, clear: function() { this.$input.data('datepicker').date = null; this.$input.find('.active').removeClass('active'); if(!this.options.showbuttons) { this.$input.closest('form').submit(); } }, autosubmit: function() { this.$input.on('mouseup', '.day', function(e){ if($(e.currentTarget).is('.old') || $(e.currentTarget).is('.new')) { return; } var $form = $(this).closest('form'); setTimeout(function() { $form.submit(); }, 200); }); //changedate is not suitable as it triggered when showing datepicker. see #149 /* this.$input.on('changeDate', function(e){ var $form = $(this).closest('form'); setTimeout(function() { $form.submit(); }, 200); }); */ }, /* For incorrect date bootstrap-datepicker returns current date that is not suitable for datefield. This function returns null for incorrect date. */ parseDate: function(str, format) { var date = null, formattedBack; if(str) { date = this.dpg.parseDate(str, format, this.options.datepicker.language); if(typeof str === 'string') { formattedBack = this.dpg.formatDate(date, format, this.options.datepicker.language); if(str !== formattedBack) { date = null; } } } return date; } }); Date.defaults = $.extend({}, $.fn.editabletypes.abstractinput.defaults, { /** @property tpl @default <div></div> **/ tpl:'<div class="editable-date well"></div>', /** @property inputclass @default null **/ inputclass: null, /** Format used for sending value to server. Also applied when converting date from <code>data-value</code> attribute.<br> Possible tokens are: <code>d, dd, m, mm, yy, yyyy</code> @property format @type string @default yyyy-mm-dd **/ format:'yyyy-mm-dd', /** Format used for displaying date. Also applied when converting date from element's text on init. If not specified equals to <code>format</code> @property viewformat @type string @default null **/ viewformat: null, /** Configuration of datepicker. Full list of options: http://vitalets.github.com/bootstrap-datepicker @property datepicker @type object @default { weekStart: 0, startView: 0, minViewMode: 0, autoclose: false } **/ datepicker:{ weekStart: 0, startView: 0, minViewMode: 0, autoclose: false }, /** Text shown as clear date button. If <code>false</code> clear button will not be rendered. @property clear @type boolean|string @default 'x clear' **/ clear: '&times; clear' }); $.fn.editabletypes.date = Date; }(window.jQuery)); /** Bootstrap datefield input - modification for inline mode. Shows normal <input type="text"> and binds popup datepicker. Automatically shown in inline mode. @class datefield @extends date @since 1.4.0 **/ (function ($) { "use strict"; var DateField = function (options) { this.init('datefield', options, DateField.defaults); this.initPicker(options, DateField.defaults); }; $.fn.editableutils.inherit(DateField, $.fn.editabletypes.date); $.extend(DateField.prototype, { render: function () { this.$input = this.$tpl.find('input'); this.setClass(); this.setAttr('placeholder'); //bootstrap-datepicker is set `bdateicker` to exclude conflict with jQuery UI one. (in date.js) this.$tpl.bdatepicker(this.options.datepicker); //need to disable original event handlers this.$input.off('focus keydown'); //update value of datepicker this.$input.keyup($.proxy(function(){ this.$tpl.removeData('date'); this.$tpl.bdatepicker('update'); }, this)); }, value2input: function(value) { this.$input.val(value ? this.dpg.formatDate(value, this.parsedViewFormat, this.options.datepicker.language) : ''); this.$tpl.bdatepicker('update'); }, input2value: function() { return this.html2value(this.$input.val()); }, activate: function() { $.fn.editabletypes.text.prototype.activate.call(this); }, autosubmit: function() { //reset autosubmit to empty } }); DateField.defaults = $.extend({}, $.fn.editabletypes.date.defaults, { /** @property tpl **/ tpl:'<div class="input-append date"><input type="text"/><span class="add-on"><i class="icon-th"></i></span></div>', /** @property inputclass @default 'input-small' **/ inputclass: 'input-small', /* datepicker config */ datepicker: { weekStart: 0, startView: 0, minViewMode: 0, autoclose: true } }); $.fn.editabletypes.datefield = DateField; }(window.jQuery)); /** Bootstrap-datetimepicker. Based on [smalot bootstrap-datetimepicker plugin](https://github.com/smalot/bootstrap-datetimepicker). Before usage you should manually include dependent js and css: <link href="css/datetimepicker.css" rel="stylesheet" type="text/css"></link> <script src="js/bootstrap-datetimepicker.js"></script> For **i18n** you should include js file from here: https://github.com/smalot/bootstrap-datetimepicker/tree/master/js/locales and set `language` option. @class datetime @extends abstractinput @final @since 1.4.4 @example <a href="#" id="last_seen" data-type="datetime" data-pk="1" data-url="/post" title="Select date & time">15/03/2013 12:45</a> <script> $(function(){ $('#last_seen').editable({ format: 'yyyy-mm-dd hh:ii', viewformat: 'dd/mm/yyyy hh:ii', datetimepicker: { weekStart: 1 } } }); }); </script> **/ (function ($) { "use strict"; var DateTime = function (options) { this.init('datetime', options, DateTime.defaults); this.initPicker(options, DateTime.defaults); }; $.fn.editableutils.inherit(DateTime, $.fn.editabletypes.abstractinput); $.extend(DateTime.prototype, { initPicker: function(options, defaults) { //'format' is set directly from settings or data-* attributes //by default viewformat equals to format if(!this.options.viewformat) { this.options.viewformat = this.options.format; } //try parse datetimepicker config defined as json string in data-datetimepicker options.datetimepicker = $.fn.editableutils.tryParseJson(options.datetimepicker, true); //overriding datetimepicker config (as by default jQuery extend() is not recursive) //since 1.4 datetimepicker internally uses viewformat instead of format. Format is for submit only this.options.datetimepicker = $.extend({}, defaults.datetimepicker, options.datetimepicker, { format: this.options.viewformat }); //language this.options.datetimepicker.language = this.options.datetimepicker.language || 'en'; //store DPglobal this.dpg = $.fn.datetimepicker.DPGlobal; //store parsed formats this.parsedFormat = this.dpg.parseFormat(this.options.format, this.options.formatType); this.parsedViewFormat = this.dpg.parseFormat(this.options.viewformat, this.options.formatType); }, render: function () { this.$input.datetimepicker(this.options.datetimepicker); //adjust container position when viewMode changes //see https://github.com/smalot/bootstrap-datetimepicker/pull/80 this.$input.on('changeMode', function(e) { var f = $(this).closest('form').parent(); //timeout here, otherwise container changes position before form has new size setTimeout(function(){ f.triggerHandler('resize'); }, 0); }); //"clear" link if(this.options.clear) { this.$clear = $('<a href="#"></a>').html(this.options.clear).click($.proxy(function(e){ e.preventDefault(); e.stopPropagation(); this.clear(); }, this)); this.$tpl.parent().append($('<div class="editable-clear">').append(this.$clear)); } }, value2html: function(value, element) { //formatDate works with UTCDate! var text = value ? this.dpg.formatDate(this.toUTC(value), this.parsedViewFormat, this.options.datetimepicker.language, this.options.formatType) : ''; if(element) { DateTime.superclass.value2html.call(this, text, element); } else { return text; } }, html2value: function(html) { //parseDate return utc date! var value = this.parseDate(html, this.parsedViewFormat); return value ? this.fromUTC(value) : null; }, value2str: function(value) { //formatDate works with UTCDate! return value ? this.dpg.formatDate(this.toUTC(value), this.parsedFormat, this.options.datetimepicker.language, this.options.formatType) : ''; }, str2value: function(str) { //parseDate return utc date! var value = this.parseDate(str, this.parsedFormat); return value ? this.fromUTC(value) : null; }, value2submit: function(value) { return this.value2str(value); }, value2input: function(value) { if(value) { this.$input.data('datetimepicker').setDate(value); } }, input2value: function() { //date may be cleared, in that case getDate() triggers error var dt = this.$input.data('datetimepicker'); return dt.date ? dt.getDate() : null; }, activate: function() { }, clear: function() { this.$input.data('datetimepicker').date = null; this.$input.find('.active').removeClass('active'); if(!this.options.showbuttons) { this.$input.closest('form').submit(); } }, autosubmit: function() { this.$input.on('mouseup', '.minute', function(e){ var $form = $(this).closest('form'); setTimeout(function() { $form.submit(); }, 200); }); }, //convert date from local to utc toUTC: function(value) { return value ? new Date(value.valueOf() - value.getTimezoneOffset() * 60000) : value; }, //convert date from utc to local fromUTC: function(value) { return value ? new Date(value.valueOf() + value.getTimezoneOffset() * 60000) : value; }, /* For incorrect date bootstrap-datetimepicker returns current date that is not suitable for datetimefield. This function returns null for incorrect date. */ parseDate: function(str, format) { var date = null, formattedBack; if(str) { date = this.dpg.parseDate(str, format, this.options.datetimepicker.language, this.options.formatType); if(typeof str === 'string') { formattedBack = this.dpg.formatDate(date, format, this.options.datetimepicker.language, this.options.formatType); if(str !== formattedBack) { date = null; } } } return date; } }); DateTime.defaults = $.extend({}, $.fn.editabletypes.abstractinput.defaults, { /** @property tpl @default <div></div> **/ tpl:'<div class="editable-date well"></div>', /** @property inputclass @default null **/ inputclass: null, /** Format used for sending value to server. Also applied when converting date from <code>data-value</code> attribute.<br> Possible tokens are: <code>d, dd, m, mm, yy, yyyy, h, i</code> @property format @type string @default yyyy-mm-dd hh:ii **/ format:'yyyy-mm-dd hh:ii', formatType:'standard', /** Format used for displaying date. Also applied when converting date from element's text on init. If not specified equals to <code>format</code> @property viewformat @type string @default null **/ viewformat: null, /** Configuration of datetimepicker. Full list of options: https://github.com/smalot/bootstrap-datetimepicker @property datetimepicker @type object @default { } **/ datetimepicker:{ todayHighlight: false, autoclose: false }, /** Text shown as clear date button. If <code>false</code> clear button will not be rendered. @property clear @type boolean|string @default 'x clear' **/ clear: '&times; clear' }); $.fn.editabletypes.datetime = DateTime; }(window.jQuery)); /** Bootstrap datetimefield input - datetime input for inline mode. Shows normal <input type="text"> and binds popup datetimepicker. Automatically shown in inline mode. @class datetimefield @extends datetime **/ (function ($) { "use strict"; var DateTimeField = function (options) { this.init('datetimefield', options, DateTimeField.defaults); this.initPicker(options, DateTimeField.defaults); }; $.fn.editableutils.inherit(DateTimeField, $.fn.editabletypes.datetime); $.extend(DateTimeField.prototype, { render: function () { this.$input = this.$tpl.find('input'); this.setClass(); this.setAttr('placeholder'); this.$tpl.datetimepicker(this.options.datetimepicker); //need to disable original event handlers this.$input.off('focus keydown'); //update value of datepicker this.$input.keyup($.proxy(function(){ this.$tpl.removeData('date'); this.$tpl.datetimepicker('update'); }, this)); }, value2input: function(value) { this.$input.val(this.value2html(value)); this.$tpl.datetimepicker('update'); }, input2value: function() { return this.html2value(this.$input.val()); }, activate: function() { $.fn.editabletypes.text.prototype.activate.call(this); }, autosubmit: function() { //reset autosubmit to empty } }); DateTimeField.defaults = $.extend({}, $.fn.editabletypes.datetime.defaults, { /** @property tpl **/ tpl:'<div class="input-append date"><input type="text"/><span class="add-on"><i class="icon-th"></i></span></div>', /** @property inputclass @default 'input-medium' **/ inputclass: 'input-medium', /* datetimepicker config */ datetimepicker:{ todayHighlight: false, autoclose: true } }); $.fn.editabletypes.datetimefield = DateTimeField; }(window.jQuery)); /** Typeahead input (bootstrap 2 only). Based on Twitter Bootstrap 2 [typeahead](http://getbootstrap.com/2.3.2/javascript.html#typeahead). Depending on `source` format typeahead operates in two modes: * **strings**: When `source` defined as array of strings, e.g. `['text1', 'text2', 'text3' ...]`. User can submit one of these strings or any text entered in input (even if it is not matching source). * **objects**: When `source` defined as array of objects, e.g. `[{value: 1, text: "text1"}, {value: 2, text: "text2"}, ...]`. User can submit only values that are in source (otherwise `null` is submitted). This is more like *dropdown* behavior. @class typeahead @extends list @since 1.4.1 @final @example <a href="#" id="country" data-type="typeahead" data-pk="1" data-url="/post" data-title="Input country"></a> <script> $(function(){ $('#country').editable({ value: 'ru', source: [ {value: 'gb', text: 'Great Britain'}, {value: 'us', text: 'United States'}, {value: 'ru', text: 'Russia'} ] }); }); </script> **/ (function ($) { "use strict"; var Constructor = function (options) { this.init('typeahead', options, Constructor.defaults); //overriding objects in config (as by default jQuery extend() is not recursive) this.options.typeahead = $.extend({}, Constructor.defaults.typeahead, { //set default methods for typeahead to work with objects matcher: this.matcher, sorter: this.sorter, highlighter: this.highlighter, updater: this.updater }, options.typeahead); }; $.fn.editableutils.inherit(Constructor, $.fn.editabletypes.list); $.extend(Constructor.prototype, { renderList: function() { this.$input = this.$tpl.is('input') ? this.$tpl : this.$tpl.find('input[type="text"]'); //set source of typeahead this.options.typeahead.source = this.sourceData; //apply typeahead this.$input.typeahead(this.options.typeahead); //patch some methods in typeahead var ta = this.$input.data('typeahead'); ta.render = $.proxy(this.typeaheadRender, ta); ta.select = $.proxy(this.typeaheadSelect, ta); ta.move = $.proxy(this.typeaheadMove, ta); this.renderClear(); this.setClass(); this.setAttr('placeholder'); }, value2htmlFinal: function(value, element) { if(this.getIsObjects()) { var items = $.fn.editableutils.itemsByValue(value, this.sourceData); value = items.length ? items[0].text : ''; } $.fn.editabletypes.abstractinput.prototype.value2html.call(this, value, element); }, html2value: function (html) { return html ? html : null; }, value2input: function(value) { if(this.getIsObjects()) { var items = $.fn.editableutils.itemsByValue(value, this.sourceData); this.$input.data('value', value).val(items.length ? items[0].text : ''); } else { this.$input.val(value); } }, input2value: function() { if(this.getIsObjects()) { var value = this.$input.data('value'), items = $.fn.editableutils.itemsByValue(value, this.sourceData); if(items.length && items[0].text.toLowerCase() === this.$input.val().toLowerCase()) { return value; } else { return null; //entered string not found in source } } else { return this.$input.val(); } }, /* if in sourceData values <> texts, typeahead in "objects" mode: user must pick some value from list, otherwise `null` returned. if all values == texts put typeahead in "strings" mode: anything what entered is submited. */ getIsObjects: function() { if(this.isObjects === undefined) { this.isObjects = false; for(var i=0; i<this.sourceData.length; i++) { if(this.sourceData[i].value !== this.sourceData[i].text) { this.isObjects = true; break; } } } return this.isObjects; }, /* Methods borrowed from text input */ activate: $.fn.editabletypes.text.prototype.activate, renderClear: $.fn.editabletypes.text.prototype.renderClear, postrender: $.fn.editabletypes.text.prototype.postrender, toggleClear: $.fn.editabletypes.text.prototype.toggleClear, clear: function() { $.fn.editabletypes.text.prototype.clear.call(this); this.$input.data('value', ''); }, /* Typeahead option methods used as defaults */ /*jshint eqeqeq:false, curly: false, laxcomma: true, asi: true*/ matcher: function (item) { return $.fn.typeahead.Constructor.prototype.matcher.call(this, item.text); }, sorter: function (items) { var beginswith = [] , caseSensitive = [] , caseInsensitive = [] , item , text; while (item = items.shift()) { text = item.text; if (!text.toLowerCase().indexOf(this.query.toLowerCase())) beginswith.push(item); else if (~text.indexOf(this.query)) caseSensitive.push(item); else caseInsensitive.push(item); } return beginswith.concat(caseSensitive, caseInsensitive); }, highlighter: function (item) { return $.fn.typeahead.Constructor.prototype.highlighter.call(this, item.text); }, updater: function (item) { this.$element.data('value', item.value); return item.text; }, /* Overwrite typeahead's render method to store objects. There are a lot of disscussion in bootstrap repo on this point and still no result. See https://github.com/twitter/bootstrap/issues/5967 This function just store item via jQuery data() method instead of attr('data-value') */ typeaheadRender: function (items) { var that = this; items = $(items).map(function (i, item) { // i = $(that.options.item).attr('data-value', item) i = $(that.options.item).data('item', item); i.find('a').html(that.highlighter(item)); return i[0]; }); //add option to disable autoselect of first line //see https://github.com/twitter/bootstrap/pull/4164 if (this.options.autoSelect) { items.first().addClass('active'); } this.$menu.html(items); return this; }, //add option to disable autoselect of first line //see https://github.com/twitter/bootstrap/pull/4164 typeaheadSelect: function () { var val = this.$menu.find('.active').data('item') if(this.options.autoSelect || val){ this.$element .val(this.updater(val)) .change() } return this.hide() }, /* if autoSelect = false and nothing matched we need extra press onEnter that is not convinient. This patch fixes it. */ typeaheadMove: function (e) { if (!this.shown) return switch(e.keyCode) { case 9: // tab case 13: // enter case 27: // escape if (!this.$menu.find('.active').length) return e.preventDefault() break case 38: // up arrow e.preventDefault() this.prev() break case 40: // down arrow e.preventDefault() this.next() break } e.stopPropagation() } /*jshint eqeqeq: true, curly: true, laxcomma: false, asi: false*/ }); Constructor.defaults = $.extend({}, $.fn.editabletypes.list.defaults, { /** @property tpl @default <input type="text"> **/ tpl:'<input type="text">', /** Configuration of typeahead. [Full list of options](http://getbootstrap.com/2.3.2/javascript.html#typeahead). @property typeahead @type object @default null **/ typeahead: null, /** Whether to show `clear` button @property clear @type boolean @default true **/ clear: true }); $.fn.editabletypes.typeahead = Constructor; }(window.jQuery));
admin/src/components/form/tests/inputtitle.spec.js
mparlak/mparlak.github.io
import React from 'react'; import expect from 'expect'; import { mount } from 'enzyme'; import InputTitle from '../InputTitle'; function setup(props = {title: 'GSoC'}) { let actions = { onChange: expect.createSpy() }; let component = mount( <InputTitle {...props} {...actions} /> ); return { component, textarea: component.find('textarea'), props, actions }; } describe('Components::InputTitle', () => { it('should return the current input value', () => { const { component, props} = setup(); }); it('should call onChange', () => { const { textarea, actions } = setup(); textarea.simulate('change'); expect(actions.onChange).toHaveBeenCalled(); }); });
fields/types/cloudinaryimage/CloudinaryImageFilter.js
ONode/keystone
import React from 'react'; import { SegmentedControl } from '../../../admin/client/App/elemental'; const OPTIONS = [ { label: 'Is Set', value: true }, { label: 'Is NOT Set', value: false }, ]; function getDefaultValue () { return { exists: true, }; } var CloudinaryImageFilter = React.createClass({ propTypes: { filter: React.PropTypes.shape({ exists: React.PropTypes.oneOf(OPTIONS.map(i => i.value)), }), }, statics: { getDefaultValue: getDefaultValue, }, getDefaultProps () { return { filter: getDefaultValue(), }; }, toggleExists (value) { this.props.onChange({ exists: value }); }, render () { const { filter } = this.props; return ( <SegmentedControl equalWidthSegments onChange={this.toggleExists} options={OPTIONS} value={filter.exists} /> ); }, }); module.exports = CloudinaryImageFilter;
ajax/libs/aui/5.6.5/aui/js/aui-all.js
jdanyow/cdnjs
!function(){"use strict";function a(c,d){p||(p=new o(function(b){b.forEach(function(b){a.init(b.addedNodes),f(b.removedNodes)})}),p.observe(document,{childList:!0,subtree:!0})),d||(d={}),"function"==typeof d&&(d={insert:d}),l(d,a.defaults);var e=m(c,d);d.ready&&n.sheet.insertRule(c+":not(."+d.classname+"),["+c+"]:not(."+d.classname+"),."+c+":not(."+d.classname+"){display:none}",n.sheet.cssRules.length);for(var g=e.existing(),h=0;h<g.length;h++)b(c,d,g[h]);return q[c]=d,e}function b(a,b,e){h(e,"blacklisted")||c(a,b,e,function(c){if(!c)return d(a,b,e);if(c!==e&&e.parentNode){var f=document.createComment("placeholder");if(e.parentNode.insertBefore(f,e),e.parentNode.removeChild(e),"string"==typeof c){var g=document.createElement("div");g.innerHTML=c,c=g.children}j(c,function(a){f.parentNode.insertBefore(a,f)}),f.parentNode.removeChild(f)}})}function c(a,b,c,d){var e=/^[^(]+\([^,)]+,/,f=b.ready;return d=d||function(){},h(c,a+".ready-called")?d():(h(c,a+".ready-called",!0),l(c,b.prototype),void(f&&e.test(f)?f(c,d):f?d(f(c)):d()))}function d(a,b,c){var d=b.insert;h(c,a+".insert-called")||c.parentNode&&(h(c,a+".insert-called",!0),g(a,b,c),i(c,b.classname),d&&d(c))}function e(a,b,c){!b.remove||h(c,"blacklisted")||h(c,a+".remove-called")||(h(c,a+".remove-called",!0),b.remove(c))}function f(a){j(a,function(a){f(a.children);for(var b in k(a))b in q&&e(b,q[b],a)})}function g(a,b,c){function d(a,b,c){(a.insert||a.update||a)(b,c)}function e(a,b,c,d){(a.update||a)(b,c,d)}function f(a,b,c){a.remove(b,c)}if(b.attributes&&!h(c,a+".attributes-called")){h(c,a+".attributes-called",!0);var g=new o(function(a){a.forEach(function(a){var g=a.attributeName,h=c.attributes[g],i=b.attributes[g];i&&(h&&null===a.oldValue&&(i.insert||i.update||i)?d(i,c,h.nodeValue):h&&null!==a.oldValue&&(i.update||i)?e(i,c,h.nodeValue,a.oldValue):!h&&i.remove&&f(i,c,a.oldValue))})});g.observe(c,{attributes:!0,attributeOldValue:!0});for(var i=0;i<c.attributes.length;i++){var j=c.attributes[i],k=b.attributes[j.nodeName];k&&d(k,c,j.nodeValue)}}}function h(a,b,c){return void 0===c?a.__SKATE_DATA&&a.__SKATE_DATA[b]:(a.__SKATE_DATA||(a.__SKATE_DATA={}),a.__SKATE_DATA[b]=c,a)}function i(a,b){a.classList?a.classList.add(b):a.className+=a.className?" "+b:b}function j(a,b){if(a){if(a.nodeType){if(1!==a.nodeType)return;a=[a]}if(a.length)for(var c=0;c<a.length;c++)a[c]&&1===a[c].nodeType&&b(a[c],c)}}function k(a){var b=h(a,"possible-ids");if(b)return b;var c=a.tagName.toLowerCase();b={},b[c]=c;for(var d=0;d<a.attributes.length;d++){var e=a.attributes[d].nodeName;b[e]=e}return a.className.split(" ").forEach(function(a){a&&(b[a]=a)}),h(a,"possible-ids",b),b}function l(a,b){for(var c in b)void 0===a[c]&&(a[c]=b[c]);return a}function m(b,d){var e=d.type.indexOf(a.types.TAG)>-1,f=d.type.indexOf(a.types.ATTR)>-1,g=d.type.indexOf(a.types.CLASS)>-1,h=function(){var a=[];return e&&a.push(b),f&&a.push("["+b+"]"),g&&a.push("."+b),a.join(", ")}(),i=function(){if(!e)throw new Error('Cannot construct "'+b+'" as a custom element.');var a=document.createElement(b);return c(b,d,a),a};return i.existing=function(a){return(a||document).querySelectorAll(i.selector())},i.selector=function(){return h},i}var n=document.createElement("style"),o=window.MutationObserver||window.WebkitMutationObserver||window.MozMutationObserver;o||(o=function(a){this.callback=a,this.elements=[]},o.prototype={observe:function(a,b){function c(c){return b.childList&&(b.subtree||c.target.parentNode===a)}function d(b){return b.target===a}function e(a,b){return l(b,{addedNodes:null,attributeName:null,attributeNamespace:null,nextSibling:a.target.nextSibling,oldValue:null,previousSibling:a.target.previousSibling,removedNodes:null,target:a.target,type:"childList"})}var f=this,g={},h={target:a,options:b,insertHandler:function(a){c(a)&&f.callback([e(a,{addedNodes:[a.target]})])},removeHandler:function(a){c(a)&&f.callback([e(a,{removedNodes:[a.target]})])},attributeHandler:function(a){d(a)&&(f.callback([e(a,{attributeName:a.attrName,oldValue:b.attributeOldValue?g[a.attrName]||a.prevValue||null:null,type:"attributes"})]),b.attributeOldValue&&(g[a.attrName]=a.newValue))}};return this.elements.push(h),b.childList&&(a.addEventListener("DOMSubtreeModified",h.insertHandler),a.addEventListener("DOMNodeRemoved",h.removeHandler)),b.attributes&&a.addEventListener("DOMAttrModified",h.attributeHandler),this},disconnect:function(){for(var a in this.elements){var b=this.elements[a];b.target.removeEventListener("DOMSubtreeModified",b.insertHandler),b.target.removeEventListener("DOMNodeRemoved",b.removeHandler),b.target.removeEventListener("DOMAttrModified",b.attributeHandler)}}});var p,q={};a.types={ANY:"act",ATTR:"a",CLASS:"c",NOATTR:"ct",NOCLASS:"at",NOTAG:"ac",TAG:"t"},a.defaults={attributes:!1,classname:"__skate",listen:!0,prototype:{},type:a.types.ANY},a.blacklist=function(b,c){return void 0===c&&(c=!0),j(b,function(b){h(b,"blacklisted",!0),c&&a.blacklist(b.children,!0)}),a},a.destroy=function(){return p.disconnect(),p=void 0,q={},a},a.init=function(c){return j(c,function(c){for(var d in k(c))d in q&&b(d,q[d],c);a.init(c.children)}),a},a.watch=function(a){return new o(a)},a.whitelist=function(b,c){return void 0===c&&(c=!0),j(b,function(b){h(b,"blacklisted",void 0),c&&a.whitelist(b.children,!0)}),a},document.getElementsByTagName("head")[0].appendChild(n),"function"==typeof define&&define.amd?define("skate",[],function(){return a}):window.skate=a}(),function(a,b){function c(a){var b=ob[a]={};return $.each(a.split(bb),function(a,c){b[c]=!0}),b}function d(a,c,d){if(d===b&&1===a.nodeType){var e="data-"+c.replace(qb,"-$1").toLowerCase();if(d=a.getAttribute(e),"string"==typeof d){try{d="true"===d?!0:"false"===d?!1:"null"===d?null:+d+""===d?+d:pb.test(d)?$.parseJSON(d):d}catch(f){}$.data(a,c,d)}else d=b}return d}function e(a){var b;for(b in a)if(("data"!==b||!$.isEmptyObject(a[b]))&&"toJSON"!==b)return!1;return!0}function f(){return!1}function g(){return!0}function h(a){return!a||!a.parentNode||11===a.parentNode.nodeType}function i(a,b){do a=a[b];while(a&&1!==a.nodeType);return a}function j(a,b,c){if(b=b||0,$.isFunction(b))return $.grep(a,function(a,d){var e=!!b.call(a,d,a);return e===c});if(b.nodeType)return $.grep(a,function(a){return a===b===c});if("string"==typeof b){var d=$.grep(a,function(a){return 1===a.nodeType});if(Kb.test(b))return $.filter(b,d,!c);b=$.filter(b,d)}return $.grep(a,function(a){return $.inArray(a,b)>=0===c})}function k(a){var b=Nb.split("|"),c=a.createDocumentFragment();if(c.createElement)for(;b.length;)c.createElement(b.pop());return c}function l(a,b){return a.getElementsByTagName(b)[0]||a.appendChild(a.ownerDocument.createElement(b))}function m(a,b){if(1===b.nodeType&&$.hasData(a)){var c,d,e,f=$._data(a),g=$._data(b,f),h=f.events;if(h){delete g.handle,g.events={};for(c in h)for(d=0,e=h[c].length;e>d;d++)$.event.add(b,c,h[c][d])}g.data&&(g.data=$.extend({},g.data))}}function n(a,b){var c;1===b.nodeType&&(b.clearAttributes&&b.clearAttributes(),b.mergeAttributes&&b.mergeAttributes(a),c=b.nodeName.toLowerCase(),"object"===c?(b.parentNode&&(b.outerHTML=a.outerHTML),$.support.html5Clone&&a.innerHTML&&!$.trim(b.innerHTML)&&(b.innerHTML=a.innerHTML)):"input"===c&&Xb.test(a.type)?(b.defaultChecked=b.checked=a.checked,b.value!==a.value&&(b.value=a.value)):"option"===c?b.selected=a.defaultSelected:"input"===c||"textarea"===c?b.defaultValue=a.defaultValue:"script"===c&&b.text!==a.text&&(b.text=a.text),b.removeAttribute($.expando))}function o(a){return"undefined"!=typeof a.getElementsByTagName?a.getElementsByTagName("*"):"undefined"!=typeof a.querySelectorAll?a.querySelectorAll("*"):[]}function p(a){Xb.test(a.type)&&(a.defaultChecked=a.checked)}function q(a,b){if(b in a)return b;for(var c=b.charAt(0).toUpperCase()+b.slice(1),d=b,e=rc.length;e--;)if(b=rc[e]+c,b in a)return b;return d}function r(a,b){return a=b||a,"none"===$.css(a,"display")||!$.contains(a.ownerDocument,a)}function s(a,b){for(var c,d,e=[],f=0,g=a.length;g>f;f++)c=a[f],c.style&&(e[f]=$._data(c,"olddisplay"),b?(e[f]||"none"!==c.style.display||(c.style.display=""),""===c.style.display&&r(c)&&(e[f]=$._data(c,"olddisplay",w(c.nodeName)))):(d=cc(c,"display"),e[f]||"none"===d||$._data(c,"olddisplay",d)));for(f=0;g>f;f++)c=a[f],c.style&&(b&&"none"!==c.style.display&&""!==c.style.display||(c.style.display=b?e[f]||"":"none"));return a}function t(a,b,c){var d=kc.exec(b);return d?Math.max(0,d[1]-(c||0))+(d[2]||"px"):b}function u(a,b,c,d){for(var e=c===(d?"border":"content")?4:"width"===b?1:0,f=0;4>e;e+=2)"margin"===c&&(f+=$.css(a,c+qc[e],!0)),d?("content"===c&&(f-=parseFloat(cc(a,"padding"+qc[e]))||0),"margin"!==c&&(f-=parseFloat(cc(a,"border"+qc[e]+"Width"))||0)):(f+=parseFloat(cc(a,"padding"+qc[e]))||0,"padding"!==c&&(f+=parseFloat(cc(a,"border"+qc[e]+"Width"))||0));return f}function v(a,b,c){var d="width"===b?a.offsetWidth:a.offsetHeight,e=!0,f=$.support.boxSizing&&"border-box"===$.css(a,"boxSizing");if(0>=d||null==d){if(d=cc(a,b),(0>d||null==d)&&(d=a.style[b]),lc.test(d))return d;e=f&&($.support.boxSizingReliable||d===a.style[b]),d=parseFloat(d)||0}return d+u(a,b,c||(f?"border":"content"),e)+"px"}function w(a){if(nc[a])return nc[a];var b=$("<"+a+">").appendTo(P.body),c=b.css("display");return b.remove(),("none"===c||""===c)&&(dc=P.body.appendChild(dc||$.extend(P.createElement("iframe"),{frameBorder:0,width:0,height:0})),ec&&dc.createElement||(ec=(dc.contentWindow||dc.contentDocument).document,ec.write("<!doctype html><html><body>"),ec.close()),b=ec.body.appendChild(ec.createElement(a)),c=cc(b,"display"),P.body.removeChild(dc)),nc[a]=c,c}function x(a,b,c,d){var e;if($.isArray(b))$.each(b,function(b,e){c||uc.test(a)?d(a,e):x(a+"["+("object"==typeof e?b:"")+"]",e,c,d)});else if(c||"object"!==$.type(b))d(a,b);else for(e in b)x(a+"["+e+"]",b[e],c,d)}function y(a){return function(b,c){"string"!=typeof b&&(c=b,b="*");var d,e,f,g=b.toLowerCase().split(bb),h=0,i=g.length;if($.isFunction(c))for(;i>h;h++)d=g[h],f=/^\+/.test(d),f&&(d=d.substr(1)||"*"),e=a[d]=a[d]||[],e[f?"unshift":"push"](c)}}function z(a,c,d,e,f,g){f=f||c.dataTypes[0],g=g||{},g[f]=!0;for(var h,i=a[f],j=0,k=i?i.length:0,l=a===Kc;k>j&&(l||!h);j++)h=i[j](c,d,e),"string"==typeof h&&(!l||g[h]?h=b:(c.dataTypes.unshift(h),h=z(a,c,d,e,h,g)));return!l&&h||g["*"]||(h=z(a,c,d,e,"*",g)),h}function A(a,c){var d,e,f=$.ajaxSettings.flatOptions||{};for(d in c)c[d]!==b&&((f[d]?a:e||(e={}))[d]=c[d]);e&&$.extend(!0,a,e)}function B(a,c,d){var e,f,g,h,i=a.contents,j=a.dataTypes,k=a.responseFields;for(f in k)f in d&&(c[k[f]]=d[f]);for(;"*"===j[0];)j.shift(),e===b&&(e=a.mimeType||c.getResponseHeader("content-type"));if(e)for(f in i)if(i[f]&&i[f].test(e)){j.unshift(f);break}if(j[0]in d)g=j[0];else{for(f in d){if(!j[0]||a.converters[f+" "+j[0]]){g=f;break}h||(h=f)}g=g||h}return g?(g!==j[0]&&j.unshift(g),d[g]):void 0}function C(a,b){var c,d,e,f,g=a.dataTypes.slice(),h=g[0],i={},j=0;if(a.dataFilter&&(b=a.dataFilter(b,a.dataType)),g[1])for(c in a.converters)i[c.toLowerCase()]=a.converters[c];for(;e=g[++j];)if("*"!==e){if("*"!==h&&h!==e){if(c=i[h+" "+e]||i["* "+e],!c)for(d in i)if(f=d.split(" "),f[1]===e&&(c=i[h+" "+f[0]]||i["* "+f[0]])){c===!0?c=i[d]:i[d]!==!0&&(e=f[0],g.splice(j--,0,e));break}if(c!==!0)if(c&&a["throws"])b=c(b);else try{b=c(b)}catch(k){return{state:"parsererror",error:c?k:"No conversion from "+h+" to "+e}}}h=e}return{state:"success",data:b}}function D(){try{return new a.XMLHttpRequest}catch(b){}}function E(){try{return new a.ActiveXObject("Microsoft.XMLHTTP")}catch(b){}}function F(){return setTimeout(function(){Vc=b},0),Vc=$.now()}function G(a,b){$.each(b,function(b,c){for(var d=(_c[b]||[]).concat(_c["*"]),e=0,f=d.length;f>e;e++)if(d[e].call(a,b,c))return})}function H(a,b,c){var d,e=0,f=$c.length,g=$.Deferred().always(function(){delete h.elem}),h=function(){for(var b=Vc||F(),c=Math.max(0,i.startTime+i.duration-b),d=c/i.duration||0,e=1-d,f=0,h=i.tweens.length;h>f;f++)i.tweens[f].run(e);return g.notifyWith(a,[i,e,c]),1>e&&h?c:(g.resolveWith(a,[i]),!1)},i=g.promise({elem:a,props:$.extend({},b),opts:$.extend(!0,{specialEasing:{}},c),originalProperties:b,originalOptions:c,startTime:Vc||F(),duration:c.duration,tweens:[],createTween:function(b,c){var d=$.Tween(a,i.opts,b,c,i.opts.specialEasing[b]||i.opts.easing);return i.tweens.push(d),d},stop:function(b){for(var c=0,d=b?i.tweens.length:0;d>c;c++)i.tweens[c].run(1);return b?g.resolveWith(a,[i,b]):g.rejectWith(a,[i,b]),this}}),j=i.props;for(I(j,i.opts.specialEasing);f>e;e++)if(d=$c[e].call(i,a,j,i.opts))return d;return G(i,j),$.isFunction(i.opts.start)&&i.opts.start.call(a,i),$.fx.timer($.extend(h,{anim:i,queue:i.opts.queue,elem:a})),i.progress(i.opts.progress).done(i.opts.done,i.opts.complete).fail(i.opts.fail).always(i.opts.always)}function I(a,b){var c,d,e,f,g;for(c in a)if(d=$.camelCase(c),e=b[d],f=a[c],$.isArray(f)&&(e=f[1],f=a[c]=f[0]),c!==d&&(a[d]=f,delete a[c]),g=$.cssHooks[d],g&&"expand"in g){f=g.expand(f),delete a[d];for(c in f)c in a||(a[c]=f[c],b[c]=e)}else b[d]=e}function J(a,b,c){var d,e,f,g,h,i,j,k,l,m=this,n=a.style,o={},p=[],q=a.nodeType&&r(a);c.queue||(k=$._queueHooks(a,"fx"),null==k.unqueued&&(k.unqueued=0,l=k.empty.fire,k.empty.fire=function(){k.unqueued||l()}),k.unqueued++,m.always(function(){m.always(function(){k.unqueued--,$.queue(a,"fx").length||k.empty.fire()})})),1===a.nodeType&&("height"in b||"width"in b)&&(c.overflow=[n.overflow,n.overflowX,n.overflowY],"inline"===$.css(a,"display")&&"none"===$.css(a,"float")&&($.support.inlineBlockNeedsLayout&&"inline"!==w(a.nodeName)?n.zoom=1:n.display="inline-block")),c.overflow&&(n.overflow="hidden",$.support.shrinkWrapBlocks||m.done(function(){n.overflow=c.overflow[0],n.overflowX=c.overflow[1],n.overflowY=c.overflow[2]}));for(d in b)if(f=b[d],Xc.exec(f)){if(delete b[d],i=i||"toggle"===f,f===(q?"hide":"show"))continue;p.push(d)}if(g=p.length){h=$._data(a,"fxshow")||$._data(a,"fxshow",{}),"hidden"in h&&(q=h.hidden),i&&(h.hidden=!q),q?$(a).show():m.done(function(){$(a).hide()}),m.done(function(){var b;$.removeData(a,"fxshow",!0);for(b in o)$.style(a,b,o[b])});for(d=0;g>d;d++)e=p[d],j=m.createTween(e,q?h[e]:0),o[e]=h[e]||$.style(a,e),e in h||(h[e]=j.start,q&&(j.end=j.start,j.start="width"===e||"height"===e?1:0))}}function K(a,b,c,d,e){return new K.prototype.init(a,b,c,d,e)}function L(a,b){var c,d={height:a},e=0;for(b=b?1:0;4>e;e+=2-b)c=qc[e],d["margin"+c]=d["padding"+c]=a;return b&&(d.opacity=d.width=a),d}function M(a){return $.isWindow(a)?a:9===a.nodeType?a.defaultView||a.parentWindow:!1}var N,O,P=a.document,Q=a.location,R=a.navigator,S=a.jQuery,T=a.$,U=Array.prototype.push,V=Array.prototype.slice,W=Array.prototype.indexOf,X=Object.prototype.toString,Y=Object.prototype.hasOwnProperty,Z=String.prototype.trim,$=function(a,b){return new $.fn.init(a,b,N)},_=/[\-+]?(?:\d*\.|)\d+(?:[eE][\-+]?\d+|)/.source,ab=/\S/,bb=/\s+/,cb=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,db=/^(?:[^#<]*(<[\w\W]+>)[^>]*$|#([\w\-]*)$)/,eb=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,fb=/^[\],:{}\s]*$/,gb=/(?:^|:|,)(?:\s*\[)+/g,hb=/\\(?:["\\\/bfnrt]|u[\da-fA-F]{4})/g,ib=/"[^"\\\r\n]*"|true|false|null|-?(?:\d\d*\.|)\d+(?:[eE][\-+]?\d+|)/g,jb=/^-ms-/,kb=/-([\da-z])/gi,lb=function(a,b){return(b+"").toUpperCase()},mb=function(){P.addEventListener?(P.removeEventListener("DOMContentLoaded",mb,!1),$.ready()):"complete"===P.readyState&&(P.detachEvent("onreadystatechange",mb),$.ready())},nb={};$.fn=$.prototype={constructor:$,init:function(a,c,d){var e,f,g;if(!a)return this;if(a.nodeType)return this.context=this[0]=a,this.length=1,this;if("string"==typeof a){if(e="<"===a.charAt(0)&&">"===a.charAt(a.length-1)&&a.length>=3?[null,a,null]:db.exec(a),!e||!e[1]&&c)return!c||c.jquery?(c||d).find(a):this.constructor(c).find(a);if(e[1])return c=c instanceof $?c[0]:c,g=c&&c.nodeType?c.ownerDocument||c:P,a=$.parseHTML(e[1],g,!0),eb.test(e[1])&&$.isPlainObject(c)&&this.attr.call(a,c,!0),$.merge(this,a);if(f=P.getElementById(e[2]),f&&f.parentNode){if(f.id!==e[2])return d.find(a);this.length=1,this[0]=f}return this.context=P,this.selector=a,this}return $.isFunction(a)?d.ready(a):(a.selector!==b&&(this.selector=a.selector,this.context=a.context),$.makeArray(a,this))},selector:"",jquery:"1.8.3",length:0,size:function(){return this.length},toArray:function(){return V.call(this)},get:function(a){return null==a?this.toArray():0>a?this[this.length+a]:this[a]},pushStack:function(a,b,c){var d=$.merge(this.constructor(),a);return d.prevObject=this,d.context=this.context,"find"===b?d.selector=this.selector+(this.selector?" ":"")+c:b&&(d.selector=this.selector+"."+b+"("+c+")"),d},each:function(a,b){return $.each(this,a,b)},ready:function(a){return $.ready.promise().done(a),this},eq:function(a){return a=+a,-1===a?this.slice(a):this.slice(a,a+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},slice:function(){return this.pushStack(V.apply(this,arguments),"slice",V.call(arguments).join(","))},map:function(a){return this.pushStack($.map(this,function(b,c){return a.call(b,c,b)}))},end:function(){return this.prevObject||this.constructor(null)},push:U,sort:[].sort,splice:[].splice},$.fn.init.prototype=$.fn,$.extend=$.fn.extend=function(){var a,c,d,e,f,g,h=arguments[0]||{},i=1,j=arguments.length,k=!1;for("boolean"==typeof h&&(k=h,h=arguments[1]||{},i=2),"object"==typeof h||$.isFunction(h)||(h={}),j===i&&(h=this,--i);j>i;i++)if(null!=(a=arguments[i]))for(c in a)d=h[c],e=a[c],h!==e&&(k&&e&&($.isPlainObject(e)||(f=$.isArray(e)))?(f?(f=!1,g=d&&$.isArray(d)?d:[]):g=d&&$.isPlainObject(d)?d:{},h[c]=$.extend(k,g,e)):e!==b&&(h[c]=e));return h},$.extend({noConflict:function(b){return a.$===$&&(a.$=T),b&&a.jQuery===$&&(a.jQuery=S),$},isReady:!1,readyWait:1,holdReady:function(a){a?$.readyWait++:$.ready(!0)},ready:function(a){if(a===!0?!--$.readyWait:!$.isReady){if(!P.body)return setTimeout($.ready,1);$.isReady=!0,a!==!0&&--$.readyWait>0||(O.resolveWith(P,[$]),$.fn.trigger&&$(P).trigger("ready").off("ready"))}},isFunction:function(a){return"function"===$.type(a)},isArray:Array.isArray||function(a){return"array"===$.type(a)},isWindow:function(a){return null!=a&&a==a.window},isNumeric:function(a){return!isNaN(parseFloat(a))&&isFinite(a)},type:function(a){return null==a?String(a):nb[X.call(a)]||"object"},isPlainObject:function(a){if(!a||"object"!==$.type(a)||a.nodeType||$.isWindow(a))return!1;try{if(a.constructor&&!Y.call(a,"constructor")&&!Y.call(a.constructor.prototype,"isPrototypeOf"))return!1}catch(c){return!1}var d;for(d in a);return d===b||Y.call(a,d)},isEmptyObject:function(a){var b;for(b in a)return!1;return!0},error:function(a){throw new Error(a)},parseHTML:function(a,b,c){var d;return a&&"string"==typeof a?("boolean"==typeof b&&(c=b,b=0),b=b||P,(d=eb.exec(a))?[b.createElement(d[1])]:(d=$.buildFragment([a],b,c?null:[]),$.merge([],(d.cacheable?$.clone(d.fragment):d.fragment).childNodes))):null},parseJSON:function(b){return b&&"string"==typeof b?(b=$.trim(b),a.JSON&&a.JSON.parse?a.JSON.parse(b):fb.test(b.replace(hb,"@").replace(ib,"]").replace(gb,""))?new Function("return "+b)():void $.error("Invalid JSON: "+b)):null},parseXML:function(c){var d,e;if(!c||"string"!=typeof c)return null;try{a.DOMParser?(e=new DOMParser,d=e.parseFromString(c,"text/xml")):(d=new ActiveXObject("Microsoft.XMLDOM"),d.async="false",d.loadXML(c))}catch(f){d=b}return d&&d.documentElement&&!d.getElementsByTagName("parsererror").length||$.error("Invalid XML: "+c),d},noop:function(){},globalEval:function(b){b&&ab.test(b)&&(a.execScript||function(b){a.eval.call(a,b)})(b)},camelCase:function(a){return a.replace(jb,"ms-").replace(kb,lb)},nodeName:function(a,b){return a.nodeName&&a.nodeName.toLowerCase()===b.toLowerCase()},each:function(a,c,d){var e,f=0,g=a.length,h=g===b||$.isFunction(a);if(d)if(h){for(e in a)if(c.apply(a[e],d)===!1)break}else for(;g>f&&c.apply(a[f++],d)!==!1;);else if(h){for(e in a)if(c.call(a[e],e,a[e])===!1)break}else for(;g>f&&c.call(a[f],f,a[f++])!==!1;);return a},trim:Z&&!Z.call("\ufeff\xa0")?function(a){return null==a?"":Z.call(a)}:function(a){return null==a?"":(a+"").replace(cb,"")},makeArray:function(a,b){var c,d=b||[];return null!=a&&(c=$.type(a),null==a.length||"string"===c||"function"===c||"regexp"===c||$.isWindow(a)?U.call(d,a):$.merge(d,a)),d},inArray:function(a,b,c){var d;if(b){if(W)return W.call(b,a,c);for(d=b.length,c=c?0>c?Math.max(0,d+c):c:0;d>c;c++)if(c in b&&b[c]===a)return c}return-1},merge:function(a,c){var d=c.length,e=a.length,f=0;if("number"==typeof d)for(;d>f;f++)a[e++]=c[f];else for(;c[f]!==b;)a[e++]=c[f++];return a.length=e,a},grep:function(a,b,c){var d,e=[],f=0,g=a.length;for(c=!!c;g>f;f++)d=!!b(a[f],f),c!==d&&e.push(a[f]);return e},map:function(a,c,d){var e,f,g=[],h=0,i=a.length,j=a instanceof $||i!==b&&"number"==typeof i&&(i>0&&a[0]&&a[i-1]||0===i||$.isArray(a));if(j)for(;i>h;h++)e=c(a[h],h,d),null!=e&&(g[g.length]=e);else for(f in a)e=c(a[f],f,d),null!=e&&(g[g.length]=e);return g.concat.apply([],g)},guid:1,proxy:function(a,c){var d,e,f;return"string"==typeof c&&(d=a[c],c=a,a=d),$.isFunction(a)?(e=V.call(arguments,2),f=function(){return a.apply(c,e.concat(V.call(arguments)))},f.guid=a.guid=a.guid||$.guid++,f):b},access:function(a,c,d,e,f,g,h){var i,j=null==d,k=0,l=a.length;if(d&&"object"==typeof d){for(k in d)$.access(a,c,k,d[k],1,g,e);f=1}else if(e!==b){if(i=h===b&&$.isFunction(e),j&&(i?(i=c,c=function(a,b,c){return i.call($(a),c)}):(c.call(a,e),c=null)),c)for(;l>k;k++)c(a[k],d,i?e.call(a[k],k,c(a[k],d)):e,h);f=1}return f?a:j?c.call(a):l?c(a[0],d):g},now:function(){return(new Date).getTime()}}),$.ready.promise=function(b){if(!O)if(O=$.Deferred(),"complete"===P.readyState)setTimeout($.ready,1);else if(P.addEventListener)P.addEventListener("DOMContentLoaded",mb,!1),a.addEventListener("load",$.ready,!1);else{P.attachEvent("onreadystatechange",mb),a.attachEvent("onload",$.ready);var c=!1;try{c=null==a.frameElement&&P.documentElement}catch(d){}c&&c.doScroll&&!function e(){if(!$.isReady){try{c.doScroll("left")}catch(a){return setTimeout(e,50)}$.ready()}}()}return O.promise(b)},$.each("Boolean Number String Function Array Date RegExp Object".split(" "),function(a,b){nb["[object "+b+"]"]=b.toLowerCase()}),N=$(P);var ob={};$.Callbacks=function(a){a="string"==typeof a?ob[a]||c(a):$.extend({},a);var d,e,f,g,h,i,j=[],k=!a.once&&[],l=function(b){for(d=a.memory&&b,e=!0,i=g||0,g=0,h=j.length,f=!0;j&&h>i;i++)if(j[i].apply(b[0],b[1])===!1&&a.stopOnFalse){d=!1;break}f=!1,j&&(k?k.length&&l(k.shift()):d?j=[]:m.disable())},m={add:function(){if(j){var b=j.length;!function c(b){$.each(b,function(b,d){var e=$.type(d);"function"===e?a.unique&&m.has(d)||j.push(d):d&&d.length&&"string"!==e&&c(d)})}(arguments),f?h=j.length:d&&(g=b,l(d))}return this},remove:function(){return j&&$.each(arguments,function(a,b){for(var c;(c=$.inArray(b,j,c))>-1;)j.splice(c,1),f&&(h>=c&&h--,i>=c&&i--)}),this},has:function(a){return $.inArray(a,j)>-1},empty:function(){return j=[],this},disable:function(){return j=k=d=b,this},disabled:function(){return!j},lock:function(){return k=b,d||m.disable(),this},locked:function(){return!k},fireWith:function(a,b){return b=b||[],b=[a,b.slice?b.slice():b],!j||e&&!k||(f?k.push(b):l(b)),this},fire:function(){return m.fireWith(this,arguments),this},fired:function(){return!!e}};return m},$.extend({Deferred:function(a){var b=[["resolve","done",$.Callbacks("once memory"),"resolved"],["reject","fail",$.Callbacks("once memory"),"rejected"],["notify","progress",$.Callbacks("memory")]],c="pending",d={state:function(){return c},always:function(){return e.done(arguments).fail(arguments),this},then:function(){var a=arguments;return $.Deferred(function(c){$.each(b,function(b,d){var f=d[0],g=a[b];e[d[1]]($.isFunction(g)?function(){var a=g.apply(this,arguments);a&&$.isFunction(a.promise)?a.promise().done(c.resolve).fail(c.reject).progress(c.notify):c[f+"With"](this===e?c:this,[a])}:c[f])}),a=null}).promise()},promise:function(a){return null!=a?$.extend(a,d):d}},e={};return d.pipe=d.then,$.each(b,function(a,f){var g=f[2],h=f[3];d[f[1]]=g.add,h&&g.add(function(){c=h},b[1^a][2].disable,b[2][2].lock),e[f[0]]=g.fire,e[f[0]+"With"]=g.fireWith}),d.promise(e),a&&a.call(e,e),e},when:function(a){var b,c,d,e=0,f=V.call(arguments),g=f.length,h=1!==g||a&&$.isFunction(a.promise)?g:0,i=1===h?a:$.Deferred(),j=function(a,c,d){return function(e){c[a]=this,d[a]=arguments.length>1?V.call(arguments):e,d===b?i.notifyWith(c,d):--h||i.resolveWith(c,d)}};if(g>1)for(b=new Array(g),c=new Array(g),d=new Array(g);g>e;e++)f[e]&&$.isFunction(f[e].promise)?f[e].promise().done(j(e,d,f)).fail(i.reject).progress(j(e,c,b)):--h;return h||i.resolveWith(d,f),i.promise()}}),$.support=function(){var b,c,d,e,f,g,h,i,j,k,l,m=P.createElement("div");if(m.setAttribute("className","t"),m.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",c=m.getElementsByTagName("*"),d=m.getElementsByTagName("a")[0],!c||!d||!c.length)return{};e=P.createElement("select"),f=e.appendChild(P.createElement("option")),g=m.getElementsByTagName("input")[0],d.style.cssText="top:1px;float:left;opacity:.5",b={leadingWhitespace:3===m.firstChild.nodeType,tbody:!m.getElementsByTagName("tbody").length,htmlSerialize:!!m.getElementsByTagName("link").length,style:/top/.test(d.getAttribute("style")),hrefNormalized:"/a"===d.getAttribute("href"),opacity:/^0.5/.test(d.style.opacity),cssFloat:!!d.style.cssFloat,checkOn:"on"===g.value,optSelected:f.selected,getSetAttribute:"t"!==m.className,enctype:!!P.createElement("form").enctype,html5Clone:"<:nav></:nav>"!==P.createElement("nav").cloneNode(!0).outerHTML,boxModel:"CSS1Compat"===P.compatMode,submitBubbles:!0,changeBubbles:!0,focusinBubbles:!1,deleteExpando:!0,noCloneEvent:!0,inlineBlockNeedsLayout:!1,shrinkWrapBlocks:!1,reliableMarginRight:!0,boxSizingReliable:!0,pixelPosition:!1},g.checked=!0,b.noCloneChecked=g.cloneNode(!0).checked,e.disabled=!0,b.optDisabled=!f.disabled;try{delete m.test}catch(n){b.deleteExpando=!1}if(!m.addEventListener&&m.attachEvent&&m.fireEvent&&(m.attachEvent("onclick",l=function(){b.noCloneEvent=!1}),m.cloneNode(!0).fireEvent("onclick"),m.detachEvent("onclick",l)),g=P.createElement("input"),g.value="t",g.setAttribute("type","radio"),b.radioValue="t"===g.value,g.setAttribute("checked","checked"),g.setAttribute("name","t"),m.appendChild(g),h=P.createDocumentFragment(),h.appendChild(m.lastChild),b.checkClone=h.cloneNode(!0).cloneNode(!0).lastChild.checked,b.appendChecked=g.checked,h.removeChild(g),h.appendChild(m),m.attachEvent)for(j in{submit:!0,change:!0,focusin:!0})i="on"+j,k=i in m,k||(m.setAttribute(i,"return;"),k="function"==typeof m[i]),b[j+"Bubbles"]=k;return $(function(){var c,d,e,f,g="padding:0;margin:0;border:0;display:block;overflow:hidden;",h=P.getElementsByTagName("body")[0];h&&(c=P.createElement("div"),c.style.cssText="visibility:hidden;border:0;width:0;height:0;position:static;top:0;margin-top:1px",h.insertBefore(c,h.firstChild),d=P.createElement("div"),c.appendChild(d),d.innerHTML="<table><tr><td></td><td>t</td></tr></table>",e=d.getElementsByTagName("td"),e[0].style.cssText="padding:0;margin:0;border:0;display:none",k=0===e[0].offsetHeight,e[0].style.display="",e[1].style.display="none",b.reliableHiddenOffsets=k&&0===e[0].offsetHeight,d.innerHTML="",d.style.cssText="box-sizing:border-box;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;padding:1px;border:1px;display:block;width:4px;margin-top:1%;position:absolute;top:1%;",b.boxSizing=4===d.offsetWidth,b.doesNotIncludeMarginInBodyOffset=1!==h.offsetTop,a.getComputedStyle&&(b.pixelPosition="1%"!==(a.getComputedStyle(d,null)||{}).top,b.boxSizingReliable="4px"===(a.getComputedStyle(d,null)||{width:"4px"}).width,f=P.createElement("div"),f.style.cssText=d.style.cssText=g,f.style.marginRight=f.style.width="0",d.style.width="1px",d.appendChild(f),b.reliableMarginRight=!parseFloat((a.getComputedStyle(f,null)||{}).marginRight)),"undefined"!=typeof d.style.zoom&&(d.innerHTML="",d.style.cssText=g+"width:1px;padding:1px;display:inline;zoom:1",b.inlineBlockNeedsLayout=3===d.offsetWidth,d.style.display="block",d.style.overflow="visible",d.innerHTML="<div></div>",d.firstChild.style.width="5px",b.shrinkWrapBlocks=3!==d.offsetWidth,c.style.zoom=1),h.removeChild(c),c=d=e=f=null)}),h.removeChild(m),c=d=e=f=g=h=m=null,b}();var pb=/(?:\{[\s\S]*\}|\[[\s\S]*\])$/,qb=/([A-Z])/g;$.extend({cache:{},deletedIds:[],uuid:0,expando:"jQuery"+($.fn.jquery+Math.random()).replace(/\D/g,""),noData:{embed:!0,object:"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000",applet:!0},hasData:function(a){return a=a.nodeType?$.cache[a[$.expando]]:a[$.expando],!!a&&!e(a)},data:function(a,c,d,e){if($.acceptData(a)){var f,g,h=$.expando,i="string"==typeof c,j=a.nodeType,k=j?$.cache:a,l=j?a[h]:a[h]&&h;if(l&&k[l]&&(e||k[l].data)||!i||d!==b)return l||(j?a[h]=l=$.deletedIds.pop()||$.guid++:l=h),k[l]||(k[l]={},j||(k[l].toJSON=$.noop)),("object"==typeof c||"function"==typeof c)&&(e?k[l]=$.extend(k[l],c):k[l].data=$.extend(k[l].data,c)),f=k[l],e||(f.data||(f.data={}),f=f.data),d!==b&&(f[$.camelCase(c)]=d),i?(g=f[c],null==g&&(g=f[$.camelCase(c)])):g=f,g}},removeData:function(a,b,c){if($.acceptData(a)){var d,f,g,h=a.nodeType,i=h?$.cache:a,j=h?a[$.expando]:$.expando;if(i[j]){if(b&&(d=c?i[j]:i[j].data)){$.isArray(b)||(b in d?b=[b]:(b=$.camelCase(b),b=b in d?[b]:b.split(" ")));for(f=0,g=b.length;g>f;f++)delete d[b[f]];if(!(c?e:$.isEmptyObject)(d))return}(c||(delete i[j].data,e(i[j])))&&(h?$.cleanData([a],!0):$.support.deleteExpando||i!=i.window?delete i[j]:i[j]=null)}}},_data:function(a,b,c){return $.data(a,b,c,!0)},acceptData:function(a){var b=a.nodeName&&$.noData[a.nodeName.toLowerCase()];return!b||b!==!0&&a.getAttribute("classid")===b}}),$.fn.extend({data:function(a,c){var e,f,g,h,i,j=this[0],k=0,l=null;if(a===b){if(this.length&&(l=$.data(j),1===j.nodeType&&!$._data(j,"parsedAttrs"))){for(g=j.attributes,i=g.length;i>k;k++)h=g[k].name,h.indexOf("data-")||(h=$.camelCase(h.substring(5)),d(j,h,l[h]));$._data(j,"parsedAttrs",!0)}return l}return"object"==typeof a?this.each(function(){$.data(this,a)}):(e=a.split(".",2),e[1]=e[1]?"."+e[1]:"",f=e[1]+"!",$.access(this,function(c){return c===b?(l=this.triggerHandler("getData"+f,[e[0]]),l===b&&j&&(l=$.data(j,a),l=d(j,a,l)),l===b&&e[1]?this.data(e[0]):l):(e[1]=c,void this.each(function(){var b=$(this);b.triggerHandler("setData"+f,e),$.data(this,a,c),b.triggerHandler("changeData"+f,e)}))},null,c,arguments.length>1,null,!1))},removeData:function(a){return this.each(function(){$.removeData(this,a)})}}),$.extend({queue:function(a,b,c){var d;return a?(b=(b||"fx")+"queue",d=$._data(a,b),c&&(!d||$.isArray(c)?d=$._data(a,b,$.makeArray(c)):d.push(c)),d||[]):void 0},dequeue:function(a,b){b=b||"fx";var c=$.queue(a,b),d=c.length,e=c.shift(),f=$._queueHooks(a,b),g=function(){$.dequeue(a,b)};"inprogress"===e&&(e=c.shift(),d--),e&&("fx"===b&&c.unshift("inprogress"),delete f.stop,e.call(a,g,f)),!d&&f&&f.empty.fire()},_queueHooks:function(a,b){var c=b+"queueHooks";return $._data(a,c)||$._data(a,c,{empty:$.Callbacks("once memory").add(function(){$.removeData(a,b+"queue",!0),$.removeData(a,c,!0)})})}}),$.fn.extend({queue:function(a,c){var d=2;return"string"!=typeof a&&(c=a,a="fx",d--),arguments.length<d?$.queue(this[0],a):c===b?this:this.each(function(){var b=$.queue(this,a,c);$._queueHooks(this,a),"fx"===a&&"inprogress"!==b[0]&&$.dequeue(this,a)})},dequeue:function(a){return this.each(function(){$.dequeue(this,a)})},delay:function(a,b){return a=$.fx?$.fx.speeds[a]||a:a,b=b||"fx",this.queue(b,function(b,c){var d=setTimeout(b,a);c.stop=function(){clearTimeout(d)}})},clearQueue:function(a){return this.queue(a||"fx",[])},promise:function(a,c){var d,e=1,f=$.Deferred(),g=this,h=this.length,i=function(){--e||f.resolveWith(g,[g])};for("string"!=typeof a&&(c=a,a=b),a=a||"fx";h--;)d=$._data(g[h],a+"queueHooks"),d&&d.empty&&(e++,d.empty.add(i));return i(),f.promise(c)}});var rb,sb,tb,ub=/[\t\r\n]/g,vb=/\r/g,wb=/^(?:button|input)$/i,xb=/^(?:button|input|object|select|textarea)$/i,yb=/^a(?:rea|)$/i,zb=/^(?:autofocus|autoplay|async|checked|controls|defer|disabled|hidden|loop|multiple|open|readonly|required|scoped|selected)$/i,Ab=$.support.getSetAttribute; $.fn.extend({attr:function(a,b){return $.access(this,$.attr,a,b,arguments.length>1)},removeAttr:function(a){return this.each(function(){$.removeAttr(this,a)})},prop:function(a,b){return $.access(this,$.prop,a,b,arguments.length>1)},removeProp:function(a){return a=$.propFix[a]||a,this.each(function(){try{this[a]=b,delete this[a]}catch(c){}})},addClass:function(a){var b,c,d,e,f,g,h;if($.isFunction(a))return this.each(function(b){$(this).addClass(a.call(this,b,this.className))});if(a&&"string"==typeof a)for(b=a.split(bb),c=0,d=this.length;d>c;c++)if(e=this[c],1===e.nodeType)if(e.className||1!==b.length){for(f=" "+e.className+" ",g=0,h=b.length;h>g;g++)f.indexOf(" "+b[g]+" ")<0&&(f+=b[g]+" ");e.className=$.trim(f)}else e.className=a;return this},removeClass:function(a){var c,d,e,f,g,h,i;if($.isFunction(a))return this.each(function(b){$(this).removeClass(a.call(this,b,this.className))});if(a&&"string"==typeof a||a===b)for(c=(a||"").split(bb),h=0,i=this.length;i>h;h++)if(e=this[h],1===e.nodeType&&e.className){for(d=(" "+e.className+" ").replace(ub," "),f=0,g=c.length;g>f;f++)for(;d.indexOf(" "+c[f]+" ")>=0;)d=d.replace(" "+c[f]+" "," ");e.className=a?$.trim(d):""}return this},toggleClass:function(a,b){var c=typeof a,d="boolean"==typeof b;return this.each($.isFunction(a)?function(c){$(this).toggleClass(a.call(this,c,this.className,b),b)}:function(){if("string"===c)for(var e,f=0,g=$(this),h=b,i=a.split(bb);e=i[f++];)h=d?h:!g.hasClass(e),g[h?"addClass":"removeClass"](e);else("undefined"===c||"boolean"===c)&&(this.className&&$._data(this,"__className__",this.className),this.className=this.className||a===!1?"":$._data(this,"__className__")||"")})},hasClass:function(a){for(var b=" "+a+" ",c=0,d=this.length;d>c;c++)if(1===this[c].nodeType&&(" "+this[c].className+" ").replace(ub," ").indexOf(b)>=0)return!0;return!1},val:function(a){var c,d,e,f=this[0];{if(arguments.length)return e=$.isFunction(a),this.each(function(d){var f,g=$(this);1===this.nodeType&&(f=e?a.call(this,d,g.val()):a,null==f?f="":"number"==typeof f?f+="":$.isArray(f)&&(f=$.map(f,function(a){return null==a?"":a+""})),c=$.valHooks[this.type]||$.valHooks[this.nodeName.toLowerCase()],c&&"set"in c&&c.set(this,f,"value")!==b||(this.value=f))});if(f)return c=$.valHooks[f.type]||$.valHooks[f.nodeName.toLowerCase()],c&&"get"in c&&(d=c.get(f,"value"))!==b?d:(d=f.value,"string"==typeof d?d.replace(vb,""):null==d?"":d)}}}),$.extend({valHooks:{option:{get:function(a){var b=a.attributes.value;return!b||b.specified?a.value:a.text}},select:{get:function(a){for(var b,c,d=a.options,e=a.selectedIndex,f="select-one"===a.type||0>e,g=f?null:[],h=f?e+1:d.length,i=0>e?h:f?e:0;h>i;i++)if(c=d[i],!(!c.selected&&i!==e||($.support.optDisabled?c.disabled:null!==c.getAttribute("disabled"))||c.parentNode.disabled&&$.nodeName(c.parentNode,"optgroup"))){if(b=$(c).val(),f)return b;g.push(b)}return g},set:function(a,b){var c=$.makeArray(b);return $(a).find("option").each(function(){this.selected=$.inArray($(this).val(),c)>=0}),c.length||(a.selectedIndex=-1),c}}},attrFn:{},attr:function(a,c,d,e){var f,g,h,i=a.nodeType;if(a&&3!==i&&8!==i&&2!==i)return e&&$.isFunction($.fn[c])?$(a)[c](d):"undefined"==typeof a.getAttribute?$.prop(a,c,d):(h=1!==i||!$.isXMLDoc(a),h&&(c=c.toLowerCase(),g=$.attrHooks[c]||(zb.test(c)?sb:rb)),d!==b?null===d?void $.removeAttr(a,c):g&&"set"in g&&h&&(f=g.set(a,d,c))!==b?f:(a.setAttribute(c,d+""),d):g&&"get"in g&&h&&null!==(f=g.get(a,c))?f:(f=a.getAttribute(c),null===f?b:f))},removeAttr:function(a,b){var c,d,e,f,g=0;if(b&&1===a.nodeType)for(d=b.split(bb);g<d.length;g++)e=d[g],e&&(c=$.propFix[e]||e,f=zb.test(e),f||$.attr(a,e,""),a.removeAttribute(Ab?e:c),f&&c in a&&(a[c]=!1))},attrHooks:{type:{set:function(a,b){if(wb.test(a.nodeName)&&a.parentNode)$.error("type property can't be changed");else if(!$.support.radioValue&&"radio"===b&&$.nodeName(a,"input")){var c=a.value;return a.setAttribute("type",b),c&&(a.value=c),b}}},value:{get:function(a,b){return rb&&$.nodeName(a,"button")?rb.get(a,b):b in a?a.value:null},set:function(a,b,c){return rb&&$.nodeName(a,"button")?rb.set(a,b,c):void(a.value=b)}}},propFix:{tabindex:"tabIndex",readonly:"readOnly","for":"htmlFor","class":"className",maxlength:"maxLength",cellspacing:"cellSpacing",cellpadding:"cellPadding",rowspan:"rowSpan",colspan:"colSpan",usemap:"useMap",frameborder:"frameBorder",contenteditable:"contentEditable"},prop:function(a,c,d){var e,f,g,h=a.nodeType;if(a&&3!==h&&8!==h&&2!==h)return g=1!==h||!$.isXMLDoc(a),g&&(c=$.propFix[c]||c,f=$.propHooks[c]),d!==b?f&&"set"in f&&(e=f.set(a,d,c))!==b?e:a[c]=d:f&&"get"in f&&null!==(e=f.get(a,c))?e:a[c]},propHooks:{tabIndex:{get:function(a){var c=a.getAttributeNode("tabindex");return c&&c.specified?parseInt(c.value,10):xb.test(a.nodeName)||yb.test(a.nodeName)&&a.href?0:b}}}}),sb={get:function(a,c){var d,e=$.prop(a,c);return e===!0||"boolean"!=typeof e&&(d=a.getAttributeNode(c))&&d.nodeValue!==!1?c.toLowerCase():b},set:function(a,b,c){var d;return b===!1?$.removeAttr(a,c):(d=$.propFix[c]||c,d in a&&(a[d]=!0),a.setAttribute(c,c.toLowerCase())),c}},Ab||(tb={name:!0,id:!0,coords:!0},rb=$.valHooks.button={get:function(a,c){var d;return d=a.getAttributeNode(c),d&&(tb[c]?""!==d.value:d.specified)?d.value:b},set:function(a,b,c){var d=a.getAttributeNode(c);return d||(d=P.createAttribute(c),a.setAttributeNode(d)),d.value=b+""}},$.each(["width","height"],function(a,b){$.attrHooks[b]=$.extend($.attrHooks[b],{set:function(a,c){return""===c?(a.setAttribute(b,"auto"),c):void 0}})}),$.attrHooks.contenteditable={get:rb.get,set:function(a,b,c){""===b&&(b="false"),rb.set(a,b,c)}}),$.support.hrefNormalized||$.each(["href","src","width","height"],function(a,c){$.attrHooks[c]=$.extend($.attrHooks[c],{get:function(a){var d=a.getAttribute(c,2);return null===d?b:d}})}),$.support.style||($.attrHooks.style={get:function(a){return a.style.cssText.toLowerCase()||b},set:function(a,b){return a.style.cssText=b+""}}),$.support.optSelected||($.propHooks.selected=$.extend($.propHooks.selected,{get:function(a){var b=a.parentNode;return b&&(b.selectedIndex,b.parentNode&&b.parentNode.selectedIndex),null}})),$.support.enctype||($.propFix.enctype="encoding"),$.support.checkOn||$.each(["radio","checkbox"],function(){$.valHooks[this]={get:function(a){return null===a.getAttribute("value")?"on":a.value}}}),$.each(["radio","checkbox"],function(){$.valHooks[this]=$.extend($.valHooks[this],{set:function(a,b){return $.isArray(b)?a.checked=$.inArray($(a).val(),b)>=0:void 0}})});var Bb=/^(?:textarea|input|select)$/i,Cb=/^([^\.]*|)(?:\.(.+)|)$/,Db=/(?:^|\s)hover(\.\S+|)\b/,Eb=/^key/,Fb=/^(?:mouse|contextmenu)|click/,Gb=/^(?:focusinfocus|focusoutblur)$/,Hb=function(a){return $.event.special.hover?a:a.replace(Db,"mouseenter$1 mouseleave$1")};$.event={add:function(a,c,d,e,f){var g,h,i,j,k,l,m,n,o,p,q;if(3!==a.nodeType&&8!==a.nodeType&&c&&d&&(g=$._data(a))){for(d.handler&&(o=d,d=o.handler,f=o.selector),d.guid||(d.guid=$.guid++),i=g.events,i||(g.events=i={}),h=g.handle,h||(g.handle=h=function(a){return"undefined"==typeof $||a&&$.event.triggered===a.type?b:$.event.dispatch.apply(h.elem,arguments)},h.elem=a),c=$.trim(Hb(c)).split(" "),j=0;j<c.length;j++)k=Cb.exec(c[j])||[],l=k[1],m=(k[2]||"").split(".").sort(),q=$.event.special[l]||{},l=(f?q.delegateType:q.bindType)||l,q=$.event.special[l]||{},n=$.extend({type:l,origType:k[1],data:e,handler:d,guid:d.guid,selector:f,needsContext:f&&$.expr.match.needsContext.test(f),namespace:m.join(".")},o),p=i[l],p||(p=i[l]=[],p.delegateCount=0,q.setup&&q.setup.call(a,e,m,h)!==!1||(a.addEventListener?a.addEventListener(l,h,!1):a.attachEvent&&a.attachEvent("on"+l,h))),q.add&&(q.add.call(a,n),n.handler.guid||(n.handler.guid=d.guid)),f?p.splice(p.delegateCount++,0,n):p.push(n),$.event.global[l]=!0;a=null}},global:{},remove:function(a,b,c,d,e){var f,g,h,i,j,k,l,m,n,o,p,q=$.hasData(a)&&$._data(a);if(q&&(m=q.events)){for(b=$.trim(Hb(b||"")).split(" "),f=0;f<b.length;f++)if(g=Cb.exec(b[f])||[],h=i=g[1],j=g[2],h){for(n=$.event.special[h]||{},h=(d?n.delegateType:n.bindType)||h,o=m[h]||[],k=o.length,j=j?new RegExp("(^|\\.)"+j.split(".").sort().join("\\.(?:.*\\.|)")+"(\\.|$)"):null,l=0;l<o.length;l++)p=o[l],!e&&i!==p.origType||c&&c.guid!==p.guid||j&&!j.test(p.namespace)||d&&d!==p.selector&&("**"!==d||!p.selector)||(o.splice(l--,1),p.selector&&o.delegateCount--,n.remove&&n.remove.call(a,p));0===o.length&&k!==o.length&&(n.teardown&&n.teardown.call(a,j,q.handle)!==!1||$.removeEvent(a,h,q.handle),delete m[h])}else for(h in m)$.event.remove(a,h+b[f],c,d,!0);$.isEmptyObject(m)&&(delete q.handle,$.removeData(a,"events",!0))}},customEvent:{getData:!0,setData:!0,changeData:!0},trigger:function(c,d,e,f){if(!e||3!==e.nodeType&&8!==e.nodeType){var g,h,i,j,k,l,m,n,o,p,q=c.type||c,r=[];if(!Gb.test(q+$.event.triggered)&&(q.indexOf("!")>=0&&(q=q.slice(0,-1),h=!0),q.indexOf(".")>=0&&(r=q.split("."),q=r.shift(),r.sort()),e&&!$.event.customEvent[q]||$.event.global[q]))if(c="object"==typeof c?c[$.expando]?c:new $.Event(q,c):new $.Event(q),c.type=q,c.isTrigger=!0,c.exclusive=h,c.namespace=r.join("."),c.namespace_re=c.namespace?new RegExp("(^|\\.)"+r.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,l=q.indexOf(":")<0?"on"+q:"",e){if(c.result=b,c.target||(c.target=e),d=null!=d?$.makeArray(d):[],d.unshift(c),m=$.event.special[q]||{},!m.trigger||m.trigger.apply(e,d)!==!1){if(o=[[e,m.bindType||q]],!f&&!m.noBubble&&!$.isWindow(e)){for(p=m.delegateType||q,j=Gb.test(p+q)?e:e.parentNode,k=e;j;j=j.parentNode)o.push([j,p]),k=j;k===(e.ownerDocument||P)&&o.push([k.defaultView||k.parentWindow||a,p])}for(i=0;i<o.length&&!c.isPropagationStopped();i++)j=o[i][0],c.type=o[i][1],n=($._data(j,"events")||{})[c.type]&&$._data(j,"handle"),n&&n.apply(j,d),n=l&&j[l],n&&$.acceptData(j)&&n.apply&&n.apply(j,d)===!1&&c.preventDefault();return c.type=q,f||c.isDefaultPrevented()||m._default&&m._default.apply(e.ownerDocument,d)!==!1||"click"===q&&$.nodeName(e,"a")||!$.acceptData(e)||l&&e[q]&&("focus"!==q&&"blur"!==q||0!==c.target.offsetWidth)&&!$.isWindow(e)&&(k=e[l],k&&(e[l]=null),$.event.triggered=q,e[q](),$.event.triggered=b,k&&(e[l]=k)),c.result}}else{g=$.cache;for(i in g)g[i].events&&g[i].events[q]&&$.event.trigger(c,d,g[i].handle.elem,!0)}}},dispatch:function(c){c=$.event.fix(c||a.event);var d,e,f,g,h,i,j,k,l,m=($._data(this,"events")||{})[c.type]||[],n=m.delegateCount,o=V.call(arguments),p=!c.exclusive&&!c.namespace,q=$.event.special[c.type]||{},r=[];if(o[0]=c,c.delegateTarget=this,!q.preDispatch||q.preDispatch.call(this,c)!==!1){if(n&&(!c.button||"click"!==c.type))for(f=c.target;f!=this;f=f.parentNode||this)if(f.disabled!==!0||"click"!==c.type){for(h={},j=[],d=0;n>d;d++)k=m[d],l=k.selector,h[l]===b&&(h[l]=k.needsContext?$(l,this).index(f)>=0:$.find(l,this,null,[f]).length),h[l]&&j.push(k);j.length&&r.push({elem:f,matches:j})}for(m.length>n&&r.push({elem:this,matches:m.slice(n)}),d=0;d<r.length&&!c.isPropagationStopped();d++)for(i=r[d],c.currentTarget=i.elem,e=0;e<i.matches.length&&!c.isImmediatePropagationStopped();e++)k=i.matches[e],(p||!c.namespace&&!k.namespace||c.namespace_re&&c.namespace_re.test(k.namespace))&&(c.data=k.data,c.handleObj=k,g=(($.event.special[k.origType]||{}).handle||k.handler).apply(i.elem,o),g!==b&&(c.result=g,g===!1&&(c.preventDefault(),c.stopPropagation())));return q.postDispatch&&q.postDispatch.call(this,c),c.result}},props:"attrChange attrName relatedNode srcElement altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(a,b){return null==a.which&&(a.which=null!=b.charCode?b.charCode:b.keyCode),a}},mouseHooks:{props:"button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(a,c){var d,e,f,g=c.button,h=c.fromElement;return null==a.pageX&&null!=c.clientX&&(d=a.target.ownerDocument||P,e=d.documentElement,f=d.body,a.pageX=c.clientX+(e&&e.scrollLeft||f&&f.scrollLeft||0)-(e&&e.clientLeft||f&&f.clientLeft||0),a.pageY=c.clientY+(e&&e.scrollTop||f&&f.scrollTop||0)-(e&&e.clientTop||f&&f.clientTop||0)),!a.relatedTarget&&h&&(a.relatedTarget=h===a.target?c.toElement:h),a.which||g===b||(a.which=1&g?1:2&g?3:4&g?2:0),a}},fix:function(a){if(a[$.expando])return a;var b,c,d=a,e=$.event.fixHooks[a.type]||{},f=e.props?this.props.concat(e.props):this.props;for(a=$.Event(d),b=f.length;b;)c=f[--b],a[c]=d[c];return a.target||(a.target=d.srcElement||P),3===a.target.nodeType&&(a.target=a.target.parentNode),a.metaKey=!!a.metaKey,e.filter?e.filter(a,d):a},special:{load:{noBubble:!0},focus:{delegateType:"focusin"},blur:{delegateType:"focusout"},beforeunload:{setup:function(a,b,c){$.isWindow(this)&&(this.onbeforeunload=c)},teardown:function(a,b){this.onbeforeunload===b&&(this.onbeforeunload=null)}}},simulate:function(a,b,c,d){var e=$.extend(new $.Event,c,{type:a,isSimulated:!0,originalEvent:{}});d?$.event.trigger(e,null,b):$.event.dispatch.call(b,e),e.isDefaultPrevented()&&c.preventDefault()}},$.event.handle=$.event.dispatch,$.removeEvent=P.removeEventListener?function(a,b,c){a.removeEventListener&&a.removeEventListener(b,c,!1)}:function(a,b,c){var d="on"+b;a.detachEvent&&("undefined"==typeof a[d]&&(a[d]=null),a.detachEvent(d,c))},$.Event=function(a,b){return this instanceof $.Event?(a&&a.type?(this.originalEvent=a,this.type=a.type,this.isDefaultPrevented=a.defaultPrevented||a.returnValue===!1||a.getPreventDefault&&a.getPreventDefault()?g:f):this.type=a,b&&$.extend(this,b),this.timeStamp=a&&a.timeStamp||$.now(),void(this[$.expando]=!0)):new $.Event(a,b)},$.Event.prototype={preventDefault:function(){this.isDefaultPrevented=g;var a=this.originalEvent;a&&(a.preventDefault?a.preventDefault():a.returnValue=!1)},stopPropagation:function(){this.isPropagationStopped=g;var a=this.originalEvent;a&&(a.stopPropagation&&a.stopPropagation(),a.cancelBubble=!0)},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=g,this.stopPropagation()},isDefaultPrevented:f,isPropagationStopped:f,isImmediatePropagationStopped:f},$.each({mouseenter:"mouseover",mouseleave:"mouseout"},function(a,b){$.event.special[a]={delegateType:b,bindType:b,handle:function(a){{var c,d=this,e=a.relatedTarget,f=a.handleObj;f.selector}return(!e||e!==d&&!$.contains(d,e))&&(a.type=f.origType,c=f.handler.apply(this,arguments),a.type=b),c}}}),$.support.submitBubbles||($.event.special.submit={setup:function(){return $.nodeName(this,"form")?!1:void $.event.add(this,"click._submit keypress._submit",function(a){var c=a.target,d=$.nodeName(c,"input")||$.nodeName(c,"button")?c.form:b;d&&!$._data(d,"_submit_attached")&&($.event.add(d,"submit._submit",function(a){a._submit_bubble=!0}),$._data(d,"_submit_attached",!0))})},postDispatch:function(a){a._submit_bubble&&(delete a._submit_bubble,this.parentNode&&!a.isTrigger&&$.event.simulate("submit",this.parentNode,a,!0))},teardown:function(){return $.nodeName(this,"form")?!1:void $.event.remove(this,"._submit")}}),$.support.changeBubbles||($.event.special.change={setup:function(){return Bb.test(this.nodeName)?(("checkbox"===this.type||"radio"===this.type)&&($.event.add(this,"propertychange._change",function(a){"checked"===a.originalEvent.propertyName&&(this._just_changed=!0)}),$.event.add(this,"click._change",function(a){this._just_changed&&!a.isTrigger&&(this._just_changed=!1),$.event.simulate("change",this,a,!0)})),!1):void $.event.add(this,"beforeactivate._change",function(a){var b=a.target;Bb.test(b.nodeName)&&!$._data(b,"_change_attached")&&($.event.add(b,"change._change",function(a){!this.parentNode||a.isSimulated||a.isTrigger||$.event.simulate("change",this.parentNode,a,!0)}),$._data(b,"_change_attached",!0))})},handle:function(a){var b=a.target;return this!==b||a.isSimulated||a.isTrigger||"radio"!==b.type&&"checkbox"!==b.type?a.handleObj.handler.apply(this,arguments):void 0},teardown:function(){return $.event.remove(this,"._change"),!Bb.test(this.nodeName)}}),$.support.focusinBubbles||$.each({focus:"focusin",blur:"focusout"},function(a,b){var c=0,d=function(a){$.event.simulate(b,a.target,$.event.fix(a),!0)};$.event.special[b]={setup:function(){0===c++&&P.addEventListener(a,d,!0)},teardown:function(){0===--c&&P.removeEventListener(a,d,!0)}}}),$.fn.extend({on:function(a,c,d,e,g){var h,i;if("object"==typeof a){"string"!=typeof c&&(d=d||c,c=b);for(i in a)this.on(i,c,d,a[i],g);return this}if(null==d&&null==e?(e=c,d=c=b):null==e&&("string"==typeof c?(e=d,d=b):(e=d,d=c,c=b)),e===!1)e=f;else if(!e)return this;return 1===g&&(h=e,e=function(a){return $().off(a),h.apply(this,arguments)},e.guid=h.guid||(h.guid=$.guid++)),this.each(function(){$.event.add(this,a,e,d,c)})},one:function(a,b,c,d){return this.on(a,b,c,d,1)},off:function(a,c,d){var e,g;if(a&&a.preventDefault&&a.handleObj)return e=a.handleObj,$(a.delegateTarget).off(e.namespace?e.origType+"."+e.namespace:e.origType,e.selector,e.handler),this;if("object"==typeof a){for(g in a)this.off(g,c,a[g]);return this}return(c===!1||"function"==typeof c)&&(d=c,c=b),d===!1&&(d=f),this.each(function(){$.event.remove(this,a,d,c)})},bind:function(a,b,c){return this.on(a,null,b,c)},unbind:function(a,b){return this.off(a,null,b)},live:function(a,b,c){return $(this.context).on(a,this.selector,b,c),this},die:function(a,b){return $(this.context).off(a,this.selector||"**",b),this},delegate:function(a,b,c,d){return this.on(b,a,c,d)},undelegate:function(a,b,c){return 1===arguments.length?this.off(a,"**"):this.off(b,a||"**",c)},trigger:function(a,b){return this.each(function(){$.event.trigger(a,b,this)})},triggerHandler:function(a,b){return this[0]?$.event.trigger(a,b,this[0],!0):void 0},toggle:function(a){var b=arguments,c=a.guid||$.guid++,d=0,e=function(c){var e=($._data(this,"lastToggle"+a.guid)||0)%d;return $._data(this,"lastToggle"+a.guid,e+1),c.preventDefault(),b[e].apply(this,arguments)||!1};for(e.guid=c;d<b.length;)b[d++].guid=c;return this.click(e)},hover:function(a,b){return this.mouseenter(a).mouseleave(b||a)}}),$.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(a,b){$.fn[b]=function(a,c){return null==c&&(c=a,a=null),arguments.length>0?this.on(b,null,a,c):this.trigger(b)},Eb.test(b)&&($.event.fixHooks[b]=$.event.keyHooks),Fb.test(b)&&($.event.fixHooks[b]=$.event.mouseHooks)}),function(a,b){function c(a,b,c,d){c=c||[],b=b||F;var e,f,g,h,i=b.nodeType;if(!a||"string"!=typeof a)return c;if(1!==i&&9!==i)return[];if(g=v(b),!g&&!d&&(e=cb.exec(a)))if(h=e[1]){if(9===i){if(f=b.getElementById(h),!f||!f.parentNode)return c;if(f.id===h)return c.push(f),c}else if(b.ownerDocument&&(f=b.ownerDocument.getElementById(h))&&w(b,f)&&f.id===h)return c.push(f),c}else{if(e[2])return K.apply(c,L.call(b.getElementsByTagName(a),0)),c;if((h=e[3])&&mb&&b.getElementsByClassName)return K.apply(c,L.call(b.getElementsByClassName(h),0)),c}return p(a.replace(Z,"$1"),b,c,d,g)}function d(a){return function(b){var c=b.nodeName.toLowerCase();return"input"===c&&b.type===a}}function e(a){return function(b){var c=b.nodeName.toLowerCase();return("input"===c||"button"===c)&&b.type===a}}function f(a){return N(function(b){return b=+b,N(function(c,d){for(var e,f=a([],c.length,b),g=f.length;g--;)c[e=f[g]]&&(c[e]=!(d[e]=c[e]))})})}function g(a,b,c){if(a===b)return c;for(var d=a.nextSibling;d;){if(d===b)return-1;d=d.nextSibling}return 1}function h(a,b){var d,e,f,g,h,i,j,k=Q[D][a+" "];if(k)return b?0:k.slice(0);for(h=a,i=[],j=t.preFilter;h;){(!d||(e=_.exec(h)))&&(e&&(h=h.slice(e[0].length)||h),i.push(f=[])),d=!1,(e=ab.exec(h))&&(f.push(d=new E(e.shift())),h=h.slice(d.length),d.type=e[0].replace(Z," "));for(g in t.filter)!(e=hb[g].exec(h))||j[g]&&!(e=j[g](e))||(f.push(d=new E(e.shift())),h=h.slice(d.length),d.type=g,d.matches=e);if(!d)break}return b?h.length:h?c.error(a):Q(a,i).slice(0)}function i(a,b,c){var d=b.dir,e=c&&"parentNode"===b.dir,f=I++;return b.first?function(b,c,f){for(;b=b[d];)if(e||1===b.nodeType)return a(b,c,f)}:function(b,c,g){if(g){for(;b=b[d];)if((e||1===b.nodeType)&&a(b,c,g))return b}else for(var h,i=H+" "+f+" ",j=i+r;b=b[d];)if(e||1===b.nodeType){if((h=b[D])===j)return b.sizset;if("string"==typeof h&&0===h.indexOf(i)){if(b.sizset)return b}else{if(b[D]=j,a(b,c,g))return b.sizset=!0,b;b.sizset=!1}}}}function j(a){return a.length>1?function(b,c,d){for(var e=a.length;e--;)if(!a[e](b,c,d))return!1;return!0}:a[0]}function k(a,b,c,d,e){for(var f,g=[],h=0,i=a.length,j=null!=b;i>h;h++)(f=a[h])&&(!c||c(f,d,e))&&(g.push(f),j&&b.push(h));return g}function l(a,b,c,d,e,f){return d&&!d[D]&&(d=l(d)),e&&!e[D]&&(e=l(e,f)),N(function(f,g,h,i){var j,l,m,n=[],p=[],q=g.length,r=f||o(b||"*",h.nodeType?[h]:h,[]),s=!a||!f&&b?r:k(r,n,a,h,i),t=c?e||(f?a:q||d)?[]:g:s;if(c&&c(s,t,h,i),d)for(j=k(t,p),d(j,[],h,i),l=j.length;l--;)(m=j[l])&&(t[p[l]]=!(s[p[l]]=m));if(f){if(e||a){if(e){for(j=[],l=t.length;l--;)(m=t[l])&&j.push(s[l]=m);e(null,t=[],j,i)}for(l=t.length;l--;)(m=t[l])&&(j=e?M.call(f,m):n[l])>-1&&(f[j]=!(g[j]=m))}}else t=k(t===g?t.splice(q,t.length):t),e?e(null,g,t,i):K.apply(g,t)})}function m(a){for(var b,c,d,e=a.length,f=t.relative[a[0].type],g=f||t.relative[" "],h=f?1:0,k=i(function(a){return a===b},g,!0),n=i(function(a){return M.call(b,a)>-1},g,!0),o=[function(a,c,d){return!f&&(d||c!==A)||((b=c).nodeType?k(a,c,d):n(a,c,d))}];e>h;h++)if(c=t.relative[a[h].type])o=[i(j(o),c)];else{if(c=t.filter[a[h].type].apply(null,a[h].matches),c[D]){for(d=++h;e>d&&!t.relative[a[d].type];d++);return l(h>1&&j(o),h>1&&a.slice(0,h-1).join("").replace(Z,"$1"),c,d>h&&m(a.slice(h,d)),e>d&&m(a=a.slice(d)),e>d&&a.join(""))}o.push(c)}return j(o)}function n(a,b){var d=b.length>0,e=a.length>0,f=function(g,h,i,j,l){var m,n,o,p=[],q=0,s="0",u=g&&[],v=null!=l,w=A,x=g||e&&t.find.TAG("*",l&&h.parentNode||h),y=H+=null==w?1:Math.E;for(v&&(A=h!==F&&h,r=f.el);null!=(m=x[s]);s++){if(e&&m){for(n=0;o=a[n];n++)if(o(m,h,i)){j.push(m);break}v&&(H=y,r=++f.el)}d&&((m=!o&&m)&&q--,g&&u.push(m))}if(q+=s,d&&s!==q){for(n=0;o=b[n];n++)o(u,p,h,i);if(g){if(q>0)for(;s--;)u[s]||p[s]||(p[s]=J.call(j));p=k(p)}K.apply(j,p),v&&!g&&p.length>0&&q+b.length>1&&c.uniqueSort(j)}return v&&(H=y,A=w),u};return f.el=0,d?N(f):f}function o(a,b,d){for(var e=0,f=b.length;f>e;e++)c(a,b[e],d);return d}function p(a,b,c,d,e){{var f,g,i,j,k,l=h(a);l.length}if(!d&&1===l.length){if(g=l[0]=l[0].slice(0),g.length>2&&"ID"===(i=g[0]).type&&9===b.nodeType&&!e&&t.relative[g[1].type]){if(b=t.find.ID(i.matches[0].replace(gb,""),b,e)[0],!b)return c;a=a.slice(g.shift().length)}for(f=hb.POS.test(a)?-1:g.length-1;f>=0&&(i=g[f],!t.relative[j=i.type]);f--)if((k=t.find[j])&&(d=k(i.matches[0].replace(gb,""),db.test(g[0].type)&&b.parentNode||b,e))){if(g.splice(f,1),a=d.length&&g.join(""),!a)return K.apply(c,L.call(d,0)),c;break}}return x(a,l)(d,b,e,c,db.test(a)),c}function q(){}var r,s,t,u,v,w,x,y,z,A,B=!0,C="undefined",D=("sizcache"+Math.random()).replace(".",""),E=String,F=a.document,G=F.documentElement,H=0,I=0,J=[].pop,K=[].push,L=[].slice,M=[].indexOf||function(a){for(var b=0,c=this.length;c>b;b++)if(this[b]===a)return b;return-1},N=function(a,b){return a[D]=null==b||b,a},O=function(){var a={},b=[];return N(function(c,d){return b.push(c)>t.cacheLength&&delete a[b.shift()],a[c+" "]=d},a)},P=O(),Q=O(),R=O(),S="[\\x20\\t\\r\\n\\f]",T="(?:\\\\.|[-\\w]|[^\\x00-\\xa0])+",U=T.replace("w","w#"),V="([*^$|!~]?=)",W="\\["+S+"*("+T+")"+S+"*(?:"+V+S+"*(?:(['\"])((?:\\\\.|[^\\\\])*?)\\3|("+U+")|)|)"+S+"*\\]",X=":("+T+")(?:\\((?:(['\"])((?:\\\\.|[^\\\\])*?)\\2|([^()[\\]]*|(?:(?:"+W+")|[^:]|\\\\.)*|.*))\\)|)",Y=":(even|odd|eq|gt|lt|nth|first|last)(?:\\("+S+"*((?:-\\d)?\\d*)"+S+"*\\)|)(?=[^-]|$)",Z=new RegExp("^"+S+"+|((?:^|[^\\\\])(?:\\\\.)*)"+S+"+$","g"),_=new RegExp("^"+S+"*,"+S+"*"),ab=new RegExp("^"+S+"*([\\x20\\t\\r\\n\\f>+~])"+S+"*"),bb=new RegExp(X),cb=/^(?:#([\w\-]+)|(\w+)|\.([\w\-]+))$/,db=/[\x20\t\r\n\f]*[+~]/,eb=/h\d/i,fb=/input|select|textarea|button/i,gb=/\\(?!\\)/g,hb={ID:new RegExp("^#("+T+")"),CLASS:new RegExp("^\\.("+T+")"),NAME:new RegExp("^\\[name=['\"]?("+T+")['\"]?\\]"),TAG:new RegExp("^("+T.replace("w","w*")+")"),ATTR:new RegExp("^"+W),PSEUDO:new RegExp("^"+X),POS:new RegExp(Y,"i"),CHILD:new RegExp("^:(only|nth|first|last)-child(?:\\("+S+"*(even|odd|(([+-]|)(\\d*)n|)"+S+"*(?:([+-]|)"+S+"*(\\d+)|))"+S+"*\\)|)","i"),needsContext:new RegExp("^"+S+"*[>+~]|"+Y,"i")},ib=function(a){var b=F.createElement("div");try{return a(b)}catch(c){return!1}finally{b=null}},jb=ib(function(a){return a.appendChild(F.createComment("")),!a.getElementsByTagName("*").length}),kb=ib(function(a){return a.innerHTML="<a href='#'></a>",a.firstChild&&typeof a.firstChild.getAttribute!==C&&"#"===a.firstChild.getAttribute("href")}),lb=ib(function(a){a.innerHTML="<select></select>";var b=typeof a.lastChild.getAttribute("multiple");return"boolean"!==b&&"string"!==b}),mb=ib(function(a){return a.innerHTML="<div class='hidden e'></div><div class='hidden'></div>",a.getElementsByClassName&&a.getElementsByClassName("e").length?(a.lastChild.className="e",2===a.getElementsByClassName("e").length):!1}),nb=ib(function(a){a.id=D+0,a.innerHTML="<a name='"+D+"'></a><div name='"+D+"'></div>",G.insertBefore(a,G.firstChild);var b=F.getElementsByName&&F.getElementsByName(D).length===2+F.getElementsByName(D+0).length;return s=!F.getElementById(D),G.removeChild(a),b});try{L.call(G.childNodes,0)[0].nodeType}catch(ob){L=function(a){for(var b,c=[];b=this[a];a++)c.push(b);return c}}c.matches=function(a,b){return c(a,null,null,b)},c.matchesSelector=function(a,b){return c(b,null,null,[a]).length>0},u=c.getText=function(a){var b,c="",d=0,e=a.nodeType;if(e){if(1===e||9===e||11===e){if("string"==typeof a.textContent)return a.textContent;for(a=a.firstChild;a;a=a.nextSibling)c+=u(a)}else if(3===e||4===e)return a.nodeValue}else for(;b=a[d];d++)c+=u(b);return c},v=c.isXML=function(a){var b=a&&(a.ownerDocument||a).documentElement;return b?"HTML"!==b.nodeName:!1},w=c.contains=G.contains?function(a,b){var c=9===a.nodeType?a.documentElement:a,d=b&&b.parentNode;return a===d||!!(d&&1===d.nodeType&&c.contains&&c.contains(d))}:G.compareDocumentPosition?function(a,b){return b&&!!(16&a.compareDocumentPosition(b))}:function(a,b){for(;b=b.parentNode;)if(b===a)return!0;return!1},c.attr=function(a,b){var c,d=v(a);return d||(b=b.toLowerCase()),(c=t.attrHandle[b])?c(a):d||lb?a.getAttribute(b):(c=a.getAttributeNode(b),c?"boolean"==typeof a[b]?a[b]?b:null:c.specified?c.value:null:null)},t=c.selectors={cacheLength:50,createPseudo:N,match:hb,attrHandle:kb?{}:{href:function(a){return a.getAttribute("href",2)},type:function(a){return a.getAttribute("type")}},find:{ID:s?function(a,b,c){if(typeof b.getElementById!==C&&!c){var d=b.getElementById(a);return d&&d.parentNode?[d]:[]}}:function(a,c,d){if(typeof c.getElementById!==C&&!d){var e=c.getElementById(a);return e?e.id===a||typeof e.getAttributeNode!==C&&e.getAttributeNode("id").value===a?[e]:b:[]}},TAG:jb?function(a,b){return typeof b.getElementsByTagName!==C?b.getElementsByTagName(a):void 0}:function(a,b){var c=b.getElementsByTagName(a);if("*"===a){for(var d,e=[],f=0;d=c[f];f++)1===d.nodeType&&e.push(d);return e}return c},NAME:nb&&function(a,b){return typeof b.getElementsByName!==C?b.getElementsByName(name):void 0},CLASS:mb&&function(a,b,c){return typeof b.getElementsByClassName===C||c?void 0:b.getElementsByClassName(a)}},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(a){return a[1]=a[1].replace(gb,""),a[3]=(a[4]||a[5]||"").replace(gb,""),"~="===a[2]&&(a[3]=" "+a[3]+" "),a.slice(0,4)},CHILD:function(a){return a[1]=a[1].toLowerCase(),"nth"===a[1]?(a[2]||c.error(a[0]),a[3]=+(a[3]?a[4]+(a[5]||1):2*("even"===a[2]||"odd"===a[2])),a[4]=+(a[6]+a[7]||"odd"===a[2])):a[2]&&c.error(a[0]),a},PSEUDO:function(a){var b,c;return hb.CHILD.test(a[0])?null:(a[3]?a[2]=a[3]:(b=a[4])&&(bb.test(b)&&(c=h(b,!0))&&(c=b.indexOf(")",b.length-c)-b.length)&&(b=b.slice(0,c),a[0]=a[0].slice(0,c)),a[2]=b),a.slice(0,3))}},filter:{ID:s?function(a){return a=a.replace(gb,""),function(b){return b.getAttribute("id")===a}}:function(a){return a=a.replace(gb,""),function(b){var c=typeof b.getAttributeNode!==C&&b.getAttributeNode("id");return c&&c.value===a}},TAG:function(a){return"*"===a?function(){return!0}:(a=a.replace(gb,"").toLowerCase(),function(b){return b.nodeName&&b.nodeName.toLowerCase()===a})},CLASS:function(a){var b=P[D][a+" "];return b||(b=new RegExp("(^|"+S+")"+a+"("+S+"|$)"))&&P(a,function(a){return b.test(a.className||typeof a.getAttribute!==C&&a.getAttribute("class")||"")})},ATTR:function(a,b,d){return function(e){var f=c.attr(e,a);return null==f?"!="===b:b?(f+="","="===b?f===d:"!="===b?f!==d:"^="===b?d&&0===f.indexOf(d):"*="===b?d&&f.indexOf(d)>-1:"$="===b?d&&f.substr(f.length-d.length)===d:"~="===b?(" "+f+" ").indexOf(d)>-1:"|="===b?f===d||f.substr(0,d.length+1)===d+"-":!1):!0}},CHILD:function(a,b,c,d){return"nth"===a?function(a){var b,e,f=a.parentNode;if(1===c&&0===d)return!0;if(f)for(e=0,b=f.firstChild;b&&(1!==b.nodeType||(e++,a!==b));b=b.nextSibling);return e-=d,e===c||e%c===0&&e/c>=0}:function(b){var c=b;switch(a){case"only":case"first":for(;c=c.previousSibling;)if(1===c.nodeType)return!1;if("first"===a)return!0;c=b;case"last":for(;c=c.nextSibling;)if(1===c.nodeType)return!1;return!0}}},PSEUDO:function(a,b){var d,e=t.pseudos[a]||t.setFilters[a.toLowerCase()]||c.error("unsupported pseudo: "+a);return e[D]?e(b):e.length>1?(d=[a,a,"",b],t.setFilters.hasOwnProperty(a.toLowerCase())?N(function(a,c){for(var d,f=e(a,b),g=f.length;g--;)d=M.call(a,f[g]),a[d]=!(c[d]=f[g])}):function(a){return e(a,0,d)}):e}},pseudos:{not:N(function(a){var b=[],c=[],d=x(a.replace(Z,"$1"));return d[D]?N(function(a,b,c,e){for(var f,g=d(a,null,e,[]),h=a.length;h--;)(f=g[h])&&(a[h]=!(b[h]=f))}):function(a,e,f){return b[0]=a,d(b,null,f,c),!c.pop()}}),has:N(function(a){return function(b){return c(a,b).length>0}}),contains:N(function(a){return function(b){return(b.textContent||b.innerText||u(b)).indexOf(a)>-1}}),enabled:function(a){return a.disabled===!1},disabled:function(a){return a.disabled===!0},checked:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&!!a.checked||"option"===b&&!!a.selected},selected:function(a){return a.parentNode&&a.parentNode.selectedIndex,a.selected===!0},parent:function(a){return!t.pseudos.empty(a)},empty:function(a){var b;for(a=a.firstChild;a;){if(a.nodeName>"@"||3===(b=a.nodeType)||4===b)return!1;a=a.nextSibling}return!0},header:function(a){return eb.test(a.nodeName)},text:function(a){var b,c;return"input"===a.nodeName.toLowerCase()&&"text"===(b=a.type)&&(null==(c=a.getAttribute("type"))||c.toLowerCase()===b)},radio:d("radio"),checkbox:d("checkbox"),file:d("file"),password:d("password"),image:d("image"),submit:e("submit"),reset:e("reset"),button:function(a){var b=a.nodeName.toLowerCase();return"input"===b&&"button"===a.type||"button"===b},input:function(a){return fb.test(a.nodeName)},focus:function(a){var b=a.ownerDocument;return a===b.activeElement&&(!b.hasFocus||b.hasFocus())&&!!(a.type||a.href||~a.tabIndex)},active:function(a){return a===a.ownerDocument.activeElement},first:f(function(){return[0]}),last:f(function(a,b){return[b-1]}),eq:f(function(a,b,c){return[0>c?c+b:c]}),even:f(function(a,b){for(var c=0;b>c;c+=2)a.push(c);return a}),odd:f(function(a,b){for(var c=1;b>c;c+=2)a.push(c);return a}),lt:f(function(a,b,c){for(var d=0>c?c+b:c;--d>=0;)a.push(d);return a}),gt:f(function(a,b,c){for(var d=0>c?c+b:c;++d<b;)a.push(d);return a})}},y=G.compareDocumentPosition?function(a,b){return a===b?(z=!0,0):(a.compareDocumentPosition&&b.compareDocumentPosition?4&a.compareDocumentPosition(b):a.compareDocumentPosition)?-1:1}:function(a,b){if(a===b)return z=!0,0;if(a.sourceIndex&&b.sourceIndex)return a.sourceIndex-b.sourceIndex;var c,d,e=[],f=[],h=a.parentNode,i=b.parentNode,j=h;if(h===i)return g(a,b);if(!h)return-1;if(!i)return 1;for(;j;)e.unshift(j),j=j.parentNode;for(j=i;j;)f.unshift(j),j=j.parentNode;c=e.length,d=f.length; for(var k=0;c>k&&d>k;k++)if(e[k]!==f[k])return g(e[k],f[k]);return k===c?g(a,f[k],-1):g(e[k],b,1)},[0,0].sort(y),B=!z,c.uniqueSort=function(a){var b,c=[],d=1,e=0;if(z=B,a.sort(y),z){for(;b=a[d];d++)b===a[d-1]&&(e=c.push(d));for(;e--;)a.splice(c[e],1)}return a},c.error=function(a){throw new Error("Syntax error, unrecognized expression: "+a)},x=c.compile=function(a,b){var c,d=[],e=[],f=R[D][a+" "];if(!f){for(b||(b=h(a)),c=b.length;c--;)f=m(b[c]),f[D]?d.push(f):e.push(f);f=R(a,n(e,d))}return f},F.querySelectorAll&&!function(){var a,b=p,d=/'|\\/g,e=/\=[\x20\t\r\n\f]*([^'"\]]*)[\x20\t\r\n\f]*\]/g,f=[":focus"],g=[":active"],i=G.matchesSelector||G.mozMatchesSelector||G.webkitMatchesSelector||G.oMatchesSelector||G.msMatchesSelector;ib(function(a){a.innerHTML="<select><option selected=''></option></select>",a.querySelectorAll("[selected]").length||f.push("\\["+S+"*(?:checked|disabled|ismap|multiple|readonly|selected|value)"),a.querySelectorAll(":checked").length||f.push(":checked")}),ib(function(a){a.innerHTML="<p test=''></p>",a.querySelectorAll("[test^='']").length&&f.push("[*^$]="+S+"*(?:\"\"|'')"),a.innerHTML="<input type='hidden'/>",a.querySelectorAll(":enabled").length||f.push(":enabled",":disabled")}),f=new RegExp(f.join("|")),p=function(a,c,e,g,i){if(!g&&!i&&!f.test(a)){var j,k,l=!0,m=D,n=c,o=9===c.nodeType&&a;if(1===c.nodeType&&"object"!==c.nodeName.toLowerCase()){for(j=h(a),(l=c.getAttribute("id"))?m=l.replace(d,"\\$&"):c.setAttribute("id",m),m="[id='"+m+"'] ",k=j.length;k--;)j[k]=m+j[k].join("");n=db.test(a)&&c.parentNode||c,o=j.join(",")}if(o)try{return K.apply(e,L.call(n.querySelectorAll(o),0)),e}catch(p){}finally{l||c.removeAttribute("id")}}return b(a,c,e,g,i)},i&&(ib(function(b){a=i.call(b,"div");try{i.call(b,"[test!='']:sizzle"),g.push("!=",X)}catch(c){}}),g=new RegExp(g.join("|")),c.matchesSelector=function(b,d){if(d=d.replace(e,"='$1']"),!v(b)&&!g.test(d)&&!f.test(d))try{var h=i.call(b,d);if(h||a||b.document&&11!==b.document.nodeType)return h}catch(j){}return c(d,null,null,[b]).length>0})}(),t.pseudos.nth=t.pseudos.eq,t.filters=q.prototype=t.pseudos,t.setFilters=new q,c.attr=$.attr,$.find=c,$.expr=c.selectors,$.expr[":"]=$.expr.pseudos,$.unique=c.uniqueSort,$.text=c.getText,$.isXMLDoc=c.isXML,$.contains=c.contains}(a);var Ib=/Until$/,Jb=/^(?:parents|prev(?:Until|All))/,Kb=/^.[^:#\[\.,]*$/,Lb=$.expr.match.needsContext,Mb={children:!0,contents:!0,next:!0,prev:!0};$.fn.extend({find:function(a){var b,c,d,e,f,g,h=this;if("string"!=typeof a)return $(a).filter(function(){for(b=0,c=h.length;c>b;b++)if($.contains(h[b],this))return!0});for(g=this.pushStack("","find",a),b=0,c=this.length;c>b;b++)if(d=g.length,$.find(a,this[b],g),b>0)for(e=d;e<g.length;e++)for(f=0;d>f;f++)if(g[f]===g[e]){g.splice(e--,1);break}return g},has:function(a){var b,c=$(a,this),d=c.length;return this.filter(function(){for(b=0;d>b;b++)if($.contains(this,c[b]))return!0})},not:function(a){return this.pushStack(j(this,a,!1),"not",a)},filter:function(a){return this.pushStack(j(this,a,!0),"filter",a)},is:function(a){return!!a&&("string"==typeof a?Lb.test(a)?$(a,this.context).index(this[0])>=0:$.filter(a,this).length>0:this.filter(a).length>0)},closest:function(a,b){for(var c,d=0,e=this.length,f=[],g=Lb.test(a)||"string"!=typeof a?$(a,b||this.context):0;e>d;d++)for(c=this[d];c&&c.ownerDocument&&c!==b&&11!==c.nodeType;){if(g?g.index(c)>-1:$.find.matchesSelector(c,a)){f.push(c);break}c=c.parentNode}return f=f.length>1?$.unique(f):f,this.pushStack(f,"closest",a)},index:function(a){return a?"string"==typeof a?$.inArray(this[0],$(a)):$.inArray(a.jquery?a[0]:a,this):this[0]&&this[0].parentNode?this.prevAll().length:-1},add:function(a,b){var c="string"==typeof a?$(a,b):$.makeArray(a&&a.nodeType?[a]:a),d=$.merge(this.get(),c);return this.pushStack(h(c[0])||h(d[0])?d:$.unique(d))},addBack:function(a){return this.add(null==a?this.prevObject:this.prevObject.filter(a))}}),$.fn.andSelf=$.fn.addBack,$.each({parent:function(a){var b=a.parentNode;return b&&11!==b.nodeType?b:null},parents:function(a){return $.dir(a,"parentNode")},parentsUntil:function(a,b,c){return $.dir(a,"parentNode",c)},next:function(a){return i(a,"nextSibling")},prev:function(a){return i(a,"previousSibling")},nextAll:function(a){return $.dir(a,"nextSibling")},prevAll:function(a){return $.dir(a,"previousSibling")},nextUntil:function(a,b,c){return $.dir(a,"nextSibling",c)},prevUntil:function(a,b,c){return $.dir(a,"previousSibling",c)},siblings:function(a){return $.sibling((a.parentNode||{}).firstChild,a)},children:function(a){return $.sibling(a.firstChild)},contents:function(a){return $.nodeName(a,"iframe")?a.contentDocument||a.contentWindow.document:$.merge([],a.childNodes)}},function(a,b){$.fn[a]=function(c,d){var e=$.map(this,b,c);return Ib.test(a)||(d=c),d&&"string"==typeof d&&(e=$.filter(d,e)),e=this.length>1&&!Mb[a]?$.unique(e):e,this.length>1&&Jb.test(a)&&(e=e.reverse()),this.pushStack(e,a,V.call(arguments).join(","))}}),$.extend({filter:function(a,b,c){return c&&(a=":not("+a+")"),1===b.length?$.find.matchesSelector(b[0],a)?[b[0]]:[]:$.find.matches(a,b)},dir:function(a,c,d){for(var e=[],f=a[c];f&&9!==f.nodeType&&(d===b||1!==f.nodeType||!$(f).is(d));)1===f.nodeType&&e.push(f),f=f[c];return e},sibling:function(a,b){for(var c=[];a;a=a.nextSibling)1===a.nodeType&&a!==b&&c.push(a);return c}});var Nb="abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",Ob=/ jQuery\d+="(?:null|\d+)"/g,Pb=/^\s+/,Qb=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,Rb=/<([\w:]+)/,Sb=/<tbody/i,Tb=/<|&#?\w+;/,Ub=/<(?:script|style|link)/i,Vb=/<(?:script|object|embed|option|style)/i,Wb=new RegExp("<(?:"+Nb+")[\\s/>]","i"),Xb=/^(?:checkbox|radio)$/,Yb=/checked\s*(?:[^=]|=\s*.checked.)/i,Zb=/\/(java|ecma)script/i,$b=/^\s*<!(?:\[CDATA\[|\-\-)|[\]\-]{2}>\s*$/g,_b={option:[1,"<select multiple='multiple'>","</select>"],legend:[1,"<fieldset>","</fieldset>"],thead:[1,"<table>","</table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],area:[1,"<map>","</map>"],_default:[0,"",""]},ac=k(P),bc=ac.appendChild(P.createElement("div"));_b.optgroup=_b.option,_b.tbody=_b.tfoot=_b.colgroup=_b.caption=_b.thead,_b.th=_b.td,$.support.htmlSerialize||(_b._default=[1,"X<div>","</div>"]),$.fn.extend({text:function(a){return $.access(this,function(a){return a===b?$.text(this):this.empty().append((this[0]&&this[0].ownerDocument||P).createTextNode(a))},null,a,arguments.length)},wrapAll:function(a){if($.isFunction(a))return this.each(function(b){$(this).wrapAll(a.call(this,b))});if(this[0]){var b=$(a,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&b.insertBefore(this[0]),b.map(function(){for(var a=this;a.firstChild&&1===a.firstChild.nodeType;)a=a.firstChild;return a}).append(this)}return this},wrapInner:function(a){return this.each($.isFunction(a)?function(b){$(this).wrapInner(a.call(this,b))}:function(){var b=$(this),c=b.contents();c.length?c.wrapAll(a):b.append(a)})},wrap:function(a){var b=$.isFunction(a);return this.each(function(c){$(this).wrapAll(b?a.call(this,c):a)})},unwrap:function(){return this.parent().each(function(){$.nodeName(this,"body")||$(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,!0,function(a){(1===this.nodeType||11===this.nodeType)&&this.appendChild(a)})},prepend:function(){return this.domManip(arguments,!0,function(a){(1===this.nodeType||11===this.nodeType)&&this.insertBefore(a,this.firstChild)})},before:function(){if(!h(this[0]))return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this)});if(arguments.length){var a=$.clean(arguments);return this.pushStack($.merge(a,this),"before",this.selector)}},after:function(){if(!h(this[0]))return this.domManip(arguments,!1,function(a){this.parentNode.insertBefore(a,this.nextSibling)});if(arguments.length){var a=$.clean(arguments);return this.pushStack($.merge(this,a),"after",this.selector)}},remove:function(a,b){for(var c,d=0;null!=(c=this[d]);d++)(!a||$.filter(a,[c]).length)&&(b||1!==c.nodeType||($.cleanData(c.getElementsByTagName("*")),$.cleanData([c])),c.parentNode&&c.parentNode.removeChild(c));return this},empty:function(){for(var a,b=0;null!=(a=this[b]);b++)for(1===a.nodeType&&$.cleanData(a.getElementsByTagName("*"));a.firstChild;)a.removeChild(a.firstChild);return this},clone:function(a,b){return a=null==a?!1:a,b=null==b?a:b,this.map(function(){return $.clone(this,a,b)})},html:function(a){return $.access(this,function(a){var c=this[0]||{},d=0,e=this.length;if(a===b)return 1===c.nodeType?c.innerHTML.replace(Ob,""):b;if(!("string"!=typeof a||Ub.test(a)||!$.support.htmlSerialize&&Wb.test(a)||!$.support.leadingWhitespace&&Pb.test(a)||_b[(Rb.exec(a)||["",""])[1].toLowerCase()])){a=a.replace(Qb,"<$1></$2>");try{for(;e>d;d++)c=this[d]||{},1===c.nodeType&&($.cleanData(c.getElementsByTagName("*")),c.innerHTML=a);c=0}catch(f){}}c&&this.empty().append(a)},null,a,arguments.length)},replaceWith:function(a){return h(this[0])?this.length?this.pushStack($($.isFunction(a)?a():a),"replaceWith",a):this:$.isFunction(a)?this.each(function(b){var c=$(this),d=c.html();c.replaceWith(a.call(this,b,d))}):("string"!=typeof a&&(a=$(a).detach()),this.each(function(){var b=this.nextSibling,c=this.parentNode;$(this).remove(),b?$(b).before(a):$(c).append(a)}))},detach:function(a){return this.remove(a,!0)},domManip:function(a,c,d){a=[].concat.apply([],a);var e,f,g,h,i=0,j=a[0],k=[],m=this.length;if(!$.support.checkClone&&m>1&&"string"==typeof j&&Yb.test(j))return this.each(function(){$(this).domManip(a,c,d)});if($.isFunction(j))return this.each(function(e){var f=$(this);a[0]=j.call(this,e,c?f.html():b),f.domManip(a,c,d)});if(this[0]){if(e=$.buildFragment(a,this,k),g=e.fragment,f=g.firstChild,1===g.childNodes.length&&(g=f),f)for(c=c&&$.nodeName(f,"tr"),h=e.cacheable||m-1;m>i;i++)d.call(c&&$.nodeName(this[i],"table")?l(this[i],"tbody"):this[i],i===h?g:$.clone(g,!0,!0));g=f=null,k.length&&$.each(k,function(a,b){b.src?$.ajax?$.ajax({url:b.src,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0}):$.error("no ajax"):$.globalEval((b.text||b.textContent||b.innerHTML||"").replace($b,"")),b.parentNode&&b.parentNode.removeChild(b)})}return this}}),$.buildFragment=function(a,c,d){var e,f,g,h=a[0];return c=c||P,c=!c.nodeType&&c[0]||c,c=c.ownerDocument||c,!(1===a.length&&"string"==typeof h&&h.length<512&&c===P&&"<"===h.charAt(0))||Vb.test(h)||!$.support.checkClone&&Yb.test(h)||!$.support.html5Clone&&Wb.test(h)||(f=!0,e=$.fragments[h],g=e!==b),e||(e=c.createDocumentFragment(),$.clean(a,c,e,d),f&&($.fragments[h]=g&&e)),{fragment:e,cacheable:f}},$.fragments={},$.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){$.fn[a]=function(c){var d,e=0,f=[],g=$(c),h=g.length,i=1===this.length&&this[0].parentNode;if((null==i||i&&11===i.nodeType&&1===i.childNodes.length)&&1===h)return g[b](this[0]),this;for(;h>e;e++)d=(e>0?this.clone(!0):this).get(),$(g[e])[b](d),f=f.concat(d);return this.pushStack(f,a,g.selector)}}),$.extend({clone:function(a,b,c){var d,e,f,g;if($.support.html5Clone||$.isXMLDoc(a)||!Wb.test("<"+a.nodeName+">")?g=a.cloneNode(!0):(bc.innerHTML=a.outerHTML,bc.removeChild(g=bc.firstChild)),!($.support.noCloneEvent&&$.support.noCloneChecked||1!==a.nodeType&&11!==a.nodeType||$.isXMLDoc(a)))for(n(a,g),d=o(a),e=o(g),f=0;d[f];++f)e[f]&&n(d[f],e[f]);if(b&&(m(a,g),c))for(d=o(a),e=o(g),f=0;d[f];++f)m(d[f],e[f]);return d=e=null,g},clean:function(a,b,c,d){var e,f,g,h,i,j,l,m,n,o,q,r=b===P&&ac,s=[];for(b&&"undefined"!=typeof b.createDocumentFragment||(b=P),e=0;null!=(g=a[e]);e++)if("number"==typeof g&&(g+=""),g){if("string"==typeof g)if(Tb.test(g)){for(r=r||k(b),l=b.createElement("div"),r.appendChild(l),g=g.replace(Qb,"<$1></$2>"),h=(Rb.exec(g)||["",""])[1].toLowerCase(),i=_b[h]||_b._default,j=i[0],l.innerHTML=i[1]+g+i[2];j--;)l=l.lastChild;if(!$.support.tbody)for(m=Sb.test(g),n="table"!==h||m?"<table>"!==i[1]||m?[]:l.childNodes:l.firstChild&&l.firstChild.childNodes,f=n.length-1;f>=0;--f)$.nodeName(n[f],"tbody")&&!n[f].childNodes.length&&n[f].parentNode.removeChild(n[f]);!$.support.leadingWhitespace&&Pb.test(g)&&l.insertBefore(b.createTextNode(Pb.exec(g)[0]),l.firstChild),g=l.childNodes,l.parentNode.removeChild(l)}else g=b.createTextNode(g);g.nodeType?s.push(g):$.merge(s,g)}if(l&&(g=l=r=null),!$.support.appendChecked)for(e=0;null!=(g=s[e]);e++)$.nodeName(g,"input")?p(g):"undefined"!=typeof g.getElementsByTagName&&$.grep(g.getElementsByTagName("input"),p);if(c)for(o=function(a){return!a.type||Zb.test(a.type)?d?d.push(a.parentNode?a.parentNode.removeChild(a):a):c.appendChild(a):void 0},e=0;null!=(g=s[e]);e++)$.nodeName(g,"script")&&o(g)||(c.appendChild(g),"undefined"!=typeof g.getElementsByTagName&&(q=$.grep($.merge([],g.getElementsByTagName("script")),o),s.splice.apply(s,[e+1,0].concat(q)),e+=q.length));return s},cleanData:function(a,b){for(var c,d,e,f,g=0,h=$.expando,i=$.cache,j=$.support.deleteExpando,k=$.event.special;null!=(e=a[g]);g++)if((b||$.acceptData(e))&&(d=e[h],c=d&&i[d])){if(c.events)for(f in c.events)k[f]?$.event.remove(e,f):$.removeEvent(e,f,c.handle);i[d]&&(delete i[d],j?delete e[h]:e.removeAttribute?e.removeAttribute(h):e[h]=null,$.deletedIds.push(d))}}}),function(){var a,b;$.uaMatch=function(a){a=a.toLowerCase();var b=/(chrome)[ \/]([\w.]+)/.exec(a)||/(webkit)[ \/]([\w.]+)/.exec(a)||/(opera)(?:.*version|)[ \/]([\w.]+)/.exec(a)||/(msie) ([\w.]+)/.exec(a)||a.indexOf("compatible")<0&&/(mozilla)(?:.*? rv:([\w.]+)|)/.exec(a)||[];return{browser:b[1]||"",version:b[2]||"0"}},a=$.uaMatch(R.userAgent),b={},a.browser&&(b[a.browser]=!0,b.version=a.version),b.chrome?b.webkit=!0:b.webkit&&(b.safari=!0),$.browser=b,$.sub=function(){function a(b,c){return new a.fn.init(b,c)}$.extend(!0,a,this),a.superclass=this,a.fn=a.prototype=this(),a.fn.constructor=a,a.sub=this.sub,a.fn.init=function(c,d){return d&&d instanceof $&&!(d instanceof a)&&(d=a(d)),$.fn.init.call(this,c,d,b)},a.fn.init.prototype=a.fn;var b=a(P);return a}}();var cc,dc,ec,fc=/alpha\([^)]*\)/i,gc=/opacity=([^)]*)/,hc=/^(top|right|bottom|left)$/,ic=/^(none|table(?!-c[ea]).+)/,jc=/^margin/,kc=new RegExp("^("+_+")(.*)$","i"),lc=new RegExp("^("+_+")(?!px)[a-z%]+$","i"),mc=new RegExp("^([-+])=("+_+")","i"),nc={BODY:"block"},oc={position:"absolute",visibility:"hidden",display:"block"},pc={letterSpacing:0,fontWeight:400},qc=["Top","Right","Bottom","Left"],rc=["Webkit","O","Moz","ms"],sc=$.fn.toggle;$.fn.extend({css:function(a,c){return $.access(this,function(a,c,d){return d!==b?$.style(a,c,d):$.css(a,c)},a,c,arguments.length>1)},show:function(){return s(this,!0)},hide:function(){return s(this)},toggle:function(a,b){var c="boolean"==typeof a;return $.isFunction(a)&&$.isFunction(b)?sc.apply(this,arguments):this.each(function(){(c?a:r(this))?$(this).show():$(this).hide()})}}),$.extend({cssHooks:{opacity:{get:function(a,b){if(b){var c=cc(a,"opacity");return""===c?"1":c}}}},cssNumber:{fillOpacity:!0,fontWeight:!0,lineHeight:!0,opacity:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":$.support.cssFloat?"cssFloat":"styleFloat"},style:function(a,c,d,e){if(a&&3!==a.nodeType&&8!==a.nodeType&&a.style){var f,g,h,i=$.camelCase(c),j=a.style;if(c=$.cssProps[i]||($.cssProps[i]=q(j,i)),h=$.cssHooks[c]||$.cssHooks[i],d===b)return h&&"get"in h&&(f=h.get(a,!1,e))!==b?f:j[c];if(g=typeof d,"string"===g&&(f=mc.exec(d))&&(d=(f[1]+1)*f[2]+parseFloat($.css(a,c)),g="number"),!(null==d||"number"===g&&isNaN(d)||("number"!==g||$.cssNumber[i]||(d+="px"),h&&"set"in h&&(d=h.set(a,d,e))===b)))try{j[c]=d}catch(k){}}},css:function(a,c,d,e){var f,g,h,i=$.camelCase(c);return c=$.cssProps[i]||($.cssProps[i]=q(a.style,i)),h=$.cssHooks[c]||$.cssHooks[i],h&&"get"in h&&(f=h.get(a,!0,e)),f===b&&(f=cc(a,c)),"normal"===f&&c in pc&&(f=pc[c]),d||e!==b?(g=parseFloat(f),d||$.isNumeric(g)?g||0:f):f},swap:function(a,b,c){var d,e,f={};for(e in b)f[e]=a.style[e],a.style[e]=b[e];d=c.call(a);for(e in b)a.style[e]=f[e];return d}}),a.getComputedStyle?cc=function(b,c){var d,e,f,g,h=a.getComputedStyle(b,null),i=b.style;return h&&(d=h.getPropertyValue(c)||h[c],""!==d||$.contains(b.ownerDocument,b)||(d=$.style(b,c)),lc.test(d)&&jc.test(c)&&(e=i.width,f=i.minWidth,g=i.maxWidth,i.minWidth=i.maxWidth=i.width=d,d=h.width,i.width=e,i.minWidth=f,i.maxWidth=g)),d}:P.documentElement.currentStyle&&(cc=function(a,b){var c,d,e=a.currentStyle&&a.currentStyle[b],f=a.style;return null==e&&f&&f[b]&&(e=f[b]),lc.test(e)&&!hc.test(b)&&(c=f.left,d=a.runtimeStyle&&a.runtimeStyle.left,d&&(a.runtimeStyle.left=a.currentStyle.left),f.left="fontSize"===b?"1em":e,e=f.pixelLeft+"px",f.left=c,d&&(a.runtimeStyle.left=d)),""===e?"auto":e}),$.each(["height","width"],function(a,b){$.cssHooks[b]={get:function(a,c,d){return c?0===a.offsetWidth&&ic.test(cc(a,"display"))?$.swap(a,oc,function(){return v(a,b,d)}):v(a,b,d):void 0},set:function(a,c,d){return t(a,c,d?u(a,b,d,$.support.boxSizing&&"border-box"===$.css(a,"boxSizing")):0)}}}),$.support.opacity||($.cssHooks.opacity={get:function(a,b){return gc.test((b&&a.currentStyle?a.currentStyle.filter:a.style.filter)||"")?.01*parseFloat(RegExp.$1)+"":b?"1":""},set:function(a,b){var c=a.style,d=a.currentStyle,e=$.isNumeric(b)?"alpha(opacity="+100*b+")":"",f=d&&d.filter||c.filter||"";c.zoom=1,b>=1&&""===$.trim(f.replace(fc,""))&&c.removeAttribute&&(c.removeAttribute("filter"),d&&!d.filter)||(c.filter=fc.test(f)?f.replace(fc,e):f+" "+e)}}),$(function(){$.support.reliableMarginRight||($.cssHooks.marginRight={get:function(a,b){return $.swap(a,{display:"inline-block"},function(){return b?cc(a,"marginRight"):void 0})}}),!$.support.pixelPosition&&$.fn.position&&$.each(["top","left"],function(a,b){$.cssHooks[b]={get:function(a,c){if(c){var d=cc(a,b);return lc.test(d)?$(a).position()[b]+"px":d}}}})}),$.expr&&$.expr.filters&&($.expr.filters.hidden=function(a){return 0===a.offsetWidth&&0===a.offsetHeight||!$.support.reliableHiddenOffsets&&"none"===(a.style&&a.style.display||cc(a,"display"))},$.expr.filters.visible=function(a){return!$.expr.filters.hidden(a)}),$.each({margin:"",padding:"",border:"Width"},function(a,b){$.cssHooks[a+b]={expand:function(c){var d,e="string"==typeof c?c.split(" "):[c],f={};for(d=0;4>d;d++)f[a+qc[d]+b]=e[d]||e[d-2]||e[0];return f}},jc.test(a)||($.cssHooks[a+b].set=t)});var tc=/%20/g,uc=/\[\]$/,vc=/\r?\n/g,wc=/^(?:color|date|datetime|datetime-local|email|hidden|month|number|password|range|search|tel|text|time|url|week)$/i,xc=/^(?:select|textarea)/i;$.fn.extend({serialize:function(){return $.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?$.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||xc.test(this.nodeName)||wc.test(this.type))}).map(function(a,b){var c=$(this).val();return null==c?null:$.isArray(c)?$.map(c,function(a){return{name:b.name,value:a.replace(vc,"\r\n")}}):{name:b.name,value:c.replace(vc,"\r\n")}}).get()}}),$.param=function(a,c){var d,e=[],f=function(a,b){b=$.isFunction(b)?b():null==b?"":b,e[e.length]=encodeURIComponent(a)+"="+encodeURIComponent(b)};if(c===b&&(c=$.ajaxSettings&&$.ajaxSettings.traditional),$.isArray(a)||a.jquery&&!$.isPlainObject(a))$.each(a,function(){f(this.name,this.value)});else for(d in a)x(d,a[d],c,f);return e.join("&").replace(tc,"+")};var yc,zc,Ac=/#.*$/,Bc=/^(.*?):[ \t]*([^\r\n]*)\r?$/gm,Cc=/^(?:about|app|app\-storage|.+\-extension|file|res|widget):$/,Dc=/^(?:GET|HEAD)$/,Ec=/^\/\//,Fc=/\?/,Gc=/<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi,Hc=/([?&])_=[^&]*/,Ic=/^([\w\+\.\-]+:)(?:\/\/([^\/?#:]*)(?::(\d+)|)|)/,Jc=$.fn.load,Kc={},Lc={},Mc=["*/"]+["*"];try{zc=Q.href}catch(Nc){zc=P.createElement("a"),zc.href="",zc=zc.href}yc=Ic.exec(zc.toLowerCase())||[],$.fn.load=function(a,c,d){if("string"!=typeof a&&Jc)return Jc.apply(this,arguments);if(!this.length)return this;var e,f,g,h=this,i=a.indexOf(" ");return i>=0&&(e=a.slice(i,a.length),a=a.slice(0,i)),$.isFunction(c)?(d=c,c=b):c&&"object"==typeof c&&(f="POST"),$.ajax({url:a,type:f,dataType:"html",data:c,complete:function(a,b){d&&h.each(d,g||[a.responseText,b,a])}}).done(function(a){g=arguments,h.html(e?$("<div>").append(a.replace(Gc,"")).find(e):a)}),this},$.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "),function(a,b){$.fn[b]=function(a){return this.on(b,a)}}),$.each(["get","post"],function(a,c){$[c]=function(a,d,e,f){return $.isFunction(d)&&(f=f||e,e=d,d=b),$.ajax({type:c,url:a,data:d,success:e,dataType:f})}}),$.extend({getScript:function(a,c){return $.get(a,b,c,"script")},getJSON:function(a,b,c){return $.get(a,b,c,"json")},ajaxSetup:function(a,b){return b?A(a,$.ajaxSettings):(b=a,a=$.ajaxSettings),A(a,b),a},ajaxSettings:{url:zc,isLocal:Cc.test(yc[1]),global:!0,type:"GET",contentType:"application/x-www-form-urlencoded; charset=UTF-8",processData:!0,async:!0,accepts:{xml:"application/xml, text/xml",html:"text/html",text:"text/plain",json:"application/json, text/javascript","*":Mc},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText"},converters:{"* text":a.String,"text html":!0,"text json":$.parseJSON,"text xml":$.parseXML},flatOptions:{context:!0,url:!0}},ajaxPrefilter:y(Kc),ajaxTransport:y(Lc),ajax:function(a,c){function d(a,c,d,g){var j,l,s,t,v,x=c;2!==u&&(u=2,i&&clearTimeout(i),h=b,f=g||"",w.readyState=a>0?4:0,d&&(t=B(m,w,d)),a>=200&&300>a||304===a?(m.ifModified&&(v=w.getResponseHeader("Last-Modified"),v&&($.lastModified[e]=v),v=w.getResponseHeader("Etag"),v&&($.etag[e]=v)),304===a?(x="notmodified",j=!0):(j=C(m,t),x=j.state,l=j.data,s=j.error,j=!s)):(s=x,(!x||a)&&(x="error",0>a&&(a=0))),w.status=a,w.statusText=(c||x)+"",j?p.resolveWith(n,[l,x,w]):p.rejectWith(n,[w,x,s]),w.statusCode(r),r=b,k&&o.trigger("ajax"+(j?"Success":"Error"),[w,m,j?l:s]),q.fireWith(n,[w,x]),k&&(o.trigger("ajaxComplete",[w,m]),--$.active||$.event.trigger("ajaxStop")))}"object"==typeof a&&(c=a,a=b),c=c||{};var e,f,g,h,i,j,k,l,m=$.ajaxSetup({},c),n=m.context||m,o=n!==m&&(n.nodeType||n instanceof $)?$(n):$.event,p=$.Deferred(),q=$.Callbacks("once memory"),r=m.statusCode||{},s={},t={},u=0,v="canceled",w={readyState:0,setRequestHeader:function(a,b){if(!u){var c=a.toLowerCase();a=t[c]=t[c]||a,s[a]=b}return this},getAllResponseHeaders:function(){return 2===u?f:null},getResponseHeader:function(a){var c;if(2===u){if(!g)for(g={};c=Bc.exec(f);)g[c[1].toLowerCase()]=c[2];c=g[a.toLowerCase()]}return c===b?null:c},overrideMimeType:function(a){return u||(m.mimeType=a),this},abort:function(a){return a=a||v,h&&h.abort(a),d(0,a),this}};if(p.promise(w),w.success=w.done,w.error=w.fail,w.complete=q.add,w.statusCode=function(a){if(a){var b;if(2>u)for(b in a)r[b]=[r[b],a[b]];else b=a[w.status],w.always(b)}return this},m.url=((a||m.url)+"").replace(Ac,"").replace(Ec,yc[1]+"//"),m.dataTypes=$.trim(m.dataType||"*").toLowerCase().split(bb),null==m.crossDomain&&(j=Ic.exec(m.url.toLowerCase()),m.crossDomain=!(!j||j[1]===yc[1]&&j[2]===yc[2]&&(j[3]||("http:"===j[1]?80:443))==(yc[3]||("http:"===yc[1]?80:443)))),m.data&&m.processData&&"string"!=typeof m.data&&(m.data=$.param(m.data,m.traditional)),z(Kc,m,c,w),2===u)return w;if(k=m.global,m.type=m.type.toUpperCase(),m.hasContent=!Dc.test(m.type),k&&0===$.active++&&$.event.trigger("ajaxStart"),!m.hasContent&&(m.data&&(m.url+=(Fc.test(m.url)?"&":"?")+m.data,delete m.data),e=m.url,m.cache===!1)){var x=$.now(),y=m.url.replace(Hc,"$1_="+x);m.url=y+(y===m.url?(Fc.test(m.url)?"&":"?")+"_="+x:"")}(m.data&&m.hasContent&&m.contentType!==!1||c.contentType)&&w.setRequestHeader("Content-Type",m.contentType),m.ifModified&&(e=e||m.url,$.lastModified[e]&&w.setRequestHeader("If-Modified-Since",$.lastModified[e]),$.etag[e]&&w.setRequestHeader("If-None-Match",$.etag[e])),w.setRequestHeader("Accept",m.dataTypes[0]&&m.accepts[m.dataTypes[0]]?m.accepts[m.dataTypes[0]]+("*"!==m.dataTypes[0]?", "+Mc+"; q=0.01":""):m.accepts["*"]);for(l in m.headers)w.setRequestHeader(l,m.headers[l]);if(m.beforeSend&&(m.beforeSend.call(n,w,m)===!1||2===u))return w.abort();v="abort";for(l in{success:1,error:1,complete:1})w[l](m[l]);if(h=z(Lc,m,c,w)){w.readyState=1,k&&o.trigger("ajaxSend",[w,m]),m.async&&m.timeout>0&&(i=setTimeout(function(){w.abort("timeout")},m.timeout));try{u=1,h.send(s,d)}catch(A){if(!(2>u))throw A;d(-1,A)}}else d(-1,"No Transport");return w},active:0,lastModified:{},etag:{}});var Oc=[],Pc=/\?/,Qc=/(=)\?(?=&|$)|\?\?/,Rc=$.now();$.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var a=Oc.pop()||$.expando+"_"+Rc++;return this[a]=!0,a}}),$.ajaxPrefilter("json jsonp",function(c,d,e){var f,g,h,i=c.data,j=c.url,k=c.jsonp!==!1,l=k&&Qc.test(j),m=k&&!l&&"string"==typeof i&&!(c.contentType||"").indexOf("application/x-www-form-urlencoded")&&Qc.test(i);return"jsonp"===c.dataTypes[0]||l||m?(f=c.jsonpCallback=$.isFunction(c.jsonpCallback)?c.jsonpCallback():c.jsonpCallback,g=a[f],l?c.url=j.replace(Qc,"$1"+f):m?c.data=i.replace(Qc,"$1"+f):k&&(c.url+=(Pc.test(j)?"&":"?")+c.jsonp+"="+f),c.converters["script json"]=function(){return h||$.error(f+" was not called"),h[0]},c.dataTypes[0]="json",a[f]=function(){h=arguments},e.always(function(){a[f]=g,c[f]&&(c.jsonpCallback=d.jsonpCallback,Oc.push(f)),h&&$.isFunction(g)&&g(h[0]),h=g=b}),"script"):void 0}),$.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/javascript|ecmascript/},converters:{"text script":function(a){return $.globalEval(a),a}}}),$.ajaxPrefilter("script",function(a){a.cache===b&&(a.cache=!1),a.crossDomain&&(a.type="GET",a.global=!1)}),$.ajaxTransport("script",function(a){if(a.crossDomain){var c,d=P.head||P.getElementsByTagName("head")[0]||P.documentElement;return{send:function(e,f){c=P.createElement("script"),c.async="async",a.scriptCharset&&(c.charset=a.scriptCharset),c.src=a.url,c.onload=c.onreadystatechange=function(a,e){(e||!c.readyState||/loaded|complete/.test(c.readyState))&&(c.onload=c.onreadystatechange=null,d&&c.parentNode&&d.removeChild(c),c=b,e||f(200,"success"))},d.insertBefore(c,d.firstChild)},abort:function(){c&&c.onload(0,1)}}}});var Sc,Tc=a.ActiveXObject?function(){for(var a in Sc)Sc[a](0,1)}:!1,Uc=0;$.ajaxSettings.xhr=a.ActiveXObject?function(){return!this.isLocal&&D()||E()}:D,function(a){$.extend($.support,{ajax:!!a,cors:!!a&&"withCredentials"in a})}($.ajaxSettings.xhr()),$.support.ajax&&$.ajaxTransport(function(c){if(!c.crossDomain||$.support.cors){var d;return{send:function(e,f){var g,h,i=c.xhr();if(c.username?i.open(c.type,c.url,c.async,c.username,c.password):i.open(c.type,c.url,c.async),c.xhrFields)for(h in c.xhrFields)i[h]=c.xhrFields[h];c.mimeType&&i.overrideMimeType&&i.overrideMimeType(c.mimeType),c.crossDomain||e["X-Requested-With"]||(e["X-Requested-With"]="XMLHttpRequest");try{for(h in e)i.setRequestHeader(h,e[h])}catch(j){}i.send(c.hasContent&&c.data||null),d=function(a,e){var h,j,k,l,m;try{if(d&&(e||4===i.readyState))if(d=b,g&&(i.onreadystatechange=$.noop,Tc&&delete Sc[g]),e)4!==i.readyState&&i.abort();else{h=i.status,k=i.getAllResponseHeaders(),l={},m=i.responseXML,m&&m.documentElement&&(l.xml=m);try{l.text=i.responseText}catch(n){}try{j=i.statusText}catch(n){j=""}h||!c.isLocal||c.crossDomain?1223===h&&(h=204):h=l.text?200:404}}catch(o){e||f(-1,o)}l&&f(h,j,l,k)},c.async?4===i.readyState?setTimeout(d,0):(g=++Uc,Tc&&(Sc||(Sc={},$(a).unload(Tc)),Sc[g]=d),i.onreadystatechange=d):d()},abort:function(){d&&d(0,1)}}}});var Vc,Wc,Xc=/^(?:toggle|show|hide)$/,Yc=new RegExp("^(?:([-+])=|)("+_+")([a-z%]*)$","i"),Zc=/queueHooks$/,$c=[J],_c={"*":[function(a,b){var c,d,e=this.createTween(a,b),f=Yc.exec(b),g=e.cur(),h=+g||0,i=1,j=20;if(f){if(c=+f[2],d=f[3]||($.cssNumber[a]?"":"px"),"px"!==d&&h){h=$.css(e.elem,a,!0)||c||1;do i=i||".5",h/=i,$.style(e.elem,a,h+d);while(i!==(i=e.cur()/g)&&1!==i&&--j)}e.unit=d,e.start=h,e.end=f[1]?h+(f[1]+1)*c:c}return e}]};$.Animation=$.extend(H,{tweener:function(a,b){$.isFunction(a)?(b=a,a=["*"]):a=a.split(" ");for(var c,d=0,e=a.length;e>d;d++)c=a[d],_c[c]=_c[c]||[],_c[c].unshift(b)},prefilter:function(a,b){b?$c.unshift(a):$c.push(a)}}),$.Tween=K,K.prototype={constructor:K,init:function(a,b,c,d,e,f){this.elem=a,this.prop=c,this.easing=e||"swing",this.options=b,this.start=this.now=this.cur(),this.end=d,this.unit=f||($.cssNumber[c]?"":"px")},cur:function(){var a=K.propHooks[this.prop];return a&&a.get?a.get(this):K.propHooks._default.get(this)},run:function(a){var b,c=K.propHooks[this.prop];return this.pos=b=this.options.duration?$.easing[this.easing](a,this.options.duration*a,0,1,this.options.duration):a,this.now=(this.end-this.start)*b+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),c&&c.set?c.set(this):K.propHooks._default.set(this),this}},K.prototype.init.prototype=K.prototype,K.propHooks={_default:{get:function(a){var b;return null==a.elem[a.prop]||a.elem.style&&null!=a.elem.style[a.prop]?(b=$.css(a.elem,a.prop,!1,""),b&&"auto"!==b?b:0):a.elem[a.prop]},set:function(a){$.fx.step[a.prop]?$.fx.step[a.prop](a):a.elem.style&&(null!=a.elem.style[$.cssProps[a.prop]]||$.cssHooks[a.prop])?$.style(a.elem,a.prop,a.now+a.unit):a.elem[a.prop]=a.now}}},K.propHooks.scrollTop=K.propHooks.scrollLeft={set:function(a){a.elem.nodeType&&a.elem.parentNode&&(a.elem[a.prop]=a.now)}},$.each(["toggle","show","hide"],function(a,b){var c=$.fn[b];$.fn[b]=function(d,e,f){return null==d||"boolean"==typeof d||!a&&$.isFunction(d)&&$.isFunction(e)?c.apply(this,arguments):this.animate(L(b,!0),d,e,f)}}),$.fn.extend({fadeTo:function(a,b,c,d){return this.filter(r).css("opacity",0).show().end().animate({opacity:b},a,c,d)},animate:function(a,b,c,d){var e=$.isEmptyObject(a),f=$.speed(b,c,d),g=function(){var b=H(this,$.extend({},a),f);e&&b.stop(!0)};return e||f.queue===!1?this.each(g):this.queue(f.queue,g)},stop:function(a,c,d){var e=function(a){var b=a.stop;delete a.stop,b(d)};return"string"!=typeof a&&(d=c,c=a,a=b),c&&a!==!1&&this.queue(a||"fx",[]),this.each(function(){var b=!0,c=null!=a&&a+"queueHooks",f=$.timers,g=$._data(this);if(c)g[c]&&g[c].stop&&e(g[c]);else for(c in g)g[c]&&g[c].stop&&Zc.test(c)&&e(g[c]);for(c=f.length;c--;)f[c].elem!==this||null!=a&&f[c].queue!==a||(f[c].anim.stop(d),b=!1,f.splice(c,1));(b||!d)&&$.dequeue(this,a)})}}),$.each({slideDown:L("show"),slideUp:L("hide"),slideToggle:L("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(a,b){$.fn[a]=function(a,c,d){return this.animate(b,a,c,d)}}),$.speed=function(a,b,c){var d=a&&"object"==typeof a?$.extend({},a):{complete:c||!c&&b||$.isFunction(a)&&a,duration:a,easing:c&&b||b&&!$.isFunction(b)&&b};return d.duration=$.fx.off?0:"number"==typeof d.duration?d.duration:d.duration in $.fx.speeds?$.fx.speeds[d.duration]:$.fx.speeds._default,(null==d.queue||d.queue===!0)&&(d.queue="fx"),d.old=d.complete,d.complete=function(){$.isFunction(d.old)&&d.old.call(this),d.queue&&$.dequeue(this,d.queue)},d},$.easing={linear:function(a){return a},swing:function(a){return.5-Math.cos(a*Math.PI)/2}},$.timers=[],$.fx=K.prototype.init,$.fx.tick=function(){var a,c=$.timers,d=0;for(Vc=$.now();d<c.length;d++)a=c[d],a()||c[d]!==a||c.splice(d--,1);c.length||$.fx.stop(),Vc=b},$.fx.timer=function(a){a()&&$.timers.push(a)&&!Wc&&(Wc=setInterval($.fx.tick,$.fx.interval))},$.fx.interval=13,$.fx.stop=function(){clearInterval(Wc),Wc=null},$.fx.speeds={slow:600,fast:200,_default:400},$.fx.step={},$.expr&&$.expr.filters&&($.expr.filters.animated=function(a){return $.grep($.timers,function(b){return a===b.elem}).length});var ad=/^(?:body|html)$/i;$.fn.offset=function(a){if(arguments.length)return a===b?this:this.each(function(b){$.offset.setOffset(this,a,b)});var c,d,e,f,g,h,i,j={top:0,left:0},k=this[0],l=k&&k.ownerDocument;if(l)return(d=l.body)===k?$.offset.bodyOffset(k):(c=l.documentElement,$.contains(c,k)?("undefined"!=typeof k.getBoundingClientRect&&(j=k.getBoundingClientRect()),e=M(l),f=c.clientTop||d.clientTop||0,g=c.clientLeft||d.clientLeft||0,h=e.pageYOffset||c.scrollTop,i=e.pageXOffset||c.scrollLeft,{top:j.top+h-f,left:j.left+i-g}):j) },$.offset={bodyOffset:function(a){var b=a.offsetTop,c=a.offsetLeft;return $.support.doesNotIncludeMarginInBodyOffset&&(b+=parseFloat($.css(a,"marginTop"))||0,c+=parseFloat($.css(a,"marginLeft"))||0),{top:b,left:c}},setOffset:function(a,b,c){var d=$.css(a,"position");"static"===d&&(a.style.position="relative");var e,f,g=$(a),h=g.offset(),i=$.css(a,"top"),j=$.css(a,"left"),k=("absolute"===d||"fixed"===d)&&$.inArray("auto",[i,j])>-1,l={},m={};k?(m=g.position(),e=m.top,f=m.left):(e=parseFloat(i)||0,f=parseFloat(j)||0),$.isFunction(b)&&(b=b.call(a,c,h)),null!=b.top&&(l.top=b.top-h.top+e),null!=b.left&&(l.left=b.left-h.left+f),"using"in b?b.using.call(a,l):g.css(l)}},$.fn.extend({position:function(){if(this[0]){var a=this[0],b=this.offsetParent(),c=this.offset(),d=ad.test(b[0].nodeName)?{top:0,left:0}:b.offset();return c.top-=parseFloat($.css(a,"marginTop"))||0,c.left-=parseFloat($.css(a,"marginLeft"))||0,d.top+=parseFloat($.css(b[0],"borderTopWidth"))||0,d.left+=parseFloat($.css(b[0],"borderLeftWidth"))||0,{top:c.top-d.top,left:c.left-d.left}}},offsetParent:function(){return this.map(function(){for(var a=this.offsetParent||P.body;a&&!ad.test(a.nodeName)&&"static"===$.css(a,"position");)a=a.offsetParent;return a||P.body})}}),$.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(a,c){var d=/Y/.test(c);$.fn[a]=function(e){return $.access(this,function(a,e,f){var g=M(a);return f===b?g?c in g?g[c]:g.document.documentElement[e]:a[e]:void(g?g.scrollTo(d?$(g).scrollLeft():f,d?f:$(g).scrollTop()):a[e]=f)},a,e,arguments.length,null)}}),$.each({Height:"height",Width:"width"},function(a,c){$.each({padding:"inner"+a,content:c,"":"outer"+a},function(d,e){$.fn[e]=function(e,f){var g=arguments.length&&(d||"boolean"!=typeof e),h=d||(e===!0||f===!0?"margin":"border");return $.access(this,function(c,d,e){var f;return $.isWindow(c)?c.document.documentElement["client"+a]:9===c.nodeType?(f=c.documentElement,Math.max(c.body["scroll"+a],f["scroll"+a],c.body["offset"+a],f["offset"+a],f["client"+a])):e===b?$.css(c,d,e,h):$.style(c,d,e,h)},c,g?e:b,g,null)}})}),a.jQuery=a.$=$,"function"==typeof define&&define.amd&&define.amd.jQuery&&define("jquery",[],function(){return $})}(window),function(a){for(var b=0,c=["webkit","moz"],d=a.requestAnimationFrame,e=a.cancelAnimationFrame,f=c.length;--f>=0&&!d;)d=a[c[f]+"RequestAnimationFrame"],e=a[c[f]+"CancelAnimationFrame"];d&&e||(d=function(a){var c=Date.now(),d=Math.max(b+16,c);return setTimeout(function(){a(b=d)},d-c)},e=clearTimeout),a.requestAnimationFrame=d,a.cancelAnimationFrame=e}(window),function(a){var b,c,d="0.3.4",e="hasOwnProperty",f=/[\.\/]/,g="*",h=function(){},i=function(a,b){return a-b},j={n:{}},k=function(a,d){var e,f=c,g=Array.prototype.slice.call(arguments,2),h=k.listeners(a),j=0,l=[],m={},n=[],o=b;b=a,c=0;for(var p=0,q=h.length;q>p;p++)"zIndex"in h[p]&&(l.push(h[p].zIndex),h[p].zIndex<0&&(m[h[p].zIndex]=h[p]));for(l.sort(i);l[j]<0;)if(e=m[l[j++]],n.push(e.apply(d,g)),c)return c=f,n;for(p=0;q>p;p++)if(e=h[p],"zIndex"in e)if(e.zIndex==l[j]){if(n.push(e.apply(d,g)),c)break;do if(j++,e=m[l[j]],e&&n.push(e.apply(d,g)),c)break;while(e)}else m[e.zIndex]=e;else if(n.push(e.apply(d,g)),c)break;return c=f,b=o,n.length?n:null};k.listeners=function(a){var b,c,d,e,h,i,k,l,m=a.split(f),n=j,o=[n],p=[];for(e=0,h=m.length;h>e;e++){for(l=[],i=0,k=o.length;k>i;i++)for(n=o[i].n,c=[n[m[e]],n[g]],d=2;d--;)b=c[d],b&&(l.push(b),p=p.concat(b.f||[]));o=l}return p},k.on=function(a,b){for(var c=a.split(f),d=j,e=0,g=c.length;g>e;e++)d=d.n,!d[c[e]]&&(d[c[e]]={n:{}}),d=d[c[e]];for(d.f=d.f||[],e=0,g=d.f.length;g>e;e++)if(d.f[e]==b)return h;return d.f.push(b),function(a){+a==+a&&(b.zIndex=+a)}},k.stop=function(){c=1},k.nt=function(a){return a?new RegExp("(?:\\.|\\/|^)"+a+"(?:\\.|\\/|$)").test(b):b},k.off=k.unbind=function(a,b){var c,d,h,i,k,l,m,n=a.split(f),o=[j];for(i=0,k=n.length;k>i;i++)for(l=0;l<o.length;l+=h.length-2){if(h=[l,1],c=o[l].n,n[i]!=g)c[n[i]]&&h.push(c[n[i]]);else for(d in c)c[e](d)&&h.push(c[d]);o.splice.apply(o,h)}for(i=0,k=o.length;k>i;i++)for(c=o[i];c.n;){if(b){if(c.f){for(l=0,m=c.f.length;m>l;l++)if(c.f[l]==b){c.f.splice(l,1);break}!c.f.length&&delete c.f}for(d in c.n)if(c.n[e](d)&&c.n[d].f){var p=c.n[d].f;for(l=0,m=p.length;m>l;l++)if(p[l]==b){p.splice(l,1);break}!p.length&&delete c.n[d].f}}else{delete c.f;for(d in c.n)c.n[e](d)&&c.n[d].f&&delete c.n[d].f}c=c.n}},k.once=function(a,b){var c=function(){var d=b.apply(this,arguments);return k.unbind(a,c),d};return k.on(a,c)},k.version=d,k.toString=function(){return"You are running Eve "+d},"undefined"!=typeof module&&module.exports?module.exports=k:"undefined"!=typeof define?define("eve",[],function(){return k}):a.eve=k}(this),window.eve||"function"!=typeof define||"function"!=typeof require||(window.eve=require("eve")),function(){function a(b){if(a.is(b,"function"))return s?b():eve.on("raphael.DOMload",b);if(a.is(b,T))return a._engine.create[B](a,b.splice(0,3+a.is(b[0],R))).add(b);var c=Array.prototype.slice.call(arguments,0);if(a.is(c[c.length-1],"function")){var d=c.pop();return s?d.call(a._engine.create[B](a,c)):eve.on("raphael.DOMload",function(){d.call(a._engine.create[B](a,c))})}return a._engine.create[B](a,arguments)}function b(a){if(Object(a)!==a)return a;var c=new a.constructor;for(var d in a)a[x](d)&&(c[d]=b(a[d]));return c}function c(a,b){for(var c=0,d=a.length;d>c;c++)if(a[c]===b)return a.push(a.splice(c,1)[0])}function d(a,b,d){function e(){var f=Array.prototype.slice.call(arguments,0),g=f.join("\u2400"),h=e.cache=e.cache||{},i=e.count=e.count||[];return h[x](g)?(c(i,g),d?d(h[g]):h[g]):(i.length>=1e3&&delete h[i.shift()],i.push(g),h[g]=a[B](b,f),d?d(h[g]):h[g])}return e}function e(){return this.hex}function f(a,b){for(var c=[],d=0,e=a.length;e-2*!b>d;d+=2){var f=[{x:+a[d-2],y:+a[d-1]},{x:+a[d],y:+a[d+1]},{x:+a[d+2],y:+a[d+3]},{x:+a[d+4],y:+a[d+5]}];b?d?e-4==d?f[3]={x:+a[0],y:+a[1]}:e-2==d&&(f[2]={x:+a[0],y:+a[1]},f[3]={x:+a[2],y:+a[3]}):f[0]={x:+a[e-2],y:+a[e-1]}:e-4==d?f[3]=f[2]:d||(f[0]={x:+a[d],y:+a[d+1]}),c.push(["C",(-f[0].x+6*f[1].x+f[2].x)/6,(-f[0].y+6*f[1].y+f[2].y)/6,(f[1].x+6*f[2].x-f[3].x)/6,(f[1].y+6*f[2].y-f[3].y)/6,f[2].x,f[2].y])}return c}function g(a,b,c,d,e){var f=-3*b+9*c-9*d+3*e,g=a*f+6*b-12*c+6*d;return a*g-3*b+3*c}function h(a,b,c,d,e,f,h,i,j){null==j&&(j=1),j=j>1?1:0>j?0:j;for(var k=j/2,l=12,m=[-.1252,.1252,-.3678,.3678,-.5873,.5873,-.7699,.7699,-.9041,.9041,-.9816,.9816],n=[.2491,.2491,.2335,.2335,.2032,.2032,.1601,.1601,.1069,.1069,.0472,.0472],o=0,p=0;l>p;p++){var q=k*m[p]+k,r=g(q,a,c,e,h),s=g(q,b,d,f,i),t=r*r+s*s;o+=n[p]*L.sqrt(t)}return k*o}function i(a,b,c,d,e,f,g,i,j){if(!(0>j||h(a,b,c,d,e,f,g,i)<j)){var k,l=1,m=l/2,n=l-m,o=.01;for(k=h(a,b,c,d,e,f,g,i,n);O(k-j)>o;)m/=2,n+=(j>k?1:-1)*m,k=h(a,b,c,d,e,f,g,i,n);return n}}function j(a,b,c,d,e,f,g,h){if(!(M(a,c)<N(e,g)||N(a,c)>M(e,g)||M(b,d)<N(f,h)||N(b,d)>M(f,h))){var i=(a*d-b*c)*(e-g)-(a-c)*(e*h-f*g),j=(a*d-b*c)*(f-h)-(b-d)*(e*h-f*g),k=(a-c)*(f-h)-(b-d)*(e-g);if(k){var l=i/k,m=j/k,n=+l.toFixed(2),o=+m.toFixed(2);if(!(n<+N(a,c).toFixed(2)||n>+M(a,c).toFixed(2)||n<+N(e,g).toFixed(2)||n>+M(e,g).toFixed(2)||o<+N(b,d).toFixed(2)||o>+M(b,d).toFixed(2)||o<+N(f,h).toFixed(2)||o>+M(f,h).toFixed(2)))return{x:l,y:m}}}}function k(b,c,d){var e=a.bezierBBox(b),f=a.bezierBBox(c);if(!a.isBBoxIntersect(e,f))return d?0:[];for(var g=h.apply(0,b),i=h.apply(0,c),k=~~(g/5),l=~~(i/5),m=[],n=[],o={},p=d?0:[],q=0;k+1>q;q++){var r=a.findDotsAtSegment.apply(a,b.concat(q/k));m.push({x:r.x,y:r.y,t:q/k})}for(q=0;l+1>q;q++)r=a.findDotsAtSegment.apply(a,c.concat(q/l)),n.push({x:r.x,y:r.y,t:q/l});for(q=0;k>q;q++)for(var s=0;l>s;s++){var t=m[q],u=m[q+1],v=n[s],w=n[s+1],x=O(u.x-t.x)<.001?"y":"x",y=O(w.x-v.x)<.001?"y":"x",z=j(t.x,t.y,u.x,u.y,v.x,v.y,w.x,w.y);if(z){if(o[z.x.toFixed(4)]==z.y.toFixed(4))continue;o[z.x.toFixed(4)]=z.y.toFixed(4);var A=t.t+O((z[x]-t[x])/(u[x]-t[x]))*(u.t-t.t),B=v.t+O((z[y]-v[y])/(w[y]-v[y]))*(w.t-v.t);A>=0&&1>=A&&B>=0&&1>=B&&(d?p++:p.push({x:z.x,y:z.y,t1:A,t2:B}))}}return p}function l(b,c,d){b=a._path2curve(b),c=a._path2curve(c);for(var e,f,g,h,i,j,l,m,n,o,p=d?0:[],q=0,r=b.length;r>q;q++){var s=b[q];if("M"==s[0])e=i=s[1],f=j=s[2];else{"C"==s[0]?(n=[e,f].concat(s.slice(1)),e=n[6],f=n[7]):(n=[e,f,e,f,i,j,i,j],e=i,f=j);for(var t=0,u=c.length;u>t;t++){var v=c[t];if("M"==v[0])g=l=v[1],h=m=v[2];else{"C"==v[0]?(o=[g,h].concat(v.slice(1)),g=o[6],h=o[7]):(o=[g,h,g,h,l,m,l,m],g=l,h=m);var w=k(n,o,d);if(d)p+=w;else{for(var x=0,y=w.length;y>x;x++)w[x].segment1=q,w[x].segment2=t,w[x].bez1=n,w[x].bez2=o;p=p.concat(w)}}}}}return p}function m(a,b,c,d,e,f){null!=a?(this.a=+a,this.b=+b,this.c=+c,this.d=+d,this.e=+e,this.f=+f):(this.a=1,this.b=0,this.c=0,this.d=1,this.e=0,this.f=0)}function n(){return this.x+F+this.y+F+this.width+" \xd7 "+this.height}function o(a,b,c,d,e,f){function g(a){return((l*a+k)*a+j)*a}function h(a,b){var c=i(a,b);return((o*c+n)*c+m)*c}function i(a,b){var c,d,e,f,h,i;for(e=a,i=0;8>i;i++){if(f=g(e)-a,O(f)<b)return e;if(h=(3*l*e+2*k)*e+j,O(h)<1e-6)break;e-=f/h}if(c=0,d=1,e=a,c>e)return c;if(e>d)return d;for(;d>c;){if(f=g(e),O(f-a)<b)return e;a>f?c=e:d=e,e=(d-c)/2+c}return e}var j=3*b,k=3*(d-b)-j,l=1-j-k,m=3*c,n=3*(e-c)-m,o=1-m-n;return h(a,1/(200*f))}function p(a,b){var c=[],d={};if(this.ms=b,this.times=1,a){for(var e in a)a[x](e)&&(d[Z(e)]=a[e],c.push(Z(e)));c.sort(jb)}this.anim=d,this.top=c[c.length-1],this.percents=c}function q(b,c,d,e,f,g){d=Z(d);var h,i,j,k,l,n,p=b.ms,q={},r={},s={};if(e)for(v=0,w=fc.length;w>v;v++){var t=fc[v];if(t.el.id==c.id&&t.anim==b){t.percent!=d?(fc.splice(v,1),j=1):i=t,c.attr(t.totalOrigin);break}}else e=+r;for(var v=0,w=b.percents.length;w>v;v++){if(b.percents[v]==d||b.percents[v]>e*b.top){d=b.percents[v],l=b.percents[v-1]||0,p=p/b.top*(d-l),k=b.percents[v+1],h=b.anim[d];break}e&&c.attr(b.anim[b.percents[v]])}if(h){if(i)i.initstatus=e,i.start=new Date-i.ms*e;else{for(var y in h)if(h[x](y)&&(bb[x](y)||c.paper.customAttributes[x](y)))switch(q[y]=c.attr(y),null==q[y]&&(q[y]=ab[y]),r[y]=h[y],bb[y]){case R:s[y]=(r[y]-q[y])/p;break;case"colour":q[y]=a.getRGB(q[y]);var z=a.getRGB(r[y]);s[y]={r:(z.r-q[y].r)/p,g:(z.g-q[y].g)/p,b:(z.b-q[y].b)/p};break;case"path":var A=Ib(q[y],r[y]),B=A[1];for(q[y]=A[0],s[y]=[],v=0,w=q[y].length;w>v;v++){s[y][v]=[0];for(var D=1,E=q[y][v].length;E>D;D++)s[y][v][D]=(B[v][D]-q[y][v][D])/p}break;case"transform":var F=c._,I=Nb(F[y],r[y]);if(I)for(q[y]=I.from,r[y]=I.to,s[y]=[],s[y].real=!0,v=0,w=q[y].length;w>v;v++)for(s[y][v]=[q[y][v][0]],D=1,E=q[y][v].length;E>D;D++)s[y][v][D]=(r[y][v][D]-q[y][v][D])/p;else{var J=c.matrix||new m,K={_:{transform:F.transform},getBBox:function(){return c.getBBox(1)}};q[y]=[J.a,J.b,J.c,J.d,J.e,J.f],Lb(K,r[y]),r[y]=K._.transform,s[y]=[(K.matrix.a-J.a)/p,(K.matrix.b-J.b)/p,(K.matrix.c-J.c)/p,(K.matrix.d-J.d)/p,(K.matrix.e-J.e)/p,(K.matrix.f-J.f)/p]}break;case"csv":var L=G(h[y])[H](u),M=G(q[y])[H](u);if("clip-rect"==y)for(q[y]=M,s[y]=[],v=M.length;v--;)s[y][v]=(L[v]-q[y][v])/p;r[y]=L;break;default:for(L=[][C](h[y]),M=[][C](q[y]),s[y]=[],v=c.paper.customAttributes[y].length;v--;)s[y][v]=((L[v]||0)-(M[v]||0))/p}var N=h.easing,O=a.easing_formulas[N];if(!O)if(O=G(N).match(X),O&&5==O.length){var P=O;O=function(a){return o(a,+P[1],+P[2],+P[3],+P[4],p)}}else O=lb;if(n=h.start||b.start||+new Date,t={anim:b,percent:d,timestamp:n,start:n+(b.del||0),status:0,initstatus:e||0,stop:!1,ms:p,easing:O,from:q,diff:s,to:r,el:c,callback:h.callback,prev:l,next:k,repeat:g||b.times,origin:c.attr(),totalOrigin:f},fc.push(t),e&&!i&&!j&&(t.stop=!0,t.start=new Date-p*e,1==fc.length))return hc();j&&(t.start=new Date-t.ms*e),1==fc.length&&gc(hc)}eve("raphael.anim.start."+c.id,c,b)}}function r(a){for(var b=0;b<fc.length;b++)fc[b].el.paper==a&&fc.splice(b--,1)}a.version="2.1.0",a.eve=eve;var s,t,u=/[, ]+/,v={circle:1,rect:1,path:1,ellipse:1,text:1,image:1},w=/\{(\d+)\}/g,x="hasOwnProperty",y={doc:document,win:window},z={was:Object.prototype[x].call(y.win,"Raphael"),is:y.win.Raphael},A=function(){this.ca=this.customAttributes={}},B="apply",C="concat",D="createTouch"in y.doc,E="",F=" ",G=String,H="split",I="click dblclick mousedown mousemove mouseout mouseover mouseup touchstart touchmove touchend touchcancel"[H](F),J={mousedown:"touchstart",mousemove:"touchmove",mouseup:"touchend"},K=G.prototype.toLowerCase,L=Math,M=L.max,N=L.min,O=L.abs,P=L.pow,Q=L.PI,R="number",S="string",T="array",U=Object.prototype.toString,V=(a._ISURL=/^url\(['"]?([^\)]+?)['"]?\)$/i,/^\s*((#[a-f\d]{6})|(#[a-f\d]{3})|rgba?\(\s*([\d\.]+%?\s*,\s*[\d\.]+%?\s*,\s*[\d\.]+%?(?:\s*,\s*[\d\.]+%?)?)\s*\)|hsba?\(\s*([\d\.]+(?:deg|\xb0|%)?\s*,\s*[\d\.]+%?\s*,\s*[\d\.]+(?:%?\s*,\s*[\d\.]+)?)%?\s*\)|hsla?\(\s*([\d\.]+(?:deg|\xb0|%)?\s*,\s*[\d\.]+%?\s*,\s*[\d\.]+(?:%?\s*,\s*[\d\.]+)?)%?\s*\))\s*$/i),W={NaN:1,Infinity:1,"-Infinity":1},X=/^(?:cubic-)?bezier\(([^,]+),([^,]+),([^,]+),([^\)]+)\)/,Y=L.round,Z=parseFloat,$=parseInt,_=G.prototype.toUpperCase,ab=a._availableAttrs={"arrow-end":"none","arrow-start":"none",blur:0,"clip-rect":"0 0 1e9 1e9",cursor:"default",cx:0,cy:0,fill:"#fff","fill-opacity":1,font:'10px "Arial"',"font-family":'"Arial"',"font-size":"10","font-style":"normal","font-weight":400,gradient:0,height:0,href:"http://raphaeljs.com/","letter-spacing":0,opacity:1,path:"M0,0",r:0,rx:0,ry:0,src:"",stroke:"#000","stroke-dasharray":"","stroke-linecap":"butt","stroke-linejoin":"butt","stroke-miterlimit":0,"stroke-opacity":1,"stroke-width":1,target:"_blank","text-anchor":"middle",title:"Raphael",transform:"",width:0,x:0,y:0},bb=a._availableAnimAttrs={blur:R,"clip-rect":"csv",cx:R,cy:R,fill:"colour","fill-opacity":R,"font-size":R,height:R,opacity:R,path:"path",r:R,rx:R,ry:R,stroke:"colour","stroke-opacity":R,"stroke-width":R,transform:"transform",width:R,x:R,y:R},cb=/[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029]*,[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029]*/,db={hs:1,rg:1},eb=/,?([achlmqrstvxz]),?/gi,fb=/([achlmrqstvz])[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029,]*((-?\d*\.?\d*(?:e[\-+]?\d+)?[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029]*,?[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029]*)+)/gi,gb=/([rstm])[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029,]*((-?\d*\.?\d*(?:e[\-+]?\d+)?[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029]*,?[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029]*)+)/gi,hb=/(-?\d*\.?\d*(?:e[\-+]?\d+)?)[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029]*,?[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029]*/gi,ib=(a._radial_gradient=/^r(?:\(([^,]+?)[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029]*,[\x09\x0a\x0b\x0c\x0d\x20\xa0\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\u2028\u2029]*([^\)]+?)\))?/,{}),jb=function(a,b){return Z(a)-Z(b)},kb=function(){},lb=function(a){return a},mb=a._rectPath=function(a,b,c,d,e){return e?[["M",a+e,b],["l",c-2*e,0],["a",e,e,0,0,1,e,e],["l",0,d-2*e],["a",e,e,0,0,1,-e,e],["l",2*e-c,0],["a",e,e,0,0,1,-e,-e],["l",0,2*e-d],["a",e,e,0,0,1,e,-e],["z"]]:[["M",a,b],["l",c,0],["l",0,d],["l",-c,0],["z"]]},nb=function(a,b,c,d){return null==d&&(d=c),[["M",a,b],["m",0,-d],["a",c,d,0,1,1,0,2*d],["a",c,d,0,1,1,0,-2*d],["z"]]},ob=a._getPath={path:function(a){return a.attr("path")},circle:function(a){var b=a.attrs;return nb(b.cx,b.cy,b.r)},ellipse:function(a){var b=a.attrs;return nb(b.cx,b.cy,b.rx,b.ry)},rect:function(a){var b=a.attrs;return mb(b.x,b.y,b.width,b.height,b.r)},image:function(a){var b=a.attrs;return mb(b.x,b.y,b.width,b.height)},text:function(a){var b=a._getBBox();return mb(b.x,b.y,b.width,b.height)}},pb=a.mapPath=function(a,b){if(!b)return a;var c,d,e,f,g,h,i;for(a=Ib(a),e=0,g=a.length;g>e;e++)for(i=a[e],f=1,h=i.length;h>f;f+=2)c=b.x(i[f],i[f+1]),d=b.y(i[f],i[f+1]),i[f]=c,i[f+1]=d;return a};if(a._g=y,a.type=y.win.SVGAngle||y.doc.implementation.hasFeature("http://www.w3.org/TR/SVG11/feature#BasicStructure","1.1")?"SVG":"VML","VML"==a.type){var qb,rb=y.doc.createElement("div");if(rb.innerHTML='<v:shape adj="1"/>',qb=rb.firstChild,qb.style.behavior="url(#default#VML)",!qb||"object"!=typeof qb.adj)return a.type=E;rb=null}a.svg=!(a.vml="VML"==a.type),a._Paper=A,a.fn=t=A.prototype=a.prototype,a._id=0,a._oid=0,a.is=function(a,b){return b=K.call(b),"finite"==b?!W[x](+a):"array"==b?a instanceof Array:"null"==b&&null===a||b==typeof a&&null!==a||"object"==b&&a===Object(a)||"array"==b&&Array.isArray&&Array.isArray(a)||U.call(a).slice(8,-1).toLowerCase()==b},a.angle=function(b,c,d,e,f,g){if(null==f){var h=b-d,i=c-e;return h||i?(180+180*L.atan2(-i,-h)/Q+360)%360:0}return a.angle(b,c,f,g)-a.angle(d,e,f,g)},a.rad=function(a){return a%360*Q/180},a.deg=function(a){return 180*a/Q%360},a.snapTo=function(b,c,d){if(d=a.is(d,"finite")?d:10,a.is(b,T)){for(var e=b.length;e--;)if(O(b[e]-c)<=d)return b[e]}else{b=+b;var f=c%b;if(d>f)return c-f;if(f>b-d)return c-f+b}return c};a.createUUID=function(a,b){return function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(a,b).toUpperCase()}}(/[xy]/g,function(a){var b=16*L.random()|0,c="x"==a?b:3&b|8;return c.toString(16)});a.setWindow=function(b){eve("raphael.setWindow",a,y.win,b),y.win=b,y.doc=y.win.document,a._engine.initWin&&a._engine.initWin(y.win)};var sb=function(b){if(a.vml){var c,e=/^\s+|\s+$/g;try{var f=new ActiveXObject("htmlfile");f.write("<body>"),f.close(),c=f.body}catch(g){c=createPopup().document.body}var h=c.createTextRange();sb=d(function(a){try{c.style.color=G(a).replace(e,E);var b=h.queryCommandValue("ForeColor");return b=(255&b)<<16|65280&b|(16711680&b)>>>16,"#"+("000000"+b.toString(16)).slice(-6)}catch(d){return"none"}})}else{var i=y.doc.createElement("i");i.title="Rapha\xebl Colour Picker",i.style.display="none",y.doc.body.appendChild(i),sb=d(function(a){return i.style.color=a,y.doc.defaultView.getComputedStyle(i,E).getPropertyValue("color")})}return sb(b)},tb=function(){return"hsb("+[this.h,this.s,this.b]+")"},ub=function(){return"hsl("+[this.h,this.s,this.l]+")"},vb=function(){return this.hex},wb=function(b,c,d){if(null==c&&a.is(b,"object")&&"r"in b&&"g"in b&&"b"in b&&(d=b.b,c=b.g,b=b.r),null==c&&a.is(b,S)){var e=a.getRGB(b);b=e.r,c=e.g,d=e.b}return(b>1||c>1||d>1)&&(b/=255,c/=255,d/=255),[b,c,d]},xb=function(b,c,d,e){b*=255,c*=255,d*=255;var f={r:b,g:c,b:d,hex:a.rgb(b,c,d),toString:vb};return a.is(e,"finite")&&(f.opacity=e),f};a.color=function(b){var c;return a.is(b,"object")&&"h"in b&&"s"in b&&"b"in b?(c=a.hsb2rgb(b),b.r=c.r,b.g=c.g,b.b=c.b,b.hex=c.hex):a.is(b,"object")&&"h"in b&&"s"in b&&"l"in b?(c=a.hsl2rgb(b),b.r=c.r,b.g=c.g,b.b=c.b,b.hex=c.hex):(a.is(b,"string")&&(b=a.getRGB(b)),a.is(b,"object")&&"r"in b&&"g"in b&&"b"in b?(c=a.rgb2hsl(b),b.h=c.h,b.s=c.s,b.l=c.l,c=a.rgb2hsb(b),b.v=c.b):(b={hex:"none"},b.r=b.g=b.b=b.h=b.s=b.v=b.l=-1)),b.toString=vb,b},a.hsb2rgb=function(a,b,c,d){this.is(a,"object")&&"h"in a&&"s"in a&&"b"in a&&(c=a.b,b=a.s,a=a.h,d=a.o),a*=360;var e,f,g,h,i;return a=a%360/60,i=c*b,h=i*(1-O(a%2-1)),e=f=g=c-i,a=~~a,e+=[i,h,0,0,h,i][a],f+=[h,i,i,h,0,0][a],g+=[0,0,h,i,i,h][a],xb(e,f,g,d)},a.hsl2rgb=function(a,b,c,d){this.is(a,"object")&&"h"in a&&"s"in a&&"l"in a&&(c=a.l,b=a.s,a=a.h),(a>1||b>1||c>1)&&(a/=360,b/=100,c/=100),a*=360;var e,f,g,h,i;return a=a%360/60,i=2*b*(.5>c?c:1-c),h=i*(1-O(a%2-1)),e=f=g=c-i/2,a=~~a,e+=[i,h,0,0,h,i][a],f+=[h,i,i,h,0,0][a],g+=[0,0,h,i,i,h][a],xb(e,f,g,d)},a.rgb2hsb=function(a,b,c){c=wb(a,b,c),a=c[0],b=c[1],c=c[2];var d,e,f,g;return f=M(a,b,c),g=f-N(a,b,c),d=0==g?null:f==a?(b-c)/g:f==b?(c-a)/g+2:(a-b)/g+4,d=(d+360)%6*60/360,e=0==g?0:g/f,{h:d,s:e,b:f,toString:tb}},a.rgb2hsl=function(a,b,c){c=wb(a,b,c),a=c[0],b=c[1],c=c[2];var d,e,f,g,h,i;return g=M(a,b,c),h=N(a,b,c),i=g-h,d=0==i?null:g==a?(b-c)/i:g==b?(c-a)/i+2:(a-b)/i+4,d=(d+360)%6*60/360,f=(g+h)/2,e=0==i?0:.5>f?i/(2*f):i/(2-2*f),{h:d,s:e,l:f,toString:ub}},a._path2string=function(){return this.join(",").replace(eb,"$1")};a._preload=function(a,b){var c=y.doc.createElement("img");c.style.cssText="position:absolute;left:-9999em;top:-9999em",c.onload=function(){b.call(this),this.onload=null,y.doc.body.removeChild(this)},c.onerror=function(){y.doc.body.removeChild(this)},y.doc.body.appendChild(c),c.src=a};a.getRGB=d(function(b){if(!b||(b=G(b)).indexOf("-")+1)return{r:-1,g:-1,b:-1,hex:"none",error:1,toString:e};if("none"==b)return{r:-1,g:-1,b:-1,hex:"none",toString:e};!(db[x](b.toLowerCase().substring(0,2))||"#"==b.charAt())&&(b=sb(b));var c,d,f,g,h,i,j=b.match(V);return j?(j[2]&&(f=$(j[2].substring(5),16),d=$(j[2].substring(3,5),16),c=$(j[2].substring(1,3),16)),j[3]&&(f=$((h=j[3].charAt(3))+h,16),d=$((h=j[3].charAt(2))+h,16),c=$((h=j[3].charAt(1))+h,16)),j[4]&&(i=j[4][H](cb),c=Z(i[0]),"%"==i[0].slice(-1)&&(c*=2.55),d=Z(i[1]),"%"==i[1].slice(-1)&&(d*=2.55),f=Z(i[2]),"%"==i[2].slice(-1)&&(f*=2.55),"rgba"==j[1].toLowerCase().slice(0,4)&&(g=Z(i[3])),i[3]&&"%"==i[3].slice(-1)&&(g/=100)),j[5]?(i=j[5][H](cb),c=Z(i[0]),"%"==i[0].slice(-1)&&(c*=2.55),d=Z(i[1]),"%"==i[1].slice(-1)&&(d*=2.55),f=Z(i[2]),"%"==i[2].slice(-1)&&(f*=2.55),("deg"==i[0].slice(-3)||"\xb0"==i[0].slice(-1))&&(c/=360),"hsba"==j[1].toLowerCase().slice(0,4)&&(g=Z(i[3])),i[3]&&"%"==i[3].slice(-1)&&(g/=100),a.hsb2rgb(c,d,f,g)):j[6]?(i=j[6][H](cb),c=Z(i[0]),"%"==i[0].slice(-1)&&(c*=2.55),d=Z(i[1]),"%"==i[1].slice(-1)&&(d*=2.55),f=Z(i[2]),"%"==i[2].slice(-1)&&(f*=2.55),("deg"==i[0].slice(-3)||"\xb0"==i[0].slice(-1))&&(c/=360),"hsla"==j[1].toLowerCase().slice(0,4)&&(g=Z(i[3])),i[3]&&"%"==i[3].slice(-1)&&(g/=100),a.hsl2rgb(c,d,f,g)):(j={r:c,g:d,b:f,toString:e},j.hex="#"+(16777216|f|d<<8|c<<16).toString(16).slice(1),a.is(g,"finite")&&(j.opacity=g),j)):{r:-1,g:-1,b:-1,hex:"none",error:1,toString:e}},a),a.hsb=d(function(b,c,d){return a.hsb2rgb(b,c,d).hex}),a.hsl=d(function(b,c,d){return a.hsl2rgb(b,c,d).hex}),a.rgb=d(function(a,b,c){return"#"+(16777216|c|b<<8|a<<16).toString(16).slice(1)}),a.getColor=function(a){var b=this.getColor.start=this.getColor.start||{h:0,s:1,b:a||.75},c=this.hsb2rgb(b.h,b.s,b.b);return b.h+=.075,b.h>1&&(b.h=0,b.s-=.2,b.s<=0&&(this.getColor.start={h:0,s:1,b:b.b})),c.hex},a.getColor.reset=function(){delete this.start},a.parsePathString=function(b){if(!b)return null;var c=yb(b);if(c.arr)return Ab(c.arr);var d={a:7,c:6,h:1,l:2,m:2,r:4,q:4,s:4,t:2,v:1,z:0},e=[];return a.is(b,T)&&a.is(b[0],T)&&(e=Ab(b)),e.length||G(b).replace(fb,function(a,b,c){var f=[],g=b.toLowerCase();if(c.replace(hb,function(a,b){b&&f.push(+b)}),"m"==g&&f.length>2&&(e.push([b][C](f.splice(0,2))),g="l",b="m"==b?"l":"L"),"r"==g)e.push([b][C](f));else for(;f.length>=d[g]&&(e.push([b][C](f.splice(0,d[g]))),d[g]););}),e.toString=a._path2string,c.arr=Ab(e),e},a.parseTransformString=d(function(b){if(!b)return null;var c=[];return a.is(b,T)&&a.is(b[0],T)&&(c=Ab(b)),c.length||G(b).replace(gb,function(a,b,d){{var e=[];K.call(b)}d.replace(hb,function(a,b){b&&e.push(+b)}),c.push([b][C](e))}),c.toString=a._path2string,c});var yb=function(a){var b=yb.ps=yb.ps||{};return b[a]?b[a].sleep=100:b[a]={sleep:100},setTimeout(function(){for(var c in b)b[x](c)&&c!=a&&(b[c].sleep--,!b[c].sleep&&delete b[c])}),b[a]};a.findDotsAtSegment=function(a,b,c,d,e,f,g,h,i){var j=1-i,k=P(j,3),l=P(j,2),m=i*i,n=m*i,o=k*a+3*l*i*c+3*j*i*i*e+n*g,p=k*b+3*l*i*d+3*j*i*i*f+n*h,q=a+2*i*(c-a)+m*(e-2*c+a),r=b+2*i*(d-b)+m*(f-2*d+b),s=c+2*i*(e-c)+m*(g-2*e+c),t=d+2*i*(f-d)+m*(h-2*f+d),u=j*a+i*c,v=j*b+i*d,w=j*e+i*g,x=j*f+i*h,y=90-180*L.atan2(q-s,r-t)/Q;return(q>s||t>r)&&(y+=180),{x:o,y:p,m:{x:q,y:r},n:{x:s,y:t},start:{x:u,y:v},end:{x:w,y:x},alpha:y}},a.bezierBBox=function(b,c,d,e,f,g,h,i){a.is(b,"array")||(b=[b,c,d,e,f,g,h,i]);var j=Hb.apply(null,b);return{x:j.min.x,y:j.min.y,x2:j.max.x,y2:j.max.y,width:j.max.x-j.min.x,height:j.max.y-j.min.y}},a.isPointInsideBBox=function(a,b,c){return b>=a.x&&b<=a.x2&&c>=a.y&&c<=a.y2},a.isBBoxIntersect=function(b,c){var d=a.isPointInsideBBox;return d(c,b.x,b.y)||d(c,b.x2,b.y)||d(c,b.x,b.y2)||d(c,b.x2,b.y2)||d(b,c.x,c.y)||d(b,c.x2,c.y)||d(b,c.x,c.y2)||d(b,c.x2,c.y2)||(b.x<c.x2&&b.x>c.x||c.x<b.x2&&c.x>b.x)&&(b.y<c.y2&&b.y>c.y||c.y<b.y2&&c.y>b.y)},a.pathIntersection=function(a,b){return l(a,b)},a.pathIntersectionNumber=function(a,b){return l(a,b,1)},a.isPointInsidePath=function(b,c,d){var e=a.pathBBox(b);return a.isPointInsideBBox(e,c,d)&&l(b,[["M",c,d],["H",e.x2+10]],1)%2==1},a._removedFactory=function(a){return function(){eve("raphael.log",null,"Rapha\xebl: you are calling to method \u201c"+a+"\u201d of removed object",a)}};var zb=a.pathBBox=function(a){var c=yb(a);if(c.bbox)return c.bbox;if(!a)return{x:0,y:0,width:0,height:0,x2:0,y2:0};a=Ib(a);for(var d,e=0,f=0,g=[],h=[],i=0,j=a.length;j>i;i++)if(d=a[i],"M"==d[0])e=d[1],f=d[2],g.push(e),h.push(f);else{var k=Hb(e,f,d[1],d[2],d[3],d[4],d[5],d[6]);g=g[C](k.min.x,k.max.x),h=h[C](k.min.y,k.max.y),e=d[5],f=d[6]}var l=N[B](0,g),m=N[B](0,h),n=M[B](0,g),o=M[B](0,h),p={x:l,y:m,x2:n,y2:o,width:n-l,height:o-m};return c.bbox=b(p),p},Ab=function(c){var d=b(c);return d.toString=a._path2string,d},Bb=a._pathToRelative=function(b){var c=yb(b);if(c.rel)return Ab(c.rel);a.is(b,T)&&a.is(b&&b[0],T)||(b=a.parsePathString(b));var d=[],e=0,f=0,g=0,h=0,i=0;"M"==b[0][0]&&(e=b[0][1],f=b[0][2],g=e,h=f,i++,d.push(["M",e,f]));for(var j=i,k=b.length;k>j;j++){var l=d[j]=[],m=b[j];if(m[0]!=K.call(m[0]))switch(l[0]=K.call(m[0]),l[0]){case"a":l[1]=m[1],l[2]=m[2],l[3]=m[3],l[4]=m[4],l[5]=m[5],l[6]=+(m[6]-e).toFixed(3),l[7]=+(m[7]-f).toFixed(3);break;case"v":l[1]=+(m[1]-f).toFixed(3);break;case"m":g=m[1],h=m[2];default:for(var n=1,o=m.length;o>n;n++)l[n]=+(m[n]-(n%2?e:f)).toFixed(3)}else{l=d[j]=[],"m"==m[0]&&(g=m[1]+e,h=m[2]+f);for(var p=0,q=m.length;q>p;p++)d[j][p]=m[p]}var r=d[j].length;switch(d[j][0]){case"z":e=g,f=h;break;case"h":e+=+d[j][r-1];break;case"v":f+=+d[j][r-1];break;default:e+=+d[j][r-2],f+=+d[j][r-1]}}return d.toString=a._path2string,c.rel=Ab(d),d},Cb=a._pathToAbsolute=function(b){var c=yb(b);if(c.abs)return Ab(c.abs);if(a.is(b,T)&&a.is(b&&b[0],T)||(b=a.parsePathString(b)),!b||!b.length)return[["M",0,0]];var d=[],e=0,g=0,h=0,i=0,j=0;"M"==b[0][0]&&(e=+b[0][1],g=+b[0][2],h=e,i=g,j++,d[0]=["M",e,g]);for(var k,l,m=3==b.length&&"M"==b[0][0]&&"R"==b[1][0].toUpperCase()&&"Z"==b[2][0].toUpperCase(),n=j,o=b.length;o>n;n++){if(d.push(k=[]),l=b[n],l[0]!=_.call(l[0]))switch(k[0]=_.call(l[0]),k[0]){case"A":k[1]=l[1],k[2]=l[2],k[3]=l[3],k[4]=l[4],k[5]=l[5],k[6]=+(l[6]+e),k[7]=+(l[7]+g);break;case"V":k[1]=+l[1]+g;break;case"H":k[1]=+l[1]+e;break;case"R":for(var p=[e,g][C](l.slice(1)),q=2,r=p.length;r>q;q++)p[q]=+p[q]+e,p[++q]=+p[q]+g;d.pop(),d=d[C](f(p,m));break;case"M":h=+l[1]+e,i=+l[2]+g;default:for(q=1,r=l.length;r>q;q++)k[q]=+l[q]+(q%2?e:g)}else if("R"==l[0])p=[e,g][C](l.slice(1)),d.pop(),d=d[C](f(p,m)),k=["R"][C](l.slice(-2));else for(var s=0,t=l.length;t>s;s++)k[s]=l[s];switch(k[0]){case"Z":e=h,g=i;break;case"H":e=k[1];break;case"V":g=k[1];break;case"M":h=k[k.length-2],i=k[k.length-1];default:e=k[k.length-2],g=k[k.length-1]}}return d.toString=a._path2string,c.abs=Ab(d),d},Db=function(a,b,c,d){return[a,b,c,d,c,d]},Eb=function(a,b,c,d,e,f){var g=1/3,h=2/3;return[g*a+h*c,g*b+h*d,g*e+h*c,g*f+h*d,e,f]},Fb=function(a,b,c,e,f,g,h,i,j,k){var l,m=120*Q/180,n=Q/180*(+f||0),o=[],p=d(function(a,b,c){var d=a*L.cos(c)-b*L.sin(c),e=a*L.sin(c)+b*L.cos(c);return{x:d,y:e}});if(k)y=k[0],z=k[1],w=k[2],x=k[3];else{l=p(a,b,-n),a=l.x,b=l.y,l=p(i,j,-n),i=l.x,j=l.y;var q=(L.cos(Q/180*f),L.sin(Q/180*f),(a-i)/2),r=(b-j)/2,s=q*q/(c*c)+r*r/(e*e);s>1&&(s=L.sqrt(s),c=s*c,e=s*e);var t=c*c,u=e*e,v=(g==h?-1:1)*L.sqrt(O((t*u-t*r*r-u*q*q)/(t*r*r+u*q*q))),w=v*c*r/e+(a+i)/2,x=v*-e*q/c+(b+j)/2,y=L.asin(((b-x)/e).toFixed(9)),z=L.asin(((j-x)/e).toFixed(9));y=w>a?Q-y:y,z=w>i?Q-z:z,0>y&&(y=2*Q+y),0>z&&(z=2*Q+z),h&&y>z&&(y-=2*Q),!h&&z>y&&(z-=2*Q)}var A=z-y;if(O(A)>m){var B=z,D=i,E=j;z=y+m*(h&&z>y?1:-1),i=w+c*L.cos(z),j=x+e*L.sin(z),o=Fb(i,j,c,e,f,0,h,D,E,[z,B,w,x])}A=z-y;var F=L.cos(y),G=L.sin(y),I=L.cos(z),J=L.sin(z),K=L.tan(A/4),M=4/3*c*K,N=4/3*e*K,P=[a,b],R=[a+M*G,b-N*F],S=[i+M*J,j-N*I],T=[i,j];if(R[0]=2*P[0]-R[0],R[1]=2*P[1]-R[1],k)return[R,S,T][C](o);o=[R,S,T][C](o).join()[H](",");for(var U=[],V=0,W=o.length;W>V;V++)U[V]=V%2?p(o[V-1],o[V],n).y:p(o[V],o[V+1],n).x;return U},Gb=function(a,b,c,d,e,f,g,h,i){var j=1-i;return{x:P(j,3)*a+3*P(j,2)*i*c+3*j*i*i*e+P(i,3)*g,y:P(j,3)*b+3*P(j,2)*i*d+3*j*i*i*f+P(i,3)*h}},Hb=d(function(a,b,c,d,e,f,g,h){var i,j=e-2*c+a-(g-2*e+c),k=2*(c-a)-2*(e-c),l=a-c,m=(-k+L.sqrt(k*k-4*j*l))/2/j,n=(-k-L.sqrt(k*k-4*j*l))/2/j,o=[b,h],p=[a,g];return O(m)>"1e12"&&(m=.5),O(n)>"1e12"&&(n=.5),m>0&&1>m&&(i=Gb(a,b,c,d,e,f,g,h,m),p.push(i.x),o.push(i.y)),n>0&&1>n&&(i=Gb(a,b,c,d,e,f,g,h,n),p.push(i.x),o.push(i.y)),j=f-2*d+b-(h-2*f+d),k=2*(d-b)-2*(f-d),l=b-d,m=(-k+L.sqrt(k*k-4*j*l))/2/j,n=(-k-L.sqrt(k*k-4*j*l))/2/j,O(m)>"1e12"&&(m=.5),O(n)>"1e12"&&(n=.5),m>0&&1>m&&(i=Gb(a,b,c,d,e,f,g,h,m),p.push(i.x),o.push(i.y)),n>0&&1>n&&(i=Gb(a,b,c,d,e,f,g,h,n),p.push(i.x),o.push(i.y)),{min:{x:N[B](0,p),y:N[B](0,o)},max:{x:M[B](0,p),y:M[B](0,o)}}}),Ib=a._path2curve=d(function(a,b){var c=!b&&yb(a);if(!b&&c.curve)return Ab(c.curve);for(var d=Cb(a),e=b&&Cb(b),f={x:0,y:0,bx:0,by:0,X:0,Y:0,qx:null,qy:null},g={x:0,y:0,bx:0,by:0,X:0,Y:0,qx:null,qy:null},h=(function(a,b){var c,d;if(!a)return["C",b.x,b.y,b.x,b.y,b.x,b.y];switch(!(a[0]in{T:1,Q:1})&&(b.qx=b.qy=null),a[0]){case"M":b.X=a[1],b.Y=a[2];break;case"A":a=["C"][C](Fb[B](0,[b.x,b.y][C](a.slice(1))));break;case"S":c=b.x+(b.x-(b.bx||b.x)),d=b.y+(b.y-(b.by||b.y)),a=["C",c,d][C](a.slice(1));break;case"T":b.qx=b.x+(b.x-(b.qx||b.x)),b.qy=b.y+(b.y-(b.qy||b.y)),a=["C"][C](Eb(b.x,b.y,b.qx,b.qy,a[1],a[2]));break;case"Q":b.qx=a[1],b.qy=a[2],a=["C"][C](Eb(b.x,b.y,a[1],a[2],a[3],a[4]));break;case"L":a=["C"][C](Db(b.x,b.y,a[1],a[2]));break;case"H":a=["C"][C](Db(b.x,b.y,a[1],b.y));break;case"V":a=["C"][C](Db(b.x,b.y,b.x,a[1]));break;case"Z":a=["C"][C](Db(b.x,b.y,b.X,b.Y))}return a}),i=function(a,b){if(a[b].length>7){a[b].shift();for(var c=a[b];c.length;)a.splice(b++,0,["C"][C](c.splice(0,6)));a.splice(b,1),l=M(d.length,e&&e.length||0)}},j=function(a,b,c,f,g){a&&b&&"M"==a[g][0]&&"M"!=b[g][0]&&(b.splice(g,0,["M",f.x,f.y]),c.bx=0,c.by=0,c.x=a[g][1],c.y=a[g][2],l=M(d.length,e&&e.length||0))},k=0,l=M(d.length,e&&e.length||0);l>k;k++){d[k]=h(d[k],f),i(d,k),e&&(e[k]=h(e[k],g)),e&&i(e,k),j(d,e,f,g,k),j(e,d,g,f,k);var m=d[k],n=e&&e[k],o=m.length,p=e&&n.length;f.x=m[o-2],f.y=m[o-1],f.bx=Z(m[o-4])||f.x,f.by=Z(m[o-3])||f.y,g.bx=e&&(Z(n[p-4])||g.x),g.by=e&&(Z(n[p-3])||g.y),g.x=e&&n[p-2],g.y=e&&n[p-1]}return e||(c.curve=Ab(d)),e?[d,e]:d},null,Ab),Jb=(a._parseDots=d(function(b){for(var c=[],d=0,e=b.length;e>d;d++){var f={},g=b[d].match(/^([^:]*):?([\d\.]*)/);if(f.color=a.getRGB(g[1]),f.color.error)return null;f.color=f.color.hex,g[2]&&(f.offset=g[2]+"%"),c.push(f)}for(d=1,e=c.length-1;e>d;d++)if(!c[d].offset){for(var h=Z(c[d-1].offset||0),i=0,j=d+1;e>j;j++)if(c[j].offset){i=c[j].offset;break}i||(i=100,j=e),i=Z(i);for(var k=(i-h)/(j-d+1);j>d;d++)h+=k,c[d].offset=h+"%"}return c}),a._tear=function(a,b){a==b.top&&(b.top=a.prev),a==b.bottom&&(b.bottom=a.next),a.next&&(a.next.prev=a.prev),a.prev&&(a.prev.next=a.next)}),Kb=(a._tofront=function(a,b){b.top!==a&&(Jb(a,b),a.next=null,a.prev=b.top,b.top.next=a,b.top=a)},a._toback=function(a,b){b.bottom!==a&&(Jb(a,b),a.next=b.bottom,a.prev=null,b.bottom.prev=a,b.bottom=a) },a._insertafter=function(a,b,c){Jb(a,c),b==c.top&&(c.top=a),b.next&&(b.next.prev=a),a.next=b.next,a.prev=b,b.next=a},a._insertbefore=function(a,b,c){Jb(a,c),b==c.bottom&&(c.bottom=a),b.prev&&(b.prev.next=a),a.prev=b.prev,b.prev=a,a.next=b},a.toMatrix=function(a,b){var c=zb(a),d={_:{transform:E},getBBox:function(){return c}};return Lb(d,b),d.matrix}),Lb=(a.transformPath=function(a,b){return pb(a,Kb(a,b))},a._extractTransform=function(b,c){if(null==c)return b._.transform;c=G(c).replace(/\.{3}|\u2026/g,b._.transform||E);var d=a.parseTransformString(c),e=0,f=0,g=0,h=1,i=1,j=b._,k=new m;if(j.transform=d||[],d)for(var l=0,n=d.length;n>l;l++){var o,p,q,r,s,t=d[l],u=t.length,v=G(t[0]).toLowerCase(),w=t[0]!=v,x=w?k.invert():0;"t"==v&&3==u?w?(o=x.x(0,0),p=x.y(0,0),q=x.x(t[1],t[2]),r=x.y(t[1],t[2]),k.translate(q-o,r-p)):k.translate(t[1],t[2]):"r"==v?2==u?(s=s||b.getBBox(1),k.rotate(t[1],s.x+s.width/2,s.y+s.height/2),e+=t[1]):4==u&&(w?(q=x.x(t[2],t[3]),r=x.y(t[2],t[3]),k.rotate(t[1],q,r)):k.rotate(t[1],t[2],t[3]),e+=t[1]):"s"==v?2==u||3==u?(s=s||b.getBBox(1),k.scale(t[1],t[u-1],s.x+s.width/2,s.y+s.height/2),h*=t[1],i*=t[u-1]):5==u&&(w?(q=x.x(t[3],t[4]),r=x.y(t[3],t[4]),k.scale(t[1],t[2],q,r)):k.scale(t[1],t[2],t[3],t[4]),h*=t[1],i*=t[2]):"m"==v&&7==u&&k.add(t[1],t[2],t[3],t[4],t[5],t[6]),j.dirtyT=1,b.matrix=k}b.matrix=k,j.sx=h,j.sy=i,j.deg=e,j.dx=f=k.e,j.dy=g=k.f,1==h&&1==i&&!e&&j.bbox?(j.bbox.x+=+f,j.bbox.y+=+g):j.dirtyT=1}),Mb=function(a){var b=a[0];switch(b.toLowerCase()){case"t":return[b,0,0];case"m":return[b,1,0,0,1,0,0];case"r":return 4==a.length?[b,0,a[2],a[3]]:[b,0];case"s":return 5==a.length?[b,1,1,a[3],a[4]]:3==a.length?[b,1,1]:[b,1]}},Nb=a._equaliseTransform=function(b,c){c=G(c).replace(/\.{3}|\u2026/g,b),b=a.parseTransformString(b)||[],c=a.parseTransformString(c)||[];for(var d,e,f,g,h=M(b.length,c.length),i=[],j=[],k=0;h>k;k++){if(f=b[k]||Mb(c[k]),g=c[k]||Mb(f),f[0]!=g[0]||"r"==f[0].toLowerCase()&&(f[2]!=g[2]||f[3]!=g[3])||"s"==f[0].toLowerCase()&&(f[3]!=g[3]||f[4]!=g[4]))return;for(i[k]=[],j[k]=[],d=0,e=M(f.length,g.length);e>d;d++)d in f&&(i[k][d]=f[d]),d in g&&(j[k][d]=g[d])}return{from:i,to:j}};a._getContainer=function(b,c,d,e){var f;return f=null!=e||a.is(b,"object")?b:y.doc.getElementById(b),null!=f?f.tagName?null==c?{container:f,width:f.style.pixelWidth||f.offsetWidth,height:f.style.pixelHeight||f.offsetHeight}:{container:f,width:c,height:d}:{container:1,x:b,y:c,width:d,height:e}:void 0},a.pathToRelative=Bb,a._engine={},a.path2curve=Ib,a.matrix=function(a,b,c,d,e,f){return new m(a,b,c,d,e,f)},function(b){function c(a){return a[0]*a[0]+a[1]*a[1]}function d(a){var b=L.sqrt(c(a));a[0]&&(a[0]/=b),a[1]&&(a[1]/=b)}b.add=function(a,b,c,d,e,f){var g,h,i,j,k=[[],[],[]],l=[[this.a,this.c,this.e],[this.b,this.d,this.f],[0,0,1]],n=[[a,c,e],[b,d,f],[0,0,1]];for(a&&a instanceof m&&(n=[[a.a,a.c,a.e],[a.b,a.d,a.f],[0,0,1]]),g=0;3>g;g++)for(h=0;3>h;h++){for(j=0,i=0;3>i;i++)j+=l[g][i]*n[i][h];k[g][h]=j}this.a=k[0][0],this.b=k[1][0],this.c=k[0][1],this.d=k[1][1],this.e=k[0][2],this.f=k[1][2]},b.invert=function(){var a=this,b=a.a*a.d-a.b*a.c;return new m(a.d/b,-a.b/b,-a.c/b,a.a/b,(a.c*a.f-a.d*a.e)/b,(a.b*a.e-a.a*a.f)/b)},b.clone=function(){return new m(this.a,this.b,this.c,this.d,this.e,this.f)},b.translate=function(a,b){this.add(1,0,0,1,a,b)},b.scale=function(a,b,c,d){null==b&&(b=a),(c||d)&&this.add(1,0,0,1,c,d),this.add(a,0,0,b,0,0),(c||d)&&this.add(1,0,0,1,-c,-d)},b.rotate=function(b,c,d){b=a.rad(b),c=c||0,d=d||0;var e=+L.cos(b).toFixed(9),f=+L.sin(b).toFixed(9);this.add(e,f,-f,e,c,d),this.add(1,0,0,1,-c,-d)},b.x=function(a,b){return a*this.a+b*this.c+this.e},b.y=function(a,b){return a*this.b+b*this.d+this.f},b.get=function(a){return+this[G.fromCharCode(97+a)].toFixed(4)},b.toString=function(){return a.svg?"matrix("+[this.get(0),this.get(1),this.get(2),this.get(3),this.get(4),this.get(5)].join()+")":[this.get(0),this.get(2),this.get(1),this.get(3),0,0].join()},b.toFilter=function(){return"progid:DXImageTransform.Microsoft.Matrix(M11="+this.get(0)+", M12="+this.get(2)+", M21="+this.get(1)+", M22="+this.get(3)+", Dx="+this.get(4)+", Dy="+this.get(5)+", sizingmethod='auto expand')"},b.offset=function(){return[this.e.toFixed(4),this.f.toFixed(4)]},b.split=function(){var b={};b.dx=this.e,b.dy=this.f;var e=[[this.a,this.c],[this.b,this.d]];b.scalex=L.sqrt(c(e[0])),d(e[0]),b.shear=e[0][0]*e[1][0]+e[0][1]*e[1][1],e[1]=[e[1][0]-e[0][0]*b.shear,e[1][1]-e[0][1]*b.shear],b.scaley=L.sqrt(c(e[1])),d(e[1]),b.shear/=b.scaley;var f=-e[0][1],g=e[1][1];return 0>g?(b.rotate=a.deg(L.acos(g)),0>f&&(b.rotate=360-b.rotate)):b.rotate=a.deg(L.asin(f)),b.isSimple=!(+b.shear.toFixed(9)||b.scalex.toFixed(9)!=b.scaley.toFixed(9)&&b.rotate),b.isSuperSimple=!+b.shear.toFixed(9)&&b.scalex.toFixed(9)==b.scaley.toFixed(9)&&!b.rotate,b.noRotation=!+b.shear.toFixed(9)&&!b.rotate,b},b.toTransformString=function(a){var b=a||this[H]();return b.isSimple?(b.scalex=+b.scalex.toFixed(4),b.scaley=+b.scaley.toFixed(4),b.rotate=+b.rotate.toFixed(4),(b.dx||b.dy?"t"+[b.dx,b.dy]:E)+(1!=b.scalex||1!=b.scaley?"s"+[b.scalex,b.scaley,0,0]:E)+(b.rotate?"r"+[b.rotate,0,0]:E)):"m"+[this.get(0),this.get(1),this.get(2),this.get(3),this.get(4),this.get(5)]}}(m.prototype);var Ob=navigator.userAgent.match(/Version\/(.*?)\s/)||navigator.userAgent.match(/Chrome\/(\d+)/);t.safari="Apple Computer, Inc."==navigator.vendor&&(Ob&&Ob[1]<4||"iP"==navigator.platform.slice(0,2))||"Google Inc."==navigator.vendor&&Ob&&Ob[1]<8?function(){var a=this.rect(-99,-99,this.width+99,this.height+99).attr({stroke:"none"});setTimeout(function(){a.remove()})}:kb;for(var Pb=function(){this.returnValue=!1},Qb=function(){return this.originalEvent.preventDefault()},Rb=function(){this.cancelBubble=!0},Sb=function(){return this.originalEvent.stopPropagation()},Tb=function(){return y.doc.addEventListener?function(a,b,c,d){var e=D&&J[b]?J[b]:b,f=function(e){var f=y.doc.documentElement.scrollTop||y.doc.body.scrollTop,g=y.doc.documentElement.scrollLeft||y.doc.body.scrollLeft,h=e.clientX+g,i=e.clientY+f;if(D&&J[x](b))for(var j=0,k=e.targetTouches&&e.targetTouches.length;k>j;j++)if(e.targetTouches[j].target==a){var l=e;e=e.targetTouches[j],e.originalEvent=l,e.preventDefault=Qb,e.stopPropagation=Sb;break}return c.call(d,e,h,i)};return a.addEventListener(e,f,!1),function(){return a.removeEventListener(e,f,!1),!0}}:y.doc.attachEvent?function(a,b,c,d){var e=function(a){a=a||y.win.event;var b=y.doc.documentElement.scrollTop||y.doc.body.scrollTop,e=y.doc.documentElement.scrollLeft||y.doc.body.scrollLeft,f=a.clientX+e,g=a.clientY+b;return a.preventDefault=a.preventDefault||Pb,a.stopPropagation=a.stopPropagation||Rb,c.call(d,a,f,g)};a.attachEvent("on"+b,e);var f=function(){return a.detachEvent("on"+b,e),!0};return f}:void 0}(),Ub=[],Vb=function(a){for(var b,c=a.clientX,d=a.clientY,e=y.doc.documentElement.scrollTop||y.doc.body.scrollTop,f=y.doc.documentElement.scrollLeft||y.doc.body.scrollLeft,g=Ub.length;g--;){if(b=Ub[g],D){for(var h,i=a.touches.length;i--;)if(h=a.touches[i],h.identifier==b.el._drag.id){c=h.clientX,d=h.clientY,(a.originalEvent?a.originalEvent:a).preventDefault();break}}else a.preventDefault();var j,k=b.el.node,l=k.nextSibling,m=k.parentNode,n=k.style.display;y.win.opera&&m.removeChild(k),k.style.display="none",j=b.el.paper.getElementByPoint(c,d),k.style.display=n,y.win.opera&&(l?m.insertBefore(k,l):m.appendChild(k)),j&&eve("raphael.drag.over."+b.el.id,b.el,j),c+=f,d+=e,eve("raphael.drag.move."+b.el.id,b.move_scope||b.el,c-b.el._drag.x,d-b.el._drag.y,c,d,a)}},Wb=function(b){a.unmousemove(Vb).unmouseup(Wb);for(var c,d=Ub.length;d--;)c=Ub[d],c.el._drag={},eve("raphael.drag.end."+c.el.id,c.end_scope||c.start_scope||c.move_scope||c.el,b);Ub=[]},Xb=a.el={},Yb=I.length;Yb--;)!function(b){a[b]=Xb[b]=function(c,d){return a.is(c,"function")&&(this.events=this.events||[],this.events.push({name:b,f:c,unbind:Tb(this.shape||this.node||y.doc,b,c,d||this)})),this},a["un"+b]=Xb["un"+b]=function(a){for(var c=this.events||[],d=c.length;d--;)if(c[d].name==b&&c[d].f==a)return c[d].unbind(),c.splice(d,1),!c.length&&delete this.events,this;return this}}(I[Yb]);Xb.data=function(b,c){var d=ib[this.id]=ib[this.id]||{};if(1==arguments.length){if(a.is(b,"object")){for(var e in b)b[x](e)&&this.data(e,b[e]);return this}return eve("raphael.data.get."+this.id,this,d[b],b),d[b]}return d[b]=c,eve("raphael.data.set."+this.id,this,c,b),this},Xb.removeData=function(a){return null==a?ib[this.id]={}:ib[this.id]&&delete ib[this.id][a],this},Xb.hover=function(a,b,c,d){return this.mouseover(a,c).mouseout(b,d||c)},Xb.unhover=function(a,b){return this.unmouseover(a).unmouseout(b)};var Zb=[];Xb.drag=function(b,c,d,e,f,g){function h(h){(h.originalEvent||h).preventDefault();var i=y.doc.documentElement.scrollTop||y.doc.body.scrollTop,j=y.doc.documentElement.scrollLeft||y.doc.body.scrollLeft;this._drag.x=h.clientX+j,this._drag.y=h.clientY+i,this._drag.id=h.identifier,!Ub.length&&a.mousemove(Vb).mouseup(Wb),Ub.push({el:this,move_scope:e,start_scope:f,end_scope:g}),c&&eve.on("raphael.drag.start."+this.id,c),b&&eve.on("raphael.drag.move."+this.id,b),d&&eve.on("raphael.drag.end."+this.id,d),eve("raphael.drag.start."+this.id,f||e||this,h.clientX+j,h.clientY+i,h)}return this._drag={},Zb.push({el:this,start:h}),this.mousedown(h),this},Xb.onDragOver=function(a){a?eve.on("raphael.drag.over."+this.id,a):eve.unbind("raphael.drag.over."+this.id)},Xb.undrag=function(){for(var b=Zb.length;b--;)Zb[b].el==this&&(this.unmousedown(Zb[b].start),Zb.splice(b,1),eve.unbind("raphael.drag.*."+this.id));!Zb.length&&a.unmousemove(Vb).unmouseup(Wb)},t.circle=function(b,c,d){var e=a._engine.circle(this,b||0,c||0,d||0);return this.__set__&&this.__set__.push(e),e},t.rect=function(b,c,d,e,f){var g=a._engine.rect(this,b||0,c||0,d||0,e||0,f||0);return this.__set__&&this.__set__.push(g),g},t.ellipse=function(b,c,d,e){var f=a._engine.ellipse(this,b||0,c||0,d||0,e||0);return this.__set__&&this.__set__.push(f),f},t.path=function(b){b&&!a.is(b,S)&&!a.is(b[0],T)&&(b+=E);var c=a._engine.path(a.format[B](a,arguments),this);return this.__set__&&this.__set__.push(c),c},t.image=function(b,c,d,e,f){var g=a._engine.image(this,b||"about:blank",c||0,d||0,e||0,f||0);return this.__set__&&this.__set__.push(g),g},t.text=function(b,c,d){var e=a._engine.text(this,b||0,c||0,G(d));return this.__set__&&this.__set__.push(e),e},t.set=function(b){!a.is(b,"array")&&(b=Array.prototype.splice.call(arguments,0,arguments.length));var c=new jc(b);return this.__set__&&this.__set__.push(c),c},t.setStart=function(a){this.__set__=a||this.set()},t.setFinish=function(){var a=this.__set__;return delete this.__set__,a},t.setSize=function(b,c){return a._engine.setSize.call(this,b,c)},t.setViewBox=function(b,c,d,e,f){return a._engine.setViewBox.call(this,b,c,d,e,f)},t.top=t.bottom=null,t.raphael=a;var $b=function(a){var b=a.getBoundingClientRect(),c=a.ownerDocument,d=c.body,e=c.documentElement,f=e.clientTop||d.clientTop||0,g=e.clientLeft||d.clientLeft||0,h=b.top+(y.win.pageYOffset||e.scrollTop||d.scrollTop)-f,i=b.left+(y.win.pageXOffset||e.scrollLeft||d.scrollLeft)-g;return{y:h,x:i}};t.getElementByPoint=function(a,b){var c=this,d=c.canvas,e=y.doc.elementFromPoint(a,b);if(y.win.opera&&"svg"==e.tagName){var f=$b(d),g=d.createSVGRect();g.x=a-f.x,g.y=b-f.y,g.width=g.height=1;var h=d.getIntersectionList(g,null);h.length&&(e=h[h.length-1])}if(!e)return null;for(;e.parentNode&&e!=d.parentNode&&!e.raphael;)e=e.parentNode;return e==c.canvas.parentNode&&(e=d),e=e&&e.raphael?c.getById(e.raphaelid):null},t.getById=function(a){for(var b=this.bottom;b;){if(b.id==a)return b;b=b.next}return null},t.forEach=function(a,b){for(var c=this.bottom;c;){if(a.call(b,c)===!1)return this;c=c.next}return this},t.getElementsByPoint=function(a,b){var c=this.set();return this.forEach(function(d){d.isPointInside(a,b)&&c.push(d)}),c},Xb.isPointInside=function(b,c){var d=this.realPath=this.realPath||ob[this.type](this);return a.isPointInsidePath(d,b,c)},Xb.getBBox=function(a){if(this.removed)return{};var b=this._;return a?((b.dirty||!b.bboxwt)&&(this.realPath=ob[this.type](this),b.bboxwt=zb(this.realPath),b.bboxwt.toString=n,b.dirty=0),b.bboxwt):((b.dirty||b.dirtyT||!b.bbox)&&((b.dirty||!this.realPath)&&(b.bboxwt=0,this.realPath=ob[this.type](this)),b.bbox=zb(pb(this.realPath,this.matrix)),b.bbox.toString=n,b.dirty=b.dirtyT=0),b.bbox)},Xb.clone=function(){if(this.removed)return null;var a=this.paper[this.type]().attr(this.attr());return this.__set__&&this.__set__.push(a),a},Xb.glow=function(a){if("text"==this.type)return null;a=a||{};var b={width:(a.width||10)+(+this.attr("stroke-width")||1),fill:a.fill||!1,opacity:a.opacity||.5,offsetx:a.offsetx||0,offsety:a.offsety||0,color:a.color||"#000"},c=b.width/2,d=this.paper,e=d.set(),f=this.realPath||ob[this.type](this);f=this.matrix?pb(f,this.matrix):f;for(var g=1;c+1>g;g++)e.push(d.path(f).attr({stroke:b.color,fill:b.fill?b.color:"none","stroke-linejoin":"round","stroke-linecap":"round","stroke-width":+(b.width/c*g).toFixed(3),opacity:+(b.opacity/c).toFixed(3)}));return e.insertBefore(this).translate(b.offsetx,b.offsety)};var _b=function(b,c,d,e,f,g,j,k,l){return null==l?h(b,c,d,e,f,g,j,k):a.findDotsAtSegment(b,c,d,e,f,g,j,k,i(b,c,d,e,f,g,j,k,l))},ac=function(b,c){return function(d,e,f){d=Ib(d);for(var g,h,i,j,k,l="",m={},n=0,o=0,p=d.length;p>o;o++){if(i=d[o],"M"==i[0])g=+i[1],h=+i[2];else{if(j=_b(g,h,i[1],i[2],i[3],i[4],i[5],i[6]),n+j>e){if(c&&!m.start){if(k=_b(g,h,i[1],i[2],i[3],i[4],i[5],i[6],e-n),l+=["C"+k.start.x,k.start.y,k.m.x,k.m.y,k.x,k.y],f)return l;m.start=l,l=["M"+k.x,k.y+"C"+k.n.x,k.n.y,k.end.x,k.end.y,i[5],i[6]].join(),n+=j,g=+i[5],h=+i[6];continue}if(!b&&!c)return k=_b(g,h,i[1],i[2],i[3],i[4],i[5],i[6],e-n),{x:k.x,y:k.y,alpha:k.alpha}}n+=j,g=+i[5],h=+i[6]}l+=i.shift()+i}return m.end=l,k=b?n:c?m:a.findDotsAtSegment(g,h,i[0],i[1],i[2],i[3],i[4],i[5],1),k.alpha&&(k={x:k.x,y:k.y,alpha:k.alpha}),k}},bc=ac(1),cc=ac(),dc=ac(0,1);a.getTotalLength=bc,a.getPointAtLength=cc,a.getSubpath=function(a,b,c){if(this.getTotalLength(a)-c<1e-6)return dc(a,b).end;var d=dc(a,c,1);return b?dc(d,b).end:d},Xb.getTotalLength=function(){return"path"==this.type?this.node.getTotalLength?this.node.getTotalLength():bc(this.attrs.path):void 0},Xb.getPointAtLength=function(a){return"path"==this.type?cc(this.attrs.path,a):void 0},Xb.getSubpath=function(b,c){return"path"==this.type?a.getSubpath(this.attrs.path,b,c):void 0};var ec=a.easing_formulas={linear:function(a){return a},"<":function(a){return P(a,1.7)},">":function(a){return P(a,.48)},"<>":function(a){var b=.48-a/1.04,c=L.sqrt(.1734+b*b),d=c-b,e=P(O(d),1/3)*(0>d?-1:1),f=-c-b,g=P(O(f),1/3)*(0>f?-1:1),h=e+g+.5;return 3*(1-h)*h*h+h*h*h},backIn:function(a){var b=1.70158;return a*a*((b+1)*a-b)},backOut:function(a){a-=1;var b=1.70158;return a*a*((b+1)*a+b)+1},elastic:function(a){return a==!!a?a:P(2,-10*a)*L.sin(2*(a-.075)*Q/.3)+1},bounce:function(a){var b,c=7.5625,d=2.75;return 1/d>a?b=c*a*a:2/d>a?(a-=1.5/d,b=c*a*a+.75):2.5/d>a?(a-=2.25/d,b=c*a*a+.9375):(a-=2.625/d,b=c*a*a+.984375),b}};ec.easeIn=ec["ease-in"]=ec["<"],ec.easeOut=ec["ease-out"]=ec[">"],ec.easeInOut=ec["ease-in-out"]=ec["<>"],ec["back-in"]=ec.backIn,ec["back-out"]=ec.backOut;var fc=[],gc=window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.oRequestAnimationFrame||window.msRequestAnimationFrame||function(a){setTimeout(a,16)},hc=function(){for(var b=+new Date,c=0;c<fc.length;c++){var d=fc[c];if(!d.el.removed&&!d.paused){var e,f,g=b-d.start,h=d.ms,i=d.easing,j=d.from,k=d.diff,l=d.to,m=(d.t,d.el),n={},o={};if(d.initstatus?(g=(d.initstatus*d.anim.top-d.prev)/(d.percent-d.prev)*h,d.status=d.initstatus,delete d.initstatus,d.stop&&fc.splice(c--,1)):d.status=(d.prev+(d.percent-d.prev)*(g/h))/d.anim.top,!(0>g))if(h>g){var p=i(g/h);for(var r in j)if(j[x](r)){switch(bb[r]){case R:e=+j[r]+p*h*k[r];break;case"colour":e="rgb("+[ic(Y(j[r].r+p*h*k[r].r)),ic(Y(j[r].g+p*h*k[r].g)),ic(Y(j[r].b+p*h*k[r].b))].join(",")+")";break;case"path":e=[];for(var s=0,t=j[r].length;t>s;s++){e[s]=[j[r][s][0]];for(var u=1,v=j[r][s].length;v>u;u++)e[s][u]=+j[r][s][u]+p*h*k[r][s][u];e[s]=e[s].join(F)}e=e.join(F);break;case"transform":if(k[r].real)for(e=[],s=0,t=j[r].length;t>s;s++)for(e[s]=[j[r][s][0]],u=1,v=j[r][s].length;v>u;u++)e[s][u]=j[r][s][u]+p*h*k[r][s][u];else{var w=function(a){return+j[r][a]+p*h*k[r][a]};e=[["m",w(0),w(1),w(2),w(3),w(4),w(5)]]}break;case"csv":if("clip-rect"==r)for(e=[],s=4;s--;)e[s]=+j[r][s]+p*h*k[r][s];break;default:var y=[][C](j[r]);for(e=[],s=m.paper.customAttributes[r].length;s--;)e[s]=+y[s]+p*h*k[r][s]}n[r]=e}m.attr(n),function(a,b,c){setTimeout(function(){eve("raphael.anim.frame."+a,b,c)})}(m.id,m,d.anim)}else{if(function(b,c,d){setTimeout(function(){eve("raphael.anim.frame."+c.id,c,d),eve("raphael.anim.finish."+c.id,c,d),a.is(b,"function")&&b.call(c)})}(d.callback,m,d.anim),m.attr(l),fc.splice(c--,1),d.repeat>1&&!d.next){for(f in l)l[x](f)&&(o[f]=d.totalOrigin[f]);d.el.attr(o),q(d.anim,d.el,d.anim.percents[0],null,d.totalOrigin,d.repeat-1)}d.next&&!d.stop&&q(d.anim,d.el,d.next,null,d.totalOrigin,d.repeat)}}}a.svg&&m&&m.paper&&m.paper.safari(),fc.length&&gc(hc)},ic=function(a){return a>255?255:0>a?0:a};Xb.animateWith=function(b,c,d,e,f,g){var h=this;if(h.removed)return g&&g.call(h),h;var i=d instanceof p?d:a.animation(d,e,f,g);q(i,h,i.percents[0],null,h.attr());for(var j=0,k=fc.length;k>j;j++)if(fc[j].anim==c&&fc[j].el==b){fc[k-1].start=fc[j].start;break}return h},Xb.onAnimation=function(a){return a?eve.on("raphael.anim.frame."+this.id,a):eve.unbind("raphael.anim.frame."+this.id),this},p.prototype.delay=function(a){var b=new p(this.anim,this.ms);return b.times=this.times,b.del=+a||0,b},p.prototype.repeat=function(a){var b=new p(this.anim,this.ms);return b.del=this.del,b.times=L.floor(M(a,0))||1,b},a.animation=function(b,c,d,e){if(b instanceof p)return b;(a.is(d,"function")||!d)&&(e=e||d||null,d=null),b=Object(b),c=+c||0;var f,g,h={};for(g in b)b[x](g)&&Z(g)!=g&&Z(g)+"%"!=g&&(f=!0,h[g]=b[g]);return f?(d&&(h.easing=d),e&&(h.callback=e),new p({100:h},c)):new p(b,c)},Xb.animate=function(b,c,d,e){var f=this;if(f.removed)return e&&e.call(f),f;var g=b instanceof p?b:a.animation(b,c,d,e);return q(g,f,g.percents[0],null,f.attr()),f},Xb.setTime=function(a,b){return a&&null!=b&&this.status(a,N(b,a.ms)/a.ms),this},Xb.status=function(a,b){var c,d,e=[],f=0;if(null!=b)return q(a,this,-1,N(b,1)),this;for(c=fc.length;c>f;f++)if(d=fc[f],d.el.id==this.id&&(!a||d.anim==a)){if(a)return d.status;e.push({anim:d.anim,status:d.status})}return a?0:e},Xb.pause=function(a){for(var b=0;b<fc.length;b++)fc[b].el.id!=this.id||a&&fc[b].anim!=a||eve("raphael.anim.pause."+this.id,this,fc[b].anim)!==!1&&(fc[b].paused=!0);return this},Xb.resume=function(a){for(var b=0;b<fc.length;b++)if(fc[b].el.id==this.id&&(!a||fc[b].anim==a)){var c=fc[b];eve("raphael.anim.resume."+this.id,this,c.anim)!==!1&&(delete c.paused,this.status(c.anim,c.status))}return this},Xb.stop=function(a){for(var b=0;b<fc.length;b++)fc[b].el.id!=this.id||a&&fc[b].anim!=a||eve("raphael.anim.stop."+this.id,this,fc[b].anim)!==!1&&fc.splice(b--,1);return this},eve.on("raphael.remove",r),eve.on("raphael.clear",r),Xb.toString=function(){return"Rapha\xebl\u2019s object"};var jc=function(a){if(this.items=[],this.length=0,this.type="set",a)for(var b=0,c=a.length;c>b;b++)!a[b]||a[b].constructor!=Xb.constructor&&a[b].constructor!=jc||(this[this.items.length]=this.items[this.items.length]=a[b],this.length++)},kc=jc.prototype;kc.push=function(){for(var a,b,c=0,d=arguments.length;d>c;c++)a=arguments[c],!a||a.constructor!=Xb.constructor&&a.constructor!=jc||(b=this.items.length,this[b]=this.items[b]=a,this.length++);return this},kc.pop=function(){return this.length&&delete this[this.length--],this.items.pop()},kc.forEach=function(a,b){for(var c=0,d=this.items.length;d>c;c++)if(a.call(b,this.items[c],c)===!1)return this;return this};for(var lc in Xb)Xb[x](lc)&&(kc[lc]=function(a){return function(){var b=arguments;return this.forEach(function(c){c[a][B](c,b)})}}(lc));kc.attr=function(b,c){if(b&&a.is(b,T)&&a.is(b[0],"object"))for(var d=0,e=b.length;e>d;d++)this.items[d].attr(b[d]);else for(var f=0,g=this.items.length;g>f;f++)this.items[f].attr(b,c);return this},kc.clear=function(){for(;this.length;)this.pop()},kc.splice=function(a,b){a=0>a?M(this.length+a,0):a,b=M(0,N(this.length-a,b));var c,d=[],e=[],f=[];for(c=2;c<arguments.length;c++)f.push(arguments[c]);for(c=0;b>c;c++)e.push(this[a+c]);for(;c<this.length-a;c++)d.push(this[a+c]);var g=f.length;for(c=0;c<g+d.length;c++)this.items[a+c]=this[a+c]=g>c?f[c]:d[c-g];for(c=this.items.length=this.length-=b-g;this[c];)delete this[c++];return new jc(e)},kc.exclude=function(a){for(var b=0,c=this.length;c>b;b++)if(this[b]==a)return this.splice(b,1),!0},kc.animate=function(b,c,d,e){(a.is(d,"function")||!d)&&(e=d||null);var f,g,h=this.items.length,i=h,j=this;if(!h)return this;e&&(g=function(){!--h&&e.call(j)}),d=a.is(d,S)?d:g;var k=a.animation(b,c,d,g);for(f=this.items[--i].animate(k);i--;)this.items[i]&&!this.items[i].removed&&this.items[i].animateWith(f,k,k);return this},kc.insertAfter=function(a){for(var b=this.items.length;b--;)this.items[b].insertAfter(a);return this},kc.getBBox=function(){for(var a=[],b=[],c=[],d=[],e=this.items.length;e--;)if(!this.items[e].removed){var f=this.items[e].getBBox();a.push(f.x),b.push(f.y),c.push(f.x+f.width),d.push(f.y+f.height)}return a=N[B](0,a),b=N[B](0,b),c=M[B](0,c),d=M[B](0,d),{x:a,y:b,x2:c,y2:d,width:c-a,height:d-b}},kc.clone=function(a){a=new jc;for(var b=0,c=this.items.length;c>b;b++)a.push(this.items[b].clone());return a},kc.toString=function(){return"Rapha\xebl\u2018s set"},a.registerFont=function(a){if(!a.face)return a;this.fonts=this.fonts||{};var b={w:a.w,face:{},glyphs:{}},c=a.face["font-family"];for(var d in a.face)a.face[x](d)&&(b.face[d]=a.face[d]);if(this.fonts[c]?this.fonts[c].push(b):this.fonts[c]=[b],!a.svg){b.face["units-per-em"]=$(a.face["units-per-em"],10);for(var e in a.glyphs)if(a.glyphs[x](e)){var f=a.glyphs[e];if(b.glyphs[e]={w:f.w,k:{},d:f.d&&"M"+f.d.replace(/[mlcxtrv]/g,function(a){return{l:"L",c:"C",x:"z",t:"m",r:"l",v:"c"}[a]||"M"})+"z"},f.k)for(var g in f.k)f[x](g)&&(b.glyphs[e].k[g]=f.k[g])}}return a},t.getFont=function(b,c,d,e){if(e=e||"normal",d=d||"normal",c=+c||{normal:400,bold:700,lighter:300,bolder:800}[c]||400,a.fonts){var f=a.fonts[b];if(!f){var g=new RegExp("(^|\\s)"+b.replace(/[^\w\d\s+!~.:_-]/g,E)+"(\\s|$)","i");for(var h in a.fonts)if(a.fonts[x](h)&&g.test(h)){f=a.fonts[h];break}}var i;if(f)for(var j=0,k=f.length;k>j&&(i=f[j],i.face["font-weight"]!=c||i.face["font-style"]!=d&&i.face["font-style"]||i.face["font-stretch"]!=e);j++);return i}},t.print=function(b,c,d,e,f,g,h){g=g||"middle",h=M(N(h||0,1),-1);var i,j=G(d)[H](E),k=0,l=0,m=E;if(a.is(e,d)&&(e=this.getFont(e)),e){i=(f||16)/e.face["units-per-em"];for(var n=e.face.bbox[H](u),o=+n[0],p=n[3]-n[1],q=0,r=+n[1]+("baseline"==g?p+ +e.face.descent:p/2),s=0,t=j.length;t>s;s++){if("\n"==j[s])k=0,w=0,l=0,q+=p;else{var v=l&&e.glyphs[j[s-1]]||{},w=e.glyphs[j[s]];k+=l?(v.w||e.w)+(v.k&&v.k[j[s]]||0)+e.w*h:0,l=1}w&&w.d&&(m+=a.transformPath(w.d,["t",k*i,q*i,"s",i,i,o,r,"t",(b-o)/i,(c-r)/i]))}}return this.path(m).attr({fill:"#000",stroke:"none"})},t.add=function(b){if(a.is(b,"array"))for(var c,d=this.set(),e=0,f=b.length;f>e;e++)c=b[e]||{},v[x](c.type)&&d.push(this[c.type]().attr(c));return d},a.format=function(b,c){var d=a.is(c,T)?[0][C](c):arguments;return b&&a.is(b,S)&&d.length-1&&(b=b.replace(w,function(a,b){return null==d[++b]?E:d[b]})),b||E},a.fullfill=function(){var a=/\{([^\}]+)\}/g,b=/(?:(?:^|\.)(.+?)(?=\[|\.|$|\()|\[('|")(.+?)\2\])(\(\))?/g,c=function(a,c,d){var e=d;return c.replace(b,function(a,b,c,d,f){b=b||d,e&&(b in e&&(e=e[b]),"function"==typeof e&&f&&(e=e()))}),e=(null==e||e==d?a:e)+""};return function(b,d){return String(b).replace(a,function(a,b){return c(a,b,d)})}}(),a.ninja=function(){return z.was?y.win.Raphael=z.is:delete Raphael,a},a.st=kc,function(b,c,d){function e(){/in/.test(b.readyState)?setTimeout(e,9):a.eve("raphael.DOMload")}null==b.readyState&&b.addEventListener&&(b.addEventListener(c,d=function(){b.removeEventListener(c,d,!1),b.readyState="complete"},!1),b.readyState="loading"),e()}(document,"DOMContentLoaded"),z.was?y.win.Raphael=a:Raphael=a,eve.on("raphael.DOMload",function(){s=!0})}(),window.Raphael&&window.Raphael.svg&&function(a){var b="hasOwnProperty",c=String,d=parseFloat,e=parseInt,f=Math,g=f.max,h=f.abs,i=f.pow,j=/[, ]+/,k=a.eve,l="",m=" ",n="http://www.w3.org/1999/xlink",o={block:"M5,0 0,2.5 5,5z",classic:"M5,0 0,2.5 5,5 3.5,3 3.5,2z",diamond:"M2.5,0 5,2.5 2.5,5 0,2.5z",open:"M6,1 1,3.5 6,6",oval:"M2.5,0A2.5,2.5,0,0,1,2.5,5 2.5,2.5,0,0,1,2.5,0z"},p={};a.toString=function(){return"Your browser supports SVG.\nYou are running Rapha\xebl "+this.version};var q=function(d,e){if(e){"string"==typeof d&&(d=q(d));for(var f in e)e[b](f)&&("xlink:"==f.substring(0,6)?d.setAttributeNS(n,f.substring(6),c(e[f])):d.setAttribute(f,c(e[f])))}else d=a._g.doc.createElementNS("http://www.w3.org/2000/svg",d),d.style&&(d.style.webkitTapHighlightColor="rgba(0,0,0,0)");return d},r=function(b,e){var j="linear",k=b.id+e,m=.5,n=.5,o=b.node,p=b.paper,r=o.style,s=a._g.doc.getElementById(k);if(!s){if(e=c(e).replace(a._radial_gradient,function(a,b,c){if(j="radial",b&&c){m=d(b),n=d(c);var e=2*(n>.5)-1;i(m-.5,2)+i(n-.5,2)>.25&&(n=f.sqrt(.25-i(m-.5,2))*e+.5)&&.5!=n&&(n=n.toFixed(5)-1e-5*e)}return l}),e=e.split(/\s*\-\s*/),"linear"==j){var t=e.shift();if(t=-d(t),isNaN(t))return null;var u=[0,0,f.cos(a.rad(t)),f.sin(a.rad(t))],v=1/(g(h(u[2]),h(u[3]))||1);u[2]*=v,u[3]*=v,u[2]<0&&(u[0]=-u[2],u[2]=0),u[3]<0&&(u[1]=-u[3],u[3]=0)}var w=a._parseDots(e);if(!w)return null;if(k=k.replace(/[\(\)\s,\xb0#]/g,"_"),b.gradient&&k!=b.gradient.id&&(p.defs.removeChild(b.gradient),delete b.gradient),!b.gradient){s=q(j+"Gradient",{id:k}),b.gradient=s,q(s,"radial"==j?{fx:m,fy:n}:{x1:u[0],y1:u[1],x2:u[2],y2:u[3],gradientTransform:b.matrix.invert()}),p.defs.appendChild(s);for(var x=0,y=w.length;y>x;x++)s.appendChild(q("stop",{offset:w[x].offset?w[x].offset:x?"100%":"0%","stop-color":w[x].color||"#fff"}))}}return q(o,{fill:"url(#"+k+")",opacity:1,"fill-opacity":1}),r.fill=l,r.opacity=1,r.fillOpacity=1,1},s=function(a){var b=a.getBBox(1);q(a.pattern,{patternTransform:a.matrix.invert()+" translate("+b.x+","+b.y+")"})},t=function(d,e,f){if("path"==d.type){for(var g,h,i,j,k,m=c(e).toLowerCase().split("-"),n=d.paper,r=f?"end":"start",s=d.node,t=d.attrs,u=t["stroke-width"],v=m.length,w="classic",x=3,y=3,z=5;v--;)switch(m[v]){case"block":case"classic":case"oval":case"diamond":case"open":case"none":w=m[v];break;case"wide":y=5;break;case"narrow":y=2;break;case"long":x=5;break;case"short":x=2}if("open"==w?(x+=2,y+=2,z+=2,i=1,j=f?4:1,k={fill:"none",stroke:t.stroke}):(j=i=x/2,k={fill:t.stroke,stroke:"none"}),d._.arrows?f?(d._.arrows.endPath&&p[d._.arrows.endPath]--,d._.arrows.endMarker&&p[d._.arrows.endMarker]--):(d._.arrows.startPath&&p[d._.arrows.startPath]--,d._.arrows.startMarker&&p[d._.arrows.startMarker]--):d._.arrows={},"none"!=w){var A="raphael-marker-"+w,B="raphael-marker-"+r+w+x+y;a._g.doc.getElementById(A)?p[A]++:(n.defs.appendChild(q(q("path"),{"stroke-linecap":"round",d:o[w],id:A})),p[A]=1);var C,D=a._g.doc.getElementById(B);D?(p[B]++,C=D.getElementsByTagName("use")[0]):(D=q(q("marker"),{id:B,markerHeight:y,markerWidth:x,orient:"auto",refX:j,refY:y/2}),C=q(q("use"),{"xlink:href":"#"+A,transform:(f?"rotate(180 "+x/2+" "+y/2+") ":l)+"scale("+x/z+","+y/z+")","stroke-width":(1/((x/z+y/z)/2)).toFixed(4)}),D.appendChild(C),n.defs.appendChild(D),p[B]=1),q(C,k);var E=i*("diamond"!=w&&"oval"!=w);f?(g=d._.arrows.startdx*u||0,h=a.getTotalLength(t.path)-E*u):(g=E*u,h=a.getTotalLength(t.path)-(d._.arrows.enddx*u||0)),k={},k["marker-"+r]="url(#"+B+")",(h||g)&&(k.d=Raphael.getSubpath(t.path,g,h)),q(s,k),d._.arrows[r+"Path"]=A,d._.arrows[r+"Marker"]=B,d._.arrows[r+"dx"]=E,d._.arrows[r+"Type"]=w,d._.arrows[r+"String"]=e}else f?(g=d._.arrows.startdx*u||0,h=a.getTotalLength(t.path)-g):(g=0,h=a.getTotalLength(t.path)-(d._.arrows.enddx*u||0)),d._.arrows[r+"Path"]&&q(s,{d:Raphael.getSubpath(t.path,g,h)}),delete d._.arrows[r+"Path"],delete d._.arrows[r+"Marker"],delete d._.arrows[r+"dx"],delete d._.arrows[r+"Type"],delete d._.arrows[r+"String"];for(k in p)if(p[b](k)&&!p[k]){var F=a._g.doc.getElementById(k);F&&F.parentNode.removeChild(F)}}},u={"":[0],none:[0],"-":[3,1],".":[1,1],"-.":[3,1,1,1],"-..":[3,1,1,1,1,1],". ":[1,3],"- ":[4,3],"--":[8,3],"- .":[4,3,1,3],"--.":[8,3,1,3],"--..":[8,3,1,3,1,3]},v=function(a,b,d){if(b=u[c(b).toLowerCase()]){for(var e=a.attrs["stroke-width"]||"1",f={round:e,square:e,butt:0}[a.attrs["stroke-linecap"]||d["stroke-linecap"]]||0,g=[],h=b.length;h--;)g[h]=b[h]*e+(h%2?1:-1)*f;q(a.node,{"stroke-dasharray":g.join(",")})}},w=function(d,f){var i=d.node,k=d.attrs,m=i.style.visibility;i.style.visibility="hidden";for(var o in f)if(f[b](o)){if(!a._availableAttrs[b](o))continue;var p=f[o];switch(k[o]=p,o){case"blur":d.blur(p);break;case"href":case"title":case"target":var u=i.parentNode;if("a"!=u.tagName.toLowerCase()){var w=q("a");u.insertBefore(w,i),w.appendChild(i),u=w}"target"==o?u.setAttributeNS(n,"show","blank"==p?"new":p):u.setAttributeNS(n,o,p);break;case"cursor":i.style.cursor=p;break;case"transform":d.transform(p);break;case"arrow-start":t(d,p);break;case"arrow-end":t(d,p,1);break;case"clip-rect":var x=c(p).split(j);if(4==x.length){d.clip&&d.clip.parentNode.parentNode.removeChild(d.clip.parentNode);var z=q("clipPath"),A=q("rect");z.id=a.createUUID(),q(A,{x:x[0],y:x[1],width:x[2],height:x[3]}),z.appendChild(A),d.paper.defs.appendChild(z),q(i,{"clip-path":"url(#"+z.id+")"}),d.clip=A}if(!p){var B=i.getAttribute("clip-path");if(B){var C=a._g.doc.getElementById(B.replace(/(^url\(#|\)$)/g,l));C&&C.parentNode.removeChild(C),q(i,{"clip-path":l}),delete d.clip}}break;case"path":"path"==d.type&&(q(i,{d:p?k.path=a._pathToAbsolute(p):"M0,0"}),d._.dirty=1,d._.arrows&&("startString"in d._.arrows&&t(d,d._.arrows.startString),"endString"in d._.arrows&&t(d,d._.arrows.endString,1)));break;case"width":if(i.setAttribute(o,p),d._.dirty=1,!k.fx)break;o="x",p=k.x;case"x":k.fx&&(p=-k.x-(k.width||0));case"rx":if("rx"==o&&"rect"==d.type)break;case"cx":i.setAttribute(o,p),d.pattern&&s(d),d._.dirty=1;break;case"height":if(i.setAttribute(o,p),d._.dirty=1,!k.fy)break;o="y",p=k.y;case"y":k.fy&&(p=-k.y-(k.height||0));case"ry":if("ry"==o&&"rect"==d.type)break;case"cy":i.setAttribute(o,p),d.pattern&&s(d),d._.dirty=1;break;case"r":"rect"==d.type?q(i,{rx:p,ry:p}):i.setAttribute(o,p),d._.dirty=1;break;case"src":"image"==d.type&&i.setAttributeNS(n,"href",p);break;case"stroke-width":(1!=d._.sx||1!=d._.sy)&&(p/=g(h(d._.sx),h(d._.sy))||1),d.paper._vbSize&&(p*=d.paper._vbSize),i.setAttribute(o,p),k["stroke-dasharray"]&&v(d,k["stroke-dasharray"],f),d._.arrows&&("startString"in d._.arrows&&t(d,d._.arrows.startString),"endString"in d._.arrows&&t(d,d._.arrows.endString,1));break;case"stroke-dasharray":v(d,p,f);break;case"fill":var D=c(p).match(a._ISURL);if(D){z=q("pattern");var E=q("image");z.id=a.createUUID(),q(z,{x:0,y:0,patternUnits:"userSpaceOnUse",height:1,width:1}),q(E,{x:0,y:0,"xlink:href":D[1]}),z.appendChild(E),function(b){a._preload(D[1],function(){var a=this.offsetWidth,c=this.offsetHeight;q(b,{width:a,height:c}),q(E,{width:a,height:c}),d.paper.safari()})}(z),d.paper.defs.appendChild(z),q(i,{fill:"url(#"+z.id+")"}),d.pattern=z,d.pattern&&s(d);break}var F=a.getRGB(p);if(F.error){if(("circle"==d.type||"ellipse"==d.type||"r"!=c(p).charAt())&&r(d,p)){if("opacity"in k||"fill-opacity"in k){var G=a._g.doc.getElementById(i.getAttribute("fill").replace(/^url\(#|\)$/g,l));if(G){var H=G.getElementsByTagName("stop");q(H[H.length-1],{"stop-opacity":("opacity"in k?k.opacity:1)*("fill-opacity"in k?k["fill-opacity"]:1)})}}k.gradient=p,k.fill="none";break}}else delete f.gradient,delete k.gradient,!a.is(k.opacity,"undefined")&&a.is(f.opacity,"undefined")&&q(i,{opacity:k.opacity}),!a.is(k["fill-opacity"],"undefined")&&a.is(f["fill-opacity"],"undefined")&&q(i,{"fill-opacity":k["fill-opacity"]}); F[b]("opacity")&&q(i,{"fill-opacity":F.opacity>1?F.opacity/100:F.opacity});case"stroke":F=a.getRGB(p),i.setAttribute(o,F.hex),"stroke"==o&&F[b]("opacity")&&q(i,{"stroke-opacity":F.opacity>1?F.opacity/100:F.opacity}),"stroke"==o&&d._.arrows&&("startString"in d._.arrows&&t(d,d._.arrows.startString),"endString"in d._.arrows&&t(d,d._.arrows.endString,1));break;case"gradient":("circle"==d.type||"ellipse"==d.type||"r"!=c(p).charAt())&&r(d,p);break;case"opacity":k.gradient&&!k[b]("stroke-opacity")&&q(i,{"stroke-opacity":p>1?p/100:p});case"fill-opacity":if(k.gradient){G=a._g.doc.getElementById(i.getAttribute("fill").replace(/^url\(#|\)$/g,l)),G&&(H=G.getElementsByTagName("stop"),q(H[H.length-1],{"stop-opacity":p}));break}default:"font-size"==o&&(p=e(p,10)+"px");var I=o.replace(/(\-.)/g,function(a){return a.substring(1).toUpperCase()});i.style[I]=p,d._.dirty=1,i.setAttribute(o,p)}}y(d,f),i.style.visibility=m},x=1.2,y=function(d,f){if("text"==d.type&&(f[b]("text")||f[b]("font")||f[b]("font-size")||f[b]("x")||f[b]("y"))){var g=d.attrs,h=d.node,i=h.firstChild?e(a._g.doc.defaultView.getComputedStyle(h.firstChild,l).getPropertyValue("font-size"),10):10;if(f[b]("text")){for(g.text=f.text;h.firstChild;)h.removeChild(h.firstChild);for(var j,k=c(f.text).split("\n"),m=[],n=0,o=k.length;o>n;n++)j=q("tspan"),n&&q(j,{dy:i*x,x:g.x}),j.appendChild(a._g.doc.createTextNode(k[n])),h.appendChild(j),m[n]=j}else for(m=h.getElementsByTagName("tspan"),n=0,o=m.length;o>n;n++)n?q(m[n],{dy:i*x,x:g.x}):q(m[0],{dy:0});q(h,{x:g.x,y:g.y}),d._.dirty=1;var p=d._getBBox(),r=g.y-(p.y+p.height/2);r&&a.is(r,"finite")&&q(m[0],{dy:r})}},z=function(b,c){this[0]=this.node=b,b.raphael=!0,this.id=a._oid++,b.raphaelid=this.id,this.matrix=a.matrix(),this.realPath=null,this.paper=c,this.attrs=this.attrs||{},this._={transform:[],sx:1,sy:1,deg:0,dx:0,dy:0,dirty:1},!c.bottom&&(c.bottom=this),this.prev=c.top,c.top&&(c.top.next=this),c.top=this,this.next=null},A=a.el;z.prototype=A,A.constructor=z,a._engine.path=function(a,b){var c=q("path");b.canvas&&b.canvas.appendChild(c);var d=new z(c,b);return d.type="path",w(d,{fill:"none",stroke:"#000",path:a}),d},A.rotate=function(a,b,e){if(this.removed)return this;if(a=c(a).split(j),a.length-1&&(b=d(a[1]),e=d(a[2])),a=d(a[0]),null==e&&(b=e),null==b||null==e){var f=this.getBBox(1);b=f.x+f.width/2,e=f.y+f.height/2}return this.transform(this._.transform.concat([["r",a,b,e]])),this},A.scale=function(a,b,e,f){if(this.removed)return this;if(a=c(a).split(j),a.length-1&&(b=d(a[1]),e=d(a[2]),f=d(a[3])),a=d(a[0]),null==b&&(b=a),null==f&&(e=f),null==e||null==f)var g=this.getBBox(1);return e=null==e?g.x+g.width/2:e,f=null==f?g.y+g.height/2:f,this.transform(this._.transform.concat([["s",a,b,e,f]])),this},A.translate=function(a,b){return this.removed?this:(a=c(a).split(j),a.length-1&&(b=d(a[1])),a=d(a[0])||0,b=+b||0,this.transform(this._.transform.concat([["t",a,b]])),this)},A.transform=function(c){var d=this._;if(null==c)return d.transform;if(a._extractTransform(this,c),this.clip&&q(this.clip,{transform:this.matrix.invert()}),this.pattern&&s(this),this.node&&q(this.node,{transform:this.matrix}),1!=d.sx||1!=d.sy){var e=this.attrs[b]("stroke-width")?this.attrs["stroke-width"]:1;this.attr({"stroke-width":e})}return this},A.hide=function(){return!this.removed&&this.paper.safari(this.node.style.display="none"),this},A.show=function(){return!this.removed&&this.paper.safari(this.node.style.display=""),this},A.remove=function(){if(!this.removed&&this.node.parentNode){var b=this.paper;b.__set__&&b.__set__.exclude(this),k.unbind("raphael.*.*."+this.id),this.gradient&&b.defs.removeChild(this.gradient),a._tear(this,b),"a"==this.node.parentNode.tagName.toLowerCase()?this.node.parentNode.parentNode.removeChild(this.node.parentNode):this.node.parentNode.removeChild(this.node);for(var c in this)this[c]="function"==typeof this[c]?a._removedFactory(c):null;this.removed=!0}},A._getBBox=function(){if("none"==this.node.style.display){this.show();var a=!0}var b={};try{b=this.node.getBBox()}catch(c){}finally{b=b||{}}return a&&this.hide(),b},A.attr=function(c,d){if(this.removed)return this;if(null==c){var e={};for(var f in this.attrs)this.attrs[b](f)&&(e[f]=this.attrs[f]);return e.gradient&&"none"==e.fill&&(e.fill=e.gradient)&&delete e.gradient,e.transform=this._.transform,e}if(null==d&&a.is(c,"string")){if("fill"==c&&"none"==this.attrs.fill&&this.attrs.gradient)return this.attrs.gradient;if("transform"==c)return this._.transform;for(var g=c.split(j),h={},i=0,l=g.length;l>i;i++)c=g[i],h[c]=c in this.attrs?this.attrs[c]:a.is(this.paper.customAttributes[c],"function")?this.paper.customAttributes[c].def:a._availableAttrs[c];return l-1?h:h[g[0]]}if(null==d&&a.is(c,"array")){for(h={},i=0,l=c.length;l>i;i++)h[c[i]]=this.attr(c[i]);return h}if(null!=d){var m={};m[c]=d}else null!=c&&a.is(c,"object")&&(m=c);for(var n in m)k("raphael.attr."+n+"."+this.id,this,m[n]);for(n in this.paper.customAttributes)if(this.paper.customAttributes[b](n)&&m[b](n)&&a.is(this.paper.customAttributes[n],"function")){var o=this.paper.customAttributes[n].apply(this,[].concat(m[n]));this.attrs[n]=m[n];for(var p in o)o[b](p)&&(m[p]=o[p])}return w(this,m),this},A.toFront=function(){if(this.removed)return this;"a"==this.node.parentNode.tagName.toLowerCase()?this.node.parentNode.parentNode.appendChild(this.node.parentNode):this.node.parentNode.appendChild(this.node);var b=this.paper;return b.top!=this&&a._tofront(this,b),this},A.toBack=function(){if(this.removed)return this;var b=this.node.parentNode;"a"==b.tagName.toLowerCase()?b.parentNode.insertBefore(this.node.parentNode,this.node.parentNode.parentNode.firstChild):b.firstChild!=this.node&&b.insertBefore(this.node,this.node.parentNode.firstChild),a._toback(this,this.paper);this.paper;return this},A.insertAfter=function(b){if(this.removed)return this;var c=b.node||b[b.length-1].node;return c.nextSibling?c.parentNode.insertBefore(this.node,c.nextSibling):c.parentNode.appendChild(this.node),a._insertafter(this,b,this.paper),this},A.insertBefore=function(b){if(this.removed)return this;var c=b.node||b[0].node;return c.parentNode.insertBefore(this.node,c),a._insertbefore(this,b,this.paper),this},A.blur=function(b){var c=this;if(0!==+b){var d=q("filter"),e=q("feGaussianBlur");c.attrs.blur=b,d.id=a.createUUID(),q(e,{stdDeviation:+b||1.5}),d.appendChild(e),c.paper.defs.appendChild(d),c._blur=d,q(c.node,{filter:"url(#"+d.id+")"})}else c._blur&&(c._blur.parentNode.removeChild(c._blur),delete c._blur,delete c.attrs.blur),c.node.removeAttribute("filter")},a._engine.circle=function(a,b,c,d){var e=q("circle");a.canvas&&a.canvas.appendChild(e);var f=new z(e,a);return f.attrs={cx:b,cy:c,r:d,fill:"none",stroke:"#000"},f.type="circle",q(e,f.attrs),f},a._engine.rect=function(a,b,c,d,e,f){var g=q("rect");a.canvas&&a.canvas.appendChild(g);var h=new z(g,a);return h.attrs={x:b,y:c,width:d,height:e,r:f||0,rx:f||0,ry:f||0,fill:"none",stroke:"#000"},h.type="rect",q(g,h.attrs),h},a._engine.ellipse=function(a,b,c,d,e){var f=q("ellipse");a.canvas&&a.canvas.appendChild(f);var g=new z(f,a);return g.attrs={cx:b,cy:c,rx:d,ry:e,fill:"none",stroke:"#000"},g.type="ellipse",q(f,g.attrs),g},a._engine.image=function(a,b,c,d,e,f){var g=q("image");q(g,{x:c,y:d,width:e,height:f,preserveAspectRatio:"none"}),g.setAttributeNS(n,"href",b),a.canvas&&a.canvas.appendChild(g);var h=new z(g,a);return h.attrs={x:c,y:d,width:e,height:f,src:b},h.type="image",h},a._engine.text=function(b,c,d,e){var f=q("text");b.canvas&&b.canvas.appendChild(f);var g=new z(f,b);return g.attrs={x:c,y:d,"text-anchor":"middle",text:e,font:a._availableAttrs.font,stroke:"none",fill:"#000"},g.type="text",w(g,g.attrs),g},a._engine.setSize=function(a,b){return this.width=a||this.width,this.height=b||this.height,this.canvas.setAttribute("width",this.width),this.canvas.setAttribute("height",this.height),this._viewBox&&this.setViewBox.apply(this,this._viewBox),this},a._engine.create=function(){var b=a._getContainer.apply(0,arguments),c=b&&b.container,d=b.x,e=b.y,f=b.width,g=b.height;if(!c)throw new Error("SVG container not found.");var h,i=q("svg"),j="overflow:hidden;";return d=d||0,e=e||0,f=f||512,g=g||342,q(i,{height:g,version:1.1,width:f,xmlns:"http://www.w3.org/2000/svg"}),1==c?(i.style.cssText=j+"position:absolute;left:"+d+"px;top:"+e+"px",a._g.doc.body.appendChild(i),h=1):(i.style.cssText=j+"position:relative",c.firstChild?c.insertBefore(i,c.firstChild):c.appendChild(i)),c=new a._Paper,c.width=f,c.height=g,c.canvas=i,c.clear(),c._left=c._top=0,h&&(c.renderfix=function(){}),c.renderfix(),c},a._engine.setViewBox=function(a,b,c,d,e){k("raphael.setViewBox",this,this._viewBox,[a,b,c,d,e]);var f,h,i=g(c/this.width,d/this.height),j=this.top,l=e?"meet":"xMinYMin";for(null==a?(this._vbSize&&(i=1),delete this._vbSize,f="0 0 "+this.width+m+this.height):(this._vbSize=i,f=a+m+b+m+c+m+d),q(this.canvas,{viewBox:f,preserveAspectRatio:l});i&&j;)h="stroke-width"in j.attrs?j.attrs["stroke-width"]:1,j.attr({"stroke-width":h}),j._.dirty=1,j._.dirtyT=1,j=j.prev;return this._viewBox=[a,b,c,d,!!e],this},a.prototype.renderfix=function(){var a,b=this.canvas,c=b.style;try{a=b.getScreenCTM()||b.createSVGMatrix()}catch(d){a=b.createSVGMatrix()}var e=-a.e%1,f=-a.f%1;(e||f)&&(e&&(this._left=(this._left+e)%1,c.left=this._left+"px"),f&&(this._top=(this._top+f)%1,c.top=this._top+"px"))},a.prototype.clear=function(){a.eve("raphael.clear",this);for(var b=this.canvas;b.firstChild;)b.removeChild(b.firstChild);this.bottom=this.top=null,(this.desc=q("desc")).appendChild(a._g.doc.createTextNode("Created with Rapha\xebl "+a.version)),b.appendChild(this.desc),b.appendChild(this.defs=q("defs"))},a.prototype.remove=function(){k("raphael.remove",this),this.canvas.parentNode&&this.canvas.parentNode.removeChild(this.canvas);for(var b in this)this[b]="function"==typeof this[b]?a._removedFactory(b):null};var B=a.st;for(var C in A)A[b](C)&&!B[b](C)&&(B[C]=function(a){return function(){var b=arguments;return this.forEach(function(c){c[a].apply(c,b)})}}(C))}(window.Raphael),window.Raphael&&window.Raphael.vml&&function(a){var b="hasOwnProperty",c=String,d=parseFloat,e=Math,f=e.round,g=e.max,h=e.min,i=e.abs,j="fill",k=/[, ]+/,l=a.eve,m=" progid:DXImageTransform.Microsoft",n=" ",o="",p={M:"m",L:"l",C:"c",Z:"x",m:"t",l:"r",c:"v",z:"x"},q=/([clmz]),?([^clmz]*)/gi,r=/ progid:\S+Blur\([^\)]+\)/g,s=/-?[^,\s-]+/g,t="position:absolute;left:0;top:0;width:1px;height:1px",u=21600,v={path:1,rect:1,image:1},w={circle:1,ellipse:1},x=function(b){var d=/[ahqstv]/gi,e=a._pathToAbsolute;if(c(b).match(d)&&(e=a._path2curve),d=/[clmz]/g,e==a._pathToAbsolute&&!c(b).match(d)){var g=c(b).replace(q,function(a,b,c){var d=[],e="m"==b.toLowerCase(),g=p[b];return c.replace(s,function(a){e&&2==d.length&&(g+=d+p["m"==b?"l":"L"],d=[]),d.push(f(a*u))}),g+d});return g}var h,i,j=e(b);g=[];for(var k=0,l=j.length;l>k;k++){h=j[k],i=j[k][0].toLowerCase(),"z"==i&&(i="x");for(var m=1,r=h.length;r>m;m++)i+=f(h[m]*u)+(m!=r-1?",":o);g.push(i)}return g.join(n)},y=function(b,c,d){var e=a.matrix();return e.rotate(-b,.5,.5),{dx:e.x(c,d),dy:e.y(c,d)}},z=function(a,b,c,d,e,f){var g=a._,h=a.matrix,k=g.fillpos,l=a.node,m=l.style,o=1,p="",q=u/b,r=u/c;if(m.visibility="hidden",b&&c){if(l.coordsize=i(q)+n+i(r),m.rotation=f*(0>b*c?-1:1),f){var s=y(f,d,e);d=s.dx,e=s.dy}if(0>b&&(p+="x"),0>c&&(p+=" y")&&(o=-1),m.flip=p,l.coordorigin=d*-q+n+e*-r,k||g.fillsize){var t=l.getElementsByTagName(j);t=t&&t[0],l.removeChild(t),k&&(s=y(f,h.x(k[0],k[1]),h.y(k[0],k[1])),t.position=s.dx*o+n+s.dy*o),g.fillsize&&(t.size=g.fillsize[0]*i(b)+n+g.fillsize[1]*i(c)),l.appendChild(t)}m.visibility="visible"}};a.toString=function(){return"Your browser doesn\u2019t support SVG. Falling down to VML.\nYou are running Rapha\xebl "+this.version};var A=function(a,b,d){for(var e=c(b).toLowerCase().split("-"),f=d?"end":"start",g=e.length,h="classic",i="medium",j="medium";g--;)switch(e[g]){case"block":case"classic":case"oval":case"diamond":case"open":case"none":h=e[g];break;case"wide":case"narrow":j=e[g];break;case"long":case"short":i=e[g]}var k=a.node.getElementsByTagName("stroke")[0];k[f+"arrow"]=h,k[f+"arrowlength"]=i,k[f+"arrowwidth"]=j},B=function(e,i){e.attrs=e.attrs||{};var l=e.node,m=e.attrs,p=l.style,q=v[e.type]&&(i.x!=m.x||i.y!=m.y||i.width!=m.width||i.height!=m.height||i.cx!=m.cx||i.cy!=m.cy||i.rx!=m.rx||i.ry!=m.ry||i.r!=m.r),r=w[e.type]&&(m.cx!=i.cx||m.cy!=i.cy||m.r!=i.r||m.rx!=i.rx||m.ry!=i.ry),s=e;for(var t in i)i[b](t)&&(m[t]=i[t]);if(q&&(m.path=a._getPath[e.type](e),e._.dirty=1),i.href&&(l.href=i.href),i.title&&(l.title=i.title),i.target&&(l.target=i.target),i.cursor&&(p.cursor=i.cursor),"blur"in i&&e.blur(i.blur),(i.path&&"path"==e.type||q)&&(l.path=x(~c(m.path).toLowerCase().indexOf("r")?a._pathToAbsolute(m.path):m.path),"image"==e.type&&(e._.fillpos=[m.x,m.y],e._.fillsize=[m.width,m.height],z(e,1,1,0,0,0))),"transform"in i&&e.transform(i.transform),r){var y=+m.cx,B=+m.cy,D=+m.rx||+m.r||0,E=+m.ry||+m.r||0;l.path=a.format("ar{0},{1},{2},{3},{4},{1},{4},{1}x",f((y-D)*u),f((B-E)*u),f((y+D)*u),f((B+E)*u),f(y*u))}if("clip-rect"in i){var G=c(i["clip-rect"]).split(k);if(4==G.length){G[2]=+G[2]+ +G[0],G[3]=+G[3]+ +G[1];var H=l.clipRect||a._g.doc.createElement("div"),I=H.style;I.clip=a.format("rect({1}px {2}px {3}px {0}px)",G),l.clipRect||(I.position="absolute",I.top=0,I.left=0,I.width=e.paper.width+"px",I.height=e.paper.height+"px",l.parentNode.insertBefore(H,l),H.appendChild(l),l.clipRect=H)}i["clip-rect"]||l.clipRect&&(l.clipRect.style.clip="auto")}if(e.textpath){var J=e.textpath.style;i.font&&(J.font=i.font),i["font-family"]&&(J.fontFamily='"'+i["font-family"].split(",")[0].replace(/^['"]+|['"]+$/g,o)+'"'),i["font-size"]&&(J.fontSize=i["font-size"]),i["font-weight"]&&(J.fontWeight=i["font-weight"]),i["font-style"]&&(J.fontStyle=i["font-style"])}if("arrow-start"in i&&A(s,i["arrow-start"]),"arrow-end"in i&&A(s,i["arrow-end"],1),null!=i.opacity||null!=i["stroke-width"]||null!=i.fill||null!=i.src||null!=i.stroke||null!=i["stroke-width"]||null!=i["stroke-opacity"]||null!=i["fill-opacity"]||null!=i["stroke-dasharray"]||null!=i["stroke-miterlimit"]||null!=i["stroke-linejoin"]||null!=i["stroke-linecap"]){var K=l.getElementsByTagName(j),L=!1;if(K=K&&K[0],!K&&(L=K=F(j)),"image"==e.type&&i.src&&(K.src=i.src),i.fill&&(K.on=!0),(null==K.on||"none"==i.fill||null===i.fill)&&(K.on=!1),K.on&&i.fill){var M=c(i.fill).match(a._ISURL);if(M){K.parentNode==l&&l.removeChild(K),K.rotate=!0,K.src=M[1],K.type="tile";var N=e.getBBox(1);K.position=N.x+n+N.y,e._.fillpos=[N.x,N.y],a._preload(M[1],function(){e._.fillsize=[this.offsetWidth,this.offsetHeight]})}else K.color=a.getRGB(i.fill).hex,K.src=o,K.type="solid",a.getRGB(i.fill).error&&(s.type in{circle:1,ellipse:1}||"r"!=c(i.fill).charAt())&&C(s,i.fill,K)&&(m.fill="none",m.gradient=i.fill,K.rotate=!1)}if("fill-opacity"in i||"opacity"in i){var O=((+m["fill-opacity"]+1||2)-1)*((+m.opacity+1||2)-1)*((+a.getRGB(i.fill).o+1||2)-1);O=h(g(O,0),1),K.opacity=O,K.src&&(K.color="none")}l.appendChild(K);var P=l.getElementsByTagName("stroke")&&l.getElementsByTagName("stroke")[0],Q=!1;!P&&(Q=P=F("stroke")),(i.stroke&&"none"!=i.stroke||i["stroke-width"]||null!=i["stroke-opacity"]||i["stroke-dasharray"]||i["stroke-miterlimit"]||i["stroke-linejoin"]||i["stroke-linecap"])&&(P.on=!0),("none"==i.stroke||null===i.stroke||null==P.on||0==i.stroke||0==i["stroke-width"])&&(P.on=!1);var R=a.getRGB(i.stroke);P.on&&i.stroke&&(P.color=R.hex),O=((+m["stroke-opacity"]+1||2)-1)*((+m.opacity+1||2)-1)*((+R.o+1||2)-1);var S=.75*(d(i["stroke-width"])||1);if(O=h(g(O,0),1),null==i["stroke-width"]&&(S=m["stroke-width"]),i["stroke-width"]&&(P.weight=S),S&&1>S&&(O*=S)&&(P.weight=1),P.opacity=O,i["stroke-linejoin"]&&(P.joinstyle=i["stroke-linejoin"]||"miter"),P.miterlimit=i["stroke-miterlimit"]||8,i["stroke-linecap"]&&(P.endcap="butt"==i["stroke-linecap"]?"flat":"square"==i["stroke-linecap"]?"square":"round"),i["stroke-dasharray"]){var T={"-":"shortdash",".":"shortdot","-.":"shortdashdot","-..":"shortdashdotdot",". ":"dot","- ":"dash","--":"longdash","- .":"dashdot","--.":"longdashdot","--..":"longdashdotdot"};P.dashstyle=T[b](i["stroke-dasharray"])?T[i["stroke-dasharray"]]:o}Q&&l.appendChild(P)}if("text"==s.type){s.paper.canvas.style.display=o;var U=s.paper.span,V=100,W=m.font&&m.font.match(/\d+(?:\.\d*)?(?=px)/);p=U.style,m.font&&(p.font=m.font),m["font-family"]&&(p.fontFamily=m["font-family"]),m["font-weight"]&&(p.fontWeight=m["font-weight"]),m["font-style"]&&(p.fontStyle=m["font-style"]),W=d(m["font-size"]||W&&W[0])||10,p.fontSize=W*V+"px",s.textpath.string&&(U.innerHTML=c(s.textpath.string).replace(/</g,"&#60;").replace(/&/g,"&#38;").replace(/\n/g,"<br>"));var X=U.getBoundingClientRect();s.W=m.w=(X.right-X.left)/V,s.H=m.h=(X.bottom-X.top)/V,s.X=m.x,s.Y=m.y+s.H/2,("x"in i||"y"in i)&&(s.path.v=a.format("m{0},{1}l{2},{1}",f(m.x*u),f(m.y*u),f(m.x*u)+1));for(var Y=["x","y","text","font","font-family","font-weight","font-style","font-size"],Z=0,$=Y.length;$>Z;Z++)if(Y[Z]in i){s._.dirty=1;break}switch(m["text-anchor"]){case"start":s.textpath.style["v-text-align"]="left",s.bbx=s.W/2;break;case"end":s.textpath.style["v-text-align"]="right",s.bbx=-s.W/2;break;default:s.textpath.style["v-text-align"]="center",s.bbx=0}s.textpath.style["v-text-kern"]=!0}},C=function(b,f,g){b.attrs=b.attrs||{};var h=(b.attrs,Math.pow),i="linear",j=".5 .5";if(b.attrs.gradient=f,f=c(f).replace(a._radial_gradient,function(a,b,c){return i="radial",b&&c&&(b=d(b),c=d(c),h(b-.5,2)+h(c-.5,2)>.25&&(c=e.sqrt(.25-h(b-.5,2))*(2*(c>.5)-1)+.5),j=b+n+c),o}),f=f.split(/\s*\-\s*/),"linear"==i){var k=f.shift();if(k=-d(k),isNaN(k))return null}var l=a._parseDots(f);if(!l)return null;if(b=b.shape||b.node,l.length){b.removeChild(g),g.on=!0,g.method="none",g.color=l[0].color,g.color2=l[l.length-1].color;for(var m=[],p=0,q=l.length;q>p;p++)l[p].offset&&m.push(l[p].offset+n+l[p].color);g.colors=m.length?m.join():"0% "+g.color,"radial"==i?(g.type="gradientTitle",g.focus="100%",g.focussize="0 0",g.focusposition=j,g.angle=0):(g.type="gradient",g.angle=(270-k)%360),b.appendChild(g)}return 1},D=function(b,c){this[0]=this.node=b,b.raphael=!0,this.id=a._oid++,b.raphaelid=this.id,this.X=0,this.Y=0,this.attrs={},this.paper=c,this.matrix=a.matrix(),this._={transform:[],sx:1,sy:1,dx:0,dy:0,deg:0,dirty:1,dirtyT:1},!c.bottom&&(c.bottom=this),this.prev=c.top,c.top&&(c.top.next=this),c.top=this,this.next=null},E=a.el;D.prototype=E,E.constructor=D,E.transform=function(b){if(null==b)return this._.transform;var d,e=this.paper._viewBoxShift,f=e?"s"+[e.scale,e.scale]+"-1-1t"+[e.dx,e.dy]:o;e&&(d=b=c(b).replace(/\.{3}|\u2026/g,this._.transform||o)),a._extractTransform(this,f+b);var g,h=this.matrix.clone(),i=this.skew,j=this.node,k=~c(this.attrs.fill).indexOf("-"),l=!c(this.attrs.fill).indexOf("url(");if(h.translate(-.5,-.5),l||k||"image"==this.type)if(i.matrix="1 0 0 1",i.offset="0 0",g=h.split(),k&&g.noRotation||!g.isSimple){j.style.filter=h.toFilter();var m=this.getBBox(),p=this.getBBox(1),q=m.x-p.x,r=m.y-p.y;j.coordorigin=q*-u+n+r*-u,z(this,1,1,q,r,0)}else j.style.filter=o,z(this,g.scalex,g.scaley,g.dx,g.dy,g.rotate);else j.style.filter=o,i.matrix=c(h),i.offset=h.offset();return d&&(this._.transform=d),this},E.rotate=function(a,b,e){if(this.removed)return this;if(null!=a){if(a=c(a).split(k),a.length-1&&(b=d(a[1]),e=d(a[2])),a=d(a[0]),null==e&&(b=e),null==b||null==e){var f=this.getBBox(1);b=f.x+f.width/2,e=f.y+f.height/2}return this._.dirtyT=1,this.transform(this._.transform.concat([["r",a,b,e]])),this}},E.translate=function(a,b){return this.removed?this:(a=c(a).split(k),a.length-1&&(b=d(a[1])),a=d(a[0])||0,b=+b||0,this._.bbox&&(this._.bbox.x+=a,this._.bbox.y+=b),this.transform(this._.transform.concat([["t",a,b]])),this)},E.scale=function(a,b,e,f){if(this.removed)return this;if(a=c(a).split(k),a.length-1&&(b=d(a[1]),e=d(a[2]),f=d(a[3]),isNaN(e)&&(e=null),isNaN(f)&&(f=null)),a=d(a[0]),null==b&&(b=a),null==f&&(e=f),null==e||null==f)var g=this.getBBox(1);return e=null==e?g.x+g.width/2:e,f=null==f?g.y+g.height/2:f,this.transform(this._.transform.concat([["s",a,b,e,f]])),this._.dirtyT=1,this},E.hide=function(){return!this.removed&&(this.node.style.display="none"),this},E.show=function(){return!this.removed&&(this.node.style.display=o),this},E._getBBox=function(){return this.removed?{}:{x:this.X+(this.bbx||0)-this.W/2,y:this.Y-this.H,width:this.W,height:this.H}},E.remove=function(){if(!this.removed&&this.node.parentNode){this.paper.__set__&&this.paper.__set__.exclude(this),a.eve.unbind("raphael.*.*."+this.id),a._tear(this,this.paper),this.node.parentNode.removeChild(this.node),this.shape&&this.shape.parentNode.removeChild(this.shape);for(var b in this)this[b]="function"==typeof this[b]?a._removedFactory(b):null;this.removed=!0}},E.attr=function(c,d){if(this.removed)return this;if(null==c){var e={};for(var f in this.attrs)this.attrs[b](f)&&(e[f]=this.attrs[f]);return e.gradient&&"none"==e.fill&&(e.fill=e.gradient)&&delete e.gradient,e.transform=this._.transform,e}if(null==d&&a.is(c,"string")){if(c==j&&"none"==this.attrs.fill&&this.attrs.gradient)return this.attrs.gradient;for(var g=c.split(k),h={},i=0,m=g.length;m>i;i++)c=g[i],h[c]=c in this.attrs?this.attrs[c]:a.is(this.paper.customAttributes[c],"function")?this.paper.customAttributes[c].def:a._availableAttrs[c];return m-1?h:h[g[0]]}if(this.attrs&&null==d&&a.is(c,"array")){for(h={},i=0,m=c.length;m>i;i++)h[c[i]]=this.attr(c[i]);return h}var n;null!=d&&(n={},n[c]=d),null==d&&a.is(c,"object")&&(n=c);for(var o in n)l("raphael.attr."+o+"."+this.id,this,n[o]);if(n){for(o in this.paper.customAttributes)if(this.paper.customAttributes[b](o)&&n[b](o)&&a.is(this.paper.customAttributes[o],"function")){var p=this.paper.customAttributes[o].apply(this,[].concat(n[o]));this.attrs[o]=n[o];for(var q in p)p[b](q)&&(n[q]=p[q])}n.text&&"text"==this.type&&(this.textpath.string=n.text),B(this,n)}return this},E.toFront=function(){return!this.removed&&this.node.parentNode.appendChild(this.node),this.paper&&this.paper.top!=this&&a._tofront(this,this.paper),this},E.toBack=function(){return this.removed?this:(this.node.parentNode.firstChild!=this.node&&(this.node.parentNode.insertBefore(this.node,this.node.parentNode.firstChild),a._toback(this,this.paper)),this)},E.insertAfter=function(b){return this.removed?this:(b.constructor==a.st.constructor&&(b=b[b.length-1]),b.node.nextSibling?b.node.parentNode.insertBefore(this.node,b.node.nextSibling):b.node.parentNode.appendChild(this.node),a._insertafter(this,b,this.paper),this)},E.insertBefore=function(b){return this.removed?this:(b.constructor==a.st.constructor&&(b=b[0]),b.node.parentNode.insertBefore(this.node,b.node),a._insertbefore(this,b,this.paper),this)},E.blur=function(b){var c=this.node.runtimeStyle,d=c.filter;d=d.replace(r,o),0!==+b?(this.attrs.blur=b,c.filter=d+n+m+".Blur(pixelradius="+(+b||1.5)+")",c.margin=a.format("-{0}px 0 0 -{0}px",f(+b||1.5))):(c.filter=d,c.margin=0,delete this.attrs.blur)},a._engine.path=function(a,b){var c=F("shape");c.style.cssText=t,c.coordsize=u+n+u,c.coordorigin=b.coordorigin;var d=new D(c,b),e={fill:"none",stroke:"#000"};a&&(e.path=a),d.type="path",d.path=[],d.Path=o,B(d,e),b.canvas.appendChild(c);var f=F("skew");return f.on=!0,c.appendChild(f),d.skew=f,d.transform(o),d},a._engine.rect=function(b,c,d,e,f,g){var h=a._rectPath(c,d,e,f,g),i=b.path(h),j=i.attrs;return i.X=j.x=c,i.Y=j.y=d,i.W=j.width=e,i.H=j.height=f,j.r=g,j.path=h,i.type="rect",i},a._engine.ellipse=function(a,b,c,d,e){{var f=a.path();f.attrs}return f.X=b-d,f.Y=c-e,f.W=2*d,f.H=2*e,f.type="ellipse",B(f,{cx:b,cy:c,rx:d,ry:e}),f},a._engine.circle=function(a,b,c,d){{var e=a.path();e.attrs}return e.X=b-d,e.Y=c-d,e.W=e.H=2*d,e.type="circle",B(e,{cx:b,cy:c,r:d}),e},a._engine.image=function(b,c,d,e,f,g){var h=a._rectPath(d,e,f,g),i=b.path(h).attr({stroke:"none"}),k=i.attrs,l=i.node,m=l.getElementsByTagName(j)[0];return k.src=c,i.X=k.x=d,i.Y=k.y=e,i.W=k.width=f,i.H=k.height=g,k.path=h,i.type="image",m.parentNode==l&&l.removeChild(m),m.rotate=!0,m.src=c,m.type="tile",i._.fillpos=[d,e],i._.fillsize=[f,g],l.appendChild(m),z(i,1,1,0,0,0),i},a._engine.text=function(b,d,e,g){var h=F("shape"),i=F("path"),j=F("textpath");d=d||0,e=e||0,g=g||"",i.v=a.format("m{0},{1}l{2},{1}",f(d*u),f(e*u),f(d*u)+1),i.textpathok=!0,j.string=c(g),j.on=!0,h.style.cssText=t,h.coordsize=u+n+u,h.coordorigin="0 0";var k=new D(h,b),l={fill:"#000",stroke:"none",font:a._availableAttrs.font,text:g};k.shape=h,k.path=i,k.textpath=j,k.type="text",k.attrs.text=c(g),k.attrs.x=d,k.attrs.y=e,k.attrs.w=1,k.attrs.h=1,B(k,l),h.appendChild(j),h.appendChild(i),b.canvas.appendChild(h);var m=F("skew");return m.on=!0,h.appendChild(m),k.skew=m,k.transform(o),k},a._engine.setSize=function(b,c){var d=this.canvas.style;return this.width=b,this.height=c,b==+b&&(b+="px"),c==+c&&(c+="px"),d.width=b,d.height=c,d.clip="rect(0 "+b+" "+c+" 0)",this._viewBox&&a._engine.setViewBox.apply(this,this._viewBox),this},a._engine.setViewBox=function(b,c,d,e,f){a.eve("raphael.setViewBox",this,this._viewBox,[b,c,d,e,f]);var h,i,j=this.width,k=this.height,l=1/g(d/j,e/k);return f&&(h=k/e,i=j/d,j>d*h&&(b-=(j-d*h)/2/h),k>e*i&&(c-=(k-e*i)/2/i)),this._viewBox=[b,c,d,e,!!f],this._viewBoxShift={dx:-b,dy:-c,scale:l},this.forEach(function(a){a.transform("...")}),this};var F;a._engine.initWin=function(a){var b=a.document;b.createStyleSheet().addRule(".rvml","behavior:url(#default#VML)");try{!b.namespaces.rvml&&b.namespaces.add("rvml","urn:schemas-microsoft-com:vml"),F=function(a){return b.createElement("<rvml:"+a+' class="rvml">')}}catch(c){F=function(a){return b.createElement("<"+a+' xmlns="urn:schemas-microsoft.com:vml" class="rvml">')}}},a._engine.initWin(a._g.win),a._engine.create=function(){var b=a._getContainer.apply(0,arguments),c=b.container,d=b.height,e=b.width,f=b.x,g=b.y;if(!c)throw new Error("VML container not found.");var h=new a._Paper,i=h.canvas=a._g.doc.createElement("div"),j=i.style;return f=f||0,g=g||0,e=e||512,d=d||342,h.width=e,h.height=d,e==+e&&(e+="px"),d==+d&&(d+="px"),h.coordsize=1e3*u+n+1e3*u,h.coordorigin="0 0",h.span=a._g.doc.createElement("span"),h.span.style.cssText="position:absolute;left:-9999em;top:-9999em;padding:0;margin:0;line-height:1;",i.appendChild(h.span),j.cssText=a.format("top:0;left:0;width:{0};height:{1};display:inline-block;position:relative;clip:rect(0 {0} {1} 0);overflow:hidden",e,d),1==c?(a._g.doc.body.appendChild(i),j.left=f+"px",j.top=g+"px",j.position="absolute"):c.firstChild?c.insertBefore(i,c.firstChild):c.appendChild(i),h.renderfix=function(){},h},a.prototype.clear=function(){a.eve("raphael.clear",this),this.canvas.innerHTML=o,this.span=a._g.doc.createElement("span"),this.span.style.cssText="position:absolute;left:-9999em;top:-9999em;padding:0;margin:0;line-height:1;display:inline;",this.canvas.appendChild(this.span),this.bottom=this.top=null},a.prototype.remove=function(){a.eve("raphael.remove",this),this.canvas.parentNode.removeChild(this.canvas);for(var b in this)this[b]="function"==typeof this[b]?a._removedFactory(b):null;return!0};var G=a.st;for(var H in E)E[b](H)&&!G[b](H)&&(G[H]=function(a){return function(){var b=arguments;return this.forEach(function(c){c[a].apply(c,b)})}}(H))}(window.Raphael),function(a,b){function c(b,c){var e=b.nodeName.toLowerCase();if("area"===e){var f,g=b.parentNode,h=g.name;return b.href&&h&&"map"===g.nodeName.toLowerCase()?(f=a("img[usemap=#"+h+"]")[0],!!f&&d(f)):!1}return(/input|select|textarea|button|object/.test(e)?!b.disabled:"a"==e?b.href||c:c)&&d(b)}function d(b){return!a(b).parents().andSelf().filter(function(){return"hidden"===a.curCSS(this,"visibility")||a.expr.filters.hidden(this)}).length}a.ui=a.ui||{},a.ui.version||(a.extend(a.ui,{version:"1.8.24",keyCode:{ALT:18,BACKSPACE:8,CAPS_LOCK:20,COMMA:188,COMMAND:91,COMMAND_LEFT:91,COMMAND_RIGHT:93,CONTROL:17,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,INSERT:45,LEFT:37,MENU:93,NUMPAD_ADD:107,NUMPAD_DECIMAL:110,NUMPAD_DIVIDE:111,NUMPAD_ENTER:108,NUMPAD_MULTIPLY:106,NUMPAD_SUBTRACT:109,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SHIFT:16,SPACE:32,TAB:9,UP:38,WINDOWS:91}}),a.fn.extend({propAttr:a.fn.prop||a.fn.attr,_focus:a.fn.focus,focus:function(b,c){return"number"==typeof b?this.each(function(){var d=this;setTimeout(function(){a(d).focus(),c&&c.call(d)},b)}):this._focus.apply(this,arguments)},scrollParent:function(){var b;return b=a.browser.msie&&/(static|relative)/.test(this.css("position"))||/absolute/.test(this.css("position"))?this.parents().filter(function(){return/(relative|absolute|fixed)/.test(a.curCSS(this,"position",1))&&/(auto|scroll)/.test(a.curCSS(this,"overflow",1)+a.curCSS(this,"overflow-y",1)+a.curCSS(this,"overflow-x",1))}).eq(0):this.parents().filter(function(){return/(auto|scroll)/.test(a.curCSS(this,"overflow",1)+a.curCSS(this,"overflow-y",1)+a.curCSS(this,"overflow-x",1))}).eq(0),/fixed/.test(this.css("position"))||!b.length?a(document):b},zIndex:function(c){if(c!==b)return this.css("zIndex",c);if(this.length)for(var d,e,f=a(this[0]);f.length&&f[0]!==document;){if(d=f.css("position"),("absolute"===d||"relative"===d||"fixed"===d)&&(e=parseInt(f.css("zIndex"),10),!isNaN(e)&&0!==e))return e;f=f.parent()}return 0},disableSelection:function(){return this.bind((a.support.selectstart?"selectstart":"mousedown")+".ui-disableSelection",function(a){a.preventDefault()})},enableSelection:function(){return this.unbind(".ui-disableSelection")}}),a("<a>").outerWidth(1).jquery||a.each(["Width","Height"],function(c,d){function e(b,c,d,e){return a.each(f,function(){c-=parseFloat(a.curCSS(b,"padding"+this,!0))||0,d&&(c-=parseFloat(a.curCSS(b,"border"+this+"Width",!0))||0),e&&(c-=parseFloat(a.curCSS(b,"margin"+this,!0))||0)}),c}var f="Width"===d?["Left","Right"]:["Top","Bottom"],g=d.toLowerCase(),h={innerWidth:a.fn.innerWidth,innerHeight:a.fn.innerHeight,outerWidth:a.fn.outerWidth,outerHeight:a.fn.outerHeight};a.fn["inner"+d]=function(c){return c===b?h["inner"+d].call(this):this.each(function(){a(this).css(g,e(this,c)+"px")})},a.fn["outer"+d]=function(b,c){return"number"!=typeof b?h["outer"+d].call(this,b):this.each(function(){a(this).css(g,e(this,b,!0,c)+"px")})}}),a.extend(a.expr[":"],{data:a.expr.createPseudo?a.expr.createPseudo(function(b){return function(c){return!!a.data(c,b)}}):function(b,c,d){return!!a.data(b,d[3])},focusable:function(b){return c(b,!isNaN(a.attr(b,"tabindex")))},tabbable:function(b){var d=a.attr(b,"tabindex"),e=isNaN(d);return(e||d>=0)&&c(b,!e)}}),a(function(){var b=document.body,c=b.appendChild(c=document.createElement("div"));c.offsetHeight,a.extend(c.style,{minHeight:"100px",height:"auto",padding:0,borderWidth:0}),a.support.minHeight=100===c.offsetHeight,a.support.selectstart="onselectstart"in c,b.removeChild(c).style.display="none"}),a.curCSS||(a.curCSS=a.css),a.extend(a.ui,{plugin:{add:function(b,c,d){var e=a.ui[b].prototype;for(var f in d)e.plugins[f]=e.plugins[f]||[],e.plugins[f].push([c,d[f]])},call:function(a,b,c){var d=a.plugins[b];if(d&&a.element[0].parentNode)for(var e=0;e<d.length;e++)a.options[d[e][0]]&&d[e][1].apply(a.element,c)}},contains:function(a,b){return document.compareDocumentPosition?16&a.compareDocumentPosition(b):a!==b&&a.contains(b)},hasScroll:function(b,c){if("hidden"===a(b).css("overflow"))return!1;var d=c&&"left"===c?"scrollLeft":"scrollTop",e=!1;return b[d]>0?!0:(b[d]=1,e=b[d]>0,b[d]=0,e)},isOverAxis:function(a,b,c){return a>b&&b+c>a},isOver:function(b,c,d,e,f,g){return a.ui.isOverAxis(b,d,f)&&a.ui.isOverAxis(c,e,g)}}))}(jQuery),function(a,b){if(a.cleanData){var c=a.cleanData;a.cleanData=function(b){for(var d,e=0;null!=(d=b[e]);e++)try{a(d).triggerHandler("remove")}catch(f){}c(b)}}else{var d=a.fn.remove;a.fn.remove=function(b,c){return this.each(function(){return c||(!b||a.filter(b,[this]).length)&&a("*",this).add([this]).each(function(){try{a(this).triggerHandler("remove")}catch(b){}}),d.call(a(this),b,c)})}}a.widget=function(b,c,d){var e,f=b.split(".")[0];b=b.split(".")[1],e=f+"-"+b,d||(d=c,c=a.Widget),a.expr[":"][e]=function(c){return!!a.data(c,b)},a[f]=a[f]||{},a[f][b]=function(a,b){arguments.length&&this._createWidget(a,b)};var g=new c; g.options=a.extend(!0,{},g.options),a[f][b].prototype=a.extend(!0,g,{namespace:f,widgetName:b,widgetEventPrefix:a[f][b].prototype.widgetEventPrefix||b,widgetBaseClass:e},d),a.widget.bridge(b,a[f][b])},a.widget.bridge=function(c,d){a.fn[c]=function(e){var f="string"==typeof e,g=Array.prototype.slice.call(arguments,1),h=this;return e=!f&&g.length?a.extend.apply(null,[!0,e].concat(g)):e,f&&"_"===e.charAt(0)?h:(this.each(f?function(){var d=a.data(this,c),f=d&&a.isFunction(d[e])?d[e].apply(d,g):d;return f!==d&&f!==b?(h=f,!1):void 0}:function(){var b=a.data(this,c);b?b.option(e||{})._init():a.data(this,c,new d(e,this))}),h)}},a.Widget=function(a,b){arguments.length&&this._createWidget(a,b)},a.Widget.prototype={widgetName:"widget",widgetEventPrefix:"",options:{disabled:!1},_createWidget:function(b,c){a.data(c,this.widgetName,this),this.element=a(c),this.options=a.extend(!0,{},this.options,this._getCreateOptions(),b);var d=this;this.element.bind("remove."+this.widgetName,function(){d.destroy()}),this._create(),this._trigger("create"),this._init()},_getCreateOptions:function(){return a.metadata&&a.metadata.get(this.element[0])[this.widgetName]},_create:function(){},_init:function(){},destroy:function(){this.element.unbind("."+this.widgetName).removeData(this.widgetName),this.widget().unbind("."+this.widgetName).removeAttr("aria-disabled").removeClass(this.widgetBaseClass+"-disabled ui-state-disabled")},widget:function(){return this.element},option:function(c,d){var e=c;if(0===arguments.length)return a.extend({},this.options);if("string"==typeof c){if(d===b)return this.options[c];e={},e[c]=d}return this._setOptions(e),this},_setOptions:function(b){var c=this;return a.each(b,function(a,b){c._setOption(a,b)}),this},_setOption:function(a,b){return this.options[a]=b,"disabled"===a&&this.widget()[b?"addClass":"removeClass"](this.widgetBaseClass+"-disabled ui-state-disabled").attr("aria-disabled",b),this},enable:function(){return this._setOption("disabled",!1)},disable:function(){return this._setOption("disabled",!0)},_trigger:function(b,c,d){var e,f,g=this.options[b];if(d=d||{},c=a.Event(c),c.type=(b===this.widgetEventPrefix?b:this.widgetEventPrefix+b).toLowerCase(),c.target=this.element[0],f=c.originalEvent)for(e in f)e in c||(c[e]=f[e]);return this.element.trigger(c,d),!(a.isFunction(g)&&g.call(this.element[0],c,d)===!1||c.isDefaultPrevented())}}}(jQuery),function(a){var b=!1;a(document).mouseup(function(){b=!1}),a.widget("ui.mouse",{options:{cancel:":input,option",distance:1,delay:0},_mouseInit:function(){var b=this;this.element.bind("mousedown."+this.widgetName,function(a){return b._mouseDown(a)}).bind("click."+this.widgetName,function(c){return!0===a.data(c.target,b.widgetName+".preventClickEvent")?(a.removeData(c.target,b.widgetName+".preventClickEvent"),c.stopImmediatePropagation(),!1):void 0}),this.started=!1},_mouseDestroy:function(){this.element.unbind("."+this.widgetName),this._mouseMoveDelegate&&a(document).unbind("mousemove."+this.widgetName,this._mouseMoveDelegate).unbind("mouseup."+this.widgetName,this._mouseUpDelegate)},_mouseDown:function(c){if(!b){this._mouseStarted&&this._mouseUp(c),this._mouseDownEvent=c;var d=this,e=1==c.which,f="string"==typeof this.options.cancel&&c.target.nodeName?a(c.target).closest(this.options.cancel).length:!1;return e&&!f&&this._mouseCapture(c)?(this.mouseDelayMet=!this.options.delay,this.mouseDelayMet||(this._mouseDelayTimer=setTimeout(function(){d.mouseDelayMet=!0},this.options.delay)),this._mouseDistanceMet(c)&&this._mouseDelayMet(c)&&(this._mouseStarted=this._mouseStart(c)!==!1,!this._mouseStarted)?(c.preventDefault(),!0):(!0===a.data(c.target,this.widgetName+".preventClickEvent")&&a.removeData(c.target,this.widgetName+".preventClickEvent"),this._mouseMoveDelegate=function(a){return d._mouseMove(a)},this._mouseUpDelegate=function(a){return d._mouseUp(a)},a(document).bind("mousemove."+this.widgetName,this._mouseMoveDelegate).bind("mouseup."+this.widgetName,this._mouseUpDelegate),c.preventDefault(),b=!0,!0)):!0}},_mouseMove:function(b){return!a.browser.msie||document.documentMode>=9||b.button?this._mouseStarted?(this._mouseDrag(b),b.preventDefault()):(this._mouseDistanceMet(b)&&this._mouseDelayMet(b)&&(this._mouseStarted=this._mouseStart(this._mouseDownEvent,b)!==!1,this._mouseStarted?this._mouseDrag(b):this._mouseUp(b)),!this._mouseStarted):this._mouseUp(b)},_mouseUp:function(b){return a(document).unbind("mousemove."+this.widgetName,this._mouseMoveDelegate).unbind("mouseup."+this.widgetName,this._mouseUpDelegate),this._mouseStarted&&(this._mouseStarted=!1,b.target==this._mouseDownEvent.target&&a.data(b.target,this.widgetName+".preventClickEvent",!0),this._mouseStop(b)),!1},_mouseDistanceMet:function(a){return Math.max(Math.abs(this._mouseDownEvent.pageX-a.pageX),Math.abs(this._mouseDownEvent.pageY-a.pageY))>=this.options.distance},_mouseDelayMet:function(){return this.mouseDelayMet},_mouseStart:function(){},_mouseDrag:function(){},_mouseStop:function(){},_mouseCapture:function(){return!0}})}(jQuery),function(a){a.widget("ui.draggable",a.ui.mouse,{widgetEventPrefix:"drag",options:{addClasses:!0,appendTo:"parent",axis:!1,connectToSortable:!1,containment:!1,cursor:"auto",cursorAt:!1,grid:!1,handle:!1,helper:"original",iframeFix:!1,opacity:!1,refreshPositions:!1,revert:!1,revertDuration:500,scope:"default",scroll:!0,scrollSensitivity:20,scrollSpeed:20,snap:!1,snapMode:"both",snapTolerance:20,stack:!1,zIndex:!1},_create:function(){"original"!=this.options.helper||/^(?:r|a|f)/.test(this.element.css("position"))||(this.element[0].style.position="relative"),this.options.addClasses&&this.element.addClass("ui-draggable"),this.options.disabled&&this.element.addClass("ui-draggable-disabled"),this._mouseInit()},destroy:function(){return this.element.data("draggable")?(this.element.removeData("draggable").unbind(".draggable").removeClass("ui-draggable ui-draggable-dragging ui-draggable-disabled"),this._mouseDestroy(),this):void 0},_mouseCapture:function(b){var c=this.options;return this.helper||c.disabled||a(b.target).is(".ui-resizable-handle")?!1:(this.handle=this._getHandle(b),this.handle?(c.iframeFix&&a(c.iframeFix===!0?"iframe":c.iframeFix).each(function(){a('<div class="ui-draggable-iframeFix" style="background: #fff;"></div>').css({width:this.offsetWidth+"px",height:this.offsetHeight+"px",position:"absolute",opacity:"0.001",zIndex:1e3}).css(a(this).offset()).appendTo("body")}),!0):!1)},_mouseStart:function(b){var c=this.options;return this.helper=this._createHelper(b),this.helper.addClass("ui-draggable-dragging"),this._cacheHelperProportions(),a.ui.ddmanager&&(a.ui.ddmanager.current=this),this._cacheMargins(),this.cssPosition=this.helper.css("position"),this.scrollParent=this.helper.scrollParent(),this.offset=this.positionAbs=this.element.offset(),this.offset={top:this.offset.top-this.margins.top,left:this.offset.left-this.margins.left},a.extend(this.offset,{click:{left:b.pageX-this.offset.left,top:b.pageY-this.offset.top},parent:this._getParentOffset(),relative:this._getRelativeOffset()}),this.originalPosition=this.position=this._generatePosition(b),this.originalPageX=b.pageX,this.originalPageY=b.pageY,c.cursorAt&&this._adjustOffsetFromHelper(c.cursorAt),c.containment&&this._setContainment(),this._trigger("start",b)===!1?(this._clear(),!1):(this._cacheHelperProportions(),a.ui.ddmanager&&!c.dropBehaviour&&a.ui.ddmanager.prepareOffsets(this,b),this._mouseDrag(b,!0),a.ui.ddmanager&&a.ui.ddmanager.dragStart(this,b),!0)},_mouseDrag:function(b,c){if(this.position=this._generatePosition(b),this.positionAbs=this._convertPositionTo("absolute"),!c){var d=this._uiHash();if(this._trigger("drag",b,d)===!1)return this._mouseUp({}),!1;this.position=d.position}return this.options.axis&&"y"==this.options.axis||(this.helper[0].style.left=this.position.left+"px"),this.options.axis&&"x"==this.options.axis||(this.helper[0].style.top=this.position.top+"px"),a.ui.ddmanager&&a.ui.ddmanager.drag(this,b),!1},_mouseStop:function(b){var c=!1;a.ui.ddmanager&&!this.options.dropBehaviour&&(c=a.ui.ddmanager.drop(this,b)),this.dropped&&(c=this.dropped,this.dropped=!1);for(var d=this.element[0],e=!1;d&&(d=d.parentNode);)d==document&&(e=!0);if(!e&&"original"===this.options.helper)return!1;if("invalid"==this.options.revert&&!c||"valid"==this.options.revert&&c||this.options.revert===!0||a.isFunction(this.options.revert)&&this.options.revert.call(this.element,c)){var f=this;a(this.helper).animate(this.originalPosition,parseInt(this.options.revertDuration,10),function(){f._trigger("stop",b)!==!1&&f._clear()})}else this._trigger("stop",b)!==!1&&this._clear();return!1},_mouseUp:function(b){return a("div.ui-draggable-iframeFix").each(function(){this.parentNode.removeChild(this)}),a.ui.ddmanager&&a.ui.ddmanager.dragStop(this,b),a.ui.mouse.prototype._mouseUp.call(this,b)},cancel:function(){return this.helper.is(".ui-draggable-dragging")?this._mouseUp({}):this._clear(),this},_getHandle:function(b){var c=this.options.handle&&a(this.options.handle,this.element).length?!1:!0;return a(this.options.handle,this.element).find("*").andSelf().each(function(){this==b.target&&(c=!0)}),c},_createHelper:function(b){var c=this.options,d=a.isFunction(c.helper)?a(c.helper.apply(this.element[0],[b])):"clone"==c.helper?this.element.clone().removeAttr("id"):this.element;return d.parents("body").length||d.appendTo("parent"==c.appendTo?this.element[0].parentNode:c.appendTo),d[0]==this.element[0]||/(fixed|absolute)/.test(d.css("position"))||d.css("position","absolute"),d},_adjustOffsetFromHelper:function(b){"string"==typeof b&&(b=b.split(" ")),a.isArray(b)&&(b={left:+b[0],top:+b[1]||0}),"left"in b&&(this.offset.click.left=b.left+this.margins.left),"right"in b&&(this.offset.click.left=this.helperProportions.width-b.right+this.margins.left),"top"in b&&(this.offset.click.top=b.top+this.margins.top),"bottom"in b&&(this.offset.click.top=this.helperProportions.height-b.bottom+this.margins.top)},_getParentOffset:function(){this.offsetParent=this.helper.offsetParent();var b=this.offsetParent.offset();return"absolute"==this.cssPosition&&this.scrollParent[0]!=document&&a.ui.contains(this.scrollParent[0],this.offsetParent[0])&&(b.left+=this.scrollParent.scrollLeft(),b.top+=this.scrollParent.scrollTop()),(this.offsetParent[0]==document.body||this.offsetParent[0].tagName&&"html"==this.offsetParent[0].tagName.toLowerCase()&&a.browser.msie)&&(b={top:0,left:0}),{top:b.top+(parseInt(this.offsetParent.css("borderTopWidth"),10)||0),left:b.left+(parseInt(this.offsetParent.css("borderLeftWidth"),10)||0)}},_getRelativeOffset:function(){if("relative"==this.cssPosition){var a=this.element.position();return{top:a.top-(parseInt(this.helper.css("top"),10)||0)+this.scrollParent.scrollTop(),left:a.left-(parseInt(this.helper.css("left"),10)||0)+this.scrollParent.scrollLeft()}}return{top:0,left:0}},_cacheMargins:function(){this.margins={left:parseInt(this.element.css("marginLeft"),10)||0,top:parseInt(this.element.css("marginTop"),10)||0,right:parseInt(this.element.css("marginRight"),10)||0,bottom:parseInt(this.element.css("marginBottom"),10)||0}},_cacheHelperProportions:function(){this.helperProportions={width:this.helper.outerWidth(),height:this.helper.outerHeight()}},_setContainment:function(){var b=this.options;if("parent"==b.containment&&(b.containment=this.helper[0].parentNode),("document"==b.containment||"window"==b.containment)&&(this.containment=["document"==b.containment?0:a(window).scrollLeft()-this.offset.relative.left-this.offset.parent.left,"document"==b.containment?0:a(window).scrollTop()-this.offset.relative.top-this.offset.parent.top,("document"==b.containment?0:a(window).scrollLeft())+a("document"==b.containment?document:window).width()-this.helperProportions.width-this.margins.left,("document"==b.containment?0:a(window).scrollTop())+(a("document"==b.containment?document:window).height()||document.body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top]),/^(document|window|parent)$/.test(b.containment)||b.containment.constructor==Array)b.containment.constructor==Array&&(this.containment=b.containment);else{var c=a(b.containment),d=c[0];if(!d)return;var e=(c.offset(),"hidden"!=a(d).css("overflow"));this.containment=[(parseInt(a(d).css("borderLeftWidth"),10)||0)+(parseInt(a(d).css("paddingLeft"),10)||0),(parseInt(a(d).css("borderTopWidth"),10)||0)+(parseInt(a(d).css("paddingTop"),10)||0),(e?Math.max(d.scrollWidth,d.offsetWidth):d.offsetWidth)-(parseInt(a(d).css("borderLeftWidth"),10)||0)-(parseInt(a(d).css("paddingRight"),10)||0)-this.helperProportions.width-this.margins.left-this.margins.right,(e?Math.max(d.scrollHeight,d.offsetHeight):d.offsetHeight)-(parseInt(a(d).css("borderTopWidth"),10)||0)-(parseInt(a(d).css("paddingBottom"),10)||0)-this.helperProportions.height-this.margins.top-this.margins.bottom],this.relative_container=c}},_convertPositionTo:function(b,c){c||(c=this.position);var d="absolute"==b?1:-1,e=(this.options,"absolute"!=this.cssPosition||this.scrollParent[0]!=document&&a.ui.contains(this.scrollParent[0],this.offsetParent[0])?this.scrollParent:this.offsetParent),f=/(html|body)/i.test(e[0].tagName);return{top:c.top+this.offset.relative.top*d+this.offset.parent.top*d-(a.browser.safari&&a.browser.version<526&&"fixed"==this.cssPosition?0:("fixed"==this.cssPosition?-this.scrollParent.scrollTop():f?0:e.scrollTop())*d),left:c.left+this.offset.relative.left*d+this.offset.parent.left*d-(a.browser.safari&&a.browser.version<526&&"fixed"==this.cssPosition?0:("fixed"==this.cssPosition?-this.scrollParent.scrollLeft():f?0:e.scrollLeft())*d)}},_generatePosition:function(b){var c=this.options,d="absolute"!=this.cssPosition||this.scrollParent[0]!=document&&a.ui.contains(this.scrollParent[0],this.offsetParent[0])?this.scrollParent:this.offsetParent,e=/(html|body)/i.test(d[0].tagName),f=b.pageX,g=b.pageY;if(this.originalPosition){var h;if(this.containment){if(this.relative_container){var i=this.relative_container.offset();h=[this.containment[0]+i.left,this.containment[1]+i.top,this.containment[2]+i.left,this.containment[3]+i.top]}else h=this.containment;b.pageX-this.offset.click.left<h[0]&&(f=h[0]+this.offset.click.left),b.pageY-this.offset.click.top<h[1]&&(g=h[1]+this.offset.click.top),b.pageX-this.offset.click.left>h[2]&&(f=h[2]+this.offset.click.left),b.pageY-this.offset.click.top>h[3]&&(g=h[3]+this.offset.click.top)}if(c.grid){var j=c.grid[1]?this.originalPageY+Math.round((g-this.originalPageY)/c.grid[1])*c.grid[1]:this.originalPageY;g=h&&(j-this.offset.click.top<h[1]||j-this.offset.click.top>h[3])?j-this.offset.click.top<h[1]?j+c.grid[1]:j-c.grid[1]:j;var k=c.grid[0]?this.originalPageX+Math.round((f-this.originalPageX)/c.grid[0])*c.grid[0]:this.originalPageX;f=h&&(k-this.offset.click.left<h[0]||k-this.offset.click.left>h[2])?k-this.offset.click.left<h[0]?k+c.grid[0]:k-c.grid[0]:k}}return{top:g-this.offset.click.top-this.offset.relative.top-this.offset.parent.top+(a.browser.safari&&a.browser.version<526&&"fixed"==this.cssPosition?0:"fixed"==this.cssPosition?-this.scrollParent.scrollTop():e?0:d.scrollTop()),left:f-this.offset.click.left-this.offset.relative.left-this.offset.parent.left+(a.browser.safari&&a.browser.version<526&&"fixed"==this.cssPosition?0:"fixed"==this.cssPosition?-this.scrollParent.scrollLeft():e?0:d.scrollLeft())}},_clear:function(){this.helper.removeClass("ui-draggable-dragging"),this.helper[0]==this.element[0]||this.cancelHelperRemoval||this.helper.remove(),this.helper=null,this.cancelHelperRemoval=!1},_trigger:function(b,c,d){return d=d||this._uiHash(),a.ui.plugin.call(this,b,[c,d]),"drag"==b&&(this.positionAbs=this._convertPositionTo("absolute")),a.Widget.prototype._trigger.call(this,b,c,d)},plugins:{},_uiHash:function(){return{helper:this.helper,position:this.position,originalPosition:this.originalPosition,offset:this.positionAbs}}}),a.extend(a.ui.draggable,{version:"1.8.24"}),a.ui.plugin.add("draggable","connectToSortable",{start:function(b,c){var d=a(this).data("draggable"),e=d.options,f=a.extend({},c,{item:d.element});d.sortables=[],a(e.connectToSortable).each(function(){var c=a.data(this,"sortable");c&&!c.options.disabled&&(d.sortables.push({instance:c,shouldRevert:c.options.revert}),c.refreshPositions(),c._trigger("activate",b,f))})},stop:function(b,c){var d=a(this).data("draggable"),e=a.extend({},c,{item:d.element});a.each(d.sortables,function(){this.instance.isOver?(this.instance.isOver=0,d.cancelHelperRemoval=!0,this.instance.cancelHelperRemoval=!1,this.shouldRevert&&(this.instance.options.revert=!0),this.instance._mouseStop(b),this.instance.options.helper=this.instance.options._helper,"original"==d.options.helper&&this.instance.currentItem.css({top:"auto",left:"auto"})):(this.instance.cancelHelperRemoval=!1,this.instance._trigger("deactivate",b,e))})},drag:function(b,c){var d=a(this).data("draggable"),e=this;a.each(d.sortables,function(){this.instance.positionAbs=d.positionAbs,this.instance.helperProportions=d.helperProportions,this.instance.offset.click=d.offset.click,this.instance._intersectsWith(this.instance.containerCache)?(this.instance.isOver||(this.instance.isOver=1,this.instance.currentItem=a(e).clone().removeAttr("id").appendTo(this.instance.element).data("sortable-item",!0),this.instance.options._helper=this.instance.options.helper,this.instance.options.helper=function(){return c.helper[0]},b.target=this.instance.currentItem[0],this.instance._mouseCapture(b,!0),this.instance._mouseStart(b,!0,!0),this.instance.offset.click.top=d.offset.click.top,this.instance.offset.click.left=d.offset.click.left,this.instance.offset.parent.left-=d.offset.parent.left-this.instance.offset.parent.left,this.instance.offset.parent.top-=d.offset.parent.top-this.instance.offset.parent.top,d._trigger("toSortable",b),d.dropped=this.instance.element,d.currentItem=d.element,this.instance.fromOutside=d),this.instance.currentItem&&this.instance._mouseDrag(b)):this.instance.isOver&&(this.instance.isOver=0,this.instance.cancelHelperRemoval=!0,this.instance.options.revert=!1,this.instance._trigger("out",b,this.instance._uiHash(this.instance)),this.instance._mouseStop(b,!0),this.instance.options.helper=this.instance.options._helper,this.instance.currentItem.remove(),this.instance.placeholder&&this.instance.placeholder.remove(),d._trigger("fromSortable",b),d.dropped=!1)})}}),a.ui.plugin.add("draggable","cursor",{start:function(){var b=a("body"),c=a(this).data("draggable").options;b.css("cursor")&&(c._cursor=b.css("cursor")),b.css("cursor",c.cursor)},stop:function(){var b=a(this).data("draggable").options;b._cursor&&a("body").css("cursor",b._cursor)}}),a.ui.plugin.add("draggable","opacity",{start:function(b,c){var d=a(c.helper),e=a(this).data("draggable").options;d.css("opacity")&&(e._opacity=d.css("opacity")),d.css("opacity",e.opacity)},stop:function(b,c){var d=a(this).data("draggable").options;d._opacity&&a(c.helper).css("opacity",d._opacity)}}),a.ui.plugin.add("draggable","scroll",{start:function(){var b=a(this).data("draggable");b.scrollParent[0]!=document&&"HTML"!=b.scrollParent[0].tagName&&(b.overflowOffset=b.scrollParent.offset())},drag:function(b){var c=a(this).data("draggable"),d=c.options,e=!1;c.scrollParent[0]!=document&&"HTML"!=c.scrollParent[0].tagName?(d.axis&&"x"==d.axis||(c.overflowOffset.top+c.scrollParent[0].offsetHeight-b.pageY<d.scrollSensitivity?c.scrollParent[0].scrollTop=e=c.scrollParent[0].scrollTop+d.scrollSpeed:b.pageY-c.overflowOffset.top<d.scrollSensitivity&&(c.scrollParent[0].scrollTop=e=c.scrollParent[0].scrollTop-d.scrollSpeed)),d.axis&&"y"==d.axis||(c.overflowOffset.left+c.scrollParent[0].offsetWidth-b.pageX<d.scrollSensitivity?c.scrollParent[0].scrollLeft=e=c.scrollParent[0].scrollLeft+d.scrollSpeed:b.pageX-c.overflowOffset.left<d.scrollSensitivity&&(c.scrollParent[0].scrollLeft=e=c.scrollParent[0].scrollLeft-d.scrollSpeed))):(d.axis&&"x"==d.axis||(b.pageY-a(document).scrollTop()<d.scrollSensitivity?e=a(document).scrollTop(a(document).scrollTop()-d.scrollSpeed):a(window).height()-(b.pageY-a(document).scrollTop())<d.scrollSensitivity&&(e=a(document).scrollTop(a(document).scrollTop()+d.scrollSpeed))),d.axis&&"y"==d.axis||(b.pageX-a(document).scrollLeft()<d.scrollSensitivity?e=a(document).scrollLeft(a(document).scrollLeft()-d.scrollSpeed):a(window).width()-(b.pageX-a(document).scrollLeft())<d.scrollSensitivity&&(e=a(document).scrollLeft(a(document).scrollLeft()+d.scrollSpeed)))),e!==!1&&a.ui.ddmanager&&!d.dropBehaviour&&a.ui.ddmanager.prepareOffsets(c,b)}}),a.ui.plugin.add("draggable","snap",{start:function(){var b=a(this).data("draggable"),c=b.options;b.snapElements=[],a(c.snap.constructor!=String?c.snap.items||":data(draggable)":c.snap).each(function(){var c=a(this),d=c.offset();this!=b.element[0]&&b.snapElements.push({item:this,width:c.outerWidth(),height:c.outerHeight(),top:d.top,left:d.left})})},drag:function(b,c){for(var d=a(this).data("draggable"),e=d.options,f=e.snapTolerance,g=c.offset.left,h=g+d.helperProportions.width,i=c.offset.top,j=i+d.helperProportions.height,k=d.snapElements.length-1;k>=0;k--){var l=d.snapElements[k].left,m=l+d.snapElements[k].width,n=d.snapElements[k].top,o=n+d.snapElements[k].height;if(g>l-f&&m+f>g&&i>n-f&&o+f>i||g>l-f&&m+f>g&&j>n-f&&o+f>j||h>l-f&&m+f>h&&i>n-f&&o+f>i||h>l-f&&m+f>h&&j>n-f&&o+f>j){if("inner"!=e.snapMode){var p=Math.abs(n-j)<=f,q=Math.abs(o-i)<=f,r=Math.abs(l-h)<=f,s=Math.abs(m-g)<=f;p&&(c.position.top=d._convertPositionTo("relative",{top:n-d.helperProportions.height,left:0}).top-d.margins.top),q&&(c.position.top=d._convertPositionTo("relative",{top:o,left:0}).top-d.margins.top),r&&(c.position.left=d._convertPositionTo("relative",{top:0,left:l-d.helperProportions.width}).left-d.margins.left),s&&(c.position.left=d._convertPositionTo("relative",{top:0,left:m}).left-d.margins.left)}var t=p||q||r||s;if("outer"!=e.snapMode){var p=Math.abs(n-i)<=f,q=Math.abs(o-j)<=f,r=Math.abs(l-g)<=f,s=Math.abs(m-h)<=f;p&&(c.position.top=d._convertPositionTo("relative",{top:n,left:0}).top-d.margins.top),q&&(c.position.top=d._convertPositionTo("relative",{top:o-d.helperProportions.height,left:0}).top-d.margins.top),r&&(c.position.left=d._convertPositionTo("relative",{top:0,left:l}).left-d.margins.left),s&&(c.position.left=d._convertPositionTo("relative",{top:0,left:m-d.helperProportions.width}).left-d.margins.left)}!d.snapElements[k].snapping&&(p||q||r||s||t)&&d.options.snap.snap&&d.options.snap.snap.call(d.element,b,a.extend(d._uiHash(),{snapItem:d.snapElements[k].item})),d.snapElements[k].snapping=p||q||r||s||t}else d.snapElements[k].snapping&&d.options.snap.release&&d.options.snap.release.call(d.element,b,a.extend(d._uiHash(),{snapItem:d.snapElements[k].item})),d.snapElements[k].snapping=!1}}}),a.ui.plugin.add("draggable","stack",{start:function(){var b=a(this).data("draggable").options,c=a.makeArray(a(b.stack)).sort(function(b,c){return(parseInt(a(b).css("zIndex"),10)||0)-(parseInt(a(c).css("zIndex"),10)||0)});if(c.length){var d=parseInt(c[0].style.zIndex)||0;a(c).each(function(a){this.style.zIndex=d+a}),this[0].style.zIndex=d+c.length}}}),a.ui.plugin.add("draggable","zIndex",{start:function(b,c){var d=a(c.helper),e=a(this).data("draggable").options;d.css("zIndex")&&(e._zIndex=d.css("zIndex")),d.css("zIndex",e.zIndex)},stop:function(b,c){var d=a(this).data("draggable").options;d._zIndex&&a(c.helper).css("zIndex",d._zIndex)}})}(jQuery),function(a){a.widget("ui.sortable",a.ui.mouse,{widgetEventPrefix:"sort",ready:!1,options:{appendTo:"parent",axis:!1,connectWith:!1,containment:!1,cursor:"auto",cursorAt:!1,dropOnEmpty:!0,forcePlaceholderSize:!1,forceHelperSize:!1,grid:!1,handle:!1,helper:"original",items:"> *",opacity:!1,placeholder:!1,revert:!1,scroll:!0,scrollSensitivity:20,scrollSpeed:20,scope:"default",tolerance:"intersect",zIndex:1e3},_create:function(){var a=this.options;this.containerCache={},this.element.addClass("ui-sortable"),this.refresh(),this.floating=this.items.length?"x"===a.axis||/left|right/.test(this.items[0].item.css("float"))||/inline|table-cell/.test(this.items[0].item.css("display")):!1,this.offset=this.element.offset(),this._mouseInit(),this.ready=!0},destroy:function(){a.Widget.prototype.destroy.call(this),this.element.removeClass("ui-sortable ui-sortable-disabled"),this._mouseDestroy();for(var b=this.items.length-1;b>=0;b--)this.items[b].item.removeData(this.widgetName+"-item");return this},_setOption:function(b,c){"disabled"===b?(this.options[b]=c,this.widget()[c?"addClass":"removeClass"]("ui-sortable-disabled")):a.Widget.prototype._setOption.apply(this,arguments)},_mouseCapture:function(b,c){var d=this;if(this.reverting)return!1;if(this.options.disabled||"static"==this.options.type)return!1;this._refreshItems(b);{var e=null,f=this;a(b.target).parents().each(function(){return a.data(this,d.widgetName+"-item")==f?(e=a(this),!1):void 0})}if(a.data(b.target,d.widgetName+"-item")==f&&(e=a(b.target)),!e)return!1;if(this.options.handle&&!c){var g=!1;if(a(this.options.handle,e).find("*").andSelf().each(function(){this==b.target&&(g=!0)}),!g)return!1}return this.currentItem=e,this._removeCurrentsFromItems(),!0},_mouseStart:function(b,c,d){var e=this.options,f=this;if(this.currentContainer=this,this.refreshPositions(),this.helper=this._createHelper(b),this._cacheHelperProportions(),this._cacheMargins(),this.scrollParent=this.helper.scrollParent(),this.offset=this.currentItem.offset(),this.offset={top:this.offset.top-this.margins.top,left:this.offset.left-this.margins.left},a.extend(this.offset,{click:{left:b.pageX-this.offset.left,top:b.pageY-this.offset.top},parent:this._getParentOffset(),relative:this._getRelativeOffset()}),this.helper.css("position","absolute"),this.cssPosition=this.helper.css("position"),this.originalPosition=this._generatePosition(b),this.originalPageX=b.pageX,this.originalPageY=b.pageY,e.cursorAt&&this._adjustOffsetFromHelper(e.cursorAt),this.domPosition={prev:this.currentItem.prev()[0],parent:this.currentItem.parent()[0]},this.helper[0]!=this.currentItem[0]&&this.currentItem.hide(),this._createPlaceholder(),e.containment&&this._setContainment(),e.cursor&&(a("body").css("cursor")&&(this._storedCursor=a("body").css("cursor")),a("body").css("cursor",e.cursor)),e.opacity&&(this.helper.css("opacity")&&(this._storedOpacity=this.helper.css("opacity")),this.helper.css("opacity",e.opacity)),e.zIndex&&(this.helper.css("zIndex")&&(this._storedZIndex=this.helper.css("zIndex")),this.helper.css("zIndex",e.zIndex)),this.scrollParent[0]!=document&&"HTML"!=this.scrollParent[0].tagName&&(this.overflowOffset=this.scrollParent.offset()),this._trigger("start",b,this._uiHash()),this._preserveHelperProportions||this._cacheHelperProportions(),!d)for(var g=this.containers.length-1;g>=0;g--)this.containers[g]._trigger("activate",b,f._uiHash(this));return a.ui.ddmanager&&(a.ui.ddmanager.current=this),a.ui.ddmanager&&!e.dropBehaviour&&a.ui.ddmanager.prepareOffsets(this,b),this.dragging=!0,this.helper.addClass("ui-sortable-helper"),this._mouseDrag(b),!0},_mouseDrag:function(b){if(this.position=this._generatePosition(b),this.positionAbs=this._convertPositionTo("absolute"),this.lastPositionAbs||(this.lastPositionAbs=this.positionAbs),this.options.scroll){var c=this.options,d=!1;this.scrollParent[0]!=document&&"HTML"!=this.scrollParent[0].tagName?(this.overflowOffset.top+this.scrollParent[0].offsetHeight-b.pageY<c.scrollSensitivity?this.scrollParent[0].scrollTop=d=this.scrollParent[0].scrollTop+c.scrollSpeed:b.pageY-this.overflowOffset.top<c.scrollSensitivity&&(this.scrollParent[0].scrollTop=d=this.scrollParent[0].scrollTop-c.scrollSpeed),this.overflowOffset.left+this.scrollParent[0].offsetWidth-b.pageX<c.scrollSensitivity?this.scrollParent[0].scrollLeft=d=this.scrollParent[0].scrollLeft+c.scrollSpeed:b.pageX-this.overflowOffset.left<c.scrollSensitivity&&(this.scrollParent[0].scrollLeft=d=this.scrollParent[0].scrollLeft-c.scrollSpeed)):(b.pageY-a(document).scrollTop()<c.scrollSensitivity?d=a(document).scrollTop(a(document).scrollTop()-c.scrollSpeed):a(window).height()-(b.pageY-a(document).scrollTop())<c.scrollSensitivity&&(d=a(document).scrollTop(a(document).scrollTop()+c.scrollSpeed)),b.pageX-a(document).scrollLeft()<c.scrollSensitivity?d=a(document).scrollLeft(a(document).scrollLeft()-c.scrollSpeed):a(window).width()-(b.pageX-a(document).scrollLeft())<c.scrollSensitivity&&(d=a(document).scrollLeft(a(document).scrollLeft()+c.scrollSpeed))),d!==!1&&a.ui.ddmanager&&!c.dropBehaviour&&a.ui.ddmanager.prepareOffsets(this,b)}this.positionAbs=this._convertPositionTo("absolute"),this.options.axis&&"y"==this.options.axis||(this.helper[0].style.left=this.position.left+"px"),this.options.axis&&"x"==this.options.axis||(this.helper[0].style.top=this.position.top+"px");for(var e=this.items.length-1;e>=0;e--){var f=this.items[e],g=f.item[0],h=this._intersectsWithPointer(f);if(h&&f.instance===this.currentContainer&&g!=this.currentItem[0]&&this.placeholder[1==h?"next":"prev"]()[0]!=g&&!a.ui.contains(this.placeholder[0],g)&&("semi-dynamic"==this.options.type?!a.ui.contains(this.element[0],g):!0)){if(this.direction=1==h?"down":"up","pointer"!=this.options.tolerance&&!this._intersectsWithSides(f))break;this._rearrange(b,f),this._trigger("change",b,this._uiHash());break}}return this._contactContainers(b),a.ui.ddmanager&&a.ui.ddmanager.drag(this,b),this._trigger("sort",b,this._uiHash()),this.lastPositionAbs=this.positionAbs,!1},_mouseStop:function(b,c){if(b){if(a.ui.ddmanager&&!this.options.dropBehaviour&&a.ui.ddmanager.drop(this,b),this.options.revert){var d=this,e=d.placeholder.offset();d.reverting=!0,a(this.helper).animate({left:e.left-this.offset.parent.left-d.margins.left+(this.offsetParent[0]==document.body?0:this.offsetParent[0].scrollLeft),top:e.top-this.offset.parent.top-d.margins.top+(this.offsetParent[0]==document.body?0:this.offsetParent[0].scrollTop)},parseInt(this.options.revert,10)||500,function(){d._clear(b)})}else this._clear(b,c);return!1}},cancel:function(){var b=this;if(this.dragging){this._mouseUp({target:null}),"original"==this.options.helper?this.currentItem.css(this._storedCSS).removeClass("ui-sortable-helper"):this.currentItem.show();for(var c=this.containers.length-1;c>=0;c--)this.containers[c]._trigger("deactivate",null,b._uiHash(this)),this.containers[c].containerCache.over&&(this.containers[c]._trigger("out",null,b._uiHash(this)),this.containers[c].containerCache.over=0)}return this.placeholder&&(this.placeholder[0].parentNode&&this.placeholder[0].parentNode.removeChild(this.placeholder[0]),"original"!=this.options.helper&&this.helper&&this.helper[0].parentNode&&this.helper.remove(),a.extend(this,{helper:null,dragging:!1,reverting:!1,_noFinalSort:null}),this.domPosition.prev?a(this.domPosition.prev).after(this.currentItem):a(this.domPosition.parent).prepend(this.currentItem)),this},serialize:function(b){var c=this._getItemsAsjQuery(b&&b.connected),d=[];return b=b||{},a(c).each(function(){var c=(a(b.item||this).attr(b.attribute||"id")||"").match(b.expression||/(.+)[-=_](.+)/);c&&d.push((b.key||c[1]+"[]")+"="+(b.key&&b.expression?c[1]:c[2]))}),!d.length&&b.key&&d.push(b.key+"="),d.join("&")},toArray:function(b){var c=this._getItemsAsjQuery(b&&b.connected),d=[];return b=b||{},c.each(function(){d.push(a(b.item||this).attr(b.attribute||"id")||"")}),d},_intersectsWith:function(a){var b=this.positionAbs.left,c=b+this.helperProportions.width,d=this.positionAbs.top,e=d+this.helperProportions.height,f=a.left,g=f+a.width,h=a.top,i=h+a.height,j=this.offset.click.top,k=this.offset.click.left,l=d+j>h&&i>d+j&&b+k>f&&g>b+k;return"pointer"==this.options.tolerance||this.options.forcePointerForContainers||"pointer"!=this.options.tolerance&&this.helperProportions[this.floating?"width":"height"]>a[this.floating?"width":"height"]?l:f<b+this.helperProportions.width/2&&c-this.helperProportions.width/2<g&&h<d+this.helperProportions.height/2&&e-this.helperProportions.height/2<i},_intersectsWithPointer:function(b){var c="x"===this.options.axis||a.ui.isOverAxis(this.positionAbs.top+this.offset.click.top,b.top,b.height),d="y"===this.options.axis||a.ui.isOverAxis(this.positionAbs.left+this.offset.click.left,b.left,b.width),e=c&&d,f=this._getDragVerticalDirection(),g=this._getDragHorizontalDirection(); return e?this.floating?g&&"right"==g||"down"==f?2:1:f&&("down"==f?2:1):!1},_intersectsWithSides:function(b){var c=a.ui.isOverAxis(this.positionAbs.top+this.offset.click.top,b.top+b.height/2,b.height),d=a.ui.isOverAxis(this.positionAbs.left+this.offset.click.left,b.left+b.width/2,b.width),e=this._getDragVerticalDirection(),f=this._getDragHorizontalDirection();return this.floating&&f?"right"==f&&d||"left"==f&&!d:e&&("down"==e&&c||"up"==e&&!c)},_getDragVerticalDirection:function(){var a=this.positionAbs.top-this.lastPositionAbs.top;return 0!=a&&(a>0?"down":"up")},_getDragHorizontalDirection:function(){var a=this.positionAbs.left-this.lastPositionAbs.left;return 0!=a&&(a>0?"right":"left")},refresh:function(a){return this._refreshItems(a),this.refreshPositions(),this},_connectWith:function(){var a=this.options;return a.connectWith.constructor==String?[a.connectWith]:a.connectWith},_getItemsAsjQuery:function(b){var c=[],d=[],e=this._connectWith();if(e&&b)for(var f=e.length-1;f>=0;f--)for(var g=a(e[f]),h=g.length-1;h>=0;h--){var i=a.data(g[h],this.widgetName);i&&i!=this&&!i.options.disabled&&d.push([a.isFunction(i.options.items)?i.options.items.call(i.element):a(i.options.items,i.element).not(".ui-sortable-helper").not(".ui-sortable-placeholder"),i])}d.push([a.isFunction(this.options.items)?this.options.items.call(this.element,null,{options:this.options,item:this.currentItem}):a(this.options.items,this.element).not(".ui-sortable-helper").not(".ui-sortable-placeholder"),this]);for(var f=d.length-1;f>=0;f--)d[f][0].each(function(){c.push(this)});return a(c)},_removeCurrentsFromItems:function(){for(var a=this.currentItem.find(":data("+this.widgetName+"-item)"),b=0;b<this.items.length;b++)for(var c=0;c<a.length;c++)a[c]==this.items[b].item[0]&&this.items.splice(b,1)},_refreshItems:function(b){this.items=[],this.containers=[this];var c=this.items,d=[[a.isFunction(this.options.items)?this.options.items.call(this.element[0],b,{item:this.currentItem}):a(this.options.items,this.element),this]],e=this._connectWith();if(e&&this.ready)for(var f=e.length-1;f>=0;f--)for(var g=a(e[f]),h=g.length-1;h>=0;h--){var i=a.data(g[h],this.widgetName);i&&i!=this&&!i.options.disabled&&(d.push([a.isFunction(i.options.items)?i.options.items.call(i.element[0],b,{item:this.currentItem}):a(i.options.items,i.element),i]),this.containers.push(i))}for(var f=d.length-1;f>=0;f--)for(var j=d[f][1],k=d[f][0],h=0,l=k.length;l>h;h++){var m=a(k[h]);m.data(this.widgetName+"-item",j),c.push({item:m,instance:j,width:0,height:0,left:0,top:0})}},refreshPositions:function(b){this.offsetParent&&this.helper&&(this.offset.parent=this._getParentOffset());for(var c=this.items.length-1;c>=0;c--){var d=this.items[c];if(d.instance==this.currentContainer||!this.currentContainer||d.item[0]==this.currentItem[0]){var e=this.options.toleranceElement?a(this.options.toleranceElement,d.item):d.item;b||(d.width=e.outerWidth(),d.height=e.outerHeight());var f=e.offset();d.left=f.left,d.top=f.top}}if(this.options.custom&&this.options.custom.refreshContainers)this.options.custom.refreshContainers.call(this);else for(var c=this.containers.length-1;c>=0;c--){var f=this.containers[c].element.offset();this.containers[c].containerCache.left=f.left,this.containers[c].containerCache.top=f.top,this.containers[c].containerCache.width=this.containers[c].element.outerWidth(),this.containers[c].containerCache.height=this.containers[c].element.outerHeight()}return this},_createPlaceholder:function(b){var c=b||this,d=c.options;if(!d.placeholder||d.placeholder.constructor==String){var e=d.placeholder;d.placeholder={element:function(){var b=a(document.createElement(c.currentItem[0].nodeName)).addClass(e||c.currentItem[0].className+" ui-sortable-placeholder").removeClass("ui-sortable-helper")[0];return e||(b.style.visibility="hidden"),b},update:function(a,b){(!e||d.forcePlaceholderSize)&&(b.height()||b.height(c.currentItem.innerHeight()-parseInt(c.currentItem.css("paddingTop")||0,10)-parseInt(c.currentItem.css("paddingBottom")||0,10)),b.width()||b.width(c.currentItem.innerWidth()-parseInt(c.currentItem.css("paddingLeft")||0,10)-parseInt(c.currentItem.css("paddingRight")||0,10)))}}}c.placeholder=a(d.placeholder.element.call(c.element,c.currentItem)),c.currentItem.after(c.placeholder),d.placeholder.update(c,c.placeholder)},_contactContainers:function(b){for(var c=null,d=null,e=this.containers.length-1;e>=0;e--)if(!a.ui.contains(this.currentItem[0],this.containers[e].element[0]))if(this._intersectsWith(this.containers[e].containerCache)){if(c&&a.ui.contains(this.containers[e].element[0],c.element[0]))continue;c=this.containers[e],d=e}else this.containers[e].containerCache.over&&(this.containers[e]._trigger("out",b,this._uiHash(this)),this.containers[e].containerCache.over=0);if(c)if(1===this.containers.length)this.containers[d]._trigger("over",b,this._uiHash(this)),this.containers[d].containerCache.over=1;else if(this.currentContainer!=this.containers[d]){for(var f=1e4,g=null,h=this.positionAbs[this.containers[d].floating?"left":"top"],i=this.items.length-1;i>=0;i--)if(a.ui.contains(this.containers[d].element[0],this.items[i].item[0])){var j=this.containers[d].floating?this.items[i].item.offset().left:this.items[i].item.offset().top;Math.abs(j-h)<f&&(f=Math.abs(j-h),g=this.items[i],this.direction=j-h>0?"down":"up")}if(!g&&!this.options.dropOnEmpty)return;this.currentContainer=this.containers[d],g?this._rearrange(b,g,null,!0):this._rearrange(b,null,this.containers[d].element,!0),this._trigger("change",b,this._uiHash()),this.containers[d]._trigger("change",b,this._uiHash(this)),this.options.placeholder.update(this.currentContainer,this.placeholder),this.containers[d]._trigger("over",b,this._uiHash(this)),this.containers[d].containerCache.over=1}},_createHelper:function(b){var c=this.options,d=a.isFunction(c.helper)?a(c.helper.apply(this.element[0],[b,this.currentItem])):"clone"==c.helper?this.currentItem.clone():this.currentItem;return d.parents("body").length||a("parent"!=c.appendTo?c.appendTo:this.currentItem[0].parentNode)[0].appendChild(d[0]),d[0]==this.currentItem[0]&&(this._storedCSS={width:this.currentItem[0].style.width,height:this.currentItem[0].style.height,position:this.currentItem.css("position"),top:this.currentItem.css("top"),left:this.currentItem.css("left")}),(""==d[0].style.width||c.forceHelperSize)&&d.width(this.currentItem.width()),(""==d[0].style.height||c.forceHelperSize)&&d.height(this.currentItem.height()),d},_adjustOffsetFromHelper:function(b){"string"==typeof b&&(b=b.split(" ")),a.isArray(b)&&(b={left:+b[0],top:+b[1]||0}),"left"in b&&(this.offset.click.left=b.left+this.margins.left),"right"in b&&(this.offset.click.left=this.helperProportions.width-b.right+this.margins.left),"top"in b&&(this.offset.click.top=b.top+this.margins.top),"bottom"in b&&(this.offset.click.top=this.helperProportions.height-b.bottom+this.margins.top)},_getParentOffset:function(){this.offsetParent=this.helper.offsetParent();var b=this.offsetParent.offset();return"absolute"==this.cssPosition&&this.scrollParent[0]!=document&&a.ui.contains(this.scrollParent[0],this.offsetParent[0])&&(b.left+=this.scrollParent.scrollLeft(),b.top+=this.scrollParent.scrollTop()),(this.offsetParent[0]==document.body||this.offsetParent[0].tagName&&"html"==this.offsetParent[0].tagName.toLowerCase()&&a.browser.msie)&&(b={top:0,left:0}),{top:b.top+(parseInt(this.offsetParent.css("borderTopWidth"),10)||0),left:b.left+(parseInt(this.offsetParent.css("borderLeftWidth"),10)||0)}},_getRelativeOffset:function(){if("relative"==this.cssPosition){var a=this.currentItem.position();return{top:a.top-(parseInt(this.helper.css("top"),10)||0)+this.scrollParent.scrollTop(),left:a.left-(parseInt(this.helper.css("left"),10)||0)+this.scrollParent.scrollLeft()}}return{top:0,left:0}},_cacheMargins:function(){this.margins={left:parseInt(this.currentItem.css("marginLeft"),10)||0,top:parseInt(this.currentItem.css("marginTop"),10)||0}},_cacheHelperProportions:function(){this.helperProportions={width:this.helper.outerWidth(),height:this.helper.outerHeight()}},_setContainment:function(){var b=this.options;if("parent"==b.containment&&(b.containment=this.helper[0].parentNode),("document"==b.containment||"window"==b.containment)&&(this.containment=[0-this.offset.relative.left-this.offset.parent.left,0-this.offset.relative.top-this.offset.parent.top,a("document"==b.containment?document:window).width()-this.helperProportions.width-this.margins.left,(a("document"==b.containment?document:window).height()||document.body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top]),!/^(document|window|parent)$/.test(b.containment)){var c=a(b.containment)[0],d=a(b.containment).offset(),e="hidden"!=a(c).css("overflow");this.containment=[d.left+(parseInt(a(c).css("borderLeftWidth"),10)||0)+(parseInt(a(c).css("paddingLeft"),10)||0)-this.margins.left,d.top+(parseInt(a(c).css("borderTopWidth"),10)||0)+(parseInt(a(c).css("paddingTop"),10)||0)-this.margins.top,d.left+(e?Math.max(c.scrollWidth,c.offsetWidth):c.offsetWidth)-(parseInt(a(c).css("borderLeftWidth"),10)||0)-(parseInt(a(c).css("paddingRight"),10)||0)-this.helperProportions.width-this.margins.left,d.top+(e?Math.max(c.scrollHeight,c.offsetHeight):c.offsetHeight)-(parseInt(a(c).css("borderTopWidth"),10)||0)-(parseInt(a(c).css("paddingBottom"),10)||0)-this.helperProportions.height-this.margins.top]}},_convertPositionTo:function(b,c){c||(c=this.position);var d="absolute"==b?1:-1,e=(this.options,"absolute"!=this.cssPosition||this.scrollParent[0]!=document&&a.ui.contains(this.scrollParent[0],this.offsetParent[0])?this.scrollParent:this.offsetParent),f=/(html|body)/i.test(e[0].tagName);return{top:c.top+this.offset.relative.top*d+this.offset.parent.top*d-(a.browser.safari&&"fixed"==this.cssPosition?0:("fixed"==this.cssPosition?-this.scrollParent.scrollTop():f?0:e.scrollTop())*d),left:c.left+this.offset.relative.left*d+this.offset.parent.left*d-(a.browser.safari&&"fixed"==this.cssPosition?0:("fixed"==this.cssPosition?-this.scrollParent.scrollLeft():f?0:e.scrollLeft())*d)}},_generatePosition:function(b){var c=this.options,d="absolute"!=this.cssPosition||this.scrollParent[0]!=document&&a.ui.contains(this.scrollParent[0],this.offsetParent[0])?this.scrollParent:this.offsetParent,e=/(html|body)/i.test(d[0].tagName);"relative"!=this.cssPosition||this.scrollParent[0]!=document&&this.scrollParent[0]!=this.offsetParent[0]||(this.offset.relative=this._getRelativeOffset());var f=b.pageX,g=b.pageY;if(this.originalPosition&&(this.containment&&(b.pageX-this.offset.click.left<this.containment[0]&&(f=this.containment[0]+this.offset.click.left),b.pageY-this.offset.click.top<this.containment[1]&&(g=this.containment[1]+this.offset.click.top),b.pageX-this.offset.click.left>this.containment[2]&&(f=this.containment[2]+this.offset.click.left),b.pageY-this.offset.click.top>this.containment[3]&&(g=this.containment[3]+this.offset.click.top)),c.grid)){var h=this.originalPageY+Math.round((g-this.originalPageY)/c.grid[1])*c.grid[1];g=this.containment&&(h-this.offset.click.top<this.containment[1]||h-this.offset.click.top>this.containment[3])?h-this.offset.click.top<this.containment[1]?h+c.grid[1]:h-c.grid[1]:h;var i=this.originalPageX+Math.round((f-this.originalPageX)/c.grid[0])*c.grid[0];f=this.containment&&(i-this.offset.click.left<this.containment[0]||i-this.offset.click.left>this.containment[2])?i-this.offset.click.left<this.containment[0]?i+c.grid[0]:i-c.grid[0]:i}return{top:g-this.offset.click.top-this.offset.relative.top-this.offset.parent.top+(a.browser.safari&&"fixed"==this.cssPosition?0:"fixed"==this.cssPosition?-this.scrollParent.scrollTop():e?0:d.scrollTop()),left:f-this.offset.click.left-this.offset.relative.left-this.offset.parent.left+(a.browser.safari&&"fixed"==this.cssPosition?0:"fixed"==this.cssPosition?-this.scrollParent.scrollLeft():e?0:d.scrollLeft())}},_rearrange:function(a,b,c,d){c?c[0].appendChild(this.placeholder[0]):b.item[0].parentNode.insertBefore(this.placeholder[0],"down"==this.direction?b.item[0]:b.item[0].nextSibling),this.counter=this.counter?++this.counter:1;var e=this,f=this.counter;window.setTimeout(function(){f==e.counter&&e.refreshPositions(!d)},0)},_clear:function(b,c){this.reverting=!1;var d=[];if(!this._noFinalSort&&this.currentItem.parent().length&&this.placeholder.before(this.currentItem),this._noFinalSort=null,this.helper[0]==this.currentItem[0]){for(var e in this._storedCSS)("auto"==this._storedCSS[e]||"static"==this._storedCSS[e])&&(this._storedCSS[e]="");this.currentItem.css(this._storedCSS).removeClass("ui-sortable-helper")}else this.currentItem.show();this.fromOutside&&!c&&d.push(function(a){this._trigger("receive",a,this._uiHash(this.fromOutside))}),!this.fromOutside&&this.domPosition.prev==this.currentItem.prev().not(".ui-sortable-helper")[0]&&this.domPosition.parent==this.currentItem.parent()[0]||c||d.push(function(a){this._trigger("update",a,this._uiHash())}),this!==this.currentContainer&&(c||(d.push(function(a){this._trigger("remove",a,this._uiHash())}),d.push(function(a){return function(b){a._trigger("receive",b,this._uiHash(this))}}.call(this,this.currentContainer)),d.push(function(a){return function(b){a._trigger("update",b,this._uiHash(this))}}.call(this,this.currentContainer))));for(var e=this.containers.length-1;e>=0;e--)c||d.push(function(a){return function(b){a._trigger("deactivate",b,this._uiHash(this))}}.call(this,this.containers[e])),this.containers[e].containerCache.over&&(d.push(function(a){return function(b){a._trigger("out",b,this._uiHash(this))}}.call(this,this.containers[e])),this.containers[e].containerCache.over=0);if(this._storedCursor&&a("body").css("cursor",this._storedCursor),this._storedOpacity&&this.helper.css("opacity",this._storedOpacity),this._storedZIndex&&this.helper.css("zIndex","auto"==this._storedZIndex?"":this._storedZIndex),this.dragging=!1,this.cancelHelperRemoval){if(!c){this._trigger("beforeStop",b,this._uiHash());for(var e=0;e<d.length;e++)d[e].call(this,b);this._trigger("stop",b,this._uiHash())}return this.fromOutside=!1,!1}if(c||this._trigger("beforeStop",b,this._uiHash()),this.placeholder[0].parentNode.removeChild(this.placeholder[0]),this.helper[0]!=this.currentItem[0]&&this.helper.remove(),this.helper=null,!c){for(var e=0;e<d.length;e++)d[e].call(this,b);this._trigger("stop",b,this._uiHash())}return this.fromOutside=!1,!0},_trigger:function(){a.Widget.prototype._trigger.apply(this,arguments)===!1&&this.cancel()},_uiHash:function(b){var c=b||this;return{helper:c.helper,placeholder:c.placeholder||a([]),position:c.position,originalPosition:c.originalPosition,offset:c.positionAbs,item:c.currentItem,sender:b?b.element:null}}}),a.extend(a.ui.sortable,{version:"1.8.24"})}(jQuery),jQuery.noConflict(),function(a){function b(){if(a.fn.ajaxSubmit.debug){var b="[jquery.form] "+Array.prototype.join.call(arguments,"");window.console&&window.console.log?window.console.log(b):window.opera&&window.opera.postError&&window.opera.postError(b)}}a.fn.ajaxSubmit=function(c){function d(){function d(){var b=m.attr("target"),c=m.attr("action");f.setAttribute("target",h),"POST"!=f.getAttribute("method")&&f.setAttribute("method","POST"),f.getAttribute("action")!=g.url&&f.setAttribute("action",g.url),g.skipEncodingOverride||m.attr({encoding:"multipart/form-data",enctype:"multipart/form-data"}),g.timeout&&setTimeout(function(){n=!0,e()},g.timeout);var d=[];try{if(g.extraData)for(var k in g.extraData)d.push(a('<input type="hidden" name="'+k+'" value="'+g.extraData[k]+'" />').appendTo(f)[0]);i.appendTo("body"),j.attachEvent?j.attachEvent("onload",e):j.addEventListener("load",e,!1),f.submit()}finally{f.setAttribute("action",c),b?f.setAttribute("target",b):m.removeAttr("target"),a(d).remove()}}function e(){if(!k.aborted){var c=j.contentWindow?j.contentWindow.document:j.contentDocument?j.contentDocument:j.document;if(c&&c.location.href!=g.iframeSrc){j.detachEvent?j.detachEvent("onload",e):j.removeEventListener("load",e,!1);var d=!0;try{if(n)throw"timeout";var f="xml"==g.dataType||c.XMLDocument||a.isXMLDoc(c);if(b("isXml="+f),!f&&window.opera&&(null==c.body||""==c.body.innerHTML)&&--r)return b("requeing onLoad callback, DOM not available"),void setTimeout(e,250);k.responseText=c.body?c.body.innerHTML:c.documentElement?c.documentElement.innerHTML:null,k.responseXML=c.XMLDocument?c.XMLDocument:c,k.getResponseHeader=function(a){var b={"content-type":g.dataType};return b[a]};var h=/(json|script)/.test(g.dataType);if(h||g.textarea){var m=c.getElementsByTagName("textarea")[0];if(m)k.responseText=m.value;else if(h){var o=c.getElementsByTagName("pre")[0],p=c.getElementsByTagName("body")[0];o?k.responseText=o.textContent:p&&(k.responseText=p.innerHTML)}}else"xml"!=g.dataType||k.responseXML||null==k.responseText||(k.responseXML=s(k.responseText));q=u(k,g.dataType,g)}catch(t){b("error caught:",t),d=!1,k.error=t,g.error&&g.error.call(g.context,k,"error",t),l&&a.event.trigger("ajaxError",[k,g,t])}k.aborted&&(b("upload aborted"),d=!1),d&&(g.success&&g.success.call(g.context,q,"success",k),l&&a.event.trigger("ajaxSuccess",[k,g])),l&&a.event.trigger("ajaxComplete",[k,g]),l&&!--a.active&&a.event.trigger("ajaxStop"),g.complete&&g.complete.call(g.context,k,d?"success":"error"),setTimeout(function(){i.removeData("form-plugin-onload"),i.remove(),k.responseXML=null},100)}}}var f=m[0];if(a(":input[name=submit],:input[id=submit]",f).length)return void alert('Error: Form elements must not have name or id of "submit".');var g=a.extend(!0,{},a.ajaxSettings,c);g.context=g.context||g;var h="jqFormIO"+(new Date).getTime(),i=a('<iframe id="'+h+'" name="'+h+'" src="'+g.iframeSrc+'" />'),j=i[0];i.css({position:"absolute",top:"-1000px",left:"-1000px"});var k={aborted:0,responseText:null,responseXML:null,status:0,statusText:"n/a",getAllResponseHeaders:function(){},getResponseHeader:function(){},setRequestHeader:function(){},abort:function(){b("aborting upload...");var c="aborted";this.aborted=1,i.attr("src",g.iframeSrc),k.error=c,g.error&&g.error.call(g.context,k,"error",c),l&&a.event.trigger("ajaxError",[k,g,c]),g.complete&&g.complete.call(g.context,k,"error")}},l=g.global;if(l&&!a.active++&&a.event.trigger("ajaxStart"),l&&a.event.trigger("ajaxSend",[k,g]),g.beforeSend&&g.beforeSend.call(g.context,k,g)===!1)return void(g.global&&a.active--);if(!k.aborted){var n=0,o=f.clk;if(o){var p=o.name;p&&!o.disabled&&(g.extraData=g.extraData||{},g.extraData[p]=o.value,"image"==o.type&&(g.extraData[p+".x"]=f.clk_x,g.extraData[p+".y"]=f.clk_y))}g.forceSync?d():setTimeout(d,10);var q,r=50,s=a.parseXML||function(a,b){return window.ActiveXObject?(b=new ActiveXObject("Microsoft.XMLDOM"),b.async="false",b.loadXML(a)):b=(new DOMParser).parseFromString(a,"text/xml"),b&&b.documentElement&&"parsererror"!=b.documentElement.nodeName?b:null},t=a.parseJSON||function(a){return window.eval("("+a+")")},u=function(b,c,d){var e=b.getResponseHeader("content-type")||"",f="xml"===c||!c&&e.indexOf("xml")>=0,g=f?b.responseXML:b.responseText;return f&&"parsererror"===g.documentElement.nodeName&&a.error&&a.error("parsererror"),d&&d.dataFilter&&(g=d.dataFilter(g,c)),"string"==typeof g&&("json"===c||!c&&e.indexOf("json")>=0?g=t(g):("script"===c||!c&&e.indexOf("javascript")>=0)&&a.globalEval(g)),g}}}if(!this.length)return b("ajaxSubmit: skipping submit process - no element selected"),this;"function"==typeof c&&(c={success:c});var e=this.attr("action"),f="string"==typeof e?a.trim(e):"";f&&(f=(f.match(/^([^#]+)/)||[])[1]),f=f||window.location.href||"",c=a.extend(!0,{url:f,type:this[0].getAttribute("method")||"GET",iframeSrc:/^https/i.test(window.location.href||"")?"javascript:false":"about:blank"},c);var g={};if(this.trigger("form-pre-serialize",[this,c,g]),g.veto)return b("ajaxSubmit: submit vetoed via form-pre-serialize trigger"),this;if(c.beforeSerialize&&c.beforeSerialize(this,c)===!1)return b("ajaxSubmit: submit aborted via beforeSerialize callback"),this;var h,i,j=this.formToArray(c.semantic);if(c.data){c.extraData=c.data;for(h in c.data)if(c.data[h]instanceof Array)for(var k in c.data[h])j.push({name:h,value:c.data[h][k]});else i=c.data[h],i=a.isFunction(i)?i():i,j.push({name:h,value:i})}if(c.beforeSubmit&&c.beforeSubmit(j,this,c)===!1)return b("ajaxSubmit: submit aborted via beforeSubmit callback"),this;if(this.trigger("form-submit-validate",[j,this,c,g]),g.veto)return b("ajaxSubmit: submit vetoed via form-submit-validate trigger"),this;var l=a.param(j);"GET"==c.type.toUpperCase()?(c.url+=(c.url.indexOf("?")>=0?"&":"?")+l,c.data=null):c.data=l;var m=this,n=[];if(c.resetForm&&n.push(function(){m.resetForm()}),c.clearForm&&n.push(function(){m.clearForm()}),!c.dataType&&c.target){var o=c.success||function(){};n.push(function(b){var d=c.replaceTarget?"replaceWith":"html";a(c.target)[d](b).each(o,arguments)})}else c.success&&n.push(c.success);c.success=function(a,b,d){for(var e=c.context||c,f=0,g=n.length;g>f;f++)n[f].apply(e,[a,b,d||m,m])};var p=a("input:file",this).length>0,q="multipart/form-data",r=m.attr("enctype")==q||m.attr("encoding")==q;return c.iframe!==!1&&(p||c.iframe||r)?c.closeKeepAlive?a.get(c.closeKeepAlive,d):d():a.ajax(c),this.trigger("form-submit-notify",[this,c]),this},a.fn.ajaxForm=function(c){if(0===this.length){var d={s:this.selector,c:this.context};return!a.isReady&&d.s?(b("DOM not ready, queuing ajaxForm"),a(function(){a(d.s,d.c).ajaxForm(c)}),this):(b("terminating; zero elements found by selector"+(a.isReady?"":" (DOM not ready)")),this)}return this.ajaxFormUnbind().bind("submit.form-plugin",function(b){b.isDefaultPrevented()||(b.preventDefault(),a(this).ajaxSubmit(c))}).bind("click.form-plugin",function(b){var c=b.target,d=a(c);if(!d.is(":submit,input:image")){var e=d.closest(":submit");if(0==e.length)return;c=e[0]}var f=this;if(f.clk=c,"image"==c.type)if(void 0!=b.offsetX)f.clk_x=b.offsetX,f.clk_y=b.offsetY;else if("function"==typeof a.fn.offset){var g=d.offset();f.clk_x=b.pageX-g.left,f.clk_y=b.pageY-g.top}else f.clk_x=b.pageX-c.offsetLeft,f.clk_y=b.pageY-c.offsetTop;setTimeout(function(){f.clk=f.clk_x=f.clk_y=null},100)})},a.fn.ajaxFormUnbind=function(){return this.unbind("submit.form-plugin click.form-plugin")},a.fn.formToArray=function(b){var c=[];if(0===this.length)return c;var d=this[0],e=b?d.getElementsByTagName("*"):d.elements;if(!e)return c;var f,g,h,i,j,k,l;for(f=0,k=e.length;k>f;f++)if(j=e[f],h=j.name)if(b&&d.clk&&"image"==j.type)j.disabled||d.clk!=j||(c.push({name:h,value:a(j).val()}),c.push({name:h+".x",value:d.clk_x},{name:h+".y",value:d.clk_y}));else if(i=a.fieldValue(j,!0),i&&i.constructor==Array)for(g=0,l=i.length;l>g;g++)c.push({name:h,value:i[g]});else null!==i&&"undefined"!=typeof i&&c.push({name:h,value:i});if(!b&&d.clk){var m=a(d.clk),n=m[0];h=n.name,h&&!n.disabled&&"image"==n.type&&(c.push({name:h,value:m.val()}),c.push({name:h+".x",value:d.clk_x},{name:h+".y",value:d.clk_y}))}return c},a.fn.formSerialize=function(b){return a.param(this.formToArray(b))},a.fn.fieldSerialize=function(b){var c=[];return this.each(function(){var d=this.name;if(d){var e=a.fieldValue(this,b);if(e&&e.constructor==Array)for(var f=0,g=e.length;g>f;f++)c.push({name:d,value:e[f]});else null!==e&&"undefined"!=typeof e&&c.push({name:this.name,value:e})}}),a.param(c)},a.fn.fieldValue=function(b){for(var c=[],d=0,e=this.length;e>d;d++){var f=this[d],g=a.fieldValue(f,b);null===g||"undefined"==typeof g||g.constructor==Array&&!g.length||(g.constructor==Array?a.merge(c,g):c.push(g))}return c},a.fieldValue=function(b,c){var d=b.name,e=b.type,f=b.tagName.toLowerCase();if(void 0===c&&(c=!0),c&&(!d||b.disabled||"reset"==e||"button"==e||("checkbox"==e||"radio"==e)&&!b.checked||("submit"==e||"image"==e)&&b.form&&b.form.clk!=b||"select"==f&&-1==b.selectedIndex))return null;if("select"==f){var g=b.selectedIndex;if(0>g)return null;for(var h=[],i=b.options,j="select-one"==e,k=j?g+1:i.length,l=j?g:0;k>l;l++){var m=i[l];if(m.selected){var n=m.value;if(n||(n=m.attributes&&m.attributes.value&&!m.attributes.value.specified?m.text:m.value),j)return n;h.push(n)}}return h}return a(b).val()},a.fn.clearForm=function(){return this.each(function(){a("input,select,textarea",this).clearFields()})},a.fn.clearFields=a.fn.clearInputs=function(){return this.each(function(){var a=this.type,b=this.tagName.toLowerCase();"text"==a||"password"==a||"textarea"==b?this.value="":"checkbox"==a||"radio"==a?this.checked=!1:"select"==b&&(this.selectedIndex=-1)})},a.fn.resetForm=function(){return this.each(function(){("function"==typeof this.reset||"object"==typeof this.reset&&!this.reset.nodeType)&&this.reset()})},a.fn.enable=function(a){return void 0===a&&(a=!0),this.each(function(){this.disabled=!a})},a.fn.selected=function(b){return void 0===b&&(b=!0),this.each(function(){var c=this.type;if("checkbox"==c||"radio"==c)this.checked=b;else if("option"==this.tagName.toLowerCase()){var d=a(this).parent("select");b&&d[0]&&"select-one"==d[0].type&&d.find("option").selected(!1),this.selected=b}})}}(jQuery),function(){var _after=1,_afterThrow=2,_afterFinally=3,_before=4,_around=5,_intro=6,_regexEnabled=!0,_arguments="arguments",_undef="undefined",getType=function(){for(var a=Object.prototype.toString,b={},c={1:"element",3:"textnode",9:"document",11:"fragment"},d="Arguments Array Boolean Date Document Element Error Fragment Function NodeList Null Number Object RegExp String TextNode Undefined Window".split(" "),e=d.length;e--;){var f=d[e],g=window[f];if(g)try{b[a.call(new g)]=f.toLowerCase()}catch(h){}}return function(d){return null==d&&(void 0===d?_undef:"null")||d.nodeType&&c[d.nodeType]||"number"==typeof d.length&&(d.callee&&_arguments||d.alert&&"window"||d.item&&"nodelist")||b[a.call(d)]}}(),isFunc=function(a){return"function"==getType(a)},weaveOne=function(source,method,advice){var old=source[method];if(advice.type!=_intro&&!isFunc(old)){var oldObject=old;old=function(){for(var code=arguments.length>0?_arguments+"[0]":"",i=1;i<arguments.length;i++)code+=","+_arguments+"["+i+"]";return eval("oldObject("+code+");")}}var aspect;return advice.type==_after||advice.type==_afterThrow||advice.type==_afterFinally?aspect=function(){var a,b=null;try{a=old.apply(this,arguments)}catch(c){b=c}if(advice.type==_after){if(null!=b)throw b;a=advice.value.apply(this,[a,method])}else advice.type==_afterThrow&&null!=b?a=advice.value.apply(this,[b,method]):advice.type==_afterFinally&&(a=advice.value.apply(this,[a,b,method]));return a}:advice.type==_before?aspect=function(){return advice.value.apply(this,[arguments,method]),old.apply(this,arguments)}:advice.type==_intro?aspect=function(){return advice.value.apply(this,arguments)}:advice.type==_around&&(aspect=function(){var a={object:this,args:Array.prototype.slice.call(arguments)};return advice.value.apply(a.object,[{arguments:a.args,method:method,proceed:function(){return old.apply(a.object,a.args)}}])}),aspect.unweave=function(){source[method]=old,pointcut=source=aspect=old=null},source[method]=aspect,aspect},search=function(a,b,c){var d=[];for(var e in a){var f=null;try{f=a[e]}catch(g){}null!=f&&e.match(b.method)&&isFunc(f)&&(d[d.length]={source:a,method:e,advice:c})}return d},weave=function(a,b){var c=typeof a.target.prototype!=_undef?a.target.prototype:a.target,d=[];if(b.type!=_intro&&typeof c[a.method]==_undef){var e=search(a.target,a,b);0==e.length&&(e=search(c,a,b));for(var f in e)d[d.length]=weaveOne(e[f].source,e[f].method,e[f].advice)}else d[0]=weaveOne(c,a.method,b);return _regexEnabled?d:d[0]};jQuery.aop={after:function(a,b){return weave(a,{type:_after,value:b})},afterThrow:function(a,b){return weave(a,{type:_afterThrow,value:b})},afterFinally:function(a,b){return weave(a,{type:_afterFinally,value:b})},before:function(a,b){return weave(a,{type:_before,value:b})},around:function(a,b){return weave(a,{type:_around,value:b})},introduction:function(a,b){return weave(a,{type:_intro,value:b})},setup:function(a){_regexEnabled=a.regexMatch}}}(),window.Raphael&&(Raphael.shadow=function(a,b,c,d,e){e=e||{};var f,g,h,i=jQuery(e.target),j=jQuery("<div/>",{"class":"aui-shadow"}),k=e.shadow||e.color||"#000",l=10*e.size||0,m=e.offsetSize||3,n=e.zindex||0,o=e.radius||0,p="0.4",q=e.blur||3;return c+=l+2*q,d+=l+2*q,Raphael.shadow.BOX_SHADOW_SUPPORT?(i.addClass("aui-box-shadow"),j.addClass("hidden")):(0===a&&0===b&&i.length>0&&(h=i.offset(),a=m-q+h.left,b=m-q+h.top),jQuery.browser.msie&&jQuery.browser.version<"9"&&(k="#f0f0f0",p="0.2"),j.css({position:"absolute",left:a,top:b,width:c,height:d,zIndex:n}),i.length>0?(j.appendTo(document.body),f=Raphael(j[0],c,d,o)):f=Raphael(a,b,c,d,o),f.canvas.style.position="absolute",g=f.rect(q,q,c-2*q,d-2*q).attr({fill:k,stroke:k,blur:""+q,opacity:p}),j)},Raphael.shadow.BOX_SHADOW_SUPPORT=function(){for(var a=document.documentElement.style,b=["boxShadow","MozBoxShadow","WebkitBoxShadow","msBoxShadow"],c=0;c<b.length;c++)if(b[c]in a)return!0;return!1}()),jQuery.os={};var jQueryOSplatform=navigator.platform.toLowerCase();jQuery.os.windows=-1!=jQueryOSplatform.indexOf("win"),jQuery.os.mac=-1!=jQueryOSplatform.indexOf("mac"),jQuery.os.linux=-1!=jQueryOSplatform.indexOf("linux"),function(a){function b(a){this.num=0,this.timer=a>0?a:!1}function c(c){if(a.isPlainObject(c.data)||a.isArray(c.data)||"string"==typeof c.data){var e=c.handler,f={timer:700};!function(b){"string"==typeof b?f.combo=[b]:a.isArray(b)?f.combo=b:a.extend(f,b),f.combo=a.map(f.combo,function(a){return a.toLowerCase()})}(c.data),c.index=new b(f.timer),c.handler=function(b){if(this===b.target||!/textarea|select|input/i.test(b.target.nodeName)){var g="keypress"!==b.type?a.hotkeys.specialKeys[b.which]:null,h=String.fromCharCode(b.which).toLowerCase(),i="",j={};b.altKey&&"alt"!==g&&(i+="alt+"),b.ctrlKey&&"ctrl"!==g&&(i+="ctrl+"),b.metaKey&&!b.ctrlKey&&"meta"!==g&&(i+="meta+"),b.shiftKey&&"shift"!==g&&(i+="shift+"),b.metaKey&&"["===h&&(h=null),g&&(j[i+g]=!0),h&&(j[i+h]=!0),/shift+/.test(i)&&(j[i.replace("shift+","")+a.hotkeys.shiftNums[g||h]]=!0);var k=c.index,l=f.combo;if(d(l[k.val()],j)){if(k.val()===l.length-1)return k.reset(),e.apply(this,arguments);k.inc()}else k.reset(),d(l[0],j)&&k.inc()}}}}function d(a,b){for(var c=a.split(" "),d=0,e=c.length;e>d;d++)if(b[c[d]])return!0;return!1}a.hotkeys={version:"0.8",specialKeys:{8:"backspace",9:"tab",13:"return",16:"shift",17:"ctrl",18:"alt",19:"pause",20:"capslock",27:"esc",32:"space",33:"pageup",34:"pagedown",35:"end",36:"home",37:"left",38:"up",39:"right",40:"down",45:"insert",46:"del",91:"meta",96:"0",97:"1",98:"2",99:"3",100:"4",101:"5",102:"6",103:"7",104:"8",105:"9",106:"*",107:"+",109:"-",110:".",111:"/",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:"scroll",188:",",190:".",191:"/",224:"meta",219:"[",221:"]"},keypressKeys:["<",">","?"],shiftNums:{"`":"~",1:"!",2:"@",3:"#",4:"$",5:"%",6:"^",7:"&",8:"*",9:"(",0:")","-":"_","=":"+",";":":","'":'"',",":"<",".":">","/":"?","\\":"|"}},a.each(a.hotkeys.keypressKeys,function(b,c){a.hotkeys.shiftNums[c]=c}),b.prototype.val=function(){return this.num},b.prototype.inc=function(){this.timer&&(clearTimeout(this.timeout),this.timeout=setTimeout(a.proxy(b.prototype.reset,this),this.timer)),this.num++},b.prototype.reset=function(){this.timer&&clearTimeout(this.timeout),this.num=0},a.each(["keydown","keyup","keypress"],function(){a.event.special[this]={add:c}})}(jQuery),jQuery.fn.moveTo=function(a){var b,c={transition:!1,scrollOffset:35},d=jQuery.extend(c,a),e=this,f=e.offset().top;if((jQuery(window).scrollTop()+jQuery(window).height()-this.outerHeight()<f||jQuery(window).scrollTop()+d.scrollOffset>f)&&jQuery(window).height()>d.scrollOffset){if(b=jQuery(window).scrollTop()+d.scrollOffset>f?f-(jQuery(window).height()-this.outerHeight())+d.scrollOffset:f-d.scrollOffset,!jQuery.fn.moveTo.animating&&d.transition)return jQuery(document).trigger("moveToStarted",this),jQuery.fn.moveTo.animating=!0,jQuery("html,body").animate({scrollTop:b},1e3,function(){jQuery(document).trigger("moveToFinished",e),delete jQuery.fn.moveTo.animating}),this;var g=jQuery("html, body");return g.is(":animated")&&(g.stop(),delete jQuery.fn.moveTo.animating),jQuery(document).trigger("moveToStarted"),jQuery(window).scrollTop(b),setTimeout(function(){jQuery(document).trigger("moveToFinished",e) },100),this}return jQuery(document).trigger("moveToFinished",this),this},function($,undefined){function Datepicker(){this.debug=!1,this._curInst=null,this._keyEvent=!1,this._disabledInputs=[],this._datepickerShowing=!1,this._inDialog=!1,this._mainDivId="ui-datepicker-div",this._inlineClass="ui-datepicker-inline",this._appendClass="ui-datepicker-append",this._triggerClass="ui-datepicker-trigger",this._dialogClass="ui-datepicker-dialog",this._disableClass="ui-datepicker-disabled",this._unselectableClass="ui-datepicker-unselectable",this._currentClass="ui-datepicker-current-day",this._dayOverClass="ui-datepicker-days-cell-over",this.regional=[],this.regional[""]={closeText:"Done",prevText:"Prev",nextText:"Next",currentText:"Today",monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],monthNamesShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayNamesShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],dayNamesMin:["Su","Mo","Tu","We","Th","Fr","Sa"],weekHeader:"Wk",dateFormat:"mm/dd/yy",firstDay:0,isRTL:!1,showMonthAfterYear:!1,yearSuffix:""},this._defaults={showOn:"focus",showAnim:"fadeIn",showOptions:{},defaultDate:null,appendText:"",buttonText:"...",buttonImage:"",buttonImageOnly:!1,hideIfNoPrevNext:!1,navigationAsDateFormat:!1,gotoCurrent:!1,changeMonth:!1,changeYear:!1,yearRange:"c-10:c+10",showOtherMonths:!1,selectOtherMonths:!1,showWeek:!1,calculateWeek:this.iso8601Week,shortYearCutoff:"+10",minDate:null,maxDate:null,duration:"fast",beforeShowDay:null,beforeShow:null,onSelect:null,onChangeMonthYear:null,onClose:null,numberOfMonths:1,showCurrentAtPos:0,stepMonths:1,stepBigMonths:12,altField:"",altFormat:"",constrainInput:!0,showButtonPanel:!1,autoSize:!1,disabled:!1},$.extend(this._defaults,this.regional[""]),this.dpDiv=bindHover($('<div id="'+this._mainDivId+'" class="ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all"></div>'))}function bindHover(a){var b="button, .ui-datepicker-prev, .ui-datepicker-next, .ui-datepicker-calendar td a";return a.bind("mouseout",function(a){var c=$(a.target).closest(b);c.length&&c.removeClass("ui-state-hover ui-datepicker-prev-hover ui-datepicker-next-hover")}).bind("mouseover",function(c){var d=$(c.target).closest(b);!$.datepicker._isDisabledDatepicker(instActive.inline?a.parent()[0]:instActive.input[0])&&d.length&&(d.parents(".ui-datepicker-calendar").find("a").removeClass("ui-state-hover"),d.addClass("ui-state-hover"),d.hasClass("ui-datepicker-prev")&&d.addClass("ui-datepicker-prev-hover"),d.hasClass("ui-datepicker-next")&&d.addClass("ui-datepicker-next-hover"))})}function extendRemove(a,b){$.extend(a,b);for(var c in b)(null==b[c]||b[c]==undefined)&&(a[c]=b[c]);return a}function isArray(a){return a&&($.browser.safari&&"object"==typeof a&&a.length||a.constructor&&a.constructor.toString().match(/\Array\(\)/))}$.extend($.ui,{datepicker:{version:"1.8.24"}});var PROP_NAME="datepicker",dpuuid=(new Date).getTime(),instActive;$.extend(Datepicker.prototype,{markerClassName:"hasDatepicker",maxRows:4,log:function(){this.debug&&console.log.apply("",arguments)},_widgetDatepicker:function(){return this.dpDiv},setDefaults:function(a){return extendRemove(this._defaults,a||{}),this},_attachDatepicker:function(target,settings){var inlineSettings=null;for(var attrName in this._defaults){var attrValue=target.getAttribute("date:"+attrName);if(attrValue){inlineSettings=inlineSettings||{};try{inlineSettings[attrName]=eval(attrValue)}catch(err){inlineSettings[attrName]=attrValue}}}var nodeName=target.nodeName.toLowerCase(),inline="div"==nodeName||"span"==nodeName;target.id||(this.uuid+=1,target.id="dp"+this.uuid);var inst=this._newInst($(target),inline);inst.settings=$.extend({},settings||{},inlineSettings||{}),"input"==nodeName?this._connectDatepicker(target,inst):inline&&this._inlineDatepicker(target,inst)},_newInst:function(a,b){var c=a[0].id.replace(/([^A-Za-z0-9_-])/g,"\\\\$1");return{id:c,input:a,selectedDay:0,selectedMonth:0,selectedYear:0,drawMonth:0,drawYear:0,inline:b,dpDiv:b?bindHover($('<div class="'+this._inlineClass+' ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all"></div>')):this.dpDiv}},_connectDatepicker:function(a,b){var c=$(a);b.append=$([]),b.trigger=$([]),c.hasClass(this.markerClassName)||(this._attachments(c,b),c.addClass(this.markerClassName).keydown(this._doKeyDown).keypress(this._doKeyPress).keyup(this._doKeyUp).bind("setData.datepicker",function(a,c,d){b.settings[c]=d}).bind("getData.datepicker",function(a,c){return this._get(b,c)}),this._autoSize(b),$.data(a,PROP_NAME,b),b.settings.disabled&&this._disableDatepicker(a))},_attachments:function(a,b){var c=this._get(b,"appendText"),d=this._get(b,"isRTL");b.append&&b.append.remove(),c&&(b.append=$('<span class="'+this._appendClass+'">'+c+"</span>"),a[d?"before":"after"](b.append)),a.unbind("focus",this._showDatepicker),b.trigger&&b.trigger.remove();var e=this._get(b,"showOn");if(("focus"==e||"both"==e)&&a.focus(this._showDatepicker),"button"==e||"both"==e){var f=this._get(b,"buttonText"),g=this._get(b,"buttonImage");b.trigger=$(this._get(b,"buttonImageOnly")?$("<img/>").addClass(this._triggerClass).attr({src:g,alt:f,title:f}):$('<button type="button"></button>').addClass(this._triggerClass).html(""==g?f:$("<img/>").attr({src:g,alt:f,title:f}))),a[d?"before":"after"](b.trigger),b.trigger.click(function(){return $.datepicker._datepickerShowing&&$.datepicker._lastInput==a[0]?$.datepicker._hideDatepicker():$.datepicker._datepickerShowing&&$.datepicker._lastInput!=a[0]?($.datepicker._hideDatepicker(),$.datepicker._showDatepicker(a[0])):$.datepicker._showDatepicker(a[0]),!1})}},_autoSize:function(a){if(this._get(a,"autoSize")&&!a.inline){var b=new Date(2009,11,20),c=this._get(a,"dateFormat");if(c.match(/[DM]/)){var d=function(a){for(var b=0,c=0,d=0;d<a.length;d++)a[d].length>b&&(b=a[d].length,c=d);return c};b.setMonth(d(this._get(a,c.match(/MM/)?"monthNames":"monthNamesShort"))),b.setDate(d(this._get(a,c.match(/DD/)?"dayNames":"dayNamesShort"))+20-b.getDay())}a.input.attr("size",this._formatDate(a,b).length)}},_inlineDatepicker:function(a,b){var c=$(a);c.hasClass(this.markerClassName)||(c.addClass(this.markerClassName).append(b.dpDiv).bind("setData.datepicker",function(a,c,d){b.settings[c]=d}).bind("getData.datepicker",function(a,c){return this._get(b,c)}),$.data(a,PROP_NAME,b),this._setDate(b,this._getDefaultDate(b),!0),this._updateDatepicker(b),this._updateAlternate(b),b.settings.disabled&&this._disableDatepicker(a),b.dpDiv.css("display","block"))},_dialogDatepicker:function(a,b,c,d,e){var f=this._dialogInst;if(!f){this.uuid+=1;var g="dp"+this.uuid;this._dialogInput=$('<input type="text" id="'+g+'" style="position: absolute; top: -100px; width: 0px;"/>'),this._dialogInput.keydown(this._doKeyDown),$("body").append(this._dialogInput),f=this._dialogInst=this._newInst(this._dialogInput,!1),f.settings={},$.data(this._dialogInput[0],PROP_NAME,f)}if(extendRemove(f.settings,d||{}),b=b&&b.constructor==Date?this._formatDate(f,b):b,this._dialogInput.val(b),this._pos=e?e.length?e:[e.pageX,e.pageY]:null,!this._pos){var h=document.documentElement.clientWidth,i=document.documentElement.clientHeight,j=document.documentElement.scrollLeft||document.body.scrollLeft,k=document.documentElement.scrollTop||document.body.scrollTop;this._pos=[h/2-100+j,i/2-150+k]}return this._dialogInput.css("left",this._pos[0]+20+"px").css("top",this._pos[1]+"px"),f.settings.onSelect=c,this._inDialog=!0,this.dpDiv.addClass(this._dialogClass),this._showDatepicker(this._dialogInput[0]),$.blockUI&&$.blockUI(this.dpDiv),$.data(this._dialogInput[0],PROP_NAME,f),this},_destroyDatepicker:function(a){var b=$(a),c=$.data(a,PROP_NAME);if(b.hasClass(this.markerClassName)){var d=a.nodeName.toLowerCase();$.removeData(a,PROP_NAME),"input"==d?(c.append.remove(),c.trigger.remove(),b.removeClass(this.markerClassName).unbind("focus",this._showDatepicker).unbind("keydown",this._doKeyDown).unbind("keypress",this._doKeyPress).unbind("keyup",this._doKeyUp)):("div"==d||"span"==d)&&b.removeClass(this.markerClassName).empty()}},_enableDatepicker:function(a){var b=$(a),c=$.data(a,PROP_NAME);if(b.hasClass(this.markerClassName)){var d=a.nodeName.toLowerCase();if("input"==d)a.disabled=!1,c.trigger.filter("button").each(function(){this.disabled=!1}).end().filter("img").css({opacity:"1.0",cursor:""});else if("div"==d||"span"==d){var e=b.children("."+this._inlineClass);e.children().removeClass("ui-state-disabled"),e.find("select.ui-datepicker-month, select.ui-datepicker-year").removeAttr("disabled")}this._disabledInputs=$.map(this._disabledInputs,function(b){return b==a?null:b})}},_disableDatepicker:function(a){var b=$(a),c=$.data(a,PROP_NAME);if(b.hasClass(this.markerClassName)){var d=a.nodeName.toLowerCase();if("input"==d)a.disabled=!0,c.trigger.filter("button").each(function(){this.disabled=!0}).end().filter("img").css({opacity:"0.5",cursor:"default"});else if("div"==d||"span"==d){var e=b.children("."+this._inlineClass);e.children().addClass("ui-state-disabled"),e.find("select.ui-datepicker-month, select.ui-datepicker-year").attr("disabled","disabled")}this._disabledInputs=$.map(this._disabledInputs,function(b){return b==a?null:b}),this._disabledInputs[this._disabledInputs.length]=a}},_isDisabledDatepicker:function(a){if(!a)return!1;for(var b=0;b<this._disabledInputs.length;b++)if(this._disabledInputs[b]==a)return!0;return!1},_getInst:function(a){try{return $.data(a,PROP_NAME)}catch(b){throw"Missing instance data for this datepicker"}},_optionDatepicker:function(a,b,c){var d=this._getInst(a);if(2==arguments.length&&"string"==typeof b)return"defaults"==b?$.extend({},$.datepicker._defaults):d?"all"==b?$.extend({},d.settings):this._get(d,b):null;var e=b||{};if("string"==typeof b&&(e={},e[b]=c),d){this._curInst==d&&this._hideDatepicker();var f=this._getDateDatepicker(a,!0),g=this._getMinMaxDate(d,"min"),h=this._getMinMaxDate(d,"max");extendRemove(d.settings,e),null!==g&&e.dateFormat!==undefined&&e.minDate===undefined&&(d.settings.minDate=this._formatDate(d,g)),null!==h&&e.dateFormat!==undefined&&e.maxDate===undefined&&(d.settings.maxDate=this._formatDate(d,h)),this._attachments($(a),d),this._autoSize(d),this._setDate(d,f),this._updateAlternate(d),this._updateDatepicker(d)}},_changeDatepicker:function(a,b,c){this._optionDatepicker(a,b,c)},_refreshDatepicker:function(a){var b=this._getInst(a);b&&this._updateDatepicker(b)},_setDateDatepicker:function(a,b){var c=this._getInst(a);c&&(this._setDate(c,b),this._updateDatepicker(c),this._updateAlternate(c))},_getDateDatepicker:function(a,b){var c=this._getInst(a);return c&&!c.inline&&this._setDateFromField(c,b),c?this._getDate(c):null},_doKeyDown:function(a){var b=$.datepicker._getInst(a.target),c=!0,d=b.dpDiv.is(".ui-datepicker-rtl");if(b._keyEvent=!0,$.datepicker._datepickerShowing)switch(a.keyCode){case 9:$.datepicker._hideDatepicker(),c=!1;break;case 13:var e=$("td."+$.datepicker._dayOverClass+":not(."+$.datepicker._currentClass+")",b.dpDiv);e[0]&&$.datepicker._selectDay(a.target,b.selectedMonth,b.selectedYear,e[0]);var f=$.datepicker._get(b,"onSelect");if(f){var g=$.datepicker._formatDate(b);f.apply(b.input?b.input[0]:null,[g,b])}else $.datepicker._hideDatepicker();return!1;case 27:$.datepicker._hideDatepicker();break;case 33:$.datepicker._adjustDate(a.target,a.ctrlKey?-$.datepicker._get(b,"stepBigMonths"):-$.datepicker._get(b,"stepMonths"),"M");break;case 34:$.datepicker._adjustDate(a.target,a.ctrlKey?+$.datepicker._get(b,"stepBigMonths"):+$.datepicker._get(b,"stepMonths"),"M");break;case 35:(a.ctrlKey||a.metaKey)&&$.datepicker._clearDate(a.target),c=a.ctrlKey||a.metaKey;break;case 36:(a.ctrlKey||a.metaKey)&&$.datepicker._gotoToday(a.target),c=a.ctrlKey||a.metaKey;break;case 37:(a.ctrlKey||a.metaKey)&&$.datepicker._adjustDate(a.target,d?1:-1,"D"),c=a.ctrlKey||a.metaKey,a.originalEvent.altKey&&$.datepicker._adjustDate(a.target,a.ctrlKey?-$.datepicker._get(b,"stepBigMonths"):-$.datepicker._get(b,"stepMonths"),"M");break;case 38:(a.ctrlKey||a.metaKey)&&$.datepicker._adjustDate(a.target,-7,"D"),c=a.ctrlKey||a.metaKey;break;case 39:(a.ctrlKey||a.metaKey)&&$.datepicker._adjustDate(a.target,d?-1:1,"D"),c=a.ctrlKey||a.metaKey,a.originalEvent.altKey&&$.datepicker._adjustDate(a.target,a.ctrlKey?+$.datepicker._get(b,"stepBigMonths"):+$.datepicker._get(b,"stepMonths"),"M");break;case 40:(a.ctrlKey||a.metaKey)&&$.datepicker._adjustDate(a.target,7,"D"),c=a.ctrlKey||a.metaKey;break;default:c=!1}else 36==a.keyCode&&a.ctrlKey?$.datepicker._showDatepicker(this):c=!1;c&&(a.preventDefault(),a.stopPropagation())},_doKeyPress:function(a){var b=$.datepicker._getInst(a.target);if($.datepicker._get(b,"constrainInput")){var c=$.datepicker._possibleChars($.datepicker._get(b,"dateFormat")),d=String.fromCharCode(a.charCode==undefined?a.keyCode:a.charCode);return a.ctrlKey||a.metaKey||" ">d||!c||c.indexOf(d)>-1}},_doKeyUp:function(a){var b=$.datepicker._getInst(a.target);if(b.input.val()!=b.lastVal)try{var c=$.datepicker.parseDate($.datepicker._get(b,"dateFormat"),b.input?b.input.val():null,$.datepicker._getFormatConfig(b));c&&($.datepicker._setDateFromField(b),$.datepicker._updateAlternate(b),$.datepicker._updateDatepicker(b))}catch(d){$.datepicker.log(d)}return!0},_showDatepicker:function(a){if(a=a.target||a,"input"!=a.nodeName.toLowerCase()&&(a=$("input",a.parentNode)[0]),!$.datepicker._isDisabledDatepicker(a)&&$.datepicker._lastInput!=a){var b=$.datepicker._getInst(a);$.datepicker._curInst&&$.datepicker._curInst!=b&&($.datepicker._curInst.dpDiv.stop(!0,!0),b&&$.datepicker._datepickerShowing&&$.datepicker._hideDatepicker($.datepicker._curInst.input[0]));var c=$.datepicker._get(b,"beforeShow"),d=c?c.apply(a,[a,b]):{};if(d!==!1){extendRemove(b.settings,d),b.lastVal=null,$.datepicker._lastInput=a,$.datepicker._setDateFromField(b),$.datepicker._inDialog&&(a.value=""),$.datepicker._pos||($.datepicker._pos=$.datepicker._findPos(a),$.datepicker._pos[1]+=a.offsetHeight);var e=!1;$(a).parents().each(function(){return e|="fixed"==$(this).css("position"),!e}),e&&$.browser.opera&&($.datepicker._pos[0]-=document.documentElement.scrollLeft,$.datepicker._pos[1]-=document.documentElement.scrollTop);var f={left:$.datepicker._pos[0],top:$.datepicker._pos[1]};if($.datepicker._pos=null,b.dpDiv.empty(),b.dpDiv.css({position:"absolute",display:"block",top:"-1000px"}),$.datepicker._updateDatepicker(b),f=$.datepicker._checkOffset(b,f,e),b.dpDiv.css({position:$.datepicker._inDialog&&$.blockUI?"static":e?"fixed":"absolute",display:"none",left:f.left+"px",top:f.top+"px"}),!b.inline){var g=$.datepicker._get(b,"showAnim"),h=$.datepicker._get(b,"duration"),i=function(){var a=b.dpDiv.find("iframe.ui-datepicker-cover");if(a.length){var c=$.datepicker._getBorders(b.dpDiv);a.css({left:-c[0],top:-c[1],width:b.dpDiv.outerWidth(),height:b.dpDiv.outerHeight()})}};b.dpDiv.zIndex($(a).zIndex()+1),$.datepicker._datepickerShowing=!0,$.effects&&$.effects[g]?b.dpDiv.show(g,$.datepicker._get(b,"showOptions"),h,i):b.dpDiv[g||"show"](g?h:null,i),g&&h||i(),b.input.is(":visible")&&!b.input.is(":disabled")&&b.input.focus(),$.datepicker._curInst=b}}}},_updateDatepicker:function(a){var b=this;b.maxRows=4;var c=$.datepicker._getBorders(a.dpDiv);instActive=a,a.dpDiv.empty().append(this._generateHTML(a)),this._attachHandlers(a);var d=a.dpDiv.find("iframe.ui-datepicker-cover");d.length&&d.css({left:-c[0],top:-c[1],width:a.dpDiv.outerWidth(),height:a.dpDiv.outerHeight()}),a.dpDiv.find("."+this._dayOverClass+" a").mouseover();var e=this._getNumberOfMonths(a),f=e[1],g=17;if(a.dpDiv.removeClass("ui-datepicker-multi-2 ui-datepicker-multi-3 ui-datepicker-multi-4").width(""),f>1&&a.dpDiv.addClass("ui-datepicker-multi-"+f).css("width",g*f+"em"),a.dpDiv[(1!=e[0]||1!=e[1]?"add":"remove")+"Class"]("ui-datepicker-multi"),a.dpDiv[(this._get(a,"isRTL")?"add":"remove")+"Class"]("ui-datepicker-rtl"),a==$.datepicker._curInst&&$.datepicker._datepickerShowing&&a.input&&a.input.is(":visible")&&!a.input.is(":disabled")&&a.input[0]!=document.activeElement&&a.input.focus(),a.yearshtml){var h=a.yearshtml;setTimeout(function(){h===a.yearshtml&&a.yearshtml&&a.dpDiv.find("select.ui-datepicker-year:first").replaceWith(a.yearshtml),h=a.yearshtml=null},0)}},_getBorders:function(a){var b=function(a){return{thin:1,medium:2,thick:3}[a]||a};return[parseFloat(b(a.css("border-left-width"))),parseFloat(b(a.css("border-top-width")))]},_checkOffset:function(a,b,c){var d=a.dpDiv.outerWidth(),e=a.dpDiv.outerHeight(),f=a.input?a.input.outerWidth():0,g=a.input?a.input.outerHeight():0,h=document.documentElement.clientWidth+(c?0:$(document).scrollLeft()),i=document.documentElement.clientHeight+(c?0:$(document).scrollTop());return b.left-=this._get(a,"isRTL")?d-f:0,b.left-=c&&b.left==a.input.offset().left?$(document).scrollLeft():0,b.top-=c&&b.top==a.input.offset().top+g?$(document).scrollTop():0,b.left-=Math.min(b.left,b.left+d>h&&h>d?Math.abs(b.left+d-h):0),b.top-=Math.min(b.top,b.top+e>i&&i>e?Math.abs(e+g):0),b},_findPos:function(a){for(var b=this._getInst(a),c=this._get(b,"isRTL");a&&("hidden"==a.type||1!=a.nodeType||$.expr.filters.hidden(a));)a=a[c?"previousSibling":"nextSibling"];var d=$(a).offset();return[d.left,d.top]},_hideDatepicker:function(a){var b=this._curInst;if(b&&(!a||b==$.data(a,PROP_NAME))&&this._datepickerShowing){var c=this._get(b,"showAnim"),d=this._get(b,"duration"),e=function(){$.datepicker._tidyDialog(b)};$.effects&&$.effects[c]?b.dpDiv.hide(c,$.datepicker._get(b,"showOptions"),d,e):b.dpDiv["slideDown"==c?"slideUp":"fadeIn"==c?"fadeOut":"hide"](c?d:null,e),c||e(),this._datepickerShowing=!1;var f=this._get(b,"onClose");f&&f.apply(b.input?b.input[0]:null,[b.input?b.input.val():"",b]),this._lastInput=null,this._inDialog&&(this._dialogInput.css({position:"absolute",left:"0",top:"-100px"}),$.blockUI&&($.unblockUI(),$("body").append(this.dpDiv))),this._inDialog=!1}},_tidyDialog:function(a){a.dpDiv.removeClass(this._dialogClass).unbind(".ui-datepicker-calendar")},_checkExternalClick:function(a){if($.datepicker._curInst){var b=$(a.target),c=$.datepicker._getInst(b[0]);(b[0].id!=$.datepicker._mainDivId&&0==b.parents("#"+$.datepicker._mainDivId).length&&!b.hasClass($.datepicker.markerClassName)&&!b.closest("."+$.datepicker._triggerClass).length&&$.datepicker._datepickerShowing&&(!$.datepicker._inDialog||!$.blockUI)||b.hasClass($.datepicker.markerClassName)&&$.datepicker._curInst!=c)&&$.datepicker._hideDatepicker()}},_adjustDate:function(a,b,c){var d=$(a),e=this._getInst(d[0]);this._isDisabledDatepicker(d[0])||(this._adjustInstDate(e,b+("M"==c?this._get(e,"showCurrentAtPos"):0),c),this._updateDatepicker(e))},_gotoToday:function(a){var b=$(a),c=this._getInst(b[0]);if(this._get(c,"gotoCurrent")&&c.currentDay)c.selectedDay=c.currentDay,c.drawMonth=c.selectedMonth=c.currentMonth,c.drawYear=c.selectedYear=c.currentYear;else{var d=new Date;c.selectedDay=d.getDate(),c.drawMonth=c.selectedMonth=d.getMonth(),c.drawYear=c.selectedYear=d.getFullYear()}this._notifyChange(c),this._adjustDate(b)},_selectMonthYear:function(a,b,c){var d=$(a),e=this._getInst(d[0]);e["selected"+("M"==c?"Month":"Year")]=e["draw"+("M"==c?"Month":"Year")]=parseInt(b.options[b.selectedIndex].value,10),this._notifyChange(e),this._adjustDate(d)},_selectDay:function(a,b,c,d){var e=$(a);if(!$(d).hasClass(this._unselectableClass)&&!this._isDisabledDatepicker(e[0])){var f=this._getInst(e[0]);f.selectedDay=f.currentDay=$("a",d).html(),f.selectedMonth=f.currentMonth=b,f.selectedYear=f.currentYear=c,this._selectDate(a,this._formatDate(f,f.currentDay,f.currentMonth,f.currentYear))}},_clearDate:function(a){{var b=$(a);this._getInst(b[0])}this._selectDate(b,"")},_selectDate:function(a,b){var c=$(a),d=this._getInst(c[0]);b=null!=b?b:this._formatDate(d),d.input&&d.input.val(b),this._updateAlternate(d);var e=this._get(d,"onSelect");e?e.apply(d.input?d.input[0]:null,[b,d]):d.input&&d.input.trigger("change"),d.inline?this._updateDatepicker(d):(this._hideDatepicker(),this._lastInput=d.input[0],"object"!=typeof d.input[0]&&d.input.focus(),this._lastInput=null)},_updateAlternate:function(a){var b=this._get(a,"altField");if(b){var c=this._get(a,"altFormat")||this._get(a,"dateFormat"),d=this._getDate(a),e=this.formatDate(c,d,this._getFormatConfig(a));$(b).each(function(){$(this).val(e)})}},noWeekends:function(a){var b=a.getDay();return[b>0&&6>b,""]},iso8601Week:function(a){var b=new Date(a.getTime());b.setDate(b.getDate()+4-(b.getDay()||7));var c=b.getTime();return b.setMonth(0),b.setDate(1),Math.floor(Math.round((c-b)/864e5)/7)+1},parseDate:function(a,b,c){if(null==a||null==b)throw"Invalid arguments";if(b="object"==typeof b?b.toString():b+"",""==b)return null;var d=(c?c.shortYearCutoff:null)||this._defaults.shortYearCutoff;d="string"!=typeof d?d:(new Date).getFullYear()%100+parseInt(d,10);for(var e=(c?c.dayNamesShort:null)||this._defaults.dayNamesShort,f=(c?c.dayNames:null)||this._defaults.dayNames,g=(c?c.monthNamesShort:null)||this._defaults.monthNamesShort,h=(c?c.monthNames:null)||this._defaults.monthNames,i=-1,j=-1,k=-1,l=-1,m=!1,n=function(b){var c=s+1<a.length&&a.charAt(s+1)==b;return c&&s++,c},o=function(a){var c=n(a),d="@"==a?14:"!"==a?20:"y"==a&&c?4:"o"==a?3:2,e=new RegExp("^\\d{1,"+d+"}"),f=b.substring(r).match(e);if(!f)throw"Missing number at position "+r;return r+=f[0].length,parseInt(f[0],10)},p=function(a,c,d){var e=$.map(n(a)?d:c,function(a,b){return[[b,a]]}).sort(function(a,b){return-(a[1].length-b[1].length)}),f=-1;if($.each(e,function(a,c){var d=c[1];return b.substr(r,d.length).toLowerCase()==d.toLowerCase()?(f=c[0],r+=d.length,!1):void 0}),-1!=f)return f+1;throw"Unknown name at position "+r},q=function(){if(b.charAt(r)!=a.charAt(s))throw"Unexpected literal at position "+r;r++},r=0,s=0;s<a.length;s++)if(m)"'"!=a.charAt(s)||n("'")?q():m=!1;else switch(a.charAt(s)){case"d":k=o("d");break;case"D":p("D",e,f);break;case"o":l=o("o");break;case"m":j=o("m");break;case"M":j=p("M",g,h);break;case"y":i=o("y");break;case"@":var t=new Date(o("@"));i=t.getFullYear(),j=t.getMonth()+1,k=t.getDate();break;case"!":var t=new Date((o("!")-this._ticksTo1970)/1e4);i=t.getFullYear(),j=t.getMonth()+1,k=t.getDate();break;case"'":n("'")?q():m=!0;break;default:q()}if(r<b.length)throw"Extra/unparsed characters found in date: "+b.substring(r);if(-1==i?i=(new Date).getFullYear():100>i&&(i+=(new Date).getFullYear()-(new Date).getFullYear()%100+(d>=i?0:-100)),l>-1)for(j=1,k=l;;){var u=this._getDaysInMonth(i,j-1);if(u>=k)break;j++,k-=u}var t=this._daylightSavingAdjust(new Date(i,j-1,k));if(t.getFullYear()!=i||t.getMonth()+1!=j||t.getDate()!=k)throw"Invalid date";return t},ATOM:"yy-mm-dd",COOKIE:"D, dd M yy",ISO_8601:"yy-mm-dd",RFC_822:"D, d M y",RFC_850:"DD, dd-M-y",RFC_1036:"D, d M y",RFC_1123:"D, d M yy",RFC_2822:"D, d M yy",RSS:"D, d M y",TICKS:"!",TIMESTAMP:"@",W3C:"yy-mm-dd",_ticksTo1970:24*(718685+Math.floor(492.5)-Math.floor(19.7)+Math.floor(4.925))*60*60*1e7,formatDate:function(a,b,c){if(!b)return"";var d=(c?c.dayNamesShort:null)||this._defaults.dayNamesShort,e=(c?c.dayNames:null)||this._defaults.dayNames,f=(c?c.monthNamesShort:null)||this._defaults.monthNamesShort,g=(c?c.monthNames:null)||this._defaults.monthNames,h=function(b){var c=m+1<a.length&&a.charAt(m+1)==b;return c&&m++,c},i=function(a,b,c){var d=""+b;if(h(a))for(;d.length<c;)d="0"+d;return d},j=function(a,b,c,d){return h(a)?d[b]:c[b]},k="",l=!1;if(b)for(var m=0;m<a.length;m++)if(l)"'"!=a.charAt(m)||h("'")?k+=a.charAt(m):l=!1;else switch(a.charAt(m)){case"d":k+=i("d",b.getDate(),2);break;case"D":k+=j("D",b.getDay(),d,e);break;case"o":k+=i("o",Math.round((new Date(b.getFullYear(),b.getMonth(),b.getDate()).getTime()-new Date(b.getFullYear(),0,0).getTime())/864e5),3);break;case"m":k+=i("m",b.getMonth()+1,2);break;case"M":k+=j("M",b.getMonth(),f,g);break;case"y":k+=h("y")?b.getFullYear():(b.getYear()%100<10?"0":"")+b.getYear()%100;break;case"@":k+=b.getTime();break;case"!":k+=1e4*b.getTime()+this._ticksTo1970;break;case"'":h("'")?k+="'":l=!0;break;default:k+=a.charAt(m)}return k},_possibleChars:function(a){for(var b="",c=!1,d=function(b){var c=e+1<a.length&&a.charAt(e+1)==b;return c&&e++,c},e=0;e<a.length;e++)if(c)"'"!=a.charAt(e)||d("'")?b+=a.charAt(e):c=!1;else switch(a.charAt(e)){case"d":case"m":case"y":case"@":b+="0123456789";break;case"D":case"M":return null;case"'":d("'")?b+="'":c=!0;break;default:b+=a.charAt(e)}return b},_get:function(a,b){return a.settings[b]!==undefined?a.settings[b]:this._defaults[b]},_setDateFromField:function(a,b){if(a.input.val()!=a.lastVal){var c,d,e=this._get(a,"dateFormat"),f=a.lastVal=a.input?a.input.val():null;c=d=this._getDefaultDate(a);var g=this._getFormatConfig(a);try{c=this.parseDate(e,f,g)||d}catch(h){this.log(h),f=b?"":f}a.selectedDay=c.getDate(),a.drawMonth=a.selectedMonth=c.getMonth(),a.drawYear=a.selectedYear=c.getFullYear(),a.currentDay=f?c.getDate():0,a.currentMonth=f?c.getMonth():0,a.currentYear=f?c.getFullYear():0,this._adjustInstDate(a)}},_getDefaultDate:function(a){return this._restrictMinMax(a,this._determineDate(a,this._get(a,"defaultDate"),new Date))},_determineDate:function(a,b,c){var d=function(a){var b=new Date;return b.setDate(b.getDate()+a),b},e=function(b){try{return $.datepicker.parseDate($.datepicker._get(a,"dateFormat"),b,$.datepicker._getFormatConfig(a))}catch(c){}for(var d=(b.toLowerCase().match(/^c/)?$.datepicker._getDate(a):null)||new Date,e=d.getFullYear(),f=d.getMonth(),g=d.getDate(),h=/([+-]?[0-9]+)\s*(d|D|w|W|m|M|y|Y)?/g,i=h.exec(b);i;){switch(i[2]||"d"){case"d":case"D":g+=parseInt(i[1],10);break;case"w":case"W":g+=7*parseInt(i[1],10);break;case"m":case"M":f+=parseInt(i[1],10),g=Math.min(g,$.datepicker._getDaysInMonth(e,f));break;case"y":case"Y":e+=parseInt(i[1],10),g=Math.min(g,$.datepicker._getDaysInMonth(e,f))}i=h.exec(b)}return new Date(e,f,g)},f=null==b||""===b?c:"string"==typeof b?e(b):"number"==typeof b?isNaN(b)?c:d(b):new Date(b.getTime());return f=f&&"Invalid Date"==f.toString()?c:f,f&&(f.setHours(0),f.setMinutes(0),f.setSeconds(0),f.setMilliseconds(0)),this._daylightSavingAdjust(f)},_daylightSavingAdjust:function(a){return a?(a.setHours(a.getHours()>12?a.getHours()+2:0),a):null},_setDate:function(a,b,c){var d=!b,e=a.selectedMonth,f=a.selectedYear,g=this._restrictMinMax(a,this._determineDate(a,b,new Date));a.selectedDay=a.currentDay=g.getDate(),a.drawMonth=a.selectedMonth=a.currentMonth=g.getMonth(),a.drawYear=a.selectedYear=a.currentYear=g.getFullYear(),e==a.selectedMonth&&f==a.selectedYear||c||this._notifyChange(a),this._adjustInstDate(a),a.input&&a.input.val(d?"":this._formatDate(a))},_getDate:function(a){var b=!a.currentYear||a.input&&""==a.input.val()?null:this._daylightSavingAdjust(new Date(a.currentYear,a.currentMonth,a.currentDay));return b},_attachHandlers:function(a){var b=this._get(a,"stepMonths"),c="#"+a.id.replace(/\\\\/g,"\\");a.dpDiv.find("[data-handler]").map(function(){var a={prev:function(){window["DP_jQuery_"+dpuuid].datepicker._adjustDate(c,-b,"M")},next:function(){window["DP_jQuery_"+dpuuid].datepicker._adjustDate(c,+b,"M")},hide:function(){window["DP_jQuery_"+dpuuid].datepicker._hideDatepicker()},today:function(){window["DP_jQuery_"+dpuuid].datepicker._gotoToday(c)},selectDay:function(){return window["DP_jQuery_"+dpuuid].datepicker._selectDay(c,+this.getAttribute("data-month"),+this.getAttribute("data-year"),this),!1},selectMonth:function(){return window["DP_jQuery_"+dpuuid].datepicker._selectMonthYear(c,this,"M"),!1},selectYear:function(){return window["DP_jQuery_"+dpuuid].datepicker._selectMonthYear(c,this,"Y"),!1}};$(this).bind(this.getAttribute("data-event"),a[this.getAttribute("data-handler")])})},_generateHTML:function(a){var b=new Date;b=this._daylightSavingAdjust(new Date(b.getFullYear(),b.getMonth(),b.getDate()));var c=this._get(a,"isRTL"),d=this._get(a,"showButtonPanel"),e=this._get(a,"hideIfNoPrevNext"),f=this._get(a,"navigationAsDateFormat"),g=this._getNumberOfMonths(a),h=this._get(a,"showCurrentAtPos"),i=this._get(a,"stepMonths"),j=1!=g[0]||1!=g[1],k=this._daylightSavingAdjust(a.currentDay?new Date(a.currentYear,a.currentMonth,a.currentDay):new Date(9999,9,9)),l=this._getMinMaxDate(a,"min"),m=this._getMinMaxDate(a,"max"),n=a.drawMonth-h,o=a.drawYear;if(0>n&&(n+=12,o--),m){var p=this._daylightSavingAdjust(new Date(m.getFullYear(),m.getMonth()-g[0]*g[1]+1,m.getDate()));for(p=l&&l>p?l:p;this._daylightSavingAdjust(new Date(o,n,1))>p;)n--,0>n&&(n=11,o--)}a.drawMonth=n,a.drawYear=o;var q=this._get(a,"prevText");q=f?this.formatDate(q,this._daylightSavingAdjust(new Date(o,n-i,1)),this._getFormatConfig(a)):q;var r=this._canAdjustMonth(a,-1,o,n)?'<a class="ui-datepicker-prev ui-corner-all" data-handler="prev" data-event="click" title="'+q+'"><span class="ui-icon ui-icon-circle-triangle-'+(c?"e":"w")+'">'+q+"</span></a>":e?"":'<a class="ui-datepicker-prev ui-corner-all ui-state-disabled" title="'+q+'"><span class="ui-icon ui-icon-circle-triangle-'+(c?"e":"w")+'">'+q+"</span></a>",s=this._get(a,"nextText");s=f?this.formatDate(s,this._daylightSavingAdjust(new Date(o,n+i,1)),this._getFormatConfig(a)):s;var t=this._canAdjustMonth(a,1,o,n)?'<a class="ui-datepicker-next ui-corner-all" data-handler="next" data-event="click" title="'+s+'"><span class="ui-icon ui-icon-circle-triangle-'+(c?"w":"e")+'">'+s+"</span></a>":e?"":'<a class="ui-datepicker-next ui-corner-all ui-state-disabled" title="'+s+'"><span class="ui-icon ui-icon-circle-triangle-'+(c?"w":"e")+'">'+s+"</span></a>",u=this._get(a,"currentText"),v=this._get(a,"gotoCurrent")&&a.currentDay?k:b;u=f?this.formatDate(u,v,this._getFormatConfig(a)):u;var w=a.inline?"":'<button type="button" class="ui-datepicker-close ui-state-default ui-priority-primary ui-corner-all" data-handler="hide" data-event="click">'+this._get(a,"closeText")+"</button>",x=d?'<div class="ui-datepicker-buttonpane ui-widget-content">'+(c?w:"")+(this._isInRange(a,v)?'<button type="button" class="ui-datepicker-current ui-state-default ui-priority-secondary ui-corner-all" data-handler="today" data-event="click">'+u+"</button>":"")+(c?"":w)+"</div>":"",y=parseInt(this._get(a,"firstDay"),10);y=isNaN(y)?0:y;for(var z=this._get(a,"showWeek"),A=this._get(a,"dayNames"),B=(this._get(a,"dayNamesShort"),this._get(a,"dayNamesMin")),C=this._get(a,"monthNames"),D=this._get(a,"monthNamesShort"),E=this._get(a,"beforeShowDay"),F=this._get(a,"showOtherMonths"),G=this._get(a,"selectOtherMonths"),H=(this._get(a,"calculateWeek")||this.iso8601Week,this._getDefaultDate(a)),I="",J=0;J<g[0];J++){var K="";this.maxRows=4;for(var L=0;L<g[1];L++){var M=this._daylightSavingAdjust(new Date(o,n,a.selectedDay)),N=" ui-corner-all",O="";if(j){if(O+='<div class="ui-datepicker-group',g[1]>1)switch(L){case 0:O+=" ui-datepicker-group-first",N=" ui-corner-"+(c?"right":"left");break;case g[1]-1:O+=" ui-datepicker-group-last",N=" ui-corner-"+(c?"left":"right");break;default:O+=" ui-datepicker-group-middle",N=""}O+='">'}O+='<div class="ui-datepicker-header ui-widget-header ui-helper-clearfix'+N+'">'+(/all|left/.test(N)&&0==J?c?t:r:"")+(/all|right/.test(N)&&0==J?c?r:t:"")+this._generateMonthYearHeader(a,n,o,l,m,J>0||L>0,C,D)+'</div><table class="ui-datepicker-calendar"><thead><tr>';for(var P=z?'<th class="ui-datepicker-week-col">'+this._get(a,"weekHeader")+"</th>":"",Q=0;7>Q;Q++){var R=(Q+y)%7;P+="<th"+((Q+y+6)%7>=5?' class="ui-datepicker-week-end"':"")+'><span title="'+A[R]+'">'+B[R]+"</span></th>"}O+=P+"</tr></thead><tbody>";var S=this._getDaysInMonth(o,n);o==a.selectedYear&&n==a.selectedMonth&&(a.selectedDay=Math.min(a.selectedDay,S));var T=(this._getFirstDayOfMonth(o,n)-y+7)%7,U=Math.ceil((T+S)/7),V=j&&this.maxRows>U?this.maxRows:U;this.maxRows=V;for(var W=this._daylightSavingAdjust(new Date(o,n,1-T)),X=0;V>X;X++){O+="<tr>";for(var Y=z?'<td class="ui-datepicker-week-col">'+this._get(a,"calculateWeek")(W)+"</td>":"",Q=0;7>Q;Q++){var Z=E?E.apply(a.input?a.input[0]:null,[W]):[!0,""],_=W.getMonth()!=n,ab=_&&!G||!Z[0]||l&&l>W||m&&W>m;Y+='<td class="'+((Q+y+6)%7>=5?" ui-datepicker-week-end":"")+(_?" ui-datepicker-other-month":"")+(W.getTime()==M.getTime()&&n==a.selectedMonth&&a._keyEvent||H.getTime()==W.getTime()&&H.getTime()==M.getTime()?" "+this._dayOverClass:"")+(ab?" "+this._unselectableClass+" ui-state-disabled":"")+(_&&!F?"":" "+Z[1]+(W.getTime()==k.getTime()?" "+this._currentClass:"")+(W.getTime()==b.getTime()?" ui-datepicker-today":""))+'"'+(_&&!F||!Z[2]?"":' title="'+Z[2]+'"')+(ab?"":' data-handler="selectDay" data-event="click" data-month="'+W.getMonth()+'" data-year="'+W.getFullYear()+'"')+">"+(_&&!F?"&#xa0;":ab?'<span class="ui-state-default">'+W.getDate()+"</span>":'<a class="ui-state-default'+(W.getTime()==b.getTime()?" ui-state-highlight":"")+(W.getTime()==k.getTime()?" ui-state-active":"")+(_?" ui-priority-secondary":"")+'" href="#">'+W.getDate()+"</a>")+"</td>",W.setDate(W.getDate()+1),W=this._daylightSavingAdjust(W) }O+=Y+"</tr>"}n++,n>11&&(n=0,o++),O+="</tbody></table>"+(j?"</div>"+(g[0]>0&&L==g[1]-1?'<div class="ui-datepicker-row-break"></div>':""):""),K+=O}I+=K}return I+=x+($.browser.msie&&parseInt($.browser.version,10)<7&&!a.inline?'<iframe src="javascript:false;" class="ui-datepicker-cover" frameborder="0"></iframe>':""),a._keyEvent=!1,I},_generateMonthYearHeader:function(a,b,c,d,e,f,g,h){var i=this._get(a,"changeMonth"),j=this._get(a,"changeYear"),k=this._get(a,"showMonthAfterYear"),l='<div class="ui-datepicker-title">',m="";if(f||!i)m+='<span class="ui-datepicker-month">'+g[b]+"</span>";else{var n=d&&d.getFullYear()==c,o=e&&e.getFullYear()==c;m+='<select class="ui-datepicker-month" data-handler="selectMonth" data-event="change">';for(var p=0;12>p;p++)(!n||p>=d.getMonth())&&(!o||p<=e.getMonth())&&(m+='<option value="'+p+'"'+(p==b?' selected="selected"':"")+">"+h[p]+"</option>");m+="</select>"}if(k||(l+=m+(!f&&i&&j?"":"&#xa0;")),!a.yearshtml)if(a.yearshtml="",f||!j)l+='<span class="ui-datepicker-year">'+c+"</span>";else{var q=this._get(a,"yearRange").split(":"),r=(new Date).getFullYear(),s=function(a){var b=a.match(/c[+-].*/)?c+parseInt(a.substring(1),10):a.match(/[+-].*/)?r+parseInt(a,10):parseInt(a,10);return isNaN(b)?r:b},t=s(q[0]),u=Math.max(t,s(q[1]||""));for(t=d?Math.max(t,d.getFullYear()):t,u=e?Math.min(u,e.getFullYear()):u,a.yearshtml+='<select class="ui-datepicker-year" data-handler="selectYear" data-event="change">';u>=t;t++)a.yearshtml+='<option value="'+t+'"'+(t==c?' selected="selected"':"")+">"+t+"</option>";a.yearshtml+="</select>",l+=a.yearshtml,a.yearshtml=null}return l+=this._get(a,"yearSuffix"),k&&(l+=(!f&&i&&j?"":"&#xa0;")+m),l+="</div>"},_adjustInstDate:function(a,b,c){var d=a.drawYear+("Y"==c?b:0),e=a.drawMonth+("M"==c?b:0),f=Math.min(a.selectedDay,this._getDaysInMonth(d,e))+("D"==c?b:0),g=this._restrictMinMax(a,this._daylightSavingAdjust(new Date(d,e,f)));a.selectedDay=g.getDate(),a.drawMonth=a.selectedMonth=g.getMonth(),a.drawYear=a.selectedYear=g.getFullYear(),("M"==c||"Y"==c)&&this._notifyChange(a)},_restrictMinMax:function(a,b){var c=this._getMinMaxDate(a,"min"),d=this._getMinMaxDate(a,"max"),e=c&&c>b?c:b;return e=d&&e>d?d:e},_notifyChange:function(a){var b=this._get(a,"onChangeMonthYear");b&&b.apply(a.input?a.input[0]:null,[a.selectedYear,a.selectedMonth+1,a])},_getNumberOfMonths:function(a){var b=this._get(a,"numberOfMonths");return null==b?[1,1]:"number"==typeof b?[1,b]:b},_getMinMaxDate:function(a,b){return this._determineDate(a,this._get(a,b+"Date"),null)},_getDaysInMonth:function(a,b){return 32-this._daylightSavingAdjust(new Date(a,b,32)).getDate()},_getFirstDayOfMonth:function(a,b){return new Date(a,b,1).getDay()},_canAdjustMonth:function(a,b,c,d){var e=this._getNumberOfMonths(a),f=this._daylightSavingAdjust(new Date(c,d+(0>b?b:e[0]*e[1]),1));return 0>b&&f.setDate(this._getDaysInMonth(f.getFullYear(),f.getMonth())),this._isInRange(a,f)},_isInRange:function(a,b){var c=this._getMinMaxDate(a,"min"),d=this._getMinMaxDate(a,"max");return(!c||b.getTime()>=c.getTime())&&(!d||b.getTime()<=d.getTime())},_getFormatConfig:function(a){var b=this._get(a,"shortYearCutoff");return b="string"!=typeof b?b:(new Date).getFullYear()%100+parseInt(b,10),{shortYearCutoff:b,dayNamesShort:this._get(a,"dayNamesShort"),dayNames:this._get(a,"dayNames"),monthNamesShort:this._get(a,"monthNamesShort"),monthNames:this._get(a,"monthNames")}},_formatDate:function(a,b,c,d){b||(a.currentDay=a.selectedDay,a.currentMonth=a.selectedMonth,a.currentYear=a.selectedYear);var e=b?"object"==typeof b?b:this._daylightSavingAdjust(new Date(d,c,b)):this._daylightSavingAdjust(new Date(a.currentYear,a.currentMonth,a.currentDay));return this.formatDate(this._get(a,"dateFormat"),e,this._getFormatConfig(a))}}),$.fn.datepicker=function(a){if(!this.length)return this;$.datepicker.initialized||($(document).mousedown($.datepicker._checkExternalClick).find("body").append($.datepicker.dpDiv),$.datepicker.initialized=!0);var b=Array.prototype.slice.call(arguments,1);return"string"!=typeof a||"isDisabled"!=a&&"getDate"!=a&&"widget"!=a?"option"==a&&2==arguments.length&&"string"==typeof arguments[1]?$.datepicker["_"+a+"Datepicker"].apply($.datepicker,[this[0]].concat(b)):this.each(function(){"string"==typeof a?$.datepicker["_"+a+"Datepicker"].apply($.datepicker,[this].concat(b)):$.datepicker._attachDatepicker(this,a)}):$.datepicker["_"+a+"Datepicker"].apply($.datepicker,[this[0]].concat(b))},$.datepicker=new Datepicker,$.datepicker.initialized=!1,$.datepicker.uuid=(new Date).getTime(),$.datepicker.version="1.8.24",window["DP_jQuery_"+dpuuid]=$}(jQuery),function(){"use strict";if(!window.jQuery&&!window.Zepto)throw new Error("either jQuery or Zepto is required for AJS to function.");"undefined"==typeof window.console?window.console={messages:[],log:function(a){this.messages.push(a)},show:function(){alert(this.messages.join("\n")),this.messages=[]}}:console.show=function(){},window.AJS=function(){function a(a){var b={"<":"&lt;",">":"&gt;","&":"&amp;","'":"&#39;","`":"&#96;"};return"string"==typeof b[a]?b[a]:"&quot;"}var b,c,d=[],e=0,f=/[&"'<>`]/g,g={version:"5.6.5",params:{},$:window.jQuery||window.Zepto,log:function(){return"undefined"!=typeof console&&console.log?Function.prototype.bind?Function.prototype.bind.call(console.log,console):function(){Function.prototype.apply.call(console.log,console,arguments)}:function(){}}(),warn:function(){"undefined"!=typeof console&&console.warn&&Function.prototype.apply.apply(console.warn,[console,arguments])},error:function(){"undefined"!=typeof console&&console.error&&Function.prototype.apply.apply(console.error,[console,arguments])},preventDefault:function(a){a.preventDefault()},stopEvent:function(a){return a.stopPropagation(),!1},include:function(a){if(!this.contains(d,a)){d.push(a);var b=document.createElement("script");b.src=a,this.$("body").append(b)}},toggleClassName:function(a,b){(a=this.$(a))&&a.toggleClass(b)},setVisible:function(a,b){if(a=this.$(a)){var c=this.$;c(a).each(function(){var a=c(this).hasClass("hidden");a&&b?c(this).removeClass("hidden"):a||b||c(this).addClass("hidden")})}},setCurrent:function(a,b){(a=this.$(a))&&(b?a.addClass("current"):a.removeClass("current"))},isVisible:function(a){return!this.$(a).hasClass("hidden")},isClipped:function(a){return a=AJS.$(a),a.prop("scrollWidth")>a.prop("clientWidth")},populateParameters:function(a){a||(a=this.params);var b=this;this.$(".parameters input").each(function(){var c=this.value,d=this.title||this.id;b.$(this).hasClass("list")?a[d]?a[d].push(c):a[d]=[c]:a[d]=c.match(/^(tru|fals)e$/i)?"true"===c.toLowerCase():c})},toInit:function(a){var b=this;return this.$(function(){try{a.apply(this,arguments)}catch(c){b.log("Failed to run init function: "+c+"\n"+a.toString())}}),this},indexOf:function(a,b,c){var d=a.length;c?0>c&&(c=Math.max(0,d+c)):c=0;for(var e=c;d>e;e++)if(a[e]===b)return e;return-1},contains:function(a,b){return this.indexOf(a,b)>-1},firebug:function(){AJS.log("DEPRECATED: AJS.firebug should no longer be used.");var a=this.$(document.createElement("script"));a.attr("src","https://getfirebug.com/releases/lite/1.2/firebug-lite-compressed.js"),this.$("head").append(a),function(){window.firebug?firebug.init():setTimeout(AJS.firebug,0)}()},clone:function(a){return AJS.$(a).clone().removeAttr("id")},alphanum:function(a,b){a=(a+"").toLowerCase(),b=(b+"").toLowerCase();for(var c=/(\d+|\D+)/g,d=a.match(c),e=b.match(c),f=Math.max(d.length,e.length),g=0;f>g;g++){if(g===d.length)return-1;if(g===e.length)return 1;var h=parseInt(d[g],10)+"",i=parseInt(e[g],10)+"";if(h===d[g]&&i===e[g]&&h!==i)return(h-i)/Math.abs(h-i);if((h!==d[g]||i!==e[g])&&d[g]!==e[g])return d[g]<e[g]?-1:1}return 0},onTextResize:function(a){if("function"==typeof a)if(AJS.onTextResize["on-text-resize"])AJS.onTextResize["on-text-resize"].push(function(b){a(b)});else{var b=AJS("div");b.css({width:"1em",height:"1em",position:"absolute",top:"-9999em",left:"-9999em"}),this.$("body").append(b),b.size=b.width(),setInterval(function(){if(b.size!==b.width()){b.size=b.width();for(var a=0,c=AJS.onTextResize["on-text-resize"].length;c>a;a++)AJS.onTextResize["on-text-resize"][a](b.size)}},0),AJS.onTextResize.em=b,AJS.onTextResize["on-text-resize"]=[function(b){a(b)}]}},unbindTextResize:function(a){for(var b=0,c=AJS.onTextResize["on-text-resize"].length;c>b;b++)if(AJS.onTextResize["on-text-resize"][b]===a)return AJS.onTextResize["on-text-resize"].splice(b,1)},escape:function(a){return escape(a).replace(/%u\w{4}/gi,function(a){return unescape(a)})},escapeHtml:function(b){return b.replace(f,a)},filterBySearch:function(a,b,c){if(!b)return[];var d=(this.$,c&&c.keywordsField||"keywords"),e=c&&c.ignoreForCamelCase?"i":"",f=c&&c.matchBoundary?"\\b":"",g=c&&c.splitRegex||/\s+/,h=b.split(g),i=[];h.forEach(function(a){var b=[new RegExp(f+a,"i")];if(/^([A-Z][a-z]*) {2,}$/.test(this)){var c=this.replace(/([A-Z][a-z]*)/g,"\\b$1[^,]*");b.push(new RegExp(c,e))}i.push(b)});var j=[];return a.forEach(function(a){for(var b=0;b<i.length;b++){for(var c=!1,e=0;e<i[b].length;e++)if(i[b][e].test(a[d])){c=!0;break}if(!c)return}j.push(a)}),j},drawLogo:function(a){AJS.log("DEPRECATED: AJS.drawLogo should no longer be used.");var b=a.scaleFactor||1,c=a.fill||"#fff",d=a.stroke||"#000",e=400*b,f=40*b,g=a.strokeWidth||1,h=a.containerID||".aui-logo";AJS.$(".aui-logo").length||AJS.$("body").append('<div id="aui-logo" class="aui-logo"><div>');var i=Raphael(h,e+50*b,f+100*b),j=i.path("M 0,0 c 3.5433333,-4.7243333 7.0866667,-9.4486667 10.63,-14.173 -14.173,0 -28.346,0 -42.519,0 C -35.432667,-9.4486667 -38.976333,-4.7243333 -42.52,0 -28.346667,0 -14.173333,0 0,0 z m 277.031,28.346 c -14.17367,0 -28.34733,0 -42.521,0 C 245.14,14.173 255.77,0 266.4,-14.173 c -14.17267,0 -28.34533,0 -42.518,0 C 213.25167,0 202.62133,14.173 191.991,28.346 c -14.17333,0 -28.34667,0 -42.52,0 14.17333,-18.8976667 28.34667,-37.7953333 42.52,-56.693 -7.08667,-9.448667 -14.17333,-18.897333 -21.26,-28.346 -14.173,0 -28.346,0 -42.519,0 7.08667,9.448667 14.17333,18.897333 21.26,28.346 -14.17333,18.8976667 -28.34667,37.7953333 -42.52,56.693 -14.173333,0 -28.346667,0 -42.52,0 10.63,-14.173 21.26,-28.346 31.89,-42.519 -14.390333,0 -28.780667,0 -43.171,0 C 42.520733,1.330715e-4 31.889933,14.174867 21.26,28.347 c -42.520624,6.24e-4 -85.039187,-8.13e-4 -127.559,-0.001 11.220667,-14.961 22.441333,-29.922 33.662,-44.883 -6.496,-8.661 -12.992,-17.322 -19.488,-25.983 5.905333,0 11.810667,0 17.716,0 -10.63,-14.173333 -21.26,-28.346667 -31.89,-42.52 14.173333,0 28.346667,0 42.52,0 10.63,14.173333 21.26,28.346667 31.89,42.52 14.173333,0 28.3466667,0 42.52,0 -10.63,-14.173333 -21.26,-28.346667 -31.89,-42.52 14.1733333,0 28.3466667,0 42.52,0 10.63,14.173333 21.26,28.346667 31.89,42.52 14.390333,0 28.780667,0 43.171,0 -10.63,-14.173333 -21.26,-28.346667 -31.89,-42.52 42.51967,0 85.03933,0 127.559,0 10.63033,14.173333 21.26067,28.346667 31.891,42.52 14.17267,0 28.34533,0 42.518,0 -10.63,-14.173333 -21.26,-28.346667 -31.89,-42.52 14.17367,0 28.34733,0 42.521,0 14.17333,18.897667 28.34667,37.795333 42.52,56.693 -14.17333,18.8976667 -28.34667,37.7953333 -42.52,56.693 z");j.scale(b,-b,0,0),j.translate(120*b,f),j.attr("fill",c),j.attr("stroke",d),j.attr("stroke-width",g)},debounce:function(a,b){var c,d;return function(){var e=arguments,f=this,g=function(){d=a.apply(f,e)};return clearTimeout(c),c=setTimeout(g,b),d}},id:function(a){if(b=e++ +"",c=a?a+b:"aui-uid-"+b,document.getElementById(c)){if(c=c+"-"+(new Date).getTime(),document.getElementById(c))throw new Error("ERROR: timestamped fallback ID "+c+" exists. AJS.id stopped.");return c}return c},_addID:function(a,b){var c=AJS.$(a),d=b||!1;c.each(function(){var a=AJS.$(this);a.attr("id")||a.attr("id",AJS.id(d))})},enable:function(a,b){var c=AJS.$(a);return"undefined"==typeof b&&(b=!0),c.each(function(){this.disabled=!b})}};if("undefined"!=typeof AJS)for(var h in AJS)g[h]=AJS[h];var i=function(){var a=null;return arguments.length&&"string"==typeof arguments[0]&&(a=AJS.$(document.createElement(arguments[0])),2===arguments.length&&a.html(arguments[1])),a};for(var j in g)i[j]=g[j];return i}(),AJS.$(function(){var a=AJS.$("body");a.data("auiVersion")||a.attr("data-aui-version",AJS.version),AJS.populateParameters()}),AJS.$.ajaxSettings.traditional=!0}(),AJS.format=function(){var a=/'(?!')/g,b=/^\d+$/,c=/^(\d+),number$/,d=/^(\d+)\,choice\,(.+)/,e=/^(\d+)([#<])(.+)/,f=function(a,f){var g,h="";if(g=a.match(b))h=f.length>++a?f[a]:"";else if(g=a.match(c))h=f.length>++g[1]?f[g[1]]:"";else if(g=a.match(d)){var i=f.length>++g[1]?f[g[1]]:null;if(null!==i){for(var j=g[2].split("|"),k=null,l=0;l<j.length;l++){var m=j[l].match(e),n=parseInt(m[1],10);if(n>i){if(k){h=k;break}h=m[3];break}if(i==n&&"#"==m[2]){h=m[3];break}l==j.length-1&&(h=m[3]),k=m[3]}var o=[h].concat(Array.prototype.slice.call(f,1));h=AJS.format.apply(AJS,o)}}return h},g=function(a){for(var b=!1,c=-1,d=0,e=0;e<a.length;e++){var f=a.charAt(e);if("'"==f&&(b=!b),!b)if("{"===f)0===d&&(c=e),d++;else if("}"===f&&d>0&&(d--,0===d)){var g=[];return g.push(a.substring(0,e+1)),g.push(a.substring(0,c)),g.push(a.substring(c+1,e)),g}}return null},h=function(b){for(var c=arguments,d="",e=g(b);e;)b=b.substring(e[0].length),d+=e[1].replace(a,""),d+=f(e[2],c),e=g(b);return d+=b.replace(a,"")};return h.apply(AJS,arguments)},AJS.I18n={getText:function(a){var b=Array.prototype.slice.call(arguments,1);return AJS.I18n.keys&&Object.prototype.hasOwnProperty.call(AJS.I18n.keys,a)?AJS.format.apply(null,[AJS.I18n.keys[a]].concat(b)):a}},AJS.I18n.keys={},AJS.I18n.keys["aui.words.add"]="Add",AJS.I18n.keys["aui.words.update"]="Update",AJS.I18n.keys["aui.words.delete"]="Delete",AJS.I18n.keys["aui.words.remove"]="Remove",AJS.I18n.keys["aui.words.cancel"]="Cancel",AJS.I18n.keys["aui.words.loading"]="Loading",AJS.I18n.keys["aui.words.close"]="Close",AJS.I18n.keys["aui.enter.value"]="Enter value",AJS.I18n.keys["aui.keyboard.shortcut.type.x"]="Type ''{0}''",AJS.I18n.keys["aui.keyboard.shortcut.then.x"]="then ''{0}''",AJS.I18n.keys["aui.keyboard.shortcut.or.x"]="OR ''{0}''",AJS.I18n.keys["aui.sidebar.expand.tooltip"]="Expand sidebar ( [ )",AJS.I18n.keys["aui.sidebar.collapse.tooltip"]="Collapse sidebar ( [ )",AJS.I18n.keys["aui.words.more"]="More",AJS.I18n.keys["aui.validation.message.maxlength"]="Must be fewer than {0} characters",AJS.I18n.keys["aui.validation.message.minlength"]="Must be greater than {0} characters",AJS.I18n.keys["aui.validation.message.matchingfield"]="{0} and {1} do not match.",AJS.I18n.keys["aui.validation.message.doesnotcontain"]="Do not include the phrase {0} in this field",AJS.I18n.keys["aui.validation.message.pattern"]="This field does not match the required format",AJS.I18n.keys["aui.validation.message.required"]="This is a required field",AJS.I18n.keys["aui.validation.message.validnumber"]="Please enter a valid number",AJS.I18n.keys["aui.validation.message.min"]="Enter a value greater than {0}",AJS.I18n.keys["aui.validation.message.max"]="Enter a value less than {0}",AJS.I18n.keys["aui.validation.message.dateformat"]="Enter a valid date",AJS.I18n.keys["aui.validation.message.minchecked"]="Tick at least {0} checkboxes.",AJS.I18n.keys["aui.validation.message.maxchecked"]="Tick at most {0} checkboxes.",AJS._internal||(AJS._internal={}),function(a){AJS._internal.browser={};var b=null;AJS._internal.browser.supportsCalc=function(){if(null===b){var c=a('<div style="height: 10px; height: -webkit-calc(20px + 0); height: calc(20px);"></div>');b=20===c.appendTo(document.documentElement).height(),c.remove()}return b}}(AJS.$),function(a){AJS._internal=AJS._internal||{},AJS._internal.widget=function(b,c){var d="_aui-widget-"+b;return function(b,e){var f,g;a.isPlainObject(b)?g=b:(f=b,g=e);var h,i=f&&a(f);return i&&i.data(d)?h=i.data(d):(h=new c(i,g||{}),i=h.$el,i.data(d,h)),h}}}(AJS.$),function(){function a(a,b){for(var c=a.length;c--;)if(b(a[c]))return c;return-1}function b(b,c){return a(b,function(a){return a[0]===c[0]})}function c(b){return a(b,function(a){return AJS.layer(a).isBlanketed()})}function d(a){var b;if(a.length){var c=a[a.length-1],d=parseInt(c.css("z-index"),10);b=(isNaN(d)?0:d)+100}else b=0;return Math.max(3e3,b)}function e(){this._stack=[]}e.prototype.push=function(a){if(b(this._stack,a)>=0)throw new Error("The given element is already an active layer");var e=AJS.layer(a),f=d(this._stack);e._showLayer(f),e.isBlanketed()&&(c(this._stack)>=0&&AJS.undim(),AJS.dim(!1,f-20)),this._stack.push(a)},e.prototype.popUntil=function(a){var d=b(this._stack,a);if(0>d)return null;var e=this._stack.slice(d);this._stack=this._stack.slice(0,d);var f=c(e);if(f>=0){AJS.undim();var g=c(this._stack);g>=0&&AJS.dim(!1,this._stack[g].css("z-index")-20)}for(var h;e.length;)h=e.pop(),AJS.layer(h)._hideLayer();return h},e.prototype.getTopLayer=function(){if(!this._stack.length)return null;var a=this._stack[this._stack.length-1];return a},e.prototype.popTopIfNonModal=function(){var a=this.getTopLayer();return!a||AJS.layer(a).isModal()?null:this.popUntil(a)},e.prototype.popUntilTopBlanketed=function(){var a=c(this._stack);if(0>a)return null;var b=this._stack[a];return AJS.layer(b).isModal()?null:this.popUntil(b)},AJS.LayerManager=e}(AJS.$),function(a){AJS.LayerManager.global=new AJS.LayerManager,a(document).on("keydown",function(a){if(a.keyCode===AJS.keyCode.ESCAPE){var b=AJS.LayerManager.global.popTopIfNonModal();b&&a.preventDefault()}}).on("click",".aui-blanket",function(a){var b=AJS.LayerManager.global.popUntilTopBlanketed();b&&a.preventDefault()})}(AJS.$),AJS.FocusManager=function(a){function b(){this._focusTrapStack=[],a(document).on("focusout",{focusTrapStack:this._focusTrapStack},f)}function c(a,b){b.push(a)}function d(a){a.pop()}function e(a){return a.is(".aui-dialog2")}function f(a){var b=a.data.focusTrapStack;if(a.relatedTarget&&0!==b.length){var c=b[b.length-1],d=a.target,e=a.relatedTarget,f=c.find(":aui-tabbable"),g=AJS.$(f.first()),h=AJS.$(f.last()),i=0===c.has(e).length,j=i&&e;j&&(g.is(d)?h.focus():h.is(d)&&g.focus())}}!function(){function b(b){return!a(b).parents().andSelf().filter(function(){return"hidden"===a.css(this,"visibility")||a.expr.filters.hidden(this)}).length}function c(c,d){var e=c.nodeName.toLowerCase();if("area"===e){var f=c.parentNode,g=f.name,h=a("img[usemap=#"+g+"]").get();return c.href&&g&&"map"===f.nodeName.toLowerCase()?h&&b(h):!1}var i=/input|select|textarea|button|object/.test(e),j="a"===e,k=c.href||d;return(i?!c.disabled:j?k:d)&&b(c)}function d(b){var d=a.attr(b,"tabindex"),e=isNaN(d),f=e||d>=0;return f&&c(b,!e)}a.extend(a.expr[":"],{"aui-focusable":function(b){return c(b,!isNaN(a.attr(b,"tabindex")))},"aui-tabbable":d})}();var g="_aui-focus-restore";return b.defaultFocusSelector=":aui-tabbable",b.prototype.enter=function(d){if(d.data(g,a(document.activeElement)),"false"!==d.attr("data-aui-focus")){var f=d.attr("data-aui-focus-selector")||b.defaultFocusSelector,h=d.is(f)?d:d.find(f);h.first().focus()}e(d)&&c(d,this._focusTrapStack)},b.prototype.exit=function(b){e(b)&&d(this._focusTrapStack);var c=document.activeElement;(b[0]===c||b.has(c).length)&&a(c).blur();var f=b.data(g);f&&f.length&&(b.removeData(g),f.focus())},b.global=new b,b}(AJS.$),AJS=AJS||{},function(){var a="%CONTEXT_PATH%";a=0===a.indexOf("%CONTEXT_PATH")?!1:a,AJS.contextPath=function(){for(var b=null,c=[a,window.contextPath,window.Confluence&&Confluence.getContextPath(),window.BAMBOO&&BAMBOO.contextPath,window.FECRU&&FECRU.pageContext],d=0;d<c.length;d++)if("string"==typeof c[d]){b=c[d];break}return b}}(),function(){function a(a,b){b=b||"";var c=new RegExp(f(a)+"=([^|]+)"),d=b.match(c);return d&&d[1]}function b(a,b,c){var d=new RegExp("(\\s|\\|)*\\b"+f(a)+"=[^|]*[|]*");if(c=c||"",c=c.replace(d,"|"),""!==b){var e=a+"="+b;c.length+e.length<4020&&(c+="|"+e)}return c.replace(i,"|")}function c(a){return a.replace(h,"")}function d(a){var b=new RegExp("\\b"+f(a)+"=((?:[^\\\\;]+|\\\\.)*)(?:;|$)"),d=document.cookie.match(b);return d&&c(d[1])}function e(a,b,c){var d,e="",f='"'+b.replace(j,'\\"')+'"';c&&(d=new Date,d.setTime(+d+24*c*60*60*1e3),e="; expires="+d.toGMTString()),document.cookie=a+"="+f+e+";path=/"}function f(a){return a.replace(k,"\\$&")}var g="AJS.conglomerate.cookie",h=/(\\|^"|"$)/g,i=/\|\|+/g,j=/"/g,k=/[.*+?|^$()[\]{\\]/g;AJS.Cookie={save:function(a,c,f){var h=d(g);h=b(a,c,h),e(g,h,f||365)},read:function(b,c){var e=d(g),f=a(b,e);return null!=f?f:c},erase:function(a){this.save(a,"")}}}(),function(a){var b;AJS.dim=function(c,d){return b||(b=a(document.body)),c===!0&&AJS.log("DEPRECATED: useShim is calculated by dim() now"),AJS.dim.$dim||(AJS.dim.$dim=AJS("div").addClass("aui-blanket"),AJS.dim.$dim.attr("tabindex","0"),d&&AJS.dim.$dim.css({zIndex:d}),a.browser.msie&&AJS.dim.$dim.css({width:"200%",height:Math.max(a(document).height(),a(window).height())+"px"}),a("body").append(AJS.dim.$dim),AJS.dim.cachedOverflow=b.css("overflow"),b.css("overflow","hidden")),AJS.dim.$dim},AJS.undim=function(){if(AJS.dim.$dim&&(AJS.dim.$dim.remove(),AJS.dim.$dim=null,AJS.dim.$shim&&(AJS.dim.$shim.remove(),AJS.dim.$shim=null),b&&b.css("overflow",AJS.dim.cachedOverflow),a.browser.safari)){var c=a(window).scrollTop();a(window).scrollTop(10+5*(10==c)).scrollTop(c)}}}(AJS.$),function(a){function b(b){this.$el=a(b||'<div class="aui-layer" aria-hidden="true"></div>')}var c="_aui-internal-layer-",d="_aui-internal-layer-global-";b.prototype.changeSize=function(a,b){return this.$el.css("width",a),this.$el.css("height","content"===b?"":b),this},b.prototype.on=function(a,b){return this.$el.on(c+a,b),this},b.prototype.off=function(a,b){return this.$el.off(c+a,b),this},b.prototype.show=function(){if(this.$el.is(":visible"))return this;var b=AJS.$.Event(c+"beforeShow");this.$el.trigger(b);var e=AJS.$.Event(d+"beforeShow");return a(document).trigger(e,[this.$el]),b.isDefaultPrevented()||e.isDefaultPrevented()||(AJS.LayerManager.global.push(this.$el),this.$el.attr("data-aui-alignment")&&this.$el[0]._tether.enable()),this},b.prototype.hide=function(){if(!this.$el.is(":visible"))return this;var b=AJS.$.Event(c+"beforeHide");this.$el.trigger(b);var e=AJS.$.Event(d+"beforeHide");return a(document).trigger(e,[this.$el]),b.isDefaultPrevented()||e.isDefaultPrevented()||AJS.LayerManager.global.popUntil(this.$el),this},b.prototype.isVisible=function(){return"false"===this.$el.attr("aria-hidden")},b.prototype.remove=function(){this.hide(),this.$el[0]._tether&&this.$el[0]._tether.destroy(),this.$el.remove(),this.$el=null},b.prototype._showLayer=function(b){this.$el.parent().is("body")||this.$el.appendTo(document.body),this.$el.data("_aui-layer-cached-z-index",this.$el.css("z-index")),this.$el.css("z-index",b),this.$el.attr("aria-hidden","false"),AJS.FocusManager.global.enter(this.$el),this.$el.trigger(c+"show"),a(document).trigger(d+"show",[this.$el])},b.prototype._hideLayer=function(){AJS.FocusManager.global.exit(this.$el),this.$el.attr("aria-hidden","true"),this.$el.css("z-index",this.$el.data("_aui-layer-cached-z-index")||""),this.$el.data("_aui-layer-cached-z-index",""),this.$el.trigger(c+"hide"),a(document).trigger(d+"hide",[this.$el])},b.prototype.isBlanketed=function(){return"true"===this.$el.attr("data-aui-blanketed")},b.prototype.isModal=function(){return"true"===this.$el.attr("data-aui-modal")},AJS.layer=AJS._internal.widget("layer",b),AJS.layer.on=function(b,c){return a(document).on(d+b,c),this},AJS.layer.off=function(b,c){return a(document).off(d+b,c),this}}(AJS.$),AJS.popup=function(a){var b={width:800,height:600,closeOnOutsideClick:!1,keypressListener:function(a){27===a.keyCode&&c.is(":visible")&&i.hide()}};"object"!=typeof a&&(a={width:arguments[0],height:arguments[1],id:arguments[2]},a=AJS.$.extend({},a,arguments[3])),a=AJS.$.extend({},b,a);var c=AJS("div").addClass("aui-popup");a.id&&c.attr("id",a.id);var d=3e3;AJS.$(".aui-dialog").each(function(){var a=AJS.$(this);d=a.css("z-index")>d?a.css("z-index"):d});var e=function(b,e){return a.width=b=b||a.width,a.height=e=e||a.height,c.css({marginTop:-Math.round(e/2)+"px",marginLeft:-Math.round(b/2)+"px",width:b,height:e,"z-index":parseInt(d,10)+2}),arguments.callee}(a.width,a.height);AJS.$("body").append(c),c.hide(),AJS.enable(c);var f=AJS.$(".aui-blanket"),g=function(a,b){var c=AJS.$(a,b);return c.length?(c.focus(),!0):!1},h=function(b){if(0===AJS.$(".dialog-page-body",b).find(":focus").length){if(a.focusSelector)return g(a.focusSelector,b);var c=":input:visible:enabled:first";g(c,AJS.$(".dialog-page-body",b))||g(c,AJS.$(".dialog-button-panel",b))||g(c,AJS.$(".dialog-page-menu",b))}},i={changeSize:function(b,c){(b&&b!=a.width||c&&c!=a.height)&&e(b,c),this.show()},show:function(){var b=function(){AJS.$(document).off("keydown",a.keypressListener).on("keydown",a.keypressListener),AJS.dim(),f=AJS.$(".aui-blanket"),0!=f.size()&&a.closeOnOutsideClick&&f.click(function(){c.is(":visible")&&i.hide()}),c.show(),AJS.popup.current=this,h(c),AJS.$(document).trigger("showLayer",["popup",this])};b.call(this),this.show=b},hide:function(){AJS.$(document).unbind("keydown",a.keypressListener),f.unbind(),this.element.hide(),0==AJS.$(".aui-dialog:visible").size()&&AJS.undim();var b=document.activeElement;this.element.has(b).length&&b.blur(),AJS.$(document).trigger("hideLayer",["popup",this]),AJS.popup.current=null,this.enable()},element:c,remove:function(){c.remove(),this.element=null},disable:function(){this.disabled||(this.popupBlanket=AJS.$("<div class='dialog-blanket'> </div>").css({height:c.height(),width:c.width()}),c.append(this.popupBlanket),this.disabled=!0)},enable:function(){this.disabled&&(this.disabled=!1,this.popupBlanket.remove(),this.popupBlanket=null)}};return i},function(){function a(a,b,c,d){a.buttonpanel||a.addButtonPanel(),this.page=a,this.onclick=c,this._onclick=function(b){return c.call(this,a.dialog,a,b)===!0},this.item=AJS("button",b).addClass("button-panel-button"),d&&this.item.addClass(d),"function"==typeof c&&this.item.click(this._onclick),a.buttonpanel.append(this.item),this.id=a.button.length,a.button[this.id]=this}function b(a,b,c,d,e){a.buttonpanel||a.addButtonPanel(),e||(e="#"),this.page=a,this.onclick=c,this._onclick=function(b){return c.call(this,a.dialog,a,b)===!0},this.item=AJS("a",b).attr("href",e).addClass("button-panel-link"),d&&this.item.addClass(d),"function"==typeof c&&this.item.click(this._onclick),a.buttonpanel.append(this.item),this.id=a.button.length,a.button[this.id]=this}function c(a,b){var c="left"==a?-1:1;return function(a){var d=this.page[b];if(this.id!=(1==c?d.length-1:0)){c*=a||1,d[this.id+c].item[0>c?"before":"after"](this.item),d.splice(this.id,1),d.splice(this.id+c,0,this);for(var e=0,f=d.length;f>e;e++)"panel"==b&&this.page.curtab==d[e].id&&(this.page.curtab=e),d[e].id=e}return this}}function d(a){return function(){this.page[a].splice(this.id,1);for(var b=0,c=this.page[a].length;c>b;b++)this.page[a][b].id=b;this.item.remove()}}a.prototype.moveUp=a.prototype.moveLeft=c("left","button"),a.prototype.moveDown=a.prototype.moveRight=c("right","button"),a.prototype.remove=d("button"),a.prototype.html=function(a){return this.item.html(a)},a.prototype.onclick=function(a){return"undefined"==typeof a?this.onclick:(this.item.unbind("click",this._onclick),this._onclick=function(b){return a.call(this,page.dialog,page,b)===!0},"function"==typeof a&&this.item.click(this._onclick),void 0)};var e=20,f=function(a,b,c,d,f){c instanceof AJS.$||(c=AJS.$(c)),this.dialog=a.dialog,this.page=a,this.id=a.panel.length,this.button=AJS("button").html(b).addClass("item-button"),f&&(this.button[0].id=f),this.item=AJS("li").append(this.button).addClass("page-menu-item"),this.body=AJS("div").append(c).addClass("dialog-panel-body").css("height",a.dialog.height+"px"),this.padding=e,d&&this.body.addClass(d);var g=a.panel.length,h=this;a.menu.append(this.item),a.body.append(this.body),a.panel[g]=this;var i=function(){var b;a.curtab+1&&(b=a.panel[a.curtab],b.body.hide(),b.item.removeClass("selected"),"function"==typeof b.onblur&&b.onblur()),a.curtab=h.id,h.body.show(),h.item.addClass("selected"),"function"==typeof h.onselect&&h.onselect(),"function"==typeof a.ontabchange&&a.ontabchange(h,b)};this.button.click?this.button.click(i):(AJS.log("atlassian-dialog:Panel:constructor - this.button.click false"),this.button.onclick=i),i(),0==g?a.menu.css("display","none"):a.menu.show()};f.prototype.select=function(){this.button.click()},f.prototype.moveUp=f.prototype.moveLeft=c("left","panel"),f.prototype.moveDown=f.prototype.moveRight=c("right","panel"),f.prototype.remove=d("panel"),f.prototype.html=function(a){return a?(this.body.html(a),this):this.body.html()},f.prototype.setPadding=function(a){return isNaN(+a)||(this.body.css("padding",+a),this.padding=+a,this.page.recalcSize()),this};var g=56,h=51,i=50,j=function(a,b){this.dialog=a,this.id=a.page.length,this.element=AJS("div").addClass("dialog-components"),this.body=AJS("div").addClass("dialog-page-body"),this.menu=AJS("ul").addClass("dialog-page-menu").css("height",a.height+"px"),this.body.append(this.menu),this.curtab,this.panel=[],this.button=[],b&&this.body.addClass(b),a.popup.element.append(this.element.append(this.menu).append(this.body)),a.page[a.page.length]=this};j.prototype.recalcSize=function(){for(var a=this.header?g:0,b=this.buttonpanel?h:0,c=this.panel.length;c--;){var d=this.dialog.height-a-b;this.panel[c].body.css("height",d),this.menu.css("height",d)}},j.prototype.addButtonPanel=function(){this.buttonpanel=AJS("div").addClass("dialog-button-panel"),this.element.append(this.buttonpanel)},j.prototype.addPanel=function(a,b,c,d){return new f(this,a,b,c,d),this.recalcSize(),this},j.prototype.addHeader=function(a,b){return this.header&&this.header.remove(),this.header=AJS("h2").text(a||"").addClass("dialog-title"),b&&this.header.addClass(b),this.element.prepend(this.header),this.recalcSize(),this},j.prototype.addButton=function(b,c,d){return new a(this,b,c,d),this.recalcSize(),this},j.prototype.addLink=function(a,c,d,e){return new b(this,a,c,d,e),this.recalcSize(),this},j.prototype.gotoPanel=function(a){this.panel[a.id||a].select()},j.prototype.getCurrentPanel=function(){return this.panel[this.curtab]},j.prototype.hide=function(){this.element.hide()},j.prototype.show=function(){this.element.show()},j.prototype.remove=function(){this.element.remove()},AJS.Dialog=function(a,b,c){var d={};+a||(d=Object(a),a=d.width,b=d.height,c=d.id),this.height=b||480,this.width=a||640,this.id=c,d=AJS.$.extend({},d,{width:this.width,height:this.height,id:this.id}),this.popup=AJS.popup(d),this.popup.element.addClass("aui-dialog"),this.page=[],this.curpage=0,new j(this)},AJS.Dialog.prototype.addHeader=function(a,b){return this.page[this.curpage].addHeader(a,b),this},AJS.Dialog.prototype.addButton=function(a,b,c){return this.page[this.curpage].addButton(a,b,c),this},AJS.Dialog.prototype.addLink=function(a,b,c,d){return this.page[this.curpage].addLink(a,b,c,d),this},AJS.Dialog.prototype.addSubmit=function(a,b){return this.page[this.curpage].addButton(a,b,"button-panel-submit-button"),this},AJS.Dialog.prototype.addCancel=function(a,b){return this.page[this.curpage].addLink(a,b,"button-panel-cancel-link"),this},AJS.Dialog.prototype.addButtonPanel=function(){return this.page[this.curpage].addButtonPanel(),this},AJS.Dialog.prototype.addPanel=function(a,b,c,d){return this.page[this.curpage].addPanel(a,b,c,d),this},AJS.Dialog.prototype.addPage=function(a){return new j(this,a),this.page[this.curpage].hide(),this.curpage=this.page.length-1,this},AJS.Dialog.prototype.nextPage=function(){return this.page[this.curpage++].hide(),this.curpage>=this.page.length&&(this.curpage=0),this.page[this.curpage].show(),this},AJS.Dialog.prototype.prevPage=function(){return this.page[this.curpage--].hide(),this.curpage<0&&(this.curpage=this.page.length-1),this.page[this.curpage].show(),this},AJS.Dialog.prototype.gotoPage=function(a){return this.page[this.curpage].hide(),this.curpage=a,this.curpage<0?this.curpage=this.page.length-1:this.curpage>=this.page.length&&(this.curpage=0),this.page[this.curpage].show(),this},AJS.Dialog.prototype.getPanel=function(a,b){var c=null==b?this.curpage:a; return null==b&&(b=a),this.page[c].panel[b]},AJS.Dialog.prototype.getPage=function(a){return this.page[a]},AJS.Dialog.prototype.getCurrentPanel=function(){return this.page[this.curpage].getCurrentPanel()},AJS.Dialog.prototype.gotoPanel=function(a,b){if(null!=b){var c=a.id||a;this.gotoPage(c)}this.page[this.curpage].gotoPanel("undefined"==typeof b?a:b)},AJS.Dialog.prototype.show=function(){return this.popup.show(),AJS.trigger("show.dialog",{dialog:this}),this},AJS.Dialog.prototype.hide=function(){return this.popup.hide(),AJS.trigger("hide.dialog",{dialog:this}),this},AJS.Dialog.prototype.remove=function(){this.popup.hide(),this.popup.remove(),AJS.trigger("remove.dialog",{dialog:this})},AJS.Dialog.prototype.disable=function(){return this.popup.disable(),this},AJS.Dialog.prototype.enable=function(){return this.popup.enable(),this},AJS.Dialog.prototype.get=function(a){var b=[],c=this,d='#([^"][^ ]*|"[^"]*")',e=":(\\d+)",f="page|panel|button|header",g="(?:("+f+")(?:"+d+"|"+e+")?|"+d+")",h=new RegExp("(?:^|,)\\s*"+g+"(?:\\s+"+g+")?\\s*(?=,|$)","ig");(a+"").replace(h,function(a,d,e,f,g,h,i,j,k){d=d&&d.toLowerCase();var l=[];if("page"==d&&c.page[f]?(l.push(c.page[f]),d=h,d=d&&d.toLowerCase(),e=i,f=j,g=k):l=c.page,e=e&&(e+"").replace(/"/g,""),i=i&&(i+"").replace(/"/g,""),g=g&&(g+"").replace(/"/g,""),k=k&&(k+"").replace(/"/g,""),d||g)for(var m=l.length;m--;){if(g||"panel"==d&&(e||!e&&null==f))for(var n=l[m].panel.length;n--;)(l[m].panel[n].button.html()==g||l[m].panel[n].button.html()==e||"panel"==d&&!e&&null==f)&&b.push(l[m].panel[n]);if(g||"button"==d&&(e||!e&&null==f))for(var n=l[m].button.length;n--;)(l[m].button[n].item.html()==g||l[m].button[n].item.html()==e||"button"==d&&!e&&null==f)&&b.push(l[m].button[n]);l[m][d]&&l[m][d][f]&&b.push(l[m][d][f]),"header"==d&&l[m].header&&b.push(l[m].header)}else b=b.concat(l)});for(var i={length:b.length},j=b.length;j--;){i[j]=b[j];for(var k in b[j])k in i||!function(a){i[a]=function(){for(var b=this.length;b--;)"function"==typeof this[b][a]&&this[b][a].apply(this[b],arguments)}}(k)}return i},AJS.Dialog.prototype.updateHeight=function(){for(var a=0,b=AJS.$(window).height()-g-h-2*i,c=0;this.getPanel(c);c++)this.getPanel(c).body.css({height:"auto",display:"block"}).outerHeight()>a&&(a=Math.min(b,this.getPanel(c).body.outerHeight())),c!==this.page[this.curpage].curtab&&this.getPanel(c).body.css({display:"none"});for(c=0;this.getPanel(c);c++)this.getPanel(c).body.css({height:a||this.height});this.page[0].menu.height(a),this.height=a+g+h+1,this.popup.changeSize(void 0,this.height)},AJS.Dialog.prototype.isMaximised=function(){return this.popup.element.outerHeight()>=AJS.$(window).height()-2*i},AJS.Dialog.prototype.getCurPanel=function(){return this.getPanel(this.page[this.curpage].curtab)},AJS.Dialog.prototype.getCurPanelButton=function(){return this.getCurPanel().button}}(),function(a){function b(a){jQuery.each(e,function(b,c){var d="data-"+b;a[0].hasAttribute(d)||a.attr(d,c)})}function c(c){this.$el=a(c?c:AJS.parseHtml(a(aui.dialog.dialog2({})))),b(this.$el)}function d(b){AJS.layer.on(b,function(c,d){if(d.is(".aui-dialog2")){var e=AJS.$.Event(f+b);return a(document).trigger(e,[d]),!e.isDefaultPrevented()}return!0})}var e={"aui-focus":"false","aui-blanketed":"true"};c.prototype.on=function(a,b){return AJS.layer(this.$el).on(a,b),this},c.prototype.off=function(a,b){return AJS.layer(this.$el).off(a,b),this},c.prototype.show=function(){var a=AJS.layer(this.$el);return a.show(),this},c.prototype.hide=function(){return AJS.layer(this.$el).hide(),this},c.prototype.remove=function(){return AJS.layer(this.$el).remove(),this},AJS.dialog2=AJS._internal.widget("dialog2",c);for(var f="_aui-internal-dialog2-global-",g=["show","hide","beforeShow","beforeHide"],h=0;h<g.length;++h)d(g[h]);AJS.dialog2.on=function(b,c){return a(document).on(f+b,c),this},AJS.dialog2.off=function(b,c){return a(document).off(f+b,c),this},a(document).on("click",".aui-dialog2-header-close",function(b){b.preventDefault(),AJS.dialog2(a(this).closest(".aui-dialog2")).hide()}),AJS.dialog2.on("show",function(a,b){var c,d=[".aui-dialog2-content",".aui-dialog2-footer",".aui-dialog2-header"];d.some(function(a){return c=b.find(a+" :aui-tabbable"),c.length}),c&&c.first().focus()}),AJS.dialog2.on("hide",function(a,b){var c=AJS.layer(b);b.data("aui-remove-on-hide")&&c.remove()})}(AJS.$),function(a){"use strict";var b=0;AJS.DatePicker=function(c,d){var e,f,g,h;return e={},h=b++,g=a(c),g.attr("data-aui-dp-uuid",h),d=a.extend(void 0,AJS.DatePicker.prototype.defaultOptions,d),e.getField=function(){return g},e.getOptions=function(){return d},f=function(){var b,c,f,i,j,k,l,m,n,o;e.hide=function(){n.hide()},e.show=function(){n.show()},e.setDate=function(a){"undefined"!=typeof b&&b.datepicker("setDate",a)},e.getDate=function(){return"undefined"!=typeof b?b.datepicker("getDate"):void 0},k=function(c){if(o.off(),d.hint){var i=a("<div/>").addClass("aui-datepicker-hint");i.append("<span/>").text(d.hint),o.append(i)}b=a("<div/>"),b.attr("data-aui-dp-popup-uuid",h),o.append(b);var k={dateFormat:d.dateFormat,defaultDate:g.val(),maxDate:g.attr("max"),minDate:g.attr("min"),nextText:">",onSelect:function(a){g.val(a),g.change(),e.hide(),l=!0,g.focus(),d.onSelect&&d.onSelect.call(this,a)},onChangeMonthYear:function(){setTimeout(n.refresh,0)},prevText:"<"};a.extend(k,c),d.firstDay>-1&&(k.firstDay=d.firstDay),"undefined"!=typeof g.attr("step")&&AJS.log("WARNING: The AJS date picker polyfill currently does not support the step attribute!"),b.datepicker(k),g.on("focusout",f),g.on("propertychange keyup input paste",j)},c=function(b){var c=a(b.target);b.preventDefault(),c.closest(o).length||c.is(g)||c.closest(".ui-datepicker-header").length||e.hide()},f=function(){m||(a("body").on("focus blur click mousedown","*",c),m=!0)},i=function(){l?l=!1:e.show()},j=function(){var c=a(this).val();c&&(b.datepicker("setDate",g.val()),b.datepicker("option",{maxDate:g.attr("max"),minDate:g.attr("min")}))},e.destroyPolyfill=function(){e.hide(),g.attr("placeholder",null),g.off("propertychange keyup input paste",j),g.off("focus click",i),g.off("focusout",f),AJS.DatePicker.prototype.browserSupportsDateField&&(g[0].type="date"),"undefined"!=typeof b&&b.datepicker("destroy"),delete e.destroyPolyfill,delete e.show,delete e.hide},l=!1,m=!1,d.languageCode in AJS.DatePicker.prototype.localisations||(d.languageCode="");var p=AJS.DatePicker.prototype.localisations[d.languageCode],q="",r=240;"large"===p.size&&(r=325,q="aui-datepicker-dialog-large");var s={hideCallback:function(){a("body").off("focus blur click mousedown","*",c),m=!1},hideDelay:null,noBind:!0,persistent:!0,width:r};d.position&&(s.calculatePositions=function(b,c){var e=a(b[0]);return d.position.call(this,e,c)}),n=AJS.InlineDialog(g,void 0,function(a,c,d){"undefined"==typeof b&&(o=a,k(p)),d()},s),n.addClass("aui-datepicker-dialog"),n.addClass(q),g.on("focus click",i),g.attr("placeholder",d.dateFormat),d.overrideBrowserDefault&&AJS.DatePicker.prototype.browserSupportsDateField&&(g[0].type="text")},e.reset=function(){"function"==typeof e.destroyPolyfill&&e.destroyPolyfill(),(!AJS.DatePicker.prototype.browserSupportsDateField||d.overrideBrowserDefault)&&f()},e.reset(),e},AJS.DatePicker.prototype.browserSupportsDateField="date"===a('<input type="date" />')[0].type,AJS.DatePicker.prototype.defaultOptions={overrideBrowserDefault:!1,firstDay:-1,languageCode:AJS.$("html").attr("lang")||"en-AU",dateFormat:a.datepicker.W3C},AJS.DatePicker.prototype.localisations={"":{dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayNamesMin:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],firstDay:0,isRTL:!1,monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],showMonthAfterYear:!1,yearSuffix:""},af:{dayNames:["Sondag","Maandag","Dinsdag","Woensdag","Donderdag","Vrydag","Saterdag"],dayNamesMin:["Son","Maa","Din","Woe","Don","Vry","Sat"],firstDay:1,isRTL:!1,monthNames:["Januarie","Februarie","Maart","April","Mei","Junie","Julie","Augustus","September","Oktober","November","Desember"],showMonthAfterYear:!1,yearSuffix:""},"ar-DZ":{dayNames:["\u0627\u0644\u0623\u062d\u062f","\u0627\u0644\u0627\u062b\u0646\u064a\u0646","\u0627\u0644\u062b\u0644\u0627\u062b\u0627\u0621","\u0627\u0644\u0623\u0631\u0628\u0639\u0627\u0621","\u0627\u0644\u062e\u0645\u064a\u0633","\u0627\u0644\u062c\u0645\u0639\u0629","\u0627\u0644\u0633\u0628\u062a"],dayNamesMin:["\u0627\u0644\u0623\u062d\u062f","\u0627\u0644\u0627\u062b\u0646\u064a\u0646","\u0627\u0644\u062b\u0644\u0627\u062b\u0627\u0621","\u0627\u0644\u0623\u0631\u0628\u0639\u0627\u0621","\u0627\u0644\u062e\u0645\u064a\u0633","\u0627\u0644\u062c\u0645\u0639\u0629","\u0627\u0644\u0633\u0628\u062a"],firstDay:6,isRTL:!0,monthNames:["\u062c\u0627\u0646\u0641\u064a","\u0641\u064a\u0641\u0631\u064a","\u0645\u0627\u0631\u0633","\u0623\u0641\u0631\u064a\u0644","\u0645\u0627\u064a","\u062c\u0648\u0627\u0646","\u062c\u0648\u064a\u0644\u064a\u0629","\u0623\u0648\u062a","\u0633\u0628\u062a\u0645\u0628\u0631","\u0623\u0643\u062a\u0648\u0628\u0631","\u0646\u0648\u0641\u0645\u0628\u0631","\u062f\u064a\u0633\u0645\u0628\u0631"],showMonthAfterYear:!1,yearSuffix:""},ar:{dayNames:["\u0627\u0644\u0623\u062d\u062f","\u0627\u0644\u0627\u062b\u0646\u064a\u0646","\u0627\u0644\u062b\u0644\u0627\u062b\u0627\u0621","\u0627\u0644\u0623\u0631\u0628\u0639\u0627\u0621","\u0627\u0644\u062e\u0645\u064a\u0633","\u0627\u0644\u062c\u0645\u0639\u0629","\u0627\u0644\u0633\u0628\u062a"],dayNamesMin:["\u0627\u0644\u0623\u062d\u062f","\u0627\u0644\u0627\u062b\u0646\u064a\u0646","\u0627\u0644\u062b\u0644\u0627\u062b\u0627\u0621","\u0627\u0644\u0623\u0631\u0628\u0639\u0627\u0621","\u0627\u0644\u062e\u0645\u064a\u0633","\u0627\u0644\u062c\u0645\u0639\u0629","\u0627\u0644\u0633\u0628\u062a"],firstDay:6,isRTL:!0,monthNames:["\u0643\u0627\u0646\u0648\u0646 \u0627\u0644\u062b\u0627\u0646\u064a","\u0634\u0628\u0627\u0637","\u0622\u0630\u0627\u0631","\u0646\u064a\u0633\u0627\u0646","\u0645\u0627\u064a\u0648","\u062d\u0632\u064a\u0631\u0627\u0646","\u062a\u0645\u0648\u0632","\u0622\u0628","\u0623\u064a\u0644\u0648\u0644","\u062a\u0634\u0631\u064a\u0646 \u0627\u0644\u0623\u0648\u0644","\u062a\u0634\u0631\u064a\u0646 \u0627\u0644\u062b\u0627\u0646\u064a","\u0643\u0627\u0646\u0648\u0646 \u0627\u0644\u0623\u0648\u0644"],showMonthAfterYear:!1,yearSuffix:""},az:{dayNames:["Bazar","Bazar ert\u0259si","\xc7\u0259r\u015f\u0259nb\u0259 ax\u015fam\u0131","\xc7\u0259r\u015f\u0259nb\u0259","C\xfcm\u0259 ax\u015fam\u0131","C\xfcm\u0259","\u015e\u0259nb\u0259"],dayNamesMin:["B","Be","\xc7a","\xc7","Ca","C","\u015e"],firstDay:1,isRTL:!1,monthNames:["Yanvar","Fevral","Mart","Aprel","May","\u0130yun","\u0130yul","Avqust","Sentyabr","Oktyabr","Noyabr","Dekabr"],showMonthAfterYear:!1,yearSuffix:""},bg:{dayNames:["\u041d\u0435\u0434\u0435\u043b\u044f","\u041f\u043e\u043d\u0435\u0434\u0435\u043b\u043d\u0438\u043a","\u0412\u0442\u043e\u0440\u043d\u0438\u043a","\u0421\u0440\u044f\u0434\u0430","\u0427\u0435\u0442\u0432\u044a\u0440\u0442\u044a\u043a","\u041f\u0435\u0442\u044a\u043a","\u0421\u044a\u0431\u043e\u0442\u0430"],dayNamesMin:["\u041d\u0435\u0434","\u041f\u043e\u043d","\u0412\u0442\u043e","\u0421\u0440\u044f","\u0427\u0435\u0442","\u041f\u0435\u0442","\u0421\u044a\u0431"],firstDay:1,isRTL:!1,monthNames:["\u042f\u043d\u0443\u0430\u0440\u0438","\u0424\u0435\u0432\u0440\u0443\u0430\u0440\u0438","\u041c\u0430\u0440\u0442","\u0410\u043f\u0440\u0438\u043b","\u041c\u0430\u0439","\u042e\u043d\u0438","\u042e\u043b\u0438","\u0410\u0432\u0433\u0443\u0441\u0442","\u0421\u0435\u043f\u0442\u0435\u043c\u0432\u0440\u0438","\u041e\u043a\u0442\u043e\u043c\u0432\u0440\u0438","\u041d\u043e\u0435\u043c\u0432\u0440\u0438","\u0414\u0435\u043a\u0435\u043c\u0432\u0440\u0438"],showMonthAfterYear:!1,yearSuffix:""},bs:{dayNames:["Nedelja","Ponedeljak","Utorak","Srijeda","\u010cetvrtak","Petak","Subota"],dayNamesMin:["Ned","Pon","Uto","Sri","\u010cet","Pet","Sub"],firstDay:1,isRTL:!1,monthNames:["Januar","Februar","Mart","April","Maj","Juni","Juli","August","Septembar","Oktobar","Novembar","Decembar"],showMonthAfterYear:!1,yearSuffix:""},ca:{dayNames:["Diumenge","Dilluns","Dimarts","Dimecres","Dijous","Divendres","Dissabte"],dayNamesMin:["Dug","Dln","Dmt","Dmc","Djs","Dvn","Dsb"],firstDay:1,isRTL:!1,monthNames:["Gener","Febrer","Mar&ccedil;","Abril","Maig","Juny","Juliol","Agost","Setembre","Octubre","Novembre","Desembre"],showMonthAfterYear:!1,yearSuffix:""},cs:{dayNames:["ned\u011ble","pond\u011bl\xed","\xfater\xfd","st\u0159eda","\u010dtvrtek","p\xe1tek","sobota"],dayNamesMin:["ne","po","\xfat","st","\u010dt","p\xe1","so"],firstDay:1,isRTL:!1,monthNames:["leden","\xfanor","b\u0159ezen","duben","kv\u011bten","\u010derven","\u010dervenec","srpen","z\xe1\u0159\xed","\u0159\xedjen","listopad","prosinec"],showMonthAfterYear:!1,yearSuffix:""},da:{dayNames:["S\xf8ndag","Mandag","Tirsdag","Onsdag","Torsdag","Fredag","L\xf8rdag"],dayNamesMin:["S\xf8n","Man","Tir","Ons","Tor","Fre","L\xf8r"],firstDay:1,isRTL:!1,monthNames:["Januar","Februar","Marts","April","Maj","Juni","Juli","August","September","Oktober","November","December"],showMonthAfterYear:!1,yearSuffix:""},de:{dayNames:["Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag"],dayNamesMin:["So","Mo","Di","Mi","Do","Fr","Sa"],firstDay:1,isRTL:!1,monthNames:["Januar","Februar","M\xe4rz","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember"],showMonthAfterYear:!1,yearSuffix:""},el:{dayNames:["\u039a\u03c5\u03c1\u03b9\u03b1\u03ba\u03ae","\u0394\u03b5\u03c5\u03c4\u03ad\u03c1\u03b1","\u03a4\u03c1\u03af\u03c4\u03b7","\u03a4\u03b5\u03c4\u03ac\u03c1\u03c4\u03b7","\u03a0\u03ad\u03bc\u03c0\u03c4\u03b7","\u03a0\u03b1\u03c1\u03b1\u03c3\u03ba\u03b5\u03c5\u03ae","\u03a3\u03ac\u03b2\u03b2\u03b1\u03c4\u03bf"],dayNamesMin:["\u039a\u03c5\u03c1","\u0394\u03b5\u03c5","\u03a4\u03c1\u03b9","\u03a4\u03b5\u03c4","\u03a0\u03b5\u03bc","\u03a0\u03b1\u03c1","\u03a3\u03b1\u03b2"],firstDay:1,isRTL:!1,monthNames:["\u0399\u03b1\u03bd\u03bf\u03c5\u03ac\u03c1\u03b9\u03bf\u03c2","\u03a6\u03b5\u03b2\u03c1\u03bf\u03c5\u03ac\u03c1\u03b9\u03bf\u03c2","\u039c\u03ac\u03c1\u03c4\u03b9\u03bf\u03c2","\u0391\u03c0\u03c1\u03af\u03bb\u03b9\u03bf\u03c2","\u039c\u03ac\u03b9\u03bf\u03c2","\u0399\u03bf\u03cd\u03bd\u03b9\u03bf\u03c2","\u0399\u03bf\u03cd\u03bb\u03b9\u03bf\u03c2","\u0391\u03cd\u03b3\u03bf\u03c5\u03c3\u03c4\u03bf\u03c2","\u03a3\u03b5\u03c0\u03c4\u03ad\u03bc\u03b2\u03c1\u03b9\u03bf\u03c2","\u039f\u03ba\u03c4\u03ce\u03b2\u03c1\u03b9\u03bf\u03c2","\u039d\u03bf\u03ad\u03bc\u03b2\u03c1\u03b9\u03bf\u03c2","\u0394\u03b5\u03ba\u03ad\u03bc\u03b2\u03c1\u03b9\u03bf\u03c2"],showMonthAfterYear:!1,yearSuffix:""},"en-AU":{dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayNamesMin:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],firstDay:1,isRTL:!1,monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],showMonthAfterYear:!1,yearSuffix:""},"en-GB":{dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayNamesMin:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],firstDay:1,isRTL:!1,monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],showMonthAfterYear:!1,yearSuffix:""},"en-NZ":{dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayNamesMin:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],firstDay:1,isRTL:!1,monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],showMonthAfterYear:!1,yearSuffix:""},eo:{dayNames:["Diman\u0109o","Lundo","Mardo","Merkredo","\u0134a\u016ddo","Vendredo","Sabato"],dayNamesMin:["Dim","Lun","Mar","Mer","\u0134a\u016d","Ven","Sab"],firstDay:0,isRTL:!1,monthNames:["Januaro","Februaro","Marto","Aprilo","Majo","Junio","Julio","A\u016dgusto","Septembro","Oktobro","Novembro","Decembro"],showMonthAfterYear:!1,yearSuffix:""},es:{dayNames:["Domingo","Lunes","Martes","Mi&eacute;rcoles","Jueves","Viernes","S&aacute;bado"],dayNamesMin:["Dom","Lun","Mar","Mi&eacute;","Juv","Vie","S&aacute;b"],firstDay:1,isRTL:!1,monthNames:["Enero","Febrero","Marzo","Abril","Mayo","Junio","Julio","Agosto","Septiembre","Octubre","Noviembre","Diciembre"],showMonthAfterYear:!1,yearSuffix:""},et:{dayNames:["P\xfchap\xe4ev","Esmasp\xe4ev","Teisip\xe4ev","Kolmap\xe4ev","Neljap\xe4ev","Reede","Laup\xe4ev"],dayNamesMin:["P\xfchap","Esmasp","Teisip","Kolmap","Neljap","Reede","Laup"],firstDay:1,isRTL:!1,monthNames:["Jaanuar","Veebruar","M\xe4rts","Aprill","Mai","Juuni","Juuli","August","September","Oktoober","November","Detsember"],showMonthAfterYear:!1,yearSuffix:"",size:"large"},eu:{dayNames:["Igandea","Astelehena","Asteartea","Asteazkena","Osteguna","Ostirala","Larunbata"],dayNamesMin:["Iga","Ast","Ast","Ast","Ost","Ost","Lar"],firstDay:1,isRTL:!1,monthNames:["Urtarrila","Otsaila","Martxoa","Apirila","Maiatza","Ekaina","Uztaila","Abuztua","Iraila","Urria","Azaroa","Abendua"],showMonthAfterYear:!1,yearSuffix:""},fa:{dayNames:["\u064a\u06a9\u0634\u0646\u0628\u0647","\u062f\u0648\u0634\u0646\u0628\u0647","\u0633\u0647\u0634\u0646\u0628\u0647","\u0686\u0647\u0627\u0631\u0634\u0646\u0628\u0647","\u067e\u0646\u062c\u0634\u0646\u0628\u0647","\u062c\u0645\u0639\u0647","\u0634\u0646\u0628\u0647"],dayNamesMin:["\u064a","\u062f","\u0633","\u0686","\u067e","\u062c","\u0634"],firstDay:6,isRTL:!0,monthNames:["\u0641\u0631\u0648\u0631\u062f\u064a\u0646","\u0627\u0631\u062f\u064a\u0628\u0647\u0634\u062a","\u062e\u0631\u062f\u0627\u062f","\u062a\u064a\u0631","\u0645\u0631\u062f\u0627\u062f","\u0634\u0647\u0631\u064a\u0648\u0631","\u0645\u0647\u0631","\u0622\u0628\u0627\u0646","\u0622\u0630\u0631","\u062f\u064a","\u0628\u0647\u0645\u0646","\u0627\u0633\u0641\u0646\u062f"],showMonthAfterYear:!1,yearSuffix:""},fi:{dayNames:["Sunnuntai","Maanantai","Tiistai","Keskiviikko","Torstai","Perjantai","Lauantai"],dayNamesMin:["Su","Ma","Ti","Ke","To","Pe","Su"],firstDay:1,isRTL:!1,monthNames:["Tammikuu","Helmikuu","Maaliskuu","Huhtikuu","Toukokuu","Kes&auml;kuu","Hein&auml;kuu","Elokuu","Syyskuu","Lokakuu","Marraskuu","Joulukuu"],showMonthAfterYear:!1,yearSuffix:""},fo:{dayNames:["Sunnudagur","M\xe1nadagur","T\xfdsdagur","Mikudagur","H\xf3sdagur","Fr\xedggjadagur","Leyardagur"],dayNamesMin:["Sun","M\xe1n","T\xfds","Mik","H\xf3s","Fr\xed","Ley"],firstDay:0,isRTL:!1,monthNames:["Januar","Februar","Mars","Apr\xedl","Mei","Juni","Juli","August","September","Oktober","November","Desember"],showMonthAfterYear:!1,yearSuffix:""},"fr-CH":{dayNames:["Dimanche","Lundi","Mardi","Mercredi","Jeudi","Vendredi","Samedi"],dayNamesMin:["Dim","Lun","Mar","Mer","Jeu","Ven","Sam"],firstDay:1,isRTL:!1,monthNames:["Janvier","F\xe9vrier","Mars","Avril","Mai","Juin","Juillet","Ao\xfbt","Septembre","Octobre","Novembre","D\xe9cembre"],showMonthAfterYear:!1,yearSuffix:""},fr:{dayNames:["Dimanche","Lundi","Mardi","Mercredi","Jeudi","Vendredi","Samedi"],dayNamesMin:["Dim.","Lun.","Mar.","Mer.","Jeu.","Ven.","Sam."],firstDay:1,isRTL:!1,monthNames:["Janvier","F\xe9vrier","Mars","Avril","Mai","Juin","Juillet","Ao\xfbt","Septembre","Octobre","Novembre","D\xe9cembre"],showMonthAfterYear:!1,yearSuffix:""},gl:{dayNames:["Domingo","Luns","Martes","M&eacute;rcores","Xoves","Venres","S&aacute;bado"],dayNamesMin:["Dom","Lun","Mar","M&eacute;r","Xov","Ven","S&aacute;b"],firstDay:1,isRTL:!1,monthNames:["Xaneiro","Febreiro","Marzo","Abril","Maio","Xu\xf1o","Xullo","Agosto","Setembro","Outubro","Novembro","Decembro"],showMonthAfterYear:!1,yearSuffix:""},he:{dayNames:["\u05e8\u05d0\u05e9\u05d5\u05df","\u05e9\u05e0\u05d9","\u05e9\u05dc\u05d9\u05e9\u05d9","\u05e8\u05d1\u05d9\u05e2\u05d9","\u05d7\u05de\u05d9\u05e9\u05d9","\u05e9\u05d9\u05e9\u05d9","\u05e9\u05d1\u05ea"],dayNamesMin:["\u05d0'","\u05d1'","\u05d2'","\u05d3'","\u05d4'","\u05d5'","\u05e9\u05d1\u05ea"],firstDay:0,isRTL:!0,monthNames:["\u05d9\u05e0\u05d5\u05d0\u05e8","\u05e4\u05d1\u05e8\u05d5\u05d0\u05e8","\u05de\u05e8\u05e5","\u05d0\u05e4\u05e8\u05d9\u05dc","\u05de\u05d0\u05d9","\u05d9\u05d5\u05e0\u05d9","\u05d9\u05d5\u05dc\u05d9","\u05d0\u05d5\u05d2\u05d5\u05e1\u05d8","\u05e1\u05e4\u05d8\u05de\u05d1\u05e8","\u05d0\u05d5\u05e7\u05d8\u05d5\u05d1\u05e8","\u05e0\u05d5\u05d1\u05de\u05d1\u05e8","\u05d3\u05e6\u05de\u05d1\u05e8"],showMonthAfterYear:!1,yearSuffix:""},hr:{dayNames:["Nedjelja","Ponedjeljak","Utorak","Srijeda","\u010cetvrtak","Petak","Subota"],dayNamesMin:["Ned","Pon","Uto","Sri","\u010cet","Pet","Sub"],firstDay:1,isRTL:!1,monthNames:["Sije\u010danj","Velja\u010da","O\u017eujak","Travanj","Svibanj","Lipanj","Srpanj","Kolovoz","Rujan","Listopad","Studeni","Prosinac"],showMonthAfterYear:!1,yearSuffix:""},hu:{dayNames:["Vas\xe1rnap","H\xe9tf\xf6","Kedd","Szerda","Cs\xfct\xf6rt\xf6k","P\xe9ntek","Szombat"],dayNamesMin:["Vas","H\xe9t","Ked","Sze","Cs\xfc","P\xe9n","Szo"],firstDay:1,isRTL:!1,monthNames:["Janu\xe1r","Febru\xe1r","M\xe1rcius","\xc1prilis","M\xe1jus","J\xfanius","J\xfalius","Augusztus","Szeptember","Okt\xf3ber","November","December"],showMonthAfterYear:!0,yearSuffix:""},hy:{dayNames:["\u056f\u056b\u0580\u0561\u056f\u056b","\u0565\u056f\u0578\u0582\u0577\u0561\u0562\u0569\u056b","\u0565\u0580\u0565\u0584\u0577\u0561\u0562\u0569\u056b","\u0579\u0578\u0580\u0565\u0584\u0577\u0561\u0562\u0569\u056b","\u0570\u056b\u0576\u0563\u0577\u0561\u0562\u0569\u056b","\u0578\u0582\u0580\u0562\u0561\u0569","\u0577\u0561\u0562\u0561\u0569"],dayNamesMin:["\u056f\u056b\u0580","\u0565\u0580\u056f","\u0565\u0580\u0584","\u0579\u0580\u0584","\u0570\u0576\u0563","\u0578\u0582\u0580\u0562","\u0577\u0562\u0569"],firstDay:1,isRTL:!1,monthNames:["\u0540\u0578\u0582\u0576\u057e\u0561\u0580","\u0553\u0565\u057f\u0580\u057e\u0561\u0580","\u0544\u0561\u0580\u057f","\u0531\u057a\u0580\u056b\u056c","\u0544\u0561\u0575\u056b\u057d","\u0540\u0578\u0582\u0576\u056b\u057d","\u0540\u0578\u0582\u056c\u056b\u057d","\u0555\u0563\u0578\u057d\u057f\u0578\u057d","\u054d\u0565\u057a\u057f\u0565\u0574\u0562\u0565\u0580","\u0540\u0578\u056f\u057f\u0565\u0574\u0562\u0565\u0580","\u0546\u0578\u0575\u0565\u0574\u0562\u0565\u0580","\u0534\u0565\u056f\u057f\u0565\u0574\u0562\u0565\u0580"],showMonthAfterYear:!1,yearSuffix:""},id:{dayNames:["Minggu","Senin","Selasa","Rabu","Kamis","Jumat","Sabtu"],dayNamesMin:["Min","Sen","Sel","Rab","kam","Jum","Sab"],firstDay:0,isRTL:!1,monthNames:["Januari","Februari","Maret","April","Mei","Juni","Juli","Agustus","September","Oktober","Nopember","Desember"],showMonthAfterYear:!1,yearSuffix:""},is:{dayNames:["Sunnudagur","M&aacute;nudagur","&THORN;ri&eth;judagur","Mi&eth;vikudagur","Fimmtudagur","F&ouml;studagur","Laugardagur"],dayNamesMin:["Sun","M&aacute;n","&THORN;ri","Mi&eth;","Fim","F&ouml;s","Lau"],firstDay:0,isRTL:!1,monthNames:["Jan&uacute;ar","Febr&uacute;ar","Mars","Apr&iacute;l","Ma&iacute","J&uacute;n&iacute;","J&uacute;l&iacute;","&Aacute;g&uacute;st","September","Okt&oacute;ber","N&oacute;vember","Desember"],showMonthAfterYear:!1,yearSuffix:""},it:{dayNames:["Domenica","Luned&#236","Marted&#236","Mercoled&#236","Gioved&#236","Venerd&#236","Sabato"],dayNamesMin:["Dom","Lun","Mar","Mer","Gio","Ven","Sab"],firstDay:1,isRTL:!1,monthNames:["Gennaio","Febbraio","Marzo","Aprile","Maggio","Giugno","Luglio","Agosto","Settembre","Ottobre","Novembre","Dicembre"],showMonthAfterYear:!1,yearSuffix:""},ja:{dayNames:["\u65e5\u66dc\u65e5","\u6708\u66dc\u65e5","\u706b\u66dc\u65e5","\u6c34\u66dc\u65e5","\u6728\u66dc\u65e5","\u91d1\u66dc\u65e5","\u571f\u66dc\u65e5"],dayNamesMin:["\u65e5","\u6708","\u706b","\u6c34","\u6728","\u91d1","\u571f"],firstDay:0,isRTL:!1,monthNames:["1\u6708","2\u6708","3\u6708","4\u6708","5\u6708","6\u6708","7\u6708","8\u6708","9\u6708","10\u6708","11\u6708","12\u6708"],showMonthAfterYear:!0,yearSuffix:"\u5e74"},ko:{dayNames:["\uc77c","\uc6d4","\ud654","\uc218","\ubaa9","\uae08","\ud1a0"],dayNamesMin:["\uc77c","\uc6d4","\ud654","\uc218","\ubaa9","\uae08","\ud1a0"],firstDay:0,isRTL:!1,monthNames:["1\uc6d4(JAN)","2\uc6d4(FEB)","3\uc6d4(MAR)","4\uc6d4(APR)","5\uc6d4(MAY)","6\uc6d4(JUN)","7\uc6d4(JUL)","8\uc6d4(AUG)","9\uc6d4(SEP)","10\uc6d4(OCT)","11\uc6d4(NOV)","12\uc6d4(DEC)"],showMonthAfterYear:!1,yearSuffix:"\ub144"},kz:{dayNames:["\u0416\u0435\u043a\u0441\u0435\u043d\u0431\u0456","\u0414\u04af\u0439\u0441\u0435\u043d\u0431\u0456","\u0421\u0435\u0439\u0441\u0435\u043d\u0431\u0456","\u0421\u04d9\u0440\u0441\u0435\u043d\u0431\u0456","\u0411\u0435\u0439\u0441\u0435\u043d\u0431\u0456","\u0416\u04b1\u043c\u0430","\u0421\u0435\u043d\u0431\u0456"],dayNamesMin:["\u0436\u043a\u0441","\u0434\u0441\u043d","\u0441\u0441\u043d","\u0441\u0440\u0441","\u0431\u0441\u043d","\u0436\u043c\u0430","\u0441\u043d\u0431"],firstDay:1,isRTL:!1,monthNames:["\u049a\u0430\u04a3\u0442\u0430\u0440","\u0410\u049b\u043f\u0430\u043d","\u041d\u0430\u0443\u0440\u044b\u0437","\u0421\u04d9\u0443\u0456\u0440","\u041c\u0430\u043c\u044b\u0440","\u041c\u0430\u0443\u0441\u044b\u043c","\u0428\u0456\u043b\u0434\u0435","\u0422\u0430\u043c\u044b\u0437","\u049a\u044b\u0440\u043a\u04af\u0439\u0435\u043a","\u049a\u0430\u0437\u0430\u043d","\u049a\u0430\u0440\u0430\u0448\u0430","\u0416\u0435\u043b\u0442\u043e\u049b\u0441\u0430\u043d"],showMonthAfterYear:!1,yearSuffix:""},lt:{dayNames:["sekmadienis","pirmadienis","antradienis","tre\u010diadienis","ketvirtadienis","penktadienis","\u0161e\u0161tadienis"],dayNamesMin:["sek","pir","ant","tre","ket","pen","\u0161e\u0161"],firstDay:1,isRTL:!1,monthNames:["Sausis","Vasaris","Kovas","Balandis","Gegu\u017e\u0117","Bir\u017eelis","Liepa","Rugpj\u016btis","Rugs\u0117jis","Spalis","Lapkritis","Gruodis"],showMonthAfterYear:!1,yearSuffix:""},lv:{dayNames:["sv\u0113tdiena","pirmdiena","otrdiena","tre\u0161diena","ceturtdiena","piektdiena","sestdiena"],dayNamesMin:["svt","prm","otr","tre","ctr","pkt","sst"],firstDay:1,isRTL:!1,monthNames:["Janv\u0101ris","Febru\u0101ris","Marts","Apr\u012blis","Maijs","J\u016bnijs","J\u016blijs","Augusts","Septembris","Oktobris","Novembris","Decembris"],showMonthAfterYear:!1,yearSuffix:""},ml:{dayNames:["\u0d1e\u0d3e\u0d2f\u0d30\u0d4d","\u0d24\u0d3f\u0d19\u0d4d\u0d15\u0d33\u0d4d","\u0d1a\u0d4a\u0d35\u0d4d\u0d35","\u0d2c\u0d41\u0d27\u0d28\u0d4d","\u0d35\u0d4d\u0d2f\u0d3e\u0d34\u0d02","\u0d35\u0d46\u0d33\u0d4d\u0d33\u0d3f","\u0d36\u0d28\u0d3f"],dayNamesMin:["\u0d1e\u0d3e\u0d2f","\u0d24\u0d3f\u0d19\u0d4d\u0d15","\u0d1a\u0d4a\u0d35\u0d4d\u0d35","\u0d2c\u0d41\u0d27","\u0d35\u0d4d\u0d2f\u0d3e\u0d34\u0d02","\u0d35\u0d46\u0d33\u0d4d\u0d33\u0d3f","\u0d36\u0d28\u0d3f"],firstDay:1,isRTL:!1,monthNames:["\u0d1c\u0d28\u0d41\u0d35\u0d30\u0d3f","\u0d2b\u0d46\u0d2c\u0d4d\u0d30\u0d41\u0d35\u0d30\u0d3f","\u0d2e\u0d3e\u0d30\u0d4d\u0d1a\u0d4d\u0d1a\u0d4d","\u0d0f\u0d2a\u0d4d\u0d30\u0d3f\u0d32\u0d4d","\u0d2e\u0d47\u0d2f\u0d4d","\u0d1c\u0d42\u0d23\u0d4d","\u0d1c\u0d42\u0d32\u0d48","\u0d06\u0d17\u0d38\u0d4d\u0d31\u0d4d\u0d31\u0d4d","\u0d38\u0d46\u0d2a\u0d4d\u0d31\u0d4d\u0d31\u0d02\u0d2c\u0d30\u0d4d","\u0d12\u0d15\u0d4d\u0d1f\u0d4b\u0d2c\u0d30\u0d4d","\u0d28\u0d35\u0d02\u0d2c\u0d30\u0d4d","\u0d21\u0d3f\u0d38\u0d02\u0d2c\u0d30\u0d4d"],showMonthAfterYear:!1,yearSuffix:""},ms:{dayNames:["Ahad","Isnin","Selasa","Rabu","Khamis","Jumaat","Sabtu"],dayNamesMin:["Aha","Isn","Sel","Rab","kha","Jum","Sab"],firstDay:0,isRTL:!1,monthNames:["Januari","Februari","Mac","April","Mei","Jun","Julai","Ogos","September","Oktober","November","Disember"],showMonthAfterYear:!1,yearSuffix:""},nl:{dayNames:["zondag","maandag","dinsdag","woensdag","donderdag","vrijdag","zaterdag"],dayNamesMin:["zon","maa","din","woe","don","vri","zat"],firstDay:1,isRTL:!1,monthNames:["januari","februari","maart","april","mei","juni","juli","augustus","september","oktober","november","december"],showMonthAfterYear:!1,yearSuffix:""},no:{dayNames:["s\xf8ndag","mandag","tirsdag","onsdag","torsdag","fredag","l\xf8rdag"],dayNamesMin:["s\xf8n","man","tir","ons","tor","fre","l\xf8r"],firstDay:1,isRTL:!1,monthNames:["januar","februar","mars","april","mai","juni","juli","august","september","oktober","november","desember"],showMonthAfterYear:!1,yearSuffix:""},pl:{dayNames:["Niedziela","Poniedzia\u0142ek","Wtorek","\u015aroda","Czwartek","Pi\u0105tek","Sobota"],dayNamesMin:["Nie","Pn","Wt","\u015ar","Czw","Pt","So"],firstDay:1,isRTL:!1,monthNames:["Stycze\u0144","Luty","Marzec","Kwiecie\u0144","Maj","Czerwiec","Lipiec","Sierpie\u0144","Wrzesie\u0144","Pa\u017adziernik","Listopad","Grudzie\u0144"],showMonthAfterYear:!1,yearSuffix:""},"pt-BR":{dayNames:["Domingo","Segunda-feira","Ter&ccedil;a-feira","Quarta-feira","Quinta-feira","Sexta-feira","S&aacute;bado"],dayNamesMin:["Dom","Seg","Ter","Qua","Qui","Sex","S&aacute;b"],firstDay:0,isRTL:!1,monthNames:["Janeiro","Fevereiro","Mar&ccedil;o","Abril","Maio","Junho","Julho","Agosto","Setembro","Outubro","Novembro","Dezembro"],showMonthAfterYear:!1,yearSuffix:""},pt:{dayNames:["Domingo","Segunda-feira","Ter&ccedil;a-feira","Quarta-feira","Quinta-feira","Sexta-feira","S&aacute;bado"],dayNamesMin:["Dom","Seg","Ter","Qua","Qui","Sex","S&aacute;b"],firstDay:0,isRTL:!1,monthNames:["Janeiro","Fevereiro","Mar&ccedil;o","Abril","Maio","Junho","Julho","Agosto","Setembro","Outubro","Novembro","Dezembro"],showMonthAfterYear:!1,yearSuffix:""},rm:{dayNames:["Dumengia","Glindesdi","Mardi","Mesemna","Gievgia","Venderdi","Sonda"],dayNamesMin:["Dum","Gli","Mar","Mes","Gie","Ven","Som"],firstDay:1,isRTL:!1,monthNames:["Schaner","Favrer","Mars","Avrigl","Matg","Zercladur","Fanadur","Avust","Settember","October","November","December"],showMonthAfterYear:!1,yearSuffix:""},ro:{dayNames:["Duminic\u0103","Luni","Mar\u0163i","Miercuri","Joi","Vineri","S\xe2mb\u0103t\u0103"],dayNamesMin:["Dum","Lun","Mar","Mie","Joi","Vin","S\xe2m"],firstDay:1,isRTL:!1,monthNames:["Ianuarie","Februarie","Martie","Aprilie","Mai","Iunie","Iulie","August","Septembrie","Octombrie","Noiembrie","Decembrie"],showMonthAfterYear:!1,yearSuffix:""},ru:{dayNames:["\u0432\u043e\u0441\u043a\u0440\u0435\u0441\u0435\u043d\u044c\u0435","\u043f\u043e\u043d\u0435\u0434\u0435\u043b\u044c\u043d\u0438\u043a","\u0432\u0442\u043e\u0440\u043d\u0438\u043a","\u0441\u0440\u0435\u0434\u0430","\u0447\u0435\u0442\u0432\u0435\u0440\u0433","\u043f\u044f\u0442\u043d\u0438\u0446\u0430","\u0441\u0443\u0431\u0431\u043e\u0442\u0430"],dayNamesMin:["\u0432\u0441\u043a","\u043f\u043d\u0434","\u0432\u0442\u0440","\u0441\u0440\u0434","\u0447\u0442\u0432","\u043f\u0442\u043d","\u0441\u0431\u0442"],firstDay:1,isRTL:!1,monthNames:["\u042f\u043d\u0432\u0430\u0440\u044c","\u0424\u0435\u0432\u0440\u0430\u043b\u044c","\u041c\u0430\u0440\u0442","\u0410\u043f\u0440\u0435\u043b\u044c","\u041c\u0430\u0439","\u0418\u044e\u043d\u044c","\u0418\u044e\u043b\u044c","\u0410\u0432\u0433\u0443\u0441\u0442","\u0421\u0435\u043d\u0442\u044f\u0431\u0440\u044c","\u041e\u043a\u0442\u044f\u0431\u0440\u044c","\u041d\u043e\u044f\u0431\u0440\u044c","\u0414\u0435\u043a\u0430\u0431\u0440\u044c"],showMonthAfterYear:!1,yearSuffix:""},sk:{dayNames:["Nede\u013ea","Pondelok","Utorok","Streda","\u0160tvrtok","Piatok","Sobota"],dayNamesMin:["Ned","Pon","Uto","Str","\u0160tv","Pia","Sob"],firstDay:1,isRTL:!1,monthNames:["Janu\xe1r","Febru\xe1r","Marec","Apr\xedl","M\xe1j","J\xfan","J\xfal","August","September","Okt\xf3ber","November","December"],showMonthAfterYear:!1,yearSuffix:""},sl:{dayNames:["Nedelja","Ponedeljek","Torek","Sreda","&#x10C;etrtek","Petek","Sobota"],dayNamesMin:["Ned","Pon","Tor","Sre","&#x10C;et","Pet","Sob"],firstDay:1,isRTL:!1,monthNames:["Januar","Februar","Marec","April","Maj","Junij","Julij","Avgust","September","Oktober","November","December"],showMonthAfterYear:!1,yearSuffix:""},sq:{dayNames:["E Diel","E H\xebn\xeb","E Mart\xeb","E M\xebrkur\xeb","E Enjte","E Premte","E Shtune"],dayNamesMin:["Di","H\xeb","Ma","M\xeb","En","Pr","Sh"],firstDay:1,isRTL:!1,monthNames:["Janar","Shkurt","Mars","Prill","Maj","Qershor","Korrik","Gusht","Shtator","Tetor","N\xebntor","Dhjetor"],showMonthAfterYear:!1,yearSuffix:""},"sr-SR":{dayNames:["Nedelja","Ponedeljak","Utorak","Sreda","\u010cetvrtak","Petak","Subota"],dayNamesMin:["Ned","Pon","Uto","Sre","\u010cet","Pet","Sub"],firstDay:1,isRTL:!1,monthNames:["Januar","Februar","Mart","April","Maj","Jun","Jul","Avgust","Septembar","Oktobar","Novembar","Decembar"],showMonthAfterYear:!1,yearSuffix:""},sr:{dayNames:["\u041d\u0435\u0434\u0435\u0459\u0430","\u041f\u043e\u043d\u0435\u0434\u0435\u0459\u0430\u043a","\u0423\u0442\u043e\u0440\u0430\u043a","\u0421\u0440\u0435\u0434\u0430","\u0427\u0435\u0442\u0432\u0440\u0442\u0430\u043a","\u041f\u0435\u0442\u0430\u043a","\u0421\u0443\u0431\u043e\u0442\u0430"],dayNamesMin:["\u041d\u0435\u0434","\u041f\u043e\u043d","\u0423\u0442\u043e","\u0421\u0440\u0435","\u0427\u0435\u0442","\u041f\u0435\u0442","\u0421\u0443\u0431"],firstDay:1,isRTL:!1,monthNames:["\u0408\u0430\u043d\u0443\u0430\u0440","\u0424\u0435\u0431\u0440\u0443\u0430\u0440","\u041c\u0430\u0440\u0442","\u0410\u043f\u0440\u0438\u043b","\u041c\u0430\u0458","\u0408\u0443\u043d","\u0408\u0443\u043b","\u0410\u0432\u0433\u0443\u0441\u0442","\u0421\u0435\u043f\u0442\u0435\u043c\u0431\u0430\u0440","\u041e\u043a\u0442\u043e\u0431\u0430\u0440","\u041d\u043e\u0432\u0435\u043c\u0431\u0430\u0440","\u0414\u0435\u0446\u0435\u043c\u0431\u0430\u0440"],showMonthAfterYear:!1,yearSuffix:""},sv:{dayNames:["S\xf6ndag","M\xe5ndag","Tisdag","Onsdag","Torsdag","Fredag","L\xf6rdag"],dayNamesMin:["S\xf6n","M\xe5n","Tis","Ons","Tor","Fre","L\xf6r"],firstDay:1,isRTL:!1,monthNames:["Januari","Februari","Mars","April","Maj","Juni","Juli","Augusti","September","Oktober","November","December"],showMonthAfterYear:!1,yearSuffix:""},ta:{dayNames:["\u0b9e\u0bbe\u0baf\u0bbf\u0bb1\u0bcd\u0bb1\u0bc1\u0b95\u0bcd\u0b95\u0bbf\u0bb4\u0bae\u0bc8","\u0ba4\u0bbf\u0b99\u0bcd\u0b95\u0b9f\u0bcd\u0b95\u0bbf\u0bb4\u0bae\u0bc8","\u0b9a\u0bc6\u0bb5\u0bcd\u0bb5\u0bbe\u0baf\u0bcd\u0b95\u0bcd\u0b95\u0bbf\u0bb4\u0bae\u0bc8","\u0baa\u0bc1\u0ba4\u0ba9\u0bcd\u0b95\u0bbf\u0bb4\u0bae\u0bc8","\u0bb5\u0bbf\u0baf\u0bbe\u0bb4\u0b95\u0bcd\u0b95\u0bbf\u0bb4\u0bae\u0bc8","\u0bb5\u0bc6\u0bb3\u0bcd\u0bb3\u0bbf\u0b95\u0bcd\u0b95\u0bbf\u0bb4\u0bae\u0bc8","\u0b9a\u0ba9\u0bbf\u0b95\u0bcd\u0b95\u0bbf\u0bb4\u0bae\u0bc8"],dayNamesMin:["\u0b9e\u0bbe\u0baf\u0bbf\u0bb1\u0bc1","\u0ba4\u0bbf\u0b99\u0bcd\u0b95\u0bb3\u0bcd","\u0b9a\u0bc6\u0bb5\u0bcd\u0bb5\u0bbe\u0baf\u0bcd","\u0baa\u0bc1\u0ba4\u0ba9\u0bcd","\u0bb5\u0bbf\u0baf\u0bbe\u0bb4\u0ba9\u0bcd","\u0bb5\u0bc6\u0bb3\u0bcd\u0bb3\u0bbf","\u0b9a\u0ba9\u0bbf"],firstDay:1,isRTL:!1,monthNames:["\u0ba4\u0bc8","\u0bae\u0bbe\u0b9a\u0bbf","\u0baa\u0b99\u0bcd\u0b95\u0bc1\u0ba9\u0bbf","\u0b9a\u0bbf\u0ba4\u0bcd\u0ba4\u0bbf\u0bb0\u0bc8","\u0bb5\u0bc8\u0b95\u0bbe\u0b9a\u0bbf","\u0b86\u0ba9\u0bbf","\u0b86\u0b9f\u0bbf","\u0b86\u0bb5\u0ba3\u0bbf","\u0baa\u0bc1\u0bb0\u0b9f\u0bcd\u0b9f\u0bbe\u0b9a\u0bbf","\u0b90\u0baa\u0bcd\u0baa\u0b9a\u0bbf","\u0b95\u0bbe\u0bb0\u0bcd\u0ba4\u0bcd\u0ba4\u0bbf\u0b95\u0bc8","\u0bae\u0bbe\u0bb0\u0bcd\u0b95\u0bb4\u0bbf"],showMonthAfterYear:!1,yearSuffix:""},th:{dayNames:["\u0e2d\u0e32\u0e17\u0e34\u0e15\u0e22\u0e4c","\u0e08\u0e31\u0e19\u0e17\u0e23\u0e4c","\u0e2d\u0e31\u0e07\u0e04\u0e32\u0e23","\u0e1e\u0e38\u0e18","\u0e1e\u0e24\u0e2b\u0e31\u0e2a\u0e1a\u0e14\u0e35","\u0e28\u0e38\u0e01\u0e23\u0e4c","\u0e40\u0e2a\u0e32\u0e23\u0e4c"],dayNamesMin:["\u0e2d\u0e32.","\u0e08.","\u0e2d.","\u0e1e.","\u0e1e\u0e24.","\u0e28.","\u0e2a."],firstDay:0,isRTL:!1,monthNames:["\u0e21\u0e01\u0e23\u0e32\u0e04\u0e21","\u0e01\u0e38\u0e21\u0e20\u0e32\u0e1e\u0e31\u0e19\u0e18\u0e4c","\u0e21\u0e35\u0e19\u0e32\u0e04\u0e21","\u0e40\u0e21\u0e29\u0e32\u0e22\u0e19","\u0e1e\u0e24\u0e29\u0e20\u0e32\u0e04\u0e21","\u0e21\u0e34\u0e16\u0e38\u0e19\u0e32\u0e22\u0e19","\u0e01\u0e23\u0e01\u0e0e\u0e32\u0e04\u0e21","\u0e2a\u0e34\u0e07\u0e2b\u0e32\u0e04\u0e21","\u0e01\u0e31\u0e19\u0e22\u0e32\u0e22\u0e19","\u0e15\u0e38\u0e25\u0e32\u0e04\u0e21","\u0e1e\u0e24\u0e28\u0e08\u0e34\u0e01\u0e32\u0e22\u0e19","\u0e18\u0e31\u0e19\u0e27\u0e32\u0e04\u0e21"],showMonthAfterYear:!1,yearSuffix:""},tj:{dayNames:["\u044f\u043a\u0448\u0430\u043d\u0431\u0435","\u0434\u0443\u0448\u0430\u043d\u0431\u0435","\u0441\u0435\u0448\u0430\u043d\u0431\u0435","\u0447\u043e\u0440\u0448\u0430\u043d\u0431\u0435","\u043f\u0430\u043d\u04b7\u0448\u0430\u043d\u0431\u0435","\u04b7\u0443\u043c\u044a\u0430","\u0448\u0430\u043d\u0431\u0435"],dayNamesMin:["\u044f\u043a\u0448","\u0434\u0443\u0448","\u0441\u0435\u0448","\u0447\u043e\u0440","\u043f\u0430\u043d","\u04b7\u0443\u043c","\u0448\u0430\u043d"],firstDay:1,isRTL:!1,monthNames:["\u042f\u043d\u0432\u0430\u0440","\u0424\u0435\u0432\u0440\u0430\u043b","\u041c\u0430\u0440\u0442","\u0410\u043f\u0440\u0435\u043b","\u041c\u0430\u0439","\u0418\u044e\u043d","\u0418\u044e\u043b","\u0410\u0432\u0433\u0443\u0441\u0442","\u0421\u0435\u043d\u0442\u044f\u0431\u0440","\u041e\u043a\u0442\u044f\u0431\u0440","\u041d\u043e\u044f\u0431\u0440","\u0414\u0435\u043a\u0430\u0431\u0440"],showMonthAfterYear:!1,yearSuffix:""},tr:{dayNames:["Pazar","Pazartesi","Sal\u0131","\xc7ar\u015famba","Per\u015fembe","Cuma","Cumartesi"],dayNamesMin:["Pz","Pt","Sa","\xc7a","Pe","Cu","Ct"],firstDay:1,isRTL:!1,monthNames:["Ocak","\u015eubat","Mart","Nisan","May\u0131s","Haziran","Temmuz","A\u011fustos","Eyl\xfcl","Ekim","Kas\u0131m","Aral\u0131k"],showMonthAfterYear:!1,yearSuffix:""},uk:{dayNames:["\u043d\u0435\u0434\u0456\u043b\u044f","\u043f\u043e\u043d\u0435\u0434\u0456\u043b\u043e\u043a","\u0432\u0456\u0432\u0442\u043e\u0440\u043e\u043a","\u0441\u0435\u0440\u0435\u0434\u0430","\u0447\u0435\u0442\u0432\u0435\u0440","\u043f\u2019\u044f\u0442\u043d\u0438\u0446\u044f","\u0441\u0443\u0431\u043e\u0442\u0430"],dayNamesMin:["\u043d\u0435\u0434","\u043f\u043d\u0434","\u0432\u0456\u0432","\u0441\u0440\u0434","\u0447\u0442\u0432","\u043f\u0442\u043d","\u0441\u0431\u0442"],firstDay:1,isRTL:!1,monthNames:["\u0421\u0456\u0447\u0435\u043d\u044c","\u041b\u044e\u0442\u0438\u0439","\u0411\u0435\u0440\u0435\u0437\u0435\u043d\u044c","\u041a\u0432\u0456\u0442\u0435\u043d\u044c","\u0422\u0440\u0430\u0432\u0435\u043d\u044c","\u0427\u0435\u0440\u0432\u0435\u043d\u044c","\u041b\u0438\u043f\u0435\u043d\u044c","\u0421\u0435\u0440\u043f\u0435\u043d\u044c","\u0412\u0435\u0440\u0435\u0441\u0435\u043d\u044c","\u0416\u043e\u0432\u0442\u0435\u043d\u044c","\u041b\u0438\u0441\u0442\u043e\u043f\u0430\u0434","\u0413\u0440\u0443\u0434\u0435\u043d\u044c"],showMonthAfterYear:!1,yearSuffix:""},vi:{dayNames:["Ch\u1ee7 Nh\u1eadt","Th\u1ee9 Hai","Th\u1ee9 Ba","Th\u1ee9 T\u01b0","Th\u1ee9 N\u0103m","Th\u1ee9 S\xe1u","Th\u1ee9 B\u1ea3y"],dayNamesMin:["CN","T2","T3","T4","T5","T6","T7"],firstDay:0,isRTL:!1,monthNames:["Th\xe1ng M\u1ed9t","Th\xe1ng Hai","Th\xe1ng Ba","Th\xe1ng T\u01b0","Th\xe1ng N\u0103m","Th\xe1ng S\xe1u","Th\xe1ng B\u1ea3y","Th\xe1ng T\xe1m","Th\xe1ng Ch\xedn","Th\xe1ng M\u01b0\u1eddi","Th\xe1ng M\u01b0\u1eddi M\u1ed9t","Th\xe1ng M\u01b0\u1eddi Hai"],showMonthAfterYear:!1,yearSuffix:""},"zh-CN":{dayNames:["\u661f\u671f\u65e5","\u661f\u671f\u4e00","\u661f\u671f\u4e8c","\u661f\u671f\u4e09","\u661f\u671f\u56db","\u661f\u671f\u4e94","\u661f\u671f\u516d"],dayNamesMin:["\u5468\u65e5","\u5468\u4e00","\u5468\u4e8c","\u5468\u4e09","\u5468\u56db","\u5468\u4e94","\u5468\u516d"],firstDay:1,isRTL:!1,monthNames:["\u4e00\u6708","\u4e8c\u6708","\u4e09\u6708","\u56db\u6708","\u4e94\u6708","\u516d\u6708","\u4e03\u6708","\u516b\u6708","\u4e5d\u6708","\u5341\u6708","\u5341\u4e00\u6708","\u5341\u4e8c\u6708"],showMonthAfterYear:!0,yearSuffix:"\u5e74"},"zh-HK":{dayNames:["\u661f\u671f\u65e5","\u661f\u671f\u4e00","\u661f\u671f\u4e8c","\u661f\u671f\u4e09","\u661f\u671f\u56db","\u661f\u671f\u4e94","\u661f\u671f\u516d"],dayNamesMin:["\u5468\u65e5","\u5468\u4e00","\u5468\u4e8c","\u5468\u4e09","\u5468\u56db","\u5468\u4e94","\u5468\u516d"],firstDay:0,isRTL:!1,monthNames:["\u4e00\u6708","\u4e8c\u6708","\u4e09\u6708","\u56db\u6708","\u4e94\u6708","\u516d\u6708","\u4e03\u6708","\u516b\u6708","\u4e5d\u6708","\u5341\u6708","\u5341\u4e00\u6708","\u5341\u4e8c\u6708"],showMonthAfterYear:!0,yearSuffix:"\u5e74"},"zh-TW":{dayNames:["\u661f\u671f\u65e5","\u661f\u671f\u4e00","\u661f\u671f\u4e8c","\u661f\u671f\u4e09","\u661f\u671f\u56db","\u661f\u671f\u4e94","\u661f\u671f\u516d"],dayNamesMin:["\u5468\u65e5","\u5468\u4e00","\u5468\u4e8c","\u5468\u4e09","\u5468\u56db","\u5468\u4e94","\u5468\u516d"],firstDay:1,isRTL:!1,monthNames:["\u4e00\u6708","\u4e8c\u6708","\u4e09\u6708","\u56db\u6708","\u4e94\u6708","\u516d\u6708","\u4e03\u6708","\u516b\u6708","\u4e5d\u6708","\u5341\u6708","\u5341\u4e00\u6708","\u5341\u4e8c\u6708"],showMonthAfterYear:!0,yearSuffix:"\u5e74"}},a.fn.datePicker=function(a){return new AJS.DatePicker(this,a) }}(jQuery),AJS.dropDown=function(a,b){var c=null,d=[],e=!1,f=AJS.$(document),g={item:"li:has(a)",activeClass:"active",alignment:"right",displayHandler:function(a){return a.name},escapeHandler:function(){return this.hide("escape"),!1},hideHandler:function(){},moveHandler:function(){},useDisabled:!1};if(AJS.$.extend(g,b),g.alignment={left:"left",right:"right"}[g.alignment.toLowerCase()]||"left",a&&a.jquery)c=a;else if("string"==typeof a)c=AJS.$(a);else{if(!a||a.constructor!=Array)throw new Error("AJS.dropDown function was called with illegal parameter. Should be AJS.$ object, AJS.$ selector or array.");c=AJS("div").addClass("aui-dropdown").toggleClass("hidden",!!g.isHiddenByDefault);for(var h=0,i=a.length;i>h;h++){for(var j=AJS("ol"),k=0,l=a[h].length;l>k;k++){var m=AJS("li"),n=a[h][k];n.href?(m.append(AJS("a").html("<span>"+g.displayHandler(n)+"</span>").attr({href:n.href}).addClass(n.className)),AJS.$.data(AJS.$("a > span",m)[0],"properties",n)):m.html(n.html).addClass(n.className),n.icon&&m.prepend(AJS("img").attr("src",n.icon)),n.insideSpanIcon&&m.children("a").prepend(AJS("span").attr("class","icon")),AJS.$.data(m[0],"properties",n),j.append(m)}h==i-1&&j.addClass("last"),c.append(j)}AJS.$("body").append(c)}var o=function(){q(1)},p=function(){q(-1)},q=function(a){var b=!e,c=AJS.dropDown.current.$[0],d=AJS.dropDown.current.links,f=c.focused;if(e=!0,0!==d.length){if(c.focused="number"==typeof f?f:-1,!AJS.dropDown.current)return AJS.log("move - not current, aborting"),!0;c.focused+=a,c.focused<0?c.focused=d.length-1:c.focused>=d.length&&(c.focused=0),g.moveHandler(AJS.$(d[c.focused]),0>a?"up":"down"),b&&d.length?(AJS.$(d[c.focused]).addClass(g.activeClass),e=!1):d.length||(e=!1)}},r=function(a){if(!AJS.dropDown.current)return!0;var b=a.which,c=AJS.dropDown.current.$[0],d=AJS.dropDown.current.links;switch(AJS.dropDown.current.cleanActive(),b){case 40:o();break;case 38:p();break;case 27:return g.escapeHandler.call(AJS.dropDown.current,a);case 13:return c.focused>=0?g.selectionHandler?g.selectionHandler.call(AJS.dropDown.current,a,AJS.$(d[c.focused])):"a"!=AJS.$(d[c.focused]).attr("nodeName")?AJS.$("a",d[c.focused]).trigger("focus"):AJS.$(d[c.focused]).trigger("focus"):!0;default:return d.length&&AJS.$(d[c.focused]).addClass(g.activeClass),!0}return a.stopPropagation(),a.preventDefault(),!1},s=function(a){a&&a.which&&3==a.which||a&&a.button&&2==a.button||AJS.dropDown.current&&AJS.dropDown.current.hide("click")},t=function(a){return function(){AJS.dropDown.current&&(AJS.dropDown.current.cleanFocus(),this.originalClass=this.className,AJS.$(this).addClass(g.activeClass),AJS.dropDown.current.$[0].focused=a)}},u=function(a){return a.button||a.metaKey||a.ctrlKey||a.shiftKey?!0:void(AJS.dropDown.current&&g.selectionHandler&&g.selectionHandler.call(AJS.dropDown.current,a,AJS.$(this)))},v=function(a){var b=!1;return a.data("events")&&AJS.$.each(a.data("events"),function(a,c){AJS.$.each(c,function(a,c){return u===c?(b=!0,!1):void 0})}),b};return c.each(function(){var a=this,b=AJS.$(this),c={},e={reset:function(){c=AJS.$.extend(c,{$:b,links:AJS.$(g.item||"li:has(a)",a),cleanActive:function(){a.focused+1&&c.links.length&&AJS.$(c.links[a.focused]).removeClass(g.activeClass)},cleanFocus:function(){c.cleanActive(),a.focused=-1},moveDown:o,moveUp:p,moveFocus:r,getFocusIndex:function(){return"number"==typeof a.focused?a.focused:-1}}),c.links.each(function(a){var b=AJS.$(this);v(b)||(b.hover(t(a),c.cleanFocus),b.click(u))})},appear:function(a){a?(b.removeClass("hidden"),b.addClass("aui-dropdown-"+g.alignment)):b.addClass("hidden")},fade:function(a){a?b.fadeIn("fast"):b.fadeOut("fast")},scroll:function(a){a?b.slideDown("fast"):b.slideUp("fast")}};c.reset=e.reset,c.reset(),c.addControlProcess=function(a,b){AJS.$.aop.around({target:this,method:a},b)},c.addCallback=function(a,b){return AJS.$.aop.after({target:this,method:a},b)},c.show=function(b){g.useDisabled&&this.$.closest(".aui-dd-parent").hasClass("disabled")||(this.alignment=g.alignment,s(),AJS.dropDown.current=this,this.method=b||this.method||"appear",this.timer=setTimeout(function(){f.click(s)},0),f.keydown(r),g.firstSelected&&this.links[0]&&t(0).call(this.links[0]),AJS.$(a.offsetParent).css({zIndex:2e3}),e[this.method](!0),AJS.$(document).trigger("showLayer",["dropdown",AJS.dropDown.current]))},c.hide=function(a){return this.method=this.method||"appear",AJS.$(b.get(0).offsetParent).css({zIndex:""}),this.cleanFocus(),e[this.method](!1),f.unbind("click",s).unbind("keydown",r),AJS.$(document).trigger("hideLayer",["dropdown",AJS.dropDown.current]),AJS.dropDown.current=null,a},c.addCallback("reset",function(){g.firstSelected&&this.links[0]&&t(0).call(this.links[0])}),AJS.dropDown.iframes||(AJS.dropDown.iframes=[]),AJS.dropDown.createShims=function(){return AJS.$("iframe").each(function(){var a=this;a.shim||(a.shim=AJS.$("<div />").addClass("shim hidden").appendTo("body"),AJS.dropDown.iframes.push(a))}),arguments.callee}(),c.addCallback("show",function(){AJS.$(AJS.dropDown.iframes).each(function(){var a=AJS.$(this);if(a.is(":visible")){var b=a.offset();b.height=a.height(),b.width=a.width(),this.shim.css({left:b.left+"px",top:b.top+"px",height:b.height+"px",width:b.width+"px"}).removeClass("hidden")}})}),c.addCallback("hide",function(){AJS.$(AJS.dropDown.iframes).each(function(){this.shim.addClass("hidden")}),g.hideHandler()}),d.push(c)}),d},AJS.dropDown.getAdditionalPropertyValue=function(a,b){var c=a[0];c&&"string"==typeof c.tagName&&"li"==c.tagName.toLowerCase()||AJS.log("AJS.dropDown.getAdditionalPropertyValue : item passed in should be an LI element wrapped by jQuery");var d=AJS.$.data(c,"properties");return d?d[b]:null},AJS.dropDown.removeAllAdditionalProperties=function(){},AJS.dropDown.Standard=function(a){var b,c=[],d={selector:".aui-dd-parent",dropDown:".aui-dropdown",trigger:".aui-dd-trigger"};AJS.$.extend(d,a);var e=function(a,b,c,e){AJS.$.extend(e,{trigger:a}),b.addClass("dd-allocated"),c.addClass("hidden"),0==d.isHiddenByDefault&&e.show(),e.addCallback("show",function(){b.addClass("active")}),e.addCallback("hide",function(){b.removeClass("active")})},f=function(a,b,c,d){d!=AJS.dropDown.current&&(c.css({top:b.outerHeight()}),d.show(),a.stopImmediatePropagation()),a.preventDefault()};if(d.useLiveEvents){var g=[],h=[];AJS.$(d.trigger).live("click",function(a){var b,c,i,j,k=AJS.$(this);if((j=AJS.$.inArray(this,g))>=0){var l=h[j];b=l.parent,c=l.dropdown,i=l.ddcontrol}else{if(b=k.closest(d.selector),c=b.find(d.dropDown),0===c.length)return;if(i=AJS.dropDown(c,d)[0],!i)return;g.push(this),l={parent:b,dropdown:c,ddcontrol:i},e(k,b,c,i),h.push(l)}f(a,k,c,i)})}else b=this instanceof AJS.$?this:AJS.$(d.selector),b=b.not(".dd-allocated").filter(":has("+d.dropDown+")").filter(":has("+d.trigger+")"),b.each(function(){var a=AJS.$(this),b=AJS.$(d.dropDown,this),g=AJS.$(d.trigger,this),h=AJS.dropDown(b,d)[0];AJS.$.extend(h,{trigger:g}),e(g,a,b,h),g.click(function(a){f(a,g,b,h)}),c.push(h)});return c},AJS.dropDown.Ajax=function(a){var b,c={cache:!0};return AJS.$.extend(c,a||{}),b=AJS.dropDown.Standard.call(this,c),AJS.$(b).each(function(){var a=this;AJS.$.extend(a,{getAjaxOptions:function(b){var d=function(b){c.formatResults&&(b=c.formatResults(b)),c.cache&&a.cache.set(a.getAjaxOptions(),b),a.refreshSuccess(b)};return c.ajaxOptions?AJS.$.isFunction(c.ajaxOptions)?AJS.$.extend(c.ajaxOptions.call(a),{success:d}):AJS.$.extend(c.ajaxOptions,{success:d}):AJS.$.extend(b,{success:d})},refreshSuccess:function(a){this.$.html(a)},cache:function(){var a={};return{get:function(b){var c=b.data||"";return a[(b.url+c).replace(/[\?\&]/gi,"")]},set:function(b,c){var d=b.data||"";a[(b.url+d).replace(/[\?\&]/gi,"")]=c},reset:function(){a={}}}}(),show:function(b){return function(){c.cache&&a.cache.get(a.getAjaxOptions())?(a.refreshSuccess(a.cache.get(a.getAjaxOptions())),b.call(a)):(AJS.$(AJS.$.ajax(a.getAjaxOptions())).throbber({target:a.$,end:function(){a.reset()}}),b.call(a),a.iframeShim&&a.iframeShim.hide())}}(a.show),resetCache:function(){a.cache.reset()}}),a.addCallback("refreshSuccess",function(){a.reset()})}),b},AJS.$.fn.dropDown=function(a,b){return a=(a||"Standard").replace(/^([a-z])/,function(a){return a.toUpperCase()}),AJS.dropDown[a].call(this,b)},function(a){function b(a){a.preventDefault()}function c(a){if(a.click)a.click();else{var b=document.createEvent("MouseEvents");b.initMouseEvent("click",!0,!0,window,0,0,0,0,0,!1,!1,!1,!1,0,null),a.dispatchEvent(b)}}function d(b,c){return b===c||a.contains(c,b)}function e(b){b instanceof AJS.$||(b=a(b));var c=b.attr("aria-owns"),d=b.attr("aria-haspopup"),e=document.getElementById(c);if(e)return a(e);if(!c)throw new Error("Dropdown 2 trigger required attribute not set: aria-owns");if(!d)throw new Error("Dropdown 2 trigger required attribute not set: aria-haspopup");if(!e)throw new Error("Dropdown 2 trigger aria-owns attr set to nonexistent id: "+c);throw new Error("Dropdown 2 trigger unknown error. I don't know what you did, but there's smoke everywhere. Consult the documentation.")}var f=a(document),g=null,h=function(){function c(b){g||1!==b.which||(g=!0,f.bind("mouseup mouseleave",d),a(this).trigger("aui-button-invoke"))}function d(){f.unbind("mouseup mouseleave",d),setTimeout(function(){g=!1},0)}function e(){g||a(this).trigger("aui-button-invoke")}var g=!1;return"undefined"==typeof document.addEventListener?{click:e,"click selectstart":b,mousedown:function(a){function b(a){switch(a.toElement){case null:case d:case document.body:case document.documentElement:a.returnValue=!1}}var d=this,e=document.activeElement;c.call(this,a),null!==e&&(e.attachEvent("onbeforedeactivate",b),setTimeout(function(){e.detachEvent("onbeforedeactivate",b)},0))}}:{click:e,"click mousedown":b,mousedown:c}}(),i={"aui-button-invoke":function(h,i){function j(b,c){b.each(function(){var b=a(this);b.attr("role",c),b.hasClass("checked")||b.hasClass("aui-dropdown2-checked")?(b.attr("aria-checked","true"),"radio"==c&&b.closest("ul").attr("role","radiogroup")):b.attr("aria-checked","false")})}function k(){var b=D.offset(),c=D.outerWidth();C.css({left:0,top:0});var d=C.outerWidth(),e=a("body").outerWidth(!0),f=Math.max(parseInt(C.css("min-width"),10),c),g=D.data("container")||!1,h="left";E||C.css("min-width",f+"px");var i=b.left,j=b.top+D.outerHeight();if(E){var k=3;i=b.left+K.outerWidth()-k,j=b.top}if(i+d>e&&i+c>=d&&(i=b.left+c-d,E&&(i=b.left-d),h="right"),g){var l=(D.closest(g),D.offset().left+D.outerWidth()),m=l+d;f>=d&&(d=f),m>l&&(i=l-d,h="right")}C.attr({"data-dropdown2-alignment":h,"aria-hidden":"false"}).css({display:"block",left:i+"px",top:j+"px"}),C.appendTo(document.body)}function l(){z(),B("off"),setTimeout(function(){C.css("display","none").css("min-width","").insertAfter(D).attr("aria-hidden","true"),E||D.removeClass("active aui-dropdown2-active"),r().removeClass("active aui-dropdown2-active"),C.removeClass("aui-dropdown2-in-toolbar"),C.removeClass("aui-dropdown2-in-buttons"),G?C.insertBefore(G):C.appendTo(F),C.trigger("aui-dropdown2-hide")},0)}function m(){l(),E&&K.trigger("aui-dropdown2-hide-all")}function n(a){E&&a.target===K[0]&&l()}function o(a){return!a.is(".disabled, .aui-dropdown2-disabled, [aria-disabled=true]")}function p(a){return a.hasClass("aui-dropdown2-sub-trigger")}function q(b,c){if(p(b)){c=a.extend({},c,{$menu:J});var d=e(b);d.is(":visible")?d.trigger("aui-dropdown2-select-first"):b.trigger("aui-button-invoke",c)}}function r(){return C.find("a.active,a.aui-dropdown2-active")}function s(a){return N&&N[0]===a[0]?!1:(N=a,r().removeClass("active aui-dropdown2-active"),o(a)&&a.addClass("active aui-dropdown2-active"),C.trigger("aui-dropdown2-item-selected"),A(),!0)}function t(){s(C.find("a:not(.disabled):not(.aui-dropdown2-disabled)").first())}function u(a){var b=C.find("> ul > li > a, > .aui-dropdown2-section > ul > li > a").not(".disabled,.aui-dropdown2-disabled");s(x(b,a,!0))}function v(a){a.length>0&&(m(),a.trigger("aui-button-invoke"))}function w(a){v(x(J.find(".aui-dropdown2-trigger").not(".disabled, .aui-dropdown2-disabled, [aria-disabled=true], .aui-dropdown2-sub-trigger"),a,!1))}function x(a,b,c){var d=a.index(a.filter(".active,.aui-dropdown2-active"));return d+=0>d&&0>b?1:0,d+=b,c?d%=a.length:0>d&&(d=a.length),a.eq(d)}function y(){v(a(this))}function z(){g===M&&(f.unbind(M),g=null)}function A(){g!==M&&(f.unbind(g),f.bind(M),g=M)}function B(a){var b="bind",c="delegate";"on"!==a&&(b="unbind",c="undelegate"),E?K[b]("aui-dropdown2-hide aui-dropdown2-item-selected aui-dropdown2-step-out",n):(J[c](".aui-dropdown2-trigger:not(.active):not(.aui-dropdown2-active)","mousemove",y),D[b]("aui-button-invoke",l)),C[b]("aui-dropdown2-hide-all",m),C[c]("a",L),C[b]("aui-dropdown2-hide",A),C[b]("aui-dropdown2-select-first",t)}i=a.extend({selectFirst:!0},i);var C=e(this),D=a(this).addClass("active aui-dropdown2-active"),E=D.hasClass("aui-dropdown2-sub-trigger"),F=C.parent()[0],G=C.next()[0],H=a(this).attr("data-dropdown2-hide-location");if(H){var I=document.getElementById(H);if(!I)throw new Error("The specified data-dropdown2-hide-location id doesn't exist");F=a(I),G=void 0}var J=i.$menu||D.closest(".aui-dropdown2-trigger-group");if(E){var K=D.closest(".aui-dropdown2");C.addClass(K.attr("class")).addClass("aui-dropdown2-sub-menu")}var L={click:function(c){var d=a(this);o(d)&&(d.hasClass("interactive")||d.hasClass("aui-dropdown2-interactive")||m(),p(d)&&(q(d,{selectFirst:!1}),b(c)))},mousemove:function(){var b=a(this),c=s(b);c&&q(b,{selectFirst:!1})}},M={"click focusin mousedown":function(a){var b=a.target;(document!==b||"focusin"!==a.type)&&(d(b,C[0])||d(b,D[0])||m())},keydown:function(a){var d;if(a.shiftKey&&9==a.keyCode)u(-1);else switch(a.keyCode){case 13:d=r(),p(d)?q(d):c(d[0]);break;case 27:l();break;case 37:if(d=r(),p(d)){var f=e(d);if(f.is(":visible"))return void C.trigger("aui-dropdown2-step-out")}E?l():w(-1);break;case 38:u(-1);break;case 39:d=r(),p(d)?q(d):w(1);break;case 40:u(1);break;case 9:u(1);break;default:return}b(a)}};D.attr("aria-controls",D.attr("aria-owns")),C.find(".disabled,.aui-dropdown2-disabled").attr("aria-disabled","true"),C.find("li.hidden > a,li.aui-dropdown2-hidden > a").addClass("disabled aui-dropdown2-disabled").attr("aria-disabled","true"),j(C.find(".aui-dropdown2-checkbox"),"checkbox"),j(C.find(".aui-dropdown2-radio"),"radio"),k(),D.hasClass("toolbar-trigger")&&C.addClass("aui-dropdown2-in-toolbar"),D.parent().hasClass("aui-buttons")&&C.addClass("aui-dropdown2-in-buttons"),D.parents().hasClass("aui-header")&&C.addClass("aui-dropdown2-in-header"),C.trigger("aui-dropdown2-show",i),i.selectFirst&&t(),B("on");var N=null},mousedown:function(b){1===b.which&&a(this).bind(j)}},j={mouseleave:function(){f.bind(k)},"mouseup mouseleave":function(){a(this).unbind(j)}},k={mouseup:function(b){var d=a(b.target).closest(".aui-dropdown2 a, .aui-dropdown2-trigger")[0];d&&setTimeout(function(){c(d)},0)},"mouseup mouseleave":function(){a(this).unbind(k)}};f.delegate(".aui-dropdown2-trigger",h),f.delegate(".aui-dropdown2-trigger:not(.active):not(.aui-dropdown2-active):not([aria-disabled=true]),.aui-dropdown2-sub-trigger:not([aria-disabled=true])",i),f.delegate(".aui-dropdown2-checkbox:not(.disabled):not(.aui-dropdown2-disabled)","click",function(){var b=a(this);b.hasClass("checked")||b.hasClass("aui-dropdown2-checked")?(b.removeClass("checked aui-dropdown2-checked").attr("aria-checked","false"),b.trigger("aui-dropdown2-item-uncheck")):(b.addClass("checked aui-dropdown2-checked").attr("aria-checked","true"),b.trigger("aui-dropdown2-item-check"))}),f.delegate(".aui-dropdown2-radio:not(.checked):not(.aui-dropdown2-checked):not(.disabled):not(.aui-dropdown2-disabled)","click",function(){var b=a(this),c=b.closest("ul").find(".checked,.aui-dropdown2-checked");c.removeClass("checked aui-dropdown2-checked").attr("aria-checked","false").trigger("aui-dropdown2-item-uncheck"),b.addClass("checked aui-dropdown2-checked").attr("aria-checked","true").trigger("aui-dropdown2-item-check")}),f.delegate(".aui-dropdown2 a.disabled,.aui-dropdown2 a.aui-dropdown2-disabled","click",function(a){b(a)})}(AJS.$),AJS.bind=function(a,b,c){try{return"function"==typeof c?AJS.$(window).bind(a,b,c):AJS.$(window).bind(a,b)}catch(d){AJS.log("error while binding: "+d.message)}},AJS.unbind=function(a,b){try{return AJS.$(window).unbind(a,b)}catch(c){AJS.log("error while unbinding: "+c.message)}},AJS.trigger=function(a,b){try{return AJS.$(window).trigger(a,b)}catch(c){AJS.log("error while triggering: "+c.message)}},AJS.warnAboutFirebug=function(){AJS.log("DEPRECATED: please remove all uses of AJS.warnAboutFirebug")},AJS.inlineHelp=function(){AJS.$(".icon-inline-help").click(function(){var a=AJS.$(this).siblings(".field-help");a.hasClass("hidden")?a.removeClass("hidden"):a.addClass("hidden")})},function(a){function b(b){var c=a(b),d=a.extend({left:0,top:0},c.offset());return{left:d.left,top:d.top,width:c.outerWidth(),height:c.outerHeight()}}function c(a,b,c,d){var e=AJS.$.isFunction(d.offsetX)?d.offsetX(a,b,c,d):d.offsetX,f=AJS.$.isFunction(d.offsetY)?d.offsetY(a,b,c,d):d.offsetY,g=AJS.$.isFunction(d.arrowOffsetX)?d.arrowOffsetX(a,b,c,d):d.arrowOffsetX,h=AJS.$.isFunction(d.arrowOffsetY)?d.arrowOffsetY(a,b,c,d):d.arrowOffsetY,i="body"!==d.container.toLowerCase(),j=AJS.$(d.container),k=i?AJS.$(d.container).parent():AJS.$(window),l=i?j.offset():{left:0,top:0},m=i?k.offset():{left:0,top:0},n=b.target,o=n.offset(),p=n[0].getBBox&&n[0].getBBox();return{screenPadding:10,arrowMargin:5,window:{top:m.top,left:m.left,scrollTop:k.scrollTop(),scrollLeft:k.scrollLeft(),width:k.width(),height:k.height()},scrollContainer:{width:j.width(),height:j.height()},trigger:{top:o.top-l.top,left:o.left-l.left,width:p?p.width:n.outerWidth(),height:p?p.height:n.outerHeight()},dialog:{width:a.width(),height:a.height(),offset:{top:f,left:e}},arrow:{height:a.find(".arrow").outerHeight(),offset:{top:h,left:g}}}}function d(a,b,d,e){var f=c(a,b,d,e),g=f.screenPadding,h=f.window,i=f.trigger,j=f.dialog,k=f.arrow,l=f.scrollContainer,m={top:i.top-h.scrollTop,left:i.left-h.scrollLeft},n=Math.floor(i.height/2),o=Math.floor(j.height/2),p=Math.floor(k.height/2),q=m.left-j.offset.left-g,r=l.width-m.left-i.width-j.offset.left-g,s=q>=j.width,t=r>=j.width,u=!t&&s?"e":"w",v=m.top+n-p,w=h.height-v-k.height;g=Math.min(g,v-f.arrowMargin),g=Math.min(g,w-f.arrowMargin);var x,y,z=m.top+n,A=Math.max(z-g,0),B=Math.max(h.height-z-g,0),C=o-j.offset.top>A,D=o+j.offset.top>B;return C?(x={top:h.scrollTop+g,left:"w"===u?i.left+i.width+j.offset.left:i.left-j.width-j.offset.left},y={top:i.top+n-(x.top+p)}):D?(x={top:h.scrollTop+h.height-j.height-g,left:"w"===u?i.left+i.width+j.offset.left:i.left-j.width-j.offset.left},y={top:i.top+n-(x.top+p)}):(x={top:i.top+n-o+j.offset.top,left:"w"===u?i.left+i.width+j.offset.left:i.left-j.width-j.offset.left},y={top:o-p+k.offset.top}),{gravity:u,popupCss:x,arrowCss:y}}function e(a,c,d,e){var f=AJS.$.isFunction(e.offsetX)?e.offsetX(a,c,d,e):e.offsetX,g=AJS.$.isFunction(e.offsetY)?e.offsetY(a,c,d,e):e.offsetY,h=AJS.$.isFunction(e.arrowOffsetX)?e.arrowOffsetX(a,c,d,e):e.arrowOffsetX,i=(AJS.$.isFunction(e.arrowOffsetY)?e.arrowOffsetY(a,c,d,e):e.arrowOffsetY,b(window)),j=b(c.target),k=b(a),l=b(a.find(".aui-inline-dialog-arrow")),m=j.left+j.width/2,n=(window.pageYOffset||document.documentElement.scrollTop)+i.height,o=10;k.top=j.top+j.height+~~g,k.left=j.left+~~f;var p=i.width-(k.left+k.width+o);l.left=m-k.left+~~h,l.top=-(l.height/2);var q=j.top>k.height,r=k.top+k.height<n,s=!r&&q||q&&"s"===e.gravity;if(s&&(k.top=j.top-k.height-l.height/2,l.top=k.height),e.isRelativeToMouse)0>p?(k.right=o,k.left="auto",l.left=d.x-(i.width-k.width)):(k.left=d.x-20,l.left=d.x-k.left);else if(0>p){k.right=o,k.left="auto";var t=i.width-k.right,u=t-k.width;l.right="auto",l.left=m-u-l.width/2}else k.width<=j.width/2&&(l.left=k.width/2,k.left=m-k.width/2);return{gravity:s?"s":"n",displayAbove:s,popupCss:{left:k.left,top:k.top,right:k.right},arrowCss:{left:l.left,top:l.top,right:l.right}}}AJS.InlineDialog=function(b,c,d,e){if(e&&e.getArrowAttributes&&AJS.log("DEPRECATED: getArrowAttributes - See https://ecosystem.atlassian.net/browse/AUI-1362"),e&&e.getArrowPath&&(AJS.log("DEPRECATED: getArrowPath - See https://ecosystem.atlassian.net/browse/AUI-1362"),void 0!==e.gravity&&AJS.log("DEPRECATED: getArrowPath does not support gravity - See https://ecosystem.atlassian.net/browse/AUI-2197")),e&&void 0!==e.onTop&&(AJS.log("DEPRECATED: onTop has been replaced with gravity - See https://ecosystem.atlassian.net/browse/AUI-2197"),e.onTop&&void 0===e.gravity&&(e.gravity="s")),"undefined"==typeof c&&(c=String(Math.random()).replace(".",""),a("#inline-dialog-"+c+", #arrow-"+c+", #inline-dialog-shim-"+c).length))throw"GENERATED_IDENTIFIER_NOT_UNIQUE";var f=a.extend(!1,AJS.InlineDialog.opts,e);"w"===f.gravity&&(f.offsetX=void 0===e.offsetX?10:e.offsetX,f.offsetY=void 0===e.offsetY?0:e.offsetY);var g,h,i,j,k,l=function(){return window.Raphael&&e&&(e.getArrowPath||e.getArrowAttributes)},m=!1,n=!1,o=!1,p=a('<div id="inline-dialog-'+c+'" class="aui-inline-dialog"><div class="aui-inline-dialog-contents contents"></div><div id="arrow-'+c+'" class="aui-inline-dialog-arrow arrow"></div></div>'),q=a("#arrow-"+c,p),r=p.find(".contents");l()||p.find(".aui-inline-dialog-arrow").addClass("aui-css-arrow"),f.displayShadow||r.addClass("aui-inline-dialog-no-shadow"),f.autoWidth?r.addClass("aui-inline-dialog-auto-width"):r.css("width",f.width+"px"),r.mouseover(function(){clearTimeout(h),p.unbind("mouseover")}).mouseout(function(){u()});var s=function(){return g||(g={popup:p,hide:function(){u(0)},id:c,show:function(){t()},persistent:f.persistent?!0:!1,reset:function(){function b(b,d){if(b.css(d.popupCss),l()){"s"===d.gravity&&(d.arrowCss.top-=a.browser.msie?10:9),b.arrowCanvas||(b.arrowCanvas=Raphael("arrow-"+c,16,16));var e=f.getArrowPath,g=a.isFunction(e)?e(d):e;b.arrowCanvas.path(g).attr(f.getArrowAttributes())}else q.removeClass("aui-bottom-arrow aui-left-arrow aui-right-arrow"),"s"!==d.gravity||q.hasClass("aui-bottom-arrow")?"n"===d.gravity||("w"===d.gravity?q.addClass("aui-left-arrow"):"e"===d.gravity&&q.addClass("aui-right-arrow")):q.addClass("aui-bottom-arrow");q.css(d.arrowCss)}var d=AJS.$(window).height(),e=Math.round(.75*d);p.children(".aui-inline-dialog-contents").css("max-height",e);var g=f.calculatePositions(p,k,j,f);if(void 0!==g.displayAbove&&(AJS.log("DEPRECATED: displayAbove has been replaced with gravity - See https://ecosystem.atlassian.net/browse/AUI-2197"),g.gravity=g.displayAbove?"s":"n"),b(p,g),p.fadeIn(f.fadeTime,function(){}),a.browser.msie&&~~a.browser.version<10){var h=a("#inline-dialog-shim-"+c);h.length||a(p).prepend(a('<iframe class = "inline-dialog-shim" id="inline-dialog-shim-'+c+'" frameBorder="0" src="javascript:false;"></iframe>')),h.css({width:r.outerWidth(),height:r.outerHeight()})}}}),g},t=function(){p.is(":visible")||(i=setTimeout(function(){o&&n&&(f.addActiveClass&&a(b).addClass("active"),m=!0,f.persistent||B(),AJS.InlineDialog.current=s(),a(document).trigger("showLayer",["inlineDialog",s()]),s().reset())},f.showDelay))},u=function(c){"undefined"==typeof c&&f.persistent||(n=!1,m&&f.preHideCallback.call(p[0].popup)&&(c=null==c?f.hideDelay:c,clearTimeout(h),clearTimeout(i),null!=c&&(h=setTimeout(function(){C(),f.addActiveClass&&a(b).removeClass("active"),p.fadeOut(f.fadeTime,function(){f.hideCallback.call(p[0].popup)}),p.arrowCanvas&&(p.arrowCanvas.remove(),p.arrowCanvas=null),m=!1,n=!1,a(document).trigger("hideLayer",["inlineDialog",s()]),AJS.InlineDialog.current=null,f.cacheContent||(o=!1,w=!1)},c))))},v=function(b,e){var g=a(e);f.upfrontCallback.call({popup:p,hide:function(){u(0)},id:c,show:function(){t()}}),p.each(function(){"undefined"!=typeof this.popup&&this.popup.hide()}),f.closeOthers&&a(".aui-inline-dialog").each(function(){!this.popup.persistent&&this.popup.hide()}),k={target:g},j=b?{x:b.pageX,y:b.pageY}:{x:g.offset().left,y:g.offset().top},m||clearTimeout(i),n=!0;var l=function(){w=!1,o=!0,f.initCallback.call({popup:p,hide:function(){u(0)},id:c,show:function(){t()}}),t()};return w||(w=!0,a.isFunction(d)?d(r,e,l):a.get(d,function(a,b,d){r.html(f.responseHandler(a,b,d)),o=!0,f.initCallback.call({popup:p,hide:function(){u(0)},id:c,show:function(){t()}}),t()})),clearTimeout(h),m||t(),!1};p[0].popup=s();var w=!1,x=!1,y=function(){x||(a(f.container).append(p),x=!0)},z=a(b);f.onHover?f.useLiveEvents?z.selector?a(document).on("mousemove",z.selector,function(a){y(),v(a,this)}).on("mouseout",z.selector,function(){u()}):AJS.log("Warning: inline dialog trigger elements must have a jQuery selector when the useLiveEvents option is enabled."):z.mousemove(function(a){y(),v(a,this)}).mouseout(function(){u()}):f.noBind||(f.useLiveEvents?z.selector?a(document).on("click",z.selector,function(a){return y(),A()?p.hide():v(a,this),!1}).on("mouseout",z.selector,function(){u()}):AJS.log("Warning: inline dialog trigger elements must have a jQuery selector when the useLiveEvents option is enabled."):z.click(function(a){return y(),A()?p.hide():v(a,this),!1}).mouseout(function(){u()}));var A=function(){return m&&f.closeOnTriggerClick},B=function(){F(),I()},C=function(){G(),J()},D=!1,E=c+".inline-dialog-check",F=function(){D||(a("body").bind("click."+E,function(b){var d=a(b.target);0===d.closest("#inline-dialog-"+c+" .contents").length&&u(0)}),D=!0)},G=function(){D&&a("body").unbind("click."+E),D=!1},H=function(a){27===a.keyCode&&u(0)},I=function(){a(document).on("keydown",H)},J=function(){a(document).off("keydown",H)};return p.show=function(a,c){a&&a.stopPropagation(),y(),!f.noBind||b&&b.length?v(a,b):v(a,void 0===c?a.target:c)},p.hide=function(){u(0)},p.refresh=function(){m&&s().reset()},p.getOptions=function(){return f},p},AJS.InlineDialog.opts={onTop:!1,responseHandler:function(a){return a},closeOthers:!0,isRelativeToMouse:!1,addActiveClass:!0,onHover:!1,useLiveEvents:!1,noBind:!1,fadeTime:100,persistent:!1,hideDelay:1e4,showDelay:0,width:300,offsetX:0,offsetY:10,arrowOffsetX:0,arrowOffsetY:0,container:"body",cacheContent:!0,displayShadow:!0,autoWidth:!1,gravity:"n",closeOnTriggerClick:!1,preHideCallback:function(){return!0},hideCallback:function(){},initCallback:function(){},upfrontCallback:function(){},calculatePositions:function(a,b,c,f){f=f||{};var g="w"===f.gravity?d:e;return g(a,b,c,f)},getArrowPath:function(a){return"s"===a.gravity?"M0,8L8,16,16,8":"M0,8L8,0,16,8"},getArrowAttributes:function(){return{fill:"#fff",stroke:"#ccc"}}}}(AJS.$),function(){AJS.keyCode={ALT:18,BACKSPACE:8,CAPS_LOCK:20,COMMA:188,COMMAND:91,COMMAND_LEFT:91,COMMAND_RIGHT:93,CONTROL:17,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,INSERT:45,LEFT:37,MENU:93,NUMPAD_ADD:107,NUMPAD_DECIMAL:110,NUMPAD_DIVIDE:111,NUMPAD_ENTER:108,NUMPAD_MULTIPLY:106,NUMPAD_SUBTRACT:109,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SHIFT:16,SPACE:32,TAB:9,UP:38,WINDOWS:91}}(AJS.$),function(){var a=500,b=5e3,c=100;AJS.messages={setup:function(){AJS.messages.createMessage("generic"),AJS.messages.createMessage("error"),AJS.messages.createMessage("warning"),AJS.messages.createMessage("info"),AJS.messages.createMessage("success"),AJS.messages.createMessage("hint"),AJS.messages.makeCloseable(),AJS.messages.makeFadeout()},makeCloseable:function(a){AJS.$(a||"div.aui-message.closeable").each(function(){var a=AJS.$(this),b=AJS.$('<span class="aui-icon icon-close" role="button" tabindex="0"></span>').click(function(){a.closeMessage()}).keypress(function(b){(b.which===AJS.keyCode.ENTER||b.which===AJS.keyCode.SPACE)&&(a.closeMessage(),b.preventDefault())});a.append(b)})},makeFadeout:function(d,e,f){e="undefined"!=typeof e?e:b,f="undefined"!=typeof f?f:a,AJS.$(d||"div.aui-message.fadeout").each(function(){function a(){g.stop(!0,!1).delay(e).fadeOut(f,function(){g.closeMessage()})}function b(){g.stop(!0,!1).fadeTo(c,1)}function d(){return!h&&!i}var g=AJS.$(this),h=!1,i=!1;g.focusin(function(){h=!0,b()}).focusout(function(){h=!1,d()&&a()}).hover(function(){i=!0,b()},function(){i=!1,d()&&a()}),a()})},template:'<div class="aui-message {type} {closeable} {shadowed} {fadeout}"><p class="title"><strong>{title}</strong></p>{body}<!-- .aui-message --></div>',createMessage:function(a){AJS.messages[a]=function(b,c){var d,e,f=this.template;return c||(c=b,b="#aui-message-bar"),c.closeable=c.closeable!==!1,c.shadowed=c.shadowed!==!1,d=AJS.$(AJS.template(f).fill({type:"aui-message-"+a+" "+a,closeable:c.closeable?"closeable":"",shadowed:c.shadowed?"shadowed":"",fadeout:c.fadeout?"fadeout":"",title:c.title||"","body:html":c.body||""}).toString()),c.id&&(/[#\'\"\.\s]/g.test(c.id)?AJS.log("AJS.Messages error: ID rejected, must not include spaces, hashes, dots or quotes."):d.attr("id",c.id)),e=c.insert||"append","prepend"===e?d.prependTo(b):d.appendTo(b),c.closeable&&AJS.messages.makeCloseable(d),c.fadeout&&AJS.messages.makeFadeout(d,c.delay,c.duration),d}}},AJS.$.fn.closeMessage=function(){var a=AJS.$(this);a.hasClass("aui-message","closeable")&&(a.stop(!0),a.trigger("messageClose",[this]).remove(),AJS.$(document).trigger("aui-message-close",[this]))},AJS.$(function(){AJS.messages.setup()})}(),function(a){"use strict";function b(){var b=a(this);AJS._addID(b),b.attr("role","tab");var c=b.attr("href");a(c).attr("aria-labelledby",b.attr("id")),b.parent().hasClass(k)?b.attr(m,"true"):b.attr(m,"false")}function c(b,c){var d=a(b),e=d.parent(),f=d.find(".tabs-menu").first(),g=f.find("li:not(.aui-tabs-responsive-trigger-item)"),h=f.find(".aui-tabs-responsive-trigger").parent(),j=h.find("a"),k=j.attr("aria-owns"),l=a(document).find("#"+k).attr("aria-checked",!1),m=l.length>0,n=r.totalTabsWidth(g,l),o=n>e.outerWidth();if(!m&&o&&(h=r.createResponsiveDropdownTrigger(f,c),l=r.createResponsiveDropdown(d,c)),j.attr("aria-owns","aui-tabs-responsive-dropdown-"+c),j.attr("id","aui-tabs-responsive-trigger-"+c),j.attr("href","aui-tabs-responsive-trigger-"+c),l.attr("id","aui-tabs-responsive-dropdown-"+c),o){var p=r.processVisibleTabs(g.toArray(),e,h),q=r.totalVisibleTabWidth(p),s=e.outerWidth()-q-h.outerWidth(!0),t=s>0;if(t){var u=l.find("li");r.processInvisibleTabs(u.toArray(),s,h)}l.on("click","a",i)}m&&!o&&(l.find("li").each(function(){r.moveTabOutOfDropdown(a(this),h)}),r.removeResponsiveDropdown(l,h))}function d(b){if(!b.hasClass("aui-tabs-responsive-trigger")){var c=a(b.attr("href").match(j)[0]);c.addClass(l).attr(n,"false").siblings(".tabs-pane").removeClass(l).attr(n,"true");var d=b.parents(".aui-tabs").find(".aui-tabs-responsive-trigger-item a"),e=d.attr("aria-owns"),f=a(document).find("#"+e);f.find("li a").attr("aria-checked",!1).removeClass("checked aui-dropdown2-checked"),f.find("li").removeClass("active-tab")}if(b.parent("li.menu-item").addClass(k).siblings(".menu-item").removeClass(k),b.hasClass("aui-tabs-responsive-item")){var g=c.parent(".aui-tabs").find("li.menu-item:not(.aui-tabs-responsive-trigger-item)");g.removeClass(k),g.find("a").removeClass("checked").removeAttr("aria-checked")}b.closest(".tabs-menu").find("a").attr(m,"false"),b.attr(m,"true"),b.trigger("tabSelect",{tab:b,pane:c})}function e(a){return void 0!==a.attr(o)&&"false"!==a.attr(o)}function f(a){var b=a.attr("id"),c=a.attr(o);return p+(b?b:"")+(c&&"true"!==c?"-"+c:"")}function g(a){for(var b=0,c=a.length;c>b;b++){var g=a.eq(b);if(e(g)){var h=g.attr("id");if(h){var i=window.localStorage.getItem(f(g));if(i){var j=g.find("#"+i);j.length&&d(j)}}else AJS.warn("A tab group must specify an id attribute if it specifies data-aui-persist")}}}function h(a){var b=a.closest(".aui-tabs"),c=b.attr("id");if(c){var d=a.attr("id");d&&window.localStorage.setItem(f(b),d)}else AJS.warn("A tab group must specify an id attribute if it specifies data-aui-persist")}function i(b){AJS.tabs.change(a(this),b),b&&b.preventDefault()}var j=/#.*/,k="active-tab",l="active-pane",m="aria-selected",n="aria-hidden",o="data-aui-persist",p="_internal-aui-tabs-",q=".aui-tabs.horizontal-tabs[data-aui-responsive]:not([data-aui-responsive='false'])",r={totalTabsWidth:function(a,b){var c=this.totalVisibleTabWidth(a),d=0;return b.find("li").each(function(a,b){d+=parseInt(b.getAttribute("data-aui-tab-width")) }),c+d},totalVisibleTabWidth:function(b){var c=0;return b.each(function(b,d){c+=a(d).outerWidth()}),c},removeResponsiveDropdown:function(a,b){a.remove(),b.remove()},createResponsiveDropdownTrigger:function(a,b){var c='<li class="menu-item aui-tabs-responsive-trigger-item"><a class="aui-dropdown2-trigger aui-tabs-responsive-trigger" id="aui-tabs-responsive-trigger-'+b+'" aria-haspopup="true" aria-owns="aui-tabs-responsive-dropdown-'+b+'" href="aui-tabs-responsive-dropdown-'+b+'">...</a></li>';a.append(c);var d=a.find(".aui-tabs-responsive-trigger-item");return d},createResponsiveDropdown:function(a,b){var c='<div class="aui-dropdown2 aui-style-default aui-tabs-responsive-dropdown" id="aui-tabs-responsive-dropdown-'+b+'"><ul></ul></div>';a.append(c);var d=a.find("#aui-tabs-responsive-dropdown-"+b);return d},findNewVisibleTabs:function(b,c,d){function e(a,b,c){return c>=a+b}for(var f=0,g=0;e(f,d,c)&&g<b.length;g++){var h=a(b[g]),i=h.outerWidth(!0);f+=i}return b.slice(0,g-1)},processVisibleTabs:function(b,c,d){for(var e=d.find("a").attr("aria-owns"),f=a("#"+e),g=this.findNewVisibleTabs(b,c.outerWidth(),d.parent().outerWidth(!0)),h=g.length-1,i=b.length-1;i>=h;i--){var j=a(b[i]);this.moveTabToResponsiveDropdown(j,f,d)}return a(g)},moveTabToResponsiveDropdown:function(a,b,c){var d=a.find("a");a.attr("data-aui-tab-width",a.outerWidth(!0)),d.addClass("aui-dropdown2-radio aui-tabs-responsive-item"),a.hasClass("active-tab")&&(d.addClass("aui-dropdown2-checked"),c.addClass("active-tab")),b.find("ul").prepend(a)},processInvisibleTabs:function(b,c,d){function e(a){return a>0}for(var f=0;e(c)&&f<b.length;f++){var g=a(b[f]),h=parseInt(g.attr("data-aui-tab-width"),10),i=c>h;i&&this.moveTabOutOfDropdown(g,d),c-=h}},moveTabOutOfDropdown:function(a,b){var c=a.find("a").hasClass("aui-dropdown2-checked");c&&(a.addClass("active-tab"),b.removeClass("active-tab")),a.children("a").removeClass("aui-dropdown2-radio aui-tabs-responsive-item aui-dropdown2-checked"),b.before(a)}};AJS.tabs={setup:function(){function d(a){for(var b in a)c(a[b],b)}var e=a(".aui-tabs:not(.aui-tabs-disabled)"),f=a(q).toArray();d(f);var h=AJS.debounce(d,200);a(window).resize(function(){h(f)}),e.attr("role","application"),e.find(".tabs-pane").each(function(){var b=a(this);b.attr("role","tabpanel"),b.hasClass(l)?b.attr(n,"false"):b.attr(n,"true")});for(var j=0,k=e.length;k>j;j++){var m=e.eq(j);if(!m.data("aui-tab-events-bound")){var o=m.children("ul.tabs-menu");o.attr("role","tablist"),o.children("li").attr("role","presentation"),o.find("> .menu-item a").each(b),o.delegate("a","click",i),m.data("aui-tab-events-bound",!0)}}window.localStorage&&g(e),a(".aui-tabs.vertical-tabs").find("a").each(function(){var b=a(this);if(!b.attr("title")){var c=b.children("strong:first");AJS.isClipped(c)&&b.attr("title",b.text())}})},change:function(a){d(a);var b=a.closest(".aui-tabs");window.localStorage&&e(b)&&h(a)}},a(AJS.tabs.setup)}(AJS.$),AJS.template=function(a){var b=/\{([^\}]+)\}/g,c=/(?:(?:^|\.)(.+?)(?=\[|\.|$|\()|\[('|")(.+?)\2\])(\(\))?/g,d=/([^\\])'/g,e=function(a,b,d,e){var f=d;return b.replace(c,function(a,b,c,d,g){b=b||d,f&&(b+":html"in f?(f=f[b+":html"],e=!0):b in f&&(f=f[b]),g&&"function"==typeof f&&(f=f()))}),(null==f||f==d)&&(f=a),f=String(f),e||(f=i.escape(f)),f},f=function(a){return this.template=this.template.replace(b,function(b,c){return e(b,c,a,!0)}),this},g=function(a){return this.template=this.template.replace(b,function(b,c){return e(b,c,a)}),this},h=function(){return this.template},i=function(a){function b(){return b.template}return b.template=String(a),b.toString=b.valueOf=h,b.fill=g,b.fillHtml=f,b},j={},k=[];return i.load=function(b){return b=String(b),j.hasOwnProperty(b)||(k.length>=1e3&&delete j[k.shift()],k.push(b),j[b]=a("script[title='"+b.replace(d,"$1\\'")+"']")[0].text),this(j[b])},i.escape=AJS.escapeHtml,i}(AJS.$),function(a,b){var c=-1!==navigator.platform.indexOf("Mac"),d=/^(backspace|tab|r(ight|eturn)|s(hift|pace|croll)|c(trl|apslock)|alt|pa(use|ge(up|down))|e(sc|nd)|home|left|up|d(el|own)|insert|f\d\d?|numlock|meta)/i;a.whenIType=function(e){function f(a){!AJS.popup.current&&p&&p.fire(a)}function g(a){a.preventDefault()}function h(a){var c=a&&a.split?b.trim(a).split(" "):[a];c.forEach(function(a){j(a)})}function i(a){for(var b=a.length;b--;)if(a[b].length>1&&"space"!==a[b])return!0;return!1}function j(a){var c=a instanceof Array?a:k(a.toString()),d=i(c)?"keydown":"keypress";o.push(c),b(document).bind(d,c,f),b(document).bind(d+" keyup",c,g)}function k(a){for(var b,c,e=[],f="";a.length;)(b=a.match(/^(ctrl|meta|shift|alt)\+/i))?(f+=b[0],a=a.substring(b[0].length)):(c=a.match(d))?(e.push(f+c[0]),a=a.substring(c[0].length),f=""):(e.push(f+a[0]),a=a.substring(1),f="");return e}function l(a){for(var d=b(a),e=d.attr("title")||"",f=o.slice(),g=d.data("kbShortcutAppended")||"",h=!g,i=h?e:e.substring(0,e.length-g.length);f.length;)g=n(f.shift().slice(),g,h),h=!1;c&&(g=g.replace(/Meta/gi,"\u2318").replace(/Shift/gi,"\u21e7")),d.attr("title",i+g),d.data("kbShortcutAppended",g)}function m(a){var c=b(a),d=c.data("kbShortcutAppended");if(d){var e=c.attr("title");c.attr("title",e.replace(d,"")),c.removeData("kbShortcutAppended")}}function n(a,b,c){return c?b+=" ("+AJS.I18n.getText("aui.keyboard.shortcut.type.x",a.shift()):(b=b.replace(/\)$/,""),b+=AJS.I18n.getText("aui.keyboard.shortcut.or.x",a.shift())),a.forEach(function(a){b+=" "+AJS.I18n.getText("aui.keyboard.shortcut.then.x",a)}),b+=")"}var o=[],p=b.Callbacks();return h(e),a.whenIType.makeShortcut({executor:p,bindKeys:h,addShortcutsToTitle:l,removeShortcutsFromTitle:m,keypressHandler:f,defaultPreventionHandler:g})},a.whenIType.makeShortcut=function(a){function c(a){return function(c,e){e=e||{};var f=e.focusedClass||"focused",g=e.hasOwnProperty("wrapAround")?e.wrapAround:!0,h=e.hasOwnProperty("escToCancel")?e.escToCancel:!0;return d.add(function(){var d=b(c),e=d.filter("."+f),i=0===e.length?void 0:{transition:!0};h&&b(document).one("keydown",function(a){a.keyCode===AJS.keyCode.ESCAPE&&e&&e.removeClass(f)}),e.length&&e.removeClass(f),e=a(e,d,g),e&&e.length>0&&(e.addClass(f),e.moveTo(i),e.is("a")?e.focus():e.find("a:first").focus())}),this}}var d=a.executor,e=a.bindKeys,f=a.addShortcutsToTitle,g=a.removeShortcutsFromTitle,h=a.keypressHandler,i=a.defaultPreventionHandler,j=[];return{moveToNextItem:c(function(a,c,d){var e;return d&&0===a.length?c.eq(0):(e=b.inArray(a.get(0),c),e<c.length-1?(e+=1,c.eq(e)):d?c.eq(0):a)}),moveToPrevItem:c(function(a,c,d){var e;return d&&0===a.length?c.filter(":last"):(e=b.inArray(a.get(0),c),e>0?(e-=1,c.eq(e)):d?c.filter(":last"):a)}),click:function(a){return j.push(a),f(a),d.add(function(){var c=b(a);c.length>0&&c.click()}),this},goTo:function(a){return d.add(function(){window.location.href=a}),this},followLink:function(a){return j.push(a),f(a),d.add(function(){var c=b(a)[0];c&&{a:!0,link:!0}[c.nodeName.toLowerCase()]&&(window.location.href=c.href)}),this},execute:function(a){var b=this;return d.add(function(){a.apply(b,arguments)}),this},evaluate:function(a){a.call(this)},moveToAndClick:function(a){return j.push(a),f(a),d.add(function(){var c=b(a);c.length>0&&(c.click(),c.moveTo())}),this},moveToAndFocus:function(a){return j.push(a),f(a),d.add(function(b){var c=AJS.$(a);c.length>0&&(c.focus(),c.moveTo&&c.moveTo(),c.is(":input")&&b.preventDefault())}),this},or:function(a){return e(a),this},unbind:function(){b(document).unbind("keydown keypress",h).unbind("keydown keypress keyup",i);for(var a=0,c=j.length;c>a;a++)g(j[a]);j=[]}}},a.whenIType.fromJSON=function(a,d){var e=[];return a&&b.each(a,function(a,f){var g,h=f.op,i=f.param;if("execute"===h||"evaluate"===h)g=[new Function(i)];else if(/^\[[^\]\[]*,[^\]\[]*\]$/.test(i)){try{g=JSON.parse(i)}catch(j){AJS.error("When using a parameter array, array must be in strict JSON format: "+i)}b.isArray(g)||AJS.error("Badly formatted shortcut parameter. String or JSON Array of parameters required: "+i)}else g=[i];f.keys.forEach(function(a){d&&c&&(a=b.map(this,function(a){return a.replace(/ctrl/i,"meta")}));var f=AJS.whenIType(a);f[h].apply(f,g),e.push(f)})}),e},b(document).bind("iframeAppended",function(a,c){b(c).load(function(){var a=b(c).contents();a.bind("keyup keydown keypress",function(a){b.browser.safari&&"keypress"===a.type||b(a.target).is(":input")||b.event.trigger(a,arguments,document,!0)})})})}(AJS,AJS.$),function(a){AJS.responsiveheader={},AJS.responsiveheader.setup=function(){function b(b,c){function d(a){var b;if(e(),!(n>o)){k.show(),b=n-q;for(var c=0;b>=0;c++)b-=m[c].itemWidth;return c-=1,h(c,a),g(c,l,a),c}i(a)}function e(){var b=0!==j.length?j.offset().left:a(window).width(),c=p.offset().left+p.outerWidth(!0)+s;n=b-c}function f(b){var c=a("<li>"+aui.dropdown2.trigger({menu:{id:"aui-responsive-header-dropdown-content-"+b},text:AJS.I18n.getText("aui.words.more"),extraAttributes:{href:"#"},id:"aui-responsive-header-dropdown-trigger-"+b})+"</li>");c.append(aui.dropdown2.contents({id:"aui-responsive-header-dropdown-content-"+b,extraClasses:"aui-style-default",content:aui.dropdown2.section({content:"<ul id='aui-responsive-header-dropdown-list-"+b+"'></ul>"})})),0===s?c.appendTo(r(".aui-nav")):c.insertBefore(r(".aui-nav > li > .aui-button").first().parent()),k=c,q=k.outerWidth(!0)}function g(b,c,d){if(!(0>b||0>c||b===c)){var e,f,g=a("#aui-responsive-header-dropdown-trigger-"+d),h=g.parent();g.hasClass("active")&&g.trigger("aui-button-invoke");for(var i=r(".aui-nav > li > a:not(.aui-button):not(#aui-responsive-header-dropdown-trigger-"+d+")").length;b>c;)e=m[c],e&&e.itemElement&&(f=e.itemElement,0===i?f.prependTo(r(".aui-nav")):f.insertBefore(h),f.children("a").removeClass("aui-dropdown2-sub-trigger active"),c+=1,i+=1)}}function h(b,c){if(!(0>b))for(var d=a("#aui-responsive-header-dropdown-list-"+c),e=b;e<m.length;e++){m[e].itemElement.appendTo(d);var f=m[e].itemElement.children("a");f.hasClass("aui-dropdown2-trigger")&&f.addClass("aui-dropdown2-sub-trigger")}}function i(a){k.hide(),g(m.length,l,a)}var j=b.find(".aui-header-secondary .aui-nav").first();a(".aui-header").attr("data-aui-responsive","true");var k,l,m=[],n=0,o=0,p=b.find("#logo"),q=0,r=function(){var a=b.find(".aui-header-primary").first();return function(b){return a.find(b)}}(),s=0;r(".aui-button").parent().each(function(b,c){s+=a(c).outerWidth(!0)}),r(".aui-nav > li > a:not(.aui-button)").each(function(b,c){var d=a(c).parent(),e=d.outerWidth(!0);m.push({itemElement:d,itemWidth:e}),o+=e}),l=m.length,a(window).resize(function(){l=d(c)}),f(c);var t=p.find("img");0!==t.length&&(t.attr("data-aui-responsive-header-index",c),t.load(function(){l=d(c)})),l=d(c),r(".aui-nav").css("width","auto")}var c=a(".aui-header");c.length&&c.each(function(c,d){b(a(d),c)})}}(AJS.$),AJS.$(AJS.responsiveheader.setup),function(a){"function"==typeof define&&define.amd?define(["jquery"],a):a(jQuery)}(function(a){"use strict";function b(c,d){var e=a(c).data("FancyFileInput");return e?e:(d=a.extend({},b.defaults,d),this.el=c,this.$el=a(c),this.$label=this.createLabel(d.buttonText),this._addLabelText(),this.$clearButton=a("<button>",{text:this.$label.attr("data-ffi-clearButtonText")||d.clearButtonText,"class":"ffi-clear",type:"button",tabindex:"-1"}),this.multipleFileTextPattern=this.$label.attr("data-ffi-multipleFileTextPattern")||d.multipleFileTextPattern,this._eventNamespace=".ffi",this.CLASSES={disabled:"is-disabled",focused:"is-focused",active:"is-active",valid:"is-valid",invalid:"is-invalid"},this[this.isDisabled()?"disable":"enable"](),void(this.isFocused=!1))}var c=/^.*[\\\/]/,d=/\{0\}/gi,e=function(){var a=3,b=document.createElement("div"),c=b.getElementsByTagName("i");do b.innerHTML="<!--[if gt IE "+ ++a+"]><i></i><![endif]-->";while(c[0]);return a>4?a:document.documentMode}();return a.fn.fancyFileInput=function(c){return this.each(function(){var d=new b(this,c);a(this).data("FancyFileInput",d)})},b.defaults={buttonText:"Browse\u2026",clearButtonText:"Clear",multipleFileTextPattern:"{0} files"},b.prototype._addLabelText=function(){var b=a('label[for="'+this.el.id+'"]');b.length&&this.$el.attr("aria-label",b.text())},b.prototype.createLabel=function(b){var c=this.$el.parent(".ffi[data-ffi-button-text]");return c.length||(c=this.$el.wrap(a("<label>",{"class":"ffi","data-ffi-button-text":b})).parent()),c},b.prototype.isDisabled=function(){return this.$el.is(":disabled")},b.prototype.formatMultipleFileText=function(a){return this.multipleFileTextPattern.replace(d,a)},b.prototype.bindEvents=function(){this.$el.on("invalid"+this._eventNamespace,a.proxy(this.checkValidity,this)).on("change"+this._eventNamespace,a.proxy(this.change,this)).on("keydown"+this._eventNamespace,a.proxy(this.keydown,this)).on("mousedown"+this._eventNamespace,a.proxy(this.mousedown,this)).on("mouseup"+this._eventNamespace,a.proxy(this.mouseup,this)).on("focus"+this._eventNamespace,a.proxy(this.focus,this)).on("blur"+this._eventNamespace,a.proxy(this.blur,this)),this.$clearButton.on("click"+this._eventNamespace,a.proxy(this.clear,this))},b.prototype.unbindEvents=function(){this.$el.off(this._eventNamespace),this.$clearButton.off(this._eventNamespace)},b.prototype.fireEvent=function(a){this.$el.trigger(a+this._eventNamespace)},b.prototype.enable=function(){this.bindEvents(),this.$el.prop("disabled",!1),this.$label.removeClass(this.CLASSES.disabled)},b.prototype.disable=function(){this.unbindEvents(),this.$el.prop("disabled",!0),this.$label.addClass(this.CLASSES.disabled)},b.prototype.clear=function(){return this.el.value="",this.cloneAndReplaceField(),this.change(),!1},b.prototype.cloneAndReplaceField=function(){var a=this.$el.clone();this.$el.replaceWith(a),this.unbindEvents(),this.$el=a,this.el=a[0],this.bindEvents()},b.prototype.focus=function(){var a=this;this.$label.addClass(this.CLASSES.focused),e&&!this.isFocused&&(this.isFocused=!0,setTimeout(function(){a.$el.blur(),a.$el.focus()},0))},b.prototype.blur=function(){e&&this.isFocused||(this.$label.removeClass(this.CLASSES.focused),this.isFocused=!1)},b.prototype.mousedown=function(){this.$label.addClass(this.CLASSES.active)},b.prototype.mouseup=function(){this.$label.removeClass(this.CLASSES.active)},b.prototype.keydown=function(a){var b=a.which,c=8,d=9,f=46;if((b===c||b===f)&&(this.clear(),a.preventDefault()),e&&b===d){var g=this;this.isFocused=!1,this.$el.prop("disabled",!0),setTimeout(function(){g.$el.prop("disabled",!1).blur()},0)}},b.prototype.checkValidity=function(){if(this.el.required){var a=this.$el.is(":invalid");this.$label.toggleClass(this.CLASSES.invalid,a).toggleClass(this.CLASSES.valid,!a)}},b.prototype.change=function(){var a,b="";this.checkValidity(),a=this.el.multiple&&this.el.files.length>1?this.formatMultipleFileText(this.el.files.length):this.el.value,a.length?(b=a.replace(c,""),this.$clearButton.appendTo(this.$label)):this.$clearButton.detach(),this.$el.focus(),this.setFieldText(b),this.fireEvent("value-changed")},b.prototype.setFieldText=function(a){var b="data-ffi-value";a.length?(this.$label.attr(b,a),this.fireEvent("value-added")):(this.$label.removeAttr(b),this.fireEvent("value-cleared"))},b}),function(a){function b(a,b){return"function"==typeof a?a.call(b):a}function c(a){for(;a=a.parentNode;)if(a==document)return!0;return!1}function d(){var a=f++;return"tipsyuid"+a}function e(b,c){this.$element=a(b),this.options=c,this.enabled=!0,this.fixTitle()}var f=0;e.prototype={show:function(){function c(){h.hoverTooltip=!0}function e(){if("in"!=h.hoverState&&(h.hoverTooltip=!1,"manual"!=h.options.trigger)){var a="hover"==h.options.trigger?"mouseleave.tipsy":"blur.tipsy";h.$element.trigger(a)}}var f=this.getTitle();if(f&&this.enabled){var g=this.tip();g.find(".tipsy-inner")[this.options.html?"html":"text"](f),g[0].className="tipsy",g.remove().css({top:0,left:0,visibility:"hidden",display:"block"}).prependTo(document.body);var h=this;this.options.hoverable&&g.hover(c,e),this.options.className&&g.addClass(b(this.options.className,this.$element[0]));var i,j=a.extend({},this.$element.offset(),{width:this.$element[0].offsetWidth,height:this.$element[0].offsetHeight}),k=g[0].offsetWidth,l=g[0].offsetHeight,m=b(this.options.gravity,this.$element[0]);switch(m.charAt(0)){case"n":i={top:j.top+j.height+this.options.offset,left:j.left+j.width/2-k/2};break;case"s":i={top:j.top-l-this.options.offset,left:j.left+j.width/2-k/2};break;case"e":i={top:j.top+j.height/2-l/2,left:j.left-k-this.options.offset};break;case"w":i={top:j.top+j.height/2-l/2,left:j.left+j.width+this.options.offset}}if(2==m.length&&(i.left="w"==m.charAt(1)?j.left+j.width/2-15:j.left+j.width/2-k+15),g.css(i).addClass("tipsy-"+m),g.find(".tipsy-arrow")[0].className="tipsy-arrow tipsy-arrow-"+m.charAt(0),this.options.fade?g.stop().css({opacity:0,display:"block",visibility:"visible"}).animate({opacity:this.options.opacity}):g.css({visibility:"visible",opacity:this.options.opacity}),this.options.aria){var n=d();g.attr("id",n),this.$element.attr("aria-describedby",n)}}},hide:function(){this.options.fade?this.tip().stop().fadeOut(function(){a(this).remove()}):this.tip().remove(),this.options.aria&&this.$element.removeAttr("aria-describedby")},fixTitle:function(){var a=this.$element;(a.attr("title")||"string"!=typeof a.attr("original-title"))&&a.attr("original-title",a.attr("title")||"").removeAttr("title")},getTitle:function(){var a,b=this.$element,c=this.options;this.fixTitle();var a,c=this.options;return"string"==typeof c.title?a=b.attr("title"==c.title?"original-title":c.title):"function"==typeof c.title&&(a=c.title.call(b[0])),a=(""+a).replace(/(^\s*|\s*$)/,""),a||c.fallback},tip:function(){return this.$tip||(this.$tip=a('<div class="tipsy"></div>').html('<div class="tipsy-arrow"></div><div class="tipsy-inner"></div>').attr("role","tooltip"),this.$tip.data("tipsy-pointee",this.$element[0])),this.$tip},validate:function(){this.$element[0].parentNode||(this.hide(),this.$element=null,this.options=null)},enable:function(){this.enabled=!0},disable:function(){this.enabled=!1},toggleEnabled:function(){this.enabled=!this.enabled}},a.fn.tipsy=function(b){function c(c){var d=a.data(c,"tipsy");return d||(d=new e(c,a.fn.tipsy.elementOptions(c,b)),a.data(c,"tipsy",d)),d}function d(){var a=c(this);a.hoverState="in",0==b.delayIn?a.show():(a.fixTitle(),setTimeout(function(){"in"==a.hoverState&&a.show()},b.delayIn))}function f(){var a=c(this);a.hoverState="out",0==b.delayOut?a.hide():setTimeout(function(){"out"!=a.hoverState||a.hoverTooltip||a.hide()},b.delayOut)}if(b===!0)return this.data("tipsy");if("string"==typeof b){var g=this.data("tipsy");return g&&g[b](),this}if(b=a.extend({},a.fn.tipsy.defaults,b),b.hoverable&&(b.delayOut=b.delayOut||20),b.live||this.each(function(){c(this)}),"manual"!=b.trigger){var h="hover"==b.trigger?"mouseenter.tipsy":"focus.tipsy",i="hover"==b.trigger?"mouseleave.tipsy":"blur.tipsy";b.live?a(this.context).on(h,this.selector,d).on(i,this.selector,f):this.bind(h,d).bind(i,f)}return this},a.fn.tipsy.defaults={aria:!1,className:null,delayIn:0,delayOut:0,fade:!1,fallback:"",gravity:"n",html:!1,live:!1,hoverable:!1,offset:0,opacity:.8,title:"title",trigger:"hover"},a.fn.tipsy.revalidate=function(){a(".tipsy").each(function(){var b=a.data(this,"tipsy-pointee");b&&c(b)||a(this).remove()})},a.fn.tipsy.elementOptions=function(b,c){return a.metadata?a.extend({},c,a(b).metadata()):c},a.fn.tipsy.autoNS=function(){return a(this).offset().top>a(document).scrollTop()+a(window).height()/2?"s":"n"},a.fn.tipsy.autoWE=function(){return a(this).offset().left>a(document).scrollLeft()+a(window).width()/2?"e":"w"},a.fn.tipsy.autoBounds=function(b,c){return function(){var d={ns:c[0],ew:c.length>1?c[1]:!1},e=a(document).scrollTop()+b,f=a(document).scrollLeft()+b,g=a(this);return g.offset().top<e&&(d.ns="n"),g.offset().left<f&&(d.ew="w"),a(window).width()+a(document).scrollLeft()-g.offset().left<b&&(d.ew="e"),a(window).height()+a(document).scrollTop()-g.offset().top<b&&(d.ns="s"),d.ns+(d.ew?d.ew:"")}}}(jQuery),!function(a){"use strict";a.extend({tablesorter:new function(){function b(a){"undefined"!=typeof console&&"undefined"!=typeof console.log?console.log(a):alert(a)}function c(a,c){b(a+" ("+((new Date).getTime()-c.getTime())+"ms)")}function d(b,c,d){if(!c)return"";var e=b.config,f=e.textExtraction,g="";return g="simple"===f?e.supportsTextContent?c.textContent:a(c).text():"function"==typeof f?f(c,b,d):"object"==typeof f&&f.hasOwnProperty(d)?f[d](c,b,d):e.supportsTextContent?c.textContent:a(c).text(),a.trim(g)}function e(a,c,e,f){for(var g,h=w.parsers.length,i=!1,j="",k=!0;""===j&&k;)e++,c[e]?(i=c[e].cells[f],j=d(a,i,f),a.config.debug&&b("Checking if value was empty on row "+e+", column: "+f+': "'+j+'"')):k=!1;for(;--h>=0;)if(g=w.parsers[h],g&&"text"!==g.id&&g.is&&g.is(j,a,i))return g;return w.getParserById("text")}function f(a){var c,d,f,g,h,i,j,k=a.config,l=k.$tbodies=k.$table.children("tbody:not(."+k.cssInfoBlock+")"),m="";if(0===l.length)return k.debug?b("*Empty table!* Not building a parser cache"):"";if(c=l[0].rows,c[0])for(d=[],f=c[0].cells.length,g=0;f>g;g++)h=k.$headers.filter(":not([colspan])"),h=h.add(k.$headers.filter('[colspan="1"]')).filter('[data-column="'+g+'"]:last'),i=k.headers[g],j=w.getParserById(w.getData(h,i,"sorter")),k.empties[g]=w.getData(h,i,"empty")||k.emptyTo||(k.emptyToBottom?"bottom":"top"),k.strings[g]=w.getData(h,i,"string")||k.stringTo||"max",j||(j=e(a,c,-1,g)),k.debug&&(m+="column:"+g+"; parser:"+j.id+"; string:"+k.strings[g]+"; empty: "+k.empties[g]+"\n"),d.push(j);k.debug&&b(m),k.parsers=d}function g(e){var f,g,h,i,j,k,l,m,n,o,p=e.tBodies,q=e.config,r=q.parsers,s=[];if(q.cache={},!r)return q.debug?b("*Empty table!* Not building a cache"):"";for(q.debug&&(o=new Date),q.showProcessing&&w.isProcessing(e,!0),l=0;l<p.length;l++)if(q.cache[l]={row:[],normalized:[]},!a(p[l]).hasClass(q.cssInfoBlock)){for(f=p[l]&&p[l].rows.length||0,g=p[l].rows[0]&&p[l].rows[0].cells.length||0,j=0;f>j;++j)if(m=a(p[l].rows[j]),n=[],m.hasClass(q.cssChildRow))q.cache[l].row[q.cache[l].row.length-1]=q.cache[l].row[q.cache[l].row.length-1].add(m);else{for(q.cache[l].row.push(m),k=0;g>k;++k)h=d(e,m[0].cells[k],k),i=r[k].format(h,e,m[0].cells[k],k),n.push(i),"numeric"===(r[k].type||"").toLowerCase()&&(s[k]=Math.max(Math.abs(i)||0,s[k]||0));n.push(q.cache[l].normalized.length),q.cache[l].normalized.push(n)}q.cache[l].colMax=s}q.showProcessing&&w.isProcessing(e),q.debug&&c("Building cache for "+f+" rows",o)}function h(b,d){var e,f,g,h,i,j,k,l,m,n,o,p,q=b.config,r=b.tBodies,s=[],t=q.cache;if(t[0]){for(q.debug&&(p=new Date),m=0;m<r.length;m++)if(i=a(r[m]),i.length&&!i.hasClass(q.cssInfoBlock)){for(j=w.processTbody(b,i,!0),e=t[m].row,f=t[m].normalized,g=f.length,h=g?f[0].length-1:0,k=0;g>k;k++)if(o=f[k][h],s.push(e[o]),!q.appender||!q.removeRows)for(n=e[o].length,l=0;n>l;l++)j.append(e[o][l]);w.processTbody(b,j,!1)}q.appender&&q.appender(b,s),q.debug&&c("Rebuilt table",p),d||w.applyWidget(b),a(b).trigger("sortEnd",b)}}function i(b){var c,d,e,f,g,h,i,j,k,l,m,n,o=[],p={},q=0,r=a(b).find("thead:eq(0), tfoot").children("tr");for(c=0;c<r.length;c++)for(h=r[c].cells,d=0;d<h.length;d++){for(g=h[d],i=g.parentNode.rowIndex,j=i+"-"+g.cellIndex,k=g.rowSpan||1,l=g.colSpan||1,"undefined"==typeof o[i]&&(o[i]=[]),e=0;e<o[i].length+1;e++)if("undefined"==typeof o[i][e]){m=e;break}for(p[j]=m,q=Math.max(m,q),a(g).attr({"data-column":m}),e=i;i+k>e;e++)for("undefined"==typeof o[e]&&(o[e]=[]),n=o[e],f=m;m+l>f;f++)n[f]="x"}return b.config.columns=q,p}function j(a){return/^d/i.test(a)||1===a}function k(d){var e,f,g,h,k,l,n,o=i(d),p=d.config;p.headerList=[],p.headerContent=[],p.debug&&(n=new Date),h=p.cssIcon?'<i class="'+p.cssIcon+'"></i>':"",p.$headers=a(d).find(p.selectorHeaders).each(function(b){f=a(this),e=p.headers[b],p.headerContent[b]=this.innerHTML,k=p.headerTemplate.replace(/\{content\}/g,this.innerHTML).replace(/\{icon\}/g,h),p.onRenderTemplate&&(g=p.onRenderTemplate.apply(f,[b,k]),g&&"string"==typeof g&&(k=g)),this.innerHTML='<div class="tablesorter-header-inner">'+k+"</div>",p.onRenderHeader&&p.onRenderHeader.apply(f,[b]),this.column=o[this.parentNode.rowIndex+"-"+this.cellIndex],this.order=j(w.getData(f,e,"sortInitialOrder")||p.sortInitialOrder)?[1,0,2]:[0,1,2],this.count=-1,this.lockedOrder=!1,l=w.getData(f,e,"lockedOrder")||!1,"undefined"!=typeof l&&l!==!1&&(this.order=this.lockedOrder=j(l)?[1,1,1]:[0,0,0]),f.addClass(p.cssHeader),p.headerList[b]=this,f.parent().addClass(p.cssHeaderRow),f.attr("tabindex",0)}),m(d),p.debug&&(c("Built headers:",n),b(p.$headers))}function l(a,b,c){var d=a.config;d.$table.find(d.selectorRemove).remove(),f(a),g(a),u(d.$table,b,c)}function m(b){var c,d=b.config;d.$headers.each(function(b,e){c="false"===w.getData(e,d.headers[b],"sorter"),e.sortDisabled=c,a(e)[c?"addClass":"removeClass"]("sorter-false")})}function n(b){var c,d,e,f,g=b.config,h=g.sortList,i=[g.cssAsc,g.cssDesc],j=a(b).find("tfoot tr").children().removeClass(i.join(" "));for(g.$headers.removeClass(i.join(" ")),f=h.length,d=0;f>d;d++)if(2!==h[d][1]&&(c=g.$headers.not(".sorter-false").filter('[data-column="'+h[d][0]+'"]'+(1===f?":last":"")),c.length))for(e=0;e<c.length;e++)c[e].sortDisabled||(c.eq(e).addClass(i[h[d][1]]),j.length&&j.filter('[data-column="'+h[d][0]+'"]').eq(e).addClass(i[h[d][1]]))}function o(b){if(b.config.widthFixed&&0===a(b).find("colgroup").length){var c=a("<colgroup>"),d=a(b).width();a(b.tBodies[0]).find("tr:first").children("td").each(function(){c.append(a("<col>").css("width",parseInt(a(this).width()/d*1e3,10)/10+"%"))}),a(b).prepend(c)}}function p(b,c){var d,e,f,g=b.config,h=c||g.sortList;g.sortList=[],a.each(h,function(b,c){d=[parseInt(c[0],10),parseInt(c[1],10)],f=g.headerList[d[0]],f&&(g.sortList.push(d),e=a.inArray(d[1],f.order),f.count=e>=0?e:d[1]%(g.sortReset?3:2))})}function q(a,b){return a&&a[b]?a[b].type||"":""}function r(b,c,d){var e,f,g,i,j,k=b.config,l=!d[k.sortMultiSortKey],m=a(b);if(m.trigger("sortStart",b),c.count=d[k.sortResetKey]?2:(c.count+1)%(k.sortReset?3:2),k.sortRestart&&(f=c,k.$headers.each(function(){this===f||!l&&a(this).is("."+k.cssDesc+",."+k.cssAsc)||(this.count=-1)})),f=c.column,l){if(k.sortList=[],null!==k.sortForce)for(e=k.sortForce,g=0;g<e.length;g++)e[g][0]!==f&&k.sortList.push(e[g]);if(i=c.order[c.count],2>i&&(k.sortList.push([f,i]),c.colSpan>1))for(g=1;g<c.colSpan;g++)k.sortList.push([f+g,i])}else if(k.sortAppend&&k.sortList.length>1&&w.isValueInArray(k.sortAppend[0][0],k.sortList)&&k.sortList.pop(),w.isValueInArray(f,k.sortList))for(g=0;g<k.sortList.length;g++)j=k.sortList[g],i=k.headerList[j[0]],j[0]===f&&(j[1]=i.order[i.count],2===j[1]&&(k.sortList.splice(g,1),i.count=-1));else if(i=c.order[c.count],2>i&&(k.sortList.push([f,i]),c.colSpan>1))for(g=1;g<c.colSpan;g++)k.sortList.push([f+g,i]);if(null!==k.sortAppend)for(e=k.sortAppend,g=0;g<e.length;g++)e[g][0]!==f&&k.sortList.push(e[g]);m.trigger("sortBegin",b),setTimeout(function(){n(b),s(b),h(b)},1)}function s(b){var d,e,f,g,h,i,j,k,l,m,n=0,o=b.config,p=o.sortList,r=p.length,s=b.tBodies.length;if(!o.serverSideSorting&&o.cache[0]){for(o.debug&&(d=new Date),f=0;s>f;f++)h=o.cache[f].colMax,i=o.cache[f].normalized,j=i.length,m=i&&i[0]?i[0].length-1:0,i.sort(function(c,d){for(e=0;r>e;e++){g=p[e][0],l=p[e][1],k=/n/i.test(q(o.parsers,g))?"Numeric":"Text",k+=0===l?"":"Desc",/Numeric/.test(k)&&o.strings[g]&&(n="boolean"==typeof o.string[o.strings[g]]?(0===l?1:-1)*(o.string[o.strings[g]]?-1:1):o.strings[g]?o.string[o.strings[g]]||0:0);var f=a.tablesorter["sort"+k](b,c[g],d[g],g,h[g],n);if(f)return f}return c[m]-d[m]});o.debug&&c("Sorting on "+p.toString()+" and dir "+l+" time",d)}}function t(a,b){a.trigger("updateComplete"),"function"==typeof b&&b(a[0])}function u(a,b,c){b===!1||a[0].isProcessing?t(a,c):a.trigger("sorton",[a[0].config.sortList,function(){t(a,c)}])}function v(b){var c,e,i=b.config,j=i.$table;i.$headers.find(i.selectorSort).add(i.$headers.filter(i.selectorSort)).unbind("mousedown.tablesorter mouseup.tablesorter sort.tablesorter keypress.tablesorter").bind("mousedown.tablesorter mouseup.tablesorter sort.tablesorter keypress.tablesorter",function(c,d){if(1!==(c.which||c.button)&&!/sort|keypress/.test(c.type)||"keypress"===c.type&&13!==c.which)return!1;if("mouseup"===c.type&&d!==!0&&(new Date).getTime()-e>250)return!1;if("mousedown"===c.type)return e=(new Date).getTime(),"INPUT"===c.target.tagName?"":!i.cancelSelection;i.delayInit&&!i.cache&&g(b);var f=/TH|TD/.test(this.tagName)?a(this):a(this).parents("th, td").filter(":first"),h=f[0];h.sortDisabled||r(b,h,c)}),i.cancelSelection&&i.$headers.attr("unselectable","on").bind("selectstart",!1).css({"user-select":"none",MozUserSelect:"none"}),j.unbind("sortReset update updateRows updateCell updateAll addRows sorton appendCache applyWidgetId applyWidgets refreshWidgets destroy mouseup mouseleave ".split(" ").join(".tablesorter ")).bind("sortReset.tablesorter",function(a){a.stopPropagation(),i.sortList=[],n(b),s(b),h(b)}).bind("updateAll.tablesorter",function(a,c,d){a.stopPropagation(),w.refreshWidgets(b,!0,!0),w.restoreHeaders(b),k(b),v(b),l(b,c,d)}).bind("update.tablesorter updateRows.tablesorter",function(a,c,d){a.stopPropagation(),m(b),l(b,c,d)}).bind("updateCell.tablesorter",function(c,e,f,g){c.stopPropagation(),j.find(i.selectorRemove).remove();var h,k,l,m=j.find("tbody"),n=m.index(a(e).parents("tbody").filter(":first")),o=a(e).parents("tr").filter(":first");e=a(e)[0],m.length&&n>=0&&(k=m.eq(n).find("tr").index(o),l=e.cellIndex,h=i.cache[n].normalized[k].length-1,i.cache[n].row[b.config.cache[n].normalized[k][h]]=o,i.cache[n].normalized[k][l]=i.parsers[l].format(d(b,e,l),b,e,l),u(j,f,g))}).bind("addRows.tablesorter",function(a,e,g,h){a.stopPropagation();var k,l=e.filter("tr").length,m=[],n=e[0].cells.length,o=j.find("tbody").index(e.parents("tbody").filter(":first"));for(i.parsers||f(b),k=0;l>k;k++){for(c=0;n>c;c++)m[c]=i.parsers[c].format(d(b,e[k].cells[c],c),b,e[k].cells[c],c);m.push(i.cache[o].row.length),i.cache[o].row.push([e[k]]),i.cache[o].normalized.push(m),m=[]}u(j,g,h)}).bind("sorton.tablesorter",function(a,c,d,e){a.stopPropagation(),j.trigger("sortStart",this),p(b,c),n(b),j.trigger("sortBegin",this),s(b),h(b,e),"function"==typeof d&&d(b)}).bind("appendCache.tablesorter",function(a,c,d){a.stopPropagation(),h(b,d),"function"==typeof c&&c(b)}).bind("applyWidgetId.tablesorter",function(a,c){a.stopPropagation(),w.getWidgetById(c).format(b,i,i.widgetOptions)}).bind("applyWidgets.tablesorter",function(a,c){a.stopPropagation(),w.applyWidget(b,c)}).bind("refreshWidgets.tablesorter",function(a,c,d){a.stopPropagation(),w.refreshWidgets(b,c,d)}).bind("destroy.tablesorter",function(a,c,d){a.stopPropagation(),w.destroy(b,c,d)})}var w=this;w.version="2.10.8",w.parsers=[],w.widgets=[],w.defaults={theme:"default",widthFixed:!1,showProcessing:!1,headerTemplate:"{content}",onRenderTemplate:null,onRenderHeader:null,cancelSelection:!0,dateFormat:"mmddyyyy",sortMultiSortKey:"shiftKey",sortResetKey:"ctrlKey",usNumberFormat:!0,delayInit:!1,serverSideSorting:!1,headers:{},ignoreCase:!0,sortForce:null,sortList:[],sortAppend:null,sortInitialOrder:"asc",sortLocaleCompare:!1,sortReset:!1,sortRestart:!1,emptyTo:"bottom",stringTo:"max",textExtraction:"simple",textSorter:null,widgets:[],widgetOptions:{zebra:["even","odd"]},initWidgets:!0,initialized:null,tableClass:"tablesorter",cssAsc:"tablesorter-headerAsc",cssChildRow:"tablesorter-childRow",cssDesc:"tablesorter-headerDesc",cssHeader:"tablesorter-header",cssHeaderRow:"tablesorter-headerRow",cssIcon:"tablesorter-icon",cssInfoBlock:"tablesorter-infoOnly",cssProcessing:"tablesorter-processing",selectorHeaders:"> thead th, > thead td",selectorSort:"th, td",selectorRemove:".remove-me",debug:!1,headerList:[],empties:{},strings:{},parsers:[]},w.log=b,w.benchmark=c,w.construct=function(c){return this.each(function(){if(!this.tHead||0===this.tBodies.length||this.hasInitialized===!0)return this.config&&this.config.debug?b("stopping initialization! No thead, tbody or tablesorter has already been initialized"):"";var d,e=a(this),h=this,i="",j=a.metadata;h.hasInitialized=!1,h.isProcessing=!0,h.config={},d=a.extend(!0,h.config,w.defaults,c),a.data(h,"tablesorter",d),d.debug&&a.data(h,"startoveralltimer",new Date),d.supportsTextContent="x"===a("<span>x</span>")[0].textContent,d.supportsDataObject=parseFloat(a.fn.jquery)>=1.4,d.string={max:1,min:-1,"max+":1,"max-":-1,zero:0,none:0,"null":0,top:!0,bottom:!1},/tablesorter\-/.test(e.attr("class"))||(i=""!==d.theme?" tablesorter-"+d.theme:""),d.$table=e.addClass(d.tableClass+i),d.$tbodies=e.children("tbody:not(."+d.cssInfoBlock+")"),k(h),o(h),f(h),d.delayInit||g(h),v(h),d.supportsDataObject&&"undefined"!=typeof e.data().sortlist?d.sortList=e.data().sortlist:j&&e.metadata()&&e.metadata().sortlist&&(d.sortList=e.metadata().sortlist),w.applyWidget(h,!0),d.sortList.length>0?e.trigger("sorton",[d.sortList,{},!d.initWidgets]):d.initWidgets&&w.applyWidget(h),d.showProcessing&&e.unbind("sortBegin.tablesorter sortEnd.tablesorter").bind("sortBegin.tablesorter sortEnd.tablesorter",function(a){w.isProcessing(h,"sortBegin"===a.type) }),h.hasInitialized=!0,h.isProcessing=!1,d.debug&&w.benchmark("Overall initialization time",a.data(h,"startoveralltimer")),e.trigger("tablesorter-initialized",h),"function"==typeof d.initialized&&d.initialized(h)})},w.isProcessing=function(b,c,d){b=a(b);var e=b[0].config,f=d||b.find("."+e.cssHeader);c?(e.sortList.length>0&&(f=f.filter(function(){return this.sortDisabled?!1:w.isValueInArray(parseFloat(a(this).attr("data-column")),e.sortList)})),f.addClass(e.cssProcessing)):f.removeClass(e.cssProcessing)},w.processTbody=function(b,c,d){var e;return d?(b.isProcessing=!0,c.before('<span class="tablesorter-savemyplace"/>'),e=a.fn.detach?c.detach():c.remove()):(e=a(b).find("span.tablesorter-savemyplace"),c.insertAfter(e),e.remove(),void(b.isProcessing=!1))},w.clearTableBody=function(b){a(b)[0].config.$tbodies.empty()},w.restoreHeaders=function(b){var c=b.config;c.$table.find(c.selectorHeaders).each(function(b){a(this).find(".tablesorter-header-inner").length&&a(this).html(c.headerContent[b])})},w.destroy=function(b,c,d){if(b=a(b)[0],b.hasInitialized){w.refreshWidgets(b,!0,!0);var e=a(b),f=b.config,g=e.find("thead:first"),h=g.find("tr."+f.cssHeaderRow).removeClass(f.cssHeaderRow),i=e.find("tfoot:first > tr").children("th, td");g.find("tr").not(h).remove(),e.removeData("tablesorter").unbind("sortReset update updateAll updateRows updateCell addRows sorton appendCache applyWidgetId applyWidgets refreshWidgets destroy mouseup mouseleave keypress sortBegin sortEnd ".split(" ").join(".tablesorter ")),f.$headers.add(i).removeClass(f.cssHeader+" "+f.cssAsc+" "+f.cssDesc).removeAttr("data-column"),h.find(f.selectorSort).unbind("mousedown.tablesorter mouseup.tablesorter keypress.tablesorter"),w.restoreHeaders(b),c!==!1&&e.removeClass(f.tableClass+" tablesorter-"+f.theme),b.hasInitialized=!1,"function"==typeof d&&d(b)}},w.regex=[/(^([+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?)?$|^0x[0-9a-f]+$|\d+)/gi,/(^([\w ]+,?[\w ]+)?[\w ]+,?[\w ]+\d+:\d+(:\d+)?[\w ]?|^\d{1,4}[\/\-]\d{1,4}[\/\-]\d{1,4}|^\w+, \w+ \d+, \d{4})/,/^0x[0-9a-f]+$/i],w.sortText=function(a,b,c,d){if(b===c)return 0;var e,f,g,h,i,j,k,l,m=a.config,n=m.string[m.empties[d]||m.emptyTo],o=w.regex;if(""===b&&0!==n)return"boolean"==typeof n?n?-1:1:-n||-1;if(""===c&&0!==n)return"boolean"==typeof n?n?1:-1:n||1;if("function"==typeof m.textSorter)return m.textSorter(b,c,a,d);if(e=b.replace(o[0],"\\0$1\\0").replace(/\\0$/,"").replace(/^\\0/,"").split("\\0"),g=c.replace(o[0],"\\0$1\\0").replace(/\\0$/,"").replace(/^\\0/,"").split("\\0"),f=parseInt(b.match(o[2]),16)||1!==e.length&&b.match(o[1])&&Date.parse(b),h=parseInt(c.match(o[2]),16)||f&&c.match(o[1])&&Date.parse(c)||null){if(h>f)return-1;if(f>h)return 1}for(l=Math.max(e.length,g.length),k=0;l>k;k++){if(i=isNaN(e[k])?e[k]||0:parseFloat(e[k])||0,j=isNaN(g[k])?g[k]||0:parseFloat(g[k])||0,isNaN(i)!==isNaN(j))return isNaN(i)?1:-1;if(typeof i!=typeof j&&(i+="",j+=""),j>i)return-1;if(i>j)return 1}return 0},w.sortTextDesc=function(a,b,c,d){if(b===c)return 0;var e=a.config,f=e.string[e.empties[d]||e.emptyTo];return""===b&&0!==f?"boolean"==typeof f?f?-1:1:f||1:""===c&&0!==f?"boolean"==typeof f?f?1:-1:-f||-1:"function"==typeof e.textSorter?e.textSorter(c,b,a,d):w.sortText(a,c,b)},w.getTextValue=function(a,b,c){if(b){var d,e=a?a.length:0,f=b+c;for(d=0;e>d;d++)f+=a.charCodeAt(d);return c*f}return 0},w.sortNumeric=function(a,b,c,d,e,f){if(b===c)return 0;var g=a.config,h=g.string[g.empties[d]||g.emptyTo];return""===b&&0!==h?"boolean"==typeof h?h?-1:1:-h||-1:""===c&&0!==h?"boolean"==typeof h?h?1:-1:h||1:(isNaN(b)&&(b=w.getTextValue(b,e,f)),isNaN(c)&&(c=w.getTextValue(c,e,f)),b-c)},w.sortNumericDesc=function(a,b,c,d,e,f){if(b===c)return 0;var g=a.config,h=g.string[g.empties[d]||g.emptyTo];return""===b&&0!==h?"boolean"==typeof h?h?-1:1:h||1:""===c&&0!==h?"boolean"==typeof h?h?1:-1:-h||-1:(isNaN(b)&&(b=w.getTextValue(b,e,f)),isNaN(c)&&(c=w.getTextValue(c,e,f)),c-b)},w.characterEquivalents={a:"\xe1\xe0\xe2\xe3\xe4\u0105\xe5",A:"\xc1\xc0\xc2\xc3\xc4\u0104\xc5",c:"\xe7\u0107\u010d",C:"\xc7\u0106\u010c",e:"\xe9\xe8\xea\xeb\u011b\u0119",E:"\xc9\xc8\xca\xcb\u011a\u0118",i:"\xed\xec\u0130\xee\xef\u0131",I:"\xcd\xcc\u0130\xce\xcf",o:"\xf3\xf2\xf4\xf5\xf6",O:"\xd3\xd2\xd4\xd5\xd6",ss:"\xdf",SS:"\u1e9e",u:"\xfa\xf9\xfb\xfc\u016f",U:"\xda\xd9\xdb\xdc\u016e"},w.replaceAccents=function(a){var b,c="[",d=w.characterEquivalents;if(!w.characterRegex){w.characterRegexArray={};for(b in d)"string"==typeof b&&(c+=d[b],w.characterRegexArray[b]=new RegExp("["+d[b]+"]","g"));w.characterRegex=new RegExp(c+"]")}if(w.characterRegex.test(a))for(b in d)"string"==typeof b&&(a=a.replace(w.characterRegexArray[b],b));return a},w.isValueInArray=function(a,b){var c,d=b.length;for(c=0;d>c;c++)if(b[c][0]===a)return!0;return!1},w.addParser=function(a){var b,c=w.parsers.length,d=!0;for(b=0;c>b;b++)w.parsers[b].id.toLowerCase()===a.id.toLowerCase()&&(d=!1);d&&w.parsers.push(a)},w.getParserById=function(a){var b,c=w.parsers.length;for(b=0;c>b;b++)if(w.parsers[b].id.toLowerCase()===a.toString().toLowerCase())return w.parsers[b];return!1},w.addWidget=function(a){w.widgets.push(a)},w.getWidgetById=function(a){var b,c,d=w.widgets.length;for(b=0;d>b;b++)if(c=w.widgets[b],c&&c.hasOwnProperty("id")&&c.id.toLowerCase()===a.toLowerCase())return c},w.applyWidget=function(b,d){b=a(b)[0];var e,f,g,h=b.config,i=h.widgetOptions,j=[];h.debug&&(e=new Date),h.widgets.length&&(h.widgets=a.grep(h.widgets,function(b,c){return a.inArray(b,h.widgets)===c}),a.each(h.widgets||[],function(a,b){g=w.getWidgetById(b),g&&g.id&&(g.priority||(g.priority=10),j[a]=g)}),j.sort(function(a,b){return a.priority<b.priority?-1:a.priority===b.priority?0:1}),a.each(j,function(c,e){e&&(d?(e.hasOwnProperty("options")&&(i=b.config.widgetOptions=a.extend(!0,{},e.options,i)),e.hasOwnProperty("init")&&e.init(b,e,h,i)):!d&&e.hasOwnProperty("format")&&e.format(b,h,i,!1))})),h.debug&&(f=h.widgets.length,c("Completed "+(d===!0?"initializing ":"applying ")+f+" widget"+(1!==f?"s":""),e))},w.refreshWidgets=function(c,d,e){c=a(c)[0];var f,g=c.config,h=g.widgets,i=w.widgets,j=i.length;for(f=0;j>f;f++)i[f]&&i[f].id&&(d||a.inArray(i[f].id,h)<0)&&(g.debug&&b("Refeshing widgets: Removing "+i[f].id),i[f].hasOwnProperty("remove")&&i[f].remove(c,g,g.widgetOptions));e!==!0&&w.applyWidget(c,d)},w.getData=function(b,c,d){var e,f,g="",h=a(b);return h.length?(e=a.metadata?h.metadata():!1,f=" "+(h.attr("class")||""),"undefined"!=typeof h.data(d)||"undefined"!=typeof h.data(d.toLowerCase())?g+=h.data(d)||h.data(d.toLowerCase()):e&&"undefined"!=typeof e[d]?g+=e[d]:c&&"undefined"!=typeof c[d]?g+=c[d]:" "!==f&&f.match(" "+d+"-")&&(g=f.match(new RegExp("\\s"+d+"-([\\w-]+)"))[1]||""),a.trim(g)):""},w.formatFloat=function(b,c){if("string"!=typeof b||""===b)return b;var d,e=c&&c.config?c.config.usNumberFormat!==!1:"undefined"!=typeof c?c:!0;return b=e?b.replace(/,/g,""):b.replace(/[\s|\.]/g,"").replace(/,/g,"."),/^\s*\([.\d]+\)/.test(b)&&(b=b.replace(/^\s*\(/,"-").replace(/\)/,"")),d=parseFloat(b),isNaN(d)?a.trim(b):d},w.isDigit=function(a){return isNaN(a)?/^[\-+(]?\d+[)]?$/.test(a.toString().replace(/[,.'"\s]/g,"")):!0}}});var b=a.tablesorter;a.fn.extend({tablesorter:b.construct}),b.addParser({id:"text",is:function(){return!0},format:function(c,d){var e=d.config;return c&&(c=a.trim(e.ignoreCase?c.toLocaleLowerCase():c),c=e.sortLocaleCompare?b.replaceAccents(c):c),c},type:"text"}),b.addParser({id:"digit",is:function(a){return b.isDigit(a)},format:function(c,d){var e=b.formatFloat((c||"").replace(/[^\w,. \-()]/g,""),d);return c&&"number"==typeof e?e:c?a.trim(c&&d.config.ignoreCase?c.toLocaleLowerCase():c):c},type:"numeric"}),b.addParser({id:"currency",is:function(a){return/^\(?\d+[\u00a3$\u20ac\u00a4\u00a5\u00a2?.]|[\u00a3$\u20ac\u00a4\u00a5\u00a2?.]\d+\)?$/.test((a||"").replace(/[,. ]/g,""))},format:function(c,d){var e=b.formatFloat((c||"").replace(/[^\w,. \-()]/g,""),d);return c&&"number"==typeof e?e:c?a.trim(c&&d.config.ignoreCase?c.toLocaleLowerCase():c):c},type:"numeric"}),b.addParser({id:"ipAddress",is:function(a){return/^\d{1,3}[\.]\d{1,3}[\.]\d{1,3}[\.]\d{1,3}$/.test(a)},format:function(a,c){var d,e=a?a.split("."):"",f="",g=e.length;for(d=0;g>d;d++)f+=("00"+e[d]).slice(-3);return a?b.formatFloat(f,c):a},type:"numeric"}),b.addParser({id:"url",is:function(a){return/^(https?|ftp|file):\/\//.test(a)},format:function(b){return b?a.trim(b.replace(/(https?|ftp|file):\/\//,"")):b},type:"text"}),b.addParser({id:"isoDate",is:function(a){return/^\d{4}[\/\-]\d{1,2}[\/\-]\d{1,2}/.test(a)},format:function(a,c){return a?b.formatFloat(""!==a?new Date(a.replace(/-/g,"/")).getTime()||"":"",c):a},type:"numeric"}),b.addParser({id:"percent",is:function(a){return/(\d\s*?%|%\s*?\d)/.test(a)&&a.length<15},format:function(a,c){return a?b.formatFloat(a.replace(/%/g,""),c):a},type:"numeric"}),b.addParser({id:"usLongDate",is:function(a){return/^[A-Z]{3,10}\.?\s+\d{1,2},?\s+(\d{4})(\s+\d{1,2}:\d{2}(:\d{2})?(\s+[AP]M)?)?$/i.test(a)||/^\d{1,2}\s+[A-Z]{3,10}\s+\d{4}/i.test(a)},format:function(a,c){return a?b.formatFloat(new Date(a.replace(/(\S)([AP]M)$/i,"$1 $2")).getTime()||"",c):a},type:"numeric"}),b.addParser({id:"shortDate",is:function(a){return/(^\d{1,2}[\/\s]\d{1,2}[\/\s]\d{4})|(^\d{4}[\/\s]\d{1,2}[\/\s]\d{1,2})/.test((a||"").replace(/\s+/g," ").replace(/[\-.,]/g,"/"))},format:function(a,c,d,e){if(a){var f=c.config,g=f.headerList[e],h=g.dateFormat||b.getData(g,f.headers[e],"dateFormat")||f.dateFormat;a=a.replace(/\s+/g," ").replace(/[\-.,]/g,"/"),"mmddyyyy"===h?a=a.replace(/(\d{1,2})[\/\s](\d{1,2})[\/\s](\d{4})/,"$3/$1/$2"):"ddmmyyyy"===h?a=a.replace(/(\d{1,2})[\/\s](\d{1,2})[\/\s](\d{4})/,"$3/$2/$1"):"yyyymmdd"===h&&(a=a.replace(/(\d{4})[\/\s](\d{1,2})[\/\s](\d{1,2})/,"$1/$2/$3"))}return a?b.formatFloat(new Date(a).getTime()||"",c):a},type:"numeric"}),b.addParser({id:"time",is:function(a){return/^(([0-2]?\d:[0-5]\d)|([0-1]?\d:[0-5]\d\s?([AP]M)))$/i.test(a)},format:function(a,c){return a?b.formatFloat(new Date("2000/01/01 "+a.replace(/(\S)([AP]M)$/i,"$1 $2")).getTime()||"",c):a},type:"numeric"}),b.addParser({id:"metadata",is:function(){return!1},format:function(b,c,d){var e=c.config,f=e.parserMetadataName?e.parserMetadataName:"sortValue";return a(d).metadata()[f]},type:"numeric"}),b.addWidget({id:"zebra",priority:90,format:function(c,d,e){var f,g,h,i,j,k,l,m,n=new RegExp(d.cssChildRow,"i"),o=d.$tbodies;for(d.debug&&(k=new Date),l=0;l<o.length;l++)f=o.eq(l),m=f.children("tr").length,m>1&&(i=0,g=f.children("tr:visible"),g.each(function(){h=a(this),n.test(this.className)||i++,j=i%2===0,h.removeClass(e.zebra[j?1:0]).addClass(e.zebra[j?0:1])}));d.debug&&b.benchmark("Applying Zebra widget",k)},remove:function(b,c,d){var e,f,g=c.$tbodies,h=(d.zebra||["even","odd"]).join(" ");for(e=0;e<g.length;e++)f=a.tablesorter.processTbody(b,g.eq(e),!0),f.children().removeClass(h),a.tablesorter.processTbody(b,f,!1)}})}(jQuery),!function(a,b,c){function d(a,c){var d,e=b.createElement(a||"div");for(d in c)e[d]=c[d];return e}function e(a){for(var b=1,c=arguments.length;c>b;b++)a.appendChild(arguments[b]);return a}function f(a,b,c,d){var e=["opacity",b,~~(100*a),c,d].join("-"),f=.01+c/d*100,g=Math.max(1-(1-a)/b*(100-f),a),h=k.substring(0,k.indexOf("Animation")).toLowerCase(),i=h&&"-"+h+"-"||"";return m[e]||(n.insertRule("@"+i+"keyframes "+e+"{0%{opacity:"+g+"}"+f+"%{opacity:"+a+"}"+(f+.01)+"%{opacity:1}"+(f+b)%100+"%{opacity:"+a+"}100%{opacity:"+g+"}}",n.cssRules.length),m[e]=1),e}function g(a,b){var d,e,f=a.style;if(f[b]!==c)return b;for(b=b.charAt(0).toUpperCase()+b.slice(1),e=0;e<l.length;e++)if(d=l[e]+b,f[d]!==c)return d}function h(a,b){for(var c in b)a.style[g(a,c)||c]=b[c];return a}function i(a){for(var b=1;b<arguments.length;b++){var d=arguments[b];for(var e in d)a[e]===c&&(a[e]=d[e])}return a}function j(a){for(var b={x:a.offsetLeft,y:a.offsetTop};a=a.offsetParent;)b.x+=a.offsetLeft,b.y+=a.offsetTop;return b}var k,l=["webkit","Moz","ms","O"],m={},n=function(){var a=d("style",{type:"text/css"});return e(b.getElementsByTagName("head")[0],a),a.sheet||a.styleSheet}(),o={lines:12,length:7,width:5,radius:10,rotate:0,corners:1,color:"#000",speed:1,trail:100,opacity:.25,fps:20,zIndex:2e9,className:"spinner",top:"auto",left:"auto",position:"relative"},p=function q(a){return this.spin?void(this.opts=i(a||{},q.defaults,o)):new q(a)};p.defaults={},i(p.prototype,{spin:function(a){this.stop();var b,c,e=this,f=e.opts,g=e.el=h(d(0,{className:f.className}),{position:f.position,width:0,zIndex:f.zIndex}),i=f.radius+f.length+f.width;if(a&&(a.insertBefore(g,a.firstChild||null),c=j(a),b=j(g),h(g,{left:("auto"==f.left?c.x-b.x+(a.offsetWidth>>1):parseInt(f.left,10)+i)+"px",top:("auto"==f.top?c.y-b.y+(a.offsetHeight>>1):parseInt(f.top,10)+i)+"px"})),g.setAttribute("aria-role","progressbar"),e.lines(g,e.opts),!k){var l=0,m=f.fps,n=m/f.speed,o=(1-f.opacity)/(n*f.trail/100),p=n/f.lines;!function q(){l++;for(var a=f.lines;a;a--){var b=Math.max(1-(l+a*p)%n*o,f.opacity);e.opacity(g,f.lines-a,b,f)}e.timeout=e.el&&setTimeout(q,~~(1e3/m))}()}return e},stop:function(){var a=this.el;return a&&(clearTimeout(this.timeout),a.parentNode&&a.parentNode.removeChild(a),this.el=c),this},lines:function(a,b){function c(a,c){return h(d(),{position:"absolute",width:b.length+b.width+"px",height:b.width+"px",background:a,boxShadow:c,transformOrigin:"left",transform:"rotate("+~~(360/b.lines*i+b.rotate)+"deg) translate("+b.radius+"px,0)",borderRadius:(b.corners*b.width>>1)+"px"})}for(var g,i=0;i<b.lines;i++)g=h(d(),{position:"absolute",top:1+~(b.width/2)+"px",transform:b.hwaccel?"translate3d(0,0,0)":"",opacity:b.opacity,animation:k&&f(b.opacity,b.trail,i,b.lines)+" "+1/b.speed+"s linear infinite"}),b.shadow&&e(g,h(c("#000","0 0 4px #000"),{top:"2px"})),e(a,e(g,c(b.color,"0 0 1px rgba(0,0,0,.1)")));return a},opacity:function(a,b,c){b<a.childNodes.length&&(a.childNodes[b].style.opacity=c)}}),function(){function a(a,b){return d("<"+a+' xmlns="urn:schemas-microsoft.com:vml" class="spin-vml">',b)}var b=h(d("group"),{behavior:"url(#default#VML)"});!g(b,"transform")&&b.adj?(n.addRule(".spin-vml","behavior:url(#default#VML)"),p.prototype.lines=function(b,c){function d(){return h(a("group",{coordsize:j+" "+j,coordorigin:-i+" "+-i}),{width:j,height:j})}function f(b,f,g){e(l,e(h(d(),{rotation:360/c.lines*b+"deg",left:~~f}),e(h(a("roundrect",{arcsize:c.corners}),{width:i,height:c.width,left:c.radius,top:-c.width>>1,filter:g}),a("fill",{color:c.color,opacity:c.opacity}),a("stroke",{opacity:0}))))}var g,i=c.length+c.width,j=2*i,k=2*-(c.width+c.length)+"px",l=h(d(),{position:"absolute",top:k,left:k});if(c.shadow)for(g=1;g<=c.lines;g++)f(g,-2,"progid:DXImageTransform.Microsoft.Blur(pixelradius=2,makeshadow=1,shadowopacity=.3)");for(g=1;g<=c.lines;g++)f(g);return e(b,l)},p.prototype.opacity=function(a,b,c,d){var e=a.firstChild;d=d.shadow&&d.lines||0,e&&b+d<e.childNodes.length&&(e=e.childNodes[b+d],e=e&&e.firstChild,e=e&&e.firstChild,e&&(e.opacity=c))}):k=g(b,"animation")}(),"function"==typeof define&&define.amd?define(function(){return p}):a.Spinner=p}(window,document),function(a){a.fn.spin=function(b,c){var d,e;if("string"==typeof b){if(!b in a.fn.spin.presets)throw new Error("Preset '"+b+"' isn't defined");d=a.fn.spin.presets[b],e=c||{}}else{if(c)throw new Error("Invalid arguments. Accepted arguments:\n$.spin([String preset[, Object options]]),\n$.spin(Object options),\n$.spin(Boolean shouldSpin)");d=a.fn.spin.presets.small,e=a.isPlainObject(b)?b:{}}if(window.Spinner)return this.each(function(){var c=a(this),f=c.data();f.spinner&&(f.spinner.stop(),delete f.spinner),b!==!1&&(e=a.extend({color:c.css("color")},d,e),f.spinner=new Spinner(e).spin(this))});throw"Spinner class not available."},a.fn.spin.presets={small:{lines:12,length:3,width:2,radius:3,trail:60,speed:1.5},medium:{lines:12,length:5,width:3,radius:8,trail:60,speed:1.5},large:{lines:12,length:8,width:4,radius:10,trail:60,speed:1.5}},a.fn.spinStop=function(){if(window.Spinner)return this.each(function(){var b=a(this),c=b.data();c.spinner&&(c.spinner.stop(),delete c.spinner)});throw"Spinner class not available."}}(jQuery),function(a){"undefined"==typeof a.fn.each2&&a.extend(a.fn,{each2:function(b){for(var c=a([0]),d=-1,e=this.length;++d<e&&(c.context=c[0]=this[d])&&b.call(c[0],d,c)!==!1;);return this}})}(jQuery),function(a,b){"use strict";function c(a){var b,c,d,e;if(!a||a.length<1)return a;for(b="",c=0,d=a.length;d>c;c++)e=a.charAt(c),b+=N[e]||e;return b}function d(a,b){for(var c=0,d=b.length;d>c;c+=1)if(f(a,b[c]))return c;return-1}function e(){var b=a(M);b.appendTo("body");var c={width:b.width()-b[0].clientWidth,height:b.height()-b[0].clientHeight};return b.remove(),c}function f(a,c){return a===c?!0:a===b||c===b?!1:null===a||null===c?!1:a.constructor===String?a+""==c+"":c.constructor===String?c+""==a+"":!1}function g(b,c){var d,e,f;if(null===b||b.length<1)return[];for(d=b.split(c),e=0,f=d.length;f>e;e+=1)d[e]=a.trim(d[e]);return d}function h(a){return a.outerWidth(!1)-a.width()}function i(c){var d="keyup-change-value";c.on("keydown",function(){a.data(c,d)===b&&a.data(c,d,c.val())}),c.on("keyup",function(){var e=a.data(c,d);e!==b&&c.val()!==e&&(a.removeData(c,d),c.trigger("keyup-change"))})}function j(c){c.on("mousemove",function(c){var d=L;(d===b||d.x!==c.pageX||d.y!==c.pageY)&&a(c.target).trigger("mousemove-filtered",c)})}function k(a,c,d){d=d||b;var e;return function(){var b=arguments;window.clearTimeout(e),e=window.setTimeout(function(){c.apply(d,b)},a)}}function l(a){var b,c=!1;return function(){return c===!1&&(b=a(),c=!0),b}}function m(a,b){var c=k(a,function(a){b.trigger("scroll-debounced",a)});b.on("scroll",function(a){d(a.target,b.get())>=0&&c(a)})}function n(a){a[0]!==document.activeElement&&window.setTimeout(function(){var b,c=a[0],d=a.val().length;a.focus(),a.is(":visible")&&c===document.activeElement&&(c.setSelectionRange?c.setSelectionRange(d,d):c.createTextRange&&(b=c.createTextRange(),b.collapse(!1),b.select()))},0)}function o(b){b=a(b)[0];var c=0,d=0;if("selectionStart"in b)c=b.selectionStart,d=b.selectionEnd-c;else if("selection"in document){b.focus();var e=document.selection.createRange();d=document.selection.createRange().text.length,e.moveStart("character",-b.value.length),c=e.text.length-d}return{offset:c,length:d}}function p(a){a.preventDefault(),a.stopPropagation()}function q(a){a.preventDefault(),a.stopImmediatePropagation()}function r(b){if(!I){var c=b[0].currentStyle||window.getComputedStyle(b[0],null);I=a(document.createElement("div")).css({position:"absolute",left:"-10000px",top:"-10000px",display:"none",fontSize:c.fontSize,fontFamily:c.fontFamily,fontStyle:c.fontStyle,fontWeight:c.fontWeight,letterSpacing:c.letterSpacing,textTransform:c.textTransform,whiteSpace:"nowrap"}),I.attr("class","select2-sizer"),a("body").append(I)}return I.text(b.val()),I.width()}function s(b,c,d){var e,f,g=[];e=b.attr("class"),e&&(e=""+e,a(e.split(" ")).each2(function(){0===this.indexOf("select2-")&&g.push(this)})),e=c.attr("class"),e&&(e=""+e,a(e.split(" ")).each2(function(){0!==this.indexOf("select2-")&&(f=d(this),f&&g.push(f))})),b.attr("class",g.join(" "))}function t(a,b,d,e){var f=c(a.toUpperCase()).indexOf(c(b.toUpperCase())),g=b.length;return 0>f?void d.push(e(a)):(d.push(e(a.substring(0,f))),d.push("<span class='select2-match'>"),d.push(e(a.substring(f,f+g))),d.push("</span>"),void d.push(e(a.substring(f+g,a.length))))}function u(a){var b={"\\":"&#92;","&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;","/":"&#47;"};return String(a).replace(/[&<>"'\/\\]/g,function(a){return b[a]})}function v(c){var d,e=null,f=c.quietMillis||100,g=c.url,h=this;return function(i){window.clearTimeout(d),d=window.setTimeout(function(){var d=c.data,f=g,j=c.transport||a.fn.select2.ajaxDefaults.transport,k={type:c.type||"GET",cache:c.cache||!1,jsonpCallback:c.jsonpCallback||b,dataType:c.dataType||"json"},l=a.extend({},a.fn.select2.ajaxDefaults.params,k);d=d?d.call(h,i.term,i.page,i.context):null,f="function"==typeof f?f.call(h,i.term,i.page,i.context):f,e&&e.abort(),c.params&&(a.isFunction(c.params)?a.extend(l,c.params.call(h)):a.extend(l,c.params)),a.extend(l,{url:f,dataType:c.dataType,data:d,success:function(a){var b=c.results(a,i.page);i.callback(b)}}),e=j.call(h,l)},f)}}function w(b){var c,d,e=b,f=function(a){return""+a.text};a.isArray(e)&&(d=e,e={results:d}),a.isFunction(e)===!1&&(d=e,e=function(){return d});var g=e();return g.text&&(f=g.text,a.isFunction(f)||(c=g.text,f=function(a){return a[c]})),function(b){var c,d=b.term,g={results:[]};return""===d?void b.callback(e()):(c=function(e,g){var h,i;if(e=e[0],e.children){h={};for(i in e)e.hasOwnProperty(i)&&(h[i]=e[i]);h.children=[],a(e.children).each2(function(a,b){c(b,h.children)}),(h.children.length||b.matcher(d,f(h),e))&&g.push(h)}else b.matcher(d,f(e),e)&&g.push(e)},a(e().results).each2(function(a,b){c(b,g.results)}),void b.callback(g))}}function x(c){var d=a.isFunction(c);return function(e){var f=e.term,g={results:[]};a(d?c():c).each(function(){var a=this.text!==b,c=a?this.text:this;(""===f||e.matcher(f,c))&&g.results.push(a?this:{id:this,text:this})}),e.callback(g)}}function y(b,c){if(a.isFunction(b))return!0;if(!b)return!1;throw new Error(c+" must be a function or a falsy value")}function z(b){return a.isFunction(b)?b():b}function A(b){var c=0;return a.each(b,function(a,b){b.children?c+=A(b.children):c++}),c}function B(a,c,d,e){var g,h,i,j,k,l=a,m=!1;if(!e.createSearchChoice||!e.tokenSeparators||e.tokenSeparators.length<1)return b;for(;;){for(h=-1,i=0,j=e.tokenSeparators.length;j>i&&(k=e.tokenSeparators[i],h=a.indexOf(k),!(h>=0));i++);if(0>h)break;if(g=a.substring(0,h),a=a.substring(h+k.length),g.length>0&&(g=e.createSearchChoice.call(this,g,c),g!==b&&null!==g&&e.id(g)!==b&&null!==e.id(g))){for(m=!1,i=0,j=c.length;j>i;i++)if(f(e.id(g),e.id(c[i]))){m=!0;break}m||d(g)}}return l!==a?a:void 0}function C(b,c){var d=function(){};return d.prototype=new b,d.prototype.constructor=d,d.prototype.parent=b.prototype,d.prototype=a.extend(d.prototype,c),d}if(window.Select2===b){var D,E,F,G,H,I,J,K,L={x:0,y:0},D={TAB:9,ENTER:13,ESC:27,SPACE:32,LEFT:37,UP:38,RIGHT:39,DOWN:40,SHIFT:16,CTRL:17,ALT:18,PAGE_UP:33,PAGE_DOWN:34,HOME:36,END:35,BACKSPACE:8,DELETE:46,isArrow:function(a){switch(a=a.which?a.which:a){case D.LEFT:case D.RIGHT:case D.UP:case D.DOWN:return!0}return!1},isControl:function(a){var b=a.which;switch(b){case D.SHIFT:case D.CTRL:case D.ALT:return!0}return a.metaKey?!0:!1},isFunctionKey:function(a){return a=a.which?a.which:a,a>=112&&123>=a}},M="<div class='select2-measure-scrollbar'></div>",N={"\u24b6":"A",\uff21:"A",\u00c0:"A",\u00c1:"A",\u00c2:"A",\u1ea6:"A",\u1ea4:"A",\u1eaa:"A",\u1ea8:"A",\u00c3:"A",\u0100:"A",\u0102:"A",\u1eb0:"A",\u1eae:"A",\u1eb4:"A",\u1eb2:"A",\u0226:"A",\u01e0:"A",\u00c4:"A",\u01de:"A",\u1ea2:"A",\u00c5:"A",\u01fa:"A",\u01cd:"A",\u0200:"A",\u0202:"A",\u1ea0:"A",\u1eac:"A",\u1eb6:"A",\u1e00:"A",\u0104:"A",\u023a:"A",\u2c6f:"A",\ua732:"AA",\u00c6:"AE",\u01fc:"AE",\u01e2:"AE",\ua734:"AO",\ua736:"AU",\ua738:"AV",\ua73a:"AV",\ua73c:"AY","\u24b7":"B",\uff22:"B",\u1e02:"B",\u1e04:"B",\u1e06:"B",\u0243:"B",\u0182:"B",\u0181:"B","\u24b8":"C",\uff23:"C",\u0106:"C",\u0108:"C",\u010a:"C",\u010c:"C",\u00c7:"C",\u1e08:"C",\u0187:"C",\u023b:"C",\ua73e:"C","\u24b9":"D",\uff24:"D",\u1e0a:"D",\u010e:"D",\u1e0c:"D",\u1e10:"D",\u1e12:"D",\u1e0e:"D",\u0110:"D",\u018b:"D",\u018a:"D",\u0189:"D",\ua779:"D",\u01f1:"DZ",\u01c4:"DZ",\u01f2:"Dz",\u01c5:"Dz","\u24ba":"E",\uff25:"E",\u00c8:"E",\u00c9:"E",\u00ca:"E",\u1ec0:"E",\u1ebe:"E",\u1ec4:"E",\u1ec2:"E",\u1ebc:"E",\u0112:"E",\u1e14:"E",\u1e16:"E",\u0114:"E",\u0116:"E",\u00cb:"E",\u1eba:"E",\u011a:"E",\u0204:"E",\u0206:"E",\u1eb8:"E",\u1ec6:"E",\u0228:"E",\u1e1c:"E",\u0118:"E",\u1e18:"E",\u1e1a:"E",\u0190:"E",\u018e:"E","\u24bb":"F",\uff26:"F",\u1e1e:"F",\u0191:"F",\ua77b:"F","\u24bc":"G",\uff27:"G",\u01f4:"G",\u011c:"G",\u1e20:"G",\u011e:"G",\u0120:"G",\u01e6:"G",\u0122:"G",\u01e4:"G",\u0193:"G","\ua7a0":"G",\ua77d:"G",\ua77e:"G","\u24bd":"H",\uff28:"H",\u0124:"H",\u1e22:"H",\u1e26:"H",\u021e:"H",\u1e24:"H",\u1e28:"H",\u1e2a:"H",\u0126:"H",\u2c67:"H",\u2c75:"H","\ua78d":"H","\u24be":"I",\uff29:"I",\u00cc:"I",\u00cd:"I",\u00ce:"I",\u0128:"I",\u012a:"I",\u012c:"I",\u0130:"I",\u00cf:"I",\u1e2e:"I",\u1ec8:"I",\u01cf:"I",\u0208:"I",\u020a:"I",\u1eca:"I",\u012e:"I",\u1e2c:"I",\u0197:"I","\u24bf":"J",\uff2a:"J",\u0134:"J",\u0248:"J","\u24c0":"K",\uff2b:"K",\u1e30:"K",\u01e8:"K",\u1e32:"K",\u0136:"K",\u1e34:"K",\u0198:"K",\u2c69:"K",\ua740:"K",\ua742:"K",\ua744:"K","\ua7a2":"K","\u24c1":"L",\uff2c:"L",\u013f:"L",\u0139:"L",\u013d:"L",\u1e36:"L",\u1e38:"L",\u013b:"L",\u1e3c:"L",\u1e3a:"L",\u0141:"L",\u023d:"L",\u2c62:"L",\u2c60:"L",\ua748:"L",\ua746:"L",\ua780:"L",\u01c7:"LJ",\u01c8:"Lj","\u24c2":"M",\uff2d:"M",\u1e3e:"M",\u1e40:"M",\u1e42:"M",\u2c6e:"M",\u019c:"M","\u24c3":"N",\uff2e:"N",\u01f8:"N",\u0143:"N",\u00d1:"N",\u1e44:"N",\u0147:"N",\u1e46:"N",\u0145:"N",\u1e4a:"N",\u1e48:"N",\u0220:"N",\u019d:"N","\ua790":"N","\ua7a4":"N",\u01ca:"NJ",\u01cb:"Nj","\u24c4":"O",\uff2f:"O",\u00d2:"O",\u00d3:"O",\u00d4:"O",\u1ed2:"O",\u1ed0:"O",\u1ed6:"O",\u1ed4:"O",\u00d5:"O",\u1e4c:"O",\u022c:"O",\u1e4e:"O",\u014c:"O",\u1e50:"O",\u1e52:"O",\u014e:"O",\u022e:"O",\u0230:"O",\u00d6:"O",\u022a:"O",\u1ece:"O",\u0150:"O",\u01d1:"O",\u020c:"O",\u020e:"O",\u01a0:"O",\u1edc:"O",\u1eda:"O",\u1ee0:"O",\u1ede:"O",\u1ee2:"O",\u1ecc:"O",\u1ed8:"O",\u01ea:"O",\u01ec:"O",\u00d8:"O",\u01fe:"O",\u0186:"O",\u019f:"O",\ua74a:"O",\ua74c:"O",\u01a2:"OI",\ua74e:"OO",\u0222:"OU","\u24c5":"P",\uff30:"P",\u1e54:"P",\u1e56:"P",\u01a4:"P",\u2c63:"P",\ua750:"P",\ua752:"P",\ua754:"P","\u24c6":"Q",\uff31:"Q",\ua756:"Q",\ua758:"Q",\u024a:"Q","\u24c7":"R",\uff32:"R",\u0154:"R",\u1e58:"R",\u0158:"R",\u0210:"R",\u0212:"R",\u1e5a:"R",\u1e5c:"R",\u0156:"R",\u1e5e:"R",\u024c:"R",\u2c64:"R",\ua75a:"R","\ua7a6":"R",\ua782:"R","\u24c8":"S",\uff33:"S",\u1e9e:"S",\u015a:"S",\u1e64:"S",\u015c:"S",\u1e60:"S",\u0160:"S",\u1e66:"S",\u1e62:"S",\u1e68:"S",\u0218:"S",\u015e:"S","\u2c7e":"S","\ua7a8":"S",\ua784:"S","\u24c9":"T",\uff34:"T",\u1e6a:"T",\u0164:"T",\u1e6c:"T",\u021a:"T",\u0162:"T",\u1e70:"T",\u1e6e:"T",\u0166:"T",\u01ac:"T",\u01ae:"T",\u023e:"T",\ua786:"T",\ua728:"TZ","\u24ca":"U",\uff35:"U",\u00d9:"U",\u00da:"U",\u00db:"U",\u0168:"U",\u1e78:"U",\u016a:"U",\u1e7a:"U",\u016c:"U",\u00dc:"U",\u01db:"U",\u01d7:"U",\u01d5:"U",\u01d9:"U",\u1ee6:"U",\u016e:"U",\u0170:"U",\u01d3:"U",\u0214:"U",\u0216:"U",\u01af:"U",\u1eea:"U",\u1ee8:"U",\u1eee:"U",\u1eec:"U",\u1ef0:"U",\u1ee4:"U",\u1e72:"U",\u0172:"U",\u1e76:"U",\u1e74:"U",\u0244:"U","\u24cb":"V",\uff36:"V",\u1e7c:"V",\u1e7e:"V",\u01b2:"V",\ua75e:"V",\u0245:"V",\ua760:"VY","\u24cc":"W",\uff37:"W",\u1e80:"W",\u1e82:"W",\u0174:"W",\u1e86:"W",\u1e84:"W",\u1e88:"W",\u2c72:"W","\u24cd":"X",\uff38:"X",\u1e8a:"X",\u1e8c:"X","\u24ce":"Y",\uff39:"Y",\u1ef2:"Y",\u00dd:"Y",\u0176:"Y",\u1ef8:"Y",\u0232:"Y",\u1e8e:"Y",\u0178:"Y",\u1ef6:"Y",\u1ef4:"Y",\u01b3:"Y",\u024e:"Y",\u1efe:"Y","\u24cf":"Z",\uff3a:"Z",\u0179:"Z",\u1e90:"Z",\u017b:"Z",\u017d:"Z",\u1e92:"Z",\u1e94:"Z",\u01b5:"Z",\u0224:"Z","\u2c7f":"Z",\u2c6b:"Z",\ua762:"Z","\u24d0":"a",\uff41:"a",\u1e9a:"a",\u00e0:"a",\u00e1:"a",\u00e2:"a",\u1ea7:"a",\u1ea5:"a",\u1eab:"a",\u1ea9:"a",\u00e3:"a",\u0101:"a",\u0103:"a",\u1eb1:"a",\u1eaf:"a",\u1eb5:"a",\u1eb3:"a",\u0227:"a",\u01e1:"a",\u00e4:"a",\u01df:"a",\u1ea3:"a",\u00e5:"a",\u01fb:"a",\u01ce:"a",\u0201:"a",\u0203:"a",\u1ea1:"a",\u1ead:"a",\u1eb7:"a",\u1e01:"a",\u0105:"a",\u2c65:"a",\u0250:"a",\ua733:"aa",\u00e6:"ae",\u01fd:"ae",\u01e3:"ae",\ua735:"ao",\ua737:"au",\ua739:"av",\ua73b:"av",\ua73d:"ay","\u24d1":"b",\uff42:"b",\u1e03:"b",\u1e05:"b",\u1e07:"b",\u0180:"b",\u0183:"b",\u0253:"b","\u24d2":"c",\uff43:"c",\u0107:"c",\u0109:"c",\u010b:"c",\u010d:"c",\u00e7:"c",\u1e09:"c",\u0188:"c",\u023c:"c",\ua73f:"c",\u2184:"c","\u24d3":"d",\uff44:"d",\u1e0b:"d",\u010f:"d",\u1e0d:"d",\u1e11:"d",\u1e13:"d",\u1e0f:"d",\u0111:"d",\u018c:"d",\u0256:"d",\u0257:"d",\ua77a:"d",\u01f3:"dz",\u01c6:"dz","\u24d4":"e",\uff45:"e",\u00e8:"e",\u00e9:"e",\u00ea:"e",\u1ec1:"e",\u1ebf:"e",\u1ec5:"e",\u1ec3:"e",\u1ebd:"e",\u0113:"e",\u1e15:"e",\u1e17:"e",\u0115:"e",\u0117:"e",\u00eb:"e",\u1ebb:"e",\u011b:"e",\u0205:"e",\u0207:"e",\u1eb9:"e",\u1ec7:"e",\u0229:"e",\u1e1d:"e",\u0119:"e",\u1e19:"e",\u1e1b:"e",\u0247:"e",\u025b:"e",\u01dd:"e","\u24d5":"f",\uff46:"f",\u1e1f:"f",\u0192:"f",\ua77c:"f","\u24d6":"g",\uff47:"g",\u01f5:"g",\u011d:"g",\u1e21:"g",\u011f:"g",\u0121:"g",\u01e7:"g",\u0123:"g",\u01e5:"g",\u0260:"g","\ua7a1":"g",\u1d79:"g",\ua77f:"g","\u24d7":"h",\uff48:"h",\u0125:"h",\u1e23:"h",\u1e27:"h",\u021f:"h",\u1e25:"h",\u1e29:"h",\u1e2b:"h",\u1e96:"h",\u0127:"h",\u2c68:"h",\u2c76:"h",\u0265:"h",\u0195:"hv","\u24d8":"i",\uff49:"i",\u00ec:"i",\u00ed:"i",\u00ee:"i",\u0129:"i",\u012b:"i",\u012d:"i",\u00ef:"i",\u1e2f:"i",\u1ec9:"i",\u01d0:"i",\u0209:"i",\u020b:"i",\u1ecb:"i",\u012f:"i",\u1e2d:"i",\u0268:"i",\u0131:"i","\u24d9":"j",\uff4a:"j",\u0135:"j",\u01f0:"j",\u0249:"j","\u24da":"k",\uff4b:"k",\u1e31:"k",\u01e9:"k",\u1e33:"k",\u0137:"k",\u1e35:"k",\u0199:"k",\u2c6a:"k",\ua741:"k",\ua743:"k",\ua745:"k","\ua7a3":"k","\u24db":"l",\uff4c:"l",\u0140:"l",\u013a:"l",\u013e:"l",\u1e37:"l",\u1e39:"l",\u013c:"l",\u1e3d:"l",\u1e3b:"l",\u017f:"l",\u0142:"l",\u019a:"l",\u026b:"l",\u2c61:"l",\ua749:"l",\ua781:"l",\ua747:"l",\u01c9:"lj","\u24dc":"m",\uff4d:"m",\u1e3f:"m",\u1e41:"m",\u1e43:"m",\u0271:"m",\u026f:"m","\u24dd":"n",\uff4e:"n",\u01f9:"n",\u0144:"n",\u00f1:"n",\u1e45:"n",\u0148:"n",\u1e47:"n",\u0146:"n",\u1e4b:"n",\u1e49:"n",\u019e:"n",\u0272:"n",\u0149:"n","\ua791":"n","\ua7a5":"n",\u01cc:"nj","\u24de":"o",\uff4f:"o",\u00f2:"o",\u00f3:"o",\u00f4:"o",\u1ed3:"o",\u1ed1:"o",\u1ed7:"o",\u1ed5:"o",\u00f5:"o",\u1e4d:"o",\u022d:"o",\u1e4f:"o",\u014d:"o",\u1e51:"o",\u1e53:"o",\u014f:"o",\u022f:"o",\u0231:"o",\u00f6:"o",\u022b:"o",\u1ecf:"o",\u0151:"o",\u01d2:"o",\u020d:"o",\u020f:"o",\u01a1:"o",\u1edd:"o",\u1edb:"o",\u1ee1:"o",\u1edf:"o",\u1ee3:"o",\u1ecd:"o",\u1ed9:"o",\u01eb:"o",\u01ed:"o",\u00f8:"o",\u01ff:"o",\u0254:"o",\ua74b:"o",\ua74d:"o",\u0275:"o",\u01a3:"oi",\u0223:"ou",\ua74f:"oo","\u24df":"p",\uff50:"p",\u1e55:"p",\u1e57:"p",\u01a5:"p",\u1d7d:"p",\ua751:"p",\ua753:"p",\ua755:"p","\u24e0":"q",\uff51:"q",\u024b:"q",\ua757:"q",\ua759:"q","\u24e1":"r",\uff52:"r",\u0155:"r",\u1e59:"r",\u0159:"r",\u0211:"r",\u0213:"r",\u1e5b:"r",\u1e5d:"r",\u0157:"r",\u1e5f:"r",\u024d:"r",\u027d:"r",\ua75b:"r","\ua7a7":"r",\ua783:"r","\u24e2":"s",\uff53:"s",\u00df:"s",\u015b:"s",\u1e65:"s",\u015d:"s",\u1e61:"s",\u0161:"s",\u1e67:"s",\u1e63:"s",\u1e69:"s",\u0219:"s",\u015f:"s",\u023f:"s","\ua7a9":"s",\ua785:"s",\u1e9b:"s","\u24e3":"t",\uff54:"t",\u1e6b:"t",\u1e97:"t",\u0165:"t",\u1e6d:"t",\u021b:"t",\u0163:"t",\u1e71:"t",\u1e6f:"t",\u0167:"t",\u01ad:"t",\u0288:"t",\u2c66:"t",\ua787:"t",\ua729:"tz","\u24e4":"u",\uff55:"u",\u00f9:"u",\u00fa:"u",\u00fb:"u",\u0169:"u",\u1e79:"u",\u016b:"u",\u1e7b:"u",\u016d:"u",\u00fc:"u",\u01dc:"u",\u01d8:"u",\u01d6:"u",\u01da:"u",\u1ee7:"u",\u016f:"u",\u0171:"u",\u01d4:"u",\u0215:"u",\u0217:"u",\u01b0:"u",\u1eeb:"u",\u1ee9:"u",\u1eef:"u",\u1eed:"u",\u1ef1:"u",\u1ee5:"u",\u1e73:"u",\u0173:"u",\u1e77:"u",\u1e75:"u",\u0289:"u","\u24e5":"v",\uff56:"v",\u1e7d:"v",\u1e7f:"v",\u028b:"v",\ua75f:"v",\u028c:"v",\ua761:"vy","\u24e6":"w",\uff57:"w",\u1e81:"w",\u1e83:"w",\u0175:"w",\u1e87:"w",\u1e85:"w",\u1e98:"w",\u1e89:"w",\u2c73:"w","\u24e7":"x",\uff58:"x",\u1e8b:"x",\u1e8d:"x","\u24e8":"y",\uff59:"y",\u1ef3:"y",\u00fd:"y",\u0177:"y",\u1ef9:"y",\u0233:"y",\u1e8f:"y",\u00ff:"y",\u1ef7:"y",\u1e99:"y",\u1ef5:"y",\u01b4:"y",\u024f:"y",\u1eff:"y","\u24e9":"z",\uff5a:"z",\u017a:"z",\u1e91:"z",\u017c:"z",\u017e:"z",\u1e93:"z",\u1e95:"z",\u01b6:"z",\u0225:"z",\u0240:"z",\u2c6c:"z",\ua763:"z"};J=a(document),H=function(){var a=1;return function(){return a++}}(),J.on("mousemove",function(a){L.x=a.pageX,L.y=a.pageY}),E=C(Object,{bind:function(a){var b=this;return function(){a.apply(b,arguments)}},init:function(c){var d,f,g=".select2-results";this.opts=c=this.prepareOpts(c),this.id=c.id,c.element.data("select2")!==b&&null!==c.element.data("select2")&&c.element.data("select2").destroy(),this.container=this.createContainer(),this.containerId="s2id_"+(c.element.attr("id")||"autogen"+H()),this.containerSelector="#"+this.containerId.replace(/([;&,\.\+\*\~':"\!\^#$%@\[\]\(\)=>\|])/g,"\\$1"),this.container.attr("id",this.containerId),this.body=l(function(){return c.element.closest("body") }),s(this.container,this.opts.element,this.opts.adaptContainerCssClass),this.container.attr("style",c.element.attr("style")),this.container.css(z(c.containerCss)),this.container.addClass(z(c.containerCssClass)),this.elementTabIndex=this.opts.element.attr("tabindex"),this.opts.element.data("select2",this).attr("tabindex","-1").before(this.container).on("click.select2",p),this.container.data("select2",this),this.dropdown=this.container.find(".select2-drop"),s(this.dropdown,this.opts.element,this.opts.adaptDropdownCssClass),this.dropdown.addClass(z(c.dropdownCssClass)),this.dropdown.data("select2",this),this.dropdown.on("click",p),this.results=d=this.container.find(g),this.search=f=this.container.find("input.select2-input"),this.queryCount=0,this.resultsPage=0,this.context=null,this.initContainer(),this.container.on("click",p),j(this.results),this.dropdown.on("mousemove-filtered touchstart touchmove touchend",g,this.bind(this.highlightUnderEvent)),m(80,this.results),this.dropdown.on("scroll-debounced",g,this.bind(this.loadMoreIfNeeded)),a(this.container).on("change",".select2-input",function(a){a.stopPropagation()}),a(this.dropdown).on("change",".select2-input",function(a){a.stopPropagation()}),a.fn.mousewheel&&d.mousewheel(function(a,b,c,e){var f=d.scrollTop();e>0&&0>=f-e?(d.scrollTop(0),p(a)):0>e&&d.get(0).scrollHeight-d.scrollTop()+e<=d.height()&&(d.scrollTop(d.get(0).scrollHeight-d.height()),p(a))}),i(f),f.on("keyup-change input paste",this.bind(this.updateResults)),f.on("focus",function(){f.addClass("select2-focused")}),f.on("blur",function(){f.removeClass("select2-focused")}),this.dropdown.on("mouseup",g,this.bind(function(b){a(b.target).closest(".select2-result-selectable").length>0&&(this.highlightUnderEvent(b),this.selectHighlighted(b))})),this.dropdown.on("click mouseup mousedown",function(a){a.stopPropagation()}),a.isFunction(this.opts.initSelection)&&(this.initSelection(),this.monitorSource()),null!==c.maximumInputLength&&this.search.attr("maxlength",c.maximumInputLength);var h=c.element.prop("disabled");h===b&&(h=!1),this.enable(!h);var k=c.element.prop("readonly");k===b&&(k=!1),this.readonly(k),K=K||e(),this.autofocus=c.element.prop("autofocus"),c.element.prop("autofocus",!1),this.autofocus&&this.focus(),this.nextSearchTerm=b},destroy:function(){var a=this.opts.element,c=a.data("select2");this.close(),this.propertyObserver&&(delete this.propertyObserver,this.propertyObserver=null),c!==b&&(c.container.remove(),c.dropdown.remove(),a.removeClass("select2-offscreen").removeData("select2").off(".select2").prop("autofocus",this.autofocus||!1),this.elementTabIndex?a.attr({tabindex:this.elementTabIndex}):a.removeAttr("tabindex"),a.show())},optionToData:function(a){return a.is("option")?{id:a.prop("value"),text:a.text(),element:a.get(),css:a.attr("class"),disabled:a.prop("disabled"),locked:f(a.attr("locked"),"locked")||f(a.data("locked"),!0)}:a.is("optgroup")?{text:a.attr("label"),children:[],element:a.get(),css:a.attr("class")}:void 0},prepareOpts:function(c){var d,e,h,i,j=this;if(d=c.element,"select"===d.get(0).tagName.toLowerCase()&&(this.select=e=c.element),e&&a.each(["id","multiple","ajax","query","createSearchChoice","initSelection","data","tags"],function(){if(this in c)throw new Error("Option '"+this+"' is not allowed for Select2 when attached to a <select> element.")}),c=a.extend({},{populateResults:function(d,e,f){var g,h=this.opts.id;(g=function(d,e,i){var k,l,m,n,o,p,q,r,s,t;for(d=c.sortResults(d,e,f),k=0,l=d.length;l>k;k+=1)m=d[k],o=m.disabled===!0,n=!o&&h(m)!==b,p=m.children&&m.children.length>0,q=a("<li></li>"),q.addClass("select2-results-dept-"+i),q.addClass("select2-result"),q.addClass(n?"select2-result-selectable":"select2-result-unselectable"),o&&q.addClass("select2-disabled"),p&&q.addClass("select2-result-with-children"),q.addClass(j.opts.formatResultCssClass(m)),r=a(document.createElement("div")),r.addClass("select2-result-label"),t=c.formatResult(m,r,f,j.opts.escapeMarkup),t!==b&&r.html(t),q.append(r),p&&(s=a("<ul></ul>"),s.addClass("select2-result-sub"),g(m.children,s,i+1),q.append(s)),q.data("select2-data",m),e.append(q)})(e,d,0)}},a.fn.select2.defaults,c),"function"!=typeof c.id&&(h=c.id,c.id=function(a){return a[h]}),a.isArray(c.element.data("select2Tags"))){if("tags"in c)throw"tags specified as both an attribute 'data-select2-tags' and in options of Select2 "+c.element.attr("id");c.tags=c.element.data("select2Tags")}if(e?(c.query=this.bind(function(a){var c,e,f,g={results:[],more:!1},h=a.term;f=function(b,c){var d;b.is("option")?a.matcher(h,b.text(),b)&&c.push(j.optionToData(b)):b.is("optgroup")&&(d=j.optionToData(b),b.children().each2(function(a,b){f(b,d.children)}),d.children.length>0&&c.push(d))},c=d.children(),this.getPlaceholder()!==b&&c.length>0&&(e=this.getPlaceholderOption(),e&&(c=c.not(e))),c.each2(function(a,b){f(b,g.results)}),a.callback(g)}),c.id=function(a){return a.id},c.formatResultCssClass=function(a){return a.css}):"query"in c||("ajax"in c?(i=c.element.data("ajax-url"),i&&i.length>0&&(c.ajax.url=i),c.query=v.call(c.element,c.ajax)):"data"in c?c.query=w(c.data):"tags"in c&&(c.query=x(c.tags),c.createSearchChoice===b&&(c.createSearchChoice=function(b){return{id:a.trim(b),text:a.trim(b)}}),c.initSelection===b&&(c.initSelection=function(b,d){var e=[];a(g(b.val(),c.separator)).each(function(){var b={id:this,text:this},d=c.tags;a.isFunction(d)&&(d=d()),a(d).each(function(){return f(this.id,b.id)?(b=this,!1):void 0}),e.push(b)}),d(e)}))),"function"!=typeof c.query)throw"query function not defined for Select2 "+c.element.attr("id");return c},monitorSource:function(){var a,c,d=this.opts.element;d.on("change.select2",this.bind(function(){this.opts.element.data("select2-change-triggered")!==!0&&this.initSelection()})),a=this.bind(function(){var a=d.prop("disabled");a===b&&(a=!1),this.enable(!a);var c=d.prop("readonly");c===b&&(c=!1),this.readonly(c),s(this.container,this.opts.element,this.opts.adaptContainerCssClass),this.container.addClass(z(this.opts.containerCssClass)),s(this.dropdown,this.opts.element,this.opts.adaptDropdownCssClass),this.dropdown.addClass(z(this.opts.dropdownCssClass))}),d.on("propertychange.select2",a),this.mutationCallback===b&&(this.mutationCallback=function(b){b.forEach(a)}),c=window.MutationObserver||window.WebKitMutationObserver||window.MozMutationObserver,c!==b&&(this.propertyObserver&&(delete this.propertyObserver,this.propertyObserver=null),this.propertyObserver=new c(this.mutationCallback),this.propertyObserver.observe(d.get(0),{attributes:!0,subtree:!1}))},triggerSelect:function(b){var c=a.Event("select2-selecting",{val:this.id(b),object:b});return this.opts.element.trigger(c),!c.isDefaultPrevented()},triggerChange:function(b){b=b||{},b=a.extend({},b,{type:"change",val:this.val()}),this.opts.element.data("select2-change-triggered",!0),this.opts.element.trigger(b),this.opts.element.data("select2-change-triggered",!1),this.opts.element.click(),this.opts.blurOnChange&&this.opts.element.blur()},isInterfaceEnabled:function(){return this.enabledInterface===!0},enableInterface:function(){var a=this._enabled&&!this._readonly,b=!a;return a===this.enabledInterface?!1:(this.container.toggleClass("select2-container-disabled",b),this.close(),this.enabledInterface=a,!0)},enable:function(a){a===b&&(a=!0),this._enabled!==a&&(this._enabled=a,this.opts.element.prop("disabled",!a),this.enableInterface())},disable:function(){this.enable(!1)},readonly:function(a){return a===b&&(a=!1),this._readonly===a?!1:(this._readonly=a,this.opts.element.prop("readonly",a),this.enableInterface(),!0)},opened:function(){return this.container.hasClass("select2-dropdown-open")},positionDropdown:function(){var b,c,d,e,f,g=this.dropdown,h=this.container.offset(),i=this.container.outerHeight(!1),j=this.container.outerWidth(!1),k=g.outerHeight(!1),l=a(window),m=l.width(),n=l.height(),o=l.scrollLeft()+m,p=l.scrollTop()+n,q=h.top+i,r=h.left,s=p>=q+k,t=h.top-k>=this.body().scrollTop(),u=g.outerWidth(!1),v=o>=r+u,w=g.hasClass("select2-drop-above");w?(c=!0,!t&&s&&(d=!0,c=!1)):(c=!1,!s&&t&&(d=!0,c=!0)),d&&(g.hide(),h=this.container.offset(),i=this.container.outerHeight(!1),j=this.container.outerWidth(!1),k=g.outerHeight(!1),o=l.scrollLeft()+m,p=l.scrollTop()+n,q=h.top+i,r=h.left,u=g.outerWidth(!1),v=o>=r+u,g.show()),this.opts.dropdownAutoWidth?(f=a(".select2-results",g)[0],g.addClass("select2-drop-auto-width"),g.css("width",""),u=g.outerWidth(!1)+(f.scrollHeight===f.clientHeight?0:K.width),u>j?j=u:u=j,v=o>=r+u):this.container.removeClass("select2-drop-auto-width"),"static"!==this.body().css("position")&&(b=this.body().offset(),q-=b.top,r-=b.left),v||(r=h.left+j-u),e={left:r,width:j},c?(e.bottom=n-h.top,e.top="auto",this.container.addClass("select2-drop-above"),g.addClass("select2-drop-above")):(e.top=q,e.bottom="auto",this.container.removeClass("select2-drop-above"),g.removeClass("select2-drop-above")),e=a.extend(e,z(this.opts.dropdownCss)),g.css(e)},shouldOpen:function(){var b;return this.opened()?!1:this._enabled===!1||this._readonly===!0?!1:(b=a.Event("select2-opening"),this.opts.element.trigger(b),!b.isDefaultPrevented())},clearDropdownAlignmentPreference:function(){this.container.removeClass("select2-drop-above"),this.dropdown.removeClass("select2-drop-above")},open:function(){return this.shouldOpen()?(this.opening(),!0):!1},opening:function(){var b,c=this.containerId,d="scroll."+c,e="resize."+c,f="orientationchange."+c;this.container.addClass("select2-dropdown-open").addClass("select2-container-active"),this.clearDropdownAlignmentPreference(),this.dropdown[0]!==this.body().children().last()[0]&&this.dropdown.detach().appendTo(this.body()),b=a("#select2-drop-mask"),0==b.length&&(b=a(document.createElement("div")),b.attr("id","select2-drop-mask").attr("class","select2-drop-mask"),b.hide(),b.appendTo(this.body()),b.on("mousedown touchstart click",function(b){var c,d=a("#select2-drop");d.length>0&&(c=d.data("select2"),c.opts.selectOnBlur&&c.selectHighlighted({noFocus:!0}),c.close({focus:!0}),b.preventDefault(),b.stopPropagation())})),this.dropdown.prev()[0]!==b[0]&&this.dropdown.before(b),a("#select2-drop").removeAttr("id"),this.dropdown.attr("id","select2-drop"),b.show(),this.positionDropdown(),this.dropdown.show(),this.positionDropdown(),this.dropdown.addClass("select2-drop-active");var g=this;this.container.parents().add(window).each(function(){a(this).on(e+" "+d+" "+f,function(){g.positionDropdown()})})},close:function(){if(this.opened()){var b=this.containerId,c="scroll."+b,d="resize."+b,e="orientationchange."+b;this.container.parents().add(window).each(function(){a(this).off(c).off(d).off(e)}),this.clearDropdownAlignmentPreference(),a("#select2-drop-mask").hide(),this.dropdown.removeAttr("id"),this.dropdown.hide(),this.container.removeClass("select2-dropdown-open").removeClass("select2-container-active"),this.results.empty(),this.clearSearch(),this.search.removeClass("select2-active"),this.opts.element.trigger(a.Event("select2-close"))}},externalSearch:function(a){this.open(),this.search.val(a),this.updateResults(!1)},clearSearch:function(){},getMaximumSelectionSize:function(){return z(this.opts.maximumSelectionSize)},ensureHighlightVisible:function(){var b,c,d,e,f,g,h,i=this.results;if(c=this.highlight(),!(0>c)){if(0==c)return void i.scrollTop(0);b=this.findHighlightableChoices().find(".select2-result-label"),d=a(b[c]),e=d.offset().top+d.outerHeight(!0),c===b.length-1&&(h=i.find("li.select2-more-results"),h.length>0&&(e=h.offset().top+h.outerHeight(!0))),f=i.offset().top+i.outerHeight(!0),e>f&&i.scrollTop(i.scrollTop()+(e-f)),g=d.offset().top-i.offset().top,0>g&&"none"!=d.css("display")&&i.scrollTop(i.scrollTop()+g)}},findHighlightableChoices:function(){return this.results.find(".select2-result-selectable:not(.select2-disabled, .select2-selected)")},moveHighlight:function(b){for(var c=this.findHighlightableChoices(),d=this.highlight();d>-1&&d<c.length;){d+=b;var e=a(c[d]);if(e.hasClass("select2-result-selectable")&&!e.hasClass("select2-disabled")&&!e.hasClass("select2-selected")){this.highlight(d);break}}},highlight:function(b){var c,e,f=this.findHighlightableChoices();return 0===arguments.length?d(f.filter(".select2-highlighted")[0],f.get()):(b>=f.length&&(b=f.length-1),0>b&&(b=0),this.removeHighlight(),c=a(f[b]),c.addClass("select2-highlighted"),this.ensureHighlightVisible(),e=c.data("select2-data"),void(e&&this.opts.element.trigger({type:"select2-highlight",val:this.id(e),choice:e})))},removeHighlight:function(){this.results.find(".select2-highlighted").removeClass("select2-highlighted")},countSelectableResults:function(){return this.findHighlightableChoices().length},highlightUnderEvent:function(b){var c=a(b.target).closest(".select2-result-selectable");if(c.length>0&&!c.is(".select2-highlighted")){var d=this.findHighlightableChoices();this.highlight(d.index(c))}else 0==c.length&&this.removeHighlight()},loadMoreIfNeeded:function(){var a,b=this.results,c=b.find("li.select2-more-results"),d=this.resultsPage+1,e=this,f=this.search.val(),g=this.context;0!==c.length&&(a=c.offset().top-b.offset().top-b.height(),a<=this.opts.loadMorePadding&&(c.addClass("select2-active"),this.opts.query({element:this.opts.element,term:f,page:d,context:g,matcher:this.opts.matcher,callback:this.bind(function(a){e.opened()&&(e.opts.populateResults.call(this,b,a.results,{term:f,page:d,context:g}),e.postprocessResults(a,!1,!1),a.more===!0?(c.detach().appendTo(b).text(e.opts.formatLoadMore(d+1)),window.setTimeout(function(){e.loadMoreIfNeeded()},10)):c.remove(),e.positionDropdown(),e.resultsPage=d,e.context=a.context,this.opts.element.trigger({type:"select2-loaded",items:a}))})})))},tokenize:function(){},updateResults:function(c){function d(){j.removeClass("select2-active"),m.positionDropdown()}function e(a){k.html(a),d()}var g,h,i,j=this.search,k=this.results,l=this.opts,m=this,n=j.val(),o=a.data(this.container,"select2-last-term");if((c===!0||!o||!f(n,o))&&(a.data(this.container,"select2-last-term",n),c===!0||this.showSearchInput!==!1&&this.opened())){i=++this.queryCount;var p=this.getMaximumSelectionSize();if(p>=1&&(g=this.data(),a.isArray(g)&&g.length>=p&&y(l.formatSelectionTooBig,"formatSelectionTooBig")))return void e("<li class='select2-selection-limit'>"+l.formatSelectionTooBig(p)+"</li>");if(j.val().length<l.minimumInputLength)return e(y(l.formatInputTooShort,"formatInputTooShort")?"<li class='select2-no-results'>"+l.formatInputTooShort(j.val(),l.minimumInputLength)+"</li>":""),void(c&&this.showSearch&&this.showSearch(!0));if(l.maximumInputLength&&j.val().length>l.maximumInputLength)return void e(y(l.formatInputTooLong,"formatInputTooLong")?"<li class='select2-no-results'>"+l.formatInputTooLong(j.val(),l.maximumInputLength)+"</li>":"");l.formatSearching&&0===this.findHighlightableChoices().length&&e("<li class='select2-searching'>"+l.formatSearching()+"</li>"),j.addClass("select2-active"),this.removeHighlight(),h=this.tokenize(),h!=b&&null!=h&&j.val(h),this.resultsPage=1,l.query({element:l.element,term:j.val(),page:this.resultsPage,context:null,matcher:l.matcher,callback:this.bind(function(g){var h;if(i==this.queryCount){if(!this.opened())return void this.search.removeClass("select2-active");if(this.context=g.context===b?null:g.context,this.opts.createSearchChoice&&""!==j.val()&&(h=this.opts.createSearchChoice.call(m,j.val(),g.results),h!==b&&null!==h&&m.id(h)!==b&&null!==m.id(h)&&0===a(g.results).filter(function(){return f(m.id(this),m.id(h))}).length&&g.results.unshift(h)),0===g.results.length&&y(l.formatNoMatches,"formatNoMatches"))return void e("<li class='select2-no-results'>"+l.formatNoMatches(j.val())+"</li>");k.empty(),m.opts.populateResults.call(this,k,g.results,{term:j.val(),page:this.resultsPage,context:null}),g.more===!0&&y(l.formatLoadMore,"formatLoadMore")&&(k.append("<li class='select2-more-results'>"+m.opts.escapeMarkup(l.formatLoadMore(this.resultsPage))+"</li>"),window.setTimeout(function(){m.loadMoreIfNeeded()},10)),this.postprocessResults(g,c),d(),this.opts.element.trigger({type:"select2-loaded",items:g})}})})}},cancel:function(){this.close()},blur:function(){this.opts.selectOnBlur&&this.selectHighlighted({noFocus:!0}),this.close(),this.container.removeClass("select2-container-active"),this.search[0]===document.activeElement&&this.search.blur(),this.clearSearch(),this.selection.find(".select2-search-choice-focus").removeClass("select2-search-choice-focus")},focusSearch:function(){n(this.search)},selectHighlighted:function(a){var b=this.highlight(),c=this.results.find(".select2-highlighted"),d=c.closest(".select2-result").data("select2-data");d?(this.highlight(b),this.onSelect(d,a)):a&&a.noFocus&&this.close()},getPlaceholder:function(){var a;return this.opts.element.attr("placeholder")||this.opts.element.attr("data-placeholder")||this.opts.element.data("placeholder")||this.opts.placeholder||((a=this.getPlaceholderOption())!==b?a.text():b)},getPlaceholderOption:function(){if(this.select){var a=this.select.children("option").first();if(this.opts.placeholderOption!==b)return"first"===this.opts.placeholderOption&&a||"function"==typeof this.opts.placeholderOption&&this.opts.placeholderOption(this.select);if(""===a.text()&&""===a.val())return a}},initContainerWidth:function(){function c(){var c,d,e,f,g,h;if("off"===this.opts.width)return null;if("element"===this.opts.width)return 0===this.opts.element.outerWidth(!1)?"auto":this.opts.element.outerWidth(!1)+"px";if("copy"===this.opts.width||"resolve"===this.opts.width){if(c=this.opts.element.attr("style"),c!==b)for(d=c.split(";"),f=0,g=d.length;g>f;f+=1)if(h=d[f].replace(/\s/g,""),e=h.match(/^width:(([-+]?([0-9]*\.)?[0-9]+)(px|em|ex|%|in|cm|mm|pt|pc))/i),null!==e&&e.length>=1)return e[1];return"resolve"===this.opts.width?(c=this.opts.element.css("width"),c.indexOf("%")>0?c:0===this.opts.element.outerWidth(!1)?"auto":this.opts.element.outerWidth(!1)+"px"):null}return a.isFunction(this.opts.width)?this.opts.width():this.opts.width}var d=c.call(this);null!==d&&this.container.css("width",d)}}),F=C(E,{createContainer:function(){var b=a(document.createElement("div")).attr({"class":"select2-container"}).html(["<a href='javascript:void(0)' onclick='return false;' class='select2-choice' tabindex='-1'>"," <span class='select2-chosen'>&nbsp;</span><abbr class='select2-search-choice-close'></abbr>"," <span class='select2-arrow'><b></b></span>","</a>","<input class='select2-focusser select2-offscreen' type='text'/>","<div class='select2-drop select2-display-none'>"," <div class='select2-search'>"," <input type='text' autocomplete='off' autocorrect='off' autocapitalize='off' spellcheck='false' class='select2-input'/>"," </div>"," <ul class='select2-results'>"," </ul>","</div>"].join(""));return b},enableInterface:function(){this.parent.enableInterface.apply(this,arguments)&&this.focusser.prop("disabled",!this.isInterfaceEnabled())},opening:function(){var c,d,e;this.opts.minimumResultsForSearch>=0&&this.showSearch(!0),this.parent.opening.apply(this,arguments),this.showSearchInput!==!1&&this.search.val(this.focusser.val()),this.search.focus(),c=this.search.get(0),c.createTextRange?(d=c.createTextRange(),d.collapse(!1),d.select()):c.setSelectionRange&&(e=this.search.val().length,c.setSelectionRange(e,e)),""===this.search.val()&&this.nextSearchTerm!=b&&(this.search.val(this.nextSearchTerm),this.search.select()),this.focusser.prop("disabled",!0).val(""),this.updateResults(!0),this.opts.element.trigger(a.Event("select2-open"))},close:function(a){this.opened()&&(this.parent.close.apply(this,arguments),a=a||{focus:!0},this.focusser.removeAttr("disabled"),a.focus&&this.focusser.focus())},focus:function(){this.opened()?this.close():(this.focusser.removeAttr("disabled"),this.focusser.focus())},isFocused:function(){return this.container.hasClass("select2-container-active")},cancel:function(){this.parent.cancel.apply(this,arguments),this.focusser.removeAttr("disabled"),this.focusser.focus()},destroy:function(){a("label[for='"+this.focusser.attr("id")+"']").attr("for",this.opts.element.attr("id")),this.parent.destroy.apply(this,arguments)},initContainer:function(){var b,c=this.container,d=this.dropdown;this.showSearch(this.opts.minimumResultsForSearch<0?!1:!0),this.selection=b=c.find(".select2-choice"),this.focusser=c.find(".select2-focusser"),this.focusser.attr("id","s2id_autogen"+H()),a("label[for='"+this.opts.element.attr("id")+"']").attr("for",this.focusser.attr("id")),this.focusser.attr("tabindex",this.elementTabIndex),this.search.on("keydown",this.bind(function(a){if(this.isInterfaceEnabled()){if(a.which===D.PAGE_UP||a.which===D.PAGE_DOWN)return void p(a);switch(a.which){case D.UP:case D.DOWN:return this.moveHighlight(a.which===D.UP?-1:1),void p(a);case D.ENTER:return this.selectHighlighted(),void p(a);case D.TAB:return void this.selectHighlighted({noFocus:!0});case D.ESC:return this.cancel(a),void p(a)}}})),this.search.on("blur",this.bind(function(){document.activeElement===this.body().get(0)&&window.setTimeout(this.bind(function(){this.search.focus()}),0)})),this.focusser.on("keydown",this.bind(function(a){if(this.isInterfaceEnabled()&&a.which!==D.TAB&&!D.isControl(a)&&!D.isFunctionKey(a)&&a.which!==D.ESC){if(this.opts.openOnEnter===!1&&a.which===D.ENTER)return void p(a);if(a.which==D.DOWN||a.which==D.UP||a.which==D.ENTER&&this.opts.openOnEnter){if(a.altKey||a.ctrlKey||a.shiftKey||a.metaKey)return;return this.open(),void p(a)}return a.which==D.DELETE||a.which==D.BACKSPACE?(this.opts.allowClear&&this.clear(),void p(a)):void 0}})),i(this.focusser),this.focusser.on("keyup-change input",this.bind(function(a){if(this.opts.minimumResultsForSearch>=0){if(a.stopPropagation(),this.opened())return;this.open()}})),b.on("mousedown","abbr",this.bind(function(a){this.isInterfaceEnabled()&&(this.clear(),q(a),this.close(),this.selection.focus())})),b.on("mousedown",this.bind(function(b){this.container.hasClass("select2-container-active")||this.opts.element.trigger(a.Event("select2-focus")),this.opened()?this.close():this.isInterfaceEnabled()&&this.open(),p(b)})),d.on("mousedown",this.bind(function(){this.search.focus()})),b.on("focus",this.bind(function(a){p(a)})),this.focusser.on("focus",this.bind(function(){this.container.hasClass("select2-container-active")||this.opts.element.trigger(a.Event("select2-focus")),this.container.addClass("select2-container-active")})).on("blur",this.bind(function(){this.opened()||(this.container.removeClass("select2-container-active"),this.opts.element.trigger(a.Event("select2-blur")))})),this.search.on("focus",this.bind(function(){this.container.hasClass("select2-container-active")||this.opts.element.trigger(a.Event("select2-focus")),this.container.addClass("select2-container-active")})),this.initContainerWidth(),this.opts.element.addClass("select2-offscreen"),this.setPlaceholder()},clear:function(b){var c=this.selection.data("select2-data");if(c){var d=a.Event("select2-clearing");if(this.opts.element.trigger(d),d.isDefaultPrevented())return;var e=this.getPlaceholderOption();this.opts.element.val(e?e.val():""),this.selection.find(".select2-chosen").empty(),this.selection.removeData("select2-data"),this.setPlaceholder(),b!==!1&&(this.opts.element.trigger({type:"select2-removed",val:this.id(c),choice:c}),this.triggerChange({removed:c}))}},initSelection:function(){if(this.isPlaceholderOptionSelected())this.updateSelection(null),this.close(),this.setPlaceholder();else{var a=this;this.opts.initSelection.call(null,this.opts.element,function(c){c!==b&&null!==c&&(a.updateSelection(c),a.close(),a.setPlaceholder())})}},isPlaceholderOptionSelected:function(){var a;return this.getPlaceholder()?(a=this.getPlaceholderOption())!==b&&a.prop("selected")||""===this.opts.element.val()||this.opts.element.val()===b||null===this.opts.element.val():!1},prepareOpts:function(){var b=this.parent.prepareOpts.apply(this,arguments),c=this;return"select"===b.element.get(0).tagName.toLowerCase()?b.initSelection=function(a,b){var d=a.find("option").filter(function(){return this.selected});b(c.optionToData(d))}:"data"in b&&(b.initSelection=b.initSelection||function(c,d){var e=c.val(),g=null;b.query({matcher:function(a,c,d){var h=f(e,b.id(d));return h&&(g=d),h},callback:a.isFunction(d)?function(){d(g)}:a.noop})}),b},getPlaceholder:function(){return this.select&&this.getPlaceholderOption()===b?b:this.parent.getPlaceholder.apply(this,arguments)},setPlaceholder:function(){var a=this.getPlaceholder();if(this.isPlaceholderOptionSelected()&&a!==b){if(this.select&&this.getPlaceholderOption()===b)return;this.selection.find(".select2-chosen").html(this.opts.escapeMarkup(a)),this.selection.addClass("select2-default"),this.container.removeClass("select2-allowclear")}},postprocessResults:function(a,b,c){var d=0,e=this;if(this.findHighlightableChoices().each2(function(a,b){return f(e.id(b.data("select2-data")),e.opts.element.val())?(d=a,!1):void 0}),c!==!1&&this.highlight(b===!0&&d>=0?d:0),b===!0){var g=this.opts.minimumResultsForSearch;g>=0&&this.showSearch(A(a.results)>=g)}},showSearch:function(b){this.showSearchInput!==b&&(this.showSearchInput=b,this.dropdown.find(".select2-search").toggleClass("select2-search-hidden",!b),this.dropdown.find(".select2-search").toggleClass("select2-offscreen",!b),a(this.dropdown,this.container).toggleClass("select2-with-searchbox",b))},onSelect:function(a,b){if(this.triggerSelect(a)){var c=this.opts.element.val(),d=this.data();this.opts.element.val(this.id(a)),this.updateSelection(a),this.opts.element.trigger({type:"select2-selected",val:this.id(a),choice:a}),this.nextSearchTerm=this.opts.nextSearchTerm(a,this.search.val()),this.close(),b&&b.noFocus||this.focusser.focus(),f(c,this.id(a))||this.triggerChange({added:a,removed:d})}},updateSelection:function(a){var c,d,e=this.selection.find(".select2-chosen");this.selection.data("select2-data",a),e.empty(),null!==a&&(c=this.opts.formatSelection(a,e,this.opts.escapeMarkup)),c!==b&&e.append(c),d=this.opts.formatSelectionCssClass(a,e),d!==b&&e.addClass(d),this.selection.removeClass("select2-default"),this.opts.allowClear&&this.getPlaceholder()!==b&&this.container.addClass("select2-allowclear")},val:function(){var a,c=!1,d=null,e=this,f=this.data();if(0===arguments.length)return this.opts.element.val();if(a=arguments[0],arguments.length>1&&(c=arguments[1]),this.select)this.select.val(a).find("option").filter(function(){return this.selected}).each2(function(a,b){return d=e.optionToData(b),!1}),this.updateSelection(d),this.setPlaceholder(),c&&this.triggerChange({added:d,removed:f});else{if(!a&&0!==a)return void this.clear(c);if(this.opts.initSelection===b)throw new Error("cannot call val() if initSelection() is not defined");this.opts.element.val(a),this.opts.initSelection(this.opts.element,function(a){e.opts.element.val(a?e.id(a):""),e.updateSelection(a),e.setPlaceholder(),c&&e.triggerChange({added:a,removed:f})})}},clearSearch:function(){this.search.val(""),this.focusser.val("")},data:function(a){var c,d=!1;return 0===arguments.length?(c=this.selection.data("select2-data"),c==b&&(c=null),c):(arguments.length>1&&(d=arguments[1]),void(a?(c=this.data(),this.opts.element.val(a?this.id(a):""),this.updateSelection(a),d&&this.triggerChange({added:a,removed:c})):this.clear(d)))}}),G=C(E,{createContainer:function(){var b=a(document.createElement("div")).attr({"class":"select2-container select2-container-multi"}).html(["<ul class='select2-choices'>"," <li class='select2-search-field'>"," <input type='text' autocomplete='off' autocorrect='off' autocapitalize='off' spellcheck='false' class='select2-input'>"," </li>","</ul>","<div class='select2-drop select2-drop-multi select2-display-none'>"," <ul class='select2-results'>"," </ul>","</div>"].join(""));return b},prepareOpts:function(){var b=this.parent.prepareOpts.apply(this,arguments),c=this;return"select"===b.element.get(0).tagName.toLowerCase()?b.initSelection=function(a,b){var d=[];a.find("option").filter(function(){return this.selected}).each2(function(a,b){d.push(c.optionToData(b))}),b(d)}:"data"in b&&(b.initSelection=b.initSelection||function(c,d){var e=g(c.val(),b.separator),h=[];b.query({matcher:function(c,d,g){var i=a.grep(e,function(a){return f(a,b.id(g))}).length;return i&&h.push(g),i},callback:a.isFunction(d)?function(){for(var a=[],c=0;c<e.length;c++)for(var g=e[c],i=0;i<h.length;i++){var j=h[i];if(f(g,b.id(j))){a.push(j),h.splice(i,1);break}}d(a)}:a.noop})}),b},selectChoice:function(a){var b=this.container.find(".select2-search-choice-focus");b.length&&a&&a[0]==b[0]||(b.length&&this.opts.element.trigger("choice-deselected",b),b.removeClass("select2-search-choice-focus"),a&&a.length&&(this.close(),a.addClass("select2-search-choice-focus"),this.opts.element.trigger("choice-selected",a)))},destroy:function(){a("label[for='"+this.search.attr("id")+"']").attr("for",this.opts.element.attr("id")),this.parent.destroy.apply(this,arguments)},initContainer:function(){var b,c=".select2-choices";this.searchContainer=this.container.find(".select2-search-field"),this.selection=b=this.container.find(c);var d=this;this.selection.on("click",".select2-search-choice:not(.select2-locked)",function(){d.search[0].focus(),d.selectChoice(a(this))}),this.search.attr("id","s2id_autogen"+H()),a("label[for='"+this.opts.element.attr("id")+"']").attr("for",this.search.attr("id")),this.search.on("input paste",this.bind(function(){this.isInterfaceEnabled()&&(this.opened()||this.open())})),this.search.attr("tabindex",this.elementTabIndex),this.keydowns=0,this.search.on("keydown",this.bind(function(a){if(this.isInterfaceEnabled()){++this.keydowns;var c=b.find(".select2-search-choice-focus"),d=c.prev(".select2-search-choice:not(.select2-locked)"),e=c.next(".select2-search-choice:not(.select2-locked)"),f=o(this.search);if(c.length&&(a.which==D.LEFT||a.which==D.RIGHT||a.which==D.BACKSPACE||a.which==D.DELETE||a.which==D.ENTER)){var g=c;return a.which==D.LEFT&&d.length?g=d:a.which==D.RIGHT?g=e.length?e:null:a.which===D.BACKSPACE?(this.unselect(c.first()),this.search.width(10),g=d.length?d:e):a.which==D.DELETE?(this.unselect(c.first()),this.search.width(10),g=e.length?e:null):a.which==D.ENTER&&(g=null),this.selectChoice(g),p(a),void(g&&g.length||this.open())}if((a.which===D.BACKSPACE&&1==this.keydowns||a.which==D.LEFT)&&0==f.offset&&!f.length)return this.selectChoice(b.find(".select2-search-choice:not(.select2-locked)").last()),void p(a);if(this.selectChoice(null),this.opened())switch(a.which){case D.UP:case D.DOWN:return this.moveHighlight(a.which===D.UP?-1:1),void p(a);case D.ENTER:return this.selectHighlighted(),void p(a);case D.TAB:return this.selectHighlighted({noFocus:!0}),void this.close();case D.ESC:return this.cancel(a),void p(a)}if(a.which!==D.TAB&&!D.isControl(a)&&!D.isFunctionKey(a)&&a.which!==D.BACKSPACE&&a.which!==D.ESC){if(a.which===D.ENTER){if(this.opts.openOnEnter===!1)return;if(a.altKey||a.ctrlKey||a.shiftKey||a.metaKey)return}this.open(),(a.which===D.PAGE_UP||a.which===D.PAGE_DOWN)&&p(a),a.which===D.ENTER&&p(a)}}})),this.search.on("keyup",this.bind(function(){this.keydowns=0,this.resizeSearch()})),this.search.on("blur",this.bind(function(b){this.container.removeClass("select2-container-active"),this.search.removeClass("select2-focused"),this.selectChoice(null),this.opened()||this.clearSearch(),b.stopImmediatePropagation(),this.opts.element.trigger(a.Event("select2-blur"))})),this.container.on("click",c,this.bind(function(b){this.isInterfaceEnabled()&&(a(b.target).closest(".select2-search-choice").length>0||(this.selectChoice(null),this.clearPlaceholder(),this.container.hasClass("select2-container-active")||this.opts.element.trigger(a.Event("select2-focus")),this.open(),this.focusSearch(),b.preventDefault()))})),this.container.on("focus",c,this.bind(function(){this.isInterfaceEnabled()&&(this.container.hasClass("select2-container-active")||this.opts.element.trigger(a.Event("select2-focus")),this.container.addClass("select2-container-active"),this.dropdown.addClass("select2-drop-active"),this.clearPlaceholder())})),this.initContainerWidth(),this.opts.element.addClass("select2-offscreen"),this.clearSearch() },enableInterface:function(){this.parent.enableInterface.apply(this,arguments)&&this.search.prop("disabled",!this.isInterfaceEnabled())},initSelection:function(){if(""===this.opts.element.val()&&""===this.opts.element.text()&&(this.updateSelection([]),this.close(),this.clearSearch()),this.select||""!==this.opts.element.val()){var a=this;this.opts.initSelection.call(null,this.opts.element,function(c){c!==b&&null!==c&&(a.updateSelection(c),a.close(),a.clearSearch())})}},clearSearch:function(){var a=this.getPlaceholder(),c=this.getMaxSearchWidth();a!==b&&0===this.getVal().length&&this.search.hasClass("select2-focused")===!1?(this.search.val(a).addClass("select2-default"),this.search.width(c>0?c:this.container.css("width"))):this.search.val("").width(10)},clearPlaceholder:function(){this.search.hasClass("select2-default")&&this.search.val("").removeClass("select2-default")},opening:function(){this.clearPlaceholder(),this.resizeSearch(),this.parent.opening.apply(this,arguments),this.focusSearch(),this.updateResults(!0),this.search.focus(),this.opts.element.trigger(a.Event("select2-open"))},close:function(){this.opened()&&this.parent.close.apply(this,arguments)},focus:function(){this.close(),this.search.focus()},isFocused:function(){return this.search.hasClass("select2-focused")},updateSelection:function(b){var c=[],e=[],f=this;a(b).each(function(){d(f.id(this),c)<0&&(c.push(f.id(this)),e.push(this))}),b=e,this.selection.find(".select2-search-choice").remove(),a(b).each(function(){f.addSelectedChoice(this)}),f.postprocessResults()},tokenize:function(){var a=this.search.val();a=this.opts.tokenizer.call(this,a,this.data(),this.bind(this.onSelect),this.opts),null!=a&&a!=b&&(this.search.val(a),a.length>0&&this.open())},onSelect:function(a,b){this.triggerSelect(a)&&(this.addSelectedChoice(a),this.opts.element.trigger({type:"selected",val:this.id(a),choice:a}),(this.select||!this.opts.closeOnSelect)&&this.postprocessResults(a,!1,this.opts.closeOnSelect===!0),this.opts.closeOnSelect?(this.close(),this.search.width(10)):this.countSelectableResults()>0?(this.search.width(10),this.resizeSearch(),this.getMaximumSelectionSize()>0&&this.val().length>=this.getMaximumSelectionSize()&&this.updateResults(!0),this.positionDropdown()):(this.close(),this.search.width(10)),this.triggerChange({added:a}),b&&b.noFocus||this.focusSearch())},cancel:function(){this.close(),this.focusSearch()},addSelectedChoice:function(c){var d,e,f=!c.locked,g=a("<li class='select2-search-choice'> <div></div> <a href='#' onclick='return false;' class='select2-search-choice-close' tabindex='-1'></a></li>"),h=a("<li class='select2-search-choice select2-locked'><div></div></li>"),i=f?g:h,j=this.id(c),k=this.getVal();d=this.opts.formatSelection(c,i.find("div"),this.opts.escapeMarkup),d!=b&&i.find("div").replaceWith("<div>"+d+"</div>"),e=this.opts.formatSelectionCssClass(c,i.find("div")),e!=b&&i.addClass(e),f&&i.find(".select2-search-choice-close").on("mousedown",p).on("click dblclick",this.bind(function(b){this.isInterfaceEnabled()&&(a(b.target).closest(".select2-search-choice").fadeOut("fast",this.bind(function(){this.unselect(a(b.target)),this.selection.find(".select2-search-choice-focus").removeClass("select2-search-choice-focus"),this.close(),this.focusSearch()})).dequeue(),p(b))})).on("focus",this.bind(function(){this.isInterfaceEnabled()&&(this.container.addClass("select2-container-active"),this.dropdown.addClass("select2-drop-active"))})),i.data("select2-data",c),i.insertBefore(this.searchContainer),k.push(j),this.setVal(k)},unselect:function(b){var c,e,f=this.getVal();if(b=b.closest(".select2-search-choice"),0===b.length)throw"Invalid argument: "+b+". Must be .select2-search-choice";if(c=b.data("select2-data")){for(;(e=d(this.id(c),f))>=0;)f.splice(e,1),this.setVal(f),this.select&&this.postprocessResults();var g=a.Event("select2-removing");g.val=this.id(c),g.choice=c,this.opts.element.trigger(g),g.isDefaultPrevented()||(b.remove(),this.opts.element.trigger({type:"select2-removed",val:this.id(c),choice:c}),this.triggerChange({removed:c}))}},postprocessResults:function(a,b,c){var e=this.getVal(),f=this.results.find(".select2-result"),g=this.results.find(".select2-result-with-children"),h=this;f.each2(function(a,b){var c=h.id(b.data("select2-data"));d(c,e)>=0&&(b.addClass("select2-selected"),b.find(".select2-result-selectable").addClass("select2-selected"))}),g.each2(function(a,b){b.is(".select2-result-selectable")||0!==b.find(".select2-result-selectable:not(.select2-selected)").length||b.addClass("select2-selected")}),-1==this.highlight()&&c!==!1&&h.highlight(0),!this.opts.createSearchChoice&&!f.filter(".select2-result:not(.select2-selected)").length>0&&(!a||a&&!a.more&&0===this.results.find(".select2-no-results").length)&&y(h.opts.formatNoMatches,"formatNoMatches")&&this.results.append("<li class='select2-no-results'>"+h.opts.formatNoMatches(h.search.val())+"</li>")},getMaxSearchWidth:function(){return this.selection.width()-h(this.search)},resizeSearch:function(){var a,b,c,d,e,f=h(this.search);a=r(this.search)+10,b=this.search.offset().left,c=this.selection.width(),d=this.selection.offset().left,e=c-(b-d)-f,a>e&&(e=c-f),40>e&&(e=c-f),0>=e&&(e=a),this.search.width(Math.floor(e))},getVal:function(){var a;return this.select?(a=this.select.val(),null===a?[]:a):(a=this.opts.element.val(),g(a,this.opts.separator))},setVal:function(b){var c;this.select?this.select.val(b):(c=[],a(b).each(function(){d(this,c)<0&&c.push(this)}),this.opts.element.val(0===c.length?"":c.join(this.opts.separator)))},buildChangeDetails:function(a,b){for(var b=b.slice(0),a=a.slice(0),c=0;c<b.length;c++)for(var d=0;d<a.length;d++)f(this.opts.id(b[c]),this.opts.id(a[d]))&&(b.splice(c,1),c>0&&c--,a.splice(d,1),d--);return{added:b,removed:a}},val:function(c,d){var e,f=this;if(0===arguments.length)return this.getVal();if(e=this.data(),e.length||(e=[]),!c&&0!==c)return this.opts.element.val(""),this.updateSelection([]),this.clearSearch(),void(d&&this.triggerChange({added:this.data(),removed:e}));if(this.setVal(c),this.select)this.opts.initSelection(this.select,this.bind(this.updateSelection)),d&&this.triggerChange(this.buildChangeDetails(e,this.data()));else{if(this.opts.initSelection===b)throw new Error("val() cannot be called if initSelection() is not defined");this.opts.initSelection(this.opts.element,function(b){var c=a.map(b,f.id);f.setVal(c),f.updateSelection(b),f.clearSearch(),d&&f.triggerChange(f.buildChangeDetails(e,f.data()))})}this.clearSearch()},onSortStart:function(){if(this.select)throw new Error("Sorting of elements is not supported when attached to <select>. Attach to <input type='hidden'/> instead.");this.search.width(0),this.searchContainer.hide()},onSortEnd:function(){var b=[],c=this;this.searchContainer.show(),this.searchContainer.appendTo(this.searchContainer.parent()),this.resizeSearch(),this.selection.find(".select2-search-choice").each(function(){b.push(c.opts.id(a(this).data("select2-data")))}),this.setVal(b),this.triggerChange()},data:function(b,c){var d,e,f=this;return 0===arguments.length?this.selection.find(".select2-search-choice").map(function(){return a(this).data("select2-data")}).get():(e=this.data(),b||(b=[]),d=a.map(b,function(a){return f.opts.id(a)}),this.setVal(d),this.updateSelection(b),this.clearSearch(),c&&this.triggerChange(this.buildChangeDetails(e,this.data())),void 0)}}),a.fn.select2=function(){var c,e,f,g,h,i=Array.prototype.slice.call(arguments,0),j=["val","destroy","opened","open","close","focus","isFocused","container","dropdown","onSortStart","onSortEnd","enable","disable","readonly","positionDropdown","data","search"],k=["opened","isFocused","container","dropdown"],l=["val","data"],m={search:"externalSearch"};return this.each(function(){if(0===i.length||"object"==typeof i[0])c=0===i.length?{}:a.extend({},i[0]),c.element=a(this),"select"===c.element.get(0).tagName.toLowerCase()?h=c.element.prop("multiple"):(h=c.multiple||!1,"tags"in c&&(c.multiple=h=!0)),e=h?new G:new F,e.init(c);else{if("string"!=typeof i[0])throw"Invalid arguments to select2 plugin: "+i;if(d(i[0],j)<0)throw"Unknown method: "+i[0];if(g=b,e=a(this).data("select2"),e===b)return;if(f=i[0],"container"===f?g=e.container:"dropdown"===f?g=e.dropdown:(m[f]&&(f=m[f]),g=e[f].apply(e,i.slice(1))),d(i[0],k)>=0||d(i[0],l)&&1==i.length)return!1}}),g===b?this:g},a.fn.select2.defaults={width:"copy",loadMorePadding:0,closeOnSelect:!0,openOnEnter:!0,containerCss:{},dropdownCss:{},containerCssClass:"",dropdownCssClass:"",formatResult:function(a,b,c,d){var e=[];return t(a.text,c.term,e,d),e.join("")},formatSelection:function(a,c,d){return a?d(a.text):b},sortResults:function(a){return a},formatResultCssClass:function(){return b},formatSelectionCssClass:function(){return b},formatNoMatches:function(){return"No matches found"},formatInputTooShort:function(a,b){var c=b-a.length;return"Please enter "+c+" more character"+(1==c?"":"s")},formatInputTooLong:function(a,b){var c=a.length-b;return"Please delete "+c+" character"+(1==c?"":"s")},formatSelectionTooBig:function(a){return"You can only select "+a+" item"+(1==a?"":"s")},formatLoadMore:function(){return"Loading more results..."},formatSearching:function(){return"Searching..."},minimumResultsForSearch:0,minimumInputLength:0,maximumInputLength:null,maximumSelectionSize:0,id:function(a){return a.id},matcher:function(a,b){return c(""+b).toUpperCase().indexOf(c(""+a).toUpperCase())>=0},separator:",",tokenSeparators:[],tokenizer:B,escapeMarkup:u,blurOnChange:!1,selectOnBlur:!1,adaptContainerCssClass:function(a){return a},adaptDropdownCssClass:function(){return null},nextSearchTerm:function(){return b}},a.fn.select2.ajaxDefaults={transport:a.ajax,params:{type:"GET",cache:!1,dataType:"json"}},window.Select2={query:{ajax:v,local:w,tags:x},util:{debounce:k,markMatch:t,escapeMarkup:u,stripDiacritics:c},"class":{"abstract":E,single:F,multi:G}}}}(jQuery),window.Modernizr=function(a,b,c){function d(a){n.cssText=a}function e(a,b){return typeof a===b}var f,g,h,i="2.8.0",j={},k=b.documentElement,l="modernizr",m=b.createElement(l),n=m.style,o=({}.toString," -webkit- -moz- -o- -ms- ".split(" ")),p={},q=[],r=q.slice,s=function(a,c,d,e){var f,g,h,i,j=b.createElement("div"),m=b.body,n=m||b.createElement("body");if(parseInt(d,10))for(;d--;)h=b.createElement("div"),h.id=e?e[d]:l+(d+1),j.appendChild(h);return f=["&#173;",'<style id="s',l,'">',a,"</style>"].join(""),j.id=l,(m?j:n).innerHTML+=f,n.appendChild(j),m||(n.style.background="",n.style.overflow="hidden",i=k.style.overflow,k.style.overflow="hidden",k.appendChild(n)),g=c(j,a),m?j.parentNode.removeChild(j):(n.parentNode.removeChild(n),k.style.overflow=i),!!g},t={}.hasOwnProperty;h=e(t,"undefined")||e(t.call,"undefined")?function(a,b){return b in a&&e(a.constructor.prototype[b],"undefined")}:function(a,b){return t.call(a,b)},Function.prototype.bind||(Function.prototype.bind=function(a){var b=this;if("function"!=typeof b)throw new TypeError;var c=r.call(arguments,1),d=function(){if(this instanceof d){var e=function(){};e.prototype=b.prototype;var f=new e,g=b.apply(f,c.concat(r.call(arguments)));return Object(g)===g?g:f}return b.apply(a,c.concat(r.call(arguments)))};return d}),p.touch=function(){var c;return"ontouchstart"in a||a.DocumentTouch&&b instanceof DocumentTouch?c=!0:s(["@media (",o.join("touch-enabled),("),l,")","{#modernizr{top:9px;position:absolute}}"].join(""),function(a){c=9===a.offsetTop}),c};for(var u in p)h(p,u)&&(g=u.toLowerCase(),j[g]=p[u](),q.push((j[g]?"":"no-")+g));return j.addTest=function(a,b){if("object"==typeof a)for(var d in a)h(a,d)&&j.addTest(d,a[d]);else{if(a=a.toLowerCase(),j[a]!==c)return j;b="function"==typeof b?b():b,"undefined"!=typeof enableClasses&&enableClasses&&(k.className+=" "+(b?"":"no-")+a),j[a]=b}return j},d(""),m=f=null,j._version=i,j._prefixes=o,j.testStyles=s,j}(this,this.document),function(a){"use strict";a.fn.tooltip=function(b){var c=a.extend({},a.fn.tooltip.defaults,b),d=this.tipsy(c);if(c.hideOnClick&&("hover"==c.trigger||!c.trigger&&"hover"==this.tipsy.defaults.trigger)){var e=function(){a(this).tipsy("hide")};c.live?a(this.context).on("click.tipsy",this.selector,e):this.bind("click.tipsy",e)}return d},a.fn.tooltip.defaults={opacity:1,offset:1,delayIn:500,hoverable:!0,hideOnClick:!0}}(AJS.$),function(){function a(a){var c=b;a.find("th").each(function(a,b){var d=AJS.$(b);c.headers[a]={},d.hasClass("aui-table-column-unsortable")?c.headers[a].sorter=!1:(d.attr("tabindex","0"),d.wrapInner("<span class='aui-table-header-content'/>"),d.hasClass("aui-table-column-issue-key")&&(c.headers[a].sorter="issue-key"))}),a.tablesorter(c)}var b={sortMultiSortKey:"",headers:{},debug:!1};AJS.tablessortable={setup:function(){AJS.$.tablesorter.addParser({id:"issue-key",is:function(){return!1},format:function(a){var b=a.split("-"),c=b[0],d=b[1],e="..........",f="000000",g=(c+e).slice(0,e.length);return g+=(f+d).slice(-f.length)},type:"text"}),AJS.$(".aui-table-sortable").each(function(){a(AJS.$(this))})},setTableSortable:function(b){a(b)}},AJS.$(AJS.tablessortable.setup)}(),function(a){var b=a(document),c=function(c){var d={};return d.$trigger=a(c.currentTarget),d.$content=b.find("#"+d.$trigger.attr("aria-controls")),d.triggerIsParent=0!==d.$content.parent().filter(d.$trigger).length,d.$shortContent=d.triggerIsParent?d.$trigger.find(".aui-expander-short-content"):null,d.height=d.$content.css("min-height"),d.isCollapsible=d.$trigger.data("collapsible")!==!1,d.replaceText=d.$trigger.attr("data-replace-text"),d.replaceSelector=d.$trigger.data("replace-selector"),d},d=function(a){if(a.replaceText){var b=a.replaceSelector?a.$trigger.find(a.replaceSelector):a.$trigger;a.$trigger.attr("data-replace-text",b.text()),b.text(a.replaceText)}},e={"aui-expander-invoke":function(c){var d=a(c.currentTarget),e=b.find("#"+d.attr("aria-controls")),f=d.data("collapsible")!==!1;d.trigger("true"==e.attr("aria-expanded")&&f?"aui-expander-collapse":"aui-expander-expand")},"aui-expander-expand":function(a){var b=c(a);b.$content.attr("aria-expanded","true"),b.$content.outerHeight()>0&&b.$content.attr("aria-hidden","false"),d(b),b.triggerIsParent&&b.$shortContent.hide(),b.$trigger.trigger("aui-expander-expanded")},"aui-expander-collapse":function(a){{var b=c(a);parseInt(b.$content.css("line-height"),10),b.$content.children().first().height()}0===b.$content.outerHeight()&&b.$content.attr("aria-hidden","true"),d(b),b.$content.attr("aria-expanded","false"),b.triggerIsParent&&b.$shortContent.show(),b.$trigger.trigger("aui-expander-collapsed")},"click.aui-expander":function(b){var c=a(b.currentTarget);c.trigger("aui-expander-invoke",b.currentTarget)}};b.on(e,".aui-expander-trigger")}(jQuery),function(){function a(a,b,c){window.setTimeout(function(){a.css("width",100*c+"%"),b.attr("data-value",c)},0)}AJS.progressBars={update:function(b,c){var d=AJS.$(b).first(),e=d.children(".aui-progress-indicator-value"),f=e.attr("data-value")||0,g="aui-progress-indicator-after-update",h="aui-progress-indicator-before-update",i="transitionend webkitTransitionEnd",j=!d.attr("data-value");if(j&&e.detach().css("width",0).appendTo(d),"number"==typeof c&&1>=c&&c>=0){d.trigger(h,[f,c]);var k=document.body||document.documentElement,l=k.style;"string"==typeof l.transition||"string"==typeof l.WebkitTransition?(e.one(i,function(){d.trigger(g,[f,c])}),a(e,d,c)):(a(e,d,c),d.trigger(g,[f,c]))}return d},setIndeterminate:function(a){var b=AJS.$(a).first(),c=b.children(".aui-progress-indicator-value");b.removeAttr("data-value"),c.css("width","100%")}}}(),function(a){var b=a.fn.select2,c="aui-select2-container",d="aui-select2-drop aui-dropdown2 aui-style-default",e="aui-has-avatar";a.fn.auiSelect2=function(f){var g;if(a.isPlainObject(f)){var h=a.extend({},f),i=h.hasAvatar?" "+e:"";h.containerCssClass=c+i+(h.containerCssClass?" "+h.containerCssClass:""),h.dropdownCssClass=d+i+(h.dropdownCssClass?" "+h.dropdownCssClass:""),g=Array.prototype.slice.call(arguments,1),g.unshift(h)}else g=arguments.length?arguments:[{containerCssClass:c,dropdownCssClass:d}];return b.apply(this,g)}}(AJS.$),function(a){"use strict";function b(a,b){if(!b)return void console.warn("Attempting to notify a field without options");var d=b.type,e=b.message;e?z(a,e):o(a),c(a),n(a,d),f(a,d);var g=p(a)&&q(a)||!p(a);g&&v(a)}function c(a){r(a)||(g(a),i(a),s(a))}function d(a){var b=e(a),c={error:U,info:V};return c[b]}function e(a){return a.data(N)}function f(a,b){a.data(N,b)}function g(a){a.addClass(O),h(a)}function h(a){var b=t();a.after(b),y(a)?a.addClass("aui-field-has-invisible-icon"):b.addClass("aui-form-notification-icon-outside-field")}function i(a){A(a).tipsy({gravity:x(a),title:function(){return j(a)},trigger:"manual",offset:y(a)?$:_,opacity:Z,className:function(){return T+" "+d(a)},html:!0})}function j(a){var b=k(a);if(0===b.length)return"";if(1===b.length)return b[0];var c=b.map(function(a){return"<li>"+a+"</li>"});return"<ul>"+c.join("")+"</ul>"}function k(a){var b=a.data(K);return b?JSON.parse(b):[]}function l(a,b){var c=JSON.stringify(b);a.data(K,c)}function m(a){a.on("focusin",function(){v(a)}),a.on("focusout",function(){w(a)})}function n(a,b){var c={error:{icon:W,iconClass:P},wait:{icon:X},info:{icon:Y,iconClass:Q},none:{icon:"",iconClass:""}};c[b]||console.warn("Setting field icon for unknown type: "+b);var d=c[b].icon,e=c[b].iconClass||"";E(a,d),B(a,e)}function o(a){w(a),a.data(K,"")}function p(a){return a.is(":aui-focusable")}function q(a){return a.is(document.activeElement)}function r(a){return a.hasClass(O)}function s(a){u(a)&&m(a)}function t(){return a('<span class="aui-icon aui-icon-small '+S+'"/>')}function u(a){return a.is(":aui-focusable")}function v(a){A(a).tipsy("show")}function w(a){A(a).tipsy("hide")}function x(a){var b=a.data(L)||"side",c={side:"w",top:"se",bottom:"ne"},d=c[b];if(!d)throw d="w",new Error('Invalid notification position: "'+b+'". Valid options are "side", "bottom, "top"');return d}function y(a){var b=-1!==["text","password"].indexOf(a.attr("type"));return b}function z(a,b){if(b){var c=k(a),d=c.concat([b]);l(a,d)}}function A(a){return I(a)}function B(a,b){var c=I(a);C(c),D(c,b)}function C(a){var b=R.join(" ");a.removeClass(b)}function D(a,b){a.addClass(b)}function E(a,b){F(a,b),b?G(a):H(a)}function F(a,b){var c=a.data(M);a.data(M,b);var d=I(a);c&&d.removeClass(c),d.addClass(b)}function G(a){y(a)?(a.removeClass("aui-field-has-invisible-icon"),a.addClass("aui-field-has-icon")):I(a).removeClass("hidden")}function H(a){y(a)?(a.addClass("aui-field-has-invisible-icon"),a.removeClass("aui-field-has-icon")):I(a).addClass("hidden")}function I(a){return a.next("."+S)}var J="aui-form-notification",K=J+"-message",L=J+"-position",M=J+"-active-icon",N=J+"-type",O=J+"-initialised",P=J+"-icon-error",Q=J+"-icon-info",R=[P,Q],S="aui-icon-notification",T=J+"-tooltip",U=T+"-error",V=T+"-info",W="aui-iconfont-error",X="aui-icon-wait",Y="aui-iconfont-info",Z=1,$=7,_=3;AJS._notifyField=b}(AJS.$),function(a,b){"use strict";function c(a,b){var c;if("string"==typeof a)c=a;else{var e=d(a);if(e)return console.warn('Validators cannot be registered with the argument "'+e+'", as it is a reserved argument.'),!1;c="[data-aui-validate-"+a.join("],[data-aui-validate-")+"]"}var f={validatorFunction:b,validatorTrigger:c};return M.push(f),f}function d(b){var c=!1;return b.some(function(b){var d=-1!==a.inArray(b,D);return d&&(c=b),d}),c}function e(a){return a.hasClass(K)}function f(a){g(a),h(a),r(a,I)}function g(a){var b=s(a);b.addClass(K)}function h(a){i(a),j(a)}function i(a){var b,c=function(){a.trigger("aui-stop-typing")};a.on("keyup",function(){clearTimeout(b),b=setTimeout(c,1500)})}function j(a){var b=l(a,"when"),c=l(a,"watch"),d=c?a.add("#"+c):a;d.on(b,k(a))}function k(a){return function(){var b=l(a,"novalidate");b||m(a)}}function l(a,b){var c=a.data(C+b);return c||(c=l.defaults[b]),c}function m(b){var c=n(b);r(b,H);var d=o(b,c);a.when.apply(a,d).done(function(){r(b,G)})}function n(a){var b=[];return M.forEach(function(c,d){var e=c.validatorTrigger,f=a.is(e);f&&b.push(d)}),b}function o(b,c){var d=[];return c.forEach(function(c){var e=M[c].validatorFunction,f=new a.Deferred,g=p(b,f);e(g),d.push(f)}),d}function p(a,b){return{validate:function(){b.resolve()},invalidate:function(c){r(a,F,c),b.reject()},args:q(a),$el:a}}function q(a){return function(b){return a.data("aui-validate-"+b)}}function r(b,c,d){if(b.attr("data-"+E,c),c!==I){b.trigger(a.Event(L));var e=s(b),f={};f[H]="wait",f[F]="error",f[G]="none";var g=f[c];AJS._notifyField(e,{type:g,message:d})}}function s(b){var c=l(b,"displayfield"),d=void 0===c;return d?b:a("#"+c)}function t(a){return a.attr("data-"+E)}function u(a){k(a)()}function v(a,b){b.preventDefault();var c=w(a)===H;c?a.one(L,function(){a.trigger("submit")}):a.trigger("submit")}function w(a){var b=a.find("."+K),c=x(b),d=y(c);return d}function x(b){var c=a.map(b,function(b){return t(a(b))});return c}function y(a){var b=-1!==a.indexOf(F),c=-1!==a.indexOf(I),d=-1!==a.indexOf(H),e=-1!==a.indexOf(G);return b?F:c?I:d?H:e?G:void 0}function z(b){var c=B(b,I);c.each(function(b,c){AJS.validator.validate(a(c))})}function A(a){var b=B(a,F).first();b.focus()}function B(a,b){var c="[data-"+E+"="+b+"]";return a.find(c)}var C="aui-validate-",D=["displayfield","watch","when","novalidate","state"],E="aui-validate-state",F="invalid",G="valid",H="validating",I="unvalidated",J="data-aui-field",K="aui-validation-field",L="_aui-internal-field-state-changed",M=[];b(J,{ready:function(b){var c=a(b);e(c)||f(c)},type:b.types.ATTR}),l.defaults={when:"change"},a(document).on("submit",function(b){var c=b.target,d=a(c),e=w(d);if(e===I)z(d),v(d,b);else if(e===H)v(d,b);else if(e===F)b.preventDefault(),A(d);else if(e===G){var f=a.Event("aui-valid-submit");d.trigger(f);var g=f.isDefaultPrevented();g&&b.preventDefault()}}),AJS.validator={register:c,validate:u}}(AJS.$,window.skate||require("skate")),function(a){"use strict";function b(a,b,c,d){var e=void 0!==AJS.I18n.keys;e&&(c=AJS.I18n.keys["aui.validation.message."+a]),d||(d=[b(a)]);var f,g=b(a+"-msg");return f=g?[g].concat(d):[c].concat(d),AJS.format.apply(null,f)}function c(a,b){var c=a.match(b);if(!c)return!1;var d=a===c[0];return d}AJS.validator.register(["maxlength","minlength"],function(a){var c=b("minlength",a.args,AJS.I18n.getText("aui.validation.message.minlength")),d=b("maxlength",a.args,AJS.I18n.getText("aui.validation.message.maxlength"));a.$el.val().length<a.args("minlength")?a.invalidate(c):a.$el.val().length>a.args("maxlength")?a.invalidate(d):a.validate()}),AJS.validator.register(["matchingfield"],function(c){var d=c.$el.val(),e=a("#"+c.args("matchingfield")),f=e.val(),g=b("matchingfield",c.args,AJS.I18n.getText("aui.validation.message.matchingfield"),[d,f]);d&&f&&f!==d?c.invalidate(g):c.validate()}),AJS.validator.register(["doesnotcontain"],function(a){var c=b("doesnotcontain",a.args,AJS.I18n.getText("aui.validation.message.doesnotcontain"));-1===a.$el.val().indexOf(a.args("doesnotcontain"))?a.validate():a.invalidate(c)}),AJS.validator.register(["pattern"],function(a){var d=b("pattern",a.args,AJS.I18n.getText("aui.validation.message.pattern"));c(a.$el.val(),new RegExp(a.args("pattern"),"i"))?a.validate():a.invalidate(d)}),AJS.validator.register(["required"],function(a){var c=b("required",a.args,AJS.I18n.getText("aui.validation.message.required"));a.$el.val()?a.validate():a.invalidate(c)}),AJS.validator.register(["min","max"],function(a){var c=b("validnumber",a.args,AJS.I18n.getText("aui.validation.message.validnumber")),d=b("min",a.args,AJS.I18n.getText("aui.validation.message.min")),e=b("max",a.args,AJS.I18n.getText("aui.validation.message.max")),f=parseInt(a.$el.val());return isNaN(f)?void a.invalidate(c):void(a.args("min")&&f<parseInt(a.args("min"))?a.invalidate(d):a.args("max")&&f>parseInt(a.args("max"))?a.invalidate(e):a.validate())}),AJS.validator.register(["dateformat"],function(a){var d=a.args("dateformat"),e=b("dateformat",a.args,AJS.I18n.getText("aui.validation.message.dateformat")),f={Y:"[0-9]{4}",y:"[0-9]{2}",m:"(11|12|0{0,1}[0-9])",M:"[Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec]",D:"[Mon|Tue|Wed|Thu|Fri|Sat|Sun]",d:"([0-2]{0,1}[0-9]{1})|(30|31)"},g=d.split(""),h="";g.forEach(function(a){var b=f.hasOwnProperty(a);h+=b?f[a]:a});var i=new RegExp(h+"$","i"),j=c(a.$el.val(),i);j?a.validate():a.invalidate(e)}),AJS.validator.register(["minchecked","maxchecked"],function(a){var c=a.$el.find(":checked").length,d=!a.args("minchecked")||c>=a.args("minchecked"),e=!a.args("maxchecked")||c<=a.args("maxchecked"),f=b("minchecked",a.args,AJS.I18n.getText("aui.validation.message.minchecked")),g=b("maxchecked",a.args,AJS.I18n.getText("aui.validation.message.maxchecked"));d&&e?a.validate():d?e||a.invalidate(g):a.invalidate(f)})}(AJS.$),function(a){"use strict";function b(b){this.$el=a(b).closest(".aui-nav"),this.$treeParent=this.$el.parent("li[aria-expanded]"),this.$subtreeToggleIcon=this.$treeParent.children(".aui-nav-subtree-toggle").children("span.aui-icon")}b.prototype.isNested=function(){return 1===this.$treeParent.length},b.prototype.isCollapsed=function(){return"false"===this.$treeParent.attr("aria-expanded")},b.prototype.expand=function(){return this.$treeParent.attr("aria-expanded","true"),this.$subtreeToggleIcon.removeClass("aui-iconfont-collapsed").addClass("aui-iconfont-expanded"),this},b.prototype.collapse=function(){return this.$treeParent.attr("aria-expanded","false"),this.$subtreeToggleIcon.removeClass("aui-iconfont-expanded").addClass("aui-iconfont-collapsed"),this},b.prototype.toggle=function(){return this.isCollapsed()?this.expand():this.collapse(),this},AJS.navigation=AJS._internal.widget("navigation",b),a(function(a){a(document).on("click",".aui-nav li[aria-expanded]",function(b){var c=a(b.target),d=c.closest("li[aria-expanded]")[0]!==this;if(!d){var e=c.closest(".aui-nav-subtree-toggle",this).length>0;e&&b.preventDefault();var f=AJS.navigation(a(this).children(".aui-nav"));f.toggle()}})})}(AJS.$),function(a){"use strict";function b(a){return a.offset().top}function c(b){this.$body=a("body"),this.$el=a(b),this.$wrapper=this.$el.children(".aui-sidebar-wrapper"),this.submenus=new d,this.$body.addClass("aui-page-sidebar"),this._previousScrollTop=null,this._previousViewportHeight=null,this._previousViewportWidth=null,this._previousOffsetTop=null}function d(){this.inlineDialog=AJS.InlineDialog(a(),"sidebar-submenu",this.inlineDialogShowHandler.bind(this),{noBind:!0,addActiveClass:!1,hideCallback:this.inlineDialogHideHandler.bind(this),gravity:"w",offsetY:function(a,b){var c=b.target.height()/2,d=a.height()/2;return d-c-this.submenuHeadingHeight()}.bind(this),arrowOffsetY:function(a,b){var c=b.target.height()/2,d=a.height()/2;return-d+this.submenuHeadingHeight()+c}.bind(this)}),this.$trigger=null,this.$placeholder=null,this.$placeholderSubmenu=null,this.postHideCallback=null}function e(a){a.tipsy(k).tipsy("show");var b=a.data("tipsy")&&a.data("tipsy").$tip;b&&b.css({opacity:""}).addClass("tooltip-shown")}function f(a){var b=a.data("tipsy")&&a.data("tipsy").$tip;b&&(b.on("transitionend",function(){a.tipsy("hide")}),b.removeClass("tooltip-shown"))}var g="undefined"!=typeof document.documentElement.style.transition||"undefined"!=typeof document.documentElement.style.webkitTransition,h=1280,i="_aui-internal-sidebar-";c.prototype.on=function(){var b=arguments[0],c=Array.prototype.slice.call(arguments,1),d=a.map(b.split(" "),function(a){return i+a}).join(" ");return this.$el.on.apply(this.$el,[d].concat(c)),this},c.prototype.setHeight=function(a,c,d){a=a||window.pageYOffset,c=c||window.innerHeight,d=d||b(this.$el);var e=Math.max(0,d-a);return this.$wrapper.height(c-e),this},c.prototype.setPosition=function(a){return a=a||window.pageYOffset,this.$wrapper.toggleClass("aui-is-docked",a>b(this.$el)),this},c.prototype.setCollapsedState=function(b){var c={collapsed:{},expanded:{}};c.collapsed.narrow={narrow:a.noop,wide:function(a){a._expand(b)}},c.collapsed.wide={narrow:a.noop,wide:a.noop},c.expanded.narrow={narrow:a.noop,wide:function(a){a.$body.removeClass("aui-sidebar-collapsed"),a.$el.removeClass("aui-sidebar-fly-out")}},c.expanded.wide={narrow:function(a){a.collapse()},wide:a.noop};var d=this.isCollapsed()?"collapsed":"expanded",e=this.isViewportNarrow(this._previousViewportWidth)?"narrow":"wide",f=this.isViewportNarrow(b)?"narrow":"wide";return c[d][e][f](this),this},c.prototype.collapse=function(){return this.$el.trigger(a.Event(i+"collapse-start")),this.$body.addClass("aui-sidebar-collapsed"),this.$el.attr("aria-expanded","false"),this.$el.removeClass("aui-sidebar-fly-out"),this.isAnimated()||this.$el.trigger(a.Event(i+"collapse-end")),this},c.prototype._expand=function(b){this.$el.trigger(a.Event(i+"expand-start"));var c=this.isViewportNarrow(b);return this.$el.attr("aria-expanded","true"),this.$body.toggleClass("aui-sidebar-collapsed",c),this.$el.toggleClass("aui-sidebar-fly-out",c),this.isAnimated()||this.$el.trigger(a.Event(i+"expand-end")),this},c.prototype.expand=function(){return this._expand(this._previousViewportWidth),this},c.prototype.isAnimated=function(){return g&&this.$el.hasClass("aui-is-animated")},c.prototype.isCollapsed=function(){return"false"===this.$el.attr("aria-expanded")},c.prototype.isViewportNarrow=function(a){return a=void 0===a?this._previousViewportWidth:a,h>a},c.prototype.reflow=function(){var a=window.pageYOffset,c=window.innerHeight,d=window.innerWidth,e=b(this.$el);(a!==this._previousScrollTop||c!==this._previousViewportHeight||e!==this._previousOffsetTop)&&(this.$body.hasClass("aui-page-sidebar-touch")||(this.setHeight(a,c,e),this.setPosition(a)));var f="false"!==this.$el.attr("data-aui-responsive");if(f){var g=null===this._previousViewportWidth;if(g){if(!this.isCollapsed()&&this.isViewportNarrow(d)){var h=this.isAnimated();h&&this.$el.removeClass("aui-is-animated"),this.collapse(),h&&(this.$el[0].offsetHeight,this.$el.addClass("aui-is-animated"))}}else d!==this._previousViewportWidth&&this.setCollapsedState(d)}else{var i=!this.isCollapsed()&&this.isViewportNarrow(d);this.$el.toggleClass("aui-sidebar-fly-out",i)}return this._previousScrollTop=a,this._previousViewportHeight=c,this._previousViewportWidth=d,this._previousOffsetTop=e,this},c.prototype.toggle=function(){return this.isCollapsed()?this.submenus.isShowing()?this.submenus.hide(this.expand.bind(this)):(this.expand(),a(".aui-sidebar-section-tooltip").remove()):this.collapse(),this},c.prototype.collapsedTriggersSelector=function(){return[".aui-sidebar-group:not(.aui-sidebar-group-tier-one)",".aui-sidebar-group.aui-sidebar-group-tier-one > .aui-nav > li > a",".aui-sidebar-footer > .aui-sidebar-settings-button"].join(", ")},d.prototype.submenu=function(a){return a.is("a")?a.next(".aui-nav"):a.children(".aui-nav")},d.prototype.hasSubmenu=function(a){return 0!==this.submenu(a).length},d.prototype.submenuHeadingHeight=function(){return 34},d.prototype.isShowing=function(){return null!==this.$trigger},d.prototype.show=function(a,b){var c=this.isShowing();return this.inlineDialog.show(a,b),c&&this.inlineDialog.refresh(),this},d.prototype.hide=function(a){return void 0!==a&&(this.postHideCallback=a),this.inlineDialog.hide(),this};var j='<div class="aui-sidebar-submenu"><div class="aui-navgroup aui-navgroup-vertical"><div class="aui-navgroup-inner"><div class="aui-nav-heading"><strong></strong></div></div></div></div>';d.prototype.inlineDialogShowHandler=function(b,c,d){this.isShowing()&&(this.restoreSubmenu(),this.$trigger.removeClass("active")),this.$trigger=a(c).is(".aui-sidebar-group")?a(c):a(c).closest("a"),this.$trigger.addClass("active");var e=this.$trigger.is("a")?this.$trigger.text():this.$trigger.children(".aui-nav-heading").text();b.html(j);var f=b.find(".aui-navgroup-inner");f.children(".aui-nav-heading").attr("title",e).children("strong").text(e),this.moveSubmenuToInlineDialog(this.submenu(this.$trigger)),d()},d.prototype.inlineDialogHideHandler=function(){this.restoreSubmenu(),this.$trigger.removeClass("active"),this.$trigger=null,null!==this.postHideCallback&&(this.postHideCallback(),this.postHideCallback=null) },d.prototype.moveSubmenuToInlineDialog=function(b){return this.$placeholder=a("<!-- placholder -->"),this.$placeholderSubmenu=b,b.replaceWith(this.$placeholder),this.inlineDialog.find(".aui-navgroup-inner").append(b),this},d.prototype.restoreSubmenu=function(){return this.$placeholder.replaceWith(this.$placeholderSubmenu),delete this.$placeholder,delete this.$placeholderSubmenu,this};var k={trigger:"manual",gravity:"w",className:"aui-sidebar-section-tooltip",title:function(){var b=a(this);return b.is("a")?b.attr("title")||b.find(".aui-nav-item-label").text()||b.data("tooltip"):b.children(".aui-nav").attr("title")||b.children(".aui-nav-heading").text()}};AJS.sidebar=AJS._internal.widget("sidebar",c),a(function(a){var b=a(".aui-sidebar");if(b.length){Modernizr.touch&&a("body").addClass("aui-page-sidebar-touch");var d=new c(b),g=null;a(window).on("scroll resize",function(){null===g&&(g=requestAnimationFrame(function(){d.reflow(),g=null}))}),d.reflow(),d.isAnimated()&&d.$el.on("transitionend webkitTransitionEnd",function(){d.$el.trigger(a.Event(i+(d.isCollapsed()?"collapse-end":"expand-end")))}),d.$el.on("click",".aui-sidebar-toggle",function(a){a.preventDefault(),d.toggle()}),d.$el.on("click",".aui-sidebar-body",function(b){a(b.target).is(".aui-sidebar-body")&&(b.preventDefault(),d.toggle())}),a(".aui-page-panel").click(function(){!d.isCollapsed()&&d.isViewportNarrow()&&d.collapse()}),AJS.whenIType("[").execute(function(){d.toggle()}),d.$el.on("touchend",function(a){d.isCollapsed()&&(d.expand(),a.preventDefault())}),d.$el.on("mouseenter focus",d.collapsedTriggersSelector(),function(){d.isCollapsed()&&e(a(this))}),d.$el.on("click blur mouseleave",d.collapsedTriggersSelector(),function(){d.isCollapsed()&&f(a(this))}),d.$el.on("mouseenter focus",".aui-sidebar-footer > .aui-sidebar-toggle",function(){var b=a(this);d.isCollapsed()?b.data("tooltip",AJS.I18n.getText("aui.sidebar.expand.tooltip")):b.data("tooltip",AJS.I18n.getText("aui.sidebar.collapse.tooltip")),e(b)}),d.$el.on("click blur mouseleave",".aui-sidebar-footer > .aui-sidebar-toggle",function(){f(a(this))}),d.$el.on("click",d.collapsedTriggersSelector(),function(b){if(d.isCollapsed()){var c=a(this);d.submenus.hasSubmenu(c)&&(b.preventDefault(),d.submenus.show(b,this))}}),d.$el.find(".aui-sidebar-body").on("mouseenter mouseover mouseleave",function(b){d.$el.toggleClass("aui-is-hover",("mouseover"===b.type||"mouseenter"===b.type)&&!a(b.srcElement||b.target).parentsUntil(d.$el).filter(".aui-page-header, .aui-navgroup").length)})}})}(AJS.$);var goog=goog||{};goog.inherits=function(a,b){function c(){}c.prototype=b.prototype,a.superClass_=b.prototype,a.prototype=new c,a.prototype.constructor=a},goog.userAgent||(goog.userAgent=function(){var a="";"undefined"!=typeof navigator&&navigator&&"string"==typeof navigator.userAgent&&(a=navigator.userAgent);var b=0==a.indexOf("Opera");return{HAS_JSCRIPT:"string"in this,IS_OPERA:b,IS_IE:!b&&-1!=a.indexOf("MSIE"),IS_WEBKIT:!b&&-1!=a.indexOf("WebKit")}}()),goog.asserts||(goog.asserts={fail:function(){}}),goog.dom||(goog.dom={},goog.dom.DomHelper=function(a){this.document_=a||document},goog.dom.DomHelper.prototype.getDocument=function(){return this.document_},goog.dom.DomHelper.prototype.createElement=function(a){return this.document_.createElement(a)},goog.dom.DomHelper.prototype.createDocumentFragment=function(){return this.document_.createDocumentFragment()}),goog.format||(goog.format={insertWordBreaks:function(a,b){a=String(a);for(var c=[],d=0,e=!1,f=!1,g=0,h=0,i=0,j=a.length;j>i;++i){var k=a.charCodeAt(i);if(g>=b&&32!=k&&(c[d++]=a.substring(h,i),h=i,c[d++]=goog.format.WORD_BREAK,g=0),e)62==k&&(e=!1);else if(f)switch(k){case 59:f=!1,++g;break;case 60:f=!1,e=!0;break;case 32:f=!1,g=0}else switch(k){case 60:e=!0;break;case 38:f=!0;break;case 32:g=0;break;default:++g}}return c[d++]=a.substring(h),c.join("")},WORD_BREAK:goog.userAgent.IS_WEBKIT?"<wbr></wbr>":goog.userAgent.IS_OPERA?"&shy;":"<wbr>"}),goog.i18n||(goog.i18n={bidi:{detectRtlDirectionality:function(a,b){return a=soyshim.$$bidiStripHtmlIfNecessary_(a,b),soyshim.$$bidiRtlWordRatio_(a)>soyshim.$$bidiRtlDetectionThreshold_}}}),goog.i18n.bidi.Dir={RTL:-1,UNKNOWN:0,LTR:1},goog.i18n.bidi.toDir=function(a){return"number"==typeof a?a>0?goog.i18n.bidi.Dir.LTR:0>a?goog.i18n.bidi.Dir.RTL:goog.i18n.bidi.Dir.UNKNOWN:a?goog.i18n.bidi.Dir.RTL:goog.i18n.bidi.Dir.LTR},goog.i18n.BidiFormatter=function(a){this.dir_=goog.i18n.bidi.toDir(a)},goog.i18n.BidiFormatter.prototype.dirAttr=function(a,b){var c=soy.$$bidiTextDir(a,b);return c&&c!=this.dir_?0>c?"dir=rtl":"dir=ltr":""},goog.i18n.BidiFormatter.prototype.endEdge=function(){return this.dir_<0?"left":"right"},goog.i18n.BidiFormatter.prototype.mark=function(){return this.dir_>0?"\u200e":this.dir_<0?"\u200f":""},goog.i18n.BidiFormatter.prototype.markAfter=function(a,b){var c=soy.$$bidiTextDir(a,b);return soyshim.$$bidiMarkAfterKnownDir_(this.dir_,c,a,b)},goog.i18n.BidiFormatter.prototype.spanWrap=function(a){a=String(a);var b=soy.$$bidiTextDir(a,!0),c=soyshim.$$bidiMarkAfterKnownDir_(this.dir_,b,a,!0);return b>0&&this.dir_<=0?a="<span dir=ltr>"+a+"</span>":0>b&&this.dir_>=0&&(a="<span dir=rtl>"+a+"</span>"),a+c},goog.i18n.BidiFormatter.prototype.startEdge=function(){return this.dir_<0?"right":"left"},goog.i18n.BidiFormatter.prototype.unicodeWrap=function(a){a=String(a);var b=soy.$$bidiTextDir(a,!0),c=soyshim.$$bidiMarkAfterKnownDir_(this.dir_,b,a,!0);return b>0&&this.dir_<=0?a="\u202a"+a+"\u202c":0>b&&this.dir_>=0&&(a="\u202b"+a+"\u202c"),a+c},goog.string={newLineToBr:function(a,b){return a=String(a),goog.string.NEWLINE_TO_BR_RE_.test(a)?a.replace(/(\r\n|\r|\n)/g,b?"<br />":"<br>"):a},urlEncode:encodeURIComponent,NEWLINE_TO_BR_RE_:/[\r\n]/},goog.string.StringBuffer=function(a){this.buffer_=goog.userAgent.HAS_JSCRIPT?[]:"",null!=a&&this.append.apply(this,arguments)},goog.string.StringBuffer.prototype.bufferLength_=0,goog.string.StringBuffer.prototype.append=function(a,b){if(goog.userAgent.HAS_JSCRIPT)if(null==b)this.buffer_[this.bufferLength_++]=a;else{var c=this.buffer_;c.push.apply(c,arguments),this.bufferLength_=this.buffer_.length}else if(this.buffer_+=a,null!=b)for(var d=1;d<arguments.length;d++)this.buffer_+=arguments[d];return this},goog.string.StringBuffer.prototype.clear=function(){goog.userAgent.HAS_JSCRIPT?(this.buffer_.length=0,this.bufferLength_=0):this.buffer_=""},goog.string.StringBuffer.prototype.toString=function(){if(goog.userAgent.HAS_JSCRIPT){var a=this.buffer_.join("");return this.clear(),a&&this.append(a),a}return this.buffer_},goog.soy||(goog.soy={renderAsElement:function(a,b,c,d){return soyshim.$$renderWithWrapper_(a,b,d,!0,c)},renderAsFragment:function(a,b,c,d){return soyshim.$$renderWithWrapper_(a,b,d,!1,c)},renderElement:function(a,b,c,d){a.innerHTML=b(c,null,d)}});var soy={esc:{}},soydata={},soyshim={$$DEFAULT_TEMPLATE_DATA_:{}};if(soyshim.$$renderWithWrapper_=function(a,b,c,d,e){var f=c||document,g=f.createElement("div");if(g.innerHTML=a(b||soyshim.$$DEFAULT_TEMPLATE_DATA_,void 0,e),1==g.childNodes.length){var h=g.firstChild;if(!d||1==h.nodeType)return h}if(d)return g;for(var i=f.createDocumentFragment();g.firstChild;)i.appendChild(g.firstChild);return i},soyshim.$$bidiMarkAfterKnownDir_=function(a,b,c,d){return a>0&&(0>b||soyshim.$$bidiIsRtlExitText_(c,d))?"\u200e":0>a&&(b>0||soyshim.$$bidiIsLtrExitText_(c,d))?"\u200f":""},soyshim.$$bidiStripHtmlIfNecessary_=function(a,b){return b?a.replace(soyshim.$$BIDI_HTML_SKIP_RE_," "):a},soyshim.$$BIDI_HTML_SKIP_RE_=/<[^>]*>|&[^;]+;/g,soyshim.$$bidiLtrChars_="A-Za-z\xc0-\xd6\xd8-\xf6\xf8-\u02b8\u0300-\u0590\u0800-\u1fff\u2c00-\ufb1c\ufdfe-\ufe6f\ufefd-\uffff",soyshim.$$bidiNeutralChars_="\x00- !-@[-`{-\xbf\xd7\xf7\u02b9-\u02ff\u2000-\u2bff",soyshim.$$bidiRtlChars_="\u0591-\u07ff\ufb1d-\ufdfd\ufe70-\ufefc",soyshim.$$bidiRtlDirCheckRe_=new RegExp("^[^"+soyshim.$$bidiLtrChars_+"]*["+soyshim.$$bidiRtlChars_+"]"),soyshim.$$bidiNeutralDirCheckRe_=new RegExp("^["+soyshim.$$bidiNeutralChars_+"]*$|^http://"),soyshim.$$bidiIsRtlText_=function(a){return soyshim.$$bidiRtlDirCheckRe_.test(a)},soyshim.$$bidiIsNeutralText_=function(a){return soyshim.$$bidiNeutralDirCheckRe_.test(a)},soyshim.$$bidiRtlDetectionThreshold_=.4,soyshim.$$bidiRtlWordRatio_=function(a){for(var b=0,c=0,d=a.split(" "),e=0;e<d.length;e++)soyshim.$$bidiIsRtlText_(d[e])?(b++,c++):soyshim.$$bidiIsNeutralText_(d[e])||c++;return 0==c?0:b/c},soyshim.$$bidiLtrExitDirCheckRe_=new RegExp("["+soyshim.$$bidiLtrChars_+"][^"+soyshim.$$bidiRtlChars_+"]*$"),soyshim.$$bidiRtlExitDirCheckRe_=new RegExp("["+soyshim.$$bidiRtlChars_+"][^"+soyshim.$$bidiLtrChars_+"]*$"),soyshim.$$bidiIsLtrExitText_=function(a,b){return a=soyshim.$$bidiStripHtmlIfNecessary_(a,b),soyshim.$$bidiLtrExitDirCheckRe_.test(a)},soyshim.$$bidiIsRtlExitText_=function(a,b){return a=soyshim.$$bidiStripHtmlIfNecessary_(a,b),soyshim.$$bidiRtlExitDirCheckRe_.test(a)},soy.StringBuilder=goog.string.StringBuffer,soydata.SanitizedContentKind={HTML:0,JS_STR_CHARS:1,URI:2,HTML_ATTRIBUTE:3},soydata.SanitizedContent=function(a){this.content=a},soydata.SanitizedContent.prototype.contentKind,soydata.SanitizedContent.prototype.toString=function(){return this.content},soydata.SanitizedHtml=function(a){soydata.SanitizedContent.call(this,a)},goog.inherits(soydata.SanitizedHtml,soydata.SanitizedContent),soydata.SanitizedHtml.prototype.contentKind=soydata.SanitizedContentKind.HTML,soydata.SanitizedJsStrChars=function(a){soydata.SanitizedContent.call(this,a)},goog.inherits(soydata.SanitizedJsStrChars,soydata.SanitizedContent),soydata.SanitizedJsStrChars.prototype.contentKind=soydata.SanitizedContentKind.JS_STR_CHARS,soydata.SanitizedUri=function(a){soydata.SanitizedContent.call(this,a)},goog.inherits(soydata.SanitizedUri,soydata.SanitizedContent),soydata.SanitizedUri.prototype.contentKind=soydata.SanitizedContentKind.URI,soydata.SanitizedHtmlAttribute=function(a){soydata.SanitizedContent.call(this,a)},goog.inherits(soydata.SanitizedHtmlAttribute,soydata.SanitizedContent),soydata.SanitizedHtmlAttribute.prototype.contentKind=soydata.SanitizedContentKind.HTML_ATTRIBUTE,soy.renderElement=goog.soy.renderElement,soy.renderAsFragment=function(a,b,c,d){return goog.soy.renderAsFragment(a,b,d,new goog.dom.DomHelper(c))},soy.renderAsElement=function(a,b,c,d){return goog.soy.renderAsElement(a,b,d,new goog.dom.DomHelper(c))},soy.$$augmentData=function(a,b){function c(){}c.prototype=a;var d=new c;for(var e in b)d[e]=b[e];return d},soy.$$getMapKeys=function(a){var b=[];for(var c in a)b.push(c);return b},soy.$$getDelegateId=function(a){return a},soy.$$DELEGATE_REGISTRY_PRIORITIES_={},soy.$$DELEGATE_REGISTRY_FUNCTIONS_={},soy.$$registerDelegateFn=function(a,b,c){var d="key_"+a,e=soy.$$DELEGATE_REGISTRY_PRIORITIES_[d];if(void 0===e||b>e)soy.$$DELEGATE_REGISTRY_PRIORITIES_[d]=b,soy.$$DELEGATE_REGISTRY_FUNCTIONS_[d]=c;else if(b==e)throw Error('Encountered two active delegates with same priority (id/name "'+a+'").')},soy.$$getDelegateFn=function(a){var b=soy.$$DELEGATE_REGISTRY_FUNCTIONS_["key_"+a];return b?b:soy.$$EMPTY_TEMPLATE_FN_},soy.$$EMPTY_TEMPLATE_FN_=function(){return""},soy.$$escapeHtml=function(a){return"object"==typeof a&&a&&a.contentKind===soydata.SanitizedContentKind.HTML?a.content:soy.esc.$$escapeHtmlHelper(a)},soy.$$escapeHtmlRcdata=function(a){return"object"==typeof a&&a&&a.contentKind===soydata.SanitizedContentKind.HTML?soy.esc.$$normalizeHtmlHelper(a.content):soy.esc.$$escapeHtmlHelper(a)},soy.$$stripHtmlTags=function(a){return String(a).replace(soy.esc.$$HTML_TAG_REGEX_,"")},soy.$$escapeHtmlAttribute=function(a){return"object"==typeof a&&a&&a.contentKind===soydata.SanitizedContentKind.HTML?soy.esc.$$normalizeHtmlHelper(soy.$$stripHtmlTags(a.content)):soy.esc.$$escapeHtmlHelper(a)},soy.$$escapeHtmlAttributeNospace=function(a){return"object"==typeof a&&a&&a.contentKind===soydata.SanitizedContentKind.HTML?soy.esc.$$normalizeHtmlNospaceHelper(soy.$$stripHtmlTags(a.content)):soy.esc.$$escapeHtmlNospaceHelper(a)},soy.$$filterHtmlAttribute=function(a){return"object"==typeof a&&a&&a.contentKind===soydata.SanitizedContentKind.HTML_ATTRIBUTE?a.content.replace(/=([^"']*)$/,'="$1"'):soy.esc.$$filterHtmlAttributeHelper(a)},soy.$$filterHtmlElementName=function(a){return soy.esc.$$filterHtmlElementNameHelper(a)},soy.$$escapeJs=function(a){return soy.$$escapeJsString(a)},soy.$$escapeJsString=function(a){return"object"==typeof a&&a.contentKind===soydata.SanitizedContentKind.JS_STR_CHARS?a.content:soy.esc.$$escapeJsStringHelper(a)},soy.$$escapeJsValue=function(a){if(null==a)return" null ";switch(typeof a){case"boolean":case"number":return" "+a+" ";default:return"'"+soy.esc.$$escapeJsStringHelper(String(a))+"'"}},soy.$$escapeJsRegex=function(a){return soy.esc.$$escapeJsRegexHelper(a)},soy.$$problematicUriMarks_=/['()]/g,soy.$$pctEncode_=function(a){return"%"+a.charCodeAt(0).toString(16)},soy.$$escapeUri=function(a){if("object"==typeof a&&a.contentKind===soydata.SanitizedContentKind.URI)return soy.$$normalizeUri(a);var b=soy.esc.$$escapeUriHelper(a);return soy.$$problematicUriMarks_.lastIndex=0,soy.$$problematicUriMarks_.test(b)?b.replace(soy.$$problematicUriMarks_,soy.$$pctEncode_):b},soy.$$normalizeUri=function(a){return soy.esc.$$normalizeUriHelper(a)},soy.$$filterNormalizeUri=function(a){return soy.esc.$$filterNormalizeUriHelper(a)},soy.$$escapeCssString=function(a){return soy.esc.$$escapeCssStringHelper(a)},soy.$$filterCssValue=function(a){return null==a?"":soy.esc.$$filterCssValueHelper(a)},soy.$$changeNewlineToBr=function(a){return goog.string.newLineToBr(String(a),!1)},soy.$$insertWordBreaks=function(a,b){return goog.format.insertWordBreaks(String(a),b)},soy.$$truncate=function(a,b,c){return a=String(a),a.length<=b?a:(c&&(b>3?b-=3:c=!1),soy.$$isHighSurrogate_(a.charAt(b-1))&&soy.$$isLowSurrogate_(a.charAt(b))&&(b-=1),a=a.substring(0,b),c&&(a+="..."),a)},soy.$$isHighSurrogate_=function(a){return a>=55296&&56319>=a},soy.$$isLowSurrogate_=function(a){return a>=56320&&57343>=a},soy.$$bidiFormatterCache_={},soy.$$getBidiFormatterInstance_=function(a){return soy.$$bidiFormatterCache_[a]||(soy.$$bidiFormatterCache_[a]=new goog.i18n.BidiFormatter(a))},soy.$$bidiTextDir=function(a,b){return a?goog.i18n.bidi.detectRtlDirectionality(a,b)?-1:1:0},soy.$$bidiDirAttr=function(a,b,c){return new soydata.SanitizedHtmlAttribute(soy.$$getBidiFormatterInstance_(a).dirAttr(b,c))},soy.$$bidiMarkAfter=function(a,b,c){var d=soy.$$getBidiFormatterInstance_(a);return d.markAfter(b,c)},soy.$$bidiSpanWrap=function(a,b){var c=soy.$$getBidiFormatterInstance_(a);return c.spanWrap(b+"",!0)},soy.$$bidiUnicodeWrap=function(a,b){var c=soy.$$getBidiFormatterInstance_(a);return c.unicodeWrap(b+"",!0)},soy.esc.$$escapeUriHelper=function(a){return encodeURIComponent(String(a))},soy.esc.$$ESCAPE_MAP_FOR_ESCAPE_HTML__AND__NORMALIZE_HTML__AND__ESCAPE_HTML_NOSPACE__AND__NORMALIZE_HTML_NOSPACE_={"\x00":"&#0;",'"':"&quot;","&":"&amp;","'":"&#39;","<":"&lt;",">":"&gt;"," ":"&#9;","\n":"&#10;"," ":"&#11;","\f":"&#12;","\r":"&#13;"," ":"&#32;","-":"&#45;","/":"&#47;","=":"&#61;","`":"&#96;","\x85":"&#133;","\xa0":"&#160;","\u2028":"&#8232;","\u2029":"&#8233;"},soy.esc.$$REPLACER_FOR_ESCAPE_HTML__AND__NORMALIZE_HTML__AND__ESCAPE_HTML_NOSPACE__AND__NORMALIZE_HTML_NOSPACE_=function(a){return soy.esc.$$ESCAPE_MAP_FOR_ESCAPE_HTML__AND__NORMALIZE_HTML__AND__ESCAPE_HTML_NOSPACE__AND__NORMALIZE_HTML_NOSPACE_[a]},soy.esc.$$ESCAPE_MAP_FOR_ESCAPE_JS_STRING__AND__ESCAPE_JS_REGEX_={"\x00":"\\x00","\b":"\\x08"," ":"\\t","\n":"\\n"," ":"\\x0b","\f":"\\f","\r":"\\r",'"':"\\x22","&":"\\x26","'":"\\x27","/":"\\/","<":"\\x3c","=":"\\x3d",">":"\\x3e","\\":"\\\\","\x85":"\\x85","\u2028":"\\u2028","\u2029":"\\u2029",$:"\\x24","(":"\\x28",")":"\\x29","*":"\\x2a","+":"\\x2b",",":"\\x2c","-":"\\x2d",".":"\\x2e",":":"\\x3a","?":"\\x3f","[":"\\x5b","]":"\\x5d","^":"\\x5e","{":"\\x7b","|":"\\x7c","}":"\\x7d"},soy.esc.$$REPLACER_FOR_ESCAPE_JS_STRING__AND__ESCAPE_JS_REGEX_=function(a){return soy.esc.$$ESCAPE_MAP_FOR_ESCAPE_JS_STRING__AND__ESCAPE_JS_REGEX_[a]},soy.esc.$$ESCAPE_MAP_FOR_ESCAPE_CSS_STRING_={"\x00":"\\0 ","\b":"\\8 "," ":"\\9 ","\n":"\\a "," ":"\\b ","\f":"\\c ","\r":"\\d ",'"':"\\22 ","&":"\\26 ","'":"\\27 ","(":"\\28 ",")":"\\29 ","*":"\\2a ","/":"\\2f ",":":"\\3a ",";":"\\3b ","<":"\\3c ","=":"\\3d ",">":"\\3e ","@":"\\40 ","\\":"\\5c ","{":"\\7b ","}":"\\7d ","\x85":"\\85 ","\xa0":"\\a0 ","\u2028":"\\2028 ","\u2029":"\\2029 "},soy.esc.$$REPLACER_FOR_ESCAPE_CSS_STRING_=function(a){return soy.esc.$$ESCAPE_MAP_FOR_ESCAPE_CSS_STRING_[a]},soy.esc.$$ESCAPE_MAP_FOR_NORMALIZE_URI__AND__FILTER_NORMALIZE_URI_={"\x00":"%00","":"%01","":"%02","":"%03","":"%04","":"%05","":"%06","":"%07","\b":"%08"," ":"%09","\n":"%0A"," ":"%0B","\f":"%0C","\r":"%0D","":"%0E","":"%0F","":"%10","":"%11","":"%12","":"%13","":"%14","":"%15","":"%16","":"%17","":"%18","":"%19","":"%1A","":"%1B","":"%1C","":"%1D","":"%1E","":"%1F"," ":"%20",'"':"%22","'":"%27","(":"%28",")":"%29","<":"%3C",">":"%3E","\\":"%5C","{":"%7B","}":"%7D","":"%7F","\x85":"%C2%85","\xa0":"%C2%A0","\u2028":"%E2%80%A8","\u2029":"%E2%80%A9","\uff01":"%EF%BC%81","\uff03":"%EF%BC%83","\uff04":"%EF%BC%84","\uff06":"%EF%BC%86","\uff07":"%EF%BC%87","\uff08":"%EF%BC%88","\uff09":"%EF%BC%89","\uff0a":"%EF%BC%8A","\uff0b":"%EF%BC%8B","\uff0c":"%EF%BC%8C","\uff0f":"%EF%BC%8F","\uff1a":"%EF%BC%9A","\uff1b":"%EF%BC%9B","\uff1d":"%EF%BC%9D","\uff1f":"%EF%BC%9F","\uff20":"%EF%BC%A0","\uff3b":"%EF%BC%BB","\uff3d":"%EF%BC%BD"},soy.esc.$$REPLACER_FOR_NORMALIZE_URI__AND__FILTER_NORMALIZE_URI_=function(a){return soy.esc.$$ESCAPE_MAP_FOR_NORMALIZE_URI__AND__FILTER_NORMALIZE_URI_[a]},soy.esc.$$MATCHER_FOR_ESCAPE_HTML_=/[\x00\x22\x26\x27\x3c\x3e]/g,soy.esc.$$MATCHER_FOR_NORMALIZE_HTML_=/[\x00\x22\x27\x3c\x3e]/g,soy.esc.$$MATCHER_FOR_ESCAPE_HTML_NOSPACE_=/[\x00\x09-\x0d \x22\x26\x27\x2d\/\x3c-\x3e`\x85\xa0\u2028\u2029]/g,soy.esc.$$MATCHER_FOR_NORMALIZE_HTML_NOSPACE_=/[\x00\x09-\x0d \x22\x27\x2d\/\x3c-\x3e`\x85\xa0\u2028\u2029]/g,soy.esc.$$MATCHER_FOR_ESCAPE_JS_STRING_=/[\x00\x08-\x0d\x22\x26\x27\/\x3c-\x3e\\\x85\u2028\u2029]/g,soy.esc.$$MATCHER_FOR_ESCAPE_JS_REGEX_=/[\x00\x08-\x0d\x22\x24\x26-\/\x3a\x3c-\x3f\x5b-\x5e\x7b-\x7d\x85\u2028\u2029]/g,soy.esc.$$MATCHER_FOR_ESCAPE_CSS_STRING_=/[\x00\x08-\x0d\x22\x26-\x2a\/\x3a-\x3e@\\\x7b\x7d\x85\xa0\u2028\u2029]/g,soy.esc.$$MATCHER_FOR_NORMALIZE_URI__AND__FILTER_NORMALIZE_URI_=/[\x00- \x22\x27-\x29\x3c\x3e\\\x7b\x7d\x7f\x85\xa0\u2028\u2029\uff01\uff03\uff04\uff06-\uff0c\uff0f\uff1a\uff1b\uff1d\uff1f\uff20\uff3b\uff3d]/g,soy.esc.$$FILTER_FOR_FILTER_CSS_VALUE_=/^(?!-*(?:expression|(?:moz-)?binding))(?:[.#]?-?(?:[_a-z0-9-]+)(?:-[_a-z0-9-]+)*-?|-?(?:[0-9]+(?:\.[0-9]*)?|\.[0-9]+)(?:[a-z]{1,2}|%)?|!important|)$/i,soy.esc.$$FILTER_FOR_FILTER_NORMALIZE_URI_=/^(?:(?:https?|mailto):|[^&:\/?#]*(?:[\/?#]|$))/i,soy.esc.$$FILTER_FOR_FILTER_HTML_ATTRIBUTE_=/^(?!style|on|action|archive|background|cite|classid|codebase|data|dsync|href|longdesc|src|usemap)(?:[a-z0-9_$:-]*)$/i,soy.esc.$$FILTER_FOR_FILTER_HTML_ELEMENT_NAME_=/^(?!script|style|title|textarea|xmp|no)[a-z0-9_$:-]*$/i,soy.esc.$$escapeHtmlHelper=function(a){var b=String(a);return b.replace(soy.esc.$$MATCHER_FOR_ESCAPE_HTML_,soy.esc.$$REPLACER_FOR_ESCAPE_HTML__AND__NORMALIZE_HTML__AND__ESCAPE_HTML_NOSPACE__AND__NORMALIZE_HTML_NOSPACE_)},soy.esc.$$normalizeHtmlHelper=function(a){var b=String(a);return b.replace(soy.esc.$$MATCHER_FOR_NORMALIZE_HTML_,soy.esc.$$REPLACER_FOR_ESCAPE_HTML__AND__NORMALIZE_HTML__AND__ESCAPE_HTML_NOSPACE__AND__NORMALIZE_HTML_NOSPACE_)},soy.esc.$$escapeHtmlNospaceHelper=function(a){var b=String(a);return b.replace(soy.esc.$$MATCHER_FOR_ESCAPE_HTML_NOSPACE_,soy.esc.$$REPLACER_FOR_ESCAPE_HTML__AND__NORMALIZE_HTML__AND__ESCAPE_HTML_NOSPACE__AND__NORMALIZE_HTML_NOSPACE_)},soy.esc.$$normalizeHtmlNospaceHelper=function(a){var b=String(a);return b.replace(soy.esc.$$MATCHER_FOR_NORMALIZE_HTML_NOSPACE_,soy.esc.$$REPLACER_FOR_ESCAPE_HTML__AND__NORMALIZE_HTML__AND__ESCAPE_HTML_NOSPACE__AND__NORMALIZE_HTML_NOSPACE_)},soy.esc.$$escapeJsStringHelper=function(a){var b=String(a);return b.replace(soy.esc.$$MATCHER_FOR_ESCAPE_JS_STRING_,soy.esc.$$REPLACER_FOR_ESCAPE_JS_STRING__AND__ESCAPE_JS_REGEX_)},soy.esc.$$escapeJsRegexHelper=function(a){var b=String(a);return b.replace(soy.esc.$$MATCHER_FOR_ESCAPE_JS_REGEX_,soy.esc.$$REPLACER_FOR_ESCAPE_JS_STRING__AND__ESCAPE_JS_REGEX_)},soy.esc.$$escapeCssStringHelper=function(a){var b=String(a);return b.replace(soy.esc.$$MATCHER_FOR_ESCAPE_CSS_STRING_,soy.esc.$$REPLACER_FOR_ESCAPE_CSS_STRING_)},soy.esc.$$filterCssValueHelper=function(a){var b=String(a);return soy.esc.$$FILTER_FOR_FILTER_CSS_VALUE_.test(b)?b:"zSoyz"},soy.esc.$$normalizeUriHelper=function(a){var b=String(a);return b.replace(soy.esc.$$MATCHER_FOR_NORMALIZE_URI__AND__FILTER_NORMALIZE_URI_,soy.esc.$$REPLACER_FOR_NORMALIZE_URI__AND__FILTER_NORMALIZE_URI_)},soy.esc.$$filterNormalizeUriHelper=function(a){var b=String(a);return soy.esc.$$FILTER_FOR_FILTER_NORMALIZE_URI_.test(b)?b.replace(soy.esc.$$MATCHER_FOR_NORMALIZE_URI__AND__FILTER_NORMALIZE_URI_,soy.esc.$$REPLACER_FOR_NORMALIZE_URI__AND__FILTER_NORMALIZE_URI_):"zSoyz"},soy.esc.$$filterHtmlAttributeHelper=function(a){var b=String(a);return soy.esc.$$FILTER_FOR_FILTER_HTML_ATTRIBUTE_.test(b)?b:"zSoyz"},soy.esc.$$filterHtmlElementNameHelper=function(a){var b=String(a);return soy.esc.$$FILTER_FOR_FILTER_HTML_ELEMENT_NAME_.test(b)?b:"zSoyz"},soy.esc.$$HTML_TAG_REGEX_=/<(?:!|\/?[a-zA-Z])(?:[^>'"]|"[^"]*"|'[^']*')*>/g,"undefined"==typeof aui)var aui={};if(aui.renderExtraAttributes=function(a,b){var c=b||new soy.StringBuilder;if(null!=a&&a.extraAttributes)if("[object Object]"===Object.prototype.toString.call(a.extraAttributes))for(var d=soy.$$getMapKeys(a.extraAttributes),e=d.length,f=0;e>f;f++){var g=d[f];c.append(" ",soy.$$escapeHtml(g),'="',soy.$$escapeHtml(a.extraAttributes[g]),'"')}else c.append(" ",a.extraAttributes);return b?"":c.toString()},aui.renderExtraClasses=function(a,b){var c=b||new soy.StringBuilder;if(null!=a&&a.extraClasses)if(a.extraClasses instanceof Array)for(var d=a.extraClasses,e=d.length,f=0;e>f;f++){var g=d[f];c.append(" ",soy.$$escapeHtml(g))}else c.append(" ",soy.$$escapeHtml(a.extraClasses));return b?"":c.toString()},"undefined"==typeof aui)var aui={};if("undefined"==typeof aui.avatar&&(aui.avatar={}),aui.avatar.avatar=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"span"),a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-avatar aui-avatar-',soy.$$escapeHtml(a.size),soy.$$escapeHtml(a.isProject?" aui-avatar-project":""),soy.$$escapeHtml(a.badgeContent?" aui-avatar-badged":"")),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append('><span class="aui-avatar-inner"><img src="',soy.$$escapeHtml(a.avatarImageUrl),'"',a.accessibilityText?' alt="'+soy.$$escapeHtml(a.accessibilityText)+'"':"",a.title?' title="'+soy.$$escapeHtml(a.title)+'"':"",a.imageClasses?' class="'+soy.$$escapeHtml(a.imageClasses)+'"':""," /></span>",a.badgeContent?a.badgeContent:"","</",soy.$$escapeHtml(a.tagName?a.tagName:"span"),">"),b?"":d.toString()},"undefined"==typeof aui)var aui={};if("undefined"==typeof aui.badges&&(aui.badges={}),aui.badges.badge=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"span"),a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-badge'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",soy.$$escapeHtml(a.text),"</",soy.$$escapeHtml(a.tagName?a.tagName:"span"),">"),b?"":d.toString()},"undefined"==typeof aui)var aui={};if("undefined"==typeof aui.buttons&&(aui.buttons={}),aui.buttons.button=function(a,b,c){var d=b||new soy.StringBuilder;return a.href?(d.append('<a href="',soy.$$escapeHtml(a.href),'"'),aui.buttons.buttonAttributes(soy.$$augmentData(a,{tagName:"a"}),d,c),d.append(">"),aui.buttons.buttonIcon(a,d,c),d.append(a.hasLabel?'<span class="aui-button-label">':"",soy.$$escapeHtml(a.text),a.hasLabel?"</span>":"","</a>")):"input"==a.tagName?(d.append('<input type="',soy.$$escapeHtml(a.inputType?a.inputType:"button"),'" '),aui.buttons.buttonAttributes(a,d,c),d.append(' value="',soy.$$escapeHtml(a.text),'" />')):(d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"button")),aui.buttons.buttonAttributes(soy.$$augmentData(a,{tagName:a.tagName?a.tagName:"button"}),d,c),d.append(">"),aui.buttons.buttonIcon(a,d,c),d.append(a.hasLabel?'<span class="aui-button-label">':"",soy.$$escapeHtml(a.text),a.hasLabel?"</span>":"","</",soy.$$escapeHtml(a.tagName?a.tagName:"button"),">")),b?"":d.toString()},aui.buttons.buttons=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<div",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-buttons'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</div>"),b?"":d.toString()},aui.buttons.buttonAttributes=function(a,b,c){var d=b||new soy.StringBuilder;switch(d.append(a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-button',"main"==a.splitButtonType?" aui-button-split-main":"",a.dropdown2Target?" aui-dropdown2-trigger"+("more"==a.splitButtonType?" aui-button-split-more":""):""),a.type){case"primary":d.append(" aui-button-primary");break;case"link":d.append(" aui-button-link");break;case"subtle":d.append(" aui-button-subtle")}return aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(a.isPressed?' aria-pressed="'+soy.$$escapeHtml(a.isPressed)+'"':"",a.isDisabled?' aria-disabled="'+soy.$$escapeHtml(a.isDisabled)+'"'+(1==a.isDisabled&&("button"==a.tagName||"input"==a.tagName)?' disabled="disabled" ':""):"",a.dropdown2Target?' aria-owns="'+soy.$$escapeHtml(a.dropdown2Target)+'" aria-haspopup="true"':"","a"==a.tagName?' tabindex="0"':""),b?"":d.toString()},aui.buttons.buttonIcon=function(a,b){var c=b||new soy.StringBuilder;return c.append(a.iconType?'<span class="'+("aui"==a.iconType?"aui-icon":"")+(a.iconClass?" "+soy.$$escapeHtml(a.iconClass):"")+'">'+(a.iconText?soy.$$escapeHtml(a.iconText)+" ":"")+"</span>":""),b?"":c.toString()},aui.buttons.splitButton=function(a,b,c){var d=b||new soy.StringBuilder;return aui.buttons.button(soy.$$augmentData(a.splitButtonMain,{splitButtonType:"main"}),d,c),aui.buttons.button(soy.$$augmentData(a.splitButtonMore,{splitButtonType:"more"}),d,c),b?"":d.toString()},"undefined"==typeof aui)var aui={};if("undefined"==typeof aui.dialog&&(aui.dialog={}),aui.dialog.dialog2=function(a,b,c){var d=b||new soy.StringBuilder,e=new soy.StringBuilder;return aui.dialog.dialog2Content(a,e,c),aui.dialog.dialog2Chrome({id:a.id,titleId:a.id?a.id+"-dialog-title":null,modal:a.modal,tagName:a.tagName,removeOnHide:a.removeOnHide,visible:a.visible,size:a.size,extraClasses:a.extraClasses,extraAttributes:a.extraAttributes,content:e.toString()},d,c),b?"":d.toString()},aui.dialog.dialog2Chrome=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"section"),a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",a.titleId?' aria-labelledby="'+soy.$$escapeHtml(a.titleId)+'"':"",' role="dialog" class=" aui-layer aui-dialog2 aui-dialog2-',soy.$$escapeHtml(a.size?a.size:"medium")),aui.renderExtraClasses(a,d,c),d.append('"',a.modal?'data-aui-modal="true"':"",a.removeOnHide?'data-aui-remove-on-hide="true"':"",1!=a.visible?'aria-hidden="true"':""),aui.renderExtraAttributes(a,d,c),d.append(">",a.content?a.content:"","</",soy.$$escapeHtml(a.tagName?a.tagName:"section"),">"),b?"":d.toString()},aui.dialog.dialog2Content=function(a,b,c){var d=b||new soy.StringBuilder;return aui.dialog.dialog2Header({titleId:a.id?a.id+"-dialog-title":null,titleText:a.titleText,titleContent:a.titleContent,actionContent:a.headerActionContent,secondaryContent:a.headerSecondaryContent,modal:a.modal},d,c),aui.dialog.dialog2Panel(a,d,c),aui.dialog.dialog2Footer({hintText:a.footerHintText,hintContent:a.footerHintContent,actionContent:a.footerActionContent},d,c),b?"":d.toString()},aui.dialog.dialog2Header=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<header",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-dialog2-header'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append("><h2 ",a.titleId?' id="'+soy.$$escapeHtml(a.titleId)+'"':"",' class="aui-dialog2-header-main">',a.titleText?soy.$$escapeHtml(a.titleText):"",a.titleContent?a.titleContent:"","</h2>",a.actionContent?'<div class="aui-dialog2-header-actions">'+a.actionContent+"</div>":"",a.secondaryContent?'<div class="aui-dialog2-header-secondary">'+a.secondaryContent+"</div>":"",1!=a.modal?'<a class="aui-dialog2-header-close"><span class="aui-icon aui-icon-small aui-iconfont-close-dialog">'+soy.$$escapeHtml("Close")+"</span></a>":"","</header>"),b?"":d.toString()},aui.dialog.dialog2Footer=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<footer",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-dialog2-footer'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.actionContent?'<div class="aui-dialog2-footer-actions">'+a.actionContent+"</div>":"",a.hintText||a.hintContent?'<div class="aui-dialog2-footer-hint">'+(a.hintText?soy.$$escapeHtml(a.hintText):"")+(a.hintContent?a.hintContent:"")+"</div>":"","</footer>"),b?"":d.toString()},aui.dialog.dialog2Panel=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<div",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-dialog2-content'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.content?a.content:"","</div>"),b?"":d.toString()},"undefined"==typeof aui)var aui={};if("undefined"==typeof aui.dropdown&&(aui.dropdown={}),aui.dropdown.trigger=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<a",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-dd-trigger'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append('><span class="dropdown-text">',a.accessibilityText?soy.$$escapeHtml(a.accessibilityText):"","</span>",0!=a.showIcon?'<span class="icon icon-dropdown"></span>':"","</a>"),b?"":d.toString()},aui.dropdown.menu=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"ul"),a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-dropdown hidden'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</",soy.$$escapeHtml(a.tagName?a.tagName:"ul"),">"),b?"":d.toString()},aui.dropdown.parent=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"div"),a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-dd-parent'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</",soy.$$escapeHtml(a.tagName?a.tagName:"div"),">"),b?"":d.toString()},aui.dropdown.item=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"li"),a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="dropdown-item'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append('><a href="',soy.$$escapeHtml(a.url?a.url:"#"),'">',soy.$$escapeHtml(a.text),"</a></",soy.$$escapeHtml(a.tagName?a.tagName:"li"),">"),b?"":d.toString()},"undefined"==typeof aui)var aui={};if("undefined"==typeof aui.dropdown2&&(aui.dropdown2={}),aui.dropdown2.dropdown2=function(a,b,c){var d=b||new soy.StringBuilder;return aui.dropdown2.trigger(soy.$$augmentData(a.trigger,{menu:a.menu}),d,c),aui.dropdown2.contents(a.menu,d,c),b?"":d.toString()},aui.dropdown2.trigger=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"a"),a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-dropdown2-trigger'),aui.renderExtraClasses(a,d,c),d.append('" aria-owns="',soy.$$escapeHtml(a.menu.id),'" aria-haspopup="true"',a.title?' title="'+soy.$$escapeHtml(a.title)+'"':"",a.container?' data-container="'+soy.$$escapeHtml(a.container)+'"':"",a.tagName&&"a"!=a.tagName||a.extraAttributes&&("[object Object]"!==Object.prototype.toString.call(a.extraAttributes)||a.extraAttributes.href||a.extraAttributes.tabindex)?"":' tabindex="0"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.content?a.content:"",a.text?soy.$$escapeHtml(a.text):"",0!=a.showIcon?'<span class="icon '+soy.$$escapeHtml(a.iconClasses?a.iconClasses:"aui-icon-dropdown")+'">'+(a.iconText?soy.$$escapeHtml(a.iconText):"")+"</span>":"","</",soy.$$escapeHtml(a.tagName?a.tagName:"a"),">"),b?"":d.toString() },aui.dropdown2.contents=function(a,b,c){var d=b||new soy.StringBuilder;return d.append('<div id="',soy.$$escapeHtml(a.id),'" class="aui-dropdown2'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.content?a.content:"","</div>"),b?"":d.toString()},aui.dropdown2.section=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<div",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-dropdown2-section'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.label?"<strong>"+soy.$$escapeHtml(a.label)+"</strong>":"",a.content,"</div>"),b?"":d.toString()},"undefined"==typeof aui)var aui={};if("undefined"==typeof aui.expander&&(aui.expander={}),aui.expander.content=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<div",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-expander-content'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(a.initiallyExpanded?' aria-expanded="'+soy.$$escapeHtml(a.initiallyExpanded)+'"':"",">",a.content?a.content:"","</div>"),b?"":d.toString()},aui.expander.trigger=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tag?a.tag:"div"),a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",a.replaceText?' data-replace-text="'+soy.$$escapeHtml(a.replaceText)+'"':"",a.replaceSelector?' data-replace-selector="'+soy.$$escapeHtml(a.replaceSelector)+'"':"",' class="aui-expander-trigger'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(' aria-controls="',soy.$$escapeHtml(a.contentId),'"',a.collapsible?' data-collapsible="'+soy.$$escapeHtml(a.collapsible)+'"':"",">",a.content?a.content:"","</",soy.$$escapeHtml(a.tag?a.tag:"div"),">"),b?"":d.toString()},aui.expander.revealText=function(a,b,c){var d=b||new soy.StringBuilder,e=new soy.StringBuilder(soy.$$escapeHtml(a.contentContent));return aui.expander.trigger({id:a.triggerId,contentId:a.contentId,tag:"a",content:"<span class='reveal-text-trigger-text'>Show more</span>",replaceSelector:".reveal-text-trigger-text",replaceText:"Show less",extraAttributes:a.triggerExtraAttributes,extraClasses:(a.triggerExtraClasses?soy.$$escapeHtml(a.triggerExtraClasses)+" ":"")+" aui-expander-reveal-text"},e,c),aui.expander.content({id:a.contentId,content:e.toString(),extraAttributes:a.contentExtraAttributes,extraClasses:a.contentExtraClasses},d,c),b?"":d.toString()},"undefined"==typeof aui)var aui={};if("undefined"==typeof aui.form&&(aui.form={}),aui.form.form=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<form",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui',a.isUnsectioned?" unsectioned":"",a.isLongLabels?" long-label":"",a.isTopLabels?" top-label":""),aui.renderExtraClasses(a,d,c),d.append('" action="',soy.$$escapeHtml(a.action),'" method="',soy.$$escapeHtml(a.method?a.method:"post"),'"',a.enctype?' enctype="'+soy.$$escapeHtml(a.enctype)+'"':""),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</form>"),b?"":d.toString()},aui.form.formDescription=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<div",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="field-group'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</div>"),b?"":d.toString()},aui.form.fieldset=function(a,b,c){var d=b||new soy.StringBuilder,e=a.isInline||a.isDateSelect||a.isGroup||a.extraClasses;return d.append("<fieldset",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':""),e&&(d.append(' class="',soy.$$escapeHtml(a.isInline?"inline":a.isDateSelect?"date-select":a.isGroup?"group":"")),aui.renderExtraClasses(a,d,c),d.append('"')),aui.renderExtraAttributes(a,d,c),d.append("><legend><span>",a.legendContent,"</span></legend>",a.content,"</fieldset>"),b?"":d.toString()},aui.form.fieldGroup=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<div",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="field-group'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</div>"),b?"":d.toString()},aui.form.buttons=function(a,b,c){var d=b||new soy.StringBuilder;return d.append('<div class="buttons-container',a.alignment?" "+soy.$$escapeHtml(a.alignment):""),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append('><div class="buttons">',a.content,"</div></div>"),b?"":d.toString()},aui.form.label=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<label",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",a.forField?' for="'+soy.$$escapeHtml(a.forField)+'"':""),a.extraClasses&&(d.append(' class="'),aui.renderExtraClasses(a,d,c),d.append('"')),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,a.isRequired?'<span class="aui-icon icon-required"></span>':"","</label>"),b?"":d.toString()},aui.form.input=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<input",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="',soy.$$escapeHtml("password"==a.type?"text":"submit"==a.type?"button":a.type)),aui.renderExtraClasses(a,d,c),d.append(!a.icon||"text"!=a.type&&"password"!=a.type?"":" aui-field-has-icon ",'" type="',soy.$$escapeHtml(a.type),'" name="',soy.$$escapeHtml(a.name?a.name:a.id),'"',a.value?' value="'+soy.$$escapeHtml(a.value)+'"':"","checkbox"!=a.type&&"radio"!=a.type||!a.isChecked?"":' checked="checked"',"text"==a.type&&a.maxLength?' maxlength="'+soy.$$escapeHtml(a.maxLength)+'"':"","text"==a.type&&a.size?' size="'+soy.$$escapeHtml(a.size)+'"':"","text"!=a.type&&"password"!=a.type||!a.autocomplete?"":' autocomplete="'+soy.$$escapeHtml(a.autocomplete)+'"',a.isDisabled?" disabled":"",a.isAutofocus?" autofocus":""),aui.renderExtraAttributes(a,d,c),aui.form.renderValidationArguments(a,d,c),aui.form.renderTooltipArguments(a,d,c),d.append("/>"),!a.icon||"text"!=a.type&&"password"!=a.type||aui.icons.icon({icon:a.icon,useIconFont:!0,size:"small"},d,c),b?"":d.toString()},aui.form.renderValidationArguments=function(a,b){var c=b||new soy.StringBuilder;if(a.validationArguments){for(var d=soy.$$getMapKeys(a.validationArguments),e=d.length,f=0;e>f;f++){var g=d[f];c.append(" ",soy.$$escapeHtml("data-aui-validate-"+g),'="',soy.$$escapeHtml(a.validationArguments[g]),'"')}c.append(" data-aui-field")}return b?"":c.toString()},aui.form.renderTooltipArguments=function(a,b){var c=b||new soy.StringBuilder;if(a.tooltipArguments)for(var d=soy.$$getMapKeys(a.tooltipArguments),e=d.length,f=0;e>f;f++){var g=d[f];c.append(" ",soy.$$escapeHtml("data-aui-form-notification-"+g),'="',soy.$$escapeHtml(a.tooltipArguments[g]),'"')}return b?"":c.toString()},aui.form.submit=function(a,b,c){var d=b||new soy.StringBuilder,e=new soy.StringBuilder(a.name?'name="'+soy.$$escapeHtml(a.name)+'"':"");return aui.renderExtraAttributes(a,e,c),aui.buttons.button({id:a.id,tagName:"input",inputType:"submit",text:a.text,type:a.type,href:a.href,isDisabled:a.isDisabled,isPressed:a.isPressed,iconType:a.iconType,iconText:a.iconText,iconClass:a.iconClass,dropdown2Target:a.dropdown2Target,splitButtonType:a.splitButtonType,extraClasses:a.extraClasses,extraAttributes:e.toString()},d,c),b?"":d.toString()},aui.form.button=function(a,b,c){var d=b||new soy.StringBuilder,e=new soy.StringBuilder(a.name?'name="'+soy.$$escapeHtml(a.name)+'"':"");return aui.renderExtraAttributes(a,e,c),aui.buttons.button({id:a.id,tagName:a.tagName,inputType:a.inputType,text:a.text,type:a.type,href:a.href,isDisabled:a.isDisabled,isPressed:a.isPressed,iconType:a.iconType,iconText:a.iconText,iconClass:a.iconClass,dropdown2Target:a.dropdown2Target,splitButtonType:a.splitButtonType,extraClasses:a.extraClasses,extraAttributes:e.toString()},d,c),b?"":d.toString()},aui.form.linkButton=function(a,b,c){var d=b||new soy.StringBuilder,e=new soy.StringBuilder("cancel");aui.renderExtraClasses(a,e,c);var f=new soy.StringBuilder(a.name?'name="'+soy.$$escapeHtml(a.name)+'"':"");return aui.renderExtraAttributes(a,f,c),aui.buttons.button({id:a.id,tagName:"a",inputType:a.inputType,text:a.text,type:"link",href:a.href?a.href:a.url,isDisabled:a.isDisabled,isPressed:a.isPressed,iconType:a.iconType,iconText:a.iconText,iconClass:a.iconClass,dropdown2Target:a.dropdown2Target,splitButtonType:a.splitButtonType,extraClasses:e.toString(),extraAttributes:f.toString()},d,c),b?"":d.toString()},aui.form.textarea=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<textarea",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' name="',soy.$$escapeHtml(a.name?a.name:a.id),'" class="textarea'),aui.renderExtraClasses(a,d,c),d.append(" ",a.icon?"aui-field-has-icon":"",'"',a.rows?' rows="'+soy.$$escapeHtml(a.rows)+'"':"",a.cols?' cols="'+soy.$$escapeHtml(a.cols)+'"':"",a.autocomplete?' autocomplete="'+soy.$$escapeHtml(a.autocomplete)+'"':"",a.isDisabled?" disabled":"",a.isAutofocus?" autofocus":""),aui.renderExtraAttributes(a,d,c),aui.form.renderValidationArguments(a,d,c),aui.form.renderTooltipArguments(a,d,c),d.append(">",a.value?soy.$$escapeHtml(a.value):"","</textarea>"),a.icon&&aui.icons.icon({icon:a.icon,useIconFont:!0,size:"small"},d,c),b?"":d.toString()},aui.form.select=function(a,b,c){var d=b||new soy.StringBuilder;d.append("<select",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' name="',soy.$$escapeHtml(a.name?a.name:a.id),'" class="',soy.$$escapeHtml(a.isMultiple?"multi-select":"select")),aui.renderExtraClasses(a,d,c),d.append('"',a.size?' size="'+soy.$$escapeHtml(a.size)+'"':"",a.isDisabled?" disabled":"",a.isAutofocus?" autofocus":"",a.isMultiple?" multiple":""),aui.renderExtraAttributes(a,d,c),aui.form.renderValidationArguments(a,d,c),aui.form.renderTooltipArguments(a,d,c),d.append(">");for(var e=a.options,f=e.length,g=0;f>g;g++){var h=e[g];aui.form.optionOrOptgroup(soy.$$augmentData(h,{defaultValue:a.value}),d,c)}return d.append("</select>"),b?"":d.toString()},aui.form.optionOrOptgroup=function(a,b,c){var d=b||new soy.StringBuilder;if(a.options){d.append('<optgroup label="',soy.$$escapeHtml(a.text),'"',a.disabled?" disabled":"",">");for(var e=a.options,f=e.length,g=0;f>g;g++){var h=e[g];aui.form.optionOrOptgroup(soy.$$augmentData(h,{defaultValue:a.defaultValue}),d,c)}d.append("</optgroup>")}else d.append('<option value="',soy.$$escapeHtml(a.value),'"',a.selected||a.defaultValue==a.value?" selected":"",a.disabled?" disabled":"",">",soy.$$escapeHtml(a.text),"</option>");return b?"":d.toString()},aui.form.value=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<span",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="field-value'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</span>"),b?"":d.toString()},aui.form.field=function(a,b,c){var d=b||new soy.StringBuilder,e="checkbox"==a.type||"radio"==a.type,f=a.fieldWidth?a.fieldWidth+"-field":"";switch(d.append('<div class="',e?soy.$$escapeHtml(a.type):"field-group"),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">"),a.labelContent&&!e&&aui.form.label({forField:a.id,isRequired:a.isRequired,content:a.labelContent},d,c),a.type){case"textarea":aui.form.textarea({id:a.id,name:a.name,value:a.value,rows:a.rows,cols:a.cols,autocomplete:a.autocomplete,isDisabled:a.isDisabled?!0:!1,isAutofocus:a.isAutofocus,extraClasses:f,icon:a.icon,validationArguments:a.validationArguments,tooltipArguments:a.tooltipArguments},d,c);break;case"select":aui.form.select({id:a.id,name:a.name,value:a.value,options:a.options,isMultiple:a.isMultiple,size:a.size,isDisabled:a.isDisabled?!0:!1,isAutofocus:a.isAutofocus,extraClasses:f,validationArguments:a.validationArguments,tooltipArguments:a.tooltipArguments},d,c);break;case"value":aui.form.value({id:a.id,content:soy.$$escapeHtml(a.value)},d,c);break;case"text":case"password":case"file":case"radio":case"checkbox":case"button":case"submit":case"reset":aui.form.input({id:a.id,name:a.name,type:a.type,value:a.value,maxLength:a.maxLength,size:a.size,autocomplete:a.autocomplete,isChecked:a.isChecked,isDisabled:a.isDisabled?!0:!1,isAutofocus:a.isAutofocus,extraClasses:f,icon:a.icon,validationArguments:a.validationArguments,tooltipArguments:a.tooltipArguments},d,c)}if(a.labelContent&&e&&aui.form.label({forField:a.id,isRequired:a.isRequired,content:a.labelContent},d,c),(a.descriptionText||a.descriptionContent)&&aui.form.fieldDescription({text:a.descriptionText,content:a.descriptionContent},d,c),a.errorTexts)for(var g=a.errorTexts,h=g.length,i=0;h>i;i++){var j=g[i];aui.form.fieldError({message:j},d,c)}return d.append("</div>"),b?"":d.toString()},aui.form.fieldError=function(a,b,c){var d=b||new soy.StringBuilder;return d.append('<div class="error'),aui.renderExtraClasses(a,d,c),d.append('">',soy.$$escapeHtml(a.message),"</div>"),b?"":d.toString()},aui.form.fieldDescription=function(a,b,c){var d=b||new soy.StringBuilder;return d.append('<div class="description'),aui.renderExtraClasses(a,d,c),d.append('">',a.text?soy.$$escapeHtml(a.text):a.message?soy.$$escapeHtml(a.message):a.content,"</div>"),b?"":d.toString()},aui.form.textField=function(a,b,c){var d=b||new soy.StringBuilder;return aui.form.field({id:a.id,name:a.name,type:"text",labelContent:a.labelContent,value:a.value,maxLength:a.maxLength,size:a.size,autocomplete:a.autocomplete,isRequired:a.isRequired,isDisabled:a.isDisabled,isAutofocus:a.isAutofocus,descriptionText:a.descriptionText,descriptionContent:a.descriptionContent,errorTexts:a.errorTexts,extraClasses:a.extraClasses,extraAttributes:a.extraAttributes,fieldWidth:a.fieldWidth,validationArguments:a.validationArguments,tooltipArguments:a.tooltipArguments},d,c),b?"":d.toString()},aui.form.textareaField=function(a,b,c){var d=b||new soy.StringBuilder;return aui.form.field({id:a.id,name:a.name,type:"textarea",labelContent:a.labelContent,value:a.value,rows:a.rows,cols:a.cols,autocomplete:a.autocomplete,isRequired:a.isRequired,isDisabled:a.isDisabled,isAutofocus:a.isAutofocus,descriptionText:a.descriptionText,descriptionContent:a.descriptionContent,errorTexts:a.errorTexts,extraClasses:a.extraClasses,extraAttributes:a.extraAttributes,fieldWidth:a.fieldWidth,validationArguments:a.validationArguments,tooltipArguments:a.tooltipArguments},d,c),b?"":d.toString()},aui.form.passwordField=function(a,b,c){var d=b||new soy.StringBuilder;return aui.form.field({id:a.id,name:a.name,type:"password",labelContent:a.labelContent,value:a.value,autocomplete:a.autocomplete,isRequired:a.isRequired,isDisabled:a.isDisabled,isAutofocus:a.isAutofocus,descriptionText:a.descriptionText,descriptionContent:a.descriptionContent,errorTexts:a.errorTexts,extraClasses:a.extraClasses,extraAttributes:a.extraAttributes,fieldWidth:a.fieldWidth,validationArguments:a.validationArguments,tooltipArguments:a.tooltipArguments},d,c),b?"":d.toString()},aui.form.fileField=function(a,b,c){var d=b||new soy.StringBuilder;return aui.form.field({id:a.id,name:a.name,type:"file",labelContent:a.labelContent,value:a.value,isRequired:a.isRequired,isDisabled:a.isDisabled,isAutofocus:a.isAutofocus,descriptionText:a.descriptionText,descriptionContent:a.descriptionContent,errorTexts:a.errorTexts,extraClasses:a.extraClasses,extraAttributes:a.extraAttributes,validationArguments:a.validationArguments,tooltipArguments:a.tooltipArguments},d,c),b?"":d.toString()},aui.form.selectField=function(a,b,c){var d=b||new soy.StringBuilder;return aui.form.field({id:a.id,name:a.name,type:"select",value:a.value,labelContent:a.labelContent,options:a.options,isMultiple:a.isMultiple,size:a.size,isRequired:a.isRequired,isDisabled:a.isDisabled,isAutofocus:a.isAutofocus,descriptionText:a.descriptionText,descriptionContent:a.descriptionContent,errorTexts:a.errorTexts,extraClasses:a.extraClasses,extraAttributes:a.extraAttributes,fieldWidth:a.fieldWidth,validationArguments:a.validationArguments,tooltipArguments:a.tooltipArguments},d,c),b?"":d.toString()},aui.form.checkboxField=function(a,b,c){for(var d=b||new soy.StringBuilder,e=new soy.StringBuilder(a.isMatrix?'<div class="matrix">':""),f=a.fields,g=f.length,h=0;g>h;h++){var i=f[h];aui.form.field(soy.$$augmentData(i,{type:"checkbox",labelContent:soy.$$escapeHtml(i.labelText)}),e,c)}return e.append(a.isMatrix?"</div>":""),(a.descriptionText||a.descriptionContent||a.errorTexts&&a.errorTexts.length)&&aui.form.field({descriptionText:a.descriptionText,descriptionContent:a.descriptionContent,errorTexts:a.errorTexts,isDisabled:!1},e,c),aui.form.fieldset({legendContent:a.legendContent+(a.isRequired?'<span class="aui-icon icon-required"></span>':""),isGroup:!0,id:a.id,extraClasses:a.extraClasses,extraAttributes:a.extraAttributes,content:e.toString()},d,c),b?"":d.toString()},aui.form.radioField=function(a,b,c){for(var d=b||new soy.StringBuilder,e=new soy.StringBuilder(a.isMatrix?'<div class="matrix">':""),f=a.fields,g=f.length,h=0;g>h;h++){var i=f[h];aui.form.field(soy.$$augmentData(i,{type:"radio",name:a.name?a.name:a.id,labelContent:soy.$$escapeHtml(i.labelText)}),e,c)}return e.append(a.isMatrix?"</div>":""),(a.descriptionText||a.descriptionContent||a.errorTexts&&a.errorTexts.length)&&aui.form.field({descriptionText:a.descriptionText,descriptionContent:a.descriptionContent,errorTexts:a.errorTexts,isDisabled:!1},e,c),aui.form.fieldset({legendContent:a.legendContent+(a.isRequired?'<span class="aui-icon icon-required"></span>':""),isGroup:!0,id:a.id,extraClasses:a.extraClasses,extraAttributes:a.extraAttributes,content:e.toString()},d,c),b?"":d.toString()},aui.form.valueField=function(a,b,c){var d=b||new soy.StringBuilder;return aui.form.field({id:a.id,type:"value",value:a.value,labelContent:a.labelContent,isRequired:a.isRequired,descriptionText:a.descriptionText,descriptionContent:a.descriptionContent,errorTexts:a.errorTexts,extraClasses:a.extraClasses,extraAttributes:a.extraAttributes},d,c),b?"":d.toString()},"undefined"==typeof aui)var aui={};if("undefined"==typeof aui.group&&(aui.group={}),aui.group.group=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"div"),a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-group',a.isSplit?" aui-group-split":""),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</",soy.$$escapeHtml(a.tagName?a.tagName:"div"),">"),b?"":d.toString()},aui.group.item=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"div"),a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-item'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</",soy.$$escapeHtml(a.tagName?a.tagName:"div"),">"),b?"":d.toString()},"undefined"==typeof aui)var aui={};if("undefined"==typeof aui.icons&&(aui.icons={}),aui.icons.icon=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"span"),a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-icon',a.useIconFont?" aui-icon-"+soy.$$escapeHtml(a.size?a.size:"small"):""," aui",soy.$$escapeHtml(a.useIconFont?"-iconfont":"-icon"),soy.$$escapeHtml(a.iconFontSet?"-"+a.iconFontSet:""),"-",soy.$$escapeHtml(a.icon)),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.accessibilityText?soy.$$escapeHtml(a.accessibilityText):"","</",soy.$$escapeHtml(a.tagName?a.tagName:"span"),">"),b?"":d.toString()},"undefined"==typeof aui)var aui={};if("undefined"==typeof aui.labels&&(aui.labels={}),aui.labels.label=function(a,b,c){var d=b||new soy.StringBuilder;return a.url&&1==a.isCloseable?(d.append("<span",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-label aui-label-closeable aui-label-split'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append('><a class="aui-label-split-main" href="',soy.$$escapeHtml(a.url),'">',soy.$$escapeHtml(a.text),'</a><span class="aui-label-split-close" >'),aui.labels.closeIcon(a,d,c),d.append("</span></span>")):(d.append("<",soy.$$escapeHtml(a.url?"a":"span"),a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-label',a.isCloseable?" aui-label-closeable":""),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(a.url?' href="'+soy.$$escapeHtml(a.url)+'"':"",">",soy.$$escapeHtml(a.text)),a.isCloseable&&aui.labels.closeIcon(a,d,c),d.append("</",soy.$$escapeHtml(a.url?"a":"span"),">")),b?"":d.toString()},aui.labels.closeIcon=function(a,b,c){var d=b||new soy.StringBuilder;return d.append('<span tabindex="0" class="aui-icon aui-icon-close"'),0!=a.hasTitle&&(d.append(' title="'),aui.labels.closeIconText(a,d,c),d.append('"')),d.append(">"),aui.labels.closeIconText(a,d,c),d.append("</span>"),b?"":d.toString()},aui.labels.closeIconText=function(a,b){var c=b||new soy.StringBuilder;return c.append(a.closeIconText?soy.$$escapeHtml(a.closeIconText):"("+soy.$$escapeHtml("Remove")+" "+soy.$$escapeHtml(a.text)+")"),b?"":c.toString()},"undefined"==typeof aui)var aui={};if("undefined"==typeof aui.lozenges&&(aui.lozenges={}),aui.lozenges.lozenge=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"span"),a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",a.title?' title="'+soy.$$escapeHtml(a.title)+'"':"",' class="aui-lozenge',soy.$$escapeHtml(a.type?" aui-lozenge-"+a.type:""),soy.$$escapeHtml(a.isSubtle?" aui-lozenge-subtle":"")),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.maxLength?soy.$$truncate(soy.$$escapeHtml(a.text),a.maxLength,!0):soy.$$escapeHtml(a.text),"</",soy.$$escapeHtml(a.tagName?a.tagName:"span"),">"),b?"":d.toString()},"undefined"==typeof aui)var aui={};if("undefined"==typeof aui.message&&(aui.message={}),aui.message.info=function(a,b,c){var d=b||new soy.StringBuilder;return aui.message.message(soy.$$augmentData(a,{type:"aui-message-info info"}),d,c),b?"":d.toString()},aui.message.warning=function(a,b,c){var d=b||new soy.StringBuilder;return aui.message.message(soy.$$augmentData(a,{type:"aui-message-warning warning"}),d,c),b?"":d.toString()},aui.message.error=function(a,b,c){var d=b||new soy.StringBuilder;return aui.message.message(soy.$$augmentData(a,{type:"aui-message-error error"}),d,c),b?"":d.toString()},aui.message.success=function(a,b,c){var d=b||new soy.StringBuilder;return aui.message.message(soy.$$augmentData(a,{type:"aui-message-success success"}),d,c),b?"":d.toString()},aui.message.hint=function(a,b,c){var d=b||new soy.StringBuilder;return aui.message.message(soy.$$augmentData(a,{type:"aui-message-hint hint"}),d,c),b?"":d.toString()},aui.message.generic=function(a,b,c){var d=b||new soy.StringBuilder;return aui.message.message(soy.$$augmentData(a,{type:"aui-message-generic generic"}),d,c),b?"":d.toString()},aui.message.message=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"div"),a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-message ',soy.$$escapeHtml(a.type?a.type:"aui-message-generic generic"),a.isCloseable?" closeable":"",a.isShadowed?" shadowed":""),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.titleContent?'<p class="title"><strong>'+a.titleContent+"</strong></p>":"",a.content,a.isCloseable?'<span class="aui-icon icon-close" role="button" tabindex="0"></span>':"","</",soy.$$escapeHtml(a.tagName?a.tagName:"div"),">"),b?"":d.toString()},"undefined"==typeof aui)var aui={};if("undefined"==typeof aui.page&&(aui.page={}),aui.page.document=function(a,b,c){var d=b||new soy.StringBuilder;return d.append('<!DOCTYPE html><html lang="',soy.$$escapeHtml(c.language?c.language:"en"),'"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><title>',soy.$$escapeHtml(a.windowTitle),"</title>",a.headContent?a.headContent:"","</head><body"),a.pageType?"generic"==a.pageType?a.extraClasses&&(d.append(' class="'),aui.renderExtraClasses(a,d,c),d.append('"')):"focused"==a.pageType?(d.append(' class="aui-page-focused aui-page-focused-',soy.$$escapeHtml(a.focusedPageSize?a.focusedPageSize:"xlarge")),aui.renderExtraClasses(a,d,c),d.append('"')):"sidebar"==a.pageType?(d.append(' class="aui-page-sidebar',soy.$$escapeHtml(a.sidebarState?" aui-sidebar-"+a.sidebarState:"")),aui.renderExtraClasses(a,d,c),d.append('"')):(d.append(' class="aui-page-',soy.$$escapeHtml(a.pageType)),aui.renderExtraClasses(a,d,c),d.append('"')):(d.append(' class="'),aui.renderExtraClasses(a,d,c),d.append('"')),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</body></html>"),b?"":d.toString()},aui.page.page=function(a,b){var c=b||new soy.StringBuilder;return c.append('<div id="page"><header id="header" role="banner">',a.headerContent,'</header><!-- #header --><section id="content" role="main">',a.contentContent,'</section><!-- #content --><footer id="footer" role="contentinfo">',a.footerContent,"</footer><!-- #footer --></div><!-- #page -->"),b?"":c.toString()},aui.page.header=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<nav",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-header aui-dropdown2-trigger-group'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(' role="navigation"><div class="aui-header-inner">',a.headerBeforeContent?'<div class="aui-header-before">'+a.headerBeforeContent+"</div>":"",'<div class="aui-header-primary"><h1 id="logo" class="aui-header-logo',a.headerLogoImageUrl?" aui-header-logo-custom":a.logo?" aui-header-logo-"+soy.$$escapeHtml(a.logo):"",'"><a href="',soy.$$escapeHtml(a.headerLink?a.headerLink:"/"),'">',a.headerLogoImageUrl?'<img src="'+soy.$$escapeHtml(a.headerLogoImageUrl)+'" alt="'+soy.$$escapeHtml(a.headerLogoText)+'" />':'<span class="aui-header-logo-device">'+soy.$$escapeHtml(a.headerLogoText?a.headerLogoText:"")+"</span>",a.headerText?'<span class="aui-header-logo-text">'+soy.$$escapeHtml(a.headerText)+"</span>":"","</a></h1>",a.primaryNavContent?a.primaryNavContent:"","</div>",a.secondaryNavContent?'<div class="aui-header-secondary">'+a.secondaryNavContent+"</div>":"",a.headerAfterContent?'<div class="aui-header-after">'+a.headerAfterContent+"</div>":"","</div><!-- .aui-header-inner--></nav><!-- .aui-header -->"),b?"":d.toString()},aui.page.pagePanel=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"div"),' class="aui-page-panel'),aui.renderExtraClasses(a,d,c),d.append('"',a.id?' id="'+soy.$$escapeHtml(a.id)+'"':""),aui.renderExtraAttributes(a,d,c),d.append('><div class="aui-page-panel-inner">',a.content,"</div><!-- .aui-page-panel-inner --></",soy.$$escapeHtml(a.tagName?a.tagName:"div"),"><!-- .aui-page-panel -->"),b?"":d.toString()},aui.page.pagePanelNav=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"div"),' class="aui-page-panel-nav'),aui.renderExtraClasses(a,d,c),d.append('"',a.id?' id="'+soy.$$escapeHtml(a.id)+'"':""),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</",soy.$$escapeHtml(a.tagName?a.tagName:"div"),"><!-- .aui-page-panel-nav -->"),b?"":d.toString()},aui.page.pagePanelContent=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"section"),' class="aui-page-panel-content'),aui.renderExtraClasses(a,d,c),d.append('"',a.id?' id="'+soy.$$escapeHtml(a.id)+'"':""),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</",soy.$$escapeHtml(a.tagName?a.tagName:"section"),"><!-- .aui-page-panel-content -->"),b?"":d.toString()},aui.page.pagePanelSidebar=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"aside"),' class="aui-page-panel-sidebar'),aui.renderExtraClasses(a,d,c),d.append('"',a.id?' id="'+soy.$$escapeHtml(a.id)+'"':""),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</",soy.$$escapeHtml(a.tagName?a.tagName:"aside"),"><!-- .aui-page-panel-sidebar -->"),b?"":d.toString()},aui.page.pagePanelItem=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"section"),' class="aui-page-panel-item'),aui.renderExtraClasses(a,d,c),d.append('"',a.id?' id="'+soy.$$escapeHtml(a.id)+'"':""),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</",soy.$$escapeHtml(a.tagName?a.tagName:"section"),"><!-- .aui-page-panel-item -->"),b?"":d.toString()},aui.page.pageHeader=function(a,b,c){var d=b||new soy.StringBuilder;return d.append('<header class="aui-page-header'),aui.renderExtraClasses(a,d,c),d.append('"',a.id?' id="'+soy.$$escapeHtml(a.id)+'"':""),aui.renderExtraAttributes(a,d,c),d.append('><div class="aui-page-header-inner">',a.content,"</div><!-- .aui-page-header-inner --></header><!-- .aui-page-header -->"),b?"":d.toString()},aui.page.pageHeaderImage=function(a,b,c){var d=b||new soy.StringBuilder;return d.append('<div class="aui-page-header-image'),aui.renderExtraClasses(a,d,c),d.append('"',a.id?' id="'+soy.$$escapeHtml(a.id)+'"':""),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</div><!-- .aui-page-header-image -->"),b?"":d.toString()},aui.page.pageHeaderMain=function(a,b,c){var d=b||new soy.StringBuilder;return d.append('<div class="aui-page-header-main'),aui.renderExtraClasses(a,d,c),d.append('"',a.id?' id="'+soy.$$escapeHtml(a.id)+'"':""),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</div><!-- .aui-page-header-main -->"),b?"":d.toString()},aui.page.pageHeaderActions=function(a,b,c){var d=b||new soy.StringBuilder;return d.append('<div class="aui-page-header-actions'),aui.renderExtraClasses(a,d,c),d.append('"',a.id?' id="'+soy.$$escapeHtml(a.id)+'"':""),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</div><!-- .aui-page-header-actions -->"),b?"":d.toString()},"undefined"==typeof aui)var aui={};if(aui.panel=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"div"),a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-panel'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</",soy.$$escapeHtml(a.tagName?a.tagName:"div"),">"),b?"":d.toString()},"undefined"==typeof aui)var aui={};if("undefined"==typeof aui.progressTracker&&(aui.progressTracker={}),aui.progressTracker.progressTracker=function(a,b,c){var d=b||new soy.StringBuilder;d.append("<ol",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-progress-tracker',a.isInverted?" aui-progress-tracker-inverted":""),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">");for(var e=new soy.StringBuilder,f=a.steps,g=f.length,h=0;g>h;h++){var i=f[h];if(i.isCurrent)for(var j=a.steps,k=j.length,l=0;k>l;l++){var m=j[l];aui.progressTracker.step(soy.$$augmentData(m,{width:Math.round(100/a.steps.length*1e4)/1e4,href:h>l?m.href:null}),e,c)}}return aui.progressTracker.content({steps:a.steps,content:e.toString()},d,c),d.append("</ol>"),b?"":d.toString()},aui.progressTracker.content=function(a,b,c){var d=b||new soy.StringBuilder;if(""!=a.content)d.append(a.content);else for(var e=a.steps,f=e.length,g=0;f>g;g++){var h=e[g];aui.progressTracker.step(soy.$$augmentData(h,{isCurrent:0==g,width:Math.round(100/a.steps.length*1e4)/1e4,href:null}),d,c)}return b?"":d.toString()},aui.progressTracker.step=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<li",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-progress-tracker-step',a.isCurrent?" aui-progress-tracker-step-current":""),aui.renderExtraClasses(a,d,c),d.append('" style="width: ',soy.$$escapeHtml(a.width),'%;"'),aui.renderExtraAttributes(a,d,c),d.append("><",soy.$$escapeHtml(a.href?"a":"span"),a.href?' href="'+soy.$$escapeHtml(a.href)+'"':"",">",soy.$$escapeHtml(a.text),"</",soy.$$escapeHtml(a.href?"a":"span"),"></li>"),b?"":d.toString()},"undefined"==typeof aui)var aui={};if("undefined"==typeof aui.sidebar&&(aui.sidebar={}),aui.sidebar.sidebar=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"div"),a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",a.state?' aria-expanded="'+("collapsed"==a.state?"false":"true")+'"':"",' class="aui-sidebar ',a.isAnimated?"aui-is-animated":""),aui.renderExtraClasses(a,d,c),d.append('" ',0==a.isResponsive?'data-aui-responsive="false"':""),aui.renderExtraAttributes(a,d,c),d.append('><div class="aui-sidebar-wrapper"><div class="aui-sidebar-body">',a.headerContent,a.content,'</div><div class="aui-sidebar-footer">',a.footerContent?a.footerContent:a.settingsButtonUrl&&a.settingsText?'<a href="'+soy.$$escapeHtml(a.settingsButtonUrl)+'" class="aui-button aui-button-subtle aui-sidebar-settings-button" data-tooltip="'+soy.$$escapeHtml(a.settingsTooltip?a.settingsTooltip:a.settingsText)+'"><span class="aui-icon aui-icon-small aui-iconfont-configure"></span><span class="aui-button-label">'+soy.$$escapeHtml(a.settingsText)+"</span></a>":"",'<a class="aui-button aui-button-subtle aui-sidebar-toggle aui-sidebar-footer-tipsy" data-tooltip="',soy.$$escapeHtml("Expand sidebar ( [ )"),'" href="#"><span class="aui-icon aui-icon-small"></span></a></div>',a.isResizable?'<div class="aui-sidebar-handle"></div>':"","</div></",soy.$$escapeHtml(a.tagName?a.tagName:"div"),">"),b?"":d.toString() },"undefined"==typeof aui)var aui={};if(aui.table=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<table",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.columnsContent?a.columnsContent:"",a.captionContent?"<caption>"+a.captionContent+"</caption>":"",a.theadContent?"<thead>"+a.theadContent+"</thead>":"",a.tfootContent?"<tfoot>"+a.tfootContent+"</tfoot>":"",a.contentIncludesTbody?"":"<tbody>",a.content,a.contentIncludesTbody?"":"</tbody>","</table>"),b?"":d.toString()},"undefined"==typeof aui)var aui={};if(aui.tabs=function(a,b,c){var d=b||new soy.StringBuilder;d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"div"),a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-tabs ',soy.$$escapeHtml(a.isVertical?"vertical-tabs":"horizontal-tabs"),a.isDisabled?" aui-tabs-disabled":""),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append('><ul class="tabs-menu">');for(var e=a.menuItems,f=e.length,g=0;f>g;g++){var h=e[g];aui.tabMenuItem(h,d,c)}return d.append("</ul>",a.paneContent,"</",soy.$$escapeHtml(a.tagName?a.tagName:"div"),">"),b?"":d.toString()},aui.tabMenuItem=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<li",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="menu-item',a.isActive?" active-tab":""),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append('><a href="',soy.$$escapeHtml(a.url),'"><strong>',soy.$$escapeHtml(a.text),"</strong></a></li>"),b?"":d.toString()},aui.tabPane=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"div"),a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="tabs-pane',a.isActive?" active-pane":""),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</",soy.$$escapeHtml(a.tagName?a.tagName:"div"),">"),b?"":d.toString()},"undefined"==typeof aui)var aui={};if("undefined"==typeof aui.toolbar&&(aui.toolbar={}),aui.toolbar.toolbar=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"div"),a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-toolbar'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</",soy.$$escapeHtml(a.tagName?a.tagName:"div"),">"),b?"":d.toString()},aui.toolbar.split=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"div"),a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="toolbar-split toolbar-split-',soy.$$escapeHtml(a.split)),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</",soy.$$escapeHtml(a.tagName?a.tagName:"div"),">"),b?"":d.toString()},aui.toolbar.group=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<ul",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="toolbar-group'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</ul>"),b?"":d.toString()},aui.toolbar.item=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<li ",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="toolbar-item',a.isPrimary?" primary":"",a.isActive?" active":""),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</li>"),b?"":d.toString()},aui.toolbar.trigger=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<a",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="toolbar-trigger'),aui.renderExtraClasses(a,d,c),d.append('" href="',soy.$$escapeHtml(a.url?a.url:"#"),'"',a.title?' title="'+soy.$$escapeHtml(a.title)+'"':""),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</a>"),b?"":d.toString()},aui.toolbar.button=function(a,b,c){var d=b||new soy.StringBuilder;if(null==a)d.append("Either $text or both $title and $iconClass must be provided.");else{var e=new soy.StringBuilder;aui.toolbar.trigger({url:a.url,title:a.title,content:(a.iconClass?'<span class="icon '+soy.$$escapeHtml(a.iconClass)+'"></span>':"")+(a.text?'<span class="trigger-text">'+soy.$$escapeHtml(a.text)+"</span>":"")},e,c),aui.toolbar.item({isActive:a.isActive,isPrimary:a.isPrimary,id:a.id,extraClasses:a.extraClasses,extraAttributes:a.extraAttributes,content:e.toString()},d,c)}return b?"":d.toString()},aui.toolbar.link=function(a,b,c){var d=b||new soy.StringBuilder,e=new soy.StringBuilder("toolbar-item-link");aui.renderExtraClasses(a,e,c);var f=new soy.StringBuilder;return aui.toolbar.trigger({url:a.url,content:soy.$$escapeHtml(a.text)},f,c),aui.toolbar.item({id:a.id,extraClasses:e.toString(),extraAttributes:a.extraAttributes,content:f.toString()},d,c),b?"":d.toString()},aui.toolbar.dropdownInternal=function(a,b,c){var d=b||new soy.StringBuilder,e=new soy.StringBuilder(a.itemClass);aui.renderExtraClasses(a,e,c);var f=new soy.StringBuilder(a.splitButtonContent?a.splitButtonContent:""),g=new soy.StringBuilder;return aui.dropdown.trigger({extraClasses:"toolbar-trigger",accessibilityText:a.text},g,c),aui.dropdown.menu({content:a.dropdownItemsContent},g,c),aui.dropdown.parent({content:g.toString()},f,c),aui.toolbar.item({isPrimary:a.isPrimary,id:a.id,extraClasses:e.toString(),extraAttributes:a.extraAttributes,content:f.toString()},d,c),b?"":d.toString()},aui.toolbar.dropdown=function(a,b,c){var d=b||new soy.StringBuilder;return aui.toolbar.dropdownInternal({isPrimary:a.isPrimary,id:a.id,itemClass:"toolbar-dropdown",extraClasses:a.extraClasses,extraAttributes:a.extraAttributes,text:a.text,dropdownItemsContent:a.dropdownItemsContent},d,c),b?"":d.toString()},aui.toolbar.splitButton=function(a,b,c){var d=b||new soy.StringBuilder,e=new soy.StringBuilder;return aui.toolbar.trigger({url:a.url,content:soy.$$escapeHtml(a.text)},e,c),aui.toolbar.dropdownInternal({isPrimary:a.isPrimary,id:a.id,itemClass:"toolbar-splitbutton",extraClasses:a.extraClasses,extraAttributes:a.extraAttributes,dropdownItemsContent:a.dropdownItemsContent,splitButtonContent:e.toString()},d,c),b?"":d.toString()},"undefined"==typeof aui)var aui={};if("undefined"==typeof aui.toolbar2&&(aui.toolbar2={}),aui.toolbar2.toolbar2=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<div",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-toolbar2'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(' role="toolbar"><div class="aui-toolbar2-inner">',a.content,"</div></div>"),b?"":d.toString()},aui.toolbar2.item=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<div",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-toolbar2-',soy.$$escapeHtml(a.item)),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</div>"),b?"":d.toString()},aui.toolbar2.group=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<div",a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="aui-toolbar2-group'),aui.renderExtraClasses(a,d,c),d.append('"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.content,"</div>"),b?"":d.toString()},"undefined"==typeof aui)var aui={};"undefined"==typeof aui.trigger&&(aui.trigger={}),aui.trigger.trigger=function(a,b,c){var d=b||new soy.StringBuilder;return d.append("<",soy.$$escapeHtml(a.tagName?a.tagName:"a"),a.id?' id="'+soy.$$escapeHtml(a.id)+'"':"",' class="'),aui.renderExtraClasses(a,d,c),d.append('" aria-owns="',soy.$$escapeHtml(a.menu.id),'" aria-controls="',soy.$$escapeHtml(a.menu.id),'" aria-haspopup="true"',a.title?' title="'+soy.$$escapeHtml(a.title)+'"':"",a.container?' data-container="'+soy.$$escapeHtml(a.container)+'"':"",a.tagName&&"a"!=a.tagName||a.extraAttributes&&("[object Object]"!==Object.prototype.toString.call(a.extraAttributes)||a.extraAttributes.href||a.extraAttributes.tabindex)?"":' tabindex="0"'),aui.renderExtraAttributes(a,d,c),d.append(">",a.content?a.content:"",a.text?soy.$$escapeHtml(a.text):"",0!=a.showIcon?'<span class="icon '+soy.$$escapeHtml(a.iconClasses?a.iconClasses:"aui-icon-dropdown")+'">'+(a.iconText?soy.$$escapeHtml(a.iconText):"")+"</span>":"","</",soy.$$escapeHtml(a.tagName?a.tagName:"a"),">"),b?"":d.toString()};
example/examples/CustomTiles.js
phantomlds/react-native-maps
import React from 'react'; import { StyleSheet, View, Text, Dimensions, } from 'react-native'; import MapView, { MAP_TYPES, PROVIDER_DEFAULT } from 'react-native-maps'; const { width, height } = Dimensions.get('window'); const ASPECT_RATIO = width / height; const LATITUDE = 37.78825; const LONGITUDE = -122.4324; const LATITUDE_DELTA = 0.0922; const LONGITUDE_DELTA = LATITUDE_DELTA * ASPECT_RATIO; class CustomTiles extends React.Component { constructor(props, context) { super(props, context); this.state = { region: { latitude: LATITUDE, longitude: LONGITUDE, latitudeDelta: LATITUDE_DELTA, longitudeDelta: LONGITUDE_DELTA, }, }; } get mapType() { // MapKit does not support 'none' as a base map return this.props.provider === PROVIDER_DEFAULT ? MAP_TYPES.STANDARD : MAP_TYPES.NONE; } render() { const { region } = this.state; return ( <View style={styles.container}> <MapView provider={this.props.provider} mapType={this.mapType} style={styles.map} initialRegion={region} > <MapView.UrlTile urlTemplate="http://c.tile.stamen.com/watercolor/{z}/{x}/{y}.jpg" zIndex={-1} /> </MapView> <View style={styles.buttonContainer}> <View style={styles.bubble}> <Text>Custom Tiles</Text> </View> </View> </View> ); } } CustomTiles.propTypes = { provider: MapView.ProviderPropType, }; const styles = StyleSheet.create({ container: { position: 'absolute', top: 0, left: 0, right: 0, bottom: 0, justifyContent: 'flex-end', alignItems: 'center', }, map: { position: 'absolute', top: 0, left: 0, right: 0, bottom: 0, }, bubble: { flex: 1, backgroundColor: 'rgba(255,255,255,0.7)', paddingHorizontal: 18, paddingVertical: 12, borderRadius: 20, }, latlng: { width: 200, alignItems: 'stretch', }, button: { width: 80, paddingHorizontal: 12, alignItems: 'center', marginHorizontal: 10, }, buttonContainer: { flexDirection: 'row', marginVertical: 20, backgroundColor: 'transparent', }, }); module.exports = CustomTiles;
src/applications/static-pages/medical-copays-cta/index.js
department-of-veterans-affairs/vets-website
// Node modules. import React from 'react'; import ReactDOM from 'react-dom'; import { Provider } from 'react-redux'; export default (store, widgetType) => { const root = document.querySelector(`[data-widget-type="${widgetType}"]`); if (root) { import(/* webpackChunkName: "medical-copays-cta" */ './components/App').then(module => { const App = module.default; ReactDOM.render( <Provider store={store}> <App /> </Provider>, root, ); }); } };
app/jsx/permissions/components/DetailsToggle.js
djbender/canvas-lms
/* * Copyright (C) 2018 - present Instructure, Inc. * * This file is part of Canvas. * * Canvas is free software: you can redistribute it and/or modify it under * the terms of the GNU Affero General Public License as published by the Free * Software Foundation, version 3 of the License. * * Canvas is distributed in the hope that it will be useful, but WITHOUT ANY * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR * A PARTICULAR PURPOSE. See the GNU Affero General Public License for more * details. * * You should have received a copy of the GNU Affero General Public License along * with this program. If not, see <http://www.gnu.org/licenses/>. */ import React from 'react' import {arrayOf, string} from 'prop-types' import {ToggleDetails} from '@instructure/ui-toggle-details' import {Text} from '@instructure/ui-elements' import {View} from '@instructure/ui-layout' import propTypes from '../propTypes' class DetailsToggle extends React.Component { static propTypes = { title: string.isRequired, detailItems: arrayOf(propTypes.permissionDetails).isRequired } renderDetailGroup(item) { return ( <View key={item.title} margin="small" padding="small"> <Text weight="bold" as="div"> {item.title} </Text> <Text weight="normal" as="div"> {item.description} </Text> </View> ) } render() { if (!this.props.detailItems || this.props.detailItems.length === 0) { return null } return ( <ToggleDetails summary={ <Text weight="bold" as="h3"> {this.props.title} </Text> } > {this.props.detailItems.map(item => this.renderDetailGroup(item))} </ToggleDetails> ) } } export default DetailsToggle
analysis/warlockdestruction/src/modules/talents/InternalCombustion.js
yajinni/WoWAnalyzer
import React from 'react'; import Analyzer, { SELECTED_PLAYER } from 'parser/core/Analyzer'; import Events from 'parser/core/Events'; import SPELLS from 'common/SPELLS'; import { formatThousands, formatNumber, formatPercentage } from 'common/format'; import Statistic from 'parser/ui/Statistic'; import BoringSpellValueText from 'parser/ui/BoringSpellValueText'; import STATISTIC_CATEGORY from 'parser/ui/STATISTIC_CATEGORY'; /* Internal Combustion (Tier 30 Destruction talent): Chaos Bolt consumes up to 5 sec of Immolate's damage over time effect on your target, instantly dealing that much damage. */ class InternalCombustion extends Analyzer { get dps() { return this.damage / this.owner.fightDuration * 1000; } damage = 0; constructor(...args) { super(...args); this.active = this.selectedCombatant.hasTalent(SPELLS.INTERNAL_COMBUSTION_TALENT.id); this.addEventListener(Events.damage.by(SELECTED_PLAYER).spell(SPELLS.INTERNAL_COMBUSTION_DAMAGE), this.onInternalCombustionDamage); } onInternalCombustionDamage(event) { this.damage += (event.amount || 0) + (event.absorbed || 0); } statistic() { return ( <Statistic category={STATISTIC_CATEGORY.TALENTS} size="small" tooltip={`${formatThousands(this.damage)} damage`} > <BoringSpellValueText spell={SPELLS.INTERNAL_COMBUSTION_TALENT}> {formatNumber(this.dps)} DPS <small>{formatPercentage(this.owner.getPercentageOfTotalDamageDone(this.damage))} % of total</small> </BoringSpellValueText> </Statistic> ); } } export default InternalCombustion;
src/index.js
eperiou/DeGreenFields
import React from 'react'; import ReactDOM from 'react-dom'; import App from './App'; import './index.css'; ReactDOM.render(<App />, document.getElementById('root'));
node_modules/react-google-maps/src/creators/CircleCreator.js
yomolify/cs-webserver
import { default as React, PropTypes, Component, } from "react"; import {default as CircleEventList} from "../eventLists/CircleEventList"; import {default as eventHandlerCreator} from "../utils/eventHandlerCreator"; import {default as defaultPropsCreator} from "../utils/defaultPropsCreator"; import {default as composeOptions} from "../utils/composeOptions"; import {default as componentLifecycleDecorator} from "../utils/componentLifecycleDecorator"; import {default as GoogleMapHolder} from "./GoogleMapHolder"; export const circleControlledPropTypes = { // [].map.call($0.querySelectorAll("tr>td>code"), function(it){ return it.textContent; }).filter(function(it){ return it.match(/^set/) && !it.match(/^setMap/); }) // https://developers.google.com/maps/documentation/javascript/3.exp/reference#Circle center: PropTypes.any, draggable: PropTypes.bool, editable: PropTypes.bool, options: PropTypes.object, radius: PropTypes.number, visible: PropTypes.bool, }; export const circleDefaultPropTypes = defaultPropsCreator(circleControlledPropTypes); const circleUpdaters = { center (center, component) { component.getCircle().setCenter(center); }, draggable (draggable, component) { component.getCircle().setDraggable(draggable); }, editable (editable, component) { component.getCircle().setEditable(editable); }, options (options, component) { component.getCircle().setOptions(options); }, radius (radius, component) { component.getCircle().setRadius(radius); }, visible (visible, component) { component.getCircle().setVisible(visible); }, }; const {eventPropTypes, registerEvents} = eventHandlerCreator(CircleEventList); export const circleEventPropTypes = eventPropTypes; @componentLifecycleDecorator({ registerEvents, instanceMethodName: "getCircle", updaters: circleUpdaters, }) export default class CircleCreator extends Component { static propTypes = { mapHolderRef: PropTypes.instanceOf(GoogleMapHolder).isRequired, circle: PropTypes.object.isRequired, } static _createCircle (mapHolderRef, circleProps) { // https://developers.google.com/maps/documentation/javascript/3.exp/reference#Circle const circle = new google.maps.Circle(composeOptions(circleProps, [ // https://developers.google.com/maps/documentation/javascript/3.exp/reference#CircleOptions "center", "draggable", "editable", "radius", "visible", ])); circle.setMap(mapHolderRef.getMap()); return circle; } getCircle () { return this.props.circle; } render () { return (<noscript />); } }
src/index.js
quebez/react_todolist
import React, { Component } from 'react'; import ReactDOM from 'react-dom'; import update from 'immutability-helper'; import InputBar from './components/input_bar'; import List from './components/list'; import Messages from './components/messages'; let timeoutId; class App extends Component { state = { items: [], tickedItems: [], messageId: 0 }; onDeleteClick = (item) => { this.setState(this.deleteItem(item)); this.deleteMessageAfterTimeout(); } onAddItemClick = (item, messageId) => { this.setState(this.addItem(item, messageId)); this.deleteMessageAfterTimeout(); } onTickUntickClick = (item) => { this.setState(this.tickUntickItem(item)); this.deleteMessageAfterTimeout(); } deleteMessageAfterTimeout = (state) => { clearTimeout(timeoutId); timeoutId = setTimeout(() => {this.setState({...state, messageId: 0})}, 5000); } addItem(item, messageId, state) { return { ...state, items: update(this.state.items, { $push: [item] }), messageId}; } deleteItem(item, state) { const list = item.ticked ? this.state.tickedItems : this.state.items; const newList = list.filter(element => { return element.id !== item.id; }); return item.ticked ? { ...state, tickedItems: newList, messageId: 3 } : { ...state, items: newList, messageId: -3 }; } tickUntickItem(item, state) { this.onDeleteClick(item); item.ticked = item.ticked ? false : true; return item.ticked ? { ...state, tickedItems: update(this.state.tickedItems, { $unshift: [item] }), messageId: 2 } : this.addItem(item, -2, state); } render() { return ( <div> <div className='messages'> <Messages messageId={this.state.messageId} /> </div> <div className='content'> <InputBar onAddItemClick={this.onAddItemClick} /> <br /> <List items={this.state.items} onDeleteClick={this.onDeleteClick} onTickUntickClick={this.onTickUntickClick} /> <List items={this.state.tickedItems} onDeleteClick={this.onDeleteClick} onTickUntickClick={this.onTickUntickClick} /> </div> </div> ); }; } ReactDOM.render(<App />, document.querySelector('.container'));
components/logo.js
mars/heroku-nextjs
import React from 'react' // Circle Right icon designed by Hector (CC license): https://thenounproject.com/term/circle-right/557979 export default (props) => <svg viewBox="0 0 1150.9491 1151.219" {...props}><g transform="translate(1904.506,419.41757)"><path d="m -1354.6565,731.56083 c -20.4904,-1.2663 -41.6453,-3.3398 -56.875,-5.5744 -120.7717,-17.7206 -230.7568,-71.8587 -318.5583,-156.8044 -90.8856,-87.92949 -150.3919,-204.43803 -168.8656,-330.62503 -4.2575,-29.08131 -5.5507,-48.30232 -5.5507,-82.5 0,-34.19767 1.2932,-53.41869 5.5507,-82.500001 17.6653,-120.66555 71.8544,-230.758109 156.7989,-318.558329 87.9295,-90.88557 204.438,-150.39189 330.625,-168.86555 29.0813,-4.25748 48.3023,-5.55069 82.5,-5.55069 34.1977,0 53.4187,1.29321 82.5,5.55069 126.187,18.47366 242.6955,77.97998 330.62496,168.86556 26.5872,27.48095 45.6005,51.07991 66.1988,82.16452 54.0043,81.497079 85.2183,170.4165988 94.6107,269.5188 0.8471,8.9375 1.5401,31.15625 1.5401,49.375 0,44.49681 -3.0696,75.17263 -11.7846,117.76996 -14.705,71.87482 -45.7252,144.69077 -88.1667,206.95994 -48.3424,70.92683 -114.3252,132.03273 -188.64826,174.70493 -70.9275,40.7226 -153.5259,66.7537 -235.625,74.2577 -15.4629,1.4134 -64.5864,2.5708 -76.875,1.8113 z m 77.8682,-139.798 c 129.6922,-16.8933 241.2895,-85.75754 312.08516,-192.58083 38.8375,-58.60169 62.0617,-122.51198 70.8604,-195 2.2079,-18.1894 2.2079,-75.5606 0,-93.75 -14.469,-119.2023912 -71.0092,-221.84159 -162.68876,-295.33419 -63.2446,-50.69841 -140.8843,-82.69356 -225.625,-92.97956 -18.1894,-2.20786 -75.5606,-2.20786 -93.75,0 -84.7407,10.286 -162.3804,42.28115 -225.625,92.97956 -91.6796,73.4926 -148.2197,176.1317988 -162.6888,295.33419 -2.2078,18.1894 -2.2078,75.5606 0,93.75 14.4672,119.18687 71.0528,221.91 162.6888,295.33839 63.3034,50.72534 146.1995,84.78074 225.625,92.69134 7.5625,0.7532 15.7187,1.5927 18.125,1.8655 10.3498,1.1734 66.5446,-0.4324 80.9932,-2.3144 z m -73.958,-217.77592 -42.3398,-41.98998 55.7773,-55.78762 c 30.6775,-30.68319 55.7773,-56.25862 55.7773,-56.8343 0,-0.57566 -73.5469,-0.8546 -163.4375,-0.61983 l -163.4375,0.42682 0,-60 0,-60.000001 165.3125,-0.3171 c 90.9219,-0.1744 165.3125,-0.69776 165.3125,-1.16303 0,-0.46524 -25.875,-26.38857 -57.5,-57.60736 -31.625,-31.2188002 -57.5,-57.41734 -57.5,-58.21897 0,-1.76811 82.6199,-84.568539 84.3841,-84.568539 0.685,0 59.6315,58.388139 130.9923,129.751399 l 129.7469,129.751411 -129.2534,129.62359 c -71.0894,71.29298 -129.7578,129.60557 -130.3742,129.58355 -0.6164,-0.022 -20.1736,-18.93555 -43.4605,-42.03004 z" fill="#000000"></path></g></svg>